:root{
  --is-bg:#1e1b4b;
  --is-cyan:#22d3ee;
  --is-pink:#f472b6;
  --is-violet:#a78bfa;
  --is-amber:#fbbf24;
  --is-line:rgba(148,163,184,.18);
}
*{box-sizing:border-box;margin:0;padding:0}
body{
  background:
    radial-gradient(900px 520px at 50% -12%, rgba(34,211,238,.32), transparent 62%),
    radial-gradient(700px 420px at 110% 110%, rgba(244,114,182,.16), transparent 60%),
    linear-gradient(180deg,#14104a,#0a0728 70%,#05031a);
  color:#e0e7ff;
  font-family:"Trebuchet MS","Bahnschrift","Segoe UI",system-ui,sans-serif;
  /* The document must scroll: the guide, its h1 and the ad unit live below
     the fold, and hiding the overflow made all three unreachable. */
  overflow-x:hidden;
  -webkit-font-smoothing:antialiased;
}
.is-wrap{max-width:560px;margin:0 auto;min-height:100vh;min-height:100dvh;display:flex;flex-direction:column;gap:9px;padding:12px 12px 14px}
.is-hud{display:grid;grid-template-columns:1.4fr repeat(3,1fr);gap:8px}
.is-hud2{display:grid;grid-template-columns:1fr;gap:8px}
.is-chip{
  background:linear-gradient(180deg,rgba(30,41,59,.5),rgba(15,23,42,.78));
  border:1px solid var(--is-line);border-radius:14px;padding:7px 10px;
  display:flex;flex-direction:column;gap:2px;
  box-shadow:inset 0 1px 0 rgba(255,255,255,.06),0 8px 18px rgba(0,0,0,.4);
  backdrop-filter:blur(6px);
}
.is-chip .k{font-size:.58rem;letter-spacing:.24em;color:#67e8f9}
.is-chip .v{font-size:1.05rem;font-weight:800;color:#f0f9ff;text-shadow:0 0 12px rgba(34,211,238,.55)}
.is-brand{
  background:linear-gradient(135deg,rgba(34,211,238,.16),rgba(244,114,182,.14));
  border-color:rgba(34,211,238,.45);
}
.is-brand .v{
  font-size:.86rem;letter-spacing:.3em;
  background:linear-gradient(90deg,#22d3ee,#f472b6);
  -webkit-background-clip:text;background-clip:text;color:transparent;
}
.is-charge .v{color:#fbbf24;text-shadow:0 0 12px rgba(251,191,36,.6)}
.is-bar{height:5px;border-radius:99px;background:rgba(148,163,184,.2);overflow:hidden;margin-top:2px}
.is-bar i{display:block;height:100%;width:0%;border-radius:99px;background:linear-gradient(90deg,#22d3ee,#fbbf24);transition:width .12s linear}
.is-stage{
  position:relative;flex:1;display:flex;align-items:center;justify-content:center;
  border-radius:16px;overflow:hidden;
  /* Matches the canvas gradient so the letterbox bands read as one surface. */
  background:linear-gradient(180deg,#151046,#05031a);
  border:1px solid rgba(34,211,238,.5);
  box-shadow:0 0 0 1px rgba(0,0,0,.5),0 0 36px rgba(34,211,238,.32),inset 0 0 50px rgba(5,3,26,.95);
}
/* The buffer is 560x480. Stretching it to the stage (which used to be
   whatever height was left) distorted the whole playfield, so the canvas now
   shrinks to fit inside the stage and keeps its own ratio, centred. */
.is-stage canvas{display:block;width:auto;height:auto;max-width:100%;max-height:100%}
.is-stage::after{
  content:"";position:absolute;inset:0;pointer-events:none;
  background:
    repeating-linear-gradient(180deg,rgba(255,255,255,.025) 0 1px,transparent 1px 3px),
    radial-gradient(120% 85% at 50% 50%,transparent 52%,rgba(0,0,0,.7) 100%);
  mix-blend-mode:screen;opacity:.5;
}
.is-overlay{
  position:fixed;inset:0;z-index:20;display:flex;flex-direction:column;align-items:center;justify-content:center;
  gap:14px;text-align:center;padding:24px;
  background:radial-gradient(560px 320px at 50% 42%,rgba(34,211,238,.3),transparent 70%),linear-gradient(180deg,rgba(6,4,26,.93),rgba(3,2,15,.97));
  backdrop-filter:blur(4px);
}
.is-overlay h2{
  margin:0;font-size:clamp(1.9rem,8vw,3rem);letter-spacing:.18em;text-transform:uppercase;
  background:linear-gradient(90deg,#22d3ee,#f472b6);
  -webkit-background-clip:text;background-clip:text;color:transparent;
  filter:drop-shadow(0 0 16px rgba(34,211,238,.5));
  animation:isBob 3.2s ease-in-out infinite;
}
@keyframes isBob{0%,100%{transform:translateY(-3px)}50%{transform:translateY(3px)}}
.is-rules{
  margin:0;max-width:340px;color:#c7d2fe;font-size:.95rem;line-height:1.6;
  border-left:2px solid rgba(103,232,249,.6);padding-left:14px;text-align:left;
}
.is-btn{
  border:0;border-radius:999px;padding:14px 32px;cursor:pointer;font-weight:800;
  letter-spacing:.16em;text-transform:uppercase;font-size:.95rem;color:#0a0728;
  background:linear-gradient(135deg,#22d3ee,#a78bfa 60%,#f472b6);
  box-shadow:0 10px 30px rgba(34,211,238,.35),0 0 0 1px rgba(255,255,255,.2) inset;
  transition:transform .15s ease,box-shadow .2s ease;
}
.is-btn:hover{transform:translateY(-2px);box-shadow:0 16px 44px rgba(244,114,182,.45)}
.is-score-final{font-size:1.5rem;font-weight:800;color:#fbbf24;text-shadow:0 0 16px rgba(251,191,36,.6)}
.is-hide{display:none}
.is-pads{display:grid;grid-template-columns:repeat(3,1fr);gap:6px;max-width:280px;margin:auto auto 0}
.is-pad{
  padding:13px;border-radius:14px;cursor:pointer;border:1px solid rgba(34,211,238,.55);
  touch-action:none;user-select:none;-webkit-user-select:none;
  background:linear-gradient(180deg,rgba(15,23,42,.92),rgba(8,10,26,.92));
  color:#67e8f9;font-weight:800;font-size:1rem;
  box-shadow:0 5px 0 rgba(34,211,238,.4);
  transition:transform .1s ease,box-shadow .1s ease;
}
.is-pad:active{transform:translateY(4px);box-shadow:0 1px 0 rgba(34,211,238,.4)}
.is-pad.empty{border:0;background:none;box-shadow:none;pointer-events:none}
.is-pad.fire{grid-column:1 / -1;color:#0a0728;background:linear-gradient(135deg,#fbbf24,#f97316);border-color:rgba(251,191,36,.6);box-shadow:0 5px 0 rgba(251,191,36,.4)}
.is-pad.fire:active{box-shadow:0 1px 0 rgba(251,191,36,.4)}
@media (hover:hover){.is-pads{opacity:.4}.is-pads:hover{opacity:1}}
@media (max-width:420px){.is-chip .v{font-size:.95rem}.is-hud{gap:6px}}

/* The site grid owns the game column and adds its own padding on mobile; the
   wrap already pads itself, so keeping both only stole playfield width. */
.parent > .div18{padding:0}
/* Without this the desktop in-flow unit is auto-placed into the width of one
   side column instead of spanning the page. */
.parent > .bottom-ad{grid-column:1 / -1}
