:root {
  --ink: #111;
  --ink-2: #444;
  --ink-3: #666;
  --rule: #d9d9d9;
  --rule-strong: #111;
  --bg: #fff;
  --soft: #f5f5f5;
  --lean: #2F6B4F;
  --balanced: #1F4E8C;
  --member: #8A3B2E;
  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif;
  --mono: ui-monospace, "SF Mono", Menlo, Consolas, monospace;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 15px/1.5 var(--font); }
main { max-width: 1040px; margin: 0 auto; padding: 40px 24px 24px; }
h1 { font-size: 28px; font-weight: 700; margin: 0 0 8px; letter-spacing: -0.01em; }
h2 { font-size: 18px; font-weight: 700; margin: 0 0 4px; }
p { margin: 0; }
a { color: inherit; }
button, select, input { font: inherit; color: inherit; }

.page-head { display: flex; justify-content: space-between; align-items: center; gap: 16px; margin-bottom: 8px; }
.page-head h1 { margin: 0; }
a.btn { text-decoration: none; display: inline-block; }
.intro { max-width: 62ch; color: var(--ink-2); }
.intro + .intro { margin-top: 6px; }

section { border-top: 1px solid var(--rule-strong); padding: 22px 0 28px; margin-top: 28px; }
.section-head { display: flex; justify-content: space-between; align-items: baseline; gap: 16px; flex-wrap: wrap; margin-bottom: 14px; }
.section-head p { color: var(--ink-3); font-size: 14px; }
.step { font-weight: 400; color: var(--ink-3); margin-right: 8px; }

/* buttons */
.btn { background: var(--bg); border: 1px solid var(--ink); border-radius: 3px; padding: 7px 14px; cursor: pointer; font-size: 14px; }
.btn:hover { background: var(--soft); }
.btn-dark { background: var(--ink); color: #fff; }
.btn-dark:hover { background: #333; }
.linkish { background: none; border: 0; padding: 0; text-decoration: underline; cursor: pointer; font-size: 14px; color: var(--ink-2); }
.btn:focus-visible, .linkish:focus-visible, select:focus-visible, input:focus-visible { outline: 2px solid var(--balanced); outline-offset: 2px; }

/* upload */
.drop { border: 1px dashed #999; border-radius: 3px; padding: 28px 20px; text-align: center; cursor: pointer; }
.drop:hover, .drop.over, .drop:focus-visible { background: var(--soft); border-color: var(--ink); outline: none; }
.drop strong { display: block; font-size: 15px; margin-bottom: 2px; }
.drop span { color: var(--ink-3); font-size: 14px; }
.upload-links { display: flex; gap: 18px; margin-top: 12px; flex-wrap: wrap; }
.error { margin-top: 12px; color: #a11; font-size: 14px; }
.loaded { display: flex; justify-content: space-between; gap: 16px; align-items: flex-end; flex-wrap: wrap; }
.loaded-meta { color: var(--ink-3); font-size: 14px; }
.gym-input { font-size: 17px; font-weight: 600; border: 0; border-bottom: 1px solid var(--rule); padding: 2px 0; margin: 2px 0 4px; width: 320px; max-width: 100%; }
.gym-input:focus { outline: none; border-bottom-color: var(--ink); }

.tpl { margin-top: 14px; padding: 14px 16px; background: var(--soft); max-width: 640px; font-size: 14px; }
.tpl-row { display: flex; gap: 14px; align-items: center; flex-wrap: wrap; margin-top: 10px; }
.tpl input[type=date] { border: 1px solid #bbb; border-radius: 3px; padding: 4px 6px; margin-left: 4px; background: #fff; }
details.files { margin-top: 16px; font-size: 14px; color: var(--ink-2); }
details.files summary { cursor: pointer; }
details.files ul { margin: 8px 0 0; padding-left: 18px; }
details.files li { margin-bottom: 4px; }

/* tables */
table { border-collapse: collapse; width: 100%; }
th, td { text-align: left; padding: 7px 12px 7px 0; border-bottom: 1px solid var(--rule); vertical-align: middle; }
th { font-size: 13px; font-weight: 600; color: var(--ink-3); border-bottom-color: var(--ink); }
td.num, th.num { text-align: right; font-variant-numeric: tabular-nums; }

/* staffed hours */
.hours-table { max-width: 560px; }
.hours-table select { border: 1px solid #bbb; border-radius: 3px; padding: 4px 6px; background: #fff; }
.hours-table td:first-child { width: 120px; font-weight: 600; }
.hours-table .muted { color: var(--ink-3); font-size: 13px; }
.hours-actions { margin-top: 10px; display: flex; gap: 18px; flex-wrap: wrap; align-items: center; }
.note { margin-top: 14px; font-size: 14px; color: var(--ink-2); background: var(--soft); padding: 8px 12px; max-width: 62ch; }

/* summary */
.summary { display: grid; grid-template-columns: repeat(4, 1fr); border-top: 1px solid var(--rule); border-bottom: 1px solid var(--rule); margin: 0; }
.summary div { padding: 12px 14px 12px 0; }
.summary div + div { border-left: 1px solid var(--rule); padding-left: 14px; }
.summary dt { font-size: 13px; color: var(--ink-3); }
.summary dd { margin: 2px 0 0; font-size: 20px; font-weight: 700; font-variant-numeric: tabular-nums; }

/* heatmap */
.heatmap-wrap { overflow-x: auto; margin-top: 14px; }
.heatmap { display: grid; gap: 2px; min-width: 620px; }
.hm-hour { font: 11px var(--mono); color: var(--ink-3); text-align: center; }
.hm-day { font-size: 13px; font-weight: 600; display: flex; align-items: center; }
.hm-cell { height: 30px; display: grid; place-items: center; font: 11px var(--mono); }
.hm-cell.off { background: repeating-linear-gradient(135deg, #fff 0 4px, #e6e6e6 4px 5px); color: #777; }
.hm-cell.empty { background: #fafafa; }
.legend { display: flex; gap: 16px; align-items: center; margin-top: 10px; font-size: 13px; color: var(--ink-3); flex-wrap: wrap; }
.legend .ramp { display: inline-flex; vertical-align: middle; margin: 0 6px; }
.legend .ramp i { width: 18px; height: 10px; }
.legend .off-swatch { display: inline-block; width: 18px; height: 10px; vertical-align: middle; margin-right: 6px; border: 1px solid #ddd; background: repeating-linear-gradient(135deg, #fff 0 4px, #ccc 4px 5px); }

/* settings */
.settings { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px 24px; }
.settings label { display: block; font-size: 13px; color: var(--ink-2); margin-bottom: 4px; }
.settings .field { display: flex; align-items: center; gap: 6px; }
.settings input { width: 80px; border: 1px solid #bbb; border-radius: 3px; padding: 5px 7px; font-variant-numeric: tabular-nums; }
.settings .unit { color: var(--ink-3); font-size: 13px; }

/* plans table */
.plans td:first-child { font-weight: 600; }
.plans .swatch { display: inline-block; width: 10px; height: 10px; margin-right: 8px; }
.plans .desc { display: block; font-weight: 400; color: var(--ink-3); font-size: 13px; max-width: 36ch; }
.plans .default { font-weight: 400; color: var(--ink-3); font-size: 13px; }

/* plan switcher */
.switcher { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin: 12px 0 14px; }
.switcher-label { font-size: 14px; font-weight: 600; }
.tabs { display: inline-flex; border: 1px solid var(--ink); border-radius: 4px; overflow: hidden; }
.tab { background: #fff; border: 0; padding: 9px 18px; cursor: pointer; font-size: 14px; font-weight: 600; color: var(--ink); display: inline-flex; align-items: center; gap: 8px; }
.tab + .tab { border-left: 1px solid var(--ink); }
.tab:hover { background: var(--soft); }
.tab .dot { width: 10px; height: 10px; background: var(--mc); }
.tab[aria-selected=true] { background: var(--mc); color: #fff; }
.tab[aria-selected=true] .dot { background: #fff; }
.tab:focus-visible { outline: 2px solid var(--ink); outline-offset: -4px; }

/* schedule */
.schedule { overflow-x: auto; }
.sched-grid { min-width: 760px; }
.sched-axis, .sched-row { display: grid; grid-template-columns: 110px 1fr 60px; }
.sched-axis .ticks { position: relative; height: 20px; }
.sched-axis .ticks span { position: absolute; transform: translateX(-50%); font: 11px var(--mono); color: var(--ink-3); top: 2px; }
.sched-row { border-top: 1px solid var(--rule); padding: 8px 0; }
.sched-day { font-weight: 600; font-size: 14px; }
.sched-day small { display: block; font-weight: 400; color: var(--ink-3); font-size: 12px; }
.sched-hours { font-size: 13px; text-align: right; font-variant-numeric: tabular-nums; color: var(--ink-2); }
.sched-track { position: relative; }
.grid-lines { position: absolute; inset: 0; pointer-events: none; }
.grid-lines b { position: absolute; top: 0; bottom: 0; width: 1px; background: #f0f0f0; }
.sched-traffic { position: relative; height: 22px; margin-bottom: 4px; }
.sched-traffic i { position: absolute; bottom: 0; background: #d6d6d6; }
.sched-lanes { position: relative; }
.shift { position: absolute; height: 20px; background: var(--mc); color: #fff; font: 11px/20px var(--mono); padding: 0 6px; white-space: nowrap; overflow: hidden; border-radius: 2px; }
.shift.extra { background: color-mix(in srgb, var(--mc) 40%, white); color: #111; }
.sched-closed { font-size: 13px; color: var(--ink-3); }
.sched-key { font-size: 13px; color: var(--ink-3); margin-top: 10px; max-width: 75ch; }

.method { font-size: 13px; color: var(--ink-3); max-width: 75ch; margin-top: 18px; }

footer { max-width: 1040px; margin: 0 auto; padding: 20px 24px 40px; font-size: 13px; color: var(--ink-3); }

@media (max-width: 760px) {
  main { padding-top: 24px; }
  .summary { grid-template-columns: 1fr 1fr; }
  .summary div:nth-child(3) { border-left: 0; padding-left: 0; }
  .summary div:nth-child(n+3) { border-top: 1px solid var(--rule); }
  .settings { grid-template-columns: 1fr 1fr; }
  .plans-wrap { overflow-x: auto; }
  .plans { min-width: 640px; }
}
