/* Oceanview: one dark, cinematic system for every page.
   Every surface below declares its own text colour, so no component can
   inherit light text onto a light ground (or the reverse). Forms are light
   cards on the dark page, because typed text must be effortless to read. */

:root {
    --bg: #0c1820;
    --bg-2: #101f29;
    --surface: #142631;
    --surface-2: #1a3140;
    --surface-3: #213b4b;
    --line: #2b4352;
    --line-strong: #5f7a8a;
    --text: #f2f0e8;
    --text-2: #c9d2d6;
    --text-3: #9fb0b8;
    --accent: #99d2c7;
    --accent-hover: #b7e4da;
    --accent-ink: #0c1820;
    --gold: #eac58f;
    --gold-ink: #2b1d07;
    --ok: #93d8aa;
    --warn: #eac58f;
    --danger: #ffaaa0;
    --danger-strong: #d9473a;
    --field-bg: #f2f0e8;
    --field-text: #101f29;
    --field-hint: #4b5c64;
    --field-line: #8ea3ab;
    --focus: #eac58f;
    --serif: Georgia, 'Times New Roman', serif;
    --sans: 'IBM Plex Sans', 'Segoe UI', system-ui, sans-serif;
    --mono: 'IBM Plex Mono', 'Cascadia Mono', Consolas, monospace;
    --radius: 6px;
    --radius-lg: 12px;
    --shell: 1240px;
    --measure: 68ch;
    /* Aliases older templates still use. */
    --ink: var(--bg); --raised: var(--surface-2); --muted: var(--text-2); --faint: var(--text-3);
    --sea: var(--accent); --sea-dim: #5e9d92; --flare: var(--gold);
    color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-padding-top: 96px; -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--text); font: 400 16px/1.6 var(--sans); -webkit-font-smoothing: antialiased; }
img { max-width: 100%; }
a { color: var(--accent); text-decoration: underline; text-decoration-color: rgba(153, 210, 199, .35); text-underline-offset: 3px; }
a:hover { color: var(--accent-hover); text-decoration-color: currentColor; }
h1, h2, h3, h4 { color: var(--text); margin: 0 0 .6rem; line-height: 1.15; text-wrap: balance; }
h1 { font: 400 clamp(2.3rem, 5vw, 3.7rem)/1.06 var(--serif); letter-spacing: -.03em; }
h2 { font: 600 clamp(1.35rem, 2.4vw, 1.75rem)/1.2 var(--sans); letter-spacing: -.015em; }
h3 { font: 600 1.12rem/1.3 var(--sans); }
h4 { font: 600 1rem/1.3 var(--sans); }
p { margin: 0 0 1rem; max-width: var(--measure); }
ul, ol { padding-left: 1.25rem; }
li + li { margin-top: .3rem; }
hr { border: 0; border-top: 1px solid var(--line); margin: 2rem 0; }
code, .mono { font-family: var(--mono); font-size: .9em; }
small, .small { font-size: .875rem; }
.muted { color: var(--text-2); }
.faint { color: var(--text-3); }
strong { font-weight: 600; }
::selection { background: var(--accent); color: var(--accent-ink); }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 3px; }
[hidden] { display: none !important; }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

body .ov-skip { position: fixed; left: 16px; top: -100px; z-index: 1000; padding: 12px 18px; background: var(--text); color: var(--bg); font-weight: 600; text-decoration: none; }
body .ov-skip:focus { top: 12px; }

.wrap, .ov-shell { width: min(var(--shell), 100% - 64px); margin-inline: auto; }
main { min-width: 0; }
.ov-app main { padding: 0 0 4rem; }
.ov-app main > .wrap { padding-top: 2.5rem; }

/* --- header ------------------------------------------------------------------ */
.ov-header { position: sticky; top: 0; z-index: 50; background: rgba(12, 24, 32, .94); border-bottom: 1px solid var(--line); backdrop-filter: blur(12px); }
.ov-header-inner { display: flex; align-items: center; justify-content: space-between; gap: 24px; min-height: 76px; }
.ov-brand { display: inline-flex; align-items: center; color: var(--text); text-decoration: none; flex-shrink: 0; }
.ov-brand:hover { color: var(--text); }
.ov-wordmark { font: 700 27px/1 var(--serif); letter-spacing: -.035em; text-transform: none; }
.ov-wordmark small { display: block; margin-top: 6px; font: 600 10px/1.3 var(--sans); letter-spacing: .14em; color: var(--accent); text-transform: uppercase; }
.ov-nav { display: flex; align-items: center; gap: 4px; font-size: 14.5px; }
.ov-nav > a, .ov-account summary { display: inline-flex; align-items: center; gap: 6px; min-height: 44px; padding: 0 12px; border-radius: var(--radius); color: var(--text-2); text-decoration: none; font-weight: 500; }
.ov-nav > a:hover, .ov-account summary:hover { color: var(--text); background: var(--surface); }
.ov-nav > a[aria-current="page"] { color: var(--text); box-shadow: inset 0 -2px 0 var(--accent); border-radius: 0; }
.ov-nav .ov-nav-cta { margin-left: 8px; background: var(--accent); color: var(--accent-ink); font-weight: 600; padding: 0 16px; }
.ov-nav .ov-nav-cta:hover { background: var(--accent-hover); color: var(--accent-ink); }
.ov-account { position: relative; }
.ov-account summary { list-style: none; cursor: pointer; }
.ov-account summary::-webkit-details-marker { display: none; }
.ov-account summary img { width: 26px; height: 26px; border-radius: 50%; border: 1px solid var(--line-strong); }
.ov-account-links { position: absolute; right: 0; top: calc(100% + 8px); width: 260px; padding: 8px; background: var(--surface-2); border: 1px solid var(--line-strong); border-radius: var(--radius-lg); box-shadow: 0 18px 40px rgba(0, 0, 0, .45); }
.ov-account-links a { display: flex; justify-content: space-between; align-items: center; min-height: 42px; padding: 0 12px; border-radius: var(--radius); color: var(--text); text-decoration: none; }
.ov-account-links a:hover { background: var(--surface-3); color: var(--text); }
.ov-account-name { display: block; padding: 8px 12px 12px; margin-bottom: 6px; border-bottom: 1px solid var(--line); color: var(--text-2); font-size: 13px; overflow-wrap: anywhere; }
.ov-account-links hr { margin: 6px 0; }
.ov-menu-toggle { display: none; align-items: center; gap: 10px; min-height: 44px; padding: 0 14px; border: 1px solid var(--line-strong); border-radius: var(--radius); background: transparent; color: var(--text); font: 500 14px var(--sans); cursor: pointer; }
.ov-menu-lines { width: 18px; height: 12px; border-block: 2px solid currentColor; position: relative; }
.ov-menu-lines::after { content: ''; position: absolute; left: 0; right: 0; top: 3px; border-top: 2px solid currentColor; }
.unread-dot { display: inline-flex; align-items: center; justify-content: center; min-width: 20px; height: 20px; padding: 0 6px; border-radius: 10px; background: var(--gold); color: var(--gold-ink); font: 700 11px/1 var(--sans); }

@media (max-width: 1100px) {
    .ov-menu-toggle { display: inline-flex; }
    .ov-nav { display: none; position: absolute; left: 0; right: 0; top: 100%; flex-direction: column; align-items: stretch; gap: 2px; padding: 12px 32px 20px; background: var(--bg-2); border-bottom: 1px solid var(--line); max-height: calc(100vh - 76px); overflow-y: auto; }
    .ov-nav.is-open { display: flex; }
    .ov-nav > a, .ov-account summary { padding: 0 8px; }
    .ov-nav > a[aria-current="page"] { box-shadow: inset 3px 0 0 var(--accent); }
    .ov-nav .ov-nav-cta { margin: 8px 0 0; justify-content: center; }
    .ov-account-links { position: static; width: auto; margin-top: 4px; box-shadow: none; }
}

/* --- page heads and banners ------------------------------------------------------ */
.eyebrow, .ov-label { display: block; font: 600 12px/1.5 var(--sans); letter-spacing: .12em; text-transform: uppercase; color: var(--accent); margin: 0 0 .75rem; }
.eyebrow a { color: inherit; }
.page-head { padding: 1rem 0 2rem; margin-bottom: 2rem; border-bottom: 1px solid var(--line); }
.page-head h1, .workflow-title { margin: 0 0 1rem; }
.page-head .lead, .workflow-intro, .lead { color: var(--text-2); font-size: 1.12rem; line-height: 1.65; max-width: 62ch; }
.page-head .actions { margin-top: 1.5rem; }
.breadcrumb { display: flex; flex-wrap: wrap; gap: 6px; font-size: 14px; color: var(--text-3); margin-bottom: 1rem; }
.breadcrumb a { color: var(--text-2); }

.ov-intake-banner { background: #133a35; color: var(--text); border-bottom: 1px solid #2f6157; }
.ov-intake-inner { width: min(var(--shell), 100% - 64px); margin-inline: auto; padding: 14px 0; display: flex; flex-wrap: wrap; align-items: center; gap: 8px 24px; }
.ov-intake-heading { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 14px; }
.ov-intake-eyebrow { font: 600 11px/1.4 var(--sans); letter-spacing: .12em; text-transform: uppercase; color: #bfe0d7; }
.ov-intake-status { display: inline-block; padding: 2px 8px; border: 1px solid #7fb3a5; border-radius: 3px; font-size: 12px; font-weight: 600; color: var(--text); }
.ov-intake-title { margin: 0; font-weight: 600; color: var(--text); }
.ov-intake-copy { flex: 1 1 360px; }
.ov-intake-copy p { margin: 0; color: #dbe8e3; font-size: 14px; }
.ov-intake-copy .ov-intake-note { display: none; }
.ov-intake-banner .ov-intake-action { display: inline-flex; align-items: center; gap: 12px; min-height: 42px; padding: 0 16px; border-radius: var(--radius); background: var(--text); color: #133a35; font-weight: 600; text-decoration: none; }
.ov-intake-banner .ov-intake-action:hover { background: #fff; color: #133a35; }
.ov-intake-banner[data-intake-mode="unavailable"] { background: var(--surface); border-color: var(--line); }

.ov-agency-intake { margin-bottom: 28px; padding: 18px 22px; border: 1px solid var(--line-strong); border-left: 4px solid var(--accent); border-radius: var(--radius); background: var(--surface); color: var(--text); }
.ov-agency-intake p:last-child { margin: 8px 0 0; color: var(--text-2); }
.ov-agency-intake[data-recruitment-state="closed"] { border-left-color: var(--gold); }
.ov-agency-intake[data-recruitment-state="pathway"] { border-left-color: #8eb7d4; }

/* --- buttons -------------------------------------------------------------------------- */
.btn, .ov-button { display: inline-flex; align-items: center; justify-content: center; gap: 10px; min-height: 44px; padding: 0 18px; border-radius: var(--radius); border: 1px solid transparent; font: 600 15px/1.2 var(--sans); text-decoration: none; cursor: pointer; white-space: nowrap; }
.btn:hover, .ov-button:hover { text-decoration: none; }
.btn-primary, .ov-button { background: var(--accent); color: var(--accent-ink); border-color: var(--accent); }
.btn-primary:hover, .ov-button:hover { background: var(--accent-hover); border-color: var(--accent-hover); color: var(--accent-ink); }
.btn-quiet, .btn-secondary { background: transparent; color: var(--text); border-color: var(--line-strong); }
.btn-quiet:hover, .btn-secondary:hover { border-color: var(--accent); color: var(--text); background: var(--surface); }
.btn-ok { background: var(--ok); color: #0d2316; border-color: var(--ok); }
.btn-ok:hover { background: #b5e8c6; color: #0d2316; }
.btn-gold { background: var(--gold); color: var(--gold-ink); border-color: var(--gold); }
.btn-gold:hover { background: #f3d6ad; color: var(--gold-ink); }
.btn-danger { background: transparent; color: var(--danger); border-color: rgba(255, 170, 160, .6); }
.btn-danger:hover { background: rgba(217, 71, 58, .14); color: #ffd0ca; border-color: var(--danger); }
.btn-sm { min-height: 36px; padding: 0 12px; font-size: 14px; }
.btn-block { width: 100%; }
.btn[disabled], .btn[aria-disabled="true"] { opacity: .5; cursor: not-allowed; }
.actions, .row { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; }
.ov-text-link { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; color: var(--accent); font-weight: 600; }
.ov-arrow { width: 18px; height: 18px; flex-shrink: 0; }

/* --- surfaces ------------------------------------------------------------------- */
.panel, .card { background: var(--surface); color: var(--text); border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 1.5rem; }
.panel + .panel { margin-top: 1rem; }
.panel > :last-child, .card > :last-child { margin-bottom: 0; }
.panel h2:first-child, .card h2:first-child, .panel h3:first-child { margin-top: 0; }
a.panel, a.card { display: block; text-decoration: none; transition: border-color .15s, background .15s; }
a.panel:hover, a.card:hover { border-color: var(--accent); background: var(--surface-2); color: var(--text); }
.panel-accent { border-left: 3px solid var(--accent); }
.panel-gold { border-left: 3px solid var(--gold); }
.panel-quiet { background: transparent; }
.callout { padding: 1rem 1.25rem; border-radius: var(--radius); background: var(--surface-2); border-left: 3px solid var(--gold); color: var(--text); }
.callout p:last-child { margin: 0; }
.stack > * + * { margin-top: 1rem; }
.section { padding: 2.5rem 0; border-top: 1px solid var(--line); }
.section-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: end; gap: 1rem; margin-bottom: 1.25rem; }
.section-head h2 { margin: 0; }
.section-head p { margin: 0; color: var(--text-2); }
.grid-2 { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: 1.5rem; align-items: start; }
.grid-2 > * { min-width: 0; }
.grid-halves { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.25rem; }
.grid-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 290px), 1fr)); gap: 1rem; }
.grid-cards > .panel { margin-top: 0; }
.split { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 2rem; align-items: start; }
.split > * { min-width: 0; }
.sticky { position: sticky; top: 100px; }

/* --- data ----------------------------------------------------------------------- */
.table-scroll, .cole-scroll { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--radius-lg); background: var(--surface); }
table.data { width: 100%; border-collapse: collapse; font-size: .95rem; color: var(--text); }
table.data th { text-align: left; padding: .75rem 1rem; font: 600 12px/1.4 var(--sans); letter-spacing: .08em; text-transform: uppercase; color: var(--text-2); background: var(--surface-2); border-bottom: 1px solid var(--line-strong); white-space: nowrap; }
table.data td { padding: .8rem 1rem; border-bottom: 1px solid var(--line); vertical-align: middle; }
table.data tr:last-child td { border-bottom: 0; }
table.data tbody tr:hover td { background: rgba(255, 255, 255, .02); }
.panel > table.data th { background: transparent; padding-inline: .5rem; }
.panel > table.data td { padding-inline: .5rem; }
dl.kv { display: grid; grid-template-columns: max-content minmax(0, 1fr); gap: .5rem 1.5rem; margin: 0; }
dl.kv dt { color: var(--text-2); font-size: .92rem; }
dl.kv dd { margin: 0; overflow-wrap: anywhere; white-space: pre-wrap; }

.pill { display: inline-flex; align-items: center; gap: 6px; padding: 2px 10px; border-radius: 999px; border: 1px solid var(--line-strong); font: 600 12px/1.6 var(--sans); letter-spacing: .02em; color: var(--text-2); background: transparent; white-space: nowrap; }
.pill-open, .pill-trainee, .pill-enrolled, .pill-pending, .pill-info { color: var(--accent); border-color: rgba(153, 210, 199, .55); background: rgba(153, 210, 199, .08); }
.pill-hold, .pill-accepted-wait, .pill-expired, .pill-warn { color: var(--gold); border-color: rgba(234, 197, 143, .55); background: rgba(234, 197, 143, .08); }
.pill-accepted, .pill-active, .pill-ok, .pill-pass, .pill-confirmed, .pill-hired, .pill-ready { color: var(--ok); border-color: rgba(147, 216, 170, .55); background: rgba(147, 216, 170, .08); }
.pill-denied, .pill-revoked, .pill-suspended, .pill-banned, .pill-fail, .pill-returned, .pill-declined { color: var(--danger); border-color: rgba(255, 170, 160, .55); background: rgba(255, 170, 160, .07); }
.pill-withdrawn, .pill-inactive, .pill-none, .pill-closed { color: var(--text-3); }

.tabs { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 1.25rem; }
.tabs a { display: inline-flex; align-items: center; min-height: 38px; padding: 0 14px; border-radius: 999px; border: 1px solid var(--line-strong); color: var(--text-2); font-size: 14px; text-decoration: none; }
.tabs a:hover { color: var(--text); border-color: var(--accent); }
.tabs a.active, .tabs a[aria-current="page"] { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); font-weight: 600; }

details > summary { cursor: pointer; color: var(--text-2); }
details > summary:hover { color: var(--text); }
details[open] > summary { margin-bottom: .75rem; }
.disclosure { border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 1rem 1.25rem; background: var(--surface); }
.disclosure + .disclosure { margin-top: .75rem; }
.disclosure > summary { font-weight: 600; color: var(--text); }

.flash { display: flex; gap: 12px; align-items: flex-start; margin: 0 0 1.25rem; padding: .9rem 1.1rem; border-radius: var(--radius); border: 1px solid var(--line-strong); border-left: 4px solid var(--accent); background: var(--surface-2); color: var(--text); }
.flash a { color: var(--accent); }
.flash.success { border-left-color: var(--ok); }
.flash.warning { border-left-color: var(--gold); }
.flash.danger { border-left-color: var(--danger-strong); background: #2b1f24; }
.flash.info { border-left-color: var(--accent); }

/* --- forms: light cards so typed text is always dark on light ------------------------------ */
label { display: block; font-weight: 600; margin-bottom: .4rem; color: var(--text); }
.field { margin-bottom: 1.25rem; }
.field label { margin-bottom: .45rem; }
input:not([type=checkbox]):not([type=radio]):not([type=range]):not([type=submit]):not([type=button]):not([type=hidden]):not([type=file]),
textarea, select {
    display: block; width: 100%; min-height: 46px; padding: .65rem .85rem; border: 1px solid var(--field-line); border-radius: var(--radius);
    background: var(--field-bg); color: var(--field-text); font: 400 16px/1.45 var(--sans); color-scheme: light;
}
textarea { min-height: 120px; resize: vertical; }
select option, select optgroup { background: var(--field-bg); color: var(--field-text); }
input::placeholder, textarea::placeholder { color: var(--field-hint); opacity: 1; }
input:focus, textarea:focus, select:focus { outline: 3px solid var(--focus); outline-offset: 2px; border-color: var(--field-text); }
input:disabled, textarea:disabled, select:disabled { background: #c9d0cf; color: #33434b; }
input:-webkit-autofill, textarea:-webkit-autofill { -webkit-text-fill-color: var(--field-text); box-shadow: 0 0 0 1000px var(--field-bg) inset; }
input[type=checkbox], input[type=radio] { width: 20px; height: 20px; margin: 2px 0 0; accent-color: var(--accent); flex-shrink: 0; }
input[type=file] { color: var(--text); }
.check { display: flex; gap: .75rem; align-items: flex-start; font-weight: 400; }
.hint { display: block; margin: .35rem 0 0; color: var(--text-2); font-size: .9rem; font-weight: 400; }
.req { color: var(--gold); }
.field-error { color: var(--danger); font-weight: 600; margin-top: .35rem; }
.field [aria-invalid=true] { border: 2px solid var(--danger-strong); }
.error-summary { padding: 1rem 1.25rem; border: 2px solid var(--danger-strong); border-radius: var(--radius); background: #2b1f24; color: var(--text); margin-bottom: 1.5rem; }
.error-summary h2 { font-size: 1.1rem; }
.error-summary li, .error-summary a { color: #ffd0ca; }
form.inline { display: inline; }
fieldset { border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 1.25rem; margin: 0 0 1.5rem; }
legend { padding: 0 .5rem; font-weight: 600; color: var(--accent); }
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 1.25rem; }
.form-grid .full { grid-column: 1 / -1; }

/* --- footer ------------------------------------------------------------------------ */
.ov-footer { border-top: 1px solid var(--line); background: var(--bg-2); color: var(--text-2); padding: 3rem 0 2rem; font-size: 14px; }
.ov-footer-top { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 2rem; padding-bottom: 2rem; border-bottom: 1px solid var(--line); }
.ov-footer nav { display: flex; flex-wrap: wrap; gap: 4px 24px; }
.ov-footer nav a, .ov-back-top { display: inline-flex; align-items: center; gap: 6px; min-height: 40px; color: var(--text-2); text-decoration: none; }
.ov-footer nav a:hover, .ov-back-top:hover { color: var(--text); }
.ov-footer-bottom { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 1rem; padding-top: 1.25rem; color: var(--text-3); }
.ov-image-credit { display: block; margin-top: .75rem; color: var(--text-3); font-size: 12px; }

/* --- the applications journey ---------------------------------------------------------- */
.onboarding-steps, .journey { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 0; list-style: none; margin: 1.5rem 0 2rem; padding: 0; border: 1px solid var(--line); border-radius: var(--radius-lg); overflow: hidden; background: var(--surface); }
.onboarding-steps li, .journey li { margin: 0; padding: 1.1rem 1.2rem 1.2rem; border-top: 3px solid transparent; border-right: 1px solid var(--line); color: var(--text); }
.onboarding-steps li:last-child, .journey li:last-child { border-right: 0; }
.onboarding-steps li > span, .journey .step-n { display: block; font: 600 12px/1.4 var(--mono); color: var(--text-3); margin-bottom: .4rem; }
.onboarding-steps h2, .journey h3 { font: 600 1rem/1.3 var(--sans); margin: 0 0 .35rem; }
.onboarding-steps p, .journey p { font-size: .88rem; color: var(--text-2); margin: 0; }
.onboarding-steps li.step-complete, .journey li.done { border-top-color: var(--ok); }
.onboarding-steps li.step-complete > span, .journey li.done .step-n { color: var(--ok); }
.onboarding-steps li.step-current, .journey li.current { border-top-color: var(--gold); background: var(--surface-2); }
.onboarding-steps li.step-current > span, .journey li.current .step-n { color: var(--gold); }
.onboarding-next { border-left: 3px solid var(--gold); }
.application-layout { align-items: start; margin-top: 1.5rem; }
.application-card h2, .conversation h2, .application-layout h2 { font-size: 1.3rem; margin: .3rem 0 .7rem; }
.application-answers dt { overflow-wrap: anywhere; }
.decision-note { border-left: 3px solid var(--line-strong); padding: .25rem 1rem; margin: 1rem 0; }
.message-list { margin: 1.25rem 0; }
.application-message { background: var(--surface-2); border: 1px solid var(--line); border-radius: var(--radius); padding: 1rem 1.15rem; margin-bottom: .8rem; }
.message-staff { border-left: 3px solid var(--gold); }
.message-meta { display: flex; flex-wrap: wrap; align-items: baseline; gap: .3rem 1rem; margin-bottom: .6rem; }
.message-meta span { font-size: .8rem; color: var(--text-2); }
.message-body { white-space: pre-wrap; overflow-wrap: anywhere; line-height: 1.65; }
.answer-preview { margin: .9rem 0 .2rem; }
.answer-preview summary, .withdraw-application summary { font-size: .9rem; }
.answer-preview[open] summary { color: var(--gold); }
.withdraw-application { margin-top: 1.5rem; border-top: 1px solid var(--line); padding-top: 1rem; }

.dept-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1rem; }
@media (min-width: 1180px) { .dept-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
@media (max-width: 640px) { .dept-grid { grid-template-columns: 1fr; } }
.dept-card { display: flex; flex-direction: column; gap: .75rem; padding: 1.4rem; border: 1px solid var(--line); border-top: 4px solid var(--dept, var(--accent)); border-radius: var(--radius-lg); background: var(--surface); color: var(--text); }
.dept-card h3 { margin: 0; font: 400 1.6rem/1.15 var(--serif); }
.dept-card p { color: var(--text-2); font-size: .95rem; margin: 0; }
.dept-card .dept-foot { margin-top: auto; display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: .75rem; padding-top: .5rem; }
.dept-cle { --dept: #abbd86; } .dept-mp { --dept: #8eb7d4; } .dept-safr { --dept: #e2707b; } .dept-gs { --dept: #eac58f; }

/* --- COLE ---------------------------------------------------------------------------------- */
.cole-page > .flash { width: min(var(--shell), 100% - 64px); margin: 1.25rem auto; }
.cole-hero { position: relative; isolation: isolate; overflow: hidden; margin: 0 0 1rem; padding: 5rem 0 3.5rem; background: var(--bg-2); border-bottom: 1px solid var(--line); }
.cole-hero > img { position: absolute; inset: 0; z-index: -2; width: 100%; height: 100%; object-fit: cover; object-position: 50% 40%; }
.cole-hero::after { content: ''; position: absolute; inset: 0; z-index: -1; background: linear-gradient(90deg, rgba(12, 24, 32, .96), rgba(12, 24, 32, .82) 50%, rgba(12, 24, 32, .45)); }
.cole-hero h1 { max-width: 15ch; font-size: clamp(2.6rem, 6vw, 4.4rem); }
.cole-hero .lead { color: #dde4e6; }
.cole-crest { display: inline-flex; align-items: center; gap: 10px; font: 600 12px/1.4 var(--sans); letter-spacing: .14em; text-transform: uppercase; color: var(--gold); margin-bottom: 1.25rem; }
.cole-crest::before { content: ''; width: 26px; height: 2px; background: var(--gold); }
.facts { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1px; margin: 2rem 0 0; background: var(--line); border: 1px solid var(--line); border-radius: var(--radius-lg); overflow: hidden; }
.facts div { background: rgba(20, 38, 49, .92); padding: 1rem 1.2rem; }
.facts dt { font-size: 12px; letter-spacing: .1em; text-transform: uppercase; color: var(--text-2); }
.facts dd { margin: .25rem 0 0; font: 400 1.9rem/1.1 var(--serif); color: var(--text); }

.score-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1rem; }
.split .score-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
@media (min-width: 1240px) { .split .score-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.score-tile { position: relative; padding: 1.2rem 1.2rem 1.1rem; border: 1px solid var(--line); border-radius: var(--radius-lg); background: var(--surface); color: var(--text); }
.score-tile .score-label { display: block; font: 600 12px/1.4 var(--sans); letter-spacing: .1em; text-transform: uppercase; color: var(--text-2); }
.score-tile .score-value { display: block; margin: .35rem 0 .5rem; font: 400 2.6rem/1 var(--serif); color: var(--text); font-variant-numeric: tabular-nums; }
.score-tile .score-value small { font: 500 1rem var(--sans); color: var(--text-3); margin-left: 2px; }
.score-tile .score-detail { display: block; font-size: .85rem; color: var(--text-2); margin-top: .5rem; }
.score-tile.is-pass { border-color: rgba(147, 216, 170, .45); }
.score-tile.is-pass::before { content: ''; position: absolute; inset: 0 0 auto 0; height: 3px; background: var(--ok); border-radius: var(--radius-lg) var(--radius-lg) 0 0; }
.score-tile.is-expired::before, .score-tile.is-fail::before { content: ''; position: absolute; inset: 0 0 auto 0; height: 3px; background: var(--gold); border-radius: var(--radius-lg) var(--radius-lg) 0 0; }
.meter { height: 6px; border-radius: 3px; background: var(--surface-3); overflow: hidden; }
.meter > span { display: block; height: 100%; background: var(--accent); border-radius: 3px; }
.meter.is-pass > span { background: var(--ok); }
.meter.is-fail > span { background: var(--gold); }
.composite { display: flex; align-items: baseline; gap: .75rem; }
.composite strong { font: 400 3rem/1 var(--serif); }

.module-list { list-style: none; margin: 0; padding: 0; border: 1px solid var(--line); border-radius: var(--radius-lg); overflow: hidden; background: var(--surface); }
.module-list li { display: grid; grid-template-columns: 40px minmax(0, 1fr) auto; gap: 1rem; align-items: center; margin: 0; padding: 1rem 1.2rem; border-bottom: 1px solid var(--line); }
.module-list li:last-child { border-bottom: 0; }
.module-n { display: grid; place-items: center; width: 36px; height: 36px; border-radius: 50%; border: 1px solid var(--line-strong); font: 600 13px var(--mono); color: var(--text-2); }
.module-list li.is-pass .module-n { background: var(--ok); border-color: var(--ok); color: #0d2316; }
.module-title { font-weight: 600; color: var(--text); }
.module-title a { color: var(--text); }
.module-meta { display: block; font-size: .87rem; color: var(--text-2); margin-top: 2px; }
.module-actions { display: flex; flex-wrap: wrap; justify-content: flex-end; align-items: center; gap: 8px; }
.module-score { font: 400 1.5rem/1 var(--serif); font-variant-numeric: tabular-nums; }

.rank-table td:first-child { width: 100%; }
.rank-table select { width: 170px; min-height: 40px; }
.offer { padding: 1.25rem; border: 1px solid var(--line); border-radius: var(--radius-lg); background: var(--surface); }
.offer + .offer { margin-top: .75rem; }
.offer-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: .5rem 1rem; margin-bottom: .5rem; }
.offer-head h3 { margin: 0; }
.offer-pending { border-color: rgba(153, 210, 199, .6); box-shadow: 0 0 0 1px rgba(153, 210, 199, .2); }
.offer blockquote { margin: .75rem 0; padding: .5rem 1rem; border-left: 3px solid var(--line-strong); color: var(--text-2); white-space: pre-wrap; }

.candidate-row { display: grid; grid-template-columns: minmax(0, 1.4fr) repeat(4, minmax(70px, .5fr)) minmax(90px, .6fr) auto; gap: 1rem; align-items: center; padding: 1rem 1.2rem; border-bottom: 1px solid var(--line); }
.candidate-row:last-child { border-bottom: 0; }
.candidate-row .cr-score { font: 400 1.35rem/1 var(--serif); font-variant-numeric: tabular-nums; }
.candidate-row .cr-score small { display: block; font: 500 11px/1.4 var(--sans); color: var(--text-3); letter-spacing: .08em; text-transform: uppercase; margin-top: 4px; }
.candidate-head { background: var(--surface-2); font: 600 12px/1.4 var(--sans); letter-spacing: .08em; text-transform: uppercase; color: var(--text-2); }
.candidate-list { border: 1px solid var(--line); border-radius: var(--radius-lg); overflow: hidden; background: var(--surface); }

/* The exam: big, calm, tappable answers and a clock that is always visible. */
.exam-bar { position: sticky; top: 76px; z-index: 30; display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: .75rem 1.5rem; margin: 0 0 1.5rem; padding: .8rem 1.1rem; border: 1px solid var(--line-strong); border-radius: var(--radius-lg); background: rgba(26, 49, 64, .97); backdrop-filter: blur(8px); }
.exam-clock { font: 600 1.35rem/1 var(--mono); font-variant-numeric: tabular-nums; color: var(--text); }
.exam-clock.is-low { color: var(--gold); }
.exam-progress { flex: 1 1 200px; }
.exam-progress span { display: block; font-size: .85rem; color: var(--text-2); margin-bottom: .35rem; }
.question { margin: 0 0 1.25rem; padding: 1.4rem 1.5rem; border: 1px solid var(--line); border-radius: var(--radius-lg); background: var(--surface); }
.question legend { float: left; width: 100%; padding: 0; margin: 0 0 1rem; color: var(--text); font: 500 1.08rem/1.55 var(--sans); }
.question legend .q-n { display: block; font: 600 12px/1.4 var(--mono); letter-spacing: .08em; color: var(--accent); margin-bottom: .35rem; }
.question .options { clear: both; display: grid; gap: .5rem; }
.option { display: flex; gap: .85rem; align-items: flex-start; margin: 0; padding: .8rem 1rem; border: 1px solid var(--line-strong); border-radius: var(--radius); background: var(--bg-2); color: var(--text); font-weight: 400; cursor: pointer; transition: border-color .12s, background .12s; }
.option:hover { border-color: var(--accent); }
.option:has(input:checked) { border-color: var(--accent); background: rgba(153, 210, 199, .1); }
.option input { margin-top: 3px; }
.exam-submit { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 1rem; padding: 1.25rem 1.5rem; border: 1px solid var(--line-strong); border-radius: var(--radius-lg); background: var(--surface-2); }

.result-hero { text-align: center; padding: 2.5rem 1.5rem; border: 1px solid var(--line); border-radius: var(--radius-lg); background: var(--surface); }
.result-hero .result-score { display: block; font: 400 clamp(4rem, 12vw, 6.5rem)/1 var(--serif); margin: .5rem 0; }
.result-hero.is-pass { border-top: 4px solid var(--ok); }
.result-hero.is-fail { border-top: 4px solid var(--gold); }
.result-hero p { margin-inline: auto; }

.study { max-width: 72ch; }
.study p { font-size: 1.06rem; line-height: 1.75; color: #e3e8e9; max-width: none; }
.study .authorities dt { margin-top: 0.9rem; font-weight: 600; color: #e3e8e9; }
.study .authorities dd { margin: 0.2rem 0 0; color: #b9c2c4; line-height: 1.6; }
.study-nav { display: flex; flex-direction: column; gap: 2px; }
.study-nav a { display: flex; gap: .75rem; align-items: center; min-height: 42px; padding: .35rem .75rem; border-radius: var(--radius); color: var(--text-2); text-decoration: none; }
.study-nav a:hover { background: var(--surface); color: var(--text); }
.study-nav a[aria-current="page"] { background: var(--surface-2); color: var(--text); font-weight: 600; }

/* --- responsive -------------------------------------------------------------------- */
@media (max-width: 1000px) {
    .grid-2, .split { grid-template-columns: 1fr; }
    .sticky { position: static; }
    .score-grid, .facts { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .candidate-row { grid-template-columns: minmax(0, 1fr) repeat(4, minmax(56px, auto)); }
    .candidate-row > :nth-child(n+6) { grid-column: 1 / -1; }
    .candidate-head { display: none; }
}
@media (max-width: 700px) {
    .wrap, .ov-shell, .ov-intake-inner { width: calc(100% - 32px); }
    .ov-nav { padding-inline: 16px; }
    .ov-app main > .wrap { padding-top: 1.5rem; }
    .grid-halves, .form-grid { grid-template-columns: 1fr; }
    .onboarding-steps li, .journey li { border-right: 0; border-bottom: 1px solid var(--line); }
    .module-list li { grid-template-columns: 36px minmax(0, 1fr); }
    .module-actions { grid-column: 1 / -1; justify-content: flex-start; }
    .candidate-row { grid-template-columns: repeat(4, minmax(0, 1fr)); }
    .candidate-row > :first-child { grid-column: 1 / -1; }
    .exam-bar { top: 70px; }
    .question { padding: 1.1rem; }
    dl.kv { grid-template-columns: 1fr; gap: .15rem; }
    dl.kv dd { margin-bottom: .6rem; }
    .cole-hero { padding: 3rem 0 2.5rem; }
    .cole-page > .flash { width: calc(100% - 32px); }
    .panel, .card { padding: 1.15rem; }
    .btn { white-space: normal; }
}
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}
@media print {
    body { background: #fff; color: #000; }
    .ov-header, .ov-footer, .ov-intake-banner, .exam-bar { display: none; }
}
