/* =============================== */
/*   CSS Exclusivo: Ler Mais da Notícia   */
/* =============================== */

/* Contêiner principal da página - Altere aqui a largura máxima */
.noticia-ler-mais-container {
    width: 100%;
    max-width: var(--site-max-width, 1400px) !important;
    margin-left: auto;
    margin-right: auto;
    box-sizing: border-box;
    padding-left: var(--site-container-padding, 1.5rem) !important;
    padding-right: var(--site-container-padding, 1.5rem) !important;
}

/* ---------- Faixa de título ---------- */
.noticia-hero {
    background: linear-gradient(120deg, #0D3B66 0%, #175394 100%);
    padding: 2rem 0 5.5rem;
    position: relative;
}

.noticia-hero::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    height: 4px;
    background: linear-gradient(90deg, #1A8C5B 0 33.33%, #1A5EA8 33.33% 66.66%, #F9C846 66.66% 100%);
}

.noticia-breadcrumb {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.8125rem;
    color: #BFD4EA;
    margin-bottom: 1rem;
}

.noticia-breadcrumb a {
    color: #BFD4EA;
    text-decoration: none;
    transition: color 0.2s;
}

.noticia-breadcrumb a:hover {
    color: #ffffff;
}

.noticia-breadcrumb i {
    font-size: 0.55rem;
    opacity: 0.7;
}

.noticia-breadcrumb span {
    color: #ffffff;
    font-weight: 500;
}

.news-category-badge {
    display: inline-flex;
    align-items: center;
    padding: 0.35rem 0.75rem;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    border-radius: 8px;
    background-color: #F9C846;
    color: #0D3B66 !important;
}

.news-tag-pill {
    display: inline-flex;
    align-items: center;
    font-size: 0.75rem;
    padding: 0.35rem 0.75rem;
    font-weight: 600;
    border-radius: 8px;
    line-height: 1;
}

.article-main-title {
    color: #ffffff !important;
    font-size: clamp(1.6rem, 3.2vw, 2.75rem);
    font-weight: 800;
    letter-spacing: -0.02em;
    line-height: 1.2;
    max-width: 60rem;
    margin: 0;
    background: none !important;
}

/* ---------- Layout em duas colunas ---------- */
.noticia-ler-mais-main {
    background-color: #F8FAFC;
    padding-bottom: 4rem;
    min-height: 60vh;
}

.noticia-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 360px;
    gap: 2rem;
    align-items: start;
    position: relative;
}

.noticia-coluna-principal {
    min-width: 0;
}

/* ---------- Linha de data e compartilhar (dentro da faixa) ---------- */
.noticia-hero-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 1rem 2rem;
    margin-top: 1.5rem;
    padding-top: 1.25rem;
    border-top: 1px solid rgba(255, 255, 255, 0.15);
}

.noticia-hero-info {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.5rem 1.25rem;
    font-size: 0.9375rem;
    color: #DBEAFE;
}

.noticia-hero-info span {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.noticia-hero-info span + span::before {
    content: "";
    width: 4px;
    height: 4px;
    border-radius: 50%;
    background: #BFD4EA;
    margin-right: 0.75rem;
    opacity: 0.7;
}

.noticia-hero-info i {
    color: #F9C846;
}

.noticia-hero-compartilhar {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.noticia-hero-compartilhar-rotulo {
    font-size: 0.8125rem;
    color: #BFD4EA;
    margin-right: 0.25rem;
}

.noticia-hero .compartilhar-redondo {
    position: relative;
    width: 38px;
    height: 38px;
    padding: 0;
    gap: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.12);
    border: 1px solid rgba(255, 255, 255, 0.25);
    color: #ffffff;
    font-size: 1rem;
    box-shadow: none;
    text-decoration: none;
    cursor: pointer;
    transition: background-color 0.2s, border-color 0.2s, transform 0.2s;
}

.noticia-hero .compartilhar-redondo i {
    color: inherit;
}

.noticia-hero .compartilhar-redondo:hover,
.noticia-hero .compartilhar-redondo:focus-visible {
    background: rgba(255, 255, 255, 0.24) !important;
    border-color: rgba(255, 255, 255, 0.5) !important;
    color: #ffffff !important;
    box-shadow: none !important;
    transform: translateY(-2px);
    outline: none;
}

.noticia-hero .compartilhar-redondo:focus-visible {
    box-shadow: 0 0 0 3px rgba(249, 200, 70, 0.6) !important;
}

.noticia-hero .compartilhar-mais {
    background: #F9C846;
    border-color: #F9C846;
    color: #0D3B66;
}

.noticia-hero .compartilhar-mais:hover,
.noticia-hero .compartilhar-mais:focus-visible {
    background: #FCD766 !important;
    border-color: #FCD766 !important;
    color: #0D3B66 !important;
}

.noticia-hero .compartilhar-mais:hover i {
    color: #0D3B66 !important;
    transform: none;
}

/* Aviso "Link copiado" */
.compartilhar-aviso {
    position: absolute;
    top: calc(100% + 10px);
    left: 50%;
    transform: translate(-50%, -4px);
    white-space: nowrap;
    background: #0F172A;
    color: #ffffff;
    font-size: 0.75rem;
    font-weight: 500;
    padding: 0.35rem 0.65rem;
    border-radius: 8px;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.2s, transform 0.2s;
    z-index: 5;
}

.compartilhar-aviso:empty {
    display: none;
}

.compartilhar-redondo.copiado .compartilhar-aviso {
    opacity: 1;
    transform: translate(-50%, 0);
}

.compartilhar-redondo.copiado {
    background: #1A8C5B !important;
    border-color: #1A8C5B !important;
}

/* Banner: mesma proporção do corte feito no admin (crop_imagem.js → banner 4.64:1, 1920×414) */
.article-banner-wrapper {
    position: relative;
    margin: -3.5rem 0 2rem;
    border-radius: 12px;
    overflow: hidden;
    background: #E2E8F0;
    border: 1px solid #E2E8F0;
    box-shadow: 0 16px 40px -14px rgba(0, 45, 86, 0.35);
    aspect-ratio: 4.64 / 1;
}

.article-banner-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.article-card {
    background: #ffffff;
    border: 1px solid #E2E8F0;
    border-radius: 12px;
    padding: 2.5rem;
    box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.04), 0 4px 6px -2px rgba(0, 0, 0, 0.02);
}

.article-body {
    color: #334155;
    font-size: 1.125rem;
    line-height: 1.85;
    font-family: 'Roboto', system-ui, -apple-system, 'Segoe UI', sans-serif;
    max-width: 48rem;
    margin-left: auto;
    margin-right: auto;
    text-rendering: optimizeLegibility;
    -webkit-font-smoothing: antialiased;
    overflow-wrap: break-word;
}

.article-body > * + * {
    margin-top: 1.5rem;
}

.article-body::before {
    content: "";
    display: block;
    width: 40px;
    height: 4px;
    border-radius: 2px;
    background: #F9C846;
    margin-bottom: 1.75rem;
}

.article-footer {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    margin-top: 2.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid #E2E8F0;
}

.article-voltar {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.875rem;
    font-weight: 600;
    color: #175394;
    text-decoration: none;
}

.article-voltar i {
    font-size: 0.75rem;
    transition: transform 0.2s;
}

.article-voltar:hover i {
    transform: translateX(-3px);
}

.botao-compartilhar-secundario {
    border-radius: 8px;
    box-shadow: none;
}

/* ---------- Lateral ---------- */
.noticia-lateral {
    position: sticky;
    top: 110px; /* abaixo do cabeçalho fixo do portal (94px) */
}

.noticia-lateral-fixa {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
}

.recentes-card {
    background: #ffffff;
    border: 1px solid #E2E8F0;
    border-radius: 12px;
    padding: 1.5rem;
    box-shadow: 0 6px 20px -8px rgba(13, 59, 102, 0.18);
}

.lateral-titulo {
    font-size: 1.125rem;
    font-weight: 700;
    color: #0F172A;
    border-left: 4px solid #F9C846;
    padding-left: 0.75rem;
    text-align: left !important;
    margin: 0 0 1rem;
    line-height: 1.3;
}

.recentes-lista {
    list-style: none;
    margin: 0;
    padding: 0;
}

.recentes-lista li + li {
    border-top: 1px solid #F1F5F9;
}

.recente-item {
    display: flex;
    gap: 0.875rem;
    padding: 0.875rem 0;
    text-decoration: none;
    color: inherit;
}

.recente-thumb {
    flex: 0 0 96px;
    height: 72px;
    border-radius: 8px;
    overflow: hidden;
    background: linear-gradient(135deg, #175394, #1A8C5B);
}

.recente-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.3s ease;
}

.recente-item:hover .recente-thumb img {
    transform: scale(1.06);
}

.recente-info {
    display: flex;
    flex-direction: column;
    gap: 0.2rem;
    min-width: 0;
}

.recente-categoria {
    font-size: 0.6875rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: #1A8C5B;
}

.recente-titulo {
    font-size: 0.875rem;
    font-weight: 600;
    line-height: 1.35;
    color: #0F172A;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    transition: color 0.2s;
}

.recente-item:hover .recente-titulo {
    color: #175394;
}

.recente-data {
    font-size: 0.75rem;
    color: #94A3B8;
}

.recentes-ver-todas {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    margin-top: 0.5rem;
    padding: 0.625rem;
    border-radius: 8px;
    background: #EFF6FF;
    color: #175394;
    font-size: 0.8125rem;
    font-weight: 600;
    text-decoration: none;
    transition: background-color 0.2s;
}

.recentes-ver-todas:hover {
    background: #DBEAFE;
}

.lateral-cta {
    background: linear-gradient(120deg, #0D3B66 0%, #175394 100%);
    border-radius: 12px;
    padding: 1.5rem;
    color: #ffffff;
}

.lateral-cta-sobretitulo {
    display: block;
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: #F9C846;
    margin-bottom: 0.5rem;
}

.lateral-cta-titulo {
    font-size: 1.25rem;
    font-weight: 700;
    line-height: 1.3;
    margin: 0 0 1rem;
    color: #ffffff;
}

.lateral-cta-botao {
    display: inline-flex;
    padding: 0.55rem 1.25rem;
    border-radius: 8px;
    background: #F9C846;
    color: #0D3B66;
    font-size: 0.875rem;
    font-weight: 700;
    text-decoration: none;
    transition: filter 0.2s;
}

.lateral-cta-botao:hover {
    filter: brightness(1.05);
    color: #0D3B66;
}

.article-body p {
    margin-bottom: 1.25rem;
}

.article-body p:last-child {
    margin-bottom: 0;
}

/* Restauração e Suporte a Formatações do Editor Rich Text / WYSIWYG */
.article-body h1 {
    font-size: 2.25rem !important;
    font-weight: 800 !important;
    margin-top: 1.75rem;
    margin-bottom: 0.75rem;
    color: #0f172a !important;
    line-height: 1.2;
}

.article-body h2 {
    font-size: 1.75rem !important;
    font-weight: 700 !important;
    margin-top: 1.5rem;
    margin-bottom: 0.75rem;
    color: #0f172a !important;
    line-height: 1.25;
}

.article-body h3 {
    font-size: 1.5rem !important;
    font-weight: 700 !important;
    margin-top: 1.25rem;
    margin-bottom: 0.5rem;
    color: #0f172a !important;
    line-height: 1.3;
}

.article-body h4 {
    font-size: 1.25rem !important;
    font-weight: 700 !important;
    margin-top: 1.25rem;
    margin-bottom: 0.5rem;
    color: #0f172a !important;
    line-height: 1.35;
}

.article-body h5 {
    font-size: 1.1rem !important;
    font-weight: 600 !important;
    margin-top: 1rem;
    margin-bottom: 0.5rem;
    color: #0f172a !important;
}

.article-body h6 {
    font-size: 1rem !important;
    font-weight: 600 !important;
    margin-top: 1rem;
    margin-bottom: 0.5rem;
    color: #0f172a !important;
}

/* Negrito, Itálico, Sublinhado e Riscado */
.article-body b,
.article-body strong {
    font-weight: 700 !important;
}

.article-body i,
.article-body em {
    font-style: italic !important;
}

.article-body u {
    text-decoration: underline !important;
}

.article-body s,
.article-body strike,
.article-body del {
    text-decoration: line-through !important;
}

/* Suporte à tag <font size="..."> tradicional do editor HTML */
.article-body font[size="1"] { font-size: 0.75rem !important; }
.article-body font[size="2"] { font-size: 0.875rem !important; }
.article-body font[size="3"] { font-size: 1rem !important; }
.article-body font[size="4"] { font-size: 1.25rem !important; }
.article-body font[size="5"] { font-size: 1.5rem !important; }
.article-body font[size="6"] { font-size: 2rem !important; }
.article-body font[size="7"] { font-size: 2.5rem !important; }

.article-body big { font-size: 1.25em !important; }
.article-body small { font-size: 0.85em !important; }

/* Links */
.article-body a {
    color: #0284c7;
    text-decoration: underline;
    font-weight: 600;
    transition: color 0.2s ease;
}

.article-body a:hover {
    color: #0369a1;
}

/* Imagens no Corpo do Texto */
.article-body img {
    max-width: 100%;
    height: auto;
    border-radius: 0.75rem;
    margin: 1.5rem auto;
    display: block;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

/* Citações e Listas */
.article-body blockquote {
    border-left: 4px solid #0284c7;
    background-color: #f8fafc;
    padding: 1rem 1.25rem;
    margin: 1.5rem 0;
    border-radius: 0 0.75rem 0.75rem 0;
    font-style: italic;
    color: #475569;
}

.article-body ul {
    list-style-type: disc !important;
    padding-left: 1.5rem !important;
    margin-bottom: 1.25rem;
}

.article-body ol {
    list-style-type: decimal !important;
    padding-left: 1.5rem !important;
    margin-bottom: 1.25rem;
}

.article-body li {
    margin-bottom: 0.5rem;
}

/* Suporte a Tabelas e Mídias no Editor */
.article-body table {
    display: block;
    width: 100%;
    max-width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    margin: 1.25rem 0;
    border-collapse: collapse;
}

.article-body iframe {
    max-width: 100%;
}

/* ===================================================== */
/*   Tipografia editorial (sobrepõe o básico do editor)   */
/* ===================================================== */

/* Parágrafo de abertura (classe aplicada pelo script da página) */
.article-body p.article-lead {
    font-size: 1.3125rem;
    line-height: 1.65;
    font-weight: 500;
    color: #0F172A;
}

.article-body p.article-lead::first-letter {
    float: left;
    font-size: 4.6rem;
    line-height: 0.82;
    font-weight: 900;
    color: #175394;
    margin: 0.42rem 0.65rem 0 0;
}

/* Destaque em negrito com efeito marca-texto */
.article-body strong,
.article-body b {
    font-weight: 700;
    color: #0F172A;
    background-image: linear-gradient(transparent 62%, rgba(249, 200, 70, 0.45) 62%);
    padding: 0 0.1em;
    -webkit-box-decoration-break: clone;
    box-decoration-break: clone;
}

.article-body h1 strong, .article-body h2 strong, .article-body h3 strong,
.article-body blockquote strong, .article-body .article-citacao strong {
    background-image: none;
    padding: 0;
}

/* Links */
.article-body a {
    color: #175394;
    font-weight: 600;
    text-decoration: underline;
    text-decoration-color: rgba(23, 83, 148, 0.35);
    text-decoration-thickness: 2px;
    text-underline-offset: 4px;
    transition: text-decoration-color 0.2s, color 0.2s;
}

.article-body a:hover {
    color: #0D3B66;
    text-decoration-color: #F9C846;
}

/* Citação: <blockquote> do editor ou parágrafo inteiro entre aspas */
.article-body blockquote,
.article-body .article-citacao {
    position: relative;
    margin: 2rem 0 !important;
    padding: 1.5rem 1.75rem 1.5rem 4.25rem;
    background: #EFF6FF;
    border: none;
    border-left: 5px solid #175394;
    border-radius: 12px;
    font-size: 1.25rem;
    line-height: 1.6;
    font-style: italic;
    font-weight: 500;
    color: #0D3B66;
    quotes: none;
}

.article-body blockquote::before,
.article-body .article-citacao::before {
    content: "\201C";
    position: absolute;
    left: 1.1rem;
    top: 0.6rem;
    font-size: 4.5rem;
    line-height: 1;
    font-style: normal;
    font-weight: 900;
    color: #F9C846;
}

.article-body blockquote p {
    margin: 0;
}

/* Listas com marcadores da identidade do portal */
.article-body ul,
.article-body ol {
    list-style: none !important;
    padding-left: 0 !important;
    margin-left: 0 !important;
}

.article-body ul > li,
.article-body ol > li {
    position: relative;
    padding-left: 2.25rem;
    margin-bottom: 0.65rem;
}

.article-body ul > li::before {
    content: "\2713";
    position: absolute;
    left: 0;
    top: 0.3em;
    width: 1.4rem;
    height: 1.4rem;
    border-radius: 50%;
    background: #DCFCE7;
    color: #1A8C5B;
    font-size: 0.75rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
}

.article-body ol {
    counter-reset: item-noticia;
}

.article-body ol > li {
    counter-increment: item-noticia;
}

.article-body ol > li::before {
    content: counter(item-noticia);
    position: absolute;
    left: 0;
    top: 0.3em;
    width: 1.4rem;
    height: 1.4rem;
    border-radius: 50%;
    background: #175394;
    color: #ffffff;
    font-size: 0.75rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Imagens e legendas */
.article-body img {
    max-width: 100%;
    height: auto;
    border-radius: 12px;
    box-shadow: 0 12px 30px -12px rgba(13, 59, 102, 0.3);
    margin: 1rem 0;
    display: block;
}

.article-body figure {
    margin: 2rem 0;
}

.article-body figcaption {
    margin-top: 0.75rem;
    text-align: center;
    font-size: 0.875rem;
    font-style: italic;
    color: #64748B;
}

/* Separador */
.article-body hr {
    border: none;
    height: 4px;
    width: 120px;
    margin: 2.5rem auto;
    background: linear-gradient(90deg, #1A8C5B 0 30%, transparent 30% 35%, #1A5EA8 35% 65%, transparent 65% 70%, #F9C846 70% 100%);
    border-radius: 2px;
}

/* Tabelas */
.article-tabela-rolagem {
    overflow-x: auto;
    border-radius: 12px;
    border: 1px solid #E2E8F0;
}

.article-body table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.95rem;
}

.article-body th {
    background: #0D3B66;
    color: #ffffff;
    font-weight: 600;
    text-align: left;
}

.article-body th,
.article-body td {
    padding: 0.7rem 1rem;
    border-bottom: 1px solid #E2E8F0;
}

.article-body tbody tr:nth-child(even) {
    background: #F8FAFC;
}

/* Título de seção (bloco "título" da redação) */
.article-section-title {
    font-size: 1.625rem !important;
    font-weight: 900 !important;
    color: #0F172A !important;
    line-height: 1.3;
    letter-spacing: -0.01em;
    margin-top: 2.75rem !important;
    padding-bottom: 0.75rem;
    position: relative;
    border: none;
}

.article-section-title::after {
    content: "";
    position: absolute;
    left: 0;
    bottom: 0;
    width: 56px;
    height: 4px;
    border-radius: 2px;
    background: #175394;
}

.article-section-title + * {
    margin-top: 1.25rem !important;
}

/* Marca de fim do texto */
.article-fim {
    display: flex;
    justify-content: center;
    gap: 0.4rem;
    margin-top: 2.5rem;
}

.article-fim span {
    width: 36px;
    height: 4px;
    border-radius: 2px;
}

.article-fim span:nth-child(1) { background: #1A8C5B; }
.article-fim span:nth-child(2) { background: #1A5EA8; }
.article-fim span:nth-child(3) { background: #F9C846; }

/* ---------- Responsivo ---------- */
@media (max-width: 1024px) {
    .noticia-layout {
        grid-template-columns: minmax(0, 1fr);
    }

    .noticia-lateral {
        position: static;
    }
}

@media (max-width: 640px) {
    .noticia-hero {
        padding: 1.5rem 0 3rem;
    }

    .article-banner-wrapper {
        margin: -2rem 0 1.25rem;
        border-radius: 8px;
    }

    .noticia-layout {
        gap: 1.5rem;
    }

    .article-card {
        padding: 1.25rem;
    }

    .article-body {
        font-size: 1rem;
        line-height: 1.7;
    }

    .article-section-title {
        font-size: 1.35rem !important;
    }

    .article-body p.article-lead {
        font-size: 1.125rem;
    }

    .article-body p.article-lead::first-letter {
        font-size: 3.6rem;
    }

    .article-body blockquote,
    .article-body .article-citacao {
        font-size: 1.0625rem;
        padding: 1.25rem 1.25rem 1.25rem 3.5rem;
    }

    .article-body blockquote::before,
    .article-body .article-citacao::before {
        left: 0.75rem;
        font-size: 3.5rem;
    }

    .noticia-hero-meta {
        flex-direction: column;
        align-items: flex-start;
    }

    .noticia-hero-info {
        font-size: 0.875rem;
    }
}
