:root {
  --bg-0: #0a0a0c;
  --bg-1: #101116;
  --bg-2: #171922;
  --panel: #1e1f27;
  --panel-alt: #232531;
  --line: #333746;
  --line-soft: #272a35;
  --ink: #e0e0e6;
  --ink-soft: #a0a8b8;
  --accent-green: #53ff9a;
  --accent-yellow: #ffd447;
  --accent-pink: #ff4dcb;
  --accent-blue: #4fd6ff;
  --neon-red: #ff3131;
  --neon-cyan: #00ffff;
  --neon-green: #39ff14;
  --neon-purple: #bc13fe;
  --danger: #ff7777;
  --ok: #75ffb4;
  --radius: 14px;
  --shadow: 0 14px 34px rgba(0, 0, 0, 0.55);
  --layout-max-height: 95vh;
  --board-scene-image: url('../assets/board/Board1.png');
  --board-scene-position-x: 35.2%;
  --monitor-left: 30.3%;
  --monitor-top: 33.2%;
  --monitor-width: 38.7%;
  --monitor-height: 19.1%;
  --monitor-feed-inset-left: 0%;
  --monitor-feed-inset-top: 10%;
  --monitor-feed-inset-right: 0%;
  --monitor-feed-inset-bottom: 8%;
  --monitor-feed-line-width: 72ch;
  --monitor-feed-pad-left: 0%;
  --monitor-feed-pad-top: 0%;
  --monitor-feed-pad-right: 0%;
}

* {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

body {
  margin: 0;
  min-height: 100vh;
  height: 100vh;
  font-family: "Inter", "Roboto", "Segoe UI", system-ui, sans-serif;
  color: var(--ink);
  overflow: hidden;
  background:
    radial-gradient(circle at 14% 8%, rgba(255, 77, 203, 0.12), transparent 34%),
    radial-gradient(circle at 88% 16%, rgba(83, 255, 154, 0.12), transparent 32%),
    radial-gradient(circle at 50% 100%, rgba(79, 214, 255, 0.08), transparent 48%),
    linear-gradient(165deg, var(--bg-0) 0%, var(--bg-1) 42%, #0d0f15 100%);
}

#app {
  width: min(1480px, 100%);
  margin: 0 auto;
  height: var(--layout-max-height);
  max-height: var(--layout-max-height);
  padding: 12px;
  animation: ui-fade-in 340ms ease-out;
}

@keyframes ui-fade-in {
  from {
    opacity: 0;
    transform: translateY(8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.ui-shell {
  display: grid;
  gap: 16px;
  height: 100%;
  min-height: 0;
}

.screen-hidden {
  display: none !important;
}

.lobby-container,
.game-container {
  min-height: 0;
  height: 100%;
}

.lobby-container {
  display: grid;
}

.lobby-screen {
  min-height: 0;
  height: 100%;
  display: grid;
  place-items: center;
  padding: 18px;
}

.lobby-landing-inner {
  width: min(760px, 100%);
  text-align: center;
  display: grid;
  gap: 14px;
}

.lobby-title {
  margin: 0;
  font-size: clamp(34px, 7vw, 72px);
  font-weight: 900;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: #e8f5ff;
  text-shadow: 0 0 24px rgba(79, 214, 255, 0.35);
}

.lobby-subtitle {
  margin: 0;
  color: var(--ink-soft);
}

.lobby-play-btn {
  justify-self: center;
  width: min(320px, 100%);
}

.lobby-panel {
  width: min(640px, 100%);
  padding: 18px;
  display: grid;
  gap: 12px;
}

.lobby-panel-title {
  margin: 0;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.lobby-label {
  color: var(--ink-soft);
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.8px;
}

.lobby-input {
  border: 1px solid #3a4054;
  background: #131722;
  color: var(--ink);
  border-radius: 10px;
  min-height: 44px;
  padding: 10px 12px;
}

.lobby-token-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.lobby-token-btn {
  border: 1px solid #34394b;
  border-radius: 10px;
  background: #141825;
  min-height: 74px;
  display: inline-grid;
  place-items: center;
  cursor: pointer;
}

.lobby-token-btn img {
  width: 52px;
  height: 52px;
  object-fit: contain;
}

.lobby-token-btn.selected {
  border-color: var(--accent-green);
  box-shadow: 0 0 0 1px rgba(83, 255, 154, 0.4);
}

.lobby-join-btn {
  width: 100%;
}

.lobby-host-grid {
  width: min(1180px, 100%);
  display: flex;
  align-items: stretch;
  justify-content: center;
  flex-wrap: nowrap;
  gap: 14px;
}

.lobby-host-left,
.lobby-host-right {
  flex: 1 1 0;
  min-width: 300px;
  padding: 14px;
  display: grid;
  align-content: start;
  gap: 10px;
}

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

.lobby-player-row {
  border: 1px solid #34394b;
  border-radius: 10px;
  padding: 8px 10px;
  display: flex;
  align-items: center;
  gap: 10px;
  background: #121622;
}

.lobby-player-row.offline {
  opacity: 0.72;
}

.lobby-player-avatar {
  width: 36px;
  height: 36px;
  background: #000;
}

.lobby-player-label {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}

.lobby-player-name {
  font-weight: 700;
}

.lobby-host-badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  border-radius: 999px;
  border: 1px solid rgba(83, 255, 154, 0.45);
  color: var(--accent-green);
  background: rgba(83, 255, 154, 0.12);
  padding: 2px 8px;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.6px;
  text-transform: uppercase;
}

.lobby-offline-badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  border-radius: 999px;
  border: 1px solid rgba(255, 159, 67, 0.45);
  color: #ffb36b;
  background: rgba(255, 159, 67, 0.15);
  padding: 2px 8px;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.6px;
  text-transform: uppercase;
}

.status-icon {
  width: 16px;
  height: 16px;
  object-fit: contain;
  display: inline-block;
}

.lobby-kick-btn {
  margin-left: auto;
  border: 1px solid rgba(255, 99, 99, 0.45);
  background: rgba(255, 70, 70, 0.15);
  color: #ff7f7f;
  border-radius: 8px;
  min-height: 34px;
  min-width: 52px;
  padding: 6px 10px;
  cursor: pointer;
  font-size: 12px;
  font-weight: 700;
}

.rule-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  min-height: 44px;
  border: 1px solid #34394b;
  border-radius: 10px;
  padding: 8px 10px;
  background: #121622;
}

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

.rule-title {
  font-weight: 700;
}

.rule-help {
  color: var(--ink-dim);
  font-size: 11px;
  line-height: 1.2;
}

.rule-select {
  border: 1px solid #3a4054;
  background: #0f1320;
  color: var(--ink);
  border-radius: 8px;
  min-height: 34px;
  padding: 5px 8px;
}

.rule-row input:disabled,
.rule-row select:disabled {
  opacity: 0.55;
  cursor: not-allowed;
}

.lobby-host-actions {
  width: min(1180px, 100%);
  margin-top: 12px;
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 10px;
}

.lobby-host-actions .center-btn {
  width: min(320px, 100%);
}

.lobby-invite-share {
  margin-top: 12px;
  padding: 10px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 10px;
  background: rgba(8, 10, 16, 0.58);
}

.lobby-invite-label {
  display: block;
  margin-bottom: 6px;
}

.lobby-invite-row {
  display: flex;
  gap: 8px;
  align-items: center;
}

.lobby-invite-input {
  flex: 1 1 auto;
  min-width: 0;
  font-family: "Roboto Mono", "Consolas", monospace;
  font-size: 12px;
}

.lobby-invite-row .ui-btn {
  min-width: 116px;
}

.game-container {
  display: grid;
  position: relative;
  min-height: 0;
}

.connection-badge {
  position: absolute;
  top: 8px;
  right: 10px;
  z-index: 40;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.22);
  background: rgba(11, 15, 22, 0.84);
  color: #c9d5ea;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.8px;
  text-transform: uppercase;
  padding: 4px 10px;
  line-height: 1.2;
  pointer-events: none;
}

.connection-badge[data-tone="good"] {
  border-color: rgba(83, 255, 154, 0.55);
  color: #8bffbc;
}

.connection-badge[data-tone="warn"] {
  border-color: rgba(255, 212, 71, 0.55);
  color: #ffe08a;
}

.connection-badge[data-tone="bad"] {
  border-color: rgba(255, 119, 119, 0.6);
  color: #ff9f9f;
}

.connection-badge[data-tone="local"] {
  border-color: rgba(160, 168, 184, 0.46);
  color: #b6c2d8;
}

.status-pill {
  border-radius: 999px;
  border: 1px solid var(--line);
  background: #171920;
  color: var(--ink-soft);
  padding: 3px 10px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.45px;
  text-transform: uppercase;
}

.status-pill[data-tone="good"] {
  border-color: rgba(83, 255, 154, 0.35);
  color: var(--accent-green);
}

.status-pill[data-tone="warn"] {
  border-color: rgba(255, 212, 71, 0.35);
  color: var(--accent-yellow);
}

.main-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(300px, 350px);
  gap: 12px;
  min-height: 0;
  max-height: 100%;
}

.panel {
  background: linear-gradient(165deg, #1d1f28, #181a21);
  border: 1px solid var(--line-soft);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.panel-header {
  padding: 11px 14px;
  border-bottom: 1px solid var(--line-soft);
  color: var(--ink-soft);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 1px;
  text-transform: uppercase;
}

.board-panel {
  padding: 0;
  display: grid;
  place-items: center;
  min-height: 0;
  position: relative;
  overflow: hidden;
  background: var(--board-scene-image) var(--board-scene-position-x) 48% / cover no-repeat;
  border-color: rgba(255, 255, 255, 0.16);
}

.board-grid {
  display: grid;
  grid-template-columns: repeat(11, minmax(0, 1fr));
  grid-template-rows: repeat(11, minmax(0, 1fr));
  width: min(100%, calc(var(--layout-max-height) - 44px));
  max-height: 100%;
  position: relative;
  overflow: hidden;
  aspect-ratio: 1 / 1;
  border: 0;
  border-radius: 12px;
  isolation: isolate;
  background: transparent;
}

.board-grid::before {
  display: none;
}

.board-grid > * {
  position: relative;
  z-index: 1;
}

.board-calibration-overlay {
  position: absolute;
  inset: 0;
  z-index: 30;
  pointer-events: none;
}

.board-calibration-center-line {
  position: absolute;
  top: 0;
  bottom: 0;
  left: 50%;
  width: 1px;
  transform: translateX(-50%);
  background: repeating-linear-gradient(
    to bottom,
    rgba(83, 255, 154, 0.9) 0 6px,
    rgba(83, 255, 154, 0) 6px 12px
  );
}

.board-calibration-monitor-box {
  position: absolute;
  top: var(--monitor-top);
  left: var(--monitor-left);
  width: var(--monitor-width);
  height: var(--monitor-height);
  border: 1px dashed rgba(255, 84, 84, 0.95);
  box-shadow: inset 0 0 0 1px rgba(255, 84, 84, 0.5);
}

.board-calibration-panel {
  position: absolute;
  left: 12px;
  bottom: 12px;
  width: min(520px, calc(100% - 24px));
  border: 1px solid rgba(83, 255, 154, 0.5);
  border-radius: 12px;
  background: rgba(7, 14, 17, 0.86);
  padding: 14px;
  pointer-events: auto;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.36);
}

.board-calibration-title {
  margin: 0;
  color: #9effd1;
  font-size: 15px;
  font-weight: 800;
  letter-spacing: 0.7px;
  text-transform: uppercase;
}

.board-calibration-help {
  margin: 6px 0 0;
  color: #b8c5d8;
  font-size: 13px;
  line-height: 1.35;
}

.board-calibration-buttons {
  margin-top: 10px;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.board-calibration-buttons .ui-btn {
  min-height: 46px;
  padding: 10px 12px;
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.2px;
}

.board-calibration-readout {
  margin: 10px 0 0;
  color: #d5ebf7;
  font-size: 13px;
  line-height: 1.3;
}

.board-center {
  grid-column: 2 / 11;
  grid-row: 2 / 11;
  margin: 0;
  border: 0;
  border-radius: 10px;
  background: transparent;
  padding: 8px 10px 10px;
  display: grid;
  min-height: 0;
  position: relative;
  overflow: hidden;
}

.auth-gate {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: grid;
  place-items: center;
  padding: clamp(16px, 2vw, 28px);
  opacity: 0;
  pointer-events: none;
  transition: opacity 200ms ease;
  background:
    radial-gradient(1200px 500px at 60% -20%, rgba(255, 177, 66, 0.08), transparent 60%),
    radial-gradient(900px 360px at -8% 108%, rgba(166, 189, 205, 0.08), transparent 60%),
    linear-gradient(180deg, #141414 0%, #0f0f0f 45%, #101216 100%);
}

.auth-gate--visible {
  opacity: 1;
  pointer-events: auto;
}

.auth-gate__noise {
  position: absolute;
  inset: 0;
  background-image:
    repeating-linear-gradient(
      115deg,
      rgba(255, 255, 255, 0.02) 0 2px,
      rgba(0, 0, 0, 0.03) 2px 4px
    );
  mix-blend-mode: soft-light;
  opacity: 0.6;
}

.auth-gate__card {
  position: relative;
  width: min(640px, 100%);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 22px;
  padding: clamp(18px, 2.6vw, 34px);
  background:
    linear-gradient(180deg, rgba(24, 24, 24, 0.94), rgba(12, 12, 12, 0.95)),
    repeating-linear-gradient(
      0deg,
      rgba(255, 255, 255, 0.018) 0 1px,
      rgba(0, 0, 0, 0.03) 1px 3px
    );
  box-shadow:
    0 22px 70px rgba(0, 0, 0, 0.55),
    inset 0 1px 0 rgba(255, 255, 255, 0.07);
}

.auth-gate__kicker {
  margin: 0 0 10px;
  color: #c9c9c9;
  letter-spacing: 0.13em;
  text-transform: uppercase;
  font-size: 12px;
  font-weight: 700;
}

.auth-gate__title {
  margin: 0;
  color: #f5f5f5;
  font-family: "Montserrat", "Oswald", "Arial Black", sans-serif;
  font-size: clamp(28px, 4.2vw, 44px);
  letter-spacing: 0.03em;
  text-transform: uppercase;
}

.auth-gate__copy {
  margin: 12px 0 22px;
  color: #d2d2d2;
  font-size: clamp(14px, 1.8vw, 18px);
  letter-spacing: 0.02em;
}

.auth-gate__discord-btn {
  display: inline-flex;
  justify-content: center;
  align-items: center;
  width: min(420px, 100%);
  min-height: 58px;
  padding: 10px 20px;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.28);
  text-decoration: none;
  text-transform: uppercase;
  font-family: "Montserrat", "Arial Black", sans-serif;
  letter-spacing: 0.09em;
  font-weight: 800;
  color: #0f1013;
  background: linear-gradient(165deg, #e9e9e9 0%, #b8b8b8 100%);
  box-shadow:
    0 12px 28px rgba(0, 0, 0, 0.34),
    inset 0 1px 0 rgba(255, 255, 255, 0.65);
  transition: transform 130ms ease, box-shadow 130ms ease, filter 130ms ease;
}

.auth-gate__discord-btn:hover {
  transform: translateY(-1px);
  filter: brightness(1.02);
  box-shadow:
    0 16px 34px rgba(0, 0, 0, 0.4),
    inset 0 1px 0 rgba(255, 255, 255, 0.7);
}

.auth-gate__discord-btn:active {
  transform: translateY(0);
}

.auth-gate__divider {
  width: min(420px, 100%);
  height: 1px;
  margin: 14px 0 12px;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.35), transparent);
}

.auth-gate__guest-btn {
  display: inline-flex;
  justify-content: center;
  align-items: center;
  width: min(420px, 100%);
  min-height: 50px;
  padding: 8px 14px;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.22);
  text-decoration: none;
  text-transform: uppercase;
  font-family: "Montserrat", "Arial Black", sans-serif;
  letter-spacing: 0.08em;
  font-weight: 700;
  color: #d5d5d5;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.1), rgba(255, 255, 255, 0.04));
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.3);
  transition: transform 120ms ease, filter 120ms ease;
}

.auth-gate__guest-btn:hover {
  transform: translateY(-1px);
  filter: brightness(1.04);
}

.auth-gate__guest-btn:active {
  transform: translateY(0);
}

.auth-gate__guest-note {
  width: min(420px, 100%);
  margin: 10px 0 0;
  color: #a9a9a9;
  font-size: 12px;
  line-height: 1.35;
}

.auth-gate__status {
  margin: 16px 0 0;
  color: #bfbfbf;
  font-size: 13px;
  letter-spacing: 0.02em;
}

.board-center::before {
  display: none;
}

.center-dashboard {
  min-height: 100%;
  position: relative;
  z-index: 2;
}

.center-decks {
  display: none !important;
}

.center-deck-card {
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  display: inline-grid;
  place-items: center;
  min-height: 64px;
  padding: 0;
  overflow: hidden;
}

.center-deck-card img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.center-deck-fallback {
  font-size: 12px;
  font-weight: 700;
  color: var(--ink-soft);
  text-align: center;
}

.center-dice {
  position: absolute;
  left: 50%;
  bottom: 104px;
  transform: translateX(-50%);
  display: grid;
  grid-template-columns: repeat(2, minmax(64px, 94px));
  gap: 10px;
  justify-content: center;
  z-index: 6;
  pointer-events: none;
}

.center-dice.is-hidden {
  display: none;
}

.center-actions {
  position: absolute;
  left: 50%;
  bottom: 32px;
  transform: translateX(-50%);
  width: min(420px, calc(100% - 40px));
  display: grid;
  gap: 8px;
  justify-items: center;
  z-index: 7;
}

.center-btn {
  width: min(360px, 100%);
  border: 1px solid #3a4054;
  background: linear-gradient(165deg, #272b39, #1d212c);
  color: var(--ink);
  border-radius: 10px;
  padding: 12px 14px;
  font-size: 14px;
  font-weight: 900;
  letter-spacing: 0.6px;
  text-transform: uppercase;
  cursor: pointer;
  transition: border-color 120ms ease, transform 120ms ease, box-shadow 120ms ease;
  min-height: 44px;
  min-width: 44px;
}

.center-btn:hover {
  border-color: rgba(79, 214, 255, 0.65);
  transform: translateY(-1px);
  box-shadow: 0 8px 18px rgba(0, 0, 0, 0.38);
}

.center-btn.primary {
  border-color: rgba(83, 255, 154, 0.65);
  color: #07120a;
  background: linear-gradient(165deg, #74ffb2, #34e786);
}

.center-btn.warn {
  border-color: rgba(255, 212, 71, 0.65);
  color: #1d1600;
  background: linear-gradient(165deg, #ffe07c, #ffcc37);
}

.phase-info {
  margin: 0;
  color: var(--ink-soft);
  font-size: 12px;
  text-align: center;
}

.spectator-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
}

.property-action-row {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  width: min(420px, 100%);
}

.center-feed-shell {
  position: absolute;
  top: var(--monitor-top);
  left: var(--monitor-left);
  width: var(--monitor-width);
  height: var(--monitor-height);
  min-height: 0;
  max-height: none;
  border: 0;
  border-radius: 2px;
  background: transparent;
  overflow: hidden;
  backdrop-filter: none;
  display: block;
  z-index: 5;
}

#event-screen {
  position: absolute;
  top: var(--monitor-feed-inset-top);
  left: var(--monitor-feed-inset-left);
  right: var(--monitor-feed-inset-right);
  bottom: var(--monitor-feed-inset-bottom);
  box-sizing: border-box !important;
  z-index: 1;
  background: transparent;
  background-color: transparent;
  text-align: left;
  overflow-y: auto;
  overflow-x: hidden;
  padding-top: var(--monitor-feed-pad-top, 0%);
  padding-left: var(--monitor-feed-pad-left, 0%);
  padding-right: var(--monitor-feed-pad-right, 0%);
  max-height: none;
  scrollbar-width: thin;
  scrollbar-color: rgba(79, 213, 255, 0.95) transparent;
}

#event-screen.duel-active .center-feed-list {
  opacity: 0.28;
  filter: blur(0.8px);
}

.monitor-robbery-duel {
  position: absolute;
  inset: 0;
  z-index: 9;
  display: grid;
  place-items: center;
  pointer-events: none;
  padding: 10px;
}

.monitor-robbery-card {
  width: min(98%, 420px);
  max-height: 96%;
  overflow-y: auto;
  border: 1px solid rgba(98, 214, 255, 0.62);
  border-radius: 10px;
  background:
    linear-gradient(180deg, rgba(7, 13, 26, 0.93), rgba(4, 10, 20, 0.94));
  box-shadow:
    0 12px 30px rgba(0, 0, 0, 0.52),
    0 0 0 1px rgba(80, 211, 255, 0.22) inset;
  padding: 8px;
  pointer-events: auto;
}

.monitor-robbery-title {
  margin: 0;
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 0.08em;
  color: #d6f4ff;
  text-transform: uppercase;
}

.monitor-robbery-subtitle {
  margin: 5px 0 0;
  font-size: 10px;
  line-height: 1.3;
  color: #9fc7da;
}

.monitor-robbery-choices {
  margin-top: 8px;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 6px;
}

.monitor-robbery-choice {
  min-height: 26px;
  border-radius: 8px;
  border: 1px solid rgba(111, 190, 214, 0.44);
  background: linear-gradient(170deg, #1e293f, #121a2b);
  color: #e4edf9;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.01em;
  text-transform: uppercase;
  cursor: pointer;
  transition: transform 120ms ease, border-color 120ms ease, filter 120ms ease;
}

.monitor-robbery-choice:hover:not(:disabled) {
  transform: translateY(-1px);
  border-color: rgba(103, 233, 255, 0.78);
  filter: brightness(1.06);
}

.monitor-robbery-choice.selected {
  border-color: rgba(83, 255, 154, 0.82);
  box-shadow: 0 0 0 1px rgba(83, 255, 154, 0.38) inset;
}

.monitor-robbery-choice:disabled {
  opacity: 0.58;
  cursor: default;
}

.monitor-robbery-status {
  margin: 6px 0 0;
  font-size: 10px;
  color: #c7dfed;
}

.center-feed-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 10px;
  align-content: start;
  justify-items: stretch;
  width: 100%;
  max-width: none;
  overflow: visible;
  height: auto;
  min-height: 0;
  font-family: "Roboto", "Montserrat", "Arial", sans-serif;
}

#event-screen::-webkit-scrollbar {
  width: 4px;
  height: 4px;
}

#event-screen::-webkit-scrollbar-track {
  background: transparent;
  border-radius: 999px;
}

#event-screen::-webkit-scrollbar-thumb {
  background: linear-gradient(180deg, rgba(87, 226, 255, 0.98), rgba(0, 126, 255, 0.98));
  border-radius: 999px;
  box-shadow: 0 0 10px rgba(87, 226, 255, 0.58);
}

#event-screen::-webkit-scrollbar-button {
  display: none;
  width: 0;
  height: 0;
}

.center-feed-item {
  border: 0;
  border-radius: 0;
  padding: 0;
  background: transparent;
  width: 100%;
  transition: opacity 140ms ease;
}

.center-feed-item.is-latest {
  opacity: 1 !important;
}

.afk-countdown-item .feed-line {
  color: #ffe38f;
  font-weight: 700;
}

.center-feed-top {
  display: flex;
  justify-content: flex-start;
  align-items: center;
  gap: 8px;
  margin-bottom: 2px;
}

.event-type {
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.3px;
  text-transform: uppercase;
  border-radius: 0;
  padding: 0;
  border: 0;
  background: transparent;
  color: #9dffd4;
  text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.8);
}

.center-feed-top small {
  color: #ffffff;
  font-weight: 600;
  text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.8);
}

.feed-line {
  margin: 0;
  color: #ffffff;
  font-size: 12px;
  line-height: 1.35;
  font-weight: 600;
  text-align: center;
  white-space: normal;
  overflow-wrap: anywhere;
  word-break: break-word;
  max-width: none;
  text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.8);
}

.feed-line.is-single-line {
  text-align: center;
}

.feed-line.is-wrapped-line {
  text-align: center;
}

/* Calibration hard override: remove clipping/size caps from feed wrapper chain. */
.board-panel.calibration-unlocked,
.board-panel.calibration-unlocked .board-grid,
.board-panel.calibration-unlocked .board-center,
.board-panel.calibration-unlocked .center-dashboard,
.board-panel.calibration-unlocked .center-feed-shell {
  overflow: visible !important;
  max-width: none !important;
  max-height: none !important;
}

.board-panel.calibration-unlocked #event-screen {
  max-width: none !important;
  max-height: none !important;
  overflow-x: hidden !important;
  overflow-y: auto !important;
}

.feed-line.is-typing::after {
  content: '▌';
  margin-left: 2px;
  color: rgba(255, 255, 255, 0.92);
  animation: caret-blink 740ms step-end infinite;
}

/* Typed-monitor overrides */
.center-feed-list {
  font-family: "Roboto Mono", "Share Tech Mono", "Consolas", "Courier New", monospace;
}

.feed-line {
  letter-spacing: 0.01em;
}

.feed-line.is-typing::after {
  content: '|';
}

@keyframes caret-blink {
  0%,
  45% {
    opacity: 1;
  }
  46%,
  100% {
    opacity: 0;
  }
}

.waiting-turn {
  width: min(420px, 100%);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 8px 10px;
}

.waiting-turn-avatar {
  width: 36px;
  height: 36px;
  background: #000;
}

.waiting-turn-text {
  margin: 0;
  color: var(--ink-soft);
  font-size: 15px;
  font-weight: 700;
  letter-spacing: 0.2px;
}

.tile {
  border-radius: 4px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(25, 25, 30, 0.85);
  backdrop-filter: blur(12px);
  box-shadow: inset 0 0 10px rgba(255, 255, 255, 0.05);
  color: var(--ink);
  position: relative;
  padding: 10px 3px clamp(24px, 2.7vw, 36px) 3px;
  text-align: left;
  display: grid;
  align-content: space-between;
  gap: 2px;
  cursor: pointer;
  font-size: 10px;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  overflow: hidden;
}

.tile.owned {
  position: relative;
}

.property-color-band {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 6px;
  border-radius: 0;
  background: var(--group-color, transparent);
  z-index: 1;
}

.tile.top-edge {
  padding-top: 10px;
}

.tile.right-edge {
  padding-right: 10px;
}

.tile.bottom-edge {
  padding-bottom: clamp(30px, 3vw, 42px);
}

.tile.left-edge {
  padding-left: 10px;
}

.tile.top-edge .property-color-band {
  top: 0;
  left: 0;
  right: 0;
  height: 6px;
  width: auto;
}

.tile.right-edge .property-color-band {
  top: 0;
  right: 0;
  bottom: 0;
  left: auto;
  width: 6px;
  height: auto;
}

.tile.bottom-edge .property-color-band {
  top: auto;
  right: 0;
  bottom: 0;
  left: 0;
  height: 6px;
  width: auto;
}

.tile.left-edge .property-color-band {
  top: 0;
  right: auto;
  bottom: 0;
  left: 0;
  width: 6px;
  height: auto;
}

.tile.owned {
  border-color: var(--owner-color, #2f3340);
}

.tile.owned .property-color-band {
  background: var(--owner-color, var(--group-color, transparent));
}

.tile:hover {
  transform: scale(1.02);
  z-index: 10;
  box-shadow: 0 0 15px rgba(0, 255, 255, 0.3);
}

.tile.owned:hover {
  border-color: var(--owner-color, #2f3340);
}

.tile.active {
  border-color: var(--accent-green);
  box-shadow: 0 0 0 1px rgba(83, 255, 154, 0.55), 0 0 18px rgba(83, 255, 154, 0.22);
  z-index: 2;
}

.tile.owner-p1 { --owner-color: #ef4444; box-shadow: 0 0 0 1px rgba(239, 68, 68, 0.35), 0 0 11px rgba(239, 68, 68, 0.18); }
.tile.owner-p2 { --owner-color: #0ea5e9; box-shadow: 0 0 0 1px rgba(14, 165, 233, 0.35), 0 0 11px rgba(14, 165, 233, 0.18); }
.tile.owner-p3 { --owner-color: #16a34a; box-shadow: 0 0 0 1px rgba(22, 163, 74, 0.35), 0 0 11px rgba(22, 163, 74, 0.18); }
.tile.owner-p4 { --owner-color: #f59e0b; box-shadow: 0 0 0 1px rgba(245, 158, 11, 0.35), 0 0 11px rgba(245, 158, 11, 0.18); }
.tile.owner-p5 { --owner-color: #8b5cf6; box-shadow: 0 0 0 1px rgba(139, 92, 246, 0.35), 0 0 11px rgba(139, 92, 246, 0.18); }
.tile.owner-p6 { --owner-color: #ec4899; box-shadow: 0 0 0 1px rgba(236, 72, 153, 0.35), 0 0 11px rgba(236, 72, 153, 0.18); }
.tile.owner-p7 { --owner-color: #22d3ee; box-shadow: 0 0 0 1px rgba(34, 211, 238, 0.35), 0 0 11px rgba(34, 211, 238, 0.18); }
.tile.owner-p8 { --owner-color: #facc15; box-shadow: 0 0 0 1px rgba(250, 204, 21, 0.35), 0 0 11px rgba(250, 204, 21, 0.18); }

.tile-price {
  font-size: 9px;
  color: #dbe3f1;
  position: absolute;
  top: 8px;
  left: 4px;
  z-index: 4;
  font-weight: 700;
  text-shadow: 0 0 6px rgba(0, 0, 0, 0.8);
  background: rgba(0, 0, 0, 0.36);
  border-radius: 3px;
  padding: 1px 3px;
}

.tile-name {
  display: block;
  font-weight: 700;
  line-height: 1.15;
  position: absolute;
  left: 50%;
  bottom: 4px;
  transform: translateX(-50%);
  z-index: 4;
  width: max-content;
  max-width: calc(100% - 8px);
  padding: 1px 3px;
  border-radius: 3px;
  background: rgba(0, 0, 0, 0.36);
  text-align: center;
  overflow-wrap: anywhere;
  word-break: break-word;
  hyphens: auto;
}

.tile.has-tile-art .tile-name {
  display: none;
}

.tile.color-BROWN .tile-name,
.tile.color-ORANGE .tile-name,
.tile.color-RED .tile-name,
.tile.color-YELLOW .tile-name {
  text-shadow: 0 0 6px rgba(255, 49, 49, 0.4);
}

.tile.color-LIGHT_BLUE .tile-name,
.tile.color-TRANSIT .tile-name,
.tile.color-UTILITY .tile-name {
  text-shadow: 0 0 6px rgba(0, 255, 255, 0.45);
}

.tile.color-GREEN .tile-name {
  text-shadow: 0 0 6px rgba(57, 255, 20, 0.45);
}

.tile.color-PINK .tile-name,
.tile.color-DARK_BLUE .tile-name {
  text-shadow: 0 0 6px rgba(188, 19, 254, 0.45);
}

.tile-icon {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 0;
  opacity: 1;
  overflow: hidden;
}

.tile-icon img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
}

.tile-icon img.tile-art-img {
  position: absolute;
  top: 0;
  left: 0;
  z-index: 1;
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: brightness(1.2) drop-shadow(0 0 5px rgba(255, 255, 255, 0.2));
}

.tile.has-tile-art::after {
  content: '';
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background: linear-gradient(180deg, rgba(0, 0, 0, 0.32) 0%, rgba(0, 0, 0, 0.48) 100%);
}

.tile.color-BROWN { --group-color: #8b5a2b; }
.tile.color-LIGHT_BLUE { --group-color: #7dd3fc; }
.tile.color-PINK { --group-color: #f472b6; }
.tile.color-ORANGE { --group-color: #fb923c; }
.tile.color-RED { --group-color: #ef4444; }
.tile.color-YELLOW { --group-color: #facc15; }
.tile.color-GREEN { --group-color: #22c55e; }
.tile.color-DARK_BLUE { --group-color: #1d4ed8; }
.tile.color-TRANSIT { --group-color: #6b7280; }
.tile.color-UTILITY { --group-color: #38bdf8; }

.active-turn-glow {
  box-shadow: 0 0 20px var(--player-color), inset 0 0 10px var(--player-color);
  border: 2px solid var(--player-color);
  z-index: 100;
}

.player-card.active-turn-glow {
  position: relative;
}

.token-container {
  position: absolute;
  inset: 14px 2px 16px 2px;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-evenly;
  align-content: center;
  align-items: center;
  gap: 2px;
  height: 100%;
  pointer-events: none;
  z-index: 6;
  overflow: hidden;
}

.house-container {
  position: absolute;
  z-index: 5;
  width: clamp(20px, 40%, 50px);
  height: clamp(20px, 40%, 50px);
  pointer-events: none;
  display: grid;
  place-items: center;
}

.tile.top-edge .house-container {
  left: 50%;
  bottom: 14px;
  transform: translateX(-50%);
}

.tile.right-edge .house-container {
  right: 8px;
  top: 50%;
  transform: translateY(-50%);
}

.tile.bottom-edge .house-container {
  left: 50%;
  top: 8px;
  transform: translateX(-50%);
}

.tile.left-edge .house-container {
  left: 8px;
  top: 50%;
  transform: translateY(-50%);
}

.house-level {
  width: 100%;
  height: 100%;
  display: grid;
  place-items: center;
}

.house-level-image {
  width: 100%;
  height: 100%;
  object-fit: contain;
  filter: drop-shadow(0 2px 5px rgba(0, 0, 0, 0.52));
}

.house-level-fallback {
  font-size: 9px;
  font-weight: 800;
  color: #dcfce7;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.86);
}

.tile.has-tile-art .token-container {
  inset: 14px 2px 2px 2px;
}

.board-token {
  width: 44px;
  height: 44px;
  overflow: hidden;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  z-index: 7;
  background: transparent;
  border: 0;
  box-shadow: none;
  border-radius: 0;
  max-width: 45%;
  max-height: 45%;
}

.board-token-image {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
  max-width: 100%;
  max-height: 100%;
  transform: scale(1.7);
  transform-origin: center;
}

.board-token-fallback {
  width: 100%;
  height: 100%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #e5e7eb;
  font-size: 14px;
  font-weight: 900;
  background: transparent;
  border: 0;
  box-shadow: none;
  border-radius: 0;
}

.token-container[data-count="1"] .board-token {
  max-width: 80%;
  max-height: 80%;
}

.sidebar {
  display: grid;
  grid-template-rows: repeat(2, minmax(0, 1fr));
  gap: 12px;
  min-height: 0;
  overflow: hidden;
}

.sidebar .panel {
  min-height: 0;
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
}

.section-body {
  padding: 14px;
  display: grid;
  gap: 12px;
  min-height: 0;
}

.player-list {
  display: grid;
  gap: 9px;
  overflow-y: auto;
  min-height: 0;
}

.sidebar-action-row {
  display: flex;
  justify-content: stretch;
}

.sidebar-action-row .ui-btn {
  width: 100%;
}

#btn-restart-match {
  display: none !important;
}

.my-properties-owner {
  color: var(--ink-soft);
  font-size: 12px;
}

.my-properties-list {
  display: grid;
  gap: 8px;
  max-height: none;
  overflow-y: auto;
  padding-right: 2px;
  min-height: 0;
}

.property-link {
  border: 1px solid #3a4054;
  background: #171b24;
  color: var(--ink);
  border-radius: 9px;
  padding: 8px 9px;
  font-size: 12px;
  font-weight: 700;
  text-align: left;
  cursor: pointer;
  min-height: 44px;
  min-width: 44px;
}

.property-link:hover {
  border-color: rgba(79, 214, 255, 0.65);
}

.player-card {
  border: 1px solid #343949;
  border-radius: 10px;
  background: linear-gradient(160deg, #1e212a, #181a21);
  padding: 9px 10px;
}

.player-card.current {
  border-color: rgba(79, 214, 255, 0.65);
  box-shadow: 0 0 0 1px rgba(79, 214, 255, 0.24);
}

.player-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
}

.player-top-left {
  display: flex;
  align-items: center;
  gap: 8px;
}

.player-name-row {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.player-id {
  font-size: 11px;
  color: var(--ink-soft);
}

.player-host-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  border-radius: 999px;
  border: 1px solid rgba(83, 255, 154, 0.45);
  color: var(--accent-green);
  background: rgba(83, 255, 154, 0.12);
  padding: 2px 8px;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.5px;
  text-transform: uppercase;
}

.avatar-wrap {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  display: inline-grid;
  place-items: center;
  background: #000000;
  color: #06080c;
  font-size: 11px;
  font-weight: 800;
  overflow: hidden;
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.14);
}

.avatar-wrap img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  transform: scale(1.6);
  transform-origin: center;
}

.player-stat-row {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 7px;
  color: var(--ink-soft);
  font-size: 12px;
}

.die {
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  aspect-ratio: 1 / 1;
  display: grid;
  place-items: center;
  color: var(--accent-yellow);
  font-size: 28px;
  font-weight: 900;
}

.die.rolling {
  animation: die-pulse 190ms ease-in-out infinite alternate;
}

@keyframes die-pulse {
  from {
    transform: scale(1);
    box-shadow: 0 0 0 rgba(255, 77, 203, 0);
  }
  to {
    transform: scale(1.04);
    box-shadow: 0 0 16px rgba(255, 77, 203, 0.36);
  }
}

button.ui-btn {
  border: 1px solid #3a4054;
  background: linear-gradient(165deg, #272b39, #1d212c);
  color: var(--ink);
  border-radius: 9px;
  padding: 9px 11px;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.55px;
  text-transform: uppercase;
  cursor: pointer;
  transition: border-color 120ms ease, transform 120ms ease, box-shadow 120ms ease;
  min-height: 44px;
  min-width: 44px;
}

button.ui-btn.icon-btn {
  width: 44px;
  height: 44px;
  min-height: 44px;
  min-width: 44px;
  padding: 0;
  display: grid;
  place-items: center;
  font-size: 24px;
  line-height: 1;
}

button.ui-btn:hover {
  border-color: rgba(79, 214, 255, 0.65);
  transform: translateY(-1px);
  box-shadow: 0 6px 14px rgba(0, 0, 0, 0.35);
}

button.ui-btn.primary {
  border-color: rgba(83, 255, 154, 0.65);
  color: #07120a;
  background: linear-gradient(165deg, #74ffb2, #34e786);
}

button.ui-btn.warn {
  border-color: rgba(255, 212, 71, 0.65);
  color: #1d1600;
  background: linear-gradient(165deg, #ffe07c, #ffcc37);
}

button:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none !important;
  box-shadow: none !important;
}

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

select,
input[type="number"] {
  border: 1px solid #383e50;
  border-radius: 8px;
  background: #1a1d27;
  color: var(--ink);
  padding: 8px 9px;
  font-size: 12px;
}

.kv-grid {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 6px 10px;
  font-size: 12px;
}

.notice {
  min-height: 20px;
  font-size: 12px;
  color: var(--ink-soft);
}

.notice.good {
  color: var(--ok);
}

.notice.bad {
  color: var(--danger);
}

.modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 80;
  background: rgba(4, 5, 8, 0.72);
  backdrop-filter: blur(2px);
  display: grid;
  place-items: center;
  padding: 16px;
}

.modal-card {
  width: min(960px, 96vw);
  border-radius: 14px;
  border: 1px solid #394055;
  background: linear-gradient(165deg, #1d202b, #141721);
  box-shadow: 0 24px 42px rgba(0, 0, 0, 0.6);
  padding: 16px;
}

.modal-header h3 {
  margin: 0;
  text-transform: uppercase;
  letter-spacing: 0.9px;
}

.modal-header-split {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 10px;
}

.modal-subtitle {
  margin: 8px 0 14px;
  color: var(--ink-soft);
}

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

.auction-layout {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 14px;
  margin-top: 10px;
}

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

.auction-stat {
  border: 1px solid #34384b;
  border-radius: 10px;
  padding: 8px;
  background: #151922;
  display: grid;
  gap: 4px;
}

.auction-timer-track {
  margin-top: 10px;
  height: 10px;
  border-radius: 999px;
  background: #10131a;
  border: 1px solid #2f3444;
  overflow: hidden;
}

.auction-timer-bar {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, var(--accent-pink), var(--accent-yellow));
}

.auction-controls {
  margin-top: 10px;
  display: grid;
  gap: 8px;
}

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

.auction-feed-shell {
  margin-top: 10px;
  border: 1px solid #34384b;
  border-radius: 10px;
  background: #151922;
  padding: 8px;
}

.auction-feed-shell h4,
.auction-right h4 {
  margin: 0 0 8px;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.6px;
}

.auction-feed-list {
  list-style: none;
  margin: 0;
  padding: 0;
  max-height: 126px;
  overflow: auto;
  display: grid;
  gap: 5px;
  font-family: "Fira Code", "Consolas", "Courier New", monospace;
  font-size: 12px;
}

.auction-feed-item {
  border: 1px solid #34384b;
  border-radius: 7px;
  padding: 5px 6px;
  background: #121621;
}

.auction-right {
  border: 1px solid #34384b;
  border-radius: 10px;
  background: #151922;
  padding: 10px;
}

.property-layout {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-top: 10px;
}

.property-left,
.property-right {
  border: 1px solid #34384b;
  border-radius: 10px;
  background: #151922;
  padding: 10px;
}

.property-left h4,
.property-right h4 {
  margin: 0 0 8px;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.6px;
}

.property-actions {
  margin-top: 12px;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.tile-tooltip {
  position: fixed;
  z-index: 90;
  width: min(280px, calc(100vw - 24px));
  border: 1px solid #394055;
  border-radius: 10px;
  background: linear-gradient(165deg, #1f2430, #161922);
  box-shadow: 0 16px 30px rgba(0, 0, 0, 0.55);
  padding: 10px;
}

.tile-tooltip h4 {
  margin: 0 0 8px;
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 0.6px;
}

.tooltip-grid {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 4px 8px;
  font-size: 12px;
}

@media (max-width: 1180px) {
  body {
    overflow: hidden;
  }

  #app {
    padding: 10px;
  }

  .main-layout {
    grid-template-columns: 1fr;
    grid-template-rows: minmax(0, 1fr) minmax(0, 0.72fr);
  }

  .lobby-host-grid {
    flex-direction: column;
  }

  .board-grid {
    width: min(100%, 64vh);
  }
}

@media (max-width: 768px) {
  #app {
    padding: 10px;
  }

  .ui-shell {
    gap: 12px;
  }

  .lobby-screen {
    padding: 10px;
  }

  .lobby-token-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 8px;
  }

  .lobby-token-btn {
    min-height: 64px;
  }

  .lobby-token-btn img {
    width: 44px;
    height: 44px;
  }

  .lobby-host-actions {
    justify-content: stretch;
  }

  .lobby-host-actions .center-btn {
    width: 100%;
  }

  .lobby-invite-row {
    flex-direction: column;
    align-items: stretch;
  }

  .lobby-invite-row .ui-btn {
    width: 100%;
  }

  .connection-badge {
    top: 6px;
    right: 8px;
    font-size: 9px;
    padding: 3px 8px;
  }

  .section-body {
    padding: 12px;
    gap: 10px;
  }

  .inline-controls {
    gap: 10px;
  }

  .center-dice {
    bottom: 86px;
    grid-template-columns: repeat(2, minmax(58px, 78px));
  }

  .center-feed-shell {
    --monitor-left: 16%;
    --monitor-top: 28%;
    --monitor-width: 68%;
    --monitor-height: 33%;
    padding: 10px 12px 10px 16px;
  }

  .center-btn {
    width: 100%;
    font-size: 13px;
  }

  .center-actions {
    width: min(360px, calc(100% - 24px));
    bottom: 16px;
  }

  .property-action-row {
    grid-template-columns: 1fr;
  }

  .tile {
    font-size: 9px;
  }

  .auction-layout {
    grid-template-columns: 1fr;
  }

  .resolve-actions {
    grid-template-columns: 1fr;
  }

  .property-layout {
    grid-template-columns: 1fr;
  }

  .property-actions {
    grid-template-columns: 1fr;
    gap: 10px;
    position: sticky;
    bottom: 0;
    padding-top: 10px;
    background: linear-gradient(180deg, rgba(20, 23, 33, 0), rgba(20, 23, 33, 0.95) 22%);
  }

  .my-properties-list {
    max-height: 36vh;
  }

  #property-modal {
    padding: 0;
    place-items: end stretch;
    align-items: end;
    justify-items: stretch;
  }

  .property-card {
    width: 100%;
    max-height: 92vh;
    overflow-y: auto;
    border-radius: 18px 18px 0 0;
    border-left: 0;
    border-right: 0;
    border-bottom: 0;
    padding: 14px 14px calc(14px + env(safe-area-inset-bottom));
  }

  .modal-header-split {
    align-items: center;
  }
}

@media (max-width: 768px) {
  .center-feed-shell {
    --monitor-left: 14%;
    --monitor-top: 26%;
    --monitor-width: 72%;
    --monitor-height: 30%;
  }
}
