/* style/faq.css */

/* Base styles for the FAQ page */
.page-faq {
    font-family: 'Arial', sans-serif;
    line-height: 1.6;
    color: #333333; /* Dark text for light body background */
    background-color: #FFFFFF; /* Ensure consistency with body background */
}

/* Header offset for fixed header */
.page-faq__hero-section {
    padding-top: var(--header-offset, 120px); /* Desktop and mobile offset */
}

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

.page-faq__hero-section {
    background-color: #FFFFFF;
    text-align: center;
    padding-bottom: 60px;
}

.page-faq__main-title {
    font-size: 2.8em;
    color: #017439; /* Primary brand color */
    margin-bottom: 20px;
    font-weight: bold;
    line-height: 1.2;
}

.page-faq__intro-text {
    font-size: 1.2em;
    color: #555555;
    margin-bottom: 40px;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}

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

.page-faq__btn-primary,
.page-faq__btn-secondary,
.page-faq__btn-tertiary {
    display: inline-block;
    padding: 12px 25px;
    border-radius: 8px;
    font-weight: bold;
    text-decoration: none;
    transition: background-color 0.3s ease, color 0.3s ease, border-color 0.3s ease;
    cursor: pointer;
    text-align: center;
    box-sizing: border-box; /* Important for responsiveness */
}

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

.page-faq__btn-primary:hover {
    background-color: #a00606;
    border-color: #a00606;
}

.page-faq__btn-secondary {
    background-color: #FFFFFF;
    color: #C30808; /* Register/Login button background as text color */
    border: 2px solid #C30808;
}

.page-faq__btn-secondary:hover {
    background-color: #C30808;
    color: #FFFFFF;
}

.page-faq__btn-tertiary {
    background-color: #017439; /* Primary brand color */
    color: #FFFFFF;
    border: 2px solid #017439;
}

.page-faq__btn-tertiary:hover {
    background-color: #005a2e;
    border-color: #005a2e;
}

.page-faq__faq-list-section {
    padding: 80px 0;
    background-color: #f9f9f9;
}

.page-faq__section-title {
    font-size: 2.2em;
    color: #017439;
    text-align: center;
    margin-bottom: 20px;
    font-weight: bold;
}

.page-faq__section-description {
    font-size: 1.1em;
    color: #555555;
    text-align: center;
    max-width: 900px;
    margin: 0 auto 60px auto;
}

.page-faq__faq-group {
    margin-bottom: 60px;
}

.page-faq__group-title {
    font-size: 1.8em;
    color: #017439;
    margin-bottom: 30px;
    border-bottom: 2px solid #e0e0e0;
    padding-bottom: 15px;
    font-weight: bold;
}

.page-faq__faq-item {
    background-color: #ffffff;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    margin-bottom: 15px;
    overflow: hidden;
    box-shadow: 0 2px 5px rgba(0,0,0,0.05);
}

.page-faq__faq-item summary {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 25px;
    font-size: 1.15em;
    font-weight: bold;
    color: #333333;
    cursor: pointer;
    outline: none;
    list-style: none; /* Remove default marker */
}

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

.page-faq__faq-question {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
}

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

.page-faq__faq-item[open] .page-faq__faq-toggle {
    transform: rotate(45deg); /* Change + to X or similar when open */
}
/* For details, the toggle logic is handled by JS in faq.js for the visual + / - change */
.page-faq__faq-item.active .page-faq__faq-toggle {
    transform: rotate(45deg);
}


.page-faq__faq-answer {
    padding: 0 25px 20px 25px;
    color: #555555;
    font-size: 1em;
    line-height: 1.8;
    /* max-height: 0; */ /* Removed for native details behavior */
    overflow: hidden;
    /* transition: max-height 0.5s ease-out; */ /* Removed for native details behavior */
}

/* .page-faq__faq-item[open] .page-faq__faq-answer { */
    /* max-height: 2000px; */ /* Removed for native details behavior */
/* } */

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

.page-faq__faq-answer ul {
    margin-bottom: 15px;
    padding-left: 25px;
}

.page-faq__faq-answer li {
    margin-bottom: 8px;
}

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

.page-faq__text-link {
    color: #017439;
    text-decoration: underline;
    font-weight: bold;
    transition: color 0.3s ease;
}

.page-faq__text-link:hover {
    color: #005a2e;
}

.page-faq__info-links {
  display: flex;
  flex-wrap: wrap;
  gap: 15px;
  margin-top: 20px;
}

.page-faq__info-links .page-faq__text-link {
  padding: 8px 15px;
  border: 1px solid #017439;
  border-radius: 5px;
  text-decoration: none;
  background-color: #f0fdf5;
}

.page-faq__info-links .page-faq__text-link:hover {
  background-color: #017439;
  color: #FFFFFF;
}

/* CTA Section at the bottom */
.page-faq__cta-section {
    background-color: #017439; /* Primary brand color */
    color: #ffffff;
    padding: 80px 20px;
    text-align: center;
    margin-top: 60px;
}

.page-faq__cta-title {
    font-size: 2.5em;
    margin-bottom: 20px;
    font-weight: bold;
    line-height: 1.2;
}

.page-faq__cta-description {
    font-size: 1.1em;
    max-width: 800px;
    margin: 0 auto 40px auto;
    line-height: 1.8;
}

/* Responsive Design */
@media (max-width: 1024px) {
    .page-faq__main-title {
        font-size: 2.2em;
    }
    .page-faq__section-title {
        font-size: 1.8em;
    }
    .page-faq__group-title {
        font-size: 1.5em;
    }
    .page-faq__faq-item summary {
        font-size: 1.1em;
        padding: 18px 20px;
    }
    .page-faq__cta-title {
        font-size: 2em;
    }
}

@media (max-width: 768px) {
    .page-faq__hero-section {
        padding-bottom: 40px;
    }
    .page-faq__main-title {
        font-size: 1.8em;
    }
    .page-faq__intro-text {
        font-size: 1em;
        margin-bottom: 30px;
    }
    .page-faq__cta-buttons {
        flex-direction: column;
        gap: 15px;
        padding: 0 15px; /* Add padding to prevent buttons touching edges */
    }
    .page-faq__btn-primary,
    .page-faq__btn-secondary,
    .page-faq__btn-tertiary {
        max-width: 100% !important;
        width: 100% !important;
        white-space: normal !important;
        word-wrap: break-word !important;
        padding: 12px 15px; /* Adjust padding for mobile */
    }

    .page-faq__faq-list-section {
        padding: 60px 0;
    }
    .page-faq__section-title {
        font-size: 1.6em;
    }
    .page-faq__section-description {
        font-size: 0.95em;
        margin-bottom: 40px;
    }
    .page-faq__group-title {
        font-size: 1.3em;
        margin-bottom: 20px;
    }
    .page-faq__faq-item summary {
        font-size: 1em;
        padding: 15px 18px;
    }
    .page-faq__faq-answer {
        font-size: 0.9em;
        padding: 0 18px 15px 18px;
    }
    .page-faq__image {
        max-width: 100% !important;
        width: 100% !important;
        height: auto !important;
        box-sizing: border-box !important; /* Ensure padding/border is included in width */
    }
    .page-faq__container {
        padding: 0 15px; /* Add mobile padding for content */
        max-width: 100% !important;
        width: 100% !important;
        box-sizing: border-box !important;
        overflow-x: hidden !important; /* Prevent horizontal scroll */
    }
    .page-faq__cta-section {
        padding: 60px 15px;
    }
    .page-faq__cta-title {
        font-size: 1.8em;
    }
    .page-faq__cta-description {
        font-size: 1em;
    }
    .page-faq__info-links {
        flex-direction: column;
        align-items: center;
    }
    .page-faq__info-links .page-faq__text-link {
        width: 100%;
        text-align: center;
    }
}