/* Inkstincts — the public site */

:root { --gutter: clamp(1.1rem, 4vw, 2.5rem); --maxw: 1180px; }

body {
  background:
    radial-gradient(900px 520px at 88% -8%, rgba(232, 184, 79, 0.22), transparent 62%),
    radial-gradient(760px 520px at -8% 28%, rgba(194, 91, 114, 0.1), transparent 60%),
    var(--paper);
  background-attachment: fixed;
}
:root[data-theme='dark'] body {
  background:
    radial-gradient(760px 520px at 88% -6%, rgba(240, 194, 101, 0.15), transparent 60%),
    radial-gradient(900px 600px at 0% 62%, rgba(95, 143, 179, 0.1), transparent 60%),
    var(--paper);
  background-attachment: fixed;
}

#grain {
  position: fixed; inset: 0; z-index: 0; pointer-events: none; opacity: 0.4; mix-blend-mode: multiply;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='220' height='220'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='2' stitchTiles='stitch'/><feColorMatrix values='0 0 0 0 .35  0 0 0 0 .28  0 0 0 0 .2  0 0 0 .32 0'/></filter><rect width='100%' height='100%' filter='url(%23n)'/></svg>");
}
:root[data-theme='dark'] #grain { opacity: 0.16; mix-blend-mode: screen; }

.skip {
  position: absolute; left: 1rem; top: -4rem; z-index: 200; padding: 0.6em 1em;
  background: var(--ink); color: var(--on-ink); border-radius: 10px; text-decoration: none; transition: top 0.2s;
}
.skip:focus { top: 1rem; }

main {
  position: relative; z-index: 2; outline: none;
  width: min(100%, var(--maxw)); margin-inline: auto; padding-inline: var(--gutter); min-height: 70vh;
}

/* ---------- header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 20;
  display: flex; align-items: center; gap: 0.6rem;
  padding: 0.85rem max(var(--gutter), calc((100% - var(--maxw)) / 2 + var(--gutter)));
  background: color-mix(in srgb, var(--paper) 96%, transparent);
  border-bottom: 1.5px dashed transparent;
  transition: border-color 0.3s;
}
.site-header.scrolled { border-bottom-color: var(--line); }

.brand {
  display: inline-flex; align-items: center; gap: 0.55rem; text-decoration: none; color: var(--ink);
  font-family: var(--display); font-size: 1.55rem; font-weight: 600;
  font-variation-settings: 'SOFT' 100, 'WONK' 1; letter-spacing: -0.02em;
}
.brand i { color: var(--rose); }
.brand-logo { height: 36px; width: auto; max-width: 150px; object-fit: contain; }
.brand.has-logo .drop { display: none; }
.brand.logo-only .brand-logo { height: 44px; max-width: 240px; }
.brand.logo-only .brand-name { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; }
.drop { color: var(--rose); transition: transform 0.45s var(--ease); }
.brand:hover .drop { transform: rotate(-14deg) translateY(-2px) scale(1.12); }

.nav {
  margin-left: auto; display: flex; align-items: center; gap: clamp(0.9rem, 2vw, 1.8rem);
  font-family: var(--display); font-size: 1rem; font-weight: 500; font-variation-settings: 'SOFT' 100, 'WONK' 0;
}
.nav a { text-decoration: none; padding: 0.3em 0.1em; text-underline-offset: 7px; text-decoration-thickness: 1.5px; text-decoration-color: var(--gold); }
.nav a:not(.nav-cta):hover, .nav a[aria-current='page']:not(.nav-cta) { text-decoration-line: underline; text-decoration-style: wavy; }
.nav-cta {
  padding: 0.45em 1em !important; background: var(--card); border: 1.5px solid var(--ink);
  border-radius: var(--blob); box-shadow: 3px 3px 0 var(--rose); transition: transform 0.18s var(--ease), box-shadow 0.18s var(--ease);
}
.nav-cta:hover { transform: translate(-1px, -1px) rotate(-1deg); box-shadow: 5px 5px 0 var(--rose); }

.icon-btn {
  width: 42px; height: 42px; display: grid; place-items: center; border: 0; border-radius: 50%;
  background: transparent; color: var(--ink); cursor: pointer; transition: background 0.2s, transform 0.4s var(--ease);
}
.icon-btn:hover { background: color-mix(in srgb, var(--gold) 22%, transparent); transform: rotate(-12deg); }
.i-sun { display: none; }
:root[data-theme='dark'] .i-sun { display: block; color: var(--gold-glow); }
:root[data-theme='dark'] .i-moon { display: none; }

.menu-btn { display: none; position: relative; }
.menu-btn span { position: absolute; left: 10px; width: 22px; height: 2px; background: currentColor; border-radius: 2px; transition: transform 0.3s var(--ease), top 0.3s var(--ease); }
.menu-btn span:nth-child(1) { top: 16px; }
.menu-btn span:nth-child(2) { top: 24px; }
.site-header.open .menu-btn span:nth-child(1) { top: 20px; transform: rotate(45deg); }
.site-header.open .menu-btn span:nth-child(2) { top: 20px; transform: rotate(-45deg); }

@media (max-width: 820px) {
  .theme-toggle { margin-left: auto; }
  .menu-btn { display: block; }
  .nav {
    position: absolute; top: 100%; left: 0; right: 0; margin: 0; flex-direction: column; align-items: flex-start; gap: 0.4rem;
    padding: 0.8rem var(--gutter) 1.6rem; background: var(--paper); border-bottom: 1.5px dashed var(--line);
    font-size: 1.5rem; opacity: 0; visibility: hidden; transform: translateY(-10px);
    transition: opacity 0.3s, transform 0.3s var(--ease), visibility 0.3s;
  }
  .site-header.open .nav { opacity: 1; visibility: visible; transform: none; }
  .nav-cta { margin-top: 0.6rem; font-size: 1.1rem; }
}

/* ---------- loading ---------- */
.loading { padding: 30vh 0; text-align: center; font-family: var(--hand); font-size: 2rem; color: var(--ink-soft); }
.loading span { animation: blink 1.2s infinite; }
.loading span:nth-child(2) { animation-delay: 0.2s; }
.loading span:nth-child(3) { animation-delay: 0.4s; }

/* ---------- reveal ---------- */
.reveal { opacity: 0; translate: 0 26px; transition: opacity 0.8s var(--ease) var(--d, 0ms), translate 0.8s var(--ease) var(--d, 0ms); }
.reveal.in { opacity: 1; translate: 0 0; }

/* ---------- shared bits ---------- */
.note { font-family: var(--hand); font-size: 1.55rem; line-height: 1.1; color: var(--rose); font-weight: 500; }
.section { padding-block: clamp(2.6rem, 7vw, 5.2rem); }
.section.tight { padding-top: 0.6rem; }
.empty { font-family: var(--hand); font-size: 1.7rem; color: var(--ink-soft); padding: 2rem 0; }

.section-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 1rem 2rem; flex-wrap: wrap; margin-bottom: 2rem; }
.section-head h2 { font-size: clamp(2.1rem, 5vw, 3.2rem); }
.more {
  display: inline-flex; align-items: center; gap: 0.5rem; text-decoration: none;
  font-family: var(--display); font-weight: 600; font-size: 1rem; color: var(--ink);
  padding-bottom: 0.2em; border-bottom: 1.5px dashed var(--ink);
}
.arrow { transition: transform 0.3s var(--ease); }
.more:hover .arrow, .post-row a:hover .arrow { transform: translateX(6px); }

.page-head { padding-block: clamp(2.6rem, 6vw, 4.5rem) 1.4rem; display: grid; gap: 0.7rem; justify-items: start; max-width: 760px; }
.page-head h1 { font-size: clamp(3rem, 9vw, 5.6rem); }
.lede { font-size: 1.3rem; line-height: 1.5; color: var(--ink-soft); max-width: 44ch; }
.page-head.lost { min-height: 55vh; align-content: center; }

.filters { display: flex; flex-wrap: wrap; gap: 0.6rem; margin-top: 1rem; }
.filter {
  font-family: var(--display); font-size: 0.95rem; padding: 0.4em 1.05em; cursor: pointer; background: transparent;
  border: 1.5px solid var(--ink); border-radius: 999px 40px 999px 40px / 40px 999px 40px 999px;
  transition: background 0.2s, color 0.2s, transform 0.2s var(--ease);
}
.filter:hover { transform: translateY(-2px) rotate(-1deg); }
.filter.on { background: var(--ink); color: var(--on-ink); }
.filter small { opacity: 0.6; margin-left: 0.25em; }

/* ---------- hero ---------- */
.hero {
  position: relative; min-height: calc(100svh - 76px); display: grid; place-content: center; justify-items: center;
  text-align: center; padding-block: 4rem 6rem;
}
.hero > * { position: relative; }
.hero-note, .hero-tag, .hero-by, .hero-cta, .scroll-cue { opacity: 0; animation: fadeUp 0.9s var(--ease) forwards; }
.hero-note { font-family: var(--hand); font-size: clamp(1.5rem, 3.2vw, 2rem); color: var(--rose); animation-delay: 0.1s; }
.wm {
  font-size: clamp(3.7rem, 16vw, 10.5rem); font-weight: 600; letter-spacing: -0.035em; line-height: 1; margin-top: 0.05em;
  font-variation-settings: 'SOFT' 100, 'WONK' 1;
}
.wm-letters span {
  display: inline-block; opacity: 0; transform: translateY(0.4em) rotate(7deg) scale(0.85); filter: blur(10px);
  animation: inkIn 1s var(--ease) forwards; animation-delay: calc(var(--i) * 75ms + 350ms);
}
.wm .ink { color: var(--rose); font-style: italic; }
.wm.done .wm-letters span { animation: none; opacity: 1; transform: none; filter: none; transition: transform 0.4s var(--ease); cursor: default; }
.wm.done .wm-letters span:hover { transform: translateY(-0.07em) rotate(-5deg); }

.hero .squiggle { width: min(64%, 440px); height: 24px; color: var(--gold); margin-top: 0.1rem; }
.squiggle path { fill: none; stroke: currentColor; stroke-width: 3.5; stroke-linecap: round; stroke-dasharray: 1; stroke-dashoffset: 1; animation: draw 1.3s 1.5s var(--ease) forwards; }
.hero-tag {
  font-family: var(--display); font-style: italic; font-weight: 350; font-size: clamp(1.3rem, 2.7vw, 1.8rem);
  line-height: 1.35; max-width: 28ch; margin-top: 1.5rem; text-wrap: balance; animation-delay: 1.8s;
}
.hero-by { margin-top: 0.7rem; font-size: 1rem; letter-spacing: 0.16em; text-transform: uppercase; color: var(--ink-soft); animation-delay: 2s; }
.hero-by b { color: var(--ink); font-weight: 600; }
.hero-cta { display: flex; flex-wrap: wrap; gap: 1.1rem; justify-content: center; margin-top: 2.2rem; animation-delay: 2.2s; }
.scroll-cue {
  position: absolute !important; bottom: 1.4rem; left: 50%; translate: -50% 0; display: grid; justify-items: center; gap: 0.2rem;
  font-family: var(--hand); font-size: 1.3rem; color: var(--ink-soft); text-decoration: none; animation-delay: 2.8s;
}
.scroll-cue svg { animation: bounce 2s ease-in-out infinite 3.5s; }

.hero-deco { position: absolute; inset: 0; pointer-events: none; }
.deco { position: absolute; transform: translate(calc(var(--mx, 0) * var(--depth, 10) * 1px), calc(var(--my, 0) * var(--depth, 10) * 1px)); transition: transform 0.5s ease-out; }
.deco.d1 { top: 3%; right: 2%; width: clamp(96px, 15vw, 180px); color: var(--gold); }
:root[data-theme='dark'] .deco.d1 { color: var(--gold-glow); }
.moon { width: 100%; height: auto; overflow: visible; animation: bob 8s ease-in-out infinite; }
.deco.d2 { top: 22%; left: 9%; width: 30px; color: var(--gold); }
.deco.d3 { top: 60%; left: 5%; width: 18px; color: var(--rose); }
.deco.d4 { top: 34%; right: 19%; width: 20px; color: var(--sage); }
.deco.d5 { bottom: 22%; right: 8%; width: 28px; color: var(--gold); }
:root[data-theme='dark'] .deco.d2, :root[data-theme='dark'] .deco.d5 { color: var(--gold-glow); }
.tw { animation: twinkle 3.6s ease-in-out infinite var(--td, 0s); }
@media (max-width: 640px) { .deco.d2, .deco.d3, .deco.d4 { display: none; } .deco.d1 { top: 0; right: -4%; } }

/* ---------- story cards ---------- */
.story-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 310px), 1fr)); gap: 2.6rem 2rem; }
.story-grid.two { grid-template-columns: repeat(auto-fit, minmax(min(100%, 340px), 1fr)); }
.story-card {
  --accent: var(--gold); rotate: var(--tilt, 0deg);
  transition: opacity 0.8s var(--ease) var(--d, 0ms), translate 0.8s var(--ease) var(--d, 0ms), rotate 0.35s var(--ease);
}
.story-card:hover { rotate: 0deg; }
.story-card > a {
  display: flex; flex-direction: column; gap: 0.75rem; height: 100%; padding: 1.6rem 1.5rem 1.2rem; text-decoration: none;
  background: var(--card); border: 1.5px solid var(--ink); border-radius: var(--blob); box-shadow: 6px 6px 0 var(--accent);
  transition: box-shadow 0.3s var(--ease), translate 0.3s var(--ease);
}
.story-card:hover > a { box-shadow: 10px 10px 0 var(--accent); translate: -2px -3px; }
.story-card .chip { align-self: flex-start; background: color-mix(in srgb, var(--accent) 24%, transparent); }
.story-card h3 { font-size: clamp(1.55rem, 3vw, 1.85rem); }
.story-card .blurb { font-style: italic; color: var(--ink-soft); font-size: 1.02rem; line-height: 1.4; }
.snippet {
  font-size: 1.03rem; line-height: 1.6; max-height: 8.9em; overflow: hidden;
  -webkit-mask-image: linear-gradient(#000 52%, transparent); mask-image: linear-gradient(#000 52%, transparent);
}
.snippet p { margin: 0 0 0.7em; }
.snippet em { font-style: italic; }
.card-foot {
  margin-top: auto; padding-top: 0.7rem; display: flex; justify-content: space-between; align-items: center; gap: 1rem;
  border-top: 1.5px dashed var(--line); font-size: 0.92rem; color: var(--ink-soft); line-height: 1.3;
}
.card-foot b { color: var(--ink); font-weight: 600; }
.seal { flex: none; transition: transform 0.5s var(--ease); }
.story-card:hover .seal { transform: rotate(20deg) scale(1.12); }

/* ---------- journal ---------- */
.post-list { border-top: 1.5px dashed var(--line); }
.post-row a {
  display: grid; grid-template-columns: 8.5rem 1fr auto; gap: 1.5rem; align-items: baseline; padding: 1.7rem 0.4rem;
  text-decoration: none; border-bottom: 1.5px dashed var(--line); transition: padding 0.35s var(--ease);
}
.post-row a:hover { padding-left: 1.1rem; }
.post-date { font-family: var(--hand); font-size: 1.4rem; color: var(--rose); white-space: nowrap; }
.post-main h3 {
  display: inline; font-size: clamp(1.5rem, 3.2vw, 2rem);
  background: linear-gradient(var(--gold), var(--gold)) 0 100% / 0 3px no-repeat; transition: background-size 0.45s var(--ease);
}
.post-row a:hover h3 { background-size: 100% 3px; }
.post-main p { margin-top: 0.5rem; color: var(--ink-soft); max-width: 60ch; }
.post-main .tags { margin-top: 0.3rem; }
.tags span { font-family: var(--hand); font-size: 1.2rem; color: var(--ink-soft); margin-right: 0.8rem; }
.post-go { color: var(--rose); align-self: center; }
@media (max-width: 680px) {
  .post-row a { grid-template-columns: 1fr; gap: 0.3rem; }
  .post-go { display: none; }
}

/* ---------- books ---------- */
.shelf-strip, .book-grid { list-style: none; margin: 0; padding: 0; display: grid; gap: 2.4rem 1.6rem; }
.shelf-strip { grid-template-columns: repeat(auto-fill, minmax(min(45%, 140px), 1fr)); }
.book-grid { grid-template-columns: repeat(auto-fill, minmax(min(45%, 170px), 1fr)); }
.book-item { display: flex; flex-direction: column; gap: 0.9rem; }
.book {
  position: relative; display: block; width: 100%; aspect-ratio: 2 / 3.05; padding: 0; border: 0; cursor: pointer;
  background: var(--bg); color: var(--fg); border-radius: 3px 9px 9px 3px; transform-origin: left center;
  box-shadow: 5px 6px 0 rgba(42, 36, 64, 0.22), inset 0 0 0 1px rgba(0, 0, 0, 0.06);
  transition: transform 0.45s var(--ease), box-shadow 0.45s var(--ease);
}
:root[data-theme='dark'] .book { box-shadow: 5px 6px 0 rgba(0, 0, 0, 0.4), inset 0 0 0 1px rgba(255, 255, 255, 0.06); }
.book::before {
  content: ''; position: absolute; inset: 0 auto 0 0; width: 9%; border-radius: 3px 0 0 3px;
  background: linear-gradient(90deg, rgba(0, 0, 0, 0.3), rgba(255, 255, 255, 0.1) 65%, rgba(0, 0, 0, 0.08));
}
.book:hover { transform: perspective(900px) rotateY(-17deg) translateY(-6px); box-shadow: 12px 12px 0 rgba(42, 36, 64, 0.2); }
.book-face {
  position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 0.55rem;
  padding: 12% 12% 12% 19%; text-align: center; overflow: hidden; border-radius: inherit;
}
.book-face::after { content: ''; position: absolute; inset: 6% 6% 6% 14%; border: 1.5px solid currentColor; opacity: 0.38; border-radius: 2px; pointer-events: none; }
.book-face.has-img { padding: 0; }
.book-face img { width: 100%; height: 100%; object-fit: cover; }
.book-orn { font-size: 0.9rem; opacity: 0.75; }
.book-title { font-family: var(--display); font-variation-settings: 'SOFT' 100, 'WONK' 1; font-weight: 600; font-size: clamp(1rem, 1.6vw, 1.25rem); line-height: 1.12; text-wrap: balance; }
.book-author { font-size: 0.68rem; letter-spacing: 0.16em; text-transform: uppercase; opacity: 0.8; line-height: 1.3; }
.ribbon {
  position: absolute; top: 12px; right: -9px; padding: 0.05em 0.65em 0.1em; background: var(--rose); color: #fff;
  font-family: var(--hand); font-size: 1.05rem; border-radius: 3px; rotate: 4deg; box-shadow: 2px 2px 0 rgba(0, 0, 0, 0.22);
}
.book-meta { display: flex; flex-direction: column; gap: 0.1rem; line-height: 1.25; }
.book-meta strong { font-family: var(--display); font-size: 1.02rem; font-weight: 600; }
.book-meta span:not(.stars) { font-size: 0.92rem; color: var(--ink-soft); }
.stars i { font-style: normal; font-size: 0.85rem; margin-right: 0.12em; opacity: 0.25; }
.stars i.on { opacity: 1; color: var(--gold); }

/* ---------- dialog ---------- */
dialog {
  position: fixed; border: 1.5px solid var(--ink); border-radius: var(--blob-2); background: var(--paper); color: var(--ink); padding: 0;
  width: min(700px, calc(100vw - 2rem)); max-height: calc(100dvh - 2rem); box-shadow: 9px 9px 0 var(--gold); overflow: auto;
}
dialog[open] { animation: pop 0.5s var(--ease); }
dialog::backdrop { background: rgba(16, 13, 36, 0.58); animation: fade 0.3s; }
.dlg-x {
  position: absolute; top: 0.8rem; right: 1rem; z-index: 2; width: 38px; height: 38px; border: 0; border-radius: 50%; background: transparent;
  font-size: 1.9rem; line-height: 1; cursor: pointer; color: var(--ink-soft); transition: transform 0.3s var(--ease), background 0.2s;
}
.dlg-x:hover { transform: rotate(90deg); background: var(--paper-2); }
.book-dlg { display: grid; grid-template-columns: 170px 1fr; gap: 2rem; padding: 2.2rem; }
.book-dlg-cover {
  position: relative; aspect-ratio: 2 / 3.05; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 0.5rem;
  padding: 12% 12% 12% 19%; text-align: center; background: var(--bg); color: var(--fg); border-radius: 3px 9px 9px 3px;
  box-shadow: 5px 6px 0 rgba(42, 36, 64, 0.22); overflow: hidden;
}
.book-dlg-cover img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.book-dlg-text h2 { font-size: clamp(1.9rem, 4vw, 2.5rem); margin: 0.1rem 0 0.2rem; padding-right: 2rem; }
.book-dlg-text .by { color: var(--ink-soft); margin-bottom: 0.6rem; }
.book-dlg-text .prose { font-size: 1.1rem; line-height: 1.7; margin-top: 1rem; }
.unlock-dlg { padding: 2.6rem 2rem 2.2rem; text-align: center; display: grid; justify-items: center; gap: 0.7rem; }
.unlock-dlg h2 { font-size: clamp(1.9rem, 5vw, 2.6rem); }
.unlock-dlg p:not(.note) { color: var(--ink-soft); max-width: 40ch; }
.unlock-seal { animation: wobble 2.8s ease-in-out infinite; }
.unlock-dlg .nl-form { width: 100%; margin-top: 0.6rem; }
.nl-thanks { font-size: 1.2rem; color: var(--ink) !important; }
@media (max-width: 600px) { .book-dlg { grid-template-columns: 1fr; padding: 1.6rem; } .book-dlg-cover { width: 150px; } }

/* ---------- reading pages ---------- */
.reading { max-width: 700px; margin: 0 auto; padding-block: 2rem 3rem; }
.back { font-family: var(--display); font-size: 0.98rem; text-decoration: none; color: var(--ink-soft); }
.back:hover { color: var(--rose); }
.reading-head { margin: 1.8rem 0 2.6rem; display: grid; gap: 1rem; justify-items: start; }
.reading-head h1 { font-size: clamp(2.4rem, 7vw, 4rem); }
.meta { font-family: var(--hand); font-size: 1.35rem; color: var(--ink-soft); }
.meta b { color: var(--rose); }
.prose.is-cut > :last-child {
  margin-bottom: 0; -webkit-mask-image: linear-gradient(#000 5%, transparent 96%); mask-image: linear-gradient(#000 5%, transparent 96%);
}
.seal-card {
  position: relative; margin-top: 4.6rem; padding: 0 1.5rem 2rem; text-align: center; display: grid; justify-items: center; gap: 0.8rem;
  background: var(--card); border: 1.5px solid var(--ink); border-radius: var(--blob); box-shadow: 7px 7px 0 var(--rose);
}
.seal-btn { margin-top: -3.1rem; padding: 0; border: 0; background: none; cursor: pointer; filter: drop-shadow(0 6px 0 rgba(42, 36, 64, 0.2)); }
.seal-btn:hover { animation: wobble 0.7s; }
.seal-card h2 { font-size: clamp(1.8rem, 4.5vw, 2.4rem); }
.seal-card p b { font-weight: 600; }
.row { display: flex; flex-wrap: wrap; gap: 1rem; justify-content: center; margin-top: 0.5rem; }
.tiny { font-family: var(--hand); font-size: 1.25rem; color: var(--ink-soft); }
.preview-note { margin: 2.6rem 0 1.6rem; padding: 1rem 1.3rem; font-size: 1rem; border: 1.5px dashed var(--rose); border-radius: var(--blob); }
.preview-note span { font-family: var(--hand); font-size: 1.35rem; color: var(--rose); }
.end-mark { text-align: center; color: var(--gold); font-size: 1.4rem; margin-top: 1rem; }

/* ---------- about ---------- */
.about { display: grid; grid-template-columns: minmax(230px, 340px) 1fr; gap: clamp(2rem, 6vw, 5rem); padding-block: clamp(2.6rem, 6vw, 4.5rem); align-items: start; }
.portrait {
  position: relative; aspect-ratio: 3 / 4; display: grid; place-items: center; background: var(--paper-2);
  border: 1.5px solid var(--ink); border-radius: 999px 999px 26px 26px; box-shadow: 9px 9px 0 var(--rose);
}
.portrait > span { font-family: var(--display); font-variation-settings: 'SOFT' 100, 'WONK' 1; font-style: italic; font-size: clamp(4.5rem, 11vw, 7rem); color: var(--rose); }
.portrait img { width: 100%; height: 100%; object-fit: cover; border-radius: inherit; }
.p-star { position: absolute; width: 34px; color: var(--gold); top: 6%; right: -12px; }
.p-star.b { width: 20px; top: auto; bottom: 14%; left: -12px; color: var(--sage); }
.now-card { margin-top: 2.4rem; padding: 1.1rem 1.4rem 1.2rem; background: var(--card); border: 1.5px solid var(--ink); border-radius: var(--blob-2); rotate: -1.3deg; box-shadow: 5px 5px 0 var(--gold); }
.now-card dl { margin: 0.4rem 0 0; display: grid; gap: 0.55rem; }
.now-card dt { font-family: var(--hand); font-size: 1.25rem; color: var(--rose); line-height: 1; }
.now-card dd { margin: 0; font-size: 1.02rem; line-height: 1.35; }
.about-text h1 { font-size: clamp(3.2rem, 8vw, 5.4rem); margin: 0.2rem 0 1.4rem; }
.sign { font-family: var(--hand); font-size: 2.2rem; color: var(--rose); margin: 0.6rem 0 1.4rem; }
@media (max-width: 760px) { .about { grid-template-columns: 1fr; } .about-side { max-width: 340px; } }

/* ---------- newsletter ---------- */
.nl {
  position: relative; overflow: hidden; display: grid; grid-template-columns: auto 1fr; gap: clamp(1.5rem, 4vw, 3.5rem); align-items: center;
  padding: clamp(1.8rem, 4vw, 3.2rem); background: var(--paper-2); border: 1.5px solid var(--ink); border-radius: var(--blob); box-shadow: 8px 8px 0 var(--sage);
}
.nl-copy { display: grid; gap: 0.6rem; justify-items: start; }
.nl-copy h2 { font-size: clamp(2.1rem, 5vw, 3.2rem); }
.nl-copy > p:not(.note):not(.nl-done) { color: var(--ink-soft); max-width: 44ch; }
.nl-art { width: clamp(140px, 22vw, 230px); color: var(--ink); }
.envelope { width: 100%; height: auto; overflow: visible; animation: bob 6s ease-in-out infinite; }
.envelope * { stroke-linejoin: round; }
.env-back { fill: var(--rose); stroke: var(--ink); stroke-width: 2.5; }
.env-letter { color: var(--ink); transition: transform 0.7s var(--ease); }
.env-letter rect { fill: var(--card); stroke: var(--ink); stroke-width: 2.5; }
.env-front { fill: color-mix(in srgb, var(--rose) 82%, #fff); stroke: var(--ink); stroke-width: 2.5; }
.env-flap { transform-box: fill-box; transform-origin: 50% 0; transform: scaleY(-1); transition: transform 0.7s 0.5s var(--ease); }
.env-flap path { fill: var(--rose); stroke: var(--ink); stroke-width: 2.5; }
.env-dot { fill: var(--gold); stroke: var(--ink); stroke-width: 2.5; opacity: 0; transition: opacity 0.3s 1.1s; }
.nl.sent .env-letter { transform: translateY(34px); }
.nl.sent .env-flap { transform: scaleY(1); }
.nl.sent .env-dot { opacity: 1; }
.nl.sent .envelope { animation: hop 0.9s 1.2s var(--ease); }
.nl-form { display: flex; flex-wrap: wrap; gap: 0.8rem; width: 100%; max-width: 520px; margin-top: 0.8rem; }
.nl-form input[type='email'] {
  flex: 1 1 220px; min-width: 0; padding: 0.8em 1.1em; background: var(--card); border: 1.5px solid var(--ink); border-radius: var(--blob-2); font-size: 1.05rem;
}
.nl-form input::placeholder { color: var(--ink-soft); opacity: 0.7; }
.nl-form input:focus-visible { outline-offset: 3px; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }
.nl-msg { flex-basis: 100%; min-height: 1.4em; font-size: 0.98rem; color: var(--rose); }
.nl-done { display: none; font-size: 1.25rem; }
.nl.sent .nl-form { display: none; }
.nl.sent .nl-done { display: block; animation: fadeUp 0.8s 1.3s var(--ease) both; }
@media (max-width: 720px) { .nl { grid-template-columns: 1fr; justify-items: center; text-align: center; } .nl-copy { justify-items: center; } }

/* ---------- footer ---------- */
.site-footer { position: relative; z-index: 2; text-align: center; padding: 3.5rem var(--gutter) 3.2rem; color: var(--ink-soft); }
.foot-wave { width: min(100%, var(--maxw)); height: 24px; margin: 0 auto 2rem; display: block; color: var(--line); }
.foot-mark { font-family: var(--display); font-variation-settings: 'SOFT' 100, 'WONK' 1; font-weight: 600; font-size: 2.1rem; color: var(--ink); }
.foot-mark i { color: var(--rose); }
.foot-line { margin-top: 0.3rem; font-size: 1rem; }
.foot-links { display: flex; flex-wrap: wrap; gap: 0.4rem 1.5rem; justify-content: center; margin-top: 1.2rem; font-size: 1rem; }
.foot-links a { text-decoration: none; text-underline-offset: 5px; text-decoration-color: var(--gold); }
.foot-links a:hover { text-decoration: underline wavy; }
.desk-link { font-family: var(--hand); font-size: 1.25rem; opacity: 0.7; }

/* ---------- ink wash, sparks, view transitions ---------- */
#ink {
  position: fixed; inset: 0; z-index: 100; background: var(--wash); pointer-events: none;
  clip-path: circle(0px at var(--x, 50%) var(--y, 50%)); transition: clip-path 0.58s cubic-bezier(0.7, 0, 0.3, 1);
}
#ink::after { content: '✦'; position: absolute; left: 50%; top: 50%; translate: -50% -50%; font-size: 2.6rem; color: var(--gold-glow); opacity: 0; transition: opacity 0.3s 0.25s; }
#ink.cover { clip-path: circle(150vmax at var(--x, 50%) var(--y, 50%)); pointer-events: all; }
#ink.cover::after { opacity: 1; animation: spin 1.6s linear infinite; }
.spark { position: fixed; z-index: 200; pointer-events: none; color: var(--gold-glow); line-height: 1; text-shadow: 0 0 8px rgba(255, 214, 120, 0.6); }
::view-transition-old(root), ::view-transition-new(root) { animation: none; mix-blend-mode: normal; }
::view-transition-old(root) { z-index: 1; }
::view-transition-new(root) { z-index: 2; }

/* ---------- keyframes ---------- */
@keyframes fadeUp { from { opacity: 0; transform: translateY(18px); } to { opacity: 1; transform: none; } }
@keyframes inkIn { to { opacity: 1; transform: none; filter: blur(0); } }
@keyframes draw { to { stroke-dashoffset: 0; } }
@keyframes bob { 0%, 100% { transform: translateY(0) rotate(-2deg); } 50% { transform: translateY(-10px) rotate(2deg); } }
@keyframes twinkle { 0%, 100% { scale: 0.7; opacity: 0.35; } 50% { scale: 1.2; opacity: 1; } }
@keyframes wobble { 0%, 100% { transform: rotate(0); } 20% { transform: rotate(-9deg) scale(1.05); } 50% { transform: rotate(7deg) scale(1.05); } 80% { transform: rotate(-3deg); } }
@keyframes pop { from { opacity: 0; transform: translateY(24px) scale(0.94) rotate(-1deg); } to { opacity: 1; transform: none; } }
@keyframes fade { from { opacity: 0; } to { opacity: 1; } }
@keyframes spin { to { rotate: 360deg; } }
@keyframes bounce { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(7px); } }
@keyframes blink { 0%, 100% { opacity: 0.2; } 50% { opacity: 1; } }
@keyframes hop { 0%, 100% { transform: translateY(0); } 40% { transform: translateY(-18px) rotate(-4deg); } 70% { transform: translateY(2px) rotate(2deg); } }

@media (prefers-reduced-motion: reduce) {
  .wm-letters span, .hero-note, .hero-tag, .hero-by, .hero-cta, .scroll-cue { opacity: 1; transform: none; filter: none; }
  .squiggle path { stroke-dashoffset: 0; }
  .reveal { opacity: 1; translate: none; }
}

/* ---------- "read more" buttons, newest tag ---------- */
.more-wrap { display: flex; justify-content: center; margin-top: 2.2rem; }
.more-wrap .btn { gap: 0.7rem; }
.post-when { display: grid; gap: 0.1rem; justify-items: start; }
.newest {
  font-family: var(--hand); font-size: 1.15rem; line-height: 1.2; color: var(--ink); padding: 0 0.7em 0.05em;
  background: color-mix(in srgb, var(--gold) 30%, transparent); border-radius: 999px 30px 999px 30px / 30px 999px 30px 999px;
}
