/* Variáveis globais: cores, tipografia e tema escuro. */
:root {
    color-scheme: dark;
    --background: #111318;
    --surface: #171a20;
    --text: #f3f4f6;
    --muted: #aeb4c0;
    --accent: #8ab4f8;
    --border: #30353e;
    --font-body: 'Manrope', sans-serif;
    --font-mono: 'IBM Plex Mono', monospace;
}

/* Padronização do cálculo de largura e altura dos elementos. */
* {
    box-sizing: border-box;
}

html {
    scroll-padding-top: 112px;
}

/* Aparência geral da página. */
body {
    margin: 0;
    background: var(--background);
    color: var(--text);
    font-family: var(--font-body);
    -webkit-font-smoothing: antialiased;
}

a {
    color: inherit;
    text-decoration: none;
}

button {
    font: inherit;
}

a, button {
    touch-action: manipulation;
}

/* Indicação de foco para quem navega usando o teclado. */
:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 5px;
}

img {
    display: block;
    max-width: 100%;
}

h1, h2, h3, p {
    overflow-wrap: break-word;
}

/* Largura máxima e margens laterais do conteúdo. */
.container {
    width: min(1152px, calc(100% - 96px));
    margin-inline: auto;
}

/* Símbolos SVG ocultos; seus desenhos são reutilizados pelos ícones. */
.icon-definitions {
    position: absolute;
    width: 0;
    height: 0;
    overflow: hidden;
}

/* Tamanho e traçado padrão dos ícones. */
.icon {
    width: 20px;
    height: 20px;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.6;
    stroke-linecap: round;
    stroke-linejoin: round;
    flex-shrink: 0;
}

/* Atalho acessível para pular o cabeçalho. */
.skip-link {
    position: fixed;
    top: -100px;
    left: 20px;
    z-index: 100;
    padding: 15px;
    background: var(--accent);
    color: var(--background);
}

.skip-link:focus {
    top: 15px;
}

/* Cabeçalho e navegação principal. */
.header {
    position: sticky;
    top: 0;
    z-index: 20;
    background: var(--background);
    border-bottom: 1px solid var(--border);
}

.header-inner {
    height: 96px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 30px;
}

.brand {
    width: 234px;
    flex-shrink: 0;
}

.brand img {
    width: 100%;
    height: auto;
    mix-blend-mode: screen;
}

nav {
    display: flex;
    align-items: center;
    gap: 32px;
    font-size: 13px;
    font-weight: 600;
    color: #c8cdd6;
}

nav a:hover, .text-link:hover, .project-link:hover, .instagram-link:hover {
    color: var(--accent);
}

.nav-contact {
    display: flex;
    gap: 13px;
    align-items: center;
}

.menu-toggle {
    display: none;
}

/* Organização da apresentação em texto e fotografia. */
.hero {
    padding-block: 76px 86px;
    display: grid;
    grid-template-columns: 1.6fr 1fr;
    gap: 80px;
    align-items: center;
}

/* Pequenas legendas acima dos títulos. */
.eyebrow {
    color: var(--muted);
    font: 10px/1.7 var(--font-mono);
    letter-spacing: 1.5px;
    margin: 0 0 22px;
}

.small-line {
    display: none;
}

h1 {
    font-size: clamp(42px, 4.5vw, 64px);
    line-height: 1.12;
    font-weight: 700;
    letter-spacing: -2.5px;
    margin: 0 0 20px;
}

.hero-role {
    font-size: clamp(20px, 2vw, 27px);
    color: #d2d9e5;
    line-height: 1.5;
    margin: 0 0 21px;
    letter-spacing: -.5px;
}

.hero-description {
    max-width: 470px;
    color: var(--muted);
    font-size: 15px;
    line-height: 1.9;
    margin: 0;
}

.hero-actions {
    display: flex;
    align-items: center;
    gap: 29px;
    margin-top: 32px;
}

/* Estilo compartilhado pelos botões em forma de link. */
.button {
    min-height: 50px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 20px;
    padding: 15px 22px;
    border: 1px solid transparent;
    border-radius: 3px;
    font-size: 12px;
    font-weight: 700;
}

.button-primary {
    background: #e5ebf5;
    color: #152031;
}

.button-primary:hover {
    background: #bed3f5;
}

.text-link {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    font-size: 12px;
    font-weight: 600;
}

/* Especialidades exibidas abaixo dos botões da apresentação. */
.specialties {
    display: flex;
    flex-wrap: wrap;
    gap: 24px;
    margin-top: 38px;
    color: var(--muted);
    font-size: 10px;
}

.specialties span {
    display: flex;
    gap: 9px;
    align-items: center;
}

.portrait {
    margin: 0;
}

.portrait img {
    width: 100%;
    height: 390px;
    object-fit: cover;
    object-position: center 29%;
    border-radius: 3px;
}

/* Espaçamento e separadores entre seções. */
.section {
    padding-block: 78px;
    border-top: 1px solid var(--border);
}

.section-top {
    display: flex;
    align-items: end;
    justify-content: space-between;
    gap: 35px;
}

h2 {
    font-size: clamp(29px, 3vw, 37px);
    font-weight: 600;
    letter-spacing: -1.2px;
    line-height: 1.3;
    margin: 0;
}

.section-top > p {
    max-width: 340px;
    color: var(--muted);
    font-size: 13px;
    line-height: 1.8;
    margin: 0;
}

/* Grade dos dois projetos em destaque. */
.project-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 40px;
    margin-top: 36px;
}

/* Área de exibição das capturas dos projetos. */
.project-visual {
    height: 310px;
    display: flex;
    justify-content: center;
    overflow: hidden;
    border: 1px solid #414751;
    border-radius: 3px;
}

.neovital-visual {
    background: #252a30;
}

.neovital-visual img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: top;
}

.terra-visual {
    padding: 20px;
    background: #f0eddf;
}

.terra-visual img {
    height: 100%;
    width: auto;
    object-fit: contain;
}

.project-heading {
    margin-top: 25px;
}

h3 {
    margin: 0;
    font-size: 22px;
    font-weight: 600;
    letter-spacing: -.5px;
}

.project > p {
    color: var(--muted);
    font-size: 13px;
    line-height: 1.9;
    margin-top: 14px;
}

/* Lista de características de cada projeto. */
.project-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    margin-top: 20px;
}

.project-tags span {
    font: 10px/1.7 var(--font-mono);
    color: #c1c9d7;
}

.project-link {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    margin-top: 22px;
    font-size: 12px;
    font-weight: 700;
    color: var(--accent);
}

.project > .project-credit {
    font-size: 10px;
    margin-top: 14px;
}










/* Grade responsiva das tecnologias e seus logos. */
.stack-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 0;
    list-style: none;
    padding: 0;
    margin: 38px 0 0;
    border-top: 1px solid var(--border);
    border-left: 1px solid var(--border);
}

.stack-item {
    display: grid;
    grid-template-columns: 42px 1fr;
    column-gap: 19px;
    align-items: center;
    padding: 30px 24px;
    border-right: 1px solid var(--border);
    border-bottom: 1px solid var(--border);
}

.stack-item img {
    grid-row: span 2;
    width: 42px;
    height: 42px;
    object-fit: contain;
}

.stack-item h3 {
    font-size: 14px;
    letter-spacing: 0;
    line-height: 1.5;
}

.stack-item span {
    font-size: 10px;
    color: var(--muted);
    margin-top: 3px;
}

/* Bloco de contato e seus links externos. */
.contact {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 50px;
}

.contact p:not(.eyebrow) {
    color: var(--muted);
    font-size: 14px;
    line-height: 1.9;
    margin-top: 20px;
}

.contact-links {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 24px;
}

.instagram-link {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 12px;
    color: #c3cad6;
}

/* Rodapé da página. */
.footer {
    display: flex;
    justify-content: space-between;
    gap: 25px;
    border-top: 1px solid var(--border);
    padding-block: 30px;
    color: var(--muted);
    font-size: 10px;
}

.footer a span {
    margin-left: 10px;
}

/* Tablets e telas intermediárias: ajusta grades, navegação e margens. */
@media (max-width: 1100px) {
    .container {
        width: calc(100% - 64px);
    }

    .hero {
        gap: 50px;
    }

    .portrait img {
        height: 350px;
    }

    .stack-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

}

/* Celulares: menu compacto, conteúdo em coluna e ajustes de espaçamento. */
@media (max-width: 760px) {
    html {
        scroll-padding-top: 100px;
    }

    .container {
        width: calc(100% - 40px);
    }

    .header-inner {
        height: 80px;
    }

    .brand {
        width: 205px;
    }

    .menu-toggle {
        display: flex;
        flex-direction: column;
        justify-content: center;
        gap: 6px;
        width: 42px;
        height: 42px;
        background: none;
        color: var(--text);
        border: 1px solid var(--border);
        border-radius: 3px;
        padding: 10px;
        cursor: pointer;
    }

    .menu-toggle span {
        width: 20px;
        height: 1px;
        background: currentColor;
    }

    nav {
        display: none;
        position: absolute;
        top: 80px;
        left: 0;
        width: 100%;
        background: var(--surface);
        border-bottom: 1px solid var(--border);
        padding: 15px 20px;
        align-items: stretch;
        gap: 0;
    }

    nav.is-open {
        display: flex;
        flex-direction: column;
    }

    nav a {
        padding: 16px 0;
    }

    .hero {
        padding-block: 48px;
        grid-template-columns: 1fr;
        gap: 35px;
    }

    h1 {
        font-size: clamp(37px, 7.5vw, 55px);
        letter-spacing: -1.5px;
    }

    .hero-role {
        font-size: 21px;
    }

    .hero-description {
        font-size: 14px;
    }

    .hero-actions {
        gap: 25px;
    }

    .specialties {
        gap: 17px;
        margin-top: 29px;
    }

    .portrait {
        max-width: 400px;
    }

    .portrait img {
        height: 340px;
    }

    .section {
        padding-block: 52px;
    }

    .section-top {
        align-items: start;
        flex-direction: column;
        gap: 18px;
    }

    .project-grid {
        grid-template-columns: 1fr;
        gap: 38px;
        margin-top: 28px;
    }

    .project-visual {
        height: auto;
        aspect-ratio: 1.5;
    }

    .terra-visual {
        height: 320px;
        aspect-ratio: auto;
    }


    .stack-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        margin-top: 28px;
    }

    .stack-item {
        grid-template-columns: 32px 1fr;
        column-gap: 12px;
        padding: 22px 13px;
    }

    .stack-item img {
        width: 32px;
        height: 32px;
    }

    .stack-item h3 {
        font-size: 12px;
    }

    .contact {
        flex-direction: column;
        align-items: start;
        gap: 22px;
    }

    .contact-links {
        align-items: start;
    }

    .footer {
        flex-wrap: wrap;
        line-height: 1.7;
    }

    .footer > span:nth-child(2) {
        display: none;
    }
}

/* Acessibilidade: respeita a preferência por movimento reduzido. */
@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }
}

/* Grade dos cursos e certificados selecionados. */
.certificate-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    column-gap: 42px;
    margin-top: 35px;
}

.certificate {
    display: flex;
    flex-direction: column;
    padding: 27px 0;
    border-top: 1px solid var(--border);
}

.certificate-provider {
    display: flex;
    justify-content: space-between;
    margin: 0 0 15px;
    font: 11px var(--font-mono);
    color: var(--accent);
}

.certificate-provider span {
    color: var(--muted);
}

.certificate h3 {
    font-size: 17px;
    line-height: 1.65;
    letter-spacing: -.2px;
}

.certificate-instructor {
    margin: 12px 0 22px;
    font-size: 11px;
    line-height: 1.8;
    color: var(--muted);
}

/* Data de conclusão e link para abrir o certificado. */
.certificate-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 15px;
    margin-top: auto;
    font-size: 11px;
}

.certificate-footer time {
    color: var(--muted);
    font-family: var(--font-mono);
    font-size: 10px;
}

.certificate-footer a {
    display: inline-flex;
    align-items: center;
    gap: 9px;
}

.certificate-footer a:hover {
    color: var(--accent);
}

.certificate-footer .icon {
    width: 17px;
    height: 17px;
}

/* Tablets e telas intermediárias: ajusta grades, navegação e margens. */
@media (min-width: 761px) and (max-width: 1000px) {
    nav {
        gap: 20px;
        font-size: 12px;
    }

    .brand {
        width: 205px;
    }
}

/* Celulares: menu compacto, conteúdo em coluna e ajustes de espaçamento. */
@media (max-width: 760px) {
    .certificate-grid {
        grid-template-columns: 1fr;
        margin-top: 27px;
    }

    .certificate h3 {
        font-size: 16px;
    }
}

/* Foto circular e enquadramento das capturas dos projetos. */
.portrait {
    width: min(100%, 350px);
    aspect-ratio: 1;
    padding: 9px;
    border: 1px solid #52637e;
    border-radius: 50%;
    justify-self: center;
}

.portrait img {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    object-position: center 27%;
}

.terra-visual {
    padding: 0;
    background: #f3eddf;
}

.terra-visual img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: top;
}

/* Interações: navegação ativa, respostas ao mouse e animações de entrada. */
html {
    scroll-behavior: smooth;
}

nav a {
    position: relative;
    transition: color 180ms ease;
}

nav a::after {
    content: '';
    position: absolute;
    left: 0;
    right: 0;
    bottom: -10px;
    height: 1px;
    background: var(--accent);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 200ms ease;
}

nav a:hover::after, nav a.is-current::after {
    transform: scaleX(1);
}

nav a.is-current {
    color: var(--accent);
}

.button, .project-visual, .stack-item, .certificate {
    transition: background-color 200ms ease, border-color 200ms ease, transform 200ms ease;
}

.button .icon, .text-link .icon, .project-link .icon, .certificate-footer .icon {
    transition: transform 200ms ease;
}

.button:hover .icon, .text-link:hover .icon, .project-link:hover .icon, .certificate-footer a:hover .icon {
    transform: translateX(3px);
}

.project-visual:hover {
    border-color: var(--accent);
}

.stack-item:hover {
    background: #1c222d;
}

.certificate:hover {
    border-top-color: #8599b8;
}

/* Estado inicial dos elementos ainda fora da tela; aplicado apenas por JavaScript. */
.reveal-pending {
    opacity: 0;
    transform: translateY(18px);
}

/* Estado final após o elemento aparecer na área visível. */
.reveal-visible {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 600ms ease, transform 600ms ease;
}

.hero-copy {
    animation: introduction 650ms ease both;
}

.portrait {
    animation: introduction 850ms ease both;
}

/* Animação de entrada do texto e da foto na abertura. */
@keyframes introduction {
    from {
        opacity: 0;
        transform: translateY(14px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Botão flutuante do WhatsApp: posição, cores, legenda e pulsação. */
.whatsapp-float {
    position: fixed;
    right: max(26px, env(safe-area-inset-right));
    bottom: max(26px, env(safe-area-inset-bottom));
    z-index: 30;
    display: grid;
    place-items: center;
    width: 58px;
    height: 58px;
    border: 1px solid #68e49b;
    border-radius: 50%;
    background: #25d366;
    color: #082c16;
    box-shadow: 0 5px 20px #0005;
    animation: contact-pulse 2300ms ease 3;
    transition: background-color 180ms ease, transform 180ms ease;
}

.whatsapp-float > .icon {
    width: 29px;
    height: 29px;
    stroke-width: 1.7;
}

.whatsapp-float:hover, .whatsapp-float:focus-visible {
    background: #54e58b;
    transform: translateY(-3px);
}

.whatsapp-tooltip {
    position: absolute;
    right: 72px;
    padding: 11px 14px;
    border: 1px solid var(--border);
    border-radius: 4px;
    background: #20262f;
    color: var(--text);
    font-size: 11px;
    white-space: nowrap;
    opacity: 0;
    visibility: hidden;
    transition: opacity 180ms ease;
}

.whatsapp-float:hover .whatsapp-tooltip, .whatsapp-float:focus-visible .whatsapp-tooltip {
    opacity: 1;
    visibility: visible;
}

/* Pulsação limitada a três ciclos para destacar o contato. */
@keyframes contact-pulse {
    0%, 100% {
        box-shadow: 0 5px 20px #0005, 0 0 0 0 #25d34400;
    }

    40% {
        box-shadow: 0 5px 20px #0005, 0 0 0 9px #25d34422;
    }
}

/* Celulares: menu compacto, conteúdo em coluna e ajustes de espaçamento. */
@media (max-width: 760px) {
    .portrait {
        width: min(280px, 88%);
    }

    .portrait img {
        height: 100%;
    }

    .terra-visual {
        height: auto;
        aspect-ratio: 1.5;
    }

    nav a::after {
        bottom: 8px;
        right: auto;
        width: 32px;
    }

    .whatsapp-float {
        right: max(18px, env(safe-area-inset-right));
        bottom: max(18px, env(safe-area-inset-bottom));
        width: 52px;
        height: 52px;
    }

    .footer {
        padding-bottom: 92px;
    }
}

/* Acessibilidade: respeita a preferência por movimento reduzido. */
@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }

    *, *::before, *::after {
        animation: none !important;
        transition: none !important;
    }

    .reveal-pending {
        opacity: 1;
        transform: none;
    }
}
