/**
 * FAQ Styles for Directories Custom Fields
 */

.drts-dcf-faqs {
    margin: 2rem 0;
}

.drts-dcf-faqs .drts-display-element-header {
    position: relative;
    text-align: center;
    margin-bottom: 2rem;
    font-size: 2rem;
    font-weight: 800;
}

.drts-dcf-faqs .drts-display-element-header:before {
    content: "";
    display: block;
    height: 1px;
    background-color: #e0e0e0;
    position: absolute;
    top: 50%;
    width: 100%;
    z-index: 1;
}

.drts-dcf-faqs .drts-display-element-header span {
    background-color: #fff;
    /* Match your page background */
    padding: 0 1rem;
    position: relative;
    z-index: 2;
    color: #6d6d6d;
    font-weight: 700;
}

.drts-dcf-faqs-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.drts-dcf-faq-item {
    border: 1px solid #e0e0e0;
    border-radius: 4px;
    overflow: hidden;
    background: #fff;
}

/* Accordion Style */
.drts-dcf-faqs-accordion .drts-dcf-faq-question {
    width: 100%;
    padding: 1rem 1.5rem;
    background: #f8f9fa;
    border: none;
    text-align: left;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 1rem;
    font-weight: 600;
    color: #333;
    transition: background-color 0.2s;
}

.drts-dcf-faqs-accordion .drts-dcf-faq-question:hover {
    background: #e9ecef;
}

.drts-dcf-faq-question-text {
    flex: 1;
    margin-right: 1rem;
}

.drts-dcf-faq-toggle {
    font-size: 1.5rem;
    font-weight: bold;
    color: #666;
    transition: transform 0.2s;
    line-height: 1;
}

.drts-dcf-faq-answer {
    padding: 0;
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease-out, padding 0.3s ease-out;
}

.drts-dcf-faq-answer[aria-hidden="false"] {
    padding: 1rem 1.5rem;
    max-height: 1000px;
}

.drts-dcf-faq-answer-content {
    color: #555;
    line-height: 1.6;
}

/* Simple Style (non-accordion) */
.drts-dcf-faqs:not(.drts-dcf-faqs-accordion) .drts-dcf-faq-question {
    font-size: 1.1rem;
    font-weight: 600;
    color: #333;
    margin-bottom: 0.5rem;
    padding: 0.5rem 0;
}

.drts-dcf-faqs:not(.drts-dcf-faqs-accordion) .drts-dcf-faq-answer {
    color: #555;
    line-height: 1.6;
    padding: 0.5rem 0 1rem 0;
}

/* Responsive */
@media (max-width: 768px) {
    .drts-dcf-faqs-accordion .drts-dcf-faq-question {
        padding: 0.875rem 1rem;
        font-size: 0.95rem;
    }

    .drts-dcf-faq-answer[aria-hidden="false"] {
        padding: 0.875rem 1rem;
    }
}

/* Lists in answers */
.drts-dcf-faq-answer-content ol,
.drts-dcf-faq-answer-content ul {
    margin: 0.5rem 0 0.5rem 1.5rem;
    padding: 0;
}

.drts-dcf-faq-answer-content li {
    margin-bottom: 0.25rem;
}