/* =====================================================================
   Anthony's Ristorante · Springfield — Reservations Portal
   Stylesheet (assets/css/app.css)

   HOW THIS FILE IS ORGANIZED
   Rules are listed in the order the design was built up, and LATER RULES
   OVERRIDE EARLIER ONES. When changing a style, search for the selector and
   edit the LAST rule that sets the property you want — that is the one that
   wins. Both themes are handled with html[data-theme="light"] /
   html[data-theme="dark"] selectors.

   Breakpoints used throughout
     max-width: 480px    small phones
     max-width: 760px    phones (bottom tab bar layout)
     761px – 1376px      iPad / tablet layout (13" iPad Pro landscape = 1376px)
     min-width: 1377px   desktop

   Sections (search for these headings)
     Base · Buttons & inputs · Login · Shell · Book view · Detail · Layers
     Toasts · Guests / Audit / Staff · Responsive · Additions for the
     Airtable model · Color · Booking form · Themed calendar · Tables board
     Title font · List column headings · Light theme · Action column …
     followed by later refinements, each with its own heading comment.
   ===================================================================== */

:root {
  --ink: #0b0b0c;
  --coal: #111113;
  --slate: #18181b;
  --raise: #1f1f23;
  --line: rgba(255, 255, 255, 0.07);
  --line2: rgba(255, 255, 255, 0.12);
  --text: #f3f1ec;
  --sub: #aaa59c;
  --mute: #6e6b65;
  --faint: #45433f;
  --gold: #b89b5e;
  --gold-hi: #d6bf8a;
  --gold-lo: #8c7444;
  --gold-soft: rgba(184, 155, 94, 0.13);
  --gold-line: rgba(184, 155, 94, 0.38);
  --sage: #8fae96;
  --rust: #bd7a6c;
  --ivory: #e7dcc6;
  --sans: Inter, -apple-system, "SF Pro Text", system-ui, sans-serif;
  --r: 14px;
  --sa-t: env(safe-area-inset-top, 0px);
  --sa-b: env(safe-area-inset-bottom, 0px);
  --sa-l: env(safe-area-inset-left, 0px);
  --sa-r: env(safe-area-inset-right, 0px);
  --ease: cubic-bezier(0.2, 0.7, 0.2, 1);
}
* {
  box-sizing: border-box;
  -webkit-tap-highlight-color: transparent;
  /* iPhone / iPad: a quick second tap never zooms the app in (scrolling and pinching work as usual); places that
     handle touches themselves set their own touch-action further down */
  touch-action: manipulation;
}
html,
body {
  margin: 0;
  background: var(--ink);
  color: var(--text);
  font-family: var(--sans);
  font-size: 15px;
  line-height: 1.45;
  -webkit-font-smoothing: antialiased;
  font-feature-settings:
    "tnum" 1,
    "cv11" 1;
}
button {
  font: inherit;
  color: inherit;
  background: none;
  border: 0;
  cursor: pointer;
  padding: 0;
}
input,
textarea,
select {
  font: inherit;
  color: inherit;
}
a {
  color: inherit;
}
svg.i {
  width: 20px;
  height: 20px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.6;
  stroke-linecap: round;
  stroke-linejoin: round;
  flex: none;
}

.muted {
  color: var(--sub);
}
.faint {
  color: var(--mute);
}
.hidden {
  display: none !important;
}
::selection {
  background: var(--gold-soft);
}
:focus-visible {
  outline: 1.5px solid var(--gold);
  outline-offset: 2px;
  border-radius: 8px;
}
/* ---------- Buttons & inputs ---------- */
.btn {
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  height: 44px;
  padding: 0 18px;
  border-radius: 12px;
  letter-spacing: 0.01em;
  border: 1px solid var(--line2);
  background: var(--slate);
  transition:
    background 0.15s,
    border-color 0.15s,
    transform 0.08s;
  white-space: nowrap;
}
.btn:hover {
  background: var(--raise);
}
.btn:active {
  transform: scale(0.98);
}

.btn.gold:hover {
  background: linear-gradient(180deg, #cdb277, #b09358);
}
.btn.ghost {
  background: transparent;
}
.btn.quiet {
  background: transparent;
  border-color: transparent;
  color: var(--sub);
}
.btn.quiet:hover {
  color: var(--text);
  background: var(--slate);
}
.btn.danger {
  color: var(--rust);
  border-color: rgba(189, 122, 108, 0.35);
  background: transparent;
}
.btn.danger:hover {
  background: rgba(189, 122, 108, 0.08);
}
.btn.sm {
  height: 34px;
  padding: 0 12px;
  border-radius: 10px;
  font-size: 13px;
}
.btn.icon {
  width: 44px;
  padding: 0;
}
.btn.sm.icon {
  width: 34px;
}
.btn[disabled] {
  opacity: 0.45;
  pointer-events: none;
}
.field {
  display: flex;
  flex-direction: column;
  gap: 7px;
}
.field > span:not(.xfield) {
  color: var(--mute);
  display: flex;
  align-items: center;
  gap: 8px;
}
.input {
  height: 46px;
  border-radius: 12px;
  border: 1px solid var(--line2);
  background: var(--coal);
  padding: 0 14px;
  outline: none;
  transition:
    border-color 0.15s,
    background 0.15s;
  width: 100%;
}
.input:focus {
  border-color: var(--gold-line);
  background: var(--field-focus);
}
textarea.input {
  height: auto;
  min-height: 84px;
  padding: 12px 14px;
  resize: vertical;
  line-height: 1.5;
}
select.input {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23aaa59c' stroke-width='1.6'%3E%3Cpath d='M7 10l5 5 5-5'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  background-size: 18px;
  padding-right: 38px;
}
input[type="date"].input,
input[type="time"].input {
  color-scheme: dark;
}
.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.chip {
  height: 38px;
  min-width: 44px;
  padding: 0 13px;
  border-radius: 10px;
  border: 1px solid var(--line2);
  background: var(--coal);
  font-size: 14px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  transition: all 0.12s;
  color: var(--sub);
}
.chip:hover {
  color: var(--text);
  border-color: rgba(255, 255, 255, 0.2);
}

.chip small {
  font-size: 10.5px;
  color: var(--mute);
}
.chip.busy {
  position: relative;
}
.chip .load {
  position: absolute;
  left: 8px;
  right: 8px;
  bottom: 4px;
  height: 2px;
  border-radius: 2px;
  background: var(--faint);
  overflow: hidden;
}
.chip .load i {
  display: block;
  height: 100%;
  background: var(--gold-lo);
}
.seg {
  display: inline-flex;
  padding: 3px;
  border-radius: 12px;
  background: var(--coal);
  border: 1px solid var(--line);
}
.seg button {
  height: 32px;
  padding: 0 13px;
  border-radius: 9px;
  font-size: 13px;
  color: var(--sub);
  white-space: nowrap;
}

.seg button .n {
  color: var(--mute);
  margin-left: 5px;
  font-size: 12px;
}

/* ---------- Login ---------- */
#login {
  position: fixed;
  inset: 0;
  display: grid;
  place-items: center;
  padding: calc(24px + var(--sa-t)) 22px calc(24px + var(--sa-b));
  overflow: auto;
}
.lg-wrap {
  width: 100%;
  max-width: 420px;
  display: flex;
  flex-direction: column;
  align-items: center;
}
.crest {
  position: relative;
  width: min(360px, 88vw);
  aspect-ratio: 1.85;
  display: grid;
  place-items: center;
  margin-bottom: 34px;
}
.crest svg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}
.crest .wm {
  position: relative;
  text-align: center;
  transform: translateY(-4px);
}
.wordmark {
  font-family: var(--script);
  font-size: min(96px, 24vw);
  line-height: 0.8;
  color: var(--text);
  letter-spacing: 0.01em;
  text-shadow: 0 2px 30px rgba(0, 0, 0, 0.6);
}

.lg-card {
  width: 100%;
  border-radius: 20px;
  padding: 26px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  backdrop-filter: blur(8px);
}
.lg-card h1 {
  margin: 0;
  text-align: center;
}
.lg-card .rule {
  display: flex;
  align-items: center;
  gap: 12px;
  color: var(--gold);
  font-size: 11px;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  justify-content: center;
}
.lg-card .rule:before,
.lg-card .rule:after {
  content: "";
  height: 1px;
  background: var(--gold-line);
}
.lg-err {
  color: var(--rust);
  font-size: 13px;
  min-height: 18px;
  text-align: center;
}
.lg-foot {
  margin-top: 22px;
  font-size: 12px;
  color: var(--mute);
  text-align: center;
  letter-spacing: 0.04em;
  line-height: 1.7;
}
.lg-demo {
  margin-top: 6px;
  border: 1px dashed var(--line2);
  border-radius: 12px;
  padding: 10px 12px;
  font-size: 12.5px;
  color: var(--sub);
  text-align: center;
}
.lg-demo b {
  color: var(--gold-hi);
  font-weight: 500;
}
.pw {
  position: relative;
}
.pw .btn {
  position: absolute;
  right: 4px;
  top: 4px;
  height: 38px;
  color: var(--mute);
}
/* ---------- Shell ---------- */
.app {
  display: grid;
  grid-template-columns: var(--rail-col) minmax(0, 1fr) 440px;
  height: 100vh;
  height: 100dvh;
}
.app[data-view="guests"],
.app[data-view="servers"],
.app[data-view="texts"],
.app[data-view="audit"],
.app[data-view="staff"] {
  grid-template-columns: var(--rail-col) minmax(0, 1fr) 0;
}
.rail {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: calc(18px + var(--sa-t)) 0 calc(16px + var(--sa-b)) var(--sa-l);
  gap: 6px;
}
.mono {
  border-radius: 50%;
  display: grid;
  place-items: center;
  position: relative;
  margin-bottom: 18px;
}
.mono:before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 50%;
  border: 1px solid var(--gold-line);
}
.mono:after {
  content: "";
  position: absolute;
  border-radius: 50%;
  border: 1px solid rgba(184, 155, 94, 0.18);
}
.mono span {
  font-family: var(--script);
  font-size: 40px;
  color: var(--gold-hi);
  transform: translate(1px, 3px);
}
.nav {
  width: 66px;
  height: 62px;
  border-radius: 14px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 5px;
  color: var(--mute);
  transition:
    color 0.15s,
    background 0.15s;
}
.nav span {
  font-size: 9.5px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}
.nav:hover {
  color: var(--sub);
  background: var(--coal);
}

.nav.on:before {
  content: "";
  position: absolute;
  left: -9px;
  top: 16px;
  bottom: 16px;
  width: 2px;
  border-radius: 2px;
  background: var(--gold);
}
.rail .sp {
  flex: 1;
}
.avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: var(--slate);
  border: 1px solid var(--line2);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.04em;
  color: var(--ivory);
  flex: none;
}
.avatar.gold {
  border-color: var(--gold-line);
  color: var(--gold-hi);
}
.avatar.sm {
  width: 30px;
  height: 30px;
  font-size: 11px;
}
.avatar.lg {
  width: 64px;
  height: 64px;
}
main#main {
  min-width: 0;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  position: relative;
}
aside#detail {
  overflow: hidden;
  min-width: 0;
}
.tabbar {
  display: none;
}
/* ---------- Book view ---------- */
.view {
  display: flex;
  flex-direction: column;
  min-height: 0;
  height: 100%;
}
.top {
  padding: calc(22px + var(--sa-t)) 28px 0;
  display: flex;
  align-items: flex-end;
  gap: 16px 20px;
  flex-wrap: wrap;
}
.top .title {
  flex: 1;
  min-width: 220px;
}
.top h1 {
  margin: 4px 0 0;
  display: flex;
  align-items: baseline;
  gap: 14px;
  flex-wrap: wrap;
}
.today-tag {
  font-family: var(--sans);
  font-size: 11px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  border: 1px solid var(--gold-line);
  border-radius: 999px;
  padding: 4px 10px;
  transform: translateY(-6px);
}
.tools {
  display: flex;
  gap: 10px;
  align-items: center;
  flex-wrap: wrap;
}
#bookView .top .title {
  flex: 1 1 100%;
}
#bookView .tools {
  flex: 1 1 100%;
}
#bookView .tools .search {
  flex: 1;
  min-width: 180px;
  width: auto;
}
.search {
  position: relative;
  width: 260px;
}
.search svg {
  position: absolute;
  left: 13px;
  top: 13px;
  color: var(--mute);
  width: 18px;
  height: 18px;
}
.search .input {
  padding-left: 40px;
  height: 44px;
  border-radius: 12px;
}
.search kbd {
  position: absolute;
  right: 10px;
  top: 12px;
  font: 11px var(--sans);
  color: var(--mute);
  border: 1px solid var(--line2);
  border-radius: 6px;
  padding: 1px 6px;
}
.datenav {
  display: flex;
  align-items: center;
  gap: 6px;
}

.strip {
  display: flex;
  gap: 6px;
  padding: 20px 28px 0;
}
.day {
  height: 70px;
  border-radius: 14px;
  border: 1px solid var(--line);
  background: transparent;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1px;
  color: var(--sub);
  transition: all 0.15s;
  position: relative;
}
.day:hover {
  border-color: var(--line2);
  background: var(--coal);
}
.day .dw {
  color: var(--mute);
}
.day .dn {
  color: var(--text);
}

.day.is-today:after {
  content: "";
  position: absolute;
  top: var(--doty, 3px); /* set by placeTodayDot: level with the weekday */
  right: 9px;
  width: 5px;
  height: 5px;
  border-radius: 50%;
}
.summary {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 28px;
  padding: 22px 28px 6px;
}
.stats {
  display: flex;
}
.stat .v {
  line-height: 1;
  color: var(--text);
}
.stat .v small {
  font-size: 16px;
  color: var(--mute);
  margin-left: 3px;
}
.stat .k {
  color: var(--mute);
  white-space: nowrap;
}

.pace {
  position: relative;
  height: 84px;
  display: flex;
  align-items: flex-end;
  gap: 3px;
  padding: 20px 0 16px;
  min-width: 0;
}
.pace .b {
  flex: 1;
  min-width: 4px;
  position: relative;
  height: 100%;
  display: flex;
  align-items: flex-end;
  cursor: pointer;
}
.pace .b i {
  display: block;
  width: 100%;
  border-radius: 3px 3px 1px 1px;
  min-height: 2px;
  transition: height 0.4s var(--ease);
}

.pace .b.zero i {
  opacity: 0.5;
}
.pace .b:hover i {
  filter: brightness(1.35);
}
.pace .b em {
  position: absolute;
  left: 0;
  color: var(--mute);
}
.pace .now {
  position: absolute;
  top: -2px;
  bottom: 12px;
  width: 1px;
}
.pace .now:before {
  content: "";
  position: absolute;
  top: -3px;
  left: -3px;
  width: 7px;
  height: 7px;
  border-radius: 50%;
}
.pace .gap {
  flex: 0.6;
  min-width: 6px;
}

.pace .lbl {
  position: absolute;
  top: 0;
  right: 0;
  color: var(--mute);
}
.bar {
  display: flex;
  gap: 10px;
  align-items: center;
  flex-wrap: wrap;
}
.bar .sp {
  flex: 1;
}
.sync {
  font-size: 11.5px;
  color: var(--mute);
  display: flex;
  align-items: center;
  gap: 7px;
}
.sync i {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--sage);
  box-shadow: 0 0 0 3px rgba(143, 174, 150, 0.15);
}
.sync.off i {
  background: var(--rust);
  box-shadow: 0 0 0 3px rgba(189, 122, 108, 0.15);
}
/* a save waiting for the Wi-Fi: amber */
.sync.saving i {
  background: #f59e0b;
  box-shadow: 0 0 0 3px rgba(245, 158, 11, 0.18);
}
.sync.demo i {
  background: var(--gold);
  box-shadow: 0 0 0 3px var(--gold-soft);
}
.list {
  flex: 1;
  overflow-y: auto;
  padding: 0 0 calc(40px + var(--sa-b));
  -webkit-overflow-scrolling: touch;
  scroll-behavior: smooth;
}
/* Each time section keeps its own layering, so the sticky time row doesn't stack above the list's
   scroll bar (on iPad the scroll bar slid under the time rows) */
.gsec {
  isolation: isolate;
}
.grp {
  position: sticky;
  top: 0;
  z-index: 2;
  display: flex;
  gap: 12px;
}
.grp .t {
  line-height: 1;
}
.grp .t small {
  font-family: var(--sans);
  color: var(--mute);
  margin-left: 4px;
}

.grp .ln {
  flex: 1;
  height: 1px;
  background: var(--line);
  transform: translateY(-4px);
}
.row {
  display: grid;
  align-items: center;
  gap: 16px;
  padding: 14px 14px 14px 16px;
  cursor: pointer;
  position: relative;
  transition: background 0.15s;
}

.row + .row:after {
  content: "";
  position: absolute;
  left: 60px;
  right: 14px;
  top: 0;
  height: 1px;
  background: var(--line);
}
.row.sel:after,
.row.sel + .row:after,
.row:hover:after,
.row:hover + .row:after {
  opacity: 0;
}
.dot {
  justify-self: center;
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--mute);
  box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.04);
}
.s-confirmed .dot {
  background: var(--gold);
}
.s-arrived .dot {
  background: var(--ivory);
  box-shadow: 0 0 0 3px rgba(231, 220, 198, 0.14);
}
.s-seated .dot {
  background: var(--sage);
  box-shadow: 0 0 0 3px rgba(143, 174, 150, 0.16);
}
.s-finished .dot {
  background: var(--faint);
}
.s-noshow .dot {
  background: var(--rust);
}
.row .nm {
  text-overflow: ellipsis;
  display: flex;
  align-items: center;
  gap: 8px;
}
.row .nm .vip {
  width: 14px;
  height: 14px;
}
.row .sub {
  color: var(--mute);
  margin-top: 7px;
  display: flex;
  gap: 10px;
  align-items: center;
}
.row .sub .note {
  font-style: italic;
  color: var(--sub);
}
.row .meta {
  color: var(--sub);
}
.row .meta .p {
  display: flex;
  align-items: center;
  gap: 5px;
}
.row .meta .p svg {
  width: 15px;
  height: 15px;
}
.row .meta .tb {
  text-align: center;
  border: 1px solid var(--line2);
  border-radius: 8px;
}
.row .meta .tb.none {
  border-style: dashed;
  color: var(--mute);
}
.st {
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--mute);
  white-space: nowrap;
}
.s-seated .st {
  color: var(--sage);
}
.s-confirmed .st {
  color: var(--gold);
}
.s-arrived .st {
  color: var(--ivory);
}
.s-noshow .st {
  color: var(--rust);
}
.s-finished .nm,
.s-cancelled .nm,
.s-noshow .nm {
  color: var(--sub);
}
.s-cancelled .nm {
  text-decoration-color: var(--faint);
}
.s-finished,
.s-cancelled,
.s-noshow {
  opacity: 0.72;
}
.badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  height: 20px;
  padding: 0 8px;
  border-radius: 999px;
  font-size: 10.5px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  border: 1px solid var(--line2);
  color: var(--sub);
  white-space: nowrap;
}

.badge.late {
  border-color: rgba(189, 122, 108, 0.4);
  color: var(--rust);
}
.badge.seat {
  border-color: rgba(143, 174, 150, 0.35);
  color: var(--sage);
}
.empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 70px 30px;
  color: var(--mute);
  gap: 10px;
}
.empty .orn {
  font-family: var(--script);
  font-size: 64px;
  color: var(--gold-lo);
  line-height: 0.6;
}
.empty h3 {
  margin: 0;
  color: var(--sub);
}
.skel {
  height: 58px;
  margin: 10px 28px;
  border-radius: 12px;
  background: linear-gradient(90deg, var(--coal), var(--slate), var(--coal));
  background-size: 200% 100%;
  animation: sk 1.4s infinite;
}
@keyframes sk {
  to {
    background-position: -200% 0;
  }
}
/* ---------- Detail ---------- */
.dp {
  height: 100%;
  display: flex;
  flex-direction: column;
}
.dp-scroll {
  flex: 1;
  overflow-y: auto;
  padding: calc(26px + var(--sa-t)) 28px 24px;
}

.contact {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 16px;
  font-size: 13.5px;
  color: var(--sub);
}
.contact a {
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 7px;
}
.contact a:hover {
  color: var(--gold-hi);
}
.contact svg {
  width: 15px;
  height: 15px;
  color: var(--mute);
}
.stepper {
  display: flex;
  align-items: flex-start;
  margin: 26px 0 22px;
  position: relative;
}
.stp {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  position: relative;
  font-size: 10px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--faint);
  cursor: pointer;
}
.stp:before {
  content: "";
  position: absolute;
  top: 6px;
  left: -50%;
  right: 50%;
  height: 1px;
  background: var(--line2);
}
.stp:first-child:before {
  display: none;
}
.stp i {
  width: 13px;
  height: 13px;
  border-radius: 50%;
  border: 1.5px solid var(--faint);
  background: var(--coal);
  position: relative;
  z-index: 1;
  transition: all 0.2s;
}

.stp:hover {
  color: var(--sub);
}
.voidbanner {
  margin: 22px 0;
  border: 1px solid rgba(189, 122, 108, 0.3);
  background: rgba(189, 122, 108, 0.06);
  border-radius: 14px;
  padding: 14px 16px;
  display: flex;
  align-items: center;
  gap: 12px;
  color: var(--rust);
  font-size: 13.5px;
}
.voidbanner.grey {
  border-color: var(--line2);
  background: var(--slate);
  color: var(--sub);
}
.dp-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}
.dp-actions .btn {
  height: 50px;
}
.dp-actions .wide {
  grid-column: 1/-1;
}
.facts {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  border-radius: 16px;
  margin: 22px 0 0;
  overflow: hidden;
}
.fact {
  border-right: 1px solid var(--line);
  text-align: center;
  min-width: 0;
}
.fact:last-child {
  border: 0;
}
.fact .k {
  color: var(--mute);
}
.fact .v {
  margin-top: 4px;
  line-height: 1.1;
  white-space: nowrap;
  overflow: hidden;
}
.fact .v small {
  font-family: var(--sans);
  letter-spacing: 0.12em;
  color: var(--mute);
}
.fact.tap {
  cursor: pointer;
}
.fact.tap:hover {
  background: var(--slate);
}
.fact.tap .v.none {
  color: var(--mute);
  font-size: 18px;
}
.sec {
  margin-top: 24px;
}
.sec h4 {
  margin: 0 0 10px;
  color: var(--mute);
  display: flex;
  align-items: center;
  gap: 10px;
}
.sec h4:after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--line);
}
.notebox {
  border-left: 2px solid var(--gold-line);
  padding: 2px 0 2px 14px;
}
.gcard {
  border-radius: 16px;
  padding: 16px;
  cursor: pointer;
  transition: border-color 0.15s;
}
.gcard:hover {
  border-color: var(--gold-line);
}
.gcard .gtop {
  display: flex;
  align-items: center;
  gap: 12px;
}
.gcard .gtop .t {
  flex: 1;
}
.gcard .gtop b {
  font-weight: 500;
}
.gcard .mini {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  margin-top: 14px;
}
.gcard .mini div {
  border-radius: 10px;
  padding: 9px 10px;
}
.gcard .mini .k {
  color: var(--mute);
}
.hist {
  display: flex;
  flex-direction: column;
}
.hist .h {
  display: grid;
  grid-template-columns: 96px 1fr auto;
  gap: 12px;
  padding: 10px 0;
  border-bottom: 1px solid var(--line);
  font-size: 13.5px;
  align-items: center;
  cursor: pointer;
}
.hist .h:last-child {
  border: 0;
}
.hist .h .d {
  color: var(--sub);
}
.hist .h:hover .d {
  color: var(--gold-hi);
}
.metaline {
  font-size: 12px;
  color: var(--mute);
  line-height: 1.8;
  margin-top: 22px;
}
.dp-foot {
  display: flex;
  gap: 8px;
  padding: 14px 20px calc(14px + var(--sa-b));
}
.dp-foot .sp {
  flex: 1;
}
.dp-empty {
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 40px;
  gap: 14px;
  color: var(--mute);
}
.dp-empty .crest-sm {
  font-family: var(--script);
  font-size: 72px;
  color: var(--gold-lo);
  line-height: 0.7;
}
.dp-empty p {
  margin: 0;
  max-width: 260px;
  font-size: 13.5px;
}
/* ---------- Layers (sheets, drawers, dialogs) ---------- */
.layer {
  position: fixed;
  inset: 0;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
}
.layer .scrim {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.62);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  opacity: 0;
  transition: opacity 0.22s;
}
.layer .panel {
  position: relative;
  border: 1px solid var(--line2);
  border-radius: 22px;
  width: min(720px, 100%);
  max-height: min(900px, 100%);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  box-shadow: 0 40px 80px -30px rgba(0, 0, 0, 0.9);
  transform: translateY(14px) scale(0.985);
  opacity: 0;
  transition:
    transform 0.26s var(--ease),
    opacity 0.2s;
}
.layer.in .scrim {
  opacity: 1;
}
.layer.in .panel {
  transform: none;
  opacity: 1;
}
.layer.dialog .panel {
  width: min(420px, 100%);
}
.layer.drawer {
  justify-content: flex-end;
  padding: 0;
}
.layer.drawer .panel {
  height: 100%;
  max-height: none;
  width: min(460px, 100%);
  border-radius: 0;
  border-width: 0 0 0 1px;
  transform: translateX(30px);
}
.layer.drawer.in .panel {
  transform: none;
}
.sh-head {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 22px 24px 14px;
}
.sh-head h3 {
  margin: 0;
  flex: 1;
}
.sh-body {
  flex: 1;
  overflow-y: auto;
  padding: 6px 24px 24px;
  display: flex;
  flex-direction: column;
  gap: 22px;
}
.sh-foot {
  display: flex;
  gap: 10px;
  align-items: center;
  padding: 14px 24px calc(14px + var(--sa-b));
}
.sh-foot .sp {
  flex: 1;
}
.grid2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}
.welcome {
  display: flex;
  gap: 12px;
  align-items: center;
  border: 1px solid var(--gold-line);
  border-radius: 14px;
  padding: 12px 14px;
  font-size: 13.5px;
  animation: fadeup 0.3s var(--ease);
}
.welcome b {
  color: var(--gold-hi);
  font-weight: 500;
}
.svc {
  font-size: 11px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--mute);
  margin: 4px 0 8px;
}
.times .chip {
  min-width: 72px;
  position: relative;
}
.stepnum {
  display: inline-flex;
  align-items: center;
  border: 1px solid var(--line2);
  border-radius: 10px;
  overflow: hidden;
  height: 38px;
}
.stepnum button {
  width: 38px;
  height: 100%;
  color: var(--sub);
}
.stepnum button:hover {
  background: var(--slate);
  color: var(--text);
}
.stepnum b {
  min-width: 40px;
  text-align: center;
}
.warn {
  font-size: 12.5px;
  color: var(--rust);
  min-height: 0;
}
.dlg-body {
  padding: 6px 24px 8px;
  color: var(--sub);
  font-size: 14.5px;
}
@keyframes fadeup {
  from {
    opacity: 0;
    transform: translateY(6px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}
/* ---------- Toasts ---------- */
#toasts {
  position: fixed;
  left: 50%;
  top: calc(18px + var(--sa-t));
  transform: translateX(-50%);
  z-index: 80;
  display: flex;
  flex-direction: column;
  gap: 8px;
  align-items: center;
  pointer-events: none;
  width: min(560px, calc(100% - 32px));
}
.toast {
  pointer-events: auto;
  display: flex;
  align-items: center;
  gap: 14px;
  background: var(--toast);
  border: 1px solid var(--line2);
  border-radius: 14px;
  padding: 12px 14px 12px 16px;
  box-shadow: 0 20px 40px -14px rgba(0, 0, 0, 0.8);
  font-size: 14px;
  animation: fadeup 0.25s var(--ease);
  width: 100%;
}
.toast .tx {
  flex: 1;
}
.toast .ic {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: var(--gold-soft);
  color: var(--gold-hi);
}
.toast .ic svg {
  width: 14px;
  height: 14px;
}
.toast.err .ic {
  background: rgba(189, 122, 108, 0.14);
  color: var(--rust);
}
.toast button {
  color: var(--gold-hi);
  font-weight: 600;
  font-size: 13px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 6px 8px;
  border-radius: 8px;
}
.toast button:hover {
  background: var(--gold-soft);
}
/* ---------- Guests / Audit / Staff ---------- */
.split {
  flex: 1;
  display: grid;
  grid-template-columns: minmax(300px, 380px) 1fr;
  /* the panels are exactly the split's height, whatever is in them: in iPad Safari the row grew with the right
     panel's content, so picking another booking on Texts resized the list under the finger and the next swipe
     stuck until the finger was lifted */
  grid-template-rows: minmax(0, 1fr);
  min-height: 0;
  margin-top: 18px;
}
.split > .l,
.split > .r {
  min-height: 0;
}
.split .l {
  overflow-y: auto;
  padding: 10px 0 calc(30px + var(--sa-b));
}
.split .r {
  overflow-y: auto;
  min-width: 0;
}
.gl {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 22px;
  cursor: pointer;
  position: relative;
}
.gl:hover {
  background: var(--coal);
}

.gl.sel:before {
  content: "";
  position: absolute;
  left: 0;
  top: 12px;
  bottom: 12px;
  width: 2px;
  background: var(--gold);
  border-radius: 2px;
}
.gl .t {
  flex: 1;
  min-width: 0;
}
.gl .t b {
  font-weight: 500;
  display: block;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.gl .t span {
  font-size: 12.5px;
  color: var(--mute);
}
.gl .c {
  text-align: right;
  line-height: 1;
}
.gl .c small {
  display: block;
  font-family: var(--sans);
  font-size: 9.5px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--mute);
}
.profile {
  padding: 30px 34px calc(40px + var(--sa-b));
}
.ph {
  display: flex;
  gap: 20px;
  align-items: center;
}
.ph h2 {
  margin: 4px 0 6px;
}
.kpis {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 1px;
  border-radius: 16px;
  overflow: hidden;
  margin-top: 26px;
}
.kpis div {
  padding: 16px 14px;
}
.kpis .v {
  line-height: 1;
}
.kpis .k {
  color: var(--mute);
  margin-top: 7px;
}
.timeline {
  position: relative;
  margin-left: 6px;
}
.tl {
  position: relative;
  padding: 0 0 18px 26px;
  cursor: pointer;
}
.tl:before {
  content: "";
  position: absolute;
  left: 4px;
  top: 8px;
  bottom: -6px;
  width: 1px;
  background: var(--line2);
}
.tl:last-child:before {
  display: none;
}
.tl .dot {
  position: absolute;
  left: 0;
  top: 5px;
}
.tl .x {
  font-size: 12.5px;
  color: var(--mute);
  margin-top: 2px;
}
.tl:hover .d {
  color: var(--gold-hi);
}
.auditwrap {
  flex: 1;
  overflow-y: auto;
  margin-top: 18px;
}
.aday {
  font-size: 10.5px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
}
.ae {
  display: grid;
  grid-template-columns: 70px 34px minmax(0, 1fr) auto;
  gap: 14px;
  align-items: flex-start;
  padding: 13px 0;
  border-bottom: 1px solid var(--line);
}
.ae .tm {
  font-size: 12.5px;
  color: var(--mute);
  padding-top: 6px;
}
.ae .tx {
  min-width: 0;
  padding-top: 2px;
}
.ae .tx b {
  font-weight: 500;
}
.ae .tx .what {
  color: var(--sub);
}
.ae .ch {
  margin-top: 6px;
  display: flex;
  flex-direction: column;
  gap: 3px;
}
.ae .ch div {
  font-size: 12.5px;
  color: var(--mute);
}
.ae .ch em {
  font-style: normal;
  color: var(--sub);
}
.ae .ch s {
  color: var(--faint);
}
.ae .ch ins {
  text-decoration: none;
  color: var(--ivory);
}
.ae .dev {
  font-size: 11.5px;
  color: var(--faint);
  text-align: right;
  padding-top: 5px;
  max-width: 160px;
}
.atype {
  font-size: 10px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  padding: 2px 7px;
  border-radius: 6px;
  margin-left: 8px;
  border: 1px solid var(--line2);
  vertical-align: 2px;
}
.atype.create {
  color: var(--gold-hi);
  border-color: var(--gold-line);
}
.atype.delete,
.atype.failed {
  color: var(--rust);
  border-color: rgba(189, 122, 108, 0.35);
}
.atype.status {
  color: var(--sage);
  border-color: rgba(143, 174, 150, 0.3);
}
.filters {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  padding: 18px 28px 0;
}
.filters .input {
  height: 40px;
  width: auto;
  min-width: 150px;
  font-size: 14px;
}
.stafflist {
  overflow-y: auto;
  flex: 1;
  margin-top: 18px;
}
.srow {
  display: grid;
  /* the last sign-in column is wide enough for "Last in Nov 22, 11:07 PM" on one line; the role sits left of it */
  grid-template-columns: 44px minmax(0, 1fr) 120px 200px auto;
  gap: 16px;
  align-items: center;
  padding: 16px 0;
  border-bottom: 1px solid var(--line);
}
.srow .t b {
  font-weight: 500;
}
.srow .t div {
  font-size: 12.5px;
  color: var(--mute);
}
.srow.off {
  opacity: 0.5;
}
.srow .slast {
  white-space: nowrap;
}
.role {
  font-size: 10.5px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--sub);
}
.role.admin {
  color: var(--gold-hi);
}
.back {
  display: none;
}

/* ---------- Responsive ---------- */
@media (max-width: 1279px) {
  .app,
  .app[data-view] {
    grid-template-columns: var(--rail-col) minmax(0, 1fr) 0;
  }
  aside#detail {
    display: none;
  }
  .search {
    width: 210px;
  }
}
@media (max-width: 980px) {
  .summary {
    grid-template-columns: 1fr;
    gap: 16px;
  }
  .kpis {
    grid-template-columns: repeat(3, 1fr);
  }
  .srow {
    grid-template-columns: 44px 1fr auto;
  }
  .srow .hide-m {
    display: none;
  }
}
@media (max-width: 760px) {
  html,
  body {
    font-size: 15px;
  }
  .app,
  .app[data-view] {
    grid-template-columns: minmax(0, 1fr);
  }
  .rail {
    display: none;
  }

  .tabbar {
    display: flex;
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 40;
    padding: 0 6px var(--sa-b);
    backdrop-filter: blur(18px) saturate(1.2);
    -webkit-backdrop-filter: blur(18px) saturate(1.2);
    justify-content: space-around;
  }
  .tabbar .nav {
    height: 58px;
  }
  .tabbar .nav.on:before {
    left: 22px;
    right: 22px;
    top: -1px;
    bottom: auto;
    width: auto;
    height: 2px;
  }
  .fab {
    width: 52px;
    height: 52px;
    border-radius: 50%;
    display: grid;
    place-items: center;
    transform: translateY(-6px);
  }
  .fab svg {
    width: 24px;
    height: 24px;
    stroke-width: 2;
  }
  .top {
    padding: calc(14px + var(--sa-t)) 18px 0;
  }
  .tools .search,
  .tools .newbtn {
    display: none;
  }
  .strip {
    padding: 16px 18px 0;
  }
  .day {
    height: 64px;
  }
  .summary {
    padding: 18px 18px 4px;
  }
  .stats {
    scrollbar-width: none;
  }
  .bar {
    gap: 8px;
  }
  .bar .seg {
    overflow-x: auto;
    max-width: 100%;
    scrollbar-width: none;
  }
  .msearch {
    display: block !important;
    width: 100%;
  }
  .row {
    padding: 13px 10px;
    gap: 10px;
  }
  .row + .row:after {
    left: 50px;
  }
  .layer {
    padding: 0;
    align-items: flex-end;
  }
  .layer .panel {
    width: 100%;
    max-height: calc(100% - var(--sa-t) - 12px);
    border-radius: 22px 22px 0 0;
    border-width: 1px 0 0;
    transform: translateY(40px);
  }
  .layer.full .panel {
    height: calc(100% - var(--sa-t) - 12px);
  }
  .layer.drawer .panel {
    width: 100%;
    height: calc(100% - var(--sa-t) - 12px);
    border-radius: 22px 22px 0 0;
    border-width: 1px 0 0;
    transform: translateY(40px);
  }
  .layer.dialog {
    align-items: center;
    padding: 20px;
  }
  .layer.dialog .panel {
    border-radius: 20px;
    border-width: 1px;
  }
  .grid2 {
    grid-template-columns: 1fr;
  }
  .dp-scroll {
    padding: 22px 20px 20px;
  }

  .facts {
    grid-template-columns: repeat(2, 1fr);
  }
  .fact:nth-child(2) {
    border-right: 0;
  }
  .fact:nth-child(-n + 2) {
    border-bottom: 1px solid var(--line);
  }
  .split {
    grid-template-columns: 1fr;
  }
  .split .r {
    display: none;
  }
  .split.showing .l {
    display: none;
  }
  .split.showing .r {
    display: block;
  }
  .back {
    display: inline-flex;
  }
  .profile {
    padding: 20px 20px 40px;
  }
  .kpis {
    grid-template-columns: repeat(3, 1fr);
  }

  .ae {
    grid-template-columns: 52px minmax(0, 1fr);
    gap: 10px;
  }
  .ae .av,
  .ae .dev {
    display: none;
  }
  .filters {
    padding: 14px 18px 0;
  }
  .filters .input {
    flex: 1;
    min-width: 0;
  }

  #toasts {
    top: calc(10px + var(--sa-t));
  }
  .sh-head {
    padding: 18px 20px 10px;
  }
  .sh-body {
    padding: 6px 20px 20px;
  }
  .sh-foot {
    padding: 12px 20px calc(12px + var(--sa-b));
  }
}
.msearch {
  display: none;
}
@media (prefers-reduced-motion: reduce) {
  * {
    animation: none !important;
    transition: none !important;
  }
}
/* ---------- Additions for the Airtable model ---------- */
.s-checkdate .dot {
  background: transparent;
  border: 1.5px solid var(--gold);
  box-shadow: 0 0 0 3px var(--gold-soft);
}
.s-waiting .dot {
  background: var(--ivory);
  box-shadow: 0 0 0 3px rgba(231, 220, 198, 0.14);
}
.s-hold .st,
.s-checkdate .st {
  color: var(--gold);
}
.s-waiting .st {
  color: var(--ivory);
}
.badge.warn {
  border-color: var(--gold-line);
  color: var(--gold-hi);
}
.badge.wl {
  border-color: rgba(231, 220, 198, 0.3);
  color: var(--ivory);
}
.ordn {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  border: 1px solid rgba(231, 220, 198, 0.35);
  flex: none;
}
.stars {
  display: inline-flex;
  gap: 2px;
  vertical-align: -2px;
}
.stars svg {
  width: 14px;
  height: 14px;
  fill: none;
  stroke-width: 1.5;
}

.stars.lg svg {
  width: 22px;
  height: 22px;
}
.stars.edit button {
  padding: 3px;
  border-radius: 6px;
}
.stars.edit button:hover svg {
  fill: var(--gold-soft);
}
.flag {
  margin: 22px 0 0;
  border: 1px solid var(--gold-line);
  background: var(--gold-soft);
  border-radius: 14px;
  padding: 13px 16px;
  display: flex;
  align-items: center;
  gap: 12px;
  color: var(--gold-hi);
  font-size: 13.5px;
}
.flag .sp {
  flex: 1;
}

.picker {
  position: relative;
}
.results {
  margin-top: 8px;
  border: 1px solid var(--line2);
  border-radius: 14px;
  overflow: hidden;
  background: var(--ink);
}
.results button {
  display: flex;
  width: 100%;
  align-items: center;
  gap: 12px;
  padding: 11px 14px;
  text-align: left;
  border-bottom: 1px solid var(--line);
}
.results button:last-child {
  border-bottom: 0;
}
.results button:hover,
.results button.hl {
  background: var(--slate);
}
.results .t {
  flex: 1;
  min-width: 0;
}
.results .t b {
  font-weight: 500;
  display: block;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.results .t span {
  font-size: 12.5px;
  color: var(--mute);
}
.results .new {
  color: var(--gold-hi);
}
.custcard {
  display: flex;
  align-items: center;
  gap: 14px;
  border-radius: 16px;
  padding: 14px 16px;
}
.custcard .t {
  flex: 1;
  min-width: 0;
}
.custcard .t b {
  font-weight: 500;
  font-size: 16px;
}
.custcard .t div {
  font-size: 12.5px;
  color: var(--mute);
  margin-top: 2px;
}
.custcard .ins {
  font-size: 12.5px;
  color: var(--sub);
  margin-top: 6px;
}
.newcust {
  border: 1px dashed var(--line2);
  border-radius: 16px;
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.quick {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 8px;
}
.quick button {
  height: 28px;
  padding: 0 10px;
  border-radius: 8px;
  border: 1px solid var(--line);
  font-size: 12px;
}

.activity .a {
  display: grid;
  grid-template-columns: 96px 1fr;
  gap: 10px;
  padding: 8px 0;
  border-bottom: 1px solid var(--line);
  font-size: 12.5px;
}
.activity .a:last-child {
  border: 0;
}
.activity .a .w {
  color: var(--mute);
}
.activity .a em {
  font-style: normal;
  color: var(--sub);
}
.wlhead {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 16px;
  border: 1px solid var(--line);
  border-radius: 14px;
  font-size: 13px;
  color: var(--sub);
}
.wlhead .sp {
  flex: 1;
}
.info {
  display: grid;
  grid-template-columns: 120px 1fr;
  gap: 10px 18px;
  font-size: 14px;
}
.info dt {
  font-size: 10.5px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--mute);
  padding-top: 3px;
}
.info dd {
  margin: 0;
  color: var(--text);
  white-space: pre-line;
}
.info dd.none {
  color: var(--faint);
}
.bday {
  color: var(--gold-hi);
}
.mode-switch {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}
.mode-switch .btn {
  height: 64px;
  flex-direction: column;
  gap: 2px;
  border-radius: 14px;
}
.mode-switch .btn small {
  font-size: 11px;
  color: var(--mute);
  font-weight: 400;
}

.remember {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 13px;
  color: var(--sub);
  cursor: pointer;
}
.remember input {
  width: 21px;
  height: 21px;
  accent-color: var(--sel-bg, #2563eb);
}
@media (max-width: 760px) {
  .info {
    grid-template-columns: 96px 1fr;
  }
}
.toast {
  animation-name: fadedown;
}
@keyframes fadedown {
  from {
    opacity: 0;
    transform: translateY(-6px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}
.row .ordn {
  justify-self: center;
}
main#main {
  container-type: inline-size;
}
@container (max-width:900px) {
  .tools .lbl-long {
    display: none;
  }
  .tools .newbtn.ghost {
    width: 44px;
    padding: 0;
  }
}
@container (min-width:901px) {
  .tools .lbl-short {
    display: none;
  }
}
.grp.wl .t {
  font-family: var(--sans);
  font-size: 11px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
}
.kpis .v {
  min-height: 30px;
  display: flex;
  align-items: flex-end;
}
/* Official logo */
.crest .logo {
  position: relative;
  width: 72%;
  height: auto;
  transform: translateY(-2px);
  filter: drop-shadow(0 2px 24px rgba(0, 0, 0, 0.6));
}
.mono img {
  position: relative;
  height: auto;
}
.orn img {
  width: 64px;
  height: auto;
  opacity: 0.55;
}
.crest-sm img {
  width: 76px;
  height: auto;
  opacity: 0.5;
}
.splash {
  height: 100vh;
  height: 100dvh;
  display: grid;
  place-items: center;
}
.splash img {
  width: min(300px, 64vw);
  opacity: 0;
  animation: splash 1.2s var(--ease) 0.1s forwards;
}
@keyframes splash {
  to {
    opacity: 0.85;
  }
}
.lg-card .rule {
  white-space: nowrap;
}
.lg-card .rule:before,
.lg-card .rule:after {
  width: auto;
  flex: 1 1 42px;
  max-width: 42px;
  min-width: 10px;
}
@media (max-width: 420px) {
  .lg-card .rule {
    letter-spacing: 0.2em;
    font-size: 10.5px;
  }
}

/* Display type: Playfair Display, lining + tabular figures so times and counts line up */

.notebox {
  color: var(--ivory);
  line-height: 1.55;
}
/* Sub-line under the guest name: wrap instead of clipping; italics get room for their overhang */
.row .sub {
  flex-wrap: wrap;
  white-space: normal;
  overflow: visible;
  row-gap: 5px;
  column-gap: 10px;
  line-height: 1.4;
}
.row .sub .note {
  white-space: normal;
  overflow: hidden;
  text-overflow: clip;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  padding-right: 0.2em;
  min-width: 0;
  flex: 1 1 220px;
}
.row .sub .badge {
  flex: none;
}
.notebox,
.tl .x i,
.custcard .ins i,
.welcome i {
  padding-right: 0.15em;
}
/* ===== Color: one muted jewel tone per status ===== */
:root {
  --c-booked: #8fa6c8;
  --c-confirmed: #d0ae66;
  --c-hold: #d9a05b;
  --c-checkdate: #d48a9a;
  --c-waiting: #ab9be0;
  --c-seated: #7dbb91;
  --c-finished: #8a8680;
  --c-noshow: #d07563;
  --c-cancelled: #9a8784;
  --c-lunch: #d9b26a;
  --c-dinner: #c48aa0;
}
.s-booked {
  --c: var(--c-booked);
}
.s-confirmed {
  --c: var(--c-confirmed);
}
.s-hold {
  --c: var(--c-hold);
}
.s-checkdate {
  --c: var(--c-checkdate);
}
.s-waiting {
  --c: var(--c-waiting);
}
.s-seated {
  --c: var(--c-seated);
}
.s-finished {
  --c: var(--c-finished);
}
.s-noshow {
  --c: var(--c-noshow);
}
.s-cancelled {
  --c: var(--c-cancelled);
}

/* status dots */
.row .dot,
.tl .dot {
  background: var(--c);
  border: 0;
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--c) 22%, transparent);
}
.s-booked .dot {
  background: transparent;
  border: 1.5px solid var(--c);
}
.s-hold .dot {
  background: transparent;
  border: 1.5px dashed var(--c);
}
.s-cancelled .dot {
  background: transparent;
  border: 1.5px solid var(--c);
  box-shadow: none;
}
.s-finished .dot {
  box-shadow: none;
  opacity: 0.7;
}
/* status label in each row becomes a tinted pill */
.row .st {
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 10px;
  letter-spacing: 0.12em;
  border: 1px solid color-mix(in srgb, var(--c) 32%, transparent);
}
.hist .st,
.tl .st {
  color: var(--c);
}

/* filter + service pills */
.seg button.tone {
  display: inline-flex;
  align-items: center;
}
.seg .sw {
  display: inline-block;
  border-radius: 50%;
  background: var(--c);
  margin-right: 8px;
  flex: none;
  box-shadow: 0 0 0 2px color-mix(in srgb, var(--c) 22%, transparent);
}
.f-all {
  --c: var(--gold);
}
.f-upcoming {
  --c: var(--c-booked);
}
.f-waitlist {
  --c: var(--c-waiting);
}
.f-seated {
  --c: var(--c-seated);
}
.f-finished {
  --c: var(--c-finished);
}
.f-void {
  --c: var(--c-noshow);
}
.svc-0 {
  --c: var(--gold);
}
.svc-1 {
  --c: var(--c-lunch);
}
.svc-2 {
  --c: var(--c-dinner);
}
.f-all .sw {
  display: none;
}
.seg button.tone.on {
  color: var(--c);
}
.seg button.tone.on .n {
  color: var(--c);
  opacity: 0.85;
}
.seg button.tone:not(.on):hover {
  color: var(--text);
}
/* headline numbers */

.stat.t-seated .k,
.stat.t-booked .k,
.stat.t-waiting .k {
  display: flex;
  align-items: center;
  gap: 6px;
}
.stat.t-seated .k:before,
.stat.t-booked .k:before,
.stat.t-waiting .k:before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 50%;
  flex: none;
}
.stat.t-seated .k:before {
  background: var(--c-seated);
}
.stat.t-booked .k:before {
  background: var(--c-booked);
}
.stat.t-waiting .k:before {
  background: var(--c-waiting);
}
/* finish button + detail status */

.ordn {
  border-color: color-mix(in srgb, var(--c-waiting) 55%, transparent);
  color: var(--c-waiting);
  background: color-mix(in srgb, var(--c-waiting) 10%, transparent);
}
.grp.wl .t {
  color: var(--c-waiting);
}
/* name-tinted avatars (VIPs and admins stay gold) */
.avatar.tinted {
  color: var(--c);
  border-color: color-mix(in srgb, var(--c) 40%, transparent);
  background: color-mix(in srgb, var(--c) 11%, var(--slate));
}
/* audit types */
.atype.create {
  --c: var(--c-confirmed);
}
.atype.update {
  --c: var(--c-booked);
}
.atype.status {
  --c: var(--c-seated);
}
.atype.delete,
.atype.failed {
  --c: var(--c-noshow);
}
.atype.customer {
  --c: var(--c-waiting);
}
.atype.auth {
  --c: var(--c-finished);
}
.atype.admin {
  --c: var(--c-checkdate);
}
.atype {
  color: var(--c);
  border-color: color-mix(in srgb, var(--c) 40%, transparent);
  background: color-mix(in srgb, var(--c) 10%, transparent);
}
/* ===== Color for choices and variable data ===== */
:root {
  --f-time: #8fa6c8;
  --f-party: #7fb6c2;
  --f-table: #d9a05b;
  --f-server: #ab9be0;
  --f-request: #d48a9a;
}
#edTimes,
.fx-time,
.kx-time {
  --c: var(--f-time);
}
#edParty,
#wkParty,
.fx-party,
.kx-party {
  --c: var(--f-party);
}
#edTableS,
.ct-table,
.fx-table {
  --c: var(--f-table);
}
.ct-server,
.fx-server {
  --c: var(--f-server);
}
.kx-visits {
  --c: var(--gold-hi);
}
.kx-cancel {
  --c: var(--c-cancelled);
}
/* selected chips take their field's color (gold everywhere else) */

.chip.on small {
  color: var(--c, var(--gold));
}
#edParty .stepnum b,
#wkParty .stepnum b {
  color: var(--f-party);
}
.role-admin {
  --c: var(--gold);
}
.role-manager {
  --c: var(--c-booked);
}
.role-host {
  --c: var(--f-party);
}
.role.manager {
  color: var(--c-booked);
}
.role.host {
  color: var(--f-party);
}
.mode-seat {
  --c: var(--c-seated);
}
.mode-wait {
  --c: var(--c-waiting);
}
.mode-switch .btn.on {
  border-color: var(--c);
  background: color-mix(in srgb, var(--c) 14%, transparent);
  color: var(--c);
}
.quick button {
  color: color-mix(in srgb, var(--f-request) 75%, var(--mute));
  border-color: color-mix(in srgb, var(--f-request) 22%, transparent);
}
.quick button:hover {
  color: var(--f-request);
  border-color: color-mix(in srgb, var(--f-request) 55%, transparent);
  background: color-mix(in srgb, var(--f-request) 10%, transparent);
}
/* rows: party, table, server */
.row .meta .p {
  color: var(--f-party);
}
.row .meta .p svg {
  color: color-mix(in srgb, var(--f-party) 70%, transparent);
}
.row .meta .tb:not(.none) {
  color: var(--f-table);
}
.row .sub .srv {
  color: var(--f-server);
}
.s-finished .meta .p,
.s-cancelled .meta .p,
.s-noshow .meta .p {
  color: var(--sub);
}
/* detail facts + profile numbers */
.fact .v:not(.none) {
  color: var(--c, var(--text));
}
.fact.fx-time .v small {
  color: color-mix(in srgb, var(--f-time) 70%, var(--mute));
}
.kpis .kx-visits .v,
.kpis .kx-party .v,
.kpis .kx-time .v,
.kpis .kx-cancel .v,
.gcard .mini .kx-visits .v,
.gcard .mini .kx-cancel .v {
  color: var(--c);
}
.gl .c {
  color: var(--gold-hi);
}
.day .dc {
  color: var(--mute);
}
.day:not(.on) .dc:not(:empty) {
  color: color-mix(in srgb, var(--gold) 70%, var(--mute));
}
.grp .m {
  color: color-mix(in srgb, var(--f-party) 55%, var(--mute));
}
/* ===== Booking form: sectioned cards ===== */
.sh-body.ed {
  gap: 14px;
  background: linear-gradient(180deg, transparent, rgba(255, 255, 255, 0.008));
}
.ecard {
  display: flex;
  flex-direction: column;
}
.ecard > header {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 0 0 -2px;
}
.ecard > header h5 {
  margin: 0;
}
.ecard > header .opt {
  margin-left: auto;
  font-size: 10.5px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--faint);
}
.en {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-size: 11.5px;
  font-weight: 600;
  border: 1px solid var(--gold-line);
  flex: none;
}
.erow {
  display: grid;
  grid-template-columns: 118px minmax(0, 1fr);
  gap: 16px;
  align-items: start;
}
.erow + .erow {
  padding-top: 18px;
  border-top: 1px solid var(--line);
}
.el {
  color: var(--mute);
  padding-top: 11px;
}
.ev {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.ev-inline {
  flex-direction: row;
  align-items: center;
  gap: 18px;
  flex-wrap: wrap;
}
.bigparty {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin-left: 6px;
  padding-left: 14px;
  border-left: 1px solid var(--line);
  font-size: 12px;
  color: var(--mute);
}
.bigparty.on .stepnum {
  border-color: var(--f-party);
  background: color-mix(in srgb, var(--f-party) 12%, transparent);
}

.dchip {
  min-width: 0;
}

#edSvc {
  align-self: flex-start;
}
#edSvc .n {
  font-size: 11px;
  color: var(--mute);
  margin-left: 6px;
}
.hours {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.hr {
  display: grid;
  grid-template-columns: 52px minmax(0, 1fr);
  align-items: center;
  gap: 8px;
}
.hl small {
  font-family: var(--sans);
  font-size: 9.5px;
  letter-spacing: 0.14em;
  color: var(--mute);
  margin-left: 3px;
}
.hours .chips {
  gap: 6px;
}
.hours .times .chip {
  min-width: 64px;
  height: 36px;
  font-size: 13.5px;
}
.othertime {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  font-size: 13px;
  padding-top: 4px;
}
.sumbar {
  flex: 1;
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  font-size: 13.5px;
  color: var(--sub);
}
.sumbar b {
  font-weight: 500;
  color: var(--text);
}
.sumbar i {
  font-style: normal;
  color: var(--faint);
}
.sumbar .sx-party {
  color: var(--f-party);
}
.sumbar .sx-time {
  color: var(--f-time);
}
.sumbar .sx-date {
  color: var(--gold-hi);
}
@media (max-width: 760px) {
  .erow {
    grid-template-columns: 1fr;
    gap: 8px;
  }
  .el {
    padding-top: 0;
  }
  .bigparty {
    margin-left: 0;
    padding-left: 0;
    border-left: 0;
  }
  .hr {
    grid-template-columns: 42px minmax(0, 1fr);
  }
  .hours .times .chip {
    min-width: 58px;
    padding: 0 8px;
  }
  .sh-foot {
    flex-wrap: wrap;
  }
  .sumbar {
    flex-basis: 100%;
    order: -1;
    font-size: 12.5px;
  }
}
/* ===== Themed calendar ===== */
.layer.calsheet .panel {
  width: min(440px, 100%);
}
.cal {
  padding: 2px 22px 16px;
}
.cal-head {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 10px;
}
.cal-head .btn {
  width: 40px;
  height: 40px;
  padding: 0;
}
.cal-title {
  flex: 1;
  text-align: center;
  display: flex;
  justify-content: center;
  gap: 8px;
  align-items: baseline;
}
.cal-sel {
  appearance: none;
  background: var(--coal);
  border: 1px solid var(--line2);
  border-radius: 10px;
  color: var(--text);
  font: 500 15px var(--sans);
  height: 38px;
  padding: 0 12px;
  cursor: pointer;
  color-scheme: dark;
}
.cal-grid {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 4px;
}
.cal-dows {
  margin-bottom: 4px;
}
.cal-dow {
  text-align: center;
  font-size: 10px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--mute);
  padding: 6px 0;
}
.cal-d {
  position: relative;
  height: 52px;
  border-radius: 12px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1px;
  color: var(--text);
  border: 1px solid transparent;
  transition:
    background 0.15s,
    border-color 0.15s,
    transform 0.08s;
}
.cal-d small {
  font-size: 9.5px;
  color: color-mix(in srgb, var(--gold) 80%, var(--mute));
  line-height: 1;
}
.cal-d:hover {
  border-color: var(--line2);
}
.cal-d:active {
  transform: scale(0.96);
}
.cal-d.out {
  color: var(--faint);
}
.cal-d.out small {
  opacity: 0.5;
}
.cal-d.past {
  color: var(--mute);
}
.cal-d.today {
  border-color: var(--gold-line);
}

.cal-d[disabled] {
  opacity: 0.28;
  pointer-events: none;
}
.cal-legend {
  align-items: center;
  flex-wrap: wrap;
  font-size: 11px;
  color: var(--mute);
}
.cal-legend span {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.cal-legend i {
  width: 12px;
  height: 12px;
  border-radius: 4px;
  border: 1px solid var(--line);
}

.cal-foot {
  flex-wrap: wrap;
}
.cal-foot .chip {
  height: 36px;
}
.datebtn {
  display: flex;
  align-items: center;
  gap: 10px;
  text-align: left;
  cursor: pointer;
}
.datebtn svg {
  width: 16px;
  height: 16px;
  color: var(--gold);
}
.datebtn.empty {
  color: var(--mute);
}

@media (max-width: 760px) {
  .layer.calsheet .panel {
    width: 100%;
  }
  .cal {
    padding: 0 14px 10px;
  }
  .cal-d {
    height: 48px;
    border-radius: 10px;
  }
}
.cal-quick {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 14px;
}
.cal-quick .chip {
  height: 36px;
}
/* ===== Tables board ===== */
.tboard .dp-scroll {
  padding-top: calc(26px + var(--sa-t));
}
.tb-head {
  display: flex;
  align-items: flex-start;
  gap: 12px;
}
.tb-head h2 {
  margin: 6px 0 0;
}
.tb-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  border-radius: 16px;
  overflow: hidden;
  margin-top: 18px;
}
.tb-stats > button {
  padding: 13px 14px;
  display: flex;
  flex-direction: column;
  gap: 3px;
}
/* the tiles open the view-only floor plan */
.tb-stats > button {
  border: 0;
  margin: 0;
  font: inherit;
  text-align: left;
  align-items: flex-start;
  cursor: pointer;
  transition: filter 0.15s;
}
.tb-stats > button:hover {
  filter: brightness(1.15);
}
.tb-stats > button:active {
  filter: brightness(0.95);
}
.tb-stats b {
  color: var(--c);
}
.tb-stats span {
  color: var(--mute);
}
.tcards {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.tcard {
  display: grid;
  gap: 14px;
  border-radius: 14px;
  cursor: pointer;
  transition: border-color 0.15s;
}
.tcard:hover {
  border-color: color-mix(in srgb, var(--c-seated) 40%, transparent);
}
.tno {
  min-width: 58px;
  height: 44px;
  padding: 0 10px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  color: var(--f-table);
  border: 1px solid color-mix(in srgb, var(--f-table) 38%, transparent);
  white-space: nowrap;
}
.tno.none {
  color: var(--mute);
  border-style: dashed;
  background: transparent;
  border-color: var(--line2);
}
.tno.sm {
  min-width: 52px;
  height: 34px;
  border-radius: 10px;
}
.tinfo {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 3px;
}
.tinfo b {
  font-weight: 500;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.tinfo > span {
  display: flex;
  gap: 10px;
  font-size: 12.5px;
  align-items: center;
  flex-wrap: wrap;
}
.tinfo .tp {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  color: var(--f-party);
}
.tinfo .tp svg {
  width: 13px;
  height: 13px;
}
.tinfo .srv {
  color: var(--f-server);
}
.trows {
  display: flex;
  flex-direction: column;
}
.trow {
  display: grid;
  gap: 12px;
  align-items: start;
  padding: 10px 0;
  border-bottom: 1px solid var(--line);
}
.trow:last-child {
  border: 0;
}
.tslots {
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.tslot {
  display: grid;
  grid-template-columns: 10px 66px minmax(0, 1fr) auto;
  gap: 8px;
  align-items: center;
  text-align: left;
  padding: 7px 10px;
  border-radius: 10px;
}
.tslot:hover {
  background: var(--slate);
}
.tslot .dot {
  width: 7px;
  height: 7px;
}
.tslot .tt {
  color: var(--f-time);
  font-variant-numeric: tabular-nums;
}
.tslot .tp {
  color: var(--f-party);
  font-size: 12px;
}
.tslot.soon {
  background: color-mix(in srgb, var(--gold) 9%, transparent);
  box-shadow: inset 0 0 0 1px var(--gold-line);
}
.tb-empty {
  font-size: 13px;
  color: var(--mute);
  padding: 6px 0;
}
/* Tables panel: two equal light-blue buttons that filter the board */
.tb-notes {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-top: 14px;
}
.tb-note {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  min-height: 44px;
  padding: 8px 10px;
  border-radius: 12px;
  border: 1px solid color-mix(in srgb, var(--c-booked) 45%, transparent);
  background: color-mix(in srgb, var(--c-booked) 14%, transparent);
  color: var(--c-booked);
  font-size: 13.5px;
  font-weight: 600;
  text-align: center;
  line-height: 1.2;
}
.tb-note:hover {
  background: color-mix(in srgb, var(--c-booked) 22%, transparent);
}
.tb-note b {
  font-size: 15px;
}
.backlink {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 12px;
  color: var(--mute);
  margin: -4px 0 6px -4px;
  padding: 2px 4px;
  border-radius: 6px;
}
.backlink svg {
  width: 14px;
  height: 14px;
}
.backlink:hover {
  color: var(--gold-hi);
}
@container (max-width:900px) {
  .tools .tblbtn {
    width: 44px;
    padding: 0;
  }
}
@media (min-width: 1280px) {
  .tools .tblbtn {
    display: none;
  }
}
@media (max-width: 760px) {
  .tools .newbtn.tblbtn {
    display: inline-flex;
    width: 44px;
    padding: 0;
  }
  .tools .tblbtn .lbl-long {
    display: none;
  }
}
.trow .tno.sm {
  justify-self: start;
  text-overflow: ellipsis;
  display: block;
  line-height: 32px;
  text-align: center;
}
@media (max-width: 760px) {
  .tslot {
    grid-template-columns: 10px 62px minmax(0, 1fr) auto;
  }
}
/* ===== Numbers: clean sans with even-width digits (Playfair stays for words) ===== */
:root {
  --num: Inter, -apple-system, "SF Pro Display", "Helvetica Neue", system-ui, sans-serif;
}
.day .dn,
.stat .v,
.grp .t,
.fact .v,
.kpis .v,
.gcard .mini .v,
.gl .c,
.tl .d,
.stepnum b,
.ordn,
.hl,
.cal-d,
.tb-stats b,
.tno,
.hist .d,
.row .meta,
.tslot,
.hours .chip,
.dchip,
.ae .tm,
.sumbar {
  font-family: var(--num);
  font-variant-numeric: tabular-nums lining-nums;
  font-feature-settings:
    "tnum" 1,
    "lnum" 1,
    "cv11" 1,
    "ss01" 1;
}
.day .dn {
  line-height: 1.25;
}
.day .dc {
  font-weight: 500;
}
.grp .t small {
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.12em;
}
.fact .v small {
  font-size: 10px;
  font-weight: 600;
}
.fact .v.none {
  font-family: var(--sans);
  font-size: 15px;
  font-weight: 500;
}
.gcard .mini .v {
  font-size: 18px;
}
.gl .c {
  font-size: 17px;
  font-weight: 600;
}
.tl .d {
  font-size: 14.5px;
  font-weight: 600;
  letter-spacing: 0;
}
.stepnum b {
  font-size: 16px;
  font-weight: 600;
}
.ordn {
  font-size: 13px;
}
.hl {
  font-size: 14px;
  font-weight: 600;
  color: var(--text);
}
.hours .chip {
  font-weight: 500;
  font-size: 14px;
}
.cal-d {
  font-size: 15.5px;
  font-weight: 500;
}
.cal-d.sel {
  font-weight: 700;
}
.cal-d small {
  font-weight: 600;
}
.tno {
  font-size: 16px;
}
.tno.sm {
  font-size: 14px;
}
.row .meta {
  font-size: 14px;
  font-weight: 500;
}
.row .meta .tb {
  font-size: 14px;
  padding: 6px 10px; /* same height as the party-size box beside it */
  min-width: 48px;
}
.row .meta .tb.none {
  font-weight: 500;
}
.row .meta .p {
  font-weight: 600;
}
.tslot {
  font-size: 13.5px;
}
.tslot .tt {
  font-weight: 600;
}
.tslot .tp {
  font-weight: 600;
}
.hist .d {
  font-weight: 500;
}
/* =====================================================================
   THEMES — higher-contrast dark (default) and a warm ivory light mode
   ===================================================================== */
html {
  color-scheme: dark;
  /* iPhone Safari enlarges some blocks of text on its own ("text autosizing"), so rows that
     should match end up different sizes; keep every text at the size the styles set */
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}
html[data-theme="light"] {
  color-scheme: light;
}
html[data-theme="light"] .layer .scrim {
  background: rgba(40, 32, 20, 0.38);
}
html[data-theme="light"] .layer .panel {
  box-shadow: 0 40px 80px -30px rgba(40, 30, 10, 0.45);
}
html[data-theme="light"] .toast {
  box-shadow: 0 18px 40px -16px rgba(40, 30, 10, 0.35);
}
html[data-theme="light"] .lg-card {
  box-shadow: 0 30px 60px -36px rgba(40, 30, 10, 0.35);
}
html[data-theme="light"] .splash img {
  filter: brightness(0);
  opacity: 0.75;
}
html[data-theme="light"] .ecard,
html[data-theme="light"] .gcard,
html[data-theme="light"] .custcard {
  box-shadow: 0 1px 0 rgba(28, 22, 12, 0.04);
}
html[data-theme="light"] .sh-body.ed {
  background: var(--ink);
}
html[data-theme="light"] input,
html[data-theme="light"] select,
html[data-theme="light"] .cal-sel {
  color-scheme: light;
}
/* more color + contrast in both modes */
.grp .t {
  color: var(--text);
}

.stat {
  padding-left: 12px;
  border-left: 2px solid var(--line2);
}

.stat.t-seated .k:before,
.stat.t-booked .k:before,
.stat.t-waiting .k:before {
  display: none;
}
.stats {
  gap: 22px;
}
/* theme switch */
.themebtn {
  width: 40px;
  height: 40px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  color: var(--mute);
  margin-bottom: 8px;
}
.themebtn:hover {
  color: var(--gold-hi);
  background: var(--gold-soft);
}
.lg-theme {
  position: fixed;
  top: calc(16px + var(--sa-t));
  right: 16px;
  z-index: 5;
}
.appear {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 6px;
}
.appear .seg {
  align-self: flex-start;
}
.appear .seg button {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.appear .seg svg {
  width: 15px;
  height: 15px;
}
/* ===== Reservation detail header ===== */
.dp-bar {
  display: flex;
  align-items: center;
  min-height: 30px;
  margin: -8px 0 14px;
}
.dp-bar .sp {
  flex: 1;
}
.dp-bar .backlink {
  margin: 0;
  padding: 6px 10px 6px 6px;
  font-size: 12.5px;
  border-radius: 9px;
}
.dp-bar .backlink:hover {
  background: var(--slate);
}
.dp-id {
  display: flex;
  gap: 16px;
}
.dp-id .avatar.lg {
  width: 60px;
  height: 60px;
  font-size: 18px;
  flex: none;
}
.dp-id .who {
  min-width: 0;
  flex: 1;
  display: flex;
  flex-direction: column;
}
.dp-id h2 {
  word-wrap: break-word;
}
.dp-id .eyebrow {
  letter-spacing: 0.18em;
}
.idtags {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}
.contact-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 18px;
}

@media (max-width: 760px) {
  .dp-id .avatar.lg {
    width: 54px;
    height: 54px;
    font-size: 17px;
  }
}
/* ===== Calendar busy levels: clear, distinct colors ===== */
:root {
  --lv-quiet: #6ed49b;
  --lv-steady: #e2ba62;
  --lv-busy: #f39a4a;
  --lv-full: #f2667a;
}
.lv-quiet {
  --lv: var(--lv-quiet);
}
.lv-steady {
  --lv: var(--lv-steady);
}
.lv-busy {
  --lv: var(--lv-busy);
}
.lv-full {
  --lv: var(--lv-full);
}
.cal-d,
html[data-theme="light"] .cal-d {
  background: transparent;
}
.cal-d[class*="lv-"] {
  border-color: color-mix(in srgb, var(--lv) 40%, transparent);
}
.cal-d[class*="lv-"]:after {
  content: "";
  position: absolute;
  left: 22%;
  right: 22%;
  bottom: 5px;
  height: 3px;
  border-radius: 3px;
  background: var(--lv);
}
.cal-d[class*="lv-"] small {
  font-size: 10.5px;
}
.cal-d.today[class*="lv-"] {
  box-shadow: inset 0 0 0 1.5px var(--gold);
}
.cal-d.today[class*="lv-"]:after {
  content: "";
  position: absolute;
  left: 22%;
  right: 22%;
  bottom: 5px;
  top: auto;
  width: auto;
  height: 3px;
  border-radius: 3px;
  background: var(--lv);
}
.cal-d.out[class*="lv-"] {
  background: color-mix(in srgb, var(--lv) 7%, transparent);
  border-color: transparent;
}
.cal-d.out[class*="lv-"]:after {
  opacity: 0.4;
}
.cal-d.out[class*="lv-"] small {
  opacity: 0.55;
}

.cal-d.sel[class*="lv-"]:after {
  background: #121110;
  opacity: 0.55;
}

.cal-legend {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 6px;
  margin-top: 14px;
}
.cal-legend .lg {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 2px;
  padding: 8px 10px;
}
.cal-legend .lg i {
  display: none;
}
.cal-legend .lg b {
  font-size: 11.5px;
  font-weight: 600;
  color: var(--lv);
}
.cal-legend .lg em {
  font-style: normal;
  font-size: 10.5px;
  color: var(--sub);
  font-family: var(--num);
}
.cal-note2 {
  margin-top: 8px;
  font-size: 11px;
  color: var(--mute);
}
@media (max-width: 760px) {
  .cal-legend .lg {
    padding: 7px 8px;
  }
  .cal-legend .lg b {
    font-size: 10.5px;
  }
}
html[data-theme="light"] .cal-d.out[class*="lv-"] {
  background: color-mix(in srgb, var(--lv) 6%, transparent);
}
/* ===== Stronger, easier-to-see color coding ===== */
.row,
.row.s-finished,
.row.s-cancelled {
  box-shadow: none;
}
.row.sel:before,
.row:before {
  display: block;
  content: "";
  position: absolute;
  left: 0;
  top: 12px;
  bottom: 12px;
  width: 4px;
  border-radius: 4px;
  background: var(--c, transparent);
}
.row.s-finished:before,
.row.s-cancelled:before {
  opacity: 0.45;
}

.row .dot {
  width: 11px;
  height: 11px;
}
.row .st {
  font-weight: 600;
}
.badge.tn {
  font-weight: 600;
}
.seg .sw {
  width: 9px;
  height: 9px;
}
.seg button.tone.on {
  background: color-mix(in srgb, var(--c) 22%, var(--slate));
  box-shadow: inset 0 0 0 1.5px color-mix(in srgb, var(--c) 60%, transparent);
  font-weight: 600;
}
.atype {
  font-weight: 600;
}
/* Detail header: everything stacked under the name, evenly spaced */
.dp-id {
  align-items: flex-start;
}
.dp-id .avatar.lg {
  margin-top: 2px;
}
.dp-id .who {
  gap: 8px;
}
.dp-id h2 {
  margin: -2px 0 0;
}
.idtags {
  margin-top: 0;
}
.dp-id .contact-row {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin: 2px 0 0;
}
.cline {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 14.5px;
  color: var(--text);
  text-decoration: none;
  min-width: 0;
  line-height: 1.3;
}
.cline span {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.cline svg {
  width: 16px;
  height: 16px;
  color: var(--gold);
  flex: none;
}
.cline:hover span {
  text-decoration: underline;
  text-underline-offset: 3px;
}
.cline.none {
  color: var(--mute);
}
.cline.none svg {
  color: var(--mute);
}
/* ===== Title font: Libre Baskerville (bundled, SIL OFL 1.1) — one face for every title, numbers included ===== */
@font-face {
  font-family: "AR Baskerville";
  src: url("../fonts/libre-baskerville.woff") format("woff");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
:root {
  --serif: "AR Baskerville", "Libre Baskerville", Baskerville, Georgia, serif;
  --script: var(--serif);
}
.serif,
.top h1,
.dp-id h2,
.ph h2,
.sh-head h3,
.ecard > header h5,
.tb-head h2,
.lg-card h1,
.cal-title,
.empty h3,
.dp-empty h3,
.avatar.lg {
  font-family: var(--serif);
  font-weight: 400;
  font-variant-numeric: lining-nums proportional-nums;
  font-feature-settings: "lnum" 1;
  letter-spacing: -0.005em;
}

.avatar.lg {
  font-size: 17px;
  letter-spacing: 0.02em;
}
.notebox {
  font-family: var(--sans);
  font-style: italic;
  font-size: 15px;
}

/* ===== Deeper blacks (dark mode): no warm/yellow fills behind selections ===== */
/* selected states: black fill, gold (or status-color) ring + text */
html[data-theme="dark"] .day.on {
  background: #000;
  border-color: var(--gold);
  box-shadow: inset 0 0 0 1px var(--gold-line);
}
html[data-theme="dark"] .nav.on {
  background: #000;
  box-shadow: inset 0 0 0 1px var(--gold-line);
}
html[data-theme="dark"] .chip.on {
  background: color-mix(in srgb, var(--c, var(--gold)) 9%, #000);
  border-color: var(--c, var(--gold));
}
html[data-theme="dark"] .seg {
  background: #000;
}
html[data-theme="dark"] .seg button.tone.on {
  background: color-mix(in srgb, var(--c) 9%, #000);
  box-shadow: inset 0 0 0 1.5px var(--c);
}
html[data-theme="dark"] .today-tag {
  background: #000;
}
html[data-theme="dark"] .badge.gold,
html[data-theme="dark"] .welcome,
html[data-theme="dark"] .en {
  background: #000;
}
/* ===== List column headings (aligned with every row) ===== */
.row .meta {
  display: grid;
  gap: 0;
  justify-items: center;
  align-items: center;
}
.row .meta .p {
  justify-content: center;
  min-width: 0;
}
.row .act {
  min-width: 0;
}
.list {
  scrollbar-gutter: stable;
}
.colhead {
  display: grid;
  gap: 16px;
  align-items: center;
  padding: 9px 14px 9px 16px;
  overflow-y: hidden;
  scrollbar-gutter: stable;
}
/* the rows' scrollbar (desktop) takes width from the list, not the heading: the app nudges this
   block (left) so the Party / Table headings line up with the rows */
.colhead .ch-meta {
  position: relative;
  display: grid;
  justify-items: center;
}
.colhead .ch-m {
  display: none;
}
.colhead .ch-act {
  text-align: right;
  padding-right: 6px;
}

@media (max-width: 760px) {
  .row .meta {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
  }
  .colhead {
    padding: 8px 10px;
    gap: 10px;
  }
  .colhead .ch-meta {
    display: block;
  }
  .colhead .ch-meta > span:not(.ch-m) {
    display: none;
  }
  .colhead .ch-m {
    display: inline;
  }
  .colhead .ch-act {
    display: none;
  }
}
.gsec {
  position: relative;
}
/* ===== Status vs. next step: state is a badge, the next step is a button ===== */
.row .act {
  display: flex;
  align-items: center;
  gap: 8px;
}
.seatbtn svg,
.finbtn svg {
  width: 15px;
  height: 15px;
}
.seatbtn {
  gap: 6px;
  padding: 0 14px;
}

.btn.finbtn {
  gap: 6px;
  padding: 0 12px;
  background: transparent;
  border: 1px solid var(--line2);
  color: var(--text);
  font-weight: 500;
}
.btn.finbtn svg {
  color: var(--sub);
}
.btn.finbtn:hover {
  border-color: var(--text);
  background: var(--slate);
}
html[data-theme="dark"] .btn.finbtn {
  background: #000;
}
.flag.seated {
  border-color: color-mix(in srgb, var(--c-seated) 45%, transparent);
  background: color-mix(in srgb, var(--c-seated) 10%, transparent);
  color: var(--text);
}
.flag.seated svg {
  color: var(--c-seated);
  stroke-width: 2.2;
}
.flag.seated b {
  color: var(--c-seated);
  font-weight: 600;
}
.flag.seated span b:last-child {
  color: var(--text);
}

/* Assign-table step, wider status column, fixes */
.row .act .st {
  font-size: 9.5px;
  padding: 4px 8px;
}
.btn.assignbtn {
  gap: 6px;
  padding: 0 12px;
  color: var(--f-table);
  border: 1px solid color-mix(in srgb, var(--f-table) 55%, transparent);
  background: color-mix(in srgb, var(--f-table) 8%, transparent);
  font-weight: 600;
}
.btn.assignbtn svg {
  width: 15px;
  height: 15px;
}
.btn.assignbtn:hover {
  background: color-mix(in srgb, var(--f-table) 16%, transparent);
}
html[data-theme="dark"] .btn.assignbtn {
  background: color-mix(in srgb, var(--f-table) 8%, #000);
}
.dp-actions .assignbtn {
  height: 50px;
}
.fact {
  padding: 14px 8px;
}
.fact .v {
  text-overflow: clip;
}
.fact .v small {
  margin-left: 1px;
}
@media (max-width: 760px) {
  .row .act {
    display: none !important;
  }
}
/* =====================================================================
   LIGHT MODE — high contrast: white "paper" on warm stone, black + gold accents
   ===================================================================== */
/* white panels with real borders */
html[data-theme="light"] .rail {
  border-right: 1px solid var(--line2);
}
html[data-theme="light"] aside#detail {
  border-left: 1px solid var(--line2);
}
html[data-theme="light"] .colhead {
  border: 1px solid var(--line2);
  border-bottom-color: var(--line);
  margin-bottom: 0;
  border-radius: 14px 14px 0 0;
}
html[data-theme="light"] .list {
  margin: 0 16px;
  border: 1px solid var(--line2);
  border-top: 0;
  border-radius: 0 0 14px 14px;
}
html[data-theme="light"] .row {
  margin: 0 6px;
}
html[data-theme="light"] .row.sel {
  outline: 1.5px solid var(--gold);
  box-shadow: none;
}
html[data-theme="light"] .row + .row:after {
  background: var(--line);
}
/* chips, inputs, segmented controls on white */
html[data-theme="light"] .input,
html[data-theme="light"] .chip,
html[data-theme="light"] .btn,
html[data-theme="light"] .seg,
html[data-theme="light"] .day,
html[data-theme="light"] .cal-sel {
  background: #fff;
  border-color: var(--line2);
}
html[data-theme="light"] .chip {
  color: var(--sub);
}
html[data-theme="light"] .btn {
  color: var(--text);
}
html[data-theme="light"] .btn.quiet {
  border-color: transparent;
}
html[data-theme="light"] .seg button {
  color: var(--sub);
}
html[data-theme="light"] .seg button.on {
  background: var(--blk);
}
html[data-theme="light"] .seg button.tone.on {
  background: color-mix(in srgb, var(--c) 13%, #fff);
  color: var(--c);
  box-shadow: inset 0 0 0 1.5px var(--c);
}
html[data-theme="light"] .seg button.tone.f-all.on,
html[data-theme="light"] .seg button.tone.svc-0.on {
  background: var(--blk);
  color: var(--blk-text);
  box-shadow: none;
}
html[data-theme="light"] .seg button.tone.f-all.on .n {
  color: var(--blk-text);
}
html[data-theme="light"] .chip.on {
  background: color-mix(in srgb, var(--c, var(--gold)) 12%, #fff);
  border-color: var(--c, var(--gold));
  border-width: 1.5px;
  color: var(--c, var(--gold-hi));
  font-weight: 600;
}
/* selected day + active nav + today tag: black with gold */
html[data-theme="light"] .day .dw,
html[data-theme="light"] .day .dc {
  color: var(--mute);
}
html[data-theme="light"] .day.on {
  background: var(--blk);
  border-color: var(--blk);
}
html[data-theme="light"] .day.on .dw,
html[data-theme="light"] .day.on .dc {
  color: var(--blk-text);
}
html[data-theme="light"] .day.is-today:after {
  background: var(--gold);
}
html[data-theme="light"] .nav {
  color: var(--mute);
}
html[data-theme="light"] .nav.on {
  background: var(--blk);
  color: var(--blk-text);
  box-shadow: none;
}
html[data-theme="light"] .nav.on:before {
  display: none;
}
html[data-theme="light"] .today-tag {
  background: var(--blk);
  color: var(--blk-text);
  border-color: var(--blk);
}
/* primary buttons: black with gold text */
html[data-theme="light"] .btn.gold,
html[data-theme="light"] .fab {
  background: var(--blk);
  color: var(--blk-text);
  border-color: var(--blk);
  box-shadow: 0 6px 16px -8px rgba(20, 17, 12, 0.6);
}
html[data-theme="light"] .fab svg {
  color: var(--blk-text);
}
html[data-theme="light"] .cal-d.sel,
html[data-theme="light"] .cal-d.sel[class*="lv-"] {
  background: var(--blk);
  border-color: var(--blk);
  color: #fff;
}
html[data-theme="light"] .cal-d.sel small {
  color: var(--blk-text) !important;
}
html[data-theme="light"] .cal-d.sel[class*="lv-"]:after {
  background: var(--blk-text);
  opacity: 0.8;
}
html[data-theme="light"] .btn.finbtn {
  background: #fff;
  border-color: var(--line2);
}
/* numbers & labels */
html[data-theme="light"] .stat .k,
html[data-theme="light"] .colhead,
html[data-theme="light"] .el,
html[data-theme="light"] .field > span:not(.xfield),
html[data-theme="light"] .sec h4,
html[data-theme="light"] .fact .k,
html[data-theme="light"] .kpis .k,
html[data-theme="light"] .tb-stats span {
  color: var(--mute);
}

html[data-theme="light"] .pace .b.zero i {
  background: var(--line2);
  opacity: 1;
}
html[data-theme="light"] .pace .b em,
html[data-theme="light"] .pace .lbl {
  color: var(--mute);
}
/* status & badge legibility */
html[data-theme="light"] .badge {
  border-color: var(--line2);
  color: var(--sub);
}

html[data-theme="light"] .row .meta .tb.none {
  border-color: var(--line2);
  color: var(--faint);
}
/* cards & sheets */
html[data-theme="light"] .layer .panel {
  border-color: var(--line2);
}
html[data-theme="light"] .ecard,
html[data-theme="light"] .gcard,
html[data-theme="light"] .custcard,
html[data-theme="light"] .tcard,
html[data-theme="light"] .kpis,
html[data-theme="light"] .facts,
html[data-theme="light"] .tb-stats {
  border-color: var(--line2);
}
html[data-theme="light"] .fact {
  border-color: var(--line);
}
html[data-theme="light"] .dp-foot,
html[data-theme="light"] .sh-foot {
  border-top-color: var(--line2);
}
html[data-theme="light"] .split .l {
  border-right-color: var(--line2);
}
html[data-theme="light"] .tabbar {
  border-top-color: var(--line2);
}
@media (max-width: 760px) {
  html[data-theme="light"] .list,
  html[data-theme="light"] .colhead {
    margin-left: 8px;
    margin-right: 8px;
  }
}
html[data-theme="light"] .btn.assignbtn {
  color: var(--f-table);
  border-color: color-mix(in srgb, var(--f-table) 60%, transparent);
}
html[data-theme="light"] .btn.assignbtn svg {
  color: var(--f-table);
}
/* ===== Status pill beside the guest name (status column removed) ===== */
.row .act {
  justify-content: flex-end;
}
.row .nm .vip,
.row .nm .npill {
  flex: none;
}
.row .nm .npill {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  height: 22px;
  padding: 0 9px;
  font-size: 9.5px;
  line-height: 1;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  font-weight: 650;
  border: 1px solid;
}
.row .nm .npill svg {
  width: 11px;
  height: 11px;
  stroke-width: 2.6;
}
.s-cancelled .nm {
  text-decoration: none;
}
.s-cancelled .nm .nmt {
  text-decoration: line-through;
  text-decoration-color: var(--faint);
}

/* Waiting / Checked in pills: the minutes sit in their own darker section on the right */
.row .nm .npill .pmin {
  align-self: stretch;
  display: inline-flex;
  align-items: center;
  margin: 0 -9px 0 5px;
  padding: 0 8px 0 7px;
  border-radius: 0 999px 999px 0;
  background: rgba(0, 0, 0, 0.42);
}
html[data-theme="light"] .row .nm .npill .pmin {
  background: rgba(0, 0, 0, 0.16);
}
@media (max-width: 760px) {
  .row .nm .npill .pmin {
    padding: 0 7px 0 6px;
  }
}
/* ===== Action column: one button style, a color per action ===== */
.a-assign {
  --a: var(--f-table);
}
.a-seat {
  --a: var(--c-seated);
}
.a-finish {
  --a: var(--c-booked);
}
.btn.actbtn,
html[data-theme] .btn.actbtn {
  width: 124px;
  justify-content: center;
  gap: 6px;
  padding: 0 10px;
  height: 34px;
  border-radius: 10px;
  font-weight: 600;
  letter-spacing: 0.01em;
  border: 1.5px solid color-mix(in srgb, var(--a) 62%, transparent);
}
.btn.actbtn svg,
html[data-theme] .btn.actbtn svg {
  width: 15px;
  height: 15px;
  flex: none;
}

/* solid action buttons */
html[data-theme] .btn.actbtn {
  background: var(--a);
  color: var(--on-a);
  border-color: var(--a);
}
html[data-theme] .btn.actbtn svg {
  color: var(--on-a);
}
html[data-theme] .btn.actbtn:hover {
  background: color-mix(in srgb, var(--a) 88%, #fff);
  border-color: var(--a);
}
.strip,
.summary,
.top {
  flex: none;
}
.btn.actbtn.wide,
html[data-theme] .btn.actbtn.wide {
  width: 100%;
  height: 50px;
  font-size: 15px;
}
html[data-theme] .btn.actbtn {
  box-shadow: none;
}
/* =====================================================================
   MAISON colors on the original layout
   Primary #0E0E0E · Accent #B89B5E · Surface #FAF7F0 · Muted #ECE6DA · Text #0E0E0E
   + coordinating accents, every text pairing ≥ 4.5:1 in both modes
   ===================================================================== */
html[data-theme="dark"] body,
html:not([data-theme]) body {
  background: var(--ink);
}
html[data-theme="dark"] .grp {
  background: linear-gradient(180deg, var(--ink) 82%, transparent);
}
html[data-theme="dark"] .pace .b i {
  background: linear-gradient(180deg, rgba(184, 155, 94, 0.9), rgba(184, 155, 94, 0.25));
}
/* Surface (#FAF7F0) wherever the original used white */
html[data-theme="light"] .rail,
html[data-theme="light"] aside#detail,
html[data-theme="light"] .list,
html[data-theme="light"] .colhead,
html[data-theme="light"] .input,
html[data-theme="light"] .chip,
html[data-theme="light"] .btn,
html[data-theme="light"] .seg,
html[data-theme="light"] .day,
html[data-theme="light"] .cal-sel,
html[data-theme="light"] .ecard,
html[data-theme="light"] .gcard,
html[data-theme="light"] .custcard,
html[data-theme="light"] .tcard,
html[data-theme="light"] .kpis,
html[data-theme="light"] .facts,
html[data-theme="light"] .tb-stats,
html[data-theme="light"] .dp-foot,
html[data-theme="light"] .sh-foot,
html[data-theme="light"] .split .l {
  background-color: var(--coal);
}
html[data-theme="light"] .btn.quiet {
  background: transparent;
}
html[data-theme="light"] .day.on .dn,
html[data-theme="light"] .seg button.on {
  color: var(--coal);
}
html[data-theme="light"] .layer .panel,
html[data-theme="light"] .sh-head {
  background: var(--ink);
}
/* ===== Neutral blacks & grays (dark) · beige + white (light) ===== */
html[data-theme="light"] .row.sel,
html[data-theme="light"] .gl.sel {
  background: #f5eddc;
}
html[data-theme="light"] .tabbar {
  background: rgba(255, 255, 255, 0.96);
}
/* ===== Bold primary accents (all text ≥ 4.5:1) ===== */
html[data-theme="dark"],
html:not([data-theme]) {
  --c-confirmed: #facc15;
  --c-seated: #4ade80;
  --c-lunch: #facc15;
  --f-party: #2dd4bf;
  --lv-quiet: #4ade80;
  --lv-steady: #facc15;
  --sage: #4ade80;
  --rust: #f87171;
}
html[data-theme="dark"] .a-assign,
html:not([data-theme]) .a-assign {
  --a: #fb923c;
}
html[data-theme="dark"] .a-seat,
html:not([data-theme]) .a-seat {
  --a: #4ade80;
}
html[data-theme="dark"] .a-finish,
html:not([data-theme]) .a-finish {
  --a: #60a5fa;
}
html[data-theme="dark"] .btn.actbtn,
html:not([data-theme]) .btn.actbtn {
  --on-a: #0a0a0a;
}
/* ===== Dark mode: cool gray family (zinc) — no warm cast anywhere ===== */
html[data-theme="dark"] .seg button.on {
  background: #202024;
}
html[data-theme="dark"] .pace .b.past i {
  background: linear-gradient(180deg, rgba(228, 228, 231, 0.24), rgba(228, 228, 231, 0.06));
}
/* table chips: gray fill, color only in border + number (no brown/yellow tint) */
html[data-theme="dark"] .row .meta .tb:not(.none),
html[data-theme="dark"] .tno,
html:not([data-theme]) .row .meta .tb:not(.none),
html:not([data-theme]) .tno {
  background: var(--slate) !important;
  border-color: color-mix(in srgb, var(--f-table) 60%, transparent) !important;
}
html[data-theme="dark"] .row.sel {
  background: #16161a;
}
/* ===== Light: translucent white panels over beige ===== */

/* ===== Clear separation between time slots ===== */

.grp,
html[data-theme] .grp {
  align-items: center;
}
.grp .ln {
  display: none;
}
.grp .t {
  display: inline-flex;
  align-items: baseline;
  padding-left: 12px;
  border-left: 3px solid var(--gold-lo);
}
.grp.wl .t,
.grp.wl > span:first-child {
  border-left-color: var(--c-waiting);
}
html[data-theme="light"] .grp.nowgrp,
html[data-theme="dark"] .grp.nowgrp {
  box-shadow: inset 3px 0 0 var(--gold-lo);
}

/* =====================================================================
   FINAL SYSTEM — deep-blue accent, no gold, identical layout in both modes,
   one spacing scale and one type scale.
   ===================================================================== */
/* ---- Tokens: accent = deep blue ---- */
html[data-theme="light"] {
  --on-accent: #ffffff;
}
html[data-theme="dark"],
html:not([data-theme]) {
  --on-accent: #ffffff;
  --gold: #93c5fd;
  --gold-hi: #bfdbfe;
  --gold-lo: #3b82f6;
  --ivory: #bfdbfe;
  --blk: #1e40af;
  --blk-text: #ffffff;
}
:root {
  --pad: 28px;
}
@media (max-width: 760px) {
  :root {
    --pad: 18px;
  }
}
/* ---- Selected & primary: one style for both modes (solid deep blue, white text) ---- */
html[data-theme] .btn.gold,
html[data-theme] .fab,
html[data-theme] .day.on,
html[data-theme] .nav.on,
html[data-theme] .today-tag,
html[data-theme] .seg button.on,
html[data-theme] .seg button.tone.f-all.on,
html[data-theme] .seg button.tone.svc-0.on,
html[data-theme] .cal-d.sel,
html[data-theme] .cal-d.sel[class*="lv-"],
html[data-theme] .tabbar .nav.on {
  background: var(--sel-bg) !important;
  color: var(--sel-fg) !important;
  border-color: var(--sel-bd) !important;
  box-shadow: none !important;
}
html[data-theme] .btn.gold svg,
html[data-theme] .fab svg,
html[data-theme] .nav.on svg,
html[data-theme] .seg button.on .n,
html[data-theme] .day.on .dn,
html[data-theme] .day.on .dw,
html[data-theme] .day.on .dc,
html[data-theme] .cal-d.sel small {
  color: var(--sel-fg) !important;
}
html[data-theme] .day.on .dw,
html[data-theme] .day.on .dc {
  opacity: 0.85;
}
html[data-theme] .seg button.on .sw {
  background: var(--sel-fg) !important;
}
html[data-theme] .btn.gold:hover,
html[data-theme] .fab:hover {
  filter: brightness(1.12);
}
html[data-theme] .nav.on:before {
  display: none;
}
html[data-theme] .day.is-today:after {
  background: var(--accent-2);
}
html[data-theme] .day.on.is-today:after {
  background: var(--sel-fg);
}
/* Phones: the day boxes are narrow, so today's dot sits close to the right edge */
@media (max-width: 760px) {
  .day.is-today:after {
    right: 5px;
  }
}
html[data-theme] .seg button.tone.on:not(.f-all):not(.svc-0) {
  background: color-mix(in srgb, var(--c) 12%, transparent) !important;
  color: var(--c) !important;
  border-color: transparent !important;
  box-shadow: inset 0 0 0 1.5px var(--c) !important;
}
html[data-theme] .seg button.tone.on:not(.f-all):not(.svc-0) .n {
  color: var(--c) !important;
}
html[data-theme] .chip.on {
  background: color-mix(in srgb, var(--c, var(--accent-2)) 12%, transparent);
  border-color: var(--c, var(--accent-2));
  color: var(--c, var(--accent-text));
}
/* ---- Former gold details → neutral or blue ---- */
html[data-theme] .eyebrow {
  color: var(--mute);
}
html[data-theme] .grp.nowgrp .t {
  color: var(--accent-text);
}
html[data-theme] .stars svg {
  stroke: var(--c-confirmed);
}
html[data-theme] .stars svg.on {
  fill: var(--c-confirmed);
}
html[data-theme] .row .nm .vip {
  color: var(--c-confirmed);
}
html[data-theme] .badge.gold {
  background: color-mix(in srgb, var(--f-request) 10%, transparent);
  border-color: color-mix(in srgb, var(--f-request) 50%, transparent);
  color: var(--f-request);
}
html[data-theme] .welcome {
  background: var(--gold-soft);
  border-color: var(--gold-line);
}
html[data-theme] .en {
  background: var(--gold-soft);
  color: var(--accent-text);
}
html[data-theme] .cal-title span {
  color: var(--mute);
}
html[data-theme] .pace .b i {
  background: linear-gradient(180deg, var(--accent-2), color-mix(in srgb, var(--accent-2) 30%, transparent));
}
html[data-theme] .pace .b.past i {
  background: linear-gradient(
    180deg,
    color-mix(in srgb, var(--mute) 55%, transparent),
    color-mix(in srgb, var(--mute) 15%, transparent)
  );
}
html[data-theme] .pace .b.zero i {
  background: var(--line2);
}
html[data-theme] .pace .now,
html[data-theme] .pace .now:before {
  background: var(--accent-2);
  box-shadow: none;
}
.rail img,
.lg-card img,
.orn img,
.brand img,
.splash img {
  filter: grayscale(1) contrast(1.05);
}
html[data-theme] .grp .t {
  border-left-color: var(--accent-2);
}
html[data-theme] .grp.wl .t {
  border-left-color: var(--c-waiting);
}
html[data-theme] .row.sel {
  background: var(--row-sel) !important;
  outline: 1.5px solid var(--gold-line);
  outline-offset: -1.5px;
  box-shadow: none;
}
html[data-theme] .gl.sel {
  background: var(--row-sel);
}
html[data-theme] #login {
  background:
    radial-gradient(1000px 560px at 50% -10%, color-mix(in srgb, var(--accent-2) 12%, transparent), transparent 62%),
    var(--ink);
}
html[data-theme] .cline:hover span {
  color: var(--accent-text);
  text-decoration-color: var(--gold-line);
}
/* ---- Identical layout in both modes ---- */
html[data-theme] .top {
  padding-left: var(--pad);
  padding-right: var(--pad);
}
html[data-theme] .strip {
  padding-left: var(--pad);
  padding-right: var(--pad);
}
html[data-theme] .summary {
  padding-left: var(--pad);
  padding-right: var(--pad);
}
html[data-theme] .bar {
  padding: 14px var(--pad) 14px;
  border-bottom: 0;
}
html[data-theme] .rail {
  background: var(--panel);
  border-right: 1px solid var(--line);
}
html[data-theme] aside#detail {
  background: var(--panel);
  border-left: 1px solid var(--line);
}
html[data-theme] .colhead {
  background: var(--panel);
  border: 1px solid var(--line2);
  border-bottom: 3px solid var(--colhead-rule, #16181d);
  border-radius: 14px 14px 0 0;
  margin: 0 var(--pad);
  color: var(--mute);
  box-shadow: none;
}
html[data-theme="light"] {
  --colhead-rule: #b9bec7;
}
html[data-theme] .list {
  background: var(--panel);
  border: 1px solid var(--line2);
  border-top: 0;
  border-radius: 0 0 14px 14px;
  margin: 0 var(--pad) var(--pad);
  box-shadow: none;
}
html[data-theme] .row {
  margin: 0 6px;
  border-radius: 10px;
}
html[data-theme] .row:hover {
  background: color-mix(in srgb, var(--text) 4%, transparent);
}
html[data-theme] .ecard,
html[data-theme] .gcard,
html[data-theme] .custcard,
html[data-theme] .tcard,
html[data-theme] .kpis,
html[data-theme] .facts,
html[data-theme] .tb-stats,
html[data-theme] .lg-card {
  background: var(--panel);
  border: 1px solid var(--line2);
  box-shadow: none;
}
html[data-theme] .gcard .mini div,
html[data-theme] .kpis div,
html[data-theme] .tb-stats > button {
  background: var(--slate);
}
html[data-theme] .day,
html[data-theme] .chip,
html[data-theme] .seg,
html[data-theme] .input,
html[data-theme] .cal-sel,
html[data-theme] .btn.ghost,
html[data-theme] .btn.finbtn:not(.actbtn) {
  background-color: var(--panel);
  border-color: var(--line2);
}
html[data-theme] .dp-foot,
html[data-theme] .sh-foot {
  background: var(--panel-solid);
  border-top: 1px solid var(--line);
}
html[data-theme] .tabbar {
  background: var(--glass);
  border-top: 1px solid var(--line2);
}
html[data-theme] .layer .panel,
html[data-theme] .sh-head {
  background: var(--ink);
}
html[data-theme] .tcard {
  background: var(--panel);
}
html[data-theme] .row .meta .tb:not(.none),
html[data-theme] .tno {
  background: color-mix(in srgb, var(--f-table) 8%, transparent) !important;
  border-color: color-mix(in srgb, var(--f-table) 55%, transparent) !important;
}
html[data-theme] .row .st,
html[data-theme] .badge.tn {
  background: color-mix(in srgb, var(--c) 10%, transparent);
  border-color: color-mix(in srgb, var(--c) 50%, transparent);
  color: var(--c);
}
html[data-theme] .gsec + .gsec {
  border-top: 1px solid var(--line);
  margin-top: 4px;
}
html[data-theme] .grp {
  background: var(--grp-bg);
  border-bottom: 1px solid var(--line);
  margin: 0 0 4px;
  padding: 10px 20px;
}
@media (max-width: 760px) {
  html[data-theme] .grp {
    padding: 9px 14px;
  }
  html[data-theme] .row {
    margin: 0 4px;
  }
}
/* ---- One type scale ---- */
/* Titles: Libre Baskerville 400 only. Everything else: Inter. Numbers: Inter 600 tabular. */
html[data-theme] .top h1 {
  font-size: 32px;
  line-height: 1.1;
}
html[data-theme] .dp-id h2,
html[data-theme] .tb-head h2,
html[data-theme] .ph h2 {
  font-size: 26px;
  line-height: 1.15;
}
html[data-theme] .sh-head h3,
html[data-theme] .lg-card h1,
html[data-theme] .cal-title {
  font-size: 21px;
}
html[data-theme] .ecard > header h5,
html[data-theme] .empty h3,
html[data-theme] .dp-empty h3 {
  font-size: 18px;
}
.avatar.lg,
.ordn {
  font-family: var(--sans) !important;
  font-weight: 600;
}
.eyebrow,
.stat .k,
.colhead,
.colhead span,
.fact .k,
.kpis .k,
.tb-stats span,
.el,
.field > span:not(.xfield),
.sec h4,
.pace .lbl,
.day .dw,
.gcard .mini .k {
  font-family: var(--sans);
  font-size: 10.5px !important;
  font-weight: 600;
  letter-spacing: 0.14em !important;
  text-transform: uppercase;
}
.row .nm {
  font-size: 15.5px;
  font-weight: 500;
}
.row .sub,
.grp .m,
.row .meta .p {
  font-size: 13px;
}
.day .dc {
  font-size: 11.5px;
  letter-spacing: 0;
}
.stat .v,
.day .dn,
.grp .t,
.fact .v,
.kpis .v,
.tb-stats b,
.tno,
.gcard .mini .v,
.row .meta .tb {
  font-family: var(--num);
  font-weight: 600;
  letter-spacing: -0.01em;
}
.stat .v {
  font-size: 28px;
}
.day .dn {
  font-size: 20px;
}
.grp .t {
  font-size: 17px;
}
.fact .v {
  font-size: 19px;
}
.tb-stats b,
.kpis .v {
  font-size: 24px;
}
.btn {
  font-family: var(--sans);
  font-weight: 500;
}
.btn.gold,
.btn.actbtn {
  font-weight: 600;
}
@media (max-width: 760px) {
  html[data-theme] .top h1 {
    font-size: 27px;
  }
  .day .dn {
    font-size: 18px;
  }
  html[data-theme] .dp-id h2 {
    font-size: 23px;
  }
}
.ct-party .chip {
  min-width: 46px;
  justify-content: center;
  font-family: var(--num);
  font-weight: 600;
}
.pp-step {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: 16px;
  padding: 10px 14px;
  border: 1px solid var(--line2);
  border-radius: 12px;
  color: var(--sub);
  font-size: 14px;
}
.pp-step .stepnum b {
  font-family: var(--num);
  font-weight: 600;
}
html[data-theme] .ct-party .chip.on {
  color: var(--sel-fg);
  border-color: var(--sel-bd);
}
html[data-theme] .chips.times .chip.on {
  background: var(--sel-bg) !important;
  color: var(--sel-fg) !important;
  border-color: var(--sel-bd) !important;
}
html[data-theme] .chips.times .chip.on .load {
  opacity: 0.7;
}
/* status timeline — blue (both flows) */

.wlstep {
  --accent-2: var(--c-waiting);
  --accent-text: var(--c-waiting);
  --gold-soft: color-mix(in srgb, var(--c-waiting) 16%, transparent);
}
.wlstep .stp.static {
  cursor: default;
}
.stp small {
  display: block;
  margin-top: -3px;
  font-family: var(--num);
  font-size: 11px;
  letter-spacing: 0;
  text-transform: none;
  font-weight: 600;
  color: var(--sub);
}
.stp.cur small {
  color: inherit;
}
/* timeline steps use the same colors as the status filters */
.stp.sc-booked {
  --sc: var(--c-booked);
}
.stp.sc-confirmed {
  --sc: var(--c-confirmed);
}
.stp.sc-waiting {
  --sc: var(--c-waiting);
}
.stp.sc-table {
  --sc: var(--f-table);
}
.stp.sc-seated {
  --sc: var(--c-seated);
}
.stp.sc-finished {
  --sc: var(--c-finished);
}
html[data-theme] .stp.done i,
html[data-theme] .stp.cur i {
  background: var(--sc);
  border-color: var(--sc);
}
html[data-theme] .stp.cur i {
  box-shadow: 0 0 0 5px color-mix(in srgb, var(--sc) 22%, transparent);
}
html[data-theme] .stp.done:before,
html[data-theme] .stp.cur:before {
  background: var(--sc);
}
html[data-theme] .stp:not(.done):not(.cur) i {
  background: var(--coal);
  border-color: color-mix(in srgb, var(--sc) 55%, var(--faint));
}
html[data-theme] .stp.done {
  color: var(--sub);
}
html[data-theme] .stp.cur {
  color: var(--sc);
  font-weight: 700;
}
html[data-theme] .stp:not(.static):hover {
  color: var(--sc);
}
html[data-theme] .flag.wl {
  color: var(--text);
  background: color-mix(in srgb, var(--c-waiting) 9%, transparent);
  border-color: color-mix(in srgb, var(--c-waiting) 45%, transparent);
}
html[data-theme] .flag.wl svg {
  color: var(--c-waiting);
}
/* ===== Dark mode: slate blue-grays (matched to reference: #23272E / #2A2F37 / #3E4651) ===== */
html[data-theme="dark"],
html:not([data-theme]) {
  --text: #f4f5f7;
  --sub: #cdd2da;
  --mute: #b4bbc5;
  --faint: #7c8592;
  --sel-bg: #2563eb;
  --sel-fg: #ffffff;
  --sel-bd: #60a5fa;
  --accent: #2563eb;
  --accent-2: #60a5fa;
  --accent-text: #93c5fd;
  --row-sel: rgba(37, 99, 235, 0.2);
  --gold-soft: rgba(96, 165, 250, 0.14);
  --gold-line: rgba(147, 197, 253, 0.6);
  --c-booked: #7db5fb;
  --c-waiting: #d0a3fd;
  --c-noshow: #fb8f8f;
  --c-checkdate: #f78dc6;
  --c-finished: #b4bbc5;
  --c-cancelled: #b4bbc5;
  --c-hold: #fda15a;
  --c-dinner: #fb8f8f;
  --f-time: #7db5fb;
  --f-server: #d0a3fd;
  --f-request: #f78dc6;
  --f-table: #fda15a;
  --lv-full: #fb8f8f;
  --lv-busy: #fda15a;
}
html[data-theme="dark"] .rail {
  background: var(--rail);
}
html[data-theme="dark"] aside#detail {
  background: var(--coal);
}
html[data-theme="dark"] .colhead {
  background: var(--raise);
  color: var(--sub);
}
html[data-theme="dark"] .day,
html[data-theme="dark"] .chip,
html[data-theme="dark"] .seg,
html[data-theme="dark"] .input,
html[data-theme="dark"] .cal-sel,
html[data-theme="dark"] .btn.ghost {
  background-color: var(--coal);
  border-color: var(--line2);
}
html[data-theme="dark"] .layer .panel,
html[data-theme="dark"] .sh-head {
  background: var(--coal);
}
html[data-theme="dark"] .sh-foot,
html[data-theme="dark"] .dp-foot {
  background: var(--ink);
}
html[data-theme="dark"] .gcard .mini div,
html[data-theme="dark"] .kpis div,
html[data-theme="dark"] .tb-stats > button {
  background: var(--slate);
}
html[data-theme="dark"] .tcard,
html[data-theme="dark"] .ecard,
html[data-theme="dark"] .gcard,
html[data-theme="dark"] .custcard,
html[data-theme="dark"] .facts {
  background: var(--coal);
}
html[data-theme="dark"] .facts .fact + .fact {
  border-color: var(--line2);
}
html[data-theme="dark"] .grp .m {
  color: var(--sub);
}
html[data-theme="dark"] .stp:not(.done):not(.cur) i {
  background: var(--coal);
}
html[data-theme="dark"] .skel {
  background: linear-gradient(90deg, var(--coal), var(--slate), var(--coal));
  background-size: 200% 100%;
}
html[data-theme="dark"] .mode-switch .btn.on {
  background: color-mix(in srgb, var(--c) 14%, var(--coal));
}
/* ===== Book-a-table window: compact, more visible at once ===== */
.ed {
  gap: 12px !important;
}
.ecard {
  padding: 16px 18px !important;
  gap: 14px !important;
  border-radius: 16px !important;
}
.ecard > header .en {
  width: 22px;
  height: 22px;
  font-size: 11px;
}
html[data-theme] .ecard > header h5 {
  font-size: 16px;
}
.ed .erow {
  gap: 10px 16px;
}
.ed .erow + .erow {
  padding-top: 14px;
}
.ed .chip {
  height: 36px;
  padding: 0 13px;
  font-size: 14px;
}
.ed #edParty .chip {
  min-width: 40px;
  justify-content: center;
  padding: 0 10px;
}
.ed .bigparty .stepnum {
  height: 36px;
}
.ed .bigparty .stepnum button {
  width: 34px;
}
.ed .seg button {
  height: 32px;
  font-size: 13.5px;
}
.ed .hours .times .chip {
  height: 32px;
  min-width: 58px;
  font-size: 13.5px;
  padding: 0 8px;
}
.ed .hr {
  grid-template-columns: 44px minmax(0, 1fr);
  gap: 6px;
}
.ed .hl {
  font-size: 14px;
}
.ed .input {
  height: 40px;
}
.ed .quick button {
  font-size: 12.5px;
}
.ed .ptl,
.ed .ptr {
  display: flex;
  flex-direction: column;
  gap: 14px;
  min-width: 0;
}

@media (min-width: 980px) {
  .layer.full .panel {
    width: min(1120px, 96vw);
  }

  .ed .ptl {
    padding-right: 24px;
    border-right: 1px solid var(--line);
  }

  .ed .hours .times .chip {
    min-width: 0;
    flex: 1;
  }
  .ed .hours .chips.times {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}
@media (min-width: 700px) {
  .layer.full .panel {
    max-height: calc(100% - 48px);
  }
}
/* ===== Dark mode: much darker slate grays ===== */
html[data-theme="dark"],
html:not([data-theme]) {
  --ink: #121519;
  --coal: #181b21;
  --slate: #1f232a;
  --raise: #272c34;
  --panel: #181b21;
  --panel-solid: #181b21;
  --grp-bg: #252a32;
  --rail: #0e1014;
  --toast: #272c34;
  --glass: rgba(18, 21, 25, 0.92);
  --field-focus: #121519;
  --line: rgba(255, 255, 255, 0.07);
  --line2: rgba(255, 255, 255, 0.12);
}
html[data-theme="dark"] .row:hover {
  background: #1d2128;
}
/* ===== Light mode: softened, blended palette (warm neutrals + muted accents) ===== */
html[data-theme="light"] .btn.actbtn {
  box-shadow: none;
}
/* softer fills: tints instead of hard outlines */
html[data-theme="light"] .row:before,
html[data-theme="light"] .row .bar {
  opacity: 0.75;
}
html[data-theme="light"] .grp {
  border-bottom-color: var(--line);
}
html[data-theme="light"] .stat {
  border-left-color: color-mix(in srgb, var(--sc, var(--line2)) 60%, transparent);
}
html[data-theme="light"] .seg button.tone.on:not(.f-all):not(.svc-0) {
  background: color-mix(in srgb, var(--c) 9%, transparent) !important;
  box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--c) 45%, transparent) !important;
}
html[data-theme="light"] .day,
html[data-theme="light"] .chip,
html[data-theme="light"] .seg,
html[data-theme="light"] .input,
html[data-theme="light"] .btn.ghost {
  border-color: var(--line2);
}
/* ===== Light mode: deep gold lead, warmer beige, richer accents ===== */
html[data-theme="light"] .btn.gold:hover {
  filter: none;
}
/* ===== Time slots: booked-load shown as the chip's bottom edge ===== */
.chips.times .chip {
  position: relative;
  overflow: hidden;
  justify-content: center;
  align-items: center;
  line-height: 1;
  padding-top: 0;
  padding-bottom: 0;
}
.chips.times .chip .load {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  top: auto;
  border-radius: 0;
  background: transparent;
  overflow: visible;
}
.chips.times .chip .load i,
#edTimes .chip .load i,
#ptTimes .chip .load i {
  display: block;
  height: 100%;
  border-radius: 0 2px 0 0;
  background: var(--f-time);
}

.chips.times .chip.on .load i {
  background: var(--sel-fg);
  opacity: 0.85;
}

.ed .othertime,
#ptTimes .othertime {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 12px;
}
.othertime .input {
  width: auto;
  min-width: 150px;
  height: 38px;
}
.othertime .legend {
  margin-left: auto;
  display: inline-flex;
  align-items: center;
  font-size: 12px;
  color: var(--mute);
}
.othertime .legend i {
  display: inline-block;
  width: 22px;
  height: 3px;
  border-radius: 0;
  background: var(--f-time);
}
.ed .hours,
#ptTimes .hours {
  gap: 8px;
}
.ed .hr,
#ptTimes .hr {
  align-items: center;
}
/* ===== Guests screen: grouped gray sections ===== */
html[data-theme] .split {
  border-top: 1px solid var(--line2);
}
html[data-theme] .split .l {
  background: var(--rail);
  border-right: 1px solid var(--line2);
}
html[data-theme] .split .r {
  background: var(--ink);
}
html[data-theme] .split .l .gl {
  margin: 2px 10px;
  border-radius: 12px;
  padding-left: 12px;
  padding-right: 12px;
}
html[data-theme] .split .l .gl:hover {
  background: color-mix(in srgb, var(--text) 5%, transparent);
}
html[data-theme] .split .l .gl.sel {
  background: var(--coal);
  box-shadow: inset 0 0 0 1px var(--line2);
}
/* Guests: the search box sits at the top of the guest list (stays put while the list scrolls),
   with the same space above and below it */
html[data-theme] .split .l.gpane {
  padding-top: 0;
}
.gpane .gsearch {
  position: sticky;
  top: 0;
  z-index: 3;
  padding: 12px 10px;
  background: var(--rail);
  border-bottom: 1px solid var(--line2);
}
.gpane .gsearch .search {
  width: 100%;
}
html[data-theme] .split .l.gpane .aday {
  border-top: 0;
}
.profile {
  max-width: 980px;
}
.profile .ph {
  padding: 22px 24px;
  border-radius: 16px;
  border: 1px solid var(--line2);
  background: var(--coal);
  margin-bottom: 14px;
}
.profile .kpis {
  margin-bottom: 14px;
}
.profile > .sec {
  background: var(--coal);
  border: 1px solid var(--line2);
  border-radius: 16px;
  padding: 18px 22px 20px;
  margin: 0 0 14px;
}
.profile > .sec h4 {
  margin: -18px -22px 16px;
  padding: 13px 22px;
  background: var(--slate);
  border-bottom: 1px solid var(--line);
  border-radius: 16px 16px 0 0;
}
.profile > .sec h4:after {
  display: none;
}
html[data-theme="dark"] .profile .kpis,
html:not([data-theme]) .profile .kpis {
  background: var(--coal);
}
html[data-theme="dark"] .profile .kpis div,
html:not([data-theme]) .profile .kpis div {
  background: transparent;
}
@media (max-width: 760px) {
  .profile .ph {
    padding: 16px;
  }
  .profile > .sec {
    padding: 14px 16px 16px;
  }
  .profile > .sec h4 {
    margin: -14px -16px 14px;
    padding: 11px 16px;
  }
}
/* ===== Light mode: bright cream surfaces → light gray ===== */
html[data-theme="light"] .list,
html[data-theme="light"] .colhead,
html[data-theme="light"] .rail,
html[data-theme="light"] aside#detail,
html[data-theme="light"] .split .l {
  background: var(--panel);
  -webkit-backdrop-filter: none;
  backdrop-filter: none;
}
html[data-theme="light"] .ecard,
html[data-theme="light"] .gcard,
html[data-theme="light"] .custcard,
html[data-theme="light"] .tcard,
html[data-theme="light"] .kpis,
html[data-theme="light"] .facts,
html[data-theme="light"] .tb-stats,
html[data-theme="light"] .profile .ph,
html[data-theme="light"] .profile > .sec,
html[data-theme="light"] .lg-card {
  background: var(--panel);
}
html[data-theme="light"] .dp-foot,
html[data-theme="light"] .sh-foot {
  background: var(--panel);
}
/* light mode: page background light gray as well */
/* guest stats: visible separators between each stat */
html[data-theme] .profile .kpis {
  background: var(--line2);
  gap: 1px;
  border: 1px solid var(--line2);
  padding: 0;
}
html[data-theme] .profile .kpis > div {
  background: var(--coal);
  padding: 20px 18px 18px;
  display: flex;
  flex-direction: column;
}
html[data-theme] .profile .kpis .v {
  height: 30px;
  min-height: 30px;
  align-items: flex-end;
}
html[data-theme] .profile .kpis .k {
  margin-top: 10px;
}
html[data-theme] .profile .kpis > div div {
  background: transparent !important;
  padding: 0;
}
/* ===== Wider right panel ===== */
@media (min-width: 1360px) {
  .app {
    grid-template-columns: var(--rail-col) minmax(0, 1fr) 510px;
  }
}
@media (min-width: 1600px) {
  .app {
    grid-template-columns: var(--rail-col) minmax(0, 1fr) 560px;
  }
}
@media (min-width: 1280px) {
  .app[data-view="guests"],
  .app[data-view="servers"],
  .app[data-view="texts"],
  .app[data-view="audit"],
  .app[data-view="staff"] {
    grid-template-columns: var(--rail-col) minmax(0, 1fr) 0 !important;
  }
}
/* ===== Long table names (Chefs Room, Bar 308…) never cut off, and never run into the party size or the
   action button: a wider table column, and a very long name ("Chef's Room +1" with its lock) wraps onto
   two lines inside its box instead of spilling out ===== */
.row,
.colhead {
  grid-template-columns: 30px minmax(0, 1fr) 236px 148px;
}
.row .meta,
.colhead .ch-meta {
  grid-template-columns: 64px 172px;
}
.row .meta .tb {
  max-width: 100%;
  white-space: normal;
  line-height: 1.15;
}
.row .meta .tb .tbn {
  white-space: nowrap;
}
.trow {
  grid-template-columns: auto minmax(0, 1fr) !important;
}
.trow .tno.sm {
  max-width: none;
  min-width: 58px;
  padding: 0 10px;
  white-space: nowrap;
  overflow: visible;
}

@media (max-width: 760px) {
  .row,
  .colhead {
    grid-template-columns: 30px minmax(0, 1fr) auto;
  }
  .row .meta .tb {
    max-width: none;
  }
}
/* stats: a unique color for each */
html[data-theme="dark"],
html:not([data-theme]) {
  --st-covers: #2dd4bf;
  --st-parties: #fda15a;
}
html[data-theme] .stat.g {
  --sc: var(--st-covers);
  border-left-color: var(--st-covers);
}
html[data-theme] .stat.g .v {
  color: var(--st-covers) !important;
}
html[data-theme] .stat.t-party {
  --sc: var(--st-parties);
  border-left-color: var(--st-parties);
}
html[data-theme] .stat.t-party .v {
  color: var(--st-parties) !important;
}
html[data-theme] .stat.t-seated {
  border-left-color: var(--c-seated);
}
html[data-theme] .stat.t-seated .v {
  color: var(--c-seated) !important;
}
html[data-theme] .stat.t-booked {
  border-left-color: var(--c-booked);
}
html[data-theme] .stat.t-booked .v {
  color: var(--c-booked) !important;
}
html[data-theme] .stat.t-waiting {
  border-left-color: var(--c-waiting);
}
html[data-theme] .stat.t-waiting .v {
  color: var(--c-waiting) !important;
}
@media (min-width: 1280px) {
  .app {
    grid-template-columns: var(--rail-col) minmax(0, 1fr) 470px;
  }
}
@media (min-width: 1440px) {
  .app {
    grid-template-columns: var(--rail-col) minmax(0, 1fr) 520px;
  }
}
@media (min-width: 1700px) {
  .app {
    grid-template-columns: var(--rail-col) minmax(0, 1fr) 560px;
  }
}
.pace .lbl {
  white-space: nowrap;
}
/* ===== Nothing gets cut off ===== */
/* guest names + pills wrap instead of truncating */
.row .nm {
  white-space: normal;
  overflow: visible;
  flex-wrap: wrap;
  row-gap: 7px;
}
.row .nm .nmt {
  overflow: visible;
  text-overflow: clip;
  white-space: normal;
  overflow-wrap: anywhere;
  min-width: 0;
}
/* table schedule names wrap */
.tslot .tn {
  white-space: normal;
  overflow: visible;
  text-overflow: clip;
  overflow-wrap: anywhere;
}
/* detail facts: long server/table names wrap and shrink */
.facts .fact .v {
  white-space: normal !important;
  overflow: visible !important;
  text-overflow: clip !important;
  overflow-wrap: anywhere;
  line-height: 1.15;
}
/* Time, Party, Table and Server all the same size (17px) at every screen width; a table or a server's name too long
   for its box breaks onto more lines only between words, never inside one */
.facts .fx-time .v,
.facts .fx-party .v,
.facts .fx-server .v,
.facts .fx-table .v {
  font-size: 17px !important;
}
.facts .fx-server .v,
.facts .fx-table .v {
  padding-top: 0 !important;
}
.facts .fx-table .v {
  overflow-wrap: normal;
  word-break: keep-all;
}
/* phones (under 767px): the four values at 19px */
@media (max-width: 766px) {
  .facts .fx-time .v,
  .facts .fx-party .v,
  .facts .fx-server .v,
  .facts .fx-table .v {
    font-size: 19px !important;
  }
}
.facts .fx-server .v {
  white-space: normal !important;
  overflow: visible !important;
  text-overflow: clip !important;
  overflow-wrap: normal;
  word-break: keep-all;
  max-width: 100%;
}
.row .sub .srv,
.tinfo .srv {
  white-space: nowrap;
}
/* guest stats flow into as many columns as fit */
html[data-theme] .profile .kpis {
  grid-template-columns: repeat(auto-fit, minmax(118px, 1fr));
}
.kpis .k {
  overflow-wrap: anywhere;
}
/* page headers on phones: tools/search take full width */
@media (max-width: 760px) {
  .top .tools {
    min-width: 0 !important;
    width: 100%;
    flex-wrap: wrap;
    justify-content: flex-start !important;
  }
  .top .tools .search {
    width: 100% !important;
  }
}
/* ===== Stats row: everything sits on one bottom line ===== */
.summary {
  align-items: end !important;
}
.stats {
  align-items: flex-end;
}
.stat {
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
}
.stat .k {
  line-height: 1;
  margin-top: 8px;
}
html[data-theme] .pace {
  box-sizing: border-box;
}
.pace .b em {
  font-size: 10px;
}
/* ===== Calendar: remove the busy-level underline (tile color already shows it) ===== */
.cal-d[class*="lv-"]:after,
.cal-d.today[class*="lv-"]:after,
.cal-d.sel[class*="lv-"]:after {
  display: none !important;
}
.cal-d.today:after {
  display: block !important;
  content: "";
  position: absolute;
  top: 6px;
  right: 7px;
  left: auto;
  bottom: auto;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--accent-2);
}
/* ===== Booking window: darker fields and choices ===== */
html[data-theme="dark"] .ed .input,
html[data-theme="dark"] .ed select.input,
html[data-theme="dark"] .ed .chip,
html[data-theme="dark"] .ed .seg,
html[data-theme="dark"] .ed .stepnum,
html[data-theme="dark"] .ed .quick button,
html[data-theme="dark"] #ptTimes .chip,
html[data-theme="dark"] #ptSvc,
html[data-theme="dark"] .ct-party .chip,
html[data-theme="dark"] .pp-step {
  background: #0f1216;
  border-color: rgba(255, 255, 255, 0.1);
}
html[data-theme="dark"] .ed .chip:hover,
html[data-theme="dark"] #ptTimes .chip:hover {
  background: #151920;
}

html[data-theme] .ed .chip.on,
html[data-theme] #ptTimes .chip.on,
html[data-theme] .ct-party .chip.on {
  background: var(--sel-bg) !important;
}
/* ===== Search clear "x" ===== */
.search .sclear {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  border-radius: 50%;
  display: none;
  place-items: center;
  color: var(--mute);
  background: color-mix(in srgb, var(--text) 8%, transparent);
  border: 0;
  cursor: pointer;
  padding: 0;
}
.search .sclear svg {
  position: static;
  color: inherit;
}
.search .sclear:hover {
  color: var(--text);
  background: color-mix(in srgb, var(--text) 14%, transparent);
}
.search.has-v .sclear {
  display: grid;
}
.search.has-v kbd {
  display: none;
}
/* ===== Audit log & Staff: match the Guests page (section cards on the page background) ===== */
html[data-theme] .auditwrap,
html[data-theme] .stafflist {
  background: var(--ink);
  border-top: 1px solid var(--line2);
  padding: 20px var(--pad) calc(40px + var(--sa-b));
}
.auditwrap {
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.asec {
  background: var(--coal);
  border: 1px solid var(--line2);
  border-radius: 16px;
  overflow: hidden;
  max-width: 1100px;
}
html[data-theme="light"] .asec {
  background: var(--panel-solid);
}
html[data-theme] .aday {
  position: sticky;
  top: -20px;
  z-index: 2;
  margin: 0;
  padding: 12px 20px;
  background: var(--slate);
  border-bottom: 1px solid var(--line);
  color: var(--accent-text);
  font-weight: 600;
}
.asec .ae {
  border-bottom: 1px solid var(--line);
}
.asec .ae:last-child {
  border-bottom: 0;
}
.asec .ae:hover {
  background: color-mix(in srgb, var(--text) 3%, transparent);
}
.stafflist {
  display: block;
}
html[data-theme] .stafflist > :not(.skel):not(.empty) {
  max-width: 1100px;
}
.stafflist .srow {
  background: var(--coal);
  border: 1px solid var(--line2);
  border-radius: 14px;
  padding: 14px 18px;
  margin-bottom: 10px;
}
html[data-theme="light"] .stafflist .srow {
  background: var(--panel-solid);
}
.stafflist .srow:hover {
  border-color: color-mix(in srgb, var(--accent-2) 45%, var(--line2));
}
@media (max-width: 760px) {
  html[data-theme] .aday {
    padding: 10px 14px;
  }
  .stafflist .srow {
    padding: 12px 14px;
  }
}
/* ===== Pink (birthday / VIP) pills: more padding ===== */
html[data-theme] .badge.gold,
.dp-id .badge,
.gcard .badge,
.ph .badge {
  padding: 5px 12px !important;
  gap: 7px !important;
  line-height: 1.2;
}
.badge svg {
  flex: none;
}
/* ===== Guest profile: upcoming vs past clearly separated ===== */
.profile > .sec h4 .cnt {
  margin-left: 8px;
  min-width: 22px;
  height: 20px;
  padding: 0 7px;
  border-radius: 10px;
  display: inline-grid;
  place-items: center;
  font-size: 11px;
  letter-spacing: 0;
  background: color-mix(in srgb, var(--text) 10%, transparent);
  color: var(--sub);
}
.profile > .sec.sec-up {
  border-color: color-mix(in srgb, var(--c-booked) 45%, var(--line2));
}
.profile > .sec.sec-up h4 {
  background: color-mix(in srgb, var(--c-booked) 14%, var(--slate));
  color: var(--c-booked);
}
.profile > .sec.sec-up h4 .cnt {
  background: color-mix(in srgb, var(--c-booked) 22%, transparent);
  color: var(--c-booked);
}
.profile > .sec.sec-up .tl .d {
  color: var(--text);
}
.profile > .sec.sec-past h4 {
  color: var(--mute);
}
.profile > .sec.sec-past .tl .d {
  font-weight: 500;
}
html[data-theme="light"] .profile > .sec.sec-up h4 {
  background: color-mix(in srgb, var(--c-booked) 10%, var(--grp-bg));
}
.tcard b,
.tcard .nm {
  white-space: normal !important;
  overflow: visible !important;
  text-overflow: clip !important;
  overflow-wrap: anywhere;
}
.profile .ph .contact a {
  white-space: nowrap;
}
@media (max-width: 760px) {
  .profile .ph {
    flex-wrap: wrap;
    align-items: flex-start;
  }
  .profile .ph > div:last-child {
    flex-direction: row !important;
    flex-wrap: wrap;
    align-items: center !important;
    width: 100%;
    padding-left: 0;
  }
}
/* toasts centered over the main column (between side menu and detail panel) */
:root {
  --dp-w: 0px;
}
@media (min-width: 1280px) {
  :root {
    --dp-w: 470px;
  }
}
@media (min-width: 1440px) {
  :root {
    --dp-w: 520px;
  }
}
@media (min-width: 1700px) {
  :root {
    --dp-w: 560px;
  }
}
:root:has(.app[data-view="guests"]),
:root:has(.app[data-view="servers"]),
:root:has(.app[data-view="texts"]),
:root:has(.app[data-view="audit"]),
:root:has(.app[data-view="staff"]) {
  --dp-w: 0px;
}
@media (min-width: 761px) {
  #toasts {
    left: calc(var(--rail-w) + (100vw - var(--rail-w) - var(--dp-w)) / 2);
  }
}
/* A mark: more breathing room inside the rings */
.mono {
  width: 52px;
  height: 52px;
}
.mono img {
  width: 24px !important;
  transform: translate(1px, 1px);
}
.mono:after {
  inset: 5px;
}
/* ===== Light mode: brighter, cheerful — whites + light grays, crisp accents ===== */
html[data-theme="light"] {
  --coal: #ffffff;
  --raise: #ecece9;
  --panel: #ffffff;
  --panel-solid: #ffffff;
  --rail: #ffffff;
  --toast: #ffffff;
  --glass: rgba(255, 255, 255, 0.95);
  --field-focus: #ffffff;
}
html[data-theme="light"] body {
  background: var(--ink);
}
html[data-theme="light"] .list,
html[data-theme="light"] .colhead,
html[data-theme="light"] .rail,
html[data-theme="light"] aside#detail,
html[data-theme="light"] .split .l,
html[data-theme="light"] .day,
html[data-theme="light"] .chip,
html[data-theme="light"] .seg,
html[data-theme="light"] .input,
html[data-theme="light"] .cal-sel,
html[data-theme="light"] .btn.ghost,
html[data-theme="light"] .btn:not(.gold):not(.actbtn):not(.quiet),
html[data-theme="light"] .ecard,
html[data-theme="light"] .gcard,
html[data-theme="light"] .custcard,
html[data-theme="light"] .tcard,
html[data-theme="light"] .kpis,
html[data-theme="light"] .facts,
html[data-theme="light"] .tb-stats,
html[data-theme="light"] .profile .ph,
html[data-theme="light"] .profile > .sec,
html[data-theme="light"] .lg-card,
html[data-theme="light"] .asec,
html[data-theme="light"] .stafflist .srow,
html[data-theme="light"] .dp-foot,
html[data-theme="light"] .sh-foot {
  background-color: #ffffff;
}
html[data-theme="light"] .colhead,
html[data-theme="light"] .profile > .sec h4,
html[data-theme="light"] .aday,
html[data-theme="light"] .grp {
  background: #f6f6f4;
}
html[data-theme="light"] .gcard .mini div,
html[data-theme="light"] .kpis div,
html[data-theme="light"] .tb-stats > button {
  background: #f6f6f4;
}
html[data-theme="light"] .profile .kpis > div {
  background: #ffffff;
}
html[data-theme="light"] .row:hover {
  background: #fafaf8;
}
html[data-theme="light"] .tcard {
  background: linear-gradient(90deg, color-mix(in srgb, #15803d 6%, #fff), #fff 60%);
}
html[data-theme="light"] .pace .b.past i {
  background: linear-gradient(180deg, rgba(107, 114, 128, 0.4), rgba(107, 114, 128, 0.12));
}
html[data-theme="light"] .ed .input,
html[data-theme="light"] .ed select.input,
html[data-theme="light"] .ed .chip,
html[data-theme="light"] .ed .seg,
html[data-theme="light"] .ed .stepnum,
html[data-theme="light"] .ed .quick button,
html[data-theme="light"] #ptTimes .chip,
html[data-theme="light"] #ptSvc,
html[data-theme="light"] .ct-party .chip,
html[data-theme="light"] .pp-step {
  background: #f1f1ef;
  border-color: rgba(20, 20, 20, 0.12);
}
html[data-theme="light"] .ecard {
  background: #ffffff;
}
/* ===== App shell never scrolls; only individual panels do ===== */
html,
body {
  height: 100%;
  overflow: hidden;
  overscroll-behavior: none;
}
.app {
  width: 100%;
  max-width: 100vw;
  overflow: hidden;
}
.split .l,
.split .r,
.list,
aside#detail .dp-scroll,
.auditwrap,
.stafflist {
  overscroll-behavior: contain;
}
/* ===== Scrollbars match the theme ===== */
* {
  scrollbar-width: thin;
  scrollbar-color: var(--sb-thumb) transparent;
}
html[data-theme="dark"],
html:not([data-theme]) {
  --sb-thumb: rgba(255, 255, 255, 0.16);
  --sb-thumb-h: rgba(255, 255, 255, 0.28);
}
html[data-theme="light"] {
  --sb-thumb: rgba(20, 20, 20, 0.18);
  --sb-thumb-h: rgba(20, 20, 20, 0.32);
}
::-webkit-scrollbar {
  width: 10px;
  height: 10px;
  background: transparent;
}
::-webkit-scrollbar-track {
  background: transparent;
}
::-webkit-scrollbar-thumb {
  background: var(--sb-thumb);
  border-radius: 10px;
  border: 3px solid transparent;
  background-clip: padding-box;
}
::-webkit-scrollbar-thumb:hover {
  background: var(--sb-thumb-h);
  background-clip: padding-box;
  border: 3px solid transparent;
}
::-webkit-scrollbar-corner {
  background: transparent;
}
/* phone: the book screen scrolls as one panel so the list isn't squeezed */
@media (max-width: 760px) {
  .view[data-v="book"],
  main > .view:has(#bkList) {
    overflow-y: auto;
    overscroll-behavior: contain;
  }
  main > .view:has(#bkList) .list {
    flex: none;
    overflow: visible;
    max-height: none;
  }
  main > .view:has(#bkList) .colhead {
    top: 0;
    z-index: 3;
  }
}
/* The board ends just after its last row (5px clears the rounded corners), on every screen size */
main > .view:has(#bkList) .list {
  padding-bottom: 5px;
}
@media (max-width: 760px) {
  main > .view:has(#bkList) .colhead {
    position: static;
  }
  .stats {
    display: grid !important;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 14px 10px !important;
    overflow: visible !important;
    margin: 0 !important;
    padding: 0 !important;
  }
  .stat,
  html[data-theme] .stat {
    min-width: 0 !important;
    flex: none;
  }
  .stat .k {
    white-space: normal !important;
    overflow-wrap: anywhere;
    line-height: 1.2;
  }
  .stat .v {
    font-size: 24px !important;
  }
  main > .view:has(#bkList) .colhead {
    display: none;
  }
  main > .view:has(#bkList) .list {
    border-top: 1px solid var(--line2) !important;
    border-radius: 14px !important;
  }
  .stats {
    align-items: end;
  }
}
/* pink pills: +3px padding all around */
/* stats sit on the chart's baseline (above the hour labels) */
@media (min-width: 761px) {

  .stat {
    padding-bottom: 0;
  }
}
/* current time in the list title bar */
.colhead .ch-guest {
  align-items: center;
  gap: 14px;
}
.ch-clock {
  display: inline-flex;
  align-items: baseline;
  gap: 3px;
  padding: 3px 10px;
  border-radius: 999px;
  font-family: var(--num);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0;
  text-transform: none;
  color: var(--accent-text);
  background: var(--gold-soft);
  border: 1px solid var(--gold-line);
}
.ch-clock:empty {
  display: none;
}
.ch-clock small {
  font-size: 9.5px;
  letter-spacing: 0.08em;
  font-weight: 600;
  opacity: 0.85;
}
.ch-clock:before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: currentColor;
  align-self: center;
  margin-right: 3px;
  animation: clkpulse 2s ease-in-out infinite;
}
@keyframes clkpulse {
  50% {
    opacity: 0.35;
  }
}
/* ===== Light mode: blue theme (no brown/gold) ===== */
html[data-theme="light"] {
  --ivory: #1e40af;
  --blk-text: #ffffff;
}
html[data-theme="light"] .mono img,
html[data-theme="light"] .rail img,
html[data-theme="light"] .orn img,
html[data-theme="light"] .crest-sm img {
  filter: grayscale(1) brightness(0.35) !important;
}
/* ===== Guest profile: each reservation is its own bubble ===== */
.profile > .sec .timeline {
  margin: 0;
  display: grid;
  gap: 10px;
}
.profile > .sec .tl {
  padding: 13px 16px 13px 44px;
  border: 1px solid var(--line2);
  border-left: 4px solid var(--c, var(--line2));
  border-radius: 12px;
  background: var(--slate);
  transition:
    border-color 0.15s,
    background 0.15s;
}
.profile > .sec .tl:before {
  display: none;
}
.profile > .sec .tl .dot {
  left: 16px;
  top: 18px;
}
.profile > .sec .tl:hover {
  background: color-mix(in srgb, var(--c, var(--accent-2)) 8%, var(--slate));
  border-color: color-mix(in srgb, var(--c, var(--accent-2)) 45%, var(--line2));
}
.profile > .sec.sec-past .tl {
  opacity: 1;
  background: transparent;
}
.profile > .sec.sec-past .tl .d,
.profile > .sec.sec-past .tl div {
  color: var(--mute);
}
html[data-theme="light"] .profile > .sec .tl {
  background: #f6f6f4;
}
html[data-theme="light"] .profile > .sec.sec-past .tl {
  background: #ffffff;
}
.colhead .ch-clock {
  order: -1;
}
/* ===== Light mode: softer, less bold accents ===== */
/* ===== Calendar: neutral day tiles, busy level shown as a bold bottom line ===== */
html[data-theme] .cal-d[class*="lv-"] {
  background: var(--coal) !important;
  border: 1px solid var(--line2) !important;
}
html[data-theme="light"] .cal-d[class*="lv-"] {
  background: #ffffff !important;
}
html[data-theme] .cal-d[class*="lv-"] small {
  color: var(--lv) !important;
  font-weight: 700;
}
html[data-theme] .cal-d[class*="lv-"]:hover {
  background: color-mix(in srgb, var(--lv) 8%, var(--coal)) !important;
}
html[data-theme] .cal-d.out[class*="lv-"] {
  opacity: 0.45;
}
html[data-theme] .cal-d.sel,
html[data-theme] .cal-d.sel[class*="lv-"] {
  background: var(--sel-bg) !important;
  border-color: var(--sel-bd) !important;
  border-bottom: 4px solid var(--lv, var(--sel-bd)) !important;
}
html[data-theme] .cal-d.sel small {
  opacity: 0.9;
}
html[data-theme] .cal-legend .lg {
  background: var(--coal) !important;
  border: 1px solid var(--line2) !important;
}
html[data-theme="light"] .cal-legend .lg {
  background: #ffffff !important;
}
/* ===== Light mode: clear, vibrant palette (same transparency/tints) ===== */
/* calendar: bottom line length = how many guests are booked (full width ≈ 160+) */
html[data-theme] .cal-d[class*="lv-"] {
  position: relative;
  overflow: hidden;
  border-bottom: 1px solid var(--line2) !important;
}
html[data-theme] .cal-d.sel[class*="lv-"] {
  border-bottom-color: var(--sel-bd) !important;
}
.cal-d .lvfill {
  position: absolute;
  display: block;
}
.cal-d:not([class*="lv-"]) .lvfill {
  display: none;
}

html[data-theme] .cal-legend .lg {
  position: relative;
  overflow: hidden;
  border-bottom: 1px solid var(--line2) !important;
}
html[data-theme] .cal-legend .lg:after {
  content: "";
  position: absolute;
  background: var(--lv);
}
/* straight bar, kept clear of the rounded corners */
.cal-d .lvfill {
  border-radius: 0;
}
.cal-d .lvfill:before {
  content: "";
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: calc((100% / var(--p, 1)));
  background: color-mix(in srgb, var(--lv) 18%, transparent);
  z-index: -1;
}
html[data-theme] .cal-legend .lg:after {
  border-radius: 0;
}
/* calendar bar v2: flush with the bottom edge, straight ends, faint track shows the full scale */
.cal-d .lvfill {
  width: auto !important;
  background: linear-gradient(
    90deg,
    var(--lv) calc(var(--p, 0) * 100%),
    color-mix(in srgb, var(--lv) 16%, transparent) 0
  ) !important;
}
.cal-d .lvfill:before {
  display: none;
}
html[data-theme] .cal-d.sel small,
html[data-theme="light"] .cal-d.sel[class*="lv-"] small {
  color: #ffffff !important;
}
html[data-theme] .cal-d.sel .lvfill {
  background: linear-gradient(90deg, #ffffff calc(var(--p, 0) * 100%), rgba(255, 255, 255, 0.3) 0) !important;
  box-shadow: none;
}
html[data-theme] .cal-legend .lg:after {
  height: 4px;
}
/* ===== Booking window: reversed grays (sections darker, fields lighter); footer unchanged ===== */
html[data-theme="dark"] .ed .input,
html[data-theme="dark"] .ed select.input,
html[data-theme="dark"] .ed .chip,
html[data-theme="dark"] .ed .seg,
html[data-theme="dark"] .ed .stepnum,
html[data-theme="dark"] .ed .quick button {
  border-color: rgba(255, 255, 255, 0.1) !important;
}
html[data-theme="light"] .ed .input,
html[data-theme="light"] .ed select.input,
html[data-theme="light"] .ed .chip,
html[data-theme="light"] .ed .seg,
html[data-theme="light"] .ed .stepnum,
html[data-theme="light"] .ed .quick button {
  background: #ffffff !important;
  border-color: rgba(20, 20, 20, 0.13) !important;
}
/* pink pills match the status pills exactly */
html[data-theme] .badge.gold,
html[data-theme] .row .badge.gold,
html[data-theme] .dp-id .badge.gold,
html[data-theme] .ph .badge.gold,
html[data-theme] .gcard .badge.gold {
  display: inline-flex !important;
  align-items: center;
  gap: 4px !important;
  height: 22px !important;
  padding: 0 9px !important;
  font-size: 9.5px !important;
  line-height: 1 !important;
  letter-spacing: 0.1em !important;
  text-transform: uppercase;
  font-weight: 650 !important;
  border-radius: 999px;
}
html[data-theme] .badge.gold svg {
  width: 11px;
  height: 11px;
}
@media (max-width: 760px) {
  html[data-theme] .row .badge.gold {
    height: 20px !important;
    padding: 0 7px !important;
    font-size: 9px !important;
  }
}

/* ===== Light mode: palette from the reference swatches (backgrounds unchanged) =====
   navy #1F3667 · steel #3F6D84 · teal #2F7480 · olive #62672A · ochre #7D6424
   terracotta #A85A26 · rose #A84C66 · plum #8A4F7D · brick #B2322F · stone #625F5C
   soft tints: sky #B5D0D2 · mint #B5E1D2 · blush #F2B9BD · cream #F4E9D0 · sun #F3CC58 */
html[data-theme="light"] .mono img,
html[data-theme="light"] .rail img {
  filter: grayscale(1) brightness(0.3) !important;
}
html[data-theme="light"] #login {
  background: radial-gradient(1100px 600px at 50% -10%, rgba(97, 172, 187, 0.16), transparent 60%), #f1f1ef;
}
/* calendar: all four corners rounded again; line sits along the inside bottom of each block */
html[data-theme] .cal-d[class*="lv-"] {
  border-radius: 12px !important;
}
@media (max-width: 760px) {
  html[data-theme] .cal-d[class*="lv-"] {
    border-radius: 10px !important;
  }
}
.cal-d .lvfill {
  left: 10px !important;
  right: 10px !important;
  height: 4px;
}
html[data-theme] .cal-legend .lg {
  border-radius: 10px !important;
  padding-bottom: 16px;
}
html[data-theme] .cal-legend .lg:after {
  left: 10px;
  bottom: 6px;
}
.cal-legend .lg.lv-quiet:after {
  width: calc((100% - 20px) * 0.2);
}
.cal-legend .lg.lv-steady:after {
  width: calc((100% - 20px) * 0.45);
}
.cal-legend .lg.lv-busy:after {
  width: calc((100% - 20px) * 0.72);
}
.cal-legend .lg.lv-full:after {
  width: calc(100% - 20px);
}
html[data-theme] .cal-d[class*="lv-"] {
  padding-bottom: 10px !important;
  height: 58px !important;
}
@media (max-width: 760px) {
  html[data-theme] .cal-d[class*="lv-"] {
    height: 54px !important;
  }
}
.cal-d small {
  margin-bottom: 0 !important;
}
.cal-d .lvfill {
  bottom: 6px !important;
}
html[data-theme] .cal-d.sel[class*="lv-"] {
  border: 1px solid var(--sel-bd) !important;
}
/* light mode buttons = dark mode buttons */
html[data-theme="light"] .a-assign {
  --a: #fb923c;
}
html[data-theme="light"] .a-seat {
  --a: #4ade80;
}
html[data-theme="light"] .a-finish {
  --a: #60a5fa;
}
html[data-theme="light"] .btn.actbtn {
  --on-a: #0a0a0a;
  color: #0a0a0a;
}
html[data-theme="light"] .btn.actbtn svg {
  color: #0a0a0a;
}
html[data-theme="light"] .btn.actbtn:hover {
  background: color-mix(in srgb, var(--a) 88%, #fff);
}
html[data-theme="light"] .btn.gold:hover {
  background: #1d4ed8 !important;
}
/* clear "x": smaller, on every search box; hide Safari's contact-autofill icon that collided with it */
.search .sclear {
  width: 20px !important;
  height: 20px !important;
  right: 10px !important;
}
.search .sclear svg {
  width: 11px !important;
  height: 11px !important;
  stroke-width: 2.4;
}
.search .input {
  padding-right: 38px;
}
.search input::-webkit-contacts-auto-fill-button,
.search input::-webkit-credentials-auto-fill-button {
  visibility: hidden;
  display: none !important;
  pointer-events: none;
  position: absolute;
  right: 0;
}
.search input::-webkit-search-cancel-button {
  display: none;
}
/* ===== Light mode uses the exact dark-mode accent colors (backgrounds stay light) ===== */
html[data-theme="light"] {
  --sel-bg: #2563eb;
  --sel-bd: #2563eb;
  --sel-fg: #ffffff;
  --accent: #2563eb;
  --accent-2: #60a5fa;
  --blk: #2563eb;
  --gold-lo: #60a5fa;
  --gold-soft: rgba(96, 165, 250, 0.14);
  --gold-line: rgba(96, 165, 250, 0.6);
  --row-sel: rgba(96, 165, 250, 0.1);
  --lv-quiet: #4ade80;
  --lv-steady: #facc15;
  --lv-busy: #fda15a;
  --lv-full: #fb8f8f;
}
html[data-theme="light"] .row.sel {
  background: #eef5ff !important;
}
html[data-theme="light"] .pace .b i {
  background: linear-gradient(180deg, #60a5fa, rgba(96, 165, 250, 0.3));
}
html[data-theme="light"] .pace .now,
html[data-theme="light"] .pace .now:before {
  background: #60a5fa;
}
html[data-theme="light"] .ch-clock {
  color: #2563eb;
  background: rgba(96, 165, 250, 0.14);
  border-color: rgba(96, 165, 250, 0.6);
}
html[data-theme="light"] .mono:before {
  border-color: rgba(96, 165, 250, 0.7);
}
html[data-theme="light"] .mono:after {
  border-color: rgba(96, 165, 250, 0.2);
}
html[data-theme="light"] .avatar.gold {
  background: #eef5ff;
  color: #2563eb;
  border-color: rgba(96, 165, 250, 0.6);
}
html[data-theme="light"] .grp .t {
  border-left-color: #60a5fa;
}
/* booking window (dark): lighter section cards */
html[data-theme="dark"] .ed .ecard {
  border-color: rgba(255, 255, 255, 0.09) !important;
}
/* booking window sections: lifted from near-black to the reference gray */
html[data-theme="dark"] .layer.full .panel,
html[data-theme="dark"] .layer.full .sh-head {
  background: #23272e;
}
/* booking sections: previous colors, section fill at ~60% opacity (40% lighter) */
html[data-theme="dark"] .ed .ecard {
  background: rgba(25, 28, 31, 0.6) !important;
}
/* booking: separator runs full height; "Other date" on its own line; selected chips stable on hover */
@media (min-width: 980px) {
  .ed .ptl {
    align-self: stretch;
  }
}

html[data-theme] .ed .chip.on,
html[data-theme] .ed .chip.on:hover,
html[data-theme] .ed .chip.on:active,
html[data-theme] .ed .chip.on:focus,
html[data-theme] #ptTimes .chip.on,
html[data-theme] #ptTimes .chip.on:hover,
html[data-theme] .ct-party .chip.on:hover {
  background: var(--sel-bg) !important;
  border-color: var(--sel-bd) !important;
  color: var(--sel-fg) !important;
}
html[data-theme] .ed .chip.on * {
  color: var(--sel-fg) !important;
}
.ed .chip {
  transition: none !important;
}
/* request shortcut buttons: pink outline */
html[data-theme] .ed .quick button {
  border: 1px solid color-mix(in srgb, var(--f-request) 60%, transparent) !important;
  color: var(--f-request) !important;
}
html[data-theme] .ed .quick button:hover {
  background: color-mix(in srgb, var(--f-request) 12%, transparent) !important;
  border-color: var(--f-request) !important;
}
/* ===== Light mode: same hues, deeper tones for readable text (all ≥ 4.5:1 on white & light gray) ===== */
html[data-theme="light"] {
  --faint: #9ca3af;
  --accent-text: #1d4ed8;
  --gold: #1d4ed8;
  --gold-hi: #1e40af;
  --c-hold: #c2410c;
  --c-checkdate: #be185d;
  --c-waiting: #7e22ce;
  --c-finished: #4b5563;
  --c-noshow: #b91c1c;
  --c-cancelled: #57534e;
  --c-dinner: #b91c1c;
  --f-time: #1d4ed8;
  --f-party: #0f766e;
  --f-table: #c2410c;
  --f-server: #7e22ce;
  --f-request: #be185d;
  --st-covers: #0f766e;
  --st-parties: #c2410c;
  --rust: #b91c1c;
}
/* dots/bars/calendar lines keep the bright dark-mode colors; only text gets the deeper tones */
html[data-theme="light"] .row:before {
  opacity: 1;
}
html[data-theme="light"] .stars svg {
  stroke: #ca8a04;
}
html[data-theme="light"] .stars svg.on {
  fill: #eab308;
  stroke: #ca8a04;
}
html[data-theme="light"] .row .nm .vip {
  color: #ca8a04;
}
html[data-theme="light"] .cal-d[class*="lv-quiet"] small {
  color: #166534 !important;
}
html[data-theme="light"] .cal-d[class*="lv-steady"] small {
  color: #854d0e !important;
}
html[data-theme="light"] .cal-d[class*="lv-busy"] small {
  color: #c2410c !important;
}
html[data-theme="light"] .cal-d[class*="lv-full"] small {
  color: #b91c1c !important;
}
html[data-theme="light"] .cal-legend .lg.lv-quiet b {
  color: #166534;
}
html[data-theme="light"] .cal-legend .lg.lv-steady b {
  color: #854d0e;
}
html[data-theme="light"] .cal-legend .lg.lv-busy b {
  color: #c2410c;
}
html[data-theme="light"] .cal-legend .lg.lv-full b {
  color: #b91c1c;
}
html[data-theme="light"] .ed .quick button {
  border-color: color-mix(in srgb, #be185d 50%, transparent) !important;
}
html[data-theme="light"] .eyebrow,
html[data-theme="light"] .colhead,
html[data-theme="light"] .stat .k,
html[data-theme="light"] .el,
html[data-theme="light"] .fact .k,
html[data-theme="light"] .sec h4 {
  color: #52525b !important;
}
html[data-theme="light"] .row .sub,
html[data-theme="light"] .grp .m {
  color: #333333;
}
/* ===== Light mode: Airtable-style — near-black text, soft solid status pills with dark text,
   cool light-gray group headers. (Peach/beige tints intentionally not used.) ===== */
html[data-theme="light"] {
  --text: #232429;
  --sub: #3e4046;
  --mute: #5c5f66;
  --grp-bg: #f6f8fb;
  --slate: #f6f8fb;
  --ink: #f2f2f2;
  --line: rgba(0, 0, 0, 0.09);
  --line2: rgba(0, 0, 0, 0.16);
}
html[data-theme="light"] .s-booked {
  --pill: #99d8fb;
}
html[data-theme="light"] .s-confirmed {
  --pill: #a6c4fa;
}
html[data-theme="light"] .s-seated {
  --pill: #a8dd9b;
}
html[data-theme="light"] .s-checkdate {
  --pill: #f8d67b;
}
html[data-theme="light"] .s-hold {
  --pill: #ffc59e;
}
html[data-theme="light"] .s-waiting {
  --pill: #d3c2f7;
}
html[data-theme="light"] .s-finished {
  --pill: #d7dadf;
}
html[data-theme="light"] .s-noshow {
  --pill: #ffaba6;
}
html[data-theme="light"] .s-cancelled {
  --pill: #e1dedb;
}
html[data-theme="light"] .row .st,
html[data-theme="light"] .row .nm .npill,
html[data-theme="light"] .badge.tn,
html[data-theme="light"] .tl .st {
  background: var(--pill, #e5e7eb) !important;
  color: #232429 !important;
  border-color: transparent !important;
  font-weight: 600;
}
html[data-theme="light"] .row .nm .npill svg {
  color: #232429;
}
/* dots, row bars, filter swatches use the pill colors' deeper twins so they read on white */
html[data-theme="light"] .s-booked {
  --c: #2b8fd6;
}
html[data-theme="light"] .s-confirmed {
  --c: #4f72dc;
}
html[data-theme="light"] .s-checkdate {
  --c: #c99a12;
}
html[data-theme="light"] .s-hold {
  --c: #d9772e;
}
html[data-theme="light"] .s-waiting {
  --c: #8b62d9;
}
html[data-theme="light"] .s-finished {
  --c: #7a7f88;
}
html[data-theme="light"] .s-noshow {
  --c: #d9483f;
}
html[data-theme="light"] .colhead,
html[data-theme="light"] .grp {
  background: #f6f8fb !important;
}
html[data-theme="light"] .list {
  background: #ffffff;
}
html[data-theme="light"] .rail,
html[data-theme="light"] .split .l {
  background: #f2f2f2;
}
html[data-theme="light"] .badge.gold {
  background: #fbc7e0 !important;
  border-color: transparent !important;
  color: #232429 !important;
}
html[data-theme="light"] .row .meta .tb:not(.none),
html[data-theme="light"] .tno {
  border-color: transparent !important;
  color: #232429 !important;
}
html[data-theme="light"] .stp.done i,
html[data-theme="light"] .stp.cur i {
  background: var(--sc);
  border-color: var(--sc);
}
html[data-theme="light"] .row .meta .tb:not(.none),
html[data-theme="light"] .tno {
  background: #ffc59e !important;
}
/* booking window: equal spacing around and between the 5 sections; light-mode sections get a soft tint */
.layer.full .sh-body.ed {
  padding: 20px !important;
  gap: 20px !important;
}

@media (max-width: 760px) {
  .layer.full .sh-body.ed {
    padding: 14px !important;
    gap: 14px !important;
  }
}
html[data-theme="light"] .layer.full .panel,
html[data-theme="light"] .layer.full .sh-head,
html[data-theme="light"] .layer.full .sh-body {
  background: #ffffff !important;
}
html[data-theme="light"] .ed .ecard {
  background: #f4f6f9 !important;
  border-color: rgba(0, 0, 0, 0.07) !important;
}
/* small dialogs (table, server, party, time…): header shares the panel color so the sub-line isn't clipped */
html[data-theme] .layer:not(.full) .sh-head {
  background: transparent !important;
}
html[data-theme="light"] .layer:not(.full) .panel {
  background: #ffffff !important;
}
.layer:not(.full) .sh-body > .muted:first-child {
  position: relative;
  z-index: 1;
}
/* ===== All pop-ups share one theme: plain header & footer, tinted center area ===== */
html[data-theme="light"] .layer .panel,
html[data-theme="light"] .layer .sh-head,
html[data-theme="light"] .layer .sh-foot {
  background: #ffffff !important;
}
html[data-theme="dark"] .layer .panel,
html[data-theme="dark"] .layer .sh-head {
  background: #23272e !important;
}
html[data-theme] .layer:not(.full) .sh-body {
  border-top: 1px solid var(--line);
  padding-top: 18px !important;
}
html[data-theme="light"] .layer:not(.full) .sh-body {
  background: #f4f6f9 !important;
}
html[data-theme="dark"] .layer:not(.full) .sh-body {
  background: rgba(25, 28, 31, 0.6) !important;
}
.layer:not(.full) .sh-body > .muted:first-child {
  margin-top: 0 !important;
}
html[data-theme="light"] .layer:not(.full) .sh-body .input,
html[data-theme="light"] .layer:not(.full) .sh-body .chip,
html[data-theme="light"] .layer:not(.full) .sh-body .btn.ghost {
  background: #ffffff;
}
html[data-theme] .layer:not(.full) .sh-head {
  padding-bottom: 16px;
}
/* calendar + confirm dialogs follow the same pop-up theme */
html[data-theme] .layer .cal,
html[data-theme] .layer .dlg-body {
  border-top: 1px solid var(--line);
}
html[data-theme="light"] .layer .cal,
html[data-theme="light"] .layer .dlg-body {
  background: #f4f6f9 !important;
}
html[data-theme="dark"] .layer .cal,
html[data-theme="dark"] .layer .dlg-body {
  background: rgba(25, 28, 31, 0.6) !important;
}
html[data-theme] .layer .cal {
  padding-top: 16px;
}
html[data-theme] .layer .cal-top {
  padding-bottom: 16px;
}
html[data-theme="light"] .layer .cal .btn,
html[data-theme="light"] .layer .cal .chip {
  background: #ffffff;
}
/* dark pop-ups: fields/buttons match the header color; footer a darker gray */
html[data-theme="dark"] .layer:not(.full) .sh-body .input,
html[data-theme="dark"] .layer:not(.full) .sh-body select.input,
html[data-theme="dark"] .layer:not(.full) .sh-body .chip,
html[data-theme="dark"] .layer:not(.full) .sh-body .btn.ghost,
html[data-theme="dark"] .layer:not(.full) .sh-body .seg,
html[data-theme="dark"] .layer:not(.full) .sh-body .stepnum,
html[data-theme="dark"] .layer .cal .btn,
html[data-theme="dark"] .layer .cal .chip,
html[data-theme="dark"] .layer .dlg-body .input {
  background: #23272e !important;
}
html[data-theme="dark"] .layer:not(.full) .sh-body .chip:hover,
html[data-theme="dark"] .layer:not(.full) .sh-body .btn.ghost:hover {
  background: #2b3038 !important;
}
html[data-theme="dark"] .layer .sh-foot {
  background: #15181c !important;
}
/* same for every pop-up, including Book a table / Walk-in */
html[data-theme="dark"] .layer .sh-body .input,
html[data-theme="dark"] .layer .sh-body select.input,
html[data-theme="dark"] .layer .sh-body .chip,
html[data-theme="dark"] .layer .sh-body .btn.ghost,
html[data-theme="dark"] .layer .sh-body .seg,
html[data-theme="dark"] .layer .sh-body .stepnum,
html[data-theme="dark"] .layer .sh-body .quick button,
html[data-theme="dark"] .ed .input,
html[data-theme="dark"] .ed select.input,
html[data-theme="dark"] .ed .chip,
html[data-theme="dark"] .ed .seg,
html[data-theme="dark"] .ed .stepnum,
html[data-theme="dark"] .ed .quick button {
  background: #23272e !important;
}
html[data-theme="dark"] .layer .sh-body .chip:hover,
html[data-theme="dark"] .ed .chip:hover,
html[data-theme="dark"] .layer .sh-body .btn.ghost:hover {
  background: #2b3038 !important;
}
html[data-theme] .ed .chip.on,
html[data-theme] .layer .chip.on,
html[data-theme] .ed .seg button.on {
  background: var(--sel-bg) !important;
}
html[data-theme] .ed .seg button.tone.on:not(.f-all):not(.svc-0) {
  background: color-mix(in srgb, var(--c) 14%, transparent) !important;
}
/* walk-in Seat now / Add to waitlist: selected option gets its color fill back */
.mode-switch .mode-seat {
  --c: var(--c-seated);
}
.mode-switch .mode-wait {
  --c: var(--c-waiting);
}
html[data-theme] .layer .sh-body .mode-switch .btn.on {
  background: color-mix(in srgb, var(--c) 16%, transparent) !important;
  border-color: var(--c) !important;
  box-shadow: inset 0 0 0 1px var(--c);
  color: var(--c) !important;
}
html[data-theme="dark"] .layer .sh-body .mode-switch .btn.on {
  background: color-mix(in srgb, var(--c) 24%, transparent) !important;
}
html[data-theme="light"] .layer .sh-body .mode-switch .btn.on {
  background: color-mix(in srgb, var(--c) 16%, #fff) !important;
}
/* FINAL: a selected chip/time/table stays solid blue even while hovered or pressed (beats every hover rule) */
html[data-theme][data-theme] body .layer .chip.on,
html[data-theme][data-theme] body .layer .chip.on:hover,
html[data-theme][data-theme] body .layer .chip.on:active,
html[data-theme][data-theme] body .layer .chip.on:focus,
html[data-theme][data-theme] body .ed .chip.on,
html[data-theme][data-theme] body .ed .chip.on:hover,
html[data-theme][data-theme] body .ed .chip.on:active {
  background: var(--sel-bg) !important;
  border-color: var(--sel-bd) !important;
  color: var(--sel-fg) !important;
  transition: none !important;
}
html[data-theme][data-theme] body .layer .chip.on * {
  color: var(--sel-fg) !important;
}
html[data-theme][data-theme] body .layer .chip.on .load i {
  background: var(--sel-fg) !important;
}
/* Party size + Time on the left, Date on the right */
.ed .ptl .erow + .erow {
  padding-top: 14px;
  border-top: 1px solid var(--line);
}
/* undo column swap: Date + Party size left, Time right */

/* clock pinned to the far left of the header row; "Guest" lines up with the guest-name column */
.colhead .ch-guest {
  display: block;
}

.colhead .ch-clock:before {
  display: none;
}

.colhead .ch-clock small {
  margin-left: 1px;
}
/* ===== Tablet / desktop: compact header area so the guest list gets more height ===== */
@media (min-width: 761px) and (max-width: 1376px) {
  html[data-theme] .top {
    padding-top: calc(14px + var(--sa-t));
    align-items: center;
    flex-wrap: nowrap;
  }
  html[data-theme] .top h1 {
    font-size: 28px;
  }
  .top .title {
    flex: none;
  }
  .top .tools {
    flex: 1;
    justify-content: flex-end;
  }
  html[data-theme] .strip {
    padding-top: 12px;
  }
  html[data-theme] .day {
    height: 56px;
    border-radius: 12px;
  }
  html[data-theme] .day .dn {
    font-size: 18px;
  }
  html[data-theme] .summary {
    padding-top: 12px;
    padding-bottom: 0;
    gap: 20px;
  }
  html[data-theme] .stat .v {
    font-size: 24px !important;
  }
  html[data-theme] .pace {
    height: 64px;
  }
  /* every filter on one row */
  html[data-theme] .bar {
    padding-top: 10px;
    padding-bottom: 10px;
    gap: 8px;
    scrollbar-width: none;
  }
  html[data-theme] .bar::-webkit-scrollbar {
    display: none;
  }
  html[data-theme] .bar .seg {
    flex: none;
  }
  html[data-theme] .bar .seg button {
    height: 32px;
    padding: 0 10px;
    font-size: 13px;
  }
  html[data-theme] .bar .seg button .n {
    margin-left: 4px;
  }
  html[data-theme] .bar .sync {
    white-space: nowrap;
  }
}
/* narrower tablets: the date title sits above the toolbar again */
@media (min-width: 761px) and (max-width: 1100px) {
  html[data-theme] .top {
    flex-wrap: nowrap;
  }
  .top .tools .search {
    min-width: 120px;
  }
}
/* right panel 50px narrower on iPad landscape */
@media (min-width: 1280px) and (max-width: 1439px) {
  .app {
    grid-template-columns: var(--rail-col) minmax(0, 1fr) 420px;
  }
  :root {
    --dp-w: 420px;
  }
}
/* header clock: plain text so longer times (12:12 AM) never collide with "Guest" */

@media (min-width: 1101px) and (max-width: 1376px) {
  html[data-theme] .top {
    gap: 16px;
  }
  .top .tools {
    flex-wrap: nowrap !important;
    gap: 8px;
  }
  .top .tools .datenav {
    flex: none;
    gap: 4px;
  }
  .top .tools .datenav .btn.icon {
    width: 36px;
    padding: 0;
  }
  .top .tools .datenav .btn:not(.icon) {
    padding: 0 12px;
  }
  .top .tools .search {
    flex: 1 1 120px;
    min-width: 110px;
  }
  .top .tools .newbtn {
    flex: none;
  }
  html[data-theme] .top h1 {
    font-size: 26px;
  }
}
@media (min-width: 761px) and (max-width: 1376px) {
  html[data-theme] .bar .sync {
    font-size: 0;
    gap: 0;
  }
  html[data-theme] .bar .sync *:not(i):not(.dot) {
    display: none;
  }
}

/* Booking window: 5-card grid (tablet/desktop), stacked on phones */
.ed .ptr .erow {
  padding-top: 0 !important;
  border-top: 0 !important;
}
.ed .ptr .ev {
  display: flex;
  flex-direction: column;
  gap: 12px;
}
@media (min-width: 761px) {
  .layer.full .sh-body.ed {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    grid-template-areas: "guest time" "dp time" "req seat" "warn warn";
    /* rows never shrink below their cards, so when the form scrolls nothing is squashed or overlaps */
    grid-template-rows: max-content minmax(max-content, 1fr) max-content max-content;
    align-content: start;
  }
  .ed .ec-guest {
    grid-area: guest;
  }
  .ed .ec-dp {
    grid-area: dp;
  }
  .ed .ec-time {
    grid-area: time;
  }
  .ed .ec-seat {
    grid-area: seat;
  }
  .ed .ec-req {
    grid-area: req;
  }
  .ed #edWarn {
    grid-area: warn;
  }
  .ed #edWarn:empty {
    display: none;
  }
  .ed .ecard .erow {
    grid-template-columns: 1fr !important;
    gap: 8px !important;
  }
  .ed .ecard .el {
    padding-top: 0 !important;
  }
  .ed .ecard .input,
  .ed .ecard select {
    max-width: none !important;
  }
  .ed .ptl .erow + .erow {
    padding-top: 12px !important;
  }
  .ed .chip {
    height: 36px !important;
  }
  .ed .hours .times .chip {
    height: 34px !important;
  }
  .ed .ec-req .quick {
    margin-top: 0;
  }
}
@media (min-width: 761px) and (max-height: 900px) {
  .ed .ecard > header h5 {
    font-size: 17px !important;
  }
  .ed .hours {
    gap: 6px !important;
  }
  .ed .hours .times .chip {
    height: 32px !important;
  }
  .ed .chip {
    height: 34px !important;
  }
}
/* Filter bar: keep on one row on iPad */
@media (min-width: 761px) and (max-width: 1439px) {
  html[data-theme] .bar {
    gap: 6px;
  }
  html[data-theme] .bar .seg button {
    padding: 0 8px;
    font-size: 12.5px;
  }
}
/* Light: vibrant seated green */
html[data-theme="light"] {
  --c-seated: #15803d;
  --sage: #15803d;
}
html[data-theme="light"] .s-seated {
  --c: #16a34a;
}
/* Booking window compaction (tablet/desktop) */
@media (min-width: 761px) {
  .ed .ptl {
    padding-right: 0 !important;
    border-right: 0 !important;
  }
  .layer.full .sh-body.ed {
    gap: 12px !important;
    padding: 14px 16px !important;
  }
  .layer.full:has(.ed) .sh-head {
    padding-top: 14px !important;
    padding-bottom: 12px !important;
  }
  .layer.full:has(.ed) .sh-head h3 {
    font-size: 22px !important;
    margin-top: 2px !important;
  }
  .ed .ecard {
    padding: 14px 16px !important;
    gap: 10px !important;
  }
  .ed .ec-seat {
    display: grid !important;
    column-gap: 14px;
    align-content: start;
  }
  .ed .ec-seat > header {
    grid-column: 1/-1;
  }
  .ed .ec-seat .erow + .erow {
    padding-top: 0 !important;
    border-top: 0 !important;
  }
  .ed .ec-req .erow + .erow {
    padding-top: 10px !important;
  }
  .ed .ec-req .erow:last-child {
    grid-template-columns: auto minmax(0, 1fr) !important;
    gap: 14px !important;
  }
  .ed .ec-req .ev-inline {
    display: flex;
    align-items: center;
    gap: 14px;
  }
  .ed .ec-req #edStatus {
    max-width: 200px !important;
  }
  .ed .bigparty > span:first-child {
    display: none;
  }
  .ed .bigparty {
    padding-left: 8px !important;
    margin-left: 0 !important;
    border-left: 0 !important;
  }
  .ed #edParty .chip {
    min-width: 36px !important;
    padding: 0 6px !important;
  }
  .ed .ptr .ev {
    gap: 10px;
  }
  .ed .othertime {
    margin-top: 8px !important;
  }
  .ed .ecard .erow {
    align-content: start !important;
    align-items: start;
  }
  .ed .ec-req .erow:last-child {
    align-items: center !important;
  }
}
@media (min-width: 761px) and (max-height: 860px) {
  .ed .ecard > header {
    margin-bottom: -2px;
  }
  .ed .hours .times .chip {
    height: 30px !important;
  }
  .ed .hours {
    gap: 5px !important;
  }
  .ed .quick button {
    padding-top: 3px !important;
    padding-bottom: 3px !important;
  }
  .ed .ecard {
    gap: 8px !important;
  }
  .ed .ptl .erow + .erow {
    padding-top: 8px !important;
  }
  .layer.full:has(.ed) .panel {
    max-height: calc(100% - 20px) !important;
  }
  .layer.full:has(.ed) .sh-head .eyebrow {
    display: none;
  }
  .layer.full:has(.ed) .sh-head {
    padding-top: 12px !important;
    padding-bottom: 8px !important;
  }
  .layer.full:has(.ed) .sh-foot {
    padding-top: 10px !important;
    padding-bottom: 10px !important;
  }
  .ed .ecard > header h5 {
    font-size: 16px !important;
  }
  .ed .ec-seat #edTableS {
    margin-top: 6px !important;
  }
  .ed .ec-req .erow + .erow {
    padding-top: 8px !important;
  }
  .layer.full .sh-body.ed {
    padding: 10px 14px !important;
  }
}
/* Confirm button = Confirmed pill color */
html[data-theme] .btn.stbtn,
html[data-theme] .btn.stbtn:hover {
  background: color-mix(in srgb, var(--c) 20%, transparent) !important;
  border: 1px solid color-mix(in srgb, var(--c) 55%, transparent) !important;
  color: var(--c) !important;
  font-weight: 600;
}
html[data-theme] .btn.stbtn:hover {
  background: color-mix(in srgb, var(--c) 28%, transparent) !important;
}
html[data-theme="light"] .btn.stbtn,
html[data-theme="light"] .btn.stbtn:hover {
  background: var(--pill) !important;
  border-color: transparent !important;
  color: #232429 !important;
}
/* fit 1366x925 exactly */
@media (min-width: 761px) and (max-height: 940px) {
  .layer.full .sh-body.ed {
    padding-top: 12px !important;
    padding-bottom: 12px !important;
  }
}
/* Guest column title removed; clock sits in its place */
html[data-theme] .colhead .ch-guest {
  padding-left: 6px !important;
}
/* Collapsible left sidebar */
:root {
  --rail-col: calc(84px + var(--sa-l));
  --rail-w: var(--rail-col);
}
.railbtn {
  width: 40px;
  height: 32px;
  border-radius: 10px;
  display: grid;
  place-items: center;
  cursor: pointer;
}

.railbtn .i,
.railtab .i {
  width: 18px;
  height: 18px;
}
.railtab {
  display: none;
}
@media (min-width: 761px) {
  html.rail-off {
    --rail-col: var(--sa-l);
  }
  html.rail-off .rail {
    visibility: hidden !important;
    overflow: hidden !important;
    padding: 0 !important;
    border: 0 !important;
    min-width: 0 !important;
    width: 0 !important;
  }
  html.rail-off .railtab {
    display: grid;
    place-items: center;
    position: fixed;
    left: calc(var(--sa-l));
    top: 50%;
    transform: translateY(-50%);
    z-index: 40;
    width: 22px;
    height: 56px;
    border-radius: 0 10px 10px 0;
    border: 1px solid var(--line);
    border-left: 0;
    background: var(--panel-solid, var(--panel));
    color: var(--mute);
    cursor: pointer;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12);
    padding: 0;
  }
  .app {
    transition: grid-template-columns 0.2s ease;
  }
}
@media (max-width: 760px) {
  .railbtn {
    display: none;
  }
}
@media (min-width: 761px) {
  .top .title {
    flex: none !important;
    min-width: max-content;
  }
  .top .tools {
    min-width: 0;
  }
}
/* Date nav beside the day strip on screens below 1366px */
.striprow {
  display: contents;
}
.dn-strip {
  display: none !important;
}
@media (min-width: 761px) and (max-width: 1376px) {
  .top .tools .datenav:not(.dn-strip) {
    display: none !important;
  }
  .striprow {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px var(--strip-px, 28px) 0;
  }
  .striprow .dn-strip {
    display: flex !important;
    flex: none;
    gap: 4px;
  }
  .striprow .dn-strip .btn {
    height: 40px;
  }
  .striprow .dn-strip .btn.icon {
    width: 36px;
    padding: 0;
  }
  .striprow .dn-strip .btn:not(.icon) {
    padding: 0 12px;
  }
  html[data-theme] .striprow .strip {
    flex: 1;
    min-width: 0;
    padding: 0 !important;
  }
}
/* Day buttons: 3px more padding top and bottom */
@media (min-width: 761px) {
  html[data-theme] .day {
    height: 62px;
  }
}
@media (min-width: 1377px) {
  html[data-theme] .day {
    height: 76px;
  }
}
@media (min-width: 761px) and (max-width: 1376px) {
  .top .tools {
    flex-wrap: nowrap !important;
    gap: 8px;
  }

}
@media (min-width: 761px) and (max-width: 1100px) {
  .top .tools .newbtn.ghost .lbl-long {
    display: none;
  }
  .top .tools .newbtn.ghost {
    width: 44px;
    padding: 0;
    justify-content: center;
  }
}
/* Light: status indicator colors follow their pill colors */
html[data-theme="light"] {
  --c-confirmed: #4263d6;
  --c-booked: #0369a1;
}
/* Stats half width, pace graph the other half */
@media (min-width: 761px) {
  html[data-theme] .summary {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: 24px !important;
    align-items: end !important;
  }
  html[data-theme] .summary .stats {
    min-width: 0;
    width: 100%;
  }
  html[data-theme] .summary .stat {
    min-width: 0;
    padding-left: 10px !important;
  }
  html[data-theme] .summary .stat .l {
    white-space: normal !important;
    font-size: 10px !important;
    letter-spacing: 0.08em !important;
    line-height: 1.25;
  }
  html[data-theme] .summary .pace {
    width: 100% !important;
    max-width: none !important;
    flex: none !important;
    min-width: 0;
  }
  html[data-theme] .summary .stat {
    overflow: hidden;
  }
  html[data-theme] .summary .stat .k {
    white-space: normal !important;
    overflow-wrap: normal;
    font-size: 10px !important;
    line-height: 1.3;
    max-width: 100%;
  }
  html[data-theme] .summary .stats {
    grid-template-columns: repeat(5, auto) !important;
    gap: 8px !important;
  }
  html[data-theme] .summary .stat .k {
    letter-spacing: 0.05em !important;
  }
}
/* Sidebar collapse button: highlight color, darker on hover */
html[data-theme] .railbtn,
html[data-theme] .railtab {
  border-color: transparent !important;
}
html[data-theme="dark"] .railbtn:hover,
html[data-theme="dark"] .railtab:hover {
  background: #3b82f6 !important;
}
html[data-theme] .railbtn {
  margin-bottom: 6px;
}
/* Clock: pinned to the header's left corner as a tinted pill */
html[data-theme] .colhead {
  position: relative;
}
html[data-theme] .colhead .ch-clock {
  position: absolute !important;
  display: inline-flex;
  align-items: center;
  color: var(--accent-text) !important;
  white-space: nowrap;
  line-height: 1;
}

html[data-theme="dark"] .colhead .ch-clock {
  color: #93b4ff !important;
}
/* Collapse button: white with blue arrow; blue on hover */
html[data-theme] .railbtn,
html[data-theme] .railtab {
  background: #ffffff !important;
  color: var(--accent, #2563eb) !important;
  border: 1px solid var(--line) !important;
}
html[data-theme="dark"] .railbtn,
html[data-theme="dark"] .railtab {
  background: #2e333c !important;
  color: #93b4ff !important;
  border-color: rgba(255, 255, 255, 0.1) !important;
}
/* Collapse button: no shadow; hover matches the theme button */
html[data-theme] .railbtn,
html[data-theme] .railtab {
  box-shadow: none !important;
}
html[data-theme] .railbtn:hover,
html[data-theme] .railtab:hover {
  background: var(--gold-soft) !important;
  color: var(--gold-hi) !important;
  border-color: transparent !important;
}
/* Clock: tinted block filling the header's left corner (no pill) */
html[data-theme] .colhead .ch-clock {
  top: 0 !important;
  bottom: 0 !important;
  left: 0 !important;
  transform: none !important;
  height: auto !important;
  border: 0 !important;
  border-radius: var(--colhead-r, 14px) 0 0 0 !important;
}

/* Stats: top-aligned so numbers line up; equal-height dividers */
@media (min-width: 761px) {
  html[data-theme] .summary .stats {
    align-items: stretch !important;
  }
  html[data-theme] .summary .stat {
    display: flex !important;
    flex-direction: column !important;
    justify-content: flex-start !important;
    align-self: stretch !important;
  }
}
/* Light: timeline colors = pill fills */
html[data-theme="light"] .stp.sc-booked {
  --sc: #99d8fb;
}
html[data-theme="light"] .stp.sc-confirmed {
  --sc: #a6c4fa;
}
html[data-theme="light"] .stp.sc-seated {
  --sc: #a8dd9b;
}
html[data-theme="light"] .stp.sc-finished {
  --sc: #d7dadf;
}
html[data-theme="light"] .stp.sc-waiting {
  --sc: #d3c2f7;
}
html[data-theme="light"] .stp.sc-table {
  --sc: #ffc59e;
}
html[data-theme="light"] .stp.cur {
  color: #232429 !important;
}
html[data-theme="light"] .stp.cur i {
  box-shadow: 0 0 0 5px color-mix(in srgb, var(--sc) 45%, transparent) !important;
}
html[data-theme="light"] .stp:not(.done):not(.cur) i {
  background: #fff !important;
  border-color: var(--sc) !important;
  border-width: 2px;
}
html[data-theme="light"] .stp:not(.static):hover {
  color: #232429;
}
/* Clock block lines up with the group time labels below */
html[data-theme] .colhead .ch-clock {
  box-sizing: border-box !important;
  justify-content: flex-start !important;
}
/* Stats: vertically centered between day buttons and filter row */
@media (min-width: 761px) {
  html[data-theme] .summary .stats {
    align-self: center !important;
    margin: 0 !important;
  }
  html[data-theme] .summary {
    padding-top: 14px !important;
    padding-bottom: 4px !important;
  }
}
@media (min-width: 1377px) {
  html[data-theme] .summary {
    padding-top: 18px !important;
  }
}
/* Login: black backdrop to match the logo; location at card bottom */
html[data-theme="dark"] #login {
  background: #000 !important;
}
html[data-theme="dark"] .lg-card {
  background: #0e0e0f !important;
  border-color: rgba(255, 255, 255, 0.1) !important;
}
html[data-theme="dark"] .lg-card .input {
  background: #17181a !important;
  border-color: rgba(255, 255, 255, 0.12) !important;
}
html[data-theme="dark"] .lg-demo {
  border-color: rgba(255, 255, 255, 0.14) !important;
}
.lg-loc {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-top: 2px;
  font-size: 11px;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: var(--mute);
  justify-content: center;
}
.lg-loc:before,
.lg-loc:after {
  content: "";
  flex: 1;
  max-width: 84px;
  height: 1px;
  background: var(--line2, var(--line));
}
/* Walk-in window: tidy grid on tablet/desktop */
@media (min-width: 761px) {
  .layer.full .sh-body.ed.wk {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    grid-template-areas: "mode mode" "party seat" "req req" "warn warn";
    grid-template-rows: auto auto auto auto;
    align-content: start;
    align-items: stretch;
  }
  .layer.full .sh-body.ed.wk:has(#wkTableF[style*="none"]) {
    grid-template-areas: "mode mode" "party req" "warn warn";
  }
  .ed.wk .mode-switch {
    grid-area: mode;
  }
  .ed.wk .ec-wparty {
    grid-area: party;
  }
  .ed.wk .ec-wseat {
    grid-area: seat;
  }
  .ed.wk .ec-wreq {
    grid-area: req;
    align-self: start;
  }
  .ed.wk #wkWarn {
    grid-area: warn;
  }
  .ed.wk #wkWarn:empty {
    display: none;
  }
  .ed.wk .mode-switch .btn {
    height: 64px;
  }
  .ed.wk #wkParty {
    flex-wrap: nowrap;
  }
  .ed.wk #wkParty .chip {
    min-width: 36px !important;
    padding: 0 6px !important;
  }
  .ed.wk .ec-wseat .chips {
    margin-top: 8px;
  }
  .ed.wk .ec-wseat .input {
    max-width: none !important;
  }
}
html[data-theme] .crest svg ellipse:first-of-type {
  fill: #070708;
}
@media (min-width: 761px) and (max-width: 1100px) {
  .ed.wk #wkParty {
    flex-wrap: wrap !important;
  }
}
/* Above 1366: stats evenly spaced in a slightly narrower left column */
@media (min-width: 1600px) {
  html[data-theme] .summary {
    grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr) !important;
    gap: 32px !important;
  }
  html[data-theme] .summary .stats {
    grid-template-columns: repeat(5, minmax(0, 1fr)) !important;
    gap: 14px !important;
  }
  html[data-theme] .summary .stat {
    padding-left: 12px !important;
  }
  html[data-theme] .summary .stat .v {
    font-size: 30px !important;
  }
}
/* Above 1366: stats at natural width on one line, graph fills the rest */
@media (min-width: 1377px) {
  html[data-theme] .summary {
    gap: clamp(24px, 3vw, 56px) !important;
  }
  html[data-theme] .summary .stats {
    flex-wrap: nowrap !important;
    gap: clamp(18px, 2.2vw, 40px) !important;
  }
  html[data-theme] .summary .stat {
    flex: none !important;
    overflow: visible !important;
    padding-left: 14px !important;
  }

}
@media (min-width: 1377px) and (max-width: 1599px) {
  html[data-theme] .summary .stats {
    gap: 14px !important;
  }
  html[data-theme] .summary .stat {
    padding-left: 10px !important;
  }
  html[data-theme] .summary .stat .k {
    letter-spacing: 0.06em !important;
    font-size: 10.5px !important;
  }
  html[data-theme] .summary .stat .v {
    font-size: 26px !important;
  }
  html[data-theme] .summary {
    gap: 20px !important;
  }
}
/* Graph: show only the current service on smaller screens */
.pace .lbl-svc {
  display: none;
}
@media (max-width: 1100px) {
  .pace[data-cur="0"] .b.sv1,
  .pace[data-cur="1"] .b.sv0,
  .pace .gap {
    display: none !important;
  }
  .pace .lbl-svc {
    display: inline;
  }
}
/* 600–760px: five stats and the graph on one row */
@media (min-width: 600px) and (max-width: 760px) {
  html[data-theme] .summary {
    display: grid !important;
    grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr) !important;
    gap: 16px !important;
    align-items: center !important;
    padding-top: 14px !important;
    padding-bottom: 4px !important;
  }
  html[data-theme] .summary .stats {
    grid-template-columns: repeat(5, auto) !important;
    gap: 8px !important;
    margin: 0 !important;
    align-items: stretch !important;
  }
  html[data-theme] .summary .stat {
    padding-left: 8px !important;
    min-width: 0;
    display: flex !important;
    flex-direction: column !important;
    justify-content: flex-start !important;
  }
  html[data-theme] .summary .stat .v {
    font-size: 22px !important;
  }
  html[data-theme] .summary .stat .k {
    white-space: normal !important;
    font-size: 9.5px !important;
    letter-spacing: 0.05em !important;
    line-height: 1.25;
  }
  html[data-theme] .summary .pace {
    display: flex !important;
    height: 64px !important;
    width: 100% !important;
    margin: 0 !important;
  }
}
/* Filters: service seg drops to its own line when space runs out */
@media (max-width: 1100px) {
  html[data-theme] .bar {
    flex-wrap: wrap !important;
    overflow: visible !important;
    row-gap: 8px !important;
  }
}
@media (min-width: 761px) and (max-width: 1100px) {
  html[data-theme] .summary {
    grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr) !important;
    gap: 16px !important;
  }
  html[data-theme] .summary .stats {
    gap: 6px !important;
  }
  html[data-theme] .summary .stat {
    padding-left: 8px !important;
  }
  html[data-theme] .summary .stat .v {
    font-size: 22px !important;
  }
  html[data-theme] .summary .stat .k {
    font-size: 9.5px !important;
    letter-spacing: 0.03em !important;
  }
}
@media (min-width: 761px) and (max-width: 960px) {
  html[data-theme] .striprow {
    gap: 8px;
  }
  html[data-theme] .striprow .dn-strip {
    gap: 3px;
  }
  html[data-theme] .striprow .dn-strip .btn.icon {
    width: 32px;
  }
  html[data-theme] .striprow .dn-strip .btn:not(.icon) {
    padding: 0 9px;
  }
  html[data-theme] .striprow .strip {
    gap: 4px;
  }
  html[data-theme] .striprow .day .dw,
  html[data-theme] .striprow .day .dc {
    font-size: 10px;
  }
}
/* Light mode stat line: the same colours as dark mode (teal, orange, blue, green, purple), in deeper shades
   so they read on a light background */
html[data-theme="light"] .stat.g {
  border-left-color: #0d9488 !important;
}
html[data-theme="light"] .stat.g .v {
  color: #0d9488 !important;
}
html[data-theme="light"] .stat.t-party {
  border-left-color: #ea580c !important;
}
html[data-theme="light"] .stat.t-party .v {
  color: #ea580c !important;
}
html[data-theme="light"] .stat.t-booked {
  border-left-color: #2563eb !important;
}
html[data-theme="light"] .stat.t-booked .v {
  color: #2563eb !important;
}
html[data-theme="light"] .stat.t-seated {
  border-left-color: #16a34a !important;
}
html[data-theme="light"] .stat.t-seated .v {
  color: #16a34a !important;
}
html[data-theme="light"] .stat.t-waiting {
  border-left-color: #9333ea !important;
}
html[data-theme="light"] .stat.t-waiting .v {
  color: #9333ea !important;
}
/* Seating card: table + server side by side, quick-pick chips span the full card */
@media (min-width: 761px) {
  .ed .ec-seat {
    grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr) !important;
    grid-template-areas: "hd hd" "l1 l2" "in sel" "ch ch";
    row-gap: 8px !important;
  }
  .ed .ec-seat > header {
    grid-area: hd;
  }
  .ed .ec-seat .erow,
  .ed .ec-seat .ev {
    display: contents !important;
  }
  .ed .ec-seat .erow:first-of-type > .el {
    grid-area: l1;
  }
  .ed .ec-seat .erow + .erow > .el {
    grid-area: l2;
  }
  .ed .ec-seat #edTable {
    grid-area: in;
  }
  .ed .ec-seat #edServer {
    grid-area: sel;
  }
  .ed .ec-seat #edTableS {
    grid-area: ch;
    margin-top: 2px !important;
  }
}
@media (min-width: 761px) and (max-height: 940px) {
  .layer.full:has(.ed) .sh-head .eyebrow {
    display: none;
  }
  .layer.full:has(.ed) .sh-head {
    padding-top: 14px !important;
    padding-bottom: 10px !important;
  }
  .layer.full:has(.ed) .sh-foot {
    padding-top: 12px !important;
    padding-bottom: 12px !important;
  }
  .ed .ec-req .erow + .erow {
    padding-top: 8px !important;
  }
  .ed .input,
  .ed select.input {
    height: 38px !important;
  }
  .ed .chip {
    height: 34px !important;
  }
  .ed .quick button {
    padding-top: 3px !important;
    padding-bottom: 3px !important;
  }
  .layer.full .sh-body.ed {
    gap: 10px !important;
  }
}
@media (min-width: 761px) and (max-height: 860px) {
  .ed .input,
  .ed select.input {
    height: 36px !important;
  }
  .ed .chip {
    height: 32px !important;
  }
  .layer.full .sh-body.ed {
    gap: 8px !important;
  }
  .ed .ecard {
    padding: 10px 14px !important;
  }
  .ed .ec-seat {
    row-gap: 6px !important;
  }
}
/* Recently seated (last 10 min): green-tinted row, green table chip, brief pulse */
@keyframes jsPulse {
  0% {
    box-shadow: 0 0 0 0 color-mix(in srgb, #22c55e 55%, transparent);
  }
  70% {
    box-shadow: 0 0 0 10px transparent;
  }
  100% {
    box-shadow: 0 0 0 0 transparent;
  }
}
@keyframes jsFlash {
  0% {
    background-color: color-mix(in srgb, #22c55e 30%, transparent);
  }
  100% {
    background-color: var(--js-bg);
  }
}
html[data-theme] .row.just-seated {
  --js-bg: color-mix(in srgb, #22c55e 10%, transparent);
  background: var(--js-bg) !important;
  animation: jsFlash 1.6s ease-out 1;
}
html[data-theme="dark"] .row.just-seated {
  --js-bg: color-mix(in srgb, #4ade80 9%, transparent);
}
html[data-theme] .row.just-seated .meta .tb {
  background: #22c55e !important;
  color: #052e16 !important;
  border-color: transparent !important;
  animation: jsPulse 1.4s ease-out 3;
}
html[data-theme] .badge.justseat {
  display: inline-flex;
  align-items: center;
  height: 20px;
  padding: 0 8px;
  border-radius: 999px;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  background: #22c55e;
  color: #052e16;
  border: 0;
  margin-right: 6px;
}
@media (min-width: 761px) and (max-width: 1376px) {
  html[data-theme] .bar {
    flex-wrap: wrap !important;
    overflow: visible !important;
    row-gap: 8px !important;
  }
}
/* 480–760px: search sits beside the date controls */
@media (min-width: 480px) and (max-width: 760px) {
  .top .tools {
    display: flex !important;
    flex-wrap: nowrap !important;
    align-items: center;
    gap: 8px !important;
    width: 100%;
  }
  .top .tools .search {
    display: flex !important;
    flex: 1 1 auto;
    min-width: 0;
    width: auto !important;
  }
  .top .tools .search kbd {
    display: none;
  }
  .bar .msearch {
    display: none !important;
  }
}
/* 480–599px: five stats + graph on one row (same as 600–760) */
@media (min-width: 480px) and (max-width: 599px) {
  html[data-theme] .summary {
    display: grid !important;
    grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr) !important;
    gap: 12px !important;
    align-items: center !important;
    padding-top: 12px !important;
    padding-bottom: 4px !important;
  }
  html[data-theme] .summary .stats {
    grid-template-columns: repeat(5, auto) !important;
    gap: 6px !important;
    margin: 0 !important;
    align-items: stretch !important;
  }
  html[data-theme] .summary .stat {
    padding-left: 7px !important;
    min-width: 0;
    display: flex !important;
    flex-direction: column !important;
    justify-content: flex-start !important;
  }
  html[data-theme] .summary .stat .v {
    font-size: 20px !important;
  }
  html[data-theme] .summary .stat .k {
    white-space: normal !important;
    font-size: 9px !important;
    letter-spacing: 0.03em !important;
    line-height: 1.25;
  }
  html[data-theme] .summary .pace {
    display: flex !important;
    height: 60px !important;
    width: 100% !important;
    margin: 0 !important;
  }
  html[data-theme] .summary .pace .lbl {
    font-size: 8.5px !important;
    letter-spacing: 0.08em !important;
    white-space: nowrap;
  }
  html[data-theme] .summary .pace .lbl .lbl-svc {
    display: none;
  }
}
/* Under 480px: five stats on one row, graph hidden */
@media (max-width: 479px) {
  html[data-theme] .summary {
    display: block !important;
    padding-top: 12px !important;
    padding-bottom: 4px !important;
  }
  html[data-theme] .summary .pace {
    display: none !important;
  }
  html[data-theme] .summary .stats {
    grid-template-columns: repeat(5, minmax(0, 1fr)) !important;
    gap: 6px !important;
    margin: 0 !important;
    align-items: stretch !important;
  }
  html[data-theme] .summary .stat {
    padding-left: 7px !important;
    min-width: 0;
    display: flex !important;
    flex-direction: column !important;
    justify-content: flex-start !important;
  }
  html[data-theme] .summary .stat .v {
    font-size: 20px !important;
  }
  html[data-theme] .summary .stat .k {
    white-space: normal !important;
    font-size: 8.5px !important;
    letter-spacing: 0.02em !important;
    line-height: 1.25;
    overflow-wrap: anywhere;
  }
}
/* Clear "x" in seating & request fields */
.xfield {
  position: relative;
  display: block;
  width: 100%;
  min-width: 0;
}
.xfield > .input {
  width: 100%;
  padding-right: 40px !important;
}
.xfield .sclear {
  position: absolute;
  right: 10px;
  top: 50%;
  transform: translateY(-50%);
  width: 20px;
  height: 20px;
  border-radius: 50%;
  display: none;
  place-items: center;
  color: var(--mute);
  background: color-mix(in srgb, var(--text) 8%, transparent);
  border: 0;
  cursor: pointer;
  padding: 0;
}
.xfield .sclear svg {
  width: 12px;
  height: 12px;
  color: inherit;
}
.xfield .sclear:hover {
  color: var(--text);
  background: color-mix(in srgb, var(--text) 14%, transparent);
}
.xfield.has-v .sclear {
  display: grid;
}
@media (min-width: 761px) {
  .ed .ec-seat .xfield[data-for="edTable"] {
    grid-area: in;
  }
}
/* Walk-in requests: field takes one column, quick pills to its right */
.ed.wk .wkreq {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.ed.wk .wkreq .quick {
  margin: 0 !important;
}
@media (min-width: 761px) {
  .ed.wk .wkreq {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: 16px;
    align-items: start;
  }
  .layer.full .sh-body.ed.wk:has(#wkTableF[style*="none"]) .wkreq {
    display: flex;
  }
}
/* Party size in list rows: tap to change */
.row .meta .pedit {
  background: none;
  border: 1px solid transparent;
  border-radius: 10px;
  /* the person icon has a little blank room built in on its left: less padding there so the space
     looks the same on both sides */
  padding: 4px 8px 4px 6px;
  margin: -5px -9px -5px -7px;
  font: inherit;
  color: inherit;
  display: inline-flex;
  align-items: center;
  gap: inherit;
  cursor: pointer;
  /* the number's own width (not the wide table-figure box), so the hover box sits evenly around the icon and number */
  font-variant-numeric: lining-nums proportional-nums;
}
/* iPad and up: the whole Party column — heading, icon and number — sits right of centre:
   16px up to 1367px, 23px from 1368px */
@media (min-width: 761px) {
  .row .meta .pedit,
  .colhead .ch-meta > :first-child {
    position: relative;
    left: 16px;
  }
}
@media (min-width: 1368px) {
  .row .meta .pedit,
  .colhead .ch-meta > :first-child {
    left: 23px;
  }
}
.row .meta .pedit:hover {
  border-color: var(--line2, var(--line));
  background: color-mix(in srgb, var(--text) 5%, transparent);
}
.row .meta .pedit:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 1px;
}
/* Party size steppers: type a number */
.stepnum .pnum {
  width: 44px;
  height: 100%;
  min-height: 28px;
  border: 0;
  background: transparent;
  text-align: center;
  font: inherit;
  font-family: var(--num, inherit);
  font-size: 16px;
  font-weight: 600;
  color: var(--f-party);
  padding: 0;
  border-radius: 6px;
  -moz-appearance: textfield;
}
.stepnum .pnum:focus {
  outline: 2px solid var(--accent);
  outline-offset: -2px;
  background: var(--panel-solid, #fff);
}
/* Dropdown chevrons on all select fields */
html[data-theme][data-theme] body select:not(#_z1):not(#_z2) {
  -webkit-appearance: none !important;
  appearance: none !important;
}

/* Arrow sits on its own full-height panel, styled like the party − / + buttons:
   soft fill at rest, accent highlight on hover. (Panel = second background layer.) */
html[data-theme][data-theme] body select:not(#_z1):not(#_z2) {
  --sel-panel: color-mix(in srgb, var(--text) 7%, transparent);
  padding-right: 52px !important;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%235C5F66' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6.5 9.5l5.5 5.5 5.5-5.5'/%3E%3C/svg%3E"),
    linear-gradient(var(--sel-panel), var(--sel-panel)) !important;
  background-position: right 12px center, right top !important;
  background-size: 16px 16px, 40px 100% !important;
  background-repeat: no-repeat, no-repeat !important;
}
html[data-theme="dark"][data-theme] body select:not(#_z1):not(#_z2) {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23AEB4BF' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6.5 9.5l5.5 5.5 5.5-5.5'/%3E%3C/svg%3E"),
    linear-gradient(var(--sel-panel), var(--sel-panel)) !important;
}
html[data-theme][data-theme] body select:not(#_z1):not(#_z2):hover {
  --sel-panel: color-mix(in srgb, var(--blk) 22%, transparent);
}
html[data-theme="dark"][data-theme] body select:not(#_z1):not(#_z2):hover {
  --sel-panel: color-mix(in srgb, #3b82f6 35%, transparent);
}
.wlhead {
  margin: 14px 16px 14px !important;
}
@media (max-width: 760px) {
  .wlhead {
    margin: 12px 8px 12px !important;
  }
}
/* Detail facts: keep the time on one line */
html[data-theme] .facts .fact.fx-time .v {
  white-space: nowrap !important;
  overflow-wrap: normal !important;
  word-break: keep-all !important;
  letter-spacing: -0.01em;
}
html[data-theme] .facts .fact.fx-time .v small {
  font-size: 0.5em !important;
  margin-left: 2px;
  white-space: nowrap;
}
.nthead {
  margin: 14px 16px 6px !important;
}
/* Guest profile KPIs: six distinct colors (matches the Book stats palette) */
html[data-theme="light"] .kpis > div:nth-child(1) .v {
  color: #be185d !important;
}
html[data-theme="light"] .kpis > div:nth-child(2) .v {
  color: #15803d !important;
}
html[data-theme="light"] .kpis > div:nth-child(3) .v {
  color: #c2410c !important;
}
html[data-theme="light"] .kpis > div:nth-child(4) .v {
  color: #1d4ed8 !important;
}
html[data-theme="light"] .kpis > div:nth-child(5) .v {
  color: #7e22ce !important;
}
html[data-theme="light"] .kpis > div:nth-child(6) .v {
  color: #0e7490 !important;
}
html[data-theme="dark"] .kpis > div:nth-child(1) .v {
  color: #f472b6 !important;
}
html[data-theme="dark"] .kpis > div:nth-child(2) .v {
  color: #4ade80 !important;
}
html[data-theme="dark"] .kpis > div:nth-child(3) .v {
  color: #fb923c !important;
}
html[data-theme="dark"] .kpis > div:nth-child(4) .v {
  color: #60a5fa !important;
}
html[data-theme="dark"] .kpis > div:nth-child(5) .v {
  color: #c084fc !important;
}
html[data-theme="dark"] .kpis > div:nth-child(6) .v {
  color: #22d3ee !important;
}
/* Seated-now cards: table label wraps (Chefs / Room); name never breaks mid-word */
html[data-theme] .tcard .tno {
  white-space: normal !important;
  padding: 8px 6px !important;
  text-align: center;
  line-height: 1.15;
  display: grid;
  place-items: center;
  overflow-wrap: normal;
  word-break: normal;
  hyphens: none;
}
html[data-theme] .tcard b,
html[data-theme] .tcard .tinfo b {
  overflow-wrap: normal !important;
  word-break: normal !important;
}
html[data-theme] .tcard .tinfo > span {
  display: flex;
  flex-wrap: wrap;
  gap: 2px 10px;
  align-items: center;
}
html[data-theme] .tcard .tinfo > span .faint {
  white-space: nowrap;
}
/* Lunch = dark cyan; lunch/dinner selected = outlined tint */
html[data-theme="light"] {
  --c-lunch: #0e7490;
}
html[data-theme="dark"] {
  --c-lunch: #22d3ee;
}
html[data-theme][data-theme] body .seg button.tone.svc-1.on,
html[data-theme][data-theme] body .seg button.tone.svc-2.on {
  background: color-mix(in srgb, var(--c) 10%, transparent) !important;
  box-shadow: inset 0 0 0 1.5px var(--c) !important;
  color: var(--c) !important;
  border-color: transparent !important;
}
html[data-theme][data-theme] body .seg button.tone.svc-1.on .n,
html[data-theme][data-theme] body .seg button.tone.svc-2.on .n {
  color: var(--c) !important;
  opacity: 0.85;
}
/* Active-filter chip in the second filter row ("No Table" / "Tables to Confirm") */
html[data-theme][data-theme] body .seg button.tone.f-notable.on,
html[data-theme][data-theme] body .seg button.tone.f-toconfirm.on {
  --c: #c2410c;
  background: color-mix(in srgb, var(--c) 12%, transparent) !important;
  box-shadow: inset 0 0 0 1.5px var(--c) !important;
  color: var(--c) !important;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-weight: 600;
}
html[data-theme="dark"][data-theme] body .seg button.tone.f-notable.on,
html[data-theme="dark"][data-theme] body .seg button.tone.f-toconfirm.on {
  --c: #fb923c;
}
.seg button.f-notable .i,
.seg button.f-toconfirm .i {
  width: 15px;
  height: 15px;
}
.seg button.f-notable .n,
.seg button.f-toconfirm .n {
  color: inherit !important;
  opacity: 0.85;
}
.seg button.f-notable .fx,
.seg button.f-toconfirm .fx {
  display: inline-grid;
  place-items: center;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: color-mix(in srgb, var(--c) 18%, transparent);
  margin-left: 2px;
}
.seg button.f-notable .fx .i,
.seg button.f-toconfirm .fx .i {
  width: 10px;
  height: 10px;
}
/* Party size dialog: "Larger party" row matches the other fields */
html[data-theme="light"][data-theme] body .pp-step {
  background: #ffffff !important;
  border: 1px solid rgba(20, 20, 20, 0.13) !important;
}
html[data-theme="light"][data-theme] body .pp-step .stepnum {
  background: #f4f6f9 !important;
  border-color: rgba(20, 20, 20, 0.13) !important;
}
html[data-theme="dark"][data-theme] body .pp-step {
  background: #23272e !important;
  border: 1px solid rgba(255, 255, 255, 0.1) !important;
}
html[data-theme="dark"][data-theme] body .pp-step .stepnum {
  background: #2a2e35 !important;
  border-color: rgba(255, 255, 255, 0.12) !important;
}
/* Toast: dismiss button, swipe, no text selection */
.toast {
  touch-action: none;
  user-select: none;
  -webkit-user-select: none;
  cursor: grab;
}
.toast .tclose {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: none;
  border: 0;
  color: var(--mute);
  cursor: pointer;
  padding: 0;
  margin-left: -4px;
  flex: none;
}
.toast .tclose:hover {
  background: color-mix(in srgb, var(--text) 8%, transparent);
  color: var(--text);
}
.toast .tclose .i {
  width: 14px;
  height: 14px;
}
.search kbd {
  display: none !important;
}
/* Option buttons stretch so each row spans the full field width (recurring dates use an even grid instead) */
.ed .chips:not(.times):not(.rp-dates) {
  display: flex !important;
  flex-wrap: wrap;
}
.ed .chips:not(.times):not(.rp-dates) > .chip {
  flex: 1 1 auto;
  justify-content: center;
  text-align: center;
}
/* Party Size window: every number button the same width, rows start on the left
   (a short last row doesn't stretch) — 7 across, 5 on phones */
#ppChips {
  display: grid !important;
  grid-template-columns: repeat(7, minmax(0, 1fr));
}
#ppChips > .chip {
  justify-content: center;
  text-align: center;
  min-width: 0;
}
@media (max-width: 760px) {
  #ppChips {
    grid-template-columns: repeat(5, minmax(0, 1fr));
  }
}
.ed .chips .bigparty {
  flex: 0 0 auto;
}
/* Table / room options: natural width, left-aligned, with room below the row */
.ed #edTableS > .chip {
  flex: 0 0 auto;
}
.ed #edTableS {
  margin-bottom: 10px;
}

/* Seated-now cards: name on its own full-width line; details + Finish on the line below */
html[data-theme][data-theme] .tcard {
  grid-template-columns: 76px minmax(0, 1fr) auto !important;
  column-gap: 14px !important;
  row-gap: 6px !important;
  align-items: center;
  padding: 12px 14px 12px 12px !important;
}
html[data-theme] .tcard .tno {
  grid-area: tbl;
  width: 62px !important;
  min-width: 62px !important;
  max-width: 62px !important;
  align-self: stretch;
  height: auto !important;
  min-height: 52px;
}
html[data-theme] .tcard .tinfo {
  display: contents !important;
}
html[data-theme][data-theme] .tcard .tinfo b {
  grid-area: name;
  white-space: nowrap !important;
  overflow: hidden !important;
  text-overflow: ellipsis !important;
  font-size: 16px;
  line-height: 1.25;
  align-self: end;
}
html[data-theme] .tcard .tinfo > span {
  grid-area: meta;
  align-self: center;
  font-size: 13px;
}
html[data-theme] .tcard .finbtn {
  grid-area: btn;
  height: 34px !important;
  font-size: 13.5px !important;
  align-self: center;
}

html[data-theme] .tcard .tmeta {
  grid-area: meta;
  display: flex !important;
  flex-wrap: nowrap !important;
  align-items: center;
  gap: 10px;
  min-width: 0;
  font-size: 13px;
  white-space: nowrap;
  overflow: hidden;
}
html[data-theme] .tcard .tmeta .srv,
html[data-theme] .tcard .tmeta .faint {
  overflow: hidden;
  text-overflow: ellipsis;
  min-width: 0;
}
html[data-theme] .tcard .finbtn {
  justify-self: end;
}

html[data-theme][data-theme] .tcard .tinfo > span.tmeta {
  grid-area: meta !important;
}
html[data-theme][data-theme] .tcard {
  grid-template-areas: "tbl name name" "tbl meta btn" !important;
}
html[data-theme] .tcard .tmeta .ttm {
  color: var(--sub);
  font-weight: 500;
  white-space: nowrap;
}
html[data-theme] .tcard .finbtn {
  padding: 0 12px !important;
}
#bkList .wlhead {
  margin-right: calc(16px - var(--sbw, 0px)) !important;
}
@media (max-width: 760px) {
  #bkList .wlhead {
    margin-right: calc(8px - var(--sbw, 0px)) !important;
  }
}
.ed .chips > .chip.nogrow {
  flex: 0 0 auto !important;
}
/* Header clock: larger, room for 12:00 AM */
html[data-theme][data-theme] .colhead .ch-clock {
  width: auto !important;
  min-width: var(--clk-w, 106px) !important;
  padding: 0 14px 0 var(--clk-pl, 20px) !important;
  font-weight: 700 !important;
  letter-spacing: -0.01em !important;
  gap: 4px !important;
  font-variant-numeric: tabular-nums;
}
html[data-theme][data-theme] .colhead .ch-clock small {
  font-weight: 700 !important;
  letter-spacing: 0.04em;
}
html[data-theme][data-theme] .colhead .ch-clock {
  font-size: 18px !important;
  padding-right: 12px !important;
}
html[data-theme][data-theme] .colhead .ch-clock small {
  font-size: 11px !important;
}
/* Closed dates */
.day.closed .dc {
  color: var(--c-noshow) !important;
  font-weight: 600;
}
.day.closed:not(.on) {
  background: repeating-linear-gradient(
    135deg,
    transparent 0 6px,
    color-mix(in srgb, var(--c-noshow) 7%, transparent) 6px 12px
  ) !important;
}
.closedhead {
  border-color: color-mix(in srgb, var(--c-noshow) 45%, transparent) !important;
  background: color-mix(in srgb, var(--c-noshow) 7%, transparent);
  color: var(--text) !important;
}
.closedhead .i {
  color: var(--c-noshow);
}
/* Closed day on the board: "Closed" in the same red striped pill as the day strip.
   An open day with no bookings: "No reservations yet" in the same size pill, dark gray. */
html[data-theme] .empty h3.closedpill,
html[data-theme] .empty h3.nonepill,
html[data-theme] .dp-empty h3.nonepill {
  margin: 4px 0 10px;
  padding: 8px 20px 6px; /* even space above the capitals and below the baseline */
  line-height: 1.2;
  border-radius: 999px;
}
html[data-theme] .empty h3.nonepill,
html[data-theme] .dp-empty h3.nonepill {
  color: var(--sub);
  border: 1px solid #555a63;
  background: #23272e;
}
html[data-theme="light"] .empty h3.nonepill,
html[data-theme="light"] .dp-empty h3.nonepill {
  border-color: #d5d8dd;
  background: #eceef0;
}
html[data-theme] .empty h3.closedpill {
  border: 1px solid color-mix(in srgb, var(--c-noshow) 45%, transparent);
  color: var(--c-noshow);
  background: repeating-linear-gradient(135deg, transparent 0 6px, color-mix(in srgb, var(--c-noshow) 9%, transparent) 6px 12px);
}
.ed .chip.dchip.closed {
  text-decoration: line-through;
  opacity: 0.5;
}

/* From | To, Reason, Hours, then Add (three quarters) with Yearly beside it (a quarter) */
.bo-form {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px 12px;
  align-items: end;
}
.bo-form > .field {
  grid-column: span 2;
}
.bo-form .bo-reason {
  grid-column: 1/-1;
}
.bo-form .btn {
  grid-column: 1 / 4;
  grid-row: 4;
  justify-content: center;
  margin-top: 18px; /* 10px row gap + 18 = the 28px below it */
}
.bo-form .bo-yearly {
  grid-column: 4;
  grid-row: 4;
  height: 44px;
  align-self: end;
  justify-content: center;
  white-space: nowrap;
}
.bo-list {
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
.bo-row {
  display: grid;
  grid-template-columns: 130px minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
  padding: 10px 12px 10px 14px;
  border-bottom: 1px solid var(--line);
}
.bo-row:last-child {
  border-bottom: 0;
}
.bo-d {
  font-weight: 600;
  font-variant-numeric: tabular-nums;
}
.bo-r {
  color: var(--sub);
  font-size: 13.5px;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.bo-list .tb-empty {
  padding: 14px;
}
/* Audit entries: comfortable bottom padding */
.asec .ae {
  padding: 16px 20px 18px !important;
  min-height: 0;
}
.asec .ae .ch {
  margin-top: 8px;
}
/* Table picker: show tables already in use */
.tpick .chip {
  position: relative;
}
.tp-legend {
  display: flex;
  gap: 16px;
  font-size: 12px;
  color: var(--mute);
}
.tp-legend span {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.tp-legend i {
  width: 10px;
  height: 10px;
  border-radius: 3px;
  display: inline-block;
}
.tp-legend i.tk-seated {
  background: var(--c-seated);
}
.tp-legend i.tk-held {
  background: #f59e0b;
}
.tp-legend {
  border-top: 1px solid var(--line);
}
#bkList .wlhead.nthead,
#bkList .wlhead.closedhead {
  margin-top: 14px !important;
  margin-bottom: 14px !important;
}
#bkList .wlhead.closedhead + .wlhead.nthead {
  margin-top: 0 !important;
}
/* Graph hour labels: room for AM/PM, no clipping */
html[data-theme] .pace {
  overflow: visible !important;
  padding-bottom: 16px !important;
}
html[data-theme] .pace .b em {
  bottom: -15px !important;
  line-height: 1.2 !important;
  white-space: nowrap;
  font-style: normal;
  overflow: visible;
}
html[data-theme] .pace .b em small {
  font-size: 0.78em;
  margin-left: 1px;
  letter-spacing: 0.02em;
}
/* Service filter lives in the top-left of the covers graph */
.pacewrap {
  position: relative;
  min-width: 0;
  width: 100%;
}
.pacewrap .pace-svc {
  position: absolute;
  top: -6px;
  left: 0;
  z-index: 2;
  padding: 2px !important;
  gap: 2px;
}
html[data-theme] .pacewrap .pace-svc button {
  height: 26px !important;
  padding: 0 9px !important;
  font-size: 12px !important;
}
html[data-theme] .pacewrap .pace {
  padding-top: 34px !important;
  height: 96px !important;
}
.bar .bar-svc {
  display: none !important;
}
@media (min-width: 761px) and (max-width: 1376px) {
  html[data-theme] .pacewrap .pace {
    height: 84px !important;
  }
}
@media (max-width: 1100px) {
  html[data-theme] .pacewrap .pace .lbl {
    display: none;
  }
}
@media (max-width: 479px) {
  .pacewrap .pace-svc {
    display: none !important;
  }
  .bar .bar-svc {
    display: flex !important;
  }
}
html[data-theme] .pacewrap .pace .lbl {
  top: 3px !important;
  line-height: 12px !important;
}
.f-booked {
  --c: var(--c-booked);
}
.f-confirmed {
  --c: var(--c-confirmed);
}
.f-hold {
  --c: var(--c-hold);
}
html[data-theme="light"] .seg .f-booked .sw {
  background: #2b8fd6 !important;
  border-color: #2b8fd6 !important;
}
html[data-theme="light"] .seg .f-confirmed .sw {
  background: #4f72dc !important;
  border-color: #4f72dc !important;
}
html[data-theme="light"] .seg .f-hold .sw {
  background: #e07b39 !important;
  border-color: #e07b39 !important;
}
.bo-form .datebtn,
#ngBday {
  display: flex !important;
  flex-direction: row !important;
  align-items: center !important;
  justify-content: flex-start !important;
  gap: 10px;
  height: 44px !important;
  min-height: 0 !important;
  text-align: left;
}
html body .bo-form #boFrom.datebtn,
html body .bo-form #boTo.datebtn {
  height: 44px !important;
  max-height: 44px !important;
  min-height: 0 !important;
  flex: none !important;
}
.input.datebtn.empty {
  padding: 0 14px !important;
  flex-direction: row !important;
  align-items: center !important;
  justify-content: flex-start !important;
  text-align: left !important;
  gap: 10px !important;
}
.tp-legend {
  padding-top: 14px !important;
}
.asec,
.stafflist .srow,
.gsec {
  flex-shrink: 0 !important;
}
.tp-legend {
  margin-top: -2px !important;
}
/* Calendar: closed days match the day strip */
html[data-theme] .cal-d.closed {
  opacity: 1 !important;
  text-decoration: none !important;
  background: repeating-linear-gradient(
    135deg,
    transparent 0 6px,
    color-mix(in srgb, var(--c-noshow) 9%, transparent) 6px 12px
  ) !important;
}
html[data-theme] .cal-d.closed small.closedlbl {
  color: var(--c-noshow) !important;
  font-weight: 600;
  font-size: 11px;
  letter-spacing: 0.02em;
}
html[data-theme] .cal-d.closed.sel small.closedlbl {
  color: #fff !important;
}
html[data-theme] .cal-d.closed.sel {
  background: var(--sel-bg) !important;
}
/* closed days: the standard border; red on hover */
html[data-theme] .cal-d.closed:not(.sel) {
  border-color: var(--line2) !important;
}
html[data-theme] .cal-d.closed:not(.sel):hover {
  border-color: color-mix(in srgb, var(--c-noshow) 70%, transparent) !important;
  background: color-mix(in srgb, var(--c-noshow) 14%, transparent) !important;
}
/* Stats: evenly spaced columns (equal widths) at every size */
html[data-theme][data-theme] .summary .stats {
  display: grid !important;
  justify-content: stretch !important;
}
@media (max-width: 1376px) {
  html[data-theme][data-theme] .summary .stats {
    grid-template-columns: repeat(5, minmax(0, 1fr)) !important;
  }
}
@media (min-width: 1377px) and (max-width: 1799px) {
  html[data-theme][data-theme] .summary {
    grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr) !important;
  }
  html[data-theme][data-theme] .summary .stats {
    grid-template-columns: repeat(5, minmax(0, 1fr)) !important;
    width: auto !important;
  }
  html[data-theme][data-theme] .summary .stat .k {
    white-space: normal !important;
    letter-spacing: 0.06em !important;
  }
}
@media (min-width: 1800px) {
  html[data-theme][data-theme] .summary .stat .k {
    letter-spacing: 0.1em !important;
  }
}
@media (min-width: 1377px) {
  html[data-theme][data-theme] .summary {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) !important;
  }
  html[data-theme][data-theme] .summary .stats {
    grid-template-columns: repeat(5, minmax(0, 1fr)) !important;
    width: auto !important;
  }
  html[data-theme][data-theme] .summary .stat {
    min-width: 0;
  }
  html[data-theme][data-theme] .summary .stat .v {
    font-size: clamp(24px, 1.7vw, 32px) !important;
  }
  html[data-theme][data-theme] .summary .stat .k {
    white-space: normal !important;
    letter-spacing: 0.08em !important;
    font-size: 10.5px !important;
    line-height: 1.3;
  }
}
.pacewrap {
  container-type: inline-size;
}
@container (max-width:470px) {
  .pacewrap .pace .lbl {
    display: none !important;
  }
}
html[data-theme] .tpick .chip {
  height: 50px !important;
  min-height: 50px !important;
  max-height: 50px !important;
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  padding-top: 0 !important;
  padding-bottom: 0 !important;
}
html[data-theme] .tpick .chip:not(#_z1) {
  height: 48px !important;
  min-height: 48px !important;
  max-height: 48px !important;
  padding-left: 12px !important;
  padding-right: 12px !important;
}
html[data-theme] .tpick .chip:not(#_z1):not(#_z2) {
  height: 46px !important;
  min-height: 46px !important;
  max-height: 46px !important;
  padding-left: 11px !important;
  padding-right: 11px !important;
}
html[data-theme] .tpick .chip:not(#_z1):not(#_z2):not(#_z3) {
  height: 44px !important;
  min-height: 44px !important;
  max-height: 44px !important;
  padding-left: 10px !important;
  padding-right: 10px !important;
}
@media (max-width: 760px) {
  html[data-theme] .tabbar {
    height: calc(80px + var(--sa-b)) !important;
    padding-top: 0 !important;
    align-items: center !important;
  }
  html[data-theme] main#main {
    padding-bottom: calc(80px + var(--sa-b)) !important;
  }
  html[data-theme] .tabbar .fab {
    transform: none !important;
    align-self: center !important;
    margin: 0 !important;
  }
  html[data-theme] .tabbar .nav {
    align-self: center !important;
  }
}
html[data-theme] #edTable:not(#_z1),
html[data-theme] #edServer:not(#_z1),
html[data-theme] #wkTable:not(#_z1) {
  max-width: none !important;
  width: 100% !important;
}
@media (max-width: 760px) {
  html[data-theme] .row .meta .pedit:not(#_z1) {
    margin-bottom: 4px !important;
    margin-right: 0 !important; /* box's right edge lines up with the table box below */
  }
  html[data-theme] header.top.audtop:not(#_z1) {
    display: flex !important;
    flex-direction: row !important;
    flex-wrap: wrap !important;
    align-items: flex-end !important;
    justify-content: space-between !important;
    gap: 10px !important;
  }
  html[data-theme] header.top.audtop .title {
    flex: 1 1 auto;
    min-width: 0;
  }
  html[data-theme] header.top.audtop .tools:not(#_z1) {
    width: auto !important;
    margin: 0 0 4px auto !important;
    flex: 0 0 auto !important;
    justify-content: flex-end !important;
  }
  html[data-theme] .audtop + .filters .search:not(#_z1) {
    width: 100% !important;
    flex: 1 1 100% !important;
    max-width: none !important;
  }
  html[data-theme] .search:has(#aQ):not(#_z1) {
    width: 100% !important;
    flex: 1 1 100% !important;
    max-width: none !important;
  }
  html[data-theme] header.audtop .tools:not(#_z1) {
    min-width: 0 !important;
    flex: 0 0 auto !important;
    display: flex !important;
  }
  html[data-theme] header.audtop .tools .newbtn[data-act="newguest"]:not(#_z1),
  html[data-theme] header.audtop .tools .newbtn[data-act="newserver"]:not(#_z1),
  html[data-theme] header.audtop .tools .newbtn[data-act="txAll"]:not(#_z1) {
    display: inline-flex !important;
    width: auto !important;
    padding: 0 14px !important;
    gap: 6px;
  }
  html[data-theme] header.audtop .tools .newbtn[data-act="newguest"] .lbl-long,
  html[data-theme] header.audtop .tools .newbtn[data-act="newserver"] .lbl-long {
    display: inline !important;
  }
  html[data-theme] .tools .newbtn.wkbtn:not(#_z1) {
    display: inline-flex !important;
    width: auto !important;
    padding: 0 14px !important;
    gap: 6px;
    flex: none;
  }
  html[data-theme] .tools .newbtn.wkbtn .lbl-long {
    display: inline !important;
  }
  html[data-theme] .tools:has(.wkbtn):not(#_z1) {
    gap: 8px !important;
    flex-wrap: nowrap !important;
  }
  html[data-theme] .tools .newbtn.wkbtn:not(#_z1):not(#_z2) {
    width: 44px !important;
    padding: 0 !important;
    justify-content: center !important;
    margin-left: auto !important;
  }
  html[data-theme] .tools .newbtn.wkbtn .lbl-long:not(#_z1) {
    display: none !important;
  }
  html[data-theme] .search:has(#aQ) #aQ {
    width: 100% !important;
  }
  html[data-theme] .tools .newbtn.wkbtn:not(#_z1):not(#_z2):not(#_z3) {
    margin-left: 0 !important;
  }
}
@keyframes rowflash {
  0%,
  100% {
    box-shadow: inset 0 0 0 0 transparent;
  }
  15%,
  70% {
    box-shadow: inset 0 0 0 2px var(--blk);
    background: color-mix(in srgb, var(--blk) 14%, transparent);
  }
}
html[data-theme] #bkList .row.flash {
  animation: rowflash 2s ease;
}
html[data-theme] .toast .tshow {
  color: var(--blk);
}
/* Just-seated rows: hover gets a deeper tint + green ring so the row under the mouse stands out */
html[data-theme] .row.just-seated {
  transition:
    background-color 0.16s ease,
    box-shadow 0.16s ease;
}
html[data-theme] .row.just-seated:hover {
  --js-bg: color-mix(in srgb, #22c55e 17%, transparent);
  box-shadow: inset 0 0 0 1.5px color-mix(in srgb, #22c55e 55%, transparent) !important;
}
html[data-theme="dark"] .row.just-seated:hover {
  --js-bg: color-mix(in srgb, #4ade80 15%, transparent);
  box-shadow: inset 0 0 0 1.5px color-mix(in srgb, #4ade80 50%, transparent) !important;
}
html[data-theme] .row.just-seated:hover .meta .tb {
  filter: brightness(1.08);
}
/* Re-renders (save confirm, 30s refresh) rebuild the row; a negative delay continues the
   seat animation where it left off instead of restarting it (which looked like a flicker) */
html[data-theme] .row.just-seated,
html[data-theme] .row.just-seated .meta .tb {
  animation-delay: var(--jsd, 0ms) !important;
}
/* Steady seat highlight: no row-level animation/transition (a rebuilt row re-ran them = flicker).
   The table badge pulse continues across redraws via --jsd. */
html[data-theme] .row.just-seated:not(#_z1) {
  animation: none !important;
  transition: none !important;
}
/* "Table Reserved" pill — bright red in both themes (kept red by choice; reserved tables themselves are blue) */
html[data-theme] .badge.dnm {
  background: #ef4444 !important;
  color: #fff !important;
  border: 0 !important;
  font-weight: 700;
  letter-spacing: 0.08em;
}
html[data-theme="dark"] .badge.dnm {
  background: #f04444 !important;
  color: #fff !important;
}
/* Validation: red outline on fields that need attention */
html[data-theme] .invalid:not(#_z1),
html[data-theme] .search.invalid:not(#_z1) .input,
html[data-theme] .input.invalid:not(#_z1) {
  border-color: #ef4444 !important;
  box-shadow: 0 0 0 3px color-mix(in srgb, #ef4444 22%, transparent) !important;
  border-radius: 12px;
}
html[data-theme] .search.invalid:not(#_z1) {
  border-color: transparent !important;
  box-shadow: none !important;
}
html[data-theme] #edTimes.invalid:not(#_z1) {
  outline: 1.5px solid #ef4444;
  outline-offset: 6px;
  border-color: transparent !important;
  box-shadow: none !important;
  border-radius: 12px;
}
html[data-theme] .invalid {
  animation: invShake 0.32s ease 1;
}
@keyframes invShake {
  0%,
  100% {
    transform: translateX(0);
  }
  25% {
    transform: translateX(-4px);
  }
  75% {
    transform: translateX(4px);
  }
}
html[data-theme] .ecard.invalid:not(#_z1) {
  border-color: #ef4444 !important;
  box-shadow: 0 0 0 3px color-mix(in srgb, #ef4444 20%, transparent) !important;
  border-radius: var(--ecard-r, 18px);
}
/* Today: time slots that have already passed are grayed out and can't be picked */
html[data-theme] #edTimes .chip.past:not(#_z1) {
  opacity: 0.32;
  cursor: not-allowed;
  pointer-events: none;
  background: transparent !important;
  border-style: dashed !important;
  filter: grayscale(1);
}
/* Past slots: visible dashed outline, dimmed text, no load bar */
html[data-theme] #edTimes .chip.past:not(#_z1):not(#_z2) {
  opacity: 1;
  filter: none;
  background: transparent !important;
  border: 1.5px dashed color-mix(in srgb, var(--text) 22%, transparent) !important;
  color: color-mix(in srgb, var(--text) 30%, transparent) !important;
  box-shadow: none !important;
}
html[data-theme] #edTimes .chip.past .load {
  display: none !important;
}

/* ===== Guest card (Book a Table / Party at the Door): Edit + Change ===== */
.custcard .cp-acts {
  display: flex;
  gap: 4px;
  flex: none;
  align-items: center;
}
@media (max-width: 480px) {
  .custcard .cp-acts {
    flex-direction: column;
    align-items: stretch;
    gap: 2px;
  }
}

/* ===== Assign table: tables in use =====
   Gray chip like every other table; a full-width divider and a tinted strip
   underneath say why (SEATED in green, assigned time in amber). */
html[data-theme] .tpick .chip.taken:not(#_z1):not(#_z2):not(#_z3) {
  padding: 0 !important;
  overflow: hidden;
  flex-direction: column;
  align-items: stretch;
  justify-content: stretch;
  gap: 0;
  line-height: 1;
}
.tpick .chip.taken .tnum {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 12px;
}
html[data-theme] .tpick .chip.taken small {
  flex: none;
  display: flex;
  align-items: center;
  justify-content: center;
  height: 17px;
  margin: 0 !important;
  padding: 0 8px !important;
  border-top: 1px solid var(--tk);
  background: color-mix(in srgb, var(--tk) 16%, transparent);
  color: var(--tk-text);
  font-size: 9.5px;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  white-space: nowrap;
}
html[data-theme] .tpick .chip.tk-seated {
  --tk: color-mix(in srgb, var(--c-seated) 75%, transparent);
  --tk-text: var(--c-seated);
}
html[data-theme] .tpick .chip.tk-held {
  --tk: color-mix(in srgb, #f59e0b 75%, transparent);
  --tk-text: #b45309;
}
html[data-theme="dark"] .tpick .chip.tk-held {
  --tk-text: #fbbf24;
}
html[data-theme] .tpick .chip.taken:not(.on) {
  border-color: var(--tk) !important;
}

/* ===== Party size stepper: − / + buttons =====
   Soft fill at rest, accent highlight on hover, deeper on press. */
html[data-theme] .stepnum button:not(#_z1) {
  background: color-mix(in srgb, var(--text) 7%, transparent);
  color: var(--text);
  font-size: 17px;
  font-weight: 600;
  transition: background-color 0.15s ease, color 0.15s ease;
}
html[data-theme] .stepnum button:not(#_z1):hover {
  background: color-mix(in srgb, var(--blk) 22%, transparent);
  color: var(--blk);
}
html[data-theme="dark"] .stepnum button:not(#_z1):hover {
  background: color-mix(in srgb, #3b82f6 35%, transparent);
  color: #dbeafe;
}
html[data-theme] .stepnum button:not(#_z1):active {
  background: color-mix(in srgb, var(--blk) 34%, transparent);
}

/* ===== Book a Table: "Other date" button in the Date & Party header =====
   Same chip styling as the date buttons; only its position is set here. */

/* Dropdowns: hand cursor over the whole field, arrow included */
select,
select.input {
  cursor: pointer;
}

/* ===== Customer information dialog: wide enough for a full birthday on one line ===== */
html[data-theme] .layer .panel.custsheet:not(#_z1) {
  width: min(560px, calc(100vw - 24px));
  max-width: none;
}
.custsheet #cuBday span {
  white-space: nowrap;
}

/* ===== Guest search results float over the form =====
   Results open as a dropdown under the search field instead of pushing the form down,
   so the window keeps its size while typing. */
.picker #cpRes {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  z-index: 40;
}
.picker #cpRes .results {
  max-height: min(360px, 52vh);
  overflow-y: auto;
  box-shadow: 0 18px 40px -12px rgba(0, 0, 0, 0.45);
}
.ecard:has(#cpRes .results) {
  position: relative;
  z-index: 30;
  overflow: visible;
}
/* Dim the rest of the window while the guest results are open */
.layer .panel:has(#cpRes .results)::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 20;
  border-radius: inherit;
  background: rgba(0, 0, 0, 0.42);
  pointer-events: none;
  animation: cpDim 0.15s ease;
}
html[data-theme="light"] .layer .panel:has(#cpRes .results)::after {
  background: rgba(20, 24, 33, 0.22);
}
@keyframes cpDim {
  from { opacity: 0; }
}

/* Empty "Different time" field: dim the browser's placeholder time */
input[type="time"].input.t-empty:not(:focus)::-webkit-datetime-edit {
  opacity: 0.4;
}

/* Guest results dropdown spans the full #1 Guest card, framed like the card itself */
.ecard .picker {
  position: static;
}
.ecard .picker #cpRes {
  top: auto;
  left: -1px;
  right: -1px;
  margin-top: 0;
}
.ecard .picker #cpRes:has(.results) {
  padding: 18px 18px 16px;
  border: 1px solid var(--line);
  border-top: 0;
  border-radius: 0 0 16px 16px;
  background: #171a1d; /* card color as seen over the dimmed window */
  box-shadow: 0 18px 40px -12px rgba(0, 0, 0, 0.45);
}
.ecard .picker #cpRes .results {
  margin-top: 0;
  background: #0e1013;
  box-shadow: none;
}
.ecard:has(#cpRes .results) {
  border-bottom-left-radius: 0 !important;
  border-bottom-right-radius: 0 !important;
}
html[data-theme="light"] .ecard .picker #cpRes:has(.results) {
  background: #f4f6f9;
  box-shadow: 0 18px 40px -12px rgba(20, 24, 33, 0.25);
}
html[data-theme="light"] .ecard .picker #cpRes .results {
  background: var(--ink);
}

/* ===== Guest confirmation text (phone number → Messages) ===== */
button.cline {
  background: none;
  border: 0;
  padding: 0;
  font: inherit;
  font-size: 14.5px;
  cursor: pointer;
  text-align: left;
}
.txstate {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 10px;
  font-size: 13px;
  color: var(--sub);
  line-height: 1.35;
}
.txstate svg {
  width: 15px;
  height: 15px;
  flex: none;
  color: var(--mute);
}
.txstate b {
  font-weight: 600;
}
.txstate.ok,
.txstate.ok svg {
  color: #6fcf97;
}
.txstate.off,
.txstate.off svg {
  color: #ef8a8a;
}
.txdlg .panel {
  width: min(520px, 100vw - 24px);
}
.txsheet {
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.txsheet .txstate {
  margin-top: 0;
}
.txlabel {
  font-size: 10.5px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--mute);
  margin-bottom: 8px;
}
.txbubble {
  background: #1f6feb;
  color: #fff;
  border-radius: 20px 20px 6px 20px;
  padding: 12px 16px;
  font-size: 15px;
  line-height: 1.4;
  margin-left: 32px;
  overflow-wrap: anywhere;
  min-height: 46px;
}
.txbubble .faint {
  color: rgba(255, 255, 255, 0.7);
}
.txlink {
  text-decoration: underline;
  text-underline-offset: 2px;
}
.txerr {
  color: #ffe0e0;
}
.txhint {
  margin-top: 10px;
  font-size: 13px;
  color: var(--mute);
  line-height: 1.45;
}
.txdemo {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  padding-top: 14px;
  border-top: 1px dashed var(--line2);
  font-size: 12.5px;
}
.txdemo span {
  flex-basis: 100%;
}
.txdlg .sh-foot .btn svg {
  width: 18px;
  height: 18px;
  margin-right: 6px;
}
.txgo.is-wait {
  opacity: 0.55;
  pointer-events: none;
}
.atype.text {
  color: #7fb2ff;
  border-color: rgba(127, 178, 255, 0.35);
}
html[data-theme="light"] .txstate.ok,
html[data-theme="light"] .txstate.ok svg {
  color: #1e8a4c;
}
html[data-theme="light"] .txstate.off,
html[data-theme="light"] .txstate.off svg {
  color: #c43c3c;
}
/* Confirm button → "Confirm manually" / "Text confirmation" side by side */
.sh-foot.txfoot {
  gap: 10px;
}
.sh-foot.txfoot .btn {
  flex: 1 1 0;
  min-width: 0;
  width: auto;
  white-space: nowrap;
  justify-content: center;
}
@media (max-width: 480px) {
  .sh-foot.txfoot {
    flex-direction: column;
    align-items: stretch;
  }
  .sh-foot.txfoot .btn {
    flex: none;
    width: 100%;
  }
}
.txphone {
  margin-top: 4px;
  font-size: 15px;
  color: var(--sub);
}
/* Board: guest answered the confirmation text (shown left of the status pill) */
.row .nm .gtx {
  flex: none;
  display: inline-flex;
  width: 20px;
  height: 20px;
  margin-right: -2px;
}
.row .nm .gtx svg {
  width: 20px;
  height: 20px;
  stroke-width: 1.9;
}
.row .nm .gtx.yes {
  color: var(--c);
}
.row .nm .gtx.no {
  color: #ef6b6b;
}
html[data-theme="light"] .row .nm .gtx.no {
  color: #c43c3c;
}
.sh-foot.txfoot .btn {
  padding-left: 14px;
  padding-right: 14px;
  gap: 8px;
}
.sh-foot.txfoot .btn svg {
  margin: 0 !important;
}

/* ===== Guest replies: badge, header button, list ===== */
.rbadge {
  position: absolute;
  top: 4px;
  right: 4px;
  background: #e5484d;
  color: #fff;
  font: 700 11px/18px var(--sans);
  font-style: normal;
  text-align: center;
  letter-spacing: 0;
  pointer-events: none;
}
.rbadge[hidden] {
  display: none;
}
.nav,
.rpbtn {
  position: relative;
}

.rpsound {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  white-space: nowrap;
}
.rpsound svg {
  width: 17px;
  height: 17px;
}
.rplist {
  display: flex;
  flex-direction: column;
  gap: 8px;
  max-height: min(70vh, 640px);
  overflow-y: auto;
}
.rprow {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  padding: 12px 14px;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: var(--coal);
  color: var(--text);
  font: inherit;
  text-align: left;
  cursor: pointer;
}
.rprow:hover {
  border-color: var(--line2);
  background: color-mix(in srgb, var(--text) 5%, var(--coal));
}
.rprow .gtx {
  flex: none;
  display: inline-flex;
}
.rprow .gtx svg {
  width: 22px;
  height: 22px;
  stroke-width: 1.9;
}
.rprow .gtx.yes {
  color: var(--c);
}
.rprow .gtx.no {
  color: #ef6b6b;
}
html[data-theme="light"] .rprow .gtx.no {
  color: #c43c3c;
}
.rprow .t {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.rprow .t b {
  font-weight: 600;
  font-size: 15px;
}
.rprow .t span {
  font-size: 13px;
  color: var(--mute);
  line-height: 1.35;
}
.rprow .when {
  flex: none;
  font-size: 12.5px;
  color: var(--mute);
}
@media (max-width: 480px) {
  .rpsound span {
    display: none;
  }
}
/* Verify Date (Airtable "Check Date") = lime in dark mode (pill, row bar, dot, filter) — its own family,
   apart from Checked In's teal */
html[data-theme="dark"] {
  --c-checkdate: #bef264;
}
/* Badge sits on the button's top-right corner, 5px outside, no ring */
.rbadge {
  box-shadow: none;
}
/* the side menu's and phone tab bar's icons: 25px */
.rail .nav svg.i,
.tabbar .nav svg.i {
  width: 25px;
  height: 25px;
}
/* on the tab buttons the badge sits up on the icon's top-right corner (the icon's centre is 9.4px above the middle) */
.rail .nav .rbadge,
.tabbar .nav .rbadge {
  top: calc(50% - 33px);
  left: calc(50% + 2px);
  right: auto;
}
/* on the active (blue) Texts button the badge slides over to its top-right corner, same height — phones' tab
   bar and the iPad / desktop side menu */
html[data-theme] .rail .nav .rbadge,
html[data-theme] .tabbar .nav .rbadge {
  transition: left 0.2s ease;
}
html[data-theme] .rail .nav.on .rbadge,
html[data-theme] .tabbar .nav.on .rbadge {
  left: calc(100% - 15px);
}
/* Guest Replies (chat) button: 2px higher and 2px further right */
.rpbtn .rbadge {
  top: -7px;
  right: -7px;
}
.rail .nav,
.tabbar .nav,
.rpbtn {
  overflow: visible;
}

.rbadge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
  font-variant-numeric: tabular-nums;
}
/* 1px less inside at the top and right (number keeps its spot from the bottom-left) */

/* Final badge size: 21px circle, number centered evenly */
.rbadge {
  min-width: 21px;
  height: 21px;
  padding: 0 6px;
  border-radius: 10.5px;
}
/* "TIME:" label in front of the live clock on the board header */
.ch-clock .clk-l {
  font-family: var(--sans);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  opacity: 0.8;
  margin-right: 6px;
  align-self: center;
}
/* Board clock: blue tint fades into the gray header on the right */
html[data-theme] .colhead .ch-clock {
  background: linear-gradient(90deg, color-mix(in srgb, var(--accent, #2563eb) 18%, transparent) 0%, color-mix(in srgb, var(--accent, #2563eb) 10%, transparent) 55%, transparent 100%) !important;
  border-right: 0 !important;
  box-shadow: none !important;
}

/* ===== Day-first booking: prompt on the board + fixed day in Book a Table ===== */
.bookbar {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 14px 12px 16px;
  border-radius: 14px;
  border: 1px solid color-mix(in srgb, var(--accent, #2563eb) 55%, transparent);
  background: color-mix(in srgb, var(--accent, #2563eb) 12%, var(--coal));
  animation: bbIn 0.2s ease;
}
.bookbar[hidden] {
  display: none;
}
@keyframes bbIn {
  from {
    opacity: 0;
    transform: translateY(-4px);
  }
}
.bookbar .bb-ic {
  flex: none;
  display: inline-flex;
  color: var(--accent, #6ea0ff);
}
.bookbar .bb-ic svg {
  width: 22px;
  height: 22px;
}
.bookbar .bb-t {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}
.bookbar .bb-t b {
  font-weight: 600;
  font-size: 15px;
}
.bookbar .bb-t span {
  font-size: 13px;
  color: var(--sub);
}
.bookbar .sp {
  flex: 1;
}
.bookbar .btn {
  flex: none;
  white-space: nowrap;
}
.bookbar .btn svg {
  width: 17px;
  height: 17px;
  margin-right: 6px;
}
.bookbar .btn[disabled] {
  opacity: 0.45;
  pointer-events: none;
}
@media (max-width: 760px) {
  .bookbar {
    flex-wrap: wrap;
  }
  .bookbar .sp {
    display: none;
  }

  .bookbar .btn {
    flex: 1 1 0;
  }
}
.dfixed {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}
.dfixed .dfx {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 0 16px;
  border-radius: 12px;
  border: 1px solid var(--accent, #2563eb);
  background: color-mix(in srgb, var(--accent, #2563eb) 16%, transparent);
  font-size: 16px;
  flex: none; /* Change Day wraps below rather than squeezing the date */
  min-width: 0;
  max-width: 100%; /* never wider than the card; the date text shortens instead */
}
.dfixed .dfx svg,
.dfixed .dfx .today-tag {
  flex: none;
}
.dfixed .dfx svg {
  width: 18px;
  height: 18px;
  color: var(--accent, #6ea0ff);
}
.dfixed .dfx b {
  font-weight: 600;
  min-width: 0;
  white-space: nowrap; /* one line: the script switches to "Wed, Nov 11" when it won't fit */
  overflow: hidden;
  text-overflow: ellipsis;
}
.dfixed .today-tag {
  margin-left: 2px;
}
.bookbar {
  margin: 14px 28px 0;
}
@media (max-width: 760px) {
  .bookbar {
    margin: 12px 18px 0;
  }
}
/* Booking prompt: Cancel and Choose Day are the same height */
.bookbar .btn {
  height: 44px;
  min-height: 44px;
  padding-top: 0;
  padding-bottom: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
}
/* Book a Table: "Change day" matches the height of the date box */
.dfixed .dfx,
.dfixed .chip {
  height: 44px;
  min-height: 44px;
  box-sizing: border-box;
}
.dfixed .chip {
  display: inline-flex;
  align-items: center;
  padding: 0 16px;
}

/* ===== Time slots: guests already booked (number + colored bar) ===== */
:root,
html[data-theme="dark"] {
  --lv1: #4ade80; /* light  */
  --lv2: #fbbf24; /* busy   */
  --lv3: #f87171; /* heavy  */
}
html[data-theme="light"] {
  --lv1: #16a34a;
  --lv2: #d97706;
  --lv3: #dc2626;
}
.chips.times .chip:has(.load) {
  border-bottom-color: var(--line2);
}
.chips.times .chip .gc {
  position: absolute;
  top: 3px;
  right: 5px;
  font-size: 10.5px;
  font-weight: 700;
  line-height: 1;
  letter-spacing: 0;
  font-variant-numeric: tabular-nums;
}
.gc.lv1 { color: var(--lv1); }
.gc.lv2 { color: var(--lv2); }
.gc.lv3 { color: var(--lv3); }
html[data-theme] .layer .chips.times .chip .load.lv1 i { background: var(--lv1) !important; }
html[data-theme] .layer .chips.times .chip .load.lv2 i { background: var(--lv2) !important; }
html[data-theme] .layer .chips.times .chip .load.lv3 i { background: var(--lv3) !important; }
.chips.times .chip .load {
  height: 4px;
}
/* Selected slot keeps its level color on the number and bar */
html[data-theme][data-theme] body .layer .chip.on .gc {
  color: #fff !important;
  opacity: 0.9;
}
.othertime .legend {
  flex-wrap: wrap;
  gap: 12px;
}
.othertime .legend .lg {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.othertime .legend .lg i {
  display: inline-block;
  width: 16px;
  height: 4px;
  border-radius: 2px;
}
.othertime .legend .lv1 i { background: var(--lv1); }
.othertime .legend .lv2 i { background: var(--lv2); }
.othertime .legend .lv3 i { background: var(--lv3); }
.othertime .legend .lg-n {
  color: var(--faint, var(--mute));
}
/* TODAY pill: text truly centered (letter-spacing leaves a trailing gap), and sits level with the date */
.today-tag {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding-left: calc(10px + 0.2em);
  padding-right: 10px;
}
.dfixed .today-tag {
  transform: none;
  align-self: center;
}
/* Past time slots: guest count and bar go gray too */
html[data-theme] .layer .chips.times .chip.past .gc {
  color: var(--faint, var(--mute)) !important;
  opacity: 0.7;
}
html[data-theme] .layer .chips.times .chip.past .load i {
  background: var(--line2) !important;
}
/* Guests seated / Waitlist stats work as filters */
button.stat.statf {
  appearance: none;
  -webkit-appearance: none;
  background: none;
  border-top: 0;
  border-right: 0;
  border-bottom: 0;
  margin: 0;
  font: inherit;
  color: inherit;
  text-align: left;
  cursor: pointer;
  border-radius: 0 10px 10px 0;
  padding-top: 2px;
  padding-bottom: 2px;
  padding-right: 10px;
  transition: background 0.15s ease;
}
/* the bar's extra 2px slides out to the left when selected, and back in when deselected */
button.stat.statf.j-on {
  animation: statBarOut 0.24s ease both;
}
button.stat.statf.j-off {
  animation: statBarIn 0.24s ease both;
}
@keyframes statBarOut {
  from {
    box-shadow: 0 0 0 0 var(--stat-c, currentColor);
  }
  to {
    box-shadow: -2px 0 0 0 var(--stat-c, currentColor);
  }
}
@keyframes statBarIn {
  from {
    box-shadow: -2px 0 0 0 var(--stat-c, currentColor);
  }
  to {
    box-shadow: 0 0 0 0 var(--stat-c, currentColor);
  }
}
button.stat.statf .k {
  text-decoration: none;
}
button.stat.statf:hover {
  background: color-mix(in srgb, var(--text) 6%, transparent);
}
/* selected: the coloured bar thickens outward (to the left) — the border stays 2px, the extra 2px is a
   shadow outside it — so the number and label don't move */
button.stat.statf.on {
  background: color-mix(in srgb, var(--text) 9%, transparent);
  box-shadow: -2px 0 0 0 var(--stat-c, currentColor);
}
html[data-theme] .stat.t-seated {
  --stat-c: var(--c-seated);
}
html[data-theme] .stat.t-waiting {
  --stat-c: var(--c-waiting);
}
html[data-theme="light"] .stat.t-seated {
  --stat-c: #16a34a;
}
html[data-theme="light"] .stat.t-waiting {
  --stat-c: #9333ea;
}
button.stat.statf.on .k {
  text-decoration: none;
  color: var(--text);
}

/* ===== Checked in (arrived, waiting for their table) — teal ===== */
:root,
html[data-theme="dark"] {
  --c-checkedin: #2dd4bf;
}
html[data-theme="light"] {
  --c-checkedin: #0f9488;
}
html[data-theme] .s-checkedin {
  --c: var(--c-checkedin);
  --pill: color-mix(in srgb, var(--c-checkedin) 22%, transparent);
}
html[data-theme] .row.s-checkedin .dot {
  background: var(--c-checkedin);
  border: 0;
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--c-checkedin) 25%, transparent);
}
html[data-theme] .row.s-checkedin::before,
html[data-theme] .row.s-checkedin .bar {
  background: var(--c-checkedin);
}
html[data-theme] .npill.s-checkedin {
  color: var(--c-checkedin) !important;
  border-color: color-mix(in srgb, var(--c-checkedin) 60%, transparent) !important;
  background: color-mix(in srgb, var(--c-checkedin) 14%, transparent) !important;
  display: inline-flex;
  align-items: center;
  gap: 5px;
}
.npill.s-checkedin svg {
  width: 13px;
  height: 13px;
}
/* Second-line pills (RES time on checked-in rows, WALK-IN on the waitlist): a solid fill of the
   status colour with dark text, so they stand well apart from the outlined status pill above them */
html[data-theme] .badge.s-checkedin,
html[data-theme] .badge.walkin {
  --dc: var(--c-checkedin);
  color: #0d1013 !important;
  border: 1px solid var(--dc) !important;
  background: var(--dc) !important;
}
html[data-theme] .badge.walkin {
  --dc: var(--c-waiting);
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}
html[data-theme="light"] .badge.s-checkedin,
html[data-theme="light"] .badge.walkin {
  color: color-mix(in srgb, var(--dc) 38%, #000) !important;
  border-color: color-mix(in srgb, var(--dc) 62%, #fff) !important;
  background: color-mix(in srgb, var(--dc) 55%, #fff) !important;
}
.flag.ci {
  border-color: color-mix(in srgb, var(--c-checkedin) 45%, transparent);
  background: color-mix(in srgb, var(--c-checkedin) 10%, transparent);
}
.flag.ci svg {
  color: var(--c-checkedin);
}
html[data-theme] .btn.cibtn {
  color: var(--c-checkedin);
  border-color: color-mix(in srgb, var(--c-checkedin) 55%, transparent);
  background: color-mix(in srgb, var(--c-checkedin) 12%, transparent);
}
html[data-theme] .btn.cibtn:hover {
  background: color-mix(in srgb, var(--c-checkedin) 20%, transparent);
}
.btn.cibtn svg {
  width: 18px;
  height: 18px;
  margin-right: 6px;
}
html[data-theme][data-theme] body .row .npill.s-checkedin {
  color: var(--c-checkedin) !important;
  background: color-mix(in srgb, var(--c-checkedin) 14%, transparent) !important;
  border: 1px solid color-mix(in srgb, var(--c-checkedin) 55%, transparent) !important;
}
html[data-theme="light"][data-theme] body .row .npill.s-checkedin {
  color: #0b766c !important;
  background: #d5f5f0 !important;
}
/* Stats: a little room above and below so the hover / active background has padding (all bars match) */
#bkStats .stat,
#bkStats button.stat.statf {
  padding-top: 8px;
  padding-bottom: 8px;
}
#bkStats .stat {
  padding-right: 12px;
}
/* Checked In step on the reservation timeline (teal) */
.stp.sc-checkedin {
  --sc: var(--c-checkedin);
}
html[data-theme] .stp.sc-checkedin.cur {
  color: var(--c-checkedin);
}
.stp.static {
  cursor: default;
}
/* 5-step timeline: keep every label on one line */
.stepper .stp {
  white-space: nowrap;
  letter-spacing: 0.06em;
}
/* Phone: compact New Reservation bar */
@media (max-width: 760px) {
  .bookbar {
    gap: 8px 10px;
    padding: 10px 12px;
    border-radius: 12px;
  }
  .bookbar .bb-ic {
    display: none;
  }
  .bookbar .bb-t {
    flex: 1 1 100%;
    gap: 1px;
  }
  .bookbar .bb-t b {
    font-size: 14px;
  }
  .bookbar .bb-t span {
    font-size: 12.5px;
    line-height: 1.35;
  }
  .bookbar .btn {
    height: 36px;
    min-height: 36px;
    font-size: 14px;
    border-radius: 10px;
  }
  .bookbar .btn svg {
    width: 15px;
    height: 15px;
  }
  /* ===== iPhone (notch / Dynamic Island) ===== */
  html[data-theme] .top {
    padding-top: calc(22px + var(--sa-t));
  }
  /* Keep scrolled content from showing behind the status bar */
  body::before {
    content: "";
    position: fixed;
    left: 0;
    right: 0;
    top: 0;
    height: var(--sa-t);
    background: var(--ink);
    z-index: 60;
    pointer-events: none;
  }
}
.bookbar .bb-t .bb-hl {
  display: inline;
  font-size: inherit;
  font-weight: 700;
  color: var(--accent, #6ea0ff);
}
html[data-theme="dark"] .bookbar .bb-t .bb-hl {
  color: #7fb0ff;
}
/* Cancel in the New Reservation bar: visible edge so it reads the same size as Choose Day */
html[data-theme] .bookbar .btn.ghost {
  border: 1px solid color-mix(in srgb, var(--text) 26%, transparent) !important;
  background: color-mix(in srgb, var(--text) 6%, var(--coal)) !important;
}
html[data-theme] .bookbar .btn.ghost:hover {
  background: color-mix(in srgb, var(--text) 11%, var(--coal)) !important;
}
/* "Now" button next to the board clock — scrolls to the current time slot */
.colhead .ch-now {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  height: 26px;
  padding: 0 10px;
  border-radius: 8px;
  border: 1px solid var(--line2);
  background: color-mix(in srgb, var(--text) 5%, transparent);
  color: var(--mute);
  font: 600 11px/1 var(--sans);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease;
}
.colhead .ch-now svg {
  width: 13px;
  height: 13px;
}
.colhead .ch-now:hover {
  color: var(--sub);
  background: color-mix(in srgb, var(--text) 10%, transparent);
}
/* Now sits at the right end of the header (over the Action column): dimmed while the current
   time slot is on screen, blue once the board is scrolled away from it */
@media (min-width: 761px) {
  .colhead .ch-act {
    display: flex;
    justify-content: flex-end;
    align-items: center;
  }
}
/* both header buttons: gray when idle — Now when the current slot is on screen, Finished when all are shown */
.colhead .ch-now:not(.away):not(.on) {
  opacity: 0.55;
}
.colhead .ch-act .ch-now {
  flex: none;
  white-space: nowrap;
}
.colhead .ch-act .ch-hide {
  margin-right: 8px;
}
html[data-theme] .colhead .ch-now.ch-hide.on,
html[data-theme] .colhead .ch-now.away {
  color: #93c5fd;
  border-color: color-mix(in srgb, #60a5fa 65%, transparent);
  background: color-mix(in srgb, #60a5fa 14%, transparent);
}
html[data-theme="light"] .colhead .ch-now.ch-hide.on,
html[data-theme="light"] .colhead .ch-now.away {
  color: #1d4ed8;
  border-color: color-mix(in srgb, #2563eb 55%, transparent);
  background: color-mix(in srgb, #3b82f6 10%, transparent);
}
/* Phone: the first header in the board follows the board's rounded top corners */
@media (max-width: 760px) {
  #bkList > .gsec:first-child > .grp,
  #bkList > .wlhead:first-child {
    border-top-left-radius: 13px;
    border-top-right-radius: 13px;
  }
  /* Phone stats: labels wrap only between words (2 lines max) and the five columns use the full width */
  html[data-theme] #bkStats {
    gap: 4px;
  }
  html[data-theme] #bkStats .stat,
  html[data-theme] #bkStats button.stat.statf {
    padding: 8px 2px 8px 8px;
    min-width: 0;
  }
  html[data-theme] #bkStats .stat .k {
    overflow-wrap: normal;
    word-break: keep-all;
    hyphens: none;
    font-size: 9.5px;
    letter-spacing: 0.05em;
    line-height: 1.3;
  }
  /* Phone: time slots fill the row (4 across) so the guest count has room beside the time */
  html[data-theme] .layer .chips.times {
    display: grid !important;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 6px;
    width: 100%;
  }
  html[data-theme] .layer .chips.times .chip {
    width: auto !important;
    min-width: 0 !important;
    max-width: none !important;
    flex: none !important;
  }
  html[data-theme] .layer .chips.times .chip .gc {
    top: 3px;
    font-size: 10px;
  }
  html[data-theme] .layer .chips.times .chip .gc {
    right: 5px;
  }
}
/* New Reservation bar: keep the hint on one line on iPad / desktop */
@media (min-width: 1101px) {
  .bookbar .bb-t span {
    white-space: nowrap;
  }
  .bookbar .bb-t {
    min-width: 0;
  }
}
/* Reservation timeline: use the panel's full width so five labels have breathing room */
.dp .stepper {
  margin-left: -22px;
  margin-right: -22px;
}
.dp .stepper .stp {
  letter-spacing: 0.04em;
}
/* New Reservation bar in the header, to the right of the date (iPad / desktop) */
@media (min-width: 761px) {
  html[data-theme] .top:has(.bb-top:not([hidden])) {
    flex-wrap: wrap !important;
  }
  html[data-theme] .top:has(.bb-top:not([hidden])) .title {
    flex: 0 0 auto;
    min-width: 0;
  }
  html[data-theme] .top:has(.bb-top:not([hidden])) .tools {
    order: 3;
    flex: 1 1 100%;
  }
  .top .bookbar.bb-top {
    order: 2;
    flex: 1 1 0;
    min-width: 0;
    margin: 0 0 0 auto;
    align-self: center;
    padding: 10px 12px 10px 14px;
  }
  .top .bookbar.bb-top .btn {
    height: 40px;
    min-height: 40px;
  }
  html[data-theme] .top .bookbar.bb-top .bb-t span {
    white-space: normal;
    font-size: 13px;
    line-height: 1.35;
  }
  html[data-theme] .top .bookbar.bb-top .bb-t {
    flex: 1 1 auto;
  }
}
/* Narrow iPads: buttons drop under the message */
@media (min-width: 761px) and (max-width: 1100px) {
  .top .bookbar.bb-top {
    flex-wrap: wrap;
  }
  .top .bookbar.bb-top .bb-ic {
    display: none;
  }

  .top .bookbar.bb-top .sp {
    display: none;
  }
  .top .bookbar.bb-top .btn {
    flex: 1 1 0;
  }
}
/* iPad (up to the 13" iPad Pro landscape, 1376px): narrower search so the Book button has room for its date */
@media (min-width: 761px) and (max-width: 1376px) {
  html[data-theme] .top .tools .newbtn[data-act="new"] {
    white-space: nowrap;
  }
}
@media (min-width: 761px) and (max-width: 1100px) {
  html[data-theme] .top .bookbar.bb-top .bb-t {
    flex: 1 1 100%;
  }
}
/* iPad: search box always wide enough for its full placeholder */

/* Book a Table: legend sits on the "Different Time" row (saves height so nothing spills into Seating) */
html[data-theme] .ed .othertime {
  flex-wrap: nowrap;
  gap: 10px;
}
html[data-theme] .ed .othertime .legend {
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 4px 10px;
  font-size: 11px;
  min-width: 0;
}
html[data-theme] .ed .othertime .legend .lg-n {
  flex-basis: 100%;
  text-align: right;
}
@media (max-width: 760px) {
  html[data-theme] .ed .othertime {
    flex-wrap: wrap;
  }
  html[data-theme] .ed .othertime .legend {
    justify-content: flex-start;
  }
  html[data-theme] .ed .othertime .legend .lg-n {
    text-align: left;
  }
  /* Phone: all times left-aligned in their buttons (guest count stays in the top-right corner) */
  html[data-theme] .layer .chips.times .chip,
  html[data-theme] .layer .chips.times .chip:has(.gc) {
    justify-content: flex-start !important;
    text-align: left !important;
    padding-left: 12px !important;
    padding-right: 4px !important;
  }
}
html[data-theme] .ed .othertime > .faint {
  white-space: nowrap;
}

/* ===== Table picker: floor plan ===== */
.tpdlg .panel {
  width: min(880px, 100vw - 24px) !important;
  max-width: none !important;
}
.tpbody {
  gap: 14px;
}
.fpwrap {
  border: 1px solid var(--line);
  border-radius: 14px;
  background: color-mix(in srgb, var(--text) 3%, var(--ink));
  padding: 8px;
  overflow: auto;
  -webkit-overflow-scrolling: touch;
}
.floor {
  display: block;
  width: 100%;
  height: auto;
  max-height: min(62vh, 640px);
  user-select: none;
  -webkit-user-select: none;
}
.floor .fp-wall {
  stroke: color-mix(in srgb, var(--text) 55%, transparent);
  stroke-width: 9;
  stroke-linecap: round;
}

.floor .fp-barl,
.floor .fp-lbl {
  dominant-baseline: central;
  fill: var(--mute);
  font: 600 22px var(--sans);
  letter-spacing: 0.12em;
  text-anchor: middle;
}
.floor .fp-barl {
  fill: var(--sub);
}

.floor .fp-t {
  cursor: pointer;
  outline: none;
}
.floor .fp-t circle,
.floor .fp-t rect {
  fill: var(--coal);
  stroke: color-mix(in srgb, var(--text) 35%, transparent);
  stroke-width: 3;
  transition: fill 0.12s ease, stroke 0.12s ease;
}
.floor .fp-t:hover circle,
.floor .fp-t:hover rect,
.floor .fp-t:focus-visible circle,
.floor .fp-t:focus-visible rect {
  stroke: var(--accent, #3b82f6);
}
.floor .fp-n {
  fill: var(--text);
  font: 700 24px var(--sans);
  text-anchor: middle;
  pointer-events: none;
}
.floor .fp-s {
  font: 800 13px var(--sans);
  text-anchor: middle;
  pointer-events: none;
}
/* seated now — green */
.floor .fp-t.tk-seated circle,
.floor .fp-t.tk-seated rect {
  fill: color-mix(in srgb, var(--c-seated) 22%, var(--coal));
  stroke: var(--c-seated);
}

/* assigned within 90 min — orange */
.floor .fp-t.tk-held circle,
.floor .fp-t.tk-held rect {
  fill: color-mix(in srgb, var(--c-hold) 20%, var(--coal));
  stroke: var(--c-hold);
}

/* selected — solid white table with a blue outline, blue text and a soft blue glow (both themes) */
.floor {
  --sel-ring: var(--c-asg);
  --sel-ink: #ffffff;
}
.floor .fp-t.on circle,
.floor .fp-t.on rect {
  fill: #ffffff;
  stroke: var(--sel-ring);
  stroke-width: 5;
}
.floor .fp-t.on {
  filter: drop-shadow(0 0 7px color-mix(in srgb, var(--sel-ring) 55%, transparent));
}
.floor .fp-t.on .fp-n,
.floor .fp-t.on .fp-s {
  fill: var(--sel-ring);
}
.tp-rooms:empty {
  display: none;
}
.tp-legend .tk-free {
  background: var(--coal);
  border: 1.5px solid color-mix(in srgb, var(--text) 35%, transparent);
}
.tp-legend .tk-on {
  background: #ffffff;
  border: 2px solid var(--c-asg);
  box-shadow: 0 0 5px color-mix(in srgb, var(--c-asg) 45%, transparent);
}
.tp-legend {
  flex-wrap: wrap;
}
@media (max-width: 760px) {
  .fpwrap {
    padding: 4px;
  }
  .floor {
    width: 640px;
    max-width: none;
    max-height: none;
  }
}
/* table picker layout: field + rooms on one row, map fills the rest, legend in the footer */
.tpbody .tp-top {
  display: flex;
  align-items: flex-end;
  gap: 12px 16px;
  flex-wrap: wrap;
}
.tpbody .tp-top .field {
  flex: 1 1 260px;
  margin: 0;
}
.tpbody .tp-top .tp-rooms {
  flex: 0 1 auto;
  margin: 0;
}
.tpbody .floor {
  max-height: calc(100vh - 360px);
  min-height: 300px;
}
.tpdlg .sh-foot .tp-legend {
  margin: 0 0 0 4px;
  padding: 0;
  border: 0;
  font-size: 12px;
  gap: 6px 14px;
}

@media (max-width: 760px) {
  .tpdlg .sh-foot .tp-legend {
    display: none;
  }
  .tpbody .floor {
    max-height: none;
    min-height: 0;
  }
}
/* iPad / desktop: the floor plan fills whatever height the window has left (no scrolling) */
@media (min-width: 761px) {
  .tpdlg .panel {
    display: flex;
    flex-direction: column;
    height: min(900px, 100vh - 40px);
    max-height: calc(100vh - 40px);
  }
  .tpdlg .sh-body.tpbody {
    flex: 1 1 auto;
    min-height: 0;
    display: flex;
    flex-direction: column;
    overflow: hidden;
  }
  .tpdlg .fpwrap {
    flex: 1 1 auto;
    min-height: 0;
    overflow: hidden;
    display: flex;
  }
  .tpdlg .floor {
    width: 100%;
    height: 100%;
    max-height: none;
    min-height: 0;
  }
}
/* floor plan: one text size for every table */

.floor .fp-s {
  font-weight: 800;
}
.floor .fp-lbl {
  font-size: 24px;
}
.floor .fp-barl {
  font-size: 34px;
}
/* Bar on the floor plan is tappable like a table */
.floor .fp-bart rect {
  fill: color-mix(in srgb, var(--text) 7%, var(--coal));
}
.floor .fp-bart .fp-barl {
  fill: var(--sub);
}
.floor .fp-bart.on .fp-barl {
  fill: var(--sel-ring);
}

/* Rooms (Bar, Chefs Room, 500s) use the same text size as the table numbers */
.floor .fp-bart .fp-barl {
  font: 700 28px var(--sans);
  letter-spacing: 0.1em;
}

.floor .fp-bart ellipse {
  fill: color-mix(in srgb, var(--text) 7%, var(--coal));
  stroke: color-mix(in srgb, var(--text) 35%, transparent);
  stroke-width: 3;
}
.floor .fp-bart:hover ellipse {
  stroke: var(--accent, #3b82f6);
}
.floor .fp-bart.tk-seated ellipse {
  fill: color-mix(in srgb, var(--c-seated) 22%, var(--coal));
  stroke: var(--c-seated);
}
.floor .fp-bart.tk-held ellipse {
  fill: color-mix(in srgb, var(--c-hold) 20%, var(--coal));
  stroke: var(--c-hold);
}
.floor .fp-bart.on ellipse {
  fill: #ffffff;
  stroke: var(--sel-ring);
  stroke-width: 5;
}

/* Larger tables: numbers and status text centred in each shape */
.floor .fp-n,
.floor .fp-s,
.floor .fp-barl {
  dominant-baseline: central;
}
.floor .fp-n {
  font-size: 33px;
}

.floor .fp-bart .fp-barl {
  font-size: 33px;
}

/* Bigger seating chart: the pop-up uses nearly the whole iPad / desktop window */
@media (min-width: 767px) {
  .tpdlg .panel {
    --tpw: min(1180px, 100vw - 160px);
    width: var(--tpw) !important;
    /* always wider than tall */
    height: min(100vh - 24px, var(--tpw) * 0.74);
    max-height: calc(100vh - 24px);
  }
  .tpdlg .sh-head {
    padding-top: 18px;
    padding-bottom: 14px;
  }
  .tpdlg .sh-body.tpbody {
    padding-top: 14px;
    padding-bottom: 14px;
    gap: 12px;
  }
  .tpdlg .sh-foot {
    padding-top: 12px;
    padding-bottom: 12px;
  }
  .tpdlg .fpwrap {
    padding: 4px;
  }
}
.floor .fp-s,
.floor .fp-bart .fp-s {
  font-size: 21px !important;
  letter-spacing: 0 !important;
}
/* Floor plan: restroom icons and the logo */
.floor .fp-wc {
  fill: var(--mute);
  pointer-events: none;
}
.floor .fp-logo-img {
  opacity: 0.5;
  pointer-events: none;
}
/* light mode: soft grey logo. An SVG filter (defined in the floor plan) rather than a CSS one — Safari
   and the iPad app ignore CSS filters on SVG images, which left the logo white */
html[data-theme="light"] .floor .fp-logo-img {
  filter: url(#fpLogoGray);
  opacity: 1;
}
/* Status tag: solid pill in the status colour, white text */

/* Desktop browser: a wider seating chart */
@media (min-width: 1377px) {
  .tpdlg .panel {
    --tpw: min(1500px, 100vw - 240px);
  }
}
.floor .fp-t .fp-s {
  font-weight: 800;
  letter-spacing: 0.03em !important;
}
.floor .fp-t.tk-seated .fp-s {
  fill: var(--c-seated) !important;
}
.floor .fp-t.tk-held .fp-s {
  fill: var(--c-hold) !important;
}
.floor .fp-t.on .fp-s {
  fill: var(--sel-ring) !important;
}
.floor .fp-t .fp-s {
  font-size: 22px !important;
}
/* Status band: solid colour behind the indicator text, full width of the table */
.floor .fp-t rect.fp-band {
  stroke: none !important;
  fill: var(--c-seated) !important;
}
.floor .fp-t.tk-held rect.fp-band {
  fill: var(--c-hold) !important;
}
.floor .fp-t.on rect.fp-band {
  fill: var(--sel-ring) !important;
}
.floor .fp-t .fp-ol rect,
.floor .fp-t .fp-ol circle {
  fill: none !important;
  pointer-events: none;
}
.floor .fp-t.tk-seated .fp-sb,
.floor .fp-t.tk-held .fp-sb {
  fill: #fff !important;
}
html[data-theme="dark"] .floor .fp-t.tk-seated .fp-sb,
html[data-theme="dark"] .floor .fp-t.tk-held .fp-sb {
  fill: #10140f !important;
}

.floor .fp-band {
  pointer-events: none;
}
.floor .fp-t .fp-ol ellipse {
  fill: none !important;
  pointer-events: none;
}
.floor .fp-bart .fp-sb {
  dominant-baseline: central;
}
/* Rooms: one band segment per party, each in its own status colour */
.floor .fp-t rect.fp-seg {
  stroke: none !important;
  fill: var(--c-seated) !important;
  pointer-events: none;
}
.floor .fp-t rect.fp-seg.k-held {
  fill: var(--c-hold) !important;
}
.floor .fp-t.on rect.fp-seg {
  fill: var(--sel-ring) !important;
}
.floor .fp-sep {
  stroke: color-mix(in srgb, #000 45%, transparent);
  stroke-width: 3;
  pointer-events: none;
}
.floor .fp-t .fp-segt {
  fill: #fff !important;
  font-size: 22px !important;
  font-weight: 800;
  letter-spacing: 0.03em !important;
  text-anchor: middle;
  pointer-events: none;
}
html[data-theme="dark"] .floor .fp-t .fp-segt {
  fill: #10140f !important;
}
.floor .fp-t.on .fp-segt {
  fill: var(--sel-ink) !important;
}
/* Toast "Show" link: brighter in dark mode so it doesn't blend into the toast */
html[data-theme="dark"] .toast .tshow { /* vivid blue, so SHOW stands apart from UNDO */
  font-weight: 700;
}
/* iPad header (today): shorter search so the replies button keeps its full size and the
   TODAY tag gets breathing room */
@media (min-width: 761px) and (max-width: 1376px) {
  html[data-theme] .top .tools .search {
    flex: 0 1 262px !important;
    min-width: 200px !important;
    max-width: 262px !important;
  }
  html[data-theme] .top .tools .rpbtn {
    flex: 0 0 auto !important;
    min-width: 44px !important;
    width: 44px !important;
  }
  html[data-theme] .top .tools {
    min-width: 0;
    margin-left: 24px;
  }
}
/* 676–1199px: tall pop-up, the seating chart scrolls sideways at a readable size */
@media (min-width: 676px) and (max-width: 1199px) {
  .tpdlg .panel {
    display: flex;
    flex-direction: column;
    width: calc(100vw - 24px) !important;
    max-width: none !important;
    height: calc(100vh - 24px) !important;
    max-height: calc(100vh - 24px) !important;
  }
  .tpdlg .sh-body.tpbody {
    flex: 1 1 auto;
    min-height: 0;
    display: flex;
    flex-direction: column;
    overflow: hidden;
  }
  .tpdlg .fpwrap.fp-scroll {
    flex: 1 1 auto;
    min-height: 0;
    display: block !important;
    overflow-x: auto !important;
    overflow-y: hidden !important;
    -webkit-overflow-scrolling: touch;
  }
  .tpdlg .fpwrap.fp-scroll .floor {
    max-width: none !important;
    max-height: none !important;
    min-height: 0 !important;
  }
  .tpdlg .sh-foot .tp-legend {
    display: flex !important;
  }
}
/* Phones: the same floor-plan window — tall pop-up, the chart scrolls sideways at a readable size;
   the table field and Reserve Table share one row to leave the chart more room */
@media (max-width: 675px) {
  .tpdlg .panel {
    display: flex;
    flex-direction: column;
  }
  .tpdlg .sh-body.tpbody {
    flex: 1 1 auto;
    min-height: 0;
    display: flex;
    flex-direction: column;
    overflow: hidden;
  }
  .tpdlg .fpwrap.fp-scroll {
    flex: 1 1 auto;
    min-height: 0;
    display: block !important;
    overflow-x: auto !important;
    overflow-y: hidden !important;
    -webkit-overflow-scrolling: touch;
  }
  .tpdlg .fpwrap.fp-scroll .floor {
    max-width: none !important;
    max-height: none !important;
    min-height: 0 !important;
  }
  .tpbody .tp-top {
    gap: 10px;
  }
  .tpbody .tp-top .field {
    flex: 1 1 0;
    min-width: 0;
  }
  .tpbody .tp-top .tp-rooms {
    order: 3;
    flex-basis: 100%;
  }
  html[data-theme] .tpbody .tp-top .tp-asg {
    padding: 0 14px;
    gap: 7px;
  }
  /* alert card over the chart: table number on top, each party full width, its button on a line below */
  html[data-theme] .tpdlg .tp-info {
    width: calc(100% - 24px);
    max-width: none;
    padding: 12px 40px 12px 14px;
  }
  html[data-theme] .tpdlg .tp-info .tpi {
    grid-template-columns: minmax(0, 1fr);
  }
  html[data-theme] .tpdlg .tp-info .tpi > .tpi-p,
  html[data-theme] .tpdlg .tp-info .tpi > .tpi-m,
  html[data-theme] .tpdlg .tp-info .tpi-t {
    grid-column: 1;
    grid-row: auto;
  }
  html[data-theme] .tpdlg .tp-info .tpi-p {
    display: block;
    justify-self: stretch;
    padding: 8px 12px 8px 26px;
    border-radius: 12px;
    line-height: 1.4;
  }
  html[data-theme] .tpdlg .tp-info .tpi-p i {
    display: inline-block;
    margin: 0 6px 1px -14px;
    vertical-align: middle;
  }
  html[data-theme] .tpdlg .tp-info .tpi-p .tpi-asg {
    display: flex;
    width: max-content;
    margin: 7px 0 1px;
  }
}
/* room band text must win over the generic seated/held text colour */
html[data-theme] .floor .fp-t .fp-s.fp-segt {
  fill: #fff !important;
}
html[data-theme="dark"] .floor .fp-t .fp-s.fp-segt {
  fill: #10140f !important;
}
html[data-theme] .floor .fp-t.on .fp-s.fp-segt {
  fill: var(--sel-ink) !important;
}
/* Buttons: every word starts with a capital ("Assign Table"). Zero specificity, so buttons that are
   styled all-caps (SHOW / UNDO, eyebrow-style) keep their own casing */
:where(.btn) {
  text-transform: capitalize;
}
/* Table Reserved — blue: locked in, all good (a request without it stays orange). Red is kept for
   problems only: Table Conflict, Cancel / No Show */
:root,
html[data-theme="dark"] {
  --c-asg: #1a73e8;
}
.tp-legend i.tk-assigned {
  background: var(--c-asg);
}
.floor .fp-t.tk-assigned:not(.on) circle,
.floor .fp-t.tk-assigned:not(.on) rect,
.floor .fp-bart.tk-assigned:not(.on) ellipse {
  fill: color-mix(in srgb, var(--c-asg) 20%, var(--coal));
  stroke: var(--c-asg);
}
.floor .fp-t.tk-assigned .fp-s {
  fill: var(--c-asg);
}
.floor .fp-t.tk-assigned rect.fp-band,
.floor .fp-t rect.fp-seg.k-assigned {
  fill: var(--c-asg) !important;
}
.floor .fp-t.on rect.fp-seg.k-assigned {
  fill: var(--sel-ring) !important;
}
html[data-theme] .floor .fp-t.tk-assigned .fp-sb {
  fill: #fff !important;
}
html[data-theme] .floor .fp-t.on .fp-sb {
  fill: var(--sel-ink) !important;
}
html[data-theme] .tpick .chip.tk-assigned {
  --tk: color-mix(in srgb, var(--c-asg) 75%, transparent);
  --tk-text: var(--c-asg);
}
/* Editor: Table Assigned checkbox row at the bottom of Seating */
.ed .ed-asg .ev {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
}
.ed .ed-asg-h {
  font-size: 13px;
}
/* Desktop / iPad: the hint sits to the right of the Reserve Table button, on one line */
@media (min-width: 761px) {
  .ed .ec-seat .ed-asg {
    display: block !important;
    grid-column: 1 / -1;
  }
  .ed .ec-seat .ed-asg > .el {
    display: none;
  }
  .ed .ec-seat .ed-asg .ev {
    display: flex !important;
    flex-direction: row !important;
    justify-content: flex-start !important;
    flex-wrap: nowrap;
    align-items: center;
    gap: 14px;
  }
  .ed .ec-seat .ed-asg {
    container-type: inline-size;
  }
  .ed .ec-seat .ed-asg .ed-asg-h {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    min-width: 0;
  }
}
/* the hint's shorter wording, used when the card is too narrow for the full line on one line */
.ed .ed-asg-h .h-short {
  display: none;
}
/* (the row also holds Open Floor Plan, so the short wording kicks in sooner) */
@container (max-width: 600px) {
  .ed .ec-seat .ed-asg .h-full {
    display: none;
  }
  .ed .ec-seat .ed-asg .h-short {
    display: inline;
  }
}
.tp-legend .tp-note {
  color: var(--mute);
  font-style: italic;
  /* same space either side of the divider: the legend's gap on the left, matching padding on the right */
  padding-left: 14px;
  border-left: 1px solid var(--line);
  margin-left: 0;
}
.tpdlg .sh-foot .tp-legend .tp-note {
  padding-left: 14px;
}
/* Table picker: Table Assigned checkbox + who else is on the selected tables */
.tpbody .tp-top .tp-asg {
  flex: 0 0 auto;
  white-space: nowrap;
  font-weight: 600;
}
.tp-info {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 13.5px;
}
/* Table number on the left; each party on its own line, all left-aligned under the first */
.tp-info .tpi {
  display: grid;
  /* the same first column on every row, so the parties line up; a long name ("Chef's Room") wraps */
  grid-template-columns: 58px minmax(0, 1fr);
  align-items: center;
  justify-items: start;
  gap: 6px 8px;
}
.tp-info .tpi-t {
  grid-column: 1;
  grid-row: 1;
  min-width: 44px;
  font-weight: 700;
  line-height: 1.25;
}
.tp-info .tpi > .tpi-p {
  grid-column: 2;
}
/* a message with no table name (e.g. "Tap a table on the map…") uses the whole width */
.tp-info .tpi.tpi-nt {
  grid-template-columns: minmax(0, 1fr);
}
.tp-info .tpi.tpi-nt > .tpi-m {
  grid-column: 1;
}
.tp-info .tpi-p {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 3px 10px;
  border-radius: 999px;
  border: 1px solid var(--line);
  color: var(--sub);
}
.tp-info .tpi-p i {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--c-hold);
}
.tp-info .tpi-p.k-assigned i {
  background: var(--c-asg);
}
.tp-info .tpi-p.k-seated i {
  background: var(--c-seated);
}
.tp-info .tpi-p.k-assigned {
  border-color: color-mix(in srgb, var(--c-asg) 60%, transparent);
}
/* every party pill as tall as one holding a button ("Left – Finish", "Reserve for …"), so the rows match */
.tp-info .tpi-p {
  min-height: 39px;
}
/* seated now: green outline, like its dot; requested: orange */
.tp-info .tpi-p.k-seated {
  border-color: color-mix(in srgb, var(--c-seated) 60%, transparent);
}
.tp-info .tpi-p.k-held {
  border-color: color-mix(in srgb, var(--c-hold) 60%, transparent);
}
.tp-info .tpi-h {
  color: var(--mute);
  font-size: 12.5px;
}
/* Table Assigned: the table badge on a row / in the details turns red (requests stay orange) */
html[data-theme] .row .meta .tb.asg:not(.none),
html[data-theme] .facts .fx-table .v.asg {
  --f-table: var(--c-asg);
  color: var(--c-asg) !important;
  background: color-mix(in srgb, var(--c-asg) 12%, transparent) !important;
  border-color: color-mix(in srgb, var(--c-asg) 65%, transparent) !important;
}
html[data-theme="light"] .row .meta .tb.asg:not(.none) {
  color: var(--c-asg) !important;
  background: color-mix(in srgb, var(--c-asg) 16%, #fff) !important;
}

/* Reserve Table: a toggle button. Off = blue outline on a light see-through blue; on = solid blue.
   (A hidden checkbox inside keeps the state, so taps, keyboard and the saving code work as before.) */
html[data-theme] .tp-asg {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  user-select: none;
  -webkit-user-select: none;
  white-space: nowrap;
  height: 46px;
  padding: 0 16px;
  gap: 8px;
  position: relative;
  border-radius: 12px;
  border: 1px solid color-mix(in srgb, var(--c-asg) 60%, transparent);
  background: color-mix(in srgb, var(--c-asg) 8%, transparent);
  color: var(--c-asg);
  font-weight: 600;
  transition:
    border-color 0.15s,
    background 0.15s;
}
html[data-theme] .tp-asg:hover {
  background: color-mix(in srgb, var(--c-asg) 14%, transparent);
}
html[data-theme] .tp-asg input {
  position: absolute;
  opacity: 0;
  width: 1px;
  height: 1px;
  pointer-events: none;
}
html[data-theme] .tp-asg .i {
  width: 16px;
  height: 16px;
  flex: none;
}
html[data-theme] .tp-asg:has(input:checked) {
  background: var(--c-asg);
  border-color: var(--c-asg);
  color: #fff;
}
html[data-theme] .tp-asg:has(input:checked):hover {
  filter: brightness(1.08);
}
html[data-theme] .tp-asg:has(input:focus-visible) {
  outline: 2px solid color-mix(in srgb, var(--c-asg) 70%, transparent);
  outline-offset: 2px;
}
html[data-theme] .tp-asg {
  align-self: flex-start;
}
html[data-theme] .tpbody .tp-top .tp-asg {
  align-self: flex-end;
}
/* Booking screen: same size as the Lunch / Dinner buttons */
html[data-theme] .ed .ed-asg .tp-asg {
  height: 32px;
  min-width: 148px;
  padding: 0 14px;
  gap: 7px;
  border-radius: 9px;
  font-size: 13.5px;
  align-self: center;
  justify-self: start;
  width: fit-content;
}
/* Details "Table" box: assigned = red text only (no fill / border) */
html[data-theme] .facts .fx-table .v.asg {
  background: none !important;
  border-color: transparent !important;
  box-shadow: none !important;
}
/* Table request override dialog (the badge gets the same space above it as below) */
.ovr {
  padding-top: 8px;
}
.ovr p {
  margin: 12px 0 0;
}
.ovr-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 12px;
  border-radius: 999px;
  background: #ef4444;
  color: #fff;
  font-weight: 800;
  font-size: 12px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  animation: ovrpop 0.35s cubic-bezier(0.2, 1.4, 0.4, 1);
}
.ovr-badge .i {
  width: 16px;
  height: 16px;
}
@keyframes ovrpop {
  from {
    transform: scale(0.6);
    opacity: 0;
  }
  to {
    transform: none;
    opacity: 1;
  }
}
.ovr-list {
  margin: 10px 0 0;
  padding: 0;
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.ovr-list li {
  padding: 8px 12px;
  border-radius: 10px;
  border: 1px solid color-mix(in srgb, var(--c-asg) 45%, transparent);
}
.ovr-note {
  color: var(--mute);
  font-size: 13.5px;
}
/* Who-else-is-on-this-table card: floats over the map so the floor plan never shrinks */
.tpdlg .sh-body.tpbody {
  position: relative;
}
.tpdlg .tp-info {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  z-index: 6;
  width: max-content;
  max-width: min(760px, calc(100% - 48px));
  padding: 14px 44px 12px 16px;
  border-radius: 14px;
  animation: tpipop 0.22s ease-out;
}

@keyframes tpipop {
  from {
    opacity: 0;
    transform: translate(-50%, -6px) scale(0.98);
  }
  to {
    opacity: 1;
    transform: translateX(-50%);
  }
}
.tpdlg .tp-info .tpi-x {
  position: absolute;
  top: 8px;
  right: 8px;
  width: 28px;
  height: 28px;
  border: 0;
  border-radius: 8px;
  background: none;
  color: var(--mute);
  display: grid;
  place-items: center;
  cursor: pointer;
}
.tpdlg .tp-info .tpi-x .i {
  width: 16px;
  height: 16px;
}
.tpdlg .tp-info .tpi-x:hover {
  background: color-mix(in srgb, var(--text) 8%, transparent);
}
/* Override dialog: the parties losing their request are orange (only assignments are red) */
.ovr-list li {
  border-color: color-mix(in srgb, var(--c-hold) 50%, transparent) !important;
  background: color-mix(in srgb, var(--c-hold) 8%, transparent) !important;
}
.tp-info[hidden] {
  display: none !important;
}
/* Table conflict card: red border and red-tinted background */
html[data-theme] .tpdlg .tp-info {
  --cf: #ef4444;
  border: 1.5px solid var(--cf);
  background: color-mix(in srgb, var(--cf) 14%, var(--panel-solid, #fff));
  box-shadow:
    0 0 0 4px color-mix(in srgb, var(--cf) 16%, transparent),
    0 18px 40px rgba(0, 0, 0, 0.35);
}
html[data-theme="dark"] .tpdlg .tp-info {
  background: color-mix(in srgb, var(--cf) 16%, #23262d);
}
/* Info only (a request on a table that's seated now): green, like a seated table */
html[data-theme] .tpdlg .tp-info.ok {
  border-color: var(--c-seated);
  background: color-mix(in srgb, var(--c-seated) 12%, var(--panel-solid, #fff));
  box-shadow:
    0 0 0 4px color-mix(in srgb, var(--c-seated) 14%, transparent),
    0 18px 40px rgba(0, 0, 0, 0.35);
}
html[data-theme="dark"] .tpdlg .tp-info.ok {
  background: color-mix(in srgb, var(--c-seated) 12%, #23262d);
}
html[data-theme] .tpdlg .tp-info .tpi-p {
  background: color-mix(in srgb, var(--panel-solid, #fff) 70%, transparent);
}
html[data-theme="dark"] .tpdlg .tp-info .tpi-p {
  background: rgba(20, 22, 26, 0.55);
}
html[data-theme] .tpdlg .tp-info .tpi-h {
  color: var(--sub);
}
/* Toast actions: SHOW = vivid blue (go look), UNDO = neutral (take it back) — clearly different */
html[data-theme="dark"] .toast .tshow {
  color: #4f9dff !important;
}
html[data-theme="dark"] .toast .tundo {
  color: #e7e9ee !important;
}
html[data-theme="light"] .toast .tshow {
  color: #1d6bf0 !important;
}
html[data-theme="light"] .toast .tundo {
  color: #3b414c !important;
}
/* Requested (orange) tables: dashed outline — not final. Assigned (red): solid + lock */
.floor .fp-t.tk-held:not(.on) > circle,
.floor .fp-t.tk-held:not(.on) > rect,
.floor .fp-t.tk-held:not(.on) > ellipse,
.floor .fp-t.tk-held:not(.on) .fp-ol rect,
.floor .fp-t.tk-held:not(.on) .fp-ol circle,
.floor .fp-t.tk-held:not(.on) .fp-ol ellipse {
  stroke-dasharray: 11 7;
  stroke-width: 3;
}
.floor .fp-lock {
  pointer-events: none;
}
.floor .fp-lock circle {
  fill: var(--c-asg) !important;
  stroke: var(--coal, #1b1d22) !important;
  stroke-width: 3 !important;
  stroke-dasharray: none !important;
}
.floor .fp-lock rect,
.floor .fp-lock path {
  fill: none !important;
  stroke: #fff !important;
  stroke-width: 2.4 !important;
  stroke-dasharray: none !important;
}
/* Rows: lock button next to a requested table; "N requests" tag; impossible requests struck through */
/* the reserve lock: square, exactly as tall as the table box, hanging just to its right */
.row .meta .tblock {
  display: inline-grid;
  place-items: center;
  position: absolute;
  top: 0;
  bottom: 0;
  left: calc(100% + 6px);
  width: 30px;
  border-radius: 8px;
  border: 1px solid color-mix(in srgb, var(--c-asg) 45%, transparent);
  background: none;
  color: var(--c-asg);
  cursor: pointer;
}
.row .meta .tblock .i {
  width: 16px;
  height: 16px;
}
.row .meta .tblock:hover {
  background: color-mix(in srgb, var(--c-asg) 14%, transparent);
}
html[data-theme] .row .meta .tb.dead:not(.none) {
  text-decoration: line-through;
}
/* Floating card: Assign buttons; requests that can't happen are greyed */
.tp-info .tpi-asg {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  margin-left: 6px;
  padding: 3px 10px;
  border-radius: 999px;
  border: 0;
  background: var(--c-asg);
  color: #fff;
  font: 700 12px var(--sans);
  cursor: pointer;
}
.tp-info .tpi-asg .i {
  width: 13px;
  height: 13px;
}
/* the table box and its lock: the box fills at most the column, so it stays centred under the TABLE heading */
.row .meta .tbw {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  max-width: 100%;
}
/* phones: the lock sits inside the column, its right edge lined up with the party size above; when the
   table box is too wide for both, the lock drops to the next line (still on the right) */
@media (max-width: 760px) {
  .row .meta .tbw {
    flex-wrap: wrap;
    justify-content: flex-end;
    max-width: 140px; /* room for a table number and its lock; a wider name pushes the lock down */
  }
  .row .meta .tbw .tblock {
    position: static;
    height: 30px;
  }
}
/* Row pills: one size for every pill (status, Table Reserved, Late, Birthday, Walk-in, requests …) */
html[data-theme] .row .npill,
html[data-theme] .row .sub .badge {
  height: 22px !important;
  line-height: 20px !important;
  font-size: 10px !important;
  font-weight: 600 !important;
  letter-spacing: 0.09em !important;
  padding-top: 0 !important;
  padding-bottom: 0 !important;
  border-width: 1px !important;
  border-style: solid !important;
  box-sizing: border-box;
  display: inline-flex;
  align-items: center;
}
html[data-theme] .row .sub .badge.dnm {
  border-color: transparent !important;
  font-weight: 700 !important;
}
/* Back-to-top button: phones bottom right above the tab bar; iPad / desktop in the board corner */
.totop {
  position: fixed;
  right: 16px;
  bottom: calc(80px + env(safe-area-inset-bottom, 0px) + 16px);
  z-index: 40;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  border: 1px solid var(--line2, var(--line));
  background: color-mix(in srgb, var(--panel-solid, #fff) 92%, transparent);
  color: var(--text);
  display: grid;
  place-items: center;
  box-shadow: 0 8px 22px rgba(0, 0, 0, 0.35);
  backdrop-filter: blur(8px);
  cursor: pointer;
  animation: totopIn 0.2s ease-out;
}
html[data-theme="dark"] .totop {
  background: rgba(42, 45, 52, 0.92);
}
.totop[hidden] {
  display: none !important;
}
.totop .i {
  width: 22px;
  height: 22px;
  transform: rotate(90deg);
}
@keyframes totopIn {
  from {
    opacity: 0;
    transform: translateY(8px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}
/* iPad / desktop: placed in the board's bottom-right corner by script */
@media (min-width: 761px) {
  .totop {
    right: auto;
    bottom: auto;
  }
}

/* Chip holding a "Reserve for …" button: button sits 2px further right, same space above, below and right of it */
.tp-info .tpi-p:has(.tpi-asg) {
  padding: 8px 8px 8px 10px;
}
.tp-info .tpi-p .tpi-asg {
  margin-left: 8px;
}
/* "<Name> Left – Finish" in the conflict card: same blue as the board's Finish button */
.tp-info .tpi-asg.tpi-fin {
  background: #60a5fa;
  color: #0a0a0a;
}
/* Conflict card: a seated / reserved table can't be taken — message under its party */
.tp-info .tpi > .tpi-m {
  grid-column: 2;
  line-height: 1.45;
}
/* 15px more space above each table after the first */
.tp-info .tpi + .tpi {
  margin-top: 15px;
}
/* Table badge: "+N" other parties requesting the same table */
.row .meta .tb .tbn {
  margin-left: 5px;
  font-size: 0.8em;
  font-weight: 700;
  opacity: 0.85;
}
.row .meta .tb.hasreq {
  cursor: pointer;
}
/* "+N" popover: the other parties requesting a table */
.reqpop {
  position: fixed;
  z-index: 9000;
  min-width: 220px;
  max-width: min(400px, calc(100vw - 16px));
  padding: 10px 12px;
  border-radius: 12px;
  border: 1px solid var(--c-hold);
  background: var(--panel-solid, #fff);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.35);
  font-size: 13px;
}
html[data-theme="dark"] .reqpop {
  background: #23262d;
}
.reqpop .rp-h {
  margin-bottom: 6px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--c-hold);
}
.reqpop .rp-r {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 4px 0;
}
.reqpop .rp-r i {
  flex: none;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--c-hold);
}
.reqpop .rp-r.k-seated i {
  background: var(--c-seated);
}
.reqpop .rp-r.k-assigned i {
  background: var(--c-asg);
}
/* outline and heading match the tapped table's colour */
.reqpop.k-seated {
  border-color: var(--c-seated);
}
.reqpop.k-seated .rp-h {
  color: var(--c-seated);
}
.reqpop.k-assigned {
  border-color: var(--c-asg);
}
.reqpop.k-assigned .rp-h {
  color: var(--c-asg);
}
.reqpop.k-held {
  border-color: var(--c-hold);
}
.reqpop .rp-n {
  margin-top: 6px;
  padding-top: 8px;
  border-top: 1px solid var(--line);
  color: var(--sub);
  line-height: 1.4;
}
.reqpop .rp-r b {
  flex: none;
  max-width: 55%;
  font-weight: 600;
}
/* Long details ("8:00 PM · Reserved [from Airtable] · 8") always fit: the guest's name keeps its line and the
   details wrap inside the window (up to 400px wide, never wider than the screen) */
.reqpop .rp-r span {
  flex: 0 1 auto;
  min-width: 0;
  margin-left: auto;
  padding-left: 12px;
  color: var(--sub);
  text-align: right;
}
/* ---------------- Book a Table: One-Time / Recurring ---------------- */
.sh-head .ed-mode {
  align-self: center;
  margin-right: 12px;
}
.ed-mode button {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 36px;
  padding: 0 16px;
  font-size: 14px;
  font-weight: 600;
}
.ed-mode button .i {
  width: 16px;
  height: 16px;
}
.ed-mode button.on {
  background: var(--accent, #2f6fed);
  color: #fff;
}
/* The Repeats card sits full width under the other cards, only on the Recurring tab */
@media (min-width: 761px) {
  .layer.full .sh-body.ed.rec {
    grid-template-areas: "guest time" "dp time" "req seat" "rep rep" "warn warn";
    grid-template-rows: max-content minmax(max-content, 1fr) max-content max-content max-content;
  }
  .ed .ec-rep {
    grid-area: rep;
  }
}
.ec-rep[hidden],
.ed .remember.rp-hide {
  display: none !important;
}
/* Same space above each divider line as below it */
.ec-rep #rpBody > .erow:not(:last-child) {
  padding-bottom: 14px !important;
}
.ec-rep .seg {
  justify-self: start;
  width: max-content;
  max-width: 100%;
}
/* Frequency and Ends side by side on iPad / desktop */
@media (min-width: 761px) {
  .ec-rep #rpBody {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    column-gap: 40px;
  }
  .ec-rep #rpBody > .erow:not(.rp-f):not(.rp-e) {
    grid-column: 1 / -1;
  }
  .ec-rep #rpBody > .erow.rp-e {
    border-top: 0 !important;
    padding-top: 0 !important;
    margin-top: 0 !important;
  }
}
.ec-rep > header .rp-lbl {
  margin-left: auto;
  font-weight: 600;
  color: var(--accent, #2f6fed);
}
.ec-rep .rp-end {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 10px;
}
/* "After – 8 + times" | "On date": a divider between the two ways to end */
.ec-rep .rp-end .rp-sep {
  align-self: stretch;
  width: 1px;
  margin: 4px 8px;
  background: var(--line2);
}
.ec-rep .rp-end .stepnum.off,
.ec-rep .rp-end .rp-date.off {
  opacity: 0.5;
}
/* Last-date field (opens the calendar): sized and styled like the times counter */
.ec-rep .rp-date {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  height: 38px;
  padding: 0 14px;
  border-radius: 10px;
  border: 1px solid rgba(20, 20, 20, 0.13);
  background: #fff;
  color: var(--text);
  font-size: 15px;
  cursor: pointer;
}
html[data-theme="dark"] .ec-rep .rp-date {
  border-color: rgba(255, 255, 255, 0.1);
  background: #23272e;
}
.ec-rep .rp-date .i {
  width: 16px;
  height: 16px;
  color: var(--sub);
}
/* Series dates: on = will be booked; struck = left out; greyed = closed / passed; amber = no table that day */
/* Dates: an even grid, so every date button is the same size however many there are */
.ec-rep .rp-dates {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(132px, 1fr));
  gap: 10px;
}
.ec-rep .rp-dates .rpd {
  gap: 6px;
  width: 100%;
  min-width: 0;
  justify-content: center;
  white-space: nowrap;
}
.ec-rep .rp-dates .rpd.skip {
  text-decoration: line-through;
  opacity: 0.55;
}
.ec-rep .rp-dates .rpd.closed {
  text-decoration: line-through;
  opacity: 0.35;
  cursor: not-allowed;
}
.ec-rep .rp-dates .rpd.warn {
  border-color: var(--c-hold) !important;
}
.ec-rep .rp-dates .rpd .i {
  width: 14px;
  height: 14px;
  color: var(--c-hold);
}
.ec-rep .rp-note {
  margin-top: 10px;
  line-height: 1.45;
}
.ec-rep .rp-note b {
  color: var(--text);
}
.ec-rep .rp-warn {
  color: var(--c-hold);
}
@media (max-width: 760px) {
  .ec-rep .rp-end .rp-sep {
    display: none;
  }
  .sh-head:has(.ed-mode) {
    flex-wrap: wrap;
  }
  .sh-head .ed-mode {
    order: 3;
    flex-basis: 100%;
    margin: 10px 0 0;
  }
  .sh-head .ed-mode button {
    flex: 1;
    justify-content: center;
  }
}
/* Recurring: repeat icon next to the name; series line in the details */
.row .nm .gtx.rser {
  color: var(--accent, #2563eb);
}
.flag.rser {
  align-items: center;
}
.flag.rser > svg {
  color: var(--accent, #2563eb);
}
.flag.rser .btn {
  margin-left: auto;
  flex: none;
}
/* Launch cover: sits over the app until the first reservations are in, then fades out.
   The logo only fades in if loading takes a moment (a fast launch shows no logo flash). */
.splash.bootcover {
  position: fixed;
  inset: 0;
  z-index: 9999;
  background: var(--ink);
  transition: opacity 0.24s ease;
}
.splash.bootcover img {
  animation-delay: 0.6s;
}
.splash.bootcover.out {
  opacity: 0;
  pointer-events: none;
}
/* Closed Dates: Yearly / closing-time tags, edit row; day strip marks a day that closes early */
.bo-r .bo-tag {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  white-space: nowrap;
  padding: 1px 8px;
  border-radius: 999px;
  border: 1px solid var(--line2);
  font-size: 11.5px;
  color: var(--sub);
  vertical-align: 1px;
}
.bo-r .bo-tag .i {
  width: 12px;
  height: 12px;
}
.bo-r .bo-tag.hrs {
  color: var(--c-hold);
  border-color: color-mix(in srgb, var(--c-hold) 45%, transparent);
}
.bo-acts {
  display: inline-flex;
  gap: 2px;
}
/* Reason and its tags wrap instead of being cut off */
.bo-list .bo-row .bo-r {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 5px 8px;
  white-space: normal;
}
/* The dialog is narrow: date on its own line, then the reason / tags and the buttons */
.bo-list .bo-row:not(.bo-edit) {
  grid-template-columns: minmax(0, 1fr) auto;
  row-gap: 4px;
}
.bo-list .bo-row:not(.bo-edit) .bo-d {
  grid-column: 1 / -1;
}
/* The list scrolls inside its own box; each date sits on a darker full-width band */
.bo-list {
  flex: 1 1 auto;
  min-height: 0;
  max-height: min(460px, 52vh);
  overflow-y: auto;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
}
/* Each closed date is its own bubble inside an outlined box: date band on top, reason / tags / buttons below.
   Box padding = the gap between bubbles. */
.bo-list {
  gap: 10px;
  padding: 10px;
  border: 1px solid rgba(255, 255, 255, 0.12) !important; /* same line as the fields above */
  border-radius: 14px !important;
  background: none;
  overflow-x: hidden;
}
html[data-theme="light"] .bo-list {
  border-color: rgba(0, 0, 0, 0.16) !important;
}
.bo-list.sbar {
  padding-right: 0;
}
.bo-list .bo-row {
  flex: none;
  padding: 0 8px 6px 14px;
  border: 1px solid var(--line2, var(--line)) !important;
  border-radius: 12px;
  overflow: hidden;
  background: #23272e; /* = a field's gray ("All day") */
}
html[data-theme="light"] .bo-list .bo-row {
  background: #fff;
}
/* Reason / tags get even space above and below, so a wrapped second line (e.g. Yearly) isn't tight to the edge */
.bo-list .bo-row:not(.bo-edit) .bo-r {
  padding: 6px 0;
}
.bo-list .bo-row.bo-edit {
  padding-bottom: 12px;
  padding-right: 12px;
}
.bo-list .bo-row .bo-d {
  margin: 0 -8px 2px -14px;
  padding: 9px 12px 9px 14px;
  background: #32353c; /* = the gray behind a select's arrow */
}
html[data-theme="light"] .bo-list .bo-row .bo-d {
  background: #eff0f0;
}
/* Editing a date: date, then the reason, then hours + Cancel / Save */
.bo-row.bo-edit {
  grid-template-columns: minmax(0, 1fr) auto auto;
  row-gap: 10px;
}
.bo-row.bo-edit .bo-d,
.bo-row.bo-edit #boEReason {
  grid-column: 1 / -1;
}
.bo-row.bo-edit .input {
  height: 40px;
}
.day.closing .dc {
  color: var(--c-hold) !important;
}
@media (max-width: 760px) {
  .bo-row.bo-edit #boEHours {
    grid-column: 1 / -1;
  }
  /* Phones: Reason and Hours share a row (Add and Yearly move up to the third) */
  .bo-form .bo-reason {
    grid-column: 1 / 3;
  }
  .bo-form .btn {
    grid-row: 3;
    margin-top: 4px;
    height: 44px;
  }
  .bo-form .bo-yearly {
    grid-row: 3;
    gap: 6px;
    min-width: 0;
    padding: 0;
    font-size: 14px;
  }
  .bo-form .bo-yearly input {
    width: 20px;
    height: 20px;
    margin: 0;
    flex: none;
  }
}
@media (max-width: 380px) {
  .bo-form .bo-yearly {
    gap: 4px;
    font-size: 13px;
  }
  .bo-form .bo-yearly input {
    width: 18px;
    height: 18px;
  }
  #boWarn:empty {
    display: none;
  }
  /* Cancel and Save: natural width, on the right (as on desktop) */
  .bo-row.bo-edit [data-b="ecancel"] {
    grid-column: 2;
  }
}
/* Filter row with an extra filter at the end: same width, scrolls sideways */
#bkFilter.fscroll {
  overflow-x: auto;
  flex-wrap: nowrap;
  scrollbar-width: none;
}
#bkFilter.fscroll::-webkit-scrollbar {
  display: none;
}
#bkFilter.fscroll > button {
  flex: none;
}
/* Board: a little more room between the day strip and the stats / chart row */
#bookView .summary {
  margin-top: 5px;
}
/* Search: while the hint shows there's no clear (×) button, so the hint can use that space */
.search .input:placeholder-shown {
  padding-right: 12px !important;
}

/* View-only floor plan (Tables panel tiles): the other kinds of table fade back */
.floor .fp-t.fv-dim {
  opacity: 0.3;
}
.fvdlg .fv-seg {
  flex: none;
  margin-right: 8px;
}
.fvdlg .fvbody {
  padding-top: 14px;
}
.reqpop .rp-r[data-rid] {
  cursor: pointer;
}
/* Left – Finish sits on its own line under the guest, lined up with the name */
.reqpop .rp-r:has(.rp-act) {
  flex-wrap: wrap;
  row-gap: 0;
}
.reqpop .rp-act {
  flex-basis: 100%;
  padding: 3px 0 10px 16px;
}
.reqpop .rp-r:last-child .rp-act {
  padding-bottom: 2px;
}
.reqpop .rp-r .tpi-asg {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 3px 10px;
  border-radius: 999px;
  border: 0;
  background: #60a5fa;
  color: #0a0a0a;
  font: 700 12px var(--sans);
  white-space: nowrap;
  cursor: pointer;
}
.reqpop .rp-r .tpi-asg .i {
  width: 13px;
  height: 13px;
}
@media (max-width: 900px) {
  .fvdlg .sh-head {
    flex-wrap: wrap;
  }
  .fvdlg .fv-seg {
    order: 3;
    width: 100%;
    margin: 10px 0 0;
    overflow-x: auto;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
  }
  .fvdlg .fv-seg::-webkit-scrollbar {
    display: none;
  }
  .fvdlg .fv-seg button {
    flex: none;
  }
}

/* Phones: the main second-line pill (WALK-IN, RES time or TABLE RESERVED) moves up beside the status
   pill (to its left), the pair kept together on one line; elsewhere it stays on the second line */
.row .nm .stpair {
  display: contents;
}
.row .nm .nm-lead {
  display: none;
}
@media (max-width: 760px) {
  .row .nm .stpair {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    flex: none;
  }
  html[data-theme] .row .nm .nm-lead {
    border-radius: 999px;
  }
  html[data-theme] .row .sub .sub-lead {
    display: none !important;
  }
  /* Phones: every pill in a board row is the same size as WALK-IN / TABLE RESERVED, so they line up */
  html[data-theme] .row .nm .npill,
  html[data-theme] .row .nm .nm-lead,
  html[data-theme] .row .sub .badge:not(.sub-lead) {
    height: 20px !important;
    padding: 0 8px !important;
    font-size: 9px !important;
    font-weight: 700 !important;
    letter-spacing: 0.1em !important;
    line-height: 1 !important;
    box-sizing: border-box;
    display: inline-flex !important;
    align-items: center;
  }
  html[data-theme] .row .nm .npill .pmin {
    margin-right: -8px;
  }
}

/* Booking window: Requests quick buttons sit with equal space above (to the field) and below (to the line) */
@media (min-width: 761px) and (max-height: 860px) {
  html[data-theme] .ed .ec-req .quick {
    margin-top: -2px;
  }
}
@media (max-width: 760px) {
  html[data-theme] .ed .ec-req .quick {
    margin-top: 4px;
  }
}
/* Booking window: reminder beside the Requests label */
html[data-theme] .ed .el .el-note {
  margin-left: 4px;
  white-space: nowrap;
  color: var(--f-request);
}

/* Phones (under 768px): the reservation and Tables panels are sheets — a grab bar on top instead of
   the × (drag down to close), a shorter top, and no sideways rubber-banding */
.sh-grab {
  display: none;
}
@media (max-width: 767px) {
  .layer.sheet {
    padding: 0;
    align-items: flex-end;
  }
  .layer.calsheet .panel {
    width: 100%;
    max-height: calc(100% - var(--sa-t) - 32px);
    border-radius: 22px 22px 0 0;
    border-width: 1px 0 0;
  }
  /* floor-plan windows (table picker, view-only floor plan): a full sheet like the others */
  html[data-theme] .layer.sheet.tpdlg {
    padding: 0;
    align-items: flex-end;
  }
  html[data-theme] .layer.sheet.tpdlg .panel {
    width: 100% !important;
    height: calc(100% - var(--sa-t) - 32px) !important;
    max-height: none !important;
    border-radius: 22px 22px 0 0;
    border-width: 1px 0 0;
  }
  /* on short phones the month scrolls; Cancel / Done stay on screen */
  .layer.calsheet .panel > .cal {
    flex: 1 1 auto;
    min-height: 0;
    overflow-y: auto;
    overscroll-behavior: contain;
  }
  /* slide-up panels are only as tall as what's in them, up to 32px below the top of the screen */
  .layer.drawer .panel,
  .layer.full .panel {
    width: 100%;
    height: auto;
    max-height: calc(100% - var(--sa-t) - 32px);
    border-radius: 22px 22px 0 0;
    border-width: 1px 0 0;
    transform: translateY(40px);
  }
  .layer.drawer.in .panel,
  .layer.full.in .panel {
    transform: none;
  }
  /* the grab bar takes its share of the height, so the bottom bar stays fully on screen */
  .layer.drawer .panel > .dp {
    flex: 1 1 auto;
    min-height: 0;
    height: auto;
    display: flex;
    flex-direction: column;
  }
  /* the booking inside (its scrolling part and bottom bar) fits the panel, now that the panel fits its content */
  .layer.drawer .panel > .dp > .dp {
    flex: 1 1 auto;
    min-height: 0;
    height: auto;
  }
  .layer.sheet .sh-grab {
    display: flex;
    flex: none;
    justify-content: center;
    padding: 9px 0 7px;
    touch-action: none;
    cursor: grab;
  }
  .layer.sheet .sh-grab i {
    width: 40px;
    height: 5px;
    border-radius: 3px;
    background: color-mix(in srgb, var(--mute) 55%, transparent);
  }
  .layer.drawer [data-act="closeDrawer"],
  .layer.drawer .dp-bar:not(:has(.backlink)),
  .layer.full .sh-head [data-e="close"],
  .layer.full .sh-head [data-w="close"],
  .layer.calsheet .sh-head [data-k="close"],
  .layer.tpdlg .sh-head [data-x="close"] {
    display: none;
  }
  html[data-theme] .layer.sheet .sh-head {
    padding-top: 4px;
  }
  /* booking summary above Cancel / Book: wrapped lines sit closer together */
  .sumbar {
    row-gap: 2px;
    line-height: 1.35;
  }
  html[data-theme] .layer.drawer .dp-scroll {
    padding-top: 10px;
  }
  .layer.drawer .dp-bar {
    margin: 0 0 12px;
  }
  .layer .dp-scroll,
  .layer .sh-body {
    overflow-x: hidden;
    overscroll-behavior-x: none;
  }
  .dp .stepper {
    margin-left: -20px;
    margin-right: -20px;
  }
}

/* Search hits: matched text gets a light blue highlight (board, Guests, guest picker, audit log) */
mark.hl {
  background: color-mix(in srgb, #60a5fa 34%, transparent);
  color: inherit;
  border-radius: 3px;
  padding: 0 1px;
  margin: 0 -1px;
  box-decoration-break: clone;
  -webkit-box-decoration-break: clone;
}
html[data-theme="light"] mark.hl {
  background: color-mix(in srgb, #3b82f6 30%, transparent);
}

/* Table Reserved party not seated: Seat pulses (checked-in / waiting walk-ins until seated; others 10 min either side of the booking) */
@keyframes seatPulse {
  0% {
    box-shadow: 0 0 0 0 color-mix(in srgb, var(--c-seated) 65%, transparent);
  }
  70% {
    box-shadow: 0 0 0 12px color-mix(in srgb, var(--c-seated) 0%, transparent);
  }
  100% {
    box-shadow: 0 0 0 0 color-mix(in srgb, var(--c-seated) 0%, transparent);
  }
}
html[data-theme] .row .seatbtn.pulse {
  animation: seatPulse 1.6s ease-out infinite;
}
@media (prefers-reduced-motion: reduce) {
  html[data-theme] .row .seatbtn.pulse {
    animation: none;
    box-shadow: 0 0 0 4px color-mix(in srgb, var(--c-seated) 45%, transparent);
  }
}

/* Reserved table that's still taken (earlier party seated there, or double-booked): red, dashed, full strength */
.row .meta .tb.busy {
  border-style: dashed;
}

/* 761–991px always, and at any wider size where fitTop() finds the date and the tools colliding (.top-wrap):
   search, replies, Tables, Walk-in and Book drop to their own line under the date (search fills the space);
   at 761–991px the status filter row also scrolls sideways instead of running off the edge */
@media (min-width: 761px) {
  html[data-theme] .top.top-wrap {
    flex-wrap: wrap;
    row-gap: 12px;
  }
  html[data-theme] .top.top-wrap .tools {
    flex: 1 1 100%;
    justify-content: flex-start;
    margin-left: 0;
  }
  html[data-theme] .top.top-wrap .tools .search {
    flex: 1 1 auto !important;
    width: auto;
    max-width: none !important;
  }
}
@media (min-width: 761px) and (max-width: 991px) {
  html[data-theme] .top {
    flex-wrap: wrap;
    row-gap: 12px;
  }
  html[data-theme] .top .tools {
    flex: 1 1 100%;
    justify-content: flex-start;
    margin-left: 0;
  }
  html[data-theme] .top .tools .search {
    flex: 1 1 auto !important;
    width: auto;
    max-width: none !important;
  }
}
/* iPad / desktop: the status filter row never runs past the board's right edge — it ends level with the
   board and scrolls sideways when the filters don't fit (e.g. 1280px with the Tables panel open) */
@media (min-width: 761px) {
  html[data-theme] #bkFilter {
    max-width: 100%;
    min-width: 0;
    overflow-x: auto;
    overscroll-behavior-x: contain;
    scrollbar-width: none;
  }
  html[data-theme] #bkFilter::-webkit-scrollbar {
    display: none;
  }
  html[data-theme] #bkFilter > * {
    flex: none;
  }
}

/* iPad landscape (961–1376px): Today and the calendar button a little bigger (the arrows match their height);
   the seven day buttons give up the room and get a little narrower */
@media (min-width: 961px) and (max-width: 1376px) {
  html[data-theme] .striprow .dn-strip {
    gap: 6px;
  }
  html[data-theme] .striprow .dn-strip .btn {
    height: 50px;
  }
  html[data-theme] .striprow .dn-strip .btn:not(.icon) {
    padding: 0 20px;
    font-size: 16px;
  }
  html[data-theme] .striprow .dn-strip [data-act="cal"] {
    width: 50px;
  }
  html[data-theme] .striprow .dn-strip [data-act="cal"] svg {
    width: 21px;
    height: 21px;
  }
}

/* Board header: the Today tag never adds height to the date line, so the page doesn't shift down
   when you tap from another day onto today (equal negative margins keep it centred where it was) */
#bkDate .today-tag {
  margin-top: -24px;
  margin-bottom: -24px;
}

/* Phones up to 575px: the stats make room for an arrow on the right; tapping it drops down the
   All day / Lunch / Dinner filter above the search bar (no graph); tap again to close */
.sum-more {
  display: none;
}
@media (max-width: 575px) {
  html[data-theme] .summary {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) 36px !important;
    column-gap: 10px;
    row-gap: 0;
  }
  html[data-theme] .summary > .stats {
    grid-column: 1;
    min-width: 0;
  }
  html[data-theme] .top .title {
    position: relative;
    align-self: stretch;
  }
  html[data-theme] .top .title > #bkSync {
    position: absolute;
    right: 0;
    bottom: 0;
    margin: 0;
  }
  .summary > .sum-more {
    grid-column: 2;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    padding: 0;
    border-radius: 10px;
    border: 1px solid var(--line2);
    background: transparent;
    color: var(--mute);
    cursor: pointer;
  }
  .summary > .sum-more svg {
    width: 18px;
    height: 18px;
    transform: rotate(90deg);
    transition: transform 0.2s ease;
  }
  .summary.open > .sum-more {
    color: var(--text);
    border-color: var(--sel-bd, var(--line2));
  }
  .summary.open > .sum-more svg {
    transform: rotate(-90deg);
  }
  html[data-theme] .summary > .pacewrap {
    display: none !important;
  }
  html[data-theme] .summary.open > .pacewrap {
    display: block !important;
    grid-column: 1 / -1;
    margin-top: 14px;
    height: auto !important;
  }
  html[data-theme] .summary.open > .pacewrap .pace-svc {
    display: inline-flex !important;
    position: static;
  }
  html[data-theme] .summary.open > .pacewrap .pace-svc button {
    height: 34px !important;
    padding: 0 14px !important;
    font-size: 14px !important;
  }
  /* just the filter here — the covers-by-time graph stays hidden on phones */
  html[data-theme] .summary > .pacewrap .pace {
    display: none !important;
  }
  html[data-theme] .bar .bar-svc {
    display: none !important;
  }
  /* the status filters (All / Booked / Confirmed …) sit in the drop-down too, on the row under All day / Lunch / Dinner */
  html[data-theme] .summary > .pacewrap > #bkFilter {
    display: flex;
    width: 100%;
    max-width: 100%;
    margin-top: 10px;
    overflow-x: auto;
    overscroll-behavior-x: contain;
    scrollbar-width: none;
  }
  html[data-theme] .summary > .pacewrap > #bkFilter::-webkit-scrollbar {
    display: none;
  }
  html[data-theme] .summary > .pacewrap > #bkFilter > * {
    flex: none;
  }
  /* a filter other than All / All day is on while the drop-down is closed: blue arrow with a dot */
  .summary > .sum-more.active {
    position: relative;
    color: var(--text);
    border-color: color-mix(in srgb, #60a5fa 65%, transparent);
  }
  .summary > .sum-more.active::after {
    content: "";
    position: absolute;
    top: -3px;
    right: -3px;
    width: 9px;
    height: 9px;
    border-radius: 50%;
    background: #3b82f6;
    box-shadow: 0 0 0 2px var(--bg);
  }
  /* search moves out of the top row (it ran off the edge) into its own full-width row under the stats */
  html[data-theme] .top .tools .search {
    display: none !important;
  }
  html[data-theme] .bar .msearch {
    display: block !important;
  }
  /* Phones (575px and under): date, buttons row and day strip pinned at the top of the board while it scrolls */
  html[data-theme] #bookView > .top {
    position: sticky;
    top: 0;
    z-index: 30;
    background: var(--ink);
  }
  html[data-theme] #bookView #bkStrip {
    position: sticky;
    top: var(--bk-toph, 130px);
    z-index: 29;
    padding-bottom: 15px;
    background: var(--ink);
    box-shadow: 0 10px 12px -10px rgba(0, 0, 0, 0.55);
  }
  html[data-theme="light"] #bookView #bkStrip {
    box-shadow: 0 10px 12px -10px rgba(0, 0, 0, 0.18);
  }
  html[data-theme] #bookView .grp {
    top: var(--bk-headh, 0px);
  }
}

/* Phones: nothing slides sideways — the page and every view stay put; the few rows that scroll sideways on
   purpose (day strip, filters, floor plan) don't drag the page with them */
@media (max-width: 760px) {
  html,
  body {
    overscroll-behavior-x: none;
  }
  html[data-theme] .view {
    overflow-x: hidden;
    overscroll-behavior-x: none;
  }
  #bkFilter,
  .fpwrap.fp-scroll {
    overscroll-behavior-x: contain;
  }
}

/* iPad and desktop (761px+): All day / Lunch / Dinner sits at the right of the graph, level with the right
   edge of the day strip above, and the "Covers by half hour" title moves to the left */
@media (min-width: 761px) {
  .pacewrap .pace-svc {
    left: auto;
    right: 0;
  }
  html[data-theme] .pacewrap .pace .lbl {
    left: 0;
    right: auto;
  }
  /* the title always shows here, in the space left of All day / Lunch / Dinner (shrinks to fit) */
  html[data-theme] .summary .pacewrap .pace .lbl {
    display: block !important;
    max-width: calc(100% - 222px);
    white-space: normal;
  }
  /* iPad: smaller title; when the graph shows one service (1100px and under) its name sits on a second line */
  @container (max-width: 470px) {
    html[data-theme] .summary .pacewrap .pace .lbl {
      top: 1px !important;
      font-size: 9px !important;
      letter-spacing: 0.1em !important;
      line-height: 12px !important;
    }
  }
}
@media (min-width: 761px) and (max-width: 1100px) {
  @container (max-width: 470px) {
    html[data-theme] .summary .pace .lbl .lbl-svc {
      display: block;
    }
    .pace .lbl .lbl-dot {
      display: none;
    }
  }
}
@media (min-width: 761px) {
  /* iPad portrait: "Covers by / half hour" on two lines; the times under the bars show the service */
  @container (max-width: 330px) {
    html[data-theme] .summary .pacewrap .pace .lbl {
      font-size: 8.5px !important;
      letter-spacing: 0.08em !important;
      line-height: 11px !important;
      white-space: nowrap;
    }
    html[data-theme] .summary .pace .lbl .lbl-svc {
      display: none;
    }
    .pace .lbl .lbl-2 {
      display: block;
    }
  }
  /* narrowest iPad portrait (768px): slimmer service buttons leave the title room */
  @container (max-width: 270px) {
    html[data-theme] .pacewrap .pace-svc button {
      padding: 0 6px !important;
    }
    html[data-theme] .summary .pacewrap .pace .lbl {
      max-width: calc(100% - 204px);
    }
  }
}

/* Board rows: 4px less padding top and bottom (14 → 10 on iPad / desktop, 13 → 9 on phones) */
html[data-theme] #bkList .row {
  padding-top: 10px;
  padding-bottom: 10px;
}
@media (max-width: 760px) {
  html[data-theme] #bkList .row {
    padding-top: 9px;
    padding-bottom: 9px;
  }
}

/* Small iPhones (400px and under): the buttons row fits without squeezing, and the Demo data / sync note
   beside the date is a touch smaller so it clears the Today tag */
@media (max-width: 400px) {
  html[data-theme] #bookView .top .tools,
  html[data-theme] #bookView .top .tools .datenav {
    gap: 6px !important;
    column-gap: 6px !important;
  }
  html[data-theme] #bookView .top .tools .datenav {
    flex: 1 1 auto;
    min-width: 0;
  }
  html[data-theme] .top .tools .btn.icon {
    width: 38px;
    min-width: 38px;
    flex: none;
  }
  html[data-theme] .top .tools .datenav [data-act="today"] {
    padding: 0 12px;
    flex: 1 1 auto;
    min-width: 0;
  }
  html[data-theme] .top .title > #bkSync {
    font-size: 11px;
  }
  html[data-theme] #bookView .top .tools > .btn {
    width: 38px !important;
    min-width: 38px !important;
    flex: none;
    padding: 0 !important;
  }
}
/* phones: the sync note beside the date drops its wordy part ("Airtable · ", " — retrying");
   if it still doesn't fit it shows only the dot */
.top .title > #bkSync .sy-x {
  display: none;
}
#bkSync.dotonly .sy-t {
  display: none;
}

/* Touch devices (iPad app): show / hide the left sidebar in one step. Animating the page's column widths
   re-lays out the whole board on every frame, which the iPad's web view draws with a visible flicker. */
@media (min-width: 761px) and (hover: none), (min-width: 761px) and (pointer: coarse) {
  .app {
    transition: none !important;
  }
}
/* finished / no-show / cancelled rows: the table badge goes grey like the status pill */
html[data-theme] .row.s-finished .meta .tb:not(.none),
html[data-theme] .row.s-noshow .meta .tb:not(.none),
html[data-theme] .row.s-cancelled .meta .tb:not(.none) {
  color: var(--c-finished) !important;
  background: color-mix(in srgb, var(--c-finished) 10%, transparent) !important;
  border-color: color-mix(in srgb, var(--c-finished) 50%, transparent) !important;
}
html[data-theme="light"] .row.s-finished .meta .tb:not(.none),
html[data-theme="light"] .row.s-noshow .meta .tb:not(.none),
html[data-theme="light"] .row.s-cancelled .meta .tb:not(.none) {
  border-color: transparent !important;
}
/* Light mode: requested tables use the legend's gold, so they don't read as the red "reserved" */
html[data-theme="light"] .floor,
html[data-theme="light"] .reqpop.k-held,
html[data-theme="light"] .tp-info .tpi-p.k-held {
  --c-hold: #f59e0b;
}
/* No Show button in the guest panel: red, styled like Confirm / Contacted */
html[data-theme] .btn.stbtn.s-ns {
  --c: #f05252;
}
html[data-theme="light"] .btn.stbtn.s-ns {
  --pill: #ffaba6;
}
/* Light mode guest-panel actions: Check In is a filled pill like Confirm / Contacted / No Show,
   and every coloured action darkens on hover (dark mode brightens its tint the same way) */
html[data-theme="light"] .btn.cibtn,
html[data-theme="light"] .btn.cibtn:hover {
  background: #a6e3d9 !important;
  border-color: transparent !important;
  color: #232429 !important;
  font-weight: 600;
}
html[data-theme="light"] .btn.cibtn:hover,
html[data-theme="light"] .btn.stbtn:hover {
  filter: brightness(0.92);
}
/* Guest panel footer: Edit, Cancel and Delete get a hover in both themes, like the action buttons */
html[data-theme] .dp .dp-foot .btn.ghost:hover {
  background-color: color-mix(in srgb, var(--text) 8%, var(--panel)) !important;
}
html[data-theme="light"] .dp .dp-foot .btn.quiet:hover {
  background: color-mix(in srgb, #000 6%, transparent) !important;
  color: var(--text);
}
html[data-theme="light"] .dp .dp-foot .btn.danger:hover {
  background: color-mix(in srgb, #dc2626 10%, #fff) !important;
}
/* Empty-state pill headings in title case ("Nothing In This View", "Select A Reservation") */
h3.nonepill,
h3.closedpill {
  text-transform: capitalize;
}
/* Guest panel: keep room for the scrollbar from the start. Without it, the panel's content jumped ~10px
   narrower the moment the guest's history loaded and the panel became long enough to scroll */
.dp-scroll {
  scrollbar-gutter: stable;
}
/* the stars / birthday line under a guest's name is always the same height, so phone and email sit
   at the same place for every guest who has one */
.dp-id .idtags {
  min-height: 22px;
}
/* Finish: a blue tint and outline appear on the row. The tint glides away right to left and the last sliver
   snaps shut at the left edge; the outline holds the whole time, then pops away with the row's left bar —
   the party's visit is over. A redraw mid-animation picks up where it left off (--jfd) */
@keyframes finWipe {
  0%,
  16% {
    clip-path: inset(0 0 0 0 round 14px);
    animation-timing-function: cubic-bezier(0.45, 0, 0.3, 1);
  }
  78% {
    clip-path: inset(0 90% 0 0 round 14px);
    animation-timing-function: cubic-bezier(0.6, 0, 1, 0.6);
  }
  84%,
  100% {
    clip-path: inset(0 100% 0 0 round 14px);
  }
}
@keyframes finSnap {
  0%,
  80% {
    transform: none;
  }
  86% {
    transform: scaleY(1.35);
    background: #60a5fa;
    opacity: 1;
  }
  100% {
    transform: none;
  }
}
html[data-theme] .row.just-fin:before {
  animation: finSnap 1.7s ease-out 1;
  animation-delay: var(--jfd, 0ms);
}
html[data-theme] .row .finwipe,
html[data-theme] .row .finring {
  position: absolute;
  inset: 0;
  border-radius: inherit;
  pointer-events: none;
}
html[data-theme] .row .finring {
  box-shadow: inset 0 0 0 2px color-mix(in srgb, #60a5fa 90%, transparent);
  animation: finRing 1.7s ease-out 1 both;
  animation-delay: var(--jfd, 0ms);
}
@keyframes finRing {
  0%,
  80% {
    opacity: 1;
    transform: none;
  }
  86% {
    opacity: 1;
    transform: scale(1.012);
  }
  96% {
    opacity: 0;
    transform: scale(1.02);
  }
  100% {
    opacity: 0;
    transform: none;
  }
}
html[data-theme] .row .finwipe {
  background: color-mix(in srgb, #60a5fa 16%, transparent);
  animation: finWipe 1.7s linear 1 both;
  will-change: clip-path;
  animation-delay: var(--jfd, 0ms);
}
/* "Just seated" tag on a row's second line: same footprint as the plain text it replaces, so the row
   keeps its height when the tag goes away (Finish made the row 4px shorter and the board jumped) */
html[data-theme] #bkList .row .badge.justseat {
  margin-top: -2px;
  margin-bottom: -2px;
}
/* the row's second line already spaces its items 10px apart: no extra margin, so "Just seated" sits the same
   distance from what follows as "Table Reserved" does */
html[data-theme] #bkList .row .sub .badge.justseat {
  margin-right: 0;
}
/* Toast stack: every toast the same distance apart (8px), all centred on one line (placeToasts sets
   the centre); the stack is 560px wide so a name + table message stays on one line */
#toasts .toast {
  margin: 0 !important;
  flex: none;
}
/* iPad (touch, 761px+): the board and the right panel only scroll up and down — no sideways drift or
   rubber-banding, and the content doesn't float under a diagonal drag */
@media (min-width: 761px) and (hover: none), (min-width: 761px) and (pointer: coarse) {
  #bkList,
  aside#detail .dp-scroll {
    overflow-x: hidden;
    overscroll-behavior-x: none;
    touch-action: pan-y;
  }
}
/* Phones: a banner stuck under the header squares its top corners (markStuck) */
@media (max-width: 575px) {
  html[data-theme] #bkList .grp.stuck {
    border-top-left-radius: 0 !important;
    border-top-right-radius: 0 !important;
  }
  /* iPhone (575px and under): windows open without a flash. The iPhone's web view can flash while it fades
     in a blurred backdrop (opacity animation on a backdrop-filter layer), so the scrim stays fully opaque and
     only its tint and blur grow; sheets slide up from the bottom edge instead of fading in */
  html[data-theme] .layer .scrim {
    opacity: 1;
    background-color: rgba(0, 0, 0, 0);
    -webkit-backdrop-filter: blur(0px);
    backdrop-filter: blur(0px);
    transition:
      background-color 0.24s,
      -webkit-backdrop-filter 0.24s,
      backdrop-filter 0.24s;
  }
  html[data-theme] .layer.in .scrim {
    background-color: rgba(0, 0, 0, 0.62);
    -webkit-backdrop-filter: blur(6px);
    backdrop-filter: blur(6px);
  }
  html[data-theme="light"] .layer.in .scrim {
    background-color: rgba(40, 32, 20, 0.38);
  }
  html[data-theme] .layer.sheet .panel {
    opacity: 1;
    transform: translateY(100%);
    transition: transform 0.24s var(--ease);
    will-change: transform;
  }
  html[data-theme] .layer.sheet.in .panel {
    transform: none;
  }
  /* iPhone (575px and under): a row whose second line wraps onto a "Table Reserved" pill (checked-in
     parties on the waitlist) gets a little more room underneath */
  html[data-theme] #bkList .row:has(.sub .badge.dnm:not(.sub-lead)) {
    padding-bottom: 14px;
  }
}
/* iPhone (575px and under): Now sits to the right of the search box — gray while the current time slot
   is on screen, blue once the board is scrolled away from it (same as the board header's Now) */
.bar .mnow {
  display: none;
}
@media (max-width: 575px) {
  html[data-theme] .bar .msearch {
    width: auto;
    flex: 1 1 0;
    min-width: 0;
  }
  html[data-theme] .bar .mnow {
    display: inline-flex;
    flex: none;
    align-items: center;
    gap: 6px;
    height: 44px;
    padding: 0 14px;
    border-radius: 12px;
    border: 1px solid var(--line2);
    background: color-mix(in srgb, var(--text) 5%, transparent);
    color: var(--mute);
    font: 600 12px/1 var(--sans);
    letter-spacing: 0.12em;
    text-transform: uppercase;
    cursor: pointer;
  }
  /* the spacer would split the row with the search box; Now sits flush right instead */
  html[data-theme] .bar > .sp {
    display: none;
  }
  html[data-theme] .bar .mnow svg {
    width: 15px;
    height: 15px;
  }
  html[data-theme] .bar .mnow:not(.away) {
    opacity: 0.55;
  }
  html[data-theme] .bar .mnow.away {
    color: #93c5fd;
    border-color: color-mix(in srgb, #60a5fa 65%, transparent);
    background: color-mix(in srgb, #60a5fa 14%, transparent);
  }
  html[data-theme="light"] .bar .mnow.away {
    color: #1d4ed8;
    border-color: color-mix(in srgb, #2563eb 55%, transparent);
    background: color-mix(in srgb, #3b82f6 10%, transparent);
  }
}
/* Pop-up windows that sit in the middle of the screen (not a bottom sheet or the side drawer): their
   footer isn't at the screen's edge, so it doesn't need the home-bar allowance — buttons get the same
   space above and below */
html[data-theme] .layer:not(.sheet):not(.drawer) {
  --sa-b: 0px;
}
/* iPad / desktop (768px+): Book a Table, Party at the Door, the calendar and the floor plan are centred
   windows too (they're only bottom sheets on phones); the side drawer still reaches the bottom edge */
@media (min-width: 768px) {
  html[data-theme] .layer.sheet:not(.drawer) {
    --sa-b: 0px;
  }
}
/* "Table Conflict": bright red, white text, in both themes */
html[data-theme] .btn.actbtn.a-resolve {
  --a: #ef4444;
  --on-a: #fff;
  color: #fff;
}
html[data-theme] .btn.actbtn.a-resolve svg {
  color: #fff;
}
html[data-theme] .btn.actbtn.a-resolve:hover {
  background: #dc2626;
  border-color: #dc2626;
}
/* The board never scrolls sideways (iPad / desktop, where the board is its own scroller): nothing inside a
   row — like the Finish outline's pop — can push it wider than the board */
@media (min-width: 761px) {
  html[data-theme] #bkList {
    overflow-x: hidden;
  }
}
/* iPhone (575px and under): the pills beside a name (Table Reserved / Res time + status) wrap onto a
   second line when they don't fit, instead of running under the table column */
@media (max-width: 575px) {
  html[data-theme] #bkList .row .stpair {
    flex-wrap: wrap;
    max-width: 100%;
    row-gap: 6px;
  }
  html[data-theme] #bkList .row .nm {
    min-width: 0;
    max-width: 100%;
  }
}
/* A seated party's table stays green (same as while "Just seated") until they're finished */
html[data-theme] .row.s-seated .meta .tb:not(.none) {
  background: #22c55e !important;
  color: #052e16 !important;
  border-color: transparent !important;
}
/* Table Conflict pill on the row: phones only (iPad / desktop show the red Table Conflict button instead) */
#bkList .row .sub .badge.conflict {
  display: none;
}
@media (max-width: 760px) {
  html[data-theme] #bkList .row .sub .badge.conflict {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    background: #b91c1c;
    color: #fff;
    border-color: transparent;
  }
  html[data-theme] #bkList .row .sub .badge.conflict svg {
    width: 12px;
    height: 12px;
    color: #fff;
  }
}
/* Tables panel: table colours match the board — green outline = seated now, red = reserved, orange = requested */
html[data-theme] .tboard .tno.k-seat {
  color: #4ade80 !important;
  background: color-mix(in srgb, #4ade80 10%, transparent) !important;
  border-color: color-mix(in srgb, #4ade80 55%, transparent) !important;
}
html[data-theme] .tboard .tno.k-res {
  color: var(--c-asg) !important;
  background: color-mix(in srgb, var(--c-asg) 12%, transparent) !important;
  border-color: color-mix(in srgb, var(--c-asg) 65%, transparent) !important;
}
html[data-theme="light"] .tboard .tno.k-seat {
  color: #15803d !important;
  background: color-mix(in srgb, #22c55e 10%, #fff) !important;
  border-color: #22c55e !important;
}
html[data-theme="light"] .tboard .tno.k-res {
  color: var(--c-asg) !important;
  background: color-mix(in srgb, var(--c-asg) 16%, #fff) !important;
  border-color: color-mix(in srgb, var(--c-asg) 65%, transparent) !important;
}
/* Tables panel, Coming Up by Table: a party whose table won't be free for them — dotted red outline and a
   red warning icon in place of the status dot (the board shows the same party as a Table Conflict) */
html[data-theme] .tslot.conflict {
  background: color-mix(in srgb, #ef4444 8%, transparent);
  box-shadow: none;
  outline: 1px dashed color-mix(in srgb, #ef4444 75%, transparent);
  outline-offset: -1px;
}
.tslot .cf {
  display: inline-flex;
  width: 12px;
  height: 12px;
  margin-left: -1px;
  color: #ef4444;
}
.tslot .cf svg {
  width: 12px;
  height: 12px;
}
/* Board table column: a table this party can't have (Table Conflict) is red — full strength, dashed outline;
   a lost request is also crossed out. Red only ever means a conflict now (reserved tables are blue) */
html[data-theme] .row .meta .tb.busy:not(.none),
html[data-theme] .row .meta .tb.dead:not(.none) {
  --f-table: #ef4444;
  color: #ef4444 !important;
  background: color-mix(in srgb, #ef4444 10%, transparent) !important;
  border-color: #ef4444 !important;
  border-style: dashed !important;
}
html[data-theme="light"] .row .meta .tb.busy:not(.none),
html[data-theme="light"] .row .meta .tb.dead:not(.none) {
  color: #b91c1c !important;
  background: #fee2e2 !important;
}
/* Tables panel header: "Status Now" (with a down arrow to its right, in the divider-line grey) sits over the table tiles, and the
   section title lines up with the time column (tile 58px + row gap 12px = 70px, then the slot's 10px padding) */
.sec .thead {
  display: grid;
  grid-template-columns: 70px minmax(0, 1fr);
  column-gap: 10px;
  align-items: start;
  margin: 0 0 10px;
}
.sec .thead h4 {
  margin: 0;
  line-height: 13px;
}
.thead .thd {
  font-family: var(--sans);
  display: flex;
  align-items: flex-start;
  gap: 9px;
  font-size: 10.5px;
  font-weight: 600;
  line-height: 13px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--mute);
  white-space: nowrap;
}
/* slim down arrow right of the two-line label (9px gap), as tall as it, pointing at the tiles below; same grey as the divider line */
.thead .thd svg {
  flex: none;
  width: 8px;
  height: 26px;
  fill: none;
  stroke: var(--line);
  stroke-width: 1.6;
  stroke-linecap: round;
  stroke-linejoin: round;
}
/* Seat: the green is already so light that the shared "lighten" hover barely showed — deepen it instead,
   like Table Conflict does (board and guest panel, both themes) */
html[data-theme] .btn.actbtn.a-seat:not(:disabled):hover {
  background: #22c55e;
  border-color: #22c55e;
}
/* Red (conflict) table badge on the board: tap for who has the table (iPad has no hover) */
.row .meta .tb.dead,
.row .meta .tb.busy {
  cursor: pointer;
}
.reqpop.k-conflict {
  border-color: #ef4444;
}
.reqpop.k-conflict .rp-h {
  color: #ef4444;
}
/* name on one line, the details on the line under it (lined up with the name) */
.reqpop.k-conflict .rp-r {
  flex-wrap: wrap;
  row-gap: 2px;
}
.reqpop.k-conflict .rp-r b {
  max-width: none;
  white-space: nowrap;
}
.reqpop.k-conflict .rp-r span {
  flex-basis: calc(100% - 16px);
  margin-left: 16px;
  padding-left: 0;
  white-space: normal;
}
.row .meta .tb.asg[data-act] {
  cursor: pointer;
}
/* Info only (a request on a table reserved for someone else): blue, like a reserved table */
html[data-theme] .tpdlg .tp-info.ok.res {
  border-color: var(--c-asg);
  background: color-mix(in srgb, var(--c-asg) 10%, var(--panel-solid, #fff));
  box-shadow:
    0 0 0 4px color-mix(in srgb, var(--c-asg) 14%, transparent),
    0 18px 40px rgba(0, 0, 0, 0.35);
}
html[data-theme="dark"] .tpdlg .tp-info.ok.res {
  background: color-mix(in srgb, var(--c-asg) 12%, #23262d);
}
/* Board's calendar (pick a date) button: solid blue with a white icon, like the Book button */
html[data-theme][data-theme] body .btn[data-act="cal"] {
  background: #2563eb !important;
  border: 1px solid #60a5fa !important;
  box-shadow: none !important;
  color: #fff !important;
}
html[data-theme="light"][data-theme] body .btn[data-act="cal"] {
  border-color: #2563eb !important;
}
html[data-theme][data-theme] body .btn[data-act="cal"] svg {
  color: #fff !important;
  stroke: currentColor;
}
/* hover: like Book — a touch brighter in dark mode, a deeper blue in light mode */
html[data-theme][data-theme] body .btn[data-act="cal"]:hover {
  filter: brightness(1.12);
}
html[data-theme="light"][data-theme] body .btn[data-act="cal"]:hover {
  background: #1d4ed8 !important;
  filter: none;
}
/* Board's Today button: same outlined-tint look, in the Booked blue (the stat line's booked count) */
html[data-theme="light"] {
  --c-today: #2563eb; /* the light-mode Guests Expected blue */
}
html[data-theme="dark"] {
  --c-today: var(--c-booked);
}
html[data-theme][data-theme] body .btn[data-act="today"] {
  --c: var(--c-today);
  background: color-mix(in srgb, var(--c) 10%, transparent) !important;
  box-shadow: inset 0 0 0 1.5px var(--c) !important;
  border-color: transparent !important;
  color: var(--c) !important;
}
html[data-theme][data-theme] body .btn[data-act="today"]:hover {
  background: color-mix(in srgb, var(--c) 18%, transparent) !important;
}
/* "Different Time" pill: the custom time as a chip beside the field (blue with a check while selected) */
.othertime .chip.tpill {
  flex: none;
  width: auto !important;
  height: 38px;
  min-width: 0;
  padding: 0 14px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-weight: 600;
  font-size: 14px;
  opacity: 1;
}
.othertime .chip.tpill small {
  font-size: 0.72em;
  font-weight: 600;
  letter-spacing: 0.04em;
  margin-left: 1px;
}
.othertime .chip.tpill svg {
  width: 15px;
  height: 15px;
  flex: none;
}
/* Light mode: the selected table is dark grey with a white number (blue outline and glow stay) */
html[data-theme="light"] .floor .fp-t.on circle,
html[data-theme="light"] .floor .fp-t.on rect:not(.fp-band):not(.fp-seg),
html[data-theme="light"] .floor .fp-bart.on ellipse {
  fill: #3a3f47;
}
html[data-theme="light"] .floor .fp-t.on .fp-n,
html[data-theme="light"] .floor .fp-bart.on .fp-barl {
  fill: #ffffff;
}
html[data-theme="light"] .tp-legend .tk-on {
  background: #3a3f47;
}
/* Day strip (Mon–Sun): hover — other days lift a little; the selected day brightens like Book */
@media (hover: hover) {
  html[data-theme][data-theme] .day:not(.on):hover {
    background: color-mix(in srgb, var(--text) 7%, var(--coal)) !important;
    border-color: color-mix(in srgb, var(--text) 28%, transparent) !important;
  }
  html[data-theme="light"][data-theme] .day:not(.on):hover {
    background: #f1f3f6 !important;
    border-color: rgba(0, 0, 0, 0.28) !important;
  }
  html[data-theme][data-theme] .day.on:hover {
    filter: brightness(1.12);
  }
  html[data-theme="light"][data-theme] .day.on:hover {
    filter: none;
    background: #1d4ed8 !important;
  }
  /* Board header: previous / next day, Guest Replies, Tables and Walk-In buttons lift on hover, like the day strip */
  html[data-theme][data-theme] body .btn[data-act="day"]:hover,
  html[data-theme][data-theme] body .btn[data-act="replies"]:hover,
  html[data-theme][data-theme] body .btn[data-act="tables"]:hover,
  html[data-theme][data-theme] body .btn[data-act="walkin"]:hover {
    background: color-mix(in srgb, var(--text) 7%, var(--coal)) !important;
    border-color: color-mix(in srgb, var(--text) 28%, transparent) !important;
  }
  html[data-theme="light"][data-theme] body .btn[data-act="day"]:hover,
  html[data-theme="light"][data-theme] body .btn[data-act="replies"]:hover,
  html[data-theme="light"][data-theme] body .btn[data-act="tables"]:hover,
  html[data-theme="light"][data-theme] body .btn[data-act="walkin"]:hover {
    background: #f1f3f6 !important;
    border-color: rgba(0, 0, 0, 0.28) !important;
  }
}
/* Board's Party and Table column headings: buttons that open the party-size / table filters */
.colhead .ch-pty,
.colhead .ch-tbl {
  appearance: none;
  -webkit-appearance: none;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  box-sizing: border-box;
  height: 26px; /* same box as the Finished / Now buttons in this row (text keeps its own size) */
  margin: -4px 0;
  padding: 0 7px 0 10px; /* the arrow has blank room on its right: this keeps the space even on both sides */
  border: 1px solid transparent;
  border-radius: 8px;
  background: none;
  font: inherit;
  color: inherit;
  letter-spacing: inherit;
  text-transform: inherit;
  cursor: pointer;
}
.colhead .ch-pty {
  white-space: nowrap;
}
.colhead .ch-pty .i,
.colhead .ch-tbl .i {
  width: 13px;
  height: 13px;
  opacity: 0.7;
}
.colhead .ch-pty .tfd,
.colhead .ch-tbl .tfd {
  display: none;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--tf-c);
}
@media (hover: hover) {
  .colhead .ch-pty:hover,
  .colhead .ch-tbl:hover {
    background: color-mix(in srgb, var(--text) 8%, transparent);
  }
}
.colhead .ch-pty.on,
.colhead .ch-tbl.on {
  color: var(--tf-c);
  background: color-mix(in srgb, var(--tf-c) 14%, transparent);
  border-color: color-mix(in srgb, var(--tf-c) 60%, transparent);
}
.colhead .ch-pty.on .tfd,
.colhead .ch-tbl.on .tfd {
  display: inline-block;
}
.ch-tbl.f-tconflict,
.tfpop .f-tconflict,
.seg button.tone.f-tconflict {
  --tf-c: #ef4444;
}
.ch-tbl.f-treq,
.tfpop .f-treq,
.seg button.tone.f-treq {
  --tf-c: var(--c-hold);
}
.ch-tbl.f-tres,
.tfpop .f-tres,
.seg button.tone.f-tres {
  --tf-c: var(--c-asg);
}
.tfpop .f-all {
  --tf-c: var(--mute);
}
/* the menu */
.reqpop.tfpop {
  min-width: 200px;
  padding: 8px;
  border-color: var(--line2);
}
.reqpop.tfpop .rp-h {
  padding: 2px 6px 4px;
}
.tfpop .tf-i {
  appearance: none;
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  padding: 9px 8px;
  border: 0;
  border-radius: 8px;
  background: none;
  font: inherit;
  font-size: 14px;
  color: var(--text);
  text-align: left;
  cursor: pointer;
}
.tfpop .tf-i i {
  flex: none;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--tf-c);
}
.tfpop .f-all i {
  background: none;
  box-shadow: inset 0 0 0 1.5px var(--mute);
}
.tfpop .tf-i span {
  flex: 1;
}
.tfpop .tf-i .n {
  color: var(--mute);
  font-weight: 600;
  font-variant-numeric: tabular-nums;
}
@media (hover: hover) {
  .tfpop .tf-i:hover {
    background: color-mix(in srgb, var(--text) 7%, transparent);
  }
}
.tfpop .tf-i.on {
  background: color-mix(in srgb, var(--tf-c) 14%, transparent);
  color: var(--tf-c);
  font-weight: 600;
}
.tfpop .tf-i.on .n {
  color: inherit;
}
/* active chip in the filter row: same look as "Tables to Confirm", in the filter's colour */
html[data-theme][data-theme] body .seg button.tone.f-tconflict.on,
html[data-theme][data-theme] body .seg button.tone.f-treq.on,
html[data-theme][data-theme] body .seg button.tone.f-tres.on {
  --c: var(--tf-c);
  background: color-mix(in srgb, var(--c) 12%, transparent) !important;
  box-shadow: inset 0 0 0 1.5px var(--c) !important;
  color: var(--c) !important;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-weight: 600;
}
.seg button.f-tconflict .i,
.seg button.f-treq .i,
.seg button.f-tres .i {
  width: 15px;
  height: 15px;
}
.seg button.f-tconflict .n,
.seg button.f-treq .n,
.seg button.f-tres .n {
  color: inherit !important;
  opacity: 0.85;
}
.seg button.f-tconflict .fx,
.seg button.f-treq .fx,
.seg button.f-tres .fx {
  display: inline-grid;
  place-items: center;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: color-mix(in srgb, var(--c) 18%, transparent);
  color: var(--mute);
}
.colhead .ch-m.ch-tbl {
  display: none;
}
@media (max-width: 760px) {
  .colhead .ch-m.ch-tbl {
    display: inline-flex;
  }
}
.reqpop.tfpop .rp-h {
  color: var(--mute);
}
/* Party heading: teal like the party icon when a size is chosen */
.colhead .ch-pty,
.tfpop.pty .tf-i {
  --tf-c: #2dd4bf;
}
html[data-theme="light"] .colhead .ch-pty,
html[data-theme="light"] .tfpop.pty .tf-i {
  --tf-c: #0f766e;
}
.tfpop.pty .tf-i.f-all,
html[data-theme="light"] .tfpop.pty .tf-i.f-all {
  --tf-c: var(--mute);
}
/* Manager PIN dialog: four dots and a keypad (big enough for a fingertip on the iPad) */
.layer.pinlayer .panel {
  width: min(360px, calc(100vw - 32px));
}
.pin-dlg {
  text-align: center;
}
.pin-dlg .pin-why {
  margin: 0 0 18px;
  color: var(--mute);
  font-size: 14px;
  line-height: 1.4;
}
.pin-dots {
  display: flex;
  justify-content: center;
  gap: 16px;
  margin-bottom: 10px;
}
.pin-dots i {
  width: 16px;
  height: 16px;
  border-radius: 50%;
  box-shadow: inset 0 0 0 2px var(--line2);
  transition:
    background 0.12s ease,
    box-shadow 0.12s ease;
}
.pin-dots i.on {
  background: var(--c-asg);
  box-shadow: inset 0 0 0 2px var(--c-asg);
}
.pin-dots.ok i {
  background: #22c55e;
  box-shadow: inset 0 0 0 2px #22c55e;
}
.pin-dots.shake {
  animation: pinShake 0.36s ease;
}
@keyframes pinShake {
  20%,
  60% {
    transform: translateX(-8px);
  }
  40%,
  80% {
    transform: translateX(8px);
  }
}
.pin-msg {
  min-height: 20px;
  margin: 0 0 12px;
  font-size: 13px;
  font-weight: 600;
  color: var(--mute);
}
.pin-msg.bad {
  color: #ef4444;
}
.pin-msg.ok {
  color: #22c55e;
}
.pin-pad {
  display: grid;
  grid-template-columns: repeat(3, 64px);
  justify-content: center;
  gap: 12px;
  margin-bottom: 5px; /* a little more room under the 0 */
}
.pin-k {
  appearance: none;
  -webkit-appearance: none;
  width: 64px;
  height: 64px;
  border-radius: 50%;
  border: 1px solid var(--line2);
  background: color-mix(in srgb, var(--text) 5%, transparent);
  color: var(--text);
  font: inherit;
  font-size: 24px;
  font-weight: 600;
  cursor: pointer;
  display: grid;
  place-items: center;
  -webkit-tap-highlight-color: transparent;
}
.pin-k.del {
  border-color: transparent;
  background: none;
}
.pin-k .i {
  width: 24px;
  height: 24px;
}
.pin-k:active {
  background: color-mix(in srgb, var(--c-asg) 22%, transparent);
}
@media (hover: hover) {
  .pin-k:hover {
    background: color-mix(in srgb, var(--text) 10%, transparent);
  }
}
/* Empty table box on the board: tap to open the floor plan (request a table, or reserve with a manager PIN) */
.row .meta .tb.none[data-act="table"] {
  cursor: pointer;
}
@media (hover: hover) {
  .row .meta .tb.none[data-act="table"]:hover {
    border-color: color-mix(in srgb, var(--text) 45%, transparent);
    color: var(--text);
  }
}
/* A party seated without a table: its "—" box opens the floor plan to pick the table they're at */
.row .meta .tb.none[data-act="seatTbl"] {
  cursor: pointer;
}
@media (hover: hover) {
  .row .meta .tb.none[data-act="seatTbl"]:hover {
    filter: brightness(1.12);
  }
}
/* Tables panel tiles: today Seated / Guests / Tables Assigned; other days Reserved / Requested / Without a Table.
   Reserved is the reserved blue, Requested the request orange (as on the board and floor plan). */
.tb-stats .t-res {
  --c: var(--c-asg);
}
.tb-stats .t-req {
  --c: var(--f-table);
}
.tb-stats .t-none {
  --c: var(--text);
}

/* ===== Booking screen: Open Floor Plan (same button as Reserve Table, in the table colour) ===== */
html[data-theme] .ed .fp-open {
  --c-asg: var(--f-table);
  font: inherit;
  font-weight: 600;
}
/* no time picked yet: "Pick a Time First", faded and not tappable */
html[data-theme] .ed .fp-open:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}
/* Seating: required for big parties */
.ecard > header .opt.req {
  color: var(--f-table);
}
/* Party size: one row of numbers (as many as fit), the − / + box on its own row below */
.ed #edParty {
  flex-wrap: nowrap !important;
}
.ed .ed-pstep {
  margin-top: 10px;
}
/* "Larger party" in a box, same as the party size dialog; the − / + box turns party-coloured past the number buttons */
.ed .ed-pstep .pp-step {
  margin-top: 0;
}
html[data-theme][data-theme] body .ed .ed-pstep .pp-step.on .stepnum {
  border-color: var(--f-party) !important;
  background: color-mix(in srgb, var(--f-party) 12%, transparent) !important;
}
/* Change Day: natural width with a calendar icon, on the same line as the date. If both won't fit the date
   shortens to "Wed, Nov 18", then Change Day drops its icon, then (the app adds .stack) it goes to the next line */
.dfixed .dchip {
  flex: none;
  justify-content: center;
  gap: 8px;
  white-space: nowrap;
}
@media (min-width: 761px) {
  /* a little tighter, so the full date fits beside Change Day on a 1367 × 1024 iPad Pro */
  .dfixed:not(.stack) {
    flex-wrap: nowrap;
    gap: 10px;
  }
  .dfixed:not(.stack) .dfx {
    gap: 8px;
  }
  .dfixed .chip.dchip {
    padding: 0 14px;
  }
  .dfixed.tight .dchip .i {
    display: none;
  }
}
.dfixed .dchip .i {
  width: 17px;
  height: 17px;
  flex: none;
}

/* Floor plan: the Finger table — a pointing hand above its name */
.floor .fp-ico {
  fill: none;
  stroke: var(--sub);
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
  pointer-events: none;
}
.floor .fp-bart.on .fp-ico {
  stroke: var(--sel-ring);
}

/* Booking: a party of 11+ saved without a table — the Seating card turns red until one is picked */
html[data-theme] .ed .ecard.ec-seat.need {
  border-color: var(--c-noshow) !important;
  background: color-mix(in srgb, var(--c-noshow) 10%, transparent) !important;
  box-shadow: 0 0 0 1px var(--c-noshow) !important;
  transition:
    border-color 0.2s,
    background 0.2s;
}
html[data-theme] .ed .ecard.ec-seat.need > header .opt.req {
  color: var(--c-noshow);
}

/* Floor plan: the Porch is picked — its own tables 501–505 are greyed out */
.floor .fp-t.fp-off {
  opacity: 0.32;
}
/* Booking window: the error message in a red box, lined up with the cards above it (same left and right edges)
   and the same space above it (the cards' gap) as below it (the form's bottom padding, 14px) */
html[data-theme] .ed #edWarn:not(:empty) {
  padding: 12px 16px;
  border: 1px solid #ef4444; /* the same red (and glow) as the fields marked in red */
  box-shadow: 0 0 0 3px color-mix(in srgb, #ef4444 22%, transparent);
  border-radius: 14px;
  background: color-mix(in srgb, #ef4444 10%, transparent);
  color: #ef4444;
  flex-shrink: 0; /* phones: the form is a scrolling column, don't squash the box */
  min-height: max-content; /* iPad / desktop: when the form scrolls, its grid row mustn't squash the box either */
}
@media (min-width: 761px) {
  html[data-theme] .ed #edWarn:not(:empty) {
    margin-bottom: -2px; /* cards 12px apart, form bottom padding 14px (shorter screens: 10px / 12px) */
  }
}
@media (min-width: 761px) and (max-height: 860px) {
  html[data-theme] .ed #edWarn:not(:empty) {
    margin-bottom: -4px; /* short screens: cards 8px apart, bottom padding 12px */
  }
}
/* Floor plan: the party line over the name (Table · Party of 2 · 6:00 PM) larger and brighter, easy to read at a glance */
html[data-theme] .sh-head .eyebrow.tp-eye {
  font-size: 14px !important;
  letter-spacing: 0.1em !important;
  color: var(--sub);
}
/* Floor plan footer: the legend (and the note under it, when it wraps) left-aligned, centred top to bottom
   beside Clear Table */
.tpdlg .sh-foot .tp-legend {
  padding-top: 0 !important;
  margin-top: 0 !important;
  align-self: center;
  justify-content: flex-start;
}
.tpdlg .sh-foot .tp-legend.wrap2 .tp-note {
  flex-basis: 100%;
}
/* Floor plan: the 501–505 tables behind the Porch's status, as outlined pills (status colour) above its status bar */
.floor .fp-t rect.fp-pill {
  fill: transparent !important;
  stroke: var(--c-seated) !important;
  stroke-width: 3 !important;
  pointer-events: none;
}
.floor .fp-t rect.fp-pill.k-assigned {
  stroke: var(--c-asg) !important;
}
.floor .fp-t rect.fp-pill.k-held {
  stroke: var(--c-hold) !important;
}
.floor .fp-t .fp-pillt {
  dominant-baseline: central;
  text-anchor: middle;
  font: 800 23px var(--sans);
  letter-spacing: 0.03em;
  fill: #fff;
  pointer-events: none;
}
/* light mode: white wouldn't show on the pale block, so the text is the normal dark text there */
html[data-theme="light"] .floor .fp-t .fp-pillt {
  fill: var(--text);
}
/* Porch selected: its table pills take the selection blue (outline and number), like the name and the status bar */
html[data-theme] .floor .fp-t.on rect.fp-pill {
  stroke: var(--sel-ring) !important;
}
html[data-theme] .floor .fp-t.on .fp-pillt {
  fill: var(--sel-ring);
}
/* Seated-now cards in a narrower Tables panel: Finish takes only the room it needs, so a time like "10:40 AM" fits */
@media (max-width: 1439px) {
  html[data-theme] .tcard .finbtn.actbtn {
    width: auto;
    padding: 0 14px !important;
  }
}
/* Floor plan: Clear Table gets a hover in both themes, like the guest panel's footer buttons */
html[data-theme] .tpdlg .sh-foot .btn.ghost[data-x="clear"]:hover {
  background-color: color-mix(in srgb, var(--text) 8%, var(--panel)) !important;
  border-color: color-mix(in srgb, var(--text) 28%, transparent) !important;
}
/* Confirmation text replies: "Reply by 5:00 PM" while waiting; red "No Reply" (tap to release or keep) once it's late */
html[data-theme] .badge.replyby {
  background: transparent !important;
  color: var(--sub) !important;
  border: 1px solid var(--line2) !important;
}
html[data-theme] .badge.noreply {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  background: #b91c1c !important;
  color: #fff !important;
  border: 0 !important;
  font-weight: 700;
  cursor: pointer;
}
html[data-theme] .badge.noreply svg {
  width: 12px;
  height: 12px;
}
.txstate.late,
.txstate.late svg {
  color: #ef4444;
}
.txstate.late .btn {
  margin-left: auto;
  flex: none;
}
/* "Didn't go through?" after a recorded confirmation text: a small link */
.txstate .txundo,
.flag.txflag .txundo {
  appearance: none;
  background: none;
  border: 0;
  padding: 0;
  font: inherit;
  color: inherit;
  text-decoration: underline;
  text-underline-offset: 2px;
  cursor: pointer;
}
html[data-theme] #bkList .row .sub .badge.noreply {
  border: 0 !important;
}
html[data-theme] #bkList .row .sub .badge.replyby {
  border: 1px solid var(--line2) !important;
  color: var(--sub) !important;
  background: transparent !important;
}
/* Guest Replies: no-reply confirmation alerts first (Keep / Release), then the guests' replies */
.rplist .rpsec {
  margin: 4px 2px 2px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--mute);
}
.rplist .rpsec:first-child {
  margin-top: 0;
}
.rprow.nr {
  cursor: default;
  border-color: color-mix(in srgb, #ef4444 45%, transparent);
  box-shadow: inset 3px 0 0 #ef4444;
}
.rprow.nr .gtx.no {
  color: #ef4444;
}
.rprow.nr .t {
  appearance: none;
  background: none;
  border: 0;
  padding: 0;
  font: inherit;
  color: inherit;
  text-align: left;
  cursor: pointer;
}
.rprow.nr .rpact {
  flex: none;
  display: flex;
  gap: 8px;
}
@media (max-width: 480px) {
  .rprow.nr {
    flex-wrap: wrap;
  }
  /* Keep and Release on their own line: lined up with the name and details above (past the 22px icon and the
     12px gap), sharing the rest of the width equally */
  .rprow.nr .rpact {
    width: 100%;
    box-sizing: border-box;
    padding-left: 34px;
    justify-content: flex-start;
  }
  .rprow.nr .rpact .btn {
    flex: 1 1 0;
    max-width: calc(50% - 4px); /* a kept booking's lone Release stays the same width */
    justify-content: center;
  }
  /* 5px under the buttons, to match the air above the name's letters, so the space looks the same top and bottom */
  .rprow.nr.txr .rpact {
    margin-bottom: 5px;
  }
}
/* Reservation details: the confirmation text's state as a notice box under the status steps */
.flag.txflag > span {
  flex: 1;
  min-width: 0;
}
.flag.txflag .btn {
  flex: none;
}
html[data-theme] .flag.txflag.ok {
  border-color: color-mix(in srgb, var(--c-seated) 45%, transparent);
  background: color-mix(in srgb, var(--c-seated) 10%, transparent);
  color: var(--c-seated);
}
html[data-theme] .flag.txflag.off,
html[data-theme] .flag.txflag.late {
  border-color: color-mix(in srgb, #ef4444 50%, transparent);
  background: color-mix(in srgb, #ef4444 10%, transparent);
  color: #ef4444;
}
html[data-theme] .flag.txflag.ok svg,
html[data-theme] .flag.txflag.off svg,
html[data-theme] .flag.txflag.late svg {
  color: inherit;
}
/* Text Tomorrow's Guests: one confirmation text after another */
.layer.tqdlg .panel {
  width: min(500px, 100%);
}
.tq {
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.tq-n {
  font-size: 13px;
  color: var(--mute);
  margin-bottom: 8px;
}
.tq-n b {
  color: var(--text);
  font-weight: 600;
}
.tq-bar {
  height: 4px;
  border-radius: 2px;
  background: var(--line);
  overflow: hidden;
}
.tq-bar i {
  display: block;
  height: 100%;
  background: #1f6feb;
  transition: width 0.3s ease;
}
.tq-card {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.tq-who {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
}
.tq-who b {
  font-size: 18px;
  font-weight: 600;
}
.tq-who span {
  font-size: 14px;
  color: var(--mute);
  white-space: nowrap;
}
.tq-card .txbubble {
  margin-top: 4px;
}
.tq-list {
  display: flex;
  flex-direction: column;
  max-height: 210px;
  overflow-y: auto;
  border-top: 1px solid var(--line);
  padding-top: 8px;
}
.tq-row {
  display: grid;
  grid-template-columns: 22px minmax(0, 1fr) max-content 64px;
  align-items: center;
  gap: 10px;
  padding: 7px 4px;
  font-size: 13.5px;
  color: var(--mute);
}
.tq-row b {
  font-weight: 500;
  color: var(--text);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.tq-row .tq-ic {
  display: inline-flex;
  justify-content: center;
}
.tq-row .tq-ic svg {
  width: 16px;
  height: 16px;
}
.tq-row .tq-st {
  text-align: right;
  font-size: 12px;
}
.tq-row.on {
  color: #7fb2ff;
}
.tq-row.sent {
  color: #4ade80;
}
.tq-row.sent b,
.tq-row.skip b,
.tq-row.nophone b {
  color: var(--mute);
}
.tq-row.nophone {
  color: #ef8a8a;
}
html[data-theme="light"] .tq-row.on {
  color: #1f6feb;
}
html[data-theme="light"] .tq-row.sent {
  color: #1e8a4c;
}
html[data-theme="light"] .tq-row.nophone {
  color: #c43c3c;
}
.tq-done {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  padding: 10px 0 2px;
  text-align: center;
}
.tq-done svg {
  width: 30px;
  height: 30px;
  color: #4ade80;
}
.tq-done b {
  font-size: 17px;
  font-weight: 600;
}
.tq-done span {
  font-size: 13.5px;
  color: var(--mute);
  line-height: 1.45;
}
/* A booking the host released because the guest didn't answer the confirmation text: "No Reply" on its second line */
html[data-theme] #bkList .row .sub .badge.released {
  gap: 4px;
  background: transparent;
  border: 1px solid color-mix(in srgb, #b91c1c 80%, transparent);
  color: #f87171;
  font-weight: 700;
}
html[data-theme="light"] #bkList .row .sub .badge.released {
  color: #b91c1c;
}
html[data-theme] #bkList .row .sub .badge.released svg {
  width: 11px;
  height: 11px;
  stroke-width: 2.4;
}
/* Text sheet: the red No Reply notice sits in a card like the No Reply guests in Guest Replies */
.txsheet .txstate.late {
  padding: 12px 14px;
  border-radius: 12px;
  border: 1px solid color-mix(in srgb, #ef4444 45%, transparent);
  background: var(--coal);
  box-shadow: inset 3px 0 0 #ef4444;
}
/* Servers screen: servers who are not active are dimmed in the list; Active / Not active pill; guest name in each booking */
.gl.off .t,
.gl.off .avatar,
.gl.off .c {
  opacity: 0.55;
}
.srvstate {
  display: inline-flex;
  align-items: center;
  height: 24px;
  padding: 0 10px;
  border-radius: 999px;
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  border: 1px solid var(--line2);
  color: var(--mute);
}
.srvstate.on {
  border-color: color-mix(in srgb, #22c55e 55%, transparent);
  color: #4ade80;
}
html[data-theme="light"] .srvstate.on {
  color: #1e8a4c;
}
.tl .x .who {
  font-weight: 600;
  color: var(--text);
}
/* ===== Texts tab: confirmation texts grouped by what to do next ===== */
.txsum {
  padding: 6px 28px 0;
}
.txsum-row {
  display: flex;
  align-items: flex-end; /* the count buttons' bottom edge lines up with the progress bar */
  justify-content: flex-start;
  gap: 28px;
  flex-wrap: wrap;
}
.txsum-d {
  display: flex;
  flex-direction: column;
  gap: 2px;
  width: 240px;
  margin-top: 6px; /* a little room under the Texts title */
}
.txsum-d b {
  font-size: 15px;
  font-weight: 600;
  color: var(--text);
}
.txsum-d span {
  font-size: 13px;
  color: var(--mute);
}
/* the date, the booking count and the confirmed bar in their own outlined box, like the count buttons */
.txprog {
  padding: 8px 13px 10px;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: var(--coal);
}
.txstats {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}
.ts {
  appearance: none;
  display: flex;
  align-items: baseline;
  gap: 7px;
  padding: 7px 13px;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: var(--coal);
  color: var(--mute);
  font: inherit;
  cursor: pointer;
}
.ts:hover {
  border-color: var(--line2);
}
.ts b {
  font-size: 18px;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
}
.ts span {
  font-size: 10.5px;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}
.ts-confirmed b {
  color: #4ade80;
}
.ts-waiting b {
  color: #fbbf24;
}
.ts-nottexted b {
  color: #7fb2ff;
}
.ts-noreply b {
  color: #f87171;
}
.ts-replied b {
  color: #c4b5fd;
}
html[data-theme="light"] .ts-confirmed b {
  color: #1e8a4c;
}
html[data-theme="light"] .ts-waiting b {
  color: #b45309;
}
html[data-theme="light"] .ts-nottexted b {
  color: #1f6feb;
}
html[data-theme="light"] .ts-noreply b {
  color: #c43c3c;
}
html[data-theme="light"] .ts-replied b {
  color: #7c3aed;
}
.txsum .txbar {
  margin-top: 8px;
}
.rplist.txlist {
  max-height: none;
  overflow: visible;
  padding: 0 20px 28px;
  gap: 0; /* day panels sit edge to edge; the rows inside keep their 8px gap */
}
.rprow.txr {
  cursor: pointer;
}
.rprow .rpact {
  flex: none;
  display: flex;
  gap: 8px;
}
.rprow .rpact .btn svg {
  width: 15px;
  height: 15px;
}
.rprow.txr.sel {
  outline: 2px solid color-mix(in srgb, #3b82f6 75%, transparent);
  outline-offset: 1px;
}
.rprow.nr.kept {
  box-shadow: none;
  border-style: dashed;
}
.rprow .gtx.not {
  color: #7fb2ff;
}
.rprow .gtx.wait {
  color: #fbbf24;
}
html[data-theme="light"] .rprow .gtx.not {
  color: #1f6feb;
}
html[data-theme="light"] .rprow .gtx.wait {
  color: #b45309;
}
/* Texts, Replied rows: purple like the Replied count (border, left bar); a reply not opened yet has a faint purple
   wash and a blue dot. What the guest said is in a tag, with the icon in the same color: green Confirmed, red Canceled, gray
   Released. */
.rprow.rrep {
  border-color: color-mix(in srgb, #a78bfa 45%, transparent);
  box-shadow: inset 3px 0 0 #a78bfa;
}
.rprow.rrep.fresh {
  position: relative;
  border-color: color-mix(in srgb, #a78bfa 65%, transparent);
  background: color-mix(in srgb, #a78bfa 8%, var(--coal));
}
/* a reply nobody has opened yet: a blue dot in the card's top-right corner (goes when the card is picked) */
.rprow.rrep.fresh::after {
  content: "";
  position: absolute;
  top: 9px;
  right: 9px;
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: #3b82f6;
}
html[data-theme="light"] .rprow.rrep.fresh::after {
  background: #2563eb;
}
.rprow .gtx.r-yes {
  color: #86efac;
}
.rprow .gtx.r-no {
  color: #fca5a5;
}
.rprow .gtx.r-rel {
  color: var(--mute);
}
html[data-theme="light"] .rprow.rrep {
  border-color: color-mix(in srgb, #7c3aed 35%, transparent);
  box-shadow: inset 3px 0 0 #7c3aed;
}
html[data-theme="light"] .rprow.rrep.fresh {
  border-color: color-mix(in srgb, #7c3aed 55%, transparent);
  background: color-mix(in srgb, #7c3aed 6%, var(--coal));
}
html[data-theme="light"] .rprow .gtx.r-yes {
  color: #15803d;
}
html[data-theme="light"] .rprow .gtx.r-no {
  color: #b42318;
}
/* a guest who still wants a reservation the host released (replied after the deadline): amber, needs a call */
.rprow .gtx.r-late {
  color: #fbbf24;
}
html[data-theme="light"] .rprow .gtx.r-late {
  color: #b45309;
}
.rprow .t span.rtag {
  align-self: flex-start;
  margin-top: 4px;
  padding: 3px 9px;
  border-radius: 7px;
  font-size: 12.5px;
  font-weight: 600;
}
.rprow .t span.rtag.yes {
  background: color-mix(in srgb, #22c55e 16%, transparent);
  border: 1px solid color-mix(in srgb, #22c55e 40%, transparent);
  color: #86efac;
}
.rprow .t span.rtag.no {
  background: color-mix(in srgb, #ef4444 16%, transparent);
  border: 1px solid color-mix(in srgb, #ef4444 40%, transparent);
  color: #fca5a5;
}
.rprow .t span.rtag.rel {
  background: color-mix(in srgb, var(--text) 8%, transparent);
  border: 1px solid var(--line2);
  color: var(--mute);
}
html[data-theme="light"] .rprow .t span.rtag.yes {
  background: color-mix(in srgb, #22c55e 10%, transparent);
  color: #15803d;
}
html[data-theme="light"] .rprow .t span.rtag.no {
  background: color-mix(in srgb, #ef4444 10%, transparent);
  color: #b42318;
}
.rprow .t span.rtag.late {
  background: color-mix(in srgb, #f59e0b 16%, transparent);
  border: 1px solid color-mix(in srgb, #f59e0b 40%, transparent);
  color: #fcd34d;
}
html[data-theme="light"] .rprow .t span.rtag.late {
  background: color-mix(in srgb, #f59e0b 10%, transparent);
  color: #b45309;
}
.txstate.wantback,
.txstate.wantback svg {
  color: #fbbf24;
}
html[data-theme="light"] .txstate.wantback,
html[data-theme="light"] .txstate.wantback svg {
  color: #b45309;
}
/* Texts, Confirmed rows: the check in green, like the Confirmed count */
.rprow .gtx.ok {
  color: #4ade80;
}
html[data-theme="light"] .rprow .gtx.ok {
  color: #1e8a4c;
}
.rplist .txsec {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-top: 14px;
}
.txsec.k-noreply {
  color: #f87171;
}
html[data-theme="light"] .txsec.k-noreply {
  color: #c43c3c;
}
/* the whole title row is the button (looks the same: same type, same 6px gap after the arrow), with 10px more
   above and below to tap — taken back with negative margins so nothing moves */
.txfold {
  appearance: none;
  display: inline-flex;
  flex: 1;
  align-items: center;
  gap: 6px;
  margin: -10px 0;
  padding: 10px 0;
  border: 0;
  background: none;
  color: inherit;
  font: inherit;
  letter-spacing: inherit;
  text-transform: inherit;
  text-align: left;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
.txfold svg {
  width: 14px;
  height: 14px;
  transition: transform 0.15s ease;
}
.txfold.on svg {
  transform: rotate(90deg);
}
.txnone {
  padding: 2px 4px 6px;
  font-size: 13.5px;
}
.txdet .txline {
  margin: 16px 0 16px;
  font-size: 15px;
  color: var(--mute);
}
.txacts {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 4px 0 22px;
}
.txhist {
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.txh {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 14.5px;
}
.txh svg {
  width: 18px;
  height: 18px;
  color: var(--mute);
  flex: none;
}
.txh b {
  font-weight: 600;
}
.txh span {
  margin-left: auto;
  color: var(--mute);
}
.srvstate.late {
  border-color: color-mix(in srgb, #ef4444 55%, transparent);
  color: #f87171;
}
html[data-theme="light"] .srvstate.late {
  color: #c43c3c;
}
#txView header.audtop .tools {
  flex-wrap: wrap;
  gap: 10px;
}
/* Texts: the booking's status as a pill in its own color; a wider list column */
.srvstate.txst {
  border-color: color-mix(in srgb, var(--c) 55%, transparent);
  color: var(--c);
}
#xSplit {
  grid-template-columns: minmax(340px, 460px) 1fr;
}
/* Texts: colored words in the rows */
.c-wait,
.rprow .t span.c-wait {
  color: #fbbf24;
}
.c-late,
.rprow .t span.c-late {
  color: #f87171;
}
html[data-theme="light"] .c-wait,
html[data-theme="light"] .rprow .t span.c-wait {
  color: #b45309;
}
html[data-theme="light"] .c-late,
html[data-theme="light"] .rprow .t span.c-late {
  color: #c43c3c;
}
@media (max-width: 760px) {
  /* Texts on phones: sound and Text All (icon) on the right of the title */
  html[data-theme] #txView header.audtop .tools:not(#_z1) {
    flex: 0 0 auto !important;
    flex-wrap: nowrap;
    justify-content: flex-end !important;
    margin-left: auto;
  }
  #txView .rpsound {
    flex: none;
    padding: 0 10px;
  }
  .txsum {
    padding: 6px 18px 0;
  }
}
/* Texts: one panel per day — a full-width header bar (tap to open or close; it stays at the top while its day
   scrolls by), with that day's groups under it */
.txdh {
  position: sticky;
  top: 0;
  z-index: 2;
  display: flex;
  align-items: center;
  gap: 10px;
  width: calc(100% + 40px);
  margin: 0 -20px;
  padding: 13px 20px;
  border-bottom: 1px solid var(--line);
  --txdh-bg: color-mix(in srgb, var(--text) 7%, var(--rail));
  background: var(--txdh-bg);
  color: var(--text);
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.01em;
  text-align: left;
}
html[data-theme="light"] .txdh {
  --txdh-bg: color-mix(in srgb, var(--text) 5%, var(--panel));
}
.txdg + .txdg > .txdh::before {
  /* a line between day panels, along the top of each header after the first */
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  top: 0;
  height: 1px;
  background: var(--line2);
}
.txdh:hover {
  --txdh-bg: color-mix(in srgb, var(--text) 10%, var(--rail));
}
html[data-theme="light"] .txdh:hover {
  --txdh-bg: color-mix(in srgb, var(--text) 8%, var(--panel));
}
.txdh > svg {
  flex: none;
  width: 16px;
  height: 16px;
  color: var(--mute);
  transition: transform 0.2s ease;
}
.txdg.open .txdh > svg {
  transform: rotate(90deg);
}
.txdh-l {
  flex: none;
}
/* the day's counts on the right of its header: numbers in the count buttons' colors (No Reply, Not Texted,
   Waiting, Replied, Confirmed) */
.txdh-n {
  margin-left: auto;
  display: flex;
  gap: 6px;
}
.txdn {
  min-width: 26px;
  padding: 2px 7px;
  border-radius: 999px;
  border: 1px solid currentColor;
  font-size: 12px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  text-align: center;
}
.txdn.k-noreply {
  color: #f87171;
}
.txdn.k-nottexted {
  color: #7fb2ff;
}
.txdn.k-waiting {
  color: #fbbf24;
}
.txdn.k-confirmed {
  color: #4ade80;
}
.txdn.k-replied {
  color: #c4b5fd;
}
html[data-theme="light"] .txdn.k-noreply {
  color: #c43c3c;
}
html[data-theme="light"] .txdn.k-nottexted {
  color: #1f6feb;
}
html[data-theme="light"] .txdn.k-waiting {
  color: #b45309;
}
html[data-theme="light"] .txdn.k-confirmed {
  color: #1e8a4c;
}
html[data-theme="light"] .txdn.k-replied {
  color: #7c3aed;
}
.txdb {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 16px 0 18px;
}
.txempty {
  margin-top: 20px;
}
/* the count button whose group is showing (tap it again to show everything) */
.ts.on {
  border-color: var(--sel-bd, #3b82f6);
  background: color-mix(in srgb, #3b82f6 14%, var(--coal));
}
/* Texts, No Reply rows: the missed deadline on its own red tag */
.rprow .t span.duepill {
  align-self: flex-start;
  margin-top: 4px;
  padding: 3px 9px;
  border-radius: 7px;
  background: color-mix(in srgb, #ef4444 16%, transparent);
  border: 1px solid color-mix(in srgb, #ef4444 40%, transparent);
  color: #fca5a5;
  font-size: 12.5px;
  font-weight: 600;
}
html[data-theme="light"] .rprow .t span.duepill {
  background: color-mix(in srgb, #ef4444 10%, transparent);
  color: #b42318;
}
/* Texts: the day filter at the right end of the summary row */
.txsum-row .txday {
  margin-left: auto;
}
/* Texts, No Reply rows: Keep on top of Release, both the same width; 5px under the red "Reply was due" tag, to
   match the air above the name's letters, so the space inside the card looks the same top and bottom */
@media (min-width: 481px) {
  .rprow.nr.txr .t span.duepill {
    margin-bottom: 5px;
  }
  .rprow.nr.txr .rpact {
    flex-direction: column;
    width: 104px;
  }
  .rprow.nr.txr .rpact .btn {
    width: 100%;
    justify-content: center;
  }
}
/* Texts summary row: the count buttons and the day filter the same height, their bottom edges level with the
   booking box's */
.txsum-row .txprog {
  box-sizing: border-box;
  padding: 10px 13px 12px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 2px;
}
.txsum-row .txprog .txbar {
  margin-top: 6px;
}
.txsum-row .ts {
  box-sizing: border-box;
  height: 48px;
  align-items: center;
}
.txsum-row .txday,
#txView .txday-top {
  box-sizing: border-box;
  height: 48px;
  align-items: stretch;
}
.txsum-row .txday button,
#txView .txday-top button {
  height: auto;
}
/* Texts: the day filter sits on the summary row, except on mid-size screens (761–1299px wide, everything wider than the phone layout), where it moves up
   to the header's top row beside Sound and Text All */
.txday-top {
  display: none !important;
}
@media (min-width: 761px) and (max-width: 1299px) {
  .txday-top {
    display: inline-flex !important;
  }
  .txsum-row .txday-row {
    display: none !important;
  }
  #txView header.audtop .title {
    flex: none;
  }
  #txView header.audtop .tools {
    flex-wrap: nowrap;
    min-width: 0 !important;
  }
}
@media (min-width: 761px) and (max-width: 1060px) {
  /* narrow: Sound and Text All as icons so the day filter fits beside the title (full labels need about 1040px) */
  #txView .rpsound span,
  #txView .newbtn[data-act="txAll"] .lbl-long {
    display: none !important;
  }
  #txView .txday-top button {
    padding: 0 10px;
  }
}
/* Texts rows: Keep is clear like Release, so hovering the row doesn't make it look pressed; it lights up only
   when the pointer is on it */
html[data-theme] .rprow .rpact .btn.ghost {
  background: transparent;
}
html[data-theme] .rprow .rpact .btn.ghost:hover {
  background: color-mix(in srgb, var(--text) 9%, transparent);
  border-color: var(--line2);
}
/* Texts: while another day loads, the current numbers and list stay put, dimmed */
#txSum.loading .txsum-d,
#txSum.loading .txstats,
#txList.loading {
  opacity: 0.45;
  transition: opacity 0.15s ease;
}
/* Guests, Servers and Texts at 991px wide and below, phones included: one column — the list, then the chosen
   guest, server or booking in its place with a back button */
@media (max-width: 991px) {
  #gSplit,
  #sSplit,
  #xSplit {
    grid-template-columns: 1fr;
  }
  #gSplit .r,
  #sSplit .r,
  #xSplit .r {
    display: none;
  }
  #gSplit.showing .l,
  #sSplit.showing .l,
  #xSplit.showing .l {
    display: none;
  }
  #gSplit.showing .r,
  #sSplit.showing .r,
  #xSplit.showing .r {
    display: block;
  }
  #gSplit .back,
  #sSplit .back,
  #xSplit .back {
    display: inline-flex;
  }
}
/* Phones: the Menu button's pop-up, just above the tab bar on the right */
.tbmenu {
  position: fixed;
  right: 10px;
  bottom: calc(80px + var(--sa-b) + 8px);
  z-index: 60;
  min-width: 190px;
  display: flex;
  flex-direction: column;
  padding: 6px;
  border-radius: 14px;
  border: 1px solid var(--line2);
  background: var(--coal);
  box-shadow: 0 12px 36px rgba(0, 0, 0, 0.35);
  animation: tbmenuIn 0.14s ease-out;
}
.tbmenu button {
  appearance: none;
  display: flex;
  align-items: center;
  gap: 12px;
  height: 46px;
  padding: 0 14px;
  border-radius: 9px;
  color: var(--text);
  font-size: 15px;
  font-weight: 500;
  text-align: left;
}
.tbmenu button svg {
  width: 20px;
  height: 20px;
  color: var(--mute);
}
.tbmenu button:hover,
.tbmenu button.on {
  background: color-mix(in srgb, var(--text) 8%, transparent);
}
@keyframes tbmenuIn {
  from {
    opacity: 0;
    transform: translateY(6px);
  }
}
@media (min-width: 761px) {
  .tbmenu {
    display: none;
  }
}
/* Texts, iPad widths (780–1039px), where the five count buttons drop under the booking box: less space above
   them, and they share the full row in equal widths (on every day, so switching days doesn't shift it); the day
   filter comes back down beside the booking box, left-aligned, so the header has room for the Sound and Text All
   labels again */
@media (min-width: 780px) and (max-width: 1039px) {
  .txsum-row {
    row-gap: 12px;
  }
  .txstats {
    display: grid;
    grid-auto-flow: column;
    grid-auto-columns: 1fr;
    width: 100%;
  }
  .ts {
    justify-content: center;
  }
  .txday-top {
    display: none !important;
  }
  .txsum-row .txday-row {
    display: inline-flex !important;
    margin-left: 0;
    order: 1;
  }
  .txsum-row .txstats {
    order: 2;
  }
  #txView .rpsound span,
  #txView .newbtn[data-act="txAll"] .lbl-long {
    display: inline !important;
  }
}
/* Texts: a booking waiting for the guest's reply gets a yellow border and bar, like the red No Reply rows */
.rprow.rwait {
  border-color: color-mix(in srgb, #fbbf24 50%, transparent);
  box-shadow: inset 3px 0 0 #fbbf24;
}
html[data-theme="light"] .rprow.rwait {
  border-color: color-mix(in srgb, #d97706 45%, transparent);
  box-shadow: inset 3px 0 0 #d97706;
}
/* Texts: the arrow that opens the count buttons — phones only */
.txmore {
  display: none;
}
/* Left panel: 5px more space under each button, and a faint line between buttons instead of outlines */
html[data-theme] .rail .nav {
  margin-bottom: 5px;
}
.rail .nav + .nav::after {
  content: "";
  position: absolute;
  left: 5px;
  right: 5px; /* 5px in from each side of the buttons */
  top: -6px; /* halfway across the 11px between buttons */
  height: 1px;
  background: var(--line);
  pointer-events: none;
}
/* Texts, 1300–1439px wide: everything on one row — the booking box, the five counts, and the day filter on the
   right — with the spacing a little tighter so it fits */
@media (min-width: 1300px) and (max-width: 1439px) {
  .txsum-row {
    column-gap: 16px;
  }
  .txsum-d {
    width: 220px;
  }
  .txstats {
    gap: 6px;
  }
  .txsum-row .ts {
    gap: 6px;
    padding-left: 9px;
    padding-right: 9px;
  }
  .ts span {
    letter-spacing: 0.05em;
  }
  .txsum-row .txday button {
    padding: 0 10px;
  }
}
/* ===== Texts summary, compact (779px wide and narrower: phones, and the narrowest iPad widths, where the day
   filter no longer fits beside the booking box) — the box full width with the arrow beside it, the count buttons
   folded under it, the day filter on its own row ===== */
@media (max-width: 779px) {
  #txView .txday {
    flex: 1 1 100%;
    min-width: 0;
  }
  #txView .txday button {
    flex: 1;
    padding: 0 6px;
    white-space: nowrap;
    font-size: 13px;
  }
  .txstats {
    width: 100%;
  }
  .ts {
    justify-content: center;
  }
  /* Texts: the four count buttons in one compact row — the number over a small label */
  .txsum-row {
    row-gap: 12px;
  }
  .txstats {
    grid-auto-flow: column;
    grid-auto-columns: 1fr;
    gap: 6px;
  }
  /* every label stays on one line (its size follows the button's width), so all five read the same: number over
     label, centered, the same space above and below */
  .txsum-row .ts {
    container-type: inline-size;
    height: 52px;
    flex-direction: column;
    justify-content: center;
    gap: 2px;
    padding: 0 4px;
    min-width: 0;
  }
  .txsum-row .ts b {
    font-size: 17px;
    line-height: 1.1;
  }
  .txsum-row .ts span {
    font-size: 8.5px;
    font-size: min(8.5px, 100cqw / 6.9); /* "Not Texted" fits on one line at any width */
    letter-spacing: 0.02em;
    line-height: 1.15;
    white-space: nowrap;
    overflow: hidden;
    max-width: 100%;
  }
  /* Texts: the arrow beside the booking box that opens the count buttons */
  .txsum-row .txsum-d {
    flex: 1 1 0;
    min-width: 0;
  }
  .txsum-row .txmore {
    flex: none;
    align-self: stretch; /* as tall as the booking box beside it */
    display: flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    margin: 6px 0 0 -18px; /* sits 10px from the booking box (the row's gap is 28px), level with its top */
    border-radius: 10px;
    border: 1px solid var(--line2);
    background: var(--coal);
    color: var(--mute);
  }
  .txsum-row .txmore svg {
    width: 18px;
    height: 18px;
    transform: rotate(90deg);
    transition: transform 0.2s ease;
  }
  #txSum.open .txmore {
    color: var(--text);
    border-color: var(--sel-bd, var(--line2));
  }
  #txSum.open .txmore svg {
    transform: rotate(-90deg);
  }
  /* the count buttons: hidden until the arrow opens them, then a full-width row under the booking box */
  .txsum-row .txstats {
    display: none;
  }
  #txSum.open .txsum-row .txstats {
    display: grid;
    flex: 1 1 100%;
  }
}
@media (min-width: 761px) and (max-width: 779px) {
  /* with the left panel: the day filter on the summary row (not the header), Sound with its label, Text All as
     its icon */
  .txday-top {
    display: none !important;
  }
  .txsum-row .txday-row {
    display: inline-flex !important;
  }
  #txView .rpsound span {
    display: inline !important;
  }
}
/* ===== Phones (760px wide and narrower) ===== */
@media (max-width: 760px) {
  /* Tab bar: five spots (Book, Texts, +, Guests, Menu) */
  .tabbar .nav {
    width: auto;
    flex: 1 1 0;
    margin: 0 8px; /* 8px in from each side, so the lit tab doesn't touch its neighbours */
  }
  .tabbar .nav span {
    white-space: nowrap;
  }
  .tabbar .nav.open {
    color: var(--text);
  }
  /* Tab bar: more room either side of the + button — Texts 5px further left, Guests 5px further right */
  .tabbar .nav[data-v="texts"] {
    transform: translateX(-5px);
  }
  .tabbar .nav[data-v="guests"] {
    transform: translateX(5px);
  }
  /* Text queue: the guest list keeps its height (the window scrolls instead of squeezing it to one row),
     and each guest's name sits over their date and time so the name isn't cut short */
  .tq .tq-list {
    flex: none;
    max-height: none;
    overflow: visible;
  }
  .tq-row {
    grid-template-columns: 22px minmax(0, 1fr) max-content;
    grid-template-areas:
      "ic name st"
      ". when when";
    row-gap: 2px;
  }
  .tq-row .tq-ic {
    grid-area: ic;
  }
  .tq-row b {
    grid-area: name;
  }
  .tq-row > span:not(.tq-ic):not(.tq-st) {
    grid-area: when;
  }
  .tq-row .tq-st {
    grid-area: st;
  }
}
/* Smallest phones (360px and narrower): tabs inset 6px instead of 8px, so the lit box still fits its label; the
   count buttons and the day filter a little tighter */
@media (max-width: 360px) {
  .tabbar .nav {
    margin: 0 6px;
  }
  .txsum-row .txstats {
    gap: 4px;
  }
  .txsum-row .ts {
    padding: 0 2px;
  }
  /* the day filter's four buttons and the line before Texts Sent fit the width */
  #txView .txday button {
    padding: 0 4px;
    font-size: 12px;
  }
}
/* Texts day filter: a thin upright line before Texts Sent, which works differently (every texted booking, any
   date) */
.txday .txsep {
  position: relative;
  margin-left: 11px;
}
.txday .txsep::before {
  content: "";
  position: absolute;
  left: -6px;
  top: 7px;
  bottom: 7px;
  width: 1px;
  background: var(--line2);
}
/* iPhone, Texts: the picked booking's sheet — the booking's own layout sets the padding; no "All texts" back
   button (swipe the sheet down instead) */
.dp-scroll.txsheet {
  padding: 0;
}
.dp-scroll.txsheet .back {
  display: none;
}
/* the sheet ends 20px below the last box, the same as its sides (plus the iPhone's home bar) */
.dp-scroll.txsheet .profile {
  padding-bottom: calc(20px + var(--sa-b));
}
/* Phones: the top row's buttons fill the row edge to edge, lined up with the edges of the rows below (Today
   twice as wide as the others); six days across the day strip (see d6Off in app.js) */
@media (max-width: 760px) {
  html[data-theme] #app #bookView > .top .tools {
    display: grid !important;
    grid-auto-flow: column;
    grid-auto-columns: minmax(0, 1fr);
    gap: 6px !important;
    width: 100% !important;
  }
  html[data-theme] #app #bookView > .top .tools .datenav {
    display: contents !important;
  }
  html[data-theme] #app #bookView > .top .tools .btn {
    width: auto !important;
    min-width: 0 !important;
    padding-left: 0 !important;
    padding-right: 0 !important;
    justify-content: center;
  }
  html[data-theme] #app #bookView > .top .tools [data-act="today"] {
    grid-column: span 2;
  }
  html[data-theme] #app #bookView #bkStrip {
    display: grid !important;
    gap: 6px !important;
  }
}
/* ===================================================================================================
   iPhone Duo, opened in landscape (890 × 626 — the height range allows for Safari's bars). Nothing here
   reaches any other screen size. Short and wide: every tab gets two panels side by side, tighter headers,
   and the board / lists get the height.
   =================================================================================================== */
@media (min-width: 880px) and (max-width: 900px) and (max-height: 660px) {
  /* ---- Shell: the side menu floats over the left panel (dark see-through glass) and can be put away — the
     ‹ button, or a swipe to the left (a swipe right from the screen's left edge, or the tab there, brings it back).
     The left and right panels each take exactly half the screen; Book keeps the reservation / Tables panel open
     on the right half. ---- */
  html[data-theme] .app,
  html[data-theme] .app[data-view] {
    grid-template-columns: minmax(0, 1fr) !important;
  }
  html[data-theme] .app[data-view="book"] {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) !important;
  }
  html[data-theme] .app > .rail {
    position: fixed;
    left: 0;
    top: 0;
    bottom: 0;
    z-index: 30;
    width: calc(84px + var(--sa-l));
    background: color-mix(in srgb, #0b0c0f 72%, transparent);
    -webkit-backdrop-filter: blur(14px) saturate(1.2);
    backdrop-filter: blur(14px) saturate(1.2);
    box-shadow: 6px 0 24px rgba(0, 0, 0, 0.35);
    transition:
      transform 0.25s ease,
      visibility 0s linear 0s;
  }
  html[data-theme="light"] .app > .rail {
    background: color-mix(in srgb, #f4f4f2 78%, transparent);
    box-shadow: 6px 0 24px rgba(0, 0, 0, 0.12);
  }
  /* put away: it slides off to the left */
  html.rail-off[data-theme] .app > .rail {
    width: calc(84px + var(--sa-l)) !important;
    padding-top: calc(10px + var(--sa-t)) !important;
    padding-bottom: calc(10px + var(--sa-b)) !important;
    transform: translateX(-100%);
    transition:
      transform 0.25s ease,
      visibility 0s linear 0.25s;
  }
  html[data-theme] .app[data-view="book"] aside#detail {
    display: block;
  }
  html[data-theme] .app {
    grid-template-rows: minmax(0, 1fr);
  }
  /* the side rail fits the 626px height (Account at the bottom was cut off) */
  html[data-theme] .rail {
    padding-top: calc(10px + var(--sa-t));
    padding-bottom: calc(10px + var(--sa-b));
    gap: 4px;
  }
  html[data-theme] .rail .mono {
    width: 40px;
    height: 40px;
    margin-bottom: 8px;
  }
  html[data-theme] .rail .nav {
    height: 52px;
    gap: 4px;
  }
  html[data-theme][data-theme] .rail .nav {
    margin-bottom: 3px;
  }
  html[data-theme] .rail .nav + .nav::after {
    top: -4px;
  }
  /* the shorter buttons: the Texts badge 3px lower */
  .rail .nav .rbadge {
    top: calc(50% - 30px);
  }
  html[data-theme] .rail .railbtn {
    height: 28px;
    margin-bottom: 4px;
  }
  html[data-theme] .rail .themebtn,
  html[data-theme] .rail .avatar {
    width: 36px;
    height: 36px;
  }
  html[data-theme] .rail .themebtn {
    margin-bottom: 4px;
  }

  /* ---- Book, left half: date + buttons on one line, the day strip, the stats (filters drop down under
     them), search + Now, then the board ---- */
  html[data-theme] #app #bookView > .top {
    padding: calc(12px + var(--sa-t)) 14px 0;
    flex-wrap: nowrap;
    align-items: center;
    gap: 8px;
  }
  html[data-theme] #app #bookView > .top .title {
    min-width: 0;
    flex: 1 1 auto;
  }
  html[data-theme] #app #bookView > .top .eyebrow {
    font-size: 9px;
  }
  html[data-theme] #app #bookView > .top h1 {
    font-size: 21px;
    line-height: 1.1;
    margin-top: 2px;
    white-space: nowrap;
  }
  html[data-theme] #app #bookView > .top h1 .today-tag,
  html[data-theme] #app #bookView > .top h1 .badge {
    display: none;
  }
  /* the buttons sit at the right, lined up with the day strip's arrow below */
  html[data-theme] #app #bookView > .top .tools {
    flex: none !important;
    flex-wrap: nowrap !important;
    gap: 6px !important;
    margin: 0 0 0 auto !important;
    width: auto !important;
  }
  /* no Search (it's in its own row), Tables (the right half shows them) or guest replies button (the Texts tab
     has them) up here */
  html[data-theme] #app #bookView > .top .tools > .search,
  html[data-theme] #app #bookView > .top .tools .rpbtn,
  html[data-theme] #app #bookView > .top .tools .tblbtn,
  html[data-theme] #app #bookView > .top .tools .datenav [data-act="day"] {
    display: none;
  }
  html[data-theme] #app #bookView > .top .tools .datenav {
    display: flex !important;
    gap: 6px;
  }
  html[data-theme] #app #bookView > .top .tools .datenav [data-act="today"],
  html[data-theme] #app #bookView > .top .tools .datenav [data-act="cal"] {
    display: inline-flex !important;
  }
  html[data-theme] #app #bookView > .top .title .sync.dotonly {
    display: none;
  }
  html[data-theme] #app #bookView > .top .tools .btn {
    height: 34px;
    min-width: 34px;
  }
  html[data-theme] #app #bookView > .top .tools .btn.icon,
  html[data-theme] #app #bookView > .top .tools .rpbtn,
  html[data-theme] #app #bookView > .top .tools .newbtn {
    width: 42px !important;
    min-width: 42px !important;
    padding: 0 !important;
    flex: none !important;
  }
  html[data-theme] #app #bookView > .top .tools [data-act="today"] {
    padding: 0 10px;
    font-size: 13px;
  }
  html[data-theme] #app #bookView > .top .tools .newbtn .lbl-long,
  html[data-theme] #app #bookView > .top .tools .newbtn .lbl-short {
    display: none;
  }
  html[data-theme] #app #bookView > .top .tools svg {
    width: 17px;
    height: 17px;
  }
  /* day strip: arrows at the ends, seven equal days */
  html[data-theme] #app #bookView .striprow {
    padding: 10px 14px 0;
    gap: 6px;
  }
  html[data-theme] #app #bookView .striprow .dn-strip {
    display: contents !important;
  }
  html[data-theme] #app #bookView #bkStrip .day.is-today:after {
    right: 3px;
  }
  html[data-theme] #app #bookView .striprow .dn-strip [data-act="today"],
  html[data-theme] #app #bookView .striprow .dn-strip [data-act="cal"] {
    display: none;
  }
  html[data-theme] #app #bookView .striprow .dn-strip [data-act="day"] {
    width: 26px;
    min-width: 26px;
    height: 50px;
    padding: 0;
    flex: none;
  }
  html[data-theme] #app #bookView .striprow .dn-strip [data-act="day"][data-d="1"] {
    order: 3;
  }
  html[data-theme] #app #bookView #bkStrip {
    order: 2;
    flex: 1 1 0;
    min-width: 0;
    display: grid;
    gap: 4px;
    margin: 0;
    padding: 0;
  }
  html[data-theme] #app #bookView #bkStrip .day {
    height: 50px;
    padding: 6px 0;
    gap: 1px;
  }
  html[data-theme] #app #bookView #bkStrip .day .dw {
    font-size: 8.5px;
    letter-spacing: 0.06em;
  }
  html[data-theme] #app #bookView #bkStrip .day .dn {
    font-size: 15px;
    line-height: 1.05;
  }
  html[data-theme] #app #bookView #bkStrip .day .dc {
    font-size: 8.5px;
    white-space: nowrap;
  }
  /* stats: five small counts + the drop-down arrow (status filter, Lunch / Dinner) */
  html[data-theme] #app #bookView .summary {
    padding: 10px 14px 0 !important;
    margin: 0;
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) 30px !important;
    gap: 8px !important;
    border: 0;
  }
  html[data-theme] #app #bookView .summary .stats {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 6px;
    min-width: 0;
  }
  html[data-theme] #app #bookView .summary .stat {
    display: flex;
    flex-direction: column;
    justify-content: center;
    min-width: 0;
    padding: 0 0 0 8px;
    margin: 0;
    min-height: 0;
  }
  html[data-theme] #app #bookView .summary .stat .v {
    font-size: 17px;
    line-height: 1.1;
  }
  html[data-theme] #app #bookView .summary .stat .k {
    display: block;
    white-space: normal;
    overflow: visible;
    font-size: 8px;
    letter-spacing: 0.06em;
    line-height: 1.2;
    margin-top: 2px;
  }
  html[data-theme] #app #bookView .summary .sum-more {
    display: grid;
    place-items: center;
    width: 30px;
    height: 30px;
    align-self: center;
    padding: 0;
    border-radius: 9px;
    border: 1px solid var(--line2);
    background: transparent;
    color: var(--mute);
    cursor: pointer;
  }
  /* the arrow points down to open the drop-down, up to close it (as on phones) */
  html[data-theme] #app #bookView .summary .sum-more svg {
    width: 17px;
    height: 17px;
    transform: rotate(90deg);
    transition: transform 0.2s ease;
  }
  html[data-theme] #app #bookView .summary.open .sum-more {
    color: var(--text);
  }
  html[data-theme] #app #bookView .summary.open .sum-more svg {
    transform: rotate(-90deg);
  }
  /* a status or Lunch / Dinner filter is on while it's closed: blue outline with a dot */
  html[data-theme] #app #bookView .summary .sum-more.active {
    position: relative;
    color: var(--text);
    border-color: color-mix(in srgb, #60a5fa 65%, transparent);
  }
  html[data-theme] #app #bookView .summary .sum-more.active::after {
    content: "";
    position: absolute;
    top: -3px;
    right: -3px;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #3b82f6;
    box-shadow: 0 0 0 2px var(--bg);
  }
  html[data-theme] #app #bookView .summary .pacewrap {
    display: none;
  }
  html[data-theme] #app #bookView .summary.open .pacewrap {
    grid-column: 1 / -1;
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 8px;
    margin: 0;
    padding: 0;
    border: 0;
    min-width: 0;
  }
  html[data-theme] #app #bookView .summary.open .pacewrap .pace {
    display: none;
  }
  html[data-theme] #app #bookView .summary.open .pacewrap .pace-svc {
    position: static;
    order: 0;
  }
  html[data-theme] #app #bookView .summary.open .pacewrap .seg {
    overflow-x: auto;
    max-width: 100%;
    align-self: flex-start;
    scrollbar-width: none;
  }
  /* search + Now */
  html[data-theme] #app #bookView .bar {
    padding: 10px 14px 0 !important;
    gap: 8px !important;
    flex-wrap: nowrap !important;
    margin: 0 !important;
  }
  /* search and Now the same height (40px), with the same 10px above and below the row */
  html[data-theme] #app #bookView .bar .msearch {
    display: flex;
    flex: 1 1 auto;
    min-width: 0;
    width: auto;
    height: 40px;
  }
  html[data-theme] #app #bookView .bar .msearch input {
    height: 40px !important;
    min-height: 0 !important;
  }
  html[data-theme] #app #bookView .bar .mnow {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    height: 40px;
    padding: 0 12px;
    border: 1px solid var(--line2);
    border-radius: 10px;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    flex: none;
  }
  html[data-theme] #app #bookView .bar .mnow svg {
    width: 14px;
    height: 14px;
  }
  /* Now lights up blue when the board has scrolled away from the current time (tap to go back), as on the
     desktop board; dimmed when the board is already there */
  html[data-theme] #app #bookView .bar .mnow:not(.away) {
    opacity: 0.55;
  }
  html[data-theme] #app #bookView .bar .mnow.away {
    color: #93c5fd;
    border-color: color-mix(in srgb, #60a5fa 65%, transparent);
    background: color-mix(in srgb, #60a5fa 14%, transparent);
  }
  html[data-theme="light"] #app #bookView .bar .mnow.away {
    color: #1d4ed8;
    border-color: color-mix(in srgb, #2563eb 55%, transparent);
    background: color-mix(in srgb, #3b82f6 10%, transparent);
  }
  html[data-theme] #app #bookView .bar .bar-svc,
  html[data-theme] #app #bookView .bar .sp,
  html[data-theme] #app #bookView .bar #bkFilter {
    display: none;
  }
  /* the board */
  html[data-theme] #app #bookView .colhead,
  html[data-theme] #app #bookView .list {
    margin-left: 14px;
    margin-right: 14px;
  }
  html[data-theme] #app #bookView .colhead {
    margin-top: 10px;
    padding: 6px 8px 6px 14px;
    gap: 6px;
    grid-template-columns: minmax(0, 1fr) auto auto;
    align-items: center;
  }
  html[data-theme] #app #bookView .colhead > span:first-child {
    display: none;
  }
  html[data-theme] #app #bookView .colhead .ch-guest {
    padding: 0;
  }
  html[data-theme] #app #bookView .colhead .ch-meta {
    display: flex;
    align-items: center;
    gap: 14px;
    position: static;
    left: 0 !important;
  }
  html[data-theme] #app #bookView .colhead .ch-act {
    padding: 0;
  }
  html[data-theme] #app #bookView .colhead .ch-hide {
    font-size: 0;
    gap: 0;
    width: 30px;
    padding: 0;
    justify-content: center;
  }
  /* Party and Table: their own two filters, as on other screens (not the phone's combined one) */
  html[data-theme] #app #bookView .colhead .ch-meta > .ch-pty,
  html[data-theme] #app #bookView .colhead .ch-meta > .ch-tbl:not(.ch-m) {
    display: inline-flex;
    width: auto;
    margin: 0;
  }
  html[data-theme] #app #bookView .colhead .ch-m {
    display: none;
  }
  html[data-theme] #app #bookView .colhead .ch-act [data-act="gonow"] {
    display: none;
  }
  html[data-theme] #app #bookView .row {
    padding: 9px 10px;
    gap: 10px;
    margin: 0 4px;
    grid-template-columns: 30px minmax(0, 1fr) auto;
  }
  html[data-theme] #app #bookView .row + .row::after {
    left: 50px;
  }
  html[data-theme] #app #bookView .row .meta {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
  }
  html[data-theme] #app #bookView .row .act {
    display: none !important;
  }
  html[data-theme] #app #bookView .row .meta .tb {
    max-width: none;
  }
  /* the party button's right edge lines up with the table's */
  html[data-theme] #app #bookView .row .meta .pedit:not(#_z1) {
    margin-bottom: 4px !important;
    margin-right: 0 !important;
    margin-left: 0 !important;
    left: 0 !important;
  }
  html[data-theme] #app #bookView .row .meta .tbw {
    flex-wrap: wrap;
    justify-content: flex-end;
    max-width: 140px;
  }
  html[data-theme] #app #bookView .row .meta .tbw .tblock {
    position: static;
    height: 30px;
  }
  html[data-theme] #app #bookView .row .nm {
    min-width: 0;
    max-width: 100%;
  }
  html[data-theme] #app #bookView .row .nm .stpair {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    flex: 0 0 auto;
    flex-wrap: wrap;
    max-width: 100%;
    row-gap: 6px;
  }
  html[data-theme] #app #bookView .row .nm .nm-lead {
    border-radius: 999px;
  }
  html[data-theme] #app #bookView .row .sub .sub-lead {
    display: none !important;
  }
  html[data-theme] #app #bookView .row .nm .npill,
  html[data-theme] #app #bookView .row .nm .nm-lead,
  html[data-theme] #app #bookView .row .sub .badge:not(.sub-lead) {
    box-sizing: border-box;
    align-items: center;
    height: 20px !important;
    padding: 0 8px !important;
    font-size: 9px !important;
    font-weight: 700 !important;
    letter-spacing: 0.1em !important;
    line-height: 1 !important;
    display: inline-flex !important;
  }
  html[data-theme] #app #bookView .row .nm .npill .pmin {
    padding: 0 7px 0 6px;
    margin-right: -8px;
  }
  html[data-theme] #app #bookView .row .badge.gold {
    height: 20px !important;
    padding: 0 7px !important;
    font-size: 9px !important;
  }
  html[data-theme] #app #bookView .row .sub .badge.conflict {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    background: #b91c1c;
    color: #fff;
    border-color: transparent;
  }
  html[data-theme] #app #bookView .row .sub .badge.conflict svg {
    width: 12px;
    height: 12px;
    color: #fff;
  }
  html[data-theme] #app #bookView .grp {
    padding: 9px 14px;
  }

  /* ---- Texts, Guests, Servers, Audit, Staff: one slim header line ---- */
  html[data-theme] #app #main > .view > header.audtop {
    padding: calc(12px + var(--sa-t)) 16px 12px !important;
    flex-wrap: nowrap !important;
    align-items: center !important;
    gap: 10px !important;
    min-height: 0;
  }
  html[data-theme] #app #main > .view > header.audtop .title {
    flex: none;
    min-width: 0;
  }
  html[data-theme] #app #main > .view > header.audtop .eyebrow {
    font-size: 9px;
  }
  html[data-theme] #app #main > .view > header.audtop h1 {
    font-size: 21px;
    line-height: 1.1;
    margin-top: 2px;
  }
  html[data-theme] #app #main > .view > header.audtop .tools {
    min-width: 0 !important;
    flex-wrap: nowrap !important;
    gap: 8px !important;
  }
  html[data-theme] #app #main > .view > header.audtop .tools .btn {
    height: 36px;
  }
  html[data-theme] #app #main > .view > header.audtop .tools .newbtn:not([data-act="txAll"]) {
    width: 36px;
    min-width: 36px;
    padding: 0;
  }
  html[data-theme] #app #main > .view > header.audtop .tools .newbtn:not([data-act="txAll"]) .lbl-long {
    display: none;
  }

  /* ---- Two panels side by side: the list on the left, the chosen booking / guest / server on the right
     (no back button — both stay on screen) ---- */
  html[data-theme] #app .split {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) !important;
    margin-top: 0;
  }
  html[data-theme] #app .split .l,
  html[data-theme] #app .split.showing .l,
  html[data-theme] #app .split .r,
  html[data-theme] #app .split.showing .r {
    display: block !important;
  }
  html[data-theme] #app .split .r {
    border-left: 1px solid var(--line);
  }
  html[data-theme] #app .split .back {
    display: none !important;
  }

  /* ---- Texts: title, day filter, Sound and Text All on one line; the date box and the five counts on the
     next ---- */
  html[data-theme] #app #txView > header.audtop .tools {
    flex: 1 1 auto !important;
  }
  html[data-theme] #app #txView .txday-top {
    display: inline-flex !important;
    margin-right: auto;
    height: 38px;
    align-items: center;
  }
  html[data-theme] #app #txView .txday-row {
    display: none !important;
  }
  html[data-theme] #app #txView .txday-top button {
    height: 30px;
    padding: 0 11px;
    font-size: 12.5px;
  }
  html[data-theme] #app #txView .rpsound {
    width: 36px;
    min-width: 36px;
    padding: 0;
    justify-content: center;
  }
  html[data-theme] #app #txView .rpsound span {
    display: none;
  }
  html[data-theme] #app #txView [data-act="txAll"] {
    padding: 0 14px;
  }
  html[data-theme] #app #txView [data-act="txAll"] .lbl-long {
    font-size: 0;
  }
  html[data-theme] #app #txView [data-act="txAll"] .lbl-long::after {
    content: "Text All";
    font-size: 13px;
  }
  html[data-theme] #app #txSum {
    padding: 0 16px 12px !important;
    margin: 0 !important;
  }
  html[data-theme] #app #txSum .txsum-row {
    display: flex !important;
    flex-wrap: nowrap !important;
    align-items: stretch;
    gap: 8px !important;
  }
  html[data-theme] #app #txSum .txsum-d {
    flex: 0 0 236px !important;
    width: 236px !important;
    min-width: 0;
  }
  html[data-theme] #app #txSum .txprog span {
    white-space: nowrap;
    font-size: 12px;
  }
  html[data-theme] #app #txSum .txmore {
    display: none !important;
  }
  html[data-theme] #app #txSum .txstats {
    align-items: stretch !important;
    display: grid !important;
    grid-template-columns: repeat(5, minmax(0, 1fr)) !important;
    gap: 6px !important;
    flex: 1 1 auto;
    min-width: 0;
    margin: 0 !important;
  }
  html[data-theme] #app #txSum .ts {
    height: auto !important;
    min-width: 0;
    padding: 0 6px !important;
    gap: 6px;
  }
  html[data-theme] #app #txSum .ts span {
    font-size: 8.5px;
    letter-spacing: 0.06em;
    white-space: nowrap;
  }

  /* ---- Guests / Servers: the chosen one's numbers three to a row in the narrower right panel ---- */
  html[data-theme] #app .split .r .kpis {
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
  }

  /* ---- Audit: title, filters and Refresh share the top line; the log gets the rest ---- */
  html[data-theme] #app #main > .view:has(#aList) {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    grid-template-rows: auto minmax(0, 1fr);
  }
  html[data-theme] #app #main > .view:has(#aList) > header.audtop {
    grid-column: 1;
    grid-row: 1;
    padding-right: 4px !important;
  }
  html[data-theme] #app #main > .view:has(#aList) > .filters {
    grid-column: 2;
    grid-row: 1;
    align-self: stretch;
    display: flex;
    align-items: center;
    flex-wrap: nowrap;
    gap: 8px;
    padding: calc(12px + var(--sa-t)) 16px 12px 0 !important;
    margin: 0 !important;
    min-width: 0;
  }
  html[data-theme] #app #main > .view:has(#aList) > .filters select {
    width: 136px !important;
    flex: 0 0 136px !important;
    min-width: 0;
    height: 36px;
  }
  html[data-theme] #app #main > .view:has(#aList) > .filters .search {
    width: auto !important;
    flex: 1 1 0 !important;
    min-width: 0 !important;
  }
  html[data-theme] #app #main > .view:has(#aList) > .filters .search input {
    width: 100% !important;
    min-width: 0 !important;
    height: 36px !important;
  }
  html[data-theme] #app #main > .view:has(#aList) > .auditwrap {
    grid-column: 1 / -1;
    grid-row: 2;
    min-height: 0;
  }

  /* ---- The right-hand panel on Texts, Guests and Servers: the phone layout of the card, which suits its width ---- */
  html[data-theme] #app .split .r .profile {
    padding: 16px 16px 32px;
  }
  html[data-theme] #app .split .r .profile .ph {
    padding: 16px;
    flex-wrap: wrap;
    align-items: flex-start;
  }
  html[data-theme] #app .split .r .profile .ph > div:last-child {
    flex-wrap: wrap;
    width: 100%;
    padding-left: 0;
    flex-direction: row !important;
    align-items: center !important;
  }
  html[data-theme] #app .split .r .profile > .sec {
    padding: 14px 16px 16px;
  }
  html[data-theme] #app .split .r .profile > .sec h4 {
    margin: -14px -16px 14px;
    padding: 11px 16px;
  }

  /* ---- Staff: Add Staff Member on the title line; the list shows each person's role and last sign-in ---- */
  html[data-theme] #app #main > .view:has(#sList) > header.top {
    padding: calc(12px + var(--sa-t)) 16px 0 !important;
    flex-wrap: nowrap !important;
    align-items: center !important;
    gap: 10px !important;
  }
  html[data-theme] #app #main > .view:has(#sList) > header.top .eyebrow {
    font-size: 9px;
  }
  html[data-theme] #app #main > .view:has(#sList) > header.top h1 {
    font-size: 21px;
    line-height: 1.1;
    margin-top: 2px;
  }
  html[data-theme] #app #main > .view:has(#sList) > header.top .title {
    flex: 1 1 auto !important;
  }
  html[data-theme] #app #main > .view:has(#sList) > header.top .tools {
    margin-left: auto !important;
    flex: none !important;
  }
  html[data-theme] #app #main > .view:has(#sList) > header.top .tools .btn {
    height: 36px;
  }
  html[data-theme] #app #main > .view:has(#sList) > .filters {
    padding: 8px 16px 12px !important;
    margin: 0 !important;
    font-size: 12px !important;
  }
  html[data-theme] #app #main > .view:has(#sList) .srow {
    grid-template-columns: 44px minmax(0, 1fr) 110px 200px auto;
  }
  html[data-theme] #app #main > .view:has(#sList) .srow .hide-m {
    display: block;
  }
}
/* Texts, iPad / desktop: the booking panel scrolls inside its own box, which is new for each booking (see
   txDetPut) — the panel itself no longer scrolls */
#xSplit > #txDetail {
  overflow: hidden;
}
#txDetail > .txdscroll {
  height: 100%;
  overflow-y: auto;
  overscroll-behavior: contain;
}
/* Audit / activity: a value that was cleared reads "removed" (see chTo) */
.gone {
  font-style: italic;
  color: var(--faint);
}
/* Texts: a new message arriving (see txSlideIn) — it fades in with a soft pulse: up, dips, then settles */
.rprow.txarrive {
  animation: txMsgArrive 1300ms ease-in-out both;
}
@keyframes txMsgArrive {
  0% {
    opacity: 0;
  }
  30% {
    opacity: 0.7;
  }
  55% {
    opacity: 0.35;
  }
  100% {
    opacity: 1;
  }
}
/* Texts, the booking's buttons: each lights up in its own color on hover — Confirm Manually yellow, Call green,
   Open Booking blue (the Today button's look) */
@media (hover: hover) {
  html[data-theme] .txacts .btn.hv-yellow:hover {
    --hv: #facc15;
  }
  html[data-theme] .txacts .btn.hv-green:hover {
    --hv: #4ade80;
  }
  html[data-theme] .txacts .btn.hv-blue:hover {
    --hv: #7db5fb;
  }
  html[data-theme="light"] .txacts .btn.hv-yellow:hover {
    --hv: #a16207;
  }
  html[data-theme="light"] .txacts .btn.hv-green:hover {
    --hv: #15803d;
  }
  html[data-theme="light"] .txacts .btn.hv-blue:hover {
    --hv: #2563eb;
  }
  html[data-theme] .txacts .btn.hv-yellow:hover,
  html[data-theme] .txacts .btn.hv-green:hover,
  html[data-theme] .txacts .btn.hv-blue:hover {
    color: var(--hv);
    background: color-mix(in srgb, var(--hv) 10%, transparent);
    border-color: transparent;
    box-shadow: inset 0 0 0 1.5px var(--hv);
  }
  html[data-theme] .txacts .btn.hv-yellow:hover svg,
  html[data-theme] .txacts .btn.hv-green:hover svg,
  html[data-theme] .txacts .btn.hv-blue:hover svg {
    color: var(--hv);
  }
}

/* Day strip: scrolls sideways through the days (swipe on iPhone / iPad, drag or wheel with a mouse) with no
   scrollbar. Seven days in view (six on phones and iPhone Duo), each snapping into place; the gap matches the
   strip's own (--sg, set by renderStrip). */
html[data-theme] #app #bookView #bkStrip {
  overflow: visible !important;
}
html[data-theme] #app #bookView #bkStrip > .sscroll {
  --sn: 7;
  display: flex;
  gap: inherit;
  flex: 1 1 auto;
  min-width: 0;
  overflow-x: auto;
  overflow-y: hidden;
  scroll-snap-type: x mandatory;
  overscroll-behavior-x: contain;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  touch-action: pan-x pan-y;
}
html[data-theme] #app #bookView #bkStrip > .sscroll::-webkit-scrollbar {
  display: none;
}
html[data-theme] #app #bookView #bkStrip > .sscroll.dragging {
  scroll-snap-type: none;
  cursor: grabbing;
}
html[data-theme] #app #bookView #bkStrip > .sscroll.dragging .day {
  cursor: grabbing;
}
html[data-theme] #app #bookView #bkStrip > .sscroll > .day {
  flex: 0 0 calc((100% - (var(--sn) - 1) * var(--sg, 6px)) / var(--sn)) !important;
  width: auto !important;
  min-width: 0 !important;
  scroll-snap-align: start;
  scroll-snap-stop: normal;
}
@media (max-width: 760px) {
  html[data-theme] #app #bookView #bkStrip > .sscroll {
    --sn: 6;
  }
}
@media (min-width: 880px) and (max-width: 900px) and (max-height: 660px) {
  html[data-theme] #app #bookView #bkStrip > .sscroll {
    --sn: 6;
  }
}

/* Guests list sections (Recent searches, VIP guests, Most booked guests): tapping a title closes / opens its
   section — the arrow points down while it's open, right when it's closed. Recent searches has Clear on the right. */
html[data-theme] .gpane .gsec-h {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  cursor: pointer;
  -webkit-user-select: none;
  user-select: none;
}
.gsec-t {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.gsec-t svg {
  width: 14px;
  height: 14px;
  transform: rotate(90deg);
  transition: transform 0.15s ease;
}
.gsec.shut .gsec-t svg {
  transform: none;
}
.gsec.shut .gsec-b {
  display: none;
}
html[data-theme] .gpane .gsec-h .gsec-x {
  appearance: none;
  margin: -6px -8px -6px 0;
  padding: 6px 8px;
  border: 0;
  border-radius: 6px;
  background: none;
  color: var(--sub);
  font: inherit;
  letter-spacing: inherit;
  text-transform: inherit;
  cursor: pointer;
}
html[data-theme] .gpane .gsec-h .gsec-x:hover {
  color: var(--text);
}
/* a line between sections; 8px above the next title when the section before it is open */
html[data-theme] .split .l.gpane .gsec:not(.shut) + .gsec {
  margin-top: 8px;
}
html[data-theme] .split .l.gpane .gsec:not(.shut) + .gsec .aday {
  border-top: 1px solid var(--line);
}
html[data-theme] .split .l.gpane .gsec-b > .gl:first-child {
  margin-top: 8px;
}
/* Guests and Servers lists: the same 8px between a section title and its first entry as between a section's last
   entry and the next title, so a highlighted (hovered or picked) entry has equal space above and below */
html[data-theme] .split .l.gpane .aday + .gl {
  margin-top: 8px;
}
html[data-theme] .split .l.gpane .gl + .aday {
  margin-top: 8px;
}

/* Walk-in sheet: the quick "Walk In" guest button under the name (Seat now) */
.wk-cq {
  margin-top: 10px;
}
.wk-cq .chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
/* sized to its words, not stretched across the row like the form's other button rows */
.ed.wk .chips.wk-cq > .chip {
  flex: 0 0 auto !important;
  width: auto !important;
  min-width: 0 !important;
  padding-left: 16px;
  padding-right: 18px;
}
.wk-cq .chip svg {
  width: 15px;
  height: 15px;
}
/* hidden on the waitlist and once a guest is chosen (beats the form's "button rows always show" rule) */
.ed.wk .chips.wk-cq[hidden] {
  display: none !important;
}
