/* style/news.css */

/* Base styles for the news page */
.page-news {
    font-family: Arial, sans-serif;
    line-height: 1.6;
    color: #333333; /* Default text color for light backgrounds */
    background-color: #f8f8f8; /* Light background for the page content */
}

/* Hero Section */
.page-news__hero-section {
    position: relative;
    width: 100%;
    display: flex;
    flex-direction: column; /* Image then text */
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 60px 20px;
    padding-top: 10px; /* Small top padding, body handles header offset */
    background-color: #f0f0f0;
    overflow: hidden; /* Ensure image doesn't overflow */
}

.page-news__hero-image-wrapper {
    width: 100%;
    max-width: 1200px; /* Max width for image container */
    margin-bottom: 30px; /* Space between image and text */
}

.page-news__hero-image {
    width: 100%;
    height: auto;
    display: block;
    border-radius: 8px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.page-news__hero-content {
    max-width: 900px;
    margin: 0 auto;
    z-index: 1; /* Ensure content is above any potential background elements */
}

.page-news__main-title {
    font-size: clamp(2.2em, 4vw, 3.5em); /* Responsive font size for H1 */
    color: #26A9E0;
    margin-bottom: 15px;
    font-weight: bold;
    line-height: 1.2;
}

.page-news__lead-text {
    font-size: 1.2em;
    color: #555555;
    margin-bottom: 30px;
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
}

.page-news__cta-buttons {
    display: flex;
    gap: 20px;
    justify-content: center;
    flex-wrap: wrap; /* Allow buttons to wrap on smaller screens */
}

/* General Section Styling */
.page-news__section {
    padding: 60px 0;
    background-color: #ffffff;
    border-bottom: 1px solid #eeeeee;
}

.page-news__section:nth-of-type(even) {
    background-color: #f8f8f8;
}

.page-news__dark-section {
    background-color: #26A9E0;
    color: #ffffff;
}

.page-news__dark-section .page-news__section-title,
.page-news__dark-section .page-news__section-description {
    color: #ffffff;
}

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

.page-news__section-title {
    font-size: clamp(1.8em, 3.5vw, 2.8em);
    color: #26A9E0;
    text-align: center;
    margin-bottom: 20px;
    font-weight: bold;
}

.page-news__dark-section .page-news__section-title {
    color: #ffffff;
}

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

.page-news__dark-section .page-news__section-description {
    color: #f0f0f0;
}

/* Card Grid */
.page-news__card-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    margin-top: 30px;
}

.page-news__card {
    background-color: #ffffff;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
    padding: 30px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    text-align: left;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

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

.page-news__dark-section .page-news__card {
    background-color: rgba(255, 255, 255, 0.1);
    color: #ffffff;
    box-shadow: none;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.page-news__dark-section .page-news__card:hover {
    background-color: rgba(255, 255, 255, 0.2);
}

.page-news__light-bg { /* For cards within dark sections */
    background-color: #ffffff;
    color: #333333;
}

.page-news__light-bg .page-news__card-title {
    color: #26A9E0;
}

.page-news__card-image {
    width: 100%;
    height: auto;
    display: block;
    border-radius: 6px;
    margin-bottom: 20px;
    min-width: 200px; /* Enforce minimum size */
    min-height: 200px; /* Enforce minimum size */
    object-fit: cover;
}

.page-news__image-full-width {
    width: 100%;
    height: auto;
    display: block;
    border-radius: 8px;
    margin: 40px auto;
    max-width: 1000px; /* Example max width */
    min-width: 200px; /* Enforce minimum size */
    min-height: 200px; /* Enforce minimum size */
    object-fit: cover;
}

.page-news__image-centered {
    width: 100%;
    height: auto;
    display: block;
    border-radius: 8px;
    margin: 40px auto;
    max-width: 800px; /* Example max width */
    min-width: 200px; /* Enforce minimum size */
    min-height: 200px; /* Enforce minimum size */
    object-fit: cover;
}


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

.page-news__dark-section .page-news__card-title {
    color: #ffffff;
}

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

.page-news__dark-section .page-news__card-text {
    color: #f0f0f0;
}

.page-news__card-link {
    display: inline-block;
    padding: 10px 20px;
    background-color: #26A9E0;
    color: #ffffff;
    text-decoration: none;
    border-radius: 5px;
    font-weight: bold;
    transition: background-color 0.3s ease;
    text-align: center;
    max-width: 100%; /* Ensure link button is responsive */
    box-sizing: border-box;
    white-space: normal; /* Allow text wrap */
    word-wrap: break-word; /* Allow text wrap */
}

.page-news__card-link:hover {
    background-color: #1e87c2;
}

/* Buttons */
.page-news__btn-primary {
    display: inline-block;
    padding: 15px 30px;
    background-color: #EA7C07; /* Login color for primary action */
    color: #ffffff;
    text-decoration: none;
    border-radius: 8px;
    font-weight: bold;
    font-size: 1.1em;
    transition: background-color 0.3s ease, transform 0.2s ease;
    border: none;
    cursor: pointer;
    text-align: center;
    max-width: 100%; /* Ensure button is responsive */
    box-sizing: border-box;
    white-space: normal; /* Allow text wrap */
    word-wrap: break-word; /* Allow text wrap */
}

.page-news__btn-primary:hover {
    background-color: #d16b06;
    transform: translateY(-2px);
}

.page-news__btn-secondary {
    display: inline-block;
    padding: 15px 30px;
    background-color: #ffffff;
    color: #26A9E0;
    text-decoration: none;
    border-radius: 8px;
    font-weight: bold;
    font-size: 1.1em;
    transition: background-color 0.3s ease, color 0.3s ease, transform 0.2s ease;
    border: 2px solid #26A9E0;
    cursor: pointer;
    text-align: center;
    max-width: 100%; /* Ensure button is responsive */
    box-sizing: border-box;
    white-space: normal; /* Allow text wrap */
    word-wrap: break-word; /* Allow text wrap */
}

.page-news__btn-secondary:hover {
    background-color: #26A9E0;
    color: #ffffff;
    transform: translateY(-2px);
}

/* FAQ Section */
.page-news__faq-section {
    background-color: #f0f0f0;
}

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

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

.page-news__faq-item summary {
    list-style: none; /* Hide default marker for details tag */
}

.page-news__faq-item summary::-webkit-details-marker {
    display: none; /* Hide default marker for details tag in Webkit */
}

.page-news__faq-question {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 25px;
    font-size: 1.15em;
    font-weight: bold;
    color: #26A9E0;
    cursor: pointer;
    background-color: #eaf6fd; /* Lighter shade of brand color */
    border-bottom: 1px solid #dcecf7;
    transition: background-color 0.3s ease;
}

.page-news__faq-item:last-child .page-news__faq-question {
    border-bottom: none;
}

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

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

.page-news__faq-toggle {
    font-size: 1.5em;
    line-height: 1;
    margin-left: 15px;
    color: #26A9E0;
}

.page-news__faq-answer {
    padding: 15px 25px 20px 25px;
    font-size: 1em;
    color: #555555;
    background-color: #ffffff;
}

/* Contact CTA Section */
.page-news__contact-cta {
    text-align: center;
    padding: 80px 20px;
    background-color: #26A9E0;
    color: #ffffff;
}

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

.page-news__contact-cta .page-news__section-title {
    color: #ffffff;
    margin-bottom: 20px;
}

.page-news__contact-cta .page-news__section-description {
    color: #f0f0f0;
    margin-bottom: 40px;
}

/* Responsive Styles */
@media (max-width: 1024px) {
    .page-news__main-title {
        font-size: clamp(2em, 5vw, 3em);
    }

    .page-news__section-title {
        font-size: clamp(1.6em, 4vw, 2.5em);
    }

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

@media (max-width: 768px) {
    .page-news {
        font-size: 16px;
        line-height: 1.6;
    }

    .page-news__hero-section {
        padding: 40px 15px;
        padding-top: 10px !important; /* body handles header offset */
    }

    .page-news__main-title {
        font-size: clamp(1.8em, 6vw, 2.5em);
    }

    .page-news__lead-text {
        font-size: 1em;
    }

    .page-news__cta-buttons {
        flex-direction: column; /* Stack buttons vertically on mobile */
        gap: 15px;
        width: 100%;
        padding: 0 15px; /* Add padding to container */
        box-sizing: border-box;
    }

    /* Mobile buttons forced 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;
      padding-left: 15px;
      padding-right: 15px;
    }

    .page-news__section {
        padding: 40px 0;
    }

    .page-news__container {
        padding: 0 15px;
        max-width: 100% !important;
        width: 100% !important;
        box-sizing: border-box !important;
    }

    .page-news__section-title {
        font-size: clamp(1.5em, 5vw, 2em);
    }

    .page-news__section-description {
        font-size: 0.95em;
        margin-bottom: 30px;
    }

    .page-news__card-grid {
        grid-template-columns: 1fr; /* Single column on mobile */
        gap: 20px;
    }

    .page-news__card {
        padding: 25px;
    }

    .page-news__card-image,
    .page-news__image-full-width,
    .page-news__image-centered {
        max-width: 100% !important;
        width: 100% !important;
        height: auto !important;
        min-width: 200px !important; /* Enforce minimum size */
        min-height: 200px !important; /* Enforce minimum size */
        margin-left: 0;
        margin-right: 0;
    }

    /* All image containers responsive */
    .page-news__section,
    .page-news__card,
    .page-news__container,
    .page-news__hero-image-wrapper {
        max-width: 100% !important;
        width: 100% !important;
        box-sizing: border-box !important;
        overflow: hidden !important; /* Prevent content overflow */
    }

    .page-news__faq-question {
        padding: 15px 20px;
        font-size: 1em;
    }

    .page-news__faq-answer {
        padding: 10px 20px 15px 20px;
    }

    .page-news__contact-cta {
        padding: 60px 15px;
    }
}

/* Ensure content area images are not smaller than 200px */
.page-news__content-area img,
.page-news__card img,
.page-news__section img {
    min-width: 200px;
    min-height: 200px;
    object-fit: cover; /* Ensure images fill their space nicely */
}

/* No CSS filters allowed for images */
.page-news img {
    filter: none;
}