/* ==========================================================
   GENESYS — camada por cima do theme.css do NinjaHost
   Adiciona: fonte chinesa (CJK), modo escuro e ajustes finos.
   ========================================================== */

/* Montserrat auto-hospedada, registrada com o mesmo nome interno da Rivify. */
@font-face {
    font-family: "Rivify";
    font-style: normal;
    font-weight: 100 900;
    font-display: swap;
    src: url("../assets/fonts/rivify-variable.ttf?v=1") format("truetype-variations");
}

:root {
    color-scheme: dark;
    --font-display: "Rivify", system-ui, -apple-system, "Segoe UI", sans-serif;
    --font-body:    "Rivify", system-ui, -apple-system, "Segoe UI", sans-serif;
    --font-brand:   "Rivify", system-ui, -apple-system, "Segoe UI", sans-serif;

    /* Paleta Rivify aplicada à Genesys. */
    --bg:            #f4f6f8;
    --bg-2:          #ffffff;
    --bg-card:       rgba(255, 255, 255, .94);
    --bg-card-hover: #f8fafb;
    --bg-elevated:   #ffffff;
    --red:           #0e6fff;
    --red-bright:    #0e6fff;
    --red-dark:      #0959cc;
    --red-glow:      rgba(14, 111, 255, .34);
    --red-soft:      #edf5ff;
    --red-border:    #bfd8ff;
    --text:          #464d51;
    --text-2:        #566267;
    --text-3:        #707a7e;
    --border:        #d8dee5;
    --border-strong: #a9b3be;
    --shadow-sm:     0 8px 24px -18px rgba(31, 41, 51, .18);
    --shadow-md:     0 18px 44px -28px rgba(31, 41, 51, .24);
    --shadow-lg:     0 30px 70px -28px rgba(9, 89, 204, .28);
    --shadow-red:    0 16px 38px -14px rgba(14, 111, 255, .42);
    --shadow-btn:    0 12px 34px -14px rgba(14, 111, 255, .45);
    --gs-scroll: 0;
    --gs-pointer-x: 0;
    --gs-pointer-y: 0;

    /* Superfície dos cards (mesmo tratamento da seção de shaders) */
    --surface-sheen: rgba(255, 255, 255, .75);
    --surface-shine: rgba(14, 111, 255, .07);
    --surface-edge:  rgba(14, 111, 255, .42);
    --surface-lift:  0 22px 48px -26px rgba(9, 60, 140, .42), 0 0 26px -8px rgba(14, 111, 255, .28);
}

/* ===== Modo escuro ===== */
[data-theme="dark"] {
    --bg:            #08111f;
    --bg-2:          #0c1828;
    --bg-card:       rgba(13, 27, 45, .94);
    --bg-card-hover: #12243a;
    --bg-elevated:   #12243a;

    --text:          #f4f8fc;
    --text-2:        #c8d6e5;
    --text-3:        #8fa3b8;

    --border:        rgba(255, 255, 255, 0.08);
    --border-strong: rgba(255, 255, 255, 0.14);

    --shadow-sm: 0 2px 8px rgba(0,0,0,0.4);
    --shadow-md: 0 10px 32px rgba(0,0,0,0.5);
    --shadow-lg: 0 24px 60px rgba(0,0,0,0.6);
    --shadow-btn: 0 2px 8px rgba(0,0,0,0.4);

    --surface-sheen: rgba(255, 255, 255, .05);
    --surface-shine: rgba(69, 163, 255, .09);
    --surface-edge:  rgba(69, 163, 255, .55);
    --surface-lift:  0 22px 48px rgba(0, 0, 0, .32), 0 0 28px rgba(23, 132, 255, .12);
}
[data-theme="dark"] html { scrollbar-color: var(--red) #1a1a20; }
[data-theme="dark"] html::-webkit-scrollbar-track { background: #1a1a20; }

/* Âncoras: compensa a navbar fixa ao rolar pras seções */
section[id] { scroll-margin-top: 88px; }

/* ===== Páginas legais (Termos, Privacidade, Reembolso) ===== */
.gs-legal { padding: clamp(3rem, 7vw, 5rem) 1.5rem; }
.gs-legal__inner { max-width: 820px; margin: 0 auto; }
.gs-legal__title { font-family: var(--font-brand); font-weight: 700; font-size: clamp(1.8rem, 4vw, 2.6rem); color: var(--text); margin: 0.5rem 0 0; }
.gs-legal__updated { margin: 0.75rem 0 0; font-size: 0.85rem; color: var(--text-3); }
.gs-legal__company { margin-top: 1.25rem; padding: 1rem 1.1rem; border: 1px solid var(--border); border-radius: 12px; background: var(--bg-card); color: var(--text-2); font-size: .9rem; line-height: 1.6; }
.gs-legal__company p { margin: 0; }
.gs-legal__company a { color: var(--red-bright); text-decoration: none; }
.gs-legal__ip-notice { margin-top: 1rem; padding: 1.15rem 1.2rem; border: 1px solid rgba(246,185,59,.48); border-left: 4px solid #f6b93b; border-radius: 12px; background: rgba(246,185,59,.08); color: var(--text-2); font-size: .88rem; line-height: 1.65; }
.gs-legal__ip-notice strong:first-child { display: block; margin-bottom: .35rem; color: #f6c453; font-size: .78rem; letter-spacing: .06em; text-transform: uppercase; }
.gs-legal__ip-notice p { margin: 0; }
.gs-legal__body { margin-top: 2rem; color: var(--text-2); line-height: 1.7; font-size: 0.95rem; }
.gs-legal__body h3 { font-family: var(--font-brand); font-size: 1.1rem; color: var(--text); margin: 2rem 0 0.75rem; }
.gs-legal__body p { margin: 0 0 1rem; }
.gs-legal__body ul { margin: 0 0 1rem; padding-left: 1.25rem; list-style: disc; }
.gs-legal__body li { margin: 0.35rem 0; }
.gs-legal__body a { color: var(--red-bright); overflow-wrap: anywhere; word-break: break-word; }
.gs-legal__body strong { color: var(--text); }
.gs-legal__nav { margin-top: 2.5rem; padding-top: 1.5rem; border-top: 1px solid var(--border); font-size: 0.85rem; color: var(--text-3); }
.gs-legal__nav a { color: var(--red-bright); text-decoration: none; }
.gs-legal__nav a:hover { text-decoration: underline; }

/* Deixa a transição de tema suave */
body, .nh-card, .site-nav, .site-footer {
    transition: background-color 0.25s ease, border-color 0.25s ease, color 0.25s ease;
}

/* ===== Identidade Rivify + movimento ambiental ===== */
body {
    letter-spacing: .006em;
    line-height: 1.5;
}

button, input, select, textarea { font-family: inherit; }
strong, b { font-weight: 650; }
h1, h2, h3, h4, h5, h6 { letter-spacing: 0 !important; }

.nh-bg::before {
    background:
        linear-gradient(180deg, rgba(3,9,18,.68), rgba(5,13,25,.82) 44%, rgba(4,11,21,.88)),
        radial-gradient(ellipse 62% 50% at 50% 34%, transparent 0%, rgba(3,9,18,.38) 72%),
        url('/assets/img/art/genesys-parallax.webp') center / cover no-repeat,
        #08111f;
    inset: -110px -45px;
    transform: translate3d(0, var(--gs-scene-y, 0px), 0) scale(1.055);
    transform-origin: center center;
    filter: saturate(.82) contrast(1.06);
    will-change: transform;
}
[data-theme="dark"] .nh-bg::before {
    background:
        linear-gradient(180deg, rgba(3,9,18,.68), rgba(5,13,25,.82) 44%, rgba(4,11,21,.88)),
        radial-gradient(ellipse 62% 50% at 50% 34%, transparent 0%, rgba(3,9,18,.38) 72%),
        url('/assets/img/art/genesys-parallax.webp') center / cover no-repeat,
        #08111f;
    filter: saturate(.82) contrast(1.06);
}

.nh-grid {
    background-image:
        linear-gradient(rgba(14,111,255,.045) 1px, transparent 1px),
        linear-gradient(90deg, rgba(14,111,255,.045) 1px, transparent 1px);
    mask-image: radial-gradient(ellipse 75% 62% at 50% 38%, black 6%, transparent 78%);
}

.gs-ambient { position: fixed; inset: 0; z-index: 1; pointer-events: none; overflow: hidden; }
.gs-ambient span { position: absolute; width: 5px; height: 5px; border-radius: 50%; background: #45a3ff; box-shadow: 0 0 18px 5px rgba(69,163,255,.3); opacity: .32; animation: gs-drift 12s ease-in-out infinite alternate; }
.gs-ambient span:nth-child(1) { left: 12%; top: 22%; }
.gs-ambient span:nth-child(2) { right: 18%; top: 46%; width: 3px; height: 3px; animation-delay: -4s; animation-duration: 15s; }
.gs-ambient span:nth-child(3) { left: 36%; bottom: 18%; width: 4px; height: 4px; animation-delay: -8s; animation-duration: 18s; }
@keyframes gs-drift { to { transform: translate3d(28px, -42px, 0) scale(1.35); opacity: .7; } }

.btn {
    min-height: 46px;
    padding: .76rem 1.45rem;
    border-radius: 999px;
    font-weight: 650;
    letter-spacing: .01em;
}
.btn-primary { background: #0e6fff; box-shadow: var(--shadow-btn); }
.btn-primary:hover { background: #0959cc; transform: translateY(-2px); box-shadow: 0 16px 38px -12px rgba(14,111,255,.55); }
.btn-ghost { border: 1.5px solid var(--border-strong); background: rgba(255,255,255,.82); color: var(--text); }
.btn-ghost:hover { border-color: #0e6fff; color: #0e6fff; background: #fff; transform: translateY(-2px); }
[data-theme="dark"] .btn-ghost { background: rgba(12,24,40,.76); }

.nh-eyebrow {
    gap: .7rem;
    padding: 0;
    border: 0;
    border-radius: 0;
    background: none;
    color: #0e6fff;
    font-size: .73rem;
    letter-spacing: .18em;
}
.nh-eyebrow::before { width: 26px; height: 2px; border-radius: 2px; background: currentColor; opacity: 1; }
.nh-eyebrow::after { display: none; }
[data-theme="dark"] .nh-eyebrow { color: #4aa3ff; }

.nh-card, .gs-topic, .gs-plan, .gs-cta__inner, .gs-choice__card {
    position: relative;
    isolation: isolate;
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    box-shadow: inset 0 1px 0 var(--surface-sheen), var(--shadow-sm);
    transition: transform .28s ease, border-color .28s ease, box-shadow .28s ease, background .28s ease;
}

/* Reflexo que percorre o card no hover, igual ao dos cards de shader. */
.nh-card::after, .gs-topic::after, .gs-plan::after, .gs-choice__card::after {
    content: "";
    position: absolute;
    z-index: -1;
    inset: 0;
    border-radius: inherit;
    pointer-events: none;
    background: linear-gradient(125deg, transparent 25%, var(--surface-shine) 50%, transparent 75%);
    transform: translateX(-100%);
    transition: transform .65s ease;
}
.nh-card:hover::after, .gs-topic:hover::after, .gs-plan:hover::after, .gs-choice__card:hover::after { transform: translateX(100%); }

.nh-card:hover, .gs-topic:hover, .gs-plan:hover, .gs-choice__card:hover {
    transform: translateY(-6px);
    border-color: var(--surface-edge);
    box-shadow: inset 0 1px 0 var(--surface-sheen), var(--surface-lift);
}

.gs-nav { box-shadow: 0 10px 30px -24px rgba(9,89,204,.35); }
.gs-nav__links a { border-radius: 999px; padding: .5rem .65rem; }
.gs-nav__links a:hover { background: rgba(14,111,255,.06); }

.gs-motion-ready .nh-section,
.gs-motion-ready .gs-choice,
.gs-motion-ready .gs-cta { opacity: 0; transform: translateY(22px); transition: opacity .7s ease, transform .7s ease; }
.gs-motion-ready .nh-section.is-visible,
.gs-motion-ready .gs-choice.is-visible,
.gs-motion-ready .gs-cta.is-visible { opacity: 1; transform: translateY(0); }

@media (prefers-reduced-motion: reduce) {
    .gs-ambient span { animation: none; }
    .nh-bg::before { transform: scale(1.055); }
    .gs-motion-ready .nh-section, .gs-motion-ready .gs-choice, .gs-motion-ready .gs-cta { opacity: 1; transform: none; transition: none; }
}

/* ===== Bloco de anúncio (AdSense) — discreto; colapsa quando não há anúncio ===== */
.gs-ad { max-width: 970px; margin: 0 auto; padding: 0 1.5rem; text-align: center; }
.gs-ad__label { display: none; font-family: var(--font-brand); font-size: 0.62rem; font-weight: 700; letter-spacing: 0.14em; text-transform: uppercase; color: var(--text-3); margin-bottom: 0.5rem; }
.gs-ad ins.adsbygoogle { display: block; }
/* Só mostra o rótulo quando o anúncio realmente carrega; some se vier vazio */
.gs-ad:has(ins[data-ad-status="filled"]) .gs-ad__label { display: block; }
.gs-ad ins[data-ad-status="unfilled"] { display: none !important; }
