/* "Plan your visit" page (plan.html). Palette and typography come from base.css, the wave shape from the home page. */
body { color: var(--fg); min-height: 100svh; }
.plan-page img { display: block; }

/* rising water between sections (same as the home page) */
.rise { position: relative; z-index: 3; height: var(--rise-h); margin-top: calc(-1 * var(--rise-h)); pointer-events: none; }
.rise svg { display: block; width: 100%; height: 100%; }
.rise path { fill: var(--next); }
.to-paper { --next: var(--paper); }
.to-deep { --next: var(--deep); }
html.lenis, html.lenis body { height: auto; }
.lenis.lenis-smooth { scroll-behavior: auto !important; }

/* ---------- hero ---------- */
.plan-hero { position: relative; height: 100svh; min-height: 560px; overflow: hidden; display: flex; align-items: flex-end; background: var(--deep); }
.plan-hero-media { position: absolute; inset: 0; transform-origin: 50% 60%; }
.plan-hero-media img { width: 100%; height: 118%; margin-top: -9%; object-fit: cover; object-position: var(--pos-m, 50% 50%); }
@media (min-width: 769px) { .plan-hero-media img { object-position: var(--pos, 50% 50%); } }
/* dark at the bottom so the title reads, a little at the top for the menu */
.plan-hero::after {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(180deg, rgba(21, 26, 24, .55) 0%, rgba(21, 26, 24, 0) 22%, rgba(21, 26, 24, 0) 45%, rgba(21, 26, 24, .78) 82%, var(--deep) 100%);
}
.plan-hero-text { position: relative; z-index: 1; padding: 0 var(--gutter) calc(var(--rise-h) * .7 + 24px); max-width: 1100px; }
.plan-hero .eyebrow { color: var(--sand); }
.plan-title { font-family: var(--serif); font-weight: 400; line-height: .95; letter-spacing: -.015em; font-size: clamp(3.2rem, 11vw, 9.5rem); }
.pt-mask { display: block; overflow: hidden; padding-bottom: .12em; margin-bottom: -.12em; }
.pt-line { display: block; }
.plan-lead { max-width: 40ch; margin-top: 1.4rem; font-size: clamp(1rem, 1.4vw, 1.2rem); color: rgba(246, 244, 238, .82); }
.plan-scroll {
  position: absolute; z-index: 1; right: var(--gutter); bottom: calc(var(--rise-h) * .7 + 28px);
  writing-mode: vertical-rl; font-size: .68rem; letter-spacing: .2em; text-transform: uppercase; color: rgba(246, 244, 238, .7);
}
.plan-scroll::after { content: ""; display: block; width: 1px; height: 54px; margin: 14px auto 0; background: linear-gradient(var(--sand), transparent); animation: drip 2.2s ease-in-out infinite; transform-origin: top; }
@keyframes drip { 0% { transform: scaleY(0); } 50% { transform: scaleY(1); } 100% { transform: scaleY(1); opacity: 0; } }
@media (max-width: 599px) { .plan-scroll { display: none; } }

/* ---------- sections ---------- */
.plan-sec { position: relative; padding: clamp(56px, 10svh, 120px) var(--gutter); }
.plan-sec + .plan-sec { padding-top: 0; }
.sec-head { margin-bottom: clamp(36px, 7svh, 80px); }
.sec-head h2 { font-size: clamp(2.6rem, 7vw, 6rem); }
.plan-small { margin-top: 2rem; font-size: .88rem; color: var(--fg-muted); }
.plan-page ul, .plan-page ol { list-style: none; }

/* ---------- distances: a road from town ---------- */
.journey { position: relative; }
.j-line { position: absolute; z-index: 0; background: var(--acc); transform-origin: 0 0; pointer-events: none; }
.j-dot {
  position: relative; z-index: 1; display: block; flex: none; width: 15px; height: 15px; border-radius: 50%;
  background: var(--sec-bg); border: 1px solid var(--acc); transition: background .4s ease, transform .4s ease;
}
.on > .j-dot, .on .j-dot { background: var(--acc); transform: scale(1.15); }
.j-start { display: grid; grid-template-columns: 15px 1fr; column-gap: 18px; align-items: center; padding-bottom: 28px; }
.j-start .j-km { grid-column: 2; font-size: .72rem; letter-spacing: .2em; text-transform: uppercase; color: var(--acc); }
.j-start .j-town { grid-column: 2; font-family: var(--serif); font-size: 1.6rem; line-height: 1.1; }
.j-start .j-dot { grid-row: span 2; }
.j-stops { display: grid; gap: 22px; }
.j-card {
  display: grid; grid-template-columns: 15px 92px minmax(0, 1fr); column-gap: 18px; align-items: center;
  color: inherit; text-decoration: none;
}
.j-card .j-dot { grid-row: 1 / span 2; }
.j-card .j-km { grid-column: 2 / 4; grid-row: 1; font-family: var(--serif); font-size: 1rem; color: var(--acc); line-height: 1; margin-bottom: 8px; padding-left: calc(92px + 18px); }
.j-n { font-size: 2.4rem; color: var(--fg); margin-right: .1em; }
.j-photo { grid-column: 2; grid-row: 2; display: block; aspect-ratio: 1; overflow: hidden; background: #232a27; }
.j-photo img { width: 100%; height: 100%; object-fit: cover; transition: transform .8s cubic-bezier(.2, .7, .2, 1); }
.j-txt { grid-column: 3; grid-row: 2; }
.j-name { display: block; font-family: var(--serif); font-size: 1.4rem; line-height: 1.15; transition: color .2s ease; }
.j-short { display: block; margin-top: .3rem; font-size: .86rem; line-height: 1.45; color: var(--fg-muted); }
.j-card:hover .j-name { color: var(--acc); }
.j-card:hover .j-photo img { transform: scale(1.07); }
/* while the road draws, a stop waits faded until the line reaches it */
.js-anim .j-line { transform: scale(0); }
.js-anim .j-start > :not(.j-dot), .js-anim .j-card > :not(.j-dot) { opacity: .15; transform: translateY(14px); transition: opacity .7s ease, transform .7s cubic-bezier(.2, .7, .2, 1); }
.js-anim .on > :not(.j-dot), .js-anim .on .j-card > :not(.j-dot) { opacity: 1; transform: none; }

@media (min-width: 900px) {
  /* the road runs across: town on the left, a column per stop */
  .journey { display: grid; grid-template-columns: minmax(0, .8fr) minmax(0, 5fr); column-gap: 24px; }
  .j-start { display: flex; flex-direction: column; align-items: flex-start; gap: 0; padding: 0; }
  .j-start .j-dot { margin-bottom: 26px; }
  .j-start .j-town { font-size: 1.9rem; margin-top: .4rem; }
  .j-stops { grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 24px; }
  .j-card { display: flex; flex-direction: column; align-items: flex-start; }
  .j-card .j-dot { margin-bottom: 26px; }
  .j-card .j-km { padding-left: 0; margin-bottom: 14px; }
  .j-n { font-size: 3.4rem; }
  .j-photo { width: 100%; aspect-ratio: 3 / 4; margin-bottom: 16px; }
}

/* ---------- before you go ---------- */
.tips { display: grid; gap: clamp(28px, 4vw, 40px); }
.tip { display: grid; gap: 18px; }
.tip-photo { display: block; aspect-ratio: 16 / 10; overflow: hidden; background: #232a27; }
.tip-photo img { width: 100%; height: 100%; object-fit: cover; transition: transform .9s cubic-bezier(.2, .7, .2, 1); }
.tip:hover .tip-photo img { transform: scale(1.05); }
.tip-num { display: block; font-size: .72rem; letter-spacing: .2em; color: var(--acc); margin-bottom: .2rem; }
.tip-name { display: inline-flex; align-items: center; min-height: 44px; font-family: var(--serif); font-size: clamp(1.6rem, 2.4vw, 2rem); line-height: 1.1; color: inherit; text-decoration: none; }
.tip-name:hover { color: var(--acc); }
.tip-text { margin-top: .3rem; padding-left: 1rem; border-left: 1px solid var(--acc); font-size: .95rem; color: var(--fg-soft); }
@media (min-width: 700px) { .tips { grid-template-columns: 1fr 1fr; } }
@media (min-width: 1200px) {
  .tips { grid-template-columns: repeat(4, minmax(0, 1fr)); align-items: start; }
  .tip-photo { aspect-ratio: 3 / 4; }
  .tip:nth-child(even) { margin-top: 64px; }
}

/* ---------- when ---------- */
#sec-when { padding-top: clamp(70px, 12svh, 130px); padding-bottom: clamp(70px, 12svh, 130px); }
/* the year on one line (plan.js: buildYear): months, bands for seasons, dots for days, and today */
.year { margin-top: clamp(10px, 2svh, 24px); }
.yr-months { list-style: none; display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); }
.yr-months li { padding: 0 0 10px 8px; border-left: 1px solid var(--rule); font-size: .7rem; letter-spacing: .16em; text-transform: uppercase; color: var(--fg-muted); }
.yr-months li.now { color: var(--acc); font-weight: 500; }
.yr-line { position: relative; height: 34px; border-radius: 999px; background: rgba(21, 26, 24, .06); }
.yr-band, .yr-dot { position: absolute; top: 5px; height: 24px; display: grid; place-items: center; font-style: normal; }
.yr-band { border-radius: 999px; background: linear-gradient(90deg, rgba(23, 149, 160, .22), rgba(23, 149, 160, .38)); box-shadow: inset 0 0 0 1px rgba(23, 149, 160, .35); }
.yr-dot { width: 24px; margin-left: -12px; border-radius: 50%; background: var(--sand-dark); box-shadow: 0 0 0 5px rgba(15, 122, 133, .16); }
.yr-band b, .yr-dot b { font-size: .68rem; font-weight: 500; font-variant-numeric: lining-nums; color: var(--ink); }
.yr-dot b { color: var(--paper); }
.yr-today { position: absolute; top: -6px; bottom: -6px; width: 2px; margin-left: -1px; border-radius: 2px; background: var(--ink); opacity: .55; }
.yr-list { list-style: none; display: grid; gap: 22px; margin-top: 36px; }
.yr-list li { display: grid; grid-template-columns: 30px minmax(0, 1fr); gap: 14px; align-items: start; align-content: start; }
.yr-photo { grid-column: 1 / -1; display: block; aspect-ratio: 4 / 3; overflow: hidden; border-radius: 14px; background: #232a27; }
a.yr-photo > * { width: 100%; height: 100%; }
.yr-photo img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform 1.2s cubic-bezier(.2, .7, .2, 1); }
a.yr-photo:hover img { transform: scale(1.05); }
div.yr-photo:not(.has-img) { display: grid; place-items: center; background: var(--deep); color: var(--paper); }
div.yr-photo.has-img img { filter: sepia(.15) contrast(1.03); }
div.yr-photo b { font-family: var(--serif); font-weight: 500; font-size: clamp(4.5rem, 7vw, 6.5rem); line-height: 1; font-variant-numeric: lining-nums; }
div.yr-photo small { margin-left: .1em; font-size: .45em; color: var(--river-light); }
.yr-n { display: grid; place-items: center; width: 28px; height: 28px; border-radius: 50%; border: 1px solid var(--acc); color: var(--acc); font-size: .74rem; font-variant-numeric: lining-nums; }
.yr-when { font-size: .7rem; letter-spacing: .2em; text-transform: uppercase; color: var(--acc); }
.yr-what { margin-top: .3rem; font-family: var(--serif); font-size: clamp(1.25rem, 1.7vw, 1.5rem); line-height: 1.25; max-width: 30ch; }
.yr-place { display: inline-flex; align-items: center; min-height: 40px; font-size: .78rem; color: var(--fg-soft); text-decoration: underline; text-underline-offset: 3px; text-decoration-color: var(--rule); }
.yr-place:hover { color: var(--acc); }
@media (min-width: 900px) { .yr-list { grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 24px; } }
@media (max-width: 599px) {
  .yr-photo { aspect-ratio: 16 / 9; }
  .yr-months li { padding-left: 3px; font-size: .56rem; letter-spacing: .04em; }
  .yr-list { grid-template-columns: 1fr; }
}

/* ---------- getting here ---------- */
.get-grid { display: grid; gap: clamp(32px, 5vw, 80px); }
.get-dist { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.get-dist li { display: flex; flex-direction: column; padding: 18px 16px 16px; border-radius: 16px; background: var(--mist); }
.get-t { font-family: var(--serif); font-weight: 500; font-size: clamp(2rem, 3.6vw, 3.4rem); line-height: 1; font-variant-numeric: lining-nums; white-space: nowrap; }
.get-city { margin-top: .7rem; font-family: var(--serif); font-size: 1.3rem; line-height: 1.1; }
.get-km { margin-top: .2rem; font-size: .78rem; color: var(--fg-muted); }
.get-notes { display: grid; gap: 0; border-top: 1px solid var(--rule); }
.get-notes div { display: grid; grid-template-columns: 110px minmax(0, 1fr); gap: 16px; padding: 16px 0; border-bottom: 1px solid var(--rule); }
.get-notes dt { padding-top: .2em; font-size: .7rem; letter-spacing: .2em; text-transform: uppercase; color: var(--acc); }
.get-notes dd { color: var(--fg-soft); }
@media (min-width: 900px) { .get-grid { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); align-items: start; } }
@media (max-width: 599px) {
  .get-dist { grid-template-columns: 1fr; }
  .get-dist li { display: grid; grid-template-columns: auto 1fr; column-gap: 16px; align-items: baseline; padding: 14px 16px; }
  .get-t { grid-row: span 2; font-size: 2rem; }
  .get-city { margin-top: 0; }
  .get-notes div { grid-template-columns: 1fr; gap: 4px; }
}

/* ---------- summer ---------- */
#sec-summer { padding-top: clamp(40px, 8svh, 90px); padding-bottom: clamp(90px, 16svh, 180px); }
.sum-grid { display: grid; gap: clamp(40px, 6vw, 90px); align-items: center; }
.sum-text h2 { font-size: clamp(2.6rem, 7vw, 6rem); }
.sum-lead { margin-top: 1.4rem; max-width: 38ch; font-family: var(--serif); font-size: clamp(1.35rem, 2vw, 1.8rem); line-height: 1.3; color: var(--fg); }
.sum-list { display: grid; gap: 0; margin-top: clamp(28px, 5svh, 48px); border-top: 1px solid var(--rule); }
.sum-list li { padding: 18px 0; border-bottom: 1px solid var(--rule); }
.sum-list h3 { font-family: var(--serif); font-weight: 500; font-size: 1.4rem; line-height: 1.15; color: var(--fg); }
.sum-list p { margin-top: .4rem; max-width: 58ch; color: var(--fg-soft); }
.sum-pics { position: relative; min-height: 420px; }
.sum-pic { position: absolute; margin: 0; }
.sum-pic img { display: block; width: 100%; height: auto; border: 7px solid #efe9db; box-shadow: 0 24px 50px -18px rgba(0, 0, 0, .7); filter: grayscale(.1) contrast(1.03); }
.sum-pic figcaption { margin-top: .5rem; font-size: .74rem; color: var(--fg-muted); }
.sum-pic.a { left: 4%; top: 0; width: 46%; transform: rotate(-3deg); z-index: 2; }
.sum-pic.b { right: 0; top: 22%; width: 60%; transform: rotate(2.5deg); }
@media (min-width: 900px) { .sum-grid { grid-template-columns: minmax(0, 1.05fr) minmax(0, .95fr); } .sum-pics { min-height: 600px; } }
@media (max-width: 599px) { .sum-pics { min-height: 340px; } }

.summer-album { min-height: 0; display: grid; grid-template-columns: 1fr 1.25fr; align-items: end; gap: 22px 14px; }
.summer-album figure { position: static; width: auto; margin: 0; transform: none; min-width: 0; }
.summer-album img { display: block; max-width: 100%; height: auto; border: 0; }
.summer-album figcaption { margin-top: .5rem; font-size: .78rem; line-height: 1.45; color: var(--fg-muted); }
.summer-album .evening-walk { grid-row: span 2; align-self: center; }
.summer-album .sum-pic.a { max-width: 11rem; }
.summer-album .summer-dives { grid-column: 2; }
.summer-album .sum-pic.b { grid-column: 1 / -1; width: 70%; justify-self: end; }

/* ---------- where to stay ---------- */
.stay-grid { display: grid; gap: clamp(36px, 5vw, 80px); }
.stay-nums { display: grid; gap: 0; border-top: 1px solid var(--rule); align-self: start; }
.stay-nums li { display: flex; align-items: baseline; gap: 18px; padding: 16px 0; border-bottom: 1px solid var(--rule); }
.stay-nums b { min-width: 2.4em; font-family: var(--serif); font-weight: 500; font-size: clamp(2.6rem, 5vw, 4.4rem); line-height: 1; font-variant-numeric: lining-nums; }
.stay-nums span { color: var(--fg-soft); }
.stay-lead { font-family: var(--serif); font-size: clamp(1.35rem, 2vw, 1.8rem); line-height: 1.3; max-width: 34ch; }
.stay-tip { margin-top: 1rem; padding-left: 1rem; border-left: 2px solid var(--acc); color: var(--fg-soft); max-width: 50ch; }
.stay-spa { margin-top: clamp(24px, 4svh, 40px); padding: 22px 24px; border-radius: 16px; background: var(--deep); color: var(--paper); }
.stay-spa-k { font-size: .7rem; letter-spacing: .2em; text-transform: uppercase; color: var(--river-light); }
.stay-spa h3 { margin-top: .3rem; font-family: var(--serif); font-weight: 500; font-size: 1.8rem; line-height: 1.1; }
.stay-spa p:last-child { margin-top: .5rem; color: rgba(246, 244, 238, .82); max-width: 52ch; }
.stay-links { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 24px; margin-top: 24px; }
.cta-line {
  display: inline-flex; align-items: center; gap: .6rem; min-height: 48px; padding: 0 1.3rem; border: 1px solid var(--acc); border-radius: 999px;
  color: var(--fg); text-decoration: none; font-size: .76rem; letter-spacing: .2em; text-transform: uppercase; transition: background .2s ease, color .2s ease;
}
.cta-line:hover { background: var(--acc); color: var(--paper); }
.stay-tz { font-size: .86rem; color: var(--fg-muted); }
.stay-tz a { color: inherit; }
@media (min-width: 900px) { .stay-grid { grid-template-columns: minmax(0, .8fr) minmax(0, 1.2fr); } }

/* ---------- routes ---------- */
#sec-routes { padding-top: clamp(40px, 8svh, 90px); }
.rcards { display: grid; gap: clamp(48px, 7svh, 72px) clamp(32px, 4vw, 64px); }
.rcard { display: grid; gap: 26px; }
.rc-fan { position: relative; display: block; aspect-ratio: 16 / 10; max-height: 360px; }
.rc-photo {
  position: absolute; top: 50%; left: 50%; height: 84%; aspect-ratio: 3 / 4; overflow: hidden; background: #232a27;
  box-shadow: 0 14px 34px rgba(21, 26, 24, .22);
  transform: translate(-50%, -50%); transition: transform .9s cubic-bezier(.2, .7, .2, 1);
}
.rc-photo img { width: 100%; height: 100%; object-fit: cover; }
/* open: the photos fan out; without animation they are open from the start */
.rcard .rc-photo:nth-child(1), .js-anim .rcard.open .rc-photo:nth-child(1) { transform: translate(-112%, -50%) rotate(-7deg); z-index: 1; }
.rcard .rc-photo:nth-child(2), .js-anim .rcard.open .rc-photo:nth-child(2) { transform: translate(-50%, -54%) rotate(1deg); z-index: 3; }
.rcard .rc-photo:nth-child(3), .js-anim .rcard.open .rc-photo:nth-child(3) { transform: translate(12%, -48%) rotate(6deg); z-index: 2; }
.rc-fan .rc-photo:only-child { transform: translate(-50%, -50%) rotate(-2deg); }
.rc-fan .rc-photo:first-child:nth-last-child(2), .js-anim .rcard.open .rc-photo:first-child:nth-last-child(2) { transform: translate(-90%, -50%) rotate(-5deg); }
.rc-fan .rc-photo:last-child:nth-child(2), .js-anim .rcard.open .rc-photo:last-child:nth-child(2) { transform: translate(-10%, -52%) rotate(4deg); }
.js-anim .rcard:not(.open) .rc-photo { transform: translate(-50%, -50%) rotate(0deg); }
.rcard:hover .rc-photo:nth-child(1) { transform: translate(-122%, -52%) rotate(-10deg); }
.rcard:hover .rc-photo:nth-child(3) { transform: translate(22%, -46%) rotate(9deg); }
.rc-num { font-size: .72rem; letter-spacing: .2em; color: var(--acc); margin-bottom: .6rem; }
.rc-name { font-family: var(--serif); font-weight: 400; font-size: clamp(2rem, 3.4vw, 2.8rem); line-height: 1.05; }
.rc-text { max-width: 38ch; margin-top: .6rem; color: var(--fg-muted); }
.rc-stops { margin-top: 1.1rem; counter-reset: stop; border-top: 1px solid var(--rule); }
.rc-stops li { counter-increment: stop; display: flex; flex-wrap: wrap; align-items: center; gap: 0 .9rem; border-bottom: 1px solid var(--rule); }
.rc-stops li::before { content: counter(stop, decimal-leading-zero); width: 1.6rem; font-size: .72rem; letter-spacing: .1em; color: var(--acc); }
.rc-stops a { display: inline-flex; align-items: center; min-height: 48px; font-family: var(--serif); font-size: 1.25rem; color: inherit; text-decoration: none; }
.rc-stops a:hover { color: var(--acc); }
.rc-km { margin-left: auto; font-size: .8rem; color: var(--fg-muted); }
.rc-extra { max-width: 40ch; margin-top: 1rem; padding-left: 1rem; border-left: 1px solid var(--acc); font-size: .9rem; color: var(--fg-muted); }
.rc-map {
  display: inline-flex; align-items: center; min-height: 44px; margin-top: 1.2rem; padding: 0 1.3rem; border-radius: 999px;
  border: 1px solid var(--acc); color: var(--acc); font-size: .72rem; letter-spacing: .2em; text-transform: uppercase; text-decoration: none;
  transition: background .25s ease, color .25s ease;
}
.rc-map::after { content: "\2192"; margin-left: .6rem; letter-spacing: 0; }
.rc-map:hover { background: var(--acc); color: var(--paper); }
.plan-check { margin-top: clamp(48px, 8svh, 90px); padding-bottom: var(--rise-h); font-family: var(--serif); font-size: clamp(1.3rem, 2.2vw, 1.8rem); color: var(--fg-soft); }
@media (min-width: 900px) { .rcards { grid-template-columns: 1fr 1fr; } }

/* ---------- closing ---------- */
.plan-cta { padding: clamp(40px, 8svh, 90px) var(--gutter) clamp(90px, 16svh, 180px); text-align: center; }
.plan-cta h2 { font-size: clamp(2.4rem, 6vw, 5.4rem); max-width: 14ch; margin: 0 auto; }
.cta-btn {
  display: inline-flex; align-items: center; min-height: 52px; margin-top: 2.4rem; padding: 0 2rem; border-radius: 999px;
  background: var(--paper); color: var(--ink); font-size: .78rem; letter-spacing: .2em; text-transform: uppercase; text-decoration: none;
  transition: background .25s ease, transform .25s ease;
}
.cta-btn::after { content: "\2192"; margin-left: .7rem; letter-spacing: 0; }
.cta-btn:hover { background: var(--sand); transform: translateY(-2px); }

@supports not (view-transition-name: none) { body { animation: pagein .5s ease; } }
@keyframes pagein { from { opacity: 0; } to { opacity: 1; } }
@media (prefers-reduced-motion: reduce) {
  body { animation: none !important; }
  .plan-scroll::after { animation: none; }
  .j-dot, .j-photo img, .tip-photo img, .rc-photo, .cta-btn { transition: none; }
}

/* the wave into the dark section rises over the bottom of the tips: keep the text clear of it */
#sec-before { padding-bottom: calc(var(--rise-h) + clamp(40px, 8svh, 90px)); }
