/* ===================================================================
   NEWS SECTION - VERSION 1.0
=================================================================== */
.news-section {
    padding: 40px 0;
    background: var(--gray-100);
}

/* SECTION HEADER */
.section-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 30px;
}

.section-title h2 {
    margin: 0 0 6px;
    font-size: 30px;
    font-weight: 700;
    color: var(--text);
    line-height: 1.3;
}

.section-title span {
    display: block;
    font-size: 15px;
    color: var(--text-light);
}

.section-more {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 15px;
    font-weight: 600;
    color: var(--primary);
    transition: all 0.3s ease;
}

.section-more:hover {
    gap: 12px;
    color: var(--primary-dark);
}

/* NEWS GRID */
.news-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
}

/* NEWS CARD */
.news-card {
    position: relative;
    background: var(--white);
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    transition: transform 0.35s ease, box-shadow 0.35s ease;
}

.news-card:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow-lg);
}

.news-card-link {
    display: flex;
    flex-direction: column;
    height: 100%;
    color: inherit;
}

/* IMAGE & OVERLAY */
.news-card-image {
    position: relative;
    overflow: hidden;
    aspect-ratio: 16 / 9;
    background: #ddd;
}

.news-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.45s ease;
}

.news-card:hover .news-card-image img {
    transform: scale(1.08);
}

.news-card-image::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.15), rgba(0, 0, 0, 0));
    opacity: 0;
    transition: opacity 0.3s ease;
}

.news-card:hover .news-card-image::after {
    opacity: 1;
}

/* CATEGORY BADGE */
.news-card-category {
    position: absolute;
    top: 16px;
    left: 16px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 6px 14px;
    border-radius: 30px;
    background: var(--primary);
    color: var(--white);
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    z-index: 2;
}

/* ===================================================================
   NEWS CARD CONTENT & LAYOUT
=================================================================== */
.news-card-content {
    display: flex;
    flex-direction: column;
    flex: 1;
    padding: 20px;
}

.news-card-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 15px;
    margin-top: auto;
    padding-top: 18px;
    border-top: 1px solid var(--border-color);
}

/* TYPOGRAPHY & LIMITS */
.news-card-title {
    margin-bottom: 14px;
    font-size: 21px;
    font-weight: 700;
    line-height: 1.45;
    color: var(--text);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    transition: color 0.3s ease;
}

.news-card-excerpt {
    flex: 1;
    margin-bottom: 20px;
    color: var(--text-light);
    font-size: 15px;
    line-height: 1.8;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.news-card:hover .news-card-title { color: var(--primary); }

/* META & READ MORE */
.news-card-meta {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 16px;
    margin-bottom: 14px;
    color: var(--text-light);
    font-size: 13px;
    line-height: 1.5;
}

.news-card-meta span { display: inline-flex; align-items: center; gap: 6px; }
.news-card-meta i { color: var(--primary); font-size: 13px; }

.news-card-readmore {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: var(--primary);
    font-size: 14px;
    font-weight: 600;
    transition: gap 0.3s ease;
}
.news-card-readmore:hover { gap: 12px; }

/* INTERACTION & ACCESSIBILITY */
.news-card:hover { box-shadow: var(--shadow-lg); }
.news-card:active { transform: scale(0.98); }
.news-card-link:focus-visible { outline: 2px solid var(--primary); outline-offset: -2px; }
.news-card-image img { display: block; image-rendering: auto; }

/* ANIMATIONS */
.news-card { animation: fadeUp 0.45s ease forwards; }

@keyframes fadeUp {
    from { opacity: 0; transform: translateY(20px); }
    to   { opacity: 1; transform: translateY(0); }
}

@media (prefers-reduced-motion: reduce) {
    .news-card, .news-card-image img, .news-card-title {
        transition: none !important;
        animation: none !important;
    }
}

/* ===================================================================
   RESPONSIVE - NEWS SECTION
=================================================================== */

@media (max-width: 1400px) {
    .news-grid { gap: 22px; }
}

@media (max-width: 1200px) {
    .news-grid { grid-template-columns: repeat(3, 1fr); gap: 20px; }
    .news-card-content { padding: 18px; }
    .news-card-title { font-size: 20px; }
}

@media (max-width: 992px) {
    .news-section { padding: 32px 0; }
    .section-header { margin-bottom: 24px; }
    .section-title h2 { font-size: 28px; }
    .news-grid { grid-template-columns: repeat(2, 1fr); gap: 20px; }
    .news-card-title { font-size: 19px; }
    .news-card-excerpt { font-size: 14px; }
}

@media (max-width: 768px) {
    .news-section { padding: 28px 0; }
    .section-header { flex-direction: column; align-items: flex-start; gap: 14px; }
    .section-title h2 { font-size: 24px; }
    .section-title span, .section-more { font-size: 14px; }
    
    .news-grid { grid-template-columns: 1fr; gap: 18px; }
    .news-card { border-radius: var(--radius-md); }
    .news-card-link { display: flex; flex-direction: row; align-items: stretch; }
    .news-card-image { flex: 0 0 150px; aspect-ratio: auto; height: auto; }
    
    .news-card-content { padding: 16px; }
    .news-card-title { font-size: 18px; margin-bottom: 10px; }
    .news-card-excerpt { font-size: 14px; margin-bottom: 0; -webkit-line-clamp: 2; }
}

@media (max-width: 576px) {
    .news-card-image { flex: 0 0 120px; }
    .news-card-category { top: 10px; left: 10px; padding: 5px 10px; font-size: 10px; }
    .news-card-content { padding: 14px; }
    .news-card-meta { gap: 10px; font-size: 12px; margin-bottom: 8px; }
    .news-card-title { font-size: 16px; margin-bottom: 8px; }
    .news-card-excerpt { display: none; }
}

@media (max-width: 420px) {
    .news-card-image { flex: 0 0 105px; }
    .news-card-content { padding: 12px; }
    .news-card-title { font-size: 15px; line-height: 1.45; }
    .news-card-meta { display: flex; flex-direction: column; align-items: flex-start; gap: 4px; }
}

/* ===================================================================
   INTERACTION & PRINT
=================================================================== */
@media (hover: none) {
    .news-card:hover,
    .news-card:hover .news-card-image img {
        transform: none;
    }
}

@media print {
    .news-section { background: #ffffff; padding: 0; }
    .news-card { box-shadow: none; border: 1px solid #cccccc; break-inside: avoid; }
}