/* Imperial Rush — общий HUD провайдера: Вегас-автомат — чёрный лак, хромированная консоль, LED-табло, красный бархат */
:root { --k: 1;
  --ir-red: #d4142c; --ir-red2: #8a0614; --ir-led: #ff3b30; --ir-amber: #ffb02e; --ir-ink: #0b0b0e; --ir-chrome1: #f4f6f8; --ir-chrome2: #9aa3ad; --ir-chrome3: #4a525c;
  --ir-ui: "Oswald", "Inter", system-ui, sans-serif; --ir-title: "Playfair Display", "Inter", serif; --ir-led-f: "Orbitron", "Inter", monospace;
}
* { box-sizing: border-box; margin: 0; padding: 0; -webkit-tap-highlight-color: transparent; }
html, body { height: 100%; overflow: hidden; }
body { background: #050506; color: #f1f1f3; font-family: var(--ir-ui); user-select: none; -webkit-user-select: none; touch-action: manipulation; }
#bg { position: fixed; inset: 0; width: 100%; height: 100%; z-index: 0; }
.ir-app { position: relative; z-index: 1; height: 100%; display: grid; grid-template-rows: auto minmax(0, 1fr) auto; }
.led { font-family: var(--ir-led-f); font-weight: 700; color: var(--ir-led); text-shadow: 0 0 6px rgba(255,59,48,.85), 0 0 18px rgba(255,59,48,.35); font-variant-numeric: tabular-nums; letter-spacing: 1px; }

/* верх: тонкая чёрная полоса с хромированной кромкой */
.ir-top { display: flex; align-items: center; gap: 12px; padding: max(calc(6px * var(--k)), env(safe-area-inset-top)) max(16px, env(safe-area-inset-right)) calc(6px * var(--k)) max(16px, env(safe-area-inset-left)); min-width: 0; background: linear-gradient(180deg, #0c0c10, rgba(12,12,16,.6)); border-bottom: 1px solid rgba(255,255,255,.08); }
.ir-back { flex: none; height: calc(42px * var(--k)); min-width: 44px; padding: 0 calc(14px * var(--k)); border-radius: 8px; display: inline-flex; align-items: center; justify-content: center; gap: 8px; color: #111; text-decoration: none; font: 800 calc(13px * var(--k)) var(--ir-ui);
  background: linear-gradient(180deg, var(--ir-chrome1), var(--ir-chrome2) 55%, #c9d0d7); border: 1px solid #2a2e34; box-shadow: inset 0 1px 0 #fff, 0 3px 0 #23272c, 0 6px 12px rgba(0,0,0,.5); }
.ir-title { flex: 1; min-width: 0; text-align: center; padding: 0 6px; }
.ir-title b { display: block; font: 900 clamp(22px, 3vw, 42px)/1 var(--ir-title); letter-spacing: 2px; text-transform: uppercase; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
  background: linear-gradient(180deg, #ffffff 0%, #e6e9ec 40%, #8e969e 52%, #f1f3f5 70%, #b9c0c7 100%); -webkit-background-clip: text; background-clip: text; color: transparent; filter: drop-shadow(0 2px 0 #3a0006) drop-shadow(0 0 14px rgba(212,20,44,.45)); }
.ir-title small { display: inline-flex; align-items: center; gap: 7px; margin-top: 5px; font: 700 10.5px var(--ir-ui); letter-spacing: 4px; color: #e7c8cc; }
.ir-title small i { color: var(--ir-red); }
.ir-bal { flex: none; display: flex; align-items: center; height: calc(44px * var(--k)); border-radius: 8px; overflow: hidden; background: #050506; border: 2px solid #3b4148; box-shadow: inset 0 0 12px #000, 0 0 0 1px #000; }
.ir-bal .lbl { font: 800 calc(9.5px * var(--k)) var(--ir-ui); letter-spacing: 2px; color: #8a8f96; padding: 0 8px 0 10px; }
.ir-bal b { font-size: calc(16px * var(--k)); padding-right: 10px; }
.ir-bal button { width: calc(44px * var(--k)); height: 100%; border: 0; border-left: 1px solid #000; background: linear-gradient(180deg, #ff5a68, var(--ir-red) 55%, var(--ir-red2)); color: #fff; font: 900 22px var(--ir-ui); cursor: pointer; }
.ir-login { flex: none; height: calc(44px * var(--k)); padding: 0 calc(16px * var(--k)); border-radius: 8px; border: 1px solid #1b6fa0; cursor: pointer; display: inline-flex; align-items: center; gap: 8px;
  background: linear-gradient(180deg, #59c6ff, #1d8fd6); color: #fff; font: 900 calc(13px * var(--k)) var(--ir-ui); box-shadow: inset 0 1px 0 rgba(255,255,255,.5), 0 3px 0 #0d4f78; }

/* сцена */
.ir-main { position: relative; display: flex; align-items: center; justify-content: center; min-height: 0; padding: 4px max(16px, env(safe-area-inset-right)) 4px max(16px, env(safe-area-inset-left)); }
.ir-stage { position: relative; height: 100%; width: 100%; max-width: 2200px; }
.ir-stage canvas { position: absolute; inset: 0; width: 100%; height: 100%; }
.ir-badges { position: absolute; left: max(16px, env(safe-area-inset-left)); top: 50%; transform: translateY(-50%); z-index: 3; display: flex; flex-direction: column; gap: calc(10px * var(--k)); width: calc(150px * min(var(--k), 1.2)); }
.ir-badge { padding: 9px 10px; border-radius: 10px; background: #050506; border: 2px solid #3b4148; box-shadow: inset 0 0 14px #000, 0 6px 14px rgba(0,0,0,.6); text-align: center; }
.ir-badge small { display: block; font: 800 calc(9.5px * var(--k)) var(--ir-ui); letter-spacing: .8px; white-space: nowrap; color: #8a8f96; text-transform: uppercase; }
.ir-badge b { display: block; font-size: calc(24px * var(--k)); line-height: 1.15; }
.ir-badge.hot b { color: var(--ir-amber); text-shadow: 0 0 8px rgba(255,176,46,.9); }
.ir-buy { width: 100%; padding: 10px 8px; border-radius: 10px; cursor: pointer; border: 1px solid #2a0008; color: #fff;
  background: linear-gradient(180deg, #ff5a68, var(--ir-red) 45%, var(--ir-red2)); box-shadow: inset 0 1px 0 rgba(255,255,255,.45), 0 4px 0 #3a0006, 0 10px 20px rgba(212,20,44,.35); }
.ir-buy span { display: block; font: 900 calc(11px * var(--k)) var(--ir-ui); letter-spacing: 1px; }
.ir-buy b { display: block; font: 700 calc(20px * var(--k)) var(--ir-led-f); margin-top: 2px; }
.ir-buy:disabled { filter: grayscale(.7); opacity: .55; }

/* нижняя хромированная консоль */
.ir-deck { position: relative; z-index: 4; display: flex; align-items: center; gap: calc(12px * var(--k)); padding: calc(10px * var(--k)) max(18px, env(safe-area-inset-right)) calc(10px * var(--k) + env(safe-area-inset-bottom)) max(18px, env(safe-area-inset-left));
  background: linear-gradient(180deg, #e9edf1 0%, #b4bcc5 18%, #79828c 50%, #aeb6bf 82%, #5c646e 100%); border-top: 2px solid #fff; box-shadow: 0 -8px 26px rgba(0,0,0,.7), inset 0 -2px 0 rgba(0,0,0,.4); }
.ir-deck::before { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 4px; background: linear-gradient(90deg, var(--ir-red2), var(--ir-red), #ff6a78, var(--ir-red), var(--ir-red2)); }
.ir-keys { display: flex; gap: calc(8px * var(--k)); flex: none; }
.ir-key { position: relative; flex: none; min-width: calc(54px * var(--k)); height: calc(54px * var(--k)); padding: 0 calc(10px * var(--k)); border-radius: 9px; cursor: pointer; display: inline-flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px;
  border: 1px solid #1c2026; color: #1a1d22; font-size: calc(18px * var(--k)); background: linear-gradient(180deg, #ffffff, #d5dbe1 45%, #a7b0ba 55%, #e3e7eb); box-shadow: inset 0 1px 0 #fff, 0 4px 0 #2a2f36, 0 7px 12px rgba(0,0,0,.45); }
.ir-key em { font: 800 calc(9px * var(--k)) var(--ir-ui); font-style: normal; letter-spacing: .5px; }
.ir-key.sm { min-width: calc(48px * var(--k)); height: calc(48px * var(--k)); font-size: calc(16px * var(--k)); }
.ir-key svg { width: 1em; height: 1em; }
.ir-key:active, .ir-key.on { transform: translateY(3px); box-shadow: inset 0 1px 0 #fff, 0 1px 0 #2a2f36, 0 3px 6px rgba(0,0,0,.45); }
.ir-key.on { background: linear-gradient(180deg, #fff1c4, #ffc947 50%, #e0a21c); }
.ir-key:disabled { opacity: .45; }
.ir-led { flex: none; min-width: calc(140px * var(--k)); padding: calc(5px * var(--k)) 12px calc(6px * var(--k)); border-radius: 8px; background: #050506; border: 2px solid #2d3238; box-shadow: inset 0 0 16px #000, 0 1px 0 rgba(255,255,255,.6); text-align: center; }
.ir-led small { display: block; font: 800 calc(9.5px * var(--k)) var(--ir-ui); letter-spacing: 1.5px; color: #8b9098; }
.ir-led b { display: block; font-size: calc(22px * var(--k)); line-height: 1.15; }
.ir-led.win b { color: var(--ir-amber); text-shadow: 0 0 8px rgba(255,176,46,.9); }
.ir-betgrp { display: flex; align-items: center; gap: calc(8px * var(--k)); flex: none; margin-left: auto; }
.ir-spin { flex: none; position: relative; width: calc(92px * var(--k)); height: calc(92px * var(--k)); margin: calc(-38px * var(--k)) 0 0 4px; border-radius: 50%; cursor: pointer; border: 6px solid #c9d0d7;
  background: radial-gradient(circle at 50% 35%, #ff8a94 0%, var(--ir-red) 45%, var(--ir-red2) 100%); box-shadow: 0 0 0 3px #2a2f36, 0 8px 0 #3a0006, 0 14px 30px rgba(212,20,44,.55), inset 0 -6px 12px rgba(0,0,0,.35), inset 0 6px 10px rgba(255,255,255,.35); color: #fff; }
.ir-spin span { font: 900 calc(15px * var(--k)) var(--ir-ui); letter-spacing: .5px; text-shadow: 0 2px 0 #3a0006; }
.ir-spin:active { transform: translateY(4px); box-shadow: 0 0 0 3px #2a2f36, 0 3px 0 #3a0006, 0 8px 18px rgba(212,20,44,.45), inset 0 -6px 12px rgba(0,0,0,.35); }
.ir-spin.busy { animation: irpulse .9s ease-in-out infinite; }
.ir-spin.fast span::after { content: " »"; }
.ir-spin.auto span { font-size: 0; }
.ir-spin.auto::after { content: attr(data-n); position: absolute; inset: 0; display: grid; place-items: center; font: 900 30px var(--ir-led-f); color: #fff; }
@keyframes irpulse { 50% { box-shadow: 0 0 0 3px #2a2f36, 0 8px 0 #3a0006, 0 0 44px rgba(255,59,48,.9), inset 0 -6px 12px rgba(0,0,0,.35); } }

/* повтор */
.ir-replay { display: none; position: fixed; left: 50%; top: 64px; transform: translateX(-50%); z-index: 6; padding: 8px 16px; border-radius: 8px; background: #050506; border: 2px solid var(--ir-red); color: #fff; font: 800 13px var(--ir-ui); }

/* оверлеи */
.ir-ov { position: fixed; inset: 0; z-index: 30; display: none; align-items: center; justify-content: center; padding: max(16px, env(safe-area-inset-top)) max(16px, env(safe-area-inset-right)) max(16px, env(safe-area-inset-bottom)) max(16px, env(safe-area-inset-left)); background: rgba(0,0,0,.78); backdrop-filter: blur(4px); -webkit-backdrop-filter: blur(4px); }
.ir-ov.show { display: flex; }
.ir-card { position: relative; width: min(440px, 100%); max-height: 92vh; overflow: auto; padding: 26px 22px; border-radius: 14px; text-align: center;
  background: linear-gradient(180deg, #17171c, #0a0a0d); border: 3px solid #c9d0d7; box-shadow: 0 0 0 2px #000, 0 0 0 6px var(--ir-red), 0 30px 80px rgba(0,0,0,.8); animation: irpop .3s ease; }
.ir-card.wide { width: min(760px, 100%); text-align: left; }
@keyframes irpop { from { transform: scale(.9); opacity: 0; } }
.ir-card h2, .ir-card h3 { font: 900 clamp(17px, 5vw, 22px)/1.2 var(--ir-title); letter-spacing: 1px; text-transform: uppercase; color: #fff; margin-bottom: 10px; text-align: center; }
.ir-card .big { font-size: clamp(44px, 9vw, 82px); line-height: 1.1; margin: 8px 0; }
.ir-card p { color: #c9cdd3; font-size: 14px; line-height: 1.5; margin: 6px 0 12px; }
.ir-tier { font: 900 clamp(34px, 7vw, 64px) var(--ir-title); letter-spacing: 3px; background: linear-gradient(180deg, #fff, #f2c6cb 40%, var(--ir-red) 60%, #ffb0b8); -webkit-background-clip: text; background-clip: text; color: transparent; filter: drop-shadow(0 0 18px rgba(212,20,44,.6)); }
.ir-tier.pop { animation: irpop .35s ease; }
.ir-cta { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-width: 200px; height: 52px; margin-top: 8px; padding: 0 22px; border-radius: 10px; cursor: pointer; border: 1px solid #2a0008;
  font: 900 15px var(--ir-ui); letter-spacing: 1px; color: #fff; background: linear-gradient(180deg, #ff5a68, var(--ir-red) 45%, var(--ir-red2)); box-shadow: inset 0 1px 0 rgba(255,255,255,.45), 0 4px 0 #3a0006; }
.ir-cta.alt { background: linear-gradient(180deg, #ffffff, #c3cad1); color: #111; border-color: #2a2f36; box-shadow: inset 0 1px 0 #fff, 0 4px 0 #2a2f36; }
.ir-x { position: absolute; top: 10px; right: 10px; width: 36px; height: 36px; border-radius: 8px; border: 1px solid #2a2f36; background: linear-gradient(180deg, #fff, #c3cad1); color: #111; cursor: pointer; }
.ir-row { display: flex; align-items: center; justify-content: space-between; padding: 12px 4px; border-bottom: 1px solid rgba(255,255,255,.08); font-weight: 800; cursor: pointer; }
.switch { width: 50px; height: 28px; border-radius: 14px; background: #2a2f36; position: relative; transition: background .2s; }
.switch::after { content: ""; position: absolute; top: 3px; left: 3px; width: 22px; height: 22px; border-radius: 50%; background: linear-gradient(180deg, #fff, #b9c0c7); transition: left .2s; }
.switch.on { background: var(--ir-red); } .switch.on::after { left: 25px; }
.ir-chips { display: flex; gap: 8px; justify-content: center; margin: 10px 0; flex-wrap: wrap; }
.ir-chips button { width: 56px; height: 44px; border-radius: 8px; border: 1px solid #2a2f36; background: linear-gradient(180deg, #fff, #c3cad1); color: #111; font: 900 16px var(--ir-led-f); cursor: pointer; }
.ir-chips button.sel { background: linear-gradient(180deg, #ff5a68, var(--ir-red)); color: #fff; }
.ir-pay { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; margin: 8px 0 14px; }
.ir-pay .it { display: flex; align-items: center; gap: 8px; padding: 8px; border-radius: 10px; background: rgba(255,255,255,.04); border: 1px solid rgba(255,255,255,.08); }
.ir-pay img { width: 56px; height: 56px; }
.ir-pay .t { font-size: 12.5px; line-height: 1.5; color: #c9cdd3; } .ir-pay .t b { color: var(--ir-amber); }
.ir-rules { padding-left: 18px; color: #c9cdd3; font-size: 13.5px; line-height: 1.6; } .ir-rules li { margin: 6px 0; }

/* телефон */
@media (max-width: 900px), (max-aspect-ratio: 1/1) {
  .ir-top { padding: 8px 10px 6px; gap: 8px; }
  .ir-back span, .ir-title small { display: none; }
  .ir-back { height: 36px; padding: 0 12px; }
  .ir-title b { font-size: 16px; letter-spacing: 1px; white-space: normal; line-height: 1.05; }
  .ir-bal { height: 36px; } .ir-bal .lbl { display: none; } .ir-bal b { font-size: 13px; padding: 0 8px; } .ir-bal button { width: 34px; }
  .ir-login { height: 36px; white-space: nowrap; }
  .ir-main { flex-direction: column; padding: 4px 8px; gap: 8px; }
  .ir-stage { flex: 1 1 0; min-height: 0; }
  .ir-badges { position: static; transform: none; flex-direction: row; width: 100%; gap: 8px; }
  .ir-badges > * { flex: 1; min-width: 0; }
  .ir-badge { padding: 6px 8px; } .ir-badge b { font-size: 18px; }
  .ir-buy { padding: 6px; } .ir-buy b { font-size: 16px; }
  .ir-deck { flex-wrap: wrap; gap: 8px; padding: 10px 10px calc(10px + env(safe-area-inset-bottom)); justify-content: space-between; }
  .ir-deck > .ir-keys:first-child { order: 5; }
  .ir-led { min-width: 0; flex: 1; padding: 4px 8px; } .ir-led b { font-size: 17px; }
  .ir-betgrp { margin-left: 0; flex: 1 1 100%; order: 2; }
  .ir-betgrp .ir-led { flex: 1; }
  .ir-key { min-width: 44px; height: 44px; }
  .ir-spin { width: 84px; height: 84px; margin: 0; order: 4; }
  .ir-spin span { font-size: 18px; }
}
/* мобильный слой v2: START без задержки/отмены тапа; кнопки ≥40px; ландшафт — доска слева, пульт справа */
#spinBtn { touch-action: none; -webkit-touch-callout: none; }
@media (max-width: 900px), (max-aspect-ratio: 1/1) {
  html body .ir-back { height: 40px; min-width: 40px; justify-content: center; }
  html body .ir-bal { height: 42px; } html body .ir-bal button { width: 40px; }
}
@media (orientation: landscape) and (max-height: 520px) and (max-width: 1000px) {
  html body .ir-app { grid-template-columns: minmax(0, 1fr) 230px !important; grid-template-rows: auto minmax(0, 1fr) !important; grid-template-areas: "top deck" "main deck" !important; }
  html body .ir-top { grid-area: top; padding: 4px 8px 0 !important; }
  html body .ir-main { grid-area: main; min-height: 0; padding: 2px 6px 6px !important; gap: 4px !important; }
  html body .ir-badge, html body .ir-buy { padding: 3px 8px !important; } html body .ir-badge b { font-size: 15px !important; } html body .ir-buy b { font-size: 14px !important; }
  html body .ir-deck { grid-area: deck; flex-direction: column !important; flex-wrap: nowrap !important; justify-content: space-evenly !important; align-items: stretch !important; gap: 6px !important; padding: 8px !important; overflow: hidden; }
  html body .ir-deck::before { left: 0; right: auto; top: 0; bottom: 0; width: 4px; height: auto; }
  html body .ir-deck > .ir-led.win { order: 1; flex: none; }
  html body .ir-deck > .ir-betgrp { order: 2; flex: none !important; }
  html body .ir-deck > .ir-keys:has(#turboBtn) { order: 3; justify-content: center; }
  html body .ir-deck > .ir-spin { order: 4; align-self: center; width: 78px !important; height: 78px !important; margin: 0 !important; }
  html body .ir-deck > .ir-keys:first-child { order: 5; justify-content: center; }
  html body .ir-key { min-width: 44px; height: 42px; }
}
/* модалки выше экрана (ландшафт телефона) прокручиваются, верх не обрезается */
.ir-ov.show { align-items: flex-start; overflow-y: auto; overscroll-behavior: contain; }
.ir-ov.show > * { margin: auto; flex: none; max-width: 100%; }
/* MOBHUD (2026-11-26): телефон — START отодвинут от кнопок ставки/иконок */
@media (max-width: 600px) and (max-aspect-ratio: 1/1) {
  html body .ir-deck > .ir-spin { margin-top: 10px; }
}
@media (orientation: landscape) and (max-height: 520px) and (max-width: 1000px) {
  html body .ir-deck > .ir-spin { margin: 10px 0 !important; }
}

/* ===== others_fix 2026-11-28: окна, 21+, громкость, Telegram, касания, телефон ===== */
/* окна с крестиком: заголовок не заходит под × */
.ir-card:has(> .ir-x) > h3 { padding: 0 40px; font-size: clamp(15px, 4.6vw, 22px); letter-spacing: .5px; }
.ir-card p.ir-note { font-size: 12px; line-height: 1.5; color: #9da2aa; margin: 14px 0 0; text-align: center; }
.ir-note a { color: var(--ir-amber); }
/* громкость музыки и звуков (ползунки wm.js в окне настроек) */
#settings .wm-vol { border-bottom-color: rgba(255,255,255,.08); text-align: left; }
#settings .wm-vol .t { color: #f1f1f3; }
#settings .wm-vol .t b { color: var(--ir-amber); }
#settings .wm-vol input[type=range] { background: linear-gradient(90deg, #ff5a68, var(--ir-red2)); }
#settings .wm-vol input[type=range]::-webkit-slider-thumb { background: linear-gradient(180deg, #fff, #c3cad1); border-color: #2a2f36; }
#settings .ir-row { text-align: left; }
/* Telegram — встроенный значок (шрифт Font Awesome Brands не загружается) */
.fa-brands.fa-telegram { font-family: inherit !important; font-weight: inherit; }
.fa-brands.fa-telegram::before { content: ""; display: inline-block; width: 1em; height: 1em; vertical-align: -.125em; background: currentColor;
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 496 512'%3E%3Cpath d='M248,8C111.033,8,0,119.033,0,256S111.033,504,248,504,496,392.967,496,256,384.967,8,248,8ZM362.952,176.66c-3.732,39.215-19.881,134.378-28.1,178.3-3.476,18.584-10.322,24.816-16.948,25.425-14.4,1.326-25.338-9.517-39.287-18.661-21.827-14.308-34.158-23.215-55.346-37.177-24.485-16.135-8.612-25,5.342-39.5,3.652-3.793,67.107-61.51,68.335-66.746.153-.655.3-3.1-1.154-4.384s-3.59-.849-5.135-.5q-3.283.746-104.608,69.142-14.845,10.194-26.894,9.934c-8.855-.191-25.888-5.006-38.551-9.123-15.531-5.048-27.875-7.717-26.8-16.291q.84-6.7,18.45-13.7,108.446-47.248,144.628-62.3c68.872-28.647,83.183-33.623,92.511-33.789,2.052-.034,6.639.474,9.61,2.885a10.452,10.452,0,0,1,3.53,6.716A43.765,43.765,0,0,1,362.952,176.66Z'/%3E%3C/svg%3E") center / contain no-repeat;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 496 512'%3E%3Cpath d='M248,8C111.033,8,0,119.033,0,256S111.033,504,248,504,496,392.967,496,256,384.967,8,248,8ZM362.952,176.66c-3.732,39.215-19.881,134.378-28.1,178.3-3.476,18.584-10.322,24.816-16.948,25.425-14.4,1.326-25.338-9.517-39.287-18.661-21.827-14.308-34.158-23.215-55.346-37.177-24.485-16.135-8.612-25,5.342-39.5,3.652-3.793,67.107-61.51,68.335-66.746.153-.655.3-3.1-1.154-4.384s-3.59-.849-5.135-.5q-3.283.746-104.608,69.142-14.845,10.194-26.894,9.934c-8.855-.191-25.888-5.006-38.551-9.123-15.531-5.048-27.875-7.717-26.8-16.291q.84-6.7,18.45-13.7,108.446-47.248,144.628-62.3c68.872-28.647,83.183-33.623,92.511-33.789,2.052-.034,6.639.474,9.61,2.885a10.452,10.452,0,0,1,3.53,6.716A43.765,43.765,0,0,1,362.952,176.66Z'/%3E%3C/svg%3E") center / contain no-repeat; }
/* сенсорные экраны: все цели касания ≥44px */
@media (pointer: coarse) {
  .ir-x { width: 44px; height: 44px; top: 8px; right: 8px; }
  .ir-card:has(> .ir-x) > h3 { padding: 0 46px; }
  html body .ir-key, html body .ir-back, html body .ir-login, html body .ir-bal button { min-width: 44px; min-height: 44px; }
  html body .ir-bal { min-height: 44px; }
  .ir-row { min-height: 48px; }
  .ir-note a { display: inline-block; padding: 12px 4px; margin: -12px 0; }
  #settings .wm-vol .ln { min-height: 44px; }
  #settings .wm-vol .switch { box-shadow: 0 0 0 8px transparent; }
  #settings .wm-vol input[type=range]::-webkit-slider-thumb { width: 28px; height: 28px; }
}
/* телефон (портрет): компактный верх, SPIN справа внизу (как у других провайдеров), безопасные зоны */
@media (max-width: 900px), (max-aspect-ratio: 1/1) {
  html body .ir-top { padding: max(8px, env(safe-area-inset-top)) max(10px, env(safe-area-inset-right)) 6px max(10px, env(safe-area-inset-left)); }
  html body .ir-back { height: 44px; min-width: 44px; padding: 0 12px; }
  html body .ir-bal { height: 44px; } html body .ir-bal button { width: 44px; }
  html body .ir-login { height: 44px; }
  html body .ir-main { padding: 4px max(8px, env(safe-area-inset-right)) 4px max(8px, env(safe-area-inset-left)); gap: 6px; }
  html body .ir-deck { padding: 10px max(10px, env(safe-area-inset-right)) calc(10px + env(safe-area-inset-bottom)) max(10px, env(safe-area-inset-left)); gap: 8px; }
  html body .ir-key { min-width: 48px; height: 48px; font-size: 18px; } html body .ir-key em { font-size: 9px; }
  html body .ir-key.sm { min-width: 48px; height: 48px; }
  html body .ir-led { min-width: 0; padding: 4px 8px; } html body .ir-led b { font-size: 19px; } html body .ir-led small { font-size: 9.5px; }
  html body .ir-deck > .ir-keys:first-child { order: 4; }
  html body .ir-deck > .ir-spin { order: 5; width: 88px; height: 88px; margin: 0 0 0 auto; }
  html body .ir-spin span { font-size: 14px; }
}
/* телефон (ландшафт): пульт справа уже — доске больше места */
@media (orientation: landscape) and (max-height: 520px) and (max-width: 1000px) {
  html body .ir-app { grid-template-columns: minmax(0, 1fr) calc(204px + env(safe-area-inset-right)) !important; }
  html body .ir-top { padding: max(4px, env(safe-area-inset-top)) 8px 0 max(8px, env(safe-area-inset-left)) !important; }
  html body .ir-main { padding: 2px 6px max(6px, env(safe-area-inset-bottom)) max(6px, env(safe-area-inset-left)) !important; }
  html body .ir-deck { padding: max(6px, env(safe-area-inset-top)) max(6px, env(safe-area-inset-right)) max(6px, env(safe-area-inset-bottom)) 10px !important; gap: 5px !important; }
  html body .ir-deck > .ir-keys { gap: 6px; }
  html body .ir-key { min-width: 44px; height: 44px; }
  html body .ir-deck > .ir-spin { order: 4; margin: 4px 0 !important; width: 76px !important; height: 76px !important; }
  html body .ir-deck > .ir-keys:first-child { order: 5; justify-content: center; }
  html body .ir-led b { font-size: 16px; }
}
/* высокие телефоны (390×844, 430×932, 360×780): доска упирается в ширину — запас высоты идёт в крупный пульт, а не в пустой фон */
@media (max-aspect-ratio: 1/2) and (min-height: 700px) {
  html body .ir-deck { padding-top: 14px; padding-bottom: calc(14px + env(safe-area-inset-bottom)); row-gap: 12px; }
  html body .ir-key, html body .ir-key.sm { min-width: 56px; height: 56px; font-size: 20px; } html body .ir-key em { font-size: 10px; }
  html body .ir-led { padding: 6px 8px; } html body .ir-led b { font-size: 23px; } html body .ir-led small { font-size: 10.5px; }
  html body .ir-deck > .ir-spin { width: 104px; height: 104px; }
  html body .ir-spin span { font-size: 16px; }
  html body .ir-badge b { font-size: 22px; } html body .ir-buy b { font-size: 18px; }
}
@media (orientation: landscape) and (max-height: 520px) and (max-width: 1000px) {
  html body .ir-deck { padding-left: 8px !important; padding-right: max(6px, env(safe-area-inset-right)) !important; }
  html body .ir-deck > .ir-keys { gap: 4px; }
  html body .ir-led small { font-size: 8.5px; letter-spacing: 0; }
  html body .ir-betgrp { gap: 4px; }
}
@media (max-aspect-ratio: 1/2) and (min-height: 700px) and (max-width: 374px) {
  html body .ir-key, html body .ir-key.sm { min-width: 52px; height: 52px; }
  html body .ir-deck > .ir-spin { width: 96px; height: 96px; }
}
@media (orientation: landscape) and (max-height: 520px) and (max-width: 1000px) {
  html body .ir-key.sm { min-width: 44px; height: 44px; }
}

/* полосы прокрутки (01.12): тонкие, тёмная дорожка, стальной бегунок, мятный при наведении (как в оболочке brink.bet) */
* { scrollbar-width: thin; scrollbar-color: rgba(120,138,180,.45) transparent; }
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: rgba(120,138,180,.45); border-radius: 6px; }
::-webkit-scrollbar-thumb:hover { background: #2FE6B8; }
::-webkit-scrollbar-corner { background: transparent; }
