:root {
  color-scheme: dark;
  --bg: #06101a;
  --bg-soft: #0d1724;
  --panel: rgba(11, 20, 33, 0.84);
  --panel-strong: rgba(12, 21, 35, 0.96);
  --line: rgba(185, 206, 228, 0.14);
  --line-strong: rgba(185, 206, 228, 0.24);
  --text: #f3f2ea;
  --muted: #9aaec5;
  --accent: #d8b36a;
  --accent-soft: rgba(216, 179, 106, 0.18);
  --accent-blue: #5da7ff;
  --accent-green: #7ce2a5;
  --accent-red: #ff8e80;
  --piece-white-color: #f7f4eb;
  --piece-black-color: #0e1826;
  --piece-white-shadow:
    0 4px 10px rgba(0, 0, 0, 0.3),
    0 0 22px var(--board-glow);
  --piece-black-shadow:
    0 3px 10px rgba(6, 12, 20, 0.48),
    0 1px 0 rgba(255, 255, 255, 0.14);
  --square-light: #eadfc7;
  --square-dark: #7f6142;
  --square-hover: rgba(255, 255, 255, 0.08);
  --square-selected: rgba(216, 179, 106, 0.92);
  --square-last-move: rgba(87, 180, 255, 0.72);
  --board-glow: rgba(73, 149, 239, 0.3);
  --move: rgba(124, 226, 165, 0.98);
  --danger: rgba(255, 142, 128, 0.96);
  --shadow: 0 24px 70px rgba(0, 0, 0, 0.34);
  --shadow-soft: 0 18px 40px rgba(0, 0, 0, 0.24);
  --radius: 26px;
  --viewport-height: 100vh;
  --play-shell-padding-x: 12px;
  --play-shell-padding-y: 20px;
  --play-fullscreen-gap: 14px;
  --play-fullscreen-left-rail: 280px;
  --play-fullscreen-center-rail: minmax(0, 1fr);
  --play-fullscreen-right-rail: 360px;
  --play-nav-left-offset: 0px;
  --play-nav-right-offset: 0px;
  --runtime-board-size: min(72vw, 72vh);
  --font-display: "Avenir Next", "Trebuchet MS", sans-serif;
  --font-body: "Segoe UI", "Helvetica Neue", sans-serif;
  --font-mono: "JetBrains Mono", "Fira Code", monospace;
}

@supports (height: 100dvh) {
  :root {
    --viewport-height: 100dvh;
  }
}

* {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

html,
body {
  margin: 0;
  height: 100%;
  min-height: 100%;
  overflow-x: hidden;
}

body {
  font-family: var(--font-body);
  color: var(--text);
  background:
    radial-gradient(circle at top left, rgba(216, 179, 106, 0.18), transparent 22rem),
    radial-gradient(circle at bottom right, rgba(70, 144, 233, 0.24), transparent 24rem),
    linear-gradient(165deg, #040a11 0%, #09111b 52%, #101a2a 100%);
}

html.is-play-app,
body.is-play-app,
body.is-play-fullscreen,
body.activity-theater-mode {
  overflow: hidden;
}

html.discord-activity-mode,
body.discord-activity-mode {
  width: 100%;
  min-width: 0;
  overflow-x: hidden;
}

body.discord-activity-mode {
  background: #050811;
}

body.discord-activity-mode::before {
  display: none;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.024) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.024) 1px, transparent 1px);
  background-size: 34px 34px;
  mask-image: linear-gradient(to bottom, rgba(0, 0, 0, 0.55), transparent 92%);
}

a {
  color: inherit;
  text-decoration: none;
}

.play-shell {
  width: min(1820px, calc(100% - 24px));
  margin: 0 auto;
  padding: 20px 0 40px;
}

.play-shell[data-layout-mode="fullscreen"],
.play-shell:fullscreen,
.play-shell.is-play-app,
.play-shell.is-play-fullscreen,
.play-shell.is-activity-theater {
  display: grid;
  grid-template-rows: minmax(0, 1fr);
  width: 100%;
  max-width: none;
  min-height: var(--viewport-height);
  height: var(--viewport-height);
  margin: 0;
  padding: var(--play-shell-padding-y) var(--play-shell-padding-x);
  overflow: hidden;
}

body.discord-activity-mode.activity-theater-mode .play-shell {
  --play-shell-padding-x: clamp(6px, 1.2vw, 12px);
  --play-shell-padding-y: clamp(6px, 1.2vh, 12px);
  --play-fullscreen-gap: clamp(2px, 0.45vw, 6px);
  --play-fullscreen-left-rail: clamp(240px, 20vw, 340px);
  --play-fullscreen-right-rail: clamp(240px, 20vw, 340px);
  --runtime-board-size: clamp(320px, min(calc(100vw - (2 * var(--activity-side-panel-width)) - 96px), calc(var(--viewport-height) - 112px)), 680px);
}

body.activity-theater-mode .activity-theater-action {
  border-color: rgba(124, 226, 165, 0.48);
  color: var(--accent-green);
}

body.discord-activity-mode {
  --activity-side-panel-width: clamp(240px, 20vw, 340px);
  --play-shell-padding-x: clamp(6px, 1.1vw, 12px);
  --play-shell-padding-y: clamp(6px, 1.1vh, 10px);
  --play-fullscreen-gap: clamp(2px, 0.45vw, 6px);
  --play-fullscreen-left-rail: clamp(240px, 20vw, 340px);
  --play-fullscreen-right-rail: clamp(240px, 20vw, 340px);
  --runtime-board-size: clamp(300px, min(calc(100vw - (2 * var(--activity-side-panel-width)) - 96px), calc(var(--viewport-height) - 132px)), 640px);
}

body.discord-activity-mode .play-shell.is-discord-activity {
  position: relative;
  display: grid;
  grid-template-rows: minmax(0, 1fr);
  width: 100%;
  max-width: none;
  min-height: var(--viewport-height);
  height: var(--viewport-height);
  margin: 0;
  padding: var(--play-shell-padding-y) var(--play-shell-padding-x);
  overflow: hidden;
}

body.discord-activity-mode .play-shell.is-discord-activity .play-nav {
  --nav-button-height: 30px;
  --nav-button-padding-x: 8px;
  display: grid;
  grid-template-columns: minmax(128px, auto) minmax(0, 1fr) minmax(0, auto);
  align-items: center;
  gap: 6px;
  position: absolute;
  top: max(6px, env(safe-area-inset-top));
  left: calc(var(--play-shell-padding-x) + var(--play-nav-left-offset, 0px));
  right: calc(var(--play-shell-padding-x) + var(--play-nav-right-offset, 0px));
  z-index: 80;
  min-width: 0;
  max-width: 100%;
  margin: 0;
  padding: 6px 8px;
  border-radius: 14px;
  overflow: visible;
  opacity: 0.18;
  transform: translateY(calc(-100% + 16px));
  transition: opacity 160ms ease, transform 160ms ease;
}

body.discord-activity-mode .play-shell.is-discord-activity .play-nav::after {
  content: "";
  position: absolute;
  left: calc(var(--play-nav-left-offset, 0px) * -1);
  right: calc(var(--play-nav-right-offset, 0px) * -1);
  bottom: -16px;
  height: 16px;
}

body.discord-activity-mode .play-shell.is-discord-activity .play-nav:hover,
body.discord-activity-mode .play-shell.is-discord-activity .play-nav:focus-within {
  opacity: 1;
  transform: translateY(0);
}

body.discord-activity-mode .play-shell.is-discord-activity .play-brand {
  gap: 6px;
  min-width: 0;
}

body.discord-activity-mode .play-shell.is-discord-activity .logo-wanalike {
  width: 26px;
  height: 26px;
  border-radius: 7px;
}

body.discord-activity-mode .play-shell.is-discord-activity .play-brand strong {
  font-size: 0.88rem;
}

body.discord-activity-mode .play-shell.is-discord-activity .play-brand-copy > span {
  display: none;
}

body.discord-activity-mode .play-shell.is-discord-activity .play-nav-links,
body.discord-activity-mode .play-shell.is-discord-activity .play-nav-auth .auth-nav-links {
  display: flex;
  flex-wrap: nowrap;
  align-items: center;
  justify-content: flex-end;
  gap: 4px;
  min-width: 0;
}

body.discord-activity-mode .play-shell.is-discord-activity .play-nav-links a,
body.discord-activity-mode .play-shell.is-discord-activity .play-nav-auth .auth-nav-link,
body.discord-activity-mode .play-shell.is-discord-activity .play-nav-auth .auth-menu-summary,
body.discord-activity-mode .play-shell.is-discord-activity .play-nav-auth .auth-menu-button,
body.discord-activity-mode .play-shell.is-discord-activity .play-nav-auth .auth-menu-item {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  min-width: 0;
  max-width: 116px;
  min-height: 30px;
  height: 30px;
  padding: 0 8px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 0.72rem;
  line-height: 1;
}

body.discord-activity-mode .play-shell.is-discord-activity .play-nav-links a[aria-current="page"] {
  color: var(--text);
  background: rgba(93, 167, 255, 0.14);
  box-shadow: 0 0 0 1px rgba(93, 167, 255, 0.14), 0 0 18px rgba(105, 213, 255, 0.08);
}

body.discord-activity-mode .play-shell.is-discord-activity .play-nav-links a span,
body.discord-activity-mode .play-shell.is-discord-activity .play-nav-auth .auth-nav-link span,
body.discord-activity-mode .play-shell.is-discord-activity .play-nav-auth .auth-menu-item span,
body.discord-activity-mode .play-shell.is-discord-activity .play-nav-auth .auth-menu-button span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
}

body.discord-activity-mode .play-shell.is-discord-activity .play-nav-links .nav-link-icon,
body.discord-activity-mode .play-shell.is-discord-activity .play-nav-auth .auth-nav-icon {
  flex: 0 0 auto;
}

body.discord-activity-mode .play-shell.is-discord-activity .play-nav-links a.btn-download {
  max-width: 104px;
}

body.discord-activity-mode .play-shell.is-discord-activity .play-nav-auth {
  min-width: 0;
  max-width: min(34vw, 230px);
  margin-left: 0;
}

body.discord-activity-mode .play-shell.is-discord-activity .play-nav-auth .auth-menu-summary {
  gap: 6px;
}

body.discord-activity-mode .play-shell.is-discord-activity .play-nav-auth .auth-menu-avatar {
  width: 22px;
  height: 22px;
}

body.discord-activity-mode .play-shell.is-discord-activity .play-nav-auth .auth-menu-copy span {
  display: none;
}

@media (max-width: 620px) {
  body.discord-activity-mode .play-shell.is-discord-activity .play-nav {
    gap: 4px;
    padding: 5px 6px;
  }

  body.discord-activity-mode .play-shell.is-discord-activity .play-nav-links {
    gap: 4px;
  }

  body.discord-activity-mode .play-shell.is-discord-activity .play-nav-links a {
    flex: 1 1 0;
    min-width: 0;
    max-width: none;
    padding: 0 10px;
  }
}

@media (max-width: 520px) {
  body.discord-activity-mode .play-shell.is-discord-activity .play-nav-links {
    gap: 3px;
  }

  body.discord-activity-mode .play-shell.is-discord-activity .play-nav-links a {
    gap: 0;
    justify-content: center;
    padding: 0;
  }

  body.discord-activity-mode .play-shell.is-discord-activity .play-nav-links a span {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
    white-space: nowrap;
    border: 0;
  }

  body.discord-activity-mode .play-shell.is-discord-activity .play-nav-links .nav-link-icon {
    font-size: 1rem;
  }
}

@media (max-width: 760px) {
  body.discord-activity-mode .play-shell.is-discord-activity .play-nav {
    grid-template-columns: minmax(0, 1fr);
    align-items: stretch;
  }

  body.discord-activity-mode .play-shell.is-discord-activity .play-nav-links,
  body.discord-activity-mode .play-shell.is-discord-activity .play-nav-auth,
  body.discord-activity-mode .play-shell.is-discord-activity .play-nav-auth .auth-nav-links {
    width: 100%;
    max-width: none;
  }

  body.discord-activity-mode .play-shell.is-discord-activity .play-nav-links,
  body.discord-activity-mode .play-shell.is-discord-activity .play-nav-auth .auth-nav-links {
    justify-content: flex-start;
  }

  body.discord-activity-mode .play-shell.is-discord-activity .play-nav-links a,
  body.discord-activity-mode .play-shell.is-discord-activity .play-nav-auth .auth-nav-link {
    flex: 1 1 0;
    max-width: none;
    text-align: center;
  }
}

body.discord-activity-mode .play-shell.is-discord-activity .play-dashboard {
  min-height: 100%;
  height: 100%;
  margin-top: 0;
  overflow: hidden;
}

body.discord-activity-mode .play-shell.is-discord-activity .play-runtime {
  display: grid !important;
  grid-template-columns:
    minmax(0, var(--play-fullscreen-left-rail))
    minmax(0, 1fr)
    minmax(0, var(--play-fullscreen-right-rail)) !important;
  gap: var(--play-fullscreen-gap) !important;
  width: 100%;
  height: 100%;
  min-height: 0;
  max-width: none;
  margin: 0;
  padding: 0;
  overflow: hidden;
  align-items: stretch;
}

body.discord-activity-mode.discord-activity-mode .play-shell.is-discord-activity.is-discord-activity .play-runtime {
  grid-template-columns:
    minmax(var(--activity-side-panel-width), var(--activity-side-panel-width))
    minmax(0, 1fr)
    minmax(var(--activity-side-panel-width), var(--activity-side-panel-width)) !important;
  gap: var(--play-fullscreen-gap) !important;
}

body.discord-activity-mode .play-shell.is-discord-activity.is-left-panel-collapsed .play-runtime {
  grid-template-columns:
    0
    minmax(0, 1fr)
    minmax(var(--activity-side-panel-width), var(--activity-side-panel-width)) !important;
}

body.discord-activity-mode .play-shell.is-discord-activity.is-right-panel-collapsed .play-runtime {
  grid-template-columns:
    minmax(var(--activity-side-panel-width), var(--activity-side-panel-width))
    minmax(0, 1fr)
    0 !important;
}

body.discord-activity-mode .play-shell.is-discord-activity.is-left-panel-collapsed.is-right-panel-collapsed .play-runtime {
  grid-template-columns:
    0
    minmax(0, 1fr)
    0 !important;
}

body.discord-activity-mode .play-shell.is-discord-activity .play-left,
body.discord-activity-mode .play-shell.is-discord-activity .play-right {
  width: var(--activity-side-panel-width);
  max-width: var(--activity-side-panel-width);
  min-height: 0;
  max-height: 100%;
  overflow: auto;
  align-content: start;
  gap: 8px;
  padding-top: 2px;
}

body.discord-activity-mode .play-shell.is-discord-activity .play-right {
  overflow: hidden;
}

body.discord-activity-mode .play-shell.is-discord-activity.is-left-panel-collapsed .play-left,
body.discord-activity-mode .play-shell.is-discord-activity.is-right-panel-collapsed .play-right {
  width: 0;
  max-width: 0;
  min-width: 0;
  overflow: visible;
  pointer-events: none;
}

body.discord-activity-mode .play-shell.is-discord-activity.is-left-panel-collapsed .play-left > .control-card,
body.discord-activity-mode .play-shell.is-discord-activity.is-right-panel-collapsed .play-right > .control-card {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  max-height: 0;
  overflow: hidden;
}

body.discord-activity-mode .play-shell.is-discord-activity .play-right {
  display: grid;
  grid-template-rows: auto minmax(0, 1fr) auto;
}

body.discord-activity-mode .play-shell.is-discord-activity.is-activity-theater .play-right,
body.discord-activity-mode .play-shell.is-discord-activity.is-play-fullscreen .play-right,
body.discord-activity-mode .play-shell.is-discord-activity.is-game-fullscreen .play-right,
body.discord-activity-mode .play-shell.is-discord-activity[data-layout-mode="fullscreen"] .play-right {
  grid-template-rows: auto auto minmax(0, 1fr) auto;
}

body.discord-activity-mode .play-shell.is-discord-activity .system-panel {
  display: none;
}

body.discord-activity-mode .play-shell.is-discord-activity .play-center {
  min-height: 0;
  height: 100%;
  max-width: 100%;
  overflow-x: hidden;
  overflow-y: auto;
  align-self: stretch;
  align-items: center;
  justify-content: safe center;
  overscroll-behavior: contain;
}

@media (max-width: 1180px) {
  body.discord-activity-mode {
    --activity-side-panel-width: clamp(190px, 17vw, 250px);
    --runtime-board-size: clamp(280px, min(calc(100vw - (2 * var(--activity-side-panel-width)) - 82px), calc(var(--viewport-height) - 132px)), 600px);
  }
}

@media (max-width: 940px) {
  body.discord-activity-mode {
    --activity-side-panel-width: clamp(150px, 18vw, 190px);
    --runtime-board-size: clamp(260px, min(calc(100vw - (2 * var(--activity-side-panel-width)) - 72px), calc(var(--viewport-height) - 132px)), 540px);
  }
}

body.discord-activity-mode .play-shell.is-discord-activity,
body.discord-activity-mode .play-shell.is-discord-activity .play-dashboard,
body.discord-activity-mode .play-shell.is-discord-activity .play-runtime {
  max-width: 100%;
  min-width: 0;
  overflow-x: hidden;
}

body.discord-activity-mode .play-shell.is-discord-activity #fullscreen-button {
  display: inline-flex !important;
  visibility: visible !important;
}

body.discord-activity-mode .play-shell.is-discord-activity .panel-toggle {
  display: inline-flex;
  position: sticky;
  top: 2px;
  z-index: 70;
  min-height: 32px;
  padding: 6px 8px;
  border-radius: 12px;
  font-size: 0.76rem;
  background: rgba(9, 16, 26, 0.96);
}

body.discord-activity-mode .play-shell.is-discord-activity .panel-toggle-label {
  font-size: 0.7rem;
}

body.discord-activity-mode .play-shell.is-discord-activity.is-left-panel-collapsed #left-panel-toggle,
body.discord-activity-mode .play-shell.is-discord-activity.is-right-panel-collapsed #right-panel-toggle {
  top: max(12px, env(safe-area-inset-top));
  z-index: 90;
}

body.discord-activity-mode .play-shell.is-discord-activity.is-left-panel-collapsed #left-panel-toggle,
body.discord-activity-mode .play-shell.is-discord-activity.is-right-panel-collapsed #right-panel-toggle {
  position: fixed;
  width: 38px;
  min-height: 38px;
  padding: 0;
  pointer-events: auto;
}

body.discord-activity-mode .play-shell.is-discord-activity.is-left-panel-collapsed #left-panel-toggle {
  left: max(8px, env(safe-area-inset-left));
}

body.discord-activity-mode .play-shell.is-discord-activity.is-right-panel-collapsed #right-panel-toggle {
  right: max(8px, env(safe-area-inset-right));
}

body.discord-activity-mode .play-shell.is-discord-activity.is-left-panel-collapsed #left-panel-toggle .panel-toggle-label,
body.discord-activity-mode .play-shell.is-discord-activity.is-right-panel-collapsed #right-panel-toggle .panel-toggle-label {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

.play-shell.theme-classic {
  --square-light: #eadfc7;
  --square-dark: #7f6142;
  --square-hover: rgba(255, 255, 255, 0.08);
  --square-selected: rgba(216, 179, 106, 0.92);
  --square-last-move: rgba(87, 180, 255, 0.72);
}

.play-shell.theme-wana {
  --square-light: #cedaed;
  --square-dark: #2c5883;
  --square-hover: rgba(126, 198, 255, 0.12);
  --square-selected: rgba(91, 179, 255, 0.92);
  --square-last-move: rgba(120, 166, 255, 0.84);
  --board-glow: rgba(76, 152, 255, 0.18);
  --move: rgba(117, 225, 255, 0.92);
  --piece-white-color: #f5f8fd;
  --piece-black-color: #101c2a;
  --piece-white-shadow:
    0 5px 12px rgba(7, 15, 24, 0.28),
    0 0 18px rgba(92, 168, 255, 0.12);
  --piece-black-shadow:
    0 4px 12px rgba(5, 10, 16, 0.46),
    0 1px 0 rgba(235, 247, 255, 0.18);
}

.play-shell.theme-green {
  --square-light: #dbe5d1;
  --square-dark: #63814f;
  --square-hover: rgba(255, 255, 255, 0.08);
  --square-selected: rgba(236, 196, 84, 0.9);
  --square-last-move: rgba(126, 163, 94, 0.7);
  --board-glow: rgba(99, 129, 79, 0.14);
}

.play-shell.is-modal-open {
  user-select: none;
}

.play-shell.is-modal-open .board,
.play-shell.is-modal-open .play-left,
.play-shell.is-modal-open .play-right,
.play-shell.is-modal-open .board-footer,
.play-shell.is-modal-open .board-topbar {
  filter: blur(2px);
}

.play-nav,
.play-hero,
.board-frame,
.control-card {
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
  backdrop-filter: blur(16px);
}

.play-nav {
  --nav-button-height: 40px;
  --nav-button-padding-x: 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 14px 18px;
  border-radius: 20px;
  background: rgba(8, 14, 22, 0.62);
}

.play-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
  color: inherit;
}

.play-brand-copy {
  display: grid;
  gap: 2px;
  min-width: 0;
}

.logo-wanalike {
  width: 34px;
  height: 34px;
  flex: 0 0 auto;
  border-radius: 9px;
  object-fit: contain;
  filter:
    drop-shadow(0 0 10px rgba(105, 213, 255, 0.2))
    drop-shadow(0 8px 18px rgba(0, 0, 0, 0.24));
}

.play-brand strong,
h1,
h2 {
  font-family: var(--font-display);
}

.play-brand strong {
  letter-spacing: 0.04em;
}

.play-brand span,
.play-copy,
.panel-copy,
.capture-groups span {
  color: var(--muted);
}

.play-nav-links {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.play-nav-links a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  min-height: var(--nav-button-height);
  height: var(--nav-button-height);
  padding: 0 var(--nav-button-padding-x);
  border-radius: 999px;
  color: var(--muted);
  line-height: 1;
  white-space: nowrap;
  transition: background 160ms ease, color 160ms ease, box-shadow 160ms ease;
}

.play-nav-links a span,
.play-nav-auth .auth-nav-link span,
.play-nav-auth .auth-menu-item span,
.play-nav-auth .auth-menu-button span {
  display: inline-flex;
  align-items: center;
  line-height: 1;
}

.play-nav-links .nav-link-icon,
.play-nav-auth .auth-nav-icon {
  width: 1em;
  flex: 0 0 auto;
  color: currentColor;
  font-size: 0.95em;
  line-height: 1;
  text-align: center;
}

.play-nav-links a:hover {
  color: var(--text);
  background: rgba(255, 255, 255, 0.04);
  box-shadow: 0 0 18px rgba(216, 179, 106, 0.08);
}

.play-nav-links a.btn-download {
  color: #10151d;
  background: linear-gradient(135deg, #f0c983, #d8b36a);
}

.play-dashboard {
  display: grid;
  gap: 18px;
  margin-top: 18px;
  grid-template-columns: 1fr;
  align-items: start;
}

.play-hero {
  padding: 24px 28px;
  border-radius: 28px;
  background:
    radial-gradient(circle at 16% 18%, rgba(216, 179, 106, 0.18), transparent 16rem),
    radial-gradient(circle at 82% 18%, rgba(70, 144, 233, 0.28), transparent 18rem),
    linear-gradient(135deg, rgba(14, 24, 36, 0.94), rgba(9, 18, 31, 0.82));
}

.play-hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(280px, 0.8fr);
  gap: 22px;
  align-items: start;
}

.play-hero-copy {
  display: grid;
  gap: 14px;
}

.play-hero-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 8px;
}

.play-command-card {
  padding: 20px;
  border-radius: 22px;
  border: 1px solid var(--line);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.05), rgba(255, 255, 255, 0.025));
  box-shadow: var(--shadow-soft);
}

.play-command-list {
  display: grid;
  gap: 10px;
  margin-top: 14px;
}

.play-command-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 14px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.05);
}

.play-command-item span {
  color: var(--accent-blue);
  font-family: var(--font-mono);
  font-size: 0.78rem;
  letter-spacing: 0.06em;
}

.play-command-item strong {
  font-size: 0.96rem;
  text-align: right;
}

.play-kicker {
  margin: 0 0 10px;
  color: var(--accent);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-size: 0.74rem;
}

h1 {
  margin: 0;
  max-width: 15ch;
  font-size: clamp(2rem, 5vw, 4.1rem);
  line-height: 0.96;
}

.play-copy {
  max-width: 58rem;
  margin: 14px 0 0;
  line-height: 1.58;
}

.play-hero {
  grid-column: 1 / -1;
}

.play-launcher,
.play-online-stub {
  grid-column: 1 / -1;
}

.play-runtime {
  display: grid;
  grid-column: 1 / -1;
  grid-template-columns: minmax(240px, 300px) minmax(640px, 960px) minmax(300px, 380px);
  gap: 18px;
  align-items: start;
  justify-content: center;
  min-width: 0;
}

.play-runtime:fullscreen,
.play-runtime.is-play-fullscreen-root {
  width: 100%;
  height: var(--viewport-height);
  min-height: var(--viewport-height);
  margin: 0;
  padding: var(--play-shell-padding-y) var(--play-shell-padding-x);
  overflow: hidden;
  align-items: stretch;
  align-content: stretch;
  justify-content: center;
  background:
    radial-gradient(circle at top left, rgba(216, 179, 106, 0.14), transparent 20rem),
    radial-gradient(circle at bottom right, rgba(70, 144, 233, 0.18), transparent 22rem),
    linear-gradient(165deg, #040a11 0%, #09111b 52%, #101a2a 100%);
}

.play-shell[data-browser="chrome"][data-layout-mode="fullscreen"] {
  --play-fullscreen-gap: 0px;
  --play-fullscreen-left-rail: clamp(320px, 22vw, 420px);
  --play-fullscreen-right-rail: clamp(360px, 25vw, 500px);
  --play-fullscreen-center-rail: minmax(0, 1fr);
}

.play-shell[data-browser="firefox"][data-layout-mode="fullscreen"] {
  --play-fullscreen-gap: 0px;
  --play-fullscreen-left-rail: clamp(280px, 20vw, 380px);
  --play-fullscreen-right-rail: clamp(340px, 24vw, 480px);
  --play-fullscreen-center-rail: minmax(0, 1fr);
  display: grid;
  grid-template-rows: minmax(0, 1fr);
  width: 100%;
  max-width: none;
  height: var(--viewport-height);
  min-height: var(--viewport-height);
  max-height: var(--viewport-height);
  margin: 0;
  padding: 10px 12px;
  overflow: hidden;
}

.play-runtime[data-browser="firefox"]:fullscreen,
.play-runtime[data-browser="firefox"].is-play-fullscreen-root {
  width: 100%;
  max-width: 100vw;
  height: 100vh;
  min-height: 0;
}

.play-shell.is-game-view .play-dashboard {
  grid-template-columns: 1fr;
}

.play-shell.is-game-view .play-center {
  gap: 14px;
}

.play-shell.is-game-fullscreen,
.play-shell.is-play-app,
.play-shell.is-play-fullscreen,
.play-shell.is-activity-theater,
.play-shell:fullscreen,
.play-shell[data-layout-mode="fullscreen"] {
  width: 100%;
  max-width: none;
  margin: 0;
  padding: var(--play-shell-padding-y) var(--play-shell-padding-x);
}

.play-shell.is-play-app .play-dashboard,
.play-shell.is-game-fullscreen .play-dashboard,
.play-shell.is-play-fullscreen .play-dashboard,
.play-shell.is-activity-theater .play-dashboard,
.play-shell[data-layout-mode="fullscreen"] .play-dashboard {
  min-height: 100%;
  height: 100%;
  margin-top: 0;
  justify-items: stretch;
  align-items: stretch;
  overflow: hidden;
}

.play-runtime:fullscreen,
.play-runtime.is-play-fullscreen-root,
.play-runtime[data-layout-mode="fullscreen"],
.play-shell.is-play-app .play-runtime,
.play-shell.is-game-fullscreen .play-runtime,
.play-shell.is-play-fullscreen .play-runtime,
.play-shell.is-activity-theater .play-runtime,
.play-shell[data-layout-mode="fullscreen"] .play-runtime {
  --fullscreen-left-rail: var(--play-fullscreen-left-rail);
  --fullscreen-center-rail: var(--play-fullscreen-center-rail);
  --fullscreen-right-rail: var(--play-fullscreen-right-rail);
  --fullscreen-left-track: minmax(0, var(--fullscreen-left-rail));
  --fullscreen-center-track: minmax(0, 1fr);
  --fullscreen-right-track: minmax(0, var(--fullscreen-right-rail));
  grid-template-columns:
    var(--fullscreen-left-track)
    var(--fullscreen-center-track)
    var(--fullscreen-right-track);
  grid-template-areas: "left center right";
  min-height: 100%;
  height: 100%;
  width: 100%;
  max-width: none;
  margin: 0;
  padding: 0;
  justify-items: stretch;
  justify-content: stretch;
  align-items: stretch;
  gap: var(--play-fullscreen-gap);
  overflow: hidden;
}

.play-shell[data-browser="firefox"][data-layout-mode="fullscreen"] .play-runtime,
.play-runtime[data-browser="firefox"][data-layout-mode="fullscreen"],
.play-runtime[data-browser="firefox"].is-play-fullscreen-root {
  --fullscreen-left-rail: var(--play-fullscreen-left-rail);
  --fullscreen-center-rail: var(--play-fullscreen-center-rail);
  --fullscreen-right-rail: var(--play-fullscreen-right-rail);
  --fullscreen-left-track: minmax(0, var(--play-fullscreen-left-rail));
  --fullscreen-center-track: minmax(0, 1fr);
  --fullscreen-right-track: minmax(0, var(--play-fullscreen-right-rail));
  grid-template-columns:
    var(--fullscreen-left-track)
    var(--fullscreen-center-track)
    var(--fullscreen-right-track);
  grid-template-rows: minmax(0, 1fr);
  grid-template-areas: "left center right";
  grid-auto-flow: row;
  width: 100%;
  height: 100%;
  margin: 0;
  padding: 0;
  gap: var(--play-fullscreen-gap);
  justify-items: stretch;
  justify-content: stretch;
  align-items: stretch;
  align-content: stretch;
  min-width: 0;
  min-height: 0;
  max-width: 100%;
  max-height: 100%;
  overflow: hidden;
}

.play-runtime[data-layout-mode="fullscreen"] .play-left,
.play-runtime[data-layout-mode="fullscreen"] .play-right,
.play-shell.is-game-fullscreen .play-left,
.play-shell.is-game-fullscreen .play-right,
.play-shell.is-play-fullscreen .play-left,
.play-shell.is-play-fullscreen .play-right,
.play-shell.is-activity-theater .play-left,
.play-shell.is-activity-theater .play-right,
.play-shell[data-layout-mode="fullscreen"] .play-left,
.play-shell[data-layout-mode="fullscreen"] .play-right {
  display: grid;
  width: 100%;
  justify-self: stretch;
  align-self: stretch;
  align-content: start;
  height: 100%;
  max-height: 100%;
  min-height: 0;
  min-width: 0;
  overflow: auto;
  overscroll-behavior: contain;
  scrollbar-gutter: auto;
}

.play-shell[data-browser="firefox"][data-layout-mode="fullscreen"] .play-left,
.play-shell[data-browser="firefox"][data-layout-mode="fullscreen"] .play-right,
.play-runtime[data-browser="firefox"][data-layout-mode="fullscreen"] .play-left,
.play-runtime[data-browser="firefox"][data-layout-mode="fullscreen"] .play-right,
.play-runtime[data-browser="firefox"].is-play-fullscreen-root .play-left,
.play-runtime[data-browser="firefox"].is-play-fullscreen-root .play-right {
  block-size: 100%;
  max-block-size: 100%;
  min-block-size: 0;
  overflow-x: hidden;
  overflow-y: auto;
}

.play-runtime[data-layout-mode="fullscreen"] .play-center,
.play-shell.is-game-fullscreen .play-center,
.play-shell.is-play-fullscreen .play-center,
.play-shell.is-activity-theater .play-center,
.play-shell[data-layout-mode="fullscreen"] .play-center {
  grid-area: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: 100%;
  justify-self: stretch;
  align-self: stretch;
  order: initial;
  height: 100%;
  max-height: 100%;
  min-height: 0;
  min-width: 0;
  overflow: hidden;
}

.play-shell[data-browser="firefox"][data-layout-mode="fullscreen"] .play-left,
.play-runtime[data-browser="firefox"][data-layout-mode="fullscreen"] .play-left,
.play-runtime[data-browser="firefox"].is-play-fullscreen-root .play-left {
  grid-area: auto;
  grid-column: 1 / 2;
  grid-row: 1 / 2;
}

.play-shell[data-browser="firefox"][data-layout-mode="fullscreen"] .play-center,
.play-runtime[data-browser="firefox"][data-layout-mode="fullscreen"] .play-center,
.play-runtime[data-browser="firefox"].is-play-fullscreen-root .play-center {
  grid-area: auto;
  grid-column: 2 / 3;
  grid-row: 1 / 2;
  block-size: 100%;
  max-block-size: 100%;
  min-block-size: 0;
}

.play-shell[data-browser="firefox"][data-layout-mode="fullscreen"] .play-right,
.play-runtime[data-browser="firefox"][data-layout-mode="fullscreen"] .play-right,
.play-runtime[data-browser="firefox"].is-play-fullscreen-root .play-right {
  grid-area: auto;
  grid-column: 3 / 4;
  grid-row: 1 / 2;
  align-content: stretch;
  overflow: hidden;
  scrollbar-gutter: auto;
}

.play-runtime[data-layout-mode="fullscreen"] .play-right,
.play-shell.is-game-fullscreen .play-right,
.play-shell.is-play-fullscreen .play-right,
.play-shell.is-activity-theater .play-right,
.play-shell[data-layout-mode="fullscreen"] .play-right {
  grid-area: right;
  order: initial;
  align-content: stretch;
  inline-size: var(--fullscreen-right-track);
  max-inline-size: var(--fullscreen-right-track);
  overflow: hidden;
  scrollbar-gutter: auto;
  contain: inline-size;
}

.play-runtime[data-layout-mode="fullscreen"] .play-left,
.play-shell.is-game-fullscreen .play-left,
.play-shell.is-play-fullscreen .play-left,
.play-shell.is-activity-theater .play-left,
.play-shell[data-layout-mode="fullscreen"] .play-left {
  grid-area: left;
  order: initial;
  inline-size: var(--fullscreen-left-rail);
  max-inline-size: var(--fullscreen-left-rail);
  overflow-x: hidden;
  overflow-y: auto;
  contain: inline-size;
}

@-moz-document url-prefix() {
  .play-shell[data-layout-mode="fullscreen"] {
    --play-fullscreen-gap: 0px;
    --play-fullscreen-left-rail: clamp(280px, 20vw, 380px);
    --play-fullscreen-right-rail: clamp(340px, 24vw, 480px);
    --play-fullscreen-center-rail: minmax(0, 1fr);
    width: 100%;
    max-width: 100vw;
    min-width: 0;
    padding: 10px 12px;
    overflow: hidden;
  }

  .play-shell[data-layout-mode="fullscreen"] .play-dashboard,
  .play-shell[data-layout-mode="fullscreen"] .play-runtime {
    min-width: 0;
    max-width: 100%;
    overflow: hidden;
  }

  .play-shell[data-layout-mode="fullscreen"] .play-runtime {
    --fullscreen-left-rail: var(--play-fullscreen-left-rail);
    --fullscreen-center-rail: var(--play-fullscreen-center-rail);
    --fullscreen-right-rail: var(--play-fullscreen-right-rail);
    --fullscreen-left-track: minmax(0, var(--fullscreen-left-rail));
    --fullscreen-center-track: minmax(0, 1fr);
    --fullscreen-right-track: minmax(0, var(--fullscreen-right-rail));
    grid-template-columns:
      var(--fullscreen-left-track)
      var(--fullscreen-center-track)
      var(--fullscreen-right-track);
    width: 100%;
    max-width: 100%;
    justify-content: stretch;
    gap: 0;
  }

  .play-shell[data-layout-mode="fullscreen"] .play-left {
    inline-size: var(--fullscreen-left-rail);
    max-inline-size: var(--fullscreen-left-rail);
    min-width: 0;
  }

  .play-shell[data-layout-mode="fullscreen"] .play-right {
    inline-size: var(--fullscreen-right-track);
    max-inline-size: var(--fullscreen-right-track);
    min-width: 0;
  }
}

.play-shell.is-game-fullscreen.is-left-panel-collapsed .play-runtime,
.play-shell.is-play-fullscreen.is-left-panel-collapsed .play-runtime,
.play-shell[data-layout-mode="fullscreen"].is-left-panel-collapsed .play-runtime {
  --fullscreen-left-rail: 52px;
  --fullscreen-left-track: 0px;
}

.play-shell.is-game-fullscreen.is-right-panel-collapsed .play-runtime,
.play-shell.is-play-fullscreen.is-right-panel-collapsed .play-runtime,
.play-shell[data-layout-mode="fullscreen"].is-right-panel-collapsed .play-runtime {
  --fullscreen-right-rail: 52px;
  --fullscreen-right-track: 0px;
}

.play-shell.is-game-fullscreen.is-left-panel-collapsed .play-runtime,
.play-shell.is-play-fullscreen.is-left-panel-collapsed .play-runtime,
.play-shell[data-layout-mode="fullscreen"].is-left-panel-collapsed .play-runtime,
.play-shell.is-game-fullscreen.is-right-panel-collapsed .play-runtime,
.play-shell.is-play-fullscreen.is-right-panel-collapsed .play-runtime,
.play-shell[data-layout-mode="fullscreen"].is-right-panel-collapsed .play-runtime {
  gap: 0;
}

.play-left,
.play-center,
.play-right {
  display: grid;
  gap: 12px;
  align-content: start;
}

.play-left,
.play-right {
  position: relative;
}

.play-left {
  min-width: 0;
}

.play-center {
  min-width: 0;
  gap: 16px;
  justify-items: center;
}

.play-right {
  min-width: 0;
  grid-template-rows: auto minmax(360px, 1fr) auto auto;
}

.play-runtime[data-layout-mode="fullscreen"] .play-left,
.play-shell.is-game-fullscreen .play-left,
.play-shell.is-play-fullscreen .play-left,
.play-shell[data-layout-mode="fullscreen"] .play-left {
  grid-template-rows: auto minmax(0, auto) minmax(0, 1fr);
}

.play-runtime[data-layout-mode="fullscreen"] .play-right,
.play-shell.is-game-fullscreen .play-right,
.play-shell.is-play-fullscreen .play-right,
.play-shell[data-layout-mode="fullscreen"] .play-right {
  gap: 10px;
  grid-template-rows: auto minmax(0, max-content) minmax(0, 1fr) minmax(0, max-content);
}

.play-shell.is-debug-mode .play-runtime[data-layout-mode="fullscreen"] .play-right,
.play-shell.is-debug-mode.is-game-fullscreen .play-right,
.play-shell.is-debug-mode.is-play-fullscreen .play-right,
.play-shell.is-debug-mode[data-layout-mode="fullscreen"] .play-right {
  grid-template-rows: auto minmax(0, max-content) minmax(0, 1fr) minmax(0, max-content) minmax(0, max-content);
}

.play-shell[data-browser="firefox"][data-layout-mode="fullscreen"] .play-left,
.play-runtime[data-browser="firefox"][data-layout-mode="fullscreen"] .play-left,
.play-runtime[data-browser="firefox"].is-play-fullscreen-root .play-left {
  grid-template-rows: auto minmax(0, max-content) minmax(0, 1fr);
}

.play-shell[data-browser="firefox"][data-layout-mode="fullscreen"] .play-right,
.play-runtime[data-browser="firefox"][data-layout-mode="fullscreen"] .play-right,
.play-runtime[data-browser="firefox"].is-play-fullscreen-root .play-right {
  grid-template-rows: auto minmax(0, max-content) minmax(0, 1fr) minmax(0, max-content);
}

.play-shell.is-play-app .action-panel,
.play-shell.is-game-fullscreen .action-panel,
.play-shell.is-play-fullscreen .action-panel,
.play-shell[data-layout-mode="fullscreen"] .action-panel {
  position: static;
  padding: 10px 12px;
}

.play-shell.is-play-app .action-panel .section-head,
.play-shell.is-game-fullscreen .action-panel .section-head,
.play-shell.is-play-fullscreen .action-panel .section-head,
.play-shell[data-layout-mode="fullscreen"] .action-panel .section-head {
  gap: 6px;
  margin-bottom: 8px;
}

.play-shell.is-play-app .action-panel h2,
.play-shell.is-game-fullscreen .action-panel h2,
.play-shell.is-play-fullscreen .action-panel h2,
.play-shell[data-layout-mode="fullscreen"] .action-panel h2 {
  font-size: 0.96rem;
  line-height: 1.08;
}

.play-shell.is-play-app .action-panel .play-kicker,
.play-shell.is-game-fullscreen .action-panel .play-kicker,
.play-shell.is-play-fullscreen .action-panel .play-kicker,
.play-shell[data-layout-mode="fullscreen"] .action-panel .play-kicker {
  margin-bottom: 3px;
  font-size: 0.6rem;
}

.play-shell.is-play-app .action-panel .action-stack,
.play-shell.is-game-fullscreen .action-panel .action-stack,
.play-shell.is-play-fullscreen .action-panel .action-stack,
.play-shell[data-layout-mode="fullscreen"] .action-panel .action-stack {
  gap: 5px;
}

.play-shell.is-play-app .action-panel .primary-action,
.play-shell.is-play-app .action-panel .secondary-action,
.play-shell.is-game-fullscreen .action-panel .primary-action,
.play-shell.is-game-fullscreen .action-panel .secondary-action,
.play-shell.is-play-fullscreen .action-panel .primary-action,
.play-shell.is-play-fullscreen .action-panel .secondary-action,
.play-shell[data-layout-mode="fullscreen"] .action-panel .primary-action,
.play-shell[data-layout-mode="fullscreen"] .action-panel .secondary-action {
  min-height: 36px;
  padding: 7px 12px;
  font-size: 0.86rem;
}

.play-shell.is-play-app .action-panel .primary-action,
.play-shell.is-game-fullscreen .action-panel .primary-action,
.play-shell.is-play-fullscreen .action-panel .primary-action,
.play-shell[data-layout-mode="fullscreen"] .action-panel .primary-action {
  margin-top: 0;
}

body.discord-activity-mode .play-shell.is-discord-activity .control-card {
  border-radius: 16px;
}

body.discord-activity-mode .play-shell.is-discord-activity .player-panel,
body.discord-activity-mode .play-shell.is-discord-activity .action-panel,
body.discord-activity-mode .play-shell.is-discord-activity .game-chat-panel,
body.discord-activity-mode .play-shell.is-discord-activity .capture-panel,
body.discord-activity-mode .play-shell.is-discord-activity .status-panel {
  padding: 8px 10px;
  gap: 8px;
}

body.discord-activity-mode .play-shell.is-discord-activity .action-panel {
  position: static;
}

body.discord-activity-mode .play-shell.is-discord-activity .action-panel .play-kicker,
body.discord-activity-mode .play-shell.is-discord-activity .action-panel h2 {
  display: none;
}

body.discord-activity-mode .play-shell.is-discord-activity .action-panel .action-stack {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 5px !important;
}

body.discord-activity-mode .play-shell.is-discord-activity .action-panel .primary-action,
body.discord-activity-mode .play-shell.is-discord-activity .action-panel .secondary-action {
  min-height: 30px;
  padding: 5px 6px;
  border-radius: 10px;
  font-size: 0.72rem;
  line-height: 1.1;
}

body.discord-activity-mode .play-shell.is-discord-activity .player-panel {
  position: sticky;
  top: 0;
  z-index: 3;
  gap: 6px;
  padding: 7px 8px;
  border-radius: 12px;
  background:
    linear-gradient(180deg, rgba(12, 20, 32, 0.98), rgba(8, 15, 24, 0.96));
}

body.discord-activity-mode .play-shell.is-discord-activity .player-stack {
  gap: 5px;
}

body.discord-activity-mode .play-shell.is-discord-activity .player-card {
  grid-template-columns: 24px minmax(0, 1fr) minmax(38px, auto);
  min-height: 40px;
  padding: 5px 6px;
  gap: 5px;
  border-radius: 10px;
  min-width: 0;
}

body.discord-activity-mode .play-shell.is-discord-activity .player-copy {
  min-width: 0;
}

body.discord-activity-mode .play-shell.is-discord-activity .player-copy strong,
body.discord-activity-mode .play-shell.is-discord-activity .player-copy span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

body.discord-activity-mode .play-shell.is-discord-activity .player-copy strong {
  font-size: 0.82rem;
  line-height: 1.08;
}

body.discord-activity-mode .play-shell.is-discord-activity .player-copy span {
  font-size: 0.66rem;
  line-height: 1.12;
}

body.discord-activity-mode .play-shell.is-discord-activity .player-badge {
  max-width: 100%;
  min-height: 18px;
  padding: 0 5px;
  white-space: nowrap;
  text-align: center;
  line-height: 1.05;
  font-size: 0.58rem;
}

body.discord-activity-mode .play-shell.is-discord-activity .player-avatar {
  width: 24px;
  height: 24px;
  font-size: 0.78rem;
}

.play-runtime[data-layout-mode="fullscreen"] .player-panel,
.play-shell.is-game-fullscreen .player-panel,
.play-shell.is-play-fullscreen .player-panel,
.play-shell[data-layout-mode="fullscreen"] .player-panel {
  padding: 10px 12px;
  gap: 10px;
}

.play-runtime[data-layout-mode="fullscreen"] .player-stack,
.play-shell.is-game-fullscreen .player-stack,
.play-shell.is-play-fullscreen .player-stack,
.play-shell[data-layout-mode="fullscreen"] .player-stack {
  gap: 8px;
}

.play-runtime[data-layout-mode="fullscreen"] .player-card,
.play-shell.is-game-fullscreen .player-card,
.play-shell.is-play-fullscreen .player-card,
.play-shell[data-layout-mode="fullscreen"] .player-card {
  min-height: 58px;
  padding: 9px 10px;
  gap: 8px;
  border-radius: 15px;
}

.play-runtime[data-layout-mode="fullscreen"] .player-avatar,
.play-shell.is-game-fullscreen .player-avatar,
.play-shell.is-play-fullscreen .player-avatar,
.play-shell[data-layout-mode="fullscreen"] .player-avatar {
  width: 34px;
  height: 34px;
}

.play-runtime[data-layout-mode="fullscreen"] .player-copy,
.play-shell.is-game-fullscreen .player-copy,
.play-shell.is-play-fullscreen .player-copy,
.play-shell[data-layout-mode="fullscreen"] .player-copy {
  gap: 2px;
}

.play-runtime[data-layout-mode="fullscreen"] .player-copy strong,
.play-shell.is-game-fullscreen .player-copy strong,
.play-shell.is-play-fullscreen .player-copy strong,
.play-shell[data-layout-mode="fullscreen"] .player-copy strong {
  font-size: 0.92rem;
}

.play-runtime[data-layout-mode="fullscreen"] .player-copy span,
.play-shell.is-game-fullscreen .player-copy span,
.play-shell.is-play-fullscreen .player-copy span,
.play-shell[data-layout-mode="fullscreen"] .player-copy span {
  font-size: 0.76rem;
}

.play-runtime[data-layout-mode="fullscreen"] .player-badge,
.play-shell.is-game-fullscreen .player-badge,
.play-shell.is-play-fullscreen .player-badge,
.play-shell[data-layout-mode="fullscreen"] .player-badge {
  min-height: 23px;
  padding: 0 7px;
  font-size: 0.66rem;
}

.play-runtime[data-layout-mode="fullscreen"] .action-panel,
.play-shell.is-game-fullscreen .action-panel,
.play-shell.is-play-fullscreen .action-panel,
.play-shell[data-layout-mode="fullscreen"] .action-panel {
  gap: 8px;
  padding: 8px 10px;
}

.play-runtime[data-layout-mode="fullscreen"] .action-panel .action-stack,
.play-shell.is-game-fullscreen .action-panel .action-stack,
.play-shell.is-play-fullscreen .action-panel .action-stack,
.play-shell[data-layout-mode="fullscreen"] .action-panel .action-stack {
  gap: 4px !important;
}

.play-runtime[data-layout-mode="fullscreen"] .action-panel .primary-action,
.play-runtime[data-layout-mode="fullscreen"] .action-panel .secondary-action,
.play-shell.is-game-fullscreen .action-panel .primary-action,
.play-shell.is-game-fullscreen .action-panel .secondary-action,
.play-shell.is-play-fullscreen .action-panel .primary-action,
.play-shell.is-play-fullscreen .action-panel .secondary-action,
.play-shell[data-layout-mode="fullscreen"] .action-panel .primary-action,
.play-shell[data-layout-mode="fullscreen"] .action-panel .secondary-action {
  min-height: 32px;
  padding: 5px 10px;
  font-size: 0.8rem;
}

.play-shell:not(.is-debug-mode) .system-panel,
.play-runtime:not(.is-debug-mode) .system-panel,
[data-debug-mode="normal"] .system-panel {
  display: none !important;
}

.play-shell.is-game-view .system-panel,
.play-shell.is-game-view .product-panel {
  opacity: 0.82;
}

.play-shell.is-play-app .play-nav,
.play-shell.is-game-fullscreen .play-nav,
.play-shell.is-play-fullscreen .play-nav,
.play-shell[data-layout-mode="fullscreen"] .play-nav {
  display: none;
}

body.discord-activity-mode .play-shell.is-discord-activity.is-play-app .play-nav,
body.discord-activity-mode .play-shell.is-discord-activity.is-game-fullscreen .play-nav,
body.discord-activity-mode .play-shell.is-discord-activity.is-play-fullscreen .play-nav,
body.discord-activity-mode .play-shell.is-discord-activity[data-layout-mode="fullscreen"] .play-nav {
  display: grid;
}

.play-runtime[data-layout-mode="fullscreen"] .board,
.play-shell.is-game-fullscreen .board,
.play-shell.is-play-fullscreen .board,
.play-shell[data-layout-mode="fullscreen"] .board {
  width: var(--runtime-board-size);
  min-width: 0;
  min-height: 0;
  max-width: var(--runtime-board-size);
  height: var(--runtime-board-size);
  max-height: var(--runtime-board-size);
}

.play-runtime[data-layout-mode="fullscreen"] .board-frame,
.play-runtime[data-layout-mode="fullscreen"] .game-chat-panel,
.play-runtime[data-layout-mode="fullscreen"] .control-card,
.play-shell.is-play-app .board-frame,
.play-shell.is-play-app .game-chat-panel,
.play-shell.is-play-app .control-card,
.play-shell.is-game-fullscreen .board-frame,
.play-shell.is-game-fullscreen .game-chat-panel,
.play-shell.is-game-fullscreen .control-card,
.play-shell.is-play-fullscreen .board-frame,
.play-shell.is-play-fullscreen .game-chat-panel,
.play-shell.is-play-fullscreen .control-card,
.play-shell[data-layout-mode="fullscreen"] .board-frame,
.play-shell[data-layout-mode="fullscreen"] .game-chat-panel,
.play-shell[data-layout-mode="fullscreen"] .control-card {
  border-radius: 20px;
}

.play-runtime[data-layout-mode="fullscreen"] .game-chat-panel,
.play-shell.is-play-app .game-chat-panel,
.play-shell.is-game-fullscreen .game-chat-panel,
.play-shell.is-play-fullscreen .game-chat-panel,
.play-shell[data-layout-mode="fullscreen"] .game-chat-panel {
  width: 100%;
  max-width: 100%;
  min-height: 0;
  min-width: 0;
  gap: 10px;
  padding: 14px;
  display: grid;
  grid-template-rows: auto auto auto minmax(0, 1fr) auto;
  grid-template-areas:
    "chat-head"
    "chat-tabs"
    "chat-coach"
    "chat-history"
    "chat-compose";
  align-content: stretch;
  overflow: hidden;
  contain: inline-size;
}

.play-runtime[data-layout-mode="fullscreen"] .game-chat-panel .section-head,
.play-shell.is-play-app .game-chat-panel .section-head,
.play-shell.is-game-fullscreen .game-chat-panel .section-head,
.play-shell.is-play-fullscreen .game-chat-panel .section-head,
.play-shell[data-layout-mode="fullscreen"] .game-chat-panel .section-head {
  grid-area: chat-head;
  gap: 6px;
}

.play-runtime[data-layout-mode="fullscreen"] .game-chat-panel .play-kicker,
.play-shell.is-play-app .game-chat-panel .play-kicker,
.play-shell.is-game-fullscreen .game-chat-panel .play-kicker,
.play-shell.is-play-fullscreen .game-chat-panel .play-kicker,
.play-shell[data-layout-mode="fullscreen"] .game-chat-panel .play-kicker {
  margin-bottom: 3px;
  font-size: 0.6rem;
}

.play-runtime[data-layout-mode="fullscreen"] .game-chat-panel .section-head h2,
.play-shell.is-play-app .game-chat-panel .section-head h2,
.play-shell.is-game-fullscreen .game-chat-panel .section-head h2,
.play-shell.is-play-fullscreen .game-chat-panel .section-head h2,
.play-shell[data-layout-mode="fullscreen"] .game-chat-panel .section-head h2 {
  font-size: 0.98rem;
}

.play-runtime[data-layout-mode="fullscreen"] .game-chat-panel .chat-tabs,
.play-shell.is-play-app .game-chat-panel .chat-tabs,
.play-shell.is-game-fullscreen .game-chat-panel .chat-tabs,
.play-shell.is-play-fullscreen .game-chat-panel .chat-tabs,
.play-shell[data-layout-mode="fullscreen"] .game-chat-panel .chat-tabs {
  grid-area: chat-tabs;
  gap: 6px;
}

.play-runtime[data-layout-mode="fullscreen"] .game-chat-panel .chat-tab,
.play-shell.is-play-app .game-chat-panel .chat-tab,
.play-shell.is-game-fullscreen .game-chat-panel .chat-tab,
.play-shell.is-play-fullscreen .game-chat-panel .chat-tab,
.play-shell[data-layout-mode="fullscreen"] .game-chat-panel .chat-tab {
  min-height: 30px;
  padding: 0 10px;
  font-size: 0.78rem;
}

.play-runtime[data-layout-mode="fullscreen"] .game-chat-panel .coach-insight-panel,
.play-shell.is-play-app .game-chat-panel .coach-insight-panel,
.play-shell.is-game-fullscreen .game-chat-panel .coach-insight-panel,
.play-shell.is-play-fullscreen .game-chat-panel .coach-insight-panel,
.play-shell[data-layout-mode="fullscreen"] .game-chat-panel .coach-insight-panel {
  grid-area: chat-coach;
}

.play-runtime[data-layout-mode="fullscreen"] .game-chat-history,
.play-shell.is-play-app .game-chat-history,
.play-shell.is-game-fullscreen .game-chat-history,
.play-shell.is-play-fullscreen .game-chat-history,
.play-shell[data-layout-mode="fullscreen"] .game-chat-history {
  grid-area: chat-history;
  flex: 1 1 auto;
  height: auto;
  max-height: none;
  max-width: 100%;
  min-width: 0;
  min-height: 0;
  align-self: stretch;
  overflow-x: hidden;
  padding: 10px 10px 10px 12px !important;
}

.play-runtime[data-layout-mode="fullscreen"] .game-chat-panel .chat-compose,
.play-shell.is-play-app .game-chat-panel .chat-compose,
.play-shell.is-game-fullscreen .game-chat-panel .chat-compose,
.play-shell.is-play-fullscreen .game-chat-panel .chat-compose,
.play-shell[data-layout-mode="fullscreen"] .game-chat-panel .chat-compose {
  grid-area: chat-compose;
  align-self: end;
  grid-template-columns: minmax(0, 1fr) auto;
  max-width: 100%;
  min-width: 0;
  position: relative;
  z-index: 1;
  margin-top: 10px;
  padding-top: 12px;
  border-top-color: rgba(183, 204, 226, 0.18);
  background: linear-gradient(180deg, rgba(8, 15, 25, 0), rgba(8, 15, 25, 0.78) 30%);
  box-shadow: 0 -10px 18px rgba(3, 8, 14, 0.18);
}

.play-runtime[data-layout-mode="fullscreen"] .game-chat-panel .chat-compose input,
.play-shell.is-play-app .game-chat-panel .chat-compose input,
.play-shell.is-game-fullscreen .game-chat-panel .chat-compose input,
.play-shell.is-play-fullscreen .game-chat-panel .chat-compose input,
.play-shell[data-layout-mode="fullscreen"] .game-chat-panel .chat-compose input {
  min-width: 0;
}

.play-runtime[data-layout-mode="fullscreen"] .game-chat-panel .chat-compose .secondary-action,
.play-shell.is-play-app .game-chat-panel .chat-compose .secondary-action,
.play-shell.is-game-fullscreen .game-chat-panel .chat-compose .secondary-action,
.play-shell.is-play-fullscreen .game-chat-panel .chat-compose .secondary-action,
.play-shell[data-layout-mode="fullscreen"] .game-chat-panel .chat-compose .secondary-action {
  min-width: 94px;
  padding-inline: 12px;
}

.play-shell[data-browser="firefox"][data-layout-mode="fullscreen"] .game-chat-panel,
.play-runtime[data-browser="firefox"][data-layout-mode="fullscreen"] .game-chat-panel,
.play-runtime[data-browser="firefox"].is-play-fullscreen-root .game-chat-panel {
  height: 100%;
  max-height: 100%;
}

.play-shell[data-browser="firefox"][data-layout-mode="fullscreen"] .game-chat-history,
.play-runtime[data-browser="firefox"][data-layout-mode="fullscreen"] .game-chat-history,
.play-runtime[data-browser="firefox"].is-play-fullscreen-root .game-chat-history {
  min-height: 96px;
  overflow-y: auto;
}

.play-runtime[data-layout-mode="fullscreen"] .chat-history li,
.play-shell.is-play-app .chat-history li,
.play-shell.is-game-fullscreen .chat-history li,
.play-shell.is-play-fullscreen .chat-history li,
.play-shell[data-layout-mode="fullscreen"] .chat-history li {
  max-width: 100%;
  min-width: 0;
  overflow-wrap: anywhere;
}

.play-runtime[data-layout-mode="fullscreen"] .chat-history li.is-coach,
.play-shell.is-play-app .chat-history li.is-coach,
.play-shell.is-game-fullscreen .chat-history li.is-coach,
.play-shell.is-play-fullscreen .chat-history li.is-coach,
.play-shell[data-layout-mode="fullscreen"] .chat-history li.is-coach {
  grid-template-columns: 42px minmax(0, 1fr);
  gap: 8px;
  padding: 10px 11px;
}

.play-runtime[data-layout-mode="fullscreen"] .chat-history li.is-coach .coach-avatar,
.play-shell.is-play-app .chat-history li.is-coach .coach-avatar,
.play-shell.is-game-fullscreen .chat-history li.is-coach .coach-avatar,
.play-shell.is-play-fullscreen .chat-history li.is-coach .coach-avatar,
.play-shell[data-layout-mode="fullscreen"] .chat-history li.is-coach .coach-avatar {
  width: 42px;
  height: 42px;
  border-radius: 14px;
}

.play-runtime[data-layout-mode="fullscreen"] .chat-message-copy,
.play-shell.is-play-app .chat-message-copy,
.play-shell.is-game-fullscreen .chat-message-copy,
.play-shell.is-play-fullscreen .chat-message-copy,
.play-shell[data-layout-mode="fullscreen"] .chat-message-copy,
.play-runtime[data-layout-mode="fullscreen"] .chat-message-text,
.play-shell.is-play-app .chat-message-text,
.play-shell.is-game-fullscreen .chat-message-text,
.play-shell.is-play-fullscreen .chat-message-text,
.play-shell[data-layout-mode="fullscreen"] .chat-message-text,
.play-runtime[data-layout-mode="fullscreen"] .coach-body,
.play-shell.is-play-app .coach-body,
.play-shell.is-game-fullscreen .coach-body,
.play-shell.is-play-fullscreen .coach-body,
.play-shell[data-layout-mode="fullscreen"] .coach-body {
  max-width: 100%;
  min-width: 0;
  overflow-wrap: anywhere;
}

.panel-toggle {
  display: none;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 44px;
  padding: 10px 12px;
  border: 1px solid rgba(93, 167, 255, 0.18);
  border-radius: 16px;
  background: rgba(9, 16, 26, 0.84);
  color: var(--text);
  font: inherit;
  cursor: pointer;
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.24);
}

.panel-toggle-icon {
  font-size: 1rem;
  line-height: 1;
}

.panel-toggle-label {
  white-space: nowrap;
  font-size: 0.82rem;
  letter-spacing: 0.04em;
}

.play-runtime[data-layout-mode="fullscreen"] .panel-toggle,
.play-shell.is-play-app .panel-toggle,
.play-shell.is-game-fullscreen .panel-toggle,
.play-shell.is-play-fullscreen .panel-toggle,
.play-shell[data-layout-mode="fullscreen"] .panel-toggle {
  display: inline-flex;
  position: sticky;
  top: 12px;
  z-index: 4;
  justify-self: stretch;
  min-width: 0;
  max-width: 100%;
  overflow: hidden;
}

.play-runtime[data-layout-mode="fullscreen"] .panel-toggle-label,
.play-shell.is-play-app .panel-toggle-label,
.play-shell.is-game-fullscreen .panel-toggle-label,
.play-shell.is-play-fullscreen .panel-toggle-label,
.play-shell[data-layout-mode="fullscreen"] .panel-toggle-label {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
}

.play-shell.is-play-app.is-left-panel-collapsed .play-left > .control-card,
.play-shell.is-play-app.is-right-panel-collapsed .play-right > .control-card,
.play-shell.is-game-fullscreen.is-left-panel-collapsed .play-left > .control-card,
.play-shell.is-game-fullscreen.is-right-panel-collapsed .play-right > .control-card,
.play-shell.is-play-fullscreen.is-left-panel-collapsed .play-left > .control-card,
.play-shell.is-play-fullscreen.is-right-panel-collapsed .play-right > .control-card,
.play-shell[data-layout-mode="fullscreen"].is-left-panel-collapsed .play-left > .control-card,
.play-shell[data-layout-mode="fullscreen"].is-right-panel-collapsed .play-right > .control-card {
  opacity: 0;
  transform: translateY(8px);
  pointer-events: none;
  visibility: hidden;
  max-height: 0;
  overflow: hidden;
  margin: 0;
  padding-top: 0;
  padding-bottom: 0;
  border-width: 0;
}

.play-shell.is-play-app.is-left-panel-collapsed .play-left,
.play-shell.is-game-fullscreen.is-left-panel-collapsed .play-left,
.play-shell.is-play-fullscreen.is-left-panel-collapsed .play-left,
.play-shell[data-layout-mode="fullscreen"].is-left-panel-collapsed .play-left,
.play-shell.is-play-app.is-right-panel-collapsed .play-right,
.play-shell.is-game-fullscreen.is-right-panel-collapsed .play-right,
.play-shell.is-play-fullscreen.is-right-panel-collapsed .play-right,
.play-shell[data-layout-mode="fullscreen"].is-right-panel-collapsed .play-right {
  width: 0;
  min-width: 0;
  overflow: visible;
  scrollbar-gutter: auto;
  pointer-events: none;
}

.play-shell.is-play-app.is-left-panel-collapsed #left-panel-toggle,
.play-shell.is-game-fullscreen.is-left-panel-collapsed #left-panel-toggle,
.play-shell.is-play-fullscreen.is-left-panel-collapsed #left-panel-toggle,
.play-shell[data-layout-mode="fullscreen"].is-left-panel-collapsed #left-panel-toggle,
.play-shell.is-play-app.is-right-panel-collapsed #right-panel-toggle,
.play-shell.is-game-fullscreen.is-right-panel-collapsed #right-panel-toggle,
.play-shell.is-play-fullscreen.is-right-panel-collapsed #right-panel-toggle,
.play-shell[data-layout-mode="fullscreen"].is-right-panel-collapsed #right-panel-toggle {
  position: fixed;
  top: max(12px, env(safe-area-inset-top));
  z-index: 30;
  width: 44px;
  min-height: 44px;
  padding: 0;
  pointer-events: auto;
}

.play-shell.is-play-app.is-left-panel-collapsed #left-panel-toggle,
.play-shell.is-game-fullscreen.is-left-panel-collapsed #left-panel-toggle,
.play-shell.is-play-fullscreen.is-left-panel-collapsed #left-panel-toggle,
.play-shell[data-layout-mode="fullscreen"].is-left-panel-collapsed #left-panel-toggle {
  left: max(12px, env(safe-area-inset-left));
}

.play-shell.is-play-app.is-right-panel-collapsed #right-panel-toggle,
.play-shell.is-game-fullscreen.is-right-panel-collapsed #right-panel-toggle,
.play-shell.is-play-fullscreen.is-right-panel-collapsed #right-panel-toggle,
.play-shell[data-layout-mode="fullscreen"].is-right-panel-collapsed #right-panel-toggle {
  right: max(12px, env(safe-area-inset-right));
}

.play-shell.is-play-app.is-left-panel-collapsed #left-panel-toggle .panel-toggle-label,
.play-shell.is-game-fullscreen.is-left-panel-collapsed #left-panel-toggle .panel-toggle-label,
.play-shell.is-play-fullscreen.is-left-panel-collapsed #left-panel-toggle .panel-toggle-label,
.play-shell[data-layout-mode="fullscreen"].is-left-panel-collapsed #left-panel-toggle .panel-toggle-label,
.play-shell.is-play-app.is-right-panel-collapsed #right-panel-toggle .panel-toggle-label,
.play-shell.is-game-fullscreen.is-right-panel-collapsed #right-panel-toggle .panel-toggle-label,
.play-shell.is-play-fullscreen.is-right-panel-collapsed #right-panel-toggle .panel-toggle-label,
.play-shell[data-layout-mode="fullscreen"].is-right-panel-collapsed #right-panel-toggle .panel-toggle-label {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

.play-shell.is-play-app.is-left-panel-collapsed .play-left,
.play-shell.is-game-fullscreen.is-left-panel-collapsed .play-left,
.play-shell.is-play-fullscreen.is-left-panel-collapsed .play-left,
.play-shell[data-layout-mode="fullscreen"].is-left-panel-collapsed .play-left {
  gap: 10px;
}

.play-shell.is-play-app.is-right-panel-collapsed .play-right,
.play-shell.is-game-fullscreen.is-right-panel-collapsed .play-right,
.play-shell.is-play-fullscreen.is-right-panel-collapsed .play-right,
.play-shell[data-layout-mode="fullscreen"].is-right-panel-collapsed .play-right {
  gap: 10px;
}

.play-shell.is-play-app.is-left-panel-collapsed #left-panel-toggle .panel-toggle-icon,
.play-shell.is-play-app.is-right-panel-collapsed #right-panel-toggle .panel-toggle-icon,
.play-shell.is-game-fullscreen.is-left-panel-collapsed #left-panel-toggle .panel-toggle-icon,
.play-shell.is-game-fullscreen.is-right-panel-collapsed #right-panel-toggle .panel-toggle-icon,
.play-shell.is-play-fullscreen.is-left-panel-collapsed #left-panel-toggle .panel-toggle-icon,
.play-shell.is-play-fullscreen.is-right-panel-collapsed #right-panel-toggle .panel-toggle-icon,
.play-shell[data-layout-mode="fullscreen"].is-left-panel-collapsed #left-panel-toggle .panel-toggle-icon,
.play-shell[data-layout-mode="fullscreen"].is-right-panel-collapsed #right-panel-toggle .panel-toggle-icon {
  transform: rotate(180deg);
}

.board-frame {
  position: relative;
  display: grid;
  gap: 14px;
  padding: 18px;
  border-radius: 30px;
  background:
    radial-gradient(circle at 20% 0%, rgba(93, 167, 255, 0.11), transparent 16rem),
    linear-gradient(180deg, rgba(11, 19, 30, 0.94), rgba(8, 15, 24, 0.9));
  min-width: 0;
  align-self: start;
  width: min(100%, clamp(720px, 70vw, 1120px));
  max-width: 100%;
  justify-self: center;
  margin-inline: auto;
  overflow: hidden;
}

.play-runtime[data-layout-mode="fullscreen"] .board-frame,
.play-shell.is-game-fullscreen .board-frame,
.play-shell.is-play-fullscreen .board-frame,
.play-shell[data-layout-mode="fullscreen"] .board-frame {
  width: 100%;
  max-width: 100%;
  height: 100%;
  min-height: 0;
  grid-template-rows: auto minmax(0, 1fr);
  align-self: stretch;
  justify-self: stretch;
  background:
    radial-gradient(circle at 50% 0%, rgba(93, 167, 255, 0.18), transparent 22rem),
    linear-gradient(180deg, rgba(8, 14, 22, 0.98), rgba(6, 10, 18, 0.96));
  box-shadow: 0 32px 90px rgba(0, 0, 0, 0.48);
}

.play-runtime[data-layout-mode="fullscreen"] .board-container,
.play-shell.is-game-fullscreen .board-container,
.play-shell.is-play-fullscreen .board-container,
.play-shell[data-layout-mode="fullscreen"] .board-container {
  width: 100%;
  height: 100%;
  min-height: 0;
  grid-template-rows: minmax(0, 1fr) auto;
  align-content: stretch;
}

.play-runtime[data-layout-mode="fullscreen"] .board-stage,
.play-shell.is-game-fullscreen .board-stage,
.play-shell.is-play-fullscreen .board-stage,
.play-shell[data-layout-mode="fullscreen"] .board-stage {
  width: 100%;
  height: 100%;
  min-height: 0;
  align-content: center;
  justify-items: center;
}

.play-runtime[data-layout-mode="fullscreen"] .board-row,
.play-shell.is-game-fullscreen .board-row,
.play-shell.is-play-fullscreen .board-row,
.play-shell[data-layout-mode="fullscreen"] .board-row {
  grid-template-columns: 24px var(--runtime-board-size) 24px;
  width: calc(var(--runtime-board-size) + 72px);
  max-width: 100%;
  justify-content: center;
}

.play-runtime[data-layout-mode="fullscreen"] .board-coordinates-top,
.play-runtime[data-layout-mode="fullscreen"] .board-coordinates-bottom,
.play-shell.is-game-fullscreen .board-coordinates-top,
.play-shell.is-game-fullscreen .board-coordinates-bottom,
.play-shell.is-play-fullscreen .board-coordinates-top,
.play-shell.is-play-fullscreen .board-coordinates-bottom,
.play-shell[data-layout-mode="fullscreen"] .board-coordinates-top,
.play-shell[data-layout-mode="fullscreen"] .board-coordinates-bottom {
  width: var(--runtime-board-size);
  max-width: var(--runtime-board-size);
}

body.discord-activity-mode .play-shell.is-discord-activity .board-frame {
  width: min(100%, calc(var(--runtime-board-size) + 92px)) !important;
  max-width: 100% !important;
  height: auto;
  max-height: none;
  min-height: 0;
  padding: 8px;
  gap: 6px;
  border-radius: 18px;
  grid-template-rows: auto minmax(0, auto);
  align-self: center;
  justify-self: center;
  overflow: visible;
}

body.discord-activity-mode .play-shell.is-discord-activity .board-topbar {
  gap: 8px;
}

body.discord-activity-mode .play-shell.is-discord-activity .board-topbar h2 {
  font-size: 1rem;
}

body.discord-activity-mode .play-shell.is-discord-activity .board-status-rail {
  gap: 5px;
}

body.discord-activity-mode .play-shell.is-discord-activity .board-status-rail .status-chip,
body.discord-activity-mode .play-shell.is-discord-activity .board-footer,
body.discord-activity-mode .play-shell.is-discord-activity .board-footer-meta {
  font-size: 0.72rem;
}

body.discord-activity-mode .play-shell.is-discord-activity .is-premium-inline-loading {
  position: relative;
}

body.discord-activity-mode .play-shell.is-discord-activity .board-footer.is-premium-inline-loading {
  border-color: rgba(216, 179, 106, 0.38);
  background:
    linear-gradient(180deg, rgba(216, 179, 106, 0.08), rgba(255, 255, 255, 0.025)),
    rgba(255, 255, 255, 0.035);
  box-shadow:
    inset 0 0 0 1px rgba(255, 244, 199, 0.04),
    0 0 18px rgba(216, 179, 106, 0.08);
}

body.discord-activity-mode .play-shell.is-discord-activity .board-footer.is-premium-inline-loading::before,
body.discord-activity-mode .play-shell.is-discord-activity .board-footer.is-premium-inline-loading::after {
  content: "";
  position: absolute;
  top: 50%;
  width: clamp(18px, 5vw, 42px);
  height: 1px;
  pointer-events: none;
  background: linear-gradient(90deg, transparent, rgba(216, 179, 106, 0.82));
  box-shadow: 0 0 10px rgba(216, 179, 106, 0.25);
}

body.discord-activity-mode .play-shell.is-discord-activity .board-footer.is-premium-inline-loading::before {
  left: 10px;
  transform: translateY(-50%);
}

body.discord-activity-mode .play-shell.is-discord-activity .board-footer.is-premium-inline-loading::after {
  right: 10px;
  transform: translateY(-50%) scaleX(-1);
}

body.discord-activity-mode .play-shell.is-discord-activity .board-footer.is-premium-inline-loading .board-footer-copy {
  padding-inline: clamp(18px, 5vw, 42px);
}

body.discord-activity-mode .play-shell.is-discord-activity .board-footer.is-premium-inline-loading .board-footer-copy strong {
  color: #f8efe0;
  text-shadow: 0 0 12px rgba(216, 179, 106, 0.22);
}

body.discord-activity-mode .play-shell.is-discord-activity .board-footer.is-premium-inline-loading .board-footer-copy span::after,
body.discord-activity-mode .play-shell.is-discord-activity .status-meta.is-premium-inline-loading::after {
  content: "...";
  display: inline-block;
  width: 1.25em;
  margin-left: 0.2em;
  overflow: hidden;
  color: #f0c772;
  text-align: left;
  vertical-align: bottom;
  text-shadow: 0 0 10px rgba(216, 179, 106, 0.42);
  animation: discordPremiumInlineDots 1.25s steps(3, end) infinite;
}

body.discord-activity-mode .play-shell.is-discord-activity .status-meta.is-premium-inline-loading {
  border-color: rgba(216, 179, 106, 0.28);
  color: rgba(248, 239, 224, 0.82);
}

body.discord-activity-mode .play-shell.is-discord-activity .board-container,
body.discord-activity-mode .play-shell.is-discord-activity .board-stage {
  width: 100%;
  height: auto;
  min-height: 0;
}

body.discord-activity-mode .play-shell.is-discord-activity .board-stage {
  padding: 6px;
  overflow: visible;
}

body.discord-activity-mode .play-shell.is-discord-activity .board-row {
  grid-template-columns: 18px var(--runtime-board-size) 18px;
  width: calc(var(--runtime-board-size) + 44px);
  max-width: 100%;
}

@keyframes discordPremiumInlineDots {
  0% {
    clip-path: inset(0 66% 0 0);
    opacity: 0.58;
  }
  33% {
    clip-path: inset(0 33% 0 0);
    opacity: 0.78;
  }
  66%,
  100% {
    clip-path: inset(0 0 0 0);
    opacity: 1;
  }
}

@media (prefers-reduced-motion: reduce) {
  body.discord-activity-mode .play-shell.is-discord-activity .board-footer.is-premium-inline-loading .board-footer-copy span::after,
  body.discord-activity-mode .play-shell.is-discord-activity .status-meta.is-premium-inline-loading::after {
    animation: none;
    clip-path: none;
  }
}

body.discord-activity-mode .play-shell.is-discord-activity .board-coordinates-top,
body.discord-activity-mode .play-shell.is-discord-activity .board-coordinates-bottom {
  width: var(--runtime-board-size);
  max-width: var(--runtime-board-size);
}

body.discord-activity-mode .play-shell.is-discord-activity #chess-board {
  width: var(--runtime-board-size) !important;
  max-width: var(--runtime-board-size) !important;
  height: var(--runtime-board-size) !important;
  max-height: var(--runtime-board-size) !important;
}

body.discord-activity-mode .play-shell.is-discord-activity .game-chat-panel {
  display: grid;
  grid-template-rows: auto auto minmax(0, auto) minmax(96px, 1fr) auto;
  grid-template-areas:
    "chat-head"
    "chat-tabs"
    "chat-coach"
    "chat-history"
    "chat-compose";
  min-height: 0 !important;
  height: 100%;
  max-height: 100%;
  margin-top: 0 !important;
  align-content: stretch;
  overflow: hidden;
}

body.discord-activity-mode .play-shell.is-discord-activity .game-chat-panel .section-head {
  gap: 4px;
}

body.discord-activity-mode .play-shell.is-discord-activity .game-chat-panel .play-kicker {
  display: none;
}

body.discord-activity-mode .play-shell.is-discord-activity .game-chat-panel .section-head h2 {
  font-size: 0.95rem;
}

body.discord-activity-mode .play-shell.is-discord-activity .game-chat-panel .chat-tabs {
  gap: 5px;
}

body.discord-activity-mode .play-shell.is-discord-activity .game-chat-panel .chat-tab {
  min-height: 28px;
  padding: 0 8px;
  font-size: 0.72rem;
}

body.discord-activity-mode .play-shell.is-discord-activity .game-chat-history {
  flex: 1 1 auto;
  height: auto;
  max-height: none;
  min-height: 96px;
  padding: 8px;
  gap: 6px;
  border-radius: 12px;
  align-self: stretch;
  overflow-y: auto;
}

body.discord-activity-mode .play-shell.is-discord-activity .game-chat-panel .coach-insight-panel {
  max-height: 96px;
  min-height: 0;
  overflow: auto;
}

body.discord-activity-mode .play-shell.is-discord-activity .player-panel {
  align-self: start;
  flex: 0 0 auto;
  max-height: none;
  overflow: visible;
}

body.discord-activity-mode .play-shell.is-discord-activity .action-panel {
  align-self: end;
}

body.discord-activity-mode .play-shell.is-discord-activity .chat-history li {
  padding: 7px 8px;
  border-radius: 10px;
}

body.discord-activity-mode .play-shell.is-discord-activity .chat-compose {
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 6px;
  margin-top: 4px;
  padding-top: 6px;
  align-self: end;
}

body.discord-activity-mode .play-shell.is-discord-activity .chat-compose input {
  min-height: 34px;
  padding: 0 10px;
  border-radius: 10px;
}

body.discord-activity-mode .play-shell.is-discord-activity .chat-compose .secondary-action {
  min-width: 78px;
  min-height: 34px;
  padding: 0 9px;
  border-radius: 10px;
  font-size: 0.78rem;
}

@media (max-width: 980px) {
  body.discord-activity-mode .play-shell.is-discord-activity {
    overflow: auto;
  }

  body.discord-activity-mode .play-shell.is-discord-activity .play-dashboard {
    overflow: visible;
  }

  body.discord-activity-mode .play-shell.is-discord-activity .play-runtime {
    grid-template-columns: 1fr !important;
    grid-template-areas:
      "center"
      "right"
      "left";
    height: auto;
    min-height: 100%;
    overflow: visible;
  }

  body.discord-activity-mode .play-shell.is-discord-activity .play-center,
  body.discord-activity-mode .play-shell.is-discord-activity .play-left,
  body.discord-activity-mode .play-shell.is-discord-activity .play-right {
    height: auto;
    max-height: none;
    overflow: visible;
  }

  body.discord-activity-mode .play-shell.is-discord-activity {
    --runtime-board-size: min(88vw, 58vh);
  }
}

.layout-debug-panel {
  position: fixed;
  z-index: 2147483647;
  right: 12px;
  bottom: 12px;
  width: min(520px, calc(100vw - 24px));
  max-height: min(72vh, 680px);
  overflow: auto;
  padding: 12px;
  border: 1px solid rgba(124, 226, 165, 0.42);
  border-radius: 12px;
  background: rgba(3, 8, 13, 0.94);
  color: #e9f5ee;
  box-shadow: 0 18px 44px rgba(0, 0, 0, 0.46);
  font: 12px/1.42 var(--font-mono);
  white-space: pre-wrap;
}

.layout-debug-panel strong {
  display: block;
  margin-bottom: 8px;
  color: var(--accent-green);
  font: 700 12px/1.2 var(--font-mono);
}

.launcher-head,
.launcher-actions,
.launcher-form,
.launcher-config-grid,
.launcher-panel {
  display: grid;
  gap: 14px;
}

.launcher-head {
  grid-template-columns: minmax(0, 1fr) minmax(280px, 0.82fr);
  align-items: start;
}

.launcher-mode-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.launcher-mode-card {
  position: relative;
  display: grid;
  gap: 10px;
  padding: 18px 18px 18px 52px;
  border: 1px solid var(--line);
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.03);
  cursor: pointer;
  transition: transform 140ms ease, border-color 140ms ease, background 140ms ease, box-shadow 140ms ease;
}

.launcher-mode-card:hover {
  transform: translateY(-1px);
  border-color: var(--line-strong);
  background: rgba(255, 255, 255, 0.05);
}

.launcher-mode-card input {
  position: absolute;
  top: 18px;
  left: 18px;
  width: 18px;
  height: 18px;
  accent-color: var(--accent);
}

.launcher-mode-card:has(input:checked) {
  border-color: rgba(216, 179, 106, 0.42);
  background: linear-gradient(135deg, rgba(216, 179, 106, 0.12), rgba(93, 167, 255, 0.08));
  box-shadow: 0 0 0 1px rgba(216, 179, 106, 0.12);
}

.launcher-mode-kicker {
  color: var(--accent-blue);
  font-family: var(--font-mono);
  font-size: 0.76rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.launcher-mode-card strong {
  font-size: 1rem;
}

.launcher-mode-card span:last-child,
.launcher-summary-grid span {
  color: var(--muted);
}

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

.launcher-panel {
  padding: 16px 18px;
  border: 1px solid var(--line);
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.03);
}

.launcher-field-grid,
.launcher-summary-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.launcher-panel select {
  width: 100%;
  min-height: 46px;
  padding: 0 14px;
  border: 1px solid rgba(183, 204, 226, 0.14);
  border-radius: 14px;
  background: rgba(5, 10, 18, 0.78);
  color: var(--text);
  font: inherit;
}

.launcher-toggle {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  min-height: 46px;
  padding: 12px 14px;
  border: 1px solid rgba(183, 204, 226, 0.14);
  border-radius: 14px;
  background: rgba(5, 10, 18, 0.78);
}

.launcher-toggle-copy {
  display: grid;
  gap: 4px;
}

.launcher-toggle-title {
  font-weight: 700;
  color: var(--text);
}

.launcher-toggle-subtitle {
  color: var(--muted);
  font-size: 0.82rem;
  line-height: 1.35;
}

.launcher-toggle input {
  width: 20px;
  height: 20px;
  margin: 0;
  accent-color: rgba(216, 179, 106, 0.96);
}

.launcher-panel select:focus-visible,
.launcher-mode-card input:focus-visible,
.launcher-toggle input:focus-visible {
  outline: 2px solid rgba(216, 179, 106, 0.82);
  outline-offset: 2px;
}

.launcher-summary-grid div {
  display: grid;
  gap: 6px;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.03);
}

.launcher-summary-grid strong {
  font-size: 1rem;
}

.board-stage {
  display: grid;
  gap: 10px;
  width: 100%;
  min-width: 0;
  max-width: 100%;
  padding: 16px;
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 24px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.035), rgba(255, 255, 255, 0.015)),
    radial-gradient(circle at 50% 0%, rgba(93, 167, 255, 0.08), transparent 18rem);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.04),
    inset 0 0 0 1px rgba(93, 167, 255, 0.04);
  justify-items: center;
  justify-self: center;
  margin-inline: auto;
  overflow: hidden;
}

.board-container {
  display: grid;
  gap: 14px;
  width: 100%;
  min-width: 0;
  max-width: 100%;
  justify-items: center;
  justify-self: center;
  margin-inline: auto;
  overflow: hidden;
}

.board-topbar {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  min-width: 0;
  flex-wrap: wrap;
}

.board-heading {
  min-width: 0;
}

.board-brand {
  display: flex;
  align-items: center;
  gap: 9px;
  min-width: 0;
  margin-bottom: 6px;
}

.board-brand .logo-wanalike {
  width: 28px;
  height: 28px;
  border-radius: 8px;
}

.board-brand .play-kicker {
  margin: 0;
}

.board-heading h2 {
  margin: 0;
  font-size: clamp(1.3rem, 2.6vw, 1.8rem);
}

.board-status-rail {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, max-content));
  justify-content: end;
  gap: 8px;
  min-width: 0;
  max-width: 100%;
}

.status-chip {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.04);
  color: var(--text);
  font-size: 0.85rem;
  white-space: nowrap;
  box-shadow: var(--shadow-soft);
  max-width: 100%;
}

.status-chip.is-accent {
  background: rgba(216, 179, 106, 0.12);
  border-color: rgba(216, 179, 106, 0.24);
  color: #f8e8bf;
}

.status-chip.is-danger {
  background: rgba(255, 142, 128, 0.12);
  border-color: rgba(255, 142, 128, 0.22);
  color: #ffd6cf;
}

.status-chip[data-kind="turn"] {
  background: rgba(216, 179, 106, 0.12);
  border-color: rgba(216, 179, 106, 0.24);
}

.status-chip[data-kind="alert"] {
  background: rgba(255, 142, 128, 0.12);
  border-color: rgba(255, 142, 128, 0.22);
}

.status-chip[data-kind="move"] {
  font-family: var(--font-mono);
}

.board-row {
  display: grid;
  width: 100%;
  min-width: 0;
  max-width: 100%;
  grid-template-columns: 24px minmax(0, 1fr) 24px;
  gap: 12px;
  align-items: stretch;
  justify-content: center;
  justify-self: center;
  margin-inline: auto;
  overflow: hidden;
}

.board-coordinates {
  display: grid;
  color: var(--muted);
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.board-coordinates-top,
.board-coordinates-bottom {
  grid-template-columns: repeat(8, minmax(0, 1fr));
  width: min(100%, 920px);
  justify-self: center;
  padding: 0;
}

.board-coordinates-side {
  grid-template-rows: repeat(8, minmax(0, 1fr));
  justify-items: center;
  align-items: center;
}

.board-coordinates span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.board {
  display: grid;
  grid-template-columns: repeat(8, minmax(0, 1fr));
  grid-template-rows: repeat(8, minmax(0, 1fr));
  width: 100%;
  min-width: 0;
  max-width: clamp(760px, 80vw, 1520px);
  aspect-ratio: 1 / 1;
  min-height: 280px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 24px;
  overflow: hidden;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.02), rgba(0, 0, 0, 0.04));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.04),
    0 22px 42px rgba(0, 0, 0, 0.26),
    0 0 0 10px rgba(6, 14, 24, 0.22);
  touch-action: manipulation;
  align-self: start;
  justify-self: center;
  margin: 0 auto;
}

.action-stack {
  display: grid;
  gap: 10px;
}

.game-chat-panel {
  display: flex;
  flex-direction: column;
  gap: 10px;
  width: 100%;
  min-height: 360px;
  height: 100%;
  justify-self: stretch;
  align-self: stretch;
}

.game-chat-panel .section-head {
  gap: 8px;
}

.game-chat-panel .play-kicker {
  margin-bottom: 5px;
  font-size: 0.66rem;
  letter-spacing: 0.07em;
}

.game-chat-panel .section-head h2 {
  font-size: 1.08rem;
  line-height: 1.1;
}

.status-panel {
  display: grid;
  gap: 12px;
  padding: 14px 16px;
}

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

.status-item-primary {
  min-height: 0;
}

.status-item-wide {
  grid-column: 1 / -1;
}

.status-item-meta {
  min-height: 0;
}

.history-inline-block {
  display: grid;
  gap: 8px;
  min-width: 0;
}

.section-head-compact h3 {
  margin: 0;
  font-size: 1rem;
}

.move-history-compact {
  max-height: 190px;
  overflow: auto;
  margin: 0;
  padding-right: 4px;
}

.coach-insight-panel {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 12px;
  padding: 12px;
  border: 1px solid rgba(216, 179, 106, 0.18);
  border-radius: 18px;
  background:
    linear-gradient(180deg, rgba(216, 179, 106, 0.12), rgba(216, 179, 106, 0.04)),
    radial-gradient(circle at 0% 0%, rgba(93, 167, 255, 0.12), transparent 9rem);
  overflow: hidden;
}

.coach-message {
  position: relative;
}

.coach-avatar {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  position: relative;
  width: 54px;
  height: 54px;
  border-radius: 18px;
  background:
    radial-gradient(circle at 30% 20%, rgba(110, 198, 255, 0.22), transparent 60%),
    linear-gradient(135deg, rgba(14, 24, 38, 0.96), rgba(24, 18, 42, 0.94));
  box-shadow:
    0 0 0 1px rgba(110, 198, 255, 0.12),
    0 10px 28px rgba(0, 0, 0, 0.28),
    0 0 26px rgba(79, 154, 255, 0.12);
  overflow: hidden;
}

.coach-avatar::after {
  content: "";
  position: absolute;
  inset: -6px;
  border-radius: 22px;
  background: radial-gradient(circle, rgba(93, 167, 255, 0.18), transparent 70%);
  z-index: 0;
  pointer-events: none;
}

.coach-avatar picture,
.coach-avatar-image {
  position: relative;
  z-index: 1;
  width: 100%;
  height: 100%;
}

.coach-avatar picture {
  display: block;
}

.coach-avatar-image {
  display: block;
  object-fit: cover;
  object-position: center;
}

.coach-avatar-fallback {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: none;
  align-items: center;
  justify-content: center;
  font-weight: 900;
  font-size: 1.1rem;
  letter-spacing: 0.08em;
  color: #f8e8bf;
}

.coach-avatar.is-fallback .coach-avatar-image,
.coach-avatar.is-fallback picture {
  display: none;
}

.coach-avatar.is-fallback .coach-avatar-fallback {
  display: inline-flex;
}

.coach-meta {
  display: grid;
  gap: 6px;
  min-width: 0;
}

.coach-insight-head,
.chat-message-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
}

.coach-title-group {
  display: grid;
  gap: 2px;
}

.coach-name {
  font-size: 1rem;
  letter-spacing: 0.01em;
}

.coach-subtitle {
  color: var(--muted);
  font-size: 0.76rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.coach-state {
  display: inline-flex;
  align-items: center;
  min-height: 26px;
  padding: 0 10px;
  border-radius: 999px;
  background: rgba(93, 167, 255, 0.12);
  color: #d6edff;
  font-size: 0.68rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  border: 1px solid rgba(93, 167, 255, 0.16);
}

.coach-state[data-severity="info"] {
  background: rgba(93, 167, 255, 0.12);
  color: #d6edff;
  border-color: rgba(93, 167, 255, 0.18);
}

.coach-state[data-severity="good"] {
  background: rgba(104, 214, 147, 0.14);
  color: #dfffe9;
  border-color: rgba(104, 214, 147, 0.2);
}

.coach-state[data-severity="warning"] {
  background: rgba(255, 189, 89, 0.14);
  color: #ffe8bd;
  border-color: rgba(255, 189, 89, 0.22);
}

.coach-state[data-severity="blunder"] {
  background: rgba(255, 104, 104, 0.16);
  color: #ffe1e1;
  border-color: rgba(255, 104, 104, 0.24);
}

.coach-body {
  margin: 0;
  color: var(--text);
  line-height: 1.48;
}

.square {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
  aspect-ratio: 1 / 1;
  min-width: 0;
  min-height: 0;
  border: none;
  padding: 0;
  font: inherit;
  cursor: pointer;
  transition: transform 120ms ease, filter 120ms ease, box-shadow 120ms ease;
}

.square:hover {
  filter: brightness(1.06);
  box-shadow: inset 0 0 0 999px var(--square-hover);
}

.square:active {
  transform: scale(0.985);
}

.square:focus-visible {
  outline: 2px solid rgba(255, 255, 255, 0.55);
  outline-offset: -2px;
}

.square.is-light {
  background: var(--square-light);
}

.square.is-dark {
  background: var(--square-dark);
}

.square.is-selected {
  box-shadow:
    inset 0 0 0 4px var(--square-selected),
    inset 0 0 40px rgba(216, 179, 106, 0.28);
}

.square.is-last-move {
  box-shadow:
    inset 0 0 0 4px var(--square-last-move),
    inset 0 0 36px rgba(87, 180, 255, 0.26);
}

.square.is-check {
  animation: kingDanger 1.1s ease-in-out infinite alternate;
  box-shadow:
    inset 0 0 0 4px rgba(255, 142, 128, 0.94),
    inset 0 0 42px rgba(178, 40, 32, 0.38);
}

.square.is-legal::after,
.square.is-capture::after {
  content: "";
  position: absolute;
  inset: 50%;
  transform: translate(-50%, -50%);
  border-radius: 999px;
  pointer-events: none;
}

.square.is-legal::after {
  width: 18%;
  height: 18%;
  background: var(--move);
  box-shadow: 0 0 14px rgba(124, 226, 165, 0.56);
  animation: legalPulse 0.9s ease-in-out infinite alternate;
}

.square.is-capture::after {
  width: 76%;
  height: 76%;
  border: 3px solid var(--danger);
  box-shadow: 0 0 18px rgba(255, 142, 128, 0.32);
}

.piece {
  position: relative;
  z-index: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 92%;
  height: 92%;
  font-family: "DejaVu Sans", "Noto Sans Symbols 2", "Segoe UI Symbol", serif;
  font-size: clamp(2.34rem, 5.9vw, 4.28rem);
  line-height: 1;
  user-select: none;
  transition: transform 140ms ease, filter 140ms ease;
  font-variation-settings: "wght" 700;
  -webkit-font-smoothing: antialiased;
  text-rendering: geometricPrecision;
}

.piece.type-p {
  font-size: clamp(1.76rem, 4.45vw, 3.02rem);
}

.piece.type-q,
.piece.type-k {
  font-size: clamp(2.58rem, 6.38vw, 4.68rem);
}

.square:hover .piece {
  transform: translateY(-1px) scale(1.03);
}

.piece.is-white {
  color: #fcfbf6;
  text-shadow:
    0 1px 0 rgba(255, 255, 255, 0.5),
    0 4px 12px rgba(0, 0, 0, 0.32),
    0 0 20px rgba(73, 149, 239, 0.18);
}

.piece.is-black {
  color: #0f131b;
  text-shadow:
    0 1px 0 rgba(255, 255, 255, 0.16),
    0 5px 14px rgba(5, 10, 16, 0.5);
}

.history-panel,
.system-panel,
.product-panel {
  padding: 16px 18px;
  background: rgba(10, 18, 30, 0.76);
}

.player-panel,
.action-panel,
.game-chat-panel,
.capture-panel {
  padding: 14px 16px;
}

.history-panel h2,
.system-panel h2,
.product-panel h2 {
  font-size: 1.15rem;
  color: var(--muted);
  letter-spacing: 0.02em;
}

.play-shell.is-game-view .history-panel,
.play-shell.is-game-view .system-panel,
.play-shell.is-game-view .product-panel {
  opacity: 0.78;
}

#system-nickname-chip {
  font-family: var(--font-mono);
  font-size: 0.78rem;
}

.board-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 14px 16px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.04), rgba(255, 255, 255, 0.02)),
    rgba(255, 255, 255, 0.03);
}

.board-footer-copy {
  display: grid;
  gap: 3px;
}

.board-footer-copy strong {
  font-size: 0.95rem;
}

.board-footer-copy span,
.board-footer-meta {
  color: var(--muted);
  font-size: 0.84rem;
}

.control-card {
  display: grid;
  gap: 14px;
  padding: 18px 20px;
  border-radius: 24px;
  background: var(--panel);
  overflow: hidden;
  min-width: 0;
}

.status-panel .status-stack {
  grid-template-columns: 1fr;
}

.control-card h2 {
  margin: 0;
  font-size: 1.3rem;
}

.system-chip-stack {
  display: grid;
  gap: 10px;
}

.player-stack {
  display: grid;
  gap: 12px;
}

.player-card {
  position: relative;
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 12px;
  min-height: 78px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.03);
  transition: border-color 160ms ease, background 160ms ease, box-shadow 160ms ease, transform 160ms ease;
}

.player-card.is-active {
  background: linear-gradient(135deg, rgba(50, 86, 132, 0.82), rgba(24, 53, 88, 0.76));
  border-color: rgba(93, 167, 255, 0.42);
  box-shadow: 0 0 0 1px rgba(93, 167, 255, 0.18), 0 18px 40px rgba(0, 0, 0, 0.22);
  transform: translateY(-1px);
}

.player-avatar {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  border-radius: 999px;
  font-weight: 800;
  border: 2px solid rgba(255, 255, 255, 0.2);
}

.player-avatar.is-white {
  color: #101216;
  background: #efe3c5;
}

.player-avatar.is-black {
  color: #eef5ff;
  background: #38597b;
}

.player-copy {
  display: grid;
  gap: 4px;
}

.player-copy strong {
  font-size: 1rem;
}

.player-copy span {
  color: var(--muted);
  font-size: 0.84rem;
}

.player-badge {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 0 10px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.05);
  color: var(--muted);
  font-size: 0.75rem;
  white-space: nowrap;
}

.player-card.is-active .player-badge {
  color: #fff5d7;
  background: rgba(216, 179, 106, 0.18);
}

.status-stack,
.capture-groups {
  display: grid;
  gap: 10px;
}

.status-item,
.capture-groups > div {
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.03);
}

.status-item span,
.capture-groups span {
  display: block;
  margin-bottom: 6px;
  font-size: 0.74rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
}

.status-item strong {
  display: inline-flex;
  align-items: center;
  min-height: 2rem;
  padding: 0.32rem 0.58rem;
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.04);
  font-size: 0.92rem;
}

.status-panel .status-item strong {
  width: 100%;
  justify-content: space-between;
}

#turn-indicator[data-side="white"] {
  color: #fff4d9;
  background: rgba(216, 179, 106, 0.14);
  border-color: rgba(216, 179, 106, 0.22);
}

#turn-indicator[data-side="black"] {
  color: #d7e5f5;
  background: rgba(70, 144, 233, 0.14);
  border-color: rgba(70, 144, 233, 0.22);
}

#game-status[data-kind="live"] {
  color: #dff6e8;
  background: rgba(124, 226, 165, 0.1);
  border-color: rgba(124, 226, 165, 0.18);
}

#game-status[data-kind="alert"],
#check-indicator[data-check="true"] {
  color: #ffd2cc;
  background: rgba(255, 142, 128, 0.12);
  border-color: rgba(255, 142, 128, 0.2);
}

#game-status[data-kind="end"] {
  color: #ffe9bd;
  background: rgba(216, 179, 106, 0.12);
  border-color: rgba(216, 179, 106, 0.2);
}

#last-move-indicator,
.history-counter {
  font-family: var(--font-mono);
}

.section-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.history-counter {
  color: var(--accent);
  font-size: 0.82rem;
  white-space: nowrap;
}

.capture-list {
  min-height: 1.8rem;
  color: var(--text);
  font-size: 1.4rem;
  letter-spacing: 0.1em;
}

.move-history {
  margin: 0;
  padding: 0 8px 0 24px;
  display: grid;
  gap: 10px;
  max-height: 420px;
  overflow: auto;
  color: var(--muted);
  scrollbar-gutter: stable;
}

.move-history li {
  position: relative;
  line-height: 1.42;
  word-break: break-word;
  padding: 8px 10px 8px 2px;
  border-radius: 12px;
  transition: background 140ms ease, color 140ms ease;
}

.move-history li.is-latest {
  color: var(--text);
  background: rgba(93, 167, 255, 0.12);
}

.move-history li::marker {
  color: rgba(216, 179, 106, 0.86);
  font-weight: 700;
}

.chat-history {
  max-height: 240px;
}

.game-chat-history {
  display: flex;
  flex-direction: column;
  flex: 0 0 auto;
  height: clamp(220px, 32vh, 360px);
  max-height: clamp(220px, 32vh, 360px);
  min-height: 0;
  overflow-x: hidden;
  overflow-y: auto;
  overscroll-behavior: contain;
  margin: 0;
  padding: 12px;
  gap: 8px;
  border: 1px solid rgba(183, 204, 226, 0.13);
  border-radius: 16px;
  background:
    linear-gradient(180deg, rgba(4, 9, 16, 0.5), rgba(8, 15, 25, 0.34)),
    rgba(255, 255, 255, 0.025);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.035),
    inset 0 -18px 34px rgba(0, 0, 0, 0.08);
}

.game-chat-history::before {
  content: "";
  margin-top: auto;
}

.chat-history li.is-coach {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 10px;
  padding: 12px 14px;
  border: 1px solid rgba(216, 179, 106, 0.16);
  border-radius: 16px;
  background: rgba(216, 179, 106, 0.08);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
}

.chat-message-copy {
  display: grid;
  gap: 8px;
  min-width: 0;
}

.chat-history li.is-coach .chat-message-meta {
  align-items: flex-start;
  justify-content: flex-start;
  gap: 0;
  width: 100%;
}

.chat-history li.is-coach .coach-title-group {
  min-width: 0;
}

.chat-history li.is-coach .coach-name,
.chat-history li.is-coach .coach-subtitle {
  overflow-wrap: anywhere;
}

.chat-message-role {
  display: inline-flex;
  align-items: center;
  min-height: 20px;
  padding: 0 8px;
  border-radius: 999px;
  background: rgba(93, 167, 255, 0.12);
  color: #d5ecff;
  font-size: 0.68rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.chat-message-text {
  min-width: 0;
  line-height: 1.45;
}

.chat-tabs {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.chat-tab {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 34px;
  padding: 0 11px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.04);
  color: var(--muted);
  font: inherit;
  font-size: 0.84rem;
  font-weight: 700;
  cursor: pointer;
}

.chat-tab.is-active {
  color: var(--text);
  border-color: rgba(93, 167, 255, 0.42);
  background: rgba(93, 167, 255, 0.14);
}

.chat-tab-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 22px;
  min-height: 22px;
  padding: 0 6px;
  border-radius: 999px;
  background: rgba(216, 179, 106, 0.16);
  color: var(--accent);
  font-size: 0.72rem;
}

.move-history li.is-self {
  color: var(--text);
  background: rgba(93, 167, 255, 0.1);
}

.move-history li.is-remote {
  color: var(--text);
  background: rgba(255, 255, 255, 0.03);
}

.move-history li.is-system {
  color: #ffe9bd;
  background: rgba(216, 179, 106, 0.1);
}

.chat-compose {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  margin-top: 8px;
  padding-top: 10px;
  border-top: 1px solid rgba(183, 204, 226, 0.1);
}

.chat-compose input {
  min-height: 46px;
  padding: 0 14px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.04);
  color: var(--text);
  font: inherit;
}

.chat-compose input:focus {
  outline: 2px solid rgba(93, 167, 255, 0.32);
  outline-offset: 1px;
  border-color: rgba(93, 167, 255, 0.42);
}

.chat-compose .secondary-action {
  width: auto;
  min-width: 120px;
}

.primary-action {
  width: 100%;
  margin-top: 4px;
  min-height: 48px;
  padding: 14px 22px;
  border: 1px solid transparent;
  border-radius: 999px;
  font: inherit;
  font-weight: 700;
  color: #101216;
  background: linear-gradient(135deg, #d8b36a, #f0c983);
  box-shadow:
    0 10px 24px rgba(216, 179, 106, 0.18),
    inset 0 1px 0 rgba(255, 255, 255, 0.22);
  cursor: pointer;
  transition: transform 160ms ease, filter 160ms ease, box-shadow 160ms ease;
}

.primary-action:hover {
  transform: translateY(-2px);
  filter: brightness(1.04);
}

.secondary-action {
  width: 100%;
  min-height: 46px;
  padding: 14px 20px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.04);
  color: var(--text);
  font: inherit;
  font-weight: 700;
  cursor: pointer;
  transition: transform 160ms ease, border-color 160ms ease, background 160ms ease;
}

.secondary-action:hover {
  transform: translateY(-1px);
  border-color: var(--line-strong);
  background: rgba(255, 255, 255, 0.07);
}

.theme-panel {
  display: grid;
  gap: 10px;
}

.theme-label {
  color: var(--muted);
  font-size: 0.82rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.theme-buttons {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.theme-button {
  min-height: 40px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.04);
  color: var(--text);
  font: inherit;
  cursor: pointer;
  transition: transform 140ms ease, border-color 140ms ease, background 140ms ease, box-shadow 140ms ease;
}

.theme-button:hover {
  transform: translateY(-1px);
  border-color: var(--line-strong);
  background: rgba(255, 255, 255, 0.07);
}

.theme-button.is-active {
  border-color: rgba(216, 179, 106, 0.45);
  background: rgba(216, 179, 106, 0.14);
  box-shadow: 0 0 0 1px rgba(216, 179, 106, 0.12);
}

.theme-button:focus-visible {
  outline: 2px solid rgba(216, 179, 106, 0.9);
  outline-offset: 2px;
}

.promotion-dialog {
  position: fixed;
  inset: 0;
  display: grid;
  place-items: center;
  padding: 24px;
  background: rgba(4, 9, 15, 0.72);
  backdrop-filter: blur(12px);
  z-index: 1000;
  pointer-events: auto;
}

.promotion-panel {
  width: min(420px, 100%);
  max-height: min(560px, calc(100vh - 32px));
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: 28px;
  background:
    radial-gradient(circle at top left, rgba(216, 179, 106, 0.16), transparent 14rem),
    linear-gradient(135deg, rgba(11, 20, 33, 0.96), rgba(9, 17, 29, 0.92));
  box-shadow: var(--shadow);
  pointer-events: auto;
  overflow: auto;
}

.promotion-header {
  display: grid;
  gap: 10px;
}

.promotion-header h2 {
  margin: 0;
  font-size: clamp(1.6rem, 3vw, 2rem);
}

.promotion-copy,
.promotion-hint,
.promotion-option-copy {
  margin: 0;
  color: var(--muted);
  line-height: 1.5;
  font-size: 0.84rem;
}

.promotion-body {
  display: grid;
  gap: 14px;
  margin-top: 18px;
}

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

.promotion-option {
  min-height: 92px;
  border: 1px solid var(--line);
  border-radius: 18px;
  font: inherit;
  color: var(--text);
  background: rgba(255, 255, 255, 0.04);
  cursor: pointer;
  transition: transform 160ms ease, border-color 160ms ease, background 160ms ease, box-shadow 160ms ease;
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 10px;
  padding: 14px 16px;
  text-align: left;
}

.promotion-option:hover {
  transform: translateY(-2px);
  border-color: rgba(216, 179, 106, 0.48);
  background: rgba(216, 179, 106, 0.1);
}

.promotion-option:focus-visible {
  outline: 2px solid rgba(216, 179, 106, 0.9);
  outline-offset: 2px;
  border-color: rgba(216, 179, 106, 0.62);
  box-shadow: 0 0 0 4px rgba(216, 179, 106, 0.14);
}

.promotion-option-symbol {
  font-size: 2rem;
  line-height: 1;
}

.promotion-option-title {
  display: block;
  font-weight: 700;
}

.promotion-option-key {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 28px;
  min-height: 28px;
  padding: 4px 8px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 999px;
  color: var(--accent);
  background: rgba(255, 255, 255, 0.03);
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
}

.promotion-hint kbd {
  display: inline-block;
  min-width: 1.9em;
  margin: 0 4px 0 0;
  padding: 2px 6px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.05);
  color: var(--text);
  font: inherit;
  font-size: 0.9em;
  text-transform: uppercase;
}

.promotion-error {
  margin: 0;
  padding: 12px 14px;
  border: 1px solid rgba(255, 142, 128, 0.24);
  border-radius: 14px;
  color: #ffbeb6;
  background: rgba(160, 32, 32, 0.14);
}

@keyframes legalPulse {
  from { transform: translate(-50%, -50%) scale(0.95); }
  to { transform: translate(-50%, -50%) scale(1.12); }
}

@keyframes kingDanger {
  from { box-shadow: inset 0 0 0 4px rgba(255, 142, 128, 0.84), inset 0 0 28px rgba(178, 40, 32, 0.26); }
  to { box-shadow: inset 0 0 0 4px rgba(255, 142, 128, 1), inset 0 0 46px rgba(178, 40, 32, 0.44); }
}

@media (max-width: 1140px) {
  .launcher-head,
  .launcher-mode-grid,
  .launcher-config-grid {
    grid-template-columns: 1fr;
  }

  .play-shell:not([data-layout-mode="fullscreen"]) .play-runtime {
    grid-template-columns: minmax(210px, 240px) minmax(560px, 740px) minmax(230px, 280px);
  }
}

@media (max-width: 1024px) {
  .play-shell:not([data-layout-mode="fullscreen"]) .play-runtime {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  }

  .board-topbar {
    flex-direction: column;
    align-items: stretch;
  }

  .board-status-rail {
    grid-template-columns: 1fr;
    justify-content: stretch;
  }

  .play-shell:not([data-layout-mode="fullscreen"]) .play-right {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .player-panel,
  .action-panel {
    grid-column: 1 / -1;
  }
}

@media (max-width: 860px) {
  .play-shell:not([data-layout-mode="fullscreen"]) .play-runtime,
  .play-hero-grid,
  .play-shell:not([data-layout-mode="fullscreen"]) .play-right {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 760px) {
  .play-shell:not([data-layout-mode="fullscreen"]) {
    width: min(100%, calc(100% - 16px));
    padding-top: 14px;
    padding-bottom: 28px;
  }

  .play-nav {
    flex-direction: column;
    align-items: stretch;
  }

  .play-nav-links {
    width: 100%;
  }

  .play-nav-links a {
    width: 100%;
    text-align: center;
  }

  .play-command-item {
    flex-direction: column;
    align-items: flex-start;
  }

  .launcher-field-grid,
  .launcher-summary-grid {
    grid-template-columns: 1fr;
  }

  .play-hero,
  .board-frame,
  .control-card {
    padding-left: 18px;
    padding-right: 18px;
    border-radius: 22px;
  }

  .board-stage {
    padding: 12px;
    border-radius: 20px;
  }

  .board-row {
    grid-template-columns: 14px minmax(220px, 1fr) 14px;
    gap: 8px;
  }

  .board-coordinates {
    font-size: 0.7rem;
  }

  .board-footer {
    flex-direction: column;
    align-items: flex-start;
  }

  .play-shell:not([data-layout-mode="fullscreen"]) .play-right {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 480px) {
  .theme-buttons,
  .launcher-mode-grid {
    grid-template-columns: 1fr;
  }

  .play-hero {
    padding-top: 22px;
    padding-bottom: 22px;
  }

  .board-frame {
    padding: 12px;
  }

  .board-coordinates-top,
  .board-coordinates-bottom {
    width: 100%;
  }

  .piece {
    font-size: clamp(1.3rem, 8vw, 2.2rem);
  }

  .status-chip {
    width: 100%;
    justify-content: center;
  }

  .player-card {
    grid-template-columns: auto 1fr;
  }

  .player-badge {
    grid-column: 1 / -1;
    justify-content: center;
  }

  .promotion-dialog {
    padding: 16px;
  }

  .promotion-panel {
    padding: 18px;
    border-radius: 22px;
  }

  .promotion-buttons {
    grid-template-columns: 1fr;
  }

  .promotion-option {
    min-height: 78px;
  }
}

.play-nav-auth {
  margin-left: auto;
}

.play-nav-auth .auth-nav-links {
  display: flex;
  align-items: center;
  gap: 10px;
}

.play-nav-auth .auth-nav-link,
.play-nav-auth .auth-menu-summary,
.play-nav-auth .auth-menu-button,
.play-nav-auth .auth-menu-item {
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 999px;
  color: var(--ink-strong, #f5f7fb);
  background: rgba(11, 18, 29, 0.82);
}

.play-nav-auth .auth-nav-link,
.play-nav-auth .auth-menu-item,
.play-nav-auth .auth-menu-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  min-height: var(--nav-button-height, 40px);
  height: var(--nav-button-height, 40px);
  padding: 0 var(--nav-button-padding-x, 14px);
  line-height: 1;
  white-space: nowrap;
  transition: background 160ms ease, color 160ms ease, box-shadow 160ms ease;
}

.play-nav-auth .auth-nav-link.is-primary {
  color: #111;
  background: linear-gradient(135deg, #f0c983, #d8b36a);
}

.play-nav-auth .auth-menu {
  position: relative;
}

.play-nav-auth .auth-menu-summary {
  display: inline-flex;
  align-items: center;
  min-height: var(--nav-button-height, 40px);
  height: var(--nav-button-height, 40px);
  gap: 10px;
  padding: 4px 12px 4px 8px;
  line-height: 1;
  list-style: none;
  cursor: pointer;
}

.play-nav-auth .auth-menu-summary::-webkit-details-marker {
  display: none;
}

.play-nav-auth .auth-menu-avatar {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  overflow: hidden;
  border-radius: 50%;
  font-weight: 700;
  color: #111;
  background: linear-gradient(135deg, #f0c983, #d8b36a);
}

.play-nav-auth .auth-menu-avatar img {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  object-fit: cover;
}

.play-nav-auth .auth-menu-copy {
  display: grid;
  gap: 2px;
  line-height: 1;
}

.play-nav-auth .auth-menu-copy strong {
  line-height: 1;
}

.play-nav-auth .auth-menu-copy span,
.play-nav-auth .auth-nav-note,
.play-nav-auth .auth-menu-error {
  color: var(--ink-muted, #a7b3c6);
  font-size: 0.76rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.play-nav-auth .auth-menu-panel {
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  z-index: 25;
  display: grid;
  gap: 10px;
  min-width: 210px;
  padding: 14px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 18px;
  background: rgba(9, 14, 24, 0.96);
  box-shadow: 0 18px 48px rgba(0, 0, 0, 0.32);
}

.play-nav-auth .auth-menu-button {
  appearance: none;
  width: 100%;
  font: inherit;
  cursor: pointer;
}

.play-nav-auth .auth-nav-link:hover,
.play-nav-auth .auth-menu-summary:hover,
.play-nav-auth .auth-menu-item:hover,
.play-nav-auth .auth-menu-button:hover {
  color: var(--text);
  background: rgba(255, 255, 255, 0.06);
  box-shadow: 0 0 18px rgba(216, 179, 106, 0.08);
}

@media (max-width: 920px) {
  .play-nav {
    flex-wrap: wrap;
  }

  .play-nav-auth {
    width: 100%;
    margin-left: 0;
  }
}

/* Dropdown layering fix */
.play-shell {
  position: relative;
  isolation: isolate;
}

.play-nav {
  position: relative;
  z-index: 40;
  overflow: visible;
}

.play-nav-auth,
.play-nav-auth .auth-menu,
.play-nav-auth .auth-menu[open],
.play-nav-auth .auth-menu-summary,
.play-nav-auth .auth-menu-panel {
  overflow: visible;
}

.play-nav-auth {
  position: relative;
  z-index: 1;
}

.play-nav-auth .auth-menu {
  z-index: 6;
}

.play-nav-auth .auth-menu[open] {
  z-index: 55;
}

.play-nav-auth .auth-menu-panel {
  min-width: 240px;
  z-index: 60;
}

.play-nav-auth .auth-menu-panel::before {
  content: "";
  position: absolute;
  top: -7px;
  right: 24px;
  width: 14px;
  height: 14px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  border-left: 1px solid rgba(255, 255, 255, 0.08);
  background: inherit;
  transform: rotate(45deg);
}
