/* FAQ Section - Improved Accordion with Smoother Animations */
.faq-section {
    margin: 4rem 0;
    max-width: 900px;
}

.faq-section h2 {
    font-size: 32px;
    font-weight: 700;
    margin-bottom: 2rem;
    color: #1e293b;
    text-align: left;
}

.faq-item {
    margin-bottom: 1rem;
    background: white;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    overflow: hidden;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.faq-item:hover {
    border-color: #cbd5e1;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
}

.faq-item:last-child {
    margin-bottom: 0;
}

.faq-question {
    position: relative;
    padding: 1.5rem 3.5rem 1.5rem 1.5rem;
    margin: 0;
    font-size: 18px;
    font-weight: 600;
    color: #1e293b;
    cursor: pointer;
    user-select: none;
    transition: color 0.2s ease;
    display: flex;
    align-items: center;
}

.faq-question:hover {
    color: #049CFF;
}

/* Remove Q: prefix */
.faq-question::before {
    display: none;
}

/* Plus/Minus icon with smooth rotation */
.faq-question::after {
    content: '+';
    position: absolute;
    right: 1.5rem;
    top: 50%;
    transform: translateY(-50%);
    font-size: 28px;
    font-weight: 300;
    color: #049CFF;
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    line-height: 1;
}

.faq-item.active .faq-question::after {
    content: '−';
}

.faq-answer {
    overflow: hidden;
    transition: max-height 0.4s cubic-bezier(0.4, 0, 0.2, 1),
        padding 0.4s cubic-bezier(0.4, 0, 0.2, 1),
        opacity 0.3s ease;
    padding: 0 1.5rem;
    color: #475569;
    font-size: 16px;
    line-height: 1.7;
    max-height: 0;
    opacity: 0;
}

.faq-item.active .faq-answer {
    padding: 0 1.5rem 2rem 1.5rem;
    opacity: 1;
}

/* Set max-height dynamically via JavaScript for smooth animation */
.faq-answer p {
    margin-bottom: 1rem;
}

.faq-answer p:last-child {
    margin-bottom: 0.5rem;
}

.faq-answer a {
    color: #049CFF;
    text-decoration: none;
    border-bottom: 1px solid transparent;
    transition: border-color 0.2s ease;
}

.faq-answer a:hover {
    border-bottom-color: #049CFF;
}

.faq-answer ul,
.faq-answer ol {
    margin: 1rem 0;
    padding-left: 1.5rem;
}

.faq-answer li {
    margin-bottom: 0.5rem;
}

.faq-answer code {
    background: #f1f5f9;
    padding: 0.2rem 0.5rem;
    border-radius: 4px;
    font-family: 'Monaco', 'Consolas', monospace;
    font-size: 14px;
    color: #e11d48;
}

/* Mobile responsiveness */
@media (max-width: 768px) {
    .faq-section h2 {
        font-size: 28px;
        margin-bottom: 1.5rem;
    }

    .faq-question {
        font-size: 16px;
        padding: 1.25rem 3rem 1.25rem 1.25rem;
    }

    .faq-question::after {
        right: 1.25rem;
        font-size: 24px;
    }

    .faq-answer {
        font-size: 15px;
    }

    .faq-item.active .faq-answer {
        padding: 0 1.25rem 1.25rem 1.25rem;
    }
}