:root {
  color-scheme: light;
  --bg: #f4f1ec;
  --ink: #1d1d1f;
  --secondary: #5c5c61;
  --tertiary: #6e6e73;
  --line: rgba(29, 29, 31, 0.12);
  --surface: #f7f5f2;
  --accent: #0c3d56;
  --accent-ink: #ffffff;
  --glass: rgba(255, 255, 255, 0.34);
  --glass-solid: #f4f1ec;
  --glass-sheen: linear-gradient(180deg, rgba(255, 255, 255, 0.62) 0%, rgba(255, 255, 255, 0.14) 42%, rgba(255, 255, 255, 0.28) 100%);
  --glass-lens: radial-gradient(125% 90% at 50% -24%, rgba(255, 255, 255, 0.72), transparent 54%);
  --glass-rim: inset 0 1px 0 rgba(255, 255, 255, 0.92), inset 0 0 0 0.5px rgba(255, 255, 255, 0.48), inset 0 -1px 0 rgba(255, 255, 255, 0.22), inset 0 12px 18px rgba(255, 255, 255, 0.16);
  --shadow: 0 10px 40px rgba(12, 28, 36, 0.16);
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --font: -apple-system, BlinkMacSystemFont, "SF Pro Display", "SF Pro Text", "PingFang SC", "Hiragino Sans GB", "Noto Sans SC", "Noto Sans CJK SC", "Source Han Sans SC", "WenQuanYi Micro Hei", sans-serif;
  --safe-b: env(safe-area-inset-bottom, 0px);
  --safe-t: env(safe-area-inset-top, 0px);
  --safe-r: env(safe-area-inset-right, 0px);
  --safe-l: env(safe-area-inset-left, 0px);
}

html[data-theme="dark"] {
  color-scheme: dark;
  --bg: #000000;
  --ink: #f5f5f7;
  --secondary: #c7c7cc;
  --tertiary: #aeaeb2;
  --line: rgba(255, 255, 255, 0.14);
  --surface: #1c1c1e;
  --accent: #8ec8e8;
  --accent-ink: #06202c;
  --glass: rgba(8, 10, 14, 0.28);
  --glass-solid: #161618;
  --glass-sheen: linear-gradient(180deg, rgba(255, 255, 255, 0.26) 0%, rgba(255, 255, 255, 0.05) 34%, rgba(0, 0, 0, 0.22) 100%);
  --glass-lens: radial-gradient(130% 100% at 50% -28%, rgba(255, 255, 255, 0.46), transparent 50%);
  --glass-rim: inset 0 1px 0 rgba(255, 255, 255, 0.7), inset 0 0 0 0.5px rgba(255, 255, 255, 0.32), inset 0 -1px 0 rgba(255, 255, 255, 0.1), inset 0 14px 22px rgba(255, 255, 255, 0.06), inset 0 -18px 26px rgba(0, 0, 0, 0.32);
  --shadow: 0 16px 50px rgba(0, 0, 0, 0.45);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font);
  background: var(--bg);
  color: var(--ink);
  font-size: 17px;
  line-height: 1.47;
  letter-spacing: -0.011em;
  padding-bottom: calc(96px + var(--safe-b));
}
button, input { font-family: inherit; color: inherit; }
a { color: var(--accent); }
img { max-width: 100%; display: block; }
h1, h2, h3 { font-weight: 700; letter-spacing: -0.04em; line-height: 1.05; }

.skip {
  position: absolute;
  left: 16px;
  top: -48px;
  background: var(--accent);
  color: var(--accent-ink);
  padding: 8px 12px;
  border-radius: 10px;
  z-index: 80;
}
.skip:focus { top: 12px; }

.topbar {
  position: fixed;
  z-index: 40;
  top: calc(10px + var(--safe-t));
  left: 0;
  right: 0;
  margin-inline: auto;
  width: min(720px, calc(100% - 24px));
  min-height: 48px;
  display: flex;
  align-items: center;
  gap: 18px;
  padding: 6px 8px 6px 18px;
  border-radius: 999px;
  background: var(--glass-solid);
  color: var(--ink);
  box-shadow: inset 0 0 0 0.5px var(--line), var(--shadow);
}
.wordmark {
  color: var(--ink);
  text-decoration: none;
  font-weight: 700;
  letter-spacing: -0.03em;
}
.topbar { justify-content: space-between; }
.chrome {
  --bar: 56px;
  position: fixed;
  z-index: 46;
  left: 50%;
  bottom: calc(16px + var(--safe-b));
  transform: translateX(-50%);
  width: min(720px, calc(100% - 24px - var(--safe-l) - var(--safe-r)));
  height: var(--bar);
  display: flex;
  align-items: center;
  gap: 12px;
}
.view-switch {
  position: relative;
  flex: 1 1 auto;
  height: var(--bar);
  min-height: var(--bar);
  display: flex;
  align-items: center;
  padding: 4px;
  border-radius: 999px;
  background: var(--glass-solid);
  box-shadow: inset 0 0 0 0.5px var(--line), var(--shadow);
}
.view-switch button {
  flex: 1 1 0;
  border: 0;
  background: transparent;
  color: var(--ink);
  height: calc(var(--bar) - 8px);
  min-height: calc(var(--bar) - 8px);
  padding: 0 10px;
  border-radius: 999px;
  cursor: pointer;
  font-size: 15px;
  font-weight: 600;
}
.view-switch button[aria-selected="true"] {
  background: color-mix(in srgb, #fff 34%, transparent);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.75), inset 0 0 0 0.5px rgba(255, 255, 255, 0.28);
  color: var(--ink);
}
.view.is-active { animation: view-in 0.45s var(--ease); }
.view[hidden] { display: none !important; }
@keyframes view-in {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: none; }
}
.choices { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 14px; }
.choices button {
  border: 0.5px solid var(--line);
  background: transparent;
  color: var(--ink);
  min-height: 44px;
  padding: 0 14px;
  border-radius: 999px;
  cursor: pointer;
}
.choices button[aria-pressed="true"] { background: var(--ink); color: var(--bg); border-color: var(--ink); }
.hint { color: var(--secondary); font-size: 14px; margin: 8px 0 0; }
.text-btn, .hero-dates, .sort button, .occ-row button, .filters button, .linkish {
  border: 0;
  background: transparent;
  cursor: pointer;
  min-height: 44px;
  padding: 0 14px;
  border-radius: 999px;
  font-size: 15px;
}
.text-btn { color: var(--ink); font-weight: 600; }
button:focus-visible, a:focus-visible, input:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}

.hero {
  position: relative;
  min-height: 100svh;
  min-height: 100dvh;
  color: #fff;
  display: flex;
  align-items: flex-end;
}
.hero-photo {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.hero-shade {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(6, 16, 22, 0.78) 0%, rgba(6, 16, 22, 0.28) 42%, rgba(6, 16, 22, 0.12) 100%);
}
.hero-copy {
  position: relative;
  z-index: 1;
  width: min(1120px, calc(100% - 48px));
  margin: 0 auto calc(120px + var(--safe-b));
}
.hero-kicker {
  margin: 0 0 12px;
  font-size: 15px;
  font-weight: 600;
  letter-spacing: 0.08em;
}
.hero h1 {
  margin: 0;
  font-size: clamp(56px, 9vw, 112px);
  font-weight: 700;
  letter-spacing: -0.045em;
  line-height: 0.96;
  text-shadow: 0 2px 24px rgba(0, 0, 0, 0.25);
}
.lede, .deck {
  max-width: 34rem;
  font-size: 21px;
  line-height: 1.4;
  color: rgba(255, 255, 255, 0.92);
}
.lede { margin: 22px 0 28px; }
.hero-dates {
  color: #fff;
  background: rgba(8, 16, 22, 0.35);
  border: 0.5px solid rgba(255, 255, 255, 0.45);
  font-size: 17px;
  font-weight: 600;
  padding: 0 18px;
}
@supports ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
  .hero-dates {
    background: rgba(255, 255, 255, 0.16);
    -webkit-backdrop-filter: blur(16px) saturate(140%);
    backdrop-filter: blur(16px) saturate(140%);
  }
}

.chapter {
  width: min(1120px, calc(100% - 48px));
  margin: 0 auto;
  padding: 96px 0 12px;
}
.kicker {
  margin: 0 0 8px;
  color: var(--secondary);
  font-size: 15px;
  font-weight: 600;
}
.chapter h2 { margin: 0; font-size: clamp(40px, 5vw, 68px); }
.deck { color: var(--secondary); margin: 16px 0 0; font-size: 19px; }

.reveal { opacity: 0; transform: translateY(18px); }
.reveal.in { animation: rise 0.7s var(--ease) forwards; }
@keyframes rise { to { opacity: 1; transform: none; } }

.flight-block { margin-top: 36px; }
.flight-block h3 {
  margin: 0 0 8px;
  font-size: 28px;
  font-weight: 650;
}
.sort { display: flex; gap: 4px; margin: 8px 0 12px; }
.sort button { color: var(--tertiary); font-weight: 500; }
.sort button[aria-selected="true"] { color: var(--ink); font-weight: 650; }
.flight {
  width: 100%;
  text-align: left;
  border: 0;
  border-bottom: 0.5px solid var(--line);
  background: transparent;
  padding: 22px 4px;
  display: grid;
  grid-template-columns: 1.4fr 0.8fr;
  gap: 16px;
  cursor: pointer;
  border-radius: 0;
}
.flight.is-selected { box-shadow: inset 3px 0 0 var(--accent); padding-left: 14px; }
.times { display: flex; align-items: baseline; gap: 10px; font-variant-numeric: tabular-nums; }
.times b { font-size: 32px; font-weight: 650; letter-spacing: -0.04em; }
.times span, .muted { color: var(--secondary); }
.plus { color: var(--accent); font-size: 13px; font-weight: 700; }
.price { margin: 0; text-align: right; }
.price strong { display: block; font-size: 22px; letter-spacing: -0.03em; }
.price small { color: var(--secondary); font-size: 13px; }
.links { display: flex; gap: 16px; margin-top: 8px; font-size: 15px; }
.links a { text-decoration: none; }
.links a:hover { text-decoration: underline; }

.occ-row, .filters { display: flex; flex-wrap: wrap; gap: 8px; margin: 18px 0 8px; }
.occ-row button, .filters button {
  background: transparent;
  border: 0.5px solid var(--line);
  color: var(--ink);
}
.occ-row button[aria-selected="true"], .filters button[aria-selected="true"] {
  background: var(--ink);
  color: var(--bg);
  border-color: var(--ink);
}

.stay-list, .day-story, .notes { display: grid; gap: 28px; margin-top: 28px; }
.stay, .day {
  display: grid;
  grid-template-columns: 1.05fr 1fr;
  gap: 28px;
  align-items: center;
  background: transparent;
  border: 0;
  padding: 0;
  text-align: left;
  color: inherit;
  cursor: pointer;
  width: 100%;
}
.stay img, .day img, .plan img {
  width: 100%;
  height: 320px;
  object-fit: cover;
  border-radius: 18px;
}
.gallery { position: relative; }
.gallery-track {
  display: flex;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  border-radius: 18px;
  scrollbar-width: none;
}
.gallery-track::-webkit-scrollbar { display: none; }
.gallery-track img {
  flex: 0 0 100%;
  width: 100%;
  scroll-snap-align: start;
  border-radius: 0;
}
.gallery-nav {
  position: absolute;
  right: 10px;
  bottom: 10px;
  display: flex;
  gap: 6px;
}
.gallery-nav button {
  width: 36px;
  height: 36px;
  border: 0;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.45);
  color: #fff;
  font-size: 22px;
  line-height: 1;
  cursor: pointer;
}
.spec { margin: 6px 0; color: var(--secondary); font-size: 15px; }
.stay.is-selected img, .plan.is-selected img { outline: 2px solid var(--accent); outline-offset: 4px; }
.stay h3, .day h3, .plan h3 { margin: 8px 0; font-size: 32px; }
.place { margin: 0; color: var(--secondary); font-size: 15px; }

.plan-row {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 12px;
  margin-top: 36px;
}
.plan {
  border: 0;
  padding: 0;
  background: transparent;
  text-align: left;
  color: inherit;
  cursor: pointer;
}
.plan img { height: 180px; border-radius: 14px; }
.plan h3 { font-size: 18px; margin: 10px 0 4px; }
.plan p { margin: 0; color: var(--secondary); font-size: 14px; line-height: 1.35; }

.note details {
  border-bottom: 0.5px solid var(--line);
  padding: 8px 0 16px;
}
.note summary {
  cursor: pointer;
  font-size: 22px;
  font-weight: 650;
  letter-spacing: -0.03em;
  min-height: 44px;
  display: flex;
  align-items: center;
}
.note p { color: var(--secondary); }
.combo {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: center;
  padding: 16px 0;
  border-bottom: 0.5px solid var(--line);
}
.quiet h2 { font-size: 40px; }

.bag {
  position: relative;
  flex: none;
  width: var(--bar, 56px);
  height: var(--bar, 56px);
  border: 0;
  border-radius: 50%;
  padding: 0;
  display: grid;
  place-items: center;
  color: var(--ink);
  background: var(--glass-solid);
  box-shadow: inset 0 0 0 0.5px var(--line), var(--shadow);
  cursor: pointer;
}
.bag-count {
  position: absolute;
  top: 5px;
  right: 5px;
  min-width: 20px;
  height: 20px;
  padding: 0 5px;
  border-radius: 999px;
  background: var(--accent);
  color: var(--accent-ink);
  font-size: 12px;
  font-weight: 700;
  line-height: 20px;
  text-align: center;
}
.bag-count[hidden] { display: none; }
.bag.is-bump { animation: bag-bump 0.45s var(--ease); }
@keyframes bag-bump {
  0% { transform: scale(1); }
  40% { transform: scale(1.12); }
  100% { transform: scale(1); }
}
.bag-panel { display: flex; flex-direction: column; overflow: hidden; }
.bag-scroll { overflow: auto; min-height: 0; flex: 1 1 auto; }
.bag-foot { flex: none; padding-top: 8px; border-top: 0.5px solid var(--line); }
.bag-list { list-style: none; margin: 0; padding: 0; }
.bag-line {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 4px 12px;
  align-items: center;
  padding: 14px 0;
  border-bottom: 0.5px solid var(--line);
}
.bag-line p { margin: 0; }
.bag-line .kicker { color: var(--secondary); font-size: 13px; }
.bag-line strong { font-size: 17px; }
.bag-line .line-price { font-weight: 650; letter-spacing: -0.03em; }
.bag-line .line-actions { grid-column: 1 / -1; display: flex; gap: 8px; }
.fine { margin: 8px 0 0; color: var(--secondary); font-size: 12px; line-height: 1.35; }
.bag-total { margin: 18px 0 6px; }
.bag-total b { display: block; font-size: 32px; letter-spacing: -0.04em; }
.bag-actions { display: flex; gap: 8px; justify-content: flex-end; margin-top: 12px; }
.confirm {
  position: fixed;
  z-index: 55;
  left: 50%;
  bottom: calc(16px + 56px + 14px + var(--safe-b));
  width: min(420px, calc(100% - 32px));
  transform: translateX(-50%) translateY(12px);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.35s var(--ease), transform 0.35s var(--ease);
}
.confirm.is-in {
  opacity: 1;
  transform: translateX(-50%);
  pointer-events: auto;
}
.confirm-card {
  position: relative;
  border-radius: 22px;
  padding: 12px 18px 14px;
  background: var(--glass-solid);
  box-shadow: inset 0 0 0 0.5px var(--line), var(--shadow);
  text-align: center;
  touch-action: none;
}
.confirm-card .grabber {
  display: block;
  width: 36px;
  height: 5px;
  margin: 0 auto 10px;
  border-radius: 999px;
  background: color-mix(in srgb, var(--ink) 22%, transparent);
}
.confirm-card p { margin: 0; font-size: 15px; }
.confirm-card b { display: block; margin-top: 4px; font-size: 28px; letter-spacing: -0.04em; }
.confirm-card span { color: var(--secondary); font-size: 13px; }
.day.is-out { opacity: 0.72; }
.primary {
  background: var(--accent);
  color: var(--accent-ink);
  border: 0;
  border-radius: 999px;
  min-height: 44px;
  padding: 0 18px;
  font-size: 16px;
  font-weight: 650;
  cursor: pointer;
}
.ghost {
  background: color-mix(in srgb, var(--ink) 8%, transparent);
  color: var(--ink);
  border: 0;
  border-radius: 999px;
  min-height: 44px;
  padding: 0 16px;
  font-size: 16px;
  cursor: pointer;
}
.breakdown { grid-column: 1 / -1; color: var(--secondary); font-size: 14px; }

.sheet[hidden] { display: none; }
.sheet { position: fixed; inset: 0; z-index: 60; }
.scrim {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.38);
  border: 0;
  width: 100%;
}
.panel {
  position: absolute;
  left: 50%;
  bottom: 0;
  transform: translateX(-50%);
  width: min(640px, 100%);
  max-height: min(88dvh, 820px);
  overflow: auto;
  background: var(--glass-solid);
  border-radius: 28px 28px 0 0;
  padding: 8px 22px calc(22px + var(--safe-b));
  box-shadow: var(--shadow);
}
.panel-bar { display: flex; justify-content: space-between; align-items: center; }
.panel-bar h2 { font-size: 28px; margin: 12px 0; }
.dates { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
label.field { display: flex; flex-direction: column; gap: 6px; font-size: 13px; color: var(--secondary); }
input[type="date"] {
  font-size: 16px;
  min-height: 48px;
  border: 0;
  border-radius: 12px;
  padding: 0 12px;
  background: color-mix(in srgb, var(--ink) 6%, transparent);
}
.segment { display: inline-flex; padding: 3px; border-radius: 999px; background: color-mix(in srgb, var(--ink) 8%, transparent); }
.segment button {
  border: 0;
  background: transparent;
  min-height: 36px;
  padding: 0 14px;
  border-radius: 999px;
  cursor: pointer;
  color: var(--ink);
}
.segment button[aria-selected="true"] { background: var(--surface); box-shadow: 0 1px 4px rgba(0, 0, 0, 0.12); }
.people { width: 100%; border-collapse: collapse; margin-top: 8px; }
.people th, .people td { text-align: left; padding: 10px 4px; border-bottom: 0.5px solid var(--line); }
.people th { color: var(--secondary); font-size: 12px; font-weight: 600; }
.switch {
  width: 51px;
  height: 31px;
  border: 0;
  border-radius: 999px;
  background: color-mix(in srgb, var(--ink) 18%, transparent);
  position: relative;
  cursor: pointer;
}
.switch[aria-pressed="true"] { background: #34c759; }
.switch i {
  position: absolute;
  top: 2px;
  left: 2px;
  width: 27px;
  height: 27px;
  border-radius: 50%;
  background: #fff;
  transition: transform 0.35s var(--ease);
}
.switch[aria-pressed="true"] i { transform: translateX(20px); }
.warn { color: #9a5b00; font-size: 14px; }
html[data-theme="dark"] .warn { color: #ffd60a; }
.row { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin: 16px 0; }

.toast {
  position: fixed;
  left: 50%;
  top: calc(72px + var(--safe-t));
  transform: translateX(-50%) translateY(-8px);
  background: var(--ink);
  color: var(--bg);
  border-radius: 999px;
  padding: 8px 14px;
  opacity: 0;
  pointer-events: none;
  z-index: 70;
  transition: opacity 0.35s var(--ease), transform 0.35s var(--ease);
}
.toast.show { opacity: 1; transform: translateX(-50%); }
.colophon {
  width: min(1120px, calc(100% - 48px));
  margin: 48px auto 0;
  color: var(--tertiary);
  font-size: 12px;
}
.checkline { display: flex; align-items: center; gap: 8px; color: var(--secondary); font-size: 15px; }

@supports ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
  .topbar, .view-switch, .bag, .confirm-card {
    background: var(--glass-sheen), var(--glass);
    -webkit-backdrop-filter: blur(42px) saturate(190%);
    backdrop-filter: blur(42px) saturate(190%);
    box-shadow: var(--glass-rim), var(--shadow);
  }
  .topbar::before, .view-switch::before, .bag::before, .confirm-card::before {
    content: "";
    position: absolute;
    inset: 0;
    border-radius: inherit;
    pointer-events: none;
    background: var(--glass-lens);
    z-index: 0;
  }
  .topbar > *, .view-switch > *, .confirm-card > *, .bag > svg { position: relative; z-index: 1; }
  .bag-count { z-index: 2; }
  .panel {
    background: color-mix(in srgb, var(--glass-solid) 82%, transparent);
    -webkit-backdrop-filter: blur(28px) saturate(160%);
    backdrop-filter: blur(28px) saturate(160%);
  }
  html[data-theme="dark"] .topbar,
  html[data-theme="dark"] .view-switch,
  html[data-theme="dark"] .bag,
  html[data-theme="dark"] .confirm-card {
    color: #fff;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.55);
  }
}
@media (prefers-reduced-transparency: reduce) {
  .topbar, .bag, .panel, .hero-dates, .view-switch, .confirm-card {
    background: var(--glass-solid) !important;
    -webkit-backdrop-filter: none !important;
    backdrop-filter: none !important;
    box-shadow: inset 0 0 0 0.5px var(--line), var(--shadow) !important;
    text-shadow: none;
  }
  .topbar::before, .view-switch::before, .bag::before, .confirm-card::before { display: none; }
}
@media (prefers-contrast: more) {
  .topbar, .bag, .panel, .view-switch, .confirm-card { background: var(--bg); box-shadow: inset 0 0 0 1px var(--ink); }
}
@media (forced-colors: active) {
  .topbar, .bag, .panel, .primary, .confirm-card { background: Canvas; color: CanvasText; border: 1px solid CanvasText; }
}
@media (prefers-reduced-motion: reduce) {
  .reveal, .view.is-active { opacity: 1; transform: none; animation: none; }
  .switch i, .toast, .confirm, .bag.is-bump { transition: none; animation: none; }
  html { scroll-behavior: auto; }
}

@media (max-width: 800px) {
  body { padding-bottom: calc(108px + var(--safe-b)); }
  .view-switch button { padding: 0 4px; font-size: 14px; }
  .chapter { width: min(1120px, calc(100% - 32px)); padding-top: 72px; }
  .hero-copy { width: min(1120px, calc(100% - 32px)); margin-bottom: calc(140px + var(--safe-b)); }
  .hero h1 { font-size: 52px; }
  .lede, .deck { font-size: 17px; }
  .stay, .day, .flight { grid-template-columns: 1fr; }
  .stay img, .day img { height: 220px; }
  .plan-row { grid-template-columns: 1fr 1fr; }
  .price { text-align: left; }
  .dates { grid-template-columns: 1fr; }
  .bag-line { grid-template-columns: 1fr; }
  .bag-line .line-price { justify-self: start; }
}
