/* ============================================================
   THE NOMAD ACCOUNT — forms, the in-page sheet, toasts, log in / sign up, the sign-up wizard, the profile, your picture.
   One stylesheet for both sites (Rikki, 2026-09-23: "it's one product across multiple websites"); moved from
   nomadfloripa.com's app.css. The screens are /shared/js/account/*.js. Needs shared/css/tokens.css + avatar.css.
   ============================================================ */

/* ---------- Forms ---------- */
.field { display: flex; flex-direction: column; gap: 6px; }
.field label { font-size: 12px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--text-muted); }
.field input, .field select {
  height: 48px;
  padding: 0 14px;
  font-family: var(--font);
  font-size: 16px;
  color: var(--text-primary);
  background: var(--bg-page);
  border: 1.5px solid var(--border-hairline);
  border-radius: var(--radius-sm);
  outline: none;
}
.field input:focus, .field select:focus { border-color: var(--action-primary); }

/* The WhatsApp field's country-code select + number input, side by side (shared/js/lib/phone-field.js). */
.field--phone { display: flex; gap: 8px; }
.field--phone select { flex: 0 0 auto; width: 104px; padding: 0 8px; }
.field--phone input { flex: 1 1 auto; min-width: 0; }

.choice {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 16px;
  border: 1.5px solid var(--border-hairline);
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: border-color var(--dur-state) var(--ease-standard), background-color var(--dur-state) var(--ease-standard);
}
.choice:hover { border-color: rgba(0, 0, 0, 0.2); }   /* --border-strong was never defined in tokens.css */
.choice:has(input:checked) { border-color: var(--action-primary); background: var(--action-tint); }
.choice input { width: 20px; height: 20px; accent-color: var(--action-primary); flex-shrink: 0; }
.choice__text { flex: 1; display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.choice__title { font-size: 16px; font-weight: 700; }
.choice__meta { font-size: 13px; color: var(--text-muted); }
/* sharing the list from a computer (ui/signup.js shareStep): copied → open the group → paste → send */
.share-steps { display: grid; gap: 10px; padding: 0; list-style: none; counter-reset: share; }
.share-steps li { display: grid; grid-template-columns: 28px 1fr; align-items: center; column-gap: 12px; font-size: 15px; line-height: 1.4; counter-increment: share; }
.share-steps li::before { content: counter(share); display: grid; place-items: center; width: 28px; height: 28px; border-radius: 50%; background: var(--whatsapp, #25D366); color: #fff; font-size: 13px; font-weight: 800; }
.share-steps kbd { padding: 1px 6px; border: 1px solid var(--border-hairline); border-bottom-width: 2px; border-radius: 4px; font: inherit; font-size: 13px; font-weight: 700; }
.share-text { width: 100%; padding: 10px 12px; border: 1.5px solid var(--border-hairline); border-radius: var(--radius-sm); font: inherit; font-size: 13px; resize: none; }
/* the comprovante upload (ui/signup.js): the label is the button; the real input is hidden but still focusable */
.upload { position: relative; }
.upload__input { position: absolute; width: 1px; height: 1px; opacity: 0; overflow: hidden; }
.upload__box { display: flex; align-items: center; gap: 14px; min-height: 72px; padding: 14px 16px; border: 1.5px dashed rgba(0, 0, 0, 0.2); border-radius: var(--radius-sm); cursor: pointer; transition: border-color var(--dur-state) var(--ease-standard), background-color var(--dur-state) var(--ease-standard); }
.upload__box:hover { border-color: var(--action-primary); }
.upload__input:focus-visible + .upload__box { outline: 2px solid var(--action-primary); outline-offset: 2px; }
.upload__icon { flex: 0 0 auto; color: var(--action-primary); }
.upload__text { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.upload__text strong { overflow: hidden; font-size: 16px; text-overflow: ellipsis; white-space: nowrap; }
.upload__text span { font-size: 13px; color: var(--text-muted); }
.upload.is-chosen .upload__box { border-style: solid; border-color: var(--action-primary); background: var(--action-tint); }
.choice__tag { display: table; margin-top: 2px; padding: 2px 8px; border-radius: var(--radius-sm); background: var(--action-tint); color: var(--action-primary); font-size: 12px; font-weight: 700; vertical-align: 2px; white-space: nowrap; }   /* square-cornered, never a capsule (Rikki, 2026-09-26) */
.choice__price { font-size: 16px; font-weight: 800; font-variant-numeric: tabular-nums; }
.choice__price--later { display: flex; flex-direction: column; align-items: flex-end; line-height: 1.2; }   /* a waiting-list place: its price, paid later */
.choice__when { font-size: 12px; font-weight: 600; color: var(--text-muted); }
.choice[aria-disabled="true"] { opacity: 0.5; pointer-events: none; }

/* ---------- Sheet (login, sign-up) ----------
   Rikki, 2026-09-22: "I do not like it when a modal pops up or the page jumps and changes — when
   someone clicks sign up/sign in the main page just transitions to the sign up or login flow."
   A full-viewport takeover (even one that slides instead of fades) still replaces the crest and
   nav with a bare screen — that reads as "somewhere else," not "this page." So the sheet mounts
   inside .app-main (sheet.js), which volleyball-app.css's flexbox already sizes to exactly the
   band between the 108/70px header and the tab bar: the crest, title and tabs never leave, only
   this content band transitions — the same vertical arrival language the rest of the app uses
   (`snap.css` "Arrival transitions"), scaled to the band instead of the full screen. Closing
   reverses it, faster (--dur-close/--ease-exit) so it feels responsive, not lingering. */
.sheet {
  position: absolute;
  inset: 0;
  z-index: 40;
  display: flex;
  flex-direction: column;
  background: var(--bg-page);
  transform: translateY(100%);
  transition: transform var(--dur-close) var(--ease-exit);
  will-change: transform;
}
.sheet.is-open { transform: none; transition-duration: var(--dur-open); transition-timing-function: var(--ease-entrance); }
/* Rikki, 2026-09-22: "make sure the x on the right is aligned with the rest of the page content"
   — .sheet__bar spanned the full viewport while the header/tab content is capped at 1280px and
   centred (volleyball-app.css's desktop .app-header__inner), so past ~1330px wide the close button
   drifted outward past the header's own right edge. Same 1280px frame here closes the gap. */
.sheet__bar { flex: 0 0 auto; display: grid; grid-template-columns: minmax(72px, 1fr) minmax(0, 520px) minmax(72px, 1fr); align-items: center; gap: 12px; height: 48px; width: 100%; max-width: 1280px; margin-inline: auto; padding: 0 var(--gutter); box-sizing: border-box; }
.sheet__bar-start { justify-self: start; }
.sheet__bar-mid { min-width: 0; }
.sheet__bar-mid > .sheet__step { display: block; overflow: hidden; text-align: center; text-overflow: ellipsis; white-space: nowrap; }
.sheet__back { display: inline-flex; align-items: center; gap: 4px; height: 44px; margin-left: -8px; padding: 0 8px; background: none; border: 0; border-radius: var(--radius-sm); font: inherit; font-size: 15px; font-weight: 700; color: var(--text-primary); cursor: pointer; }
.sheet__back span { font-size: 22px; line-height: 1; margin-top: -2px; }
.sheet__back:focus-visible, .sheet__close:focus-visible { outline: 2px solid var(--action-primary); outline-offset: -2px; }
/* a locked sheet's way out, where the × was (the sign-up wizard's Log out) — Back's look, on the right */
.sheet__bar-end { justify-self: end; }
.sheet__exit { height: 44px; margin-right: -8px; padding: 0 8px; background: none; border: 0; border-radius: var(--radius-sm); font: inherit; font-size: 15px; font-weight: 700; color: var(--text-muted); white-space: nowrap; cursor: pointer; }
.sheet__exit:focus-visible { outline: 2px solid var(--action-primary); outline-offset: -2px; }
/* while the wizard holds a new account, the header's links and the tabs are inert (onboarding.js holdNav) — and look it */
nav[inert], [data-account-slot][inert], .app-header__crest[inert] { opacity: 0.4; }
/* …and from the first frame, when the hint says this account is mid-wizard (nomadfloripa.com's boot.js → html.is-held): the page
   under the wizard is never drawn and the header is already held, and the wizard is simply there — no slide up over nothing.
   holdForOnboarding (onboarding.js) takes it off. */
.js.is-held .app-main > :not(.sheet), .js.is-held .legal-notice, .js.is-held .pager { visibility: hidden; }   /* .pager: Home's screen ticks, outside the band */
.js.is-held nav, .js.is-held [data-account-slot], .js.is-held .app-header__crest { opacity: 0.4; pointer-events: none; }
.js.is-held .sheet { transition: none; }
.sheet__step { font-size: 12px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--text-muted); }   /* reused by login.js for the "or" divider */
.sheet__close { justify-self: end; width: 44px; height: 44px; margin-right: -12px; background: none; border: 0; border-radius: var(--radius-sm); font-size: 26px; line-height: 1; cursor: pointer; }
/* Rikki, 2026-09-22: "minimal scroll, better if none, for all screen shapes and sizes". Spacing
   scales with the window's height, not a fixed 64px of air: tight on a phone, roomy on a desktop. */
.sheet__body { flex: 1 1 0; min-height: 0; overflow-y: auto; display: flex; justify-content: center; padding: clamp(4px, 2vh, 28px) var(--gutter) clamp(12px, 2.5vh, 32px); }
.sheet__inner { width: min(100%, 520px); display: flex; flex-direction: column; gap: clamp(12px, 2.2vh, 24px); }
.sheet__inner > * { flex-shrink: 0; }   /* the column is stretched to the body's height: on a tall screen of content, a child with overflow:hidden (the wizard's progress bar) would otherwise shrink to 0 */
/* Rikki, 2026-09-22: "everything is centered so the text should be too" — the sheet's content
   column is centered in the frame and every button/field in it already reads centered; the
   title and lede were the one thing still set left, an inconsistency next to all of it. */
.sheet__title { font-size: clamp(1.5rem, min(6vw, 4.2vh), 2.5rem); font-weight: 900; line-height: 1.05; letter-spacing: -0.03em; text-wrap: balance; text-align: center; }
.sheet__lede { font-size: 15px; line-height: 1.45; color: var(--text-muted); margin-top: calc(clamp(12px, 2.2vh, 24px) * -0.5); text-align: center; text-wrap: balance; }
.sheet__foot { flex: 0 0 auto; padding: 12px var(--gutter) max(12px, env(safe-area-inset-bottom)); border-top: 1px solid var(--border-hairline); display: flex; justify-content: center; }
.sheet__foot-inner { width: min(100%, 520px); display: flex; flex-direction: column; gap: 8px; }
.sheet__foot .form-hint, .sheet__foot .foot-link { text-align: center; }
.foot-link { font-size: 14px; color: var(--text-muted); }
.sheet__foot .btn { width: 100%; }
.sheet__total { display: flex; justify-content: space-between; align-items: baseline; font-size: 14px; color: var(--text-muted); }
.sheet__total strong { font-size: 22px; color: var(--text-primary); font-variant-numeric: tabular-nums; }
.sheet__later { font-size: 13px; font-variant-numeric: tabular-nums; }   /* on the total's own line: " · R$30 more when a court is booked for you" */
.stack { display: flex; flex-direction: column; gap: 10px; }
.rule { height: 1px; background: var(--border-hairline); border: 0; }

.pay {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 4px 12px;
  align-items: center;
  padding: 14px 16px;
  border: 1.5px solid var(--border-hairline);
  border-radius: var(--radius-sm);
}
.pay__label { font-size: 12px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--text-muted); }
.pay__value { grid-column: 1; font-size: 17px; font-weight: 700; word-break: break-all; }
.pay .btn { grid-column: 2; grid-row: 1 / span 2; }
/* a short sheet (a small phone, a landscape window): each way to pay is one line — the label, the key, Copy — so the pay sheet
   fits without scrolling (2026-09-29: the football month's sheet scrolled 102px at 360×640). Keyed to the sheet, like the ledes below. */
@container sheet (max-height: 640px) {
  .stack:has(> .pay) { gap: 4px; }
  .pay { grid-template-columns: 4.5em 1fr auto; padding: 4px 4px 4px 12px; }
  .pay__value { grid-column: 2; font-size: 15px; line-height: 1.25; }
  .pay .btn { grid-column: 3; grid-row: 1; height: 32px; }
  .stack:has(> .pay) > .notice { font-size: 13px; padding: 8px 12px; }
}
@container sheet (max-height: 500px) {
  .stack:has(> .pay) > .notice { display: none; }   /* "coming from abroad?" is shed with the ledes — the ways to pay stay */
}
.notice--pre { white-space: pre-wrap; }
.notice { font-size: 14px; line-height: 1.5; padding: 12px 14px; background: var(--surface-subtle); border-radius: var(--radius-sm); color: var(--text-primary); }


/* ---------- Toasts — "Welcome back", "You're logged out", "Profile saved". Here, not tool.css:
   every page loads this file, only Events loaded that one, so a toast on Home was unstyled. ---------- */
.toasts { position: fixed; left: 50%; bottom: calc(var(--tabbar-space) + 16px); z-index: 80; transform: translateX(-50%); display: grid; gap: 8px; justify-items: center; pointer-events: none; width: min(92vw, 420px); }
.toast { padding: 12px 16px; background: var(--text-primary); color: #fff; border-radius: var(--radius-sm); font-size: 14px; font-weight: 600; opacity: 0; transform: translateY(8px); transition: opacity var(--dur-open) var(--ease-entrance), transform var(--dur-open) var(--ease-entrance); }
.toast.is-in { opacity: 1; transform: none; }
.toast--error { background: var(--brand-red); }
@media (min-width: 900px) { .toasts { bottom: 24px; } }

/* `hidden` must always win: any class that sets display (.text-link inline, .stack flex, .btn inline-flex) otherwise beats the
   browser's own [hidden] rule and the element shows anyway — "Forgot password?" was showing on the sign-up form. */
[hidden] { display: none !important; }

/* ---------- Accounts: log in / sign up (ui/login.js), the wizard (ui/onboarding.js), the profile (ui/profile.js) ---------- */
.sheet__title:focus { outline: none; }   /* focus lands on the title so a screen reader announces the new screen; no ring for that */

/* a link inside a sentence ("Already have an account? Log in") — .link in tool.css is a standalone 44px button */
.text-link { display: inline; padding: 0; margin: 0; background: none; border: 0; font: inherit; font-weight: 700; color: var(--action-primary); cursor: pointer; }
.text-link:hover { text-decoration: underline; text-underline-offset: 3px; }
.text-link:focus-visible { outline: 2px solid var(--action-primary); outline-offset: 2px; border-radius: 2px; }
.text-link--small { font-size: 13px; }

.auth__switch { margin-top: -8px; font-size: 15px; text-align: center; }
/* "Continue with Google" — Google's own Sign In branding guidelines (required for app
   verification, developers.google.com/identity/branding-guidelines), not this site's tokens:
   white fill, #747775 1px border, #1F1F1F text, the logo at its standard size and full gradient
   colour on white, never recoloured. Rikki, 2026-09-22: "surely the continue with google button
   should have google on it not blue" — right on both counts: it needs the G, and a solid blue
   fill is a common misconception, not the spec — the compliant button is white, not blue. */
.btn--google { background: #FFFFFF; border: 1px solid #747775; color: #1F1F1F; gap: 10px; }
.btn--google:hover { background: #F8F9FA; }
.btn--google svg { flex: 0 0 auto; }
/* Moved here from nomadfloripa.com's nf.css (2026-09-24): the button is shared (login.js), but its style lived on one site, so
   on nomadvolleyball.com the G sat flush against "Continue with Google" with the wrong border. */
/* The first log-in screen as one group (login.js emailStep, 2026-09-24 — after Claude's own log-in): Google, or, the email with
   its button right under it, then the quiet lines. Centred in the band ("safe": on a short screen it starts at the top and
   scrolls rather than losing its head), never a lone button at the foot with empty space above it. */
.sheet__inner:has(> .auth--start) { justify-content: safe center; }
.auth--start { display: flex; flex-direction: column; gap: 12px; }
.auth--start .btn { width: 100%; }
.auth--start .auth__or { margin-block: 4px; }
.auth__email-form { display: flex; flex-direction: column; gap: 12px; }
@container sheet (min-height: 560px) { .auth--start .btn, .auth--start .field input { height: 52px; } }
.auth--start .auth__switch { margin-top: 8px; }
.auth--start .auth__switch + .auth__switch { margin-top: -4px; }
.auth--start .auth__legal { margin-top: 4px; }
/* short windows (phones on their side, a squashed desktop): tighter, and where there's width the email and its button share a row */
@container sheet (max-height: 500px) {
  .auth--start { gap: 8px; }
  .auth--start .auth__or, .auth--start .auth__switch, .auth--start .auth__switch + .auth__switch { margin: 0; }
}
@container sheet (max-height: 420px) and (min-width: 440px) {
  .auth__email-form { flex-direction: row; align-items: flex-start; gap: 8px; }
  .auth__email-form .field { flex: 1 1 auto; min-width: 0; }
  .auth--start .auth__email-form .btn { flex: 0 0 auto; width: auto; }
}
@container sheet (max-height: 340px) { .auth--start .btn, .auth--start .field input { height: 40px; } }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.auth__or { display: flex; align-items: center; gap: 12px; font-size: 12px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--text-muted); }
.auth__or::before, .auth__or::after { content: ''; flex: 1; height: 1px; background: var(--border-hairline); }

/* ---------- The sign-in card and the members' gate (shared/public/js/account/gate.js) — Home's first screen, the tournament app's
   members-only screen and Football's: one look on both sites (Rikki, 2026-09-26: "shouldn't we have a similar log in design to the
   main site"). The card moved here from nomadfloripa.com's home.css. ---------- */
.signin-card { display: grid; gap: 10px; width: min(100%, 26rem); padding: clamp(14px, 2.4cqh, 20px); border: 1px solid var(--border-hairline); border-radius: var(--radius-sm); background: var(--bg-page); }
.signin-card .btn { width: 100%; padding: 0 14px; }
.signin-card .auth__or { margin: 0; }
.signin-card__legal { margin: 0; font-size: 12px; line-height: 1.45; color: var(--text-muted); text-align: center; }
/* the gate: Home's headline, its line and the card on one centred axis, sized by the gate's own box (a size container), so it fits
   any window without scrolling */
.signin-gate { container: signin-gate / size; flex: 1 1 0; min-height: 0; width: 100%; display: flex; }
.signin-gate__in { margin: auto; width: 100%; display: flex; flex-direction: column; align-items: center; padding-block: clamp(8px, 3cqh, 24px); text-align: center; }
.signin-gate__title { margin: 0; font-size: clamp(2rem, min(11cqw, 8.5cqh), 5.25rem); font-weight: 900; line-height: 0.98; letter-spacing: -0.035em; text-wrap: balance; color: var(--text-primary); }
.signin-gate__lede { margin: clamp(10px, 2cqh, 20px) 0 0; max-width: 34em; font-size: clamp(1rem, min(2.8cqw, 2.4cqh), 1.3125rem); line-height: 1.45; color: var(--text-muted); text-wrap: pretty; }
.signin-gate .signin-card { margin-top: clamp(16px, 3cqh, 32px); }
/* a short screen sheds, lightest first — the line under the heading, then the "or" — the two buttons and the consent line under them
   always stay (2026-09-28: the consent line used to go first, so a short window started an account without it) */
@container signin-gate (max-height: 400px) { .signin-gate__lede { display: none; } }
@container signin-gate (max-height: 290px) { .signin-gate .auth__or { display: none; } .signin-gate .signin-card { gap: 6px; padding: 10px; } .signin-gate .signin-card .btn { height: 40px; min-height: 40px; } }

.field__row { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; }
.field__label { font-size: 12px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--text-muted); }
.field__hint { font-size: 13px; line-height: 1.4; color: var(--text-muted); }
.field__hint[data-pw-hint]::before { content: '○ '; }
.field__hint.is-met { color: var(--status-ok); }
.field__hint.is-met::before { content: '✓ '; }
.field__error { font-size: 13px; font-weight: 600; line-height: 1.4; color: var(--brand-red); }
.field input[aria-invalid="true"] { border-color: var(--brand-red); }

/* password + Show/Hide: the toggle sits inside the field, a full 40px tall target */
.pw { position: relative; display: flex; }
.pw input { flex: 1; min-width: 0; padding-right: 72px; }
.pw__toggle { position: absolute; top: 50%; right: 4px; transform: translateY(-50%); min-width: 56px; height: 40px; padding: 0 10px; background: none; border: 0; border-radius: var(--radius-sm); font: inherit; font-size: 13px; font-weight: 700; color: var(--action-primary); cursor: pointer; }
.pw__toggle:focus-visible { outline: 2px solid var(--action-primary); outline-offset: -2px; }

.check { display: flex; align-items: center; gap: 10px; min-height: 44px; font-size: 15px; cursor: pointer; }
.check input { flex: 0 0 auto; width: 20px; height: 20px; accent-color: var(--action-primary); }

/* what only the demo shows — never mistaken for the real thing */
.demo-note { padding: 10px 12px; border: 1.5px dashed rgba(0, 0, 0, 0.2); border-radius: var(--radius-sm); font-size: 13px; line-height: 1.5; color: var(--text-muted); text-align: left; }
.demo-note strong { display: inline-block; margin-right: 6px; padding: 1px 6px; border-radius: 3px; background: var(--text-primary); color: #fff; font-size: 11px; letter-spacing: 0.06em; text-transform: uppercase; }

/* the demo's Google account chooser */
.account-choice { display: flex; align-items: center; gap: 12px; width: 100%; min-height: 56px; padding: 10px 14px; text-align: left; background: var(--bg-page); border: 1.5px solid var(--border-hairline); border-radius: var(--radius-sm); font: inherit; color: var(--text-primary); cursor: pointer; }
.account-choice:hover { border-color: rgba(0, 0, 0, 0.2); }
.account-choice__text { display: flex; flex-direction: column; min-width: 0; }
.account-choice__text strong { font-size: 15px; }
.account-choice__text span { overflow: hidden; font-size: 13px; color: var(--text-muted); text-overflow: ellipsis; white-space: nowrap; }
.avatar--ghost { background: var(--surface-subtle); color: var(--text-primary); font-size: 18px; font-weight: 600; }
.avatar--xl { width: 72px; height: 72px; font-size: 24px; }

/* the wizard's progress */
.wizard-progress { height: 4px; overflow: hidden; background: var(--surface-subtle); border-radius: 2px; }
.wizard-progress span { display: block; height: 100%; background: var(--action-primary); transition: width var(--dur-enter) var(--ease-entrance); }
.wizard-bar { display: flex; align-items: center; gap: 10px; }
.wizard-bar .wizard-progress { flex: 1; }
.wizard-step { flex: 0 0 auto; font-size: 12px; font-weight: 700; letter-spacing: 0.04em; color: var(--text-muted); font-variant-numeric: tabular-nums; }
.choice-hint { font-size: 13px; line-height: 1.4; color: var(--text-muted); text-align: center; }
.sheet .choice { padding: 12px 14px; }
.auth__email { display: flex; justify-content: center; align-items: center; gap: 8px; flex-wrap: wrap; font-size: 15px; }
.auth__email strong { overflow-wrap: anywhere; }
.auth__legal { font-size: 12px; line-height: 1.45; color: var(--text-muted); text-align: center; }
.auth__legal a, .auth__legal .text-link, .signin-card__legal a { color: inherit; font-weight: 600; text-decoration: underline; text-underline-offset: 2px; }   /* .text-link: the wizard's Delete your account */

/* the profile */
.profile-head { display: flex; justify-content: center; margin-bottom: -4px; }
.profile-head__meta { margin-top: -8px; font-size: 14px; line-height: 1.5; color: var(--text-muted); text-align: center; overflow-wrap: anywhere; }
.profile__note { font-size: 14px; line-height: 1.5; color: var(--text-muted); }
.profile__note strong { color: var(--text-primary); overflow-wrap: anywhere; }
.readonly { font-size: 16px; line-height: 1.4; }
/* the profile's rows: label over what it holds, chevron on the right */
.rows { display: grid; border-top: 1px solid var(--border-hairline); }
.row-btn__text { display: flex; flex-direction: column; min-width: 0; gap: 1px; }
.row-btn__value { overflow: hidden; font-size: 13px; font-weight: 400; color: var(--text-muted); text-overflow: ellipsis; white-space: nowrap; }
.row-btn--todo .row-btn__label { color: var(--action-primary); }
.check--row { min-height: 52px; border-bottom: 1px solid var(--border-hairline); }
/* the beach volleyball rules (ui/beach-rules.js): a numbered list, the rule bold, why under it */
.sheet--doc .sheet__title, .sheet--doc .sheet__lede { text-align: left; text-wrap: pretty; }
/* …and the small lines between them and the fields go with them (Rikki, 2026-09-29, of the password step and the wizard: "left align
   those too"). The foot stays centred under its full-width button. */
.sheet--doc .sheet__inner .auth__switch, .sheet--doc .sheet__inner .auth__legal, .sheet--doc .sheet__inner .choice-hint { text-align: left; }
.sheet--doc .auth__email { justify-content: flex-start; }
.rulebook { display: grid; gap: clamp(10px, 1.8vh, 16px); counter-reset: rule; }
.rulebook li { display: grid; grid-template-columns: 28px 1fr; column-gap: 12px; counter-increment: rule; }
.rulebook li::before { content: counter(rule); grid-row: span 2; display: grid; place-items: center; width: 28px; height: 28px; border-radius: 50%; background: var(--surface-subtle); font-size: 13px; font-weight: 800; }
.rulebook strong { font-size: 16px; line-height: 1.3; }
.rulebook span { font-size: 14px; line-height: 1.45; color: var(--text-muted); }
/* what follows from your answers, on the wizard's last screen */
.tips { display: grid; gap: 8px; padding: 0; list-style: none; }
.tips li { padding: 10px 14px; background: var(--surface-subtle); border-radius: var(--radius-sm); font-size: 14px; line-height: 1.45; }
.tips strong { display: block; font-size: 15px; }
.game-fields { display: grid; gap: 12px; }
.game-fields .pills { gap: 6px; }
.game-fields .pill-choice span { min-height: 40px; padding: 0 12px; font-size: 14px; }
/* a phone: a smaller avatar, so the rows fit under it */
@container sheet (max-height: 600px) { .avatar--xl { width: 48px; height: 48px; font-size: 18px; } }
.pills { display: flex; flex-wrap: wrap; gap: 8px; }
.pill-choice { position: relative; display: inline-flex; }
.pill-choice input { position: absolute; inset: 0; margin: 0; opacity: 0; cursor: pointer; }
.pill-choice span { text-transform: none; letter-spacing: normal; white-space: nowrap; display: inline-flex; align-items: center; min-height: 44px; padding: 0 14px; border: 1.5px solid var(--border-hairline); border-radius: var(--radius-sm); font-size: 15px; font-weight: 600; transition: border-color var(--dur-state) var(--ease-standard), background-color var(--dur-state) var(--ease-standard); }
.pill-choice input:checked + span { border-color: var(--action-primary); background: var(--action-tint); color: var(--action-primary); }
.pill-choice input:focus-visible + span { outline: 2px solid var(--action-primary); outline-offset: 2px; }
.row-btn { display: flex; justify-content: space-between; align-items: center; width: 100%; min-height: 52px; padding: 0 2px; background: none; border: 0; border-bottom: 1px solid var(--border-hairline); font: inherit; font-size: 16px; font-weight: 600; color: var(--text-primary); text-align: left; cursor: pointer; }
.row-btn { gap: 12px; padding-top: 6px; padding-bottom: 6px; }
.row-btn__chev { flex: 0 0 auto; font-size: 20px; color: var(--text-muted); }
.row-btn--danger { color: var(--brand-red); }
.btn--destroy { background-color: var(--brand-red); border-color: var(--brand-red); color: #fff; }
.consequences { display: grid; gap: 6px; padding-left: 20px; font-size: 15px; line-height: 1.45; }
.consequences li { list-style: disc; }
@media (prefers-reduced-motion: reduce) { .wizard-progress span, .pill-choice span { transition: none; } }
/* A short sheet (a squashed desktop, a phone on its side, a small phone): shed the ledes and hints
   together, so the question and its answers stay on screen (DESIGN.md §4.3, §9 — details are shed
   together). Keyed to the sheet's own height, not the window's: the header is 108px on a desktop and
   70px on a phone, so the same window height leaves different room (1024×600 leaves 478px, 360×640
   leaves 502px — and a 360×640 phone fits everything with its ledes). */
.sheet { container: sheet / size; }
@container sheet (max-height: 500px) {
  .sheet__lede, [data-choices] .choice__meta, .choice-hint { display: none; }   /* not .auth__legal: what you agree to stays in view where an account starts */
  .sheet__title { font-size: 1.375rem; }
  .sheet .choice { padding: 8px 12px; }
  .field input, .field select { height: 44px; }
  .sheet__bar { height: 40px; }
  .sheet__back, .sheet__close, .sheet__exit { height: 40px; }
  .sheet__body { padding-top: 2px; padding-bottom: 8px; }
  .sheet__inner { gap: 10px; }
  .field { gap: 4px; }
  .check { min-height: 36px; }
  .sheet__foot { padding-top: 8px; padding-bottom: max(8px, env(safe-area-inset-bottom)); }
  /* the footer's button and its small link side by side, not stacked */
  .sheet__foot-inner:has(> .foot-link) { flex-direction: row; align-items: center; gap: 16px; }
  .sheet__foot-inner:has(> .foot-link) > .btn { flex: 1 1 auto; width: auto; }
  .sheet__foot-inner > .foot-link { flex: 0 1 auto; min-width: 0; line-height: 1.25; }   /* a narrow phone: the link takes two lines, never runs off the edge ("Keep my account" at 320 wide) */
  /* four or more answers: two columns, so they fit side by side instead of scrolling */
  [data-choices]:has(> :nth-child(4)) { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
  /* the email you're using and the switch link share one line */
  .auth__email, .auth__switch { font-size: 14px; }
  /* the profile: no big avatar, rows side by side, the game's four questions in two columns */
  .profile-head, .game-fields + .profile__note, .game-fields .profile__note, .avatar-edit__note { display: none; }
  .avatar-edit { gap: 6px; }
  .row-btn, .check--row { min-height: 44px; }
  .pill-choice span { min-height: 36px; padding: 0 12px; font-size: 14px; }
  .game-fields { gap: 6px; }
  .sheet .notice, .tips li { padding: 8px 12px; font-size: 13px; }
  .tips strong { font-size: 14px; }
  .sheet__foot .form-hint { display: none; }
  .rulebook { gap: 8px; }
  .rulebook strong { font-size: 15px; }
  .rulebook span { font-size: 13px; line-height: 1.35; }
  @container sheet (min-width: 480px) {
    .rows { grid-template-columns: 1fr 1fr; column-gap: 24px; }
    /* exactly three answers: one row of three */
    [data-choices]:has(> :nth-child(3)):not(:has(> :nth-child(4))) { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
    /* the rules and the done screen's notes side by side, two to a row */
    .rulebook, .tips { grid-template-columns: 1fr 1fr; column-gap: 20px; }
  }
  @container sheet (min-width: 560px) {
    /* each question on one line: the label on the left, its answers beside it */
    .game-fields .field { display: grid; grid-template-columns: 9rem 1fr; align-items: center; gap: 8px 12px; }
    .game-fields { gap: 4px; }
    .game-fields .pills { gap: 6px; }
  }
}
/* a very short sheet (a small phone on its side, a desktop window dragged flat): tighter still */
@container sheet (max-height: 340px) {
  .sheet__inner { gap: 6px; }
  .sheet__title { font-size: 1.125rem; }
  .sheet__bar { height: 36px; }
  .sheet__back, .sheet__close, .sheet__exit { height: 36px; }
  .field input, .field select { height: 40px; }
  .auth__or { font-size: 11px; }
  .account-choice { min-height: 44px; padding: 4px 12px; }
  .consequences { gap: 2px; font-size: 14px; }
  .sheet .btn { min-height: 40px; }
}
/* the smallest phones: the game's answers stay on two lines, not three */
@container sheet (max-width: 359px) {
  .game-fields .pills { gap: 4px; }
  .game-fields .pill-choice span { padding: 0 9px; font-size: 13px; }
}
/* the reviewers' demo pill sits exactly where a sheet's Continue button is on a phone: step aside while one is open */
body:has(.sheet.is-open) .demo-bar:not(.is-open) { opacity: 0; pointer-events: none; }
/* a toast must never cover the sheet's primary button */
body:has(.sheet.is-open) .toasts { bottom: calc(var(--tabbar-space) + 120px); }
/* the legal notice (js/legal-notice.js): a slim white strip along the window's foot — on a phone it sits on the tab bar as a second row
   of it (the same white, hairline and soft shadow) — the words on the left, the teal OK on the right, on the header's own gutters. 56px,
   the header's height; a phone wraps the words to two lines in the same 56px. The JS docks it (bottom) and puts its top on <html>
   (--legal-notice-top) for the toasts and the demo pill. Three tries before it (Rikki, 2026-09-28/29): the black bar "abit shit", the
   crest · words · OK row "messy and horrendous", the stacked card "a terrible bulky design with bad layout". Out of the way while a sheet
   is open (its Continue sits there). */
.legal-notice {
  position: fixed; left: 0; right: 0; bottom: var(--tabbar-space); z-index: 70;
  display: flex; align-items: center; justify-content: space-between; gap: 24px;
  min-height: 56px; padding: 10px calc(max(0px, (100% - var(--frame-max)) / 2) + var(--gutter));   /* the header's edges: its frame, its gutter */
  background: var(--bg-page); border-top: 1px solid var(--border-hairline);
  box-shadow: 0 -2px 8px rgba(0, 0, 0, 0.03);
  animation: legal-notice-in var(--dur-open, 260ms) var(--ease-entrance, ease-out) both;
}
.legal-notice--foot { padding-bottom: calc(10px + env(safe-area-inset-bottom, 0px)); }   /* no tab bar under it: clear the home indicator */
.legal-notice__text { margin: 0; min-width: 0; font-size: 14px; line-height: 1.4; color: var(--text-muted); text-wrap: pretty; }
.legal-notice__text a { color: var(--text-primary); font-weight: 600; text-decoration: underline; text-underline-offset: 2px; }
.legal-notice__ok { flex: 0 0 auto; min-height: 36px; height: 36px; padding: 0 20px; font-size: 14px; }
@media (max-width: 480px) {   /* a thumb's OK: 40px in the same 56px */
  .legal-notice { gap: 16px; padding-block: 8px; } .legal-notice--foot { padding-bottom: calc(8px + env(safe-area-inset-bottom, 0px)); }
  .legal-notice__text { font-size: 13px; } .legal-notice__ok { min-height: 40px; height: 40px; padding: 0 16px; }
}
@keyframes legal-notice-in { from { opacity: 0; transform: translateY(8px); } }
@media (prefers-reduced-motion: reduce) { .legal-notice { animation: none; } }
body:has(.sheet.is-open) .legal-notice { display: none; }
body:has(.legal-notice):not(:has(.sheet.is-open)) .toasts { bottom: calc(var(--legal-notice-top, 0px) + 16px); }
body:has(.legal-notice) .demo-bar { bottom: calc(var(--legal-notice-top, 0px) + 6px); }
@media print { .legal-notice { display: none; } }

/* ---------- Your picture (profile → Your details) — one picture on both apps (plan §4b)
   Stacked and centered, not a cluster beside the avatar (Rikki, 2026-09-23: "cluttered mess") —
   matches the sheet's own centered title/lede (line ~180). */
.avatar-edit { display: flex; flex-direction: column; align-items: center; gap: 10px; text-align: center; }
.avatar-edit__actions { display: flex; align-items: center; gap: 8px; }
.avatar-edit__note { margin: 0; max-width: 34ch; }

/* ---------- The header's account slot — Log in · Sign up, or your picture + points (both sites) ---------- */
.account { position: relative; display: flex; align-items: center; gap: 8px; }
.account__btn { display: inline-flex; align-items: center; gap: 8px; height: 44px; padding: 0 4px 0 0; background: none; border: 0; cursor: pointer; }
/* .avatar itself lives in shared/public/css/avatar.css — one look on both apps (plan §4b) */
/* square-cornered like every other box here (--radius-sm), not a rounded capsule (Rikki, 2026-09-24: "i do not like rounded pills").
   At least as wide as "Log in" (4.5em = 54px), so "Log in", "6 pts" and "16 pts" are one width and logging in or out moves nothing
   (Rikki, 2026-09-26: "make sure there is not too much CLS when it switches from visitor to logged in"); 100+ points grow it a little. */
.pill { min-width: 4.5em; text-align: center; font-size: 12px; font-weight: 800; font-variant-numeric: tabular-nums; padding: 5px 9px; border-radius: var(--radius-sm); background: var(--action-tint); color: var(--action-primary); white-space: nowrap; }
@media (max-width: 380px) { .pill { display: none; } }

/* Header account slot: one Account button for a visitor (shared/public/js/account/slot.js), your picture for a member.
   :where() keeps these at the weight of a plain class, so a site's own header layout (floripa's folded landscape bar,
   nf.css) still wins. 40/44px: a header CTA that reads as confident, and the 44px touch target (Rikki, 2026-09-22). */
:where(.app-header__utility) .btn--sm { height: 40px; padding: 0 18px; font-size: 14px; font-weight: 700; letter-spacing: 0.01em; }
@media (min-width: 768px) { :where(.app-header__utility) .btn--sm { height: 44px; padding: 0 22px; } }
/* The visitor's button (shared/public/js/account/slot.js, 2026-09-24): the member's pill + square, empty — "Log in" where the
   points go, an outlined square with a faint person where the picture goes. Logging in fills them; the header never changes
   shape: both buttons are 44px tall (the touch target) and the pill keeps one width. A member's pill hides on a narrow phone (the rule
   above); "Log in" stays — it's the only word saying what this is. While a returning member's session loads, a site may hold the
   visitor's button in the slot unseen (`is-held`, nomadvolleyball.com), so the header keeps its shape until their picture is drawn. */
[data-account-slot].is-held { visibility: hidden; }
.avatar--empty { background: transparent; color: var(--text-muted); box-shadow: inset 0 0 0 1.5px var(--border-hairline); transition: box-shadow var(--dur-state) var(--ease-standard), color var(--dur-state) var(--ease-standard); }
.account-cta .pill { display: inline-block; transition: background-color var(--dur-state) var(--ease-standard); }
.account-cta:hover .avatar--empty { color: var(--action-primary); box-shadow: inset 0 0 0 1.5px var(--action-primary); }
.account-cta:hover .pill { background: color-mix(in srgb, var(--action-primary) 16%, transparent); }
.account__btn:focus-visible { outline: 2px solid var(--action-primary); outline-offset: 2px; border-radius: var(--radius-sm); }

/* Phones: the longest title keeps its room ("Freelancers" at 320px) — nothing truncated (Rikki, 2026-09-23: "i do not
   like how the text is truncated we need a better design that fits"). */
@media (max-width: 479px) {
  .app-header__title { font-size: 19px; }
}
