/* GymClass studio console.
   Desk work: wide screens, long text, dense lists. Same faces as the
   published guides, so the family looks like one company. */

:root {
  --ink: #1C211F;
  --muted: #5D6B66;
  --ground: #F4F1EA;
  --card: #FFFFFF;
  --border: #DCD8CC;
  --green: #2F5D50;
  --green-dim: #274C41;
  --gold: #C9A227;
  --danger: #A63D2F;
  --ok: #2F6B4F;
  --shadow: 0 1px 2px rgba(28, 33, 31, 0.06), 0 8px 24px rgba(28, 33, 31, 0.05);
  --sans: 'Bricolage Grotesque', ui-sans-serif, system-ui, -apple-system, 'Segoe UI', sans-serif;
  --serif: 'Newsreader', ui-serif, Georgia, serif;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  background: var(--ground);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

a { color: var(--green); text-decoration-thickness: 1px; text-underline-offset: 2px; }

/* ------------------------------------------------------------------ header */

header.site {
  background: var(--green);
  color: #F4F1EA;
  padding: 14px 0;
}
header.site .inner {
  max-width: 880px; margin: 0 auto; padding: 0 20px;
  display: flex; align-items: baseline; gap: 14px; flex-wrap: wrap;
}
header.site .mark { font-weight: 700; font-size: 18px; letter-spacing: -0.01em; }
header.site .where { color: rgba(244, 241, 232, 0.72); font-size: 14px; }
header.site .who { margin-left: auto; display: flex; align-items: center; gap: 14px;
  font-size: 14px; color: rgba(244, 241, 232, 0.86); }
header.site button.link { color: #F4F1EA; }

main { max-width: 880px; margin: 0 auto; padding: 28px 20px 80px; }

h1 { font-family: var(--serif); font-size: 32px; font-weight: 600;
     letter-spacing: -0.01em; margin: 0 0 6px; text-wrap: balance; }
h2 { font-size: 17px; margin: 0; letter-spacing: -0.005em; }
p.lede { color: var(--muted); margin: 0 0 24px; max-width: 62ch; }
p.note { color: var(--muted); font-size: 14px; margin: 6px 0 0; max-width: 62ch; }

/* ------------------------------------------------------------------- cards */

section.card {
  background: var(--card); border: 1px solid var(--border); border-radius: 10px;
  margin-bottom: 14px; box-shadow: var(--shadow); overflow: hidden;
}
section.card > .head {
  display: flex; align-items: center; gap: 12px;
  padding: 16px 18px; cursor: pointer; width: 100%; background: none;
  border: 0; font: inherit; color: inherit; text-align: left;
}
section.card > .head:hover { background: #FBFAF6; }
section.card > .head .grow { flex: 1; min-width: 0; }
section.card > .head .sub { color: var(--muted); font-size: 14px; }
section.card > .body { padding: 4px 18px 20px; border-top: 1px solid var(--border); }

/* A dot, not a tick: state is a fact about the studio, not a score. */
.dot { width: 10px; height: 10px; border-radius: 50%; flex: none;
       background: var(--border); }
.dot.done { background: var(--ok); }
.dot.todo { background: var(--gold); }

.chev { color: var(--muted); font-size: 13px; flex: none; }

/* ------------------------------------------------------------------- forms */

label { display: block; font-size: 13px; font-weight: 600; color: var(--muted);
        margin: 14px 0 5px; letter-spacing: 0.01em; }
input[type=text], input[type=email], input[type=password], input[type=number],
input[type=color], select, textarea {
  width: 100%; font: inherit; color: var(--ink);
  background: #FFF; border: 1px solid var(--border); border-radius: 8px;
  padding: 10px 12px;
}
input[type=color] { padding: 4px; height: 42px; }
textarea { min-height: 220px; font-size: 15px; line-height: 1.6; resize: vertical; }
/* A line of directions is not a waiver. */
textarea.short { min-height: 0; }
input:focus-visible, select:focus-visible, textarea:focus-visible,
button:focus-visible { outline: 2px solid var(--green); outline-offset: 2px; }

.row { display: flex; gap: 14px; flex-wrap: wrap; }
.row > * { flex: 1 1 200px; }

button {
  font: inherit; font-weight: 600; cursor: pointer;
  background: var(--green); color: #F4F1EA;
  border: 0; border-radius: 8px; padding: 11px 18px;
}
button:hover { background: var(--green-dim); }
button[disabled] { opacity: 0.45; cursor: default; }
button.quiet { background: #EFECE3; color: var(--ink); }
button.quiet:hover { background: #E6E2D6; }
button.link { background: none; color: var(--green); padding: 4px 0; font-weight: 600; }
button.link:hover { background: none; text-decoration: underline; }
button.danger { background: none; color: var(--danger); padding: 4px 0; }
button.danger:hover { background: none; text-decoration: underline; }
.actions { display: flex; gap: 10px; align-items: center; margin-top: 18px; flex-wrap: wrap; }

/* Editing one thing out of a list, in place, below it. */
.editing { border-top: 1px solid var(--border); margin-top: 20px; }
.editing h3 { margin: 16px 0 0; font-size: 16px; }

/* ------------------------------------------------------------------- lists */

ul.plain { list-style: none; margin: 10px 0 0; padding: 0; }
ul.plain li {
  display: flex; align-items: baseline; gap: 12px;
  padding: 11px 0; border-top: 1px solid var(--border);
}
ul.plain li .grow { flex: 1; min-width: 0; }
ul.plain li .meta { color: var(--muted); font-size: 14px; font-variant-numeric: tabular-nums; }
ul.plain li:first-child { border-top: 0; }
.empty { color: var(--muted); font-size: 15px; margin: 10px 0 0; }

table.studios { width: 100%; border-collapse: collapse; margin-top: 8px; }
table.studios th {
  text-align: left; font-size: 12px; text-transform: uppercase;
  letter-spacing: 0.06em; color: var(--muted); font-weight: 700;
  padding: 0 10px 8px 0; white-space: nowrap;
}
table.studios td { padding: 10px 10px 10px 0; border-top: 1px solid var(--border);
                   font-variant-numeric: tabular-nums; vertical-align: baseline; }
table.studios td.name { font-weight: 600; font-variant-numeric: normal; }
.scroll { overflow-x: auto; }

.pill { display: inline-block; font-size: 12px; font-weight: 700;
        letter-spacing: 0.04em; text-transform: uppercase;
        padding: 3px 8px; border-radius: 999px; }
.pill.open { background: #E3EFE6; color: var(--ok); }
.pill.shut { background: #F3EAD8; color: #7A5B12; }

code.code {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 20px; letter-spacing: 3px; font-weight: 600;
  background: var(--ground); border: 1px solid var(--border);
  border-radius: 8px; padding: 8px 14px; display: inline-block;
}

/* ------------------------------------------------------------------ status */

.say { margin: 14px 0 0; padding: 11px 14px; border-radius: 8px; font-size: 15px; }
.say.bad { background: #F7E6E2; color: #7A2A1F; }
.say.good { background: #E3EFE6; color: #1F4A35; }

/* ------------------------------------------------------------------ signin */

.gate { max-width: 420px; margin: 8vh auto; padding: 0 20px; }
.gate .card {
  background: var(--card); border: 1px solid var(--border); border-radius: 10px;
  box-shadow: var(--shadow); padding: 22px 24px 26px;
}
.gate h1 { font-size: 27px; }
.tabs { display: flex; gap: 18px; margin: 0 0 4px; }
.tabs button { background: none; color: var(--muted); padding: 6px 0; }
.tabs { border-bottom: 1px solid var(--border); margin-bottom: 4px; }
.tabs button { border-bottom: 2px solid transparent; margin-bottom: -1px; border-radius: 0; }
.tabs button[aria-selected=true] { color: var(--ink); border-bottom-color: var(--green); }
.tabs button:hover { background: none; color: var(--ink); }

footer.site { color: var(--muted); font-size: 13px; text-align: center; padding: 30px 0 0; }

@media (max-width: 560px) {
  h1 { font-size: 26px; }
  main { padding-top: 20px; }
}

/* ------------------------------------------------- keeping in touch */

h2.divider {
  font-family: var(--serif); font-size: 24px; font-weight: 600;
  margin: 38px 0 4px; padding-top: 26px;
  border-top: 1px solid var(--border);
}

.everybody {
  display: flex; align-items: center; gap: 9px;
  text-transform: none; font-size: 14px; font-weight: 600;
  color: var(--muted); margin: 16px 0 0;
}

.history { flex-basis: 100%; margin: 8px 0 2px 30px; }
.history .event {
  display: flex; gap: 12px; padding: 5px 0;
  font-size: 14px; color: var(--ink);
}
.history .when {
  color: var(--muted); min-width: 7.5rem; flex: none;
  font-variant-numeric: tabular-nums;
}

/* The two-factor QR, and the secret for anybody who cannot scan it. */
.qr { display: block; width: 190px; height: 190px; margin: 14px 0; }
.qr svg { width: 100%; height: 100%; }
details summary { cursor: pointer; color: var(--green); font-weight: 600; font-size: 14px; }
.secret {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 15px; letter-spacing: 2px; word-break: break-all;
  background: #EFECE3; padding: 10px 12px; border-radius: 8px; margin-top: 8px;
}

/* Money: months, and what came back. */
.monthHead {
  display: flex; align-items: baseline; justify-content: space-between;
  margin: 22px 0 2px; font-size: 15px; font-weight: 700;
}
.monthHead:first-child { margin-top: 10px; }
.monthNet { font-variant-numeric: tabular-nums; }
.refunded { color: var(--danger); }
