/* style/news.css */

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

/* General styles for the page-news scope */
.page-news {
    font-family: 'Arial', sans-serif;
    background-color: var(--page-news-background); /* Dark background from custom colors */
    color: var(--page-news-text-main); /* Light text for dark background */
    line-height: 1.6;
}

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

.page-news__section-title {
    font-size: clamp(2em, 5vw, 2.8em);
    color: var(--page-news-gold-color);
    text-align: center;
    margin-bottom: 20px;
    font-weight: 700;
    line-height: 1.2;
    letter-spacing: 0.05em;
}

.page-news__section-description {
    font-size: 1.1em;
    color: var(--page-news-text-secondary);
    text-align: center;
    margin-bottom: 40px;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}

/* Hero Section */
.page-news__hero-section {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding-top: 10px; /* Small top padding, body handles --header-offset */
    padding-bottom: 60px;
    text-align: center;
    overflow: hidden;
}

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

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

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

.page-news__main-title {
    font-size: clamp(2.5em, 6vw, 3.5em);
    color: var(--page-news-gold-color);
    margin-bottom: 20px;
    font-weight: 800;
    line-height: 1.2;
    letter-spacing: 0.08em;
    text-shadow: 0 0 10px rgba(242, 193, 78, 0.6);
}

.page-news__intro-text {
    font-size: 1.2em;
    color: var(--page-news-text-main);
    margin-bottom: 30px;
    line-height: 1.6;
}

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

.page-news__btn-primary,
.page-news__btn-secondary {
    display: inline-block;
    padding: 14px 30px;
    border-radius: 8px;
    font-size: 1.1em;
    font-weight: 700;
    text-decoration: none;
    transition: all 0.3s ease;
    box-sizing: border-box;
    white-space: normal;
    word-wrap: break-word;
    max-width: 100%;
    text-align: center;
}

.page-news__btn-primary {
    background: var(--page-news-button-gradient);
    color: var(--page-news-text-main);
    border: 2px solid transparent;
    box-shadow: 0 4px 15px rgba(42, 209, 111, 0.4);
}

.page-news__btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(42, 209, 111, 0.6);
    opacity: 0.9;
}

.page-news__btn-secondary {
    background: var(--page-news-card-bg);
    color: var(--page-news-primary-color);
    border: 2px solid var(--page-news-primary-color);
    box-shadow: 0 4px 15px rgba(17, 168, 78, 0.2);
}

.page-news__btn-secondary:hover {
    transform: translateY(-3px);
    background: var(--page-news-primary-color);
    color: var(--page-news-text-main);
    box-shadow: 0 6px 20px rgba(17, 168, 78, 0.4);
}

/* News Grid Section */
.page-news__news-grid-section {
    padding: 80px 0;
    background-color: var(--page-news-card-bg);
}

.page-news__dark-section {
    background-color: var(--page-news-card-bg);
    color: var(--page-news-text-main);
}

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

.page-news__news-card {
    background-color: var(--page-news-background);
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.3);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: flex;
    flex-direction: column;
}

.page-news__news-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.4);
}

.page-news__card-image-wrapper {
    width: 100%;
    height: 220px;
    overflow: hidden;
}

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

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

.page-news__card-content {
    padding: 25px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

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

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

.page-news__card-title a:hover {
    color: var(--page-news-primary-color);
}

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

.page-news__card-excerpt {
    font-size: 1em;
    color: var(--page-news-text-secondary);
    margin-bottom: 20px;
    flex-grow: 1;
}

.page-news__read-more {
    display: inline-block;
    color: var(--page-news-primary-color);
    text-decoration: none;
    font-weight: 600;
    transition: color 0.3s ease;
}

.page-news__read-more:hover {
    color: var(--page-news-gold-color);
}

.page-news__view-all {
    text-align: center;
    margin-top: 20px;
}

/* Guides Section */
.page-news__guides-section {
    padding: 80px 0;
    background-color: var(--page-news-background);
}

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

.page-news__guide-item {
    background-color: var(--page-news-card-bg);
    border-radius: 10px;
    padding: 30px;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.3);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.page-news__guide-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.4);
}

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

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

.page-news__guide-title a:hover {
    color: var(--page-news-primary-color);
}

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

/* FAQ Section */
.page-news__faq-section {
    padding: 80px 0;
    background-color: var(--page-news-card-bg);
}

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

.page-news__faq-item {
    background-color: var(--page-news-background);
    border: 1px solid var(--page-news-border-color);
    border-radius: 8px;
    margin-bottom: 15px;
    overflow: hidden;
    transition: all 0.3s ease;
}

.page-news__faq-item summary {
    list-style: none;
}

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

.page-news__faq-question {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 25px;
    font-size: 1.15em;
    font-weight: 600;
    color: var(--page-news-text-main);
    cursor: pointer;
    background-color: var(--page-news-background);
    transition: background-color 0.3s ease;
}

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

.page-news__faq-toggle {
    font-size: 1.5em;
    line-height: 1;
    color: var(--page-news-primary-color);
    transition: transform 0.3s ease;
}

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

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

/* CTA Section */
.page-news__cta-section {
    padding: 80px 0;
    background-color: var(--page-news-background);
    text-align: center;
}

/* Responsive Design */

/* All images basic responsive styles */
.page-news img {
    max-width: 100%;
    height: auto;
    display: block;
}

/* All image containers basic responsive styles */
.page-news__card-image-wrapper,
.page-news__hero-image-wrapper {
    width: 100%;
    max-width: 100%;
    overflow: hidden;
    box-sizing: border-box;
}

/* All buttons basic responsive styles */
.page-news__cta-button,
.page-news__btn-primary,
.page-news__btn-secondary,
.page-news a[class*="button"],
.page-news a[class*="btn"] {
    max-width: 100%;
    box-sizing: border-box;
    white-space: normal;
    word-wrap: break-word;
}

/* Button containers basic responsive styles */
.page-news__cta-buttons,
.page-news__button-group,
.page-news__btn-container {
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
    overflow: hidden;
}

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

    .page-news__hero-section {
        padding-bottom: 40px;
    }

    .page-news__main-title {
        font-size: 2em; /* Smaller on mobile */
    }

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

    .page-news__cta-buttons {
        flex-direction: column;
        gap: 15px;
        padding: 0 15px;
    }

    .page-news__btn-primary,
    .page-news__btn-secondary {
        width: 100% !important;
        max-width: 100% !important;
        padding: 12px 20px !important;
        font-size: 1em !important;
    }

    .page-news__section-title {
        font-size: 1.8em;
    }

    .page-news__section-description {
        font-size: 0.95em;
    }

    .page-news__news-grid-section,
    .page-news__guides-section,
    .page-news__faq-section,
    .page-news__cta-section {
        padding: 40px 0;
    }

    .page-news__news-grid,
    .page-news__guides-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .page-news__card-title {
        font-size: 1.15em;
    }

    .page-news__guide-title {
        font-size: 1.2em;
    }

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

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

    /* Mobile image responsiveness */
    .page-news img {
        max-width: 100% !important;
        width: 100% !important;
        height: auto !important;
    }
    
    .page-news__section,
    .page-news__card,
    .page-news__container,
    .page-news__news-card,
    .page-news__guide-item,
    .page-news__faq-item,
    .page-news__hero-content {
        max-width: 100% !important;
        width: 100% !important;
        box-sizing: border-box !important;
        padding-left: 15px;
        padding-right: 15px;
    }
    
    .page-news__hero-section {
        padding-top: 10px !important; /* body already handles --header-offset */
    }

    .page-news__cta-buttons {
        max-width: 100% !important;
        width: 100% !important;
        box-sizing: border-box !important;
        padding-left: 15px;
        padding-right: 15px;
        flex-wrap: wrap !important;
        gap: 10px;
    }
}