/* Шрифт Rubik лежит на нашем сервере (без Google: быстрее в России и данные посетителей не уходят за границу) */
@font-face {
    font-family: 'Rubik'; font-style: normal; font-display: swap; font-weight: 300 900;
    src: url(fonts/rubik-cyrillic.woff2) format('woff2');
    unicode-range: U+0301,U+0400-045F,U+0490-0491,U+04B0-04B1,U+2116;
}
@font-face {
    font-family: 'Rubik'; font-style: normal; font-display: swap; font-weight: 300 900;
    src: url(fonts/rubik-latin.woff2) format('woff2');
    unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+2074,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD;
}

/* ==========================================================================
   VeksHaunt — стили магазина привилегий
   Палитра:
     --bg          фон страницы (почти чёрный)
     --bg-glow     цвет радиального оранжевого свечения
     --orange      основной акцентный оранжевый
     --orange-dim  приглушённый оранжевый (рамки, второстепенные акценты)
     --panel       фон карточек/панелей
     --panel-line  тонкая рамка панелей
     --text        основной текст (светлый)
     --text-dim    второстепенный серый текст
   ========================================================================== */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --bg: #0d0d0d;
    --bg-glow: #ff7a1a;
    --orange: #ff8c1e;
    --orange-bright: #ffab4d;
    --orange-dim: #6e4420;
    --panel: #161210;
    --panel-soft: #1b1612;
    --panel-line: #2c2117;
    --text: #f3efe9;
    --text-dim: #9a9189;
    --text-faint: #6b6359;
}

html {
    scroll-behavior: smooth;
    /* Полоса прокрутки скрыта (как на FunTime): страница не сдвигается,
       когда появляется прокрутка. Колесо, тачпад и свайп работают как обычно. */
    scrollbar-width: none;
}
html::-webkit-scrollbar,
body::-webkit-scrollbar {
    display: none;
}

/* body — флекс-колонка на всю высоту экрана, чтобы контент центрировался
   по вертикали (margin:auto у .container) и не было разного отступа сверху/снизу */
body {
    background: var(--bg);
    color: var(--text);
    font-family: 'Rubik', sans-serif;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    overflow-x: hidden;
    position: relative;
}

.hidden {
    display: none !important;
}

/* ---------- Фон: радиальное оранжевое свечение по центру ---------- */
.bg-glow {
    position: fixed;
    inset: 0;
    z-index: 0;
    pointer-events: none;
    background:
            radial-gradient(circle at 50% 18%, color-mix(in srgb, var(--bg-glow) 22%, transparent) 0%, transparent 45%),
            radial-gradient(circle at 50% 0%, color-mix(in srgb, var(--bg-glow) 14%, transparent) 0%, transparent 60%);
}

/* ---------- Рассыпанные искры-частицы (генерируются в JS) ---------- */
.sparks {
    position: fixed;
    inset: 0;
    z-index: 0;
    pointer-events: none;
    overflow: hidden;
}

.spark {
    position: absolute;
    background: var(--orange);
    border-radius: 50%;
    opacity: .5;
    box-shadow: 0 0 6px 1px color-mix(in srgb, var(--orange) 70%, transparent);
    animation: spark-float linear infinite;
}

@keyframes spark-float {
    0%   { transform: translateY(0) translateX(0); opacity: 0; }
    10%  { opacity: .6; }
    90%  { opacity: .4; }
    100% { transform: translateY(-40px) translateX(6px); opacity: 0; }
}

.sparkle-deco {
    position: fixed;
    right: 28px;
    bottom: 24px;
    color: var(--orange-bright);
    font-size: 24px;
    z-index: 1;
    text-shadow: 0 0 12px color-mix(in srgb, var(--orange) 80%, transparent);
    animation: sparkle-pulse 2.4s ease-in-out infinite;
    pointer-events: none;
}

@keyframes sparkle-pulse {
    0%, 100% { opacity: .55; transform: scale(1); }
    50%      { opacity: 1;   transform: scale(1.18); }
}

/* ---------- Контейнер ---------- */
/* margin: auto — центрирует блок и по вертикали внутри flex-колонки body,
   и по горизонтали (вместе с max-width). Если контента больше высоты экрана,
   отступы просто схлопнутся в 0 — без обрезания контента сверху. */
.container {
    position: relative;
    z-index: 1;
    width: 100%;
    max-width: 1080px;
    margin: auto;
    padding: 48px 24px;
}

/* ---------- Главный экран ---------- */
.hero {
    text-align: center;
    margin-bottom: 56px;
}

.hero-title {
    font-family: 'Rubik', sans-serif;
    font-size: clamp(24px, 4.2vw, 40px);
    line-height: 1.6;
    color: var(--text);
    text-shadow: 3px 3px 0 #000;
    margin-bottom: 28px;
}

.hero-title .accent {
    color: var(--orange);
    text-shadow: 3px 3px 0 #000, 0 0 22px color-mix(in srgb, var(--orange) 65%, transparent);
}

/* ---------- Кнопки (используются в магазине и в модалке) ---------- */
.btn {
    font-family: 'Rubik', sans-serif;
    font-weight: 600;
    font-size: 15px;
    padding: 14px 28px;
    border-radius: 8px;
    cursor: pointer;
    transition: transform .15s ease, box-shadow .2s ease, background .2s ease;
}

.btn:hover {
    transform: translateY(-1px);
}

.btn:focus-visible {
    outline: 2px solid var(--orange-bright);
    outline-offset: 2px;
}

.btn-outline {
    background: transparent;
    border: 1px solid var(--orange);
    color: var(--orange-bright);
    box-shadow: 0 0 12px color-mix(in srgb, var(--orange) 30%, transparent);
}

.btn-outline:hover {
    background: color-mix(in srgb, var(--orange) 10%, transparent);
    box-shadow: 0 0 26px color-mix(in srgb, var(--orange) 55%, transparent);
}

/* ---------- Секция магазина ---------- */
.shop {
    display: grid;
    grid-template-columns: 1.05fr 1fr;
    gap: 24px;
    align-items: stretch;
}

.panel {
    background: var(--panel);
    border: 1px solid var(--panel-line);
    border-radius: 12px;
    padding: 24px;
    display: flex;
    flex-direction: column;
    /* единая высота окон независимо от выбранного товара — чтобы блок
       не менял размер при переключении между привилегиями и коинами.
       Значение подобрано так, чтобы вмещать самый длинный вариант
       (привилегию с тремя пунктами возможностей и тремя статами) —
       более короткие варианты (коины) просто растягиваются до него же. */
    min-height: 540px;
}

.panel-title {
    font-family: 'Rubik', sans-serif;
    font-size: 16px;
    font-weight: 600;
    color: var(--text);
    padding-bottom: 14px;
    margin-bottom: 14px;
    border-bottom: 1px solid var(--panel-line);
    background-image: linear-gradient(90deg, var(--orange) 0%, transparent 55%);
    background-repeat: no-repeat;
    background-position: bottom left;
    background-size: 100% 2px;
}

/* ---------- Список товаров ---------- */
/* flex-колонка с центрированием — если в панели остаётся свободное место
   (она растянута под высоту правой колонки), оно делится поровну сверху
   и снизу, а не "проваливается" целиком под последний пункт */
.product-list {
    list-style: none;
    flex: 1;
    min-height: 0;
    overflow-y: auto;
    padding-right: 6px;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.product-list::-webkit-scrollbar {
    width: 5px;
}

.product-list::-webkit-scrollbar-thumb {
    background: var(--orange-dim);
    border-radius: 4px;
}

/* Строки товаров увеличены — список равномерно заполняет высоту панели
   и не остаётся большого пустого пространства внизу */
.product-item {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 17px 12px;
    border-radius: 9px;
    border-left: 3px solid transparent;
    cursor: pointer;
    transition: background .15s ease, border-color .15s ease;
}

.product-item:hover {
    background: color-mix(in srgb, var(--orange) 6%, transparent);
}

.product-item.active {
    background: color-mix(in srgb, var(--orange) 12%, transparent);
    border-left-color: var(--orange);
    box-shadow: inset 0 0 18px color-mix(in srgb, var(--orange) 14%, transparent);
}

/* "Слот" под иконку предмета — тёмная плитка одного размера для всех товаров
   (и привилегий с пиксель-иконками, и коинов с простым цветным квадратиком),
   с лёгким свечением в цвете товара */
.item-slot {
    width: 30px;
    height: 30px;
    border-radius: 6px;
    flex-shrink: 0;
    background: var(--panel-soft);
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow:
            inset 0 0 0 1px var(--panel-line),
            0 0 9px color-mix(in srgb, var(--icon-glow, transparent) 45%, transparent);
}

.item-slot svg {
    display: block;
    width: 19px;
    height: 19px;
}

.coin-dot {
    width: 18px;
    height: 18px;
    border-radius: 4px;
    box-shadow: 0 0 6px color-mix(in srgb, var(--icon-glow, transparent) 55%, transparent);
}

.item-name {
    flex: 1;
    font-weight: 500;
    font-size: 15px;
}

.item-price {
    font-size: 13px;
    color: var(--text-dim);
    white-space: nowrap;
}

/* ---------- Выбор срока (привилегии) ---------- */
.term-row {
    display: flex;
    align-items: center;
    gap: 16px;
    flex-wrap: wrap;
    margin-bottom: 18px;
}

.term-label {
    font-size: 14px;
    color: var(--text-dim);
}

.term-options {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
}

.term-btn {
    background: none;
    border: none;
    border-bottom: 2px solid transparent;
    color: var(--text-dim);
    font-family: 'Rubik', sans-serif;
    font-size: 14px;
    font-weight: 500;
    padding: 3px 0;
    cursor: pointer;
    transition: color .15s ease, border-color .15s ease;
}

.term-btn:hover {
    color: var(--text);
}

.term-btn.active {
    color: var(--orange-bright);
    border-bottom-color: var(--orange);
}

/* ---------- Префикс привилегии в чате ---------- */
.privilege-prefix {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 14px;
    color: var(--text);
    background: var(--panel-soft);
    border: 1px solid var(--panel-line);
    border-radius: 8px;
    padding: 9px 14px;
    margin-bottom: 16px;
}

.prefix-icon {
    color: var(--orange);
    flex-shrink: 0;
}

.privilege-prefix strong {
    color: var(--orange-bright);
}

/* ---------- Список возможностей (привилегии) ---------- */
.features-title {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-dim);
    margin-bottom: 10px;
}

.features-list {
    list-style: none;
    margin-bottom: 18px;
}

.features-list li {
    position: relative;
    padding-left: 20px;
    margin-bottom: 8px;
    font-size: 14px;
    color: var(--text);
    line-height: 1.5;
}

.features-list li::before {
    content: '›';
    position: absolute;
    left: 0;
    top: -2px;
    font-size: 17px;
    font-weight: 700;
    color: var(--orange);
}

/* Строка "и все преимущества нижестоящих привилегий" — отдельная галочка */
.features-list li.feature-inherit {
    color: var(--text-dim);
}

.features-list li.feature-inherit::before {
    content: '✓';
    top: 1px;
    font-size: 13px;
    color: #6fd17a;
}

.feature-cmd {
    color: var(--orange-bright);
    font-weight: 600;
}

/* ---------- Блок "Прочее": числовые лимиты привилегии ---------- */
.stats-list {
    list-style: none;
    margin-bottom: 8px;
}

.stats-list li {
    font-size: 14px;
    color: var(--text-dim);
    margin-bottom: 7px;
    line-height: 1.5;
}

.stat-value {
    color: var(--orange-bright);
    font-weight: 600;
}

/* ---------- Блок коинов: описание + список команд ---------- */
.amount-desc {
    font-size: 14px;
    line-height: 1.6;
    color: var(--text);
    margin-bottom: 22px;
}

.spend-list {
    list-style: none;
    margin-bottom: 28px;
}

.spend-list li {
    font-size: 14px;
    color: var(--text-dim);
    margin-bottom: 10px;
    line-height: 1.5;
}

.spend-list .spend-cmd {
    color: var(--orange-bright);
    font-weight: 600;
    font-family: 'Rubik', sans-serif;
}

.spend-list .spend-more {
    color: var(--orange);
    font-weight: 500;
}

/* ---------- Строка покупки ---------- */
.purchase-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 16px;
    margin-top: auto;
    padding-top: 18px;
    border-top: 1px solid var(--panel-line);
}

.price {
    font-size: 15px;
    color: var(--text-dim);
}

.price span {
    color: var(--orange-bright);
    font-weight: 700;
}

.buy-btn {
    padding: 12px 24px;
}

/* ---------- Тост-уведомление ---------- */
.toast {
    position: fixed;
    left: 50%;
    bottom: 30px;
    transform: translateX(-50%) translateY(20px);
    background: var(--panel);
    border: 1px solid var(--orange-dim);
    color: var(--text);
    font-size: 14px;
    padding: 14px 22px;
    border-radius: 8px;
    box-shadow: 0 0 20px color-mix(in srgb, var(--orange) 30%, transparent);
    opacity: 0;
    pointer-events: none;
    transition: opacity .25s ease, transform .25s ease;
    z-index: 60;
    max-width: calc(100vw - 40px);
    text-align: center;
}

.toast.show {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}

/* ==========================================================================
   Модалка покупки
   ========================================================================== */
.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, .7);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    z-index: 50;
    opacity: 0;
    visibility: hidden;
    transition: opacity .2s ease;
}

.modal-overlay.show {
    opacity: 1;
    visibility: visible;
}

.modal {
    position: relative;
    width: 100%;
    max-width: 440px;
    background: var(--panel);
    border: 1px solid var(--panel-line);
    border-radius: 14px;
    padding: 34px 30px 26px;
    box-shadow: 0 0 40px color-mix(in srgb, var(--orange) 25%, transparent);
    transform: translateY(10px);
    transition: transform .2s ease;
}

.modal-overlay.show .modal {
    transform: translateY(0);
}

.modal::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    border-radius: 14px 14px 0 0;
    background: linear-gradient(90deg, var(--orange) 0%, color-mix(in srgb, var(--orange) 30%, transparent) 70%, transparent 100%);
}

.modal-close {
    position: absolute;
    top: 14px;
    right: 16px;
    background: none;
    border: none;
    color: var(--text-dim);
    font-size: 24px;
    line-height: 1;
    cursor: pointer;
    transition: color .15s ease;
}

.modal-close:hover {
    color: var(--orange-bright);
}

.modal-title {
    font-size: 17px;
    font-weight: 700;
    margin-bottom: 22px;
    padding-right: 20px;
}

.modal-title #modalProductName {
    color: var(--orange-bright);
}

.modal-field {
    margin-bottom: 16px;
}

.modal-field input[type="text"] {
    width: 100%;
    background: transparent;
    border: 1px solid var(--panel-line);
    border-radius: 8px;
    padding: 15px;
    text-align: center;
    font-family: 'Rubik', sans-serif;
    font-size: 14px;
    color: var(--text);
    transition: border-color .15s ease, box-shadow .15s ease;
}

.modal-field input[type="text"]::placeholder {
    color: var(--text-dim);
}

.modal-field input[type="text"]:focus {
    outline: none;
    border-color: var(--orange);
    box-shadow: 0 0 14px color-mix(in srgb, var(--orange) 30%, transparent);
}

.modal-amount-label {
    display: block;
    font-size: 13px;
    color: var(--text-dim);
    margin-bottom: 9px;
}

.amount-stepper {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 11px;
}

.stepper-btn {
    width: 36px;
    height: 36px;
    border-radius: 8px;
    border: 1px solid var(--orange-dim);
    background: transparent;
    color: var(--orange-bright);
    font-size: 17px;
    cursor: pointer;
    transition: border-color .15s ease, color .15s ease;
}

.stepper-btn:hover {
    border-color: var(--orange);
    color: var(--orange);
}

.amount-stepper input[type="number"] {
    width: 94px;
    text-align: center;
    background: transparent;
    border: 1px solid var(--panel-line);
    border-radius: 8px;
    padding: 10px 5px;
    font-family: 'Rubik', sans-serif;
    font-size: 15px;
    font-weight: 600;
    color: var(--text);
    -moz-appearance: textfield;
}

.amount-stepper input[type="number"]::-webkit-outer-spin-button,
.amount-stepper input[type="number"]::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

.modal-bottom {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin: 22px 0 18px;
}

.modal-price {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.modal-price-label {
    font-size: 13px;
    color: var(--text-dim);
}

.modal-price-row {
    display: flex;
    align-items: baseline;
    gap: 8px;
    flex-wrap: wrap;
}

.modal-price-old {
    font-size: 13px;
    color: var(--text-faint);
    text-decoration: line-through;
}

.modal-price-value {
    font-size: 21px;
    font-weight: 700;
    color: var(--orange-bright);
}

.modal-promo-badge {
    font-size: 11px;
    font-weight: 700;
    letter-spacing: .3px;
    color: #6fd17a;
    background: color-mix(in srgb, #6fd17a 16%, transparent);
    border: 1px solid color-mix(in srgb, #6fd17a 45%, transparent);
    border-radius: 999px;
    padding: 2px 9px;
}

.modal-check-btn {
    padding: 15px 24px;
    font-size: 13px;
    letter-spacing: .5px;
    text-transform: uppercase;
    white-space: nowrap;
}

.modal-check-btn:disabled {
    opacity: .6;
    cursor: not-allowed;
    transform: none;
}

.modal-agreement {
    font-size: 12px;
    line-height: 1.5;
    color: var(--text-faint);
    text-align: center;
}

/* ---------- Адаптивность ---------- */
@media (max-width: 760px) {
    .shop {
        grid-template-columns: 1fr;
    }

    .panel {
        min-height: 0;
    }

    .hero-title {
        line-height: 1.8;
    }
}

/* ---------- Уважаем prefers-reduced-motion ---------- */
@media (prefers-reduced-motion: reduce) {
    .spark,
    .sparkle-deco {
        animation: none;
    }

    html {
        scroll-behavior: auto;
    }
}

/* ==========================================================================
   Добавлено: IP сервера, согласие с офертой, футер, страницы документов
   ========================================================================== */
.server-ip {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    padding: 10px 18px;
    background: var(--panel);
    border: 1px solid var(--panel-line);
    border-radius: 10px;
    color: var(--text);
    font: 500 15px 'Rubik', sans-serif;
    cursor: pointer;
    transition: border-color .15s ease, box-shadow .15s ease;
}
.server-ip:hover,
.server-ip:focus-visible {
    border-color: var(--orange);
    box-shadow: 0 0 16px color-mix(in srgb, var(--orange) 30%, transparent);
    outline: none;
}
.server-ip-label { color: var(--text-dim); font-size: 13px; }
.server-ip-value { color: var(--orange-bright); font-weight: 600; letter-spacing: .02em; }
.server-ip-hint {
    font-size: 11px;
    color: var(--text-faint);
    border-left: 1px solid var(--panel-line);
    padding-left: 12px;
}
.hero-sub {
    margin-top: 16px;
    font-size: 14px;
    color: var(--text-dim);
}

.modal-field input.invalid { border-color: #e2453a; }
.modal-field input.valid   { border-color: #4caf50; }

.modal-agree {
    display: flex;
    gap: 10px;
    align-items: flex-start;
    font-size: 12px;
    line-height: 1.5;
    color: var(--text-dim);
    cursor: pointer;
    text-align: left;
}
.modal-agree input {
    margin-top: 2px;
    width: 16px;
    height: 16px;
    flex-shrink: 0;
    accent-color: var(--orange);
}
.modal-agree a,
.footer-links a,
.doc a { color: var(--orange-bright); }

.load-error {
    color: var(--text-dim);
    text-align: center;
    padding: 24px 0;
}

.site-footer {
    position: relative;
    z-index: 1;
    width: 100%;
    max-width: 1080px;
    margin: 0 auto;
    padding: 0 24px 40px;
    text-align: center;
    font-size: 13px;
    color: var(--text-faint);
}
.footer-links {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 8px 24px;
    margin-bottom: 12px;
}
.footer-links a { color: var(--text-dim); text-decoration: none; }
.footer-links a:hover { color: var(--orange-bright); }

/* Страницы документов и статуса оплаты */
.doc {
    position: relative;
    z-index: 1;
    width: 100%;
    max-width: 820px;
    margin: 0 auto;
    padding: 48px 24px;
}
.doc-back {
    display: inline-block;
    margin-bottom: 24px;
    color: var(--text-dim) !important;
    text-decoration: none;
    font-size: 14px;
}
.doc-back:hover { color: var(--orange-bright) !important; }
.doc .panel { padding: 32px; min-height: 0; }
.doc h1 {
    font-family: 'Rubik', sans-serif;
    font-size: clamp(16px, 3vw, 22px);
    line-height: 1.6;
    margin-bottom: 8px;
}
.doc .doc-date { color: var(--text-faint); font-size: 13px; margin-bottom: 24px; }
.doc h2 { font-size: 17px; margin: 28px 0 10px; color: var(--orange-bright); }
.doc p, .doc li { font-size: 15px; line-height: 1.65; color: var(--text); }
.doc p + p { margin-top: 10px; }
.doc ul, .doc ol { padding-left: 22px; margin: 8px 0; }
.doc li + li { margin-top: 6px; }
.doc .fill { background: color-mix(in srgb, var(--orange) 18%, transparent); padding: 0 4px; border-radius: 4px; }

.status-box { text-align: center; }
.status-icon { font-size: 44px; margin-bottom: 12px; color: var(--orange); }
.status-box p { color: var(--text-dim); }
.status-box .btn { margin-top: 24px; display: inline-block; text-decoration: none; }

@media (max-width: 760px) {
    .server-ip { flex-wrap: wrap; justify-content: center; }
    .doc .panel { padding: 22px; }
}

/* ==========================================================================
   Доработки 12.10: сроки с ценой, поддержка, иконки, мобильная версия
   ========================================================================== */

/* ---- Иконки предметов крупнее ---- */
.item-slot { width: 38px; height: 38px; border-radius: 8px; }
.item-slot svg { width: 30px; height: 30px; }

/* ---- Выбор срока: карточки с ценой и выгодой ---- */
.term-row { flex-direction: column; align-items: stretch; gap: 10px; }
.term-options {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 10px;
}
.term-btn {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 4px;
    padding: 12px 12px 11px;
    border: 1px solid var(--panel-line);
    border-radius: 10px;
    background: var(--panel-soft);
    text-align: left;
    transition: border-color .15s ease, box-shadow .2s ease, background .2s ease;
}
.term-btn:hover { border-color: var(--orange-dim); color: var(--text); }
.term-btn.active {
    border-color: var(--orange);
    background: color-mix(in srgb, var(--orange) 9%, var(--panel-soft));
    box-shadow: 0 0 14px color-mix(in srgb, var(--orange) 28%, transparent);
}
.term-btn:focus-visible { outline: 2px solid var(--orange-bright); outline-offset: 2px; }
.term-name { font-size: 13px; color: var(--text-dim); }
.term-price { font-size: 17px; font-weight: 700; color: var(--text); font-variant-numeric: tabular-nums; }
.term-btn.active .term-price { color: var(--orange-bright); }
.term-badge {
    position: absolute;
    top: -9px;
    right: 8px;
    font-size: 11px;
    font-weight: 700;
    line-height: 1;
    padding: 4px 7px;
    border-radius: 999px;
    color: #0d0d0d;
    background: #6fd17a;
}
.term-badge.hot { background: var(--orange); }

/* ---- Поддержка ---- */
.support-chip {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin-top: 18px;
    padding: 9px 16px;
    border: 1px solid var(--panel-line);
    border-radius: 999px;
    background: var(--panel);
    color: var(--text-dim);
    font-size: 14px;
    text-decoration: none;
    transition: border-color .15s ease, color .15s ease;
}
.support-chip strong { color: var(--orange-bright); font-weight: 600; }
.support-chip:hover { border-color: var(--orange-dim); color: var(--text); }
.footer-support { margin: 10px 0 6px; color: var(--text-dim); }
.footer-support a, .modal-support a { color: var(--orange-bright); text-decoration: none; }
.footer-support a:hover, .modal-support a:hover { text-decoration: underline; }
.modal-support {
    margin-top: 14px;
    padding-top: 12px;
    border-top: 1px solid var(--panel-line);
    font-size: 12px;
    line-height: 1.5;
    color: var(--text-dim);
    text-align: center;
}

/* ---- Телефон ---- */
@media (max-width: 760px) {
    .container { padding: 32px 16px; }
    .hero { margin-bottom: 32px; }
    .sparkle-deco { display: none; }
    .panel { padding: 20px 16px; }

    .term-options { gap: 8px; }
    .term-btn { padding: 11px 9px 10px; }
    .term-price { font-size: 15px; }

    /* Цена и кнопка прилипают к низу экрана, пока видно описание товара */
    .purchase-row {
        position: sticky;
        bottom: 0;
        z-index: 5;
        flex-wrap: nowrap;
        margin: 18px -16px -20px;
        padding: 12px 16px calc(12px + env(safe-area-inset-bottom, 0px));
        background: var(--panel);
        border-radius: 0 0 12px 12px;
        box-shadow: 0 -10px 20px rgba(0, 0, 0, .45);
    }
    .buy-btn { flex: 1; max-width: 220px; padding: 14px 16px; }

    .modal { padding-left: 18px; padding-right: 18px; }
    .modal-bottom { flex-wrap: wrap; }
    .modal-check-btn { flex: 1; }
}

/* Окна «Выберите товар» и «Подробнее» одной высоты для всех товаров */
.shop .panel { min-height: max(540px, var(--panel-h, 0px)); }
.hero { margin-bottom: 40px; }
.support-chip { margin-top: 4px; }
@media (max-width: 760px) { .shop .panel { min-height: 0; } }

/* Заголовок — только название сервера */
.hero-title { font-size: clamp(30px, 6vw, 56px); margin-bottom: 22px; }

/* ---------- Верхняя панель: логотип и меню ---------- */
.topbar {
    position: relative;
    z-index: 2;
    width: 100%;
    max-width: 1080px;
    margin: 0 auto;
    padding: 20px 24px 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    flex-wrap: wrap;
}
.brand {
    font-family: 'Rubik', sans-serif;
    font-size: 15px;
    color: var(--orange);
    text-decoration: none;
    text-shadow: 2px 2px 0 #000, 0 0 14px color-mix(in srgb, var(--orange) 45%, transparent);
}
.topnav { display: flex; gap: 6px; flex-wrap: wrap; }
.topnav a {
    padding: 8px 14px;
    border: 1px solid transparent;
    border-radius: 8px;
    color: var(--text-dim);
    font-size: 14px;
    font-weight: 500;
    text-decoration: none;
    transition: color .15s ease, border-color .15s ease, background .15s ease;
}
.topnav a:hover { color: var(--text); background: var(--panel); }
.topnav a.active {
    color: var(--orange-bright);
    border-color: var(--orange-dim);
    background: var(--panel);
}
.topnav a:focus-visible, .brand:focus-visible { outline: 2px solid var(--orange-bright); outline-offset: 2px; }

/* ---------- Правила ---------- */
.doc ol.rules { list-style: none; padding-left: 0; }
.doc ol.rules li { padding-left: 0; }
.doc ol.rules b { color: var(--orange-bright); font-weight: 600; margin-right: 6px; font-variant-numeric: tabular-nums; }
.doc ol.rules.sub { margin: 6px 0 2px 18px; }
.doc .rules-note {
    margin: 10px 0;
    padding: 10px 14px;
    border-left: 2px solid var(--orange-dim);
    background: var(--panel-soft);
    border-radius: 0 8px 8px 0;
    font-size: 14px;
    color: var(--text-dim);
}
.doc a { color: var(--orange-bright); }

@media (max-width: 760px) {
    .topbar { padding: 14px 16px 0; justify-content: center; }
    .brand { font-size: 13px; }
    .topnav a { padding: 7px 11px; font-size: 13px; }
}

/* Логотип обычным шрифтом */
.brand {
    font-family: 'Rubik', sans-serif;
    font-size: 20px;
    font-weight: 700;
    letter-spacing: .3px;
    text-shadow: 0 0 16px color-mix(in srgb, var(--orange) 40%, transparent);
}
.doc h1 { font-size: clamp(22px, 4vw, 28px); font-weight: 700; line-height: 1.3; }

/* ---------- Раскрывающиеся разделы правил ---------- */
.rule-sec {
    margin-top: 12px;
    border: 1px solid var(--panel-line);
    border-radius: 10px;
    background: var(--panel-soft);
}
.rule-sec + h2 { margin-top: 28px; }
.rule-sec summary {
    list-style: none;
    cursor: pointer;
    padding: 14px 16px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    font-size: 17px;
    font-weight: 600;
    color: var(--orange-bright);
    border-radius: 10px;
    transition: background .15s ease;
}
.rule-sec summary::-webkit-details-marker { display: none; }
.rule-sec summary::after {
    content: '';
    width: 9px;
    height: 9px;
    border-right: 2px solid currentColor;
    border-bottom: 2px solid currentColor;
    transform: rotate(45deg) translateY(-3px);
    transition: transform .2s ease;
    flex-shrink: 0;
}
.rule-sec[open] summary::after { transform: rotate(225deg) translate(-2px, -1px); }
.rule-sec summary:hover { background: color-mix(in srgb, var(--orange) 6%, transparent); }
.rule-sec summary:focus-visible { outline: 2px solid var(--orange-bright); outline-offset: 2px; }
.rule-sec > ol, .rule-sec > .rules-note { margin: 8px 16px 14px !important; }
.rule-sec[open] > ol { animation: none; }
@keyframes rule-open { from { opacity: 0; transform: translateY(-4px); } to { opacity: 1; transform: none; } }

/* Заголовок правил по центру */
.doc-centered-title h1, .doc-centered-title .doc-date { text-align: center; }

/* ---------- Бонус к коинам ---------- */
.bonus-tiers { display: grid; gap: 8px; margin: 14px 0 18px; }
.bonus-tier {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 14px;
    border: 1px solid var(--panel-line);
    border-radius: 10px;
    background: var(--panel-soft);
    font-size: 14px;
    color: var(--text-dim);
}
.bonus-tier b { color: var(--text); font-variant-numeric: tabular-nums; }
.bonus-pct {
    min-width: 52px;
    text-align: center;
    padding: 4px 8px;
    border-radius: 999px;
    background: color-mix(in srgb, #6fd17a 16%, transparent);
    border: 1px solid color-mix(in srgb, #6fd17a 45%, transparent);
    color: #6fd17a;
    font-weight: 700;
    font-size: 13px;
}
.quick-amounts {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 8px;
    margin-top: 12px;
}
.quick-btn {
    position: relative;
    padding: 9px 4px;
    border: 1px solid var(--panel-line);
    border-radius: 8px;
    background: transparent;
    color: var(--text);
    font: 600 14px 'Rubik', sans-serif;
    cursor: pointer;
    font-variant-numeric: tabular-nums;
    transition: border-color .15s ease, color .15s ease;
}
.quick-btn span {
    position: absolute;
    top: -8px;
    right: -4px;
    padding: 2px 5px;
    border-radius: 999px;
    background: #6fd17a;
    color: #0d0d0d;
    font-size: 10px;
    font-weight: 700;
    line-height: 1.2;
}
.quick-btn:hover { border-color: var(--orange-dim); }
.quick-btn.active { border-color: var(--orange); color: var(--orange-bright); }
.quick-btn:focus-visible { outline: 2px solid var(--orange-bright); outline-offset: 2px; }
.modal-bonus {
    min-height: 20px;
    margin-top: 12px;
    font-size: 13px;
    line-height: 1.5;
    text-align: center;
    color: var(--text-dim);
}
.modal-bonus b { color: var(--orange-bright); }
.modal-bonus.got { color: #6fd17a; }

/* Документы (правила и др.) по центру экрана по вертикали, если они короче экрана */
main.doc { margin: auto; }

/* ---------- Что может выпасть из кейса ---------- */
.drops:empty { display: none; }
.drops { margin: 14px 0 20px; }
.drops .features-title { margin-bottom: 10px; }
.drop-privs { display: grid; gap: 8px; }
.drop-priv {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 8px 12px;
    border: 1px solid var(--panel-line);
    border-radius: 10px;
    background: var(--panel-soft);
}
.drop-priv .item-slot { width: 32px; height: 32px; }
.drop-priv .item-slot svg { width: 24px; height: 24px; }
.drop-name { flex: 1; font-weight: 500; font-size: 14px; }
.drop-terms { display: flex; gap: 6px; flex-wrap: wrap; justify-content: flex-end; }
.drop-terms span {
    font-size: 12px;
    padding: 3px 8px;
    border-radius: 999px;
    border: 1px solid var(--panel-line);
    color: var(--text-dim);
    white-space: nowrap;
}
.drop-tals { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.drop-tal {
    padding: 10px 12px;
    border: 1px solid var(--panel-line);
    border-radius: 10px;
    background: var(--panel-soft);
    min-width: 0;
}
.drop-tal-name { font-weight: 700; font-size: 14px; margin-bottom: 4px; }
.drop-tal-lore { font-size: 12px; line-height: 1.4; color: var(--text-faint); margin-bottom: 8px; }
.drop-tal ul { list-style: none; display: grid; gap: 3px; }
.drop-tal li { font-size: 12.5px; line-height: 1.35; }
.drop-tal li.good { color: #7fb2ff; }
.drop-tal li.bad { color: #ff6b6b; }
@media (max-width: 760px) {
    .drop-tals { grid-template-columns: 1fr; }
    .drop-terms span { padding: 3px 6px; }
}

/* Талисманы: только названия, сетка 2×2 */
.drop-tals { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.drop-tal { display: flex; align-items: center; gap: 10px; padding: 12px 14px; }
.drop-tal-dot { width: 8px; height: 8px; border-radius: 2px; flex-shrink: 0; box-shadow: 0 0 8px currentColor; }
.drop-tal-name { margin: 0; font-size: 14px; }
@media (max-width: 760px) { .drop-tals { grid-template-columns: 1fr; } }

/* Плавный переход между страницами (Edge/Chrome) и магазин без прыжков при загрузке */
@view-transition { navigation: auto; }
::view-transition-old(root), ::view-transition-new(root) { animation-duration: .18s; }
#shopSection { transition: opacity .18s ease; }
#shopSection:not(.ready) { opacity: 0; }

/* Без декоративных значков */
.sparkle-deco, .prefix-icon { display: none !important; }

.bg-glow, .sparks { bottom: auto; height: 100vh; height: 100lvh; transform: translateZ(0); }
.shop-right { scroll-margin-top: 12px; }
