/*
 * BN1 shared My Banya UI
 *
 * Canonical geometry and typography copied from the My Banya component system.
 * This file is the single source of truth for section headings and rail controls
 * used by Homepage V2, What is Banya V2 and Banya Sessions V2 admin previews.
 */

:root {
    --bn1-mybanya-heading-gap: 18px;
    --bn1-mybanya-rule-width: 3px;
    --bn1-mybanya-eyebrow-size: 11px;
    --bn1-mybanya-title-size: clamp(28px, 3vw, 42px);
    --bn1-mybanya-title-line-height: 1.06;
    --bn1-mybanya-title-letter-spacing: -.015em;
    --bn1-mybanya-nav-size: 40px;
    --bn1-mybanya-nav-gap: 14px;
}

.bn1-mybanya-heading-block {
    min-width: 0;
    margin: 0 0 28px;
}

.bn1-mybanya-heading-row {
    display: flex;
    min-width: 0;
    align-items: flex-end;
    justify-content: space-between;
    gap: 30px;
}

.bn1-mybanya-section-heading {
    display: flex;
    min-width: 0;
    align-items: stretch;
    gap: var(--bn1-mybanya-heading-gap);
}

.bn1-mybanya-section-heading .rule {
    width: var(--bn1-mybanya-rule-width);
    flex: 0 0 var(--bn1-mybanya-rule-width);
    border-radius: 2px;
    background: var(--Banya-Brown-300, #bdaf95);
}

/* Exact My Banya eyebrow scale. */
.bn1-mybanya-section-heading .eyebrow {
    margin: 0 0 6px;
    color: var(--Banya-Brown-500, #958464);
    font-family: "Geologica", sans-serif;
    font-size: var(--bn1-mybanya-eyebrow-size) !important;
    font-weight: 500;
    line-height: normal;
    letter-spacing: .16em;
    text-transform: uppercase;
}

/*
 * Exact My Banya h2 scale.
 * !important intentionally prevents older page-specific heading rules from
 * making Homepage / About / Sessions headings different sizes.
 */
.bn1-mybanya-section-heading h2 {
    margin: 0;
    color: var(--Banya-Graphite-800, #4b4b4b);
    font-family: "Jeferson", Georgia, serif;
    font-size: var(--bn1-mybanya-title-size) !important;
    font-weight: 400 !important;
    line-height: var(--bn1-mybanya-title-line-height) !important;
    letter-spacing: var(--bn1-mybanya-title-letter-spacing) !important;
    text-transform: none !important;
}

.bn1-mybanya-heading-description {
    max-width: 760px;
    margin: 18px 0 0 21px;
    color: var(--Banya-Graphite-700, #5e5e5e);
    font-family: "Geologica", sans-serif;
    font-size: 15px;
    font-weight: 300;
    line-height: 1.65;
}

.bn1-mybanya-heading-description p {
    margin: 0;
    color: inherit;
    font: inherit;
}

/* Exact My Banya recommendation rail controls. */
.bn1-mybanya-rail-nav {
    display: flex;
    min-height: var(--bn1-mybanya-nav-size);
    flex: 0 0 auto;
    align-items: center;
    justify-content: flex-end;
    gap: var(--bn1-mybanya-nav-gap);
}

.bn1-mybanya-rail-nav[hidden] {
    display: none !important;
}

.bn1-mybanya-rail-nav button {
    display: grid;
    width: var(--bn1-mybanya-nav-size);
    height: var(--bn1-mybanya-nav-size);
    flex: 0 0 var(--bn1-mybanya-nav-size);
    place-items: center;
    padding: 0;
    border: 1px solid var(--Banya-Brown-300, #bdaf95);
    border-radius: 50%;
    background: var(--Banya-Brown-100, #e4dccf);
    color: var(--Banya-Green-source, #003e37);
    font-family: "Geologica", "Avenir Next", system-ui, sans-serif;
    font-size: 24px;
    font-weight: 400;
    line-height: 1;
    letter-spacing: 0;
    cursor: pointer;
    transition:
        border-color .18s cubic-bezier(.2, .8, .2, 1),
        background .18s cubic-bezier(.2, .8, .2, 1),
        opacity .18s cubic-bezier(.2, .8, .2, 1);
}

.bn1-mybanya-rail-nav button:hover:not(:disabled) {
    border-color: #a9997b;
    background: #d1c5b1;
}

.bn1-mybanya-rail-nav button:disabled {
    cursor: default;
    opacity: .38;
}

.bn1-mybanya-rail-count {
    min-width: 54px;
    margin: 0;
    color: var(--Banya-Graphite-700, #5e5e5e);
    font-family: "Geologica", sans-serif;
    font-size: 13px;
    font-weight: 500;
    line-height: 1.2;
    letter-spacing: 0;
    text-align: center;
    text-transform: none;
    white-space: nowrap;
}

.bn1-mybanya-swipe-hint {
    display: none;
    color: var(--Banya-Green-800, #27534c);
    font-family: "Geologica", sans-serif;
    font-size: 10px;
    font-weight: 500;
    line-height: 1.2;
    letter-spacing: .08em;
    text-transform: uppercase;
}

/* Dark sections keep identical geometry; only contrast changes. */
.bn1-mybanya-heading-row--dark .bn1-mybanya-section-heading h2,
.bn1-v2-section--dark .bn1-mybanya-section-heading h2,
.bn1-about-v2__experience-cycle .bn1-mybanya-section-heading h2 {
    color: var(--Banya-Brown-50, #f6f3ef);
}

.bn1-mybanya-heading-row--dark .bn1-mybanya-heading-description,
.bn1-v2-section--dark .bn1-mybanya-heading-description,
.bn1-about-v2__experience-cycle .bn1-mybanya-heading-description {
    color: var(--Banya-Brown-100, #e4dccf);
}

.bn1-mybanya-heading-row--dark .bn1-mybanya-rail-count,
.bn1-v2-section--dark .bn1-mybanya-rail-count {
    color: var(--Banya-Brown-100, #e4dccf);
}

/* Homepage preview: neutralise old two-column heading geometry. */
.bn1-home-v2 .bn1-v2-section-head.bn1-mybanya-heading-block {
    display: block;
    margin-bottom: 28px;
}

.bn1-home-v2 .bn1-v2-section-head.bn1-mybanya-heading-block .bn1-mybanya-heading-description {
    max-width: 760px;
}

.bn1-home-v2 .bn1-v2-facility-group__actions {
    display: grid;
    align-self: stretch;
    align-content: end;
    justify-items: end;
    gap: 16px;
}

.bn1-home-v2 .bn1-v2-facility-group__actions .bn1-mybanya-rail-nav {
    margin: 0;
}

/* What is Banya preview. */
.bn1-about-v2 .bn1-mybanya-heading-block {
    max-width: none;
}

.bn1-about-v2 .bn1-mybanya-heading-block + .bn1-about-v2__scroller,
.bn1-about-v2 .bn1-mybanya-heading-block + .bn1-about-v2__benefits-presentation {
    margin-top: 0;
}

/* Banya Sessions: same heading spacing as the canonical component. */
.bn1-sessions-v2 .bn1-sessions-v2__heading.bn1-mybanya-heading-block {
    max-width: none;
    margin-bottom: 28px;
}

.bn1-sessions-v2 .bn1-sessions-v2__library-rail::part(navigation) {
    display: none;
}

/*
 * My Banya mobile behaviour: title size is NOT redefined.
 * The canonical clamp therefore resolves to 28px on normal mobile widths.
 */
@media (max-width: 760px) {
    .bn1-mybanya-heading-block {
        margin-bottom: 28px;
    }

    .bn1-mybanya-heading-row {
        align-items: stretch;
        flex-direction: column;
        gap: 0;
    }

    .bn1-mybanya-section-heading {
        gap: var(--bn1-mybanya-heading-gap);
        margin-bottom: 16px;
    }

    .bn1-mybanya-heading-description {
        margin: 14px 0 0 21px;
        font-size: 14px;
        line-height: 1.6;
    }

    .bn1-mybanya-rail-nav {
        width: 100%;
        margin: 0;
    }

    .bn1-mybanya-swipe-hint {
        display: inline;
        margin-right: auto;
    }

    .bn1-home-v2 .bn1-v2-facility-group__intro {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .bn1-home-v2 .bn1-v2-facility-group__actions {
        width: 100%;
        justify-items: stretch;
    }

    .bn1-home-v2 .bn1-v2-facility-group__actions .bn1-mybanya-rail-nav {
        justify-self: stretch;
    }
}

/* My Banya rails: no edge fades and no visible scrollbars. */
.bn1-home-v2 [data-bn1-v2-scroll] .bn1-v2-card-track,
.bn1-about-v2 [data-bn1-about-track] {
    -webkit-mask-image: none !important;
    mask-image: none !important;
    scrollbar-width: none;
}

.bn1-home-v2 [data-bn1-v2-scroll] .bn1-v2-card-track::-webkit-scrollbar,
.bn1-about-v2 [data-bn1-about-track]::-webkit-scrollbar {
    display: none;
}

/* Shared hero body-copy typography: Homepage + What is Banya. */
.bn1-v2-hero__copy,
.bn1-v2-hero__copy p {
    font-size: 20px !important;
    line-height: 1.55 !important;
}

@media (max-width: 767px) {
    .bn1-v2-hero__copy,
    .bn1-v2-hero__copy p {
        font-size: 17px !important;
    }
}
