html {
    scroll-behavior: smooth;
    scroll-padding-top: 80px;
}

/* Reset e estilos base */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* Animação de rolagem suave */
@media screen and (prefers-reduced-motion: no-preference) {
    html {
        scroll-behavior: smooth;
        transition: scroll-behavior var(--scroll-duration) ease;
    }
}

:root {
    --primary: #ff4d05;
    --secondary: #ff6b3d;
    --white: #ffffff;
    --gray-50: #f8fafc;
    --gray-100: #f1f5f9;
    --gray-200: #e2e8f0;
    --gray-300: #cbd5e1;
    --gray-600: #475569;
    --gray-700: #334155;
    --gray-800: #1e293b;
    --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05);
    --shadow: 0 4px 6px -1px rgb(0 0 0 / 0.1);
    --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.1);
}

html, body {
    height: 100%;
    overflow-x: hidden;
    background: var(--white);
}

body {
    font-family: 'Poppins', sans-serif;
    color: var(--gray-800);
    line-height: 1.6;
}

.noise {
    position: fixed;
    inset: 0;
    z-index: 9999;
    pointer-events: none;
    opacity: 0.05;
    background: url('data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADIAAAAyBAMAAADsEZWCAAAAElBMVEUAAAD8/vz08vT09PT8/Pz///8YzgzOAAAABnRSTlMAICDw8ODT1TCqAAAAQUlEQVQ4y2NgGAWjYBSMAhQgkZCQgNgQEhJSDwwMnFxcXP4BAwPrBwaGQG4uLkluLi4dbi4uVm4uLkNuLi4tAM4UCexzi5h0AAAAAElFTkSuQmCC');
}

.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

/* Header */
.header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 80px; /* Altura fixa do header */
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    z-index: 1000;
    border-bottom: 1px solid var(--gray-100);
}

.nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 80px;
}

/* Menu Hambúrguer */
.menu-toggle {
    display: none;
    flex-direction: column;
    justify-content: space-between;
    width: 30px;
    height: 21px;
    cursor: pointer;
    z-index: 1001;
    padding: 0;
    background: none;
    border: none;
}

.menu-toggle span {
    display: block;
    width: 100%;
    height: 3px;
    background: var(--gray-800);
    transition: all 0.3s ease;
    border-radius: 3px;
}

/* Classe para quando o menu estiver aberto */
.menu-open .menu-toggle span:nth-child(1) {
    transform: translateY(9px) rotate(45deg);
}

.menu-open .menu-toggle span:nth-child(2) {
    opacity: 0;
}

.menu-open .menu-toggle span:nth-child(3) {
    transform: translateY(-9px) rotate(-45deg);
}

.logo {
    display: flex;
    align-items: center;
    text-decoration: none;
    position: relative;
    padding: 0.5rem;
}

.logo-text {
    font-size: 1.75rem;
    font-weight: 800;
    background: linear-gradient(135deg, var(--primary) 0%, var(--secondary) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    letter-spacing: -0.5px;
    position: relative;
}

.logo-text::before {
    content: '<';
    position: absolute;
    left: -1rem;
    opacity: 0.6;
}

.logo-text::after {
    content: '/>';
    position: absolute;
    right: -1.5rem;
    opacity: 0.6;
}

.logo-dot {
    width: 6px;
    height: 6px;
    background: var(--primary);
    border-radius: 50%;
    margin-left: 4px;
    position: relative;
    animation: pulse 2s infinite;
}

.logo-dot::after {
    content: '';
    position: absolute;
    width: 12px;
    height: 12px;
    background: var(--primary);
    border-radius: 50%;
    opacity: 0.3;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    animation: pulse 2s infinite 0.3s;
}

.nav-links {
    display: flex;
    gap: 2rem;
    list-style: none;
}

.nav-link {
    color: var(--gray-700);
    text-decoration: none;
    font-weight: 500;
    position: relative;
    padding: 0.5rem 0;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 2px;
    background: var(--primary);
    transform: scaleX(0);
    transform-origin: right;
    transition: transform 0.3s ease;
}

.nav-link:hover::after {
    transform: scaleX(1);
    transform-origin: left;
}

/* Hero Section */
.hero {
    min-height: 100vh;
    padding: 120px 0 60px;
    display: flex;
    align-items: center;
}

.hero-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.hero-content {
    max-width: 600px;
    animation: fadeInUp 1s ease-out;
}

.hero h1 {
    font-size: 4rem;
    line-height: 1.1;
    margin-bottom: 1.5rem;
    color: var(--gray-800);
}

.hero p {
    font-size: 1.25rem;
    color: var (--gray-600);
    margin-bottom: 2rem;
}

.hero-buttons {
    display: flex;
    gap: 1rem;
}

.hero-image {
    width: 100%;
    height: 100%;
}

.hero-image-wrapper {
    width: 100%;
    height: 100%;
    border-radius: 20px;
    overflow: hidden;
    box-shadow: var(--shadow-lg);
    animation: fadeInUp 1s ease-out 0.3s backwards;
}

.hero-image-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transform: scale(1.1);
    transition: transform 0.6s ease;
}

/* Skills Section */
.skills {
    padding: 8rem 0;
    background: var(--gray-50);
}

.section-title {
    font-size: 2.5rem;
    text-align: center;
    margin-bottom: 4rem;
    color: var(--gray-800);
}

/* Ajuste nas seções para scroll */
section {
    scroll-margin-top: 100px; /* Aumentado para dar mais espaço */
}

#home, #about, #skills, #projects, #contact {
    scroll-margin-top: 100px; /* Aumentado para dar mais espaço */
    scroll-behavior: smooth;
}

.skills-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
}

.skill-card {
    background: var(--white);
    padding: 2rem;
    border-radius: 12px;
    box-shadow: var(--shadow);
    animation: fadeInUp 0.6s ease-out;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.skill-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.skill-header {
    margin-bottom: 2rem;
}

.skill-header h3 {
    font-size: 1.5rem;
    color: var(--gray-800);
    margin-bottom: 1rem;
}

.skill-progress {
    height: 6px;
    background: var(--gray-200);
    border-radius: 3px;
    overflow: hidden;
}

.progress {
    height: 100%;
    background: var(--primary);
    transform-origin: left;
    transform: scaleX(1) !important;
    animation: slideIn 1s ease-out;
}

.skill-list {
    list-style: none;
}

.skill-list li {
    padding: 0.75rem 0;
    color: var(--gray-600);
    opacity: 1 !important;
    transform: none !important;
}

/* Projects Section - Novo estilo mais compacto */
.projects {
    padding: 6rem 0;
    background: var(--gray-50);
}

.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 2.5rem;
    margin-top: 2rem;
}

.project-card {
    background: var(--white);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    height: 100%;
    animation: fadeInUp 0.6s ease-out;
}

.project-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.project-image {
    position: relative;
    padding-top: 56.25%; /* Aspect ratio 16:9 */
    overflow: hidden;
}

.project-image img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.project-content {
    padding: 1.5rem;
}

.project-title {
    font-size: 1.25rem;
    margin-bottom: 0.5rem;
    color: var (--gray-800);
}

.project-description {
    font-size: 0.875rem;
    color: var(--gray-600);
    margin-bottom: 1rem;
    line-height: 1.6;
    /* Removendo as propriedades que limitavam o texto */
    /* display: -webkit-box;
    -webkit-line-clamp: 3;
    line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    height: 3.9em; */
}

.tech-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.375rem;
    margin-bottom: 1rem;
}

.tech-tag {
    font-size: 0.75rem;
    padding: 0.25rem 0.5rem;
    background: var(--gray-100);
    color: var(--gray-600);
    border-radius: 12px;
}

.project-links {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    margin-top: 1rem;
}

.btn-github {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    font-size: 0.875rem;
    padding: 0.5rem 0.75rem;
    border-radius: 6px;
    background: var(--gray-100);
    color: var(--gray-700);
    text-decoration: none;
    transition: all 0.3s ease;
}

.btn-github:hover {
    background: var(--gray-200);
    color: var(--gray-800);
}

/* Responsividade para projetos */
@media (max-width: 768px) {
    .projects-grid {
        grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    }
    
    .project-card {
        max-width: none;
    }
}

/* Contact Section */
.contact {
    padding: 8rem 0;
    background: var(--gray-50);
    opacity: 1 !important;
    visibility: visible !important;
    display: block !important;
}

.contact-form {
    max-width: 600px;
    margin: 0 auto;
    background: var(--white);
    padding: 3rem;
    border-radius: 12px;
    box-shadow: var(--shadow);
    opacity: 1 !important; /* Garantir visibilidade */
    transform: none !important; /* Remover transformação que pode estar escondendo */
    animation: fadeInUp 0.8s ease-out;
}

/* Contact Section Enhanced */
.contact-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
    max-width: 1000px;
    margin: 0 auto;
}

.contact-info {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
    max-width: 1000px;
    margin: 0 auto;
}

.contact-card {
    background: var(--white);
    padding: 2.5rem 2rem;
    border-radius: 12px;
    box-shadow: var(--shadow);
    text-align: center;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    animation: fadeInUp 0.6s ease-out;
}

.contact-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.contact-card i {
    font-size: 2rem;
    color: var(--primary);
    margin-bottom: 1rem;
}

.contact-card h3 {
    font-size: 1.25rem;
    color: var(--gray-800);
    margin-bottom: 0.5rem;
}

.contact-card p {
    color: var(--gray-600);
    margin-bottom: 1rem;
    font-size: 0.875rem;
}

.contact-link {
    color: var(--primary);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.contact-link:hover {
    color: var(--secondary);
}

.contact-form {
    background: var(--white);
    padding: 2.5rem;
    border-radius: 12px;
    box-shadow: var(--shadow);
}

.btn i {
    margin-right: 0.5rem;
}

/* Responsividade do contato */
@media (max-width: 768px) {
    .contact-content {
        grid-template-columns: 1fr;
    }
    
    .contact-info {
        order: 2;
        grid-template-columns: 1fr;
        max-width: 400px;
    }
    
    .contact-form {
        order: 1;
    }
}

.form-group {
    position: relative;
    margin-bottom: 2rem;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 1rem 0;
    font-size: 1rem;
    color: var(--gray-800);
    border: none;
    border-bottom: 2px solid var(--gray-200);
    background: transparent;
    transition: border-color 0.3s ease;
}

.form-group label {
    position: absolute;
    left: 0;
    top: 1rem;
    color: var(--gray-600);
    transition: all 0.3s ease;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--primary);
}

.form-group input:focus + label,
.form-group textarea:focus + label,
.form-group input:not(:placeholder-shown) + label,
.form-group textarea:not(:placeholder-shown) + label {
    transform: translateY(-1.5rem);
    font-size: 0.875rem;
    color: var(--primary);
}

/* Botões */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.75rem 2rem;
    border-radius: 8px;
    font-weight: 500;
    text-decoration: none;
    transition: all 0.3s ease;
    border: none;
    cursor: pointer;
}

.btn-primary {
    background: var(--primary);
    color: var(--white);
    transition: all 0.3s ease;
}

.btn-primary:hover {
    background: var(--secondary);
    transform: translateY(-2px);
}

.btn-outline {
    background: transparent;
    border: 2px solid var(--primary);
    color: var(--primary);
}

.btn-outline:hover {
    background: var(--primary);
    color: var(--white);
    transform: translateY(-2px);
}

.btn-icon {
    width: 40px;
    height: 40px;
    padding: 0;
    border-radius: 50%;
    font-size: 1.25rem;
}

/* Footer */
.footer {
    padding: 4rem 0;
    background: var(--white);
    border-top: 1px solid var(--gray-100);
}

.footer-content {
    text-align: center;
}

.social-links {
    display: flex;
    justify-content: center;
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.social-link {
    color: var(--gray-600);
    font-size: 1.5rem;
    transition: color 0.3s ease;
}

.social-link:hover {
    color: var(--primary);
    transform: translateY(-2px);
}

/* Classes para animações */
.reveal-text {
    overflow: hidden;
}

.reveal-text span {
    display: block;
    transform: translateY(100%);
}

.reveal-card {
    opacity: 1 !important;
    transform: none !important;
    visibility: visible !important;
}

.reveal-form {
    opacity: 1 !important;
    transform: none !important;
    visibility: visible !important;
}

/* About Section */
.about {
    min-height: 100vh;
    display: flex;
    align-items: center;
    padding: 6rem 0;
    background: var(--white);
    position: relative;
}

.about-content {
    display: grid;
    grid-template-columns: 1fr;
    gap: 4rem;
    max-width: 800px;
    margin: 0 auto;
}

.about-text {
    font-size: 1.25rem;
    color: var(--gray-600);
    text-align: center;
}

.about-text p {
    margin-bottom: 3rem;
    line-height: 1.8;
}

/* About Section Enhanced */
.about-description {
    max-width: 800px;
    margin: 0 auto 2rem;
}

.about-description p {
    margin-bottom: 1.5rem;
    line-height: 1.8;
    font-size: 1.1rem;
    color: var(--gray-700);
}

.about-info {
    display: flex;
    justify-content: center;
    gap: 3rem;
    margin-bottom: 2.5rem;
}

.about-info-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    color: var(--gray-700);
}

.about-info-item i {
    color: var(--primary);
    font-size: 1.25rem;
}

.about-social {
    display: flex;
    justify-content: center;
    gap: 2rem;
    margin-top: 2rem;
}

.about-social .social-link {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    text-decoration: none;
    color: var(--gray-700);
    transition: all 0.3s ease;
}

.about-social .social-icon {
    width: 3.5rem;
    height: 3.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--white);
    border-radius: 1rem;
    border: 2px solid var(--gray-200);
    transition: all 0.3s ease;
}

.about-social .social-icon i {
    font-size: 1.5rem;
    color: var(--primary);
    transition: all 0.3s ease;
}

.about-social .social-link span {
    font-size: 0.875rem;
    font-weight: 500;
}

.about-social .social-link:hover {
    color: var(--primary);
    transform: translateY(-5px);
}

.about-social .social-link:hover .social-icon {
    background: var(--primary);
    border-color: var(--primary);
}

.about-social .social-link:hover .social-icon i {
    color: var(--white);
}

/* Responsive adjustments for About section */
@media (max-width: 768px) {
    .about-info {
        flex-direction: column;
        gap: 1rem;
        align-items: center;
    }

    .about-social {
        flex-wrap: wrap;
        gap: 1.5rem;
    }

    .about-description {
        padding: 0 1rem;
    }
}

/* Ajustes para garantir visibilidade */
.reveal-card,
.reveal-form,
.project-card,
.contact-form {
    opacity: 1 !important;
    transform: none !important;
    visibility: visible !important;
}

.progress {
    transform: scaleX(1) !important;
}

.skill-list li {
    opacity: 1 !important;
    transform: none !important;
}

/* Responsividade */
@media (max-width: 768px) {
    .hero-container {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .hero h1 {
        font-size: 2.5rem;
    }

    .hero-buttons {
        justify-content: center;
    }

    .skills-grid {
        grid-template-columns: 1fr;
    }

    .nav-links {
        display: flex; /* Alterado de 'none' para 'flex' */
        position: fixed;
        top: 80px; /* Ajustado para começar abaixo do header */
        right: -100%;
        width: 100%; /* Menu ocupa toda a largura */
        height: calc(100vh - 80px); /* Altura ajustada */
        background: var(--white);
        flex-direction: column;
        justify-content: flex-start;
        align-items: center;
        gap: 2rem;
        padding-top: 2rem;
        transition: right 0.3s ease;
        box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    }

    .menu-open .nav-links {
        right: 0;
        display: flex;
    }

    .menu-toggle {
        display: flex;
    }
    
    .menu-toggle span {
        display: block;
        width: 100%;
        height: 3px;
        background: var(--gray-800);
        transition: all 0.3s ease;
        border-radius: 3px;
    }

    .menu-open .menu-toggle span:nth-child(1) {
        transform: translateY(9px) rotate(45deg);
    }

    .menu-open .menu-toggle span:nth-child(2) {
        opacity: 0;
    }

    .menu-open .menu-toggle span:nth-child(3) {
        transform: translateY(-9px) rotate(-45deg);
    }

    .about-content {
        padding: 0 1rem;
    }
    
    .project-links {
        flex-direction: row;
        justify-content: flex-end;
        gap: 1rem;
    }
    
    .project-card {
        max-width: 400px;
        margin: 0 auto;
    }

    .header {
        height: 70px; /* Altura ligeiramente menor em mobile */
    }

    #home, #about, #skills, #projects, #contact {
        scroll-margin-top: 70px; /* Ajuste correspondente para mobile */
    }
}

/* Adicionando animações */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideIn {
    from {
        transform: translateX(-100%);
    }
    to {
        transform: translateX(0);
    }
}

@keyframes pulse {
    0% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
    100% {
        transform: scale(1);
    }
}

/* Modal e Botão de Tecnologias */
.tech-button {
    background: var(--primary);
    color: var(--white);
    border: none;
    padding: 0.5rem 1rem;
    border-radius: 6px;
    cursor: pointer;
    font-size: 0.875rem;
    margin-bottom: 1rem;
    transition: all 0.3s ease;
    width: 100%;
    margin-bottom: 0;
}

.tech-button:hover {
    background: var(--secondary);
    transform: translateY(-2px);
}

.tech-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 1100;
    backdrop-filter: blur(5px);
}

.tech-modal-content {
    position: relative;
    background: var(--white);
    margin: 15% auto;
    padding: 2rem;
    width: 90%;
    max-width: 500px;
    border-radius: 12px;
    box-shadow: var(--shadow-lg);
    animation: modalSlideIn 0.3s ease-out;
}

.tech-modal-content h3 {
    color: var(--gray-800);
    margin-bottom: 1.5rem;
    font-size: 1.5rem;
}

.tech-modal-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
}

.tech-modal-item {
    background: var(--gray-100);
    color: var(--primary);
    padding: 0.5rem 1rem;
    border-radius: 20px;
    font-size: 0.875rem;
    font-weight: 500;
    animation: fadeInUp 0.3s ease-out;
}

.close-modal {
    position: absolute;
    right: 1rem;
    top: 1rem;
    font-size: 1.5rem;
    color: var(--gray-600);
    cursor: pointer;
    transition: color 0.3s ease;
}

.close-modal:hover {
    color: var(--primary);
}

@keyframes modalSlideIn {
    from {
        transform: translateY(-20px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}