/* Oak Kids Marketing — one stylesheet, from Oak-HR's. Tokens first (Brand Guidelines section 2), then layout, then components. */


@font-face { font-family: Quicksand; font-weight: 500; font-display: swap; src: url(fonts/quicksand-latin-500-normal.woff2) format("woff2"); }
@font-face { font-family: Quicksand; font-weight: 600; font-display: swap; src: url(fonts/quicksand-latin-600-normal.woff2) format("woff2"); }
@font-face { font-family: Quicksand; font-weight: 700; font-display: swap; src: url(fonts/quicksand-latin-700-normal.woff2) format("woff2"); }
@font-face { font-family: "Nunito Sans"; font-weight: 400; font-display: swap; src: url(fonts/nunito-sans-latin-400-normal.woff2) format("woff2"); }
@font-face { font-family: "Nunito Sans"; font-weight: 500; font-display: swap; src: url(fonts/nunito-sans-latin-500-normal.woff2) format("woff2"); }
@font-face { font-family: "Nunito Sans"; font-weight: 600; font-display: swap; src: url(fonts/nunito-sans-latin-600-normal.woff2) format("woff2"); }
@font-face { font-family: "Nunito Sans"; font-weight: 700; font-display: swap; src: url(fonts/nunito-sans-latin-700-normal.woff2) format("woff2"); }

/* ---------- Tokens ---------- */
:root {
  --bg: #FAFAF7;
  --surface: #FFFFFF;
  --surface-2: #F5F5F1;
  --ink: #3F3F3D;
  --ink-2: #62625F;
  --ink-3: #8A8A86;
  --line: #E6E6E0;
  --line-strong: #D2D2CA;
  --accent: #44691F;
  --accent-ink: #FFFFFF;
  --accent-soft: #EEF6E6;
  --link: #055E86;
  --side: #FFFFFF;

  /* status: the brand's text-safe colours on its pale tints */
  --ok: #44691F;     --ok-soft: #EEF6E6;
  --warn: #A85716;   --warn-soft: #FFF3EA;
  --bad: #9C101B;    --bad-soft: #FDECEE;
  --info: #055E86;   --info-soft: #E8F5FB;

  /* category leaves: the six leaf colours */
  --leaf-overview: #8A8A86;
  --leaf-rulebook: #70A83B;
  --leaf-admin: #009BDB;
  --leaf-me: #FF6679;
  --leaf-drafts: #FF914D;
  --leaf-events: #FFBD59;
  --leaf-results: #D81225;

  --radius: 8px;
  --radius-sm: 6px;
  --shadow: 0 1px 2px rgba(47, 48, 46, .06);
  --focus: 0 0 0 3px color-mix(in srgb, var(--accent) 35%, transparent);
  color-scheme: light;
}

/* Dark: follows the device unless the person picked a theme. */
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #1B1B1A; --surface: #242423; --surface-2: #1F1F1E; --ink: #EDEDE9; --ink-2: #B8B8B2; --ink-3: #8E8E88;
    --line: #353533; --line-strong: #464643; --accent: #9CCB6E; --accent-ink: #172510; --accent-soft: #263220; --link: #6CC4EE; --side: #1F1F1E;
    --ok: #9CCB6E; --ok-soft: #233020; --warn: #FFB27D; --warn-soft: #3A2A1C; --bad: #FF8A95; --bad-soft: #3D1F23; --info: #6CC4EE; --info-soft: #16303D;
    --shadow: none; color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #1B1B1A; --surface: #242423; --surface-2: #1F1F1E; --ink: #EDEDE9; --ink-2: #B8B8B2; --ink-3: #8E8E88;
    --line: #353533; --line-strong: #464643; --accent: #9CCB6E; --accent-ink: #172510; --accent-soft: #263220; --link: #6CC4EE; --side: #1F1F1E;
    --ok: #9CCB6E; --ok-soft: #233020; --warn: #FFB27D; --warn-soft: #3A2A1C; --bad: #FF8A95; --bad-soft: #3D1F23; --info: #6CC4EE; --info-soft: #16303D;
  --shadow: none; color-scheme: dark;
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 400 15px/1.55 "Nunito Sans", Arial, Helvetica, sans-serif; -webkit-font-smoothing: antialiased; }
h1, h2, h3 { margin: 0; line-height: 1.25; font-weight: 700; font-family: Quicksand, "Nunito Sans", Arial, sans-serif; }
h1 { font-size: 24px; letter-spacing: -.01em; }
h2 { font-size: 17px; }
h3 { font-size: 15px; }
p { margin: 0 0 12px; }
a { color: var(--link); text-decoration: none; }
a:hover { text-decoration: underline; }
:focus-visible { outline: none; box-shadow: var(--focus); border-radius: var(--radius-sm); }
.num { font-variant-numeric: tabular-nums; white-space: nowrap; }
[hidden] { display: none !important; }
.muted { color: var(--ink-2); }
.small { font-size: 13px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
@media (prefers-reduced-motion: reduce) { * { transition: none !important; animation: none !important; } }

/* ---------- App shell ---------- */
.shell { display: grid; grid-template-columns: 248px 1fr; min-height: 100vh; }
.side { background: var(--side); border-right: 1px solid var(--line); padding: 20px 14px; position: sticky; top: 0; height: 100vh; overflow-y: auto; display: flex; flex-direction: column; gap: 22px; }
.brand { display: flex; align-items: center; gap: 10px; padding: 0 8px; color: var(--ink); }
.brand img { width: 34px; height: auto; }
.brand b { display: block; font-size: 16px; font-weight: 700; font-family: Quicksand, "Nunito Sans", Arial, sans-serif; }
.brand span { display: block; font-size: 12.5px; color: var(--ink-3); }
.brand:hover { text-decoration: none; }

.nav-group h2 { display: flex; align-items: center; gap: 8px; font-size: 12.5px; font-weight: 600; color: var(--ink-3); padding: 0 8px 6px; }
.nav-group h2 i { width: 9px; height: 13px; border-radius: 9px 1px 9px 1px; background: var(--leaf); flex: none; }
.nav-group ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 1px; }
.nav-group a { display: block; padding: 7px 10px 7px 25px; border-radius: var(--radius-sm); color: var(--ink-2); font-weight: 500; font-size: 14.5px; }
.nav-group a:hover { background: var(--surface-2); color: var(--ink); text-decoration: none; }
.nav-group a[aria-current="page"] { background: var(--surface); color: var(--ink); box-shadow: inset 3px 0 0 var(--leaf), var(--shadow); }
.leaf-overview { --leaf: var(--leaf-overview); } .leaf-rulebook { --leaf: var(--leaf-rulebook); } .leaf-admin { --leaf: var(--leaf-admin); } .leaf-me { --leaf: var(--leaf-me); }
.leaf-drafts { --leaf: var(--leaf-drafts); } .leaf-events { --leaf: var(--leaf-events); } .leaf-results { --leaf: var(--leaf-results); }
.side-foot { margin-top: auto; font-size: 12.5px; color: var(--ink-3); padding: 0 8px; }

.main { min-width: 0; display: flex; flex-direction: column; }
.top { display: flex; align-items: center; gap: 12px; padding: 12px 32px; border-bottom: 1px solid var(--line); background: var(--surface); position: sticky; top: 0; z-index: 5; }
.top .spacer { flex: 1; }
.btn.menu-btn { display: none; }
.content { padding: 28px 32px 56px; max-width: 1240px; width: 100%; }
.page-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; margin-bottom: 22px; flex-wrap: wrap; }
.page-head p { margin: 4px 0 0; color: var(--ink-2); }
.readonly-note { background: var(--info-soft); color: var(--info); padding: 8px 32px; font-size: 13.5px; font-weight: 500; }

/* Branch picker, user and theme */
.picker { display: flex; align-items: center; gap: 8px; }
.picker select { min-width: 0; width: auto; max-width: 260px; }
.who { display: flex; align-items: center; gap: 10px; font-size: 13.5px; }
.who b { font-weight: 600; }
.who span { color: var(--ink-3); }
.theme { display: inline-flex; border: 1px solid var(--line); border-radius: 999px; padding: 2px; background: var(--surface-2); }
.theme button { border: 0; background: none; color: var(--ink-3); width: 30px; height: 26px; border-radius: 999px; cursor: pointer; display: grid; place-items: center; }
.theme button[aria-pressed="true"] { background: var(--surface); color: var(--ink); box-shadow: var(--shadow); }
.theme svg { width: 15px; height: 15px; }

/* ---------- Components ---------- */
.panel { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); }
.panel + .panel { margin-top: 18px; }
.panel-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 14px 18px; border-bottom: 1px solid var(--line); }
.panel-head p { margin: 2px 0 0; font-size: 13.5px; color: var(--ink-2); }
.panel-body { padding: 18px; }
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; align-items: start; }
.grid-2 > .panel + .panel { margin-top: 0; }
.stack > * + * { margin-top: 18px; }

.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); margin-bottom: 18px; overflow: hidden; }
.stat { padding: 14px 18px; border-right: 1px solid var(--line); }
.stat:last-child { border-right: 0; }
.stat dt { font-size: 13px; color: var(--ink-2); }
.stat dd { margin: 2px 0 0; font-size: 24px; font-weight: 600; font-variant-numeric: tabular-nums; }
.stat.is-alert dd { color: var(--bad); }

table { width: 100%; border-collapse: collapse; font-size: 14px; }
th { text-align: left; font-weight: 600; font-size: 12.5px; color: var(--ink-2); padding: 9px 14px; border-bottom: 1px solid var(--line); background: var(--surface-2); white-space: nowrap; }
td { padding: 10px 14px; border-bottom: 1px solid var(--line); vertical-align: top; }
tr:last-child td { border-bottom: 0; }
td.right, th.right { text-align: right; }
.table-wrap { overflow-x: auto; }
tbody tr:hover { background: var(--surface-2); }

.pill { display: inline-flex; align-items: center; gap: 5px; font-size: 12.5px; font-weight: 600; padding: 2px 8px; border-radius: 999px; white-space: nowrap; background: var(--surface-2); color: var(--ink-2); border: 1px solid var(--line); }
.pill::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.pill.ok { background: var(--ok-soft); color: var(--ok); border-color: transparent; }
.pill.warn { background: var(--warn-soft); color: var(--warn); border-color: transparent; }
.pill.bad { background: var(--bad-soft); color: var(--bad); border-color: transparent; }
.pill.info { background: var(--info-soft); color: var(--info); border-color: transparent; }

.list { list-style: none; margin: 0; padding: 0; }
.list li { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 11px 18px; border-bottom: 1px solid var(--line); }
.list li:last-child { border-bottom: 0; }
.empty { padding: 26px 18px; color: var(--ink-2); font-size: 14px; }

dl.facts { display: grid; grid-template-columns: 160px 1fr; gap: 8px 16px; margin: 0; font-size: 14px; }
dl.facts dt { color: var(--ink-2); }
dl.facts dd { margin: 0; }

/* Forms */
label { display: block; font-size: 13.5px; font-weight: 600; margin-bottom: 5px; }
.hint { font-weight: 400; color: var(--ink-3); font-size: 12.5px; }
input[type=text], input[type=email], input[type=password], input[type=number], input[type=date], input[type=datetime-local], input[type=tel], select, textarea {
  width: 100%; font: inherit; color: var(--ink); background: var(--surface); border: 1px solid var(--line-strong); border-radius: var(--radius-sm); padding: 8px 10px; min-height: 38px;
}
textarea { min-height: 96px; resize: vertical; }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--accent); box-shadow: var(--focus); }
.field { margin-bottom: 14px; }
.fields { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 0 16px; }
.check { display: flex; gap: 8px; align-items: flex-start; font-weight: 400; font-size: 14px; }
.check input { margin-top: 3px; accent-color: var(--accent); }
.form-actions { display: flex; gap: 10px; align-items: center; margin-top: 6px; flex-wrap: wrap; }
.inline-form { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.inline-form input, .inline-form select { width: auto; min-height: 34px; padding: 5px 8px; }

.btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; font: 600 14px/1 "Nunito Sans", Arial, sans-serif; padding: 10px 16px; min-height: 38px; border-radius: var(--radius-sm); border: 1px solid var(--line-strong); background: var(--surface); color: var(--ink); cursor: pointer; white-space: nowrap; }
.btn:hover { background: var(--surface-2); text-decoration: none; }
.btn.primary { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.btn.primary:hover { filter: brightness(1.06); }
.btn.danger { color: var(--bad); }
.btn.small { padding: 6px 10px; min-height: 30px; font-size: 13px; }
.btn.link { border: 0; background: none; color: var(--accent); padding: 0; min-height: 0; font-weight: 600; }
.btn:disabled { opacity: .5; cursor: not-allowed; }

.alert { padding: 11px 14px; border-radius: var(--radius-sm); margin-bottom: 18px; font-size: 14px; font-weight: 500; border: 1px solid transparent; }
.alert.success { background: var(--ok-soft); color: var(--ok); }
.alert.error { background: var(--bad-soft); color: var(--bad); }
.alert.warning { background: var(--warn-soft); color: var(--warn); }
.alert.info { background: var(--info-soft); color: var(--info); }

.tabs { display: flex; gap: 4px; margin-bottom: 14px; flex-wrap: wrap; }
.tabs a { padding: 6px 12px; border-radius: 999px; color: var(--ink-2); font-weight: 500; font-size: 14px; border: 1px solid var(--line); background: var(--surface); }
.tabs a[aria-current="page"] { background: var(--ink); color: var(--surface); border-color: var(--ink); }
.tabs a:hover { text-decoration: none; }

/* Applicant board */
.board { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(170px, 1fr); gap: 12px; overflow-x: auto; padding-bottom: 6px; }
.lane { background: var(--surface-2); border: 1px solid var(--line); border-radius: var(--radius); padding: 10px; min-height: 140px; }
.lane h2 { font-size: 13.5px; display: flex; justify-content: space-between; color: var(--ink-2); margin: 2px 4px 10px; }
.card { display: block; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 10px 12px; margin-bottom: 8px; color: var(--ink); box-shadow: var(--shadow); }
.card:hover { border-color: var(--line-strong); text-decoration: none; }
.card b { display: block; font-weight: 600; }
.card span { display: block; font-size: 12.5px; color: var(--ink-2); }

/* Permission matrix */
.matrix td, .matrix th { text-align: center; }
.matrix td:first-child, .matrix th:first-child { text-align: left; }
.yes { color: var(--ok); font-weight: 700; }
.no { color: var(--ink-3); }
.ro { color: var(--info); font-size: 12.5px; font-weight: 600; }
.matrix .group td { background: var(--surface-2); font-weight: 600; font-size: 12.5px; color: var(--ink-2); text-align: left; }

/* Sign-in and public pages */
.bare { min-height: 100vh; display: grid; place-items: center; padding: 24px; }
.auth { width: 100%; max-width: 400px; }
.auth .brand { justify-content: center; margin-bottom: 22px; }
.auth .brand img { width: 52px; }
.auth .panel-body { padding: 26px; }
.auth h1 { font-size: 20px; margin-bottom: 4px; }
.auth .btn.primary { width: 100%; }
.code-input { font-size: 22px !important; letter-spacing: .3em; text-align: center; font-variant-numeric: tabular-nums; }
.qr { display: grid; place-items: center; padding: 14px; background: #fff; border-radius: var(--radius-sm); border: 1px solid var(--line); margin: 14px 0; }
.qr canvas { width: 180px; height: 180px; image-rendering: pixelated; }
.secret { font: 600 15px/1.4 ui-monospace, Menlo, monospace; letter-spacing: .08em; word-break: break-all; background: var(--surface-2); padding: 8px 10px; border-radius: var(--radius-sm); }

.public-top { background: var(--surface); border-bottom: 1px solid var(--line); }
.public-top .wrap, .public .wrap { max-width: 820px; margin: 0 auto; padding: 16px 24px; }
.public .wrap { padding: 36px 24px 64px; }
.job { display: block; padding: 18px; color: var(--ink); }
.job:hover { background: var(--surface-2); text-decoration: none; }
.job h2 { margin-bottom: 4px; }
.auth-foot { display: flex; justify-content: center; margin-top: 16px; }
.public-bar { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.honey { position: absolute; left: -9999px; }

/* ---------- Small screens ---------- */
@media (max-width: 900px) {
  .shell { grid-template-columns: 1fr; }
  .side { position: fixed; inset: 0 auto 0 0; width: 272px; z-index: 20; transform: translateX(-100%); transition: transform .2s ease; box-shadow: 0 0 40px rgba(0,0,0,.2); }
  body.nav-open .side { transform: none; }
  .btn.menu-btn { display: inline-flex; }
  .top { padding: 10px 16px; flex-wrap: wrap; }
  .content { padding: 20px 16px 48px; }
  .readonly-note { padding: 8px 16px; }
  .grid-2 { grid-template-columns: 1fr; }
  .who span { display: none; }
  .picker select { min-width: 0; max-width: 150px; }
  dl.facts { grid-template-columns: 1fr; gap: 2px; }
  dl.facts dd { margin-bottom: 8px; }
}

/* Spacing utilities */
.gap-top { margin-top: 14px; }
.steps { padding-left: 18px; margin: 0 0 4px; }
.steps li { margin-bottom: 4px; }
.narrow { max-width: 420px; }

/* Row disclosure: a compact "Update" toggle that opens a small form under the row */
details.row-edit > summary { list-style: none; cursor: pointer; display: inline-flex; }
details.row-edit > summary::-webkit-details-marker { display: none; }
details.row-edit[open] > summary { margin-bottom: 10px; }
details.row-edit .fields { grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); }
.panel-head > a { white-space: nowrap; }
@media (max-width: 900px) { .stat { border-bottom: 1px solid var(--line); } }
.picker { flex-wrap: wrap; }

/* Payroll steps */
.progress { list-style: none; display: flex; gap: 0; margin: 0 0 18px; padding: 0; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; background: var(--surface); }
.progress li { flex: 1; padding: 9px 14px; font-size: 13.5px; font-weight: 600; color: var(--ink-3); border-right: 1px solid var(--line); }
.progress li:last-child { border-right: 0; }
.progress li.done { color: var(--ok); }
.progress li.now { color: var(--ink); background: var(--accent-soft); box-shadow: inset 0 -3px 0 var(--accent); }
.leave-row { align-items: flex-start !important; flex-wrap: wrap; }
a.pill:hover { text-decoration: none; filter: brightness(.97); }
tfoot td { border-top: 1px solid var(--line-strong); background: var(--surface-2); }

/* Payslip, printable */
.print-page { background: var(--surface); }
.slip { max-width: 640px; margin: 32px auto; padding: 0 20px; }
.slip-head { display: flex; align-items: center; justify-content: space-between; border-bottom: 2px solid var(--ink); padding-bottom: 14px; margin-bottom: 18px; }
.slip-head img { width: 64px; height: auto; }
.slip-head h1 { text-align: right; }
.slip-head p { text-align: right; margin: 2px 0 0; color: var(--ink-2); }
.slip-table { margin: 20px 0; }
.slip-table th { background: none; border-bottom: 1px solid var(--ink-3); }
.slip-table .sum td { font-weight: 600; }
.slip-table tfoot td { font-size: 17px; font-weight: 700; border-top: 2px solid var(--ink); background: none; }
@media print {
  :root { --bg: #fff; --surface: #fff; --surface-2: #fff; --ink: #000; --ink-2: #333; --ink-3: #555; --line: #bbb; }
  .no-print { display: none; }
  .slip { margin: 0 auto; }
}

/* ---------- Growth and cases ---------- */
.leaf-growth { --leaf: var(--leaf-growth); } .leaf-cases { --leaf: var(--leaf-cases); }
.leaf-insights { --leaf: var(--leaf-insights); } .leaf-life { --leaf: var(--leaf-life); }
.pill.level-exceeding { background: var(--ok-soft); color: var(--ok); border-color: transparent; }
.pill.level-meeting { background: var(--info-soft); color: var(--info); border-color: transparent; }
.pill.level-needs_support { background: var(--warn-soft); color: var(--warn); border-color: transparent; }
.pill.level-below { background: var(--bad-soft); color: var(--bad); border-color: transparent; }
.big-num { font-size: 26px; font-weight: 600; margin-right: 6px; }
.checklist { list-style: decimal; margin: 0; padding: 4px 18px 0 38px; }
.checklist li { padding: 12px 0; border-bottom: 1px solid var(--line); }
.checklist p { margin: 0 0 8px; }
.choice { display: flex; gap: 18px; margin-bottom: 8px; }
.check-detail { border-bottom: 1px solid var(--line); padding: 0 18px; }
.check-detail:last-child { border-bottom: 0; }
.check-detail summary { display: flex; justify-content: space-between; gap: 12px; padding: 11px 0; cursor: pointer; list-style: none; }
.check-detail summary::-webkit-details-marker { display: none; }
.check-detail[open] { padding-bottom: 10px; }
.duty-form { display: flex; flex-direction: column; gap: 4px; align-items: flex-start; }
.duty-form .check { white-space: nowrap; }
.scores { display: grid; grid-template-columns: 1fr repeat(4, 64px); align-items: center; gap: 6px 4px; margin-bottom: 16px; }
.scores .head { font-size: 12.5px; color: var(--ink-2); font-weight: 600; text-align: center; }
.scores label.cell { display: grid; place-items: center; margin: 0; padding: 6px 0; border-radius: var(--radius-sm); cursor: pointer; }
.scores label.cell:hover { background: var(--surface-2); }
.scores input { accent-color: var(--accent); }
.note-box { white-space: pre-wrap; background: var(--surface-2); border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 12px 14px; margin: 0 0 12px; font-size: 14px; }
.timeline { list-style: none; margin: 0; padding: 0 18px; }
.timeline li { padding: 12px 0; border-bottom: 1px solid var(--line); }
.timeline li:last-child { border-bottom: 0; }
.timeline .meta { font-size: 12.5px; color: var(--ink-3); margin-bottom: 4px; }
.timeline p { white-space: pre-wrap; margin: 0; font-size: 14px; }
.private-note { display: flex; gap: 10px; align-items: flex-start; background: var(--accent-soft); color: var(--ink); border-radius: var(--radius-sm); padding: 12px 14px; font-size: 13.5px; margin-bottom: 18px; }
.money-lines td:last-child { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
.money-lines .minus { color: var(--bad); }
.letter { max-width: 640px; margin: 32px auto; padding: 0 20px; font-size: 15px; line-height: 1.7; }
.letter .sign { margin-top: 56px; }
@media (max-width: 900px) { .scores { grid-template-columns: 1fr repeat(4, 40px); } }
fieldset.plain { border: 0; padding: 0; margin: 0 0 14px; display: grid; gap: 8px; }
fieldset.plain legend { font-size: 13.5px; font-weight: 600; margin-bottom: 8px; padding: 0; }
.card b .pill { display: inline-flex; vertical-align: 1px; margin-left: 4px; font-size: 11.5px; }
.card b .pill.info { color: var(--info); }

/* ---------- Keep and scale ---------- */
.staff-card { max-width: 380px; overflow: hidden; }
.staff-card-head { display: flex; align-items: center; gap: 10px; padding: 14px 18px; background: var(--accent); color: var(--accent-ink); }
.staff-card-head img { width: 34px; height: auto; background: #fff; border-radius: 50%; padding: 3px; }
.staff-card-head b { display: block; } .staff-card-head span { font-size: 13px; opacity: .85; }
.wall { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 18px; }
.wall .panel + .panel { margin-top: 0; }
.wall-card { border-top: 4px solid var(--leaf-life); }
.wall-card.kind-star { border-top-color: var(--leaf-pay); }
.wall-card.kind-thanks { border-top-color: var(--leaf-me); }
.wall-card h2 { margin-bottom: 2px; }
fieldset.scale { border: 0; padding: 0; margin: 0 0 20px; }
fieldset.scale legend { font-weight: 600; margin-bottom: 10px; padding: 0; }
.scale-row { display: grid; grid-template-columns: repeat(11, 1fr); gap: 4px; }
.scale-row label { margin: 0; }
.scale-row input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.scale-row span { display: grid; place-items: center; height: 40px; border: 1px solid var(--line-strong); border-radius: var(--radius-sm); font-weight: 600; cursor: pointer; background: var(--surface); }
.scale-row input:checked + span { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.scale-row input:focus-visible + span { box-shadow: var(--focus); }
.scale-ends { display: flex; justify-content: space-between; margin-top: 4px; }
.survey[dir="rtl"] { font-size: 17px; }
.score-bar { display: inline-flex; align-items: center; gap: 10px; }
.score-bar .bar { width: 120px; height: 8px; border-radius: 99px; background: var(--surface-2); border: 1px solid var(--line); overflow: hidden; }
.score-bar .bar i { display: block; height: 100%; background: var(--accent); }
.bar .w0 { width: 0; } .bar .w1 { width: 10%; } .bar .w2 { width: 20%; } .bar .w3 { width: 30%; } .bar .w4 { width: 40%; } .bar .w5 { width: 50%; }
.bar .w6 { width: 60%; } .bar .w7 { width: 70%; } .bar .w8 { width: 80%; } .bar .w9 { width: 90%; } .bar .w10 { width: 100%; }
.up { color: var(--ok); font-weight: 600; } .down { color: var(--bad); font-weight: 600; }
.letter.wide { max-width: 900px; }
.inspect-person { margin-top: 26px; break-inside: avoid; }
.inspect-person h2 { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; font-size: 16px; }
.ladder { list-style: none; margin: 0; padding: 0 18px; }
.ladder li { padding: 10px 0 10px 22px; border-left: 2px solid var(--line); position: relative; }
.ladder li::before { content: ""; position: absolute; left: -6px; top: 15px; width: 10px; height: 10px; border-radius: 50%; background: var(--surface); border: 2px solid var(--line-strong); }
.ladder li.done::before { background: var(--accent); border-color: var(--accent); }
.ladder li.now::before { background: var(--accent); border-color: var(--accent); box-shadow: 0 0 0 4px var(--accent-soft); }
.ladder li.now b { color: var(--accent); }
@media (max-width: 900px) { .scale-row span { height: 36px; font-size: 13px; } .score-bar .bar { width: 70px; } }
.cover-offer { border-bottom: 1px solid var(--line); background: var(--warn-soft); }

/* ---------- Contracts and signing ---------- */
.contract-grid { grid-template-columns: 3fr 2fr; }
.contract h1 { font-size: 21px; margin-bottom: 8px; }
.contract h2, .contract-print h2 { font-size: 16px; margin: 20px 0 8px; }
.contract p, .contract li { font-size: 14.5px; line-height: 1.6; }
.contract-schedule { margin: 4px 0 8px; }
.contract-schedule th { width: 40%; background: none; white-space: normal; }
.contract-terms { padding-left: 20px; margin: 0; }
.contract-terms li { margin-bottom: 8px; }
.sign-pad { position: relative; border: 2px dashed var(--line-strong); border-radius: var(--radius-sm); background: #fff; touch-action: none; }
.sign-pad canvas { display: block; width: 100%; height: auto; aspect-ratio: 3 / 1; cursor: crosshair; }
.sign-pad [data-signature-clear] { position: absolute; top: 6px; right: 6px; }
.sign-pad.signed { border-style: solid; border-color: var(--accent); }
.sig-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-bottom: 14px; }
.sig-img { width: 100%; max-width: 260px; height: auto; background: #fff; border: 1px solid var(--line); border-radius: var(--radius-sm); }
.hash { font-family: ui-monospace, Menlo, monospace; font-size: 11.5px; word-break: break-all; }
@media (max-width: 900px) { .contract-grid { grid-template-columns: 1fr; } }

/* Readiness */
.readiness { table-layout: fixed; }
.readiness td { vertical-align: top; overflow-wrap: break-word; }
.readiness-what { width: 190px; }
.readiness td:nth-child(2) { width: 120px; }
.readiness td:nth-child(4) { width: 110px; }
@media (max-width: 900px) {
  .readiness, .readiness tbody { display: block; }
  .readiness tr { display: grid; grid-template-columns: 1fr auto; gap: 6px 12px; padding: 12px 14px; border-bottom: 1px solid var(--line); }
  .readiness td, .readiness-what, .readiness td:nth-child(2), .readiness td:nth-child(4) { display: block; width: auto; padding: 0; border: 0; }
  .readiness td:nth-child(3), .readiness td:nth-child(4) { grid-column: 1 / -1; text-align: left; }
}
.readonly-note.warn-note { background: var(--warn-soft); color: var(--warn); }
.readonly-note.warn-note a { color: inherit; text-decoration: underline; }

/* Maintenance or live switch (Readiness) */
.mode-switch { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 8px 18px; align-items: center; }
.mode-switch h2 { margin: 0 0 4px; font-size: 16px; }
.mode-switch p { margin: 0; }
.seg { display: inline-flex; gap: 6px; }
.mode-held { grid-column: 1 / -1; display: flex; gap: 10px; align-items: center; flex-wrap: wrap; padding-top: 10px; border-top: 1px solid var(--line); }
@media (max-width: 900px) { .mode-switch { grid-template-columns: minmax(0, 1fr); } }

/* Activity log details and overrides */
.log-details { margin-top: 4px; }
.log-details summary { cursor: pointer; color: var(--accent); font-weight: 600; }
.log-details pre { margin: 6px 0 0; padding: 10px 12px; background: var(--surface-2); border: 1px solid var(--line); border-radius: var(--radius-sm);
  font-size: 12px; line-height: 1.45; white-space: pre-wrap; overflow-wrap: anywhere; max-height: 320px; overflow: auto; color: var(--ink); }
.activity tr.is-override td { background: var(--warn-soft); }

/* ---------- The apply bot (/apply) ---------- */
.bot-page { min-height: 100vh; border-top: 4px solid var(--leaf-recruitment); }
.bot-wrap { max-width: 640px; margin: 0 auto; padding: 0 16px; }
.bot-head { position: sticky; top: 0; z-index: 5; background: var(--surface); border-bottom: 1px solid var(--line); }
.bot-headrow { display: flex; align-items: center; gap: 12px; padding-top: 10px; padding-bottom: 10px; }
.bot-headrow img { width: 36px; height: auto; flex: none; }
.bot-grow { flex: 1; min-width: 0; }
.bot-name { font-weight: 700; font-size: 16px; line-height: 1.2; }
.bot-sub, .bot-pct, .bot-soft { color: var(--ink-2); font-size: 13px; }
.bot-soft { margin: 8px 0 0; }
.bot-bar { height: 6px; background: var(--surface-2); border-radius: 99px; overflow: hidden; margin-top: 6px; }
.bot-bar i { display: block; height: 100%; width: 0; border-radius: 99px; background: var(--accent); transition: width .4s ease; }
.bot-main { padding-top: 18px; padding-bottom: 40px; display: grid; gap: 12px; }
body.bot-composing .bot-main { padding-bottom: calc(var(--bot-comp-h, 200px) + 40px); }
.bot-card { background: var(--surface); border: 1px solid var(--line); border-radius: 16px; padding: 22px; }
.bot-card h1 { font-size: 21px; margin-bottom: 8px; }
.bot-card h2 { font-size: 17px; margin-bottom: 6px; }
.bot-card p { margin: 0 0 10px; }
.bot-chat { display: flex; flex-direction: column; gap: 10px; }
.bot-say { display: flex; gap: 9px; align-items: flex-end; max-width: 88%; }
.bot-av { width: 28px; height: 28px; flex: none; border-radius: 50%; background: var(--surface); border: 1px solid var(--line); display: grid; place-items: center; }
.bot-av img { width: 20px; height: auto; }
.bot-bub { background: var(--surface); border: 1px solid var(--line); border-radius: 16px 16px 16px 4px; padding: 10px 14px; white-space: pre-wrap; overflow-wrap: anywhere; }
.bot-me { align-self: flex-end; max-width: 85%; background: var(--accent); color: var(--accent-ink); border: 0; border-radius: 16px 16px 4px 16px; padding: 9px 14px; text-align: left; font: inherit; cursor: pointer; white-space: pre-wrap; overflow-wrap: anywhere; }
.bot-me small { display: block; opacity: .8; font-size: 11.5px; margin-top: 2px; }
.bot-err { align-self: flex-start; margin-left: 37px; background: var(--bad-soft); color: var(--bad); border-radius: 12px; padding: 8px 12px; font-size: 14px; }
.bot-composer { position: fixed; left: 0; right: 0; bottom: 0; z-index: 6; background: var(--surface); border-top: 1px solid var(--line); box-shadow: 0 -6px 24px rgba(0,0,0,.06); padding: 12px 0 calc(12px + env(safe-area-inset-bottom)); }
.bot-composer .bot-wrap { display: grid; gap: 8px; }
.bot-row { display: flex; gap: 8px; align-items: stretch; }
/* 16px: iOS zooms into any smaller input when it is tapped. */
.bot-inp { flex: 1; min-width: 0; width: 100%; font-size: 16px; padding: 12px 13px; border-radius: 12px; }
textarea.bot-inp { min-height: 84px; }
.bot-btn { background: var(--accent); color: var(--accent-ink); border: 0; border-radius: 12px; padding: 12px 18px; font: 600 15px/1.2 inherit; font-family: inherit; cursor: pointer; white-space: nowrap; display: inline-flex; align-items: center; justify-content: center; }
.bot-btn:disabled { opacity: .5; cursor: default; }
.bot-ghost { background: var(--surface); color: var(--ink); border: 1px solid var(--line-strong); }
.bot-wide { width: 100%; }
.bot-pick { margin-top: 6px; }
.bot-opts { display: grid; grid-template-columns: minmax(0, 1fr); gap: 8px; max-height: 46vh; overflow-y: auto; }
.bot-opt { background: var(--surface); color: var(--ink); border: 1.5px solid var(--line-strong); border-radius: 12px; padding: 11px 13px; text-align: left; font: inherit; cursor: pointer; display: grid; gap: 1px; }
.bot-opt span { color: var(--ink-2); font-size: 13px; }
.bot-opt:hover, .bot-opt[aria-pressed="true"] { border-color: var(--accent); background: var(--accent-soft); }
.bot-tools { display: flex; justify-content: space-between; align-items: center; min-height: 20px; }
.bot-link { background: none; border: 0; color: var(--ink-2); padding: 4px 0; text-decoration: underline; text-underline-offset: 2px; font: inherit; font-size: 13.5px; cursor: pointer; }
.bot-file { display: flex; justify-content: space-between; gap: 10px; align-items: center; font-size: 14px; padding: 8px 0; border-top: 1px solid var(--line); }
.bot-file span { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.bot-review { margin-bottom: 14px; }
.bot-rv { display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 3fr) auto; gap: 10px; padding: 8px 0; border-top: 1px solid var(--line); font-size: 14.5px; align-items: start; }
.bot-rv .k { color: var(--ink-2); }
.bot-rv .v { white-space: pre-wrap; overflow-wrap: anywhere; }
.bot-msg { padding: 10px 12px; border-radius: 12px; font-size: 14px; }
.bot-msg.bad { background: var(--bad-soft); color: var(--bad); }
.bot-center { text-align: center; }
.bot-big { font-size: 40px; line-height: 1; color: var(--ok); margin-bottom: 8px; }
@media (max-width: 420px) {
  .bot-rv { grid-template-columns: minmax(0, 1fr) auto; }
  .bot-rv .k { grid-column: 1 / -1; font-size: 12.5px; }
}

/* Vacancies: each open post's apply link, to copy */
.apply-link { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; margin-top: 8px; }
.apply-link label { width: 100%; }
.apply-link input { flex: 1 1 220px; min-width: 0; width: auto; min-height: 32px; padding: 4px 8px; font-size: 13px; }

/* Interview questions and scores */
.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.nowrap { white-space: nowrap; }
.readonly-note.bad-note { background: var(--bad-soft); color: var(--bad); border-color: transparent; }
ul.plain { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
table.compact td, table.compact th { padding-top: 6px; padding-bottom: 6px; }
.q-line + .q-line { border-top: 1px solid var(--line); }
.q-head { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin: 0 0 6px; }
.q-num { display: inline-grid; place-items: center; width: 26px; height: 26px; border-radius: 50%; background: var(--surface-2); border: 1px solid var(--line); font-weight: 700; font-size: 13px; }
.q-text { display: block; font-weight: 600; margin: 0 0 8px; }
.q-answer { background: var(--surface-2); border: 1px solid var(--line); border-radius: 10px; padding: 10px 12px; margin: 0 0 10px; white-space: normal; }
.rubric { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-bottom: 10px; font-size: 14px; }
.rubric > div { border-radius: 10px; padding: 10px 12px; }
.rubric-good { background: var(--ok-soft); }
.rubric-good b { color: var(--ok); }
.rubric-bad { background: var(--bad-soft); }
.rubric-bad b { color: var(--bad); }
fieldset.rating { border: 0; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 6px; }
fieldset.rating label { position: relative; }
fieldset.rating input { position: absolute; opacity: 0; inset: 0; margin: 0; cursor: pointer; }
fieldset.rating span { display: inline-block; padding: 7px 12px; border: 1.5px solid var(--line); border-radius: 999px; font-size: 14px; background: var(--surface); }
fieldset.rating input:checked + span { border-color: var(--accent); background: var(--accent-soft); font-weight: 600; }
fieldset.rating input:focus-visible + span { outline: 2px solid var(--accent); outline-offset: 2px; }
.score-big { font-size: 30px; line-height: 1; margin-right: 4px; }
.score-line-total { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin: 12px 0 0; }
.result h3 { margin: 0 0 10px; }
@media (max-width: 700px) { .rubric { grid-template-columns: 1fr; } }
.panel-body .readonly-note, form .readonly-note { border-radius: 10px; padding: 8px 12px; }

/* ---------- Phase 2: drafts ---------- */
.post-preview { background: var(--surface-2); border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 14px 16px; white-space: normal; overflow-wrap: anywhere; }
.post-preview p:last-child { margin-bottom: 0; }
fieldset.facts-pick { border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 10px 14px; margin: 12px 0 16px; display: grid; gap: 6px; }
fieldset.facts-pick legend { font-weight: 600; font-size: 14px; padding: 0 4px; }
.gap-bottom { margin-bottom: 16px; }
table.checks td { vertical-align: top; }

/* ---------- Phase 3: media ---------- */
.media-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 14px; }
.media-card, .media-tile { display: grid; gap: 6px; align-content: start; color: var(--ink); }
.media-card img, .media-tile img { width: 100%; aspect-ratio: 1; object-fit: cover; border-radius: var(--radius-sm); border: 1px solid var(--line); background: var(--surface-2); }
.media-card:hover { text-decoration: none; }
fieldset.media-pick { border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 10px 14px; margin: 12px 0 16px; display: grid; grid-template-columns: repeat(auto-fill, minmax(110px, 1fr)); gap: 10px; }
fieldset.media-pick legend, fieldset.people-pick legend { font-weight: 600; font-size: 14px; padding: 0 4px; }
fieldset.people-pick { border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 10px 14px; margin: 12px 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 6px; }
.media-full { width: 100%; height: auto; border-radius: var(--radius-sm); }
.media-strip { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 10px; }
.media-strip img { width: 96px; height: 96px; object-fit: cover; border-radius: var(--radius-sm); border: 1px solid var(--line); }
ol.slides { padding-left: 20px; margin: 6px 0 0; display: grid; gap: 6px; }
.error-text { color: var(--bad); }

/* ---------- Phase 4: events ---------- */
.progress.stages { overflow-x: auto; }
.progress.stages li { white-space: nowrap; }
.stats.compact { margin-bottom: 12px; grid-template-columns: repeat(3, minmax(0, 1fr)); }
.stats.compact .stat { padding: 10px 14px; }
.stats.compact .stat dd { font-size: 20px; }
.comment { border-bottom: 1px solid var(--line); padding: 8px 0; }
.comment p { margin: 0 0 4px; }
.comment:last-of-type { border-bottom: 0; }
.rich h2 { font-size: 18px; margin: 14px 0 6px; }
.rich h3 { font-size: 16px; margin: 12px 0 6px; }
.rich p { margin: 0 0 10px; }
.rich ul, .rich ol { margin: 0 0 10px; padding-left: 22px; }
.rich-bar { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 6px; }
.rich-edit { min-height: 160px; padding: 10px 12px; border: 1px solid var(--line-strong, var(--line)); border-radius: var(--radius); background: var(--surface); color: var(--ink); }
.rich-edit:focus { outline: 2px solid var(--accent); outline-offset: 1px; }
.public .lead { font-size: 17px; color: var(--ink-2); }
fieldset.field { border: 0; padding: 0; margin: 0 0 14px; }
fieldset.field legend { font-weight: 600; margin-bottom: 6px; }

/* ---------- Phase 5: planning and insight ---------- */
.stars { color: var(--warn); letter-spacing: 1px; white-space: nowrap; }
tr.total td { border-top: 2px solid var(--line-strong); }
tr.muted td { color: var(--ink-3); }
.note-box p { margin: 0 0 6px; }

/* ---------- Phase 6: publishing ---------- */
.crisis-bar { background: var(--bad); color: var(--bg); padding: 10px 24px; font-size: 14px; }
.crisis-bar a { color: var(--bg); text-decoration: underline; }
.crisis-panel.is-paused { border-color: var(--bad); }
.email-preview { display: block; width: 100%; height: 720px; border: 0; background: var(--bg); }
.choose-row { align-items: end; border-bottom: 1px solid var(--line); padding-bottom: 10px; margin-bottom: 10px; }
