:root {
  /* Light & dark raw tokens */
  --bg-light: #fafaf9;
  --bg-dark: #111110;
  --surface-light: #ffffff;
  --surface-dark: #191918;
  --surface-muted-light: #f3f2ef;
  --surface-muted-dark: #222220;
  --border-light: #e5e3dd;
  --border-dark: #2d2d2a;
  --text-light: #161614;
  --text-dark: #ecece9;
  --muted-light: #5c5b56;
  --muted-dark: #9c9a92;
  --accent-light: #ce2029;
  --accent-dark: #f05252;
  --accent-soft-light: #fdf1f1;
  --accent-soft-dark: #2d1617;
  --good-light: #157347;
  --good-dark: #4ade80;
  --good-soft-light: #ebf9f1;
  --good-soft-dark: #12281c;
  --warn-light: #a15c07;
  --warn-dark: #fbbf24;
  --warn-soft-light: #fef6e7;
  --warn-soft-dark: #2b210e;
  --blue-light: #1d4ed8;
  --blue-dark: #60a5fa;
  --blue-soft-light: #eff6ff;
  --blue-soft-dark: #14223b;
  --scroll-track-light: #efede8;
  --scroll-track-dark: #1a1a18;
  --scroll-thumb-light: #b8b5ad;
  --scroll-thumb-dark: #4b4a45;

  /* Default (light) */
  --bg: var(--bg-light);
  --surface: var(--surface-light);
  --surface-muted: var(--surface-muted-light);
  --border: var(--border-light);
  --text: var(--text-light);
  --muted: var(--muted-light);
  --accent: var(--accent-light);
  --accent-soft: var(--accent-soft-light);
  --good: var(--good-light);
  --good-soft: var(--good-soft-light);
  --warn: var(--warn-light);
  --warn-soft: var(--warn-soft-light);
  --blue: var(--blue-light);
  --blue-soft: var(--blue-soft-light);
  --scroll-track: var(--scroll-track-light);
  --scroll-thumb: var(--scroll-thumb-light);

  /* Fallback for browsers without light-dark() */
  @media (prefers-color-scheme: dark) {
    --bg: var(--bg-dark);
    --surface: var(--surface-dark);
    --surface-muted: var(--surface-muted-dark);
    --border: var(--border-dark);
    --text: var(--text-dark);
    --muted: var(--muted-dark);
    --accent: var(--accent-dark);
    --accent-soft: var(--accent-soft-dark);
    --good: var(--good-dark);
    --good-soft: var(--good-soft-dark);
    --warn: var(--warn-dark);
    --warn-soft: var(--warn-soft-dark);
    --blue: var(--blue-dark);
    --blue-soft: var(--blue-soft-dark);
    --scroll-track: var(--scroll-track-dark);
    --scroll-thumb: var(--scroll-thumb-dark);
  }

  /* Modern light-dark() progressive enhancement */
  @supports (color: light-dark(white, black)) {
    --bg: light-dark(var(--bg-light), var(--bg-dark));
    --surface: light-dark(var(--surface-light), var(--surface-dark));
    --surface-muted: light-dark(var(--surface-muted-light), var(--surface-muted-dark));
    --border: light-dark(var(--border-light), var(--border-dark));
    --text: light-dark(var(--text-light), var(--text-dark));
    --muted: light-dark(var(--muted-light), var(--muted-dark));
    --accent: light-dark(var(--accent-light), var(--accent-dark));
    --accent-soft: light-dark(var(--accent-soft-light), var(--accent-soft-dark));
    --good: light-dark(var(--good-light), var(--good-dark));
    --good-soft: light-dark(var(--good-soft-light), var(--good-soft-dark));
    --warn: light-dark(var(--warn-light), var(--warn-dark));
    --warn-soft: light-dark(var(--warn-soft-light), var(--warn-soft-dark));
    --blue: light-dark(var(--blue-light), var(--blue-dark));
    --blue-soft: light-dark(var(--blue-soft-light), var(--blue-soft-dark));
    --scroll-track: light-dark(var(--scroll-track-light), var(--scroll-track-dark));
    --scroll-thumb: light-dark(var(--scroll-thumb-light), var(--scroll-thumb-dark));
  }

  color-scheme: light dark;
  accent-color: var(--accent);
  scrollbar-color: var(--scroll-thumb) var(--scroll-track);

  --font-sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --font-serif: "Iowan Old Style", "Palatino Linotype", Palatino, Georgia, "Times New Roman", serif;
  --font-mono: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  --radius: 8px;
}

@supports not (scrollbar-color: auto) {
  * {
    scrollbar-width: auto;
  }
  ::-webkit-scrollbar {
    width: 10px;
    height: 10px;
  }
  ::-webkit-scrollbar-thumb {
    background: var(--scroll-thumb);
  }
  ::-webkit-scrollbar-track {
    background: var(--scroll-track);
  }
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: var(--font-sans);
  font-size: 0.9375rem;
  line-height: 1.5;
  background: var(--bg);
  color: var(--text);
  -webkit-font-smoothing: antialiased;
}

[hidden] {
  display: none !important;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}

.container {
  max-width: 1220px;
  margin-inline: auto;
  padding-inline: 1rem;
}

/* Header */
.site-header {
  position: sticky;
  inset-block-start: 0;
  z-index: 20;
  background: var(--surface);
  border-block-end: 1px solid var(--border);
}

.header-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  padding-block: 0.65rem;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  text-decoration: none;
  color: var(--text);
}

.brand-icon {
  display: block;
  flex-shrink: 0;
}

.brand-text {
  display: flex;
  align-items: baseline;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.brand-name {
  font-weight: 700;
  font-size: 1rem;
  letter-spacing: -0.015em;
}

.brand-sub {
  font-size: 0.8125rem;
  color: var(--muted);
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  flex-wrap: wrap;
}

.updated-stamp {
  font-size: 0.78rem;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}

/* Buttons & inputs */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.35rem;
  min-block-size: 32px;
  padding: 0.3rem 0.7rem;
  border-radius: 6px;
  font: inherit;
  font-size: 0.84rem;
  font-weight: 500;
  text-decoration: none;
  cursor: pointer;
  border: 1px solid transparent;
  background: transparent;
  color: var(--text);
}

.btn-subtle {
  background: var(--surface);
  border-color: var(--border);
}

.btn-subtle:hover {
  background: var(--surface-muted);
}

.btn-primary {
  background: var(--accent);
  color: #ffffff;
}

.btn-primary:hover {
  filter: brightness(0.92);
}

.btn-link {
  color: var(--muted);
  padding-inline: 0.35rem;
}

.btn-link:hover {
  color: var(--text);
}

:is(a, button, input, select, summary, [tabindex]):focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

/* Main */
.main-content {
  padding-block: 1.25rem 3rem;
}

/* Live activity panel (only shown when active) */
.live-section {
  background: var(--surface);
  border: 1px solid var(--border);
  border-inline-start: 3px solid var(--good);
  border-radius: var(--radius);
  padding: 0.9rem 1rem;
  margin-block-end: 1.25rem;
}

.live-header {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem 1rem;
  margin-block-end: 0.75rem;
}

.live-title-wrap {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  flex-wrap: wrap;
}

.live-dot {
  width: 9px;
  height: 9px;
  border-radius: 999px;
  background: var(--good);
  box-shadow: 0 0 0 0 color-mix(in srgb, var(--good) 55%, transparent);
  animation: pulse-dot 2s infinite;
}

@keyframes pulse-dot {
  0% {
    box-shadow: 0 0 0 0 color-mix(in srgb, var(--good) 55%, transparent);
  }
  70% {
    box-shadow: 0 0 0 7px transparent;
  }
  100% {
    box-shadow: 0 0 0 0 transparent;
  }
}

@media (prefers-reduced-motion: reduce) {
  .live-dot {
    animation: none;
  }
}

.live-title {
  margin: 0;
  font-size: 0.95rem;
  font-weight: 700;
}

.live-summary {
  font-size: 0.84rem;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}

.live-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  font-size: 0.78rem;
  color: var(--muted);
  font-family: var(--font-mono);
}

.live-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 0.75rem;
}

.live-job {
  background: var(--surface-muted);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 0.7rem 0.8rem;
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
}

.live-job-top {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 0.5rem;
}

.live-job-id {
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: 0.88rem;
}

.live-job-speed {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: var(--good);
  font-weight: 600;
}

.live-job-sub {
  font-size: 0.8rem;
  color: var(--muted);
}

.progress-track {
  height: 6px;
  border-radius: 999px;
  background: var(--border);
  overflow: hidden;
}

.progress-fill {
  height: 100%;
  background: var(--good);
  border-radius: 999px;
  transition: width 0.4s ease;
}

.live-job-counts {
  display: flex;
  justify-content: space-between;
  gap: 0.5rem;
  font-size: 0.78rem;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}

.live-verse-sample {
  font-family: var(--font-serif);
  font-size: 0.84rem;
  line-height: 1.4;
  color: var(--text);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 5px;
  padding: 0.4rem 0.55rem;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.live-verse-ref {
  font-family: var(--font-mono);
  font-size: 0.74rem;
  color: var(--muted);
  margin-inline-end: 0.35rem;
}

/* Catalog intro & KPIs */
.intro-row {
  margin-block-end: 1rem;
}

.intro-row h1 {
  margin: 0 0 0.25rem;
  font-size: 1.5rem;
  letter-spacing: -0.02em;
}

.intro-copy {
  margin: 0;
  color: var(--muted);
  max-width: 72ch;
}

.kpi-strip {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(175px, 1fr));
  gap: 0.7rem;
  margin-block-end: 1.1rem;
}

.kpi-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 0.75rem 0.9rem;
}

.kpi-label {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--muted);
  margin-block-end: 0.2rem;
}

.kpi-value {
  font-size: 1.35rem;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  line-height: 1.2;
}

.kpi-sub {
  font-size: 0.78rem;
  color: var(--muted);
  margin-block-start: 0.2rem;
  font-variant-numeric: tabular-nums;
}

/* Filter toolbar */
.toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.6rem;
  margin-block-end: 0.8rem;
}

.field {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.84rem;
}

.field-label {
  color: var(--muted);
  white-space: nowrap;
}

.field-search {
  flex: 1 1 240px;
}

input[type="search"],
select {
  font: inherit;
  font-size: 0.86rem;
  padding: 0.36rem 0.6rem;
  min-block-size: 34px;
  border-radius: 6px;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text);
}

input[type="search"] {
  inline-size: 100%;
}

/* Responsive + Sortable Table (per modern-web-guidance) */
.table-wrapper {
  overflow: auto;
  max-inline-size: 100%;
  max-block-size: min(74vh, 820px);
  container-type: inline-size;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}

.bibles-table {
  width: 100%;
  min-inline-size: 820px;
  border-collapse: separate;
  border-spacing: 0;
  font-size: 0.85rem;
  font-variant-numeric: tabular-nums;
  --label-2: "Engine";
  --label-3: "Style & Voice";
  --label-4: "Verses";
  --label-5: "Words/v";
  --label-6: "Nearest Real";
  --label-7: "Fidelity / Repair";
  --label-8: "Speed";
  --label-9: "Inspect";
}

.table-caption {
  text-align: start;
  padding: 0.6rem 0.85rem;
  font-size: 0.8rem;
  color: var(--muted);
  border-block-end: 1px solid var(--border);
  background: var(--surface);
}

.bibles-table thead {
  position: sticky;
  inset-block-start: 0;
  z-index: 2;
  background: var(--surface-muted);
}

.bibles-table thead th {
  text-align: start;
  font-weight: 600;
  font-size: 0.78rem;
  color: var(--muted);
  border-block-end: 1px solid var(--border);
  white-space: nowrap;
  padding: 0.55rem 0.65rem;
}

.bibles-table thead th:has(> button) {
  padding: 0;
}

.bibles-table thead th > button {
  display: flex;
  align-items: center;
  gap: 0.3rem;
  inline-size: 100%;
  min-block-size: 36px;
  padding: 0.55rem 0.65rem;
  border: 0;
  background: transparent;
  color: inherit;
  font: inherit;
  font-weight: 600;
  text-align: start;
  cursor: pointer;
}

.bibles-table thead th > button:hover {
  color: var(--text);
}

.sort-icon::after {
  content: "↕";
  opacity: 0.35;
  font-size: 0.75rem;
}

th[aria-sort="ascending"] .sort-icon::after {
  content: "↑";
  opacity: 1;
  color: var(--accent);
}

th[aria-sort="descending"] .sort-icon::after {
  content: "↓";
  opacity: 1;
  color: var(--accent);
}

.bibles-table tbody tr {
  view-transition-name: match-element;
}

@media (prefers-reduced-motion: reduce) {
  ::view-transition-group(*),
  ::view-transition-old(*),
  ::view-transition-new(*) {
    animation: none;
  }
}

.bibles-table tbody th,
.bibles-table tbody td {
  padding: 0.58rem 0.65rem;
  border-block-end: 1px solid var(--border);
  vertical-align: middle;
}

.bibles-table tbody tr:last-child th,
.bibles-table tbody tr:last-child td {
  border-block-end: 0;
}

.bibles-table tbody th {
  position: sticky;
  inset-inline-start: 0;
  z-index: 1;
  background: var(--surface);
  text-align: start;
  font-weight: 600;
  white-space: nowrap;
}

.bibles-table tbody tr:hover th,
.bibles-table tbody tr:hover td {
  background: var(--surface-muted);
}

.bible-id-link {
  font-family: var(--font-mono);
  font-size: 0.84rem;
  font-weight: 600;
  color: var(--text);
  text-decoration: none;
}

.bible-id-link:hover {
  color: var(--accent);
  text-decoration: underline;
}

.subline {
  display: block;
  font-size: 0.76rem;
  color: var(--muted);
  font-weight: 400;
}

.badge {
  display: inline-block;
  padding: 0.1rem 0.42rem;
  border-radius: 4px;
  font-size: 0.73rem;
  font-weight: 600;
  line-height: 1.4;
  white-space: nowrap;
}

.badge-frontier {
  background: var(--blue-soft);
  color: var(--blue);
}

.badge-local {
  background: var(--surface-muted);
  color: var(--text);
  border: 1px solid var(--border);
}

.badge-good {
  background: var(--good-soft);
  color: var(--good);
}

.badge-warn {
  background: var(--warn-soft);
  color: var(--warn);
}

.badge-live {
  background: var(--good-soft);
  color: var(--good);
}

.badge-queued {
  background: var(--surface-muted);
  color: var(--muted);
}

.loading-cell {
  text-align: center;
  padding: 2rem 1rem !important;
  color: var(--muted);
}

@container (width < 700px) {
  .bibles-table {
    min-inline-size: 0;
  }
  .bibles-table,
  .bibles-table thead,
  .bibles-table tbody,
  .bibles-table tr,
  .bibles-table th,
  .bibles-table td {
    display: block;
  }
  .bibles-table thead {
    display: none;
  }
  .bibles-table tbody tr {
    margin: 0.7rem;
    border: 1px solid var(--border);
    border-radius: 6px;
    overflow: hidden;
  }
  .bibles-table tbody th {
    position: sticky;
    inset-block-start: 0;
    z-index: 2;
    background: var(--surface-muted);
    border-block-end: 1px solid var(--border);
  }
  .bibles-table tbody td {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    gap: 0.75rem;
    text-align: end;
  }
  .bibles-table tbody td::before {
    font-size: 0.76rem;
    color: var(--muted);
    font-weight: 600;
    text-align: start;
  }
  .bibles-table tbody td:nth-child(2)::before { content: var(--label-2); }
  .bibles-table tbody td:nth-child(3)::before { content: var(--label-3); }
  .bibles-table tbody td:nth-child(4)::before { content: var(--label-4); }
  .bibles-table tbody td:nth-child(5)::before { content: var(--label-5); }
  .bibles-table tbody td:nth-child(6)::before { content: var(--label-6); }
  .bibles-table tbody td:nth-child(7)::before { content: var(--label-7); }
  .bibles-table tbody td:nth-child(8)::before { content: var(--label-8); }
  .bibles-table tbody td:nth-child(9)::before { content: var(--label-9); }
}

/* Inspector view */
.inspector-topbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  margin-block-end: 0.9rem;
}

.inspector-pickers {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.6rem;
}

.inspector-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 0.9rem 1rem;
  margin-block-end: 0.75rem;
}

.inspector-head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.5rem 1rem;
  margin-block-end: 0.55rem;
}

.inspector-title {
  margin: 0;
  font-family: var(--font-mono);
  font-size: 1.2rem;
}

.inspector-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}

.inspector-desc {
  margin: 0 0 0.75rem;
  color: var(--muted);
  font-size: 0.88rem;
}

.stat-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 0.55rem;
}

.stat-box {
  background: var(--surface-muted);
  border-radius: 6px;
  padding: 0.5rem 0.65rem;
}

.stat-box-label {
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  color: var(--muted);
}

.stat-box-val {
  font-size: 0.96rem;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}

.stat-box-note {
  font-size: 0.74rem;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}

.dna-details {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 0.6rem 0.9rem;
  margin-block-end: 0.9rem;
}

.dna-details > summary {
  cursor: pointer;
  font-weight: 600;
  font-size: 0.86rem;
  color: var(--text);
}

.dna-body {
  padding-block-start: 0.8rem;
  display: grid;
  gap: 0.9rem;
}

.dna-cols {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 0.9rem;
}

.dna-block h3 {
  margin: 0 0 0.4rem;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--muted);
}

.dna-block p,
.dna-block li {
  font-size: 0.84rem;
  margin: 0 0 0.35rem;
}

.dna-block ul {
  margin: 0;
  padding-inline-start: 1.15rem;
}

.lexicon-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
}

.lex-pill {
  font-size: 0.77rem;
  background: var(--surface-muted);
  border: 1px solid var(--border);
  border-radius: 5px;
  padding: 0.16rem 0.48rem;
}

.lex-pill em {
  font-style: normal;
  color: var(--muted);
  font-family: var(--font-mono);
  font-size: 0.72rem;
}

.judge-list {
  display: grid;
  gap: 0.45rem;
}

.judge-item {
  background: var(--surface-muted);
  border-radius: 6px;
  padding: 0.5rem 0.65rem;
  font-size: 0.82rem;
}

/* Reader controls */
.reader-controls {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.65rem;
  margin-block-end: 0.55rem;
}

.nav-group {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.45rem;
}

.reader-search {
  max-inline-size: 380px;
}

.sample-chips {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.35rem;
  margin-block-end: 0.85rem;
}

.chips-label {
  font-size: 0.78rem;
  color: var(--muted);
  margin-inline-end: 0.15rem;
}

.chip {
  font: inherit;
  font-size: 0.78rem;
  padding: 0.2rem 0.55rem;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text);
  cursor: pointer;
}

.chip:hover {
  background: var(--surface-muted);
  border-color: var(--muted);
}

/* Scripture reader */
.reader-pane {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.15rem 1.25rem;
}

.chapter-heading {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.5rem;
  margin-block-end: 0.9rem;
  padding-block-end: 0.55rem;
  border-block-end: 1px solid var(--border);
}

.chapter-heading h2 {
  margin: 0;
  font-size: 1.15rem;
}

.chapter-sub {
  font-size: 0.8rem;
  color: var(--muted);
  font-family: var(--font-mono);
}

.verses-single {
  max-width: 72ch;
  font-family: var(--font-serif);
  font-size: 1.07rem;
  line-height: 1.72;
}

.verse-row-single {
  display: grid;
  grid-template-columns: 2.3rem 1fr;
  gap: 0.55rem;
  padding-block: 0.28rem;
  border-radius: 4px;
}

.verse-row-single:hover {
  background: var(--surface-muted);
}

.vnum {
  font-family: var(--font-mono);
  font-size: 0.76rem;
  color: var(--muted);
  text-align: end;
  padding-block-start: 0.24rem;
  user-select: none;
}

.vref-full {
  font-family: var(--font-mono);
  font-size: 0.76rem;
  color: var(--accent);
  white-space: nowrap;
  padding-block-start: 0.2rem;
}

.verses-compare {
  display: grid;
  gap: 0;
}

.compare-header {
  display: grid;
  grid-template-columns: 3.4rem 1fr 1fr;
  gap: 0.9rem;
  padding: 0.45rem 0.5rem;
  border-block-end: 2px solid var(--border);
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--muted);
  font-family: var(--font-mono);
}

.verse-row-compare {
  display: grid;
  grid-template-columns: 3.4rem 1fr 1fr;
  gap: 0.9rem;
  padding: 0.55rem 0.5rem;
  border-block-end: 1px solid var(--border);
  font-family: var(--font-serif);
  font-size: 1rem;
  line-height: 1.62;
}

.verse-row-compare:last-child {
  border-block-end: 0;
}

.verse-row-compare:hover {
  background: var(--surface-muted);
}

.verse-empty {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: var(--warn);
  font-style: italic;
}

.search-results-list {
  display: grid;
  gap: 0.55rem;
}

.search-hit {
  padding: 0.55rem 0.7rem;
  border: 1px solid var(--border);
  border-radius: 6px;
  cursor: pointer;
}

.search-hit:hover {
  background: var(--surface-muted);
}

.search-hit-text {
  font-family: var(--font-serif);
  font-size: 0.98rem;
  line-height: 1.5;
  margin-block-start: 0.2rem;
}

.search-hit mark {
  background: var(--warn-soft);
  color: var(--text);
  padding: 0 2px;
  border-radius: 2px;
}

@media (max-width: 720px) {
  .compare-header {
    display: none;
  }
  .verse-row-compare {
    grid-template-columns: 1fr;
    gap: 0.35rem;
  }
  .verse-row-compare .vnum {
    text-align: start;
    font-weight: 700;
  }
  .compare-col-label {
    display: block;
    font-family: var(--font-mono);
    font-size: 0.72rem;
    color: var(--muted);
  }
}

@media (min-width: 721px) {
  .compare-col-label {
    display: none;
  }
}

/* Footer */
.site-footer {
  border-block-start: 1px solid var(--border);
  padding-block: 1rem;
  color: var(--muted);
  font-size: 0.8rem;
}

.footer-inner {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 0.5rem;
}
