/**
 * Academia – FAQ Accordion Styles
 * Version: 2 – 2026-06-04
 *
 * Loaded globally on all pages so any template can use academia_render_faq()
 * without needing to duplicate these rules in its own stylesheet.
 *
 * Design tokens from academia-design-system.css:
 *   --color-deepblue-700/800  active question background
 *   --color-neutrals-0/100    white / off-white backgrounds
 *   --color-neutrals-200      border colour
 *   --color-neutrals-1000     primary text
 *   --secondary-brand         active border + link colour
 */

/* ============================================================================
   SECTION WRAPPER
   ========================================================================= */

.faq-section {
    margin-bottom: 80px;
}

.faq-list {
    max-width: 900px;
    margin: 0 auto 32px;
}

/* ============================================================================
   ACCORDION ITEMS
   ========================================================================= */

.faq-item {
    border: 1px solid var(--color-neutrals-200, #d9d9d9);
    border-radius: 8px;
    margin-bottom: 16px;
    overflow: hidden;
}

.faq-item.active {
    border-color: var(--secondary-brand, #008fdd);
}

/* ============================================================================
   QUESTION BUTTON
   ========================================================================= */

.faq-question {
    width: 100%;
    padding: 20px 24px;
    background: var(--color-neutrals-0, #ffffff);
    border: none;
    display: flex;
    justify-content: space-between;
    align-items: center;
    cursor: pointer;
    font-size: 16px;
    font-weight: 600;
    color: var(--color-neutrals-1000, #383838);
    text-align: left;
    transition: background 0.3s, color 0.3s;
}

.faq-question:hover {
    background: var(--color-neutrals-100, #fafafa);
    color: var(--color-neutrals-1000, #383838);
}

/* Active item: deepblue background, white text */
.faq-item.active .faq-question {
    background: var(--color-deepblue-800, #002b46);
    color: #ffffff;
}

.faq-item.active .faq-question:hover {
    background: var(--color-deepblue-700, #00385b);
    color: #ffffff;
}

/* Chevron icon */
.faq-question i {
    transition: transform 0.3s;
    flex-shrink: 0;
}

.faq-item.active .faq-question i {
    transform: rotate(180deg);
}

/* ============================================================================
   ANSWER PANEL
   First item opened by CSS (.active); subsequent open/close via JS slideDown/Up.
   ========================================================================= */

.faq-answer {
    padding: 0 24px 20px;
    display: none;
}

.faq-item.active .faq-answer {
    display: block;
}

/* ============================================================================
   "SEE ALL" LINK
   ========================================================================= */

.faq-link {
    margin-top: 32px;
}
