/* Mikhzan's public site: the landing page (/) and the privacy policy (/privacy), ADR 0013.
   Colours keep their dashboard meanings (ADR 0011): Salla's teal is structure, orange means
   "act", red means a product runs out before a new order could arrive, mint means it's fine.
   Readex Pro and the riyal sign are served from here, so the pages load nothing from anyone
   else. Logical properties only. */

@font-face {
  font-family: "Readex Pro";
  src: url("readex-pro-arabic.woff2") format("woff2");
  font-weight: 160 700;
  font-display: swap;
  unicode-range:
    U+0600-06FF, U+0750-077F, U+0870-088E, U+0890-0891, U+0897-08E1, U+08E3-08FF,
    U+200C-200E, U+2010-2011, U+204F, U+2E41, U+FB50-FDFF, U+FE70-FE74, U+FE76-FEFC;
}
@font-face {
  font-family: "Readex Pro";
  src: url("readex-pro-latin.woff2") format("woff2");
  font-weight: 160 700;
  font-display: swap;
  unicode-range:
    U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304,
    U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
/* Readex has no glyph for the riyal sign (U+20C1, Unicode 17). */
@font-face {
  font-family: "Saudi Riyal";
  src: url("riyal.ttf") format("truetype");
  unicode-range: U+20C1;
}

:root {
  --teal: #004d5b;
  --teal-deep: #00353f;
  --mint: #73fcd7;
  --orange: #ff7a1a;
  --on-orange: #1d1e20;
  --red: #ff5d64;
  --red-text: #ff9a9e;
  --on-teal: #ffffff;
  --on-teal-muted: #b5d3d6;
  --on-teal-line: rgb(255 255 255 / 0.12);

  --paper: #f3f6f6;
  --surface: #ffffff;
  --ink: #0f2a2f;
  --muted: #55676a;
  --line: #dce5e6;
  --link: #004d5b;
  /* Teal drawn on the page: chart bars, step rings, rules. */
  --structure: #004d5b;
  --chat: #e2f7ee;
  --pdf: #c4222a;

  --font: "Saudi Riyal", "Readex Pro", system-ui, -apple-system, "Segoe UI", Tahoma, sans-serif;
  --wrap: 1160px;
  --gutter: clamp(16px, 4vw, 48px);
  --band: clamp(64px, 9vw, 128px);
  /* Drawn the same in both directions, so they need no mirroring. */
  --check: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M3 8.5l3.2 3L13 4.5' fill='none' stroke='%23000' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  --chevron: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M3.5 6l4.5 4.5L12.5 6' fill='none' stroke='%23000' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");

  color-scheme: light dark;
}

@media (prefers-color-scheme: dark) {
  :root {
    --teal-deep: #002c34;
    --paper: #1d1e20;
    --surface: #26282b;
    --ink: #eef2f1;
    --muted: #a0aaa8;
    --line: #393c41;
    --link: #baefe3;
    --structure: #5cc4b4;
    --chat: #17342c;
    --pdf: #ff7d82;
  }
}

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

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  margin: 0;
  /* The footer stays at the bottom of a short page (the unsubscribe page). */
  min-block-size: 100svh;
  display: flex;
  flex-direction: column;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font);
  font-size: 1.125rem;
  font-weight: 400;
  line-height: 1.8;
  font-variant-numeric: tabular-nums;
  -webkit-font-smoothing: antialiased;
}
:lang(en) body,
body:lang(en) {
  line-height: 1.6;
}

h1,
h2,
h3,
p,
ol,
ul,
dl,
dd,
figure {
  margin: 0;
}

a {
  color: var(--link);
  text-underline-offset: 0.2em;
  text-decoration-thickness: 1px;
}
a:hover {
  text-decoration-thickness: 2px;
}
:focus-visible {
  outline: 3px solid var(--structure);
  outline-offset: 3px;
  border-radius: 4px;
}
.on-teal :focus-visible {
  outline-color: var(--mint);
}

main {
  flex: 1 0 auto;
}

.wrap {
  max-inline-size: var(--wrap);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

/* Teal: the header, the hero, the privacy policy's title, the price and the footer. */
.on-teal {
  background: var(--teal);
  color: var(--on-teal);
}
.on-teal a {
  color: var(--on-teal);
}

/* ---- Header ---------------------------------------------------------------------------- */

.site-header .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding-block: 20px;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-size: 1.3125rem;
  font-weight: 600;
  text-decoration: none;
  line-height: 1;
}
.brand img {
  inline-size: 40px;
  block-size: 40px;
  border-radius: 10px;
}
.lang {
  font-size: 1rem;
  font-weight: 500;
  text-decoration: none;
  padding: 8px 14px;
  border: 1px solid var(--on-teal-line);
  border-radius: 999px;
}
.lang:hover {
  border-color: var(--on-teal-muted);
}

/* ---- Buttons --------------------------------------------------------------------------- */

.button {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 14px 26px;
  border-radius: 12px;
  background: var(--orange);
  color: var(--on-orange);
  font-size: 1.125rem;
  font-weight: 600;
  line-height: 1.3;
  text-decoration: none;
}
.on-teal a.button {
  color: var(--on-orange);
}
button.button {
  border: 0;
  font-family: inherit;
  cursor: pointer;
}
.button:hover {
  background: #ff8c38;
}
.cta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 24px;
}
.cta-note {
  color: var(--on-teal-muted);
  font-size: 1rem;
}
.soon {
  display: inline-block;
  padding: 10px 18px;
  border-radius: 999px;
  background: rgb(115 252 215 / 0.14);
  color: var(--mint);
  font-size: 1rem;
  font-weight: 500;
}

/* ---- Hero ------------------------------------------------------------------------------ */

.hero {
  padding-block: clamp(32px, 6vw, 80px) clamp(56px, 8vw, 104px);
}
.hero h1 {
  font-size: clamp(2.5rem, 1.1rem + 5.4vw, 5rem);
  font-weight: 700;
  line-height: 1.22;
  max-inline-size: 17ch;
  text-wrap: balance;
}
.hero h1:lang(en) {
  line-height: 1.08;
  letter-spacing: -0.02em;
  max-inline-size: 15ch;
}
.lede {
  margin-block-start: 24px;
  max-inline-size: 46ch;
  font-size: clamp(1.125rem, 1rem + 0.5vw, 1.3125rem);
  color: var(--on-teal-muted);
}
.hero .cta {
  margin-block-start: 36px;
}

/* ---- The runway ---------------------------------------------------------------------------
   One time axis for every row: today at the start, an order placed today arriving at the
   middle (the scale is twice the lead time, as in the dashboard). A bar is how long a
   product's stock lasts; the question is whether it crosses the line. */

.runway {
  --lead: 0.5;
  margin-block-start: clamp(56px, 8vw, 96px);
  display: grid;
  grid-template-columns:
    [name-start] minmax(9rem, 15rem)
    [name-end bar-start] minmax(0, 1fr)
    [bar-end act-start] minmax(8.5rem, auto)
    [act-end];
  grid-template-rows: auto auto auto;
  column-gap: clamp(16px, 3vw, 40px);
}
.runway-head,
.runway-axis {
  grid-column: bar;
  position: relative;
  font-size: 0.875rem;
  color: var(--on-teal-muted);
  line-height: 1.5;
}
.runway-head {
  grid-row: 1;
  display: flex;
  padding-block-end: 14px;
}
.runway-arrival {
  position: absolute;
  inset-block-start: 0;
  inset-inline-start: calc(var(--lead) * 100%);
  padding-inline-start: 10px;
  color: var(--on-teal);
  font-weight: 500;
  white-space: nowrap;
}
.runway-rows {
  grid-column: 1 / -1;
  grid-row: 2;
  display: grid;
  grid-template-columns: subgrid;
  list-style: none;
  padding: 0;
  position: relative;
  z-index: 1;
}
.runway-row {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: subgrid;
  align-items: center;
  padding-block: 16px;
  border-block-start: 1px solid var(--on-teal-line);
}
.runway-row:last-child {
  border-block-end: 1px solid var(--on-teal-line);
}
.runway-name {
  grid-column: name;
  font-weight: 500;
  line-height: 1.4;
}
.runway-track {
  grid-column: bar;
  min-inline-size: 0;
}
.runway-bar {
  display: block;
  block-size: 12px;
  border-radius: 6px;
  background: rgb(255 255 255 / 0.1);
  overflow: hidden;
}
.runway-fill {
  display: block;
  block-size: 100%;
  inline-size: calc(var(--len) * 100%);
  border-radius: inherit;
  background: var(--state);
}
.runway-cover {
  display: block;
  margin-block-start: 6px;
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--state-text);
  line-height: 1.5;
}
.runway-act {
  grid-column: act;
  justify-self: end;
  font-size: 0.9375rem;
  line-height: 1.4;
  white-space: nowrap;
}
.is-short {
  --state: var(--red);
  --state-text: var(--red-text);
}
.is-due {
  --state: var(--orange);
  --state-text: #ffb27a;
}
.is-fine {
  --state: var(--mint);
  --state-text: var(--mint);
}
.is-short .runway-act,
.is-due .runway-act {
  padding: 6px 12px;
  border-radius: 8px;
  background: var(--orange);
  color: var(--on-orange);
  font-weight: 600;
}
.is-fine .runway-act {
  color: var(--on-teal-muted);
}

/* The line every bar is measured against, from its label through the rows. */
.runway-line {
  grid-column: bar;
  grid-row: 1 / 3;
  position: relative;
  z-index: 2;
  pointer-events: none;
}
.runway-line::before {
  content: "";
  position: absolute;
  inset-block: 0;
  inset-inline-start: calc(var(--lead) * 100%);
  border-inline-start: 2px solid var(--on-teal);
}

/* The next Saudi season, when it falls inside the axis: a band behind the bars. */
.runway-season {
  grid-column: bar;
  grid-row: 2 / -1;
  position: relative;
  pointer-events: none;
}
.runway-season::before {
  content: "";
  position: absolute;
  inset-block: 0;
  inset-inline-start: calc(var(--from) * 100%);
  inline-size: calc((var(--to) - var(--from)) * 100%);
  background: rgb(115 252 215 / 0.08);
  border-inline: 1px dashed rgb(115 252 215 / 0.45);
}
.runway-axis {
  grid-row: 3;
  padding-block-start: 10px;
}
.runway-axis span {
  display: block;
  margin-inline-start: min(calc(var(--from) * 100%), calc(100% - 10em));
  padding-inline-start: 8px;
  color: var(--mint);
}
.runway-caption {
  margin-block-start: 20px;
  font-size: 0.875rem;
  color: var(--on-teal-muted);
  max-inline-size: 60ch;
}

/* One moment on load: the bars run out, the line drops in, then each bar takes its colour. */
@media (prefers-reduced-motion: no-preference) {
  .runway-fill {
    animation:
      runway-grow 0.9s cubic-bezier(0.2, 0.7, 0.2, 1) calc(0.15s + var(--i) * 0.09s) both,
      runway-state 0.35s ease 1.35s both;
  }
  .runway-line::before {
    transform-origin: top;
    animation: runway-drop 0.4s cubic-bezier(0.3, 0.7, 0.3, 1) 1s both;
  }
  .runway-cover,
  .runway-act,
  .runway-arrival {
    animation: runway-appear 0.4s ease 1.45s both;
  }
  .runway-arrival {
    animation-delay: 1.1s;
  }
}
@keyframes runway-grow {
  from {
    inline-size: 0;
  }
}
@keyframes runway-state {
  from {
    background-color: rgb(255 255 255 / 0.55);
  }
}
@keyframes runway-drop {
  from {
    transform: scaleY(0);
  }
}
@keyframes runway-appear {
  from {
    opacity: 0;
  }
}

/* ---- Bands ----------------------------------------------------------------------------- */

.band {
  padding-block: var(--band);
}
.band-surface {
  background: var(--surface);
}
.band h2 {
  font-size: clamp(1.875rem, 1.2rem + 2.2vw, 2.875rem);
  font-weight: 650;
  line-height: 1.3;
  text-wrap: balance;
}
.band h2:lang(en) {
  line-height: 1.15;
  letter-spacing: -0.015em;
}
.band h3 {
  font-size: 1.3125rem;
  font-weight: 600;
  line-height: 1.45;
}
:where(.band) p + p {
  margin-block-start: 12px;
}
.muted {
  color: var(--muted);
}
.small {
  font-size: 0.9375rem;
}

/* ---- From your sales to your supplier: a real sequence, so its steps are numbered ---------- */

.steps {
  list-style: none;
  padding: 0;
  margin-block-start: clamp(40px, 6vw, 72px);
  position: relative;
}
.steps::before {
  content: "";
  position: absolute;
  inset-block: 24px;
  inset-inline-start: 23px;
  border-inline-start: 2px solid var(--line);
}
.step {
  position: relative;
  display: grid;
  grid-template-columns: 48px minmax(0, 25rem) minmax(0, 1fr);
  column-gap: clamp(20px, 4vw, 64px);
  row-gap: 24px;
  align-items: start;
}
.step + .step {
  margin-block-start: clamp(48px, 7vw, 88px);
}
.step-n {
  inline-size: 48px;
  block-size: 48px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: var(--paper);
  border: 2px solid var(--structure);
  color: var(--link);
  font-size: 1.125rem;
  font-weight: 600;
  line-height: 1;
}
.step-text h3 {
  padding-block-start: 6px;
}
.step-text p {
  margin-block-start: 8px;
  color: var(--muted);
}
.step-art {
  min-inline-size: 0;
}

/* Step 1: four weeks of sales, with the stockout days left out. */
.strip {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 24px;
}
.strip-days {
  display: grid;
  grid-template-columns: repeat(28, minmax(0, 1fr));
  gap: 3px;
  align-items: end;
  block-size: 88px;
}
.strip-day {
  display: block;
  block-size: max(3px, calc(var(--v) / 3 * 100%));
  border-radius: 3px 3px 1px 1px;
  background: var(--structure);
}
.strip-day.is-zero {
  background: var(--line);
}
.strip-out {
  grid-column: span 6;
  align-self: stretch;
  display: grid;
  place-items: center;
  border-radius: 6px;
  background: repeating-linear-gradient(135deg, var(--line) 0 2px, transparent 2px 8px);
  border: 1px solid var(--line);
  color: var(--muted);
  font-size: 0.8125rem;
  font-weight: 500;
}
.strip-out span {
  background: var(--surface);
  padding-inline: 6px;
  border-radius: 4px;
  line-height: 1.6;
}
.strip-ends {
  display: flex;
  justify-content: space-between;
  margin-block-start: 8px;
  font-size: 0.8125rem;
  color: var(--muted);
}
.strip figcaption {
  margin-block-start: 16px;
  padding-block-start: 16px;
  border-block-start: 1px solid var(--line);
  font-size: 1rem;
}

/* Step 2: the "why", as the product page writes it. */
.why {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 16px;
  padding-inline: 24px;
}
.why div {
  padding-block: 16px;
}
.why div + div {
  border-block-start: 1px solid var(--line);
}
.why dt {
  font-weight: 600;
  font-size: 1rem;
}
.why dd {
  color: var(--muted);
  font-size: 1rem;
}

/* Step 3: the WhatsApp message, as the supplier gets it. */
.chat {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 8px;
}
.chat-file,
.chat-bubble {
  max-inline-size: 30rem;
  inline-size: 100%;
  background: var(--chat);
  border-radius: 16px;
  border-start-end-radius: 4px;
}
.chat-file {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 16px;
  font-size: 0.9375rem;
  font-weight: 500;
}
.chat-file::before {
  content: "PDF";
  flex: none;
  display: grid;
  place-items: center;
  inline-size: 40px;
  block-size: 48px;
  border-radius: 6px;
  background: var(--surface);
  color: var(--pdf);
  font-size: 0.6875rem;
  font-weight: 700;
  letter-spacing: 0.04em;
}
.chat-bubble {
  padding: 16px 18px;
  font-size: 0.9375rem;
  line-height: 1.75;
  white-space: pre-line;
}
.chat-label {
  white-space: nowrap;
}
.chat-link {
  color: var(--link);
  text-decoration: underline;
  text-underline-offset: 0.2em;
}

/* ---- Seasons --------------------------------------------------------------------------- */

.split {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr);
  gap: clamp(40px, 7vw, 112px);
  align-items: start;
}
.split p {
  margin-block-start: 16px;
}
.seasons-list {
  list-style: none;
  padding: 0;
  border-block-start: 2px solid var(--ink);
}
.seasons-list li {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  column-gap: 16px;
  padding-block: 18px;
  border-block-end: 1px solid var(--line);
}
.season-name {
  grid-column: 1;
  grid-row: 1;
  font-weight: 600;
  font-size: 1.125rem;
}
.season-dates {
  grid-column: 1;
  grid-row: 2;
  color: var(--muted);
  font-size: 0.9375rem;
}
.season-in {
  grid-column: 2;
  grid-row: 1 / span 2;
  align-self: center;
  font-weight: 500;
  white-space: nowrap;
}
.season-in.is-now {
  color: var(--link);
}

/* ---- Money and privacy ----------------------------------------------------------------- */

.pair {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(48px, 7vw, 112px);
}
.pair h2 {
  font-size: clamp(1.625rem, 1.2rem + 1.3vw, 2.25rem);
}
.pair p {
  margin-block-start: 16px;
}
.quote {
  margin-block-start: 28px;
  padding-inline-start: 20px;
  border-inline-start: 4px solid var(--structure);
}
.quote strong {
  display: block;
  font-size: 1.5rem;
  font-weight: 650;
  line-height: 1.4;
}
.quote span {
  display: block;
  margin-block-start: 4px;
  color: var(--muted);
  font-size: 0.9375rem;
}
.go {
  display: inline-block;
  margin-block-start: 20px;
  font-weight: 600;
}

/* ---- FAQ ------------------------------------------------------------------------------- */

.faq {
  max-inline-size: 48rem;
}
.faq-list {
  margin-block-start: 32px;
  border-block-start: 1px solid var(--line);
}
.faq details {
  border-block-end: 1px solid var(--line);
}
.faq summary {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  padding-block: 20px;
  font-weight: 600;
  cursor: pointer;
  list-style: none;
}
.faq summary::-webkit-details-marker {
  display: none;
}
.faq summary::after {
  content: "";
  flex: none;
  inline-size: 16px;
  block-size: 16px;
  background: currentColor;
  -webkit-mask: var(--chevron) center / contain no-repeat;
  mask: var(--chevron) center / contain no-repeat;
  transition: transform 0.2s ease;
}
.faq details[open] summary::after {
  transform: rotate(180deg);
}
.faq-list p {
  padding-block-end: 20px;
  color: var(--muted);
  max-inline-size: 62ch;
}

/* ---- Price ----------------------------------------------------------------------------- */

.price {
  padding-block: var(--band);
}
.price h2 {
  font-size: clamp(2rem, 1.1rem + 3.4vw, 3.75rem);
  font-weight: 700;
  line-height: 1.25;
  max-inline-size: 18ch;
  text-wrap: balance;
}
.price h2:lang(en) {
  line-height: 1.1;
  letter-spacing: -0.02em;
}
.price-body {
  margin-block-start: 20px;
  color: var(--on-teal-muted);
}
.features {
  list-style: none;
  padding: 0;
  margin-block-start: 24px;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px 48px;
  max-inline-size: 52rem;
}
.features li {
  position: relative;
  padding-inline-start: 28px;
}
.features li::before {
  content: "";
  position: absolute;
  inset-inline-start: 0;
  inset-block-start: 0.4em;
  inline-size: 18px;
  block-size: 18px;
  background: var(--mint);
  -webkit-mask: var(--check) center / contain no-repeat;
  mask: var(--check) center / contain no-repeat;
}
.price .cta {
  margin-block-start: 40px;
}

/* ---- Footer ---------------------------------------------------------------------------- */

.site-footer {
  background: var(--teal-deep);
  color: var(--on-teal-muted);
  font-size: 0.9375rem;
}
.site-footer a {
  color: var(--on-teal);
}
.site-footer .wrap {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: flex-start;
  gap: 24px 48px;
  padding-block: 40px 48px;
}
.site-footer .brand {
  color: var(--on-teal);
}
.footer-about p {
  margin-block-start: 14px;
  max-inline-size: 52ch;
}
.footer-links {
  list-style: none;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 8px 28px;
}

/* ---- Unsubscribe: one short message, its outcome as the headline ---------------------- */

.notice {
  padding-block: clamp(40px, 7vw, 96px) clamp(64px, 10vw, 128px);
}
.notice h1 {
  font-size: clamp(2rem, 1.2rem + 3vw, 3.5rem);
  font-weight: 700;
  line-height: 1.3;
  max-inline-size: 18ch;
  text-wrap: balance;
}
.notice h1:lang(en) {
  line-height: 1.12;
  letter-spacing: -0.02em;
}
.notice p {
  margin-block-start: 16px;
  max-inline-size: 46ch;
  color: var(--on-teal-muted);
  font-size: clamp(1.125rem, 1rem + 0.4vw, 1.25rem);
}
.notice form {
  margin-block-start: 32px;
}
.notice.is-done h1::before {
  content: "";
  display: block;
  inline-size: 56px;
  block-size: 56px;
  margin-block-end: 24px;
  border-radius: 50%;
  background:
    var(--mint)
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M3 8.5l3.2 3L13 4.5' fill='none' stroke='%2300353f' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E")
    center / 28px no-repeat;
}

/* ---- Privacy policy -------------------------------------------------------------------- */

.doc-head {
  padding-block: clamp(24px, 4vw, 48px) clamp(48px, 6vw, 72px);
}
.doc-head h1 {
  font-size: clamp(2rem, 1.2rem + 3vw, 3.5rem);
  font-weight: 700;
  line-height: 1.3;
  max-inline-size: 18ch;
  text-wrap: balance;
}
.doc-head h1:lang(en) {
  line-height: 1.12;
  letter-spacing: -0.02em;
}
.doc-head p {
  margin-block-start: 16px;
  color: var(--on-teal-muted);
}
.doc-head .doc-intro {
  max-inline-size: 58ch;
  color: var(--on-teal);
  font-size: clamp(1.125rem, 1rem + 0.4vw, 1.25rem);
}
.doc {
  display: grid;
  grid-template-columns: minmax(0, 15rem) minmax(0, 44rem);
  gap: clamp(40px, 6vw, 96px);
  padding-block: clamp(48px, 7vw, 88px) var(--band);
}
.toc {
  position: sticky;
  inset-block-start: 24px;
  align-self: start;
}
.toc ol {
  list-style: none;
  padding: 0;
  border-inline-start: 2px solid var(--line);
}
.toc a {
  display: block;
  padding-block: 7px;
  padding-inline-start: 16px;
  margin-inline-start: -2px;
  border-inline-start: 2px solid transparent;
  color: var(--muted);
  font-size: 0.9375rem;
  line-height: 1.5;
  text-decoration: none;
}
.toc a:hover {
  color: var(--ink);
  border-inline-start-color: var(--structure);
}
.doc-body section {
  scroll-margin-block-start: 24px;
}
.doc-body section + section {
  margin-block-start: 48px;
  padding-block-start: 48px;
  border-block-start: 1px solid var(--line);
}
.doc-body h2 {
  font-size: 1.5rem;
  font-weight: 650;
  line-height: 1.4;
  margin-block-end: 12px;
}
.doc-body ul {
  padding-inline-start: 1.25em;
}
.doc-body p + p,
.doc-body ul + p,
.doc-body p + ul {
  margin-block-start: 12px;
}
.doc-body li + li {
  margin-block-start: 8px;
}
.doc-body li::marker {
  color: var(--structure);
}

/* ---- Narrow screens -------------------------------------------------------------------- */

@media (max-width: 900px) {
  .split,
  .pair,
  .doc {
    grid-template-columns: minmax(0, 1fr);
  }
  .toc {
    position: static;
  }
  .step {
    grid-template-columns: 48px minmax(0, 1fr);
  }
  .step-art {
    grid-column: 2;
  }
}

@media (max-width: 640px) {
  body {
    font-size: 1.0625rem;
  }
  .runway {
    grid-template-columns: [name-start bar-start] minmax(0, 1fr) [name-end act-start] auto [act-end
        bar-end];
    column-gap: 12px;
  }
  .runway-row {
    grid-template-rows: auto auto;
    row-gap: 12px;
  }
  .runway-name,
  .runway-act {
    grid-row: 1;
  }
  .runway-track {
    grid-row: 2;
  }
  .runway-arrival {
    white-space: normal;
    max-inline-size: 50%;
  }
  .runway-head {
    min-block-size: 3.5em;
  }
  /* The artifacts take the full width here, so the spine would run through them. */
  .steps::before {
    display: none;
  }
  .step {
    grid-template-columns: 40px minmax(0, 1fr);
    column-gap: 16px;
  }
  .step-n {
    inline-size: 40px;
    block-size: 40px;
  }
  .step-art {
    grid-column: 1 / -1;
  }
  .strip {
    padding: 16px;
  }
  .features {
    grid-template-columns: minmax(0, 1fr);
  }
}
