/* ── Tutorial ────────────────────────────────────────────────────────────────
   The "How to play" overlay: a CHOOSER (rules? controls?) then a short deck of
   static illustrated cards per section. Engine in src/ui/tutorial.js; each
   game's cards in src/ui/tutorials/<game>.js. Deliberately simple — skim in
   twenty seconds and play. */

.tut-full {
  position: fixed;
  inset: 0;
  z-index: 60;
  background: var(--bg);
  display: flex;
  flex-direction: column;
  min-height: 0;
  padding: max(14px, var(--sat)) 20px max(18px, var(--sab));
  animation: tut-fade var(--duration-2, 0.24s) var(--ease, ease) both;
  user-select: none;
  -webkit-user-select: none;
}
@keyframes tut-fade { from { opacity: 0; } to { opacity: 1; } }
.tut-full ::selection { background-color: rgba(128, 128, 128, 0.01); color: inherit; }

/* top row: back · name · ✕  (ghost buttons, same as the app bar) */
.tut-top { display: flex; align-items: center; gap: var(--space-3); min-height: 40px; flex: none; }
.tut-top .spacer { flex: 1; }
.tut-top .icon-btn { border-color: transparent; background: none; }
.tut-top .icon-btn:hover:not(:disabled) { background: var(--surface); }
.tut-name {
  font-family: var(--font-mono); font-size: var(--text-sm);
  letter-spacing: var(--tracking-label); text-transform: uppercase; color: var(--mute);
  margin-left: var(--space-2);
}

/* ── the chooser ── */
.tut-choose {
  flex: 1; display: flex; flex-direction: column; justify-content: center;
  gap: var(--space-5); max-width: 440px; width: 100%; margin: 0 auto;
}
.tut-hello { text-align: center; color: var(--dim); font-size: var(--text-base); margin-bottom: var(--space-2); }
.tut-choose h2 { text-align: center; font-size: var(--text-2xl); font-weight: 400; margin-bottom: var(--space-5); }
.tut-sec {
  display: flex; align-items: center; gap: var(--space-5); text-align: left;
  padding: var(--space-6); border-radius: var(--radius-lg);
  border: var(--hairline) solid var(--line); background: var(--surface);
  cursor: pointer; transition: var(--t); color: var(--text);
}
.tut-sec:hover { border-color: var(--accent-line); }
.tut-sec-ic {
  flex: none; width: 44px; height: 44px; display: grid; place-items: center;
  border-radius: var(--radius); background: var(--surface-2); color: var(--accent);
}
.tut-sec-ic svg { width: 22px; height: 22px; fill: none; stroke: currentColor;
  stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.tut-sec-t { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 3px; }
.tut-sec-t strong { font-size: var(--text-lg); font-weight: 500; }
.tut-sec-t span { color: var(--dim); font-size: var(--text-sm); }
.tut-sec-go { flex: none; color: var(--mute); }
.tut-sec-go svg { width: 16px; height: 16px; fill: none; stroke: currentColor;
  stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.tut-skip {
  margin: var(--space-5) auto 0; padding: var(--space-4) var(--space-7);
  background: none; border: none; color: var(--dim); cursor: pointer;
  font-family: var(--font-mono); font-size: var(--text-xs);
  letter-spacing: var(--tracking-label); text-transform: uppercase;
}
.tut-skip:hover { color: var(--text); }

/* ── one card ── */
.tut-card {
  flex: 1; min-height: 0; display: flex; flex-direction: column;
  align-items: center; justify-content: center; text-align: center;
  gap: var(--space-5); max-width: 480px; width: 100%; margin: 0 auto;
  padding: var(--space-5) 0;
}
.tut-art { width: min(78vw, 300px); flex: none; }
.tut-fig { width: 100%; height: auto; display: block; }
.tut-card h2 { font-size: var(--text-2xl); font-weight: 500; letter-spacing: -0.01em; }
.tut-card p { color: var(--dim); font-size: var(--text-md); line-height: var(--leading-prose); max-width: 34ch; }

/* ── pager ── */
.tut-nav {
  flex: none; display: flex; align-items: center; justify-content: space-between;
  gap: var(--space-5); max-width: 480px; width: 100%; margin: 0 auto;
}
.tut-nav .icon-btn { border-color: transparent; background: none; }
.tut-nav .icon-btn:hover:not(:disabled) { background: var(--surface); }
.tut-nav .pill { min-width: 110px; justify-content: center; }
.tut-dots { display: flex; gap: 7px; }
.tut-dots i { width: 7px; height: 7px; border-radius: var(--radius-full); background: var(--line-2); transition: var(--t); }
.tut-dots i.on { background: var(--accent); }
