/* ═══════════════════════════════════════════════════════════════
   КАЗИНО
   ═══════════════════════════════════════════════════════════════ */

.casino { min-height: 100dvh; display: flex; flex-direction: column; }

/* ── шапка ─────────────────────────────────────────────────── */
.chead {
  position: sticky;
  top: 0;
  z-index: 100;
  height: var(--header-h);
  display: flex;
  align-items: center;
  gap: 20px;
  padding: 0 20px;
  background: rgba(18, 20, 28, .9);
  backdrop-filter: blur(14px);
  box-shadow: inset 0 -1px 0 var(--line);
}

.chead__logo {
  font-family: var(--mono);
  font-weight: 700;
  font-size: 15px;
  letter-spacing: .1em;
  color: var(--accent);
  white-space: nowrap;
}

.chead__nav { display: flex; gap: 4px; margin-left: 8px; }

.ctab {
  padding: 9px 16px;
  font-size: 14px;
  font-weight: 500;
  color: var(--text-dim);
  border-radius: 8px;
  transition: background .15s, color .15s;
  white-space: nowrap;
}

.ctab:hover { color: var(--text); background: var(--bg-3); }
.ctab--active { color: var(--accent); background: rgba(0, 229, 122, .1); }

.chead__spacer { flex: 1; }

.balance {
  display: flex;
  align-items: baseline;
  gap: 8px;
  padding: 9px 18px;
  background: var(--bg-3);
  border-radius: 8px;
  font-family: var(--mono);
}

.balance__label { font-size: 10px; letter-spacing: .16em; color: var(--text-faint); }
.balance__value { font-size: 16px; font-weight: 700; color: var(--accent); transition: color .3s; }
.balance__value.pulse { animation: balancePulse .7s ease; }

@keyframes balancePulse {
  0%   { transform: scale(1) }
  30%  { transform: scale(1.12); color: var(--gold) }
  100% { transform: scale(1) }
}

/* ── лента выигрышей ───────────────────────────────────────── */
.feed {
  display: flex;
  gap: 8px;
  padding: 8px 20px;
  background: var(--bg-2);
  box-shadow: inset 0 -1px 0 var(--line);
  overflow: hidden;
  min-height: 42px;
  align-items: center;
}

.feed__label {
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: .16em;
  color: var(--text-faint);
  white-space: nowrap;
  padding-right: 8px;
}

.feed__item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 5px 12px;
  background: var(--bg-3);
  border-radius: 20px;
  font-size: 12px;
  white-space: nowrap;
  animation: feedIn .4s ease both;
}

@keyframes feedIn { from { opacity: 0; transform: translateX(-16px) } to { opacity: 1; transform: none } }

.feed__name { color: var(--text-dim); }
.feed__win  { font-family: var(--mono); font-weight: 600; color: var(--accent); }

/* ── тело ──────────────────────────────────────────────────── */
.cbody { flex: 1; padding: 28px 20px 80px; max-width: 1180px; width: 100%; margin: 0 auto; }

.section-title {
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: .22em;
  color: var(--text-faint);
  margin-bottom: 18px;
}

/* ═══════════════════════════════════════════════════════════════
   РУЛЕТКА
   ═══════════════════════════════════════════════════════════════ */

.roul__strip {
  position: relative;
  height: 110px;
  background: var(--bg-2);
  border-radius: 14px;
  overflow: hidden;
  box-shadow: inset 0 0 60px rgba(0,0,0,.6);
}

.roul__track {
  display: flex;
  height: 100%;
  align-items: center;
  gap: 6px;
  padding-left: 0;
  will-change: transform;
}

.roul__cell {
  flex: 0 0 84px;
  height: 84px;
  border-radius: 10px;
  display: grid;
  place-items: center;
  font-family: var(--mono);
  font-size: 22px;
  font-weight: 700;
  color: rgba(255,255,255,.85);
}

.roul__cell--red   { background: linear-gradient(160deg, #e0364a, #9c1e2d) }
.roul__cell--black { background: linear-gradient(160deg, #2a2f3f, #14171f) }
.roul__cell--green { background: linear-gradient(160deg, #00e57a, #007a41); color: #04150c }

.roul__marker {
  position: absolute;
  left: 50%;
  top: 0;
  bottom: 0;
  width: 3px;
  margin-left: -1.5px;
  background: var(--gold);
  box-shadow: 0 0 18px var(--gold);
  z-index: 5;
}

.roul__marker::before, .roul__marker::after {
  content: '';
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  border-left: 7px solid transparent;
  border-right: 7px solid transparent;
}

.roul__marker::before { top: 0; border-top: 9px solid var(--gold) }
.roul__marker::after  { bottom: 0; border-bottom: 9px solid var(--gold) }

.roul__fade {
  position: absolute;
  top: 0; bottom: 0;
  width: 90px;
  z-index: 4;
  pointer-events: none;
}
.roul__fade--l { left: 0;  background: linear-gradient(90deg, var(--bg-2), transparent) }
.roul__fade--r { right: 0; background: linear-gradient(270deg, var(--bg-2), transparent) }

/* ставки */
.roul__controls { margin-top: 22px; display: flex; flex-direction: column; gap: 16px; }

.bet-amount { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }

.bet-amount input {
  width: 150px;
  padding: 13px 16px;
  background: var(--bg-2);
  border: 1px solid var(--line);
  border-radius: 10px;
  color: var(--text);
  font-family: var(--mono);
  font-size: 15px;
  outline: none;
}

.bet-amount input:focus { border-color: var(--accent-dim) }

.chip {
  padding: 11px 15px;
  background: var(--bg-2);
  border-radius: 8px;
  font-family: var(--mono);
  font-size: 13px;
  color: var(--text-dim);
  transition: background .15s, color .15s;
}

.chip:hover { background: var(--bg-3); color: var(--text) }

.bet-colors { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 12px; }

.bet-btn {
  padding: 20px 12px;
  border-radius: 12px;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 16px;
  letter-spacing: .05em;
  color: #fff;
  transition: transform .12s, filter .2s;
  position: relative;
  overflow: hidden;
}

.bet-btn:hover:not(:disabled) { filter: brightness(1.15) }
.bet-btn:active:not(:disabled) { transform: scale(.98) }
.bet-btn:disabled { opacity: .45; cursor: not-allowed }

.bet-btn small { display: block; margin-top: 4px; font-size: 11px; opacity: .75; font-weight: 500 }

.bet-btn--red   { background: linear-gradient(160deg, #e0364a, #9c1e2d) }
.bet-btn--black { background: linear-gradient(160deg, #2a2f3f, #14171f) }
.bet-btn--green { background: linear-gradient(160deg, #00e57a, #007a41); color: #04150c }

.roul__result {
  margin-top: 20px;
  text-align: center;
  font-family: var(--mono);
  font-size: 20px;
  min-height: 30px;
  font-weight: 700;
}

/* ═══════════════════════════════════════════════════════════════
   КЕЙСЫ
   ═══════════════════════════════════════════════════════════════ */

.cases-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 16px;
}

.case-card {
  background: var(--panel);
  border-radius: 14px;
  padding: 20px;
  text-align: center;
  transition: transform .18s, background .18s;
  box-shadow: inset 0 0 0 1px var(--line);
}

.case-card:hover { transform: translateY(-4px); background: var(--bg-3) }

.case-card__img {
  width: 100%;
  aspect-ratio: 4/3;
  object-fit: contain;
  margin-bottom: 14px;
  filter: drop-shadow(0 12px 24px rgba(0,0,0,.5));
}

.case-card__name { font-family: var(--font-display); font-weight: 700; font-size: 17px }
.case-card__sub { margin-top: 4px; font-size: 12px; color: var(--text-faint); font-style: italic }
.case-card__price { margin-top: 10px; font-family: var(--mono); color: var(--accent); font-weight: 700 }

.drop__playing {
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: .18em;
  color: var(--accent);
  animation: playingPulse 1.8s ease-in-out infinite;
}

@keyframes playingPulse { 0%, 100% { opacity: .5 } 50% { opacity: 1 } }

/* супер-кейс */
.supercase {
  position: relative;
  margin-bottom: 28px;
  padding: 32px;
  border-radius: 18px;
  background:
    radial-gradient(ellipse at 20% 0%, rgba(255, 194, 61, .16), transparent 60%),
    linear-gradient(135deg, #1c1a12, #151824);
  box-shadow: inset 0 0 0 1px rgba(255, 194, 61, .3);
  display: flex;
  gap: 28px;
  align-items: center;
  overflow: hidden;
}

.supercase::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(105deg, transparent 35%, rgba(255,255,255,.07) 50%, transparent 65%);
  transform: translateX(-100%);
  animation: sheen 4.5s ease-in-out infinite;
  pointer-events: none;
}

@keyframes sheen { 0%, 65% { transform: translateX(-100%) } 100% { transform: translateX(100%) } }

.supercase__img { width: 170px; flex-shrink: 0; filter: drop-shadow(0 16px 32px rgba(0,0,0,.6)) }
.supercase__info { flex: 1; min-width: 0 }
.supercase__name { font-family: var(--font-display); font-size: 28px; font-weight: 700; color: var(--gold); letter-spacing: .01em }
.supercase__tag { margin-top: 8px; color: var(--text-dim); font-size: 15px }

.supercase__progress {
  margin-top: 18px;
  height: 8px;
  background: rgba(0,0,0,.4);
  border-radius: 4px;
  overflow: hidden;
}

/* Полоса всегда во всю ширину, наполнение делаем через clip-path:
   не дёргает раскладку и, в отличие от scaleX, не сжимает градиент —
   золото проступает только когда он реально близок к цели. */
.supercase__bar {
  height: 100%;
  background: linear-gradient(90deg, var(--accent), var(--gold));
  border-radius: 4px;
  clip-path: inset(0 100% 0 0);
  transition: clip-path .8s cubic-bezier(.22, 1, .36, 1);
}

.supercase__meta {
  margin-top: 10px;
  font-family: var(--mono);
  font-size: 13px;
  color: var(--text-dim);
}

.supercase__btn {
  margin-top: 18px;
  padding: 16px 36px;
  border-radius: 10px;
  font-family: var(--font-display);
  font-weight: 700;
  letter-spacing: .07em;
  background: var(--gold);
  color: #1a1400;
  transition: filter .2s, transform .12s;
}

.supercase__btn:hover:not(:disabled) { filter: brightness(1.1) }
.supercase__btn:active:not(:disabled) { transform: scale(.98) }
.supercase__btn:disabled { background: var(--bg-3); color: var(--text-faint); cursor: not-allowed }

/* ── витрина кейса ─────────────────────────────────────────── */

.back-link {
  display: inline-block;
  margin-bottom: 18px;
  padding: 8px 14px;
  border-radius: 8px;
  font-size: 13px;
  color: var(--text-dim);
  background: var(--bg-2);
  transition: color .15s, background .15s;
}

.back-link:hover { color: var(--text); background: var(--bg-3) }

.case-open {
  display: flex;
  gap: 30px;
  align-items: center;
  padding: 28px;
  border-radius: 18px;
  background: radial-gradient(ellipse at 18% 0%, rgba(0, 229, 122, .09), transparent 62%), var(--panel);
  box-shadow: inset 0 0 0 1px var(--line);
}

.case-open__img {
  width: 230px;
  aspect-ratio: 1;
  object-fit: cover;
  border-radius: 14px;
  flex-shrink: 0;
  filter: drop-shadow(0 16px 34px rgba(0,0,0,.55));
}

.case-open__info { flex: 1; min-width: 0 }
.case-open__name { font-family: var(--font-display); font-size: 30px; font-weight: 700 }
.case-open__sub { margin-top: 6px; color: var(--text-faint); font-size: 15px; font-style: italic }

.case-open__btns { margin-top: 22px; display: flex; gap: 10px; flex-wrap: wrap }

.case-open__btn {
  display: flex;
  flex-direction: column;
  gap: 3px;
  padding: 13px 22px;
  background: var(--bg-3);
  color: var(--text);
}

.case-open__btn small { font-family: var(--mono); font-size: 11px; opacity: .6; font-weight: 500 }
.case-open__btn--main { background: var(--accent); color: #000 }
.case-open__btn--main small { opacity: .7 }

/* содержимое кейса */
.content-grid { grid-template-columns: repeat(auto-fill, minmax(148px, 1fr)) }
.content-cell { position: relative }

.content-cell__odd {
  position: absolute;
  top: 7px;
  left: 7px;
  padding: 3px 8px;
  border-radius: 20px;
  background: rgba(10, 11, 15, .82);
  backdrop-filter: blur(6px);
  font-family: var(--mono);
  font-size: 11px;
  font-weight: 600;
  color: var(--text-dim);
  z-index: 2;
}

/* ── открытие кейса (оверлей) ──────────────────────────────── */

.reel-stack { display: flex; flex-direction: column; gap: 10px; width: min(940px, 100%) }
.reel-stack--multi .reel-wrap { height: 116px }
.reel-stack--multi .reel__cell { flex: 0 0 96px; height: 96px }
.opening {
  position: fixed;
  inset: 0;
  z-index: 500;
  background: rgba(6, 7, 10, .96);
  backdrop-filter: blur(10px);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 30px;
  padding: 20px;
  animation: fadeIn .3s ease both;
}

.reel-wrap {
  position: relative;
  width: min(940px, 100%);
  height: 190px;
  background: var(--bg-2);
  border-radius: 14px;
  overflow: hidden;
  box-shadow: inset 0 0 70px rgba(0,0,0,.7);
}

.reel {
  display: flex;
  height: 100%;
  align-items: center;
  gap: 10px;
  will-change: transform;
}

.reel__cell { flex: 0 0 150px; height: 150px }
.reel__cell .item { height: 100% }
.reel__cell .item__img { height: 100%; aspect-ratio: auto; object-fit: contain; padding: 10px }

.reel__marker {
  position: absolute;
  left: 50%; top: 0; bottom: 0;
  width: 3px; margin-left: -1.5px;
  background: var(--gold);
  box-shadow: 0 0 20px var(--gold);
  z-index: 5;
}

/* результат */
.drop {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
  animation: dropIn .5s cubic-bezier(.22, 1, .36, 1) both;
}

@keyframes dropIn { from { opacity: 0; transform: translateY(24px) scale(.94) } to { opacity: 1; transform: none } }

.drop__label { font-family: var(--mono); font-size: 12px; letter-spacing: .22em; color: var(--text-faint) }
.drop__card { width: 210px }
.drop__actions { display: flex; gap: 12px; margin-top: 6px; flex-wrap: wrap; justify-content: center }

/* При открытии нескольких кейсов дроп раньше не влезал на экран.
   Теперь карточки ужимаются, а если всё равно не помещаются —
   область скроллится внутри себя, а не растягивает страницу. */
.drop__cards {
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: wrap;
  max-width: min(940px, 94vw);
  max-height: 54vh;
  overflow-y: auto;
  padding: 2px;
}

.drop__cards--multi .drop__card { width: clamp(96px, 15vw, 138px) }
.drop__cards--multi .item__body { padding: 7px }
.drop__cards--multi .item__name { font-size: 11px }
.drop__cards--multi .item__price { font-size: 12px }

/* сам оверлей тоже не должен упираться в края */
.opening { gap: 22px; padding: 16px }
.drop { max-height: 92dvh }

@media (max-width: 640px) {
  .drop__cards { max-height: 46vh }
  .drop__cards--multi .drop__card { width: 92px }
  .drop__cards--multi .item__name { font-size: 10px }
}

/* ═══════════════════════════════════════════════════════════════
   ФИНАЛЬНЫЙ СБОЙ
   ═══════════════════════════════════════════════════════════════
   Он выиграл нож — и через пару секунд казино его «теряет».
   ═══════════════════════════════════════════════════════════════ */

.fx { position: relative }
.fx__holder { position: relative; display: grid; place-items: center; min-height: 300px }

.fx--breaking { animation: fxShake .16s infinite }

@keyframes fxShake {
  0%   { transform: translate(0,0) }
  25%  { transform: translate(-3px, 2px) }
  50%  { transform: translate(3px,-2px) }
  75%  { transform: translate(-2px,-3px) }
  100% { transform: translate(2px, 3px) }
}

.fx--breaking .drop__card {
  animation: fxGlitch .3s steps(2) infinite;
  filter: hue-rotate(80deg) saturate(2.2) contrast(1.3);
}

@keyframes fxGlitch {
  0%   { transform: translateX(0) skewX(0) }
  30%  { transform: translateX(-7px) skewX(-7deg) }
  60%  { transform: translateX(6px) skewX(5deg) }
  100% { transform: translateX(0) skewX(0) }
}

.fx__lines {
  position: absolute;
  left: 50%;
  bottom: -8px;
  transform: translateX(-50%);
  width: max-content;
  max-width: 92vw;
  display: flex;
  flex-direction: column;
  gap: 5px;
  align-items: center;
  font-family: var(--mono);
  pointer-events: none;
}

.fx__line {
  font-size: 12.5px;
  letter-spacing: .08em;
  color: var(--danger);
  text-shadow: 1.5px 0 var(--accent), -1.5px 0 #00d4ff;
  animation: vLineIn .2s steps(3) both;
}

.fx__label--error { color: var(--danger) !important; animation: fxGlitch .4s steps(2) infinite }

.fx__card--dying { animation: fxDie .6s cubic-bezier(.5,0,.75,0) forwards }

@keyframes fxDie {
  0%   { opacity: 1; transform: none; filter: none }
  40%  { opacity: 1; transform: scaleY(1.08); filter: invert(1) hue-rotate(120deg) }
  100% { opacity: 0; transform: scaleY(.03) skewX(30deg); filter: blur(9px) }
}

.fx__card--arriving { animation: fxArrive .75s cubic-bezier(.22, 1, .36, 1) both }

@keyframes fxArrive {
  0%   { opacity: 0; transform: scaleY(.05) skewX(-24deg); filter: blur(10px) invert(1) }
  55%  { opacity: 1; filter: blur(0) invert(0) }
  100% { opacity: 1; transform: none; filter: none }
}

.btn-ghost {
  padding: 14px 26px;
  border-radius: 10px;
  font-size: 14px;
  font-weight: 600;
  color: var(--text-dim);
  background: var(--bg-3);
  transition: color .15s, background .15s;
}

.btn-ghost:hover { color: var(--text); background: var(--line) }

/* ═══════════════════════════════════════════════════════════════
   АПГРЕЙД
   ═══════════════════════════════════════════════════════════════ */

.upgrade { display: grid; grid-template-columns: 1fr auto 1fr; gap: 26px; align-items: center }

.upg-slot {
  background: var(--panel);
  border-radius: 14px;
  padding: 22px;
  min-height: 330px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 14px;
  box-shadow: inset 0 0 0 1px var(--line);
}

.upg-slot__label { font-family: var(--mono); font-size: 11px; letter-spacing: .2em; color: var(--text-faint) }
.upg-slot__empty { color: var(--text-faint); font-size: 14px; text-align: center }
.upg-slot .item { width: 180px }

/* колесо шанса */
.upg-wheel { position: relative; width: 210px; height: 210px }
.upg-wheel svg { width: 100%; height: 100%; transform: rotate(-90deg) }
.upg-wheel__track { fill: none; stroke: var(--bg-3); stroke-width: 14 }
.upg-wheel__arc   { fill: none; stroke: var(--accent); stroke-width: 14; stroke-linecap: round;
  transition: stroke-dasharray .4s ease }

.upg-wheel__needle {
  position: absolute;
  inset: 0;
  will-change: transform;
}

/* Стрелка, а не полоска: треугольное остриё внутрь круга
   плюс тонкое древко под ним. */
.upg-wheel__needle::before {
  content: '';
  position: absolute;
  left: 50%;
  top: 1px;
  width: 0;
  height: 0;
  margin-left: -9px;
  border-left: 9px solid transparent;
  border-right: 9px solid transparent;
  border-top: 20px solid var(--gold);
  filter: drop-shadow(0 0 8px var(--gold));
}

.upg-wheel__needle::after {
  content: '';
  position: absolute;
  left: 50%;
  top: 19px;
  width: 3px;
  height: 16px;
  margin-left: -1.5px;
  background: var(--gold);
  border-radius: 0 0 2px 2px;
  box-shadow: 0 0 10px var(--gold);
}

.upg-wheel__value {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  font-family: var(--mono);
  font-size: 26px;
  font-weight: 700;
  pointer-events: none;
}

.upg-wheel__value small { display: block; font-size: 11px; letter-spacing: .18em; color: var(--text-faint); font-weight: 500 }

.upg-actions { margin-top: 26px; display: flex; justify-content: center }

/* Две полосы рядом: слева что есть, справа во что меняем.
   Раньше они лежали друг под другом и путались между собой. */
.upg-picker {
  margin-top: 38px;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 20px;
  align-items: start;
}

.upg-picker__col { min-width: 0 }

.upg-picker__title {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: .2em;
  color: var(--text-faint);
  margin-bottom: 14px;
  padding-bottom: 10px;
  box-shadow: inset 0 -1px 0 var(--line);
}

.upg-picker__arrow {
  align-self: center;
  font-size: 26px;
  color: var(--text-faint);
  padding: 0 4px;
}

.upg-picker .inv-grid { grid-template-columns: repeat(auto-fill, minmax(118px, 1fr)); gap: 10px }
.upg-picker .inv-empty { padding: 34px 14px; font-size: 13px }

@media (max-width: 860px) {
  .upg-picker { grid-template-columns: 1fr; gap: 14px }
  .upg-picker__arrow { transform: rotate(90deg); justify-self: center; padding: 4px 0 }
}

/* трек в инвентаре — кликается и играет */
.item--playable { cursor: pointer }
.item--playable:hover .item__title { filter: brightness(1.25) }

.item--playing { box-shadow: 0 0 0 2px var(--accent), 0 0 26px rgba(0, 229, 122, .35) }
.item--playing .item__note {
  color: var(--accent);
  animation: playingPulse 1.2s ease-in-out infinite;
}

/* ═══════════════════════════════════════════════════════════════
   UNO-АПГРЕЙДЕР
   ═══════════════════════════════════════════════════════════════
   Тот же каркас, что у апгрейда, но красный вместо зелёного и
   стрелка крутится в обратную сторону. Режим должен ощущаться
   неправильным ещё до того, как он прочитает, что тут происходит.
   ═══════════════════════════════════════════════════════════════ */

.uno-head { text-align: center; margin-bottom: 26px }

.uno-head__title {
  font-family: var(--font-display);
  font-size: 30px;
  font-weight: 700;
  color: var(--danger);
  letter-spacing: .03em;
  text-shadow: 0 0 40px rgba(255, 59, 87, .35);
}

.uno-head__tag { margin-top: 6px; color: var(--text-dim); font-size: 15px }

.uno-head__warn {
  margin-top: 12px;
  display: inline-block;
  padding: 7px 16px;
  border-radius: 20px;
  background: rgba(255, 59, 87, .1);
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: .1em;
  color: var(--danger);
}

/* стрелка и дуга — красные */
.uno-wheel .upg-wheel__arc { stroke: var(--danger) }
.uno-wheel .upg-wheel__needle::before {
  border-top-color: var(--danger);
  filter: drop-shadow(0 0 8px var(--danger));
}
.uno-wheel .upg-wheel__needle::after {
  background: var(--danger);
  box-shadow: 0 0 10px var(--danger);
}
.uno-wheel .upg-wheel__value { color: var(--danger) }

.uno-slot .item { width: 180px }

.uno-delta {
  margin-top: 10px;
  font-family: var(--mono);
  font-size: 17px;
  font-weight: 700;
  color: var(--danger);
}

/* ползунок шанса */
.uno-slider-wrap { margin-top: 24px; display: flex; justify-content: center }

.uno-slider {
  -webkit-appearance: none;
  appearance: none;
  width: min(460px, 100%);
  height: 6px;
  border-radius: 3px;
  background: linear-gradient(90deg, var(--bg-3), var(--danger));
  outline: none;
}

.uno-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: var(--danger);
  cursor: grab;
  box-shadow: 0 0 18px rgba(255, 59, 87, .5);
}

.uno-slider::-moz-range-thumb {
  width: 26px;
  height: 26px;
  border: none;
  border-radius: 50%;
  background: var(--danger);
  cursor: grab;
  box-shadow: 0 0 18px rgba(255, 59, 87, .5);
}

.btn-danger {
  padding: 16px 40px;
  border-radius: 10px;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 15px;
  letter-spacing: .07em;
  background: var(--danger);
  color: #fff;
  transition: filter .2s, transform .12s;
}

.btn-danger:hover { filter: brightness(1.12) }
.btn-danger:active { transform: scale(.98) }

/* заблокированные вещи */
.inv-cell--locked { cursor: not-allowed }
.inv-cell--locked .item { opacity: .32; filter: grayscale(.85) }
.inv-cell--locked:hover { transform: none }

.inv-cell__lock {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  font-size: 26px;
  pointer-events: none;
}

/* ═══════════════════════════════════════════════════════════════
   ИНВЕНТАРЬ
   ═══════════════════════════════════════════════════════════════ */

.inv-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 18px;
  flex-wrap: wrap;
}

.inv-cell__sell { width: 100%; margin-top: 6px; padding: 9px; font-size: 12px }

.inv-cell__keep {
  margin-top: 6px;
  padding: 9px;
  text-align: center;
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: .08em;
  color: var(--gold);
  opacity: .7;
}

.inv-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 14px }
.inv-cell { position: relative; cursor: pointer; transition: transform .15s }
.inv-cell:hover { transform: translateY(-3px) }
.inv-cell--selected { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 10px }

.inv-empty { padding: 60px 20px; text-align: center; color: var(--text-faint) }

/* ═══════════════════════════════════════════════════════════════
   САППОРТ-ЧАТ
   ═══════════════════════════════════════════════════════════════ */

.support-btn {
  position: fixed;
  right: 22px;
  bottom: 22px;
  width: 54px;
  height: 54px;
  border-radius: 50%;
  background: var(--accent);
  color: #000;
  display: grid;
  place-items: center;
  font-size: 22px;
  z-index: 300;
  box-shadow: 0 10px 30px rgba(0, 229, 122, .3);
  transition: transform .15s;
}

.support-btn:hover { transform: scale(1.06) }

.support-panel {
  position: fixed;
  right: 22px;
  bottom: 88px;
  width: min(330px, calc(100vw - 44px));
  height: 400px;
  background: var(--panel);
  border-radius: 14px;
  z-index: 300;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  box-shadow: 0 24px 60px rgba(0,0,0,.6), inset 0 0 0 1px var(--line);
  animation: dropIn .3s cubic-bezier(.22, 1, .36, 1) both;
}

.support-panel__head {
  padding: 14px 16px;
  font-size: 14px;
  font-weight: 600;
  background: var(--bg-3);
}

.support-panel__head span { display: block; font-size: 11px; color: var(--accent); font-weight: 500; margin-top: 2px }

.support-panel__body { flex: 1; overflow-y: auto; padding: 14px; display: flex; flex-direction: column; gap: 10px }

.msg { max-width: 82%; padding: 10px 13px; border-radius: 12px; font-size: 13.5px; line-height: 1.4 }
.msg--them { background: var(--bg-3); align-self: flex-start; border-bottom-left-radius: 4px }
.msg--me   { background: var(--accent-dim); color: #04150c; align-self: flex-end; border-bottom-right-radius: 4px }

/* «оператор печатает» */
.msg--typing { display: flex; gap: 4px; align-items: center; padding: 13px }
.msg--typing i {
  width: 6px; height: 6px; border-radius: 50%;
  background: var(--text-faint);
  animation: typingDot 1.2s ease-in-out infinite;
}
.msg--typing i:nth-child(2) { animation-delay: .18s }
.msg--typing i:nth-child(3) { animation-delay: .36s }

@keyframes typingDot {
  0%, 60%, 100% { opacity: .3; transform: translateY(0) }
  30%           { opacity: 1;  transform: translateY(-3px) }
}

/* бан на весь чат */
.support-panel--banned .support-panel__head span { color: var(--danger) }

.support-ban {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  height: 100%;
  animation: fadeIn .4s ease both;
}

.support-ban__word {
  font-family: var(--font-display);
  font-size: 62px;
  font-weight: 700;
  letter-spacing: .1em;
  color: var(--danger);
  text-shadow: 0 0 40px rgba(255, 59, 87, .5), 3px 0 #00d4ff, -3px 0 var(--accent);
  animation: vGlitch .45s steps(2) infinite;
}

.support-ban__hint {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: .18em;
  color: var(--text-faint);
}

.support-panel__foot { display: flex; padding: 10px; gap: 8px; box-shadow: inset 0 1px 0 var(--line) }
.support-panel__foot input {
  flex: 1; padding: 10px 12px; background: var(--bg-2); border: 1px solid var(--line);
  border-radius: 8px; color: var(--text); font-size: 13px; outline: none;
}

/* ═══════════════════════════════════════════════════════════════
   МОДАЛКИ
   ═══════════════════════════════════════════════════════════════ */

.modal-back {
  position: fixed;
  inset: 0;
  z-index: 600;
  background: rgba(6,7,10,.88);
  backdrop-filter: blur(8px);
  display: grid;
  place-items: center;
  padding: 20px;
  animation: fadeIn .3s ease both;
}

.modal {
  width: min(460px, 100%);
  background: var(--panel);
  border-radius: 16px;
  padding: 32px;
  text-align: center;
  box-shadow: 0 30px 80px rgba(0,0,0,.6), inset 0 0 0 1px var(--line);
  animation: dropIn .4s cubic-bezier(.22, 1, .36, 1) both;
}

.modal__title { font-family: var(--mono); font-size: 13px; letter-spacing: .22em; color: var(--accent) }
.modal__text { margin-top: 14px; color: var(--text-dim); font-size: 15px; line-height: 1.5 }

.modal input {
  width: 100%;
  margin-top: 22px;
  padding: 15px;
  text-align: center;
  font-family: var(--mono);
  font-size: 19px;
  letter-spacing: .22em;
  text-transform: uppercase;
  background: var(--bg-2);
  border: 1px solid var(--line);
  border-radius: 10px;
  color: var(--text);
  outline: none;
}

.modal input:focus { border-color: var(--accent-dim) }
.modal .btn-primary { margin-top: 18px; width: 100% }
.modal__error { margin-top: 12px; min-height: 18px; font-family: var(--mono); font-size: 13px; color: var(--danger) }

/* ═══════════════════════════════════════════════════════════════
   МОБИЛКА
   ═══════════════════════════════════════════════════════════════ */

@media (max-width: 860px) {
  .chead { gap: 10px; padding: 0 12px; height: auto; min-height: 56px; flex-wrap: wrap; padding-top: 10px; padding-bottom: 10px }
  .chead__logo { font-size: 13px }
  .chead__nav { order: 3; width: 100%; overflow-x: auto; scrollbar-width: none }
  .chead__nav::-webkit-scrollbar { display: none }
  .ctab { padding: 8px 13px; font-size: 13px }
  .balance { padding: 7px 13px }
  .balance__value { font-size: 14px }

  .cbody { padding: 20px 12px 90px }

  .supercase { flex-direction: column; text-align: center; padding: 24px 18px }
  .supercase__img { width: 130px }
  .supercase__name { font-size: 21px }

  .upgrade { grid-template-columns: 1fr; gap: 16px }
  .upg-slot { min-height: 240px }
  .upg-wheel { width: 160px; height: 160px; margin: 0 auto }

  .roul__cell { flex: 0 0 62px; height: 62px; font-size: 17px }
  .roul__strip { height: 86px }

  .reel-wrap { height: 150px }
  .reel__cell { flex: 0 0 110px; height: 110px }
  .reel-stack--multi .reel-wrap { height: 84px }
  .reel-stack--multi .reel__cell { flex: 0 0 68px; height: 68px }

  .case-open { flex-direction: column; text-align: center; padding: 20px }
  .case-open__img { width: 160px }
  .case-open__name { font-size: 23px }
  .case-open__btns { justify-content: center }

  .bet-colors { gap: 8px }
  .bet-btn { padding: 16px 6px; font-size: 13px }
}
