/* yapaykole lab: drawing-set world. One ink on one ground; state by line weight and hatching. */
@font-face { font-family: "Osifont"; src: url("fonts/osifont.woff") format("woff"); font-display: swap; }
@font-face { font-family: "Public Sans"; font-style: normal; font-weight: 400 700; font-display: swap;
  src: url("fonts/public-sans-normal-latin.woff2") format("woff2");
  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; }
@font-face { font-family: "Public Sans"; font-style: normal; font-weight: 400 700; font-display: swap;
  src: url("fonts/public-sans-normal-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: "Public Sans"; font-style: italic; font-weight: 400; font-display: swap;
  src: url("fonts/public-sans-italic-latin.woff2") format("woff2"); }

:root, [data-theme="blueprint"] {
  --ground: #17457e; --ink: #eef3fb; --mute: #bccbe2; --outer: #0e2f58; --select: #eef3fb33; --acc: #f6a05c;
}
[data-theme="paper"] { --ground: #f7f6f1; --ink: #151515; --mute: #4f4f4c; --outer: #e3e1d8; --select: #15151522; --acc: #a84b27; }
[data-theme="dark"] { --ground: #0f1012; --ink: #e6e3da; --mute: #a3a097; --outer: #08090a; --select: #e6e3da2e; --acc: #ec9a62; }
/* the atelier's hand: notes written on the drawings */
@font-face { font-family: "PH"; src: url("fonts/patrick-hand-latin-ext.woff2") format("woff2"); unicode-range: U+0100-024F; font-display: swap; }
@font-face { font-family: "PH"; src: url("fonts/patrick-hand-latin.woff2") format("woff2"); font-display: swap; }
:root {
  --font-label: "Osifont", "Public Sans", sans-serif;
  --font-body: "Public Sans", system-ui, sans-serif;
  --w-heavy: 2.4px; --w-thin: 1.1px; --w-hair: .6px;
  --gap: clamp(16px, 2.2vw, 28px);
}

* { box-sizing: border-box; }
html { background: var(--outer); color: var(--ink); }
body { margin: 0; font: 16.5px/1.6 var(--font-body); font-feature-settings: "tnum" 1; color: var(--ink);
  background: var(--outer); -webkit-font-smoothing: antialiased; }
::selection { background: var(--select); color: var(--ink); }
a { color: var(--ink); text-decoration-thickness: var(--w-hair); text-underline-offset: .22em; }
/* ruled links: a hairline at rest; on hover a heavier line is drawn along it from the left, like a ruling pen */
a:not(.panel):not(.home):not(.mt-tab), .register td.t a, .panel b {
  --rule: var(--w-hair);
  text-decoration: none; padding-bottom: .12em; -webkit-box-decoration-break: clone; box-decoration-break: clone;
  background: linear-gradient(currentColor, currentColor) 0 100% / 0% var(--w-thin) no-repeat,
              linear-gradient(currentColor, currentColor) 0 100% / 100% var(--rule) no-repeat;
  transition: background-size .32s cubic-bezier(.16, 1, .3, 1); }
a:not(.panel):not(.home):not(.mt-tab):hover, a:not(.panel):not(.home):not(.mt-tab):focus-visible, .panel:hover b, .panel:focus-visible b {
  background-size: 100% var(--w-thin), 100% var(--rule); }
.bar nav a:not(.panel), .register td.t a:not(.panel), .panel b { --rule: 0px; }
/* nav keeps its own hairline border as the resting rule; the drawn line lands exactly on it */
.bar nav a:not(.panel) { background-origin: border-box; padding-bottom: 1px; }
:focus-visible { outline: var(--w-thin) solid var(--ink); outline-offset: 3px; }
* { scrollbar-color: var(--mute) var(--outer); }

/* sheet + double frame */
.sheet { --z: 1; --pad: clamp(10px, 2vw, 28px); margin: 0 auto; padding: var(--pad); }
/* the sheet fills any screen: on wide screens the whole drawing is scaled up (like fitting a paper sheet to the
   screen) so line length, type and figures keep their designed proportions instead of stretching apart */
@media (min-width: 1680px) { .sheet { zoom: 1.1; --z: 1.1; } }
@media (min-width: 1860px) { .sheet { zoom: 1.22; --z: 1.22; } }
@media (min-width: 2100px) { .sheet { zoom: 1.4; --z: 1.4; } }
@media (min-width: 2250px) { .sheet { zoom: 1.5; --z: 1.5; } }
@media (min-width: 2400px) { .sheet { zoom: 1.62; --z: 1.62; } }
@media (min-width: 2560px) { .sheet { zoom: 1.72; --z: 1.72; } }
@media (min-width: 3000px) { .sheet { zoom: 2; --z: 2; } }
.frame { position: relative; background: var(--ground); border: var(--w-heavy) solid var(--ink);
  display: grid; grid-template-columns: minmax(0, 1fr) 350px;
  min-height: calc(100vh / var(--z) - 2 * var(--pad)); min-height: calc(100dvh / var(--z) - 2 * var(--pad)); }
.frame::before { content: ""; position: absolute; inset: 6px; border: var(--w-hair) solid var(--ink); pointer-events: none; }
.zones { position: absolute; top: -2px; left: 0; right: 0; height: 0; display: flex; justify-content: space-around; pointer-events: none; }
.zones span { position: relative; top: -1.3em; font: 11px var(--font-label); letter-spacing: .12em; color: var(--mute); }
.zones span::after { content: ""; position: absolute; left: 50%; top: 1.45em; height: 10px; border-left: var(--w-hair) solid var(--ink); }
.main { padding: clamp(28px, 4vw, 52px) clamp(22px, 4vw, 56px) 48px; min-width: 0; }
.side { border-left: var(--w-heavy) solid var(--ink); display: flex; flex-direction: column; min-width: 0; }
.side .blk { border-bottom: var(--w-hair) solid var(--ink); padding: 14px 18px 16px; }

/* top bar inside the sheet */
.bar { display: flex; flex-wrap: wrap; gap: 10px 26px; align-items: baseline; justify-content: space-between; margin-bottom: clamp(26px, 4vw, 44px); }
.bar .home { font: 15px var(--font-label); letter-spacing: .16em; text-transform: uppercase; text-decoration: none; }
.bar nav { display: flex; gap: 22px; flex-wrap: wrap; }
.bar nav a { font: 13px var(--font-label); letter-spacing: .18em; text-transform: uppercase; text-decoration: none;
  border-bottom: var(--w-hair) solid var(--ink); padding-bottom: 1px; }
.bar nav a[aria-current="page"] { border-bottom-width: var(--w-heavy); }
.themes { display: inline-flex; gap: 0; border: var(--w-hair) solid var(--ink); }
.themes button { font: 11px var(--font-label); letter-spacing: .14em; text-transform: uppercase; color: var(--ink);
  background: transparent; border: 0; padding: 4px 9px; cursor: pointer; min-height: 28px; }
.themes button + button { border-left: var(--w-hair) solid var(--ink); }
.themes button[aria-pressed="true"] { background: var(--ink); color: var(--ground); }

/* type */
.label { font: 12.5px var(--font-label); letter-spacing: .22em; text-transform: uppercase; color: var(--mute); }
h1, h2, h3 { font-family: var(--font-label); font-weight: 400; letter-spacing: .02em; text-wrap: balance; }
h1 { font-size: clamp(38px, 5.4vw, 66px); line-height: 1.04; margin: 8px 0 14px; }
h1 b { font-weight: 400; text-decoration: underline; text-decoration-thickness: var(--w-heavy); text-underline-offset: .14em; }
h2 { font-size: 26px; margin: 48px 0 10px; }
h3 { font-size: 19px; margin: 28px 0 6px; }
.question { font-family: var(--font-label); font-size: clamp(22px, 2.6vw, 30px); line-height: 1.25; max-width: 40ch; margin: 0 0 18px; text-wrap: balance; }
.question .label { display: block; margin: 0 0 4px; font-size: 12px; }
.panel .cap.q { font-style: italic; }
.lede { font-size: 19px; line-height: 1.5; max-width: 62ch; margin: 0 0 8px; }
.prose { max-width: 74ch; }
.prose figure.fig { max-width: none; width: min(100%, 1100px); }
.prose > figure.fig, .prose figure.fig + p { margin-right: 0; }
.prose p, .prose li { margin: 0 0 12px; }
.prose ul { padding-left: 1.2em; }
.prose code, code { font: 14px ui-monospace, "Cascadia Code", monospace; }
.prose strong { font-weight: 650; }
.prose table { border-collapse: collapse; margin: 10px 0 18px; font-size: 14.5px; }
.prose th, .prose td { border: var(--w-hair) solid var(--ink); padding: 5px 9px; text-align: left; }
.prose th { font: 12px var(--font-label); letter-spacing: .14em; text-transform: uppercase; }
.prose td.n, .prose th.n { text-align: right; }

/* figures */
figure.fig { margin: 30px 0 34px; max-width: 980px; overflow-x: auto; }
.main > .prose { max-width: none; }
.main > .prose > :not(figure) { max-width: 74ch; }
figure.fig table { min-width: 100%; }
figure.fig svg { display: block; width: 100%; height: auto; overflow: visible; }
figure.fig figcaption { margin-top: 8px; font-size: 14px; color: var(--mute); max-width: 70ch; }
figure.fig figcaption b { font: 13px var(--font-label); letter-spacing: .18em; color: var(--ink); font-weight: 400; margin-right: 8px; }
.fig .ink { stroke: var(--ink); fill: none; }
.fig .ink-fill { fill: var(--ink); stroke: none; }
.fig .ground-fill { fill: var(--ground); stroke: var(--ink); }
.fig .grid { stroke: var(--mute); stroke-width: var(--w-hair); opacity: .55; }
.fig text { fill: var(--ink); font: 12px var(--font-label); letter-spacing: .06em; }
.fig text.mute { fill: var(--mute); }
.fig .heavy { stroke-width: var(--w-heavy); } .fig .thin { stroke-width: var(--w-thin); }
/* animated figures (figures.py VIZ kinds + motion.js timeline). At rest: the finished drawing, still. */
.fig .mask { fill: var(--ground); stroke: none; }
.fig .acc { stroke: var(--acc); fill: none; }
.fig .acc-fill { fill: var(--acc); stroke: none; }
.fig .hatch-acc { fill: url(#hatch-acc); stroke: none; }
.fig text.lbl { font-size: 13px; }
.fig text.sub { font-size: 11px; fill: var(--mute); letter-spacing: .04em; }
.fig text.big { letter-spacing: .02em; }
.fig text .unit { fill: var(--mute); }
.fig text.note, .fig text.note tspan { font-family: "PH", cursive; fill: var(--acc); letter-spacing: 0; }
.fig text.on-ink { fill: var(--ground); }
.fig text.halo { paint-order: stroke; stroke: var(--ground); stroke-width: 4px; stroke-linejoin: round; }
.fig .route { fill: none; stroke: none; }
.fig .token { fill: var(--acc); stroke: var(--ground); stroke-width: 1.5; opacity: 0; }
.fig .say { opacity: 0; }
.fig .ink.lit, .fig .ink-fill.lit { stroke: var(--acc); stroke-width: var(--w-heavy); }
.fig .ink { transition: stroke .18s ease-out, stroke-width .18s ease-out; }
.fig .v-narrow { display: none; }
figure.fig.has-narrow { container-type: inline-size; overflow: visible; }
@container (max-width: 640px) {
  .fig.has-narrow svg.v-wide { display: none; }
  .fig.has-narrow svg.v-narrow { display: block; min-width: 0; max-width: 440px; }
}
figure.fig.has-narrow::after { content: none !important; }
/* the career road: the wide drawing, and below ~700 px of column the same road redrawn top to bottom (road.py) */
figure.fig.has-road { container-type: inline-size; overflow: visible; }
figure.fig.has-road::after { content: none !important; }
.fig.has-road svg.road-v { display: none; }
@container (max-width: 700px) {
  .fig.has-road svg.road:not(.road-v) { display: none; }
  .fig.has-road svg.road-v { display: block; min-width: 0; max-width: 460px; margin: 0 auto; }
}
.fig .replay { font: 11px var(--font-label); letter-spacing: .14em; text-transform: uppercase; color: var(--ink);
  background: transparent; border: var(--w-hair) solid var(--ink); padding: 3px 9px; margin: 0 10px 0 0; cursor: pointer;
  min-height: 26px; vertical-align: 1px; }
.fig .replay:hover { border-color: var(--acc); color: var(--acc); }
@media (max-width: 560px) { .fig .replay { min-height: 36px; padding: 6px 12px; } }
/* reading head (motion.js): plays through a figure while it is on screen */
.fig .reader { pointer-events: none; }
.fig .reader-trail { fill: url(#hatch); stroke: none; opacity: 0; }
.fig .reader-head { stroke: var(--ink); stroke-width: var(--w-heavy); opacity: 0; }
.fig .reader-ring { fill: none; stroke: var(--ink); stroke-width: 1.6; }
.fig .reader-drop { stroke: var(--ink); stroke-width: var(--w-hair); stroke-dasharray: 2 3; }
.fig rect.ink.reading { stroke-width: var(--w-heavy); }
.fig .dash { stroke-dasharray: 6 4; } .fig .dot { stroke-dasharray: 1.5 4; stroke-linecap: round; } .fig .dashdot { stroke-dasharray: 8 3 2 3; }
.src { font-size: 12.5px; color: var(--mute); }

/* side column content */
.side h3 { font: 11.5px var(--font-label); letter-spacing: .24em; margin: 0 0 9px; text-transform: uppercase; }
.refs { list-style: none; margin: 0; padding: 0; }
.refs li { display: grid; grid-template-columns: 36px 1fr; gap: 4px; padding: 3px 0; font-size: 14px; }
.refs li > span:first-child { font-family: var(--font-label); font-size: 15px; }
.legend { list-style: none; margin: 0; padding: 0; }
.legend li { display: flex; gap: 12px; align-items: center; font-size: 13.5px; padding: 3px 0; }
.legend svg { flex: none; }
.steps { list-style: none; margin: 0; padding: 0; counter-reset: s; }
.steps li { counter-increment: s; display: grid; grid-template-columns: 30px 1fr; font-size: 13.5px; padding: 4px 0; }
.steps li::before { content: counter(s); font: 15px var(--font-label); }
.steps time { display: block; color: var(--mute); font-size: 12.5px; }
.notes { font-size: 13.5px; margin: 0; padding-left: 1.2em; } .notes li { margin-bottom: 4px; }
.tb { margin-top: auto; display: grid; grid-template-columns: 1fr 1fr; border-top: var(--w-heavy) solid var(--ink); }
.tb div { padding: 8px 12px; border-right: var(--w-hair) solid var(--ink); border-bottom: var(--w-hair) solid var(--ink); font-size: 13px; min-width: 0; overflow-wrap: anywhere; }
.tb div:nth-child(2n) { border-right: 0; }
.tb small { display: block; font: 10px var(--font-label); letter-spacing: .2em; color: var(--mute); }
.stamp { display: inline-block; font: 13px var(--font-label); letter-spacing: .24em; border: var(--w-heavy) solid var(--ink); padding: 3px 10px; transform: rotate(-3deg); }

/* drawing register (project / notes lists) */
.register { width: 100%; border-collapse: collapse; margin-top: 12px; }
.register th { font: 11.5px var(--font-label); letter-spacing: .2em; text-transform: uppercase; text-align: left; color: var(--mute);
  border-bottom: var(--w-thin) solid var(--ink); padding: 6px 10px; font-weight: 400; }
.register td { border-bottom: var(--w-hair) solid var(--ink); padding: 12px 10px; vertical-align: top; }
.register td.no { font: 18px var(--font-label); width: 56px; }
.register td.t a { font: 20px var(--font-label); text-decoration: none; }
.register td.t p { margin: 2px 0 0; font-size: 14.5px; color: var(--mute); }
.register td.mark { width: 70px; }

/* home index figure: project panels */
.panels { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: var(--gap); margin-top: 26px; position: relative; }
.panel { position: relative; border: var(--w-thin) solid var(--ink); padding: 18px 18px 16px; text-decoration: none; display: flex; flex-direction: column; min-height: 250px; }
.panel.active { border-width: var(--w-heavy); }
.panel.frozen { border-style: dashed; }
.panel .num { position: absolute; top: -13px; right: 14px; background: var(--ground); padding: 0 6px; font: 18px var(--font-label); }
.panel .glyph { height: 120px; margin-bottom: 14px; }
.panel .glyph svg { height: 100%; width: auto; max-width: 100%; }
.panel b { font: 21px var(--font-label); font-weight: 400; }
.panel span.cap { font-size: 14px; color: var(--mute); margin-top: 4px; }
/* hovered panel = sheet picked out for inspection: crop marks are drawn in at its four corners */
.panel::after { content: ""; position: absolute; inset: -9px; pointer-events: none; opacity: 0;
  --m: 14px; --t: var(--w-thin);
  background:
    linear-gradient(var(--ink), var(--ink)) 0 0 / var(--m) var(--t), linear-gradient(var(--ink), var(--ink)) 0 0 / var(--t) var(--m),
    linear-gradient(var(--ink), var(--ink)) 100% 0 / var(--m) var(--t), linear-gradient(var(--ink), var(--ink)) 100% 0 / var(--t) var(--m),
    linear-gradient(var(--ink), var(--ink)) 0 100% / var(--m) var(--t), linear-gradient(var(--ink), var(--ink)) 0 100% / var(--t) var(--m),
    linear-gradient(var(--ink), var(--ink)) 100% 100% / var(--m) var(--t), linear-gradient(var(--ink), var(--ink)) 100% 100% / var(--t) var(--m);
  background-repeat: no-repeat; transform: scale(.94);
  transition: opacity .14s ease-out, transform .14s ease-out; }
.panel:hover::after, .panel:focus-visible::after { opacity: 1; transform: none;
  transition: opacity .2s ease-out, transform .34s cubic-bezier(.16, 1, .3, 1); }
.panel:focus-visible { outline: none; }
.themes button { transition: background-color .16s ease-out, color .16s ease-out; }

@media (prefers-reduced-motion: reduce) {
  a, .panel b, .panel::after, .themes button { transition-duration: .01s !important; }
  .panel::after { transform: none; }
}
.glyph .ink, .glyph path, .glyph line, .glyph circle, .glyph rect, .glyph polyline { stroke: var(--ink); }
.glyph .fill { fill: var(--ink); } .glyph .hollow { fill: var(--ground); }

.hatch { fill: url(#hatch); }

.frame.wide { grid-template-columns: 1fr; }
.frame.wide .side { border-left: 0; border-top: var(--w-heavy) solid var(--ink); display: grid; grid-template-columns: 1fr 1fr; }
.frame.wide .side .tb { margin-top: 0; border-top: 0; border-left: var(--w-hair) solid var(--ink); }

@media (max-width: 980px) {
  .frame.wide .side { grid-template-columns: 1fr; }
  .frame.wide .side .tb { border-left: 0; border-top: var(--w-heavy) solid var(--ink); }
  .frame { grid-template-columns: 1fr; }
  .side { border-left: 0; border-top: var(--w-heavy) solid var(--ink); }
  .zones { display: none; }
}
@media (max-width: 560px) {
  body { font-size: 16px; }
  .sheet { padding: 6px; }
  .frame::before { inset: 4px; }
  .bar { margin-bottom: 22px; }
  .themes button { min-height: 40px; padding: 4px 10px; }
  .bar nav a { min-height: 40px; display: inline-flex; align-items: center; }
  .panel { min-height: 0; }
  figure.fig svg { min-width: 760px; }
  figure.fig::after { content: "Drag sideways for the full figure"; display: block; font: 11px var(--font-label); letter-spacing: .14em; color: var(--mute); margin-top: 6px; position: sticky; left: 0; }
  figure.fig figcaption { position: sticky; left: 0; }
  .prose table { font-size: 13.5px; display: block; max-width: 100%; overflow-x: auto; }
}
@media print { .themes { display: none; } }
