/* house-console — foundation/components.css
   Spine (01-shadcn) class API + semantic token names, wearing the 03-structured-console skin:
   sharp corners, hairline borders over shadows, cyan/teal accent, high density, mono numerics.
   Grafted form layer from 10-workflow-forms (field/switch/choice-card/stepper) is restyled onto
   the same token vocabulary. Consumes var(--*) from tokens.css ONLY — no bare hex/rgb, no
   var() fallback chains. Base styling is vanilla-HTML-consumable: nothing here requires a
   Radix/React runtime data-* attribute (attribute hooks are additive, hover/focus cover them). */

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
[hidden] { display: none !important; }

/* Legibility bump: every text AND spacing token in this system is rem-based off the root, so
   raising the root size scales the whole product proportionally (text, padding, icons-in-rem,
   radii) with zero risk of individual tokens drifting out of ratio with each other. */
html { -webkit-text-size-adjust: 100%; font-size: 110%; }
body {
  font-family: var(--font-sans);
  font-size: var(--text-base);
  line-height: var(--leading-base);
  color: var(--foreground);
  background: var(--background);
  -webkit-font-smoothing: antialiased;
}

a { color: var(--link); }
:focus-visible {
  outline: 2px solid var(--ring);
  outline-offset: 1px;
  border-radius: var(--radius-sm);
}
.visually-hidden {
  position: absolute;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* numeric / identifier text — monospace + tabular figures across the console */
.mono, .num, code, kbd {
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums;
}

/* ============ buttons ============ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--sp-2);
  height: 1.875rem;
  padding: 0 var(--sp-3);
  border: var(--border-width) solid transparent;
  border-radius: var(--radius);
  font: inherit;
  font-size: var(--text-sm);
  font-weight: var(--font-medium);
  line-height: 1;
  text-decoration: none;
  cursor: pointer;
  white-space: nowrap;
  transition: background var(--duration-fast) var(--easing-standard),
    border-color var(--duration-fast) var(--easing-standard),
    color var(--duration-fast) var(--easing-standard);
}
.btn:disabled { cursor: not-allowed; opacity: 0.5; }
.btn svg { flex: none; width: 14px; height: 14px; }

.btn--sm { height: 1.625rem; padding: 0 var(--sp-2); font-size: var(--text-xs); }
.btn--lg { height: 2.25rem; padding: 0 var(--sp-5); font-size: var(--text-base); }

.btn--primary { background: var(--primary); color: var(--primary-foreground); }
.btn--primary:hover:not(:disabled) { background: var(--primary-hover); }
.btn--primary:active:not(:disabled) { background: var(--primary-active); }

.btn--secondary { background: var(--secondary); color: var(--secondary-foreground); border-color: var(--border); }
.btn--secondary:hover:not(:disabled) { background: var(--secondary-hover); }

.btn--outline { background: var(--card); color: var(--foreground); border-color: var(--border-strong); }
.btn--outline:hover:not(:disabled) { background: var(--hover); border-color: var(--border-strong); }

.btn--ghost { background: transparent; color: var(--muted-foreground); }
.btn--ghost:hover:not(:disabled) { background: var(--hover); color: var(--foreground); }

.btn--destructive { background: var(--danger); color: var(--text-on-accent); }
.btn--destructive:hover:not(:disabled) { background: var(--danger-text); }

.btn--icon { width: 1.875rem; padding: 0; }
.btn--icon.btn--sm { width: 1.625rem; }

/* ============ kbd hint ============ */
kbd.key {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 1.125rem;
  height: 1.125rem;
  padding: 0 var(--sp-1);
  border: var(--border-width) solid var(--border-strong);
  border-radius: var(--radius-sm);
  background: var(--surface-sunken);
  color: var(--muted-foreground);
  font-size: var(--text-2xs);
  line-height: 1;
}

/* ============ form fields: input / select / textarea ============ */
.field { display: flex; flex-direction: column; gap: var(--sp-1-5); }
.field__label {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-1);
  font-size: var(--text-xs);
  font-weight: var(--font-medium);
  color: var(--foreground);
}
.field__label .required { color: var(--danger); }
.field__label .optional { font-weight: var(--font-regular); color: var(--faint-foreground); }
.field__hint { font-size: var(--text-2xs); color: var(--muted-foreground); }
.field__error {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-1);
  font-size: var(--text-2xs);
  font-weight: var(--font-medium);
  color: var(--danger-text);
}
.field__error svg { flex: none; }

.input, .select, .textarea {
  width: 100%;
  height: 1.875rem;
  padding: 0 var(--sp-2-5);
  border: var(--border-width) solid var(--input);
  border-radius: var(--radius);
  font: inherit;
  font-size: var(--text-sm);
  color: var(--foreground);
  background: var(--card);
  transition: border-color var(--duration-fast) var(--easing-standard);
}
.textarea { height: auto; min-height: 4.5rem; padding: var(--sp-2) var(--sp-2-5); resize: vertical; line-height: var(--leading-snug); }
.input::placeholder, .textarea::placeholder { color: var(--faint-foreground); }
.input:hover, .select:hover, .textarea:hover { border-color: var(--border-strong); }
.input:focus-visible, .select:focus-visible, .textarea:focus-visible {
  outline: 2px solid var(--ring);
  outline-offset: 0;
  border-color: transparent;
}
.input:disabled, .select:disabled, .textarea:disabled {
  background: var(--surface-sunken);
  color: var(--faint-foreground);
  cursor: not-allowed;
}
/* explicit valid/invalid — bound to field state, never color alone (icon lives in .field__error) */
.field--invalid .input, .field--invalid .select, .field--invalid .textarea { border-color: var(--danger-border); }
.field--invalid .input:focus-visible, .field--invalid .select:focus-visible, .field--invalid .textarea:focus-visible { outline-color: var(--danger); }
.field--valid .input, .field--valid .select { border-color: var(--success-border); }
.input[aria-invalid="true"] { border-color: var(--danger-border); }

.select { appearance: none; padding-right: var(--sp-8); }
.select-wrap { position: relative; }
.select-wrap svg {
  position: absolute;
  right: var(--sp-2-5);
  top: 50%;
  transform: translateY(-50%);
  color: var(--faint-foreground);
  pointer-events: none;
}

.search { position: relative; display: flex; align-items: center; }
.search svg { position: absolute; left: var(--sp-2); color: var(--faint-foreground); pointer-events: none; }
.search .input, .search input { padding-left: var(--sp-8); }

/* ============ checkbox / radio ============ */
.checkbox, .radio {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-2);
  font-size: var(--text-sm);
  color: var(--foreground);
  cursor: pointer;
}
.checkbox input, .radio input {
  appearance: none;
  width: 0.9375rem;
  height: 0.9375rem;
  flex: none;
  border: var(--border-width-strong) solid var(--border-strong);
  background: var(--card);
  display: inline-grid;
  place-content: center;
  cursor: pointer;
}
.checkbox input { border-radius: var(--radius-sm); }
.radio input { border-radius: var(--radius-full); }
.checkbox input::before {
  content: "";
  width: 0.5rem;
  height: 0.5rem;
  transform: scale(0);
  transition: transform var(--duration-fast) var(--easing-standard);
  background: var(--text-on-accent);
  clip-path: polygon(14% 44%, 0 63%, 39% 100%, 100% 21%, 82% 6%, 37% 66%);
}
.radio input::before {
  content: "";
  width: 0.4rem;
  height: 0.4rem;
  border-radius: var(--radius-full);
  transform: scale(0);
  transition: transform var(--duration-fast) var(--easing-standard);
  background: var(--text-on-accent);
}
.checkbox input:checked, .radio input:checked { background: var(--primary); border-color: var(--primary); }
.checkbox input:checked::before, .radio input:checked::before { transform: scale(1); }
.checkbox input:focus-visible, .radio input:focus-visible { outline: 2px solid var(--ring); outline-offset: 2px; }
.checkbox input:disabled, .radio input:disabled { opacity: 0.5; cursor: not-allowed; }

/* ============ switch (graft: 10-workflow-forms) ============ */
.switch { position: relative; display: inline-flex; align-items: center; width: 2.25rem; height: 1.25rem; flex: none; }
.switch input { position: absolute; opacity: 0; inset: 0; margin: 0; cursor: pointer; }
.switch-track {
  position: absolute;
  inset: 0;
  border-radius: var(--radius-full);
  background: var(--border-strong);
  transition: background var(--duration-base) var(--easing-standard);
}
.switch-thumb {
  position: absolute;
  top: 0.1875rem;
  left: 0.1875rem;
  width: 0.875rem;
  height: 0.875rem;
  border-radius: var(--radius-full);
  background: var(--card);
  box-shadow: var(--shadow-xs);
  transition: transform var(--duration-base) var(--easing-standard);
}
.switch input:checked ~ .switch-track { background: var(--primary); }
.switch input:checked ~ .switch-thumb { transform: translateX(1rem); }
.switch input:focus-visible ~ .switch-track { box-shadow: var(--shadow-focus-ring); }
.switch input:disabled ~ .switch-track { opacity: 0.5; }

/* ============ choice cards (graft: 10-workflow-forms) ============ */
.choice-card-group { display: grid; grid-template-columns: repeat(auto-fit, minmax(12rem, 1fr)); gap: var(--sp-2-5); }
.choice-card {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: var(--sp-1);
  padding: var(--sp-3);
  border: var(--border-width) solid var(--border);
  border-radius: var(--radius-lg);
  background: var(--card);
  cursor: pointer;
  transition: border-color var(--duration-fast) var(--easing-standard);
}
.choice-card input { position: absolute; opacity: 0; inset: 0; margin: 0; cursor: pointer; }
.choice-card:hover { border-color: var(--border-strong); }
.choice-card:has(input:checked) { border-color: var(--primary); box-shadow: 0 0 0 1px var(--primary); background: var(--primary-soft); }
.choice-card:has(input:focus-visible) { box-shadow: var(--shadow-focus-ring); }
.choice-card-title { font-size: var(--text-sm); font-weight: var(--font-medium); color: var(--foreground); }
.choice-card-desc { font-size: var(--text-2xs); color: var(--muted-foreground); }

/* ============ fieldset / form section (graft: 10-workflow-forms) ============ */
.form-section { display: flex; flex-direction: column; gap: var(--sp-4); padding: var(--sp-5) 0; border-bottom: var(--border-width) solid var(--border); }
.form-section:last-child { border-bottom: none; }
.form-section__head { display: flex; flex-direction: column; gap: var(--sp-1); }
.form-section__title { font-size: var(--text-md); font-weight: var(--font-semibold); letter-spacing: var(--tracking-snug); }
.form-section__desc { font-size: var(--text-sm); color: var(--muted-foreground); }
.form-row { display: grid; grid-template-columns: repeat(2, 1fr); gap: var(--sp-3); }
@media (max-width: 40rem) { .form-row { grid-template-columns: 1fr; } }
.form-footer { display: flex; align-items: center; justify-content: space-between; gap: var(--sp-4); padding-top: var(--sp-5); }
.form-footer__status { display: flex; align-items: center; gap: var(--sp-2); font-size: var(--text-2xs); color: var(--muted-foreground); }

/* ============ stepper / wizard nav (graft: 10; modifiers match content step statuses) ============
   step ids in content/status-registry.yaml: complete / current / needs-attention / locked.
   Never color alone — each state also carries an index glyph/number + label weight change. */
.stepper { display: flex; align-items: center; gap: var(--sp-2); list-style: none; }
.stepper__item { display: flex; align-items: center; gap: var(--sp-2); flex: 1; }
.stepper__item:last-child { flex: none; }
.stepper__connector { flex: 1; height: 1px; background: var(--border); }
.stepper__item--complete .stepper__connector { background: var(--success); }
.stepper__button {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-2);
  background: none;
  border: none;
  font: inherit;
  cursor: pointer;
  color: var(--muted-foreground);
}
.stepper__index {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.5rem;
  height: 1.5rem;
  flex: none;
  border-radius: var(--radius-full);
  border: var(--border-width) solid var(--border-strong);
  font-family: var(--font-mono);
  font-size: var(--text-2xs);
  font-weight: var(--font-medium);
  color: var(--muted-foreground);
  background: var(--card);
}
.stepper__index svg { width: 13px; height: 13px; }
.stepper__label { font-size: var(--text-xs); font-weight: var(--font-medium); white-space: nowrap; }
.stepper__item--current .stepper__index { border-color: var(--primary); color: var(--primary); background: var(--primary-soft); }
.stepper__item--current .stepper__label { color: var(--foreground); }
.stepper__item--complete .stepper__index { border-color: var(--success); background: var(--success); color: var(--text-on-accent); }
.stepper__item--complete .stepper__label { color: var(--muted-foreground); }
.stepper__item--needs-attention .stepper__index { border-color: var(--warning); background: var(--warning); color: var(--text-on-accent); }
.stepper__item--needs-attention .stepper__label { color: var(--warning-text); }
.stepper__item--locked .stepper__index { border-color: var(--border); background: var(--surface-sunken); color: var(--faint-foreground); }
.stepper__item--locked .stepper__label { color: var(--faint-foreground); }
.stepper__item--locked .stepper__button { cursor: not-allowed; }

/* ============ cards ============ */
.card {
  display: flex;
  flex-direction: column;
  min-width: 0;
  background: var(--card);
  color: var(--card-foreground);
  border: var(--border-width) solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-xs);
}
.card-header { padding: var(--sp-4) var(--sp-4) 0; }
.card-title { font-size: var(--text-base); font-weight: var(--font-semibold); letter-spacing: var(--tracking-snug); }
.card-desc { margin-top: 2px; font-size: var(--text-xs); color: var(--muted-foreground); }
.card-body { padding: var(--sp-4); }
.card-footer {
  padding: var(--sp-3) var(--sp-4);
  border-top: var(--border-width) solid var(--border);
  display: flex;
  align-items: center;
  gap: var(--sp-3);
}

/* ============ tables ============ */
.table-scroll { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; font-size: var(--text-sm); }
thead th {
  padding: var(--sp-1-5) var(--sp-4);
  border-bottom: var(--border-width) solid var(--border);
  background: var(--surface-sunken);
  font-size: var(--text-2xs);
  font-weight: var(--font-semibold);
  text-transform: uppercase;
  letter-spacing: var(--tracking-wide);
  color: var(--muted-foreground);
  text-align: left;
  white-space: nowrap;
}
tbody td {
  padding: var(--sp-1-5) var(--sp-4);
  border-bottom: var(--border-width) solid var(--border);
  color: var(--foreground);
  white-space: nowrap;
}
tbody tr:last-child td { border-bottom: none; }
tbody tr:hover td { background: var(--hover); }
tbody tr[aria-selected="true"] td { background: var(--selected); }
th.num, td.num { text-align: right; }
td.num { font-variant-numeric: tabular-nums; }
th[aria-sort] { cursor: pointer; }
th[aria-sort] .sort-icon { margin-left: var(--sp-1); vertical-align: -2px; color: var(--faint-foreground); }
th[aria-sort="ascending"] .sort-icon, th[aria-sort="descending"] .sort-icon { color: var(--foreground); }

/* ============ tabs ============ */
.tabs { display: flex; flex-direction: column; }
.tabs__list {
  display: flex;
  align-items: center;
  gap: var(--sp-1);
  border-bottom: var(--border-width) solid var(--border);
}
.tabs__tab {
  appearance: none;
  background: transparent;
  border: none;
  border-bottom: 2px solid transparent;
  padding: var(--sp-2) var(--sp-2);
  margin-bottom: -1px;
  font: inherit;
  font-size: var(--text-sm);
  font-weight: var(--font-medium);
  color: var(--muted-foreground);
  cursor: pointer;
}
.tabs__tab:hover { color: var(--foreground); }
.tabs__tab[aria-selected="true"] { color: var(--foreground); border-bottom-color: var(--primary); }
.tabs__panel { padding-top: var(--sp-4); }
.tabs__panel[hidden] { display: none; }

/* ============ tag / badge / status ============ */
.badge {
  display: inline-flex;
  align-items: center;
  height: 1.125rem;
  padding: 0 var(--sp-1-5);
  border-radius: var(--radius-sm);
  font-size: var(--text-2xs);
  font-weight: var(--font-medium);
  border: var(--border-width) solid transparent;
  white-space: nowrap;
  vertical-align: 1px;
}
.badge--red   { background: var(--danger-bg); color: var(--danger-text); border-color: var(--danger-border); }
.badge--amber { background: var(--warning-bg); color: var(--warning-text); border-color: var(--warning-border); }
.badge--green { background: var(--success-bg); color: var(--success-text); border-color: var(--success-border); }
.badge--blue  { background: var(--info-bg); color: var(--info-text); border-color: var(--info-border); }
.badge--gray  { background: var(--neutral-bg); color: var(--neutral-text); border-color: var(--neutral-border); }

/* severity indicator = icon + label, never color alone.
   Registry severity -> modifier: critical→danger, warning→warning, ok→success,
   pending→info, categorical→neutral (see content/status-registry.yaml). */
.status-ind { display: inline-flex; align-items: center; gap: var(--sp-1-5); white-space: nowrap; font-size: var(--text-sm); }
.status-ind svg { flex: none; }
.status-ind--danger  { color: var(--danger-text); }
.status-ind--warning { color: var(--warning-text); }
.status-ind--success { color: var(--success-text); }
.status-ind--info    { color: var(--info-text); }
.status-ind--neutral { color: var(--muted-foreground); }

/* ============ modal / dialog ============ */
.dialog-overlay {
  position: fixed;
  inset: 0;
  background: var(--overlay);
  backdrop-filter: blur(2px);
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding: 12vh var(--sp-4) var(--sp-4);
  z-index: 100;
}
.dialog {
  width: 100%;
  max-width: 28rem;
  max-height: calc(100vh - 4rem);
  overflow-y: auto;
  background: var(--popover);
  color: var(--popover-foreground);
  border: var(--border-width) solid var(--border-strong);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-overlay);
}
.dialog-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: var(--sp-3);
  padding: var(--sp-4) var(--sp-4) var(--sp-3);
  border-bottom: var(--border-width) solid var(--border);
}
.dialog-title { font-size: var(--text-md); font-weight: var(--font-semibold); }
.dialog-desc { margin-top: var(--sp-1); font-size: var(--text-sm); color: var(--muted-foreground); }
.dialog-close {
  flex: none;
  width: 1.75rem;
  height: 1.75rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: none;
  border-radius: var(--radius-sm);
  background: transparent;
  color: var(--muted-foreground);
  cursor: pointer;
}
.dialog-close:hover { background: var(--hover); color: var(--foreground); }
.dialog-body { padding: var(--sp-4); }
.dialog-footer {
  display: flex;
  justify-content: flex-end;
  gap: var(--sp-2);
  padding: var(--sp-3) var(--sp-4);
  border-top: var(--border-width) solid var(--border);
}

/* ============ command palette (cmdk — console signature) ============
   Vanilla-consumable: active row is covered by :hover; the [data-active] hook is additive
   progressive enhancement written by our own mock.js, not a Radix runtime attribute. */
.cmdk-trigger {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-2);
  height: 1.875rem;
  padding: 0 var(--sp-2);
  border: var(--border-width) solid var(--border);
  border-radius: var(--radius);
  background: var(--surface-sunken);
  color: var(--faint-foreground);
  font-size: var(--text-xs);
  cursor: pointer;
  min-width: 12rem;
}
.cmdk-trigger:hover { border-color: var(--border-strong); color: var(--muted-foreground); }
.cmdk-trigger svg { flex: none; }
.cmdk-trigger .hint-text { flex: 1; text-align: left; }

.cmdk {
  width: 100%;
  max-width: 34rem;
  background: var(--popover);
  border: var(--border-width) solid var(--border-strong);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-overlay);
  overflow: hidden;
}
.cmdk-input-row {
  display: flex;
  align-items: center;
  gap: var(--sp-2);
  padding: var(--sp-3) var(--sp-4);
  border-bottom: var(--border-width) solid var(--border);
}
.cmdk-input-row svg { flex: none; color: var(--faint-foreground); }
.cmdk-input {
  flex: 1;
  border: none;
  background: none;
  outline: none;
  font: inherit;
  font-family: var(--font-mono);
  font-size: var(--text-base);
  color: var(--foreground);
}
.cmdk-input::placeholder { color: var(--faint-foreground); }
.cmdk-list { max-height: 20rem; overflow-y: auto; padding: var(--sp-1-5); }
.cmdk-group-label {
  padding: var(--sp-1-5) var(--sp-2-5) var(--sp-1);
  font-size: var(--text-2xs);
  font-weight: var(--font-medium);
  text-transform: uppercase;
  letter-spacing: var(--tracking-wide);
  color: var(--faint-foreground);
}
.cmdk-item {
  display: flex;
  align-items: center;
  gap: var(--sp-2-5);
  padding: var(--sp-2) var(--sp-2-5);
  border-radius: var(--radius);
  font-size: var(--text-sm);
  color: var(--foreground);
  cursor: pointer;
}
.cmdk-item svg { flex: none; color: var(--muted-foreground); }
.cmdk-item[data-active="true"], .cmdk-item:hover { background: var(--selected); }
.cmdk-item .cmdk-item-meta { margin-left: auto; font-family: var(--font-mono); font-size: var(--text-2xs); color: var(--faint-foreground); }
.cmdk-empty { padding: var(--sp-6) var(--sp-4); text-align: center; color: var(--muted-foreground); font-size: var(--text-sm); }

/* ============ tooltip ============ */
.tooltip-wrap { position: relative; display: inline-flex; }
.tooltip {
  position: absolute;
  bottom: calc(100% + var(--sp-2));
  left: 50%;
  transform: translateX(-50%) translateY(2px);
  padding: var(--sp-1) var(--sp-2);
  border-radius: var(--radius-sm);
  background: var(--tooltip-bg);
  color: var(--tooltip-text);
  font-size: var(--text-2xs);
  white-space: nowrap;
  box-shadow: var(--shadow-sm);
  opacity: 0;
  pointer-events: none;
  transition: opacity var(--duration-fast) var(--easing-standard),
    transform var(--duration-fast) var(--easing-standard);
  z-index: 60;
}
.tooltip-wrap:hover .tooltip,
.tooltip-wrap:focus-within .tooltip { opacity: 1; transform: translateX(-50%) translateY(0); }

/* ============ nav / shell ============ */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  display: flex;
  align-items: center;
  gap: var(--sp-5);
  border-bottom: var(--border-width) solid var(--border);
  background: var(--card);
}
.site-header__inner {
  display: flex;
  align-items: center;
  gap: var(--sp-5);
  width: 100%;
  max-width: 92rem;
  margin-inline: auto;
  padding: 0 var(--sp-4);
  height: 2.75rem;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-1-5);
  font-weight: var(--font-semibold);
  font-size: var(--text-md);
  letter-spacing: var(--tracking-snug);
  color: var(--foreground);
  text-decoration: none;
  white-space: nowrap;
}
.site-nav { display: flex; align-items: center; gap: var(--sp-0-5); flex: 1; }
.site-nav a {
  padding: var(--sp-1-5) var(--sp-2-5);
  border-radius: var(--radius);
  font-size: var(--text-sm);
  color: var(--muted-foreground);
  text-decoration: none;
}
.site-nav a:hover { color: var(--foreground); background: var(--hover); }
.site-nav a[aria-current="page"] { color: var(--foreground); background: var(--hover); font-weight: var(--font-medium); }
.site-header__aside { margin-left: auto; display: flex; align-items: center; gap: var(--sp-2); }
.signout {
  font-size: var(--text-sm);
  color: var(--muted-foreground);
  text-decoration: none;
  padding: var(--sp-1-5) var(--sp-2-5);
  border-radius: var(--radius);
}
.signout:hover { color: var(--foreground); background: var(--hover); }

/* ============ pagination ============ */
.pagination {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--sp-3);
  padding: var(--sp-2) var(--sp-4);
  border-top: var(--border-width) solid var(--border);
  font-size: var(--text-xs);
  color: var(--muted-foreground);
}
.pagination__controls { display: flex; align-items: center; gap: var(--sp-1-5); }
.page-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.5rem;
  height: 1.5rem;
  border: var(--border-width) solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--card);
  color: var(--foreground);
  cursor: pointer;
}
.page-btn:hover:not(:disabled) { background: var(--hover); }
.page-btn:disabled { color: var(--faint-foreground); cursor: default; }
.page-btn[aria-current="true"] { background: var(--primary); color: var(--primary-foreground); border-color: var(--primary); }
