/* Declare brand: see /brand/tokens.json. Pitch green, sun accent, cream surfaces. */
:root {
  --surface-100: #faf8f3; --surface-200: #ffffff;
  --ink: #14201a; --ink-muted: #5a6b61;
  --pitch: #1f5c3a; --on-pitch: #ffffff;
  --outfield: #e3eedf; --sun: #f2b63c;
  --status-claimed: #9a5b00; --status-unpaid: #b3261e;
  --line: #d9d4c7;
  --radius-sm: 6px; --radius-md: 12px; --radius-lg: 20px; --radius-pill: 999px;
  --font-display: "Fraunces", Georgia, serif;
  --font-sans: "Public Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--surface-100); color: var(--ink); font: 400 16px/24px var(--font-sans); }
a { color: var(--pitch); }
:focus-visible { outline: 3px solid var(--pitch); outline-offset: 2px; }
.skip { position: absolute; left: -999px; top: 0; background: var(--pitch); color: var(--on-pitch); padding: 12px 16px; z-index: 10; }
.skip:focus { left: 0; }
.wrap { max-width: 480px; margin: 0 auto; padding: 24px 16px 32px; display: flex; flex-direction: column; gap: 24px; }
.wrap.has-nav { padding-bottom: 112px; }

h1, h2, h3 { font-family: var(--font-display); font-weight: 600; margin: 0; }
h1 { font-size: 28px; line-height: 34px; }
h2 { font-size: 22px; line-height: 28px; }
h3 { font-size: 18px; line-height: 24px; }
.display { font-size: 40px; line-height: 44px; }
.sub, .muted { color: var(--ink-muted); }
.sub { margin: 4px 0 0; font-size: 14px; line-height: 20px; }
.small { font-size: 14px; line-height: 20px; }
.tiny { font-size: 13px; line-height: 16px; }
.label { font-size: 13px; line-height: 16px; font-weight: 600; color: var(--ink-muted); }
.num { font-variant-numeric: tabular-nums; }
.head .back { display: inline-flex; align-items: center; gap: 4px; min-height: 48px; font-size: 14px; font-weight: 600; text-decoration: none; }

.stack { display: flex; flex-direction: column; gap: 16px; }
.stack-sm { display: flex; flex-direction: column; gap: 8px; }
.row { display: flex; align-items: center; gap: 12px; }
.row.between { justify-content: space-between; align-items: flex-start; }
.grow { flex-grow: 1; min-width: 0; }
.wrap-row { display: flex; flex-wrap: wrap; gap: 8px; }

.card { background: var(--surface-200); border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 16px; display: flex; flex-direction: column; gap: 12px; }
.card.flush { padding: 4px 16px; gap: 0; }
.banner { background: var(--outfield); border-radius: var(--radius-md); padding: 12px 16px; display: flex; align-items: center; gap: 12px; text-decoration: none; color: var(--ink); }
.banner.sun { background: var(--sun); }
.list > * { padding: 12px 0; border-bottom: 1px solid var(--line); }
.list > *:last-child { border-bottom: 0; }

.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 48px; padding: 0 20px; border-radius: var(--radius-md); border: 1px solid var(--ink-muted); background: var(--surface-200); color: var(--ink); font: 600 14px/20px var(--font-sans); text-decoration: none; cursor: pointer; }
.btn-primary { background: var(--pitch); border-color: var(--pitch); color: var(--on-pitch); }
.btn-danger { color: var(--status-unpaid); border-color: var(--status-unpaid); }
.btn-block { width: 100%; min-height: 56px; font-size: 16px; }
.btn-sm { padding: 0 16px; }
.btn[aria-pressed="true"], .btn.on { background: var(--pitch); border-color: var(--pitch); color: var(--on-pitch); }
.btn:disabled { opacity: .5; cursor: default; }
form.inline { display: inline; }
.btns { display: flex; gap: 8px; }
.btns > * { flex: 1; }

.pill { display: inline-flex; align-items: center; border-radius: var(--radius-pill); padding: 4px 12px; font: 600 13px/16px var(--font-sans); background: var(--outfield); color: var(--pitch); white-space: nowrap; }
.pill.sun { background: var(--sun); color: var(--ink); }
.pill.line { background: transparent; border: 1px solid var(--ink-muted); color: var(--ink-muted); }
.badge { display: inline-flex; align-items: center; gap: 4px; font: 600 13px/16px var(--font-sans); white-space: nowrap; }
.st-unpaid { color: var(--status-unpaid); } .st-claimed { color: var(--status-claimed); } .st-confirmed { color: var(--pitch); } .st-muted { color: var(--ink-muted); }

.field { display: flex; flex-direction: column; gap: 8px; }
.field label, .field .label { font-size: 13px; line-height: 16px; font-weight: 600; color: var(--ink-muted); }
input[type=text], input[type=email], input[type=tel], input[type=number], input[type=date], input[type=time], input[type=password], select, textarea {
  width: 100%; min-height: 48px; padding: 0 12px; border: 1px solid var(--ink-muted); border-radius: var(--radius-md);
  background: var(--surface-200); color: var(--ink); font: 400 16px/24px var(--font-sans); }
textarea { padding: 12px; min-height: 96px; }
.checks label { display: flex; align-items: center; gap: 12px; min-height: 48px; font-size: 16px; color: var(--ink); font-weight: 400; }
input[type=checkbox], input[type=radio] { width: 24px; height: 24px; margin: 0; accent-color: var(--pitch); flex: none; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip { position: relative; }
.chip input { position: absolute; opacity: 0; inset: 0; width: 100%; height: 100%; margin: 0; cursor: pointer; }
.chip span { display: inline-flex; align-items: center; justify-content: center; min-width: 52px; min-height: 48px; padding: 0 14px; border: 1px solid var(--ink-muted); border-radius: var(--radius-md); background: var(--surface-200); font: 600 14px/20px var(--font-sans); }
.chip input:checked + span { background: var(--pitch); border-color: var(--pitch); color: var(--on-pitch); }
.chip input:focus-visible + span { outline: 3px solid var(--pitch); outline-offset: 2px; }
.chip input:disabled + span { opacity: .45; }

.flash { display: flex; align-items: center; gap: 8px; padding: 12px 16px; border-radius: var(--radius-md); font-size: 14px; line-height: 20px; }
.flash-ok { background: var(--outfield); color: var(--ink); }
.flash-err { background: var(--surface-200); border: 1px solid var(--status-unpaid); color: var(--status-unpaid); }

.tiles { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.tile { background: var(--surface-200); border: 1px solid var(--line); border-radius: var(--radius-md); padding: 12px; }
.tile .big { font: 600 20px/26px var(--font-display); font-variant-numeric: tabular-nums; }
.money-xl { font: 600 40px/44px var(--font-display); font-variant-numeric: tabular-nums; }
.code { font-weight: 600; font-variant-numeric: tabular-nums; letter-spacing: .04em; }
.dev { border: 1px dashed var(--ink-muted); border-radius: var(--radius-md); padding: 12px; font-size: 14px; line-height: 20px; }

.seg { display: flex; gap: 8px; }
.seg a { flex: 1; display: inline-flex; align-items: center; justify-content: center; min-height: 48px; border: 1px solid var(--ink-muted); border-radius: var(--radius-pill); background: var(--surface-200); color: var(--ink); font: 600 14px/20px var(--font-sans); text-decoration: none; text-align: center; padding: 0 8px; }
.seg a.on { background: var(--outfield); border-color: var(--pitch); color: var(--pitch); }

.avatars { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.avatar { width: 40px; height: 40px; border-radius: 50%; background: var(--pitch); color: var(--on-pitch); display: flex; align-items: center; justify-content: center; font: 600 13px/16px var(--font-sans); }
.comment { border: 1px solid var(--line); border-radius: var(--radius-md); padding: 12px; background: var(--surface-200); }

table { width: 100%; border-collapse: collapse; font-size: 14px; line-height: 20px; }
th, td { text-align: left; padding: 8px 4px; border-bottom: 1px solid var(--line); vertical-align: top; }
th { font-weight: 600; color: var(--ink-muted); }
.scroll-x { overflow-x: auto; }

.tabs { position: fixed; left: 0; right: 0; bottom: 0; z-index: 5; display: flex; justify-content: center; background: var(--surface-200); border-top: 1px solid var(--line); padding: 8px 8px calc(8px + env(safe-area-inset-bottom)); }
.tabs a { flex: 1; max-width: 96px; min-height: 48px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; text-decoration: none; color: var(--ink-muted); font: 600 12px/16px var(--font-sans); }
.tabs a.on { color: var(--pitch); }
.tabs .ico { position: relative; display: inline-flex; }
.tabs .dot { position: absolute; top: -6px; right: -12px; min-width: 18px; height: 18px; padding: 0 5px; border-radius: 9px; background: var(--sun); color: var(--ink); font: 600 11px/18px var(--font-sans); text-align: center; }

.icon { flex: none; }
.hr { border: 0; border-top: 1px solid var(--line); margin: 0; }
@media (min-width: 600px) { .wrap { padding-top: 40px; } }

[hidden] { display: none !important; }
h2 a { color: inherit; }
.seg a { white-space: nowrap; }
