/* CS2 Rewards — light minimal theme (ChatGPT / Curve / SemRush inspired) */

@font-face { font-family: "Inter"; font-style: normal; font-weight: 400; font-display: swap; src: url("/assets/fonts/inter-400.woff2") format("woff2"); }
@font-face { font-family: "Inter"; font-style: normal; font-weight: 500; font-display: swap; src: url("/assets/fonts/inter-500.woff2") format("woff2"); }
@font-face { font-family: "Inter"; font-style: normal; font-weight: 600; font-display: swap; src: url("/assets/fonts/inter-600.woff2") format("woff2"); }
@font-face { font-family: "Inter"; font-style: normal; font-weight: 700; font-display: swap; src: url("/assets/fonts/inter-700.woff2") format("woff2"); }
@font-face { font-family: "Inter"; font-style: normal; font-weight: 800; font-display: swap; src: url("/assets/fonts/inter-800.woff2") format("woff2"); }

:root {
  --bg: #ffffff;
  --bg-2: #f7f8fa;
  --panel: #ffffff;
  --panel-2: #fbfcfd;
  --line: #ebedf0;
  --line-strong: #dcdfe4;
  --text: #0d1117;
  --text-2: #3b424d;
  --muted: #6b7280;
  --faint: #9aa1ac;
  --accent: #2563eb;
  --accent-ink: #1d4fd7;
  --accent-soft: #eef3ff;
  --green: #16a34a;
  --green-soft: #ecfdf3;
  --gold: #b45309;
  --gold-soft: #fef6e7;
  --danger: #dc2626;
  --danger-soft: #fef2f2;
  --ink-btn: #0d1117;
  --radius: 12px;
  --radius-lg: 16px;
  --radius-xl: 22px;
  --shadow-sm: 0 1px 2px rgba(16, 24, 40, 0.05);
  --shadow: 0 1px 3px rgba(16, 24, 40, 0.06), 0 8px 24px rgba(16, 24, 40, 0.06);
  --shadow-lg: 0 12px 40px rgba(16, 24, 40, 0.10);
  --font: "Inter", "Segoe UI", system-ui, -apple-system, Roboto, "Helvetica Neue", Arial, sans-serif;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  overflow-x: hidden;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
body::before {
  content: "";
  position: fixed;
  inset: 0 0 auto;
  height: 420px;
  z-index: -1;
  background: linear-gradient(180deg, #f3f6fc 0%, rgba(243, 246, 252, 0) 100%);
}

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; }
::selection { background: var(--accent-soft); }

.wrap { width: min(1140px, 100% - 48px); margin-inline: auto; }
@media (max-width: 560px) { .wrap { width: calc(100% - 32px); } }

/* ---------- header ---------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  background: rgba(255, 255, 255, 0.8);
  border-bottom: 1px solid var(--line);
}
.site-header .wrap { display: flex; align-items: center; gap: 26px; height: 64px; }

.brand { display: flex; align-items: center; gap: 9px; font-weight: 700; font-size: 16px; letter-spacing: -0.01em; color: var(--text); }
.brand svg { display: block; }
.brand .beta {
  font-size: 10px; font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase;
  color: var(--accent); background: var(--accent-soft);
  border-radius: 999px; padding: 3px 9px; margin-left: 2px;
}

.main-nav { display: flex; gap: 2px; margin-left: auto; }
.main-nav a {
  padding: 8px 13px; border-radius: 9px; font-size: 14.5px; font-weight: 500;
  color: var(--muted); transition: color 0.15s, background 0.15s;
}
.main-nav a:hover, .main-nav a[aria-current="page"] { color: var(--text); background: var(--bg-2); }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  border: 1px solid transparent; border-radius: 10px; padding: 10px 18px;
  font-size: 14.5px; font-weight: 600; letter-spacing: -0.005em;
  transition: transform 0.12s, box-shadow 0.15s, background 0.15s, border-color 0.15s;
}
.btn:active { transform: translateY(1px); }

.btn-primary { color: #fff; background: var(--ink-btn); box-shadow: var(--shadow-sm); }
.btn-primary:hover { background: #23272e; box-shadow: var(--shadow); }

.btn-ghost { color: var(--text); background: #fff; border-color: var(--line-strong); }
.btn-ghost:hover { background: var(--bg-2); border-color: var(--faint); }

.btn-big { padding: 13px 24px; font-size: 15.5px; border-radius: 12px; }
.btn[disabled] { opacity: 0.5; cursor: not-allowed; }
.header-cta { margin-left: 2px; }

@media (max-width: 860px) {
  .main-nav { display: none; }
  .site-header .wrap { justify-content: space-between; }
}

/* ---------- hero ---------- */

.hero { padding: 78px 0 56px; }
.hero-grid { display: grid; grid-template-columns: 1.05fr 0.95fr; gap: 56px; align-items: center; }
@media (max-width: 940px) { .hero-grid { grid-template-columns: 1fr; gap: 40px; } .hero { padding-top: 52px; } }

.pill-row { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 24px; }
.pill {
  display: inline-flex; align-items: center; gap: 7px;
  font-size: 12.5px; font-weight: 500; color: var(--muted);
  background: #fff; border: 1px solid var(--line-strong); border-radius: 999px; padding: 5px 13px; white-space: nowrap;
}
.pill .dot { width: 7px; height: 7px; border-radius: 50%; background: var(--green); }
.pill.accent { color: var(--accent-ink); border-color: #cddaff; background: var(--accent-soft); }
.pill.gold { color: var(--gold); border-color: #f3dcae; background: var(--gold-soft); }

h1 { font-size: clamp(34px, 5vw, 56px); line-height: 1.05; font-weight: 800; letter-spacing: -0.03em; margin-bottom: 20px; color: var(--text); }
.grad-text { color: var(--accent); }

.lead { font-size: 18px; color: var(--muted); max-width: 52ch; margin-bottom: 30px; line-height: 1.6; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-bottom: 36px; }

.hero-stats { display: flex; gap: 40px; flex-wrap: wrap; }
.hero-stat .num { font-size: 26px; font-weight: 700; letter-spacing: -0.02em; }
.hero-stat .lbl { font-size: 13px; color: var(--muted); }

.hero-visual { position: relative; }
.hero-case-art { width: min(420px, 100%); margin-inline: auto; filter: drop-shadow(0 20px 40px rgba(16, 24, 40, 0.12)); }
.hero-float {
  position: absolute; width: 116px; padding: 10px;
  background: #fff; border: 1px solid var(--line); border-radius: 14px; box-shadow: var(--shadow);
  animation: floaty 5.5s ease-in-out infinite;
}
.hero-float img { height: 60px; object-fit: contain; margin-inline: auto; }
.hero-float .nm { font-size: 10.5px; font-weight: 500; color: var(--muted); text-align: center; margin-top: 6px; line-height: 1.3; }
.hero-float.f1 { top: 2%; left: -2%; animation-delay: 0s; }
.hero-float.f2 { bottom: 8%; left: 3%; animation-delay: 1.4s; }
.hero-float.f3 { top: 12%; right: -1%; animation-delay: 0.8s; }
@media (max-width: 560px) { .hero-float { display: none; } }
@keyframes floaty { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-10px); } }

/* ---------- sections ---------- */

.section { padding: 68px 0; }
.section-head { display: flex; align-items: end; justify-content: space-between; gap: 20px; margin-bottom: 32px; }
.section-head h2, .section > .wrap > h2 { font-size: clamp(24px, 3.2vw, 33px); font-weight: 700; letter-spacing: -0.025em; }
.section-head p { color: var(--muted); margin-top: 8px; max-width: 62ch; }
.section-link { font-size: 14.5px; font-weight: 600; color: var(--accent); white-space: nowrap; }
.section-link:hover { color: var(--accent-ink); }

/* ---------- case cards ---------- */

.case-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
@media (max-width: 980px) { .case-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 620px) { .case-grid { grid-template-columns: 1fr; } }

.case-card {
  position: relative; display: flex; flex-direction: column;
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius-lg);
  padding: 20px; overflow: hidden;
  transition: transform 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease;
}
.case-card:hover { transform: translateY(-3px); border-color: var(--line-strong); box-shadow: var(--shadow); }

.case-card .art { height: 160px; display: grid; place-items: center; margin-bottom: 14px; background: var(--bg-2); border-radius: 12px; }
.case-card .art img { height: 82%; object-fit: contain; transition: transform 0.25s ease; }
.case-card:hover .art img { transform: scale(1.04); }

.case-card h3 { font-size: 18px; font-weight: 700; letter-spacing: -0.01em; margin-bottom: 4px; }
.case-card .tag { font-size: 13.5px; color: var(--muted); margin-bottom: 14px; min-height: 2.7em; }

.mini-items { display: flex; gap: 8px; margin-bottom: 16px; }
.mini-items .mi { flex: 1; background: var(--bg-2); border: 1px solid var(--line); border-radius: 10px; padding: 7px 5px; display: grid; place-items: center; }
.mini-items img { height: 32px; object-fit: contain; }

.case-card .meta { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-top: auto; }
.case-card .meta .items-n { font-size: 12.5px; font-weight: 500; color: var(--muted); }
.case-card .meta .top { font-size: 12.5px; font-weight: 600; color: var(--gold); }
.case-card .open-link {
  margin-top: 14px; text-align: center; font-weight: 600; font-size: 14px;
  border-radius: 10px; padding: 11px; color: var(--text); background: var(--bg-2); border: 1px solid var(--line);
  transition: background 0.15s, border-color 0.15s, color 0.15s;
}
.case-card:hover .open-link { background: var(--ink-btn); border-color: var(--ink-btn); color: #fff; }

/* ---------- how it works / roadmap / partners ---------- */

.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
@media (max-width: 860px) { .steps { grid-template-columns: 1fr; } }
.step { background: #fff; border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 26px; }
.step .n { display: inline-grid; place-items: center; width: 36px; height: 36px; border-radius: 10px; font-weight: 700; color: #fff; background: var(--ink-btn); margin-bottom: 16px; }
.step h3 { font-size: 16.5px; font-weight: 700; margin-bottom: 8px; }
.step p { font-size: 14.5px; color: var(--muted); }

.roadmap { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
@media (max-width: 980px) { .roadmap { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .roadmap { grid-template-columns: 1fr; } }
.road-item { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; }
.road-item .phase { font-size: 11px; font-weight: 700; letter-spacing: 0.07em; text-transform: uppercase; color: var(--faint); margin-bottom: 10px; }
.road-item.live .phase { color: var(--green); }
.road-item.live { border-color: #bbf7d0; background: var(--green-soft); }
.road-item h3 { font-size: 15.5px; font-weight: 700; margin-bottom: 7px; }
.road-item p { font-size: 13.5px; color: var(--muted); }

.partner-panel {
  display: grid; grid-template-columns: 1.2fr 0.8fr; gap: 40px; align-items: center;
  background: var(--bg-2); border: 1px solid var(--line); border-radius: var(--radius-xl); padding: 44px;
}
@media (max-width: 860px) { .partner-panel { grid-template-columns: 1fr; padding: 30px 24px; } }
.partner-panel h2 { font-size: clamp(22px, 3vw, 29px); font-weight: 700; letter-spacing: -0.02em; margin-bottom: 12px; }
.partner-panel p { color: var(--muted); margin-bottom: 12px; }
.partner-list { list-style: none; display: grid; gap: 10px; }
.partner-list li { display: flex; gap: 10px; font-size: 14.5px; color: var(--text-2); }
.partner-list li::before { content: ""; flex: 0 0 6px; width: 6px; height: 6px; margin-top: 9px; border-radius: 50%; background: var(--accent); }
.partner-cta { text-align: center; }
.partner-cta .mail { display: block; margin-top: 14px; font-size: 13.5px; color: var(--muted); }
.partner-cta .mail a { color: var(--accent); }

/* ---------- footer ---------- */

.site-footer { border-top: 1px solid var(--line); padding: 44px 0 34px; margin-top: 40px; background: var(--bg-2); }
.footer-grid { display: grid; grid-template-columns: 1.3fr 1fr 1fr; gap: 34px; margin-bottom: 28px; }
@media (max-width: 780px) { .footer-grid { grid-template-columns: 1fr; } }
.footer-grid h4 { font-size: 12px; letter-spacing: 0.06em; text-transform: uppercase; color: var(--faint); margin-bottom: 12px; }
.footer-grid ul { list-style: none; display: grid; gap: 8px; }
.footer-grid a { font-size: 14px; color: var(--muted); }
.footer-grid a:hover { color: var(--text); }
.footer-brand p { font-size: 13.5px; color: var(--muted); max-width: 42ch; margin-top: 10px; }

.demo-banner {
  border: 1px solid #f3dcae; background: var(--gold-soft); color: var(--gold);
  font-size: 13.5px; font-weight: 500; border-radius: 12px; padding: 12px 16px; text-align: center; margin-bottom: 26px;
}
.legal { font-size: 12.5px; color: var(--faint); border-top: 1px solid var(--line); padding-top: 20px; line-height: 1.7; }

/* ---------- breadcrumbs ---------- */

.crumbs { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; font-size: 13.5px; color: var(--muted); padding: 22px 0 0; }
.crumbs a:hover { color: var(--text); }
.crumbs .sep { color: var(--faint); }
.crumbs .here { color: var(--text); font-weight: 500; }

.page-head { padding: 40px 0 8px; }
.page-head h1 { font-size: clamp(30px, 4vw, 42px); margin-bottom: 12px; }
.page-head .lead { margin-bottom: 8px; }

/* ---------- case hero ---------- */

.case-hero { padding: 34px 0 20px; }
.case-hero-grid { display: grid; grid-template-columns: 0.9fr 1.1fr; gap: 48px; align-items: center; }
@media (max-width: 920px) { .case-hero-grid { grid-template-columns: 1fr; gap: 26px; } }

.case-hero .art-box {
  position: relative; display: grid; place-items: center; padding: 28px;
  background: var(--bg-2); border: 1px solid var(--line); border-radius: var(--radius-xl); min-height: 320px;
}
.case-hero .art-box img { width: min(400px, 90%); }
.case-hero h1 { margin-bottom: 12px; }
.case-hero .desc { color: var(--muted); font-size: 16px; max-width: 56ch; margin-bottom: 22px; }

.best-drop-line {
  display: inline-flex; align-items: center; gap: 14px; background: #fff;
  border: 1px solid var(--line-strong); border-radius: 14px; padding: 10px 18px 10px 12px; margin-bottom: 26px; box-shadow: var(--shadow-sm);
}
.best-drop-line img { height: 50px; width: 74px; object-fit: contain; }
.best-drop-line .lbl { font-size: 11px; letter-spacing: 0.07em; text-transform: uppercase; color: var(--gold); font-weight: 700; }
.best-drop-line .nm { font-size: 15px; font-weight: 600; }
.best-drop-line .pr { font-size: 13px; color: var(--muted); }

.case-hero .actions { display: flex; flex-wrap: wrap; align-items: center; gap: 16px; }
.price-note { font-size: 12.5px; color: var(--muted); }

/* ---------- opening reel ---------- */

.opener { padding: 26px 0 10px; }
.reel-shell {
  position: relative; border: 1px solid var(--line); border-radius: var(--radius-lg);
  background: var(--bg-2); overflow: hidden; padding: 24px 0;
}
.reel-shell::before, .reel-shell::after { content: ""; position: absolute; top: 0; bottom: 0; width: 90px; z-index: 3; pointer-events: none; }
.reel-shell::before { left: 0; background: linear-gradient(90deg, var(--bg-2), transparent); }
.reel-shell::after { right: 0; background: linear-gradient(-90deg, var(--bg-2), transparent); }

.reel-marker { position: absolute; left: 50%; top: 0; bottom: 0; width: 2px; transform: translateX(-50%); background: var(--accent); z-index: 4; }
.reel-marker::before, .reel-marker::after { content: ""; position: absolute; left: 50%; transform: translateX(-50%); border: 6px solid transparent; }
.reel-marker::before { top: -1px; border-top-color: var(--accent); }
.reel-marker::after { bottom: -1px; border-bottom-color: var(--accent); }

.reel-track { display: flex; gap: 12px; will-change: transform; }
.reel-item {
  flex: 0 0 146px; background: #fff; border: 1px solid var(--line); border-top: 3px solid var(--rc, #cbd2dc);
  border-radius: 12px; padding: 12px 10px 10px; text-align: center;
}
.reel-item img { height: 64px; margin-inline: auto; object-fit: contain; }
.reel-item .nm { font-size: 11px; font-weight: 500; color: var(--muted); margin-top: 8px; line-height: 1.3; height: 2.6em; overflow: hidden; }

.opener-controls { display: flex; align-items: center; justify-content: center; gap: 18px; flex-wrap: wrap; padding: 22px 0 6px; }
.opener-note { font-size: 12.5px; color: var(--muted); text-align: center; width: 100%; }

/* ---------- result modal ---------- */

.modal-backdrop {
  position: fixed; inset: 0; z-index: 90; display: none; place-items: center;
  background: rgba(15, 23, 42, 0.34); backdrop-filter: blur(4px); -webkit-backdrop-filter: blur(4px); padding: 20px;
}
.modal-backdrop.show { display: grid; }
.result-modal {
  width: min(420px, 100%); background: #fff; border: 1px solid var(--line); border-radius: var(--radius-xl);
  padding: 32px 30px 26px; text-align: center; position: relative; box-shadow: var(--shadow-lg);
  animation: pop 0.3s cubic-bezier(0.2, 1.3, 0.4, 1);
}
@keyframes pop { from { transform: scale(0.9); opacity: 0; } to { transform: scale(1); opacity: 1; } }
.result-modal .rar {
  display: inline-block; font-size: 11px; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase;
  color: var(--result-glow, var(--muted)); background: color-mix(in srgb, var(--result-glow, #94a3b8) 12%, #fff);
  border: 1px solid color-mix(in srgb, var(--result-glow, #94a3b8) 40%, #fff); border-radius: 999px; padding: 4px 13px; margin-bottom: 18px;
}
.result-modal img { height: 120px; object-fit: contain; margin: 0 auto 16px; }
.result-modal h3 { font-size: 20px; font-weight: 700; margin-bottom: 6px; }
.result-modal .val { color: var(--muted); font-size: 14px; margin-bottom: 4px; }
.result-modal .demo-note { color: var(--gold); font-size: 12.5px; font-weight: 500; margin-bottom: 22px; }
.result-modal .row { display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; }

/* ---------- item cards / grids ---------- */

.strip-title { font-size: 19px; font-weight: 700; letter-spacing: -0.01em; margin-bottom: 18px; }
.item-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }
@media (max-width: 980px) { .item-grid { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 720px) { .item-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 380px) { .item-grid { grid-template-columns: 1fr; } }

.item-card {
  position: relative; background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  padding: 16px 14px 14px; overflow: hidden; transition: transform 0.15s ease, border-color 0.15s ease, box-shadow 0.15s ease;
}
.item-card:hover { transform: translateY(-2px); border-color: var(--line-strong); box-shadow: var(--shadow-sm); }
.item-card::before { content: ""; position: absolute; inset: 0 0 auto; height: 3px; background: var(--rc, #cbd2dc); opacity: 0.85; }
.item-card .img-box { height: 88px; display: grid; place-items: center; margin-bottom: 12px; background: var(--bg-2); border-radius: 10px; }
.item-card .img-box img { max-height: 80%; object-fit: contain; }
.item-card .weapon { font-size: 11px; letter-spacing: 0.04em; text-transform: uppercase; color: var(--faint); font-weight: 600; }
.item-card .finish { font-size: 14.5px; font-weight: 600; line-height: 1.25; margin: 2px 0 10px; }
.item-card .foot { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.rarity-badge {
  font-size: 10.5px; font-weight: 600; letter-spacing: 0.03em; text-transform: uppercase;
  color: var(--rc, #64748b); background: color-mix(in srgb, var(--rc, #94a3b8) 10%, #fff);
  border: 1px solid color-mix(in srgb, var(--rc, #94a3b8) 30%, #fff); border-radius: 7px; padding: 3px 8px; white-space: nowrap;
}
.item-card .price { font-size: 13.5px; font-weight: 700; color: var(--text); white-space: nowrap; }
.item-card .price .from { font-size: 10.5px; font-weight: 500; color: var(--muted); display: block; }
.item-card .price.na { font-size: 11px; font-weight: 500; color: var(--muted); }
.item-card .odds { font-size: 11px; color: var(--muted); margin-top: 8px; }
.best-strip .item-card { border-color: #f3dcae; }

/* ---------- disclaimer ---------- */

.disclaimer-block {
  border: 1px solid var(--line); border-left: 3px solid var(--gold); background: var(--gold-soft);
  border-radius: 12px; padding: 20px 24px; font-size: 13.5px; color: var(--text-2); line-height: 1.7;
}
.disclaimer-block strong { color: var(--text); }
.disclaimer-block a { color: var(--accent); }

.muted { color: var(--muted); }
.center { text-align: center; }
.mt-40 { margin-top: 40px; }
.updated-note { font-size: 12px; color: var(--faint); margin-top: 14px; }

/* ================= upgrader ================= */

.up-page { padding: 20px 0 60px; }

.up-topbar { display: flex; align-items: center; gap: 14px; background: #fff; border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 12px 18px; box-shadow: var(--shadow-sm); }
.up-logo { display: flex; align-items: center; gap: 9px; font-weight: 700; letter-spacing: -0.01em; font-size: 16px; }
.up-logo .chev { display: grid; }
.up-logo .chev svg { display: block; }
.up-demo-chip { font-size: 10px; font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase; color: var(--gold); background: var(--gold-soft); border-radius: 999px; padding: 3px 9px; }
.up-wallet { margin-left: auto; display: flex; align-items: center; gap: 10px; }
.up-bal { display: inline-flex; align-items: baseline; gap: 8px; background: var(--bg-2); border: 1px solid var(--line); border-radius: 10px; padding: 7px 14px; }
.up-bal .k { font-size: 10px; letter-spacing: 0.06em; text-transform: uppercase; color: var(--muted); font-weight: 600; }
.up-bal b { font-size: 16px; font-weight: 700; color: var(--green); }
.up-topbar #u-reset { font-size: 12.5px; padding: 8px 13px; }

.up-tools { display: flex; gap: 6px; }
.up-tool { width: 38px; height: 38px; display: grid; place-items: center; border-radius: 10px; border: 1px solid var(--line-strong); background: #fff; color: var(--muted); transition: all 0.15s; }
.up-tool:hover { color: var(--text); background: var(--bg-2); }
.up-tool.on { color: var(--accent); border-color: #cddaff; background: var(--accent-soft); }
#u-fast.on { color: var(--gold); border-color: #f3dcae; background: var(--gold-soft); }

.up-stats { display: flex; gap: 10px; margin-left: 8px; }
@media (max-width: 720px) { .up-stats { display: none; } }
.up-stat { display: inline-flex; flex-direction: column; background: var(--bg-2); border: 1px solid var(--line); border-radius: 10px; padding: 6px 13px; }
.up-stat .k { font-size: 9.5px; letter-spacing: 0.06em; text-transform: uppercase; color: var(--muted); font-weight: 600; }
.up-stat b { font-size: 15px; font-weight: 700; }

.up-main { display: grid; grid-template-columns: 220px 1fr; gap: 18px; align-items: start; margin-top: 18px; }
@media (max-width: 1080px) { .up-main { grid-template-columns: 1fr; } .up-feed { order: 3; } }

.up-feed { background: #fff; border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 14px; max-height: 760px; overflow: hidden; display: flex; flex-direction: column; }
.up-feed h3 { font-size: 11.5px; letter-spacing: 0.06em; text-transform: uppercase; color: var(--faint); margin-bottom: 12px; }
#u-feed { display: flex; flex-direction: column; gap: 8px; overflow-y: auto; }
@media (max-width: 1080px) { #u-feed { flex-direction: row; } .up-feed { max-height: none; } }
.feed-row { display: flex; align-items: center; gap: 10px; background: var(--bg-2); border: 1px solid var(--line); border-left: 3px solid var(--rc, #cbd2dc); border-radius: 10px; padding: 7px 10px; min-width: 190px; }
.feed-row img { height: 30px; width: 46px; object-fit: contain; }
.feed-row .fx { min-width: 0; }
.feed-row .pct { font-size: 12px; font-weight: 700; }
.feed-row .pct.win { color: var(--green); }
.feed-row .pct.lose { color: var(--danger); }
.feed-row .nm { font-size: 11px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.feed-row.best { border-left-color: var(--gold); background: var(--gold-soft); }
.feed-row.best .pct { color: var(--gold) !important; }
.feed-empty { font-size: 12.5px; color: var(--faint); padding: 8px 4px; }

.up-stage { display: grid; grid-template-columns: 1fr 340px 1fr; gap: 18px; align-items: stretch; }
@media (max-width: 860px) { .up-stage { grid-template-columns: 1fr; } .up-wheel-slot { order: -1; } }

.up-slot {
  position: relative; border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 20px; min-height: 320px;
  display: flex; flex-direction: column; background: #fff; transition: border-color 0.2s, box-shadow 0.2s;
}
.up-slot.filled { border-color: color-mix(in srgb, var(--slot-accent, var(--accent)) 40%, var(--line)); box-shadow: var(--shadow-sm); }
.up-slot .slot-weapon { font-size: 12px; letter-spacing: 0.04em; text-transform: uppercase; color: var(--muted); font-weight: 600; text-align: center; }
.up-slot .slot-name { font-size: 19px; font-weight: 700; text-align: center; margin-top: 2px; letter-spacing: -0.01em; }
.up-slot .slot-main { flex: 1; display: grid; place-items: center; padding: 12px 0; }
.up-slot .slot-main > img { max-height: 180px; object-fit: contain; filter: drop-shadow(0 10px 22px rgba(16, 24, 40, 0.14)); }
.up-slot .slot-price { text-align: center; font-size: 19px; font-weight: 700; color: var(--text); }
.up-slot .slot-close { position: absolute; top: 14px; right: 14px; width: 28px; height: 28px; display: grid; place-items: center; border-radius: 8px; border: 1px solid var(--line-strong); background: #fff; color: var(--muted); font-size: 15px; }
.up-slot .slot-close:hover { color: var(--danger); border-color: var(--danger); }

.slot-empty { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; gap: 6px; }
.slot-empty .chevs { color: var(--faint); margin-bottom: 8px; }
.slot-empty .t { font-size: 15px; font-weight: 600; max-width: 24ch; color: var(--text-2); }
.slot-empty .s { font-size: 12.5px; color: var(--muted); }

.slot-grid { flex: 1; display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; align-content: start; padding: 8px 0; overflow-y: auto; max-height: 210px; }
.slot-mini { background: var(--bg-2); border: 1px solid var(--line); border-top: 2px solid var(--rc, #cbd2dc); border-radius: 9px; padding: 8px 6px; text-align: center; position: relative; }
.slot-mini img { height: 40px; object-fit: contain; margin-inline: auto; }
.slot-mini .p { font-size: 10.5px; font-weight: 700; color: var(--text); margin-top: 4px; }
.slot-mini .x { position: absolute; top: 3px; right: 4px; font-size: 12px; color: var(--faint); cursor: pointer; }
.slot-mini .x:hover { color: var(--danger); }

.up-wheel-slot { display: flex; flex-direction: column; align-items: center; justify-content: center; }
.up-wheel { position: relative; width: 300px; height: 300px; max-width: 100%; }
.up-wheel svg { width: 100%; height: 100%; display: block; }
.uw-track { stroke: #eceef1; }
.uw-ticks line { stroke: #dfe3e8; }
#uw-arc { transition: stroke-dasharray 0.35s ease; }
.uw-chevbg { fill: #f1f3f6; }
#u-pointer { position: absolute; inset: 0; transform-origin: 50% 50%; transform: rotate(180deg); will-change: transform; }
#u-pointer .arrow { position: absolute; left: 50%; top: 8px; transform: translateX(-50%); width: 0; height: 0; border: 10px solid transparent; border-top: 20px solid var(--ink-btn); }
.uw-center { position: absolute; inset: 0; display: grid; place-items: center; text-align: center; pointer-events: none; }
.uw-center .pct { font-size: 42px; font-weight: 800; letter-spacing: -0.03em; color: var(--text); line-height: 1; }
.uw-center .cap { font-size: 12px; color: var(--muted); margin-top: 6px; }
.up-wheel.win .uw-center .pct { color: var(--green); }
.up-wheel.lose .uw-center .pct { color: var(--danger); }

.up-controls { display: grid; grid-template-columns: 1fr auto 1fr; gap: 18px; align-items: center; margin: 20px 0 8px; }
@media (max-width: 860px) { .up-controls { grid-template-columns: 1fr; text-align: center; } }
.up-balance { display: flex; flex-direction: column; gap: 6px; }
.up-balance label { font-size: 12px; color: var(--muted); }
.up-balance .brow { display: flex; align-items: center; gap: 10px; }
.up-balance input[type=range] { flex: 1; accent-color: var(--accent); }
.up-balance .bv { font-size: 13px; font-weight: 700; }
.up-balance .bm { font-size: 11px; color: var(--faint); }
#u-spin { min-width: 240px; }
.up-mults { display: flex; gap: 7px; justify-content: flex-end; flex-wrap: wrap; }
@media (max-width: 860px) { .up-mults { justify-content: center; } }
.up-mults button { border: 1px solid var(--line-strong); background: #fff; color: var(--muted); font-size: 12.5px; font-weight: 700; border-radius: 9px; padding: 8px 12px; transition: all 0.15s; }
.up-mults button:hover { color: var(--text); background: var(--bg-2); }
.up-mults button.on { color: #fff; background: var(--accent); border-color: var(--accent); }

.up-panels { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-top: 22px; }
@media (max-width: 900px) { .up-panels { grid-template-columns: 1fr; } }
.up-panel { background: #fff; border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 16px; }
.up-panel-head { display: flex; align-items: center; gap: 12px; margin-bottom: 14px; flex-wrap: wrap; }
.up-panel-head h3 { font-size: 15px; font-weight: 700; }
.up-tabs { display: flex; gap: 4px; background: var(--bg-2); border: 1px solid var(--line); border-radius: 10px; padding: 3px; }
.up-tabs .tab { border: 0; background: transparent; color: var(--muted); font-size: 13px; font-weight: 600; padding: 7px 14px; border-radius: 8px; }
.up-tabs .tab.on { color: #fff; background: var(--ink-btn); }
.up-total { font-size: 12.5px; color: var(--muted); }
.up-total b { color: var(--text); font-size: 13.5px; }
.up-panel-head .spacer { margin-left: auto; }
.up-panel select, .up-panel input { background: #fff; border: 1px solid var(--line-strong); color: var(--text); border-radius: 9px; padding: 8px 11px; font-size: 12.5px; font-family: inherit; }
.up-panel select:focus, .up-panel input:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
.up-price-filter { display: flex; align-items: center; gap: 6px; }
.up-price-filter input { width: 88px; }
.up-price-filter span { color: var(--muted); font-size: 12px; }
.up-search { flex: 1; min-width: 120px; }

.up-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(110px, 1fr)); gap: 10px; max-height: 470px; overflow-y: auto; padding-right: 4px; }
.up-grid::-webkit-scrollbar { width: 8px; }
.up-grid::-webkit-scrollbar-thumb { background: #d7dbe0; border-radius: 4px; }

.up-tile {
  position: relative; cursor: pointer; background: #fff; border: 1px solid var(--line); border-bottom: 2px solid var(--rc, #cbd2dc);
  border-radius: 11px; padding: 22px 8px 9px; text-align: center; transition: transform 0.15s, border-color 0.15s, box-shadow 0.15s;
}
.up-tile:hover { transform: translateY(-2px); box-shadow: var(--shadow-sm); }
.up-tile.sel { border-color: var(--accent); box-shadow: 0 0 0 2px var(--accent-soft); }
.up-tile.sel::after { content: "✓"; position: absolute; top: 6px; left: 8px; width: 18px; height: 18px; display: grid; place-items: center; font-size: 11px; font-weight: 800; color: #fff; background: var(--accent); border-radius: 50%; }
.up-tile .tp { position: absolute; top: 6px; right: 8px; font-size: 10.5px; font-weight: 700; color: var(--text); }
.up-tile .tw { position: absolute; top: 8px; left: 8px; font-size: 9px; font-weight: 600; color: var(--faint); letter-spacing: 0.04em; }
.up-tile.sel .tw { left: 30px; }
.up-tile img { height: 46px; object-fit: contain; margin: 2px auto 0; pointer-events: none; }
.up-tile .tn { font-size: 10.5px; font-weight: 600; line-height: 1.2; margin-top: 6px; height: 2.4em; overflow: hidden; }
.up-tile .tsub { font-size: 9.5px; color: var(--muted); }
.up-tile .tch { font-size: 10.5px; font-weight: 700; color: var(--accent); margin-top: 3px; }
.up-tile .tbuy, .up-tile .tsell { margin-top: 7px; width: 100%; border: 1px solid var(--line-strong); background: #fff; color: var(--text); font-size: 10.5px; font-weight: 700; border-radius: 7px; padding: 5px 0; }
.up-tile .tbuy:hover:not([disabled]) { border-color: var(--green); color: var(--green); }
.up-tile .tbuy[disabled] { opacity: 0.4; cursor: not-allowed; }
.up-tile .tsell:hover { border-color: var(--gold); color: var(--gold); }
.up-qty { display: flex; align-items: center; gap: 4px; margin-top: 6px; justify-content: center; }
.up-qty button { width: 22px; height: 22px; border-radius: 6px; border: 1px solid var(--line-strong); background: #fff; color: var(--text); font-size: 13px; font-weight: 700; line-height: 1; }
.up-qty span { font-size: 12px; font-weight: 700; min-width: 20px; }

.up-empty { grid-column: 1/-1; font-size: 13px; color: var(--muted); padding: 26px 6px; text-align: center; }
.up-empty a { color: var(--accent); }

.up-pager { display: flex; align-items: center; justify-content: center; gap: 14px; margin-top: 12px; }
.up-pager button { width: 34px; height: 34px; border-radius: 9px; border: 1px solid var(--line-strong); background: #fff; color: var(--text); font-size: 15px; }
.up-pager button:hover:not([disabled]) { background: var(--bg-2); }
.up-pager button[disabled] { opacity: 0.35; cursor: not-allowed; }
.up-pager .pp { font-size: 12.5px; color: var(--muted); }

.up-result { margin: 14px auto 0; max-width: 520px; border-radius: 12px; padding: 0 16px; font-size: 14px; max-height: 0; overflow: hidden; opacity: 0; transition: all 0.3s; text-align: center; }
.up-result.show { max-height: 140px; opacity: 1; padding: 13px 16px; }
.up-result.win { background: var(--green-soft); border: 1px solid #bbf7d0; color: #15803d; }
.up-result.lose { background: var(--danger-soft); border: 1px solid #fecaca; color: #b91c1c; }
.up-note { font-size: 12px; color: var(--faint); text-align: center; margin-top: 12px; }

.up-confetti { position: absolute; inset: -20% 0 0 0; pointer-events: none; overflow: hidden; z-index: 5; }
.up-confetti i { position: absolute; top: 40%; width: 8px; height: 12px; border-radius: 2px; opacity: 0; animation: upconf 1.4s ease-out forwards; }
@keyframes upconf { 0% { opacity: 1; transform: translate(0, 0) rotate(0deg) scale(1); } 100% { opacity: 0; transform: translate(calc(var(--dx, 0) * 150px), 260px) rotate(540deg) scale(0.4); } }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; }
  html { scroll-behavior: auto; }
}
