:root {
  --bg: #f4f5f7;
  --ink: #001848;
  --muted: #5f6b7a;
  --line: #d8dee6;
  --card: #ffffff;
  --navy: #001848;
  --cyan: #00c0c8;
  --accent: #001848;
  --accent-ink: #ffffff;
  --warn: #8a4b08;
  --done: #2e7d4f;
}
* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  font-family: "Segoe UI", system-ui, sans-serif;
  background: var(--bg);
  color: var(--ink);
  line-height: 1.45;
}
a { color: #007a8a; }
.app {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 220px 1fr;
}
.side {
  background: var(--navy);
  color: #e5e7eb;
  padding: 20px 14px;
}
.side a { color: #e5e7eb; text-decoration: none; display: block; padding: 8px 10px; border-radius: 6px; }
.side a:hover, .side a.active { background: #1f2937; }
.side a.brand,
.guest-bar .brand {
  display: flex; align-items: center; gap: 10px; margin: 0 4px 18px; padding: 4px 6px;
  text-decoration: none;
}
.side a.brand:hover { background: transparent; }
.brand-logo { height: 22px; width: auto; display: block; }
.brand-name {
  font-weight: 700; letter-spacing: .06em; text-transform: uppercase; font-size: 15px;
  color: #e5e7eb;
}
.guest-bar { padding: 16px 20px; }
.guest-bar .brand { margin: 0; }
.guest-bar .brand-name { color: var(--navy); }
.main { padding: 24px 28px 48px; }
.top {
  display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-bottom: 20px;
}
h1 { font-size: 26px; margin: 0 0 8px; font-weight: 650; }
h2 { font-size: 18px; margin: 24px 0 10px; }
h3 { font-size: 16px; margin: 0 0 8px; }
.lead, .muted { color: var(--muted); }
.card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 16px 18px;
  margin-bottom: 14px;
}
label { display: block; font-size: 13px; font-weight: 600; margin: 12px 0 6px; }
input, textarea, select {
  width: 100%; padding: 10px 12px; border: 1px solid var(--line); border-radius: 8px; font: inherit; background: #fff;
}
textarea { min-height: 72px; }
.row { display: flex; gap: 10px; flex-wrap: wrap; align-items: end; }
.row > * { flex: 1; min-width: 140px; }
.btn {
  display: inline-block; border: 0; border-radius: 8px; padding: 10px 14px; font: inherit; font-weight: 600;
  background: var(--accent); color: var(--accent-ink); cursor: pointer; text-decoration: none;
}
.btn.ghost { background: #fff; color: var(--ink); border: 1px solid var(--line); }
.btn.small { padding: 6px 10px; font-size: 13px; }
.btn.danger { background: #fff; color: #9b1c1c; border: 1px solid #fecaca; }
.flash { background: #ecfdf3; border: 1px solid #bbf7d0; color: #14532d; padding: 10px 12px; border-radius: 8px; margin-bottom: 12px; }
.flash.err { background: #fef2f2; border-color: #fecaca; color: #9b1c1c; }
.pill { display: inline-block; font-size: 12px; font-weight: 650; padding: 2px 8px; border-radius: 999px; background: #e5e7eb; }
.pill.expired { background: #fee2e2; color: #9b1c1c; }
.pill.soon { background: #ffedd5; color: var(--warn); }
.pill.current { background: #dcfce7; color: var(--done); }
.pill.none { background: #e5e7eb; color: var(--muted); }
table.board { width: 100%; border-collapse: collapse; background: #fff; border: 1px solid var(--line); border-radius: 10px; overflow: hidden; }
table.board th, table.board td { text-align: left; padding: 10px 12px; border-bottom: 1px solid var(--line); font-size: 14px; }
table.board th { font-size: 12px; text-transform: uppercase; letter-spacing: .04em; color: var(--muted); background: #f9fafb; }
.hero {
  max-width: 720px; margin: 56px auto; padding: 0 16px;
}
.form-card { max-width: 720px; }
.meter { margin: 0 0 14px; }
.meter-top { display: flex; justify-content: space-between; font-size: 13px; color: var(--muted); margin-bottom: 6px; }
.meter-track { height: 10px; background: #e5e7eb; border-radius: 999px; overflow: hidden; }
.meter-fill { height: 100%; background: var(--navy); }
.gap { border-left: 3px solid var(--cyan); padding-left: 12px; margin-bottom: 10px; }
.status-btns { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.status-btns button { font-size: 13px; }
.notice { background: #fff7ed; border: 1px solid #fed7aa; color: #9a3412; padding: 10px 12px; border-radius: 8px; margin-bottom: 12px; }
.rollup {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 10px;
  margin-bottom: 10px;
}
.rollup > summary {
  cursor: pointer;
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
  padding: 12px 14px;
}
.rollup > summary::-webkit-details-marker { display: none; }
.rollup-name { font-weight: 700; flex: 1 1 auto; }
.rollup-body { padding: 4px 14px 14px; border-top: 1px solid var(--line); }
.wizard-steps {
  display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 18px;
}
.wizard-step {
  display: inline-block; padding: 6px 10px; border-radius: 999px;
  background: #e5e7eb; color: var(--ink); text-decoration: none; font-size: 13px; font-weight: 600;
}
.wizard-step.current { background: var(--navy); color: #fff; }
.wizard-nav { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; margin-top: 18px; }
.wizard-inline { display: inline; margin: 0; }
.onboard-pack h3 { margin: 16px 0 8px; }
.overlap-card { margin-bottom: 12px; }
@media (max-width: 800px) {
  .app { grid-template-columns: 1fr; }
  .side { display: flex; flex-wrap: wrap; gap: 4px; }
  .side a.brand { flex: 1 1 100%; margin-bottom: 8px; }
}
@media print {
  .side, .guest-bar, .no-print, form, .flash, .flash.err { display: none !important; }
  .app { display: block; }
  .main, main { padding: 0; }
  body { background: #fff; color: #000; }
  a { color: #000; text-decoration: none; }
  .card, .board { break-inside: avoid; }
}
