@import url('https://fonts.googleapis.com/css2?family=Cascadia+Code:wght@200;300;400;500;600;700&display=swap');

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    font-size: 10px;
    scrollbar-width: none;
    scroll-behavior: smooth;
}

html::-webkit-scrollbar {
    display: none;
}

body {
    font-family: "Cascadia Code", monospace;
    overflow-x: hidden;
    overflow-y: auto;
    height: 100vh;
    margin: 0;
    height: 400vh;
    scroll-snap-type: y proximity;
}

@media (max-width: 768px) {
    body {
        height: auto !important;
        overflow-y: auto !important;
        overflow-x: hidden !important;
    }
    
    .scroll-container {
        position: relative !important;
        display: flex !important;
        flex-direction: column !important;
        height: auto !important;
        width: 100% !important;
        background: #000;
    }

    body::before, body::after {
        display: none !important;
    }
    
    .section {
        width: 100vw !important;
        height: 100vh !important;
        min-height: 100vh !important;
        position: relative !important;
        display: flex !important;
        flex-direction: column !important;
        justify-content: center !important;
        padding: 40px 20px !important;
        transition: none !important;
    }
    
    /* Força os textos e conteúdos a aparecerem */
    .perfil-content,
    .projeto-content,
    .portfolio-content,
    .contato-content {
        opacity: 1 !important;
        pointer-events: auto !important;
        width: 90%;
        max-width: 90%;
        margin: 0 auto;
        padding: 20px 0;
    }

    /* Esconde os labels gigantes de fundo que atrapalham no mobile */
    .perfil-label,
    .projeto-label,
    .portfolio-label,
    .contato-label {
        display: none;
    }
    
    /* Ajustes específicos de Layout */
    .hard-skills {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .projeto-content,
    .portfolio-content {
        flex-direction: column;
        margin-left: 0;
        gap: 30px;
    }
    
    .perfil-image {
        width: 100%;
        max-width: 300px;
    }
    
    .home-name {
        font-size: 15vw; /* Responsivo */
        margin-left: 0;
        text-align: center;
        margin-bottom: 20px;
    }

    /* --- LÓGICA DO MENU E LOGO NO MOBILE --- */
    
    /* Botão Menu e Logo sempre visíveis e fixos */
    .menu-toggle, .logo {
        position: fixed;
        opacity: 1 !important;
        pointer-events: auto !important;
        z-index: 2005; /* Acima do overlay */
    }

    .menu-toggle {
        top: 25px;
        right: 25px;
    }

    .logo {
        top: 25px;
        left: 25px;
        font-size: 24px;
        display: block !important;
    }

    /* TRUQUE DE MÁGICA PARA COR: 
       Isso faz o elemento virar a cor "oposta" do fundo.
       Fundo Branco -> Vira Preto. Fundo Preto -> Vira Branco. */
    .menu-toggle, .logo {
        mix-blend-mode: difference; 
        color: #fff !important; /* Base branca */
    }
    
    .menu-toggle span {
        background: #fff !important; /* Base branca */
    }

    /* Removemos a classe .dark via JS no mobile pois o mix-blend-mode resolve */
    .menu-toggle.dark span, .logo.dark {
        color: #fff !important;
        background: #fff !important;
    }
    
    /* Ajuste do Menu Aberto */
    .menu-overlay {
        padding: 80px 30px 30px 30px;
        flex-direction: column;
        justify-content: flex-start;
        overflow-y: auto;
    }

    .menu-close {
        top: 20px;
        right: 25px;
        font-size: 40px;
        z-index: 2010; /* Acima do toggle */
    }

    .scroll-indicator-home {
        display: none;
    }   
}

.scroll-container {
    display: flex;
    height: 100vh;
    position: fixed !important;
    top: 0;
    left: 0;
    width: 100vw;
    background: #000000;
}

body::before {
    content: '';
    position: absolute;
    top: 160vh;
    height: 1px;
    width: 100%;
    scroll-snap-align: start;
}

body::after {
    content: '';
    position: absolute;
    top: 210vh;
    height: 1px;
    width: 100%;
    scroll-snap-align: start;
}

.section {
    height: 100vh !important;
    display: flex !important;
    align-items: center;
    justify-content: center;
    transition: width 0.6s ease !important;
    position: relative !important;
    flex-shrink: 0;
    overflow: hidden;
}

.section h1 {
    font-size: 6rem;
    font-weight: 900;
}

.page-1 {
    background: #ffffff;
}

.home-name {
    font-size: 10rem;
    font-weight: 900;
    color: #000;
    line-height: 1;
    padding-left: 0;
    margin-left: -6rem;
}

.home-subtitle {
    font-size: 2.5rem;
    font-weight: 400;
    color: #666;
    margin-top: 2rem;
    padding-left: 0;
    letter-spacing: 0.2em;
}

.scroll-indicator-home {
    position: fixed;
    bottom: 4rem;
    right: 2rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
    z-index: 100;
    opacity: 1;
    transition: opacity 0.3s ease;
}

.scroll-indicator-home svg {
    width: 20px;
    height: 35px;
}

.scroll-indicator-home svg rect {
    stroke: #fff;
}

.scroll-indicator-home svg circle {
    fill: #fff;
}

.scroll-indicator-home.hidden {
    opacity: 0 !important;
    pointer-events: none;
    display: none !important;
}

.scroll-indicator-home p {
    font-size: 0.9rem;
    font-weight: 600;
    color: #fff;
    letter-spacing: 0.1em;
}

.gap-1 {
    background: #000000;
    position: relative;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
}

.perfil-label {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 36px;
    font-weight: 900;
    color: rgba(255, 255, 255, 0.15);
    letter-spacing: 0.15em;
    z-index: 5;
    opacity: 0;
    transition: opacity 0.25s ease;
    pointer-events: none;
    writing-mode: vertical-rl;
    text-orientation: mixed;
}

.perfil-label.visible {
    opacity: 1;
}

.perfil-content {
    position: relative;
    box-sizing: border-box;
    width: 800px;
    min-width: 800px;
    max-width: 800px;
    color: #fff;
    line-height: 1.4;
    padding: 32px;
    z-index: 10;
    display: flex;
    flex-direction: column;
    justify-content: center;
    flex-shrink: 0;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.25s ease;
}

.perfil-content.visible {
    opacity: 1;
    pointer-events: auto;
}

.perfil-content h2 {
    font-size: 24px;
    font-weight: 900;
    margin-bottom: 12px;
}

.perfil-content p {
    font-size: 17px;
    line-height: 1.6;
    margin-bottom: 18px;
    font-weight: 400;
    max-width: 100%;
    word-break: normal;
    overflow-wrap: normal;
    hyphens: none;
}

.hard-skills {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
    width: 100%;
    align-items: center;
}

.skill-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 4px 6px;
    background: transparent;
    border: none;
    border-radius: 0;
    font-size: 13px;
    color: #c18c4f;
    flex-shrink: 0;
}

.skill-icon {
    width: 32px;
    height: 32px;
    flex-shrink: 0;
    display: block;
}

.skill-item span {
    font-weight: 600;
    color: #4ec9b0;
}

.page-2 {
    background: #ffffff;
    color: #000;
}

.page-2 h1 {
    color: #000;
}

.page-3 {
    background: #ffffff;
    color: #000;
}

.page-3 h1 {
    color: #000;
}

.portfolio-label {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 36px;
    font-weight: 900;
    color: rgba(0, 0, 0, 0.08);
    letter-spacing: 0.15em;
    z-index: 5;
    opacity: 0;
    transition: opacity 0.25s ease;
    pointer-events: none;
    writing-mode: vertical-rl;
    text-orientation: mixed;
}

.portfolio-label.visible {
    opacity: 1;
}

.portfolio-content {
    position: relative;
    box-sizing: border-box;
    width: 900px;
    max-width: 90vw;
    color: #000;
    background: transparent;
    line-height: 1.4;
    padding: 20px;
    z-index: 10;
    display: flex;
    flex-direction: row;
    gap: 30px;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.25s ease;
    margin-left: -100px;
}

.portfolio-content.visible {
    opacity: 1;
    pointer-events: auto;
}

.portfolio-text {
    flex: 1 1 auto;
    text-align: center;
    color: #000;
    max-width: 600px;
}

.portfolio-text h2 {
    font-size: 22px;
    font-weight: 900;
    margin-bottom: 12px;
}

.portfolio-text p {
    font-size: 16px;
    line-height: 1.6;
    margin-bottom: 12px;
    color: #000;
}

.projeto-label {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 36px;
    font-weight: 900;
    color: rgba(0, 0, 0, 0.1);
    letter-spacing: 0.15em;
    z-index: 5;
    opacity: 0;
    transition: opacity 0.25s ease;
    pointer-events: none;
    writing-mode: vertical-rl;
    text-orientation: mixed;
}

.projeto-label.visible {
    opacity: 1;
}

.projeto-content {
    position: relative;
    box-sizing: border-box;
    width: 900px;
    max-width: 90vw;
    color: #000;
    background: transparent;
    line-height: 1.4;
    padding: 20px;
    z-index: 10;
    display: flex;
    flex-direction: row;
    gap: 30px;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.25s ease;
    margin-left: -100px;
}

.projeto-content.visible {
    opacity: 1;
    pointer-events: auto;
}

.projeto-text {
    flex: 1 1 auto;
    text-align: center;
    color: #000;
}

.projeto-text h2 {
    font-size: 22px;
    font-weight: 900;
    margin-bottom: 12px;
}

.projeto-text p {
    font-size: 16px;
    line-height: 1.6;
    margin-bottom: 12px;
    color: #000;
}

.perfil-image {
    width: 270px;
    height: auto;
    display: block;
    border-radius: 6px;
    object-fit: contain;
    flex-shrink: 0;
    transition: transform 0.3s ease;
    cursor: pointer;
    filter: invert(1);
}

.perfil-image:hover {
    transform: scale(1.05);
}

.github-link {
    display: inline-block;
    text-decoration: none;
    color: inherit;
    line-height: 0;
}

.github-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    background: #000;
    border: none;
    border-radius: 50%;
    color: #fff;
    text-decoration: none;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
    flex-shrink: 0;
}

.github-btn:hover {
    background: #333;
}

.github-btn svg {
    display: block;
    width: 18px;
    height: 18px;
}



.gap-2 {
    background: #000000;
    position: relative;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
}

.contato-label {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 36px;
    font-weight: 900;
    color: rgba(255, 255, 255, 0.15);
    letter-spacing: 0.15em;
    z-index: 5;
    opacity: 0;
    transition: opacity 0.25s ease;
    pointer-events: none;
    writing-mode: vertical-rl;
    text-orientation: mixed;
}

.contato-label.visible {
    opacity: 1;
}

.contato-content {
    position: relative;
    box-sizing: border-box;
    width: 650px;
    color: #fff;
    padding: 32px;
    z-index: 10;
    display: flex;
    flex-direction: column;
    justify-content: center;
    flex-shrink: 0;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.25s ease;
}

.contato-content.visible {
    opacity: 1;
    pointer-events: auto;
}

.contato-content h2 {
    font-size: 24px;
    font-weight: 900;
    margin-bottom: 24px;
    text-align: center;
}

.contato-links {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.contato-item {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 12px 16px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 8px;
    color: #fff;
    text-decoration: none;
    transition: background 0.3s ease;
}

.contato-item:hover {
    background: rgba(255, 255, 255, 0.1);
}

.contato-item svg {
    flex-shrink: 0;
}

.contato-item:nth-child(1) span {
    font-size: 16px;
    font-weight: 600;
    color: #4ec9b0;
}

.contato-item:nth-child(2) span {
    font-size: 16px;
    font-weight: 600;
    color: #dcdcaa;
}

.contato-item:nth-child(3) span {
    font-size: 16px;
    font-weight: 600;
    color: #4ec9b0;
}

.v-section {
    width: 100%;
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    position: absolute;
    top: 0;
    left: 0;
    transition: none;
}

.v-section h2 {
    font-size: 4rem;
    font-weight: 900;
}

.v1 {
    background: #e8f4f8;
}

.v2 {
    background: #d4e9f2;
}

.v3 {
    background: #c0deec;
}

.v4 {
    background: #acd3e6;
}

.logo {
    position: fixed;
    top: 4rem;
    left: 4rem;
    z-index: 1001;
    font-size: 3rem;
    font-weight: 900;
    color: #ffffff;
    opacity: 0;
    transition: opacity 0.5s ease, color 0.3s ease;
}

.logo.visible {
    opacity: 1;
}

.logo.dark {
    color: #000000;
}

.menu-toggle {
    position: fixed;
    top: 4rem;
    right: 4rem;
    z-index: 1001;
    background: none;
    border: none;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
    opacity: 0;
    transition: opacity 0.5s ease;
}

.menu-toggle.visible {
    opacity: 1;
}

.menu-toggle span {
    width: 3rem;
    height: 0.2rem;
    background: #ffffff;
    transition: background 0.3s ease;
}

.menu-toggle.dark span {
    background: #000000;
}

.menu-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    background: #000000;
    z-index: 2000;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 8rem;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.5s ease;
}

@media (max-width: 768px) {
    .menu-overlay {
        padding: 2rem;
        flex-direction: column;
        justify-content: flex-start;
        align-items: flex-start;
        overflow-y: auto;
    }
    
    .menu-close {
        top: 2rem;
        right: 2rem;
        font-size: 4rem;
    }
    
    .menu-link {
        font-size: 3rem;
    }
    
    .submenu-link {
        font-size: 2.5rem;
    }
    
    .submenu-toggle {
        font-size: 2.5rem;
    }
    
    .menu-info {
        margin-top: 3rem;
        align-items: flex-start;
    }
    
    .menu-contact p {
        text-align: left;
        font-size: 1rem;
    }
    
    .menu-social {
        align-items: flex-start;
    }
    
    .menu-social a {
        font-size: 1rem;
    }
}

.menu-overlay.active {
    opacity: 1;
    pointer-events: all;
}

.menu-close {
    position: absolute;
    top: 4rem;
    right: 4rem;
    background: none;
    border: none;
    color: #ffffff;
    font-size: 6rem;
    cursor: pointer;
    line-height: 1;
}

.menu-nav {
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

.menu-link {
    color: #ffffff;
    text-decoration: none;
    font-size: 6rem;
    font-weight: 300;
    transition: opacity 0.3s ease;
}

.menu-link:hover {
    opacity: 0.6;
}

.menu-item-with-submenu {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.submenu-toggle {
    background: none;
    border: none;
    color: #ffffff;
    font-size: 4rem;
    cursor: pointer;
    transition: transform 0.3s ease;
    padding: 0;
    line-height: 1;
}

.submenu-toggle.active {
    transform: rotate(90deg);
}

.submenu {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    padding-left: 3rem;
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
}

.submenu.active {
    max-height: 300px;
}

.submenu-link {
    color: #ffffff;
    text-decoration: none;
    font-size: 4rem;
    font-weight: 300;
    transition: opacity 0.3s ease;
}

.submenu-link:hover {
    opacity: 0.6;
}

.menu-info {
    display: flex;
    flex-direction: column;
    gap: 4rem;
    align-items: flex-end;
}

.menu-contact p {
    color: #ffffff;
    font-size: 1.4rem;
    text-align: right;
}

.menu-social {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    align-items: flex-end;
}

.menu-social a {
    color: #ffffff;
    text-decoration: none;
    font-size: 1.4rem;
    transition: opacity 0.3s ease;
}

.menu-social a:hover {
    opacity: 0.6;
}
