/* ==========================================================================
   Futuristic / Modern News Page Styles
   ========================================================================== */

:root {
    --news-bg: #f8f9fc;
    --news-white: rgba(255, 255, 255, 0.85);
    --news-glass-bg: rgba(255, 255, 255, 0.65);
    --news-glass-border: rgba(255, 255, 255, 0.4);
    --news-primary: #1a73e8;
    --news-primary-glow: rgba(26, 115, 232, 0.4);
    --news-secondary: #0b1f33;
    --news-accent: #fca311;
    --news-text-dark: #1e293b;
    --news-text-muted: #64748b;
    --news-radius-lg: 24px;
    --news-radius-md: 16px;
    --news-shadow-soft: 0 10px 40px -10px rgba(0, 0, 0, 0.08);
    --news-shadow-hover: 0 20px 40px -10px var(--news-primary-glow);
    --news-transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
}

body {
    background-color: var(--news-bg);
    overflow-x: hidden;
}

/* Base Layout for the page */
.news-page {
    padding-bottom: 80px;
    position: relative;
    overflow: hidden;
}

/* Glowing Background Orbs */
body::before {
    content: '';
    position: fixed;
    top: -10%;
    left: -10%;
    width: 60vw;
    height: 60vw;
    background: radial-gradient(circle, rgba(26, 115, 232, 0.08) 0%, transparent 70%);
    border-radius: 50%;
    z-index: -1;
    pointer-events: none;
}

body::after {
    content: '';
    position: fixed;
    bottom: -10%;
    right: -10%;
    width: 60vw;
    height: 60vw;
    background: radial-gradient(circle, rgba(252, 163, 17, 0.05) 0%, transparent 70%);
    border-radius: 50%;
    z-index: -1;
    pointer-events: none;
}

/* =========================================
   Hero Section
   ========================================= */
.news-hero {
    padding: 100px 0 80px;
    text-align: center;
    position: relative;
    z-index: 10;
    /* Removing the static image and using clean futuristic typography instead */
}

.news-hero-content h1 {
    font-size: 3.8rem;
    font-weight: 800;
    color: var(--news-secondary);
    background: linear-gradient(135deg, var(--news-secondary) 0%, var(--news-primary) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    margin-bottom: 20px;
    letter-spacing: -1px;
}

.news-hero-content p {
    font-size: 1.3rem;
    color: var(--news-text-muted);
    max-width: 700px;
    margin: 0 auto;
    line-height: 1.6;
}

/* =========================================
   Glassmorphism Main News Grid
   ========================================= */
.news-content {
    margin-bottom: 80px;
    position: relative;
    z-index: 10;
}

.news-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 30px;
}

.news-card {
    background: var(--news-glass-bg);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--news-glass-border);
    border-radius: var(--news-radius-lg);
    overflow: hidden;
    position: relative;
    transition: var(--news-transition);
    box-shadow: var(--news-shadow-soft);
    display: flex;
    flex-direction: column;
    height: 100%;
}

.news-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: linear-gradient(90deg, var(--news-primary), var(--news-accent));
    opacity: 0;
    transition: var(--news-transition);
    z-index: 2;
}

.news-card:hover {
    transform: translateY(-10px);
    box-shadow: var(--news-shadow-hover);
    border-color: rgba(26, 115, 232, 0.2);
}

.news-card:hover::before {
    opacity: 1;
}

.news-image {
    position: relative;
    height: 220px;
    overflow: hidden;
    background: rgba(26, 115, 232, 0.05);
    /* Placeholder bg */
}

.news-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.news-card:hover .news-image img {
    transform: scale(1.05);
}

.news-card.featured {
    grid-column: 1 / -1;
    flex-direction: row;
}

.news-card.featured .news-image {
    height: auto;
    width: 50%;
    min-height: 350px;
}

@media (max-width: 992px) {
    .news-card.featured {
        flex-direction: column;
    }

    .news-card.featured .news-image {
        width: 100%;
        min-height: 250px;
    }
}

.news-card .news-content-inner {
    padding: 30px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.news-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.news-category {
    display: inline-block;
    background: rgba(26, 115, 232, 0.1);
    color: var(--news-primary);
    padding: 6px 16px;
    border-radius: 30px;
    font-size: 0.85rem;
    font-weight: 700;
}

.news-date {
    color: var(--news-text-muted);
    font-size: 0.9rem;
    font-weight: 500;
}

.news-card h2 {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--news-text-dark);
    margin-bottom: 15px;
    line-height: 1.4;
}

.news-card p {
    color: var(--news-text-muted);
    font-size: 1rem;
    line-height: 1.7;
    margin-bottom: 25px;
    flex-grow: 1;
}

.read-more {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: var(--news-primary);
    font-weight: 700;
    text-decoration: none;
    transition: var(--news-transition);
    align-self: flex-start;
}

.read-more:hover {
    color: var(--news-secondary);
    gap: 12px;
}

.read-more::after {
    content: '\f060';
    /* FontAwesome arrow-left for RTL */
    font-family: 'Font Awesome 5 Free', 'Font Awesome 6 Free';
    font-weight: 900;
    font-size: 0.9em;
    transition: var(--news-transition);
}

/* =========================================
   Category Filter Pills — Futuristic
   ========================================= */
.news-categories {
    margin-bottom: 50px;
    position: relative;
    z-index: 10;
}

.cat-filter-wrap {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    justify-content: center;
    padding: 28px 24px;
    background: rgba(255, 255, 255, 0.55);
    backdrop-filter: blur(18px);
    -webkit-backdrop-filter: blur(18px);
    border: 1px solid rgba(255, 255, 255, 0.5);
    border-radius: 60px;
    box-shadow: 0 8px 40px -8px rgba(26, 115, 232, 0.10), 0 2px 0 rgba(255, 255, 255, 0.7) inset;
}

.cat-pill {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 9px 22px;
    border-radius: 100px;
    font-size: 0.92rem;
    font-weight: 600;
    color: var(--news-text-dark);
    text-decoration: none;
    background: rgba(255, 255, 255, 0.7);
    border: 1.5px solid rgba(26, 115, 232, 0.15);
    transition: all 0.25s cubic-bezier(0.34, 1.56, 0.64, 1);
    position: relative;
    overflow: hidden;
    white-space: nowrap;
}

.cat-pill i {
    font-size: 0.85em;
    opacity: 0.75;
}

.cat-pill::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, var(--news-primary), #5b6fd6);
    opacity: 0;
    transition: opacity 0.25s ease;
    border-radius: inherit;
    z-index: 0;
}

.cat-pill>* {
    position: relative;
    z-index: 1;
}

.cat-pill:hover {
    transform: translateY(-3px) scale(1.04);
    border-color: transparent;
    color: #fff;
    box-shadow: 0 8px 24px -4px rgba(26, 115, 232, 0.35);
}

.cat-pill:hover::before {
    opacity: 1;
}

.cat-pill:hover i {
    opacity: 1;
}

.cat-pill.active {
    background: linear-gradient(135deg, var(--news-primary) 0%, #5b6fd6 100%);
    color: #fff;
    border-color: transparent;
    box-shadow: 0 6px 20px -4px rgba(26, 115, 232, 0.45),
        0 0 0 3px rgba(26, 115, 232, 0.15);
    transform: translateY(-2px);
}

.cat-pill.active i {
    opacity: 1;
}

.cat-pill.active::before {
    display: none;
}

@media (max-width: 600px) {
    .cat-filter-wrap {
        border-radius: 20px;
        padding: 18px 14px;
        gap: 8px;
    }

    .cat-pill {
        font-size: 0.82rem;
        padding: 7px 14px;
    }
}



/* =========================================
   Newsletter CTA Section
   ========================================= */
.newsletter-section {
    position: relative;
    z-index: 10;
    margin-bottom: 50px;
}

.newsletter-content {
    background: linear-gradient(135deg, var(--news-secondary) 0%, var(--news-primary) 100%);
    border-radius: var(--news-radius-lg);
    padding: 50px;
    text-align: center;
    color: white;
    box-shadow: 0 15px 35px rgba(26, 115, 232, 0.2);
    position: relative;
    overflow: hidden;
}

/* Decorative circles */
.newsletter-content::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -20%;
    width: 300px;
    height: 300px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
}

.newsletter-content::after {
    content: '';
    position: absolute;
    bottom: -50%;
    right: -20%;
    width: 400px;
    height: 400px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 50%;
}

.newsletter-content h2 {
    font-size: 2.2rem;
    font-weight: 800;
    margin-bottom: 15px;
    position: relative;
    z-index: 2;
}

.newsletter-content p {
    font-size: 1.1rem;
    opacity: 0.9;
    margin-bottom: 30px;
    position: relative;
    z-index: 2;
}

.newsletter-form {
    display: flex;
    max-width: 500px;
    margin: 0 auto;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 100px;
    padding: 8px;
    position: relative;
    z-index: 2;
}

.newsletter-form input {
    flex-grow: 1;
    background: transparent;
    border: none;
    padding: 15px 25px;
    color: white;
    font-size: 1rem;
    outline: none;
}

.newsletter-form input::placeholder {
    color: rgba(255, 255, 255, 0.7);
}

.newsletter-form button {
    background: var(--news-accent);
    color: var(--news-secondary);
    border: none;
    padding: 12px 30px;
    border-radius: 100px;
    font-weight: 700;
    font-size: 1rem;
    cursor: pointer;
    transition: var(--news-transition);
}

.newsletter-form button:hover {
    background: #fff;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

/* Newsletter Flash Alerts */
.newsletter-alert {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 14px 20px;
    border-radius: 12px;
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 20px;
    position: relative;
    z-index: 2;
    backdrop-filter: blur(10px);
}

.newsletter-alert--success {
    background: rgba(40, 167, 69, 0.2);
    border: 1px solid rgba(40, 167, 69, 0.4);
    color: #d4edda;
}

.newsletter-alert--info {
    background: rgba(23, 162, 184, 0.2);
    border: 1px solid rgba(23, 162, 184, 0.4);
    color: #d1ecf1;
}

.newsletter-alert--error {
    background: rgba(220, 53, 69, 0.2);
    border: 1px solid rgba(220, 53, 69, 0.4);
    color: #f8d7da;
}

/* Pagination Adjustments */
.news-content svg {
    max-width: 25px;
}

.news-content nav[role="navigation"] {
    margin-top: 50px;
    display: flex;
    justify-content: center;
}

/* =========================================
   Responsive Adjustments
   ========================================= */
@media (max-width: 768px) {
    .news-hero {
        padding: 60px 0 40px;
    }

    .news-hero-content h1 {
        font-size: 2.5rem;
    }

    .news-card.featured {
        flex-direction: column;
    }

    .news-card.featured .news-image {
        width: 100%;
        min-height: 250px;
    }

    .newsletter-content {
        padding: 30px 20px;
    }

    .newsletter-form {
        flex-direction: column;
        border-radius: var(--news-radius-md);
        background: transparent;
        border: none;
        padding: 0;
        gap: 15px;
    }

    .newsletter-form input,
    .newsletter-form button {
        width: 100%;
        border-radius: var(--news-radius-md);
    }

    .newsletter-form input {
        background: rgba(255, 255, 255, 0.1);
        border: 1px solid rgba(255, 255, 255, 0.2);
    }
}