/* ========== NOTÍCIAS (home, listagem e detalhe) ========== */
/* Cards de notícia na home */
.news {
    background: #f5f6f8;
    padding: var(--section-space-y) 0 var(--section-space-y);
    margin-top: 0;
}
.news__ler-todas {
    position: absolute;
    left: 10px;
    bottom: 18px;
    z-index: 3;
    font-weight: 600;
    font-size: clamp(16px, 1vw, 18px);
    color: #000000;
}
.news__ler-todas:hover {
    text-decoration: underline;
    color: var(--blue-800);
}
.news .carousel__nav--prev {
    left: auto;
    right: 52px;
}
.news .carousel__nav--next {
    left: auto;
    right: 10px;
}
.news-grid {
    margin-top: 12px;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: clamp(12px, 1.1vw, 16px);
    align-items: stretch;
}
@media (max-width: 1100px) {
    .news-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}
@media (max-width: 720px) {
    .news-grid {
        grid-template-columns: 1fr;
    }
}

/* Carrossel: todos os slides com a mesma altura (a do card mais alto da linha) */
.news .carousel__track--overlap {
    align-items: stretch;
}
.news .carousel__slide--item {
    display: flex;
    align-self: stretch;
}
.news .carousel__slide--item .news-card {
    flex: 1 1 auto;
    width: 100%;
    height: 100%;
    min-height: 0;
}

@media (min-width: 981px) {
    .news .carousel__track--overlap .carousel__slide--item {
        flex: 0 0 calc((100% - 48px) / 4);
    }
}

.news-card {
    position: relative;
    background: #fff;
    border-radius: 10px;
    overflow: hidden;
    border: 1px solid rgba(15, 34, 48, 0.06);
    width: 100%;
    display: flex;
    flex-direction: column;
    text-decoration: none;
    transition: box-shadow 0.2s ease;
}
.news-card:hover {
    box-shadow: 0 10px 22px rgba(0, 0, 0, 0.08);
}
.news-card__media {
    background: rgba(0, 58, 141, 0.08);
    flex: 0 0 auto;
    aspect-ratio: 16 / 9;
    overflow: hidden;
}
.news-card__media img {
    width: 100%;
    height: 100%;
    max-width: none;
    object-fit: cover;
    object-position: center;
    display: block;
}
.news-card__body {
    padding: 12px 12px 14px;
    flex: 1 1 auto;
    display: flex;
    flex-direction: column;
    min-height: 0;
    background: #fff;
    transition: background 0.2s ease;
}
.news-card:hover .news-card__body {
    background: var(--blue-800);
}
.news-card__title {
    --news-title-lines: 3;
    --news-title-lh: 1.28;
    font-weight: 700;
    font-size: clamp(16px, 0.95vw, 18px);
    margin: 0 0 1px;
    color: var(--blue-800);
    transition: color 0.2s ease;
    line-height: var(--news-title-lh);
    flex: 0 0 auto;
    display: -webkit-box;
    -webkit-line-clamp: var(--news-title-lines);
    line-clamp: var(--news-title-lines);
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
    word-break: break-word;
    min-height: calc(var(--news-title-lh) * var(--news-title-lines) * 1em);
    max-height: calc(var(--news-title-lh) * var(--news-title-lines) * 1em);
}
.news-card__published {
    font-size: clamp(12px, 0.75vw, 14px);
    color: var(--muted);
    line-height: 1.35;
    margin-bottom: 6px;
    flex: 0 0 auto;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    transition: color 0.2s ease;
}
.news-card__excerpt {
    font-size: clamp(13px, 0.85vw, 15px);
    color: var(--muted);
    line-height: 1.45;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    transition: color 0.2s ease;
}
.news-card__more {
    margin-top: auto;
    padding-top: 6px;
    flex-shrink: 0;
    font-size: clamp(14px, 0.9vw, 16px);
    font-weight: 300;
    color: var(--blue-800);
    text-decoration: none;
    align-self: flex-start;
    transform-origin: left center;
    transition:
        color 0.2s ease,
        text-decoration 0.15s ease,
        transform 0.15s ease;
}
.news-card:hover .news-card__title,
.news-card:hover .news-card__published,
.news-card:hover .news-card__excerpt,
.news-card:hover .news-card__more {
    color: #fff;
}
.news-card:hover .news-card__more {
    text-decoration: underline;
    transform: scale(1.04);
}
.news-card__more:hover {
    text-decoration: underline;
    transform: scale(1.04);
}
.news-card--empty {
    padding: 18px;
    color: var(--muted);
}

@media (max-width: 980px) {
    .news__ler-todas {
        position: relative;
        left: auto;
        bottom: auto;
        margin-top: 10px;
        display: inline-block;
    }
}

@media (max-width: 720px) {
    .news-card__media {
        aspect-ratio: 16 / 8.5;
    }
    .news-card__title {
        --news-title-lines: 3;
    }
    .news-card__excerpt {
        -webkit-line-clamp: 3;
        line-clamp: 3;
    }
}


/* News list */
.news-list-page {
    background: #fff;
}
.news-list-page > section > .container,
.news-detail > section > .container {
    width: min(var(--container), 96vw);
    max-width: none;
    padding-left: 0;
    padding-right: 0;
}

.news-list-page__hero {
    padding: var(--section-space-y) 0 22px;
}

.news-list-page__title {
    margin: 0;
    font-size: 32px;
    line-height: 1.1;
    color: var(--blue-900);
}

.news-list-page__subtitle {
    margin: 10px 0 0;
    color: var(--muted);
    font-size: 14px;
}

.news-list-page__content {
    padding: 18px 0 var(--section-space-y-lg);
}

.news-list-page__list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    gap: 10px;
}

.news-list-page__item {
    border: 1px solid rgba(15, 34, 48, 0.08);
    border-radius: 12px;
    background: #fff;
    overflow: hidden;
}

.news-list-page__link {
    display: grid;
    gap: 6px;
    padding: 14px 16px;
    text-decoration: none;
}

.news-list-page__link:hover {
    background: rgba(0, 58, 141, 0.06);
}

.news-list-page__date {
    font-size: 12px;
    color: var(--muted);
}

.news-list-page__item-title {
    font-size: 17px;
    line-height: 1.35;
    font-weight: 700;
    color: var(--ink);
}

.news-list-page__empty {
    color: var(--muted);
    margin: 0;
    padding: 10px 0;
}

.news-list-page__pagination {
    display: flex;
    gap: 16px;
    margin-top: 18px;
}

.news-list-page__page-link {
    font-size: 14px;
    font-weight: 300;
    color: var(--blue-800);
    text-decoration: none;
}

.news-list-page__page-link:hover {
    text-decoration: underline;
}

@media (max-width: 720px) {
    .news-list-page__title {
        font-size: 26px;
    }
    .news-list-page__item-title {
        font-size: 15px;
    }
}


/* News detail */
.news-detail {
    background: #fff;
}
.news-detail__hero {
    padding: var(--section-space-y) 0 22px;
}
.news-detail__date {
    margin: 0 0 8px;
    font-size: 12px;
    color: var(--muted);
}
.news-detail__title {
    margin: 0;
    font-size: 32px;
    line-height: 1.1;
    color: var(--blue-900);
}
.news-detail__subtitle {
    margin: 10px 0 0;
    max-width: 780px;
    font-size: 18px;
    font-weight: 300;
    color: var(--ink);
}
.news-detail__gallery-section {
    padding: 22px 0 18px;
}
.news-detail__gallery-section .carousel__stage {
    max-width: 960px;
    margin: 0 auto;
}
.news-detail__gallery-section .carousel__track {
    justify-content: flex-start;
}
.news-detail__gallery-section .carousel__slide {
    flex: 0 0 100%;
    max-width: 100%;
}
.news-detail__gallery-section .carousel__stage {
    padding-bottom: 0;
}
.news-detail__gallery-section .carousel__nav {
    top: 50%;
    bottom: auto;
    transform: translateY(-50%);
    background: rgba(232, 232, 232, 0.88);
    color: #111111;
    border-color: rgba(0, 0, 0, 0.32);
}
.news-detail__gallery-section .carousel__nav--prev {
    left: -54px;
}
.news-detail__gallery-section .carousel__nav--next {
    left: auto;
    right: -54px;
}
.news-detail__figure {
    margin: 0;
    border-radius: 10px;
    overflow: hidden;
    background: rgba(0, 58, 141, 0.08);
    border: 1px solid rgba(15, 34, 48, 0.06);
}
.news-detail__figure img {
    width: 100%;
    max-height: 520px;
    object-fit: cover;
}
.news-detail__caption {
    padding: 10px 12px;
    font-size: 12px;
    color: var(--muted);
    background: #fff;
}
.news-detail__thumbs {
    margin-top: 14px;
    display: flex;
    justify-content: center;
    gap: 12px;
    flex-wrap: wrap;
}
.news-detail__thumb {
    width: 68px;
    height: 68px;
    border: 1px solid #d8d8d8;
    background: #fff;
    padding: 2px;
    border-radius: 4px;
    cursor: pointer;
    opacity: 0.45;
    filter: grayscale(0.12);
    transition:
        opacity 0.2s ease,
        border-color 0.2s ease,
        filter 0.2s ease,
        transform 0.2s ease;
}
.news-detail__thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}
.news-detail__thumb.is-active {
    opacity: 1;
    border-color: #7f7f7f;
    filter: none;
    transform: translateY(-1px);
}
.news-detail__thumb:hover {
    opacity: 0.85;
    filter: none;
}
.news-detail__content-section {
    padding: 24px 0 var(--section-space-y-lg);
}
.news-detail__content {
    width: 100%;
    font-size: 16px;
    line-height: 1.7;
    color: #1f2a36;
}
.news-detail__content p {
    margin: 0 0 14px;
}
@media (max-width: 720px) {
    .news-detail__title {
        font-size: 26px;
    }
    .news-detail__subtitle {
        font-size: 17px;
    }
    .news-detail__gallery-section .carousel__nav--prev {
        left: 6px;
    }
    .news-detail__gallery-section .carousel__nav--next {
        right: 6px;
    }
}

