/* Illuminated notebook: botanical green, quiet paper, expressive margins.
   Explicit body/root scope preserves precedence when Astro extracts shared CSS. */
html:root {
  --ink: #263d2e; --ink-soft: #56634f; --ink-faint: #6c7665;
  --cream: #f0f2e7; --cream-2: #e5ebdc; --raise: #f8f9f1;
  --hairline: #d3dccb; --hairline-strong: #acbca3;
  --botanical: #38684a; --botanical-dark: #203d2d; --sage: #bfd0b3;
  --gold: #936c32; --gold-bright: #cca95b; --teal: #38684a; --teal-ink: #315e43;
  --rust: #a45b43; --rust-ink: #8a4936;
  --urizen-ink: var(--ink); --urizen-ink-soft: var(--ink-soft);
  --urizen-cream: var(--cream); --urizen-parchment: var(--cream-2);
  --urizen-gold: var(--gold); --urizen-teal: var(--teal); --urizen-hairline: var(--hairline);
}
::selection { background: #c9d9bd; color: #203d2d; }
body.urizen-theme .site-header, body.urizen-theme .site-header.is-stuck { background: #203d2df5; border-bottom-color: #49634b; }
body.urizen-theme .site-footer, body.urizen-theme .closing-band { background: var(--botanical-dark); }
body.urizen-theme .site-nav a { font-family: var(--font-sans); text-transform: none; letter-spacing: 0; }
body.urizen-theme .button { border-radius: 3px; }
body.urizen-theme .button.primary, body.urizen-theme .hero .button.primary { background: var(--botanical); color: var(--cream); border-color: var(--botanical); box-shadow: none; }
body.urizen-theme .button.primary:hover, body.urizen-theme .hero .button.primary:hover { background: var(--botanical-dark); }
body.urizen-theme .button.secondary { background: transparent; color: var(--ink); border-color: var(--hairline-strong); }
body.urizen-theme .chapter-rail { mix-blend-mode: normal; }
body.urizen-theme .chapter-rail a { color: var(--ink-soft); opacity: .85; }
body.urizen-theme .chapter-rail a.is-committed { color: var(--botanical); }
body.urizen-theme.notebook-home .site-header, body.urizen-theme.notebook-home .site-header.is-stuck { background: #f0f2e7f5; border-bottom-color: var(--hairline); }
body.urizen-theme.notebook-home .site-header .site-nav a { color: var(--ink-soft); }
body.urizen-theme.notebook-home .site-header .site-nav a:hover, body.urizen-theme.notebook-home .site-header .site-nav a:focus-visible { color: var(--botanical-dark); background: var(--cream-2); }
body.urizen-theme.notebook-home .site-header .request-link { color: var(--botanical); border-color: var(--hairline-strong); border-radius: 3px; }
body.urizen-theme.notebook-home .hero { background: var(--cream); color: var(--ink); padding-block: clamp(48px, 7vw, 96px); }
body.urizen-theme.notebook-home .hero::before, body.urizen-theme.notebook-home .hero::after { display: none; }
body.urizen-theme.notebook-home .hero-inner { gap: clamp(28px, 4vw, 64px); grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr); }
body.urizen-theme.notebook-home .hero h1 { color: var(--ink); font-size: clamp(39px, 4.5vw, 64px); line-height: 1.1; }
body.urizen-theme.notebook-home .hero h1 em { color: var(--botanical); }
body.urizen-theme.notebook-home .hero-copy { color: var(--ink-soft); font-size: 17px; line-height: 1.75; max-width: 53ch; }
body.urizen-theme.notebook-home .hero .lab-caption { color: var(--ink-soft); font-size: 13px; max-width: 53ch; }
body.urizen-theme.notebook-home .hero .button.secondary { color: var(--ink); border-color: var(--hairline-strong); }
body.urizen-theme.notebook-home .hero .button.secondary:hover { background: var(--cream-2); border-color: var(--botanical); }
body.urizen-theme.notebook-home .hero .proof-tags { gap: 8px 20px; margin-block: 26px; }
body.urizen-theme.notebook-home .hero .proof-tags span { border: 0; padding: 0; background: none; color: var(--ink-soft); font-size: 12px; }
.notebook-figure { min-width: 0; margin: 0; position: relative; }
.notebook-illustration { display: block; width: 100%; max-width: 470px; margin-inline: auto; height: auto; transition: transform 350ms ease; }
.notebook-figure:hover .notebook-illustration { transform: translateY(-4px) rotate(-.6deg); }
.notebook-note { display: block; margin: 12px 0 26px; color: var(--botanical); font-family: var(--font-display); font-size: 20px; font-style: italic; font-weight: 400; transform: rotate(-2deg); }
.notebook-figure .notebook-note { text-align: center; margin: -8px 0 26px; }
.notebook-questions { max-width: 380px; margin-inline: auto; padding-block: 12px; border-top: 1px solid var(--hairline-strong); color: var(--ink-soft); font-size: 13px; }
.notebook-questions summary { color: var(--botanical); cursor: pointer; min-height: 30px; }
.notebook-questions ul { padding-left: 18px; line-height: 1.9; margin: 8px 0; }
body.urizen-theme.notebook-home .section.paper { background-image: radial-gradient(#b4c2ac66 .6px, transparent .8px); background-size: 26px 26px; }
body.urizen-theme.notebook-home .research-grid .stack-card { border: 0; border-top: 1px solid var(--hairline-strong); border-radius: 0; box-shadow: none; background: transparent; padding: 26px 12px 0 0; }
body.urizen-theme.notebook-home .research-grid .stack-card:hover { transform: none; }
body.urizen-theme.notebook-home .research-grid .stack-index { border-radius: 49% 43% 52% 45%; transform: rotate(-4deg); padding: 5px 9px; color: var(--botanical); border-color: var(--hairline-strong); }
body.urizen-theme.notebook-home .section-heading h2::after { background: var(--botanical); height: 1px; transform: rotate(-1deg); }
body.urizen-theme.notebook-home .manifesto-band { min-height: 0; padding: 72px var(--gutter); background: var(--cream-2); color: var(--ink); }
body.urizen-theme.notebook-home .manifesto-band::before, body.urizen-theme.notebook-home .manifesto-band::after { display: none; }
body.urizen-theme.notebook-home .manifesto-line { color: var(--ink); font-size: clamp(26px, 3.3vw, 42px); }
body.urizen-theme.notebook-home .manifesto-line em { color: var(--botanical); }
body.urizen-theme.notebook-home .manifesto-tag { color: var(--ink-soft); }
body.urizen-theme.notebook-home .manifesto-diamond { background: var(--botanical); width: 9px; height: 9px; }
body.urizen-theme.notebook-home .lab-products { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 56px; counter-reset: product; }
body.urizen-theme.notebook-home .lab-products .system-card { grid-column: auto; position: relative; border: 0; border-top: 1px solid var(--hairline-strong); border-radius: 0; background: transparent; box-shadow: none; padding: 30px 8px 34px 46px; counter-increment: product; }
body.urizen-theme.notebook-home .lab-products .system-card:last-child { grid-column: 1 / -1; max-width: 680px; }
body.urizen-theme.notebook-home .lab-products .system-card::before { content: '0' counter(product); position: absolute; left: 0; top: 31px; color: var(--botanical); font-family: var(--font-display); font-style: italic; font-size: 18px; }
body.urizen-theme.notebook-home .lab-products .system-card:hover { background: var(--cream-2); transform: none; }
body.urizen-theme.notebook-home .lab-products .system-card h3 { color: var(--ink); }
body.urizen-theme.notebook-home .system-link { color: var(--botanical); }
body.urizen-theme.notebook-home .product-label h2 { color: var(--botanical); }
body.urizen-theme.notebook-home .product-status { border-top-style: dashed; }
body.urizen-theme.notebook-home .evidence-section .system-card { border-radius: 3px; box-shadow: none; background: var(--raise); }
body.urizen-theme .closing-inner .button.primary { background: var(--cream); color: var(--botanical-dark); border-color: var(--cream); }
body.urizen-theme .closing-inner .button.primary:hover { background: var(--sage); }
body.urizen-theme .gate { background: var(--botanical-dark); }
.gate-field { opacity: .2; }
.gate-wordmark { filter: none; }
@media (max-width: 1080px) {
  body.urizen-theme .chapter-rail { background: var(--cream); border-bottom-color: var(--hairline); }
}
@media (max-width: 760px) {
  body.urizen-theme.notebook-home .hero-inner { grid-template-columns: minmax(0, 1fr); gap: 28px; }
  .notebook-figure { max-width: 430px; width: 100%; margin-inline: auto; }
  body.urizen-theme.notebook-home .lab-products { grid-template-columns: minmax(0, 1fr); gap: 0; }
  body.urizen-theme.notebook-home .hero h1 { font-size: clamp(36px, 6.5vw, 49px); }
  body.urizen-theme.notebook-home .hero-copy { font-size: 16px; }
}
@media (prefers-reduced-motion: reduce) {
  .notebook-illustration { transition: none; }
  .notebook-figure:hover .notebook-illustration { transform: none; }
}

body.urizen-theme.notebook-home .hero .urizen-kicker { color: var(--ink-soft); }

/* Paper fibres and translucent pigment carry the notebook into every page. */
body.urizen-theme {
  background-color: var(--cream);
  background-image: url('/assets/notebook-grain.svg'), radial-gradient(ellipse at 2% 18%, #95b87a14, transparent 48%), radial-gradient(ellipse at 100% 82%, #d5b57612, transparent 42%);
  background-size: 180px 180px, 100% 1200px, 100% 1400px;
}
body.urizen-theme.notebook-home .hero {
  background-color: var(--cream);
  background-image: url('/assets/notebook-grain.svg'), radial-gradient(ellipse at 90% 44%, #8ea77e2a, transparent 47%), radial-gradient(ellipse at 0 90%, #d7bb8518, transparent 43%);
  background-size: 180px 180px, auto, auto;
}
body.urizen-theme.notebook-home .section.paper {
  background-image: url('/assets/notebook-grain.svg'), radial-gradient(#9eb38b55 .65px, transparent .8px), radial-gradient(ellipse at 10% 35%, #9ab38312, transparent 70%);
  background-size: 180px 180px, 26px 26px, auto;
}
body.urizen-theme .page-hero { position: relative; }
body.urizen-theme .page-hero::after {
  content: ''; display: block; width: 90px; height: 10px; margin-top: 26px;
  border-top: 1.5px solid var(--botanical); border-radius: 50%; transform: rotate(-3deg); opacity: .7;
}
body.urizen-theme .notebook-note { text-shadow: .35px .2px #38684a25; }
body.urizen-theme .notebook-note::after {
  content: ''; display: inline-block; width: 32px; height: 8px; margin-left: 11px;
  border-top: 1px solid var(--rust); border-radius: 50%; transform: rotate(-10deg); opacity: .65;
}
body.urizen-theme.notebook-home .manifesto-band {
  background-image: url('/assets/notebook-grain.svg'), radial-gradient(ellipse at 45% 120%, #a6bd935c, transparent 70%);
  background-size: 180px 180px, auto;
}
body.urizen-theme .site-footer, body.urizen-theme .closing-band {
  background-image: url('/assets/notebook-grain.svg'), radial-gradient(ellipse at 80% 0, #607e4033, transparent 65%);
  background-size: 180px 180px, auto;
}
/* Open Sanctuary: live type and controls around an architectural study.
   Native dialog owns modality, focus containment, and Escape. */
body.urizen-theme dialog.reason-gate {
  position: fixed; inset: 0; width: 100%; max-width: none; height: 100dvh; max-height: none;
  margin: 0; padding: 27px clamp(24px, 5vw, 84px) 15px; border: 0; overflow: auto;
  color: #eef2e5; background-color: #18392e;
  background-image: url('/assets/notebook-grain.svg'), radial-gradient(ellipse at 58% 44%, #68826524, transparent 62%), linear-gradient(125deg, #122e26, #1f4234);
  background-size: 180px 180px, auto, auto; isolation: isolate;
  transition: opacity 650ms ease; transform: none;
}
body.urizen-theme dialog.reason-gate:not([open]) { display: none; }
body.urizen-theme dialog.reason-gate[open] { display: grid; grid-template-rows: auto minmax(0, 1fr) auto; gap: 0; }
.reason-gate::backdrop { background: #18392e; }
body.urizen-theme .reason-gate::after { content: none; }
.reason-gate .threshold-top, .reason-gate .threshold-bottom { position: relative; z-index: 2; display: flex; align-items: center; justify-content: space-between; gap: 20px; width: 100%; }
.reason-gate .threshold-top { border-bottom: 1px solid #c0d2ab30; padding-bottom: 20px; }
.reason-gate .threshold-brand { display: flex; align-items: center; gap: 13px; }
.reason-gate .threshold-brand img:first-child { width: 25px; height: 34px; }
.reason-gate .threshold-brand > .threshold-tag { color: #c0ccb6; font: 10px var(--font-mono); letter-spacing: .1em; text-transform: uppercase; border-left: 1px solid #c0d2ab40; padding-left: 16px; margin-left: 4px; }
.reason-gate .threshold-edition { color: #c1ceb9; font: 10px var(--font-mono); letter-spacing: .09em; text-transform: uppercase; }
.reason-gate .threshold-edition i { color: #d3ad73; font-style: normal; margin: 0 16px; }
.reason-gate .threshold-content { position: relative; width: min(1400px, 100%); min-width: 0; min-height: 540px; margin: auto; display: grid; grid-template-columns: .95fr 1.05fr; align-items: center; }
.reason-gate .threshold-copy { position: relative; z-index: 2; padding: 36px 0 90px; }
.reason-gate .threshold-kicker { color: #bfceb6; font: 10px/1.6 var(--font-mono); letter-spacing: .12em; text-transform: uppercase; margin: 0 0 27px; }
.reason-gate .threshold-kicker > span { display: inline-block; color: #d6b473; font-size: 22px; vertical-align: middle; margin-right: 10px; }
.reason-gate #threshold-title { color: #eef2e5; font: 400 clamp(45px, 5.8vw, 88px)/1.04 var(--font-display); letter-spacing: -.04em; margin: 0; }
.reason-gate #threshold-title em { color: #d9be8a; font-weight: 400; }
.reason-gate #threshold-description { color: #cad4c0; font: 15px/1.85 var(--font-sans); margin: 28px 0 31px; }
.reason-gate .threshold-enter { background: #e7ebdb; color: #234232; border-radius: 2px; border: 1px solid #e7ebdb; padding: 0 14px 0 25px; min-height: 54px; gap: 39px; font-size: 13px; font-weight: 500; box-shadow: none; }
.reason-gate .threshold-enter > span { display: grid; place-items: center; border-left: 1px solid #385b4030; min-width: 31px; min-height: 24px; font-size: 22px; font-weight: 400; padding-left: 11px; transition: transform 220ms ease; }
.reason-gate .threshold-enter:hover, .reason-gate .threshold-enter:focus-visible { background: #f5f2e3; box-shadow: 0 8px 30px #101f2426; transform: translateY(-2px); }
.reason-gate .threshold-enter:hover > span { transform: translate(2px, -2px); }
.reason-gate button:focus-visible { outline: 2px solid #d7b77e; outline-offset: 5px; }
.reason-gate .threshold-margin { display: flex; align-items: center; gap: 10px; position: absolute; left: 184px; bottom: 14px; transform: rotate(-6deg); color: #d7b77e; font: italic 21px/1.2 var(--font-display); }
.reason-gate .threshold-margin svg { width: 68px; height: 38px; stroke: currentColor; stroke-width: 1.2; stroke-linecap: round; }
.reason-gate .sanctuary-stage { position: relative; margin: 0 -24px 0 0; width: calc(100% + 24px); height: clamp(540px, calc(100dvh - 150px), 1000px); min-width: 0; }
.reason-gate .sanctuary-art { position: absolute; inset: 0; transform-origin: 50% 64%; transition: transform 650ms cubic-bezier(.25,.65,.2,1); }
.reason-gate .sanctuary-image { width: auto; max-width: 100%; height: 100%; object-fit: contain; display: block; margin-inline: auto; mask-image: linear-gradient(90deg, transparent, #000 14%, #000 86%, transparent), linear-gradient(0deg, transparent, #000 10%, #000 96%, transparent); mask-composite: intersect; }
.reason-gate .sanctuary-drawing { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; }
.reason-gate .sanctuary-measure { stroke: #c6d3b5; stroke-width: .65; opacity: .23; }
.reason-gate .sanctuary-los { stroke: #d4ad70; stroke-width: 1.1; stroke-linecap: round; stroke-dasharray: 1; stroke-dashoffset: 0; opacity: .64; animation: sanctuary-line 2600ms ease-out both; }
.reason-gate .sanctuary-los-second { stroke: #ce926e; stroke-width: .75; opacity: .5; animation-duration: 3100ms; }
.reason-gate .sanctuary-label { position: absolute; color: #c9d0ba; font: 9px var(--font-mono); letter-spacing: .035em; display: flex; align-items: center; gap: 8px; }
.reason-gate .sanctuary-label i { width: 22px; height: 1px; background: #bdcba168; }
.reason-gate .sanctuary-label-light { top: 25%; left: 4%; }
.reason-gate .sanctuary-label-tree { top: 64%; right: 0; }
.reason-gate .sanctuary-caption { position: absolute; left: 0; right: 0; bottom: 0; text-align: center; color: #bccab0; font: italic 13px var(--font-display); }
.reason-gate .sanctuary-caption > span { font: 9px var(--font-mono); letter-spacing: .08em; text-transform: uppercase; color: #d9bd87; padding-right: 13px; margin-right: 12px; border-right: 1px solid #bdcba140; }
.reason-gate .threshold-bottom { min-height: 52px; border-top: 1px solid #c0d2ab30; color: #b9c8ae; }
.reason-gate .threshold-disciplines { font: 9px/1.7 var(--font-mono); letter-spacing: .1em; text-transform: uppercase; }
.reason-gate .threshold-disciplines i { color: #d7b77e; padding: 0 12px; font-style: normal; }
.reason-gate .threshold-skip { min-height: 44px; padding: 0; color: #c2cdb7; text-transform: none; font: 12px var(--font-sans); letter-spacing: 0; }
.reason-gate .threshold-skip span { margin-left: 9px; color: #d7b77e; }
.reason-gate .threshold-skip:hover, .reason-gate .threshold-skip:focus-visible { color: #f2f1e4; }
.reason-gate .threshold-copy, .reason-gate .threshold-top, .reason-gate .threshold-bottom, .reason-gate .sanctuary-drawing, .reason-gate .sanctuary-label, .reason-gate .sanctuary-caption { transition: opacity 280ms ease, translate 650ms ease; }
body.urizen-theme dialog.reason-gate.is-departing { opacity: 0; pointer-events: none; }
.reason-gate.is-departing .sanctuary-art { transform: scale(1.28); }
.reason-gate.is-departing .threshold-copy { opacity: 0; translate: -16px 0; }
.reason-gate.is-departing .threshold-top, .reason-gate.is-departing .threshold-bottom, .reason-gate.is-departing .sanctuary-drawing, .reason-gate.is-departing .sanctuary-label, .reason-gate.is-departing .sanctuary-caption { opacity: 0; }
.reason-gate.is-departing::backdrop { opacity: 0; transition: opacity 650ms ease; }
@keyframes sanctuary-line { from { stroke-dashoffset: 1; opacity: 0; } to { stroke-dashoffset: 0; } }
@media (max-width: 1000px) {
  .reason-gate .threshold-brand > .threshold-tag { display: none; }
  .reason-gate .threshold-margin { left: 115px; }
  .reason-gate .sanctuary-label { font-size: 8px; }
  .reason-gate .sanctuary-label-light { left: -1%; }
  .reason-gate .sanctuary-label-tree { right: -1%; }
}
@media (max-width: 820px) {
  body.urizen-theme dialog.reason-gate { padding: 18px 24px 8px; }
  body.urizen-theme dialog.reason-gate[open] { grid-template-rows: auto 1fr auto; }
  .reason-gate .threshold-top { padding-bottom: 15px; gap: 10px; }
  .reason-gate .threshold-brand { gap: 9px; }
  .reason-gate .threshold-brand img:first-child { width: 20px; height: 28px; }
  .reason-gate .threshold-edition { max-width: 122px; text-align: right; font-size: 8px; line-height: 1.6; }
  .reason-gate .threshold-edition i { margin: 0 6px; }
  .reason-gate .threshold-content { min-height: 0; grid-template-columns: 1fr; text-align: center; margin-block: 0; padding-top: 10px; }
  .reason-gate .threshold-copy { display: contents; }
  .reason-gate .threshold-kicker { grid-row: 1; font-size: 8px; margin: 7px 0 0; }
  .reason-gate .threshold-kicker > span { font-size: 16px; margin-right: 7px; }
  .reason-gate .sanctuary-stage { grid-row: 2; height: clamp(245px, 37dvh, 430px); width: 100%; margin: 0; }
  .reason-gate .sanctuary-caption, .reason-gate .sanctuary-label { display: none; }
  .reason-gate #threshold-title { grid-row: 3; font-size: clamp(38px, 7.5vw, 54px); line-height: 1.05; }
  .reason-gate #threshold-title br { display: none; }
  .reason-gate #threshold-title em { display: block; }
  .reason-gate #threshold-description { grid-row: 4; font-size: 12px; line-height: 1.7; margin: 14px 0 18px; }
  .reason-gate .threshold-enter { grid-row: 5; justify-self: center; min-height: 48px; font-size: 12px; margin-bottom: 23px; }
  .reason-gate .threshold-margin { display: none; }
  .reason-gate .threshold-bottom { justify-content: center; flex-wrap: wrap; gap: 0; padding-top: 8px; }
  .reason-gate .threshold-disciplines { width: 100%; text-align: center; font-size: 8px; }
  .reason-gate .threshold-disciplines i { padding: 0 8px; }
  .reason-gate .threshold-skip { font-size: 11px; }
  .reason-gate .sanctuary-drawing { opacity: .5; }
  .reason-gate.is-departing .threshold-copy > * { opacity: 0; transition: opacity 220ms ease; }
}
@media (min-width: 821px) and (max-height: 700px) {
  .reason-gate .threshold-content { min-height: 400px; }
  .reason-gate .sanctuary-stage { height: max(400px, calc(100dvh - 145px)); }
  .reason-gate #threshold-title { font-size: clamp(45px, 5.4vw, 70px); }
  .reason-gate .threshold-copy { padding: 30px 0 65px; }
  .reason-gate .threshold-margin { bottom: 0; font-size: 18px; }
}
@media (prefers-reduced-motion: reduce) {
  .reason-gate *, .reason-gate *::before, .reason-gate *::after { animation: none !important; transition: none !important; }
  body.urizen-theme dialog.reason-gate.is-departing, .reason-gate.is-departing::backdrop { transition: none; }
  .reason-gate.is-departing .sanctuary-art { transform: none; }
}

/* A programmatic reading destination, outside the keyboard tab order. */
body.urizen-theme #hero-title:focus { outline: none; }

body.anansi-demo .site-footer span { min-width: 0; overflow-wrap: anywhere; }
body.anansi-demo .site-footer > img { flex-shrink: 0; }

/* Living Obelisk: preserve the pointed crown and clear space around the tree. */
body.urizen-theme .site-header .brand-mark,
body.urizen-theme .brand.compact .brand-mark { height: 42px; width: auto; }
body.urizen-theme.notebook-home .lab-research { grid-template-columns: repeat(2, minmax(0, 1fr)); }
@media (max-width: 760px) {
  body.urizen-theme.notebook-home .lab-research { grid-template-columns: minmax(0, 1fr); }
}

/* Dessert/Talk is an inscription voice. Fraunces and Inter remain reading fonts. */
html:root { --font-inscription: 'Dessert/Talk', 'Fraunces', Georgia, serif; }
body.urizen-theme .dessert-display,
body.anansi-demo .dessert-display {
  font-family: var(--font-inscription);
  font-weight: 400;
  font-style: normal;
  font-synthesis: none;
  font-kerning: normal;
  letter-spacing: .015em;
}
body.urizen-theme.notebook-home #hero-title .hero-inscription {
  display: block;
  font-size: clamp(44px, 5.2vw, 72px);
  line-height: 1.2;
}
body.urizen-theme.notebook-home #hero-title > br { display: none; }
body.urizen-theme.notebook-home #hero-title > em {
  display: block;
  margin-top: 18px;
  font-size: clamp(27px, 2.7vw, 36px);
  line-height: 1.25;
}
body.urizen-theme .reason-gate #threshold-title .threshold-inscription {
  display: block;
  margin-top: 8px;
  font-size: clamp(40px, 4.5vw, 66px);
  line-height: 1.25;
}
body.urizen-theme.notebook-home .lab-research .stack-index {
  width: fit-content; height: auto; min-height: 24px; max-width: 100%;
}
body.urizen-theme.notebook-home .lab-research .product-name,
body.urizen-theme.notebook-home .lab-products .product-name {
  font-size: 40px;
  line-height: 1.25;
  margin-block: 18px 20px;
}
body.urizen-theme.notebook-home .product-label .product-name {
  font-size: clamp(44px, 4.5vw, 64px);
  line-height: 1.2;
}
body.urizen-theme .page-hero .about-inscription {
  font-size: clamp(44px, 5.2vw, 68px);
  line-height: 1.3;
}
body.urizen-theme.demo-page .demo-copy h1 .demo-inscription {
  display: inline-block;
  margin-top: 12px;
  font-size: clamp(40px, 4.1vw, 58px);
  line-height: 1.25;
}
body.anansi-demo .hero h1.anansi-inscription {
  font-size: clamp(52px, 7vw, 96px);
  line-height: 1.25;
  letter-spacing: .015em;
}
@media (max-width: 760px) {
  body.urizen-theme.notebook-home #hero-title .hero-inscription {
    font-size: clamp(36px, 11.2vw, 50px);
  }
  body.urizen-theme.notebook-home #hero-title > em { font-size: 28px; margin-top: 14px; }
}
@media (max-width: 820px) {
  body.urizen-theme .reason-gate #threshold-title .threshold-inscription {
    font-size: clamp(36px, 10vw, 44px);
    margin-top: 5px;
    letter-spacing: 0;
    line-height: 1.2;
  }
}

/* The homepage wordmark shares the inscription voice at a checked compact size. */
body.urizen-theme.notebook-home .dessert-wordmark {
  display: inline-block;
  flex-shrink: 0;
  width: auto;
  max-width: none;
  height: auto;
  font-family: var(--font-inscription);
  font-size: 34px;
  font-weight: 400;
  font-style: normal;
  font-synthesis: none;
  font-kerning: normal;
  line-height: 1.15;
  letter-spacing: .035em;
  white-space: nowrap;
  color: var(--cream);
}
body.urizen-theme.notebook-home .site-header .dessert-wordmark { color: var(--botanical); }
@media (max-width: 760px) {
  body.urizen-theme.notebook-home .site-header .dessert-wordmark,
  body.urizen-theme.notebook-home .threshold-brand .dessert-wordmark { font-size: 28px; }
}

/* Sanctuary motion: a single arrival followed by persistent camera and light motion.
   Entry and skip stay available throughout the reveal. */
.reason-gate .sanctuary-reveal { position: absolute; inset: 0; transform-origin: 50% 64%; }
.reason-gate .sanctuary-light { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; mix-blend-mode: screen; }
.reason-gate .sanctuary-image, .reason-gate .sanctuary-light { transform-origin: 50% 64%; }
.reason-gate .sanctuary-current { stroke: #f2d99e; stroke-width: 1.8; stroke-linecap: round; stroke-dasharray: .12 .88; stroke-dashoffset: 1; opacity: 0; }
.reason-gate .sanctuary-rays { opacity: .2; transform-origin: 512px 286px; }
.reason-gate .sanctuary-aureole { opacity: .26; transform-origin: 512px 480px; }
.reason-gate .sanctuary-threshold-glow { opacity: .18; }
.reason-gate .threshold-actions { display: flex; align-items: center; gap: 28px; }
.reason-gate .threshold-motion { color: #b9c8ae; border: 0; background: none; padding: 0; min-height: 44px; font: 11px var(--font-sans); letter-spacing: 0; text-transform: none; cursor: pointer; }
.reason-gate .threshold-motion::before { content: ''; display: inline-block; width: 7px; height: 8px; border-inline: 2px solid currentColor; margin-right: 8px; vertical-align: -1px; }
.reason-gate.is-motion-paused .threshold-motion::before { width: 0; height: 0; border: 4px solid transparent; border-left: 6px solid currentColor; border-right: 0; }
.reason-gate .threshold-motion:hover, .reason-gate .threshold-motion:focus-visible { color: #f2f1e4; }
.reason-gate .threshold-motion[hidden] { display: none; }
.reason-gate.is-motion-paused *, .reason-gate.is-motion-paused *::before, .reason-gate.is-motion-paused *::after { animation-play-state: paused !important; }
@media (prefers-reduced-motion: no-preference) {
  body.urizen-theme dialog.reason-gate { transition: opacity 1100ms cubic-bezier(.55,0,.7,1); }
  .reason-gate .sanctuary-art { transition: transform 1100ms cubic-bezier(.45,0,.25,1); }
  .reason-gate[open] .sanctuary-reveal { animation: sanctuary-arrive 3800ms cubic-bezier(.16,1,.3,1) both; }
  .reason-gate[open] .threshold-kicker { animation: sanctuary-copy 1400ms ease-out both; }
  .reason-gate[open] #threshold-title { animation: sanctuary-copy 1800ms 160ms cubic-bezier(.16,1,.3,1) both; }
  .reason-gate[open] #threshold-description { animation: sanctuary-copy 1500ms 360ms ease-out both; }
  .reason-gate[open] .sanctuary-measure path { stroke-dasharray: 1; animation: sanctuary-measure 2800ms 700ms ease-out both; }
  .reason-gate[open] .sanctuary-los { animation: sanctuary-line 3600ms 800ms ease-out both; }
  .reason-gate[open] .sanctuary-los-second { animation-duration: 3400ms; animation-delay: 1400ms; }
  .reason-gate[open] .sanctuary-label, .reason-gate[open] .sanctuary-caption { animation: sanctuary-note 1800ms 1200ms ease-out both; }
  .reason-gate[open] .sanctuary-image,
  .reason-gate[open] .sanctuary-light { animation: sanctuary-presence 16000ms -4000ms ease-in-out infinite; }
  .reason-gate[open] .sanctuary-current { animation: sanctuary-current 10000ms -3000ms linear infinite; }
  .reason-gate[open] .sanctuary-rays { animation: sanctuary-daylight 10000ms -3000ms ease-in-out infinite alternate; }
  .reason-gate[open] .sanctuary-aureole { animation: sanctuary-warmth 8000ms -2000ms ease-in-out infinite alternate; }
  .reason-gate[open] .sanctuary-threshold-glow { animation: sanctuary-ground-light 12000ms -4000ms ease-in-out infinite alternate; }
  .reason-gate.is-departing .sanctuary-art { transform: scale(1.42); }
  .reason-gate.is-departing .sanctuary-reveal,
  .reason-gate.is-departing .sanctuary-image,
  .reason-gate.is-departing .sanctuary-light { animation-play-state: paused; }
  .reason-gate.is-departing .threshold-copy > *,
  .reason-gate.is-departing .sanctuary-label,
  .reason-gate.is-departing .sanctuary-caption { animation: none; }
  .reason-gate.is-departing::backdrop { transition: opacity 1100ms cubic-bezier(.55,0,.7,1); }
}
@keyframes sanctuary-arrive {
  from { opacity: .22; transform: translateY(22px) scale(.965); }
  to { opacity: 1; transform: none; }
}
@keyframes sanctuary-copy {
  from { opacity: .3; transform: translateY(10px); }
  to { opacity: 1; transform: none; }
}
@keyframes sanctuary-note { from { opacity: 0; } to { opacity: 1; } }
@keyframes sanctuary-measure {
  from { opacity: 0; stroke-dashoffset: 1; }
  to { opacity: 1; stroke-dashoffset: 0; }
}
@keyframes sanctuary-presence {
  0%, 100% { transform: translate(3px, 14px) scale(.975); }
  50% { transform: translate(-5px, 8px) scale(1.025); }
}
@keyframes sanctuary-current {
  0% { stroke-dashoffset: 1; opacity: 0; }
  12%, 82% { opacity: .9; }
  100% { stroke-dashoffset: 0; opacity: 0; }
}
@keyframes sanctuary-daylight {
  from { opacity: .14; transform: rotate(-4deg) scaleX(.86); }
  to { opacity: .68; transform: rotate(4deg) scaleX(1.12); }
}
@keyframes sanctuary-warmth {
  from { opacity: .16; transform: scale(.9); }
  to { opacity: .62; transform: scale(1.12); }
}
@keyframes sanctuary-ground-light { from { opacity: .1; } to { opacity: .42; } }
@media (max-width: 820px) {
  .reason-gate .threshold-actions { gap: 20px; justify-content: center; }
  .reason-gate .threshold-motion { font-size: 10px; }
}
@media (prefers-reduced-motion: reduce) {
  .reason-gate .sanctuary-light, .reason-gate .threshold-motion { display: none; }
}

.reason-gate .sanctuary-canvas { display: block; width: 100%; height: 100%; opacity: 0; transition: opacity 900ms ease; }

/* Let the sanctuary occupy the viewport; the copy is an inscription beside it. */
@media (min-width: 821px) {
  body.urizen-theme dialog.reason-gate { padding: 28px clamp(32px, 4vw, 76px) 18px; overflow: hidden; }
  .reason-gate .threshold-top, .reason-gate .threshold-bottom { border: 0; }
  .reason-gate .threshold-content { position: static; width: 100%; height: 100%; min-height: 0; display: flex; }
  .reason-gate .threshold-copy { width: min(52vw, 700px); padding: 0 0 34px; }
  .reason-gate #threshold-title { font-size: clamp(50px, 6.4vw, 104px); }
  body.urizen-theme .reason-gate #threshold-title .threshold-inscription { font-size: clamp(42px, 5.1vw, 82px); }
  .reason-gate .threshold-margin { left: 240px; bottom: -52px; }
  .reason-gate .sanctuary-stage { position: absolute; inset: 0; width: 100%; height: 100dvh; margin: 0; z-index: 0; pointer-events: none; }
  .reason-gate .sanctuary-caption { display: none; }
  .reason-gate .sanctuary-label-light { left: 13%; top: 24%; }
  .reason-gate .sanctuary-label-tree { right: 10%; top: 65%; }
  .reason-gate .threshold-bottom { text-shadow: 0 1px 8px #122e26; }
}
@media (min-width: 821px) and (max-height: 650px) {
  .reason-gate .threshold-copy { padding-bottom: 0; }
  .reason-gate .threshold-kicker { margin-bottom: 18px; }
  .reason-gate #threshold-description { margin: 20px 0; }
  .reason-gate .threshold-margin { display: none; }
}
@media (max-width: 820px) and (min-height: 760px) {
  .reason-gate .sanctuary-stage { height: clamp(300px, 45dvh, 480px); }
}


/* Cycles renders the complete oasis; a matching water matte isolates motion. */
.reason-gate .sanctuary-world { position: absolute; inset: 0; z-index: 0; pointer-events: none; overflow: hidden; }
.reason-gate .sanctuary-oasis-poster,
.reason-gate .sanctuary-canvas { position: absolute; inset: 0; display: block; width: 100%; max-width: none; height: 100%; }
.reason-gate .sanctuary-oasis-poster { object-fit: cover; object-position: 70% center; opacity: 1; transition: opacity 900ms ease; }
.reason-gate .sanctuary-world::after { content: ''; position: absolute; inset: 0; background: url('/assets/notebook-grain.svg'), linear-gradient(90deg, #10291ff2, #10291fc2 24%, #10291f18 59%, transparent 75%), linear-gradient(0deg, #10291fbd, transparent 22%), linear-gradient(180deg, #10291f88, transparent 20%), radial-gradient(ellipse 32% 24% at 100% 0, #10291fcc, #10291f80 55%, transparent); background-size: 180px 180px, auto, auto, auto, auto; }
.reason-gate.has-oasis-motion .sanctuary-canvas { opacity: 1; }
.reason-gate.has-oasis-motion .sanctuary-oasis-poster { opacity: 0; }
@media (max-width: 820px) {
  .reason-gate .sanctuary-stage { width: calc(100% + 48px); margin-inline: -24px; }
  .reason-gate .sanctuary-oasis-poster { object-position: 90% center; }
  .reason-gate .sanctuary-world::after { background: linear-gradient(0deg, #163328, #16332855 16%, transparent 35%, transparent 82%, #18392e); }
}
@media (prefers-reduced-motion: reduce) {
  .reason-gate .sanctuary-canvas { display: none; }
  .reason-gate .sanctuary-oasis-poster { opacity: 1; }
}
