/* games/index.html and games/<game>.html, on the Signal foundation (the
   study's #/games and #/games/chess). signal-read.css carries the page top,
   sections, bento cards, questions and the closing call; this sheet is the
   game pages' own parts: the painted tiles, the game hero, the numbered
   first match, the usage callout, the next-game row and the board-led
   chess lander. Foundation tokens only; violet is the step number and the
   callout rule, nothing larger. */

/* Tiles. */
.game-hero-icon, .game-card-icon { display: block; flex: 0 0 auto; max-width: 100%; height: auto; border-radius: 22%; box-shadow: 0 18px 50px #0004; }
.game-hero-icon { width: 200px; }
.game-card-icon { width: 72px; margin-bottom: 16px; border-radius: 18%; box-shadow: 0 8px 22px #0003; }

/* A game's hero: tile beside the words. */
.game-hero { display: flex; align-items: center; gap: clamp(24px, 4vw, 48px); }
.game-hero-text { flex: 1 1 0; min-width: 0; }
.games .page-hero h1 { font-size: clamp(40px, 4.6vw, 60px); }
.games .install-section h2, .games .sec-head h2 { max-width: 24ch; }
.games .cta h2 { max-width: 20ch; }

/* The directory's cards. */
.game-card h3 { margin-bottom: 6px; }
.bento-card.game-card h3 a { color: inherit; text-decoration: none; }
.bento-card.game-card h3 a:hover { text-decoration: underline; text-underline-offset: 4px; }
.game-card p { margin-bottom: 10px; }
.game-card .sg-btn { margin: 0 4px 6px 0; }

/* How a match goes (first-use). */
.first-use-inner { display: grid; grid-template-columns: minmax(260px, .8fr) minmax(0, 1.2fr); gap: clamp(40px, 7vw, 96px); align-items: start; }
.first-use-head h2 { max-width: 14ch; margin: 0 0 16px; }
.first-use-head p { max-width: 42ch; line-height: 1.7; color: var(--muted); }
.first-use-inner > p { grid-column: 1 / -1; max-width: 72ch; line-height: 1.65; color: var(--muted); }
.first-use-steps { margin: 0; padding: 0; list-style: none; border-top: 1px solid var(--line); }
.first-use-steps li { display: grid; grid-template-columns: 54px minmax(0, 1fr); gap: 20px; align-items: start; padding: 22px 0; border-bottom: 1px solid var(--line); }
.first-use-num { padding-top: 4px; font: 600 12px/1.3 var(--sans); letter-spacing: .06em; color: var(--violet); }
.first-use-steps h3 { margin: 0 0 6px; font-size: 18px; }
.first-use-steps p { max-width: 62ch; margin: 0; font-size: 14.5px; line-height: 1.65; color: var(--muted); }
.first-use-steps strong { color: var(--ink); }

/* The usage callout. */
.credit-callout { display: flex; align-items: center; justify-content: space-between; gap: 28px; margin-top: 20px; padding: 22px 26px; border: 1px solid var(--line); border-left: 3px solid var(--violet); border-radius: 0 var(--radius-md) var(--radius-md) 0; background: var(--surface); }
.credit-callout p { margin: 0 0 5px; font-size: 11px; font-weight: 650; letter-spacing: .12em; text-transform: uppercase; color: var(--ink); }
.credit-callout h3 { margin: 0 0 6px; font-size: 19px; }
.credit-callout span { line-height: 1.55; color: var(--muted); }
.credit-callout .cta-ctas { flex: none; margin-top: 0; }

/* The next-game row. */
.game-next { padding-top: 0; border-top: 0; }
.game-next-row { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 15px; }
.game-next-card { display: flex; align-items: center; gap: 16px; min-width: 0; padding: 16px 20px; border: 1px solid var(--line); border-radius: var(--radius-md); background: var(--surface); color: inherit; text-decoration: none; transition: border-color .2s, transform .2s; }
.game-next-card:hover { border-color: #55565d; transform: translateY(-2px); }
.game-next-card .game-card-icon { width: 56px; height: 56px; margin: 0; }
.game-next-card.is-next { justify-content: flex-end; text-align: right; }
.game-next-text { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.game-next-kicker { font-size: 11px; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.game-next-name { font: 600 17px/1.3 var(--display); letter-spacing: -.03em; color: var(--ink); }
.game-next-role { font-size: 13px; color: var(--muted); }

/* ── The board-led lander (chess) ── */
.gp-fold { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(24px, 4vw, 56px); align-items: center; padding-top: 40px; padding-bottom: 20px; }
.gp-board-only { position: relative; overflow: hidden; border: 1px solid var(--line); border-radius: var(--radius-md); background: var(--soft); box-shadow: var(--shadow); }
.gp-board-only img { position: absolute; max-width: none; height: auto; }
.gp-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 18px; margin-top: 12px; }
.gp-fold h1 { margin: 12px 0 0; }
.gp-fold h1 em { font-style: normal; }
.gp-lede { margin-top: 14px; }
.gp-facts { display: flex; flex-wrap: wrap; gap: 6px 20px; margin-top: 14px; font-size: 13px; color: var(--muted); }
.gp-actions { display: flex; flex-wrap: wrap; gap: 10px; }
.gp-fold .gp-actions { margin-top: 24px; }
.gp-sec { padding: clamp(56px, 7vw, 92px) 0; border-top: 1px solid var(--line); }
.gp-head { display: grid; gap: 12px; max-width: 820px; margin-bottom: clamp(28px, 4vw, 44px); }
.gp-head .t-label, .gp-prose .t-label { margin: 0; }
.gp-head h2, .gp-prose h2 { margin: 0; }
.gp-after { margin-top: 22px; }
.gp-steps { counter-reset: step; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 24px; margin: 0; padding: 24px 0 0; list-style: none; border-top: 1px solid var(--line); }
.gp-steps li { counter-increment: step; }
.gp-steps li::before { content: counter(step, decimal-leading-zero); display: block; margin-bottom: 10px; font: 600 12px/1.3 var(--sans); color: var(--violet); }
.gp-steps h3 { margin: 0 0 6px; font-size: 17px; }
.gp-steps p { margin: 0; font-size: 14.5px; line-height: 1.6; color: var(--muted); }
.gp-options { overflow: hidden; max-width: 820px; margin: 0; border: 1px solid var(--line); border-radius: var(--radius-md); background: var(--surface); }
.gp-options div { display: grid; grid-template-columns: 160px 1fr; gap: 16px; padding: 14px 18px; border-bottom: 1px solid var(--line); font-size: 14.5px; }
.gp-options div:last-child { border-bottom: 0; }
.gp-options dt { font-weight: 600; color: var(--ink); }
.gp-options dd { margin: 0; color: var(--muted); }
.gp-prose { display: grid; gap: 14px; max-width: 68ch; }
.gp-prose p { margin: 0; font-size: 16px; line-height: 1.75; color: var(--muted); }
.gp-prose p strong, .gp-prose em { color: var(--ink); }
.record-more { max-width: 820px; margin-top: 22px; }
.record-more > summary { display: inline-flex; align-items: center; gap: 10px; padding: 6px 0; list-style: none; cursor: pointer; font-weight: 550; color: var(--ink); }
.record-more > summary::-webkit-details-marker { display: none; }
.record-more > summary::before { content: '+'; display: grid; place-items: center; width: 22px; height: 22px; border: 1px solid var(--line); border-radius: 50%; font-size: 14px; color: var(--muted); }
.record-more[open] > summary::before { content: '\2013'; }
.record-body { display: grid; gap: 12px; margin-top: 12px; padding: 16px 18px; border: 1px solid var(--line); border-radius: var(--radius-md); background: var(--surface); }
.gp-every .record-body { max-width: none; }
.gp-every .record-body p { margin: 0; font-size: 15px; line-height: 1.65; }
.gp-qa { max-width: 68ch; }
.gp-qa + .gp-qa { margin-top: 34px; }
.gp-qa h2 { margin: 0 0 10px; font-size: 22px; line-height: 1.25; }
.gp-qa p { margin: 0; font-size: 16px; line-height: 1.75; color: var(--muted); }
.gp-qa a { color: var(--violet); text-decoration: underline; text-underline-offset: 3px; }
.gp-qa .gp-links { margin-top: 12px; font-size: 14px; }
.gp-spec { max-width: 820px; margin: 0; border-top: 1px solid var(--line); }
.gp-spec div { display: grid; grid-template-columns: 180px 1fr; gap: 20px; padding: 13px 0; border-bottom: 1px solid var(--line); font-size: 14.5px; }
.gp-spec dt { padding-top: 1px; font-weight: 600; color: var(--ink); }
.gp-spec dd { margin: 0; color: var(--muted); }
.gp-aside { display: flex; align-items: center; justify-content: space-between; gap: 24px; margin-top: 28px; padding: 20px 24px; border: 1px solid var(--line); border-radius: var(--radius-md); background: var(--surface); }
.gp-aside p { max-width: 52ch; margin: 0; color: var(--muted); }
.gp-aside b { display: block; margin-bottom: 4px; font-size: 17px; color: var(--ink); }
.gp-aside .gp-actions { flex: none; }
.gp-final { display: flex; flex-wrap: wrap; align-items: center; gap: 24px; }
.gp-final > div { max-width: 640px; margin-right: auto; }
.gp-final h2 em { font-style: normal; }
.gp-final .t-read { margin-top: 12px; }
.frame-tag { display: inline-flex; align-items: center; gap: 8px; font-size: 12px; color: var(--muted); }
.frame-tag::before { content: ''; flex: none; width: 6px; height: 6px; border-radius: 50%; background: var(--muted); }

@media (max-width: 900px) {
  .gp-steps { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 760px) {
  .first-use-inner { grid-template-columns: 1fr; gap: 28px; }
  .first-use-head h2 { max-width: none; }
  .first-use-steps li { grid-template-columns: 38px minmax(0, 1fr); gap: 12px; padding: 18px 0; }
  .game-next-row { grid-template-columns: 1fr; }
  .game-next-card.is-next { flex-direction: row-reverse; justify-content: flex-end; text-align: left; }
  .gp-fold { grid-template-columns: 1fr; padding-top: 24px; }
  .gp-aside { flex-direction: column; align-items: flex-start; }
}
@media (max-width: 720px) {
  .game-hero { flex-direction: column; align-items: flex-start; gap: 24px; }
  .game-hero-icon { width: 128px; }
}
@media (max-width: 600px) {
  .credit-callout { flex-direction: column; align-items: flex-start; gap: 18px; padding: 22px; }
}
@media (max-width: 540px) {
  .gp-fold .gp-actions { display: grid; }
  .gp-steps { grid-template-columns: 1fr; }
  .gp-options div, .gp-spec div { grid-template-columns: 1fr; gap: 4px; }
}
@media (prefers-reduced-motion: reduce) {
  .game-next-card { transition: none; }
  .game-next-card:hover { transform: none; }
}
