/* rxpave.com — RxPave brand (docs/brand/RXPAVE-BRAND.md): the original rxpave.com slate teal,
   Archivo for display, Atkinson Hyperlegible for text, IBM Plex Mono for figures.
   Every text/background pair below is at least 4.5:1. Ochre is a fill, never text on white.
   Mobile first: every page works at 375 px (D-9); the header folds below 980 px. */

:root {
	--slate: #26586e;
	--slate-deep: #224e63;
	--workbench: #1b3a48;
	--teal: #0a747f;
	--ochre: #ae8c3e;
	--ochre-line: #e9cf8a;
	--brown: #865308;
	--viable: #2f7a37;
	--viable-tint: #e2f0e3;
	--viable-ink: #2a6a31;
	--out: #5d1100;
	--out-tint: #f5e1da;
	--neutral-tint: #e9eef1;
	--neutral-ink: #33444f;
	--steel-tint: #a9d6e5;
	--ochre-light: #d9bd78;
	--ink: #222222;
	--ink-2: #55616b;
	--ink-3: #5f6b74;
	--paper: #f7f8f8;
	--white: #ffffff;
	--hairline: #dfe5e8;
	--charcoal: #2d2d2d;
	--muted-on-slate: #b3c4cc;
	--display: Archivo, "Helvetica Neue", Helvetica, Arial, sans-serif;
	--body: "Atkinson Hyperlegible", -apple-system, system-ui, "Segoe UI", Roboto, Arial, sans-serif;
	--mono: "IBM Plex Mono", Menlo, Consolas, monospace;
	--radius: 10px;
	--shell: 1200px;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--white); color: var(--ink); font-family: var(--body); font-size: 17px; line-height: 1.6; }
img { max-width: 100%; height: auto; }
a { color: var(--slate); text-underline-offset: 3px; }
a:hover { color: var(--slate-deep); }
:focus-visible { outline: 3px solid var(--teal); outline-offset: 2px; }
h1, h2, h3 { font-family: var(--display); line-height: 1.15; letter-spacing: -0.01em; }
h2 { font-size: 30px; font-weight: 800; margin: 0 0 16px; }
h3 { font-size: 19px; font-weight: 700; margin: 0 0 6px; font-family: var(--body); letter-spacing: 0; }
p { margin: 0 0 14px; }
.mono { font-family: var(--mono); }
.shell { max-width: var(--shell); margin: 0 auto; padding-left: 16px; padding-right: 16px; }
@media (min-width: 720px) { .shell { padding-left: 24px; padding-right: 24px; } }

.skip { position: absolute; left: -9999px; top: 8px; background: var(--white); padding: 8px 12px; z-index: 10; }
.skip:focus { left: 8px; }

.eyebrow { font-size: 13px; font-weight: 700; letter-spacing: 0.14em; text-transform: uppercase; color: var(--brown); margin: 0 0 10px; }
.eyebrow-on-slate { color: var(--ochre-light); }
.lede { font-size: 18.5px; line-height: 1.6; color: var(--ink-2); max-width: 820px; }
.micro { font-size: 14px; color: var(--ink-3); margin: 0; }
.link-cta { font-weight: 700; }

/* buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; min-height: 44px; padding: 10px 18px; border-radius: 6px; font-weight: 700; text-decoration: none; font-size: 16px; border: 1px solid transparent; }
.btn-primary { background: var(--teal); color: var(--white); }
.btn-primary:hover { background: var(--slate); color: var(--white); }
.btn-large { font-size: 17px; padding: 13px 22px; }
.btn-small { min-height: 40px; padding: 8px 14px; font-size: 15px; }
.btn-block { display: flex; width: 100%; }
.cta-row { display: flex; flex-wrap: wrap; align-items: center; gap: 14px 22px; margin: 6px 0 14px; }

/* header */
.top { background: var(--white); border-bottom: 3px solid var(--slate); position: relative; z-index: 5; }
.top-inner { display: flex; align-items: center; gap: 12px 24px; min-height: 64px; }
.brand { display: flex; align-items: center; gap: 8px; text-decoration: none; color: var(--ink); }
.brand img { height: 32px; width: auto; }
.brand span { font-family: var(--display); font-weight: 700; font-size: 20px; letter-spacing: 0.12em; }
.nav { display: none; flex: 1; justify-content: flex-end; gap: 4px 20px; font-size: 15px; }
.nav a { text-decoration: none; padding: 8px 0; }
.nav a[aria-current="page"] { color: var(--ink); font-weight: 700; box-shadow: inset 0 -2px 0 var(--teal); }
.top-actions { display: flex; align-items: center; gap: 12px; margin-left: auto; }
.signin { font-weight: 700; text-decoration: none; padding: 10px 2px; }
.hide-phone { display: none; }
.menu { position: relative; }
.menu summary { list-style: none; display: inline-flex; align-items: center; justify-content: center; width: 44px; height: 44px; border: 1px solid var(--hairline); border-radius: 8px; color: var(--slate); cursor: pointer; }
.menu summary::-webkit-details-marker { display: none; }
.menu[open] summary { background: var(--paper); }
.menu-panel { position: absolute; right: 0; top: 52px; width: min(320px, calc(100vw - 32px)); background: var(--white); border: 1px solid var(--hairline); border-radius: var(--radius); box-shadow: 0 12px 32px rgba(0, 0, 0, 0.14); padding: 8px 16px 16px; display: flex; flex-direction: column; }
.menu-panel a:not(.btn) { padding: 12px 0; border-bottom: 1px solid var(--hairline); text-decoration: none; color: var(--ink); font-size: 17px; }
.menu-panel a[aria-current="page"] { font-weight: 700; }
.menu-panel .btn { margin-top: 14px; }
@media (min-width: 560px) { .hide-phone { display: inline-flex; } }
@media (min-width: 980px) {
	.nav { display: flex; }
	.menu { display: none; }
	.top-actions { margin-left: 8px; }
}

/* sections */
.section { padding-top: 48px; padding-bottom: 48px; }
.section-head { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 6px 24px; margin-bottom: 18px; }
.section-head h2 { margin: 0; }
.band { background: var(--paper); border-top: 1px solid var(--hairline); border-bottom: 1px solid var(--hairline); padding: 48px 0; }
.split { display: grid; gap: 28px; }
@media (min-width: 900px) { .split { grid-template-columns: 1.15fr 1fr; gap: 40px; align-items: start; } }

/* hero */
.hero { display: grid; gap: 32px; padding-top: 36px; padding-bottom: 44px; align-items: center; }
.hero h1 { font-size: clamp(32px, 6vw, 50px); font-weight: 800; letter-spacing: -0.02em; line-height: 1.06; margin: 0 0 16px; }
@media (min-width: 980px) { .hero { grid-template-columns: 1fr 1fr; gap: 48px; padding-top: 56px; padding-bottom: 64px; } }
.hero-report { margin: 0; background: var(--workbench); border-radius: 14px; padding: 12px; }
@media (min-width: 720px) { .hero-report { padding: 22px; } }
.hero-report figcaption { margin-top: 10px; font-size: 13px; color: var(--muted-on-slate); }
.report-card { background: var(--paper); border-radius: var(--radius); overflow: hidden; }
.report-head { background: var(--white); border-bottom: 1px solid var(--hairline); padding: 14px 16px; display: flex; flex-direction: column; gap: 2px; }
.report-head .eyebrow { margin: 0; font-size: 12px; }
.report-head strong { font-family: var(--display); font-size: 18px; }
.report-sub { font-size: 13.5px; color: var(--ink-3); }
.report-body { padding: 14px 16px; display: flex; flex-direction: column; gap: 10px; }
.report-verdict { font-family: var(--display); font-weight: 800; font-size: 23px; margin: 0; }
.report-row { background: var(--white); border: 1px solid var(--hairline); border-radius: 8px; padding: 10px 12px; display: flex; flex-wrap: wrap; align-items: center; gap: 6px 12px; font-size: 15px; }
.report-row strong { flex: 1 1 170px; }
.report-row .mono { font-size: 14px; color: var(--neutral-ink); }
.report-row .why { flex: 1 1 100%; font-size: 13.5px; color: var(--ink-3); line-height: 1.45; }
.report-more { font-size: 14.5px; font-weight: 700; }
.pill { border-radius: 999px; padding: 3px 11px; font-size: 13px; font-weight: 700; white-space: nowrap; }
.pill-viable { background: var(--viable); color: var(--white); }
.pill-out { background: var(--out-tint); color: var(--out); }

.stats-strip { border-bottom: 1px solid var(--hairline); padding: 18px 0; }
.stats-strip .shell { display: flex; flex-wrap: wrap; align-items: baseline; gap: 8px 36px; }
.stats-strip .eyebrow { margin: 0; }
.stats-strip strong, .stats-box strong { font-family: var(--display); font-size: 24px; }
.stats-box { background: var(--paper); border-radius: var(--radius); padding: 14px 16px; display: flex; flex-wrap: wrap; gap: 8px 28px; }
.stats-box p { flex: 1 1 100%; font-size: 13.5px; color: var(--ink-3); margin: 0; }

.steps, .checks, .features { list-style: none; margin: 0; padding: 0; display: grid; gap: 22px; }
@media (min-width: 720px) { .steps { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.steps p, .features p, .checks p { font-size: 16px; color: var(--ink-2); margin: 0; }
.step-n { display: block; font-family: var(--display); font-weight: 800; font-size: 38px; color: var(--slate); line-height: 1; margin-bottom: 8px; }
.checks { gap: 14px; margin-bottom: 18px; }
@media (min-width: 720px) { .checks { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 1100px) { .checks { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.checks li { border: 1px solid var(--hairline); border-radius: var(--radius); padding: 16px; }
.check-n { display: inline-flex; align-items: center; justify-content: center; width: 32px; height: 32px; border-radius: 50%; background: var(--teal); color: var(--white); font-weight: 700; margin-bottom: 8px; }
@media (min-width: 720px) { .features { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px 32px; } }
@media (min-width: 1100px) { .features { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.features li { border-left: 3px solid var(--steel-tint); padding-left: 14px; }

.panel-slate { background: var(--slate-deep); color: var(--white); border-radius: 12px; padding: 22px; }
.panel-slate p { color: var(--white); }
.panel-slate .muted-on-slate { color: var(--muted-on-slate); font-size: 15.5px; }
.panel-slate a { color: var(--steel-tint); font-weight: 700; }

.closing { background: var(--neutral-tint); padding: 40px 0; }
.closing-inner { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 18px 40px; }
.closing h2 { flex: 1 1 420px; margin: 0; font-size: clamp(24px, 4vw, 30px); }
.closing .micro { margin-top: 8px; }

/* inner pages */
.page-head { background: var(--paper); border-bottom: 1px solid var(--hairline); padding: 30px 0 24px; }
.page-head h1 { font-size: clamp(30px, 5vw, 44px); font-weight: 800; letter-spacing: -0.02em; margin: 0 0 10px; }
.page-head .lede { margin-bottom: 8px; }
.also-in-app { font-size: 14px; color: var(--ink-3); margin: 0; }
.page-body { padding-top: 28px; padding-bottom: 56px; }
.with-toc, .with-aside { display: flex; flex-wrap: wrap; gap: 28px 48px; align-items: flex-start; }
.with-toc > .prose, .with-aside > .prose { flex: 999 1 560px; min-width: 0; }
.toc { flex: 1 1 220px; max-width: 280px; display: flex; flex-direction: column; gap: 4px; font-size: 15px; border-left: 2px solid var(--hairline); padding-left: 14px; }
.toc strong { font-size: 13px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--ink-3); margin-bottom: 4px; }
.toc a { text-decoration: none; padding: 3px 0; }
@media (max-width: 879px) { .toc { max-width: none; flex-basis: 100%; } }
.aside { flex: 1 1 280px; max-width: 360px; display: flex; flex-direction: column; gap: 14px; }
@media (max-width: 879px) { .aside { max-width: none; } }
.notice { background: var(--paper); border: 1px dashed var(--ochre); border-radius: var(--radius); padding: 14px 16px; font-size: 15.5px; }

/* long-form text, including compiled guides */
.prose { max-width: 780px; }
.prose.wide { max-width: 900px; }
.prose h2 { font-size: 27px; margin: 32px 0 12px; scroll-margin-top: 16px; }
.prose h3 { font-size: 19px; margin: 24px 0 8px; scroll-margin-top: 16px; }
.prose h4 { font-size: 17px; margin: 18px 0 6px; }
.prose > :first-child, .prose section > :first-child { margin-top: 0; }
.prose section + section { margin-top: 36px; }
.prose ul, .prose ol { padding-left: 24px; margin: 0 0 16px; }
.prose li { margin-bottom: 6px; }
.prose table { border-collapse: collapse; width: 100%; font-size: 15px; line-height: 1.45; margin: 0 0 18px; display: block; overflow-x: auto; max-width: 100%; }
.prose th, .prose td { text-align: left; vertical-align: top; padding: 9px 12px; border-top: 1px solid var(--hairline); }
.prose thead th { background: var(--paper); border-top: none; }
.prose blockquote { margin: 0 0 16px; padding: 12px 16px; background: var(--paper); border-radius: 8px; border: 1px solid var(--ochre-line); }
.prose blockquote p:last-child { margin: 0; }
.prose figure { margin: 0 0 16px; }
.prose figure img { display: block; width: 100%; max-width: 560px; border: 1px solid var(--hairline); border-radius: var(--radius); background: var(--white); }
.prose figcaption { font-size: 13.5px; color: var(--ink-3); margin-top: 6px; }
.prose code { font-family: var(--mono); font-size: 0.92em; background: var(--paper); padding: 1px 4px; border-radius: 4px; }
.guide h2 { border-top: 1px solid var(--hairline); padding-top: 28px; }
.guide h2:first-child { border-top: none; padding-top: 0; }
.credit-line { font-weight: 700; }

/* field photos */
.photos { margin: 4px 0 20px; }
.photos-title { font-weight: 700; margin: 0 0 8px; }
.photos-title span { font-weight: 400; color: var(--ink-3); font-size: 14px; margin-left: 4px; }
.photo-strip { list-style: none; margin: 0; padding: 0 0 6px; display: grid; grid-auto-flow: column; grid-auto-columns: minmax(150px, 46%); gap: 10px; overflow-x: auto; scroll-snap-type: x mandatory; }
@media (min-width: 720px) { .photo-strip { grid-auto-flow: row; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); overflow: visible; } }
.photo-strip li { scroll-snap-align: start; margin: 0; }
.photo-strip figure { margin: 0; }
.photo-strip img { display: block; width: 100%; aspect-ratio: 4 / 3; object-fit: cover; border-radius: 6px; border: none; }
.photo-strip figcaption { display: flex; flex-direction: column; gap: 1px; font-size: 12.5px; line-height: 1.4; color: var(--ink-3); margin-top: 4px; }
.photo-shows { color: var(--ink); font-weight: 700; }

/* about, research, next links */
.credits-box { border: 1px solid var(--hairline); border-radius: 12px; padding: 18px; }
.credits-box dl { margin: 0; }
.credits-box dt { font-size: 12px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--ink-3); border-top: 1px solid var(--hairline); padding-top: 10px; margin-top: 10px; }
.credits-box dd { margin: 2px 0 0; font-weight: 700; line-height: 1.35; }
.ref-list { list-style: none; padding: 0; margin: 0 0 24px; }
.ref-list li { border-top: 1px solid var(--hairline); padding: 12px 0; margin: 0; }
.ref-list li p { margin: 4px 0 0; font-size: 15.5px; color: var(--ink-2); }
.ref-list li.primary { background: var(--paper); padding-left: 12px; padding-right: 12px; border-radius: 8px; }
.ref-list .file, .ref-list .year { font-family: var(--mono); font-size: 13px; color: var(--ink-3); }
.ref-list .tag { font-size: 12.5px; font-weight: 700; background: var(--viable-tint); color: var(--viable-ink); border-radius: 999px; padding: 2px 9px; }
.ref-list .cite { font-weight: 700; }
.next-links { display: grid; gap: 12px; margin-top: 32px; }
@media (min-width: 720px) { .next-links { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.next-links a { border: 1px solid var(--hairline); border-radius: var(--radius); padding: 14px 16px; text-decoration: none; display: flex; flex-direction: column; gap: 2px; }
.next-links span { color: var(--ink-2); font-size: 15px; }
.release { border-top: 1px solid var(--hairline); padding-top: 20px; margin-top: 20px; }
.release-meta { font-family: var(--mono); font-size: 13px; color: var(--ink-3); }

/* legal (the HeadLight documents, carried verbatim) */
.legal { max-width: 780px; padding-top: 24px; padding-bottom: 48px; }
.legal-notice { font-weight: 700; font-size: 15px; line-height: 1.65; border: 1px solid var(--hairline); border-left: 3px solid var(--teal); border-radius: 6px; background: var(--paper); padding: 14px 18px; margin: 0 0 18px; }
.legal h2 { font-family: var(--body); font-size: 13px; letter-spacing: 0.12em; text-transform: uppercase; font-weight: 700; color: var(--ink-3); margin: 36px 0 10px; padding-top: 14px; border-top: 1px solid var(--hairline); }
.legal h3 { font-size: 15.5px; margin: 22px 0 8px; }
.legal p, .legal li { font-size: 15px; line-height: 1.65; color: var(--ink-2); max-width: 70ch; }
.legal ol, .legal ul { margin: 0 0 14px; padding-left: 24px; }
.legal-tablewrap { overflow-x: auto; margin: 0 0 18px; }
.legal table { border-collapse: collapse; width: 100%; font-size: 14px; line-height: 1.55; }
.legal th, .legal td { text-align: left; vertical-align: top; padding: 8px 10px; border-top: 1px solid var(--hairline); }

/* footer */
.foot { background: var(--charcoal); color: var(--muted-on-slate); margin-top: 0; }
.foot a { color: var(--neutral-tint); }
.foot-inner { display: flex; flex-wrap: wrap; gap: 24px 56px; padding-top: 36px; padding-bottom: 24px; }
.foot-brand { flex: 1 1 260px; font-size: 14.5px; }
.foot-brand p { margin: 8px 0 0; }
.foot-mark { display: inline-flex; align-items: center; gap: 8px; }
.foot-mark img { background: var(--white); border-radius: 6px; padding: 3px 5px; height: 30px; width: auto; }
.foot-mark span { font-family: var(--display); font-weight: 700; letter-spacing: 0.12em; color: var(--white); font-size: 17px; }
.foot nav { display: flex; flex-direction: column; gap: 6px; font-size: 14.5px; min-width: 150px; }
.foot nav strong { color: var(--white); }
.foot nav a { padding: 3px 0; }
.foot-credit { border-top: 1px solid var(--ink-3); padding-top: 16px; padding-bottom: 28px; font-size: 13.5px; }
.foot-credit p { margin: 0 0 6px; }
.foot-credit .credit { color: var(--white); font-size: 14.5px; }
.foot-credit .credit a { color: var(--steel-tint); }

@media print {
	.top, .foot, .toc, .menu, .cta-row, .closing, .skip { display: none !important; }
	body { font-size: 11pt; }
	.page-head { background: none; border: none; padding: 0; }
	.photo-strip { grid-auto-flow: row; grid-template-columns: repeat(4, 1fr); overflow: visible; }
	a { color: inherit; text-decoration: none; }
}
