/* style/news.css */
.page-news {
    font-family: 'Arial', sans-serif;
    line-height: 1.6;
    color: #333333; /* Default text color for light background */
    background-color: var(--background-color, #FFFFFF); /* Inherit from shared or default to white */
}

.page-news__container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
    box-sizing: border-box;
}

/* Hero Section */
.page-news__hero-section {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    min-height: 600px;
    padding-top: var(--header-offset, 120px); /* Ensure content is not hidden by fixed header */
    overflow: hidden;
    background-color: #26A9E0;
    color: #FFFFFF;
}

.page-news__hero-image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    z-index: 1;
}

.page-news__hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 2;
}

.page-news__hero-content {
    position: relative;
    z-index: 3;
    max-width: 800px;
    padding: 20px;
}

.page-news__hero-title {
    font-size: 3.5em;
    margin-bottom: 20px;
    color: #FFFFFF;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.7);
}

.page-news__hero-description {
    font-size: 1.2em;
    margin-bottom: 40px;
    color: #f0f0f0;
}

/* Section Titles and Descriptions */
.page-news__section-title {
    font-size: 2.5em;
    text-align: center;
    margin-bottom: 20px;
    color: #26A9E0;
}

.page-news__section-description {
    font-size: 1.1em;
    text-align: center;
    max-width: 800px;
    margin: 0 auto 50px auto;
    color: #555555;
}

/* Featured Articles Grid */
.page-news__featured-articles {
    padding: 80px 0;
    background-color: #FFFFFF;
}

.page-news__article-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.page-news__article-card {
    background: #ffffff;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: flex;
    flex-direction: column;
}

.page-news__article-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.15);
}

.page-news__article-image {
    width: 100%;
    height: 250px;
    object-fit: cover;
    display: block;
}

.page-news__card-content {
    padding: 20px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.page-news__card-title {
    font-size: 1.5em;
    margin-bottom: 10px;
    color: #26A9E0;
}

.page-news__card-title a {
    color: #26A9E0;
    text-decoration: none;
    transition: color 0.3s ease;
}

.page-news__card-title a:hover {
    color: #1a7fb8;
}

.page-news__card-excerpt {
    font-size: 0.95em;
    color: #666666;
    margin-bottom: 15px;
    flex-grow: 1;
}

.page-news__read-more {
    display: inline-block;
    color: #26A9E0;
    text-decoration: none;
    font-weight: bold;
    transition: color 0.3s ease;
}

.page-news__read-more:hover {
    color: #1a7fb8;
}

/* Latest Updates List */
.page-news__latest-updates {
    padding: 80px 0;
    background-color: #26A9E0;
    color: #FFFFFF;
}

.page-news__latest-updates .page-news__section-title,
.page-news__latest-updates .page-news__section-description {
    color: #FFFFFF;
}

.page-news__update-list {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.page-news__update-item {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    overflow: hidden;
    padding: 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.page-news__update-image {
    width: 100%;
    max-width: 400px; /* Constrain image width */
    height: 250px; /* Fixed height for consistency */
    object-fit: cover;
    border-radius: 8px;
    margin-bottom: 20px;
    display: block;
}

.page-news__update-title {
    font-size: 1.3em;
    margin-bottom: 10px;
    color: #FFFFFF;
}

.page-news__update-title a {
    color: #FFFFFF;
    text-decoration: none;
    transition: color 0.3s ease;
}

.page-news__update-title a:hover {
    color: #f0f0f0;
}

.page-news__update-excerpt {
    font-size: 0.9em;
    color: #f0f0f0;
    margin-bottom: 15px;
}

/* Categories Grid */
.page-news__categories {
    padding: 80px 0;
    background-color: #FFFFFF;
}

.page-news__category-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 25px;
}

.page-news__category-card {
    background: #f8f8f8;
    border-radius: 10px;
    padding: 30px;
    text-align: center;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    text-decoration: none;
    color: #333333;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

.page-news__category-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.page-news__category-title {
    font-size: 1.8em;
    margin-bottom: 10px;
    color: #26A9E0;
}

.page-news__category-description {
    font-size: 0.95em;
    color: #666666;
}

/* Call to Action Section */
.page-news__cta-section {
    padding: 80px 0;
    background-color: #26A9E0;
    color: #FFFFFF;
    text-align: center;
}

.page-news__cta-title {
    font-size: 2.8em;
    margin-bottom: 20px;
    color: #FFFFFF;
}

.page-news__cta-description {
    font-size: 1.2em;
    max-width: 900px;
    margin: 0 auto 40px auto;
    color: #f0f0f0;
}

.page-news__cta-buttons {
    display: flex;
    justify-content: center;
    gap: 20px;
    flex-wrap: wrap;
}

/* Buttons */
.page-news__btn-primary,
.page-news__btn-secondary {
    display: inline-block;
    padding: 15px 30px;
    border-radius: 5px;
    font-size: 1.1em;
    font-weight: bold;
    text-decoration: none;
    transition: all 0.3s ease;
    box-sizing: border-box;
    white-space: normal;
    word-wrap: break-word;
    text-align: center;
}

.page-news__btn-primary {
    background: #EA7C07; /* Login color for primary action */
    color: #FFFFFF;
    border: 2px solid #EA7C07;
}

.page-news__btn-primary:hover {
    background: #d46f00;
    border-color: #d46f00;
}

.page-news__btn-secondary {
    background: #FFFFFF;
    color: #26A9E0;
    border: 2px solid #26A9E0;
}

.page-news__btn-secondary:hover {
    background: #e0f4ff;
    color: #1a7fb8;
    border-color: #1a7fb8;
}

/* FAQ Section */
.page-news__faq-section {
    padding: 80px 0;
    background-color: #f8f8f8;
}

.page-news__faq-list {
    max-width: 900px;
    margin: 0 auto;
}

.page-news__faq-item {
    background: #ffffff;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    margin-bottom: 15px;
    overflow: hidden;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
}

.page-news__faq-question {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    font-size: 1.1em;
    font-weight: bold;
    color: #26A9E0;
    cursor: pointer;
    background-color: #f0f8ff;
    border-bottom: 1px solid #e0e0e0;
}

.page-news__faq-question:hover {
    background-color: #e6f2ff;
}

.page-news__faq-toggle {
    font-size: 1.5em;
    line-height: 1;
    transition: transform 0.3s ease;
}

.page-news__faq-item.active .page-news__faq-toggle {
    transform: rotate(45deg); /* Plus sign rotates to form an 'x' or minus */
    content: '−'; /* Change to minus sign */
}

.page-news__faq-answer {
    max-height: 0;
    overflow: hidden;
    padding: 0 20px;
    transition: max-height 0.3s ease-out, padding 0.3s ease-out;
    color: #555555;
}

.page-news__faq-item.active .page-news__faq-answer {
    max-height: 1000px !important; /* Sufficiently large to show content */
    padding: 20px !important;
}

.page-news__faq-answer p {
    margin-bottom: 0;
}

/* Dark/Light Background Helpers */
.page-news__dark-section {
    background-color: #26A9E0;
    color: #FFFFFF;
}

.page-news__light-bg {
    background-color: #FFFFFF;
    color: #333333;
}

/* Responsive Design */
@media (max-width: 1024px) {
    .page-news__hero-title {
        font-size: 3em;
    }
    .page-news__section-title {
        font-size: 2em;
    }
    .page-news__cta-title {
        font-size: 2.2em;
    }
}

@media (max-width: 768px) {
    .page-news {
        font-size: 16px;
        line-height: 1.6;
    }
    .page-news__container {
        padding: 15px;
    }
    .page-news__hero-section {
        min-height: 450px;
        padding-top: var(--header-offset, 120px) !important;
    }
    .page-news__hero-title {
        font-size: 2.2em;
    }
    .page-news__hero-description {
        font-size: 1em;
    }
    .page-news__section-title {
        font-size: 1.8em;
    }
    .page-news__section-description {
        font-size: 1em;
        margin-bottom: 30px;
    }
    .page-news__featured-articles, .page-news__latest-updates, .page-news__categories, .page-news__cta-section, .page-news__faq-section {
        padding: 40px 0;
    }
    .page-news__article-grid, .page-news__update-list, .page-news__category-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    .page-news__article-image, .page-news__update-image {
        height: 200px;
    }
    .page-news__cta-title {
        font-size: 1.8em;
    }
    .page-news__cta-description {
        font-size: 1em;
        margin-bottom: 30px;
    }
    .page-news__cta-buttons {
        flex-direction: column;
        gap: 15px;
    }
    .page-news__btn-primary, .page-news__btn-secondary {
        width: 100% !important;
        max-width: 100% !important;
        padding: 12px 20px;
        font-size: 1em;
    }
    /* Mobile image and video responsive fix */
    .page-news img {
        max-width: 100% !important;
        height: auto !important;
        display: block !important;
    }
    .page-news video {
        max-width: 100% !important;
        width: 100% !important;
        height: auto !important;
        display: block !important;
    }
    .page-news__section, .page-news__card, .page-news__container, .page-news__video-section, .page-news__video-container, .page-news__video-wrapper, .page-news__cta-buttons, .page-news__button-group, .page-news__btn-container {
        max-width: 100% !important;
        width: 100% !important;
        box-sizing: border-box !important;
        padding-left: 15px;
        padding-right: 15px;
        overflow: hidden !important;
    }
    /* Ensure content images are not too small */
    .page-news__article-image, .page-news__update-image {
        min-width: 200px;
        min-height: 200px;
    }
}

@media (max-width: 480px) {
    .page-news__hero-title {
        font-size: 1.8em;
    }
    .page-news__hero-description {
        font-size: 0.9em;
    }
    .page-news__btn-primary, .page-news__btn-secondary {
        padding: 10px 15px;
        font-size: 0.9em;
    }
}