/* ===================================
   NEWS STYLES
   =================================== */

/* News Hero Section */
.news-hero {
    padding: 6rem 2rem 4rem;
    text-align: center;
    background: linear-gradient(135deg, rgba(14, 18, 31, 0.95) 0%, rgba(20, 27, 45, 0.9) 100%);
    position: relative;
    overflow: hidden;
}

.news-hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('../assets/images/rocket-grid-pattern.svg') center/cover;
    opacity: 0.05;
    z-index: -1;
}

.news-hero .hero-content h1 {
    font-size: 3.5rem;
    font-weight: 700;
    margin-bottom: 1rem;
    background: linear-gradient(135deg, #3b82f6 0%, #8b5cf6 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.news-hero .hero-content p {
    font-size: 1.25rem;
    color: #cbd5e1;
    max-width: 600px;
    margin: 0 auto;
    line-height: 1.6;
}

/* Featured News Section */
.featured-news {
    padding: 4rem 2rem;
    max-width: 1200px;
    margin: 0 auto;
}

.featured-news-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
}

.featured-article {
    background: linear-gradient(135deg, rgba(14, 18, 31, 0.8) 0%, rgba(20, 27, 45, 0.6) 100%);
    border-radius: 16px;
    overflow: hidden;
    transition: all 0.3s ease;
    border: 1px solid rgba(59, 130, 246, 0.1);
    position: relative;
}

.featured-article:hover {
    transform: translateY(-8px);
    border-color: rgba(59, 130, 246, 0.3);
    box-shadow: 0 20px 40px rgba(59, 130, 246, 0.1);
}

.featured-image {
    position: relative;
    height: 200px;
    overflow: hidden;
}

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

.featured-article:hover .featured-image img {
    transform: scale(1.1);
}

.featured-overlay {
    position: absolute;
    top: 1rem;
    left: 1rem;
    right: 1rem;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
}

.featured-badge {
    background: linear-gradient(135deg, #f59e0b 0%, #f97316 100%);
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.category-badge {
    background: rgba(59, 130, 246, 0.2);
    color: #3b82f6;
    padding: 0.5rem 1rem;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 500;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(59, 130, 246, 0.3);
}

.featured-content {
    padding: 1.5rem;
}

.featured-content h3 {
    margin-bottom: 0.75rem;
}

.featured-content h3 a {
    color: #f8fafc;
    text-decoration: none;
    font-size: 1.25rem;
    font-weight: 600;
    line-height: 1.4;
    transition: color 0.3s ease;
}

.featured-content h3 a:hover {
    color: #3b82f6;
}

.excerpt {
    color: #cbd5e1;
    font-size: 0.9rem;
    line-height: 1.6;
    margin-bottom: 1rem;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* News Filters */
.news-filters {
    padding: 2rem;
    max-width: 1200px;
    margin: 0 auto;
    border-bottom: 1px solid rgba(59, 130, 246, 0.1);
}

.filters-container h3 {
    color: #f8fafc;
    margin-bottom: 1rem;
    font-size: 1.1rem;
    font-weight: 600;
}

.category-filters {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
}

.filter-btn {
    background: rgba(59, 130, 246, 0.1);
    color: #94a3b8;
    border: 1px solid rgba(59, 130, 246, 0.2);
    padding: 0.75rem 1.5rem;
    border-radius: 25px;
    font-size: 0.9rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    white-space: nowrap;
}

.filter-btn:hover {
    background: rgba(59, 130, 246, 0.2);
    color: #3b82f6;
    border-color: rgba(59, 130, 246, 0.4);
}

.filter-btn.active {
    background: linear-gradient(135deg, #3b82f6 0%, #8b5cf6 100%);
    color: white;
    border-color: transparent;
}

/* News Section */
.news-section {
    padding: 2rem;
    max-width: 1200px;
    margin: 0 auto;
    min-height: 400px;
}

.news-section .section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
    flex-wrap: wrap;
    gap: 1rem;
}

.news-actions {
    display: flex;
    gap: 1rem;
}

/* Sort Dropdown */
.sort-dropdown {
    position: relative;
    display: inline-block;
}

.sort-btn {
    background: rgba(59, 130, 246, 0.1);
    color: #3b82f6;
    border: 1px solid rgba(59, 130, 246, 0.3);
    padding: 0.75rem 1rem;
    border-radius: 8px;
    font-size: 0.9rem;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    min-width: 160px;
    justify-content: space-between;
}

.sort-btn:hover {
    background: rgba(59, 130, 246, 0.2);
    border-color: rgba(59, 130, 246, 0.5);
}

.dropdown-arrow {
    transition: transform 0.3s ease;
}

.sort-dropdown.open .dropdown-arrow {
    transform: rotate(180deg);
}

.sort-dropdown-menu {
    position: absolute;
    top: 100%;
    right: 0;
    min-width: 200px;
    background: var(--bg-card);
    border: 1px solid rgba(59, 130, 246, 0.3);
    border-radius: 8px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
    backdrop-filter: blur(20px);
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.3s ease;
    margin-top: 0.5rem;
}

.sort-dropdown.open .sort-dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.sort-option {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    width: 100%;
    padding: 0.75rem 1rem;
    background: transparent;
    border: none;
    color: #94a3b8;
    font-size: 0.875rem;
    cursor: pointer;
    transition: all 0.3s ease;
    text-align: left;
}

.sort-option:hover {
    background: rgba(59, 130, 246, 0.1);
    color: #3b82f6;
}

.sort-option.active {
    background: rgba(59, 130, 246, 0.15);
    color: #3b82f6;
    font-weight: 600;
}

.sort-option:first-child {
    border-top-left-radius: 7px;
    border-top-right-radius: 7px;
}

.sort-option:last-child {
    border-bottom-left-radius: 7px;
    border-bottom-right-radius: 7px;
}

/* News Grid */
.news-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 2rem;
    margin-bottom: 3rem;
}

.news-card {
    background: linear-gradient(135deg, rgba(14, 18, 31, 0.8) 0%, rgba(20, 27, 45, 0.6) 100%);
    border-radius: 12px;
    overflow: hidden;
    transition: all 0.3s ease;
    border: 1px solid rgba(59, 130, 246, 0.1);
    position: relative;
}

.news-card:hover {
    transform: translateY(-4px);
    border-color: rgba(59, 130, 246, 0.3);
    box-shadow: 0 15px 30px rgba(59, 130, 246, 0.1);
}

.news-image {
    position: relative;
    height: 180px;
    overflow: hidden;
}

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

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

.image-overlay {
    position: absolute;
    top: 0.75rem;
    left: 0.75rem;
    right: 0.75rem;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
}

.featured-indicator {
    background: linear-gradient(135deg, #f59e0b 0%, #f97316 100%);
    color: white;
    padding: 0.25rem 0.5rem;
    border-radius: 50%;
    font-size: 0.8rem;
    font-weight: 600;
}

.news-content {
    padding: 1.25rem;
}

.news-content h3 {
    margin-bottom: 0.75rem;
}

.news-content h3 a {
    color: #f8fafc;
    text-decoration: none;
    font-size: 1.1rem;
    font-weight: 600;
    line-height: 1.4;
    transition: color 0.3s ease;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.news-content h3 a:hover {
    color: #3b82f6;
}

.news-content .excerpt {
    margin-bottom: 1rem;
    -webkit-line-clamp: 2;
}

/* Article Meta */
.article-meta,
.news-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.5rem;
    font-size: 0.8rem;
    color: #94a3b8;
}

.meta-left,
.meta-right {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.author,
.date,
.read-time {
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

.edit-link {
    color: #f59e0b;
    text-decoration: none;
    font-weight: 500;
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
    transition: all 0.3s ease;
}

.edit-link:hover {
    background: rgba(245, 158, 11, 0.1);
    color: #fbbf24;
}

/* Load More */
.load-more-container {
    text-align: center;
    margin-top: 3rem;
}

.load-more-btn {
    background: linear-gradient(135deg, #3b82f6 0%, #8b5cf6 100%);
    color: white;
    border: none;
    padding: 1rem 2rem;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.load-more-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(59, 130, 246, 0.3);
}

/* Empty State */
.empty-state {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 300px;
    text-align: center;
}

.empty-content {
    max-width: 400px;
}

.empty-content svg {
    color: #64748b;
    margin-bottom: 1rem;
}

.empty-content h3 {
    color: #f8fafc;
    margin-bottom: 0.5rem;
    font-size: 1.25rem;
}

.empty-content p {
    color: #94a3b8;
    font-size: 0.9rem;
    line-height: 1.6;
}

/* ===================================
   NEWS ARTICLE STYLES
   =================================== */

/* Breadcrumb */
.breadcrumb {
    padding: 1rem 2rem;
    max-width: 800px;
    margin: 0 auto;
    font-size: 0.9rem;
    color: #94a3b8;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.breadcrumb a {
    color: #3b82f6;
    text-decoration: none;
    transition: color 0.3s ease;
}

.breadcrumb a:hover {
    color: #60a5fa;
}

.separator {
    color: #64748b;
}

.current-category,
.current-title {
    color: #cbd5e1;
}

.current-title {
    max-width: 200px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Article */
.news-article {
    max-width: 800px;
    margin: 0 auto;
    padding: 0 2rem 4rem;
}

.article-header {
    margin-bottom: 2rem;
}

.article-meta-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
    flex-wrap: wrap;
    gap: 1rem;
}

.admin-actions {
    display: flex;
    gap: 1rem;
}

#articleTitle {
    font-size: 2.5rem;
    font-weight: 700;
    color: #f8fafc;
    line-height: 1.2;
    margin-bottom: 1rem;
}

.article-excerpt {
    font-size: 1.25rem;
    color: #cbd5e1;
    line-height: 1.6;
    margin-bottom: 1.5rem;
    font-style: italic;
}

.share-btn {
    background: rgba(59, 130, 246, 0.1);
    color: #3b82f6;
    border: 1px solid rgba(59, 130, 246, 0.3);
    padding: 0.5rem 1rem;
    border-radius: 6px;
    font-size: 0.9rem;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.share-btn:hover {
    background: rgba(59, 130, 246, 0.2);
    border-color: rgba(59, 130, 246, 0.5);
}

/* Article Image */
.article-image {
    margin-bottom: 2rem;
    border-radius: 12px;
    overflow: hidden;
}

.article-image img {
    width: 100%;
    height: auto;
    display: block;
}

/* Article Body */
.article-body {
    margin-bottom: 3rem;
}

.article-content {
    color: #e2e8f0;
    font-size: 1.1rem;
    line-height: 1.8;
}

.article-content h1,
.article-content h2,
.article-content h3,
.article-content h4,
.article-content h5,
.article-content h6 {
    color: #f8fafc;
    margin: 2rem 0 1rem;
    font-weight: 600;
    line-height: 1.3;
}

.article-content h2 {
    font-size: 1.8rem;
}

.article-content h3 {
    font-size: 1.5rem;
}

.article-content p {
    margin-bottom: 1.5rem;
}

.article-content a {
    color: #3b82f6;
    text-decoration: underline;
    transition: color 0.3s ease;
}

.article-content a:hover {
    color: #60a5fa;
}

.article-content img {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    margin: 1.5rem 0;
}

.article-content blockquote {
    border-left: 4px solid #3b82f6;
    background: rgba(59, 130, 246, 0.1);
    padding: 1rem 1.5rem;
    margin: 1.5rem 0;
    border-radius: 0 8px 8px 0;
    font-style: italic;
}

.article-content ul,
.article-content ol {
    margin-bottom: 1.5rem;
    padding-left: 2rem;
}

.article-content li {
    margin-bottom: 0.5rem;
}

/* Article Footer */
.article-footer {
    border-top: 1px solid rgba(59, 130, 246, 0.1);
    padding-top: 2rem;
    margin-top: 3rem;
}

.article-tags {
    margin-bottom: 2rem;
    display: flex;
    align-items: center;
    gap: 1rem;
    flex-wrap: wrap;
}

.tags-label {
    color: #94a3b8;
    font-weight: 500;
}

.tag {
    background: rgba(59, 130, 246, 0.1);
    color: #3b82f6;
    padding: 0.5rem 1rem;
    border-radius: 20px;
    font-size: 0.9rem;
    border: 1px solid rgba(59, 130, 246, 0.3);
}

.share-section h4 {
    color: #f8fafc;
    margin-bottom: 1rem;
    font-size: 1.1rem;
}

.share-buttons {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

.share-buttons button {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1rem;
    border-radius: 8px;
    font-size: 0.9rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    border: 1px solid;
}

.share-twitter {
    background: rgba(29, 161, 242, 0.1);
    color: #1da1f2;
    border-color: rgba(29, 161, 242, 0.3);
}

.share-twitter:hover {
    background: rgba(29, 161, 242, 0.2);
    border-color: rgba(29, 161, 242, 0.5);
}

.share-linkedin {
    background: rgba(0, 119, 181, 0.1);
    color: #0077b5;
    border-color: rgba(0, 119, 181, 0.3);
}

.share-linkedin:hover {
    background: rgba(0, 119, 181, 0.2);
    border-color: rgba(0, 119, 181, 0.5);
}

.share-copy {
    background: rgba(59, 130, 246, 0.1);
    color: #3b82f6;
    border-color: rgba(59, 130, 246, 0.3);
}

.share-copy:hover {
    background: rgba(59, 130, 246, 0.2);
    border-color: rgba(59, 130, 246, 0.5);
}

.share-buttons svg {
    width: 16px;
    height: 16px;
}

/* Related Articles */
.related-articles {
    max-width: 1200px;
    margin: 0 auto;
    padding: 4rem 2rem;
    border-top: 1px solid rgba(59, 130, 246, 0.1);
}

.related-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
}

.related-article {
    background: linear-gradient(135deg, rgba(14, 18, 31, 0.8) 0%, rgba(20, 27, 45, 0.6) 100%);
    border-radius: 12px;
    overflow: hidden;
    transition: all 0.3s ease;
    border: 1px solid rgba(59, 130, 246, 0.1);
}

.related-article:hover {
    transform: translateY(-4px);
    border-color: rgba(59, 130, 246, 0.3);
    box-shadow: 0 15px 30px rgba(59, 130, 246, 0.1);
}

.related-image {
    height: 120px;
    overflow: hidden;
}

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

.related-article:hover .related-image img {
    transform: scale(1.05);
}

.related-content {
    padding: 1rem;
}

.related-category {
    display: inline-block;
    background: rgba(59, 130, 246, 0.1);
    color: #3b82f6;
    padding: 0.25rem 0.75rem;
    border-radius: 12px;
    font-size: 0.7rem;
    font-weight: 500;
    margin-bottom: 0.5rem;
    border: 1px solid rgba(59, 130, 246, 0.3);
}

.related-content h4 {
    margin-bottom: 0.5rem;
}

.related-content h4 a {
    color: #f8fafc;
    text-decoration: none;
    font-size: 1rem;
    font-weight: 600;
    line-height: 1.3;
    transition: color 0.3s ease;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.related-content h4 a:hover {
    color: #3b82f6;
}

.related-meta {
    display: flex;
    gap: 1rem;
    font-size: 0.8rem;
    color: #94a3b8;
}

/* Error State */
.error-state {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 400px;
    text-align: center;
    padding: 2rem;
}

.error-content {
    max-width: 400px;
}

.error-content svg {
    color: #ef4444;
    margin-bottom: 1rem;
}

.error-content h2 {
    color: #f8fafc;
    margin-bottom: 0.5rem;
    font-size: 1.5rem;
}

.error-content p {
    color: #94a3b8;
    font-size: 0.9rem;
    line-height: 1.6;
    margin-bottom: 1.5rem;
}

.back-btn {
    background: linear-gradient(135deg, #3b82f6 0%, #8b5cf6 100%);
    color: white;
    padding: 0.75rem 1.5rem;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s ease;
    display: inline-block;
}

.back-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(59, 130, 246, 0.3);
}

/* ===================================
   HOME PAGE NEWS SECTION
   =================================== */

.latest-news {
    max-width: 1200px;
    margin: 0 auto;
    padding: 4rem 2rem;
}

.latest-news .section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
}

.latest-news .news-grid {
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1.5rem;
}

/* ===================================
   RESPONSIVE DESIGN
   =================================== */

@media (max-width: 768px) {
    .news-hero .hero-content h1 {
        font-size: 2.5rem;
    }
    
    .news-hero .hero-content p {
        font-size: 1rem;
    }
    
    .featured-news-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    
    .news-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    
    .category-filters {
        justify-content: center;
    }
    
    .filter-btn {
        padding: 0.6rem 1.2rem;
        font-size: 0.85rem;
    }
    
    .news-section .section-header {
        flex-direction: column;
        align-items: flex-start;
    }
    
    #articleTitle {
        font-size: 2rem;
    }
    
    .article-excerpt {
        font-size: 1.1rem;
    }
    
    .breadcrumb {
        padding: 1rem 1rem;
    }
    
    .news-article {
        padding: 0 1rem 4rem;
    }
    
    .related-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    
    .share-buttons {
        justify-content: center;
    }
    
    .article-meta,
    .news-meta {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.75rem;
    }
    
    .meta-left,
    .meta-right {
        width: 100%;
        justify-content: space-between;
    }
    
    /* Sort dropdown mobile */
    .sort-dropdown-menu {
        left: 0;
        right: auto;
        min-width: 180px;
    }
    
    .sort-btn {
        min-width: 140px;
        padding: 0.5rem 0.75rem;
        font-size: 0.8rem;
    }
    
    .sort-option {
        padding: 0.6rem 0.75rem;
        font-size: 0.8rem;
    }
}
