/* ==========================================================================
   Lite Arcade — mobile-first design system
   ========================================================================== */

:root {
  --bg: #060a12;
  --bg-soft: #0a111c;
  --surface: rgba(15, 24, 38, 0.78);
  --surface-solid: #0e1725;
  --surface-2: #121e2e;
  --line: rgba(158, 180, 205, 0.13);
  --line-strong: rgba(158, 180, 205, 0.22);
  --text: #e9f0fa;
  --muted: #8b9cb3;
  --muted-2: #5f7189;
  --accent: #5eead4;
  --accent-2: #818cf8;
  --gold: #fbbf24;
  --danger: #fb7185;
  --tier: #38bdf8;
  --radius: 18px;
  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", "Inter", Roboto, "Helvetica Neue", Arial, sans-serif;
  --mono: ui-monospace, "SF Mono", "Cascadia Code", Menlo, Consolas, monospace;
  --safe-top: env(safe-area-inset-top, 0px);
  --safe-bottom: env(safe-area-inset-bottom, 0px);
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  background: var(--bg);
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  min-height: 100dvh;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.5;
  overflow-x: hidden;
  overscroll-behavior-y: contain;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  -webkit-text-size-adjust: 100%;
  text-rendering: optimizeLegibility;
}

button,
input {
  font: inherit;
  color: inherit;
}

button {
  -webkit-tap-highlight-color: transparent;
  touch-action: manipulation;
  cursor: pointer;
}

a {
  color: inherit;
  text-decoration: none;
  -webkit-tap-highlight-color: transparent;
}

h1,
h2,
h3,
p {
  margin: 0;
}

::selection {
  background: rgba(94, 234, 212, 0.3);
  color: #fff;
}

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}

.svg-sprite {
  position: absolute;
  width: 0;
  height: 0;
  overflow: hidden;
}

.icon {
  width: 1.25em;
  height: 1.25em;
  flex: none;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

#app {
  position: relative;
  z-index: 0;
  min-height: 100vh;
  min-height: 100dvh;
  isolation: isolate;
}

.bg-glow {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background:
    radial-gradient(58% 38% at 50% -8%, rgba(56, 189, 248, 0.13), transparent 68%),
    radial-gradient(46% 34% at 104% 10%, rgba(129, 140, 248, 0.1), transparent 70%),
    radial-gradient(52% 42% at -6% 62%, rgba(94, 234, 212, 0.055), transparent 70%);
}

#view {
  position: relative;
  z-index: 1;
}

#fx {
  position: fixed;
  inset: 0;
  z-index: 60;
  pointer-events: none;
}

/* --------------------------------------------------------------------------
   Shared primitives
   -------------------------------------------------------------------------- */

.screen {
  min-height: 100vh;
  min-height: 100dvh;
}

.topbar,
.game-top {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 56px;
  padding: calc(8px + var(--safe-top)) 16px 6px;
}

.topbar {
  max-width: 960px;
  margin: 0 auto;
  padding-inline: 18px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  font-size: 12.5px;
  font-weight: 750;
  letter-spacing: 0.16em;
  color: #dbe7f4;
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  border-radius: 10px;
  background: linear-gradient(145deg, var(--accent), #38bdf8 55%, var(--accent-2));
  color: #06121a;
  box-shadow: 0 6px 20px -6px rgba(56, 189, 248, 0.65);
}

.brand-icon {
  width: 17px;
  height: 17px;
  stroke-width: 2.6;
  transform: rotate(45deg);
}

.brand-text em {
  font-style: normal;
  color: var(--accent);
}

.topbar-actions,
.game-top-actions {
  display: flex;
  align-items: center;
  gap: 7px;
  margin-left: auto;
}

.icon-btn {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.035);
  color: #b9c8da;
  transition:
    background 0.18s ease,
    border-color 0.18s ease,
    transform 0.12s ease,
    color 0.18s ease;
}

.icon-btn .icon {
  width: 19px;
  height: 19px;
}

.icon-btn:hover {
  background: rgba(255, 255, 255, 0.07);
  border-color: var(--line-strong);
  color: var(--text);
}

.icon-btn:active {
  transform: scale(0.92);
}

.icon-btn:disabled {
  opacity: 0.32;
  pointer-events: none;
}

.icon-btn--small {
  width: 34px;
  height: 34px;
  border-radius: 10px;
}

.icon-btn--small .icon {
  width: 17px;
  height: 17px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  height: 46px;
  padding: 0 18px;
  border: 1px solid transparent;
  border-radius: 14px;
  font-size: 14px;
  font-weight: 680;
  letter-spacing: -0.01em;
  line-height: 1;
  white-space: nowrap;
  transition:
    transform 0.13s ease,
    filter 0.18s ease,
    background 0.18s ease,
    border-color 0.18s ease;
}

.btn .icon {
  width: 17px;
  height: 17px;
}

.btn:active {
  transform: scale(0.965);
}

.btn--primary {
  background: linear-gradient(135deg, #7ff5e1 0%, #5eead4 38%, #38bdf8 100%);
  color: #041118;
  box-shadow:
    0 12px 30px -12px rgba(94, 234, 212, 0.62),
    inset 0 1px 0 rgba(255, 255, 255, 0.45);
}

.btn--primary:hover {
  filter: brightness(1.06);
}

.btn--ghost {
  background: rgba(255, 255, 255, 0.035);
  border-color: var(--line-strong);
  color: #d5e2f1;
}

.btn--ghost:hover {
  background: rgba(255, 255, 255, 0.07);
}

.btn--lg {
  height: 52px;
  padding: 0 21px;
  border-radius: 15px;
  font-size: 14.5px;
}

.btn--small {
  height: 34px;
  padding: 0 13px;
  border-radius: 9px;
  font-size: 12px;
  background: rgba(255, 255, 255, 0.055);
  border-color: var(--line);
}

.btn--small:hover {
  background: rgba(255, 255, 255, 0.1);
}

.btn--block {
  width: 100%;
}

.btn-tier {
  margin-left: 3px;
  padding: 3px 6px;
  border-radius: 5px;
  background: rgba(4, 17, 24, 0.16);
  font-size: 8.5px;
  font-weight: 850;
  letter-spacing: 0.09em;
  text-transform: uppercase;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: var(--muted);
  font-size: 10px;
  font-weight: 650;
  letter-spacing: 0.15em;
  text-transform: uppercase;
}

.live-dot {
  display: inline-block;
  width: 6px;
  height: 6px;
  flex: none;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 0 3px rgba(94, 234, 212, 0.12);
  animation: livePulse 2.4s ease-in-out infinite;
}

.pill {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 5px 9px;
  border-radius: 7px;
  font-size: 9px;
  font-weight: 750;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.pill--live {
  border: 1px solid rgba(94, 234, 212, 0.25);
  background: rgba(94, 234, 212, 0.08);
  color: var(--accent);
}

.grad-text {
  background: linear-gradient(102deg, #8ffff0 2%, #5eead4 26%, #7dd3fc 54%, #a5b4fc 82%, #d8b4fe);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

/* Stars */
.stars {
  display: inline-flex;
  align-items: center;
  gap: 2px;
  color: rgba(148, 163, 184, 0.26);
  line-height: 1;
}

.star {
  display: inline-flex;
}

.star-icon {
  width: 1em;
  height: 1em;
  fill: currentColor;
  stroke: none;
}

.star.is-on {
  color: var(--gold);
  filter: drop-shadow(0 0 5px rgba(251, 191, 36, 0.45));
}

.stars--xs {
  font-size: 8px;
  gap: 1px;
}

.stars--sm {
  font-size: 11px;
}

.stars--lg {
  font-size: 36px;
  gap: 8px;
}

.stars--animate .star {
  transform: scale(0);
  animation: starPop 0.5s cubic-bezier(0.2, 1.5, 0.32, 1) forwards;
  animation-delay: calc(0.11s * var(--i) + 0.12s);
}

.stars-preview {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  color: var(--gold);
  font-size: 11px;
  font-weight: 600;
}

.stars-preview .icon {
  width: 13px;
  height: 13px;
  fill: var(--gold);
  stroke: none;
}

.stars-preview strong {
  font-size: 13px;
  color: var(--text);
}

/* --------------------------------------------------------------------------
   Home
   -------------------------------------------------------------------------- */

.home {
  max-width: 960px;
  margin: 0 auto;
  padding: 0 18px calc(34px + var(--safe-bottom));
}

.hero {
  padding: 34px 0 26px;
}

.hero h1 {
  margin: 16px 0 14px;
  font-size: clamp(43px, 13.2vw, 84px);
  font-weight: 840;
  letter-spacing: -0.055em;
  line-height: 0.93;
}

.hero-copy {
  max-width: 44ch;
  color: var(--muted);
  font-size: 14.5px;
  line-height: 1.68;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
  margin-top: 24px;
}

.hero-stats {
  display: flex;
  gap: 26px;
  margin-top: 30px;
  padding-top: 18px;
  border-top: 1px solid var(--line);
}

.hero-stats > div {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.hero-stats strong {
  font-size: 20px;
  font-weight: 780;
  letter-spacing: -0.03em;
  font-variant-numeric: tabular-nums;
}

.hero-stats span {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  color: var(--muted-2);
  font-size: 9.5px;
  font-weight: 600;
  letter-spacing: 0.09em;
  text-transform: uppercase;
}

.hero-stats .icon {
  width: 10px;
  height: 10px;
  fill: currentColor;
  stroke: none;
  color: var(--gold);
}

.feature-card {
  position: relative;
  display: grid;
  grid-template-columns: 1fr;
  overflow: hidden;
  padding: 24px 21px;
  border: 1px solid var(--line-strong);
  border-radius: 26px;
  background:
    linear-gradient(160deg, rgba(20, 32, 50, 0.92), rgba(9, 15, 24, 0.95)),
    var(--bg-soft);
  box-shadow:
    0 28px 70px -34px rgba(0, 0, 0, 0.9),
    inset 0 1px 0 rgba(255, 255, 255, 0.05);
}

.feature-card::before {
  content: "";
  position: absolute;
  inset: 0 0 auto;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--tier), transparent);
  opacity: 0.65;
}

.feature-glow {
  position: absolute;
  top: -80px;
  right: -60px;
  width: 300px;
  height: 300px;
  border-radius: 50%;
  background: radial-gradient(circle, color-mix(in srgb, var(--tier) 22%, transparent), transparent 65%);
  pointer-events: none;
}

.feature-copy {
  position: relative;
  z-index: 2;
}

.feature-copy h2 {
  margin: 13px 0 8px;
  font-size: 48px;
  font-weight: 830;
  letter-spacing: -0.055em;
  line-height: 0.95;
}

.feature-copy > p {
  max-width: 42ch;
  color: var(--muted);
  font-size: 13.5px;
  line-height: 1.65;
}

.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  margin-top: 14px;
}

.tag-row span {
  padding: 4px 7px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.025);
  color: #a7b7cb;
  font-size: 9px;
  font-weight: 650;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.feature-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin-top: 18px;
}

.feature-actions .btn {
  height: 43px;
  padding-inline: 16px;
  font-size: 13px;
}

.feature-footer {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 19px;
  padding-top: 13px;
  border-top: 1px solid var(--line);
  color: var(--muted-2);
  font-size: 10px;
}

.feature-art {
  position: absolute;
  top: -32px;
  right: -68px;
  z-index: 1;
  width: 250px;
  height: 250px;
  opacity: 0.26;
  pointer-events: none;
  -webkit-mask-image: radial-gradient(circle at 55% 50%, #000 20%, transparent 72%);
  mask-image: radial-gradient(circle at 55% 50%, #000 20%, transparent 72%);
}

.art-board {
  display: grid;
  grid-template-columns: repeat(4, 42px);
  gap: 7px;
  transform: rotate(-8deg);
}

.art-cell {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 11px;
  background: rgba(255, 255, 255, 0.028);
}

.art-cell--arrow {
  border-color: color-mix(in srgb, var(--tier) 32%, transparent);
  background: color-mix(in srgb, var(--tier) 9%, transparent);
  box-shadow: 0 0 22px -10px var(--tier);
}

.art-glyph {
  display: inline-flex;
  transform: rotate(var(--rot));
}

.art-arrow {
  width: 23px;
  height: 23px;
  color: color-mix(in srgb, var(--tier) 72%, white);
  stroke-width: 2.2;
  animation: floatArrow 5s ease-in-out infinite;
  animation-delay: var(--delay);
}

.art-halo {
  position: absolute;
  inset: 20% 10%;
  z-index: -1;
  border-radius: 50%;
  background: radial-gradient(circle, color-mix(in srgb, var(--tier) 28%, transparent), transparent 65%);
  filter: blur(20px);
}

.collection {
  margin-top: 34px;
}

.section-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 11px;
}

.section-head h2 {
  font-size: 17px;
  font-weight: 730;
  letter-spacing: -0.025em;
}

.section-head > span {
  color: var(--muted-2);
  font-size: 9.5px;
  font-weight: 620;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.game-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 8px;
}

.game-card {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  padding: 12px 13px;
  border: 1px solid var(--line);
  border-radius: 15px;
  background: rgba(15, 24, 38, 0.55);
  text-align: left;
  transition:
    background 0.18s ease,
    border-color 0.18s ease,
    transform 0.12s ease;
}

.game-card:active {
  transform: scale(0.987);
}

.game-card--live {
  border-color: color-mix(in srgb, var(--accent) 24%, transparent);
  background: linear-gradient(100deg, rgba(94, 234, 212, 0.07), rgba(15, 24, 38, 0.58) 55%);
}

.game-card--live:hover {
  border-color: color-mix(in srgb, var(--accent) 38%, transparent);
  background: linear-gradient(100deg, rgba(94, 234, 212, 0.1), rgba(15, 24, 38, 0.64) 55%);
}

.game-card--soon {
  opacity: 0.58;
}

.game-card-icon {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  flex: none;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.035);
  color: #9db0c6;
}

.game-card--live .game-card-icon {
  border-color: rgba(94, 234, 212, 0.22);
  background: rgba(94, 234, 212, 0.09);
  color: var(--accent);
}

.game-card-icon .icon {
  width: 20px;
  height: 20px;
  stroke-width: 2;
  transform: rotate(45deg);
}

.game-card--soon:nth-child(2) .game-card-icon .icon,
.game-card--soon:nth-child(3) .game-card-icon .icon {
  transform: none;
}

.game-card-copy {
  display: flex;
  flex-direction: column;
  gap: 1px;
  min-width: 0;
}

.game-card-copy strong {
  font-size: 13.5px;
  font-weight: 680;
  letter-spacing: -0.01em;
}

.game-card-copy small {
  overflow: hidden;
  color: var(--muted-2);
  font-size: 10.5px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.game-card-badge {
  margin-left: auto;
  padding: 3px 6px;
  border: 1px solid var(--line);
  border-radius: 5px;
  color: var(--muted-2);
  font-size: 8px;
  font-weight: 750;
  letter-spacing: 0.1em;
}

.game-card--live .game-card-badge {
  border-color: rgba(94, 234, 212, 0.25);
  color: var(--accent);
}

.home-footer {
  margin-top: 36px;
}

.home-note {
  display: flex;
  gap: 12px;
  padding: 15px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.018);
}

.home-note-icon {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  flex: none;
  border-radius: 10px;
  background: rgba(251, 191, 36, 0.08);
  color: var(--gold);
}

.home-note-icon .icon {
  width: 17px;
  height: 17px;
}

.home-note p {
  color: var(--muted);
  font-size: 11.5px;
  line-height: 1.62;
}

.home-note strong {
  color: #c9d7e7;
  font-weight: 650;
}

.install-btn {
  margin-top: 12px;
}

.copyright {
  margin-top: 24px;
  color: var(--muted-2);
  font-size: 9.5px;
  letter-spacing: 0.08em;
  text-align: center;
  text-transform: uppercase;
}

/* --------------------------------------------------------------------------
   Levels screen
   -------------------------------------------------------------------------- */

.levels-screen {
  max-width: 760px;
  margin: 0 auto;
  padding: 0 16px calc(30px + var(--safe-bottom));
}

.game-top {
  min-height: 54px;
  padding: calc(8px + var(--safe-top)) 2px 6px;
}

.game-top .icon-btn {
  flex: none;
}

.game-heading {
  flex: 1;
  min-width: 0;
  text-align: center;
  line-height: 1.1;
}

.game-mode {
  display: block;
  overflow: hidden;
  color: var(--muted-2);
  font-size: 8.5px;
  font-weight: 680;
  letter-spacing: 0.14em;
  text-overflow: ellipsis;
  text-transform: uppercase;
  white-space: nowrap;
}

.game-heading h1 {
  margin-top: 2px;
  font-size: 16.5px;
  font-weight: 730;
  letter-spacing: -0.028em;
}

.levels-hero {
  position: relative;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 14px;
  overflow: hidden;
  margin-top: 8px;
  padding: 21px;
  border: 1px solid color-mix(in srgb, var(--tier) 28%, transparent);
  border-radius: 22px;
  background:
    radial-gradient(120% 140% at 100% 0%, color-mix(in srgb, var(--tier) 14%, transparent), transparent 55%),
    linear-gradient(145deg, rgba(19, 30, 46, 0.9), rgba(10, 16, 26, 0.94));
}

.levels-hero::after {
  content: "";
  position: absolute;
  top: -54px;
  right: -30px;
  width: 160px;
  height: 160px;
  border: 1px solid color-mix(in srgb, var(--tier) 20%, transparent);
  border-radius: 50%;
  opacity: 0.6;
}

.levels-hero-copy {
  position: relative;
  z-index: 1;
  min-width: 0;
}

.levels-hero-copy h2 {
  margin: 7px 0 5px;
  font-size: clamp(30px, 8.5vw, 42px);
  font-weight: 820;
  letter-spacing: -0.05em;
  line-height: 1;
}

.levels-hero-copy p {
  max-width: 40ch;
  color: var(--muted);
  font-size: 11.5px;
  line-height: 1.6;
}

.levels-total {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1px;
  flex: none;
  padding-bottom: 2px;
}

.levels-total .icon {
  width: 19px;
  height: 19px;
  fill: var(--gold);
  stroke: none;
  filter: drop-shadow(0 0 8px rgba(251, 191, 36, 0.4));
}

.levels-total strong {
  font-size: 21px;
  font-weight: 780;
  letter-spacing: -0.03em;
  font-variant-numeric: tabular-nums;
}

.levels-total span {
  color: var(--muted-2);
  font-size: 8px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.tier-tabs {
  display: flex;
  gap: 7px;
  overflow-x: auto;
  margin: 13px -16px 0;
  padding: 0 16px 6px;
  scrollbar-width: none;
  scroll-snap-type: x proximity;
}

.tier-tabs::-webkit-scrollbar {
  display: none;
}

.tier-tab {
  display: flex;
  flex-direction: column;
  gap: 1px;
  min-width: 78px;
  flex: none;
  padding: 7px 9px;
  border: 1px solid var(--line);
  border-radius: 11px;
  background: rgba(15, 24, 38, 0.55);
  scroll-snap-align: start;
  transition:
    border-color 0.18s ease,
    background 0.18s ease;
}

.tier-tab strong {
  color: #b6c5d7;
  font-size: 10.5px;
  font-weight: 680;
  letter-spacing: -0.01em;
}

.tier-tab span {
  color: var(--muted-2);
  font-size: 8.5px;
  font-variant-numeric: tabular-nums;
}

.tier-tab.is-active {
  border-color: color-mix(in srgb, var(--accent) 45%, transparent);
  background: color-mix(in srgb, var(--accent) 10%, rgba(15, 24, 38, 0.6));
  box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--accent) 15%, transparent);
}

.tier-tab.is-active strong {
  color: var(--accent);
}

.levels-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin: 15px 0 10px;
}

.levels-range {
  display: flex;
  flex-direction: column;
  line-height: 1.3;
}

.levels-range strong {
  font-size: 13px;
  font-weight: 680;
  letter-spacing: -0.015em;
}

.levels-range span {
  color: var(--muted-2);
  font-size: 9.5px;
}

.level-jump {
  display: flex;
  align-items: center;
  gap: 6px;
}

.level-jump input {
  width: 88px;
  height: 34px;
  padding: 0 9px;
  border: 1px solid var(--line);
  border-radius: 9px;
  background: rgba(255, 255, 255, 0.035);
  color: var(--text);
  font-size: 11.5px;
  text-align: center;
  outline: none;
  -moz-appearance: textfield;
}

.level-jump input::-webkit-outer-spin-button,
.level-jump input::-webkit-inner-spin-button {
  margin: 0;
  -webkit-appearance: none;
}

.level-jump input:focus {
  border-color: color-mix(in srgb, var(--tier) 55%, transparent);
}

.level-jump input::placeholder {
  color: var(--muted-2);
}

.level-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(54px, 1fr));
  gap: 7px;
}

.level-tile {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  min-height: 56px;
  aspect-ratio: 1;
  padding: 4px;
  border: 1px solid var(--line);
  border-radius: 13px;
  background: linear-gradient(160deg, rgba(19, 30, 46, 0.72), rgba(12, 20, 32, 0.78));
  transition:
    transform 0.12s ease,
    border-color 0.18s ease,
    background 0.18s ease;
}

.level-tile:hover {
  border-color: var(--line-strong);
  background: linear-gradient(160deg, rgba(25, 39, 58, 0.85), rgba(14, 23, 36, 0.9));
}

.level-tile:active {
  transform: scale(0.94);
}

.level-num {
  color: #c2d0e0;
  font-size: 14.5px;
  font-weight: 720;
  letter-spacing: -0.02em;
  font-variant-numeric: tabular-nums;
  line-height: 1;
}

.level-tile.is-done {
  border-color: color-mix(in srgb, var(--tier) 24%, transparent);
  background: linear-gradient(160deg, color-mix(in srgb, var(--tier) 9%, rgba(19, 30, 46, 0.7)), rgba(12, 20, 32, 0.8));
}

.level-tile.is-next {
  border-color: color-mix(in srgb, var(--tier) 70%, transparent);
  background: linear-gradient(160deg, color-mix(in srgb, var(--tier) 16%, rgba(19, 30, 46, 0.8)), rgba(12, 20, 32, 0.9));
  box-shadow:
    0 0 0 1px color-mix(in srgb, var(--tier) 20%, transparent),
    0 0 28px -8px color-mix(in srgb, var(--tier) 60%, transparent);
}

.level-tile.is-next .level-num {
  color: color-mix(in srgb, var(--tier) 70%, white);
}

.level-tile.is-next .stars {
  display: none;
}

.level-next {
  color: color-mix(in srgb, var(--tier) 82%, white);
  font-size: 7px;
  font-weight: 780;
  letter-spacing: 0.09em;
  text-transform: uppercase;
}

.level-blank {
  width: 3px;
  height: 3px;
  border-radius: 50%;
  background: rgba(148, 163, 184, 0.28);
}

.pager {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  margin-top: 17px;
}

.pager .icon-btn {
  width: 36px;
  height: 36px;
  border-radius: 10px;
}

.pager .icon-btn .icon {
  width: 17px;
  height: 17px;
}

.pager span {
  min-width: 90px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 600;
  text-align: center;
}

.levels-note {
  margin-top: 18px;
  color: var(--muted-2);
  font-size: 10px;
  line-height: 1.65;
  text-align: center;
}

/* --------------------------------------------------------------------------
   Game screen
   -------------------------------------------------------------------------- */

.game-screen {
  display: flex;
  flex-direction: column;
  width: 100%;
  max-width: 560px;
  margin: 0 auto;
  min-height: 100vh;
  min-height: 100dvh;
  padding: 0 14px calc(7px + var(--safe-bottom));
}

.game-top {
  flex: none;
}

.game-stats {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  align-items: center;
  flex: none;
  padding: 8px 13px;
  border: 1px solid var(--line);
  border-radius: 13px;
  background: rgba(15, 24, 38, 0.6);
}

.stat {
  display: flex;
  flex-direction: column;
  gap: 1px;
  min-width: 0;
}

.stat--center {
  align-items: center;
}

.stat--right {
  align-items: flex-end;
}

.stat-label {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  color: var(--muted-2);
  font-size: 8.5px;
  font-weight: 620;
  letter-spacing: 0.11em;
  text-transform: uppercase;
}

.stat-label .icon {
  width: 10px;
  height: 10px;
}

.stat-value {
  color: #e4eefa;
  font-family: var(--mono);
  font-size: 14px;
  font-weight: 700;
  letter-spacing: -0.02em;
  font-variant-numeric: tabular-nums;
  line-height: 1.15;
}

.progress-track {
  flex: none;
  height: 3px;
  overflow: hidden;
  margin: 7px 3px 0;
  border-radius: 99px;
  background: rgba(255, 255, 255, 0.055);
}

.progress-fill {
  display: block;
  width: 0;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--tier), var(--accent-2));
  box-shadow: 0 0 10px color-mix(in srgb, var(--tier) 55%, transparent);
  transition: width 0.32s cubic-bezier(0.3, 0.8, 0.3, 1);
}

.board-wrap {
  display: grid;
  place-items: center;
  flex: 1 1 auto;
  min-height: 0;
  padding: 10px 0 7px;
}

.board-frame {
  position: relative;
  width: min(100%, 520px, max(210px, calc(100dvh - 268px)));
  padding: 8px;
  overflow: hidden;
  border: 1px solid color-mix(in srgb, var(--tier) 22%, var(--line));
  border-radius: 25px;
  background:
    radial-gradient(120% 100% at 50% 0%, color-mix(in srgb, var(--tier) 7%, transparent), transparent 60%),
    linear-gradient(160deg, rgba(19, 30, 46, 0.95), rgba(8, 13, 21, 0.97));
  box-shadow:
    0 30px 60px -28px rgba(0, 0, 0, 0.95),
    inset 0 1px 0 rgba(255, 255, 255, 0.055),
    0 0 60px -30px color-mix(in srgb, var(--tier) 50%, transparent);
}

.board-frame::before {
  content: "";
  position: absolute;
  inset: 0 0 auto;
  height: 1px;
  background: linear-gradient(90deg, transparent, color-mix(in srgb, var(--tier) 60%, transparent), transparent);
  pointer-events: none;
}

.board {
  display: grid;
  grid-template-columns: repeat(var(--n), 1fr);
  grid-template-rows: repeat(var(--n), 1fr);
  gap: 4px;
  width: 100%;
  aspect-ratio: 1;
  touch-action: manipulation;
  user-select: none;
  -webkit-user-select: none;
}

.tile {
  position: relative;
  border: 1px solid rgba(255, 255, 255, 0.028);
  border-radius: 16%;
  background: rgba(255, 255, 255, 0.022);
}

.tile--a {
  background: rgba(255, 255, 255, 0.038);
}

.tile.is-path {
  background: color-mix(in srgb, var(--tier) 12%, transparent);
  box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--tier) 18%, transparent);
}

.tile.is-trace {
  border-color: rgba(251, 113, 133, 0.28);
  background: rgba(251, 113, 133, 0.1);
}

.tile.is-blocker {
  border-color: rgba(251, 113, 133, 0.6);
  background: rgba(251, 113, 133, 0.2);
  box-shadow:
    inset 0 0 0 1px rgba(251, 113, 133, 0.45),
    0 0 18px -6px rgba(251, 113, 133, 0.65);
}

.tile.is-trail {
  animation: trailFlash 0.52s ease-out var(--d, 0ms) both;
}

.arrow {
  position: relative;
  z-index: 2;
  display: grid;
  place-items: center;
  width: 100%;
  height: 100%;
  padding: 0;
  border: 0;
  border-radius: 18%;
  background: transparent;
  color: color-mix(in srgb, var(--tier) 55%, #f5fffd);
  -webkit-tap-highlight-color: transparent;
}

.arrow-glyph {
  display: grid;
  place-items: center;
  width: 76%;
  height: 76%;
  transform: rotate(var(--rot));
  filter: drop-shadow(0 2px 7px color-mix(in srgb, var(--tier) 30%, transparent));
  transition:
    transform 0.16s ease,
    filter 0.16s ease;
}

.arrow-glyph svg {
  width: 100%;
  height: 100%;
  stroke-width: 2.5;
}

.arrow:hover .arrow-glyph {
  filter: drop-shadow(0 2px 9px color-mix(in srgb, var(--tier) 55%, transparent)) brightness(1.1);
}

.arrow:active .arrow-glyph {
  transform: rotate(var(--rot)) scale(0.9);
}

.arrow:focus-visible {
  outline: 2px solid var(--tier);
  outline-offset: -2px;
}

.arrow.is-flying {
  z-index: 6;
  pointer-events: none;
  transform: translate(var(--fly-x), var(--fly-y)) scale(0.55);
  opacity: 0;
  transition:
    transform 0.42s cubic-bezier(0.22, 0.7, 0.2, 1),
    opacity 0.38s ease-in;
}

.arrow.is-returning {
  animation: popIn 0.24s cubic-bezier(0.2, 1.3, 0.3, 1) both;
}

.arrow.is-denied {
  animation: shake 0.38s ease-in-out;
}

.arrow.is-hint::after {
  content: "";
  position: absolute;
  inset: 7%;
  border: 2px solid color-mix(in srgb, var(--tier) 78%, white);
  border-radius: 22%;
  box-shadow:
    0 0 0 3px color-mix(in srgb, var(--tier) 12%, transparent),
    0 0 24px color-mix(in srgb, var(--tier) 42%, transparent);
  animation: hintPulse 1.15s ease-in-out infinite;
  pointer-events: none;
}

.arrow.is-blocker-arrow .arrow-glyph {
  color: var(--danger);
  filter: drop-shadow(0 0 9px rgba(251, 113, 133, 0.7));
}

.game-controls {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 7px;
  flex: none;
  margin-top: 2px;
}

.control-btn {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  height: 55px;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(15, 24, 38, 0.68);
  color: #b8c8da;
  font-size: 10.5px;
  font-weight: 620;
  transition:
    background 0.16s ease,
    border-color 0.16s ease,
    transform 0.12s ease,
    color 0.16s ease;
}

.control-btn .control-icon {
  width: 17px;
  height: 17px;
  stroke-width: 1.9;
}

.control-btn small {
  position: absolute;
  top: 6px;
  right: 8px;
  color: var(--muted-2);
  font-family: var(--mono);
  font-size: 8px;
  font-weight: 600;
}

.control-btn:hover {
  background: rgba(22, 34, 50, 0.85);
  border-color: var(--line-strong);
  color: var(--text);
}

.control-btn:active {
  transform: scale(0.955);
}

.control-btn:disabled {
  opacity: 0.35;
  pointer-events: none;
}

.control-btn--hint {
  border-color: color-mix(in srgb, var(--tier) 28%, var(--line));
  background: color-mix(in srgb, var(--tier) 8%, rgba(15, 24, 38, 0.7));
  color: color-mix(in srgb, var(--tier) 68%, white);
}

.control-btn--hint small {
  color: color-mix(in srgb, var(--tier) 40%, var(--muted-2));
}

.game-footnote {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  flex: none;
  margin-top: 7px;
  color: var(--muted-2);
  font-size: 9px;
  text-align: center;
}

.game-footnote .live-dot {
  width: 4px;
  height: 4px;
  box-shadow: none;
}

/* --------------------------------------------------------------------------
   Overlays, tutorial, win
   -------------------------------------------------------------------------- */

.overlay {
  position: fixed;
  inset: 0;
  z-index: 40;
  display: grid;
  place-items: end center;
  padding: 16px calc(12px + env(safe-area-inset-right, 0px)) calc(12px + var(--safe-bottom))
    calc(12px + env(safe-area-inset-left, 0px));
  background: rgba(3, 7, 13, 0.72);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  opacity: 0;
  transition: opacity 0.22s ease;
}

.overlay.is-open {
  opacity: 1;
}

.overlay[hidden] {
  display: none;
}

.sheet {
  width: min(100%, 430px);
  max-height: calc(100dvh - 32px - var(--safe-top) - var(--safe-bottom));
  overflow-y: auto;
  padding: 21px;
  border: 1px solid var(--line-strong);
  border-radius: 24px;
  background:
    radial-gradient(100% 60% at 50% 0%, rgba(56, 189, 248, 0.07), transparent 60%),
    linear-gradient(165deg, #121d2d, #080e17);
  box-shadow:
    0 40px 90px -30px rgba(0, 0, 0, 0.95),
    inset 0 1px 0 rgba(255, 255, 255, 0.06);
  transform: translateY(28px) scale(0.985);
  transition: transform 0.28s cubic-bezier(0.2, 0.85, 0.25, 1);
  overscroll-behavior: contain;
}

.overlay.is-open .sheet {
  transform: none;
}

.sheet-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.sheet-kicker {
  color: var(--muted-2);
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.tutorial-panel h2 {
  margin: 12px 0 8px;
  font-size: 27px;
  font-weight: 800;
  letter-spacing: -0.045em;
  line-height: 1.05;
}

.sheet-copy {
  color: var(--muted);
  font-size: 12.5px;
  line-height: 1.65;
}

.sheet-copy strong {
  color: #d6e4f3;
  font-weight: 650;
}

.tutorial-demos {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-top: 16px;
}

.demo-col {
  display: flex;
  flex-direction: column;
  gap: 7px;
}

.demo-board {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 4px;
  padding: 7px;
  border: 1px solid var(--line);
  border-radius: 13px;
  background: rgba(255, 255, 255, 0.022);
}

.demo-cell {
  position: relative;
  display: grid;
  place-items: center;
  aspect-ratio: 1;
  border: 1px solid rgba(255, 255, 255, 0.03);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.022);
}

.demo-source {
  border-color: color-mix(in srgb, var(--accent) 32%, transparent);
  background: color-mix(in srgb, var(--accent) 9%, transparent);
}

.demo-path {
  border-style: dashed;
  border-color: rgba(94, 234, 212, 0.28);
}

.demo-path--bad {
  border-color: rgba(251, 113, 133, 0.35);
  background: rgba(251, 113, 133, 0.06);
}

.demo-blocker {
  border-color: rgba(251, 113, 133, 0.45);
  background: rgba(251, 113, 133, 0.12);
}

.demo-arrow {
  display: inline-flex;
  color: var(--accent);
  transform: rotate(var(--rot));
}

.demo-arrow svg {
  width: 16px;
  height: 16px;
  stroke: currentColor;
  fill: none;
  stroke-width: 2.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.demo-blocker .demo-arrow {
  color: var(--danger);
}

.demo-label {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  font-size: 9px;
  font-weight: 620;
  text-align: center;
}

.demo-label .icon {
  width: 11px;
  height: 11px;
  stroke-width: 2.4;
}

.demo-label--ok {
  color: var(--accent);
}

.demo-label--bad {
  color: var(--danger);
}

.tutorial-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin: 16px 0 18px;
  padding: 0;
  list-style: none;
}

.tutorial-list li {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.55;
}

.tutorial-list li > span {
  display: grid;
  place-items: center;
  width: 17px;
  height: 17px;
  flex: none;
  margin-top: 1px;
  border: 1px solid var(--line);
  border-radius: 5px;
  color: #aebfd2;
  font-family: var(--mono);
  font-size: 8.5px;
}

.tutorial-list li > div {
  flex: 1;
  min-width: 0;
}

.sheet:focus,
.win-panel:focus {
  outline: none;
}

.tutorial-list strong {
  color: var(--gold);
  font-weight: 650;
}

.win-panel {
  position: relative;
  width: min(100%, 400px);
  overflow: hidden;
  padding: 25px 21px 20px;
  border: 1px solid color-mix(in srgb, var(--tier) 30%, var(--line-strong));
  border-radius: 26px;
  background:
    radial-gradient(110% 70% at 50% 0%, color-mix(in srgb, var(--tier) 10%, transparent), transparent 60%),
    linear-gradient(170deg, #121e2e, #070d15);
  box-shadow:
    0 40px 100px -30px rgba(0, 0, 0, 0.95),
    inset 0 1px 0 rgba(255, 255, 255, 0.07);
  text-align: center;
  transform: translateY(26px) scale(0.985);
  transition: transform 0.3s cubic-bezier(0.2, 0.85, 0.25, 1);
}

.overlay.is-open .win-panel {
  transform: none;
}

.win-glow {
  position: absolute;
  top: -110px;
  left: 50%;
  width: 280px;
  height: 240px;
  transform: translateX(-50%);
  border-radius: 50%;
  background: radial-gradient(circle, color-mix(in srgb, var(--tier) 30%, transparent), transparent 68%);
  filter: blur(12px);
  pointer-events: none;
}

.win-eyebrow {
  position: relative;
  color: var(--muted-2);
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.win-panel h2 {
  position: relative;
  margin: 8px 0 10px;
  font-size: 36px;
  font-weight: 840;
  letter-spacing: -0.055em;
  line-height: 1;
}

.win-stars {
  position: relative;
  display: flex;
  justify-content: center;
  margin-bottom: 9px;
}

.win-note {
  position: relative;
  max-width: 32ch;
  margin: 0 auto;
  color: var(--muted);
  font-size: 11.5px;
  line-height: 1.6;
}

.win-stats {
  position: relative;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  overflow: hidden;
  margin: 17px 0 13px;
  padding: 11px 0;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.win-stats > div {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.win-stats span {
  color: var(--muted-2);
  font-size: 8px;
  font-weight: 620;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.win-stats strong {
  font-family: var(--mono);
  font-size: 15px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}

.win-record {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  margin-bottom: 11px;
  padding: 4px 8px;
  border: 1px solid rgba(251, 191, 36, 0.28);
  border-radius: 6px;
  background: rgba(251, 191, 36, 0.08);
  color: var(--gold);
  font-size: 8.5px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.win-record[hidden] {
  display: none;
}

.win-record .icon {
  width: 12px;
  height: 12px;
}

.win-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 7px;
  margin-top: 8px;
}

.win-actions .btn {
  height: 41px;
  padding-inline: 10px;
  font-size: 11.5px;
}

/* Toast */
.toast-region {
  position: fixed;
  right: 0;
  bottom: calc(92px + var(--safe-bottom));
  left: 0;
  z-index: 80;
  display: flex;
  justify-content: center;
  padding: 0 18px;
  pointer-events: none;
}

.toast {
  max-width: 92vw;
  padding: 9px 13px;
  border: 1px solid var(--line-strong);
  border-radius: 11px;
  background: rgba(14, 23, 36, 0.96);
  box-shadow: 0 16px 40px -16px rgba(0, 0, 0, 0.9);
  color: #cfddec;
  font-size: 11.5px;
  line-height: 1.4;
  opacity: 0;
  transform: translateY(8px);
  transition:
    opacity 0.2s ease,
    transform 0.2s ease;
}

.toast.is-in {
  opacity: 1;
  transform: none;
}

.toast--error {
  border-color: rgba(251, 113, 133, 0.4);
  color: #ffd4da;
}

.toast--hint {
  border-color: color-mix(in srgb, var(--tier, var(--accent)) 35%, transparent);
  color: color-mix(in srgb, var(--tier, var(--accent)) 55%, white);
}

/* --------------------------------------------------------------------------
   Responsive
   -------------------------------------------------------------------------- */

@media (min-width: 700px) {
  .topbar {
    padding-inline: 28px;
    padding-top: calc(16px + var(--safe-top));
  }

  .home {
    padding-inline: 28px;
  }

  .hero {
    padding: 58px 0 40px;
  }

  .hero h1 {
    font-size: clamp(64px, 8.6vw, 94px);
  }

  .hero-copy {
    font-size: 16px;
  }

  .feature-card {
    grid-template-columns: minmax(0, 1.15fr) minmax(240px, 0.85fr);
    align-items: center;
    gap: 24px;
    padding: 34px 34px 29px;
    min-height: 320px;
  }

  .feature-copy h2 {
    font-size: 62px;
  }

  .feature-copy > p {
    font-size: 14px;
  }

  .feature-art {
    position: relative;
    top: auto;
    right: auto;
    width: auto;
    height: auto;
    opacity: 1;
    -webkit-mask-image: none;
    mask-image: none;
    display: grid;
    place-items: center;
  }

  .art-board {
    grid-template-columns: repeat(4, 46px);
    gap: 8px;
  }

  .art-cell {
    width: 46px;
    height: 46px;
  }

  .game-grid {
    grid-template-columns: 1fr 1fr;
  }

  .collection {
    margin-top: 42px;
  }

  .section-head h2 {
    font-size: 19px;
  }

  .levels-screen {
    padding-inline: 24px;
  }

  .tier-tabs {
    margin-inline: -24px;
    padding-inline: 24px;
  }

  .level-grid {
    grid-template-columns: repeat(8, minmax(0, 1fr));
  }

  .game-screen {
    max-width: 600px;
    padding-inline: 18px;
  }

  .overlay {
    place-items: center;
  }

  .game-footnote {
    margin-top: 9px;
  }
}

@media (max-width: 370px) {
  .hero-actions .btn {
    padding-inline: 13px;
    font-size: 12.5px;
  }

  .hero-stats {
    gap: 18px;
  }

  .feature-card {
    padding: 21px 18px;
  }

  .feature-copy h2 {
    font-size: 42px;
  }

  .level-grid {
    grid-template-columns: repeat(auto-fill, minmax(50px, 1fr));
    gap: 6px;
  }

  .level-tile {
    min-height: 50px;
    border-radius: 11px;
  }

  .stat-value {
    font-size: 13px;
  }

  .game-screen {
    padding-inline: 10px;
  }

  .game-footnote {
    font-size: 8.5px;
  }
}

@media (max-height: 690px) {
  .game-screen {
    padding-bottom: 4px;
  }

  .game-top {
    min-height: 47px;
    padding-top: calc(4px + var(--safe-top));
  }

  .game-stats {
    padding-block: 5px;
  }

  .board-wrap {
    padding-block: 6px 4px;
  }

  .game-controls .control-btn {
    height: 48px;
  }

  .game-footnote {
    display: none;
  }
}

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

/* --------------------------------------------------------------------------
   Keyframes
   -------------------------------------------------------------------------- */

@keyframes livePulse {
  0%,
  100% {
    opacity: 1;
    box-shadow: 0 0 0 3px rgba(94, 234, 212, 0.12);
  }
  50% {
    opacity: 0.65;
    box-shadow: 0 0 0 5px rgba(94, 234, 212, 0.04);
  }
}

@keyframes floatArrow {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-4px);
  }
}

@keyframes starPop {
  0% {
    transform: scale(0) rotate(-25deg);
    opacity: 0;
  }
  70% {
    transform: scale(1.14) rotate(4deg);
    opacity: 1;
  }
  100% {
    transform: scale(1) rotate(0);
    opacity: 1;
  }
}

@keyframes popIn {
  0% {
    transform: scale(0.5);
    opacity: 0;
  }
  100% {
    transform: scale(1);
    opacity: 1;
  }
}

@keyframes shake {
  0%,
  100% {
    transform: translateX(0);
  }
  20% {
    transform: translateX(-3px);
  }
  40% {
    transform: translateX(3px);
  }
  60% {
    transform: translateX(-2px);
  }
  80% {
    transform: translateX(2px);
  }
}

@keyframes hintPulse {
  0%,
  100% {
    opacity: 0.55;
    transform: scale(0.97);
  }
  50% {
    opacity: 1;
    transform: scale(1.03);
  }
}

@keyframes trailFlash {
  0% {
    background: color-mix(in srgb, var(--tier) 26%, transparent);
    box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--tier) 30%, transparent);
  }
  100% {
    background: rgba(255, 255, 255, 0.022);
    box-shadow: none;
  }
}
