/* Gladipadel: dark arena. One theme (dark), lime accent, gold only for the crown.
   Shape rule: cards and buttons 12px, chips and pills full round.
   z-index scale: topbar 10, scrim/sheet 30, toast 35, timeout overlay 40. */

@font-face {
  font-family: Anton;
  src: url(/fonts/anton.woff2) format("woff2");
  font-weight: 400;
  font-display: swap;
}
@font-face {
  font-family: Barlow;
  src: url(/fonts/barlow-500.woff2) format("woff2");
  font-weight: 500;
  font-display: swap;
}
@font-face {
  font-family: Barlow;
  src: url(/fonts/barlow-600.woff2) format("woff2");
  font-weight: 600;
  font-display: swap;
}
@font-face {
  font-family: Barlow;
  src: url(/fonts/barlow-700.woff2) format("woff2");
  font-weight: 700;
  font-display: swap;
}

:root {
  color-scheme: dark;
  --bg: #0b0d0a;
  --s1: #12160f;
  --s2: #1a1f16;
  --s3: #232a1d;
  --line: #2c3426;
  --text: #eef2e6;
  --muted: #a7b09a;
  --lime: #a3e635;
  --lime-dim: rgba(163, 230, 53, 0.14);
  --gold: #e8b931;
  --ink: #0b0d0a;
  --team-a: var(--lime);
  --team-b: var(--text);
  --r: 12px;
  --display: Anton, Impact, "Arial Narrow", sans-serif;
  --body: Barlow, "Arial Narrow", system-ui, sans-serif;
  --ease: cubic-bezier(0.16, 1, 0.3, 1);
}

* {
  box-sizing: border-box;
}
html {
  -webkit-text-size-adjust: 100%;
  background: var(--bg);
}
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 500 1rem/1.45 var(--body);
  -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: transparent;
}
h1,
h2,
h3 {
  font-family: var(--display);
  font-weight: 400;
  text-transform: uppercase;
  letter-spacing: 0.01em;
  line-height: 1.05;
  margin: 0;
}
h1 {
  font-size: clamp(2rem, 9vw, 2.6rem);
}
h2 {
  font-size: 1.35rem;
}
p {
  margin: 0;
}
a {
  color: var(--lime);
}
button {
  font: inherit;
  color: inherit;
}
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}
.muted {
  color: var(--muted);
}
.small {
  font-size: 0.9rem;
}
.icon {
  width: 1.15em;
  height: 1.15em;
  flex: none;
}
.noscript {
  padding: 2rem;
}

/* ---------- layout ---------- */
.screen {
  max-width: 520px;
  margin: 0 auto;
  padding: 12px 16px calc(120px + env(safe-area-inset-bottom));
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.screen.center {
  min-height: 100dvh;
  justify-content: center;
  align-items: center;
  text-align: center;
  padding-bottom: 40px;
}
.lede {
  color: var(--muted);
  font-size: 1.08rem;
  font-weight: 600;
  max-width: 40ch;
}
.block {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.status {
  color: var(--muted);
  font-weight: 600;
  text-align: center;
}

.topbar {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 52px;
}
.topbar-spacer {
  flex: 1;
}
.wordmark {
  font-family: var(--display);
  text-transform: uppercase;
  color: var(--lime);
  letter-spacing: 0.05em;
  font-size: 1.6rem;
  text-decoration: none;
}
.wordmark.small {
  font-size: 1.25rem;
}
.topbar .wordmark.small {
  flex: none;
}
.net-pill {
  flex: 1;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--ink);
  background: var(--gold);
  border-radius: 999px;
  padding: 4px 10px;
  text-align: center;
  line-height: 1.2;
}

/* ---------- buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 48px;
  padding: 10px 18px;
  border-radius: var(--r);
  border: 2px solid transparent;
  font-weight: 700;
  font-size: 1.02rem;
  text-decoration: none;
  cursor: pointer;
  white-space: nowrap;
  transition: transform 0.15s var(--ease), background-color 0.2s, opacity 0.2s;
  touch-action: manipulation;
}
.btn:active:not(:disabled) {
  transform: scale(0.98);
}
.btn:disabled {
  opacity: 0.45;
  cursor: default;
}
.btn:focus-visible,
.icon-btn:focus-visible,
.chip:focus-visible,
.point-btn:focus-visible,
.bro-chip:focus-visible,
.bro-btn:focus-visible,
.gladiator-chip:focus-visible,
.war:focus-visible {
  outline: 3px solid var(--lime);
  outline-offset: 2px;
}
.btn-xl {
  min-height: 60px;
  font-family: var(--display);
  font-weight: 400;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  font-size: 1.35rem;
}
.btn-lg {
  min-height: 54px;
}
.btn-primary {
  background: var(--lime);
  color: var(--ink);
}
.btn-secondary {
  background: var(--s3);
  color: var(--text);
}
.btn-ghost {
  background: transparent;
  border-color: var(--line);
  color: var(--text);
}
.btn-quiet {
  background: none;
  color: var(--muted);
  min-height: 44px;
  text-decoration: underline;
  text-underline-offset: 3px;
}
.btn-danger {
  background: var(--text);
  color: var(--ink);
}
.icon-btn {
  display: inline-grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: var(--r);
  background: var(--s2);
  border: 1px solid var(--line);
  color: var(--text);
  cursor: pointer;
  flex: none;
  text-decoration: none;
}
.icon-btn .icon {
  width: 22px;
  height: 22px;
}

/* ---------- mascot + laurel ---------- */
.mascot svg {
  width: 100%;
  height: auto;
  display: block;
}
.mascot-l {
  width: 120px;
}
.mascot-m {
  width: 110px;
}
.mascot-s {
  width: 76px;
  align-self: center;
}
.laurel {
  display: block;
}

/* ---------- home ---------- */
.home .brand {
  padding-top: 8px;
}
.hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 132px;
  gap: 12px;
  align-items: center;
  padding: 8px 0 12px;
}
.hero-copy {
  display: flex;
  flex-direction: column;
  gap: 14px;
  align-items: flex-start;
}
.hero h1 {
  font-size: clamp(2.3rem, 11vw, 3.3rem);
}
.hero-art {
  position: relative;
  display: grid;
  place-items: center;
  align-self: start;
  padding-top: 8px;
}
.hero-laurel {
  position: absolute;
  inset: -6px -10px auto;
  width: calc(100% + 20px);
  color: var(--gold);
  opacity: 0.55;
}
.hero-art .mascot {
  position: relative;
  width: 108px;
  margin-top: 10px;
}
@media (max-width: 380px) {
  .hero {
    grid-template-columns: minmax(0, 1fr) 104px;
  }
  .hero-art .mascot {
    width: 88px;
  }
}
.wars-block {
  display: flex;
  flex-direction: column;
  gap: 10px;
  border-top: 1px solid var(--line);
  padding-top: 18px;
}
.wars {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.war {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 2px 12px;
  padding: 12px 14px;
  border-radius: var(--r);
  background: var(--s1);
  border: 1px solid var(--line);
  color: var(--text);
  text-decoration: none;
}
.war-date {
  color: var(--muted);
  font-size: 0.85rem;
  font-weight: 600;
}
.war-teams {
  grid-column: 1;
  font-weight: 700;
  overflow-wrap: anywhere;
}
.war-teams .vs,
.vs {
  color: var(--muted);
  font-weight: 500;
}
.war-score {
  grid-column: 2;
  grid-row: 1 / span 2;
  align-self: center;
  font-family: var(--display);
  font-size: 1.2rem;
}
.war-emperor {
  grid-column: 1 / -1;
  color: var(--gold);
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.gold {
  color: var(--gold);
}

/* ---------- setup ---------- */
.setup form {
  display: flex;
  flex-direction: column;
  gap: 18px;
}
.team-card {
  margin: 0;
  border: 1px solid var(--line);
  border-left: 4px solid var(--team-a);
  border-radius: var(--r);
  background: var(--s1);
  padding: 12px 14px 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  min-width: 0;
}
.team-card.team-b {
  border-left-color: var(--team-b);
}
.team-card legend {
  font-family: var(--display);
  text-transform: uppercase;
  font-size: 1.2rem;
  color: var(--lime);
  padding: 0 6px;
  margin-left: -6px;
}
.team-card.team-b legend {
  color: var(--text);
}
.gladiator {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.35fr);
  gap: 10px;
  border-top: 1px solid var(--line);
  padding-top: 12px;
}
.gladiator-n {
  grid-column: 1 / -1;
  font-weight: 700;
  color: var(--muted);
  font-size: 0.88rem;
}
.field {
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 0;
}
.field label,
.label {
  font-weight: 700;
  font-size: 0.92rem;
  color: var(--text);
}
.field-row {
  display: flex;
  gap: 6px;
  min-width: 0;
}
.input {
  width: 100%;
  min-width: 0;
  min-height: 46px;
  padding: 10px 12px;
  border-radius: var(--r);
  border: 1px solid #3a4432;
  background: var(--bg);
  color: var(--text);
  font: 600 1rem var(--body);
}
.input:focus {
  outline: 2px solid var(--lime);
  outline-offset: 1px;
  border-color: var(--lime);
}
.reroll {
  height: 46px;
  width: 46px;
}
@media (max-width: 400px) {
  .gladiator {
    grid-template-columns: minmax(0, 1fr);
  }
}
.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.chip {
  min-height: 46px;
  padding: 8px 16px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--s1);
  color: var(--text);
  font-weight: 700;
  cursor: pointer;
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  line-height: 1.15;
}
.chip small {
  font-weight: 600;
  font-size: 0.78rem;
  color: var(--muted);
}
.chip[aria-checked="true"] {
  background: var(--lime);
  border-color: var(--lime);
  color: var(--ink);
}
.chip[aria-checked="true"] small {
  color: #26310f;
}
.form-error {
  color: var(--gold);
  font-weight: 700;
  min-height: 1.4em;
}

/* ---------- share ---------- */
.share {
  text-align: center;
  align-items: stretch;
}
.share .lede {
  margin: 0 auto;
}
.link-box {
  background: var(--s1);
  border: 1px dashed #3a4432;
  border-radius: var(--r);
  padding: 12px;
  font-weight: 700;
  overflow-wrap: anywhere;
  color: var(--lime);
}
.qr {
  margin: 4px auto 0;
  width: 200px;
}
.qr svg {
  width: 100%;
  height: auto;
  border-radius: var(--r);
  background: #fff;
  display: block;
}
.qr figcaption {
  color: var(--muted);
  font-weight: 600;
  margin-top: 8px;
}

/* ---------- join ---------- */
.join {
  text-align: center;
}
.join .lede {
  margin: 0 auto;
}
.join-teams {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  text-align: left;
}
.join-team {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.join-team-name {
  font-family: var(--display);
  text-transform: uppercase;
  color: var(--muted);
  font-size: 1rem;
  overflow-wrap: anywhere;
}
.gladiator-chip {
  display: flex;
  flex-direction: column;
  gap: 2px;
  text-align: left;
  min-height: 72px;
  padding: 12px;
  border-radius: var(--r);
  border: 1px solid var(--line);
  border-left: 4px solid var(--team-a);
  background: var(--s2);
  cursor: pointer;
}
.gladiator-chip.team-b {
  border-left-color: var(--team-b);
}
.gc-nick {
  font-family: var(--display);
  text-transform: uppercase;
  font-size: 1.12rem;
  line-height: 1.1;
  overflow-wrap: anywhere;
}
.gc-name {
  color: var(--muted);
  font-weight: 600;
  font-size: 0.9rem;
}

/* ---------- play ---------- */
.banner {
  position: relative;
  overflow: hidden;
  min-height: 92px;
  display: grid;
  place-items: center;
  text-align: center;
  padding: 14px 16px;
  border-radius: var(--r);
  background: var(--s1);
  border: 1px solid var(--line);
}
.banner p {
  position: relative;
  font-family: var(--display);
  text-transform: uppercase;
  font-size: clamp(1.3rem, 6vw, 1.6rem);
  line-height: 1.12;
  max-width: 24ch;
}
.banner-laurel {
  position: absolute;
  width: 170px;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -48%);
  color: var(--lime);
  opacity: 0.12;
}
.banner-matchPoint,
.banner-setPoint,
.banner-breakPoint,
.banner-golden {
  background: var(--lime);
  border-color: var(--lime);
  color: var(--ink);
}
.banner-matchPoint .banner-laurel,
.banner-setPoint .banner-laurel,
.banner-breakPoint .banner-laurel,
.banner-golden .banner-laurel {
  color: var(--ink);
  opacity: 0.12;
}
@media (prefers-reduced-motion: no-preference) {
  .banner p {
    animation: rise 0.45s var(--ease);
  }
  @keyframes rise {
    from {
      opacity: 0;
      transform: translateY(6px);
    }
  }
}

.board {
  background: var(--s1);
  border: 1px solid var(--line);
  border-radius: var(--r);
  overflow: hidden;
}
.board-row {
  display: flex;
  align-items: stretch;
  min-height: 64px;
}
.board-row + .board-row {
  border-top: 1px solid var(--line);
}
.board-head {
  min-height: 0;
  color: var(--muted);
  font-size: 0.76rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}
.board-head .cell {
  font: inherit;
  padding: 6px 0;
}
.board-team {
  flex: 1;
  min-width: 0;
  padding: 8px 10px 8px 12px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  border-left: 4px solid transparent;
}
.board-row.team-a .board-team {
  border-left-color: var(--team-a);
}
.board-row.team-b .board-team {
  border-left-color: var(--team-b);
}
.team-name {
  font-family: var(--display);
  text-transform: uppercase;
  font-size: 1.12rem;
  line-height: 1.1;
  overflow-wrap: anywhere;
}
.team-nicks {
  display: flex;
  flex-direction: column;
  font-size: 0.86rem;
  font-weight: 600;
  color: var(--muted);
  line-height: 1.25;
}
.nick {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  overflow-wrap: anywhere;
}
.nick.serving {
  color: var(--lime);
}
.serve-ball {
  width: 0.95em;
  height: 0.95em;
}
.cell {
  width: 2.3rem;
  flex: none;
  display: grid;
  place-items: center;
  font-family: var(--display);
  font-size: 1.35rem;
  color: var(--muted);
}
.cell.set.won {
  color: var(--text);
}
.cell.games {
  color: var(--text);
  font-size: 1.6rem;
}
.cell-pts {
  width: 3.6rem;
}
.cell.points {
  background: var(--lime);
  color: var(--ink);
  font-size: 2rem;
}
.board-row.team-b .cell.points {
  background: var(--text);
}

.point-btns {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}
.point-btn {
  min-height: 116px;
  border-radius: var(--r);
  border: 0;
  padding: 12px;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 6px;
  text-align: center;
  color: var(--ink);
  background: var(--team-a);
  touch-action: manipulation;
  transition: transform 0.12s var(--ease), opacity 0.2s;
}
.point-btn.team-b {
  background: var(--team-b);
}
.point-btn:active:not(:disabled) {
  transform: scale(0.97);
}
.point-btn:disabled {
  opacity: 0.4;
}
.pb-team {
  font-family: var(--display);
  text-transform: uppercase;
  font-size: 1.25rem;
  line-height: 1.08;
  overflow-wrap: anywhere;
}
.pb-act {
  font-weight: 700;
  font-size: 0.92rem;
}

.bro-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}
.bro-chip {
  display: flex;
  flex-direction: column;
  gap: 4px;
  text-align: left;
  min-height: 70px;
  padding: 10px 12px;
  border-radius: var(--r);
  border: 1px solid var(--line);
  border-left: 4px solid var(--team-a);
  background: var(--s2);
  cursor: pointer;
}
.bro-chip.team-b {
  border-left-color: var(--team-b);
}
.bro-chip:active {
  transform: scale(0.98);
}
.bc-nick {
  font-family: var(--display);
  text-transform: uppercase;
  font-size: 1.02rem;
  line-height: 1.1;
  overflow-wrap: anywhere;
}
.bc-meta {
  display: flex;
  justify-content: space-between;
  gap: 6px;
  font-size: 0.84rem;
  font-weight: 600;
  color: var(--muted);
}
.bc-aura {
  color: var(--lime);
  white-space: nowrap;
}
.btn-timeout {
  width: 100%;
}

.feed-block,
.metrics-block {
  border-top: 1px solid var(--line);
  padding-top: 16px;
}
.feed {
  list-style: none;
  margin: 0;
  padding: 0;
}
.dispatch {
  display: grid;
  grid-template-columns: 2rem minmax(0, 1fr);
  gap: 10px;
  padding: 10px 0;
}
.dispatch + .dispatch {
  border-top: 1px solid var(--line);
}
.dispatch-emoji {
  font-size: 1.5rem;
  line-height: 1.2;
}
.dispatch-text strong {
  white-space: nowrap;
}
.dispatch-text .plus {
  color: var(--lime);
}
.dispatch-text .minus {
  color: var(--muted);
}
.dispatch-text small {
  display: block;
  color: var(--muted);
  font-weight: 600;
  margin-top: 2px;
}

.metrics-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px 14px;
}
.metrics-player {
  display: flex;
  flex-direction: column;
  gap: 7px;
  min-width: 0;
}
.mp-head {
  display: flex;
  flex-direction: column;
  border-left: 3px solid var(--team-a);
  padding-left: 8px;
}
.metrics-player.team-b .mp-head {
  border-left-color: var(--team-b);
}
.mp-nick {
  font-family: var(--display);
  text-transform: uppercase;
  line-height: 1.1;
  overflow-wrap: anywhere;
}
.mp-aura {
  color: var(--lime);
  font-weight: 700;
  font-size: 0.86rem;
}
.metric {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 3px 8px;
  align-items: center;
}
.metric-label {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--muted);
  line-height: 1.15;
}
.metric-n {
  font-family: var(--display);
  font-size: 0.95rem;
  grid-row: 1;
  grid-column: 2;
}
.metric-bar {
  grid-column: 1 / -1;
  height: 7px;
  border-bottom: 1px solid var(--line);
  position: relative;
}
.metric-bar span {
  position: absolute;
  inset: 0 auto 0 0;
  background: var(--lime);
  border-radius: 999px;
  transition: width 0.5s var(--ease);
}
@media (max-width: 359px) {
  .metrics-grid {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* ---------- sheets, toast, timeout ---------- */
.scrim {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
  z-index: 30;
}
.sheet {
  position: fixed;
  left: 50%;
  bottom: 0;
  transform: translateX(-50%);
  width: min(520px, 100%);
  max-height: 88dvh;
  overflow: auto;
  z-index: 31;
  background: var(--s1);
  border: 1px solid var(--line);
  border-bottom: 0;
  border-radius: 18px 18px 0 0;
  padding: 18px 16px calc(18px + env(safe-area-inset-bottom));
  display: flex;
  flex-direction: column;
  gap: 10px;
}
@media (prefers-reduced-motion: no-preference) {
  .sheet {
    animation: sheet-in 0.28s var(--ease);
  }
  @keyframes sheet-in {
    from {
      transform: translate(-50%, 24px);
      opacity: 0;
    }
  }
}
.bro-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.bro-btn {
  display: grid;
  grid-template-columns: 2.2rem minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
  min-height: 54px;
  padding: 8px 14px;
  border-radius: var(--r);
  border: 1px solid var(--line);
  background: var(--s2);
  text-align: left;
  cursor: pointer;
  font-weight: 700;
}
.bro-btn:active {
  transform: scale(0.98);
  background: var(--s3);
}
.bro-emoji {
  font-size: 1.5rem;
}
.bro-hint {
  font-family: var(--display);
  color: var(--lime);
}

.toast {
  position: fixed;
  left: 50%;
  bottom: calc(14px + env(safe-area-inset-bottom));
  transform: translateX(-50%);
  width: min(488px, calc(100% - 24px));
  z-index: 35;
  background: var(--text);
  color: var(--ink);
  border-radius: var(--r);
  padding: 10px 10px 14px 14px;
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
  overflow: hidden;
}
.toast > span:first-child {
  flex: 1;
  min-width: 0;
}
.toast-undo {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 44px;
  padding: 0 14px;
  border-radius: var(--r);
  border: 0;
  background: var(--ink);
  color: var(--lime);
  font-weight: 700;
  cursor: pointer;
  flex: none;
}
.toast-bar {
  position: absolute;
  left: 0;
  bottom: 0;
  height: 4px;
  width: 100%;
  background: var(--lime);
  transform-origin: left;
  animation: drain linear forwards;
}
@keyframes drain {
  to {
    transform: scaleX(0);
  }
}

.timeout-overlay {
  position: fixed;
  inset: 0;
  z-index: 40;
  background: var(--bg);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 14px;
  padding: 24px;
  text-align: center;
}
.timeout-overlay h2 {
  font-size: clamp(2rem, 10vw, 2.6rem);
  color: var(--lime);
}
.to-line {
  font-size: 1.2rem;
  font-weight: 700;
  max-width: 28ch;
}
.to-count {
  font-family: var(--display);
  font-size: 5.5rem;
  line-height: 1;
}
.to-count small {
  font-size: 2rem;
  color: var(--muted);
}
@media (prefers-reduced-motion: no-preference) {
  .timeout-overlay .mascot {
    animation: wobble 1.6s ease-in-out infinite;
  }
  @keyframes wobble {
    50% {
      transform: rotate(-6deg);
    }
  }
}

/* ---------- end ---------- */
.emperor {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 6px;
}
.crown-wrap {
  position: relative;
  width: 190px;
  height: 150px;
  display: grid;
  place-items: center;
}
.emp-laurel {
  position: absolute;
  inset: 0;
  width: 100%;
  color: var(--gold);
}
.emp-crown {
  position: relative;
  width: 70px;
  height: 70px;
  color: var(--gold);
  margin-top: -12px;
}
.eyebrow {
  color: var(--lime);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  font-size: 0.85rem;
}
.emperor-nick {
  color: var(--gold);
  font-size: clamp(2.4rem, 12vw, 3.4rem);
  line-height: 1.05;
  overflow-wrap: anywhere;
}
.result-line {
  font-family: var(--display);
  text-transform: uppercase;
  text-align: center;
  font-size: 1.3rem;
  line-height: 1.15;
}
.rankings {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.rank {
  display: grid;
  grid-template-columns: 2rem minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border-radius: var(--r);
  background: var(--s1);
  border: 1px solid var(--line);
}
.rank-emperor {
  border-color: var(--gold);
}
.rank-n {
  font-family: var(--display);
  font-size: 1.5rem;
  color: var(--muted);
}
.rank-emperor .rank-n {
  color: var(--gold);
}
.rank-who {
  display: flex;
  flex-direction: column;
  min-width: 0;
}
.rank-title {
  color: var(--lime);
  font-weight: 700;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}
.rank-emperor .rank-title {
  color: var(--gold);
}
.rank-nick {
  font-family: var(--display);
  text-transform: uppercase;
  font-size: 1.12rem;
  line-height: 1.1;
  overflow-wrap: anywhere;
}
.rank-name {
  color: var(--muted);
  font-size: 0.85rem;
  font-weight: 600;
}
.rank-aura {
  font-family: var(--display);
  color: var(--text);
  white-space: nowrap;
}
.supers {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}
.supers li {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 12px;
  border-radius: var(--r);
  background: var(--s2);
  font-weight: 600;
}
.sup-title {
  color: var(--lime);
  font-weight: 700;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}
@media (max-width: 380px) {
  .supers {
    grid-template-columns: minmax(0, 1fr);
  }
}
.share-block {
  border-top: 1px solid var(--line);
  padding-top: 16px;
}
.card-preview {
  width: 100%;
  border-radius: var(--r);
  display: block;
  border: 1px solid var(--line);
}
.card-preview.skeleton {
  aspect-ratio: 4 / 5;
  background: linear-gradient(100deg, var(--s1) 30%, var(--s2) 50%, var(--s1) 70%);
  background-size: 300% 100%;
}
@media (prefers-reduced-motion: no-preference) {
  .card-preview.skeleton {
    animation: shimmer 1.4s linear infinite;
  }
  @keyframes shimmer {
    to {
      background-position: -150% 0;
    }
  }
}
.card-actions {
  display: grid;
  gap: 8px;
}
.end-actions {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }
  .toast-bar {
    animation-duration: inherit !important;
  }
}
