:root {
  color-scheme: dark;
  --bg: #090d10;
  --panel: #12181d;
  --panel-2: #182027;
  --panel-3: #0d1317;
  --line: #2d3944;
  --text: #edf5f3;
  --muted: #9eb0ad;
  --green: #35d07f;
  --amber: #f0b34a;
  --red: #ff6b6b;
  --cyan: #5ec7df;
  --violet: #aa8dff;
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  min-height: 100%;
  background: var(--bg);
  color: var(--text);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  letter-spacing: 0;
}

button {
  min-height: 38px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 8px 11px;
  color: var(--text);
  background: #17212a;
  font: inherit;
  cursor: pointer;
}

button:hover,
button:focus-visible {
  border-color: var(--cyan);
  outline: none;
}

.shell {
  min-height: 100vh;
  padding: 20px;
  background:
    linear-gradient(135deg, rgba(53, 208, 127, 0.08), transparent 32rem),
    linear-gradient(315deg, rgba(94, 199, 223, 0.08), transparent 28rem),
    var(--bg);
}

.topbar,
.control-band,
.progress-panel {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(18, 24, 29, 0.82);
}

.topbar {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 12px;
  padding: 16px;
}

.eyebrow {
  margin: 0 0 5px;
  color: var(--green);
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
}

h1,
h2,
p {
  margin: 0;
  letter-spacing: 0;
}

h1 {
  font-size: clamp(32px, 5vw, 62px);
  line-height: 0.95;
}

h2 {
  font-size: 16px;
}

.subhead {
  max-width: 720px;
  margin-top: 10px;
  color: var(--muted);
}

.status-strip,
.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.status-strip {
  justify-content: flex-end;
  max-width: 620px;
}

.status-strip span,
.panel header span,
.pill {
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 5px 9px;
  color: var(--muted);
  background: rgba(18, 24, 29, 0.9);
  font-size: 12px;
  white-space: nowrap;
}

.control-band {
  display: grid;
  grid-template-columns: minmax(220px, 320px) 1fr;
  gap: 14px;
  align-items: start;
  margin-bottom: 12px;
  padding: 14px;
}

.control-band p {
  margin-top: 6px;
  color: var(--muted);
  font-size: 14px;
}

.progress-panel {
  display: grid;
  grid-template-columns: minmax(220px, 320px) 1fr;
  gap: 14px;
  margin-bottom: 12px;
  padding: 14px;
}

.progress-track {
  height: 10px;
  margin-top: 12px;
  border-radius: 999px;
  background: #1f2932;
  overflow: hidden;
}

#progress-fill {
  display: block;
  width: 0;
  height: 100%;
  background: linear-gradient(90deg, var(--green), var(--cyan));
  transition: width 180ms ease;
}

.progress-list {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 8px;
  padding: 0;
  margin: 0;
  list-style: none;
}

.progress-list li {
  min-height: 48px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 8px;
  color: var(--muted);
  background: var(--panel-3);
  font-size: 12px;
}

.progress-list li.done {
  border-color: rgba(53, 208, 127, 0.75);
  color: var(--text);
}

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

.panel {
  min-height: 214px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 14px;
  background: linear-gradient(180deg, var(--panel), #0e1317);
  box-shadow: 0 18px 44px rgba(0, 0, 0, 0.28);
}

.panel header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 12px;
}

.table-map,
.display {
  grid-column: span 4;
}

.flow,
.kds,
.customer {
  grid-column: span 4;
}

.table-grid,
.stack,
.ticket-list {
  display: grid;
  gap: 10px;
}

.table-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.table {
  min-height: 98px;
  display: grid;
  place-items: center;
  cursor: default;
}

.table span {
  display: block;
  color: var(--muted);
  font-size: 12px;
}

.table.active {
  border-color: rgba(53, 208, 127, 0.9);
  background: #123125;
}

.row,
.ticket {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 10px;
  background: var(--panel-3);
  color: var(--text);
}

.ticket {
  display: grid;
  gap: 8px;
}

.ticket strong,
.row strong {
  color: var(--cyan);
}

.ready {
  color: var(--green);
}

.pending {
  color: var(--amber);
}

.blocked {
  color: var(--red);
}

.accent {
  color: var(--violet);
}

@media (max-width: 1080px) {
  .topbar,
  .control-band,
  .progress-panel {
    grid-template-columns: 1fr;
  }

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

  .status-strip {
    justify-content: flex-start;
  }

  .panel {
    grid-column: span 6;
  }

  .progress-list {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 700px) {
  .shell {
    padding: 12px;
  }

  .panel {
    grid-column: span 12;
  }

  .table-grid,
  .progress-list {
    grid-template-columns: 1fr;
  }
}
