/**
 * Copyright © Caravel. All rights reserved.
 *
 * "Perguntas frequentes" closing the Black Cassol home: the FAQ accordion of the regular home brought into the
 * scheduled content as Page Builder elements, so the client edits the questions in the editor: Row (full-width,
 * CSS classes "bf-row bf-row--faq") > Text ("bf-faq__kick") + Heading ("bf-faq__title") > Accordion (the core
 * element, one Accordion Item per question). The accordion keeps the markup and the Alpine toggle of the theme; this
 * sheet only recolours it for the dark page (the theme paints the titles grey/black and the +/- icon in #333) and
 * spaces the items like the perks strip. The Caravel_Pagebuilder accordion.css reads the title and content colours
 * from CSS variables, set here on the row. Every rule starts at the row with #html-body to beat the
 * "#html-body [data-pb-style]" rules the Page Builder writes and the theme rules that reach into a Text or a heading.
 */

#html-body [data-content-type="row"].bf-row--faq {
    --caravel-accordion-title-color: var(--bf-text);
    --caravel-accordion-title-font-size: 16px;
    --caravel-accordion-title-font-weight: 700;
    --caravel-accordion-content-color: var(--bf-muted);
    --caravel-accordion-content-font-size: 15px;
    background-color: var(--bf-bg);
    border-top: 1px solid var(--bf-line);
    color: var(--bf-text);
}

/* Same wrap as the widgets (1360px with the mockup gutter); widget-rows.css zeroes the "bf-row" children. */
#html-body [data-content-type="row"].bf-row--faq > .row-full-width-inner {
    max-width: 1360px !important;
    margin: 0 auto;
    padding: clamp(40px, 5.6vw, 77px) clamp(16px, 4vw, 48px) clamp(56px, 7vw, 96px);
}

/* ---------- heading (the kicker and the title of the widgets) ---------- */
#html-body [data-content-type="row"].bf-row--faq .bf-faq__kick,
#html-body [data-content-type="row"].bf-row--faq .bf-faq__kick p {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 0;
    padding: 0;
    font-size: 12px;
    font-weight: 700;
    line-height: 1.2;
    letter-spacing: .16em;
    text-transform: uppercase;
    color: var(--bf-red);
}

#html-body [data-content-type="row"].bf-row--faq .bf-faq__kick {
    margin-bottom: 14px;
}

#html-body [data-content-type="row"].bf-row--faq .bf-faq__kick p::before {
    content: "";
    width: 28px;
    height: 2px;
    background: var(--bf-red);
}

#html-body [data-content-type="row"].bf-row--faq .bf-faq__title {
    margin: 0 0 18px;
    padding: 0;
    font-weight: 900;
    font-size: clamp(28px, 3.2vw, 46px);
    line-height: .95;
    letter-spacing: normal;
    text-transform: uppercase;
    color: var(--bf-text);
}

/* ---------- accordion ---------- */
#html-body [data-content-type="row"].bf-row--faq [data-content-type="accordion"] {
    margin: 0;
    padding: 0;
    list-style: none;
}

#html-body [data-content-type="row"].bf-row--faq [data-content-type="accordion-item"] {
    margin: 0;
    padding: 18px 0;
    border-bottom: 1px solid var(--bf-line);
    color: var(--bf-muted);
}

#html-body [data-content-type="row"].bf-row--faq [data-content-type="accordion-item"]:last-child {
    border-bottom: 0;
}

/* The theme's "padding-right for the +/- icon" rule lives in its home accordion scope, so the room is given here. */
#html-body [data-content-type="row"].bf-row--faq .accordion-title {
    position: relative;
    margin: 0;
    padding: 0 40px 0 0;
    line-height: 1.4;
    cursor: pointer;
    color: var(--bf-text);
}

#html-body [data-content-type="row"].bf-row--faq .accordion-title:hover {
    color: var(--bf-glow);
}

/* The theme draws the +/- icon as a #333 SVG in a background image; inverted it becomes light grey on the dark page. */
#html-body [data-content-type="row"].bf-row--faq .accordion-title::after {
    filter: invert(1);
    opacity: .85;
}

#html-body [data-content-type="row"].bf-row--faq .accordion-title:hover::after {
    opacity: 1;
}

#html-body [data-content-type="row"].bf-row--faq .accordion-content {
    margin: 0;
    padding: 0;
}

#html-body [data-content-type="row"].bf-row--faq [data-element="answer"] {
    margin: 0;
    padding: 12px 40px 4px 0;
    max-width: 880px;
    color: var(--bf-muted);
    font-size: 15px;
    line-height: 1.6;
}

#html-body [data-content-type="row"].bf-row--faq [data-element="answer"] p {
    margin: 0 0 .75rem;
    line-height: 1.6;
}

#html-body [data-content-type="row"].bf-row--faq [data-element="answer"] p:last-child {
    margin-bottom: 0;
}

#html-body [data-content-type="row"].bf-row--faq [data-element="answer"] strong {
    color: var(--bf-text);
    font-weight: 700;
}

#html-body [data-content-type="row"].bf-row--faq [data-element="answer"] a {
    color: var(--bf-text);
    text-decoration: underline;
    text-underline-offset: 2px;
}

#html-body [data-content-type="row"].bf-row--faq [data-element="answer"] a:hover {
    color: var(--bf-glow);
}

@media (max-width: 640px) {
    #html-body [data-content-type="row"].bf-row--faq [data-element="answer"] {
        padding-right: 0;
    }
}
