:root {
  --ink: #111827; --muted: #4B5563; --muted2: #6B7280; --line: #EEF0F4;
  --bg: #F4F5F8; --navy: #14213D; --accent: #3046C5; --accent-bg: #EEF2FF;
}
* { box-sizing: border-box; }
body { margin: 0; background: var(--bg); color: var(--ink); font-family: Inter, system-ui, -apple-system, sans-serif; font-size: 15px; line-height: 1.45; }
h1, h2, h3 { margin: 0; }
h1, h2, .big, .score, .avatar { font-family: "Space Grotesk", Inter, sans-serif; }
a { color: inherit; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
.wrap { max-width: 1120px; margin: 0 auto; padding: 0 16px; }
.muted { color: var(--muted); } .small { font-size: 13px; } .accent { color: var(--accent); }

/* Cover */
.cover { background: var(--navy); color: #fff; padding: 28px 0 88px; }
.cover-tall { padding-bottom: 96px; }
.cover-row { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; flex-wrap: wrap; }
.cover h1 { font-size: clamp(26px, 5vw, 38px); margin-top: 6px; }
.eyebrow { display: flex; align-items: center; gap: 8px; color: #C9D3EA; font-size: 13px; font-weight: 600; letter-spacing: .05em; text-transform: uppercase; }
.dot { width: 8px; height: 8px; border-radius: 50%; background: #7C8CFF; }
.muted-light { color: #C9D3EA; margin: 6px 0 0; }
.stat-pills { display: flex; gap: 8px; flex-wrap: wrap; }
.pill-dark { padding: 7px 12px; border-radius: 999px; background: rgba(255,255,255,.1); font-size: 13px; font-weight: 500; }
.pill-dark b { font-weight: 700; }
.back { display: inline-flex; align-items: center; gap: 6px; color: #fff; text-decoration: none; font-weight: 600; min-height: 44px; }
.lift { margin-top: -64px; padding-bottom: 48px; }
.lift-more { margin-top: -72px; padding-bottom: 48px; display: flex; flex-direction: column; gap: 20px; }

.card { background: #fff; border-radius: 18px; padding: 20px; box-shadow: 0 1px 2px rgba(20,33,61,.04); }

/* Toolbar */
.toolbar { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; box-shadow: 0 10px 30px rgba(20,33,61,.08); }
.search { flex: 999 1 280px; display: flex; align-items: center; gap: 10px; background: var(--bg); border-radius: 12px; padding: 0 14px; color: var(--muted2); }
.search input { flex: 1; border: 0; background: transparent; font: inherit; color: var(--ink); min-height: 46px; outline: none; }
.filters { display: flex; gap: 6px; }
.chip { font: inherit; font-weight: 600; font-size: 14px; border: 1px solid #D7DBE5; background: #fff; color: var(--ink); border-radius: 999px; min-height: 44px; padding: 0 16px; cursor: pointer; }
.chip.active { background: var(--navy); border-color: var(--navy); color: #fff; }
.sort { display: flex; align-items: center; gap: 8px; font-size: 13px; color: var(--muted); }
.sort select { font: inherit; color: var(--ink); min-height: 44px; border: 1px solid #D7DBE5; border-radius: 10px; padding: 0 10px; background: #fff; }
.count { color: var(--muted); font-size: 14px; margin: 18px 4px 10px; }
.empty { text-align: center; color: var(--muted); padding: 40px 0; }

/* Candidate cards */
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 14px; }
.cand { position: relative; display: flex; flex-direction: column; gap: 14px; transition: box-shadow .15s, transform .15s; }
.cand:hover { box-shadow: 0 10px 28px rgba(20,33,61,.12); transform: translateY(-1px); }
.cand[hidden] { display: none; }
.cand-top { display: flex; gap: 12px; align-items: flex-start; }
.avatar { width: 48px; height: 48px; border-radius: 14px; background: var(--accent); color: #fff; display: flex; align-items: center; justify-content: center; font-weight: 700; font-size: 18px; flex-shrink: 0; }
.avatar-lg { width: 92px; height: 92px; border-radius: 24px; font-size: 36px; }
.cand-id { flex: 1; min-width: 0; }
.cand-id h2 { font-size: 17px; font-weight: 600; line-height: 1.25; }
.stretch { text-decoration: none; }
.stretch::after { content: ""; position: absolute; inset: 0; border-radius: 18px; }
.stretch:focus-visible { outline: none; }
.stretch:focus-visible::after { outline: 3px solid var(--accent); outline-offset: 2px; }
.rank { flex-shrink: 0; display: flex; flex-direction: column; align-items: center; padding: 6px 10px; border-radius: 12px; background: var(--accent-bg); color: var(--accent); font-size: 11px; font-weight: 700; letter-spacing: .04em; }
.rank b { font-size: 17px; font-family: "Space Grotesk", sans-serif; }
.facts { margin: 0; display: flex; flex-direction: column; gap: 8px; }
.facts div { display: grid; grid-template-columns: 92px 1fr; gap: 8px; font-size: 14px; }
.facts dt { color: var(--muted2); } .facts dd { margin: 0; }
.cand-foot { margin-top: auto; padding-top: 12px; border-top: 1px solid var(--line); display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.mini-stats { display: flex; gap: 14px; font-size: 13px; color: var(--muted); flex-wrap: wrap; }
.mini-stats b { color: var(--ink); }
.btn-cv { position: relative; z-index: 1; display: inline-flex; align-items: center; gap: 6px; min-height: 40px; padding: 0 14px; border-radius: 10px; background: var(--navy); color: #fff; font-weight: 600; font-size: 14px; text-decoration: none; }
.btn-cv:hover, .btn-primary:hover { background: #22345E; }

/* Profile */
.identity { display: flex; flex-wrap: wrap; gap: 22px; align-items: center; padding: 26px; box-shadow: 0 10px 30px rgba(20,33,61,.08); }
.id-text { flex: 999 1 300px; min-width: 0; display: flex; flex-direction: column; gap: 8px; }
.id-text h1 { font-size: clamp(26px, 4.5vw, 34px); line-height: 1.1; }
.eyebrow-accent { font-size: 13px; font-weight: 600; color: var(--accent); letter-spacing: .05em; text-transform: uppercase; }
.tags { display: flex; flex-wrap: wrap; gap: 8px; }
.tag { padding: 6px 10px; border-radius: 8px; background: #F1F3F8; font-size: 13px; color: #374151; }
.btn-primary { flex: 1 1 170px; display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 48px; padding: 0 22px; border-radius: 12px; background: var(--navy); color: #fff; font-weight: 600; text-decoration: none; }
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 12px; }
.stat { display: flex; flex-direction: column; gap: 2px; }
.big { font-size: 30px; font-weight: 700; } .big small { font-size: 15px; color: var(--muted2); font-weight: 500; }
.cols { display: flex; flex-wrap: wrap; gap: 20px; align-items: flex-start; }
.col-main { flex: 999 1 560px; min-width: 0; display: flex; flex-direction: column; gap: 20px; }
.col-side { flex: 1 1 280px; min-width: 0; display: flex; flex-direction: column; gap: 20px; }
.col-main .card, .col-side .card { padding: 24px; }
.card h2 { font-size: 20px; font-weight: 600; margin-bottom: 16px; }
.h-sm { font-size: 17px !important; }
.item { display: flex; gap: 14px; padding: 14px 0; border-top: 1px solid var(--line); }
.item:first-of-type { border-top: 0; padding-top: 0; }
.icon { width: 44px; height: 44px; border-radius: 12px; display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.icon-blue { background: var(--accent-bg); color: var(--accent); }
.icon-amber { background: #FEF3E2; color: #B45309; }
.icon-green { background: #E7F6EF; color: #047857; }
.item-body { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 3px; }
.item-head { display: flex; justify-content: space-between; gap: 8px; flex-wrap: wrap; }
.item-head h3 { font-size: 16px; font-weight: 600; }
.badge { padding: 3px 10px; border-radius: 999px; font-size: 12px; font-weight: 600; white-space: nowrap; }
.badge-blue { background: var(--accent-bg); color: var(--accent); }
.badge-amber { background: #FEF3E2; color: #92400E; }
.badge-green { background: #E7F6EF; color: #065F46; }
.timeline { list-style: none; margin: 0; padding: 0; }
.tl { position: relative; padding: 0 0 20px 30px; }
.tl::before { content: ""; position: absolute; left: 6px; top: 18px; bottom: 0; width: 2px; background: #E5E7EB; }
.tl:last-child::before { display: none; }
.tl::after { content: ""; position: absolute; left: 0; top: 3px; width: 14px; height: 14px; border-radius: 50%; border: 3px solid var(--navy); background: #fff; box-sizing: border-box; }
.tl.current::after { background: var(--accent); border-color: var(--accent); }
.tl h3 { font-size: 16px; font-weight: 600; }
.tl-row { display: flex; justify-content: space-between; gap: 10px; flex-wrap: wrap; }
.tl-label { font-size: 12px; font-weight: 600; color: var(--muted2); letter-spacing: .03em; }
.score { font-size: 21px; font-weight: 700; }
.kv { margin: 0; display: flex; flex-direction: column; gap: 12px; }
.kv div { display: flex; justify-content: space-between; gap: 12px; font-size: 14px; }
.kv dt { color: var(--muted2); } .kv dd { margin: 0; font-weight: 600; text-align: right; }
.dark { background: var(--navy); color: #fff; }
.light { color: #C9D3EA; margin-bottom: 10px; } .light-muted { color: #C9D3EA; }
.tag-outline { padding: 5px 10px; border-radius: 999px; border: 1px solid rgba(255,255,255,.28); font-size: 12px; }
.also { display: flex; align-items: center; min-height: 44px; font-weight: 600; color: var(--accent); }

@media (max-width: 520px) {
  .grid { grid-template-columns: 1fr; }
  .card { padding: 16px; }
  .filters { flex: 1; } .chip { flex: 1; }
  .sort { flex: 1 1 100%; } .sort select { flex: 1; }
}

/* Login + user box */
.login-page { min-height: 100vh; display: flex; align-items: center; justify-content: center; padding: 20px; background: var(--navy); }
.login-card { width: 100%; max-width: 400px; padding: 32px; display: flex; flex-direction: column; gap: 14px; box-shadow: 0 20px 50px rgba(0,0,0,.25); }
.login-card h1 { font-size: 28px; }
.login-card p { margin: 0; }
.field { display: flex; flex-direction: column; gap: 6px; font-size: 14px; font-weight: 600; }
.field input { font: inherit; font-weight: 400; min-height: 46px; padding: 0 14px; border: 1px solid #D7DBE5; border-radius: 10px; }
.field input:focus { outline: 2px solid var(--accent); border-color: var(--accent); }
.login-card .btn-primary { border: 0; cursor: pointer; font: inherit; font-weight: 600; margin-top: 6px; flex: none; }
.login-error { background: #FDECEC; color: #9F1239; padding: 10px 12px; border-radius: 10px; font-size: 14px; }
.userbox { display: flex; align-items: center; gap: 8px; padding: 4px 4px 4px 12px; border-radius: 999px; background: rgba(255,255,255,.1); font-size: 13px; }
.userbox button { font: inherit; font-size: 13px; font-weight: 600; color: #fff; background: rgba(255,255,255,.14); border: 0; border-radius: 999px; min-height: 32px; padding: 0 12px; cursor: pointer; }
.userbox button:hover { background: rgba(255,255,255,.24); }

/* ---------- Navigation ---------- */
.topnav { display: flex; gap: 4px; padding: 4px; border-radius: 999px; background: rgba(255,255,255,.1); }
.topnav a { display: inline-flex; align-items: center; min-height: 36px; padding: 0 14px; border-radius: 999px; color: #fff; text-decoration: none; font-size: 14px; font-weight: 600; }
.topnav a.on { background: #fff; color: var(--navy); }
.stat-pills { align-items: center; }

/* ---------- Status pills ---------- */
.status { display: inline-block; padding: 5px 11px; border-radius: 999px; font-size: 12px; font-weight: 700; white-space: nowrap; }
.st-ne { background: #F1F3F8; color: #374151; }
.st-in { background: var(--accent-bg); color: var(--accent); }
.st-pass { background: #E7F6EF; color: #047857; }
.st-hold { background: #FEF3E2; color: #B45309; }
.st-rejected { background: #FDECEC; color: #B91C1C; }
.st-drop { background: #ECEEF2; color: #4B5563; }

/* ---------- List page ---------- */
.funnel { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 10px; box-shadow: 0 10px 30px rgba(20,33,61,.08); }
.fn { text-align: left; font: inherit; cursor: pointer; border: 2px solid transparent; border-radius: 14px; padding: 10px 14px; display: flex; flex-direction: column; gap: 2px; min-height: 44px; }
.fn span { font-size: 11px; font-weight: 700; letter-spacing: .04em; }
.fn b { font-family: "Space Grotesk", sans-serif; font-size: 26px; line-height: 1.1; }
.fn small { font-size: 11px; color: var(--muted2); }
.fn.active { border-color: var(--navy); }
.fn-all { background: #fff; border-color: #E5E7EB; } .fn-all span { color: var(--muted); }
.fn-not-evaluated { background: #F1F3F8; } .fn-not-evaluated span { color: #374151; }
.fn-in-process { background: var(--accent-bg); } .fn-in-process span { color: var(--accent); }
.fn-selected { background: #E7F6EF; } .fn-selected span { color: #047857; }
.fn-rejected { background: #FDECEC; } .fn-rejected span { color: #B91C1C; }
.fn-dropped { background: #ECEEF2; } .fn-dropped span { color: #4B5563; }
.toolbar:not(.card) { margin-top: 14px; }
.card-lite { background: #fff !important; }
.chip { display: inline-flex; align-items: center; gap: 6px; }
.chip.active .muted { color: #C9D3EA; }
.count-badge { padding: 1px 8px; border-radius: 999px; background: var(--accent-bg); color: var(--accent); font-size: 12px; }
.chip.active .count-badge { background: rgba(255,255,255,.2); color: #fff; }
.status-line { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }

/* ---------- Flash ---------- */
.flash { padding: 10px 12px; border-radius: 10px; font-size: 14px; margin: 0; }
.flash-ok { background: #E7F6EF; color: #065F46; }
.flash-error { background: #FDECEC; color: #9F1239; }

/* ---------- Placement panel ---------- */
.pl-row { display: flex; flex-wrap: wrap; gap: 20px; align-items: flex-start; }
.pl-main { flex: 999 1 520px; min-width: 0; }
.pl-side { flex: 1 1 300px; min-width: 0; }
.placement { display: flex; flex-direction: column; gap: 16px; padding: 24px; scroll-margin-top: 16px; }
.placement h2 { margin: 0 !important; }
.pl-head { display: flex; justify-content: space-between; align-items: center; gap: 10px; }
.pl-head .status { font-size: 13px; padding: 6px 12px; }
.pl-desc { margin: -8px 0 0; }
.interviewer { display: flex; align-items: center; gap: 10px; background: #F7F8FB; border-radius: 12px; padding: 10px 12px; }
.iv-avatar { width: 34px; height: 34px; border-radius: 50%; background: var(--navy); color: #fff; display: flex; align-items: center; justify-content: center; font-size: 12px; font-weight: 700; flex-shrink: 0; }
.iv-text { flex: 1; min-width: 0; }
.you { padding: 3px 10px; border-radius: 999px; background: var(--accent-bg); color: var(--accent); font-size: 12px; font-weight: 600; }
.stepper { list-style: none; margin: 0; padding: 0; display: flex; }
.step { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 4px; position: relative; text-align: center; font-size: 13px; }
.step + .step::before { content: ""; position: absolute; top: 15px; right: 50%; width: 100%; height: 2px; background: #E5E7EB; }
.step-done + .step::before, .step-done::before { background: #047857 !important; }
.step .dot { position: relative; z-index: 1; width: 32px; height: 32px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-weight: 700; font-size: 13px; border: 2px solid #D7DBE5; background: #fff; color: var(--muted2); }
.step-done .dot { background: #047857; border-color: #047857; color: #fff; }
.step-in .dot { background: var(--accent); border-color: var(--accent); color: #fff; }
.step-hold .dot { background: #B45309; border-color: #B45309; color: #fff; }
.step-rejected .dot { background: #B91C1C; border-color: #B91C1C; color: #fff; }
.step-drop .dot { background: #4B5563; border-color: #4B5563; color: #fff; }
.pl-form { display: flex; flex-direction: column; gap: 14px; }
.score-box { border: 0; margin: 0; background: #F7F8FB; border-radius: 14px; padding: 14px; display: flex; flex-direction: column; gap: 10px; }
.score-box legend { float: left; width: 100%; padding: 0; margin-bottom: 4px; font-size: 12px; font-weight: 700; letter-spacing: .05em; color: var(--muted); text-transform: uppercase; }
.score-row { display: flex; justify-content: space-between; align-items: center; gap: 12px; font-size: 14px; }
.score-input { display: inline-flex; align-items: center; gap: 6px; }
.score-input input { width: 76px; min-height: 44px; border: 1px solid #D7DBE5; border-radius: 10px; font: inherit; font-size: 16px; font-weight: 600; text-align: center; background: #fff; }
.score-input input:focus { outline: 2px solid var(--accent); border-color: var(--accent); }
.pl-actions { display: flex; flex-wrap: wrap; gap: 8px; }
.act { flex: 1 1 28%; min-height: 46px; padding: 0 16px; border-radius: 12px; font: inherit; font-size: 15px; font-weight: 600; cursor: pointer; border: 1px solid; }
.act:disabled { opacity: .4; cursor: not-allowed; }
.act-start { background: var(--navy); border-color: var(--navy); color: #fff; }
.act-pass { background: #047857; border-color: #047857; color: #fff; }
.act-reject { background: #fff; border-color: #F3B4B4; color: #B91C1C; }
.act-hold { background: #fff; border-color: #F5C98A; color: #B45309; }
.act-drop { background: #fff; border-color: #D7DBE5; color: #374151; }
.act:not(:disabled):hover { filter: brightness(.96); }
.gate-hint { margin: 0; font-size: 13px; color: #92400E; background: #FEF3E2; border-radius: 10px; padding: 10px 12px; }
.pl-foot { display: flex; justify-content: space-between; gap: 10px; flex-wrap: wrap; }
.link-btn { display: inline-flex; align-items: center; gap: 6px; min-height: 44px; padding: 0 4px; border: 0; background: transparent; color: var(--muted); font: inherit; font-size: 14px; font-weight: 600; cursor: pointer; }
.link-btn:hover { color: var(--ink); }
.drop-reason { margin: 0; font-size: 14px; background: #ECEEF2; border-radius: 10px; padding: 10px 12px; }

/* Drop dialog */
.sheet { border: 0; border-radius: 20px; padding: 24px; width: min(440px, calc(100vw - 24px)); box-shadow: 0 20px 60px rgba(0,0,0,.3); }
.sheet::backdrop { background: rgba(17,24,39,.55); }
.sheet form { display: flex; flex-direction: column; gap: 14px; }
.sheet h3 { margin: 0; font-family: "Space Grotesk", sans-serif; font-size: 22px; }
.sheet p { margin: 0; }
.field textarea { font: inherit; font-weight: 400; font-size: 15px; border: 1px solid #D7DBE5; border-radius: 10px; padding: 10px 12px; resize: vertical; }
.req { font-style: normal; font-weight: 400; font-size: 12px; color: #B91C1C; margin-left: 6px; }
.sheet-actions { display: flex; gap: 10px; }
.sheet-actions > * { flex: 1; }
.btn-ghost { min-height: 48px; border-radius: 12px; border: 1px solid #D7DBE5; background: #fff; font: inherit; font-weight: 600; cursor: pointer; }
.sheet .btn-primary { border: 0; cursor: pointer; font: inherit; font-weight: 600; }
.sheet .btn-primary:disabled { opacity: .4; cursor: not-allowed; }
@media (max-width: 520px) { .sheet { margin: auto 0 0; width: 100vw; max-width: 100vw; border-radius: 20px 20px 0 0; } }

/* Scores + activity */
.overall { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.overall div, .iv-grid div { border-radius: 12px; padding: 12px; display: flex; flex-direction: column; }
.overall div { background: var(--accent-bg); }
.overall span, .iv-grid span { font-size: 11px; font-weight: 700; color: var(--accent); letter-spacing: .04em; }
.overall b { font-family: "Space Grotesk", sans-serif; font-size: 26px; }
.iv-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; margin-top: 14px; }
.iv-grid div { border: 1px solid var(--line); }
.iv-grid span { color: var(--muted2); }
.iv-grid b { font-size: 14px; overflow-wrap: anywhere; }
.activity { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 12px; font-size: 14px; max-height: 420px; overflow-y: auto; }
.activity li { padding-left: 16px; position: relative; }
.activity li::before { content: ""; position: absolute; left: 0; top: 7px; width: 8px; height: 8px; border-radius: 50%; background: var(--accent); }

/* ---------- Final analysis ---------- */
.tiles { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 12px; }
.tile { display: flex; flex-direction: column; gap: 2px; box-shadow: 0 10px 30px rgba(20,33,61,.08); }
.tile span { font-size: 12px; font-weight: 700; color: var(--muted); letter-spacing: .03em; }
.tile b { font-family: "Space Grotesk", sans-serif; font-size: 30px; }
.t-green { color: #047857 !important; } .t-amber { color: #B45309 !important; } .t-blue { color: var(--accent) !important; }
.btn-outline { display: inline-flex; align-items: center; gap: 6px; min-height: 44px; padding: 0 14px; border-radius: 10px; border: 1px solid #D7DBE5; background: #fff; font-weight: 600; font-size: 14px; text-decoration: none; }
.table-wrap { padding: 0; overflow-x: auto; margin-top: 14px; }
table.final { width: 100%; min-width: 980px; border-collapse: collapse; font-size: 14px; }
.final th { text-align: left; font-size: 11px; font-weight: 700; letter-spacing: .05em; color: var(--muted2); padding: 14px 16px; border-bottom: 1px solid var(--line); text-transform: uppercase; white-space: nowrap; }
.final td { padding: 14px 16px; border-bottom: 1px solid #F1F3F8; vertical-align: middle; }
.final tr[hidden] { display: none; }
.final a { text-decoration: none; }
.final a:hover b { color: var(--accent); }
.rk { font-family: "Space Grotesk", sans-serif; font-size: 18px; font-weight: 700; color: var(--accent); }
.bar { display: flex; align-items: center; gap: 8px; min-width: 120px; }
.bar b { width: 34px; }
.track { flex: 1; height: 8px; border-radius: 8px; display: block; }
.track span { display: block; height: 8px; border-radius: 8px; }
.track.aa { background: var(--accent-bg); } .track.aa span { background: var(--accent); }
.track.pt { background: #E7F6EF; } .track.pt span { background: #047857; }
.empty-state { text-align: center; padding: 48px 20px; margin-top: 14px; }
.toolbar:not(.card) { box-shadow: none; }

/* ---------- Notes ---------- */
.sheet-body { display: flex; flex-direction: column; gap: 14px; }
.sheet-body p { margin: 0; }
.sheet-body .status { margin-left: 4px; }
.sheet-body .field textarea { min-height: 120px; }
.btn-primary.btn-pass { background: #047857; }
.btn-primary.btn-reject { background: #B91C1C; }
.btn-primary.btn-hold { background: #B45309; }
.btn-primary.btn-drop { background: var(--navy); }
.notes-box { border-radius: 12px; padding: 12px 14px; background: #F7F8FB; border-left: 0; display: flex; flex-direction: column; gap: 6px; }
.notes-box p { margin: 0; white-space: pre-line; font-size: 14px; }
.notes-head { display: flex; justify-content: space-between; gap: 8px; flex-wrap: wrap; font-size: 13px; }
.notes-pass { background: #EFF8F3; } .notes-hold { background: #FFF7EC; }
.notes-rejected { background: #FEF3F3; } .notes-drop { background: #F1F3F6; }
.act-notes { margin: 6px 0 0; padding: 8px 10px; border-radius: 8px; background: #F7F8FB; font-size: 13px; white-space: pre-line; color: #374151; }
.sync-form { margin: 0; }
.sync-form .btn-outline { font: inherit; font-size: 14px; font-weight: 600; cursor: pointer; }
.sync-status { margin: 10px 4px 0; font-size: 13px; color: var(--muted); }
.sync-bad { color: #9F1239; }
.flash + .sync-status, .toolbar + .flash { margin-top: 12px; }

/* ---------- Notes section (collapsible) ---------- */
.notes-section { border: 1px solid var(--line); border-radius: 14px; scroll-margin-top: 16px; }
.notes-section summary { list-style: none; display: flex; align-items: center; gap: 8px; min-height: 48px; padding: 0 14px; cursor: pointer; font-weight: 600; color: var(--ink); border-radius: 14px; }
.notes-section summary::-webkit-details-marker { display: none; }
.notes-section summary:hover { background: #F7F8FB; }
.notes-section summary:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.ns-cta { margin-left: auto; display: inline-flex; align-items: center; gap: 4px; color: var(--accent); font-size: 14px; }
.ns-cta svg { transition: transform .15s; }
.ns-hide { display: none; }
.notes-section[open] .ns-show { display: none; }
.notes-section[open] .ns-hide { display: inline; }
.notes-section[open] .ns-cta svg { transform: rotate(180deg); }
.notes-section[open] summary { border-bottom: 1px solid var(--line); border-radius: 14px 14px 0 0; }
.ns-list { display: flex; flex-direction: column; gap: 10px; padding: 12px; }
.note-item { border-radius: 12px; padding: 12px 14px; display: flex; flex-direction: column; gap: 6px; background: #F7F8FB; }
.note-head { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.note-text { margin: 0; white-space: pre-line; font-size: 14px; }
.note-text[hidden] { display: none; }
.note-edit-btn { align-self: flex-start; min-height: 36px; font-size: 13px; padding: 0; }
.note-edit { display: flex; flex-direction: column; gap: 8px; }
.note-edit[hidden] { display: none; }
.note-edit textarea { font: inherit; font-size: 14px; border: 1px solid #D7DBE5; border-radius: 10px; padding: 10px 12px; resize: vertical; min-height: 96px; background: #fff; }
.note-edit textarea:focus { outline: 2px solid var(--accent); border-color: var(--accent); }
.note-edit-actions { display: flex; gap: 8px; justify-content: flex-end; }
.note-edit-actions > * { min-height: 44px; padding: 0 16px; border-radius: 10px; }
.note-edit-actions .btn-primary { border: 0; font: inherit; font-weight: 600; cursor: pointer; flex: none; }
.note-edit-actions .btn-primary:disabled { opacity: .4; cursor: not-allowed; }
.note-edit-btn[hidden] { display: none; }
