/* ==========================================================================
   linkedin.ivaraa.studio: the notebook.
   Default mode. AI slop mode lives in slop.css and only overrides this file.

   Colour logic (so the highlights are art-directed, not random):
   blue   = LinkedIn, the network, distribution
   lime   = the opportunity / the realisation (80, biggest channel)
   yellow = marker pen on the phrases worth re-reading
   coral  = problems, cross-outs, warnings (strokes only, never body text)
   lavender = side characters: the team, the platform's clichés
   ========================================================================== */

/* ---------- Fonts (self-hosted, Latin subset) ---------- */
@font-face { font-family: "Archivo Black"; src: url("/assets/fonts/ArchivoBlack-400.woff2") format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "DM Sans"; src: url("/assets/fonts/DMSans-400-700.woff2") format("woff2"); font-weight: 400 700; font-display: swap; }
@font-face { font-family: "Instrument Serif"; src: url("/assets/fonts/InstrumentSerif-400-italic.woff2") format("woff2"); font-style: italic; font-weight: 400; font-display: swap; }
@font-face { font-family: "Caveat"; src: url("/assets/fonts/Caveat-600.woff2") format("woff2"); font-weight: 400 700; font-display: swap; }
@font-face { font-family: "Space Mono"; src: url("/assets/fonts/SpaceMono-400.woff2") format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Space Mono"; src: url("/assets/fonts/SpaceMono-700.woff2") format("woff2"); font-weight: 700; font-display: swap; }
@font-face { font-family: "Permanent Marker"; src: url("/assets/fonts/PermanentMarker-400.woff2") format("woff2"); font-weight: 400; font-display: swap; }

/* Metric-matched fallbacks: keep line boxes the same size while the webfonts load (no layout shift). */
@font-face { font-family: "Archivo Black fb"; src: local("Arial Black"), local("ArialBlack"); size-adjust: 100%; ascent-override: 87.8%; descent-override: 21%; line-gap-override: 0%; }
@font-face { font-family: "DM Sans fb"; src: local("Arial"), local("ArialMT"), local("Helvetica"); size-adjust: 104.4%; ascent-override: 95%; descent-override: 29.7%; line-gap-override: 0%; }
@font-face { font-family: "Instrument Serif fb"; src: local("Times New Roman Italic"), local("TimesNewRomanPS-ItalicMT"), local("Times-Italic"); font-style: italic; size-adjust: 87.5%; ascent-override: 113.1%; descent-override: 35.4%; line-gap-override: 0%; }
@font-face { font-family: "Caveat fb"; src: local("Arial"), local("ArialMT"), local("Helvetica"); size-adjust: 76.6%; ascent-override: 125.3%; descent-override: 39.2%; line-gap-override: 0%; }
@font-face { font-family: "Space Mono fb"; src: local("Courier New"), local("CourierNewPSMT"), local("Courier"); size-adjust: 102%; ascent-override: 109.8%; descent-override: 35.4%; line-gap-override: 0%; }
@font-face { font-family: "Permanent Marker fb"; src: local("Arial Bold"), local("Arial-BoldMT"); font-weight: 400; size-adjust: 105.6%; ascent-override: 105.1%; descent-override: 30.1%; line-gap-override: 2.9%; }

/* ---------- Tokens ---------- */
:root {
  --paper: #F2F0E8;
  --ink: #171717;
  --ink-soft: #4a4944;
  --blue: #3449FF;
  --lime: #D7FF55;
  --coral: #FF765E;
  --yellow: #FFE66D;
  --lav: #B9A5FF;
  --grey: #A6A69E;
  --rule-c: rgba(23, 23, 23, .085);

  --f-body: "DM Sans", "DM Sans fb", system-ui, sans-serif;
  --f-display: "Archivo Black", "Archivo Black fb", "Arial Black", sans-serif;
  --f-serif: "Instrument Serif", "Instrument Serif fb", Georgia, serif;
  --f-hand: "Caveat", "Caveat fb", "Segoe Print", cursive;
  --f-mono: "Space Mono", "Space Mono fb", ui-monospace, monospace;
  --f-marker: "Permanent Marker", "Permanent Marker fb", "Arial Black", sans-serif;

  /* The page grid. Everything in the letter sits on these ruled lines. */
  --fs: 1.25rem;                                       /* body size */
  --rule: 2rem;                                        /* ruled-line spacing = body line height */
  --base: calc(var(--rule) / 2 + .341 * var(--fs));    /* where a DM Sans baseline lands inside one line */
  --measure: 44rem;                                    /* ~68ch of running text */
  --col-l: calc(50vw - var(--measure) / 2);            /* left edge of the text column */
  --cw: var(--measure);                                /* column width, used to size the giant words */

  --u-scribble: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 60 10' preserveAspectRatio='none'%3E%3Cpath d='M1 6 C 8 1.5, 14 9.5, 21 5 S 34 1.5, 41 6 S 54 8.5, 59 3.5' fill='none' stroke='%23FF765E' stroke-width='2.6' stroke-linecap='round'/%3E%3C/svg%3E");
  --u-strike: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 120 12' preserveAspectRatio='none'%3E%3Cpath d='M1 7.5 C 30 4, 64 9.5, 119 4.5' fill='none' stroke='%23FF765E' stroke-width='2.6' stroke-linecap='round'/%3E%3Cpath d='M2 4.5 C 40 8.5, 84 3, 118 8' fill='none' stroke='%23FF765E' stroke-width='1.5' stroke-linecap='round'/%3E%3C/svg%3E");
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html {
  background-color: var(--paper);
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  scroll-padding-top: 5rem;
}
body {
  margin: 0;
  min-height: 100vh;
  color: var(--ink);
  font-family: var(--f-body);
  font-size: var(--fs);
  line-height: var(--rule);
  overflow-x: clip;
  font-kerning: normal;
  text-rendering: optimizeLegibility;
}
img, svg { max-width: 100%; }
p, h1, h2, h3 { margin: 0; }
a { color: inherit; }
em { font-style: italic; }
button { font: inherit; color: inherit; }
::selection { background: var(--lime); color: var(--ink); }
[hidden] { display: none !important; }

:focus-visible { outline: 3px solid var(--blue); outline-offset: 4px; border-radius: 2px; }

.sr-only {
  position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}
.skip {
  position: fixed; left: 1rem; top: -4rem; z-index: 100;
  background: var(--ink); color: var(--paper); padding: .5rem 1rem;
  font-family: var(--f-mono); font-size: .9rem; text-decoration: none;
}
.skip:focus { top: 1rem; }
.sprite { position: absolute; width: 0; height: 0; overflow: hidden; }
.slop-only { display: none; }

.doodle, .circled__svg {
  fill: none; stroke: currentColor; stroke-width: 3; stroke-linecap: round; stroke-linejoin: round;
  overflow: visible; pointer-events: none;
}
.draw { stroke-dasharray: 1; stroke-dashoffset: 0; }

/* ==========================================================================
   THE PAGE: one ruled sheet, one long letter
   ========================================================================== */
.page {
  overflow-x: clip; /* stamps, bursts and the 80 zoom may poke past the paper edge; never the viewport */
  position: relative;
  padding-top: calc(var(--rule) * 4);
  background-image: repeating-linear-gradient(to bottom,
    transparent 0, transparent var(--base),
    var(--rule-c) var(--base), var(--rule-c) calc(var(--base) + 1px),
    transparent calc(var(--base) + 1px), transparent var(--rule));
}
.page::before { /* the red margin line */
  content: ""; position: absolute; top: 0; bottom: 0; width: 1px;
  left: calc(var(--col-l) - 1.5rem); background: rgba(255, 118, 94, .55);
}
.col { position: relative; width: var(--cw); margin-left: var(--col-l); }
.letter .col > p, .letter .col > .ps, .letter .col > .beat { margin-bottom: var(--rule); }

.dateline { font-family: var(--f-mono); font-size: .8rem; color: var(--ink-soft); letter-spacing: .04em; }
.dateline__hand { font-family: var(--f-hand); font-size: 1.45rem; line-height: 0; color: var(--blue); margin-left: .6rem; letter-spacing: 0; }

/* ---------- Mid-sentence type switches (never taller than one ruled line) ---------- */
.up { font-size: 1.2em; line-height: 0; }
.serif { font-family: var(--f-serif); font-style: italic; font-weight: 400; letter-spacing: -.005em; }
.serif.up { font-size: 1.38em; }
.serif--blue { color: var(--blue); }
.hand { font-family: var(--f-hand); font-size: 1.4em; line-height: 0; }
.hand.up { font-size: 1.5em; }
.hand--blue { color: var(--blue); }
.ib { display: inline-block; line-height: 1; margin-block: -.5em; vertical-align: baseline; }
.nobr { white-space: nowrap; }

/* ---------- Highlights (drawn on as the reader reaches the line) ---------- */
.hl { -webkit-box-decoration-break: clone; box-decoration-break: clone; background-repeat: no-repeat; transition: background-size .9s cubic-bezier(.6, .1, .2, 1); }
.hl-marker { background-image: linear-gradient(176deg, var(--yellow), var(--yellow)); background-size: 100% 64%; background-position: 0 70%; padding: 0 .16em; margin: 0 -.06em; border-radius: .35em .15em .4em .1em; }
.hl-lime { background-image: linear-gradient(var(--lime), var(--lime)); background-size: 100% 100%; padding: .02em .2em; }
.hl-lav { background-image: linear-gradient(var(--lav), var(--lav)); background-size: 100% 48%; background-position: 0 92%; padding: 0 .12em; }
.hl-blue { color: var(--blue); font-weight: 700; background-image: linear-gradient(var(--blue), var(--blue)); background-size: 100% .12em; background-position: 0 92%; padding-bottom: .06em; }
.hl-scribble { background-image: var(--u-scribble); background-size: 100% .42em; background-position: 0 100%; padding-bottom: .2em; }
.label-lime { background-image: linear-gradient(var(--lime), var(--lime)); background-size: 100% 100%; font-family: var(--f-display); text-transform: uppercase; letter-spacing: -.01em; padding: .04em .25em; }
.hl-ink { background: var(--ink); color: var(--paper); padding: .05em .3em; font-family: var(--f-display); letter-spacing: -.01em; -webkit-box-decoration-break: clone; box-decoration-break: clone; }
.strike, s { text-decoration: none; background: var(--u-strike) no-repeat 0 58% / 100% .62em; -webkit-box-decoration-break: clone; box-decoration-break: clone; transition: background-size .7s cubic-bezier(.6, .1, .2, 1); }
.label-ink { background: var(--ink); color: var(--lime); padding: .06em .22em .02em; transform: rotate(-3deg); font-family: var(--f-display); font-size: 1.55em; letter-spacing: -.02em; }

.motion .hl-marker:not(.lit) { background-size: 0% 64%; }
.motion .hl-lime:not(.lit), .motion .label-lime:not(.lit) { background-size: 0% 100%; }
.motion .hl-lav:not(.lit) { background-size: 0% 48%; }
.motion .hl-blue:not(.lit) { background-size: 0% .12em; }
.motion .hl-scribble:not(.lit) { background-size: 0% .42em; }
.motion :is(.strike, s):not(.lit) { background-size: 0% .62em; }

.circled { position: relative; white-space: nowrap; }
.circled__svg { position: absolute; left: -12%; top: -36%; width: 124%; height: 172%; max-width: none; color: var(--blue); stroke-width: 3.2; }
.circled--coral .circled__svg { color: var(--coral); stroke-width: 2.6; }
.motion .circled__svg { stroke-dashoffset: 1; opacity: 0; transition: stroke-dashoffset 1s cubic-bezier(.6, .1, .2, 1) .1s, opacity 0s .1s; }
/* opacity hides the round line cap, which would otherwise leave a dot before the circle draws */
.motion .circled__svg.lit, .motion .linkedin-word.lit .circled__svg { stroke-dashoffset: 0; opacity: 1; }

/* ---------- Margin notes: annotations beside the line they comment on ---------- */
.mn {
  float: left; clear: left; width: 11rem; margin-left: -13.5rem;
  font-family: var(--f-hand); font-size: 1.4rem; line-height: var(--rule); font-weight: 600;
  color: var(--ink); text-align: right; transform: rotate(var(--r, -3deg)); transform-origin: 100% 0;
  transition: opacity .6s ease, transform .6s cubic-bezier(.3, .7, .2, 1.3);
}
.mn--r { float: right; clear: right; margin-left: 0; margin-right: -14rem; width: 12rem; text-align: left; transform-origin: 0 0; --r: 3deg; }
.mn svg { display: block; color: var(--coral); }
.motion .mn:not(.lit) { opacity: 0; transform: rotate(calc(var(--r, -3deg) * 3)) translateY(10px); }

.mn--seriously { color: var(--blue); font-size: 1.9rem; margin-top: calc(var(--rule) * 2); --r: 6deg; }
.mn--seriously svg { width: 5rem; height: 2.4rem; transform: scaleX(-1) rotate(18deg); margin-top: .4rem; }
.mn--seriously-m { display: none; }
.mn--scroll { color: var(--ink-soft); }
.mn--scroll svg { width: 2rem; height: 4.5rem; margin: .3rem 0 0 auto; }
.mn--twice { color: var(--blue); }
.mn--twice svg { width: 4.5rem; height: 2rem; margin: 0 0 .1rem auto; color: var(--blue); transform: rotate(10deg); }
.mn--away { --r: -5deg; }
.mn--curl svg { width: 8rem; height: 9.5rem; margin-left: auto; color: var(--ink); transform: rotate(-10deg); }
.mn--down svg { width: 2.6rem; height: 6rem; margin: 0 1rem 0 auto; color: var(--coral); }
.steroids-msg { color: var(--blue); font-size: 1.7rem; margin-top: calc(var(--rule) * -3); --r: -4deg; }
.steroids-msg:empty { display: none; }

/* ---------- Giant words. JS snaps each one's baseline onto a ruled line. ---------- */
.giant { display: block; font-weight: 400; line-height: .9; white-space: nowrap; }
.bl { display: inline-block; width: 0; height: 0; vertical-align: baseline; }

.hook { font-weight: 400; }
.g-wtf { font-family: var(--f-display); font-size: calc(var(--cw) / 2.2); letter-spacing: -.055em; margin-left: -.06em; cursor: default; }
.wl { display: inline-block; transform-origin: 50% 80%; }
.intro .wl { opacity: 0; }
.g-website { text-align: right; font-size: calc(var(--cw) / 10.6); padding-right: .3em; }
.w-isthis { font-family: var(--f-hand); font-size: .55em; display: inline-block; transform: rotate(-6deg) translateY(-.2em); }
.w-website { font-family: var(--f-serif); font-style: italic; font-size: 1.85em; letter-spacing: -.02em; }
.g-q { font-family: var(--f-marker); font-size: 2em; color: var(--coral); -webkit-text-stroke: .025em var(--ink); paint-order: stroke fill; display: inline-block; transform: rotate(12deg); margin-left: -.06em; line-height: 0; }

.drop { }
.drop .hl-lav { white-space: nowrap; }
.linkedin-word {
  float: left; position: relative; margin: 0 .25em 0 -.04em;
  font-family: var(--f-display); font-size: calc(var(--cw) / 8.6); line-height: calc(var(--rule) * 3);
  letter-spacing: -.045em; color: var(--blue); text-decoration: none; padding-right: .02em;
}
.linkedin-word .circled__svg { stroke-width: 1.6; color: var(--ink); left: -5%; top: 4%; width: 110%; height: 92%; }
.linkedin-dot { float: left; font-family: var(--f-marker); font-size: calc(var(--cw) / 8.6); line-height: calc(var(--rule) * 3); color: var(--coral); -webkit-text-stroke: 2px var(--ink); paint-order: stroke fill; margin: 0 .35em 0 -.2em; }

.runin { display: inline; font-weight: 400; font-size: 1em; }
.runin + p { display: inline; }
.runin + p::after { content: ""; display: block; height: var(--rule); }
.runin--twist, .runin--we { font-weight: 700; }
.runin--we { font-family: var(--f-marker); font-weight: 400; font-size: 1.35em; line-height: 0; letter-spacing: .01em; }
.g-founder { font-family: var(--f-display); text-transform: uppercase; font-size: calc(var(--cw) / 5.5); letter-spacing: -.05em; margin-left: -.05em; }
.g-great { font-family: var(--f-display); font-size: 1.35em; line-height: 0; letter-spacing: -.02em; }

/* Roles, written inline: name → what they do */
.roles { line-height: var(--rule); }
.role { white-space: nowrap; display: inline-block; line-height: 1; margin-right: .6em; vertical-align: baseline; }
.rn { font-weight: 400; text-transform: uppercase; }
.ra { width: 2.2em; height: 1em; vertical-align: -.15em; margin: 0 .25em; color: var(--coral); stroke-width: 3.2; }
.rd { font-family: var(--f-hand); font-size: 1.45em; }
.r-founder .rn { font-family: var(--f-display); font-size: 1.5em; letter-spacing: -.03em; }
.r-founder .rd { background: linear-gradient(transparent 55%, var(--lime) 55%, var(--lime) 92%, transparent 92%); }
.r-dev .rn { font-family: var(--f-mono); font-weight: 700; color: var(--blue); font-size: 1.05em; text-decoration: underline 2px; text-underline-offset: .2em; }
.r-design .rn { font-family: var(--f-serif); font-style: italic; text-transform: none; font-size: 1.7em; }
.r-sales .rn { font-family: var(--f-display); background: var(--coral); padding: .06em .25em; font-size: 1.05em; border: 2px solid var(--ink); box-shadow: 3px 3px 0 var(--ink); display: inline-block; transform: rotate(2deg); }
.r-all .rn { font-family: var(--f-display); font-size: 1.4em; color: var(--lav); -webkit-text-stroke: 1.5px var(--ink); paint-order: stroke fill; letter-spacing: -.02em; }
.r-all .rd { color: var(--blue); }

/* The 80 beat: one big moment in the middle of the letter */
.beat__stage { position: relative; height: calc(var(--rule) * 14); display: grid; place-items: center; }
.eighty-h { font-weight: 400; line-height: 1; position: relative; z-index: 1; }
.eighty {
  position: relative; isolation: isolate; background: none; border: 0; padding: 0 .04em; cursor: pointer;
  font-family: var(--f-display); font-size: min(calc(var(--cw) / 1.62), 27rem); line-height: .78; letter-spacing: -.07em;
  color: var(--blue); display: inline-flex; align-items: baseline;
}
.eighty::before {
  content: ""; position: absolute; z-index: -1; left: -6%; right: -3%; top: 48%; height: 40%;
  background: var(--lime); border-radius: .04em .1em .05em .08em;
  transform: rotate(-2.5deg) skewX(-10deg) scaleX(var(--hl, 1)); transform-origin: 0 50%;
}
.eighty__num { font-variant-numeric: tabular-nums; display: inline-block; min-width: 1.32em; text-align: right; }
.eighty__dot { font-family: var(--f-marker); font-size: .9em; letter-spacing: 0; margin-left: .02em; color: var(--coral); -webkit-text-stroke: .015em var(--ink); paint-order: stroke fill; }
.eighty:focus-visible { outline-offset: 10px; }
.a80 { position: absolute; font-family: var(--f-hand); font-weight: 600; font-size: 1.6rem; line-height: 1; }
.a80--a { left: -1rem; top: 12%; transform: rotate(-8deg); }
.a80--b { right: -2rem; top: 8%; transform: rotate(6deg); color: var(--blue); text-align: right; }
.a80--c { right: -1rem; bottom: 4%; transform: rotate(-4deg); display: flex; align-items: flex-end; gap: .3rem; }
.a80--c svg { width: 2.6rem; height: 2.6rem; color: var(--coral); transform: scaleX(-1); order: -1; }
.eq { position: absolute; inset: 0; display: none; flex-direction: column; align-items: center; justify-content: center; gap: 1rem; pointer-events: none; z-index: 2; }
.motion .eq { display: flex; }
.eq__people { display: flex; gap: .5rem; color: var(--ink); }
.eq__p { width: 1.6rem; height: 2.7rem; stroke-width: 2.5; }
.eq__row { display: flex; align-items: center; gap: 1.2rem; font-family: var(--f-display); font-size: clamp(2.4rem, 7vw, 4.8rem); line-height: 1; letter-spacing: -.03em; }
.eq__t { display: flex; flex-direction: column; align-items: center; }
.eq__t small { font-family: var(--f-hand); font-size: .34em; letter-spacing: 0; color: var(--blue); margin-top: .2rem; }
.eq__x { color: var(--coral); font-family: var(--f-body); font-weight: 700; }
.maths {
  position: absolute; left: 50%; bottom: -.5rem; transform: translateX(-50%) rotate(-2deg); width: max-content; max-width: 100%; z-index: 3;
  text-align: center; font-family: var(--f-hand); font-weight: 600; font-size: 1.9rem; line-height: 1.1;
  background: var(--paper); padding: .2rem .6rem; border: 2px solid var(--ink); box-shadow: 4px 4px 0 var(--ink);
}
.maths span:first-child { background: var(--yellow); padding: 0 .2em; }
.maths span:last-child { display: block; color: var(--blue); }

/* ON STEROIDS */
.g-steroids { font-family: var(--f-display); text-transform: uppercase; font-size: calc(var(--cw) / 6.6); letter-spacing: -.045em; margin-left: -.15em; }
.boom {
  position: relative; display: inline-block; line-height: .95; padding: .06em .2em .1em .18em;
  background: var(--ink); color: var(--lime); transform: rotate(-2.5deg); box-shadow: .06em .06em 0 var(--coral);
}
.t-on { font-family: var(--f-serif); font-style: italic; text-transform: none; letter-spacing: 0; color: var(--yellow); font-size: .5em; }
.steroids-word { background: none; border: 0; padding: 0; margin: 0; cursor: pointer; font: inherit; letter-spacing: inherit; text-transform: inherit; color: inherit; line-height: inherit; display: inline-block; transform-origin: 50% 80%; }
.steroids-word:hover { color: var(--yellow); }
.steroids-word:focus-visible { outline-color: var(--lime); }
.boom-burst { position: absolute; right: -.5em; top: -.55em; width: .9em; height: .9em; color: var(--yellow); pointer-events: none; }
.boom-burst svg { width: 100%; height: 100%; stroke-width: 8; filter: drop-shadow(2px 2px 0 var(--ink)); }
.boom.pulse { animation: heartbeat 2.6s ease-in-out infinite; }
.boom.pulse .boom-burst { animation: spin 9s linear infinite; }
.boom.is-pumped { animation: pump .9s cubic-bezier(.3, .7, .2, 1.2); }
@keyframes heartbeat { 0%, 70%, 100% { transform: rotate(-2.5deg) scale(1); } 76% { transform: rotate(-3.5deg) scale(1.035); } 82% { transform: rotate(-2deg) scale(.99); } 88% { transform: rotate(-3deg) scale(1.02); } }
@keyframes spin { to { transform: rotate(360deg); } }
@keyframes pump { 0% { transform: rotate(-2.5deg); } 15% { transform: rotate(-5deg) scale(1.14, .9); } 35% { transform: rotate(1deg) scale(.94, 1.1); } 55% { transform: rotate(-4deg) scale(1.08); } 75% { transform: rotate(-1deg) translateX(-.03em); } 100% { transform: rotate(-2.5deg); } }
.flex-tag {
  position: absolute; left: var(--x, 50%); top: 10%; pointer-events: none; white-space: nowrap;
  font-family: var(--f-mono); font-weight: 700; font-size: 1rem; letter-spacing: 0; text-transform: none;
  background: var(--lime); color: var(--ink); border: 2px solid var(--ink); padding: .15rem .45rem; line-height: 1.2;
  animation: floatup 1.5s cubic-bezier(.2, .7, .3, 1) forwards;
}
@keyframes floatup { 0% { opacity: 0; transform: translate(-50%, 0) rotate(var(--rot, 0deg)) scale(.7); } 15% { opacity: 1; } 100% { opacity: 0; transform: translate(-50%, -180%) rotate(var(--rot, 0deg)) scale(1); } }

.not { white-space: nowrap; font-family: var(--f-mono); font-size: .85em; color: var(--ink-soft); }
.not svg { width: .9em; height: .9em; color: var(--coral); vertical-align: -.1em; margin-right: .3em; stroke-width: 4; }
.grow { line-height: 0; }
.grow--1 { font-weight: 600; }
.grow--2 { font-family: var(--f-serif); font-style: italic; font-size: 1.4em; }
.grow--3 { font-family: var(--f-display); font-size: 1.15em; letter-spacing: -.02em; }

.g-relax { font-family: var(--f-hand); font-weight: 700; font-size: calc(var(--cw) / 8.4); transform: rotate(-3deg); transform-origin: 0 100%; padding-left: .3em; }
.relax .mn--down { margin-top: calc(var(--rule) * 1); }
.nope { white-space: nowrap; font-family: var(--f-hand); font-size: 1.4em; line-height: 0; }
.nope__no { font-family: var(--f-mono); font-weight: 700; font-size: .48em; background: var(--ink); color: var(--paper); padding: .05em .35em; vertical-align: .3em; letter-spacing: .05em; text-transform: uppercase; }

.quote { font-family: var(--f-serif); font-style: italic; font-size: 1.4em; line-height: 0; }
.quote .hl-blue { font-weight: 400; }
.final { margin-bottom: var(--rule); font-family: var(--f-display); font-weight: 400; text-transform: uppercase; font-size: calc(var(--cw) / 8.2); line-height: .95; letter-spacing: -.045em; }
.final > span { display: block; white-space: nowrap; }
.final .f2 { padding-left: 8%; }
.final em { font-family: var(--f-serif); text-transform: none; letter-spacing: -.01em; color: var(--blue); font-size: 1.12em; }
.final .f3 { display: inline-block; margin-top: .06em; padding: .02em .2em .06em; background: var(--ink); color: var(--lime); transform: rotate(-2deg); box-shadow: .06em .06em 0 var(--coral); }

.signoff { font-family: var(--f-hand); font-size: 1.6rem; }
.signoff__name { font-family: var(--f-marker); font-size: 1.5rem; }
.ps__line { font-family: var(--f-hand); font-size: 1.55rem; }
.ps__label { font-family: var(--f-marker); color: var(--coral); -webkit-text-stroke: .5px var(--ink); margin-right: .3rem; }
.contact__list { list-style: none; padding: 0; margin: var(--rule) 0 0; display: flex; flex-wrap: wrap; gap: 1.4rem 1.6rem; }
.contact__link {
  display: flex; flex-direction: column; gap: .2rem; min-height: 44px; line-height: 1.2;
  padding: .8rem 1.2rem .9rem; text-decoration: none; color: var(--ink);
  border: 3px solid var(--ink); box-shadow: 6px 6px 0 var(--ink);
  transition: transform .15s ease, box-shadow .15s ease;
}
.contact__list li:nth-child(1) .contact__link { background: var(--yellow); transform: rotate(-1.5deg); }
.contact__list li:nth-child(2) .contact__link { background: var(--lime); transform: rotate(1deg); }
.contact__list li:nth-child(3) .contact__link { background: var(--lav); transform: rotate(-.6deg); }
.contact__link:hover { transform: rotate(0) translate(-3px, -3px) !important; box-shadow: 9px 9px 0 var(--ink); }
.contact__link:active { transform: translate(4px, 4px) !important; box-shadow: 2px 2px 0 var(--ink); }
.contact__verb { font-family: var(--f-hand); font-size: 1.5rem; line-height: 1; }
.contact__val { font-family: var(--f-display); font-size: 1.25rem; letter-spacing: -.02em; overflow-wrap: anywhere; }

/* Footer: the last lines on the page */
.footer { padding: calc(var(--rule) * 2) 0 calc(var(--rule) * 3); }
.footer__big { font-family: var(--f-display); font-size: 1.6em; line-height: 0; letter-spacing: -.03em; }
.footer__big em { font-family: var(--f-serif); color: var(--blue); letter-spacing: 0; font-size: 1.15em; }
.footer__cards { font-family: var(--f-hand); font-size: .9em; letter-spacing: 0; background: var(--yellow); padding: 0 .25em; margin-left: .4em; display: inline-block; line-height: 1; margin-block: -.5em; transform: rotate(-3deg); }
.footer__meta { margin-top: var(--rule); font-family: var(--f-mono); font-size: .8rem; display: flex; flex-wrap: wrap; gap: 0 1.4rem; }
.footer__cheat { font-family: var(--f-mono); font-size: .72rem; color: var(--ink-soft); }

/* Pencil that follows the reading line (desktop + tablet) */
.pencil { position: fixed; left: 0; top: 0; z-index: 30; width: 4.4rem; height: 1.1rem; pointer-events: none; opacity: 0; transform: translate3d(-200px, -200px, 0); }
.pencil svg { display: block; width: 100%; height: 100%; overflow: visible; }
.pencil__body { fill: var(--yellow); stroke: var(--ink); stroke-width: 1.4; }
.pencil__band { fill: var(--grey); stroke: var(--ink); stroke-width: 1.2; }
.pencil__eraser { fill: var(--coral); stroke: var(--ink); stroke-width: 1.4; }
.pencil__wood { fill: #f4d7a8; stroke: var(--ink); stroke-width: 1.4; stroke-linejoin: round; }
.pencil__lead { fill: var(--ink); }
.motion .pencil.on { opacity: 1; }

/* ---------- Progress (a pencil line) ---------- */
.progress { position: fixed; inset: 0 0 auto 0; height: 10px; z-index: 60; pointer-events: none; }
.progress svg { display: block; width: 100%; height: 100%; }
.progress__path {
  fill: none; stroke: var(--blue); stroke-width: 3.2; stroke-linecap: round;
  stroke-dasharray: 1; stroke-dashoffset: 1;
}

/* ---------- Top bar ---------- */
.topbar {
  position: fixed; inset: 0 0 auto 0; z-index: 50;
  display: flex; align-items: center; gap: 1rem;
  padding: .7rem clamp(1rem, 4vw, 3rem) .6rem;
  background: linear-gradient(rgba(242, 240, 232, .96) 75%, rgba(242, 240, 232, 0));
}
.brand { display: inline-flex; align-items: baseline; gap: .15rem; text-decoration: none; font-family: var(--f-mono); font-size: .85rem; line-height: 1.2; margin-right: auto; }
.brand__mark { width: .7rem; height: .7rem; background: var(--ink); align-self: center; margin-right: .45rem; box-shadow: 3px 3px 0 var(--lime); transform: rotate(-6deg); }
.brand__name { font-weight: 700; }
.brand__sub { color: var(--blue); }

.slop-toggle {
  display: inline-flex; align-items: center; gap: .6rem;
  background: none; border: 0; padding: .3rem .2rem; cursor: pointer; text-align: right;
}
.slop-toggle__label { font-family: var(--f-hand); font-size: 1.35rem; line-height: 1; }
.slop-toggle__track {
  position: relative; flex: none; width: 2.9rem; height: 1.55rem;
  border: 2px solid var(--ink); border-radius: 1rem; background: var(--paper);
  box-shadow: 2px 2px 0 var(--ink);
  transition: background .25s ease;
}
.slop-toggle__thumb {
  position: absolute; top: 2px; left: 2px; width: 1.05rem; height: 1.05rem; border-radius: 50%;
  background: var(--ink); transition: transform .25s cubic-bezier(.3,.7,.2,1.3);
}
.slop-toggle[aria-checked="true"] .slop-toggle__track { background: linear-gradient(135deg, #8b5cf6, #6366f1); }
.slop-toggle[aria-checked="true"] .slop-toggle__thumb { transform: translateX(1.32rem); background: #fff; }
.slop-toggle:hover .slop-toggle__track { background: var(--lime); }


/* ===== Sticky CTA on small screens ===== */
.sticky-talk {
  position: fixed; right: 1rem; bottom: max(1rem, env(safe-area-inset-bottom)); z-index: 40;
  display: none; align-items: center; gap: .3rem;
  font-family: var(--f-marker); font-size: 1.15rem; line-height: 1; text-decoration: none;
  background: var(--lime); border: 2.5px solid var(--ink); box-shadow: 4px 4px 0 var(--ink);
  padding: .65rem .85rem .6rem; transform: rotate(-3deg) translateY(160%);
  transition: transform .35s cubic-bezier(.3,.7,.2,1.2);
}
.sticky-talk svg { width: 2rem; height: 1rem; }
.sticky-talk.is-visible { transform: rotate(-3deg); }

/* ===== Toast ===== */
.toast {
  position: fixed; left: 50%; top: 4.6rem; z-index: 70; pointer-events: none;
  font-family: var(--f-hand); font-size: clamp(1.5rem, 3vw, 1.9rem); line-height: 1.1; text-align: center;
  background: var(--yellow); color: var(--ink); border: 2px solid var(--ink); box-shadow: 4px 4px 0 var(--ink);
  padding: .5rem 1rem; max-width: min(92vw, 30rem);
  opacity: 0; transform: translate(-50%, -1rem) rotate(-2deg); transition: opacity .25s ease, transform .3s ease;
}
.toast.is-on { opacity: 1; transform: translate(-50%, 0) rotate(-2deg); }
.toast:empty { display: none; }

/* ===== Konami dialog ===== */
.konami {
  max-width: min(92vw, 32rem); padding: 2rem 2rem 1.6rem; border: 3px solid var(--ink); box-shadow: 10px 10px 0 var(--ink);
  background: var(--lime); color: var(--ink); transform: rotate(-1.5deg);
}
.konami::backdrop { background: rgba(23, 23, 23, .55); }
.konami__eyebrow { font-family: var(--f-mono); font-size: .8rem; text-transform: uppercase; letter-spacing: .08em; line-height: 1.4; }
.konami__title { font-family: var(--f-display); font-size: clamp(1.6rem, 4vw, 2.2rem); line-height: 1.08; letter-spacing: -.03em; margin-top: .6rem; }
.konami__aside { font-family: var(--f-hand); font-size: 1.6rem; line-height: 1.15; margin-top: 1rem; }
.konami form { margin-top: 1.4rem; }
.konami__close { background: var(--ink); color: var(--paper); border: 0; padding: .6rem 1.1rem; font-family: var(--f-mono); font-size: .95rem; cursor: pointer; min-height: 44px; }
.konami__close:hover { background: var(--blue); }
@media (prefers-reduced-motion: no-preference) {
  .konami[open] { animation: pop .35s cubic-bezier(.3,.7,.2,1.4); }
}

/* ===== Cursor annotation (fine pointers only; the native cursor stays) ===== */
.cursor-note { display: none; }
@media (hover: hover) and (pointer: fine) {
  .cursor-note {
    display: block; position: fixed; left: 0; top: 0; z-index: 80; pointer-events: none;
    transform: translate3d(var(--cx, -100px), var(--cy, -100px), 0);
  }
  .cursor-note__dot { position: absolute; left: -4px; top: -4px; width: 8px; height: 8px; border-radius: 50%; background: var(--blue); opacity: .0; transition: opacity .2s; }
  .cursor-note.is-moving .cursor-note__dot { opacity: .55; }
  .cursor-note__text {
    position: absolute; left: 16px; top: 18px; white-space: nowrap;
    font-family: var(--f-hand); font-size: 1.35rem; line-height: 1; color: var(--ink);
    background: var(--lime); border: 1.5px solid var(--ink); padding: .2rem .45rem;
    transform: rotate(-4deg) scale(.6); opacity: 0; transform-origin: 0 0;
    transition: opacity .15s ease, transform .2s cubic-bezier(.3,.7,.2,1.4);
  }
  .cursor-note.has-text .cursor-note__text { opacity: 1; transform: rotate(-4deg) scale(1); }
}


/* ==========================================================================
   Responsive: the same letter, re-set for each page size
   ========================================================================== */
/* Narrower desktops and tablets: one wide margin on the left holds every note */
@media (max-width: 1199px) {
  :root { --col-l: 13.5rem; --cw: min(var(--measure), calc(100vw - 16rem)); }
  .mn--r { float: left; clear: left; margin-left: -12.5rem; margin-right: 0; width: 10.5rem; text-align: right; transform-origin: 100% 0; --r: -3deg; }
  .mn { width: 10.5rem; margin-left: -12.5rem; font-size: 1.3rem; }
  .mn--seriously { font-size: 1.6rem; }
  .a80--a { left: 0; } .a80--b { right: 0; } .a80--c { right: 0; }
}

/* Phones: a handwritten page. Notes drop into the flow as their own ruled lines. */
@media (max-width: 700px) {
  :root { --fs: 1.0625rem; --rule: 1.75rem; --col-l: 2.5rem; --cw: calc(100vw - 3.75rem); }
  .page { padding-top: calc(var(--rule) * 3); }
  .page::before { left: 1.4rem; }
  .topbar { padding-left: 1rem !important; }
  .brand { font-size: .78rem; }
  .brand__sub { display: none; }
  .slop-toggle__label { font-size: 1.12rem; max-width: 9rem; }

  .mn, .mn--r {
    float: none; display: block; width: auto; margin: 0 0 0 auto; max-width: 80%;
    font-size: 1.3rem; text-align: right; transform-origin: 100% 50%; --r: -2deg;
  }
  .mn svg, .mn--curl, .mn--down { display: none; }
  /* phones: LinkedIn. gets its own lines, the sentence runs full width below */
  .linkedin-word { float: none; display: inline-block; font-size: calc(var(--cw) / 5.6); line-height: calc(var(--rule) * 3); margin-right: 0; }
  .linkedin-dot { float: none; display: inline; font-size: calc(var(--cw) / 5.6); line-height: 0; margin: 0; }
  .linkedin-dot::after { content: "\A"; white-space: pre; }
  .mn--seriously { display: none; }
  .mn--seriously-m { display: block; margin: 0 0 0 auto; width: max-content; font-family: var(--f-hand); font-weight: 600; font-size: 1.45rem; line-height: var(--rule); color: var(--blue); transform: rotate(-3deg); }
  .steroids-msg { margin-top: 0; font-size: 1.4rem; }
  .dateline__hand { display: none; }

  .ra { width: 1.6em; }
  .roles { line-height: var(--rule) !important; }
  .role { display: block; white-space: normal; line-height: var(--rule); margin: 0 0 calc(var(--rule) * .5); }
  .role:last-child { margin-bottom: 0; }
  .eq__p { width: 1.05rem; height: 1.8rem; }
  .eq__people { gap: .25rem; }
  .eq__row { gap: .5rem; font-size: 2.2rem; }
  .beat__stage { height: calc(var(--rule) * 11); }
  .a80 { font-size: 1.15rem; }
  .a80--a { left: 0; top: 2%; } .a80--b { right: 0; top: 2%; } .a80--c { right: 0; bottom: 1%; }
  .a80--c svg { width: 1.8rem; height: 1.8rem; }
  .maths { font-size: 1.35rem; }
  .contact__list { flex-direction: column; gap: 1rem; }
  .contact__link { width: 100%; }
  .footer__big { font-size: 1.3em; line-height: calc(var(--rule) * 1.5); }
  .footer__cards { display: table; margin: calc(var(--rule) * .25) 0 0; }
  .pencil { width: 2.6rem; height: .65rem; }
  .sticky-talk { display: inline-flex; }
}

@media (max-width: 380px) {
  .slop-toggle__label { font-size: 1rem; max-width: 7.6rem; }
  .brand__name { font-size: .72rem; }
}

/* ===== Reduced motion: everything readable, nothing moves ===== */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; }
}

/* ===== Mode switch: the new page wipes in from the toggle (View Transitions) ===== */
::view-transition-old(root) { animation: none; }
::view-transition-new(root) { animation: vt-wipe .6s cubic-bezier(.7, 0, .2, 1) both; }
@keyframes vt-wipe {
  from { clip-path: circle(0 at var(--vt-x, 100%) var(--vt-y, 0)); }
  to { clip-path: circle(160vmax at var(--vt-x, 100%) var(--vt-y, 0)); }
}

/* ===== Still in doubt? / P.P.S. / the seven secrets ===== */
.g-doubt { font-family: var(--f-marker); font-size: calc(var(--cw) / 9.5); color: var(--ink); transform: rotate(-2deg); transform-origin: 0 100%; }
.g-doubt::after { content: ""; display: inline-block; width: .32em; height: .32em; margin-left: .1em; background: var(--coral); border: .05em solid var(--ink); border-radius: 50%; vertical-align: .1em; }
.secrets-hint__where { font-family: var(--f-mono); font-size: .8em; color: var(--ink-soft); }
.pps { margin-top: calc(var(--rule) * 2); }
.pps__big { font-family: var(--f-display); font-size: 1.25em; letter-spacing: -.02em; }
.pps__big em { font-family: var(--f-serif); font-size: 1.15em; letter-spacing: -.01em; }

.egg-you { cursor: pointer; transition: transform .25s cubic-bezier(.3,.7,.2,1.6); }
.egg-you:hover { transform: rotate(-7deg) scale(1.06); }
.egg-you.is-wave { animation: wave .7s ease; }
@keyframes wave { 0%,100% { transform: rotate(-3deg); } 20% { transform: rotate(12deg) scale(1.15); } 45% { transform: rotate(-12deg) scale(1.15); } 70% { transform: rotate(8deg); } }

.eggs { margin-top: var(--rule); }
.eggs__line { font-family: var(--f-hand); font-size: 1.55rem; }
.eggs__n { font-family: var(--f-marker); font-weight: 400; color: var(--blue); font-size: 1.3em; }
.eggs__btn {
  margin-top: var(--rule); font-family: var(--f-marker); font-size: 1.15rem; line-height: 1; cursor: pointer; min-height: 44px;
  background: var(--yellow); color: var(--ink); border: 2.5px solid var(--ink); box-shadow: 4px 4px 0 var(--ink);
  padding: .7rem 1.1rem; transform: rotate(-1.5deg); transition: transform .2s ease, box-shadow .2s ease;
}
.eggs__btn:hover { transform: rotate(1deg) translate(-2px, -2px); box-shadow: 6px 6px 0 var(--ink); }
.eggs__btn:active { transform: translate(3px, 3px); box-shadow: 1px 1px 0 var(--ink); }
.eggs__list { margin: calc(var(--rule) * 1.5) 0 0; padding: 0; list-style: none; counter-reset: egg; display: grid; gap: .9rem; }
.eggs__list li {
  counter-increment: egg; position: relative; padding: .7rem 1rem .7rem 3.2rem; line-height: 1.45;
  background: var(--paper); border: 2px solid var(--ink); box-shadow: 3px 3px 0 var(--ink);
}
.eggs__list li:nth-child(odd) { transform: rotate(-.5deg); }
.eggs__list li:nth-child(even) { transform: rotate(.6deg); }
.eggs__list li::before {
  content: counter(egg); position: absolute; left: .7rem; top: .6rem; width: 1.8rem; height: 1.8rem; display: grid; place-items: center;
  font-family: var(--f-marker); background: var(--ink); color: var(--paper); border-radius: 50%; font-size: .9rem;
}
.eggs__list li.is-found { background: var(--lime); }
.eggs__list li.is-found::before { content: "\2713"; background: var(--blue); }
.eggs__list li.is-found::after { content: "found it"; position: absolute; right: .7rem; top: -.75rem; font-family: var(--f-hand); font-size: 1.2rem; font-weight: 700; color: var(--blue); background: var(--paper); padding: 0 .3rem; transform: rotate(4deg); }
@media (prefers-reduced-motion: no-preference) {
  .eggs__list:not([hidden]) li { animation: dealt .5s cubic-bezier(.3,.7,.2,1.3) both; }
  .eggs__list li:nth-child(2) { animation-delay: .06s; } .eggs__list li:nth-child(3) { animation-delay: .12s; }
  .eggs__list li:nth-child(4) { animation-delay: .18s; } .eggs__list li:nth-child(5) { animation-delay: .24s; }
  .eggs__list li:nth-child(6) { animation-delay: .3s; } .eggs__list li:nth-child(7) { animation-delay: .36s; }
}
@keyframes dealt { from { opacity: 0; transform: translateY(18px) rotate(-6deg); } }

.egg-count {
  position: fixed; left: 1rem; bottom: max(1rem, env(safe-area-inset-bottom)); z-index: 40;
  font-family: var(--f-mono); font-size: .85rem; text-decoration: none; color: var(--ink);
  background: var(--paper); border: 2px solid var(--ink); box-shadow: 3px 3px 0 var(--ink);
  padding: .45rem .7rem; transform: rotate(2deg); transition: transform .3s cubic-bezier(.3,.7,.2,1.4);
}
.egg-count b { font-family: var(--f-marker); font-weight: 400; color: var(--blue); font-size: 1.15em; }
.egg-count:hover { transform: rotate(-2deg) scale(1.05); }
.egg-count.is-pop { animation: eggpop .7s cubic-bezier(.3,.7,.2,1.4); background: var(--lime); }
@keyframes eggpop { 0% { transform: rotate(2deg) scale(1); } 35% { transform: rotate(-8deg) scale(1.35); } 100% { transform: rotate(2deg) scale(1); } }
.egg-count.is-all { background: var(--lime); }
html.slop .egg-count { display: none; }
@media (max-width: 760px) {
  .egg-count { font-size: .75rem; padding: .35rem .55rem; }
  .g-doubt { font-size: calc(var(--cw) / 7.5); }
}
