/* style/faq.css */

:root {
    --primary-color: #007BFF;
    --secondary-color: #FFD700;
    --text-color-dark-bg: #ffffff;
    --text-color-light-bg: #333333;
    --light-gray-bg: #f1f3f5;
    --border-color: #e0e0e0;
    --shadow-color: rgba(0, 0, 0, 0.1);
}

/* Base styles for the page-faq */
.page-faq {
    font-family: 'Arial', sans-serif;
    line-height: 1.7;
    color: var(--text-color-dark-bg); /* Default text color for the main content area, assuming dark body background */
    background-color: transparent; /* Main content area uses body background */
}

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

/* Intro Section */
.page-faq__intro-section {
    background: linear-gradient(135deg, var(--primary-color) 0%, #4a90e2 100%); /* Blue gradient for intro */
    padding-bottom: 60px;
    text-align: center;
    position: relative;
    overflow: hidden;
    color: var(--text-color-dark-bg);
    /* Fixed navigation bar spacing */
    padding-top: 120px; /* Desktop: Adjust based on fixed header height */
}

.page-faq__main-title {
    font-size: 42px;
    font-weight: bold;
    margin-bottom: 20px;
    color: var(--text-color-dark-bg);
}

.page-faq__main-title .highlight {
    color: var(--secondary-color);
}

.page-faq__intro-text {
    font-size: 18px;
    margin-bottom: 30px;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}

.page-faq__intro-text strong {
    font-weight: bold;
}

.page-faq__intro-image-wrapper {
    margin-bottom: 40px;
    max-width: 900px;
    margin-left: auto;
    margin-right: auto;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.2);
}

.page-faq__intro-image {
    width: 100%;
    height: auto;
    display: block;
    object-fit: cover;
}

.page-faq__cta-button {
    display: inline-block;
    padding: 15px 40px;
    background: var(--secondary-color);
    color: var(--text-color-light-bg);
    text-decoration: none;
    border-radius: 8px;
    font-size: 20px;
    font-weight: bold;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    border: none;
}

.page-faq__cta-button:hover {
    background: #e6c200;
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
}

/* FAQ Section */
.page-faq__faq-section {
    background-color: var(--light-gray-bg);
    padding: 60px 0;
    color: var(--text-color-light-bg);
}

.page-faq__section-title {
    font-size: 34px;
    font-weight: bold;
    text-align: center;
    margin-bottom: 40px;
    color: var(--text-color-light-bg);
}

.page-faq__section-title .highlight {
    color: var(--primary-color);
}

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

.page-faq__faq-item {
    margin-bottom: 15px;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 10px var(--shadow-color);
}

.page-faq__faq-question {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 18px 25px;
    background: #ffffff;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    cursor: pointer;
    user-select: none;
    transition: background-color 0.3s ease, border-color 0.3s ease;
    position: relative;
}

.page-faq__faq-question:hover {
    background: #f5f5f5;
    border-color: #c0c0c0;
}

.page-faq__faq-question:active {
    background: #eeeeee;
}

.page-faq__faq-question h3 {
    margin: 0;
    padding: 0;
    flex: 1;
    font-size: 18px;
    font-weight: 600;
    line-height: 1.5;
    color: var(--text-color-light-bg);
    pointer-events: none; /* Prevents text selection from interfering with click */
}

.page-faq__faq-toggle {
    font-size: 28px;
    font-weight: bold;
    line-height: 1;
    color: var(--primary-color);
    transition: transform 0.3s ease, color 0.3s ease;
    flex-shrink: 0;
    margin-left: 15px;
    pointer-events: none; /* Prevents toggle from interfering with click */
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
}

.page-faq__faq-item.active .page-faq__faq-toggle {
    color: #cc0000; /* Red for minus icon */
    transform: rotate(180deg); /* Rotate for minus effect */
}

.page-faq__faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s cubic-bezier(0.4, 0, 0.2, 1), padding 0.4s ease, opacity 0.4s ease;
    padding: 0 25px;
    opacity: 0;
    background: #f9f9f9;
    border-radius: 0 0 8px 8px;
    color: var(--text-color-light-bg);
    text-align: left;
}

.page-faq__faq-item.active .page-faq__faq-answer {
    max-height: 2000px !important; /* Sufficiently large value */
    padding: 20px 25px !important;
    opacity: 1;
    border: 1px solid var(--border-color);
    border-top: none;
}

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

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

.page-faq__faq-answer a {
    color: var(--primary-color);
    text-decoration: none;
    font-weight: bold;
    transition: color 0.3s ease;
}

.page-faq__faq-answer a:hover {
    color: #0056b3;
    text-decoration: underline;
}

.page-faq__content-image-wrapper {
    margin: 20px 0;
    text-align: center;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
}

.page-faq__content-image {
    width: 100%;
    height: auto;
    display: block;
    object-fit: cover;
}

.page-faq__final-cta-text {
    text-align: center;
    margin-top: 40px;
    font-size: 18px;
    font-weight: 500;
    color: var(--text-color-light-bg);
}

.page-faq__final-cta-text a {
    color: var(--primary-color);
    text-decoration: none;
    font-weight: bold;
}

.page-faq__final-cta-text a:hover {
    text-decoration: underline;
    color: #0056b3;
}

/* Responsive Design */
@media (max-width: 992px) {
    .page-faq__main-title {
        font-size: 38px;
    }
    .page-faq__section-title {
        font-size: 30px;
    }
    .page-faq__faq-question h3 {
        font-size: 17px;
    }
    .page-faq__faq-toggle {
        font-size: 26px;
        width: 30px;
        height: 30px;
    }
    .page-faq__cta-button {
        padding: 12px 30px;
        font-size: 18px;
    }
}

@media (max-width: 768px) {
    .page-faq__intro-section {
        padding-top: 100px !important; /* Mobile: Adjust based on fixed header height */
        padding-bottom: 40px;
    }
    .page-faq__faq-section {
        padding: 40px 0;
    }
    .page-faq__main-title {
        font-size: 32px;
        margin-bottom: 15px;
    }
    .page-faq__intro-text {
        font-size: 16px;
        margin-bottom: 25px;
    }
    .page-faq__section-title {
        font-size: 26px;
        margin-bottom: 30px;
    }
    .page-faq__faq-question {
        padding: 15px 20px;
    }
    .page-faq__faq-question h3 {
        font-size: 16px;
    }
    .page-faq__faq-toggle {
        font-size: 24px;
        width: 28px;
        height: 28px;
        margin-left: 10px;
    }
    .page-faq__faq-answer {
        padding: 0 20px;
    }
    .page-faq__faq-item.active .page-faq__faq-answer {
        padding: 15px 20px !important;
    }
    .page-faq__faq-answer p {
        font-size: 15px;
    }
    .page-faq__cta-button {
        padding: 10px 25px;
        font-size: 16px;
    }
    .page-faq__final-cta-text {
        font-size: 16px;
        margin-top: 30px;
    }

    /* Ensure all images are responsive and do not cause overflow */
    .page-faq img {
      max-width: 100% !important;
      width: 100% !important;
      height: auto !important;
      box-sizing: border-box !important;
    }
    .page-faq__container,
    .page-faq__intro-section,
    .page-faq__faq-section,
    .page-faq__faq-list,
    .page-faq__faq-item,
    .page-faq__content-image-wrapper,
    .page-faq__intro-image-wrapper {
        max-width: 100% !important;
        width: 100% !important;
        box-sizing: border-box !important;
        padding-left: 15px;
        padding-right: 15px;
    }
}

@media (max-width: 480px) {
    .page-faq__main-title {
        font-size: 28px;
    }
    .page-faq__section-title {
        font-size: 22px;
    }
    .page-faq__faq-question h3 {
        font-size: 15px;
    }
    .page-faq__cta-button {
        width: 100%;
        max-width: 280px;
    }
    .page-faq__intro-image-wrapper {
      border-radius: 8px;
    }
    .page-faq__faq-item {
      border-radius: 4px;
    }
    .page-faq__faq-question {
      border-radius: 4px;
    }
    .page-faq__faq-item.active .page-faq__faq-answer {
      border-radius: 0 0 4px 4px;
    }
}