:root {
  --bg: #14130f;
  --bg-2: #1d1b15;
  --paper: #d7c7a9;
  --paper-soft: #eee1c4;
  --ink: #eee5cf;
  --muted: #b8aa90;
  --line: rgba(232, 216, 182, 0.22);
  --clay: #b06a45;
  --moss: #747456;
  --ochre: #b99359;
  --shadow: rgba(0, 0, 0, 0.45);
  --scroll-progress: 0%;
  --experience-progress: 0%;
  color-scheme: dark;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 9rem;
}

body {
  margin: 0;
  background:
    radial-gradient(circle at 72% 10%, rgba(185, 147, 89, 0.08), transparent 30rem),
    linear-gradient(180deg, var(--bg), #171611 58%, #10100d);
  color: var(--ink);
  font-family: "IBM Plex Mono", ui-monospace, SFMono-Regular, Menlo, monospace;
  overflow-x: hidden;
}

body.day {
  --bg: #dfd3b9;
  --bg-2: #cdbb9a;
  --paper: #312b23;
  --paper-soft: #f1e6ce;
  --ink: #241f19;
  --muted: #635646;
  --line: rgba(36, 31, 25, 0.2);
  --shadow: rgba(66, 45, 24, 0.22);
  color-scheme: light;
  background:
    radial-gradient(circle at 72% 10%, rgba(176, 106, 69, 0.1), transparent 30rem),
    linear-gradient(180deg, #dfd3b9, #d1c09f 58%, #c2ad86);
}

a {
  color: inherit;
  text-decoration: none;
}

button {
  color: inherit;
  font: inherit;
}

.grain {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 50;
  opacity: 0.16;
  background-image:
    linear-gradient(90deg, rgba(255,255,255,0.03) 1px, transparent 1px),
    linear-gradient(rgba(255,255,255,0.025) 1px, transparent 1px);
  background-size: 4px 5px;
  mix-blend-mode: overlay;
}

.cursor-light {
  position: fixed;
  width: 19rem;
  height: 19rem;
  border-radius: 50%;
  pointer-events: none;
  z-index: 0;
  background: radial-gradient(circle, rgba(226, 196, 131, 0.13), transparent 68%);
  transform: translate(-50%, -50%);
  opacity: 0;
  transition: opacity 240ms ease;
}

.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 20;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 2rem;
  padding: 2rem clamp(1.25rem, 5vw, 4.75rem);
  background: rgba(20, 19, 15, 0.94);
  border-bottom: 1px solid rgba(232, 216, 182, 0.12);
  backdrop-filter: blur(14px);
}

.scroll-player {
  position: fixed;
  left: clamp(1.25rem, 5vw, 4.75rem);
  right: clamp(1.25rem, 5vw, 4.75rem);
  bottom: 1rem;
  z-index: 30;
  display: grid;
  grid-template-columns: auto minmax(9rem, 13rem) minmax(12rem, 1fr);
  align-items: center;
  gap: 1rem;
  padding: 0.85rem 1rem;
  background: rgba(14, 14, 12, 0.86);
  border: 1px solid rgba(232, 216, 182, 0.16);
  box-shadow: 0 1.2rem 3rem rgba(0, 0, 0, 0.24);
  backdrop-filter: blur(16px);
}

body.day .scroll-player {
  background: rgba(223, 211, 185, 0.86);
}

.scroll-player__toggle {
  position: relative;
  width: 2.2rem;
  height: 2.2rem;
  border: 1px solid var(--muted);
  border-radius: 50%;
  background: transparent;
  cursor: pointer;
}

.scroll-player__toggle span {
  position: absolute;
  top: 50%;
  left: 54%;
  transform: translate(-50%, -50%);
  border-left: 0.52rem solid currentColor;
  border-top: 0.34rem solid transparent;
  border-bottom: 0.34rem solid transparent;
}

.scroll-player.paused .scroll-player__toggle span {
  left: 50%;
  width: 0.52rem;
  height: 0.75rem;
  border: solid currentColor;
  border-width: 0 0.18rem;
}

.scroll-player__meta {
  display: grid;
  gap: 0.2rem;
  min-width: 0;
  font-size: 0.68rem;
}

.scroll-player__title {
  color: var(--clay);
  text-transform: uppercase;
}

.scroll-player__section {
  color: var(--ink);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.scroll-player__rail {
  position: relative;
  height: 1.9rem;
}

.scroll-player__rail::before,
.scroll-player__fill {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  top: calc(50% - 1px);
  height: 2px;
}

.scroll-player__rail::before {
  background: rgba(232, 216, 182, 0.22);
}

.scroll-player__fill {
  right: auto;
  width: var(--scroll-progress);
  background: var(--paper);
  box-shadow: 0 0 1.2rem rgba(215, 199, 169, 0.22);
}

.scroll-player__mark {
  position: absolute;
  left: var(--x);
  top: 50%;
  width: 0.72rem;
  height: 0.72rem;
  border: 1px solid var(--paper);
  background: var(--bg);
  transform: translate(-50%, -50%) rotate(45deg);
  transition: background 180ms ease, transform 180ms ease;
}

.scroll-player__mark.active,
.scroll-player__mark:hover {
  background: var(--clay);
  transform: translate(-50%, -50%) rotate(45deg) scale(1.25);
}

.scroll-player__mark span {
  position: absolute;
  left: 50%;
  top: -1.7rem;
  color: var(--muted);
  font-size: 0.62rem;
  white-space: nowrap;
  transform: translateX(-50%) rotate(-45deg);
  opacity: 0;
  transition: opacity 180ms ease;
}

.scroll-player__mark:hover span,
.scroll-player__mark.active span {
  opacity: 1;
}

body.day .site-header {
  background: rgba(223, 211, 185, 0.94);
}

.brand,
h1,
h2,
h3 {
  font-family: "Cormorant Garamond", Georgia, serif;
  font-weight: 500;
  letter-spacing: 0;
}

.brand {
  font-size: clamp(2rem, 3vw, 3.25rem);
  line-height: 1;
}

.main-nav {
  display: flex;
  gap: clamp(1.4rem, 4vw, 4rem);
  font-size: 0.88rem;
}

.main-nav a {
  position: relative;
  padding: 0.35rem 0;
}

.main-nav a::after {
  content: "";
  position: absolute;
  left: 0;
  right: 100%;
  bottom: 0;
  height: 1px;
  background: currentColor;
  transition: right 220ms ease;
}

.main-nav a:hover::after,
.main-nav a:focus-visible::after {
  right: 0;
}

.theme-toggle {
  justify-self: end;
  display: flex;
  align-items: center;
  gap: 0.65rem;
  border: 0;
  background: transparent;
  cursor: pointer;
  font-size: 0.78rem;
  font-style: italic;
}

.toggle-track {
  width: 3.25rem;
  height: 1.65rem;
  border: 1px solid var(--line);
  border-radius: 3rem;
  padding: 0.22rem;
  background: rgba(238, 229, 207, 0.1);
}

.toggle-track span {
  display: block;
  width: 1.08rem;
  height: 1.08rem;
  border-radius: 50%;
  background: var(--paper);
  transition: transform 220ms ease;
}

body.day .toggle-track span {
  transform: translateX(1.54rem);
}

.section {
  position: relative;
  z-index: 1;
  padding-inline: clamp(1.25rem, 5vw, 4.75rem);
  scroll-margin-top: 9rem;
}

.site-footer {
  scroll-margin-top: 9rem;
}

.hero {
  min-height: 102vh;
  display: grid;
  grid-template-columns: minmax(24rem, 1.05fr) minmax(18rem, 0.95fr);
  align-items: center;
  gap: clamp(2rem, 5vw, 5rem);
  padding-top: 6rem;
  border-bottom: 1px solid var(--line);
}

.hero-copy {
  max-width: 64rem;
  position: relative;
  z-index: 5;
}

.hero-title,
h1 {
  margin: 0;
  font-size: clamp(4rem, 7.3vw, 9.2rem);
  line-height: 0.84;
  letter-spacing: 0;
}

.hero-title {
  max-width: 15ch;
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Helvetica Neue", Arial, sans-serif;
  font-weight: 850;
}

.hero-title span {
  color: #f0cf9f;
}

body.day .hero-title span {
  color: #8c4f2f;
}

.hero-copy > p {
  max-width: 54rem;
  margin: clamp(1.2rem, 3vw, 2.4rem) 0 2.15rem;
  color: var(--muted);
  font-size: clamp(1.05rem, 1.55vw, 1.7rem);
  line-height: 1.6;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.7rem;
}

.button-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 3.05rem;
  padding: 0 1.1rem;
  border: 1px solid var(--muted);
  border-radius: 999px;
  background: rgba(20, 19, 15, 0.1);
  font-size: clamp(0.82rem, 1vw, 1.05rem);
  transition: background 220ms ease, transform 220ms ease;
}

.button-link--primary {
  background: #f1e6ce;
  border-color: #f1e6ce;
  color: #28231b;
}

.button-link--ghost {
  background: rgba(238, 229, 207, 0.06);
  border-color: rgba(238, 229, 207, 0.35);
}

.button-link:hover,
.button-link:focus-visible {
  background: rgba(238, 229, 207, 0.12);
  transform: translateY(-2px);
}

.audio-card {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: end;
  gap: 0.85rem;
  max-width: 33rem;
  margin-top: clamp(3rem, 8vw, 7rem);
  color: var(--muted);
  font-size: 0.76rem;
}

.audio-card::after {
  content: "";
  grid-column: 1 / -1;
  height: 1px;
  width: var(--scroll-progress);
  background: var(--ochre);
  opacity: 0.85;
  transition: width 80ms linear;
}

.audio-play {
  width: 1.8rem;
  height: 1.8rem;
  border: 1px solid var(--muted);
  border-radius: 50%;
  background: transparent;
  cursor: pointer;
  position: relative;
}

.audio-play::before {
  content: "";
  position: absolute;
  top: 50%;
  left: 52%;
  transform: translate(-50%, -50%);
  border-left: 0.48rem solid currentColor;
  border-top: 0.32rem solid transparent;
  border-bottom: 0.32rem solid transparent;
}

.audio-play.is-playing::before {
  width: 0.5rem;
  height: 0.72rem;
  border: solid currentColor;
  border-width: 0 0.18rem;
}

.wave {
  display: flex;
  align-items: center;
  gap: 0.2rem;
  height: 2rem;
  margin-bottom: 0.35rem;
}

.wave span {
  width: 1px;
  height: var(--h, 0.7rem);
  background: var(--ochre);
  opacity: 0.8;
  animation: pulse 1.4s ease-in-out infinite;
}

.wave span:nth-child(2n) { --h: 1.2rem; animation-delay: -0.2s; }
.wave span:nth-child(3n) { --h: 0.4rem; animation-delay: -0.4s; }
.wave span:nth-child(5n) { --h: 1.65rem; animation-delay: -0.7s; }

@keyframes pulse {
  50% { transform: scaleY(0.35); opacity: 0.45; }
}

.map-stage {
  position: relative;
  min-height: min(46rem, 72vw);
  isolation: isolate;
}

.folder-layer,
.map-paper {
  position: absolute;
  box-shadow: 0 2rem 5rem var(--shadow);
}

.folder-layer {
  inset: 7% 5% 8% 13%;
  background: #342a20;
  border: 1px solid rgba(238, 229, 207, 0.08);
}

.folder-back {
  transform: rotate(3deg);
}

.folder-mid {
  inset: 3% 8% 11% 8%;
  transform: rotate(-1.5deg);
  background:
    linear-gradient(105deg, transparent 0 56%, rgba(0,0,0,0.12) 56%),
    repeating-linear-gradient(95deg, rgba(238, 229, 207, 0.08) 0 1px, transparent 1px 3.6rem),
    #7b664b;
}

.map-paper {
  inset: 8% 8% 12% 9%;
  padding: clamp(1.2rem, 3vw, 2.3rem);
  transform: rotate(1.2deg);
  background:
    linear-gradient(rgba(60, 49, 35, 0.14), rgba(60, 49, 35, 0.14)),
    repeating-linear-gradient(38deg, transparent 0 1.6rem, rgba(35, 28, 20, 0.08) 1.7rem),
    var(--paper-soft);
  color: #2b251d;
  border: 1px solid rgba(42, 34, 25, 0.22);
}

.paper-note {
  width: max-content;
  max-width: 70%;
  margin: -0.5rem auto 1.1rem;
  padding: 0.8rem 1.2rem;
  background: #eee2c6;
  transform: rotate(-0.6deg);
  box-shadow: 0 0.5rem 1rem rgba(42, 34, 25, 0.14);
}

.photo-window {
  position: relative;
  width: min(86%, 34rem);
  aspect-ratio: 1.24;
  margin: 0 auto;
  padding: 0.8rem;
  background: #eee0c3;
  transform: rotate(-2.6deg);
  box-shadow: 0 1.5rem 2.5rem rgba(42, 34, 25, 0.25);
}

.landscape {
  position: relative;
  height: 100%;
  overflow: hidden;
  background:
    linear-gradient(180deg, rgba(237, 228, 205, 0.55), transparent 42%),
    linear-gradient(180deg, #7d7b6d 0%, #4d5548 54%, #20261f 100%);
  filter: grayscale(0.6) sepia(0.22);
}

.ridge,
.lake {
  position: absolute;
  left: -4%;
  right: -4%;
}

.ridge {
  bottom: 23%;
  height: 44%;
  background: linear-gradient(135deg, transparent 0 32%, #3f493c 32% 52%, transparent 52%),
              linear-gradient(45deg, transparent 0 44%, #586250 44% 62%, transparent 62%);
  opacity: 0.82;
}

.ridge-two {
  bottom: 8%;
  transform: scaleX(1.1) translateX(-2%);
  opacity: 0.95;
}

.lake {
  bottom: 0;
  height: 24%;
  background: linear-gradient(90deg, #5d685d, #282f29);
  clip-path: polygon(0 65%, 34% 38%, 55% 58%, 100% 20%, 100% 100%, 0 100%);
}

.pin {
  position: absolute;
  width: 1.6rem;
  height: 1.6rem;
  border: 0;
  background: var(--paper-soft);
  border-radius: 50% 50% 50% 0;
  box-shadow: 0 0 0 0.25rem rgba(0, 0, 0, 0.16);
  transform: rotate(-45deg);
  cursor: pointer;
  transition: transform 200ms ease, background 200ms ease;
}

.pin::after {
  content: "";
  position: absolute;
  inset: 0.48rem;
  border-radius: 50%;
  background: #46392a;
}

.pin:hover,
.pin.active {
  background: var(--clay);
  transform: rotate(-45deg) translateY(-0.24rem);
}

.pin-one { left: 65%; top: 54%; }
.pin-two { left: 43%; top: 35%; }
.pin-three { left: 71%; top: 18%; }

.pin-card {
  position: absolute;
  right: 9%;
  bottom: 16%;
  min-width: 8rem;
  padding: 0.85rem 0.95rem;
  color: var(--paper-soft);
  background: rgba(24, 21, 17, 0.8);
  border: 1px solid rgba(238, 229, 207, 0.18);
  font-size: 0.72rem;
  transform: rotate(2.6deg);
}

.pin-card strong,
.pin-card span {
  display: block;
}

.mini-photo {
  position: absolute;
  left: 9%;
  bottom: 9%;
  width: 8rem;
  aspect-ratio: 0.78;
  background:
    linear-gradient(180deg, transparent, rgba(0,0,0,0.2)),
    linear-gradient(140deg, #cdc1a5, #48513f 48%, #20251e);
  border: 0.65rem solid #eadfca;
  transform: rotate(8deg);
  box-shadow: 0 1rem 1.6rem rgba(42, 34, 25, 0.25);
}

.map-caption {
  position: absolute;
  right: 18%;
  bottom: 7%;
  margin: 0;
  padding: 0.7rem 1rem;
  background: #d9c59e;
  transform: rotate(-2deg);
}

.botanical {
  position: absolute;
  right: 7%;
  bottom: 11%;
  width: 1px;
  height: 14rem;
  background: #5c452e;
  transform: rotate(12deg);
  z-index: 4;
}

.botanical::before,
.botanical::after {
  content: "";
  position: absolute;
  width: 3.8rem;
  height: 1.7rem;
  border-radius: 100% 0;
  background: #817d52;
  transform-origin: left center;
}

.botanical::before {
  top: 5rem;
  left: 0;
  transform: rotate(-28deg);
}

.botanical::after {
  top: 7.5rem;
  left: 0;
  transform: rotate(24deg);
}

.scroll-cue {
  position: absolute;
  left: 50%;
  bottom: 2.2rem;
  transform: translateX(-50%);
  color: var(--muted);
  font-size: 0.72rem;
  text-align: center;
}

.scroll-cue span {
  display: block;
  margin-top: 0.4rem;
}

.work {
  padding-top: 2rem;
  padding-bottom: 2rem;
}

.experience-timeline {
  height: 520vh;
  padding-inline: 0;
  color: #28231b;
  background:
    linear-gradient(90deg, transparent 0 4.7rem, rgba(176, 106, 69, 0.22) 4.75rem 4.88rem, transparent 4.95rem),
    repeating-linear-gradient(180deg, transparent 0 3.5rem, rgba(38, 33, 25, 0.055) 3.56rem),
    #e4d4b5;
  border-top: 1px solid rgba(40, 35, 27, 0.2);
  border-bottom: 1px solid rgba(40, 35, 27, 0.2);
}

.experience-sticky {
  position: sticky;
  top: 0;
  z-index: 2;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  overflow: hidden;
  padding: 7rem clamp(1.25rem, 5vw, 4.75rem) 6rem;
  background:
    linear-gradient(90deg, transparent 0 4.7rem, rgba(176, 106, 69, 0.22) 4.75rem 4.88rem, transparent 4.95rem),
    repeating-linear-gradient(180deg, transparent 0 3.5rem, rgba(38, 33, 25, 0.055) 3.56rem),
    #e4d4b5;
}

.experience-timeline .section-heading {
  flex: 0 0 auto;
  border-color: rgba(40, 35, 27, 0.22);
}

.experience-window {
  position: relative;
  flex: 1;
  min-height: 31rem;
  overflow: hidden;
  display: flex;
  align-items: center;
  padding-bottom: 3rem;
}

.experience-window::before {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  top: 50%;
  height: 1px;
  background: rgba(40, 35, 27, 0.22);
}

.experience-window::after {
  content: "";
  position: absolute;
  left: 0;
  top: 50%;
  width: var(--experience-progress);
  height: 2px;
  background: #28231b;
}

.experience-rule {
  position: absolute;
  left: 0;
  right: 0;
  top: calc(50% - 1.8rem);
  display: flex;
  justify-content: space-between;
  color: rgba(40, 35, 27, 0.48);
  font-size: 0.72rem;
  pointer-events: none;
}

.experience-rule span {
  position: relative;
}

.experience-rule span::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 2rem;
  width: 1px;
  height: 2.5rem;
  background: rgba(40, 35, 27, 0.12);
}

.experience-track {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  gap: clamp(2rem, 6vw, 6.5rem);
  padding: 1rem 18vw 10rem 12vw;
  will-change: transform;
}

.experience-card {
  flex: 0 0 min(72vw, 58rem);
  min-height: 18rem;
  display: grid;
  grid-template-columns: minmax(7rem, 10rem) minmax(20rem, 1fr);
  grid-template-rows: auto auto 1fr;
  column-gap: clamp(2rem, 5vw, 5rem);
  padding: 2.1rem 0;
  opacity: 0.42;
  transform: scale(0.96);
  transition: opacity 220ms ease, transform 220ms ease;
}

.experience-card.active {
  opacity: 1;
  transform: scale(1);
}

.experience-card time {
  grid-row: 1 / 4;
  color: #6f604e;
  font-size: 0.9rem;
  line-height: 1.35;
  text-transform: uppercase;
}

.experience-card p {
  margin: 0 0 0.65rem;
  color: #9a5e3e;
  font-size: 0.72rem;
  text-transform: uppercase;
}

.experience-card h3 {
  margin: 0 0 0.8rem;
  font-size: clamp(3rem, 6.1vw, 5.9rem);
  line-height: 0.92;
  max-width: 14ch;
}

.experience-card span {
  color: #5a4d3f;
  font-size: clamp(1rem, 1.25vw, 1.25rem);
  line-height: 1.75;
  max-width: 54rem;
}

.experience-card.current h3 {
  max-width: 16ch;
}

.section-heading {
  display: flex;
  justify-content: space-between;
  align-items: end;
  gap: 2rem;
  border-bottom: 1px solid var(--line);
  padding-bottom: 1rem;
}

h2 {
  margin: 0;
  font-size: clamp(2.3rem, 4vw, 3.6rem);
  line-height: 1;
}

.section-heading a {
  color: var(--muted);
  font-size: 0.78rem;
}

.project-row {
  display: grid;
  grid-template-columns: 3rem minmax(9rem, 24rem) minmax(16rem, 1fr) auto;
  gap: clamp(1rem, 3vw, 3rem);
  align-items: center;
  min-height: 11rem;
  border-bottom: 1px solid var(--line);
  padding: 1.35rem 0;
  position: relative;
}

.project-number {
  color: var(--clay);
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: 1.8rem;
}

.project-thumb {
  height: 8rem;
  background-color: rgba(238, 229, 207, 0.08);
  border: 1px solid rgba(238, 229, 207, 0.16);
}

.botanical-thumb {
  background:
    radial-gradient(circle at 55% 30%, rgba(49, 44, 32, 0.2) 0 0.22rem, transparent 0.24rem),
    linear-gradient(80deg, transparent 49.6%, rgba(52, 45, 33, 0.8) 50%, transparent 50.4%),
    repeating-linear-gradient(90deg, rgba(30,28,23,0.15) 0 1px, transparent 1px 4rem),
    #c7b68f;
}

.coast-thumb {
  background:
    linear-gradient(160deg, transparent 0 34%, rgba(32, 38, 32, 0.76) 35% 58%, transparent 59%),
    linear-gradient(180deg, #cec2a2, #55604f 52%, #1f241f);
}

.code-thumb {
  background:
    linear-gradient(90deg, #1c1a15 0 48%, transparent 48%),
    repeating-linear-gradient(180deg, rgba(214, 196, 160, 0.5) 0 1px, transparent 1px 1rem),
    #c5b18d;
}

.project-copy p {
  margin: 0 0 0.4rem;
  color: var(--clay);
  font-size: 0.68rem;
  text-transform: uppercase;
}

.project-copy h3 {
  margin: 0;
  font-size: clamp(2rem, 3.6vw, 3rem);
  line-height: 1;
}

.project-copy span,
.project-detail {
  color: var(--muted);
  line-height: 1.7;
}

.project-row button {
  border: 0;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  font-size: 0.78rem;
}

.project-detail {
  grid-column: 3 / 5;
  max-height: 0;
  overflow: hidden;
  transition: max-height 260ms ease;
}

.project-row.open .project-detail {
  max-height: 5rem;
}

.obsessions {
  padding-top: 2rem;
  padding-bottom: 3.5rem;
}

.obsessions p {
  margin: 0.5rem 0 1.5rem;
  color: var(--muted);
}

.tag-board {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem 1.2rem;
  min-height: 5rem;
}

.tag {
  min-width: 7rem;
  min-height: 3rem;
  padding: 0.75rem 1.15rem;
  border: 0;
  color: #2a251d;
  box-shadow: 0 0.8rem 1.7rem rgba(0,0,0,0.24);
  cursor: grab;
  transform: rotate(var(--r, -2deg));
}

.tag:active {
  cursor: grabbing;
}

.tag:nth-child(2n) { --r: 1.5deg; }
.tag:nth-child(3n) { --r: -4deg; }
.tag.moss { background: #8d8d69; }
.tag.paper { background: #e6d8bb; }
.tag.pale { background: #d2c3a7; }
.tag.ochre { background: #c49b5f; }
.tag.clay { background: #ad6744; }

.notes {
  padding: 0;
  color: #28231b;
}

.notebook {
  padding: clamp(1.5rem, 4vw, 3rem) clamp(1.25rem, 5vw, 4.75rem);
  background:
    linear-gradient(90deg, transparent 0 5.2rem, rgba(176, 106, 69, 0.24) 5.25rem 5.32rem, transparent 5.4rem),
    repeating-linear-gradient(180deg, transparent 0 3rem, rgba(38, 33, 25, 0.08) 3.05rem),
    #e4d4b5;
}

.notebook .section-heading {
  border-color: rgba(40, 35, 27, 0.22);
}

.note-row {
  display: grid;
  grid-template-columns: 7rem 1fr minmax(9rem, 18rem);
  gap: clamp(1rem, 4vw, 4rem);
  align-items: center;
  border-bottom: 1px solid rgba(40, 35, 27, 0.18);
  padding: 1.35rem 0;
}

.note-row time {
  color: #6f604e;
  text-transform: uppercase;
  font-size: 0.78rem;
}

.note-row h3 {
  margin: 0 0 0.5rem;
  font-size: clamp(1.6rem, 2.6vw, 2.2rem);
}

.note-row p {
  margin: 0;
  color: #5a4d3f;
  line-height: 1.7;
}

.note-sketch {
  height: 6.4rem;
  opacity: 0.55;
  background: linear-gradient(135deg, transparent 48%, #44382d 49% 51%, transparent 52%);
}

.mountain {
  clip-path: polygon(0 82%, 18% 42%, 32% 68%, 48% 28%, 78% 82%, 100% 56%, 100% 100%, 0 100%);
  background: #44382d;
}

.window {
  border: 2px solid #44382d;
  background:
    linear-gradient(90deg, transparent 48%, #44382d 49% 51%, transparent 52%),
    linear-gradient(180deg, transparent 48%, #44382d 49% 51%, transparent 52%);
}

.cup {
  border: 2px solid #44382d;
  border-radius: 0 0 3rem 3rem;
  width: 8rem;
  justify-self: end;
}

.site-footer {
  display: grid;
  grid-template-columns: 1.6fr repeat(4, 1fr);
  gap: clamp(1rem, 3vw, 3rem);
  padding: clamp(2.2rem, 5vw, 4rem) clamp(1.25rem, 5vw, 4.75rem);
  border-top: 1px solid var(--line);
}

.site-footer h2 {
  font-size: clamp(2.5rem, 4vw, 4rem);
}

.site-footer p,
.site-footer span {
  color: var(--muted);
  line-height: 1.7;
}

.site-footer a {
  display: block;
  border-left: 1px solid var(--line);
  padding-left: 1.5rem;
}

.site-footer span {
  display: block;
  margin-top: 0.7rem;
  font-size: 0.78rem;
}

[data-reveal] {
  opacity: 1;
  transform: translateY(0);
  transition: opacity 700ms ease, transform 700ms ease;
}

[data-reveal].visible {
  opacity: 1;
  transform: translateY(0);
}

@media (max-width: 920px) {
  .site-header {
    grid-template-columns: 1fr auto;
  }

  .main-nav {
    order: 3;
    grid-column: 1 / -1;
    justify-content: space-between;
    gap: 0.8rem;
  }

  .hero {
    grid-template-columns: 1fr;
    padding-top: 9rem;
    padding-bottom: 5rem;
  }

  .scroll-player {
    grid-template-columns: auto 1fr;
  }

  .scroll-player__meta {
    display: none;
  }

  .map-stage {
    min-height: 34rem;
  }

  .project-row {
    grid-template-columns: 2.5rem 1fr;
  }

  .project-thumb,
  .project-copy,
  .project-row button,
  .project-detail {
    grid-column: 2;
  }

  .project-row button {
    justify-self: start;
  }

  .note-row,
  .site-footer {
    grid-template-columns: 1fr;
  }

  .site-footer a {
    border-left: 0;
    border-top: 1px solid var(--line);
    padding: 1rem 0 0;
  }

  .experience-sticky {
    justify-content: flex-start;
    min-height: 100svh;
    padding-top: 8rem;
    padding-bottom: 7rem;
  }

  .experience-window {
    flex: 0 0 auto;
    min-height: min(34rem, 66svh);
    padding-bottom: 4rem;
  }

  .experience-track {
    padding: 0 14vw 8rem 7vw;
    gap: 3rem;
  }

  .experience-card {
    flex-basis: 84vw;
    grid-template-columns: 1fr;
    gap: 0.8rem;
  }

  .experience-card time {
    grid-row: auto;
  }

  .experience-card h3 {
    font-size: clamp(2.25rem, 10.5vw, 4.4rem);
    max-width: 11ch;
  }

  .experience-card span {
    font-size: 0.95rem;
    line-height: 1.55;
  }
}

@media (max-width: 620px) {
  .site-header {
    position: absolute;
    padding-top: 1.2rem;
  }

  .main-nav {
    justify-content: flex-start;
    flex-wrap: wrap;
    row-gap: 0.6rem;
    font-size: 0.68rem;
  }

  .theme-toggle span:first-child {
    display: none;
  }

  h1 {
    font-size: clamp(3.2rem, 15vw, 4.4rem);
  }

  .hero-title {
    font-size: clamp(4rem, 21vw, 6.8rem);
    max-width: 8.8ch;
  }

  .hero-copy > p {
    font-size: clamp(1.05rem, 5vw, 1.45rem);
  }

  .hero-actions {
    gap: 0.7rem;
  }

  .button-link {
    min-height: 3rem;
    padding: 0 1.1rem;
  }

  .audio-card {
    grid-template-columns: auto 1fr;
  }

  .audio-card time {
    grid-column: 2;
  }

  .scroll-player {
    left: 0.8rem;
    right: 0.8rem;
    bottom: 0.7rem;
    grid-template-columns: auto 1fr;
    gap: 0.75rem;
    padding: 0.75rem;
  }

  .scroll-player__rail {
    height: 1.4rem;
  }

  .scroll-player__mark span {
    display: none;
  }

  .map-stage {
    min-height: 28rem;
    margin-inline: -1rem;
  }

  .map-paper {
    inset: 10% 3% 10% 3%;
  }

  .paper-note,
  .map-caption,
  .mini-photo {
    display: none;
  }

  .photo-window {
    width: 94%;
    margin-top: 2.5rem;
  }

  .section-heading {
    align-items: start;
    flex-direction: column;
    gap: 0.75rem;
  }

  .note-row {
    gap: 0.8rem;
  }

  .note-sketch {
    display: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
  }
}
