/* Layout: a dim-sum menu. A squishable dumpling up top, then the game laid out like a menu card:
   worlds as courses, the squad as the kitchen crew, the daily round as today's special. */
:root {
  /* Color: steamed-bun cream on a blush ground, soy-brown ink, the icon's coral, bamboo-steamer tan. */
  --ground: #fff1ea;
  --paper: #fffaf6;
  --ink: #3d241d;
  --ink-soft: #7a5a4f;
  --coral: #ec5a45;
  --coral-deep: #c63f2e;
  --bamboo: #c9a06a;
  --line: #f0d9cc;
  --on-coral: #ffffff;

  /* Type: a chunky Japanese-rounded display face, a rounded body face, monospace for the share grid. */
  --display: "Mochiy Pop One", "Hiragino Maru Gothic ProN", "Arial Rounded MT Bold", system-ui, sans-serif;
  --body: "M PLUS Rounded 1c", "Hiragino Maru Gothic ProN", ui-rounded, system-ui, sans-serif;
  --mono: "DM Mono", ui-monospace, "SF Mono", Menlo, monospace;

  --step--1: 0.875rem;
  --step-0: 1.0625rem;
  --step-1: 1.3rem;
  --step-2: 1.75rem;
  --step-3: clamp(2.2rem, 5vw, 3.1rem);
  --step-4: clamp(3rem, 10vw, 5.6rem);

  --radius: 22px;
  --measure: 64ch;
  color-scheme: light;
}

/* Dark: the game's Night Market, plum sky and lantern light. */
@media (prefers-color-scheme: dark) {
  :root {
    --ground: #1d1526;
    --paper: #2a2036;
    --ink: #fbeee6;
    --ink-soft: #c8b5c4;
    --coral: #ff7a63;
    --coral-deep: #ff9a86;
    --bamboo: #e2bb82;
    --line: #3d3050;
    --on-coral: #2a1018;
    color-scheme: dark;
  }
}

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

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

body {
  margin: 0;
  background: var(--ground);
  color: var(--ink);
  font-family: var(--body);
  font-size: var(--step-0);
  line-height: 1.6;
  font-weight: 500;
}

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

a { color: var(--coral-deep); text-underline-offset: 0.18em; text-decoration-thickness: 2px; }
a:hover { color: var(--coral); }
:focus-visible { outline: 3px solid var(--coral); outline-offset: 3px; border-radius: 6px; }

h1, h2, h3 { font-family: var(--display); font-weight: 400; line-height: 1.15; text-wrap: balance; margin: 0; }
h2 { font-size: var(--step-3); }
h3 { font-size: var(--step-1); }
p { margin: 0; }

.wrap { width: min(1080px, 100%); margin-inline: auto; padding-inline: 20px; }

.label {
  font-family: var(--body);
  font-weight: 800;
  font-size: var(--step--1);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--coral-deep);
}

/* Header and footer */

.site-header .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding-block: 18px;
}
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; color: var(--ink); }
.brand img { width: 40px; height: 40px; border-radius: 10px; }
.brand span { font-family: var(--display); font-size: 1.35rem; }
.site-nav { display: flex; gap: 18px; flex-wrap: wrap; font-weight: 700; }
.site-nav a { color: var(--ink-soft); text-decoration: none; }
.site-nav a:hover, .site-nav a[aria-current="page"] { color: var(--ink); text-decoration: underline; }

.site-footer { border-top: 2px dashed var(--line); margin-top: 72px; }
.site-footer .wrap {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 12px 24px;
  padding-block: 28px 40px;
  color: var(--ink-soft);
  font-size: var(--step--1);
}
.site-footer nav { display: flex; gap: 18px; flex-wrap: wrap; }

/* Landing: hero */

.hero .wrap {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr);
  align-items: center;
  gap: 32px;
  padding-block: 24px 56px;
}
.hero h1 { font-size: var(--step-4); color: var(--coral); letter-spacing: -0.01em; }
.hero .pitch { font-size: var(--step-1); max-width: 30ch; margin-top: 14px; text-wrap: pretty; }
.hero .facts { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 22px; padding: 0; list-style: none; }
.hero .facts li {
  background: var(--paper);
  border: 2px solid var(--line);
  border-radius: 999px;
  padding: 4px 14px;
  font-weight: 700;
  font-size: var(--step--1);
}
.store {
  display: inline-flex;
  flex-direction: column;
  margin-top: 26px;
  padding: 12px 22px;
  border-radius: 16px;
  background: var(--ink);
  color: var(--ground);
  line-height: 1.25;
}
.store small { font-size: 0.78rem; opacity: 0.8; font-weight: 700; }
.store strong { font-family: var(--display); font-weight: 400; font-size: 1.15rem; }

/* The squishable dumpling */

.squish { display: grid; justify-items: center; gap: 10px; }
.squish button {
  appearance: none;
  border: 0;
  padding: 0;
  background: none;
  cursor: pointer;
  width: min(360px, 82vw);
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
  position: relative;
}
.squish button::before {
  /* The steamer-basket glow behind it. */
  content: "";
  position: absolute;
  inset: 8% 4% 0;
  border-radius: 50%;
  background: radial-gradient(closest-side, color-mix(in oklab, var(--coral) 22%, transparent), transparent);
  z-index: -1;
}
.squish img { transform-origin: 50% 96%; width: 100%; }
.squish img.squashed { animation: squash 360ms cubic-bezier(.2, 1.6, .4, 1); }
@keyframes squash {
  0% { transform: scale(1.16, 0.82); }
  100% { transform: scale(1, 1); }
}
.squish .meter {
  display: flex;
  gap: 14px;
  align-items: baseline;
  font-variant-numeric: tabular-nums;
  font-weight: 800;
}
.squish .count { font-family: var(--display); font-size: var(--step-2); }
.squish .combo { color: var(--coral-deep); min-width: 7ch; }
.squish .hint { color: var(--ink-soft); font-size: var(--step--1); }
.puff {
  position: absolute;
  font-family: var(--display);
  color: var(--coral);
  pointer-events: none;
  animation: rise 700ms ease-out forwards;
}
@keyframes rise { to { transform: translateY(-70px); opacity: 0; } }

/* Landing: sections */

.section { padding-block: 56px; }
.section > .wrap { display: grid; gap: 26px; }
.section .intro { display: grid; gap: 10px; max-width: var(--measure); }
.section .intro p { color: var(--ink-soft); }

.modes { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 20px; }
.mode { background: var(--paper); border-radius: var(--radius); padding: 24px; display: grid; gap: 12px; align-content: start; }
.mode p { color: var(--ink-soft); }

.share-grid {
  font-family: var(--mono);
  font-size: 0.95rem;
  line-height: 1.55;
  background: var(--ground);
  border: 2px dashed var(--line);
  border-radius: 14px;
  padding: 12px 14px;
  white-space: pre;
  overflow-x: auto;
  color: var(--ink);
}

/* The worlds, set like a menu: course, then the boss as the chef's special. */
.menu { background: var(--paper); border-radius: var(--radius); padding: 10px 24px; }
.menu ol { list-style: none; margin: 0; padding: 0; }
.menu li {
  display: grid;
  grid-template-columns: 64px minmax(0, 1fr) auto;
  align-items: center;
  gap: 16px;
  padding-block: 14px;
  border-bottom: 2px dotted var(--line);
}
.menu li:last-child { border-bottom: 0; }
.menu img { width: 64px; height: 64px; object-fit: contain; }
.menu .world { font-family: var(--display); font-size: var(--step-1); }
.menu .boss { color: var(--ink-soft); font-size: var(--step--1); }
.menu .stages { font-variant-numeric: tabular-nums; font-weight: 800; color: var(--bamboo); white-space: nowrap; }
.menu-note { color: var(--ink-soft); font-size: var(--step--1); }

.crew { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 14px; }
.crew li { display: flex; align-items: center; gap: 12px; background: var(--paper); border-radius: 18px; padding: 12px 14px; }
.crew ul, .crew { list-style: none; margin: 0; padding: 0; }
.crew img { width: 56px; flex: none; }
.crew strong { display: block; font-weight: 800; }
.crew span { color: var(--ink-soft); font-size: var(--step--1); line-height: 1.35; }

.extras { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 24px; list-style: none; margin: 0; padding: 0; }
.extras li { display: grid; gap: 6px; align-content: start; }
.extras p { color: var(--ink-soft); }

/* Support and legal pages */

.doc .wrap { max-width: calc(var(--measure) + 40px); display: grid; gap: 18px; padding-block: 24px 0; }
.doc h1 { font-size: var(--step-3); color: var(--coral); }
.doc h2 { font-size: var(--step-1); margin-top: 18px; }
.doc .meta { color: var(--ink-soft); font-size: var(--step--1); font-weight: 700; }
.doc ul { margin: 0; padding-left: 1.2em; display: grid; gap: 6px; }
.doc details { background: var(--paper); border-radius: 16px; padding: 14px 18px; }
.doc summary { font-weight: 800; cursor: pointer; }
.doc details > *:not(summary) { margin-top: 10px; }
.doc .contact { background: var(--paper); border-radius: var(--radius); padding: 22px; display: grid; gap: 8px; }
.doc .email { font-family: var(--mono); font-size: 1.05rem; user-select: all; }
.path { font-weight: 800; white-space: nowrap; }

@media (max-width: 760px) {
  .site-nav { gap: 14px; font-size: var(--step--1); }
  .brand img { width: 34px; height: 34px; }
  .brand span { font-size: 1.15rem; }
  .hero .wrap { grid-template-columns: 1fr; text-align: left; }
  .squish { order: -1; }
  .menu li { grid-template-columns: 52px minmax(0, 1fr); }
  .menu img { width: 52px; height: 52px; }
  .menu .stages { grid-column: 2; }
}

@media (prefers-reduced-motion: reduce) {
  .squish img.squashed, .puff { animation: none; }
}
