/* Candy Arena (layout A), from the website design canvas. Mobile first. */
:root {
  --paper: #fff3f6;
  --card: #ffffff;
  --ink: #3a2340;
  --muted: #6e4e74;
  --faint: #9c86a1;
  --line: #ffd6e0;
  --line-strong: #f2c4d2;
  --blush: #ffe3ea;
  --field: #fff9fb;
  --accent: #d93c4f;
  --sunny: #ffe07a;
  --mint: #8fe3c8;
  --mint-ink: #12382d;
  --win: #1e8c6e;
  --lose-bg: #ffd6e0;
  --lose-ink: #8a1f33;
  --title-yellow: #ffd23f;
  --outline: #1a1a1a;
  --display: "Baloo 2", "Trebuchet MS", sans-serif;
  --body: "Nunito", "Trebuchet MS", system-ui, sans-serif;
  --shadow: 0 6px 0 rgba(58, 35, 64, 0.12);
  --gutter: 16px;
}

@media (min-width: 720px) {
  :root {
    --gutter: 24px;
  }
}

* {
  box-sizing: border-box;
}

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

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--body);
  font-size: 17px;
  line-height: 1.5;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

body > main {
  flex: 1 0 auto;
}

img,
video {
  max-width: 100%;
}

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

a:hover {
  color: var(--accent);
}

:focus-visible {
  outline: 3px solid var(--accent);
  outline-offset: 2px;
}

h1,
h2,
h3 {
  font-family: var(--display);
  font-weight: 800;
  line-height: 1.05;
  margin: 0;
  overflow-wrap: anywhere;
}

h1 {
  font-size: clamp(36px, 9vw, 64px);
  line-height: 1;
}

h2 {
  font-size: clamp(28px, 6vw, 40px);
  line-height: 1.1;
}

p {
  margin: 0;
}

[hidden] {
  display: none !important;
}

.icon {
  fill: none;
  stroke: currentColor;
  stroke-width: 2.2;
  stroke-linecap: round;
  stroke-linejoin: round;
  flex: none;
}

.icon-accent {
  stroke: var(--accent);
  stroke-width: 2.5;
}

.muted {
  color: var(--muted);
}

.small {
  font-size: 14px;
}

.strong {
  font-weight: 800;
}

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

.centre {
  align-self: center;
  text-align: center;
}

.kicker {
  font-size: 13px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--muted);
}

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

.lede {
  font-size: 19px;
  color: var(--muted);
  max-width: 34em;
}

.empty {
  background: var(--card);
  border-radius: 20px;
  padding: 18px 20px;
  color: var(--muted);
  font-weight: 700;
}

.card {
  background: var(--card);
  border-radius: 28px;
  padding: 20px;
}

/* ---- Header and footer --------------------------------------------------- */

.site-header {
  background: var(--card);
  border-bottom: 3px solid var(--line);
}

.site-header-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 10px var(--gutter);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 10px 24px;
}

.site-logo {
  display: flex;
  text-decoration: none;
}

.site-logo img {
  height: 64px;
  width: auto;
  display: block;
}

@media (min-width: 720px) {
  .site-logo img {
    height: 88px;
  }
}

.site-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 16px;
  font-weight: 800;
  font-size: 15px;
  order: 3;
  width: 100%;
}

.site-nav a {
  text-decoration: none;
  padding: 6px 0;
}

.site-nav a[aria-current="page"] {
  color: var(--accent);
}

@media (min-width: 1000px) {
  .site-nav {
    order: 0;
    width: auto;
  }
}

.site-me {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--paper);
  border-radius: 999px;
  padding: 6px 14px;
  min-height: 44px;
  font-weight: 800;
  font-size: 15px;
  text-decoration: none;
  color: var(--ink);
}

.pips {
  display: inline-flex;
  gap: 6px;
}

.pip {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  border: 2px solid var(--accent);
}

.pip-on {
  background: var(--accent);
}

.site-footer {
  background: var(--ink);
  color: var(--blush);
  margin-top: 32px;
}

.site-footer-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 20px var(--gutter);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px 24px;
  font-size: 15px;
}

.site-footer img {
  height: 60px;
  width: auto;
  display: block;
}

.site-footer nav {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 20px;
  font-weight: 700;
}

.site-footer a {
  color: var(--blush);
}

/* ---- Page frames --------------------------------------------------------- */

.page,
.section,
.hero {
  max-width: 1200px;
  margin: 0 auto;
  padding: 32px var(--gutter) 24px;
  width: 100%;
}

.page {
  display: flex;
  flex-direction: column;
  gap: 26px;
}

.page-narrow {
  max-width: 1100px;
}

.page-form {
  max-width: 720px;
}

.page-head {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.section {
  display: flex;
  flex-direction: column;
  gap: 18px;
  padding-top: 48px;
}

.section-tight {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.section-head {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: baseline;
  gap: 8px 20px;
}

.split {
  display: flex;
  flex-wrap: wrap;
  gap: 24px;
  align-items: stretch;
}

.section.split {
  flex-direction: row;
  align-items: center;
}

.split-main {
  flex: 3 1 520px;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.split-side {
  flex: 2 1 300px;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

/* ---- Tags, pills, buttons ------------------------------------------------ */

.tag {
  align-self: flex-start;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--sunny);
  color: var(--ink);
  font-weight: 800;
  font-size: 14px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 6px 14px;
  border-radius: 999px;
}

.tag-white {
  background: var(--card);
  text-transform: none;
  letter-spacing: 0;
}

.pill-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 16px;
  align-items: center;
}

.pill-big {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-weight: 800;
  padding: 8px 16px;
  border-radius: 22px;
  background: var(--card);
}

.pill-sunny {
  background: var(--sunny);
}

.pill-mint {
  border: 2px solid var(--mint);
}

p.pill-big.pill-mint {
  background: var(--mint);
  color: var(--mint-ink);
}

.pill {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-weight: 800;
  font-size: 14px;
  padding: 4px 12px;
  border-radius: 999px;
  white-space: nowrap;
}

.pill-won {
  background: var(--mint);
  color: var(--mint-ink);
}

.pill-lost {
  background: var(--lose-bg);
  color: var(--lose-ink);
}

.pill-crowned {
  background: var(--sunny);
  color: var(--ink);
}

.pill-locked {
  background: var(--blush);
  color: var(--ink);
}

.badge {
  position: absolute;
  top: 8px;
  left: 8px;
  font-weight: 800;
  font-size: 13px;
  padding: 3px 10px;
  border-radius: 999px;
}

.badge-won {
  background: var(--mint);
  color: var(--mint-ink);
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-family: var(--display);
  font-weight: 800;
  font-size: 20px;
  line-height: 1.2;
  background: var(--accent);
  color: #ffffff;
  text-decoration: none;
  border: 0;
  border-radius: 16px;
  padding: 10px 22px;
  min-height: 48px;
  cursor: pointer;
  text-align: center;
}

.button:hover {
  color: #ffffff;
  filter: brightness(1.05);
}

.button:disabled {
  opacity: 0.6;
  cursor: default;
}

.button-big {
  font-size: 22px;
  min-height: 52px;
  padding: 10px 30px;
}

.button-quiet {
  font-family: var(--body);
  font-size: 17px;
  background: var(--card);
  color: var(--ink);
  border: 2px solid var(--line-strong);
}

.button-quiet:hover {
  color: var(--accent);
}

.link-button {
  font: inherit;
  font-size: 15px;
  font-weight: 700;
  background: transparent;
  color: var(--muted);
  border: 0;
  text-decoration: underline;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 44px;
  padding: 0 4px;
}

.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
}

.actions-end {
  margin-left: auto;
}

.actions-right {
  justify-content: flex-end;
}

/* ---- Stats ---------------------------------------------------------------- */

.stats {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

@media (min-width: 720px) {
  .stats-3 {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
  .stats-4 {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}

.stat {
  background: var(--card);
  border-radius: 18px;
  padding: 12px 16px;
  min-width: 0;
}

.stat-label {
  font-size: 13px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--muted);
}

.stats-3 .stat {
  display: flex;
  flex-direction: column-reverse;
  justify-content: flex-end;
}

.stats-3 .stat-label {
  text-transform: none;
  letter-spacing: 0;
  font-size: 14px;
  font-weight: 700;
}

.stat-value {
  font-family: var(--display);
  font-weight: 800;
  font-size: clamp(24px, 5vw, 36px);
  line-height: 1.15;
  overflow-wrap: anywhere;
}

.tone-win {
  color: var(--win);
}

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

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

.hero {
  display: flex;
  flex-wrap: wrap;
  gap: 40px;
  align-items: center;
  padding-top: 32px;
}

.hero-words {
  flex: 1 1 480px;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.hero-art {
  flex: 1 1 440px;
  min-width: 0;
  position: relative;
  padding-bottom: 40px;
}

.arena-frame {
  position: relative;
  border-radius: 32px;
  overflow: hidden;
  aspect-ratio: 4 / 3.4;
  background: var(--line);
}

.arena-plate {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.champion-card {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -46%) rotate(-3deg);
  width: 58%;
  background: var(--card);
  border-radius: 28px;
  padding: 12px 12px 8px;
  box-shadow: 0 8px 0 rgba(58, 35, 64, 0.18);
}

.champion-card .portrait {
  width: 100%;
  border-radius: 18px;
}

.champion-card-name {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 8px;
  padding: 8px 6px 2px;
}

.champion-card-name a {
  font-family: var(--display);
  font-weight: 800;
  font-size: clamp(18px, 4vw, 26px);
  line-height: 1.1;
  text-decoration: none;
  min-width: 0;
  overflow-wrap: anywhere;
}

.blossom-says {
  position: absolute;
  left: -6px;
  bottom: 0;
  display: flex;
  align-items: flex-end;
}

.blossom-says img {
  width: 110px;
  height: 110px;
  object-fit: cover;
  border-radius: 50%;
  border: 5px solid var(--card);
  background: var(--card);
  flex: none;
}

.bubble {
  margin-bottom: 96px;
  margin-left: -10px;
  background: var(--card);
  border: 3px solid var(--ink);
  border-radius: 18px 18px 18px 4px;
  padding: 8px 14px;
  font-weight: 800;
  font-size: 15px;
  max-width: 190px;
  line-height: 1.3;
}

@media (max-width: 719px) {
  /* On a phone the champion comes first, and Blossom talks from just below the arena. */
  .hero-art {
    order: -1;
    padding-bottom: 0;
  }
  .blossom-says {
    position: relative;
    left: 0;
    margin-top: -48px;
    align-items: center;
    gap: 4px;
  }
  .blossom-says img {
    width: 96px;
    height: 96px;
  }
  .bubble {
    margin: 40px 0 0;
    max-width: none;
  }
}

@media (min-width: 720px) {
  .blossom-says {
    left: -18px;
    bottom: -12px;
  }
  .blossom-says img {
    width: 150px;
    height: 150px;
  }
  .bubble {
    margin-bottom: 96px;
  }
}

/* ---- The challenge form --------------------------------------------------- */

.challenge {
  background: var(--card);
  border: 3px solid var(--line);
  border-radius: 24px;
  padding: 14px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

@media (min-width: 480px) {
  .challenge {
    padding: 18px;
  }
}

.challenge label,
.nickname-form label {
  font-weight: 800;
  font-size: 15px;
}

.challenge-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.challenge-row input {
  flex: 1 1 220px;
  min-width: 0;
  font: inherit;
  font-size: 19px;
  padding: 12px 16px;
  border: 2px solid var(--line-strong);
  border-radius: 16px;
  background: var(--field);
  color: var(--ink);
}

.challenge-row input.is-invalid {
  border-color: var(--accent);
}

.challenge-row .button {
  flex: 1 0 auto;
}

@media (min-width: 480px) {
  .challenge-row .button {
    flex: 0 0 auto;
  }
}

.challenge-done {
  gap: 4px;
}

.form-note {
  font-size: 14px;
  color: var(--muted);
}

.form-status {
  font-weight: 800;
  font-size: 15px;
  color: var(--muted);
}

.form-status:empty {
  display: none;
}

.form-status.is-error {
  color: var(--lose-ink);
}

.cf-turnstile {
  max-width: 100%;
}

.cf-turnstile:empty {
  display: none;
}

.ideas {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

.ideas-label {
  font-size: 14px;
  font-weight: 800;
  color: var(--muted);
}

.idea {
  font: inherit;
  font-size: 15px;
  font-weight: 800;
  background: var(--paper);
  border: 0;
  border-radius: 999px;
  padding: 8px 14px;
  cursor: pointer;
  color: var(--ink);
  min-height: 40px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.idea-shuffle {
  background: transparent;
  border: 2px dashed #f2a8bc;
  color: var(--accent);
}

/* ---- Pictures with the title laid over them ------------------------------- */

.picture {
  position: relative;
  border-radius: 24px;
  overflow: hidden;
  aspect-ratio: 3 / 2;
  background: var(--ink);
  container-type: inline-size;
}

@media (min-width: 720px) {
  .picture-big {
    border-radius: 32px;
  }
}

.picture > img,
.picture > video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.picture-pending {
  position: absolute;
  inset: 0;
  background: var(--blush);
  display: grid;
  place-items: center;
}

.picture-words {
  position: absolute;
  top: 4%;
  left: 3%;
  right: 3%;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.5cqw;
  text-align: center;
  pointer-events: none;
}

.picture-title {
  font-family: var(--display);
  font-weight: 800;
  font-size: 30px;
  font-size: 7.5cqw;
  line-height: 0.95;
  color: var(--title-yellow);
  -webkit-text-stroke: 0.35cqw var(--outline);
  paint-order: stroke fill;
  text-shadow:
    0 0.45cqw 0 #c2410c,
    0 0.8cqw 0 var(--outline);
  transform: rotate(-2deg);
  overflow-wrap: anywhere;
}

.picture-subtitle {
  font-family: var(--display);
  font-weight: 800;
  font-size: 16px;
  font-size: 3cqw;
  line-height: 1.05;
  color: #ffffff;
  -webkit-text-stroke: 0.18cqw var(--outline);
  paint-order: stroke fill;
  text-shadow: 0 0.3cqw 0 var(--outline);
}

.picture-label {
  position: absolute;
  left: 12px;
  top: 12px;
  background: rgba(255, 255, 255, 0.92);
  border-radius: 999px;
  padding: 4px 12px;
  font-weight: 800;
  font-size: 14px;
}

.play-chip {
  position: absolute;
  left: 12px;
  bottom: 12px;
  display: flex;
  align-items: center;
  gap: 10px;
  background: var(--card);
  color: var(--ink);
  border-radius: 999px;
  padding: 6px 16px 6px 6px;
  font-weight: 800;
  font-size: 15px;
  text-decoration: none;
  box-shadow: 0 4px 0 rgba(26, 26, 26, 0.35);
  min-height: 44px;
}

.play-dot {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--accent);
  color: #ffffff;
  display: grid;
  place-items: center;
}

.play-dot svg {
  width: 18px;
  height: 18px;
}

.spinner {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  border: 6px solid var(--line);
  border-top-color: var(--accent);
  animation: spin 1s linear infinite;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

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

.blurred {
  filter: blur(14px) saturate(0.8);
  transform: scale(1.15);
}

/* ---- Portraits ------------------------------------------------------------ */

.portrait {
  display: block;
  aspect-ratio: 1;
  object-fit: cover;
  background: var(--card);
  width: 100%;
  height: auto;
}

.portrait-blank {
  display: grid;
  place-items: center;
  font-family: var(--display);
  font-weight: 800;
  font-size: clamp(22px, 8vw, 64px);
  color: var(--ink);
}

/* ---- Fight cards (home) --------------------------------------------------- */

.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 260px), 1fr));
  gap: 16px;
}

.fight-card {
  background: var(--card);
  border-radius: 24px;
  padding: 10px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  border: 3px solid transparent;
  min-width: 0;
}

.fight-card-won {
  border-color: var(--mint);
}

.fight-card-picture {
  position: relative;
  display: block;
  border-radius: 16px;
  overflow: hidden;
  aspect-ratio: 3 / 2;
  background: var(--blush);
}

.fight-card-picture img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.lock-badge {
  position: absolute;
  inset: 0;
  margin: auto;
  width: max-content;
  height: max-content;
  display: flex;
  align-items: center;
  gap: 8px;
  background: rgba(255, 255, 255, 0.92);
  border-radius: 999px;
  padding: 8px 14px;
  font-weight: 800;
  font-size: 15px;
}

.fight-card-words {
  padding: 0 6px 6px;
  display: flex;
  flex-direction: column;
  gap: 2px;
  font-size: 15px;
}

.fight-card-name {
  font-family: var(--display);
  font-weight: 800;
  font-size: 22px;
  line-height: 1.15;
  text-decoration: none;
  overflow-wrap: anywhere;
}

/* ---- Champion chain strip (home) ------------------------------------------ */

.chain-strip {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
}

.chain-item {
  display: flex;
  align-items: center;
  gap: 12px;
  background: var(--card);
  border-radius: 22px;
  padding: 10px 18px 10px 10px;
  border: 3px solid transparent;
  min-width: 0;
  max-width: 100%;
}

.chain-today {
  border-color: var(--accent);
}

.chain-today .kicker {
  color: var(--accent);
}

.chain-next {
  background: transparent;
  border: 3px dashed #f2a8bc;
}

.chain-portrait {
  width: 64px;
  height: 64px;
  border-radius: 16px;
  flex: none;
  font-size: 28px;
}

.chain-question {
  background: var(--blush);
  display: grid;
  place-items: center;
  font-family: var(--display);
  font-weight: 800;
  font-size: 36px;
  color: var(--accent);
}

.chain-words {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.chain-name {
  font-family: var(--display);
  font-weight: 800;
  font-size: 22px;
  line-height: 1.1;
  text-decoration: none;
  overflow-wrap: anywhere;
}

.chain-arrow {
  display: flex;
}

@media (max-width: 719px) {
  .chain-strip {
    flex-direction: column;
    align-items: stretch;
  }
  .chain-arrow {
    justify-content: center;
    transform: rotate(90deg);
  }
}

/* ---- Verdict ---------------------------------------------------------------- */

.verdict {
  display: flex;
  gap: 14px;
  align-items: flex-start;
}

.verdict-face {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  object-fit: cover;
  background: var(--card);
  border: 4px solid var(--card);
  flex: none;
}

@media (min-width: 720px) {
  .verdict:not(.verdict-small) .verdict-face {
    width: 96px;
    height: 96px;
  }
}

.verdict blockquote {
  margin: 0;
  background: var(--card);
  border-radius: 4px 24px 24px 24px;
  padding: 16px 20px;
  font-size: 19px;
  line-height: 1.55;
  min-width: 0;
}

.verdict-small blockquote {
  font-size: 17px;
}

.verdict footer {
  margin-top: 6px;
  font-weight: 800;
  font-size: 14px;
  color: var(--muted);
}

/* ---- Fight page ------------------------------------------------------------ */

.crumbs {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 10px;
  font-weight: 700;
  font-size: 15px;
  color: var(--muted);
}

.crumb-here {
  color: var(--ink);
}

.tape h2 {
  font-size: 26px;
}

.tape-faces {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
  gap: 8px;
  align-items: center;
  text-align: center;
}

.tape-faces a {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  text-decoration: none;
  font-weight: 800;
  min-width: 0;
  overflow-wrap: anywhere;
}

.tape-faces .portrait {
  border-radius: 18px;
  border: 3px solid var(--line);
}

.tape-winner .portrait {
  border-color: var(--mint);
}

.vs {
  font-family: var(--display);
  font-weight: 800;
  font-size: 34px;
  color: var(--accent);
  line-height: 1;
}

.vs-big {
  font-size: clamp(36px, 10vw, 56px);
}

.tape-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 16px;
  font-variant-numeric: tabular-nums;
}

.tape-table tr + tr {
  border-top: 2px solid var(--paper);
}

.tape-table td,
.tape-table th {
  padding: 8px 0;
  overflow-wrap: anywhere;
}

.tape-table td {
  font-weight: 800;
  width: 38%;
}

.tape-table td:last-child {
  text-align: right;
}

.tape-table th {
  color: var(--muted);
  font-weight: 700;
  text-align: center;
  padding-inline: 6px;
}

/* ---- Fight in progress ------------------------------------------------------ */

.versus {
  display: flex;
  flex-wrap: nowrap;
  align-items: center;
  justify-content: center;
  gap: 12px 24px;
}

.versus figure {
  margin: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  max-width: 40%;
}

.versus-portrait {
  width: min(168px, 32vw);
  max-width: 100%;
  border-radius: 28px;
  border: 4px solid var(--card);
  box-shadow: var(--shadow);
}

.versus figcaption {
  font-family: var(--display);
  font-weight: 800;
  font-size: clamp(20px, 5vw, 26px);
  line-height: 1;
  text-align: center;
  overflow-wrap: anywhere;
}

.progress-head {
  display: flex;
  gap: 12px;
  align-items: center;
}

.progress-head img {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  object-fit: cover;
  flex: none;
  border: 3px solid var(--line);
}

.progress-title {
  font-family: var(--display);
  font-size: 24px;
  line-height: 1.1;
  display: block;
}

.steps {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
  font-weight: 700;
  color: var(--faint);
}

.steps li {
  display: flex;
  align-items: center;
  gap: 12px;
}

.step-dot {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  flex: none;
  background: var(--card);
  border: 2px solid var(--line-strong);
  display: grid;
  place-items: center;
}

.steps .step-now,
.steps .step-done {
  color: var(--ink);
}

.step-now .step-dot {
  border-color: var(--accent);
}

.step-done .step-dot {
  background: var(--win);
  border-color: var(--win);
}

.step-done .step-dot::after {
  content: "";
  width: 10px;
  height: 6px;
  border: solid #ffffff;
  border-width: 0 0 3px 3px;
  transform: translateY(-1px) rotate(-45deg);
}

.progress-verdict {
  margin: 0;
  background: var(--paper);
  border-radius: 4px 20px 20px 20px;
  padding: 12px 16px;
}

.progress-foot {
  margin-top: auto;
}

/* ---- Whistle ---------------------------------------------------------------- */

.whistle {
  max-width: 980px;
  flex-direction: row;
  flex-wrap: wrap;
  align-items: center;
  gap: 32px;
  padding-top: 40px;
}

.whistle-blossom {
  flex: 0 1 300px;
  width: 220px;
  max-width: 100%;
  height: auto;
  aspect-ratio: 1;
  object-fit: cover;
  border-radius: 50%;
  background: var(--card);
  border: 8px solid var(--card);
  margin: 0 auto;
}

@media (min-width: 720px) {
  .whistle-blossom {
    width: 300px;
  }
}

.whistle-words {
  flex: 1 1 420px;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.whistle-words h1 {
  font-size: clamp(34px, 8vw, 52px);
}

.free-try {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 800;
  color: var(--win);
}

/* ---- Contender ---------------------------------------------------------------- */

.profile {
  display: flex;
  flex-wrap: wrap;
  gap: 32px;
  align-items: center;
}

.profile-portrait {
  flex: 0 1 340px;
  min-width: 0;
  max-width: 340px;
  margin: 0 auto;
  background: var(--card);
  border-radius: 32px;
  padding: 14px;
  transform: rotate(-2deg);
  box-shadow: 0 8px 0 rgba(58, 35, 64, 0.12);
}

.profile-portrait .portrait {
  border-radius: 22px;
}

.profile-words {
  flex: 1 1 460px;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.profile-name {
  font-size: clamp(44px, 11vw, 72px);
  line-height: 0.95;
}

.rivals {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 320px), 1fr));
  gap: 16px;
}

.rival {
  background: var(--card);
  border-radius: 24px;
  padding: 14px;
  display: flex;
  gap: 16px;
  align-items: center;
  text-decoration: none;
  border: 3px solid var(--line);
  min-width: 0;
}

.rival-victim {
  border-color: var(--mint);
}

.rival-empty {
  flex-direction: column;
  align-items: flex-start;
  gap: 2px;
}

.rival-portrait {
  width: 88px;
  height: 88px;
  border-radius: 18px;
  flex: none;
}

.rival-words {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.rival-nemesis .kicker {
  color: var(--accent);
}

.rival-victim .kicker {
  color: var(--win);
}

.rival-name {
  font-family: var(--display);
  font-size: 26px;
  line-height: 1.1;
  overflow-wrap: anywhere;
}

.fight-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.fight-row {
  background: var(--card);
  border-radius: 18px;
  padding: 10px 16px 10px 10px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 16px;
  text-decoration: none;
}

.fight-row-icon {
  width: 52px;
  height: 52px;
  border-radius: 14px;
  flex: none;
  font-size: 24px;
}

.fight-row-locked .fight-row-icon {
  background: var(--blush);
  display: grid;
  place-items: center;
  font-family: var(--display);
  font-weight: 800;
}

.fight-row-words {
  display: flex;
  flex-direction: column;
  flex: 1 1 200px;
  min-width: 0;
  overflow-wrap: anywhere;
}

/* ---- Champion chain page ----------------------------------------------------- */

.chain-cards {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.chain-card {
  background: var(--card);
  border-radius: 28px;
  overflow: hidden;
  display: flex;
  flex-wrap: wrap;
  border: 3px solid var(--card);
}

.chain-card-tomorrow {
  border-color: var(--sunny);
}

.chain-card-today {
  border-color: var(--accent);
}

.chain-card-art {
  flex: 1 1 300px;
  max-width: 100%;
  position: relative;
  aspect-ratio: 3 / 2;
  background: var(--blush);
}

@media (min-width: 720px) {
  .chain-card-art {
    flex: 0 1 340px;
  }
}

.chain-card-portrait {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%) rotate(-3deg);
  width: 46%;
  border-radius: 20px;
  border: 6px solid var(--card);
}

.chain-card-words {
  flex: 1 1 320px;
  min-width: 0;
  padding: 18px 22px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  justify-content: center;
}

.chain-card-name {
  font-family: var(--display);
  font-weight: 800;
  font-size: clamp(28px, 7vw, 36px);
  line-height: 1.05;
  text-decoration: none;
  overflow-wrap: anywhere;
}

.table-box {
  overflow-x: auto;
  background: var(--card);
  border-radius: 22px;
}

.table {
  width: 100%;
  border-collapse: collapse;
  font-variant-numeric: tabular-nums;
}

.table th {
  text-align: left;
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--muted);
  font-weight: 800;
}

.table th,
.table td {
  padding: 12px 14px;
}

.table tbody tr {
  border-top: 2px solid var(--paper);
}

.table a {
  text-decoration: none;
}

@media (min-width: 720px) {
  .table th,
  .table td {
    padding: 12px 18px;
  }
}

/* ---- Day page ------------------------------------------------------------------ */

.day-nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  font-weight: 800;
}

.day-nav .muted {
  color: var(--faint);
}

.day-head {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  align-items: center;
}

.day-portrait {
  width: 120px;
  height: 120px;
  border-radius: 28px;
  border: 5px solid var(--card);
  flex: none;
}

.day-head-words {
  display: flex;
  flex-direction: column;
  gap: 8px;
  min-width: 0;
  flex: 1 1 300px;
}

.day-head h1 {
  font-size: clamp(34px, 8vw, 56px);
}

.day-head h1 a {
  text-decoration: none;
}

.locked-note {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  background: var(--card);
  border-radius: 20px;
  padding: 16px 20px;
  font-weight: 700;
}

/* ---- How to play ------------------------------------------------------------------ */

.how-head {
  display: flex;
  flex-wrap: wrap;
  gap: 24px;
  align-items: center;
  justify-content: space-between;
}

.how-head > div {
  flex: 1 1 420px;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.how-blossom {
  width: 160px;
  height: 160px;
  border-radius: 50%;
  object-fit: cover;
  background: var(--card);
  border: 6px solid var(--card);
  flex: none;
}

.how-steps {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 16px;
}

.how-step {
  border-radius: 24px;
  padding: 14px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.how-step img {
  width: 100%;
  height: auto;
  aspect-ratio: 1;
  object-fit: cover;
  border-radius: 16px;
  background: var(--card);
}

.how-step-number {
  font-family: var(--display);
  font-weight: 800;
  font-size: 20px;
  color: var(--accent);
}

.how-step strong {
  font-family: var(--display);
  font-size: 22px;
  line-height: 1.1;
}

.rule-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 320px), 1fr));
  gap: 14px;
}

.rule {
  border-radius: 22px;
  padding: 18px 20px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.rule strong {
  font-family: var(--display);
  font-size: 24px;
  line-height: 1.2;
}

.arena-grid {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 150px), 1fr));
  gap: 10px;
}

.arena-grid li {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-weight: 800;
  font-size: 14px;
}

.arena-grid img {
  width: 100%;
  height: auto;
  aspect-ratio: 3 / 2;
  object-fit: cover;
  border-radius: 12px;
  background: var(--blush);
}

.safety {
  display: flex;
  flex-direction: column;
  gap: 14px;
  padding: 24px;
  scroll-margin-top: 16px;
}

.safety-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr));
  gap: 20px;
}

.safety-grid > div {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.safety-grid strong {
  font-size: 18px;
}

.safety-grid ul {
  margin: 0;
  padding-left: 20px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

/* ---- Nickname ------------------------------------------------------------------- */

.nickname-form {
  display: flex;
  flex-direction: column;
  gap: 14px;
  padding: 18px;
}

.nickname-form input {
  font-size: 22px;
  font-weight: 800;
  border-width: 3px;
}

.nick-message {
  background: var(--paper);
  border-radius: 14px;
  padding: 10px 14px;
  font-weight: 700;
}

.nick-message.is-error {
  background: var(--blush);
  color: var(--lose-ink);
}

.nick-message.is-ok {
  background: #d7f5e9;
  color: var(--mint-ink);
}

/* ---- Report dialog ---------------------------------------------------------------- */

.report-dialog {
  border: 0;
  border-radius: 24px;
  padding: 22px;
  width: min(420px, calc(100vw - 32px));
  color: var(--ink);
  font-family: var(--body);
}

.report-dialog::backdrop {
  background: rgba(58, 35, 64, 0.45);
}

.report-dialog h2 {
  font-size: 26px;
  margin-bottom: 4px;
}

.report-reasons {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin: 14px 0;
}

.report-reasons .button {
  justify-content: flex-start;
  text-align: left;
}

/* ---- "The arena opens soon" (no day yet) and admin placeholder -------------------- */

.soon {
  max-width: 640px;
  margin: 0 auto;
  padding: 48px var(--gutter);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 18px;
  text-align: center;
}

.soon h1 {
  font-size: clamp(36px, 8vw, 56px);
}

.soon p {
  color: var(--muted);
  font-size: 19px;
}

.soon-logo {
  width: min(440px, 100%);
  height: auto;
}

.soon-blossom {
  width: 220px;
  height: 220px;
  border-radius: 50%;
  border: 6px solid var(--card);
  object-fit: cover;
}
