:root {
  color-scheme: dark;
  font-family: "Noto Serif SC", "Songti SC", "STSong", serif;
  font-synthesis: none;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
  --ink-950: #12100d;
  --ink-900: #191611;
  --ink-850: #201c16;
  --ink-800: #28231b;
  --paper-50: #f5efe1;
  --paper-100: #e9dfcc;
  --paper-300: #cabc9f;
  --paper-500: #9c907a;
  --line: rgba(225, 210, 181, 0.16);
  --line-strong: rgba(225, 210, 181, 0.28);
  --gold: #c9a45e;
  --gold-light: #efd38e;
  --cinnabar: #a94334;
  --cinnabar-bright: #d25b45;
  --frost: #75a7b8;
  --jade: #629277;
  --danger: #d66b5e;
  --safe-top: env(safe-area-inset-top, 0px);
  --safe-right: env(safe-area-inset-right, 0px);
  --safe-bottom: env(safe-area-inset-bottom, 0px);
  --safe-left: env(safe-area-inset-left, 0px);
}

* {
  box-sizing: border-box;
}

html,
body,
#root {
  width: 100%;
  min-width: 320px;
  min-height: 100%;
  margin: 0;
}

html {
  background: #0b0a08;
  overscroll-behavior: none;
}

body {
  min-height: 100dvh;
  overflow: hidden;
  color: var(--paper-50);
  background:
    radial-gradient(circle at 50% -20%, rgba(117, 167, 184, 0.13), transparent 45%),
    var(--ink-950);
}

button,
input {
  color: inherit;
  font: inherit;
}

button {
  -webkit-tap-highlight-color: transparent;
}

button:focus-visible,
input:focus-visible {
  outline: 2px solid var(--gold-light);
  outline-offset: 3px;
}

button:disabled {
  cursor: not-allowed;
}

.app-shell {
  position: relative;
  width: 100%;
  height: 100dvh;
  overflow: hidden;
  background:
    linear-gradient(rgba(255, 255, 255, 0.012), rgba(255, 255, 255, 0)),
    repeating-linear-gradient(98deg, transparent 0 22px, rgba(255, 255, 255, 0.008) 22px 23px),
    var(--ink-900);
}

/* Full native Noname battle realm */
.native-battle-screen,
.native-battle-mount {
  position: relative;
  width: 100%;
  height: 100%;
  overflow: hidden;
  background: #12100d;
}

.native-battle-frame {
  position: fixed;
  z-index: 1;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
  background: #12100d;
  opacity: 1;
  transition: opacity 180ms ease;
}

.native-battle-frame-hidden {
  position: fixed;
  width: 1px;
  height: 1px;
  inset: 0 auto auto 0;
  opacity: 0;
  pointer-events: none;
  clip-path: inset(50%);
}

.native-battle-chrome {
  position: absolute;
  z-index: 8;
  top: 0;
  right: 0;
  left: 0;
  min-height: calc(52px + var(--safe-top));
  display: grid;
  grid-template-columns: 44px 1fr auto;
  align-items: end;
  gap: 10px;
  padding: var(--safe-top) max(12px, var(--safe-right)) 7px max(12px, var(--safe-left));
  pointer-events: none;
  background: linear-gradient(180deg, rgba(13, 11, 8, 0.98), rgba(20, 17, 13, 0.86) 78%, transparent);
}

.native-battle-chrome > * {
  pointer-events: auto;
}

.native-battle-chrome > div {
  min-width: 0;
  display: grid;
  gap: 2px;
}

.native-battle-chrome small {
  color: var(--paper-500);
  font: 700 0.58rem/1 system-ui, sans-serif;
  letter-spacing: 0.12em;
}

.native-battle-chrome strong {
  overflow: hidden;
  text-overflow: ellipsis;
  font: 800 0.82rem/1.25 system-ui, sans-serif;
  white-space: nowrap;
}

.native-exit {
  width: 40px;
  height: 40px;
  border: 1px solid rgba(233, 218, 188, 0.2);
  border-radius: 50%;
  color: var(--paper-50);
  background: rgba(0, 0, 0, 0.34);
  font: 400 1.8rem/1 system-ui, sans-serif;
  touch-action: manipulation;
}

.native-live-dot {
  min-height: 28px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 0 9px;
  color: var(--paper-300);
  background: rgba(0, 0, 0, 0.28);
  font: 700 0.64rem/1 system-ui, sans-serif;
}

.native-live-dot::before {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--gold);
}

.native-live-dot[data-online="true"]::before {
  background: #75bd91;
  box-shadow: 0 0 9px rgba(117, 189, 145, 0.72);
}

.native-loading-gate {
  position: absolute;
  z-index: 7;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: calc(var(--safe-top) + 70px) 28px calc(var(--safe-bottom) + 26px);
  text-align: center;
  background:
    radial-gradient(circle at 50% 36%, rgba(91, 145, 164, 0.2), transparent 34%),
    rgba(18, 16, 13, 0.97);
}

.native-loading-seal {
  width: 64px;
  height: 64px;
  display: grid;
  place-items: center;
  margin-bottom: 18px;
  border: 1px solid rgba(255, 235, 202, 0.42);
  border-radius: 15px 5px 15px 5px;
  color: #fff1d7;
  background: var(--cinnabar);
  box-shadow: inset 0 0 0 3px rgba(79, 18, 13, 0.25), 0 15px 40px rgba(0, 0, 0, 0.35);
  font-size: 2rem;
  font-weight: 900;
  animation: native-seal-pulse 1.8s ease-in-out infinite;
}

.native-loading-gate > small {
  color: var(--gold);
  letter-spacing: 0.22em;
  font: 800 0.62rem/1 system-ui, sans-serif;
}

.native-loading-gate h1 {
  margin: 12px 0 8px;
  font-size: 1.45rem;
}

.native-loading-gate p {
  min-height: 42px;
  max-width: 340px;
  margin: 0;
  color: var(--paper-300);
  font-size: 0.82rem;
  line-height: 1.65;
}

.native-sync-progress {
  position: relative;
  width: min(280px, 80vw);
  height: 30px;
  margin-top: 18px;
  overflow: hidden;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.28);
}

.native-sync-progress i {
  position: absolute;
  inset: 0 auto 0 0;
  border-radius: inherit;
  background: linear-gradient(90deg, rgba(169, 67, 52, 0.7), rgba(201, 164, 94, 0.72));
  transition: width 220ms ease;
}

.native-sync-progress span {
  position: relative;
  z-index: 1;
  display: grid;
  height: 100%;
  place-items: center;
  font: 700 0.68rem/1 system-ui, sans-serif;
}

.native-error {
  max-width: 340px;
  margin-top: 10px;
  color: #ef9b8e;
  font: 600 0.72rem/1.5 system-ui, sans-serif;
}

.native-cancel {
  min-height: 44px;
  margin-top: 22px;
  padding-inline: 24px;
}

.native-exit-backdrop {
  position: absolute;
  z-index: 40;
  inset: 0;
  display: grid;
  place-items: center;
  padding: calc(var(--safe-top) + 24px) max(20px, var(--safe-right)) calc(var(--safe-bottom) + 24px) max(20px, var(--safe-left));
  background: rgba(8, 7, 5, 0.72);
  backdrop-filter: blur(9px);
}

.native-exit-dialog {
  width: min(360px, 100%);
  border: 1px solid var(--line-strong);
  border-radius: 20px 7px 20px 7px;
  padding: 24px 20px 20px;
  color: var(--paper-50);
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.045), transparent 42%),
    #211d17;
  box-shadow: 0 28px 80px rgba(0, 0, 0, 0.58);
}

.native-exit-dialog > small {
  color: var(--gold);
  font: 800 0.62rem/1 system-ui, sans-serif;
  letter-spacing: 0.18em;
}

.native-exit-dialog h2 {
  margin: 10px 0 8px;
  font-size: 1.32rem;
}

.native-exit-dialog p {
  margin: 0;
  color: var(--paper-300);
  font-size: 0.8rem;
  line-height: 1.65;
}

.native-exit-dialog > div {
  display: grid;
  grid-template-columns: 1fr 1.15fr;
  gap: 9px;
  margin-top: 20px;
}

.native-exit-dialog > .native-opponent-left-actions {
  grid-template-columns: 1fr;
}

.native-opponent-left .button-primary {
  min-height: 50px;
}

.button-danger {
  color: #fff8e9;
  border-color: rgba(255, 192, 164, 0.32);
  background: linear-gradient(180deg, #b84a39, #7d2923);
  box-shadow: 0 8px 22px rgba(91, 24, 19, 0.32);
}

.button-danger:disabled {
  opacity: 0.48;
}

@keyframes native-seal-pulse {
  50% { transform: translateY(-3px); box-shadow: inset 0 0 0 3px rgba(79, 18, 13, 0.25), 0 18px 46px rgba(169, 67, 52, 0.22); }
}

.screen-scroll {
  height: 100%;
  overflow: auto;
  overscroll-behavior-y: contain;
  scrollbar-width: none;
}

.screen-scroll::-webkit-scrollbar,
.room-scroll::-webkit-scrollbar {
  display: none;
}

.button {
  min-height: 50px;
  border: 1px solid transparent;
  border-radius: 12px;
  padding: 0 18px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  font-weight: 800;
  letter-spacing: 0.04em;
  transition: transform 140ms ease, filter 140ms ease, background-color 140ms ease;
  touch-action: manipulation;
}

.button:not(:disabled):active {
  transform: translateY(1px) scale(0.985);
}

.button-primary {
  color: #fff8e9;
  border-color: rgba(255, 213, 151, 0.32);
  background:
    linear-gradient(115deg, rgba(255, 255, 255, 0.08), transparent 42%),
    linear-gradient(180deg, #bd503d, #8f3228);
  box-shadow: 0 8px 24px rgba(94, 24, 19, 0.34), inset 0 1px rgba(255, 255, 255, 0.12);
}

.button-primary:disabled {
  color: rgba(245, 239, 225, 0.4);
  border-color: var(--line);
  background: #373027;
  box-shadow: none;
}

.button-quiet {
  color: var(--paper-100);
  border-color: var(--line-strong);
  background: rgba(255, 255, 255, 0.045);
}

.button-quiet:disabled {
  opacity: 0.38;
}

.button-ai {
  margin-top: 9px;
  color: #e7f5f8;
  border-color: rgba(117, 167, 184, 0.38);
  background:
    linear-gradient(115deg, rgba(255, 255, 255, 0.07), transparent 44%),
    linear-gradient(180deg, rgba(71, 116, 133, 0.92), rgba(43, 76, 89, 0.96));
  box-shadow: 0 8px 24px rgba(25, 63, 76, 0.28), inset 0 1px rgba(255, 255, 255, 0.1);
}

.button-ai > span:first-child {
  display: grid;
  gap: 4px;
  text-align: left;
}

.button-ai strong {
  font-size: 0.9rem;
}

.button-ai small {
  color: rgba(222, 242, 247, 0.68);
  font: 600 0.62rem/1 system-ui, sans-serif;
  letter-spacing: 0.02em;
}

.button-ai:disabled {
  opacity: 0.4;
  box-shadow: none;
}

.button-large {
  width: 100%;
  min-height: 58px;
  justify-content: space-between;
  padding-inline: 22px;
}

.button-arrow {
  font-size: 1.35rem;
  font-weight: 400;
}

.icon-button {
  width: 46px;
  height: 46px;
  flex: 0 0 46px;
  border: 1px solid var(--line);
  border-radius: 50%;
  color: var(--paper-100);
  background: rgba(255, 255, 255, 0.035);
  font: 700 1.65rem/1 system-ui, sans-serif;
}

.icon-button.dark {
  border-color: rgba(255, 255, 255, 0.13);
  background: rgba(0, 0, 0, 0.25);
}

.connection-pill {
  min-height: 30px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 5px 9px;
  color: var(--paper-300);
  background: rgba(0, 0, 0, 0.18);
  font: 600 0.68rem/1 system-ui, sans-serif;
  white-space: nowrap;
}

.connection-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--paper-500);
  box-shadow: 0 0 0 3px rgba(156, 144, 122, 0.08);
}

.connection-pill[data-status="online"] .connection-dot {
  background: #7fc49a;
  box-shadow: 0 0 0 3px rgba(127, 196, 154, 0.12), 0 0 9px rgba(127, 196, 154, 0.5);
}

.connection-pill[data-status="connecting"] .connection-dot,
.connection-pill[data-status="reconnecting"] .connection-dot {
  background: var(--gold);
  animation: pulse 1.2s ease-in-out infinite;
}

.latency {
  color: rgba(202, 188, 159, 0.58);
  font-variant-numeric: tabular-nums;
}

.toast {
  position: fixed;
  z-index: 100;
  left: 50%;
  bottom: calc(var(--safe-bottom) + 174px);
  width: max-content;
  max-width: calc(100% - 32px);
  min-height: 46px;
  transform: translateX(-50%);
  display: flex;
  align-items: center;
  gap: 9px;
  border: 1px solid rgba(239, 211, 142, 0.32);
  border-radius: 999px;
  padding: 10px 16px;
  color: var(--paper-50);
  background: rgba(25, 22, 17, 0.94);
  box-shadow: 0 14px 38px rgba(0, 0, 0, 0.48);
  backdrop-filter: blur(14px);
  animation: toast-in 220ms ease-out both;
}

/* Lobby */
.lobby-screen {
  padding: calc(var(--safe-top) + 18px) max(18px, var(--safe-right)) calc(var(--safe-bottom) + 28px) max(18px, var(--safe-left));
}

.lobby-topbar,
.room-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.brand-lockup {
  display: flex;
  align-items: center;
  gap: 10px;
}

.brand-lockup > span:last-child {
  display: grid;
  gap: 1px;
}

.brand-lockup strong {
  letter-spacing: 0.16em;
  font: 800 0.92rem/1 system-ui, sans-serif;
}

.brand-lockup small {
  color: var(--paper-500);
  letter-spacing: 0.38em;
  font: 700 0.52rem/1 system-ui, sans-serif;
}

.brand-seal {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(255, 235, 205, 0.34);
  border-radius: 7px;
  color: #fff2db;
  background: var(--cinnabar);
  box-shadow: inset 0 0 0 2px rgba(85, 22, 17, 0.22);
  font-size: 1rem;
  font-weight: 900;
}

.hero-panel {
  position: relative;
  min-height: 244px;
  margin-top: 28px;
  overflow: hidden;
  border: 1px solid var(--line-strong);
  border-radius: 24px 8px 24px 8px;
  padding: 30px 24px 24px;
  background:
    radial-gradient(circle at 84% 28%, rgba(137, 185, 201, 0.16), transparent 30%),
    linear-gradient(140deg, rgba(255, 255, 255, 0.055), transparent 42%),
    #211e18;
  box-shadow: 0 22px 60px rgba(0, 0, 0, 0.25), inset 0 0 0 1px rgba(0, 0, 0, 0.22);
}

.hero-panel::before {
  content: "";
  position: absolute;
  inset: 10px;
  border: 1px solid rgba(201, 164, 94, 0.13);
  border-radius: 17px 3px 17px 3px;
  pointer-events: none;
}

.hero-kicker,
.eyebrow {
  color: var(--gold);
  font: 700 0.68rem/1.2 system-ui, sans-serif;
  letter-spacing: 0.16em;
}

.hero-panel h1 {
  position: relative;
  z-index: 1;
  margin: 12px 0 9px;
  max-width: calc(100% - 42px);
  color: var(--paper-50);
  font-size: clamp(2rem, 9.6vw, 2.7rem);
  line-height: 1.05;
  letter-spacing: 0.03em;
  white-space: nowrap;
}

.hero-panel p {
  position: relative;
  z-index: 1;
  max-width: 78%;
  margin: 0;
  color: var(--paper-300);
  font-size: 0.82rem;
  line-height: 1.75;
}

.mode-facts {
  position: absolute;
  z-index: 1;
  right: 18px;
  bottom: 18px;
  left: 24px;
  display: flex;
  gap: 6px;
}

.mode-facts span {
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 5px 8px;
  color: var(--paper-300);
  background: rgba(0, 0, 0, 0.14);
  font: 600 0.62rem/1 system-ui, sans-serif;
}

.snow-orbit {
  position: absolute;
  top: 22px;
  right: 15px;
  width: 104px;
  height: 104px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(117, 167, 184, 0.2);
  border-radius: 50%;
}

.snow-orbit::before,
.snow-orbit::after {
  content: "";
  position: absolute;
  inset: 14px;
  border: 1px dashed rgba(117, 167, 184, 0.18);
  border-radius: 50%;
  transform: rotate(28deg);
}

.snow-orbit::after {
  inset: 31px;
  border-style: solid;
}

.snow-orbit span {
  color: rgba(164, 209, 223, 0.56);
  font-size: 2rem;
  animation: snow-turn 14s linear infinite;
}

.lobby-card {
  margin-top: 18px;
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 20px;
  background: rgba(255, 255, 255, 0.027);
}

.section-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 20px;
}

.section-heading.compact {
  margin-bottom: 14px;
}

.section-heading h2 {
  margin: 5px 0 0;
  font-size: 1.18rem;
  line-height: 1.2;
}

.step-mark {
  color: rgba(202, 188, 159, 0.28);
  font: 300 2rem/1 system-ui, sans-serif;
}

.field-label {
  display: block;
  margin: 0 0 7px 2px;
  color: var(--paper-500);
  font: 600 0.7rem/1 system-ui, sans-serif;
}

.text-field,
.room-code-field {
  width: 100%;
  min-height: 52px;
  border: 1px solid var(--line-strong);
  border-radius: 11px;
  padding: 0 14px;
  color: var(--paper-50);
  background: rgba(0, 0, 0, 0.2);
  box-shadow: inset 0 1px 5px rgba(0, 0, 0, 0.18);
  appearance: none;
}

.text-field {
  margin-bottom: 12px;
}

.or-divider {
  height: 36px;
  display: flex;
  align-items: center;
  gap: 12px;
  color: rgba(202, 188, 159, 0.52);
  font: 500 0.66rem/1 system-ui, sans-serif;
}

.or-divider::before,
.or-divider::after {
  content: "";
  height: 1px;
  flex: 1;
  background: var(--line);
}

.join-row {
  display: grid;
  grid-template-columns: 1fr 94px;
  gap: 9px;
}

.room-code-field {
  text-transform: uppercase;
  letter-spacing: 0.22em;
  font: 800 1rem/1 system-ui, sans-serif;
}

/* Room */
.room-screen {
  height: 100%;
  overflow: hidden;
}

.room-screen {
  display: grid;
  grid-template-rows: auto 1fr auto;
}

.room-topbar {
  z-index: 2;
  min-height: calc(var(--safe-top) + 70px);
  padding: calc(var(--safe-top) + 12px) max(14px, var(--safe-right)) 10px max(14px, var(--safe-left));
  border-bottom: 1px solid var(--line);
  background: rgba(25, 22, 17, 0.9);
  backdrop-filter: blur(16px);
}

.room-title {
  flex: 1;
  display: grid;
  gap: 2px;
}

.room-title > span {
  font-weight: 800;
}

.room-title small {
  color: var(--paper-500);
  font: 600 0.64rem/1 system-ui, sans-serif;
}

.room-scroll {
  min-height: 0;
  overflow: auto;
  padding: 18px max(16px, var(--safe-right)) 26px max(16px, var(--safe-left));
  overscroll-behavior-y: contain;
}

.room-code-card {
  width: 100%;
  min-height: 104px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border: 1px solid rgba(201, 164, 94, 0.3);
  border-radius: 15px;
  padding: 18px 20px;
  text-align: left;
  background:
    linear-gradient(110deg, rgba(201, 164, 94, 0.08), transparent 58%),
    rgba(255, 255, 255, 0.028);
}

.ai-room-card {
  min-height: 118px;
  display: grid;
  grid-template-columns: 58px 1fr;
  align-items: center;
  gap: 15px;
  border: 1px solid rgba(117, 167, 184, 0.3);
  border-radius: 15px;
  padding: 18px 20px;
  background:
    radial-gradient(circle at 10% 50%, rgba(117, 167, 184, 0.14), transparent 34%),
    rgba(255, 255, 255, 0.028);
}

.ai-room-mark {
  width: 54px;
  height: 54px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(194, 229, 238, 0.3);
  border-radius: 50%;
  color: #d8eff5;
  background: rgba(117, 167, 184, 0.13);
  font-size: 1.35rem;
  font-weight: 900;
}

.ai-room-card > span:last-child {
  display: grid;
  gap: 5px;
}

.ai-room-card small {
  color: var(--paper-500);
  font: 600 0.64rem/1 system-ui, sans-serif;
}

.ai-room-card strong {
  color: #d9edf2;
  font-size: 1rem;
}

.ai-room-card p {
  margin: 0;
  color: var(--paper-300);
  font: 500 0.66rem/1.5 system-ui, sans-serif;
}

.room-code-card > span:first-child {
  display: grid;
  gap: 8px;
}

.room-code-card small {
  color: var(--paper-500);
  font: 600 0.67rem/1 system-ui, sans-serif;
}

.room-code-card strong {
  color: var(--gold-light);
  letter-spacing: 0.22em;
  font: 800 1.8rem/1 system-ui, sans-serif;
}

.copy-glyph {
  color: var(--gold);
  font: 400 1.5rem/1 system-ui, sans-serif;
}

.players-panel {
  margin-top: 20px;
}

.live-mark {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--paper-500);
  font: 600 0.62rem/1 system-ui, sans-serif;
}

.live-mark i {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #76b98e;
  box-shadow: 0 0 8px rgba(118, 185, 142, 0.55);
}

.player-list {
  display: grid;
  gap: 8px;
}

.room-player {
  min-height: 68px;
  display: grid;
  grid-template-columns: 25px 42px 1fr auto;
  align-items: center;
  gap: 10px;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 8px 12px;
  background: rgba(255, 255, 255, 0.025);
}

.room-player[data-connected="false"] {
  opacity: 0.55;
}

.room-player-ai {
  border-color: rgba(117, 167, 184, 0.24);
  background: rgba(117, 167, 184, 0.05);
}

.player-index {
  color: rgba(202, 188, 159, 0.4);
  font: 600 0.65rem/1 system-ui, sans-serif;
}

.player-avatar {
  width: 40px;
  height: 40px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(117, 167, 184, 0.25);
  border-radius: 50%;
  color: #d6edf3;
  background: rgba(117, 167, 184, 0.12);
  font-weight: 900;
}

.player-name {
  min-width: 0;
  display: grid;
  gap: 4px;
}

.player-name strong {
  overflow: hidden;
  font-size: 0.84rem;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.player-name small {
  color: var(--paper-500);
  font: 500 0.62rem/1 system-ui, sans-serif;
}

.ready-state {
  border-radius: 999px;
  padding: 6px 8px;
  color: var(--paper-500);
  background: rgba(255, 255, 255, 0.035);
  font: 700 0.62rem/1 system-ui, sans-serif;
}

.ready-state[data-ready="true"] {
  color: #a9daba;
  background: rgba(98, 146, 119, 0.14);
}

.empty-seat {
  min-height: 58px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  border: 1px dashed var(--line-strong);
  border-radius: 12px;
  color: rgba(202, 188, 159, 0.48);
  font: 600 0.68rem/1 system-ui, sans-serif;
}

.empty-seat > span:first-child {
  font-size: 1.2rem;
  font-weight: 300;
}

.room-tip {
  margin-top: 18px;
  display: grid;
  grid-template-columns: 28px 1fr;
  gap: 8px;
  border-left: 2px solid rgba(117, 167, 184, 0.5);
  padding: 10px 12px;
  color: var(--paper-300);
  background: rgba(117, 167, 184, 0.055);
}

.room-tip p {
  margin: 0;
  font: 500 0.7rem/1.6 system-ui, sans-serif;
}

.room-tip strong {
  color: #c5e0e8;
}

.bottom-actions {
  z-index: 20;
  border-top: 1px solid var(--line-strong);
  padding: 12px max(16px, var(--safe-right)) calc(12px + var(--safe-bottom)) max(16px, var(--safe-left));
  background: rgba(25, 22, 17, 0.95);
  box-shadow: 0 -18px 45px rgba(0, 0, 0, 0.34);
  backdrop-filter: blur(18px);
}

.ready-summary {
  display: flex;
  justify-content: space-between;
  margin-bottom: 9px;
  color: var(--paper-500);
  font: 600 0.66rem/1 system-ui, sans-serif;
}

.action-row {
  display: grid;
  grid-template-columns: 1fr 1.25fr;
  gap: 9px;
}

.waiting-host {
  min-height: 50px;
  display: grid;
  place-items: center;
  color: var(--paper-500);
  font: 600 0.7rem/1 system-ui, sans-serif;
}

@keyframes pulse {
  0%, 100% { opacity: 0.45; }
  50% { opacity: 1; }
}

@keyframes snow-turn {
  to { transform: rotate(360deg); }
}

@keyframes toast-in {
  from { opacity: 0; transform: translate(-50%, 10px) scale(0.97); }
  to { opacity: 1; transform: translate(-50%, 0) scale(1); }
}

@media (min-width: 700px) {
  .app-shell {
    width: min(100%, 480px);
    margin-inline: auto;
    border-inline: 1px solid rgba(225, 210, 181, 0.1);
    box-shadow: 0 0 80px rgba(0, 0, 0, 0.55);
  }
}

@media (orientation: landscape) and (max-height: 600px) {
  .app-shell { width: min(100%, 920px); }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
