/* Himachal logbook — dusk over the Dhauladhar: indigo sky, saffron sun, prayer-flag colours. */
:root {
  --bg: #f4faff;
  --paper: #ffffff;
  --ink: #1e2a55;
  --ink-soft: #4d5a86;
  --line: rgba(30, 42, 85, .12);
  --saffron: #f39a1e;
  --maroon: #c2394a;
  --teal: #1f8a90;
  --moss: #4a9a62;
  --night: #1e2a55;
  --dusk: #7a63b8;
  --link: #c2394a;
  --frost: #e4f3fd;
  --sun: #ffd24a;
  --ridge-mid: #cfc6f0;
  --ridge-low: #8d86d2;
  --tone-ok: #2f9a5e;
  --tone-warn: #e08a14;
  --tone-alert: #d6403a;
  --err: #c0392b;
  --display: "Yatra One", "Noto Serif Devanagari", Georgia, serif;
  --body: "Atkinson Hyperlegible Next", "Atkinson Hyperlegible", system-ui, -apple-system, "Segoe UI", sans-serif;
  --bar-h: 56px;
  --tabs-h: 0px;
  --r: 22px;
  color-scheme: light;
}


*, *::before, *::after { box-sizing: border-box; }
html { scroll-padding-top: calc(var(--bar-h) + 12px); -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 400 1.0625rem/1.6 var(--body); padding-bottom: env(safe-area-inset-bottom); }
body.lock { overflow: hidden; }
img { max-width: 100%; display: block; }
a { color: var(--link); text-underline-offset: .18em; }
:focus-visible { outline: 3px solid var(--saffron); outline-offset: 2px; border-radius: 4px; }
.skip { position: absolute; left: -999px; top: 8px; background: var(--paper); padding: .5rem 1rem; z-index: 100; border-radius: 8px; }
.skip:focus { left: 8px; }
.wrap { width: min(1120px, 100% - 2rem); margin-inline: auto; }
.wrap-narrow { max-width: 68ch; }

/* ---------- top bar ---------- */
.bar { position: fixed; inset: 0 0 auto 0; height: calc(var(--bar-h) + env(safe-area-inset-top)); padding: env(safe-area-inset-top) max(1rem, env(safe-area-inset-right)) 0 max(1rem, env(safe-area-inset-left)); display: flex; align-items: center; justify-content: space-between; z-index: 40; color: #fff; transition: background .25s, color .25s, box-shadow .25s; }
.bar.solid { background: color-mix(in srgb, var(--paper) 88%, transparent); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); color: var(--ink); box-shadow: 0 1px 0 var(--line); }
.brand { display: flex; align-items: center; gap: .55rem; font: 1.35rem/1 var(--display); color: inherit; text-decoration: none; letter-spacing: .01em; }
.bar-actions { display: flex; gap: .25rem; }
.icon-btn { display: inline-flex; align-items: center; gap: .4rem; min-height: 44px; min-width: 44px; justify-content: center; background: transparent; color: inherit; border: 0; border-radius: 999px; font: 600 .95rem var(--body); cursor: pointer; padding: 0 .7rem; }
.icon-btn:hover { background: rgba(127, 127, 160, .2); }
.icon-btn svg { width: 22px; height: 22px; }
.icon-btn.spin svg { animation: spin .8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

/* ---------- hero ---------- */
.hero { position: relative; min-height: min(92svh, 800px); overflow: hidden; color: #fff; isolation: isolate;
  background: linear-gradient(180deg, #3d8be0 0%, #74b8f0 30%, #b9e0f8 52%, #ffe3b3 76%, #ffc58f 100%); }
.scene, .scene > svg { position: absolute; inset: 0; width: 100%; height: 100%; }
.scene .layer { transform: translate3d(0, calc(var(--sy, 0) * var(--k) * 1px), 0); will-change: transform; }
.scene .sun { inset: auto; left: 68%; top: 12%; width: min(46vw, 420px); height: auto; aspect-ratio: 1; transform: translate(-50%, calc(var(--sy, 0) * -.05px)); }
.mandala { animation: turn 160s linear infinite; transform-origin: center; }
@keyframes turn { to { transform: rotate(360deg); } }
.flags { position: absolute; inset: 0 0 auto 0; height: 190px; pointer-events: none; z-index: 2; }
.flag { transform-box: fill-box; transform-origin: 0 0; animation: sway 5s ease-in-out infinite alternate; }
@keyframes sway { from { transform: skewY(-7deg) rotate(-3deg); } to { transform: skewY(6deg) rotate(4deg); } }
.hero-copy { position: relative; z-index: 3; width: min(1120px, 100% - 2rem); margin-inline: auto; padding: calc(var(--bar-h) + 130px) 0 120px; text-shadow: 0 2px 22px rgba(20, 50, 110, .45); }
.om { margin: 0 0 .25rem; font-size: 2rem; letter-spacing: .1em; color: #fff3c4; }
.title { margin: 0; font: clamp(4.2rem, 17vw, 10.5rem)/.9 var(--display); letter-spacing: -.01em; }
.deva { margin: .3rem 0 0; font: clamp(1.5rem, 4.5vw, 2.6rem)/1.2 var(--display); color: #fff3c4; }
.tag { margin: 1.2rem 0 0; max-width: 28ch; font-size: clamp(1.1rem, 2.4vw, 1.4rem); line-height: 1.35; color: #fff; font-weight: 600; }
.status { display: inline-flex; align-items: center; gap: .6rem; margin: 1.4rem 0 0; padding: .55rem 1.1rem; border-radius: 999px; background: rgba(255, 255, 255, .92); color: var(--ink); backdrop-filter: blur(6px); font-weight: 700; text-shadow: none; box-shadow: 0 8px 24px -10px rgba(20, 50, 110, .5); }
.dot { width: 10px; height: 10px; border-radius: 50%; background: var(--saffron); box-shadow: 0 0 0 4px rgba(233, 146, 43, .3); animation: pulse 2.4s ease-in-out infinite; }
@keyframes pulse { 50% { box-shadow: 0 0 0 9px rgba(233, 146, 43, 0); } }
.loading { font-size: 1.1rem; color: #fff; padding-top: 2rem; }
.loading.page-load { color: var(--ink-soft); padding: calc(var(--bar-h) + 4rem) 1rem; text-align: center; }
@media (max-width: 640px) {
  .scene .sun { left: 70%; top: 24%; width: 62vw; }
  .hero-copy { padding-top: calc(var(--bar-h) + 150px); }
}

/* ---------- home sections ---------- */
.home { padding-bottom: 3rem; }
.home > section { padding-top: 3.2rem; }
.sec { margin: 0; font: clamp(1.9rem, 4.5vw, 2.7rem)/1.1 var(--display); }
.sec-sub { margin: .4rem 0 1.4rem; color: var(--ink-soft); max-width: 60ch; }
.glance { margin-top: -2.5rem; position: relative; z-index: 4; padding-top: 0 !important; }
.glance dl { margin: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); background: var(--paper); border-radius: var(--r); overflow: hidden; box-shadow: 0 18px 50px -24px rgba(23, 27, 64, .45), inset 0 0 0 1px var(--line); }
.glance dl > div { padding: 1rem 1.2rem; box-shadow: 0 0 0 .5px var(--line); }
.glance dt { font-weight: 700; color: var(--maroon); font-size: .95rem; margin-bottom: .15rem; }
.glance dd { margin: 0; font-size: .98rem; line-height: 1.45; }

.route ol { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: .5rem .35rem; counter-reset: stop; }
.route li { counter-increment: stop; position: relative; padding: .35rem .85rem; border-radius: 999px; background: var(--paper); border: 1px solid var(--line); font-size: .95rem; }
.route li:not(:last-child)::after { content: "›"; position: absolute; right: -.62rem; top: 50%; transform: translateY(-52%); color: var(--saffron); font-weight: 700; background: var(--bg); line-height: 1; z-index: 1; }
.route li { margin-right: .5rem; }
.route li:last-child { margin-right: 0; }

/* ridge */
.ridge-scroll { overflow-x: auto; margin-inline: -1rem; padding-inline: 1rem; scrollbar-width: thin; }
.ridge { min-width: 680px; }
.ridge svg { display: block; width: 100%; height: auto; overflow: visible; }
.gridline { stroke: var(--line); stroke-dasharray: 2 7; stroke-linecap: round; }
.gridlbl { fill: var(--ink-soft); font: 600 11px var(--body); }
.ridge-line { stroke: var(--saffron); stroke-width: 3; stroke-linejoin: round; }
.ridge-fill { opacity: .95; }
.pole { stroke: var(--ink); stroke-width: 1.5; }
.pflag { transform-box: fill-box; transform-origin: 0 0; animation: sway 4.5s ease-in-out infinite alternate; }
.knot { fill: var(--paper); stroke: var(--maroon); stroke-width: 2.5; }
.alt { fill: var(--ink); font: 700 12.5px var(--body); }
.alt.top { fill: var(--maroon); font-size: 14px; }

.dn { fill: var(--ink); font: 700 12.5px var(--body); }
.pl { fill: var(--ink-soft); font: 400 11.5px var(--body); }
.peak { cursor: pointer; }
.peak:hover .knot, .peak:focus-visible .knot { fill: var(--saffron); }
.peak:focus-visible { outline: none; }
.peak:focus-visible .dn { text-decoration: underline; }


/* day cards — arched like a monastery window */
.days { list-style: none; margin: 1.4rem 0 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 1.6rem 1.2rem; }
.day { display: block; text-decoration: none; color: inherit; }
.arch { position: relative; display: block; aspect-ratio: 4 / 4.4; overflow: hidden; border-radius: 999px 999px 14px 14px; background: var(--frost); box-shadow: 0 0 0 3px var(--bg), 0 0 0 5px var(--saffron); }
.arch img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s cubic-bezier(.2, .7, .2, 1); }
.day:hover .arch img { transform: scale(1.06); }
.stamp { position: absolute; left: 50%; top: 14px; transform: translateX(-50%); min-width: 2.1rem; height: 2.1rem; padding: 0 .3rem; display: grid; place-items: center; border-radius: 50%; background: #fff; color: #8b2c3b; font: 1.15rem/1 var(--display); box-shadow: 0 2px 10px rgba(0, 0, 0, .3); }
.alt-chip { position: absolute; left: 0; right: 0; bottom: 0; padding: 1.8rem .8rem .6rem; background: linear-gradient(transparent, rgba(15, 18, 50, .75)); color: #fff; font-weight: 700; text-align: center; font-size: .95rem; }
.day-body { display: block; padding: .9rem .25rem 0; }
.day-when { display: block; color: var(--maroon); font-weight: 700; font-size: .92rem; }

.day-body strong { display: block; font: 1.3rem/1.2 var(--display); margin: .1rem 0 .35rem; }
.star { color: var(--saffron); font-family: var(--body); }
.day-blurb { display: block; font-size: .95rem; line-height: 1.5; color: var(--ink-soft); }
.days li.ping .arch { animation: ping 1.4s ease-out; }
@keyframes ping { 0%, 60% { box-shadow: 0 0 0 3px var(--bg), 0 0 0 5px var(--saffron), 0 0 0 16px rgba(233, 146, 43, .35); } 100% { box-shadow: 0 0 0 3px var(--bg), 0 0 0 5px var(--saffron), 0 0 0 16px rgba(233, 146, 43, 0); } }

.frost { background: var(--frost); border-radius: var(--r); padding: 1.4rem clamp(1rem, 3vw, 2rem); margin-top: 1.2rem; border: 1px solid var(--line); }
.frost .prose { max-width: none; }

.chapters { list-style: none; margin: 1.4rem 0 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: .8rem; }
.chapters a, #drawer-list a { display: flex; gap: .9rem; align-items: center; padding: .85rem 1rem; text-decoration: none; color: inherit; background: var(--paper); border: 1px solid var(--line); border-radius: 14px; transition: border-color .2s, transform .2s; }
.chapters a:hover { border-color: var(--saffron); transform: translateY(-2px); }
.chapters svg, #drawer-list svg { flex: none; width: 30px; height: 30px; color: var(--maroon); }

.chapters strong, #drawer-list strong { display: block; line-height: 1.2; }
.chapters em, #drawer-list em { display: block; font-style: normal; font-size: .88rem; color: var(--ink-soft); line-height: 1.35; }

.foot { padding: 2.5rem 0 calc(2rem + var(--tabs-h)); color: var(--ink-soft); font-size: .9rem; border-top: 1px solid var(--line); margin-top: 3rem; }
.foot p { margin: .3rem 0; }

/* ---------- gate / states ---------- */
.gate, .state { max-width: 640px; padding: 3rem 0 4rem; }
.gate h2, .state h2 { font: 2rem/1.15 var(--display); margin: 0 0 .6rem; }
.gate form { display: grid; gap: .5rem; margin: 1.4rem 0; }
.gate label { font-weight: 700; }
.gate input { font: 1rem var(--body); padding: .8rem 1rem; border-radius: 12px; border: 2px solid var(--line); background: var(--paper); color: var(--ink); min-height: 48px; }
.gate-err { color: var(--err, var(--tone-alert)); font-weight: 600; margin: .3rem 0 0; }
.btn { font: 700 1rem var(--body); min-height: 48px; padding: 0 1.4rem; border-radius: 999px; border: 0; background: var(--saffron); color: #1b1230; cursor: pointer; justify-self: start; }
.btn:hover { filter: brightness(1.06); }
.btn:disabled { opacity: .6; }
.gate details { background: var(--paper); border: 1px solid var(--line); border-radius: 14px; padding: .8rem 1.1rem; }
.gate summary { cursor: pointer; font-weight: 700; }
.gate ol { padding-left: 1.2rem; margin: .8rem 0 0; }

/* ---------- chapter pages ---------- */
.chap-head { position: relative; padding: calc(var(--bar-h) + 3.2rem) 0 2.2rem; color: #fff; background: linear-gradient(rgba(23, 27, 64, .55), rgba(23, 27, 64, .8)), var(--img) center 40% / cover; text-shadow: 0 2px 18px rgba(0, 0, 0, .4); }
.chap-head::after { content: ""; position: absolute; left: 0; right: 0; bottom: -1px; height: 22px; background: var(--bg); clip-path: polygon(0 100%, 0 70%, 8% 30%, 16% 70%, 24% 20%, 33% 75%, 42% 35%, 52% 80%, 61% 25%, 70% 70%, 80% 30%, 90% 75%, 100% 40%, 100% 100%); }
.chap-head h1 { margin: .4rem 0 .2rem; font: clamp(2.3rem, 6.5vw, 4.2rem)/1 var(--display); max-width: 18ch; }
.chap-head p { margin: 0; max-width: 52ch; font-size: 1.15rem; color: #eef0ff; }
.crumb { display: inline-flex; gap: .35rem; align-items: center; color: #f6c978; text-decoration: none; font-weight: 700; }
.crumb svg { width: 18px; height: 18px; }
.chap { display: grid; grid-template-columns: 240px minmax(0, 1fr); gap: 2.5rem; padding-top: 2.2rem; align-items: start; }
.chap.one { grid-template-columns: minmax(0, 1fr); }
.toc { position: sticky; top: calc(var(--bar-h) + 1rem); max-height: calc(100svh - var(--bar-h) - 2rem); overflow: auto; font-size: .92rem; scrollbar-width: thin; }
.toc summary { font-weight: 700; cursor: pointer; margin-bottom: .5rem; }
.toc ul { list-style: none; margin: 0; padding: 0; border-left: 2px solid var(--line); }
.toc li a { display: block; padding: .25rem .8rem; color: var(--ink-soft); text-decoration: none; line-height: 1.3; margin-left: -2px; border-left: 2px solid transparent; }
.toc li.h3 a { padding-left: 1.6rem; font-size: .88rem; }
.toc li a:hover { color: var(--ink); }
.toc li a.on { color: var(--maroon); border-left-color: var(--saffron); font-weight: 700; }

@media (max-width: 900px) {
  .chap { grid-template-columns: minmax(0, 1fr); gap: 1rem; }
  .toc { position: static; max-height: none; background: var(--paper); border: 1px solid var(--line); border-radius: 14px; padding: .8rem 1rem; }
}

.prose { max-width: 74ch; font-size: 1.0625rem; line-height: 1.68; }
.prose > :first-child { margin-top: 0; }
.prose h2 { font: 1.9rem/1.15 var(--display); margin: 2.8rem 0 .8rem; padding-top: 1.4rem; position: relative; }
.prose h2::before { content: ""; position: absolute; top: 0; left: 0; width: 76px; height: 10px; background: linear-gradient(90deg, #2f6fb5 0 20%, #f4f4f0 20% 40%, #d6403a 40% 60%, #3f9b5e 60% 80%, #f1c232 80%); clip-path: polygon(0 0, 100% 0, 96% 100%, 80% 40%, 76% 100%, 60% 40%, 56% 100%, 40% 40%, 36% 100%, 20% 40%, 16% 100%, 0 40%); }
.prose h3 { font: 1.35rem/1.25 var(--display); margin: 2.1rem 0 .6rem; }
.prose h4 { margin: 1.5rem 0 .4rem; font-size: 1.05rem; }
.prose p, .prose ul, .prose ol { margin: .8rem 0; }
.prose li { margin: .3rem 0; }
.prose li > ul, .prose li > ol { margin: .3rem 0; }
.prose strong { font-weight: 700; }
.prose hr { border: 0; height: 1px; background: var(--line); margin: 2rem 0; }
.prose code { font: .88em ui-monospace, "SF Mono", Menlo, monospace; background: color-mix(in srgb, var(--ink) 8%, transparent); padding: .12em .4em; border-radius: 6px; }
.prose pre { overflow: auto; padding: 1rem; border-radius: 12px; background: color-mix(in srgb, var(--ink) 8%, transparent); }
.prose pre code { background: none; padding: 0; }
.prose a.dead { color: inherit; text-decoration: underline dotted; cursor: help; }
.prose img { border-radius: 12px; }
.callout { margin: 1.2rem 0; padding: .6rem 1.2rem; background: var(--frost); border-left: 4px solid var(--saffron); border-radius: 0 12px 12px 0; }
.callout > :first-child { margin-top: .3rem; } .callout > :last-child { margin-bottom: .3rem; }
.prose [data-tone] { }
.prose li[data-tone], .prose p[data-tone] { border-left: 3px solid var(--tone, transparent); padding-left: .75rem; margin-left: -.9rem; }
.prose [data-tone="ok"] { --tone: var(--tone-ok); }
.prose [data-tone="warn"] { --tone: var(--tone-warn); }
.prose [data-tone="alert"] { --tone: var(--tone-alert); }
.prose li.task { list-style: none; margin-left: -1.3rem; }
.prose li.task input { accent-color: var(--maroon); width: 1.05em; height: 1.05em; margin-right: .5em; vertical-align: -.12em; }
.prose li.task.done { color: var(--ink-soft); }
.tablewrap { overflow-x: auto; margin: 1.2rem 0; border: 1px solid var(--line); border-radius: 12px; background: var(--paper); -webkit-overflow-scrolling: touch; }
.prose table { border-collapse: collapse; width: 100%; min-width: 520px; font-size: .96rem; line-height: 1.45; }
.prose th, .prose td { padding: .6rem .9rem; text-align: left; vertical-align: top; border-bottom: 1px solid var(--line); }
.prose th { background: var(--frost); font-weight: 700; white-space: nowrap; }
.prose tr:last-child td { border-bottom: 0; }
.frost .tablewrap { background: var(--paper); }

.pager { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; margin-top: 3.5rem; }
.pager a { display: block; padding: 1rem 1.2rem; border: 1px solid var(--line); border-radius: 14px; background: var(--paper); text-decoration: none; color: var(--ink); font: 1.15rem/1.2 var(--display); }
.pager a[rel=next] { text-align: right; }
.pager a:hover { border-color: var(--saffron); }
.pager small { display: block; font: 600 .8rem var(--body); color: var(--ink-soft); margin-bottom: .2rem; }
.credits { list-style: none; padding: 0; display: grid; gap: 1rem; }
.credits li { display: flex; gap: 1rem; align-items: center; margin: 0; }
.credits img { width: 96px; height: 64px; object-fit: cover; border-radius: 8px; flex: none; }

/* ---------- drawer + tabs ---------- */
.scrim { position: fixed; inset: 0; background: rgba(10, 12, 40, .5); z-index: 60; }
.drawer { position: fixed; top: 0; right: 0; bottom: 0; width: min(380px, 92vw); background: var(--bg); z-index: 70; display: flex; flex-direction: column; box-shadow: -20px 0 60px rgba(0, 0, 0, .3); padding-top: env(safe-area-inset-top); }
.drawer[hidden], .scrim[hidden] { display: none; }
.drawer-head { display: flex; justify-content: space-between; align-items: center; padding: .8rem 1rem .4rem 1.2rem; font: 1.4rem var(--display); }
#drawer-list { list-style: none; margin: 0; padding: .4rem 1rem; overflow: auto; flex: 1; display: grid; gap: .5rem; align-content: start; }
#drawer-list a.on { border-color: var(--saffron); }
.drawer-foot { display: flex; justify-content: space-between; gap: .8rem; flex-wrap: wrap; padding: 1rem 1.2rem calc(1rem + env(safe-area-inset-bottom)); border-top: 1px solid var(--line); }
.drawer-foot a, .drawer-foot button { background: none; border: 0; color: var(--link); font: inherit; cursor: pointer; text-decoration: underline; }

.tabs { display: none; }
@media (max-width: 720px) {
  :root { --tabs-h: 64px; }
  body { padding-bottom: calc(var(--tabs-h) + env(safe-area-inset-bottom)); }
  .bar .lbl { display: none; }
  .tabs { position: fixed; left: 0; right: 0; bottom: 0; z-index: 50; display: grid; grid-template-columns: repeat(var(--n, 5), 1fr); height: calc(var(--tabs-h) + env(safe-area-inset-bottom)); padding-bottom: env(safe-area-inset-bottom); background: color-mix(in srgb, var(--paper) 92%, transparent); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); border-top: 1px solid var(--line); }
  .tabs a, .tabs button { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; color: var(--ink-soft); text-decoration: none; font: 600 .72rem var(--body); background: none; border: 0; cursor: pointer; }
  .tabs svg { width: 24px; height: 24px; }
  .tabs a.on { color: var(--maroon); }
  
  .days { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.2rem .8rem; }
  .day-blurb { display: none; }
  .day-body strong { font-size: 1.1rem; }
  .arch { aspect-ratio: 4 / 4.6; }
}
@media (max-width: 380px) { .days { grid-template-columns: minmax(0, 1fr); } .arch { aspect-ratio: 4 / 3.4; } }
@media (min-width: 721px) and (max-width: 1000px) { .days { grid-template-columns: repeat(3, minmax(0, 1fr)); } }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}
@media print {
  .bar, .tabs, .scene, .flags, .toc, .pager, .drawer, .scrim { display: none !important; }
  .hero { min-height: 0; background: none; color: #000; } .hero-copy { padding: 1rem 0; text-shadow: none; }
  .chap-head { background: none; color: #000; text-shadow: none; padding: 1rem 0; } .chap-head::after { display: none; }
  .chap { display: block; }
}

body[data-locked] .tabs, body[data-locked] #menu-btn, body[data-locked] #refresh { display: none !important; }


/* ================= light holiday pass ================= */
.clouds { position: absolute; inset: 0; z-index: 1; overflow: hidden; pointer-events: none; }
.clouds i { position: absolute; left: -30%; width: 220px; height: 54px; border-radius: 60px; background: rgba(255, 255, 255, .85); box-shadow: 70px -22px 0 -4px rgba(255, 255, 255, .85), 130px 4px 0 -8px rgba(255, 255, 255, .85); filter: blur(.5px); animation: drift 90s linear infinite; }
.clouds i:nth-child(1) { top: 26%; animation-duration: 110s; }
.clouds i:nth-child(2) { top: 40%; transform: scale(.7); animation-duration: 150s; animation-delay: -60s; opacity: .8; }
.clouds i:nth-child(3) { top: 14%; transform: scale(1.2); animation-duration: 190s; animation-delay: -120s; opacity: .7; }
@keyframes drift { to { translate: 160vw 0; } }
.hero .scene .layer, .hero .scene .sun { z-index: 0; }

.glance { margin-top: -3.2rem !important; }
.tiles { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: .8rem; }
.tiles li { display: grid; justify-items: center; text-align: center; gap: .1rem; padding: 1.1rem .6rem 1rem; background: var(--paper); border-radius: var(--r); box-shadow: 0 16px 36px -22px rgba(30, 60, 140, .55); }
.tiles li:nth-child(1) { background: linear-gradient(160deg, #fff, #fff4d6); }
.tiles li:nth-child(2) { background: linear-gradient(160deg, #fff, #e3f6ec); }
.tiles li:nth-child(3) { background: linear-gradient(160deg, #fff, #e8e6fb); }
.tiles li:nth-child(4) { background: linear-gradient(160deg, #fff, #ffe6e2); }
.tiles .ico { font-size: 1.6rem; line-height: 1; }
.tiles b { font: 2rem/1.1 var(--display); color: var(--ink); }
.tiles span:last-child { font-size: .88rem; color: var(--ink-soft); line-height: 1.25; }
.statusline { margin: 1rem 0 0; text-align: center; font-weight: 600; color: var(--ink-soft); }
@media (max-width: 720px) { .tiles { grid-template-columns: repeat(2, 1fr); } .tiles b { font-size: 1.7rem; } }

.route li { border-radius: 999px; border: 0; background: var(--paper); box-shadow: 0 6px 16px -10px rgba(30, 60, 140, .5); }
.route li:nth-child(5n+1) { background: #fff4d6; } .route li:nth-child(5n+2) { background: #e3f6ec; } .route li:nth-child(5n+3) { background: #e8e6fb; } .route li:nth-child(5n+4) { background: #ffe6e2; } .route li:nth-child(5n) { background: #e4f3fd; }
.route li:not(:last-child)::after { background: none; }

.sec { font-size: clamp(2.1rem, 5vw, 3rem); }
.sec-sub { margin-top: .3rem; }
.knot { fill: #fff; }

/* day postcards: photo first, a single line of text */
.days { gap: 2rem 1.4rem; }
.arch { box-shadow: 0 0 0 4px #fff, 0 0 0 6px var(--sun), 0 18px 30px -16px rgba(30, 60, 140, .5); }
.day-blurb { font-size: .92rem; line-height: 1.4; }
.day-body strong { font-size: 1.4rem; }
.day { transition: transform .25s; }
.day:hover { transform: translateY(-5px) rotate(-.6deg); }

/* photo strip */
.strip { padding-top: 3.2rem; }
.strip-row { display: flex; gap: 1rem; overflow-x: auto; padding: 1.4rem max(1rem, calc((100vw - 1120px) / 2)) 1.4rem; scroll-snap-type: x proximity; scrollbar-width: thin; }
.strip-row figure { flex: none; width: min(230px, 62vw); margin: 0; padding: 8px 8px 12px; background: #fff; border-radius: 6px; box-shadow: 0 14px 28px -16px rgba(30, 60, 140, .6); scroll-snap-align: center; }
.strip-row figure:nth-child(odd) { transform: rotate(-1.8deg); } .strip-row figure:nth-child(even) { transform: rotate(1.5deg) translateY(6px); }
.strip-row img { width: 100%; aspect-ratio: 4 / 5; object-fit: cover; border-radius: 3px; }
.strip-row figcaption { padding-top: .5rem; text-align: center; font: 1.05rem var(--display); color: var(--ink); }

/* sky report */
.sky { padding: 0; overflow: hidden; background: linear-gradient(120deg, #e4f3fd, #f0f7ff); }
.sky summary { display: flex; align-items: center; gap: .9rem; padding: 1.1rem 1.3rem; cursor: pointer; list-style: none; font-weight: 700; font-size: 1.05rem; }
.sky summary::-webkit-details-marker { display: none; }
.sky summary em { margin-left: auto; font-style: normal; color: var(--maroon); font-weight: 700; white-space: nowrap; }
.sky summary em::after { content: " ▾"; }
.sky[open] summary em::after { content: " ▴"; }
.snowflake { font-size: 1.8rem; }
.sky .prose { padding: 0 1.3rem 1.3rem; }

/* chapter tiles: photos with a title */
.chapters { grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 1rem; }
.chapters a { position: relative; display: flex; flex-direction: column; justify-content: flex-end; align-items: flex-start; gap: .4rem; min-height: 150px; padding: 1rem; border: 0; border-radius: var(--r); overflow: hidden; color: #fff; background: linear-gradient(180deg, rgba(20, 40, 100, .05) 25%, rgba(20, 40, 100, .72)), var(--img) center / cover; box-shadow: 0 14px 28px -18px rgba(30, 60, 140, .7); }
.chapters a:hover { transform: translateY(-4px) rotate(-.5deg); }
.chapters strong { font: 1.25rem/1.15 var(--display); text-shadow: 0 2px 10px rgba(0, 0, 0, .35); }
.chapters .ch-ico { position: absolute; top: .8rem; left: .8rem; width: 38px; height: 38px; display: grid; place-items: center; border-radius: 50%; background: rgba(255, 255, 255, .92); }
.chapters .ch-ico svg { width: 22px; height: 22px; color: var(--maroon); }

/* chapter pages: lighter header, collapsible sections */
.chap-head { background: linear-gradient(rgba(30, 80, 170, .25), rgba(30, 60, 140, .6)), var(--img) center 40% / cover; }
.prose h2 { margin: 0; padding: 0; font-size: 1.5rem; }
.prose h2::before { display: none; }
.sect { margin: 1rem 0; background: var(--paper); border-radius: var(--r); box-shadow: 0 10px 28px -20px rgba(30, 60, 140, .6); border: 1px solid var(--line); }
.sect > summary { list-style: none; cursor: pointer; display: flex; align-items: center; gap: .8rem; padding: 1rem 1.3rem; position: relative; }
.sect > summary::-webkit-details-marker { display: none; }
.sect > summary::after { content: "+"; margin-left: auto; width: 32px; height: 32px; display: grid; place-items: center; border-radius: 50%; background: var(--frost); color: var(--maroon); font: 700 1.3rem/1 var(--body); flex: none; transition: transform .2s; }
.sect[open] > summary::after { content: "–"; background: var(--sun); color: var(--ink); }
.sect > summary h2 { flex: 1; }
.sect-body { padding: 0 1.4rem 1.3rem; border-top: 1px dashed var(--line); }
.sect-body > :first-child { margin-top: 1rem; }
.sect-body h3 { margin-top: 1.8rem; }
#expand { margin-bottom: .4rem; }
.tablewrap { border-radius: 14px; }
.callout { border-left-color: var(--sun); background: #fff8dc; }
.drawer { background: var(--bg); }
.tabs { background: rgba(255, 255, 255, .94) !important; }
.bar.solid { background: rgba(255, 255, 255, .9); }
.foot { margin-top: 2rem; }
.btn { background: var(--sun); color: #1e2a55; }
.gate-err { color: var(--err); }

.sub { margin: .6rem 0; border: 1px solid var(--line); border-radius: 16px; background: var(--bg); }
.sub > summary { list-style: none; cursor: pointer; display: flex; align-items: center; gap: .6rem; padding: .7rem 1rem; }
.sub > summary::-webkit-details-marker { display: none; }
.sub > summary h3 { margin: 0; flex: 1; font-size: 1.15rem; }
.sub > summary::after { content: "+"; width: 26px; height: 26px; display: grid; place-items: center; border-radius: 50%; background: #fff; color: var(--maroon); font-weight: 700; flex: none; }
.sub[open] > summary::after { content: "–"; background: var(--sun); color: var(--ink); }
.sub[open] { background: #fff; box-shadow: 0 8px 22px -18px rgba(30, 60, 140, .7); }
.sub-body { padding: 0 1.1rem 1rem; }
.sub-body > :first-child { margin-top: .4rem; }
@media (max-width: 720px) { .chapters { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .7rem; } .chapters a { min-height: 120px; padding: .8rem; } .chapters strong { font-size: 1.05rem; } }

/* ---------- trip map ---------- */
.mapsec { padding-top: 3.2rem; }
.mapbox { position: relative; margin-top: 1rem; border-radius: 26px; overflow: hidden; box-shadow: 0 24px 50px -28px rgba(30, 60, 140, .7); border: 4px solid #fff; background: #dfeaf2; }
#tmap { height: clamp(460px, 70vh, 640px); z-index: 0; }
#tmap .leaflet-tile-pane { filter: saturate(1.1) brightness(1.04); }
.nomap { padding: 2rem; }
.pinwrap { background: none; border: 0; }
.tpin { position: absolute; left: 0; top: 0; translate: -50% -115%; display: grid; place-items: center; min-width: 40px; height: 40px; padding: 0 .55rem; border-radius: 20px 20px 20px 4px; background: var(--maroon); color: #fff; font: 1.05rem/1 var(--display); border: 3px solid #fff; box-shadow: 0 6px 16px rgba(30, 40, 90, .45); rotate: -4deg; white-space: nowrap; }
.tdot { display: block; width: 14px; height: 14px; border-radius: 50%; background: #fff; border: 3px solid var(--teal); box-shadow: 0 2px 6px rgba(0, 0, 0, .3); }
.play { position: absolute; z-index: 500; top: 12px; right: 12px; display: inline-flex; gap: .5rem; align-items: center; min-height: 44px; padding: 0 1.1rem; border: 0; border-radius: 999px; background: var(--sun); color: var(--ink); font: 700 1rem var(--body); cursor: pointer; box-shadow: 0 8px 20px -8px rgba(0, 0, 0, .5); }
.mkey { position: absolute; z-index: 500; right: 12px; bottom: 26px; list-style: none; margin: 0; padding: .45rem .8rem; display: flex; gap: .9rem; background: rgba(255, 255, 255, .92); border-radius: 999px; font-size: .8rem; font-weight: 600; }
.mkey i { display: inline-block; width: 22px; border-top: 4px solid var(--saffron); vertical-align: middle; margin-right: .3rem; }
.mkey .k-side { border-top: 3px dotted var(--teal); } .mkey .k-fly { border-top: 3px dashed var(--maroon); }
.ov { position: absolute; z-index: 600; left: 14px; top: 14px; bottom: 14px; width: min(350px, calc(100% - 28px)); overflow: auto; background: #fff; border-radius: 20px; box-shadow: 0 20px 50px -14px rgba(20, 40, 100, .6); animation: ovin .35s cubic-bezier(.2, .8, .2, 1); }
.ov[hidden] { display: none; }
@keyframes ovin { from { opacity: 0; transform: translateX(-14px); } }
.ov > img { width: 100%; height: 150px; object-fit: cover; }
.ov-x { position: absolute; top: 10px; right: 10px; width: 36px; height: 36px; border: 0; border-radius: 50%; background: rgba(255, 255, 255, .92); font-size: 1.5rem; line-height: 1; cursor: pointer; color: var(--ink); }
.ov-b { padding: .9rem 1.1rem 1.1rem; }
.ov-days { display: flex; gap: .4rem; margin-bottom: .6rem; }
.ov-days button { border: 2px solid var(--line); background: #fff; border-radius: 999px; padding: .15rem .8rem; font-weight: 700; cursor: pointer; }
.ov-days button.on { background: var(--maroon); border-color: var(--maroon); color: #fff; }
.ov-when { margin: 0; color: var(--maroon); font-weight: 700; font-size: .92rem; }
.ov h3 { margin: .1rem 0 .3rem; font: 1.6rem/1.1 var(--display); }
.ov-alt { display: inline-block; margin: 0 0 .5rem; padding: .15rem .7rem; border-radius: 999px; background: var(--frost); font-weight: 700; font-size: .9rem; }
.ov-lead { margin: .2rem 0 .5rem; font-size: .97rem; line-height: 1.5; }
.ov ul { margin: 0 0 .8rem; padding-left: 1.1rem; font-size: .9rem; line-height: 1.45; color: var(--ink-soft); display: grid; gap: .25rem; }
.ov-nav { display: flex; align-items: center; justify-content: space-between; gap: .5rem; }
.ov-nav button { width: 44px; height: 44px; border-radius: 50%; border: 2px solid var(--line); background: #fff; font-size: 1.5rem; line-height: 1; cursor: pointer; color: var(--ink); }
.ov-nav button:disabled { opacity: .35; cursor: default; }
.ov-nav .btn { display: inline-grid; place-items: center; text-decoration: none; min-height: 44px; }
.map-note { margin: .6rem 0 0; font-size: .8rem; color: var(--ink-soft); }
.peak.on .knot { fill: var(--saffron); r: 7; }
@media (max-width: 720px) {
  #tmap { height: 560px; }
  .ov { left: 8px; right: 8px; top: auto; bottom: 8px; width: auto; max-height: 52%; border-radius: 18px; }
  .ov > img { height: 90px; }
  .mkey { display: none; }
  .play { top: 8px; right: 8px; }
}

/* sunrise & sunset strip */
.sun { margin: .8rem 0 1rem; padding: .6rem .8rem .7rem; background: var(--paper); border: 1px solid var(--line); border-radius: 14px; }
.sunsvg { display: block; width: 100%; height: auto; max-height: 96px; }
.sun figcaption { display: grid; grid-template-columns: 1fr auto 1fr; gap: .5rem; align-items: start; margin-top: .35rem; }
.sun figcaption span { display: grid; gap: .05rem; }
.sun figcaption b { font: 700 1.15rem/1.2 var(--display); color: var(--ink); }
.sun figcaption small { font-size: .8rem; color: var(--ink-soft); line-height: 1.3; }
.sun .s-up b { color: #b36a00; }
.sun .s-dn b { color: var(--maroon); }
.sun .s-mid { text-align: center; }
.sun .s-dn { text-align: right; }
.day-sun { display: block; font-size: .85rem; font-weight: 700; color: var(--ink-soft); margin: .05rem 0 .1rem; }
.ov .sun { margin: .4rem 0 .6rem; }
