/* Intake layout. Colors, type, controls and components come from the shared
   design language (../../../packages/design, Design Profile 4.2, white
   theme), served at /design. This file places things, with one exception
   marked below. */

body { min-height: 100vh; display: flex; flex-direction: column; }

.crumbs { flex: 1; min-width: 0; display: flex; align-items: center; gap: 6px; overflow: hidden; }
.crumbs .crumb { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.topbar-end { margin-left: auto; flex: none; }

.page { flex: 1; width: 100%; max-width: 720px; margin: 0 auto; padding: 48px 32px 72px; }
.narrow { max-width: 560px; }

.title { font-size: 24px; line-height: 30px; letter-spacing: -0.02em; overflow-wrap: anywhere; }
.lede { margin-top: 12px; color: var(--ink-2); max-width: 560px; }
.saved { margin-top: 12px; color: var(--green); font-weight: var(--weight-medium); }
.work-email { margin-top: 12px; display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; color: var(--ink-2); overflow-wrap: anywhere; }
.caption { margin-top: 24px; color: var(--ink-muted); font-size: var(--text-mini); }
.next { margin-top: 24px; }
.section-title { font-size: var(--title-2); line-height: 24px; margin: 0 0 8px; }
a { color: var(--link); }
.logo, .btn { color: inherit; }
.btn-primary { color: var(--on-accent); }
/* The page's one drawing of the tick, used by every chip. */
.sprite { position: absolute; }
.vh { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }

/* Forms: one question per fieldset */
.form-wrap { max-width: 640px; }
.intake { margin-top: 28px; }
.intake .progress { margin-bottom: 28px; }
.form-error { margin-bottom: 16px; }
.step + .step, .step > .q + .q, .carried + .step { margin-top: 36px; }
.q { margin: 0; padding: 0; border: 0; min-width: 0; }
.q-title { padding: 0; font-size: 20px; line-height: 26px; font-weight: var(--weight-bold); letter-spacing: -0.02em; margin-bottom: 6px; }
[data-mode="stepper"] .q-title { font-size: 24px; line-height: 30px; }
.q-help { color: var(--ink-muted); font-size: var(--text-mini); line-height: 18px; margin-bottom: 16px; max-width: 560px; }
.q .error { margin-top: 10px; }
.q-checkbox .error { margin-top: 6px; }
.group-label {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  margin: 18px 0 8px; color: var(--ink-muted); font-size: var(--text-micro); font-weight: var(--weight-medium);
}
.band-row:first-child .group-label { margin-top: 0; }
.one-tap { margin-bottom: 4px; }
.options { max-width: 460px; }
.consent span { line-height: 20px; }
.consent { align-items: flex-start; font-size: var(--text-small); }
.consent input { margin-top: 2px; flex: none; }
.q-links { margin: 6px 0 0 26px; font-size: var(--text-mini); }
.none-row { margin-top: 10px; }
.input { max-width: 460px; }
/* The text field for what a list does not hold, under its options */
.other-field { margin-top: 20px; }
.other-label { display: block; margin-bottom: 4px; color: var(--ink-2); font-size: var(--text-small); font-weight: var(--weight-medium); }
.other-help { margin-bottom: 8px; color: var(--ink-muted); font-size: var(--text-mini); line-height: 18px; max-width: 560px; }
.other-choice { margin-top: 18px; }

/* A native checkbox or radio inside a chip. The exception: the design
   language draws a chip's ticked state from aria-pressed on a button; these
   chips hold a real input, so the same look is keyed to :checked here. Move
   it into packages/design's components.css when a second app needs it. */
.chip { position: relative; }
.chip input { position: absolute; opacity: 0; width: 1px; height: 1px; margin: 0; pointer-events: none; }
.chip:has(> input:checked) { background: var(--tint); border-color: var(--accent); color: var(--ink); }
.chip:has(> input:checked) .box { background: var(--accent); border-color: var(--accent); }
/* A group with some of its places ticked shows a dash. Checkboxes only: a
   radio group with nothing picked also matches :indeterminate. */
.chip:has(> input[type="checkbox"]:indeterminate) .box { background: var(--accent); border-color: var(--accent); }
.chip:has(> input[type="checkbox"]:indeterminate) .box svg { display: none; }
.chip:has(> input[type="checkbox"]:indeterminate) .box::after { content: ""; width: 8px; height: 2px; border-radius: 1px; background: var(--on-accent); }
.chip.option:has(> input:checked) { background: transparent; border-color: transparent; }
.chip.option:has(> input:checked):hover { background: var(--hover); }
.chip:has(> input:focus-visible) { box-shadow: var(--ring); }

/* Country and state: two selects */
.place { display: flex; flex-wrap: wrap; gap: 10px; }
.select-wrap { flex: 1 1 200px; max-width: 280px; }
.select {
  width: 100%; height: var(--control); padding: 0 10px;
  border: 1px solid var(--line-strong); border-radius: var(--radius); background: var(--panel); color: var(--ink);
}
.select:hover { border-color: var(--ink-2); }

/* Geography picker: two one-tap boxes, then the world and the US */
.geo-summary { margin: 10px 0 0; color: var(--ink-2); font-size: var(--text-mini); font-weight: var(--weight-medium); }
.geo .group-label { font-size: var(--text-micro); margin-top: 22px; }
.geo-groups > .geo-row { position: relative; padding: 4px; }
.geo-row > .chip.option { padding-right: 120px; }
.geo-row details > summary {
  position: absolute; right: 8px; top: 10px;
  cursor: pointer; color: var(--ink-muted); font-size: var(--text-mini); padding: 2px 6px; border-radius: var(--radius-xs);
}
.geo-row details > summary:hover { background: var(--hover); color: var(--ink); }
.geo-row details[open] > summary { color: var(--ink); }
.geo-row details > .chips, .geo-division { padding: 8px 10px 10px; }
.geo-division > .chips { margin-top: 4px; padding-left: 26px; }
.geo-division .chip.option { height: 32px; }

/* Folded answers carried over from the first form */
.carried { border: 1px solid var(--line); border-radius: var(--radius-md); padding: 0 16px; }
.carried > summary { cursor: pointer; padding: 12px 0; font-weight: var(--weight-medium); color: var(--ink-2); }
.carried[open] { padding-bottom: 20px; }
.carried > .q + .q, .carried > summary + .q { margin-top: 20px; }

.actions { display: flex; align-items: center; gap: 8px; margin-top: 36px; }
.actions [data-next] { margin-left: auto; }
.actions [data-back] { padding-left: 8px; margin-left: -8px; }

/* Sign in */
.sign-in { margin-top: 24px; display: grid; gap: 16px; max-width: 420px; justify-items: start; }
.sign-in .field { width: 100%; }
.sign-in .error { margin-top: 8px; }

/* The way to Full registration, under the investor's answers */
.card { margin-top: 40px; padding: 20px; border: 1px solid var(--line); border-radius: var(--radius-md); background: var(--panel); }
.card p { color: var(--ink-2); }

/* Staff: the header's two links, the account list, label and value rows */
.topbar-links { display: flex; align-items: center; gap: 4px; }
.staff { max-width: 720px; }
.staff-filter { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 20px; }
.staff-list, .staff-history { margin-top: 16px; }
.staff-list > li { padding: 0; }
.staff-row { display: grid; gap: 2px; padding: 10px 14px; color: inherit; text-decoration: none; }
.staff-row:hover { background: var(--hover); }
.staff-row-head { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 4px 12px; }
.staff-row-title { font-weight: var(--weight-medium); }
.staff-row-email { overflow-wrap: anywhere; }
.staff-row-meta { color: var(--ink-muted); font-size: var(--text-mini); }
.staff-history > li { display: grid; gap: 2px; }
.staff-form { margin-top: 36px; }
.staff-form-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.staff-form .caption { margin-top: 0; }
.staff-props { margin: 16px 0 0; }
.staff-prop { display: grid; grid-template-columns: 180px minmax(0, 1fr); gap: 4px 16px; padding: 6px 0; border-bottom: 1px solid var(--line); }
.staff-prop dt { color: var(--ink-muted); font-size: var(--text-mini); }
.staff-prop dd { margin: 0; overflow-wrap: anywhere; }
.staff-actions { display: flex; flex-wrap: wrap; gap: 8px; }
.staff-danger { color: var(--red); }
.staff-danger-fill { background: var(--red); border-color: var(--red); }

@media (max-width: 600px) {
  .staff-prop { grid-template-columns: 1fr; }
  .page { padding: 28px 16px 48px; }
  [data-mode="stepper"] .q-title { font-size: 20px; line-height: 26px; }
  .topbar .crumb:not(.current), .topbar .crumb-sep:not(:last-of-type) { display: none; }
  .geo-row > .chip.option { padding-right: 100px; }
  .geo-division > .chips { padding-left: 0; }
}
