/* Layout: sticky pill nav · hero with floating interest bubbles · "sticker" cards (ink border + offset shadow) on white */
:root {
  --bg: #ffffff;
  --surface: #f7f9ff;
  --ink: #111a35;
  --ink-2: #1d2849;
  --muted: #56607b;
  --line: #e1e6f2;
  --blue: #1e5bff;
  --blue-ink: #1745c4;
  --blue-soft: #e9efff;
  --orange: #ff7a1f;
  --orange-ink: #b04704;
  --orange-soft: #fff0e2;
  --on-blue: #ffffff;
  --ok: #17a864;
  --ok-soft: rgba(23, 168, 100, 0.35);
  --scrim: rgba(17, 26, 53, 0.55);
  --glass: rgba(255, 255, 255, 0.88);

  --f-display: "Fredoka", "Nunito", ui-rounded, "Arial Rounded MT Bold", system-ui, sans-serif;
  --f-body: "Nunito", ui-rounded, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --f-mono: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;

  --r: 22px;
  color-scheme: light;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
html.no-scroll { overflow: hidden; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--f-body);
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: var(--blue-ink); }
button { font: inherit; color: inherit; }
:focus-visible { outline: 3px solid var(--orange); outline-offset: 3px; border-radius: 10px; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

.wrap {
  max-width: 1160px;
  margin-inline: auto;
  padding-left: max(20px, env(safe-area-inset-left, 0px));
  padding-right: max(20px, env(safe-area-inset-right, 0px));
}

/* ---------- Top bar ---------- */
.topbar {
  position: sticky;
  top: env(safe-area-inset-top, 0px);
  z-index: 40;
  background: var(--glass);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
  border-bottom: 1.5px solid var(--line);
}
.topbar-in { position: relative; display: flex; align-items: center; gap: 16px; min-height: 70px; }
.brand { display: flex; align-items: center; gap: 10px; margin-right: auto; color: var(--ink); text-decoration: none; min-width: 0; }
.brand-dot {
  flex: none; width: 42px; height: 42px; border-radius: 50%;
  display: grid; place-items: center;
  background: var(--orange); color: var(--ink);
  border: 2.5px solid var(--ink); box-shadow: 2px 2px 0 var(--ink);
  font: 700 15px/1 var(--f-display);
}
.brand-name { font: 600 19px/1.1 var(--f-display); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.nav { display: flex; gap: 4px; }
.nav a {
  font: 600 15.5px/1 var(--f-display); color: var(--ink); text-decoration: none;
  padding: 11px 15px; border-radius: 999px; transition: background-color .15s;
}
.nav a:hover { background: var(--blue-soft); }
.nav a[aria-current="page"] { background: var(--blue); color: var(--on-blue); }
.menu-btn { display: none; }

@media (max-width: 860px) {
  .menu-btn {
    display: inline-flex; align-items: center; cursor: pointer;
    font: 600 15px/1 var(--f-display); padding: 10px 18px; border-radius: 999px;
    border: 2px solid var(--ink); background: var(--bg); color: var(--ink); box-shadow: 2px 2px 0 var(--ink);
  }
  .nav {
    display: none; position: absolute; top: 100%; left: 0; right: 0;
    flex-direction: column; gap: 2px;
    background: var(--bg); border-bottom: 2.5px solid var(--ink);
    padding-block: 10px 18px;
    padding-left: max(20px, env(safe-area-inset-left, 0px));
    padding-right: max(20px, env(safe-area-inset-right, 0px));
  }
  .topbar.open .nav { display: flex; }
  .nav a { padding: 14px 16px; font-size: 18px; }
}

/* ---------- Buttons, chips, badges ---------- */
.btn {
  display: inline-flex; align-items: center; gap: 8px; cursor: pointer;
  font: 600 16px/1 var(--f-display); padding: 14px 22px; border-radius: 999px;
  border: 2.5px solid var(--ink); background: var(--bg); color: var(--ink); text-decoration: none;
  box-shadow: 3px 3px 0 var(--ink); transition: transform .15s, box-shadow .15s;
}
.btn:hover { transform: translate(-2px, -2px); box-shadow: 5px 5px 0 var(--ink); }
.btn:active { transform: translate(2px, 2px); box-shadow: 1px 1px 0 var(--ink); }
.btn-primary { background: var(--orange); }
.btn-blue { background: var(--blue); color: var(--on-blue); }
.cta { display: flex; flex-wrap: wrap; gap: 14px; }
.cta.col { flex-direction: column; align-items: stretch; }
.cta.col .btn { justify-content: center; }
.cta:empty { display: none; }

.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip { font: 700 13px/1 var(--f-body); padding: 7px 12px; border-radius: 999px; background: var(--blue-soft); color: var(--blue-ink); }
.chip:nth-child(even) { background: var(--orange-soft); color: var(--orange-ink); }

.badges { display: flex; flex-wrap: wrap; gap: 8px; }
.badge {
  display: inline-flex; align-items: center; white-space: nowrap;
  font: 500 12px/1 var(--f-mono); letter-spacing: .02em;
  padding: 6px 10px; border-radius: 999px; border: 2px solid var(--ink);
}
.b-blue { background: var(--blue); color: var(--on-blue); }
.b-orange { background: var(--orange); color: var(--ink); }
.b-ink { background: var(--ink); color: var(--bg); }
.b-soft { background: var(--blue-soft); color: var(--blue-ink); }
.b-upcoming { background: var(--bg); color: var(--ink); border-style: dashed; }
.b-example { background: var(--orange-soft); color: var(--orange-ink); border: 2px dashed var(--orange-ink); }

.eyebrow { font: 500 13px/1.4 var(--f-mono); letter-spacing: .07em; text-transform: uppercase; color: var(--blue-ink); margin: 0 0 14px; }
.lead { font-size: clamp(18px, 2vw, 21px); color: var(--muted); max-width: 36em; margin: 0 0 28px; }
.page-title { font: 700 clamp(38px, 5.4vw, 64px)/1.02 var(--f-display); letter-spacing: -.015em; margin: 0 0 18px; text-wrap: balance; }
.sub { font: 700 28px/1.1 var(--f-display); margin: 48px 0 18px; }
.empty { color: var(--muted); }

/* ---------- Placeholder for missing images ---------- */
.ph {
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px;
  width: 100%; height: 100%; min-height: 120px; padding: 16px; text-align: center;
  background: repeating-linear-gradient(-45deg, var(--blue-soft) 0 14px, var(--bg) 14px 28px);
  color: var(--blue-ink); font: 500 12px/1.35 var(--f-mono); overflow-wrap: anywhere;
}
.ph svg { width: 34px; height: 34px; flex: none; }
.thumb .ph span, .gal-thumb .ph span { display: none; }
.thumb .ph, .gal-thumb .ph { min-height: 0; padding: 4px; }
.thumb .ph svg, .gal-thumb .ph svg { width: 22px; height: 22px; }

/* ---------- Hero ---------- */
.hero-band { position: relative; overflow: hidden; isolation: isolate; }
.hero-band::before, .hero-band::after { content: ""; position: absolute; border-radius: 50%; z-index: -1; }
.hero-band::before { width: 560px; height: 560px; right: -160px; top: -200px; background: var(--orange-soft); }
.hero-band::after { width: 380px; height: 380px; left: -180px; bottom: -220px; background: var(--blue-soft); }
.hero { display: grid; grid-template-columns: minmax(0, 1.12fr) minmax(0, .88fr); gap: 40px; align-items: center; padding-block: 64px 80px; }
.hero-title { position: relative; z-index: 0; font: 700 clamp(48px, 7.6vw, 96px)/.98 var(--f-display); letter-spacing: -.02em; margin: 0 0 22px; text-wrap: balance; }
.hl { position: relative; z-index: 0; color: var(--blue); white-space: nowrap; }
.hl::after { content: ""; position: absolute; z-index: -1; left: -3%; right: -3%; bottom: .06em; height: .24em; border-radius: 999px; background: var(--orange); }
.status { display: flex; align-items: center; gap: 10px; margin: 30px 0 0; font: 500 13.5px/1.4 var(--f-mono); color: var(--muted); }
.pulse { flex: none; width: 10px; height: 10px; border-radius: 50%; background: var(--ok); animation: pulse 2s ease-out infinite; }
@keyframes pulse { 0% { box-shadow: 0 0 0 0 var(--ok-soft); } 100% { box-shadow: 0 0 0 12px transparent; } }

.hero-art { display: flex; justify-content: center; }
.bubbles { position: relative; width: min(100%, 470px); aspect-ratio: 1; container-type: inline-size; }
.bub {
  position: absolute; left: calc(var(--x) * 1%); top: calc(var(--y) * 1%); width: calc(var(--s) * 1%); aspect-ratio: 1;
  display: flex; align-items: center; justify-content: center; text-align: center; padding: calc(var(--s) * .13cqw); min-height: 0;
  border-radius: 50%; border: 2.5px solid var(--ink); box-shadow: 4px 4px 0 var(--ink);
  font-family: var(--f-display); font-weight: 600; line-height: 1.05;
  font-size: calc(var(--s) * .085cqw + 6px);
  overflow-wrap: normal; word-break: keep-all; hyphens: none;
  animation: float var(--d, 7s) ease-in-out var(--delay, 0s) infinite alternate;
}
@keyframes float { from { transform: translateY(-7px) rotate(-2deg); } to { transform: translateY(8px) rotate(2deg); } }
.bub > span { display: block; width: 100%; text-align: center; white-space: normal; }
.t-blue { background: var(--blue); color: var(--on-blue); }
.t-orange { background: var(--orange); color: var(--ink); }
.t-soft { background: var(--blue-soft); color: var(--blue-ink); }
.t-line { background: var(--bg); color: var(--ink); }
.t-orangesoft { background: var(--orange-soft); color: var(--orange-ink); }
.bub-photo { padding: 0; overflow: hidden; background: var(--orange-soft); box-shadow: 6px 6px 0 var(--blue); }
.bub-img { width: 100%; height: 100%; object-fit: cover; }
.bub-init { font: 700 calc(var(--s, 46) * .32cqw)/1 var(--f-display); color: var(--orange-ink); }

@media (max-width: 860px) {
  .hero { grid-template-columns: 1fr; gap: 28px; padding-block: 40px 56px; }
  .bubbles { width: min(100%, 380px); }
}

/* ---------- Sections ---------- */
.sec { padding-block: 56px; }
.sec-tight { padding-block: 0 80px; }
.phead { padding-block: 56px 32px; }
.sec-head { display: flex; align-items: flex-end; justify-content: space-between; flex-wrap: wrap; gap: 12px 24px; margin-bottom: 28px; }
.sec-head > div { min-width: 0; }
.sec-title { font: 700 clamp(30px, 4vw, 44px)/1.05 var(--f-display); letter-spacing: -.01em; margin: 0; }
.sec-kicker { margin: 8px 0 0; color: var(--muted); max-width: 40em; }
.more { font: 600 16px/1.2 var(--f-display); color: var(--blue-ink); text-decoration: none; white-space: nowrap; }
.more:hover { text-decoration: underline; text-underline-offset: 4px; }
.split { display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr); gap: 48px; align-items: start; }
@media (max-width: 900px) { .split { grid-template-columns: 1fr; } }

/* ---------- Project cards ---------- */
.pgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 310px), 1fr)); gap: 28px; }
.pcard {
  display: flex; flex-direction: column; overflow: hidden; color: var(--ink); text-decoration: none;
  background: var(--bg); border: 2.5px solid var(--ink); border-radius: var(--r);
  box-shadow: 5px 5px 0 var(--ink); transition: transform .18s, box-shadow .18s;
}
.pcard:hover { transform: translate(-3px, -3px); box-shadow: 8px 8px 0 var(--blue); }
.pcard:nth-child(even):hover { box-shadow: 8px 8px 0 var(--orange); }
.pcard-media { position: relative; aspect-ratio: 16 / 10; max-width: 100%; background: var(--blue-soft); border-bottom: 2.5px solid var(--ink); }
.pcard-img { width: 100%; height: 100%; object-fit: cover; object-position: top center; }
.pcover {
  width: 100%; height: 100%; display: flex; align-items: flex-end; padding: 22px;
  background: radial-gradient(circle at 85% 20%, var(--orange) 0 18%, transparent 18.5%), radial-gradient(circle at 70% 75%, var(--blue-soft) 0 12%, transparent 12.5%), var(--blue);
  color: var(--on-blue); font: 700 30px/1.05 var(--f-display); text-wrap: balance;
}
.pcard-count { position: absolute; left: 12px; bottom: 12px; font: 500 12px/1 var(--f-mono); padding: 6px 10px; border-radius: 999px; background: var(--bg); border: 2px solid var(--ink); }
.pcard-flag { position: absolute; top: 12px; right: 12px; }
.pcard-body { flex: 1; display: flex; flex-direction: column; gap: 10px; padding: 20px 22px 24px; }
.pcard-meta { margin: 0; font: 500 12.5px/1.3 var(--f-mono); letter-spacing: .05em; text-transform: uppercase; color: var(--muted); }
.pcard h3 { font: 600 24px/1.15 var(--f-display); margin: 0; }
.pcard-body > p:not(.pcard-meta) { margin: 0; color: var(--muted); font-size: 16px; }
.pcard .chips { margin-top: auto; padding-top: 6px; }

/* ---------- Event rows ---------- */
.elist { display: flex; flex-direction: column; gap: 14px; }
.erow {
  display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 18px; align-items: center;
  padding: 16px 20px 16px 16px; border: 2px solid var(--line); border-radius: var(--r);
  background: var(--bg); color: var(--ink); text-decoration: none;
  transition: border-color .15s, transform .15s, box-shadow .15s;
}
a.erow:hover { border-color: var(--ink); transform: translate(-2px, -2px); box-shadow: 4px 4px 0 var(--ink); }
.erow.is-planned { border-style: dashed; background: var(--surface); }
.dbub {
  flex: none; width: 70px; height: 70px; border-radius: 50%; border: 2.5px solid var(--ink);
  display: flex; flex-direction: column; align-items: center; justify-content: center; line-height: 1;
}
.dbub-big { font: 700 24px/1 var(--f-display); }
.dbub-small { font: 500 10.5px/1.2 var(--f-mono); text-transform: uppercase; margin-top: 4px; }
.d-blue { background: var(--blue); color: var(--on-blue); }
.d-orange { background: var(--orange); color: var(--ink); }
.d-ink { background: var(--ink); color: var(--bg); }
.d-soft { background: var(--blue-soft); color: var(--blue-ink); }
.is-planned .dbub { background: var(--bg); color: var(--ink); border-style: dashed; }
.erow-body { min-width: 0; display: flex; flex-direction: column; gap: 6px; }
.erow-top { display: flex; flex-wrap: wrap; gap: 6px; }
.erow h3 { font: 600 20px/1.2 var(--f-display); margin: 0; }
.erow-meta { margin: 0; font-size: 14.5px; color: var(--muted); }
.erow-ex { margin: 0; font-size: 15.5px; color: var(--muted); }
.erow-go { font: 600 24px/1 var(--f-display); color: var(--blue); }
@media (max-width: 540px) {
  .erow { grid-template-columns: auto minmax(0, 1fr); gap: 14px; }
  .erow-go { display: none; }
  .dbub { width: 58px; height: 58px; }
  .dbub-big { font-size: 20px; }
}
.filters { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 8px; }
.fchip {
  cursor: pointer; font: 600 15px/1 var(--f-display); padding: 11px 17px; border-radius: 999px;
  border: 2px solid var(--ink); background: var(--bg); color: var(--ink);
}
.fchip:hover { background: var(--blue-soft); }
.fchip[aria-pressed="true"] { background: var(--ink); color: var(--bg); }
.group-label { font: 500 13px/1.3 var(--f-mono); letter-spacing: .07em; text-transform: uppercase; color: var(--muted); margin: 32px 0 14px; }

/* ---------- Podcast ---------- */
.podteaser {
  display: flex; flex-direction: column; gap: 14px; padding: 26px; text-decoration: none;
  background: var(--blue); color: var(--on-blue); border: 2.5px solid var(--ink); border-radius: 28px;
  box-shadow: 6px 6px 0 var(--orange); transition: transform .18s, box-shadow .18s;
}
.podteaser:hover { transform: translate(-3px, -3px); box-shadow: 9px 9px 0 var(--orange); }
.podteaser h3 { font: 600 26px/1.15 var(--f-display); margin: 0; }
.podteaser p { margin: 0; }
.pod-go { font: 600 15.5px/1 var(--f-display); margin-top: 4px; }
.wave { display: flex; align-items: center; gap: 5px; height: 64px; color: var(--orange); }
.wave i {
  display: block; width: 8px; height: calc(var(--h) * 1%); border-radius: 999px; background: currentColor;
  animation: wave 1.3s ease-in-out var(--dl) infinite alternate;
}
.wave i:nth-child(3n) { background: var(--on-blue); }
@keyframes wave { from { transform: scaleY(.5); } to { transform: scaleY(1); } }

.ep {
  display: grid; grid-template-columns: 280px minmax(0, 1fr); gap: 36px; padding: 28px; margin-bottom: 28px;
  border: 2.5px solid var(--ink); border-radius: 28px; box-shadow: 6px 6px 0 var(--ink);
}
.ep-art {
  aspect-ratio: 1; max-width: 100%; border-radius: 22px; border: 2.5px solid var(--ink); overflow: hidden;
  background: var(--blue); color: var(--on-blue);
  display: flex; flex-direction: column; justify-content: space-between; padding: 22px;
}
.ep-img { width: 100%; height: 100%; object-fit: cover; }
.ep-art:has(.ep-img) { padding: 0; }
.ep-art-k { font: 500 12px/1 var(--f-mono); letter-spacing: .12em; }
.ep-art-t { font: 700 24px/1.08 var(--f-display); text-wrap: balance; }
.ep-body { min-width: 0; display: flex; flex-direction: column; gap: 14px; }
.ep-title { font: 700 clamp(28px, 3.4vw, 38px)/1.08 var(--f-display); margin: 0; }
.ep-guest { margin: 0; font-size: 18px; }
.ep-body .facts { margin: 4px 0; }
@media (max-width: 760px) {
  .ep { grid-template-columns: 1fr; padding: 20px; gap: 22px; }
  .ep-art { aspect-ratio: auto; min-height: 190px; }
}

/* ---------- Blog rows ---------- */
.plist { display: flex; flex-direction: column; }
.prow { display: grid; grid-template-columns: 140px minmax(0, 1fr); gap: 24px; padding: 22px 0; border-top: 1.5px solid var(--line); color: var(--ink); text-decoration: none; }
.prow:last-child { border-bottom: 1.5px solid var(--line); }
.prow-date { font: 500 13px/1.3 var(--f-mono); color: var(--muted); padding-top: 6px; font-variant-numeric: tabular-nums; }
.prow-main { min-width: 0; display: flex; flex-direction: column; gap: 8px; }
.prow h3 { font: 600 23px/1.2 var(--f-display); margin: 0; display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; }
.prow p { margin: 0; color: var(--muted); }
.prow:hover h3 { color: var(--blue-ink); }
@media (max-width: 600px) { .prow { grid-template-columns: 1fr; gap: 6px; } }

/* ---------- Site index ---------- */
.index { border: 2.5px solid var(--ink); border-radius: var(--r); overflow: hidden; }
.irow { display: grid; grid-template-columns: 110px minmax(0, 1fr) 120px; gap: 16px; align-items: center; padding: 14px 20px; border-top: 1.5px solid var(--line); color: var(--ink); text-decoration: none; }
.irow:first-child { border-top: 0; }
a.irow:hover { background: var(--blue-soft); }
.irow .badge { justify-self: start; }
.irow-title { font-weight: 700; min-width: 0; }
.irow-date { font: 500 13px/1.3 var(--f-mono); color: var(--muted); text-align: right; font-variant-numeric: tabular-nums; }
@media (max-width: 600px) {
  .irow { grid-template-columns: minmax(0, 1fr) auto; gap: 6px 12px; padding: 14px 16px; }
  .irow .badge { grid-column: 1 / -1; }
}

/* ---------- Article (event / post) ---------- */
.wrap.article { max-width: 880px; padding-block: 40px 88px; }
.back { display: inline-flex; font: 600 15.5px/1 var(--f-display); color: var(--blue-ink); text-decoration: none; margin-bottom: 26px; }
.back:hover { text-decoration: underline; text-underline-offset: 4px; }
.art-title { font: 700 clamp(34px, 5vw, 58px)/1.04 var(--f-display); letter-spacing: -.01em; margin: 16px 0 14px; text-wrap: balance; }
.art-head .lead { margin-bottom: 0; }
.facts { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 170px), 1fr)); gap: 12px; margin: 30px 0; padding: 0; }
.facts div { background: var(--surface); border: 1.5px solid var(--line); border-radius: 16px; padding: 12px 16px; min-width: 0; }
.facts dt { font: 500 11.5px/1.3 var(--f-mono); letter-spacing: .07em; text-transform: uppercase; color: var(--muted); }
.facts dd { margin: 4px 0 0; font-weight: 700; overflow-wrap: anywhere; }
.facts.stack { grid-template-columns: 1fr; margin: 0; }
.facts.small div { padding: 10px 14px; }
.art-fig { margin: 0 0 40px; }
.art-fig figcaption, .all-imgs figcaption { font-size: 14px; color: var(--muted); margin-top: 10px; }
.art-cover {
  display: block; width: 100%; aspect-ratio: 16 / 9; max-width: 100%; padding: 0; cursor: zoom-in; overflow: hidden;
  border: 2.5px solid var(--ink); border-radius: var(--r); background: var(--blue-soft); box-shadow: 6px 6px 0 var(--orange);
}
.art-cover-img { width: 100%; height: 100%; object-fit: cover; }
.wc { font: 500 13px/1.3 var(--f-mono); color: var(--muted); margin: 28px 0 0; }
.thumbs { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 12px; }
.thumb { padding: 0; aspect-ratio: 4 / 3; max-width: 100%; overflow: hidden; cursor: zoom-in; border: 2px solid var(--ink); border-radius: 14px; background: var(--blue-soft); }
.thumb-img { width: 100%; height: 100%; object-fit: cover; }
.post-cover { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; border-radius: var(--r); border: 2.5px solid var(--ink); margin-bottom: 36px; }

.prose { max-width: 68ch; font-size: 18px; }
.prose > :first-child { margin-top: 0; }
.prose h2 { font: 600 27px/1.2 var(--f-display); margin: 1.6em 0 .45em; }
.prose h3 { font: 600 21px/1.25 var(--f-display); margin: 1.4em 0 .35em; }
.prose p { margin: 0 0 1em; }
.prose ul, .prose ol { padding-left: 1.3em; margin: 0 0 1em; }
.prose li { margin: .3em 0; }
.prose li::marker { color: var(--orange-ink); font-weight: 700; }
.prose blockquote { margin: 1.2em 0; padding: 12px 20px; border-left: 5px solid var(--orange); background: var(--orange-soft); border-radius: 0 14px 14px 0; }
.prose code { font: 500 .86em var(--f-mono); background: var(--blue-soft); color: var(--blue-ink); padding: 2px 6px; border-radius: 6px; }
.prose pre { overflow-x: auto; background: var(--ink); color: var(--bg); padding: 16px 18px; border-radius: 14px; }
.prose pre code { background: none; color: inherit; padding: 0; }
.prose img { border-radius: 14px; border: 2px solid var(--ink); }
.prose a { text-underline-offset: 3px; }

.pager { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-top: 60px; }
.pager a { display: flex; flex-direction: column; gap: 6px; padding: 16px 18px; border: 2px solid var(--line); border-radius: 18px; color: var(--ink); text-decoration: none; }
.pager a:hover { border-color: var(--ink); }
.pager a.r { text-align: right; grid-column: 2; }
.pager span { font: 500 12.5px/1 var(--f-mono); color: var(--muted); }
.pager strong { font: 600 18px/1.2 var(--f-display); }
@media (max-width: 600px) { .pager { grid-template-columns: 1fr; } .pager a.r { grid-column: auto; } }

/* ---------- About ---------- */
.about { display: grid; grid-template-columns: 320px minmax(0, 1fr); gap: 60px; align-items: start; padding-block: 52px 88px; }
.about-side { position: sticky; top: calc(96px + env(safe-area-inset-top, 0px)); display: flex; flex-direction: column; gap: 20px; }
.about-photo {
  width: 100%; aspect-ratio: 1; max-width: 100%; border-radius: 50%; overflow: hidden; display: grid; place-items: center;
  background: var(--orange-soft); border: 3px solid var(--ink); box-shadow: 8px 8px 0 var(--blue);
}
.about-img { width: 100%; height: 100%; object-fit: cover; }
.about-photo .bub-init { font-size: 96px; }
.contact { display: flex; flex-direction: column; gap: 10px; }
.email { display: flex; align-items: center; gap: 8px; min-width: 0; padding: 6px 6px 6px 16px; border: 2px solid var(--line); border-radius: 999px; font: 500 14px/1.2 var(--f-mono); }
.email-text { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; user-select: all; }
.copy { cursor: pointer; flex: none; font: 600 14px/1 var(--f-display); padding: 9px 14px; border-radius: 999px; border: 2px solid var(--ink); background: var(--orange); color: var(--ink); }
.skill-group { margin-bottom: 18px; }
.skill-group h3 { font: 500 12.5px/1.3 var(--f-mono); letter-spacing: .07em; text-transform: uppercase; color: var(--muted); margin: 0 0 10px; }
.timeline { list-style: none; margin: 0 0 0 8px; padding: 0; border-left: 3px solid var(--blue-soft); }
.timeline li { position: relative; padding: 0 0 24px 28px; }
.timeline li::before { content: ""; position: absolute; left: -11.5px; top: 4px; width: 16px; height: 16px; border-radius: 50%; background: var(--orange); border: 2.5px solid var(--ink); }
.tl-when { font: 500 12.5px/1.3 var(--f-mono); color: var(--blue-ink); }
.timeline strong { display: block; font: 600 20px/1.25 var(--f-display); margin-top: 2px; }
.timeline p { margin: 2px 0 0; color: var(--muted); }
@media (max-width: 880px) {
  .about { grid-template-columns: 1fr; gap: 36px; padding-block: 36px 72px; }
  .about-side { position: static; }
  .about-photo { width: min(240px, 100%); }
}

/* ---------- Modal + gallery ---------- */
.modal {
  position: fixed; inset: 0; z-index: 100; display: flex; align-items: center; justify-content: center;
  padding: max(16px, env(safe-area-inset-top, 0px)) max(16px, env(safe-area-inset-right, 0px)) max(16px, env(safe-area-inset-bottom, 0px)) max(16px, env(safe-area-inset-left, 0px));
}
.modal[hidden] { display: none; }
.modal-backdrop { position: absolute; inset: 0; background: var(--scrim); -webkit-backdrop-filter: blur(5px); backdrop-filter: blur(5px); }
.modal-card {
  position: relative; display: flex; flex-direction: column; width: min(1100px, 100%); max-height: 100%; overflow: hidden;
  background: var(--bg); border: 3px solid var(--ink); border-radius: 28px; box-shadow: 8px 8px 0 var(--orange);
  animation: pop .22s cubic-bezier(.2, .9, .3, 1.25);
}
@keyframes pop { from { transform: scale(.95); opacity: .3; } to { transform: none; opacity: 1; } }
.modal-scroll { overflow: auto; overscroll-behavior: contain; }
.modal-x {
  position: absolute; top: 14px; right: 14px; z-index: 3; width: 46px; height: 46px; display: grid; place-items: center; cursor: pointer;
  border-radius: 50%; border: 2.5px solid var(--ink); background: var(--bg); color: var(--ink); box-shadow: 2px 2px 0 var(--ink);
}
.modal-x svg { width: 20px; height: 20px; }
.gal-stage { position: relative; overflow: hidden; width: 100%; aspect-ratio: 16 / 9; max-height: 56vh; background: var(--ink); }
.gal-frame { position: absolute; inset: 0; display: grid; place-items: center; }
.gal-img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; }
.gal-frame .ph { background: repeating-linear-gradient(-45deg, var(--ink) 0 14px, var(--ink-2) 14px 28px); color: var(--blue-soft); font-size: 13px; }
.gal-nav {
  position: absolute; top: 50%; transform: translateY(-50%); width: 50px; height: 50px; display: grid; place-items: center; cursor: pointer;
  border-radius: 50%; border: 2.5px solid var(--ink); background: var(--bg); color: var(--ink); box-shadow: 3px 3px 0 var(--orange);
  font: 600 28px/1 var(--f-display);
}
.gal-nav.prev { left: 14px; }
.gal-nav.next { right: 14px; }
.gal-count { position: absolute; left: 14px; bottom: 14px; font: 500 12px/1 var(--f-mono); padding: 6px 10px; border-radius: 999px; background: var(--bg); color: var(--ink); border: 2px solid var(--ink); }
.gal-cap { margin: 0; padding: 12px 28px 0; min-height: 1.6em; font-size: 15px; color: var(--muted); }
.gal-thumbs { display: flex; gap: 10px; overflow-x: auto; padding: 12px 28px 6px; }
.gal-thumb { flex: 0 0 104px; aspect-ratio: 16 / 10; padding: 0; overflow: hidden; cursor: pointer; border: 2.5px solid var(--line); border-radius: 12px; background: var(--blue-soft); }
.gal-thumb.on { border-color: var(--orange); box-shadow: 0 0 0 2px var(--orange); }
.gal-thumb-img { width: 100%; height: 100%; object-fit: cover; }
.pm-info { display: grid; grid-template-columns: minmax(0, 1fr) 290px; gap: 20px 40px; padding: 26px 32px 38px; }
.pm-info.no-gal { padding-top: 68px; }
.pm-head { grid-column: 1 / -1; }
.pm-title { font: 700 clamp(28px, 4vw, 44px)/1.05 var(--f-display); margin: 12px 0 10px; text-wrap: balance; }
.pm-head .lead { margin: 0; }
.pm-side { display: flex; flex-direction: column; gap: 18px; min-width: 0; }
@media (max-width: 760px) {
  .pm-info { grid-template-columns: 1fr; padding: 20px 20px 30px; }
  .gal-cap, .gal-thumbs { padding-left: 20px; padding-right: 20px; }
  .gal-nav { width: 42px; height: 42px; font-size: 24px; }
  .modal-card { border-radius: 22px; }
}

/* ---------- One-page version ---------- */
.wrap.allp { max-width: 920px; padding-block: 40px 88px; }
.note { background: var(--orange-soft); border: 2px dashed var(--orange-ink); border-radius: 18px; padding: 16px 20px; margin-bottom: 40px; font-size: 15.5px; }
.all-links { font: 500 13.5px/1.5 var(--f-mono); color: var(--muted); overflow-wrap: anywhere; margin: 0; }
.all-sec { font: 700 34px/1.1 var(--f-display); margin: 60px 0 16px; padding-bottom: 12px; border-bottom: 3px solid var(--ink); }
.all-item { padding: 22px 0 30px; border-bottom: 1.5px solid var(--line); }
.all-item h3 { font: 600 27px/1.15 var(--f-display); margin: 6px 0 8px; }
.all-item .sm { font-size: 16px; color: var(--muted); margin: 0 0 8px; }
.all-imgs { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 240px), 1fr)); gap: 14px; margin: 16px 0; }
.all-imgs:empty { display: none; }
.all-imgs figure { margin: 0; }
.all-img, .all-imgs .ph { width: 100%; aspect-ratio: 16 / 10; max-width: 100%; object-fit: cover; border-radius: 12px; border: 2px solid var(--ink); min-height: 0; }

/* ---------- Footer ---------- */
.footer { margin-top: 24px; border-top: 2.5px solid var(--ink); background: var(--surface); }
.foot { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 14px 32px; align-items: center; padding-block: 36px; }
.foot-name { font: 700 22px/1.1 var(--f-display); margin: 0; }
.foot-sub { margin: 6px 0 0; color: var(--muted); font-size: 15px; }
.foot-links { display: flex; flex-wrap: wrap; gap: 10px 20px; justify-content: flex-end; }
.foot-links a { font: 600 15.5px/1.3 var(--f-display); color: var(--ink); text-decoration: none; border-bottom: 2.5px solid var(--orange); }
.foot-links a:hover { color: var(--blue-ink); }
.foot-meta { grid-column: 1 / -1; margin: 6px 0 0; font: 500 12.5px/1.4 var(--f-mono); color: var(--muted); }
@media (max-width: 720px) { .foot { grid-template-columns: 1fr; } .foot-links { justify-content: flex-start; } }

/* ---------- Motion + print ---------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}
@media print {
  .topbar, .footer, .modal, .note, .btn, .cta, .back, .pager, .filters { display: none !important; }
  body { font-size: 11.5pt; }
  .wrap.allp { padding-block: 0; max-width: none; }
  .all-sec { break-after: avoid; }
  .all-item h3 { break-after: avoid; }
  .all-imgs { break-inside: avoid; }
  a { color: inherit; text-decoration: none; }
  * { animation: none !important; box-shadow: none !important; }
}
