/* ==================================================================
   سفر پرنسس به قصر — ظاهر روشن و مینیمال (حالت روز)
   ================================================================== */

/* ---------- قلم وزیرمتن (فارسی/عربی + لاتین) ---------- */
@font-face {
  font-family: 'Vazirmatn';
  src: url('fonts/Vazirmatn-Regular.woff2') format('woff2');
  font-weight: 400; font-style: normal; font-display: swap;
}
@font-face {
  font-family: 'Vazirmatn';
  src: url('fonts/Vazirmatn-Bold.woff2') format('woff2');
  font-weight: 700; font-style: normal; font-display: swap;
}
@font-face {
  font-family: 'Vazirmatn';
  src: url('fonts/Vazirmatn-ExtraBold.woff2') format('woff2');
  font-weight: 800; font-style: normal; font-display: swap;
}

:root {
  --font-main: 'Vazirmatn', 'Geeza Pro', Tahoma, 'Segoe UI', system-ui, sans-serif;

  --sky-top: #dff1ff;
  --sky-bottom: #f4fbff;
  --ink: #3c4a5a;
  --ink-soft: #7b8b9c;
  --card: #ffffff;
  --line: #e4ecf3;

  --grass-a: #d9f0cf;
  --grass-b: #cfeac4;
  --grass-edge: #bfe0b2;
  --sea-a: #b6e3f5;
  --sea-b: #a2d8ef;
  --sea-line: #d8f1fb;

  --gold: #f6c445;
  --pink: #ff8fb4;
  --blue: #6fa8dc;

  --tile: 56px;
  --content: 720px;        /* عرض ستون اصلی — همه‌ی بخش‌ها با آن هم‌تراز می‌شوند */
  --radius: 18px;
  --shadow: 0 6px 20px rgba(76, 110, 140, .10);
}

* { box-sizing: border-box; }

/* حلقه‌ی تمرکز فقط برای کاربر صفحه‌کلید (نه کلیک با ماوس) */
:focus-visible {
  outline: 3px solid var(--pink);
  outline-offset: 3px;
  border-radius: 6px;
}
.board:focus-visible { outline-offset: 5px; }

html, body {
  margin: 0;
  padding: 0;
  min-height: 100%;
  overscroll-behavior-y: contain;   /* هنگام کشیدن روی صفحه، صفحه رفرش نشود */
  color: var(--ink);
  font-family: var(--font-main);
  background: linear-gradient(180deg, var(--sky-top) 0%, var(--sky-bottom) 55%, #f2fbf0 100%);
  -webkit-tap-highlight-color: transparent;
}

.sr-only {
  position: absolute; width: 1px; height: 1px;
  margin: -1px; padding: 0; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

/* ---------- آسمان روز ---------- */
.sky { position: fixed; inset: 0; overflow: hidden; pointer-events: none; z-index: 0; }

.sun {
  position: absolute; top: -14px; left: -10px;
  width: 76px; height: 76px; border-radius: 50%;
  background: #ffe9a8;
  box-shadow: 0 0 0 18px rgba(255, 233, 168, .35), 0 0 0 38px rgba(255, 233, 168, .18);
}

.sky-puff {
  position: absolute;
  background: #fff;
  border-radius: 60px;
  opacity: .85;
  filter: blur(.2px);
}
.sky-puff::before, .sky-puff::after {
  content: ""; position: absolute; background: #fff; border-radius: 50%;
}
.sky-puff-1 { width: 120px; height: 34px; top: 60px; right: 8%; animation: drift 46s linear infinite; }
.sky-puff-1::before { width: 52px; height: 52px; top: -22px; left: 22px; }
.sky-puff-1::after  { width: 38px; height: 38px; top: -14px; left: 64px; }

.sky-puff-2 { width: 90px; height: 26px; top: 150px; right: 42%; opacity: .7; animation: drift 62s linear infinite; }
.sky-puff-2::before { width: 40px; height: 40px; top: -18px; left: 16px; }
.sky-puff-2::after  { width: 28px; height: 28px; top: -10px; left: 50px; }

.sky-puff-3 { width: 140px; height: 36px; bottom: 12%; left: 4%; opacity: .55; animation: drift 78s linear infinite reverse; }
.sky-puff-3::before { width: 56px; height: 56px; top: -24px; left: 26px; }
.sky-puff-3::after  { width: 42px; height: 42px; top: -16px; left: 76px; }

@keyframes drift {
  from { transform: translateX(0); }
  to   { transform: translateX(-60px); }
}

/* ---------- چیدمان ---------- */
/* همه‌ی بخش‌ها در یک ستون هم‌عرض، وسط صفحه */
.game {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: calc(var(--content) + 32px);
  margin: 0 auto;
  padding: 16px 16px 28px;
  /* حاشیه‌ی امن گوشی‌های نات‌چ‌دار */
  padding-inline: max(16px, env(safe-area-inset-left)) max(16px, env(safe-area-inset-right));
  padding-bottom: calc(28px + env(safe-area-inset-bottom));
  display: flex;
  flex-direction: column;
  align-items: stretch;
}

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

.topbar h1 {
  margin: 0;
  font-size: clamp(18px, 4.6vw, 26px);
  font-weight: 800;
  letter-spacing: -.2px;
  display: flex; align-items: center; gap: 9px;
  min-width: 0;
}
.title-ic { width: 1.05em; height: 1.05em; flex: 0 0 auto; display: block; }
.title-short[hidden] { display: none; }
.title-ic svg { width: 100%; height: 100%; display: block; }

.topbar-actions { display: flex; gap: 8px; }

/* ---------- دکمه‌ها ---------- */
.chip {
  border: 1.5px solid var(--line);
  background: var(--card);
  color: var(--ink);
  border-radius: 999px;
  min-width: 40px; height: 40px;
  padding: 0 14px;
  font: inherit; font-weight: 700; font-size: 14px;
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  cursor: pointer;
  box-shadow: 0 2px 0 rgba(120, 145, 170, .14);
  transition: transform .12s, box-shadow .12s, background .12s;
}
.chip:hover { background: #fbfdff; }
.chip:active { transform: translateY(2px); box-shadow: none; }
.chip.wide { min-width: 116px; }
.chip.primary { background: var(--pink); border-color: #f97fa9; color: #fff; }
.chip.primary:hover { background: #ff7fa9; }
.chip svg { width: 20px; height: 20px; }

#btn-sound svg { width: 19px; height: 19px; }

/* ---------- نوار مرحله‌ها ---------- */
.levelbar {
  display: flex; gap: 8px;
  flex-wrap: nowrap;
  justify-content: center;
  overflow-x: auto;
  scrollbar-width: none;
  margin: 12px 0 10px;
  padding-bottom: 2px;
}
.levelbar::-webkit-scrollbar { display: none; }
.lvl {
  flex: 0 0 auto;
  border: 1.5px solid var(--line);
  background: var(--card);
  border-radius: 14px;
  padding: 6px 10px 5px;
  min-width: 54px;
  cursor: pointer;
  font: inherit;
  display: flex; flex-direction: column; align-items: center; gap: 2px;
  box-shadow: 0 2px 0 rgba(120, 145, 170, .12);
  transition: transform .12s, border-color .12s;
}
.lvl:active { transform: translateY(2px); }
.lvl-num { font-weight: 800; font-size: 14px; }
.lvl-stars { display: flex; gap: 1px; }
.lvl-stars svg { width: 10px; height: 10px; }
.lvl.current { border-color: var(--pink); background: #fff5f8; }
.lvl.locked { opacity: .45; cursor: not-allowed; }
.lvl-num { display: inline-flex; align-items: center; gap: 3px; }
.lvl-lock { width: 11px; height: 11px; display: block; }
.lvl-lock svg { width: 100%; height: 100%; display: block; }

/* ---------- نوار وضعیت ---------- */
.statusbar {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  background: var(--card);
  border: 1.5px solid var(--line);
  border-radius: var(--radius);
  padding: 10px 4px;
  box-shadow: var(--shadow);
}
.stat { min-width: 0; text-align: center; padding: 0 4px; }
.stat + .stat { border-inline-start: 1.5px solid var(--line); }
.stat-label { display: block; font-size: 11px; color: var(--ink-soft); margin-bottom: 2px; }
.stat strong { font-size: 17px; font-weight: 800; }
.stat-par strong { color: var(--blue); }

.hint {
  margin: 10px 2px 8px;
  font-size: 13.5px;
  color: var(--ink-soft);
  line-height: 1.7;
  display: flex; align-items: flex-start; gap: 7px;
}
.hint-ic { width: 17px; height: 17px; flex: 0 0 auto; margin-top: 2px; }
.hint-ic svg { width: 100%; height: 100%; display: block; }

/* ---------- زمین بازی ---------- */
.board-wrap { position: relative; display: flex; justify-content: center; width: 100%; }

/* پنل بازی: پهنای یکسان در همه‌ی مرحله‌ها، شبکه در وسط آن */
/* حصار چوبی: به کودک نشان می‌دهد باغ تا کجاست و از کجا نمی‌شود رد شد */
.board {
  direction: ltr;            /* ستون ۰ همیشه سمت چپ می‌ماند */
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
  width: 100%;
  padding: 10px;
  border-radius: 22px;
  background: #eaf7e4;
  border: 3px solid #C9A16A;
  box-shadow:
    var(--shadow),
    inset 0 0 0 3px #E0BC8C,
    inset 0 0 0 10px #eaf7e4;
  outline: none;
  touch-action: none;
}

/* تخته‌های حصار: دو نوار افقی بالا و پایین پنل */
.board::before,
.board::after {
  content: "";
  position: absolute;
  left: 10px; right: 10px;
  height: 7px;
  border-radius: 4px;
  background:
    repeating-linear-gradient(90deg,
      #D9A96F 0 14px, #C9985C 14px 16px);
  opacity: .85;
  pointer-events: none;
}
.board::before { top: 11px; }
.board::after  { bottom: 11px; }

.grid {
  position: relative;
  display: grid;
  gap: 0;
  /* بدون overflow: hidden — وگرنه پرش پرنسس در سطر اول بریده می‌شود */
}
.board.shake { animation: shake .26s; }
@keyframes shake {
  0%, 100% { transform: translateX(0); }
  25% { transform: translateX(-5px); }
  75% { transform: translateX(5px); }
}

.tile {
  position: relative;
  width: var(--tile); height: var(--tile);
  display: grid; place-items: center;
}
.tile-grass  { background: var(--grass-a); }
.tile-grass.alt { background: var(--grass-b); }
.tile-grass::after {
  content: ""; position: absolute; inset: 0;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .45);
}
.tile-sea { background: var(--sea-b); }
.tile-sea::after {
  content: ""; position: absolute; inset: 0;
  background:
    radial-gradient(circle at 30% 40%, rgba(255,255,255,.5) 0 2px, transparent 3px),
    radial-gradient(circle at 70% 72%, rgba(255,255,255,.4) 0 2px, transparent 3px);
  background-repeat: no-repeat;
  animation: bob 4s ease-in-out infinite;
}
.tile-sea.alt { background: var(--sea-a); }
@keyframes bob {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(3px); }
}

.tile .art {
  position: relative;
  z-index: 2;                /* بالای موج‌های تزئینی دریا */
  width: 86%; height: 86%;
  display: grid; place-items: center;
  pointer-events: none;
}
.tile .art svg { width: 100%; height: 100%; display: block; }
.tile-castle .art { width: 104%; height: 104%; }
.tile-tree .art { width: 96%; height: 96%; }

.art.pop { animation: pop .3s ease-out; }
@keyframes pop {
  from { transform: scale(.5); opacity: 0; }
  to   { transform: scale(1); opacity: 1; }
}
/* قایق روی آب دور می‌شود (غرق نمی‌شود) */
/* هدف فعلی آرام نبض می‌زند تا کودک بدون خواندن بفهمد کجا برود */
.tile.goal::after {
  content: "";
  position: absolute; inset: 6%;
  border-radius: 12px;
  border: 3px solid rgba(255, 143, 180, .85);
  animation: goalPulse 1.9s ease-in-out infinite;
  pointer-events: none;
}
@keyframes goalPulse {
  0%, 100% { opacity: .25; transform: scale(.94); }
  50%      { opacity: .95; transform: scale(1.02); }
}

/* راهنما: خانه‌ی بعدی مسیر برق می‌زند */
.tile.hint-step::before {
  content: "";
  position: absolute; inset: 0;
  border-radius: 10px;
  background: rgba(255, 216, 107, .55);
  box-shadow: inset 0 0 0 4px #F6C445;
  animation: hintFlash .7s ease-out;
  pointer-events: none;
  z-index: 2;
}
@keyframes hintFlash {
  0%   { opacity: 0; transform: scale(.7); }
  35%  { opacity: 1; transform: scale(1.04); }
  100% { opacity: 0; transform: scale(1); }
}

/* دکمه‌ای که باید فشرده شود هم برق می‌زند */
.pad-btn.hint-key, .ferry-btn.hint-key {
  animation: hintKey .7s ease-out;
  border-color: #F6C445;
}
@keyframes hintKey {
  0%, 100% { box-shadow: 0 3px 0 rgba(120, 145, 170, .18); }
  40%      { box-shadow: 0 0 0 6px rgba(246, 196, 69, .55); }
}

.art.drift { animation: drift .6s ease-in forwards; }
@keyframes drift {
  40%  { transform: translateX(6px) rotate(4deg); opacity: .85; }
  to   { transform: translateX(26px) rotate(7deg) scale(.82); opacity: 0; }
}
.art.taken { animation: taken .42s ease-out forwards; }
@keyframes taken {
  to { transform: scale(1.5) translateY(-14px); opacity: 0; }
}

.chip:disabled { opacity: .45; cursor: default; box-shadow: none; }
/* بدون این خط، display: inline-flex بر [hidden] غلبه می‌کند */
.chip[hidden] { display: none; }

/* گل‌های ریز تزئینی روی چمن */
.blade {
  position: absolute;
  width: 5px; height: 5px; border-radius: 50%;
  background: #fff;
  opacity: .75;
}
.blade.b1 { top: 22%; left: 24%; background: #ffd9e6; }
.blade.b2 { bottom: 20%; right: 26%; background: #fff3c0; }

/* ---------- پرنسس (لایه‌ی جدا برای حرکت نرم) ---------- */
.actor {
  position: absolute;
  width: var(--tile); height: var(--tile);
  left: 0; top: 0;
  display: grid; place-items: center;
  transition: transform .19s cubic-bezier(.34, 1.4, .64, 1);
  z-index: 3;
  pointer-events: none;
}
.actor svg { width: 96%; height: 96%; }
.actor.hop svg { animation: hop .19s; }
@keyframes hop {
  50% { transform: translateY(-7px) scale(1.04); }
}
.actor.swim { transition: transform .95s ease-in-out; }
.actor.arrived svg { animation: cheer 1s ease-in-out infinite; }
@keyframes cheer {
  0%, 100% { transform: translateY(0) rotate(0); }
  30% { transform: translateY(-6px) rotate(-4deg); }
  60% { transform: translateY(-2px) rotate(4deg); }
}

/* دلفین شنا کننده در دریا */
.swimmer {
  position: absolute;
  width: calc(var(--tile) * 1.5); height: calc(var(--tile) * 1.5);
  display: grid; place-items: center;
  z-index: 2;
  pointer-events: none;
  animation: swimAcross 6s ease-in-out infinite alternate;
}
.swimmer svg { width: 100%; height: 100%; }
@keyframes swimAcross {
  from { transform: translate(-6px, 0) rotate(-3deg); }
  to   { transform: translate(6px, 6px) rotate(3deg); }
}

/* ---------- پیام کوچک ---------- */
.toast {
  position: absolute;
  top: 8px; left: 50%;
  transform: translate(-50%, -14px);
  background: #fff;
  border: 1.5px solid var(--line);
  border-radius: 999px;
  padding: 7px 16px;
  font-size: 13.5px; font-weight: 700;
  box-shadow: var(--shadow);
  opacity: 0;
  pointer-events: none;
  transition: opacity .2s, transform .2s;
  z-index: 5;
  max-width: min(92%, 430px);
  text-align: center;
  line-height: 1.65;
  display: flex; align-items: center; justify-content: center; gap: 8px;
}
.toast-ic { width: 21px; height: 21px; flex: 0 0 auto; }
.toast-ic svg { width: 100%; height: 100%; display: block; }
.toast.show { opacity: 1; transform: translate(-50%, 0); }

/* ---------- کنترل‌ها ---------- */
.controls {
  margin-top: 18px;
  display: flex; align-items: center; justify-content: center;
  gap: 34px; flex-wrap: wrap;
  width: 100%;
}

.ferry-btn {
  order: -1;
  flex: 1 1 100%;
  border: none;
  background: linear-gradient(180deg, #8fd0ea, #6fb9de);
  color: #fff;
  font: inherit; font-weight: 800; font-size: 15px;
  border-radius: 16px;
  padding: 13px 18px;
  cursor: pointer;
  display: flex; align-items: center; justify-content: center; gap: 8px;
  box-shadow: 0 4px 0 #58a3c9;
  animation: nudge 1.6s ease-in-out infinite;
}
.ferry-btn[hidden] { display: none; }
.ferry-btn:active { transform: translateY(3px); box-shadow: 0 1px 0 #58a3c9; }
.ferry-icon { width: 30px; height: 30px; display: block; }
.ferry-icon svg { width: 100%; height: 100%; }
@keyframes nudge {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-3px); }
}

.pad {
  position: relative;
  width: 168px; height: 168px;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  grid-template-rows: repeat(3, 1fr);
  gap: 6px;
  direction: ltr;
}
.pad-btn {
  border: 1.5px solid var(--line);
  background: var(--card);
  border-radius: 16px;
  font-size: 20px;
  color: var(--ink-soft);
  cursor: pointer;
  box-shadow: 0 3px 0 rgba(120, 145, 170, .16);
  transition: transform .1s, box-shadow .1s, color .1s;
}
.pad-btn:active { transform: translateY(3px); box-shadow: none; color: var(--pink); }
.pad-btn.up    { grid-area: 1 / 2; }
.pad-btn.left  { grid-area: 2 / 1; }
.pad-btn.right { grid-area: 2 / 3; }
.pad-btn.down  { grid-area: 3 / 2; }
.pad-hole { grid-area: 2 / 2; }

.side-btns { display: flex; flex-direction: column; gap: 10px; }

.tip {
  margin: 14px 2px 0;
  font-size: 12px;
  color: var(--ink-soft);
  text-align: center;
}

/* ---------- دکمه‌ی زبان ---------- */
.chip-lang { font-weight: 800; letter-spacing: .3px; }

/* ---------- پانویس حقوقی ---------- */
.legal-bar {
  margin: 22px 0 0;
  padding-top: 14px;
  border-top: 1.5px solid rgba(200, 218, 232, .55);
  text-align: center;
  font-size: 12px;
  color: var(--ink-soft);
}
.linky {
  border: none; background: none;
  font: inherit; font-size: 12px;
  color: var(--ink-soft);
  text-decoration: underline;
  text-underline-offset: 3px;
  cursor: pointer;
  padding: 4px 2px;
}
.linky:hover { color: var(--pink); }
.legal-bar .dot { margin: 0 4px; }
.copyright { margin: 6px 0 0; opacity: .85; }

.credit-line {
  margin: 8px 0 0;
  display: flex; justify-content: center; align-items: center; gap: 5px;
  font-size: 12px;
}
.credit-line a {
  color: var(--pink);
  font-weight: 700;
  text-decoration: none;
  border-bottom: 1.5px solid rgba(255, 143, 180, .45);
  padding-bottom: 1px;
}
.credit-line a:hover { border-bottom-color: var(--pink); }

/* ---------- متن‌های حقوقی ---------- */
.card-legal { max-width: 560px; text-align: start; }
.card-legal h2 { text-align: center; }
.legal-updated {
  text-align: center;
  font-size: 12px;
  margin: 0 0 14px;
}
.legal-body {
  max-height: min(58vh, 420px);
  overflow-y: auto;
  padding-inline-end: 6px;
  padding-bottom: 4px;
  -webkit-overflow-scrolling: touch;
}
.card-legal .card-btns {
  margin-top: 16px;
  padding-top: 14px;
  border-top: 1.5px solid var(--line);
}
.legal-body h3 {
  margin: 14px 0 4px;
  font-size: 14.5px;
  color: var(--ink);
  text-align: start;
}
.legal-body h3:first-child { margin-top: 0; }
.legal-body p {
  margin: 0;
  font-size: 13px;
  line-height: 1.85;
  color: var(--ink-soft);
  text-align: start;
}

/* ---------- پیام‌های تمام‌صفحه ---------- */
.overlay {
  position: fixed; inset: 0; z-index: 20;
  display: grid; place-items: center;
  background: rgba(226, 241, 250, .78);
  backdrop-filter: blur(4px);
  padding: 18px;
  animation: fade .2s;
}
@keyframes fade { from { opacity: 0; } }
.overlay[hidden] { display: none; }

.noscript-note {
  margin: 20px auto;
  width: min(720px, calc(100% - 32px));
  padding: 18px;
  border: 1.5px solid var(--line);
  border-radius: var(--radius);
  background: var(--card);
  box-shadow: var(--shadow);
  text-align: center;
}
.noscript-note h2 { margin: 0 0 8px; font-size: 20px; }
.noscript-note p { margin: 6px 0; color: var(--ink-soft); line-height: 1.8; }

.card {
  background: var(--card);
  border-radius: 26px;
  border: 1.5px solid var(--line);
  box-shadow: 0 20px 50px rgba(70, 105, 135, .18);
  padding: 24px 22px;
  max-width: 380px; width: 100%;
  text-align: center;
  animation: rise .28s cubic-bezier(.2, 1.3, .5, 1);
}
@keyframes rise { from { transform: translateY(18px) scale(.96); opacity: 0; } }
.card h2 { margin: 6px 0 4px; font-size: 22px; }
.card p { margin: 6px 0 14px; color: var(--ink-soft); font-size: 14px; line-height: 1.8; }
.card-art { height: 96px; display: flex; align-items: flex-end; justify-content: center; gap: 4px; }
.card-art svg { height: 92px; }
.card-art .small svg { height: 54px; }
.card-btns { display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; }

.stars { display: flex; justify-content: center; gap: 6px; margin: 8px 0 2px; }
.stars svg { width: 38px; height: 38px; }
.stars .lit { animation: starPop .45s cubic-bezier(.2, 1.6, .5, 1) both; }
.stars .lit:nth-child(2) { animation-delay: .13s; }
.stars .lit:nth-child(3) { animation-delay: .26s; }
@keyframes starPop { from { transform: scale(0) rotate(-40deg); } }

.card-help { max-width: 430px; text-align: start; }
.card-help h2 { text-align: center; }
.help-lead { text-align: center; }
.legend { list-style: none; margin: 0 0 18px; padding: 0; display: grid; gap: 9px; }
.legend li { display: flex; align-items: center; gap: 10px; font-size: 13.5px; }
.legend .lg-ic {
  width: 38px; height: 38px; flex: none;
  background: var(--grass-a);
  border-radius: 11px;
  display: grid; place-items: center;
}
.legend .lg-ic.water { background: var(--sea-b); }
.legend .lg-ic svg { width: 88%; height: 88%; }

/* قلب‌های جشن */
.confetti { position: fixed; inset: 0; pointer-events: none; z-index: 25; overflow: hidden; }
.confetti span {
  position: absolute; top: -8%;
  width: 22px; height: 22px;
  animation: fall linear forwards;
}
.confetti span svg { width: 100%; height: 100%; }
@keyframes fall {
  to { transform: translateY(115vh) rotate(360deg); opacity: .2; }
}

@media (max-width: 560px) {
  :root { --tile: 42px; }

  /* نوار بالا در یک ردیف می‌ماند: عنوان کوتاه می‌شود، دکمه‌ها ثابت */
  .topbar { flex-wrap: nowrap; gap: 8px; }
  .topbar h1 {
    font-size: 17px;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
  }
  /* روی صفحه‌ی کوچک، عنوان کوتاه نمایش داده می‌شود */
  .title-full { display: none; }
  .title-short[hidden] { display: block; }
  .topbar-actions { flex: 0 0 auto; gap: 6px; }

  /* هدف لمسی استاندارد ۴۴ پیکسل */
  .chip { min-width: 44px; height: 44px; padding: 0 12px; }
  .lvl { min-width: 48px; min-height: 44px; padding: 5px 8px 4px; }
  .linky { padding: 8px 4px; }

  .game { padding-top: 12px; }
  .pad { width: 156px; height: 156px; }
  .stat-label { font-size: 10px; }
  .stat strong { font-size: 15px; }
  .controls { justify-content: center; gap: 16px; margin-top: 12px; }
  .tip { margin-top: 10px; }
  .side-btns { flex-direction: row; }
  .hint { font-size: 13px; }
}

/* صفحه‌های خیلی باریک */
@media (max-width: 360px) {
  .topbar h1 { font-size: 15.5px; }
  .chip { padding: 0 9px; }
}

@media (prefers-reduced-motion: reduce) {
  * { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}
