/* News Cards Grid Styles */

/* Section Header */
.news-section-header {
    padding: 60px 0 40px;
    background-color: #ffffff;
}

.news-section-title {
    font-size: 2.5rem;
    font-weight: 700;
    color: #2c3e50;
    margin-bottom: 15px;
    letter-spacing: -0.5px;
}

.news-section-subtitle {
    font-size: 1.1rem;
    color: #6c757d;
    margin-bottom: 0;
    line-height: 1.6;
}

.news-section-view-all {
    display: inline-flex;
    align-items: center;
    color: #167a8b;
    font-weight: 600;
    font-size: 1rem;
    text-decoration: none;
    padding: 12px 24px;
    border: 2px solid #167a8b;
    border-radius: 50px;
    transition: all 0.3s ease;
}

.news-section-view-all:hover {
    background-color: #167a8b;
    color: #ffffff;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(22, 122, 139, 0.2);
}

/* News Grid Section */
.news-grid-section {
    padding: 0 0 80px;
    background-color: #f8f9fa;
}

.news-grid-row {
    margin: 0 -15px;
}

/* News Card */
.news-card {
    background: #ffffff;
    border-radius: 16px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    overflow: hidden;
    transition: all 0.3s ease;
    height: 100%;
    display: flex;
    flex-direction: column;
    margin: 0 15px;
}

.news-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.15);
}

/* Card Image */
.news-card-image-wrapper {
    position: relative;
    width: 100%;
    height: 200px;
    overflow: hidden;
}

.news-card-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.news-card:hover .news-card-image {
    transform: scale(1.05);
}

/* Card Content */
.news-card-content {
    padding: 24px;
    flex: 1;
    display: flex;
    flex-direction: column;
}

/* Badges Row */
.news-card-badges {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
    flex-wrap: wrap;
    gap: 8px;
}

.news-card-category {
    background-color: #167a8b;
    color: #ffffff;
    font-size: 0.75rem;
    font-weight: 600;
    padding: 6px 12px;
    border-radius: 20px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

a.news-card-category {
    text-decoration: none;
    display: inline-block;
    transition: background-color 0.2s ease, transform 0.2s ease;
}

a.news-card-category:hover,
a.news-card-category:focus {
    color: #ffffff;
    background-color: #125f6d;
    transform: translateY(-1px);
}

.news-card-date {
    color: #6c757d;
    font-size: 0.875rem;
    font-weight: 500;
}

/* Title */
.news-card-title {
    margin-bottom: 12px;
    line-height: 1.4;
}

.news-card-title-link {
    color: #2c3e50;
    font-size: 1.25rem;
    font-weight: 700;
    text-decoration: none;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    line-height: 1.4;
    max-height: 3.6em;
    transition: color 0.3s ease;
}

.news-card-title-link:hover {
    color: #167a8b;
}

/* Summary */
.news-card-summary {
    color: #6c757d;
    font-size: 0.95rem;
    line-height: 1.6;
    margin-bottom: 20px;
    flex: 1;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    max-height: 4.8em;
}

/* Card Footer */
.news-card-footer {
    margin-top: auto;
    display: flex;
    flex-direction: column;
    gap: 0.85rem;
}

.news-card-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.5rem 0.75rem;
}

.news-card-location {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    color: #64748b;
    font-size: 0.84rem;
    font-weight: 500;
}

.news-card-state {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    color: #64748b;
    font-size: 0.84rem;
    font-weight: 600;
    text-decoration: none;
    transition: color 0.2s ease;
}

a.news-card-state:hover,
a.news-card-state:focus {
    color: #167a8b;
}

.news-card-state i,
.news-card-location i {
    color: #167a8b;
    font-size: 0.78rem;
}

.news-card-status {
    display: inline-flex;
    align-items: center;
    padding: 0.25rem 0.65rem;
    border-radius: 999px;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.03em;
    text-transform: uppercase;
}

.news-card-status--ongoing {
    background-color: rgba(22, 122, 139, 0.12);
    color: #167a8b;
}

.news-card-status--completed {
    background-color: rgba(36, 178, 115, 0.12);
    color: #24b273;
}

.news-card-status--upcoming {
    background-color: rgba(194, 77, 44, 0.12);
    color: #c24d2c;
}

html[dir="rtl"] .news-card-read-more-icon,
.to--reverse .news-card-read-more-icon {
    transform: scaleX(-1);
}

html[dir="rtl"] .news-card-read-more:hover .news-card-read-more-icon,
.to--reverse .news-card-read-more:hover .news-card-read-more-icon {
    transform: scaleX(-1) translateX(4px);
}

.news-card-read-more {
    display: inline-flex;
    align-items: center;
    color: #167a8b;
    font-weight: 600;
    font-size: 0.9rem;
    text-decoration: none;
    transition: all 0.3s ease;
}

.news-card-read-more i {
    transition: transform 0.3s ease;
}

.news-card-read-more:hover {
    color: #125a6b;
    transform: translateX(4px);
}

.news-card-read-more:hover i {
    transform: translateX(4px);
}

/* Responsive Design */
@media (max-width: 767.98px) {
    .news-section-title {
        font-size: 2rem;
    }
    
    .news-section-header {
        padding: 40px 0 30px;
    }
    
    .news-grid-section {
        padding: 0 0 60px;
    }
    
    .news-card-content {
        padding: 20px;
    }
    
    .news-card-image-wrapper {
        height: 180px;
    }
    
    .news-card-title-link {
        font-size: 1.1rem;
    }
}

@media (max-width: 575.98px) {
    .news-section-title {
        font-size: 1.75rem;
    }
    
    .news-section-subtitle {
        font-size: 1rem;
    }
    
    .news-section-view-all {
        font-size: 0.9rem;
        padding: 10px 20px;
    }
    
    .news-card-badges {
        flex-direction: column;
        align-items: flex-start;
        gap: 6px;
    }
    
    .news-card-content {
        padding: 18px;
    }
    
    .news-card-image-wrapper {
        height: 160px;
    }
    
    .news-card-title-link {
        font-size: 1rem;
    }
    
    .news-card-summary {
        font-size: 0.9rem;
    }
}

/* Accessibility */
.news-card:focus-within {
    outline: 2px solid #167a8b;
    outline-offset: 2px;
}

.news-card-title-link:focus,
.news-card-read-more:focus {
    outline: 2px solid #167a8b;
    outline-offset: 2px;
    border-radius: 4px;
}

/* Animation for cards entering viewport */
.news-card {
    opacity: 0;
    transform: translateY(30px);
}

.news-card.aos-animate {
    opacity: 1;
    transform: translateY(0);
}
