/*
 * Onboarding (/start, steps 1–3) and placement (/placement, steps 4–5).
 * Lives inside the auth split layout (.split__main).
 */

.onb { display: flex; flex-direction: column; gap: 28px; }
.onb__step { display: flex; flex-direction: column; gap: 28px; }
.onb__step h1:focus { outline: none; }
.onb__fieldset { border: 0; margin: 0; padding: 0; min-width: 0; }

/* Step 1: focus cards (radio inputs inside labels). */
.onb__focus-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 220px), 1fr));
  gap: 12px;
}
.onb__focus {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  color: var(--ink);
  cursor: pointer;
  transition: border-color .15s ease, background-color .15s ease;
}
.onb__focus:hover { border-color: var(--ink); }
.onb__focus:has(:checked) { background: var(--clay-soft); border-color: var(--clay); }
.onb__focus-ar { font-size: 34px; line-height: 1.3; align-self: flex-start; }
.onb__focus-name { font-size: 15px; font-weight: 600; }
.onb__focus-note { font-size: 13px; color: var(--text-muted); }

/* Step 2: daily goal cards + reasons. */
.onb__goal-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 140px), 1fr));
  gap: 12px;
}
.onb__goal {
  border: 1px solid var(--ink);
  border-radius: var(--radius-md);
  padding: 18px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  font-size: 14px;
  color: var(--ink);
  cursor: pointer;
  transition: background-color .15s ease, color .15s ease;
}
.onb__goal:hover { background: var(--sand-hover); }
.onb__goal:has(:checked) { background: var(--ink); color: var(--paper); }
.onb__goal-min { font-family: var(--font-serif); font-size: 34px; line-height: 1.2; }

.onb__legend { font-size: 15px; font-weight: 600; padding: 0; margin-bottom: 14px; }
.onb__legend .muted { font-weight: 400; }
.onb__reason { padding: 10px 16px; cursor: pointer; }
.onb__reason:has(:checked) { background: var(--ink); color: var(--paper); border-color: var(--ink); }

/* Keyboard focus lands on the hidden radio/checkbox; show it on its card. */
.onb__focus:has(:focus-visible),
.onb__goal:has(:focus-visible),
.onb__reason:has(:focus-visible) { outline: 2px solid var(--green); outline-offset: 2px; }

/* Step 3: account. */
.onb__signin { font-size: 14px; }

/* Footer (Back / Continue). */
.onb__back { color: var(--ink); font-size: 15px; padding: 12px 0; }
.onb__back:hover { color: var(--clay); text-decoration: none; }
.onb__next { padding: 13px 26px; }

/* Without JavaScript the stepper can't run: show every step, one long form. */
@media (scripting: none) {
  .onb__step[hidden] { display: flex !important; }
  .onb__step + .onb__step { padding-top: 28px; border-top: 1px solid var(--line); }
}

/* Placement test (step 4) and result (step 5). */
.placement { display: flex; flex-direction: column; gap: 28px; }
.placement__lead { font-size: 18px; line-height: 1.5; color: var(--text-body); }
.placement__meta { font-size: 14px; color: var(--text-muted); }
.placement__prompt { font-size: clamp(34px, 6vw, 48px); line-height: 1.5; text-align: center; padding: 28px 0; }
.placement__options {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 240px), 1fr));
  gap: 10px;
}
.placement__option {
  background: var(--card);
  border: 1px solid var(--line-strong);
  border-radius: 12px;
  padding: 16px 18px;
  color: var(--ink);
  font-size: 16px;
  text-align: center;
  transition: border-color .15s ease, background-color .15s ease;
}
.placement__option:hover { border-color: var(--ink); background: var(--sand-hover); }
.placement__option--ar { font-family: var(--font-arabic); font-size: 26px; line-height: 1.4; padding-top: 10px; padding-bottom: 10px; }
.placement__question { display: flex; flex-direction: column; gap: 16px; }
.placement__question .progress { flex: none; }

.placement__level { font-size: clamp(44px, 7vw, 64px); }
.placement__first { display: flex; flex-direction: column; gap: 6px; padding: 20px; border-radius: var(--radius-md); }
.placement__first-label { font-size: 13px; color: var(--text-muted); }
.placement__first-title { font-size: 26px; }
.placement__first-meta { font-size: 14px; color: var(--text-muted); }

/* Phones: the step list becomes a compact row of dots above the form. */
@media (max-width: 860px) {
  .onb-steps { flex-direction: row; flex-wrap: wrap; gap: 8px; }
  .onb-steps .steps__item { gap: 10px; }
  .onb-steps .steps__item:not(.is-current) .onb-steps__label { display: none; }
}
