/* ======================================
   FAQ PAGE: a centred title, then the questions in two plain accordion columns (seven each)
   used by faq.html - every rule is scoped under .faq
   Without the script every answer stays visible; the script adds .is-ready and opens one answer at a time.
====================================== */

.faq {
    --faq-red: #ee3939;
    --faq-ink: #171717;
    --faq-text: #444444;
    --faq-line: #e5e5e5;
    position: relative;
    background: #ffffff;
    color: var(--faq-ink);
    font-family: "DM Sans", sans-serif;
}

.faq *,
.faq *::before,
.faq *::after {
    box-sizing: border-box;
}

/* same side spacing as the navbar, so the questions start under the logo */
.faq-stage {
    padding-left: 60px;
    padding-right: 60px;
}

/* ---- title ---- */
.faq-head {
    margin: 0 auto clamp(26px, 4vh, 36px);
    text-align: center;
}

.faq-title {
    margin: 0;
    font-family: "Playfair Display", serif;
    font-weight: 700;
    line-height: 1.1;
    letter-spacing: -0.01em;
    color: var(--faq-ink);
}

/* the small line above "FAQ" is part of the page's H1 and carries the search phrase */
.faq-title-kicker {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 14px;
    margin-bottom: 10px;
    font-family: "DM Sans", sans-serif;
    font-size: 12.5px;
    font-weight: 700;
    line-height: 1.4;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--faq-red);
}

.faq-title-kicker::before,
.faq-title-kicker::after {
    content: "";
    flex: none;
    width: 28px;
    height: 2px;
    background: var(--faq-red);
}

.faq-hint {
    margin: 10px 0 0;
    font-size: 14.5px;
    color: var(--faq-text);
}

/* ---- two columns of questions ---- */
.faq-window {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0 56px;
    align-items: start;
}

.faq-list {
    margin: 0;
    padding: 0;
    list-style: none;
    border-top: 1px solid var(--faq-ink);
}

.faq-item {
    margin: 0;
    padding: 0;
    border-bottom: 1px solid var(--faq-line);
}

.faq-q {
    margin: 0;
    font-family: inherit;
    font-size: inherit;
    font-weight: inherit;
    line-height: inherit;
    letter-spacing: 0;
}

.faq-btn {
    -webkit-appearance: none;
    appearance: none;
    display: flex;
    align-items: center;
    gap: 16px;
    width: 100%;
    margin: 0;
    padding: 15px 2px;
    border: 0;
    border-radius: 0;
    background: transparent;
    font-family: inherit;
    font-size: 15.5px;
    font-weight: 600;
    line-height: 1.35;
    text-align: left;
    color: var(--faq-ink);
    cursor: pointer;
    transition: color 0.25s ease;
}

/* plus sign drawn with two lines; it turns into a cross when the answer is open */
.faq-btn::after {
    content: "";
    flex: none;
    order: 2;
    margin-left: auto;
    width: 16px;
    height: 16px;
    background:
        linear-gradient(currentColor, currentColor) center / 100% 2px no-repeat,
        linear-gradient(currentColor, currentColor) center / 2px 100% no-repeat;
    transition: transform 0.25s ease;
}

.faq-btn:hover {
    color: var(--faq-red);
}

.faq-btn:focus {
    outline: none;
}

.faq-btn:focus-visible {
    outline: 2px solid var(--faq-red);
    outline-offset: -2px;
}

.faq-item.is-open .faq-btn {
    color: var(--faq-red);
}

.faq-item.is-open .faq-btn::after {
    transform: rotate(45deg);
}

/* ---- answers ---- */
.faq-answer-in {
    padding: 0 2px;             /* no vertical padding here, so a closed answer collapses to nothing */
    max-width: 720px;
    font-size: 14.5px;
    line-height: 1.65;
    color: var(--faq-text);
}

.faq-answer-in p {
    margin: 0 0 10px;
    color: inherit;
    font-size: inherit;
    line-height: inherit;
}

.faq-answer-in p:last-child {
    margin-bottom: 0;
    padding-bottom: 20px;
}

/* links to the service and city pages inside the answers */
.faq-answer-in a {
    color: var(--faq-ink);
    font-weight: 600;
    text-decoration: underline;
    text-decoration-color: var(--faq-red);
    text-decoration-thickness: 2px;
    text-underline-offset: 3px;
}

.faq-answer-in a:hover,
.faq-answer-in a:focus {
    color: var(--faq-red);
}

/* with the script: closed answers are collapsed (the grid-row trick lets the height animate) */
.faq.is-ready .faq-answer {
    display: grid;
    grid-template-rows: 0fr;
    visibility: hidden;
    transition: grid-template-rows 0.3s ease, visibility 0s linear 0.3s;
}

.faq.is-ready .faq-answer-in {
    min-height: 0;
    overflow: hidden;
}

.faq.is-ready .faq-item.is-open .faq-answer {
    grid-template-rows: 1fr;
    visibility: visible;
    transition: grid-template-rows 0.3s ease, visibility 0s;
}

/* ---- responsive ---- */
@media (max-width: 1199px) {
    .faq-stage {
        padding-left: 47px;
        padding-right: 47px;
    }

    .faq-window {
        gap: 0 36px;
    }
}

@media (max-width: 991px) {
    .faq-stage {
        padding-left: 27px;
        padding-right: 27px;
    }

    /* one column: the second list continues straight on from the first */
    .faq-window {
        grid-template-columns: minmax(0, 1fr);
    }

    .faq-list + .faq-list {
        border-top: 0;
    }
}

@media (max-width: 575px) {
    .faq-title-kicker {
        font-size: 11.5px;
        letter-spacing: 0.1em;
    }

    .faq-title-kicker::before,
    .faq-title-kicker::after {
        width: 18px;
    }

    /* the right padding keeps the plus signs clear of the floating Enquiry Now tab */
    .faq-btn {
        padding: 14px 12px 14px 2px;
        font-size: 15px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .faq-btn,
    .faq-btn::after,
    .faq.is-ready .faq-answer,
    .faq.is-ready .faq-item.is-open .faq-answer {
        transition: none;
    }
}
