/* ============================================
   News Modern Styles - Shared between news list and single news view
   ============================================ */

/* Hero Section */
.news-hero {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    padding: 100px 0 80px;
    position: relative;
    overflow: hidden;
}

.news-hero::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="grain" width="100" height="100" patternUnits="userSpaceOnUse"><circle cx="50" cy="50" r="1" fill="rgba(255,255,255,0.1)"/></pattern></defs><rect width="100" height="100" fill="url(%23grain)"/></svg>');
    opacity: 0.3;
}

.news-hero-content {
    position: relative;
    z-index: 2;
}

.news-search-box {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-radius: 25px;
    padding: 30px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
    margin-top: 30px;
}

.news-search-input {
    border: 2px solid #e2e8f0;
    border-radius: 15px;
    padding: 15px 20px;
    font-size: 1rem;
    transition: all 0.3s ease;
}

.news-search-input:focus {
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
    outline: none;
}

/* News Cards */
.news-card-modern {
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    border: none;
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.08);
    height: 100%;
    background: white;
}

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

.news-card-modern .card-img-wrapper {
    position: relative;
    overflow: hidden;
    height: 220px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.news-card-modern .card-img-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.news-card-modern:hover .card-img-wrapper img {
    transform: scale(1.1);
}

.news-card-modern .card-img-overlay {
    background: linear-gradient(
        to bottom,
        rgba(0, 0, 0, 0.7) 0%,
        transparent 100%
    );
    padding: 20px;
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
}

.news-badge {
    background: linear-gradient(135deg, #ffc107 0%, #ff8c00 100%);
    color: white;
    padding: 5px 15px;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
}

.news-card-modern .card-body {
    padding: 25px;
}

.news-card-modern .card-title {
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 15px;
    line-height: 1.5;
    color: #2d3748;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.news-card-modern .card-title a {
    color: inherit;
    text-decoration: none;
    transition: color 0.3s ease;
}

.news-card-modern .card-title a:hover {
    color: #667eea;
}

.news-card-modern .card-excerpt {
    color: #718096;
    font-size: 0.95rem;
    line-height: 1.7;
    margin-bottom: 20px;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.news-card-modern .card-footer {
    background: transparent;
    border: none;
    padding: 20px 25px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.news-date {
    display: flex;
    align-items: center;
    color: #a0aec0;
    font-size: 0.85rem;
}

.news-date svg {
    margin-left: 5px;
    width: 16px;
    height: 16px;
}

/* Featured News */
.news-featured-card {
    position: relative;
    border-radius: 25px;
    overflow: hidden;
    height: 400px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.news-featured-card::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(
        to bottom,
        rgba(0, 0, 0, 0.15) 0%,
        rgba(0, 0, 0, 0.5) 100%
    );
    z-index: 1;
    transition: background 0.3s ease;
}

.news-featured-card:hover::before {
    background: linear-gradient(
        to bottom,
        rgba(0, 0, 0, 0.35) 0%,
        rgba(0, 0, 0, 0.7) 100%
    );
}

.news-featured-card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.news-featured-content {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 40px;
    z-index: 2;
    color: white;
}

.news-featured-content h2 {
    font-size: 1.75rem;
    font-weight: 700;
    margin-bottom: 15px;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

.news-featured-content p {
    font-size: 1rem;
    opacity: 0.95;
    margin-bottom: 20px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Sidebar Styles */
.news-categories {
    background: white;
    border-radius: 20px;
    padding: 25px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.08);
    margin-bottom: 30px;
}

.news-categories h4 {
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 20px;
    color: #2d3748;
}

.category-tag {
    display: inline-flex;
    align-items: center;
    padding: 8px 16px;
    margin: 5px;
    background: linear-gradient(135deg, #f7fafc 0%, #edf2f7 100%);
    border-radius: 20px;
    color: #4a5568;
    text-decoration: none;
    font-size: 0.9rem;
    transition: all 0.3s ease;
    border: 2px solid transparent;
    gap: 5px;
}

.category-tag:hover {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(102, 126, 234, 0.3);
    border-color: transparent;
}

.category-tag.active {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.news-sidebar-card {
    background: white;
    border-radius: 20px;
    padding: 25px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.08);
    margin-bottom: 30px;
}

.news-sidebar-card h5 {
    font-size: 1.1rem;
    font-weight: 700;
    margin-bottom: 20px;
    color: #2d3748;
    padding-bottom: 15px;
    border-bottom: 2px solid #e2e8f0;
}

.news-sidebar-item {
    display: flex;
    gap: 15px;
    padding: 15px 0;
    border-bottom: 1px solid #e2e8f0;
    text-decoration: none;
    transition: all 0.3s ease;
}

.news-sidebar-item:last-child {
    border-bottom: none;
}

.news-sidebar-item:hover {
    transform: translateX(-5px);
}

.news-sidebar-item img {
    width: 80px;
    height: 80px;
    object-fit: cover;
    border-radius: 12px;
    flex-shrink: 0;
}

.news-sidebar-item-content {
    flex: 1;
}

.news-sidebar-item-content h6 {
    font-size: 0.95rem;
    font-weight: 600;
    margin-bottom: 5px;
    color: #2d3748;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.news-sidebar-item-content span {
    font-size: 0.8rem;
    color: #a0aec0;
}

/* Pagination */
.pagination-modern {
    margin-top: 50px;
}

.pagination-modern .pagination {
    justify-content: center;
    flex-wrap: wrap;
    gap: 8px;
}

.pagination-modern .pagination .page-item {
    margin: 0;
}

.pagination-modern .pagination .page-link {
    border: 2px solid #e2e8f0;
    border-radius: 12px;
    padding: 10px 18px;
    color: #4a5568;
    font-weight: 600;
    transition: all 0.3s ease;
    text-decoration: none;
    margin: 0;
    background: white;
}

.pagination-modern .pagination .page-link:hover {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white !important;
    border-color: transparent;
    transform: translateY(-2px);
    z-index: 2;
}

.pagination-modern .pagination .page-item.active .page-link {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white !important;
    border-color: transparent;
    z-index: 3;
}

.pagination-modern .pagination .page-item.disabled .page-link {
    opacity: 0.5;
    cursor: not-allowed;
}

.pagination-modern .pagination .page-item:first-child .page-link {
    border-top-right-radius: 12px;
    border-bottom-right-radius: 12px;
}

.pagination-modern .pagination .page-item:last-child .page-link {
    border-top-left-radius: 12px;
    border-bottom-left-radius: 12px;
}

/* Empty State */
.news-empty-state {
    text-align: center;
    padding: 80px 20px;
    color: #a0aec0;
}

.news-empty-state svg {
    width: 120px;
    height: 120px;
    margin-bottom: 30px;
    opacity: 0.5;
}

/* Article View Styles */
.news-article-container {
    background: white;
    border-radius: 25px;
    padding: 40px;
    box-shadow: 0 5px 25px rgba(0, 0, 0, 0.08);
    margin-bottom: 30px;
}

.news-article-header {
    margin-bottom: 30px;
    padding-bottom: 25px;
    border-bottom: 2px solid #e2e8f0;
}

.news-article-title {
    font-size: 2.25rem;
    font-weight: 700;
    color: #2d3748;
    margin-bottom: 20px;
    line-height: 1.4;
}

.news-article-meta {
    display: flex;
    align-items: center;
    gap: 20px;
    flex-wrap: wrap;
    color: #718096;
    font-size: 0.9rem;
}

.news-article-meta-item {
    display: flex;
    align-items: center;
    gap: 8px;
}

.news-article-meta-item svg {
    width: 18px;
    height: 18px;
}

.news-article-image {
    width: 100%;
    border-radius: 20px;
    margin-bottom: 35px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
    object-fit: cover;
    max-height: 500px;
}

.news-article-content {
    font-size: 1.1rem;
    line-height: 2;
    color: #4a5568;
}

.news-article-content h2 {
    font-size: 1.75rem;
    font-weight: 700;
    color: #2d3748;
    margin-top: 35px;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 2px solid #e2e8f0;
}

.news-article-content h3 {
    font-size: 1.5rem;
    font-weight: 700;
    color: #2d3748;
    margin-top: 30px;
    margin-bottom: 15px;
}

.news-article-content p {
    margin-bottom: 20px;
}

.news-article-content img {
    width: 100%;
    border-radius: 15px;
    margin: 25px 0;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.news-article-content .news_text_box {
    margin-bottom: 25px;
}

.news-article-content .news_text_box h2.h6 {
    font-size: 1.25rem;
    font-weight: 600;
    color: #667eea;
    margin-bottom: 15px;
}

.news-tags-section {
    margin-top: 40px;
    padding-top: 30px;
    border-top: 2px solid #e2e8f0;
}

.news-tags-section h4 {
    font-size: 1.1rem;
    font-weight: 700;
    color: #2d3748;
    margin-bottom: 15px;
}

.news-tag-badge {
    display: inline-block;
    padding: 8px 16px;
    margin: 5px 5px 5px 0;
    background: linear-gradient(135deg, #f7fafc 0%, #edf2f7 100%);
    border-radius: 20px;
    color: #4a5568;
    font-size: 0.9rem;
    transition: all 0.3s ease;
    border: 2px solid transparent;
}

.news-tag-badge:hover {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(102, 126, 234, 0.3);
}

.news-share-buttons {
    display: flex;
    gap: 10px;
    margin-top: 30px;
    padding-top: 30px;
    border-top: 2px solid #e2e8f0;
}

.btn-dashboard {
    margin-top: 1rem;
}

.btn-dashboard .btnbox-collapse {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px;
    background: linear-gradient(135deg, #f7fafc 0%, #edf2f7 100%);
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-dashboard .btnbox-collapse:hover {
    background: linear-gradient(135deg, #e2e8f0 0%, #cbd5e0 100%);
}

.btn-dashboard .collapse-body {
    font-size: 1rem;
    line-height: 2rem;
    padding: 20px;
    background: white;
    border-radius: 0 0 12px 12px;
}

.btn-dashboard h6 {
    font-weight: 600;
    margin: 0;
}

.news-article-breadcrumb {
    margin-bottom: 20px;
}

.news-article-breadcrumb a {
    color: #667eea;
    text-decoration: none;
    transition: color 0.3s ease;
}

.news-article-breadcrumb a:hover {
    color: #764ba2;
}

/* Responsive */
@media (max-width: 768px) {
    .news-hero {
        padding: 60px 0 40px;
    }

    .news-featured-card {
        height: 300px;
    }

    .news-featured-content {
        padding: 25px;
    }

    .news-featured-content h2 {
        font-size: 1.3rem;
    }

    .news-article-container {
        padding: 25px;
    }

    .news-article-title {
        font-size: 1.75rem;
    }

    .news-article-content {
        font-size: 1rem;
    }
}
