/* style/news.css */
/* BEM Naming: page-news__element-name */

:root {
    --primary-color: #C91F17; /* Main Brand Color */
    --secondary-color: #E53935; /* Auxiliary Brand Color */
    --background-color: #B71C1C; /* Custom Background */
    --card-bg-color: #D32F2F; /* Custom Card Background */
    --text-main-color: #FFF5E1; /* Custom Main Text Color */
    --border-color: #F2B544; /* Custom Border Color */
    --button-gradient-start: #FFD86A; /* Custom Button Gradient Start */
    --button-gradient-end: #E6B800; /* Custom Button Gradient End */
    --glow-color: #FFCC66; /* Custom Glow Color */
    --gold-color: #F4D34D; /* Custom Gold Color */
    --deep-red-color: #7A0E0E; /* Custom Deep Red Color */

    /* Generic colors for contrast safety */
    --dark-text: #333333;
    --light-text: #ffffff;
    --white-bg: #ffffff;
    --light-gray-bg: #f5f5f5;
}

/* Base styles for the page-news scope */
.page-news {
    font-family: Arial, sans-serif;
    line-height: 1.6;
    color: var(--text-main-color); /* Main text color for dark background */
    background-color: var(--background-color); /* Default background for main content sections */
    padding-bottom: 50px;
}

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

/* Hero Section */
.page-news__hero-section {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 60px 20px;
    padding-top: 10px; /* Small top padding, body handles header offset */
    background-color: var(--deep-red-color); /* A darker red for the hero section background */
}

.page-news__hero-container {
    position: relative;
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 100%; /* Ensure it takes full width for flex item */
}

.page-news__hero-image {
    width: 100%;
    margin-bottom: 30px;
}

.page-news__hero-image img {
    width: 100%;
    height: auto;
    max-width: 100%;
    display: block;
    border-radius: 8px;
    object-fit: cover;
    border: 2px solid var(--border-color); /* Added border */
    box-shadow: 0 0 15px var(--glow-color); /* Added glow effect */
}

.page-news__hero-content {
    position: relative;
    z-index: 2;
    text-align: center;
    width: 100%;
}

.page-news__main-title {
    font-size: 3em;
    font-weight: bold;
    color: var(--gold-color); /* Gold color for main title */
    margin-bottom: 20px;
    line-height: 1.2;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
}

.page-news__hero-description {
    font-size: 1.2em;
    color: var(--text-main-color);
    margin-bottom: 30px;
    max-width: 900px;
    margin-left: auto;
    margin-right: auto;
}

.page-news__cta-button {
    display: inline-block;
    padding: 15px 40px;
    background: linear-gradient(180deg, var(--button-gradient-start) 0%, var(--button-gradient-end) 100%);
    color: var(--dark-text); /* Dark text for gold button to ensure contrast */
    text-decoration: none;
    border-radius: 50px;
    font-size: 1.1em;
    font-weight: bold;
    margin-top: 20px;
    transition: all 0.3s ease;
    border: none;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
}

.page-news__cta-button:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.4);
    filter: brightness(1.1);
}

/* Section common styles */
.page-news__section {
    padding: 60px 0;
    background-color: var(--background-color); /* Default section background */
}

.page-news__section-title {
    font-size: 2.5em;
    color: var(--gold-color); /* Gold color for section titles */
    text-align: center;
    margin-bottom: 20px;
    text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.4);
}

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

.page-news__description--bottom {
    margin-top: 40px;
    margin-bottom: 20px;
}

/* News Grid (Featured News) */
.page-news__news-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    margin-bottom: 40px;
}

.page-news__news-card {
    display: flex;
    flex-direction: column;
    background-color: var(--card-bg-color); /* Card Background */
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    text-decoration: none;
    border: 1px solid var(--border-color); /* Border for cards */
}

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

.page-news__news-card-image {
    width: 100%;
    height: 200px; /* Fixed height for consistency */
    overflow: hidden;
}

.page-news__news-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.3s ease;
}

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

.page-news__news-card-content {
    padding: 25px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    color: var(--text-main-color); /* Text color for card content */
}

.page-news__news-card-title {
    font-size: 1.4em;
    font-weight: bold;
    color: var(--gold-color); /* Gold color for card titles */
    margin-bottom: 10px;
    line-height: 1.3;
}

.page-news__news-card-meta {
    font-size: 0.9em;
    color: rgba(255, 245, 225, 0.7); /* Slightly muted text */
    margin-bottom: 15px;
}

.page-news__news-card-excerpt {
    font-size: 1em;
    color: var(--text-main-color);
    margin-bottom: 20px;
    flex-grow: 1;
}

.page-news__read-more {
    display: inline-block;
    color: var(--gold-color); /* Gold color for read more link */
    font-weight: bold;
    text-decoration: none;
    transition: color 0.3s ease;
}

.page-news__read-more:hover {
    color: var(--button-gradient-start);
}

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

.page-news__view-all-button {
    display: inline-block;
    padding: 12px 30px;
    background: var(--primary-color);
    color: var(--light-text);
    text-decoration: none;
    border-radius: 50px;
    font-size: 1em;
    font-weight: bold;
    transition: all 0.3s ease;
    border: 2px solid var(--border-color);
}

.page-news__view-all-button:hover {
    background: var(--secondary-color);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

/* News List (Latest Updates) */
.page-news__news-list {
    display: flex;
    flex-direction: column;
    gap: 25px;
    margin-bottom: 40px;
}

.page-news__list-item {
    display: flex;
    background-color: var(--card-bg-color); /* Card Background */
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.15);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border: 1px solid var(--border-color); /* Border for list items */
}

.page-news__list-item:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 15px rgba(0, 0, 0, 0.25);
}

.page-news__list-item-image {
    width: 30%;
    flex-shrink: 0;
    height: auto;
    min-height: 200px; /* Minimum height for list item image */
}

.page-news__list-item-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.page-news__list-item-content {
    padding: 20px;
    flex-grow: 1;
    color: var(--text-main-color);
}

.page-news__list-item-title {
    font-size: 1.3em;
    font-weight: bold;
    margin-bottom: 8px;
    line-height: 1.3;
}

.page-news__list-item-title a {
    color: var(--gold-color); /* Gold color for list item titles */
    text-decoration: none;
    transition: color 0.3s ease;
}

.page-news__list-item-title a:hover {
    color: var(--button-gradient-start);
}

.page-news__list-item-meta {
    font-size: 0.85em;
    color: rgba(255, 245, 225, 0.7);
    margin-bottom: 12px;
}

.page-news__list-item-excerpt {
    font-size: 0.95em;
    color: var(--text-main-color);
}

/* CTA Banner */
.page-news__cta-banner {
    background-color: var(--primary-color); /* Primary color for CTA banner */
    text-align: center;
    padding: 80px 0;
}

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

.page-news__cta-banner .page-news__section-title {
    color: var(--light-text); /* White text on primary color background */
    margin-bottom: 15px;
}

.page-news__cta-banner .page-news__section-description {
    color: var(--light-text);
    margin-bottom: 30px;
}

.page-news__cta-button--secondary {
    background: var(--light-text); /* White background for secondary button */
    color: var(--primary-color); /* Primary color text */
    border: 2px solid var(--border-color); /* Gold border */
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
}

.page-news__cta-button--secondary:hover {
    background: var(--light-gray-bg);
    color: var(--secondary-color);
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.4);
}

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

.page-news__faq-section .page-news__section-title {
    margin-bottom: 50px;
}

details.page-news__faq-item {
    margin-bottom: 15px;
    border-radius: 10px;
    border: 1px solid var(--border-color); /* Border for FAQ item */
    overflow: hidden;
    background: var(--card-bg-color); /* Card Background for FAQ */
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}
details.page-news__faq-item summary.page-news__faq-question {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 18px 25px;
    cursor: pointer;
    user-select: none;
    list-style: none;
    transition: background-color 0.3s ease;
    color: var(--gold-color); /* Gold color for FAQ question */
    font-weight: bold;
}
details.page-news__faq-item summary.page-news__faq-question::-webkit-details-marker {
    display: none;
}
details.page-news__faq-item summary.page-news__faq-question:hover {
    background: var(--deep-red-color); /* Darker red on hover */
    color: var(--button-gradient-start);
}
.page-news__faq-qtext {
    flex: 1;
    font-size: 1.1em;
    line-height: 1.5;
    text-align: left;
}
.page-news__faq-toggle {
    font-size: 1.8em;
    font-weight: bold;
    color: var(--gold-color); /* Gold color for toggle icon */
    flex-shrink: 0;
    margin-left: 15px;
    width: 28px;
    text-align: center;
    transition: transform 0.3s ease, color 0.3s ease;
}
details.page-news__faq-item[open] .page-news__faq-toggle {
    transform: rotate(45deg);
    color: var(--button-gradient-start);
}
details.page-news__faq-item .page-news__faq-answer {
    padding: 0 25px 25px;
    background: var(--deep-red-color); /* Deep Red for FAQ answer background */
    border-radius: 0 0 10px 10px;
    color: var(--text-main-color); /* Main text color for answer */
    font-size: 1em;
}
details.page-news__faq-item .page-news__faq-answer p {
    margin-top: 0;
    margin-bottom: 0;
}

/* --- Responsive Design --- */

/* Mobile images & buttons responsiveness */
@media (max-width: 768px) {
    .page-news__hero-section {
        padding-top: 10px !important; /* Small top padding */
        padding-bottom: 40px;
        padding-left: 15px;
        padding-right: 15px;
    }

    .page-news__hero-image img {
        border-radius: 4px;
        border: 1px solid var(--border-color);
        box-shadow: 0 0 10px var(--glow-color);
    }

    .page-news__main-title {
        font-size: 2em;
        margin-bottom: 15px;
    }

    .page-news__hero-description {
        font-size: 1em;
        margin-bottom: 25px;
    }

    .page-news__cta-button {
        padding: 12px 30px;
        font-size: 1em;
        max-width: 100% !important;
        width: 100% !important;
        box-sizing: border-box !important;
        white-space: normal !important;
        word-wrap: break-word !important;
    }

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

    .page-news__section-title {
        font-size: 2em;
        margin-bottom: 15px;
    }

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

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

    .page-news__news-card-image {
        height: 180px;
    }

    .page-news__news-card-content {
        padding: 20px;
    }

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

    .page-news__news-card-excerpt {
        font-size: 0.9em;
    }

    .page-news__view-all-button {
        padding: 10px 25px;
        font-size: 0.95em;
        max-width: 100% !important;
        width: 100% !important;
        box-sizing: border-box !important;
        white-space: normal !important;
        word-wrap: break-word !important;
    }

    .page-news__news-list {
        gap: 20px;
    }

    .page-news__list-item {
        flex-direction: column;
    }

    .page-news__list-item-image {
        width: 100%;
        height: 200px;
        min-height: auto;
    }

    .page-news__list-item-content {
        padding: 15px;
    }

    .page-news__list-item-title {
        font-size: 1.1em;
    }

    .page-news__list-item-excerpt {
        font-size: 0.9em;
    }

    .page-news__cta-banner {
        padding: 50px 0;
    }

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

    .page-news__cta-button--secondary {
        max-width: 100% !important;
        width: 100% !important;
        box-sizing: border-box !important;
        white-space: normal !important;
        word-wrap: break-word !important;
    }

    details.page-news__faq-item summary.page-news__faq-question {
        padding: 15px 20px;
    }
    .page-news__faq-qtext {
        font-size: 1em;
    }
    .page-news__faq-toggle {
        font-size: 1.5em;
        width: 24px;
    }
    details.page-news__faq-item .page-news__faq-answer {
        padding: 0 20px 20px;
        font-size: 0.95em;
    }

    /* Universal image responsiveness */
    .page-news img {
        max-width: 100% !important;
        width: 100% !important;
        height: auto !important;
        display: block;
    }
    
    .page-news__section,
    .page-news__card,
    .page-news__container,
    .page-news__hero-container,
    .page-news__news-grid,
    .page-news__news-list,
    .page-news__list-item,
    .page-news__cta-content,
    .page-news__faq-list {
        max-width: 100% !important;
        width: 100% !important;
        box-sizing: border-box !important;
        padding-left: 15px;
        padding-right: 15px;
    }

    /* Button specific mobile padding */
    .page-news__cta-button,
    .page-news__view-all-button,
    .page-news__cta-button--secondary {
        padding-left: 15px !important;
        padding-right: 15px !important;
    }
}