/* Package picker. Phones: car on top (it stays put while you scroll), details under it.
   Wide screens: car on the left, the list on the right. */

.picker { min-height: 100vh; min-height: 100svh; background: var(--night); }

/* ---------- the car ---------- */
.view {
  position: sticky; top: 0; z-index: 2;
  /* svh = the height with Safari's bars showing, so the car area never jumps while scrolling.
     Short enough that the size switch and the package row fit on the first screen. */
  height: clamp(228px, 36vh, 330px); height: clamp(228px, 36svh, 330px);
  -webkit-user-select: none; user-select: none; -webkit-touch-callout: none;
  overflow: hidden;
  border-bottom: 1px solid var(--line);
}
#scene { position: absolute; inset: 0; width: 100%; height: 100%; display: block; touch-action: pan-y; cursor: grab; }
#scene:active { cursor: grabbing; }
.view__brand { position: absolute; left: 18px; top: calc(14px + env(safe-area-inset-top)); z-index: 3; }
.view__hint {
  position: absolute; right: 16px; top: calc(16px + env(safe-area-inset-top)); z-index: 3;
  color: var(--snow-2); font-size: .8125rem; pointer-events: none; transition: opacity .5s var(--ease);
}
.view__hint.is-gone { opacity: 0; }

/* Numbered dots sit on the car. On wide views each also gets a label, in a row above or below the car,
   listing the checklist items for that part. On narrow views the numbered list under the car does that. */
.leaders { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; z-index: 1; display: none; }
.leaders line { stroke: rgba(207, 174, 116, .7); stroke-width: 1; }
.labels { position: absolute; inset: 0; pointer-events: none; z-index: 2; }
.dot {
  position: absolute; left: 0; top: 0; width: 26px; height: 26px; margin: -13px 0 0 -13px; padding: 0;
  display: none; place-items: center; border-radius: 50%;
  border: 1.5px solid var(--brass); background: rgba(12, 12, 13, .88); color: var(--snow);
  font: 700 .8125rem/1 var(--display); cursor: pointer; pointer-events: auto; touch-action: manipulation;
  transition: background .2s var(--ease), color .2s var(--ease), opacity .2s var(--ease);
  will-change: transform;
}
.dot::after { content: ''; position: absolute; inset: -9px; }   /* bigger tap target */
.dot.is-on { display: grid; }
.dot.is-focus { background: var(--brass); color: #141414; }
.dot.is-dim { opacity: .45; }
.label {
  position: absolute; left: 0; top: 0; width: max-content; max-width: 214px;
  padding: 8px 11px 9px; border-radius: 12px;
  background: rgba(14, 14, 15, .86); border: 1px solid rgba(207, 174, 116, .4);
  -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px);
  display: none; pointer-events: auto;
  transition: opacity .25s var(--ease), border-color .2s var(--ease);
  will-change: transform;
}
.has-labels .label.is-on { display: block; }
.has-labels .leaders { display: block; }
.label.is-focus { border-color: var(--brass); }
.label.is-dim { opacity: .4; }
.label__head { display: flex; align-items: center; gap: 7px; padding: 0; border: 0; background: none; color: var(--snow); cursor: pointer; text-align: left; }
.label__head b { font: 700 .875rem/1.2 var(--display); letter-spacing: .01em; white-space: nowrap; }
.label__head i, .group__head i {
  flex: none; display: grid; place-items: center; width: 20px; height: 20px; border-radius: 50%;
  border: 1.5px solid var(--brass); font: 700 .6875rem/1 var(--display); font-style: normal; color: var(--snow);
}
.label ul { list-style: none; margin: 6px 0 0; padding: 0; }
.label li { position: relative; padding: 2px 0 2px 11px; color: #c9c9ce; font-size: .75rem; line-height: 1.32; }
.label li::before { content: ''; position: absolute; left: 1px; top: .62em; width: 4px; height: 4px; border-radius: 50%; background: var(--brass); }
.label li.is-extra { display: none; }
.label.is-open li.is-extra { display: block; }
.label__more { margin-top: 5px; padding: 3px 0; border: 0; background: none; color: var(--brass); font: 500 .75rem/1.2 var(--text); cursor: pointer; text-decoration: underline; text-underline-offset: 3px; }

/* ---------- the panel ---------- */
.panel { position: relative; z-index: 1; padding: 14px max(18px, env(safe-area-inset-right)) calc(128px + env(safe-area-inset-bottom)) max(18px, env(safe-area-inset-left)); }
.panel__head h1 { font-size: 1.375rem; }

/* size switch */
.sizes { margin-top: 12px; display: grid; grid-template-columns: 1fr 1.25fr 1fr; gap: 0; padding: 4px; border-radius: 999px; background: var(--night-2); border: 1px solid var(--line); }
.sizes button {
  min-height: 44px; border: 0; border-radius: 999px; background: transparent; color: #b4b4b9;
  font: 500 .9375rem/1 var(--text); cursor: pointer; touch-action: manipulation; transition: background .2s var(--ease), color .2s var(--ease);
}
.sizes button[aria-checked="true"] { background: var(--snow); color: #1d1d1f; }
.sizes__hint { margin-top: 6px; color: #b4b4b9; font-size: .8125rem; text-align: center; }
/* size first (2026-11-11): before a size is picked, the hint asks for one */
.sizes__hint.is-ask { color: var(--snow); font-weight: 500; }

/* package names: a row you can swipe on phones */
.list {
  margin: 12px -18px 0; padding: 0 18px 4px; scroll-padding-inline: 18px;
  display: flex; gap: 8px; overflow-x: auto; overscroll-behavior-x: contain; scroll-snap-type: x proximity; scrollbar-width: none; -webkit-overflow-scrolling: touch;
  /* the row fades out at the right edge, so it is clear there is more to swipe to */
  -webkit-mask-image: linear-gradient(90deg, #000 0, #000 calc(100% - 44px), rgba(0, 0, 0, .25) 100%); mask-image: linear-gradient(90deg, #000 0, #000 calc(100% - 44px), rgba(0, 0, 0, .25) 100%);
}
.list::-webkit-scrollbar { display: none; }
.pkg {
  flex: none; scroll-snap-align: center;
  display: flex; flex-direction: column; align-items: flex-start; gap: 4px;
  justify-content: center; min-height: 58px; padding: 9px 16px 10px; border-radius: 16px; border: 1px solid rgba(245, 245, 247, .22);
  background: transparent; color: var(--snow); text-align: left; cursor: pointer; touch-action: manipulation;
  transition: background .2s var(--ease), border-color .2s var(--ease);
}
.pkg__name { font: 500 1rem/1.15 var(--display); white-space: nowrap; }
.pkg__price { font-size: .875rem; color: #b4b4b9; }
.pkg[aria-selected="true"] { background: var(--snow); border-color: var(--snow); color: #1d1d1f; }
.pkg[aria-selected="true"] .pkg__price { color: #55555a; }

/* the chosen package */
.detail { margin-top: 18px; }
.detail__tag { display: inline-block; margin-bottom: 8px; font: 500 .8125rem/1 var(--text); color: var(--brass); }
.detail h2 { font-size: clamp(1.5rem, 6vw, 2rem); font-weight: 700; }
.detail__line { margin-top: 8px; color: var(--snow-2); font-size: 1.0625rem; line-height: 1.4; }
.detail__buy { margin-top: 16px; display: flex; align-items: center; justify-content: space-between; gap: 14px; flex-wrap: wrap; }
.detail__price { font: 700 2.5rem/1 var(--display); letter-spacing: -0.03em; }
.detail__meta { margin-top: 6px; color: var(--snow-2); font-size: .875rem; }
.detail__price.is-ask { font: 700 1.5rem/1.2 var(--display); letter-spacing: -0.015em; }
.detail__buy .btn { flex: 1 1 150px; max-width: 240px; }
.detail h3 { margin-top: 22px; font: 500 .8125rem/1 var(--text); letter-spacing: .08em; text-transform: uppercase; color: var(--snow-2); }
.groups__hint { margin-top: 8px; color: #a1a1a6; font-size: .8125rem; line-height: 1.4; }
.groups { list-style: none; margin: 10px 0 0; padding: 0; border-top: 1px solid var(--line); }
.group { padding: 12px 0 12px; border-bottom: 1px solid var(--line); transition: background .2s var(--ease); }
.group__head { display: flex; align-items: center; gap: 10px; width: 100%; padding: 2px 0; border: 0; background: none; color: var(--snow); cursor: pointer; text-align: left; touch-action: manipulation; }
.group__head i { width: 24px; height: 24px; font-size: .8125rem; transition: background .2s var(--ease), color .2s var(--ease); }
.group__head b { font: 700 1rem/1.2 var(--display); }
.group ul { list-style: none; margin: 8px 0 0; padding: 0 0 0 34px; }
.group li { position: relative; padding: 3px 0; font-size: .9375rem; line-height: 1.4; color: #dcdce0; }
.group li::before { content: ''; position: absolute; left: -14px; top: .72em; width: 5px; height: 5px; border-radius: 50%; background: var(--brass); }
.group.is-focus .group__head i { background: var(--brass); color: #141414; }
.group.is-focus .group__head b { color: var(--brass); }
.includes { margin: 10px 0 0; padding: 0; list-style: none; }
.includes li { position: relative; padding: 5px 0 5px 22px; font-size: .9375rem; line-height: 1.4; }
.includes li::before { content: ''; position: absolute; left: 3px; top: 11px; width: 9px; height: 5px; border-left: 1.5px solid var(--brass); border-bottom: 1.5px solid var(--brass); transform: rotate(-45deg); }
.notes { margin-top: 10px; color: #c9c9ce; font-size: .875rem; line-height: 1.45; }
.notes p + p { margin-top: 6px; }
.fine { margin-top: 22px; color: #a1a1a6; font-size: .8125rem; line-height: 1.45; }
.nojs { padding: 20px; } .nojs a { color: var(--brass); }

/* ---------- wide screens: car left, list right ---------- */
/* Before the car has loaded: a calm line of text where it will be. The page's words and buttons are already usable. */
.view__loading { position: absolute; inset: 0; display: grid; place-items: center; color: var(--snow-2); font-size: .9375rem; pointer-events: none; animation: breathe 1.8s ease-in-out infinite; }
@keyframes breathe { 50% { opacity: .45; } }
.view.is-ready .view__loading { display: none; }
.view:not(.is-ready) .dot, .view:not(.is-ready) .view__hint { visibility: hidden; }
.view.is-failed { display: none; }
#scene { opacity: 0; transition: opacity .5s var(--ease); }
.view.is-ready #scene { opacity: 1; }

/* Phones: the chosen package, its price and the booking button stay at the bottom of the screen, in thumb reach. */
.bar {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 6;
  display: grid; gap: 8px;
  padding: 10px max(16px, env(safe-area-inset-right)) calc(10px + env(safe-area-inset-bottom)) max(16px, env(safe-area-inset-left));
  background: #0e0e0f; border-top: 1px solid rgba(245, 245, 247, .2);
  box-shadow: 0 -14px 24px -8px rgba(0, 0, 0, .7);
}
.bar__info { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; }
.bar__info b { font: 700 .9375rem/1.2 var(--display); }
.bar__info span { flex: none; color: var(--snow); font-size: .9375rem; }
.bar .btn { width: 100%; min-height: 50px; font-weight: 600; }
.detail__buy .btn { display: none; }   /* the bar has the button on phones */

/* A phone on its side: car on the left, everything else scrolls on the right. */
@media (orientation: landscape) and (max-height: 500px) and (max-width: 899px) {
  .picker { display: grid; grid-template-columns: 46% minmax(0, 1fr); align-items: start; }
  .view { height: 100vh; height: 100svh; border-bottom: 0; border-right: 1px solid var(--line); }
  .panel { padding-top: 12px; padding-bottom: calc(84px + env(safe-area-inset-bottom)); }
  .bar { left: 46%; grid-template-columns: minmax(0, 1fr) auto; align-items: center; padding-top: 8px; padding-bottom: calc(8px + env(safe-area-inset-bottom)); }
  .bar__info { flex-direction: column; align-items: flex-start; gap: 2px; }
  .bar .btn { width: auto; min-height: 44px; padding: 0 28px; }
}

@media (min-width: 900px) {
  .bar { display: none; }
  .detail__buy .btn { display: inline-flex; }
  .picker { display: grid; grid-template-columns: minmax(0, 1fr) 440px; height: 100vh; height: 100dvh; overflow: hidden; }
  .view { position: relative; height: auto; min-height: 0; border-bottom: 0; border-right: 1px solid var(--line); }
  .panel__head h1 { font-size: 2.25rem; }
  .list { -webkit-mask-image: none; mask-image: none; }
  .pkg { min-height: 0; }
  #scene { touch-action: none; }
  .view__brand { left: 32px; top: 26px; font-size: 1.125rem; }
  .view__hint { right: auto; left: 32px; top: auto; bottom: 26px; }
  .panel { overflow-y: auto; padding: 30px 30px 36px; }
  .panel__head h1 { font-size: 2.25rem; }
  .list { margin: 20px 0 0; padding: 0; flex-direction: column; gap: 0; overflow: visible; border-top: 1px solid var(--line); }
  .pkg { flex-direction: row; align-items: baseline; justify-content: space-between; width: 100%; padding: 13px 12px; border: 0; border-bottom: 1px solid var(--line); border-radius: 0; }
  .pkg:hover { background: rgba(245, 245, 247, .05); }
  .pkg__name { font-size: 1.0625rem; }
  .pkg__price { font-size: .9375rem; font-variant-numeric: tabular-nums; }
  .pkg[aria-selected="true"] { background: var(--snow); border-radius: 12px; border-color: transparent; }
  .detail { margin-top: 22px; }
}
@media (min-width: 900px) and (max-height: 760px) {
  .panel { padding-top: 20px; }
  .pkg { padding: 9px 12px; }
}
