/* riskadjustmentsoftware.com — reference-work stylesheet. See DESIGN.md. */

:root {
  --paper: oklch(0.972 0.004 260);
  --paper-2: oklch(0.945 0.006 260);
  --ink: oklch(0.24 0.02 20);
  --ink-2: oklch(0.45 0.02 20);
  --ink-3: oklch(0.58 0.015 20);
  --claret: oklch(0.42 0.14 20);
  --claret-deep: oklch(0.33 0.12 20);
  --claret-wash: oklch(0.94 0.018 20);
  --paper-lite: oklch(0.985 0.003 260);
  --rule: oklch(0.85 0.01 20);
  --rule-strong: oklch(0.62 0.04 20);
  --good: oklch(0.5 0.1 150);
  --serif: 'Besley', 'Georgia', serif;
  --sans: 'Libre Franklin', 'Helvetica Neue', Arial, sans-serif;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-weight: 350;
  font-size: 1.0rem;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

a { color: var(--claret); text-decoration: underline; text-decoration-color: oklch(0.42 0.14 20 / 0.35); text-underline-offset: 2px; }
a:hover { text-decoration-color: var(--claret); }
a:focus-visible, button:focus-visible { outline: 2px solid var(--claret); outline-offset: 3px; border-radius: 2px; }
/* Claret focus rings vanish on the claret bands; use paper there. */
.masthead a:focus-visible, footer a:focus-visible { outline-color: oklch(0.93 0.02 20); }

.skip-link { position: absolute; left: -999px; top: 12px; z-index: 100; padding: 10px 14px; background: var(--paper); color: var(--ink); border: 1px solid var(--rule-strong); }
.skip-link:focus { left: 12px; }

.wrap { max-width: 1120px; margin: 0 auto; padding: 0 clamp(20px, 4vw, 48px); }
.prose { max-width: 68ch; }
.prose > * + * { margin-top: 1em; }
h2 + .prose { margin-top: 14px; }

/* ---------- Masthead ---------- */
.masthead { background: var(--claret-deep); color: oklch(0.95 0.01 20); }
.masthead .wrap { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; padding-top: 14px; padding-bottom: 14px; flex-wrap: wrap; }
.wordmark { font-family: var(--serif); font-weight: 700; font-size: 1.05rem; letter-spacing: 0.01em; color: inherit; text-decoration: none; white-space: nowrap; }
@media (max-width: 440px) { .wordmark { white-space: normal; font-size: 1rem; line-height: 1.25; } }
.wordmark:hover { text-decoration: underline; text-decoration-color: oklch(0.95 0.01 20 / 0.5); }
.masthead-nav { display: flex; gap: clamp(14px, 2.5vw, 28px); flex-wrap: wrap; }
.masthead-nav a { color: oklch(0.92 0.015 20); text-decoration: none; font-size: 0.84rem; font-weight: 450; }
.masthead-nav a:hover, .masthead-nav a[aria-current="page"] { text-decoration: underline; text-underline-offset: 3px; }

.dateline { border-bottom: 1px solid var(--rule); }
.dateline .wrap { display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; padding-top: 10px; padding-bottom: 10px; font-size: 0.78rem; color: var(--ink-3); font-weight: 450; letter-spacing: 0.02em; }
.dateline strong { color: var(--ink-2); font-weight: 600; }

/* ---------- Headings & labels ---------- */
h1, h2, h3 { font-family: var(--serif); font-weight: 600; line-height: 1.15; letter-spacing: -0.01em; text-wrap: balance; }
h1 { font-size: clamp(2.1rem, 5.2vw, 3.4rem); }
h2 { font-size: clamp(1.45rem, 3vw, 1.95rem); }
h3 { font-size: clamp(1.1rem, 2vw, 1.3rem); line-height: 1.25; }
.eyebrow { font-size: 0.72rem; font-weight: 600; letter-spacing: 0.12em; text-transform: uppercase; color: var(--claret); margin-bottom: 12px; }
.lede { font-size: clamp(1.05rem, 1.8vw, 1.22rem); line-height: 1.6; color: var(--ink-2); font-weight: 350; }

/* Inside a bordered .section the section rule closes the band, so the list's own
   last hairline would draw a second parallel rule with dead space between. */
.section .picks > li:last-child,
.section .entries > li:last-child,
.section .criteria > div:last-child,
.section .faq > div:last-child { border-bottom: 0; }

/* ---------- Section rhythm ---------- */
.section { padding: clamp(44px, 7vw, 84px) 0; border-bottom: 1px solid var(--rule); }
.section-tight { padding: clamp(32px, 5vw, 56px) 0; border-bottom: 1px solid var(--rule); }
.section-head { display: grid; grid-template-columns: minmax(0, 1fr); gap: 10px; margin-bottom: clamp(24px, 4vw, 40px); }
.section-head p { max-width: 68ch; color: var(--ink-2); }

/* ---------- Hero ---------- */
.hero { padding: clamp(48px, 8vw, 96px) 0 clamp(36px, 6vw, 64px); border-bottom: 1px solid var(--rule); }
.hero h1 em { font-style: italic; color: var(--claret); }
.hero .lede { margin-top: 20px; max-width: 62ch; }
.hero-facts { margin-top: clamp(28px, 4vw, 44px); display: flex; flex-wrap: wrap; gap: 0; border-top: 1px solid var(--rule-strong); }
.hero-facts > div { padding: 14px clamp(18px, 3vw, 34px) 4px 0; margin-right: clamp(18px, 3vw, 34px); border-right: 1px solid var(--rule); font-size: 0.84rem; color: var(--ink-2); }
.hero-facts > div:last-child { border-right: 0; }
.hero-facts b { display: block; font-family: var(--serif); font-size: 1.35rem; font-weight: 600; color: var(--ink); font-variant-numeric: lining-nums tabular-nums; }
/* Phone: the flex strip leaves orphaned vertical rules, so stack it as ruled rows. */
@media (max-width: 640px) {
  .hero-facts { display: grid; grid-template-columns: 1fr; }
  .hero-facts > div { display: flex; align-items: baseline; gap: 12px; margin-right: 0; border-right: 0; border-bottom: 1px solid var(--rule); padding: 10px 0; }
  .hero-facts > div:last-child { border-bottom: 0; }
  .hero-facts b { display: inline; font-size: 1.15rem; flex: 0 0 auto; min-width: 4.6em; }
}

/* ---------- Picks by job ---------- */
.picks { list-style: none; border-top: 1px solid var(--rule-strong); }
.picks li { display: grid; grid-template-columns: 220px minmax(0, 1fr); gap: 8px clamp(20px, 4vw, 48px); padding: clamp(18px, 3vw, 26px) 0; border-bottom: 1px solid var(--rule); }
.pick-job { font-size: 0.78rem; font-weight: 600; letter-spacing: 0.1em; text-transform: uppercase; color: var(--claret); padding-top: 5px; }
.pick-body .pick-name { font-family: var(--serif); font-size: 1.25rem; font-weight: 600; }
.pick-body .pick-name a { color: var(--ink); text-decoration: none; }
.pick-body .pick-name a:hover { text-decoration: underline; text-decoration-color: var(--claret); }
.pick-body p { margin-top: 6px; font-size: 0.94rem; color: var(--ink-2); max-width: 62ch; }
.pick-note { font-size: 0.8rem; color: var(--ink-3); margin-top: 6px; }
@media (max-width: 640px) { .picks li { grid-template-columns: 1fr; } }

/* ---------- Comparison table ---------- */
.table-scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; border: 1px solid var(--rule); background: var(--paper-lite); scrollbar-width: thin; }
.table-scroll:focus-visible { outline: 2px solid var(--claret); outline-offset: 2px; }
table.compare { width: 100%; min-width: 980px; border-collapse: collapse; font-size: 0.86rem; font-variant-numeric: tabular-nums; }
table.compare caption { caption-side: bottom; text-align: left; font-size: 0.76rem; color: var(--ink-3); padding: 12px 14px; }
table.compare th, table.compare td { text-align: left; vertical-align: top; padding: 12px 14px; border-bottom: 1px solid var(--rule); }
table.compare thead th { font-family: var(--sans); font-size: 0.72rem; font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase; color: var(--ink-2); background: var(--paper-2); border-bottom: 1px solid var(--rule-strong); position: sticky; top: 0; z-index: 2; }
table.compare tbody th { font-family: var(--serif); font-weight: 600; font-size: 0.98rem; white-space: nowrap; }
/* The vendor column stays put while the table scrolls sideways (this is the axis that actually scrolls). */
table.compare tbody th, table.compare thead th:first-child { position: sticky; left: 0; z-index: 1; background: var(--paper-lite); border-right: 1px solid var(--rule-strong); }
table.compare thead th:first-child { background: var(--paper-2); z-index: 3; }
table.compare tbody tr:nth-child(even) th { background: var(--paper-2); }
table.compare tbody th a { color: var(--ink); text-decoration: none; }
table.compare tbody th a:hover { text-decoration: underline; text-decoration-color: var(--claret); }
table.compare tbody tr:nth-child(even) { background: var(--paper-2); }
table.compare td { color: var(--ink-2); font-weight: 380; line-height: 1.5; }
.klas { color: var(--good); font-weight: 600; white-space: nowrap; }
@media (max-width: 640px) {
  /* Keep the frozen vendor column narrow so the scrolling columns get real room. */
  table.compare tbody th { white-space: normal; font-size: 0.9rem; }
  table.compare th, table.compare td { padding: 10px 12px; }
  table.compare thead th:first-child, table.compare tbody th { max-width: 132px; }
}

/* ---------- Vendor entries (table-of-record rows) ---------- */
.entries { list-style: none; counter-reset: vendor; border-top: 1px solid var(--rule-strong); }
.entries > li { counter-increment: vendor; display: grid; grid-template-columns: 84px minmax(0, 1fr); gap: 6px clamp(20px, 4vw, 52px); padding: clamp(26px, 4vw, 40px) 0; border-bottom: 1px solid var(--rule); }
.entries > li::before { content: counter(vendor, decimal-leading-zero); font-family: var(--serif); font-size: clamp(1.9rem, 3.6vw, 2.6rem); font-weight: 600; color: var(--claret); line-height: 1; font-variant-numeric: lining-nums tabular-nums; }
.entry-head { display: flex; align-items: baseline; gap: 14px; flex-wrap: wrap; }
.entry-head h3 { font-size: clamp(1.25rem, 2.4vw, 1.55rem); }
.entry-head h3 a { color: var(--ink); text-decoration: none; }
.entry-head h3 a:hover { text-decoration: underline; text-decoration-color: var(--claret); }
.entry-cat { font-size: 0.72rem; font-weight: 600; letter-spacing: 0.1em; text-transform: uppercase; color: var(--ink-3); }
.entry-body p { margin-top: 10px; max-width: 68ch; color: var(--ink-2); font-size: 0.96rem; }
.entry-meta { margin-top: 12px; font-size: 0.82rem; color: var(--ink-3); }
.entry-meta a { color: var(--claret); }
@media (max-width: 640px) {
  .entries > li { grid-template-columns: 1fr; }
  .entries > li::before { font-size: 1.5rem; }
}

/* ---------- Criteria ---------- */
.criteria { border-top: 1px solid var(--rule-strong); }
.criteria > div { display: grid; grid-template-columns: minmax(180px, 300px) minmax(0, 1fr); gap: 8px clamp(20px, 4vw, 48px); padding: clamp(16px, 2.6vw, 24px) 0; border-bottom: 1px solid var(--rule); }
.criteria h3, .criteria h2 { font-size: 1.05rem; line-height: 1.3; padding-top: 2px; }
.criteria p { color: var(--ink-2); font-size: 0.94rem; max-width: 62ch; }
@media (max-width: 640px) { .criteria > div { grid-template-columns: 1fr; } }

/* ---------- FAQ ---------- */
.faq { border-top: 1px solid var(--rule-strong); }
.faq > div { padding: clamp(18px, 3vw, 26px) 0; border-bottom: 1px solid var(--rule); }
.faq h3 { font-size: 1.08rem; margin-bottom: 8px; }
.faq p { color: var(--ink-2); font-size: 0.95rem; max-width: 70ch; }
/* Wide: run questions in the left column like the criteria table, so the section is not one narrow stack. */
@media (min-width: 900px) {
  .faq > div { display: grid; grid-template-columns: minmax(200px, 320px) minmax(0, 1fr); gap: 0 clamp(20px, 4vw, 48px); }
  .faq h3 { margin-bottom: 0; padding-top: 2px; }
}

/* ---------- Disclosure panel ---------- */
.disclosure { background: var(--claret-wash); border: 1px solid oklch(0.42 0.14 20 / 0.25); padding: clamp(20px, 3vw, 28px) clamp(20px, 3.4vw, 32px); max-width: 78ch; }
.disclosure h2 { font-size: 1.15rem; margin-bottom: 8px; }
.disclosure p { font-size: 0.92rem; color: var(--ink-2); }

/* ---------- Vendor profile pages ---------- */
.crumbs { font-size: 0.8rem; color: var(--ink-3); padding: 16px 0 0; }
.crumbs a { color: var(--ink-3); }
.factsheet { border-top: 1px solid var(--rule-strong); margin-top: clamp(24px, 4vw, 40px); }
.factsheet > div { display: grid; grid-template-columns: minmax(160px, 240px) minmax(0, 1fr); gap: 6px clamp(16px, 3vw, 40px); padding: 13px 0; border-bottom: 1px solid var(--rule); font-size: 0.93rem; }
.factsheet dt { font-weight: 600; color: var(--ink); font-size: 0.8rem; letter-spacing: 0.06em; text-transform: uppercase; padding-top: 2px; }
.factsheet dd { color: var(--ink-2); }
@media (max-width: 560px) { .factsheet > div { grid-template-columns: 1fr; } }
.src-list { margin-top: 10px; padding-left: 20px; color: var(--ink-2); font-size: 0.9rem; }
.src-list li { margin-bottom: 6px; }

/* ---------- Footer ---------- */
footer { background: var(--claret-deep); color: oklch(0.88 0.02 20); }
footer .wrap { padding-top: clamp(36px, 5vw, 56px); padding-bottom: 28px; }
.foot-grid { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr) minmax(0, 1fr); gap: clamp(24px, 4vw, 56px); padding-bottom: 32px; border-bottom: 1px solid oklch(0.95 0.01 20 / 0.18); }
.foot-brand .wordmark { font-size: 1rem; }
.foot-disclosure { margin-top: 12px; font-size: 0.82rem; line-height: 1.6; color: oklch(0.82 0.02 20); max-width: 40ch; }
.foot-disclosure a { color: oklch(0.93 0.015 20); }
.foot-col b { display: block; font-size: 0.72rem; font-weight: 600; letter-spacing: 0.12em; text-transform: uppercase; color: oklch(0.93 0.015 20); margin-bottom: 12px; }
.foot-col ul { list-style: none; display: flex; flex-direction: column; gap: 8px; }
.foot-col a { color: oklch(0.85 0.02 20); text-decoration: none; font-size: 0.88rem; }
.foot-col a:hover { text-decoration: underline; }
.foot-bottom { padding-top: 18px; font-size: 0.75rem; color: oklch(0.78 0.02 20); }
@media (max-width: 720px) { .foot-grid { grid-template-columns: 1fr; } }
