/* ─── Tabs ───────────────────────────────────────────────────────────────────── */
.tabs {
  display: flex; gap: 0;
  margin-bottom: 20px;
  border-bottom: 1px solid var(--border, rgba(0,0,0,0.06));
}
.tab {
  background: transparent; border: none; cursor: pointer;
  font-family: var(--font-body, 'Montserrat', sans-serif);
  font-weight: 600; font-size: 11px; letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--fg-faint, #888);
  padding: 14px 24px;
  position: relative;
  transition: color 0.2s ease-out;
}
.tab:hover { color: var(--fg-strong, #0A0A0A); }
.tab.active { color: var(--fg-strong, #0A0A0A); }
.tab.active::after {
  content: '';
  position: absolute; bottom: -1px; left: 0; right: 0;
  height: 2px;
  background: var(--gold, #B79B58);
}

/* ─── Picker row ─────────────────────────────────────────────────────────────── */
.picker-row {
  display: flex; align-items: center; gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 24px;
  padding: 16px 20px;
  background: #fff;
  border: 1px solid rgba(0,0,0,0.04);
  border-radius: var(--radius-lg, 16px);
  box-shadow: var(--shadow-subtle, 0 1px 3px rgba(0,0,0,0.06));
}
.picker {
  display: flex; align-items: center; gap: 12px;
  flex-wrap: wrap;
}
.picker.hidden { display: none; }
.picker-label {
  font-size: 10px; letter-spacing: 0.18em; text-transform: uppercase;
  font-weight: 600; color: var(--fg-faint, #888);
}
.picker input[type="date"],
.picker input[type="week"],
.picker input[type="month"] {
  font-family: var(--font-body, 'Montserrat', sans-serif);
  font-size: 13px; font-weight: 500;
  padding: 8px 12px;
  border: 1px solid var(--border-strong, rgba(0,0,0,0.12));
  border-radius: var(--radius-md, 8px);
  background: var(--bg-soft, #FAF9F7);
  color: var(--fg-strong, #0A0A0A);
  cursor: pointer;
}
.picker input:focus {
  outline: none;
  border-color: var(--gold, #B79B58);
}
.btn-sm {
  padding: 6px 14px;
  font-size: 10px;
  letter-spacing: 0.1em;
}
.range-label {
  margin-left: auto;
  font-family: var(--font-display, 'Cormorant Garamond', Georgia, serif);
  font-weight: 500; font-size: 16px;
  color: var(--fg-strong, #0A0A0A);
  letter-spacing: -0.01em;
}

/* ─── Summary bar overrides ──────────────────────────────────────────────────── */
.stat-pill.bad .stat-n { color: #B91C1C; }

/* ─── Report sections ────────────────────────────────────────────────────────── */
.report-section {
  margin-top: 36px;
}
.section-head {
  display: flex; justify-content: space-between; align-items: flex-end;
  gap: 16px; flex-wrap: wrap;
  margin-bottom: 14px;
}
.section-eyebrow {
  font-family: var(--font-body, 'Montserrat', sans-serif);
  font-weight: 600;
  font-size: 11px;
  letter-spacing: 0.36em;
  text-transform: uppercase;
  color: var(--gold, #B79B58);
  display: inline-flex; align-items: center; gap: 12px;
  margin-bottom: 6px;
}
.section-eyebrow::before {
  content: ''; width: 24px; height: 1px;
  background: var(--gold, #B79B58);
}
.section-title {
  font-family: var(--font-display, 'Cormorant Garamond', Georgia, serif);
  font-weight: 500;
  font-size: clamp(22px, 2.4vw, 30px);
  line-height: 1.1;
  letter-spacing: -0.02em;
  color: var(--fg-strong, #0A0A0A);
}
.section-title em { font-style: italic; color: var(--gold, #B79B58); font-weight: 400; }

.filter-row {
  display: flex; align-items: center; gap: 12px;
}
.filter-toggle {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: 11px; font-weight: 600;
  letter-spacing: 0.08em; text-transform: uppercase;
  color: var(--fg-muted, #575760); cursor: pointer;
  user-select: none;
}
.filter-toggle input {
  accent-color: var(--gold, #B79B58);
  width: 14px; height: 14px;
  cursor: pointer;
}

/* ─── Tables ─────────────────────────────────────────────────────────────────── */
.table-wrap {
  background: #fff;
  border: 1px solid rgba(0,0,0,0.04);
  border-radius: var(--radius-lg, 16px);
  overflow: hidden;
  box-shadow: var(--shadow-subtle, 0 1px 3px rgba(0,0,0,0.06));
}
.report-table {
  width: 100%;
  border-collapse: collapse;
  font-family: var(--font-body, 'Montserrat', sans-serif);
}
.report-table thead {
  background: var(--bg-muted, #F5F4F1);
}
.report-table th {
  text-align: left;
  font-size: 10px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  font-weight: 700;
  color: var(--fg-muted, #575760);
  padding: 14px 16px;
  border-bottom: 1px solid var(--border, rgba(0,0,0,0.06));
}
.report-table th.num { text-align: right; }
.report-table td {
  font-size: 13px;
  font-weight: 500;
  color: var(--fg-strong, #0A0A0A);
  padding: 12px 16px;
  border-bottom: 1px solid var(--border, rgba(0,0,0,0.04));
  vertical-align: middle;
}
.report-table td.num {
  text-align: right;
  font-variant-numeric: tabular-nums;
}
.report-table tbody tr:last-child td { border-bottom: none; }
.report-table tbody tr:hover { background: var(--bg-soft, #FAF9F7); }
.report-table .tail-cell {
  font-family: var(--font-display, 'Cormorant Garamond', Georgia, serif);
  font-weight: 500;
  letter-spacing: -0.01em;
}
.report-table .muted { color: var(--fg-faint, #888); font-weight: 400; }
.report-table .empty-row {
  text-align: center;
  color: var(--fg-faint, #888);
  font-weight: 500;
  padding: 32px 16px;
}

/* Status badges in the per-reservation table */
.badge {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 3px 10px;
  border-radius: var(--radius-full, 9999px);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}
.badge::before {
  content: '';
  width: 6px; height: 6px;
  border-radius: 50%;
}
.badge.ontime { background: rgba(183,155,88,0.10); color: var(--gold-dark, #9A8145); }
.badge.ontime::before { background: var(--gold, #B79B58); }
.badge.late   { background: rgba(220,38,38,0.08); color: #B91C1C; }
.badge.late::before { background: #DC2626; }
.badge.early  { background: rgba(183,155,88,0.10); color: var(--gold-dark, #9A8145); }
.badge.early::before { background: var(--gold, #B79B58); }
.badge.missing { background: rgba(0,0,0,0.05); color: var(--fg-muted, #575760); }
.badge.missing::before { background: var(--fg-faint, #888); }

.delta-cell.late  { color: #B91C1C; font-weight: 700; }
.delta-cell.early { color: var(--gold-dark, #9A8145); font-weight: 700; }
.delta-cell.ontime { color: var(--fg-strong, #0A0A0A); font-weight: 700; }

/* ─── Night Stacking ─────────────────────────────────────────────────────────── */
.run-select {
  font-family: var(--font-body, 'Montserrat', sans-serif);
  font-size: 13px; font-weight: 500;
  padding: 8px 12px;
  border: 1px solid var(--border-strong, rgba(0,0,0,0.12));
  border-radius: var(--radius-md, 8px);
  background: var(--bg-soft, #FAF9F7);
  color: var(--fg-strong, #0A0A0A);
  cursor: pointer;
  min-width: 280px;
}
.run-select:focus { outline: none; border-color: var(--gold, #B79B58); }

.rule-note {
  background: var(--gold-subtle, rgba(183,155,88,0.08));
  border-left: 3px solid var(--gold, #B79B58);
  border-radius: var(--radius-md, 8px);
  padding: 14px 18px 16px;
  font-size: 13px;
  line-height: 1.6;
  color: var(--fg-muted, #575760);
  margin-bottom: 16px;
}
.rule-note strong { color: var(--fg-strong, #0A0A0A); font-weight: 700; }
.rule-note ul {
  list-style: none;
  margin: 8px 0 8px 0;
  padding: 0;
}
.rule-note ul li {
  position: relative;
  padding-left: 18px;
  margin-bottom: 4px;
}
.rule-note ul li::before {
  content: '';
  position: absolute;
  left: 4px; top: 9px;
  width: 4px; height: 4px;
  border-radius: 50%;
  background: var(--gold, #B79B58);
}
.rule-note em { font-style: italic; color: var(--gold-dark, #9A8145); font-weight: 600; }

/* ─── Criteria card (Night Stacking top-of-page reference) ───────────────── */
.criteria-card {
  background: #fff;
  border: 1px solid rgba(0,0,0,0.04);
  border-radius: var(--radius-lg, 16px);
  box-shadow: var(--shadow-subtle, 0 1px 3px rgba(0,0,0,0.06));
  padding: 28px clamp(20px, 3vw, 36px);
  margin-bottom: 24px;
}
.criteria-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(20px, 3vw, 40px);
}
@media (max-width: 880px) {
  .criteria-grid { grid-template-columns: 1fr; }
}
.criteria-col { min-width: 0; }
.criteria-eyebrow {
  font-family: var(--font-display, 'Cormorant Garamond', Georgia, serif);
  font-weight: 500;
  font-size: clamp(18px, 1.8vw, 22px);
  letter-spacing: -0.01em;
  color: var(--fg-strong, #0A0A0A);
  margin-bottom: 12px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--border, rgba(0,0,0,0.06));
}
.criteria-lede {
  font-size: 13px;
  line-height: 1.6;
  color: var(--fg-muted, #575760);
  margin-bottom: 12px;
}
.criteria-lede strong { color: var(--fg-strong, #0A0A0A); font-weight: 700; }

.criteria-list {
  list-style: none;
  margin: 0 0 14px 0;
  padding: 0;
  font-size: 13px;
  line-height: 1.65;
  color: var(--fg-muted, #575760);
}
.criteria-list > li {
  position: relative;
  padding-left: 18px;
  margin-bottom: 6px;
}
.criteria-list > li::before {
  content: '';
  position: absolute;
  left: 4px; top: 10px;
  width: 4px; height: 4px;
  border-radius: 50%;
  background: var(--gold, #B79B58);
}
.criteria-list strong { color: var(--fg-strong, #0A0A0A); font-weight: 700; }
.criteria-list a {
  color: var(--gold-dark, #9A8145);
  border-bottom: 1px solid var(--gold-glow, rgba(183,155,88,0.3));
}
.criteria-list a:hover { color: var(--gold, #B79B58); border-bottom-color: var(--gold, #B79B58); }
.criteria-list ul {
  list-style: none;
  margin: 4px 0 4px 6px;
  padding: 0;
}
.criteria-list ul > li {
  position: relative;
  padding-left: 16px;
  margin-bottom: 3px;
  font-size: 12.5px;
}
.criteria-list ul > li::before {
  content: '';
  position: absolute;
  left: 4px; top: 11px;
  width: 4px; height: 1px;
  background: var(--fg-faint, #888);
}

.criteria-warn {
  background: var(--gold-subtle, rgba(183,155,88,0.08));
  border-left: 3px solid var(--gold, #B79B58);
  border-radius: var(--radius-sm, 4px);
  padding: 10px 14px;
  font-size: 12.5px;
  line-height: 1.55;
  color: var(--fg-strong, #0A0A0A);
  margin-top: 8px;
}
.criteria-warn strong { color: var(--gold-dark, #9A8145); }

.criteria-link {
  display: inline-flex; align-items: center; gap: 6px;
  margin-top: 24px;
  padding-top: 16px;
  border-top: 1px solid var(--border, rgba(0,0,0,0.06));
  font-family: var(--font-body, 'Montserrat', sans-serif);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--gold, #B79B58);
  width: 100%;
}
.criteria-link:hover { color: var(--gold-dark, #9A8145); }

.ns-status-col { min-width: 200px; }
.ns-action-col { width: 1%; white-space: nowrap; }

.ns-checks {
  display: flex; flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 6px;
}
.ns-check {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 11px; font-weight: 600;
  letter-spacing: 0.06em; text-transform: uppercase;
  color: var(--fg-muted, #575760);
  cursor: pointer; user-select: none;
}
.ns-check input {
  accent-color: var(--gold, #B79B58);
  width: 16px; height: 16px;
  cursor: pointer;
}
.ns-status-line { line-height: 1; }

/* Red NEEDS UPDATE pill — overrides .badge.late color hierarchy */
.badge.ns-needs {
  background: rgba(220,38,38,0.10);
  color: #B91C1C;
  font-weight: 700;
}
.badge.ns-needs::before { background: #DC2626; }
.badge.ns-reviewed {
  background: rgba(183,155,88,0.12);
  color: var(--gold-dark, #9A8145);
}

.report-table tr.ns-row-done td { opacity: 0.6; }
.report-table tr.ns-row-done td .badge,
.report-table tr.ns-row-done td .btn { opacity: 1; }
