/* ==========================================================================
   NSBM Alumni -- Design 6: "Join first, then the graduate survey"
   One calm centred column, one short screen at a time. A two-part
   tracker (Join -> Graduate survey -> Membership active) plus a
   per-step bar and "minutes left" so people always know how close
   they are. NSBM navy + green, Source Serif headings, Inter body.
   ========================================================================== */

:root {
  --navy: #0f2a43;
  --navy-2: #1c3d5c;
  --green: #1f7a4d;
  --green-2: #176139;
  --green-bg: #e8f4ed;

  --bg: #f4f6f9;
  --panel: #ffffff;
  --panel-2: #f7f9fb;

  --text: #18212c;
  --muted: #566273;
  --faint: #5f6b7d;

  --border: #dbe2ea;
  --border-strong: #bfc9d6;

  --danger: #b3261e;
  --danger-bg: #fcecea;

  /* Secondary accent: "in progress" status (e.g. a qualification being
     pursued) and the account page's decorative background shapes. */
  --amber: #c9790a;
  --amber-2: #9c5f08;
  --amber-bg: #fdf1dd;

  --r-sm: 6px;
  --r-md: 10px;
  --r-lg: 16px;

  --sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --serif: 'Source Serif 4', Georgia, 'Times New Roman', serif;

  --ring: 0 0 0 2px var(--panel), 0 0 0 4px var(--green);
  --shadow: 0 1px 2px rgba(15, 23, 42, 0.04), 0 8px 28px rgba(15, 23, 42, 0.06);
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--sans);
  font-size: 15px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
}
h1, h2, h3, p, ol, ul, fieldset, legend { margin: 0; padding: 0; }
ol, ul { list-style: none; }
fieldset { border: 0; min-width: 0; }
a { color: var(--green); }
img { display: block; max-width: 100%; }
button { font: inherit; }
svg { width: 18px; height: 18px; flex: none; }
:focus-visible { outline: none; box-shadow: var(--ring); }
.is-hidden { display: none !important; }
::selection { background: var(--green-bg); color: var(--navy); }
input, textarea { caret-color: var(--green); }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}

/* ---- Top bar ------------------------------------------------------------ */

.topbar { background: var(--panel); border-bottom: 1px solid var(--border); }
.topbar__inner {
  /* Full page width: brand at the far left, sign out at the far right. */
  padding: 12px 32px;
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
}
.brand { display: flex; align-items: center; gap: 16px; min-height: 44px; text-decoration: none; color: inherit; min-width: 0; }
.brand__logo { height: 64px; width: auto; max-width: 160px; object-fit: contain; flex-shrink: 0; }
.brand__name { display: block; font-weight: 700; font-size: 0.95rem; color: var(--navy); }
.brand__sub { display: block; font-size: 0.78rem; color: var(--muted); }
@media (max-width: 480px) {
  .topbar__inner { padding: 10px 16px; }
  .brand { gap: 10px; }
  .brand__logo { height: 40px; }
  .brand__name { font-size: 0.88rem; line-height: 1.25; }
  .brand__sub { display: none; }
}
.topbar__secure { display: inline-flex; align-items: center; gap: 6px; font-size: 0.8rem; color: var(--muted); white-space: nowrap; }
.topbar__secure svg { width: 15px; height: 15px; color: var(--green); }
@media (max-width: 480px) { .topbar__secure { display: none; } }

/* ---- Journey: parts tracker + step meter -------------------------------- */

.journey { max-width: 760px; margin: 0 auto; padding: 24px 16px 0; }

.parts { display: flex; align-items: center; gap: 10px; }
.parts__item { display: flex; align-items: center; gap: 10px; min-width: 0; }
.parts__line { flex: 1; height: 2px; background: var(--border); border-radius: 2px; min-width: 16px; }
.parts__dot {
  width: 30px; height: 30px; border-radius: 50%; flex: none;
  display: flex; align-items: center; justify-content: center;
  background: var(--panel); border: 2px solid var(--border-strong);
  color: var(--muted); font-weight: 700; font-size: 0.85rem;
}
.parts__tick { display: none; width: 16px; height: 16px; stroke-width: 2.4; }
.parts__text strong { display: block; font-size: 0.88rem; color: var(--muted); white-space: nowrap; }
.parts__text small { display: block; font-size: 0.78rem; color: var(--faint); white-space: nowrap; }

.parts__item.is-current .parts__dot { border-color: var(--navy); background: var(--navy); color: #fff; }
.parts__item.is-current .parts__text strong { color: var(--navy); }
.parts__item.is-done .parts__dot { border-color: var(--green); background: var(--green); color: #fff; }
.parts__item.is-done .parts__num { display: none; }
.parts__item.is-done .parts__tick { display: block; }
.parts__item.is-done .parts__text strong { color: var(--green); }
.parts__line.is-done { background: var(--green); }

@media (max-width: 600px) {
  .parts__text small { display: none; }
  .parts__item:not(.is-current) .parts__text { display: none; }
  /* All done: name the finish, so it isn't three unlabelled ticks. */
  .parts__item[data-part-node="3"].is-done .parts__text { display: block; }
}

.stepinfo { margin-top: 18px; }
.stepinfo__row { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-bottom: 8px; font-size: 0.82rem; }
.stepinfo__label { font-weight: 600; color: var(--navy); }
.meter { height: 6px; border-radius: 99px; background: #e3e8ee; overflow: hidden; }
.meter__fill { display: block; height: 100%; width: 0; background: var(--green); border-radius: 99px; transition: width 0.35s ease; }

/* ---- Card shell --------------------------------------------------------- */

.shell { max-width: 760px; margin: 0 auto; padding: 16px 16px 48px; }
.shell--narrow { max-width: 560px; padding-top: 32px; }
.nav--end { justify-content: flex-end; }
.topbar__signout { display: flex; align-items: center; gap: 12px; margin: 0; font-size: 0.85rem; }
.topbar__signout .link { display: inline-flex; align-items: center; gap: 6px; min-height: 44px; padding: 0 4px; white-space: nowrap; }
.topbar__signout svg { width: 16px; height: 16px; }
.topbar__who { color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 220px; }
@media (max-width: 560px) { .topbar__who { display: none; } }
.card {
  background: var(--panel); border: 1px solid var(--border);
  border-radius: var(--r-lg); box-shadow: var(--shadow);
  padding: 36px 40px 28px;
}
@media (max-width: 600px) { .card { padding: 24px 18px 20px; border-radius: var(--r-md); } }

.footnote { display: flex; align-items: center; justify-content: center; gap: 6px; margin-top: 18px; font-size: 0.78rem; color: var(--faint); text-align: center; }
.footnote svg { width: 14px; height: 14px; }

/* ---- Steps -------------------------------------------------------------- */

.step { display: none; }
.step.is-active { display: block; animation: stepIn 0.25s ease; }
@keyframes stepIn { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }

.step__head { margin-bottom: 28px; }
.step h1, .card > .step__head h1, .welcome h1 { text-wrap: balance; font-family: var(--serif); font-size: 1.85rem; line-height: 1.2; font-weight: 700; color: var(--navy); }
.step__lead { text-wrap: pretty; margin-top: 8px; color: var(--muted); font-size: 0.97rem; max-width: 58ch; }
@media (max-width: 600px) { .step h1, .card > .step__head h1, .welcome h1 { font-size: 1.5rem; } }
.step h1:focus { box-shadow: none; outline: none; }
/* A second set of questions on the same page, under its own heading. */
.step__section { margin: 40px 0 24px; padding-top: 28px; border-top: 1px solid var(--border); }
.step__section h2 { text-wrap: balance; font-family: var(--serif); font-size: 1.35rem; line-height: 1.25; font-weight: 700; color: var(--navy); }

.subhead { font-weight: 700; color: var(--navy); font-size: 0.95rem; margin: 8px 0 14px; padding-top: 18px; border-top: 1px solid var(--border); }

/* ---- Alerts & status ---------------------------------------------------- */

.alert { display: none; padding: 12px 14px; border-radius: var(--r-sm); font-size: 0.9rem; margin-bottom: 20px; border: 1px solid transparent; }
.alert.is-visible { display: block; }
.alert--error { background: var(--danger-bg); color: var(--danger); border-color: rgba(179, 38, 30, 0.2); }

.status { font-size: 0.85rem; margin-top: 8px; min-height: 0; }
.status:empty { display: none; }
.status.is-success { color: var(--green); font-weight: 600; }
.status.is-error { color: var(--danger); }
.status.is-pending { color: var(--muted); }
.status.is-info { color: var(--navy); background: #eef3f9; padding: 8px 10px; border-radius: var(--r-sm); }

/* ---- Fields ------------------------------------------------------------- */

.field { margin-bottom: 20px; }
.field > label, .group > legend { display: block; font-weight: 600; font-size: 0.9rem; margin-bottom: 6px; color: var(--text); }
.req { color: var(--danger); margin-left: 2px; }
.opt { font-weight: 400; color: var(--muted); font-size: 0.8rem; margin-left: 4px; }
.q__hint { display: block; margin-top: 2px; font-weight: 400; font-size: 0.85rem; color: var(--muted); }

.input {
  display: block; width: 100%; height: 46px; padding: 0 14px;
  font: inherit; font-size: 1rem; color: var(--text); /* 16px: iPhones zoom in on smaller text boxes */
  background: var(--panel); border: 1.5px solid var(--border-strong); border-radius: var(--r-sm);
  transition: border-color 0.15s, box-shadow 0.15s;
}
.input::placeholder { color: var(--faint); }
.input:hover { border-color: #9aa7b8; }
.input:focus { outline: none; border-color: var(--green); box-shadow: var(--ring); }
.input:disabled { background: var(--panel-2); border-color: var(--border); color: var(--muted); cursor: default; }
.input[aria-invalid="true"] { border-color: var(--danger); }
.input[aria-invalid="true"]:focus { box-shadow: 0 0 0 2px var(--panel), 0 0 0 4px var(--danger); }
.input--half { max-width: 340px; }
.input--otp { width: 150px; flex: none; text-align: center; letter-spacing: 6px; font-weight: 700; font-size: 1.1rem; }
.inline .input--otp { flex: none; width: 150px; }
.input--textarea { height: auto; min-height: 90px; padding: 10px 14px; resize: vertical; }

.hint { text-wrap: pretty; font-size: 0.8rem; color: var(--muted); margin-top: 6px; }
.hint--above { margin: -2px 0 8px; }

.field-error { display: none; color: var(--danger); font-size: 0.82rem; margin-top: 6px; }
.field.has-error .field-error { display: block; }
.ratings__row.has-error .pip span { border-color: rgba(179, 38, 30, 0.55); }
.ratings__row.has-error .field-error { display: block; }
.q.has-error > .field-error { display: block; margin-top: 8px; }
.q.has-error > .choices .choice__mark { border-color: var(--danger); }

.inline { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.inline .input { flex: 1 1 220px; width: auto; }

.input-wrap { position: relative; }
.input-wrap .input { padding-right: 70px; }
.input-wrap__btn {
  position: absolute; right: 6px; top: 50%; transform: translateY(-50%);
  border: 0; background: transparent; color: var(--navy); font-weight: 600; font-size: 0.82rem;
  padding: 6px 10px; border-radius: var(--r-sm); cursor: pointer;
}
.input-wrap__btn:hover { background: var(--panel-2); }

.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 0 16px; }
@media (max-width: 600px) { .grid-2 { grid-template-columns: 1fr; } }

.group { margin: 8px 0 0; padding: 0; }
.group > legend { margin-bottom: 12px; font-size: 0.98rem; }

/* ---- Password strength -------------------------------------------------- */

.strength__bars { display: flex; gap: 4px; margin-top: 8px; }
.strength__bars span { flex: 1; height: 4px; border-radius: 4px; background: #e3e8ee; transition: background 0.2s; }
.strength[data-level="1"] .strength__bars span:nth-child(-n+1) { background: var(--danger); }
.strength[data-level="2"] .strength__bars span:nth-child(-n+2) { background: #c77c0a; }
.strength[data-level="3"] .strength__bars span:nth-child(-n+3) { background: #4f9a5d; }
.strength[data-level="4"] .strength__bars span { background: var(--green); }

/* ---- Locked UMIS record ------------------------------------------------- */

/* The UMIS match, shown as who they are: read as text, not as locked inputs. */
.record { background: var(--green-bg); border-radius: var(--r-md); padding: 20px 22px 8px; margin-bottom: 32px; }
.record__label { display: block; font-size: 0.85rem; font-weight: 600; color: var(--green-2); }
.record__name { margin: 2px 0 14px; }
.record__name .record__value { font-family: var(--serif); font-size: 1.45rem; font-weight: 700; line-height: 1.25; color: var(--navy); }
.record__grid { display: grid; grid-template-columns: 1fr 1fr; gap: 0 20px; }
@media (max-width: 600px) { .record__grid { grid-template-columns: 1fr; } .record { padding: 18px 16px 6px; } }
.field--locked { margin-bottom: 12px; }
.field--locked > .label { display: block; font-size: 0.78rem; font-weight: 500; color: var(--muted); margin-bottom: 1px; }
.record__value { margin: 0; font-size: 0.95rem; font-weight: 600; color: var(--text); overflow-wrap: anywhere; }
.record__more { margin: 0 0 4px; }
.record__more summary { display: inline-flex; align-items: center; min-height: 44px; cursor: pointer; font-size: 0.88rem; font-weight: 600; color: var(--green-2); text-decoration: underline; text-underline-offset: 2px; }
.record__more summary:focus-visible { box-shadow: var(--ring); border-radius: var(--r-sm); }
.record__more[open] summary { margin-bottom: 10px; }
.record__src { font-size: 0.82rem; color: var(--muted); margin: -2px 0 8px; }
.field--email { margin-bottom: 24px; }
.field--email .record__value { font-weight: 600; }
.record__note { display: flex; gap: 8px; align-items: flex-start; font-size: 0.82rem; color: var(--muted); padding: 10px 0 12px; border-top: 1px solid rgba(31, 122, 77, 0.18); margin-top: 4px; }
.record__note svg { width: 15px; height: 15px; margin-top: 2px; color: var(--green); }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }

.otp { margin-top: 16px; padding: 16px; border-radius: var(--r-md); background: var(--green-bg); }
.otp > label { display: block; font-weight: 600; font-size: 0.88rem; margin-bottom: 8px; }

/* ---- Questions & choice tiles ------------------------------------------- */

.q { margin-bottom: 30px; }
.q:last-child { margin-bottom: 8px; }
.reveal > .q:last-child { margin-bottom: 30px; }
.q--tight { margin-bottom: 4px; }
.q__label { display: block; font-weight: 600; font-size: 0.98rem; color: var(--text); margin-bottom: 12px; line-height: 1.4; }

.choices { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.choices--row { display: flex; flex-wrap: wrap; }
.choices--row .choice { flex: 0 1 auto; min-width: 120px; }
.choices--compact { grid-template-columns: repeat(4, 1fr); }
.choices--scale { grid-template-columns: repeat(3, 1fr); }
@media (max-width: 600px) {
  .choices, .choices--scale { grid-template-columns: 1fr; }
  .choices--compact { grid-template-columns: 1fr 1fr; }
  .choices--row .choice { flex: 1 1 auto; }
}

.choice {
  position: relative; display: flex; align-items: center; gap: 12px;
  padding: 12px 14px; min-height: 48px;
  background: var(--panel); border: 1.5px solid var(--border); border-radius: var(--r-sm);
  cursor: pointer; transition: border-color 0.15s, background 0.15s;
}
.choice:hover { border-color: var(--border-strong); background: var(--panel-2); }
.choice input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.choice__mark {
  width: 18px; height: 18px; flex: none; border-radius: 50%;
  border: 2px solid var(--border-strong); background: var(--panel);
  display: flex; align-items: center; justify-content: center; transition: all 0.15s;
}
.choice input[type="checkbox"] + .choice__mark { border-radius: 4px; }
.choice__label { font-size: 0.92rem; line-height: 1.35; }
.choice:has(input:checked) { border-color: var(--green); background: var(--green-bg); }
.choice:has(input:checked) .choice__label { font-weight: 600; color: var(--navy); }
.choice input:checked + .choice__mark { border-color: var(--green); background: var(--green); box-shadow: inset 0 0 0 3px var(--panel); }
.choice input[type="checkbox"]:checked + .choice__mark { box-shadow: none; }
.choice input[type="checkbox"]:checked + .choice__mark::after {
  content: ''; width: 5px; height: 9px; border: solid #fff; border-width: 0 2px 2px 0; transform: translateY(-1px) rotate(45deg);
}
.choice:has(input:focus-visible) { box-shadow: var(--ring); }
.choice.is-disabled { opacity: 0.5; cursor: not-allowed; }
.choice.is-disabled:hover { border-color: var(--border); background: var(--panel); }
.q__count { margin-top: 8px; font-size: 0.85rem; color: var(--muted); }
.q__count:empty { display: none; }

/* Questions that only apply to some people */
.reveal { display: none; }
.reveal.is-shown { display: block; animation: stepIn 0.2s ease; }
.reveal--inline { margin: 14px 0 0; }

/* ---- 1-5 rating rows ---------------------------------------------------- */

.ratings { border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); }
.ratings__row {
  display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 4px 20px;
  padding: 14px 16px; border-top: 1px solid var(--border);
}
.ratings__row:first-child { border-top: 0; }
.ratings__row:nth-child(even) { background: var(--panel-2); }
/* After the zebra rule so every row with an error turns red, odd or even. */
.ratings__row.has-error, .ratings__row.has-error:nth-child(even) { background: var(--danger-bg); }
.ratings__label { font-size: 0.92rem; line-height: 1.45; }
.ratings__row > .field-error { grid-column: 1 / -1; margin-top: 2px; }
/* Five pips; the scale's end words sit under them. */
.ratings__scale { display: grid; grid-template-columns: repeat(5, 44px); gap: 6px; }
.ratings__ends {
  grid-column: 1 / 6; display: flex; justify-content: space-between;
  font-size: 0.78rem; line-height: 1.2; color: var(--muted);
}
@media (max-width: 600px) {
  .ratings__row { grid-template-columns: minmax(0, 1fr); gap: 10px; padding: 14px 12px; }
  .ratings__scale { grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 4px; }
  .pip { display: flex; justify-content: center; }
  .pip span { width: 100%; max-width: 48px; height: auto; aspect-ratio: 1; }
}
.pip { position: relative; cursor: pointer; }
.pip input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.pip span {
  display: flex; align-items: center; justify-content: center;
  width: 44px; height: 44px; border-radius: 50%;
  border: 1.5px solid var(--border-strong); background: var(--panel);
  font-weight: 600; font-size: 0.88rem; color: var(--muted); transition: all 0.15s;
}
.pip:hover span { border-color: var(--navy); color: var(--navy); }
.pip input:checked + span { background: var(--green); border-color: var(--green); color: #fff; }
.pip input:focus-visible + span { box-shadow: var(--ring); }

/* Overall experience: 1-5 stars (ui.js showStars sets data-lit) */
.stars { display: grid; grid-template-columns: repeat(5, minmax(0, 60px)); gap: 6px; } /* 56px stars, shrink to fit narrow phones */
.star { position: relative; display: block; padding: 2px; border-radius: var(--r-sm); cursor: pointer; }
.star input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.star svg {
  display: block; width: 100%; height: auto; aspect-ratio: 1;
  fill: transparent; stroke: var(--border-strong); stroke-width: 1.4; stroke-linejoin: round;
  transition: fill 0.15s, stroke 0.15s;
}
.stars[data-lit="1"] .star:nth-child(-n+1) svg,
.stars[data-lit="2"] .star:nth-child(-n+2) svg,
.stars[data-lit="3"] .star:nth-child(-n+3) svg,
.stars[data-lit="4"] .star:nth-child(-n+4) svg,
.stars[data-lit="5"] .star:nth-child(-n+5) svg { fill: #f4b400; stroke: #d99a00; }
.star:has(input:focus-visible) { box-shadow: var(--ring); }
.star.is-pop svg { animation: star-pop 0.3s ease-out; }
@keyframes star-pop { 0% { transform: scale(0.7); } 60% { transform: scale(1.2); } 100% { transform: scale(1); } }
.stars__meaning { margin-top: 10px; min-height: 1.4em; font-size: 0.9rem; color: var(--muted); }
.stars__meaning.is-set { font-weight: 600; color: var(--navy); }
.q--stars.has-error .star svg { stroke: var(--danger); }

/* ---- Qualification repeater --------------------------------------------- */

.repeater { display: flex; flex-direction: column; gap: 12px; margin-bottom: 12px; }
.repeater__item { border: 1px solid var(--border); border-radius: var(--r-md); padding: 14px 16px 16px; background: var(--panel-2); }
.repeater__head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 10px; }
.repeater__title { font-weight: 700; font-size: 0.85rem; color: var(--navy); }
.repeater__item .field { margin-bottom: 14px; }

/* ---- Welcome / done screens --------------------------------------------- */

.welcome { text-align: center; padding: 12px 0 8px; }
.welcome .step__lead { margin: 10px auto 0; }
.welcome__badge {
  width: 64px; height: 64px; margin: 0 auto 18px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  background: var(--green-bg); color: var(--green);
}
.welcome__badge svg { width: 32px; height: 32px; }
.step--break .welcome__badge { width: 96px; height: 96px; margin-bottom: 22px; }
.step--break .welcome__badge svg { width: 48px; height: 48px; }
.welcome__badge--done { background: var(--green); color: #fff; }
.welcome__badge--done svg { stroke-width: 2.4; }
.welcome__badge--award { background: var(--amber); color: #fff; }
.welcome__badge--award svg { stroke-width: 2.4; }
.step--break .welcome__badge { animation: welcomePop 0.55s cubic-bezier(.34, 1.56, .64, 1) both; }
@keyframes welcomePop {
  0% { opacity: 0; transform: scale(0.4); }
  70% { opacity: 1; transform: scale(1.08); }
  100% { opacity: 1; transform: scale(1); }
}
.welcome--break h1 { opacity: 0; animation: signinRise 0.5s 0.15s ease-out both; }
.welcome--break .step__lead { opacity: 0; animation: signinRise 0.5s 0.25s ease-out both; }
.welcome__checklist {
  display: flex; flex-wrap: wrap; justify-content: center; gap: 10px;
  margin: 24px 0 0; padding: 0; list-style: none;
}
.welcome__checklist li {
  display: inline-flex; align-items: center; gap: 6px; padding: 8px 14px; border-radius: 999px;
  background: var(--green-bg); color: var(--green-2); font-size: 0.85rem; font-weight: 600;
  opacity: 0; animation: signinRise 0.45s ease-out both;
}
.welcome__checklist li:nth-child(1) { animation-delay: 0.45s; }
.welcome__checklist li:nth-child(2) { animation-delay: 0.55s; }
.welcome__checklist li:nth-child(3) { animation-delay: 0.65s; }
.welcome__checklist svg { width: 15px; height: 15px; }
.welcome__actions { margin-top: 24px; }
.welcome__tagline { margin: 6px 0 0; font-family: var(--serif); font-style: italic; font-size: 1.1rem; color: var(--green-2); }
.welcome__small { font-size: 0.9rem; }

/* ---- Survey levels (NSBM Graduate Connect) --------------------------------
   Five badges joined by a line: gold = level completed, navy ring = the level
   on screen, grey = still to come. On level pages it sits above the heading;
   on the welcome and achievement screens it is centred and a little larger. */
.levels { margin: 0 0 18px; }
.levels__row { display: flex; align-items: center; max-width: 300px; margin: 0; padding: 0; list-style: none; }
.levels__item { display: flex; align-items: center; flex: 1; }
.levels__item:last-child { flex: none; }
.levels__item:not(:last-child)::after {
  content: ''; flex: 1; height: 2px; margin: 0 6px; border-radius: 1px; background: var(--border);
}
.levels__item.is-earned:not(:last-child)::after { background: var(--amber); }
.levels__badge {
  flex: none; width: 34px; height: 34px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  background: var(--panel); border: 1.5px solid var(--border-strong); color: var(--faint);
}
.levels__badge svg { width: 17px; height: 17px; }
.levels__item.is-current .levels__badge { border: 2px solid var(--navy); color: var(--navy); box-shadow: 0 0 0 4px rgba(15, 42, 67, 0.08); }
.levels__item.is-earned .levels__badge { background: var(--amber); border-color: var(--amber); color: #fff; }
.levels__item.is-earned .levels__badge svg { stroke-width: 2; }
.levels__caption { margin: 8px 0 0; font-size: 0.82rem; font-weight: 600; color: var(--muted); }

.welcome .levels { margin: 26px 0 4px; }
.welcome .levels__row { max-width: 360px; margin: 0 auto; }
.welcome .levels__badge { width: 42px; height: 42px; }
.welcome .levels__badge svg { width: 20px; height: 20px; }
.welcome--break .levels { opacity: 0; animation: signinRise 0.5s 0.35s ease-out both; }
/* With animations turned off (see the reduced-motion rule near the top), the
   fade-ins above never run, so show their end state straight away. */
@media (prefers-reduced-motion: reduce) {
  .welcome--break h1, .welcome--break .step__lead, .welcome--break .levels, .welcome__checklist li { opacity: 1; }
}

/* Achievement for the level just finished, at the top of the next level. */
.level-win {
  display: flex; align-items: center; gap: 14px; margin: 0 0 22px; padding: 14px 16px;
  border-radius: var(--r-md); background: var(--amber-bg); border: 1px solid #f1d9ad;
  animation: signinRise 0.45s ease-out both;
}
.level-win__badge {
  flex: none; width: 44px; height: 44px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center; background: var(--amber); color: #fff;
  animation: welcomePop 0.55s 0.15s cubic-bezier(.34, 1.56, .64, 1) both;
}
.level-win__badge svg { width: 22px; height: 22px; stroke-width: 2; }
.level-win__text { margin: 0; font-size: 0.9rem; line-height: 1.45; color: #5c3a05; text-wrap: pretty; }
.level-win__title { display: block; font-family: var(--serif); font-size: 1.08rem; color: var(--amber-2); }
/* The badge just earned lands after the screen settles: the one moment of motion here. */
.levels__item.is-new .levels__badge { animation: welcomePop 0.55s 0.7s cubic-bezier(.34, 1.56, .64, 1) both; }
.welcome--foot { padding-top: 0; }
.welcome--foot .hint { margin-top: 10px; }
/* "What's next" on the done screen and the account page */
.next { max-width: 480px; margin: 24px auto 0; padding-top: 20px; border-top: 1px solid var(--border); }
.next__title { font-size: 0.98rem; font-weight: 700; color: var(--navy); margin-bottom: 12px; }
.next__list { display: flex; flex-direction: column; gap: 12px; }
.next__list li { display: flex; gap: 12px; align-items: flex-start; font-size: 0.92rem; line-height: 1.5; color: var(--text); text-wrap: pretty; }
.next__list svg { width: 18px; height: 18px; margin-top: 2px; color: var(--green); }
.next__note { max-width: 480px; margin: 18px auto 0; font-size: 0.82rem; color: var(--muted); }
.welcome__logo { height: 56px; width: auto; margin: 0 auto 20px; }
/* Done screen: the member number, the one thing to keep from this page. */
.member-no {
  display: flex; flex-direction: column; align-items: center; gap: 2px;
  max-width: 320px; margin: 22px auto 0; padding: 16px 20px;
  background: var(--green-bg); border-radius: var(--r-md);
}
.member-no__label { font-size: 0.85rem; font-weight: 600; color: var(--green-2); }
.member-no__value { font-size: 2rem; font-weight: 700; line-height: 1.2; letter-spacing: 0.08em; color: var(--navy); font-variant-numeric: tabular-nums; }
.member-no__hint { margin-top: 4px; font-size: 0.82rem; color: var(--muted); text-wrap: pretty; }
.preview-note { margin: 22px auto 0; max-width: 46ch; font-size: 0.8rem; font-style: italic; color: var(--muted); text-wrap: pretty; }

/* ---- Account page: floating-card profile dashboard ----------------------- */

.profile-page { position: relative; max-width: 1240px; padding: 40px 32px 48px; }
@media (max-width: 600px) { .profile-page { padding: 24px 16px 48px; } }
/* Soft brand-colour glows anchored to the actual browser viewport corners
   (fixed, not inside the width-limited .profile-page), so they reach all
   the way to the true page edge regardless of how wide the screen is. Each
   one fades to transparent well inside its own box, so there's never a
   hard "cut circle" line where it happens to go off-screen. */
.profile-blob { position: fixed; z-index: 0; pointer-events: none; }
.profile-blob--1 {
  top: -220px; right: -220px; width: 560px; height: 560px;
  background: radial-gradient(circle, rgba(31, 122, 77, 0.26) 0%, rgba(95, 201, 138, 0.13) 45%, transparent 72%);
}
.profile-blob--2 {
  bottom: -240px; left: -220px; width: 520px; height: 520px;
  background: radial-gradient(circle, rgba(15, 42, 67, 0.2) 0%, rgba(31, 122, 77, 0.1) 45%, transparent 72%);
}
@media (max-width: 760px) {
  .profile-blob--1 { width: 340px; height: 340px; top: -150px; right: -150px; }
  .profile-blob--2 { width: 300px; height: 300px; }
}

/* Stretched so .profile-right (and its .profile-stack--fill row, below)
   has real extra height to grow into -- only that last row actually grows;
   everything above it keeps its natural content height. */
.profile-layout {
  position: relative; z-index: 1; display: grid; grid-template-columns: 360px 1fr; gap: 22px;
  align-items: stretch; min-height: calc(100vh - 230px);
}
@media (max-width: 860px) { .profile-layout { grid-template-columns: 1fr; min-height: 0; } }

.profile-right { display: flex; flex-direction: column; gap: 22px; }
.profile-stack { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 22px; align-items: stretch; }
/* An odd one out (e.g. 1 or 3 cards) would otherwise sit alone with an empty
   slot beside it -- give it the full row instead. */
.profile-stack > .pcard:last-child:nth-child(odd) { grid-column: 1 / -1; }
/* Always exactly the last two cards: grows to fill whatever height
   .profile-right has left over, instead of stopping at its own content height. */
.profile-stack--fill { flex: 1; grid-template-columns: 1fr; grid-template-rows: repeat(2, 1fr); gap: 22px; }
@media (max-width: 600px) { .profile-stack { grid-template-columns: 1fr; } }

.pcard {
  background: var(--panel); border-radius: 22px; box-shadow: 0 2px 6px rgba(15, 23, 42, 0.05), 0 18px 40px rgba(15, 23, 42, 0.08);
  padding: 26px 26px 24px;
}
.pcard__head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 18px; }
/* Short account page (no full profile yet): a narrow, centred column of cards. */
.pcard--narrow { max-width: 480px; margin-left: auto; margin-right: auto; }
.pcard--narrow + .pcard--narrow { margin-top: 22px; }
.pcard--center { text-align: center; }
.next__note--spaced { margin-top: 22px; }
.pcard__head h2 { font-size: 1.02rem; font-weight: 700; color: var(--navy); margin: 0; display: flex; align-items: center; gap: 9px; }
.pcard__head h2 svg { width: 18px; height: 18px; color: var(--green); flex-shrink: 0; }
.pcard .field--locked:last-child { margin-bottom: 0; }
.pcard .next__list { gap: 10px; }
.pcard .next { max-width: none; margin: 0; padding-top: 0; border-top: 0; }

/* Left card: identity. align-self: start keeps it at its natural height even
   though .profile-layout's row is taller (to give .profile-stack--fill, on
   the right, room to grow) -- only that fill row should actually stretch. */
.pcard--identity { align-self: start; text-align: center; }
.pcard__avatar-wrap { position: relative; display: inline-flex; margin-bottom: 16px; }
.pcard__avatar {
  display: flex; align-items: center; justify-content: center; width: 104px; height: 104px; border-radius: 50%;
  background: linear-gradient(135deg, var(--navy) 0%, var(--navy-2) 45%, var(--green) 100%);
  color: #fff; font-family: var(--serif); font-size: 2.1rem; font-weight: 700;
  box-shadow: 0 10px 24px rgba(15, 42, 67, 0.25);
}
.pcard__status-dot {
  position: absolute; right: 4px; bottom: 6px; width: 20px; height: 20px; border-radius: 50%;
  background: var(--green); border: 3px solid var(--panel);
}
.pcard__name { font-size: 1.3rem; margin: 0 0 2px; }
.pcard__role { color: var(--muted); font-size: 0.88rem; margin: 0 0 16px; }
.pcard__badges { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; margin-bottom: 20px; }
.pcard__meta { text-align: left; border-top: 1px solid var(--border); padding-top: 16px; margin-bottom: 18px; }
.pcard--identity .btn-gradient { width: 100%; }

.pill {
  display: inline-flex; align-items: center; gap: 6px; padding: 6px 14px; border-radius: 999px;
  font-size: 0.8rem; font-weight: 700; letter-spacing: 0.01em; white-space: nowrap;
}
.pill svg { width: 13px; height: 13px; }
.pill--brand { background: var(--green-bg); color: var(--green-2); }
.pill--navy { background: #eaf0f6; color: var(--navy); }
.pill--amber { background: var(--amber-bg); color: var(--amber-2); }

.btn-gradient {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  height: 46px; padding: 0 22px; border-radius: 999px; border: 0;
  background: linear-gradient(90deg, var(--navy) 0%, var(--navy-2) 45%, var(--green) 100%);
  color: #fff; font-weight: 700; font-size: 0.92rem; text-decoration: none;
  box-shadow: 0 10px 22px rgba(31, 122, 77, 0.28); transition: transform 0.15s, box-shadow 0.15s;
}
.btn-gradient:hover { transform: translateY(-1px); box-shadow: 0 14px 28px rgba(31, 122, 77, 0.34); }
.btn-gradient svg { width: 16px; height: 16px; }

/* Right cards: a row-style list (used for qualifications) with a status pill per row. */
.prow-list { display: flex; flex-direction: column; gap: 4px; }
.prow { display: flex; align-items: center; justify-content: space-between; gap: 14px; padding: 12px 0; border-bottom: 1px solid var(--border); }
.prow:last-child { border-bottom: 0; padding-bottom: 0; }
.prow__text { min-width: 0; }
.prow__title { font-weight: 700; color: var(--text); font-size: 0.92rem; }
.prow__sub { color: var(--muted); font-size: 0.8rem; margin-top: 1px; }

/* ---- Review ------------------------------------------------------------- */

.review { display: flex; flex-direction: column; gap: 14px; }
.review__group { border-top: 1px solid var(--border); padding-top: 4px; }
.review__head { display: flex; justify-content: space-between; align-items: center; padding: 10px 0 6px; }
.review__head .link { display: inline-flex; align-items: center; min-height: 44px; padding: 0 8px; }
.review__head h2 { font-size: 0.92rem; font-weight: 700; color: var(--navy); }
.review__row { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr); gap: 12px; padding: 10px 0; border-top: 1px solid #edf1f5; font-size: 0.95rem; }
.review__row:first-of-type { border-top: 0; }
.review__q { color: var(--muted); }
.review__a { font-weight: 600; color: var(--text); overflow-wrap: anywhere; }
.review__a--empty { font-weight: 400; color: var(--faint); font-style: italic; }
/* Survey sections fold to one line ("4 answers"); open one to check it. */
.review__more > summary {
  display: flex; align-items: center; gap: 8px; min-height: 40px; padding: 0 0 8px;
  list-style: none; cursor: pointer; font-size: 0.9rem; color: var(--muted);
}
.review__more > summary::-webkit-details-marker { display: none; }
.review__more > summary::before {
  content: ''; flex: none; width: 7px; height: 7px; margin: 0 4px 0 2px;
  border-right: 2px solid var(--muted); border-bottom: 2px solid var(--muted);
  transform: rotate(-45deg); transition: transform 0.15s ease-out;
}
.review__more[open] > summary::before { transform: rotate(45deg); }
.review__more > summary:hover { color: var(--navy); }
.review__more > summary:focus-visible { outline: none; box-shadow: var(--ring); border-radius: var(--r-sm); }
@media (max-width: 600px) { .review__row { grid-template-columns: 1fr; gap: 2px; } }

.consent { display: flex; gap: 8px; align-items: flex-start; margin-top: 18px; font-size: 0.8rem; color: var(--muted); }
.consent svg { width: 15px; height: 15px; margin-top: 2px; color: var(--green); }

/* ---- Buttons & nav ------------------------------------------------------ */

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  height: 46px; padding: 0 22px; border-radius: var(--r-sm);
  border: 1.5px solid transparent; font-weight: 600; font-size: 0.95rem;
  cursor: pointer; white-space: nowrap; transition: background 0.15s, border-color 0.15s, color 0.15s;
}
.btn svg { width: 17px; height: 17px; }
a.btn { text-decoration: none; }
.btn[disabled] { opacity: 0.55; cursor: not-allowed; }
.btn--primary { background: var(--navy); color: #fff; }
.btn--primary:hover:not([disabled]) { background: var(--navy-2); }
.btn--success { background: var(--green); color: #fff; }
.btn--success:hover:not([disabled]) { background: var(--green-2); }
.btn--outline { background: var(--panel); border-color: var(--navy); color: var(--navy); }
.btn--outline:hover:not([disabled]) { background: var(--panel-2); }
.btn--ghost { background: transparent; border-color: var(--border-strong); color: var(--text); }
.btn--ghost:hover:not([disabled]) { background: var(--panel-2); }

.link { border: 0; background: none; padding: 4px 2px; color: var(--green); font-weight: 600; font-size: 0.85rem; cursor: pointer; text-decoration: underline; text-underline-offset: 2px; }
.link[disabled] { color: var(--faint); cursor: default; text-decoration: none; }

.nav { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-top: 32px; padding-top: 22px; border-top: 1px solid var(--border); }
.nav .btn:only-child, .nav #stepNext, .nav #submiter { margin-left: auto; }
/* "Saved on this device · 12:20" with a Save progress link beside it, under the buttons. */
.savebar { display: flex; justify-content: flex-end; align-items: center; flex-wrap: wrap; gap: 4px 14px; margin-top: 10px; }
.nav__save { display: inline-flex; align-items: center; gap: 6px; min-height: 44px; padding: 0 4px; color: var(--navy); }
.nav__save svg { width: 16px; height: 16px; }

/* ---- Save progress (placeholder: browser storage) ----------------------- */

.savestate { margin: 0; text-align: right; font-size: 0.8rem; color: var(--muted); }
.savestate:empty { display: none; }
.savestate.is-error { color: var(--danger); }
@media (max-width: 600px) { .savestate { text-align: center; } }
.draft-notice { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px 14px; margin-bottom: 20px; border-radius: var(--r-sm); background: #eef3f9; color: var(--navy); font-size: 0.9rem; }
.draft-notice .link { flex-shrink: 0; }
@media (max-width: 600px) {
  /* One row: a compact Back, and Continue filling the rest, both in thumb reach. */
  .nav { flex-direction: row; align-items: stretch; gap: 10px; }
  .nav .btn { margin-left: 0; }
  .nav #stepBack { flex: none; padding: 0 16px; }
  .nav #stepNext, .nav #submiter { flex: 1 1 auto; min-width: 0; }
  .nav #submiter { white-space: normal; height: auto; min-height: 46px; padding: 10px 16px; line-height: 1.3; }
  .savebar { justify-content: center; }
}

/* ---- Sign-in page (views/signin.php) -------------------------------------
   After the "OTP Authentication Flow" mockup, in the form's own colours:
   navy + green, Source Serif headings, Inter text. */
.auth-page { position: relative; min-height: 100vh; overflow-x: hidden; background: var(--bg); }
.auth { position: relative; z-index: 1; display: flex; flex-direction: column; align-items: center; justify-content: center;
  min-height: 100vh; padding: 40px 16px; }
.auth__card { width: 100%; max-width: 440px; background: var(--panel); border: 1px solid var(--border);
  border-radius: 22px; box-shadow: 0 2px 4px rgba(15, 23, 42, 0.04), 0 24px 60px rgba(15, 42, 67, 0.12);
  padding: 32px 32px 28px; text-align: center; }
.auth__logo { display: block; height: 58px; width: auto; margin: 0 auto 18px; }
.auth__card .alert { text-align: left; }
.auth__title { text-wrap: balance; font-family: var(--serif); font-size: 1.9rem; line-height: 1.2; font-weight: 700; color: var(--navy); }
.auth__title span { color: var(--green); }
.auth__lead { text-wrap: pretty; margin-top: 8px; color: var(--muted); font-size: 0.97rem; }
.auth__art { margin: 18px auto 6px; width: 120px; height: 120px; }
.auth__art svg { width: 120px; height: 120px; }
.auth__card .field { text-align: left; margin-top: 18px; }
.auth__input { position: relative; }
.auth__input svg { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); width: 19px; height: 19px; color: var(--faint); pointer-events: none; }
.auth__input .input { padding-left: 44px; height: 50px; border-radius: 12px; }
.auth__btn { width: 100%; height: 52px; margin-top: 20px; border-radius: 12px; justify-content: center; gap: 10px;
  color: #fff; font-size: 1rem; background: linear-gradient(90deg, var(--navy) 0%, var(--navy-2) 45%, var(--green) 100%);
  box-shadow: 0 6px 16px rgba(15, 42, 67, 0.18); }
.auth__btn:hover:not([disabled]) { filter: brightness(1.08); }
.auth__btn:focus-visible { box-shadow: var(--ring), 0 6px 16px rgba(15, 42, 67, 0.18); }
.auth__btn svg { width: 19px; height: 19px; }
.auth__card .status { text-align: center; }
.auth__pill { display: inline-flex; align-items: center; gap: 10px; max-width: 100%; margin-top: 12px; padding: 10px 18px;
  border-radius: 999px; background: #eaf1f8; color: var(--navy); font-weight: 600; }
.auth__pill svg { width: 18px; height: 18px; flex: none; }
.auth__pill span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.auth__change { margin-top: 6px; font-size: 0.85rem; }
.auth__code-field { text-align: center !important; margin-top: 22px !important; }
.auth__code { display: flex; justify-content: center; gap: 10px; }
.auth__digit { width: 50px; height: 58px; padding: 0; border: 1.5px solid var(--border-strong); border-radius: 12px;
  background: var(--panel); text-align: center; font: 600 1.45rem var(--sans); color: var(--navy); }
.auth__digit:focus { outline: none; border-color: var(--green); box-shadow: var(--ring); }
.auth__digit.is-filled { border-color: var(--green); }
.auth__code-field.has-error .auth__digit { border-color: var(--danger); }
.auth__code-field.has-error .auth__digit:focus { box-shadow: 0 0 0 2px var(--panel), 0 0 0 4px var(--danger); }
.auth__code-field .field-error { text-align: center; }
.auth__timer { display: inline-flex; align-items: center; gap: 8px; margin-top: 16px; color: var(--muted); font-size: 0.92rem; }
.auth__timer svg { width: 18px; height: 18px; }
.auth__timer strong { color: var(--green); font-variant-numeric: tabular-nums; }
.auth__resend {
  display: flex; flex-direction: column; align-items: center; gap: 2px; margin-top: 22px;
  text-align: center; color: var(--muted); font-size: 0.9rem; text-wrap: pretty;
}
.auth__resend .link { display: inline-flex; align-items: center; min-height: 44px; padding: 0 6px; font-weight: 600; color: var(--green); }
.auth__resend .link[disabled] { color: var(--faint); cursor: not-allowed; text-decoration: none; }
.auth__foot { display: inline-flex; align-items: center; gap: 6px; margin-top: 18px; color: var(--muted); font-size: 0.8rem; text-align: center; }
.auth__foot svg { width: 14px; height: 14px; }
@media (max-width: 480px) {
  .auth__card { padding: 26px 18px 22px; border-radius: 18px; }
  .auth__title { font-size: 1.6rem; }
  .auth__code { gap: 7px; }
  .auth__digit { width: 42px; height: 52px; font-size: 1.3rem; }
}

/* ---- Sign-in page: full-bleed photo hero ---------------------------------
   One photo, one scrim, across the whole page -- not two different
   backgrounds stitched together at a seam. Text sits on the dark side
   of the scrim, the glass card on the lighter side. After the TCU.edu /
   paint-splash login mockups in ss/. */
.signin-hero { position: relative; min-height: 100vh; overflow: hidden; isolation: isolate; display: flex; align-items: center; color: #eef5f0; }
.signin-hero__photo {
  position: absolute; inset: 0; z-index: 0; filter: saturate(1.05);
  background-image: url('../img/campus.jpg');
  background-size: cover; background-position: center 32%;
}
.signin-hero__scrim {
  position: absolute; inset: 0; z-index: 0;
  background: linear-gradient(100deg, rgba(8, 20, 16, 0.92) 0%, rgba(8, 22, 17, 0.84) 30%, rgba(10, 30, 23, 0.6) 50%, rgba(10, 30, 23, 0.45) 62%, rgba(8, 20, 16, 0.58) 100%);
}
.signin-hero__grid {
  position: absolute; inset: 0; z-index: 0; opacity: 0.35;
  background-image: radial-gradient(rgba(255, 255, 255, 0.18) 1px, transparent 1px);
  background-size: 28px 28px;
  -webkit-mask-image: radial-gradient(ellipse 70% 60% at 22% 40%, #000 0%, transparent 75%);
  mask-image: radial-gradient(ellipse 70% 60% at 22% 40%, #000 0%, transparent 75%);
}
.signin-hero__glow { position: absolute; z-index: 0; border-radius: 50%; filter: blur(70px); pointer-events: none;
  mix-blend-mode: screen; animation: glowDrift 18s ease-in-out infinite alternate; }
.signin-hero__glow--a { width: 420px; height: 420px; top: -140px; left: 10%; opacity: 0.4;
  background: radial-gradient(circle, #2fd98a 0%, rgba(47, 217, 138, 0) 70%); animation-duration: 20s; }
.signin-hero__glow--b { width: 360px; height: 360px; bottom: -120px; right: 18%; opacity: 0.3;
  background: radial-gradient(circle, #f0bf3f 0%, rgba(240, 191, 63, 0) 70%); animation-duration: 24s; animation-direction: alternate-reverse; }
@keyframes glowDrift {
  0% { transform: translate(0, 0) scale(1); }
  50% { transform: translate(-20px, 16px) scale(1.07); }
  100% { transform: translate(16px, -12px) scale(0.96); }
}

.signin-hero__layout {
  position: relative; z-index: 1; width: 100%; max-width: 1280px; margin: 0 auto;
  display: flex; align-items: center; justify-content: space-between; gap: 48px; padding: 48px 56px;
}
.signin-hero__text { flex: 1 1 480px; max-width: 560px; animation: signinRise 0.6s ease-out both; }
.signin-hero__logo { height: 48px; width: auto; margin-bottom: 28px; filter: brightness(0) invert(1); opacity: 0.92; }
.signin-hero__headline { margin-top: 0; text-wrap: balance; font-family: var(--serif); font-size: clamp(2.1rem, 3.4vw, 3rem);
  line-height: 1.12; font-weight: 700; color: #fff; text-shadow: 0 2px 30px rgba(0, 0, 0, 0.35); }
.signin-hero__body { margin-top: 18px; font-size: 1.05rem; line-height: 1.6; color: rgba(238, 245, 240, 0.92); max-width: 46ch;
  text-shadow: 0 1px 12px rgba(0, 0, 0, 0.25); }
.signin-hero__reassure { margin-top: 14px; font-size: 0.96rem; font-weight: 400; color: #cdeedb; }
.signin-hero__reassure strong { font-weight: 700; }
.signin-hero__reassure + .signin-hero__reassure { margin-top: 8px; }
.signin-hero__badges { display: flex; flex-wrap: wrap; gap: 10px; margin: 26px 0 0; padding: 0; list-style: none; }
.signin-hero__badges li {
  display: inline-flex; align-items: center; gap: 7px; padding: 8px 14px; border-radius: 999px;
  background: rgba(255, 255, 255, 0.14); border: 1px solid rgba(255, 255, 255, 0.22);
  backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px);
  font-size: 0.83rem; font-weight: 600; color: #f1faf5; white-space: nowrap;
  opacity: 0; animation: signinRise 0.5s ease-out both; animation-delay: 0.3s;
}
/* Staggered here, not with inline styles: the CSP blocks style="" attributes. */
.signin-hero__badges li:nth-child(2) { animation-delay: 0.4s; }
.signin-hero__badges li:nth-child(3) { animation-delay: 0.5s; }
/* They only fade in by animation; with motion reduced (no animation) show them as they are. */
@media (prefers-reduced-motion: reduce) { .signin-hero__badges li { opacity: 1; } }
.signin-hero__badges svg { width: 15px; height: 15px; color: #9fd9bb; }

.signin-hero__form { flex: 0 0 auto; width: 100%; max-width: 440px; }
.signin-hero__form .auth { min-height: 0; padding: 0; }
.signin-hero__form .auth__card {
  position: relative; overflow: hidden; max-width: none; padding: 44px 40px 38px; border-radius: 16px;
  background: rgba(255, 255, 255, 0.58); backdrop-filter: blur(28px) saturate(1.5); -webkit-backdrop-filter: blur(28px) saturate(1.5);
  border: 1px solid rgba(255, 255, 255, 0.55);
  box-shadow: 0 1px 1px rgba(255, 255, 255, 0.45) inset, 0 20px 50px rgba(5, 15, 12, 0.35);
  animation: signinRise 0.6s 0.1s ease-out both;
}
.signin-hero__form .auth__card::before {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background: linear-gradient(145deg, rgba(255, 255, 255, 0.45) 0%, rgba(255, 255, 255, 0.06) 35%, rgba(255, 255, 255, 0) 65%);
}
.signin-hero__form .auth__card .auth__title {
  color: var(--navy); font-size: 2.05rem; font-weight: 800; line-height: 1.22;
}
.signin-hero__form .auth__card .auth__lead { color: #1f3a30; font-size: 0.96rem; line-height: 1.65; margin-top: 12px; }
.signin-hero__form .auth__card label,
.signin-hero__form .auth__card .hint,
.signin-hero__form .auth__card .auth__change { color: var(--navy); }
.signin-hero__form .auth__card .field { margin-top: 26px; }
.signin-hero__form .auth__card .field label { display: block; margin-bottom: 8px; }
.signin-hero__form .auth__card .hint { margin-top: 8px; line-height: 1.5; }
.signin-hero__form .auth__card .auth__btn { margin-top: 28px; }
.signin-hero__form .auth__card .input { background: rgba(255, 255, 255, 0.65); }
.signin-hero__form .auth__foot {
  margin-top: 16px; display: inline-flex; color: #eef5f0; padding: 7px 16px; border-radius: 999px;
  background: rgba(8, 20, 16, 0.45); backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px);
}

@keyframes signinRise {
  from { opacity: 0; transform: translateY(14px); }
  to { opacity: 1; transform: translateY(0); }
}

@media (max-width: 960px) {
  /* Stacked: the words sit across the whole photo, so darken it evenly. */
  .signin-hero__scrim { background: linear-gradient(180deg, rgba(8, 20, 16, 0.86) 0%, rgba(8, 22, 17, 0.72) 45%, rgba(8, 20, 16, 0.6) 100%); }
  .signin-hero__layout { flex-direction: column; align-items: stretch; padding: 40px 24px; gap: 36px; }
  .signin-hero__text { flex: none; max-width: none; text-align: center; } /* the 480px basis is a height once stacked */
  .signin-hero__logo { margin-left: auto; margin-right: auto; }
  .signin-hero__badges { justify-content: center; }
  .signin-hero__form { max-width: 480px; margin: 0 auto; }
}
@media (max-width: 600px) {
  .signin-hero__layout { gap: 22px; }
  .signin-hero__logo { height: 38px; margin-bottom: 16px; }
  .signin-hero__body, .signin-hero__badges { display: none; }
  .signin-hero__reassure { margin-top: 10px; font-size: 0.9rem; }
}
@media (max-width: 480px) {
  .signin-hero__layout { padding: 24px 16px 32px; }
  .signin-hero__badges li { font-size: 0.76rem; padding: 6px 11px; }
  .signin-hero__form .auth__card { padding: 30px 22px 26px; background: rgba(255, 255, 255, 0.9); }
  .signin-hero__headline { font-size: 1.85rem; }
  .signin-hero__form .auth__card .auth__title { font-size: 1.45rem; }
}

/* ---- Verify-your-student-e-mail step (views/register.php) --------------- */
.hint--support { margin-top: 14px; }
/* Inside the Join form the code step lines up with everything else (left). */
.step .auth__code-field { text-align: left !important; }
.step .auth__code { justify-content: flex-start; }
.step .auth__code-field .field-error { text-align: left; }
.step .auth__resend { margin-top: 16px; }
.step .auth__resend::before, .step .auth__resend::after { content: none; }
.hint--support a { color: var(--green); font-weight: 600; }

/* ---- Join steps 1-2 (Find your record, security check): campus photo layout
   Narrow screens: the heading sits on a photo banner at the top of the card,
   with a slanted bottom edge. Wide screens (only while one of these steps is
   showing): the photo fills one side of the page behind a slanted edge, the
   heading is set large on it, and the form sits on the light side.
   Step 1: photo right, form left. Step 2 (.find__media--left): mirrored. */

.find__media {
  position: relative; isolation: isolate; overflow: hidden;
  margin: -36px -40px 28px; padding: 40px 40px 64px;
  border-radius: var(--r-lg) var(--r-lg) 0 0;
  clip-path: polygon(0 0, 100% 0, 100% calc(100% - 32px), 0 100%);
  background:
    linear-gradient(160deg, rgba(8, 22, 17, 0.62) 0%, rgba(8, 22, 17, 0.86) 100%),
    url('../img/campus.jpg') center 32% / cover no-repeat;
  color: #eef5f0;
}
.find__media h1 { color: #fff; }
.find__media .step__lead { color: #d3e9dc; }
/* An error or draft message above the photo: drop the bleed into the card edge. */
.alert.is-visible ~ .step .find__media,
.draft-notice:not(.is-hidden) ~ .step .find__media { margin-top: 0; border-radius: var(--r-md) var(--r-md) 0 0; }
.find__note { margin: -6px 0 0; }
.find__strip { display: none; }
/* Photo steps have a narrow form column: the resend button goes under its hint. */
.step:has(> .find__media) .auth__resend { flex-direction: column; align-items: flex-start; gap: 2px; }
.step:has(> .find__media) .auth__resend .link { padding-left: 0; }
/* Privacy line: the lock icon flows with the first line, so it never strands when the text wraps. */
.v6:has(.step.is-active > .find__media) .footnote { display: block; }
.v6:has(.step.is-active > .find__media) .footnote svg { display: inline-block; vertical-align: -2px; margin-right: 6px; }
@media (max-width: 600px) {
  .find__media { margin: -24px -18px 24px; padding: 28px 18px 52px; border-radius: var(--r-md) var(--r-md) 0 0; }
}

@media (min-width: 1000px) {
  /* Step change: the usual stepIn slide moves the whole step, and a moving
     (transformed) step would hold the full-page photo inside its own box for
     the length of the animation, so the photo flashed small over the form.
     Here the form content slides in and the photo only fades in, in place. */
  .v6 .step.is-active:has(> .find__media) { animation: none; }
  .v6 .step.is-active:has(> .find__media) > :not(.find__media):not(.find__strip) { animation: stepIn 0.25s ease; }
  .v6 .step.is-active > .find__media,
  .v6 .step.is-active > .find__strip { animation: findPhotoIn 0.35s ease-out both; }

  /* Step 1: two slanted strips parallel to the photo's edge (38% -> 66%, so each
     strip also moves 28% across from top to bottom). Same photo, same size and
     position as the main panel, so it reads as one image showing through. */
  .v6:has(#step-find.is-active) .find__strip {
    display: block; position: absolute; inset: 0; z-index: -1; pointer-events: none;
    background:
      linear-gradient(270deg, rgba(8, 22, 17, 0.86) 0%, rgba(8, 22, 17, 0.7) 45%, rgba(8, 22, 17, 0.55) 100%),
      url('../img/campus.jpg') center 32% / cover no-repeat;
  }
  .v6:has(#step-find.is-active) .find__strip--wide { clip-path: polygon(35.1% 0, 37.1% 0, 65.1% 100%, 63.1% 100%); }
  .v6:has(#step-find.is-active) .find__strip--thin { clip-path: polygon(33.1% 0, 34.2% 0, 62.2% 100%, 61.1% 100%); }
  /* Step 2: the same strips mirrored, right of its photo edge (62% -> 34%). */
  .v6:has(#step-find-verify.is-active) .find__strip {
    display: block; position: absolute; inset: 0; z-index: -1; pointer-events: none;
    background:
      linear-gradient(90deg, rgba(8, 22, 17, 0.86) 0%, rgba(8, 22, 17, 0.7) 45%, rgba(8, 22, 17, 0.55) 100%),
      url('../img/campus.jpg') center 32% / cover no-repeat;
  }
  .v6:has(#step-find-verify.is-active) .find__strip--wide { clip-path: polygon(64.9% 0, 62.9% 0, 34.9% 100%, 36.9% 100%); }
  .v6:has(#step-find-verify.is-active) .find__strip--thin { clip-path: polygon(66.9% 0, 65.8% 0, 37.8% 100%, 38.9% 100%); }
}

/* Wider screens have room between the form and the photo for thicker strips. */
@media (min-width: 1200px) {
  .v6:has(#step-find.is-active) .find__strip--wide { clip-path: polygon(34.5% 0, 37.3% 0, 65.3% 100%, 62.5% 100%); }
  .v6:has(#step-find.is-active) .find__strip--thin { clip-path: polygon(32.2% 0, 33.8% 0, 61.8% 100%, 60.2% 100%); }
  .v6:has(#step-find-verify.is-active) .find__strip--wide { clip-path: polygon(65.5% 0, 62.7% 0, 34.7% 100%, 37.5% 100%); }
  .v6:has(#step-find-verify.is-active) .find__strip--thin { clip-path: polygon(67.8% 0, 66.2% 0, 38.2% 100%, 39.8% 100%); }
}
@media (min-width: 1300px) {
  .v6:has(#step-find.is-active) .find__strip--wide { clip-path: polygon(33.8% 0, 37.4% 0, 65.4% 100%, 61.8% 100%); }
  .v6:has(#step-find.is-active) .find__strip--thin { clip-path: polygon(31% 0, 33.2% 0, 61.2% 100%, 59% 100%); }
  .v6:has(#step-find-verify.is-active) .find__strip--wide { clip-path: polygon(66.2% 0, 62.6% 0, 34.6% 100%, 38.2% 100%); }
  .v6:has(#step-find-verify.is-active) .find__strip--thin { clip-path: polygon(69% 0, 66.8% 0, 38.8% 100%, 41% 100%); }
}

@media (min-width: 1000px) {

  /* Shared by both photo steps. */
  .v6:has(.step.is-active > .find__media) { position: relative; }
  .v6:has(.step.is-active > .find__media) .topbar { position: relative; z-index: 2; }

  /* Progress panel floats over both halves, lined up with the form. */
  .v6:has(.step.is-active > .find__media) .journey {
    position: relative; z-index: 1; margin: 20px 0 0 max(32px, 7vw); padding: 18px 24px 20px;
    background: var(--panel); border: 1px solid var(--border); border-radius: var(--r-lg); box-shadow: var(--shadow);
  }

  /* Light side: the form loses its card. */
  .v6:has(.step.is-active > .find__media) .shell { max-width: none; margin: 0; padding: 72px 24px 48px max(32px, 7vw); }
  .v6:has(.step.is-active > .find__media) .card {
    width: min(400px, 34vw); padding: 0; background: none; border: 0; border-radius: 0; box-shadow: none;
  }
  .v6:has(.step.is-active > .find__media) .footnote { width: min(400px, 34vw); justify-content: flex-start; text-align: left; }

  /* Photo side: covers the page behind everything, cut on a slant. */
  .v6:has(.step.is-active > .find__media) .find__media {
    position: absolute; inset: 0; z-index: -1; margin: 0; border-radius: 0;
    padding: 290px 7vw 48px 0;
    display: flex; flex-direction: column; align-items: flex-end; text-align: right;
    clip-path: polygon(38% 0, 100% 0, 100% 100%, 66% 100%);
    background:
      linear-gradient(270deg, rgba(8, 22, 17, 0.86) 0%, rgba(8, 22, 17, 0.7) 45%, rgba(8, 22, 17, 0.55) 100%),
      url('../img/campus.jpg') center 32% / cover no-repeat;
  }
  .v6:has(.step.is-active > .find__media) .find__media h1 {
    max-width: 11ch; font-size: clamp(2.6rem, 4vw, 3.6rem); line-height: 1.08; letter-spacing: -0.01em;
  }
  .v6:has(.step.is-active > .find__media) .find__media .step__lead { max-width: 30ch; margin-top: 22px; font-size: 1.08rem; line-height: 1.5; }

  /* Step 2, mirrored: photo on the left, form and progress panel on the right. */
  .v6:has(.step.is-active > .find__media--left) .journey { margin: 20px max(32px, 7vw) 0 auto; }
  .v6:has(.step.is-active > .find__media--left) .shell { padding: 72px max(32px, 7vw) 48px 24px; }
  .v6:has(.step.is-active > .find__media--left) .card,
  .v6:has(.step.is-active > .find__media--left) .footnote { margin-left: auto; }
  .v6:has(.step.is-active > .find__media--left) .find__media {
    padding: 290px 0 48px 7vw; align-items: flex-start; text-align: left;
    clip-path: polygon(0 0, 62% 0, 34% 100%, 0 100%);
    background:
      linear-gradient(90deg, rgba(8, 22, 17, 0.86) 0%, rgba(8, 22, 17, 0.7) 45%, rgba(8, 22, 17, 0.55) 100%),
      url('../img/campus.jpg') center 32% / cover no-repeat;
  }

  /* Fit the whole step on one laptop screen (about 650-730px tall):
     tighter vertical spacing than the card steps. */
  .v6:has(.step.is-active > .find__media) .journey { margin-top: 14px; padding: 14px 22px 16px; }
  .v6:has(.step.is-active > .find__media) .stepinfo { margin-top: 10px; }
  .v6:has(.step.is-active > .find__media) .shell { padding-top: 48px; padding-bottom: 16px; }
  /* No card here, so no divider above the buttons: spacing alone separates them. */
  .v6:has(.step.is-active > .find__media) .nav { margin-top: 24px; padding-top: 0; border-top: 0; }
  /* Step 1 has no Back button: the action sits under the left-aligned fields. */
  .v6:has(#step-find.is-active) .nav #stepNext { margin-left: 0; }
  .v6:has(#step-find.is-active) .savebar { justify-content: flex-start; }
  .v6:has(.step.is-active > .find__media) .savebar { margin-top: 4px; }
  /* The privacy line sits on the photo's bottom corner, out of the form column. */
  .v6:has(.step.is-active > .find__media) .footnote {
    position: absolute; z-index: 1; bottom: 18px; right: 7vw; width: auto; max-width: 28vw; margin: 0;
    text-align: right; color: #d3e9dc;
  }
  .v6:has(.step.is-active > .find__media--left) .footnote { right: auto; left: 7vw; text-align: left; }
  .v6:has(.step.is-active > .find__media) .auth__pill { margin-bottom: 16px; }
  .v6:has(.step.is-active > .find__media) .step .auth__resend { margin-top: 8px; }
  .v6:has(.step.is-active > .find__media) .hint--support { margin-top: 8px; }
  .v6:has(.step.is-active > .find__media) .find__media { padding-top: 270px; }
  /* Step 1 has fewer fields, so it takes a larger gap under the progress panel. */
  .v6:has(#step-find.is-active) .shell { padding-top: 72px; }
  .v6:has(#step-find.is-active) .find__media { padding-top: 294px; }
}

/* Short laptop screens: a smaller top bar and tighter gaps keep the step on one screen. */
@media (min-width: 1000px) and (max-height: 780px) {
  .v6:has(.step.is-active > .find__media) .topbar__inner { padding-top: 8px; padding-bottom: 8px; }
  .v6:has(.step.is-active > .find__media) .brand__logo { height: 48px; }
  .v6:has(.step.is-active > .find__media) .journey { padding: 12px 22px 14px; }
  .v6:has(.step.is-active > .find__media) .stepinfo { margin-top: 8px; }
  .v6:has(.step.is-active > .find__media) .shell { padding-top: 36px; padding-bottom: 0; }
  .v6:has(.step.is-active > .find__media) .field { margin-bottom: 14px; }
  .v6:has(.step.is-active > .find__media) .nav { margin-top: 16px; }
  .v6:has(.step.is-active > .find__media) .find__media { padding-top: 226px; }
  .v6:has(#step-find.is-active) .shell { padding-top: 60px; }
  .v6:has(#step-find.is-active) .find__media { padding-top: 250px; }
}

@keyframes findPhotoIn { from { opacity: 0; } to { opacity: 1; } }

/* Sign in with a mobile number: the switch link under each card's first panel. */
.auth__switch { margin-top: 14px; font-size: 0.85rem; color: var(--muted); display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 4px; }
.auth__switch .link { display: inline-flex; align-items: center; gap: 6px; min-height: 44px; padding: 0 6px; font-weight: 600; color: var(--green); }
.auth__switch svg { width: 16px; height: 16px; }

/* ---- Editing answers (/register?i=2) ---------------------------------- */
/* The level achievement banners belong to a first run through the survey. */
.is-edit .level-win { display: none; }
/* A written answer: what was said before (read-only), then a box to add another. */
.written { margin: 0 0 24px; }
.written__q { margin: 0 0 8px; font-weight: 600; color: var(--text); }
.written__none { margin: 0 0 8px; font-size: 0.9rem; color: var(--muted); }
.written__list { list-style: none; margin: 0 0 12px; padding: 0; display: grid; gap: 8px; }
.written__list li { background: var(--panel-2); border: 1px solid var(--border); border-radius: var(--r-sm); padding: 10px 14px; }
.written__when { display: block; font-size: 0.78rem; font-weight: 500; color: var(--muted); margin-bottom: 2px; }
.written__text { margin: 0; font-size: 0.95rem; color: var(--text); overflow-wrap: anywhere; }
/* Account page: the Edit my answers button and the saved notice. */
.account-edit { max-width: 480px; margin: 28px auto 0; text-align: center; }
.account-edit .btn { min-width: 220px; justify-content: center; }
.account-edit__note { margin: 10px 0 0; font-size: 0.88rem; color: var(--muted); }
.account-edit .next__note { margin-top: 14px; }
.account-notice { display: flex; align-items: center; gap: 10px; padding: 12px 14px; margin: 0 0 20px; border-radius: var(--r-sm); background: #eef3f9; color: var(--navy); font-size: 0.92rem; }
.account-notice--ok { background: var(--green-bg); color: var(--green-2); }
.account-notice svg { flex-shrink: 0; width: 18px; height: 18px; }
