.page-news {
    font-family: Arial, sans-serif;
    line-height: 1.6;
    color: #ffffff; /* Default text color for dark body background */
    background-color: transparent; /* Body background is handled by shared.css #0a0a0a */
}

/* Fixed header offset */
.page-news__hero-section {
    padding-top: var(--header-offset, 120px); /* Ensures content is not hidden by fixed header */
}

/* General Section Styling */
.page-news__section {
    padding: 60px 20px;
    position: relative;
}

.page-news__dark-section {
    background-color: #017439; /* Primary brand color as background */
    color: #ffffff;
}

.page-news__container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 15px; /* Consistent padding */
}

.page-news__section-title {
    font-size: 2.5em;
    color: #ffffff;
    text-align: center;
    margin-bottom: 20px;
    font-weight: bold;
}

.page-news__section-description {
    font-size: 1.1em;
    color: #f0f0f0;
    text-align: center;
    margin-bottom: 40px;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}

/* Hero Section */
.page-news__hero-section {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    position: relative;
    overflow: hidden;
    min-height: 600px;
    background-color: #0a0a0a; /* Ensure dark background for hero */
}

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

.page-news__hero-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: brightness(0.5); /* Darken image for text readability */
}

.page-news__hero-content {
    position: relative;
    z-index: 1;
    padding: 40px 20px;
    max-width: 900px;
    background: rgba(0, 0, 0, 0.6); /* Semi-transparent dark overlay for text */
    border-radius: 10px;
}

.page-news__hero-title {
    font-size: 3.5em;
    color: #ffffff;
    margin-bottom: 20px;
    line-height: 1.2;
    font-weight: bold;
}

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

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

/* Buttons */
.page-news__btn-primary,
.page-news__btn-secondary {
    display: inline-block;
    padding: 15px 30px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: bold;
    font-size: 1.1em;
    transition: background-color 0.3s ease, color 0.3s ease, border-color 0.3s ease;
    cursor: pointer;
    box-sizing: border-box; /* Ensure padding doesn't cause overflow */
    white-space: normal; /* Allow text wrapping */
    word-wrap: break-word; /* Break long words */
}

.page-news__btn-primary {
    background-color: #C30808; /* Register/Login color */
    color: #FFFF00; /* Register/Login font color */
    border: 2px solid #C30808;
}

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

.page-news__btn-secondary {
    background-color: transparent;
    color: #ffffff;
    border: 2px solid #ffffff;
}

.page-news__btn-secondary:hover {
    background-color: #ffffff;
    color: #017439;
}

.page-news__btn-large {
    padding: 18px 40px;
    font-size: 1.2em;
}

/* Latest Articles Grid */
.page-news__latest-articles {
    background-color: #0a0a0a; /* Dark background */
    color: #ffffff;
}

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

.page-news__article-card {
    background-color: rgba(255, 255, 255, 0.08); /* Slightly lighter background for cards */
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    display: flex;
    flex-direction: column;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

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

.page-news__article-image {
    width: 100%;
    height: 225px; /* Fixed height for consistency */
    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.4em;
    margin-bottom: 10px;
    line-height: 1.3;
}

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

.page-news__card-title a:hover {
    color: #FFFF00; /* Highlight on hover */
}

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

.page-news__read-more {
    color: #FFFF00; /* Primary accent color */
    text-decoration: none;
    font-weight: bold;
    display: flex;
    align-items: center;
    gap: 5px;
    transition: color 0.3s ease;
}

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

.page-news__arrow {
    transition: transform 0.3s ease;
}

.page-news__read-more:hover .page-news__arrow {
    transform: translateX(5px);
}

/* Featured Articles */
.page-news__featured-articles {
    background-color: #017439; /* Primary brand color */
    color: #ffffff;
}

.page-news__featured-grid {
    display: grid;
    gap: 40px;
}

.page-news__featured-item {
    display: flex;
    align-items: center;
    background-color: rgba(0, 0, 0, 0.2); /* Dark overlay for content */
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.page-news__featured-item:nth-child(even) {
    flex-direction: row-reverse; /* Alternate image and text */
}

.page-news__featured-image {
    width: 50%;
    height: 400px;
    object-fit: cover;
    display: block;
}

.page-news__featured-content {
    padding: 30px;
    width: 50%;
}

.page-news__featured-title {
    font-size: 2em;
    color: #ffffff;
    margin-bottom: 15px;
    line-height: 1.3;
}

.page-news__featured-text {
    font-size: 1em;
    color: #e0e0e0;
    margin-bottom: 20px;
}

/* Community CTA */
.page-news__community-cta {
    background-color: #0a0a0a;
    color: #ffffff;
}

.page-news__community-content {
    text-align: center;
}

/* FAQ Section */
.page-news__faq-section {
    background-color: #0a0a0a; /* Dark background */
    color: #ffffff;
}

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

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

.page-news__faq-question {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    font-size: 1.2em;
    font-weight: bold;
    cursor: pointer;
    color: #ffffff;
    transition: background-color 0.3s ease;
}

.page-news__faq-question:hover {
    background-color: rgba(255, 255, 255, 0.15);
}

.page-news__faq-toggle {
    font-size: 1.5em;
    line-height: 1;
    transition: transform 0.3s ease;
    color: #FFFF00; /* Accent color for toggle */
}

.page-news__faq-item.active .page-news__faq-toggle {
    transform: rotate(45deg);
}

.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: #e0e0e0;
}

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

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

/* CTA Banner */
.page-news__cta-banner {
    background-color: #017439; /* Primary brand color */
    color: #ffffff;
    text-align: center;
    padding: 80px 20px;
}

.page-news__cta-content {
    max-width: 800px;
}

.page-news__cta-title {
    font-size: 2.5em;
    color: #ffffff;
    margin-bottom: 20px;
    font-weight: bold;
}

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

.page-news__cta-banner .page-news__btn-primary {
    padding: 18px 40px;
    font-size: 1.2em;
}

/* Responsive Design */
@media (max-width: 1024px) {
    .page-news__hero-title {
        font-size: 3em;
    }
    .page-news__section-title {
        font-size: 2em;
    }
    .page-news__featured-item {
        flex-direction: column;
    }
    .page-news__featured-item:nth-child(even) {
        flex-direction: column;
    }
    .page-news__featured-image,
    .page-news__featured-content {
        width: 100%;
    }
    .page-news__featured-image {
        height: 300px;
    }
}

@media (max-width: 768px) {
    /* General responsive adjustments */
    .page-news__hero-section {
        min-height: 500px;
        padding-top: var(--header-offset, 120px) !important; /* Ensure mobile header offset */
    }
    .page-news__hero-content {
        padding: 30px 15px;
    }
    .page-news__hero-title {
        font-size: 2.2em;
    }
    .page-news__hero-description {
        font-size: 1em;
    }
    .page-news__hero-cta-buttons {
        flex-direction: column;
        gap: 15px;
    }

    /* Images responsiveness */
    .page-news img {
        max-width: 100% !important;
        width: 100% !important;
        height: auto !important;
        display: block !important;
    }
    .page-news__article-image {
        height: auto !important; /* Allow aspect ratio for article images */
        max-height: 200px;
    }

    /* Buttons responsiveness */
    .page-news__btn-primary,
    .page-news__btn-secondary,
    .page-news a[class*="button"],
    .page-news a[class*="btn"] {
        max-width: 100% !important;
        width: 100% !important;
        box-sizing: border-box !important;
        white-space: normal !important;
        word-wrap: break-word !important;
        padding-left: 15px;
        padding-right: 15px;
    }
    .page-news__hero-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;
        flex-wrap: wrap !important;
        gap: 10px;
    }
    .page-news__hero-cta-buttons {
        display: flex;
        flex-direction: column; /* Stack buttons vertically on mobile */
    }
    
    /* Container padding for mobile */
    .page-news__section,
    .page-news__container,
    .page-news__hero-content,
    .page-news__article-card,
    .page-news__featured-item,
    .page-news__faq-item,
    .page-news__cta-banner {
        padding-left: 15px !important;
        padding-right: 15px !important;
        box-sizing: border-box !important;
        max-width: 100% !important;
        width: 100% !important;
    }
    .page-news__faq-question {
        font-size: 1.1em;
        padding: 15px;
    }
    .page-news__faq-answer {
        padding: 0 15px;
    }
    .page-news__faq-item.active .page-news__faq-answer {
        padding: 10px 15px 15px;
    }
}

@media (max-width: 480px) {
    .page-news__hero-title {
        font-size: 1.8em;
    }
    .page-news__section-title {
        font-size: 1.8em;
    }
    .page-news__cta-title {
        font-size: 1.8em;
    }
    .page-news__btn-primary,
    .page-news__btn-secondary {
        padding: 12px 20px;
        font-size: 1em;
    }
}