/* =====================================================================
   APPLYSPARK — styles
   Type: Be Vietnam Pro (made for Vietnamese diacritics), one family throughout.
   Colour: brand navy #1A3054 + one accent, gold #FBAC19 (both from the logo), on neutral greys.
   Red is kept for form errors only. Plenty of space between lines, blocks and sections.
   ===================================================================== */
:root {
  --bg: #f8f6f1;
  --surface: #ffffff;
  --surface-2: #f2efe7;
  --ink: #172033;
  --ink-2: #4d586b;
  --ink-3: #737d91;
  --line: #e6e0d3;
  --line-2: #ede9dd;
  --brand: #1a3054;          /* navy surfaces: buttons, footer, bands */
  --navy: #1a3054;           /* navy text and marks */
  --navy-2: #2a4671;
  --navy-soft: #edf1f7;      /* navy tint for quiet fills */
  --link: #1a3054;
  --hdr-bg: #ffffff;
  --gold: #fbac19;
  --gold-2: #ffbf45;
  --gold-ink: #2b1c00;
  --gold-soft: #fff5df;
  --btn-bg: #1a3054;
  --btn-fg: #ffffff;
  --btn-bg-hover: #2a4671;
  --ok: var(--navy);
  --ok-soft: var(--navy-soft);
  --warn: #8a5a00;
  --warn-soft: var(--gold-soft);
  --bad: #b42318;
  --bad-soft: #fdecea;
  --space: #040914;
  --shadow: 0 1px 2px rgba(23, 32, 51, 0.05), 0 8px 24px -14px rgba(23, 32, 51, 0.18);
  --shadow-lg: 0 24px 56px -24px rgba(10, 18, 36, 0.4);
  --radius: 4px;             /* cards, panels, dialogs: near-square like IDP */
  --r-sm: 3px;               /* buttons, inputs, badges, chips, icon tiles */
  --wrap: 1200px;
  --hdr-h: 72px;
  --font: "Be Vietnam Pro", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  --font-cond: var(--font);
  /* every account type shares the brand navy (roles are told apart by icon and name) */
  --c-student: var(--navy); --c-club_owner: var(--navy); --c-alumni: var(--navy);
  --c-organizer: var(--navy); --c-agency: var(--navy); --c-admin: var(--navy);
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0b111d;
    --surface: #121a2a;
    --surface-2: #0f1624;
    --ink: #e7ecf4;
    --ink-2: #a6b1c3;
    --ink-3: #808b9f;
    --line: #253047;
    --line-2: #1a2335;
    --brand: #16284a;
    --navy: #b4c7ea;
    --navy-2: #cddbf3;
    --navy-soft: #1a2640;
    --link: #b4c7ea;
    --hdr-bg: #0f1624;
    --gold-soft: #33270d;
    --btn-bg: #3a5f9c;
    --btn-bg-hover: #4a6fae;
    --warn: #f3c262;
    --bad: #ff8f85;
    --bad-soft: #3a1818;
    --shadow: 0 1px 2px rgba(0, 0, 0, 0.3), 0 8px 24px -14px rgba(0, 0, 0, 0.6);
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #0b111d;
  --surface: #121a2a;
  --surface-2: #0f1624;
  --ink: #e7ecf4;
  --ink-2: #a6b1c3;
  --ink-3: #808b9f;
  --line: #253047;
  --line-2: #1a2335;
  --brand: #16284a;
  --navy: #b4c7ea;
  --navy-2: #cddbf3;
  --navy-soft: #1a2640;
  --link: #b4c7ea;
  --hdr-bg: #0f1624;
  --gold-soft: #33270d;
  --btn-bg: #3a5f9c;
  --btn-bg-hover: #4a6fae;
  --warn: #f3c262;
  --bad: #ff8f85;
  --bad-soft: #3a1818;
  --shadow: 0 1px 2px rgba(0, 0, 0, 0.3), 0 8px 24px -14px rgba(0, 0, 0, 0.6);
  color-scheme: dark;
}

/* ---------------------------------------------------------------- base */
*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: calc(var(--hdr-h) + 24px); }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font-family: var(--font); font-size: 16px; line-height: 1.7; -webkit-font-smoothing: antialiased;
}
body.has-dialog { overflow: hidden; }
h1, h2, h3, h4 { margin: 0; line-height: 1.3; font-weight: 600; letter-spacing: 0; text-wrap: balance; }
h2 { font-size: clamp(24px, 2.4vw, 32px); }
h3 { font-size: 18px; }
p { margin: 0; }
a { color: var(--link); text-underline-offset: 3px; }
img, svg, canvas { max-width: 100%; }
button { font: inherit; color: inherit; }
:focus-visible { outline: 3px solid var(--gold); outline-offset: 2px; border-radius: var(--r-sm); }
.sr-only { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.wrap { width: min(var(--wrap), 100% - 32px); margin-inline: auto; }
.muted { color: var(--ink-2); }
.small { font-size: 14px; }
.center { text-align: center; display: flex; justify-content: center; }
.center-text { text-align: center; }
.row { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; }
.row.center { justify-content: center; }
.row-between { display: flex; flex-wrap: wrap; gap: 16px; align-items: center; justify-content: space-between; }
.stack { display: flex; flex-direction: column; gap: 20px; }
.stack-sm { display: flex; flex-direction: column; gap: 10px; }
.grid-2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px 24px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px 24px; }
.span-2 { grid-column: 1 / -1; }
@media (max-width: 760px) { .grid-2, .grid-3 { grid-template-columns: minmax(0, 1fr); } }
.lede { font-size: clamp(16.5px, 1.5vw, 18.5px); font-weight: 400; line-height: 1.75; max-width: 62ch; }
.lede-sm { font-size: 16.5px; line-height: 1.7; }
.kicker { font-size: 13.5px; font-weight: 600; letter-spacing: 0.02em; color: var(--ink-3); margin-bottom: 8px; }
.ok-text { color: var(--ok); }
.danger-text { color: var(--bad) !important; }
.code { font-weight: 700; letter-spacing: 0.06em; }
.num, .up-date, .stat-v { font-variant-numeric: tabular-nums; }
.sel { user-select: all; }
.ic { display: inline-flex; vertical-align: -0.2em; flex: none; }

/* ---------------------------------------------------------------- header */
#site-header { position: sticky; top: env(safe-area-inset-top, 0px); z-index: 50; }
.hdr-bar { background: var(--hdr-bg); color: var(--ink); border-bottom: 1px solid var(--line); }
.hdr-in { display: flex; align-items: center; gap: 28px; height: var(--hdr-h); }
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; color: var(--navy); flex: none; }
.brand img { height: 28px; width: auto; }
.brand-word { font-weight: 700; font-size: 19px; letter-spacing: 0.03em; }
.brand-word em { font-style: normal; color: var(--gold); }
.brand .logo-on-dark { display: none; }
.hdr-bar { position: relative; }
.hdr-nav { flex: 1; min-width: 0; align-self: stretch; }
.nav-list { list-style: none; margin: 0; padding: 0; display: flex; align-items: stretch; gap: 2px; height: 100%; }
.nav-top { display: flex; align-items: center; }
.nav-link {
  display: inline-flex; align-items: center; gap: 6px; padding: 10px 13px; color: var(--ink-2); text-decoration: none; font: inherit; font-size: 15px;
  font-weight: 500; line-height: 1.4; white-space: nowrap; background: none; border: 0; border-radius: var(--r-sm); cursor: pointer;
}
.nav-link:hover, .has-mega.is-open > .nav-link { color: var(--ink); background: var(--surface-2); }
.nav-link.is-active { color: var(--navy); box-shadow: inset 0 -2px 0 var(--gold); border-radius: 0; }
.nav-group .ic { transition: transform 0.15s; }
.has-mega.is-open > .nav-group .ic { transform: rotate(180deg); }
/* the drop-down panel spans the whole header, like IDP's */
.mega { display: none; position: absolute; left: 0; right: 0; top: 100%; background: var(--surface); border-block: 1px solid var(--line); box-shadow: var(--shadow-lg); z-index: 5; }
.has-mega.is-open > .mega { display: block; }
.mega-in { display: grid; grid-template-columns: minmax(220px, 1fr) minmax(0, 2.6fr); gap: 48px; padding-block: 28px 34px; }
.mega-kicker { font-size: 12.5px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--navy); padding-bottom: 12px; border-bottom: 1px solid var(--line); margin-bottom: 14px; }
.mega-title { font-size: 19px; font-weight: 600; line-height: 1.4; color: var(--ink); text-wrap: balance; }
.mega-text { color: var(--ink-2); font-size: 14.5px; margin-top: 8px; max-width: 34ch; }
.mega-list { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 4px 28px; align-content: start; }
.mega-item { display: flex; gap: 14px; align-items: flex-start; padding: 12px; border-radius: var(--r-sm); color: var(--ink); text-decoration: none; }
.mega-item:hover { background: var(--surface-2); }
.mega-item.is-active { box-shadow: inset 3px 0 0 var(--gold); }
.mega-ic { flex: none; width: 40px; height: 40px; display: grid; place-items: center; background: var(--surface-2); border: 1px solid var(--line); border-radius: var(--r-sm); color: var(--navy); }
.mega-item:hover .mega-ic { background: var(--surface); }
.mega-txt { display: grid; gap: 2px; min-width: 0; }
.mega-name { font-weight: 600; font-size: 15px; line-height: 1.4; }
.mega-desc { color: var(--ink-2); font-size: 13.5px; line-height: 1.5; }
.nav-theme { display: none; }
.theme-seg { display: inline-flex; border: 1px solid var(--line); border-radius: var(--r-sm); overflow: hidden; }
.theme-seg button { background: none; border: 0; color: var(--ink-2); padding: 5px 9px; cursor: pointer; display: inline-grid; place-items: center; }
.theme-seg button:hover { color: var(--ink); }
.theme-seg button[aria-pressed="true"] { background: var(--btn-bg); color: #fff; }
.hdr-right { display: flex; align-items: center; gap: 12px; flex: none; }
.lang { display: inline-flex; border: 1px solid var(--line); border-radius: var(--r-sm); overflow: hidden; }
.lang button { background: none; border: 0; color: var(--ink-2); font-size: 13px; font-weight: 600; padding: 6px 12px; cursor: pointer; letter-spacing: 0.04em; }
.lang button[aria-pressed="true"] { background: var(--btn-bg); color: #fff; }
.hdr-signin { display: inline-flex; align-items: center; gap: 6px; color: var(--navy); font-weight: 600; text-decoration: none; font-size: 15.5px; white-space: nowrap; }
.hdr-signin .ic { display: none; }
.hdr-signin:hover { text-decoration: underline; }
.hdr-account { display: flex; align-items: center; gap: 14px; }
.hdr-icon { position: relative; color: var(--ink); display: inline-flex; padding: 7px; border-radius: var(--r-sm); }
.hdr-icon:hover { background: var(--surface-2); }
.hdr-badge { position: absolute; top: -2px; right: -4px; min-width: 18px; height: 18px; padding: 0 5px; border-radius: 0; background: var(--gold); color: var(--gold-ink); font-size: 11px; font-weight: 700; display: grid; place-items: center; }
.hdr-me { display: inline-flex; align-items: center; gap: 6px; color: var(--navy); text-decoration: none; font-weight: 600; font-size: 15px; }
.hdr-menu { display: none; background: none; border: 0; color: var(--ink); padding: 7px; cursor: pointer; border-radius: var(--r-sm); }
.hdr-menu:hover { background: var(--surface-2); }
@media (max-width: 1100px) {
  .hdr-menu { display: inline-flex; }
  .hdr-in { gap: 16px; }
  .hdr-nav { position: absolute; left: 0; right: 0; top: var(--hdr-h); background: var(--hdr-bg); border-bottom: 1px solid var(--line); box-shadow: var(--shadow-lg);
    display: none; max-height: calc(100vh - var(--hdr-h)); overflow-y: auto; align-self: auto; }
  #site-header.is-open .hdr-nav { display: block; }
  .nav-list { flex-direction: column; align-items: stretch; padding: 6px 16px 18px; gap: 0; height: auto; }
  .nav-top { display: block; }
  .nav-group { display: none; }
  .mega, .has-mega.is-open > .mega { display: block; position: static; border: 0; box-shadow: none; background: none; }
  .mega-in { display: block; width: auto; padding: 16px 0 2px; }
  .mega-title, .mega-text, .mega-desc { display: none; }
  .mega-kicker { margin: 0; padding: 0 8px 6px; font-size: 12px; border: 0; color: var(--ink-3); }
  .mega-list { display: block; }
  .mega-item { padding: 10px 8px; border-radius: 0; border-bottom: 1px solid var(--line-2); align-items: center; }
  .mega-item:hover { background: none; color: var(--navy); }
  .mega-item.is-active { padding-left: 14px; }
  .mega-ic { width: 34px; height: 34px; }
  .nav-top > .nav-link { display: flex; width: 100%; padding: 16px 8px 12px; font-size: 16px; font-weight: 600; border-radius: 0; border-bottom: 1px solid var(--line-2); }
  .nav-top > .nav-link:hover { background: none; color: var(--navy); }
  .nav-top > .nav-link.is-active { box-shadow: inset 3px 0 0 var(--gold); padding-left: 14px; }
  .nav-top > .nav-group { display: none; } /* on phones each section shows its pages under a small heading instead */
  .hdr-right { margin-left: auto; }
  .hdr-me span { display: none; }
}
@media (max-width: 560px) {
  .hdr-theme { display: none; }
  .nav-theme { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 16px 8px 4px; color: var(--ink-2); font-weight: 600; font-size: 14px; }
  .hdr-in { gap: 10px; }
  .hdr-right { gap: 8px; }
  .hdr-signin span { display: none; }
  .hdr-signin .ic { display: inline-flex; }
  .hdr-signin { padding: 7px; border-radius: var(--r-sm); }
  .lang button { padding: 6px 9px; }
}
@media (max-width: 380px) { .brand-word { font-size: 16px; } .brand img { height: 23px; } }
/* on phones the language switch moves into the menu, next to the theme (the header keeps search, account and menu) */
.nav-lang { display: none; }
@media (max-width: 560px) { .hdr-lang { display: none; } .nav-lang { display: flex; padding-top: 12px; } }

.banner { font-size: 14.5px; }
.banner .wrap { display: flex; align-items: center; gap: 6px 10px; padding-block: 10px; flex-wrap: wrap; }
.banner .wrap > span { flex: 1 1 240px; min-width: 0; }
.banner .wrap > .btn { min-height: 0; padding: 2px 0; }
@media (min-width: 900px) { .banner .wrap > span { flex: 0 1 auto; } }
.banner-demo { background: var(--gold-soft); color: var(--ink); border-bottom: 1px solid var(--line); }
.banner-ann { background: var(--brand); color: #fff; }

/* ---------------------------------------------------------------- buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 46px; padding: 0 24px;
  border-radius: var(--r-sm); border: 1.5px solid transparent; font-weight: 600; font-size: 15px; line-height: 1.2; letter-spacing: 0.01em;
  text-decoration: none; cursor: pointer; background: transparent; color: var(--ink); white-space: nowrap;
  transition: background 0.15s, color 0.15s, border-color 0.15s, transform 0.05s;
}
.btn:active { transform: translateY(1px); }
.btn:disabled { opacity: 0.55; cursor: not-allowed; }
.btn-primary { background: var(--btn-bg); color: var(--btn-fg); }
.btn-primary:hover { background: var(--btn-bg-hover); }
.btn-gold { background: var(--gold); color: var(--gold-ink); }
.btn-gold:hover { background: var(--gold-2); }
.btn-outline { border-color: var(--line); color: var(--navy); background: var(--surface); }
.btn-outline:hover { border-color: var(--navy); }
.btn-outline.is-on { border-color: var(--gold); background: var(--gold-soft); }
.btn-ghost { border-color: var(--line); background: var(--surface); }
.btn-ghost:hover { border-color: var(--ink-3); }
.btn-ghost-light { border-color: rgba(255, 255, 255, 0.55); color: #fff; }
.btn-ghost-light:hover { background: rgba(255, 255, 255, 0.08); }
.btn-danger { background: var(--bad); color: #fff; }
.btn-link { min-height: 0; padding: 4px 2px; border: 0; color: var(--link); text-decoration: underline; font-weight: 500; }
.btn-link:hover { color: var(--ink); }
/* long labels (e.g. the shortlist request) wrap instead of pushing past the screen */
.btn-wrap, .dlg-actions .btn { white-space: normal; text-align: center; max-width: 100%; }
.btn-wrap { line-height: 1.35; padding-block: 11px; }
.btn-sm { min-height: 38px; padding: 0 16px; font-size: 14px; }
.btn-sm.btn-link { min-height: 0; padding: 2px; }
.btn-lg { min-height: 52px; padding: 0 30px; font-size: 16px; }
.btn-block { width: 100%; }
.btn-in-list { background: var(--navy-soft); color: var(--navy); border-color: var(--navy); }
.btn-role { border-color: var(--line); color: var(--navy); background: var(--surface); }
.btn-role:hover { border-color: var(--navy); }
.btn.copied { border-color: var(--navy); }
.icon-btn { display: inline-grid; place-items: center; width: 36px; height: 36px; border-radius: var(--r-sm); border: 0; background: transparent; color: var(--ink-2); cursor: pointer; }
.icon-btn:hover { background: var(--line-2); color: var(--ink); }
.icon-btn.sm { width: 28px; height: 28px; border-radius: var(--r-sm); }
.link-strong { font-weight: 600; }
.link-ext { display: inline-flex; align-items: center; gap: 4px; }

/* ---------------------------------------------------------------- forms */
.form label, .label-like { display: block; font-size: 15px; font-weight: 500; margin-bottom: 8px; color: var(--ink); }
.field { display: flex; flex-direction: column; }
.field .opt { font-weight: 400; color: var(--ink-3); }
input[type="text"], input[type="email"], input[type="tel"], input[type="url"], input[type="password"], input[type="number"], input[type="search"],
input[type="date"], input[type="month"], input[type="datetime-local"], select, textarea {
  width: 100%; font: inherit; font-size: 16px; color: var(--ink); background: var(--surface); border: 1.5px solid var(--line);
  border-radius: var(--r-sm); padding: 11px 14px; min-height: 48px;
}
/* phone number with country picker */
.phone-input { position: relative; display: flex; gap: 8px; align-items: stretch; }
.phone-input > input[type="tel"] { flex: 1; min-width: 0; }
.pi-btn { display: inline-flex; align-items: center; gap: 8px; min-height: 48px; padding: 0 12px; font: inherit; font-size: 16px; color: var(--ink); background: var(--surface); border: 1.5px solid var(--line); border-radius: var(--r-sm); cursor: pointer; white-space: nowrap; }
.pi-btn:hover { border-color: var(--ink-3); }
.pi-btn:focus-visible { border-color: var(--btn-bg); outline: none; box-shadow: 0 0 0 3px color-mix(in srgb, var(--btn-bg) 18%, transparent); }
.pi-flag { font-size: 20px; line-height: 1; font-family: "Apple Color Emoji", "Segoe UI Emoji", "Noto Color Emoji", sans-serif; }
.pi-panel { position: absolute; z-index: 40; top: calc(100% + 6px); left: 0; width: min(340px, calc(100vw - 32px)); background: var(--surface); border: 1.5px solid var(--line); border-radius: var(--r-sm); box-shadow: var(--shadow-lg); padding: 8px; }
.pi-panel .pi-search { min-height: 42px; padding-block: 8px; font-size: 15px; }
.pi-list { list-style: none; margin: 6px 0 0; padding: 0; max-height: 260px; overflow-y: auto; }
.pi-opt { display: flex; align-items: center; gap: 10px; width: 100%; padding: 8px 10px; font: inherit; font-size: 15px; color: var(--ink); text-align: left; background: none; border: 0; border-radius: 8px; cursor: pointer; }
.pi-opt:hover, .pi-opt:focus-visible { background: var(--surface-2); outline: none; }
.pi-list [aria-selected="true"] .pi-opt { background: var(--navy-soft); font-weight: 600; }
.pi-name { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pi-dial { color: var(--ink-3); font-variant-numeric: tabular-nums; }
.pi-none { padding: 10px; color: var(--ink-3); }
.phone-input[aria-invalid] > input, .phone-input[aria-invalid] > .pi-btn { border-color: var(--bad); }
textarea { resize: vertical; line-height: 1.6; }
input:focus, select:focus, textarea:focus { border-color: var(--btn-bg); outline: none; box-shadow: 0 0 0 3px color-mix(in srgb, var(--btn-bg) 18%, transparent); }
[aria-invalid] { border-color: var(--bad) !important; }
.hint { font-size: 14px; color: var(--ink-3); margin-top: 8px; line-height: 1.6; }
.err { font-size: 14px; color: var(--bad); min-height: 0; margin-top: 6px; }
.err:empty { display: none; }
.form-msg { font-size: 15px; min-height: 20px; color: var(--ink-2); }
.form-msg.is-error { color: var(--bad); }
.form-msg.is-ok { color: var(--ok); }
.check { display: flex !important; align-items: flex-start; gap: 10px; font-weight: 400 !important; cursor: pointer; }
.check input { width: 18px; height: 18px; margin-top: 4px; accent-color: var(--btn-bg); flex: none; }
.inline { display: flex; gap: 10px; }
.inline select { width: auto; flex: none; }
.fieldset { border: 1.5px solid var(--line); border-radius: var(--radius); padding: 16px 20px 20px; margin: 0; }
.fieldset legend { font-weight: 600; font-size: 15px; padding: 0 6px; }
.form-nav { display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-top: 8px; }
.pw-wrap { position: relative; }
.pw-wrap input { padding-right: 48px; }
.pw-toggle { position: absolute; right: 6px; top: 6px; }

.chips { display: flex; flex-wrap: wrap; gap: 10px; }
.chip {
  display: inline-flex; align-items: center; gap: 6px; border: 1.5px solid var(--line); background: var(--surface); color: var(--ink);
  padding: 8px 16px; border-radius: var(--r-sm); font-size: 14.5px; font-weight: 500; cursor: pointer;
}
.chip:hover { border-color: var(--navy); }
.chip[aria-pressed="true"] { background: var(--btn-bg); border-color: var(--btn-bg); color: var(--btn-fg); }
.chip-sm { padding: 5px 12px; font-size: 13.5px; }
.chip-n { font-size: 12.5px; opacity: 0.7; font-variant-numeric: tabular-nums; }
.chip-star .ic { color: var(--gold); }
.chip[aria-pressed="true"] .ic { color: var(--gold); }
.tag-input { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; border: 1.5px solid var(--line); border-radius: var(--r-sm); padding: 7px 9px; background: var(--surface); }
.tag-input:focus-within { border-color: var(--btn-bg); }
.tag-input input { border: 0; min-height: 34px; padding: 4px; flex: 1; min-width: 140px; box-shadow: none !important; }
.tags { display: contents; }
.tag { display: inline-flex; align-items: center; gap: 4px; background: var(--navy-soft); color: var(--ink); border-radius: var(--r-sm); padding: 4px 6px 4px 12px; font-size: 14px; }
.tag button { border: 0; background: none; cursor: pointer; color: var(--ink-3); display: inline-grid; place-items: center; padding: 2px; }
.tag-sugg { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px; }
.tests { display: flex; flex-direction: column; gap: 10px; }
.test-row { display: flex; flex-wrap: wrap; gap: 10px 18px; align-items: center; padding: 10px 0; border-bottom: 1px solid var(--line-2); }
.test-row:last-child { border-bottom: 0; }
.test-name { font-weight: 600; min-width: 56px; }
.test-fields { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; flex: 1; min-width: 240px; }
.test-fields select { width: auto; }
.test-fields input { flex: 1; min-width: 150px; }
.test-fields .hint { margin: 0; width: 100%; }
.tests-sub { display: flex; flex-direction: column; gap: 2px; margin: 14px 0 0; padding-top: 12px; border-top: 1px solid var(--line); }
.tests-sub .hint { margin: 0; }
.test-row.is-lang .test-name { display: inline-flex; flex-direction: column; min-width: 150px; }
.test-sub { font-weight: 400; font-size: .8rem; color: var(--muted); }
.lang-req { display: grid; gap: 10px; margin: 0; padding: 0; list-style: none; }
.lang-req li { border: 1px solid var(--line); border-radius: 10px; padding: 10px 12px; }
.lang-req .lr-top { display: flex; flex-wrap: wrap; gap: 6px 10px; align-items: baseline; justify-content: space-between; }
.lang-req .lr-track { font-weight: 600; }
.lang-req .lr-min { margin: 4px 0 0; }
.lang-req .lr-note { margin: 4px 0 0; color: var(--muted); font-size: .88rem; }
.lang-req .lr-you { margin: 6px 0 0; font-size: .88rem; display: flex; gap: 6px; align-items: center; }
.lang-req .lr-you.is-ok { color: var(--ok, #1a7f4b); }
.lang-req .lr-you.is-gap { color: var(--warn, #a15c00); }
.lr-badge { font-size: .75rem; font-weight: 600; padding: 2px 8px; border-radius: 999px; background: var(--line-2); white-space: nowrap; }
.lr-badge.is-required { background: color-mix(in srgb, var(--warn, #a15c00) 18%, transparent); }
.lr-badge.is-one_of { background: color-mix(in srgb, var(--accent, #2b59c3) 15%, transparent); }
.lr-badge.is-not_required { background: color-mix(in srgb, var(--ok, #1a7f4b) 15%, transparent); }
.lr-badge.is-after_enrolment { background: color-mix(in srgb, var(--muted, #666) 15%, transparent); }
.seg { display: inline-flex; background: var(--line-2); border-radius: var(--r-sm); padding: 4px; gap: 4px; margin-block: 8px 20px; }
.seg button { border: 0; background: none; padding: 8px 20px; border-radius: var(--r-sm); font-weight: 600; font-size: 14px; cursor: pointer; color: var(--ink-2); }
.seg button[aria-checked="true"] { background: var(--surface); color: var(--ink); box-shadow: var(--shadow); }

/* ---------------------------------------------------------------- badges */
.badge { display: inline-flex; align-items: center; gap: 4px; font-size: 12.5px; font-weight: 600; padding: 3px 10px; border-radius: var(--r-sm); background: var(--line-2); color: var(--ink-2); vertical-align: 0.1em; margin-left: 6px; white-space: nowrap; }
.badge-ok { background: var(--navy-soft); color: var(--navy); }
.badge-warn { background: var(--gold-soft); color: var(--warn); }
.badge-muted { background: var(--line-2); color: var(--ink-3); }
.badge-gold { background: var(--gold-soft); color: var(--warn); }
.badge-sample { background: transparent; border: 1.5px dashed var(--ink-3); color: var(--ink-3); }
.cd { display: inline-flex; font-size: 12.5px; font-weight: 600; padding: 3px 10px; border-radius: var(--r-sm); background: var(--line-2); color: var(--ink-2); white-space: nowrap; font-variant-numeric: tabular-nums; }
.cd.is-soon { background: var(--gold-soft); color: var(--warn); }
.cd.is-urgent { background: var(--gold); color: var(--gold-ink); }
.cd.is-closed { background: transparent; color: var(--ink-3); text-decoration: line-through; }
.role-badge { display: inline-flex; align-items: center; gap: 5px; font-size: 13px; font-weight: 600; padding: 3px 11px; border-radius: var(--r-sm); color: var(--navy); background: var(--navy-soft); }
[data-role] { --role: var(--navy); }
.plan-badge { font-size: 12.5px; font-weight: 600; padding: 3px 11px; border-radius: var(--r-sm); background: var(--line-2); color: var(--ink-2); }
.plan-badge.plan-premium { background: var(--gold-soft); color: var(--warn); }
.plan-badge.plan-vip { background: var(--brand); color: var(--gold); }
.kind { display: inline-block; font-size: 13px; font-weight: 600; color: var(--ink-3); }
.pills { display: flex; flex-wrap: wrap; gap: 8px; }
.pill { font-size: 13px; padding: 3px 11px; border-radius: var(--r-sm); border: 1px solid var(--line); color: var(--ink-2); background: var(--surface-2); }
.pill-soft { border-style: dashed; }
.notice { display: flex; gap: 12px; align-items: flex-start; background: var(--surface-2); border: 1px solid var(--line); border-left: 3px solid var(--gold); padding: 14px 16px; border-radius: var(--r-sm); font-size: 15px; }
.notice > .ic { margin-top: 3px; color: var(--ink-3); }
.notice.ok { border-left-color: var(--navy); }
.lock-box { display: flex; gap: 16px; align-items: center; flex-wrap: wrap; background: var(--gold-soft); border: 1px solid color-mix(in srgb, var(--gold) 45%, transparent); border-radius: var(--radius); padding: 16px 18px; }
.lock-box > div { flex: 1; min-width: 200px; }
.lock-box p { font-size: 14.5px; color: var(--ink-2); }
.empty { text-align: center; padding: 40px 20px; color: var(--ink-2); border: 1.5px dashed var(--line); border-radius: var(--radius); background: var(--surface); grid-column: 1 / -1; }
.empty-title { font-weight: 600; color: var(--ink); font-size: 17px; margin-bottom: 6px; }
.empty .btn { margin-top: 16px; }
.loading { display: flex; align-items: center; gap: 10px; color: var(--ink-2); padding: 30px 0; }
.spin { width: 18px; height: 18px; border-radius: 50%; border: 2.5px solid currentColor; border-right-color: transparent; animation: spin 0.8s linear infinite; flex: none; }
@keyframes spin { to { transform: rotate(360deg); } }

/* ---------------------------------------------------------------- section scaffolding */
.section { padding-block: 96px; }
.section-alt { background: var(--surface); border-block: 1px solid var(--line-2); }
.section-head { margin-bottom: 40px; max-width: 70ch; }
.section-head.row-between { max-width: none; align-items: flex-end; }
.section-head .lede { margin-top: 12px; color: var(--ink-2); }
.page-body { padding-block: 48px 96px; display: flex; flex-direction: column; gap: 28px; }
.filters { display: flex; flex-direction: column; gap: 14px; }
.filters input[type="search"] { max-width: 440px; }
.filters select { max-width: 280px; }
.page-hero { background: var(--surface); color: var(--ink); padding-block: 64px 52px; border-bottom: 1px solid var(--line); }
.page-hero h1 { font-size: clamp(32px, 4vw, 46px); font-weight: 600; color: var(--navy); max-width: 24ch; }
.page-hero .lede { color: var(--ink-2); margin-top: 16px; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 28px; }
@media (max-width: 760px) {
  .section { padding-block: 64px; }
  .section-head { margin-bottom: 28px; }
  .page-hero { padding-block: 40px 36px; }
  .page-body { padding-block: 32px 72px; }
}

/* ---------------------------------------------------------------- atlas (globe hero) */
.atlas {
  position: relative; color: #e8edf6; padding: 40px 16px 28px; overflow: hidden;
  background: radial-gradient(110% 85% at 50% 42%, #0f2148 0%, #081330 42%, var(--space) 78%);
}
.atlas-stars { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; }
.atlas-frame { position: relative; max-width: 1240px; margin-inline: auto; display: grid; grid-template-rows: 1fr auto; gap: 20px; min-height: clamp(560px, 80vh, 820px); }
.atlas-body { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.6fr) minmax(0, 1fr); align-items: center; gap: 32px; }
.atlas-left { align-self: center; display: flex; flex-direction: column; gap: 20px; max-width: 340px; }
.atlas-left h1 { font-size: clamp(30px, 3vw, 42px); font-weight: 600; color: #fff; line-height: 1.22; }
.atlas-lede { font-size: 16.5px; line-height: 1.75; color: rgba(232, 237, 246, 0.8); }
.atlas-link { align-self: flex-start; display: inline-flex; align-items: center; gap: 8px; background: none; border: 0; padding: 6px 0; cursor: pointer;
  color: #fff; font-size: 15px; font-weight: 500; border-bottom: 1.5px solid var(--gold); }
.atlas-link:hover { color: var(--gold); }
.atlas-stage { position: relative; width: 100%; aspect-ratio: 1 / 1; max-width: 660px; justify-self: center; }
.globe-host { position: absolute; inset: 0; }
/* the globe is seen through a round window: zoomed in, the Earth fills it and fades softly at the rim */
.globe-canvas { display: block; width: 100%; height: 100%; cursor: grab; touch-action: pan-y; outline: none;
  -webkit-mask-image: radial-gradient(closest-side, #000 88%, transparent 100%); mask-image: radial-gradient(closest-side, #000 88%, transparent 100%); }
.globe-host:has(.globe-canvas:focus-visible)::after { content: ""; position: absolute; inset: 7%; border-radius: 50%; border: 2px solid var(--gold); pointer-events: none; }
.globe-loading { position: absolute; inset: 0; display: grid; place-items: center; align-content: center; gap: 10px; color: rgba(232, 237, 246, 0.72); font-size: 14.5px; }
.globe-loading::before { content: ""; position: absolute; width: 76%; aspect-ratio: 1; border-radius: 50%; background: radial-gradient(circle at 35% 35%, #1d4f8f, #0b2449 60%, #06122a); box-shadow: 0 0 60px rgba(80, 150, 255, 0.25); }
.globe-loading > * { position: relative; }
.globe-fallback { position: absolute; inset: 0; display: grid; place-content: center; gap: 16px; text-align: center; padding: 20px; }
.globe-markers { position: absolute; inset: 0; pointer-events: none; z-index: 3; }
.globe-marker { position: absolute; left: 0; top: 0; display: flex; align-items: center; gap: 7px; background: none; border: 0; padding: 0; cursor: pointer; pointer-events: auto;
  transition: opacity 0.2s; will-change: transform; font-family: var(--font); }
.globe-marker .dot { width: 9px; height: 9px; border-radius: 50%; background: #fff; box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.22), 0 0 12px rgba(255, 255, 255, 0.55); margin-left: -4.5px; margin-top: -4.5px; }
.globe-marker .lbl { font-size: 12.5px; font-weight: 500; letter-spacing: 0.01em; color: #fff; background: rgba(6, 12, 26, 0.66);
  padding: 3px 9px; border-radius: var(--r-sm); margin-top: -4.5px; white-space: nowrap; transition: opacity 0.15s; }
.globe-marker.no-lbl .lbl { opacity: 0; }
.globe-marker.no-lbl:hover, .globe-marker.no-lbl:focus-visible { z-index: 2; }
.globe-marker.no-lbl:hover .lbl, .globe-marker.no-lbl:focus-visible .lbl { opacity: 1; }
.globe-marker:hover .dot, .globe-marker:focus-visible .dot { background: var(--gold); }
.globe-marker.is-home .dot { background: var(--gold); animation: pulse 2.4s ease-out infinite; }
.globe-marker.is-home .lbl { color: var(--gold); }
@keyframes pulse { 0% { box-shadow: 0 0 0 0 rgba(251, 172, 25, 0.7); } 100% { box-shadow: 0 0 0 16px rgba(251, 172, 25, 0); } }
.atlas-right { justify-self: end; text-align: right; display: flex; flex-direction: column; align-items: flex-end; gap: 20px; max-width: 280px; min-height: 280px; justify-content: center; }
.atlas-stats { margin: 0; display: flex; flex-direction: column; gap: 22px; }
.atlas-stat dt { font-size: 13.5px; font-weight: 500; color: rgba(232, 237, 246, 0.62); }
.atlas-stat dd { margin: 4px 0 0; font-size: 16px; line-height: 1.5; color: #fff; }
.atlas-stat .stat-strong { color: #fff; font-weight: 600; }
.atlas-stat .cd { background: rgba(255, 255, 255, 0.12); color: #fff; }
.atlas-stat .cd.is-urgent { background: var(--gold); color: var(--gold-ink); }
.atlas-open { display: inline-flex; align-items: center; gap: 8px; background: var(--gold); color: var(--gold-ink); border: 0; border-radius: var(--r-sm); padding: 11px 20px; font-weight: 600; cursor: pointer; }
.atlas-bottom { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.atlas-hint { display: inline-flex; align-items: center; gap: 8px; font-size: 14px; color: rgba(232, 237, 246, 0.6); text-align: center; }
.atlas-nav { display: inline-flex; align-items: center; gap: 10px; background: none; border: 0; color: rgba(232, 237, 246, 0.9); cursor: pointer; padding: 8px 4px; font-size: 15px; font-weight: 500; }
.atlas-nav:hover { color: var(--gold); }
.flatmap { width: 100%; height: 100%; }
.fm-country { fill: #25406e; stroke: #0b1731; stroke-width: 0.5; cursor: pointer; }
.fm-country.has-data { fill: #3b67a8; }
.fm-country:hover, .fm-country:focus { fill: var(--gold); outline: none; }
.fm-marker { fill: #fff; cursor: pointer; }
@media (max-width: 980px) {
  .atlas { padding: 20px 16px 20px; }
  .atlas-frame { min-height: 0; gap: 12px; }
  .atlas-body { grid-template-columns: minmax(0, 1fr); gap: 18px; }
  .atlas-stage { order: 1; max-width: 520px; }
  .atlas-left { order: 2; max-width: none; gap: 14px; }
  .atlas-right { order: 3; justify-self: stretch; text-align: left; align-items: flex-start; max-width: none; min-height: 0; }
  .atlas-stats { flex-direction: row; flex-wrap: wrap; gap: 16px 28px; }
  .atlas-hint { display: none; }
  .atlas-nav span:not(.ic) { max-width: 120px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
}

/* ---------------------------------------------------------------- quiz, strips, cards */
.quiz-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); padding: 36px; display: grid; grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr); gap: 36px; }
.quiz-steps { list-style: none; counter-reset: q; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 30px; }
.quiz-steps li { counter-increment: q; position: relative; padding-left: 48px; }
.quiz-steps li::before { content: counter(q); position: absolute; left: 0; top: -1px; width: 32px; height: 32px; border-radius: 50%; background: var(--navy-soft); color: var(--navy); display: grid; place-items: center; font-weight: 700; font-size: 14px; }
.quiz-steps h3 { margin-bottom: 14px; font-size: 17.5px; }
.quiz-result { background: var(--surface-2); border-radius: var(--radius); padding: 24px; align-self: start; position: sticky; top: calc(var(--hdr-h) + 24px); }
.quiz-result { display: flex; flex-direction: column; gap: 18px; }
.quiz-result .kicker { margin: 0; }
.quiz-pick { display: flex; flex-direction: column; gap: 14px; }
.quiz-pick + .quiz-pick { border-top: 1px solid var(--line); padding-top: 18px; }
.quiz-pick h3 { font-size: 26px; }
@media (max-width: 860px) { .quiz-card { grid-template-columns: minmax(0, 1fr); padding: 24px 20px; gap: 28px; } .quiz-result { position: static; } }
.upcoming { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 250px), 1fr)); gap: 20px; }
.up-card { display: flex; flex-direction: column; gap: 8px; padding: 22px 24px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); text-decoration: none; color: var(--ink); }
.up-card:hover { border-color: var(--navy); box-shadow: var(--shadow); }
.up-top { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.up-kind { font-size: 13px; font-weight: 600; color: var(--ink-3); }
.up-date { font-weight: 600; font-size: 22px; color: var(--navy); }
.up-title { font-weight: 500; line-height: 1.45; }
.up-sub { font-size: 14px; color: var(--ink-2); line-height: 1.55; }
.role-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 210px), 1fr)); gap: 20px; }
.role-card { display: flex; flex-direction: column; gap: 12px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 26px 24px; }
.role-card .btn { margin-top: auto; align-self: flex-start; }
.role-card .ticks { margin-bottom: 8px; }
.role-icon { width: 44px; height: 44px; border-radius: var(--radius); display: grid; place-items: center; color: var(--navy); background: var(--navy-soft); }
.ticks { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 9px; }
.ticks li { position: relative; padding-left: 24px; font-size: 15px; line-height: 1.6; }
.ticks li::before { content: ""; position: absolute; left: 3px; top: 0.6em; width: 9px; height: 5px; border-left: 2px solid var(--navy); border-bottom: 2px solid var(--navy); transform: rotate(-45deg); }
.gaps { padding-left: 20px; margin: 0; display: flex; flex-direction: column; gap: 9px; font-size: 15px; line-height: 1.6; }
.gaps li::marker { color: var(--gold); }
.tools { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 300px), 1fr)); gap: 16px; }
.tool { display: flex; align-items: center; gap: 16px; padding: 20px; border-radius: var(--radius); background: var(--surface); border: 1px solid var(--line); text-decoration: none; color: var(--ink); }
.tool > span:nth-child(2) { display: flex; flex-direction: column; gap: 2px; flex: 1; }
.tool:hover { border-color: var(--navy); }
.tool-ic { width: 42px; height: 42px; border-radius: var(--r-sm); display: grid; place-items: center; background: var(--navy-soft); color: var(--navy); flex: none; }
.tool-go { color: var(--ink-3); }
.plan-mini { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; }
.plan-mini-card { display: flex; flex-direction: column; gap: 6px; padding: 26px 24px; border-radius: var(--radius); border: 1px solid var(--line); background: var(--surface); text-decoration: none; color: var(--ink); }
.plan-mini-card.plan-premium { border: 2px solid var(--gold); }
.plan-mini-card.plan-vip { background: var(--brand); color: #fff; border-color: var(--brand); }
.plan-mini-card.plan-vip .muted { color: rgba(255, 255, 255, 0.74); }
.plan-name { font-weight: 600; font-size: 18px; }
.plan-price { font-size: 26px; font-weight: 700; font-variant-numeric: tabular-nums; }
@media (max-width: 760px) { .plan-mini { grid-template-columns: minmax(0, 1fr); } }
.cta-band { background: var(--brand); color: #fff; padding-block: 80px; }
.cta-inner { display: flex; flex-direction: column; align-items: center; gap: 18px; text-align: center; }
.cta-inner img { height: 48px; width: auto; }
.cta-inner p { color: rgba(255, 255, 255, 0.78); max-width: 56ch; }
.cta-inner .row { margin-top: 8px; }

/* ---------------------------------------------------------------- listings */
.card-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 310px), 1fr)); gap: 20px; }
.listing, .person, .uni-card, .panel, .card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); }
.listing, .person { padding: 24px; display: flex; flex-direction: column; gap: 12px; }
.listing.is-featured { border: 2px solid var(--gold); }
.listing.is-locked { background: var(--surface-2); }
.listing h3, .person h3 { font-size: 18px; }
.listing-top { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; }
.listing-top .badge { margin-left: 0; }
.listing-links { margin-top: auto; padding-top: 8px; }
.person-top { display: flex; gap: 14px; align-items: center; }
.avatar { width: 48px; height: 48px; border-radius: 50%; display: grid; place-items: center; color: var(--navy); background: var(--navy-soft); font-weight: 700; flex: none; }
.person-uni { color: var(--navy); font-weight: 500; font-size: 15px; }
.person-bio { font-size: 15px; color: var(--ink-2); line-height: 1.65; }
.person-foot { margin-top: auto; display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 12px; padding-top: 14px; border-top: 1px solid var(--line-2); }
.tests-line { letter-spacing: 0.01em; }
.perk { background: var(--gold-soft); border-radius: var(--r-sm); padding: 14px; display: flex; flex-direction: column; gap: 10px; align-items: flex-start; }
.roles-row { display: flex; flex-wrap: wrap; gap: 8px; }
.role-need { font-size: 13.5px; padding: 4px 12px; border-radius: var(--r-sm); border: 1.5px dashed var(--navy); color: var(--navy); }
.role-filled { font-size: 13.5px; padding: 4px 12px; border-radius: var(--r-sm); background: var(--line-2); color: var(--ink-3); }
.checklist { background: var(--surface); border: 1px solid var(--line); border-left: 3px solid var(--gold); border-radius: var(--radius); padding: 30px; }
.checklist ol { columns: 2; column-gap: 40px; margin: 18px 0 0; padding-left: 20px; }
.checklist li { break-inside: avoid; margin-bottom: 14px; font-size: 15px; color: var(--ink-2); }
.checklist li strong { color: var(--ink); }
@media (max-width: 760px) { .checklist ol { columns: 1; } .checklist { padding: 22px; } }
.mini-list { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 12px; }
.mini-list li { padding-bottom: 12px; border-bottom: 1px solid var(--line-2); }
.mini-list li:last-child { border-bottom: 0; }

/* ---------------------------------------------------------------- deadlines */
.dl-list { display: flex; flex-direction: column; gap: 12px; }
.dl-item { display: grid; grid-template-columns: 160px minmax(0, 1fr) auto; gap: 20px; align-items: center; padding: 18px 22px; background: var(--surface); border: 1px solid var(--line); border-left: 3px solid var(--line); border-radius: var(--radius); }
.dl-item.is-soon, .dl-item.is-urgent { border-left-color: var(--gold); }
.dl-item.is-closed { opacity: 0.6; }
.dl-when { display: flex; flex-direction: column; gap: 6px; align-items: flex-start; }
.dl-day { font-weight: 600; font-size: 18px; color: var(--navy); font-variant-numeric: tabular-nums; }
.dl-title { font-weight: 500; }
.dl-actions { display: flex; flex-wrap: wrap; gap: 10px; justify-content: flex-end; align-items: center; }
@media (min-width: 701px) { .dl-actions { flex-direction: column; align-items: flex-end; gap: 8px; } }
@media (max-width: 700px) { .dl-item { grid-template-columns: minmax(0, 1fr); gap: 12px; } .dl-when { flex-direction: row; align-items: center; } .dl-actions { justify-content: flex-start; } }

/* ---------------------------------------------------------------- country */
.country-hero { background: var(--brand); color: #fff; padding-block: 32px 44px; }
.back-link { display: inline-flex; align-items: center; gap: 6px; color: rgba(232, 237, 246, 0.82); text-decoration: none; font-size: 15px; margin-bottom: 22px; }
.back-link:hover { color: #fff; }
.country-hero .atlas-tag { display: block; margin-bottom: 8px; font-size: 14px; color: rgba(232, 237, 246, 0.7); }
.country-name { font-weight: 600; font-size: clamp(38px, 6vw, 68px); line-height: 1.1; }
.country-stats { display: flex; flex-wrap: wrap; gap: 0; margin-top: 28px; border-top: 1px solid rgba(232, 237, 246, 0.16); }
.cstat { display: flex; flex-direction: column; gap: 4px; padding: 16px 28px 0 0; margin-right: 28px; border-right: 1px solid rgba(232, 237, 246, 0.14); min-width: 0; max-width: 100%; }
.cstat:last-child { border-right: 0; }
.cstat-l { font-size: 13.5px; font-weight: 500; color: rgba(232, 237, 246, 0.7); }
.cstat-v { font-size: 17px; }
.cstat .cd { background: rgba(255, 255, 255, 0.14); color: #fff; }
.cstat .cd.is-urgent { background: var(--gold); color: var(--gold-ink); }
@media (max-width: 640px) {
  .country-stats { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 18px; }
  .cstat { padding: 14px 0 0; margin: 0; border-right: 0; }
  .cstat:nth-child(2) { grid-column: 1 / -1; order: -1; }
  .tabs { flex-wrap: wrap; }
}
.tabs { display: flex; gap: 10px; overflow-x: auto; padding-block: 20px 0; }
.tab { border: 1.5px solid var(--line); background: var(--surface); border-radius: var(--r-sm); padding: 9px 18px; font-weight: 500; cursor: pointer; white-space: nowrap; }
.tab:hover { border-color: var(--navy); }
.with-dock { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 28px; width: min(var(--wrap), 100% - 32px); margin-inline: auto; align-items: start; }
.with-dock > .wrap { width: auto; margin: 0; }
.country-body { padding-block: 32px 72px; display: flex; flex-direction: column; gap: 56px; }
.c-section { display: flex; flex-direction: column; gap: 20px; scroll-margin-top: calc(var(--hdr-h) + 24px); }
.uni-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 330px), 1fr)); gap: 20px; }
.verify { display: inline-flex; gap: 5px; align-items: center; font-size: 13.5px; color: var(--ink-3); }
.verify.ok { color: var(--navy); }
.tip { display: flex; gap: 10px; align-items: flex-start; background: var(--gold-soft); border-radius: var(--r-sm); padding: 12px 14px; font-size: 15px; margin-top: 12px; line-height: 1.6; }
.tip .ic { color: var(--warn); margin-top: 3px; }
.sources { font-size: 13px; color: var(--ink-3); margin-top: 12px; }
.sources a { margin-right: 4px; }
.submit-band { flex-direction: row; flex-wrap: wrap; justify-content: space-between; align-items: center; background: var(--surface); border: 1px solid var(--line); border-left: 3px solid var(--gold); border-radius: var(--radius); padding: 28px; }
.submit-band > div { flex: 1; min-width: 260px; }
.list-dock { position: sticky; top: calc(var(--hdr-h) + 20px); margin-top: 32px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px; box-shadow: var(--shadow); display: flex; flex-direction: column; gap: 14px; }
.dock-head { display: flex; justify-content: space-between; gap: 10px; align-items: flex-start; }
.dock-kicker { font-size: 13px; font-weight: 600; color: var(--ink-3); }
.dock-count { font-weight: 600; font-size: 18px; }
.dock-items { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; font-size: 14.5px; }
.dock-items li { display: flex; justify-content: space-between; gap: 8px; align-items: center; }
.dock-empty { font-size: 14.5px; color: var(--ink-2); }
.dock-submit { width: 100%; white-space: normal; text-align: center; }
@media (max-width: 1020px) {
  .with-dock { grid-template-columns: minmax(0, 1fr); width: 100%; }
  .with-dock > .wrap { width: min(var(--wrap), 100% - 32px); margin-inline: auto; }
  .list-dock { position: fixed; left: 10px; right: 10px; bottom: calc(10px + env(safe-area-inset-bottom, 0px)); top: auto; margin: 0; z-index: 40; flex-direction: row; flex-wrap: wrap; align-items: center; padding: 10px 12px; }
  .list-dock .dock-items, .list-dock .dock-empty { display: none; }
  .list-dock .dock-head { flex: 1; align-items: center; }
  .list-dock .dock-submit { width: auto; }
  body[data-route="country"] #app, body[data-route="deadlines"] #app { padding-bottom: 96px; }
}
.list-review { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 12px; }
.list-review li { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px; padding-bottom: 12px; border-bottom: 1px solid var(--line-2); }

/* ---------------------------------------------------------------- tables */
.table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); }
.table { width: 100%; border-collapse: collapse; font-size: 15px; }
.table th, .table td { text-align: left; padding: 14px 16px; border-bottom: 1px solid var(--line-2); vertical-align: top; }
.table thead th { font-size: 13px; color: var(--ink-3); background: var(--surface-2); font-weight: 600; white-space: nowrap; }
.table tbody tr:last-child > * { border-bottom: 0; }
.table tr.is-past { opacity: 0.55; }
.table tbody th { font-weight: 500; }
.table.summary th { width: 36%; color: var(--ink-2); font-weight: 500; }

/* ---------------------------------------------------------------- auth */
.auth-band { background: var(--surface); color: var(--ink); padding-block: 56px 112px; border-bottom: 1px solid var(--line); }
.auth-band h1 { font-size: clamp(32px, 4.2vw, 48px); font-weight: 600; color: var(--navy); max-width: 20ch; }
.auth-band .lede { color: var(--ink-2); margin-top: 16px; }
.auth-card-wrap { margin-top: -72px; padding-bottom: 88px; }
.auth-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow-lg); padding: clamp(24px, 4vw, 48px); max-width: 580px; }
.auth-card.wide { max-width: 920px; }
.auth-card-title { font-size: 26px; }
.auth-divider { border-top: 1.5px dashed var(--line); margin-block: 8px; }
.demo-logins { display: flex; flex-direction: column; gap: 12px; background: var(--surface-2); border-radius: var(--radius); padding: 16px; }
.demo-logins .chip { border-color: var(--line); }
.demo-code { display: flex; gap: 8px; align-items: center; background: var(--gold-soft); border-radius: var(--r-sm); padding: 12px 16px; font-size: 15px; }
.steps { list-style: none; margin: 0 0 10px; padding: 0; display: flex; gap: 8px; }
.steps li { flex: 1; display: flex; flex-direction: column; gap: 8px; font-size: 13px; color: var(--ink-3); border-top: 3px solid var(--line); padding-top: 10px; }
.steps li.done { border-top-color: var(--navy); color: var(--ink-2); }
.steps li.current { border-top-color: var(--gold); color: var(--ink); font-weight: 600; }
.step-n { width: 24px; height: 24px; border-radius: 50%; display: grid; place-items: center; background: var(--line-2); font-weight: 700; font-size: 12px; }
.steps li.done .step-n { background: var(--brand); color: #fff; }
.steps li.current .step-n { background: var(--gold); color: var(--gold-ink); }
@media (max-width: 560px) { .step-l { display: none; } }
.step-count { font-size: 14px; font-weight: 600; color: var(--ink-3); margin-bottom: 8px; }
.role-pick { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 240px), 1fr)); gap: 14px; }
.role-option { position: relative; display: flex; gap: 14px; align-items: flex-start; border: 1.5px solid var(--line); border-radius: var(--radius); padding: 18px; cursor: pointer; background: var(--surface); }
.role-option > .ic { color: var(--navy); }
.role-option input { position: absolute; opacity: 0; inset: 0; margin: 0; cursor: pointer; }
.role-option:hover { border-color: var(--navy); }
.role-option:has(input:checked) { border-color: var(--navy); box-shadow: inset 0 0 0 1.5px var(--navy); background: var(--navy-soft); }
.role-option:has(input:focus-visible) { outline: 3px solid var(--gold); outline-offset: 2px; }
.role-text { display: flex; flex-direction: column; gap: 4px; }
.role-text span { font-size: 14.5px; color: var(--ink-2); line-height: 1.55; }
.terms { font-size: 15px; }
.otp-row { display: flex; gap: 10px; justify-content: center; }
.otp { width: 52px !important; height: 62px; text-align: center; font-size: 26px !important; font-weight: 700; padding: 0 !important; }
@media (max-width: 420px) { .otp { width: 42px !important; height: 54px; } .otp-row { gap: 6px; } }
.verify-head { display: flex; gap: 14px; align-items: flex-start; }
.verify-head .ic { color: var(--navy); }
.success-mark { width: 64px; height: 64px; margin-inline: auto; border-radius: 50%; display: grid; place-items: center; background: var(--brand); color: #fff; }
.next-steps { background: var(--surface-2); border-radius: var(--radius); padding: 18px; text-align: left; }
.next-steps h3 { margin-bottom: 8px; }

/* ---------------------------------------------------------------- dashboard */
.dash { width: min(1280px, 100% - 32px); margin-inline: auto; display: grid; grid-template-columns: 260px minmax(0, 1fr); gap: 36px; padding-block: 36px 88px; align-items: start; }
.dash-nav { position: sticky; top: calc(var(--hdr-h) + 20px); background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px 12px; }
.dash-who { display: flex; gap: 12px; align-items: center; padding: 0 6px 16px; border-bottom: 1px solid var(--line-2); margin-bottom: 10px; }
.dash-avatar { width: 44px; height: 44px; border-radius: var(--radius); display: grid; place-items: center; background: var(--navy-soft); color: var(--navy); flex: none; }
.dash-name { font-weight: 600; line-height: 1.3; margin-bottom: 6px; word-break: break-word; }
.dash-nav ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 2px; }
.dash-nav a { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-radius: var(--r-sm); text-decoration: none; color: var(--ink-2); font-weight: 500; font-size: 15px; }
.dash-nav a:hover { background: var(--surface-2); color: var(--ink); }
.dash-nav a.is-active { background: var(--navy-soft); color: var(--navy); box-shadow: inset 3px 0 0 var(--gold); }
.dash-nav a.is-active .ic { color: var(--navy); }
.dash-logout { display: flex; align-items: center; gap: 12px; width: 100%; margin-top: 12px; padding: 10px 12px; border: 0; border-top: 1px solid var(--line); border-radius: 0 0 var(--radius) var(--radius); background: none; color: var(--ink-3); font: 500 15px/1.3 var(--font); cursor: pointer; text-align: left; }
.dash-logout:hover { color: var(--ink); }
@media (max-width: 900px) { .dash-logout { width: auto; margin-top: 6px; border-top: 0; } }
.dash-nav .count { margin-left: auto; background: var(--gold); color: var(--gold-ink); font-size: 12px; font-weight: 700; border-radius: var(--r-sm); padding: 1px 8px; }
.dash-main { display: flex; flex-direction: column; gap: 24px; min-width: 0; }
.dash-head h1 { font-size: clamp(26px, 3vw, 34px); font-weight: 600; color: var(--navy); }
.dash-head .muted { margin-top: 8px; max-width: 70ch; }
@media (max-width: 900px) {
  .dash { grid-template-columns: minmax(0, 1fr); gap: 20px; padding-top: 20px; }
  .dash-nav { position: static; padding: 12px; }
  .dash-who { padding-bottom: 12px; }
  .dash-nav ul { flex-direction: row; overflow-x: auto; scrollbar-width: none; }
  .dash-nav a { white-space: nowrap; }
  .dash-nav a.is-active { box-shadow: inset 0 -3px 0 var(--gold); }
}
.panel { padding: 26px; display: flex; flex-direction: column; gap: 16px; }
.panel h2 { font-size: 20px; }
.card-pad { padding: 30px; }
.center-card { display: flex; flex-direction: column; align-items: center; gap: 14px; text-align: center; max-width: 580px; margin-inline: auto; }
.stat-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 190px), 1fr)); gap: 16px; }
.stat { display: flex; flex-direction: column; gap: 6px; padding: 20px 22px; border-radius: var(--radius); background: var(--surface); border: 1px solid var(--line); text-decoration: none; color: var(--ink); }
a.stat:hover { border-color: var(--navy); }
.stat-l { font-size: 13.5px; font-weight: 500; color: var(--ink-3); }
.stat-v { font-size: 28px; font-weight: 600; line-height: 1.2; color: var(--navy); }
.stat-f { font-size: 14px; }
.quick { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.quick-link { display: flex; align-items: center; gap: 12px; padding: 14px; border-radius: var(--r-sm); background: var(--surface-2); text-decoration: none; color: var(--ink); font-weight: 500; font-size: 15px; }
.quick-link:hover { background: var(--line-2); }
.quick-link .ic { color: var(--navy); }
.req-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 14px; }
.req { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px 22px; display: flex; flex-direction: column; gap: 12px; }
.req.is-done { opacity: 0.65; }
blockquote { margin: 0; padding: 12px 16px; border-left: 3px solid var(--line); background: var(--surface-2); border-radius: 0 var(--r-sm) var(--r-sm) 0; font-size: 15px; white-space: pre-wrap; }
.kv { margin: 0; display: grid; grid-template-columns: max-content minmax(0, 1fr); gap: 10px 18px; font-size: 15px; }
.kv > div { display: contents; }
.kv dt { color: var(--ink-3); }
.kv dd { margin: 0; word-break: break-word; }
.copy-chip { display: inline-flex; align-items: center; gap: 4px; background: var(--surface-2); border: 1px solid var(--line); border-radius: var(--r-sm); padding: 2px 2px 2px 10px; max-width: 100%; }
.copy-val { font-variant-numeric: tabular-nums; font-weight: 500; overflow-wrap: anywhere; }
.saved-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.saved-list li { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; padding: 14px 16px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); }
.saved-list li a { font-weight: 500; }
.timeline { margin: 0; padding-left: 22px; display: flex; flex-direction: column; gap: 10px; line-height: 1.65; }
.timeline li::marker { font-weight: 700; color: var(--navy); }

/* CV analyzer */
.cv-layout { display: grid; grid-template-columns: minmax(0, 1fr); gap: 24px; }
.cv-out:empty { display: none; }
.cv-score { display: flex; gap: 24px; align-items: center; flex-wrap: wrap; }
.cv-score > div { flex: 1; min-width: 240px; display: flex; flex-direction: column; gap: 6px; }
.cv-level { align-self: flex-start; font-size: 13px; font-weight: 600; padding: 3px 12px; border-radius: var(--r-sm); background: var(--gold-soft); color: var(--warn); }
.ring { width: 120px; height: 120px; flex: none; }
.ring-bg { fill: none; stroke: var(--line-2); stroke-width: 10; }
.ring-fg { fill: none; stroke: var(--gold); stroke-width: 10; stroke-linecap: round; }
.ring-v { font: 700 32px var(--font); fill: var(--ink); }
.ring-l { font: 500 13px var(--font); fill: var(--ink-3); }
.bars { display: flex; flex-direction: column; gap: 14px; }
.bar-row { display: grid; grid-template-columns: 230px minmax(0, 1fr) 40px; gap: 14px; align-items: center; font-size: 15px; }
.bar { height: 8px; background: var(--line-2); border-radius: var(--r-sm); overflow: hidden; }
.bar-fill { display: block; height: 100%; background: var(--navy); border-radius: var(--r-sm); }
.bar-v { text-align: right; font-variant-numeric: tabular-nums; font-weight: 600; }
@media (max-width: 560px) { .bar-row { grid-template-columns: minmax(0, 1fr) 40px; } .bar-row .bar { grid-column: 1 / -1; grid-row: 2; } }
.ai-note { display: flex; gap: 14px; align-items: flex-start; background: var(--navy-soft); border: 1px solid color-mix(in srgb, var(--navy) 16%, transparent); border-radius: var(--radius); padding: 18px 20px; }
.ai-note > .ic { color: var(--gold); margin-top: 3px; }
.ai-note > .spin { margin-top: 4px; color: var(--navy); }
.ai-note strong { display: block; color: var(--navy); margin-bottom: 2px; }
.ai-note p { font-size: 14.5px; color: var(--ink-2); line-height: 1.65; }
.ai-note-sm { font-size: 14px; color: var(--ink-2); display: flex; gap: 8px; align-items: flex-start; }
.ai-note-sm .ic { color: var(--gold); margin-top: 3px; }
/* estimated progress while the AI profile review runs */
.ai-progress { display: flex; flex-direction: column; gap: 10px; padding: 18px 0; }
.ai-progress__label { font-size: 14.5px; color: var(--ink-2); }
.ai-progress__track { display: block; height: 8px; background: var(--navy-soft); border-radius: var(--r-sm); overflow: hidden; }
.ai-progress__bar { display: block; height: 100%; width: 0; background: var(--gold); border-radius: var(--r-sm); transition: width 0.25s linear; }
@media (prefers-reduced-motion: reduce) { .ai-progress__bar { transition: none; } }
.school-list { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 330px), 1fr)); gap: 16px; }
.school { display: flex; flex-direction: column; gap: 10px; padding: 20px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); }
.school-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 10px; }
.school-head h3 { font-size: 17px; }
.school-head p { font-size: 14px; color: var(--ink-3); }
.school-lines { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.school-lines li { display: flex; gap: 10px; align-items: flex-start; font-size: 14.5px; line-height: 1.55; }
.school-lines li > .ic { margin-top: 2px; color: var(--ink-3); }
.school-lines li.is-ok > .ic { color: var(--navy); }
.school-lines li.is-gap > .ic { color: var(--warn); }
.school-head h3 a { color: inherit; text-decoration: none; }
.school-head h3 a:hover { text-decoration: underline; }
.school-why { font-size: 14.5px; color: var(--ink-2); line-height: 1.6; }
.school-why .ic { color: var(--gold); }
.fit { flex: none; font-size: 12.5px; font-weight: 600; padding: 3px 10px; border-radius: var(--r-sm); background: var(--line-2); color: var(--ink-2); white-space: nowrap; border: 1.5px solid transparent; }
.fit-reach { background: var(--gold-soft); color: var(--warn); }
.fit-match { background: var(--navy-soft); color: var(--navy); }
.fit-likely { background: var(--btn-bg); color: var(--btn-fg); }
.fit-needs { background: transparent; border-color: var(--gold); color: var(--warn); }
.fit-closed { background: var(--line-2); color: var(--ink-3); }
.ai-schools { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 12px; }
.ai-schools li { display: flex; flex-direction: column; gap: 4px; padding-bottom: 12px; border-bottom: 1px solid var(--line-2); }
.ai-schools li:last-child { border-bottom: 0; padding-bottom: 0; }
.ai-schools .row { gap: 10px; }

/* ---------------------------------------------------------------- inbox */
.inbox { display: grid; grid-template-columns: 360px minmax(0, 1fr); gap: 0; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; background: var(--surface); min-height: 520px; }
.inbox-col { border-right: 1px solid var(--line); max-height: 72vh; overflow-y: auto; }
.inbox-list { list-style: none; margin: 0; padding: 0; }
.inbox-list li { border-bottom: 1px solid var(--line-2); }
.msg-row { display: flex; gap: 12px; align-items: flex-start; width: 100%; text-align: left; background: none; border: 0; padding: 16px 18px; cursor: pointer; }
.msg-row:hover { background: var(--surface-2); }
.inbox-list li.is-open .msg-row { background: var(--navy-soft); }
.msg-ic { width: 36px; height: 36px; flex: none; border-radius: var(--r-sm); display: grid; place-items: center; background: var(--line-2); color: var(--navy); }
.msg-main { display: flex; flex-direction: column; gap: 3px; flex: 1; min-width: 0; }
.msg-title { font-size: 15px; line-height: 1.4; }
.is-unread .msg-title { font-weight: 700; }
.msg-time { font-size: 13px; color: var(--ink-3); }
.msg-row .dot { width: 9px; height: 9px; border-radius: 50%; background: var(--gold); margin-top: 7px; flex: none; }
.inbox-detail { padding: 26px 30px; display: flex; flex-direction: column; gap: 18px; overflow-y: auto; max-height: 72vh; }
.msg-head { display: flex; gap: 12px; align-items: flex-start; }
.msg-head h2 { font-size: 21px; }
.msg-foot { border-top: 1px solid var(--line-2); padding-top: 12px; }
.inbox-back { display: none; align-self: flex-start; }
.report-uni { border-top: 1px solid var(--line-2); padding-top: 16px; display: flex; flex-direction: column; gap: 8px; }
.report-dl { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 6px; }
.report-dl li { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; font-size: 15px; }
.report-alumni { background: var(--surface-2); border-radius: var(--radius); padding: 16px; }
.report-alumni h3 { margin-bottom: 8px; }
@media (max-width: 900px) {
  .inbox { grid-template-columns: minmax(0, 1fr); }
  .inbox-col { border-right: 0; max-height: none; }
  .inbox-detail { display: none; max-height: none; padding: 22px 20px; }
  .inbox.show-detail .inbox-col { display: none; }
  .inbox.show-detail .inbox-detail { display: flex; }
  .inbox-back { display: inline-flex; }
}

/* ---------------------------------------------------------------- dialogs + toasts */
.dlg-backdrop { position: fixed; inset: 0; z-index: 100; background: rgba(6, 11, 24, 0.55); backdrop-filter: blur(3px); display: grid; place-items: center; padding: 16px; }
.dlg { background: var(--surface); color: var(--ink); width: min(580px, 100%); max-height: calc(100vh - 32px); border-radius: var(--radius); box-shadow: var(--shadow-lg); display: flex; flex-direction: column; }
.dlg-wide { width: min(920px, 100%); }
.dlg-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 22px 22px 12px 28px; }
.dlg-head h2 { font-size: 21px; }
.dlg-body { padding: 6px 28px 22px; overflow-y: auto; }
.dlg-actions { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 12px; padding: 16px 22px 20px; border-top: 1px solid var(--line-2); }
.skip-link { position: absolute; left: 16px; top: calc(8px + env(safe-area-inset-top, 0px)); z-index: 200; padding: 10px 16px; border-radius: var(--r-sm); border: 0; background: var(--gold); color: var(--gold-ink); font: 600 14px/1 var(--font); }
.skip-link:not(:focus) { clip-path: inset(50%); width: 1px; height: 1px; padding: 0; overflow: hidden; white-space: nowrap; }
.skip-link:focus { outline: 3px solid var(--brand); outline-offset: 2px; }
#toasts { position: fixed; right: 16px; bottom: calc(16px + env(safe-area-inset-bottom, 0px)); z-index: 120; display: flex; flex-direction: column; gap: 10px; max-width: min(380px, calc(100vw - 32px)); }
.toast { display: flex; gap: 10px; align-items: flex-start; background: #14213a; color: #e8edf6; padding: 13px 16px; border-radius: var(--radius); box-shadow: var(--shadow-lg); font-size: 15px; animation: toastIn 0.2s ease-out; border-left: 4px solid var(--gold); }
.toast-ok { border-left-color: #b4c7ea; }
.toast-error { border-left-color: #ff8f85; }
.toast.out { opacity: 0; transform: translateY(6px); transition: 0.25s; }
@keyframes toastIn { from { opacity: 0; transform: translateY(8px); } }

/* ---------------------------------------------------------------- pricing + pay */
.plans { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 22px; align-items: stretch; }
.plan-card { position: relative; display: flex; flex-direction: column; gap: 14px; padding: 32px 28px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); }
.plan-card.is-popular { border: 2px solid var(--gold); box-shadow: var(--shadow); }
.plan-card.plan-vip { background: var(--brand); color: #e8edf6; border-color: var(--brand); }
.plan-card.plan-vip .muted { color: rgba(232, 237, 246, 0.74); }
.plan-card.plan-vip .btn-primary { background: var(--gold); color: var(--gold-ink); }
.plan-card.plan-vip .ticks li::before { border-color: var(--gold); }
.plan-card .plan-price { font-size: 38px; line-height: 1.1; }
.plan-card .plan-price span { font-size: 15px; font-weight: 400; margin-left: 6px; opacity: 0.75; }
.plan-flag { position: absolute; top: -13px; left: 26px; background: var(--gold); color: var(--gold-ink); font-size: 12.5px; font-weight: 700; padding: 4px 12px; border-radius: var(--r-sm); }
.plan-card .ticks { margin-top: 6px; }
.is-current { cursor: default; }
@media (max-width: 900px) { .plans { grid-template-columns: minmax(0, 1fr); } }
.compare h2, .faq h2 { margin-bottom: 16px; }
.compare .yes { color: var(--navy); }
.compare .no { color: var(--ink-3); }
.faq details { border-bottom: 1px solid var(--line); padding: 18px 0; }
.faq summary { cursor: pointer; font-weight: 500; font-size: 17px; }
.faq details p { margin-top: 10px; color: var(--ink-2); max-width: 75ch; }
.pay { display: grid; grid-template-columns: 260px minmax(0, 1fr); gap: 28px; align-items: start; }
.pay-qr { display: flex; flex-direction: column; gap: 10px; }
.qr-box { background: #fff; border-radius: var(--radius); padding: 12px; border: 1px solid var(--line); display: grid; place-items: center; min-height: 240px; }
.qr-box img, .qr-box svg { width: 232px; height: 232px; display: block; }
.pay-what { font-weight: 500; }
.pay-amount { font-weight: 700; font-size: 32px; font-variant-numeric: tabular-nums; }
.pay-fields { margin: 0; display: flex; flex-direction: column; gap: 10px; }
.pay-fields > div { display: grid; grid-template-columns: 150px minmax(0, 1fr); gap: 12px; align-items: center; font-size: 15px; }
.pay-fields dt { color: var(--ink-3); }
.pay-fields dd { margin: 0; }
.pay-status { display: flex; gap: 8px; align-items: center; font-weight: 600; padding: 12px 14px; border-radius: var(--r-sm); background: var(--line-2); }
.pay-status.is-submitted { background: var(--gold-soft); color: var(--warn); }
.pay-status.is-paid { background: var(--navy-soft); color: var(--navy); }
.vnpay-box { display: flex; flex-direction: column; gap: 10px; padding: 16px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface-2); }
.or-line { display: flex; align-items: center; gap: 12px; margin: 2px 0 0; color: var(--ink-3); font-size: 13.5px; }
.or-line::before, .or-line::after { content: ""; flex: 1; height: 1px; background: var(--line); }
@media (max-width: 700px) { .pay { grid-template-columns: minmax(0, 1fr); } .pay-qr { align-items: center; } .pay-fields > div { grid-template-columns: minmax(0, 1fr); gap: 2px; } }

/* ---------------------------------------------------------------- admin */
.dl-editor { display: flex; flex-direction: column; gap: 10px; }
.dl-edit-row { display: grid; grid-template-columns: minmax(0, 1.4fr) 170px 150px 40px; gap: 10px; align-items: center; }
@media (max-width: 700px) { .dl-edit-row { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.team-editor { display: flex; flex-direction: column; gap: 10px; }
.team-edit-row { display: grid; grid-template-columns: minmax(0, 0.8fr) minmax(0, 1fr) minmax(0, 1.2fr) 40px; gap: 10px; align-items: center; }
@media (max-width: 700px) { .team-edit-row { grid-template-columns: minmax(0, 1fr) 40px; } .team-edit-row > input:nth-child(1) { grid-column: 1 / -1; } .team-edit-row > input:nth-child(2) { grid-column: 1 / -1; } }
.setup-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 12px; counter-reset: s; }
.setup-item { display: flex; gap: 16px; align-items: flex-start; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px 20px; }
.setup-item p { color: var(--ink-2); font-size: 15px; margin-top: 4px; white-space: pre-line; }
.setup-ic { width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center; flex: none; background: var(--line-2); color: var(--ink-2); }
.setup-item.is-ok .setup-ic { background: var(--navy-soft); color: var(--navy); }
.setup-item.is-todo .setup-ic { background: var(--gold-soft); color: var(--warn); }

/* ---------------------------------------------------------------- contact */
.grid-contact { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr); gap: 28px; align-items: start; }
@media (max-width: 860px) { .grid-contact { grid-template-columns: minmax(0, 1fr); } }
.contact-body { gap: 56px; }
.team-section { display: flex; flex-direction: column; gap: 24px; }
.team-lede { margin-top: 8px; }
/* five people: three, then two centred beneath (two per row on tablets, one per row on phones) */
.team-grid { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; justify-content: center; gap: 20px; }
.team-card { flex: 0 1 calc((100% - 40px) / 3); display: flex; gap: 14px; align-items: flex-start; padding: 24px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); min-width: 0; }
.team-info { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.team-role { font-size: 13.5px; font-weight: 600; letter-spacing: 0.02em; color: var(--ink-3); }
.team-name { font-size: 17.5px; font-weight: 600; color: var(--ink); line-height: 1.4; }
.team-mail { display: flex; align-items: flex-start; gap: 4px; margin-top: 8px; min-width: 0; font-size: 14px; }
.team-mail a { min-width: 0; padding-top: 2px; }
.team-card .avatar { width: 44px; height: 44px; font-size: 15px; }
.contact-note { max-width: 78ch; }
@media (max-width: 900px) { .team-card { flex-basis: calc((100% - 20px) / 2); } }
@media (max-width: 600px) { .team-card { flex-basis: 100%; } .contact-body { gap: 40px; } }
.prose { max-width: 78ch; }
.prose section { display: flex; flex-direction: column; gap: 12px; }
.prose h2 { font-size: 22px; margin-top: 12px; }
.prose p { color: var(--ink-2); }
.prose-dialog { display: flex; flex-direction: column; gap: 20px; }
.prose-dialog h3 { font-size: 17px; }

/* ---------------------------------------------------------------- news */
.news-list { display: flex; flex-direction: column; gap: 28px; }
.news-feature { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr); background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.news-feature-body { padding: 32px 36px; display: flex; flex-direction: column; gap: 14px; justify-content: center; }
.news-feature h2 { font-size: clamp(22px, 2.3vw, 30px); line-height: 1.3; }
.news-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 300px), 1fr)); gap: 20px; }
.news-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; display: flex; flex-direction: column; }
.news-card-body { padding: 20px 22px 24px; display: flex; flex-direction: column; gap: 10px; flex: 1; }
.news-card h3 { font-size: 18px; line-height: 1.4; }
.news-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 12px; font-size: 13.5px; color: var(--ink-3); }
.news-meta .badge { margin-left: 0; }
.news-cat { font-weight: 700; font-size: 12px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--navy); }
.news-sum { color: var(--ink-2); }
.news-card .news-sum { display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.news-link { color: var(--ink); text-decoration: none; }
.news-link::after { content: ""; position: absolute; inset: 0; }
.news-feature, .news-card { position: relative; transition: border-color 0.15s, box-shadow 0.15s; }
.news-feature:hover, .news-card:hover { border-color: var(--navy); box-shadow: var(--shadow); }
.news-feature:hover .news-link, .news-card:hover .news-link { color: var(--navy); }
.news-more { display: inline-flex; align-items: center; gap: 6px; font-weight: 600; color: var(--navy); font-size: 15px; }
.news-feature .edit-btn, .news-card .edit-btn, .news-feature .news-more { position: relative; z-index: 1; }
/* cover: the post's picture, or a navy plate with the topic mark and the day it was published */
.news-plate, .news-img { display: block; width: 100%; background: var(--brand); color: #fff; }
.news-img { object-fit: cover; }
.news-plate { position: relative; display: flex; flex-direction: column; justify-content: space-between; padding: 22px 24px;
  background-image: repeating-linear-gradient(135deg, rgba(255, 255, 255, 0.045) 0 1px, transparent 1px 14px); background-color: var(--brand); }
.news-plate[data-cat="admissions"] { border-bottom: 4px solid var(--gold); }
.news-plate[data-cat="event"] { background-color: #23406b; }
.news-plate[data-cat="tips"] { background-color: #2a3b52; }
.news-plate-ic { width: 46px; height: 46px; display: grid; place-items: center; border: 1px solid rgba(255, 255, 255, 0.28); border-radius: var(--r-sm); color: var(--gold); }
.news-plate-date { font-size: 34px; font-weight: 700; letter-spacing: 0.02em; font-variant-numeric: tabular-nums; line-height: 1; color: rgba(255, 255, 255, 0.92); align-self: flex-end; }
.news-plate.is-card, .news-img.is-card { aspect-ratio: 16 / 7; max-width: 100%; }
.news-plate.is-feature, .news-img.is-feature { height: 100%; min-height: 260px; }
.news-plate.is-feature .news-plate-date { font-size: 56px; }
.news-img.is-article { aspect-ratio: 16 / 8; max-width: 100%; border-radius: var(--radius); margin-block: 8px; }
@media (max-width: 760px) {
  .news-feature { grid-template-columns: minmax(0, 1fr); }
  .news-plate.is-feature, .news-img.is-feature { min-height: 0; aspect-ratio: 16 / 7; max-width: 100%; }
  .news-plate.is-feature .news-plate-date { font-size: 38px; }
  .news-feature-body { padding: 22px; }
}
.back-link { display: inline-flex; align-items: center; gap: 6px; font-size: 14.5px; font-weight: 600; color: var(--navy); text-decoration: none; }
.back-link:hover { text-decoration: underline; }
.article { max-width: 72ch; display: flex; flex-direction: column; gap: 18px; }
.article h1 { font-size: clamp(28px, 3.4vw, 40px); color: var(--navy); line-height: 1.25; }
.article-lede { font-size: 19px; color: var(--ink-2); line-height: 1.6; }
.article-body { display: flex; flex-direction: column; gap: 16px; font-size: 17px; line-height: 1.8; border-top: 1px solid var(--line); padding-top: 22px; }
.article-body ul { margin: 0; padding-left: 22px; display: flex; flex-direction: column; gap: 6px; }
.article-more { margin-top: 24px; display: flex; flex-direction: column; gap: 18px; border-top: 1px solid var(--line); padding-top: 32px; }
.article-more h2 { font-size: 22px; }

/* ---------------------------------------------------------------- university page */
.uni-rounds { list-style: none; margin: 0; padding: 0; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); }
.uni-round { display: grid; grid-template-columns: 150px minmax(0, 1fr) auto; gap: 16px; align-items: center; padding: 16px 20px; }
.uni-round + .uni-round { border-top: 1px solid var(--line-2); }
.uni-round.is-past { opacity: 0.55; }
.uni-round-date { font-weight: 600; font-size: 17px; color: var(--navy); font-variant-numeric: tabular-nums; }
.uni-round-name { font-weight: 500; }
@media (max-width: 560px) { .uni-round { grid-template-columns: minmax(0, 1fr) auto; } .uni-round-name { grid-column: 1 / -1; grid-row: 2; } }
.dl-title-link { color: inherit; text-decoration: none; }
.dl-title-link:hover { color: var(--navy); text-decoration: underline; }
.dl-more { font-weight: 600; }

/* ---------------------------------------------------------------- edit mode (admins) */
.edit-btn { display: inline-flex; align-items: center; gap: 5px; margin-left: auto; padding: 4px 10px; border: 1px dashed var(--gold); border-radius: var(--r-sm);
  background: var(--gold-soft); color: var(--ink); font-size: 13px; font-weight: 600; cursor: pointer; line-height: 1.4; }
.edit-btn:hover { background: var(--gold); color: var(--gold-ink); }
.person-top .edit-btn { align-self: flex-start; }
body.is-editing .listing, body.is-editing .person, body.is-editing .news-card, body.is-editing .news-feature, body.is-editing .uni-card, body.is-editing .dl-item { outline: 1px dashed rgba(251, 172, 25, 0.55); outline-offset: 3px; }
#edit-bar { position: fixed; left: 16px; bottom: calc(16px + env(safe-area-inset-bottom, 0px)); z-index: 60; display: flex; flex-wrap: wrap; align-items: center; gap: 8px 16px;
  max-width: calc(100% - 32px); padding: 10px 14px; background: var(--surface); color: var(--ink); border: 1px solid var(--line); border-left: 3px solid var(--gold); border-radius: var(--radius); box-shadow: var(--shadow-lg); font-size: 14px; }
.edit-switch { display: inline-flex; align-items: center; gap: 10px; cursor: pointer; position: relative; }
.edit-switch input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.edit-knob { width: 36px; height: 20px; border-radius: var(--r-sm); background: var(--line); position: relative; flex: none; transition: background 0.15s; }
.edit-knob::after { content: ""; position: absolute; top: 3px; left: 3px; width: 14px; height: 14px; border-radius: 0; background: #fff; box-shadow: 0 1px 2px rgba(0, 0, 0, 0.25); transition: transform 0.15s; }
.edit-switch input:checked + .edit-knob { background: var(--gold); }
.edit-switch input:checked + .edit-knob::after { transform: translateX(16px); }
.edit-switch input:focus-visible + .edit-knob { outline: 3px solid var(--gold); outline-offset: 2px; }
.edit-hint { color: var(--ink-2); font-size: 13.5px; }
.edit-dash { display: inline-flex; align-items: center; gap: 4px; font-weight: 600; color: var(--navy); text-decoration: none; }
.edit-dash:hover { text-decoration: underline; }
.multi-field { border: 1.5px solid var(--line); border-radius: var(--radius); padding: 12px 16px 16px; margin: 0; }
.multi-field legend { font-weight: 600; font-size: 15px; padding: 0 6px; }
.multi-check { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 190px), 1fr)); gap: 8px 16px; }
.texts-list { display: flex; flex-direction: column; gap: 12px; }
.text-row { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px; display: flex; flex-direction: column; gap: 10px; }
.text-row.is-changed { border-left: 3px solid var(--gold); }
.text-key { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.text-key code { font-size: 12.5px; color: var(--ink-3); overflow-wrap: anywhere; }
.text-row input, .text-row textarea { width: 100%; }

/* ---------------------------------------------------------------- activities with roles, awards */
.act-field, .award-field { display: flex; flex-direction: column; gap: 12px; }
.act-add { display: flex; gap: 10px; align-items: center; }
.act-add input { flex: 1; min-width: 0; }
.act-add .btn { flex: none; min-height: 48px; }
.act-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.act-list:empty { display: none; }
.act-row { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 250px) 32px; gap: 10px; align-items: center; padding: 8px 10px 8px 14px;
  background: var(--surface-2); border: 1px solid var(--line); border-left: 3px solid var(--navy); border-radius: var(--r-sm); }
.act-row.needs-role { border-left-color: var(--gold); background: var(--gold-soft); }
.act-row.needs-role select { border-color: var(--gold); }
.act-name { font-weight: 600; overflow-wrap: anywhere; }
.act-row select { min-height: 40px; padding-block: 7px; font-size: 15px; }
.act-desc { grid-column: 1 / -1; display: flex; flex-direction: column; gap: 4px; }
.act-desc textarea { min-height: 78px; font-size: 15px; line-height: 1.5; resize: vertical; }
.act-desc-foot { display: flex; gap: 10px; flex-wrap: wrap; align-items: baseline; justify-content: space-between; }
.act-desc-foot .hint { margin: 0; }
.act-count { margin-left: auto; font-size: 13px; color: var(--ink-3); font-variant-numeric: tabular-nums; white-space: nowrap; }
.act-count.is-over { color: var(--bad); font-weight: 600; }
.act-row.needs-desc { border-left-color: var(--gold); }
.act-row.needs-desc textarea { border-color: var(--gold); }
.role-choices { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.role-choices .chip { justify-content: flex-start; min-height: 44px; }
.award-list { display: flex; flex-direction: column; gap: 8px; }
.award-row { display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 1.1fr) minmax(0, 1.1fr) 76px 32px; gap: 8px; align-items: center; padding: 8px;
  background: var(--surface-2); border: 1px solid var(--line); border-left: 3px solid var(--navy); border-radius: var(--r-sm); }
.award-row.is-incomplete { border-left-color: var(--gold); background: var(--gold-soft); }
.award-row input, .award-row select { min-height: 40px; padding-block: 7px; font-size: 15px; }
@media (max-width: 760px) {
  .act-row { grid-template-columns: minmax(0, 1fr) 32px; }
  .act-row select { grid-column: 1 / -1; grid-row: 2; }
  .award-row { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) 32px; }
  .award-row > input:first-child { grid-column: 1 / -1; }
  .award-row > input[inputmode] { grid-column: 1 / 2; }
}
@media (max-width: 420px) { .role-choices { grid-template-columns: minmax(0, 1fr); } }
.bar-w { color: var(--ink-3); font-weight: 400; font-size: 13.5px; }
.cv-focus { display: flex; gap: 10px; align-items: flex-start; font-size: 15px; color: var(--ink-2); border-top: 1px solid var(--line-2); padding-top: 14px; }
.cv-focus > .ic { color: var(--navy); margin-top: 3px; }
.cv-focus strong { color: var(--ink); font-weight: 600; }
.school-weights { font-size: 13.5px; color: var(--ink-3); }
.weights-edit { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 10px; }
.weights-cell { display: flex !important; flex-direction: column; gap: 6px; font-size: 13.5px !important; margin: 0 !important; }
@media (max-width: 700px) { .weights-edit { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

/* ---------------------------------------------------------------- academic profile at a glance (student overview) */
.pf-card { gap: 18px; }
.pf-facts { margin: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1px; background: var(--line-2); border: 1px solid var(--line-2); border-radius: var(--r-sm); overflow: hidden; }
.pf-facts > div { background: var(--surface); padding: 12px 14px; min-width: 0; }
.pf-facts dt { font-size: 12px; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; color: var(--ink-3); }
.pf-facts dd { margin: 4px 0 0; font-weight: 600; font-size: 15px; line-height: 1.45; overflow-wrap: anywhere; }
.pf-facts dd.muted { font-weight: 400; }
.pf-row { display: grid; grid-template-columns: 110px minmax(0, 1fr); gap: 12px; align-items: start; }
.pf-label { font-size: 13.5px; font-weight: 600; color: var(--ink-3); padding-top: 5px; }
.pf-chips { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.pf-chip { display: inline-flex; align-items: baseline; gap: 6px; padding: 5px 10px; font-size: 14px; font-weight: 600; background: var(--navy-soft); color: var(--ink);
  border: 1px solid var(--line); border-radius: var(--r-sm); }
.pf-chip .ic { color: var(--gold); align-self: center; }
.pf-chip.is-award { background: var(--gold-soft); }
.pf-chip.is-missing { border-style: dashed; border-color: var(--gold); background: var(--surface); }
.pf-sub { font-weight: 400; font-size: 13px; color: var(--ink-2); }
.pf-more { font-size: 13.5px; color: var(--ink-3); font-weight: 600; }
.pf-warn { font-size: 14px; color: var(--warn); display: flex; align-items: center; gap: 4px; }
.pf-warn a { color: inherit; }
@media (max-width: 900px) { .pf-facts { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 520px) { .pf-row { grid-template-columns: minmax(0, 1fr); gap: 6px; } .pf-label { padding-top: 0; } }
.cv-load { display: flex; flex-wrap: wrap; gap: 12px 20px; align-items: center; justify-content: space-between; padding: 14px 16px; margin-bottom: 4px;
  background: var(--surface-2); border: 1px solid var(--line); border-left: 3px solid var(--navy); border-radius: var(--r-sm); }
.cv-load > div { flex: 1 1 260px; min-width: 0; }
.cv-facts { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px 18px; margin: 14px 0; padding: 14px 16px; border: 1px solid var(--line); border-radius: var(--r-sm); }
.cv-facts > div { min-width: 0; }
.cv-facts dt { font-size: 12px; color: var(--ink-3); text-transform: uppercase; letter-spacing: .04em; }
.cv-facts dd { margin: 2px 0 0; font-weight: 600; overflow-wrap: anywhere; }
.notice.is-warn { background: var(--warn-soft); border-left-color: var(--warn); margin: 0 0 14px; }
.notice.is-warn ul { margin: 6px 0 10px; padding-left: 18px; }

/* ---------------------------------------------------------------- footer */
#site-footer { background: var(--brand); color: rgba(232, 237, 246, 0.8); padding-block: 56px 28px; font-size: 15px; }
#site-footer .brand { color: #fff; }
.foot-in { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1.2fr) minmax(0, 1fr) minmax(0, 1fr); gap: 32px; }
.foot-brand p { margin-top: 14px; max-width: 34ch; }
.foot-h { color: #fff; font-weight: 600; margin-bottom: 12px; font-size: 15px; }
.foot-contact p { display: flex; gap: 8px; align-items: center; margin-bottom: 8px; }
.foot-nav { display: flex; flex-direction: column; gap: 9px; }
#site-footer a { color: rgba(232, 237, 246, 0.86); }
#site-footer a:hover { color: var(--gold); }
.foot-link { display: inline-block; margin-top: 8px; }
.foot-legal { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 10px; border-top: 1px solid rgba(232, 237, 246, 0.14); margin-top: 36px; padding-top: 20px; font-size: 13.5px; color: rgba(232, 237, 246, 0.62); }
@media (max-width: 860px) { .foot-in { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 520px) { .foot-in { grid-template-columns: minmax(0, 1fr); } }

/* ---------------------------------------------------------------- fees + section intros */
.fee-line { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 6px; color: var(--ink-2); }
.fee-line > .ic { color: var(--ink-3); }
.fee-line strong { color: var(--ink); font-weight: 600; font-variant-numeric: tabular-nums; }
.section-intro { display: flex; flex-direction: column; gap: 6px; max-width: 72ch; }
.section-intro h2 { font-size: clamp(22px, 2.4vw, 28px); }

/* ---------------------------------------------------------------- universities: cards, directory, search
   After U.S. News and CollegeVine: photo on top, the name, where it is, rank chips and the four numbers a
   student compares first. Until a photo is added (Admin → Universities) a navy plate with initials stands in. */
.uni-card { display: flex; flex-direction: column; overflow: hidden; transition: border-color 0.15s, box-shadow 0.15s; }
.uni-card:hover { border-color: color-mix(in srgb, var(--navy) 45%, var(--line)); box-shadow: var(--shadow); }
.uni-card-media { display: block; margin: 16px 16px 0; aspect-ratio: 1 / 1; max-width: 100%; background: var(--brand); overflow: hidden; border-radius: 0; }
.uni-card-media > *, .uni-hero-bg > *, .uni-hero-mark > *, .hs-thumb > * { width: 100%; height: 100%; }
.uni-img { display: block; object-fit: cover; }
.uni-ph { position: relative; display: grid; place-items: center; overflow: hidden; color: rgba(255, 255, 255, 0.92);
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.07), transparent 58%), var(--brand); }
.uni-ph::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 4px; background: var(--gold); }
.uni-ph span { font-weight: 700; font-size: clamp(22px, 3vw, 30px); letter-spacing: 0.08em; }
.uni-card-body { flex: 1; display: flex; flex-direction: column; gap: 8px; padding: 18px 20px 16px; }
.uni-card-body h3 { font-size: 19px; line-height: 1.35; text-wrap: balance; }
.uni-card-body h3 a { color: var(--ink); text-decoration: none; }
.uni-card-body h3 a:hover { color: var(--navy); text-decoration: underline; }
.uni-card-where { font-size: 14px; color: var(--ink-2); }
.uni-mini { margin: 6px 0 0; padding-top: 14px; border-top: 1px solid var(--line-2); display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 132px), 1fr)); gap: 14px 18px; }
.uni-mini > div { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.uni-mini dt { font-size: 12.5px; font-weight: 500; color: var(--ink-3); line-height: 1.4; }
.uni-mini dd { margin: 0; display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.uni-mini strong { font-size: 16.5px; font-weight: 700; line-height: 1.35; color: var(--ink); font-variant-numeric: tabular-nums; }
.uni-mini .is-empty strong { font-size: 14.5px; font-weight: 500; color: var(--ink-3); }
.um-sub { display: flex; flex-wrap: wrap; align-items: center; gap: 4px; font-size: 12.5px; color: var(--ink-3); line-height: 1.45; }
.uni-card-foot { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; padding: 12px 20px 14px; border-top: 1px solid var(--line-2); }
.uni-card-foot .btn-sm:not(.btn-link) { padding: 0 12px; font-size: 13.5px; }
.uni-card-foot .edit-btn { margin-left: 0; }
.uni-card-more { margin-left: auto; }
.uni-list { display: flex; flex-direction: column; gap: 16px; }
.uni-card.is-row { display: grid; grid-template-columns: 276px minmax(0, 1fr); grid-template-rows: 1fr auto; }
.uni-card.is-row .uni-card-media { grid-row: 1 / 3; align-self: stretch; margin: 16px 0 16px 16px; width: 260px; aspect-ratio: auto; height: auto; min-height: 260px; border-radius: 0; }
.uni-card.is-row .uni-card-foot { grid-column: 2; }
@media (max-width: 680px) {
  .uni-card.is-row { display: flex; }
  .uni-card.is-row .uni-card-media { width: auto; margin: 16px 16px 0; aspect-ratio: 1 / 1; min-height: 0; }
}
.search-panel { display: flex; flex-direction: column; gap: 14px; padding: 18px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); }
.search-panel .row select { width: auto; min-width: 210px; }
.search-big { display: flex; align-items: center; gap: 10px; margin: 0; padding: 0 14px; background: var(--surface); color: var(--ink-3); border: 1.5px solid var(--line); border-radius: var(--r-sm); }
.search-big:focus-within { border-color: var(--btn-bg); box-shadow: 0 0 0 3px color-mix(in srgb, var(--btn-bg) 18%, transparent); }
.search-big input[type="search"] { border: 0; box-shadow: none; background: transparent; padding-inline: 0; min-height: 52px; font-size: 17px; }
.search-big input[type="search"]:focus { box-shadow: none; }
.sort-label { display: inline-flex; align-items: center; gap: 8px; margin: 0; }
@media (max-width: 560px) { .search-panel { padding: 14px; } .search-panel .row > * { flex: 1 1 100%; } .search-panel .row select { width: 100%; min-width: 0; } .sort-label select { flex: 1; } }
/* header search (every page) */
.hdr-search { position: relative; }
.hs-btn { background: none; border: 0; cursor: pointer; }
.hs-panel { position: absolute; right: 0; top: calc(100% + 12px); z-index: 70; width: min(460px, calc(100vw - 32px)); display: flex; flex-direction: column; gap: 8px; padding: 12px;
  background: var(--surface); color: var(--ink); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow-lg); }
.hs-panel .search-big input[type="search"] { min-height: 46px; font-size: 16px; }
.hs-results { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; max-height: min(60vh, 440px); overflow-y: auto; }
.hs-item a { display: flex; align-items: center; gap: 12px; padding: 8px; border-radius: var(--r-sm); color: var(--ink); text-decoration: none; }
.hs-item a:hover, .hs-item.is-active a { background: var(--surface-2); }
.hs-thumb { flex: none; width: 58px; height: 40px; border-radius: var(--r-sm); overflow: hidden; background: var(--brand); }
.hs-thumb .uni-ph span { font-size: 12px; letter-spacing: 0.04em; }
.hs-thumb .uni-ph::after { height: 2px; }
.hs-txt { display: flex; flex-direction: column; min-width: 0; line-height: 1.4; }
.hs-txt strong { font-size: 15px; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hs-all a { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-top: 4px; padding: 10px 8px 4px; border-top: 1px solid var(--line-2);
  font-size: 14.5px; font-weight: 600; color: var(--navy); text-decoration: none; }
.hs-all a:hover { text-decoration: underline; }
.hs-hint { padding: 6px 8px; }
@media (max-width: 560px) { .hs-panel { position: fixed; left: 16px; right: 16px; top: calc(var(--hdr-h) + 8px + env(safe-area-inset-top, 0px)); width: auto; } }
/* rank chips: "#4 National Universities · 2027", "#16 QS 2027" */
.rank-chips { display: flex; flex-wrap: wrap; gap: 6px 8px; }
.rank-chip { display: inline-flex; flex-wrap: wrap; align-items: baseline; gap: 0 4px; padding: 3px 10px; font-size: 13px; line-height: 1.5; border-radius: var(--r-sm);
  background: var(--navy-soft); color: var(--navy); border: 1px solid color-mix(in srgb, var(--navy) 16%, transparent); }
.rank-chip strong { font-weight: 700; font-variant-numeric: tabular-nums; }
.rank-qs { background: var(--gold-soft); color: var(--warn); border-color: color-mix(in srgb, var(--gold) 45%, transparent); }
.rank-yr { opacity: 0.75; }

/* ---------------------------------------------------------------- university page (U.S. News-style profile) */
.uni-hero2 { position: relative; isolation: isolate; background: var(--surface); border-bottom: 1px solid var(--line); }
.uni-hero-in { position: relative; display: flex; flex-direction: column; gap: 18px; padding-block: 22px 28px; }
.uni-hero-top { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 18px 28px; }
.uni-hero-top .hero-actions { flex-wrap: wrap; }
/* photos: one large and one beside it, like U.S. News */
.ug-wrap { display: flex; flex-direction: column; gap: 8px; }
.ug { display: grid; gap: 8px; height: clamp(240px, 32vw, 440px); }
.ug-2 { grid-template-columns: minmax(0, 2fr) minmax(0, 1fr); }
.ug-1 { grid-template-columns: minmax(0, 1fr); height: clamp(220px, 28vw, 380px); }
.ug-tile { margin: 0; overflow: hidden; border-radius: var(--radius); background: var(--navy-soft); }
.ug-img { display: block; width: 100%; height: 100%; object-fit: cover; object-position: center 40%; }
.ug-credit { margin: 0; font-size: 11.5px; color: var(--ink-3); text-align: right; }
.ug-credit a { color: inherit; }
@media (max-width: 640px) { .ug-2 { grid-template-columns: 1fr; height: auto; } .ug-tile { aspect-ratio: 16 / 10; } }
.uni-hero2.has-photo { display: flex; flex-direction: column; justify-content: flex-end; min-height: clamp(360px, 44vw, 500px); background: #0c1628; color: #fff; border-bottom: 0; }
.uni-hero-bg { position: absolute; inset: 0; z-index: -1; overflow: hidden; }
.uni-hero-bg .uni-img { object-position: center 40%; }
.uni-hero-bg .uni-ph span { font-size: clamp(72px, 14vw, 180px); opacity: 0.16; }
.uni-hero-bg::after { content: ""; position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(5, 11, 24, 0.5) 0%, rgba(5, 11, 24, 0.12) 28%, rgba(5, 11, 24, 0.5) 60%, rgba(5, 11, 24, 0.9) 100%); }
.crumbs { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 8px; font-size: 13.5px; color: var(--ink-3); }
.crumbs a { color: var(--ink-2); text-decoration: none; }
.crumbs a:hover { color: var(--navy); text-decoration: underline; }
.crumbs .ic { opacity: 0.6; }
.has-photo .crumbs, .has-photo .crumbs a:hover { color: rgba(255, 255, 255, 0.75); }
.has-photo .crumbs a { color: #fff; }
.uni-hero-row { display: flex; align-items: center; gap: 20px; }
.uni-hero-mark { flex: none; width: 96px; height: 96px; overflow: hidden; border-radius: var(--radius); }
.uni-hero-text { display: flex; flex-direction: column; gap: 10px; min-width: 0; }
.uni-hero-text h1 { font-size: clamp(30px, 4.4vw, 50px); font-weight: 700; line-height: 1.12; letter-spacing: -0.01em; color: var(--navy); text-wrap: balance; }
.has-photo .uni-hero-text h1 { color: #fff; text-shadow: 0 2px 18px rgba(0, 0, 0, 0.35); }
.uni-where { display: flex; align-items: center; gap: 6px; font-size: 15.5px; font-weight: 500; color: var(--ink-2); }
.has-photo .uni-where { color: rgba(255, 255, 255, 0.9); }
.uni-hero-text .rank-chip { font-size: 14px; padding: 4px 12px; }
.has-photo .rank-chip { background: rgba(255, 255, 255, 0.14); color: #fff; border-color: rgba(255, 255, 255, 0.34); backdrop-filter: blur(6px); }
.has-photo .rank-qs { background: var(--gold); color: var(--gold-ink); border-color: var(--gold); }
.uni-hero2 .hero-actions { margin-top: 2px; gap: 10px; }
.uni-hero2 .hero-actions .btn { min-height: 44px; }
.has-photo .hero-actions .btn-outline { background: rgba(255, 255, 255, 0.08); border-color: rgba(255, 255, 255, 0.6); color: #fff; backdrop-filter: blur(6px); }
.has-photo .hero-actions .btn-outline:hover { background: rgba(255, 255, 255, 0.18); border-color: #fff; }
.photo-credit { align-self: flex-end; margin-top: -8px; font-size: 11.5px; color: var(--ink-3); text-decoration: none; }
.photo-credit:hover { text-decoration: underline; }
.has-photo .photo-credit { color: rgba(255, 255, 255, 0.62); }
@media (max-width: 560px) { .uni-hero-mark { width: 64px; height: 64px; } .uni-hero-row { align-items: flex-start; gap: 14px; } .uni-hero2 .hero-actions .btn { flex: 1 1 auto; } }
/* the section bar under the hero */
.subnav { position: sticky; top: calc(var(--hdr-h) + env(safe-area-inset-top, 0px)); z-index: 30; background: var(--hdr-bg); border-bottom: 1px solid var(--line); }
.subnav-in { display: flex; gap: 2px; overflow-x: auto; scrollbar-width: none; }
.subnav-in::-webkit-scrollbar { display: none; }
.subnav-link { flex: none; padding: 14px 12px 11px; font-size: 14.5px; font-weight: 600; color: var(--ink-2); text-decoration: none; white-space: nowrap; border-bottom: 3px solid transparent; }
.subnav-link:hover { color: var(--ink); }
.subnav-link.is-active { color: var(--navy); border-bottom-color: var(--gold); }
.uni-body { display: flex; flex-direction: column; gap: 48px; padding-block: 40px 88px; }
.u-sec { display: flex; flex-direction: column; gap: 22px; scroll-margin-top: calc(var(--hdr-h) + 72px); }
.u-sec + .u-sec { border-top: 1px solid var(--line); padding-top: 44px; }
.u-sec-title { font-size: clamp(24px, 2.6vw, 30px); font-weight: 700; color: var(--ink); }
.uni-body h3 { font-size: 18px; }
.uni-body .pill { align-self: flex-start; display: inline-flex; padding: 4px 10px; border: 0; font-size: 12.5px; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; background: var(--navy-soft); color: var(--navy); }
.uni-body .pill-gold { background: var(--gold-soft); color: var(--warn); }
.uni-body .card-pad { display: flex; flex-direction: column; gap: 14px; }
.uni-body .small .ic, .u-campus p .ic { color: var(--navy); vertical-align: -3px; }
.stack-lg { display: flex; flex-direction: column; gap: 40px; }
.stack-lg .row-between { margin-bottom: 14px; }
/* overview */
.u-overview { display: grid; grid-template-columns: minmax(0, 1.55fr) minmax(0, 1fr); gap: 28px; align-items: start; }
.u-overview.is-single { grid-template-columns: minmax(0, 1fr); }
.u-ov-main { display: flex; flex-direction: column; gap: 20px; min-width: 0; }
.u-intro { font-size: 17.5px; line-height: 1.75; max-width: 66ch; }
.tag-chips { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.tag-chips li { padding: 5px 12px; font-size: 14px; font-weight: 500; background: var(--surface-2); border: 1px solid var(--line); border-radius: var(--r-sm); }
.chance { display: flex; flex-direction: column; gap: 12px; padding: 20px 22px; background: var(--surface); border: 1px solid var(--line); border-left: 3px solid var(--gold); border-radius: var(--radius); }
.chance-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.chance-head h3 { display: flex; align-items: center; gap: 8px; font-size: 17px; }
.chance-head h3 .ic { color: var(--navy); }
.chance .fit { font-size: 14px; padding: 4px 12px; }
.glance { display: flex; flex-direction: column; gap: 14px; padding: 20px 22px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); }
.glance dl { margin: 0; display: flex; flex-direction: column; }
.glance dl > div { display: grid; grid-template-columns: minmax(0, 0.85fr) minmax(0, 1.3fr); gap: 12px; padding: 10px 0; border-top: 1px solid var(--line-2); font-size: 14.5px; }
.glance dl > div:first-child { border-top: 0; padding-top: 0; }
.glance dt { color: var(--ink-3); }
.glance dd { margin: 0; font-weight: 600; overflow-wrap: anywhere; }
.glance dd .muted { font-weight: 400; }
.glance-link { border-top: 1px solid var(--line-2); padding-top: 10px; }
@media (max-width: 860px) { .u-overview { grid-template-columns: minmax(0, 1fr); } }
/* rankings + number tiles */
.rank-tiles { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr)); gap: 16px; }
.rank-tile { display: flex; flex-direction: column; gap: 4px; padding: 22px 24px; background: var(--surface); border: 1px solid var(--line); border-top: 3px solid var(--navy); border-radius: var(--radius); }
.rank-tile:nth-child(2) { border-top-color: var(--gold); }
.rank-big { font-size: 44px; font-weight: 700; line-height: 1.05; color: var(--navy); font-variant-numeric: tabular-nums; }
.rank-what { font-size: 16px; font-weight: 600; }
.stat-tiles { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 200px), 1fr)); gap: 16px; }
.stat-tile { display: flex; flex-direction: column; gap: 4px; padding: 20px 22px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); }
.stat-big { font-size: 28px; font-weight: 700; line-height: 1.2; color: var(--navy); font-variant-numeric: tabular-nums; overflow-wrap: anywhere; }
.stat-tile .stat-l { font-size: 14px; color: var(--ink-2); }
.stat-sub { font-size: 14px; color: var(--ink-3); font-variant-numeric: tabular-nums; }
/* admissions: the six steps */
.u-admit, .u-cost { display: flex; flex-direction: column; gap: 22px; }
.u-cost { gap: 14px; }
.steps-box { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.steps-head { display: flex; flex-direction: column; gap: 4px; padding: 22px 26px 18px; background: var(--surface-2); border-bottom: 1px solid var(--line-2); }
.steps-head h3 { font-size: 20px; }
.u-steps { list-style: none; margin: 0; padding: 0; }
.u-step { display: grid; grid-template-columns: 40px minmax(0, 1fr); gap: 16px; padding: 22px 26px; }
.u-step + .u-step { border-top: 1px solid var(--line-2); }
.u-step-n { width: 34px; height: 34px; display: grid; place-items: center; border-radius: 50%; background: var(--btn-bg); color: var(--btn-fg); font-weight: 700; font-variant-numeric: tabular-nums; }
.u-step-body { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.u-step-body h4 { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; font-size: 17px; }
.u-step-body h4 .ic { color: var(--navy); }
.u-step-body p { color: var(--ink-2); line-height: 1.75; max-width: 80ch; }
.imp { display: inline-flex; align-items: center; padding: 3px 9px; font-size: 12px; font-weight: 700; letter-spacing: 0.04em; text-transform: uppercase; border-radius: var(--r-sm); }
.imp-very { background: var(--gold); color: var(--gold-ink); }
.imp-important { background: var(--navy-soft); color: var(--navy); }
.imp-considered { background: var(--line-2); color: var(--ink-2); }
@media (max-width: 560px) { .steps-head, .u-step { padding-inline: 18px; } .u-step { grid-template-columns: minmax(0, 1fr); gap: 10px; } }
.factors { display: flex; flex-direction: column; gap: 14px; }
.factor-cols { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr)); gap: 16px; align-items: start; }
.factor-col { display: flex; flex-direction: column; gap: 12px; padding: 18px 20px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); }
.factor-col .imp { align-self: flex-start; }
.factor-col ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; font-size: 15px; }
.factor-col li { position: relative; padding-left: 16px; }
.factor-col li::before { content: ""; position: absolute; left: 2px; top: 0.72em; width: 6px; height: 6px; border-radius: 50%; background: var(--ink-3); }
.req-list dt { font-size: 13px; font-weight: 700; letter-spacing: 0.04em; text-transform: uppercase; color: var(--ink-3); }
.req-list dd { margin: 4px 0 0; font-size: 15px; line-height: 1.65; }
/* majors, campus & life */
.rank-list { list-style: none; margin: 0; padding: 0; counter-reset: rk; display: flex; flex-direction: column; }
.rank-list li { counter-increment: rk; display: grid; grid-template-columns: 26px minmax(0, 1fr); gap: 10px; padding: 9px 0; border-top: 1px solid var(--line-2); font-size: 15px; }
.rank-list li:first-child { border-top: 0; padding-top: 0; }
.rank-list li::before { content: counter(rk); font-weight: 700; color: var(--navy); font-variant-numeric: tabular-nums; }
.u-campus { display: flex; flex-direction: column; overflow: hidden; }
.campus-fig { position: relative; margin: 0; aspect-ratio: 16 / 9; max-width: 100%; background: var(--surface-2); }
.campus-fig img { display: block; width: 100%; height: 100%; object-fit: cover; }
.campus-fig figcaption { position: absolute; right: 8px; bottom: 6px; font-size: 11.5px; }
.campus-fig figcaption a { color: #fff; text-decoration: none; text-shadow: 0 1px 3px rgba(0, 0, 0, 0.7); }
.life-bars { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 12px; }
.life-bars li { display: grid; grid-template-columns: 128px minmax(0, 1fr) 100px; gap: 12px; align-items: center; font-size: 15px; }
.life-bars li:last-child { padding-top: 12px; border-top: 1px solid var(--line-2); font-weight: 600; }
.life-bar { height: 10px; overflow: hidden; background: var(--line-2); border-radius: 0; }
.life-bar > span { display: block; height: 100%; background: var(--navy); border-radius: 0; }
.life-bars li:last-child .life-bar > span { background: var(--gold); }
.life-v { text-align: right; font-weight: 700; white-space: nowrap; font-variant-numeric: tabular-nums; }
.life-v .muted { font-size: 13px; font-weight: 400; }
.life-bars li.is-na .life-v { color: var(--ink-3); font-weight: 500; }
.life-bars li.is-na .life-bar { background: repeating-linear-gradient(135deg, var(--line-2) 0 6px, transparent 6px 12px); }
@media (max-width: 480px) { .life-bars li { grid-template-columns: minmax(0, 1fr) auto; row-gap: 6px; } .life-bar { grid-column: 1 / -1; grid-row: 2; } }
.u-similar .uni-grid { grid-template-columns: repeat(auto-fill, minmax(min(100%, 300px), 1fr)); }
.u-sources { border-top: 1px solid var(--line); padding-top: 20px; font-size: 13.5px; color: var(--ink-3); }
.u-sources a { margin-left: 3px; }
.u-sources p { margin-top: 8px; }

/* ---------------------------------------------------------------- chat ("Hỏi APPLYSPARK", bottom right) */
.chat { position: fixed; right: 16px; bottom: calc(16px + env(safe-area-inset-bottom, 0px)); z-index: 90; display: flex; flex-direction: column; align-items: flex-end; gap: 12px; pointer-events: none; }
.chat > * { pointer-events: auto; }
.chat-fab { display: inline-flex; align-items: center; gap: 10px; min-height: 52px; padding: 0 20px 0 16px; border: 0; border-radius: var(--radius); cursor: pointer;
  background: var(--btn-bg); color: var(--btn-fg); font: 600 15px/1.2 var(--font); box-shadow: var(--shadow-lg); }
.chat-fab:hover { background: var(--btn-bg-hover); }
.chat-fab .ic { color: var(--gold); }
.chat-panel { width: min(400px, calc(100vw - 32px)); height: min(620px, calc(100vh - 110px)); display: flex; flex-direction: column; overflow: hidden;
  background: var(--surface); color: var(--ink); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow-lg); }
.chat-head { display: flex; align-items: center; gap: 12px; padding: 12px 10px 12px 16px; background: var(--brand); color: #fff; }
.chat-head .icon-btn { margin-left: auto; color: rgba(255, 255, 255, 0.8); }
.chat-head .icon-btn:hover { background: rgba(255, 255, 255, 0.12); color: #fff; }
.chat-avatar { flex: none; width: 36px; height: 36px; display: grid; place-items: center; border-radius: var(--r-sm); background: rgba(255, 255, 255, 0.1); color: var(--gold); }
.chat-title { font-size: 15.5px; font-weight: 700; line-height: 1.3; }
.chat-sub { font-size: 12.5px; line-height: 1.4; color: rgba(232, 237, 246, 0.75); }
.chat-list { flex: 1; overflow-y: auto; overscroll-behavior: contain; display: flex; flex-direction: column; gap: 12px; padding: 16px; background: var(--bg); }
.msg { max-width: 88%; padding: 10px 14px; font-size: 14.5px; line-height: 1.6; border-radius: var(--radius); overflow-wrap: anywhere; }
.msg > * + * { margin-top: 8px; }
.msg ul, .msg ol { margin-bottom: 0; padding-left: 20px; display: flex; flex-direction: column; gap: 4px; }
.msg-h { font-weight: 700; }
.msg-assistant { align-self: flex-start; background: var(--surface); border: 1px solid var(--line); }
.msg-user { align-self: flex-end; background: var(--btn-bg); color: var(--btn-fg); white-space: pre-wrap; }
.msg-error { align-self: flex-start; display: flex; gap: 8px; align-items: flex-start; background: var(--bad-soft); color: var(--bad); border: 1px solid color-mix(in srgb, var(--bad) 30%, transparent); }
.msg-error > * + * { margin-top: 0; }
.msg-error .ic { margin-top: 4px; flex: none; }
.msg.is-typing { padding: 14px 16px; }
.dots { display: inline-flex; gap: 5px; }
.dots i { width: 7px; height: 7px; border-radius: 50%; background: var(--ink-3); animation: chatDot 1.2s infinite ease-in-out; }
.dots i:nth-child(2) { animation-delay: 0.15s; }
.dots i:nth-child(3) { animation-delay: 0.3s; }
@keyframes chatDot { 0%, 80%, 100% { opacity: 0.3; transform: none; } 40% { opacity: 1; transform: translateY(-3px); } }
.chat-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chat-chips .chip { padding: 6px 12px; font-size: 13.5px; text-align: left; white-space: normal; }
.chat-foot { display: flex; flex-direction: column; gap: 6px; padding: 10px 12px 12px; background: var(--surface); border-top: 1px solid var(--line); }
.chat-compose { display: flex; gap: 8px; align-items: flex-end; }
.chat-compose textarea { min-height: 44px; max-height: 140px; padding: 10px 12px; font-size: 15px; resize: none; }
.chat-send { flex: none; width: 44px; height: 44px; display: grid; place-items: center; border: 0; border-radius: var(--r-sm); background: var(--gold); color: var(--gold-ink); cursor: pointer; }
.chat-send:hover { background: var(--gold-2); }
.chat-send:disabled { opacity: 0.5; cursor: not-allowed; }
.chat-note { font-size: 11.5px; line-height: 1.45; color: var(--ink-3); }
.chat-login { display: flex; flex-direction: column; gap: 10px; padding: 14px 16px 16px; font-size: 14.5px; border-top: 1px solid var(--line); }
/* the chat sits above the fixed "My List" bar on pages that have one, and toasts sit above the chat */
#toasts { bottom: calc(84px + env(safe-area-inset-bottom, 0px)); }
@media (max-width: 1020px) {
  body[data-route="country"] .chat, body[data-route="deadlines"] .chat, body[data-route="unis"] .chat { bottom: calc(86px + env(safe-area-inset-bottom, 0px)); }
  body[data-route="unis"] #app { padding-bottom: 96px; }
  body[data-route="country"] #toasts, body[data-route="deadlines"] #toasts, body[data-route="unis"] #toasts { bottom: calc(156px + env(safe-area-inset-bottom, 0px)); }
}
@media (max-width: 560px) {
  .chat { right: 12px; bottom: calc(12px + env(safe-area-inset-bottom, 0px)); }
  .chat-fab { width: 54px; min-height: 54px; padding: 0; justify-content: center; }
  .chat-fab-l { display: none; }
  .chat.is-open .chat-fab { display: none; }
  .chat.is-open .chat-panel { position: fixed; inset: 0; width: auto; height: auto; border: 0; border-radius: 0; }
  .chat.is-open .chat-head { padding-top: calc(12px + env(safe-area-inset-top, 0px)); }
  .chat.is-open .chat-foot, .chat.is-open .chat-login { padding-bottom: calc(12px + env(safe-area-inset-bottom, 0px)); }
}

/* ---------------------------------------------------------------- profile analyzer (AI plan), plans not yet released, admin */
.ai-plans { gap: 16px; }
.ai-plan { display: flex; flex-direction: column; gap: 8px; padding: 16px 18px; background: var(--surface-2); border: 1px solid var(--line); border-radius: var(--radius); }
.ai-plan h3 { display: flex; align-items: center; gap: 8px; font-size: 16px; }
.ai-plan h3 .ic { color: var(--navy); }
.ai-plan p { font-size: 14.5px; line-height: 1.65; color: var(--ink-2); }
.ai-timeline { list-style: none; margin: 10px 0 0 6px; padding: 0; display: flex; flex-direction: column; border-left: 2px solid var(--line); }
.ai-timeline li { position: relative; display: grid; grid-template-columns: 150px minmax(0, 1fr); gap: 14px; padding: 8px 0 8px 18px; font-size: 15px; line-height: 1.6; }
.ai-timeline li::before { content: ""; position: absolute; left: -7px; top: 15px; width: 12px; height: 12px; border-radius: 50%; background: var(--gold); border: 2px solid var(--surface); }
.ai-when { font-size: 14px; font-weight: 700; color: var(--navy); }
@media (max-width: 560px) { .ai-timeline li { grid-template-columns: minmax(0, 1fr); gap: 2px; } }
.school-actions { display: flex; flex-direction: column; gap: 6px; padding-top: 10px; border-top: 1px solid var(--line-2); }
.school-actions .ticks li { font-size: 14.5px; }
.plans-soon { margin-bottom: 4px; }
.plan-card.is-soon > :not(.plan-flag) { opacity: 0.72; }
.plan-flag-soon { background: var(--surface); color: var(--ink-2); border: 1px solid var(--line); }
.badge-soon { background: transparent; color: var(--ink-3); border: 1px dashed var(--ink-3); }
.editor-heading { margin-top: 6px; padding-top: 14px; border-top: 1px solid var(--line); font-size: 15px; font-weight: 700; color: var(--navy); }

/* the header logo follows the theme */
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .hdr-bar .logo-on-light { display: none; }
  :root:not([data-theme="light"]) .hdr-bar .logo-on-dark { display: inline; }
}
:root[data-theme="dark"] .hdr-bar .logo-on-light { display: none; }
:root[data-theme="dark"] .hdr-bar .logo-on-dark { display: inline; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}

/* ---------- chance of admission, per school (CollegeVine-style) ---------- */
.ring-chance .ring-v { font-size: 30px; }
.ring-sm { width: 88px; height: 88px; }
.ring-fg.is-reach { stroke: var(--gold); }
.ring-fg.is-match { stroke: var(--navy-2); }
.ring-fg.is-likely { stroke: var(--navy); }
.ring-fg.is-closed, .ring-fg.is-none { stroke: var(--line); }
.ch-wrap { gap: 20px; }
.ch-tabs { display: flex; gap: 8px; overflow-x: auto; padding-bottom: 6px; margin-bottom: 2px; border-bottom: 1px solid var(--line-2); scrollbar-width: thin; }
.ch-tab { flex: none; display: inline-flex; align-items: center; gap: 10px; min-height: 44px; padding: 8px 14px; font: 600 15px var(--font); color: var(--ink-2);
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-sm); cursor: pointer; }
.ch-tab:hover { border-color: var(--navy-2); color: var(--ink); }
.ch-tab[aria-selected="true"] { color: var(--ink); border-color: var(--navy); background: var(--navy-soft); box-shadow: inset 0 -3px 0 var(--navy); }
.ch-pct { font-size: 13px; font-variant-numeric: tabular-nums; padding: 2px 8px; border-radius: 0; background: var(--line-2); color: var(--ink-2); }
.ch-pct.fit-reach { background: var(--gold-soft); color: var(--warn); }
.ch-pct.fit-match { background: var(--navy-soft); color: var(--navy); }
.ch-pct.fit-likely { background: var(--btn-bg); color: var(--btn-fg); }
.ch { display: flex; flex-direction: column; gap: 22px; }
.ch-head { display: flex; gap: 24px; align-items: flex-start; justify-content: space-between; flex-wrap: wrap; }
.ch-title { flex: 1 1 320px; min-width: 0; display: flex; flex-direction: column; gap: 6px; }
.ch-title .kicker { margin: 0; }
.ch-title h2 { font-size: clamp(21px, 2.4vw, 26px); line-height: 1.3; text-wrap: balance; }
.ch-title > p.muted { font-size: 14.5px; }
.ch-base { list-style: none; margin: 4px 0 0; padding: 0; display: flex; flex-direction: column; gap: 4px; font-size: 14.5px; color: var(--ink-2); line-height: 1.5; }
.ch-base li { padding-left: 14px; position: relative; }
.ch-base li::before { content: ""; position: absolute; left: 2px; top: 0.62em; width: 5px; height: 5px; border-radius: 50%; background: var(--gold); }
.ch-score { flex: none; display: flex; flex-direction: column; align-items: center; gap: 8px; text-align: center; max-width: 170px; }
.ch-score .fit { font-size: 14px; padding: 4px 12px; }
.ch-needs { padding: 14px 16px; background: var(--bad-soft); border-radius: var(--r-sm); }
.ch-needs li > .ic { color: var(--bad) !important; }
.ch-ai { display: flex; flex-direction: column; gap: 10px; padding: 16px 18px; background: var(--navy-soft); border-radius: var(--radius); font-size: 15px; line-height: 1.6; }
.ch-ai > p:first-child { display: flex; gap: 8px; align-items: flex-start; }
.ch-ai .ic { color: var(--gold); margin-top: 3px; flex: none; }
.ch-ai.is-pending { flex-direction: row; align-items: center; color: var(--ink-2); font-size: 14.5px; }
.ch-phase { display: flex; flex-direction: column; gap: 12px; padding-top: 18px; border-top: 1px solid var(--line-2); }
.ch-phase > h3 { display: flex; align-items: center; gap: 10px; font-size: 18px; }
.ch-phase-n { display: inline-grid; place-items: center; width: 26px; height: 26px; border-radius: 50%; background: var(--btn-bg); color: var(--btn-fg); font-size: 13.5px; font-weight: 700; flex: none; }
.parts { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 360px), 1fr)); gap: 12px; }
.part { display: flex; flex-direction: column; gap: 8px; padding: 14px 16px; background: var(--surface-2); border: 1px solid var(--line); border-radius: var(--r-sm); min-width: 0; }
.part.is-below, .part.is-missing { border-left: 3px solid var(--gold); }
.part.is-above { border-left: 3px solid var(--navy); }
.part-top { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.part-name { display: inline-flex; align-items: center; gap: 7px; font-weight: 700; font-size: 15.5px; margin-right: auto; }
.part-name .ic { color: var(--navy); }
.part-vs { margin: 0; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 10px; }
.part-vs dt { font-size: 12.5px; color: var(--ink-3); letter-spacing: 0.02em; }
.part-vs dd { margin: 2px 0 0; font-weight: 600; font-size: 14.5px; line-height: 1.45; overflow-wrap: anywhere; font-variant-numeric: tabular-nums; }
.part-note { font-size: 13.5px; color: var(--ink-2); line-height: 1.55; }
@media (max-width: 480px) { .part-vs { grid-template-columns: minmax(0, 1fr); gap: 6px; } .ch-score { flex-direction: row; flex-wrap: wrap; max-width: none; text-align: left; } }
.lvl { font-size: 12px; font-weight: 700; padding: 3px 8px; border-radius: var(--r-sm); white-space: nowrap; border: 1.5px solid transparent; }
.lvl-above { background: var(--btn-bg); color: var(--btn-fg); }
.lvl-average { background: var(--navy-soft); color: var(--navy); }
.lvl-met { background: var(--navy-soft); color: var(--navy); }
.lvl-below { background: var(--bad-soft); color: var(--bad); }
.lvl-missing { border-color: var(--gold); color: var(--warn); }
.lvl-optional, .lvl-na { background: var(--line-2); color: var(--ink-3); }
.imp-minor { background: transparent; color: var(--ink-3); border: 1px solid var(--line); }
.part .imp { font-size: 10.5px; padding: 2px 7px; }
.cmp { position: relative; height: 8px; border-radius: 0; background: var(--line); margin: 6px 4px 2px; }
.cmp-band { position: absolute; top: 0; bottom: 0; border-radius: 0; background: color-mix(in srgb, var(--navy) 38%, transparent); }
.cmp-band.is-mark { width: 3px !important; margin-left: -1.5px; top: -4px; bottom: -4px; border-radius: 0; background: var(--navy); }
.cmp-you { position: absolute; top: 50%; width: 16px; height: 16px; margin: -8px 0 0 -8px; border-radius: 50%; background: var(--gold); border: 3px solid var(--surface-2); box-shadow: 0 0 0 1px var(--gold); }
.cmp-legend { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; font-size: 13px; color: var(--ink-3); }
.cmp-legend .key-you { width: 12px; height: 12px; border-radius: 50%; background: var(--gold); }
.cmp-legend .key-typ { width: 22px; height: 8px; border-radius: 0; background: color-mix(in srgb, var(--navy) 38%, transparent); margin-left: 10px; }
.tiers { display: flex; flex-direction: column; gap: 8px; }
.tier-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; border: 1px solid var(--line); border-radius: var(--r-sm); background: var(--surface); }
.tier-list > li { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 14px; align-items: center; padding: 12px 14px; border-top: 1px solid var(--line-2); }
.tier-list > li:first-child { border-top: 0; }
.tier-name { font-weight: 600; font-size: 15px; overflow-wrap: anywhere; }
.tier-name .muted { font-weight: 400; }
.tier-why { font-size: 14px; color: var(--ink-2); line-height: 1.55; margin-top: 2px; }
.tier-why .ic { color: var(--gold); margin-right: 4px; vertical-align: -2px; }
.tier-desc { font-size: 13.5px; color: var(--ink-3); line-height: 1.5; margin-top: 2px; }
.tier-side { display: flex; flex-direction: column; align-items: flex-end; gap: 6px; }
.tier-badge { font-size: 12.5px; font-weight: 700; padding: 3px 9px; border-radius: var(--r-sm); white-space: nowrap; background: var(--line-2); color: var(--ink-2); }
.tier-1 { background: var(--gold); color: var(--gold-ink); }
.tier-2 { background: var(--btn-bg); color: var(--btn-fg); }
.tier-3 { background: var(--navy-soft); color: var(--navy); }
.tier-meter { display: inline-flex; gap: 3px; }
.tier-meter > span { width: 14px; height: 7px; border-radius: 0; background: var(--line); }
.tier-meter > span.on { background: var(--navy); }
.ch-how { border: 1px solid var(--line); border-radius: var(--r-sm); padding: 12px 16px; background: var(--surface); }
.ch-how > summary { cursor: pointer; font-weight: 600; font-size: 15px; color: var(--navy); }
.ch-how[open] > summary { margin-bottom: 12px; }
.ch-how .ticks li { font-size: 14.5px; }
.road-card { gap: 14px; }
.road-head { display: flex; gap: 18px; justify-content: space-between; align-items: flex-start; flex-wrap: wrap; }
.road-head > div { flex: 1 1 300px; min-width: 0; display: flex; flex-direction: column; gap: 6px; }
.road-months { flex: none; display: flex; flex-direction: column; align-items: center; padding: 10px 16px; border-radius: var(--radius); background: var(--gold-soft); color: var(--warn); line-height: 1.2; }
.road-months strong { font-size: 30px; color: var(--ink); font-variant-numeric: tabular-nums; }
.road-months span { font-size: 13px; }
.road { list-style: none; margin: 4px 0 0 6px; padding: 0; display: flex; flex-direction: column; border-left: 2px solid var(--line); }
.road > li { position: relative; display: grid; grid-template-columns: 150px minmax(0, 1fr); gap: 14px; padding: 9px 0 9px 18px; font-size: 15px; line-height: 1.6; }
.road > li::before { content: ""; position: absolute; left: -7px; top: 16px; width: 12px; height: 12px; border-radius: 50%; background: var(--navy); border: 2px solid var(--surface); }
.road > li.is-urgent::before { background: var(--bad); }
.road > li.is-deadline::before { background: var(--gold); }
.road-when { font-weight: 700; color: var(--navy); display: inline-flex; gap: 6px; align-items: flex-start; }
.road > li.is-urgent .road-when { color: var(--bad); }
.road-when .ic { margin-top: 4px; }
.road-what ul { margin: 0; padding-left: 18px; display: flex; flex-direction: column; gap: 6px; }
.road > li.is-deadline .road-what { font-weight: 600; }
@media (max-width: 560px) { .road > li { grid-template-columns: minmax(0, 1fr); gap: 2px; } }
.chance-top { display: flex; gap: 16px; align-items: center; }
.chance-txt { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 4px; }
.chance-txt .chance-head { flex-wrap: wrap; }
.part-mini { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 230px), 1fr)); gap: 6px 16px; }
.part-mini li { display: flex; align-items: center; gap: 8px; justify-content: space-between; padding: 7px 0; border-top: 1px solid var(--line-2); font-size: 14.5px; }
.part-mini .part-name { font-weight: 600; font-size: 14.5px; margin: 0; }
@media (max-width: 480px) { .chance-top { align-items: flex-start; } .ring-sm { width: 72px; height: 72px; } }

/* ---------- scholarships on a university page ---------- */
.u-schol { display: flex; flex-direction: column; gap: 16px; }
.schol-sum { display: flex; gap: 10px; align-items: flex-start; padding: 14px 16px; border-radius: var(--radius); background: var(--navy-soft); font-size: 15px; line-height: 1.6; }
.schol-sum .ic { color: var(--navy); margin-top: 3px; }
.schol-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 340px), 1fr)); gap: 16px; }
.schol:only-child { max-width: 780px; }
.schol { display: flex; flex-direction: column; gap: 12px; padding: 20px 22px; background: var(--surface); border: 1px solid var(--line); border-top: 3px solid var(--gold); border-radius: var(--radius); }
.schol.is-none { border-top-color: var(--line); background: var(--surface-2); }
.schol-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; }
.schol-head h3 { font-size: 17.5px; line-height: 1.35; }
@media (max-width: 480px) { .schol-head { flex-direction: column; gap: 8px; } }
.schol-type { font-size: 12.5px; font-weight: 700; letter-spacing: 0.04em; text-transform: uppercase; color: var(--warn); margin-bottom: 4px; }
.schol.is-none .schol-type { color: var(--ink-3); }
.schol-amount { font-size: 15.5px; font-weight: 600; color: var(--ink); line-height: 1.55; }
.schol-facts { margin: 0; display: flex; flex-direction: column; }
.schol-facts > div { display: grid; grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.4fr); gap: 12px; padding: 8px 0; border-top: 1px solid var(--line-2); font-size: 14.5px; }
.schol-facts dt { color: var(--ink-3); }
.schol-facts dd { margin: 0; font-weight: 600; overflow-wrap: anywhere; }
.schol-facts dd .muted { font-weight: 400; }
.elig { flex: none; font-size: 12.5px; font-weight: 700; padding: 4px 10px; border-radius: var(--r-sm); white-space: nowrap; }
.elig-yes { background: var(--btn-bg); color: var(--btn-fg); }
.elig-maybe { background: var(--gold-soft); color: var(--warn); }
.elig-no { background: var(--bad-soft); color: var(--bad); }
.schol-elig { display: flex; flex-direction: column; gap: 6px; }
.elig-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; }
.elig-list li { display: flex; gap: 8px; align-items: flex-start; font-size: 14.5px; line-height: 1.5; }
.elig-list li > .ic { margin-top: 2px; flex: none; color: var(--ink-3); }
.elig-list li.is-ok > .ic { color: var(--navy); }
.elig-list li.is-no > .ic { color: var(--bad); }
.elig-list li.is-unknown > .ic { color: var(--warn); }
.schol-how { line-height: 1.6; color: var(--ink-2); }

/* ---------- admin: university page data widgets ---------- */
.ic.flip-v svg { transform: rotate(180deg); }
.multi-field > .hint { margin: 0 0 10px; }
.fac-editor { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 260px), 1fr)); gap: 8px 16px; }
.fac-row { display: grid; grid-template-columns: minmax(0, 1fr) 150px; gap: 8px; align-items: center; font-size: 14.5px; }
.fac-row select { min-height: 38px; padding-block: 6px; font-size: 14px; }
.mr-editor { display: flex; flex-direction: column; gap: 12px; }
.mr-row { display: flex; flex-direction: column; gap: 8px; padding: 12px 14px; border: 1px solid var(--line); border-radius: var(--r-sm); background: var(--surface-2); }
.mr-field { font-weight: 700; color: var(--navy); }
.mr-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 170px), 1fr)); gap: 8px 12px; }
.mr-cell, .sch-cell { display: flex; flex-direction: column; gap: 4px; font-size: 13px; color: var(--ink-2); min-width: 0; }
.mr-cell input, .mr-cell select, .sch-cell input, .sch-cell select, .sch-cell textarea { min-height: 38px; padding-block: 6px; font-size: 14.5px; color: var(--ink); }
.sch-editor { display: flex; flex-direction: column; gap: 14px; }
.sch-editor > .btn, .elig-edits > .btn { align-self: flex-start; }
.sch-card { display: flex; flex-direction: column; gap: 12px; padding: 14px 16px; border: 1px solid var(--line); border-top: 3px solid var(--gold); border-radius: var(--r-sm); background: var(--surface-2); }
.sch-card-head { display: flex; justify-content: space-between; align-items: center; gap: 10px; }
.sch-card-head strong { overflow-wrap: anywhere; }
.sch-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px 14px; }
.sch-elig { display: flex; flex-direction: column; gap: 8px; }
.elig-edits { display: flex; flex-direction: column; gap: 8px; align-items: flex-start; }
.elig-edit { width: 100%; display: grid; grid-template-columns: 190px minmax(0, 0.8fr) minmax(0, 1fr) minmax(0, 1fr) 40px; gap: 8px; align-items: center; }
.elig-edit input, .elig-edit select { min-height: 38px; padding-block: 6px; font-size: 14px; }
.multi-check.sm { grid-template-columns: repeat(auto-fill, minmax(min(100%, 120px), 1fr)); gap: 4px 10px; font-size: 13.5px; }
@media (max-width: 760px) {
  .sch-grid { grid-template-columns: minmax(0, 1fr); }
  .elig-edit { grid-template-columns: minmax(0, 1fr) 40px; }
  .elig-edit > :not(button) { grid-column: 1 / 2; }
  .elig-edit > button { grid-column: 2; grid-row: 1; }
}

.vn-box { display: flex; flex-direction: column; gap: 10px; padding: 18px 20px; background: var(--navy-soft); border-radius: var(--radius); border-left: 3px solid var(--navy); }
.vn-box h3 { display: flex; align-items: center; gap: 8px; font-size: 17px; }
.vn-box h3 .ic { color: var(--navy); }
.vn-box p { font-size: 15px; line-height: 1.65; max-width: 75ch; }
.vn-box .tag-chips li { background: var(--surface); }

/* ---------- "back to home" bar on every page but the home page ---------- */
.home-bar { background: var(--bg); border-bottom: 1px solid var(--line-2); }
.home-bar .wrap { display: flex; align-items: center; min-height: 44px; }
.home-link { display: inline-flex; align-items: center; gap: 6px; padding: 6px 0; font-size: 14.5px; font-weight: 600; color: var(--ink-2); text-decoration: none; }
.home-link:hover, .home-link:focus-visible { color: var(--navy); text-decoration: underline; text-underline-offset: 3px; }
.home-link .ic { transition: transform .15s ease; }
.home-link:hover .ic { transform: translateX(-2px); }

/* ---------- scholarships page ---------- */
.schol-filters { display: flex; flex-direction: column; gap: 12px; }
.schol-search { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 220px) minmax(0, 200px); gap: 10px; align-items: center; }
.schol-search input, .schol-search select { min-height: 46px; max-width: none !important; width: 100%; }
@media (max-width: 760px) { .schol-search { grid-template-columns: minmax(0, 1fr); } }
.schol-count { font-weight: 700; font-size: 17px; margin-top: 6px; }
.schol-finder { margin-top: 4px; }
.schol-uni { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; font-size: 14px; margin-top: 3px; }
.schol-uni .ic { color: var(--navy); }
.schol-uni a { font-weight: 600; }
.schol-links { flex-wrap: wrap; gap: 8px; margin-top: auto; padding-top: 4px; }
.schol.is-ext { border-top-color: var(--navy); }
.schol.is-ext .schol-type { color: var(--navy); }

/* ---- full-screen loader: gradient ring (navy → gold, the logo's colours) around the logo ---- */
@property --al-a { syntax: "<angle>"; inherits: false; initial-value: 0deg; }
.app-loader { position: fixed; inset: 0; z-index: 3000; display: grid; place-items: center; background: color-mix(in srgb, var(--bg) 88%, transparent); backdrop-filter: blur(3px);
  opacity: 0; visibility: hidden; transition: opacity 0.25s ease, visibility 0.25s; pointer-events: none; }
.app-loader.is-on, .app-loader.is-boot { opacity: 1; visibility: visible; pointer-events: auto; }
.app-loader.is-boot { background: var(--bg, #f8f6f1); backdrop-filter: none; }
.al-ring { position: relative; width: 108px; height: 108px; display: grid; place-items: center; }
.al-ring::before { content: ""; position: absolute; inset: 0; border-radius: 50%;
  background: conic-gradient(from var(--al-a), rgba(26, 48, 84, 0) 0deg, #2a4671 120deg, #1a3054 200deg, #fbac19 320deg, #ffbf45 360deg);
  -webkit-mask: radial-gradient(farthest-side, transparent calc(100% - 6px), #000 calc(100% - 5px));
  mask: radial-gradient(farthest-side, transparent calc(100% - 6px), #000 calc(100% - 5px));
  animation: al-spin 1.1s linear infinite; }
.al-ring img { width: 46px; height: auto; animation: al-pulse 1.6s ease-in-out infinite; }
@keyframes al-spin { to { --al-a: 360deg; } }
@keyframes al-pulse { 50% { transform: scale(0.9); opacity: 0.8; } }
@supports not (background: conic-gradient(from 1turn at 50% 50%, red, blue)) { .al-ring::before { background: linear-gradient(135deg, #1a3054, #fbac19); } }
@media (prefers-reduced-motion: reduce) { .al-ring::before { animation-duration: 3s; } .al-ring img { animation: none; } }
:root[data-theme="dark"] .al-ring::before { background: conic-gradient(from var(--al-a), rgba(251, 172, 25, 0) 0deg, #5b86c4 140deg, #8fb2e6 220deg, #fbac19 330deg, #ffbf45 360deg); }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .al-ring::before { background: conic-gradient(from var(--al-a), rgba(251, 172, 25, 0) 0deg, #5b86c4 140deg, #8fb2e6 220deg, #fbac19 330deg, #ffbf45 360deg); } }

/* ---- courses field, comparison-bar axis, draft note ---- */
.courses { display: grid; gap: 10px; }
.course-list { display: grid; gap: 8px; }
.course-row { display: grid; grid-template-columns: minmax(0, 2fr) minmax(110px, 0.9fr) minmax(90px, 0.8fr) auto auto; gap: 8px; align-items: center; }
.course-row input[type="text"], .course-row select { width: 100%; min-width: 0; }
.course-pred { white-space: nowrap; font-size: 13px; }
@media (max-width: 720px) { .course-row { grid-template-columns: 1fr 1fr; } .course-row > :first-child { grid-column: 1 / -1; } }
.cmp-wrap { display: grid; gap: 4px; }
.cmp-axis { display: flex; justify-content: space-between; align-items: center; gap: 8px; font-size: 11.5px; color: var(--ink-3); font-variant-numeric: tabular-nums; }
.cmp-dir { text-align: center; flex: 1; }
.draft-note { display: flex; flex-wrap: wrap; align-items: center; gap: 4px; }

/* =====================================================================
   US NEWS-STYLE PASS (2026-10) — flat, square-cornered, white and grey, strong headings, photo heroes.
   Appended last so it refines the rules above; round shapes are kept only where they are really round
   (avatars, dots, spinner, the globe). Everything else has square corners.
   ===================================================================== */
:root {
  --radius: 0;
  --r-sm: 0;
  --bg: #ffffff;
  --surface: #ffffff;
  --surface-2: #f3f5f8;
  --line: #d5dae2;
  --line-2: #e6e9ee;
  --shadow: 0 1px 2px rgba(16, 28, 52, 0.06);
  --shadow-lg: 0 24px 48px -24px rgba(10, 18, 36, 0.4);
  --veil: 10, 20, 40;
}
body { text-rendering: optimizeLegibility; }
h1, h2, h3 { letter-spacing: -0.01em; font-weight: 700; }
::selection { background: var(--gold); color: var(--gold-ink); }
.section-alt { background: var(--surface-2); }

/* header: plain white bar, thin rule underneath */
.hdr-bar { background: var(--hdr-bg); border-bottom: 1px solid var(--line); box-shadow: none; -webkit-backdrop-filter: none; backdrop-filter: none; }
.nav-link { font-weight: 600; font-size: 14.5px; }
.nav-link.is-active { box-shadow: inset 0 -3px 0 var(--gold); border-radius: 0; }

/* buttons: flat, square, bold */
.btn { border-radius: 0; font-weight: 700; transition: background-color 0.15s, border-color 0.15s, color 0.15s; }
.btn:hover, .btn:active { transform: none; }
.btn-gold, .btn-gold:hover { box-shadow: none; }

/* cards: flat with a thin rule; the border darkens on hover */
.card, .listing, .person, .news-card, .dl-item, .uni-card { border-radius: 0; box-shadow: none; transition: border-color 0.15s; }
.uni-card:hover, .news-card:hover, .listing:hover, .person:hover, .dl-item:hover { transform: none; box-shadow: none; border-color: var(--navy); }

/* section titles: a short gold bar above, capitals, like U.S. News */
.section-head h2, .section-intro h2, .u-sec-title { position: relative; padding-top: 16px; font-size: clamp(20px, 2vw, 25px); text-transform: uppercase; letter-spacing: 0.02em; font-weight: 700; }
.section-head h2::before, .section-intro h2::before, .u-sec-title::before { content: ""; position: absolute; left: 0; top: 0; width: 44px; height: 4px; background: var(--gold); }

/* ---- photo hero behind every page title (Hạn nộp … Liên hệ): centred, like U.S. News ---- */
body:has(.page-hero) .home-bar { position: relative; z-index: 3; height: 0; background: transparent; border: 0; overflow: visible; }
body:has(.page-hero) .home-bar .wrap { position: absolute; left: 50%; top: 16px; transform: translateX(-50%); display: block; min-height: 0; }
body:has(.page-hero) .home-link { padding: 7px 14px 7px 10px; font-size: 12.5px; font-weight: 700; letter-spacing: 0.05em; text-transform: uppercase; color: #fff; background: rgba(10, 20, 40, 0.45); border: 1px solid rgba(255, 255, 255, 0.5); border-radius: 0; }
body:has(.page-hero) .home-link:hover, body:has(.page-hero) .home-link:focus-visible { color: #fff; background: rgba(10, 20, 40, 0.7); text-decoration: none; }
.page-hero { position: relative; isolation: isolate; overflow: hidden; display: flex; flex-direction: column; justify-content: center; align-items: center; text-align: center;
  min-height: clamp(300px, 30vw, 400px); padding-block: 72px 56px; color: #fff; border-bottom: 0;
  background: radial-gradient(120% 140% at 85% 0%, #2a4a7d, #122745 60%); }
.page-hero .hero-in { display: flex; flex-direction: column; align-items: center; width: min(var(--wrap), 100% - 32px); margin-inline: auto; }
.page-hero .hero-media { position: absolute; inset: 0; z-index: -2; }
.page-hero .hero-media img { display: block; width: 100%; height: 100%; object-fit: cover; object-position: center 25%; }
.page-hero::before { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(180deg, rgba(var(--veil), 0.5), rgba(var(--veil), 0.62)); }
.page-hero:not(.has-photo)::before { background: none; }
.page-hero::after { content: none; }
.page-hero h1 { margin: 0; color: #fff; font-size: clamp(32px, 4.8vw, 54px); font-weight: 700; line-height: 1.15; max-width: 22ch; text-shadow: 0 2px 20px rgba(0, 0, 0, 0.45); }
.page-hero h1::after { content: ""; display: block; width: 56px; height: 4px; margin: 18px auto 0; background: var(--gold); }
.page-hero .lede { margin: 18px auto 0; max-width: 62ch; font-size: clamp(16px, 1.6vw, 19px); font-weight: 600; color: #fff; text-shadow: 0 1px 12px rgba(0, 0, 0, 0.55); }
.page-hero .hero-actions { justify-content: center; margin-top: 26px; }
.page-hero .btn-outline, .page-hero .btn-ghost { color: #fff; background: rgba(10, 20, 40, 0.35); border-color: rgba(255, 255, 255, 0.7); }
.page-hero .btn-outline:hover, .page-hero .btn-ghost:hover { background: rgba(255, 255, 255, 0.2); color: #fff; }
.page-hero .edit-btn { color: var(--ink); }
.hero-credit { position: absolute; right: 16px; bottom: 10px; margin: 0; max-width: calc(100% - 32px); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-size: 11.5px; color: rgba(255, 255, 255, 0.78); text-align: right; }
.hero-credit a { color: inherit; }
@media (max-width: 760px) { .page-hero { min-height: 280px; padding-block: 64px 40px; } .hero-credit { display: none; } }

/* ---- university cards: a steady square-cornered photo ---- */
.uni-card-media { position: relative; margin: 0; aspect-ratio: 16 / 10; border-radius: 0; background: var(--brand); }
.uni-card-media > .uni-img, .uni-card-media > .uni-ph { position: absolute; inset: 0; width: 100%; height: 100%; }
.uni-card-media > .uni-img { object-fit: cover; }
.uni-card.is-row .uni-card-media { margin: 0; width: auto; min-height: 0; aspect-ratio: auto; border-radius: 0; }
.uni-card.is-row { grid-template-columns: 300px minmax(0, 1fr); }
@media (max-width: 680px) { .uni-card.is-row .uni-card-media { margin: 0; aspect-ratio: 16 / 10; border-radius: 0; } }
.uni-card-body h3 { font-size: 20px; font-weight: 700; }
.rank-chip { border-radius: 0; padding: 3px 10px; font-weight: 600; }

/* ---- footer: flat navy ---- */
#site-footer { background: #142846; border-top: 4px solid var(--gold); padding-block: 56px 28px; }

/* ---- admin edit bar: compact on phones ---- */
@media (max-width: 560px) { #edit-bar { padding: 8px 12px; gap: 6px 12px; } #edit-bar .edit-hint { display: none; } }

.avatar .ic { width: 26px; height: 26px; }
.avatar svg { fill: currentColor; fill-opacity: 0.18; }
.atlas-link { text-align: left; max-width: 34ch; }

/* ---- photo behind cards (U.S. News style) ---- */
.has-bg { position: relative; isolation: isolate; overflow: hidden; color: #fff; border-color: transparent; }
.has-bg > .card-bg { position: absolute; inset: 0; z-index: -1; display: block; }
.has-bg > .card-bg img { width: 100%; height: 100%; object-fit: cover; display: block; }
.has-bg > .card-bg::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(8,24,52,.55) 0%, rgba(8,24,52,.86) 100%); }
.has-bg, .has-bg :is(h2, h3, p, span, strong, li, .muted, .small, .up-date, .up-title, .up-sub, .plan-name, .plan-price) { color: #fff; }
.has-bg .muted, .has-bg .up-sub { color: rgba(255,255,255,.82); }
.has-bg .ticks li::before { filter: brightness(2); }
.has-bg .role-icon, .has-bg .tool-ic { background: rgba(255,255,255,.16); color: #fff; }
.has-bg .btn:not(.btn-primary):not(.btn-gold) { background: #fff; color: var(--navy, #0b2a5b); border-color: #fff; }
.has-bg .badge, .has-bg .chip-count { color: inherit; }
.has-bg:hover > .card-bg img { transform: scale(1.04); }
.has-bg > .card-bg img { transition: transform .4s ease; }
.quiz-pick.has-bg { min-height: 150px; padding: 22px; align-items: flex-end; }
.role-card.has-bg { min-height: 340px; }
.tool.has-bg, .plan-mini-card.has-bg { min-height: 96px; }
.country-hero.page-hero .back-link, .country-hero.page-hero .atlas-tag, .country-hero.page-hero .country-name, .country-hero.page-hero .cstat-l, .country-hero.page-hero .cstat-v { color: #fff; }
.scope-badge { display: inline-flex; align-items: center; gap: 4px; }
.scope-international { background: #e8f0fc; color: #123a7a; }
.scope-national { background: #fdf3d6; color: #6b4a00; }
.scope-regional { background: #e6f4ea; color: #1b5e30; }
.role-card.has-bg > .card-bg::after { background: linear-gradient(180deg, rgba(8,24,52,.80) 0%, rgba(8,24,52,.94) 100%); }
.role-card.has-bg .muted, .role-card.has-bg li { color: #fff; }
.uni-strong { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 14px; margin: 2px 0 10px; font-size: 13px; }
.uni-strong-l { font-weight: 700; text-transform: uppercase; letter-spacing: .04em; font-size: 11px; color: var(--muted, #5b6575); }
.uni-strong-i b { color: #8a5a00; }
.rank-subjects { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 16px; margin-top: 16px; }
.rank-sub-list { list-style: none; margin: 10px 0 8px; padding: 0; }
.rank-sub { display: flex; justify-content: space-between; gap: 12px; padding: 8px 0; border-bottom: 1px solid var(--line, #e3e7ee); }
.rank-sub:last-child { border-bottom: 0; }
.rank-sub strong { color: #8a5a00; font-variant-numeric: tabular-nums; }
.u-fields { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin: 12px 0; }
.u-fields-l { font-weight: 700; text-transform: uppercase; letter-spacing: .04em; font-size: 12px; color: var(--muted, #5b6575); }
.u-field { background: #fdf3d6; color: #6b4a00; padding: 4px 10px; font-size: 13px; font-weight: 600; }

/* ---- side-by-side photo cards (photo left, text right) ---- */
.has-side { display: grid !important; grid-template-columns: minmax(96px, 36%) 1fr; align-items: stretch; padding: 0 !important; overflow: hidden; gap: 0; }
.has-side > .side-media { position: relative; display: block; min-height: 100%; background: #dfe5ee; }
.has-side > .side-media img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; display: block; }
.has-side > .side-body { padding: 16px 18px; min-width: 0; display: flex; flex-direction: column; gap: 6px; }
.upcoming { grid-template-columns: repeat(auto-fill, minmax(340px, 1fr)); }
.tools { grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); }
.tool.has-side > .side-body { flex-direction: row; align-items: center; gap: 12px; }
@media (max-width: 520px) { .has-side { grid-template-columns: 30% 1fr; } .upcoming, .tools { grid-template-columns: 1fr; } }
.tool.has-side > .side-body { flex-direction: row; align-items: center; gap: 12px; padding: 14px 16px; }
.tool.has-side > .side-body > span:not(.tool-ic) { display: flex; flex-direction: column; gap: 3px; flex: 1; min-width: 0; }
.tool.has-side > .side-body > span:not(.tool-ic) > strong { display: block; font-size: 16px; }
.tool.has-side > .side-body > span:not(.tool-ic) > .muted { display: block; line-height: 1.45; }
.tool.has-side .tool-ic, .tool.has-side .tool-go { flex: none; }
.tool > span:not(.tool-ic), .tool > .side-body > span:not(.tool-ic) { display: flex; flex-direction: column; gap: 3px; flex: 1; min-width: 0; }
.tool strong { display: block; }
.tool { align-items: center; }
.tool.has-side { grid-template-columns: minmax(84px, 28%) 1fr; }
.tool.has-side .tool-ic { display: none; }
.tool.has-side > .side-body { padding: 14px 16px; gap: 10px; }
.photo-list { display: grid; gap: 14px; margin: 16px 0; }
.photo-row { display: grid; grid-template-columns: 180px 1fr; gap: 16px; padding: 14px; border: 1px solid var(--line, #e3e7ee); background: #fff; }
.photo-prev { aspect-ratio: 3/1; background: #dfe5ee; overflow: hidden; }
.photo-prev img { width: 100%; height: 100%; object-fit: cover; display: block; }
.photo-fields { display: grid; gap: 8px; min-width: 0; }
@media (max-width: 560px) { .photo-row { grid-template-columns: 1fr; } }

.photo-pos { display: grid; grid-template-columns: auto 1fr auto; gap: .6rem; align-items: center; font-size: .85rem; }
.photo-pos input { width: 100%; }

/* deadline cards: photo on the left like the university cards; whole card opens the school page */
.dl-item.has-dl-media { grid-template-columns: minmax(130px, 200px) 150px minmax(0, 1fr) auto; padding: 0 22px 0 0; overflow: hidden; }
.dl-item.has-dl-media > .dl-media { position: relative; align-self: stretch; min-height: 120px; background: #dfe5ee; }
.dl-item.has-dl-media > .dl-media img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; display: block; }
.dl-item.has-dl-media > :not(.dl-media) { padding-block: 18px; }
.dl-item.is-link { cursor: pointer; }
@media (max-width: 700px) {
  .dl-item.has-dl-media { grid-template-columns: minmax(0, 1fr); padding: 0; gap: 0; }
  .dl-item.has-dl-media > .dl-media { min-height: 0; height: 130px; }
  .dl-item.has-dl-media > :not(.dl-media) { padding: 12px 16px; }
  .dl-item.has-dl-media > .dl-actions { padding-bottom: 16px; }
}
.item-prev { aspect-ratio: 5/4; max-width: 240px; margin-bottom: 10px; }

/* scholarship finder: photo on the left, text on the right (same layout as the university cards) */
.schol-finder { grid-template-columns: 1fr; gap: 14px; }
.schol.has-side { grid-template-columns: minmax(170px, 260px) minmax(0, 1fr); }
.schol.has-side { border-top: 3px solid var(--gold); }
.schol.has-side > .side-body { padding: 18px 20px; gap: 12px; }
.schol.has-side > .side-media { min-height: 180px; }
@media (max-width: 520px) { .schol.has-side { grid-template-columns: 1fr; } .schol.has-side > .side-media { min-height: 0; height: 130px; } }

/* competitions: one per row, photo on the left (same as the scholarship list) */
.card-grid.comp-rows { grid-template-columns: 1fr; gap: 14px; }
.listing.has-side { grid-template-columns: minmax(170px, 260px) minmax(0, 1fr); }
.listing.has-side > .side-media { min-height: 200px; }
.listing.has-side > .side-body { padding: 18px 22px; gap: 10px; }
@media (max-width: 520px) { .listing.has-side { grid-template-columns: 1fr; } .listing.has-side > .side-media { min-height: 0; height: 130px; } }

/* profile analyzer: volunteering / recommendation letters / research rows, school offering, Ivy checklist */
.xrows { display: grid; gap: 10px; }
.xrow-list { display: grid; gap: 8px; }
.xrow { display: grid; gap: 8px; align-items: center; }
.xrow-vol { grid-template-columns: minmax(0, 1.6fr) minmax(90px, 0.6fr) minmax(0, 2fr) auto; }
.xrow-recs { grid-template-columns: minmax(150px, 1fr) minmax(0, 1.4fr) minmax(120px, 0.8fr) auto; }
.xrow-res { grid-template-columns: minmax(0, 2fr) minmax(120px, 0.9fr) minmax(130px, 1fr) minmax(0, 1.2fr) auto; }
.xrow input, .xrow select { width: 100%; min-width: 0; }
@media (max-width: 720px) { .xrow-vol, .xrow-recs, .xrow-res { grid-template-columns: 1fr 1fr; } .xrow > :first-child { grid-column: 1 / -1; } }
.cw-offer select { flex: 2; } .cw-offer input { flex: 1; max-width: 160px; }
.ivy-box { border: 1px solid var(--line); border-left: 3px solid var(--navy); background: var(--surface); padding: 18px 20px; display: grid; gap: 10px; }
.ivy-box h3 { display: flex; align-items: center; gap: 8px; font-size: 17px; }
.ivy-list { list-style: none; padding: 0; margin: 0; display: grid; gap: 8px; }
.ivy-list li { display: grid; grid-template-columns: 18px 1fr; gap: 8px; align-items: start; line-height: 1.5; font-size: 14.5px; }
.ivy-list li.is-ok .ic { color: var(--ok, #1f7a4d); }
.ivy-list li.is-gap .ic { color: var(--warn, #b45309); }
.ivy-list li.is-unknown .ic { color: var(--muted, #6b7280); }
.intl-box .ticks { margin-top: 6px; }
/* deadline reminder days under Account */
.remind-days { border: 0; padding: 0; margin: 0; min-width: 0; }
.remind-days legend { font-weight: 600; color: var(--ink); padding: 0; margin-bottom: 6px; }

/* ---- soft corners on selected blocks only: main cards, dialogs, buttons and fields.
   Badges, chips, tables, tiles, the dashboard menu and the photos inside cards keep their square corners. ---- */
:root { --r-soft: 10px; --r-ctl: 6px; }
.card, .panel, .listing, .person, .uni-card, .plan-card, .news-card, .news-feature, .team-card, .auth-card, .dlg,
.quiz-card, .role-card, .tool, .stat-tile, .ai-note, .search-panel, .submit-band, .notice, .empty { border-radius: var(--r-soft); }
.uni-card, .news-card, .news-feature { overflow: hidden; }
.btn:not(.btn-link) { border-radius: var(--r-ctl); }
input[type="text"], input[type="email"], input[type="tel"], input[type="url"], input[type="password"], input[type="number"], input[type="search"],
input[type="date"], input[type="month"], input[type="datetime-local"], select, textarea { border-radius: var(--r-ctl); }

/* ---- Phase 1 (HNUE proposal): trial note, analysis rating, data reports, sign-up source QR ---- */
.badge-bad { background: var(--bad-soft); color: var(--bad); }
.table tr.is-late td { background: color-mix(in srgb, var(--bad-soft) 55%, transparent); }
.rate-box h3 { font-size: 17px; margin: 0 0 10px; }
.rate-row { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.rate-btn { min-width: 44px; justify-content: center; }
.src-form { align-items: flex-end; gap: 12px; flex-wrap: wrap; margin-top: 14px; }
.src-form .field { flex: 1 1 220px; margin: 0; }
.src-out { margin-top: 12px; display: grid; gap: 10px; justify-items: start; }
.src-out svg { width: 180px; height: 180px; background: #fff; padding: 8px; border: 1px solid var(--line); border-radius: var(--r-ctl); }
.u-sources .alumni-ok { white-space: nowrap; }
/* two plans on sale (Basic, Premium): two columns instead of three */
.plans { grid-template-columns: repeat(2, minmax(0, 1fr)); max-width: 880px; margin-inline: auto; }
.plan-mini { grid-template-columns: repeat(2, minmax(0, 1fr)); }
@media (max-width: 760px) { .plans, .plan-mini { grid-template-columns: 1fr; } }

/* ---- Phase 2: partner page, practice tests, workshops ---- */
.page-body.narrow { max-width: 760px; }
.pq { border: 1px solid var(--line); margin: 0; }
.pq legend { font-weight: 600; padding: 0 4px; line-height: 1.5; }
.pq-n { color: var(--ink-3); }
.pq-review { padding-left: 20px; }
.pq-review li { padding: 10px 12px; border-radius: var(--r-ctl); border-left: 3px solid var(--line); }
.pq-review li.is-ok { border-left-color: var(--navy); background: var(--navy-soft); }
.pq-review li.is-bad { border-left-color: var(--bad); background: var(--bad-soft); }
.ws-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 14px; }
.ws-item { display: grid; gap: 10px; padding: 16px; border: 1px solid var(--line); border-radius: var(--r-soft); background: var(--surface); }
.ws-item .row { flex-wrap: wrap; gap: 10px; align-items: center; }
.ws-ask { display: grid; gap: 8px; }
.ws-ask .field { margin: 0; }
.dc { display: contents; }
