:root {
  --bg: #f6f3ee;
  --bg-alt: #ece6dc;
  --surface: #fffdf9;
  --ink: #1d2420;
  --ink-soft: #55605a;
  --line: #d9d1c4;
  --accent: #2f5d50;
  --accent-soft: #dce8e2;
  --warm: #c8642f;
  --ridge-back: #b9c7bf;
  --ridge-front: #2f5d50;
  --shadow: 0 1px 2px rgba(29, 36, 32, 0.06), 0 8px 24px rgba(29, 36, 32, 0.06);
  --radius: 14px;
  --serif: "Fraunces", Georgia, serif;
  --sans: "Inter", system-ui, -apple-system, sans-serif;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #131815;
    --bg-alt: #1a201c;
    --surface: #1f2622;
    --ink: #ece8e1;
    --ink-soft: #a3ada7;
    --line: #333d37;
    --accent: #7fb8a4;
    --accent-soft: #24352e;
    --warm: #e8925f;
    --ridge-back: #26302b;
    --ridge-front: #1a201c;
    --shadow: 0 1px 2px rgba(0, 0, 0, 0.3), 0 8px 24px rgba(0, 0, 0, 0.25);
  }
}
:root[data-theme="dark"] {
  --bg: #131815;
  --bg-alt: #1a201c;
  --surface: #1f2622;
  --ink: #ece8e1;
  --ink-soft: #a3ada7;
  --line: #333d37;
  --accent: #7fb8a4;
  --accent-soft: #24352e;
  --warm: #e8925f;
  --ridge-back: #26302b;
  --ridge-front: #1a201c;
  --shadow: 0 1px 2px rgba(0, 0, 0, 0.3), 0 8px 24px rgba(0, 0, 0, 0.25);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 72px; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 400 17px/1.6 var(--sans);
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; }
h1, h2, h3 { font-family: var(--serif); font-weight: 600; line-height: 1.1; margin: 0; }
h2 { font-size: clamp(30px, 4.5vw, 44px); margin-bottom: 16px; }
h3 { font-size: 20px; }

.wrap { max-width: 1040px; margin: 0 auto; padding: 0 24px; }
@media (max-width: 600px) { .wrap { padding: 0 16px; } }

.eyebrow {
  font-size: 13px; font-weight: 600; letter-spacing: 0.12em; text-transform: uppercase;
  color: var(--warm); margin: 0 0 12px;
}
.lede { font-size: 19px; color: var(--ink-soft); max-width: 720px; margin: 0 0 40px; }

/* Nav */
.nav {
  position: sticky; top: 0; z-index: 20;
  display: flex; justify-content: space-between; align-items: center;
  padding: 14px 24px;
  background: color-mix(in srgb, var(--bg) 85%, transparent);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid transparent;
  transition: border-color 0.2s;
}
.nav.scrolled { border-bottom-color: var(--line); }
.nav-name { font-family: var(--serif); font-weight: 700; font-size: 19px; text-decoration: none; }
.nav nav { display: flex; gap: 24px; }
.nav nav a { text-decoration: none; font-size: 15px; font-weight: 500; color: var(--ink-soft); }
.nav nav a:hover, .nav nav a.active { color: var(--ink); }
@media (max-width: 600px) { .nav { padding: 12px 16px; } .nav nav { gap: 16px; } }

/* Hero */
.hero { position: relative; padding: 96px 0 200px; overflow: hidden; }
.hero h1 { font-size: clamp(48px, 9vw, 96px); letter-spacing: -0.02em; margin-bottom: 20px; }
.hero-tagline { font-size: clamp(19px, 2.4vw, 23px); color: var(--ink-soft); max-width: 620px; margin: 0 0 32px; }
.hero-actions { display: flex; gap: 12px; flex-wrap: wrap; }
.hero-grid { display: grid; grid-template-columns: auto 1fr; gap: 56px; align-items: center; }
.hero-grid > div { position: relative; z-index: 1; }
.headshot {
  width: 260px; height: 260px; border-radius: 50%; object-fit: cover; display: block;
  border: 6px solid var(--surface); box-shadow: var(--shadow); position: relative; z-index: 1;
}
@media (max-width: 760px) {
  .hero-grid { grid-template-columns: 1fr; gap: 28px; }
  .headshot { width: 140px; height: 140px; border-width: 4px; }
}
.hobby-list strong { white-space: nowrap; }
.hobby-list a { color: var(--accent); text-decoration: none; }
.hobby-list a:hover { text-decoration: underline; }
.ridge { position: absolute; left: 0; bottom: 0; width: 100%; height: 200px; }
.ridge-back { fill: var(--ridge-back); }
.ridge-front { fill: var(--ridge-front); }

.btn {
  display: inline-block; padding: 12px 22px; border-radius: 999px;
  border: 1px solid var(--line); background: var(--surface);
  font: 500 15px var(--sans); text-decoration: none; cursor: pointer;
  transition: transform 0.15s, box-shadow 0.15s;
}
.btn:hover { transform: translateY(-1px); box-shadow: var(--shadow); }
.btn-primary { background: var(--accent); border-color: var(--accent); color: var(--bg); }

/* Stats */
.stats-band { background: var(--ridge-front); color: #f6f3ee; padding: 8px 0 56px; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .stats-band { color: var(--ink); } }
:root[data-theme="dark"] .stats-band { color: var(--ink); }
.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; }
.stat-value { font-family: var(--serif); font-size: clamp(34px, 5vw, 48px); font-weight: 600; }
.stat-label { font-size: 14px; opacity: 0.8; }
@media (max-width: 760px) { .stats { grid-template-columns: repeat(2, 1fr); row-gap: 32px; } }

/* Sections */
.section { padding: 96px 0; }
.section-alt { background: var(--bg-alt); }
@media (max-width: 600px) { .section { padding: 64px 0; } }

/* Filter chips */
.filter { margin-bottom: 32px; }
.filter-head { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 12px; font-size: 14px; font-weight: 600; color: var(--ink-soft); }
.link-btn { background: none; border: 0; color: var(--accent); font: 600 14px var(--sans); cursor: pointer; padding: 0; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip {
  border: 1px solid var(--line); background: var(--surface); color: var(--ink);
  padding: 7px 14px; border-radius: 999px; font: 500 14px var(--sans); cursor: pointer;
  transition: background 0.15s, border-color 0.15s, color 0.15s;
}
.chip:hover { border-color: var(--accent); }
.chip[aria-pressed="true"] { background: var(--accent); border-color: var(--accent); color: var(--bg); }
.chip-count { opacity: 0.6; margin-left: 4px; font-variant-numeric: tabular-nums; }

/* Timeline */
.timeline { list-style: none; margin: 0; padding: 0; position: relative; }
.timeline::before {
  content: ""; position: absolute; left: 11px; top: 12px; bottom: 12px; width: 2px; background: var(--line);
}
.role { position: relative; padding-left: 44px; margin-bottom: 20px; }
.role::before {
  content: ""; position: absolute; left: 4px; top: 26px; width: 16px; height: 16px; border-radius: 50%;
  background: var(--bg); border: 3px solid var(--accent);
}
.role-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); overflow: hidden; }
.role-toggle {
  width: 100%; display: flex; justify-content: space-between; align-items: center; gap: 16px;
  padding: 20px 24px; background: none; border: 0; text-align: left; cursor: pointer; color: inherit; font: inherit;
}
.role-title { font-family: var(--serif); font-size: 22px; font-weight: 600; }
.role-company { color: var(--accent); font-weight: 600; }
.role-sub { font-size: 14px; color: var(--ink-soft); margin-top: 2px; }
.role-chevron { flex: none; width: 28px; height: 28px; border-radius: 50%; display: grid; place-items: center; background: var(--accent-soft); color: var(--accent); transition: transform 0.25s; }
.role.open .role-chevron { transform: rotate(180deg); }
.role-body { display: grid; grid-template-rows: 0fr; transition: grid-template-rows 0.3s ease; }
.role.open .role-body { grid-template-rows: 1fr; }
.role-body > div { overflow: hidden; }
.role-note { margin: 0 24px 8px; font-size: 14px; font-style: italic; color: var(--ink-soft); }
.bullets { list-style: none; margin: 0; padding: 0 24px 20px; }
.bullet { padding: 12px 0 12px 16px; border-top: 1px solid var(--line); position: relative; transition: opacity 0.2s, background 0.2s; }
.bullet::before { content: ""; position: absolute; left: 0; top: 22px; width: 6px; height: 6px; border-radius: 50%; background: var(--warm); }
.bullet strong { font-weight: 600; }
.filtering .bullet { opacity: 0.35; }
.filtering .bullet.match { opacity: 1; }
.filtering .bullet.match::before { background: var(--accent); box-shadow: 0 0 0 4px var(--accent-soft); }
.role-match { font-size: 13px; font-weight: 600; color: var(--accent); background: var(--accent-soft); padding: 2px 10px; border-radius: 999px; margin-left: 8px; white-space: nowrap; }
@media (max-width: 600px) {
  .role { padding-left: 32px; }
  .timeline::before { left: 7px; }
  .role::before { left: 0; }
  .role-toggle { padding: 16px; }
  .role-note { margin: 0 16px 8px; }
  .bullets { padding: 0 16px 16px; }
  .role-title { font-size: 19px; }
}

.extra-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; margin-top: 48px; }
.panel { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; }
.panel h3 { margin-bottom: 10px; }
.panel p { margin: 0; color: var(--ink-soft); }
.panel-wide { grid-column: 1 / -1; display: grid; grid-template-columns: 1fr 1fr; gap: 24px; }
.panel-wide p { color: var(--ink); }
@media (max-width: 760px) { .extra-grid, .panel-wide { grid-template-columns: 1fr; } }
.tags { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 6px; }
.tags li { font-size: 14px; padding: 4px 10px; border-radius: 6px; background: var(--accent-soft); color: var(--accent); font-weight: 500; }

/* Hobbies */
.hobbies { display: grid; grid-template-columns: repeat(2, 1fr); gap: 20px; margin-top: 32px; }
@media (max-width: 860px) { .hobbies { grid-template-columns: 1fr; } }
.hobby {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 28px; box-shadow: var(--shadow); display: flex; flex-direction: column;
}
.hobby-icon { width: 48px; height: 48px; border-radius: 12px; display: grid; place-items: center; background: var(--accent-soft); color: var(--accent); margin-bottom: 20px; }
.hobby-icon svg { width: 26px; height: 26px; }
.hobby-stat { font-family: var(--serif); font-size: 56px; font-weight: 700; line-height: 1; color: var(--accent); }
.hobby-stat-label { font-size: 14px; color: var(--ink-soft); margin: 6px 0 16px; }
.hobby p { margin: 0 0 16px; }
.hobby-list { list-style: none; margin: auto 0 0; padding: 0; }
.hobby-list li { display: flex; justify-content: space-between; gap: 12px; padding: 10px 0; border-top: 1px solid var(--line); font-size: 15px; }
.hobby-list span { color: var(--ink-soft); text-align: right; }

/* Trips */
.trips { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 32px 20px; }
.trip { background: none; border: 0; padding: 0; cursor: pointer; color: inherit; font: inherit; text-align: center; }
.trip-ring {
  width: 120px; height: 120px; margin: 0 auto 12px; border-radius: 50%; padding: 4px;
  background: conic-gradient(from 200deg, var(--warm), #e0a24a, var(--accent), var(--warm));
  transition: transform 0.2s;
}
.trip:hover .trip-ring, .trip:focus-visible .trip-ring { transform: scale(1.05); }
.trip-ring img, .trip-ring .trip-fallback {
  width: 100%; height: 100%; border-radius: 50%; object-fit: cover; display: block;
  border: 4px solid var(--bg); background: var(--bg-alt);
}
.trip-fallback { display: grid !important; place-items: center; font-family: var(--serif); font-size: 36px; color: var(--accent); }
.trip-title { font-weight: 600; font-size: 15px; }
.trip-meta { font-size: 13px; color: var(--ink-soft); }
.empty { color: var(--ink-soft); }

/* Story viewer */
.story { position: fixed; inset: 0; z-index: 100; background: rgba(8, 10, 9, 0.94); display: grid; place-items: center; }
.story[hidden] { display: none; }
.story-frame {
  position: relative; width: min(420px, 100vw); height: min(746px, 100dvh);
  background: #000; border-radius: 16px; overflow: hidden; color: #fff;
}
@media (max-width: 480px) { .story-frame { border-radius: 0; } }
.story-frame::before {
  content: ""; position: absolute; top: 0; left: 0; right: 0; height: 110px; z-index: 2; pointer-events: none;
  background: linear-gradient(rgba(0,0,0,0.55), transparent);
}
.story-bars { position: absolute; top: 10px; left: 10px; right: 10px; display: flex; gap: 4px; z-index: 3; }
.story-bar { flex: 1; height: 3px; border-radius: 2px; background: rgba(255,255,255,0.3); overflow: hidden; }
.story-bar i { display: block; height: 100%; width: 0; background: #fff; }
.story-head {
  position: absolute; top: 22px; left: 0; right: 0; z-index: 3; padding: 0 14px;
  display: flex; justify-content: space-between; align-items: center; text-shadow: 0 1px 3px rgba(0,0,0,0.6);
}
.story-head strong { display: block; font-size: 15px; }
.story-head span { font-size: 13px; opacity: 0.85; }
.story-close { background: none; border: 0; color: #fff; font-size: 34px; line-height: 1; cursor: pointer; padding: 4px 8px; z-index: 4; }
.story-media { position: absolute; inset: 0; display: grid; place-items: center; }
.story-media img, .story-media video { width: 100%; height: 100%; object-fit: contain; }
.story-caption {
  position: absolute; left: 0; right: 0; bottom: 0; margin: 0; padding: 48px 18px 22px; z-index: 3;
  background: linear-gradient(transparent, rgba(0,0,0,0.7)); font-size: 15px;
}
.story-caption:empty { display: none; }
.story-nav { position: absolute; top: 70px; bottom: 0; width: 35%; background: none; border: 0; cursor: pointer; z-index: 2; }
.story-prev { left: 0; }
.story-next { right: 0; width: 65%; }

.footer { border-top: 1px solid var(--line); padding: 28px 0; font-size: 14px; color: var(--ink-soft); }
.footer-inner { display: flex; justify-content: space-between; }

.reveal { opacity: 0; transform: translateY(16px); transition: opacity 0.6s ease, transform 0.6s ease; }
.reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }
}

/* Hobby photo cover (opens story viewer) */
.hobby.has-cover { padding-top: 0; overflow: hidden; }
.hobby-cover {
  position: relative; display: block; margin: 0 -28px 20px; padding: 0; border: 0; cursor: pointer;
  aspect-ratio: 3 / 2; overflow: hidden; background: var(--bg-alt);
}
.hobby-cover img { width: 100%; height: 100%; object-fit: cover; object-position: center 20%; display: block; transition: transform 0.4s ease; }
.hobby-cover:hover img, .hobby-cover:focus-visible img { transform: scale(1.04); }
.hobby-cover-pill {
  position: absolute; left: 14px; bottom: 14px; display: inline-flex; align-items: center; gap: 6px;
  padding: 6px 12px; border-radius: 999px; background: rgba(15, 20, 17, 0.72); color: #fff;
  font: 600 13px var(--sans); backdrop-filter: blur(6px);
}
.has-cover .hobby-icon { display: none; }

/* Resume + profile links */
.hero-actions { align-items: center; }
.btn-primary { display: inline-flex; align-items: center; gap: 8px; }
.btn-icon { width: 16px; height: 16px; }
.icon-btn {
  width: 46px; height: 46px; border-radius: 50%; display: inline-grid; place-items: center;
  border: 1px solid var(--line); background: var(--surface); color: var(--ink);
  transition: transform 0.15s, box-shadow 0.15s, color 0.15s;
}
.icon-btn:hover { transform: translateY(-1px); box-shadow: var(--shadow); color: var(--accent); }
.icon-btn svg { width: 20px; height: 20px; }
.work-resume { margin: -24px 0 40px; }
.work-resume a { color: var(--accent); font-weight: 600; text-decoration: none; }
.work-resume a:hover { text-decoration: underline; }
.footer-links { display: flex; gap: 20px; flex-wrap: wrap; }
@media (max-width: 600px) { .footer-inner { flex-direction: column; gap: 12px; } }

/* ---------- Multi-page nav ---------- */
.nav-name { display: inline-flex; align-items: center; gap: 8px; }
.nav-logo { width: 26px; height: 26px; color: var(--ink); }
.nav nav { align-items: center; }
.nav-icon { display: inline-grid; place-items: center; width: 28px; height: 28px; color: var(--ink-soft); }
.nav-icon:hover { color: var(--ink); }
.nav-icon svg { width: 19px; height: 19px; }
.nav nav a.active { color: var(--ink); box-shadow: inset 0 -2px 0 var(--warm); }
@media (max-width: 600px) { .nav-icon { display: none; } }

.page-title { font-size: clamp(36px, 6vw, 60px); letter-spacing: -0.015em; margin-bottom: 18px; }
.hero-hobbies { padding-bottom: 180px; }
.hero-hobbies .ridge-front { fill: var(--bg-alt); }
.jump-links { display: flex; gap: 10px; margin: 0; }
.jump-links a {
  text-decoration: none; font-size: 14px; font-weight: 600; padding: 8px 16px; border-radius: 999px;
  background: var(--surface); border: 1px solid var(--line);
}
.jump-links a:hover { border-color: var(--accent); color: var(--accent); }

/* ---------- Landing ---------- */
:root {
  --ill-ink: #23304a;
  --ill-paper: #fffdf9;
  --work-blob: #e3e8f4;
  --work-acc: #5873b8;
  --work-acc-soft: #c9d4ef;
  --out-blob: #f7e4d2;
  --sunset: #d9692f;
  --sun: #efb53f;
  --co-red: #c8372d;
  --pine: #3f6b4f;
  --aspen: #e9b949;
  --mtn: #b9c4d6;
  --wood: #b98552;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --ill-ink: #dfe5ef;
    --ill-paper: #262e3a;
    --work-blob: #1f2738;
    --work-acc: #8aa3e0;
    --work-acc-soft: #34405a;
    --out-blob: #33261d;
    --mtn: #4a5568;
    --pine: #5f9070;
    --wood: #8a6440;
  }
}
:root[data-theme="dark"] {
  --ill-ink: #dfe5ef;
  --ill-paper: #262e3a;
  --work-blob: #1f2738;
  --work-acc: #8aa3e0;
  --work-acc-soft: #34405a;
  --out-blob: #33261d;
  --mtn: #4a5568;
  --pine: #5f9070;
  --wood: #8a6440;
}

.landing { padding: 56px 0 72px; overflow: hidden; }
.landing-intro { text-align: center; padding: 0 16px; max-width: 760px; margin: 0 auto 28px; }
.landing-intro h1 { font-size: clamp(48px, 8vw, 84px); letter-spacing: -0.02em; margin-bottom: 10px; }
.landing-intro .eyebrow { margin-bottom: 16px; }
.landing-tagline { font-size: clamp(17px, 2.2vw, 20px); color: var(--ink-soft); margin: 0; }
@media (max-width: 700px) { .br-wide { display: none; } }

.doors { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; max-width: 1120px; margin: 0 auto; padding: 0 24px; }
.door { position: relative; display: block; text-decoration: none; color: inherit; border-radius: 40px; outline: none; }
.door-art { display: block; width: 100%; height: auto; overflow: visible; }
.door:nth-child(2) .door-art { margin-top: 28px; }

.blob { transition: transform 0.45s cubic-bezier(.2,.8,.2,1); transform-box: fill-box; transform-origin: center; }
.door-work .blob { fill: var(--work-blob); }
.door-hobbies .blob { fill: var(--out-blob); }
.blob-ring {
  fill: none; stroke-width: 2; opacity: 0; transform-box: fill-box; transform-origin: center;
  transform: scale(.97); transition: opacity 0.3s, transform 0.45s cubic-bezier(.2,.8,.2,1);
}
.door-work .blob-ring { stroke: var(--work-acc); }
.door-hobbies .blob-ring { stroke: var(--sunset); }

.ink { stroke: var(--ill-ink); stroke-width: 3; stroke-linecap: round; stroke-linejoin: round; fill: none; }
.ink.thin { stroke-width: 2; }
.ink-paper { stroke: var(--ill-paper); stroke-width: 2.6; stroke-linecap: round; fill: none; }
.hl { stroke: var(--work-blob); stroke-width: 3; stroke-linecap: round; fill: none; opacity: .55; }
.fill-ink { fill: var(--ill-ink); }
.paper { fill: var(--ill-paper); }
.dots circle { fill: var(--work-acc-soft); }
.door-work .acc { fill: var(--work-acc); }
.door-work .acc-soft { fill: var(--work-acc-soft); }
.door-work .fill-acc { fill: var(--work-acc); }
.line-acc { stroke: var(--work-acc); stroke-width: 3.5; stroke-linecap: round; stroke-linejoin: round; fill: none; }
.fill-sunset { fill: var(--sunset); }
.fill-sun { fill: var(--sun); }
.co-c { fill: none; stroke: var(--co-red); stroke-width: 13; }
.mtn { fill: var(--mtn); }
.snow { fill: #fff; }
.pine { fill: var(--pine); }
.aspen { fill: var(--aspen); }
.wood { fill: var(--wood); }
.sign-text { font: 700 9.5px var(--sans); letter-spacing: .06em; fill: #fff; }
.route { fill: none; stroke: var(--ill-ink); stroke-width: 2; stroke-dasharray: 3 7; stroke-linecap: round; }

/* Each icon lifts a beat after the last on hover. Long ease-out curves keep it soft. */
.door { --ease: cubic-bezier(.22, 1, .36, 1); }
.ic { transition: transform 0.9s var(--ease); transition-delay: calc(var(--d) * 45ms); will-change: transform; }
.door:hover .ic, .door:focus-visible .ic { transform: translateY(-5px); }
.blob { transition: transform 1s var(--ease); }
.door:hover .blob, .door:focus-visible .blob { transform: scale(1.012); }
.blob-ring { transition: opacity 0.6s ease, transform 1s var(--ease); }
.door:hover .blob-ring, .door:focus-visible .blob-ring { opacity: 1; transform: translate(9px, 9px) scale(1); }

.spin { transform-box: fill-box; transform-origin: center; transition: transform 1.6s var(--ease); }
.door:hover .spin { transform: rotate(-20deg); }
.flag { transform-box: fill-box; transform-origin: left center; animation: flag 3.2s ease-in-out infinite; }
@keyframes flag { 0%, 100% { transform: none; } 50% { transform: scaleX(.86) skewY(3deg); } }
.route { opacity: .45; }

.door-pill {
  position: absolute; left: 50%; bottom: 6%; transform: translate(-50%, 10px); opacity: 0;
  padding: 11px 26px; border-radius: 999px; font: 600 16px var(--sans);
  box-shadow: 0 6px 20px rgba(29, 36, 32, 0.15);
  transition: opacity 0.5s ease, transform 0.7s cubic-bezier(.22, 1, .36, 1);
  pointer-events: none;
}
.door-work .door-pill { background: var(--ill-paper); color: var(--ill-ink); border: 2px solid var(--work-acc); }
.door-hobbies .door-pill { background: var(--sunset); color: #fff; }
.door:hover .door-pill, .door:focus-visible .door-pill { opacity: 1; transform: translate(-50%, 0); }
.door:focus-visible .blob-ring { stroke-width: 3; }

/* Touch screens can't hover, so show the labels. */
@media (hover: none) {
  .door-pill { opacity: 1; transform: translate(-50%, 0); }
}
@media (max-width: 760px) {
  .landing { padding-top: 36px; }
  .doors { grid-template-columns: 1fr; gap: 8px; padding: 0 16px; }
  .door:nth-child(2) .door-art { margin-top: 0; }
  .door-art { max-width: 440px; margin: 0 auto; }
}
@media (prefers-reduced-motion: reduce) {
  .flag { animation: none; }
  .ic, .blob, .blob-ring, .spin { transition: none; }
}
.hero-summary { font-size: 18px; line-height: 1.65; max-width: 640px; }

/* JF twin-peaks mark: ink only, follows the theme. The name shows on phones only. */
.nav-logo { width: 34px; height: 34px; color: var(--ink); transition: transform 0.4s cubic-bezier(.22, 1, .36, 1); }
.nav-name:hover .nav-logo { transform: translateY(-2px); }
@media (min-width: 700px) { .nav-name-text { display: none; } }

/* Light/dark toggle */
:root { color-scheme: light; }
:root[data-theme="dark"] { color-scheme: dark; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) { color-scheme: dark; } }
.theme-toggle {
  display: inline-grid; place-items: center; width: 34px; height: 34px; padding: 0; border-radius: 50%;
  border: 1px solid var(--line); background: var(--surface); color: var(--ink-soft); cursor: pointer;
  transition: color 0.2s, border-color 0.2s, transform 0.3s cubic-bezier(.22, 1, .36, 1);
}
.theme-toggle:hover { color: var(--ink); border-color: var(--ink-soft); transform: rotate(-12deg); }
.theme-toggle svg { width: 17px; height: 17px; }
.theme-toggle .icon-sun { display: none; }
:root[data-theme="dark"] .theme-toggle .icon-sun { display: block; }
:root[data-theme="dark"] .theme-toggle .icon-moon { display: none; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .theme-toggle .icon-sun { display: block; }
  :root:not([data-theme="light"]) .theme-toggle .icon-moon { display: none; }
}

/* Backpacking trip tiles (open in the story viewer) */
.trip-tiles { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-top: auto; }
.trip-tile {
  position: relative; aspect-ratio: 4 / 5; padding: 0; border: 0; border-radius: 12px; overflow: hidden;
  cursor: pointer; background: var(--bg-alt); text-align: left; color: #fff;
}
.trip-tile img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform 0.6s cubic-bezier(.22, 1, .36, 1); }
.trip-tile:hover img, .trip-tile:focus-visible img { transform: scale(1.05); }
.trip-tile::after { content: ""; position: absolute; inset: 0; background: linear-gradient(transparent 45%, rgba(0, 0, 0, 0.65)); }
.trip-tile-text { position: absolute; left: 14px; right: 14px; bottom: 12px; z-index: 1; display: flex; flex-direction: column; }
.trip-tile-text strong { font-family: var(--serif); font-size: 20px; font-weight: 600; line-height: 1.15; }
.trip-tile-text span { font-size: 13px; opacity: 0.85; }
.trip-tile-play {
  position: absolute; top: 12px; right: 12px; z-index: 1; width: 30px; height: 30px; border-radius: 50%;
  display: grid; place-items: center; background: rgba(15, 20, 17, 0.6); backdrop-filter: blur(6px);
}

/* Hobby card link */
.hobby-link { margin-top: auto; padding-top: 12px; color: var(--accent); font-weight: 600; text-decoration: none; }
.hobby-link:hover { text-decoration: underline; }

/* ---------- 14ers ---------- */
.fourteeners { --peak: var(--accent); --peak-on: var(--warm); --snow: #dce7e1; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .fourteeners { --snow: #eef3f0; } }
:root[data-theme="dark"] .fourteeners { --snow: #eef3f0; }

.ft-stats { display: grid; grid-template-columns: auto auto 1fr; gap: 24px 48px; align-items: end; margin: 8px 0 28px; }
.ft-num { font-family: var(--serif); font-size: clamp(36px, 5vw, 48px); font-weight: 600; line-height: 1; color: var(--ink); }
.ft-label { font-size: 14px; color: var(--ink-soft); margin-top: 6px; }
.ft-progress { height: 10px; border-radius: 999px; background: var(--bg-alt); overflow: hidden; }
.ft-progress span { display: block; height: 100%; border-radius: 999px; background: var(--peak); }
@media (max-width: 700px) { .ft-stats { grid-template-columns: 1fr 1fr; } .ft-progress-wrap { grid-column: 1 / -1; } }

.ft-chart { position: relative; margin: 0 0 32px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 12px 8px 4px; }
.ft-chart-scroll { overflow-x: auto; }
.ft-chart svg { display: block; width: 100%; min-width: 640px; height: auto; }
.ft-grid { stroke: var(--line); stroke-width: 1; stroke-dasharray: 2 4; }
.ft-axis { font: 500 12px var(--sans); fill: var(--ink-soft); }
.ft-range { font: 600 13px var(--sans); fill: var(--ink); }
.ft-bracket { fill: none; stroke: var(--ink-soft); stroke-width: 1.2; opacity: .6; }
.ft-callout { font: 600 12px var(--sans); fill: var(--ink); }
.ft-mtn { fill: var(--peak); stroke: var(--surface); stroke-width: 2; stroke-linejoin: round; transition: fill 0.2s; }
.ft-snow { fill: var(--snow); pointer-events: none; }
.ft-hit { fill: transparent; cursor: pointer; }
.ft-peak { outline: none; }
.ft-peak.on .ft-mtn { fill: var(--peak-on); }
.ft-peak:focus-visible .ft-mtn { stroke: var(--ink); }

.ft-tip {
  position: absolute; transform: translate(-50%, calc(-100% - 12px)); pointer-events: none; z-index: 2;
  background: var(--ink); color: var(--bg); padding: 8px 12px; border-radius: 8px; white-space: nowrap;
  box-shadow: var(--shadow); font-size: 13px; display: flex; flex-direction: column;
}
.ft-tip[hidden] { display: none; }
.ft-tip strong { font-size: 14px; }
.ft-tip span { opacity: .8; }

.ft-list { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; }
@media (max-width: 900px) { .ft-list { grid-template-columns: 1fr 1fr; } }
@media (max-width: 520px) { .ft-list { grid-template-columns: 1fr; } }
.ft-group h3 { font-size: 18px; margin-bottom: 8px; display: flex; justify-content: space-between; align-items: baseline; }
.ft-group h3 span { font: 600 13px var(--sans); color: var(--ink-soft); }
.ft-group ul { list-style: none; margin: 0; padding: 0; }
.ft-group li {
  display: flex; justify-content: space-between; gap: 12px; padding: 7px 8px; margin: 0 -8px;
  border-top: 1px solid var(--line); font-size: 15px; border-radius: 6px; transition: background 0.15s;
}
.ft-group li.on { background: var(--accent-soft); }
.ft-elev { color: var(--ink-soft); font-variant-numeric: tabular-nums; }
.ft-num { white-space: nowrap; }
@media (max-width: 520px) { .ft-num { font-size: 32px; } }
.ft-name { display: inline-flex; align-items: center; gap: 6px; }
.ft-cam {
  display: inline-grid; place-items: center; width: 24px; height: 24px; padding: 0; border-radius: 6px;
  border: 0; background: var(--accent-soft); color: var(--accent); cursor: pointer;
}
.ft-cam:hover { background: var(--accent); color: var(--bg); }
.ft-cam svg { width: 14px; height: 14px; }

/* Story viewer: big on desktop, sized to each photo */
@media (min-width: 700px) {
  .story-frame {
    --ar: 0.75;
    width: min(94vw, calc(90dvh * var(--ar)));
    height: auto;
    aspect-ratio: var(--ar);
    max-height: 90dvh;
    border-radius: 14px;
    transition: width 0.35s cubic-bezier(.22, 1, .36, 1);
  }
  .story-media img, .story-media video { object-fit: cover; }
  .story-head strong { font-size: 16px; }
  .story-caption { font-size: 16px; padding: 56px 22px 24px; }
  /* Visible arrows on hover, since there's no swipe on desktop. */
  .story-nav::after {
    content: ""; position: absolute; top: 50%; width: 44px; height: 44px; margin-top: -22px; border-radius: 50%;
    background: rgba(0, 0, 0, 0.45) no-repeat center / 18px;
    opacity: 0; transition: opacity 0.2s;
  }
  .story-prev::after { left: 14px; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M15 5l-7 7 7 7'/%3E%3C/svg%3E"); }
  .story-next::after { right: 14px; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M9 5l7 7-7 7'/%3E%3C/svg%3E"); }
  .story-nav:hover::after { opacity: 1; }
  .story-prev, .story-next { width: 50%; }
}
