/* style/news.css */

/* Custom Properties based on provided color scheme */
:root {
    --page-news-primary-color: #11A84E;
    --page-news-secondary-color: #22C768;
    --page-news-button-gradient: linear-gradient(180deg, #2AD16F 0%, #13994A 100%);
    --page-news-card-bg: #11271B;
    --page-news-bg: #08160F;
    --page-news-text-main: #F2FFF6;
    --page-news-text-secondary: #A7D9B8;
    --page-news-border: #2E7A4E;
    --page-news-glow: #57E38D;
    --page-news-gold: #F2C14E;
    --page-news-divider: #1E3A2A;
    --page-news-deep-green: #0A4B2C;
}

/* Base styles for the news page, ensuring text contrast with body background */
.page-news {
    color: var(--page-news-text-main); /* Light text for dark body background */
    background-color: var(--page-news-bg); /* Ensures consistent dark background for sections */
    font-family: Arial, sans-serif;
    line-height: 1.6;
}

/* Section styling */
.page-news__section {
    padding: 60px 0;
    text-align: center;
    background-color: var(--page-news-bg); /* Ensures consistent dark background */
}

.page-news__section-title {
    font-size: clamp(28px, 4vw, 48px);
    font-weight: 700;
    color: var(--page-news-gold);
    margin-bottom: 20px;
    line-height: 1.2;
    padding: 0 15px; /* Add padding for smaller screens */
}

.page-news__text-block {
    max-width: 800px;
    margin: 0 auto 40px auto;
    font-size: 18px;
    color: var(--page-news-text-secondary);
    padding: 0 15px;
}

/* Container for responsive centering */
.page-news__container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    box-sizing: border-box; /* Ensure padding is included in width */
}

/* Hero Section */
.page-news__hero-section {
    position: relative;
    width: 100%;
    display: flex;
    flex-direction: column; /* Image above, text below */
    align-items: center;
    padding: 10px 0 60px 0; /* Small top padding, larger bottom padding */
    background-color: var(--page-news-bg);
    overflow: hidden;
}

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

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

.page-news__hero-content {
    max-width: 900px;
    text-align: center;
    padding: 0 20px;
}

.page-news__main-title {
    font-size: clamp(32px, 5vw, 56px); /* H1 constraint - use clamp */
    font-weight: 800;
    color: var(--page-news-text-main);
    margin-bottom: 15px;
    line-height: 1.1;
}

.page-news__description {
    font-size: 20px;
    color: var(--page-news-text-secondary);
    margin-bottom: 30px;
}

.page-news__cta-button {
    display: inline-block;
    background: var(--page-news-button-gradient);
    color: var(--page-news-text-main);
    padding: 15px 30px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 700;
    font-size: 18px;
    transition: all 0.3s ease;
    border: none;
    cursor: pointer;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.page-news__cta-button:hover {
    opacity: 0.9;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
}

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

.page-news__card {
    background-color: var(--page-news-card-bg);
    border: 1px solid var(--page-news-border);
    border-radius: 12px;
    padding: 30px;
    text-align: left;
    display: flex;
    flex-direction: column;
    height: 100%; /* Ensure cards are same height */
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.15);
}

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

.page-news__card-title {
    font-size: 24px;
    color: var(--page-news-gold);
    margin-bottom: 15px;
    line-height: 1.3;
    flex-grow: 1; /* Push link to bottom */
}

.page-news__card-text {
    font-size: 16px;
    color: var(--page-news-text-secondary);
    margin-bottom: 20px;
}

.page-news__card-link {
    color: var(--page-news-secondary-color);
    text-decoration: none;
    font-weight: 600;
    font-size: 16px;
    transition: color 0.3s ease;
    margin-top: auto; /* Push link to bottom */
}

.page-news__card-link:hover {
    color: var(--page-news-glow);
    text-decoration: underline;
}

/* Article Grid for Types Section */
.page-news__article-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    margin-top: 40px;
}

.page-news__article-card {
    background-color: var(--page-news-card-bg);
    border: 1px solid var(--page-news-border);
    border-radius: 12px;
    overflow: hidden;
    text-align: left;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.15);
    display: flex;
    flex-direction: column;
}

.page-news__article-image {
    width: 100%;
    height: 225px; /* Fixed height for consistency, adjust for responsive */
    display: block;
    object-fit: cover;
    min-height: 200px; /* Min size constraint */
}

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

.page-news__article-title {
    font-size: 22px;
    margin-bottom: 10px;
    line-height: 1.3;
    flex-grow: 1;
}

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

.page-news__article-title a:hover {
    color: var(--page-news-glow);
    text-decoration: underline;
}

.page-news__article-meta {
    font-size: 14px;
    color: var(--page-news-text-secondary);
    margin-bottom: 15px;
}

.page-news__article-excerpt {
    font-size: 16px;
    color: var(--page-news-text-secondary);
    margin-bottom: 20px;
}

.page-news__read-more {
    color: var(--page-news-secondary-color);
    text-decoration: none;
    font-weight: 600;
    font-size: 16px;
    transition: color 0.3s ease;
    margin-top: auto;
}

.page-news__read-more:hover {
    color: var(--page-news-glow);
    text-decoration: underline;
}

.page-news__cta-container {
    margin-top: 50px;
}

.page-news__view-all-button {
    background: var(--page-news-button-gradient);
}

/* Benefits List */
.page-news__benefits-list {
    list-style: none;
    padding: 0;
    margin-top: 40px;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    text-align: left;
}

.page-news__benefits-item {
    background-color: var(--page-news-card-bg);
    border: 1px solid var(--page-news-border);
    border-radius: 12px;
    padding: 30px;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.15);
}

.page-news__benefits-title {
    font-size: 24px;
    color: var(--page-news-gold);
    margin-bottom: 15px;
    line-height: 1.3;
}

.page-news__benefits-text {
    font-size: 16px;
    color: var(--page-news-text-secondary);
}

/* Access Features */
.page-news__access-features {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    margin-top: 40px;
    text-align: left;
}

.page-news__feature-item {
    background-color: var(--page-news-card-bg);
    border: 1px solid var(--page-news-border);
    border-radius: 12px;
    padding: 30px;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.15);
    display: flex;
    flex-direction: column;
    height: 100%;
}

.page-news__feature-image {
    width: 100%;
    height: auto;
    display: block;
    border-radius: 8px;
    margin-bottom: 20px;
    object-fit: cover;
    min-height: 200px; /* Min size constraint */
}

.page-news__feature-title {
    font-size: 24px;
    color: var(--page-news-gold);
    margin-bottom: 15px;
    line-height: 1.3;
    flex-grow: 1;
}

.page-news__feature-text {
    font-size: 16px;
    color: var(--page-news-text-secondary);
    margin-bottom: 20px;
}

.page-news__feature-content .page-news__cta-button {
    margin-top: auto; /* Push button to bottom */
}

/* FAQ Section */
.page-news__faq-list {
    margin-top: 40px;
    max-width: 900px;
    margin-left: auto;
    margin-right: auto;
}

.page-news__faq-item {
    background-color: var(--page-news-card-bg);
    border: 1px solid var(--page-news-border);
    border-radius: 10px;
    margin-bottom: 15px;
    overflow: hidden;
    text-align: left;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.page-news__faq-item summary {
    list-style: none; /* Hide default marker for details */
    cursor: pointer;
    padding: 20px 25px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 20px;
    font-weight: 600;
    color: var(--page-news-gold);
    background-color: var(--page-news-card-bg);
    transition: background-color 0.3s ease;
}

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

.page-news__faq-item summary:hover {
    background-color: var(--page-news-deep-green);
}

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

.page-news__faq-toggle {
    font-size: 24px;
    font-weight: 700;
    margin-left: 15px;
    color: var(--page-news-secondary-color);
}

.page-news__faq-answer {
    padding: 0 25px 20px 25px;
    font-size: 16px;
    color: var(--page-news-text-secondary);
    line-height: 1.7;
}

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

.page-news__faq-answer a {
    color: var(--page-news-secondary-color);
    text-decoration: underline;
}

/* Bottom CTA */
.page-news__cta-bottom {
    background-color: var(--page-news-deep-green);
    padding: 80px 20px;
}

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

/* Responsive Styles */
@media (max-width: 1024px) {
    .page-news__section {
        padding: 40px 0;
    }
    .page-news__hero-section {
        padding: 10px 0 40px 0;
    }
    .page-news__main-title {
        font-size: clamp(28px, 4.5vw, 48px);
    }
    .page-news__description {
        font-size: 18px;
    }
    .page-news__section-title {
        font-size: clamp(24px, 3.5vw, 40px);
    }
    .page-news__text-block {
        font-size: 16px;
    }
    .page-news__card-title,
    .page-news__article-title,
    .page-news__benefits-title,
    .page-news__feature-title {
        font-size: 20px;
    }
    .page-news__faq-item summary {
        font-size: 18px;
    }
}

@media (max-width: 768px) {
    /* Mobile image responsiveness */
    .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,
    .page-news__hero-section,
    .page-news__hero-image-wrapper,
    .page-news__hero-content,
    .page-news__card-grid,
    .page-news__article-grid,
    .page-news__benefits-list,
    .page-news__access-features,
    .page-news__faq-list,
    .page-news__cta-bottom,
    .page-news__cta-content {
        max-width: 100% !important;
        width: 100% !important;
        box-sizing: border-box !important;
        padding-left: 15px !important;
        padding-right: 15px !important;
        overflow: hidden !important; /* Prevent content overflow */
    }

    /* Video section top padding (hero-section acts as main top content) */
    .page-news__hero-section {
        padding-top: 10px !important; /* body already handles --header-offset */
    }

    /* Button responsiveness */
    .page-news__cta-button,
    .page-news__view-all-button,
    .page-news__subscribe-button,
    .page-news__card-link,
    .page-news__read-more,
    .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: 12px 20px !important; /* Adjust padding for smaller screens */
        text-align: center;
        margin-bottom: 10px; /* Space between stacked buttons */
    }
    .page-news__cta-container,
    .page-news__feature-content {
        display: flex !important;
        flex-direction: column !important;
        gap: 10px;
    }

    .page-news__main-title {
        font-size: clamp(24px, 7vw, 36px);
    }
    .page-news__description {
        font-size: 16px;
    }
    .page-news__section-title {
        font-size: clamp(22px, 6vw, 32px);
    }
    .page-news__text-block {
        font-size: 15px;
    }
    .page-news__card-title,
    .page-news__article-title,
    .page-news__benefits-title,
    .page-news__feature-title {
        font-size: 18px;
    }
    .page-news__article-image {
        height: 180px; /* Adjust height for mobile */
    }
    .page-news__faq-item summary {
        font-size: 16px;
        padding: 15px 20px;
    }
    .page-news__faq-answer {
        font-size: 14px;
        padding: 0 20px 15px 20px;
    }
    .page-news__section {
        padding: 30px 0;
    }
    .page-news__cta-bottom {
        padding: 50px 15px;
    }
}

/* Ensure no filter on images */
.page-news img {
    filter: none;
}