:root {
    --primary-color: #26A9E0;
    --secondary-color: #FFFFFF;
    --text-dark: #333333;
    --text-light: #ffffff;
    --background-light: #f8f9fa;
    --border-color: #e0e0e0;
    --button-login: #EA7C07; /* Custom color for login buttons */
}

/* Base styles for the news page */
.page-news {
    font-family: Arial, sans-serif;
    line-height: 1.6;
    color: var(--text-dark); /* Default text color for light background */
    background-color: var(--secondary-color); /* Body background is light */
}

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

.page-news__section-title {
    font-size: 2.5em;
    color: var(--primary-color);
    text-align: center;
    margin-bottom: 40px;
    font-weight: bold;
}

.page-news__section-title--white {
    color: var(--text-light);
}

/* Hero Section */
.page-news__hero-section {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 60px 20px;
    padding-top: var(--header-offset, 120px); /* Ensure space below fixed header */
    background: linear-gradient(135deg, var(--primary-color) 0%, #34C6F0 100%); /* Light blue gradient */
    color: var(--text-light);
    overflow: hidden;
}

.page-news__hero-container {
    position: relative;
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    z-index: 1; /* Ensure content is above any potential background overlays */
}

.page-news__hero-image {
    width: 100%;
    height: auto;
    max-width: 100%;
    display: block;
    border-radius: 12px;
    object-fit: cover;
    margin-bottom: 40px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}

.page-news__hero-content {
    position: relative;
    z-index: 2;
    text-align: center;
    width: 100%;
    max-width: 800px;
}

.page-news__main-title {
    font-size: 3.2em;
    margin-bottom: 20px;
    line-height: 1.2;
    font-weight: 800;
    color: var(--text-light);
    text-shadow: 2px 2px 4px rgba(0,0,0,0.3);
}

.page-news__intro-text {
    font-size: 1.2em;
    margin-bottom: 30px;
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
    color: var(--text-light);
}

.page-news__cta-button {
    display: inline-block;
    padding: 15px 40px;
    background: var(--button-login); /* Use custom login color for CTA */
    color: var(--text-light);
    text-decoration: none;
    border-radius: 50px;
    font-size: 1.1em;
    font-weight: bold;
    margin-top: 20px;
    transition: all 0.3s ease;
    box-shadow: 0 6px 15px rgba(0, 0, 0, 0.2);
    border: none;
    cursor: pointer;
}

.page-news__cta-button:hover {
    background: #FF8C00; /* Slightly darker orange on hover */
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.3);
}

/* Featured Articles Section */
.page-news__featured-articles {
    background-color: var(--background-light);
    padding: 60px 0;
    color: var(--text-dark);
}

.page-news__articles-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 30px;
    justify-content: center;
}

.page-news__article-card {
    background: var(--secondary-color);
    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(-8px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

.page-news__article-image-wrapper {
    width: 100%;
    height: 250px; /* Fixed height for consistency */
    overflow: hidden;
}

.page-news__article-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.3s ease;
}

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

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

.page-news__article-title {
    font-size: 1.5em;
    margin-bottom: 15px;
    font-weight: 700;
    line-height: 1.4;
}

.page-news__article-title a {
    color: var(--primary-color);
    text-decoration: none;
    transition: color 0.3s ease;
}

.page-news__article-title a:hover {
    color: #1a7fb0; /* Slightly darker primary color */
}

.page-news__article-summary {
    font-size: 0.95em;
    color: #666;
    margin-bottom: 20px;
    flex-grow: 1;
}

.page-news__read-more-link {
    display: inline-block;
    color: var(--button-login);
    text-decoration: none;
    font-weight: bold;
    transition: color 0.3s ease;
    margin-top: auto; /* Push to bottom */
}

.page-news__read-more-link:hover {
    color: #FF8C00;
    text-decoration: underline;
}

.page-news__read-more-link--white {
    color: var(--text-light);
}

.page-news__read-more-link--white:hover {
    color: #f0f0f0;
    text-decoration: underline;
}

/* Latest Updates Section */
.page-news__latest-updates {
    background-color: var(--primary-color);
    padding: 60px 0;
    color: var(--text-light);
}

.page-news__updates-list {
    display: flex;
    flex-direction: column;
    gap: 30px;
}

.page-news__update-item {
    background: rgba(255, 255, 255, 0.1); /* Slightly transparent white for dark background */
    border-radius: 10px;
    padding: 30px;
    display: flex;
    align-items: center;
    gap: 25px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.page-news__update-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.2);
}

.page-news__update-content {
    flex: 1;
    color: var(--text-light);
}

.page-news__update-title {
    font-size: 1.6em;
    margin-bottom: 10px;
    font-weight: 700;
    line-height: 1.3;
}

.page-news__update-title a {
    color: var(--text-light);
    text-decoration: none;
    transition: color 0.3s ease;
}

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

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

.page-news__update-summary {
    font-size: 1em;
    color: #f0f0f0;
    margin-bottom: 20px;
}

.page-news__update-image-wrapper {
    flex-shrink: 0;
    width: 250px;
    height: 180px;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.15);
}

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

/* FAQ Section */
.page-news__faq-section {
    background-color: var(--secondary-color);
    padding: 60px 0;
    color: var(--text-dark);
}

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

.page-news__faq-item {
    margin-bottom: 15px;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
}

.page-news__faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s cubic-bezier(0.4, 0, 0.2, 1), padding 0.4s ease, opacity 0.4s ease;
    padding: 0 25px;
    opacity: 0;
    background: var(--background-light);
    color: var(--text-dark);
}

.page-news__faq-item.active .page-news__faq-answer {
    max-height: 2000px !important; /* Sufficiently large to contain any content */
    padding: 25px !important;
    opacity: 1;
    border-top: 1px solid var(--border-color);
}

.page-news__faq-question {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 25px;
    background: var(--secondary-color);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    cursor: pointer;
    user-select: none;
    transition: background-color 0.3s ease, border-color 0.3s ease;
    position: relative;
}

.page-news__faq-item.active .page-news__faq-question {
    border-bottom-left-radius: 0;
    border-bottom-right-radius: 0;
    border-color: var(--primary-color);
    background-color: var(--background-light);
}

.page-news__faq-question:hover {
    background: var(--background-light);
    border-color: #d0d0d0;
}

.page-news__faq-question:active {
    background: #eeeeee;
}

.page-news__faq-question h3 {
    margin: 0;
    padding: 0;
    flex: 1;
    font-size: 1.2em;
    font-weight: 600;
    line-height: 1.5;
    color: var(--primary-color);
    pointer-events: none; /* Prevent h3 from blocking click event */
}

.page-news__faq-toggle {
    font-size: 2.2em;
    font-weight: bold;
    line-height: 1;
    color: var(--primary-color);
    transition: transform 0.3s ease, color 0.3s ease;
    flex-shrink: 0;
    margin-left: 15px;
    pointer-events: none; /* Prevent icon from blocking click event */
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 30px;
}

.page-news__faq-item.active .page-news__faq-toggle {
    color: var(--button-login);
    transform: rotate(45deg); /* Change to X or rotate for active state */
}

/* Bottom CTA Section */
.page-news__cta-bottom {
    background-color: var(--primary-color);
    padding: 60px 0;
    text-align: center;
    color: var(--text-light);
}

.page-news__cta-bottom-content {
    max-width: 800px;
    margin: 0 auto;
    padding: 20px;
}

.page-news__cta-description {
    font-size: 1.2em;
    margin-bottom: 30px;
    color: var(--text-light);
}

/* Global Image styles (for all images in .page-news) */
.page-news img {
    max-width: 100%;
    height: auto;
    display: block;
}

/* Responsive Design */
@media (max-width: 1024px) {
    .page-news__main-title {
        font-size: 2.8em;
    }
    .page-news__section-title {
        font-size: 2em;
    }
    .page-news__articles-grid {
        grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    }
    .page-news__update-item {
        flex-direction: column;
        text-align: center;
    }
    .page-news__update-image-wrapper {
        width: 100%;
        height: 200px;
        margin-top: 20px;
    }
}

@media (max-width: 768px) {
    .page-news__hero-section {
        padding-top: var(--header-offset, 120px) !important; /* Mobile fixed header offset */
        padding-bottom: 40px;
        padding-left: 15px;
        padding-right: 15px;
    }
    .page-news__hero-image {
        margin-bottom: 30px;
        border-radius: 8px;
    }
    .page-news__main-title {
        font-size: 2.2em;
    }
    .page-news__intro-text {
        font-size: 1em;
    }
    .page-news__cta-button {
        max-width: 100% !important;
        width: 100% !important;
        box-sizing: border-box !important;
        white-space: normal !important;
        word-wrap: break-word !important;
        padding: 12px 15px !important; /* Adjusted padding for full width */
        font-size: 1em;
    }

    .page-news__container {
        padding: 20px 15px;
    }
    .page-news__section-title {
        font-size: 1.8em;
        margin-bottom: 30px;
    }
    .page-news__articles-grid {
        grid-template-columns: 1fr;
    }
    .page-news__article-image-wrapper {
        height: 200px;
    }
    .page-news__article-title {
        font-size: 1.3em;
    }
    .page-news__update-item {
        padding: 20px;
    }
    .page-news__update-title {
        font-size: 1.4em;
    }
    .page-news__update-image-wrapper {
        width: 100%;
        height: 150px;
    }

    .page-news__faq-question {
        padding: 15px 20px;
    }
    .page-news__faq-question h3 {
        font-size: 1.1em;
    }
    .page-news__faq-toggle {
        font-size: 1.8em;
        width: 25px;
        height: 25px;
    }
    .page-news__faq-answer {
        padding: 0 20px;
    }
    .page-news__faq-item.active .page-news__faq-answer {
        padding: 20px !important;
    }

    /* Mobile specific image rules */
    .page-news img {
        max-width: 100% !important;
        width: 100% !important;
        height: auto !important;
    }
    .page-news__section,
    .page-news__card,
    .page-news__container,
    .page-news__hero-container,
    .page-news__cta-bottom-content {
        max-width: 100% !important;
        width: 100% !important;
        box-sizing: border-box !important;
        padding-left: 15px;
        padding-right: 15px;
    }
    .page-news__cta-bottom .page-news__cta-button {
        max-width: 100% !important;
        width: 100% !important;
        box-sizing: border-box !important;
        white-space: normal !important;
        word-wrap: break-word !important;
        padding: 12px 15px !important;
    }
}