/* ============================================================
   HOME NOVO — design moderno isolado (prefixo .hn-)
   Paleta do projeto: magenta / cyan / amber / green
   Sem dependência de app.css ou public.css
   ============================================================ */

.hn-body {
    /* Paleta do projeto (idêntica a tokens.css) */
    --hn-magenta:    #E5326E;
    --hn-magenta-d:  #C71E5C;
    --hn-magenta-50: #FFF1F6;
    --hn-cyan:       #14B8C9;
    --hn-cyan-d:     #0E94A2;
    --hn-cyan-50:    #ECFBFD;
    --hn-amber:      #D97706;
    --hn-amber-50:   #FEF3C7;
    --hn-green:      #16A34A;
    --hn-green-50:   #DCFCE7;

    --hn-ink:    #0F172A;
    --hn-ink-2:  #1E293B;
    --hn-text:   #334155;
    --hn-muted:  #64748B;
    --hn-line:   #E2E8F0;
    --hn-line-2: #F1F5F9;
    --hn-bg:     #FAFAFB;
    --hn-card:   #FFFFFF;
    --hn-elev-1: 0 1px 2px rgba(15,23,42,.04);
    --hn-elev-2: 0 4px 16px rgba(15,23,42,.08);
    --hn-elev-3: 0 24px 60px rgba(15,23,42,.10);

    --hn-radius:    14px;
    --hn-radius-sm: 10px;
    --hn-radius-lg: 22px;

    --hn-fonte: 16px;

    margin: 0; padding: 0;
    background: var(--hn-bg);
    color: var(--hn-text);
    font-family: ui-sans-serif, -apple-system, BlinkMacSystemFont, "Inter", "Segoe UI", Roboto, sans-serif;
    font-size: var(--hn-fonte);
    line-height: 1.55;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    text-rendering: optimizeLegibility;
}

/* Tamanho de fonte (A-/A/A+) — escala 80-140% em steps de 10%, eMAG/WCAG.
   Usa zoom pra escalar TUDO (texto, ícones, espaçamentos) sem precisar
   reescrever todos os px do CSS. */
html[data-fonte="80"]  .hn-body { zoom: 0.80; }
html[data-fonte="90"]  .hn-body { zoom: 0.90; }
html[data-fonte="100"] .hn-body { zoom: 1.00; }
html[data-fonte="110"] .hn-body { zoom: 1.10; }
html[data-fonte="120"] .hn-body { zoom: 1.20; }
html[data-fonte="130"] .hn-body { zoom: 1.30; }
html[data-fonte="140"] .hn-body { zoom: 1.40; }

/* ===== Tema escuro ===== */
html[data-tema="escuro"] .hn-body {
    --hn-ink:    #F8FAFC;
    --hn-ink-2:  #E2E8F0;
    --hn-text:   #CBD5E1;
    --hn-muted:  #94A3B8;
    --hn-line:   #1E293B;
    --hn-line-2: #0F172A;
    --hn-bg:     #0B1120;
    --hn-card:   #111827;
    --hn-magenta-50: rgba(229,50,110,.10);
    --hn-cyan-50:    rgba(20,184,201,.10);
    --hn-amber-50:   rgba(217,119,6,.10);
    --hn-green-50:   rgba(22,163,74,.10);
    --hn-elev-1: 0 1px 2px rgba(0,0,0,.40);
    --hn-elev-2: 0 4px 16px rgba(0,0,0,.40);
    --hn-elev-3: 0 24px 60px rgba(0,0,0,.50);
}

* { box-sizing: border-box; }

.hn-body :is(h1,h2,h3,h4,h5,h6) {
    margin: 0;
    color: var(--hn-ink);
    font-weight: 700;
    line-height: 1.2;
    letter-spacing: -.02em;
}
.hn-body p { margin: 0; }
.hn-body a { color: inherit; text-decoration: none; transition: color .15s; }
.hn-body img { max-width: 100%; display: block; }
/* :where() zera a especificidade — assim .hn-tile etc podem ter background próprio */
.hn-body :where(button) { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; padding: 0; }
.hn-body ul, .hn-body ol { margin: 0; padding: 0; list-style: none; }

.hn-body :focus-visible {
    outline: 3px solid var(--hn-magenta);
    outline-offset: 3px;
    border-radius: 6px;
}

.hn-shell {
    max-width: 1240px;
    margin: 0 auto;
    padding: 0 24px;
}

.hn-sr {
    position: absolute !important; width: 1px !important; height: 1px !important;
    padding: 0 !important; overflow: hidden !important;
    clip: rect(0,0,0,0) !important; white-space: nowrap !important; border: 0 !important;
}

.hn-skip {
    position: absolute; top: -42px; left: 8px;
    background: var(--hn-ink); color: #fff;
    padding: 10px 16px;
    font-weight: 700; font-size: 13px;
    border-radius: 0 0 8px 8px;
    z-index: 9999;
    transition: top .2s;
}
.hn-skip:focus { top: 0; }

.hn-eyebrow {
    display: inline-block;
    margin-bottom: 6px;
    color: var(--hn-magenta);
    font-size: 11px; font-weight: 700;
    text-transform: uppercase; letter-spacing: .12em;
}

/* ============================================================
   TOPBAR (a11y)
   ============================================================ */
.hn-topbar {
    /* Sempre escuro — independente do tema (claro ou escuro) — pra garantir
       contraste visual com o header branco. No alto contraste, é sobrescrito
       lá embaixo nas regras data-contraste="alto". */
    background: #0F172A;
    color: #cbd5e1;
    font-size: 12.5px;
    border-bottom: 1px solid rgba(255,255,255,.06);
}
.hn-topbar-inner {
    display: flex; align-items: center; justify-content: space-between;
    height: 40px; gap: 16px;
}
.hn-topbar-link {
    display: inline-flex; align-items: center; gap: 8px;
    padding: 4px 10px;
    color: #cbd5e1; opacity: .9;
    font-weight: 600;
    background: rgba(255,255,255,.04);
    border: 1px solid rgba(255,255,255,.12);
    border-radius: 999px;
    transition: background .15s, color .15s, border-color .15s;
}
.hn-topbar-link:hover {
    opacity: 1; color: #fff;
    background: var(--hn-magenta);
    border-color: var(--hn-magenta);
}
.hn-acessos-badge {
    display: inline-flex; align-items: center; justify-content: center;
    min-width: 26px;
    padding: 1px 7px;
    background: var(--hn-magenta);
    color: #fff;
    border-radius: 999px;
    font-size: 10.5px; font-weight: 800;
    font-variant-numeric: tabular-nums;
    line-height: 1.4;
}
.hn-topbar-tools {
    display: flex; align-items: center; gap: 8px;
}
.hn-fonte {
    display: inline-flex;
    border: 1px solid rgba(255,255,255,.15);
    border-radius: 999px;
    overflow: hidden;
}
.hn-fonte button {
    padding: 4px 10px; font-size: 11px; font-weight: 700;
    color: #cbd5e1; opacity: .75;
    border-right: 1px solid rgba(255,255,255,.10);
    transition: background .15s, opacity .15s;
}
.hn-fonte button:last-child { border-right: 0; }
.hn-fonte button:hover { opacity: 1; }
.hn-fonte button[aria-pressed="true"] {
    background: var(--hn-magenta);
    color: #fff; opacity: 1;
}
.hn-tema {
    display: inline-flex; align-items: center; justify-content: center;
    width: 28px; height: 28px;
    color: #cbd5e1;
    border: 1px solid rgba(255,255,255,.15);
    border-radius: 999px;
    transition: background .15s, color .15s;
}
.hn-tema:hover { background: rgba(255,255,255,.10); color: #fff; }
.hn-vlibras,
.hn-hc {
    display: inline-flex; align-items: center; gap: 6px;
    padding: 4px 12px;
    color: #cbd5e1;
    background: transparent;
    border: 1px solid rgba(255,255,255,.15);
    border-radius: 999px;
    font-size: 11px; font-weight: 700;
    transition: background .15s, border-color .15s, color .15s;
}
.hn-vlibras:hover,
.hn-hc:hover {
    background: var(--hn-magenta); color: #fff; border-color: var(--hn-magenta);
}
html[data-contraste="alto"] .hn-hc {
    background: #ffd60a; color: #000; border-color: #ffd60a;
}

/* ============================================================
   HEADER
   ============================================================ */
.hn-header {
    background: var(--hn-card);
    border-bottom: 1px solid var(--hn-line);
    position: relative;
    z-index: 50;
}
.hn-header-inner {
    display: grid;
    grid-template-columns: auto 1fr auto;
    gap: 24px;
    align-items: center;
    padding: 18px 24px;
}
.hn-brand {
    display: inline-flex; align-items: center; gap: 14px;
}
.hn-brand-logo {
    width: 64px; height: 64px;
    object-fit: contain;
    filter: drop-shadow(0 2px 6px rgba(229,50,110,.18));
}
.hn-brand-stack { display: flex; flex-direction: column; line-height: 1.15; }
.hn-brand-pretitle {
    font-size: 11px; font-weight: 600; color: var(--hn-muted);
    letter-spacing: .04em;
}
.hn-brand-titulo {
    font-size: 22px; font-weight: 800; color: var(--hn-ink);
    letter-spacing: -.025em;
}
.hn-brand-subtitle {
    font-size: 12px; font-weight: 700;
    color: var(--hn-magenta);
    letter-spacing: .08em;
    text-transform: uppercase;
}

.hn-search {
    position: relative;
    display: flex; align-items: stretch;
    background: var(--hn-bg);
    border: 1.5px solid var(--hn-line);
    border-radius: 999px;
    transition: border-color .2s, box-shadow .2s;
    max-width: 580px;
    width: 100%;
    justify-self: center;
}
.hn-search:focus-within {
    border-color: var(--hn-magenta);
    box-shadow: 0 0 0 4px rgba(229,50,110,.12);
}
.hn-search-icon {
    display: inline-flex; align-items: center;
    padding-left: 18px;
    color: var(--hn-magenta);
}
.hn-search input {
    flex: 1; min-width: 0;
    border: 0; outline: 0;
    padding: 12px 16px;
    background: transparent;
    font-size: 14px;
    color: var(--hn-ink);
    font-family: inherit;
}
.hn-search input::placeholder { color: var(--hn-muted); }
/* O container .hn-search já dá feedback visual via :focus-within — sem outline duplo no input */
.hn-search input:focus,
.hn-search input:focus-visible { outline: 0; }
.hn-search button[type="submit"] {
    display: inline-flex; align-items: center; gap: 6px;
    padding: 0 20px;
    margin: 4px;
    background: var(--hn-magenta);
    color: #fff;
    border-radius: 999px;
    font-size: 13px; font-weight: 700;
    transition: background .15s;
}
.hn-search button[type="submit"]:hover { background: var(--hn-magenta-d); }
.hn-search-arrow {
    display: inline-flex;
    transition: transform .2s;
}
.hn-search button[type="submit"]:hover .hn-search-arrow { transform: translateX(2px); }

.hn-ac {
    position: absolute;
    top: calc(100% + 8px);
    left: 0; right: 0;
    background: var(--hn-card);
    border: 1px solid var(--hn-line);
    border-radius: var(--hn-radius);
    box-shadow: var(--hn-elev-3);
    max-height: 420px;
    overflow-y: auto;
    z-index: 40;
    display: none;
}
.hn-ac.is-open { display: block; }
.hn-ac-loading,
.hn-ac-empty {
    padding: 18px 20px;
    color: var(--hn-muted);
    font-size: 13.5px;
    text-align: center;
}
.hn-ac-grupo {
    padding: 6px 0;
    border-bottom: 1px solid var(--hn-line-2);
}
.hn-ac-grupo:last-of-type { border-bottom: 0; }
.hn-ac-grupo-titulo {
    padding: 8px 18px 6px;
    font-size: 11px; font-weight: 800;
    color: var(--hn-magenta);
    text-transform: uppercase;
    letter-spacing: .08em;
}
.hn-ac-item {
    display: block;
    padding: 10px 18px;
    color: var(--hn-text);
    transition: background .12s, color .12s;
    border-left: 3px solid transparent;
}
.hn-ac-item:hover,
.hn-ac-item.is-active {
    background: var(--hn-magenta-50);
    border-left-color: var(--hn-magenta);
    color: var(--hn-ink);
}
.hn-ac-item-titulo {
    font-size: 14px; font-weight: 600;
    line-height: 1.3;
    color: var(--hn-ink);
}
.hn-ac-item-titulo mark {
    background: rgba(229,50,110,.15);
    color: var(--hn-magenta-d);
    font-weight: 800;
    padding: 0 2px; border-radius: 3px;
}
.hn-ac-item-meta {
    margin-top: 2px;
    font-size: 11.5px;
    color: var(--hn-muted);
    text-transform: capitalize;
}
.hn-ac-item-badge {
    display: inline-block;
    margin-right: 4px;
    padding: 1px 6px;
    background: var(--hn-cyan-50);
    color: var(--hn-cyan-d);
    border-radius: 999px;
    font-size: 10px; font-weight: 700;
    text-transform: uppercase; letter-spacing: .04em;
    vertical-align: middle;
}
.hn-ac-footer {
    padding: 10px 18px;
    border-top: 1px solid var(--hn-line);
    text-align: center;
}
.hn-ac-footer a {
    color: var(--hn-magenta);
    font-size: 13px; font-weight: 700;
}
.hn-ac-footer a:hover { text-decoration: underline; }

/* Chip fixo: "Procurando servidor? Vai pra Folha de Pagamento" */
.hn-ac-tip {
    display: grid;
    grid-template-columns: auto 1fr auto;
    gap: 12px;
    align-items: center;
    padding: 12px 18px;
    margin: 4px 12px;
    background: linear-gradient(135deg, var(--hn-cyan-50), #fff);
    border: 1px solid var(--hn-cyan);
    border-radius: var(--hn-radius-sm);
    color: var(--hn-ink);
    text-decoration: none;
    transition: transform .15s, box-shadow .15s, border-color .15s;
}
.hn-ac-tip:hover {
    transform: translateY(-1px);
    box-shadow: var(--hn-elev-1);
    border-color: var(--hn-cyan-d);
}
.hn-ac-tip-icon {
    display: inline-flex;
    align-items: center; justify-content: center;
    width: 32px; height: 32px;
    background: var(--hn-cyan);
    color: #fff;
    border-radius: 8px;
    font-size: 16px;
    flex-shrink: 0;
}
.hn-ac-tip-text {
    font-size: 12.5px;
    line-height: 1.4;
    color: var(--hn-text);
}
.hn-ac-tip-text strong {
    display: block;
    color: var(--hn-cyan-d);
    font-size: 13px;
    margin-bottom: 1px;
}
.hn-ac-tip-arrow {
    color: var(--hn-cyan-d);
    font-weight: 800;
    font-size: 16px;
}

/* Quando o termo digitado parece nome — destaca mais ainda */
.hn-ac-tip.hn-ac-tip--destaque {
    background: linear-gradient(135deg, var(--hn-magenta-50), var(--hn-cyan-50));
    border-color: var(--hn-magenta);
    animation: hn-tip-pulse 2.5s ease-in-out infinite;
}
.hn-ac-tip.hn-ac-tip--destaque .hn-ac-tip-icon {
    background: var(--hn-magenta);
}
.hn-ac-tip.hn-ac-tip--destaque .hn-ac-tip-text strong { color: var(--hn-magenta); }
.hn-ac-tip.hn-ac-tip--destaque .hn-ac-tip-arrow { color: var(--hn-magenta); }
@keyframes hn-tip-pulse {
    0%, 100% { box-shadow: 0 0 0 0 rgba(229,50,110,0); }
    50%      { box-shadow: 0 0 0 4px rgba(229,50,110,.10); }
}
@media (prefers-reduced-motion: reduce) {
    .hn-ac-tip.hn-ac-tip--destaque { animation: none !important; }
}

.hn-header-social {
    display: flex; align-items: center; gap: 8px;
}
.hn-header-social a {
    display: inline-flex; align-items: center; justify-content: center;
    width: 36px; height: 36px;
    background: var(--hn-magenta-50);
    color: var(--hn-magenta);
    border-radius: 999px;
    transition: background .15s, color .15s, transform .15s;
}
.hn-header-social a:hover {
    background: var(--hn-magenta); color: #fff;
    transform: translateY(-2px);
}

/* ============================================================
   NAV
   ============================================================ */
.hn-nav {
    background: linear-gradient(135deg, var(--hn-magenta), var(--hn-magenta-d));
    box-shadow: 0 4px 16px rgba(229,50,110,.20);
    position: sticky; top: 0;
    z-index: 40;
}
.hn-nav-sentinel {
    /* Marca onde o nav começa naturalmente; quando ele sai da viewport,
       o nav está sticky e o JS adiciona .is-stuck. */
    height: 1px;
    pointer-events: none;
}

.hn-nav-wrap {
    position: relative;
    display: flex;
    align-items: center;
    gap: 8px;
}

/* Mini-brand: aparece SOMENTE quando o nav está pegajoso (sticky no topo).
   Specificity .hn-nav .hn-nav-brand é necessária pra ganhar do .hn-nav a
   que define display: inline-flex pros links do menu. */
.hn-nav .hn-nav-brand {
    display: none;
    flex-direction: column;
    align-items: flex-start;
    flex-shrink: 0;
    line-height: 1.05;
    padding: 4px 14px 4px 0;
    border-right: 1px solid rgba(255,255,255,.20);
    margin-right: 6px;
    color: #fff;
    text-decoration: none;
    transition: opacity .25s ease, transform .25s ease;
    opacity: 0;
    transform: translateX(-6px);
}
.hn-nav.is-stuck .hn-nav-brand {
    display: flex;
    opacity: 1;
    transform: translateX(0);
}
.hn-nav-brand-pre {
    font-size: 9.5px;
    font-weight: 600;
    letter-spacing: .04em;
    opacity: .85;
    text-transform: uppercase;
}
.hn-nav-brand-titulo {
    font-size: 14px;
    font-weight: 800;
    letter-spacing: -.01em;
    margin: 1px 0;
}
.hn-nav-brand-sub {
    font-size: 9.5px;
    font-weight: 700;
    letter-spacing: .06em;
    text-transform: uppercase;
    opacity: .9;
}
.hn-nav-brand:hover { color: #fff; opacity: .85; }
.hn-nav-a11y {
    display: inline-flex; align-items: center; gap: 6px;
    flex-shrink: 0;
    padding: 8px 14px;
    margin-right: 4px;
    background: rgba(255,255,255,.18);
    color: #fff;
    border: 1.5px solid rgba(255,255,255,.30);
    border-radius: 999px;
    font-size: 13px; font-weight: 700;
    transition: background .15s, border-color .15s, transform .15s;
    white-space: nowrap;
}
.hn-nav-a11y:hover {
    background: #fff;
    color: var(--hn-magenta);
    border-color: #fff;
    transform: translateY(-1px);
}
.hn-nav-a11y[aria-pressed="true"] {
    background: #FFD60A;
    color: #000;
    border-color: #FFD60A;
}
.hn-nav-inner { flex: 1; min-width: 0; }
.hn-nav-inner {
    display: flex; gap: 4px;
    padding: 6px 24px;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
}
.hn-nav-inner::-webkit-scrollbar { display: none; }
.hn-nav-scroll-hint {
    display: none;
    position: absolute;
    top: 0; right: 0; bottom: 0;
    width: 56px;
    pointer-events: none;
    background: linear-gradient(to right, rgba(199,30,92,0), var(--hn-magenta-d) 75%);
    align-items: center;
    justify-content: flex-end;
    padding-right: 10px;
    color: #fff;
    animation: hn-hint-bob 1.4s ease-in-out infinite;
}
@keyframes hn-hint-bob {
    0%, 100% { transform: translateX(0); opacity: .9; }
    50%      { transform: translateX(4px); opacity: 1; }
}
.hn-nav a {
    display: inline-flex; align-items: center; gap: 6px;
    padding: 10px 16px;
    color: rgba(255,255,255,.85);
    font-weight: 600; font-size: 14px;
    border-radius: 999px;
    white-space: nowrap;
    transition: background .15s, color .15s;
}
.hn-nav a:hover { background: rgba(255,255,255,.10); color: #fff; }
.hn-nav a.is-active {
    background: #fff;
    color: var(--hn-magenta);
}

/* ============================================================
   HERO
   ============================================================ */
.hn-hero {
    position: relative;
    overflow: hidden;
    isolation: isolate;
    padding: clamp(56px, 8vw, 88px) 0 clamp(72px, 9vw, 112px);
    border-bottom: 1px solid var(--hn-line);
}
.hn-hero-bg {
    position: absolute; inset: 0;
    z-index: -1;
    pointer-events: none;
    overflow: hidden;
}
.hn-hero-blob {
    position: absolute;
    width: 520px; height: 520px;
    border-radius: 50%;
    filter: blur(120px);
    opacity: .35;
    animation: hn-float 22s ease-in-out infinite;
}
.hn-hero-blob--magenta { background: var(--hn-magenta); top: -160px; left: -120px; }
.hn-hero-blob--cyan    { background: var(--hn-cyan);    bottom: -160px; right: -100px; animation-delay: -10s; }
html[data-tema="escuro"] .hn-hero-blob { opacity: .25; }

@keyframes hn-float {
    0%, 100% { transform: translate(0,0) scale(1); }
    33%      { transform: translate(40px,-30px) scale(1.05); }
    66%      { transform: translate(-30px,20px) scale(.95); }
}

.hn-hero-grid-pattern {
    position: absolute; inset: 0;
    background-image:
        linear-gradient(to right, rgba(15,23,42,.03) 1px, transparent 1px),
        linear-gradient(to bottom, rgba(15,23,42,.03) 1px, transparent 1px);
    background-size: 40px 40px;
    mask-image: radial-gradient(ellipse 70% 60% at 50% 30%, #000 30%, transparent 80%);
}
html[data-tema="escuro"] .hn-hero-grid-pattern {
    background-image:
        linear-gradient(to right, rgba(255,255,255,.04) 1px, transparent 1px),
        linear-gradient(to bottom, rgba(255,255,255,.04) 1px, transparent 1px);
}

.hn-hero-grid {
    display: grid;
    grid-template-columns: 1.1fr .9fr;
    gap: 56px;
    align-items: center;
}
.hn-breadcrumb {
    display: inline-flex; align-items: center; gap: 6px;
    margin-bottom: 16px;
    font-size: 13px; font-weight: 600;
    color: var(--hn-muted);
}
.hn-breadcrumb a { color: var(--hn-magenta); }
.hn-breadcrumb a:hover { text-decoration: underline; }

.hn-hero-h1 {
    font-size: clamp(40px, 5.5vw, 68px);
    font-weight: 800;
    line-height: .98;
    letter-spacing: -.035em;
    color: var(--hn-ink);
    margin-bottom: 24px;
}
.hn-hero-h1-grad {
    background: linear-gradient(135deg, var(--hn-magenta) 0%, var(--hn-cyan) 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    color: transparent;
}
.hn-hero-lede {
    font-size: clamp(15px, 1.5vw, 17px);
    line-height: 1.65;
    color: var(--hn-text);
    max-width: 580px;
}
.hn-hero-lede strong { color: var(--hn-ink); font-weight: 700; }

/* CARD e-SIC */
.hn-esic-card {
    position: relative;
    background: var(--hn-card);
    border: 1px solid var(--hn-line);
    border-radius: var(--hn-radius-lg);
    padding: 32px;
    box-shadow: var(--hn-elev-3);
    backdrop-filter: blur(8px) saturate(120%);
    -webkit-backdrop-filter: blur(8px) saturate(120%);
}
.hn-esic-card::before {
    content: "";
    position: absolute;
    inset: 0;
    border-radius: var(--hn-radius-lg);
    padding: 1.5px;
    background: linear-gradient(135deg, var(--hn-magenta), var(--hn-cyan));
    -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
            mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
    -webkit-mask-composite: xor;
            mask-composite: exclude;
    pointer-events: none;
    opacity: .5;
}
.hn-esic-head {
    display: flex; align-items: center; gap: 12px;
    margin-bottom: 4px;
}
.hn-esic-icon {
    display: inline-flex; align-items: center; justify-content: center;
    width: 44px; height: 44px;
    background: var(--hn-magenta-50);
    color: var(--hn-magenta);
    border-radius: 12px;
}
.hn-esic-card h2 {
    font-size: 22px; font-weight: 800;
    color: var(--hn-ink);
    letter-spacing: -.02em;
}
.hn-esic-sub {
    font-size: 13px;
    color: var(--hn-muted);
    margin-bottom: 24px;
    margin-left: 56px;
}
.hn-esic-stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
    margin-bottom: 18px;
}
.hn-esic-stat {
    text-align: center;
    padding: 16px 8px;
    background: var(--hn-line-2);
    border-radius: 12px;
    transition: transform .2s;
}
.hn-esic-stat:hover { transform: translateY(-2px); }
.hn-esic-num {
    display: block;
    font-size: clamp(28px, 3.5vw, 36px);
    font-weight: 800;
    line-height: 1;
    margin-bottom: 6px;
    font-variant-numeric: tabular-nums;
    letter-spacing: -.03em;
}
.hn-esic-stat--green .hn-esic-num { color: var(--hn-green); }
.hn-esic-stat--cyan  .hn-esic-num { color: var(--hn-cyan-d); }
.hn-esic-stat--amber .hn-esic-num { color: var(--hn-amber); }
.hn-esic-label {
    display: block;
    font-size: 11.5px; font-weight: 700;
    color: var(--hn-muted);
    text-transform: uppercase;
    letter-spacing: .05em;
}
.hn-esic-updated {
    display: inline-flex; align-items: center; gap: 4px;
    font-size: 11.5px; color: var(--hn-muted);
    margin-bottom: 18px;
}
.hn-esic-btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 8px;
    width: 100%;
    padding: 14px 20px;
    background: linear-gradient(135deg, var(--hn-magenta), var(--hn-magenta-d));
    color: #fff !important;
    font-weight: 700; font-size: 14px;
    border-radius: 12px;
    box-shadow: 0 8px 20px rgba(229,50,110,.25);
    transition: transform .15s, box-shadow .15s;
}
.hn-esic-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 28px rgba(229,50,110,.35);
}

/* ============================================================
   ACESSO RÁPIDO
   ============================================================ */
.hn-quick { padding: clamp(56px, 7vw, 88px) 0; }
.hn-quick-head {
    display: flex; align-items: end; justify-content: space-between;
    gap: 16px; flex-wrap: wrap;
    margin-bottom: 32px;
}
.hn-quick-head h2 {
    font-size: clamp(26px, 3vw, 36px);
    font-weight: 800;
    letter-spacing: -.025em;
}
.hn-quick-count {
    display: inline-flex; align-items: center; gap: 6px;
    padding: 6px 14px;
    background: var(--hn-magenta-50);
    color: var(--hn-magenta);
    border-radius: 999px;
    font-size: 13px;
    font-weight: 600;
}
.hn-quick-count strong { font-weight: 800; }

.hn-quick-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(148px, 1fr));
    gap: 10px;
}
.hn-tile {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
    width: 100%;
    padding: 14px;
    background: var(--hn-card);
    border: 1px solid var(--hn-line);
    border-radius: var(--hn-radius-sm);
    color: var(--hn-ink);
    text-align: left;
    transition: transform .25s, box-shadow .25s, border-color .25s;
    overflow: hidden;
    min-height: 100px;
}
.hn-tile::before {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, var(--hn-magenta-50) 0%, var(--hn-cyan-50) 100%);
    opacity: 0;
    transition: opacity .25s;
    z-index: 0;
}
.hn-tile > * { position: relative; z-index: 1; }
.hn-tile:hover {
    transform: translateY(-4px);
    box-shadow: var(--hn-elev-2);
    border-color: transparent;
}
.hn-tile:hover::before { opacity: 1; }
.hn-tile.is-disabled {
    opacity: .45;
    cursor: not-allowed;
    pointer-events: none;
}
.hn-tile-icon {
    display: inline-flex; align-items: center; justify-content: center;
    width: 40px; height: 40px;
    background: var(--hn-magenta-50);
    color: var(--hn-magenta);
    border-radius: 10px;
    transition: transform .25s;
}
.hn-tile-icon svg { width: 22px; height: 22px; }
.hn-tile:hover .hn-tile-icon {
    transform: scale(1.05) rotate(-2deg);
}
.hn-tile-name {
    font-size: 13px; font-weight: 700;
    color: var(--hn-ink);
    line-height: 1.3;
}
.hn-tile-arrow,
.hn-tile-ext {
    position: absolute;
    top: 12px; right: 12px;
    color: var(--hn-muted);
    opacity: 0;
    transform: translate(-4px, 4px);
    transition: opacity .25s, transform .25s, color .25s;
}
.hn-tile:hover .hn-tile-arrow,
.hn-tile:hover .hn-tile-ext {
    opacity: 1;
    transform: translate(0, 0);
    color: var(--hn-magenta);
}

/* ============================================================
   CATEGORIAS COLAPSÁVEIS
   ============================================================ */
.hn-cats-wrap {
    padding: clamp(56px, 7vw, 88px) 0;
    background: var(--hn-line-2);
    border-top: 1px solid var(--hn-line);
}
.hn-cats-head {
    text-align: center;
    max-width: 640px;
    margin: 0 auto 36px;
}
.hn-cats-head h2 {
    font-size: clamp(26px, 3vw, 36px);
    font-weight: 800;
    letter-spacing: -.025em;
    margin-bottom: 8px;
}
.hn-cats-lede { color: var(--hn-muted); font-size: 14px; }

.hn-cats {
    display: flex;
    flex-direction: column;
    gap: 12px;
    max-width: 880px;
    margin: 0 auto;
}

.hn-cat {
    background: var(--hn-card);
    border: 1px solid var(--hn-line);
    border-radius: var(--hn-radius);
    overflow: hidden;
    transition: box-shadow .2s, border-color .2s;
}
.hn-cat:hover { box-shadow: var(--hn-elev-1); }
.hn-cat[open] { box-shadow: var(--hn-elev-2); border-color: var(--hn-magenta-50); }

.hn-cat-head {
    display: grid;
    grid-template-columns: auto 1fr auto auto;
    align-items: center;
    gap: 14px;
    padding: 16px 22px;
    cursor: pointer;
    list-style: none;
    transition: background .15s;
}
.hn-cat-head::-webkit-details-marker { display: none; }
.hn-cat-head:hover { background: var(--hn-line-2); }

.hn-cat-icon {
    display: inline-flex; align-items: center; justify-content: center;
    width: 44px; height: 44px;
    border-radius: 12px;
    flex-shrink: 0;
    transition: transform .25s;
}
.hn-cat-icon--magenta { background: var(--hn-magenta-50); color: var(--hn-magenta); }
.hn-cat-icon--cyan    { background: var(--hn-cyan-50);    color: var(--hn-cyan-d); }
.hn-cat[open] .hn-cat-icon { transform: scale(1.05) rotate(-3deg); }

.hn-cat-title {
    font-size: 16px; font-weight: 700;
    color: var(--hn-ink);
    line-height: 1.25;
}

.hn-cat-updated {
    display: inline-flex; align-items: center; justify-content: center; gap: 6px;
    font-size: 12px; font-weight: 600;
    color: var(--hn-muted);
    white-space: nowrap;
    text-align: center;
}
.hn-status {
    display: inline-block;
    width: 10px; height: 10px;
    border-radius: 50%;
    box-shadow: 0 0 0 3px rgba(0,0,0,.04);
}
.hn-status--fresco { background: var(--hn-green); animation: hn-pulse 2s ease-in-out infinite; }
.hn-status--medio  { background: var(--hn-amber); }
.hn-status--velho  { background: var(--hn-magenta); }
@keyframes hn-pulse {
    0%, 100% { box-shadow: 0 0 0 3px rgba(22,163,74,.10); }
    50%      { box-shadow: 0 0 0 7px rgba(22,163,74,.18); }
}

.hn-cat-chev {
    display: inline-flex;
    color: var(--hn-muted);
    transition: transform .25s;
}
.hn-cat[open] .hn-cat-chev { transform: rotate(180deg); color: var(--hn-magenta); }

.hn-cat-body {
    padding: 4px 22px 22px 22px;
    border-top: 1px solid var(--hn-line);
    animation: hn-slide-down .25s ease;
}
@keyframes hn-slide-down {
    from { opacity: 0; transform: translateY(-4px); }
    to   { opacity: 1; transform: translateY(0); }
}

.hn-cat-items {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 8px;
    margin-top: 14px;
}
.hn-cat-item {
    position: relative;
    display: flex; align-items: center; gap: 12px;
    padding: 12px 16px;
    background: var(--hn-line-2);
    border-radius: 10px;
    color: var(--hn-text);
    font-size: 14px;
    font-weight: 500;
    text-align: left;
    width: 100%;
    transition: background .15s, color .15s, transform .15s;
}
.hn-cat-item:hover {
    background: var(--hn-magenta-50);
    color: var(--hn-magenta);
    transform: translateX(2px);
}
.hn-cat-item.is-disabled { opacity: .45; pointer-events: none; }
.hn-cat-item-icon {
    display: inline-flex; align-items: center;
    color: currentColor;
    flex-shrink: 0;
}
.hn-cat-item-name { flex: 1; }
.hn-cat-item-arrow,
.hn-cat-item-ext {
    color: var(--hn-muted);
    opacity: 0;
    transform: translateX(-4px);
    transition: opacity .15s, transform .15s, color .15s;
}
.hn-cat-item:hover .hn-cat-item-arrow,
.hn-cat-item:hover .hn-cat-item-ext {
    opacity: 1;
    transform: translateX(0);
    color: var(--hn-magenta);
}

/* Skeleton enquanto carrega subitens — grid 2-col idêntico ao final pra
   evitar layout shift quando os items reais chegam. */
.hn-cat-skeleton {
    padding-top: 14px;
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 8px;
}
.hn-skel {
    height: 44px;
    background: linear-gradient(90deg, var(--hn-line-2) 0%, var(--hn-line) 50%, var(--hn-line-2) 100%);
    background-size: 200% 100%;
    border-radius: 10px;
    animation: hn-shimmer 1.4s linear infinite;
}
.hn-skel--block { height: 60px; }
.hn-skel-list { display: flex; flex-direction: column; gap: 8px; }
@keyframes hn-shimmer {
    from { background-position: 200% 0; }
    to   { background-position: -200% 0; }
}

/* Fade-in suave quando subitens reais substituem o skeleton */
.hn-cat-items--enter {
    opacity: 0;
    transform: translateY(4px);
}
.hn-cat-items--enter.hn-cat-items--in {
    opacity: 1;
    transform: translateY(0);
    transition: opacity .25s ease, transform .25s ease;
}
@media (prefers-reduced-motion: reduce) {
    .hn-cat-items--enter,
    .hn-cat-items--enter.hn-cat-items--in {
        opacity: 1 !important;
        transform: none !important;
        transition: none !important;
    }
}

/* ============================================================
   FOOTER
   ============================================================ */
.hn-footer {
    /* Sempre escuro — mantém identidade institucional independente do tema. */
    background: #0F172A;
    color: #cbd5e1;
    padding: 56px 0 24px;
    border-top: 4px solid var(--hn-magenta);
}
.hn-footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 40px;
    margin-bottom: 40px;
}
.hn-footer-col h3 {
    font-size: 14px; font-weight: 800;
    color: #fff;
    margin-bottom: 14px;
    text-transform: uppercase;
    letter-spacing: .06em;
}
.hn-footer-col p, .hn-footer-col ul li { font-size: 13.5px; line-height: 1.8; color: #94a3b8; }
.hn-footer-col a { color: #cbd5e1; transition: color .15s; }
.hn-footer-col a:hover { color: var(--hn-magenta); text-decoration: underline; }
.hn-footer-col--brand p, .hn-footer-col--brand address { color: #94a3b8; font-style: normal; }
.hn-footer-col--brand address {
    display: flex; flex-direction: column; gap: 8px;
    margin: 14px 0;
    font-size: 13px;
}
.hn-footer-col--brand address span {
    display: inline-flex; align-items: flex-start; gap: 8px;
}
.hn-footer-site a {
    font-weight: 700; color: var(--hn-magenta);
}
.hn-footer-social {
    display: flex; gap: 8px;
    margin-top: 8px;
}
.hn-footer-social a {
    display: inline-flex; align-items: center; justify-content: center;
    width: 32px; height: 32px;
    background: rgba(255,255,255,.06);
    color: #cbd5e1;
    border-radius: 999px;
    transition: background .15s, color .15s;
}
.hn-footer-social a:hover {
    background: var(--hn-magenta); color: #fff;
}

.hn-footer-bottom {
    display: flex; flex-wrap: wrap;
    justify-content: space-between;
    gap: 12px;
    padding-top: 22px;
    border-top: 1px solid rgba(255,255,255,.08);
    font-size: 12px;
    color: #94a3b8;
}
.hn-footer-bottom strong { color: #fff; }
.hn-footer-bottom a { color: #cbd5e1; }
.hn-footer-bottom a:hover { color: var(--hn-magenta); }

/* ============================================================
   MODAIS (<dialog>)
   ============================================================ */
.hn-modal {
    border: 0;
    padding: 0;
    background: transparent;
    max-width: 720px;
    width: calc(100% - 32px);
    max-height: 90vh;
}
.hn-modal--lg { max-width: 920px; }
.hn-modal::backdrop {
    background: rgba(15,23,42,.55);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
}
.hn-modal-box {
    background: var(--hn-card);
    border-radius: var(--hn-radius-lg);
    overflow: hidden;
    box-shadow: var(--hn-elev-3);
    max-height: 90vh;
    display: flex;
    flex-direction: column;
}
.hn-modal-head {
    display: grid;
    grid-template-columns: auto 1fr auto;
    align-items: center;
    gap: 14px;
    padding: 18px 24px;
    background: linear-gradient(135deg, var(--hn-magenta), var(--hn-magenta-d));
    color: #fff;
}
.hn-modal-icon {
    display: inline-flex; align-items: center; justify-content: center;
    width: 40px; height: 40px;
    background: rgba(255,255,255,.18);
    border-radius: 10px;
}
.hn-modal-head h2 {
    color: #fff;
    font-size: 18px;
    font-weight: 800;
}
.hn-modal-close {
    display: inline-flex; align-items: center; justify-content: center;
    width: 36px; height: 36px;
    background: rgba(255,255,255,.18);
    color: #fff;
    border-radius: 999px;
    transition: background .15s, transform .15s;
}
.hn-modal-close:hover { background: rgba(255,255,255,.30); transform: rotate(90deg); }

.hn-modal-body {
    padding: 24px;
    overflow-y: auto;
    color: var(--hn-text);
    line-height: 1.6;
}
.hn-modal-body :is(h3) {
    font-size: 14px; font-weight: 800;
    color: var(--hn-magenta);
    text-transform: uppercase; letter-spacing: .06em;
    margin: 18px 0 8px;
    padding-bottom: 6px;
    border-bottom: 2px solid var(--hn-magenta-50);
}
.hn-modal-body p { margin-bottom: 12px; }
.hn-modal-body ul {
    list-style: disc;
    padding-left: 22px;
    margin-bottom: 12px;
}
.hn-modal-body ul li { margin-bottom: 6px; }
.hn-modal-callout {
    margin: 16px 0;
    padding: 14px 16px;
    background: var(--hn-magenta-50);
    border-left: 4px solid var(--hn-magenta);
    border-radius: 8px;
    font-size: 14px;
}
.hn-modal-callout strong { color: var(--hn-magenta-d); }
.hn-modal-callout--info {
    display: flex; gap: 12px;
    background: var(--hn-cyan-50);
    border-left-color: var(--hn-cyan);
    color: var(--hn-text);
}
.hn-modal-callout--info strong { color: var(--hn-cyan-d); }
.hn-modal-link a {
    display: inline-flex; align-items: center; gap: 4px;
    color: var(--hn-magenta);
    font-weight: 600;
}
.hn-modal-link a:hover { text-decoration: underline; }

.hn-modal-foot {
    padding: 16px 24px;
    border-top: 1px solid var(--hn-line);
    display: flex; justify-content: flex-end;
}
.hn-modal-btn {
    padding: 10px 20px;
    background: var(--hn-line-2);
    color: var(--hn-ink);
    font-weight: 600; font-size: 14px;
    border-radius: 10px;
    transition: background .15s;
}
.hn-modal-btn:hover { background: var(--hn-line); }

/* ============================================================
   ESTATÍSTICAS DE ACESSO (modal)
   ============================================================ */
.hn-acessos-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: 12px;
    margin-bottom: 24px;
}
.hn-acessos-card {
    position: relative;
    padding: 18px;
    border-radius: var(--hn-radius);
    background: var(--hn-line-2);
    border: 1px solid var(--hn-line);
    overflow: hidden;
    text-align: left;
}
.hn-acessos-card::before {
    content: "";
    position: absolute;
    inset: 0 auto 0 0;
    width: 4px;
    background: var(--hn-magenta);
}
.hn-acessos-card--magenta::before { background: var(--hn-magenta); }
.hn-acessos-card--cyan::before    { background: var(--hn-cyan); }
.hn-acessos-card--green::before   { background: var(--hn-green); }
.hn-acessos-card--amber::before   { background: var(--hn-amber); }
.hn-acessos-label {
    display: block;
    font-size: 11px; font-weight: 700;
    text-transform: uppercase; letter-spacing: .08em;
    color: var(--hn-muted);
    margin-bottom: 6px;
}
.hn-acessos-value {
    display: block;
    font-size: clamp(22px, 3vw, 30px);
    font-weight: 800;
    color: var(--hn-ink);
    font-variant-numeric: tabular-nums;
    letter-spacing: -.025em;
    line-height: 1;
}
.hn-acessos-chart {
    margin-bottom: 22px;
}
.hn-acessos-chart h3 {
    font-size: 13px; font-weight: 800;
    color: var(--hn-magenta);
    text-transform: uppercase; letter-spacing: .06em;
    margin-bottom: 10px;
    padding-bottom: 6px;
    border-bottom: 2px solid var(--hn-magenta-50);
}
.hn-acessos-chart-wrap {
    background: var(--hn-line-2);
    padding: 12px;
    border-radius: var(--hn-radius);
}

/* ============================================================
   COVID DOC LIST (renderizado via JS)
   ============================================================ */
.hn-doc-intro {
    margin-bottom: 14px;
    font-size: 13px;
    color: var(--hn-muted);
}
.hn-doc-year {
    font-size: 13px;
    font-weight: 800;
    color: var(--hn-magenta);
    text-transform: uppercase; letter-spacing: .08em;
    margin: 18px 0 10px;
    padding-bottom: 6px;
    border-bottom: 2px solid var(--hn-magenta-50);
}
.hn-doc-list {
    list-style: none;
    padding: 0;
    margin: 0 0 16px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}
.hn-doc-item {
    display: grid;
    grid-template-columns: auto 1fr auto;
    align-items: center;
    gap: 14px;
    padding: 14px 16px;
    background: var(--hn-line-2);
    border: 1px solid transparent;
    border-radius: 10px;
    transition: background .15s, border-color .15s, transform .15s, box-shadow .15s;
}
.hn-doc-item::before {
    content: "";
    display: inline-flex;
    width: 36px; height: 36px;
    border-radius: 10px;
    background: var(--hn-card);
    background-image:
        url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='18' height='18' viewBox='0 0 24 24' fill='none' stroke='%23E5326E' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'><path d='M14.5 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V7.5L14.5 2z'/><polyline points='14 2 14 8 20 8'/><line x1='16' y1='13' x2='8' y2='13'/><line x1='16' y1='17' x2='8' y2='17'/><line x1='10' y1='9' x2='8' y2='9'/></svg>");
    background-repeat: no-repeat;
    background-position: center;
    flex-shrink: 0;
    transition: transform .15s;
}
.hn-doc-item:hover {
    background: var(--hn-magenta-50);
    border-color: var(--hn-magenta);
    transform: translateX(2px);
    box-shadow: var(--hn-elev-1);
}
.hn-doc-item:hover::before { transform: scale(1.05) rotate(-2deg); }
.hn-doc-item-title {
    font-size: 14px;
    font-weight: 600;
    color: var(--hn-ink);
    line-height: 1.35;
    min-width: 0;
}
.hn-doc-anexos {
    display: flex; flex-wrap: wrap; gap: 6px;
    list-style: none;
    padding: 0;
}
.hn-doc-chip {
    display: inline-flex; align-items: center; gap: 6px;
    padding: 6px 12px;
    border: 1.5px solid;
    border-radius: 999px;
    font-size: 11px; font-weight: 800;
    letter-spacing: .03em;
    transition: transform .15s, box-shadow .15s, filter .15s;
}
.hn-doc-chip:hover {
    transform: translateY(-1px);
    box-shadow: var(--hn-elev-1);
    filter: saturate(1.2);
}
.hn-doc-chip--red    { background: #FEE2E2; color: #E5326E; border-color: #FCA5A5; }
.hn-doc-chip--blue   { background: #DBEAFE; color: #1D4ED8; border-color: #93C5FD; }
.hn-doc-chip--green  { background: #DCFCE7; color: #15803D; border-color: #86EFAC; }
.hn-doc-chip--cyan   { background: #CFFAFE; color: #0E7490; border-color: #67E8F9; }
.hn-doc-chip--purple { background: #F3E8FF; color: #7E22CE; border-color: #D8B4FE; }
.hn-doc-chip--gray   { background: #F1F5F9; color: #475569; border-color: #CBD5E1; }
.hn-doc-chip-arrow { font-size: 11px; opacity: .8; }

.hn-doc-empty,
.hn-cat-empty {
    display: inline-block;
    padding: 12px 16px;
    color: var(--hn-muted);
    font-size: 13px;
    font-style: italic;
}

/* ============================================================
   ALTO CONTRASTE — WCAG AAA (toggle pelo botão Alto contraste)
   Esquema branco-com-preto: fundo branco puro, texto preto puro,
   links/destaques em magenta forte, focus em amarelo grosso.
   ============================================================ */
html[data-contraste="alto"] .hn-body {
    --hn-ink:        #000000;
    --hn-ink-2:      #000000;
    --hn-text:       #000000;
    --hn-muted:      #000000;
    --hn-line:       #000000;
    --hn-line-2:     #FFFFFF;
    --hn-bg:         #FFFFFF;
    --hn-card:       #FFFFFF;
    --hn-magenta:    #E5326E;
    --hn-magenta-d:  #C71E5C;
    --hn-magenta-50: #FFFFFF;
    --hn-cyan:       #1D4ED8;
    --hn-cyan-d:     #1E3A8A;
    --hn-cyan-50:    #FFFFFF;
    --hn-amber:      #B45309;
    --hn-amber-50:   #FFFFFF;
    --hn-green:      #166534;
    --hn-green-50:   #FFFFFF;
    --hn-elev-1: 0 0 0 0 transparent;
    --hn-elev-2: 0 0 0 0 transparent;
    --hn-elev-3: 0 0 0 0 transparent;
}
/* Bordas grossas em todo elemento de container */
html[data-contraste="alto"] .hn-tile,
html[data-contraste="alto"] .hn-cat,
html[data-contraste="alto"] .hn-esic-card,
html[data-contraste="alto"] .hn-modal-box,
html[data-contraste="alto"] .hn-doc-item,
html[data-contraste="alto"] .hn-cat-item,
html[data-contraste="alto"] .hn-acessos-card {
    border: 2px solid #000 !important;
    background: #fff !important;
    color: #000 !important;
}
/* Topbar — fundo branco, texto preto */
html[data-contraste="alto"] .hn-topbar {
    background: #fff !important;
    color: #000 !important;
    border-bottom: 2px solid #000;
}
html[data-contraste="alto"] .hn-topbar-link,
html[data-contraste="alto"] .hn-fonte button,
html[data-contraste="alto"] .hn-tema,
html[data-contraste="alto"] .hn-vlibras,
html[data-contraste="alto"] .hn-hc {
    color: #000 !important;
    background: #fff !important;
    border-color: #000 !important;
    opacity: 1 !important;
}
html[data-contraste="alto"] .hn-fonte { border: 2px solid #000; }
html[data-contraste="alto"] .hn-fonte button { border-right-color: #000 !important; }
html[data-contraste="alto"] .hn-fonte button[aria-pressed="true"] {
    background: #000 !important; color: #fff !important;
}
html[data-contraste="alto"] .hn-acessos-badge {
    background: #000 !important; color: #fff !important;
}
html[data-contraste="alto"] .hn-hc[aria-pressed="true"] {
    background: #000 !important; color: #fff !important;
}
/* Header — fundo branco, texto preto */
html[data-contraste="alto"] .hn-header {
    background: #fff !important;
    border-bottom: 2px solid #000;
}
html[data-contraste="alto"] .hn-brand-titulo,
html[data-contraste="alto"] .hn-brand-pretitle,
html[data-contraste="alto"] .hn-brand-subtitle { color: #000 !important; }
html[data-contraste="alto"] .hn-search {
    background: #fff !important;
    border: 2px solid #000 !important;
}
html[data-contraste="alto"] .hn-search-icon,
html[data-contraste="alto"] .hn-search input { color: #000 !important; }
html[data-contraste="alto"] .hn-search input::placeholder { color: #444 !important; }
html[data-contraste="alto"] .hn-search button[type="submit"] {
    background: #000 !important; color: #fff !important;
}
html[data-contraste="alto"] .hn-header-social a {
    background: #fff !important; color: #000 !important; border: 2px solid #000;
}
/* Nav */
html[data-contraste="alto"] .hn-nav {
    background: #000 !important;
    box-shadow: none;
    border-bottom: 2px solid #000;
}
html[data-contraste="alto"] .hn-nav a {
    color: #fff !important;
    background: transparent !important;
}
html[data-contraste="alto"] .hn-nav a.is-active {
    background: #FFD60A !important; color: #000 !important;
}
html[data-contraste="alto"] .hn-nav a:hover {
    background: #fff !important; color: #000 !important;
}
/* Hero — sem blob, sem grad */
html[data-contraste="alto"] .hn-hero-blob,
html[data-contraste="alto"] .hn-hero-grid-pattern { display: none !important; }
html[data-contraste="alto"] .hn-hero-h1-grad {
    background: none !important;
    -webkit-background-clip: initial !important;
    background-clip: initial !important;
    -webkit-text-fill-color: #E5326E !important;
    color: #E5326E !important;
}
html[data-contraste="alto"] .hn-tile::before,
html[data-contraste="alto"] .hn-esic-card::before { display: none !important; }
/* e-SIC botão */
html[data-contraste="alto"] .hn-esic-btn {
    background: #000 !important; color: #fff !important;
    border: 2px solid #000 !important;
    box-shadow: none !important;
}
html[data-contraste="alto"] .hn-esic-stat { background: #fff !important; border: 1.5px solid #000; }
/* Modal */
html[data-contraste="alto"] .hn-modal-head {
    background: #000 !important; color: #fff !important;
}
html[data-contraste="alto"] .hn-modal-head h2 { color: #fff !important; }
html[data-contraste="alto"] .hn-modal-icon,
html[data-contraste="alto"] .hn-modal-close {
    background: #fff !important; color: #000 !important;
}
html[data-contraste="alto"] .hn-modal-callout {
    background: #fff !important; border: 2px solid #000 !important; color: #000 !important;
}
html[data-contraste="alto"] .hn-doc-chip {
    background: #fff !important; color: #000 !important; border-color: #000 !important;
}
/* Footer — fundo branco, texto preto */
html[data-contraste="alto"] .hn-footer {
    background: #fff !important;
    color: #000 !important;
    border-top: 4px solid #000 !important;
}
html[data-contraste="alto"] .hn-footer :is(h3, p, a, address, span, strong),
html[data-contraste="alto"] .hn-footer-col a,
html[data-contraste="alto"] .hn-footer-bottom strong { color: #000 !important; }
html[data-contraste="alto"] .hn-footer-col a:hover,
html[data-contraste="alto"] .hn-footer-site a { color: #E5326E !important; }
html[data-contraste="alto"] .hn-footer-social a {
    background: #fff !important; color: #000 !important; border: 2px solid #000;
}
/* Focus */
html[data-contraste="alto"] .hn-body :focus-visible {
    outline: 4px solid #FFD60A !important;
    outline-offset: 3px;
}

/* ============================================================
   ANIMAÇÕES SCROLL-TRIGGERED
   ============================================================ */
[data-anim] {
    opacity: 0;
    transform: translateY(16px);
    transition: opacity .55s ease, transform .55s ease;
}
[data-anim].is-in {
    opacity: 1;
    transform: translateY(0);
}

/* ============================================================
   PREFERS-REDUCED-MOTION
   ============================================================ */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: .01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: .01ms !important;
        scroll-behavior: auto !important;
    }
    .hn-hero-blob { animation: none !important; }
    [data-anim] { opacity: 1 !important; transform: none !important; }
}

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 1024px) {
    .hn-header-inner {
        grid-template-columns: auto 1fr;
        grid-template-rows: auto auto;
        gap: 14px;
    }
    .hn-search { grid-column: 1 / -1; max-width: 100%; }
    .hn-header-social { grid-column: 2; justify-self: end; grid-row: 1; }
    .hn-hero-grid { grid-template-columns: 1fr; gap: 40px; }
    .hn-footer-grid { grid-template-columns: 1fr 1fr; }
    .hn-footer-col--brand { grid-column: 1 / -1; }
}

@media (max-width: 720px) {
    .hn-shell { padding: 0 16px; }
    .hn-topbar-link-label { display: none; }
    .hn-topbar-link { padding: 3px 8px; }
    .hn-topbar-tools { gap: 6px; }
    .hn-fonte button { padding: 4px 8px; font-size: 10px; }
    .hn-vlibras span,
    .hn-hc span { display: none; }
    .hn-vlibras, .hn-hc { padding: 4px 8px; }

    .hn-header-inner { padding: 14px 16px; gap: 10px; }
    .hn-brand-logo { width: 48px; height: 48px; }
    .hn-brand-titulo { font-size: 18px; }
    .hn-brand-pretitle { font-size: 10px; }
    .hn-brand-subtitle { font-size: 10px; }
    .hn-header-social a { width: 32px; height: 32px; }

    .hn-search button[type="submit"] {
        padding: 0 14px;
        font-size: 11px;
        letter-spacing: .04em;
        text-transform: uppercase;
    }
    .hn-search button[type="submit"] .hn-search-arrow { display: none; }

    .hn-nav-inner { padding: 4px 8px 4px 16px; }
    .hn-nav a { padding: 8px 12px; font-size: 13px; }
    .hn-nav.is-stuck .hn-nav-brand { display: none; }  /* mobile: mini-brand não cabe */
    .hn-nav-scroll-hint {
        display: flex;
        right: 56px;  /* deixa espaço pro botão de acessibilidade fixo na direita */
    }
    .hn-nav-a11y {
        padding: 8px 10px;
        margin-right: 8px;
    }
    .hn-nav-a11y span { display: none; }

    .hn-hero { padding: 40px 0 56px; }
    .hn-esic-card { padding: 24px; }
    .hn-esic-stats { gap: 8px; }
    .hn-esic-stat { padding: 12px 4px; }
    .hn-esic-num { font-size: 24px; }
    .hn-esic-label { font-size: 10px; }
    .hn-esic-sub { margin-left: 0; margin-top: 4px; }

    .hn-quick-grid { grid-template-columns: repeat(2, 1fr); gap: 8px; }
    .hn-tile { padding: 12px; min-height: 90px; gap: 8px; }
    .hn-tile-icon { width: 36px; height: 36px; }
    .hn-tile-icon svg { width: 20px; height: 20px; }
    .hn-tile-name { font-size: 12.5px; }

    .hn-cat-head {
        grid-template-columns: auto 1fr auto;
        grid-template-rows: auto auto;
        gap: 10px;
        padding: 14px 16px;
    }
    .hn-cat-updated {
        grid-column: 1 / -1;
        grid-row: 2;
        font-size: 11px;
    }
    .hn-cat-chev { grid-column: 3; grid-row: 1; }
    .hn-cat-body { padding: 0 16px 16px; }
    .hn-cat-items { grid-template-columns: 1fr; }

    .hn-footer-grid { grid-template-columns: 1fr; gap: 28px; }
    .hn-footer { padding: 40px 0 16px; }
    .hn-footer-bottom { flex-direction: column; text-align: center; }

    .hn-modal-body { padding: 18px; }
    .hn-modal-head { padding: 14px 16px; }
    .hn-modal-head h2 { font-size: 16px; }
}

@media (max-width: 440px) {
    .hn-quick-grid { grid-template-columns: 1fr; }
}
