:root {
  --pine: #171d18;
  --pine-soft: #273028;
  --gold: #d4a431;
  --blue: #657c83;
  --rust: #98452e;
  --paper: #f1e9d7;
  --paper-deep: #e6d9bc;
  --ink: #1d211d;
  --muted: #68685f;
  --hairline: rgba(23, 29, 24, 0.4);
  --serif: Georgia, "Times New Roman", serif;
  --sans: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --mono: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  --western: "Rockwell Extra Bold", Rockwell, "Arial Black", Georgia, serif;
}

* {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

html {
  background: var(--gold);
}

body {
  margin: 0;
  color: var(--ink);
  background: var(--gold);
  font-family: var(--sans);
}

button,
a {
  -webkit-tap-highlight-color: transparent;
}

.route-scroll {
  position: relative;
  height: 300svh;
  background: var(--gold);
}

.route-sticky {
  position: sticky;
  top: 0;
  width: 100%;
  height: 100svh;
  overflow: hidden;
  isolation: isolate;
  background: var(--gold);
}

.route-sticky::after,
.collage-section::after {
  position: absolute;
  inset: 0;
  z-index: -1;
  background-image: radial-gradient(rgba(241, 233, 215, 0.18) 0.75px, transparent 0.75px);
  background-size: 5px 5px;
  content: "";
  mix-blend-mode: soft-light;
  opacity: 0.82;
  pointer-events: none;
}

.hero-copy {
  position: absolute;
  bottom: clamp(64px, 11vh, 110px);
  left: clamp(22px, 4.5vw, 78px);
  z-index: 6;
  width: min(54vw, 800px);
  will-change: transform, opacity;
}

.hero-logo {
  display: block;
  width: min(41vw, 600px);
  height: auto;
  margin: 0 0 -6%;
  transform: rotate(-1.2deg);
}

.hero-copy p {
  max-width: 650px;
  margin: clamp(52px, 9vh, 96px) 0 0 0.7vw;
  font-family: var(--serif);
  font-size: clamp(1.35rem, 2.6vw, 2.8rem);
  line-height: 1.04;
  letter-spacing: -0.025em;
  text-shadow: 0 0 9px var(--gold), 0 0 9px var(--gold);
  text-wrap: balance;
}

.hero-date {
  position: absolute;
  right: 4vw;
  bottom: clamp(68px, 8vh, 96px);
  z-index: 7;
  display: flex;
  gap: 18px;
  justify-content: space-between;
  align-items: end;
  width: min(42vw, 570px);
  padding-top: 13px;
  border-top: 1px solid var(--hairline);
  text-shadow: 0 0 9px var(--gold), 0 0 9px var(--gold);
  will-change: transform, opacity;
}

.hero-date-year {
  font-family: var(--mono);
  font-size: clamp(0.58rem, 0.78vw, 0.75rem);
  letter-spacing: 0.15em;
  text-transform: uppercase;
}

.hero-date-year {
  flex: 0 0 auto;
  margin-bottom: 0.7em;
  text-align: right;
}

.hero-date-main {
  flex: 0 1 auto;
  font-family: var(--serif);
  font-size: clamp(2.9rem, 4.8vw, 5rem);
  font-weight: 400;
  line-height: 0.82;
  letter-spacing: -0.05em;
  text-transform: uppercase;
  white-space: nowrap;
}

.route-map {
  position: absolute;
  top: 1vh;
  right: -4vw;
  z-index: 3;
  width: min(72vw, 1020px);
  aspect-ratio: 4 / 3;
  overflow: visible;
  transform: translate3d(12vw, 8vh, 0) scale(1.6) rotate(5deg);
  transform-origin: 50% 50%;
  will-change: transform;
}

.route-art,
.topo-map {
  position: absolute;
  inset: 0;
  display: block;
  width: 100%;
  height: 100%;
}

.topo-map {
  z-index: 1;
  opacity: 0;
  will-change: opacity;
}

.route-art {
  z-index: 2;
  overflow: visible;
}

.route-art.route-unavailable {
  opacity: 0;
}

.route-halo,
.route-line {
  fill: none;
  stroke-linecap: round;
  stroke-linejoin: round;
  vector-effect: non-scaling-stroke;
}

.route-halo {
  stroke: var(--paper);
  stroke-width: 14;
  stroke-opacity: 0.68;
}

.route-line {
  stroke: var(--rust);
  stroke-width: 6;
  opacity: 0.76;
  will-change: opacity;
}

.route-day-two {
  stroke: var(--blue);
  opacity: 0;
  pointer-events: none;
  will-change: opacity, stroke-dashoffset;
}

.route-labels {
  opacity: 0;
  will-change: opacity;
}

.place-label circle {
  fill: var(--gold);
  stroke: var(--ink);
  stroke-width: 3;
  vector-effect: non-scaling-stroke;
}

.place-label text {
  fill: var(--ink);
  stroke: var(--gold);
  stroke-width: 8px;
  paint-order: stroke;
  font-family: var(--mono);
  font-size: 21px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.place-label-landmark text {
  font-size: 16.5px;
  font-weight: 500;
}

.scroll-cue {
  position: absolute;
  right: 2.35vw;
  bottom: 24px;
  z-index: 8;
  display: flex;
  gap: 11px;
  align-items: center;
  font-family: var(--mono);
  font-size: 0.55rem;
  letter-spacing: 0.13em;
  text-transform: uppercase;
  will-change: opacity;
}

.scroll-cue svg {
  display: block;
  width: 13px;
  height: 17px;
  overflow: visible;
}

.scroll-cue path {
  fill: none;
  stroke: currentColor;
  stroke-linecap: square;
  stroke-linejoin: miter;
  stroke-width: 1.25;
  vector-effect: non-scaling-stroke;
}

.elevation-panel {
  position: absolute;
  right: 4vw;
  bottom: 86px;
  left: 4vw;
  z-index: 7;
  padding: 17px 0 0;
  border-top: 1px solid var(--hairline);
  opacity: 0;
  transform: translate3d(0, 32px, 0);
  pointer-events: none;
  will-change: transform, opacity;
}

.elevation-heading {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 18px;
  margin-bottom: 9px;
}

.elevation-days {
  display: flex;
  gap: 18px;
  align-items: center;
}

.elevation-days span {
  display: inline-flex;
  gap: 7px;
  align-items: center;
  font-family: var(--mono);
  font-size: 0.72rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.elevation-days span::before {
  width: 22px;
  height: 3px;
  background: currentColor;
  content: "";
}

.day-one-marker {
  color: var(--rust);
}

.day-two-marker {
  color: var(--blue);
}

.elevation-heading p {
  margin: 0;
  font-family: var(--serif);
  font-size: 1.02rem;
  letter-spacing: -0.01em;
  white-space: nowrap;
}

#elevation-profile {
  display: block;
  width: 100%;
  height: min(20vh, 180px);
  overflow: visible;
}

.elevation-base,
.elevation-split {
  stroke: rgba(23, 29, 24, 0.4);
  stroke-width: 1;
  vector-effect: non-scaling-stroke;
}

.elevation-line {
  fill: none;
  stroke-width: 2.6;
  vector-effect: non-scaling-stroke;
}

.elevation-line-day-one {
  stroke: var(--rust);
}

.elevation-line-day-two {
  stroke: var(--blue);
}

.elevation-area-day-one {
  fill: url(#elevation-fill-day-one);
}

.elevation-area-day-two {
  fill: url(#elevation-fill-day-two);
}

.elevation-label {
  fill: var(--ink);
  font-family: var(--serif);
  font-size: 18px;
  font-weight: 600;
  letter-spacing: 0.025em;
}

.gpx-download {
  position: absolute;
  right: auto;
  bottom: 24px;
  left: 4vw;
  z-index: 9;
  display: block;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--ink);
  color: var(--ink);
  opacity: 0;
  transform: translate3d(0, 18px, 0);
  text-decoration: none;
  pointer-events: none;
  will-change: transform, opacity;
}

.gpx-download strong {
  font-family: var(--serif);
  font-size: clamp(1.65rem, 2.4vw, 2.7rem);
  font-weight: 400;
}

.scroll-progress {
  position: absolute;
  top: 82px;
  right: 14px;
  bottom: 82px;
  z-index: 9;
  width: 1px;
  background: rgba(23, 29, 24, 0.16);
}

.scroll-progress span {
  display: block;
  width: 1px;
  height: 0;
  background: var(--ink);
}

.collage-section {
  position: relative;
  isolation: isolate;
  min-height: 1900px;
  overflow: hidden;
  border-top: 1px solid var(--hairline);
  background: var(--gold);
}

.collage-canvas {
  position: relative;
  width: min(100%, 1600px);
  margin: 0 auto;
}

.story-copy-fallback,
.story-copy-flow {
  font-family: var(--serif);
  font-size: clamp(2.35rem, 3.9vw, 4.2rem);
  font-weight: 400;
  line-height: 1.01;
  letter-spacing: -0.045em;
}

.story-copy-fallback {
  position: relative;
  z-index: 8;
  max-width: 72%;
  margin: 0;
  padding: 0 3vw;
}

.story-copy-fallback a,
.story-copy-flow a {
  color: inherit;
  text-decoration-color: var(--rust);
  text-decoration-thickness: 0.07em;
  text-underline-offset: 0.11em;
}

.story-copy-flow {
  position: absolute;
  inset: 0;
  z-index: 8;
  pointer-events: none;
}

.story-flow-line {
  position: absolute;
  white-space: nowrap;
}

.story-flow-line a {
  pointer-events: auto;
}

.rsvp-open {
  position: absolute;
  z-index: 11;
  display: grid;
  width: 96px;
  height: 96px;
  padding: 0;
  border: 1px solid var(--ink);
  border-radius: 0;
  color: var(--paper);
  background: var(--ink);
  box-shadow: 5px 5px 0 var(--blue);
  font-family: var(--western);
  font-size: 1.12rem;
  font-weight: 900;
  letter-spacing: 0.015em;
  line-height: 0.9;
  place-items: center;
  text-transform: uppercase;
  cursor: pointer;
  transition: color 180ms ease, background 180ms ease, box-shadow 180ms ease, transform 180ms ease;
}

.rsvp-open:hover,
.rsvp-open:focus-visible {
  color: var(--ink);
  background: var(--paper);
  box-shadow: 7px 7px 0 var(--blue);
  transform: translate(-2px, -2px);
}

.rsvp-open:focus-visible {
  outline: 3px solid var(--rust);
  outline-offset: 3px;
}

.collage-quote {
  position: absolute;
  margin: 0;
  color: var(--ink);
}

.collage-quote blockquote {
  margin: 0;
  font-family: var(--serif);
  font-size: clamp(1.65rem, 2.8vw, 3rem);
  font-weight: 400;
  line-height: 1.02;
  letter-spacing: -0.035em;
}

.collage-quote figcaption {
  margin-top: 12px;
  padding-top: 8px;
  border-top: 1px solid var(--hairline);
  font-family: var(--mono);
  font-size: clamp(0.52rem, 0.7vw, 0.68rem);
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.collage-quote cite {
  font-style: normal;
}

.artwork {
  position: absolute;
  display: block;
  overflow: hidden;
  padding: 0;
  border: clamp(4px, 0.55vw, 9px) solid var(--paper);
  background: var(--pine);
  box-shadow: 0 16px 40px rgba(23, 29, 24, 0.2);
  cursor: zoom-in;
  transition: transform 500ms cubic-bezier(0.2, 0.72, 0.1, 1), box-shadow 300ms ease;
}

.artwork img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(0.9) sepia(0.03);
  transition: transform 700ms cubic-bezier(0.2, 0.72, 0.1, 1), filter 400ms ease;
}

.artwork:hover,
.artwork:focus-visible {
  z-index: 12;
  box-shadow: 0 24px 54px rgba(23, 29, 24, 0.3);
}

.artwork:hover img,
.artwork:focus-visible img {
  transform: scale(1.025);
  filter: saturate(1) sepia(0);
}

.artwork:focus-visible {
  outline: 3px solid var(--ink);
  outline-offset: 3px;
}

.lightbox {
  width: 100vw;
  max-width: none;
  height: 100svh;
  max-height: none;
  margin: 0;
  padding: clamp(22px, 3vw, 48px);
  border: 0;
  color: var(--paper);
  background: rgba(23, 29, 24, 0.98);
  overflow: hidden;
}

.lightbox::backdrop {
  background: rgba(23, 29, 24, 0.98);
}

.lightbox figure {
  display: grid;
  grid-template-rows: minmax(0, 1fr) auto;
  gap: 20px;
  width: 100%;
  height: 100%;
  margin: 0;
}

.lightbox-media {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: clamp(10px, 1.5vw, 24px);
  min-height: 0;
}

.lightbox[data-paired="true"] .lightbox-media {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.lightbox-panel {
  position: relative;
  display: grid;
  min-width: 0;
  min-height: 0;
  place-items: center;
}

.lightbox-panel img {
  display: block;
  width: 100%;
  height: 100%;
  min-height: 0;
  object-fit: contain;
}

.lightbox-panel-label {
  position: absolute;
  z-index: 1;
  top: 0;
  left: 0;
  padding: 7px 9px 6px;
  color: var(--paper);
  background: var(--pine);
  font-family: var(--mono);
  font-size: clamp(0.5rem, 0.65vw, 0.64rem);
  letter-spacing: 0.11em;
  text-transform: uppercase;
}

.lightbox figcaption {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 7px 24px;
  align-items: end;
  padding-right: 85px;
}

.lightbox h2 {
  margin: 0;
  font-family: var(--serif);
  font-size: clamp(1.5rem, 2.4vw, 2.8rem);
  font-weight: 400;
  line-height: 1;
  letter-spacing: -0.025em;
}

.lightbox p,
.lightbox a,
.lightbox-close {
  font-family: var(--mono);
  font-size: clamp(0.54rem, 0.7vw, 0.7rem);
  letter-spacing: 0.09em;
  text-transform: uppercase;
}

.lightbox p {
  grid-column: 1;
  margin: 0;
  color: rgba(241, 233, 215, 0.62);
}

.lightbox a {
  grid-column: 2;
  grid-row: 1 / span 2;
  color: var(--paper);
  text-decoration-color: rgba(241, 233, 215, 0.4);
  text-underline-offset: 5px;
}

.lightbox-close {
  position: fixed;
  top: 25px;
  right: 28px;
  z-index: 2;
  min-width: 52px;
  padding: 10px 0;
  border: 0;
  border-bottom: 1px solid rgba(241, 233, 215, 0.5);
  color: var(--paper);
  background: transparent;
  cursor: pointer;
}

body:has(.lightbox[open]) {
  overflow: hidden;
}

.rsvp-dialog {
  width: min(92vw, 560px);
  max-height: min(90svh, 760px);
  padding: 0;
  overflow: auto;
  border: 1px solid var(--ink);
  color: var(--ink);
  background: var(--paper);
  box-shadow: 0 28px 90px rgba(23, 29, 24, 0.38);
}

.rsvp-dialog::backdrop {
  background: rgba(23, 29, 24, 0.72);
  backdrop-filter: blur(4px);
}

.rsvp-dialog-shell {
  position: relative;
  padding: clamp(35px, 6vw, 60px);
}

.rsvp-close {
  position: absolute;
  top: 16px;
  right: 18px;
  padding: 5px 0;
  border: 0;
  border-bottom: 1px solid currentColor;
  color: var(--ink);
  background: transparent;
  font-family: var(--mono);
  font-size: 0.55rem;
  letter-spacing: 0.11em;
  text-transform: uppercase;
  cursor: pointer;
}

.rsvp-kicker {
  margin: 0 0 18px;
  font-family: var(--mono);
  font-size: 0.6rem;
  letter-spacing: 0.13em;
  text-transform: uppercase;
}

.rsvp-dialog h2 {
  margin: 0;
  font-family: var(--serif);
  font-size: clamp(2.6rem, 8vw, 4.4rem);
  font-weight: 400;
  line-height: 0.9;
  letter-spacing: -0.055em;
}

.rsvp-lede {
  max-width: 39ch;
  margin: 20px 0 28px;
  font-family: var(--serif);
  font-size: 1.08rem;
  line-height: 1.35;
}

.rsvp-form {
  display: grid;
  gap: 18px;
}

.rsvp-field {
  display: grid;
  gap: 7px;
  font-family: var(--mono);
  font-size: 0.58rem;
  letter-spacing: 0.11em;
  text-transform: uppercase;
}

.rsvp-field input {
  width: 100%;
  padding: 12px 0 10px;
  border: 0;
  border-bottom: 1px solid var(--ink);
  border-radius: 0;
  color: var(--ink);
  background: transparent;
  font-family: var(--serif);
  font-size: 1.28rem;
  letter-spacing: 0;
  outline: none;
}

.rsvp-field input:focus {
  border-bottom-color: var(--rust);
  box-shadow: 0 2px 0 var(--rust);
}

.rsvp-code-input {
  text-transform: uppercase;
}

.rsvp-submit {
  justify-self: start;
  min-width: 150px;
  margin-top: 4px;
  padding: 13px 20px 12px;
  border: 1px solid var(--ink);
  border-radius: 999px;
  color: var(--paper);
  background: var(--ink);
  font-family: var(--mono);
  font-size: 0.62rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  cursor: pointer;
}

.rsvp-submit:disabled {
  cursor: wait;
  opacity: 0.56;
}

.rsvp-error {
  min-height: 1.25em;
  margin: -5px 0 0;
  color: var(--rust);
  font-family: var(--sans);
  font-size: 0.82rem;
}

.rsvp-privacy {
  margin: 0;
  color: var(--muted);
  font-family: var(--sans);
  font-size: 0.78rem;
  line-height: 1.4;
}

.rsvp-success-mark {
  display: grid;
  width: 52px;
  height: 52px;
  margin-bottom: 24px;
  border: 1px solid var(--ink);
  border-radius: 50%;
  place-items: center;
  font-family: var(--serif);
  font-size: 1.8rem;
}

body:has(.rsvp-dialog[open]) {
  overflow: hidden;
}

@media (max-width: 760px) {
  .route-scroll {
    height: 315svh;
  }

  .hero-copy {
    top: 9vh;
    bottom: auto;
    left: 18px;
    width: calc(100% - 36px);
  }

  .hero-logo {
    width: min(86vw, 440px);
    margin: 0 0 -4%;
  }

  .hero-copy p {
    max-width: 325px;
    margin: 54px 0 0 4px;
    font-size: clamp(1.45rem, 7vw, 2rem);
  }

  .hero-date {
    right: 20px;
    bottom: 72px;
    left: 20px;
    width: auto;
    padding-top: 11px;
  }

  .hero-date-year {
    font-size: 0.58rem;
  }

  .hero-date-main {
    font-size: clamp(3rem, 13vw, 3.6rem);
  }

  .route-map {
    top: 8vh;
    right: -26vw;
    width: 128vw;
    transform: translate3d(22vw, 18vh, 0) scale(1.55) rotate(9deg);
  }

  .place-label text {
    font-size: 25px;
    stroke-width: 10px;
  }

  .place-label-landmark text {
    font-size: 20px;
  }

  .scroll-cue {
    right: 18px;
    bottom: 17px;
  }

  .elevation-panel {
    right: 18px;
    bottom: 94px;
    left: 18px;
    padding-top: 12px;
  }

  .elevation-heading {
    gap: 10px;
    align-items: baseline;
    margin-bottom: 16px;
  }

  .elevation-heading p {
    max-width: none;
    font-size: 0.9rem;
    text-align: right;
    line-height: 1;
    white-space: nowrap;
  }

  .elevation-days {
    gap: 10px;
  }

  .elevation-days span {
    gap: 5px;
    font-size: 0.62rem;
  }

  .elevation-days span::before {
    width: 14px;
  }

  #elevation-profile {
    height: 150px;
  }

  .elevation-label {
    font-size: 21px;
  }

  .gpx-download {
    right: auto;
    bottom: 22px;
    left: 18px;
  }

  .scroll-progress {
    right: 6px;
  }

  .collage-section {
    min-height: 0;
  }

  .story-copy-fallback,
  .story-copy-flow {
    font-size: clamp(1.5rem, 6.6vw, 1.9rem);
    line-height: 1.05;
    letter-spacing: -0.035em;
  }

  .story-copy-fallback {
    max-width: 94%;
    padding: 0 18px;
  }

  .rsvp-open {
    width: 82px;
    height: 82px;
    font-size: 0.98rem;
    box-shadow: 4px 4px 0 var(--blue);
  }

  .collage-quote blockquote {
    font-size: clamp(1.3rem, 7.2vw, 1.85rem);
    line-height: 1.04;
  }

  .collage-quote figcaption {
    margin-top: 9px;
    padding-top: 6px;
    font-size: 0.53rem;
  }

  .artwork {
    border-width: 5px;
  }

  .lightbox {
    padding: 58px 14px 18px;
  }

  .lightbox figure {
    gap: 14px;
  }

  .lightbox-media {
    gap: 8px;
  }

  .lightbox-panel-label {
    padding: 5px 6px 4px;
    font-size: 0.46rem;
  }

  .lightbox figcaption {
    display: block;
    padding: 0 3px;
  }

  .lightbox h2 {
    font-size: 1.7rem;
  }

  .lightbox p {
    margin: 9px 0 14px;
    line-height: 1.45;
  }

  .lightbox a {
    display: inline-block;
  }

  .lightbox-close {
    top: 14px;
    right: 17px;
  }

  .rsvp-dialog-shell {
    padding: 48px 24px 34px;
  }

  .rsvp-dialog h2 {
    font-size: clamp(2.7rem, 15vw, 3.8rem);
  }
}

@media (prefers-reduced-motion: reduce) {
  .route-scroll {
    height: auto;
  }

  .route-sticky {
    position: relative;
    min-height: 1180px;
  }

  .hero-copy {
    opacity: 1 !important;
    transform: none !important;
  }

  .hero-date {
    opacity: 1 !important;
    transform: none !important;
  }

  .route-map {
    transform: translate3d(-3vw, -9vh, 0) scale(0.78) !important;
  }

  .topo-map,
  .route-labels,
  .elevation-panel,
  .gpx-download {
    opacity: 1 !important;
    transform: none !important;
  }

  .gpx-download,
  .elevation-panel {
    pointer-events: auto !important;
  }

  .scroll-cue,
  .scroll-progress {
    display: none;
  }

  .artwork,
  .artwork img {
    transition: none;
  }
}
