/* ================================================================
   Fluorite B2B — дизайн-система v10 «SHOWROOM» (чистый пересбор).
   Канон: светлое молочно-серое полотно, белые карты с мягкой тенью,
   графитовый сайдбар (мост от тёмного логина), ЧЁРНЫЕ primary-кнопки,
   один тёплый акцент #FDCF00 (полосы/точки/gauge — не текст),
   фото товаров живут в тёмных «витринных» колодцах (хрусталь снят
   на чёрном). Радиусы: панели 14 / контролы 10 / чипы pill.
   Логин-секции перенесены из v5 без изменений (в конце файла).
   ================================================================ */

/* ---------- шрифты (self-host) ---------- */

@font-face {
    font-family: 'Montserrat';
    src: url('../fonts/montserrat-cyr.woff2') format('woff2');
    font-weight: 300 800;
    font-display: swap;
    unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
    font-family: 'Montserrat';
    src: url('../fonts/montserrat-lat.woff2') format('woff2');
    font-weight: 300 800;
    font-display: swap;
    unicode-range: U+0000-00FF, U+2000-206F, U+20AC, U+2122, U+20BD;
}
@font-face {
    font-family: 'JB Mono';
    src: url('../fonts/jbm-cyr.woff2') format('woff2');
    font-weight: 100 800;
    font-display: swap;
    unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
    font-family: 'JB Mono';
    src: url('../fonts/jbm-lat.woff2') format('woff2');
    font-weight: 100 800;
    font-display: swap;
    unicode-range: U+0000-00FF, U+2000-206F, U+20AC, U+2122, U+20BD;
}

/* ---------- токены ---------- */

:root {
    --font: 'Montserrat', -apple-system, 'Segoe UI', sans-serif;
    --hud: 'Montserrat', -apple-system, 'Segoe UI', sans-serif;
    --mono: 'JB Mono', ui-monospace, Consolas, monospace;

    /* --bg — легаси-токен логина (тёмный), интерьер использует --bg-day */
    --bg: #050506;
    --bg-day: #F2F3F5;

    --surface: #FFFFFF;
    --night: #0F1013;        /* сайдбар, primary-кнопки, фото-колодцы */
    --night-2: #1B1C21;

    --ink: #16171A;
    --ink-2: #494C52;
    --ink-3: #6C7077;
    --line: #E8E9EC;         /* хэйрлайны */
    --line-strong: #D9DBDF;  /* границы контролов */

    --warm-y: #FDCF00;
    --warm-o: #F08C2D;
    --warm-r: #E03E3E;
    --ok-g: #1F9D61;
    /* текстовые варианты семантики (контраст на белом) */
    --ok-t: #12784A;
    --warn-t: #9A5B00;
    --err-t: #C2333E;

    --r-panel: 14px;
    --r-ctl: 10px;
    --r-badge: 999px;

    --shadow: 0 1px 2px rgba(16, 17, 20, .05), 0 10px 30px -14px rgba(16, 17, 20, .12);
    --shadow-lift: 0 2px 4px rgba(16, 17, 20, .05), 0 18px 44px -16px rgba(16, 17, 20, .18);

    --ez: cubic-bezier(.2, .7, .2, 1);
    --ez-hud: cubic-bezier(.2, .7, .2, 1);
}

* { box-sizing: border-box; }

/* ---------- сцена ---------- */

.b2b-body {
    margin: 0;
    background: var(--bg-day);
    color: var(--ink);
    font: 400 14px/1.55 var(--font);
    -webkit-font-smoothing: antialiased;
}
::selection { background: #16171A; color: #fff; }

/* зерно: тонкий шум снимает пластиковую плоскость светлого поля */
.b2b-body::after {
    content: ""; position: fixed; inset: 0; z-index: 0; pointer-events: none; opacity: .028;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='140' height='140'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='2'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

.b2b-muted { color: var(--ink-3); }

/* ambient-блобы: еле заметное тёплое дыхание фона (двигает GSAP) */
.b2b-blob {
    position: fixed; border-radius: 50%; pointer-events: none; z-index: 0;
    filter: blur(60px); will-change: transform;
}
.b2b-blob--a { top: -160px; right: 8%; width: 640px; height: 640px; background: radial-gradient(circle, rgba(253, 207, 0, .09) 0%, transparent 62%); }
.b2b-blob--b { bottom: -240px; left: 30%; width: 720px; height: 720px; background: radial-gradient(circle, rgba(16, 17, 20, .05) 0%, transparent 62%); }
.b2b-blob--c { top: 34%; left: 12%; width: 460px; height: 460px; background: radial-gradient(circle, rgba(253, 207, 0, .06) 0%, transparent 62%); }
.b2b-app, .b2b-minimal-wrap { position: relative; z-index: 1; }

/* ---------- каркас: сайдбар + контент ---------- */

.b2b-app { min-height: 100dvh; }
.b2b-app--side { display: flex; align-items: stretch; flex-direction: row; }

.b2b-side {
    position: sticky; top: 0; align-self: flex-start;
    width: 248px; flex-shrink: 0; height: 100dvh;
    display: flex; flex-direction: column;
    background: linear-gradient(180deg, #131418 0%, var(--night) 30%);
    padding: 26px 14px 18px;
    z-index: 30;
}

.b2b-side__logo {
    display: block; text-decoration: none; padding: 0 12px 18px; margin-bottom: 10px;
    border-bottom: 1px solid rgba(255, 255, 255, .1);
    font: 700 15px/1 var(--font); letter-spacing: .06em; color: #fff;
}
.b2b-side__logo span { color: var(--warm-y); margin-left: 5px; }
.b2b-side__logo em {
    display: block; font: 600 9.5px/1 var(--font); font-style: normal;
    letter-spacing: .16em; color: rgba(255, 255, 255, .45); margin-top: 8px;
}

.b2b-side__nav { display: flex; flex-direction: column; gap: 3px; flex: 1; overflow-y: auto; padding-top: 8px; }
.b2b-side__link {
    display: flex; align-items: center; gap: 12px;
    padding: 10px 12px; border-radius: var(--r-ctl); text-decoration: none;
    font: 500 13px/1.2 var(--font); color: rgba(255, 255, 255, .72);
    transition: background .2s var(--ez), color .2s var(--ez);
}
.b2b-side__link svg { width: 17px; height: 17px; flex-shrink: 0; opacity: .7; }
.b2b-side__link:hover { background: rgba(255, 255, 255, .07); color: #fff; }
.b2b-side__link.is-current {
    background: var(--surface); color: var(--ink); font-weight: 600;
    box-shadow: 0 8px 20px -8px rgba(0, 0, 0, .6);
}
.b2b-side__link.is-current svg { opacity: 1; }
.b2b-side__count {
    margin-left: auto; background: var(--warm-y); color: #16171A;
    border-radius: var(--r-badge); padding: 3px 8px; font: 700 10.5px/1 var(--font);
}
.b2b-side__link.is-current .b2b-side__count { background: #16171A; color: #fff; }

.b2b-side__bottom { display: flex; flex-direction: column; gap: 12px; padding-top: 16px; border-top: 1px solid rgba(255, 255, 255, .1); }
.b2b-side__cta { text-align: center; }
.b2b-side__status { display: inline-flex; align-items: center; gap: 8px; justify-content: center; }
.b2b-side__status span, .b2b-side__status b { font: 500 11px/1 var(--font); color: rgba(255, 255, 255, .45); }
.b2b-side__status b { color: rgba(255, 255, 255, .75); font-weight: 600; }
.b2b-hud-status { display: inline-flex; align-items: center; gap: 8px; }
.b2b-hud-status span, .b2b-hud-status b { font: 500 11.5px/1 var(--font); color: var(--ink-3); }
.b2b-hud-status b { color: var(--ink-2); }
.b2b-hud-status__dot { width: 8px; height: 8px; border-radius: 50%; background: var(--ok-g); }

.b2b-wrap { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.b2b-top { position: relative; z-index: 5; }
.b2b-top__inner { max-width: none; padding: 16px 28px 0; display: flex; align-items: center; gap: 14px; }
.b2b-top__user { margin-left: auto; display: flex; align-items: center; gap: 14px; white-space: nowrap; }
.b2b-top__company { font: 500 12.5px/1.3 var(--font); color: var(--ink-3); max-width: 260px; overflow: hidden; text-overflow: ellipsis; }
.b2b-top__logout { font: 500 12.5px/1 var(--font); color: var(--ink-3); text-decoration: none; }
.b2b-top__logout:hover { color: var(--ink); }
.b2b-top__burger {
    display: none; background: var(--surface); border: 1px solid var(--line-strong); border-radius: var(--r-ctl);
    cursor: pointer; font-size: 18px; color: var(--ink); padding: 6px 12px;
}

.b2b-le-switch { display: inline-flex; }
.b2b-le-switch__select {
    max-width: 210px; height: 36px; padding: 0 26px 0 12px;
    font: 500 12.5px/1 var(--font); color: var(--ink);
    background: var(--surface); border: 1px solid var(--line-strong); border-radius: var(--r-ctl);
    cursor: pointer; text-overflow: ellipsis;
}
.b2b-le-switch__select option { color: var(--ink); background: #fff; }
.b2b-le-switch__select:focus { outline: none; border-color: var(--ink); }

.b2b-main { flex: 1 1 auto; width: 100%; max-width: none; padding: 18px 28px 56px; }
.b2b-page-title {
    margin: 8px 0 22px; padding-bottom: 14px;
    border-bottom: 1px solid var(--line-strong);
    font: 650 26px/1.2 var(--font); letter-spacing: -.015em; text-wrap: balance;
}
.b2b-foot { margin-top: auto; border-top: 1px solid var(--line); color: var(--ink-3); font-size: 12px; padding: 16px 28px 28px; }
.b2b-foot__inner { max-width: none; margin: 0; }

@media (max-width: 1023px) {
    .b2b-side {
        position: fixed; left: 0; top: 0; transform: translateX(-102%);
        transition: transform .3s var(--ez);
        box-shadow: 24px 0 80px rgba(0, 0, 0, .35);
    }
    .b2b-side.is-open { transform: translateX(0); }
    .b2b-top__burger { display: block; }
    .b2b-top__inner { padding: 12px 16px 0; }
    .b2b-main { padding: 14px 16px 44px; }
    .b2b-top__company { display: none; }
}

/* ---------- панели: белые карты, мягкая тень, r14 ---------- */

.b2b-card, .b2b-kpi {
    position: relative;
    background: var(--surface);
    border: 1px solid var(--line); border-radius: var(--r-panel);
    box-shadow: var(--shadow);
}
.b2b-card { padding: 22px 24px; margin-bottom: 16px; }
.b2b-card__title { margin: 0 0 14px; font: 600 15px/1.3 var(--font); color: var(--ink); }

.b2b-kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(168px, 1fr)); gap: 14px; margin-bottom: 16px; }
.b2b-kpi { padding: 20px 22px; transition: transform .25s var(--ez), box-shadow .25s var(--ez); }
.b2b-kpi:hover { transform: translateY(-3px); box-shadow: var(--shadow-lift); }
.b2b-kpi__label { font: 500 12px/1.3 var(--font); color: var(--ink-3); }
.b2b-kpi__value { margin-top: 8px; font: 600 clamp(20px, 1.6vw, 26px)/1.15 var(--font); letter-spacing: -.01em; color: var(--ink); font-variant-numeric: tabular-nums; white-space: nowrap; }
.b2b-kpi__value small { font-size: 13px; font-weight: 500; color: var(--ink-3); }
/* акцентная плита — графит с белыми цифрами (контраст-панель бенто) */
.b2b-kpi--accent { background: var(--night); border-color: var(--night); }
.b2b-kpi--accent .b2b-kpi__label { color: rgba(255, 255, 255, .55); }
.b2b-kpi--accent .b2b-kpi__value { color: #fff; }
.b2b-kpi--accent .b2b-kpi__value small { color: rgba(255, 255, 255, .55); }
.b2b-kpi--accent .b2b-hud-delta { color: rgba(255, 255, 255, .7); }
.b2b-hud-delta { font: 500 12px/1.3 var(--font); color: var(--ink-2); margin-top: 10px; }

.b2b-grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-bottom: 16px; }
@media (max-width: 900px) { .b2b-grid-2 { grid-template-columns: 1fr; } }

/* ---------- кнопки: primary — графит ---------- */

.b2b-btn {
    display: inline-block; cursor: pointer; text-decoration: none;
    padding: 12px 24px; border-radius: var(--r-ctl);
    font: 600 13px/1.2 var(--font);
    background: var(--night); color: #fff; border: 0;
    transition: background .2s var(--ez), transform .12s var(--ez), box-shadow .2s var(--ez);
}
.b2b-btn:hover { background: var(--night-2); box-shadow: 0 10px 24px -10px rgba(16, 17, 20, .45); }
.b2b-btn:active { transform: translateY(1px); }
.b2b-btn:focus-visible { outline: 2px solid var(--ink); outline-offset: 2px; }
.b2b-btn--ghost { background: var(--surface); color: var(--ink); border: 1px solid var(--line-strong); padding: 11px 23px; }
.b2b-btn--ghost:hover { background: #F5F6F8; border-color: var(--ink-3); box-shadow: none; }
.b2b-btn--danger { background: var(--warm-r); color: #fff; }
.b2b-btn--danger:hover { background: #C93434; box-shadow: none; }
.b2b-btn--sm { padding: 8px 16px; font-size: 12px; }
.b2b-main a.b2b-btn, .b2b-main a.b2b-btn:visited { color: #fff; text-decoration: none; }
.b2b-main a.b2b-btn--ghost, .b2b-main a.b2b-btn--ghost:visited { color: var(--ink); }
.b2b-main a.b2b-btn--danger, .b2b-main a.b2b-btn--danger:visited { color: #fff; }

/* CTA в тёмном сайдбаре — белая, инверсия primary */
.b2b-side__cta, .b2b-side__cta:hover { background: #fff; color: #16171A; }
.b2b-side__cta:hover { background: #ECEDEF; box-shadow: 0 10px 30px -10px rgba(0, 0, 0, .55); }

/* ---------- чипы-фильтры: сегмент-группа, активный — графит ---------- */

.b2b-feature-pills { display: inline-flex; gap: 0; margin-bottom: 20px; background: var(--surface); border: 1px solid var(--line-strong); border-radius: var(--r-ctl); overflow: hidden; flex-wrap: wrap; }
.b2b-feature-pills__pill {
    padding: 10px 18px; border-right: 1px solid var(--line);
    font: 500 12.5px/1.2 var(--font); color: var(--ink-2); text-decoration: none;
    transition: background .15s var(--ez), color .15s var(--ez);
}
.b2b-feature-pills__pill:last-child { border-right: 0; }
.b2b-feature-pills__pill:hover { color: var(--ink); background: #F3F4F6; }
.b2b-feature-pills__pill.is-current { background: var(--night); color: #fff; font-weight: 600; }

.b2b-brand-tabs { display: flex; gap: 0; margin-bottom: 16px; background: var(--surface); border: 1px solid var(--line-strong); border-radius: var(--r-ctl); overflow: hidden; width: max-content; }
.b2b-brand-tabs__tab {
    padding: 10px 18px; border-right: 1px solid var(--line);
    font: 500 12.5px/1.2 var(--font); color: var(--ink-2); text-decoration: none;
}
.b2b-brand-tabs__tab:last-child { border-right: 0; }
.b2b-brand-tabs__tab:hover { color: var(--ink); background: #F3F4F6; }
.b2b-brand-tabs__tab.is-current { background: var(--night); color: #fff; font-weight: 600; }
.b2b-brand-tabs__tab span { margin-left: 7px; font: 600 10.5px/1 var(--mono); opacity: .55; }

/* ---------- статус-бейджи: точка + светлый чип-пилюля ---------- */

.b2b-badge {
    display: inline-flex; align-items: center; gap: 6px;
    font: 500 11.5px/1.4 var(--font); color: var(--ink-2);
    background: #F1F2F4; border-radius: var(--r-badge); padding: 5px 12px 5px 10px;
    white-space: nowrap;
}
.b2b-badge::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: var(--ink-3); flex-shrink: 0; }
.b2b-badge--new::before, .b2b-badge--q-open::before { background: var(--warm-y); }
.b2b-badge--confirmed::before, .b2b-badge--invoiced::before,
.b2b-badge--review::before, .b2b-badge--q-answered::before,
.b2b-badge--inv-partially_paid::before { background: var(--warm-o); }
.b2b-badge--shipped::before, .b2b-badge--done::before, .b2b-badge--accepted::before,
.b2b-badge--resolved::before, .b2b-badge--inv-paid::before, .b2b-badge--q-ordered::before { background: var(--ok-g); }
.b2b-badge--cancelled::before, .b2b-badge--rejected::before,
.b2b-badge--inv-overdue::before, .b2b-badge--q-declined::before { background: var(--warm-r); }

/* флаги каталога — на тёмном фото-колодце */
.b2b-flag { position: absolute; z-index: 2; top: 10px; left: 10px; display: flex; gap: 5px; }
.b2b-flag span { padding: 3px 10px; border-radius: var(--r-badge); font: 600 10.5px/1.4 var(--font); text-transform: lowercase; }
.b2b-flag__new { background: #fff; color: #16171A; }
.b2b-flag__sale { background: var(--warm-y); color: #16171A; }
.b2b-flag__liq { background: var(--warm-r); color: #fff; }

/* транзит и склад */
.b2b-transit-note {
    display: inline-block; font: 600 11px/1.5 var(--font); color: #6B4E00;
    background: #FFF1BE; padding: 2px 10px; border-radius: var(--r-badge); white-space: nowrap;
}
.b2b-stock { font: 600 12px/1.4 var(--mono); }
.b2b-stock--ok { color: var(--ok-t); }
.b2b-stock--low { color: var(--warn-t); }
.b2b-stock--out { color: var(--err-t); }

/* ---------- алерты ---------- */

.b2b-alert { padding: 12px 16px; margin-bottom: 16px; border-radius: var(--r-ctl); border-left: 3px solid var(--line-strong); background: var(--surface); box-shadow: var(--shadow); font-size: 13.5px; }
.b2b-alert--ok { border-left-color: var(--ok-g); background: #F0FAF4; box-shadow: none; }
.b2b-alert--info { border-left-color: var(--warm-y); background: #FFFAE8; box-shadow: none; }
.b2b-alert--err { border-left-color: var(--warm-r); background: #FDF0F0; box-shadow: none; }

/* ---------- инпуты ---------- */

.b2b-field { margin-bottom: 14px; }
.b2b-field label { display: block; margin-bottom: 7px; font: 500 11.5px/1.3 var(--font); color: var(--ink-3); }
.b2b-input, .b2b-select, .b2b-textarea {
    width: 100%; padding: 10px 14px; border-radius: var(--r-ctl);
    background: var(--surface); border: 1px solid var(--line-strong);
    font: 400 13.5px/1.4 var(--font); color: var(--ink);
    transition: border-color .18s var(--ez), box-shadow .18s var(--ez);
}
.b2b-input::placeholder, .b2b-textarea::placeholder { color: #9AA0A8; }
.b2b-input:hover, .b2b-select:hover, .b2b-textarea:hover { border-color: var(--ink-3); }
.b2b-input:focus, .b2b-select:focus, .b2b-textarea:focus { outline: none; border-color: var(--ink); box-shadow: 0 0 0 3px rgba(16, 17, 20, .08); }
.b2b-select option { color: var(--ink); background: #fff; }
.b2b-textarea { min-height: 90px; resize: vertical; }
.b2b-input:-webkit-autofill { -webkit-box-shadow: 0 0 0 60px #fff inset; -webkit-text-fill-color: var(--ink); caret-color: var(--ink); }

.b2b-filter-row { display: flex; gap: 14px; align-items: flex-end; flex-wrap: wrap; }
.b2b-filter-row .b2b-field { margin-bottom: 0; }

.b2b-searchpill { position: relative; }
.b2b-searchpill input {
    width: 100%; height: 46px; padding: 0 46px 0 20px; border-radius: var(--r-ctl);
    background: var(--surface); border: 1px solid var(--line-strong);
    font: 400 13.5px/1 var(--font); color: var(--ink);
    box-shadow: var(--shadow);
    transition: border-color .18s var(--ez), box-shadow .18s var(--ez);
}
.b2b-searchpill input::placeholder { color: #9AA0A8; font-weight: 500; font-size: 12.5px; }
.b2b-searchpill input:focus { outline: none; border-color: var(--ink); box-shadow: 0 0 0 3px rgba(16, 17, 20, .08); }
.b2b-searchpill__icon { position: absolute; right: 18px; top: 50%; transform: translateY(-50%); width: 16px; height: 16px; color: var(--ink-3); pointer-events: none; }

/* саджест быстрого заказа */
.b2b-suggest {
    position: absolute; left: 0; right: 0; top: calc(100% + 6px); z-index: 60;
    background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-ctl);
    box-shadow: var(--shadow-lift);
    max-height: 340px; overflow-y: auto; display: none;
}
.b2b-suggest.is-open { display: block; }
.b2b-suggest__item { display: flex; align-items: center; gap: 12px; padding: 10px 14px; cursor: pointer; border-bottom: 1px solid var(--line); }
.b2b-suggest__item:hover { background: #F5F6F8; }
.b2b-suggest__img { width: 38px; height: 38px; object-fit: cover; background: var(--night); border-radius: 8px; flex-shrink: 0; }
.b2b-suggest__name { font: 500 13px/1.3 var(--font); color: var(--ink); }
.b2b-suggest__meta { font: 400 11.5px/1.3 var(--font); color: var(--ink-3); }
.b2b-suggest__price { margin-left: auto; font: 600 13px/1 var(--font); color: var(--ink); white-space: nowrap; }

/* ---------- таблицы ---------- */

.b2b-table-wrap { overflow-x: auto; }
.b2b-table { width: 100%; border-collapse: collapse; font-family: var(--font); }
.b2b-table thead th {
    text-align: left; padding: 6px 12px 12px;
    font: 600 11.5px/1.3 var(--font); color: var(--ink-3);
    border-bottom: 1px solid var(--line-strong);
    white-space: nowrap;
}
.b2b-table tbody td { padding: 14px 12px; border-bottom: 1px solid var(--line); vertical-align: middle; font-size: 13.5px; }
.b2b-table tbody tr:hover td { background: #FAFAFB; }
.b2b-table tfoot td { padding: 14px 12px; border-top: 2px solid var(--ink); font-weight: 600; }
.b2b-table .num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
.b2b-table a { color: var(--ink); }
.b2b-thumb { width: 44px; height: 44px; object-fit: cover; background: var(--night); border-radius: 8px; display: block; }

/* количество +/- */
.b2b-qty { display: inline-flex; align-items: stretch; border: 1px solid var(--line-strong); border-radius: var(--r-ctl); overflow: hidden; background: var(--surface); }
.b2b-qty button { width: 30px; background: transparent; border: 0; color: var(--ink); cursor: pointer; font-size: 15px; }
.b2b-qty button:hover { background: #F3F4F6; }
.b2b-qty input { width: 46px; text-align: center; background: transparent; border: 0; color: var(--ink); font: 500 13px/1 var(--font); }
.b2b-qty input:focus { outline: none; }

/* ---------- пейджер ---------- */

.b2b-pager { display: flex; gap: 0; margin: 20px 0 0; background: var(--surface); border: 1px solid var(--line-strong); border-radius: var(--r-ctl); overflow: hidden; width: max-content; }
.b2b-pager__btn {
    padding: 8px 14px; border-right: 1px solid var(--line);
    font: 500 12.5px/1.2 var(--font); color: var(--ink-2); text-decoration: none;
}
.b2b-pager__btn:last-child { border-right: 0; }
.b2b-pager__btn:hover { background: #F3F4F6; color: var(--ink); }
.b2b-pager__btn.is-current { background: var(--night); color: #fff; font-weight: 600; }
.b2b-pager__gap { padding: 8px 10px; color: var(--ink-3); }

/* ---------- каталог ---------- */

.b2b-catalog-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 16px; }
.b2b-catalog-grid--related { grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); }
.b2b-product-card {
    position: relative; display: flex; flex-direction: column;
    background: var(--surface);
    border: 1px solid var(--line); border-radius: var(--r-panel); overflow: hidden;
    box-shadow: var(--shadow);
    transition: transform .25s var(--ez), box-shadow .25s var(--ez);
}
.b2b-product-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lift); }
/* фото-колодец: хрусталь снят на чёрном — чёрным и остаётся */
.b2b-product-card__img { position: relative; aspect-ratio: 1; background: var(--night); display: flex; align-items: center; justify-content: center; min-height: 120px; }
.b2b-product-card__img img { width: 100%; height: 100%; object-fit: cover; }
.b2b-product-card__img:empty::after, .b2b-product-card__img--none::after,
.b2b-product-card__img:not(:has(img))::after { content: "без фото"; font: 500 11px/1 var(--font); color: rgba(255, 255, 255, .38); }
.b2b-product-card__body { display: flex; flex-direction: column; gap: 7px; padding: 14px 16px 16px; flex: 1; }
.b2b-product-card__name { font: 600 13.5px/1.35 var(--font); }
.b2b-product-card__name a { color: var(--ink); text-decoration: none; }
.b2b-product-card__name a:hover { text-decoration: underline; }
.b2b-product-card__meta { font: 500 11.5px/1.4 var(--font); color: var(--ink-3); }
.b2b-product-card__prices { display: flex; align-items: baseline; gap: 10px; }
.b2b-product-card__prices b { font: 600 16px/1.2 var(--font); font-variant-numeric: tabular-nums; }
.b2b-product-card__prices span { font-size: 12px; color: var(--ink-3); text-decoration: line-through; }
.b2b-product-card__footer { margin-top: auto; display: flex; align-items: center; justify-content: space-between; gap: 8px; flex-wrap: wrap; row-gap: 6px; }
.b2b-product-card__buy { display: inline-flex; gap: 6px; }
.b2b-product-card__buy .b2b-input { width: 54px; padding: 6px; text-align: center; font: 500 13px/1.2 var(--font); }

/* ---------- карточка товара ---------- */

.b2b-product-page { display: grid; grid-template-columns: minmax(300px, 480px) 1fr; gap: 18px; margin-bottom: 18px; }
@media (max-width: 900px) { .b2b-product-page { grid-template-columns: 1fr; } }
.b2b-product-page__photo { display: flex; align-items: center; justify-content: center; background: var(--night); border-radius: var(--r-panel); overflow: hidden; }
.b2b-product-page__photo img { max-width: 100%; max-height: 460px; object-fit: contain; }
.b2b-product-page__article { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.b2b-copy {
    display: inline-flex; align-items: center; gap: 7px; position: relative;
    background: var(--surface); border: 1px solid var(--line-strong); border-radius: var(--r-ctl);
    padding: 6px 11px; cursor: pointer; transition: border-color .15s var(--ez);
}
.b2b-copy:hover { border-color: var(--ink); }
.b2b-copy__code { font: 650 13.5px/1 var(--mono); color: var(--ink); letter-spacing: .02em; }
.b2b-copy svg { width: 15px; height: 15px; color: var(--ink-3); }
.b2b-copy__done {
    position: absolute; left: 50%; top: -30px; transform: translateX(-50%) translateY(4px);
    background: var(--night); color: #fff; font: 500 11.5px/1 var(--font); font-style: normal;
    padding: 5px 9px; border-radius: 7px; opacity: 0; pointer-events: none;
    transition: opacity .18s var(--ez), transform .18s var(--ez); white-space: nowrap;
}
.b2b-copy.is-copied .b2b-copy__done { opacity: 1; transform: translateX(-50%) translateY(0); }
.b2b-product-page__prices { display: flex; flex-direction: column; gap: 6px; margin: 18px 0 14px; }
.b2b-product-page__price { display: flex; justify-content: space-between; align-items: baseline; gap: 16px; max-width: 420px; }
.b2b-product-page__price span { font-size: 13px; color: var(--ink-2); }
.b2b-product-page__price b { font: 600 24px/1.1 var(--font); letter-spacing: -.01em; font-variant-numeric: tabular-nums; }
.b2b-product-page__price--muted b { font-size: 15.5px; font-weight: 500; color: var(--ink-3); }
.b2b-product-page__stock { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-bottom: 16px; }
.b2b-product-page__buy { display: flex; align-items: center; gap: 12px; margin-bottom: 10px; }
.b2b-table--props td { padding-top: 8px; padding-bottom: 8px; }

/* ---------- витрины: тёмные фото-полотна ---------- */

.b2b-showcase { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; margin-bottom: 22px; }
@media (max-width: 900px) { .b2b-showcase { grid-template-columns: 1fr; } }
.b2b-showcase--n2 { grid-template-columns: repeat(2, 1fr); }
.b2b-showcase--n1 { grid-template-columns: 1fr; }
.b2b-showtile {
    position: relative; display: block; overflow: hidden;
    aspect-ratio: 5 / 4; border-radius: var(--r-panel); text-decoration: none;
    background: var(--night); box-shadow: var(--shadow);
    transition: transform .3s var(--ez), box-shadow .3s var(--ez);
}
.b2b-showtile:hover { transform: translateY(-3px); box-shadow: var(--shadow-lift); }
.b2b-showtile__img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.b2b-showtile::after {
    content: ""; position: absolute; inset: 0; pointer-events: none;
    background: linear-gradient(180deg, transparent 55%, rgba(0, 0, 0, .78) 100%);
}
.b2b-showtile__meta { position: absolute; z-index: 2; left: 20px; right: 20px; bottom: 18px; display: flex; flex-direction: column; gap: 4px; }
.b2b-showtile__title { font: 600 20px/1.1 var(--font); color: #fff; }
.b2b-showtile__count { font: 500 12px/1 var(--font); color: rgba(255, 255, 255, .6); }
.b2b-showtile__cta {
    margin-top: 6px; font: 500 12.5px/1 var(--font); color: #fff;
    display: inline-flex; align-items: center; gap: 6px;
    opacity: 0; transform: translateY(4px);
    transition: opacity .3s var(--ez), transform .3s var(--ez);
}
.b2b-showtile__cta svg { width: 15px; height: 15px; }
.b2b-showtile:hover .b2b-showtile__cta { opacity: 1; transform: translateY(0); }
@media (hover: none) { .b2b-showtile__cta { opacity: 1; transform: none; } }
.b2b-showtile--empty-img { display: flex; align-items: center; justify-content: center; color: rgba(255, 255, 255, .4); }

/* ---------- Celoxis-компоненты дашборда ---------- */

.b2b-dotstat { display: flex; flex-direction: column; gap: 4px; }
.b2b-dotstat__num { font: 600 26px/1.1 var(--font); color: var(--ink); font-variant-numeric: tabular-nums; }
.b2b-dotstat__label { display: flex; align-items: center; gap: 6px; font: 500 11.5px/1.2 var(--font); color: var(--ink-2); }
.b2b-dotstat__label::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: var(--dot, var(--ink-3)); }

.b2b-warmbar { margin-top: 8px; }
.b2b-warmbar__head { display: flex; justify-content: space-between; align-items: baseline; }
.b2b-warmbar__val { font: 600 20px/1.2 var(--font); color: var(--ink); font-variant-numeric: tabular-nums; }
.b2b-warmbar__note { font: 500 11px/1.2 var(--font); color: var(--ink-3); }
.b2b-warmbar__track { height: 6px; border-radius: var(--r-badge); background: #ECEDEF; margin-top: 8px; overflow: hidden; }
.b2b-warmbar__fill { height: 100%; border-radius: var(--r-badge); }

.b2b-gauge { position: relative; width: 210px; margin: 0 auto; }
.b2b-gauge svg { display: block; width: 100%; }
.b2b-gauge__val { position: absolute; left: 0; right: 0; bottom: 4px; text-align: center; font: 600 32px/1 var(--font); color: var(--ink); font-variant-numeric: tabular-nums; }
.b2b-gauge__val small { font-size: 13px; font-weight: 500; color: var(--ink-3); }
.b2b-gauge__track-stroke { stroke: #ECEDEF; }
@media (prefers-reduced-motion: no-preference) {
    .b2b-gauge__arc { animation: noirGauge 1.2s .3s var(--ez) both; }
}
@keyframes noirGauge { from { stroke-dashoffset: 264; } }

.b2b-filecard {
    position: relative; display: flex; align-items: center; gap: 8px;
    background: var(--surface);
    border: 1px solid var(--line); border-radius: var(--r-panel);
    box-shadow: var(--shadow);
    padding: 18px; text-decoration: none;
    transition: transform .25s var(--ez), box-shadow .25s var(--ez);
}
.b2b-filecard:hover { transform: translateY(-3px); box-shadow: var(--shadow-lift); }
.b2b-filecard b { display: block; font: 600 13.5px/1.25 var(--font); color: var(--ink); }
.b2b-filecard i { display: block; font: 400 11.5px/1.3 var(--font); font-style: normal; color: var(--ink-3); margin-top: 3px; }
.b2b-filecard svg { width: 16px; height: 16px; color: var(--ink-3); margin-left: auto; flex-shrink: 0; }
.b2b-main a.b2b-filecard { text-decoration: none; }

/* легаси-обёртки v7-дашборда, живущие в страницах */
.b2b-hud-quick { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.b2b-hud-quick a { display: block; background: #F5F6F8; border-radius: var(--r-ctl); padding: 13px; text-decoration: none; transition: background .2s var(--ez); }
.b2b-hud-quick a:hover { background: #ECEDEF; }
.b2b-hud-quick b { display: block; font: 600 12.5px/1.2 var(--font); color: var(--ink); }
.b2b-hud-quick i { display: block; font: 400 11.5px/1.3 var(--font); font-style: normal; color: var(--ink-3); margin-top: 4px; }
.b2b-hud-alert { display: flex; align-items: center; gap: 18px; }
.b2b-hud-alert__ico { width: 44px; height: 44px; border-radius: var(--r-ctl); background: var(--warm-y); display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.b2b-hud-alert__ico svg path { stroke: #16171A; }
.b2b-hud-alert__title { font: 600 14px/1.3 var(--font); color: var(--ink); }
.b2b-hud-alert__sub { font: 400 12.5px/1.4 var(--font); color: var(--ink-2); margin-top: 3px; }
.b2b-hud-msglabel { display: block; margin-bottom: 8px; font: 600 11px/1.2 var(--font); color: var(--ink-3); }
.b2b-hud-cursor { display: none; }
.b2b-hud-ring { display: none; }
.b2b-sec__head { display: flex; align-items: baseline; gap: 14px; padding-bottom: 12px; margin-bottom: 18px; border-bottom: 1px solid var(--line-strong); }
.b2b-sec__index { font: 600 12px/1.2 var(--mono); color: var(--ink-3); }
.b2b-sec__name { font: 600 12px/1.2 var(--font); color: var(--ink-2); }
.b2b-sec__aside { margin-left: auto; font: 500 12px/1.2 var(--font); color: var(--ink-3); }
.b2b-sec__aside a { color: var(--ink); }

/* summary (корзина) */
.b2b-summary { position: sticky; top: 16px; }
.b2b-summary__row { display: flex; justify-content: space-between; gap: 14px; padding: 7px 0; font-size: 13.5px; color: var(--ink-2); }
.b2b-summary__row b, .b2b-summary__row span:last-child { color: var(--ink); }
.b2b-summary__row--total { border-top: 2px solid var(--ink); margin-top: 8px; padding-top: 12px; font: 600 16px/1.3 var(--font); color: var(--ink); }

/* ---------- печать КП (светлая — уходит в PDF/принтер) ---------- */

.b2b-quote-actions { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 18px; }
.b2b-quote-doc {
    background: #fff; color: #111; max-width: 900px; margin: 0 auto;
    border-radius: var(--r-panel); box-shadow: var(--shadow-lift); padding: 36px 40px;
}
.b2b-quote-doc h1 { font-size: 22px; margin: 0 0 4px; }
.b2b-quote-doc table { width: 100%; border-collapse: collapse; }
.b2b-quote-doc th, .b2b-quote-doc td { border-bottom: 1px solid #e5e5e5; padding: 8px 10px; text-align: left; font-size: 13px; color: #111; }
.b2b-quote-doc .num { text-align: right; }
@media print {
    .b2b-side, .b2b-top, .b2b-foot, .b2b-quote-actions { display: none !important; }
    .b2b-body { background: #fff; }
    .b2b-quote-doc { box-shadow: none; padding: 0; }
}

/* чат квот */
.b2b-chat { display: flex; flex-direction: column; gap: 10px; }
.b2b-chat__msg { max-width: 85%; padding: 10px 14px; border-radius: 12px; font-size: 13.5px; background: #F3F4F6; }
.b2b-chat__msg--self { align-self: flex-end; background: var(--night); color: #fff; }
.b2b-chat__msg--self .b2b-chat__meta { color: rgba(255, 255, 255, .55); }
.b2b-chat__meta { font-size: 11px; color: var(--ink-3); margin-top: 4px; }

/* ---------- shimmer (техника jh3y: бегущий градиент по тексту) ---------- */

.b2b-shimmer {
    background: linear-gradient(110deg, rgba(22, 23, 26, .55) 40%, #16171A 50%, rgba(22, 23, 26, .55) 60%);
    background-size: 250% 100%;
    -webkit-background-clip: text; background-clip: text;
    color: transparent; -webkit-text-fill-color: transparent;
    box-decoration-break: clone; -webkit-box-decoration-break: clone;
}
@media (prefers-reduced-motion: no-preference) {
    .b2b-shimmer { animation: noirShimmer 3.2s linear infinite; }
}
@keyframes noirShimmer { from { background-position: 200% 0; } to { background-position: -50% 0; } }
@media (prefers-reduced-motion: reduce) { .b2b-shimmer { color: var(--ink); -webkit-text-fill-color: currentColor; background: none; } }

/* ---------- ссылки ---------- */

.b2b-main a:not(.b2b-btn):not(.b2b-side__link):not(.b2b-showtile):not(.b2b-filecard):not(.b2b-feature-pills__pill):not(.b2b-brand-tabs__tab):not(.b2b-pager__btn) {
    color: var(--ink); text-decoration-color: rgba(16, 17, 20, .3);
}
/* активные чипы: белый текст на графитовой плите (специфичность выше ссылочного правила) */
.b2b-main a.b2b-feature-pills__pill.is-current,
.b2b-main a.b2b-brand-tabs__tab.is-current,
.b2b-main a.b2b-pager__btn.is-current { color: #fff; }

/* ---------- каскад входа (fallback без GSAP; fx перекрывает) ---------- */

@media (prefers-reduced-motion: no-preference) {
    html:not(.has-fx) .b2b-enter { opacity: 0; transform: translateY(10px); animation: noirRise .55s var(--ez) forwards; }
    html:not(.has-fx) .b2b-enter:nth-child(2) { animation-delay: .1s; }
    html:not(.has-fx) .b2b-enter:nth-child(3) { animation-delay: .2s; }
    html:not(.has-fx) .b2b-enter:nth-child(4) { animation-delay: .3s; }
}
@keyframes noirRise { to { opacity: 1; transform: translateY(0); } }

/* мобильные мелочи */
@media (max-width: 640px) {
    .b2b-btn { min-height: 44px; }
    .b2b-input, .b2b-select { min-height: 44px; }
    .b2b-card { padding: 16px; }
}
/* ================ ЛОГИН (перенос из v5 без изменений) ================ */
/* ---------- минимальный layout (логин, печать КП) ---------- */

.b2b-body--minimal { background: var(--bg); }
.b2b-minimal-wrap { min-height: 100dvh; }

/* ---------- логин: сплит — three.js-светильник слева, форма на бумаге справа ---------- */

.b2b-login-split { display: grid; grid-template-columns: minmax(400px, 46%) 1fr; min-height: 100dvh; }

.b2b-login-brand {
    position: relative; overflow: hidden;
    background: #d2d4d8; /* сцена светло-серая — как мрамор-референс */
    display: flex; flex-direction: column; justify-content: space-between;
    padding: 42px 46px;
    color: #565c66;
}
.b2b-lux__video {
    position: absolute; inset: 0; width: 100%; height: 100%;
    object-fit: cover; object-position: center 42%; display: block;
    /* zoom-crop: у исходных видео вшиты кинематографичные чёрные полосы
       сверху/снизу, повторяющиеся на каждом loop — обрезаем их масштабом,
       родитель уже держит overflow:hidden (2026-07-07, откат см. b2b_video_bar_fix_rollback.sh) */
    transform: scale(1.28);
}
/* скрим снизу — читаемость нижней подписи поверх видео */
.b2b-lux__scrim {
    position: absolute; inset: 0; pointer-events: none;
    background: linear-gradient(180deg, rgba(210,212,216,.35) 0%, transparent 22%, transparent 74%, rgba(210,212,216,.72) 100%);
}

.b2b-login-brand__top { position: relative; z-index: 2; }
.b2b-lux__word { display: inline-flex; }
.b2b-lux__word i {
    font-style: normal; font-weight: 800; font-size: 25px; letter-spacing: .18em; color: #16181d;
    opacity: 0; transform: translateY(12px);
}
.lux-ready .b2b-lux__word i {
    animation: luxLetter .8s cubic-bezier(.16, 1, .3, 1) forwards;
    animation-delay: calc(.7s + var(--i) * 50ms);
}
.b2b-lux__b2b {
    font-weight: 800; font-size: 12px; letter-spacing: .26em; color: var(--accent);
    margin-left: 8px; opacity: 0;
}
.lux-ready .b2b-lux__b2b { animation: luxFade 1s ease 1.25s forwards; }
.b2b-lux__tag {
    margin-top: 9px; font-size: 11px; letter-spacing: .2em; text-transform: uppercase;
    color: #787f8a; opacity: 0;
}
.lux-ready .b2b-lux__tag { animation: luxFade 1.1s ease 1.45s forwards; }

.b2b-login-brand__note {
    position: relative; z-index: 2; margin: 0;
    font-size: 13.5px; line-height: 1.65; max-width: 34ch; opacity: 0;
}
.b2b-login-brand__note b { color: #16181d; font-weight: 650; }
.lux-ready .b2b-login-brand__note { animation: luxFade 1.4s ease 2.1s forwards; }

.b2b-login-pane {
    display: flex; align-items: center; justify-content: center; padding: 40px 24px;
    /* холодный светло-серый мрамор — продолжает фон видео слева, шов у левого края совпадает */
    background:
        radial-gradient(66% 76% at 44% 46%, rgba(255, 255, 255, .5), transparent 62%),
        linear-gradient(100deg, #c8cbd0 0%, #d5d7db 44%, #e3e5e8 100%);
}
.b2b-login { width: 100%; max-width: 360px; }

/* ---------- Stitch-карточка входа (тёмное стекло) ---------- */

.b2b-authcard {
    width: 100%; max-width: 420px;
    background: rgba(0, 0, 0, .9); /* глубокое чёрное стекло, 10% прозрачности */
    backdrop-filter: blur(20px); -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, .16);
    border-radius: 24px;
    padding: 44px 40px;
    box-shadow: 0 30px 90px -30px rgba(0, 0, 0, .7), inset 0 1px 0 rgba(255, 255, 255, .08);
    will-change: transform;
}
@media (prefers-reduced-transparency: reduce) {
    .b2b-authcard { background: #050608; backdrop-filter: none; -webkit-backdrop-filter: none; }
}
.b2b-authcard__head { text-align: center; margin-bottom: 30px; }
.b2b-authcard__title { margin: 0 0 8px; font-size: 30px; font-weight: 700; letter-spacing: -.02em; color: #fff; }
.b2b-authcard__sub { margin: 0; font-size: 14px; color: #a7adba; }

.b2b-authcard__error {
    margin-bottom: 18px; padding: 11px 14px; border-radius: 12px; font-size: 13.5px;
    background: rgba(205, 53, 64, .16); color: #ffb4ab; border: 1px solid rgba(205, 53, 64, .3);
}

.b2b-authcard__form { display: flex; flex-direction: column; gap: 20px; }
.b2b-authfield__label { display: block; font-size: 13px; font-weight: 500; color: #c3c7d2; margin-bottom: 8px; }
.b2b-authfield__row { display: flex; justify-content: space-between; align-items: baseline; }
.b2b-authfield__wrap { position: relative; }
.b2b-authfield__icon {
    position: absolute; left: 15px; top: 50%; transform: translateY(-50%);
    width: 20px; height: 20px; color: #7d8494; pointer-events: none;
}
.b2b-authfield__input {
    width: 100%; height: 50px; padding: 0 46px 0 44px;
    background: rgba(255, 255, 255, .04);
    border: 1px solid rgba(255, 255, 255, .18); border-radius: 14px;
    font: 400 15px/1 var(--font); color: #fff;
    transition: border-color .18s var(--ease), box-shadow .18s var(--ease), background .18s var(--ease);
}
.b2b-authfield__input::placeholder { color: #6b7280; }
.b2b-authfield__input:hover { border-color: rgba(255, 255, 255, .3); }
.b2b-authfield__input:focus {
    outline: none; border-color: rgba(255, 255, 255, .85);
    background: rgba(255, 255, 255, .07); box-shadow: 0 0 0 3px rgba(255, 255, 255, .1);
}
.b2b-authfield__input:-webkit-autofill {
    -webkit-box-shadow: 0 0 0 60px #171922 inset; -webkit-text-fill-color: #fff; caret-color: #fff;
}
.b2b-authfield__toggle {
    position: absolute; right: 12px; top: 50%; transform: translateY(-50%);
    width: 28px; height: 28px; padding: 0; border: 0; background: none; cursor: pointer;
    color: #7d8494; display: flex; align-items: center; justify-content: center; transition: color .15s var(--ease);
}
.b2b-authfield__toggle:hover { color: #fff; }
.b2b-authfield__toggle svg { width: 20px; height: 20px; }

.b2b-authcard__link { font-size: 12.5px; color: #cfd3dc; text-decoration: underline; text-underline-offset: 2px; }
.b2b-authcard__link:hover { color: #fff; }

.b2b-authcard__cta {
    margin-top: 4px; width: 100%; height: 50px;
    display: flex; align-items: center; justify-content: center; gap: 8px;
    background: #fff; color: #101318; border: 0; border-radius: 14px; cursor: pointer;
    font: 700 15px/1 var(--font);
    transition: background .18s var(--ease), transform .12s var(--ease), box-shadow .18s var(--ease);
}
.b2b-authcard__cta svg { width: 18px; height: 18px; }
.b2b-authcard__cta:hover { background: #eceef2; transform: translateY(-1px); box-shadow: 0 10px 28px -10px rgba(255, 255, 255, .3); }
.b2b-authcard__cta:active { transform: scale(.98); box-shadow: none; }
.b2b-authcard__cta:focus-visible { outline: 2px solid #fff; outline-offset: 2px; }

.b2b-authcard__foot { margin: 26px 0 0; text-align: center; font-size: 13px; color: #9aa1ad; }
.b2b-authcard__foot a { color: #fff; text-decoration: underline; text-underline-offset: 2px; }

/* мягкое появление карточки */
.b2b-authcard { opacity: 0; transform: translateY(14px); }
.lux-ready .b2b-authcard { animation: luxAuthIn .8s cubic-bezier(.16, 1, .3, 1) .35s forwards; }
@keyframes luxAuthIn { to { opacity: 1; transform: translateY(0); } }

/* бренд-марка (общая) */
.b2b-lux__brandmark { display: inline-flex; align-items: baseline; text-decoration: none; }

/* ---------- композиция C (mirror): видео с двух сторон, форма по центру ---------- */

.b2b-login-mirror {
    position: fixed; inset: 0; overflow: hidden;
    display: grid; grid-template-columns: 1fr minmax(360px, 460px) 1fr;
    /* серый мост под формой — единый тон мрамора видео (точный, весь мост одним цветом) */
    background: #d3d5d9;
}
.b2b-mirror-side { position: relative; overflow: hidden; }
.b2b-mirror-side .b2b-lux__video {
    position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: center 42%;
}
/* мягкое растворение внутренних краёв видео в серый мост под формой */
.b2b-mirror-side__fade { position: absolute; inset: 0; pointer-events: none; }
.b2b-mirror-side__fade--l { background: linear-gradient(90deg, transparent 62%, #d3d5d9 100%); }
.b2b-mirror-side__fade--r { background: linear-gradient(270deg, transparent 62%, #d3d5d9 100%); }

.b2b-mirror-stage {
    position: relative; z-index: 2;
    display: flex; flex-direction: column; align-items: center; justify-content: center;
    gap: 26px; padding: 40px 12px;
}
/* бренд по центру НАД формой, чёрный (мост светлый) */
.b2b-mirror-brand { text-align: center; }
.b2b-mirror-brand .b2b-lux__word i { color: #16181d; }
.b2b-mirror-brand .b2b-lux__b2b { color: var(--accent); }
.b2b-mirror-brand .b2b-lux__tag { margin-top: 7px; color: #6b7280; }

@media (max-width: 900px) {
    /* на узком — видео уходит фоном на весь экран, форма по центру (как center) */
    .b2b-login-mirror { grid-template-columns: 1fr; }
    .b2b-mirror-side--l { position: absolute; inset: 0; }
    .b2b-mirror-side--l .b2b-lux__video { object-position: center 40%; transform: scale(1.5); }
    .b2b-mirror-side--l .b2b-mirror-side__fade { display: none; }
    .b2b-mirror-side--r { display: none; }
    .b2b-mirror-stage { position: absolute; inset: 0; z-index: 2; padding: 80px 16px; }
    /* поверх видео на мобиле бренд читается светлым */
    .b2b-mirror-brand .b2b-lux__word i { color: #f5f6f8; text-shadow: 0 1px 10px rgba(0,0,0,.5); }
    .b2b-mirror-brand .b2b-lux__tag { color: #dfe2e8; text-shadow: 0 1px 8px rgba(0,0,0,.5); }
}

/* ---------- композиция B: видео на весь экран, карточка по центру ---------- */

.b2b-login-center { position: fixed; inset: 0; overflow: hidden; }
.b2b-login-center .b2b-lux__video {
    position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: center 40%;
}
.b2b-lux__scrim--center {
    background:
        linear-gradient(90deg, rgba(18,19,24,.5) 0%, transparent 30%, transparent 60%, rgba(18,19,24,.5) 100%),
        radial-gradient(60% 60% at 50% 50%, transparent 30%, rgba(14,15,20,.45) 100%);
}
.b2b-login-center__top {
    position: absolute; z-index: 3; top: 0; left: 0; right: 0;
    padding: 26px clamp(20px, 5vw, 64px);
}
.b2b-login-center__top .b2b-lux__word i { color: #f5f6f8; }
.b2b-login-center__top .b2b-lux__b2b { color: var(--primary, #b4c5ff); }
.b2b-login-center__stage {
    position: absolute; inset: 0; z-index: 2;
    display: flex; align-items: center; justify-content: center; padding: 90px 20px;
}
.b2b-login-center__foot {
    position: absolute; z-index: 3; bottom: 0; left: 0; right: 0;
    padding: 22px clamp(20px, 5vw, 64px); text-align: center;
    font-size: 12px; color: rgba(255, 255, 255, .55);
}
@media (max-width: 640px) {
    .b2b-authcard { padding: 34px 24px; border-radius: 20px; }
    .b2b-login-center__stage { padding: 76px 16px; }
}
.b2b-login__h { margin: 0 0 4px; font-size: 24px; font-weight: 700; letter-spacing: -.015em; }
.b2b-login__sub { color: var(--ink-2); font-size: 13.5px; margin-bottom: 26px; }
.b2b-login__cta { width: 100%; margin-top: 8px; }

.b2b-login__h, .b2b-login__sub, .b2b-login__f1, .b2b-login__f2, .b2b-login__cta { opacity: 0; transform: translateY(10px); }
.lux-ready .b2b-login__h   { animation: luxLetter .7s cubic-bezier(.16, 1, .3, 1) .55s forwards; }
.lux-ready .b2b-login__sub { animation: luxLetter .7s cubic-bezier(.16, 1, .3, 1) .68s forwards; }
.lux-ready .b2b-login__f1  { animation: luxLetter .7s cubic-bezier(.16, 1, .3, 1) .82s forwards; }
.lux-ready .b2b-login__f2  { animation: luxLetter .7s cubic-bezier(.16, 1, .3, 1) .94s forwards; }
.lux-ready .b2b-login__cta { animation: luxLetter .7s cubic-bezier(.16, 1, .3, 1) 1.08s forwards; }

@keyframes luxLetter { to { opacity: 1; transform: translateY(0); } }
@keyframes luxFade { to { opacity: 1; } }

@media (max-width: 900px) {
    .b2b-login-split { grid-template-columns: 1fr; grid-template-rows: 32dvh 1fr; }
    .b2b-login-brand { padding: 22px 24px; }
    .b2b-login-brand__note { display: none; }
    .b2b-lux__word i { font-size: 19px; }
}

@media (prefers-reduced-motion: reduce) {
    .b2b-lux__word i, .b2b-lux__b2b, .b2b-lux__tag, .b2b-login-brand__note,
    .b2b-login__h, .b2b-login__sub, .b2b-login__f1, .b2b-login__f2, .b2b-login__cta {
        opacity: 1 !important; transform: none !important; animation: none !important;
    }
}
