/* FAQ — 2-column layout of native <details> accordions.
   Heading uses shared .circla-heading (see style.css). */

.faq-block {
    padding: 80px 0;
    background-color: #e0e7e2;
}

.faq-block__inner {
    max-width: 1264px;
    margin: 0 auto;
    padding: 0 32px;
}

.faq-block__header {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 16px;
    margin-bottom: 72px;
}

.faq-block__intro {
    max-width: 862px;
    margin: 0;
    font-family: "Open Sans";
    font-size: 16px;
    line-height: 24px;
    color: #161616;
}

/* Two independent columns. Each column is its own vertical stack, so opening
   an item only pushes items below it in that column — the other column never
   moves and items never jump between columns. */
.faq-block__list {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
    align-items: start;
}

.faq-block__col {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.faq-block__item {
    background-color: #fff;
    border-radius: 16px;
    overflow: hidden;
}

.faq-block__question {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
    padding: 24px;
    cursor: pointer;
    font-family: "Open Sans";
    font-weight: 700;
    font-size: 18px;
    line-height: 27px;
    color: #2c3536;
    list-style: none;
}

.faq-block__question::-webkit-details-marker {
    display: none;
}

.faq-block__toggle {
    flex-shrink: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    font-size: 24px;
    font-weight: 300;
    line-height: 1;
    color: #161616;
}

.faq-block__toggle::before {
    content: "+";
}

.faq-block__item[open] .faq-block__toggle::before {
    content: "\2212"; /* minus sign */
}

/* Animated dropdown — controlled by inline JS in faq.php that measures the
   real content height and animates `height` + `padding-bottom`. We force
   `display: block !important` so the answer is always in flow (the browser
   UA otherwise sets `display: none` on closed <details> children, which can't
   transition). The base height: 0 keeps it collapsed until the JS opens it. */
.faq-block__item .faq-block__answer {
    display: block !important;
    overflow: hidden;
    height: 0;
    /* border-box so the JS-set `height` includes the bottom padding — content-box
       makes scrollHeight (which includes padding) overshoot, causing a snap at
       the end when height resolves back to `auto`. */
    box-sizing: border-box;
    padding: 0 24px;
    font-family: "Open Sans";
    font-size: 16px;
    line-height: 24px;
    color: #444;
}

.faq-block__item[open] .faq-block__answer {
    /* Open state without JS (fallback): just show it. The JS overrides this
       with an inline `height: auto` after the open transition completes. */
    height: auto;
    padding-bottom: 24px;
}

.faq-block__answer p {
    margin: 0 0 12px;
}

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

@media (max-width: 768px) {
    .faq-block {
        padding: 40px 16px;
    }
    .faq-block__inner {
        padding: 0; /* block now supplies the 16px gutter */
    }
    .faq-block__list {
        grid-template-columns: 1fr;
    }
    /* Header left-aligned on mobile, not centred. */
    .faq-block__header {
        align-items: flex-start;
        text-align: left;
        margin-bottom: 24px;
    }
    /* Hide the intro visually on mobile but keep it for screen readers / SEO. */
    .faq-block__intro {
        position: absolute;
        width: 1px;
        height: 1px;
        padding: 0;
        margin: -1px;
        overflow: hidden;
        clip: rect(0, 0, 0, 0);
        white-space: nowrap;
        border: 0;
    }
}
