/* BidBoard base: brand tokens, type, controls. Shared by the pages, the admin and the React web app.
   The token block is generated from shared/tokens.ts by `npm run build`; edit the tokens there. */
/* build:tokens */
:root {
  --font: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif; --mono: ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace; --radius-xs: 6px; --radius-sm: 8px; --radius-md: 12px; --radius-lg: 16px; --radius-xl: 22px; --radius-pill: 999px;
  --bg: #f7f8fa; --surface: #ffffff; --surface-2: #eef1f5; --ink: #0f172a; --muted: #475569; --subtle: #64748b; --border: #e2e8f0; --border-strong: #cbd5e1; --accent: #0f766e; --accent-hover: #115e59; --accent-ink: #ffffff; --accent-soft: #d9f4ef; --ok: #15803d; --ok-soft: #e7f6ec; --warn: #b45309; --warn-soft: #fff4e0; --danger: #b91c1c; --danger-soft: #fdecec; --info: #1d4ed8; --info-soft: #e8efff; --overlay: rgba(15, 23, 42, 0.45); --status-applied-fg: #1d4ed8; --status-applied-bg: #e8efff; --status-applied-dot: #3b82f6; --status-viewed-fg: #6d28d9; --status-viewed-bg: #f1eaff; --status-viewed-dot: #8b5cf6; --status-interview-fg: #b45309; --status-interview-bg: #fff4e0; --status-interview-dot: #f59e0b; --status-won-fg: #15803d; --status-won-bg: #e7f6ec; --status-won-dot: #22c55e; --status-lost-fg: #be123c; --status-lost-bg: #fdecef; --status-lost-dot: #f43f5e; --fit-low-fg: #b91c1c; --fit-low-bg: #fdecec; --fit-low-dot: #ef4444; --fit-medium-fg: #b45309; --fit-medium-bg: #fff4e0; --fit-medium-dot: #f59e0b; --fit-high-fg: #15803d; --fit-high-bg: #e7f6ec; --fit-high-dot: #22c55e; --chart-bar: #0f766e; --chart-bar-muted: #99d5cc; --chart-won: #0d9488; --chart-lost: #d97706; --chart-open: #64748b; --chart-grid: #e2e8f0; --chart-axis: #64748b; --shadow: 0 1px 2px rgba(15, 23, 42, 0.06), 0 8px 24px rgba(15, 23, 42, 0.06); --shadow-raised: 0 2px 4px rgba(15, 23, 42, 0.08), 0 16px 40px rgba(15, 23, 42, 0.14);
  --text: var(--ink);
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) { --bg: #0b1120; --surface: #111a2e; --surface-2: #172238; --ink: #e2e8f0; --muted: #94a3b8; --subtle: #7c8aa0; --border: #1f2a40; --border-strong: #334155; --accent: #2dd4bf; --accent-hover: #5eead4; --accent-ink: #042f2e; --accent-soft: #0f2f2e; --ok: #4ade80; --ok-soft: #0f2a1b; --warn: #fbbf24; --warn-soft: #2b2110; --danger: #f87171; --danger-soft: #2c1414; --info: #93c5fd; --info-soft: #142242; --overlay: rgba(2, 6, 23, 0.7); --status-applied-fg: #93c5fd; --status-applied-bg: #142242; --status-applied-dot: #60a5fa; --status-viewed-fg: #c4b5fd; --status-viewed-bg: #241a42; --status-viewed-dot: #a78bfa; --status-interview-fg: #fbbf24; --status-interview-bg: #2b2110; --status-interview-dot: #fbbf24; --status-won-fg: #4ade80; --status-won-bg: #0f2a1b; --status-won-dot: #4ade80; --status-lost-fg: #fb7185; --status-lost-bg: #2c1418; --status-lost-dot: #fb7185; --fit-low-fg: #f87171; --fit-low-bg: #2c1414; --fit-low-dot: #f87171; --fit-medium-fg: #fbbf24; --fit-medium-bg: #2b2110; --fit-medium-dot: #fbbf24; --fit-high-fg: #4ade80; --fit-high-bg: #0f2a1b; --fit-high-dot: #4ade80; --chart-bar: #2dd4bf; --chart-bar-muted: #1d5c56; --chart-won: #2dd4bf; --chart-lost: #f59e0b; --chart-open: #64748b; --chart-grid: #1f2a40; --chart-axis: #94a3b8; --shadow: 0 1px 2px rgba(0, 0, 0, 0.3), 0 10px 30px rgba(0, 0, 0, 0.35); --shadow-raised: 0 2px 6px rgba(0, 0, 0, 0.4), 0 18px 44px rgba(0, 0, 0, 0.5); color-scheme: dark; }
}
:root[data-theme="dark"] { --bg: #0b1120; --surface: #111a2e; --surface-2: #172238; --ink: #e2e8f0; --muted: #94a3b8; --subtle: #7c8aa0; --border: #1f2a40; --border-strong: #334155; --accent: #2dd4bf; --accent-hover: #5eead4; --accent-ink: #042f2e; --accent-soft: #0f2f2e; --ok: #4ade80; --ok-soft: #0f2a1b; --warn: #fbbf24; --warn-soft: #2b2110; --danger: #f87171; --danger-soft: #2c1414; --info: #93c5fd; --info-soft: #142242; --overlay: rgba(2, 6, 23, 0.7); --status-applied-fg: #93c5fd; --status-applied-bg: #142242; --status-applied-dot: #60a5fa; --status-viewed-fg: #c4b5fd; --status-viewed-bg: #241a42; --status-viewed-dot: #a78bfa; --status-interview-fg: #fbbf24; --status-interview-bg: #2b2110; --status-interview-dot: #fbbf24; --status-won-fg: #4ade80; --status-won-bg: #0f2a1b; --status-won-dot: #4ade80; --status-lost-fg: #fb7185; --status-lost-bg: #2c1418; --status-lost-dot: #fb7185; --fit-low-fg: #f87171; --fit-low-bg: #2c1414; --fit-low-dot: #f87171; --fit-medium-fg: #fbbf24; --fit-medium-bg: #2b2110; --fit-medium-dot: #fbbf24; --fit-high-fg: #4ade80; --fit-high-bg: #0f2a1b; --fit-high-dot: #4ade80; --chart-bar: #2dd4bf; --chart-bar-muted: #1d5c56; --chart-won: #2dd4bf; --chart-lost: #f59e0b; --chart-open: #64748b; --chart-grid: #1f2a40; --chart-axis: #94a3b8; --shadow: 0 1px 2px rgba(0, 0, 0, 0.3), 0 10px 30px rgba(0, 0, 0, 0.35); --shadow-raised: 0 2px 6px rgba(0, 0, 0, 0.4), 0 18px 44px rgba(0, 0, 0, 0.5); color-scheme: dark; }
/* /build:tokens */

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 76px; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } *, *::before, *::after { transition: none !important; animation: none !important; } }
body { margin: 0; background: var(--bg); color: var(--ink); font: 16px/1.6 var(--font); -webkit-font-smoothing: antialiased; }
h1, h2, h3 { line-height: 1.2; margin: 0 0 .5em; letter-spacing: -.01em; color: var(--ink); }
p { margin: 0 0 1em; }
a { color: var(--accent); text-underline-offset: 3px; }
a:hover { color: var(--accent-hover); }
img, svg { display: block; max-width: 100%; }
button, input, select, textarea { font: inherit; color: inherit; }
kbd { font: 12px var(--mono); padding: 1px 6px; border: 1px solid var(--border-strong); border-bottom-width: 2px; border-radius: 5px; background: var(--surface); }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; border-radius: 6px; }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap; }
.muted { color: var(--muted); }
.small { font-size: .875rem; }
.wrap { width: 100%; max-width: 1180px; margin: 0 auto; padding: 0 16px; }
@media (min-width: 720px) { .wrap { padding: 0 28px; } }
.wrap.narrow { max-width: 780px; }

.skip-link { position: absolute; left: 12px; top: -60px; background: var(--accent); color: var(--accent-ink); padding: 8px 14px; border-radius: 8px; z-index: 100; }
.skip-link:focus { top: 12px; color: var(--accent-ink); }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 44px; padding: 0 16px; border-radius: 10px; border: 1px solid var(--border-strong);
  background: var(--surface); color: var(--ink); font-weight: 650; font-size: .95rem; text-decoration: none; cursor: pointer;
  transition: background .15s, border-color .15s, transform .05s; white-space: nowrap;
}
.btn:hover { background: var(--surface-2); color: var(--ink); }
.btn:active { transform: translateY(1px); }
.btn.primary { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.btn.primary:hover { background: var(--accent-hover); border-color: var(--accent-hover); color: var(--accent-ink); }
.btn.ghost { background: transparent; }
.btn.ghost:hover { background: var(--surface-2); }
.btn.danger { color: var(--danger); }
.btn.danger.solid { background: var(--danger); border-color: var(--danger); color: #fff; }
.btn.small { min-height: 36px; padding: 0 12px; font-size: .875rem; }
.btn.block { width: 100%; }
.btn[disabled], .btn[aria-disabled="true"] { opacity: .55; cursor: not-allowed; }
.btn svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; flex: none; }
.linkish { background: none; border: 0; padding: 0; color: var(--accent); text-decoration: underline; text-underline-offset: 3px; cursor: pointer; font: inherit; }

.icon-btn {
  display: inline-grid; place-items: center; width: 44px; height: 44px; border-radius: 10px; flex: none;
  border: 1px solid var(--border); background: var(--surface); color: var(--ink); cursor: pointer;
}
.icon-btn:hover { background: var(--surface-2); }
.icon-btn svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.icon-btn[disabled] { opacity: .45; cursor: not-allowed; }
.i-moon { display: none; }
:root[data-theme="dark"] .i-sun { display: none; }
:root[data-theme="dark"] .i-moon { display: block; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .i-sun { display: none; }
  :root:not([data-theme="light"]) .i-moon { display: block; }
}

/* Fields */
.field { display: grid; gap: 6px; font-size: .875rem; font-weight: 600; margin-bottom: 14px; min-width: 0; align-content: start; }
.field > span { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: baseline; gap: 2px 8px; }
.field input:not([type="checkbox"]):not([type="radio"]), .field select, .field textarea,
input.input, select.input, textarea.input {
  width: 100%; min-width: 0; min-height: 44px; padding: 8px 12px; border-radius: 10px; border: 1px solid var(--border-strong);
  background: var(--surface); color: var(--ink); font-weight: 400; font-size: 1rem;
}
.field textarea, textarea.input { min-height: 96px; resize: vertical; line-height: 1.5; }
.field input:focus-visible, .field select:focus-visible, .field textarea:focus-visible { outline: 3px solid color-mix(in srgb, var(--accent) 60%, transparent); outline-offset: 1px; border-color: var(--accent); }
.field [aria-invalid="true"] { border-color: var(--danger); }
.field-error { color: var(--danger); font-weight: 600; font-size: .82rem; }
.hint-text { font-weight: 400; color: var(--muted); font-size: .8rem; }

/* Switch */
.switch { display: flex; align-items: center; gap: 12px; cursor: pointer; font-size: .9rem; margin: 6px 0; position: relative; }
.switch input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.switch-ui { flex: none; width: 40px; height: 24px; border-radius: 999px; background: var(--border-strong); position: relative; transition: background .2s; }
.switch-ui::after { content: ""; position: absolute; top: 3px; left: 3px; width: 18px; height: 18px; border-radius: 50%; background: #fff; box-shadow: 0 1px 2px rgba(0,0,0,.25); transition: transform .2s; }
.switch input:checked + .switch-ui { background: var(--accent); }
.switch input:checked + .switch-ui::after { transform: translateX(16px); }
.switch input:focus-visible + .switch-ui { outline: 3px solid var(--accent); outline-offset: 2px; }

.card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-lg); padding: 18px; box-shadow: var(--shadow); min-width: 0; }
.card h2, .card h3 { font-size: 1.02rem; margin-bottom: 12px; }
.card-title-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 8px; flex-wrap: wrap; }
.card-title-row h2, .card-title-row h3 { margin: 0; }
.badge { display: inline-flex; align-items: center; gap: 4px; padding: 2px 9px; border-radius: 999px; background: var(--accent-soft); color: var(--accent); font-size: .75rem; font-weight: 700; letter-spacing: .02em; white-space: nowrap; }
.badge.ok { background: var(--ok-soft); color: var(--ok); }
.badge.warn { background: var(--warn-soft); color: var(--warn); }
.badge.danger { background: var(--danger-soft); color: var(--danger); }
.badge.muted { background: var(--surface-2); color: var(--muted); }

/* Status and fit chips (shared with the web app) */
.chip { display: inline-flex; align-items: center; gap: 6px; padding: 2px 9px; border-radius: 999px; font-size: .78rem; font-weight: 700; white-space: nowrap; line-height: 1.6; }
.chip::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: currentColor; opacity: .9; }
.chip.applied { background: var(--status-applied-bg); color: var(--status-applied-fg); }
.chip.viewed { background: var(--status-viewed-bg); color: var(--status-viewed-fg); }
.chip.interview { background: var(--status-interview-bg); color: var(--status-interview-fg); }
.chip.won { background: var(--status-won-bg); color: var(--status-won-fg); }
.chip.lost { background: var(--status-lost-bg); color: var(--status-lost-fg); }
.fit { display: inline-flex; align-items: center; justify-content: center; min-width: 40px; padding: 2px 8px; border-radius: 8px; font-size: .78rem; font-weight: 800; font-variant-numeric: tabular-nums; white-space: nowrap; }
.fit.low { background: var(--fit-low-bg); color: var(--fit-low-fg); }
.fit.medium { background: var(--fit-medium-bg); color: var(--fit-medium-fg); }
.fit.high { background: var(--fit-high-bg); color: var(--fit-high-fg); }

.notice { margin: 12px 0 0; padding: 10px 12px; border-radius: 10px; background: var(--warn-soft); color: var(--ink); font-size: .9rem; border: 1px solid color-mix(in srgb, var(--warn) 30%, transparent); }
.notice.ok { background: var(--ok-soft); border-color: color-mix(in srgb, var(--ok) 30%, transparent); }
.notice.info { background: var(--info-soft); border-color: color-mix(in srgb, var(--info) 30%, transparent); }
.notice.danger { background: var(--danger-soft); border-color: color-mix(in srgb, var(--danger) 30%, transparent); }

.toast {
  position: fixed; left: 50%; bottom: 24px; transform: translateX(-50%); z-index: 90; max-width: min(92vw, 520px);
  background: var(--ink); color: var(--bg); padding: 12px 18px; border-radius: 12px; box-shadow: var(--shadow-raised); font-size: .95rem;
}
