/* ============================================================
   PepAxiom — brand site
   Register: clinical print. Two-colour ink on paper stock,
   Swiss-pharmaceutical grid, expanded grotesque + serif italic.
   ============================================================ */

:root {
  --paper:    #EFF0EC;   /* stock */
  --paper-2:  #E6E8E2;   /* recessed */
  --white:    #FAFAF9;   /* raised: fields, cards */
  --ink:      #15171A;   /* first colour */
  --ink-mid:  #585C61;   /* secondary text */
  --blue:     #12369C;   /* second colour */
  --blue-pale:#D6DDF1;
  --rule:     #C6C8C1;

  --grotesk: "Archivo", "Helvetica Neue", Helvetica, Arial, sans-serif;
  --serif:   "Source Serif 4", Georgia, "Times New Roman", serif;

  --gut: clamp(1.25rem, 5vw, 4.5rem);
  --max: 1180px;
  --rhythm: clamp(4.5rem, 10vw, 8.5rem);
  --margincol: 10rem;
}

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

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--serif);
  font-size: clamp(1rem, 0.95rem + 0.24vw, 1.125rem);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

h1, h2, h3 { margin: 0; }
p { margin: 0; }
ol, ul, dl { margin: 0; padding: 0; list-style: none; }

::selection { background: var(--blue); color: var(--paper); }

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

.skip {
  position: absolute; left: -9999px; top: 0; z-index: 99;
  background: var(--ink); color: var(--paper); padding: 0.75rem 1.25rem;
  font-family: var(--grotesk); font-size: 0.75rem; text-decoration: none;
}
.skip:focus { left: 0; }

a { color: inherit; }
:focus-visible { outline: 2px solid var(--blue); outline-offset: 3px; }

/* ── the marginal tag: names the section in the left column ── */

.tag {
  font-family: var(--grotesk);
  font-variation-settings: "wdth" 100;
  font-size: 0.6875rem;
  font-weight: 600;
  line-height: 1.35;
  letter-spacing: 0.13em;
  text-transform: uppercase;
  color: var(--blue);
  padding-top: 0.55rem;
  border-top: 2px solid var(--blue);
  margin-bottom: 2.25rem;
}
.tag br { display: none; }
@media (min-width: 1020px) { .tag br { display: inline; } }
.tag--invert { color: var(--paper); border-top-color: var(--paper); }

/* ── nav ─────────────────────────────────────────────────── */

.nav {
  display: flex; align-items: center; justify-content: space-between;
  gap: 1rem;
  max-width: var(--max);
  margin: 0 auto;
  padding: 1.1rem var(--gut);
  border-bottom: 1px solid var(--rule);
}

.nav__mark {
  font-family: var(--grotesk);
  font-variation-settings: "wdth" 118;
  font-size: 0.9375rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  text-decoration: none;
}

.nav__right { display: flex; align-items: center; gap: 1.5rem; }

.nav__state {
  font-family: var(--grotesk);
  font-size: 0.6875rem;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-mid);
}
@media (max-width: 720px) { .nav__state { display: none; } }

/* ── buttons ─────────────────────────────────────────────── */

.btn {
  display: inline-block;
  font-family: var(--grotesk);
  font-size: 0.6875rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  text-decoration: none;
  color: var(--paper);
  background: var(--ink);
  border: 0;
  padding: 0.7rem 1.2rem;
  cursor: pointer;
  transition: background 150ms ease;
}
.btn:hover { background: var(--blue); }
.btn--sm { padding: 0.6rem 1rem; font-size: 0.625rem; }
.btn--full { width: 100%; padding: 0.95rem 1.2rem; margin-top: 0.75rem; }

/* ── grid shell ──────────────────────────────────────────── */

.hero, .band {
  max-width: var(--max);
  margin: 0 auto;
  padding: var(--rhythm) var(--gut) 0;
}
.band--tight { padding-top: clamp(2.5rem, 5vw, 4rem); }

@media (min-width: 1020px) {
  .band {
    display: grid;
    grid-template-columns: var(--margincol) minmax(0, 1fr);
    column-gap: 4rem;
  }
  .band > * { grid-column: 2; }
  .band > .tag { grid-column: 1; grid-row: 1; margin-bottom: 0; }
}

/* ── hero ────────────────────────────────────────────────── */

.hero { padding-top: clamp(3rem, 7vw, 5.5rem); }

@media (min-width: 1020px) {
  .hero__grid {
    display: grid;
    grid-template-columns: var(--margincol) minmax(0, 1fr);
    column-gap: 4rem;
  }
}

.hero__title {
  font-family: var(--grotesk);
  font-variation-settings: "wdth" 122;
  font-size: clamp(2.35rem, 1.1rem + 5.6vw, 5.4rem);
  font-weight: 700;
  line-height: 1.0;
  letter-spacing: -0.015em;
  margin-bottom: 2.25rem;
}
.hero__title em {
  display: inline-block;
  font-family: var(--serif);
  font-variation-settings: normal;
  font-style: italic;
  font-weight: 300;
  font-size: 1.06em;
  letter-spacing: -0.012em;
  color: var(--blue);
}

.hero__lede {
  max-width: 34em;
  font-size: clamp(1.0625rem, 1rem + 0.36vw, 1.3125rem);
  line-height: 1.52;
  color: var(--ink-mid);
  text-wrap: pretty;
}
.hero__lede b {
  color: var(--ink);
  font-weight: 600;
  font-variant-numeric: tabular-nums;
}

/* ── figure ──────────────────────────────────────────────── */

.fig {
  margin: clamp(3rem, 6vw, 5rem) 0 0;
  border-top: 2px solid var(--ink);
}

.fig__head {
  display: flex; flex-wrap: wrap; align-items: baseline; gap: 0.4rem 1rem;
  padding: 0.7rem 0 1.5rem;
  font-family: var(--grotesk);
  font-size: 0.6875rem;
  font-weight: 500;
  letter-spacing: 0.09em;
  text-transform: uppercase;
}
.fig__no { color: var(--blue); font-weight: 700; }
.fig__title { color: var(--ink-mid); }

.fig__canvas {
  display: block;
  width: 100%;
  height: clamp(220px, 30vw, 340px);
}

.fig__cap {
  display: flex; flex-wrap: wrap; justify-content: space-between; gap: 0.4rem 1.5rem;
  padding-top: 0.85rem;
  border-top: 1px solid var(--rule);
  font-family: var(--grotesk);
  font-size: 0.6875rem;
  color: var(--ink-mid);
}
.fig__withheld {
  color: var(--paper);
  background: var(--ink);
  padding: 0.1rem 0.5rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  font-weight: 500;
}

/* ── section heads ───────────────────────────────────────── */

.sechead { max-width: 32em; margin-bottom: clamp(2.5rem, 5vw, 3.5rem); }

.sechead__h {
  font-family: var(--grotesk);
  font-variation-settings: "wdth" 116;
  font-size: clamp(1.55rem, 1.1rem + 1.8vw, 2.5rem);
  font-weight: 700;
  line-height: 1.08;
  letter-spacing: -0.012em;
  margin-bottom: 1rem;
}
.sechead__p { color: var(--ink-mid); max-width: 30em; text-wrap: pretty; }

/* ── ledger ──────────────────────────────────────────────── */

.ledger { border-top: 1px solid var(--ink); }

.ledger__row {
  display: flex; align-items: baseline; gap: 1.5rem;
  padding: 0.85rem 0;
  border-bottom: 1px solid var(--rule);
}
.ledger__row dt { flex: 1; }
.ledger__row dd {
  margin: 0;
  font-family: var(--grotesk);
  font-variation-settings: "wdth" 100;
  font-size: clamp(1rem, 0.85rem + 0.7vw, 1.5rem);
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.01em;
}
.ledger__row:nth-child(1) dd,
.ledger__row:nth-child(2) dd { color: var(--blue); }

/* ── stages ──────────────────────────────────────────────── */

.stages {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(205px, 1fr));
  gap: clamp(1.75rem, 3vw, 2.75rem);
}
.stage { border-top: 1px solid var(--ink); padding-top: 1.1rem; }

.stage__h {
  font-family: var(--grotesk);
  font-variation-settings: "wdth" 105;
  font-size: 1.0625rem;
  font-weight: 700;
  letter-spacing: 0.005em;
  margin-bottom: 0.85rem;
}
.stage__n {
  display: inline-block;
  min-width: 1.9rem;
  color: var(--blue);
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}
.stage__p { font-size: 0.9375rem; color: var(--ink-mid); text-wrap: pretty; }

/* ── the inverted statement ──────────────────────────────── */

.rule-band {
  margin-top: var(--rhythm);
  background: var(--ink);
  color: var(--paper);
  padding: clamp(3.5rem, 8vw, 6.5rem) 0;
}
.rule-band__inner {
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 var(--gut);
}
@media (min-width: 1020px) {
  .rule-band__inner {
    display: grid;
    grid-template-columns: var(--margincol) minmax(0, 1fr);
    column-gap: 4rem;
  }
  .rule-band__inner > .tag { grid-column: 1; grid-row: 1; margin-bottom: 0; }
  .rule-band__inner > .statement,
  .rule-band__inner > .statement__p { grid-column: 2; }
}

.statement {
  font-family: var(--grotesk);
  font-variation-settings: "wdth" 122;
  font-size: clamp(2.1rem, 1rem + 5vw, 4.6rem);
  font-weight: 800;
  line-height: 0.98;
  letter-spacing: -0.022em;
  margin-bottom: 1.75rem;
}
.statement__p {
  max-width: 34em;
  font-size: clamp(1rem, 0.95rem + 0.3vw, 1.1875rem);
  line-height: 1.58;
  color: color-mix(in srgb, var(--paper) 74%, var(--ink));
  text-wrap: pretty;
}

/* ── tier cards ──────────────────────────────────────────── */

.tiers {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: clamp(1.25rem, 2.5vw, 2rem);
}
.tier { padding: clamp(1.5rem, 3vw, 2.1rem); }

.tier__label {
  font-family: var(--grotesk);
  font-size: 0.625rem;
  font-weight: 700;
  letter-spacing: 0.13em;
  text-transform: uppercase;
  margin-bottom: 1.5rem;
}
.tier__h {
  font-family: var(--grotesk);
  font-variation-settings: "wdth" 108;
  font-size: 1.1875rem;
  font-weight: 700;
  margin-bottom: 0.75rem;
}
.tier__p { font-size: 0.9375rem; color: var(--ink-mid); margin-bottom: 1.4rem; text-wrap: pretty; }
.tier__meta {
  font-family: var(--grotesk);
  font-size: 0.6875rem;
  font-weight: 500;
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.04em;
  padding-top: 1rem;
}

/* expert: printed, filled, ranked */
.tier--expert {
  background: var(--white);
  border: 1px solid var(--rule);
  border-top: 3px solid var(--ink);
}
.tier--expert .tier__label { color: var(--ink); }
.tier--expert .tier__meta  { border-top: 1px solid var(--rule); color: var(--ink); }

/* community: unprinted, provisional, a different register entirely */
.tier--community {
  background: transparent;
  border: 1px dashed var(--blue);
  border-top: 3px dashed var(--blue);
}
.tier--community .tier__label { color: var(--blue); }
.tier--community .tier__h     { font-weight: 500; color: var(--ink-mid); }
.tier--community .tier__meta  { border-top: 1px dashed var(--blue); color: var(--blue); }

/* ── the gate ────────────────────────────────────────────── */

.modules { border-top: 1px solid var(--ink); }

.module {
  display: grid;
  grid-template-columns: 1fr auto auto;
  align-items: center;
  gap: 1.25rem;
  padding: 0.95rem 0;
  border-bottom: 1px solid var(--rule);
}
.module__name { font-size: 1.0625rem; }
.module__meta {
  display: inline-flex; align-items: center;
  font-family: var(--grotesk);
  font-size: 0.6875rem;
  font-weight: 500;
  font-variant-numeric: tabular-nums;
  color: var(--ink-mid);
}
.module__lock {
  font-family: var(--grotesk);
  font-size: 0.5625rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--blue);
  border: 1px solid var(--blue);
  padding: 0.24rem 0.5rem;
  white-space: nowrap;
}
@media (max-width: 620px) {
  .module { grid-template-columns: 1fr auto; }
  .module__meta { grid-column: 1; grid-row: 2; }
  .module__lock { grid-column: 2; grid-row: 1 / span 2; }
}

/* struck through, the way a released document is */
.redact {
  display: inline-block;
  width: 4.75rem; height: 0.85rem;
  background: var(--ink);
}
.redact--sm { width: 2.9rem; }
.redact--lg { width: 6.25rem; }

/* ── access ──────────────────────────────────────────────── */

.band--access { padding-bottom: var(--rhythm); }

.access { display: grid; grid-template-columns: 1fr; gap: clamp(2.5rem, 5vw, 4rem); }
@media (min-width: 900px) { .access { grid-template-columns: 1fr 1fr; align-items: start; } }

.expect { margin-top: clamp(2rem, 4vw, 2.5rem); border-top: 1px solid var(--ink); }
.expect__row {
  display: flex; gap: 1.25rem;
  padding: 0.75rem 0;
  border-bottom: 1px solid var(--rule);
}
.expect__row dt {
  flex: 0 0 7rem;
  font-family: var(--grotesk);
  font-size: 0.625rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--blue);
  padding-top: 0.3rem;
}
.expect__row dd { margin: 0; font-size: 0.9375rem; color: var(--ink-mid); }

.form { display: flex; flex-direction: column; gap: 1.1rem; }
.field-row { display: flex; flex-direction: column; gap: 0.4rem; }

.lbl {
  font-family: var(--grotesk);
  font-size: 0.625rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink);
}
.lbl__opt { color: var(--ink-mid); font-weight: 400; text-transform: none; letter-spacing: 0.02em; }

.in {
  font-family: var(--serif);
  font-size: 1rem;
  color: var(--ink);
  background: var(--white);
  border: 1px solid var(--rule);
  border-radius: 0;
  padding: 0.75rem 0.85rem;
  width: 100%;
  transition: border-color 150ms ease;
}
.in:hover { border-color: var(--ink-mid); }
.in:focus { border-color: var(--blue); outline: none; box-shadow: inset 0 0 0 1px var(--blue); }
.in--area { resize: vertical; min-height: 6.5rem; line-height: 1.5; }
.in[aria-invalid="true"] { border-color: var(--blue); background: var(--blue-pale); }

.form__note {
  font-family: var(--grotesk);
  font-size: 0.6875rem;
  line-height: 1.6;
  color: var(--ink-mid);
}
.form__note--err { color: var(--blue); font-weight: 600; }

/* ── footer ──────────────────────────────────────────────── */

.foot { border-top: 2px solid var(--ink); margin-top: var(--rhythm); }
.foot__inner {
  max-width: var(--max);
  margin: 0 auto;
  padding: 1.75rem var(--gut) 3.5rem;
}

.foot__top {
  display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 1.5rem;
}
.foot__mark {
  font-family: var(--grotesk);
  font-variation-settings: "wdth" 118;
  font-size: 0.875rem; font-weight: 700;
  letter-spacing: 0.1em; text-transform: uppercase;
}
.foot__mail {
  font-family: var(--grotesk);
  font-size: 0.75rem;
  color: var(--blue);
  text-decoration: none;
  border-bottom: 1px solid var(--blue);
  padding-bottom: 1px;
}
.foot__mail:hover { color: var(--ink); border-color: var(--ink); }

.foot__legal {
  max-width: 46em;
  font-size: 0.875rem;
  line-height: 1.62;
  color: var(--ink-mid);
  margin-bottom: 1.1rem;
  text-wrap: pretty;
}
.foot__copy {
  font-family: var(--grotesk);
  font-size: 0.625rem;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink-mid);
}

/* ── reveal ──────────────────────────────────────────────── */

.reveal {
  opacity: 0;
  transform: translateY(10px);
  transition: opacity 560ms cubic-bezier(.22,.61,.36,1), transform 560ms cubic-bezier(.22,.61,.36,1);
}
.reveal.is-in { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
  .btn, .in { transition: none; }
}
