:root {
  --bg: #0f1115;
  --panel: #171a21;
  --panel2: #202633;
  --text: #f6f7fb;
  --muted: #aeb6c5;
  --line: rgba(255, 255, 255, .12);
  --accent: #00d4ff;
  --accent2: #2d6cff;
  --good: #1fb66b;
  --warn: #f4c430;
  --bad: #ef4444;
  --orange: #f97316;
  --shadow: 0 20px 58px rgba(0, 0, 0, .38);
  --radius: 15px;
}

* { box-sizing: border-box; }
body {
  margin: 0;
  font-family: Inter, Arial, Helvetica, sans-serif;
  background:
    radial-gradient(circle at top left, rgba(0, 212, 255, .14), transparent 32rem),
    radial-gradient(circle at bottom right, rgba(249, 115, 22, .09), transparent 32rem),
    var(--bg);
  color: var(--text);
}
button, input, select, textarea { font: inherit; }
button { cursor: pointer; }
button:disabled { cursor: not-allowed; }
.hidden { display: none !important; }

.topbar {
  position: sticky;
  top: 0;
  z-index: 30;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 18px;
  padding: 13px 18px;
  border-bottom: 1px solid var(--line);
  background: rgba(15, 17, 21, .86);
  backdrop-filter: blur(14px);
}
.brand { display: flex; align-items: center; gap: 10px; min-width: 210px; }
.brand-mark {
  width: 36px;
  height: 36px;
  border-radius: 11px;
  display: grid;
  place-items: center;
  background: linear-gradient(135deg, var(--accent), var(--accent2));
  font-weight: 900;
  font-size: 14px;
}
.brand strong { display: block; font-size: 15px; }
.brand span { display: block; color: var(--muted); font-size: 11px; font-weight: 700; }
.nav { display: flex; flex-wrap: wrap; gap: 7px; justify-content: flex-end; }
.nav-link {
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, .05);
  color: var(--muted);
  border-radius: 999px;
  padding: 8px 10px;
  font-weight: 800;
  font-size: 12px;
}
.nav-link.active, .nav-link:hover {
  background: #07586a;
  color: #ffffff;
  border-color: rgba(0, 212, 255, .45);
}
.nav-divider { width: 1px; background: var(--line); margin: 0 4px; }

.page { display: none; max-width: 1160px; margin: 0 auto; padding: 34px 18px; }
.page.active { display: block; }
.hero {
  display: grid;
  grid-template-columns: 1.1fr .9fr;
  gap: 26px;
  align-items: center;
  padding: 24px 0;
}
.eyebrow {
  margin: 0 0 8px;
  color: var(--accent);
  text-transform: uppercase;
  letter-spacing: .12em;
  font-weight: 900;
  font-size: 11px;
}
h1 { margin: 0 0 14px; font-size: clamp(34px, 5vw, 58px); line-height: .98; letter-spacing: -.055em; }
h2 { margin: 0 0 9px; font-size: clamp(26px, 3.4vw, 38px); letter-spacing: -.04em; }
h3 { margin: 0 0 10px; font-size: 19px; letter-spacing: -.02em; }
.lead, p { color: var(--muted); line-height: 1.5; }
.lead { font-size: 16px; max-width: 640px; }
.actions, .form-actions { display: flex; gap: 10px; flex-wrap: wrap; }
.btn {
  border: 0;
  border-radius: 999px;
  padding: 10px 14px;
  font-weight: 900;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 42px;
}
.btn.primary { background: linear-gradient(135deg, var(--accent), var(--accent2)); color: white; }
.btn.secondary { background: #303745; border: 1px solid #5b6474; color: #ffffff; }
.btn.danger { background: #641f28; border: 1px solid #a94755; color: #ffd1d1; }
.wide-button { width: 100%; }

.hero-panel, .content-card, .panel {
  background: linear-gradient(180deg, rgba(255, 255, 255, .07), rgba(255, 255, 255, .035));
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 18px;
}
.hero-panel li { margin: 10px 0; color: var(--muted); }
.section-head, .internal-banner { display: flex; justify-content: space-between; align-items: flex-end; gap: 18px; margin-bottom: 18px; }
.filters { display: flex; gap: 8px; flex-wrap: wrap; }
.filter {
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 8px 11px;
  background: rgba(255, 255, 255, .05);
  color: var(--muted);
  font-weight: 800;
  font-size: 13px;
}
.filter.active { background: #07586a; color: #ffffff; border-color: #1592ad; }
.class-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
.class-card {
  border: 1px solid var(--line);
  background: linear-gradient(180deg, rgba(255, 255, 255, .07), rgba(255, 255, 255, .035));
  border-radius: var(--radius);
  padding: 17px;
  min-height: 280px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  position: relative;
  overflow: hidden;
}
.class-card:before { content: ""; position: absolute; top: 0; left: 0; right: 0; height: 4px; background: var(--accent); }
.class-card.family:before { background: var(--orange); }
.class-card.drug:before { background: var(--good); }
.class-card.vip:before { background: var(--warn); }
.card-top { display: flex; justify-content: space-between; gap: 10px; align-items: flex-start; }
.tag {
  background: rgba(0, 212, 255, .16);
  border: 1px solid rgba(0, 212, 255, .35);
  border-radius: 999px;
  padding: 6px 9px;
  font-weight: 900;
  font-size: 11px;
}
.price { font-size: 23px; font-weight: 900; letter-spacing: -.04em; }
.meta { display: grid; gap: 7px; color: var(--muted); font-size: 13px; }
.seat-good { color: #b6ffd7; }
.seat-warn { color: #ffe79c; }
.seat-full { color: #ffb4b4; }
.content-card.narrow { max-width: 760px; margin: 0 auto; }
.help-grid, .stats, .export-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.help-grid > div, .stat, .export-card { border: 1px solid var(--line); background: rgba(255, 255, 255, .045); border-radius: 13px; padding: 14px; }
.help-grid strong, .help-grid span { display: block; }
.help-grid span { color: var(--muted); margin-top: 6px; }

.internal-banner { background: rgba(0, 212, 255, .06); border: 1px solid rgba(0, 212, 255, .20); border-radius: 18px; padding: 16px; }
.stat b { display: block; color: var(--muted); font-size: 11px; text-transform: uppercase; letter-spacing: .08em; }
.stat span { display: block; font-size: 24px; font-weight: 900; margin-top: 5px; }
.manager-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin-bottom: 14px; }
.form-card { box-shadow: none; }
form { display: grid; gap: 11px; }
label { display: grid; gap: 6px; color: var(--muted); font-weight: 800; font-size: 12px; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 11px; }
.wide { grid-column: 1 / -1; }
input, select, textarea {
  width: 100%;
  border: 1px solid var(--line);
  background: rgba(0, 0, 0, .22);
  color: white;
  border-radius: 11px;
  padding: 10px 11px;
  min-height: 42px;
  outline: none;
}
textarea { min-height: 92px; resize: vertical; }
input:focus, select:focus, textarea:focus { border-color: rgba(0, 212, 255, .7); }
.table-wrap { overflow: auto; }
.data-table { width: 100%; border-collapse: collapse; font-size: 12px; }
.data-table th, .data-table td { border-bottom: 1px solid var(--line); padding: 9px; text-align: left; vertical-align: top; }
.data-table th { color: #ffffff; background: #303745; position: sticky; top: 0; }
.filter-row { display: grid; grid-template-columns: repeat(3, 1fr); gap: 11px; margin-bottom: 14px; }
.admin-class-list { display: grid; gap: 14px; }
.admin-class { border: 1px solid var(--line); border-radius: 14px; background: rgba(255, 255, 255, .035); padding: 14px; }
.admin-class-head { display: flex; justify-content: space-between; gap: 11px; align-items: start; }
.date-chip { border: 1px solid var(--line); background: rgba(255, 255, 255, .05); border-radius: 12px; padding: 10px; margin: 9px 0; display: grid; grid-template-columns: 1.4fr repeat(5, auto); align-items: center; gap: 9px; }
.pill { border: 1px solid var(--line); border-radius: 999px; padding: 5px 8px; background: rgba(255, 255, 255, .05); color: var(--muted); font-size: 11px; font-weight: 800; }
.message { margin-top: 8px; color: #b6ffd7; min-height: 18px; }
.message.error { color: #ffb4b4; }

.modal-backdrop {
  position: fixed;
  inset: 0;
  width: 100vw;
  max-width: none;
  height: 100dvh;
  max-height: none;
  margin: 0;
  border: 0;
  background: transparent;
  color: inherit;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 14px;
}
.modal-backdrop[open] { display: flex; }
.modal-backdrop::backdrop { background: rgba(0, 0, 0, .72); }
.modal {
  width: min(1120px, 100%);
  max-height: 94vh;
  overflow: auto;
  background: #11151d;
  border: 1px solid var(--line);
  border-radius: 22px;
  box-shadow: var(--shadow);
}
.modal-head {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: start;
  padding: 18px;
  border-bottom: 1px solid var(--line);
  position: sticky;
  top: 0;
  background: rgba(17, 21, 29, .96);
  z-index: 2;
}
.modal-head p { margin: 0; }
.close { width: 38px; height: 38px; border-radius: 999px; border: 1px solid #5b6474; background: #303745; color: #ffffff; font-size: 22px; flex: 0 0 auto; }
.modal-body { display: grid; grid-template-columns: 1.05fr .95fr; gap: 16px; padding: 18px; }
.date-panel { min-width: 0; }
.date-picker-layout { display: grid; grid-template-columns: 1fr; gap: 12px; align-items: start; }
.date-helper { margin: 0 0 8px; }
.date-list { display: grid; gap: 9px; }
.date-option { border: 1px solid #4a5362; background: #242a36; color: #ffffff; text-align: left; border-radius: 13px; padding: 11px 12px; width: 100%; min-height: 64px; }
.date-option strong { display: block; font-size: 15px; line-height: 1.25; }
.date-option span { display: block; margin-top: 3px; color: var(--muted); font-size: 13px; }
.date-option:hover, .date-option.selected { background: rgba(0, 212, 255, .12); border-color: rgba(0, 212, 255, .62); }
.date-option.full { opacity: .55; cursor: not-allowed; }
.summary { border: 1px solid rgba(0, 212, 255, .25); background: rgba(0, 212, 255, .06); border-radius: 13px; padding: 11px; color: var(--muted); display: grid; gap: 7px; margin-bottom: 10px; font-size: 14px; }
.summary strong { color: white; }

.calendar-wrap { width: min(100%, 360px); min-width: 0; margin-top: 4px; }
.calendar { border: 1px solid var(--line); border-radius: 15px; background: rgba(255, 255, 255, .03); padding: 12px; }
.calendar-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 10px; }
.calendar-title { font-size: 14px; font-weight: 800; letter-spacing: -.01em; }
.calendar-nav { display: inline-flex; gap: 6px; }
.calendar-nav button { width: 30px; height: 30px; border-radius: 999px; border: 1px solid #5b6474; background: #303745; color: #ffffff; font-weight: 800; }
.calendar-nav button:disabled { opacity: .35; }
.calendar-weekdays, .calendar-grid { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 5px; }
.calendar-weekdays span { color: rgba(174, 182, 197, .82); font-size: 10px; text-align: center; font-weight: 700; text-transform: uppercase; }
.calendar-day {
  min-height: 42px;
  border: 1px solid rgba(255, 255, 255, .065);
  border-radius: 10px;
  background: rgba(0, 0, 0, .12);
  color: rgba(174, 182, 197, .72);
  padding: 5px;
  display: grid;
  align-content: start;
  gap: 2px;
  text-align: left;
}
.calendar-day:disabled { cursor: default; }
.calendar-day.blank { opacity: .22; pointer-events: none; }
.calendar-day.has-class { color: #ffffff; background: #07586a; border-color: #1592ad; cursor: pointer; }
.calendar-day.has-class:hover, .calendar-day.selected { background: rgba(0, 212, 255, .17); border-color: rgba(0, 212, 255, .72); }
.calendar-day.full { color: #ffb4b4; background: #5b2027; border-color: #a94755; cursor: not-allowed; }
.calendar-day.full:hover { background: #5b2027; border-color: #a94755; }
.calendar-day .day-num { font-size: 12px; font-weight: 500; }
.calendar-day.has-class .day-num { font-weight: 850; }
.calendar-day.selected .day-num { font-weight: 900; }
.calendar-day.full .day-num { font-weight: 800; }
.calendar-day .day-meta { font-size: 9px; color: rgba(174, 182, 197, .72); line-height: 1.15; }
.calendar-day.has-class .day-meta { color: #bdefff; font-weight: 700; }
.calendar-day.full .day-meta { color: #ffb4b4; font-weight: 700; }
.calendar-empty { color: var(--muted); font-size: 13px; margin: 0; }

.danger-zone { border-color: rgba(239, 68, 68, .28); }
.login-card { margin-top: 26px; }
.export-card a { color: white; font-weight: 900; text-decoration: none; }
.export-card a:hover { text-decoration: underline; }
.small-muted { font-size: 12px; color: var(--muted); }

@media (max-width: 1080px) {
  .modal-body { grid-template-columns: 1fr; }
  .date-picker-layout { grid-template-columns: 1fr; }
}

@media (max-width: 980px) {
  .topbar { display: block; }
  .brand { margin-bottom: 10px; }
  .nav { justify-content: flex-start; }
  .hero, .manager-grid { grid-template-columns: 1fr; }
  .class-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .help-grid, .stats, .export-grid, .filter-row { grid-template-columns: 1fr 1fr; }
  .date-chip { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 720px) {
  .section-head, .internal-banner { display: grid; align-items: start; }
  .date-picker-layout { grid-template-columns: 1fr; }
  .calendar-wrap { width: min(100%, 360px); }
  .calendar { padding: 10px; }
  .calendar-day { min-height: 40px; }
}

@media (max-width: 640px) {
  .page { padding: 22px 12px; }
  h1 { font-size: clamp(31px, 11vw, 42px); }
  h2 { font-size: clamp(23px, 8vw, 30px); }
  h3 { font-size: 17px; }
  .lead { font-size: 15px; }
  .class-grid, .help-grid, .stats, .export-grid, .filter-row, .form-grid { grid-template-columns: 1fr; }
  .class-card { min-height: 0; padding: 15px; }
  .hero-panel, .content-card, .panel { padding: 15px; }
  .modal-backdrop { align-items: stretch; padding: 7px; }
  .modal { max-height: 100%; border-radius: 16px; }
  .modal-head { padding: 14px; }
  .modal-body { padding: 14px; gap: 12px; }
  .close { width: 34px; height: 34px; font-size: 20px; }
  .date-option { min-height: 58px; }
  input, select, textarea, .btn { min-height: 44px; }
  .calendar-weekdays, .calendar-grid { gap: 4px; }
  .calendar-day { min-height: 38px; border-radius: 9px; padding: 4px; }
  .calendar-day .day-meta { display: none; }
}

@media (max-width: 420px) {
  .topbar { padding: 11px 12px; }
  .brand { min-width: 0; }
  .nav-link { padding: 7px 9px; font-size: 11px; }
  .price { font-size: 21px; }
  .calendar-day { min-height: 34px; }
  .calendar-day .day-num { font-size: 11px; }
}

/* v9 staging/backups admin panel */
.settings-divider {
  height: 1px;
  background: rgba(148, 163, 184, 0.2);
  margin: 1.4rem 0;
}

.backup-header {
  align-items: center;
  display: flex;
  gap: 1rem;
  justify-content: space-between;
  margin-bottom: 1rem;
}

.backup-list {
  display: grid;
  gap: 0.8rem;
  margin-top: 1rem;
}

.backup-card {
  align-items: center;
  background: rgba(15, 23, 42, 0.35);
  border: 1px solid rgba(148, 163, 184, 0.2);
  border-radius: 14px;
  display: flex;
  gap: 1rem;
  justify-content: space-between;
  padding: 0.9rem;
}

.backup-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  justify-content: flex-end;
}

@media (max-width: 720px) {
  .backup-header,
  .backup-card {
    align-items: stretch;
    flex-direction: column;
  }

  .backup-actions {
    justify-content: flex-start;
  }
}

/* v9.2 export timestamp clarity */
.export-status-card {
  grid-column: 1 / -1;
  border: 1px solid rgba(0, 212, 255, .24);
  background: rgba(0, 212, 255, .06);
  border-radius: 13px;
  padding: 14px;
}
.export-status-card h3 { margin-bottom: 6px; }
.export-meta-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin-top: 12px;
}
.export-meta-grid div {
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, .04);
  border-radius: 11px;
  padding: 10px;
}
.export-meta-grid strong,
.export-meta-grid span { display: block; }
.export-meta-grid strong {
  color: var(--muted);
  font-size: 11px;
  letter-spacing: .06em;
  text-transform: uppercase;
}
.export-meta-grid span {
  color: white;
  font-weight: 850;
  margin-top: 5px;
}
.primary-export-card {
  grid-column: 1 / -1;
  display: flex;
  justify-content: space-between;
  gap: 14px;
  align-items: center;
}

@media (max-width: 980px) {
  .export-meta-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 640px) {
  .export-meta-grid { grid-template-columns: 1fr; }
  .primary-export-card { display: grid; }
}

/* v9.7 SES test email controls */
.inline-form.notification-test-form {
  align-items: end;
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin: 1rem 0 0.5rem;
}

.inline-form.notification-test-form label {
  display: grid;
  flex: 1 1 260px;
  gap: 0.35rem;
  margin: 0;
}

.inline-form.notification-test-form input {
  min-width: 220px;
}

.consent-row {
  display: flex;
  align-items: flex-start;
  gap: 0.55rem;
  font-size: 0.78rem;
  line-height: 1.35;
  color: var(--muted, #cbd5e1);
}
.consent-row input[type="checkbox"] {
  width: auto;
  min-width: 1rem;
  height: 1rem;
  margin-top: 0.15rem;
  accent-color: var(--accent, #38bdf8);
}
.consent-row span {
  display: block;
}

.meeting-days {
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 0.9rem;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(86px, 1fr));
  gap: 0.5rem;
}
.meeting-days legend { font-weight: 700; padding: 0 0.35rem; }
.meeting-days label { flex-direction: row; align-items: center; gap: 0.35rem; font-size: 0.86rem; }
.meeting-days input { width: auto; min-height: auto; }
.meeting-days .muted { grid-column: 1 / -1; font-size: 0.82rem; color: var(--muted); margin: 0.25rem 0 0; }
.date-chip small { display: block; flex-basis: 100%; color: var(--muted); font-size: 0.82rem; margin-top: 0.25rem; }
.date-option small { display: block; color: var(--muted); font-size: 0.78rem; margin-top: 0.25rem; text-align: left; }

/* v9.12 multi-day UX refinement */
.date-option-wrap { display: grid; gap: 6px; }
.date-option-wrap .date-option { display: grid; gap: 2px; }
.date-option-wrap .date-option strong { margin-bottom: 2px; }
.meeting-toggle {
  justify-self: start;
  border: 0;
  background: transparent;
  color: #7dd3fc;
  font-weight: 800;
  font-size: 12px;
  padding: 0 2px 3px;
  cursor: pointer;
}
.meeting-toggle:hover { text-decoration: underline; }
.meeting-detail-list {
  display: grid;
  gap: 4px;
  margin: -1px 0 6px 8px;
  padding-left: 10px;
  border-left: 2px solid rgba(0, 212, 255, .30);
  color: var(--muted);
  font-size: 12px;
  line-height: 1.35;
}

.calendar-day.multi-range { border-color: rgba(0, 212, 255, .46); background: rgba(0, 212, 255, .10); }
.calendar-day.range-start { border-top-right-radius: 6px; border-bottom-right-radius: 6px; }
.calendar-day.range-middle { border-radius: 6px; background: rgba(0, 212, 255, .13); }
.calendar-day.range-end { border-top-left-radius: 6px; border-bottom-left-radius: 6px; }
.calendar-day.multi-count { border-color: rgba(250, 204, 21, .42); background: rgba(250, 204, 21, .08); }
.calendar-day.multi-count .day-meta { color: #fde68a; }
.calendar-day.selected.multi-range { background: #07586a; box-shadow: inset 0 0 0 1px rgba(125, 211, 252, .55); }
.calendar-choice {
  margin-top: 10px;
  border: 1px solid rgba(250, 204, 21, .28);
  background: rgba(250, 204, 21, .06);
  border-radius: 12px;
  padding: 9px;
  display: grid;
  gap: 6px;
}
.calendar-choice > strong { color: white; font-size: 13px; }
.calendar-choice > span { color: var(--muted); font-size: 12px; }
.calendar-choice button {
  text-align: left;
  border: 1px solid #4a5362;
  background: #242a36;
  color: #ffffff;
  border-radius: 10px;
  padding: 8px;
  display: grid;
  gap: 2px;
  cursor: pointer;
}
.calendar-choice button:hover { border-color: #25b9d8; background: #07586a; }
.calendar-choice small { color: var(--muted); }
.date-chip details { margin-top: 5px; font-size: 12px; color: var(--muted); }
.date-chip summary { cursor: pointer; color: #7dd3fc; font-weight: 800; }
.date-chip details div { margin-top: 3px; }

/* v9.16 live Google Sheets controls */
.google-sheets-card { margin-top: 4px; }
.google-sheet-field {
  display: grid;
  gap: 6px;
  margin-top: 14px;
  max-width: 900px;
}
.google-sheet-field input { width: 100%; }
.google-sheet-actions { margin-top: 12px; align-items: center; }
.google-sheet-actions .btn { text-decoration: none; }

/* v9.17 simplified live Google Sheets workflow */
.google-connect-button { min-width: 280px; }
.google-sheet-primary-actions { margin-top: 14px; }
.google-sheets-advanced {
  margin-top: 14px;
  border-top: 1px solid var(--line);
  padding-top: 12px;
}
.google-sheets-advanced summary {
  cursor: pointer;
  font-weight: 800;
  color: var(--accent);
}
.google-sheet-error-detail {
  display: grid;
  gap: 4px;
  margin-top: 12px;
  padding: 10px 12px;
  border: 1px solid #8b3a3a;
  border-radius: 10px;
  background: #331f24;
}
.google-sheet-error-detail span { color: var(--muted); }
@media (max-width: 640px) {
  .google-connect-button { min-width: 0; width: 100%; }
  .google-sheet-primary-actions .btn,
  .google-sheet-primary-actions a { width: 100%; text-align: center; }
}

/* v10.2 payment integrity, outcomes, instructors, and annual analytics */
.filter-panel { margin-bottom: 14px; }
.filter-panel summary { cursor: pointer; font-weight: 800; color: var(--accent); margin-bottom: 10px; }
.analytics-filter-row { grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); align-items: end; }
.bulk-action-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: end;
  gap: 10px;
  margin: 12px 0;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: rgba(255,255,255,.025);
}
.bulk-action-bar label { min-width: 150px; }
.analytics-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(360px, 1fr)); gap: 16px; }
.analytics-card { min-width: 0; border: 1px solid var(--line); border-radius: 14px; padding: 14px; background: rgba(255,255,255,.02); overflow: hidden; }
.analytics-card .table-wrap { max-height: 420px; }
.outcome-table select { min-width: 125px; }
.outcome-table small { color: var(--muted); line-height: 1.45; }
.outcome-table td { vertical-align: top; }

@media (max-width: 760px) {
  .analytics-grid { grid-template-columns: 1fr; }
  .bulk-action-bar { display: grid; grid-template-columns: 1fr; }
  .bulk-action-bar label, .bulk-action-bar button { width: 100%; }
  .outcome-table { min-width: 1180px; }
}

/* v10.3 admin UX and reporting consolidation */
#page-schedule { max-width: 1380px; }
.schedule-banner {
  align-items: center;
  padding: 16px 18px;
  margin-bottom: 14px;
}
.schedule-banner h2 { font-size: clamp(25px, 3vw, 34px); }
.schedule-banner p { margin: 0; }
.schedule-primary-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
}
.schedule-primary-actions .btn { min-width: 0; }
.management-panel {
  margin-bottom: 14px;
  padding: 0;
  overflow: hidden;
  box-shadow: none;
}
.management-panel > summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 16px;
  cursor: pointer;
  font-weight: 900;
  list-style: none;
}
.management-panel > summary::-webkit-details-marker { display: none; }
.management-panel > summary::after {
  content: '+';
  color: var(--accent);
  font-size: 22px;
  line-height: 1;
}
.management-panel[open] > summary::after { content: '−'; }
.management-panel[open] > summary { border-bottom: 1px solid var(--line); }
.management-panel-body { padding: 16px; }
.management-panel-grid {
  display: grid;
  grid-template-columns: minmax(320px, .8fr) minmax(420px, 1.2fr);
  gap: 16px;
  align-items: start;
}
.compact-form {
  display: grid;
  gap: 13px;
}
.compact-form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px 16px;
}
.compact-form label { gap: 5px; }
.compact-form input,
.compact-form select {
  height: 42px;
  min-height: 42px;
  padding: 8px 11px;
}
.compact-form textarea {
  min-height: 88px;
  max-height: 180px;
  padding: 10px 11px;
}
.compact-form .wide { grid-column: 1 / -1; }
.compact-form-head,
.offering-form-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}
.compact-form-head h3,
.offering-form-head h3 { margin-bottom: 2px; }
.compact-form-head p,
.offering-form-head p { margin: 0; }
.offering-form {
  margin-bottom: 14px;
  padding: 16px;
  box-shadow: none;
}
.offering-form .compact-form-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.form-section-heading {
  grid-column: 1 / -1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding-top: 4px;
  color: white;
  font-size: 13px;
  font-weight: 900;
}
.advanced-offering-fields {
  grid-column: 1 / -1;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: rgba(255,255,255,.02);
}
.advanced-offering-fields > summary {
  cursor: pointer;
  padding: 11px 12px;
  color: var(--muted);
  font-weight: 900;
}
.advanced-offering-fields[open] > summary { border-bottom: 1px solid var(--line); color: white; }
.advanced-offering-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px 16px;
  padding: 12px;
}
.meeting-days.compact-meeting-days {
  grid-column: 1 / -1;
  padding: 12px;
  grid-template-columns: repeat(7, minmax(64px, 1fr));
  gap: 8px;
}
.meeting-days.compact-meeting-days label {
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: center;
  gap: 6px;
  min-height: 34px;
  padding: 6px;
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 9px;
  background: rgba(255,255,255,.025);
}
.sticky-form-actions {
  position: sticky;
  bottom: 0;
  z-index: 6;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin: 2px -4px -4px;
  padding: 10px 4px 4px;
  background: linear-gradient(180deg, rgba(23,26,33,0), rgba(23,26,33,.98) 34%);
}
.sticky-form-actions .action-copy { color: var(--muted); font-size: 12px; }
.compact-actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
}
.compact-actions .btn,
.offering-row-actions .btn,
.roster-toolbar .btn {
  width: auto;
  min-width: 0;
  max-width: max-content;
  min-height: 40px;
  height: 40px;
  padding: 8px 13px;
  border-radius: 11px;
}
.compact-actions .btn.primary { min-width: 142px; }
.class-management-list { display: grid; gap: 8px; }
.class-management-row {
  display: grid;
  grid-template-columns: minmax(180px, 1fr) minmax(120px, .55fr) auto;
  gap: 10px;
  align-items: center;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 11px;
  background: rgba(255,255,255,.025);
}
.class-management-row p { margin: 2px 0 0; font-size: 12px; }
.offering-list { display: grid; gap: 9px; }
.offering-row {
  display: grid;
  grid-template-columns: minmax(230px, 1.1fr) minmax(260px, 1fr) minmax(200px, .8fr) auto;
  gap: 12px;
  align-items: center;
  padding: 11px 12px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: rgba(255,255,255,.025);
}
.offering-row strong { display: block; }
.offering-row p { margin: 3px 0 0; font-size: 12px; }
.offering-row-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.offering-row-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 6px;
}
.offering-row-actions .btn { font-size: 12px; min-height: 36px; height: 36px; padding: 7px 10px; }
.read-only-notice {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 12px;
  padding: 10px 12px;
  border: 1px solid rgba(0,212,255,.25);
  border-radius: 11px;
  background: rgba(0,212,255,.055);
}
.read-only-notice span { color: var(--muted); font-size: 12px; }
.registration-ledger-table .btn { min-height: 34px; padding: 6px 10px; border-radius: 9px; }
.roster-operations-card { margin-bottom: 14px; }
.roster-toolbar {
  display: flex;
  align-items: end;
  gap: 10px;
  margin: 10px 0 12px;
}
.roster-toolbar label { min-width: min(520px, 100%); }
.roster-context {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
  gap: 8px;
  margin: 10px 0 12px;
}
.roster-context > div {
  padding: 9px 10px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: rgba(255,255,255,.025);
}
.roster-context b,
.roster-context span { display: block; }
.roster-context b { color: var(--muted); font-size: 10px; text-transform: uppercase; letter-spacing: .07em; }
.roster-context span { margin-top: 3px; font-size: 13px; font-weight: 800; }
.roster-table { min-width: 1180px; }
.roster-table input[type="checkbox"] { width: 17px; min-height: 17px; height: 17px; }
.roster-table select { min-width: 120px; }
.roster-table textarea { min-width: 210px; min-height: 64px; }

@media (max-width: 1050px) {
  .management-panel-grid { grid-template-columns: 1fr; }
  .offering-row { grid-template-columns: minmax(220px, 1fr) minmax(250px, 1fr); }
  .offering-row-actions { justify-content: flex-start; grid-column: 1 / -1; }
  .meeting-days.compact-meeting-days { grid-template-columns: repeat(4, minmax(70px, 1fr)); }
}

@media (max-width: 760px) {
  #page-schedule { padding-inline: 12px; }
  .schedule-banner,
  .compact-form-head,
  .offering-form-head,
  .sticky-form-actions,
  .read-only-notice,
  .roster-toolbar { align-items: stretch; flex-direction: column; }
  .schedule-primary-actions { justify-content: flex-start; }
  .compact-form-grid,
  .offering-form .compact-form-grid,
  .advanced-offering-grid { grid-template-columns: 1fr; }
  .compact-form .wide,
  .form-section-heading,
  .advanced-offering-fields,
  .meeting-days.compact-meeting-days { grid-column: auto; }
  .meeting-days.compact-meeting-days { grid-template-columns: repeat(2, minmax(80px, 1fr)); }
  .class-management-row,
  .offering-row { grid-template-columns: 1fr; }
  .offering-row-actions { grid-column: auto; justify-content: flex-start; }
  .roster-toolbar label { min-width: 0; }
  .sticky-form-actions { position: static; background: transparent; padding-top: 4px; }
}

@media (max-width: 480px) {
  .schedule-primary-actions,
  .compact-actions,
  .offering-row-actions { display: grid; grid-template-columns: 1fr; width: 100%; }
  .schedule-primary-actions .btn,
  .compact-actions .btn,
  .offering-row-actions .btn,
  .roster-toolbar .btn { width: 100%; max-width: none; }
  .meeting-days.compact-meeting-days { grid-template-columns: 1fr 1fr; }
}

/* v10.3 selector alignment for generated admin markup */
.management-panel > form { padding: 16px; }
.advanced-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px 16px;
  padding: 12px;
}
.compact-class-group { padding: 12px; }
.compact-class-group .admin-class-head { align-items: center; }
.compact-class-group .admin-class-head p { margin: 3px 0 0; }
.offering-rows { display: grid; gap: 8px; margin-top: 10px; }
.offering-row .offering-main { min-width: 0; }
.offering-row .offering-main span,
.offering-row .offering-main small { display: block; margin-top: 3px; color: var(--muted); }
.offering-row .offering-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.offering-row .offering-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 6px;
}
.offering-row .offering-actions .btn {
  width: auto;
  min-width: 0;
  max-width: max-content;
  min-height: 36px;
  height: 36px;
  padding: 7px 10px;
  border-radius: 10px;
  font-size: 12px;
}
.roster-summary-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
  gap: 8px;
}
.roster-summary-grid > div {
  padding: 9px 10px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: rgba(255,255,255,.025);
}
.roster-summary-grid strong,
.roster-summary-grid span { display: block; }
.roster-summary-grid strong { color: var(--muted); font-size: 10px; text-transform: uppercase; letter-spacing: .07em; }
.roster-summary-grid span { margin-top: 3px; font-size: 13px; font-weight: 800; }
.roster-edit-table { min-width: 1180px; }
.roster-edit-table input[type="checkbox"] { width: 17px; min-height: 17px; height: 17px; }
.roster-edit-table select { min-width: 120px; }
.roster-edit-table input[data-roster-notes] { min-width: 210px; }

@media (max-width: 760px) {
  .advanced-grid { grid-template-columns: 1fr; }
  .offering-row .offering-actions { justify-content: flex-start; }
}

@media (max-width: 480px) {
  .offering-row .offering-actions { display: grid; grid-template-columns: 1fr; width: 100%; }
  .offering-row .offering-actions .btn { width: 100%; max-width: none; }
}


.self-paced-quantity { margin: 14px 0; padding: 14px; border: 1px solid var(--border, #d1d5db); border-radius: 12px; background: #f8fafc; }
.self-paced-quantity label { max-width: 180px; display: grid; gap: 6px; font-weight: 700; }
.self-paced-quantity input { min-height: 42px; }

/* v10.4 progressive admin UX */
.admin-dialog {
  border: 0;
  padding: 0;
  margin: auto;
  max-width: none;
  max-height: none;
  background: transparent;
  color: var(--text);
  overflow: visible;
}
.admin-dialog::backdrop { background: rgba(3, 7, 18, .78); backdrop-filter: blur(4px); }
.dialog-shell {
  width: min(620px, calc(100vw - 32px));
  max-height: min(90vh, 860px);
  overflow: auto;
  background: linear-gradient(180deg, #1b1f28, #151820);
  border: 1px solid var(--line);
  border-radius: 18px;
  box-shadow: 0 28px 90px rgba(0, 0, 0, .65);
}
.dialog-shell-wide { width: min(980px, calc(100vw - 32px)); }
.dialog-head {
  position: sticky;
  top: 0;
  z-index: 4;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 16px 18px;
  border-bottom: 1px solid var(--line);
  background: rgba(23, 26, 33, .97);
}
.dialog-head h2, .dialog-head h3, .dialog-head .eyebrow { margin-bottom: 0; }
.dialog-head .close {
  width: 38px;
  height: 38px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: rgba(255,255,255,.05);
  color: var(--text);
  font-size: 25px;
  line-height: 1;
}
.dialog-content { padding: 16px 18px 18px; }
.dialog-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: 14px;
  padding-top: 14px;
  border-top: 1px solid var(--line);
}
.dialog-footer .btn, .compact-actions .btn { width: auto; min-width: 130px; min-height: 42px; height: 42px; }
.compact-form { display: grid; gap: 12px; }
.compact-form > label { margin: 0; }
.compact-form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 11px 14px;
}
.compact-form-grid .wide { grid-column: 1 / -1; }
.compact-form input:not([type="checkbox"]):not([type="radio"]),
.compact-form select {
  min-height: 42px;
  height: 42px;
}
.compact-form textarea { min-height: 84px; resize: vertical; }
.manager-split {
  display: grid;
  grid-template-columns: minmax(280px, .9fr) minmax(320px, 1.1fr);
  gap: 18px;
  align-items: start;
}
.compact-manager-list { display: grid; gap: 8px; }
.compact-manager-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 11px;
  border: 1px solid var(--line);
  border-radius: 11px;
  background: rgba(255,255,255,.035);
}
.compact-manager-row strong, .compact-manager-row small { display: block; }
.compact-manager-row small { margin-top: 3px; color: var(--muted); }
.context-menu { position: relative; flex: 0 0 auto; }
.context-menu > summary {
  list-style: none;
  display: grid;
  place-items: center;
  width: 38px;
  height: 36px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: rgba(255,255,255,.05);
  color: var(--text);
  font-size: 22px;
  font-weight: 900;
  cursor: pointer;
}
.context-menu > summary::-webkit-details-marker { display: none; }
.context-menu-popover {
  position: absolute;
  right: 0;
  top: calc(100% + 6px);
  z-index: 25;
  min-width: 178px;
  padding: 6px;
  border: 1px solid var(--line);
  border-radius: 11px;
  background: #20252f;
  box-shadow: 0 15px 42px rgba(0,0,0,.55);
}
.context-menu-popover button {
  width: 100%;
  padding: 9px 10px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: var(--text);
  text-align: left;
  font-weight: 750;
}
.context-menu-popover button:hover, .context-menu-popover button:focus { background: rgba(255,255,255,.08); }
.context-menu-popover .danger-text { color: #ff9da6; }
.schedule-helper-bar {
  margin: -18px 0 14px;
  padding: 9px 12px;
  color: var(--muted);
  font-size: 12px;
}
.schedule-primary-actions { display: flex; flex-wrap: wrap; gap: 8px; justify-content: flex-end; }
.schedule-primary-actions .btn { width: auto; min-width: 0; }
.offering-row {
  display: grid;
  grid-template-columns: minmax(220px, 1.4fr) minmax(260px, 1fr) auto;
  gap: 12px;
  align-items: center;
  padding: 11px 12px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: rgba(255,255,255,.025);
}
.offering-actions { display: flex; align-items: center; gap: 7px; }
.read-only-notice {
  display: flex;
  gap: 10px;
  align-items: baseline;
  margin: 8px 0 14px;
  padding: 9px 11px;
  border: 1px solid rgba(0,212,255,.22);
  border-radius: 10px;
  background: rgba(0,212,255,.055);
  color: var(--muted);
}
.read-only-notice strong { color: var(--text); }
.active-filter-chips { display: flex; flex-wrap: wrap; gap: 6px; margin: 8px 0 12px; }
.filter-chip { padding: 5px 8px; border-radius: 999px; border: 1px solid var(--line); background: rgba(255,255,255,.045); color: var(--muted); font-size: 11px; }
.form-section-heading { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.advanced-offering-fields { padding: 10px 0 0; }
.advanced-offering-fields > summary, .filter-panel > summary { cursor: pointer; font-weight: 850; }
.detail-section-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.detail-section {
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: rgba(255,255,255,.025);
}
.detail-section h3 { margin-bottom: 8px; }
.detail-kv { display: grid; grid-template-columns: minmax(130px, .7fr) 1fr; gap: 6px 12px; font-size: 13px; }
.detail-kv dt { color: var(--muted); }
.detail-kv dd { margin: 0; font-weight: 750; overflow-wrap: anywhere; }
.payment-history-table { min-width: 760px; }
.self-paced-quantity { background: rgba(255,255,255,.035); border-color: var(--line); }
.self-paced-quantity input { background: #11151c; color: var(--text); border-color: var(--line); }

@media (max-width: 900px) {
  .manager-split { grid-template-columns: 1fr; }
  .offering-row { grid-template-columns: 1fr; }
  .offering-actions { justify-content: flex-start; }
  .schedule-primary-actions { justify-content: flex-start; }
}
@media (max-width: 700px) {
  .admin-dialog { width: 100vw; max-width: 100vw; }
  .dialog-shell, .dialog-shell-wide {
    width: calc(100vw - 12px);
    max-height: calc(100vh - 12px);
    border-radius: 14px;
  }
  .compact-form-grid, .detail-section-grid { grid-template-columns: 1fr; }
  .compact-form-grid .wide { grid-column: auto; }
  .dialog-footer { align-items: stretch; flex-direction: column; }
  .dialog-footer .form-actions { width: 100%; }
  .dialog-footer .btn { flex: 1; min-width: 0; }
  .read-only-notice { align-items: flex-start; flex-direction: column; }
}
@media (max-width: 480px) {
  .schedule-primary-actions { display: grid; grid-template-columns: 1fr; width: 100%; }
  .schedule-primary-actions .btn { width: 100%; }
  .dialog-content { padding: 13px; }
  .dialog-head { padding: 13px; }
}

/* v10.4 progressive settings and utility navigation */
.nav-utility { opacity: .72; }
.nav-utility:hover, .nav-utility:focus-visible { opacity: 1; }
.settings-group { margin: 0 0 18px; padding: 18px; border: 1px solid var(--line); border-radius: 14px; background: rgba(255,255,255,.025); }
.settings-group > h3, .settings-group > h4 { margin-top: 0; }
.settings-advanced > summary { cursor: pointer; padding: 2px 0 10px; }
.settings-advanced[open] > summary { margin-bottom: 12px; }

/* ========================================================================== */
/* v10.5 — A Better Choice brand UI system + responsive refinement            */
/* Functional behavior remains unchanged; this layer standardizes presentation. */
/* ========================================================================== */

:root {
  /* Brand palette derived from the supplied A Better Choice seal. */
  --brand-navy-950: #172340;
  --brand-navy-900: #1f2f59;
  --brand-navy-800: #283a6d;
  --brand-navy-700: #344b82;
  --brand-navy-600: #45619a;
  --brand-gold-700: #8f7424;
  --brand-gold-600: #a98b2f;
  --brand-gold-500: #ba9d39;
  --brand-gold-200: #e6d8a5;
  --brand-gold-100: #f5efd9;
  --brand-silver-300: #bec3cc;

  /* Neutral application surfaces. */
  --bg: #f4f6f9;
  --surface: #ffffff;
  --surface-subtle: #f8f9fb;
  --surface-muted: #eef1f5;
  --panel: #ffffff;
  --panel2: #f8f9fb;
  --text: #172033;
  --text-strong: #101828;
  --muted: #667085;
  --muted-2: #8a94a6;
  --line: #d9dee7;
  --line-strong: #c7ced9;

  /* Compatibility aliases used by older components. */
  --accent: #283a6d;
  --accent2: #344b82;
  --good: #18794e;
  --warn: #8a6116;
  --bad: #b42318;
  --orange: #b85f18;

  /* Semantic surfaces. */
  --success-bg: #ecfdf3;
  --success-line: #a6f4c5;
  --success-text: #067647;
  --warning-bg: #fffaeb;
  --warning-line: #fedf89;
  --warning-text: #93370d;
  --danger-bg: #fef3f2;
  --danger-line: #fecdca;
  --danger-text: #b42318;
  --info-bg: #eef4ff;
  --info-line: #c7d7fe;
  --info-text: #274a8a;

  /* Standardized geometry/density. */
  --radius-xs: 6px;
  --radius-sm: 8px;
  --radius-md: 10px;
  --radius-lg: 12px;
  --radius-xl: 16px;
  --radius: 12px;
  --control-h: 38px;
  --control-h-compact: 32px;
  --page-max: 1280px;
  --shadow-xs: 0 1px 2px rgba(16, 24, 40, .04);
  --shadow-sm: 0 1px 3px rgba(16, 24, 40, .08), 0 1px 2px rgba(16, 24, 40, .04);
  --shadow: 0 12px 30px rgba(16, 24, 40, .10);
}

html { color-scheme: light; }
body {
  min-height: 100vh;
  font-family: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  font-size: 14px;
  line-height: 1.45;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

button, input, select, textarea { font: inherit; }
button, .btn, .nav-link, .filter, summary { -webkit-tap-highlight-color: transparent; }
button:focus-visible,
.btn:focus-visible,
.nav-link:focus-visible,
.filter:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible,
summary:focus-visible,
a:focus-visible {
  outline: 3px solid rgba(186, 157, 57, .34);
  outline-offset: 2px;
}

::selection { background: var(--brand-gold-200); color: var(--text-strong); }

/* Typography hierarchy */
h1, h2, h3, h4, h5, h6 { color: var(--text-strong); font-weight: 700; }
h1 { margin: 0 0 12px; font-size: clamp(30px, 4vw, 44px); line-height: 1.06; letter-spacing: -.035em; }
h2 { margin: 0 0 7px; font-size: clamp(22px, 2.5vw, 28px); line-height: 1.16; letter-spacing: -.025em; }
h3 { margin: 0 0 7px; font-size: 16px; line-height: 1.25; letter-spacing: -.012em; }
h4 { margin: 0 0 6px; font-size: 14px; line-height: 1.3; }
p { margin-top: 0; margin-bottom: 10px; color: var(--muted); line-height: 1.5; }
.lead { max-width: 650px; font-size: 15px; line-height: 1.55; }
.eyebrow {
  margin: 0 0 5px;
  color: var(--brand-navy-700);
  font-size: 10px;
  line-height: 1.3;
  font-weight: 750;
  letter-spacing: .105em;
  text-transform: uppercase;
}
.small-muted { color: var(--muted); font-size: 11.5px; line-height: 1.45; }

/* Header / navigation */
.topbar {
  min-height: 60px;
  padding: 8px clamp(14px, 2vw, 24px);
  border-bottom: 1px solid rgba(255,255,255,.12);
  background: rgba(31, 47, 89, .98);
  box-shadow: 0 1px 3px rgba(16,24,40,.12);
  backdrop-filter: blur(10px);
}
.brand { min-width: 190px; gap: 9px; }
.brand-mark {
  width: 40px;
  height: 40px;
  padding: 2px;
  overflow: hidden;
  border: 1px solid rgba(255,255,255,.18);
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 1px 2px rgba(0,0,0,.12);
}
.brand-mark img { display: block; width: 100%; height: 100%; object-fit: contain; border-radius: 50%; }
.brand strong { color: #fff; font-size: 14px; font-weight: 720; letter-spacing: -.01em; }
.brand span { margin-top: 1px; color: rgba(255,255,255,.68); font-size: 10px; font-weight: 550; }
.nav { gap: 2px; flex-wrap: nowrap; }
.nav-link {
  min-height: 36px;
  padding: 7px 10px;
  border: 1px solid transparent;
  border-radius: var(--radius-sm);
  background: transparent;
  color: rgba(255,255,255,.72);
  font-size: 12px;
  font-weight: 620;
  transition: background-color .14s ease, color .14s ease, border-color .14s ease;
}
.nav-link:hover { border-color: rgba(255,255,255,.10); background: rgba(255,255,255,.08); color: #fff; }
.nav-link.active {
  border-color: rgba(230,216,165,.30);
  background: rgba(186,157,57,.18);
  color: #fff;
  box-shadow: inset 0 -2px 0 var(--brand-gold-500);
}
.nav-utility { margin-left: 4px; opacity: .72; }
.nav-utility:hover, .nav-utility:focus-visible { opacity: 1; }

/* Page structure */
.page { max-width: var(--page-max); padding: 24px clamp(14px, 2.2vw, 28px) 40px; }
#page-schedule { max-width: 1380px; }
.hero {
  min-height: calc(100vh - 150px);
  grid-template-columns: minmax(0, 1.12fr) minmax(300px, .72fr);
  gap: clamp(28px, 5vw, 72px);
  padding: 42px 0;
}
.section-head, .internal-banner { margin-bottom: 14px; gap: 14px; }
.internal-banner {
  align-items: center;
  padding: 14px 16px;
  border: 1px solid var(--line);
  border-left: 4px solid var(--brand-gold-500);
  border-radius: var(--radius-lg);
  background: var(--surface);
  box-shadow: var(--shadow-xs);
}
.internal-banner p { margin-bottom: 0; font-size: 12.5px; }
.internal-site .internal-banner .eyebrow { display: none; }
.schedule-helper-bar { margin: -6px 2px 10px; padding: 4px 8px; font-size: 11.5px; }

/* Cards and panels */
.hero-panel, .content-card, .panel,
.analytics-card, .settings-group, .export-status-card,
.management-panel, .admin-class, .detail-section {
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: var(--surface);
  box-shadow: var(--shadow-xs);
}
.hero-panel, .content-card, .panel { padding: 15px; }
.hero-panel { padding: 18px 20px; }
.hero-panel ol { margin: 10px 0 0; padding-left: 21px; }
.hero-panel li { margin: 7px 0; color: var(--muted); }
.content-card.narrow { max-width: 680px; }
.login-card { margin-top: 52px; }
.settings-group { margin-bottom: 12px; padding: 14px; }
.settings-group > h3, .settings-group > h4 { margin-bottom: 4px; }

/* Buttons */
.actions, .form-actions { gap: 7px; }
.btn {
  min-height: var(--control-h);
  padding: 7px 12px;
  border: 1px solid transparent;
  border-radius: var(--radius-sm);
  font-size: 12.5px;
  line-height: 1.2;
  font-weight: 680;
  text-decoration: none;
  box-shadow: var(--shadow-xs);
  transition: transform .08s ease, background-color .14s ease, border-color .14s ease, box-shadow .14s ease;
}
.btn:hover:not(:disabled) { box-shadow: var(--shadow-sm); }
.btn:active:not(:disabled) { transform: translateY(1px); box-shadow: none; }
.btn:disabled { opacity: .48; }
.btn.primary {
  border-color: var(--brand-navy-800);
  background: var(--brand-navy-800);
  color: #fff;
}
.btn.primary:hover:not(:disabled) { border-color: var(--brand-navy-900); background: var(--brand-navy-900); }
.btn.secondary {
  border-color: var(--line-strong);
  background: var(--surface);
  color: var(--text);
}
.btn.secondary:hover:not(:disabled) { border-color: #aeb7c5; background: var(--surface-subtle); }
.btn.danger {
  border-color: var(--danger-line);
  background: var(--danger-bg);
  color: var(--danger-text);
}
.btn.danger:hover:not(:disabled) { border-color: #fda29b; background: #fee4e2; }
.compact-btn,
.registration-ledger-table .btn,
.offering-row .offering-actions .btn,
.offering-row-actions .btn,
.roster-toolbar .btn {
  min-height: var(--control-h-compact);
  height: var(--control-h-compact);
  padding: 5px 9px;
  border-radius: 7px;
  font-size: 11.5px;
}

/* Forms */
form { gap: 9px; }
label { gap: 4px; color: #475467; font-size: 11.5px; font-weight: 650; }
.form-grid, .compact-form-grid { gap: 9px 12px; }
input, select, textarea {
  min-height: var(--control-h);
  padding: 7px 9px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-sm);
  background: #fff;
  color: var(--text);
  font-size: 13px;
  box-shadow: inset 0 1px 1px rgba(16,24,40,.025);
  transition: border-color .14s ease, box-shadow .14s ease;
}
input:hover, select:hover, textarea:hover { border-color: #aeb7c5; }
input:focus, select:focus, textarea:focus {
  border-color: var(--brand-navy-600);
  box-shadow: 0 0 0 3px rgba(52,75,130,.10);
}
input::placeholder, textarea::placeholder { color: #98a2b3; }
textarea { min-height: 76px; }
.compact-form { gap: 10px; }
.compact-form input:not([type="checkbox"]):not([type="radio"]),
.compact-form select { min-height: var(--control-h); height: var(--control-h); }
.compact-form textarea { min-height: 72px; }
.inline-form.notification-test-form { margin-top: 10px; gap: 8px; }
.consent-row { color: var(--muted); font-size: 11px; line-height: 1.4; }
.consent-row input[type="checkbox"] { accent-color: var(--brand-navy-800); }
.meeting-days {
  padding: 10px;
  border-color: var(--line);
  border-radius: var(--radius-md);
  background: var(--surface-subtle);
}
.meeting-days.compact-meeting-days label {
  min-height: 32px;
  border-color: var(--line);
  border-radius: 7px;
  background: #fff;
}
.self-paced-quantity {
  margin: 10px 0;
  padding: 10px;
  border-color: var(--brand-gold-200);
  border-radius: var(--radius-md);
  background: var(--brand-gold-100);
}
.self-paced-quantity input { background: #fff; color: var(--text); border-color: var(--line-strong); }

/* Filters / progressive disclosure */
.filters { gap: 6px; }
.filter {
  min-height: 32px;
  padding: 5px 9px;
  border-color: var(--line-strong);
  border-radius: 999px;
  background: var(--surface);
  color: #475467;
  font-size: 11.5px;
  font-weight: 650;
}
.filter:hover { border-color: var(--brand-navy-600); color: var(--brand-navy-800); }
.filter.active {
  border-color: var(--brand-navy-800);
  background: var(--brand-navy-800);
  color: #fff;
}
.filter-panel {
  margin-bottom: 10px;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: var(--surface-subtle);
}
.filter-panel > summary {
  margin: 0;
  padding: 9px 11px;
  color: var(--brand-navy-800);
  font-size: 12px;
  font-weight: 700;
  list-style: none;
}
.filter-panel > summary::-webkit-details-marker { display: none; }
.filter-panel > summary::after { content: "+"; float: right; color: var(--muted); font-size: 16px; line-height: 1; }
.filter-panel[open] > summary::after { content: "−"; }
.filter-panel[open] > summary { border-bottom: 1px solid var(--line); }
.filter-panel > .filter-row,
.filter-panel > .active-filter-chips + .filter-row { margin: 0; padding: 10px; }
.filter-panel > .active-filter-chips { margin: 8px 10px 0; }
.filter-row { gap: 8px 10px; margin-bottom: 10px; }
.analytics-filter-row { grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); }
.filter-chip {
  padding: 4px 7px;
  border-color: var(--brand-gold-200);
  background: var(--brand-gold-100);
  color: #6b571a;
  font-size: 10.5px;
}

/* Class selection cards */
.class-grid { gap: 12px; }
.class-card {
  min-height: 236px;
  gap: 9px;
  padding: 14px;
  border-color: var(--line);
  border-radius: var(--radius-lg);
  background: var(--surface);
  box-shadow: var(--shadow-xs);
  transition: transform .14s ease, border-color .14s ease, box-shadow .14s ease;
}
.class-card:hover { transform: translateY(-1px); border-color: #c2c9d4; box-shadow: var(--shadow-sm); }
.class-card:before { height: 3px; background: var(--brand-navy-800); }
.class-card.family:before { background: var(--brand-navy-600); }
.class-card.drug:before { background: var(--good); }
.class-card.vip:before { background: var(--brand-gold-500); }
.class-card h3 { font-size: 15px; }
.card-top { gap: 8px; }
.tag, .pill {
  padding: 4px 7px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--surface-muted);
  color: #475467;
  font-size: 10.5px;
  font-weight: 650;
}
.tag { border-color: #cbd5e3; background: #eef3fb; color: var(--brand-navy-800); }
.price { color: var(--brand-navy-900); font-size: 20px; font-weight: 760; letter-spacing: -.025em; }
.meta { gap: 5px; color: var(--muted); font-size: 12px; }
.seat-good { color: var(--success-text); }
.seat-warn { color: var(--warning-text); }
.seat-full { color: var(--danger-text); }

/* Compact info grids / stats */
.help-grid, .stats, .export-grid { gap: 9px; }
.help-grid > div, .stat, .export-card,
.export-meta-grid div, .roster-context > div, .roster-summary-grid > div {
  padding: 10px 11px;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: var(--surface-subtle);
}
.help-grid span { margin-top: 3px; font-size: 12px; }
.stat b, .export-meta-grid strong, .roster-context b, .roster-summary-grid strong {
  color: var(--muted);
  font-size: 9.5px;
  font-weight: 700;
  letter-spacing: .07em;
}
.stat span { margin-top: 3px; color: var(--brand-navy-900); font-size: 20px; font-weight: 760; }
.export-meta-grid span { margin-top: 3px; color: var(--text-strong); font-size: 12.5px; font-weight: 680; }
.export-status-card { padding: 12px; }
.primary-export-card { gap: 12px; }
.export-card a { color: var(--brand-navy-800); font-weight: 700; }

/* Tables */
.table-wrap {
  width: 100%;
  overflow: auto;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: var(--surface);
  scrollbar-width: thin;
  scrollbar-color: #c5ccd6 transparent;
  -webkit-overflow-scrolling: touch;
}
.data-table { font-size: 11.5px; }
.data-table th, .data-table td {
  padding: 7px 9px;
  border-bottom: 1px solid #e8ebf0;
  color: var(--text);
  line-height: 1.4;
}
.data-table tbody tr:last-child td { border-bottom: 0; }
.data-table tbody tr:hover { background: #fafbfc; }
.data-table th {
  top: 0;
  z-index: 1;
  background: #f1f3f6;
  color: #475467;
  font-size: 10.5px;
  font-weight: 720;
  letter-spacing: .015em;
  white-space: nowrap;
}
.data-table td small { color: var(--muted); }
.registration-ledger-table { min-width: 880px; }
.payment-history-table { min-width: 700px; }
.roster-table, .roster-edit-table { min-width: 1080px; }
.analytics-card .table-wrap { max-height: 360px; }

/* Schedule / management rows */
.admin-class-list { gap: 10px; }
.admin-class { padding: 11px; }
.compact-class-group { padding: 11px; }
.compact-class-group .admin-class-head p { margin: 2px 0 0; font-size: 11.5px; }
.offering-rows { gap: 6px; margin-top: 8px; }
.offering-row {
  grid-template-columns: minmax(210px, 1.25fr) minmax(240px, 1fr) auto;
  gap: 10px;
  padding: 9px 10px;
  border-color: var(--line);
  border-radius: var(--radius-md);
  background: var(--surface-subtle);
}
.offering-row .offering-main span,
.offering-row .offering-main small { margin-top: 2px; font-size: 11px; }
.offering-row .offering-meta { gap: 4px; }
.schedule-primary-actions { gap: 6px; }
.schedule-primary-actions .btn { min-height: 36px; }
.compact-manager-list { gap: 6px; }
.compact-manager-row {
  gap: 9px;
  padding: 8px 9px;
  border-color: var(--line);
  border-radius: var(--radius-sm);
  background: var(--surface-subtle);
}
.compact-manager-row small { margin-top: 2px; font-size: 10.5px; }

/* Read-only / status messaging */
.read-only-notice {
  gap: 7px;
  margin: 8px 0 10px;
  padding: 7px 9px;
  border: 1px solid var(--info-line);
  border-radius: var(--radius-sm);
  background: var(--info-bg);
  color: #475467;
  font-size: 11.5px;
}
.read-only-notice strong { color: var(--info-text); }
.read-only-notice span { font-size: 11.5px; }
.message { margin-top: 6px; min-height: 16px; color: var(--success-text); font-size: 12px; }
.message.error { color: var(--danger-text); }
.danger-zone { border-color: var(--danger-line); background: var(--danger-bg); }

/* Public registration dialog */
.modal-backdrop { padding: 16px; }
.modal-backdrop::backdrop { background: rgba(15, 23, 42, .58); backdrop-filter: blur(2px); }
.modal {
  width: min(1000px, 100%);
  max-height: 92dvh;
  border: 1px solid var(--line);
  border-radius: var(--radius-xl);
  background: var(--surface);
  box-shadow: 0 24px 70px rgba(16,24,40,.22);
}
.modal-head {
  padding: 13px 15px;
  border-color: var(--line);
  background: rgba(255,255,255,.97);
}
.modal-head h2 { font-size: 20px; }
.modal-head p { margin: 2px 0 0; font-size: 11.5px; }
.modal-body { grid-template-columns: .95fr 1.05fr; gap: 12px; padding: 12px; }
.close {
  width: 34px;
  height: 34px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-sm);
  background: var(--surface-subtle);
  color: #475467;
  font-size: 20px;
}
.close:hover { background: var(--surface-muted); color: var(--text-strong); }
.date-list { gap: 6px; }
.date-option {
  min-height: 54px;
  padding: 8px 10px;
  border-color: var(--line-strong);
  border-radius: var(--radius-sm);
  background: var(--surface);
  color: var(--text);
}
.date-option strong { font-size: 13px; }
.date-option span { margin-top: 2px; color: var(--muted); font-size: 11.5px; }
.date-option:hover, .date-option.selected {
  border-color: var(--brand-navy-600);
  background: #f1f5fb;
}
.summary {
  gap: 4px;
  margin-bottom: 8px;
  padding: 8px 9px;
  border-color: var(--brand-gold-200);
  border-radius: var(--radius-sm);
  background: var(--brand-gold-100);
  color: #5f542d;
  font-size: 12px;
}
.summary strong { color: var(--text-strong); }
.calendar { padding: 9px; border-color: var(--line); border-radius: var(--radius-md); background: var(--surface-subtle); }
.calendar-head { margin-bottom: 7px; }
.calendar-title { color: var(--text-strong); font-size: 12.5px; }
.calendar-nav button {
  width: 28px;
  height: 28px;
  border-color: var(--line-strong);
  border-radius: 7px;
  background: #fff;
  color: var(--brand-navy-800);
}
.calendar-weekdays, .calendar-grid { gap: 3px; }
.calendar-weekdays span { color: var(--muted); font-size: 9px; }
.calendar-day {
  min-height: 38px;
  padding: 4px;
  border-color: #e6e9ee;
  border-radius: 7px;
  background: #fff;
  color: var(--muted);
}
.calendar-day.has-class {
  border-color: #b8c6e0;
  background: #eef3fb;
  color: var(--brand-navy-900);
}
.calendar-day.has-class:hover, .calendar-day.selected {
  border-color: var(--brand-navy-700);
  background: #e4ebf7;
}
.calendar-day.full {
  border-color: var(--danger-line);
  background: var(--danger-bg);
  color: var(--danger-text);
}
.calendar-day.full:hover { border-color: var(--danger-line); background: var(--danger-bg); }
.calendar-day .day-num { font-size: 11px; }
.calendar-day .day-meta { color: var(--muted); font-size: 8px; }
.calendar-day.has-class .day-meta { color: var(--brand-navy-700); }
.calendar-day.full .day-meta { color: var(--danger-text); }
.calendar-day.multi-range { border-color: #aabbdc; background: #eef3fb; }
.calendar-day.range-middle { background: #e9eff9; }
.calendar-day.multi-count { border-color: var(--brand-gold-200); background: var(--brand-gold-100); }
.calendar-day.multi-count .day-meta { color: var(--brand-gold-700); }
.calendar-day.selected.multi-range { background: #dfe8f6; box-shadow: inset 0 0 0 1px var(--brand-navy-700); }
.meeting-toggle, .date-chip summary { color: var(--brand-navy-700); }
.meeting-detail-list { border-left-color: #b8c6e0; }
.calendar-choice {
  border-color: var(--brand-gold-200);
  background: var(--brand-gold-100);
}
.calendar-choice > strong { color: var(--text-strong); }
.calendar-choice button { border-color: var(--line-strong); background: #fff; color: var(--text); }
.calendar-choice button:hover { border-color: var(--brand-navy-600); background: #f1f5fb; }

/* Admin dialogs / drawers */
.admin-dialog { color: var(--text); }
.admin-dialog::backdrop { background: rgba(15, 23, 42, .58); backdrop-filter: blur(2px); }
.dialog-shell {
  width: min(600px, calc(100vw - 32px));
  max-height: min(90dvh, 820px);
  border: 1px solid var(--line);
  border-radius: var(--radius-xl);
  background: var(--surface);
  box-shadow: 0 24px 70px rgba(16,24,40,.22);
}
.dialog-shell-wide { width: min(960px, calc(100vw - 32px)); }
.dialog-head {
  padding: 12px 14px;
  border-color: var(--line);
  background: rgba(255,255,255,.97);
}
.dialog-head h2 { font-size: 20px; }
.dialog-head .close {
  width: 34px;
  height: 34px;
  border-color: var(--line-strong);
  border-radius: var(--radius-sm);
  background: var(--surface-subtle);
  color: #475467;
  font-size: 21px;
}
.dialog-content { padding: 13px 14px 14px; }
.dialog-footer { gap: 8px; margin-top: 10px; padding-top: 10px; border-color: var(--line); }
.dialog-footer .btn, .compact-actions .btn { min-height: 36px; height: 36px; }
.manager-split { grid-template-columns: minmax(260px, .9fr) minmax(320px, 1.1fr); gap: 14px; }
.context-menu > summary {
  width: 32px;
  height: 32px;
  border-color: var(--line-strong);
  border-radius: 7px;
  background: #fff;
  color: #475467;
  font-size: 18px;
}
.context-menu > summary:hover { background: var(--surface-muted); color: var(--text-strong); }
.context-menu-popover {
  min-width: 170px;
  padding: 5px;
  border-color: var(--line);
  border-radius: var(--radius-sm);
  background: #fff;
  box-shadow: 0 12px 30px rgba(16,24,40,.16);
}
.context-menu-popover button { padding: 7px 8px; border-radius: 6px; color: var(--text); font-size: 12px; font-weight: 620; }
.context-menu-popover button:hover, .context-menu-popover button:focus { background: var(--surface-muted); }
.context-menu-popover .danger-text { color: var(--danger-text); }
.detail-section-grid { gap: 9px; }
.detail-section { padding: 10px; background: var(--surface-subtle); }
.detail-kv { grid-template-columns: minmax(120px, .68fr) 1fr; gap: 5px 10px; font-size: 12px; }
.detail-kv dt { color: var(--muted); }
.detail-kv dd { font-weight: 650; }

/* Settings, exports, notifications */
.backup-card {
  gap: 10px;
  padding: 9px 10px;
  border-color: var(--line);
  border-radius: var(--radius-md);
  background: var(--surface-subtle);
}
.backup-actions { gap: 6px; }
.google-sheets-card { margin-top: 2px; }
.google-sheets-advanced { border-color: var(--line); background: var(--surface-subtle); }
.google-sheet-error-detail { border-color: var(--danger-line); background: var(--danger-bg); }
.settings-advanced > summary, .google-sheets-advanced summary { color: var(--brand-navy-800); }

/* Payment result */
.public-shell.payment-result-shell {
  min-height: 100dvh;
  display: grid;
  place-items: center;
  padding: 20px;
}
.payment-result-card { width: min(620px, 100%); padding: 22px; }
.payment-result-card h1 { font-size: clamp(25px, 4vw, 34px); }
.registration-summary { display: grid; gap: 7px; margin: 14px 0; }
.button-row { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 14px; }

/* Desktop polish */
@media (min-width: 1100px) {
  .internal-site .page { padding-top: 20px; }
  #page-registrations .content-card,
  #page-analytics .content-card,
  #page-exports .content-card { padding: 13px; }
}

/* Tablet */
@media (max-width: 980px) {
  .topbar { display: flex; align-items: center; }
  .brand { margin-bottom: 0; }
  .nav { justify-content: flex-end; overflow-x: auto; scrollbar-width: none; }
  .nav::-webkit-scrollbar { display: none; }
  .hero { min-height: auto; grid-template-columns: 1fr; gap: 20px; padding: 34px 0; }
  .hero-panel { max-width: 620px; }
  .class-grid { grid-template-columns: repeat(2, minmax(0,1fr)); }
  .manager-grid { grid-template-columns: 1fr; }
  .help-grid, .stats, .export-grid { grid-template-columns: repeat(2, minmax(0,1fr)); }
  .manager-split { grid-template-columns: 1fr; }
}

/* Mobile */
@media (max-width: 720px) {
  body { font-size: 13.5px; }
  .topbar {
    display: grid;
    grid-template-columns: 1fr;
    gap: 6px;
    padding: 7px 10px 6px;
  }
  .brand { min-width: 0; }
  .brand-mark { width: 36px; height: 36px; }
  .brand strong { font-size: 13px; }
  .brand span { font-size: 9.5px; }
  .nav {
    width: calc(100vw - 20px);
    justify-content: flex-start;
    overflow-x: auto;
    padding-bottom: 1px;
    scroll-snap-type: x proximity;
  }
  .nav-link {
    flex: 0 0 auto;
    min-height: 33px;
    padding: 6px 9px;
    font-size: 11.5px;
    scroll-snap-align: start;
  }
  .nav-utility { margin-left: 0; }

  .page { padding: 16px 10px 28px; }
  h1 { font-size: clamp(28px, 9vw, 36px); }
  h2 { font-size: 21px; }
  h3 { font-size: 15px; }
  .lead { font-size: 14px; }
  .hero { padding: 24px 2px; }
  .section-head, .internal-banner { display: grid; align-items: start; }
  .internal-banner { padding: 11px 12px; border-left-width: 3px; }
  .internal-banner h2 { font-size: 20px; }
  .internal-banner p { font-size: 11.5px; }
  .schedule-helper-bar { margin: -3px 0 8px; padding: 3px 4px; }

  .class-grid, .help-grid, .stats, .export-grid, .filter-row, .form-grid { grid-template-columns: 1fr; }
  .class-card { min-height: 0; padding: 12px; }
  .hero-panel, .content-card, .panel { padding: 12px; }
  .stats { grid-template-columns: repeat(2, minmax(0,1fr)); }
  .stat { min-width: 0; }
  .stat span { font-size: 18px; }

  input, select, textarea, .btn { min-height: 44px; }
  .btn { padding-inline: 12px; }
  .compact-btn,
  .registration-ledger-table .btn,
  .offering-row .offering-actions .btn,
  .offering-row-actions .btn,
  .roster-toolbar .btn { min-height: 38px; height: 38px; }

  .filter-panel > summary { min-height: 42px; display: flex; align-items: center; justify-content: space-between; }
  .filter-panel > summary::after { float: none; }
  .analytics-filter-row { grid-template-columns: 1fr; }

  .modal-backdrop { align-items: flex-end; padding: 6px; }
  .modal {
    width: 100%;
    max-height: calc(100dvh - 8px);
    border-radius: 16px 16px 8px 8px;
  }
  .modal-head { padding: 11px 12px; }
  .modal-body { grid-template-columns: 1fr; gap: 8px; padding: 8px; }
  .date-picker-layout { gap: 8px; }
  .date-option { min-height: 50px; }
  .calendar-wrap { width: 100%; max-width: 420px; margin-inline: auto; }
  .calendar { padding: 8px; }
  .calendar-day { min-height: 36px; }
  .calendar-day .day-meta { display: none; }

  .admin-dialog { width: 100vw; max-width: 100vw; margin: auto 0 0; }
  .dialog-shell, .dialog-shell-wide {
    width: 100vw;
    max-height: calc(100dvh - 6px);
    border-radius: 16px 16px 0 0;
  }
  .dialog-head { padding: 11px 12px; }
  .dialog-content { padding: 10px 11px 12px; }
  .compact-form-grid, .detail-section-grid { grid-template-columns: 1fr; }
  .compact-form-grid .wide { grid-column: auto; }
  .dialog-footer { align-items: stretch; flex-direction: column; }
  .dialog-footer .form-actions { width: 100%; }
  .dialog-footer .btn { flex: 1; min-width: 0; }

  .schedule-primary-actions { justify-content: flex-start; }
  .offering-row { grid-template-columns: 1fr; }
  .offering-actions, .offering-row .offering-actions { justify-content: space-between; }
  .read-only-notice { align-items: flex-start; flex-direction: column; }

  /* Registration ledger keeps the task-critical columns visible on phones.
     Hidden monetary detail remains available through View Details. */
  .registration-ledger-table { min-width: 620px; }
  .registration-ledger-table th:nth-child(1), .registration-ledger-table td:nth-child(1),
  .registration-ledger-table th:nth-child(4), .registration-ledger-table td:nth-child(4),
  .registration-ledger-table th:nth-child(5), .registration-ledger-table td:nth-child(5),
  .registration-ledger-table th:nth-child(6), .registration-ledger-table td:nth-child(6) { display: none; }

  .primary-export-card { display: grid; }
  .button-row { display: grid; }
  .button-row .btn { width: 100%; }
}

@media (max-width: 480px) {
  .page { padding-inline: 9px; }
  .stats { gap: 7px; }
  .stat { padding: 9px; }
  .schedule-primary-actions,
  .compact-actions,
  .offering-row-actions { display: grid; grid-template-columns: 1fr; width: 100%; }
  .schedule-primary-actions .btn,
  .compact-actions .btn,
  .offering-row-actions .btn,
  .roster-toolbar .btn { width: 100%; max-width: none; }
  .meeting-days.compact-meeting-days { grid-template-columns: 1fr 1fr; }
  .backup-header, .backup-card { align-items: stretch; flex-direction: column; }
  .backup-actions { justify-content: flex-start; }
  .google-connect-button { min-width: 0; width: 100%; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition-duration: .01ms !important; animation-duration: .01ms !important; animation-iteration-count: 1 !important; }
}

/* v10.6 large-data navigation */
.table-pagination {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 7px 2px;
}
.table-pagination-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 7px;
  flex-wrap: wrap;
}
.compact-select-label {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  margin: 0;
  color: var(--text-muted, #586579);
  font-size: 11.5px;
  font-weight: 600;
}
.compact-select-label select {
  width: auto;
  min-width: 64px;
  min-height: 32px;
  height: 32px;
  padding: 4px 24px 4px 7px;
  font-size: 12px;
}
@media (max-width: 640px) {
  .table-pagination { align-items: flex-start; flex-direction: column; }
  .table-pagination-actions { width: 100%; justify-content: flex-start; }
  .table-pagination-actions .btn { width: auto; min-width: 82px; }
}

/* v10.7 manual payment / balance operations */
.manual-payment-search-row,.balance-filter-row{align-items:end}.grow-label{flex:1 1 20rem}.manual-charge-form{margin:1rem 0}.payment-summary-grid{margin-top:.5rem}.balance-filter-row{display:flex;flex-wrap:wrap;gap:.75rem}.balance-filter-row label{min-width:10rem}.balance-filter-row .grow-label{min-width:18rem}@media(max-width:760px){.manual-payment-search-row,.balance-filter-row{display:grid;grid-template-columns:1fr}.balance-filter-row label,.balance-filter-row .grow-label{min-width:0;width:100%}.manual-charge-form{display:grid;grid-template-columns:1fr}.manual-charge-form .btn{width:100%}}

/* v10.7.1 manual enrollment + keyed partial-payment workflow */
.manual-enrollment-form{margin-top:.25rem}.manual-enrollment-summary{border:1px solid var(--line);border-radius:12px;background:rgba(255,255,255,.025);padding:12px}.manual-enrollment-summary p{margin:.45rem 0 0}.manual-enrollment-summary-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:10px}.manual-enrollment-summary-grid>div{display:grid;gap:4px}.manual-enrollment-summary-grid strong{font-size:11px;text-transform:uppercase;letter-spacing:.06em;color:var(--muted)}.manual-enrollment-summary-grid span{font-weight:800}.manual-enrollment-actions{display:flex;justify-content:flex-end}.manual-enrollment-actions .btn{min-width:240px}#manualNewTotalPrice[readonly]{font-weight:900}@media(max-width:760px){.manual-enrollment-summary-grid{grid-template-columns:1fr 1fr}.manual-enrollment-actions{display:block}.manual-enrollment-actions .btn{width:100%;min-width:0}}@media(max-width:480px){.manual-enrollment-summary-grid{grid-template-columns:1fr}}
