/* Estilos Globais */
body {
    font-family: 'Inter', sans-serif; /* Usando uma fonte moderna, pode ser ajustada */
    padding-bottom: 0; /* sem espaço adicional abaixo */
}

/* Header (replica estilo do site sem usar stylePrincipal) */
.header-content { background: #04162C; border-bottom: 2px solid; border-image: linear-gradient(90deg, #0FE 0%, #D429B7 100%) 1; padding: 20px 0;}
.header-content .navbar { background: transparent; padding-top: .75rem; padding-bottom: .75rem; }
.header-content .navbar-brand .mblogo { max-height: 61px; height: auto; width: auto; }
/* Links do menu principal (desktop e mobile) */
.header-content .navbar-dark .navbar-nav .nav-link,
.header-content .nav-link,
.header-content .fzWhiteDrop {
    color: #fff;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.02em;
    line-height: 1.1;
    padding: .25rem .75rem;
    font-size: 1rem;
}
.header-content .navbar-dark .navbar-nav .nav-link:hover { color: #fff !important; }
.header-content .dropdown-item:hover { color: #00E4E9; }
.header-content .dropdown-menu { background: #04162C; color: #fff; border: none; max-height: 280px; overflow-y: auto; scrollbar-width: thin; scrollbar-color: rgba(255,255,255,.3) #04162C; }
@supports selector(::-webkit-scrollbar) {
  .header-content .dropdown-menu::-webkit-scrollbar { width: 6px; }
  .header-content .dropdown-menu::-webkit-scrollbar-track { background: #04162C; }
  .header-content .dropdown-menu::-webkit-scrollbar-thumb { background: rgba(255,255,255,.3); border-radius: 4px; }
  .header-content .dropdown-menu::-webkit-scrollbar-button { display: none; }
}
.header-content .dropdown-item { color: #fff; font-weight: 600;text-wrap: auto }
.header-content .dropdown-toggle::after {
    border-top: .3em solid #fff; /* caret branco */
    border-right: .3em solid transparent;
    border-left: .3em solid transparent;
    opacity: 1;
}
.header-content .offcanvas.header-mobile-background { background: #04162C; color: #fff; }
/* Layout do offcanvas: vira menu horizontal no desktop */
@media (min-width: 992px) {
    .header-content .offcanvas {
        position: static;
        visibility: visible;
        transform: none;
        background: transparent;
        height: auto;
    }
    /* Container do nav alinhado e com espaçamento dos itens */
    .header-content .navbar .container {
        justify-content: flex-start;
        align-items: center;
        gap: 48px;
    }
    .header-content .navbar-brand { margin-right: 8px; }
    .header-content .offcanvas .navbar-nav {
        flex-direction: row;
        gap: 32px;
        align-items: center;
        display: flex;
        justify-content: space-around;
    }
    .header-content .navbar-toggler { display: none; }
    .header-content .dropdown-menu { margin-top: 0.5rem; }
}
.close-navbar-mobile { position: absolute; top: 10px; right: 10px; filter: invert(1); }
.header-content .close-navbar-mobile { display: none; }
@media (max-width: 991px) {
    .header-content .offcanvas { z-index: 1045; padding: 16px 12px; }
    .header-content .offcanvas .navbar-nav { flex-direction: column; gap: 12px; padding: 8px 6px; }
    .header-content .offcanvas .nav-link { padding: 8px 4px; }
    .header-content .offcanvas.show .close-navbar-mobile { display: block; top: 12px; right: 12px; z-index: 1060; pointer-events: auto; }
    /* Margem lateral no mobile para respiro visual do header */
    .header-content .navbar { margin: 0 10px; }
}
.fz300 { font-weight: 300; }
.dBullet-navbar { color: #00E4E9; margin-right: 6px; }
/* Sem bolinha nos itens do dropdown do header */
.header-content .dropdown-menu .dBullet-navbar { display: none !important; }
/* Texto menor na segunda linha dos itens do menu */
.header-content .nav-link .fz300 { font-size: .875rem; opacity: .9; }

/* Wrapper principal da página de notícias para evitar sobreposição com o footer */
.noticias-main {
    display: flow-root;
    padding-bottom: 3rem; /* Espaço extra antes do footer */
    position: relative;
    z-index: 10; /* garante que o conteúdo fique acima de qualquer overlay */
    background: #ffffff;
    margin-bottom: 4rem;
    overflow: visible; /* evita scroll interno duplicado */
    isolation: isolate; /* separa contexto de empilhamento */
}

/* Compensação do header na página de artigo */
.noticias-article { padding-top: 120px; }
/* Mobile: remover espaço extra no topo */
@media (max-width: 991px) {
    .noticias-article { padding-top: 0; }
}

/* Garante margem inferior suficiente nas seções de conteúdo das notícias */
.noticias-main > section.container {
    margin-bottom: 4rem !important;
}

/* Footer custom das notícias */
.noticias-footer {
    position: relative;
    clear: both;
    margin-top: 6rem;
    z-index: 0;
}
.noticias-footer .nt-white-background { background-color: #fff; padding: 12px 0; }
.noticias-footer .nt-blue-background { background-color: #051830; color: #fff; padding: 8px 0; }

/* Hardening contra regras globais (position fixed/absolute genéricas) */
.noticias-footer,
.noticias-footer .nt-white-background,
.noticias-footer .nt-blue-background {
    position: relative !important;
    top: auto !important;
    bottom: auto !important;
    left: auto !important;
    right: auto !important;
}

/* Espaço dedicado antes do footer nas páginas de notícias */
.footer-spacer {
    height: 120px;
}

.noticias-footer-spacer { height: 0; }

/* Ajuste extra de respiro para conteúdos longos */
@media (max-width: 991px) {
    .noticias-main { padding-bottom: 4rem; }
}
@media (min-width: 992px) {
    .noticias-main { padding-bottom: 5rem; }
}

/* Banner */
.banner-principal {
  background-image: url('../image/noticias.png');
  background-position: center;
  background-size: cover;
  background-repeat: no-repeat;
  width: 100%;
  min-height: 450px;
}
@media (max-width: 575.98px) {
    .header-content{
        padding: 10px 0;
    }
  .banner-principal {
    background-image: url('../image/noticias-mb.png');
    background-position: center;
    background-size: cover;
    background-repeat: no-repeat;
    min-height: 140px;
  }
}

/* Seção de Pesquisa e Artigos */
.section-title {
    font-weight: 700;
    color: #333;
    margin-bottom: 20px;
}

/* Breadcrumb de notícias */
.breadcrumb-noticias { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin: 0 0 8px; font-weight: 700; color: #1b1b1b; }
.breadcrumb-noticias a { color: #1b1b1b; text-decoration: none; }
.breadcrumb-noticias a:hover { text-decoration: underline; }
.breadcrumb-noticias .bc-current { font-weight: 700; color: #333; }
.breadcrumb-noticias .bc-sep { display: inline-flex; align-items: center; justify-content: center; }
.breadcrumb-noticias .bc-sep svg { width: 14px; height: 14px; fill: #666; }
@media (max-width: 575.98px) { .breadcrumb-noticias { gap: 4px; font-weight: 600; } }

/* Componente de Busca */
.search-component { display: flex; align-items: center; gap: 12px; margin-bottom: 24px; }
.search-component { flex-wrap: nowrap; }
.search-component .search-dropdown { width: 240px; }
.search-component .flex-grow-1 { flex: 1; }

.search-component .dropdown-toggle { border-right: 0; border-radius: 10px; }
.btn-buscar-categoria { height: 56px !important; padding: 0 16px !important; display: inline-flex; align-items: center; justify-content: center; }
.search-dropdown .dropdown-toggle.dropdown-toggle-split::after { border-top: .3em solid #04162C; border-right: .3em solid transparent; border-left: .3em solid transparent; }

/* Botão de busca à esquerda do input */
.search-input-group .btn-buscar-trigger { background: #fff !important; border: 1px solid #ced4da !important; border-radius: 10px 0 0 10px !important; width: 56px; height: 56px; display: inline-flex; align-items: center; justify-content: center; }

.btn-buscar-categoria {
    background-color: #FFD700;
    color: #04162C;
    font-weight: 700;
    border: none;
    height: 100%;
    border-radius: 10px 0 0 10px;
    text-transform: uppercase;
}
/* Hover/active do botão amarelo: permanece amarelo (sem branco) */
.btn-buscar-categoria:hover,
.btn-buscar-categoria:focus,
.btn-buscar-categoria:active,
.btn-check:checked + .btn-buscar-categoria,
.show > .btn-buscar-categoria.dropdown-toggle {
    background-color: #F2C500 !important; /* amarelo ligeiramente mais escuro */
    color: #04162C !important;
    border-color: #F2C500 !important;
}

.search-input-group .input-group-text { background: #fff !important; border: 1px solid #ced4da !important; border-radius: 10px 0 0 10px !important; }
.search-input-group .input-group-text { display: flex; align-items: center; justify-content: center; line-height: 1; }
.search-component .form-control { border: 1px solid #ced4da !important; border-radius: 0 10px 10px 0 !important; height: 56px !important; }
.search-component .input-busca { background: #fff !important; text-transform: uppercase; }
.search-component .input-busca::placeholder { text-transform: uppercase; letter-spacing: .04em; color: #7c7c7c; }

/* removido botão extra à direita do input */

/* Grupo do input com botão (overlay) */
.search-input-group { position: relative; width: 100%; }
.search-input-group .btn-buscar-submit {
    border: 1px solid #ced4da !important;
    background: #fff !important;
    display: inline-flex !important;
    align-items: center; justify-content: center;
    width: 56px; height: 56px; border-radius: 0 10px 10px 0 !important;
    cursor: pointer;
}

/* Desktop: duas colunas (botão + input) com ícone embutido no input */
@media (min-width: 576px) {
    .search-component { flex-direction: row !important; }
    /* Mostrar botão de buscar também no desktop */
    .search-input-group .btn-buscar-submit { display: inline-flex !important; }
    .btn-buscar-categoria.dropdown-toggle::after { border-top: .3em solid #04162C !important; border-right: .3em solid transparent; border-left: .3em solid transparent; }
    /* Dropdown com largura do botão e estilo mais visível */
    .search-dropdown .dropdown-menu { width: 100% !important; min-width: 240px; border: 1px solid #ced4da; border-radius: 10px; padding: 6px 0; box-shadow: 0 6px 18px rgba(0,0,0,.08); }
    .search-dropdown .dropdown-item { font-weight: 700; color: #04162C; padding: 10px 16px; }
    .search-dropdown .dropdown-item:hover { background: #f8f9fa; }
}

/* Usabilidade no celular: empilhado, alvos grandes e margem lateral */
@media (max-width: 575.98px) {
    .search-component { flex-direction: column !important; align-items: stretch !important; padding: 12px !important; margin: 0 10px 24px !important; border: 1px solid #ced4da !important; border-radius: 12px !important; background: #fff !important; }
    .search-dropdown { width: 100% !important; }
    .search-component .dropdown-toggle { border-right: 0 !important; border-radius: 10px !important; width: 100% !important; height: 52px !important; }
    .btn-buscar-categoria { border-radius: 10px !important; width: 100% !important; height: 52px !important; }
    .search-input-group { display: flex !important; flex-wrap: nowrap !important; align-items: center !important; width: 100% !important; }
    .search-input-group .btn-buscar-trigger { height: 52px !important; border-radius: 10px 0 0 10px !important; flex: 0 0 52px !important; }
    .search-component .form-control { width: auto !important; min-width: 0 !important; height: 52px !important; border-radius: 0 10px 10px 0 !important; flex: 1 1 0 !important; }

/* Resultados de busca (mock) */
/* Estilo similar ao buscador da home */
.autoBusca2 {
    max-width: 1315px;
    width: 100%;
    display: block;
    position: relative;
    background: #10409e;
    color: #fff;
    font-size: 12px;
    font-weight: 700;
    border-radius: 3px;
    margin-top: 10px;
    max-height: 400px;
    overflow-y: auto;
    z-index: 999;
}
.autoBusca2 p { cursor: pointer; padding: 10px 20px; margin: 0; border-bottom: dashed 1px #0b2f75; font-size: 15px; font-weight: 500; }
.autoBusca2 p:last-child { border-bottom: none; }
.autoBusca2 p:hover { background: rgba(255,255,255,0.08); }
    .search-component .dropdown-menu { width: 100% !important; max-height: 240px; overflow-y: auto; }
}

/* Forçar layout ideal dentro das páginas de notícias (maior especificidade) */
@media (min-width: 576px) {
  .noticias-main .search-component { border: 0 !important; background: transparent !important; box-shadow: none !important; height: 56px !important; }
}

/* Artigos por Categoria */
.category-title-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background-color: #002347; /* Cor azul escuro do print */
    color: white;
    padding: 10px 20px;
    border-radius: 5px;
    margin-bottom: 20px;
    position: relative;
    z-index: 10;
}

.category-title-container h3 {
    margin: 0;
    font-size: 1.2rem;
    font-weight: bold;
}
/* Seta ao lado do título da categoria */
.category-title-container .cat-arrow { display: inline-flex; align-items: center; justify-content: center; margin-left: 8px; }
.category-title-container .cat-arrow svg { width: 16px; height: 16px; }

/* Cards de Artigo */
.article-card {
    border: 1px solid #ddd;
    border-radius: 8px;
    overflow: hidden;
    transition: box-shadow 0.3s ease;
}

.article-card:hover {
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
}

.article-card img {
    width: 100%;
    height: auto;
}

.article-card .card-body {
    padding: 15px;
}

.article-card .card-tag {
    font-size: 0.8rem;
    color: #555;
    margin-bottom: 5px;
}

.article-card .card-date {
    font-size: 0.8rem;
    color: #888;
    margin-bottom: 10px;
    float: none !important; /* evita impacto no fluxo do card */
}

.article-card .card-title {
    font-size: 1.1rem;
    font-weight: bold;
    margin-bottom: 15px;
    min-height: 60px; /* Para alinhar os botões */
}

/* Cabeçalho do card (tag + data) com layout estável */
.article-card .card-body .mb-2 {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

/* Garante que grids de posts limpem qualquer float residual */
.posts-grid::after {
    content: '';
    display: block;
    clear: both;
}
.posts-grid { position: relative; z-index: 10; }

/* Slider de artigos (desktop e mobile) */
.article-slider { margin-bottom: 0px; }
.article-slider .slider-viewport { overflow: hidden; position: relative; padding-right: 56px; }
.article-slider .slider-track { display: flex; flex-wrap: nowrap; gap: 16px; transition: transform 0.4s ease; will-change: transform; }
@media (min-width: 992px) { .article-slider .slider-track > .col-md-3 { flex: 0 0 calc(25% - 12px); } }
@media (min-width: 576px) and (max-width: 991px) { .article-slider .slider-track > .col-md-3 { flex: 0 0 calc(50% - 12px); } }
@media (max-width: 575.98px) { .article-slider .slider-track > .col-md-3 { flex: 0 0 100%; } }
.article-slider .slider-dots { display: flex; gap: 6px; justify-content: center; align-items: center; margin-top: 10px; }
.article-slider .slider-dot { width: 24px; height: 6px; background: #ddd; border-radius: 4px; cursor: pointer; }
.article-slider .slider-dot.active { background: #999; }
.category-title-container .next-slide { cursor: pointer; }

/* Botão circular de avanço sobre o último card (desktop) */
.article-slider .slider-next-btn { position: absolute; right: 8px; top: 50%; transform: translateY(-50%); width: 42px; height: 42px; border-radius: 50%; border: 1px solid #ced4da; background: #fff; display: none; align-items: center; justify-content: center; box-shadow: 0 2px 8px rgba(0,0,0,.1); cursor: pointer; z-index: 50; }
.article-slider .slider-next-btn svg { width: 20px; height: 20px; }
@media (min-width: 992px) { .article-slider .slider-next-btn { display: flex; } }
@media (max-width: 575.98px) {
  .article-slider .slider-next-btn { display: flex; }
  .article-slider .slider-prev-btn { display: none; }
  .article-slider .slider-dots { display: none; }
  .article-slider .slider-viewport { padding-right: 6px; }
  .nt-white-background { margin: 20px; }
}

/* Botão circular de retorno (prev) */
.article-slider .slider-prev-btn { position: absolute; left: 8px; top: 50%; transform: translateY(-50%); width: 42px; height: 42px; border-radius: 50%; border: 1px solid #ced4da; background: #fff; display: none; align-items: center; justify-content: center; box-shadow: 0 2px 8px rgba(0,0,0,.1); cursor: pointer; z-index: 50; }
.article-slider .slider-prev-btn svg { width: 20px; height: 20px; transform: rotate(180deg); }

/* Mobile: transformar grid em carrossel horizontal tocável */
@media (max-width: 575.98px) {
    .posts-grid {
        display: flex;
        flex-wrap: nowrap;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        gap: 12px;
        padding: 6px 10px 10px;
        margin: 0;
        scroll-snap-type: x mandatory;
    }
    .posts-grid > .col-md-3 {
        flex: 0 0 80% !important;
        max-width: 80% !important;
        scroll-snap-align: start;
    }
    .posts-grid::-webkit-scrollbar { height: 6px; }
    .posts-grid::-webkit-scrollbar-thumb { background: #cfcfcf; border-radius: 3px; }
    /* Categoria: exibir grid "normal" com paginação (sem carrossel) */
    .categoria-grid { display: grid !important; grid-template-columns: 1fr !important; gap: 16px !important; overflow-x: visible !important; scroll-snap-type: none !important; padding: 0 !important; }
}

.article-card .btn-leia-mais {
    background-color: #8A2BE2; /* Roxo do print */
    color: white;
    font-weight: bold;
    width: 100%;
    padding: 10px;
    border: none;
    border-radius: 5px;
}

.btn-ver-todos {
    background-color: #FFD700; /* Amarelo do print */
    color: #333;
    font-weight: bold;
    padding: 10px 30px;
    border: none;
    border-radius: 5px;
    display: block;
    margin: 20px auto 10px; /* respiro extra para não tocar o footer */
}

/* Paginação custom da categoria */
.nt-pagination { display: flex; justify-content: center; align-items: center; gap: 10px; margin: 20px 0 40px; }
.nt-pagination .nt-page-btn { background: #fff; color: #04162C; border: 1px solid #ced4da; border-radius: 8px; padding: 8px 12px; font-weight: 700; cursor: pointer; }
.nt-pagination .nt-page-btn:hover { background: #f8f9fa; }
.nt-pagination .nt-page-btn[disabled] { opacity: .5; cursor: not-allowed; }
.nt-pagination .nt-page-list { display: flex; gap: 8px; }
.nt-pagination .nt-page-num { background: #fff; color: #04162C; border: 1px solid #ced4da; border-radius: 8px; padding: 8px 12px; font-weight: 700; cursor: pointer; }
.nt-pagination .nt-page-num.active { background: #FFD700; color: #04162C; border-color: #FFD700; }

/* Grid da categoria: responsivo com até 5 colunas (desktop) */
.categoria-grid { display: grid; grid-template-columns: repeat(5, 1fr); gap: 16px; }
.categoria-grid > .col-md-3 { width: auto !important; max-width: 100% !important; }
@media (max-width: 1399.98px) { .categoria-grid { grid-template-columns: repeat(4, 1fr); } }
@media (max-width: 991.98px) { .categoria-grid { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 767.98px) { .categoria-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 575.98px) { .categoria-grid { grid-template-columns: repeat(2, 1fr); } }
/* Hover/active do botão amarelo de "Ver todos": manter amarelo (não ficar branco) */
.btn-ver-todos:hover,
.btn-ver-todos:focus,
.btn-ver-todos:active,
.btn-check:checked + .btn-ver-todos,
.show > .btn-ver-todos.dropdown-toggle {
    background-color: #F2C500 !important; /* amarelo ligeiramente mais escuro */
    color: #333 !important;
    border-color: #F2C500 !important;
    text-decoration: none;
}

/* Tipografia básica do rodapé de notícias */
.noticias-footer .tituloRodape { font-weight: bold; font-size: 16px; border-bottom: 1px solid #000; padding-bottom: 10px; text-transform: uppercase; max-width: 300px; }
.noticias-footer .lirodape { list-style: none; margin: 8px 0; }
.noticias-footer .atxtrodape { color: #000; text-decoration: none; font-weight: 600; }
.noticias-footer .atxtrodape:hover { color: #333; }
.noticias-footer .txtDir { font-size: 12px; }
.noticias-footer .txtPol { color: #fff; text-decoration: underline; }
/* Texto Portaria, ReclameAqui e Acreditamos */
.noticias-footer .porttxt { color: #d42929; font-weight: 700; text-transform: uppercase; }
.noticias-footer .txtrodape { color: #1b1b1b; display: inline-block; max-width: 420px; }
.noticias-footer .bordaReclameAqui { border-bottom: 1px solid #000; padding-bottom: 10px; }
.noticias-footer .text-footer-acreditamos { font-style: italic; color: #1b2a3a; }
