:root {
  --bg: #090416;
  --bg-2: #110922;
  --panel: rgba(30, 19, 52, .66);
  --panel-solid: #1a1130;
  --line: rgba(181, 145, 255, .13);
  --line-strong: rgba(181, 145, 255, .32);
  --text: #f3eeff;
  --muted: #a99dc6;
  --dim: #7d7299;
  --violet: #8b5cf6;
  --violet-hi: #c4a1ff;
  --orchid: #d14ef0;
  --grad: linear-gradient(135deg, #7a3cf0 0%, #a23fe6 55%, #d14ef0 100%);
  --ok: #5ee6a0;
  --warn: #ffb86b;
  --bad: #ff6b8b;
  --r-lg: 22px;
  --r-md: 14px;
  --r-sm: 10px;
  --font: "Manrope", system-ui, -apple-system, "Segoe UI", sans-serif;
  --display: "Unbounded", "Manrope", system-ui, sans-serif;
  --mono: ui-monospace, "Cascadia Code", Consolas, monospace;
  color-scheme: dark;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--text);
  font: 16px/1.6 var(--font);
  overflow-x: hidden;
}
a { color: var(--violet-hi); }
h1, h2, h3 { font-family: var(--display); font-weight: 700; line-height: 1.15; margin: 0; letter-spacing: -.01em; }
p { margin: 0; }
.muted { color: var(--muted); }
.ic { width: 18px; height: 18px; flex: none; }
[hidden] { display: none !important; }

/* фон: два мягких фиолетовых свечения и сетка */
.aura {
  position: fixed; inset: 0; z-index: -1; pointer-events: none;
  background:
    radial-gradient(60vw 50vh at 85% -10%, rgba(139, 92, 246, .28), transparent 60%),
    radial-gradient(50vw 45vh at -5% 105%, rgba(209, 78, 240, .16), transparent 60%),
    linear-gradient(var(--bg), var(--bg-2));
}
.aura::after {
  content: ""; position: absolute; inset: 0;
  background-image:
    linear-gradient(rgba(181, 145, 255, .045) 1px, transparent 1px),
    linear-gradient(90deg, rgba(181, 145, 255, .045) 1px, transparent 1px);
  background-size: 48px 48px;
  mask-image: radial-gradient(ellipse at 50% 0%, #000 20%, transparent 75%);
  -webkit-mask-image: radial-gradient(ellipse at 50% 0%, #000 20%, transparent 75%);
}

.wrap { width: min(1180px, 100% - 32px); margin-inline: auto; }

/* ───────── верхняя панель ───────── */
.topbar {
  position: sticky; top: 0; z-index: 30;
  display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 20px;
  padding: 12px max(16px, calc((100% - 1240px) / 2));
  background: rgba(9, 6, 15, .72);
  backdrop-filter: blur(16px) saturate(140%);
  -webkit-backdrop-filter: blur(16px) saturate(140%);
  border-bottom: 1px solid var(--line);
}
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; color: var(--text); }
.brand-mark {
  width: 40px; height: 40px; border-radius: 12px; object-fit: cover; flex: none;
  box-shadow: 0 0 0 1px var(--line-strong), 0 6px 18px -6px rgba(162, 63, 230, .6);
}
.brand-name { font: 700 17px/1 var(--display); letter-spacing: .04em; }

/* «док» — панель разделов */
.dock {
  justify-self: center;
  display: flex; align-items: center; gap: 4px;
  padding: 5px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: var(--panel);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .04), 0 10px 30px -18px rgba(0, 0, 0, .8);
}
.dock-item {
  position: relative;
  display: flex; align-items: center; gap: 8px;
  padding: 9px 14px;
  border: 0; border-radius: 13px;
  background: transparent;
  color: var(--muted);
  font: 600 14.5px/1 var(--font);
  text-decoration: none; white-space: nowrap; cursor: pointer;
  transition: color .18s, background-color .18s, transform .18s;
}
.dock-item:hover { color: var(--text); background: rgba(139, 92, 246, .12); }
.dock-item:active { transform: scale(.97); }
.dock-item:focus-visible, .btn:focus-visible, .icon-btn:focus-visible, .tile:focus-visible {
  outline: 2px solid var(--violet-hi); outline-offset: 2px;
}
.dock-item[aria-current="page"], .dock-more.is-active > .dock-item {
  color: #fff;
  background: var(--grad);
  box-shadow: 0 6px 22px -6px rgba(162, 63, 230, .7), inset 0 1px 0 rgba(255, 255, 255, .25);
}
.lbl-short { display: none; }
.chev { width: 14px; height: 14px; transition: transform .2s; }
.js-more[aria-expanded="true"] .chev { transform: rotate(180deg); }

/* выпадающая панель «Сервисы» */
.dock-more { position: relative; }
.mega {
  position: absolute; top: calc(100% + 14px); right: -6px;
  width: min(560px, 92vw);
  padding: 10px;
  border: 1px solid var(--line-strong);
  border-radius: var(--r-lg);
  background: rgba(22, 14, 40, .96);
  backdrop-filter: blur(18px); -webkit-backdrop-filter: blur(18px);
  box-shadow: 0 30px 60px -20px rgba(0, 0, 0, .9), 0 0 0 1px rgba(0, 0, 0, .3);
  animation: pop .18s ease-out;
}
.mega::before {
  content: ""; position: absolute; top: -7px; right: 48px;
  width: 12px; height: 12px; transform: rotate(45deg);
  background: rgba(22, 14, 40, .96);
  border-left: 1px solid var(--line-strong); border-top: 1px solid var(--line-strong);
}
@keyframes pop { from { opacity: 0; transform: translateY(-6px); } to { opacity: 1; transform: none; } }
.mega-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 4px; }
.tile {
  display: flex; gap: 12px; align-items: flex-start;
  padding: 12px; border-radius: var(--r-md);
  color: var(--text); text-decoration: none;
  transition: background-color .15s;
}
.tile:hover, .tile[aria-current="page"] { background: rgba(139, 92, 246, .14); }
.tile-ic {
  display: grid; place-items: center; flex: none;
  width: 38px; height: 38px; border-radius: 11px;
  background: rgba(139, 92, 246, .16); color: var(--violet-hi);
  border: 1px solid var(--line);
}
.tile[aria-current="page"] .tile-ic { background: var(--grad); color: #fff; }
.tile-txt { display: grid; gap: 2px; }
.tile-txt b { font-size: 14.5px; }
.tile-txt small { color: var(--muted); font-size: 12.5px; line-height: 1.4; }

/* пользователь: кнопка-профиль и меню с выходом */
.me { position: relative; display: flex; align-items: center; justify-self: end; }
.me-chip {
  display: flex; align-items: center; gap: 8px;
  padding: 4px 10px 4px 4px; border-radius: 999px;
  border: 1px solid var(--line); background: var(--panel); color: var(--text);
  font: 600 14px/1 var(--font); cursor: pointer;
  transition: border-color .15s, background-color .15s;
}
.me-chip:hover, .me-chip[aria-expanded="true"] { border-color: var(--line-strong); background: rgba(139, 92, 246, .14); }
.me-chip:focus-visible { outline: 2px solid var(--violet-hi); outline-offset: 2px; }
.me-chip .chev { color: var(--muted); }
.me-chip[aria-expanded="true"] .chev { transform: rotate(180deg); }
.me-ava {
  display: grid; place-items: center; width: 28px; height: 28px; border-radius: 50%; flex: none;
  background: var(--grad); color: #fff; font-size: 13px; font-weight: 700;
}
.me-ava.big { width: 42px; height: 42px; font-size: 17px; }
.me-name { max-width: 140px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.profile {
  position: absolute; top: calc(100% + 12px); right: 0; z-index: 40;
  width: 260px; padding: 8px;
  border: 1px solid var(--line-strong); border-radius: var(--r-lg);
  background: rgba(22, 14, 40, .97);
  box-shadow: 0 30px 60px -20px rgba(0, 0, 0, .9);
  animation: pop .18s ease-out;
}
.profile-head { display: flex; gap: 12px; align-items: center; padding: 10px 10px 14px; border-bottom: 1px solid var(--line); }
.profile-who { display: grid; gap: 3px; min-width: 0; }
.profile-who b { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.profile-who small { color: var(--muted); font-size: 12.5px; }
.profile form { margin: 6px 0 0; }
.profile-out {
  display: flex; align-items: center; gap: 10px; width: 100%;
  padding: 11px 12px; border: 0; border-radius: var(--r-md);
  background: transparent; color: #ffb3c4; font: 600 14.5px/1 var(--font); cursor: pointer; text-align: left;
}
.profile-out:hover { background: rgba(255, 107, 139, .12); }
.profile-out:focus-visible { outline: 2px solid var(--violet-hi); outline-offset: -2px; }
.icon-btn {
  display: grid; place-items: center;
  width: 36px; height: 36px; padding: 0;
  border: 1px solid var(--line); border-radius: 11px;
  background: transparent; color: var(--muted); cursor: pointer;
  transition: color .15s, border-color .15s, background-color .15s;
}
.icon-btn:hover { color: var(--text); border-color: var(--line-strong); background: rgba(139, 92, 246, .1); }
.icon-btn.done { color: var(--ok); border-color: rgba(94, 230, 160, .4); }

/* ───────── общие блоки ───────── */
main.wrap { padding: 44px 0 64px; }
.eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  color: var(--violet-hi); font-size: 12.5px; font-weight: 700;
  letter-spacing: .14em; text-transform: uppercase;
}
.eyebrow .ic { width: 15px; height: 15px; }
.page-head { display: grid; gap: 14px; margin-bottom: 34px; max-width: 760px; }
.page-head h1 { font-size: clamp(30px, 5vw, 46px); }
.page-head p { color: var(--muted); font-size: 17.5px; }
.section-title { font-size: 20px; margin: 48px 0 18px; }

.panel {
  position: relative;
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  background: var(--panel);
  backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
}
.grid { display: grid; gap: 16px; }
.grid-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  padding: 13px 22px; border-radius: var(--r-md);
  border: 1px solid var(--line-strong); background: rgba(139, 92, 246, .08);
  color: var(--text); font: 700 15px/1 var(--font); text-decoration: none; cursor: pointer;
  transition: transform .15s, box-shadow .2s, background-color .2s, opacity .2s;
}
.btn:hover { background: rgba(139, 92, 246, .16); }
.btn:active { transform: translateY(1px); }
.btn-main {
  border-color: transparent; background: var(--grad); color: #fff;
  box-shadow: 0 10px 30px -10px rgba(162, 63, 230, .75), inset 0 1px 0 rgba(255, 255, 255, .25);
}
.btn-main:hover { background: var(--grad); box-shadow: 0 14px 36px -10px rgba(209, 78, 240, .85), inset 0 1px 0 rgba(255, 255, 255, .3); }
.btn[aria-disabled="true"] { opacity: .38; pointer-events: none; filter: saturate(.4); }
.actions { display: flex; flex-wrap: wrap; gap: 12px; }

/* ───────── главная ───────── */
.home-hero {
  display: grid; grid-template-columns: auto 1fr; gap: 32px; align-items: center;
  margin-bottom: 40px;
}
.home-emblem {
  width: 168px; height: 168px; border-radius: 36px; object-fit: cover;
  box-shadow: 0 0 0 1px var(--line-strong), 0 24px 60px -18px rgba(162, 63, 230, .75);
}
.home-hero .hero-txt { display: grid; gap: 14px; }
.home-hero h1 { font-size: clamp(34px, 6vw, 58px); letter-spacing: .02em; }
.home-hero p { color: var(--muted); font-size: 18px; max-width: 600px; }
.live-dot { display: inline-flex; align-items: center; gap: 8px; }
.live-dot::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--orchid); box-shadow: 0 0 0 4px rgba(209, 78, 240, .2); }

.links { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.links.two { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.links.one { grid-template-columns: 1fr; }
.link-card {
  --brand: var(--violet);
  position: relative; overflow: hidden;
  display: flex; align-items: center; gap: 14px;
  min-height: 78px; padding: 16px 18px;
  border: 1px solid var(--line); border-radius: var(--r-lg);
  background: var(--panel);
  color: var(--text); text-decoration: none;
  transition: transform .18s, border-color .18s, background-color .18s, box-shadow .18s;
}
.link-card::after {
  content: ""; position: absolute; inset: 0; pointer-events: none; opacity: 0; transition: opacity .2s;
  background: radial-gradient(120% 140% at 0% 0%, color-mix(in srgb, var(--brand) 22%, transparent), transparent 60%);
}
a.link-card:hover { transform: translateY(-2px); border-color: color-mix(in srgb, var(--brand) 55%, transparent);
  box-shadow: 0 16px 40px -22px color-mix(in srgb, var(--brand) 80%, transparent); }
a.link-card:hover::after { opacity: 1; }
a.link-card:active { transform: translateY(0); }
a.link-card:focus-visible { outline: 2px solid var(--violet-hi); outline-offset: 2px; }
.lc-ic {
  position: relative; z-index: 1; display: grid; place-items: center; flex: none;
  width: 46px; height: 46px; border-radius: 14px;
  background: color-mix(in srgb, var(--brand) 18%, transparent); color: var(--brand);
  border: 1px solid color-mix(in srgb, var(--brand) 35%, transparent);
}
.lc-ic .ic { width: 22px; height: 22px; }
.lc-txt { position: relative; z-index: 1; display: grid; gap: 3px; min-width: 0; flex: 1; }
.lc-txt b { font-size: 15.5px; }
.lc-txt small { color: var(--muted); font-size: 13px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.lc-go { position: relative; z-index: 1; color: var(--dim); transition: color .15s, transform .15s; }
a.link-card:hover .lc-go { color: var(--brand); transform: translate(2px, -2px); }
.soon { position: relative; z-index: 1; padding: 4px 10px; border-radius: 999px; font-size: 12px; font-weight: 700;
  color: var(--muted); border: 1px dashed var(--line-strong); white-space: nowrap; }
.link-card.is-soon { opacity: .62; }
.lc-telegram { --brand: #2aabee; }
.lc-twitch { --brand: #a970ff; }
.lc-youtube { --brand: #ff3355; }
.lc-vk { --brand: #3d8bff; }
.lc-vklive { --brand: #ff5f8a; }
.lc-bot { --brand: #c4a1ff; }
.lc-heart { --brand: #ff7aa8; }
.lc-download, .lc-calc, .lc-help { --brand: #b98cff; }
.lc-handshake { --brand: #ffc46b; }
.home-split { display: grid; grid-template-columns: 1.6fr 1fr; gap: 28px; }

/* ───────── модпак ───────── */
.mods-hero { display: grid; grid-template-columns: 1.15fr .85fr; gap: 28px; align-items: center; margin-bottom: 44px; scroll-margin-top: 90px; }
.mods-hero .page-head { margin-bottom: 0; }
.mods-hero .dl-card { padding: 22px; }
.dl-solo { display: grid; gap: 12px; }
.dl-solo .alert { margin: 0; }
.once {
  display: flex; gap: 14px; align-items: center; margin-top: 4px;
  padding: 14px 16px; border-radius: var(--r-md);
  border: 1px solid rgba(94, 230, 160, .3); background: rgba(94, 230, 160, .07);
}
.once .ic { color: var(--ok); width: 22px; height: 22px; }
.once b { color: #c9f7df; }
.features { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; }
.feature { display: grid; gap: 10px; align-content: start; }
.feature h3 { font-size: 16px; font-family: var(--font); font-weight: 700; }
.feature p { color: var(--muted); font-size: 14.5px; }
.how { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; counter-reset: how; }
.how li { list-style: none; display: grid; gap: 8px; align-content: start; }
.how li::before {
  counter-increment: how; content: counter(how);
  display: grid; place-items: center; width: 40px; height: 40px; border-radius: 12px;
  font: 700 16px/1 var(--display); background: var(--grad); color: #fff;
}
.how b { font-size: 16px; }
.how p { color: var(--muted); font-size: 14.5px; }
.how { padding: 0; margin: 0; }
.notes { display: grid; gap: 12px; margin-top: 44px; }
.notes-head { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; flex-wrap: wrap; }
.notes-head h2 { font-size: 18px; }
.notes-lead { color: var(--text); font-weight: 600; }
.notes-list { margin: 0; padding-left: 20px; color: var(--muted); display: grid; gap: 6px; }

/* ───────── установка ───────── */
.alert {
  margin: 0 0 18px; padding: 12px 16px; border-radius: var(--r-md);
  border: 1px solid rgba(255, 107, 139, .35); background: rgba(255, 107, 139, .1); color: #ffc2cf;
  font-size: 14.5px;
}
.alert.info { border-color: rgba(255, 184, 107, .35); background: rgba(255, 184, 107, .08); color: #ffdcb3; }
.steps { display: grid; gap: 18px; counter-reset: step; }
.step { display: grid; grid-template-columns: 56px 1fr; gap: 20px; }
.step-no {
  position: relative;
  display: grid; place-items: center; align-self: start;
  width: 56px; height: 56px; border-radius: 16px;
  font: 700 18px/1 var(--display);
  background: var(--panel-solid); border: 1px solid var(--line-strong); color: var(--violet-hi);
}
.step.is-done .step-no { background: var(--grad); color: #fff; border-color: transparent; }
.step-body { display: grid; gap: 14px; }
.step-body h2 { font-size: 20px; }
.step-body > p { color: var(--muted); }
.checks { display: grid; gap: 8px; }
.check {
  display: flex; align-items: center; gap: 12px;
  padding: 12px 14px; border-radius: var(--r-md);
  border: 1px solid var(--line); background: rgba(9, 6, 15, .35);
  cursor: pointer; transition: border-color .15s, background-color .15s;
}
.check:hover { border-color: var(--line-strong); }
.check input { appearance: none; -webkit-appearance: none; margin: 0; flex: none;
  width: 22px; height: 22px; border-radius: 7px; border: 1.5px solid var(--line-strong); background: transparent;
  display: grid; place-items: center; cursor: pointer; }
.check input:checked { background: var(--grad); border-color: transparent; }
.check input:checked::after { content: ""; width: 10px; height: 5px; border: solid #fff; border-width: 0 0 2px 2px; transform: translateY(-1px) rotate(-45deg); }
.check input:focus-visible { outline: 2px solid var(--violet-hi); outline-offset: 2px; }
.check:has(input:checked) { border-color: rgba(139, 92, 246, .5); background: rgba(139, 92, 246, .08); }

.dl-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.dl-card { display: grid; gap: 16px; align-content: start; padding: 20px; border-radius: var(--r-lg); border: 1px solid var(--line); background: rgba(9, 6, 15, .4); }
.dl-card.primary { border-color: var(--line-strong); background: linear-gradient(160deg, rgba(122, 60, 240, .18), rgba(9, 6, 15, .4) 60%); }
.dl-card.missing { opacity: .7; }
.dl-head { display: flex; gap: 12px; align-items: center; }
.dl-icon { display: grid; place-items: center; width: 42px; height: 42px; border-radius: 12px; background: rgba(139, 92, 246, .16); color: var(--violet-hi); }
.dl-card.primary .dl-icon { background: var(--grad); color: #fff; }
.dl-title { font-weight: 700; font-size: 16px; }
.dl-kind { color: var(--muted); font-size: 13px; }
.dl-meta { display: flex; gap: 24px; margin: 0; }
.dl-meta dt { color: var(--dim); font-size: 12px; text-transform: uppercase; letter-spacing: .08em; }
.dl-meta dd { margin: 2px 0 0; font-weight: 600; }
.hash { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 10px; padding: 8px 8px 8px 12px; border-radius: var(--r-sm); background: rgba(0, 0, 0, .3); border: 1px solid var(--line); }
.hash-label { font-size: 11px; font-weight: 700; color: var(--dim); letter-spacing: .08em; }
.hash code { font: 12px/1.3 var(--mono); color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hash .icon-btn { width: 30px; height: 30px; border-radius: 8px; }
.hash .ic { width: 15px; height: 15px; }
.gate-note { font-size: 13.5px; color: var(--dim); }

.tips { margin: 0; padding-left: 20px; color: var(--muted); display: grid; gap: 6px; }
.tips b { color: var(--text); }
kbd { font: 600 12.5px/1 var(--mono); padding: 3px 7px; border-radius: 6px; border: 1px solid var(--line-strong); background: rgba(0, 0, 0, .3); color: var(--text); }

/* ───────── таблицы (ПК, настройки) ───────── */
.spec { width: 100%; border-collapse: collapse; }
.spec th, .spec td { text-align: left; padding: 13px 0; border-bottom: 1px dashed var(--line); vertical-align: top; }
.spec tr:last-child th, .spec tr:last-child td { border-bottom: 0; }
.spec th { width: 38%; color: var(--muted); font-weight: 600; padding-right: 16px; }
.panel h2 { font-size: 17px; margin-bottom: 8px; display: flex; gap: 10px; align-items: center; }
.panel h2 .tile-ic { width: 34px; height: 34px; }

.empty { text-align: center; padding: 56px 24px; display: grid; gap: 14px; justify-items: center; }
.empty .tile-ic { width: 56px; height: 56px; border-radius: 16px; }
.empty h1 { font-size: 26px; }

/* ───────── подвал ───────── */
.foot { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px 24px; padding: 24px 0 40px; border-top: 1px solid var(--line); font-size: 13.5px; }

/* ───────── вход ───────── */
.login-body { display: grid; place-items: center; padding: 24px 16px; }
.gate {
  width: min(920px, 100%);
  display: grid; grid-template-columns: 1fr 1.1fr;
  border: 1px solid var(--line-strong); border-radius: 28px; overflow: hidden;
  background: rgba(18, 11, 32, .8);
  box-shadow: 0 40px 100px -40px rgba(122, 60, 240, .55);
}
.gate-art {
  position: relative; min-height: 440px; display: grid; place-items: center; overflow: hidden;
  background: radial-gradient(circle at 50% 45%, rgba(162, 63, 230, .45), transparent 60%), #0e0819;
  border-right: 1px solid var(--line);
}
.orbit { position: absolute; inset: 0; display: grid; place-items: center; }
.orbit span { position: absolute; border-radius: 50%; border: 1px solid rgba(196, 161, 255, .22); animation: spin 26s linear infinite; }
.orbit span:nth-child(1) { width: 180px; height: 180px; }
.orbit span:nth-child(2) { width: 280px; height: 280px; border-style: dashed; animation-duration: 40s; animation-direction: reverse; }
.orbit span:nth-child(3) { width: 390px; height: 390px; border-color: rgba(196, 161, 255, .1); }
.orbit span:nth-child(1)::after, .orbit span:nth-child(3)::after {
  content: ""; position: absolute; top: -5px; left: 50%; width: 9px; height: 9px; border-radius: 50%;
  background: var(--orchid); box-shadow: 0 0 14px var(--orchid);
}
@keyframes spin { to { transform: rotate(360deg); } }
.gate-brand { position: relative; display: grid; justify-items: center; gap: 12px; text-align: center; }
.gate-emblem { width: 180px; height: 180px; border-radius: 40px; object-fit: cover;
  box-shadow: 0 0 0 1px var(--line-strong), 0 20px 60px -16px rgba(162, 63, 230, .8); }
.btn-tg {
  width: 100%; padding-block: 15px; border-color: transparent; color: #fff;
  background: linear-gradient(135deg, #2aabee, #6a5cff 70%, #a23fe6);
  box-shadow: 0 10px 30px -10px rgba(42, 171, 238, .6), inset 0 1px 0 rgba(255, 255, 255, .25);
}
.btn-tg:hover { background: linear-gradient(135deg, #36b6f5, #7868ff 70%, #ad4cf0); }
.btn-tg:disabled { opacity: .6; cursor: progress; }
.btn-tg .ic { width: 20px; height: 20px; }
.tg-wait { display: grid; gap: 10px; margin-top: 12px; padding: 14px; border-radius: var(--r-md);
  border: 1px solid var(--line); background: rgba(0, 0, 0, .25); }
.tg-status { font-size: 14.5px; }
.tg-status.bad { color: #ffb3c4; }
.tg-code-row { font-size: 14px; }
.tg-code { font: 700 16px/1 var(--mono); letter-spacing: .12em; color: var(--violet-hi); }
.tg-wait .btn { padding: 10px 14px; font-size: 14px; }
.code-box { border-top: 1px solid var(--line); padding-top: 14px; margin-top: 4px; }
.code-box summary { cursor: pointer; color: var(--muted); font-weight: 600; font-size: 14.5px; list-style: none; display: flex; align-items: center; gap: 8px; }
.code-box summary::-webkit-details-marker { display: none; }
.code-box summary::before { content: "›"; display: inline-block; transition: transform .15s; color: var(--violet-hi); font-size: 18px; line-height: 1; }
.code-box[open] summary::before { transform: rotate(90deg); }
.code-box summary:hover { color: var(--text); }
.code-box .code-form { margin-top: 12px; }
.gate-site { font: 700 26px/1 var(--display); letter-spacing: .06em; margin-top: 8px; }
.gate-tag { color: var(--muted); font-size: 14px; }
.gate-form { display: grid; gap: 16px; align-content: center; padding: 48px 44px; }
.gate-form h1 { font-size: 30px; }
.code-form { display: grid; gap: 10px; margin-top: 6px; }
.code-form label { font-size: 13px; font-weight: 700; color: var(--muted); letter-spacing: .04em; }
.code-input {
  width: 100%; padding: 15px 16px; border-radius: var(--r-md);
  border: 1px solid var(--line-strong); background: rgba(0, 0, 0, .35); color: var(--text);
  font: 600 17px/1.2 var(--mono); letter-spacing: .12em;
  transition: border-color .15s, box-shadow .15s;
}
.code-input::placeholder { color: var(--dim); letter-spacing: .12em; }
.code-input:focus { outline: none; border-color: var(--violet); box-shadow: 0 0 0 4px rgba(139, 92, 246, .2); }
.code-form .btn { margin-top: 6px; padding-block: 15px; }
.gate-hint { display: flex; gap: 10px; align-items: center; color: var(--dim); font-size: 13.5px; margin-top: 4px; }
.gate-hint .ic { color: var(--violet-hi); }

/* ───────── адаптив ───────── */
@media (max-width: 1180px) {
  .me-name { display: none; }
  .me-chip { padding: 4px; }
  .dock-item { padding: 9px 11px; }
}
@media (max-width: 960px) {
  body { padding-bottom: 84px; }
  /* backdrop-filter у шапки делает её «рамкой» для position:fixed, поэтому на мобильных его нет */
  .topbar { grid-template-columns: auto 1fr; padding: 10px 16px; background: rgba(9, 6, 15, .94); backdrop-filter: none; -webkit-backdrop-filter: none; }
  .lbl-full { display: none; }
  .lbl-short { display: inline !important; }
  .me { grid-column: 2; }
  .dock {
    position: fixed; left: 10px; right: 10px; bottom: 10px; top: auto; justify-self: stretch;
    justify-content: space-between; gap: 2px; padding: 6px;
    background: rgba(22, 14, 40, .92);
    backdrop-filter: blur(18px); -webkit-backdrop-filter: blur(18px);
    border-color: var(--line-strong);
    box-shadow: 0 20px 50px -10px rgba(0, 0, 0, .9);
  }
  .dock > a, .dock-more { flex: 1 1 0; min-width: 0; }
  .dock-item { flex-direction: column; gap: 5px; width: 100%; padding: 8px 2px; font-size: 11px; border-radius: 12px; }
  .dock-item span { max-width: 100%; overflow: hidden; text-overflow: ellipsis; }
  .dock-item .chev { display: none; }
  .dock-more { position: static; }
  .mega { top: auto; bottom: calc(100% + 10px); right: 0; left: 0; width: auto; }
  .mega::before { display: none; }
  .grid-3, .grid-2, .dl-grid, .mods-hero, .home-split, .how { grid-template-columns: 1fr; }
  .links { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .features { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .profile { position: fixed; top: 64px; right: 12px; }
  .gate { grid-template-columns: 1fr; }
  .gate-art { min-height: 220px; border-right: 0; border-bottom: 1px solid var(--line); }
  .gate-form { padding: 32px 24px; }
}
@media (max-width: 520px) {
  main.wrap { padding-top: 28px; }
  .mega-grid { grid-template-columns: 1fr; }
  .links, .links.two, .features { grid-template-columns: 1fr; }
  .home-hero { grid-template-columns: 1fr; justify-items: start; gap: 20px; }
  .home-emblem { width: 112px; height: 112px; border-radius: 26px; }
  .gate-emblem { width: 120px; height: 120px; border-radius: 28px; }
  .step { grid-template-columns: 1fr; gap: 12px; }
  .step-no { width: 44px; height: 44px; border-radius: 13px; font-size: 16px; }
  .panel { padding: 18px; }
  .spec th { width: 45%; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}

/* ───────── подвал и правила ───────── */
.foot { display: grid; gap: 10px; }
.foot-top { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 10px 24px; }
.foot-links { display: flex; flex-wrap: wrap; gap: 6px 18px; }
.foot-links a { color: var(--muted); text-decoration: none; font-size: 13.5px; }
.foot-links a:hover { color: var(--violet-hi); text-decoration: underline; text-underline-offset: 3px; }
.foot-note { font-size: 12.5px; }
.login-body { grid-template-rows: 1fr auto; }
.login-foot { justify-content: center; padding: 18px 0 4px; }
.gate-legal { color: var(--dim); font-size: 12.5px; }
.gate-legal a { color: var(--muted); }
.btn-sm { padding: 9px 16px; font-size: 14px; }
.is-public .topbar { grid-template-columns: auto 1fr auto; }

.legal { max-width: 820px; display: grid; gap: 18px; }
.legal .page-head { margin-bottom: 6px; }
.legal-toc { display: flex; flex-wrap: wrap; gap: 8px; }
.legal-toc a { padding: 7px 12px; border-radius: 999px; border: 1px solid var(--line); color: var(--muted); text-decoration: none; font-size: 13.5px; font-weight: 600; }
.legal-toc a:hover, .legal-toc a[aria-current="page"] { border-color: var(--line-strong); color: var(--text); background: rgba(139, 92, 246, .12); }
.legal section { scroll-margin-top: 90px; }
.legal h2 { font-size: 18px; margin-bottom: 10px; display: flex; gap: 10px; align-items: baseline; }
.legal h2 .n { color: var(--violet-hi); font-size: 14px; }
.legal p, .legal li { color: var(--muted); }
.legal ul { margin: 8px 0 0; padding-left: 20px; display: grid; gap: 6px; }
.legal b { color: var(--text); }
.legal .updated { color: var(--dim); font-size: 13px; }
@media (max-width: 960px) { .is-public .topbar .btn-sm { grid-column: 2; justify-self: end; } }

/* вход: два способа подтвердить */
.tg-wait { gap: 0; padding: 6px; }
.tg-ways { display: grid; gap: 4px; }
.tg-way { display: grid; grid-template-columns: auto 1fr; gap: 10px 12px; align-items: center; padding: 12px; border-radius: var(--r-md); }
.tg-way > div { display: grid; gap: 3px; }
.tg-way small { color: var(--muted); font-size: 13px; line-height: 1.4; }
.tg-way .btn, .tg-way .tg-code { grid-column: 1 / -1; }
.tg-way-n { display: grid; place-items: center; width: 28px; height: 28px; border-radius: 9px; background: var(--grad); color: #fff; font: 700 13px/1 var(--display); }
.tg-or { display: flex; align-items: center; gap: 10px; color: var(--dim); font-size: 12px; text-transform: uppercase; letter-spacing: .12em; padding: 0 12px; }
.tg-or::before, .tg-or::after { content: ""; flex: 1; height: 1px; background: var(--line); }
.tg-code {
  display: flex; align-items: center; justify-content: center; gap: 12px; width: 100%;
  padding: 12px; border-radius: var(--r-md); border: 1px dashed var(--line-strong);
  background: rgba(139, 92, 246, .08); color: var(--violet-hi); cursor: pointer;
  font: 700 28px/1 var(--mono); letter-spacing: .14em;
}
.tg-code small { font: 600 12px/1 var(--font); letter-spacing: 0; color: var(--muted); }
.tg-code:hover { border-color: var(--violet); background: rgba(139, 92, 246, .14); }
.tg-code:focus-visible { outline: 2px solid var(--violet-hi); outline-offset: 2px; }
.tg-status { margin-top: 10px; font-size: 14px; color: var(--muted); }
.tg-status:empty { display: none; }

/* вход по почте и открытый сайт */
.or-line { display: flex; align-items: center; gap: 12px; color: var(--dim); font-size: 12px; text-transform: uppercase; letter-spacing: .12em; margin: 4px 0; }
.or-line::before, .or-line::after { content: ""; flex: 1; height: 1px; background: var(--line); }
.mail-form { display: grid; gap: 10px; }
.mail-form label { font-size: 13px; font-weight: 700; color: var(--muted); letter-spacing: .04em; }
.mail-input {
  width: 100%; padding: 14px 16px; border-radius: var(--r-md);
  border: 1px solid var(--line-strong); background: rgba(0, 0, 0, .35); color: var(--text); font: 600 16px/1.2 var(--font);
}
.mail-input:focus { outline: none; border-color: var(--violet); box-shadow: 0 0 0 4px rgba(139, 92, 246, .2); }
.mail-sent { font-size: 14px; color: var(--muted); }
.mail-sent b { color: var(--text); word-break: break-all; }
.mail-again { display: flex; justify-content: space-between; gap: 12px; margin-top: 8px; font-size: 13.5px; }
.mail-again a { color: var(--muted); }
.link-btn { padding: 0; border: 0; background: none; color: var(--violet-hi); font: 600 13.5px/1.4 var(--font); cursor: pointer; text-decoration: underline; text-underline-offset: 3px; }
.mail-off { display: flex; align-items: center; gap: 10px; padding: 12px 14px; border-radius: var(--r-md); border: 1px dashed var(--line-strong); color: var(--muted); font-size: 14px; }
.gate-back { justify-self: start; color: var(--muted); font-size: 14px; text-decoration: none; }
.gate-back:hover { color: var(--text); }
.dl-closed .dl-icon { background: rgba(255, 184, 107, .14); color: #ffc46b; }
.me .btn-sm .ic { width: 16px; height: 16px; }

.tg-widget { display: flex; justify-content: center; min-height: 48px; }

/* профиль */
img.me-ava, video.me-ava { object-fit: cover; background: var(--panel-solid); display: block; }
.me-ava.huge { width: 128px; height: 128px; font-size: 48px; border-radius: 32px; box-shadow: 0 0 0 1px var(--line-strong), 0 16px 40px -16px rgba(162, 63, 230, .7); }
.profile-link {
  display: flex; align-items: center; gap: 10px; margin-top: 6px; padding: 11px 12px; border-radius: var(--r-md);
  color: var(--text); text-decoration: none; font: 600 14.5px/1 var(--font);
}
.profile-link:hover { background: rgba(139, 92, 246, .14); }
.profile-grid { display: grid; grid-template-columns: 320px 1fr; gap: 16px; align-items: start; }
.profile-card { display: grid; gap: 20px; }
.ava-edit { display: grid; justify-items: center; gap: 12px; text-align: center; }
.ava-edit form { margin: 0; }
.ava-edit label.btn { cursor: pointer; }
.small { font-size: 12.5px; }
.profile-facts { margin: 0; display: grid; gap: 10px; border-top: 1px solid var(--line); padding-top: 16px; }
.profile-facts div { display: flex; justify-content: space-between; gap: 12px; }
.profile-facts dt { color: var(--muted); font-size: 13.5px; }
.profile-facts dd { margin: 0; font-weight: 600; font-size: 14px; text-align: right; word-break: break-all; }
.profile-form { display: grid; gap: 10px; }
.profile-form label { font-size: 13px; font-weight: 700; color: var(--muted); letter-spacing: .04em; margin-top: 6px; }
.profile-form textarea { resize: vertical; min-height: 84px; font-weight: 500; }
.profile-form .btn { justify-self: start; margin-top: 8px; }
.alert.ok { border-color: rgba(94, 230, 160, .4); background: rgba(94, 230, 160, .08); color: #b9f5d6; }
@media (max-width: 860px) { .profile-grid { grid-template-columns: 1fr; } }

/* привязанные аккаунты */
.linked { grid-column: 1 / -1; display: grid; gap: 10px; }
.linked h2 { font-size: 17px; }
.link-row {
  display: flex; align-items: center; gap: 14px; flex-wrap: wrap;
  padding: 12px 14px; border-radius: var(--r-md); border: 1px solid var(--line); background: rgba(0, 0, 0, .2);
}
.link-row .lc-ic { width: 40px; height: 40px; border-radius: 12px; }
.lc-telegram-ic { --brand: #2aabee; }
.lc-vk-ic { --brand: #3d8bff; }
.link-txt { display: grid; gap: 2px; flex: 1; min-width: 160px; }
.link-txt small { color: var(--muted); font-size: 13px; }
.link-row form { margin: 0; }
.link-row.is-on { border-color: rgba(94, 230, 160, .35); }
.link-badge { display: grid; place-items: center; width: 30px; height: 30px; border-radius: 50%; background: rgba(94, 230, 160, .15); color: var(--ok); }
.link-row.is-soon { opacity: .5; filter: grayscale(1); }
.small-widget { min-height: 0; }

/* VK ID */
.btn-vk {
  width: 100%; padding-block: 14px; border-color: transparent; color: #fff;
  background: #0077ff; box-shadow: 0 10px 30px -12px rgba(0, 119, 255, .6), inset 0 1px 0 rgba(255, 255, 255, .2);
}
.btn-vk:hover { background: #1a85ff; }
.btn-vk .ic { width: 20px; height: 20px; }
.link-row .btn-vk { width: auto; padding: 9px 14px; }
.tg-widget + .btn-vk, .tg-widget + p + .btn-vk { margin-top: 2px; }

/* привязка почты */
.lc-mail-ic { --brand: #c4a1ff; }
.link-mail { display: flex; gap: 8px; flex-wrap: wrap; margin: 0; }
.link-mail .mail-input { width: 240px; padding: 9px 12px; font-size: 14px; }
.mail-link-code { display: grid; gap: 10px; max-width: 420px; margin-bottom: 16px; }
.mail-link-code .btn { justify-self: start; }

/* Wargaming / Lesta */
.btn-wg, .btn-lesta { width: 100%; padding-block: 14px; border-color: transparent; color: #fff; }
.btn-wg { background: #b3121c; box-shadow: 0 10px 30px -12px rgba(220, 30, 40, .55), inset 0 1px 0 rgba(255, 255, 255, .2); }
.btn-wg:hover { background: #cc1823; }
.btn-lesta { background: #e8590c; box-shadow: 0 10px 30px -12px rgba(232, 89, 12, .55), inset 0 1px 0 rgba(255, 255, 255, .2); }
.btn-lesta:hover { background: #f76707; }
.btn-wg .ic, .btn-lesta .ic { width: 20px; height: 20px; }
.link-row .btn-wg, .link-row .btn-lesta { width: auto; padding: 9px 14px; }
.lc-wg-ic { --brand: #ff4d56; }
.lc-lesta-ic { --brand: #ff8a3d; }

/* Telegram: своя кнопка в стиле остальных */
.btn-tg { width: 100%; padding-block: 14px; border-color: transparent; color: #fff;
  background: #229ed9; box-shadow: 0 10px 30px -12px rgba(34, 158, 217, .6), inset 0 1px 0 rgba(255, 255, 255, .2); }
.btn-tg:hover { background: #2aabee; }
.btn-tg .ic { width: 20px; height: 20px; }
.link-row .btn-tg { width: auto; padding: 9px 14px; }
.tg-return { width: min(420px, 100%); display: grid; justify-items: center; gap: 12px; text-align: center; padding: 36px 28px; }
.tg-return h1 { font-size: 22px; }
.gate-emblem.small { width: 72px; height: 72px; border-radius: 20px; }

/* привязка игры / вход в приложение через сайт */
.bridge { max-width: 560px; margin: 24px auto; display: grid; gap: 14px; }
.bridge h1 { font-size: 24px; }
.bridge form { margin: 4px 0; }
