/*
 * FUCAM — melhorias de experiência (animações, navegação e leitura).
 * Carregado por último no layout público. Todas as animações ficam desligadas
 * para quem pede "reduzir movimento" no sistema operacional.
 */
:root {
    --fx-green: var(--brand-700);
    --fx-green-dark: var(--brand-800);
    --fx-green-deep: var(--brand-950);
    --fx-accent: var(--brand-400);
    --fx-ink: var(--ink);
    --fx-muted: var(--muted);
    --fx-line: var(--line-soft);
    --fx-ease: cubic-bezier(.22, .8, .24, 1);
}

/* ---------- Rolagem suave e foco ---------- */
@media (prefers-reduced-motion: no-preference) {
    html { scroll-behavior: smooth; }
}
:target { scroll-margin-top: 110px; }

/* ---------- Cabeçalho fixo no desktop, com sombra ao rolar ---------- */
@media (min-width: 1024px) {
    body.fucam-public-v46 .site-header {
        position: sticky;
        top: 0;
        transition: box-shadow .3s var(--fx-ease), background-color .3s var(--fx-ease);
    }
    body.fucam-public-v46 .site-header.is-scrolled {
        box-shadow: var(--shadow-lg);
    }
}

/* ---------- Barra de progresso de leitura (notícias) ---------- */
.fx-progress {
    position: fixed;
    inset: 0 0 auto 0;
    height: 3px;
    z-index: 1000;
    pointer-events: none;
    background: transparent;
}
.fx-progress span {
    display: block;
    height: 100%;
    width: 100%;
    transform-origin: 0 50%;
    transform: scaleX(0);
    background: linear-gradient(90deg, var(--fx-accent), var(--fx-green));
}

/* ---------- Revelar seções ao rolar ---------- */
@media (prefers-reduced-motion: no-preference) {
    .fx-js .fx-reveal {
        opacity: 0;
        transform: translateY(12px);
        transition:
            opacity .45s var(--fx-ease) var(--fx-delay, 0ms),
            transform .45s var(--fx-ease) var(--fx-delay, 0ms);
    }
    .fx-js .fx-reveal.is-visible {
        opacity: 1;
        transform: none;
    }
}

/* ---------- Botão "voltar ao topo" ---------- */
.fx-top {
    position: fixed;
    right: clamp(14px, 3vw, 28px);
    bottom: clamp(14px, 3vw, 28px);
    z-index: 900;
    display: inline-grid;
    place-items: center;
    width: 48px;
    height: 48px;
    border: 0;
    border-radius: var(--radius-pill);
    color: #fff;
    background: var(--fx-green-dark);
    box-shadow: var(--shadow-lg);
    cursor: pointer;
    opacity: 0;
    visibility: hidden;
    transform: translateY(12px) scale(.9);
    transition: opacity .25s ease, transform .25s var(--fx-ease), visibility .25s, background-color .2s;
}
.fx-top.is-visible {
    opacity: 1;
    visibility: visible;
    transform: none;
}
.fx-top:hover { background: var(--fx-green); }
.fx-top:focus-visible { outline: 3px solid var(--fx-accent); outline-offset: 3px; }
.fx-top svg { width: 22px; height: 22px; }

/* ---------- Notícia: meta, tempo de leitura e compartilhamento ---------- */
.news-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: .35rem 1rem;
    margin-top: .75rem;
    color: var(--fx-muted);
    font-size: var(--fs-base);
}
.news-meta span { display: inline-flex; align-items: center; gap: .4rem; }
.news-meta span + span::before {
    content: "";
    width: 4px;
    height: 4px;
    margin-right: .6rem;
    border-radius: 50%;
    background: currentColor;
    opacity: .5;
}

.news-share {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: .6rem;
    margin: 2.25rem 0 .5rem;
    padding-top: 1.5rem;
    border-top: 1px solid var(--fx-line);
}
.news-share strong { margin-right: .35rem; color: var(--fx-ink); font-size: var(--fs-base); }
.news-share a,
.news-share button {
    display: inline-flex;
    align-items: center;
    gap: .45rem;
    min-height: 40px;
    padding: .5rem .95rem;
    border: 1px solid var(--fx-line);
    border-radius: var(--radius-pill);
    color: var(--fx-green-dark);
    background: #fff;
    font: inherit;
    font-size: var(--fs-md);
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
    transition: background-color .2s, color .2s, border-color .2s, transform .2s var(--fx-ease);
}
.news-share a:hover,
.news-share button:hover {
    color: #fff;
    border-color: var(--fx-green);
    background: var(--fx-green);
    transform: translateY(-2px);
}
.news-share a:focus-visible,
.news-share button:focus-visible { outline: 3px solid var(--fx-accent); outline-offset: 2px; }
.news-share svg { width: 18px; height: 18px; flex: none; }
.news-share [data-share-status] { color: var(--fx-green-dark); font-size: var(--fs-md); font-weight: 600; }

/* ---------- Formulário de contato ---------- */
.contact-hp {
    position: absolute !important;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
    white-space: nowrap;
}
.contact-form small { font-weight: 400; color: var(--fx-muted); }
.contact-counter { display: block; margin-top: .3rem; text-align: right; font-size: var(--fs-md); }
.contact-counter.is-near-limit { color: #b45309; font-weight: 600; }
.contact-form label.contact-consent {
    display: flex;
    align-items: flex-start;
    gap: .7rem;
    font-weight: 400;
    line-height: 1.5;
}
.contact-form label.contact-consent input {
    flex: none;
    width: 20px;
    height: 20px;
    margin: .15rem 0 0;
    accent-color: var(--fx-green);
}
.contact-consent a { color: var(--fx-green-dark); font-weight: 600; }
.contact-form button[disabled] { opacity: .7; cursor: progress; }

/* ---------- Rodapé: logo do Governo de Minas no mesmo padrão do logo da FUCAM ---------- */
.state-brand--logo {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    min-height: 80px;
    padding: 0;
}
.fucam-public-v46 .state-brand--logo .state-brand-logo,
.state-brand--logo .state-brand-logo {
    display: block;
    width: 220px;
    max-width: 100%;
    max-height: 85px;
    height: auto;
    object-fit: contain;
    object-position: right center;
    /* Sem filtro: a versão para fundo escuro já tem letras brancas e mantém o triângulo vermelho. */
    filter: none;
    transition: opacity .2s;
}
.state-brand--logo:hover .state-brand-logo { opacity: .85; }
.state-brand--logo:focus-visible { outline: 3px solid var(--fx-accent); outline-offset: 4px; border-radius: var(--radius-xs); }

/* ---------- Rodapé: crédito de desenvolvimento ---------- */
.footer-credit {
    display: inline-block;
    margin-left: .6rem;
    padding-left: .6rem;
    border-left: 1px solid rgba(255, 255, 255, .25);
    opacity: .85;
}
.footer-credit strong { font-weight: 700; color: #fff; }
@media (max-width: 760px) {
    .footer-credit { display: block; margin: .35rem 0 0; padding: 0; border: 0; }
}

/* ---------- Notícia: botão "Voltar" alinhado à coluna do texto ---------- */
.news-detail .page-back-link {
    max-width: 900px;
    margin-inline: auto;
    padding-top: .5rem;
    padding-bottom: 2.5rem;
}

/* ---------- Notícia: últimas notícias abaixo do texto ---------- */
.news-related { padding: clamp(2.5rem, 5vw, 4rem) 0 clamp(3rem, 6vw, 5rem); background: var(--surface); margin-top: 2.5rem; }
.news-related .section-heading-row { display: flex; flex-wrap: wrap; align-items: end; justify-content: space-between; gap: 1rem; margin-bottom: 1.75rem; }
.news-related h2 { margin: .25rem 0 0; font-size: clamp(1.5rem, 3vw, 2rem); color: var(--fx-ink); }
.news-related-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(1rem, 2vw, 1.75rem); }
@media (max-width: 960px) { .news-related-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 640px) { .news-related-grid { grid-template-columns: 1fr; } }
body.high-contrast .news-related { background: #000; }

/* ---------- Notícias: rolagem infinita ---------- */
.news-infinite { display: none; }
.fx-js .news-infinite { display: grid; justify-items: center; gap: 1rem; padding: 2.5rem 0 1rem; }
.fx-js [data-infinite-pagination].is-replaced { display: none; }
.news-infinite__retry[hidden] { display: none !important; }
.news-infinite__status { display: inline-flex; align-items: center; gap: .75rem; color: var(--fx-muted); font-weight: 600; }
.news-infinite__spinner {
    width: 22px; height: 22px; border-radius: 50%;
    border: 3px solid rgba(8, 123, 97, .18); border-top-color: var(--fx-green);
}
.news-infinite.is-idle .news-infinite__spinner { visibility: hidden; }
.news-infinite.is-done .news-infinite__spinner { display: none; }
.news-infinite.is-done .news-infinite__status { color: var(--fx-green-dark); }
.news-infinite.is-done .news-infinite__status::before {
    content: ""; width: 40px; height: 2px; border-radius: var(--radius-xs); background: var(--fx-line);
}
.news-infinite.is-done .news-infinite__status::after {
    content: ""; width: 40px; height: 2px; border-radius: var(--radius-xs); background: var(--fx-line);
}
@media (prefers-reduced-motion: no-preference) {
    .news-infinite__spinner { animation: fx-spin .8s linear infinite; }
    @keyframes fx-spin { to { transform: rotate(360deg); } }
}

/* ---------- Período eleitoral ---------- */
.electoral-bar {
    background: #fff8e6;
    border-bottom: 1px solid #f1d58a;
    color: #4a3b0b;
}
.electoral-bar__inner {
    display: flex;
    align-items: flex-start;
    gap: .9rem;
    padding-top: .85rem;
    padding-bottom: .85rem;
}
.electoral-bar__tag {
    flex: none;
    padding: .2rem .65rem;
    border-radius: var(--radius-pill);
    background: #7a5a00;
    color: #fff;
    font-size: var(--fs-xs);
    letter-spacing: .06em;
    text-transform: uppercase;
    white-space: nowrap;
}
.electoral-bar p { margin: 0; font-size: var(--fs-md); line-height: 1.5; }
@media (max-width: 760px) {
    .electoral-bar__inner { flex-direction: column; gap: .5rem; }
}
body.high-contrast .electoral-bar { background: #000; color: #ff0; border-color: #ff0; }
body.high-contrast .electoral-bar__tag { background: #ff0; color: #000; }

.electoral-notice-page { padding: clamp(3rem, 8vw, 6rem) 0; background: var(--surface); }
.electoral-notice-card {
    max-width: 780px;
    padding: clamp(1.75rem, 5vw, 3rem);
    border-radius: var(--radius-lg);
    background: #fff;
    box-shadow: var(--shadow-lg);
    text-align: center;
}
.electoral-notice-card h1 { margin: .5rem 0 1rem; font-size: clamp(1.6rem, 4vw, 2.3rem); color: var(--fx-ink); }
.electoral-notice-card p { margin: 0 auto; max-width: 60ch; color: var(--ink-2); line-height: 1.7; }
.electoral-notice-actions { display: flex; flex-wrap: wrap; justify-content: center; gap: .75rem; margin-top: 2rem; }

/* ---------- Imagens com carregamento suave ---------- */
@media (prefers-reduced-motion: no-preference) {
    .fx-js img.fx-fade { opacity: 0; transition: opacity .5s ease; }
    .fx-js img.fx-fade.is-loaded { opacity: 1; }
}

/* ---------- Alto contraste: mantém os novos elementos legíveis ---------- */
body.high-contrast .fx-top { background: #000; outline: 2px solid #ff0; color: #ff0; }
body.high-contrast .news-share a,
body.high-contrast .news-share button { background: #000; color: #ff0; border-color: #ff0; }
body.high-contrast .fx-progress span { background: #ff0; }

@media print {
    .fx-top, .fx-progress, .news-share { display: none !important; }
}

/* ---------- Notícia: linha fina e traço de destaque no topo ---------- */
.news-detail .page-heading h1 { margin-bottom: 0; }
.news-subtitle {
    max-width: 60rem;
    margin: .75rem 0 0;
    color: var(--muted);
    font-size: clamp(1.02rem, 1.6vw, 1.2rem);
    font-style: italic;
    line-height: 1.5;
}
.news-detail .news-meta { margin-top: 1.1rem; }
.news-meta strong { color: var(--muted); font-weight: 700; }
.news-heading-bar {
    display: block;
    width: 38px;
    height: 6px;
    margin-top: .9rem;
    border-radius: var(--radius-pill);
    background: var(--green, var(--brand-700));
}

/* ---------- Bloco "Linha do tempo" (construtor de páginas) ---------- */
.block-timeline { padding-top: 1.5rem; padding-bottom: 2rem; }
.tl-nav {
    position: sticky; top: var(--tl-top, 100px); z-index: 5;
    display: flex; gap: .4rem; overflow-x: auto; scrollbar-width: none;
    margin: 0 auto 1.6rem; padding: .5rem; width: max-content; max-width: 100%;
    border: 1px solid var(--line-soft); border-radius: var(--radius-pill);
    background: rgba(255, 255, 255, .92); backdrop-filter: blur(8px);
    box-shadow: var(--shadow-md);
}
.tl-nav::-webkit-scrollbar { display: none; }
.tl-nav a {
    flex: 0 0 auto; padding: .45rem .85rem; border-radius: var(--radius-pill);
    color: var(--ink-2); font-size: var(--fs-sm); font-weight: 700; text-decoration: none; white-space: nowrap;
    transition: background-color .25s ease, color .25s ease;
}
.tl-nav a:hover { background: var(--surface-2); color: var(--green, var(--brand-700)); }
.tl-nav a.is-active { background: var(--green, var(--brand-700)); color: #fff; }
.tl-nav a:focus-visible { outline: 3px solid #ffc658; outline-offset: 2px; }

.tl-wrap { position: relative; }
.tl-line { position: absolute; top: 0; bottom: 0; left: 31px; width: 4px; border-radius: var(--radius-xs); background: var(--line-soft); }
.tl-progress { position: absolute; inset: 0; border-radius: var(--radius-xs); background: linear-gradient(var(--brand-500), var(--brand-700)); transform-origin: top; transform: scaleY(0); }
.block-timeline:not(.tl-js) .tl-progress { transform: scaleY(1); }
.tl { position: relative; margin: 0; padding: 0; list-style: none; }
.tl .timeline-item {
    display: grid; grid-template-columns: 66px minmax(0, 1fr); gap: 1.1rem; align-items: start;
    padding: 0 0 2.2rem; border: 0; scroll-margin-top: 150px;
}
.tl .timeline-item::before { display: none; }
.tl-year {
    position: relative; z-index: 1; display: grid; place-items: center;
    width: 66px; min-height: 66px; padding: .35rem; border-radius: 50%;
    background: #fff; color: var(--green, var(--brand-700)); border: 3px solid var(--line);
    font-size: var(--fs-base); font-weight: 800; line-height: 1.05; text-align: center; overflow-wrap: anywhere;
    box-shadow: 0 0 0 6px #fff; transition: background-color .4s ease, color .4s ease, border-color .4s ease, transform .4s ease;
}
.tl-item.is-reached .tl-year, .block-timeline:not(.tl-js) .tl-year { background: var(--green, var(--brand-700)); color: #fff; border-color: var(--green, var(--brand-700)); }
.tl-item.is-reached .tl-year { transform: scale(1.04); }
.tl-card {
    display: grid; gap: 1rem; padding: 1.25rem 1.35rem; border: 1px solid var(--line-soft); border-radius: var(--radius-lg);
    background: #fff; box-shadow: var(--shadow-lg);
    transition: box-shadow .3s ease, transform .3s ease;
}
.tl-card:hover { box-shadow: var(--shadow-lg); transform: translateY(-2px); }
.tl-text h3 { margin: 0 0 .5rem; color: var(--ink-brand); font-size: clamp(1.08rem, 1.6vw, 1.25rem); line-height: 1.3; }
.tl-text p { margin: 0 0 .7rem; color: var(--ink-2); line-height: 1.7; }
.tl-text p:last-child { margin-bottom: 0; }
.tl-figure { margin: 0; }
/* Moldura 16:10; o enquadramento (posição e zoom) vem do painel em --tl-x, --tl-y e --tl-zoom. */
.tl-frame { display: block; overflow: hidden; border-radius: var(--radius-md); aspect-ratio: 16 / 10; background: var(--surface-2); }
.tl-figure img {
    display: block; width: 100%; height: 100%; object-fit: cover; cursor: zoom-in;
    object-position: var(--tl-x, 50%) var(--tl-y, 50%);
    transform: scale(var(--tl-zoom, 1)); transform-origin: var(--tl-x, 50%) var(--tl-y, 50%);
    filter: sepia(.35) saturate(.85); transition: filter .5s ease, transform .6s ease;
}
.tl-card:hover .tl-figure img, .tl-figure img:focus-visible { filter: none; transform: scale(calc(var(--tl-zoom, 1) * 1.03)); }
.tl-figure figcaption { padding: .5rem .2rem 0; color: var(--muted); font-size: var(--fs-sm); font-style: italic; }

@media (min-width: 961px) {
    .tl-line { left: calc(50% - 2px); }
    .tl .timeline-item { grid-template-columns: minmax(0, 1fr) 84px minmax(0, 1fr); gap: 0 1.6rem; }
    .tl-year { grid-column: 2; grid-row: 1; justify-self: center; width: 76px; min-height: 76px; font-size: var(--fs-base); }
    .tl-card { grid-column: 1; grid-row: 1; }
    .tl .timeline-item:nth-child(even) .tl-card { grid-column: 3; }
    .tl-item--photo .tl-card { grid-template-columns: 1fr; }
}
@media (max-width: 640px) {
    .tl-nav { margin-left: 0; }
    .tl-line { left: 25px; }
    .tl .timeline-item { grid-template-columns: 54px minmax(0, 1fr); gap: .8rem; }
    .tl-year { width: 54px; min-height: 54px; font-size: var(--fs-sm); }
    .tl-card { padding: 1rem; }
}

/* ---------- Bloco "Citação" ---------- */
.block-quote { position: relative; max-width: 54rem; margin: 2.2rem auto; padding: 1.4rem 1.2rem 1.4rem 4.2rem; }
.block-quote::before {
    content: "\201C"; position: absolute; left: .6rem; top: -.6rem;
    color: var(--green, var(--brand-700)); opacity: .25; font: 700 6rem/1 Georgia, "Times New Roman", serif;
}
.block-quote blockquote { margin: 0; }
.block-quote blockquote p { margin: 0; color: var(--ink-brand); font-size: clamp(1.3rem, 2.6vw, 1.9rem); font-weight: 700; line-height: 1.35; font-style: italic; }
.block-quote figcaption { margin-top: .8rem; color: var(--muted); font-size: var(--fs-md); }
.block-quote figcaption::before { content: "— "; }

@media (prefers-reduced-motion: reduce) {
    .tl-progress, .tl-year, .tl-card, .tl-figure img, .tl-nav a { transition: none !important; }
    .tl-card:hover { transform: none; }
    .tl-card:hover .tl-figure img { transform: scale(var(--tl-zoom, 1)); }
}

/* Bloco "Destaque principal": foto de fundo cobrindo a área toda (antes repetia em mosaico). */
.block-hero { background-size: cover; background-position: center; background-repeat: no-repeat; }
.block-hero h1 { max-width: 46rem; font-size: clamp(2.2rem, 5vw, 3.6rem); line-height: 1.05; }
.block-hero p { max-width: 40rem; font-size: clamp(1rem, 1.6vw, 1.2rem); line-height: 1.55; opacity: .95; }

/* ---------- Bloco "Cards com detalhes" ---------- */
.block-cardx { padding-top: 1.5rem; padding-bottom: 1.5rem; }
.cardx-head { margin-bottom: 1.2rem; }
.cardx-head h2 { margin: 0 0 .35rem; color: var(--ink-brand); font-size: clamp(1.35rem, 2.4vw, 1.75rem); }
.cardx-head p { margin: 0; color: var(--muted); max-width: 44rem; }
.cardx-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 250px), 1fr)); gap: 1rem; }
.cardx {
    display: flex; flex-direction: column; gap: .55rem; padding: 1.25rem; border: 1px solid var(--line-soft); border-radius: var(--radius-md);
    background: linear-gradient(180deg, #fff, var(--surface)); box-shadow: var(--shadow-md);
    transition: transform .25s ease, box-shadow .25s ease, border-color .25s ease;
}
.cardx:hover { transform: translateY(-3px); box-shadow: var(--shadow-lg); border-color: var(--line); }
.cardx-icon { display: grid; place-items: center; width: 46px; height: 46px; border-radius: var(--radius-md); background: var(--surface-2); color: var(--green, var(--brand-700)); }
.cardx-icon .site-icon { width: 24px; height: 24px; }
.cardx h3 { margin: .2rem 0 0; color: var(--ink-brand); font-size: var(--fs-base); line-height: 1.3; }
.cardx p { margin: 0; color: var(--muted); font-size: var(--fs-md); line-height: 1.55; }
.cardx-more {
    display: inline-flex; align-items: center; gap: .35rem; margin-top: auto; padding: .45rem 0 0; border: 0; background: none;
    color: var(--green, var(--brand-700)); font: inherit; font-size: var(--fs-md); font-weight: 800; cursor: pointer; align-self: flex-start;
}
.cardx-more .site-icon { width: .9rem; height: .9rem; transition: transform .2s ease; }
.cardx-more:hover .site-icon { transform: translateX(3px); }
.cardx-more:focus-visible, .cardx-dialog__close:focus-visible, .cardx-link:focus-visible { outline: 3px solid #ffc658; outline-offset: 2px; border-radius: var(--radius-sm); }
html.cardx-open { overflow: hidden; }
.cardx-dialog { width: min(640px, calc(100% - 32px)); max-height: min(85vh, 760px); padding: 0; border: 0; border-radius: var(--radius-lg); box-shadow: var(--shadow-lg); }
.cardx-dialog::backdrop { background: rgba(5, 25, 19, .55); backdrop-filter: blur(3px); }
.cardx-dialog[open] { animation: cardx-in .25s ease; }
@keyframes cardx-in { from { opacity: 0; transform: translateY(12px) scale(.98); } to { opacity: 1; transform: none; } }
.cardx-dialog__box { display: flex; flex-direction: column; max-height: inherit; }
.cardx-dialog__head { position: sticky; top: 0; display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: .8rem; padding: 1rem 1.2rem; border-bottom: 1px solid var(--surface-2); background: #fff; }
.cardx-dialog__head h3 { margin: 0; color: var(--ink-brand); font-size: var(--fs-xl); }
.cardx-dialog__close { display: grid; place-items: center; width: 38px; height: 38px; border: 0; border-radius: 50%; background: var(--surface-2); color: var(--ink); cursor: pointer; }
.cardx-dialog__close .site-icon { width: 18px; height: 18px; }
.cardx-dialog__body { overflow-y: auto; padding: 1.1rem 1.3rem 1.4rem; color: var(--ink-2); line-height: 1.65; }
.cardx-dialog__summary { margin-top: 0; color: var(--muted); font-weight: 600; }
.cardx-link { display: inline-flex; align-items: center; gap: .4rem; margin-top: .6rem; padding: .6rem 1rem; border-radius: var(--radius-sm); background: var(--green, var(--brand-700)); color: #fff; font-weight: 700; text-decoration: none; }
.cardx-link .site-icon { width: .95rem; height: .95rem; }
@media (prefers-reduced-motion: reduce) { .cardx, .cardx-more .site-icon { transition: none; } .cardx:hover { transform: none; } .cardx-dialog[open] { animation: none; } }

/* ---------- Bloco "Diagrama de dois eixos" ---------- */
.block-axes { padding-top: 1.5rem; padding-bottom: 2rem; }
.axes { display: grid; grid-template-columns: minmax(0, 1fr) minmax(220px, 300px) minmax(0, 1fr); gap: 1.2rem; align-items: stretch; }
.axes-col { position: relative; padding: 1.3rem; border-radius: var(--radius-lg); }
.axes-col--left { background: linear-gradient(160deg, #fff7ec, #fdf0dc); border: 1px solid #f3dcb9; }
.axes-col--right { background: linear-gradient(160deg, #eef6fc, #e1eef8); border: 1px solid #c9dff0; }
.axes-title { margin: 0 0 1rem; font-size: var(--fs-xl); line-height: 1.2; }
.axes-col--left .axes-title { color: #8a4a06; }
.axes-col--right .axes-title { color: #0c4f7a; }
.axes-tags { display: flex; flex-wrap: wrap; gap: .5rem; margin: 0; padding: 0; list-style: none; }
.axes-tags li {
    padding: .5rem .8rem; border-radius: var(--radius-sm); font-size: var(--fs-md); font-weight: 800; line-height: 1.2;
    box-shadow: var(--shadow-sm); transition: transform .2s ease;
}
.axes-tags li:hover { transform: translateY(-2px); }
.axes-col--left .axes-tags li:nth-child(4n+1) { background: #f7a24a; color: #3d1f00; }
.axes-col--left .axes-tags li:nth-child(4n+2) { background: #fbc067; color: #3d2600; }
.axes-col--left .axes-tags li:nth-child(4n+3) { background: #f8de6b; color: #3a3000; }
.axes-col--left .axes-tags li:nth-child(4n+4) { background: #c7e27a; color: #233300; }
.axes-col--right .axes-tags li:nth-child(4n+1) { background: #2f7fc1; color: #fff; }
.axes-col--right .axes-tags li:nth-child(4n+2) { background: #48a6d8; color: #fff; }
.axes-col--right .axes-tags li:nth-child(4n+3) { background: #1d5f96; color: #fff; }
.axes-col--right .axes-tags li:nth-child(4n+4) { background: #7cc4e8; color: #0b3350; }

.axes-flow { display: flex; flex-direction: column; justify-content: center; gap: .9rem; }
.axes-flow__text { position: relative; margin: 0; padding: .9rem 1rem; border-radius: var(--radius-md); background: #fff; border: 1px solid var(--line-soft); color: var(--ink-2); font-size: var(--fs-md); line-height: 1.5; box-shadow: var(--shadow-md); }
.axes-flow__arrow { display: block; height: 10px; margin-bottom: .45rem; background:
    linear-gradient(currentColor, currentColor) center / calc(100% - 10px) 2px no-repeat; color: var(--green, var(--brand-700)); position: relative; }
.axes-flow__arrow::after { content: ""; position: absolute; top: 50%; width: 9px; height: 9px; border-top: 2px solid currentColor; border-right: 2px solid currentColor; }
.axes-flow__text--ltr .axes-flow__arrow::after { right: 1px; transform: translateY(-50%) rotate(45deg); }
.axes-flow__text--rtl .axes-flow__arrow::after { left: 1px; transform: translateY(-50%) rotate(-135deg); }
.axes-pulse { position: relative; height: 6px; border-radius: var(--radius-sm); background: var(--line-soft); overflow: hidden; }
.axes-pulse span { position: absolute; top: 0; width: 34%; height: 100%; border-radius: var(--radius-sm); background: linear-gradient(90deg, transparent, var(--brand-500), transparent); }
.axes-pulse span:first-child { animation: axes-ltr 2.6s ease-in-out infinite; }
.axes-pulse span:last-child { animation: axes-rtl 2.6s ease-in-out infinite 1.3s; }
@keyframes axes-ltr { from { left: -34%; } to { left: 100%; } }
@keyframes axes-rtl { from { left: 100%; } to { left: -34%; } }

.axes-base { position: relative; margin-top: 2.2rem; padding: 1.3rem 1.5rem; border-radius: var(--radius-lg); text-align: center;
    background: linear-gradient(135deg, var(--brand-800), var(--brand-700) 60%, var(--brand-700)); color: #fff; box-shadow: var(--shadow-lg); }
.axes-base h3 { margin: 0 0 .35rem; color: #fff; font-size: clamp(1.25rem, 2.4vw, 1.7rem); }
.axes-base p { margin: 0 auto; max-width: 52rem; color: rgba(255, 255, 255, .9); line-height: 1.55; }
.axes-base__pillars span { position: absolute; bottom: 100%; width: 3px; height: 2.2rem; background: linear-gradient(var(--line), var(--brand-700)); }
.axes-base__pillars span::before { content: ""; position: absolute; top: -2px; left: 50%; width: 10px; height: 10px; border-top: 3px solid var(--brand-700); border-left: 3px solid var(--brand-700); transform: translateX(-50%) rotate(45deg); }
.axes-base__pillars span:first-child { left: 16%; }
.axes-base__pillars span:last-child { right: 16%; }

@media (max-width: 960px) {
    .axes { grid-template-columns: 1fr; }
    .axes-flow { order: 0; }
    .axes-col--left { order: -1; }
    .axes-col--right { order: 1; }
    .axes-base__pillars span:first-child { left: 30%; }
    .axes-base__pillars span:last-child { right: 30%; }
}
@media (prefers-reduced-motion: reduce) {
    .axes-pulse span { animation: none; left: 33% !important; }
    .axes-tags li { transition: none; }
}

/* ---------- Dúvidas frequentes (bloco FAQ com busca e temas) ---------- */
.faqx { padding-top: .5rem; padding-bottom: 2.5rem; max-width: 980px; }
.faqx-tools { position: sticky; top: var(--faqx-top, 84px); z-index: 5; display: grid; gap: .8rem; padding: 1rem 0 .9rem; background: linear-gradient(#fff 85%, rgba(255,255,255,0)); }
.faqx-search { display: flex; align-items: center; gap: .6rem; padding: .75rem 1rem; border: 1px solid var(--line); border-radius: var(--radius-md); background: #fff; box-shadow: var(--shadow-md); cursor: text; }
.faqx-search:focus-within { border-color: var(--green, var(--brand-700)); box-shadow: 0 0 0 3px rgba(8, 123, 97, .18); }
.faqx-search .site-icon { width: 20px; height: 20px; color: var(--muted); flex-shrink: 0; }
.faqx-search input { flex: 1; min-width: 0; border: 0; outline: 0; background: transparent; font: inherit; font-size: var(--fs-base); color: var(--ink-brand); }
.faqx-topics { display: flex; flex-wrap: wrap; gap: .45rem; }
.faqx-topics button { display: inline-flex; align-items: center; gap: .35rem; padding: .42rem .8rem; border-radius: var(--radius-pill); border: 1px solid var(--line); background: #fff; color: var(--ink-2); font: inherit; font-size: var(--fs-md); font-weight: 700; cursor: pointer; }
.faqx-topics button small { font-size: var(--fs-xs); opacity: .7; }
.faqx-topics button:hover { border-color: var(--green, var(--brand-700)); color: var(--green, var(--brand-700)); }
.faqx-topics button.is-active { background: var(--green, var(--brand-700)); border-color: var(--green, var(--brand-700)); color: #fff; }
.faqx-meta { display: flex; justify-content: space-between; align-items: center; font-size: var(--fs-md); color: var(--muted); }
.faqx-toggle-all { border: 0; background: none; color: var(--green, var(--brand-700)); font: inherit; font-weight: 800; cursor: pointer; padding: .2rem 0; }
.faqx-toggle-all:hover { text-decoration: underline; }

.faqx-list { display: grid; gap: .65rem; }
.faqx-item { border: 1px solid var(--line-soft); border-radius: var(--radius-md); background: #fff; transition: border-color .2s ease, box-shadow .2s ease; scroll-margin-top: 220px; }
.faqx-item:hover { border-color: var(--line-strong); }
.faqx-item[open] { border-color: var(--line-strong); box-shadow: var(--shadow-md); }
.faqx-item:target { outline: 3px solid rgba(8, 123, 97, .25); }
.faqx-item summary { display: flex; align-items: center; gap: .75rem; padding: 1rem 1.15rem; cursor: pointer; list-style: none; }
.faqx-item summary::-webkit-details-marker { display: none; }
.faqx-item summary:focus-visible { outline: 3px solid rgba(8, 123, 97, .35); outline-offset: -3px; border-radius: var(--radius-md); }
.faqx-q { flex: 1; font-weight: 800; font-size: var(--fs-base); color: var(--ink-brand); line-height: 1.35; }
.faqx-tag { flex-shrink: 0; padding: .18rem .55rem; border-radius: var(--radius-pill); background: var(--surface); color: var(--ink-2); font-size: var(--fs-xs); font-weight: 800; }
.faqx-chevron { flex-shrink: 0; width: 30px; height: 30px; border-radius: 50%; background: var(--surface); position: relative; transition: transform .25s ease, background .2s ease; }
.faqx-chevron::before { content: ""; position: absolute; left: 50%; top: 45%; width: 8px; height: 8px; border-right: 2px solid var(--green, var(--brand-700)); border-bottom: 2px solid var(--green, var(--brand-700)); transform: translate(-50%, -50%) rotate(45deg); }
.faqx-item[open] .faqx-chevron { transform: rotate(180deg); background: var(--green, var(--brand-700)); }
.faqx-item[open] .faqx-chevron::before { border-color: #fff; }
.faqx-answer { padding: 0 1.15rem 1.1rem; color: var(--ink-2); line-height: 1.65; animation: faqx-in .25s ease; }
.faqx-answer .rich-content > :first-child { margin-top: 0; }
.faqx-copy { display: inline-flex; align-items: center; gap: .35rem; margin-top: .6rem; padding: .3rem .6rem; border: 1px solid var(--line); border-radius: var(--radius-sm); background: #fff; color: var(--muted); font: inherit; font-size: var(--fs-xs); font-weight: 700; cursor: pointer; }
.faqx-copy:hover { color: var(--green, var(--brand-700)); border-color: var(--green, var(--brand-700)); }
.faqx-copy .site-icon { width: 14px; height: 14px; }
@keyframes faqx-in { from { opacity: 0; transform: translateY(-4px); } to { opacity: 1; transform: none; } }

.faqx-empty { padding: 1.5rem; margin-top: .5rem; border: 1px dashed var(--line); border-radius: var(--radius-md); text-align: center; color: var(--muted); }
.faqx-empty p { margin: .3rem 0 0; }
.faqx-help { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 1rem 1.5rem; margin-top: 2rem; padding: 1.4rem 1.5rem; border-radius: var(--radius-lg);
    background: linear-gradient(135deg, var(--brand-800), var(--brand-700) 60%, var(--brand-700)); color: #fff; box-shadow: var(--shadow-lg); }
.faqx-help strong { display: block; font-size: var(--fs-xl); }
.faqx-help p { margin: .25rem 0 0; max-width: 34rem; color: rgba(255, 255, 255, .88); }
.faqx-help__actions { display: flex; flex-wrap: wrap; align-items: center; gap: .9rem 1.2rem; }
.faqx-help .button-primary { background: #fff; color: var(--brand-800); border-color: #fff; }
.faqx-help__link { display: inline-flex; align-items: center; gap: .35rem; color: #fff; font-weight: 800; text-decoration: none; }
.faqx-help__link:hover { text-decoration: underline; }
.faqx-help__link .site-icon { width: 18px; height: 18px; }

@media (max-width: 640px) {
    .faqx-tag { display: none; }
    .faqx-topics { flex-wrap: nowrap; overflow-x: auto; padding-bottom: .2rem; scrollbar-width: none; }
    .faqx-topics button { flex-shrink: 0; }
}
@media (prefers-reduced-motion: reduce) {
    .faqx-answer { animation: none; }
    .faqx-chevron { transition: none; }
}

/* ---------- Contato: formulário em card + canais ao lado ---------- */
.contact-header { margin-bottom: clamp(1.5rem, 3vw, 2.5rem); }
.contact-layout--split { display: grid; grid-template-columns: minmax(0, 1fr) minmax(280px, 380px); gap: clamp(1.25rem, 3vw, 2.5rem); align-items: start; }
.contact-form--card { max-width: none; padding: clamp(1.25rem, 3vw, 2rem); border: 1px solid var(--line-soft); border-radius: var(--radius-lg); background: #fff; box-shadow: var(--shadow-lg); }
.contact-form__intro h2 { margin: 0; color: var(--ink-brand); font-family: var(--font-display); font-size: var(--fs-xl); letter-spacing: -.02em; }
.contact-form__intro p { margin: .3rem 0 .4rem; color: var(--fx-muted); font-size: var(--fs-base); }
.contact-form--card input, .contact-form--card textarea { border-color: var(--line); border-radius: var(--radius-md); background: var(--surface-0); transition: border-color .2s ease, box-shadow .2s ease, background-color .2s ease; }
.contact-form--card input:hover, .contact-form--card textarea:hover { border-color: var(--line-strong); }
.contact-form--card input:focus, .contact-form--card textarea:focus { border-color: var(--fx-green); background: #fff; box-shadow: 0 0 0 3px rgba(8, 123, 97, .16); }
.contact-form--card .button-primary { display: inline-flex; align-items: center; justify-content: center; gap: .5rem; }
.contact-form--card .button-primary .site-icon { width: 1.05rem; height: 1.05rem; }

.contact-aside { display: grid; gap: 1rem; position: sticky; top: 120px; }
.contact-channels { padding: 1.4rem; border-radius: var(--radius-lg); color: #fff; background: linear-gradient(135deg, var(--brand-800), var(--brand-700) 60%, var(--brand-700)); box-shadow: var(--shadow-lg); }
.contact-channels h2, .contact-shortcuts h2 { margin: 0 0 .8rem; font-family: var(--font-display); font-size: var(--fs-lg); }
.contact-channel { display: flex; align-items: flex-start; gap: .8rem; padding: .75rem 0; border-top: 1px solid rgba(255, 255, 255, .16); color: #fff; text-decoration: none; }
.contact-channel small { display: block; color: rgba(255, 255, 255, .72); font-size: var(--fs-xs); font-weight: 800; letter-spacing: .06em; text-transform: uppercase; }
.contact-channel strong { display: block; font-size: var(--fs-base); font-weight: 600; line-height: 1.4; overflow-wrap: anywhere; }
a.contact-channel:hover strong { text-decoration: underline; }
.contact-channel__icon { display: grid; place-items: center; flex: none; width: 38px; height: 38px; border-radius: var(--radius-md); background: rgba(255, 255, 255, .14); }
.contact-channel__icon .site-icon { width: 20px; height: 20px; }
.contact-shortcuts { padding: 1.4rem; border: 1px solid var(--line-soft); border-radius: var(--radius-lg); background: var(--surface); }
.contact-shortcuts h2 { color: var(--ink-brand); margin-bottom: .2rem; }
.contact-shortcuts p { margin: 0 0 .6rem; color: var(--fx-muted); font-size: var(--fs-md); }
.contact-shortcuts a { display: flex; align-items: center; gap: .6rem; padding: .7rem 0; border-top: 1px solid var(--line-soft); color: var(--ink-brand); font-weight: 700; text-decoration: none; }
.contact-shortcuts a .site-icon { width: 18px; height: 18px; color: var(--fx-green); }
.contact-shortcuts a .site-icon:last-child { margin-left: auto; transition: transform .2s var(--fx-ease); }
.contact-shortcuts a:hover { color: var(--fx-green-dark); }
.contact-shortcuts a:hover .site-icon:last-child { transform: translateX(3px); }
@media (max-width: 960px) {
    .contact-layout--split { grid-template-columns: 1fr; }
    .contact-aside { position: static; }
}

/* ---------- Projeto: cabeçalho, capa, chamada e outros projetos ---------- */
.project-breadcrumb { display: flex; flex-wrap: wrap; align-items: center; gap: .35rem; margin-bottom: .9rem; color: var(--muted); font-size: var(--fs-md); }
.project-breadcrumb a { color: var(--fx-green-dark); font-weight: 700; text-decoration: none; }
.project-breadcrumb a:hover { text-decoration: underline; }
.project-breadcrumb .site-icon { width: .9rem; height: .9rem; opacity: .6; }
.project-body { padding-top: clamp(1.5rem, 3vw, 2.5rem); padding-bottom: clamp(2rem, 4vw, 3.5rem); }
.project-cover { margin: 0 0 1.75rem; overflow: hidden; border-radius: var(--radius-lg); box-shadow: var(--shadow-lg); }
.project-cover .content-cover { display: block; width: 100%; max-height: 520px; margin: 0; object-fit: cover; border-radius: 0; }
.project-cta { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 1rem 1.5rem; margin-top: 2.5rem; padding: 1.4rem 1.5rem; border-radius: var(--radius-lg); color: #fff; background: linear-gradient(135deg, var(--brand-800), var(--brand-700) 60%, var(--brand-700)); box-shadow: var(--shadow-lg); }
.project-cta strong { display: block; font-size: var(--fs-lg); }
.project-cta p { margin: .25rem 0 0; max-width: 34rem; color: rgba(255, 255, 255, .88); }
.project-cta__actions { display: flex; flex-wrap: wrap; align-items: center; gap: .9rem 1.2rem; }
.project-cta .button-primary { display: inline-flex; align-items: center; gap: .45rem; background: #fff; color: var(--brand-800); border-color: #fff; }
.project-cta__link { display: inline-flex; align-items: center; gap: .35rem; color: #fff; font-weight: 800; text-decoration: none; }
.project-cta__link:hover { text-decoration: underline; }
.project-others { padding: clamp(2rem, 4vw, 3rem) 0; background: var(--surface); border-top: 1px solid var(--line-soft); }
.project-others__grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 1rem; margin-top: 1.25rem; }
.project-card { min-height: 0; }
.project-card h3 { margin: .65rem 0 .4rem; color: var(--fx-ink); font-size: var(--fs-lg); line-height: 1.25; }
.project-card p { margin: 0; color: var(--fx-muted); font-size: var(--fs-md); }

/* ---------- Pesquisa: atalhos no estado vazio ---------- */
.search-suggestions { display: flex; flex-wrap: wrap; justify-content: center; gap: .55rem; max-width: 720px; margin: 1.25rem auto 0; }
.search-suggestions a { display: inline-flex; align-items: center; gap: .4rem; padding: .5rem .95rem; border: 1px solid var(--line); border-radius: var(--radius-pill); background: #fff; color: var(--ink-2); font-size: var(--fs-md); font-weight: 700; text-decoration: none; transition: border-color .2s ease, color .2s ease, transform .2s var(--fx-ease), box-shadow .2s ease; }
.search-suggestions a .site-icon { width: 17px; height: 17px; color: var(--fx-green); }
.search-suggestions a:hover, .search-suggestions a:focus-visible { border-color: var(--fx-green); color: var(--fx-green-dark); transform: translateY(-2px); box-shadow: var(--shadow-md); }
.empty-state .search-suggestions .site-icon { width: 17px; height: 17px; }

@media (prefers-reduced-motion: reduce) {
    .contact-shortcuts a .site-icon:last-child, .search-suggestions a { transition: none; }
}

/* =====================================================================
   FASE 1 — ACESSIBILIDADE (WCAG 2.2 AA)
   Camada de garantia: fica no fim da folha carregada por último.
   ===================================================================== */

/* ---------- Anel de foco duplo: visível em fundo claro E escuro ----------
   Amarelo sozinho dá 1,86:1 no branco. O anel interno escuro (box-shadow)
   garante contraste no branco; o amarelo externo garante no verde escuro. */
html body :is(a, button, input, select, textarea, summary, [tabindex]:not([tabindex="-1"])):focus-visible {
    outline: 3px solid var(--focus-outer) !important;
    outline-offset: 2px !important;
    box-shadow: 0 0 0 2px var(--focus-inner) !important;
}
/* Buscas com caixa própria já destacam a caixa inteira via :focus-within. */
html body :is(.faqx-search, .acts-search) input:focus-visible { outline: none !important; box-shadow: none !important; }
html body :is(.faqx-search, .acts-search):focus-within { outline: 3px solid var(--focus-outer); outline-offset: 2px; box-shadow: 0 0 0 2px var(--focus-inner); }


/* ---------- Carrossel: botão de pausar (WCAG 2.2.2) ---------- */
.fucam-banner-pause {
    position: absolute; z-index: 4; right: 1rem; bottom: .7rem;
    display: inline-flex; align-items: center; gap: .5rem;
    min-height: 36px; padding: .45rem .85rem;
    border: 1px solid rgba(255, 255, 255, .45); border-radius: var(--radius-pill);
    background: rgba(0, 24, 20, .55); color: #fff;
    font: 700 var(--fs-sm)/1 var(--font-display);
    cursor: pointer; backdrop-filter: blur(6px);
    transition: background-color .2s ease;
}
.fucam-banner-pause:hover { background: rgba(0, 24, 20, .8); }
.fucam-banner-pause[hidden] { display: none; }
/* Ícone desenhado em CSS: duas barras (pausar) ou triângulo (reproduzir). */
.fucam-banner-pause__icon { position: relative; width: 10px; height: 12px; flex: 0 0 auto; }
.fucam-banner-pause__icon::before, .fucam-banner-pause__icon::after { content: ""; position: absolute; top: 0; width: 3px; height: 12px; border-radius: var(--radius-xs); background: currentColor; }
.fucam-banner-pause__icon::before { left: 0; }
.fucam-banner-pause__icon::after { right: 0; }
.fucam-banner-pause.is-paused .fucam-banner-pause__icon::before { width: 0; height: 0; border-radius: 0; background: none; border-style: solid; border-width: 6px 0 6px 10px; border-color: transparent transparent transparent currentColor; }
.fucam-banner-pause.is-paused .fucam-banner-pause__icon::after { display: none; }
@media (max-width: 760px) {
    .fucam-banner-pause { right: .75rem; bottom: .55rem; width: 40px; height: 40px; padding: 0; justify-content: center; }
    .fucam-banner-pause__label { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
}

/* ---------- Alvos de toque mínimos (WCAG 2.5.8: 24×24px) ---------- */
/* Indicadores do carrossel: o ponto continua pequeno, a área clicável cresce. */
html body .fucam-banner-dots { gap: 0; }
html body .fucam-banner-dots button { box-sizing: content-box !important; border: 8px solid transparent !important; background-clip: content-box !important; }

/* Botão da busca e links do rodapé. */
html body .site-search button { top: 50% !important; right: .35rem !important; display: grid; place-items: center; width: 36px; height: 36px; padding: 0; transform: translateY(-50%); border-radius: var(--radius-sm); }
html body .site-footer a { padding-block: .2rem; }


/* =====================================================================
   FASE 3 — COMPONENTES
   ===================================================================== */

/* ---------- Botões: um único sistema (primário, secundário, inverso) ----------
   Mesma altura (44px), raio, tipografia e hover em todo o portal.
   .legacy-outline-button e .legacy-news-arrow ficam fora de propósito:
   são temáveis em Aparência → Componentes visuais. */
.fucam-public-v46 :is(.button, .fucam-banner-button, .home-mission-inner > a, .home-v4-header-quick) {
    display: inline-flex; align-items: center; justify-content: center; gap: .5rem;
    min-height: 44px; padding: .65rem 1.15rem;
    border: 1.5px solid transparent; border-radius: var(--radius-sm);
    font-family: var(--font-display); font-size: var(--fs-md); font-weight: 700; line-height: 1.2;
    letter-spacing: 0; text-transform: none; text-decoration: none; white-space: nowrap;
    cursor: pointer; filter: none;
    transition: background-color var(--dur) ease, border-color var(--dur) ease, color var(--dur) ease, transform var(--dur) var(--ease-out), box-shadow var(--dur) var(--ease-out);
}
.fucam-public-v46 :is(.button, .fucam-banner-button, .home-mission-inner > a, .home-v4-header-quick) .site-icon { width: 1rem; height: 1rem; transition: transform var(--dur) var(--ease-out); }
.fucam-public-v46 :is(.button, .fucam-banner-button, .home-mission-inner > a):hover .site-icon:last-child { transform: translateX(3px); }

/* Primário: verde da marca (5,2:1) → hover mais escuro (6,3:1). */
.fucam-public-v46 :is(.button-primary, .fucam-banner-button--primary, .home-v4-header-quick) { background: var(--brand-700); border-color: var(--brand-700); color: var(--white); }
.fucam-public-v46 :is(.button-primary, .fucam-banner-button--primary, .home-v4-header-quick):hover,
.fucam-public-v46 .home-v4-header-quick[aria-expanded="true"] { background: var(--brand-750); border-color: var(--brand-750); color: var(--white); transform: translateY(-1px); box-shadow: var(--shadow-sm); }

/* Secundário: contorno verde sobre fundo claro. */
.fucam-public-v46 .button-secondary { background: transparent; border-color: var(--brand-700); color: var(--brand-700); }
.fucam-public-v46 .button-secondary:hover { background: var(--brand-100); color: var(--brand-800); }

/* Sobre fundo escuro (banner, faixas verdes): secundário vira contorno claro e o
   botão da faixa institucional vira "inverso" (branco com texto verde). */
.fucam-public-v46 .fucam-banner-button--secondary { background: rgba(1, 42, 36, .35); border-color: rgba(255, 255, 255, .6); color: var(--white); }
.fucam-public-v46 .fucam-banner-button--secondary:hover { background: rgba(1, 42, 36, .6); border-color: var(--white); }
.fucam-public-v46 .home-mission-inner > a,
.fucam-public-v46 :is(.project-cta, .faqx-help) .button-primary { background: var(--white); border-color: var(--white); color: var(--brand-800); }
.fucam-public-v46 .home-mission-inner > a:hover,
.fucam-public-v46 :is(.project-cta, .faqx-help) .button-primary:hover { background: var(--brand-100); border-color: var(--brand-100); color: var(--brand-900); transform: translateY(-1px); }

@media (prefers-reduced-motion: reduce) {
    .fucam-public-v46 :is(.button, .fucam-banner-button, .home-mission-inner > a, .home-v4-header-quick),
    .fucam-public-v46 :is(.button, .fucam-banner-button, .home-mission-inner > a, .home-v4-header-quick) .site-icon { transition: none; transform: none !important; }
}

/* ---------- Cabeçalho ---------- */
.search-toggle { display: none; }
.home-v4-header-quick__icon { display: none; }

/* Mobile: cabeçalho compacto em UMA linha (~64px) — logo | busca | acesso rápido | menu.
   A busca abre abaixo sob demanda; o painel de acesso rápido ocupa a largura útil. */
@media (max-width: 760px) {
    body.fucam-public-v46 .header-inner { position: relative; display: flex; flex-wrap: wrap; align-items: center; gap: .4rem; min-height: 64px; padding: .5rem 0; }
    body.fucam-public-v46 .site-header .brand { order: 0; margin-right: auto; }
    body.fucam-public-v46 .site-header .brand-logo { width: 128px; max-height: 40px; }

    body.fucam-public-v46 .search-toggle,
    body.fucam-public-v46 .home-v4-header-quick,
    body.fucam-public-v46 .menu-toggle {
        display: inline-flex; align-items: center; justify-content: center; gap: .4rem;
        min-width: 44px; min-height: 44px; margin: 0; padding: 0 .7rem;
        border: 1px solid rgba(255, 255, 255, .35); border-radius: var(--radius-sm);
        background: rgba(255, 255, 255, .08); color: var(--white);
        font-family: var(--font-display); font-size: var(--fs-md); font-weight: 700;
        cursor: pointer;
    }
    body.fucam-public-v46 .search-toggle { order: 1; padding: 0; }
    body.fucam-public-v46 .search-toggle .site-icon { width: 1.25rem; height: 1.25rem; }
    body.fucam-public-v46 .search-toggle[aria-expanded="true"] { background: var(--white); color: var(--brand-900); }

    body.fucam-public-v46 .home-v4-header-quick-wrap { position: static; order: 2; margin: 0; }
    body.fucam-public-v46 .home-v4-header-quick { padding: 0; background: var(--brand-700); border-color: var(--brand-700); }
    body.fucam-public-v46 .home-v4-header-quick__icon { display: block; width: 1.2rem; height: 1.2rem; }
    body.fucam-public-v46 .home-v4-header-quick__chevron { display: none; }
    body.fucam-public-v46 .home-v4-header-quick__label { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
    body.fucam-public-v46 .home-v4-quick-popover { left: 0; right: 0; top: calc(100% + 6px); width: auto; max-height: calc(100dvh - 90px); }

    body.fucam-public-v46 .menu-toggle { order: 3; }

    body.fucam-public-v46 .site-search { display: none; order: 4; flex: 1 1 100%; width: 100%; max-width: none; margin: .25rem 0 .2rem; }
    body.fucam-public-v46 .site-header.is-search-open .site-search { display: block; }
    body.fucam-public-v46 .main-nav { order: 5; }
}

/* =====================================================================
   FASE 4 — PÁGINAS
   ===================================================================== */

/* ---------- Títulos: tracking que não cola as palavras ----------
   -0,045em a 50px tirava ~2px de cada espaço ("IELunem"). */
body.fucam-public-v46 :is(.page-heading h1, .news-archive-header h1, .units-hero h1, .fucam-banner-copy :is(h1, h2), .legacy-hero-copy :is(h1, h2), .news-archive-hero h1, .news-archive-hero h2) { letter-spacing: var(--tracking-tight); word-spacing: .06em; }
body.fucam-public-v46 :is(.section-heading h2, .legacy-section-heading h2, .home-mission-inner h2) { letter-spacing: -.015em; }

/* ---------- Home: painel "Acesso rápido" do banner ----------
   Desde a v4.3 o acesso rápido vive no cabeçalho. No banner ele sobrava como bloco
   de texto escuro sobre fundo escuro (invisível, mas lido por leitores de tela). */
.fucam-home-v4 .fucam-banner-quick { display: none; }

/* ---------- Home: banner proporcional no celular ----------
   Antes: 500px+ de gradiente vazio acima do título no mobile. */
@media (max-width: 760px) {
    .fucam-home-v4 .legacy-hero-panel.fucam-banner-slide { min-height: min(400px, 58svh); padding: 1.6rem 1.25rem 3.6rem; align-content: end; }
}

/* ---------- Home: notícias em layout editorial (1 destaque + 3 compactas) ---------- */
.fucam-home-v4 .legacy-news-grid.is-editorial { grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr); grid-template-rows: repeat(3, auto); gap: 1rem clamp(1rem, 1.8vw, 1.5rem); }
.fucam-home-v4 .legacy-news-grid.is-editorial > :first-child { grid-row: 1 / span 3; }
.fucam-home-v4 .legacy-news-grid.is-editorial > :first-child .legacy-news-cover { aspect-ratio: 16 / 10; }
.fucam-home-v4 .legacy-news-grid.is-editorial > :first-child h3 { font-size: var(--fs-2xl); line-height: 1.22; }
.fucam-home-v4 .legacy-news-grid.is-editorial > :first-child .legacy-news-content { padding: 1.25rem 1.4rem 1.35rem; gap: .6rem; }
.fucam-home-v4 .legacy-news-grid.is-editorial > :not(:first-child) { flex-direction: row; }
.fucam-home-v4 .legacy-news-grid.is-editorial > :not(:first-child) .legacy-news-cover { flex: 0 0 38%; aspect-ratio: auto; min-height: 150px; }
.fucam-home-v4 .legacy-news-grid.is-editorial > :not(:first-child) :is(.legacy-news-cover > span, .legacy-news-arrow) { display: none; }
.fucam-home-v4 .legacy-news-grid.is-editorial > :not(:first-child) .legacy-news-content { padding: .9rem 1rem; }
.fucam-home-v4 .legacy-news-grid.is-editorial > :not(:first-child) .legacy-news-content p { -webkit-line-clamp: 2; line-clamp: 2; }
.fucam-home-v4 .legacy-news-grid.is-editorial > :not(:first-child) h3 { font-size: var(--fs-base); }
@media (max-width: 960px) {
    .fucam-home-v4 .legacy-news-grid.is-editorial { grid-template-columns: minmax(0, 1fr); grid-template-rows: none; }
    .fucam-home-v4 .legacy-news-grid.is-editorial > :first-child { grid-row: auto; }
}
@media (max-width: 520px) {
    .fucam-home-v4 .legacy-news-grid.is-editorial > :first-child h3 { font-size: var(--fs-xl); }
    .fucam-home-v4 .legacy-news-grid.is-editorial > :not(:first-child) .legacy-news-cover { flex-basis: 34%; min-height: 120px; }
    .fucam-home-v4 .legacy-news-grid.is-editorial > :not(:first-child) .legacy-news-content p { display: none; }
}

/* ---------- Matérias: largura e ritmo de leitura ---------- */
.news-detail .page-heading h1 { max-width: 28ch; text-wrap: balance; }
.news-detail .news-subtitle { max-width: 60ch; }
.news-detail .block-text { max-width: 880px; }
.news-detail .rich-content { max-width: var(--measure); font-size: var(--fs-lg); line-height: 1.7; }
.news-detail .rich-content :is(h2, h3) { margin-top: 2rem; color: var(--ink-brand); font-family: var(--font-display); letter-spacing: -.01em; line-height: 1.25; }
.news-detail .rich-content :is(p, li) { text-wrap: pretty; }

/* ---------- Transições entre páginas (substituem a sensação de "recarregar") ---------- */
@media (prefers-reduced-motion: no-preference) {
    @view-transition { navigation: auto; }
    ::view-transition-old(root), ::view-transition-new(root) { animation-duration: 220ms; }
}
