/* =========================================================================
   faq.css — страница «Часто задаваемые вопросы» (/faq)
   Оформление в духе новой страницы матча (match2.css) и страницы контактов:
   мягкие карточки, токены цветов, аккуратные тени и адаптивная сетка.
   Все правила ограничены .bt-faq, чтобы не задевать остальные страницы.
   ========================================================================= */

.bt-faq {
    --bf-card: #ffffff;
    --bf-ink: #1c2b42;
    --bf-ink-soft: #5d6b81;
    --bf-muted: #8a94a3;
    --bf-line: #e6eaf0;
    --bf-line-soft: #f0f3f8;
    --bf-bg: #f8f9fc;
    --bf-brand: #cc1d14;
    --bf-accent: #ffda33;
    --bf-green: #2f9a4d;
    --bf-blue: #2a5a9f;
    --bf-radius: 18px;
    --bf-radius-sm: 12px;
    --bf-shadow: 0 6px 24px rgba(19, 31, 53, .07);
    --bf-shadow-sm: 0 3px 12px rgba(19, 31, 53, .05);
    width: 100%;
    max-width: 1180px;
    padding-left: 14px;
    padding-right: 14px;
    color: var(--bf-ink);
}

.bt-faq *,
.bt-faq *::before,
.bt-faq *::after {
    box-sizing: border-box;
}

.bt-faq p {
    margin: 0 0 12px;
    color: #33415a;
    line-height: 1.65;
}

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

.bt-faq a {
    color: var(--bf-blue);
}

.bt-faq__inner {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.bt-faq .breadcrumb {
    margin: 6px 0 10px !important;
    padding-left: 0 !important;
}

/* ---------- Первый экран ---------- */
.bt-faq__hero {
    position: relative;
    overflow: hidden;
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(220px, 360px);
    align-items: center;
    gap: 28px;
    padding: 30px 32px;
    border: 1px solid var(--bf-line);
    border-radius: var(--bf-radius);
    background: linear-gradient(135deg, #ffffff 0%, #f7f9fc 58%, #fff8e1 100%);
    box-shadow: var(--bf-shadow);
}

.bt-faq__hero::before,
.bt-faq__hero::after {
    content: "";
    position: absolute;
    border-radius: 50%;
    pointer-events: none;
}

.bt-faq__hero::before {
    width: 240px;
    height: 240px;
    right: -80px;
    top: -110px;
    background: rgba(255, 218, 51, .22);
}

.bt-faq__hero::after {
    width: 180px;
    height: 180px;
    left: -70px;
    bottom: -110px;
    background: rgba(42, 90, 159, .07);
}

.bt-faq__hero-body,
.bt-faq__hero-art {
    position: relative;
    z-index: 1;
}

.bt-faq__eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin: 0 0 12px;
    padding: 5px 12px;
    border-radius: 999px;
    background: #fff3c4;
    color: #6f5500;
    font-size: 11px;
    font-weight: 800;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.bt-faq__eyebrow::before {
    content: "";
    flex: 0 0 auto;
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: var(--bf-green);
    box-shadow: 0 0 0 3px rgba(47, 154, 77, .18);
}

.bt-faq__hero h1 {
    margin: 0 0 10px;
    color: var(--bf-ink);
    font-size: clamp(28px, 4vw, 42px);
    line-height: 1.1;
    font-weight: 850;
    letter-spacing: -.015em;
    text-align: left;
}

.bt-faq__lead {
    max-width: 58ch;
    margin: 0 0 18px !important;
    color: var(--bf-ink-soft);
    font-size: 15px;
    line-height: 1.6;
}

.bt-faq__hero-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
}

.bt-faq__btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 46px;
    padding: 11px 18px;
    border: 1px solid #d7e1f0;
    border-radius: 10px;
    background: #fff;
    color: var(--bf-ink) !important;
    font-size: 14px;
    font-weight: 750;
    line-height: 1.2;
    text-align: center;
    text-decoration: none !important;
    box-shadow: var(--bf-shadow-sm);
    transition: transform .12s ease, box-shadow .15s ease, border-color .15s ease, background .15s ease;
}

.bt-faq__btn:hover {
    transform: translateY(-1px);
    border-color: #c6d4e8;
    box-shadow: 0 6px 16px rgba(19, 31, 53, .1);
}

.bt-faq__btn--primary {
    border-color: var(--bf-brand);
    background: var(--bf-brand);
    color: #fff !important;
    box-shadow: 0 6px 16px rgba(204, 29, 20, .28);
}

.bt-faq__btn--primary:hover {
    border-color: #b41a12;
    background: #b41a12;
    box-shadow: 0 8px 20px rgba(204, 29, 20, .34);
}

.bt-faq__btn:focus-visible,
.bt-faq__chip:focus-visible,
.bt-faq__link:focus-visible,
.bt-faq__toggle-all:focus-visible,
.bt-faq__question:focus-visible {
    outline: 3px solid rgba(42, 90, 159, .35);
    outline-offset: 2px;
}

.bt-faq__hero-art {
    display: flex;
    align-items: center;
    justify-content: center;
}

.bt-faq__hero-art img {
    display: block;
    width: 100%;
    max-width: 360px;
    height: auto;
    margin: 0;
    object-fit: contain;
    filter: drop-shadow(0 12px 24px rgba(19, 31, 53, .12));
}

.bt-faq__hero-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 16px;
}

.bt-faq__meta-pill {
    display: inline-flex;
    align-items: center;
    min-height: 26px;
    padding: 4px 10px;
    border: 1px solid var(--bf-line);
    border-radius: 999px;
    background: rgba(255, 255, 255, .82);
    color: var(--bf-ink-soft);
    font-size: 11px;
    font-weight: 750;
    letter-spacing: .02em;
}

/* ---------- Раскладка ---------- */
.bt-faq__layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(280px, 340px);
    gap: 16px;
    align-items: start;
}

.bt-faq__main {
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

/* ---------- Панель над вопросами ---------- */
.bt-faq__toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    flex-wrap: wrap;
}

.bt-faq__chips {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.bt-faq__chip {
    display: inline-flex;
    align-items: center;
    min-height: 40px;
    padding: 8px 14px;
    border-radius: 999px;
    background: #f1f4f8;
    color: #33415a !important;
    font-size: 13px;
    font-weight: 750;
    line-height: 1.2;
    text-decoration: none !important;
    transition: background .15s ease, color .15s ease;
}

.bt-faq__chip:hover {
    background: #e6ecf5;
    color: var(--bf-ink) !important;
}

.bt-faq__toggle-all {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 40px;
    margin: 0;
    padding: 8px 14px;
    border: 1px solid #d7e1f0;
    border-radius: 10px;
    background: #fff;
    color: var(--bf-blue);
    font-family: inherit;
    font-size: 13px;
    font-weight: 750;
    line-height: 1.2;
    cursor: pointer;
    box-shadow: var(--bf-shadow-sm);
    transition: background .15s ease, border-color .15s ease;
}

.bt-faq__toggle-all:hover {
    border-color: #c6d4e8;
    background: #f8fbff;
}

/* ---------- Группы вопросов ---------- */
.bt-faq__group {
    min-width: 0;
    padding: 22px 24px;
    border: 1px solid var(--bf-line);
    border-radius: var(--bf-radius);
    background: var(--bf-card);
    box-shadow: var(--bf-shadow);
    scroll-margin-top: 120px;
}

.bt-faq__group-head {
    margin-bottom: 8px;
}

.bt-faq__title {
    position: relative;
    margin: 0 0 8px;
    padding-left: 14px;
    color: var(--bf-ink);
    font-size: 21px;
    line-height: 1.25;
    font-weight: 800;
    text-align: left;
}

.bt-faq__title::before {
    content: "";
    position: absolute;
    left: 0;
    top: .18em;
    bottom: .18em;
    width: 4px;
    border-radius: 3px;
    background: linear-gradient(180deg, var(--bf-brand), var(--bf-accent));
}

.bt-faq__subtitle {
    margin: 0 !important;
    color: var(--bf-ink-soft);
    font-size: 14px;
    line-height: 1.6;
}

.bt-faq__items {
    margin-top: 16px;
}

.bt-faq__item {
    border-top: 1px solid var(--bf-line-soft);
    scroll-margin-top: 120px;
}

.bt-faq__item:first-child {
    border-top: 0;
}

.bt-faq__question {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 14px;
    min-height: 56px;
    padding: 16px 4px;
    color: var(--bf-ink);
    font-size: 15.5px;
    font-weight: 750;
    line-height: 1.45;
    list-style: none;
    cursor: pointer;
    transition: color .15s ease;
}

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

.bt-faq__question:hover {
    color: var(--bf-blue);
}

.bt-faq__q-text {
    flex: 1 1 auto;
    min-width: 0;
}

.bt-faq__q-icon {
    position: relative;
    flex: 0 0 28px;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: #f1f4f8;
    transition: background .18s ease, transform .18s ease;
}

.bt-faq__q-icon::before,
.bt-faq__q-icon::after {
    content: "";
    position: absolute;
    left: 50%;
    top: 50%;
    border-radius: 2px;
    background: var(--bf-ink-soft);
    transform: translate(-50%, -50%);
    transition: transform .18s ease, background .18s ease;
}

.bt-faq__q-icon::before {
    width: 12px;
    height: 2px;
}

.bt-faq__q-icon::after {
    width: 2px;
    height: 12px;
}

.bt-faq__item[open] .bt-faq__q-icon {
    background: var(--bf-brand);
    box-shadow: 0 4px 10px rgba(204, 29, 20, .25);
}

.bt-faq__item[open] .bt-faq__q-icon::before,
.bt-faq__item[open] .bt-faq__q-icon::after {
    background: #fff;
}

.bt-faq__item[open] .bt-faq__q-icon::after {
    transform: translate(-50%, -50%) scaleY(0);
}

.bt-faq__answer {
    padding: 0 44px 18px 4px;
    color: #33415a;
    font-size: 14px;
    line-height: 1.7;
}

.bt-faq__answer > :first-child {
    margin-top: 0;
}

.bt-faq__answer > :last-child {
    margin-bottom: 0;
}

.bt-faq__answer p {
    margin: 0 0 10px;
}

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

.bt-faq__answer a {
    color: var(--bf-blue);
    text-decoration: underline;
    text-underline-offset: 2px;
}

.bt-faq__table-wrap {
    width: 100%;
    margin: 12px 0 14px;
    overflow-x: auto;
    border: 1px solid var(--bf-line);
    border-radius: 10px;
    -webkit-overflow-scrolling: touch;
}

.bt-faq__table {
    width: 100%;
    min-width: 320px;
    border-collapse: collapse;
    font-size: 13.5px;
}

.bt-faq__table th {
    padding: 9px 12px;
    border-bottom: 1px solid var(--bf-line);
    background: #f6f8fc;
    color: var(--bf-ink);
    font-size: 11px;
    font-weight: 800;
    letter-spacing: .04em;
    text-align: left;
    text-transform: uppercase;
    white-space: nowrap;
}

.bt-faq__table td {
    padding: 9px 12px;
    border-bottom: 1px solid var(--bf-line-soft);
    color: var(--bf-ink-soft);
    font-variant-numeric: tabular-nums;
}

.bt-faq__table th:last-child,
.bt-faq__table td:last-child {
    text-align: right;
    white-space: nowrap;
}

.bt-faq__table tbody tr:last-child td {
    border-bottom: 0;
}

.bt-faq__table tbody tr:hover td {
    background: #fbfcfe;
}

/* ---------- Боковая колонка ---------- */
.bt-faq__side {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.bt-faq__card {
    min-width: 0;
    padding: 22px 24px;
    border: 1px solid var(--bf-line);
    border-radius: var(--bf-radius);
    background: var(--bf-card);
    box-shadow: var(--bf-shadow);
}

.bt-faq__help {
    background: linear-gradient(145deg, #ffffff 0%, #fff8e1 100%);
}

.bt-faq__help p {
    margin: 0 0 14px;
    color: var(--bf-ink-soft);
    font-size: 13.5px;
    line-height: 1.6;
}

.bt-faq__help-actions {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.bt-faq__help .bt-faq__btn {
    width: 100%;
    min-height: 44px;
}

.bt-faq__hint {
    margin: 12px 0 0 !important;
    color: var(--bf-muted);
    font-size: 12px;
    line-height: 1.45;
}

.bt-faq__links {
    display: grid;
    margin-top: 10px;
}

.bt-faq__link {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding: 11px 2px;
    border-bottom: 1px solid var(--bf-line-soft);
    color: var(--bf-ink) !important;
    font-size: 13.5px;
    font-weight: 650;
    line-height: 1.4;
    text-decoration: none !important;
}

.bt-faq__link:last-child {
    border-bottom: 0;
}

.bt-faq__link span {
    flex: 0 0 auto;
    color: var(--bf-muted);
    font-size: 18px;
    line-height: 1;
    transition: transform .15s ease, color .15s ease;
}

.bt-faq__link:hover span {
    color: var(--bf-blue);
    transform: translateX(3px);
}

/* ---------- Адаптив ---------- */
@media screen and (max-width: 1024px) {
    .bt-faq__hero {
        grid-template-columns: minmax(0, 1fr) minmax(180px, 280px);
        gap: 20px;
        padding: 26px;
    }

    .bt-faq__layout {
        grid-template-columns: minmax(0, 1fr) minmax(260px, 320px);
    }
}

@media screen and (max-width: 900px) {
    .bt-faq__layout {
        grid-template-columns: minmax(0, 1fr);
    }

    .bt-faq__side {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        align-items: start;
    }
}

@media screen and (max-width: 640px) {
    .bt-faq {
        padding-left: 10px;
        padding-right: 10px;
    }

    .bt-faq__inner {
        gap: 12px;
    }

    .bt-faq__hero {
        grid-template-columns: minmax(0, 1fr);
        gap: 14px;
        padding: 20px 18px;
        border-radius: 14px;
    }

    .bt-faq__hero h1 {
        font-size: clamp(26px, 8vw, 34px);
    }

    .bt-faq__lead {
        font-size: 14px;
    }

    .bt-faq__hero-art {
        justify-content: flex-start;
    }

    .bt-faq__hero-art img {
        max-width: 230px;
    }

    .bt-faq__hero-actions {
        align-items: stretch;
    }

    .bt-faq__btn {
        flex: 1 1 auto;
        min-height: 48px;
    }

    .bt-faq__toolbar {
        align-items: stretch;
        flex-direction: column;
    }

    .bt-faq__chips {
        gap: 6px;
    }

    .bt-faq__chip {
        flex: 1 1 auto;
        justify-content: center;
        min-height: 42px;
        padding: 8px 11px;
    }

    .bt-faq__toggle-all {
        width: 100%;
        min-height: 44px;
    }

    .bt-faq__group {
        padding: 17px 15px;
        border-radius: 14px;
    }

    .bt-faq__title {
        font-size: 18px;
    }

    .bt-faq__question {
        padding: 14px 2px;
        font-size: 14.5px;
    }

    .bt-faq__answer {
        padding: 0 36px 16px 2px;
        font-size: 13.5px;
    }

    .bt-faq__table {
        min-width: 300px;
    }

    .bt-faq__side {
        display: flex;
        flex-direction: column;
    }

    .bt-faq__card {
        padding: 18px 15px;
        border-radius: 14px;
    }
}

@media screen and (max-width: 390px) {
    .bt-faq__hero {
        padding: 16px 14px;
    }

    .bt-faq__eyebrow {
        font-size: 10px;
    }

    .bt-faq__question {
        gap: 10px;
        font-size: 14px;
    }

    .bt-faq__q-icon {
        flex-basis: 26px;
        width: 26px;
        height: 26px;
    }

    .bt-faq__answer {
        padding-right: 32px;
    }
}

/* Уважаем системную настройку «меньше движения» */
@media (prefers-reduced-motion: reduce) {
    .bt-faq__btn,
    .bt-faq__chip,
    .bt-faq__toggle-all,
    .bt-faq__question,
    .bt-faq__q-icon,
    .bt-faq__q-icon::before,
    .bt-faq__q-icon::after,
    .bt-faq__link span {
        transition: none !important;
    }
}
