/* ==========================================================================
   FAQ Page
   BEM block: sd-faq
   Gradient hero with live search + theme chips, numbered theme sections,
   native <details> accordions with the site's chevron pattern.
   ========================================================================== */

.sd-faq-page {
    --fq-primary: var(--sd-color-primary, #36452f);
    --fq-accent: var(--sd-color-cta, #5f7d3a);
    --fq-accent-hover: var(--sd-color-cta-hover, #8db35a);
    --fq-text: var(--sd-color-text, #171717);
    --fq-text-light: var(--sd-color-text-light, #525252);
    --fq-cream: var(--sd-color-cream, #f8f6ee);
    --fq-rule: rgba(23, 23, 23, 0.08);
    --fq-radius: 8px;

    background: #ffffff;
    color: var(--fq-text);
    -webkit-font-smoothing: antialiased;
}

.sd-faq-page h1,
.sd-faq-page h2 {
    font-family: var(--sd-font-family-primary, 'Outfit', sans-serif);
}

.sd-faq__container {
    max-width: 1080px;
    margin-inline: auto;
    padding-inline: clamp(1.25rem, 5vw, 3.5rem);
}

/* ── Hero ────────────────────────────────────────────────────── */
.sd-faq__hero {
    background: var(--sd-color-primary, #36452f); /* flat, matches nav */
    color: #ffffff;
    padding: clamp(6.5rem, 11vw, 9rem) 0 clamp(2.25rem, 4.5vw, 3.25rem);
}

.sd-faq__overline {
    display: inline-flex;
    align-items: center;
    gap: 0.6rem;
    font-size: 0.9375rem;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.6);
    margin: 0 0 1rem;
}

.sd-faq__title {
    /* typography.css paints headings dark; colour must be explicit */
    color: #ffffff;
    font-size: clamp(2.25rem, 5vw, 4rem); /* unified hero title scale */
    line-height: 1.05;
    letter-spacing: -0.02em;
    margin: 0 0 1rem;
}

.sd-faq__sub {
    font-size: clamp(1rem, 1.4vw, 1.125rem);
    color: rgba(255, 255, 255, 0.78);
    line-height: 1.65;
    max-width: 560px;
    margin: 0 0 1.75rem;
}

/* Search */
.sd-faq__search {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    background: #ffffff;
    border-radius: 999px;
    padding: 0.35rem 0.5rem 0.35rem 1.25rem;
    max-width: 560px;
    color: var(--fq-text-light);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.18);
}

.sd-faq__search input {
    flex: 1;
    border: none;
    background: none;
    outline: none;
    font-family: inherit;
    font-size: 0.9375rem;
    color: var(--fq-text);
    padding: 0.55rem 0.5rem 0.55rem 0;
}

.sd-faq__search input::placeholder {
    color: rgba(23, 23, 23, 0.4);
}

.sd-faq__results {
    font-size: 0.8125rem;
    color: rgba(255, 255, 255, 0.75);
    margin: 0.75rem 0 0;
}

/* Theme chips */
.sd-faq__chips {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: 1.5rem;
}

.sd-faq__chip {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    font-size: 0.8125rem;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.92);
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.16);
    border-radius: 999px;
    padding: 0.45rem 1rem;
    text-decoration: none;
    transition: all 0.2s ease;
}

.sd-faq__chip:hover {
    background: rgba(255, 255, 255, 0.18);
    border-color: rgba(255, 255, 255, 0.35);
    color: #ffffff;
}

.sd-faq__chip-count {
    font-size: 0.6875rem;
    color: var(--fq-accent-hover);
    font-variant-numeric: tabular-nums;
}

/* ── Themed sections ─────────────────────────────────────────── */
.sd-faq__main {
    padding-block: clamp(2.5rem, 5vw, 4rem);
}

.sd-faq__theme {
    margin-bottom: clamp(2.5rem, 5vw, 4rem);
    scroll-margin-top: calc(var(--sd-header-height-desktop, 88px) + 1.5rem);
}

.sd-faq__theme-head {
    display: flex;
    align-items: baseline;
    gap: 0.75rem;
    border-bottom: 1px solid rgba(23, 23, 23, 0.18);
    padding-bottom: 0.85rem;
    margin-bottom: 0.5rem;
}

.sd-faq__theme-num {
    font-family: var(--sd-font-family-primary, 'Outfit', sans-serif);
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--fq-accent);
    font-variant-numeric: tabular-nums;
}

.sd-faq__theme-title {
    font-size: clamp(1.375rem, 2.4vw, 1.75rem);
    letter-spacing: -0.015em;
    margin: 0;
}

/* Accordion items — native details/summary */
.sd-faq__item {
    border-bottom: 1px solid var(--fq-rule);
}

.sd-faq__question {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 1.1rem 0.25rem;
    font-size: 1.0625rem;
    font-weight: 600;
    color: var(--fq-text);
    cursor: pointer;
    list-style: none;
    transition: color 0.15s ease;
}

.sd-faq__question::-webkit-details-marker {
    display: none;
}

.sd-faq__question:hover {
    color: var(--fq-primary);
}

.sd-faq__chevron {
    flex-shrink: 0;
    color: var(--fq-accent);
    transition: transform 0.25s ease;
}

.sd-faq__item[open] .sd-faq__chevron {
    transform: rotate(180deg);
}

.sd-faq__answer {
    padding: 0 0.25rem 1.25rem;
    max-width: 760px;
    font-size: 0.9375rem;
    line-height: 1.7;
    color: var(--fq-text-light);
}

.sd-faq__answer p {
    margin: 0 0 0.9em;
}

.sd-faq__answer p:last-child {
    margin-bottom: 0;
}

.sd-faq__answer ul {
    margin: 0.5em 0 0.9em;
    padding-left: 1.25rem;
}

.sd-faq__answer li {
    margin-bottom: 0.35em;
}

.sd-faq__answer a {
    color: var(--fq-accent);
}

/* No results */
.sd-faq__no-results {
    text-align: center;
    padding: clamp(2.5rem, 6vw, 4rem) 1rem;
    color: var(--fq-text-light);
}

.sd-faq__no-results p {
    margin: 0 0 0.75rem;
}

.sd-faq__no-results strong {
    color: var(--fq-text);
    font-size: 1.125rem;
}

.sd-faq__no-results .sd-faq__btn {
    margin-top: 1rem;
}

/* ── CTA ─────────────────────────────────────────────────────── */
.sd-faq__cta {
    padding-bottom: clamp(3rem, 6vw, 5rem);
}

.sd-faq__cta-inner {
    background: var(--fq-primary);
    color: #ffffff;
    border-radius: var(--fq-radius);
    padding: clamp(2rem, 4vw, 3rem) clamp(2rem, 4.5vw, 3.5rem);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 2rem;
    flex-wrap: wrap;
}

.sd-faq__cta-title {
    color: #ffffff; /* typography.css dark-heading bleed */
    font-size: clamp(1.375rem, 2.4vw, 1.875rem);
    margin: 0 0 0.4rem;
}

.sd-faq__cta-sub {
    font-size: 0.9375rem;
    color: rgba(255, 255, 255, 0.75);
    line-height: 1.6;
    margin: 0;
    max-width: 520px;
}

.sd-faq__cta-actions {
    display: flex;
    gap: 0.75rem;
    flex-wrap: wrap;
}

.sd-faq__btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 0.9375rem;
    font-weight: 600;
    padding: 0.875rem 1.875rem;
    border-radius: 999px;
    text-decoration: none;
    transition: all 0.2s ease;
    white-space: nowrap;
    line-height: 1;
}

.sd-faq__btn--primary {
    background: var(--fq-accent);
    color: #ffffff;
}

.sd-faq__btn--primary:hover {
    background: var(--sd-color-cta-strong, #4f6b30);
    transform: translateY(-1px);
}

.sd-faq__cta .sd-faq__btn--outline {
    color: #ffffff;
    border: 1.5px solid rgba(255, 255, 255, 0.5);
    font-variant-numeric: tabular-nums;
}

.sd-faq__cta .sd-faq__btn--outline:hover {
    border-color: #ffffff;
    background: rgba(255, 255, 255, 0.1);
}

.sd-faq__empty {
    color: var(--fq-text-light);
    text-align: center;
    padding: 3rem 0;
}

/* ── Responsive ──────────────────────────────────────────────── */
@media (max-width: 680px) {
    .sd-faq__question {
        font-size: 0.9375rem;
        padding-block: 0.95rem;
    }

    .sd-faq__cta-inner {
        flex-direction: column;
        align-items: flex-start;
    }
}

/* FAQ questions are headings (WAI-ARIA accordion pattern): the h3 carries the
   outline only, the question keeps its look. */
.sd-faq__q {
  margin: 0;
  font: inherit;
  font-weight: inherit !important;
  letter-spacing: inherit;
  text-transform: none;
  color: inherit;
}
