/* style/news.css */

/* Base styles for the news page */
.page-news {
    color: #ffffff; /* Default text color for dark body background */
    background-color: #1a1a1a; /* Inherited from shared, ensuring consistency */
    font-family: Arial, sans-serif;
    line-height: 1.6;
}

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

/* Hero Section */
.page-news__hero-section {
    position: relative;
    width: 100%;
    height: 600px; /* Adjust height as needed */
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    overflow: hidden;
    padding-top: var(--header-offset, 120px); /* Fixed header spacing */
    box-sizing: border-box;
}

.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.6);
    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;
    color: #FFFFFF;
    margin-bottom: 20px;
    line-height: 1.2;
}

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

.page-news__section-intro {
    font-size: 1.1em;
    color: #f0f0f0;
    text-align: center;
    max-width: 900px;
    margin: 20px auto 40px;
    line-height: 1.7;
}

/* Section Titles */
.page-news__section-title {
    font-size: 2.5em;
    color: #017439; /* Brand color for titles */
    text-align: center;
    margin: 60px 0 40px;
    position: relative;
    padding-bottom: 10px;
}

.page-news__section-title::after {
    content: '';
    position: absolute;
    left: 50%;
    bottom: 0;
    transform: translateX(-50%);
    width: 80px;
    height: 4px;
    background-color: #017439;
    border-radius: 2px;
}

/* Article Grid Section */
.page-news__articles-section {
    padding: 80px 0;
    background-color: #1a1a1a;
}

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

.page-news__article-card {
    background-color: rgba(255, 255, 255, 0.1); /* Light background for card content on dark page */
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
    transition: transform 0.3s ease;
    display: flex;
    flex-direction: column;
}

.page-news__article-card:hover {
    transform: translateY(-5px);
}

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

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

.page-news__article-title {
    font-size: 1.5em;
    margin-bottom: 10px;
    line-height: 1.3;
}

.page-news__article-title a {
    color: #FFFFFF; /* White text for titles on dark card */
    text-decoration: none;
    transition: color 0.3s ease;
}

.page-news__article-title a:hover {
    color: #017439; /* Brand color on hover */
}

.page-news__article-meta {
    font-size: 0.9em;
    color: #cccccc;
    margin-bottom: 15px;
}

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

/* Buttons */
.page-news__btn-primary,
.page-news__btn-secondary {
    display: inline-block;
    padding: 12px 25px;
    border-radius: 5px;
    text-decoration: none;
    font-weight: bold;
    transition: all 0.3s ease;
    text-align: center;
    cursor: pointer;
    box-sizing: border-box;
    max-width: 100%; /* For responsive buttons */
    white-space: normal;
    word-wrap: break-word;
}

.page-news__btn-primary {
    background-color: #017439; /* Brand color */
    color: #FFFFFF;
    border: 2px solid #017439;
    margin-right: 15px;
}

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

.page-news__btn-secondary {
    background-color: transparent;
    color: #017439; /* Brand color */
    border: 2px solid #017439;
}

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

.page-news__btn-text-link {
    color: #017439;
    text-decoration: none;
    font-weight: bold;
    transition: color 0.3s ease;
}

.page-news__btn-text-link:hover {
    color: #FFFFFF;
}

/* Video Section */
.page-news__video-section {
    padding: 80px 0;
    background-color: #1a1a1a;
    text-align: center;
}

.page-news__video-wrapper {
    position: relative;
    padding-bottom: 56.25%; /* 16:9 Aspect Ratio */
    height: 0;
    overflow: hidden;
    max-width: 100%;
    background: #000;
    margin: 0 auto 30px;
    border-radius: 10px;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.3);
    box-sizing: border-box; /* Ensure padding/border is included in width */
}

.page-news__video {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: 0;
    display: block;
    cursor: pointer;
}

.page-news__video-caption {
    font-size: 1.1em;
    color: #f0f0f0;
    margin-bottom: 30px;
}

.page-news__video-cta {
    margin-top: 20px;
}

/* Latest Updates Section */
.page-news__latest-updates-section {
    padding: 80px 0;
    background-color: #1a1a1a;
}

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

.page-news__update-item {
    background-color: rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
    display: flex;
    align-items: center;
    transition: transform 0.3s ease;
}

.page-news__update-item:hover {
    transform: translateY(-5px);
}

.page-news__update-image {
    width: 200px; /* Fixed width for image in update item */
    height: 150px;
    object-fit: cover;
    display: block;
    flex-shrink: 0;
    border-radius: 10px 0 0 10px;
}

.page-news__update-content {
    padding: 20px;
    flex-grow: 1;
}

.page-news__update-title {
    font-size: 1.3em;
    margin-bottom: 8px;
    line-height: 1.3;
}

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

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

.page-news__update-meta {
    font-size: 0.85em;
    color: #cccccc;
    margin-bottom: 10px;
}

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

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

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

.page-news__faq-item {
    background-color: rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    margin-bottom: 15px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    color: #FFFFFF; /* Light text for FAQ items */
}

.page-news__faq-question {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 18px 25px;
    font-size: 1.15em;
    font-weight: bold;
    color: #FFFFFF;
    cursor: pointer;
    list-style: none; /* For details/summary */
    transition: background-color 0.3s ease;
}

.page-news__faq-item summary::-webkit-details-marker {
    display: none;
}
.page-news__faq-item summary::marker {
    display: none;
}

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

.page-news__faq-qtext {
    flex-grow: 1;
}

.page-news__faq-toggle {
    font-size: 1.5em;
    margin-left: 15px;
    color: #017439; /* Brand color for toggle */
}

.page-news__faq-answer {
    padding: 0 25px 18px;
    font-size: 1em;
    color: #f0f0f0;
    line-height: 1.7;
}

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

.page-news__faq-answer a {
    color: #017439;
    text-decoration: none;
    font-weight: bold;
}

.page-news__faq-answer a:hover {
    text-decoration: underline;
}

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

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

.page-news__cta-description {
    font-size: 1.2em;
    margin-bottom: 40px;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}

.page-news__cta-buttons {
    display: flex;
    justify-content: center;
    gap: 20px;
    flex-wrap: wrap; /* Allow buttons to wrap on smaller screens */
    width: 100%;
    max-width: 100%;
    overflow: hidden;
    box-sizing: border-box;
    padding: 0 20px; /* Add padding for small screens */
}

/* Ensure contrast for buttons on brand color background */
.page-news__cta-buttons .page-news__btn-primary {
    background-color: #FFFFFF;
    color: #017439;
    border-color: #FFFFFF;
}
.page-news__cta-buttons .page-news__btn-primary:hover {
    background-color: #f0f0f0;
    border-color: #f0f0f0;
}

.page-news__cta-buttons .page-news__btn-secondary {
    background-color: transparent;
    color: #FFFFFF;
    border-color: #FFFFFF;
}
.page-news__cta-buttons .page-news__btn-secondary:hover {
    background-color: #FFFFFF;
    color: #017439;
}


/* Responsive Design */
@media (max-width: 1024px) {
    .page-news__hero-title {
        font-size: 2.8em;
    }
    .page-news__section-title {
        font-size: 2em;
    }
    .page-news__update-list {
        grid-template-columns: 1fr; /* Stack update items */
    }
    .page-news__update-item {
        flex-direction: column;
        text-align: center;
    }
    .page-news__update-image {
        width: 100%;
        height: 250px;
        border-radius: 10px 10px 0 0;
    }
    .page-news__update-content {
        padding: 20px;
    }
    .page-news__cta-title {
        font-size: 2.2em;
    }
}

@media (max-width: 768px) {
    /* General mobile padding */
    .page-news__container {
        padding: 0 15px !important;
    }

    /* Hero Section */
    .page-news__hero-section {
        height: 500px;
        padding-top: var(--header-offset, 120px) !important; /* Fixed header spacing for mobile */
    }
    .page-news__hero-title {
        font-size: 2em;
        margin-bottom: 15px;
    }
    .page-news__hero-description {
        font-size: 1em;
        margin-bottom: 20px;
    }

    /* Section titles */
    .page-news__section-title {
        font-size: 1.8em;
        margin: 40px 0 30px;
    }
    .page-news__section-intro {
        font-size: 1em;
        margin: 15px auto 30px;
    }

    /* Article Grid */
    .page-news__articles-section,
    .page-news__video-section,
    .page-news__latest-updates-section,
    .page-news__faq-section,
    .page-news__cta-section {
        padding: 50px 0 !important;
    }
    .page-news__article-grid {
        grid-template-columns: 1fr;
    }
    .page-news__article-card {
        margin-bottom: 20px;
    }
    .page-news__article-image {
        height: 180px;
    }

    /* Buttons responsive */
    .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;
        margin-right: 0 !important; /* Remove right margin for stacking */
    }
    .page-news__cta-buttons {
        flex-direction: column !important; /* Stack buttons vertically */
        gap: 15px !important; /* Space between stacked buttons */
        padding: 0 15px !important;
    }

    /* Image responsive */
    .page-news img {
        max-width: 100% !important;
        width: 100% !important;
        height: auto !important;
        display: block !important;
    }
    .page-news__section,
    .page-news__card,
    .page-news__container {
        max-width: 100% !important;
        width: 100% !important;
        box-sizing: border-box !important;
        padding-left: 15px;
        padding-right: 15px;
    }

    /* Video responsive */
    .page-news video,
    .page-news__video {
        max-width: 100% !important;
        width: 100% !important;
        height: auto !important;
        display: block !important;
    }
    .page-news__video-section,
    .page-news__video-container,
    .page-news__video-wrapper {
        max-width: 100% !important;
        width: 100% !important;
        box-sizing: border-box !important;
        padding-left: 15px;
        padding-right: 15px;
        overflow: hidden !important;
    }
    .page-news__video-wrapper {
        padding-bottom: 75% !important; /* Adjust aspect ratio for mobile if needed, e.g., 4:3 */
    }
    .page-news__video-cta {
        margin-top: 15px;
    }

    /* Latest Updates */
    .page-news__update-item {
        margin-bottom: 20px;
    }
    .page-news__update-image {
        height: 180px;
    }
    .page-news__update-title {
        font-size: 1.2em;
    }
    .page-news__update-text {
        font-size: 0.9em;
    }

    /* FAQ */
    .page-news__faq-question {
        font-size: 1em;
        padding: 15px 20px;
    }
    .page-news__faq-answer {
        padding: 0 20px 15px;
    }

    /* CTA */
    .page-news__cta-title {
        font-size: 1.8em;
    }
    .page-news__cta-description {
        font-size: 1em;
        margin-bottom: 30px;
    }
}