@charset "utf-8";

/* ============================================================
   Maple Play Room — single stylesheet
   Tokens, layout, components, game boards.
   ============================================================ */

@font-face {
  font-family: "Oswald";
  font-style: normal;
  font-weight: 200 700;
  font-display: swap;
  src: url("/assets/fonts/oswald.woff2") format("woff2");
}

@font-face {
  font-family: "Work Sans";
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url("/assets/fonts/work-sans.woff2") format("woff2");
}

:root {
  --paper: #efeeea;
  --paper-lift: #f7f6f3;
  --paper-tint: #e4e3dc;
  --paper-deep: #d8d6cd;
  --ink: #17181b;
  --ink-soft: #54555c;
  --cobalt: #1b45d6;
  --cobalt-deep: #12309a;
  --coral: #ff5b49;
  --line: #cfcdc4;

  --radius: 14px;
  --radius-sm: 10px;
  --pill: 999px;
  --notch: 30px;

  --s1: 4px;
  --s2: 8px;
  --s3: 12px;
  --s4: 16px;
  --s5: 24px;
  --s6: 32px;
  --s7: 48px;
  --s8: 64px;
  --s9: 96px;

  --display: "Oswald", "Arial Narrow", "Helvetica Neue", system-ui, sans-serif;
  --body: "Work Sans", -apple-system, "Segoe UI", Roboto, system-ui, sans-serif;

  --theme: var(--cobalt);
  --theme-tint: #e8ecfa;
}

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

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--body);
  font-size: 17px;
  line-height: 1.62;
  font-weight: 400;
  overflow-x: hidden;
}

/* fine-grain paper noise, sits behind everything */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  opacity: .5;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.86' numOctaves='3'/%3E%3C/filter%3E%3Crect width='160' height='160' filter='url(%23n)' opacity='.11'/%3E%3C/svg%3E");
}

body > * { position: relative; z-index: 1; }

img { max-width: 100%; height: auto; }

/* ---------- typography ---------- */

h1, h2, h3, h4 {
  font-family: var(--display);
  font-weight: 700;
  margin: 0;
  text-wrap: balance;
}

/* condensed display type sits tight, so give it air before body copy */
h2 + p, h2 + ul, h2 + ol, h2 + dl { margin-top: var(--s5); }
h3 + p, h4 + p { margin-top: var(--s3); }

h1 {
  font-size: clamp(2.7rem, 7.4vw, 5.1rem);
  line-height: .93;
  letter-spacing: -.005em;
  text-transform: uppercase;
}

h2 {
  font-size: clamp(1.85rem, 3.6vw, 2.85rem);
  line-height: 1.02;
  text-transform: uppercase;
  letter-spacing: .002em;
}

h3 {
  font-size: clamp(1.2rem, 1.9vw, 1.45rem);
  line-height: 1.16;
  font-weight: 600;
}

h4 {
  font-size: 1.02rem;
  line-height: 1.25;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .06em;
}

p { margin: 0 0 var(--s4); }

.kicker {
  display: block;
  font-family: var(--display);
  font-size: .82rem;
  font-weight: 500;
  letter-spacing: .2em;
  text-transform: uppercase;
  color: var(--coral);
  margin: 0 0 var(--s3);
}

.accent { color: var(--cobalt); }

.lede {
  font-size: clamp(1.08rem, 1.6vw, 1.22rem);
  line-height: 1.55;
  color: var(--ink-soft);
}

.num {
  font-variant-numeric: tabular-nums;
  font-feature-settings: "tnum" 1;
}

.prose {
  max-width: 68ch;

  & > * + * { margin-top: var(--s4); }

  & h2 { margin-top: var(--s7); }

  & h3 { margin-top: var(--s6); }

  & a {
    color: var(--cobalt);
    text-decoration: underline;
    text-underline-offset: 3px;
    text-decoration-thickness: 1px;

    &::after { content: "\00a0\2192"; }

    &:hover { color: var(--cobalt-deep); }
  }
}

a { color: var(--cobalt); }

a:focus-visible,
button:focus-visible,
summary:focus-visible,
[tabindex]:focus-visible {
  outline: 3px solid var(--coral);
  outline-offset: 3px;
  border-radius: 4px;
}

/* ---------- layout ---------- */

.wrap {
  width: min(1160px, 100% - 40px);
  margin-inline: auto;
}

.wrap--narrow { width: min(780px, 100% - 40px); }

.section { padding-block: clamp(var(--s7), 7vw, var(--s9)); }

.section--tight { padding-block: clamp(var(--s6), 5vw, var(--s7)); }

.band { background: var(--paper-tint); }

.band--ink {
  background: var(--ink);
  color: var(--paper);

  & h2, & h3 { color: var(--paper); }

  & .kicker { color: var(--coral); }

  & .lede { color: #b6b5b0; }
}

/* notched corners where two sections meet */
.band--notch {
  clip-path: polygon(
    0 var(--notch),
    var(--notch) 0,
    100% 0,
    100% calc(100% - var(--notch)),
    calc(100% - var(--notch)) 100%,
    0 100%
  );
}

.head-row {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: var(--s5);
  margin-bottom: var(--s6);
}

.head-row p { margin: 0; max-width: 46ch; }

/* ---------- surfaces & imagery ---------- */

/* the single box-shadow used anywhere on this site */
.surface {
  background: var(--paper-lift);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: inset 0 1px 0 #fff;
}

.shot {
  position: relative;
  margin: 0 14px 14px 0;

  & img {
    position: relative;
    display: block;
    width: 100%;
    border: 1px solid var(--line);
    border-radius: var(--radius);
  }

  &::before {
    content: "";
    position: absolute;
    inset: 14px -14px -14px 14px;
    border-radius: var(--radius);
    background: var(--cobalt);
  }
}

.shot--coral::before { background: var(--coral); }

.shot--ink::before { background: var(--ink); }

/* ---------- badges ---------- */

.badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 14px 6px 12px;
  border-radius: var(--pill);
  font-family: var(--display);
  font-size: .78rem;
  font-weight: 500;
  letter-spacing: .12em;
  text-transform: uppercase;
  background: var(--paper-deep);
  color: var(--ink);
  border: 1px solid var(--line);

  &::before {
    content: "";
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--coral);
    flex: none;
  }
}

.badge--cobalt {
  background: var(--cobalt);
  border-color: var(--cobalt);
  color: #fff;

  &::before { background: #fff; }
}

.badge--coral {
  background: var(--coral);
  border-color: var(--coral);
  color: var(--ink);

  &::before { background: var(--ink); }
}

.badge--plain {
  background: transparent;
  border-color: currentcolor;
}

.badge-row {
  display: flex;
  flex-wrap: wrap;
  gap: var(--s2);
}

/* ---------- buttons ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 46px;
  padding: 11px 24px;
  border-radius: var(--pill);
  border: 2px solid transparent;
  font-family: var(--display);
  font-size: .95rem;
  font-weight: 600;
  letter-spacing: .08em;
  text-transform: uppercase;
  text-decoration: none;
  cursor: pointer;
  background: var(--cobalt);
  color: #fff;
  transition: background-color .16s ease, color .16s ease, border-color .16s ease;

  &:hover { background: var(--cobalt-deep); }

  &[disabled] {
    opacity: .42;
    cursor: not-allowed;
  }
}

.btn--ghost {
  background: transparent;
  border-color: var(--ink);
  color: var(--ink);

  &:hover {
    background: var(--ink);
    color: var(--paper);
  }
}

.btn--coral {
  background: var(--coral);
  color: var(--ink);

  &:hover { background: #ef4331; }
}

.btn--small {
  min-height: 38px;
  padding: 7px 16px;
  font-size: .82rem;
}

.btn-row {
  display: flex;
  flex-wrap: wrap;
  gap: var(--s3);
  align-items: center;
}

/* ---------- lists ---------- */

.list {
  margin: 0;
  padding-left: 1.25em;

  & li {
    margin-bottom: var(--s2);

    &::marker {
      color: var(--coral);
      content: "\25AA\00a0\00a0";
    }
  }
}

.list--check li::marker { content: "\2713\00a0\00a0"; }

.list--num {
  list-style: decimal;

  & li::marker {
    content: counter(list-item) ".\00a0";
    font-family: var(--display);
    font-weight: 600;
    color: var(--cobalt);
  }
}

@media (min-width: 760px) {
  .list--two {
    columns: 2;
    column-gap: var(--s7);

    & li { break-inside: avoid; }
  }
}

.linklist {
  list-style: none;
  margin: 0;
  padding: 0;

  & li { margin-bottom: var(--s3); }

  & a {
    color: var(--cobalt);
    text-decoration: underline;
    text-underline-offset: 3px;

    &::after { content: "\00a0\2192"; }
  }
}

/* ---------- tables ---------- */

.table-scroll { overflow-x: auto; }

.table {
  width: 100%;
  border-collapse: collapse;
  font-size: .96rem;
  font-variant-numeric: tabular-nums;
  min-width: 460px;

  & caption {
    text-align: left;
    font-family: var(--display);
    font-size: .8rem;
    letter-spacing: .14em;
    text-transform: uppercase;
    color: var(--ink-soft);
    padding-bottom: var(--s3);
  }

  & th, & td {
    padding: 11px 14px;
    text-align: left;
    border-bottom: 1px solid var(--line);
    vertical-align: top;
  }

  & thead th {
    font-family: var(--display);
    font-weight: 600;
    font-size: .8rem;
    letter-spacing: .1em;
    text-transform: uppercase;
    border-bottom: 2px solid var(--ink);
  }

  & td + td, & th + th { text-align: right; }

  & tbody tr:last-child td { border-bottom: none; }
}

.table--left td + td,
.table--left th + th { text-align: left; }

/* ---------- age bar ---------- */

.agebar {
  position: sticky;
  top: 0;
  z-index: 60;
  background: var(--coral);
  color: var(--ink);
  font-size: .78rem;
  letter-spacing: .02em;
  border-bottom: 1px solid rgba(23, 24, 27, .22);

  & .wrap {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 4px 14px;
    padding-block: 6px;
  }

  & strong {
    font-family: var(--display);
    font-weight: 600;
    letter-spacing: .1em;
    text-transform: uppercase;
  }

  & a {
    color: var(--ink);
    text-decoration: underline;
    text-underline-offset: 2px;

    &::after { content: "\00a0\2192"; }
  }
}

/* ---------- header ---------- */

.utility {
  background: var(--ink);
  color: #b6b5b0;
  font-size: .76rem;

  & .wrap {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 4px 18px;
    padding-block: 7px;
  }

  & a {
    color: var(--paper);
    text-decoration: none;

    &:hover { text-decoration: underline; }
  }

  & ul {
    display: flex;
    gap: 18px;
    list-style: none;
    margin: 0;
    padding: 0;
  }
}

.masthead {
  border-bottom: 2px solid var(--ink);
  background: var(--paper);

  & .wrap {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--s5);
    padding-block: var(--s4);
  }
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  color: var(--ink);
  flex: none;

  & svg {
    width: 40px;
    height: 40px;
    flex: none;
  }

  & b {
    font-family: var(--display);
    font-size: 1.32rem;
    font-weight: 700;
    letter-spacing: .04em;
    text-transform: uppercase;
    line-height: 1;
  }

  & span {
    display: block;
    font-size: .64rem;
    letter-spacing: .18em;
    text-transform: uppercase;
    color: var(--ink-soft);
    font-family: var(--display);
    font-weight: 500;
  }
}

.mainnav {
  overflow-x: auto;
  scrollbar-width: none;
  -ms-overflow-style: none;

  &::-webkit-scrollbar { display: none; }

  & ul {
    display: flex;
    align-items: center;
    gap: var(--s5);
    list-style: none;
    margin: 0;
    padding: 0;
  }

  & a {
    display: block;
    white-space: nowrap;
    font-family: var(--display);
    font-size: .92rem;
    font-weight: 500;
    letter-spacing: .1em;
    text-transform: uppercase;
    color: var(--ink);
    text-decoration: none;
    padding-block: 4px;
    border-bottom: 2px solid transparent;

    &:hover { border-bottom-color: var(--coral); }
  }

  & [aria-current="page"] { border-bottom-color: var(--cobalt); }
}

@media (max-width: 900px) {
  .masthead .wrap {
    flex-direction: column;
    align-items: flex-start;
    gap: var(--s3);
  }

  .mainnav {
    width: 100%;
    padding-bottom: 2px;
  }
}

/* ---------- hero ---------- */

.hero {
  padding-block: clamp(var(--s7), 6vw, var(--s8)) var(--s6);

  & .wrap {
    display: grid;
    grid-template-columns: 1.15fr .85fr;
    gap: clamp(var(--s5), 4vw, var(--s8));
    align-items: center;
  }
}

.hero__copy p { max-width: 46ch; }

.hero h1 { margin-bottom: var(--s5); }

@media (max-width: 880px) {
  .hero .wrap { grid-template-columns: 1fr; }

  .hero__art { order: -1; }
}

.freebar {
  background: var(--ink);
  color: var(--paper);

  & .wrap {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: var(--s3) var(--s5);
    padding-block: var(--s4);
  }

  & p {
    margin: 0;
    font-size: .95rem;
    max-width: 74ch;
  }

  & strong { color: var(--coral); }
}

/* ---------- game mosaic ---------- */

.mosaic {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: clamp(var(--s5), 3.4vw, var(--s7)) var(--s6);
}

.tile {
  grid-column: span 3;
  display: flex;
  flex-direction: column;

  &:nth-child(1) { grid-column: span 4; }

  &:nth-child(2) { grid-column: span 2; }

  & h3 { margin-bottom: var(--s2); }

  & p {
    color: var(--ink-soft);
    font-size: .97rem;
  }

  & .btn { align-self: flex-start; margin-top: auto; }
}

.tile__art {
  position: relative;
  margin: 0 0 var(--s5);

  & img {
    position: relative;
    display: block;
    width: 100%;
    aspect-ratio: 4 / 3;
    object-fit: cover;
    border: 1px solid var(--line);
    border-radius: var(--radius);
  }

  &::before {
    content: "";
    position: absolute;
    inset: 12px -12px -12px 12px;
    border-radius: var(--radius);
    background: var(--tile-block, var(--cobalt));
  }
}

.tile:nth-child(1) .tile__art img { aspect-ratio: 16 / 10; }

.tile__meta {
  display: flex;
  flex-wrap: wrap;
  gap: var(--s2);
  margin-bottom: var(--s3);
}

@media (max-width: 900px) {
  .mosaic { grid-template-columns: repeat(2, 1fr); }

  .tile,
  .tile:nth-child(1),
  .tile:nth-child(2) { grid-column: span 1; }
}

@media (max-width: 600px) {
  .mosaic { grid-template-columns: 1fr; }

  .tile,
  .tile:nth-child(1),
  .tile:nth-child(2) { grid-column: span 1; }
}

/* staggered reveal, games grid only */
@media (prefers-reduced-motion: no-preference) {
  .mosaic .tile {
    opacity: 0;
    transform: translateY(16px);
    animation: tile-rise .55s cubic-bezier(.22, .68, .38, 1) forwards;
    animation-delay: calc(var(--i, 0) * 90ms);
  }
}

@keyframes tile-rise {
  to {
    opacity: 1;
    transform: none;
  }
}

/* ---------- content blocks ---------- */

.grid-2 {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: clamp(var(--s5), 4vw, var(--s7));
  align-items: center;
}

.grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--s5);
}

@media (max-width: 860px) {
  .grid-2, .grid-3 { grid-template-columns: 1fr; }
}

.checklist {
  padding: clamp(var(--s5), 3vw, var(--s6));
  clip-path: polygon(
    0 0,
    calc(100% - 22px) 0,
    100% 22px,
    100% 100%,
    22px 100%,
    0 calc(100% - 22px)
  );

  & h3 { margin-bottom: var(--s4); }

  & ol, & ul {
    list-style: none;
    margin: 0;
    padding: 0;
    counter-reset: check;
  }

  & li {
    position: relative;
    padding-left: 40px;
    margin-bottom: var(--s4);
    font-size: .98rem;

    &:last-child { margin-bottom: 0; }

    &::before {
      content: "";
      position: absolute;
      left: 0;
      top: 2px;
      width: 22px;
      height: 22px;
      border: 2px solid var(--cobalt);
      border-radius: 6px;
    }

    &::after {
      content: "";
      position: absolute;
      left: 6px;
      top: 8px;
      width: 10px;
      height: 5px;
      border-left: 2px solid var(--coral);
      border-bottom: 2px solid var(--coral);
      transform: rotate(-45deg);
    }
  }

  & li b {
    display: block;
    font-family: var(--display);
    font-weight: 600;
    letter-spacing: .04em;
    text-transform: uppercase;
    font-size: .92rem;
  }
}

.callout {
  padding: var(--s5);
  border-left: 4px solid var(--coral);
  background: var(--paper-lift);
  border-radius: 0 var(--radius) var(--radius) 0;

  & p:last-child { margin-bottom: 0; }

  & h3 { margin-bottom: var(--s3); }
}

.glossary {
  margin: 0;

  & dt {
    font-family: var(--display);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: .06em;
    font-size: .95rem;
    border-bottom: 2px solid var(--coral);
    padding-bottom: 4px;
    margin-bottom: var(--s2);
    display: inline-block;
  }

  & dd {
    margin: 0 0 var(--s5);
    font-size: .95rem;
    color: var(--ink-soft);
  }
}

.faq-group {
  margin-bottom: var(--s7);

  & > h3 {
    font-family: var(--display);
    font-size: .85rem;
    letter-spacing: .2em;
    text-transform: uppercase;
    color: var(--coral);
    border-bottom: 1px solid var(--line);
    padding-bottom: var(--s2);
    margin-bottom: var(--s5);
  }
}

.faq-item {
  margin-bottom: var(--s5);
  max-width: 72ch;

  & h4 {
    text-transform: none;
    letter-spacing: 0;
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: var(--s2);
  }

  & p:last-child { margin-bottom: 0; }
}

.rundown {
  display: grid;
  gap: var(--s5);
}

.rundown__item {
  display: grid;
  grid-template-columns: 180px 1fr;
  gap: var(--s5);
  padding-bottom: var(--s5);
  border-bottom: 1px solid var(--line);

  &:last-child {
    border-bottom: none;
    padding-bottom: 0;
  }

  & h3 { margin-bottom: var(--s2); }

  & p { margin-bottom: 0; }
}

.rundown__label {
  font-family: var(--display);
  font-size: .82rem;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--ink-soft);
  padding-top: 5px;
}

@media (max-width: 720px) {
  .rundown__item { grid-template-columns: 1fr; gap: var(--s2); }
}

.disclaimer {
  font-size: .92rem;
  color: var(--ink-soft);

  & p { max-width: 90ch; }

  & p:last-child { margin-bottom: 0; }

  & strong { color: var(--ink); }
}

.pagehead {
  padding-block: clamp(var(--s6), 5vw, var(--s8)) var(--s6);

  & h1 { margin-bottom: var(--s4); }

  & .lede { max-width: 60ch; }
}

.updated {
  font-size: .82rem;
  color: var(--ink-soft);
  font-variant-numeric: tabular-nums;
  margin-top: var(--s5);
}

/* ---------- footer ---------- */

.site-foot {
  background: var(--ink);
  color: #b6b5b0;
  padding-block: var(--s7) var(--s6);
  font-size: .88rem;

  & a {
    color: var(--paper);
    text-decoration: none;

    &:hover { text-decoration: underline; }
  }
}

.foot-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--s4) var(--s6);
  padding-bottom: var(--s5);
  border-bottom: 1px solid #2f3036;
}

.foot-row .brand {
  color: var(--paper);

  & span { color: #8b8c92; }
}

.foot-links {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 18px;
  list-style: none;
  margin: 0;
  padding: 0;
  font-size: .86rem;
}

.foot-notice {
  margin: var(--s5) 0 0;
  max-width: 92ch;
  font-size: .84rem;
  line-height: 1.6;

  & strong { color: var(--coral); }
}

.foot-meta {
  margin: var(--s4) 0 0;
  font-size: .8rem;
  color: #8b8c92;
  font-variant-numeric: tabular-nums;
}

/* ---------- cookie bar ---------- */

.cookiebar {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 70;
  background: var(--paper-lift);
  border-top: 2px solid var(--ink);
  padding-block: var(--s4);

  &[hidden] { display: none; }

  & .wrap {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: var(--s4);
  }

  & p {
    margin: 0;
    font-size: .88rem;
    max-width: 68ch;
  }
}

/* ---------- game shell ---------- */

.gamestage {
  --theme: var(--cobalt);
  --theme-tint: #e8ecfa;
}

.stage {
  padding: clamp(var(--s4), 3vw, var(--s6));
  background: var(--paper-lift);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.stage__top {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--s4);
  margin-bottom: var(--s5);
  padding-bottom: var(--s4);
  border-bottom: 1px solid var(--line);
}

.coinpanel {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--s3) var(--s5);
}

.coinpanel__balance {
  display: flex;
  flex-direction: column;
  line-height: 1.1;
}

.coinpanel__label {
  font-family: var(--display);
  font-size: .7rem;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--ink-soft);
}

.coinpanel__value {
  font-family: var(--display);
  font-size: clamp(1.7rem, 4vw, 2.3rem);
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  color: var(--ink);
}

.coinpanel__acts {
  display: flex;
  flex-wrap: wrap;
  gap: var(--s2);
}

.coin-note {
  margin: var(--s3) 0 0;
  font-size: .82rem;
  line-height: 1.45;
  color: var(--ink-soft);
  max-width: 46ch;
}

.betbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--s3);
  margin-bottom: var(--s5);
}

.betbar__label {
  font-family: var(--display);
  font-size: .74rem;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--ink-soft);
}

.chip {
  min-width: 58px;
  min-height: 40px;
  padding: 6px 14px;
  border-radius: var(--pill);
  border: 2px solid var(--line);
  background: transparent;
  font-family: var(--display);
  font-weight: 600;
  font-size: .95rem;
  font-variant-numeric: tabular-nums;
  color: var(--ink);
  cursor: pointer;

  &:hover { border-color: var(--ink); }

  &[aria-pressed="true"] {
    background: var(--ink);
    border-color: var(--ink);
    color: var(--paper);
  }
}

.stage__board {
  background: var(--theme-tint);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: clamp(var(--s4), 3vw, var(--s6));
  margin-bottom: var(--s5);
}

.stage__msg {
  display: block;
  min-height: 3.2em;
  font-size: 1rem;
  line-height: 1.5;
  padding: var(--s3) var(--s4);
  border-left: 4px solid var(--theme);
  background: var(--paper);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  margin-bottom: var(--s5);

  & b { font-weight: 600; }
}

.stage__controls {
  display: flex;
  flex-wrap: wrap;
  gap: var(--s3);
  align-items: center;
}

.stage__foot {
  margin: var(--s5) 0 0;
  font-size: .82rem;
  color: var(--ink-soft);
  border-top: 1px solid var(--line);
  padding-top: var(--s4);
}

.nojs {
  padding: var(--s4);
  border: 2px dashed var(--line);
  border-radius: var(--radius);
  font-size: .92rem;
  margin-bottom: var(--s5);
}

.rules-panel {
  padding: clamp(var(--s5), 3vw, var(--s6));

  & h2 { margin-bottom: var(--s4); }

  & h3 { margin: var(--s5) 0 var(--s3); }

  & p, & ul { font-size: .96rem; }

  & p:last-child { margin-bottom: 0; }
}

/* playing cards, shared by Hi-Lo and video poker */

.card {
  position: relative;
  width: 100%;
  aspect-ratio: 5 / 7;
  background: #fff;
  border: 2px solid var(--ink);
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--display);
  font-weight: 600;
  user-select: none;
}

.card__rank {
  position: absolute;
  top: 5px;
  left: 8px;
  font-size: clamp(.9rem, 2.4vw, 1.15rem);
  line-height: 1;
}

.card__rank--flip {
  top: auto;
  left: auto;
  bottom: 5px;
  right: 8px;
  transform: rotate(180deg);
}

.card__pip {
  font-size: clamp(1.9rem, 6vw, 2.9rem);
  line-height: 1;
}

.card--red { color: var(--coral); }

.card--black { color: var(--ink); }

.card--back {
  background: var(--theme);
  border-color: var(--theme);
  background-image: repeating-linear-gradient(
    45deg,
    rgba(255, 255, 255, .18) 0 6px,
    transparent 6px 12px
  );
}

/* ---------- Hi-Lo (Cyber Vault) ---------- */

.hilo {
  --theme: #1b45d6;
  --theme-tint: #e8ecfa;
}

.hilo__board {
  background-image:
    linear-gradient(var(--paper-deep) 1px, transparent 1px),
    linear-gradient(90deg, var(--paper-deep) 1px, transparent 1px);
  background-size: 32px 32px;
  background-position: -1px -1px;
}

.hilo__cards {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: clamp(var(--s4), 4vw, var(--s6));
}

.hilo__slot {
  width: clamp(96px, 22vw, 132px);
  flex: none;
  text-align: center;
}

.hilo__slot span {
  display: block;
  font-family: var(--display);
  font-size: .7rem;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--ink-soft);
  margin-bottom: var(--s2);
}

.hilo__stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--s3);
  margin-top: var(--s5);
  text-align: center;
}

.hilo__stat {
  padding: var(--s3);
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);

  & b {
    display: block;
    font-family: var(--display);
    font-size: 1.35rem;
    font-variant-numeric: tabular-nums;
  }

  & span {
    font-size: .72rem;
    letter-spacing: .12em;
    text-transform: uppercase;
    color: var(--ink-soft);
    font-family: var(--display);
  }
}

.call-btn small {
  display: block;
  font-size: .68rem;
  letter-spacing: .06em;
  opacity: .85;
  font-variant-numeric: tabular-nums;
}

.call-btn {
  flex-direction: column;
  gap: 1px;
  padding-block: 8px;
}

/* ---------- Sic Bo (Jungle Expedition) ---------- */

.sicbo {
  --theme: #1c7a4f;
  --theme-tint: #e6f1e9;
}

.dice-row {
  display: flex;
  justify-content: center;
  gap: clamp(var(--s3), 3vw, var(--s5));
  margin-bottom: var(--s5);
}

.die {
  width: clamp(64px, 17vw, 92px);
  height: clamp(64px, 17vw, 92px);
  flex: none;
  background: #fff;
  border: 2px solid var(--theme);
  border-radius: 12px;
}

.die--rolling { animation: die-shake .42s linear infinite; }

@keyframes die-shake {
  0%, 100% { transform: translateY(0) rotate(0deg); }
  25% { transform: translateY(-5px) rotate(-5deg); }
  75% { transform: translateY(4px) rotate(5deg); }
}

@media (prefers-reduced-motion: reduce) {
  .die--rolling { animation: none; }
}

.bet-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(104px, 1fr));
  gap: var(--s2);
}

.bet-grid--totals {
  grid-template-columns: repeat(3, 1fr);

  @media (min-width: 560px) { grid-template-columns: repeat(5, 1fr); }
  @media (min-width: 900px) { grid-template-columns: repeat(7, 1fr); }
}

.bet-cell {
  padding: 9px 8px;
  border: 2px solid var(--line);
  border-radius: var(--radius-sm);
  background: var(--paper);
  cursor: pointer;
  text-align: center;
  font-family: var(--body);
  color: var(--ink);
  line-height: 1.25;

  &:hover { border-color: var(--theme); }

  & b {
    display: block;
    font-family: var(--display);
    font-weight: 600;
    font-size: .95rem;
    text-transform: uppercase;
    letter-spacing: .04em;
  }

  & span {
    display: block;
    font-size: .72rem;
    color: var(--ink-soft);
    font-variant-numeric: tabular-nums;
  }

  & u {
    display: block;
    margin-top: 3px;
    font-size: .76rem;
    font-weight: 600;
    text-decoration: none;
    color: var(--theme);
    font-variant-numeric: tabular-nums;
    min-height: 1.1em;
  }

  &[data-staked="yes"] {
    border-color: var(--theme);
    background: #fff;
  }

  &.bet-cell--hit {
    border-color: var(--coral);
    background: #fff2ef;
  }
}

.bet-groups {
  display: grid;
  gap: var(--s4);
}

.bet-groups h4 {
  font-size: .74rem;
  letter-spacing: .16em;
  color: var(--ink-soft);
  margin-bottom: var(--s2);
}

/* ---------- Video poker (Carnival Midway) ---------- */

.poker {
  --theme: #d8402f;
  --theme-tint: #fdeee9;
}

.poker__board {
  max-width: 660px;
  margin-inline: auto;
  background-image: repeating-linear-gradient(
    90deg,
    rgba(216, 64, 47, .05) 0 34px,
    transparent 34px 68px
  );
}

.poker__hand {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: clamp(6px, 1.6vw, 14px);
  max-width: 560px;
  margin: 0 auto;
}

.poker__seat {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.hold-btn {
  width: 100%;
  min-height: 34px;
  padding: 5px 4px;
  border-radius: var(--pill);
  border: 2px solid var(--line);
  background: var(--paper);
  font-family: var(--display);
  font-size: .68rem;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--ink-soft);
  cursor: pointer;

  &[aria-pressed="true"] {
    background: var(--theme);
    border-color: var(--theme);
    color: #fff;
  }

  &[disabled] { opacity: .4; cursor: not-allowed; }
}

.paytable-wrap {
  max-width: 480px;
  margin-top: var(--s6);
}

.paytable {
  width: 100%;
  border-collapse: collapse;
  font-size: .88rem;
  font-variant-numeric: tabular-nums;

  & caption {
    text-align: left;
    padding-bottom: 8px;
    font-family: var(--display);
    font-size: .72rem;
    font-weight: 500;
    letter-spacing: .14em;
    text-transform: uppercase;
    color: var(--ink-soft);
  }

  & th, & td {
    padding: 6px 8px;
    border-bottom: 1px solid var(--line);
    text-align: right;
  }

  & th:first-child, & td:first-child { text-align: left; }

  & thead th {
    font-family: var(--display);
    font-size: .72rem;
    letter-spacing: .08em;
    text-transform: uppercase;
    border-bottom: 2px solid var(--ink);
  }

  & tr[data-win="yes"] {
    background: var(--theme);
    color: #fff;
  }

  & tr[data-win="yes"] td { border-bottom-color: var(--theme); }
}

/* ---------- Crash (Norse Legends) ---------- */

.crash {
  --theme: #2b6d95;
  --theme-tint: #e6eff5;
}

.crash__canvas {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 4 / 3;

  @media (min-width: 700px) { aspect-ratio: 2 / 1; }
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
}

.crash__readout {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: var(--s3);
  margin-bottom: var(--s4);
}

.crash__mult {
  font-family: var(--display);
  font-size: clamp(2.4rem, 8vw, 4rem);
  font-weight: 700;
  line-height: 1;
  font-variant-numeric: tabular-nums;
  color: var(--theme);

  &[data-state="bust"] { color: var(--coral); }

  &[data-state="won"] { color: #1c7a4f; }
}

.crash__history {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  list-style: none;
  margin: var(--s4) 0 0;
  padding: 0;

  & li {
    font-family: var(--display);
    font-size: .8rem;
    font-variant-numeric: tabular-nums;
    padding: 3px 10px;
    border-radius: var(--pill);
    border: 1px solid var(--line);
    background: var(--paper);
  }

  & li[data-low="yes"] { color: var(--coral); border-color: var(--coral); }
}

.field {
  display: flex;
  align-items: center;
  gap: var(--s2);
  font-size: .86rem;

  & input {
    width: 88px;
    min-height: 40px;
    padding: 6px 12px;
    border: 2px solid var(--line);
    border-radius: var(--pill);
    background: var(--paper);
    font-family: var(--body);
    font-size: .95rem;
    font-variant-numeric: tabular-nums;
    color: var(--ink);

    &:focus-visible { border-color: var(--theme); }
  }
}

/* ---------- records / leaderboard ---------- */

.records-empty {
  padding: var(--s5);
  text-align: center;
  color: var(--ink-soft);
}

.stat-strip {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
  gap: var(--s4);
  margin-bottom: var(--s6);
}

.stat {
  padding: var(--s4);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--paper-lift);

  & b {
    display: block;
    font-family: var(--display);
    font-size: 1.9rem;
    line-height: 1.05;
    font-variant-numeric: tabular-nums;
  }

  & span {
    font-family: var(--display);
    font-size: .7rem;
    letter-spacing: .14em;
    text-transform: uppercase;
    color: var(--ink-soft);
  }
}

/* ---------- misc ---------- */

.contact-card {
  padding: clamp(var(--s5), 3vw, var(--s6));
  text-align: left;

  & .mail {
    display: inline-block;
    font-family: var(--display);
    font-size: clamp(1.2rem, 3vw, 1.7rem);
    font-weight: 600;
    color: var(--cobalt);
    text-decoration: underline;
    text-underline-offset: 5px;
    word-break: break-word;
  }
}

.res-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: var(--s4);
  list-style: none;
  margin: 0;
  padding: 0;
}

.res-list li {
  padding: var(--s4);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--paper-lift);

  & b {
    display: block;
    font-family: var(--display);
    font-size: 1.02rem;
    letter-spacing: .03em;
    margin-bottom: 4px;
  }

  & span {
    display: block;
    font-size: .88rem;
    color: var(--ink-soft);
    margin-bottom: var(--s2);
  }

  & a {
    font-size: .9rem;
    word-break: break-word;
    color: var(--cobalt);
    text-decoration: underline;
    text-underline-offset: 3px;

    &::after { content: "\00a0\2192"; }
  }
}

.skip {
  position: absolute;
  left: -9999px;

  &:focus {
    left: 12px;
    top: 12px;
    z-index: 90;
    padding: 10px 16px;
    background: var(--ink);
    color: var(--paper);
    border-radius: var(--radius-sm);
  }
}

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