/* ============================================================
   BASE — reset, tipografia global, acessibilidade
   ============================================================ */

*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
    -webkit-text-size-adjust: 100%;
}

body {
    font-family: var(--font-data);
    font-size: var(--text-md);
    line-height: 1.6;
    color: var(--text-1);
    background-color: var(--bg);
    min-height: 100vh;
    -webkit-font-smoothing: antialiased;
}

/* Luz ambiente — estática e barata (sem animação contínua) */
.ambient {
    position: fixed;
    inset: 0;
    z-index: -1;
    pointer-events: none;
    background:
        radial-gradient(ellipse 70% 55% at 8% 0%, rgba(196, 146, 154, 0.10) 0%, transparent 60%),
        radial-gradient(ellipse 55% 45% at 95% 100%, rgba(196, 168, 130, 0.08) 0%, transparent 55%);
}

/* ── Tipografia ── */
h1, h2, h3, h4 {
    font-family: var(--font-sans);
    font-weight: 600;
    line-height: 1.25;
    color: var(--text-1);
    text-wrap: balance;
}

/* Títulos display — o serif entra aqui, com ênfase em itálico */
.display {
    font-family: var(--font-display);
    font-weight: 300;
    letter-spacing: -0.01em;
    line-height: 1.15;
}

.display em {
    font-style: italic;
    font-weight: 600;
    background: var(--gradient-text);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    color: var(--accent); /* fallback */
}

.display--lg { font-size: var(--display-lg); }
.display--md { font-size: var(--display-md); }
.display--sm { font-size: var(--display-sm); }

/* Eyebrow — rótulo uppercase que antecede títulos */
.eyebrow {
    display: block;
    font-family: var(--font-sans);
    font-size: var(--eyebrow-size);
    font-weight: 600;
    letter-spacing: var(--eyebrow-tracking);
    text-transform: uppercase;
    color: var(--accent-2);
    margin-bottom: var(--space-3);
}

p { color: var(--text-2); }

a {
    color: var(--accent);
    text-decoration: none;
    transition: color var(--dur-1) var(--ease-out);
}

a:hover { color: var(--brand-accent-200); }

small { font-size: var(--text-sm); color: var(--text-3); }

::selection {
    background: rgba(196, 168, 130, 0.30);
    color: var(--text-1);
}

/* ── Foco visível (navegação por teclado) ── */
:focus {
    outline: none;
}

:focus-visible {
    outline: none;
    box-shadow: var(--focus-ring);
    border-radius: var(--radius-sm);
}

/* ── Linha de luz — divisor assinatura ── */
.light-line {
    border: 0;
    height: 1px;
    width: 100%;
    background: var(--light-line);
}

/* ── Scrollbar discreta ── */
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb {
    background: rgba(196, 168, 130, 0.18);
    border-radius: var(--radius-pill);
    border: 2px solid var(--bg);
}
::-webkit-scrollbar-thumb:hover { background: rgba(196, 168, 130, 0.32); }

/* ── Acessibilidade ── */
.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
    white-space: nowrap;
    border: 0;
}

.skip-link {
    position: absolute;
    top: -100%;
    left: var(--space-4);
    z-index: 100;
    padding: var(--space-2) var(--space-4);
    background: var(--surface-solid);
    border: 1px solid var(--border-2);
    border-radius: var(--radius-sm);
    color: var(--text-1);
    font-size: var(--text-sm);
}

.skip-link:focus-visible {
    top: var(--space-4);
}

/* Movimento reduzido: desliga transições e reveals */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
}

/* ── Reveal on scroll (aplicado via JS; inofensivo sem JS) ── */
.reveal {
    opacity: 1;
    transform: none;
}

.js .reveal {
    opacity: 0;
    transform: translateY(16px);
    transition: opacity var(--dur-3) var(--ease-out), transform var(--dur-3) var(--ease-out);
}

.js .reveal.is-visible {
    opacity: 1;
    transform: none;
}
