:root {
  color-scheme: dark;
  --ink: #e9eadf;
  --muted: #aeb6a7;
  --paper: #15241d;
  --panel: #1d3128;
  --panel-2: #263b31;
  --line: #405349;
  --field: #102019;
  --jade: #78c59b;
  --jade-dim: #3f8f67;
  --vermilion: #d3664c;
  --gold: #e3bd67;
  --blue: #6daec9;
  --danger: #f18169;
  --shadow: rgba(0, 0, 0, 0.28);
  font-family: "Noto Sans SC", "PingFang SC", "Microsoft YaHei", system-ui, sans-serif;
}

* {
  box-sizing: border-box;
}

body {
  min-width: 320px;
  min-height: 100vh;
  margin: 0;
  background: #0d1813;
  color: var(--ink);
}

button,
input,
select {
  font: inherit;
}

button {
  color: inherit;
}

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

#app {
  min-height: 100vh;
}

.app-shell {
  min-height: 100vh;
  background: #102019;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 58px;
  padding: 10px 16px;
  border-bottom: 1px solid var(--line);
  background: rgba(16, 32, 25, 0.96);
  backdrop-filter: blur(14px);
}

.brand,
.topbar-side,
.resource-row,
.metric-row,
.event-meta,
.action-title,
.log-title,
.city-summary,
.person-line,
.tab-label {
  display: flex;
  align-items: center;
}

.brand {
  gap: 10px;
  min-width: 0;
}

.seal {
  display: grid;
  width: 32px;
  height: 32px;
  place-items: center;
  border: 1px solid var(--vermilion);
  border-radius: 4px;
  color: #ffcfb5;
  background: #582d25;
  box-shadow: inset 0 0 0 2px #3e211c;
  font-family: serif;
  font-size: 18px;
  font-weight: 700;
}

.brand-name {
  font-weight: 800;
  letter-spacing: 0;
}

.brand-sub,
.small-muted {
  color: var(--muted);
  font-size: 12px;
}

.topbar-side {
  gap: 10px;
}

.turn-chip,
.faction-chip,
.status-chip,
.count-chip {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  min-height: 28px;
  padding: 4px 8px;
  border: 1px solid var(--line);
  border-radius: 4px;
  color: var(--muted);
  background: #182a21;
  font-size: 12px;
  white-space: nowrap;
}

.turn-chip strong,
.faction-chip strong {
  color: var(--ink);
}

.icon-button,
.text-button,
.primary-button,
.secondary-button,
.action-button,
.tab-button,
.choice-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid transparent;
  border-radius: 5px;
  cursor: pointer;
  transition: border-color 150ms ease, background 150ms ease, transform 150ms ease;
}

.icon-button:active,
.text-button:active,
.primary-button:active,
.secondary-button:active,
.action-button:active,
.tab-button:active,
.choice-button:active {
  transform: translateY(1px);
}

.icon-button {
  width: 34px;
  height: 34px;
  border-color: var(--line);
  background: var(--panel);
}

.icon-button:hover,
.secondary-button:hover,
.text-button:hover {
  border-color: var(--jade-dim);
  background: #294234;
}

.lucide {
  width: 17px;
  height: 17px;
  stroke-width: 1.8;
}

.game-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 330px;
  min-height: calc(100vh - 58px);
}

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

.status-strip {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 1px;
  border-bottom: 1px solid var(--line);
  background: var(--line);
}

.faction-status {
  min-width: 0;
  padding: 11px 16px;
  background: var(--paper);
}

.faction-status.player {
  background: #193226;
}

.faction-status.enemy {
  background: #2f2923;
}

.faction-status-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.faction-name {
  overflow: hidden;
  font-weight: 800;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.faction-role {
  color: var(--muted);
  font-size: 12px;
}

.resource-row {
  gap: 12px;
  margin-top: 7px;
  overflow: auto;
  color: var(--muted);
  font-size: 12px;
}

.resource-row span {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  white-space: nowrap;
}

.resource-row .lucide {
  width: 13px;
  height: 13px;
}

.map-stage {
  position: relative;
  min-height: 430px;
  overflow: hidden;
  background: var(--field);
}

.map-stage::after {
  position: absolute;
  inset: 0;
  pointer-events: none;
  border: 1px solid rgba(235, 223, 176, 0.1);
  content: "";
}

#map-canvas {
  display: block;
  width: 100%;
  height: 100%;
  min-height: 430px;
  touch-action: none;
}

.map-legend {
  position: absolute;
  right: 14px;
  bottom: 14px;
  display: flex;
  gap: 9px;
  padding: 8px 10px;
  border: 1px solid rgba(216, 227, 195, 0.18);
  border-radius: 4px;
  background: rgba(12, 27, 20, 0.88);
  color: var(--muted);
  font-size: 11px;
  pointer-events: none;
}

.legend-dot {
  display: inline-block;
  width: 7px;
  height: 7px;
  margin-right: 4px;
  border-radius: 50%;
}

.legend-dot.player {
  background: var(--jade);
}

.legend-dot.enemy {
  background: var(--vermilion);
}

.legend-dot.neutral {
  background: var(--gold);
}

.action-dock {
  position: sticky;
  bottom: 0;
  z-index: 10;
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  min-height: 78px;
  border-top: 1px solid var(--line);
  background: #16271f;
}

.action-button {
  flex-direction: column;
  gap: 5px;
  min-width: 0;
  padding: 8px 4px;
  border-right: 1px solid rgba(64, 83, 73, 0.55);
  border-radius: 0;
  color: var(--muted);
  background: transparent;
  font-size: 11px;
}

.action-button:last-child {
  border-right: 0;
}

.action-button:hover,
.action-button.active {
  color: var(--ink);
  background: #244033;
}

.action-button .lucide {
  color: var(--jade);
}

.action-button[data-kind="military"] .lucide {
  color: var(--vermilion);
}

.action-button[data-kind="diplomacy"] .lucide {
  color: var(--gold);
}

.action-button[data-kind="end-turn"] .lucide {
  color: var(--blue);
}

.side-panel {
  display: flex;
  min-height: 0;
  flex-direction: column;
  border-left: 1px solid var(--line);
  background: #17281f;
}

.panel-tabs {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  border-bottom: 1px solid var(--line);
}

.tab-button {
  gap: 5px;
  min-height: 45px;
  border: 0;
  border-right: 1px solid rgba(64, 83, 73, 0.5);
  border-radius: 0;
  color: var(--muted);
  background: transparent;
  font-size: 12px;
}

.tab-button:last-child {
  border-right: 0;
}

.tab-button.active {
  color: var(--ink);
  background: #21382c;
  box-shadow: inset 0 -2px 0 var(--jade);
}

.tab-button .lucide {
  width: 15px;
  height: 15px;
}

.panel-content {
  min-height: 0;
  flex: 1;
  overflow-y: auto;
  padding: 14px;
}

.panel-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 12px;
}

.eyebrow {
  margin-bottom: 3px;
  color: var(--jade);
  font-size: 11px;
  font-weight: 700;
}

.panel-heading h2,
.event-card h3,
.action-modal h2,
.lobby-title h1,
.lobby-panel h2 {
  margin: 0;
  letter-spacing: 0;
}

.panel-heading h2 {
  font-size: 18px;
}

.city-detail {
  display: grid;
  gap: 12px;
}

.city-title-row {
  display: flex;
  align-items: center;
  gap: 8px;
}

.city-title-row h3 {
  margin: 0;
  font-size: 22px;
}

.owner-flag {
  width: 8px;
  height: 23px;
  border-radius: 1px;
}

.metric-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1px;
  border: 1px solid var(--line);
  background: var(--line);
}

.metric {
  padding: 10px;
  background: #1b3026;
}

.metric-label {
  color: var(--muted);
  font-size: 11px;
}

.metric-value {
  margin-top: 3px;
  font-size: 17px;
  font-weight: 800;
}

.city-description,
.person-description,
.event-card p,
.log-entry p,
.lobby-copy {
  margin: 0;
  color: #cbd2c5;
  font-size: 13px;
  line-height: 1.65;
}

.list-heading {
  margin: 4px 0 7px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 700;
}

.person-list,
.log-list,
.event-list {
  display: grid;
  gap: 8px;
}

.person-row,
.log-entry,
.event-card,
.action-summary {
  border: 1px solid var(--line);
  border-radius: 5px;
  background: #1a2e24;
}

.person-row {
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr) auto;
  gap: 8px;
  align-items: center;
  padding: 9px;
}

.person-avatar {
  display: grid;
  width: 34px;
  height: 34px;
  place-items: center;
  border: 1px solid #627e6e;
  border-radius: 3px;
  color: #cce5d5;
  background: #2f4a3b;
  font-family: serif;
  font-size: 17px;
  font-weight: 700;
}

.person-name {
  font-size: 14px;
  font-weight: 800;
}

.person-meta {
  overflow: hidden;
  margin-top: 2px;
  color: var(--muted);
  font-size: 11px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.person-value {
  color: var(--gold);
  font-size: 12px;
  font-weight: 700;
}

.event-card {
  position: relative;
  overflow: hidden;
  padding: 12px;
}

.event-card.secret {
  border-color: #596b8b;
  background: #202e37;
}

.event-card.warning {
  border-color: #986956;
  background: #382b25;
}

.event-card h3 {
  margin-bottom: 5px;
  font-size: 14px;
}

.event-meta {
  gap: 7px;
  margin-bottom: 8px;
  color: var(--muted);
  font-size: 11px;
}

.event-meta .lucide {
  width: 13px;
  height: 13px;
  color: var(--gold);
}

.event-actions {
  display: grid;
  gap: 6px;
  margin-top: 10px;
}

.text-button {
  min-height: 32px;
  justify-content: flex-start;
  gap: 7px;
  padding: 7px 8px;
  border-color: var(--line);
  color: #d9e3d7;
  background: #20372b;
  font-size: 12px;
  text-align: left;
}

.text-button .lucide {
  width: 15px;
  height: 15px;
  color: var(--jade);
  flex: 0 0 auto;
}

.log-entry {
  padding: 10px;
}

.log-entry.good {
  border-left: 3px solid var(--jade);
}

.log-entry.bad {
  border-left: 3px solid var(--vermilion);
}

.log-entry.info {
  border-left: 3px solid var(--blue);
}

.log-title {
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 5px;
  color: #e1e8dc;
  font-size: 12px;
  font-weight: 800;
}

.log-date {
  color: var(--muted);
  font-size: 11px;
  font-weight: 400;
}

.lobby {
  min-height: 100vh;
  background: #102019;
}

.lobby-hero {
  display: grid;
  min-height: 40vh;
  align-content: end;
  padding: 34px 20px 28px;
  border-bottom: 1px solid var(--line);
  background: #192c22;
}

.lobby-badge {
  display: inline-flex;
  width: fit-content;
  align-items: center;
  gap: 7px;
  margin-bottom: 14px;
  color: var(--gold);
  font-size: 12px;
  font-weight: 700;
}

.lobby-badge .lucide {
  width: 15px;
  height: 15px;
}

.lobby-title h1 {
  max-width: 700px;
  color: #f2f1e8;
  font-family: serif;
  font-size: clamp(34px, 8vw, 60px);
  font-weight: 800;
  line-height: 1.12;
}

.lobby-title p {
  max-width: 600px;
  margin: 13px 0 0;
  color: #bdc9bb;
  font-size: 15px;
  line-height: 1.65;
}

.lobby-content {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 310px;
  max-width: 1080px;
  margin: 0 auto;
}

.lobby-main,
.lobby-aside {
  padding: 22px 20px 34px;
}

.lobby-aside {
  border-left: 1px solid var(--line);
  background: #15261e;
}

.lobby-panel {
  max-width: 660px;
}

.lobby-panel h2 {
  margin-bottom: 5px;
  font-size: 20px;
}

.setup-form {
  display: grid;
  gap: 12px;
  margin-top: 18px;
}

.input-label {
  display: grid;
  gap: 6px;
  color: var(--muted);
  font-size: 12px;
}

.text-input,
.select-input {
  width: 100%;
  min-height: 44px;
  padding: 0 11px;
  border: 1px solid var(--line);
  border-radius: 4px;
  outline: none;
  color: var(--ink);
  background: #14271e;
}

.text-input:focus,
.select-input:focus {
  border-color: var(--jade);
}

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

.choice-button {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  justify-content: start;
  gap: 9px;
  min-height: 72px;
  padding: 10px;
  border-color: var(--line);
  color: var(--muted);
  background: #182c22;
  text-align: left;
}

.choice-button.selected {
  border-color: var(--jade);
  color: var(--ink);
  background: #244033;
}

.choice-crest {
  display: grid;
  width: 36px;
  height: 48px;
  place-items: center;
  border: 1px solid currentColor;
  border-radius: 2px;
  color: var(--gold);
  font-family: serif;
  font-size: 19px;
  font-weight: 700;
}

.choice-button.selected[data-faction="cao"] .choice-crest {
  color: var(--vermilion);
}

.choice-name {
  display: block;
  margin-bottom: 3px;
  color: var(--ink);
  font-weight: 800;
}

.choice-meta {
  display: block;
  overflow: hidden;
  color: var(--muted);
  font-size: 11px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.primary-button,
.secondary-button {
  min-height: 46px;
  gap: 8px;
  padding: 0 15px;
  font-weight: 800;
}

.primary-button {
  border-color: #8fbfa2;
  color: #102019;
  background: var(--jade);
}

.primary-button:hover {
  background: #9ed3af;
}

.secondary-button {
  border-color: var(--line);
  color: var(--ink);
  background: transparent;
}

.primary-button .lucide,
.secondary-button .lucide {
  width: 17px;
  height: 17px;
}

.aside-stat {
  display: grid;
  gap: 4px;
  padding: 12px 0;
  border-bottom: 1px solid var(--line);
}

.aside-stat:last-child {
  border-bottom: 0;
}

.aside-value {
  color: var(--gold);
  font-family: serif;
  font-size: 25px;
  font-weight: 800;
}

.aside-label {
  color: var(--muted);
  font-size: 12px;
}

.modal-backdrop {
  position: fixed;
  z-index: 40;
  inset: 0;
  display: grid;
  place-items: end center;
  padding: 0;
  background: rgba(2, 11, 6, 0.7);
}

.action-modal {
  width: min(680px, 100%);
  max-height: min(86vh, 720px);
  overflow: auto;
  border: 1px solid var(--line);
  border-bottom: 0;
  border-radius: 8px 8px 0 0;
  background: #182b22;
  box-shadow: 0 -18px 50px var(--shadow);
}

.modal-header {
  position: sticky;
  top: 0;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 15px;
  border-bottom: 1px solid var(--line);
  background: #1a2e24;
}

.modal-header h2 {
  font-size: 19px;
}

.modal-body {
  display: grid;
  gap: 15px;
  padding: 15px;
}

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

.action-option {
  display: grid;
  gap: 6px;
  min-height: 82px;
  padding: 11px;
  border: 1px solid var(--line);
  border-radius: 5px;
  color: var(--muted);
  background: #13251c;
  cursor: pointer;
  text-align: left;
}

.action-option.selected {
  border-color: var(--jade);
  color: var(--ink);
  background: #244033;
}

.action-option span {
  color: var(--ink);
  font-size: 13px;
  font-weight: 800;
}

.action-option small {
  color: inherit;
  font-size: 11px;
  line-height: 1.4;
}

.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.form-grid .full {
  grid-column: 1 / -1;
}

.range-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 10px;
  align-items: center;
}

input[type="range"] {
  width: 100%;
  accent-color: var(--jade);
}

.action-summary {
  padding: 11px;
  background: #20372b;
}

.action-summary strong {
  display: block;
  margin-bottom: 4px;
  color: var(--gold);
  font-size: 12px;
}

.action-summary span {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.5;
}

.modal-footer {
  display: grid;
  grid-template-columns: 1fr 1.25fr;
  gap: 9px;
  padding: 0 15px 15px;
}

.dice-overlay {
  position: fixed;
  z-index: 60;
  inset: 0;
  display: grid;
  place-items: center;
  padding: 20px;
  background: rgba(3, 12, 7, 0.76);
}

.dice-card {
  width: min(300px, 100%);
  padding: 22px;
  border: 1px solid #648776;
  border-radius: 8px;
  background: #1c3328;
  box-shadow: 0 18px 50px rgba(0, 0, 0, 0.4);
  text-align: center;
}

.die {
  display: grid;
  width: 80px;
  height: 80px;
  margin: 4px auto 16px;
  place-items: center;
  border: 2px solid var(--gold);
  border-radius: 8px;
  color: var(--gold);
  background: #153025;
  font-family: Georgia, serif;
  font-size: 36px;
  font-weight: 800;
}

.die.rolling {
  animation: die-roll 620ms ease-in-out infinite alternate;
}

@keyframes die-roll {
  from { transform: rotate(-8deg) scale(0.95); }
  to { transform: rotate(9deg) scale(1.05); }
}

.dice-card h3 {
  margin: 0;
  font-size: 17px;
}

.dice-card p {
  margin: 7px 0 0;
  color: var(--muted);
  font-size: 13px;
}

.toast {
  position: fixed;
  z-index: 70;
  right: 14px;
  bottom: 92px;
  max-width: min(360px, calc(100vw - 28px));
  padding: 11px 13px;
  border: 1px solid #638675;
  border-radius: 5px;
  color: #e9f1e6;
  background: #244232;
  box-shadow: 0 10px 28px var(--shadow);
  font-size: 13px;
}

.empty-state {
  padding: 20px 8px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.65;
  text-align: center;
}

@media (max-width: 840px) {
  .game-layout {
    display: block;
    min-height: 0;
  }

  .side-panel {
    min-height: 330px;
    border-top: 1px solid var(--line);
    border-left: 0;
  }

  .map-stage,
  #map-canvas {
    min-height: 390px;
  }

  .lobby-content {
    display: block;
  }

  .lobby-aside {
    border-top: 1px solid var(--line);
    border-left: 0;
  }
}

@media (max-width: 520px) {
  .topbar {
    padding-right: 12px;
    padding-left: 12px;
  }

  .brand-sub,
  .turn-chip .turn-label {
    display: none;
  }

  .faction-status {
    padding: 10px 12px;
  }

  .resource-row {
    gap: 8px;
  }

  .map-stage,
  #map-canvas {
    min-height: 340px;
  }

  .map-legend {
    right: 9px;
    bottom: 9px;
  }

  .panel-content {
    padding: 12px;
  }

  .action-option {
    min-height: 74px;
  }

  .form-grid {
    grid-template-columns: 1fr;
  }

  .lobby-hero {
    min-height: 35vh;
    padding: 28px 18px 24px;
  }

  .lobby-main,
  .lobby-aside {
    padding: 20px 16px 28px;
  }
}

a.primary-button {
  text-decoration: none;
}

button:disabled {
  cursor: not-allowed;
  opacity: 0.48;
}

.login-screen {
  display: grid;
  min-height: 100vh;
  place-items: center;
  padding: 22px;
  background: #102019;
}

.login-panel {
  display: grid;
  width: min(440px, 100%);
  justify-items: start;
  gap: 13px;
  padding: 26px;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: #1b3026;
  box-shadow: 0 20px 60px var(--shadow);
}

.login-panel h1 {
  margin: 0;
  font-family: serif;
  font-size: 34px;
}

.login-panel p {
  margin: 0;
  color: #cbd2c5;
  font-size: 14px;
  line-height: 1.7;
}

.login-button {
  width: 100%;
  margin-top: 3px;
}

.login-error {
  width: 100%;
  padding: 9px 10px;
  border: 1px solid #986956;
  border-radius: 4px;
  color: #ffcec0 !important;
  background: #3b2924;
}

.hub,
.room {
  min-height: 100vh;
  background: #102019;
}

.hub-header {
  display: flex;
  min-height: 62px;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px max(16px, calc((100vw - 960px) / 2));
  border-bottom: 1px solid var(--line);
  background: #17291f;
}

.hub-content,
.room-content {
  width: min(960px, 100%);
  margin: 0 auto;
  padding: 28px 18px 48px;
}

.hub-title {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 22px;
}

.hub-title h1,
.faction-pick h1 {
  margin: 0;
  font-family: serif;
  font-size: 31px;
}

.hub-title p {
  max-width: 360px;
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.6;
}

.hub-actions {
  display: flex;
  gap: 9px;
  margin: 22px 0;
}

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

.game-card {
  display: flex;
  width: 100%;
  min-height: 66px;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 5px;
  color: var(--ink);
  background: #1a2e24;
  cursor: pointer;
  text-align: left;
}

.game-card:hover {
  border-color: var(--jade-dim);
  background: #22382d;
}

.game-card-title {
  margin-bottom: 3px;
  font-weight: 800;
}

.room-content {
  display: grid;
  gap: 25px;
}

.room-code {
  display: grid;
  justify-items: center;
  gap: 5px;
  padding: 26px;
  border: 1px solid var(--gold);
  border-radius: 6px;
  background: #302d22;
  text-align: center;
}

.room-code strong {
  color: var(--gold);
  font-family: Georgia, serif;
  font-size: 43px;
  letter-spacing: 5px;
}

.room-code span {
  color: var(--muted);
  font-size: 12px;
}

.seat-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1px;
  border: 1px solid var(--line);
  background: var(--line);
}

.seat {
  display: grid;
  gap: 4px;
  min-height: 96px;
  padding: 15px;
  background: #172b21;
}

.seat.occupied {
  background: #20382b;
}

.seat-label {
  color: var(--muted);
  font-size: 11px;
}

.seat strong {
  font-size: 17px;
}

.seat > span:last-child {
  color: var(--jade);
  font-size: 12px;
}

.faction-pick {
  display: grid;
  gap: 15px;
}

.connection-indicator {
  position: absolute;
  top: 12px;
  right: 12px;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  min-height: 28px;
  padding: 5px 8px;
  border: 1px solid var(--line);
  border-radius: 4px;
  background: rgba(16, 32, 25, 0.88);
  color: var(--muted);
  font-size: 11px;
}

.connection-indicator .lucide {
  width: 14px;
  height: 14px;
}

.connection-indicator.online .lucide {
  color: var(--jade);
}

.connection-indicator.offline {
  border-color: #986956;
  color: #ffd2c2;
}

.connection-indicator.offline .lucide {
  color: var(--vermilion);
}

.order-queue {
  display: grid;
  gap: 7px;
}

.order-item {
  display: grid;
  grid-template-columns: 28px minmax(0, 1fr) 34px;
  gap: 8px;
  align-items: center;
  padding: 9px;
  border: 1px solid var(--line);
  border-radius: 5px;
  background: #1a2f24;
}

.order-item > span {
  display: grid;
  width: 25px;
  height: 25px;
  place-items: center;
  border: 1px solid var(--jade-dim);
  border-radius: 3px;
  color: var(--jade);
  font-size: 12px;
  font-weight: 800;
}

.order-item strong,
.order-item small {
  display: block;
}

.order-item strong {
  font-size: 13px;
}

.order-item small {
  overflow: hidden;
  margin-top: 2px;
  color: var(--muted);
  font-size: 11px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.add-order {
  width: 100%;
  margin-top: 10px;
}

.code-input {
  letter-spacing: 4px;
  text-transform: uppercase;
}

@media (max-width: 560px) {
  .hub-title {
    display: grid;
    gap: 8px;
  }

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

  .seat-grid {
    grid-template-columns: 1fr;
  }

  .room-code strong {
    font-size: 36px;
  }
}
