:root {
  --ink: #f6f7fb;
  --surface: #12141a;
  --line: rgba(255, 255, 255, 0.075);
  --banker: #ff5c66;
  --player: #38a7ff;
  --tie: #4bd49a;
  --live: #4bd49a;
  --accent: #dcc57a;
  --signal-wash: rgba(255, 195, 91, 0.09);
  --signal-surface-top: #1b1821;
  --signal-surface-bottom: #14151b;
  --road-wash: rgba(56, 167, 255, 0.1);
  --road-surface-top: #111923;
  --road-surface-bottom: #0d141c;
  --road-canvas: #091018;
  --logo-a: #38a7ff;
  --logo-b: #8b5cf6;
  --logo-c: #ff5c66;
}

html[data-game="andar-bahar"] {
  --banker: #ffad42;
  --player: #338cff;
  --tie: #4fd39a;
  --accent: #f5c85b;
  --signal-wash: rgba(255, 173, 66, 0.14);
  --signal-surface-top: #18241e;
  --signal-surface-bottom: #101814;
  --road-wash: rgba(46, 190, 125, 0.13);
  --road-surface-top: #10241d;
  --road-surface-bottom: #0b1714;
  --road-canvas: #07130f;
  --logo-a: #35d39a;
  --logo-b: #f5c85b;
  --logo-c: #ff8b35;
}

html[data-game="teen-patti"] {
  --banker: #ff386f;
  --player: #6e55ff;
  --tie: #f6c653;
  --accent: #ffe09a;
  --signal-wash: rgba(255, 56, 111, 0.18);
  --signal-surface-top: #32101f;
  --signal-surface-bottom: #170b17;
  --road-wash: rgba(246, 198, 83, 0.11);
  --road-surface-top: #211127;
  --road-surface-bottom: #0f0916;
  --road-canvas: #0c0711;
  --logo-a: #f6c653;
  --logo-b: #ff386f;
  --logo-c: #6e55ff;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }

html,
body {
  margin: 0;
  width: 100%;
  max-width: 100%;
  height: 100%;
  min-height: 0;
  overflow: hidden;
  overscroll-behavior: none;
  background: #090a0d;
  color: var(--ink);
  font-family: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

html { position: fixed; inset: 0; }
body { touch-action: pan-y pinch-zoom; }

button { font: inherit; touch-action: manipulation; }
button:focus-visible { outline: 2px solid #fff; outline-offset: 3px; }

.app-shell {
  position: relative;
  height: 100%;
  min-height: 0;
  display: grid;
  place-items: center;
  overflow: hidden;
  overscroll-behavior: none;
  touch-action: pan-y pinch-zoom;
  isolation: isolate;
  background:
    radial-gradient(circle at 15% 18%, rgba(54, 100, 147, 0.2), transparent 28%),
    radial-gradient(circle at 82% 74%, rgba(101, 81, 35, 0.16), transparent 29%),
    #090a0d;
}

.ambient {
  position: fixed;
  z-index: -1;
  width: 340px;
  height: 340px;
  border-radius: 50%;
  filter: blur(90px);
  opacity: 0.23;
  pointer-events: none;
}

.ambient-one { top: -180px; right: -90px; background: #2169a5; }
.ambient-two { bottom: -200px; left: -130px; background: #806c2c; }
html[data-game="andar-bahar"] .ambient-one { background: #1c8e63; }
html[data-game="andar-bahar"] .ambient-two { background: #b56e18; }
html[data-game="teen-patti"] .ambient-one { background: #704ac7; }
html[data-game="teen-patti"] .ambient-two { background: #9f304f; }

.phone {
  position: relative;
  width: min(100%, 430px);
  height: 100%;
  min-height: 0;
  padding: 10px 16px 12px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  background:
    linear-gradient(135deg, color-mix(in srgb, var(--accent) 4%, transparent) 25%, transparent 25%) 0 0 / 24px 24px,
    linear-gradient(315deg, color-mix(in srgb, var(--banker) 4%, transparent) 25%, transparent 25%) 0 0 / 24px 24px,
    radial-gradient(circle at 50% -10%, color-mix(in srgb, var(--player) 17%, transparent), transparent 40%),
    #0b0c11;
  overflow: hidden;
  overscroll-behavior-x: none;
  transition: background 280ms ease;
}

.phone[data-game="baccarat"] {
  background:
    linear-gradient(135deg, rgba(56, 167, 255, 0.038) 25%, transparent 25%) 0 0 / 24px 24px,
    linear-gradient(315deg, rgba(255, 92, 102, 0.038) 25%, transparent 25%) 0 0 / 24px 24px,
    radial-gradient(circle at 50% -10%, rgba(57, 92, 164, 0.28), transparent 42%),
    #080d15;
}

.phone[data-game="andar-bahar"] {
  background:
    linear-gradient(135deg, rgba(245, 200, 91, 0.04) 25%, transparent 25%) 0 0 / 24px 24px,
    linear-gradient(315deg, rgba(53, 211, 154, 0.04) 25%, transparent 25%) 0 0 / 24px 24px,
    radial-gradient(circle at 50% -10%, rgba(32, 139, 96, 0.27), transparent 42%),
    #07120e;
}

.phone[data-game="teen-patti"] {
  background:
    linear-gradient(135deg, rgba(246, 198, 83, 0.035) 25%, transparent 25%) 0 0 / 24px 24px,
    linear-gradient(315deg, rgba(255, 56, 111, 0.035) 25%, transparent 25%) 0 0 / 24px 24px,
    radial-gradient(circle at 50% -10%, rgba(111, 48, 111, 0.32), transparent 40%),
    #100811;
}

.topbar,
.section-title-row,
.input-copy,
.signal-heading,
.brand-lockup,
.top-actions,
.road-actions {
  display: flex;
  align-items: center;
}

.topbar,
.section-title-row,
.input-copy,
.signal-heading { justify-content: space-between; }
.topbar { min-height: 40px; }
.brand-lockup { gap: 10px; }

.brand-mark {
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(220, 197, 122, 0.35);
  border-radius: 12px;
  background: linear-gradient(145deg, #27251d, #121310);
  color: var(--accent);
  font-size: 17px;
  font-weight: 900;
  box-shadow: inset 0 1px rgba(255, 255, 255, 0.08);
}

.eyebrow,
.section-kicker {
  margin: 0;
  color: #c9cbd1;
  font-size: 12px;
  line-height: 1;
  font-weight: 800;
  letter-spacing: 0.16em;
}

.brand-subtitle { margin: 4px 0 0; color: #6e7480; font-size: 10px; font-weight: 600; }
.top-actions { gap: 8px; }

.live-pill {
  height: 32px;
  padding: 0 12px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  border: 1px solid rgba(75, 212, 154, 0.18);
  border-radius: 999px;
  background: rgba(75, 212, 154, 0.07);
  color: #8be7bd;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.1em;
}

.live-pill i { width: 6px; height: 6px; border-radius: 50%; background: var(--live); box-shadow: 0 0 0 4px rgba(75, 212, 154, 0.08); animation: live-dot 1.35s ease-in-out infinite; }

.teen-mode-switch {
  height: 34px;
  padding: 3px;
  display: grid;
  grid-template-columns: 0.8fr 1.25fr;
  gap: 3px;
  border: 1px solid color-mix(in srgb, var(--accent) 24%, transparent);
  border-radius: 9px;
  background: rgba(5, 3, 10, 0.5);
  box-shadow: inset 0 1px rgba(255, 255, 255, 0.045);
  overflow: hidden;
  overscroll-behavior-x: none;
  touch-action: pan-y;
}
.teen-mode-switch button { padding: 0 8px; border: 0; border-radius: 6px; background: transparent; color: #82788b; font-size: 9.5px; font-weight: 900; letter-spacing: 0.06em; white-space: nowrap; cursor: pointer; transition: transform 260ms cubic-bezier(0.22, 1, 0.36, 1), opacity 220ms ease, color 180ms ease, background 180ms ease, box-shadow 180ms ease; }
.teen-mode-switch button.is-active { background: linear-gradient(145deg, color-mix(in srgb, var(--player) 48%, #20132c), color-mix(in srgb, var(--banker) 28%, #130a19)); color: #fff4d2; box-shadow: inset 0 1px rgba(255, 255, 255, 0.16), 0 0 12px color-mix(in srgb, var(--player) 22%, transparent); }

.icon-button {
  width: 28px;
  height: 28px;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: #15171c;
  color: #8f949e;
  font-family: Georgia, serif;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
}

.signal-card,
.road-card {
  border: 1px solid rgba(255, 255, 255, 0.09);
  border-radius: 24px;
  box-shadow: 0 18px 50px rgba(0, 0, 0, 0.25);
}

.signal-card { position: relative; min-height: 0; padding: 12px 18px 18px; display: flex; flex: 0 0 auto; flex-direction: column; overflow: hidden; background: linear-gradient(145deg, var(--signal-wash), transparent 39%), linear-gradient(180deg, var(--signal-surface-top), var(--signal-surface-bottom)); box-shadow: 0 20px 55px rgba(0, 0, 0, 0.28), inset 0 1px rgba(255, 227, 164, 0.04); transition: background 280ms ease, border-color 280ms ease; }

.phone .signal-card {
  border-color: color-mix(in srgb, var(--accent) 28%, transparent);
  border-radius: 16px;
  background:
    linear-gradient(118deg, rgba(255, 255, 255, 0.075), transparent 21%),
    repeating-linear-gradient(135deg, transparent 0 16px, color-mix(in srgb, var(--accent) 2.2%, transparent) 16px 17px),
    radial-gradient(circle at 14% 18%, color-mix(in srgb, var(--banker) 24%, transparent), transparent 36%),
    radial-gradient(circle at 89% 78%, color-mix(in srgb, var(--player) 21%, transparent), transparent 38%),
    color-mix(in srgb, var(--signal-surface-bottom) 84%, #090b10);
  box-shadow: 0 22px 60px rgba(3, 0, 8, 0.52), inset 0 0 0 1px color-mix(in srgb, var(--accent) 4%, transparent), inset 0 1px color-mix(in srgb, var(--accent) 12%, white);
}

.phone .signal-card::after {
  content: "";
  position: absolute;
  inset: 7px;
  border: 1px solid color-mix(in srgb, var(--accent) 8%, transparent);
  border-radius: 11px;
  pointer-events: none;
}

.game-switcher {
  position: relative;
  z-index: 2;
  height: 46px;
  margin: -3px -7px 10px;
  padding: 4px;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 3px;
  border: 1px solid rgba(255, 255, 255, 0.065);
  border-radius: 14px;
  background: rgba(4, 6, 9, 0.38);
  box-shadow: inset 0 1px rgba(255, 255, 255, 0.035);
  overscroll-behavior-x: none;
  touch-action: pan-y;
}

.game-switcher button {
  min-width: 0;
  padding: 0 5px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  border: 1px solid transparent;
  border-radius: 10px;
  background: transparent;
  color: #777e89;
  font-size: 12px;
  line-height: 1;
  font-weight: 850;
  white-space: nowrap;
  cursor: pointer;
  transition: color 180ms ease, background 180ms ease, border-color 180ms ease, box-shadow 180ms ease, transform 140ms ease;
}

.game-switcher button:active { transform: scale(0.96); }
.game-switcher button i { width: 6px; height: 6px; flex: 0 0 auto; border-radius: 50%; background: #59606b; transition: background 180ms ease, box-shadow 180ms ease; }
.game-switcher button[data-game="andar-bahar"] { --tab-accent: #f3ad42; }
.game-switcher button[data-game="baccarat"] { --tab-accent: #51adff; }
.game-switcher button[data-game="teen-patti"] { --tab-accent: #d277ff; }
.game-switcher button.is-active { border-color: color-mix(in srgb, var(--tab-accent) 30%, transparent); background: linear-gradient(180deg, color-mix(in srgb, var(--tab-accent) 18%, rgba(255, 255, 255, 0.035)), color-mix(in srgb, var(--tab-accent) 7%, transparent)); color: #f3f5f8; box-shadow: inset 0 1px rgba(255, 255, 255, 0.08), 0 0 13px color-mix(in srgb, var(--tab-accent) 13%, transparent); }
.game-switcher button.is-active i { background: var(--tab-accent); box-shadow: 0 0 7px var(--tab-accent); }

.signal-heading { position: relative; z-index: 1; align-items: center; min-height: 34px; gap: 7px; }
.signal-heading h1, .section-title-row h2, .input-copy h2, .info-sheet h2 { margin: 0; letter-spacing: -0.04em; }
.signal-heading h1 { font-size: 34px; line-height: 0.98; }
.signal-heading h1 { min-width: 0; flex: 1 1 auto; overflow: hidden; white-space: nowrap; }
.signal-heading .live-pill,
.signal-heading .teen-mode-switch { flex: 0 0 auto; }
.game-switcher button,
.teen-mode-switch button,
.predictor-label,
.road-title,
.input-copy h2 { white-space: nowrap; }
.signal-banker .signal-heading h1 { color: color-mix(in srgb, var(--banker) 76%, white); }
.signal-player .signal-heading h1 { color: color-mix(in srgb, var(--player) 76%, white); }
.signal-tie .signal-heading h1 { color: color-mix(in srgb, var(--tie) 76%, white); }

.model-chip {
  padding: 7px 9px;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: #747a85;
  background: rgba(255, 255, 255, 0.025);
  font-size: 8px;
  font-weight: 800;
  letter-spacing: 0.12em;
}

.signal-core { margin-top: 16px; display: grid; grid-template-columns: 142px 1fr; gap: 18px; align-items: center; }

.confidence-ring {
  --ring-color: var(--banker);
  --ring-progress: 43deg;
  position: relative;
  width: 134px;
  height: 134px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  overflow: hidden;
  background:
    radial-gradient(circle, #12141a 58%, transparent 59%),
    conic-gradient(from 210deg, var(--ring-color) 0 var(--ring-progress), rgba(255, 255, 255, 0.07) var(--ring-progress) 360deg);
  box-shadow: inset 0 0 35px rgba(255, 255, 255, 0.025), 0 0 30px color-mix(in srgb, var(--ring-color) 12%, transparent);
}

.ring-logo-mark {
  position: absolute;
  z-index: 2;
  top: 25px;
  left: 50%;
  width: 62px;
  height: 55px;
  display: none;
  transform: translateX(-50%);
  background: linear-gradient(135deg, var(--logo-a), var(--logo-b) 52%, var(--logo-c));
  -webkit-mask: url("./nxthand-mark.svg") center / contain no-repeat;
  mask: url("./nxthand-mark.svg") center / contain no-repeat;
  filter: drop-shadow(0 0 8px color-mix(in srgb, var(--logo-b) 55%, transparent));
  transition: background 280ms ease, filter 280ms ease;
}

.confidence-ring.is-empty {
  background:
    radial-gradient(circle, #12141a 58%, transparent 59%),
    conic-gradient(from 210deg, var(--logo-a), var(--logo-b) 52%, var(--logo-c), var(--logo-a));
  box-shadow: inset 0 0 35px rgba(255, 255, 255, 0.035), 0 0 28px color-mix(in srgb, var(--logo-b) 18%, transparent);
}

.confidence-ring.is-empty .ring-logo-mark { display: block; }
.confidence-ring.is-empty .ring-value,
.confidence-ring.is-empty .ring-track-glint { display: none; }

.ring-track-glint { position: absolute; inset: 0; border-radius: 50%; background: conic-gradient(from 210deg, rgba(255, 255, 255, 0.98) 0 7deg, rgba(255, 255, 255, 0.5) 9deg, rgba(255, 255, 255, 0.16) 15deg, transparent 19deg 360deg); -webkit-mask: radial-gradient(circle at 50% 50%, transparent 0 58%, #000 59% 100%); mask: radial-gradient(circle at 50% 50%, transparent 0 58%, #000 59% 100%); filter: drop-shadow(0 0 5px color-mix(in srgb, var(--ring-color) 72%, transparent)); transform-origin: 50% 50%; opacity: 0; pointer-events: none; }

.signal-player .confidence-ring { --ring-color: var(--player); }
.signal-tie .confidence-ring { --ring-color: var(--tie); }
.confidence-ring > div { position: absolute; inset: 0; }
.confidence-ring strong { position: absolute; top: 50%; left: 50%; font-size: 38px; line-height: 0.9; letter-spacing: -0.07em; transform: translate(-50%, -50%); }
.confidence-ring > div > span { position: absolute; top: calc(50% - 22px); left: calc(50% + 28px); color: #8f949e; font-size: 14px; font-weight: 800; }
.confidence-ring small { position: absolute; bottom: 32px; color: #686e79; font-size: 10px; font-weight: 900; letter-spacing: 0.13em; }
.confidence-ring.is-empty small { bottom: 22px; color: color-mix(in srgb, var(--logo-b) 68%, white); font-size: 10px; letter-spacing: 0.04em; text-transform: none; }

.phone .confidence-ring {
  outline: 1px solid color-mix(in srgb, var(--accent) 28%, transparent);
  outline-offset: 4px;
  box-shadow: inset 0 0 42px color-mix(in srgb, var(--banker) 7%, transparent), 0 0 0 7px color-mix(in srgb, var(--accent) 2.8%, transparent), 0 0 32px color-mix(in srgb, var(--ring-color) 18%, transparent);
}
.probability-list { display: grid; gap: 13px; }
.phone[data-game="andar-bahar"] .probability-list { gap: 20px; }
.probability-label { display: flex; justify-content: space-between; color: #777d88; font-size: 13px; font-weight: 650; }
.probability-label b { color: #cfd2d8; font-variant-numeric: tabular-nums; }
.probability-track { margin-top: 7px; height: 7px; overflow: hidden; border-radius: 99px; background: rgba(255, 255, 255, 0.07); }
.probability-track i { display: block; height: 100%; min-width: 3px; border-radius: inherit; transition: width 250ms ease; }
.probability-track .banker { width: 46%; background: var(--banker); }
.probability-track .player { width: 45%; background: var(--player); }
.probability-track .tie { width: 9%; background: var(--tie); }

.signal-note {
  position: relative;
  min-height: 58px;
  padding: 12px;
  display: flex;
  gap: 9px;
  align-items: center;
  border: 1px solid color-mix(in srgb, var(--readiness-accent) 22%, rgba(220, 197, 122, 0.1));
  border-radius: 12px;
  background: linear-gradient(135deg, color-mix(in srgb, var(--readiness-accent) 18%, transparent) 0%, rgba(18, 19, 26, 0.94) 42%, color-mix(in srgb, var(--readiness-color) 14%, rgba(13, 14, 20, 0.98)) 100%);
  box-shadow: inset 0 1px rgba(255, 255, 255, 0.08), inset 0 0 22px color-mix(in srgb, var(--readiness-color) 10%, transparent);
  overflow: hidden;
}

.signal-note::before { content: ""; position: absolute; inset: 0; background: linear-gradient(122deg, rgba(255, 255, 255, 0.12), rgba(255, 255, 255, 0.025) 25%, transparent 48%, color-mix(in srgb, var(--readiness-accent) 10%, transparent)); pointer-events: none; }
.signal-note > * { position: relative; z-index: 1; }
.signal-note.is-record { animation: record-module-impact 760ms cubic-bezier(0.2, 0.9, 0.28, 1); }
.signal-note.is-record::after { content: ""; position: absolute; inset: -35% auto -35% -45%; width: 32%; background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent); transform: skewX(-16deg); pointer-events: none; animation: record-module-sweep 820ms 80ms ease-out both; }

.pulse-icon { width: 32px; height: 32px; flex: 0 0 auto; display: grid; place-items: center; overflow: hidden; isolation: isolate; border: 1px solid rgba(220, 197, 122, 0.18); border-radius: 10px; background: rgba(220, 197, 122, 0.1); color: var(--accent); font-size: 14px; font-weight: 900; transition: color 180ms ease, background 180ms ease, border-color 180ms ease, box-shadow 180ms ease; }
.pulse-icon .record-crown { display: block; width: 17px; height: 17px; margin: 0; fill: currentColor; filter: drop-shadow(0 0 3px currentColor); transform: translateY(0.25px); }
.signal-note p { min-width: 0; flex: 1; margin: 0; overflow: hidden; }
.signal-note p strong, .signal-note p span { display: block; }
.signal-note p strong, .signal-note p span { max-width: 100%; white-space: nowrap; overflow: hidden; text-overflow: clip; line-height: 1.15; }
.signal-note p strong { color: #e2e4e9; font-size: 13px; }
.signal-note p span { margin-top: 3px; color: #9399a5; font-size: 12px; }
.pulse-icon.record { font-size: 18px; line-height: 1; }
.record-badge { width: 58px; flex: 0 0 auto; margin: 0 !important; color: #a889d8; font-size: 10px !important; font-weight: 900; line-height: 1.25; letter-spacing: 0.09em; text-align: right; }
.signal-note.is-record .record-badge { transform-origin: right center; animation: record-badge-impact 720ms cubic-bezier(0.18, 0.9, 0.25, 1); }
.analysis-stage { --readiness-color: hsl(275 58% 42%); --readiness-accent: hsl(275 66% 60%); position: relative; min-height: 58px; margin-top: 14px; }
.analysis-stage > .signal-note, .analysis-stage > .readiness-meter, .analysis-stage > .readiness-success { position: absolute; inset: 0; margin: 0; transition: opacity 420ms ease, transform 520ms cubic-bezier(0.22, 1, 0.36, 1); }
.analysis-stage > .signal-note { opacity: 0; transform: translateY(5px) scale(0.985); pointer-events: none; }
.analysis-stage > .readiness-success { opacity: 0; transform: translateY(4px) scale(0.985); pointer-events: none; }
.readiness-meter { min-height: 58px; padding: 12px; border: 1px solid color-mix(in srgb, var(--readiness-accent) 28%, transparent); border-radius: 12px; background: linear-gradient(90deg, color-mix(in srgb, var(--readiness-color) 20%, transparent), transparent); box-shadow: inset 0 0 18px color-mix(in srgb, var(--readiness-color) 8%, transparent); transition: border-color 240ms ease, background 240ms ease, box-shadow 240ms ease; }
.readiness-copy { min-width: 0; min-height: 13px; display: grid; grid-template-columns: minmax(0, 1.18fr) minmax(0, 0.92fr) auto; gap: 7px; align-items: center; color: #666c77; font-size: 11px; font-weight: 850; line-height: 1; letter-spacing: 0.12em; text-transform: uppercase; }
.readiness-copy > span,
.readiness-copy > strong,
.readiness-copy > b { min-width: 0; display: block; overflow: hidden; white-space: nowrap; }
.readiness-copy > span,
.readiness-copy > strong { -webkit-mask-image: linear-gradient(90deg, #000 0%, #000 82%, transparent 100%); mask-image: linear-gradient(90deg, #000 0%, #000 82%, transparent 100%); }
.readiness-copy strong { color: var(--readiness-accent); font-size: 11px; text-align: right; text-shadow: 0 0 12px color-mix(in srgb, var(--readiness-color) 72%, transparent); transition: color 240ms ease, text-shadow 240ms ease; }
.readiness-copy b { min-width: 38px; color: #aeb2bb; font-size: 11px; font-variant-numeric: tabular-nums; letter-spacing: 0.04em; text-align: right; }
.readiness-track { height: 7px; margin-top: 8px; overflow: hidden; border-radius: 99px; background: rgba(255, 255, 255, 0.055); }
.readiness-track i { position: relative; display: block; min-width: 3px; height: 100%; border-radius: inherit; background: linear-gradient(90deg, color-mix(in srgb, var(--readiness-color) 72%, #111), var(--readiness-accent)); box-shadow: 0 0 12px color-mix(in srgb, var(--readiness-accent) 62%, transparent); transition: width 220ms ease, background 240ms ease, box-shadow 240ms ease; }
.analysis-stage:not(.is-ready) .readiness-track i { animation: readiness-bar-pulse 1.35s ease-in-out infinite; }
.analysis-stage.is-ready > .readiness-meter { opacity: 0; transform: translateY(-5px) scale(0.985); pointer-events: none; }
.analysis-stage.is-ready:not(.is-celebrating) > .signal-note { opacity: 1; transform: translateY(0) scale(1); pointer-events: auto; transition-delay: 120ms; }
.readiness-success { min-height: 58px; padding: 12px; display: flex; gap: 10px; align-items: center; border: 1px solid color-mix(in srgb, var(--readiness-accent) 28%, rgba(220, 197, 122, 0.1)); border-radius: 12px; background: linear-gradient(135deg, color-mix(in srgb, var(--readiness-accent) 20%, transparent) 0%, rgba(18, 19, 26, 0.96) 42%, color-mix(in srgb, var(--readiness-color) 18%, rgba(13, 14, 20, 0.98)) 100%); box-shadow: inset 0 1px rgba(255, 255, 255, 0.1), inset 0 0 24px color-mix(in srgb, var(--readiness-color) 13%, transparent), 0 0 18px color-mix(in srgb, var(--readiness-color) 10%, transparent); overflow: hidden; }
.readiness-success::before { content: ""; position: absolute; inset: 0; background: linear-gradient(122deg, rgba(255, 255, 255, 0.14), rgba(255, 255, 255, 0.03) 25%, transparent 48%, color-mix(in srgb, var(--readiness-accent) 12%, transparent)); pointer-events: none; }
.readiness-success::after { content: ""; position: absolute; inset: -30% auto -30% -42%; width: 38%; background: linear-gradient(90deg, transparent, rgba(255, 208, 110, 0.62), rgba(255, 255, 255, 0.72), transparent); transform: skewX(-18deg); pointer-events: none; }
.analysis-stage.is-celebrating > .readiness-success { animation: readiness-success-lifecycle 1.9s ease forwards; }
.analysis-stage.is-celebrating > .readiness-success::after { animation: readiness-success-burn 1.9s ease-in forwards; }
.analysis-stage.is-celebrating > .readiness-success > span { animation: readiness-success-icon 1.35s cubic-bezier(0.18, 0.9, 0.25, 1) both; }
.analysis-stage.is-celebrating > .readiness-success strong { animation: readiness-success-copy 1.5s ease both; }
.readiness-success > span { position: relative; z-index: 1; width: 30px; height: 30px; flex: 0 0 auto; display: grid; place-items: center; border: 1px solid color-mix(in srgb, var(--readiness-accent) 42%, transparent); border-radius: 10px; background: color-mix(in srgb, var(--readiness-color) 62%, rgba(255, 255, 255, 0.08)); color: var(--readiness-accent); box-shadow: 0 0 13px color-mix(in srgb, var(--readiness-color) 45%, transparent); font-size: 15px; font-weight: 900; }
.readiness-success p { position: relative; z-index: 1; margin: 0; }
.readiness-success strong { display: block; color: var(--readiness-accent); font-size: 10px; letter-spacing: 0.13em; }
.readiness-success small { display: block; margin-top: 3px; color: #969da7; font-size: 11px; line-height: 1.35; }
.road-card { --road-bead-size: clamp(30px, 8.6vw, 38px); --road-gap: clamp(4px, 1.4vw, 7px); position: relative; min-height: 0; padding: 14px; display: flex; flex: 1 1 0; flex-direction: column; background: linear-gradient(145deg, var(--road-wash), transparent 43%), linear-gradient(180deg, var(--road-surface-top), var(--road-surface-bottom)); box-shadow: 0 18px 48px rgba(0, 0, 0, 0.24), inset 0 1px rgba(116, 196, 255, 0.035); transition: background 280ms ease; }
.section-title-row h2, .input-copy h2 { font-size: 20px; line-height: 1; }
.input-copy h2 { margin: 0; }
.road-heading-stack { min-width: 0; display: grid; gap: 4px; }
.predictor-label { margin: 0; color: color-mix(in srgb, var(--accent) 80%, white); font-size: 16px; line-height: 1; font-weight: 900; letter-spacing: 0.08em; text-transform: uppercase; text-shadow: 0 0 14px color-mix(in srgb, var(--accent) 22%, transparent); }
.road-title { color: color-mix(in srgb, var(--player) 28%, #d0d2d8); font-size: 11px; letter-spacing: 0.13em; white-space: nowrap; }
.road-actions { gap: 7px; }
.road-actions span { color: #777e89; font-size: 11px; font-weight: 700; }
.road-actions button { position: relative; min-width: 48px; min-height: 44px; padding: 7px 9px; border: 1px solid var(--line); border-radius: 9px; background: rgba(255, 255, 255, 0.025); color: #9297a1; font-size: 11px; cursor: pointer; overflow: hidden; }
.road-actions button:disabled { opacity: 0.35; cursor: default; }
.road-actions button:not(:disabled)::after { content: ""; position: absolute; top: -45%; bottom: -45%; left: -45%; width: 34%; background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.48), transparent); transform: translateX(-170%) skewX(-18deg); pointer-events: none; animation: utility-glint 9.4s ease-in-out infinite; }
.road-actions button:not(:disabled):nth-of-type(2)::after { animation-duration: 12.7s; animation-delay: 2.9s; }

.phone .road-card {
  border-color: color-mix(in srgb, var(--accent) 22%, transparent);
  border-radius: 13px;
  background:
    linear-gradient(145deg, color-mix(in srgb, var(--accent) 9%, transparent), transparent 35%),
    radial-gradient(circle at 95% 5%, color-mix(in srgb, var(--player) 19%, transparent), transparent 36%),
    color-mix(in srgb, var(--road-surface-bottom) 86%, #07090d);
  box-shadow: 0 20px 50px rgba(3, 0, 8, 0.48), inset 0 1px rgba(255, 232, 171, 0.08);
}

.phone .road-window { border-color: color-mix(in srgb, var(--accent) 12%, transparent); border-radius: 9px; }
.phone .road-grid { background: linear-gradient(color-mix(in srgb, var(--accent) 3.8%, transparent) 1px, transparent 1px), linear-gradient(90deg, color-mix(in srgb, var(--accent) 3.8%, transparent) 1px, transparent 1px); background-size: var(--road-cell-size) var(--road-cell-size); }
.phone .road-bead { border-radius: 10px; box-shadow: 0 0 0 1px color-mix(in srgb, var(--accent) 36%, transparent), inset 0 0 0 2px rgba(10, 5, 15, 0.24), inset 0 1px rgba(255, 255, 255, 0.3), 0 7px 14px rgba(0, 0, 0, 0.54); }
.phone .road-bead::before,
.phone .road-bead.is-chain::after { border-radius: 10px; }

.road-window {
  min-height: 82px;
  margin-top: 10px;
  padding: 8px 11px 8px 8px;
  flex: 1 1 auto;
  overflow-x: hidden;
  overflow-y: auto;
  scrollbar-color: rgba(255, 92, 102, 0.72) rgba(255, 255, 255, 0.045);
  scrollbar-width: thin;
  border: 1px solid rgba(255, 255, 255, 0.055);
  border-radius: 15px;
  background: var(--road-canvas);
  transition: background 280ms ease;
}

.road-window::-webkit-scrollbar { width: 5px; }
.road-window::-webkit-scrollbar-track { border-radius: 99px; background: rgba(255, 255, 255, 0.045); }
.road-window::-webkit-scrollbar-thumb { border-radius: 99px; background: linear-gradient(var(--accent), var(--banker)); }
.road-grid { --road-cell-size: calc(var(--road-bead-size) + var(--road-gap)); width: max-content; min-height: 100%; margin-inline: auto; display: grid; grid-template-columns: repeat(7, var(--road-cell-size)); grid-auto-flow: row; grid-auto-rows: var(--road-cell-size); align-content: start; justify-content: center; background: linear-gradient(rgba(255, 255, 255, 0.026) 1px, transparent 1px), linear-gradient(90deg, rgba(255, 255, 255, 0.026) 1px, transparent 1px); background-size: var(--road-cell-size) var(--road-cell-size); }
.road-bead { --bead-glow: rgba(255, 255, 255, 0.12); position: relative; z-index: 1; isolation: isolate; width: var(--road-bead-size); height: var(--road-bead-size); align-self: center; justify-self: center; display: grid; place-items: center; border-radius: 50%; color: #fff; font-size: clamp(12px, 3.4vw, 15px); font-weight: 900; box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.045), inset 0 1px rgba(255, 255, 255, 0.25), 0 6px 12px rgba(0, 0, 0, 0.46); overflow: visible; animation: none; }
.road-bead::before { content: ""; position: absolute; z-index: -1; inset: -3px; border-radius: 50%; background: var(--bead-glow); filter: blur(3px); opacity: 0; pointer-events: none; animation: none; }
.road-bead.is-latest { z-index: 3; animation: bead-arrive 780ms cubic-bezier(0.18, 0.9, 0.25, 1); }
.road-bead.is-pattern:not(.is-latest) { z-index: 2; animation: pattern-breathe 1.75s ease-in-out var(--pattern-phase, 0ms) infinite both; }
.road-bead.is-pattern.is-latest { animation: bead-arrive 780ms cubic-bezier(0.18, 0.9, 0.25, 1), pattern-breathe 1.75s ease-in-out var(--pattern-phase, 0ms) infinite both; }
.road-bead.is-active-pattern:not(.is-latest) { animation: pattern-breathe 1.75s ease-in-out var(--pattern-phase, 0ms) infinite both, bead-glow 3.4s ease-in-out infinite; }
.road-bead.is-active-pattern.is-latest { animation: bead-arrive 780ms cubic-bezier(0.18, 0.9, 0.25, 1), pattern-breathe 1.75s ease-in-out var(--pattern-phase, 0ms) infinite both, bead-glow 3.4s ease-in-out infinite; }
.road-bead.is-active-pattern::before { animation: bead-halo-breathe 3.4s ease-in-out infinite; }
.road-bead.is-chain::after { content: ""; position: absolute; z-index: 2; inset: 0; border-radius: 50%; background: radial-gradient(circle, rgba(255, 255, 255, 0.68) 0 1.4px, transparent 1.9px), radial-gradient(circle, rgba(255, 235, 177, 0.66) 0 1.1px, transparent 1.7px), linear-gradient(105deg, transparent 28%, rgba(255, 255, 255, 0.63) 48%, rgba(255, 236, 181, 0.49) 54%, transparent 72%); background-repeat: no-repeat; background-size: 7px 7px, 5px 5px, 46% 160%; background-position: 118% 20%, 126% 76%, 145% 50%; filter: drop-shadow(0 0 3px rgba(255, 255, 255, 0.55)); pointer-events: none; animation: chain-glint 4.2s linear calc(var(--chain-phase, 0ms) + var(--chain-order, 0) * 110ms) infinite both; }
.road-bead.banker { --bead-glow: color-mix(in srgb, var(--banker) 25%, transparent); background: linear-gradient(145deg, color-mix(in srgb, var(--banker) 78%, white), color-mix(in srgb, var(--banker) 78%, #13151a)); }
.road-bead.player { --bead-glow: color-mix(in srgb, var(--player) 25%, transparent); background: linear-gradient(145deg, color-mix(in srgb, var(--player) 78%, white), color-mix(in srgb, var(--player) 78%, #13151a)); }
.road-bead.tie { --bead-glow: color-mix(in srgb, var(--tie) 23%, transparent); background: linear-gradient(145deg, color-mix(in srgb, var(--tie) 78%, white), color-mix(in srgb, var(--tie) 78%, #13151a)); }
.road-empty { grid-column: 1 / -1; min-height: 100%; width: 100%; display: flex; align-items: center; justify-content: center; gap: 7px; color: #5c626d; font-size: 12px; }
.road-empty span { width: 20px; height: 20px; display: grid; place-items: center; border: 1px dashed #414650; border-radius: 50%; }
.shoe-stats { margin-top: 10px; display: grid; grid-template-columns: repeat(4, 1fr); gap: 7px; }
.shoe-stats span { padding: 8px 5px; border-radius: 9px; background: rgba(255, 255, 255, 0.025); color: #7e8794; text-align: center; font-size: 11px; font-weight: 700; }
.shoe-stats span i { color: inherit; font-style: normal; }
.phone[data-game="andar-bahar"] .shoe-stats { grid-template-columns: repeat(3, 1fr); }
.shoe-stats b { margin-left: 3px; color: #c0c3ca; font-variant-numeric: tabular-nums; }

.hand-workspace { min-height: 0; margin-top: 10px; display: flex; flex: 1 1 auto; flex-direction: column; gap: 8px; }
.hand-cards { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.hand-card-slot { position: relative; min-height: 88px; padding: 8px; display: grid; place-items: center; align-content: center; gap: 3px; overflow: hidden; border: 1px solid color-mix(in srgb, var(--accent) 18%, transparent); border-radius: 9px; background: linear-gradient(145deg, color-mix(in srgb, var(--accent) 6%, rgba(255,255,255,0.035)), rgba(5, 3, 10, 0.58)); color: #766b7c; cursor: pointer; clip-path: polygon(5px 0, calc(100% - 5px) 0, 100% 5px, 100% calc(100% - 5px), calc(100% - 5px) 100%, 5px 100%, 0 calc(100% - 5px), 0 5px); transition: transform 150ms ease, border-color 180ms ease, box-shadow 180ms ease; }
.hand-card-slot::after { content: ""; position: absolute; inset: 0; background: linear-gradient(125deg, rgba(255,255,255,0.11), transparent 32%); pointer-events: none; }
.hand-card-slot:active { transform: scale(0.95); }
.hand-card-slot.is-active { border-color: color-mix(in srgb, var(--accent) 58%, transparent); box-shadow: inset 0 0 18px color-mix(in srgb, var(--player) 10%, transparent), 0 0 14px color-mix(in srgb, var(--accent) 12%, transparent); }
.hand-card-slot > span { width: 28px; height: 28px; display: grid; place-items: center; border: 1px dashed currentColor; border-radius: 7px; font-size: 13px; font-weight: 900; }
.hand-card-slot small { color: #786f82; font-size: 9px; font-weight: 800; letter-spacing: 0.04em; text-transform: uppercase; }
.hand-card-slot.is-filled { grid-template-columns: auto auto; grid-template-rows: auto auto; background: linear-gradient(145deg, #f8edcf, #d8c694 64%, #9f884d); color: #221525; box-shadow: inset 0 1px white, 0 8px 18px rgba(0,0,0,0.36); }
.hand-card-slot.is-filled strong { font-family: Georgia, serif; font-size: 28px; line-height: 1; }
.hand-card-slot.is-filled b { font-size: 27px; line-height: 1; }
.hand-card-slot.is-filled small { grid-column: 1 / -1; color: rgba(34,21,37,0.58); font-size: 8px; }
.hand-card-slot.is-filled.is-red strong, .hand-card-slot.is-filled.is-red b { color: #b71949; }
.hand-summary { min-height: 42px; padding: 8px 10px; display: flex; gap: 10px; align-items: center; justify-content: space-between; border: 1px solid color-mix(in srgb, var(--accent) 12%, transparent); border-radius: 8px; background: linear-gradient(110deg, color-mix(in srgb, var(--player) 9%, transparent), rgba(4,3,8,0.4)); }
.hand-summary p { min-width: 0; margin: 0; }
.hand-summary p strong, .hand-summary p span { display: block; white-space: nowrap; }
.hand-summary p strong { color: #f2e9d0; font-size: 12px; }
.hand-summary p span { margin-top: 2px; color: #988ca1; font-size: 10px; }
.hand-metrics { display: flex; gap: 7px; }
.hand-metrics span { color: #736a7c; font-size: 8px; font-weight: 800; text-transform: uppercase; white-space: nowrap; }
.hand-metrics b { display: block; margin-top: 2px; color: #d6c7a4; font-size: 10px; text-align: right; }
.hand-session { min-height: 34px; display: flex; gap: 8px; align-items: center; justify-content: space-between; }
.hand-session-road { min-width: 0; display: flex; flex: 1; gap: 4px; overflow: hidden; }
.hand-session-empty { color: #665e6c; font-size: 10px; font-weight: 700; }
.session-result { width: 24px; height: 24px; flex: 0 0 auto; display: grid; place-items: center; border-radius: 6px; color: #fff; font-size: 9px; font-weight: 900; box-shadow: inset 0 1px rgba(255,255,255,0.2); }
.session-result.player { background: var(--player); }
.session-result.banker { background: var(--banker); }
.session-result.tie { background: var(--tie); color: #201722; }
.session-result.is-latest { outline: 1px solid color-mix(in srgb, var(--accent) 56%, transparent); outline-offset: 2px; }
.hand-outcome-actions { display: flex; align-items: center; gap: 3px; }
.hand-outcome-actions > span { margin-right: 3px; color: #726a7a; font-size: 8px; font-weight: 850; text-transform: uppercase; }
.hand-outcome-actions button { min-height: 28px; padding: 0 7px; border: 1px solid color-mix(in srgb, var(--accent) 13%, transparent); border-radius: 6px; background: rgba(255,255,255,0.035); color: #c6bacb; font-size: 9px; font-weight: 850; cursor: pointer; }
.hand-outcome-actions button:active { transform: scale(0.92); }
.input-zone { margin-top: 0; flex: 0 0 auto; }
.input-copy > span { color: #8b929e; font-size: 12px; font-weight: 700; }
.result-buttons { --result-label-size: 14px; margin-top: 8px; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 0.82fr) minmax(0, 1fr); gap: 6px; }
.result-buttons.is-two { grid-template-columns: repeat(2, minmax(0, 1fr)); }

.card-entry { margin-top: 8px; padding: 8px; border: 1px solid color-mix(in srgb, var(--accent) 17%, transparent); border-radius: 10px; background: linear-gradient(145deg, color-mix(in srgb, var(--player) 7%, rgba(10,5,14,0.82)), color-mix(in srgb, var(--banker) 5%, #08050b)); box-shadow: inset 0 1px rgba(255,255,255,0.05); }
.card-entry-head { min-height: 22px; display: flex; justify-content: space-between; align-items: center; }
.card-entry-head > span { color: color-mix(in srgb, var(--accent) 78%, white); font-size: 10px; font-weight: 850; letter-spacing: 0.04em; }
.card-entry-head button { padding: 3px 6px; border: 0; background: transparent; color: #746b7a; font-size: 9px; font-weight: 750; cursor: pointer; }
.rank-grid { margin-top: 5px; display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 4px; }
.rank-grid button { min-width: 0; height: 31px; padding: 0; border: 1px solid color-mix(in srgb, var(--accent) 12%, transparent); border-radius: 6px; background: rgba(255,255,255,0.04); color: #d8cedd; font-size: 12px; font-weight: 900; cursor: pointer; transition: transform 120ms ease, background 150ms ease, color 150ms ease; }
.rank-grid button:active, .suit-grid button:active { transform: scale(0.9); }
.rank-grid button.is-selected { border-color: color-mix(in srgb, var(--accent) 55%, transparent); background: linear-gradient(145deg, color-mix(in srgb, var(--player) 50%, #21142c), color-mix(in srgb, var(--banker) 25%, #130a18)); color: #fff7df; box-shadow: 0 0 11px color-mix(in srgb, var(--player) 20%, transparent); }
.suit-grid { margin-top: 5px; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 4px; }
.suit-grid button { height: 34px; padding: 0 3px; display: flex; align-items: center; justify-content: center; gap: 4px; border: 1px solid color-mix(in srgb, var(--accent) 12%, transparent); border-radius: 6px; background: rgba(255,255,255,0.035); color: #92889a; font-size: 8px; font-weight: 800; cursor: pointer; transition: opacity 150ms ease, transform 120ms ease, color 150ms ease, background 150ms ease; }
.suit-grid button span { color: #e7dfeb; font-size: 18px; line-height: 1; }
.suit-grid button[data-card-suit="H"] span, .suit-grid button[data-card-suit="D"] span { color: #ff4c79; }
.card-entry:not(.is-awaiting-suit) .suit-grid button { opacity: 0.42; }
.card-entry.is-awaiting-suit .suit-grid button { color: #d8ccdd; background: color-mix(in srgb, var(--player) 9%, rgba(255,255,255,0.035)); }
.card-entry.has-error { animation: card-entry-error 360ms ease; }

.phone[data-teen-mode="play-fold"] .road-card { min-height: 190px; flex: 0 0 190px; padding: 10px 12px; }
.phone[data-teen-mode="play-fold"] .section-title-row { min-height: 36px; }
.phone[data-teen-mode="play-fold"] .predictor-label { font-size: 14px; }
.phone[data-teen-mode="play-fold"] .road-title { font-size: 9px; }
.phone[data-teen-mode="play-fold"] .road-actions button { min-width: 43px; min-height: 36px; padding: 5px 7px; }
.phone[data-teen-mode="play-fold"] .hand-workspace { margin-top: 5px; gap: 5px; }
.phone[data-teen-mode="play-fold"] .hand-card-slot { min-height: 59px; padding: 5px; }
.phone[data-teen-mode="play-fold"] .hand-card-slot > span { width: 22px; height: 22px; font-size: 11px; }
.phone[data-teen-mode="play-fold"] .hand-card-slot small { font-size: 7px; }
.phone[data-teen-mode="play-fold"] .hand-card-slot.is-filled strong,
.phone[data-teen-mode="play-fold"] .hand-card-slot.is-filled b { font-size: 22px; }
.phone[data-teen-mode="play-fold"] .hand-summary { min-height: 39px; padding: 5px 7px; display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 5px; }
.phone[data-teen-mode="play-fold"] .hand-summary p strong { font-size: 10.5px; }
.phone[data-teen-mode="play-fold"] .hand-summary p span { font-size: 8.5px; }
.phone[data-teen-mode="play-fold"] .hand-metrics { gap: 5px; }
.phone[data-teen-mode="play-fold"] .hand-metrics span { font-size: 6.5px; }
.phone[data-teen-mode="play-fold"] .hand-metrics b { font-size: 8.5px; }
.phone[data-teen-mode="play-fold"] .hand-session { min-height: 25px; }
.phone[data-teen-mode="play-fold"] .input-copy h2 { font-size: 17px; }
.phone[data-teen-mode="play-fold"] .input-copy > span { font-size: 10px; }
.phone[data-teen-mode="play-fold"] .card-entry { margin-top: 5px; padding: 6px; }
.phone[data-teen-mode="play-fold"] .card-entry-head { min-height: 18px; }
.phone[data-teen-mode="play-fold"] .rank-grid { margin-top: 3px; gap: 3px; }
.phone[data-teen-mode="play-fold"] .rank-grid button { height: 24px; font-size: 10px; }
.phone[data-teen-mode="play-fold"] .suit-grid { margin-top: 3px; gap: 3px; }
.phone[data-teen-mode="play-fold"] .suit-grid button { height: 27px; font-size: 7px; }
.phone[data-teen-mode="play-fold"] .suit-grid button span { font-size: 14px; }
.phone[data-teen-mode="play-fold"] .product-footer { margin-top: 4px; font-size: 9px; }

.phone[data-teen-mode="play-fold"] .road-card { min-height: 154px; flex-basis: 154px; }
.phone[data-teen-mode="play-fold"] .hand-workspace { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 12px; }
.workspace-label { margin: 0 0 5px; color: color-mix(in srgb, var(--accent) 72%, white); font-size: 8px; line-height: 1; font-weight: 900; letter-spacing: 0.13em; }
.workspace-label small { margin-left: 4px; color: #716878; font-size: 6px; letter-spacing: 0.08em; }
.hand-column, .result-column { min-width: 0; }
.phone[data-teen-mode="play-fold"] .hand-cards { gap: 5px; }
.phone[data-teen-mode="play-fold"] .hand-card-slot { width: 100%; min-width: 0; min-height: 82px; padding: 4px 2px; }
.phone[data-teen-mode="play-fold"] .hand-card-slot.is-filled { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; }
.phone[data-teen-mode="play-fold"] .hand-card-slot.is-filled strong { font-size: 25px; line-height: 1; }
.phone[data-teen-mode="play-fold"] .hand-card-slot.is-filled b { font-size: 27px; line-height: 1; }
.phone[data-teen-mode="play-fold"] .hand-card-slot > span { width: 26px; height: 26px; }
.result-column-head { height: 14px; display: flex; align-items: flex-start; justify-content: space-between; }
.pattern-toggle { position: relative; display: flex; align-items: center; gap: 4px; color: #766d7e; font-size: 6px; font-weight: 900; letter-spacing: 0.08em; cursor: pointer; }
.pattern-toggle input { position: absolute; opacity: 0; pointer-events: none; }
.pattern-toggle span { width: 13px; height: 13px; display: grid; place-items: center; border: 1px solid color-mix(in srgb, var(--accent) 27%, transparent); border-radius: 4px; background: rgba(255,255,255,0.035); }
.pattern-toggle input:checked + span { border-color: color-mix(in srgb, var(--tie) 65%, transparent); background: color-mix(in srgb, var(--tie) 32%, #0d1110); box-shadow: 0 0 8px color-mix(in srgb, var(--tie) 30%, transparent); }
.pattern-toggle input:checked + span::after { content: "✓"; color: #fff; font-size: 9px; font-weight: 900; }
.pattern-toggle input:checked ~ b { color: color-mix(in srgb, var(--tie) 76%, white); }
.phone[data-teen-mode="play-fold"] .hand-outcome-actions { margin-top: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 5px; }
.phone[data-teen-mode="play-fold"] .hand-outcome-actions button { min-width: 0; min-height: 82px; padding: 4px 2px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 5px; border-radius: 9px; text-align: center; opacity: 0.38; clip-path: polygon(5px 0, calc(100% - 5px) 0, 100% 5px, 100% calc(100% - 5px), calc(100% - 5px) 100%, 5px 100%, 0 calc(100% - 5px), 0 5px); transition: transform 120ms ease, opacity 180ms ease, border-color 180ms ease, background 180ms ease; }
.phone[data-teen-mode="play-fold"] .hand-outcome-actions.is-ready button { opacity: 1; }
.phone[data-teen-mode="play-fold"] .hand-outcome-actions button b { color: var(--accent); font-family: Georgia, serif; font-size: 24px; line-height: 1; }
.phone[data-teen-mode="play-fold"] .hand-outcome-actions button span { color: #d0c5d4; font-size: 9px; font-weight: 900; line-height: 1; text-transform: uppercase; }
.phone[data-teen-mode="play-fold"] .hand-outcome-actions button[data-hand-result="P"] { border-color: color-mix(in srgb, var(--player) 25%, transparent); background: color-mix(in srgb, var(--player) 8%, rgba(255,255,255,0.025)); }
.phone[data-teen-mode="play-fold"] .hand-outcome-actions button[data-hand-result="T"] { border-color: color-mix(in srgb, var(--tie) 22%, transparent); background: color-mix(in srgb, var(--tie) 6%, rgba(255,255,255,0.025)); }
.phone[data-teen-mode="play-fold"] .hand-outcome-actions button[data-hand-result="B"] { border-color: color-mix(in srgb, var(--banker) 25%, transparent); background: color-mix(in srgb, var(--banker) 8%, rgba(255,255,255,0.025)); }
.phone[data-teen-mode="play-fold"] .hand-outcome-actions button:disabled { cursor: default; }
.phone[data-teen-mode="play-fold"] .hand-session-road { height: 15px; margin-top: 4px; gap: 3px; }
.phone[data-teen-mode="play-fold"] .hand-session-road { display: none; }
.phone[data-teen-mode="play-fold"] .hand-session-empty { font-size: 7px; }
.phone[data-teen-mode="play-fold"] .session-result { width: 14px; height: 14px; border-radius: 4px; font-size: 6px; }
.phone[data-teen-mode="play-fold"] .confidence-ring small { bottom: 20px; width: 72px; overflow: hidden; color: color-mix(in srgb, var(--accent) 70%, white); font-size: 7.5px; line-height: 1; letter-spacing: 0.06em; text-align: center; text-overflow: ellipsis; white-space: nowrap; }
.phone[data-teen-mode="play-fold"] .confidence-ring.is-empty small { bottom: 21px; font-size: 9px; }
.phone[data-teen-mode="play-fold"] .input-zone { min-height: 0; display: flex; flex: 0 0 auto; flex-direction: column; }
.phone[data-teen-mode="play-fold"] .card-entry { flex: 0 0 auto; display: flex; flex-direction: column; justify-content: space-between; }
.phone[data-teen-mode="play-fold"] .card-entry-head > span { font-size: 12px; }
.phone[data-teen-mode="play-fold"] .card-entry-head button { font-size: 11px; }
.phone[data-teen-mode="play-fold"] .rank-grid button { height: 31px; font-size: 14px; }
.phone[data-teen-mode="play-fold"] .suit-grid button { height: 38px; gap: 5px; font-size: 11px; }
.phone[data-teen-mode="play-fold"] .suit-grid button span { font-size: 20px; }
.phone[data-teen-mode="play-fold"] .product-footer { margin-top: auto; padding-top: 5px; }

.result-button {
  min-width: 0;
  min-height: 48px;
  padding: 5px 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  border: 1px solid transparent;
  border-radius: 15px;
  color: #fff;
  font-size: var(--result-label-size);
  font-weight: 800;
  cursor: pointer;
  transition: transform 160ms cubic-bezier(0.2, 0.9, 0.25, 1), filter 160ms ease;
  box-shadow: inset 0 1px rgba(255, 255, 255, 0.2), 0 10px 20px rgba(0, 0, 0, 0.2);
}

.result-button:active { transform: scale(0.91); filter: brightness(1.14) saturate(1.12); }
.result-button span { width: 26px; height: 26px; flex: 0 0 26px; display: grid; place-items: center; border-radius: 50%; background: rgba(0, 0, 0, 0.14); font-size: 11px; }
.result-button strong { min-width: 0; max-height: 2.15em; overflow: hidden; font-size: inherit; line-height: 1.05; overflow-wrap: anywhere; text-align: center; white-space: normal; }
.result-button.banker { background: linear-gradient(145deg, color-mix(in srgb, var(--banker) 86%, white), color-mix(in srgb, var(--banker) 76%, #11151a)); }
.result-button.player { background: linear-gradient(145deg, color-mix(in srgb, var(--player) 86%, white), color-mix(in srgb, var(--player) 76%, #11151a)); }
.result-button.tie { background: linear-gradient(145deg, color-mix(in srgb, var(--tie) 86%, white), color-mix(in srgb, var(--tie) 70%, #11151a)); }
.phone .result-button { border-color: color-mix(in srgb, var(--accent) 28%, transparent); border-radius: 9px; clip-path: polygon(5px 0, calc(100% - 5px) 0, 100% 5px, 100% calc(100% - 5px), calc(100% - 5px) 100%, 5px 100%, 0 calc(100% - 5px), 0 5px); }
.phone .result-button span { border: 1px solid color-mix(in srgb, var(--accent) 30%, transparent); border-radius: 7px; }
.product-footer { margin: 8px auto 0; display: flex; gap: 4px; align-items: center; justify-content: center; color: #4f545e; font-size: 11px; line-height: 1.4; }
.product-footer button { padding: 0; border: 0; border-bottom: 1px solid rgba(151, 156, 166, 0.35); background: transparent; color: #8d929c; font-size: inherit; cursor: pointer; }

.modal-backdrop {
  position: absolute;
  inset: 0;
  z-index: 10;
  display: flex;
  align-items: flex-end;
  padding: 12px;
  background: rgba(3, 4, 6, 0.72);
  backdrop-filter: blur(8px);
}

.info-sheet { width: 100%; padding: 10px 20px 20px; border: 1px solid var(--line); border-radius: 24px; background: #181a20; box-shadow: 0 -20px 70px rgba(0, 0, 0, 0.5); }
.sheet-handle { width: 38px; height: 4px; display: block; margin: 0 auto 20px; border-radius: 99px; background: #3b3f47; }
.info-sheet h2 { font-size: 24px; }
.info-sheet > p:not(.section-kicker) { color: #8e939d; font-size: 13px; line-height: 1.6; }
.info-sheet button { width: 100%; height: 48px; margin-top: 8px; border: 0; border-radius: 13px; background: #f1f2f4; color: #101216; font-size: 12px; font-weight: 850; cursor: pointer; }

@media (min-width: 480px) {
  .phone { width: min(calc(100% - 24px), 500px); }
  .road-card { --road-bead-size: 38px; --road-gap: 7px; }
  .road-grid { grid-template-columns: repeat(9, var(--road-cell-size)); }
}

@media (min-width: 560px) {
  .phone { width: min(calc(100% - 32px), 580px); border-inline: 1px solid rgba(255, 255, 255, 0.05); box-shadow: 0 40px 100px rgba(0, 0, 0, 0.65); }
  .road-grid { grid-template-columns: repeat(11, var(--road-cell-size)); }
}

@media (max-height: 730px) {
  .phone { gap: 8px; padding-top: 8px; }
  .signal-card { padding: 10px 18px 15px; }
  .game-switcher { margin-bottom: 7px; }
  .signal-core { margin-top: 12px; grid-template-columns: 124px 1fr; }
  .confidence-ring { width: 116px; height: 116px; }
  .confidence-ring strong { font-size: 34px; }
  .confidence-ring > div > span { top: calc(50% - 20px); left: calc(50% + 25px); }
  .confidence-ring small { bottom: 26px; }
  .road-window { min-height: 68px; }
  .shoe-stats { display: none; }
  .phone[data-teen-mode="play-fold"] .hand-card-slot,
  .phone[data-teen-mode="play-fold"] .hand-outcome-actions button { min-height: 68px; }
  .phone[data-teen-mode="play-fold"] .hand-summary { min-height: 36px; padding-block: 5px; }
  .phone[data-teen-mode="play-fold"] .rank-grid button { height: 29px; }
  .phone[data-teen-mode="play-fold"] .suit-grid button { height: 34px; }
  .phone[data-teen-mode="play-fold"] .product-footer { margin-top: 4px; }
}

@media (max-width: 380px) {
  .signal-core { grid-template-columns: 126px 1fr; gap: 12px; }
  .confidence-ring { width: 120px; height: 120px; }
  .confidence-ring strong { font-size: 35px; }
  .probability-list { gap: 11px; }
  .game-switcher button { gap: 3px; padding-inline: 3px; font-size: 10.5px; }
  .result-buttons { gap: 4px; }
  .result-button { padding-inline: 4px; gap: 4px; }
  .result-button span { width: 23px; height: 23px; flex-basis: 23px; font-size: 10px; }
}

@media (max-width: 430px) {
  .road-actions > span { display: none; }
}

/* Play / Fold uses the available phone height instead of fixed card rows. */
.phone[data-game="teen-patti"] .teen-mode-switch { grid-template-columns: 1.25fr 0.8fr; }
.phone[data-teen-mode="play-fold"] .road-card {
  min-height: clamp(142px, 21dvh, 188px);
  max-height: 232px;
  flex: 1 1 188px;
}
.phone[data-teen-mode="play-fold"] .hand-workspace {
  min-height: 0;
  flex: 1 1 auto;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 18px;
  align-items: stretch;
}
.phone[data-teen-mode="play-fold"] .hand-column,
.phone[data-teen-mode="play-fold"] .result-column { height: 100%; min-height: 0; display: flex; flex-direction: column; }
.phone[data-teen-mode="play-fold"] .hand-column { padding-left: 2px; }
.phone[data-teen-mode="play-fold"] .result-column { padding-right: 2px; }
.phone[data-teen-mode="play-fold"] .hand-cards,
.phone[data-teen-mode="play-fold"] .hand-outcome-actions { flex: 1 1 auto; height: auto; min-height: 0; }
.phone[data-teen-mode="play-fold"] .hand-card-slot,
.phone[data-teen-mode="play-fold"] .hand-outcome-actions button { min-height: 0; height: 100%; }
.phone[data-teen-mode="play-fold"] .rank-grid button { height: clamp(31px, 4.15dvh, 38px); }
.phone[data-teen-mode="play-fold"] .suit-grid button { height: clamp(38px, 5dvh, 46px); }
.phone[data-teen-mode="play-fold"] .road-title { display: none; }
.phone[data-teen-mode="play-fold"] .group-caption { flex: 0 0 auto; margin: 5px 1px 0; color: #746b7c; font-size: 8px; line-height: 1; font-weight: 900; letter-spacing: 0.12em; text-transform: uppercase; }
.phone[data-game="teen-patti"] .teen-mode-switch[data-active-mode="twenty"] button[data-teen-mode="play-fold"] { justify-content: flex-start; padding-left: 6px; text-align: left; opacity: 0.58; -webkit-mask-image: linear-gradient(90deg, #000 0%, #000 35%, rgba(0,0,0,0.5) 58%, transparent 88%); mask-image: linear-gradient(90deg, #000 0%, #000 35%, rgba(0,0,0,0.5) 58%, transparent 88%); }
.phone[data-teen-mode="play-fold"] .group-caption { margin-top: 10px; font-size: 10px; letter-spacing: 0.13em; }
.phone[data-teen-mode="play-fold"] .input-copy { padding-block: clamp(3px, 0.75dvh, 7px); }
.phone[data-teen-mode="play-fold"] .card-entry { margin-top: clamp(5px, 0.9dvh, 9px); }

.section-kicker,
.predictor-label,
.road-title,
.input-copy h2,
.group-caption,
.probability-label span,
.road-actions > span,
.card-entry-head > span { min-width: 0; overflow: hidden; white-space: nowrap; -webkit-mask-image: linear-gradient(90deg, #000 0%, #000 90%, transparent 100%); mask-image: linear-gradient(90deg, #000 0%, #000 90%, transparent 100%); }

@media (max-height: 620px) {
  .phone[data-teen-mode="play-fold"] .road-card { min-height: 116px; max-height: 150px; flex-basis: 132px; padding: 8px 10px; }
  .phone[data-teen-mode="play-fold"] .section-title-row { min-height: 31px; }
  .phone[data-teen-mode="play-fold"] .road-actions button { min-width: 38px; min-height: 31px; }
  .phone[data-teen-mode="play-fold"] .input-copy h2 { font-size: 15px; }
  .phone[data-teen-mode="play-fold"] .rank-grid button { height: 26px; font-size: 12px; }
  .phone[data-teen-mode="play-fold"] .suit-grid button { height: 30px; font-size: 9px; }
  .phone[data-teen-mode="play-fold"] .suit-grid button span { font-size: 17px; }
}

@keyframes live-dot {
  0%, 100% { transform: scale(0.92); box-shadow: 0 0 0 3px rgba(75, 212, 154, 0.07); opacity: 0.8; }
  50% { transform: scale(1.18); box-shadow: 0 0 0 6px rgba(75, 212, 154, 0.14), 0 0 12px rgba(75, 212, 154, 0.55); opacity: 1; }
}
@keyframes card-entry-error {
  0%, 100% { transform: translateX(0); border-color: color-mix(in srgb, var(--accent) 17%, transparent); }
  28% { transform: translateX(-4px); border-color: var(--banker); }
  62% { transform: translateX(4px); border-color: var(--banker); }
}
@keyframes readiness-bar-pulse {
  0%, 100% { filter: brightness(0.88); opacity: 0.78; }
  50% { filter: brightness(1.38) saturate(1.16); opacity: 1; }
}
@keyframes bead-arrive {
  0% { transform: scale(0.25); opacity: 0; filter: brightness(1.7); }
  42% { transform: scale(1.32); opacity: 1; filter: brightness(1.35); }
  65% { transform: scale(0.9); }
  82% { transform: scale(1.1); }
  100% { transform: scale(1); filter: brightness(1); }
}
@keyframes pattern-breathe {
  0%, 100% { scale: 0.985; filter: brightness(0.96); }
  50% { scale: 1.065; filter: brightness(1.2) saturate(1.08); }
}
@keyframes bead-glow {
  0%, 100% { box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.018), inset 0 1px rgba(255, 255, 255, 0.25), 0 6px 12px rgba(0, 0, 0, 0.42), 0 0 6px var(--bead-glow); }
  50% { box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.05), inset 0 1px rgba(255, 255, 255, 0.28), 0 7px 13px rgba(0, 0, 0, 0.48), 0 0 10px var(--bead-glow); }
}
@keyframes bead-halo-breathe {
  0%, 100% { opacity: 0.12; transform: scale(0.97); }
  50% { opacity: 0.24; transform: scale(1.04); }
}
@keyframes chain-glint {
  0%, 7% { background-position: 118% 20%, 126% 76%, 145% 50%; opacity: 0; }
  8% { background-position: 112% 20%, 120% 76%, 136% 50%; opacity: 0.7; }
  12% { background-position: -18% 20%, -28% 76%, -72% 50%; opacity: 0.7; }
  13%, 100% { background-position: -18% 20%, -28% 76%, -72% 50%; opacity: 0; }
}
@keyframes utility-glint {
  0%, 61% { transform: translateX(-170%) skewX(-18deg); opacity: 0; }
  63% { opacity: 0.8; }
  68% { transform: translateX(520%) skewX(-18deg); opacity: 0; }
  69%, 100% { transform: translateX(520%) skewX(-18deg); opacity: 0; }
}
@keyframes record-module-impact {
  0% { border-color: rgba(255, 255, 255, 0.1); box-shadow: 0 0 0 rgba(255, 255, 255, 0); }
  38% { border-color: var(--readiness-accent); box-shadow: 0 0 26px color-mix(in srgb, var(--readiness-color) 64%, transparent), inset 0 0 20px color-mix(in srgb, var(--readiness-color) 26%, transparent); }
  100% { border-color: rgba(220, 197, 122, 0.1); box-shadow: 0 0 0 rgba(255, 255, 255, 0); }
}
@keyframes record-module-sweep {
  from { transform: translateX(0) skewX(-16deg); opacity: 0; }
  22% { opacity: 1; }
  to { transform: translateX(520%) skewX(-16deg); opacity: 0; }
}
@keyframes record-badge-impact {
  0% { transform: scale(0.72); opacity: 0.45; }
  44% { transform: scale(1.28); opacity: 1; }
  68% { transform: scale(0.94); }
  100% { transform: scale(1); opacity: 1; }
}
@keyframes readiness-success-lifecycle {
  0% { opacity: 0; transform: translateY(4px) scale(0.985); filter: brightness(0.9); }
  12%, 68% { opacity: 1; transform: translateY(0) scale(1); filter: brightness(1); }
  82% { opacity: 1; transform: translateY(0) scale(1.01); filter: brightness(1.35); }
  100% { opacity: 0; transform: translateY(-3px) scale(0.985); filter: brightness(1.75) blur(1.5px); }
}
@keyframes readiness-success-burn {
  0%, 56% { transform: translateX(0) skewX(-18deg); opacity: 0; }
  64% { opacity: 1; }
  88%, 100% { transform: translateX(520%) skewX(-18deg); opacity: 0; }
}
@keyframes readiness-success-icon {
  0% { transform: scale(0.7) rotate(-8deg); opacity: 0; }
  35% { transform: scale(1.16) rotate(3deg); opacity: 1; }
  62% { transform: scale(0.96) rotate(0); }
  100% { transform: scale(1); opacity: 1; }
}
@keyframes readiness-success-copy {
  0% { opacity: 0; transform: translateX(-5px); text-shadow: none; }
  32%, 74% { opacity: 1; transform: translateX(0); text-shadow: 0 0 14px color-mix(in srgb, var(--readiness-accent) 72%, transparent); }
  100% { opacity: 1; text-shadow: 0 0 5px color-mix(in srgb, var(--readiness-accent) 32%, transparent); }
}

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

/* Middle brand: local visual revision, September 2026. */
.middle-brand {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  gap: 13px;
  min-height: 66px;
  padding: 5px 10px;
  isolation: isolate;
}
.middle-brand::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 8%;
  right: 8%;
  height: 1px;
  background: linear-gradient(90deg, transparent, color-mix(in srgb, var(--logo-a) 28%, transparent), color-mix(in srgb, var(--logo-c) 28%, transparent), transparent);
  box-shadow: 0 2px 9px color-mix(in srgb, var(--logo-b) 10%, transparent);
}
.middle-brand-mark {
  width: 55px;
  height: 49px;
  flex: 0 0 auto;
  background: linear-gradient(135deg, var(--logo-a), var(--logo-b) 52%, var(--logo-c));
  mask: url("./nxthand-mark.svg") center / contain no-repeat;
  -webkit-mask: url("./nxthand-mark.svg") center / contain no-repeat;
  filter: drop-shadow(0 0 4px color-mix(in srgb, var(--logo-b) 15%, transparent));
}
.middle-brand-name {
  color: #c9d0df;
  font-size: clamp(27px, 8vw, 38px);
  font-weight: 650;
  line-height: 1;
  letter-spacing: .035em;
  white-space: nowrap;
  background: linear-gradient(110deg, transparent 42%, #ffffff99 49%, transparent 56%) 100% 0 / 280% 100%, linear-gradient(135deg, var(--logo-a), var(--logo-b) 52%, var(--logo-c)) 0 0 / 100% 100%;
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  text-shadow: 0 0 12px color-mix(in srgb, var(--logo-b) 8%, transparent);
  animation: middle-brand-glint 7s ease-in-out infinite;
}
@keyframes middle-brand-glint {
  0%, 72% { background-position: 100% 0, 0 0; }
  94%, 100% { background-position: 0% 0, 0 0; }
}
@media (max-height: 730px) {
  .phone { overflow-y: auto; }
  .phone:not([data-teen-mode="play-fold"]) .road-card { flex: 1 0 150px; min-height: 150px; }
  .input-zone { flex: 0 0 auto; }
  .middle-brand { min-height: 48px; gap: 10px; padding-block: 2px; }
  .middle-brand-mark { width: 43px; height: 38px; }
  .middle-brand-name { font-size: 27px; }
}
@media (prefers-reduced-motion: reduce) {
  .middle-brand-name { animation: none; }
}

/* Recognized ordinary-game case: fine outline without changing bead geometry. */
.phone:not([data-teen-mode="play-fold"]) .road-bead.is-recognized-case {
  outline: 1px solid color-mix(in srgb, var(--accent) 60%, white 40%);
  outline-offset: 2px;
  animation: none;
}
.phone:not([data-teen-mode="play-fold"]) .road-title.is-case-title {
  color: color-mix(in srgb, var(--accent) 45%, #ddd);
  letter-spacing: .07em;
  font-size: 10px;
}
