/* ==========================================================================
   NBC Biz Signup — заявка на оптовый доступ, панель справа
   ========================================================================== */

.nbc-biz {
    --b-navy:       #1B2356;
    --b-navy-deep:  #0E1433;
    --b-gold:       #C49953;
    --b-gold-light: #D5B480;
    --b-cream:      #FAF6F0;
    --b-cream-dark: #F0E8DA;
    --b-white:      #FFFFFF;
    --b-text:       #2A2A2A;
    --b-muted:      #6B6B6B;
    --b-line:       rgba(27, 35, 86, .14);

    /* Выезд и заезд одинаковые — 400 мс */
    --b-ease:       cubic-bezier(.4, 0, .2, 1);
    --b-time:       .4s;

    position: fixed;
    inset: 0;
    z-index: 100000;
    font-family: 'Montserrat', -apple-system, BlinkMacSystemFont, sans-serif;
}

.nbc-biz[hidden] { display: none !important; }

.nbc-biz * { box-sizing: border-box; }

.nbc-biz__overlay {
    position: absolute;
    inset: 0;
    background: rgba(14, 20, 51, .45);
    opacity: 0;
    transition: opacity var(--b-time) var(--b-ease);
}

.nbc-biz__panel {
    position: absolute;
    top: 0;
    right: 0;
    height: 100%;
    width: 30%;
    min-width: 380px;
    max-width: 560px;
    background: var(--b-cream);
    box-shadow: -18px 0 48px rgba(14, 20, 51, .18);
    transform: translateX(100%);
    transition: transform var(--b-time) var(--b-ease);
    display: flex;
    flex-direction: column;
}

/* Класс вешает JS в следующем кадре — иначе браузер не анимирует появление */
.nbc-biz.is-open .nbc-biz__overlay { opacity: 1; }
.nbc-biz.is-open .nbc-biz__panel   { transform: translateX(0); }

.nbc-biz__scroll {
    flex: 1;
    overflow-y: auto;
    padding: 54px 34px 40px;
}

.nbc-biz__close {
    position: absolute;
    top: 16px;
    right: 16px;
    width: 34px;
    height: 34px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    background: transparent;
    border: 1px solid var(--b-line);
    border-radius: 50%;
    color: var(--b-navy);
    cursor: pointer;
    transition: background .2s, color .2s;
}

.nbc-biz__close svg { width: 16px; height: 16px; }
.nbc-biz__close:hover { background: var(--b-navy); color: var(--b-white); }

/* ─────── Заголовок ─────── */
.nbc-biz__kicker {
    margin: 0 0 6px;
    font-size: 11px;
    font-weight: 600;
    letter-spacing: .14em;
    text-transform: uppercase;
    color: var(--b-gold);
}

.nbc-biz__title {
    margin: 0 0 10px;
    font-family: 'Spectral', Georgia, serif;
    font-size: 28px;
    font-weight: 400;
    line-height: 1.1;
    color: var(--b-navy);
}

.nbc-biz__lead {
    margin: 0 0 22px;
    font-size: 13px;
    line-height: 1.55;
    color: var(--b-muted);
}

/* ─────── Что даём ─────── */
.nbc-biz__perks {
    margin: 0 0 24px;
    padding: 0;
    list-style: none;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
}

.nbc-biz__perk {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
    padding: 12px 10px;
    background: var(--b-white);
    border: 1px solid var(--b-line);
    border-radius: 12px;
    font-size: 11px;
    line-height: 1.35;
    color: var(--b-text);
}

.nbc-biz__perk-ico {
    flex: 0 0 28px;
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--b-cream-dark);
    border-radius: 50%;
    color: var(--b-navy);
}

.nbc-biz__perk-ico svg { width: 14px; height: 14px; }

/* ─────── Форма ─────── */
.nbc-biz__form { display: grid; gap: 10px; }

/* Подпись лежит поверх поля и уезжает наверх, когда в поле что-то есть.
   Держится на placeholder=" " — без него :placeholder-shown не сработает. */
.nbc-biz__field {
    display: block;
    position: relative;
}

.nbc-biz__label {
    position: absolute;
    left: 2px;
    top: 16px;
    font-size: 13px;
    line-height: 1;
    color: var(--b-muted);
    pointer-events: none;
    transform-origin: left top;
    transition: transform .2s var(--b-ease), color .2s var(--b-ease);
}

.nbc-biz__field input {
    width: 100%;
    padding: 18px 2px 6px;
    background: transparent;
    border: 0;
    border-bottom: 1px solid var(--b-line);
    border-radius: 0;
    font-family: inherit;
    font-size: 14px;
    line-height: 1.2;
    color: var(--b-text);
    transition: border-color .2s;
}

.nbc-biz__field input:focus {
    outline: none;
    border-bottom-color: var(--b-gold);
}

.nbc-biz__field input:focus + .nbc-biz__label,
.nbc-biz__field input:not(:placeholder-shown) + .nbc-biz__label {
    transform: translateY(-14px) scale(.78);
    letter-spacing: .06em;
    text-transform: uppercase;
    font-weight: 600;
}

.nbc-biz__field input:focus + .nbc-biz__label { color: var(--b-gold); }

.nbc-biz__field input.is-bad { border-bottom-color: #C0392B; }
.nbc-biz__field input.is-bad + .nbc-biz__label { color: #C0392B; }

/* Honeypot: вне потока и вне экрана, но не display:none — боты такое пропускают */
.nbc-biz__trap {
    position: absolute;
    left: -9999px;
    width: 1px;
    height: 1px;
    overflow: hidden;
}

.nbc-biz__agree {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    font-size: 11.5px;
    line-height: 1.5;
    color: var(--b-muted);
    cursor: pointer;
}

.nbc-biz__agree input {
    flex: 0 0 16px;
    width: 16px;
    height: 16px;
    margin: 2px 0 0;
    accent-color: var(--b-navy);
    cursor: pointer;
}

.nbc-biz__agree a {
    color: var(--b-navy);
    text-decoration: underline;
    text-underline-offset: 2px;
}

.nbc-biz__agree a:hover { color: var(--b-gold); }

.nbc-biz__submit {
    margin-top: 4px;
    padding: 14px 20px;
    background: var(--b-navy);
    border: 1px solid var(--b-navy);
    border-radius: 90px;
    font-family: inherit;
    font-size: 12px;
    font-weight: 600;
    letter-spacing: .1em;
    text-transform: uppercase;
    color: var(--b-white);
    cursor: pointer;
    transition: background .2s, color .2s, border-color .2s;
}

.nbc-biz__submit:hover {
    background: var(--b-gold);
    border-color: var(--b-gold);
}

.nbc-biz__submit[disabled] {
    opacity: .6;
    cursor: default;
}

.nbc-biz__error {
    margin: 0;
    font-size: 12px;
    line-height: 1.4;
    color: #C0392B;
}

/* ─────── Спасибо ─────── */
.nbc-biz__done { text-align: center; padding: 30px 0 10px; }

.nbc-biz__done-ico {
    width: 60px;
    height: 60px;
    margin: 0 auto 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--b-gold), var(--b-gold-light));
    border-radius: 50%;
    color: var(--b-white);
}

.nbc-biz__done-ico svg { width: 26px; height: 26px; }

.nbc-biz__done h3 {
    margin: 0 0 8px;
    font-family: 'Spectral', Georgia, serif;
    font-size: 22px;
    font-weight: 400;
    color: var(--b-navy);
}

.nbc-biz__done p {
    margin: 0;
    font-size: 13px;
    line-height: 1.55;
    color: var(--b-muted);
}

/* ─────── Мобильный ─────── */
@media (max-width: 767px) {
    .nbc-biz__panel {
        width: 95%;
        min-width: 0;
        max-width: none;
    }

    .nbc-biz__scroll { padding: 48px 22px 32px; }
    .nbc-biz__title  { font-size: 24px; }

    .nbc-biz__perks { grid-template-columns: 1fr; }

    .nbc-biz__perk {
        flex-direction: row;
        align-items: center;
        font-size: 12px;
    }
}

/* Пользователь просил меньше движения — уважаем настройку системы */
@media (prefers-reduced-motion: reduce) {
    .nbc-biz__overlay,
    .nbc-biz__panel { transition: none; }
}
