/* CFIL sign-up pages. Phone first. Brand colours match apps/links/static/links/tokens.css
   (blue #3276c9, navy #171d3a); only /static/signup/ and /static/brand/ load on this host. */
:root {
  --blue: #3276c9;
  --blue-press: #2a64ad;
  --navy: #171d3a;
  --paper: #f4f6fb;
  --white: #fcfdff;
  --line: #dde2ee;
  --ink: #171d3a;
  --ink-soft: #545c7a;
  --ok: #17703d;
  --ok-bg: #e4f4ea;
  --danger: #b42318;
  --danger-bg: #fdecea;
  --radius: 14px;
  --tap: 3rem;
  --focus: 0 0 0 3px var(--white), 0 0 0 6px var(--blue);
  color-scheme: light;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font: 1rem/1.5 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  overflow-wrap: anywhere;
}

/* Full-width dark bar (Coach Portal dark --bg); side padding lines the logo up with main's text column (32rem). */
.brand { background: #0c0d11; padding: 1rem max(1rem, calc((100% - 32rem) / 2)); }
.brand a { display: inline-block; vertical-align: top; border-radius: 4px; }
.brand img { display: block; width: 116px; height: auto; }
@media (min-width: 48rem) {
  .brand { padding-block: 1.25rem; }
  .brand img { width: 150px; }
}

main { max-width: 34rem; margin: 0 auto; padding: 1.25rem 1rem 3rem; }

h1 { font-size: 1.6rem; line-height: 1.2; margin: 0.25rem 0 0.5rem; }
h2 { font-size: 1.2rem; margin: 1.75rem 0 0.5rem; }
a { color: var(--blue-press); }
a:focus-visible, button:focus-visible, input:focus-visible, textarea:focus-visible { outline: none; box-shadow: var(--focus); }

.meta { color: var(--ink-soft); font-size: 0.9rem; margin: 0.25rem 0; }
.description { margin: 1rem 0; }

.notice { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); padding: 0.75rem 1rem; }
.notice.ok { background: var(--ok-bg); border-color: var(--ok-bg); color: var(--ok); font-weight: 600; }
.error { color: var(--danger); font-weight: 600; margin: 0.25rem 0; }
p.error[role="alert"]:first-child { margin-top: 0; }

.cards { list-style: none; padding: 0; margin: 1rem 0; display: grid; gap: 0.75rem; }
.card { display: block; background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); padding: 1rem; color: var(--ink); text-decoration: none; }
.card .meta { display: block; }

fieldset { border: 0; margin: 1rem 0; padding: 0; min-width: 0; }
legend { font-weight: 700; font-size: 1.1rem; margin-bottom: 0.5rem; padding: 0; }

.option { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); padding: 0.75rem 1rem; margin-bottom: 0.75rem; }
.option.is-full { opacity: 0.7; }
.pick { display: flex; align-items: center; gap: 0.75rem; min-height: var(--tap); cursor: pointer; }
.pick input { width: 1.4rem; height: 1.4rem; margin: 0; flex: none; accent-color: var(--blue); }
.pick-text { flex: 1; display: flex; flex-direction: column; }
.label { font-weight: 600; }
.status { flex: none; font-size: 0.85rem; font-weight: 700; color: var(--blue-press); background: var(--paper); border-radius: 999px; padding: 0.15rem 0.6rem; }
.is-full .status { color: var(--ink-soft); }

.extra { display: grid; gap: 0.35rem; margin-top: 0.5rem; padding-left: 2.15rem; }
.js .extra[hidden] { display: none; }
.names { list-style: none; padding: 0; margin: 0.5rem 0 0; font-size: 0.9rem; color: var(--ink-soft); }
.names li + li { margin-top: 0.15rem; }

.field { margin: 1rem 0; }
.field > label, .extra > label { display: block; font-weight: 600; margin-bottom: 0.25rem; }
input[type="text"], input[type="email"], input[type="tel"], input[type="number"], input[type="password"], textarea {
  width: 100%; min-height: var(--tap); padding: 0.6rem 0.75rem; font: inherit; color: inherit;
  background: var(--white); border: 1px solid var(--line); border-radius: 10px;
}
.check { display: flex; gap: 0.5rem; align-items: flex-start; margin: 0.35rem 0; }
.check input { width: 1.2rem; height: 1.2rem; margin-top: 0.2rem; accent-color: var(--blue); }

.stepper { display: flex; gap: 0.5rem; align-items: center; max-width: 12rem; }
.stepper input { text-align: center; }
.stepper button { flex: none; width: var(--tap); height: var(--tap); border-radius: 10px; border: 1px solid var(--line); background: var(--paper); font-size: 1.4rem; color: var(--ink); cursor: pointer; }

.button { display: inline-flex; align-items: center; justify-content: center; min-height: var(--tap); padding: 0.6rem 1.25rem; border: 0; border-radius: 999px; background: var(--blue); color: var(--white); font: inherit; font-weight: 700; text-decoration: none; cursor: pointer; }
.button:hover { background: var(--blue-press); }
form.signup > .button { width: 100%; margin-top: 0.5rem; }
.button.secondary { background: var(--white); color: var(--blue-press); border: 1px solid var(--line); }
.button.danger { background: var(--white); color: var(--danger); border: 1px solid var(--danger); }
form.cancel { margin-top: 2rem; }
.actions { display: flex; flex-wrap: wrap; gap: 0.5rem; }

.thanks { background: var(--white); border: 2px solid var(--ok); border-radius: var(--radius); padding: 1rem; margin: 1rem 0; }
.thanks h2 { margin-top: 0; color: var(--ok); }
.link { word-break: break-all; font-size: 0.9rem; }
.summary { padding-left: 1.25rem; }
.answers dt { font-weight: 600; margin-top: 0.5rem; }
.answers dd { margin: 0; }

/* honeypot: off screen for people, still in the DOM for bots */
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

.grid-wrap { overflow-x: auto; margin: 1rem 0; background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); }
.grid { border-collapse: collapse; width: 100%; font-size: 0.9rem; }
.grid th, .grid td { padding: 0.5rem; border-bottom: 1px solid var(--line); text-align: center; }
.grid th[scope="row"] { text-align: left; white-space: nowrap; }
.grid th .meta { display: block; font-weight: 400; font-size: 0.8rem; }
.grid .is-best { background: var(--ok-bg); color: var(--ok); font-weight: 700; }
