/* ==== 01-variables.css ==== */
/* Переменные темы: цвета, скругления, тени, шрифты.
   Основные цвета (primary / secondary / accent) удобнее менять в админке → Настройки → «Цвета сайта».
   Здесь — остальное: фон, поверхности, текст, радиусы, ширина контейнера. */

:root {
  --bg: #0b0d17;
  --bg-2: #0f1222;
  --surface: #141831;
  --surface-2: #1b2040;
  --surface-3: #232a52;
  --border: rgba(255, 255, 255, .08);
  --border-2: rgba(255, 255, 255, .14);
  --text: #eceefb;
  --text-2: #c5c9e6;
  --muted: #8e94b8;
  --primary: #7c5cff;
  --primary-2: #22d3ee;
  --primary-ink: #ffffff;
  --accent: #ff5c8a;
  --success: #22c55e;
  --warning: #f59e0b;
  --danger: #ef4444;
  --grad: linear-gradient(135deg, var(--primary) 0%, color-mix(in srgb, var(--primary) 50%, var(--primary-2)) 60%, var(--primary-2) 100%);
  --grad-soft: linear-gradient(135deg, color-mix(in srgb, var(--primary) 16%, transparent), color-mix(in srgb, var(--primary-2) 10%, transparent));
  --shadow: 0 8px 24px -14px rgba(0, 0, 0, .55);
  --shadow-lg: 0 24px 60px -20px rgba(0, 0, 0, .7);
  --glow: 0 8px 26px -10px color-mix(in srgb, var(--primary) 70%, transparent);
  --r-sm: 10px;
  --r: 14px;
  --r-lg: 20px;
  --header-h: 60px;
  --bottom-h: 64px;
  --container: 1140px;
  --font: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif;
  --mono: ui-monospace, "SF Mono", "JetBrains Mono", Menlo, Consolas, monospace;
  color-scheme: dark;
}
:root[data-theme="light"] {
  --bg: #f4f5fb;
  --bg-2: #eceef7;
  --surface: #ffffff;
  --surface-2: #f1f2fa;
  --surface-3: #e5e7f4;
  --border: rgba(20, 24, 60, .09);
  --border-2: rgba(20, 24, 60, .16);
  --text: #12152a;
  --text-2: #2c3157;
  --muted: #61678c;
  --shadow: 0 8px 24px -16px rgba(30, 35, 90, .3);
  --shadow-lg: 0 24px 60px -24px rgba(30, 35, 90, .35);
  --grad-soft: linear-gradient(135deg, color-mix(in srgb, var(--primary) 10%, transparent), color-mix(in srgb, var(--primary-2) 8%, transparent));
  color-scheme: light;
}

/* ==== 02-base.css ==== */
/* База: сброс стилей, типографика, контейнер, служебные классы (.muted, .small …). */

/* ---------- База ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 64px); }
body {
  margin: 0; font-family: var(--font); font-size: 16px; line-height: 1.5; color: var(--text); background: var(--bg);
  min-height: 100vh; min-height: 100dvh; display: flex; flex-direction: column;
  -webkit-font-smoothing: antialiased; -webkit-tap-highlight-color: transparent;
  padding-bottom: calc(var(--bottom-h) + env(safe-area-inset-bottom)); overflow-x: hidden;
}
body.no-bottom-nav { padding-bottom: 0; }
@media (min-width: 960px) { body { padding-bottom: 0; } }
img, svg { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
p { margin: 0 0 .75em; }
h1, h2, h3, h4 { margin: 0 0 .5em; line-height: 1.2; letter-spacing: -.015em; font-weight: 800; text-wrap: balance; }
h1 { font-size: clamp(1.6rem, 5vw, 2.4rem); }
h2, .h2 { font-size: clamp(1.3rem, 3.6vw, 1.7rem); }
h3, .h3 { font-size: 1.1rem; }
code { font-family: var(--mono); font-size: .9em; background: var(--surface-2); padding: .1em .4em; border-radius: 6px; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
[hidden] { display: none !important; }
::selection { background: color-mix(in srgb, var(--primary) 40%, transparent); }
:focus-visible { outline: 2px solid var(--primary-2); outline-offset: 2px; border-radius: 6px; }
.icon { width: 1.2em; height: 1.2em; flex: none; }
.container { width: 100%; max-width: var(--container); margin: 0 auto; padding: 0 16px; }
.container.narrow, .narrow { max-width: 780px; }
.narrow-inner { max-width: 560px; margin-left: auto; margin-right: auto; }
.site-main { flex: 1; }
.muted { color: var(--muted); }
.small { font-size: .85rem; }
.center { text-align: center; display: flex; justify-content: center; }
.text-success { color: var(--success); }
.text-danger { color: var(--danger); }
.error-text { color: var(--danger); font-size: .88rem; margin: 0 0 10px; }
.skip-link { position: absolute; left: -999px; top: 8px; background: var(--primary); color: #fff; padding: 8px 14px; border-radius: 8px; z-index: 100; }
.skip-link:focus { left: 8px; }
.hp { position: absolute !important; left: -10000px; width: 1px; height: 1px; overflow: hidden; }

/* ==== 03-buttons.css ==== */
/* Кнопки: .btn, .btn-primary, .btn-ghost, .icon-btn … */

/* ---------- Кнопки ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5em;
  min-height: 46px; padding: 0 18px; border-radius: 12px; border: 1px solid transparent;
  font-weight: 700; font-size: .95rem; line-height: 1; white-space: nowrap;
  transition: transform .15s ease, box-shadow .2s ease, background .2s ease, border-color .2s ease, opacity .2s;
  user-select: none; touch-action: manipulation;
}
.btn:active { transform: scale(.98); }
.btn:disabled { opacity: .45; pointer-events: none; }
/* border-box: градиент рисуется и под прозрачной рамкой — иначе он повторяется и у края видна полоска другого цвета */
.btn-primary { background: var(--grad) border-box; color: var(--primary-ink); box-shadow: var(--glow); }
.btn-ghost { background: var(--surface-2); border-color: var(--border); color: var(--text); }
.btn-ghost:hover { border-color: var(--border-2); }
.btn-danger { background: rgba(239, 68, 68, .14); color: #ff8a8a; border-color: rgba(239, 68, 68, .35); }
.btn-sm { min-height: 38px; padding: 0 12px; border-radius: 10px; font-size: .88rem; }
.btn-lg { min-height: 54px; padding: 0 22px; border-radius: 14px; font-size: 1.02rem; }
.btn-block { width: 100%; }
.btn.loading { pointer-events: none; opacity: .75; }
.icon-btn {
  display: inline-grid; place-items: center; min-width: 40px; height: 40px; padding: 0 8px; border-radius: 11px;
  background: var(--surface-2); border: 1px solid var(--border); color: var(--text-2); font-weight: 800; font-size: .8rem;
}
.icon-btn:hover { color: var(--text); border-color: var(--border-2); }
.link-more { display: inline-flex; align-items: center; gap: .35em; color: var(--primary-2); font-weight: 700; font-size: .9rem; }
.link-more .icon { width: 1.05em; height: 1.05em; }

/* ==== 04-forms.css ==== */
/* Формы: поля ввода, подписи, чекбоксы, степпер количества. */

/* ---------- Формы ---------- */
.form { display: flex; flex-direction: column; gap: 4px; }
.field { margin: 0 0 14px; border: 0; padding: 0; min-width: 0; }
.field > label, .field > legend { display: block; font-weight: 700; font-size: .88rem; margin-bottom: 6px; color: var(--text-2); padding: 0; }
.input {
  width: 100%; min-height: 48px; padding: 0 14px; border-radius: 12px; background: var(--bg-2);
  border: 1px solid var(--border-2); color: var(--text); font-size: 16px;
  transition: border-color .2s, box-shadow .2s; -webkit-appearance: none; appearance: none;
}
textarea.input { padding: 12px 14px; min-height: 120px; resize: vertical; line-height: 1.5; }
select.input { background-image: linear-gradient(45deg, transparent 50%, var(--muted) 50%), linear-gradient(135deg, var(--muted) 50%, transparent 50%); background-position: calc(100% - 20px) 50%, calc(100% - 15px) 50%; background-size: 5px 5px; background-repeat: no-repeat; padding-right: 36px; }
.input:focus { outline: none; border-color: var(--primary); box-shadow: 0 0 0 4px color-mix(in srgb, var(--primary) 20%, transparent); }
.input:user-invalid { border-color: var(--danger); }
.input-lg { min-height: 56px; font-size: 1.25rem; font-weight: 800; }
.input-code { font-family: var(--mono); font-size: 1.5rem !important; letter-spacing: .4em; text-align: center; font-weight: 800; }
.input-icon { position: relative; }
.input-icon > .icon { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); color: var(--muted); pointer-events: none; }
.input-icon .input { padding-left: 44px; }
.help { font-size: .8rem; color: var(--muted); margin: 6px 0 0; }
.check { display: flex; gap: 10px; align-items: flex-start; font-size: .88rem; color: var(--text-2); margin: 4px 0 14px; cursor: pointer; }
.check input { width: 20px; height: 20px; margin: 1px 0 0; accent-color: var(--primary); flex: none; }
.check a { color: var(--primary-2); text-decoration: underline; text-underline-offset: 2px; }
.stepper { display: flex; gap: 8px; align-items: center; }
.stepper .input { text-align: center; font-weight: 800; font-size: 1.1rem; }
.stepper .icon-btn { width: 48px; height: 48px; flex: none; }
.quick-amounts { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 10px; }

/* ==== 05-cards.css ==== */
/* Карточки, уведомления (alert), пустые состояния, заголовки страниц. */

/* ---------- Карточки, алерты, пустые состояния ---------- */
.card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--r-lg); padding: 18px; }
.card + .card { margin-top: 14px; }
.card-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 12px; }
.card-head h2, .card-head .h3 { display: flex; align-items: center; gap: 8px; margin: 0; }
.card-head .icon { color: var(--primary-2); }
@media (min-width: 720px) { .card { padding: 22px; } }
.alert { display: flex; align-items: flex-start; gap: 10px; padding: 12px 14px; border-radius: 12px; border: 1px solid; font-weight: 600; font-size: .92rem; margin-bottom: 12px; }
.alert .icon { margin-top: 1px; }
.alert-success { background: rgba(34, 197, 94, .1); border-color: rgba(34, 197, 94, .3); color: #6ee7a0; }
.alert-error { background: rgba(239, 68, 68, .1); border-color: rgba(239, 68, 68, .32); color: #ff9b9b; }
.alert-info { background: color-mix(in srgb, var(--primary-2) 8%, transparent); border-color: color-mix(in srgb, var(--primary-2) 25%, transparent); color: #8be9f8; }
[data-theme="light"] .alert-success { color: #15803d; }
[data-theme="light"] .alert-error { color: #b91c1c; }
[data-theme="light"] .alert-info { color: #0e7490; }
.alert-action { align-items: center; flex-wrap: wrap; }
.alert-action span { flex: 1; min-width: 180px; }
.flash-wrap { padding-top: 14px; }
.info-card { display: flex; gap: 14px; align-items: flex-start; }
.info-card > .icon { width: 26px; height: 26px; color: var(--primary-2); }
.info-card p { margin: 0; }
.empty { display: flex; flex-direction: column; align-items: center; gap: 10px; padding: 36px 16px; text-align: center; color: var(--muted); }
.empty .icon { width: 40px; height: 40px; opacity: .6; }
.empty-sm { padding: 20px; border: 1px dashed var(--border-2); border-radius: var(--r); }
.tag { display: inline-flex; align-items: center; gap: 5px; font-size: .78rem; font-weight: 700; color: var(--muted); }
.tag .icon { width: 1em; height: 1em; }
.dot { width: 8px; height: 8px; border-radius: 50%; background: var(--muted); display: inline-block; flex: none; }
.dot-live { background: var(--success); animation: pulse 2s infinite; }
.section-title { display: flex; align-items: center; gap: 10px; font-size: 1.15rem; margin: 22px 0 12px; }
.section-title .icon { color: var(--primary-2); }
.section-sm { padding: 14px 0; }
.page-hero { padding: 26px 0 14px; }
.page-hero.compact { padding: 22px 0 8px; }
.page-hero h1 { margin-bottom: 6px; }
@media (min-width: 720px) { .page-hero { padding: 40px 0 20px; } }
.eyebrow { display: inline-flex; align-items: center; gap: 7px; padding: 5px 11px; border-radius: 99px; background: var(--surface); border: 1px solid var(--border); color: var(--text-2); font-size: .78rem; font-weight: 700; margin-bottom: 10px; }
.eyebrow .icon { width: 1em; height: 1em; color: var(--primary-2); }

/* ==== 10-header.css ==== */
/* Шапка сайта — theme/parts/header.php (+ объявление и подсказка языка из theme/layout.php). */

/* ---------- Шапка ---------- */
.announcement { background: var(--grad); color: #fff; font-size: .86rem; font-weight: 600; }
.announcement .container { display: flex; align-items: center; gap: 8px; padding-top: 7px; padding-bottom: 7px; }
.lang-suggest { background: var(--surface-2); border-bottom: 1px solid var(--border); font-size: .86rem; font-weight: 600; }
.lang-suggest .container { display: flex; align-items: center; gap: 10px; padding-top: 6px; padding-bottom: 6px; }
.lang-suggest .container > span { flex: 1; }
.lang-suggest .icon-btn { width: 34px; height: 34px; }
.site-header {
  position: sticky; top: 0; z-index: 40; height: var(--header-h);
  background: color-mix(in srgb, var(--bg) 82%, transparent);
  backdrop-filter: saturate(160%) blur(14px); -webkit-backdrop-filter: saturate(160%) blur(14px);
  border-bottom: 1px solid var(--border);
}
.header-inner { height: 100%; display: flex; align-items: center; gap: 10px; }
.brand { display: inline-flex; align-items: center; gap: 9px; font-weight: 900; font-size: 1.1rem; letter-spacing: -.02em; }
.brand-name { background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.main-nav { display: none; gap: 2px; margin-left: 14px; }
.main-nav a { padding: 8px 12px; border-radius: 10px; color: var(--text-2); font-weight: 650; font-size: .93rem; white-space: nowrap; }
.main-nav a:hover { color: var(--text); background: var(--surface-2); }
.main-nav a.active { color: var(--text); background: var(--surface-2); }
.header-actions { margin-left: auto; display: flex; align-items: center; gap: 8px; }
.online-pill { display: inline-flex; align-items: center; gap: 7px; height: 40px; padding: 0 12px; border-radius: 11px; background: var(--surface-2); border: 1px solid var(--border); font-size: .85rem; }
.online-pill b { font-variant-numeric: tabular-nums; }
.online-pill[data-status="offline"] .dot-live { background: var(--danger); animation: none; }
.online-pill[data-status="unknown"] .dot-live { background: var(--muted); animation: none; }
.online-label { color: var(--muted); font-weight: 600; display: none; }
.header-cabinet { gap: 8px; display: inline-flex; align-items: center; justify-content: center; } /* иконка по центру кнопки, с ником — рядом */
.cab-name { display: none; max-width: 110px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: .88rem; }
.lang-code { font-size: .78rem; font-weight: 800; letter-spacing: .03em; }
@media (min-width: 420px) { .online-label { display: inline; } }
@media (min-width: 720px) { .cab-name { display: inline; } }
@media (min-width: 960px) { .main-nav { display: flex; } }
.theme-toggle .icon-sun, [data-theme-toggle] .icon-sun { display: none; }
[data-theme="light"] [data-theme-toggle] .icon-sun { display: block; }
[data-theme="light"] [data-theme-toggle] .icon-moon { display: none; }
.dropdown { position: relative; }
.dropdown summary { list-style: none; cursor: pointer; }
.dropdown summary::-webkit-details-marker { display: none; }
.dropdown-menu { position: absolute; right: 0; top: calc(100% + 8px); min-width: 160px; padding: 6px; background: var(--surface); border: 1px solid var(--border-2); border-radius: 12px; box-shadow: var(--shadow-lg); animation: pop .16s ease; z-index: 5; }
.dropdown-menu a { display: block; padding: 10px 12px; border-radius: 9px; font-weight: 600; color: var(--text-2); }
.dropdown-menu a:hover, .dropdown-menu a.active { background: var(--surface-2); color: var(--text); }

/* ==== 11-bottom-nav.css ==== */
/* Нижняя панель на телефоне и меню «Ещё» — theme/parts/bottom-nav.php, theme/parts/menu-sheet.php. */

/* ---------- Нижняя навигация (телефоны) ---------- */
.bottom-nav {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 45;
  height: calc(var(--bottom-h) + env(safe-area-inset-bottom)); padding: 6px 4px env(safe-area-inset-bottom);
  display: grid; grid-template-columns: repeat(5, 1fr);
  background: color-mix(in srgb, var(--surface) 92%, transparent);
  backdrop-filter: saturate(160%) blur(16px); -webkit-backdrop-filter: saturate(160%) blur(16px);
  border-top: 1px solid var(--border);
}
.bottom-nav a, .bottom-nav button { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; padding: 0; background: none; border: 0; color: var(--muted); font-size: .7rem; font-weight: 700; }
.bn-icon { display: grid; place-items: center; width: 46px; height: 30px; border-radius: 10px; }
.bn-icon .icon { width: 22px; height: 22px; }
.bottom-nav .active { color: var(--text); }
.bottom-nav .active .bn-icon { background: var(--grad-soft); color: var(--primary-2); }
@media (min-width: 960px) { .bottom-nav { display: none; } }

/* Меню «Ещё» */
.menu-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin-bottom: 14px; }
.menu-tile {
  display: flex; flex-direction: column; align-items: center; gap: 8px; padding: 16px 8px; text-align: center;
  border-radius: 16px; background: var(--surface-2); border: 1px solid var(--border); font-weight: 700; font-size: .85rem;
}
.menu-tile:active { transform: scale(.97); }
.menu-tile .icon { width: 26px; height: 26px; color: var(--primary-2); }
.menu-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px 0; border-top: 1px solid var(--border); }
.seg { display: inline-flex; background: var(--surface-2); border: 1px solid var(--border); border-radius: 12px; padding: 3px; }
.seg a { padding: 7px 12px; border-radius: 9px; font-weight: 800; font-size: .85rem; color: var(--muted); }
.seg a.active { background: var(--grad); color: #fff; }
.menu-links { margin: 6px 0 0; text-align: center; }
.menu-links a { text-decoration: underline; text-underline-offset: 2px; }

/* ==== 20-server-hero.css ==== */
/* Главная: карточка сервера с IP и кнопкой «Играть» — верх theme/pages/shop.php. */

/* ---------- Шапка магазина: сервер, IP, «Играть» ---------- */
.server-hero { padding: 14px 0 4px; }
.sh-card {
  display: flex; flex-direction: column; gap: 12px; padding: 14px; border-radius: var(--r-lg);
  background: radial-gradient(120% 140% at 0% 0%, color-mix(in srgb, var(--primary) 22%, transparent), transparent 55%), var(--surface);
  border: 1px solid var(--border);
}
.sh-main { display: flex; align-items: center; gap: 12px; min-width: 0; }
.sh-logo img { width: 44px; height: 44px; }
.sh-text { min-width: 0; }
.sh-title { font-size: 1.25rem; margin: 0; }
.sh-title span { display: block; font-size: .88rem; font-weight: 650; color: var(--text-2); letter-spacing: 0; }
.sh-sub { margin: 1px 0 0; color: var(--muted); font-size: .8rem; }
.sh-actions { display: flex; gap: 8px; }
.ip-chip {
  flex: 1; min-width: 0; display: flex; align-items: center; gap: 6px; min-height: 48px; padding: 0 12px; border-radius: 12px;
  background: var(--bg-2); border: 1px dashed var(--border-2); font-size: .95rem; text-align: left;
}
.ip-chip-text { flex: 1; display: flex; flex-direction: column; min-width: 0; line-height: 1.2; }
.ip-chip-label { font-size: .7rem; font-weight: 700; color: var(--muted); }
.ip-chip-value { font-weight: 800; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ip-chip .icon { color: var(--muted); }
.ip-chip.copied { border-color: var(--success); border-style: solid; }
.ip-chip.copied .icon { color: var(--success); }
.sh-play { min-height: 48px; padding: 0 16px; }
@media (min-width: 760px) {
  .server-hero { padding-top: 22px; }
  .sh-card { flex-direction: row; align-items: center; justify-content: space-between; padding: 18px 22px; }
  .sh-title { font-size: 1.6rem; }
  .sh-actions { flex: 0 1 520px; }
}

/* ==== 21-promo.css ==== */
/* Акции: баннеры на главной, бонус при пополнении — theme/pages/shop.php, theme/pages/cabinet/topup.php. */

/* ---------- Акции ---------- */
.promo-banners { display: flex; gap: 8px; padding-top: 10px; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; }
.promo-banners::-webkit-scrollbar { display: none; }
.promo-banners > .promo-banner { flex: 0 0 calc(100% - 28px); scroll-snap-align: start; }
.promo-banners > .promo-banner:only-child { flex-basis: 100%; }
@media (min-width: 760px) { .promo-banners { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); overflow: visible; } }
.promo-banner {
  display: flex; align-items: center; gap: 12px; padding: 12px 14px; border-radius: var(--r);
  background: linear-gradient(120deg, color-mix(in srgb, var(--accent) 22%, transparent), color-mix(in srgb, var(--primary) 18%, transparent)); border: 1px solid color-mix(in srgb, var(--accent) 35%, transparent);
}
.pb-icon { display: grid; place-items: center; width: 38px; height: 38px; border-radius: 12px; background: linear-gradient(135deg, var(--accent), var(--warning)); color: #fff; flex: none; }
.pb-text { flex: 1; min-width: 0; display: flex; flex-direction: column; line-height: 1.25; }
.pb-text small { color: var(--text-2); font-size: .8rem; }
.pb-timer { flex: none; font-size: .78rem; font-weight: 800; font-variant-numeric: tabular-nums; color: #ffb3c8; text-align: right; max-width: 92px; }
[data-theme="light"] .pb-timer { color: #be123c; }
.bonus-box { display: flex; gap: 12px; align-items: flex-start; padding: 12px 14px; margin: 4px 0 14px; border-radius: var(--r); background: linear-gradient(120deg, color-mix(in srgb, var(--accent) 16%, transparent), color-mix(in srgb, var(--primary) 14%, transparent)); border: 1px solid color-mix(in srgb, var(--accent) 30%, transparent); }
.bonus-icon { display: grid; place-items: center; width: 34px; height: 34px; border-radius: 11px; background: linear-gradient(135deg, var(--accent), var(--warning)); color: #fff; flex: none; }
.bonus-tiers { list-style: none; padding: 0; margin: 4px 0; display: grid; gap: 2px; font-size: .9rem; color: var(--text-2); }
.topup-calc { display: grid; gap: 4px; padding: 12px 14px; margin: 0 0 14px; border-radius: var(--r); background: var(--bg-2); border: 1px solid var(--border); }
.topup-calc div { display: flex; justify-content: space-between; gap: 10px; }
.topup-calc b { font-variant-numeric: tabular-nums; }
.pay-lines .get dd { color: var(--primary-2); font-weight: 900; }

/* ==== 22-shop.css ==== */
/* Магазин: выбор сервера, категории, карточки товаров — theme/pages/shop.php, theme/parts/product-card.php. */

/* ---------- Магазин ---------- */
.shop { padding-top: 14px; padding-bottom: 8px; }
.shop-head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; margin: 4px 0 12px; }
.shop-head h2 { margin: 0; font-size: 1.3rem; white-space: nowrap; }
.shop-head .link-more { font-size: .85rem; white-space: nowrap; }
@media (min-width: 720px) { .shop-head h2 { font-size: 1.6rem; } }
.server-switch { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(150px, 1fr); gap: 8px; overflow-x: auto; scrollbar-width: none; margin: 0 -16px 10px; padding: 0 16px; scroll-padding-inline: 16px; }
.server-switch::-webkit-scrollbar { display: none; }
.server-option { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 14px; background: var(--surface); border: 1px solid var(--border); min-width: 0; }
.server-option.active { border-color: var(--primary); background: var(--grad-soft); }
.so-icon { display: grid; place-items: center; width: 36px; height: 36px; border-radius: 10px; background: var(--surface-2); color: var(--muted); flex: none; }
.server-option.active .so-icon { background: var(--grad); color: #fff; }
.so-text { display: flex; flex-direction: column; min-width: 0; }
.so-text b { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.so-text small { display: inline-flex; align-items: center; gap: 5px; color: var(--muted); font-size: .78rem; font-weight: 600; font-variant-numeric: tabular-nums; }
.server-option[data-status="online"] .dot { background: var(--success); }
.server-option[data-status="offline"] .dot { background: var(--danger); }
.chips { display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none; }
.chips::-webkit-scrollbar { display: none; }
.cat-chips { position: sticky; top: var(--header-h); z-index: 20; margin: 0 -16px 6px; padding: 8px 16px; background: color-mix(in srgb, var(--bg) 88%, transparent); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); transition: background-color .2s ease; }
/* Пока полоса на своём месте — прозрачная (над фоновой картинкой нет тёмной ленты); прилипла к шапке — с фоном (theme/js/10-shop.js) */
.cat-sticky-js .cat-chips:not(.is-stuck) { background: transparent; backdrop-filter: none; -webkit-backdrop-filter: none; }
.cat-chips-mark { height: 1px; margin-bottom: -1px; }
.chip { display: inline-flex; align-items: center; gap: 6px; flex: none; min-height: 38px; padding: 0 14px; border-radius: 99px; background: var(--surface); border: 1px solid var(--border); color: var(--text-2); font-weight: 700; font-size: .88rem; white-space: nowrap; }
.chip .icon { width: 1.05em; height: 1.05em; }
.chip.active { background: var(--text); color: var(--bg); border-color: var(--text); }
.category-block { margin-bottom: 20px; }
.category-title { font-size: 1rem; color: var(--muted); font-weight: 750; text-transform: uppercase; letter-spacing: .06em; margin: 12px 0 10px; }
.product-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
@media (min-width: 720px) { .product-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; } }
@media (min-width: 1040px) { .product-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); } .product-media { aspect-ratio: 16 / 9; } }
.product-card {
  --c: #7c5cff; display: flex; flex-direction: column; border-radius: var(--r-lg); overflow: hidden;
  background: var(--surface); border: 1px solid var(--border); transition: transform .18s ease, border-color .18s ease;
}
.product-card:hover { transform: translateY(-2px); border-color: color-mix(in srgb, var(--c) 60%, transparent); }
.product-card:active { transform: scale(.985); }
.product-media { position: relative; overflow: hidden; aspect-ratio: 4 / 3; display: grid; place-items: center; background: radial-gradient(110% 90% at 50% 0%, color-mix(in srgb, var(--c) 45%, transparent), transparent 70%), var(--surface-2); }
/* Картинка — по центру в своих пропорциях, углы скруглены как у карточки. Позиция absolute: в Safari на iPhone
   картинка с height: 100% внутри блока с aspect-ratio вылезала за карточку и наезжала на название */
.product-media img { position: absolute; inset: 0; margin: auto; width: auto; height: calc(100% - 20px); max-width: calc(100% - 20px); object-fit: contain; border-radius: calc(var(--r-lg) - 8px); }
.product-glyph { display: grid; place-items: center; width: 58px; height: 58px; border-radius: 18px; background: color-mix(in srgb, var(--c) 32%, transparent); color: #fff; }
.product-glyph .icon { width: 30px; height: 30px; }
.badge { position: absolute; top: 8px; left: 8px; padding: 3px 8px; border-radius: 8px; font-size: .72rem; font-weight: 900; }
.badge-sale { background: var(--accent); color: #fff; }
.badge-hot { background: rgba(0, 0, 0, .5); color: #ffc46b; }
.product-body { display: flex; flex-direction: column; gap: 2px; padding: 10px 12px 12px; }
.product-name { font-weight: 800; font-size: 1rem; color: color-mix(in srgb, var(--c) 30%, var(--text)); }
.product-term { color: var(--muted); font-size: .78rem; font-weight: 600; }
.product-price { margin-top: 6px; font-weight: 900; font-size: 1.1rem; font-variant-numeric: tabular-nums; }
.product-price s { color: var(--muted); font-weight: 600; font-size: .8rem; }
.price { font-weight: 900; font-size: 1.1rem; font-variant-numeric: tabular-nums; }
.price small { font-size: .72rem; color: var(--muted); font-weight: 700; }
.price s { color: var(--muted); font-weight: 600; font-size: .8rem; }
.price-lg { font-size: 1.5rem; }
.product-meta { display: flex; align-items: center; flex-wrap: wrap; gap: 6px 12px; }
.product-term .term-until { color: var(--accent, #ff5c8a); font-weight: 800; }

/* ==== 23-purchases.css ==== */
/* Лента последних покупок и аватарки — theme/parts/purchases.php. */

/* Лента покупок — одна горизонтальная полоса */
.purchases-wrap { padding-top: 6px; padding-bottom: 20px; }
.strip-title { display: flex; align-items: center; gap: 8px; font-size: .95rem; color: var(--muted); font-weight: 750; margin: 6px 0 10px; }
.purchases { list-style: none; padding: 0 16px; margin: 0 -16px; display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none; }
.purchases::-webkit-scrollbar { display: none; }
.purchase { flex: none; display: flex; align-items: center; gap: 10px; padding: 8px 12px 8px 8px; border-radius: 14px; background: var(--surface); border: 1px solid var(--border); max-width: 280px; }
.purchase.is-new { animation: slide-in .5s ease; }
.purchase-info { display: flex; flex-direction: column; min-width: 0; line-height: 1.25; }
.purchase-info strong { font-size: .9rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.purchase-info .small { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.purchase-item { --c: #7c5cff; font-weight: 800; color: color-mix(in srgb, var(--c) 55%, var(--text)); }
.purchase-empty { padding: 8px 0; }
.avatar { display: grid; place-items: center; width: 36px; height: 36px; border-radius: 10px; font-weight: 900; color: #fff; flex: none; background: #7c5cff; }
.avatar-lg { width: 56px; height: 56px; border-radius: 16px; font-size: 1.4rem; }
.av-0 { background: linear-gradient(135deg, #7c5cff, #5b8cff); } .av-1 { background: linear-gradient(135deg, #22d3ee, #0ea5e9); }
.av-2 { background: linear-gradient(135deg, #ff5c8a, #f43f5e); } .av-3 { background: linear-gradient(135deg, #22c55e, #10b981); }
.av-4 { background: linear-gradient(135deg, #f59e0b, #f97316); } .av-5 { background: linear-gradient(135deg, #a855f7, #ec4899); }
.av-6 { background: linear-gradient(135deg, #14b8a6, #22d3ee); } .av-7 { background: linear-gradient(135deg, #6366f1, #8b5cf6); }

/* ==== 24-product-sheet.css ==== */
/* Шторка товара (шаг 1: ник и количество) — theme/pages/shop.php, theme/parts/buy-form.php. */

/* ---------- Шторка товара ---------- */
dialog.sheet {
  border: 0; padding: 0; margin: 0; color: var(--text); background: var(--surface);
  width: 100%; max-width: 100%; max-height: 90dvh; position: fixed; inset: auto 0 0 0; border-radius: 22px 22px 0 0;
  box-shadow: var(--shadow-lg); overflow: hidden; display: none; flex-direction: column;
}
dialog.sheet[open] { display: flex; animation: sheet-up .26s cubic-bezier(.2, .9, .3, 1); }
dialog.sheet::backdrop { background: rgba(5, 6, 15, .6); backdrop-filter: blur(3px); }
.sheet-handle { width: 42px; height: 5px; border-radius: 99px; background: var(--border-2); margin: 9px auto 0; flex: none; }
.sheet-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 16px; border-bottom: 1px solid var(--border); flex: none; }
.sheet-body { padding: 16px 16px calc(18px + env(safe-area-inset-bottom)); overflow-y: auto; overscroll-behavior: contain; }
@media (min-width: 720px) {
  dialog.sheet { inset: 0; margin: auto; width: min(500px, 92vw); max-height: 88vh; border-radius: 22px; }
  .sheet-handle { display: none; }
  dialog.sheet[open] { animation: pop .2s ease; }
}
.sheet-product { --c: #7c5cff; margin-bottom: 14px; }
.sheet-product-head { display: flex; gap: 14px; align-items: center; margin-bottom: 12px; }
.sheet-product-media { width: 64px; height: 64px; flex: none; display: grid; place-items: center; border-radius: 18px; background: color-mix(in srgb, var(--c) 35%, transparent); color: #fff; }
.sheet-product-media .icon { width: 32px; height: 32px; }
.sheet-product-media img { width: auto; height: 54px; max-width: 54px; object-fit: contain; border-radius: 12px; }
.sheet-product-name { font-size: 1.3rem; margin: 0 0 4px; }
.sheet-desc { margin-top: 10px; border: 1px solid var(--border); border-radius: 12px; padding: 0 14px; }
.sheet-desc summary { list-style: none; display: flex; align-items: center; justify-content: space-between; padding: 11px 0; font-weight: 700; cursor: pointer; }
.sheet-desc summary::-webkit-details-marker { display: none; }
.sheet-desc[open] summary .icon { transform: rotate(180deg); }
.feature-list { list-style: none; padding: 0; margin: 0; display: grid; gap: 7px; }
.feature-list li { display: flex; gap: 10px; align-items: flex-start; font-size: .93rem; }
.feature-list .icon { width: 20px; height: 20px; padding: 3px; border-radius: 7px; background: color-mix(in srgb, var(--c, var(--primary)) 25%, transparent); color: color-mix(in srgb, var(--c, var(--primary)) 50%, #fff); flex: none; margin-top: 1px; }
.buy-form { border-top: 1px solid var(--border); padding-top: 14px; }
.checkout-card .buy-form { border-top: 0; padding-top: 0; }
.btn-price { font-variant-numeric: tabular-nums; }
.upgrade-note { margin: 0 0 12px; padding: 10px 12px; border-radius: 12px; background: rgba(34, 197, 94, .1); border: 1px solid rgba(34, 197, 94, .3); color: var(--success); font-size: .88rem; font-weight: 650; }
.next-step-note { display: flex; align-items: center; justify-content: center; gap: 6px; margin: 10px 0 0; }
.next-step-note .icon { width: 1em; height: 1em; }

/* ---------- Количество: ступени скидки, свёрнутое описание ---------- */
.bulk-tiers { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.bulk-tiers .chip { min-height: 32px; padding: 0 11px; font-size: .8rem; cursor: pointer; }
.bulk-tiers .chip.active { background: color-mix(in srgb, var(--success) 18%, transparent); border-color: color-mix(in srgb, var(--success) 45%, transparent); color: var(--success); }
.sheet-desc > .feature-list, .sheet-desc > .prose { padding-bottom: 12px; }
.sheet-desc-open { margin-top: 10px; }

/* Строки «Что входит»: команды и заметки */
.feature-list code { font-size: .86em; padding: 1px 6px; border-radius: 6px; background: color-mix(in srgb, var(--c, var(--primary)) 16%, transparent); color: var(--text); white-space: nowrap; }
.feature-list .feature-note { padding: 8px 10px; border-radius: 10px; background: color-mix(in srgb, var(--warning, #f59e0b) 14%, transparent); border: 1px solid color-mix(in srgb, var(--warning, #f59e0b) 35%, transparent); font-weight: 650; }
.feature-list .feature-note .icon { background: none; color: var(--warning, #f59e0b); }

/* ==== 25-pay.css ==== */
/* Страница оплаты (шаг 2): способы оплаты, промокод, итог — theme/pages/pay.php. */

/* ---------- Оплата (шаг 2) ---------- */
.pay-page { padding-top: 12px; padding-bottom: 24px; }
.pay-top { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 12px; }
.back-link { display: inline-flex; align-items: center; gap: 6px; color: var(--text-2); font-weight: 700; font-size: .92rem; }
.step-tag { font-size: .78rem; font-weight: 800; color: var(--muted); text-transform: uppercase; letter-spacing: .06em; }
.pay-layout { display: grid; gap: 14px; }
@media (min-width: 900px) { .pay-layout { grid-template-columns: minmax(0, 1fr) 340px; align-items: start; } .pay-summary { order: 2; position: sticky; top: calc(var(--header-h) + 16px); } }
.pay-summary { background: var(--surface); border: 1px solid var(--border); border-radius: var(--r-lg); padding: 14px; display: grid; gap: 12px; }
.order-line { --c: #7c5cff; display: flex; align-items: center; gap: 12px; }
.ol-icon { width: 46px; height: 46px; flex: none; display: grid; place-items: center; border-radius: 14px; background: color-mix(in srgb, var(--c) 32%, transparent); color: #fff; }
.ol-text { display: flex; flex-direction: column; min-width: 0; line-height: 1.3; }
.ol-text small b { color: var(--text); }
.pay-lines { margin: 0; display: grid; gap: 4px; padding: 10px 0 0; border-top: 1px dashed var(--border-2); }
.pay-lines div { display: flex; justify-content: space-between; gap: 10px; font-size: .9rem; color: var(--text-2); }
.pay-lines dt, .pay-lines dd { margin: 0; }
.pay-lines dd { font-variant-numeric: tabular-nums; font-weight: 700; }
.pay-lines .ok dd { color: var(--success); }
.pay-lines .total { font-size: 1.05rem; color: var(--text); padding-top: 6px; }
.pay-lines .total dd { font-size: 1.25rem; font-weight: 900; }
.pay-lines .charge { color: var(--muted); font-size: .85rem; } /* «Спишется в рублях» при ценах в евро */
.promo-box { border: 1px solid var(--border); border-radius: 12px; background: var(--bg-2); }
.promo-box summary { list-style: none; display: flex; align-items: center; gap: 8px; padding: 11px 12px; font-weight: 700; font-size: .9rem; cursor: pointer; }
.promo-box summary::-webkit-details-marker { display: none; }
.promo-box summary span { flex: 1; }
.promo-box summary > .icon:first-child { color: var(--primary-2); }
.promo-box[open] summary > .icon:last-child { transform: rotate(180deg); }
.promo-form { display: flex; gap: 8px; padding: 0 12px 12px; }
.promo-form .input { min-height: 44px; text-transform: uppercase; }
.pay-main { min-width: 0; }
.pay-main h1 { margin: 2px 0 12px; }
.method-group { border: 0; padding: 0; margin: 0 0 16px; min-width: 0; }
.method-group legend { padding: 0; margin-bottom: 8px; font-size: .78rem; font-weight: 800; color: var(--muted); text-transform: uppercase; letter-spacing: .06em; }
.method-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
@media (min-width: 600px) { .method-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.method { display: block; position: relative; }
.method input { position: absolute; opacity: 0; pointer-events: none; }
.method-box {
  position: relative; display: flex; align-items: center; gap: 10px; height: 100%;
  min-height: 64px; padding: 10px; border-radius: 14px; background: var(--surface); border: 1.5px solid var(--border-2); cursor: pointer;
  transition: border-color .15s, background .15s;
}
.method-text { display: flex; flex-direction: column; gap: 1px; min-width: 0; }
.method-logo { --c: #5b8cff; flex: none; width: 40px; height: 40px; box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .12); display: grid; place-items: center; border-radius: 11px; background: var(--c); color: #fff; font-size: .7rem; font-weight: 900; letter-spacing: -.02em; overflow: hidden; }
.method-logo.on-light { color: #1b1b1b; }
.method-logo img { width: 100%; height: 100%; object-fit: cover; }
.method-logo.ml-icon { background: var(--grad); }
.method-name { font-weight: 750; font-size: .88rem; line-height: 1.2; overflow-wrap: anywhere; }
.method-note { font-size: .74rem; color: var(--muted); font-weight: 600; }
.method-note:empty { display: none; }
.method input:checked + .method-box { border-color: var(--primary); background: var(--grad-soft); box-shadow: 0 0 0 1px var(--primary) inset; }
.method input:focus-visible + .method-box { outline: 2px solid var(--primary-2); outline-offset: 2px; }
.method.disabled .method-box { opacity: .45; cursor: not-allowed; }
.pay-final { margin-top: 6px; }
.pay-bar {
  position: sticky; bottom: 0; z-index: 30; display: flex; align-items: center; gap: 12px; margin: 4px -16px 0; padding: 12px 16px calc(12px + env(safe-area-inset-bottom));
  background: color-mix(in srgb, var(--bg) 92%, transparent); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); border-top: 1px solid var(--border);
}
.pay-bar-total { display: flex; flex-direction: column; line-height: 1.15; }
.pay-bar-total b { font-size: 1.3rem; font-weight: 900; font-variant-numeric: tabular-nums; }
.pay-bar .btn { flex: 1; }
@media (min-width: 900px) { .pay-bar { position: static; margin: 4px 0 0; padding: 0; background: none; backdrop-filter: none; border: 0; } .pay-bar .btn { flex: 0 1 320px; margin-left: auto; } }
.secure-note { display: flex; align-items: center; justify-content: center; gap: 6px; margin: 10px 0 0; }
.secure-note .icon { width: 1em; height: 1em; color: var(--success); }

/* ==== 26-upgrade.css ==== */
/* Докупка привилегии — theme/pages/upgrade.php. */

/* ---------- Докупка привилегии ---------- */
.upgrade-banner {
  display: flex; align-items: center; gap: 12px; margin: 0 0 12px; padding: 12px 14px; border-radius: var(--r);
  background: var(--grad-soft); border: 1px solid color-mix(in srgb, var(--primary) 35%, var(--border)); font-size: .9rem; color: var(--text-2);
}
.upgrade-banner b { color: var(--text); }
.upgrade-banner > span:nth-child(2) { flex: 1; min-width: 0; }
.upgrade-banner > .icon { color: var(--muted); }
.ub-icon { display: grid; place-items: center; width: 36px; height: 36px; border-radius: 11px; background: var(--grad); color: #fff; flex: none; }
.upgrade-page { padding-bottom: 28px; }
.upgrade-form .field:last-child { margin-bottom: 0; }
.upgrade-row { display: flex; gap: 8px; }
.upgrade-row .input-icon { flex: 1; min-width: 0; }
.upgrade-row .btn { min-height: 48px; flex: none; }
.chip-group { display: flex; flex-wrap: wrap; gap: 8px; }
.chip-radio { position: relative; }
.chip-radio input { position: absolute; opacity: 0; pointer-events: none; }
.chip-radio .chip { cursor: pointer; }
.chip-radio input:checked + .chip { background: var(--text); color: var(--bg); border-color: var(--text); }
.chip-radio input:focus-visible + .chip { outline: 2px solid var(--primary-2); outline-offset: 2px; }
.upgrade-page > .alert, .owned-list { margin-top: 14px; }
.owned-list { display: grid; gap: 8px; }
.owned { --c: #7c5cff; display: flex; align-items: center; gap: 12px; padding: 12px 14px; border-radius: var(--r); background: var(--surface); border: 1px solid color-mix(in srgb, var(--c) 40%, var(--border)); }
.owned-icon, .offer-icon { width: 44px; height: 44px; flex: none; display: grid; place-items: center; border-radius: 13px; background: color-mix(in srgb, var(--c) 35%, transparent); color: #fff; overflow: hidden; }
.owned-icon img, .offer-icon img { width: 36px; height: 36px; object-fit: contain; }
.owned-text { flex: 1; min-width: 0; display: flex; flex-direction: column; line-height: 1.3; }
.owned-text b { font-size: 1.05rem; color: color-mix(in srgb, var(--c) 45%, var(--text)); }
.offer-list { display: grid; gap: 8px; }
.offer { --c: #7c5cff; display: flex; align-items: center; gap: 12px; padding: 12px; border-radius: var(--r); background: var(--surface); border: 1px solid var(--border); }
.offer-text { flex: 1; min-width: 0; display: flex; flex-direction: column; line-height: 1.3; }
.offer-name { font-weight: 800; color: color-mix(in srgb, var(--c) 40%, var(--text)); }
.offer-text small { font-size: .78rem; }
.offer .btn { flex: none; gap: .4em; }
.offer .btn b { font-variant-numeric: tabular-nums; }
@media (max-width: 420px) {
  .offer { flex-wrap: wrap; }
  .offer .btn { width: 100%; min-height: 44px; }
}
.ladder { list-style: none; padding: 0; margin: 0 0 8px; display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.ladder-step { --c: #7c5cff; position: relative; display: flex; flex-direction: column; margin-left: 14px; padding: 8px 12px; border-radius: 12px; background: var(--surface); border: 1px solid color-mix(in srgb, var(--c) 40%, var(--border)); line-height: 1.25; }
.ladder-step:first-child { margin-left: 0; }
.ladder-step b { color: color-mix(in srgb, var(--c) 45%, var(--text)); }
.ladder-step span { font-size: .8rem; color: var(--muted); font-weight: 700; font-variant-numeric: tabular-nums; }
.ladder-step + .ladder-step::before { content: "→"; position: absolute; left: -17px; top: 50%; transform: translateY(-50%); color: var(--muted); font-weight: 800; }
.upgrade-how { display: flex; gap: 8px; align-items: flex-start; margin-top: 18px; }
.upgrade-how .icon { margin-top: 2px; color: var(--primary-2); }

/* ==== 27-product-page.css ==== */
/* Отдельная страница товара — theme/pages/product.php. */

/* ---------- Страница товара ---------- */
.breadcrumbs { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; padding: 14px 0; font-size: .85rem; color: var(--muted); font-weight: 600; }
.breadcrumbs .icon { width: 14px; height: 14px; }
.breadcrumbs a:hover { color: var(--text); }
.product-page { --c: #7c5cff; display: grid; gap: 14px; padding-bottom: 28px; }
@media (min-width: 960px) { .product-page { grid-template-columns: 1fr 400px; align-items: start; } .checkout-card { position: sticky; top: calc(var(--header-h) + 16px); } }
.product-hero { display: flex; gap: 16px; align-items: center; margin-bottom: 14px; }
.product-hero h1 { font-size: clamp(1.5rem, 5vw, 2.2rem); margin-bottom: 4px; }
.product-hero-media { width: 88px; height: 88px; flex: none; display: grid; place-items: center; border-radius: 24px; background: color-mix(in srgb, var(--c) 35%, transparent); color: #fff; }
.product-hero-media .icon { width: 42px; height: 42px; }
.product-hero-media img { width: auto; height: 76px; max-width: 76px; object-fit: contain; border-radius: 16px; }
.product-spoiler { padding: 0 18px; }
.product-spoiler summary { font-size: 1.05rem; }

/* Телефон: форма покупки сразу под названием товара, описание — ниже (не нужно листать до ника) */
@media (max-width: 959px) {
  .product-page { display: flex; flex-direction: column; }
  .product-info { display: contents; }
  .product-info > .product-hero { order: 1; margin-bottom: 0; }
  .product-page > .checkout-card { order: 2; }
  .product-info > :not(.product-hero) { order: 3; }
}

/* ---------- Конструктор доната ---------- */
.builder-head { display: grid; gap: 6px; margin-bottom: 10px; }
.builder-head p { margin: 0; }
.builder-tools { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.builder-count { margin-right: auto; font-weight: 650; }
.builder-group { border-top: 1px solid var(--border); }
.builder-group summary { list-style: none; display: flex; align-items: center; gap: 8px; padding: 11px 0; font-weight: 800; cursor: pointer; }
.builder-group summary::-webkit-details-marker { display: none; }
.builder-group summary .icon { margin-left: auto; width: 18px; height: 18px; }
.builder-group[open] summary .icon { transform: rotate(180deg); }
.builder-list { list-style: none; margin: 0 0 10px; padding: 0; display: grid; gap: 6px; }
.builder-opt label { display: grid; grid-template-columns: auto 1fr auto; gap: 10px; align-items: center; padding: 9px 11px; border: 1px solid var(--border); border-radius: 12px; cursor: pointer; }
.builder-opt label:has(input:checked) { border-color: color-mix(in srgb, var(--c, var(--primary)) 60%, transparent); background: color-mix(in srgb, var(--c, var(--primary)) 10%, transparent); }
.builder-opt input[type="checkbox"] { width: 18px; height: 18px; accent-color: var(--primary); }
.builder-opt.is-required label { cursor: default; opacity: .9; }
.bo-name { font-size: .93rem; line-height: 1.35; }
.bo-name code { font-size: .86em; padding: 1px 6px; border-radius: 6px; background: color-mix(in srgb, var(--c, var(--primary)) 16%, transparent); }
.bo-price { font-weight: 800; white-space: nowrap; font-variant-numeric: tabular-nums; }
.bo-text { margin: 6px 0 2px 40px; width: calc(100% - 40px); }
.builder-bar { display: none; }
@media (max-width: 959px) {
  .product-page.is-builder .product-info > .builder { order: 2; }
  .product-page.is-builder > .checkout-card { order: 3; }
  .product-page.is-builder .product-info > :not(.product-hero):not(.builder) { order: 4; }
  .builder-bar { display: flex; align-items: center; justify-content: space-between; gap: 10px; position: fixed; left: 12px; right: 12px; z-index: 40;
    bottom: calc(var(--bottom-h) + env(safe-area-inset-bottom) + 10px); padding: 10px 12px; border-radius: 16px;
    background: color-mix(in srgb, var(--surface) 94%, transparent); border: 1px solid var(--border); box-shadow: 0 10px 30px rgba(0, 0, 0, .35);
    backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); }
  .builder-bar span { display: grid; line-height: 1.15; }
  .builder-bar b { font-size: 1.15rem; font-variant-numeric: tabular-nums; }
  .product-page.is-builder { padding-bottom: 90px; }
}
.pay-options { margin: 0 0 12px; border: 1px solid var(--border); border-radius: 12px; padding: 0 12px; }
.pay-options summary { list-style: none; display: flex; align-items: center; justify-content: space-between; padding: 10px 0; font-weight: 700; cursor: pointer; }
.pay-options summary::-webkit-details-marker { display: none; }
.pay-options .feature-list { padding-bottom: 10px; }
.limit-note { display: flex; align-items: center; gap: 6px; }
.limit-note .icon { width: 1em; height: 1em; flex: none; }

/* ==== 30-monitoring.css ==== */
/* Мониторинг: карточки серверов, онлайн, график — theme/pages/monitoring.php, theme/parts/monitoring-card.php. */

/* ---------- Мониторинг (страница) ---------- */
.mon-grid { display: grid; gap: 12px; grid-template-columns: 1fr; }
@media (min-width: 640px) { .mon-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1000px) { .mon-grid { grid-template-columns: repeat(3, 1fr); } }
.mon-card { position: relative; overflow: hidden; background: var(--surface); border: 1px solid var(--border); border-radius: var(--r-lg); padding: 16px; }
.mon-card::before { content: ""; position: absolute; inset: 0 0 auto 0; height: 3px; background: var(--muted); opacity: .4; }
.mon-card[data-status="online"]::before { background: var(--grad); opacity: 1; }
.mon-card[data-status="offline"]::before { background: var(--danger); opacity: 1; }
.mon-head { display: flex; align-items: center; gap: 12px; }
.mon-icon { display: grid; place-items: center; width: 42px; height: 42px; border-radius: 13px; background: var(--grad-soft); color: var(--primary-2); flex: none; }
.mon-icon .icon { width: 22px; height: 22px; }
.mon-title { min-width: 0; flex: 1; }
.mon-title h3 { margin: 0; font-size: 1.05rem; }
.mon-version { font-size: .78rem; color: var(--muted); font-weight: 600; }
.status-badge { display: inline-flex; align-items: center; gap: 6px; font-size: .75rem; font-weight: 800; padding: 5px 9px; border-radius: 99px; background: var(--surface-2); color: var(--muted); white-space: nowrap; }
[data-status="online"] .status-badge { color: var(--success); background: rgba(34, 197, 94, .12); }
[data-status="online"] .status-badge .dot { background: var(--success); }
[data-status="offline"] .status-badge { color: var(--danger); background: rgba(239, 68, 68, .12); }
.mon-online { display: flex; align-items: baseline; justify-content: space-between; margin: 14px 0 8px; }
.mon-count b { font-size: 1.7rem; font-weight: 900; font-variant-numeric: tabular-nums; }
.mon-bar { height: 8px; border-radius: 99px; background: var(--surface-2); overflow: hidden; }
.mon-bar span { display: block; height: 100%; width: 0; border-radius: inherit; background: var(--grad); transition: width .8s cubic-bezier(.2, .9, .3, 1); }
/* Мини-график в карточке режима — тот же движок, что у большого (drawChart, mini) */
.mon-spark { position: relative; width: 100%; height: 48px; margin-top: 12px; cursor: crosshair; touch-action: pan-y; }
.mon-spark:focus-visible { outline: 2px solid var(--primary-2); outline-offset: 3px; border-radius: 8px; }
.mon-spark-fallback { width: 100%; height: 36px; }
.mc-mini { height: 48px; }
.mc-single { fill: var(--primary-2); }
.mc-tip-mini { min-width: 0; }
[data-status]:not([data-status="online"]) .mc-mini .mc-line { opacity: .45; }
.spark-line { fill: none; stroke: var(--primary-2); stroke-width: 2; vector-effect: non-scaling-stroke; opacity: .35; }
.spark-area { fill: var(--primary); opacity: .08; }
[data-status="online"] .spark-line { opacity: 1; }
[data-status="online"] .spark-area { opacity: .18; }
.mon-summary { display: grid; grid-template-columns: repeat(2, 1fr); gap: 14px; margin-bottom: 14px; }
@media (min-width: 720px) { .mon-summary { grid-template-columns: repeat(4, 1fr); } }
.mon-total { display: flex; flex-direction: column; gap: 4px; }
.mon-total span { font-size: .8rem; font-weight: 700; }
.mon-total b { font-size: 1.5rem; font-weight: 900; font-variant-numeric: tabular-nums; }
.mon-grid-lg { margin-bottom: 14px; }
.mon-chart-card { margin-top: 14px; }
/* График «Онлайн за сутки»: рисует theme/js/30-monitoring.js (drawChart), без скрипта — запасная картинка */
.mon-chart { position: relative; width: 100%; min-height: 230px; touch-action: pan-y; cursor: crosshair; }
.mon-chart:focus-visible { outline: 2px solid var(--primary-2); outline-offset: 4px; border-radius: 10px; }
.mon-chart-fallback { width: 100%; height: 180px; }
.mc-svg { display: block; width: 100%; height: 230px; overflow: visible; }
.mc-svg.mc-mini { height: 48px; }
.mc-grid { stroke: var(--border); stroke-width: 1; }
.mc-base { stroke: var(--border-2); stroke-width: 1; }
.mc-label { fill: var(--muted); font-size: 11px; font-weight: 600; font-variant-numeric: tabular-nums; }
.mc-line { fill: none; stroke: var(--primary-2); stroke-width: 2; stroke-linejoin: round; stroke-linecap: round; }
.mc-mini .mc-line { stroke-width: 1.5; }
.mc-area { fill: var(--primary-2); opacity: .12; }
.mc-peak { fill: var(--primary-2); stroke: var(--surface); stroke-width: 2; }
.mc-peak-label { fill: var(--text-2); font-size: 11px; font-weight: 800; font-variant-numeric: tabular-nums; }
.mc-cross { stroke: var(--text-2); stroke-width: 1; opacity: .55; }
.mc-dot { fill: var(--primary-2); stroke: var(--surface); stroke-width: 2.5; }
.mc-tip { position: absolute; z-index: 2; pointer-events: none; min-width: 130px; padding: 8px 11px; border-radius: 11px; background: var(--surface-3);
  border: 1px solid var(--border-2); box-shadow: var(--shadow-lg); font-size: .8rem; line-height: 1.35; white-space: nowrap; }
.mc-tip-head { color: var(--text-2); }
.mc-tip-head b { font-size: 1.15rem; font-weight: 900; color: var(--text); font-variant-numeric: tabular-nums; }
.mc-tip-time { color: var(--muted); font-weight: 600; margin-bottom: 2px; }
.mc-tip-row { display: flex; justify-content: space-between; gap: 14px; color: var(--text-2); }
.mc-tip-row b { color: var(--text); font-variant-numeric: tabular-nums; }
.grid-lines path { stroke: var(--border); stroke-width: 1; vector-effect: non-scaling-stroke; }
.chart-line { fill: none; stroke: var(--primary-2); stroke-width: 2.5; vector-effect: non-scaling-stroke; }
.chart-area { fill: var(--primary); opacity: .15; }

/* ==== 31-pages.css ==== */
/* Текстовые страницы: оформление текста (.prose), FAQ-аккордеон, шаги «Как начать», контакты, описание доната. */

/* ---------- Текстовые страницы ---------- */
.prose { color: var(--text-2); overflow-wrap: anywhere; }
.prose h2 { color: var(--text); font-size: 1.25rem; margin: 1.3em 0 .5em; }
.prose h2:first-child, .prose h3:first-child { margin-top: 0; }
.prose h3 { color: var(--text); margin: 1.1em 0 .4em; }
.prose ul, .prose ol { padding-left: 1.3em; margin: 0 0 1em; }
.prose li { margin: .3em 0; }
.prose li::marker { color: var(--primary-2); font-weight: 800; }
.prose a { color: var(--primary-2); text-decoration: underline; text-underline-offset: 3px; }
.prose strong { color: var(--text); }
.prose .callout { border-left: 3px solid var(--primary); background: var(--grad-soft); padding: 12px 14px; border-radius: 0 12px 12px 0; margin: 0 0 1em; color: var(--text); }
.toc { display: flex; gap: 8px; overflow-x: auto; padding-bottom: 12px; margin-bottom: 6px; scrollbar-width: none; }
.toc::-webkit-scrollbar { display: none; }
.accordion { display: grid; gap: 8px; }
.acc-item { background: var(--surface); border: 1px solid var(--border); border-radius: 14px; overflow: hidden; }
.acc-item summary { list-style: none; display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 15px 16px; font-weight: 750; cursor: pointer; }
.acc-item summary::-webkit-details-marker { display: none; }
.acc-item summary .icon { transition: transform .2s; color: var(--muted); }
.acc-item[open] summary .icon { transform: rotate(180deg); color: var(--primary-2); }
.acc-body { padding: 0 16px 16px; }
.help-page { padding-bottom: 24px; }
.help-note { margin-top: 12px; }
.steps { list-style: none; padding: 0; margin: 0 0 20px; display: grid; gap: 10px; }
.step { display: flex; gap: 14px; align-items: flex-start; background: var(--surface); border: 1px solid var(--border); border-radius: var(--r-lg); padding: 16px; }
.step p { margin: 0; }
.step .prose { min-width: 0; }
.step-num { flex: none; display: grid; place-items: center; width: 36px; height: 36px; border-radius: 11px; background: var(--grad); color: #fff; font-weight: 900; }
.steps-vertical { margin-top: 14px; }
.ip-card { display: flex; flex-direction: column; gap: 12px; }
.ip-row { display: grid; grid-template-columns: 1fr auto; gap: 10px; }
.ip-field { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.ip-label { font-size: .74rem; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }
.ip-value { display: flex; align-items: center; justify-content: space-between; gap: 10px; width: 100%; min-height: 50px; padding: 0 14px; border-radius: 12px; background: var(--bg-2); border: 1px dashed var(--border-2); font-weight: 800; font-size: 1rem; text-align: left; font-variant-numeric: tabular-nums; }
.ip-value span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ip-value .icon { color: var(--muted); }
.ip-value.copied { border-color: var(--success); border-style: solid; }
.ip-value.secret { font-family: var(--mono); font-size: .9rem; letter-spacing: .05em; }
.ip-hint { margin: 0; text-align: center; }
.mode-grid { display: grid; gap: 10px; margin-bottom: 28px; }
@media (min-width: 640px) { .mode-grid { grid-template-columns: repeat(2, 1fr); } }
.mode-card, .contact-card { display: flex; align-items: center; gap: 12px; padding: 14px; border-radius: 16px; background: var(--surface); border: 1px solid var(--border); }
.mode-card:hover, .contact-card:hover { border-color: var(--primary); }
.mode-card > span:nth-child(2), .contact-card > span:nth-child(2) { flex: 1; display: flex; flex-direction: column; min-width: 0; }
.mode-card > .icon, .contact-card > .icon { color: var(--muted); }
.contact-grid { display: grid; gap: 10px; }
@media (min-width: 640px) { .contact-grid { grid-template-columns: repeat(2, 1fr); } }
.contact-icon { display: grid; place-items: center; width: 44px; height: 44px; border-radius: 13px; background: var(--grad-soft); color: var(--primary-2); flex: none; }
.ci-discord { background: #5865f2; color: #fff; } .ci-telegram { background: #229ed9; color: #fff; } .ci-vk { background: #0077ff; color: #fff; }
.rank-grid { display: grid; gap: 12px; grid-template-columns: 1fr; }
@media (min-width: 640px) { .rank-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1000px) { .rank-grid { grid-template-columns: repeat(3, 1fr); } }
.rank-card { --c: #7c5cff; display: flex; flex-direction: column; gap: 12px; padding: 16px; border-radius: var(--r-lg); border: 1px solid color-mix(in srgb, var(--c) 35%, var(--border)); background: radial-gradient(130% 70% at 0% 0%, color-mix(in srgb, var(--c) 18%, transparent), transparent 60%), var(--surface); }
.rank-card .feature-list { flex: 1; }
.rank-head { display: flex; gap: 12px; align-items: center; }
.rank-head h3 { margin: 0 0 2px; color: color-mix(in srgb, var(--c) 45%, var(--text)); }
.rank-icon { display: grid; place-items: center; width: 48px; height: 48px; border-radius: 14px; background: color-mix(in srgb, var(--c) 40%, transparent); color: #fff; flex: none; }
.rank-icon img { width: 40px; height: 40px; object-fit: contain; }
.rank-mini { gap: 8px; }
.rank-mini p { margin: 0; display: flex; gap: 6px; align-items: center; }
.rank-mini p .icon { width: 1em; height: 1em; }
.top-list { list-style: none; padding: 0; margin: 0 0 10px; display: grid; gap: 6px; }
.top-item { display: flex; align-items: center; gap: 12px; padding: 10px; border-radius: 12px; background: var(--surface-2); }
.top-item strong { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.top-rank { width: 28px; height: 28px; display: grid; place-items: center; border-radius: 9px; font-weight: 900; background: var(--surface-3); font-size: .85rem; flex: none; }

/* ==== 32-rules.css ==== */
/* Правила сервера — theme/pages/rules.php. */

/* ---------- Правила ---------- */
.rules-page { padding-bottom: 28px; }
.rules-modes, .donate-modes { margin-bottom: 12px; }
.rules-lead { display: flex; gap: 10px; align-items: flex-start; padding: 12px 14px; margin-bottom: 12px; border-radius: var(--r); background: var(--grad-soft); border: 1px solid var(--border); color: var(--text-2); font-size: .92rem; }
.rules-lead p { margin: 0; }
.rules-lead .icon { color: var(--primary-2); margin-top: 2px; }
.rules-search { margin-bottom: 12px; }
.rules-search .input { -webkit-appearance: none; }
.rules-empty { text-align: center; padding: 12px 0; }
.rules-sec summary { padding: 14px 16px; }
.rs-title { display: flex; align-items: center; gap: 10px; min-width: 0; }
.rs-no { display: grid; place-items: center; min-width: 28px; height: 28px; padding: 0 6px; border-radius: 9px; background: var(--grad-soft); color: var(--primary-2); font-size: .82rem; font-weight: 900; flex: none; }
.rs-meta { display: inline-flex; align-items: center; gap: 8px; flex: none; }
.rs-name { display: flex; flex-direction: column; min-width: 0; line-height: 1.25; }
.rs-tag { font-size: .74rem; font-weight: 600; color: var(--muted); }
.rs-count { min-width: 24px; height: 22px; padding: 0 7px; display: grid; place-items: center; border-radius: 99px; background: var(--surface-2); color: var(--muted); font-size: .75rem; font-weight: 800; }
.rs-intro { color: var(--text-2); margin: 0 0 10px; }
.rule-list { list-style: none; padding: 0; margin: 0; display: grid; gap: 2px; }
.rule { display: flex; gap: 12px; padding: 10px 0; border-top: 1px dashed var(--border); scroll-margin-top: calc(var(--header-h) + 20px); }
.rule:first-child { border-top: 0; padding-top: 2px; }
.rule.flash { animation: rule-flash 2.2s ease; border-radius: 10px; }
.rule-num { flex: none; min-width: 38px; height: 26px; padding: 0 6px; display: grid; place-items: center; border-radius: 8px; background: var(--surface-2); color: var(--text-2); font-size: .8rem; font-weight: 800; font-variant-numeric: tabular-nums; }
.rule-num:hover { color: var(--primary-2); }
.rule-body { min-width: 0; flex: 1; }
.rule-text { margin: 2px 0 0; color: var(--text); overflow-wrap: anywhere; }
.rule-text a { color: var(--primary-2); text-decoration: underline; }
.rule-punish { display: inline-flex; align-items: flex-start; gap: 6px; margin: 6px 0 0; padding: 5px 10px; border-radius: 9px; background: rgba(239, 68, 68, .1); border: 1px solid rgba(239, 68, 68, .25); color: #ff9b9b; font-size: .84rem; font-weight: 600; }
.rule-punish .icon { width: 1em; height: 1em; margin-top: 2px; flex: none; }
.rule-punish b { color: inherit; }
[data-theme="light"] .rule-punish { color: #b91c1c; }
.rs-note { display: flex; gap: 8px; align-items: flex-start; margin: 10px 0 0; padding: 10px 12px; border-radius: 10px; background: var(--surface-2); color: var(--text-2); font-size: .88rem; }
.rs-note .icon { color: var(--primary-2); margin-top: 2px; flex: none; }
@keyframes rule-flash { 0%, 40% { background: color-mix(in srgb, var(--primary) 22%, transparent); } 100% { background: transparent; } }

/* ==== 33-order.css ==== */
/* Статус заказа — theme/pages/order.php. */

/* ---------- Заказ ---------- */
.order-card { text-align: center; margin: 22px auto 36px; }
.order-status-icon { width: 72px; height: 72px; margin: 6px auto 14px; display: grid; place-items: center; border-radius: 22px; background: var(--surface-2); color: var(--muted); }
.order-status-icon .icon { width: 36px; height: 36px; }
.status-pending .order-status-icon { background: rgba(245, 158, 11, .14); color: var(--warning); }
.status-paid .order-status-icon { background: color-mix(in srgb, var(--primary-2) 14%, transparent); color: var(--primary-2); }
.status-paid .order-status-icon .icon { animation: spin 1.6s linear infinite; }
.status-delivered .order-status-icon { background: var(--grad); color: #fff; }
.status-failed .order-status-icon, .status-canceled .order-status-icon, .status-refunded .order-status-icon { background: rgba(239, 68, 68, .12); color: var(--danger); }
.order-details { display: grid; margin: 16px 0; text-align: left; background: var(--bg-2); border: 1px solid var(--border); border-radius: 14px; padding: 4px 14px; }
.order-details div { display: flex; justify-content: space-between; gap: 14px; padding: 10px 0; border-bottom: 1px dashed var(--border); }
.order-details div:last-child { border-bottom: 0; }
.order-details dt { color: var(--muted); font-size: .9rem; }
.order-details dd { margin: 0; font-weight: 700; text-align: right; overflow-wrap: anywhere; }
.order-actions { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; margin: 14px 0 10px; }

/* ==== 34-cabinet.css ==== */
/* Личный кабинет — theme/pages/cabinet/*.php, theme/parts/cabinet-nav.php. */

/* ---------- Кабинет ---------- */
.cabinet { padding-top: 18px; padding-bottom: 28px; }
.cabinet-head { display: grid; grid-template-columns: auto 1fr; gap: 14px; align-items: center; }
.cabinet-user h1 { margin: 0; }
.cabinet-user { min-width: 0; }
.cabinet-user .muted { display: block; overflow: hidden; text-overflow: ellipsis; }
.balance { grid-column: 1 / -1; display: flex; align-items: center; gap: 10px; flex-wrap: wrap; padding: 12px 14px; border-radius: 12px; background: var(--grad-soft); border: 1px solid var(--border-2); }
.balance b { font-size: 1.35rem; font-weight: 900; margin-right: auto; font-variant-numeric: tabular-nums; }
@media (min-width: 720px) { .cabinet-head { grid-template-columns: auto 1fr auto; } .balance { grid-column: auto; } }
.tabs { display: flex; gap: 6px; overflow-x: auto; margin: 14px 0 6px; padding: 4px; background: var(--surface); border: 1px solid var(--border); border-radius: 14px; scrollbar-width: none; }
.tabs a { flex: 1; display: inline-flex; align-items: center; justify-content: center; gap: 6px; padding: 10px 12px; border-radius: 10px; font-weight: 700; font-size: .9rem; color: var(--muted); white-space: nowrap; }
.tabs a.active { background: var(--surface-2); color: var(--text); }
.order-list { display: grid; gap: 8px; }
.order-row { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 12px 14px; border-radius: 14px; background: var(--surface); border: 1px solid var(--border); }
.order-row-main { display: flex; flex-direction: column; min-width: 0; }
.order-row-main b { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.order-row-side { display: flex; flex-direction: column; align-items: flex-end; gap: 4px; flex: none; }
.status-pill { font-size: .72rem; font-weight: 800; padding: 3px 8px; border-radius: 99px; background: var(--surface-2); color: var(--muted); white-space: nowrap; }
.st-delivered { background: rgba(34, 197, 94, .14); color: var(--success); }
.st-paid { background: color-mix(in srgb, var(--primary-2) 14%, transparent); color: var(--primary-2); }
.st-pending { background: rgba(245, 158, 11, .14); color: var(--warning); }
.st-failed, .st-canceled, .st-refunded { background: rgba(239, 68, 68, .12); color: var(--danger); }
/* Наказания на сервере: баны и варны (theme/pages/cabinet/index.php) */
.punish-ban { margin-bottom: 10px; }
.punish-ban p { margin: 6px 0 0; font-weight: 500; }
.punish-ok { display: flex; align-items: center; gap: 8px; margin: 0 0 10px; color: var(--success); font-weight: 700; }
.punish-sub { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; font-size: 1rem; margin: 14px 0 8px; }
.order-row.is-muted { opacity: .65; }
.order-row-main .warn-rule { overflow: hidden; text-overflow: ellipsis; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.settings-grid { display: grid; gap: 14px; margin-top: 12px; }
.settings-grid .card + .card { margin-top: 0; }
.settings-grid h2 { display: flex; align-items: center; gap: 8px; }
.settings-grid h2 .icon { color: var(--primary-2); }
@media (min-width: 900px) { .settings-grid { grid-template-columns: repeat(2, 1fr); align-items: start; } }

/* ==== 35-auth.css ==== */
/* Вход, регистрация, ошибки 404/500 — theme/pages/auth/*.php, theme/pages/error.php. */

/* ---------- Авторизация, ошибки ---------- */
.auth-wrap { display: grid; place-items: center; padding-top: 26px; padding-bottom: 36px; }
.auth-card { width: 100%; max-width: 430px; }
.auth-head { text-align: center; margin-bottom: 16px; }
.auth-head p { margin: 0; }
.auth-icon { width: 56px; height: 56px; margin: 0 auto 12px; display: grid; place-items: center; border-radius: 18px; background: var(--grad); color: #fff; }
.auth-icon .icon { width: 26px; height: 26px; }
.auth-links { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 10px; margin-top: 14px; font-size: .9rem; font-weight: 600; }
.auth-links a { color: var(--primary-2); }
.error-page { padding: 56px 0; }
.error-page .center { flex-direction: column; align-items: center; }
.error-code { font-size: clamp(4.5rem, 20vw, 8rem); font-weight: 900; line-height: 1; letter-spacing: -.05em; background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }

/* Капча на входе (theme/pages/auth/login.php, theme/admin/login.php) */
.captcha .captcha-img { display: block; width: 190px; height: 64px; border-radius: 10px; border: 1px solid var(--border-2); margin-bottom: 8px; image-rendering: auto; }
.captcha .captcha-input { text-transform: uppercase; letter-spacing: .25em; font-weight: 800; max-width: 190px; }
.captcha-refresh { display: inline-flex; align-items: center; gap: 6px; margin-top: 8px; color: var(--primary-2); font-weight: 600; }
.captcha-refresh .icon { width: 1em; height: 1em; }

/* ==== 40-footer.css ==== */
/* Подвал сайта — theme/parts/footer.php. */

/* ---------- Подвал ---------- */
.site-footer { margin-top: 28px; border-top: 1px solid var(--border); background: var(--bg-2); padding: 22px 0 18px; font-size: .9rem; }
.footer-inner { display: grid; gap: 14px; }
.footer-links { display: flex; flex-wrap: wrap; gap: 8px 18px; font-weight: 650; color: var(--text-2); }
.footer-links a:hover { color: var(--primary-2); }
.footer-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; }
.socials { display: flex; gap: 8px; flex-wrap: wrap; }
.footer-copy { margin: 0; }

/* ==== 41-toasts.css ==== */
/* Всплывающие уведомления («Скопировано» и т.п.). */

/* ---------- Тосты ---------- */
.toasts { position: fixed; left: 50%; transform: translateX(-50%); bottom: calc(var(--bottom-h) + 14px + env(safe-area-inset-bottom)); z-index: 60; display: grid; gap: 8px; width: min(92vw, 380px); pointer-events: none; }
.no-bottom-nav .toasts { bottom: calc(96px + env(safe-area-inset-bottom)); }
@media (min-width: 960px) { .toasts { bottom: 24px; } }
.toast { display: flex; align-items: center; gap: 10px; padding: 12px 14px; border-radius: 12px; background: var(--surface-3); border: 1px solid var(--border-2); box-shadow: var(--shadow-lg); font-weight: 700; font-size: .92rem; animation: toast-in .25s ease; }
.toast .icon { color: var(--success); }
.toast.out { animation: toast-out .25s ease forwards; }

/* ==== 50-animations.css ==== */
/* Анимации. */

/* ---------- Анимации ---------- */
.reveal { opacity: 1; }
@keyframes pulse { 0% { box-shadow: 0 0 0 0 rgba(34, 197, 94, .55); } 70% { box-shadow: 0 0 0 7px rgba(34, 197, 94, 0); } 100% { box-shadow: 0 0 0 0 rgba(34, 197, 94, 0); } }
@keyframes spin { to { transform: rotate(360deg); } }
@keyframes pop { from { opacity: 0; transform: scale(.97) translateY(6px); } to { opacity: 1; transform: none; } }
@keyframes sheet-up { from { transform: translateY(100%); } to { transform: none; } }
@keyframes toast-in { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
@keyframes toast-out { to { opacity: 0; transform: translateY(10px); } }
@keyframes slide-in { from { opacity: 0; transform: translateX(-10px); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; scroll-behavior: auto !important; }
}

/* ==== 90-appearance.css ==== */
/* Внешний вид из админки (Настройки → «Цвета и внешний вид»). Классы на <html> ставит App\Services\Theme::htmlClass(),
   фоновую картинку и её затемнение — App\Services\Theme::css(). Свои правки пишите в 99-custom.css. */

/* ---------- Без градиентов: кнопки, акценты и выделения — сплошным основным цветом ---------- */
html.no-grad { --grad: var(--primary); }
html.no-grad, html.no-grad[data-theme="light"] { --grad-soft: color-mix(in srgb, var(--primary) 12%, transparent); }
html.no-grad .promo-banner { background: color-mix(in srgb, var(--accent) 16%, var(--surface)); }
html.no-grad .bonus-box { background: color-mix(in srgb, var(--accent) 12%, var(--surface)); }
html.no-grad .pb-icon, html.no-grad .bonus-icon { background: var(--accent); }

/* ---------- Без цветной подсветки за картинками товаров, у карточки сервера и привилегий ---------- */
html.no-glow .product-media { background: var(--surface-2); }
html.no-glow .sh-card { background: var(--surface); }
html.no-glow .rank-card { background: var(--surface); }

/* ---------- Без свечения под кнопками ---------- */
html.no-btn-glow { --glow: none; }

/* ---------- Картинки товаров на всю карточку (обрезаются по краям, без полей) ---------- */
html.img-cover .product-media img { inset: 0; margin: 0; width: 100%; height: 100%; max-width: none; object-fit: cover; border-radius: 0; }
html.img-cover .sheet-product-media, html.img-cover .product-hero-media { overflow: hidden; }
html.img-cover .sheet-product-media img, html.img-cover .product-hero-media img { width: 100%; height: 100%; max-width: none; object-fit: cover; border-radius: 0; }

/* ---------- Скругление карточек ---------- */
html.r-sm { --r-sm: 6px; --r: 9px; --r-lg: 12px; }
html.r-lg { --r-sm: 14px; --r: 18px; --r-lg: 28px; }
html.r-none { --r-sm: 2px; --r: 3px; --r-lg: 4px; }
html.r-none .product-media img { border-radius: 2px; }

/* Фоновая картинка включена — на <html> есть класс has-bg-image (для своих правок в 99-custom.css) */

/* ==== 99-custom.css ==== */
/* ==========================================================================
   ВАШИ СТИЛИ. Этот файл подключается последним, поэтому всё, что написано
   здесь, перекрывает стили из остальных файлов.

   Удобно, чтобы не править «родные» файлы темы: при обновлении движка
   ваши правки останутся в одном месте.

   Примеры:
     .product-card { border-radius: 8px; }          — менее круглые карточки
     .site-footer  { background: #000; }            — чёрный подвал
     :root { --r-lg: 12px; }                        — скругления больших блоков
   ========================================================================== */

