:root {
  --ink: #19362f;
  --dim: #425b52;
  --white: #ffffff;
  --page: #f7f9f3;
  --mint: #dfedda;
  --lilac: #eae3f6;
  --rose: #f0e3e9;
  --line: #81978c;
  --light-line: #c4d2c4;
  --accent: #523e73;
  --chapter-paper: var(--mint);
  --body: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --mono: ui-monospace, "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  --size: 1.125rem;
  --leading: 1.65;
  --measure: 66ch;
  --space: clamp(1.25rem, 3vw, 3rem);
  --gutter: clamp(1.125rem, 4.5vw, 4.5rem);
  --wide: 80rem;
  --radius: 1.25rem;
  --shadow: 0 10px 26px #19362f0c;
}

* { box-sizing: border-box; }
html { color-scheme: light; scroll-padding-top: 1rem; }
body { margin: 0; color: var(--ink); background: var(--page); font-family: var(--body); font-size: var(--size); line-height: var(--leading); }
body::before { content: ""; position: absolute; inset: 0 0 auto; height: 48rem; background: radial-gradient(ellipse at 83% 13%, #d8edcc99, transparent 46%), radial-gradient(ellipse at 35% 8%, #e8dcf499, transparent 53%); z-index: -1; pointer-events: none; }
button, select, input { font: inherit; }
button, select { color: var(--ink); }
button, a, summary, select { -webkit-tap-highlight-color: #d7dfcb; }
a { color: inherit; text-decoration-thickness: 1.5px; text-underline-offset: .2em; }
a:focus-visible, button:focus-visible, select:focus-visible, summary:focus-visible { outline: 3px solid var(--accent); outline-offset: 4px; }
h1, h2, h3, h4, p, figure, ul { margin: 0; }
h1, .chapter-title { font-weight: 560; letter-spacing: -.045em; text-wrap: balance; }
h1 { font-size: clamp(2.35rem, 4.6vw, 4.25rem); line-height: 1.08; max-width: 19ch; }
.chapter-title { font-size: clamp(1.55rem, 2.35vw, 2.15rem); line-height: 1.2; margin-bottom: 1.25rem; max-width: 31ch; }
.chapter-title:focus { outline: none; }
.chapter-part { scroll-margin-top: 1.5rem; }
p + p { margin-top: 1rem; }
ul { padding-left: 1.35rem; }
li + li { margin-top: .6rem; }
.w { width: min(calc(100% - var(--gutter) * 2), var(--wide)); margin-inline: auto; }
.g { display: grid; }
.mono, .tag, .brand a { font-family: var(--mono); }
.tag { font-size: 1rem; line-height: 1.5; letter-spacing: -.025em; margin-bottom: 1rem; }
.skip { position: fixed; top: .7rem; left: .7rem; z-index: 10; min-height: 44px; padding: .7rem 1rem; background: var(--white); border: 2px solid var(--ink); transform: translateY(-170%); }
.skip:focus { transform: translateY(0); }
.head { padding-top: 1.75rem; }
.brand { display: flex; align-items: center; justify-content: space-between; gap: 1rem; }
.brand a { display: inline-flex; align-items: center; gap: .65rem; min-height: 44px; font-size: 1rem; letter-spacing: -.02em; text-decoration: none; }
.brand p { font-size: 1rem; line-height: 1.5; color: var(--dim); }
.mark { display: block; width: 29px; height: 29px; border-radius: 50% 8% 50% 50%; background: var(--ink); transform: rotate(-25deg); position: relative; flex: 0 0 29px; }
.mark::after { content: ""; position: absolute; width: 17px; height: 17px; inset: 6px; border-radius: 50%; background: var(--mint); }
.tabs { display: flex; flex-wrap: wrap; align-items: stretch; gap: .45rem; margin-top: 1.35rem; padding-bottom: .5rem; border-bottom: 1px solid var(--line); position: relative; z-index: 3; }
.tab, .more > summary { display: flex; align-items: center; justify-content: center; padding: .6rem 1rem; min-height: 48px; font-size: 1rem; line-height: 1.4; text-decoration: none; border: 1px solid var(--line); border-radius: .7rem .7rem .25rem .25rem; background: #ffffffb3; cursor: pointer; }
.tab:hover, .more > summary:hover { background: var(--mint); }
.tab[aria-current="page"], .more > summary.here { background: var(--ink); color: var(--page); border-color: var(--ink); }
.more { margin-left: auto; }
.more > summary { gap: .9rem; list-style: none; }
.more > summary::-webkit-details-marker { display: none; }
.more[open] > summary { border-radius: .7rem .7rem 0 0; }
.more-list { position: absolute; right: 0; top: calc(100% - .5rem); width: min(32rem, 100%); padding: .7rem; background: var(--white); border: 1px solid var(--line); box-shadow: var(--shadow); display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .45rem; }
.more-list .tab { text-align: left; justify-content: flex-start; border-radius: .4rem; }
.hero { grid-template-columns: minmax(0, 1.15fr) minmax(0, .85fr); gap: 2.5rem; align-items: center; padding: 3.5rem 0 4rem; }
.intro { min-width: 0; }
.intro > .tag { color: var(--dim); margin-bottom: 1.25rem; }
.dek { font-size: 1.2rem; line-height: 1.6; max-width: 48ch; margin-top: 1.7rem; }
.btn { display: inline-flex; align-items: center; justify-content: space-between; gap: 1.3rem; padding: .8rem 1.2rem; min-height: 48px; border: 1px solid var(--ink); border-radius: .4rem; background: var(--ink); color: var(--page); font-size: 1.0625rem; font-weight: 500; line-height: 1.45; text-decoration: none; cursor: pointer; }
.btn span { font-size: 1.4rem; line-height: 1; }
.intro .btn { margin-top: 1.7rem; }
.btn:hover { background: #294a3e; }
.btn.soft { color: var(--ink); background: transparent; margin-top: 1.5rem; }
.btn.soft:hover { background: var(--mint); }
.art { position: relative; min-width: 0; height: 26rem; isolation: isolate; margin: .5rem 0; }
.halo { position: absolute; inset: 5% 9% 8%; border-radius: 50%; background: linear-gradient(128deg, var(--lilac), #d5e5c2 67%, var(--mint)); transform: rotate(-12deg); }
.leaf { position: absolute; inset: 11% 24% 22% 4%; background: var(--ink); clip-path: polygon(5% 0, 100% 9%, 94% 100%, 0 86%, 2% 68%, 0 43%); transform: rotate(-9deg); }
.fold { position: absolute; inset: 4% 6% 27% 30%; background: var(--lilac); border: 1px solid var(--light-line); border-radius: 52% 46% 2% 4%; transform: rotate(13deg); box-shadow: var(--shadow); }
.slip { position: absolute; inset: 26% 10% auto 14%; min-height: 14rem; background: var(--white); padding: 1.6rem 1.8rem; clip-path: polygon(0 1%, 23% 0, 45% 1%, 62% 0, 83% 1%, 100% 0, 99% 35%, 100% 60%, 99% 79%, 100% 100%, 82% 99%, 59% 100%, 32% 99%, 0 100%, 1% 77%, 0 47%); box-shadow: var(--shadow); transform: rotate(-3deg); }
.slip .tag { margin-bottom: .5rem; }
.slip .line { font-size: clamp(1.2rem, 2vw, 1.55rem); line-height: 1.45; border-bottom: 1px solid var(--light-line); padding: .3rem 0 .55rem; margin-top: .2rem; }
.pin { position: absolute; height: 2.25rem; width: 4rem; top: -.15rem; right: 1rem; background: #e0eccc; opacity: .9; transform: rotate(12deg); }
.art figcaption { position: absolute; bottom: .4rem; right: .5rem; font-family: var(--mono); font-size: 1rem; color: var(--dim); max-width: 27ch; }
.chapter .art { height: 22rem; }
.chapter .slip { padding: 1.25rem 1.5rem; inset: 21% 7% auto 10%; }
.lay { display: grid; grid-template-columns: minmax(0, 16rem) minmax(0, 46rem); gap: clamp(2rem, 6vw, 6rem); justify-content: center; align-items: start; }
.side { position: sticky; top: 1.5rem; min-width: 0; }
.jump { border-top: 2px solid var(--ink); padding-top: 1rem; }
.jump-ui { margin-bottom: 1rem; }
.jump-ui[hidden] { display: none; }
.jump-ui label { display: block; font-size: 1rem; margin-bottom: .5rem; }
.jump-ui select { display: block; width: 100%; min-height: 48px; font-size: 1rem; padding: .6rem .45rem; background: var(--white); border: 1px solid var(--line); border-radius: .25rem; }
.jump-ui .btn { width: 100%; margin-top: .5rem; font-size: 1rem; }
.jump-links { padding: 0; list-style: none; }
.jump-links li { margin: 0; }
.jump-links a { display: flex; align-items: center; min-height: 44px; padding: .45rem 0; line-height: 1.45; font-size: 1rem; color: var(--dim); }
.read { min-width: 0; max-width: var(--measure); }
.s { margin-bottom: 3rem; scroll-margin-top: 1.5rem; }
.s p, .s li { font-size: var(--size); }
.s > .tag { font-size: 1rem; }
.sum { padding: clamp(1.25rem, 3vw, 2rem); background: var(--chapter-paper); border-radius: .35rem var(--radius) var(--radius) .35rem; position: relative; }
.sum::before { content: ""; display: block; height: 2px; width: 3rem; background: var(--ink); margin-bottom: 1rem; }
.deep { padding: 0 1rem; }
.ask { font-size: clamp(1.25rem, 2vw, 1.5rem) !important; line-height: 1.5; font-weight: 500; letter-spacing: -.025em; }
.list { margin: 1.25rem 0; }
.list p { margin: 0; }
.kit { margin-top: 1.5rem; border-top: 1px solid var(--line); }
.q { display: flex; justify-content: space-between; align-items: center; gap: 1rem; padding: .9rem .25rem; min-height: 52px; border-bottom: 1px solid var(--line); text-decoration: none; font-size: 1.125rem; line-height: 1.5; }
.q:hover { text-decoration: underline; }
.q span:last-child { font-size: 1.5rem; flex: 0 0 auto; }
.notes { border-top: 1px solid var(--line); padding: 1.6rem 1rem 0; }
.notes ul { list-style: none; padding: 0; }
.notes li + li { margin-top: 1.5rem; }
.src { display: flex; align-items: center; gap: .8rem; min-height: 48px; padding: .3rem 0; font-size: 1rem; line-height: 1.5; }
.src .mono { width: 2rem; height: 2rem; display: grid; place-items: center; flex: 0 0 auto; background: var(--chapter-paper); border-radius: 50%; }
.src span:last-child { margin-left: auto; font-size: 1.25rem; }
.notes li p { margin: .5rem 0 0 2.8rem; color: var(--dim); font-size: 1rem; }
.next { margin: 3rem 0 1rem; padding: 1.5rem 1rem; border-block: 1px solid var(--line); }
.next a { display: flex; align-items: center; justify-content: space-between; min-height: 48px; gap: 1rem; font-size: 1.25rem; line-height: 1.5; }
.sheet { padding: 0; list-style: none; }
.sheet li { padding: 1.3rem 0; border-top: 1px solid var(--light-line); margin: 0; break-inside: avoid; }
.sheet li p { margin: 0; }
.rule { height: 2.8rem; background: repeating-linear-gradient(transparent 0, transparent 1.35rem, var(--light-line) 1.35rem, var(--light-line) calc(1.35rem + 1px)); }
.foot { margin-top: 4rem; padding: 2rem 0 2.5rem; border-top: 1px solid var(--line); display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); gap: 3rem; }
.foot p { font-size: 1.0625rem; max-width: 50ch; }
.foot nav { display: flex; flex-wrap: wrap; align-content: start; justify-content: flex-end; gap: .3rem 1rem; }
.foot a { display: inline-flex; align-items: center; min-height: 44px; font-size: 1rem; padding: .35rem .25rem; }

@media (max-width: 900px) {
  .hero { gap: 1.5rem; }
  .brand { align-items: start; }
  .brand p { max-width: 24ch; }
  .art { height: 23rem; }
  .lay { grid-template-columns: minmax(0, 12rem) minmax(0, 1fr); gap: 2rem; }
  .slip { padding: 1.25rem; }
  .slip .tag { font-size: 1rem; }
}
@media (max-width: 690px) {
  :root { --size: 1.0625rem; --gutter: 1.125rem; }
  .head { padding-top: 1rem; }
  .brand { display: block; }
  .brand p { max-width: none; margin: .1rem 0 0; }
  .tabs { gap: .35rem; margin-top: 1rem; }
  .tabs > .tab { flex: 1 1 44%; padding-inline: .5rem; }
  .more { flex: 1 1 100%; margin: 0; }
  .more > summary { min-height: 44px; justify-content: space-between; padding-inline: .7rem; }
  .more-list { grid-template-columns: 1fr; max-height: 60vh; overflow-y: auto; }
  .hero { grid-template-columns: minmax(0, 1fr); padding: 2rem 0 2rem; gap: 1.7rem; }
  h1 { font-size: 2.45rem; max-width: 20ch; }
  .intro > .tag { margin-bottom: 1rem; }
  .dek { margin-top: 1.25rem; font-size: 1.125rem; }
  .art { height: 23rem; max-width: 28rem; width: 100%; margin-inline: auto; }
  .chapter .art { height: 22rem; }
  .chapter .slip { inset: 21% 10% auto 12%; }
  .lay { display: flex; flex-direction: column; gap: 2rem; }
  .side { position: static; width: 100%; }
  .jump-ui { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: .5rem; }
  .jump-ui label { grid-column: 1 / -1; margin-bottom: 0; }
  .jump-ui .btn { margin: 0; width: auto; padding-inline: .75rem; }
  .jump-ui select { min-width: 0; }
  .jump-links { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 1rem; }
  .jump-links a { font-size: 1rem; }
  .deep, .notes { padding-inline: .35rem; }
  .s { margin-bottom: 2.5rem; }
  .sum { padding: 1.4rem 1.25rem; }
  .foot { grid-template-columns: minmax(0, 1fr); gap: 1.25rem; margin-top: 3rem; }
  .foot nav { justify-content: flex-start; }
}
@media (max-width: 350px) {
  h1 { font-size: 2.05rem; }
  .jump-ui { grid-template-columns: minmax(0, 1fr); }
  .jump-ui .btn { width: 100%; }
  .slip { padding: 1rem; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; animation: none !important; transition: none !important; }
}
@media print {
  :root { --size: 12pt; --leading: 1.45; --ink: #111111; --dim: #333333; --chapter-paper: #ffffff; }
  body { background: white; }
  body::before, .skip, .tabs, .art, .side, .next, .foot nav, .btn { display: none; }
  .w { width: 100%; margin: 0; }
  .head { padding: 0 0 1rem; border-bottom: 1px solid #777; }
  .brand { display: block; }
  .brand p { margin-top: .25rem; }
  .brand a, .brand p, .tag, .notes li p, .foot p, .src { font-size: 12pt; }
  .hero { display: block; padding: 1.5rem 0; }
  h1 { font-size: 25pt; max-width: none; }
  .chapter-title { font-size: 18pt; break-after: avoid; }
  .dek { font-size: 12pt; max-width: none; }
  .lay { display: block; }
  .read { max-width: none; }
  .s { margin-bottom: 1.6rem; }
  .sum, .deep, .notes { padding: 0; background: white; border-radius: 0; }
  .sum::before { display: none; }
  .ask { font-size: 15pt !important; }
  .sheet li { padding: .7rem 0; }
  .notes li { break-inside: avoid; }
  .foot { display: block; margin-top: 1.5rem; padding: 1rem 0; }
  a { text-decoration: none; }
  @page { margin: 17mm; }
}
