/* ========================================================
   New STALKER Chill — стили сайта
   Тёмная тема, «зона»: тёплая радиационная зелень + янтарь.
   ======================================================== */

:root {
  --bg: #0a0c08;
  --bg-2: #0f120c;
  --panel: #131710;
  --panel-2: #171c13;
  --line: rgba(170, 200, 96, 0.14);
  --line-strong: rgba(170, 200, 96, 0.28);
  --txt: #dde2d2;
  --muted: #8b947c;
  --acc: #b9e34a;
  --acc-dim: #7d9a34;
  --amber: #ffb347;
  --danger: #e0653f;
  --radius: 14px;
  --max: 1120px;
  --font: "Bahnschrift", "Segoe UI", system-ui, -apple-system, sans-serif;
  --mono: ui-monospace, "Consolas", "SF Mono", "Courier New", monospace;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; scroll-padding-top: 84px; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--txt);
  font-family: var(--font);
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

/* Фон: картинка FON_0212, чуть размыта, с затемнением */
body::before {
  content: "";
  position: fixed;
  inset: -24px;
  z-index: -2;
  background: url('/bg.jpg') no-repeat center center;
  background-size: cover;
  filter: blur(5px);
  transform: scale(1.06);
  pointer-events: none;
}
body::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  background: rgba(10, 12, 8, 0.55);
  pointer-events: none;
}

.scanlines {
  position: fixed;
  inset: 0;
  z-index: 60;
  pointer-events: none;
  background: repeating-linear-gradient(to bottom, rgba(255,255,255,0.025) 0 1px, transparent 1px 3px);
  opacity: 0.55;
  mix-blend-mode: overlay;
}

a { color: var(--acc); text-decoration: none; }
a:hover { text-decoration: underline; }
code { font-family: var(--mono); font-size: 0.92em; background: rgba(185,227,74,0.08); padding: 2px 6px; border-radius: 6px; }
p { margin: 0 0 1em; }
.muted { color: var(--muted); }

/* ---------- верхняя панель ---------- */
.top {
  position: sticky;
  top: 0;
  z-index: 50;
  display: flex;
  align-items: center;
  gap: 24px;
  padding: 12px clamp(16px, 4vw, 40px);
  background: rgba(10, 12, 8, 0.82);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line);
}

.brand { display: flex; align-items: center; gap: 12px; color: var(--txt); text-decoration: none; }
.brand:hover { text-decoration: none; }
.brand-mark { width: 32px; height: 32px; color: var(--acc); flex: none; filter: drop-shadow(0 0 10px rgba(185,227,74,0.35)); }
.brand-text {
  display: flex; flex-direction: column; line-height: 1.05;
  font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; font-size: 15px;
  white-space: nowrap;
}
.brand-text small { font-size: 10px; letter-spacing: 0.35em; color: var(--muted); font-weight: 500; }

.nav { display: flex; gap: 22px; margin-left: 12px; overflow-x: auto; scrollbar-width: none; }

/* мобильное меню: видно только на узких экранах */
.nav-mobile { display: none; position: relative; }
.nav-mobile > summary {
  list-style: none; cursor: pointer; font-family: var(--mono); font-size: 12px;
  letter-spacing: .08em; text-transform: uppercase; color: var(--muted);
  border: 1px solid var(--line-strong); border-radius: 9px; padding: 8px 11px;
}
.nav-mobile > summary::-webkit-details-marker { display: none; }
.nav-mobile[open] > summary { color: var(--acc); border-color: var(--acc-dim); }
.nav-mobile-panel {
  position: absolute; top: calc(100% + 8px); left: 0; z-index: 70;
  display: flex; flex-direction: column; gap: 2px; min-width: 190px;
  padding: 8px; border: 1px solid var(--line-strong); border-radius: 12px;
  background: #0f120c; box-shadow: 0 20px 40px -18px #000;
}
.nav-mobile-panel a { padding: 9px 11px; border-radius: 8px; color: var(--muted); text-decoration: none; font-size: 14px; }
.nav-mobile-panel a:hover { color: var(--txt); background: rgba(185,227,74,.07); }
.nav::-webkit-scrollbar { display: none; }
.nav a {
  color: var(--muted); text-decoration: none; white-space: nowrap;
  font-size: 14px; letter-spacing: 0.04em; text-transform: uppercase;
  padding: 6px 0; border-bottom: 1px solid transparent; transition: color .15s, border-color .15s;
}
.nav a:hover { color: var(--txt); border-color: var(--acc); text-decoration: none; }

.top-actions { margin-left: auto; display: flex; align-items: center; gap: 14px; }

.status { display: inline-flex; align-items: center; gap: 8px; font-size: 13px; color: var(--muted); font-family: var(--mono); white-space: nowrap; }
.status i { width: 8px; height: 8px; border-radius: 50%; background: var(--muted); display: block; }
.status[data-state="online"] i { background: var(--acc); box-shadow: 0 0 0 0 rgba(185,227,74,.6); animation: pulse 2.2s infinite; }
.status[data-state="offline"] i { background: var(--danger); }
@keyframes pulse {
  0% { box-shadow: 0 0 0 0 rgba(185,227,74,.55); }
  70% { box-shadow: 0 0 0 9px rgba(185,227,74,0); }
  100% { box-shadow: 0 0 0 0 rgba(185,227,74,0); }
}

/* ---------- кнопки ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 12px 22px; border-radius: 10px;
  border: 1px solid var(--line-strong);
  background: rgba(255,255,255,0.02);
  color: var(--txt); font: inherit; font-weight: 600; font-size: 15px;
  letter-spacing: 0.02em; cursor: pointer; text-decoration: none;
  transition: transform .12s, background .15s, border-color .15s, box-shadow .15s;
}
.btn:hover { text-decoration: none; border-color: var(--acc-dim); background: rgba(185,227,74,0.07); }
.btn:active { transform: translateY(1px); }
.btn-primary {
  background: linear-gradient(180deg, #b9e34a, #7d9a34);
  border-color: #b9e34a; color: #10160a;
  box-shadow: 0 8px 30px -12px rgba(185,227,74,0.5);
  padding: 10px 24px; border-radius: 10px; font-size: 14px;
}
.btn-primary:hover { background: linear-gradient(180deg, #d0f56a, #a9d43a); }
.btn-primary:focus-visible { outline: 2px solid var(--acc); outline-offset: 3px; }
.btn-ghost { padding: 8px 16px; font-size: 14px; }
.btn-small { padding: 8px 18px; font-size: 13px; border-radius: 8px; transition: opacity .15s; }
.btn-small:hover { opacity: 0.9; }
.btn.is-disabled { opacity: 0.45; cursor: not-allowed; }
.btn:focus-visible, .chip:focus-visible, details:focus-visible { outline: 2px solid var(--acc); outline-offset: 3px; }

/* ---------- hero ---------- */
.hero { position: relative; padding: clamp(56px, 10vw, 120px) clamp(16px, 4vw, 40px) clamp(40px, 6vw, 72px); overflow: hidden; }
.hero-glow {
  position: absolute; inset: -30% -10% auto; height: 640px;
  background: radial-gradient(closest-side, rgba(185,227,74,0.16), transparent 70%);
  filter: blur(20px); pointer-events: none;
}
.hero-inner { position: relative; max-width: var(--max); margin: 0 auto; }
.kicker {
  font-family: var(--mono); font-size: 13px; letter-spacing: 0.28em; text-transform: uppercase;
  color: var(--amber); margin: 0 0 18px;
}
.hero h1 {
  margin: 0 0 18px;
  font-size: clamp(2.4rem, 7vw, 5rem);
  line-height: 0.98; letter-spacing: -0.02em; text-transform: uppercase;
  text-shadow: 0 0 60px rgba(185,227,74,0.18);
}
.lead { max-width: 62ch; font-size: clamp(1rem, 1.6vw, 1.2rem); color: #b9c1ad; margin: 0 0 32px; }
.cta { display: flex; flex-wrap: wrap; gap: 14px; margin-bottom: 42px; }

.chips { display: flex; flex-wrap: wrap; gap: 10px; }
.chip {
  display: flex; flex-direction: column; gap: 2px;
  min-width: 132px; padding: 12px 16px;
  border: 1px solid var(--line); border-radius: 12px;
  background: linear-gradient(180deg, rgba(255,255,255,0.035), rgba(255,255,255,0.01));
  font: inherit; color: var(--txt); text-align: left;
}
.chip-k { font-family: var(--mono); font-size: 10px; letter-spacing: 0.2em; text-transform: uppercase; color: var(--muted); }
.chip-v { font-family: var(--mono); font-size: 15px; }
button.chip { cursor: pointer; transition: border-color .15s, background .15s; }
button.chip:hover:not(:disabled) { border-color: var(--acc-dim); background: rgba(185,227,74,0.06); }
button.chip:disabled { cursor: default; opacity: .7; }
.chip-copy { position: relative; padding-right: 84px; }
.chip-hint {
  position: absolute; right: 14px; top: 50%; transform: translateY(-50%);
  font-family: var(--mono); font-size: 10px; color: var(--acc); opacity: .75;
  letter-spacing: .1em; text-transform: uppercase;
}
.chip-copy.copied { border-color: var(--acc); }
.chip-copy.copied .chip-hint { color: var(--acc); }

/* ---------- секции ---------- */
main { display: block; }
.section { max-width: var(--max); margin: 0 auto; padding: clamp(32px, 5vw, 52px) clamp(16px, 4vw, 40px); border-top: 1px solid var(--line); }
.section-head { display: flex; align-items: center; gap: 16px; margin-bottom: 32px; }
.section-num { font-family: var(--mono); font-size: 13px; color: var(--acc); letter-spacing: .15em; }
.section-head h2 {
  margin: 0; font-size: clamp(1.4rem, 3vw, 2rem); text-transform: uppercase;
  letter-spacing: 0.02em; font-weight: 700;
}
.section-line { flex: 1; height: 1px; background: linear-gradient(90deg, var(--line-strong), transparent); }

.prose { max-width: 62ch; color: #c3cbb6; }
.empty { color: var(--muted); border: 1px dashed var(--line-strong); border-radius: var(--radius); padding: 24px; }

/* ---------- о сервере ---------- */
.about-grid { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr); gap: 36px; align-items: start; }
.cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); gap: 14px; }
.card {
  padding: 20px; border: 1px solid var(--line); border-radius: var(--radius);
  background: linear-gradient(180deg, rgba(255,255,255,0.03), rgba(255,255,255,0));
  transition: border-color .18s, transform .18s;
}
.card:hover { border-color: var(--line-strong); transform: translateY(-2px); }
.card h3 { margin: 0 0 8px; font-size: 16px; letter-spacing: 0.03em; text-transform: uppercase; color: var(--acc); }
.card p { margin: 0; font-size: 14.5px; color: var(--muted); }

/* ---------- подключение ---------- */
.connect-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.2fr); gap: 24px; align-items: start; }
.panel { padding: 22px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--panel); }
.panel h3 { margin: 0 0 14px; font-size: 14px; letter-spacing: .16em; text-transform: uppercase; color: var(--muted); }
.addr { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; margin-bottom: 12px; }
.addr code { font-size: 15px; padding: 10px 14px; background: rgba(185,227,74,0.07); border: 1px solid var(--line-strong); border-radius: 9px; }

.steps { list-style: none; margin: 0; padding: 0; display: grid; gap: 14px; }
.steps li { display: flex; gap: 14px; align-items: flex-start; }
.steps li > span {
  flex: none; width: 30px; height: 30px; border-radius: 50%;
  display: grid; place-items: center; font-family: var(--mono); font-size: 13px;
  border: 1px solid var(--line-strong); color: var(--acc); background: rgba(185,227,74,0.06);
}
.steps b { display: block; font-size: 15px; margin-bottom: 2px; }
.steps p { margin: 0; font-size: 14.5px; color: var(--muted); }

/* ---------- моды ---------- */
.mods { display: grid; gap: 8px; }
.mod {
  display: grid; grid-template-columns: 44px minmax(0, 1.2fr) minmax(0, 1.8fr) auto;
  gap: 14px; align-items: center;
  padding: 14px 16px; border: 1px solid var(--line); border-radius: 11px;
  background: rgba(255,255,255,0.015); color: var(--txt); text-decoration: none;
  transition: border-color .15s, background .15s;
}
.mod:hover { text-decoration: none; border-color: var(--line-strong); background: rgba(185,227,74,0.04); }
.mod-i { font-family: var(--mono); font-size: 12px; color: var(--acc-dim); }
.mod-name { font-weight: 600; }
.mod-note { font-size: 14px; color: var(--muted); }
.mod-tag {
  font-family: var(--mono); font-size: 10px; letter-spacing: .14em; text-transform: uppercase;
  color: var(--muted); border: 1px solid var(--line); border-radius: 999px; padding: 3px 10px;
}
.mods-foot { margin-top: 16px; font-size: 14px; color: var(--muted); }
.mods-rest { margin-top: 8px; }
.mods-rest summary { display: inline-flex; list-style: none; cursor: pointer; }
.mods-rest summary::-webkit-details-marker { display: none; }
.mods-rest[open] summary { margin-bottom: 10px; }

/* ---------- правила ---------- */
.rules { counter-reset: r; list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.rules li {
  counter-increment: r; position: relative; padding: 16px 18px 16px 58px;
  border: 1px solid var(--line); border-radius: 11px; background: rgba(255,255,255,0.015);
}
.rules li::before {
  content: counter(r, decimal-leading-zero); position: absolute; left: 18px; top: 16px;
  font-family: var(--mono); font-size: 13px; color: var(--acc);
}
.rules b { display: block; margin-bottom: 3px; }
.rules p { margin: 0; font-size: 14.5px; color: var(--muted); }

/* ---------- новости ---------- */
.news-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 16px; }
.news-grid:has(> .news:only-child) .news { grid-column: 1 / -1; }
.news { padding: 20px; border: 1px solid var(--line); border-radius: var(--radius); background: linear-gradient(180deg, rgba(255,255,255,0.03), transparent); }
.news time { font-family: var(--mono); font-size: 11px; letter-spacing: .16em; color: var(--amber); text-transform: uppercase; }
.news h3 { margin: 8px 0 8px; font-size: 17px; }
.news p { margin: 0; font-size: 14.5px; color: var(--muted); }

/* ---------- faq ---------- */
.faq { display: grid; gap: 10px; max-width: 900px; }
.faq details { border: 1px solid var(--line); border-radius: 11px; background: rgba(255,255,255,0.015); }
.faq details[open] { border-color: var(--line-strong); }
.faq summary {
  cursor: pointer; padding: 16px 18px; font-weight: 600; list-style: none;
  display: flex; justify-content: space-between; gap: 14px; align-items: center;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; font-family: var(--mono); color: var(--acc); font-size: 18px; }
.faq details[open] summary::after { content: "−"; }
.faq-a { padding: 0 18px 16px; }
.faq-a p { margin: 0; color: var(--muted); font-size: 15px; }

/* ---------- подвал ---------- */
.footer { border-top: 1px solid var(--line); margin-top: 24px; padding: 40px clamp(16px, 4vw, 40px); }
.footer-grid { max-width: var(--max); margin: 0 auto; display: flex; flex-wrap: wrap; gap: 32px; justify-content: space-between; }
.footer-brand { margin: 0 0 4px; font-weight: 700; text-transform: uppercase; letter-spacing: .14em; }
.footer-contacts { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.footer-contacts li { display: flex; gap: 10px; font-size: 14px; }
.footer-contacts span { color: var(--muted); min-width: 110px; }
.fine { max-width: var(--max); margin: 28px auto 0; font-size: 12px; color: #5f6755; line-height: 1.5; }

/* ---------- адаптив ---------- */
@media (max-width: 1120px) {
  .top { gap: 12px; padding: 10px 16px; }
  .brand { gap: 9px; }
  .brand-mark { width: 28px; height: 28px; }
  .brand-text { font-size: 13px; }
  .brand-text small { font-size: 9px; }
  .nav { gap: 10px; margin-left: 0; }
  .nav a { font-size: 12px; }
  .top-actions { gap: 8px; }
  .top-actions .status { display: none; }
  .top-actions .btn-primary { padding: 9px 13px; font-size: 13px; }
}
@media (max-width: 900px) {
  .nav { display: none; }
  .nav-mobile { display: block; }
  .about-grid, .connect-grid { grid-template-columns: 1fr; }
  .mod { grid-template-columns: 34px minmax(0, 1fr); row-gap: 4px; }
  .mod-note { grid-column: 2; }
  .mod-tag { display: none; }
  .top-actions .status { display: none; }
}
@media (max-width: 560px) {
  body { font-size: 16px; }
  .top-actions { gap: 6px; }
  .top-actions .btn { padding: 8px 10px; font-size: 12.5px; }
  .chip { flex: 1 1 45%; min-width: 0; }
  .chip-copy { padding-right: 16px; }
  .chip-hint { display: none; }
  .cta .btn { flex: 1 1 100%; }
  .footer-contacts li { flex-direction: column; gap: 0; }
}
@media (max-width: 480px) {
  .top { gap: 7px; padding: 8px 10px; }
  .brand-text { font-size: 11px; max-width: 104px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .brand-text small { display: none; }
  .brand { gap: 6px; min-width: 0; }
  .top-actions { gap: 4px; }
  .top-actions .btn-ghost { padding: 7px 8px; font-size: 11.5px; }
  .top-actions .btn-primary { padding: 7px 9px; font-size: 11.5px; }
  .nav-mobile > summary { padding: 7px 8px; font-size: 11px; }
  .nav-mobile-panel { left: auto; right: 0; }
}

/* ========================================================
   Голосование
   ======================================================== */
.vote-grid { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); gap: 18px; align-items: start; }
.vote-panel { padding: 24px; }
.field-label { display: block; font-family: var(--mono); font-size: 11px; letter-spacing: .18em; text-transform: uppercase; color: var(--muted); margin-bottom: 10px; }
.field-row { display: flex; gap: 10px; flex-wrap: wrap; }
.input {
  flex: 1 1 220px; min-width: 0;
  padding: 13px 16px; border-radius: 12px;
  border: 1px solid var(--line-strong); background: rgba(0,0,0,.35);
  color: var(--txt); font: inherit; font-size: 16px;
  transition: border-color .15s, box-shadow .15s;
  outline: none;
}
.input::placeholder { color: #646c58; opacity: 0.8; }
.input:hover { border-color: var(--muted); }
.input:focus { border-color: var(--acc); box-shadow: 0 0 0 3px rgba(185,227,74,.12); }
.hint { margin: 12px 0 0; font-size: 13.5px; color: var(--muted); }
.small { font-size: 13px; }

.vote-result { margin-top: 18px; padding: 18px; border-radius: 12px; border: 1px solid var(--line-strong); background: rgba(185,227,74,.05); }
.vote-result.is-error { border-color: rgba(224,101,63,.5); background: rgba(224,101,63,.08); color: #f0b2a0; }
.vote-result-title { margin: 0 0 12px; font-size: 14.5px; color: var(--txt); }
.code-row { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.code-big {
  font-family: var(--mono); font-size: 26px; letter-spacing: .12em;
  padding: 10px 18px; border-radius: 10px;
  background: rgba(0,0,0,.35); border: 1px dashed var(--acc-dim); color: var(--acc);
}
.reward-list { list-style: none; margin: 0 0 12px; padding: 0; display: grid; gap: 10px; }
.reward-list li { position: relative; padding-left: 24px; font-size: 15px; }
.reward-list li::before { content: "◆"; position: absolute; left: 0; color: var(--acc); font-size: 11px; top: 5px; }

.vote-how { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 16px; margin-top: 26px; }
.vote-how-item { display: flex; gap: 14px; align-items: flex-start; padding: 18px; border: 1px solid var(--line); border-radius: var(--radius); background: rgba(255,255,255,.015); }
.vote-how-item > span {
  flex: none; width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center;
  font-family: var(--mono); font-size: 13px; border: 1px solid var(--line-strong); color: var(--acc);
  background: rgba(185,227,74,.06);
}
.vote-how-item b { display: block; margin-bottom: 2px; font-size: 15px; }
.vote-how-item p { margin: 0; font-size: 14px; color: var(--muted); }
.vote-stats { margin-top: 22px; font-size: 14px; color: var(--muted); }
.vote-stats b { color: var(--txt); }

/* ---------- админка ---------- */
.stat-row { display: flex; flex-wrap: wrap; gap: 14px; margin-bottom: 28px; }
.stat { min-width: 150px; padding: 16px 20px; border: 1px solid var(--line); border-radius: 12px; background: rgba(255,255,255,.02); }
.stat b { display: block; font-size: 28px; line-height: 1.1; color: var(--acc); }
.stat span { font-size: 13px; color: var(--muted); }
.admin-h { margin: 26px 0 12px; font-size: 15px; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }
.table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: 12px; }
.admin-table { width: 100%; border-collapse: collapse; font-size: 14.5px; }
.admin-table th, .admin-table td { padding: 12px 16px; text-align: left; border-bottom: 1px solid var(--line); white-space: nowrap; }
.admin-table th { font-family: var(--mono); font-size: 11px; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); font-weight: 500; }
.admin-table tbody tr:last-child td { border-bottom: none; }
.admin-table tbody tr:hover { background: rgba(185,227,74,.04); }
.ok-bar { margin: 0 0 20px; padding: 12px 16px; border-radius: 10px; border: 1px solid rgba(185,227,74,.4); background: rgba(185,227,74,.07); font-size: 14.5px; }

/* ---------- магазин: карточки ---------- */
.shop-card { display: flex; flex-direction: column; }
.shop-card .shop-stock { font-size: 12.5px; color: var(--amber); }
.shop-card .shop-price { margin-top: auto; font-size: 15px; }
.shop-card form { margin: 0; }
.shop-card .btn { width: 100%; }

/* ---------- счётчик голосов ---------- */
.leaderboard { margin-top: 34px; max-width: 760px; }
.leader-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.leader-list li {
  display: grid; grid-template-columns: 44px minmax(0, 1fr) auto; align-items: center; gap: 12px;
  padding: 11px 16px; border: 1px solid var(--line); border-radius: 10px;
  background: rgba(255,255,255,0.015);
}
.lead-place { font-family: var(--mono); font-size: 12px; color: var(--acc-dim); }
.lead-name { font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.lead-votes { font-family: var(--mono); color: var(--acc); }

/* ---------- магазин в админке ---------- */
.shop-admin-list { display: grid; gap: 16px; margin-bottom: 28px; max-width: 920px; }
.shop-admin-item { padding: 18px; border: 1px solid var(--line); border-radius: 12px; background: rgba(255,255,255,0.015); }
.shop-admin-item .settings-grid { margin-bottom: 12px; }
.shop-admin-actions { display: flex; gap: 10px; flex-wrap: wrap; }
.shop-admin-actions .btn-primary { color: #10160a; }

/* ---------- настройки в админке ---------- */
.settings-form { max-width: 760px; }
.settings-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 16px; margin-bottom: 18px; }
.settings-field { display: flex; flex-direction: column; gap: 8px; font-size: 13px; color: var(--muted); }
.settings-field .input { flex: none; }
.settings-wide { grid-column: 1 / -1; }
.settings-field textarea { resize: vertical; min-height: 96px; }
.settings-check { display: flex; align-items: center; gap: 10px; padding: 12px 14px; border: 1px solid var(--line); border-radius: 10px; font-size: 14px; background: rgba(255,255,255,.015); }
.settings-check input { width: 18px; height: 18px; accent-color: var(--acc); }

/* ---------- вход и регистрация ---------- */
.auth-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(320px, 420px); gap: 40px; align-items: start; max-width: 980px; }
.auth-copy h1 { margin: 6px 0 14px; font-size: clamp(2rem, 4vw, 3rem); text-transform: uppercase; letter-spacing: .02em; }
.auth-copy .lead { max-width: 540px; }
.auth-points { list-style: none; margin: 28px 0 0; padding: 0; display: grid; gap: 16px; max-width: 560px; }
.auth-points li { display: grid; gap: 4px; padding-left: 16px; border-left: 2px solid rgba(157,214,74,.35); }
.auth-points b { font-size: 14.5px; }
.auth-points p { margin: 0; font-size: 13.5px; color: var(--muted); line-height: 1.55; }
.auth-panel { padding: 26px; }
.auth-form { display: flex; flex-direction: column; }
.auth-form .field-label { margin: 14px 0 7px; }
.auth-form .field-label:first-child { margin-top: 0; }
.auth-form .input { flex: none; width: 100%; padding: 13px 16px; border-radius: 12px; border: 1px solid var(--line-strong); background: rgba(0,0,0,.35); color: var(--txt); font: inherit; font-size: 16px; transition: border-color .15s; }
.auth-form .input:focus { outline: none; border-color: var(--acc); box-shadow: 0 0 0 3px rgba(185,227,74,.12); }
.auth-submit { margin-top: 22px; width: 100%; }
.auth-alt { margin: 16px 0 0; text-align: center; }
.auth-error { margin-bottom: 16px; }
.auth-panel .hint code { color: var(--txt); }

/* ---------- заглушка выключенного сайта ---------- */
.maintenance { max-width: 680px; margin: 6vh auto; padding: 46px 40px; border: 1px solid var(--line); border-radius: 16px; background: rgba(255,255,255,.02); text-align: center; }
.maintenance h1 { margin: 10px 0 16px; font-size: clamp(1.9rem, 4vw, 3rem); text-transform: uppercase; }
.maintenance .lead { margin: 0 auto 12px; max-width: 520px; }
.maintenance .cta { justify-content: center; margin-bottom: 6px; }
.maintenance .hint { margin-top: 22px; }
.site-form { margin-top: 6px; }

@media (max-width: 820px) {
  .vote-grid { grid-template-columns: 1fr; }
  .code-big { font-size: 21px; }
  .auth-grid { grid-template-columns: 1fr; gap: 26px; }
  .maintenance { padding: 34px 22px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .status i { animation: none; }
  * { transition: none !important; }
}

/* ========================================================
   Магазин: плитки, фильтры, балансы
   ======================================================== */
.shop-banner {
  margin: 0 0 18px; padding: 16px 20px; border-radius: 12px;
  border: 1px solid var(--line-strong);
  background: linear-gradient(120deg, rgba(185,227,74,.10), rgba(185,227,74,.02));
  color: #cfd8bf; font-size: 15px;
}
.shop-balance { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 22px; margin: 0 0 20px; font-size: 14.5px; color: var(--muted); }
.shop-balance b { color: var(--txt); font-family: var(--mono); }
.shop-balance .btn { margin-left: 0; }
.nav-balance {
  font-family: var(--mono); font-size: 12px; color: var(--acc);
  border: 1px solid var(--line); border-radius: 999px; padding: 5px 11px; white-space: nowrap;
}
.shop-toolbar { display: flex; flex-wrap: wrap; gap: 14px; align-items: flex-start; justify-content: space-between; margin: 0 0 24px; }
.filter-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.filter-chip {
  padding: 8px 14px; border-radius: 999px; border: 1px solid var(--line);
  background: rgba(255,255,255,.02); color: var(--muted);
  font-size: 13px; letter-spacing: .02em; text-decoration: none; white-space: nowrap;
  transition: color .15s, border-color .15s, background .15s;
}
.filter-chip:hover { color: var(--txt); border-color: var(--line-strong); text-decoration: none; }
.filter-chip.is-on { color: #10160a; background: var(--acc); border-color: var(--acc); font-weight: 700; }
.shop-sort { display: flex; gap: 8px; flex-wrap: wrap; flex: 1 1 380px; justify-content: flex-end; }
.shop-sort .input { min-width: 150px; }
.shop-note { margin-top: 22px; }

.tiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(232px, 1fr)); gap: 16px; }
.tile {
  display: flex; flex-direction: column; overflow: hidden;
  border: 1px solid var(--line); border-radius: var(--radius);
  background: linear-gradient(180deg, rgba(255,255,255,.035), rgba(255,255,255,.008));
  transition: border-color .18s, transform .18s, box-shadow .18s;
}
.tile:hover { border-color: var(--line-strong); transform: translateY(-3px); box-shadow: 0 18px 34px -26px rgba(0,0,0,.9); }
.tile.is-featured { border-color: rgba(255,179,71,.4); }
.tile.is-soldout { opacity: .72; }
.tile-media {
  position: relative; aspect-ratio: 4 / 3; overflow: hidden;
  background: radial-gradient(circle at 50% 40%, rgba(185,227,74,.10), rgba(0,0,0,.35));
  display: grid; place-items: center;
}
.tile-media img { width: 100%; height: 100%; object-fit: cover; display: block; }
.tile-ph { font-family: var(--mono); font-size: 30px; color: var(--acc-dim); letter-spacing: .1em; text-transform: uppercase; }
.tile-discount, .tile-badge, .tile-star, .tile-sold {
  position: absolute; font-family: var(--mono); font-size: 11px; letter-spacing: .08em;
  padding: 4px 9px; border-radius: 8px; text-transform: uppercase;
}
.tile-discount { top: 10px; left: 10px; background: var(--danger); color: #1a0a04; font-weight: 700; }
.tile-badge { top: 10px; right: 10px; background: rgba(10,12,8,.8); border: 1px solid var(--acc-dim); color: var(--acc); }
.tile-star { bottom: 10px; right: 10px; color: var(--amber); background: rgba(10,12,8,.8); border: 1px solid rgba(255,179,71,.4); }
.tile-sold { bottom: 10px; left: 10px; background: rgba(10,12,8,.85); color: var(--muted); border: 1px solid var(--line-strong); }
.tile-body { display: flex; flex-direction: column; gap: 8px; padding: 14px 16px 16px; flex: 1; }
.tile-meta { display: flex; flex-wrap: wrap; gap: 8px; }
.tile-cat { font-family: var(--mono); font-size: 10px; letter-spacing: .16em; text-transform: uppercase; color: var(--acc-dim); }
.tile-stock { font-size: 11.5px; color: var(--amber); }
.tile-body h3 { margin: 0; font-size: 16px; line-height: 1.25; letter-spacing: .01em; }
.tile-desc { margin: 0; font-size: 13.5px; color: var(--muted); line-height: 1.45; }
.tile-price {
  margin-top: auto;
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding-top: 6px;
}
.tile-price-row { display: flex; align-items: baseline; flex-wrap: wrap; gap: 8px; }
.tile-price b { font-size: 16px; color: var(--acc); }
.tile-price s { font-size: 13px; color: #6d7563; }
.tile-buy { display: flex; flex-direction: column; gap: 6px; margin-top: 8px; }
.tile-body form { margin: 0; }
.tile-body .btn { width: 100%; }
.tile-body .btn[disabled] { opacity: .5; cursor: not-allowed; }

.account-panel { max-width: 760px; }
.balance-cards { display: flex; flex-wrap: wrap; gap: 12px; margin: 0 0 18px; }
.balance-card {
  flex: 1 1 150px; padding: 12px 16px; border-radius: 11px;
  border: 1px solid var(--line); background: rgba(0,0,0,.25);
}
.balance-card span { display: block; font-family: var(--mono); font-size: 10px; letter-spacing: .16em; text-transform: uppercase; color: var(--muted); }
.balance-card b { font-size: 22px; color: var(--acc); }

/* ========================================================
   Админка 2.0
   ======================================================== */
.admin-body { background-color: rgba(0,0,0,.82); }
.admin-top .admin-status { font-family: var(--mono); font-size: 12px; color: var(--muted); }
.admin-shell { display: grid; grid-template-columns: 232px minmax(0, 1fr); gap: 0; max-width: 1440px; margin: 0 auto; align-items: start; }
.admin-side {
  position: sticky; top: 58px; align-self: start;
  padding: 18px 12px; border-right: 1px solid var(--line); min-height: calc(100vh - 58px);
}
.admin-tabs { display: flex; flex-direction: column; gap: 3px; }
.admin-tab {
  display: flex; align-items: center; justify-content: space-between; gap: 8px;
  padding: 10px 13px; border-radius: 9px; border: 1px solid transparent;
  color: var(--muted); font-size: 14.5px; text-decoration: none;
  transition: color .15s, background .15s, border-color .15s;
}
.admin-tab:hover { color: var(--txt); background: rgba(255,255,255,.03); text-decoration: none; }
.admin-tab.is-active { color: var(--acc); background: rgba(185,227,74,.08); border-color: var(--line-strong); font-weight: 600; }
.tab-badge { font-family: var(--mono); font-size: 11px; background: var(--amber); color: #1a1204; border-radius: 999px; padding: 1px 7px; }
.admin-side-foot { margin-top: 22px; padding-top: 16px; border-top: 1px solid var(--line); font-size: 12.5px; color: var(--muted); }
.admin-main { padding: 24px clamp(16px, 3vw, 32px) 60px; min-width: 0; }
.admin-page-head { margin: 0 0 20px; }
.admin-page-head h1 { margin: 0 0 4px; font-size: clamp(1.4rem, 2.6vw, 1.9rem); text-transform: uppercase; letter-spacing: .02em; }
.admin-page-head p { margin: 0; font-size: 13.5px; }
.admin-2col { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 16px; margin-bottom: 8px; }
.admin-main .panel { margin-bottom: 16px; }
.admin-main .panel h3 { color: var(--acc); font-size: 12px; letter-spacing: .16em; }
.settings-checks { display: flex; flex-wrap: wrap; gap: 10px; }
.settings-check { flex: 1 1 220px; cursor: pointer; }
.settings-field .input { width: 100%; }
.settings-field .input[type="number"] { width: 100%; }
.settings-form textarea, .item-form textarea { font-family: var(--mono); font-size: 13px; }
.code-area { width: 100%; font-size: 13px; line-height: 1.5; white-space: pre; }
.admin-h { margin: 26px 0 12px; font-size: 13px; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); }
.nowrap { white-space: nowrap; }
.inline-form { display: inline-flex; margin: 0 4px 0 0; }
.btn-danger { border-color: rgba(224,101,63,.5); background: rgba(224,101,63,.10); color: #f0b2a0; }
.btn-danger:hover { border-color: var(--danger); background: rgba(224,101,63,.18); }
.tag-danger { font-size: 11px; font-family: var(--mono); background: rgba(224,101,63,.16); color: #f0b2a0; border: 1px solid rgba(224,101,63,.4); border-radius: 999px; padding: 2px 8px; }
.mini-stat { font-family: var(--mono); font-size: 12px; color: var(--acc); border: 1px solid var(--line); border-radius: 999px; padding: 4px 10px; }

.admin-items { display: grid; gap: 10px; }
.admin-item { border: 1px solid var(--line); border-radius: 12px; background: rgba(255,255,255,.015); }

.admin-item > summary {
  display: grid; grid-template-columns: 46px minmax(0, 1.4fr) auto auto; gap: 12px;
  align-items: center; padding: 10px 14px; cursor: pointer; list-style: none;
}
.admin-item > summary::-webkit-details-marker { display: none; }
.admin-item[open] > summary { border-bottom: 1px solid var(--line); }
.admin-item-thumb { width: 46px; height: 38px; display: grid; place-items: center; border-radius: 7px; background: rgba(0,0,0,.35); color: var(--muted); overflow: hidden; font-size: 11px; }
.admin-item-thumb img { width: 100%; height: 100%; object-fit: cover; }
.admin-item-title { font-weight: 600; font-size: 14.5px; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.admin-item-price { font-family: var(--mono); font-size: 12.5px; color: var(--acc); white-space: nowrap; }
.admin-item-price s { color: #6d7563; margin-left: 4px; }
.admin-item-cat { font-size: 11px; color: var(--muted); text-transform: uppercase; letter-spacing: .1em; }
.admin-add > summary { grid-template-columns: 1fr; color: var(--acc); }
.item-form { padding: 16px; }
.item-form-media { display: flex; gap: 16px; flex-wrap: wrap; margin-bottom: 16px; }
.item-thumb {
  width: 150px; height: 112px; flex: none; border-radius: 10px; overflow: hidden;
  border: 1px dashed var(--line-strong); background: rgba(0,0,0,.3);
  display: grid; place-items: center; color: var(--muted); font-size: 12px;
}
.item-thumb img { width: 100%; height: 100%; object-fit: cover; }
.item-media-fields { flex: 1 1 320px; min-width: 0; }
.item-media-fields .settings-field { margin-bottom: 8px; }
.item-media-fields .hint { margin: 4px 0 0; }
.item-flags { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; margin: 14px 0; }
.item-flags .settings-check { flex: 0 0 auto; }
.item-tools { display: flex; gap: 8px; flex-wrap: wrap; padding: 0 16px 16px; }
.item-tools form { margin: 0; }

.admin-users { display: grid; gap: 12px; }
.admin-user { border: 1px solid var(--line); border-radius: 12px; padding: 14px 16px; background: rgba(255,255,255,.015); }
.admin-user.is-banned { border-color: rgba(224,101,63,.35); background: rgba(224,101,63,.05); }
.admin-user-head { display: flex; flex-wrap: wrap; gap: 10px; align-items: flex-start; justify-content: space-between; }
.admin-user-badges { display: flex; flex-wrap: wrap; gap: 8px; }
.admin-user-forms { display: grid; gap: 10px; margin-top: 12px; }
.admin-user-forms .field-row { flex-wrap: wrap; align-items: flex-end; }
.admin-user-forms .settings-field { flex: 0 1 auto; }
.admin-user-forms .settings-field .input { flex: none; }
.admin-user-forms .settings-field span { font-family: var(--mono); font-size: 10px; letter-spacing: .14em; }

@media (max-width: 900px) {
  .admin-shell { grid-template-columns: 1fr; }
  .admin-side { position: static; min-height: 0; border-right: none; border-bottom: 1px solid var(--line); padding: 10px 12px; }
  .admin-tabs { flex-direction: row; flex-wrap: wrap; }
  .admin-tab { white-space: nowrap; border: 1px solid var(--line); }
  .admin-side-foot { display: none; }
  .shop-sort { justify-content: flex-start; }
  .tiles { grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); }
}

/* ---------- прокрутка таблиц ---------- */
.table-wrap { scrollbar-width: thin; scrollbar-color: var(--acc-dim) rgba(255,255,255,.05); }
.table-wrap::-webkit-scrollbar { height: 8px; width: 8px; }
.table-wrap::-webkit-scrollbar-track { background: rgba(255,255,255,.04); border-radius: 8px; }
.table-wrap::-webkit-scrollbar-thumb { background: rgba(185,227,74,.35); border-radius: 8px; }
.table-wrap::-webkit-scrollbar-thumb:hover { background: rgba(185,227,74,.55); }

/* ======================== КЕЙСЫ ======================== */
.case-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 20px;
  margin: 22px 0 10px;
}

.case-card {
  display: flex;
  flex-direction: column;
  background: linear-gradient(180deg, var(--panel-2), var(--panel));
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  transition: transform .25s ease, border-color .25s ease, box-shadow .25s ease;
}
.case-card:hover {
  transform: translateY(-4px);
  border-color: var(--line-strong);
  box-shadow: 0 18px 42px rgba(0, 0, 0, .45);
}
.case-card.is-free { border-color: rgba(185, 227, 74, .38); }

.case-cover {
  position: relative;
  aspect-ratio: 16 / 9;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  background: radial-gradient(120% 130% at 50% 15%, rgba(185, 227, 74, .18), rgba(10, 12, 8, .92));
}
.case-cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: scale(1.02);
  transition: transform .45s ease;
}
.case-card:hover .case-cover img { transform: scale(1.09); }
.case-cover-ph {
  font-size: 42px;
  font-weight: 700;
  letter-spacing: .08em;
  color: rgba(185, 227, 74, .5);
  text-transform: uppercase;
}
.case-badge,
.case-free-mark {
  position: absolute;
  top: 10px;
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .12em;
  text-transform: uppercase;
  backdrop-filter: blur(6px);
}
.case-badge {
  left: 10px;
  color: var(--acc);
  background: rgba(10, 12, 8, .72);
  border: 1px solid rgba(185, 227, 74, .45);
}
.case-free-mark {
  right: 10px;
  color: #0a0c08;
  background: var(--acc);
  border: 1px solid var(--acc);
}

.case-body {
  display: flex;
  flex-direction: column;
  gap: 8px;
  flex: 1;
  padding: 16px 16px 18px;
}
.case-body h3 { margin: 0; font-size: 20px; line-height: 1.25; }
.case-desc { margin: 0; font-size: 14px; color: var(--muted); }
.case-meta {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  margin-top: auto;
  padding-top: 8px;
  font-size: 12px;
  letter-spacing: .07em;
  text-transform: uppercase;
  color: var(--muted);
}
.case-meta-free { color: var(--acc); font-weight: 700; }
.case-meta-price { color: var(--txt); font-weight: 700; }

.case-pool { display: flex; gap: 6px; flex-wrap: wrap; margin: 2px 0 6px; }
.case-pool-item {
  width: 42px;
  height: 42px;
  border-radius: 9px;
  border: 1px solid var(--line);
  background: #0b0e08;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  font-size: 11px;
  color: var(--muted);
}
.case-pool-item img { width: 100%; height: 100%; object-fit: cover; }
.case-pool-item i { font-style: normal; }

/* редкость */
.r-common { border-color: rgba(154, 164, 140, .35); }
.r-rare { border-color: rgba(94, 168, 255, .55); }
.r-epic { border-color: rgba(192, 123, 255, .6); }
.r-legendary { border-color: rgba(255, 179, 71, .75); }
.case-result.r-rare, .case-win.r-rare { box-shadow: 0 0 26px rgba(94, 168, 255, .12); }
.case-result.r-epic, .case-win.r-epic { box-shadow: 0 0 26px rgba(192, 123, 255, .14); }
.case-result.r-legendary, .case-win.r-legendary { box-shadow: 0 0 30px rgba(255, 179, 71, .18); }

/* результат на странице */
.case-result {
  display: grid;
  grid-template-columns: 96px 1fr;
  gap: 18px;
  align-items: center;
  margin-top: 20px;
  padding: 18px;
  background: linear-gradient(120deg, rgba(185, 227, 74, .07), var(--panel));
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
}
.case-result-media {
  width: 96px;
  height: 96px;
  border-radius: 12px;
  background: #0b0e08;
  border: 1px solid var(--line);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  font-size: 30px;
  color: var(--muted);
}
.case-result-media img { width: 100%; height: 100%; object-fit: contain; }
.case-result-kicker {
  font-size: 11px;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--acc);
}
.case-result-body h3 { margin: 2px 0 6px; }

/* лента дропов */
.case-drops { margin-top: 36px; }
.drop-list { list-style: none; margin: 14px 0 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.drop-list li {
  display: grid;
  grid-template-columns: 40px 1fr auto auto;
  align-items: center;
  gap: 12px;
  padding: 8px 12px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: rgba(19, 23, 16, .7);
  font-size: 14px;
}
.drop-thumb {
  width: 40px;
  height: 40px;
  border-radius: 8px;
  overflow: hidden;
  background: #0b0e08;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  color: var(--muted);
}
.drop-thumb img { width: 100%; height: 100%; object-fit: cover; }
.drop-title { display: flex; flex-direction: column; line-height: 1.25; }
.drop-title small { color: var(--muted); font-size: 12px; }
.drop-user { color: var(--muted); font-size: 13px; }
.drop-time { color: var(--muted); font-size: 12px; white-space: nowrap; }

/* модалка рулетки: нативный <dialog> — не зависит от backdrop-filter body */
.case-modal {
  width: min(680px, calc(100% - 24px));
  max-width: none;
  max-height: 92vh;
  margin: auto;
  padding: 0;
  border: 0;
  border-radius: 18px;
  background: transparent;
  color: var(--txt);
  overflow: visible;
}
.case-modal::backdrop { background: rgba(4, 6, 3, .8); backdrop-filter: blur(6px); }
.case-modal-panel {
  position: relative;
  width: min(680px, 100%);
  padding: 22px;
  border: 1px solid var(--line-strong);
  border-radius: 18px;
  background: var(--panel);
  box-shadow: 0 30px 80px rgba(0, 0, 0, .65);
}
.case-modal-close {
  position: absolute;
  top: 8px;
  right: 12px;
  border: 0;
  background: none;
  color: var(--muted);
  font-size: 28px;
  line-height: 1;
  cursor: pointer;
}
.case-modal-close:hover { color: var(--txt); }
.case-modal-panel h3 { margin: 0 0 4px; font-size: 22px; }
.case-modal-sub { margin: 0 0 16px; color: var(--muted); font-size: 14px; }

.reel {
  position: relative;
  height: 138px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: linear-gradient(90deg, #090c06, #141a0f 50%, #090c06);
}
.reel::before,
.reel::after {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  width: 56px;
  z-index: 2;
  pointer-events: none;
}
.reel::before { left: 0; background: linear-gradient(90deg, #0b0e08, transparent); }
.reel::after { right: 0; background: linear-gradient(270deg, #0b0e08, transparent); }
.reel-strip {
  display: flex;
  gap: 10px;
  padding: 12px;
  will-change: transform;
  transition: transform 4.2s cubic-bezier(.12, .72, .12, 1);
}
.reel-item {
  flex: 0 0 112px;
  height: 112px;
  padding: 8px 6px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #0d1109;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  text-align: center;
  font-size: 11px;
  line-height: 1.2;
  color: var(--muted);
  overflow: hidden;
}
.reel-item img { width: 62px; height: 62px; object-fit: contain; }
.reel-item span { max-height: 28px; overflow: hidden; }
.reel-item.is-win {
  border-color: var(--acc);
  box-shadow: 0 0 0 1px var(--acc), 0 0 26px rgba(185, 227, 74, .35);
  color: var(--txt);
  animation: reel-win .5s cubic-bezier(.2, .9, .3, 1.35);
}
@keyframes reel-win {
  from { transform: scale(.84); }
  to { transform: scale(1); }
}
/* лента крутится по кадрам из JS — лёгкое смазывание и яркий маркер */
.reel-strip { transition: filter .2s linear; }
.reel.is-spinning .reel-strip { filter: blur(.35px); }
.reel.is-spinning .reel-mark { box-shadow: 0 0 24px rgba(185, 227, 74, 1); }
.reel-mark {
  position: absolute;
  left: 50%;
  top: 0;
  bottom: 0;
  width: 2px;
  transform: translateX(-1px);
  background: linear-gradient(180deg, transparent, var(--acc), transparent);
  box-shadow: 0 0 14px rgba(185, 227, 74, .8);
  pointer-events: none;
  z-index: 3;
}
.case-modal-actions { display: flex; justify-content: flex-end; gap: 10px; margin-top: 16px; }
.case-win {
  display: grid;
  grid-template-columns: 76px 1fr;
  gap: 14px;
  align-items: center;
  margin-top: 16px;
  padding: 14px;
  border: 1px solid var(--line-strong);
  border-radius: 12px;
  background: linear-gradient(120deg, rgba(185, 227, 74, .07), transparent);
}
.case-win[hidden] { display: none; }
.case-win-media {
  width: 76px;
  height: 76px;
  border-radius: 10px;
  overflow: hidden;
  background: #0b0e08;
  border: 1px solid var(--line);
  display: flex;
  align-items: center;
  justify-content: center;
}
.case-win-media img { width: 100%; height: 100%; object-fit: contain; }
.case-win-body h4 { margin: 0 0 4px; font-size: 18px; }
.case-win-body p { margin: 0; font-size: 13px; color: var(--muted); }
.case-win-body code { font-size: 13px; }

.tag-free {
  display: inline-block;
  margin-left: 6px;
  padding: 1px 8px;
  border-radius: 999px;
  background: rgba(185, 227, 74, .14);
  color: var(--acc);
  font-size: 11px;
  letter-spacing: .06em;
  text-transform: uppercase;
}
.case-admin-h { margin: 18px 0 8px; font-size: 15px; color: var(--muted); text-transform: uppercase; letter-spacing: .08em; }
.case-admin-items { display: grid; grid-template-columns: repeat(auto-fill, minmax(330px, 1fr)); gap: 12px; }
.case-item-form {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  gap: 10px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--panel-2);
}
.case-item-form .settings-field { flex: 1 1 135px; }
.case-item-media { display: flex; flex-direction: column; gap: 6px; width: 110px; }
.case-item-media .item-thumb { width: 64px; height: 64px; }
.case-item-actions { display: flex; gap: 8px; flex: 1 1 100%; justify-content: flex-end; }
.case-admin-add { margin-top: 12px; }
.case-admin-add > summary { display: inline-block; cursor: pointer; }

@media (max-width: 620px) {
  .case-result { grid-template-columns: 1fr; }
  .case-result-media { width: 100%; height: 160px; }
  .drop-list li { grid-template-columns: 40px 1fr; }
  .drop-user, .drop-time { display: none; }
  .reel-strip { transition-duration: 3.4s; }
  .case-modal-panel { padding: 16px; }
}

@media (prefers-reduced-motion: reduce) {
  .reel-strip { transition: none; }
  .case-card, .case-cover img { transition: none; }
}

/* семь пунктов меню не помещаются раньше — переключаемся на «Меню» */
@media (max-width: 1024px) {
  .nav { display: none; }
  .nav-mobile { display: block; }
}

.case-modal[hidden] { display: none; }
.reel-empty { opacity: .4; }

/* на телефоне баланс в шапке не помещается — он есть на страницах */
@media (max-width: 640px) {
  .nav-balance { display: none; }
  .top-actions { gap: 6px; }
}

/* ежедневный бонус и промокоды в профиле */
.daily-reward {
  margin: 6px 0 14px;
  font-size: 18px;
  color: var(--acc);
  font-family: var(--mono);
}

/* график покупок в админке */
.admin-bars { display: flex; flex-direction: column; gap: 9px; margin: 6px 0 14px; }
.bar-row {
  display: grid;
  grid-template-columns: 46px minmax(0, 1fr) 34px 74px;
  align-items: center;
  gap: 10px;
  font-size: 13px;
}
.bar-label, .bar-note { color: var(--muted); font-family: var(--mono); font-size: 12px; }
.bar-note { text-align: right; }
.bar-row b { color: var(--acc); text-align: right; font-family: var(--mono); }
.bar-track { height: 10px; border-radius: 999px; background: rgba(185, 227, 74, 0.09); overflow: hidden; }
.bar-track i {
  display: block;
  height: 100%;
  min-width: 2px;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--acc-dim), var(--acc));
}

@media (max-width: 520px) {
  .bar-row { grid-template-columns: 40px minmax(0, 1fr) 30px; }
  .bar-note { display: none; }
  .connect-grid { grid-template-columns: 1fr; }
}
