/* style/faq.css */

/* Base styles for the FAQ page */
.page-faq {
    color: #ffffff; /* Text color for dark body background */
    font-family: Arial, sans-serif;
    line-height: 1.6;
    background-color: transparent; /* Body background handled by shared.css */
}

/* Hero Section */
.page-faq__hero-section {
    position: relative;
    padding: 80px 20px;
    padding-top: var(--header-offset, 120px); /* Ensure space for fixed header */
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    overflow: hidden; /* Prevent image overflow */
    background-color: #017439; /* Use brand color for hero background */
}

.page-faq__hero-content {
    position: relative;
    z-index: 10;
    max-width: 900px;
    margin-bottom: 30px;
}

.page-faq__main-title {
    font-size: 3em;
    color: #FFFF00; /* Use specified font color for main title */
    margin-bottom: 20px;
    line-height: 1.2;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
}

.page-faq__hero-description {
    font-size: 1.2em;
    color: #ffffff;
    margin-bottom: 30px;
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
}

.page-faq__hero-image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.3; /* Subtle background image */
    z-index: 1;
}

/* Call to Action Buttons in Hero */
.page-faq__cta-buttons {
    display: flex;
    gap: 20px;
    justify-content: center;
    flex-wrap: wrap; /* Allow wrapping on small screens */
    position: relative;
    z-index: 10;
}

.page-faq__btn-primary,
.page-faq__btn-secondary {
    display: inline-block;
    padding: 15px 30px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: bold;
    font-size: 1.1em;
    transition: background-color 0.3s ease, transform 0.3s ease;
    box-sizing: border-box; /* Include padding in width */
    white-space: normal; /* Allow text wrapping */
    word-wrap: break-word; /* Allow text wrapping */
    max-width: 100%;
}

.page-faq__btn-primary {
    background-color: #C30808; /* Register color */
    color: #FFFF00; /* Register font color */
    border: 2px solid #C30808;
}

.page-faq__btn-primary:hover {
    background-color: #a00606;
    transform: translateY(-3px);
}

.page-faq__btn-secondary {
    background-color: transparent;
    color: #FFFF00; /* Login font color */
    border: 2px solid #C30808; /* Login border color */
}

.page-faq__btn-secondary:hover {
    background-color: rgba(195, 8, 8, 0.2);
    transform: translateY(-3px);
}

/* Content Area */
.page-faq__content-area {
    max-width: 1200px;
    margin: 0 auto;
    padding: 60px 20px;
    background-color: #000000; /* Ensure content area has a dark background if not inherited */
    color: #ffffff; /* Ensure text is white for contrast */
}

.page-faq__section-title {
    font-size: 2.5em;
    color: #FFFF00;
    text-align: center;
    margin-bottom: 50px;
    position: relative;
    padding-bottom: 15px;
}

.page-faq__section-title::after {
    content: '';
    position: absolute;
    left: 50%;
    bottom: 0;
    transform: translateX(-50%);
    width: 80px;
    height: 4px;
    background-color: #017439;
    border-radius: 2px;
}

/* FAQ Category */
.page-faq__faq-category {
    margin-bottom: 40px;
    background-color: rgba(255, 255, 255, 0.05); /* Slightly lighter background for categories */
    border-radius: 10px;
    padding: 20px;
}

.page-faq__category-title {
    font-size: 2em;
    color: #017439; /* Brand color for category titles */
    margin-bottom: 30px;
    text-align: center;
    padding-bottom: 10px;
    border-bottom: 2px solid rgba(1, 116, 57, 0.5);
}

/* FAQ List Item */
.page-faq__faq-item {
    background-color: rgba(255, 255, 255, 0.1); /* Card background for each FAQ item */
    margin-bottom: 15px;
    border-radius: 8px;
    overflow: hidden;
    transition: background-color 0.3s ease;
}

.page-faq__faq-item:hover {
    background-color: rgba(255, 255, 255, 0.15);
}

.page-faq__faq-question {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 25px;
    cursor: pointer;
    font-size: 1.1em;
    font-weight: bold;
    color: #ffffff;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.page-faq__faq-item.active .page-faq__faq-question {
    border-bottom: 1px solid #017439;
    color: #FFFF00;
}

.page-faq__faq-question-text {
    flex-grow: 1;
    margin-right: 15px;
}

.page-faq__faq-toggle {
    font-size: 1.5em;
    font-weight: normal;
    transition: transform 0.3s ease;
    color: #017439;
}

.page-faq__faq-item.active .page-faq__faq-toggle {
    transform: rotate(45deg);
    color: #FFFF00;
}

.page-faq__faq-answer {
    max-height: 0;
    overflow: hidden;
    padding: 0 25px;
    transition: max-height 0.3s ease-out, padding 0.3s ease-out;
    color: #f0f0f0;
}

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

.page-faq__faq-answer p:last-child {
    margin-bottom: 0;
}

.page-faq__faq-answer a {
    color: #FFFF00; /* Link color within answers */
    text-decoration: underline;
}

.page-faq__faq-answer a:hover {
    color: #017439;
}

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

.page-faq__faq-item.active .page-faq__faq-answer {
    max-height: 1000px !important; /* Sufficiently large to show content */
    padding: 20px 25px;
}

/* CTA Section at the bottom */
.page-faq__cta-section {
    text-align: center;
    padding: 60px 20px;
    background-color: #017439; /* Brand color background for CTA */
    border-radius: 10px;
    margin-top: 50px;
}

.page-faq__cta-title {
    font-size: 2.2em;
    color: #FFFF00;
    margin-bottom: 20px;
}

.page-faq__cta-description {
    font-size: 1.1em;
    color: #ffffff;
    max-width: 800px;
    margin: 0 auto 30px auto;
}

/* Responsive Design */
@media (max-width: 1024px) {
    .page-faq__main-title {
        font-size: 2.5em;
    }
    .page-faq__hero-description {
        font-size: 1.1em;
    }
    .page-faq__section-title {
        font-size: 2em;
    }
    .page-faq__category-title {
        font-size: 1.8em;
    }
}

@media (max-width: 768px) {
    .page-faq__hero-section {
        padding: 60px 15px;
        padding-top: var(--header-offset, 120px) !important; /* Ensure mobile header offset */
    }
    .page-faq__main-title {
        font-size: 2em;
        margin-bottom: 15px;
    }
    .page-faq__hero-description {
        font-size: 1em;
        margin-bottom: 20px;
    }
    .page-faq__cta-buttons {
        flex-direction: column;
        gap: 15px;
        width: 100%;
        max-width: 300px; /* Constrain button width on mobile */
        margin-left: auto;
        margin-right: auto;
    }
    .page-faq__btn-primary,
    .page-faq__btn-secondary {
        width: 100% !important;
        max-width: 100% !important;
        padding: 12px 20px;
        font-size: 1em;
        white-space: normal !important;
        word-wrap: break-word !important;
    }

    .page-faq__content-area,
    .page-faq__faq-category,
    .page-faq__cta-section {
        max-width: 100% !important;
        width: 100% !important;
        box-sizing: border-box !important;
        padding-left: 15px;
        padding-right: 15px;
    }

    .page-faq img {
        max-width: 100% !important;
        width: 100% !important;
        height: auto !important;
        display: block !important;
    }

    .page-faq__section-title {
        font-size: 1.8em;
        margin-bottom: 30px;
    }
    .page-faq__category-title {
        font-size: 1.5em;
        margin-bottom: 20px;
    }
    .page-faq__faq-question {
        padding: 15px 20px;
        font-size: 1em;
    }
    .page-faq__faq-answer {
        padding: 15px 20px;
    }
    .page-faq__cta-title {
        font-size: 1.8em;
    }
    .page-faq__cta-description {
        font-size: 1em;
    }
}

@media (max-width: 480px) {
    .page-faq__main-title {
        font-size: 1.8em;
    }
    .page-faq__section-title {
        font-size: 1.5em;
    }
    .page-faq__category-title {
        font-size: 1.3em;
    }
    .page-faq__faq-question {
        font-size: 0.95em;
    }
}