/* =====================================================================
   ОРБИТА — веб-версия. Цвета и шрифты меняются здесь.
   ===================================================================== */
:root {
  color-scheme: light;
  --bg: #FFFFFF;
  --bg-soft: #F8FAFD;
  --card: #FFFFFF;
  --line: #EFF2F5;
  --line-strong: #E1E6EC;
  --text: #0D1421;
  --muted: #58667E;
  --faint: #8A94A8;
  --up: #16C784;
  --down: #EA3943;
  --accent: #3E4FC2;
  --accent-soft: rgba(62, 79, 194, .1);
  --pink: #C8235A;
  --purple: #6E3C9C;
  --gold: #F2B01E;
  --tg: #2AABEE;
  --grad: linear-gradient(90deg, #C8235A, #6E3C9C);
  --shadow: 0 6px 24px rgba(13, 20, 33, .08);
  --radius: 16px;
  --display: "Unbounded", "Arial Black", system-ui, sans-serif;
  --body: "Manrope", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
}
:root[data-theme="dark"] {
  color-scheme: dark;
  --bg: #0D1421;
  --bg-soft: #111A2B;
  --card: #171E2E;
  --line: #222B3D;
  --line-strong: #2E384C;
  --text: #FFFFFF;
  --muted: #A1A7BB;
  --faint: #6F7A90;
  --accent: #7E8BFF;
  --accent-soft: rgba(126, 139, 255, .14);
  --shadow: 0 6px 24px rgba(0, 0, 0, .35);
}

*, *::before, *::after { box-sizing: border-box }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100% }
body { margin: 0; background: var(--bg); color: var(--text); font-family: var(--body); font-size: 15px; line-height: 1.5; -webkit-font-smoothing: antialiased }
a { color: var(--accent); text-decoration: none }
a:hover { text-decoration: underline }
h1, h2, h3, h4 { font-family: var(--display); margin: 0; line-height: 1.15; letter-spacing: -.01em; text-wrap: balance }
p { margin: 0 }
img { max-width: 100%; display: block }
button, input, select, textarea { font: inherit; color: inherit }
:focus-visible { outline: 3px solid var(--gold); outline-offset: 2px; border-radius: 6px }
.num, .tnum { font-variant-numeric: tabular-nums }
.wrap { width: 100%; max-width: 1320px; margin: 0 auto; padding-inline: 20px }
.muted { color: var(--muted) }
.faint { color: var(--faint) }
.up { color: var(--up) }
.down { color: var(--down) }
.hidden { display: none !important }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto } *, *::before, *::after { animation: none !important; transition: none !important } }

/* ---------- кнопки, поля ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 40px; padding: 0 18px; border-radius: 10px; border: 0; background: var(--accent); color: #fff; font-weight: 700; font-size: 14px; cursor: pointer; text-decoration: none; transition: filter .15s, transform .15s; white-space: nowrap }
.btn:hover { filter: brightness(1.08); text-decoration: none }
.btn:active { transform: translateY(1px) }
.btn[disabled] { opacity: .5; cursor: not-allowed }
.btn.ghost { background: transparent; color: var(--text); border: 1px solid var(--line-strong) }
.btn.ghost:hover { background: var(--bg-soft) }
.btn.soft { background: var(--accent-soft); color: var(--accent) }
.btn.up { background: var(--up); color: #fff }
.btn.down { background: var(--down); color: #fff }
.btn.tg { background: var(--tg); color: #fff }
.btn.grad { background: var(--grad); color: #fff }
.btn.sm { min-height: 32px; padding: 0 12px; font-size: 13px; border-radius: 8px }
.btn.lg { min-height: 48px; padding: 0 24px; font-size: 15px; border-radius: 12px }
.btn.block { width: 100% }
.iconbtn { display: inline-grid; place-items: center; width: 38px; height: 38px; border-radius: 10px; border: 1px solid var(--line-strong); background: var(--card); color: var(--text); cursor: pointer }
.iconbtn:hover { background: var(--bg-soft) }
.field { display: grid; gap: 6px }
.field label, .lbl { font-size: 13px; font-weight: 700; color: var(--muted) }
.input, select.input, textarea.input { width: 100%; min-height: 42px; padding: 9px 12px; border-radius: 10px; border: 1px solid var(--line-strong); background: var(--card); color: var(--text) }
textarea.input { min-height: 96px; resize: vertical }
.input:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft) }
.check { display: flex; gap: 10px; align-items: flex-start; font-size: 14px; cursor: pointer }
.check input { margin-top: 3px; width: 17px; height: 17px; accent-color: var(--accent); flex: none }
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px }
.form-grid .full { grid-column: 1 / -1 }
@media (max-width: 640px) { .form-grid { grid-template-columns: 1fr } }

/* ---------- шапка ---------- */
.top { position: sticky; top: 0; z-index: 40; background: color-mix(in srgb, var(--bg) 92%, transparent); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); border-bottom: 1px solid var(--line) }
.top .wrap { display: flex; align-items: center; gap: 18px; min-height: 64px }
.logo { font-family: var(--display); font-weight: 800; font-size: 20px; letter-spacing: .04em; color: var(--text); text-decoration: none; display: flex; align-items: center; gap: 9px; flex: none }
.logo:hover { text-decoration: none }
.logo i { width: 26px; height: 26px; border-radius: 50%; background: var(--grad); position: relative; display: inline-block }
.logo i::after { content: ""; position: absolute; inset: -5px -9px; border: 2px solid var(--gold); border-radius: 50%; transform: rotate(-22deg) }
nav.menu { display: flex; align-items: center; gap: 4px; flex: 1; min-width: 0 }
nav.menu a { color: var(--text); font-weight: 700; font-size: 14px; padding: 8px 10px; border-radius: 8px; text-decoration: none; white-space: nowrap }
nav.menu a:hover { background: var(--bg-soft) }
nav.menu a.on { color: var(--accent) }
nav.menu a .soon { font-size: 10px; font-weight: 800; color: #fff; background: var(--pink); border-radius: 5px; padding: 1px 5px; margin-left: 5px; vertical-align: 2px }
.top-right { display: flex; align-items: center; gap: 8px; flex: none }
.pill { display: inline-flex; align-items: center; gap: 8px; padding: 6px 12px; border-radius: 999px; background: var(--bg-soft); border: 1px solid var(--line); font-size: 13px; font-weight: 700; white-space: nowrap; color: var(--text); text-decoration: none }
.pill:hover { text-decoration: none; border-color: var(--line-strong) }
.pill .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--up); box-shadow: 0 0 0 0 rgba(22, 199, 132, .6); animation: pulse 1.8s infinite }
.pill.wait .dot { background: var(--gold); box-shadow: 0 0 0 0 rgba(242, 176, 30, .6) }
@keyframes pulse { 0% { box-shadow: 0 0 0 0 rgba(22, 199, 132, .5) } 70% { box-shadow: 0 0 0 8px rgba(22, 199, 132, 0) } 100% { box-shadow: 0 0 0 0 rgba(22, 199, 132, 0) } }
.lang { display: flex; border: 1px solid var(--line-strong); border-radius: 10px; overflow: hidden }
.lang button { border: 0; background: transparent; padding: 0 10px; height: 36px; font-weight: 800; font-size: 12px; cursor: pointer; color: var(--muted) }
.lang button.on { background: var(--text); color: var(--bg) }
.avatar { width: 38px; height: 38px; border-radius: 50%; display: grid; place-items: center; font-weight: 800; color: #fff; background: var(--grad); border: 0; cursor: pointer; flex: none; font-size: 14px }
.menu-pop { position: absolute; right: 20px; top: 60px; min-width: 220px; background: var(--card); border: 1px solid var(--line); border-radius: 14px; box-shadow: var(--shadow); padding: 8px; display: grid; z-index: 60 }
.menu-pop a, .menu-pop button { text-align: left; padding: 10px 12px; border-radius: 8px; color: var(--text); font-weight: 600; background: none; border: 0; cursor: pointer; text-decoration: none }
.menu-pop a:hover, .menu-pop button:hover { background: var(--bg-soft) }
.menu-pop .who { padding: 8px 12px 10px; border-bottom: 1px solid var(--line); margin-bottom: 6px; font-size: 13px; color: var(--muted) }
.menu-pop .who b { display: block; color: var(--text); font-size: 15px }
.burger { display: none }
@media (max-width: 1100px) { .pill.week { display: none } }
@media (max-width: 980px) {
  .burger { display: inline-grid }
  nav.menu { display: none; position: absolute; left: 0; right: 0; top: 100%; flex-direction: column; align-items: stretch; background: var(--card); border-bottom: 1px solid var(--line); padding: 8px 20px 16px; box-shadow: var(--shadow) }
  nav.menu.open { display: flex }
  nav.menu a { padding: 12px 6px; font-size: 16px; border-bottom: 1px solid var(--line); border-radius: 0 }
  .top .wrap { position: relative; gap: 10px }
  .top-right { margin-left: auto }
}
@media (max-width: 640px) { .pill.wait { display: none } }
@media (max-width: 520px) { .theme-btn { display: none } .lang button { padding: 0 8px } .top-right { gap: 6px } }
@media (max-width: 360px) { .logo { font-size: 15px } .top-right .btn.sm { padding-inline: 10px } }

/* ---------- демо-плашка ---------- */
.demo-bar { background: repeating-linear-gradient(135deg, rgba(242, 176, 30, .16) 0 12px, rgba(242, 176, 30, .08) 12px 24px); border-bottom: 1px solid rgba(242, 176, 30, .35); font-size: 13px; color: var(--text) }
.demo-bar .wrap { display: flex; gap: 10px; align-items: center; min-height: 36px; flex-wrap: wrap; padding-block: 6px }
.badge { display: inline-flex; align-items: center; gap: 5px; font-size: 11px; font-weight: 800; letter-spacing: .04em; text-transform: uppercase; padding: 3px 8px; border-radius: 6px; background: var(--gold); color: #1A1300; white-space: nowrap }
.badge.blue { background: var(--accent-soft); color: var(--accent) }
.badge.pink { background: rgba(200, 35, 90, .12); color: var(--pink) }
.badge.green { background: rgba(22, 199, 132, .14); color: #0E9E68 }
.badge.grey { background: var(--bg-soft); color: var(--muted); border: 1px solid var(--line) }
:root[data-theme="dark"] .badge.green { color: var(--up) }

/* ---------- слайдер анонсов ---------- */
.slider { position: relative; height: clamp(230px, 33vh, 380px); margin-top: 18px; border-radius: 22px; overflow: hidden; background: #1B1340 }
.slides { display: flex; height: 100%; transition: transform .7s cubic-bezier(.6, .05, .25, 1) }
.slide { position: relative; flex: 0 0 100%; height: 100%; display: flex; align-items: center; color: #fff; text-decoration: none; overflow: hidden }
.slide:hover { text-decoration: none }
.slide .art { position: absolute; inset: 0 }
.slide .art img { width: 100%; height: 100%; object-fit: cover }
.slide .copy { position: relative; z-index: 2; padding: 0 clamp(22px, 5vw, 64px); max-width: 720px }
.slide .kicker { display: inline-block; font-size: 12px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; background: rgba(255, 255, 255, .16); border: 1px solid rgba(255, 255, 255, .28); padding: 4px 10px; border-radius: 999px; margin-bottom: 14px }
.slide h2 { font-size: clamp(22px, 3.2vw, 40px); font-weight: 800; text-shadow: 0 2px 20px rgba(0, 0, 0, .25) }
.slide p { margin-top: 12px; font-size: clamp(14px, 1.3vw, 17px); opacity: .92; max-width: 560px }
.slide .more { display: inline-flex; margin-top: 18px; font-weight: 800; font-size: 14px; background: #fff; color: #1B1340; border-radius: 10px; padding: 9px 16px }
.slider .nav { position: absolute; top: 50%; transform: translateY(-50%); z-index: 3; width: 42px; height: 42px; border-radius: 50%; border: 0; background: rgba(255, 255, 255, .18); color: #fff; cursor: pointer; font-size: 20px; display: grid; place-items: center }
.slider .nav:hover { background: rgba(255, 255, 255, .3) }
.slider .prev { left: 14px } .slider .next { right: 14px }
.slider .dots { position: absolute; bottom: 14px; left: 0; right: 0; display: flex; justify-content: center; gap: 7px; z-index: 3 }
.slider .dots button { width: 8px; height: 8px; border-radius: 99px; border: 0; background: rgba(255, 255, 255, .45); cursor: pointer; padding: 0; transition: width .3s }
.slider .dots button.on { width: 26px; background: #fff }
@media (max-width: 640px) { .slider { border-radius: 16px } .slider .nav { display: none } }

/* ---------- блоки главной ---------- */
.section { margin-top: 22px }
.statbar { display: flex; flex-wrap: wrap; gap: 8px 22px; align-items: center; font-size: 13px; color: var(--muted); padding: 10px 0 }
.statbar b { color: var(--text) }
.launch { display: grid; grid-template-columns: 1fr auto; gap: 18px; align-items: center; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px 20px; box-shadow: var(--shadow) }
.launch h3 { font-size: 18px }
.launch p { color: var(--muted); margin-top: 6px; font-size: 14px }
.progress { height: 10px; border-radius: 99px; background: var(--bg-soft); border: 1px solid var(--line); overflow: hidden; margin-top: 12px }
.progress span { display: block; height: 100%; background: var(--grad); border-radius: 99px; transition: width .6s }
@media (max-width: 720px) { .launch { grid-template-columns: 1fr } }
.weekbar { display: flex; flex-wrap: wrap; gap: 14px 26px; align-items: center; justify-content: space-between; border-radius: var(--radius); padding: 16px 20px; color: #fff; background: linear-gradient(100deg, #1B1340 0%, #3E4FC2 55%, #C8235A 100%); position: relative; overflow: hidden }
.weekbar .t { font-size: 13px; font-weight: 700; opacity: .85; text-transform: uppercase; letter-spacing: .06em }
.weekbar .clock { display: flex; gap: 8px; margin-top: 6px }
.weekbar .clock div { background: rgba(255, 255, 255, .14); border: 1px solid rgba(255, 255, 255, .22); border-radius: 10px; padding: 6px 10px; min-width: 62px; text-align: center }
.weekbar .clock b { display: block; font-family: var(--display); font-size: 22px; font-variant-numeric: tabular-nums; line-height: 1.1 }
.weekbar .clock small { font-size: 11px; opacity: .8 }
.weekbar .lead { font-size: 14px }
.weekbar .lead b { font-size: 16px }
.weekbar a { color: #fff; text-decoration: underline }
.cards3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px }
@media (max-width: 900px) { .cards3 { grid-template-columns: 1fr } }
.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px 18px }
.card h4 { font-family: var(--body); font-size: 15px; font-weight: 800; display: flex; align-items: center; gap: 8px; justify-content: space-between }
.mini-list { display: grid; gap: 2px; margin-top: 10px }
.mini-list a { display: grid; grid-template-columns: 22px 1fr auto; gap: 10px; align-items: center; padding: 7px 6px; border-radius: 8px; color: var(--text); text-decoration: none; font-size: 14px }
.mini-list a:hover { background: var(--bg-soft) }
.mini-list .i { color: var(--faint); font-weight: 700; font-size: 13px }
.mini-list .n { display: flex; gap: 8px; align-items: center; min-width: 0; font-weight: 700 }
.mini-list .n span:last-child { overflow: hidden; text-overflow: ellipsis; white-space: nowrap }

/* ---------- таблица рейтинга ---------- */
.toolbar { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; justify-content: space-between; margin: 22px 0 10px }
.tabs { display: flex; gap: 4px; flex-wrap: wrap }
.tabs button { border: 0; background: transparent; padding: 8px 12px; border-radius: 8px; font-weight: 700; cursor: pointer; color: var(--muted); font-size: 14px }
.tabs button.on { background: var(--accent-soft); color: var(--accent) }
.tabs button:hover:not(.on) { background: var(--bg-soft) }
.filters { display: flex; gap: 8px; flex-wrap: wrap }
.filters .input { min-height: 38px; width: auto }
.filters input.input { width: 200px }
.table-wrap { overflow-x: auto; border-top: 1px solid var(--line); -webkit-overflow-scrolling: touch }
table.rank { width: 100%; border-collapse: collapse; min-width: 980px; font-variant-numeric: tabular-nums }
table.rank th { position: sticky; top: 0; background: var(--bg); text-align: right; font-size: 12px; font-weight: 800; color: var(--text); padding: 12px 10px; border-bottom: 1px solid var(--line); white-space: nowrap; cursor: pointer; user-select: none }
table.rank th.l, table.rank td.l { text-align: left }
table.rank th .arr { color: var(--faint); font-size: 10px; margin-left: 3px }
table.rank td { padding: 12px 10px; border-bottom: 1px solid var(--line); text-align: right; white-space: nowrap; font-size: 14px; font-weight: 600 }
table.rank tbody tr { cursor: pointer; transition: background .2s }
table.rank tbody tr:hover { background: var(--bg-soft) }
table.rank td.rk { color: var(--muted); width: 44px; text-align: left }
table.rank td.club { min-width: 230px }
table.rank .sticky1 { position: sticky; left: 0; background: var(--bg); z-index: 1 }
table.rank .sticky2 { position: sticky; left: 44px; background: var(--bg); z-index: 1 }
table.rank tbody tr:hover .sticky1, table.rank tbody tr:hover .sticky2 { background: var(--bg-soft) }
.clubcell { display: flex; align-items: center; gap: 10px }
.clubcell .nm { font-weight: 800; color: var(--text) }
.clubcell .sub { font-size: 12px; color: var(--muted); font-weight: 600 }
.ava { width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; font-size: 11px; font-weight: 800; color: #fff; flex: none; text-shadow: 0 1px 2px rgba(0, 0, 0, .2) }
.ava.lg { width: 64px; height: 64px; font-size: 22px }
.ava.md { width: 44px; height: 44px; font-size: 15px }
.chg { font-weight: 700; white-space: nowrap }
.chg.up::before { content: "▲ "; font-size: 9px; vertical-align: 1px }
.chg.down::before { content: "▼ "; font-size: 9px; vertical-align: 1px }
.eibox { display: inline-flex; align-items: baseline; gap: 6px }
.eibox b { font-size: 15px }
.eibox small { font-size: 11px; font-weight: 800 }
.spark { width: 128px; height: 38px; display: block; margin-left: auto }
.flash-up { animation: fUp 1.2s ease-out } .flash-down { animation: fDown 1.2s ease-out }
@keyframes fUp { 0% { background: rgba(22, 199, 132, .28) } 100% { background: transparent } }
@keyframes fDown { 0% { background: rgba(234, 57, 67, .24) } 100% { background: transparent } }
.moved { animation: moved 1.6s ease-out }
@keyframes moved { 0% { background: var(--accent-soft) } 100% { background: transparent } }
.empty { padding: 40px 20px; text-align: center; color: var(--muted) }
.tag { display: inline-flex; align-items: center; gap: 4px; font-size: 11px; font-weight: 800; padding: 2px 7px; border-radius: 6px; background: var(--bg-soft); color: var(--muted); border: 1px solid var(--line) }
.tag.founder { background: rgba(242, 176, 30, .16); color: #A87400; border-color: rgba(242, 176, 30, .35) }
:root[data-theme="dark"] .tag.founder { color: var(--gold) }
.tag.new { background: rgba(200, 35, 90, .1); color: var(--pink); border-color: rgba(200, 35, 90, .25) }

/* ---------- страницы ---------- */
main { min-height: 60vh; padding-bottom: 60px }
.page-head { padding: 26px 0 8px }
.page-head h1 { font-size: clamp(26px, 3.4vw, 38px) }
.page-head p { color: var(--muted); margin-top: 8px; max-width: 760px }
.crumbs { font-size: 13px; color: var(--muted); margin-top: 18px }
.crumbs a { color: var(--muted) }
.grid2 { display: grid; grid-template-columns: minmax(0, 1fr) 360px; gap: 22px; align-items: start }
@media (max-width: 1000px) { .grid2 { grid-template-columns: 1fr } }
.stack { display: grid; gap: 18px }
.panel { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px }
.panel h3 { font-size: 17px; margin-bottom: 12px }
.panel h3 small { font-family: var(--body); font-size: 13px; font-weight: 600; color: var(--muted); margin-left: 6px }
.club-head { display: flex; gap: 16px; align-items: center; flex-wrap: wrap; margin-top: 14px }
.club-head h1 { font-size: clamp(24px, 3vw, 34px) }
.club-head .meta { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 8px; align-items: center }
.pricebig { font-family: var(--display); font-size: clamp(28px, 3.4vw, 40px); font-weight: 700; font-variant-numeric: tabular-nums }
.kv { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px }
.kv > div { background: var(--bg-soft); border: 1px solid var(--line); border-radius: 12px; padding: 12px 14px }
.kv span { display: block; font-size: 12px; color: var(--muted); font-weight: 700 }
.kv b { font-size: 18px; font-variant-numeric: tabular-nums }
@media (max-width: 700px) { .kv { grid-template-columns: repeat(2, minmax(0, 1fr)) } }
.seg { display: inline-flex; background: var(--bg-soft); border: 1px solid var(--line); border-radius: 10px; padding: 3px }
.seg button { border: 0; background: transparent; padding: 6px 12px; border-radius: 8px; font-weight: 700; font-size: 13px; cursor: pointer; color: var(--muted) }
.seg button.on { background: var(--card); color: var(--text); box-shadow: 0 1px 3px rgba(0, 0, 0, .1) }
.chart { width: 100%; height: auto; display: block }
.chart text { fill: var(--faint); font-size: 11px; font-family: var(--body) }
.bars { display: grid; gap: 12px }
.bar-row .top-line { display: flex; justify-content: space-between; font-size: 14px; font-weight: 700 }
.bar-row .top-line span { color: var(--muted); font-weight: 600 }
.bar { height: 8px; border-radius: 99px; background: var(--bg-soft); border: 1px solid var(--line); margin-top: 6px; overflow: hidden }
.bar i { display: block; height: 100%; background: var(--grad); border-radius: 99px }
.bar-row p { font-size: 12px; color: var(--muted); margin-top: 4px }
.ei-big { display: flex; align-items: center; gap: 16px; margin-bottom: 16px }
.ei-ring { width: 84px; height: 84px; flex: none }
.trade-box .row { display: flex; gap: 8px }
.trade-box .row > * { flex: 1 }
.qty { display: flex; align-items: center; border: 1px solid var(--line-strong); border-radius: 10px; overflow: hidden }
.qty button { width: 42px; height: 42px; border: 0; background: var(--bg-soft); cursor: pointer; font-size: 18px; font-weight: 800 }
.qty input { flex: 1; min-width: 0; border: 0; text-align: center; height: 42px; background: var(--card); font-weight: 800; font-variant-numeric: tabular-nums }
.qty input:focus { outline: none }
.cost { display: grid; gap: 4px; font-size: 13px; color: var(--muted); margin: 12px 0 }
.cost div { display: flex; justify-content: space-between }
.cost b { color: var(--text); font-variant-numeric: tabular-nums }
.note { font-size: 12px; color: var(--muted) }
.notice { display: flex; gap: 10px; align-items: flex-start; padding: 12px 14px; border-radius: 12px; background: var(--accent-soft); color: var(--text); font-size: 14px }
.notice.warn { background: rgba(242, 176, 30, .15) }
.notice.ok { background: rgba(22, 199, 132, .12) }
.notice.err { background: rgba(234, 57, 67, .1) }
.poll { border: 1px solid var(--line); border-radius: 12px; padding: 14px; display: grid; gap: 8px }
.poll .q { font-weight: 800 }
.poll .opt { position: relative; border: 1px solid var(--line-strong); border-radius: 10px; padding: 9px 12px; overflow: hidden; cursor: pointer; background: var(--card); text-align: left; display: flex; justify-content: space-between; gap: 10px; font-weight: 600 }
.poll .opt i { position: absolute; inset: 0 auto 0 0; background: var(--accent-soft); z-index: 0 }
.poll .opt span { position: relative; z-index: 1 }
.poll .opt.mine { border-color: var(--accent) }
.poll .opt[disabled] { cursor: default }
.list { display: grid; gap: 0 }
.list .li { display: flex; justify-content: space-between; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--line); font-size: 14px; align-items: center }
.list .li:last-child { border-bottom: 0 }
.owner-tabs { display: flex; gap: 6px; border-bottom: 1px solid var(--line); margin: 20px 0 18px; overflow-x: auto }
.owner-tabs button { border: 0; background: none; padding: 10px 14px; font-weight: 800; color: var(--muted); cursor: pointer; border-bottom: 2px solid transparent; white-space: nowrap }
.owner-tabs button.on { color: var(--accent); border-bottom-color: var(--accent) }
.funnel { display: grid; gap: 8px }
.funnel div { display: grid; grid-template-columns: 1fr auto; padding: 10px 14px; border-radius: 10px; color: #fff; font-weight: 700 }
.months { display: flex; gap: 6px; flex-wrap: wrap }
.months span { min-width: 54px; padding: 6px 8px; border-radius: 8px; text-align: center; font-size: 12px; font-weight: 800; border: 1px solid var(--line) }
.months span.ok { background: rgba(22, 199, 132, .14); color: #0E9E68; border-color: rgba(22, 199, 132, .3) }
.months span.no { background: rgba(234, 57, 67, .08); color: var(--down) }
.months span.cur { border-style: dashed }
.copy-row { display: flex; gap: 8px }
.copy-row .input { font-size: 13px }

/* ---------- новости ---------- */
.news-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; margin-top: 18px }
@media (max-width: 1000px) { .news-grid { grid-template-columns: repeat(2, minmax(0, 1fr)) } }
@media (max-width: 640px) { .news-grid { grid-template-columns: 1fr } }
.news-card { display: grid; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; color: var(--text); text-decoration: none; transition: transform .2s, box-shadow .2s }
.news-card:hover { transform: translateY(-2px); box-shadow: var(--shadow); text-decoration: none }
.news-card .art { height: 150px; position: relative; overflow: hidden }
.news-card .art img { width: 100%; height: 100%; object-fit: cover }
.news-card .body { padding: 16px 18px 18px; display: grid; gap: 8px }
.news-card h3 { font-size: 17px }
.news-card p { color: var(--muted); font-size: 14px }
.news-card time { font-size: 12px; color: var(--faint); font-weight: 700 }
.article { max-width: 760px }
.article .art { height: 260px; border-radius: 20px; overflow: hidden; position: relative; margin: 18px 0 24px }
.article h1 { font-size: clamp(26px, 3.4vw, 40px) }
.article .content { font-size: 17px; line-height: 1.7; display: grid; gap: 16px; margin-top: 18px }

/* ---------- правила, тексты ---------- */
.prose { max-width: 820px; min-width: 0; display: grid; grid-template-columns: minmax(0, 1fr); gap: 14px; font-size: 16px; line-height: 1.7 }
.prose h2 { font-size: 22px; margin-top: 22px; overflow-wrap: anywhere }
.prose section { display: grid; gap: 14px; min-width: 0 }
.prose h3 { font-size: 17px; margin-top: 8px }
.prose ul, .prose ol { margin: 0; padding-left: 22px; display: grid; gap: 6px }
.prose .formula { font-family: ui-monospace, Menlo, Consolas, monospace; background: var(--bg-soft); border: 1px solid var(--line); border-radius: 10px; padding: 12px 14px; font-size: 14px; overflow-x: auto; white-space: pre }
.rules-layout { display: grid; grid-template-columns: 240px minmax(0, 1fr); gap: 32px; align-items: start; margin-top: 16px }
.toc { position: sticky; top: 84px; display: grid; gap: 2px; font-size: 14px }
.toc a { color: var(--muted); padding: 6px 10px; border-radius: 8px; font-weight: 600 }
.toc a:hover { background: var(--bg-soft); text-decoration: none; color: var(--text) }
@media (max-width: 900px) { .rules-layout { grid-template-columns: minmax(0, 1fr) } .toc { position: static; grid-template-columns: repeat(2, minmax(0, 1fr)) } .toc a { overflow-wrap: anywhere } }
@media (max-width: 420px) { .toc { grid-template-columns: minmax(0, 1fr) } }

/* ---------- мини-игры ---------- */
.game-hero { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 32px; align-items: center; background: radial-gradient(circle at 70% 40%, #3E4FC2 0, #1B1340 60%); color: #fff; border-radius: 24px; padding: clamp(22px, 4vw, 48px); margin-top: 18px; overflow: hidden }
.game-hero h1 { font-size: clamp(28px, 4vw, 48px) }
.game-hero p { opacity: .9; margin-top: 12px; font-size: 16px }
@media (max-width: 860px) { .game-hero { grid-template-columns: 1fr } }

/* ---------- модальные окна, уведомления ---------- */
.modal-back { position: fixed; inset: 0; background: rgba(9, 13, 24, .55); z-index: 80; display: grid; place-items: center; padding: 16px }
.modal { width: min(560px, 100%); max-height: calc(100vh - 32px); overflow: auto; background: var(--card); border-radius: 20px; padding: 22px; box-shadow: 0 20px 60px rgba(0, 0, 0, .3); display: grid; gap: 14px }
.modal.wide { width: min(820px, 100%) }
.modal h3 { font-size: 20px }
.modal .actions { display: flex; gap: 10px; justify-content: flex-end; flex-wrap: wrap }
.toasts { position: fixed; bottom: 18px; left: 50%; transform: translateX(-50%); z-index: 90; display: grid; gap: 8px; width: min(440px, calc(100% - 32px)) }
.toast { background: var(--text); color: var(--bg); padding: 12px 16px; border-radius: 12px; font-weight: 700; box-shadow: var(--shadow); font-size: 14px }
.toast.err { background: var(--down); color: #fff }
.toast.ok { background: #0E9E68; color: #fff }

/* ---------- вход ---------- */
.auth-box { max-width: 460px; margin: 30px auto; display: grid; gap: 16px }
.auth-box .or { display: flex; align-items: center; gap: 12px; color: var(--faint); font-size: 13px; font-weight: 700 }
.auth-box .or::before, .auth-box .or::after { content: ""; flex: 1; height: 1px; background: var(--line) }
.tg-widget { min-height: 44px; display: flex; justify-content: center }

/* ---------- администрирование ---------- */
.admin-tabs { display: flex; gap: 6px; flex-wrap: wrap; margin: 16px 0 18px }
.admin-tabs button { border: 1px solid var(--line); background: var(--card); border-radius: 10px; padding: 8px 14px; font-weight: 800; cursor: pointer; color: var(--muted) }
.admin-tabs button.on { background: var(--text); color: var(--bg); border-color: var(--text) }
.admin-tabs button b { background: var(--pink); color: #fff; border-radius: 6px; padding: 0 6px; margin-left: 6px; font-size: 12px }
.stat-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px }
.stat-grid div { background: var(--bg-soft); border: 1px solid var(--line); border-radius: 12px; padding: 12px }
.stat-grid span { display: block; font-size: 12px; font-weight: 700; color: var(--muted) }
.stat-grid b { font-size: 22px; font-variant-numeric: tabular-nums }
table.plain { width: 100%; border-collapse: collapse; font-size: 14px }
table.plain th { text-align: left; font-size: 12px; color: var(--muted); padding: 8px; border-bottom: 1px solid var(--line); white-space: nowrap }
table.plain td { padding: 9px 8px; border-bottom: 1px solid var(--line); vertical-align: top }
.app-card { border: 1px solid var(--line); border-radius: 14px; padding: 16px; display: grid; gap: 8px }
.app-card .h { display: flex; justify-content: space-between; gap: 10px; flex-wrap: wrap; align-items: center }
.row-actions { display: flex; gap: 6px; flex-wrap: wrap }

/* ---------- подвал ---------- */
footer { border-top: 1px solid var(--line); padding: 34px 0 calc(34px + env(safe-area-inset-bottom, 0px)); color: var(--muted); font-size: 14px; background: var(--bg-soft) }
footer .cols { display: grid; grid-template-columns: 1.5fr 1fr 1fr 1fr; gap: 26px }
footer .c { display: grid; gap: 7px; align-content: start }
footer .c b { color: var(--text) }
footer a { color: var(--muted) }
footer .legal { margin-top: 24px; padding-top: 18px; border-top: 1px solid var(--line); font-size: 12px; display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap }
@media (max-width: 860px) { footer .cols { grid-template-columns: 1fr 1fr } }
@media (max-width: 520px) { footer .cols { grid-template-columns: 1fr } }

/* защита от горизонтальной прокрутки на телефонах */
.grid2 > *, .stack > *, .form-grid > * { min-width: 0 }
.panel { min-width: 0; overflow-x: auto }
table.plain td.note { overflow-wrap: anywhere; min-width: 140px }

/* =====================================================================
   «Парад планет»
   ===================================================================== */
.pp-cards { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; margin-top: 18px }
@media (max-width: 960px) { .pp-cards { grid-template-columns: minmax(0, 1fr) } }
.pp-cards .panel { display: grid; gap: 12px; align-content: start }
.pp-cards h3 { font-size: 18px }
.pp-pills { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 16px }
.pp-pills span { background: rgba(255, 255, 255, .14); border-radius: 999px; padding: 5px 12px; font-size: 13px; font-weight: 700 }
.pp-matches { display: grid; gap: 8px }
.pp-match { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px 14px; border: 1px solid var(--line); border-radius: 12px; background: var(--bg-soft); flex-wrap: wrap }
.pp-rules { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; margin-top: 12px }
@media (max-width: 760px) { .pp-rules { grid-template-columns: minmax(0, 1fr) } }
.pp-rules > div { background: var(--bg-soft); border: 1px solid var(--line); border-radius: 12px; padding: 14px }
.pp-rules b { display: block; margin-bottom: 4px }
.pp-rules p { color: var(--muted); font-size: 14px }

.pp-layout { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 20px; align-items: start; margin-top: 14px }
@media (max-width: 1080px) { .pp-layout { grid-template-columns: minmax(0, 1fr) } }
.pp-board { --cell: calc(100% / 8); position: relative; display: grid; grid-template-columns: repeat(8, minmax(0, 1fr)); grid-template-rows: repeat(8, minmax(0, 1fr)); aspect-ratio: 1; width: 100%; max-width: min(760px, max(320px, calc(100vh - 150px))); margin: 0 auto; gap: 3px; padding: 3px; border-radius: 18px; background: radial-gradient(circle at 50% 50%, #2A2370 0, #120E33 72%); box-shadow: var(--shadow) }
.pp-cell { position: relative; min-width: 0; min-height: 0; border-radius: 8px; background: var(--card); color: var(--text); display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; padding: 3px; overflow: hidden; cursor: pointer; border: 2px solid transparent; transition: border-color .2s, box-shadow .2s; font-size: 11px; line-height: 1.15; text-align: center }
.pp-cell:hover { box-shadow: 0 0 0 2px var(--accent) inset }
.pp-cell .band { position: absolute; left: 0; right: 0; top: 0; height: 6px; background: var(--g) }
.pp-cell .ava { width: 26px; height: 26px; font-size: 10px; margin-top: 4px; flex: none }
.pp-cell .nm { font-weight: 700; font-size: 10px; max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--muted) }
.pp-cell .pr { font-weight: 800; font-size: 11px }
.pp-cell .ic { font-size: 22px; line-height: 1 }
.pp-cell .lb { font-weight: 800; font-size: 10px; text-transform: uppercase; letter-spacing: .02em; color: var(--muted) }
.pp-cell.corner { background: var(--bg-soft) }
.pp-cell.planet { background: var(--g); border-color: rgba(255, 255, 255, .25) }
.pp-cell.planet .ava { box-shadow: 0 0 0 2px #fff }
.pp-cell.planet .nm { color: #0D1421 }
.pp-cell.planet .pr { color: #fff; text-shadow: 0 1px 2px rgba(0, 0, 0, .45) }
.pp-cell .flag { position: absolute; left: 4px; top: 4px; width: 11px; height: 11px; border-radius: 3px; background: var(--o); box-shadow: 0 0 0 2px #fff, 0 1px 3px rgba(0, 0, 0, .4) }
.pp-cell .lb-s { display: none; font-weight: 800; font-size: 8px; text-transform: uppercase; color: var(--muted) }
.pp-cell .sats { position: absolute; right: 4px; top: 4px; display: flex; gap: 3px }
.pp-cell .sats i { width: 8px; height: 8px; border-radius: 50%; background: var(--o); box-shadow: 0 0 0 2px #fff }
.pp-cell.pending { box-shadow: 0 0 0 3px #fff inset, 0 0 14px 2px rgba(255, 255, 255, .7); animation: pp-glow 1.2s infinite }
.pp-cell.can-up { outline: 3px dashed #fff; outline-offset: -5px }
@keyframes pp-glow { 50% { box-shadow: 0 0 0 3px #fff inset, 0 0 4px 0 rgba(255, 255, 255, .3) } }
.pp-tokens { position: absolute; right: 2px; bottom: 2px; display: flex; flex-direction: row-reverse; pointer-events: none }
.pp-pawn { width: 17px; height: 21px; flex: none; filter: drop-shadow(0 1px 2px rgba(0, 0, 0, .55)); animation: pp-pop .25s }
.pp-tokens .pp-pawn + .pp-pawn { margin-right: -7px }
.pp-pawn.cur { width: 20px; height: 25px; animation: pp-pulse 1.2s infinite; position: relative; z-index: 1 }
.pp-turnbar { display: flex; align-items: center; justify-content: center; gap: 12px; max-width: min(760px, max(320px, calc(100vh - 150px))); margin: 0 auto 10px; padding: 10px 16px; border-radius: 14px; background: var(--card); border: 1px solid var(--line); box-shadow: var(--shadow); font-family: var(--display); font-size: clamp(20px, 3vw, 30px); font-weight: 800; line-height: 1.1 }
.pp-turnbar .pp-pawn.big { width: 30px; height: 38px; animation: none }
.pp-turnbar.pop { animation: pp-banner .45s }
@keyframes pp-banner { from { transform: scale(.94); opacity: .3 } to { transform: scale(1); opacity: 1 } }
.pp-legend { max-width: min(760px, max(320px, calc(100vh - 150px))); margin: 12px auto 0; background: var(--card); border: 1px solid var(--line); border-radius: 14px; padding: 12px 16px }
.pp-legend table { width: 100%; border-collapse: collapse; font-size: 14px }
.pp-legend th { text-align: left; font-size: 12px; color: var(--muted); font-weight: 700; padding: 0 0 6px }
.pp-legend td { padding: 5px 0; border-top: 1px solid var(--line); font-weight: 700; font-variant-numeric: tabular-nums }
.pp-legend .note { margin-top: 8px }
.pp-sw { display: inline-block; width: 46px; height: 16px; border-radius: 5px; vertical-align: middle }
.pp-sw.sm { width: 22px; height: 12px; border-radius: 4px; vertical-align: -1px }
@keyframes pp-pop { from { transform: scale(.3) } to { transform: scale(1) } }
@keyframes pp-pulse { 50% { transform: scale(1.18) } }
.pp-center { grid-area: 2 / 2 / 8 / 8; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 10px; color: #fff; text-align: center; padding: 10px; min-width: 0; min-height: 0; overflow: hidden }
.pp-center .ttl { font-family: var(--display); font-size: clamp(14px, 2.4vw, 22px); opacity: .9 }
.pp-center .st { font-size: clamp(12px, 1.8vw, 15px); font-weight: 700 }
.pp-center .st small { display: block; font-weight: 600; opacity: .75 }
.pp-dice { display: flex; gap: 10px }
.pp-die { width: clamp(34px, 6vw, 52px); aspect-ratio: 1; border-radius: 10px; background: #fff; display: grid; grid-template: repeat(3, 1fr) / repeat(3, 1fr); padding: 15%; box-shadow: 0 4px 12px rgba(0, 0, 0, .35) }
.pp-die i { width: 70%; aspect-ratio: 1; border-radius: 50%; background: #1B1340; place-self: center; visibility: hidden }
.pp-die i.on { visibility: visible }
.pp-die.roll { animation: pp-roll .45s }
@keyframes pp-roll { 30% { transform: rotate(-20deg) scale(.9) } 70% { transform: rotate(14deg) scale(1.05) } }
.pp-acts { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; max-width: 100% }
.pp-acts .btn { min-height: 38px }
.pp-ups { display: flex; flex-wrap: wrap; gap: 6px; justify-content: center }
.pp-ups .btn { background: rgba(255, 255, 255, .14); color: #fff; min-height: 30px; font-size: 12px }
.pp-timer { font-size: 13px; font-weight: 700; color: var(--gold) }
.pp-last { font-size: 12px; opacity: .8; max-width: 100%; display: grid; gap: 2px }
.pp-last div { overflow: hidden; text-overflow: ellipsis; white-space: nowrap }
.pp-side { display: grid; gap: 16px }
.pp-players { display: grid; gap: 8px }
.pp-pl { display: grid; grid-template-columns: 18px minmax(0, 1fr) auto; gap: 10px; align-items: center; padding: 10px 12px; border-radius: 12px; border: 1px solid var(--line); background: var(--bg-soft) }
.pp-pl.cur { border-color: var(--accent); box-shadow: 0 0 0 1px var(--accent) inset }
.pp-pl.out { opacity: .5 }
.pp-pl .dot { width: 16px; height: 16px; border-radius: 50%; border: 2px solid #fff; box-shadow: 0 0 0 1px var(--line-strong) }
.pp-pl .n { font-weight: 800; overflow: hidden; text-overflow: ellipsis; white-space: nowrap }
.pp-pl .n small { font-weight: 600; color: var(--muted); margin-left: 4px }
.pp-pl .c { text-align: right; font-weight: 800; font-variant-numeric: tabular-nums }
.pp-pl .c small { display: block; color: var(--muted); font-weight: 600; font-size: 12px }
.pp-log { max-height: 320px; overflow-y: auto; display: grid; gap: 6px; font-size: 13px }
.pp-log div { padding: 6px 10px; border-radius: 8px; background: var(--bg-soft); border-left: 3px solid var(--c, var(--line-strong)) }
.pp-log div.r { background: transparent; border: 0; color: var(--muted); font-weight: 800; font-size: 12px; text-transform: uppercase; padding-top: 10px }
.pp-res { display: grid; gap: 8px; margin: 10px 0 }
.pp-res div { display: grid; grid-template-columns: 32px minmax(0, 1fr) auto; gap: 10px; align-items: center; padding: 10px 12px; border-radius: 10px; background: var(--bg-soft) }
.pp-res div.win { background: color-mix(in srgb, var(--gold) 22%, var(--card)) }
.pp-lobby-seats { display: grid; gap: 8px; margin: 12px 0 }
.pp-rent { width: 100%; border-collapse: collapse; margin-top: 10px; font-size: 14px }
.pp-rent td { padding: 6px 0; border-bottom: 1px solid var(--line) }
.pp-rent td:last-child { text-align: right; font-weight: 800 }
.pp-rent tr.on td { color: var(--accent) }
@media (max-width: 640px) {
  .pp-board { gap: 2px; padding: 2px; border-radius: 12px }
  .pp-cell { border-radius: 5px; padding: 1px; border-width: 1.5px }
  .pp-cell .nm, .pp-cell .lb { display: none }
  .pp-cell .lb-s { display: block }
  .pp-cell .ava { width: 18px; height: 18px; font-size: 8px; margin-top: 0 }
  .pp-cell.planet .ava { box-shadow: 0 0 0 1.5px #fff }
  .pp-cell .flag { left: 2px; top: 2px; width: 7px; height: 7px; border-radius: 2px; box-shadow: 0 0 0 1.5px #fff }
  .pp-cell .pr { font-size: 9px }
  .pp-cell .ic { font-size: 16px }
  .pp-cell .sats { top: 2px; right: 2px; gap: 2px }
  .pp-cell .sats i { width: 5px; height: 5px; box-shadow: 0 0 0 1.5px #fff }
  .pp-turnbar { font-size: 18px; padding: 8px 12px }
  .pp-turnbar .pp-pawn.big { width: 22px; height: 28px }
  .pp-tokens { right: 1px; bottom: 1px }
  .pp-pawn { width: 13px; height: 16px }
  .pp-pawn.cur { width: 15px; height: 19px }
  .pp-tokens .pp-pawn + .pp-pawn { margin-right: -5px }
  .pp-center { gap: 6px; padding: 4px }
  .pp-last { display: none }
  .pp-acts .btn { min-height: 34px; padding: 0 10px; font-size: 12px }
  .pp-ups .btn { min-height: 26px; padding: 0 8px; font-size: 11px }
}
