/* ==========================================================================
   SE AGRÍCOLA — NOTÍCIAS
   Layout editorial moderno, responsivo e acessível
   ========================================================================== */


/* ==========================================================================
   1. PÁGINA
   ========================================================================== */

.noticia-page {
    position: relative;
    overflow: hidden;
    padding: 3.5rem 0 5rem;
    background:
            radial-gradient(
                    circle at 7% 5%,
                    rgba(234, 179, 8, 0.12),
                    transparent 25rem
            ),
            radial-gradient(
                    circle at 95% 9%,
                    rgba(22, 101, 52, 0.08),
                    transparent 24rem
            ),
            linear-gradient(
                    180deg,
                    #fffdf7 0%,
                    #f6f8f4 44%,
                    #ffffff 100%
            );
}

.noticia-page::before,
.noticia-page::after {
    content: "";
    position: absolute;
    border-radius: 50%;
    pointer-events: none;
}

.noticia-page::before {
    top: -180px;
    right: -170px;
    width: 430px;
    height: 430px;
    border: 1px solid rgba(22, 101, 52, 0.07);
}

.noticia-page::after {
    bottom: 10%;
    left: -190px;
    width: 340px;
    height: 340px;
    background: rgba(234, 179, 8, 0.025);
}

.noticia-page .container {
    position: relative;
    z-index: 1;
}


/* ==========================================================================
   2. HERO EDITORIAL
   ========================================================================== */

.noticia-hero {
    position: relative;
    display: grid;
    grid-template-columns: minmax(0, 1.45fr) minmax(285px, 0.55fr);
    align-items: stretch;
    gap: 1.5rem;
    margin-bottom: 2.25rem;
}

.noticia-hero-copy {
    position: relative;
    padding: clamp(2rem, 4vw, 3.7rem);
    overflow: hidden;
    border: 1px solid rgba(22, 101, 52, 0.09);
    border-radius: 30px;
    background:
            linear-gradient(
                    130deg,
                    rgba(255, 255, 255, 0.97),
                    rgba(250, 253, 247, 0.94)
            );
    box-shadow:
            0 24px 60px rgba(15, 23, 42, 0.075),
            0 3px 12px rgba(15, 23, 42, 0.035);
}

.noticia-hero-copy::after {
    content: "";
    position: absolute;
    right: -80px;
    bottom: -100px;
    width: 260px;
    height: 260px;
    border-radius: 50%;
    background: rgba(22, 101, 52, 0.04);
}

.noticia-eyebrow {
    position: relative;
    z-index: 1;
    display: inline-flex;
    align-items: center;
    gap: 0.55rem;
    margin-bottom: 1.1rem;
    padding: 0.48rem 0.82rem;
    border: 1px solid rgba(22, 101, 52, 0.13);
    border-radius: 999px;
    background: rgba(22, 101, 52, 0.06);
    color: var(--primary-dark, #14532d);
    font-size: 0.72rem;
    font-weight: 850;
    letter-spacing: 0.09em;
    text-transform: uppercase;
}

.noticia-eyebrow::before {
    content: "";
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: var(--accent-color, #eab308);
    box-shadow: 0 0 0 4px rgba(234, 179, 8, 0.15);
}

.noticia-hero .section-title {
    position: relative;
    z-index: 1;
    max-width: 760px;
    margin: 0;
    color: #143421;
    font-size: clamp(2.1rem, 5vw, 4rem);
    font-weight: 900;
    line-height: 1.02;
    letter-spacing: -0.055em;
}

.noticia-hero .section-title strong {
    display: block;
    color: var(--primary, #166534);
    font-weight: inherit;
}

.noticia-hero .section-description {
    position: relative;
    z-index: 1;
    max-width: 650px;
    margin: 1.25rem 0 0;
    color: var(--text-muted, #64748b);
    font-size: clamp(0.98rem, 1.4vw, 1.12rem);
    line-height: 1.72;
}

.noticia-hero-highlights {
    position: relative;
    z-index: 1;
    display: flex;
    flex-wrap: wrap;
    gap: 0.65rem;
    margin-top: 1.55rem;
}

.noticia-hero-highlights span {
    display: inline-flex;
    align-items: center;
    gap: 0.42rem;
    padding: 0.55rem 0.7rem;
    border: 1px solid rgba(15, 23, 42, 0.07);
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.72);
    color: #475569;
    font-size: 0.75rem;
    font-weight: 720;
}

.noticia-hero-highlights svg {
    width: 15px;
    height: 15px;
    color: var(--primary, #166534);
}

.noticia-hero-panel {
    position: relative;
    display: flex;
    min-height: 100%;
    flex-direction: column;
    justify-content: flex-end;
    padding: 2rem;
    overflow: hidden;
    border-radius: 30px;
    background:
            linear-gradient(
                    145deg,
                    rgba(13, 71, 39, 0.96),
                    rgba(20, 83, 45, 0.98)
            );
    color: #ffffff;
    box-shadow: 0 24px 55px rgba(20, 83, 45, 0.18);
}

.noticia-hero-panel::before {
    content: "";
    position: absolute;
    top: -70px;
    right: -60px;
    width: 220px;
    height: 220px;
    border: 1px solid rgba(255, 255, 255, 0.09);
    border-radius: 50%;
}

.noticia-hero-panel::after {
    content: "";
    position: absolute;
    top: 46px;
    right: 44px;
    width: 70px;
    height: 70px;
    border-radius: 50%;
    background: rgba(234, 179, 8, 0.13);
    filter: blur(2px);
}

.noticia-hero-panel-icon {
    position: relative;
    z-index: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 58px;
    height: 58px;
    margin-bottom: auto;
    border: 1px solid rgba(255, 255, 255, 0.16);
    border-radius: 17px;
    background: rgba(255, 255, 255, 0.1);
    color: #facc15;
    backdrop-filter: blur(8px);
}

.noticia-hero-panel-icon svg {
    width: 27px;
    height: 27px;
}

.noticia-hero-panel > span,
.noticia-hero-panel > strong,
.noticia-hero-panel > small {
    position: relative;
    z-index: 1;
}

.noticia-hero-panel > span {
    margin-top: 2rem;
    color: #fde68a;
    font-size: 0.74rem;
    font-weight: 800;
    letter-spacing: 0.09em;
    text-transform: uppercase;
}

.noticia-hero-panel > strong {
    margin-top: 0.35rem;
    font-size: 1.55rem;
    font-weight: 850;
    line-height: 1.15;
    letter-spacing: -0.03em;
}

.noticia-hero-panel > small {
    margin-top: 0.75rem;
    color: rgba(255, 255, 255, 0.72);
    font-size: 0.82rem;
    line-height: 1.55;
}


/* ==========================================================================
   3. NOTÍCIA EM DESTAQUE
   ========================================================================== */

.noticia-destaque-horizontal {
    display: grid;
    grid-template-columns: minmax(0, 1.22fr) minmax(340px, 0.78fr);
    min-height: 420px;
    margin-bottom: 3.5rem;
    overflow: hidden;
    border: 1px solid rgba(15, 23, 42, 0.065);
    border-radius: 28px;
    background: #ffffff;
    box-shadow:
            0 22px 58px rgba(15, 23, 42, 0.09),
            0 3px 12px rgba(15, 23, 42, 0.035);
}

.noticia-destaque-media {
    position: relative;
    display: block;
    min-height: 420px;
    overflow: hidden;
    background: #e8ece8;
}

.noticia-destaque-media::after {
    content: "";
    position: absolute;
    inset: 0;
    background:
            linear-gradient(
                    180deg,
                    transparent 48%,
                    rgba(5, 33, 17, 0.31) 100%
            );
    pointer-events: none;
}

.noticia-destaque-media img {
    width: 100%;
    height: 100%;
    min-height: 420px;
    object-fit: cover;
    transition:
            transform 0.75s cubic-bezier(0.2, 0.7, 0.2, 1),
            filter 0.4s ease;
}

.noticia-destaque-horizontal:hover .noticia-destaque-media img {
    transform: scale(1.045);
}

.noticia-destaque-label {
    position: absolute;
    top: 1.15rem;
    left: 1.15rem;
    z-index: 2;
    display: inline-flex;
    align-items: center;
    gap: 0.43rem;
    padding: 0.5rem 0.78rem;
    border: 1px solid rgba(255, 255, 255, 0.24);
    border-radius: 999px;
    background: rgba(13, 71, 39, 0.92);
    color: #ffffff;
    font-size: 0.68rem;
    font-weight: 850;
    letter-spacing: 0.065em;
    text-transform: uppercase;
    backdrop-filter: blur(8px);
}

.noticia-destaque-label svg {
    width: 13px;
    height: 13px;
    color: #facc15;
    fill: rgba(250, 204, 21, 0.18);
}

.noticia-destaque-body {
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: clamp(2rem, 3.5vw, 3rem);
}

.noticia-destaque-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.68rem;
    margin-bottom: 1rem;
}

.destaque-categoria {
    display: inline-flex;
    align-items: center;
    padding: 0.38rem 0.62rem;
    border-radius: 7px;
    background: rgba(22, 101, 52, 0.07);
    color: var(--primary, #166534);
    font-size: 0.71rem;
    font-weight: 850;
    letter-spacing: 0.055em;
    text-transform: uppercase;
}

.destaque-date {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    color: var(--text-muted, #64748b);
    font-size: 0.78rem;
    font-weight: 550;
}

.destaque-date::before {
    content: "";
    width: 4px;
    height: 4px;
    border-radius: 50%;
    background: #cbd5e1;
}

.destaque-title {
    margin: 0;
    color: var(--primary-dark, #123c23);
    font-size: clamp(1.65rem, 2.8vw, 2.45rem);
    font-weight: 900;
    line-height: 1.13;
    letter-spacing: -0.045em;
}

.destaque-title a {
    color: inherit;
    text-decoration: none;
    transition: color 0.22s ease;
}

.destaque-title a:hover {
    color: var(--primary, #166534);
}

.destaque-subtitle {
    display: -webkit-box;
    margin: 1rem 0 0;
    overflow: hidden;
    color: var(--text-muted, #64748b);
    font-size: 0.98rem;
    line-height: 1.68;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 4;
}

.noticia-destaque-footer {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    margin-top: 1.6rem;
}

.noticia-featured-action {
    display: inline-flex;
    align-items: center;
    gap: 0.55rem;
    width: fit-content;
    padding: 0.76rem 1.05rem;
    border-radius: 11px;
    background: var(--primary, #166534);
    color: #ffffff;
    font-size: 0.82rem;
    font-weight: 800;
    text-decoration: none;
    transition:
            transform 0.22s ease,
            background-color 0.22s ease,
            box-shadow 0.22s ease;
}

.noticia-featured-action svg {
    width: 17px;
    height: 17px;
    transition: transform 0.22s ease;
}

.noticia-featured-action:hover {
    transform: translateY(-2px);
    background: var(--primary-dark, #14532d);
    color: #ffffff;
    box-shadow: 0 10px 24px rgba(22, 101, 52, 0.2);
}

.noticia-featured-action:hover svg {
    transform: translateX(3px);
}

.noticia-destaque-id {
    color: #94a3b8;
    font-size: 0.72rem;
    font-weight: 650;
}


/* ==========================================================================
   4. CABEÇALHO DO GRID
   ========================================================================== */

.noticia-grid-header {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 1.45rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid rgba(15, 23, 42, 0.085);
}

.noticia-grid-header-copy {
    display: flex;
    align-items: center;
    gap: 0.85rem;
}

.noticia-grid-header-marker {
    width: 5px;
    height: 50px;
    border-radius: 999px;
    background: linear-gradient(
            180deg,
            var(--accent-color, #eab308),
            #ca8a04
    );
}

.noticia-grid-kicker {
    display: block;
    margin-bottom: 0.15rem;
    color: var(--primary, #166534);
    font-size: 0.66rem;
    font-weight: 850;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.noticia-grid-header h2 {
    margin: 0;
    color: var(--primary-dark, #123c23);
    font-size: 1.65rem;
    font-weight: 900;
    letter-spacing: -0.035em;
}

.noticia-grid-header p {
    margin: 0.28rem 0 0;
    color: var(--text-muted, #64748b);
    font-size: 0.86rem;
}

.noticia-grid-count {
    flex: 0 0 auto;
    padding: 0.48rem 0.72rem;
    border: 1px solid rgba(22, 101, 52, 0.11);
    border-radius: 999px;
    background: rgba(22, 101, 52, 0.05);
    color: var(--primary-dark, #14532d);
    font-size: 0.73rem;
    font-weight: 750;
}


/* ==========================================================================
   5. GRID
   ========================================================================== */

.noticia-grid {
    row-gap: 1.75rem;
}


/* ==========================================================================
   6. CARTÕES
   ========================================================================== */

.noticia-card {
    position: relative;
    display: flex;
    height: 100%;
    flex-direction: column;
    overflow: hidden;
    border: 1px solid rgba(15, 23, 42, 0.07);
    border-radius: 21px;
    background: #ffffff;
    box-shadow: 0 8px 28px rgba(15, 23, 42, 0.055);
    transition:
            transform 0.3s cubic-bezier(0.2, 0.7, 0.2, 1),
            box-shadow 0.3s ease,
            border-color 0.3s ease;
}

.noticia-card:hover {
    transform: translateY(-7px);
    border-color: rgba(22, 101, 52, 0.17);
    box-shadow: 0 19px 44px rgba(15, 23, 42, 0.11);
}

.noticia-card-media {
    position: relative;
    display: block;
    flex: 0 0 auto;
    overflow: hidden;
    aspect-ratio: 16 / 10;
    background: #e9eeea;
}

.noticia-card-overlay {
    position: absolute;
    inset: 0;
    z-index: 1;
    background: linear-gradient(
            180deg,
            rgba(5, 33, 17, 0.02) 40%,
            rgba(5, 33, 17, 0.24) 100%
    );
    pointer-events: none;
}

.noticia-card-media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition:
            transform 0.58s cubic-bezier(0.2, 0.7, 0.2, 1),
            filter 0.35s ease;
}

.noticia-card:hover .noticia-card-media img {
    transform: scale(1.06);
}

.tag-categoria {
    position: absolute;
    top: 0.9rem;
    left: 0.9rem;
    z-index: 2;
    display: inline-flex;
    align-items: center;
    max-width: calc(100% - 1.8rem);
    padding: 0.42rem 0.7rem;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.24);
    border-radius: 999px;
    background: rgba(13, 71, 39, 0.91);
    color: #ffffff;
    font-size: 0.65rem;
    font-weight: 850;
    letter-spacing: 0.045em;
    text-overflow: ellipsis;
    text-transform: uppercase;
    white-space: nowrap;
    backdrop-filter: blur(8px);
}

.noticia-card .card-body {
    display: flex;
    flex: 1 1 auto;
    flex-direction: column;
    padding: 1.3rem 1.35rem 1.35rem;
}

.noticia-card-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    margin-bottom: 0.7rem;
}

.card-date {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    color: var(--text-muted, #64748b);
    font-size: 0.73rem;
    font-weight: 600;
}

.card-date svg {
    width: 14px;
    height: 14px;
    color: var(--primary, #166534);
    stroke-width: 2;
}

.noticia-card-type {
    color: #94a3b8;
    font-size: 0.66rem;
    font-weight: 750;
    letter-spacing: 0.05em;
    text-transform: uppercase;
}

.noticia-card .card-title {
    display: -webkit-box;
    margin: 0;
    overflow: hidden;
    color: var(--primary-dark, #123c23);
    font-size: 1.14rem;
    font-weight: 850;
    line-height: 1.38;
    letter-spacing: -0.022em;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 3;
}

.noticia-card .card-title a {
    color: inherit;
    text-decoration: none;
    transition: color 0.22s ease;
}

.noticia-card .card-title a:hover {
    color: var(--primary, #166534);
}

.noticia-card .card-text {
    display: -webkit-box;
    margin: 0.78rem 0 0;
    overflow: hidden;
    color: var(--text-muted, #64748b);
    font-size: 0.89rem;
    line-height: 1.62;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 3;
}

.noticia-card-footer {
    margin-top: auto;
    padding-top: 1.15rem;
}

.noticia-card-link {
    display: inline-flex;
    align-items: center;
    gap: 0.44rem;
    color: var(--primary, #166534);
    font-size: 0.79rem;
    font-weight: 820;
    text-decoration: none;
}

.noticia-card-link svg {
    width: 16px;
    height: 16px;
    transition: transform 0.22s ease;
}

.noticia-card-link:hover {
    color: var(--primary-dark, #14532d);
}

.noticia-card-link:hover svg {
    transform: translate(3px, -3px);
}


/* ==========================================================================
   7. PAGINAÇÃO
   ========================================================================== */

.noticia-pagination {
    display: flex;
    justify-content: center;
    margin-top: 3.5rem;
}

.noticia-pagination .paginator,
.noticia-pagination ul {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 0.42rem;
    margin: 0;
    padding: 0;
    list-style: none;
}

.noticia-pagination a,
.noticia-pagination span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 43px;
    height: 43px;
    padding: 0 0.75rem;
    border: 1px solid rgba(15, 23, 42, 0.09);
    border-radius: 11px;
    background: #ffffff;
    color: var(--primary-dark, #14532d);
    font-size: 0.82rem;
    font-weight: 780;
    text-decoration: none;
    box-shadow: 0 4px 12px rgba(15, 23, 42, 0.035);
    transition:
            background-color 0.2s ease,
            border-color 0.2s ease,
            color 0.2s ease,
            transform 0.2s ease;
}

.noticia-pagination a:hover {
    transform: translateY(-2px);
    border-color: var(--primary, #166534);
    background: rgba(22, 101, 52, 0.05);
    color: var(--primary, #166534);
}

.noticia-pagination .active,
.noticia-pagination [aria-current="page"] {
    border-color: var(--primary, #166534);
    background: var(--primary, #166534);
    color: #ffffff;
}


/* ==========================================================================
   8. SEM RESULTADOS
   ========================================================================== */

.noticia-empty {
    max-width: 640px;
    margin: 2rem auto 0;
    padding: 4.25rem 2rem;
    border: 1px dashed rgba(22, 101, 52, 0.22);
    border-radius: 26px;
    background: rgba(255, 255, 255, 0.78);
    text-align: center;
    box-shadow: 0 14px 40px rgba(15, 23, 42, 0.045);
    backdrop-filter: blur(7px);
}

.noticia-empty-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 70px;
    height: 70px;
    margin-bottom: 1.25rem;
    border-radius: 19px;
    background: rgba(22, 101, 52, 0.08);
    color: var(--primary, #166534);
}

.noticia-empty-icon svg {
    width: 31px;
    height: 31px;
}

.noticia-empty h2 {
    margin: 0;
    color: var(--primary-dark, #123c23);
    font-size: 1.55rem;
    font-weight: 880;
    letter-spacing: -0.03em;
}

.noticia-empty p {
    margin: 0.75rem 0 0;
    color: var(--text-muted, #64748b);
    font-size: 0.95rem;
    line-height: 1.65;
}


/* ==========================================================================
   9. ANIMAÇÃO
   ========================================================================== */

.sa-fade-in {
    animation: noticiaFadeIn 0.65s ease both;
}

@keyframes noticiaFadeIn {
    from {
        opacity: 0;
        transform: translateY(18px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}


/* ==========================================================================
   10. RESPONSIVIDADE
   ========================================================================== */

@media (max-width: 1199px) {

    .noticia-hero {
        grid-template-columns: minmax(0, 1.35fr) minmax(270px, 0.65fr);
    }

    .noticia-destaque-horizontal {
        grid-template-columns: minmax(0, 1fr) minmax(330px, 0.9fr);
    }
}

@media (max-width: 991px) {

    .noticia-page {
        padding: 3rem 0 4.5rem;
    }

    .noticia-hero {
        grid-template-columns: 1fr;
    }

    .noticia-hero-panel {
        min-height: 250px;
    }

    .noticia-destaque-horizontal {
        grid-template-columns: 1fr;
        min-height: auto;
    }

    .noticia-destaque-media,
    .noticia-destaque-media img {
        min-height: 350px;
        height: 350px;
    }

    .noticia-destaque-body {
        padding: 2rem;
    }
}

@media (max-width: 767px) {

    .noticia-page {
        padding: 2.5rem 0 4rem;
    }

    .noticia-hero-copy,
    .noticia-hero-panel {
        border-radius: 22px;
    }

    .noticia-hero-copy {
        padding: 2rem 1.55rem;
    }

    .noticia-hero-panel {
        min-height: 225px;
        padding: 1.55rem;
    }

    .noticia-hero .section-title {
        font-size: clamp(2rem, 10vw, 3rem);
    }

    .noticia-destaque-horizontal {
        margin-bottom: 3rem;
        border-radius: 21px;
    }

    .noticia-destaque-media,
    .noticia-destaque-media img {
        min-height: 280px;
        height: 280px;
    }

    .noticia-grid-header {
        align-items: flex-start;
    }

    .noticia-grid-header h2 {
        font-size: 1.4rem;
    }
}

@media (max-width: 575px) {

    .noticia-page {
        padding: 2rem 0 3.5rem;
    }

    .noticia-hero {
        gap: 1rem;
        margin-bottom: 1.5rem;
    }

    .noticia-hero-copy {
        padding: 1.7rem 1.25rem;
    }

    .noticia-hero-highlights {
        align-items: stretch;
        flex-direction: column;
    }

    .noticia-hero-highlights span {
        width: 100%;
    }

    .noticia-hero-panel {
        min-height: 205px;
        padding: 1.35rem;
    }

    .noticia-destaque-horizontal {
        border-radius: 18px;
    }

    .noticia-destaque-media,
    .noticia-destaque-media img {
        min-height: 225px;
        height: 225px;
    }

    .noticia-destaque-label {
        top: 0.85rem;
        left: 0.85rem;
        font-size: 0.62rem;
    }

    .noticia-destaque-body {
        padding: 1.35rem;
    }

    .destaque-title {
        font-size: 1.43rem;
    }

    .destaque-subtitle {
        font-size: 0.91rem;
        -webkit-line-clamp: 4;
    }

    .noticia-destaque-footer {
        align-items: stretch;
        flex-direction: column;
    }

    .noticia-featured-action {
        width: 100%;
        justify-content: center;
    }

    .noticia-destaque-id {
        text-align: center;
    }

    .noticia-grid-header {
        align-items: flex-start;
    }

    .noticia-grid-count {
        display: none;
    }

    .noticia-card {
        border-radius: 18px;
    }

    .noticia-card .card-body {
        padding: 1.15rem 1.2rem 1.3rem;
    }

    .noticia-empty {
        padding: 3rem 1.25rem;
        border-radius: 19px;
    }
}


/* ==========================================================================
   11. ACESSIBILIDADE
   ========================================================================== */

.noticia-page a:focus-visible {
    outline: 3px solid rgba(234, 179, 8, 0.68);
    outline-offset: 3px;
}

@media (prefers-reduced-motion: reduce) {

    .sa-fade-in {
        animation: none;
    }

    .noticia-card,
    .noticia-card-media img,
    .noticia-destaque-media img,
    .noticia-card-link svg,
    .noticia-featured-action,
    .noticia-featured-action svg {
        transition: none;
    }

    .noticia-card:hover,
    .noticia-featured-action:hover {
        transform: none;
    }
}
