/* RadioB2B account forms: free trial signup and subscription checkout.
   Loaded after css/legal.css, which supplies the tokens, the page chrome
   (.legal-head, .legal-wrap, .legal-foot), h1, .doc-kicker and .note.
   This file adds only what a form page needs on top of that. */

:root {
  /* Tokens index.html has but legal.css does not declare. */
  --brand-soft: #3b82f6;
  --ok:       #10b981;
  --ok-ink:   #047857;
  --ok-wash:  #ecfdf5;
  --ok-line:  #c9f0e0;
  --risk-ink: #b42318;
  --risk-wash:#fef2f2;
  --risk-line:#fbdcdc;
  --shadow-md: 0 4px 16px -4px rgba(31, 41, 55, .10), 0 1px 3px rgba(31, 41, 55, .05);
  --shadow-lg: 0 18px 48px -16px rgba(30, 64, 175, .20), 0 2px 8px rgba(31, 41, 55, .05);
}

/* The form column is narrower than a legal document: a 54rem measure makes
   two-column fields too wide to scan. */
.form-wrap { max-width: 44rem; }

.lede-sm { font-size: 1.0625rem; color: var(--ink-body); max-width: 60ch; margin: 0 0 2rem; }

/* ── Card ── */
.card {
  background: #fff; border: 1px solid var(--line); border-radius: var(--r-card);
  box-shadow: var(--shadow-md); padding: 1.75rem;
}
.card + .card { margin-top: 1.25rem; }
@media (max-width: 560px) { .card { padding: 1.25rem; } }

.card-title { font-size: 1.15rem; font-weight: 600; color: var(--ink); letter-spacing: -.015em; margin: 0 0 .5rem; }
.card-sub   { font-size: .9375rem; color: var(--ink-body); margin: 0 0 1.5rem; max-width: 60ch; }

/* ── Fields ── */
.field-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem 1.25rem; }
.field-grid .wide { grid-column: 1 / -1; }
@media (max-width: 620px) { .field-grid { grid-template-columns: 1fr; } }

.field label,
.field-label {
  display: block; font-size: .8125rem; font-weight: 500; color: var(--ink);
  margin-bottom: .4rem;
}
.control {
  width: 100%; font: inherit; font-size: .9375rem; line-height: 1.5; color: var(--ink);
  background: #fff; border: 1px solid var(--line); border-radius: var(--r-ctrl);
  padding: .625rem .75rem;
  transition: border-color .18s ease, box-shadow .18s ease;
}
.control:focus {
  border-color: var(--brand); box-shadow: 0 0 0 3px rgba(37, 99, 235, .12); outline: none;
}
.control::placeholder { color: var(--ink-faint); }
select.control {
  appearance: none; -webkit-appearance: none; padding-right: 2.25rem;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%235d6470' stroke-width='1.75' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right .7rem center;
}
.hint { font-size: .75rem; color: var(--ink-mute); margin: .35rem 0 0; }
.hint.is-error { color: var(--risk-ink); }

/* The 8 digit activation code. Wide tracking so a mistyped digit is obvious. */
.code-input {
  letter-spacing: .3em; font-family: 'Geist Mono', ui-monospace, monospace;
  font-size: 1.2rem; text-align: center; max-width: 16rem;
}

/* ── Consent row ── */
.consent {
  display: flex; gap: .625rem; align-items: flex-start;
  margin: 1.25rem 0 0; font-size: .875rem; color: var(--ink-body);
}
.consent input { margin: .3rem 0 0; flex: none; width: 1rem; height: 1rem; accent-color: var(--brand); }
.consent label { margin: 0; font-weight: 400; font-size: .875rem; }
.consent a { color: var(--brand); text-decoration: underline; text-underline-offset: 3px; }

/* ── Buttons ── */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5rem;
  font: inherit; font-size: .9375rem; font-weight: 500; letter-spacing: -.005em;
  padding: .8125rem 1.375rem; border-radius: var(--r-ctrl); min-height: 44px;
  border: 1px solid transparent; cursor: pointer; text-decoration: none;
  transition: background-color .18s ease, border-color .18s ease, color .18s ease,
              box-shadow .18s ease, transform .12s ease;
}
.btn-primary { background: var(--brand); color: #fff; box-shadow: var(--shadow-sm); }
.btn-primary:hover { background: var(--brand-strong); box-shadow: 0 6px 20px -6px rgba(37, 99, 235, .55); transform: translateY(-1px); }
.btn-primary:active { transform: scale(.985) translateY(0); }
.btn-ghost { background: #fff; color: var(--ink); border-color: var(--line); box-shadow: var(--shadow-sm); }
.btn-ghost:hover { border-color: var(--brand-line); color: var(--brand-deep); background: var(--brand-wash); }
.btn-ghost:active { transform: scale(.985); }
.btn[disabled], .btn[aria-busy="true"] { opacity: .6; cursor: progress; transform: none; box-shadow: none; }
.btn-block { width: 100%; }

.actions { display: flex; flex-wrap: wrap; gap: .75rem; margin-top: 1.5rem; }
.actions .btn { flex: 1 1 14rem; }

/* ── Messages ── */
.err {
  background: var(--risk-wash); border: 1px solid var(--risk-line); color: var(--risk-ink);
  border-radius: var(--r-ctrl); padding: .75rem 1rem; margin: 1.25rem 0 0; font-size: .875rem;
}
.err p { margin: 0; }
.err p + p { margin-top: .35rem; }
.ok-note {
  background: var(--ok-wash); border: 1px solid var(--ok-line); color: var(--ok-ink);
  border-radius: var(--r-ctrl); padding: .75rem 1rem; margin: 1.25rem 0 0; font-size: .875rem;
}
.fine { font-size: .78rem; color: var(--ink-mute); margin: 1rem 0 0; }
.fine a { color: var(--brand); text-decoration: underline; text-underline-offset: 3px; }
.help { font-size: .875rem; color: var(--ink-mute); margin: 2rem 0 0; }
.help a { color: var(--brand); text-decoration: underline; text-underline-offset: 3px; }

/* ── Step rail ── */
.steps {
  display: flex; flex-wrap: wrap; gap: .5rem 1.25rem; list-style: none;
  padding: 0; margin: 0 0 2rem;
  font-family: 'Geist Mono', ui-monospace, monospace; font-size: .72rem;
  letter-spacing: .06em; text-transform: uppercase; color: var(--ink-faint);
}
.steps li { display: flex; align-items: center; gap: .45rem; }
.steps b {
  width: 1.35rem; height: 1.35rem; border-radius: 999px; display: grid; place-items: center;
  background: var(--surface-2); color: var(--ink-mute); font-size: .7rem; font-weight: 500;
}
.steps li[aria-current="step"] { color: var(--brand-deep); }
.steps li[aria-current="step"] b { background: var(--brand); color: #fff; }
.steps li.done { color: var(--ok-ink); }
.steps li.done b { background: var(--ok-wash); color: var(--ok-ink); border: 1px solid var(--ok-line); }

/* ── Plan picker ── */
.plan-toggle { display: inline-flex; padding: 3px; background: var(--surface-2); border-radius: 999px; }
.plan-toggle button {
  font: inherit; font-size: .82rem; font-weight: 500; padding: .45rem 1rem; border-radius: 999px;
  border: none; background: transparent; color: var(--ink-mute); cursor: pointer; min-height: 32px;
  transition: background-color .18s ease, color .18s ease;
}
.plan-toggle button[aria-pressed="true"] { background: #fff; color: var(--ink); box-shadow: var(--shadow-sm); }

.plan-head {
  display: flex; flex-wrap: wrap; align-items: flex-start; justify-content: space-between;
  gap: 1rem; margin-bottom: 1.5rem;
}

.price-row {
  display: grid; grid-template-columns: 1fr 1fr; gap: 1.25rem; align-items: end;
  padding-bottom: 1.5rem; border-bottom: 1px solid var(--line); margin-bottom: 1.5rem;
}
@media (max-width: 620px) { .price-row { grid-template-columns: 1fr; } }
.price-out { display: flex; align-items: baseline; gap: .5rem; }
.price-out .amount {
  font-family: 'Geist Mono', ui-monospace, monospace; font-variant-numeric: tabular-nums;
  font-size: 2.6rem; font-weight: 600; color: var(--ink); line-height: 1; letter-spacing: -.02em;
}
.price-out .period { font-size: .9rem; color: var(--ink-mute); }
.price-note { font-size: .8125rem; color: var(--ok-ink); margin: .5rem 0 0; }

.incl-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 0 2rem; margin-bottom: 1.5rem; }
@media (max-width: 620px) { .incl-grid { grid-template-columns: 1fr; } }
.incl { display: flex; align-items: center; gap: .5rem; font-size: .84rem; color: var(--ink-body); padding: .3rem 0; }
.incl svg { flex: none; width: 15px; height: 15px; color: var(--ok); }

.summary {
  display: flex; align-items: baseline; justify-content: space-between; gap: 1rem;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-ctrl);
  padding: .875rem 1.125rem; margin-top: 1.5rem;
}
.summary .label { font-size: .84rem; color: var(--ink-mute); }
.summary .value {
  font-family: 'Geist Mono', ui-monospace, monospace; font-variant-numeric: tabular-nums;
  font-size: 1.25rem; font-weight: 600; color: var(--ink);
}

/* ── Done panel ── */
.done { text-align: center; }
.done .mark {
  width: 3rem; height: 3rem; border-radius: 999px; margin: 0 auto 1rem;
  display: grid; place-items: center; background: var(--ok-wash);
  border: 1px solid var(--ok-line); color: var(--ok-ink);
}
.done .mark svg { width: 24px; height: 24px; }
.done p { margin-left: auto; margin-right: auto; }

@media (prefers-reduced-motion: reduce) {
  .btn:hover, .btn:active { transform: none; }
}
