/* =====================================================================
   teamBoard — "Playbook" design system
   Athletic / coaching language: dark side rail, light field, one hard red,
   field-green for "made it", heavy uppercase headings, tabular numerals,
   hard edges. Visual layer only — layout/structure below is preserved from
   the original stylesheet (incl. the Safari-safe tree markers and mobile
   rules), so every page reskins without template changes.
   ===================================================================== */

/* --- Apercu-ready font. Drop the licensed webfont into app/static/fonts/
   and uncomment this block; the stack already prefers "Apercu" everywhere. ---
@font-face{ font-family:"Apercu"; font-weight:400; font-style:normal; font-display:swap;
  src:url("/static/fonts/apercu-regular.woff2") format("woff2"); }
@font-face{ font-family:"Apercu"; font-weight:500; font-style:normal; font-display:swap;
  src:url("/static/fonts/apercu-medium.woff2") format("woff2"); }
@font-face{ font-family:"Apercu"; font-weight:700; font-style:normal; font-display:swap;
  src:url("/static/fonts/apercu-bold.woff2") format("woff2"); }
*/

:root{
  --font: ui-sans-serif, system-ui, sans-serif; /* same as Visible */
  --ink:#14181d; --paper:#fbfaf7; --panel:#f4f5f1; --card:#ffffff;
  --line:#edeee9; --line2:#e4e5e0; --dim:#6f7668; --faint:#9aa090;
  --red:#e11d2a; --red-dk:#b3141f; --green:#17915a; --amber:#f0a828; --blue:#2f4a72;
  --side:#14181d; --side-2:#1d232b; --side-ink:#8f97a1; --side-ink2:#cfd4da; --side-line:#262d36;
  --r:2px;
}

* { box-sizing: border-box; font-family: var(--font); }
body { margin: 0; color: var(--ink); background: var(--paper);
  -webkit-text-size-adjust: 100%; }
.layout { display: flex; min-height: 100vh; }

/* ---------- side rail ---------- */
/* Grouped links (Planning / People / Owner), name + Sign Out pinned to the
   bottom, and the rail stays put while the page scrolls. */
.sidebar { width: 210px; flex: none; background: var(--side); padding: 18px 12px 14px;
  display: flex; flex-direction: column; position: sticky; top: 0; height: 100vh;
  overflow-y: auto; }
/* Red edge like BaseBoard's nav bar (its 3px red underline), down the right side. */
.sidebar { border-right: 3px solid var(--red); }
.nav-top { display: flex; align-items: center; padding: 0 6px 14px; }
.sidebar strong { color:#fff; letter-spacing:-.01em; font-weight:800; font-size:19px; }
.brand-dot { color: var(--red); }
.nav-toggle { display: none; }
.nav-links { display: flex; flex-direction: column; gap: 1px; }
/* Section headings, with a divider line above so each group reads as its own section. */
.nav-head { margin: 12px 0 0; padding: 12px 10px 4px; border-top: 1px solid var(--side-line);
  font-size: 10px; font-weight: 800; text-transform: uppercase; letter-spacing: .08em;
  color: #5d6670; }
.sidebar a, .sidebar .nav-group > summary { display: flex; align-items: center; padding: 7px 10px;
  color: var(--side-ink); text-decoration: none; font-size: 13.5px; font-weight: 600;
  border-radius: 4px; }
.sidebar a:hover, .sidebar .nav-group > summary:hover { color:#fff; background: var(--side-2); }
/* Current page, like Visible: white text with a straight red bar under the
   word (a positioned ::after, so it doesn't shift the text). */
.sidebar a.active, .sidebar a.active:hover { color:#fff; background: none; font-weight: 700; }
.sidebar a.active .nav-label { position: relative; }
.sidebar a.active .nav-label::after { content: ""; position: absolute; left: 0; right: 0;
  bottom: -4px; height: 2px; background: var(--red); }
.nav-pill { margin-left: auto; background: var(--red); color: #fff; font-size: 10.5px; font-weight: 800;
  padding: 1px 7px; border-radius: 9px; }
/* Account menu at the bottom (BaseBoard's look): person icon + name; opens
   upward with the app name, email and Sign Out. */
.nav-user { margin-top: auto; border-top: 1px solid var(--side-line); padding-top: 10px; position: relative; }
.nav-user-label { list-style: none; display: flex; align-items: center; gap: 8px; padding: 7px 10px;
  color: #d4d4d4; cursor: pointer; border-radius: 4px; font-size: 13px; font-weight: 600; }
.nav-user-label::-webkit-details-marker { display: none; }
.nav-user-label:hover, .nav-user[open] .nav-user-label { color: #fff; background: var(--side-2); }
.nav-user-icon { width: 20px; height: 20px; flex: none; }
.nav-who { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.nav-caret { width: 11px; height: 11px; margin-left: auto; flex: none; transition: transform .15s; }
.nav-user[open] .nav-caret { transform: rotate(180deg); }
.nav-user-menu { position: absolute; left: 0; right: 0; bottom: calc(100% + 4px); z-index: 30;
  background: var(--side-2); border: 1px solid var(--side-line); border-radius: 6px;
  padding: 10px 8px 6px; display: flex; flex-direction: column; }
.nav-app-name { padding: 0 8px; color: #fff; font-weight: 800; font-size: 15px; }
.nav-user-menu .who { padding: 2px 8px 8px; color: #a3a3a3; font-size: 12px; overflow-wrap: anywhere;
  border-bottom: 1px solid #484848; margin-bottom: 4px; }
.nav-access { display: block; color: var(--side-ink); font-weight: 600; font-size: 11px;
  text-transform: capitalize; }
.sidebar .nav-user-menu a.nav-signout { padding: 6px 8px; font-size: 13px; }
@media (prefers-reduced-motion: reduce) { .nav-caret { transition: none; } }

.content { flex: 1; padding: 28px; background: var(--paper); }

/* ---------- headings ---------- */
h1, h2 { text-transform: uppercase; font-weight: 800; letter-spacing: -.02em;
  margin: 0 0 6px; }
h1 { font-size: 27px; } h2 { font-size: 23px; }
h3 { font-size: 15px; font-weight: 800; letter-spacing: -.01em; margin: 18px 0 8px; }

/* ---------- cards ---------- */
.card { border: 1px solid var(--line); border-radius: var(--r);
  padding: 14px; margin: 10px 0; background: var(--card); }

/* ---------- progress bars ---------- */
.bar { background: #e7e8e3; border-radius: 0; height: 8px; overflow: hidden; }
.bar > span { display:block; background: var(--green); height: 8px; border-radius: 0; }

/* ---------- tables ---------- */
table { border-collapse: collapse; width: 100%; }
th { text-align: left; padding: 8px; border-bottom: 2px solid var(--line);
  font-size: 10px; text-transform: uppercase; letter-spacing: .08em;
  color: var(--faint); font-weight: 800; }
td { text-align: left; padding: 10px 8px; border-bottom: 1px solid var(--line);
  font-variant-numeric: tabular-nums; }

/* ---------- buttons: hard-edged, uppercase ---------- */
.btn, .btn-secondary, .btn-ghost, .btn-danger, .btn-inert {
  border-radius: var(--r); padding: 8px 14px; font-size: 11.5px; font-weight: 800;
  text-transform: uppercase; letter-spacing: .05em; text-decoration: none;
  display: inline-block; cursor: pointer; line-height: 1.25; }
.btn { background: var(--red); color:#fff; border: 1px solid var(--red); }
.btn:hover { background: var(--red-dk); border-color: var(--red-dk); }
.btn-secondary { background: var(--ink); color:#fff; border: 1px solid var(--ink); }
.btn-secondary:hover { background:#000; }
.btn-ghost { background: transparent; color: var(--ink); border: 2px solid var(--ink); padding: 7px 13px; }
.btn-ghost:hover { background: var(--ink); color:#fff; }
.btn-danger { background:#fff; color: var(--red); border: 2px solid var(--red); padding: 7px 13px; }
.btn-danger:hover { background: var(--red); color:#fff; }
.btn-inert { background:#e9e7e2; color:#8a8a8a; border:1px solid #d8d5cf; cursor:default; }
button.btn:disabled { background:#e9e7e2; color:#8a8a8a; border-color:#d8d5cf; cursor:default; }

/* ---------- content links ----------
   On-palette, no underline, no visited/purple distinction. Scoped to bare
   anchors inside .content so the sidebar nav and .btn/.btn-* keep their own
   colours. Person-row links (candidates + directory) also get a red skewed
   "slash" on hover — the same mark as the logo — to flag the hovered row.
   Space for the slash is reserved so nothing shifts on hover. */
.content a:not([class]),
.content a:not([class]):visited { color: var(--blue); text-decoration: none; }
.content a:not([class]):hover { color: var(--red); }
/* Role/Voice resource links (leader home) are a.mod-name but sit directly in
   .mod-row (module-checklist names are nested in .mod-left and stay ink). Give
   them the same themed treatment as other content links — no browser blue. */
.mod-row > a.mod-name { color: var(--blue); text-decoration: none; }
.mod-row > a.mod-name:hover { color: var(--red); }
/* Role Resources: "Welcome to leadership" leads full-width & emphasised; the
   remaining documents flow two-up (single column on mobile). */
.mod-row.rr-welcome { border-bottom: 2px solid var(--line); }
.mod-row.rr-welcome a.mod-name { font-weight: 700; font-size: 15px; }
.rr-grid { display: grid; grid-template-columns: 1fr 1fr; column-gap: 22px; }
.rr-grid .mod-row { border-bottom: none; padding: 8px 4px; }
@media (max-width: 640px) { .rr-grid { grid-template-columns: 1fr; } }

/* ---------- "What you're doing well" — celebratory admin encouragement ----------
   Only rendered when an admin has written something; a bold green "award" card
   with a gold ribbon top and a hard athletic shadow so it feels rewarding. */
.doing-well { margin: 6px 0 22px; padding: 16px 20px 18px; background: #eafaf0;
  border: 2px solid var(--green); border-top: 5px solid var(--amber);
  border-radius: var(--r); box-shadow: 0 4px 0 0 rgba(23,145,90,.22); }
.doing-well .dw-head { font-size: 13px; font-weight: 800; text-transform: uppercase;
  letter-spacing: .06em; color: #0f6b3f; margin-bottom: 8px; }
.doing-well .dw-body { font-size: 19px; line-height: 1.45; font-weight: 600;
  color: var(--ink); white-space: pre-wrap; overflow-wrap: anywhere; }

/* ---------- Value of the Week (no label, clean centred script) ----------
   In the restaurant strip (admins): centred italic line between the name and
   the Switch links. On the user home (no strip): a centred line at the top. */
.vow-line { text-align: center; font-style: italic; font-weight: 600;
  font-size: 17px; color: var(--ink); margin: 0 0 16px; }
/* Blue "This week" pill flagging scheduled modules within the role curriculum */
.sched-pill { margin-left: 8px; vertical-align: middle; }
/* Settings: value-of-the-week management list */
.value-list { margin: 0 0 14px; padding-left: 22px; max-width: 700px; }
.value-list li { padding: 7px 0; border-bottom: 1px solid var(--line);
  display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.value-list li:last-child { border-bottom: none; }
@media (hover: hover) and (pointer: fine) {
  .card-title a { position: relative; padding-left: 14px; }
  .card-title a::before { content: ""; position: absolute; left: 0; top: 50%;
    width: 6px; height: 1.05em; background: transparent;
    transform: translateY(-50%) skewX(-12deg); }
  .card-title a:hover { color: var(--red); }
  .card-title a:hover::before { background: var(--red); }
}

/* ---------- banners ---------- */
.preview-banner { background:#fff4e5; border:1px solid #ffcf99; border-left:5px solid var(--amber);
  border-radius: var(--r); padding:10px 14px; margin-bottom:16px; font-size:14px; }
.preview-banner a { margin-left:10px; font-weight:700; }
.error-banner { background:#fdecea; border-left:5px solid var(--red); color:#611a15;
  padding:10px 14px; border-radius: var(--r); margin-bottom:16px; }
.essay-answer { background: var(--panel); border-left:3px solid var(--red); padding:8px 12px;
  margin:8px 0; border-radius: var(--r); }

/* ---------- restaurant banner: store | Value of the Week | store toggle ---------- */
.team-strip { display: grid; grid-template-columns: auto 1fr auto; gap: 16px; align-items: center;
  background: var(--card); border: 1px solid var(--line2); border-top: 4px solid var(--team-color, var(--red));
  border-radius: 6px; padding: 12px 16px; margin-bottom: 18px; }
.team-strip .ts-name { min-width: 140px; font-weight: 800; font-size: 16px; padding-right: 16px; border-right: 1px solid var(--line2); white-space: nowrap; }
.team-strip .ts-vow { text-align: center; min-width: 0; }
.team-strip .ts-vow small { display: block; font-size: 10.5px; font-weight: 800; letter-spacing: .08em;
  text-transform: uppercase; color: var(--faint); margin-bottom: 1px; }
.team-strip .ts-vow-word { display: block; font-size: 18px; font-weight: 800; color: var(--team-color, var(--red)); letter-spacing: .02em; }
.team-strip .ts-vow-rest { display: block; font-size: 13.5px; color: var(--dim); }
.team-strip .ts-switch { grid-column: 3; display: inline-flex; border: 1px solid var(--line2); border-radius: 999px;
  background: var(--panel); padding: 2px; gap: 2px; }
.team-strip .ts-switch > * { padding: 5px 12px; font-size: 12px; font-weight: 700; border-radius: 999px; white-space: nowrap; }
.team-strip .ts-switch .on { background: var(--team-color, var(--red)); color: #fff; }
.team-strip .ts-switch a { color: var(--dim); text-decoration: none; }
.team-strip .ts-switch a:hover { background: #fff; color: var(--ink); }

.note { font-size: 12px; color: var(--dim); }
.muted { color: var(--dim); }
.role-resources-note { margin: -8px 0 8px; font-style: italic; }

/* ---------- scoreboard tiles (dashboard) ---------- */
.scoreboard { display:grid; grid-template-columns:repeat(3,1fr); gap:11px; margin:16px 0 22px; }
.score { border:2px solid var(--line); border-top:4px solid var(--ink); padding:11px 13px; background:var(--card); }
.score.win { border-top-color: var(--green); } .score.hot { border-top-color: var(--red); }
.score .k { font-size:10px; text-transform:uppercase; letter-spacing:.09em; color:var(--dim); font-weight:800; }
.score .v { font-size:32px; font-weight:800; letter-spacing:-.03em; font-variant-numeric:tabular-nums;
  margin-top:2px; line-height:1; }
.score .v small { font-size:14px; color:var(--faint); font-weight:800; }

/* ---------- directory roster section headings ---------- */
.roster-head { border-bottom: 3px solid var(--red); padding-bottom: 6px;
  display: flex; justify-content: space-between; align-items: baseline; }
.roster-head small { color: var(--faint); font-weight: 800; font-size: 12px; letter-spacing: .04em; }
.roster-head-dark { border-bottom-color: var(--side); }
/* Archived users: collapsed by default; the summary reads like a roster heading. */
.roster-archived { margin-top: 0; }
.roster-archived > summary { cursor: pointer; list-style: none; font-size: 15px; font-weight: 800;
  letter-spacing: -.01em; margin: 18px 0 8px; }
.roster-archived > summary::-webkit-details-marker { display: none; }
.roster-archived > summary::before { content: "▸"; color: var(--faint); margin-right: 8px; }
.roster-archived[open] > summary::before { content: "▾"; }
.roster-archived > summary small { margin-left: auto; }

/* FOH / BOH split under a position heading (directory, plan week, dashboard) */
.position-side { margin-left: 18px; }
/* Every group's rows get the same indent, with or without a FOH/BOH heading,
   so the leader-row columns line up across groups. */
.position-members { margin-left: 18px; }
@media (max-width: 640px) { .position-side, .position-members { margin-left: 10px; } }
.position-sub { font-size: 11.5px; margin: 12px 0 6px; text-transform: uppercase;
  letter-spacing: .06em; font-weight: 800; color: var(--dim); }
.position-sub small { color: var(--faint); font-weight: 700; }

/* ---------- Plan Week sticky action bar + autosave status ---------- */
.plan-actions { position: sticky; bottom: 0; z-index: 5; display: flex; align-items: center;
  justify-content: flex-end; gap: 14px; margin-top: 16px; padding: 12px 14px;
  background: var(--card); border: 1px solid var(--line2); border-top: 3px solid var(--ink);
  box-shadow: 0 -4px 12px rgba(0,0,0,.06); }
.autosave-status { font-size: 12px; font-weight: 700; color: var(--dim); margin-right: auto; }
.autosave-status.is-saved { color: var(--green); }
.autosave-status.is-saved::before { content: "✓ "; }
.autosave-status.is-error { color: var(--red); }
.autosave-status.is-pending, .autosave-status.is-saving { color: var(--amber); }

/* ---------- "add a person" panels (directory, candidates, 1:1s) ---------- */
.add-panel { border-top: 4px solid var(--ink); padding: 16px 18px; margin: 14px 0 22px; }
.add-panel-title { margin: 0 0 12px; font-size: 13px; text-transform: uppercase;
  letter-spacing: .06em; font-weight: 800; }
.add-panel-fields { display: flex; flex-wrap: wrap; gap: 12px 14px; align-items: flex-end; }
.add-panel .field { display: flex; flex-direction: column; gap: 5px; flex: 1 1 160px; min-width: 0; }
.add-panel .field-wide { flex: 2 1 220px; }
.add-panel .field-action { flex: 0 0 auto; }
.add-panel .field > span { font-size: 11px; font-weight: 800; text-transform: uppercase;
  letter-spacing: .06em; color: var(--dim); }
.add-panel .field > span em { font-style: normal; font-weight: 700; color: var(--faint);
  text-transform: none; letter-spacing: 0; }
.add-panel input, .add-panel select { width: 100%; height: 40px; padding: 0 10px; font-size: 14px;
  color: var(--ink); background: #fff; border: 1px solid var(--line2); border-bottom: 2px solid #c9ccc3;
  border-radius: var(--r); }
.add-panel input:focus, .add-panel select:focus { outline: none; border-color: var(--ink); }
.add-panel .btn { height: 40px; white-space: nowrap; }
@media (max-width: 640px) {
  .add-panel .field, .add-panel .field-wide { flex-basis: 100%; margin: 0; }
  .content form.add-panel label { display: flex; margin: 0; }
  .add-panel .field-action, .add-panel .btn { width: 100%; }
}

/* ---------- application review cards (applications page) ---------- */
.app-list { display: grid; gap: 16px; }
.app-card { background: var(--card); border: 1px solid var(--line2); border-top: 4px solid var(--ink);
  border-radius: var(--r); padding: 18px 20px; }
.app-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px;
  flex-wrap: wrap; padding-bottom: 12px; border-bottom: 1px solid var(--line); }
.app-name { margin: 0 0 6px; font-size: 20px; letter-spacing: -.01em; }
.app-meta { display: flex; gap: 6px; flex-wrap: wrap; }
.app-chip { font-size: 11px; font-weight: 800; text-transform: uppercase; letter-spacing: .04em;
  background: var(--panel); border: 1px solid var(--line2); padding: 3px 8px; }
.app-chip-pos { background: var(--ink); color: #fff; border-color: var(--ink); }
.app-date { font-size: 12px; color: var(--dim); white-space: nowrap; }
.app-facts { display: flex; gap: 28px; flex-wrap: wrap; padding: 12px 0 0; }
.app-label { display: block; font-size: 11px; font-weight: 800; text-transform: uppercase;
  letter-spacing: .06em; color: var(--dim); margin-bottom: 4px; }
.app-answer { padding-top: 14px; }
.app-answer p { margin: 0; line-height: 1.5; white-space: pre-wrap; overflow-wrap: anywhere; max-width: 75ch; }
.app-values { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.app-value { background: var(--panel); border: 1px solid var(--line); padding: 10px 12px; }
.app-value strong { font-size: 13px; }
.app-value ol { margin: 6px 0 0; padding-left: 18px; line-height: 1.45; }
.app-value li { margin-bottom: 4px; overflow-wrap: anywhere; }
.app-value p { margin: 6px 0 0; }
.app-actions { display: flex; align-items: center; gap: 8px; flex-wrap: wrap;
  margin-top: 18px; padding-top: 14px; border-top: 1px solid var(--line); }
.app-actions form { margin: 0; }
.app-link-form { display: flex; gap: 6px; }
.app-link-form select { min-width: 200px; }
.app-actions-spacer { flex: 1; }
.app-prereqs { margin-top: 12px; background: var(--panel); border: 1px solid var(--line); padding: 10px 12px; }
.prereq-list { list-style: none; margin: 4px 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: 6px 18px; }
.prereq { font-weight: 700; font-size: 14px; }
.prereq-mark { display: inline-block; width: 1.2em; font-weight: 900; }
.prereq-done .prereq-mark { color: var(--green); }
.prereq-todo .prereq-mark { color: var(--red); }
.prereq-wait .prereq-mark { color: var(--amber); }
.prereq-date { margin-left: 6px; font-size: 12px; font-weight: 400; color: var(--dim); }
.prereq-flag { margin: 8px 0 0; font-size: 12px; font-weight: 800; color: var(--red); }
.prereq-open { display: inline-block; margin-top: 8px; font-size: 12px; font-weight: 800; }
@media (max-width: 640px) {
  .app-card { padding: 14px; }
  .app-values { grid-template-columns: 1fr; }
  .app-actions-spacer { display: none; }
  .app-link-form { width: 100%; }
  .app-link-form select { flex: 1; min-width: 0; }
}

/* ---------- application answers on the candidate page ---------- */
.app-notes-view { border-top: 4px solid var(--ink); padding: 16px 18px; max-width: 900px; }
.app-notes-view .app-answer:first-child, .app-notes-view .add-panel-title + .app-answer { padding-top: 4px; }
.app-notes-view .add-panel-title { margin-top: 14px; }
.app-notes-view .add-panel-title:first-child { margin-top: 0; }
.app-notes-edit-hint { margin: 14px 0 0; }
.app-notes-legacy > summary { list-style: none; cursor: pointer; }
.app-notes-legacy > summary::-webkit-details-marker { display: none; }
.app-notes-preview { display: block; line-height: 1.5; color: var(--ink); max-width: 75ch; }
.app-notes-more { display: inline-block; margin-top: 8px; font-size: 11px; font-weight: 800;
  text-transform: uppercase; letter-spacing: .06em; color: var(--blue); }
.app-notes-legacy[open] .app-notes-preview { display: none; }
.app-notes-legacy[open] .app-notes-more::after { content: " — Hide"; }
.app-notes-legacy[open] .app-notes-more { font-size: 0; }
.app-notes-legacy[open] .app-notes-more::after { font-size: 11px; content: "Hide"; }
textarea.notes-wide { width: 100%; max-width: 900px; font-size: 14px; line-height: 1.5; padding: 8px 10px; }

/* ---------- public application links (applications page) ---------- */
.apply-links { border-top: 4px solid var(--ink); padding: 16px 18px; margin: 28px 0 10px; }
.apply-links .note { margin: -4px 0 12px; }
.apply-link-row { display: grid; grid-template-columns: 120px minmax(0, 1fr) auto; align-items: center;
  gap: 12px; padding: 10px 0; border-top: 1px solid var(--line); }
.apply-link-team { font-weight: 800; font-size: 14px; }
.apply-link-url { width: 100%; height: 40px; padding: 0 10px; font-size: 14px; color: var(--blue);
  background: var(--panel); border: 1px solid var(--line2); border-radius: var(--r);
  text-overflow: ellipsis; cursor: text; }
.apply-link-url:focus { outline: none; border-color: var(--ink); background: #fff; }
.apply-link-actions { display: flex; gap: 8px; }
.apply-link-actions .btn-secondary, .apply-link-actions .btn-ghost { height: 40px; display: inline-flex;
  align-items: center; justify-content: center; white-space: nowrap; text-decoration: none; }
.apply-link-actions .btn-secondary { min-width: 116px; }
.apply-qr { grid-column: 2 / -1; display: flex; align-items: center; gap: 16px; flex-wrap: wrap; }
.apply-qr-img { width: 164px; height: 164px; image-rendering: pixelated; background: #fff;
  border: 1px solid var(--line2); border-radius: var(--r); }
@media (max-width: 640px) {
  .apply-link-row { grid-template-columns: 1fr; gap: 8px; }
  .apply-qr { grid-column: 1; }
  .apply-link-actions > * { flex: 1; }
}

/* Heavy rule (sidebar colour) separating users (Team Leads/Trainers/Senior Trainers) from
   Admins, Super admins, and Owners on the directory. */
.roster-divider { border: 0; height: 8px; background: var(--side); margin: 40px 0 8px; }
.roster-divider-red { background: var(--red); }

/* ---------- access chips (directory) ---------- */
.acc { font-size:9.5px; text-transform:uppercase; letter-spacing:.04em; font-weight:800;
  padding:3px 8px; background:#eef0ec; color:#4a5040; white-space:nowrap; border-radius: var(--r); }
.acc.super { background:var(--ink); color:#fff; }
.acc.admin { background:var(--blue); color:#fff; }
.acc.manager { background:#e8eef7; color:var(--blue); }
.acc.owner { background:var(--red); color:#fff; }

/* ---------- security matrix ---------- */
.security-matrix th, .security-matrix td { text-align: center; }
.security-matrix th:first-child, .security-matrix td:first-child { text-align: left; }
.security-matrix .sec-group th { background: var(--panel); text-align: left;
  font-size: 11px; text-transform: uppercase; letter-spacing: .06em; color: var(--dim); }
.security-matrix .sec-yes { color: var(--green); font-weight: 800; }
.security-matrix .sec-no { color: #c7c7c7; }

/* ---------- certify: team heading + leader disclosure ---------- */
.cert-team-heading { margin: 28px 0 8px; font-size: 12px; text-transform: uppercase;
  letter-spacing: 0.1em; color: var(--ink); font-weight: 800;
  border-bottom: 3px solid var(--red); padding-bottom: 6px; }
.cert-team-heading:first-of-type { margin-top: 0; }
.cert-leader > summary { cursor: pointer; list-style: none;
  display: flex; align-items: baseline; gap: 8px; padding: 4px 0; }
.cert-leader > summary::-webkit-details-marker { display: none; }
.cert-leader > summary::before { content: "\25B6"; color: var(--red); font-size: 15px; width: 14px;
  display: inline-block; transition: transform 0.1s ease; }
.cert-leader[open] > summary::before { transform: rotate(90deg); }
.cert-leader > summary:hover .cert-leader-name { color: var(--red); }
.cert-leader-name { font-weight: 800; font-size: 15px; }
.cert-leader-stat { margin-left: auto; font-variant-numeric: tabular-nums; font-weight: 800; }
.cert-leader-stat.stat-lagging { color: var(--red); font-weight: 800; }
.cert-leader[open] > summary { margin-bottom: 10px; padding-bottom: 10px; border-bottom: 2px solid var(--line); }

.plan-note-input { width: 100%; min-width: 200px; }
.week-note { background: #fff8e1; border-left: 4px solid var(--amber);
  padding: 10px 12px; margin: 0 0 12px 0; border-radius: var(--r); white-space: pre-wrap; }
.legend { margin-top: 20px; padding: 10px 14px; background: var(--panel);
  border-radius: var(--r); font-size: 13px; color: var(--dim); }
.legend span { display: inline-block; margin: 0 12px 0 0; }

/* ---------- module rows ---------- */
.mod-row { display: flex; justify-content: space-between; align-items: center; gap: 16px;
  padding: 14px 4px; border-bottom: 1px solid var(--line); }
.mod-row:last-child { border-bottom: none; }
.mod-left { display: flex; align-items: center; gap: 10px; flex: 1; min-width: 0; }
.mod-left .mod-icon { font-size: 18px; flex-shrink: 0; width: 24px; text-align: center; }
.mod-left .mod-name { font-size: 15px; font-weight: 700; color: var(--ink); text-decoration: none; }
.mod-left a.mod-name:hover { text-decoration: underline; }
.mod-left .resource-link { font-size: 16px; opacity: 0.65; text-decoration: none; margin-left: 2px; }
.mod-left .resource-link:hover { opacity: 1; }
.mod-meta { font-size: 13px; color: var(--faint); font-variant-numeric: tabular-nums; }
.mod-right { flex-shrink: 0; display: flex; align-items: center; gap: 10px; }
.mod-state-done { color: var(--green); font-size: 13px; font-weight: 700; }
.mod-state-awaiting { color: var(--dim); font-size: 13px; font-style: italic; }
.inline-form { display: inline; margin: 0; }
.section-name { display: block; font-size: 14px; text-transform: uppercase; letter-spacing: 0.5px;
  color: var(--dim); margin-bottom: 4px; }
.obj-caption { display: block; font-size: 11px; font-weight: 800; text-transform: uppercase;
  letter-spacing: 0.05em; color: var(--faint); margin-bottom: 2px; }
.obj-caption.week-obj { margin-top: 10px; }
.plan-table td { border-bottom: none; }
/* Plan Week dropdowns (Week, Admin): rounded, soft border, custom chevron.
   A planned week turns green so scheduled rows stand out. */
.plan-table select { appearance: none; -webkit-appearance: none; font: inherit; font-size: 13px; font-weight: 600;
  color: var(--ink); background: #fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath d='M3 4.5l3 3 3-3' fill='none' stroke='%236f7668' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") no-repeat right 10px center;
  border: 1px solid var(--line2); border-radius: 8px; padding: 7px 32px 7px 11px; min-width: 150px; cursor: pointer;
  box-shadow: 0 1px 2px rgba(20,24,29,.04); transition: border-color .15s, box-shadow .15s, background-color .15s; }
.plan-table select:hover:not(:disabled) { border-color: #c9ccc2; }
.plan-table select:focus { outline: none; border-color: var(--blue); box-shadow: 0 0 0 3px rgba(47,74,114,.15); }
.plan-table select:disabled { background-color: var(--panel); color: var(--faint); cursor: default; box-shadow: none; }
.plan-table select.is-set { background-color: #eaf3ee; border-color: #b9d6c4; color: #1f5135; }
.plan-table .plan-note-input { font: inherit; font-size: 13px; border: 1px solid var(--line2); border-radius: 8px; padding: 7px 11px;
  background: #fff; transition: border-color .15s, box-shadow .15s; }
.plan-table .plan-note-input:focus { outline: none; border-color: var(--blue); box-shadow: 0 0 0 3px rgba(47,74,114,.15); }
.plan-table .plan-note-input:disabled { background: var(--panel); }
.plan-table .obj-group-row td { border-top: 1px solid var(--line2); padding-top: 12px; }
.plan-table .obj-group-first td { border-top: none; }
.obj-group-name { font-size: 11px; font-weight: 800; text-transform: uppercase;
  letter-spacing: 0.05em; color: var(--faint); }

/* ---------- certify rows ---------- */
.cert-row { border-top: 1px solid var(--line); padding: 14px 0; }
.cert-row:first-of-type { border-top: 0; padding-top: 4px; }
.cert-row-header { display: flex; justify-content: space-between; align-items: baseline;
  margin-bottom: 8px; gap: 12px; flex-wrap: wrap; }
.cert-row .mod-name { font-weight: 800; font-size: 15px; }
.cert-row .mod-meta { font-size: 12px; }
.cert-row textarea, .lp-open textarea { width: 100%; min-height: 140px; font-family: inherit; font-size: 14px;
  line-height: 1.5; padding: 10px 12px; border:1px solid #ccc; border-radius: var(--r); resize: vertical; }
.cert-actions { margin-top: 10px; display: flex; gap: 8px; }

/* ---------- status pills: solid, uppercase ---------- */
.pill { display: inline-block; padding: 3px 9px; border-radius: var(--r);
  font-size: 10px; font-weight: 800; text-transform: uppercase; letter-spacing: .05em; }
.pill-not_started { background:#eef0ec; color:#4a5040; }
.pill-in_progress { background: var(--amber); color:#231800; }
.pill-scheduled   { background: var(--blue); color:#fff; }
.pill-completed   { background: var(--green); color:#fff; }
.pill-overdue-1   { background: var(--amber); color:#231800; }
.pill-overdue-2   { background: var(--red); color:#fff; }
.pill-retired     { background:#eef0ec; color: var(--faint); }
.retire-form { margin-top: 6px; }
.archived-badge { display: inline-block; padding: 2px 6px; border-radius: var(--r);
  background:#eef0ec; color: var(--dim); font-size: 10px; font-weight:800; text-transform:uppercase;
  letter-spacing:.04em; margin-left: 6px; }
.standing-badge { display: inline-block; padding: 2px 6px; border-radius: var(--r);
  background: var(--red); color:#fff; font-size: 9.5px; font-weight: 800; text-transform:uppercase;
  letter-spacing:.04em; margin-left: 6px; }
/* No email = can't sign in or get mail: an amber tag with a lock so it's easy to spot. */
.nologin-badge { background: #fff1e0; color: #a35f00; border: 1px solid #f5c98a; }
.nologin-badge::before { content: "🔒 "; }

/* ---------- Candidate Check-Ins (candidate_detail.html) ---------- */
#check-ins small { font-weight: 700; font-size: 12px; }
.ci-add { background: var(--panel); padding: 12px; display: grid; gap: 8px; max-width: 760px; }
.ci-add label { font-weight: 600; font-size: 13px; }
.ci-add textarea, .ci-edit textarea { width: 100%; font: inherit; resize: vertical; }
.ci-add-row { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.ci-add .ci-add-row .btn { margin-left: auto; }
.ci-list { list-style: none; margin: 10px 0 0; padding: 0; max-width: 760px; }
.ci { display: grid; grid-template-columns: 74px minmax(0, 1fr); gap: 12px; padding: 12px 0; border-top: 1px solid var(--line2); }
.ci:first-child { border-top: 0; }
.ci-when { font-weight: 800; font-size: 13px; font-variant-numeric: tabular-nums; }
.ci-when small { display: block; color: var(--faint); font-weight: 600; font-size: 11px; }
.ci-meta { display: flex; align-items: center; gap: 6px; font-size: 12px; color: var(--dim); margin-bottom: 2px; }
.ci-acts { margin-left: auto; display: flex; align-items: center; }
.ci-acts[hidden] { display: none; }
.ci-acts form { margin: 0; }
.ci-link { background: none; border: 0; color: var(--dim); padding: 4px 6px; font-weight: 600; font-size: 12px; cursor: pointer; }
.ci-link:hover { color: var(--ink); }
.ci-del:hover, .ci-del[data-armed] { color: var(--red); }
.ci-body { white-space: pre-wrap; }
.ci-edit { display: grid; gap: 6px; }
.ci-earlier { background: var(--panel); padding: 12px; margin-top: 6px; border-top: 0; }
.ci-earlier-body summary { cursor: pointer; list-style: none; }
.ci-earlier-body summary::-webkit-details-marker { display: none; }
.ci-earlier-body .ci-body { font-size: 12.5px; color: var(--dim); display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.ci-earlier-body[open] .ci-body { display: block; }
.ci-earlier-body summary::after { content: "Show All"; display: block; margin-top: 4px; font-size: 12px; font-weight: 600; color: var(--dim); text-decoration: underline; }
.ci-earlier-body[open] summary::after { content: "Show Less"; }
@media (max-width: 600px) { .ci { grid-template-columns: 1fr; gap: 4px; } }

/* ---------- candidate vote dots ---------- */
.app-check { color: var(--green); font-weight:800; }
.vote-dots, .vote-summary { display:inline-flex; align-items:center; gap:5px; flex-wrap:wrap; }
.vote-dot { display:inline-block; width:12px; height:12px; border-radius:50%;
  border:1px solid rgba(0,0,0,.15); flex:0 0 auto; }
.vote-green  { background: var(--green); }
.vote-yellow { background: var(--amber); }
.vote-red    { background: var(--red); }
.vote-none   { background: var(--faint); }

/* ---------- 1:1 page ---------- */
.oo-exp-list { list-style: none; padding: 0; margin: 0; }
.oo-exp-row { display: flex; align-items: center; gap: 8px; padding: 8px 0;
  border-bottom: 1px solid var(--line); flex-wrap: wrap; }
.oo-exp-text { flex: 1 1 auto; }
.oo-exp-actions { display: flex; gap: 6px; flex-wrap: wrap; }
.oo-note { border-bottom: 1px solid var(--line); padding: 10px 0; }
.oo-note-body { white-space: pre-wrap; }

/* ---------- curriculum tree ---------- */
.tree-role, .tree-objective, .tree-module, .tree-quiz, .tree-question, .tree-archived {
  border-left: 2px solid var(--line2); margin: 6px 0; padding: 2px 0; }
.tree-role { border-left-color: var(--red); }
.tree-role > summary, .tree-objective > summary, .tree-module > summary,
.tree-quiz > summary, .tree-question > summary, .tree-archived > summary {
  cursor: pointer; padding: 6px 10px; list-style: none;
  display: flex; align-items: baseline; gap: 10px; }
/* Edit toggle stays inside its own <summary> so it shares the name's line;
   Safari renders all non-summary <details> content as one block box, so a
   sibling toggle can't be pulled onto the line by CSS. Open -> own line. */
.tree-role > summary > details.row-edit[open],
.tree-objective > summary > details.row-edit[open],
.tree-module > summary > details.row-edit[open],
.tree-quiz > summary > details.row-edit[open],
.tree-question > summary > details.row-edit[open] { display: block; margin-left: 0; }
.tree-module > summary { flex-wrap: wrap; }
.tree-module > summary > .row-meta { flex-basis: 100%; }
.tree-role > summary::-webkit-details-marker,
.tree-objective > summary::-webkit-details-marker,
.tree-module > summary::-webkit-details-marker,
.tree-quiz > summary::-webkit-details-marker,
.tree-question > summary::-webkit-details-marker,
.tree-archived > summary::-webkit-details-marker { display: none; }
.tree-role > summary::before, .tree-objective > summary::before,
.tree-module > summary::before, .tree-quiz > summary::before,
.tree-question > summary::before, .tree-archived > summary::before {
  content: "\25B6"; color: var(--faint); font-size: 15px; width: 15px;
  display: inline-block; transition: transform 0.1s ease; }
.tree-role > summary::before { color: var(--red); }
.tree-role[open] > summary::before, .tree-objective[open] > summary::before,
.tree-module[open] > summary::before, .tree-quiz[open] > summary::before,
.tree-question[open] > summary::before,
.tree-archived[open] > summary::before { transform: rotate(90deg); }
.tree-role > summary:hover, .tree-objective > summary:hover,
.tree-module > summary:hover, .tree-quiz > summary:hover,
.tree-question > summary:hover, .tree-archived > summary:hover { background: var(--panel); }
.tree-role > .tree-body, .tree-objective > .tree-body,
.tree-module > .tree-body, .tree-quiz > .tree-body,
.tree-question > .tree-body, .tree-archived > .tree-body { padding: 4px 0 4px 22px; }
.tree-role[data-key^="role-"][open] { border-left-width: 3px; background: #fceeef; }
main.content:has(> .tree-role[data-key^="role-"][open])
  > .tree-role[data-key^="role-"]:not([open]) { opacity: 0.55; transition: opacity 0.2s ease; }
.row-name { font-weight: 700; font-size: 14px; }
.tree-role > summary .row-name { font-size: 15px; font-weight: 800; text-transform: uppercase; letter-spacing: -.01em; }
.tree-objective > summary .row-name { font-size: 14px; }
.row-meta { font-size: 11px; color: var(--faint); text-transform: uppercase; letter-spacing: 0.05em; font-weight: 700; }

.row-edit { margin: 4px 0 8px; }
.row-edit > summary { cursor: pointer; color: var(--dim); font-size: 12px; padding: 2px 0; list-style: none; }
.row-edit > summary::-webkit-details-marker { display: none; }
.row-edit > summary:hover { color: var(--ink); }
.row-edit-body { padding: 6px 0 6px 16px; display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.tree-add { padding: 6px 0; display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.tree-options { margin: 6px 0; padding-left: 18px; }
.tree-options li { padding: 2px 0; }
.resource-row { display: flex; align-items: center; gap: 6px; padding: 3px 0; }

.table-scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; }

/* ===== Mobile (≤640px) ===== */
@media (max-width: 640px) {
  .layout { flex-direction: column; }
  /* Menu folds behind ☰ in a top bar. */
  .sidebar { width: auto; height: auto; padding: 0 12px; z-index: 20; border-right: 0; border-bottom: 3px solid var(--red); }
  .nav-top { height: 52px; padding: 0 4px; }
  .nav-toggle { all: unset; display: grid; gap: 4px; margin-left: auto; padding: 10px; cursor: pointer; color: #fff; }
  .nav-toggle i { display: block; width: 20px; height: 2px; background: currentColor; }
  .nav-toggle:focus-visible { outline: 2px solid #fff; }
  .sidebar .nav-links, .sidebar .nav-whoami { display: none; }
  .sidebar.open { max-height: 100vh; overflow-y: auto; }
  .sidebar.open .nav-links { display: flex; padding-bottom: 8px; }
  .sidebar.open .nav-whoami { display: block; padding-bottom: 12px; }
  .nav-user-menu { position: static; margin-bottom: 6px; }
  .sidebar a, .sidebar .nav-group > summary { font-size: 15px; padding: 10px; }
  .content { padding: 16px; }

  .team-strip { grid-template-columns: 1fr auto; }
  .team-strip .ts-name { border-right: 0; padding-right: 0; min-width: 0; }
  .team-strip .ts-vow { grid-column: 1 / -1; grid-row: 2; text-align: left; }
  .team-strip .ts-switch { grid-column: 2; }

  input, select, textarea { font-size: 16px; }
  .content input:not([type=radio]):not([type=checkbox]):not([type=hidden]),
  .content select, .content textarea { width: 100%; max-width: 100%; }
  .content form label { display: block; margin: 8px 0; }

  .btn, .btn-ghost, .btn-danger, .btn-secondary { min-height: 40px; padding: 11px 16px; font-size: 12px; }

  .cert-actions { flex-wrap: wrap; }
  .cert-actions > .btn, .cert-actions > .btn-secondary { flex: 1 1 140px; text-align: center; }

  .mod-row { flex-wrap: wrap; gap: 8px 12px; }
  .mod-right { width: 100%; justify-content: flex-start; }
  .mod-right .btn { width: 100%; text-align: center; }

  .scoreboard { grid-template-columns: 1fr 1fr; }

  /* Directory: table -> stacked cards */
  table.cards, table.cards > tbody { display: block; width: 100%; }
  table.cards > colgroup, table.cards > thead { display: none; }
  table.cards > tbody > tr { display: block; border: 1px solid var(--line2); border-radius: var(--r);
    padding: 10px 12px; margin: 0 0 10px; }
  table.cards > tbody > tr > td { display: flex; justify-content: space-between; gap: 12px;
    padding: 4px 0; border: none; text-align: right; overflow-wrap: anywhere; }
  table.cards > tbody > tr > td::before { content: attr(data-label); font-weight: 800; color: var(--dim);
    text-align: left; text-transform: uppercase; font-size: 11px; letter-spacing: .04em;
    flex: none; white-space: nowrap; }
  table.cards > tbody > tr > td.card-title { display: block; text-align: left; font-size: 17px;
    font-weight: 800; padding: 0 0 6px; margin-bottom: 4px; border-bottom: 2px solid var(--red); }
  table.cards > tbody > tr > td.card-title::before { content: none; }
  table.cards > tbody > tr > td.card-title a { text-decoration: none; }
}

/* ---------- candidate notes preview ---------- */
.cand-notes { font-size: 13px; color: var(--dim); max-width: 320px; }
.note-expand > summary { cursor: pointer; list-style: none; display: flex; align-items: flex-start; gap: 6px; text-align: left; }
.note-expand > summary::-webkit-details-marker { display: none; }
.note-expand > summary::before { content: "\25B6"; color: var(--faint); font-size: 10px; width: 10px;
  flex: none; line-height: 1.8; transition: transform 0.1s ease; }
.note-expand[open] > summary::before { transform: rotate(90deg); }
.note-expand > summary:hover { color: var(--red); }
.note-text { display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 1; overflow: hidden; }
.note-expand[open] .note-text { -webkit-line-clamp: unset; overflow: visible; }

/* ---------- certify ownership queues (dashboard) ---------- */
.cert-queue { margin: 0 0 24px; }
.cert-queue-title { font-size: 13px; margin: 20px 0 8px; text-transform: uppercase;
  letter-spacing: .06em; font-weight: 800; }
.cert-queue-title .muted { font-weight: 700; font-size: 11px; letter-spacing: .03em; }
.cert-queue .queue-item { margin-bottom: 12px; }
.cert-queue .queue-leader { font-weight: 800; font-size: 13px; color: var(--ink); margin-bottom: 2px; }
/* My queue = the green "you're on" callout; Unassigned = muted foot strip. */
.cert-queue-mine { background:#f0f8f3; border:2px solid var(--green); border-left-width:6px;
  padding: 12px 15px; border-radius: var(--r); }
.cert-queue-mine > .cert-queue-title { margin-top: 0; color:#0f6b3f; }
.cert-queue-unassigned { background: var(--panel); border-left: 5px solid var(--faint);
  padding: 11px 14px; border-radius: var(--r); }
.cert-queue-unassigned > summary { cursor: pointer; list-style: none; margin: 0;
  display: flex; align-items: baseline; gap: 8px; text-transform: uppercase;
  letter-spacing: .05em; font-weight: 800; font-size: 12px; color: var(--dim); }
.cert-queue-unassigned > summary::-webkit-details-marker { display: none; }
.cert-queue-unassigned > summary::before { content: "\25B6"; color: var(--faint); font-size: 14px;
  width: 14px; display: inline-block; transition: transform 0.1s ease; }
.cert-queue-unassigned[open] > summary::before { transform: rotate(90deg); }
.cert-queue-upcoming { margin-top: 14px; border-top: 1px dashed var(--line2); padding-top: 10px; }
.cert-queue-upcoming > summary { cursor: pointer; list-style: none; }
.cert-queue-upcoming > summary::-webkit-details-marker { display: none; }
.cert-queue-upcoming > summary::before { content: "\25B6"; color: var(--faint); font-size: 13px;
  width: 13px; display: inline-block; transition: transform 0.1s ease; }
.cert-queue-upcoming[open] > summary::before { transform: rotate(90deg); }
.cert-queue-upcoming .upcoming-week { margin: 8px 0 8px 20px; }
.cert-queue-upcoming .upcoming-week-label { font-size: 13px; color: var(--dim); font-weight: 700; }
.cert-queue-upcoming .upcoming-list { margin: 4px 0 0; padding-left: 18px; font-size: 13px; color: var(--dim); }
.cert-queue-unassigned[open] > summary { margin-bottom: 8px; }
.queue-item-collapsible { margin-bottom: 4px; }
.queue-item-collapsible > summary { cursor: pointer; list-style: none;
  display: flex; align-items: baseline; gap: 8px; padding: 3px 0; }
.queue-item-collapsible > summary::-webkit-details-marker { display: none; }
.queue-item-collapsible > summary::before { content: "\25B6"; color: var(--green); font-size: 15px;
  width: 14px; display: inline-block; transition: transform 0.1s ease; }
.queue-item-collapsible[open] > summary::before { transform: rotate(90deg); }
.queue-item-collapsible > summary .queue-leader { margin-bottom: 0; }
.queue-item-collapsible > summary .queue-module { font-size: 13px; color: var(--ink); font-weight: 700; }
.queue-item-collapsible > summary:hover .queue-module { color: var(--red); }

/* ---------- app feedback widget (leader home) ----------
   Pure CSS: radios precede .fb-opts and .fb-follow, so :checked ~ sibling
   selectors highlight the chosen star option and reveal only its follow-up
   question. No JS. */
.fb-card { border: 2px solid var(--line); border-left: 6px solid var(--amber);
  border-radius: var(--r); padding: 14px 16px; margin: 14px 0 20px; background: var(--card); }
.fb-thanks { color: var(--green); font-weight: 800; margin-bottom: 8px; }
.fb-q { font-weight: 800; text-transform: uppercase; letter-spacing: .02em; font-size: 14px; margin-bottom: 10px; }
.fb-radio { position: absolute; width: 1px; height: 1px; opacity: 0; pointer-events: none; }
.fb-opts { display: flex; gap: 10px; flex-wrap: wrap; }
.fb-opt { display: flex; flex-direction: column; align-items: center; gap: 4px; cursor: pointer;
  border: 2px solid var(--line); border-radius: var(--r); padding: 8px 16px; min-width: 92px; }
.fb-opt:hover { border-color: var(--amber); }
.fb-stars { color: #d9d9d3; font-size: 22px; letter-spacing: 2px; line-height: 1; }
.fb-cap { font-size: 10px; text-transform: uppercase; letter-spacing: .05em; font-weight: 800; color: var(--dim); }
#fb3:checked ~ .fb-opts label[for="fb3"],
#fb2:checked ~ .fb-opts label[for="fb2"],
#fb1:checked ~ .fb-opts label[for="fb1"] { border-color: var(--red); background: #fff6f2; }
#fb3:checked ~ .fb-opts label[for="fb3"] .fb-stars,
#fb2:checked ~ .fb-opts label[for="fb2"] .fb-stars,
#fb1:checked ~ .fb-opts label[for="fb1"] .fb-stars { color: var(--amber); }
#fb3:focus-visible ~ .fb-opts label[for="fb3"],
#fb2:focus-visible ~ .fb-opts label[for="fb2"],
#fb1:focus-visible ~ .fb-opts label[for="fb1"] { outline: 2px solid var(--blue); outline-offset: 2px; }
.fb-follow { display: none; margin-top: 12px; }
#fb3:checked ~ .fb-follow[data-r="3"],
#fb2:checked ~ .fb-follow[data-r="2"],
#fb1:checked ~ .fb-follow[data-r="1"] { display: block; }
.fb-follow label { display: block; font-weight: 700; margin-bottom: 6px; }
.fb-follow textarea { width: 100%; max-width: 520px; font: inherit; padding: 9px 11px;
  border: 1px solid #ccc; border-radius: var(--r); resize: vertical; }
.fb-follow .btn { margin-top: 10px; }

/* ---------- app feedback results (owner dashboard) ---------- */
.fb-results { border: 2px solid var(--line); border-left: 6px solid var(--amber);
  border-radius: var(--r); padding: 14px 16px; margin: 22px 0; background: var(--card); }
.fb-results > h3 { margin-top: 0; }
.fb-results h3 small { color: var(--dim); font-weight: 700; font-size: 12px; letter-spacing: .03em; }
.fb-bars { display: flex; gap: 16px; margin: 2px 0 12px; font-size: 13px; font-weight: 700;
  font-variant-numeric: tabular-nums; }
.fb-bars .fb-b b { color: var(--amber); letter-spacing: 1px; margin-right: 4px; }
.fb-list { list-style: none; padding: 0; margin: 0; }
.fb-item { display: flex; gap: 12px; padding: 10px 0; border-top: 1px solid var(--line); }
.fb-item:first-child { border-top: none; }
.fb-item-stars { color: var(--amber); font-size: 15px; letter-spacing: 1px; flex: none; width: 46px; }
.fb-item.fb-r1 .fb-item-stars { color: var(--red); }
.fb-item-body { flex: 1; min-width: 0; }
.fb-item-comment { font-size: 14px; overflow-wrap: anywhere; }
.fb-nocomment { color: var(--faint); font-style: italic; }
.fb-item-meta { font-size: 11px; color: var(--dim); text-transform: uppercase; letter-spacing: .04em; font-weight: 700; margin-top: 3px; }

/* ---------- org chart ---------- */
/* Main branch: the head owner, people reporting straight to them on a side
   arm, then one column per restaurant with a row per leadership level (labels
   down the left). Other owners sit to the right with their reports fanned out.
   Connectors are 2px pseudo-element lines in --oc. */
/* The frame never widens the page (contain: inline-size); the chart inside is
   laid out at its natural size and zoomed down by the page script to fit. */
.orgchart { overflow-x: auto; padding: 1rem 0 1rem; contain: inline-size; --oc: #c4c8bd; --bp: 12px;
  --cards-w: 456px; }
.org2 { position: relative; display: flex; align-items: flex-start; gap: 36px; width: max-content;
  padding-top: 22px; }
/* Bar over the owners' cards joining them (placed by the page script). */
.org2-heads-link { position: absolute; height: 18px; border: 2px solid var(--oc); border-bottom: 0; }
.org2-main { flex: 1 0 auto; display: grid;
  grid-template-columns: repeat(var(--cols), minmax(calc(var(--cards-w) + 16px), 1fr)); }
.org2-span { grid-column: 1 / -1; display: flex; flex-direction: column; align-items: center; }
.org2-headrow::after { content: ""; width: 2px; height: 18px; background: var(--oc); }
/* Room below the head for the side arm's cards before the restaurant fork. */
.org2-headrow.has-assist::after { height: 50px; }
.org2-headwrap { position: relative; display: flex; }
.org2-assist-link { position: absolute; left: 100%; top: 50%; width: 100px; height: calc(50% - 18px);
  border-top: 2px solid var(--oc); border-right: 2px solid var(--oc); }
.org2-assist-cards { position: absolute; left: calc(100% + 30px); top: calc(100% - 18px);
  display: flex; gap: 8px; }

.org2-cell { position: relative; display: flex; justify-content: center; align-items: center; }
.org2-fork { padding-top: 18px; align-items: flex-end; }
.org2-fork::before { content: ""; position: absolute; top: 0; height: 2px; background: var(--oc);
  left: 0; right: 0; }
.org2-fork.is-first::before { left: 50%; }
.org2-fork.is-last::before { right: 50%; }
.org2-fork:not(.is-first):not(.is-mid):not(.is-last)::before { display: none; }
.org2-fork::after { content: ""; position: absolute; top: 0; left: calc(50% - 1px); width: 2px;
  height: 18px; background: var(--oc); }
.org2-team { position: relative; z-index: 1; background: var(--side); color: #fff; padding: 6px 14px;
  font-size: 11px; font-weight: 800; text-transform: uppercase; letter-spacing: .08em; }

.org2-band { border-top: 1px dashed var(--line2); padding: var(--bp) 8px; min-height: 56px; }
.org2-cell.org2-band { align-items: flex-start; }
.org2-cell.org2-band.has-people::before, .org2-cell.org2-band.has-below::before {
  content: ""; position: absolute; top: 0; left: calc(50% - 1px); width: 2px; height: var(--bp);
  background: var(--oc); }
.org2-cell.org2-band.has-below:not(.has-people)::before { height: 100%; }
.org2-cell.org2-band.has-people.has-below::after { content: ""; position: absolute; bottom: 0;
  left: calc(50% - 1px); width: 2px; height: var(--bp); background: var(--oc); }
.org2-cards { position: relative; z-index: 1; display: flex; flex-wrap: wrap; justify-content: center;
  gap: 8px; max-width: var(--cards-w); }

.org-node { position: relative; z-index: 1; display: inline-block; width: 140px; padding: 7px 8px;
  text-align: center; background: var(--card); border: 1px solid var(--line2);
  border-top: 3px solid var(--line2); border-radius: var(--r); }
.org-name { font-weight: 800; color: var(--ink); font-size: 12.5px; line-height: 1.2; }
.org-role { font-size: 10.5px; color: var(--dim); line-height: 1.25; margin-top: 2px; }
.org-node-head { background: var(--side); border-color: var(--side); width: 160px; padding: 10px; }
.org-node-head .org-name { color: #fff; font-size: 14px; }
.org-node-head .org-role { color: var(--side-ink2); }
.org-node-exec { border-top-color: var(--side); }
/* Level colours: each row sets --lv (and --lv2 for a two-colour stripe);
   cards take it as a top stripe, split half and half when --lv2 is set. */
.lv-operating-partner { --lv: #8b0f18; }
.lv-director { --lv: #2563eb; }
.lv-coordinator { --lv: #e11d2a; --lv2: #2563eb; }
.lv-manager { --lv: #e11d2a; }
.lv-senior-trainer { --lv: #17915a; --lv2: #e11d2a; }
.lv-trainer { --lv: #17915a; }
.lv-team-lead { --lv: #ee7a12; }
.lv-other { --lv: var(--faint); }
.org2-cell.org2-band .org-node { border: 1px solid color-mix(in srgb, var(--lv) 35%, #fff);
  border-top: 7px solid transparent;
  background: linear-gradient(90deg, var(--lv) 50%, var(--lv2, var(--lv)) 50%)
    top / 100% 7px no-repeat border-box, var(--card); }

.org2-side { flex: 0 0 auto; display: flex; flex-direction: column; align-items: center; }
.org2-side-fork { display: flex; position: relative; padding-top: 18px; }
.org2-side-fork::before { content: ""; position: absolute; top: 0; left: calc(50% - 1px); width: 2px;
  height: 18px; background: var(--oc); }
.org2-side-kid { position: relative; padding: 18px 5px 0; }
.org2-side-kid::before { content: ""; position: absolute; top: 0; left: 0; right: 0; height: 2px;
  background: var(--oc); }
.org2-side-kid:first-child::before { left: 50%; }
.org2-side-kid:last-child::before { right: 50%; }
.org2-side-kid:only-child::before { display: none; }
.org2-side-kid::after { content: ""; position: absolute; top: 0; left: calc(50% - 1px); width: 2px;
  height: 18px; background: var(--oc); }
.orgchart-head { display: flex; align-items: center; gap: 1rem; justify-content: space-between; }

@media print {
  /* Real wrapper elements from base.html: the sidebar nav (.sidebar, inside
     .layout) and the team-strip banner sit above .content — hide both, plus
     the print trigger itself. */
  .sidebar, .team-strip, .orgchart-head .btn { display: none !important; }
  .layout { display: block; }
  .content { padding: 0; }
  body { background: #fff; }
  .orgchart { overflow: visible; }
  @page { size: landscape; margin: 1cm; }
}

/* ---------- public application form ---------- */
/* Every question on its own row, one at a time; open fields big and full-width. */
.apply-form { max-width: 620px; }
.apply-locked { margin: 0 0 22px; color: var(--ink); }
.apply-form label,
.apply-form fieldset { display: block; margin: 0 0 22px; }
.apply-form label { font-weight: 600; color: var(--ink); }
.apply-form input[type="text"],
.apply-form input[type="email"],
.apply-form select,
.apply-form textarea {
  display: block; width: 100%; margin-top: 8px; padding: 12px 14px;
  font: inherit; font-size: 16px; color: var(--ink);
  background: var(--card); border: 1px solid var(--line2);
  border-radius: var(--r); }
.apply-form input:focus,
.apply-form select:focus,
.apply-form textarea:focus {
  outline: none; border-color: var(--blue); }
.apply-form textarea { min-height: 150px; line-height: 1.5; resize: vertical; }
.apply-form fieldset {
  border: 1px solid var(--line2); border-radius: var(--r); padding: 16px 18px; }
.apply-form fieldset label { margin: 0 0 16px; font-weight: 500; }
.apply-form fieldset label:last-child { margin-bottom: 0; }
.apply-form legend {
  font-weight: 800; text-transform: uppercase; letter-spacing: .04em;
  font-size: 13px; padding: 0 6px; }
.apply-form .btn { margin-top: 6px; }

/* Curriculum editor: certification-criteria editor rows */
.cert-crit-editor { margin: 8px 0 4px; padding: 8px 10px; border: 1px solid #e4e5e0; border-radius: 4px; background: #fbfaf7; }
.cert-crit-editor .cc-title { display: block; font-size: 12px; text-transform: uppercase; letter-spacing: .04em; margin-bottom: 6px; }
.cert-crit-editor .cc-row { display: flex; flex-wrap: wrap; gap: 4px; align-items: center; margin-bottom: 4px; }
.cert-crit-editor .cc-add { margin-top: 6px; }

/* Sidebar collapsible group ("Owner tools"). The summary shares the .sidebar a
   rule above (identical font/color/hover); this only adds the toggle affordance
   and indents the nested links. */
.sidebar .nav-group { margin: 0; }
.sidebar .nav-group > summary { cursor: pointer; list-style: none; }
.sidebar .nav-group > summary::-webkit-details-marker { display: none; }
.sidebar .nav-group > summary::after { content: "\25B8"; margin-left: auto; opacity: .5; }
.sidebar .nav-group[open] > summary::after { content: "\25BE"; }
.sidebar .nav-group a { padding-left: 24px; }

/* ---------- time in role (_tenure.html): Directory, My Dashboard, Plan Week ---------- */
.tir { display: inline-flex; align-items: center; gap: 5px; margin-left: 6px; vertical-align: middle;
  font-size: 12px; font-weight: 700; color: var(--ink); white-space: nowrap; line-height: 1; }
/* Every time-in-role is a pill; Team Leads' carries the 4-month ring inside it. */
.tir { padding: 3px 8px; border-radius: 999px; background: #eef1f5; }
.tir.tir-ring { padding-left: 4px; }
td .tir { margin-left: 0; }
.tir-svg { flex: none; }
.tir-track { stroke: #dfe3ea; }
.tir-fill { stroke: var(--blue); }
.tir-done .tir-fill { stroke: var(--green); }

/* ---------- All Leaders panel (_leader_panel.html): one line per module ---------- */
.lp-flag { font-size: 11px; font-weight: 800; padding: 3px 8px; border-radius: 999px;
  background: #fff1e0; color: #a35f00; margin-left: auto; }
.lp-flag + .lp-prog { margin-left: 10px; }
.lp-prog { display: inline-flex; align-items: center; gap: 8px; font-size: 13px; color: var(--dim); }
.lp-bar { display: inline-block; width: 90px; height: 7px; border-radius: 4px; background: #e9ebe6; overflow: hidden; }
.lp-bar span { display: block; height: 100%; background: var(--green); }
.lp-body { margin-top: -6px; }
.lp-group { margin: 14px 0 6px; font-size: 12px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; }
.lp-group small, .lp-done > summary small { font-weight: 600; color: var(--dim); letter-spacing: 0; }
.lp-item { border: 1px solid var(--line2); border-radius: 4px; margin-bottom: 6px; background: var(--card); }
.lp-item > summary { display: grid; grid-template-columns: 22px minmax(0, 1fr) auto; align-items: center;
  gap: 10px; padding: 10px 12px; cursor: pointer; list-style: none; }
.lp-item > summary::-webkit-details-marker { display: none; }
.lp-item > summary:hover { background: #f7f8f5; }
.lp-item[open] > summary { border-bottom: 1px solid var(--line); }
.lp-dot { width: 18px; height: 18px; border-radius: 50%; display: inline-flex; align-items: center;
  justify-content: center; font-size: 11px; font-weight: 900; color: #fff; }
.lp-k-done .lp-dot { background: var(--green); }
.lp-k-wip .lp-dot { border: 2px solid #c27a00; }
.lp-k-todo .lp-dot { border: 2px solid #c3c8bf; }
.lp-k-fail .lp-dot { background: var(--red); }
.lp-mod { min-width: 0; }
.lp-mod b { display: block; font-size: 15px; }
.lp-obj { font-size: 12px; color: var(--dim); }
.lp-preview { display: block; margin-top: 2px; font-size: 13px; color: #4e5548;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.lp-item[open] .lp-preview { display: none; }
.lp-meta { font-size: 12px; color: var(--dim); text-align: right; white-space: nowrap; }
.lp-pill { display: inline-block; font-size: 11px; font-weight: 800; padding: 2px 8px; border-radius: 999px; }
.lp-pill-wip { background: #fff1e0; color: #a35f00; }
.lp-pill-review { background: #e8eefb; color: var(--blue); }
.lp-pill-fail { background: #fde8ea; color: var(--red-dk); }
.lp-pill-todo { background: #f0f1ee; color: var(--dim); }
.lp-pill-late { background: #fff1e0; color: #a35f00; }
.lp-open { padding: 10px 12px 12px 44px; }
.lp-open > p:first-child { margin-top: 0; }
.lp-note { margin: 0 0 8px; font-size: 14px; line-height: 1.55; white-space: pre-line; }
.lp-pdf { margin: 0 0 8px; font-size: 13px; }
.lp-edit > summary { display: inline-block; cursor: pointer; font-size: 13px; color: var(--blue);
  text-decoration: underline; padding: 4px 0; }
.lp-edit[open] > summary { margin-bottom: 8px; }
.lp-done { margin-top: 10px; }
.lp-done > summary { display: flex; align-items: center; gap: 8px; padding: 10px 2px; cursor: pointer;
  list-style: none; font-size: 12px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; color: var(--green); }
.lp-done > summary::-webkit-details-marker { display: none; }
.lp-caret { display: inline-block; font-size: 11px; transition: transform .15s; }
.lp-done[open] > summary .lp-caret { transform: rotate(90deg); }
@media (max-width: 600px) {
  .lp-item > summary { grid-template-columns: 22px minmax(0, 1fr); }
  .lp-meta { grid-column: 2; text-align: left; white-space: normal; }
  .lp-open { padding-left: 12px; }
  .lp-flag { margin-left: 0; }
  .cert-leader > summary { flex-wrap: wrap; row-gap: 4px; }
  .cert-leader > summary .lp-prog { margin-left: 0; flex-basis: 100%; padding-left: 22px; }
}

/* Promotion recommendations on All Leaders cards (_certify_list.html). */
.promo-pill { font-size: 11px; font-weight: 800; padding: 3px 8px; border-radius: 999px;
  background: #fff6d6; color: #8a6400; margin-left: auto; white-space: nowrap; }
.promo-pill ~ .lp-flag, .promo-pill ~ .cert-leader-stat { margin-left: 10px; }
.promo-bar { display: flex; align-items: center; justify-content: space-between; gap: 12px;
  flex-wrap: wrap; margin: 12px 0 0; padding-top: 10px; border-top: 1px solid var(--line); font-size: 13px; }
.promo-bar form { display: inline-flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.promo-pick { display: inline-flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.promo-pick[hidden], .promo-btn[hidden] { display: none; }
.promo-btn.is-go { background: var(--amber); border-color: var(--amber); color: #3d2c00; }
.promo-btn.is-go .promo-star { color: #fff; }
.promo-for { font-size: 11px; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; color: var(--dim); }
.promo-for-select { font: inherit; font-size: 13px; padding: 6px 8px; border: 1px solid var(--line2); border-radius: 4px; background: #fff; }
.promo-btn { display: inline-flex; align-items: center; gap: 6px; padding: 7px 14px; border-radius: 999px;
  border: 1.5px solid #e8c95a; background: #fff9e6; color: #7a5800; font-size: 12.5px; font-weight: 800;
  cursor: pointer; white-space: nowrap; transition: background .15s, border-color .15s, box-shadow .15s; }
.promo-btn:hover { background: #fff1c2; border-color: var(--amber); box-shadow: 0 1px 4px rgba(240, 168, 40, .3); }
.promo-btn:active { transform: translateY(1px); }
.promo-btn .promo-star { font-size: 15px; line-height: 1; color: var(--amber); }
.promo-vote { flex: 1 1 260px; min-width: 0; }
.promo-vote-head { margin: 0 0 6px; }
.promo-voters { display: flex; flex-wrap: wrap; gap: 6px 12px; margin: 0; }
.promo-voter { display: inline-flex; align-items: center; gap: 5px; font-size: 12.5px; font-weight: 700; }
.promo-voter.is-waiting { color: var(--faint); font-weight: 600; }
.promo-mine { display: inline-flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.promo-mine-label { font-size: 11px; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; color: var(--dim); margin-right: 2px; }
.promo-color { padding: 6px 12px; border-radius: 999px; font-size: 12px; font-weight: 800; cursor: pointer;
  background: #fff; border: 1.5px solid currentColor; transition: background .15s, color .15s; }
.promo-green { color: var(--green); } .promo-yellow { color: #b07a00; } .promo-red { color: var(--red); }
.promo-color:hover, .promo-color.is-on { color: #fff; }
.promo-green:hover, .promo-green.is-on { background: var(--green); border-color: var(--green); }
.promo-yellow:hover, .promo-yellow.is-on { background: var(--amber); border-color: var(--amber); }
.promo-red:hover, .promo-red.is-on { background: var(--red); border-color: var(--red); }
.promo-clear { background: none; border: 0; color: var(--dim); font-size: 12px; text-decoration: underline; cursor: pointer; padding: 4px; }
@media (max-width: 600px) { .promo-pill { margin-left: 0; } }

/* My Queue: links down to the module in All Leaders (_certify_list.html). */
.queue-links { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.queue-link { display: grid; grid-template-columns: minmax(0, 1fr) auto auto; align-items: center; gap: 4px 12px;
  padding: 10px 12px; background: var(--card); border: 1px solid #cfe5d8; border-radius: 4px;
  color: var(--ink); text-decoration: none; }
.queue-link:hover { border-color: var(--green); }
.queue-link .queue-leader { grid-column: 1; margin: 0; }
.queue-link .queue-module { grid-column: 1; font-size: 14px; }
.queue-link .lp-pill { grid-column: 2; grid-row: 1 / span 2; }
.queue-link .queue-go { grid-column: 3; grid-row: 1 / span 2; font-size: 13px; font-weight: 800; color: var(--green); }
.queue-link.is-done { opacity: .75; }
.lp-pill-done { background: #e3f3ea; color: #0f6b3f; }
.lp-item { scroll-margin-top: 80px; }
.lp-flash { animation: lp-flash 1.6s ease-out; }
@keyframes lp-flash { 0%, 35% { box-shadow: 0 0 0 3px var(--green); } 100% { box-shadow: 0 0 0 3px transparent; } }
@media (max-width: 600px) {
  .queue-link { grid-template-columns: minmax(0, 1fr) auto; }
  .queue-link .lp-pill { grid-column: 1; grid-row: auto; justify-self: start; }
  .queue-link .queue-go { grid-column: 2; grid-row: 1 / span 3; }
}

/* My Dashboard tiles: this week (live, whole store) + last week's completion. */
.votes-needed { background: var(--card); border: 2px solid var(--red); border-left-width: 8px;
  border-radius: 6px; padding: 14px 16px; margin: 0 0 18px; }
.votes-needed-head { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin: 0 0 10px; font-size: 13px; }
.votes-needed-head strong { color: var(--red); font-size: 16px; text-transform: uppercase; letter-spacing: .05em; }
.votes-needed-head .vn-count { background: var(--red); color: #fff; font-weight: 800; font-size: 13px; border-radius: 999px; padding: 2px 10px; }
.votes-needed ul { list-style: none; margin: 0; padding: 0; display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 10px; }
.votes-needed li { display: flex; align-items: center; justify-content: space-between; gap: 10px;
  background: #fff6f6; border: 1px solid #f6caca; border-radius: 4px; padding: 10px 12px; }
.vn-who { min-width: 0; }
.vn-who b { font-size: 15px; }
.vn-who small { display: block; font-size: 12px; color: var(--dim); }
.vn-kind { display: inline-block; font-size: 10.5px; font-weight: 800; letter-spacing: .05em; text-transform: uppercase;
  padding: 2px 6px; border-radius: 3px; margin-right: 5px; }
.vn-who small .vn-target { font-size: 12px; color: var(--ink); }
.vn-promo { background: #fff6d6; color: #8a6400; }
.vn-cand { background: #e8eef7; color: var(--blue); }
.votes-needed .btn, .votes-needed .btn-ghost { text-decoration: none; white-space: nowrap; }
.tiles-head { margin: 0 0 -8px; font-size: 13px; }
.tiles-head strong { text-transform: uppercase; letter-spacing: .06em; font-size: 12px; margin-right: 4px; }
.scoreboard-4 { grid-template-columns: repeat(3, 1fr) minmax(0, 1.1fr); }
.score-last { border-top-color: var(--faint); border-style: dashed; border-top-style: solid; background: var(--panel); }
.score-sub { font-size: 12px; color: var(--dim); font-weight: 700; margin-top: 2px; }
@media (max-width: 760px) { .scoreboard-4 { grid-template-columns: 1fr 1fr; } }

/* Leader rows (My Dashboard, Plan Week): name, role, time in role and voice
   sit in fixed-width columns so they line up from row to row. */
.cert-leader > summary { align-items: center; }
.cert-leader-name { flex: none; width: 150px; overflow-wrap: anywhere; }
.cert-leader-role { flex: none; width: 190px; }
.cert-leader-tir { flex: none; width: 104px; display: inline-flex; }
.cert-leader-tir .tir { margin-left: 0; }
.cert-leader-voice { flex: none; width: 160px; }
@media (max-width: 760px) {
  .cert-leader-name, .cert-leader-role, .cert-leader-tir, .cert-leader-voice { width: auto; }
}

/* Last Week pop-up on the dashboard tile (dashboard.html). */
.score-last { position: relative; }
.score-last.has-pop { cursor: pointer; }
.lw-hint { color: var(--blue); text-transform: none; letter-spacing: 0; }
.lw-pop { display: none; position: absolute; z-index: 30; top: calc(100% + 6px); right: -2px;
  width: min(420px, 92vw); max-height: 420px; overflow-y: auto; cursor: default;
  background: var(--card); border: 1px solid var(--line2); border-radius: 6px;
  box-shadow: 0 10px 30px rgba(20, 24, 29, .18); padding: 12px 14px; text-align: left; }
.score-last.has-pop:hover .lw-pop, .score-last.has-pop:focus-within .lw-pop, .score-last.open .lw-pop { display: block; }
.score-last.has-pop:focus-visible { outline: 2px solid var(--blue); outline-offset: 2px; }
.lw-pop-head { margin: 0 0 8px; font-size: 13px; color: var(--dim); line-height: 1.4; }
.lw-pop-head strong { color: var(--ink); }
.lw-pop ul { list-style: none; margin: 0; padding: 0; }
.lw-pop li { display: grid; grid-template-columns: 18px minmax(0, 1fr) auto; gap: 8px; align-items: start;
  padding: 8px 0; border-top: 1px solid var(--line); font-size: 13px; }
.lw-dot { width: 14px; height: 14px; margin-top: 2px; border-radius: 50%; display: inline-flex;
  align-items: center; justify-content: center; font-size: 9px; font-weight: 900; color: #fff; }
.lw-open .lw-dot { background: var(--red); }
.lw-later .lw-dot { background: #fff; border: 2px solid #c27a00; }
.lw-done .lw-dot { background: var(--green); }
.lw-retired .lw-dot { background: #c3c8bf; }
.lw-what small, .lw-state small { display: block; font-size: 11.5px; color: var(--dim); font-weight: 600; }
.lw-state { text-align: right; font-weight: 800; white-space: nowrap; }
.lw-open .lw-state { color: var(--red-dk); }
.lw-later .lw-state { color: #a35f00; }
.lw-done .lw-state { color: #0f6b3f; }
.lw-retired .lw-state { color: var(--dim); }
.lp-ci { font-weight: 700; color: var(--blue); }
/* FOH / BOH split under Planned This Week and Certified So Far. */
.score-sides { display: flex; flex-wrap: wrap; gap: 4px 6px; margin-top: 4px; }
.score-sides span { font-size: 11.5px; font-weight: 700; color: var(--dim); padding: 2px 7px;
  border-radius: 999px; background: #f0f1ee; white-space: nowrap; }
.score-sides b { color: var(--ink); }
.score-sides .side-foh { background: #e8eefb; }
.score-sides .side-boh { background: #fdf0e1; }

/* ---------- My Trainees (Manager access) ---------- */
.mt-week { font-size: 15px; font-weight: 600; margin: -8px 0 16px; }
.mt-card { margin-bottom: 14px; }
.mt-head { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; padding-bottom: 10px; border-bottom: 2px solid var(--line); margin-bottom: 4px; }
.mt-item { padding: 12px 0; border-top: 1px solid var(--line); }
.mt-item:first-of-type { border-top: 0; }
.mt-item-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 10px; margin-bottom: 6px; }
.mt-item-head .lp-obj { display: block; }
.mt-item.is-done { opacity: .8; }
.mt-plan-note { background: var(--panel); border-left: 3px solid var(--blue); padding: 6px 10px; font-size: 13px; margin: 6px 0; }

/* ---------- Directory, freshened (directory.html) — scoped to .dir-fresh ---------- */
.dir-top { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.dir-top h2 { margin: 0; }
.dir-count { color: var(--dim); font-size: 14px; font-weight: 600; }
.dir-org { margin-left: auto; font-size: 13px; font-weight: 700; color: var(--blue); text-decoration: none; }
.dir-org:hover { text-decoration: underline; }
.dir-search { margin-top: 10px; border: 1px solid var(--line2); background: var(--card); border-radius: 999px;
  padding: 8px 14px; font: inherit; font-size: 13px; width: 240px; max-width: 100%; }
.dir-search:focus { outline: none; border-color: var(--blue); box-shadow: 0 0 0 3px rgba(47,74,114,.15); }
.dir-add { background: var(--card); border: 1px solid var(--line2); border-radius: 10px; margin: 14px 0 8px; overflow: hidden; }
.dir-add > summary { list-style: none; cursor: pointer; padding: 12px 16px; display: flex; align-items: center; gap: 10px;
  font-size: 13px; font-weight: 800; text-transform: uppercase; letter-spacing: .06em; }
.dir-add > summary::-webkit-details-marker { display: none; }
.dir-add > summary small { font-weight: 600; letter-spacing: 0; text-transform: none; color: var(--faint); }
.dir-plus { width: 22px; height: 22px; border-radius: 50%; background: var(--red); color: #fff; display: grid; place-items: center;
  font-size: 15px; line-height: 1; transition: transform .15s; }
.dir-add[open] .dir-plus { transform: rotate(45deg); }
.dir-fresh .dir-add .add-panel { border: 0; border-top: 1px solid var(--line); margin: 0; padding: 14px 16px 16px; border-radius: 0; }
.dir-fresh .add-panel input, .dir-fresh .add-panel select { border-radius: 8px; }
.dir-fresh .add-panel input:focus, .dir-fresh .add-panel select:focus { border-color: var(--blue); box-shadow: 0 0 0 3px rgba(47,74,114,.15); }
.dir-fresh .add-panel .btn { border-radius: 8px; }
.dir-fresh .roster-head { display: flex; align-items: center; justify-content: flex-start; gap: 10px; margin: 26px 0 10px;
  padding-bottom: 8px; border-bottom-width: 2px; text-transform: uppercase; letter-spacing: .02em; font-size: 14px; }
.dir-fresh .roster-head small { background: var(--panel); color: var(--dim); border-radius: 999px; padding: 2px 9px; letter-spacing: 0; }
.dir-fresh .position-sub { display: inline-flex; gap: 6px; align-items: center; background: var(--panel); border-radius: 999px;
  padding: 3px 10px; margin: 10px 0 8px; font-size: 11px; }
.dir-tbl { background: var(--card); border: 1px solid var(--line2); border-radius: 10px; overflow: hidden;
  box-shadow: 0 1px 2px rgba(20,24,29,.03); margin-bottom: 8px; }
.dir-fresh .dir-tbl th { background: #fafaf7; border-bottom: 1px solid var(--line2); padding: 9px 12px; }
.dir-fresh .dir-tbl td { border-bottom: 0; border-top: 1px solid var(--line); padding: 10px 12px; vertical-align: middle; }
.dir-fresh .dir-tbl tbody tr:first-child td { border-top: 0; }
.dir-fresh .dir-tbl tbody tr { transition: background .12s; }
.dir-fresh .dir-tbl tbody tr:hover { background: #f7f8f4; }
.dir-who { display: flex; align-items: center; gap: 10px; min-width: 0; }
.dir-av { flex: none; width: 30px; height: 30px; border-radius: 50%; background: #e7efe9; color: #2d5a3d;
  font-weight: 800; font-size: 11.5px; display: grid; place-items: center; }
.dir-av.is-lead { background: #e8eef7; color: var(--blue); }
.dir-who-t { min-width: 0; display: grid; }
.dir-flags { display: flex; gap: 4px; margin-top: 2px; flex-wrap: wrap; }
.dir-flags .standing-badge { margin-left: 0; border-radius: 999px; padding: 1px 7px; }
.dir-role { color: var(--dim); font-size: 13px; }
.dir-comp { display: inline-flex; align-items: center; gap: 8px; font-size: 13px; }
.dir-comp b { min-width: 32px; font-weight: 700; }
.dir-bar { width: 70px; height: 6px; border-radius: 3px; background: #e9ebe6; overflow: hidden; }
.dir-bar span { display: block; height: 100%; background: var(--green); border-radius: 3px; }
.dir-vchips { display: inline-flex; gap: 4px; flex-wrap: wrap; }
.dir-vchip { font-size: 11.5px; font-weight: 700; padding: 2px 8px; border-radius: 999px; background: var(--panel); }
.dir-vchip.is-first { background: #eef1f5; color: var(--blue); }
.dir-fresh .acc { border-radius: 999px; padding: 3px 9px; font-size: 10px; }
.dir-fresh .roster-divider { height: 1px; background: var(--line2); margin: 36px 0 0; }
.dir-fresh .roster-divider-red { height: 2px; background: #f3c4c7; }
.dir-fresh .roster-archived > summary.roster-head { color: #b3141f; border-bottom: 0; }
.dir-fresh [hidden] { display: none !important; }
.dir-none { margin-top: 14px; }
@media (max-width: 640px) {
  .dir-org { margin-left: 0; }
  .dir-search { width: 100%; }
  .dir-tbl { background: none; border: 0; box-shadow: none; overflow: visible; }
  .dir-fresh .dir-tbl tbody tr { border-radius: 10px; }
}
@media (prefers-reduced-motion: reduce) { .dir-plus, .dir-fresh .dir-tbl tbody tr { transition: none; } }

/* ---------- Person page (person_detail.html) ---------- */
.pd-back { margin: 0 0 10px; font-size: 13px; }
.pd-back a { color: var(--dim); text-decoration: none; font-weight: 700; }
.pd-back a:hover { color: var(--ink); }
.pd-head { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 16px; align-items: center;
  background: var(--card); border: 1px solid var(--line2); border-top: 4px solid var(--red); border-radius: 10px;
  padding: 16px 18px; margin-bottom: 16px; }
.pd-av { width: 56px; height: 56px; border-radius: 50%; background: #e7efe9; color: #2d5a3d; font-weight: 800;
  font-size: 19px; display: grid; place-items: center; }
.pd-av.is-lead { background: #e8eef7; color: var(--blue); }
.pd-id h2 { margin: 0; display: flex; align-items: center; gap: 4px; flex-wrap: wrap; }
.pd-sub { margin: 4px 0 0; color: var(--dim); font-size: 14px; display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.pd-sub .acc { border-radius: 999px; padding: 3px 9px; font-size: 10px; }
.pd-email { font-size: 12.5px; color: var(--faint); margin-left: 4px; }
.pd-stats { display: grid; grid-template-columns: repeat(3, auto); gap: 10px; }
.pd-stat { background: var(--panel); border-radius: 8px; padding: 9px 12px; display: grid; gap: 3px; min-width: 120px; align-content: start; }
.pd-stat .k { font-size: 10.5px; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; color: var(--dim); }
.pd-stat .v { font-size: 24px; font-weight: 800; line-height: 1.1; font-variant-numeric: tabular-nums; }
.pd-stat .v small { font-size: 13px; color: var(--faint); }
.pd-stat .v-sm { font-size: 13px; display: flex; align-items: center; gap: 4px; flex-wrap: wrap; min-height: 24px; }
.pd-stat .tir { margin-left: 0; }
.pd-bar { display: block; height: 6px; border-radius: 3px; background: #e2e4dd; overflow: hidden; }
.pd-bar > span { display: block; height: 100%; background: var(--green); border-radius: 3px; }
.pd-grid { display: grid; grid-template-columns: minmax(0, 1fr) 360px; grid-template-areas: "main side"; gap: 16px; align-items: start; }
.pd-side { grid-area: side; display: grid; gap: 14px; }
.pd-main { grid-area: main; display: grid; gap: 14px; align-content: start; }
.pd-card { background: var(--card); border: 1px solid var(--line2); border-radius: 10px; padding: 14px 16px; margin: 0; }
.pd-card.is-warn { border-left: 5px solid var(--red); }
.pd-card h3 { margin: 0 0 10px; font-size: 14px; text-transform: uppercase; letter-spacing: .02em;
  display: flex; align-items: baseline; gap: 8px; flex-wrap: wrap; }
.pd-card h3 small { font-size: 12px; font-weight: 600; text-transform: none; letter-spacing: 0; color: var(--faint); }
.pd-h { margin: 6px 0 -4px; font-size: 13px; text-transform: uppercase; letter-spacing: .06em; color: var(--dim); }
.pd-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; }
.pd-standing.ok { color: var(--green); } .pd-standing.bad { color: var(--red); }
.pd-input { width: 100%; font: inherit; font-size: 14px; line-height: 1.5; border: 1px solid var(--line2); border-radius: 8px;
  padding: 9px 11px; resize: vertical; background: #fff; }
.pd-input:focus, .pd-form input:focus, .pd-form select:focus { outline: none; border-color: var(--blue); box-shadow: 0 0 0 3px rgba(47,74,114,.15); }
.pd-actions { display: flex; justify-content: flex-end; margin-top: 8px; }
.pd-actions .btn, .pd-card .btn-ghost, .pd-danger .btn-danger { border-radius: 8px; }
.pd-shouts { list-style: none; margin: 12px 0 0; padding: 0; }
.pd-shouts li { border-top: 1px solid var(--line); padding: 9px 0; }
.pd-shouts li.is-retired { opacity: .55; }
.pd-shouts p { margin: 0 0 3px; font-size: 14px; }
.pd-shout-meta { display: flex; align-items: center; gap: 5px; flex-wrap: wrap; font-size: 12px; color: var(--dim); }
.pd-shout-meta form { margin: 0 0 0 auto; }
.pd-manage > summary { list-style: none; cursor: pointer; display: flex; align-items: baseline; gap: 8px; flex-wrap: wrap; }
.pd-manage > summary::-webkit-details-marker { display: none; }
.pd-manage > summary h3 { margin: 0; }
.pd-manage > summary::after { content: "▾"; margin-left: auto; color: var(--faint); }
.pd-manage[open] > summary::after { content: "▴"; }
.pd-manage > summary small { color: var(--faint); font-size: 12px; }
.pd-manage { margin-top: 16px; }
.pd-form { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px 16px; margin-top: 14px; }
.content .pd-form .pd-f { display: grid; gap: 4px; margin: 0; min-width: 0; align-content: start; }
.pd-f > span { font-size: 11px; font-weight: 800; letter-spacing: .04em; text-transform: uppercase; color: var(--dim); }
.pd-f > span em, .pd-f > em { font-style: normal; font-weight: 600; text-transform: none; letter-spacing: 0; color: var(--faint); font-size: 11.5px; }
.pd-f input, .pd-f select { width: 100%; min-width: 0; max-width: 100%; height: 38px; font: inherit; font-size: 13.5px; border: 1px solid var(--line2); border-radius: 8px; padding: 0 10px; background: #fff; }
.pd-f-wide { grid-column: 1 / -1; }
.pd-checks { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 6px 12px; font-size: 13px;
  background: var(--panel); border-radius: 8px; padding: 10px 12px; }
.content .pd-checks .role-check { display: flex; gap: 8px; align-items: center; margin: 0; font-weight: 500; }
.pd-checks .role-check input { width: auto; height: auto; }
.pd-danger { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 14px; padding-top: 12px; border-top: 1px solid var(--line); }
.pd-danger form { margin: 0; }
.pd-roles { list-style: none; margin: 0; padding: 0; }
.pd-roles li { display: grid; grid-template-columns: minmax(0, 1fr) 150px auto; gap: 12px; align-items: center; padding: 8px 0; border-top: 1px solid var(--line); }
.pd-roles li:first-child { border-top: 0; }
.pd-roles li.is-current .pd-role-name { font-weight: 800; }
.pd-star { color: var(--amber); margin-right: 5px; }
.pd-role-prog { display: grid; grid-template-columns: 1fr auto; gap: 8px; align-items: center; font-size: 13px; }
.pd-role-prog b { min-width: 34px; text-align: right; font-variant-numeric: tabular-nums; }
.pd-role-meta { display: flex; gap: 8px; align-items: center; font-size: 12px; justify-content: flex-end; flex-wrap: wrap; }
.pd-mods { list-style: none; margin: 0; padding: 0; }
.pd-mod { display: grid; grid-template-columns: 22px minmax(0, 1fr) auto; gap: 10px; align-items: center; padding: 9px 0; border-top: 1px solid var(--line); }
.pd-mod:first-child { border-top: 0; }
.pd-dot { width: 20px; height: 20px; border-radius: 50%; border: 2px solid var(--faint); display: grid; place-items: center;
  font-size: 11px; font-weight: 800; color: #fff; }
.pd-mod.is-done .pd-dot { background: var(--green); border-color: var(--green); }
.pd-mod.is-wip .pd-dot { border-color: var(--amber); background: #fff4dd; }
.pd-mod-t { display: grid; gap: 2px; min-width: 0; }
.pd-mod-name { font-size: 14px; font-weight: 600; }
.pd-mod-name a { text-decoration: none; }
.pd-mod-note { font-size: 12.5px; color: var(--dim); font-style: italic; }
.pd-mod-detail { font-size: 12px; color: var(--dim); text-align: right; }
@media (max-width: 1000px) {
  .pd-head { grid-template-columns: auto minmax(0, 1fr); }
  .pd-stats { grid-column: 1 / -1; grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .pd-grid { grid-template-columns: 1fr; grid-template-areas: "side" "main"; }
  .pd-form { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 560px) {
  .pd-stats { grid-template-columns: 1fr 1fr; }
  .pd-form { grid-template-columns: 1fr; }
  .pd-roles li { grid-template-columns: 1fr; gap: 4px; }
  .pd-role-meta { justify-content: flex-start; }
  .pd-mod { grid-template-columns: 22px minmax(0, 1fr); }
  .pd-mod-detail { grid-column: 2; text-align: left; }
}

/* ---------- Candidates, freshened (candidates.html) — pipeline steps ---------- */
.cand-start { font-size: 12px; color: var(--faint); }
.cand-fresh .cand-pipe { padding-top: 8px; padding-bottom: 8px; }
.steps { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); position: relative; }
.st { display: grid; justify-items: center; gap: 2px; position: relative; text-align: center; }
.st::before { content: ""; position: absolute; top: 10px; left: -50%; width: 100%; height: 2px; background: var(--line2); z-index: 0; }
.st:first-child::before { display: none; }
.st.is-done::before, .st.is-sched::before { background: #9fd3b7; }
.st-dot { position: relative; z-index: 1; width: 22px; height: 22px; border-radius: 50%; display: grid; place-items: center;
  font-size: 11px; font-weight: 800; background: #fff; border: 2px solid var(--line2); color: var(--faint); }
.st.is-done .st-dot { background: var(--green); border-color: var(--green); color: #fff; }
.st.is-open .st-dot { border-color: var(--amber); }
.st.is-sched .st-dot { background: #e8eef7; border-color: var(--blue); font-size: 11px; }
.st.is-locked .st-dot { background: var(--panel); font-size: 9px; }
.st-lbl { font-size: 10.5px; font-weight: 800; letter-spacing: .02em; color: var(--dim); }
.st.is-done .st-lbl { color: var(--green); }
.st.is-sched .st-lbl { color: var(--blue); }
.st-dt { font-size: 10.5px; color: var(--faint); min-height: 13px; font-variant-numeric: tabular-nums; }
.st-next { display: block; margin-top: 4px; font-size: 11.5px; font-weight: 700; color: var(--ink); }
.cand-fresh .cand-notes { font-size: 13px; color: var(--dim); }
@media (max-width: 640px) {
  .cand-fresh .cand-pipe { display: block; }
  .steps { margin-top: 4px; }
}

/* Candidates: more separation so rows and columns don't blend together. */
.cand-fresh .dir-tbl { border-color: #d9dbd3; }
.cand-fresh .dir-tbl th { background: #f1f2ec; color: var(--dim); border-bottom: 2px solid #dfe1d9; }
.cand-fresh .dir-tbl td { padding-top: 12px; padding-bottom: 12px; border-top: 1px solid #e6e7e1; }
.cand-fresh .dir-tbl tbody tr:nth-child(even) { background: #fafaf6; }
.cand-fresh .dir-tbl tbody tr:hover { background: #f2f5ef; }
.cand-fresh .dir-tbl td + td { border-left: 1px solid #f0f1eb; }
.cand-fresh .card-title a { font-size: 15px; }
.cand-fresh .cand-pipe .steps { background: #fff; border: 1px solid #ecede7; border-radius: 8px; padding: 6px 4px 2px; }
.cand-fresh .st-next { display: inline-block; margin-top: 6px; padding: 2px 9px; border-radius: 999px;
  background: #fff4dd; color: #8a5a00; font-size: 11.5px; }
.cand-fresh .st-next:is(:empty) { display: none; }
.cand-fresh .cand-notes { background: none; }
.cand-fresh .cand-notes .note-text, .cand-fresh .cand-notes > :not(.note) { color: var(--ink); }
.cand-fresh td.cand-notes { font-size: 13px; line-height: 1.45; }
.cand-fresh .dir-sec:nth-of-type(odd) .roster-head { border-bottom-color: var(--red); }
.cand-fresh .roster-head { font-size: 15px; }
.cand-fresh .st-next.is-ready { background: #e6f4ec; color: var(--green); }

/* Candidates: narrower rows. */
.cand-fresh .dir-tbl td { padding-top: 6px; padding-bottom: 6px; }
.cand-fresh .cand-pipe { padding-top: 5px; padding-bottom: 5px; }
.cand-fresh .cand-pipe .steps { padding: 3px 2px 1px; }
.cand-fresh .st { gap: 0; }
.cand-fresh .st-dot { width: 18px; height: 18px; font-size: 10px; border-width: 2px; }
.cand-fresh .st::before { top: 8px; }
.cand-fresh .st-lbl { font-size: 10px; line-height: 1.2; }
.cand-fresh .st-dt { font-size: 10px; line-height: 1.1; min-height: 11px; }
.cand-fresh .st-next { margin-top: 3px; padding: 1px 8px; font-size: 11px; }
.cand-fresh .dir-av { width: 26px; height: 26px; font-size: 10.5px; }
.cand-fresh .cand-start { font-size: 11.5px; line-height: 1.2; }
.cand-fresh td.cand-notes { line-height: 1.35; }
.cand-app-pill { display: inline-block; font-size: 11.5px; font-weight: 800; padding: 3px 9px; border-radius: 999px;
  background: #e6f4ec; color: var(--green); border: 1px solid #b9dcc8; white-space: nowrap; }
.cand-archived-link { margin: 22px 0 0; padding-top: 12px; border-top: 1px solid var(--line2); font-size: 13px; font-weight: 700; }
.cand-archived-link a { color: var(--dim); text-decoration: none; }
.cand-archived-link a:hover { color: var(--ink); text-decoration: underline; }

/* ---------- Candidate page (candidate_detail.html) — builds on .pd ---------- */
.cd .pd-stats { grid-template-columns: auto auto auto; }
.cd-stat-pipe { min-width: 230px; }
.cd-stat-pipe .steps { margin-top: 4px; }
.cd-stat-pipe .st-dot { width: 18px; height: 18px; font-size: 10px; }
.cd-stat-pipe .st::before { top: 8px; }
.cd-stat-pipe .st-lbl { font-size: 10px; }
.cd .vote-dots { gap: 4px; }
.cd-line { margin: 0; font-size: 14px; }
.cd-lock { margin: 0 0 6px; font-size: 12.5px; color: var(--faint); }
.cd-input { font: inherit; font-size: 13.5px; height: 36px; border: 1px solid var(--line2); border-radius: 8px; padding: 0 10px; background: #fff; min-width: 0; }
.cd-input:focus { outline: none; border-color: var(--blue); box-shadow: 0 0 0 3px rgba(47,74,114,.15); }
.cd-input:disabled { background: var(--panel); color: var(--faint); }
.cd-inline { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.cd-inline .cd-input[type=email] { flex: 1 1 180px; }
.cd-steps { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.content form.cd-step { display: grid; gap: 8px; align-content: start; margin: 0; padding: 12px; border: 1px solid var(--line2);
  border-radius: 8px; background: #fafaf7; border-top: 3px solid var(--line2); }
.cd-step.is-done { border-top-color: var(--green); background: #f5faf7; }
.cd-step.is-open { border-top-color: var(--amber); background: #fff; }
.cd-step.is-sched { border-top-color: var(--blue); background: #f5f8fc; }
.cd-step.is-locked { opacity: .7; }
.cd-step-h { display: flex; align-items: center; gap: 8px; font-size: 14px; }
.cd-step .st-dot { width: 20px; height: 20px; font-size: 10px; flex: none; }
.cd-step.is-done .st-dot { background: var(--green); border-color: var(--green); color: #fff; }
.cd-step.is-open .st-dot { border-color: var(--amber); }
.cd-step.is-sched .st-dot { background: #e8eef7; border-color: var(--blue); }
.cd-step.is-locked .st-dot { background: var(--panel); font-size: 9px; }
.content .cd-check { display: flex; align-items: center; gap: 8px; font-size: 13.5px; font-weight: 600; margin: 0; }
.cd-check input { width: auto; height: auto; }
.cd-step .btn-ghost { justify-self: start; border-radius: 8px; padding: 6px 12px; }
.cd .app-notes-view { margin: 0; border: 0; padding: 0; background: none; }
.cd-votes { list-style: none; margin: 0 0 10px; padding: 0; display: flex; flex-wrap: wrap; gap: 6px 14px; font-size: 13.5px; }
.cd-votes li { display: inline-flex; align-items: center; gap: 6px; }
.cd-vote-lbl { font-size: 11px; font-weight: 800; letter-spacing: .05em; text-transform: uppercase; color: var(--dim); }
.cd .ci-add, .cd .ci-list { max-width: none; }
.cd .ci-add { border-radius: 8px; }
.cd .ci-add textarea, .cd .ci-edit textarea { border: 1px solid var(--line2); border-radius: 8px; padding: 8px 10px; }
.cd .ci-add input[type=date], .cd .ci-edit input[type=date] { border: 1px solid var(--line2); border-radius: 8px; height: 36px; padding: 0 10px; }
.cd .ci-add .btn, .cd .ci-edit .btn, .cd-inline .btn { border-radius: 8px; }
.cd-form { grid-template-columns: repeat(2, minmax(0, 1fr)); }
@media (max-width: 1000px) { .cd .pd-stats { grid-template-columns: 1fr 1fr 1fr; } .cd-stat-pipe { min-width: 0; } }
@media (max-width: 560px) {
  .cd .pd-stats { grid-template-columns: 1fr 1fr; }
  .cd-stat-pipe { grid-column: 1 / -1; }
  .cd-steps { grid-template-columns: 1fr; }
}

/* ---------- Applications, freshened (applications.html) ---------- */
.apps-fresh .apps-share > summary .dir-plus { background: var(--blue); font-size: 12px; }
.apps-fresh .apps-share[open] .dir-plus { transform: none; }
.apps-fresh .apply-links { border: 0; border-top: 1px solid var(--line); margin: 0; padding: 14px 16px 16px; background: none; }
.apps-fresh .apply-link-url, .apps-fresh .apply-link-actions .btn-secondary, .apps-fresh .apply-link-actions .btn-ghost { border-radius: 8px; }
.apps-fresh .apply-qr-img { border-radius: 8px; }
.apps-empty { margin-top: 18px; }
.apps-fresh .app-list { margin-top: 16px; gap: 18px; }
.apps-fresh .app-card { border-radius: 10px; border: 1px solid var(--line2); border-top: 4px solid var(--red); padding: 16px 18px;
  box-shadow: 0 1px 2px rgba(20,24,29,.04); }
.apps-fresh .app-head { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: 12px;
  padding-bottom: 12px; border-bottom: 1px solid var(--line); }
.apps-fresh .app-head .dir-av { width: 40px; height: 40px; font-size: 14px; }
.apps-fresh .app-name { margin: 0 0 4px; font-size: 18px; }
.apps-fresh .app-chip { border-radius: 999px; padding: 3px 9px; }
.apps-fresh .app-date { font-size: 12px; color: var(--faint); font-weight: 600; white-space: nowrap; }
.apps-fresh .app-prereqs { border-radius: 8px; border: 1px solid var(--line2); background: #fafaf7; padding: 12px 14px; }
.apps-fresh .app-prereqs .app-label { margin-bottom: 6px; }
.apps-fresh .prereq-list { gap: 6px; }
.apps-fresh .prereq { display: inline-flex; align-items: center; gap: 2px; font-size: 13px; padding: 4px 10px; border-radius: 999px;
  background: #fff; border: 1px solid var(--line2); }
.apps-fresh .prereq-done { background: #eef7f2; border-color: #b9dcc8; color: #145c3b; }
.apps-fresh .prereq-todo { background: #fdf0f1; border-color: #f3c4c7; color: #8c1019; }
.apps-fresh .prereq-wait { background: #fff7e6; border-color: #f5d79a; color: #7a5200; }
.apps-fresh .prereq-date { font-size: 11.5px; }
.apps-fresh .prereq-flag { display: inline-block; margin: 8px 8px 0 0; padding: 2px 9px; border-radius: 999px; background: #fdf0f1; }
.apps-fresh .prereq-open { margin-left: 2px; }
.apps-fresh .app-facts { padding-top: 14px; }
.app-answers { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 22px; }
.app-answers > .app-answer { padding-top: 14px; }
.app-answers > .app-answer:has(.app-values) { grid-column: 1 / -1; }
.apps-fresh .app-answer .app-label { color: var(--dim); }
.apps-fresh .app-answer p { font-size: 14px; }
.apps-fresh .app-value { border-radius: 8px; }
.apps-fresh .app-actions { margin-top: 16px; padding-top: 12px; border-top: 1px solid var(--line); }
.apps-fresh .app-link-form select { border-radius: 8px; height: 38px; border: 1px solid var(--line2); padding: 0 10px; font: inherit; font-size: 13.5px; }
.apps-fresh .app-actions .btn, .apps-fresh .app-actions .btn-secondary, .apps-fresh .app-actions .btn-ghost, .apps-fresh .app-actions .btn-danger { border-radius: 8px; }
@media (max-width: 760px) {
  .app-answers { grid-template-columns: 1fr; }
  .apps-fresh .app-head { grid-template-columns: auto minmax(0, 1fr); }
  .apps-fresh .app-date { grid-column: 1 / -1; }
}
.apps-fresh .apps-share { margin-top: 24px; }
