/* style/faq.css */

/* Base Styles for .page-faq */
.page-faq {
    font-family: Arial, sans-serif;
    line-height: 1.6;
    color: #333333; /* Default text color for light backgrounds */
    background-color: var(--background-color, #f5f5f5); /* Inherit from shared, fallback to light grey */
}

/* Hero Section */
.page-faq__hero-section {
    position: relative;
    padding-top: 10px; /* Specific top padding, not --header-offset */
    padding-bottom: 40px;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    overflow: hidden; /* Ensure image doesn't overflow */
}

.page-faq__hero-image-wrapper {
    width: 100%;
    max-height: 500px; /* Limit height for hero image */
    overflow: hidden;
    position: relative;
    z-index: 1;
}

.page-faq__hero-image {
    width: 100%;
    height: auto;
    display: block;
    object-fit: cover;
    min-height: 200px; /* Minimum size */
}

.page-faq__hero-content {
    position: relative;
    z-index: 2;
    max-width: 900px;
    margin-top: -150px; /* Overlap slightly for visual effect, but text is below image */
    background: rgba(0, 0, 0, 0.7); /* Dark overlay for text readability */
    padding: 30px 20px;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
    color: #FFF5E1; /* Text Main */
}

.page-faq__main-title {
    font-size: clamp(2em, 4vw, 3.5em); /* Responsive font size */
    font-weight: bold;
    color: #FFD86A; /* Gold color for main title */
    margin-bottom: 15px;
    line-height: 1.2;
}

.page-faq__hero-description {
    font-size: 1.1em;
    margin-bottom: 30px;
    color: #FFF5E1; /* Text Main */
}

/* Primary Button */
.page-faq__btn-primary {
    display: inline-block;
    padding: 15px 30px;
    background: linear-gradient(180deg, #FFD86A 0%, #E6B800 100%); /* Custom button color */
    color: #7A0E0E; /* Deep Red for text on gold button for contrast */
    text-decoration: none;
    border-radius: 5px;
    font-weight: bold;
    transition: all 0.3s ease;
    border: none;
    cursor: pointer;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
}

.page-faq__btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 15px rgba(0, 0, 0, 0.3);
    opacity: 0.9;
}

/* Secondary Button */
.page-faq__btn-secondary {
    display: inline-block;
    padding: 12px 25px;
    background: #ffffff; /* White background for secondary button */
    color: #C91F17; /* Main brand color for text */
    text-decoration: none;
    border: 2px solid #C91F17; /* Main brand color border */
    border-radius: 5px;
    font-weight: bold;
    transition: all 0.3s ease;
    cursor: pointer;
}

.page-faq__btn-secondary:hover {
    background: #C91F17; /* Main brand color background on hover */
    color: #ffffff; /* White text on hover */
}

/* Section Styles */
.page-faq__intro-section,
.page-faq__cta-section {
    padding: 60px 0;
    text-align: center;
}

.page-faq__light-bg {
    background-color: #ffffff; /* Default light background */
    color: #333333; /* Default dark text */
}

.page-faq__dark-bg {
    background-color: #B71C1C; /* Custom Background color */
    color: #FFF5E1; /* Custom Text Main color */
}

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

.page-faq__section-title {
    font-size: 2.5em;
    margin-bottom: 20px;
    font-weight: bold;
    color: #C91F17; /* Main brand color */
}

.page-faq__section-title--white {
    color: #FFF5E1; /* Text Main color for dark background */
}

.page-faq__section-description {
    font-size: 1.1em;
    margin-bottom: 20px;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}

/* FAQ Section */
.page-faq__faq-section {
    padding: 60px 0;
}

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

.page-faq__faq-category-title {
    font-size: 1.8em;
    color: #F4D34D; /* Gold color for category titles */
    margin-top: 40px;
    margin-bottom: 25px;
    text-align: left;
    border-bottom: 2px solid rgba(255, 255, 255, 0.2);
    padding-bottom: 10px;
}

.page-faq__faq-item {
    background-color: #D32F2F; /* Card BG color */
    border-radius: 8px;
    margin-bottom: 15px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
    overflow: hidden;
    color: #FFF5E1; /* Text Main */
}

.page-faq__faq-question {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 25px;
    cursor: pointer;
    font-weight: bold;
    font-size: 1.15em;
    list-style: none; /* Hide default marker for details */
    color: #FFF5E1; /* Text Main */
}

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

.page-faq__faq-qtext {
    flex-grow: 1;
    text-align: left;
}

.page-faq__faq-toggle {
    font-size: 1.5em;
    line-height: 1;
    margin-left: 15px;
    transition: transform 0.3s ease;
}

/* Rotate the toggle icon when details is open */
.page-faq__faq-item[open] .page-faq__faq-toggle {
    transform: rotate(45deg);
}

.page-faq__faq-answer {
    padding: 0 25px 20px;
    background-color: #7A0E0E; /* Deep Red for answer background */
    font-size: 1em;
    line-height: 1.7;
    text-align: left;
    color: #FFF5E1; /* Text Main */
}

.page-faq__faq-answer p {
    margin-bottom: 15px;
}

.page-faq__faq-answer a {
    color: #FFD86A; /* Gold color for links inside answers */
    text-decoration: underline;
}

.page-faq__faq-answer a:hover {
    color: #F4D34D; /* Lighter gold on hover */
}

/* Content Images */
.page-faq__content-image {
    max-width: 100%;
    height: auto;
    display: block;
    margin: 20px auto;
    border-radius: 8px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
    min-width: 200px; /* Minimum width */
    min-height: 200px; /* Minimum height */
}

/* CTA Section */
.page-faq__cta-buttons {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-top: 30px;
}

/* Responsive Styles */
@media (max-width: 1024px) {
    .page-faq__hero-content {
        margin-top: -100px;
        padding: 25px 15px;
    }

    .page-faq__main-title {
        font-size: clamp(1.8em, 5vw, 3em);
    }

    .page-faq__section-title {
        font-size: 2em;
    }

    .page-faq__faq-list {
        max-width: 768px;
    }

    .page-faq__faq-question {
        font-size: 1.1em;
        padding: 18px 20px;
    }

    .page-faq__faq-answer {
        padding: 0 20px 18px;
    }
}

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

    .page-faq__hero-section {
        padding-bottom: 20px;
    }

    .page-faq__hero-image-wrapper {
        max-height: 300px;
    }

    .page-faq__hero-content {
        margin-top: -80px;
        padding: 20px 15px;
    }

    .page-faq__main-title {
        font-size: 1.8em !important; /* Force smaller H1 on mobile */
    }

    .page-faq__hero-description {
        font-size: 1em;
    }

    .page-faq__btn-primary,
    .page-faq__btn-secondary {
        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-faq__cta-buttons {
        flex-direction: column !important; /* Stack buttons vertically */
        gap: 15px;
        max-width: 100% !important;
        width: 100% !important;
        box-sizing: border-box !important;
        padding-left: 15px;
        padding-right: 15px;
    }

    .page-faq__intro-section,
    .page-faq__faq-section,
    .page-faq__cta-section {
        padding: 40px 0;
    }

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

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

    .page-faq__faq-list {
        margin-top: 25px;
    }

    .page-faq__faq-category-title {
        font-size: 1.5em;
        margin-top: 30px;
        margin-bottom: 20px;
        padding-left: 15px; /* Adjust padding for mobile container */
        padding-right: 15px;
    }

    .page-faq__faq-item {
        margin-left: 15px;
        margin-right: 15px;
    }

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

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

    /* Images responsiveness */
    .page-faq img {
        max-width: 100% !important;
        width: 100% !important;
        height: auto !important;
        min-width: unset !important; /* Remove min-width for mobile */
        min-height: unset !important; /* Remove min-height for mobile */
    }
    
    .page-faq__section,
    .page-faq__card,
    .page-faq__container {
        max-width: 100% !important;
        width: 100% !important;
        box-sizing: border-box !important;
        padding-left: 15px;
        padding-right: 15px;
    }
}