/* EasyShortlist styles (T30 design refresh). Tokens first; every component uses tokens only.
   Look: cool grey-green neutrals, emerald for actions, highlighter yellow only where something is picked out
   (top matches, the selected thing), the way a recruiter marks up a paper CV. Public pages sell in wide bands;
   the app is dense. New layout rules use logical properties (inline/block, start/end) so the UI mirrors for RTL. */

@font-face { font-family: "Inter"; font-style: normal; font-weight: 400 600; font-display: swap;
  src: url("fonts/inter.woff2") format("woff2"); }
@font-face { font-family: "Bricolage Grotesque"; font-style: normal; font-weight: 500 700; font-display: swap;
  src: url("fonts/bricolage-grotesque.woff2") format("woff2"); }
@font-face { font-family: "JetBrains Mono"; font-style: normal; font-weight: 500 600; font-display: swap;
  src: url("fonts/jetbrains-mono.woff2") format("woff2"); }

:root {
  --ground: #f5f6f4; --surface: #ffffff; --ink: #111816; --ink-2: #3d4643; --muted: #59625f;
  --line: #dce0dd; --line-2: #c9cfcb; --fill: #eceeed; --fill-2: #dce0dd;
  --accent: #0e6b57; --accent-ink: #ffffff; --accent-soft: #e3f1ec; --accent-deep: #0a4f40; --accent-2: #6fa897;
  --mark: #ffe58a; --mark-soft: #fff6cc; --mark-line: #f0e3a8; --mark-ink: #111816;
  --bar: #111816; --bar-ink: #f5f6f4; --bar-muted: #c7cfcb; --bar-fill: #1e2926;
  --dark: #111816; --dark-ink: #f5f6f4; --dark-muted: #b9c2be; --dark-line: #2f3a36; --dark-card: #18221f;
  --ok: #0a4f40; --ok-soft: #e3f1ec; --warn: #6e4700; --warn-soft: #fbf0d6; --bad: #8e2018; --bad-soft: #fbe4e1;
  --focus: #0e6b57; --shadow: 0 24px 60px -28px rgba(17, 24, 22, 0.35);
  --font-body: "Inter", "Segoe UI", system-ui, -apple-system, sans-serif;
  --font-display: "Bricolage Grotesque", "Segoe UI", system-ui, sans-serif;
  --font-mono: "JetBrains Mono", ui-monospace, Menlo, monospace;
  --wrap: 1200px; --gutter: max(16px, env(safe-area-inset-left, 0px));
  color-scheme: light;
}
/* Dark tokens: follow the OS unless the viewer picked a theme (theme.js sets data-theme on <html>). */
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --ground: #0e1412; --surface: #151d1a; --ink: #e8edea; --ink-2: #c3ccc8; --muted: #9aa6a1;
    --line: #26322e; --line-2: #34423d; --fill: #1c2622; --fill-2: #2a3632;
    --accent: #3fb393; --accent-ink: #08140f; --accent-soft: #15302a; --accent-deep: #8fdcc4; --accent-2: #2e7f69;
    --mark: #f2d46b; --mark-soft: #2b2815; --mark-line: #4a4220; --mark-ink: #111816;
    --bar: #0a0f0d; --bar-ink: #e8edea; --bar-muted: #a9b4af; --bar-fill: #17201d;
    --dark: #0a0f0d; --dark-ink: #e8edea; --dark-muted: #a9b4af; --dark-line: #26322e; --dark-card: #121a17;
    --ok: #8fdcc4; --ok-soft: #15302a; --warn: #f0c46e; --warn-soft: #3a2b12; --bad: #ff9a90; --bad-soft: #3d1c1a;
    --focus: #3fb393; --shadow: 0 24px 60px -28px rgba(0, 0, 0, 0.7);
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --ground: #0e1412; --surface: #151d1a; --ink: #e8edea; --ink-2: #c3ccc8; --muted: #9aa6a1;
  --line: #26322e; --line-2: #34423d; --fill: #1c2622; --fill-2: #2a3632;
  --accent: #3fb393; --accent-ink: #08140f; --accent-soft: #15302a; --accent-deep: #8fdcc4; --accent-2: #2e7f69;
  --mark: #f2d46b; --mark-soft: #2b2815; --mark-line: #4a4220; --mark-ink: #111816;
  --bar: #0a0f0d; --bar-ink: #e8edea; --bar-muted: #a9b4af; --bar-fill: #17201d;
  --dark: #0a0f0d; --dark-ink: #e8edea; --dark-muted: #a9b4af; --dark-line: #26322e; --dark-card: #121a17;
  --ok: #8fdcc4; --ok-soft: #15302a; --warn: #f0c46e; --warn-soft: #3a2b12; --bad: #ff9a90; --bad-soft: #3d1c1a;
  --focus: #3fb393; --shadow: 0 24px 60px -28px rgba(0, 0, 0, 0.7);
  color-scheme: dark;
}

* { box-sizing: border-box; }
html, body { margin: 0; }
[hidden] { display: none !important; } /* components set display (grid, flex); hidden must still win */
body { background: var(--ground); color: var(--ink); font: 400 15px/1.5 var(--font-body); min-height: 100vh;
  display: flex; flex-direction: column; -webkit-font-smoothing: antialiased; }
a { color: var(--accent); }
a:hover { color: var(--accent-deep); }
:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; }
h1, h2, h3 { font-family: var(--font-display); margin: 0; text-wrap: balance; letter-spacing: -0.01em; }
p { margin: 0; }
kbd { font-family: var(--font-mono); font-size: 11px; }

/* ---- header ---- */
.topbar { border-block-end: 1px solid var(--line); background: var(--surface); }
.topbar .bar { max-width: var(--wrap); margin: 0 auto; display: flex; flex-wrap: wrap; align-items: center; gap: 10px 28px;
  padding-block: 12px; padding-inline: var(--gutter); }
.brand { font: 700 19px var(--font-display); text-decoration: none; color: var(--ink); display: inline-flex; align-items: center; gap: 8px; }
.brand:hover { color: var(--ink); }
.brand-mark { width: 22px; height: 22px; border-radius: 6px; background: var(--accent); display: inline-grid; place-items: center; flex: none; }
.brand-mark i { width: 10px; height: 4px; border-radius: 2px; background: var(--mark); }
.nav { display: flex; flex-wrap: wrap; gap: 4px; }
.nav a { color: var(--ink-2); text-decoration: none; padding: 7px 12px; border-radius: 7px; }
.nav a:hover { color: var(--ink); background: var(--fill); }
.right { margin-inline-start: auto; display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.theme-btn { padding: 6px; line-height: 0; }
.theme-btn[hidden] { display: none; }
.theme-btn svg { width: 18px; height: 18px; }
.theme-btn .sun { display: none; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .theme-btn .sun { display: inline; } :root:not([data-theme="light"]) .theme-btn .moon { display: none; } }
:root[data-theme="dark"] .theme-btn .sun { display: inline; }
:root[data-theme="dark"] .theme-btn .moon { display: none; }
.credits { font: 500 13px var(--font-mono); padding: 4px 10px; border: 1px solid var(--line-2); border-radius: 999px;
  text-decoration: none; color: var(--ink); font-variant-numeric: tabular-nums; }
.credits.low { border-color: var(--warn); color: var(--warn); }

/* the signed-in app gets a dark bar */
.topbar.app { background: var(--bar); border-block-end-color: var(--bar); }
.topbar.app .bar { max-width: 1360px; padding-block: 9px; }
.topbar.app .brand, .topbar.app .brand:hover { color: var(--bar-ink); font-size: 18px; }
/* One brand mark on every page: the emerald square from the marketing header, in the app bar too (T41). */
.topbar.app .nav a { color: var(--bar-muted); }
.topbar.app .nav a:hover { color: var(--bar-ink); background: var(--bar-fill); }
.topbar.app .nav a.on { color: var(--bar); background: var(--bar-ink); font-weight: 600; }
.topbar.app .credits { color: var(--mark); border-color: transparent; }
.topbar.app .credits.low { color: var(--warn-soft); border-color: var(--warn-soft); }
.topbar.app .btn.ghost { color: var(--bar-muted); }
.topbar.app .btn.ghost:hover { color: var(--bar-ink); background: var(--bar-fill); }

/* ---- page areas ---- */
.body { flex: 1; width: 100%; max-width: 1360px; margin: 0 auto; display: grid; gap: 16px; align-content: start;
  padding-block: 22px 36px; padding-inline: var(--gutter); }
.mkt { flex: 1; width: 100%; display: flex; flex-direction: column; }
.wrap { width: 100%; max-width: var(--wrap); margin: 0 auto; padding-inline: var(--gutter); }

.foot { border-block-start: 1px solid var(--line); }
.foot > * { max-width: var(--wrap); margin: 0 auto; padding-inline: var(--gutter); }
.foot .legal { display: flex; flex-wrap: wrap; gap: 6px 22px; font-size: 13px; padding-block: 18px 4px; }
.foot .legal a { color: var(--muted); }
.foot .legal a:hover { color: var(--ink); }
.foot .fine, .foot .advisory { font-size: 12px; color: var(--muted); padding-block: 4px 20px; }

/* ---- type and text ---- */
.title { font-size: 26px; font-weight: 700; }
.h2 { font: 700 38px/1.12 var(--font-display); letter-spacing: -0.015em; max-width: 22em; }
.sub { color: var(--ink-2); }
.lead { font-size: 18px; color: var(--ink-2); max-width: 36em; }
.small { font-size: 13px; color: var(--muted); }
.small.warn { color: var(--warn); font-weight: 600; }

.lbl { font-size: 12px; font-weight: 600; color: var(--muted); text-transform: uppercase; letter-spacing: 0.06em; }
.kicker { font: 500 13px var(--font-mono); letter-spacing: 0.06em; text-transform: uppercase; color: var(--accent); }
.error { font-size: 13px; color: var(--bad); }
.marker { background: linear-gradient(transparent 58%, var(--mark) 58%); padding: 0 4px; color: inherit; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .marker { background: linear-gradient(transparent 62%, var(--accent-2) 62%); } }
:root[data-theme="dark"] .marker { background: linear-gradient(transparent 62%, var(--accent-2) 62%); }

/* ---- layout helpers ---- */
.row { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.between { justify-content: space-between; }
.stack { display: grid; gap: 12px; }
.stack-tight { display: grid; gap: 2px; }
.stack-lg { display: grid; gap: 36px; }
.grid2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.narrow { max-width: 560px; }
.right-align { text-align: end; }
.num { text-align: end; font-variant-numeric: tabular-nums; }
form.inline { display: inline; }

/* ---- surfaces ---- */
.panel { background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 16px 18px; display: grid; gap: 10px; min-width: 0; }
.panel.empty { text-align: center; justify-items: center; padding: 40px 18px; gap: 12px; }
.tiles { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 10px; }
.tiles .panel { padding: 12px 14px; gap: 2px; }
.tiles .score { font-size: 22px; }
.flag { border: 1px solid var(--mark-line); background: var(--mark-soft); border-radius: 10px; padding: 10px 14px; font-size: 14px; color: var(--ink); }
/* Server-chosen notices under a page heading (T44). Tokens only, so both themes follow. */
.notice { border: 1px solid var(--line); border-inline-start: 3px solid var(--accent); background: var(--fill);
  color: var(--ink); border-radius: 10px; padding: 9px 12px; font-size: 13px; }
.notice:empty { display: none; }
/* A refused material (T102): warning colours only, so both themes follow the existing tokens. */
.notice.warn { border-color: var(--warn); border-inline-start-color: var(--warn); background: var(--warn-soft); }
/* Review brief (the recruiter's own question answered): verdict, alignment, strengths, what to confirm. It sits above
   the evidence table, so the claim and the proof are read in one screen. */
.brief { display: grid; gap: 8px; }
.brief-head { align-items: baseline; }
.brief-verdict { align-items: baseline; gap: 10px; flex-wrap: wrap; }
.brief-verdict .score { font-size: 20px; font-weight: 700; }
.brief-verdict .score small { font-size: 12px; font-weight: 500; color: var(--muted); }
.brief-reason { margin: 0; font-size: 14px; }
.brief-cols { display: grid; gap: 14px 24px; grid-template-columns: 1fr 1fr; }
@media (max-width: 760px) { .brief-cols { grid-template-columns: 1fr; } }
.brief-list { margin: 6px 0 0; padding-inline-start: 18px; display: grid; gap: 8px; font-size: 13px; }
.brief-list li b { display: block; font-weight: 600; }
.brief-list .quote { margin: 4px 0 0; }
.draft { border: 1px dashed var(--warn); background: var(--warn-soft); color: var(--ink); padding: 10px 12px; border-radius: 10px; font-size: 14px; }
.danger-zone { border-color: var(--bad); }
details > summary { cursor: pointer; font-weight: 600; }

/* ---- controls ---- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; min-height: 40px; padding: 8px 15px;
  border-radius: 8px; border: 1px solid var(--line-2); background: var(--surface); color: var(--ink);
  font: 500 14px var(--font-body); text-decoration: none; cursor: pointer; transition: background-color .12s, border-color .12s; }
.btn:hover { color: var(--ink); border-color: var(--ink-2); }
.btn.primary { background: var(--accent); color: var(--accent-ink); border-color: var(--accent); font-weight: 600; }
.btn.primary:hover { background: var(--accent-deep); border-color: var(--accent-deep); color: var(--accent-ink); }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .btn.primary:hover { background: var(--accent); filter: brightness(1.1); } }
:root[data-theme="dark"] .btn.primary:hover { background: var(--accent); filter: brightness(1.1); }
.btn.mark { background: var(--mark); color: var(--mark-ink); border-color: var(--mark); font-weight: 600; }
.btn.danger { color: var(--bad); border-color: var(--bad); }
.btn.danger:hover { background: var(--bad-soft); }
.btn.ghost { border-color: transparent; background: transparent; color: var(--ink-2); }
.btn.ghost:hover { background: var(--fill); }
.btn.lg { min-height: 48px; padding: 12px 22px; font-size: 16px; border-radius: 10px; }
.btn[disabled] { opacity: .5; cursor: not-allowed; }

/* Autofill panel (T69b): the fast path sits above the fields it fills, as one clearly bounded unit. Two identical
   grey buttons side by side read as "which one?" — so the picker is a drop target and there is exactly one action,
   disabled until a file is chosen (JS only; without JS the button stays enabled and the form submit is unchanged). */
.autofill { border: 1px solid var(--line); background: var(--fill); border-radius: 12px; padding: 12px 14px;
  display: grid; gap: 9px; }
.autofill-head { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 10px; }
.autofill-head .field-label { font-size: 13px; font-weight: 600; }
.autofill .drop { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; border: 1px dashed var(--line-2);
  border-radius: 10px; padding: 10px 12px; background: var(--surface); transition: border-color .12s, background .12s; }
.autofill .drop.hot { border-color: var(--accent); background: var(--fill); }
.autofill .drop .btn { flex: 0 0 auto; }
.autofill .fname { font-size: 13px; color: var(--muted); min-width: 0; overflow: hidden; text-overflow: ellipsis;
  white-space: nowrap; }
.autofill .fname.has { color: var(--ink); font-weight: 600; }
.autofill input:focus-visible + .btn { outline: 2px solid var(--focus); outline-offset: 2px; }
.autofill .go { justify-self: start; }
/* A 50%-opacity green button still reads as "click me". Until a file is chosen the action is not available, so it
   drops its accent colour entirely. */
.autofill .go[disabled] { background: var(--line); color: var(--muted); opacity: 1; box-shadow: none; }
.autofill .go[aria-busy="true"] { opacity: 1; background: var(--line); border-color: transparent; color: var(--ink); cursor: progress; }
.autofill .spinner { inline-size: 13px; block-size: 13px; border: 2px solid currentColor; border-block-start-color: transparent;
  border-radius: 50%; animation: spin .7s linear infinite; }
@keyframes spin { to { rotate: 360deg; } }
@media (prefers-reduced-motion: reduce) { .autofill .spinner { animation: none; } }

.field { display: grid; gap: 6px; min-width: 0; }
.field label { font-size: 13px; font-weight: 600; }
/* File picker (T44): the label is the button, the real input is visually hidden but still focusable. */
.file { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; }
.file .btn { cursor: pointer; font: 500 14px var(--font-body); }
.file input:focus-visible + .btn { outline: 2px solid var(--focus); outline-offset: 2px; }
input, textarea, select { font: 400 14px var(--font-body); color: var(--ink); background: var(--surface);
  border: 1px solid var(--line-2); border-radius: 8px; padding: 9px 11px; width: 100%; }
input:focus-visible, textarea:focus-visible, select:focus-visible { outline: 2px solid var(--focus); outline-offset: 0; border-color: var(--focus); }
.wt { width: 80px; text-align: end; font-family: var(--font-mono); }
.crit-weight-cell .seg { flex-wrap: nowrap; }
.check { display: flex; gap: 8px; align-items: flex-start; font-size: 14px; }
.check input { width: auto; margin-block-start: 3px; accent-color: var(--accent); }

.pill { display: inline-flex; align-items: center; font-size: 12px; font-weight: 600; padding: 3px 9px; border-radius: 999px;
  white-space: nowrap; background: var(--fill); color: var(--ink-2); }
.pill.ok { background: var(--ok-soft); color: var(--ok); }
.pill.warn { background: var(--warn-soft); color: var(--warn); }
.pill.bad { background: var(--bad-soft); color: var(--bad); }
.pill.must { background: var(--ink); color: var(--surface); border-radius: 4px; font-size: 11px; letter-spacing: 0.04em; }
.pill.solid { background: var(--accent); color: var(--accent-ink); }

/* ---- tables (dense) ---- */
.tablewrap { overflow-x: auto; border: 1px solid var(--line); border-radius: 12px; background: var(--surface); }
table { width: 100%; border-collapse: collapse; font-size: 14px; font-variant-numeric: tabular-nums; }
th { text-align: start; font-size: 11px; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); font-weight: 600;
  padding: 10px 12px; border-block-end: 1px solid var(--line); white-space: nowrap; }
td { padding: 9px 12px; border-block-end: 1px solid var(--line); vertical-align: middle; }
tr:last-child td { border-block-end: 0; }
tbody tr:hover td { background: var(--ground); }
table.compact td { padding: 5px 10px; }

/* ---- scores and evidence ---- */
.score { font: 600 18px var(--font-mono); font-variant-numeric: tabular-nums; }
.score.big { font-size: 40px; line-height: 1; }
.score.dim { color: var(--muted); }
.bars { display: inline-flex; gap: 3px; vertical-align: middle; margin-inline-end: 6px; }
.bars i { width: 18px; height: 8px; border-radius: 2px; background: var(--fill-2); display: block; }
.bars i.on { background: var(--accent); }
.quote { border-inline-start: 3px solid var(--line-2); margin: 0 0 6px; padding: 2px 0; padding-inline-start: 10px; font-size: 14px; }
.redacted { white-space: pre-wrap; font-family: var(--font-mono); font-size: 13px; background: var(--fill); padding: 12px; border-radius: 8px; overflow-x: auto; }

/* ---- auth ---- */
.auth { max-width: 440px; margin: 24px auto 0; width: 100%; background: var(--surface); border: 1px solid var(--line);
  border-radius: 14px; padding: 28px; display: grid; gap: 16px; }
.secret { font-family: var(--font-mono); font-size: 13px; background: var(--fill); padding: 6px 8px; border-radius: 6px; word-break: break-all; }
.qr { border-radius: 8px; background: #fff; padding: 6px; }

/* ---- legal ---- */
.legal-doc { max-width: 72ch; gap: 14px; }
.legal-doc h2 { margin-block-start: 22px; font-size: 20px; }
.legal-doc ul { padding-inline-start: 20px; display: grid; gap: 8px; margin: 0; }

/* ---- public pages ---- */
.hero { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 440px), 1fr)); gap: 56px; align-items: center;
  padding-block: 72px 64px; }
.hero-copy { display: grid; gap: 22px; min-width: 0; }
.hero h1 { font-size: clamp(38px, 5.2vw, 60px); line-height: 1.04; letter-spacing: -0.025em; font-weight: 700; }
.preview { background: var(--surface); border: 1px solid var(--line); border-radius: 16px; box-shadow: var(--shadow); overflow: hidden; min-width: 0; }
.preview-head { padding: 14px 20px; border-block-end: 1px solid var(--line); display: flex; flex-wrap: wrap; gap: 6px 14px; align-items: baseline; }
.preview-head b { font: 700 18px var(--font-display); }
.preview-row { display: grid; grid-template-columns: 52px minmax(0, 1fr) auto; gap: 14px; align-items: center; padding: 13px 20px;
  border-block-end: 1px solid var(--line); }
.preview-row.top { background: var(--mark-soft); border-block-end-color: var(--mark-line); }
.preview-row .score { font-size: 24px; }
.who { display: grid; min-width: 0; }
.who b { font-weight: 600; }
.preview-why { padding: 14px 20px; background: var(--ground); display: grid; gap: 6px; }
.preview-why .quote { border-inline-start-color: var(--mark); margin: 0; }

.band { background: var(--surface); border-block: 1px solid var(--line); padding-block: 72px; }
.band.dark { background: var(--dark); color: var(--dark-ink); border-color: var(--dark); }
.band.dark .lead, .band.dark p { color: var(--dark-muted); }
.band.dark .lbl { color: var(--dark-muted); }
.cards3 { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 290px), 1fr)); gap: 20px; }
.card { border: 1px solid var(--line); border-radius: 14px; padding: 24px; display: grid; gap: 10px; align-content: start; }
.card h3 { font-size: 22px; }
.card p { color: var(--ink-2); }
.step { font: 600 13px var(--font-mono); color: var(--accent); }
.band.dark .card { border-color: var(--dark-line); }
.card.price { gap: 14px; }
.card.price .btn { margin-block-start: auto; }
/* Only the dark highlighted cards get light button text; the light free card keeps the normal button (was invisible in the light theme). */
.card.price.hi .btn { background: transparent; color: var(--dark-ink); border-color: var(--dark-line); }
.card.price .btn.mark { background: var(--mark); color: var(--mark-ink); border-color: var(--mark); }
.card.price.hi { border: 2px solid var(--mark); background: var(--dark-card); color: var(--dark-ink); }
/* The highlighted pack cards are dark in both themes, so their text uses the dark-surface tokens (it was ink-on-dark,
   unreadable in the light theme). */
.card.price.hi .lbl, .card.price.hi p { color: var(--dark-muted); }
.price-v { font: 700 36px var(--font-display); }
.price-v small { font-size: 17px; font-weight: 500; color: var(--dark-muted); }
.features { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 320px), 1fr)); gap: 36px 56px; padding-block: 72px; }
.features > div { display: grid; gap: 10px; align-content: start; }
.features h3 { font-size: 23px; }
.features p { color: var(--ink-2); }
.closer { display: flex; flex-wrap: wrap; gap: 24px; align-items: center; justify-content: space-between; padding-block: 64px; }

@media (max-width: 600px) {
  .grid2 { grid-template-columns: minmax(0, 1fr); }
  .h2 { font-size: 30px; }
  .hero { padding-block: 44px 40px; gap: 36px; }
  .band, .features { padding-block: 48px; }
  .topbar.public .nav { order: 3; width: 100%; }
}
@media (prefers-reduced-motion: reduce) { * { transition: none !important; animation: none !important; } }
.topbar.app ~ .foot > * { max-width: 1360px; }
/* buttons size to their label inside grid panels and stacks */
.btn { justify-self: start; }
.panel.empty .btn { justify-self: center; }

/* extension slots (T40) */
.toolbar { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.toolbar-end { margin-inline-start: auto; display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.cand-grid { display: flex; flex-wrap: wrap; gap: 18px; align-items: flex-start; }
.cand-main { flex: 999 1 560px; min-width: 0; }
.cand-side { flex: 1 1 340px; min-width: 0; }
/* sign-up bot check: reserve its space so the button does not jump when it loads */
.turnstile { min-height: 65px; }

/* shortlist (T34) */
.dec { display: inline-flex; border: 1px solid var(--line-2); border-radius: 8px; overflow: hidden; background: var(--surface); }
.dec button { font: 500 13px var(--font-body); border: 0; border-inline-start: 1px solid var(--line-2); background: transparent;
  color: var(--ink-2); padding: 7px 11px; min-height: 36px; cursor: pointer; }
.dec button:first-of-type { border-inline-start: 0; }
.dec button:hover { background: var(--fill); }
.dec.compact button { font-size: 12px; padding: 5px 9px; min-height: 30px; }
.dec button[aria-pressed="true"].dec-shortlist { background: var(--accent); color: var(--accent-ink); font-weight: 600; }
.dec button[aria-pressed="true"].dec-maybe { background: var(--warn-soft); color: var(--warn); font-weight: 600; }
.dec button[aria-pressed="true"].dec-no { background: var(--fill-2); color: var(--ink); font-weight: 600; }
#results tr:has(form.dec[data-decision="shortlist"]) td { background: var(--mark-soft); }
#results tr.current td { box-shadow: inset 0 0 0 9999px rgba(14, 107, 87, 0.06); }
#results tr.current td:first-child { box-shadow: inset 3px 0 0 var(--accent); }
.seg { display: inline-flex; flex-wrap: wrap; gap: 2px; padding: 3px; background: var(--fill); border-radius: 9px; }
.seg a { text-decoration: none; color: var(--ink-2); padding: 6px 11px; border-radius: 7px; font-size: 13px; }
.seg a.on { background: var(--surface); color: var(--ink); font-weight: 600; box-shadow: 0 1px 2px rgba(0,0,0,.08); }
.seg .count { font-family: var(--font-mono); font-size: 12px; color: var(--muted); }
input.pick { width: 16px; height: 16px; accent-color: var(--accent); }
.note { display: grid; gap: 2px; padding-block: 6px; border-block-end: 1px solid var(--line); }
.h3 { font: 700 18px var(--font-display); }
table.compare td.best { background: var(--accent-soft); color: var(--ok); font-weight: 600; }

/* ---- T37 interview questions ---- */
#questions .notice { background: var(--warn-soft); color: var(--ink); border-radius: 8px; padding: 8px 10px; }
.questions { margin: 0; padding-inline-start: 22px; display: grid; gap: 10px; }
.questions li { padding-inline-start: 2px; }
.questions .lbl { display: block; margin-block-end: 2px; }

/* ---- Recruiter tools (wireframe P3) ---- */
.vh { position: absolute; inline-size: 1px; block-size: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.tools fieldset { border: 0; margin: 0; padding: 0; min-width: 0; }
.tools legend { padding: 0; font-size: 13px; font-weight: 600; }
.field .field-label { font-size: 13px; font-weight: 600; }
.tools legend.small { font-weight: 400; }
.tool-tabs { justify-self: start; }
.tool-inputs { align-items: end; }
.tool-inputs .amount input { inline-size: 9.5em; }
.tool-inputs .num-field input { inline-size: 6em; }

/* Segmented radios: the same look as .seg links, keyboard and screen-reader native. */
.seg-radio label { position: relative; display: inline-flex; }
.seg-radio input { position: absolute; opacity: 0; inset: 0; margin: 0; cursor: pointer; }
.seg-radio span { color: var(--ink-2); padding: 6px 11px; border-radius: 7px; font-size: 13px; }
.seg-radio input:checked + span { background: var(--surface); color: var(--ink); font-weight: 600; box-shadow: 0 1px 2px rgba(0,0,0,.08); }
.seg-radio input:focus-visible + span { outline: 2px solid var(--focus); outline-offset: 1px; }

/* Currency chips: checkboxes that look like toggles. */
.chips { display: flex; flex-wrap: wrap; gap: 6px; }
.chip { position: relative; display: inline-flex; }
.chip input { position: absolute; opacity: 0; inset: 0; margin: 0; cursor: pointer; }
.chip span { font: 500 12px var(--font-mono); padding: 4px 9px; border-radius: 999px; border: 1px solid var(--line-2);
  color: var(--ink-2); background: var(--surface); }
.chip input:checked + span { background: var(--accent-soft); border-color: var(--accent); color: var(--accent-deep); }
.chip input:disabled + span { opacity: .45; }
.chip input:focus-visible + span { outline: 2px solid var(--focus); outline-offset: 1px; }

/* Hour grid: one row per city, 24 cells aligned to the same instants, one selected column. */
.tzwrap { border: 0; background: transparent; }
.tz { display: grid; grid-template-columns: 196px minmax(0, 1fr); min-width: 700px; border: 1px solid var(--line);
  border-radius: 10px; overflow: hidden; background: var(--surface); }
.tz:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; }
.tz .city { position: sticky; inset-inline-start: 0; z-index: 1; background: var(--surface); display: grid; gap: 1px;
  align-content: center; padding: 7px 28px 7px 12px; border-block-end: 1px solid var(--line); border-inline-end: 1px solid var(--line);
  min-width: 0; transition: background .12s; }
.tz .city.hov { background: color-mix(in srgb, var(--mark) 25%, var(--surface)); }
.tz .city b { font-size: 13px; }
.tz .city .small { font-size: 11px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tz .hours { display: grid; grid-template-columns: repeat(24, minmax(0, 1fr)); border-block-end: 1px solid var(--line); }
.tz .city:nth-last-child(2), .tz .hours:last-child { border-block-end: 0; }
.tz .hours > span { position: relative; display: grid; place-items: center; align-content: center; min-block-size: 44px;
  font: 600 12px var(--font-mono); line-height: 1.05; color: var(--muted); border-inline-start: 1px solid var(--fill);
  cursor: pointer; user-select: none; transition: background .12s, color .12s; }
.tz .hours > span small { font: 500 9px system-ui; letter-spacing: .03em; opacity: .8; }
.tz .hours .w { background: var(--ok-soft); color: var(--ok); }
.tz .hours .n { background: var(--ground); } /* darker than the surface in both themes */
.tz .hours .day { border-inline-start: 2px solid var(--ink); }
.tz .hours .day small { font-weight: 700; opacity: 1; }
.tz .hours .hov { background: color-mix(in srgb, var(--mark) 45%, transparent); color: var(--ink); }
.tz .hours .sel { outline: 2px solid var(--mark); outline-offset: -2px; color: var(--mark-ink); font-weight: 700; background: var(--mark); }
.tz .hours .now::after { content: ""; position: absolute; inset-block-start: 0; inset-inline: 2px; block-size: 3px;
  border-radius: 0 0 3px 3px; background: var(--bad); }
.tz-remove { position: absolute; inset-inline-end: 6px; inset-block-start: 50%; transform: translateY(-50%);
  inline-size: 22px; block-size: 22px; padding: 0; border: 0; border-radius: 6px; background: transparent;
  color: var(--muted); font-size: 16px; line-height: 1; cursor: pointer; }
.tz-remove:hover { background: var(--fill); color: var(--ink); }
.tz-remove:disabled { visibility: hidden; }

/* Legend chips, clock toggle and the result card below the grid. */
.tz-legend { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 16px; font-size: 12px; color: var(--muted); }
.tz-legend .sw { display: inline-block; inline-size: 12px; block-size: 12px; border-radius: 3px; vertical-align: -2px;
  margin-inline-end: 5px; border: 1px solid var(--line); }
.tz-legend .sw.w { background: var(--ok-soft); }
.tz-legend .sw.n { background: var(--ground); }
.tz-legend .sw.day { border-inline-start: 2px solid var(--ink); }
.tz-legend .sw.now { block-size: 4px; background: var(--bad); }
.tz-clock { font: inherit; color: var(--muted); background: transparent; border: 0; padding: 2px 4px; cursor: pointer; }
.tz-clock .on { color: var(--ink); font-weight: 600; text-decoration: underline; }
.tz-clock:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; }
.tz-card { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; border: 1px solid var(--line);
  border-radius: 10px; padding: 10px 12px; background: var(--surface); }
.tz-card .lbl { inline-size: 100%; }
.tz-card .chips { gap: 8px; }
.tz-card .chip { border: 1px solid var(--line); border-radius: 999px; padding: 3px 10px; font-size: 13px;
  background: var(--ground); }
.tz-card .chip b { font-weight: 600; font-variant-numeric: tabular-nums; }
.tz-card .btn { margin-inline-start: auto; }
.tz-copyline { flex-basis: 100%; user-select: all; }
#tz-date, #tz-add-zone { min-block-size: 40px; inline-size: auto; }
#tz-add-zone { max-inline-size: 12em; }

/* ---- phone layouts (T45) ---- */
/* Jobs list: wide screens keep the table; below 640px each job is a card with the same data, so nothing scrolls
   sideways and Open/Edit are never off-screen. */
.job-cards { display: none; }
.job-card { gap: 6px; padding: 14px 16px; }
.job-card .score { font-size: 20px; }

/* The re-score banner borrows the T44 notice look; only the row layout is added here. */
.banner { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px 16px; }
.banner .end { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-inline-start: auto; }

/* Decision buttons stay on one line, with tighter padding on narrower screens. */
.dec button { white-space: nowrap; }

/* Live status, Refresh and the toolbar actions share one row and wrap together only when they must. */
.results-toolbar .live { white-space: nowrap; }

@media (max-width: 900px) {
  .dec button { padding: 6px 8px; }
  .dec.compact button { padding: 4px 7px; }
}

@media (max-width: 639px) {
  .job-table { display: none; }
  .job-cards { display: grid; gap: 10px; }

  /* Criteria editor: the criterion takes the full width, then type, weight and Remove on one line. */
  .crit-wrap { border: 0; background: transparent; overflow-x: visible; }
  .crit-table, .crit-table tbody { display: block; }
  .crit-table thead { display: none; }
  .crit-table tbody { display: grid; gap: 12px; }
  .crit-row { display: grid; grid-template-columns: auto auto minmax(0, 1fr); gap: 8px; align-items: center;
    border: 1px solid var(--line); border-radius: 10px; background: var(--surface); padding: 10px 12px; }
  .crit-row td { display: block; padding: 0; border: 0; }
  .crit-row .crit-label-cell { grid-area: 1 / 1 / 2 / -1; }
  .crit-row .crit-kind-cell { grid-area: 2 / 1; }
  .crit-row .crit-weight-cell { grid-area: 2 / 2; }
  .crit-row .crit-remove-cell { grid-area: 2 / 3; justify-self: end; }
  .crit-row .crit-weight-cell .seg { flex-wrap: wrap; }
}

/* Guidance for the AI dialog (V30): panel tokens only, so both themes come from the palette. */
dialog.guidance { background: var(--surface); color: var(--ink); border: 1px solid var(--line); border-radius: 12px;
  padding: 16px 18px; max-width: 40rem; width: calc(100% - 32px); box-shadow: var(--shadow); }
dialog.guidance::backdrop { background: var(--ink); opacity: 0.35; }

/* ---- T38 interview notes ---- */
/* Before -> after score and the results-table delta (wireframe A4/v2). */
.delta { font: 600 12px var(--font-mono); color: var(--ok); }
.interview-score { gap: 8px; align-items: baseline; }
.interview-evidence { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.interview-evidence li { display: grid; gap: 4px; }
.interview-evidence .lbl { font-weight: 600; }
/* Evidence quote source tag: CV text or interview notes. */
.src { display: inline-block; border-radius: 999px; padding: 1px 6px; font: 600 10px var(--font-mono);
  text-transform: uppercase; letter-spacing: .04em; background: var(--fill); color: var(--muted); }
.src.iv { background: var(--mark-soft); color: var(--mark); }

/* ---- T78 answered follow-up questions (wireframe S7) ---- */
.interview-answers { display: grid; gap: 10px; }
.interview-answers .q { display: flex; gap: 10px; align-items: baseline; }
.interview-answers .q > i { font: 600 12px var(--font-mono); color: var(--muted); font-style: normal; }
.interview-answers .q > span { display: grid; gap: 4px; justify-items: start; min-width: 0; }
.interview-answers .q b { font-weight: 600; }
.interview-answers .q .quote { margin: 2px 0 0; }

/* ---- T46 pricing ---- */
/* Currency switch: plain links in the T30 segmented-control look, so it works without JavaScript. */
.pricing-currency { align-self: start; }
.pricing-currency a[aria-current="page"] { cursor: default; }

/* Pack name, price and the "one time" note stay on one line where they fit (AED/₱ prefixes are wider than $). */
.card.price .lbl { text-wrap: balance; }
.card.price .price-v { overflow-wrap: anywhere; }
.card.price .price-v small { white-space: nowrap; }

/* ---- T52 criteria editor and settings grid ---- */
/* Growing criterion field: one row tall by default, up to ~5 lines, then it scrolls. */
.crit-text { field-sizing: content; min-block-size: 2.4em; max-block-size: 6.5em; resize: none; }
/* Remove: a square ghost button with a cross glyph. */
.btn.icon { inline-size: 40px; min-inline-size: 40px; padding: 0; font-size: 16px; line-height: 1; }
/* Settings: two columns, one below 900 px so a card never sits alone in a half-wide cell. */
@media (max-width: 900px) { .settings-grid { grid-template-columns: minmax(0, 1fr); } }

/* ---- score.v3 (S1-S5): alignment, ceiling, ring, evidence kind, strengths/weaknesses ---- */
.tag { font: 500 11px var(--font-mono); color: var(--muted); border: 1px solid var(--line); border-radius: 4px; padding: 1px 6px; }
.align { display: inline-flex; align-items: baseline; gap: 2px; font: 600 18px var(--font-display); font-variant-numeric: tabular-nums; }
.align small { font: 500 12px var(--font-body); color: var(--muted); }
.align.big { font-size: 34px; }
.ceil { font: 500 10px var(--font-mono); padding: 0 5px; border-radius: 3px; background: var(--warn-soft); color: var(--warn); white-space: nowrap; }
.ring { --p: 80; width: 78px; height: 78px; border-radius: 50%; flex: none;
  background: conic-gradient(var(--ink) calc(var(--p) * 1%), var(--fill) 0); display: grid; place-items: center; }
.ring > span { width: 60px; height: 60px; border-radius: 50%; background: var(--surface); display: grid; place-items: center; font: 600 20px var(--font-display); font-variant-numeric: tabular-nums; }
.kind { font: 500 10px var(--font-mono); padding: 1px 6px; border-radius: 3px; white-space: nowrap; }
.kind.hands { background: var(--ok-soft); color: var(--ok); }
.kind.support { background: var(--warn-soft); color: var(--warn); }
.kind.listed, .kind.none { background: var(--bad-soft); color: var(--bad); }
.sw { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.sw ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.sw li { display: grid; gap: 4px; font-size: 13px; }
.sw .lbl { display: block; margin-block-end: 6px; }
.v3-only { display: none; }
.v3 .v3-only { display: block; }
.v3 .btn.v3-only { display: inline-flex; }
.v3 .legacy-only { display: none; }
@media (max-width: 760px) { .sw { grid-template-columns: minmax(0, 1fr); } }

/* ---- T94 compact add-material panel, summary dialog and score history ---- */
/* The kind choice stays the T37 segmented radios; it only needs to sit on its own row in the panel. */
/* Assessment tabs (T83/T94): "After <material>" and "From the CV" as underlined tabs, not a grey bar. */
.seg.run-tabs { display: flex; gap: 4px; padding: 0; background: none; border-bottom: 1px solid var(--line); border-radius: 0; flex-wrap: wrap; }
.run-tabs a { padding: 9px 14px; border-radius: 8px 8px 0 0; color: var(--muted); font-size: 14px; font-weight: 500;
  border-bottom: 2px solid transparent; margin-bottom: -1px; background: none; box-shadow: none; }
.run-tabs a:hover { color: var(--ink); background: var(--fill); }
.run-tabs a.on { color: var(--ink); font-weight: 600; border-bottom-color: var(--accent); background: none; box-shadow: none; }
.run-tabs a:focus-visible { outline: 2px solid var(--focus); outline-offset: -2px; }
/* Kind choice (T92/T94): a 2x2 grid of clear options, and the result strip with its button in one card. */
.seg.seg-radio.interview-kind { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; padding: 0; background: none; justify-self: stretch; }
.interview-kind label { display: flex; }
.interview-kind label span { flex: 1; display: flex; align-items: center; gap: 8px; border: 1px solid var(--line-2); border-radius: 8px;
  padding: 9px 10px; background: var(--surface); color: var(--ink); font-size: 13px; line-height: 1.3; font-weight: 500; box-shadow: none; }
.interview-kind label span::before { content: ""; flex: none; width: 14px; height: 14px; border-radius: 50%; border: 1.5px solid var(--line-2); background: var(--surface); }
.interview-kind input:checked + span { background: var(--accent-soft); border-color: var(--accent); font-weight: 600; box-shadow: none; }
.interview-kind input:checked + span::before { border-color: var(--accent); background: radial-gradient(circle, var(--accent) 0 4px, var(--surface) 5px); }
.interview-result { display: grid; gap: 8px; background: var(--accent-soft); border-radius: 10px; padding: 12px; }
.interview-result .btn { width: 100%; justify-content: center; background: var(--surface); color: var(--accent-deep);
  border-color: var(--accent); font-weight: 600; }
.interview-result .btn:hover { background: var(--accent-soft); }
#interview form .btn.primary { width: 100%; justify-content: center; }
/* The summary dialog reuses dialog.guidance tokens: wider than the guidance dialog and scrolls inside at 85vh. */
dialog.guidance.interview-summary { max-width: 46rem; max-height: 85vh; overflow: auto; }
/* What was added so far: one label · date line per item, no pasted text. */
.added { list-style: none; margin: 0; padding: 0; display: grid; gap: 2px; }
.added li { color: var(--ink-2); }
/* Score history: label · date, the number, the change and the Viewing marker on one row that wraps on narrow columns. */
.history { list-style: none; margin: 0; padding: 0; display: grid; gap: 2px; }
.history li { display: flex; flex-wrap: wrap; align-items: baseline; gap: 6px; padding-block: 5px; border-block-end: 1px solid var(--line); }
.history li:last-child { border-block-end: 0; }
.history .lbl { flex: 1 1 9em; min-width: 0; color: var(--ink); text-decoration: none; }
.history li.current .lbl { font-weight: 600; }

/* ---- T108 recommended Boolean search ---- */
/* The popup reuses the guidance dialog tokens; it is wider because three queries sit under each other and it scrolls
   inside the viewport rather than pushing the page. Search strings wrap so a long Boolean never overflows the dialog. */
dialog.guidance.boolean-dialog { max-width: 48rem; max-height: 85vh; overflow: auto; }
.boolean-dialog .boolean-cat { display: grid; gap: 6px; border: 1px solid var(--line); border-radius: 10px;
  padding: 10px 12px; background: var(--surface); }
.boolean-string { margin: 0; padding: 9px 11px; border: 1px solid var(--line); border-radius: 8px; background: var(--fill);
  color: var(--ink); font: 500 13px/1.5 var(--font-mono); white-space: pre-wrap; overflow-wrap: anywhere; }
.boolean-dialog .chips { gap: 6px; }
.boolean-dialog .chips .btn { min-height: 32px; padding: 4px 10px; font-size: 13px; }
.boolean-dialog .drop { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; border: 1px dashed var(--line-2);
  border-radius: 10px; padding: 10px 12px; background: var(--surface); transition: border-color .12s, background .12s; }
.boolean-dialog .drop.hot { border-color: var(--accent); background: var(--fill); }
.boolean-dialog .drop .btn { flex: 0 0 auto; }
.boolean-dialog .fname { font-size: 13px; color: var(--muted); min-width: 0; overflow: hidden; text-overflow: ellipsis;
  white-space: nowrap; }
.boolean-dialog .fname.has { color: var(--ink); font-weight: 600; }
.boolean-dialog input:focus-visible + .btn { outline: 2px solid var(--focus); outline-offset: 2px; }
.empty-tools { justify-content: center; }
