/* ============ 公共样式 ============ */
* { box-sizing: border-box; margin: 0; padding: 0; }
:root {
  --bg: #F3F5F8; --card: #FFFFFF; --ink: #1F2530; --sub: #6B7280;
  --primary: #C8442A; --primary-dark: #A8361F; --ok: #16A34A; --warn: #F59E0B;
  --line: #E5E8ED;
}
html, body { height: 100%; }
body {
  font-family: 'PingFang SC', 'Microsoft YaHei', -apple-system, sans-serif;
  background: var(--bg); color: var(--ink);
  -webkit-font-smoothing: antialiased;
}

/* 座位状态（SVG） */
.seat-rect.st-empty    { transition: fill .4s; }
.seat-rect.st-unchecked{ transition: fill .4s; }
.seat-rect.st-checked  { transition: fill .4s; }
.seat-rect.flash {
  animation: seatFlash 3s ease-out;
}
@keyframes seatFlash {
  0%   { filter: drop-shadow(0 0 0 #F59E0B) brightness(1); }
  25%  { filter: drop-shadow(0 0 1.2 #F59E0B) brightness(1.35); }
  60%  { filter: drop-shadow(0 0 0.8 #F59E0B) brightness(1.15); }
  100% { filter: drop-shadow(0 0 0 #F59E0B) brightness(1); }
}
.ring { animation: ringPulse 2.2s ease-in-out infinite; transform-box: fill-box; transform-origin: center; }
@keyframes ringPulse {
  0%,100% { transform: scale(1); opacity: 1; }
  50%     { transform: scale(1.06); opacity: .55; }
}

/* 通用卡片/按钮 */
.card {
  background: var(--card); border-radius: 14px; padding: 18px;
  box-shadow: 0 1px 3px rgba(16,24,40,.08), 0 1px 2px rgba(16,24,40,.04);
}
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  border: none; border-radius: 10px; cursor: pointer;
  font-size: 15px; font-weight: 600; padding: 11px 18px;
  background: var(--primary); color: #fff;
  transition: transform .06s, background .2s;
}
.btn:active { transform: scale(.97); }
.btn:disabled { opacity: .5; cursor: not-allowed; }
.btn.secondary { background: #EEF1F5; color: var(--ink); }
.btn.danger { background: #FEE2E2; color: #B91C1C; }
.btn.small { font-size: 13px; padding: 7px 12px; border-radius: 8px; }

input, select {
  width: 100%; font-size: 16px; padding: 12px 14px;
  border: 1.5px solid var(--line); border-radius: 10px; outline: none;
  background: #fff; color: var(--ink); font-family: inherit;
}
input:focus, select:focus { border-color: var(--primary); }
label.field { display: block; margin-bottom: 14px; }
label.field span { display: block; font-size: 13px; color: var(--sub); margin-bottom: 6px; }

.badge {
  display: inline-block; font-size: 12px; padding: 3px 9px; border-radius: 99px; font-weight: 600;
}
.badge.ok { background: #DCFCE7; color: #15803D; }
.badge.wait { background: #F1F3F6; color: #6B7280; }
.badge.doing { background: #FEF3C7; color: #B45309; }

.error-banner {
  background: #FEF2F2; border: 1px solid #FECACA; color: #B91C1C;
  border-radius: 10px; padding: 10px 14px; font-size: 13px; line-height: 1.6;
  margin-bottom: 14px; word-break: break-all;
}
.toast {
  position: fixed; left: 50%; top: 18px; transform: translateX(-50%);
  background: rgba(30,35,45,.92); color: #fff; padding: 10px 18px;
  border-radius: 10px; font-size: 14px; z-index: 99;
  opacity: 0; pointer-events: none; transition: opacity .25s;
  max-width: 86vw;
}
.toast.show { opacity: 1; }
