/* HK Powergrade, the store page. Loaded after hk.css: same tokens, same
   controls, same rule that nothing pins. Only what this page adds lives here. */

.store .bar__mark { opacity: 1; translate: 0 0; }
/* the bar's button waits until the hero's own button has left the screen */
.store .bar .btn { opacity: 0; visibility: hidden; translate: 0 -6px; transition: opacity 260ms var(--sc-ease-out), translate 260ms var(--sc-ease-out), visibility 0s 260ms, background-color 160ms var(--sc-ease-out), transform 140ms var(--sc-ease-out); }
.store.past-hero .bar .btn { opacity: 1; visibility: visible; translate: 0 0; transition-delay: 0s; }
.ico--up { rotate: -45deg; }

/* ------------------------------------------------- product --------------- */
/* An ordered shop window that fills the first screen: the pack and the copy
   share one row at the pack's height, and the frames take whatever height is
   left as one row that scrolls sideways. --u keeps the pack in proportion on
   short, wide windows. */
.pg {
  --u: min(1vw, 1.6svh); --pack: calc(var(--u) * 27);
  --pad-t: clamp(0.5rem, 2svh, 1.5rem); --mid: clamp(1.25rem, 4svh, 2.75rem); --pad-b: clamp(1rem, 3svh, 2rem);
  --still-h: max(11rem, calc(100svh - var(--bar-h) - var(--pad-t) - var(--pack) - var(--mid) - var(--pad-b)));
  position: relative; min-height: 100svh; padding: calc(var(--bar-h) + var(--pad-t)) 0 var(--pad-b);
}
.pg__top { display: grid; grid-template-columns: var(--pack) minmax(0, 1fr) auto; column-gap: clamp(1.5rem, 3.2vw, 4rem); padding-inline: var(--g); }
.pg__pack { aspect-ratio: 1; overflow: hidden; border-radius: var(--r); background: var(--sc-surface); box-shadow: 0 0 0 1px var(--sc-hairline); }
.pg__pack img, .again__pack img { width: 100%; height: 100%; object-fit: cover; }
/* the name sits on the pack's top edge and the price on its bottom edge */
.pg__copy { display: flex; flex-direction: column; justify-content: space-between; }
.pg__title { font-size: clamp(2.8rem, calc(var(--u) * 4.9), 7rem); line-height: 0.9; }
.pg__title span, .why__title span, .one__title span { display: block; }
.pg__line { margin-top: var(--sc-5); font-size: var(--sc-t-lg); line-height: 1.4; max-width: 38ch; text-wrap: balance; }
.pg__buy { display: flex; align-items: center; gap: var(--sc-5); }
.pg__price { font-family: var(--sc-font-display); font-stretch: 112%; font-weight: 600; font-size: var(--sc-t-2xl); line-height: 1; letter-spacing: -0.03em; }

.pg__nav { align-self: end; display: flex; gap: var(--sc-2); }
.pg__arrow { width: 2.75rem; height: 2.75rem; display: grid; place-items: center; border: 0; border-radius: var(--r); background: color-mix(in oklab, var(--sc-ink) 9%, transparent); color: var(--sc-ink); transition: background-color 160ms var(--sc-ease-out), opacity 160ms var(--sc-ease-out), scale 120ms var(--sc-ease-out); }
.pg__arrow:active { scale: 0.95; }
.pg__arrow:disabled { opacity: 0.32; cursor: default; }
@media (hover: hover) and (pointer: fine) { .pg__arrow:not(:disabled):hover { background: color-mix(in oklab, var(--sc-ink) 18%, transparent); } }
.ico--right { rotate: 45deg; }
.ico--left { rotate: -135deg; }

/* rows that scroll sideways: the product frames, and the looks on phones */
.pg__reel { display: flex; gap: var(--gap); overflow-x: auto; overflow-y: hidden; scroll-snap-type: x mandatory; overscroll-behavior-x: contain; scrollbar-width: none; }
.pg__reel::-webkit-scrollbar { display: none; }
.pg__reel { margin-top: var(--mid); padding-inline: var(--g); scroll-padding-inline: var(--g); }
.pg__still { flex: none; width: calc(var(--still-h) * 16 / 9); scroll-snap-align: start; }
/* inside the sideways row a swipe on the frame moves the row: on touch only the handle drags the divider */
.pg__still { touch-action: auto; }

/* ------------------------------------------------- inside ---------------- */
.kit { position: relative; z-index: 2; display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: var(--gap); align-items: start; padding: clamp(3.5rem, 11vh, 8rem) var(--g) 0; }
.kit__head { grid-column: 1 / 6; }
.kit__title { font-size: var(--sc-t-3xl); max-width: 9ch; }
.kit__head .sc-lede { margin-top: var(--sc-5); max-width: 30ch; }
.kit__list { grid-column: 7 / 13; list-style: none; margin: 0; padding: 0; }
.kit__list li { display: grid; grid-template-columns: 9rem 1fr; align-items: baseline; padding: 0.14em 0; font-family: var(--sc-font-display); font-stretch: 112%; font-weight: 600; font-size: var(--sc-t-2xl); line-height: 1.12; letter-spacing: -0.03em; }
.kit__list span { font-family: var(--sc-font-mono); font-stretch: normal; font-weight: 400; font-size: var(--sc-t-xs); letter-spacing: var(--sc-track-wide); text-transform: uppercase; color: var(--sc-ink-soft); }
.kit__list li:last-child { margin-top: 0.5em; }

/* ------------------------------------------------- why ------------------- */
.why { position: relative; margin-top: clamp(4rem, 13vh, 10rem); }
.why__film { position: relative; aspect-ratio: 3 / 1; overflow: clip; }
.why__film::after { content: ""; position: absolute; inset: 55% 0 0 0; pointer-events: none; background: linear-gradient(transparent, var(--sc-canvas)); }
.why__copy { position: relative; z-index: 2; padding-inline: var(--g); margin-top: clamp(-6rem, -5vw, -1.5rem); }
.why__title { font-size: clamp(3rem, 8.6vw, 10.5rem); line-height: 0.9; }
.why__copy .sc-lede { margin-top: var(--sc-6); max-width: 40ch; }

/* ------------------------------------------------- flexible -------------- */
.free { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: var(--gap); align-items: start; padding-inline: var(--g); margin-top: clamp(5rem, 16vh, 11rem); }
.free__copy { grid-column: 1 / 6; grid-row: 1; padding-top: 3vw; }
.free__title { font-size: clamp(2.4rem, 4.9vw, 6rem); line-height: 0.94; max-width: 10ch; }
.free__copy .sc-lede { margin-top: var(--sc-5); max-width: 34ch; }
.free__clip { position: relative; aspect-ratio: 16 / 9; overflow: hidden; border-radius: var(--r); background: var(--sc-surface); box-shadow: 0 18px 50px -18px rgb(0 0 0 / 0.7), var(--sc-edge); }
.free__clip video { width: 100%; height: 100%; object-fit: cover; }
.free__clip--1 { grid-column: 6 / 13; grid-row: 1; }
.free__clip--2 { grid-column: 2 / 7; grid-row: 2; margin-top: clamp(1rem, 2.4vw, 3rem); }

/* ------------------------------------------------- any camera ------------ */
.any { display: grid; grid-template-columns: minmax(0, 1fr) minmax(15rem, 27vw); gap: clamp(2rem, 5vw, 6rem); align-items: start; padding-inline: var(--g); margin-top: clamp(5rem, 16vh, 11rem); }
.any__stage { display: grid; align-items: start; }
.any__stage img { width: 100%; height: auto; border-radius: var(--r); box-shadow: 0 18px 50px -18px rgb(0 0 0 / 0.7); }
.any__title { font-size: var(--sc-t-3xl); max-width: 8ch; }
.any__index .sc-lede { margin-top: var(--sc-5); max-width: 30ch; }
.any__index .work__names { margin-top: var(--sc-7); }

/* ------------------------------------------------- one tree -------------- */
.one { padding-inline: var(--g); margin-top: clamp(5rem, 16vh, 11rem); }
.one__title { font-size: clamp(2.8rem, 7.6vw, 9.5rem); line-height: 0.9; }
.one__head .sc-lede { margin-top: var(--sc-6); max-width: 42ch; }
.one__nodes { margin-top: clamp(2.5rem, 8vh, 5rem); overflow: hidden; border-radius: var(--r); background: var(--sc-surface); }
.one__nodes img { display: block; width: 100%; height: auto; }

/* the log frame sits over the three looks; they leave from behind it as the
   block travels up the screen (store.js), and rest in a row underneath */
.fan { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--gap); margin-top: clamp(2.5rem, 8vh, 5rem); }
.fan__log { position: relative; z-index: 2; grid-column: 1 / -1; justify-self: center; width: 38%; margin-bottom: clamp(1.5rem, 5vh, 3.5rem); }
.fan__log figcaption { margin-bottom: var(--sc-3); }
.fan__look figcaption { margin-top: var(--sc-3); opacity: var(--e, 1); }
.fan__frame { aspect-ratio: 16 / 9; overflow: hidden; border-radius: var(--r); background: var(--sc-surface); box-shadow: 0 18px 50px -18px rgb(0 0 0 / 0.7); will-change: transform; }
.fan__frame img { width: 100%; height: 100%; object-fit: cover; }
.fan .take__name { text-shadow: none; }

/* ------------------------------------------------- reviews --------------- */
.said { padding-inline: var(--g); margin-top: clamp(5rem, 16vh, 11rem); }
.said__title { font-size: var(--sc-t-3xl); }
.said__flag { display: none; margin-top: var(--sc-3); font-family: var(--sc-font-mono); font-size: var(--sc-t-xs); letter-spacing: var(--sc-track-wide); text-transform: uppercase; color: var(--sc-ink-soft); }
.said[data-sample] .said__flag { display: block; }
.said__grid { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: var(--gap); row-gap: clamp(2rem, 6vh, 4rem); margin-top: clamp(2.5rem, 8vh, 5rem); }
.quote blockquote { margin: 0; font-family: var(--sc-font-display); font-stretch: 112%; font-weight: 500; font-size: var(--sc-t-xl); line-height: 1.12; letter-spacing: -0.025em; text-wrap: balance; }
.quote figcaption { margin-top: var(--sc-4); color: var(--sc-ink-soft); font-size: var(--sc-t-sm); }
.quote figcaption strong { display: block; color: var(--sc-ink); font-weight: 600; }
.quote--1 { grid-column: 1 / 9; }
.quote--1 blockquote { font-size: var(--sc-t-2xl); line-height: 1.06; }
.quote--2 { grid-column: 9 / 13; margin-top: 9vw; }
.quote--3 { grid-column: 3 / 8; }

/* ------------------------------------------------- again ----------------- */
.again { position: relative; margin-top: clamp(5rem, 16vh, 11rem); padding: 0 var(--g) 0.9rem; overflow: clip; }
.again__name { font-family: var(--sc-font-display); font-stretch: 118%; font-weight: 700; text-transform: uppercase; font-size: var(--name-vw, 9.4vw); line-height: 0.86; letter-spacing: -0.045em; white-space: nowrap; }
.again__name span { display: block; width: max-content; will-change: transform; }
.again__row { display: flex; justify-content: space-between; align-items: flex-end; gap: var(--gap); margin-top: clamp(1rem, 2.2vw, 2.5rem); }
.again__title { font-size: clamp(2.4rem, 5.6vw, 7.5rem); line-height: 0.9; max-width: 9ch; }
.again__ask .btn { margin-top: clamp(1.1rem, 3.5svh, 2.4rem); }
.again__pack { position: relative; flex: none; width: clamp(11rem, 22vw, 23rem); aspect-ratio: 1; margin-right: clamp(0rem, 5vw, 7rem); overflow: hidden; border-radius: var(--r); background: var(--sc-surface); box-shadow: 0 40px 90px -30px rgb(0 0 0 / 0.9); will-change: transform; }
.foot { margin-top: clamp(1.5rem, 5vh, 3rem); }

/* ------------------------------------------------- phones ---------------- */
/* On phones the whole page is centred, and the rows of frames scroll sideways. */
@media (max-width: 860px) {
  .store main { text-align: center; }
  .store main :is(.sc-display, .sc-lede) { margin-inline: auto; }
  .store .work__names, .store .foot, .store .foot ul { justify-content: center; }

  .pg { --pack: min(64vw, 30svh); min-height: 0; padding-bottom: 0; }
  .pg__top { grid-template-columns: 1fr; justify-items: center; row-gap: var(--sc-4); }
  .pg__pack { width: var(--pack); }
  .pg__title { font-size: var(--sc-t-3xl); }
  .pg__line { margin-inline: auto; max-width: 24ch; }
  .pg__buy { justify-content: center; margin-top: var(--sc-6); }
  .pg__nav { display: none; }
  .pg__reel, .fan { padding-inline: 9vw; scroll-padding-inline: 9vw; }
  .pg__reel { margin-top: var(--sc-7); }
  .pg__still, .fan > * { width: 82vw; scroll-snap-align: center; }

  .kit { grid-template-columns: 1fr; row-gap: var(--sc-6); padding-top: var(--sc-9); }
  .kit__head, .kit__list { grid-column: 1; }
  .kit__list li { grid-template-columns: 1fr; font-size: var(--sc-t-xl); padding: 0.3em 0; }

  .why { margin-top: var(--sc-9); }
  .why__film { aspect-ratio: 16 / 10; }
  .why__copy { margin-top: -2rem; }

  .free, .any, .one, .said, .again { margin-top: var(--sc-9); }
  .free { grid-template-columns: 1fr; row-gap: var(--gap); }
  .free__copy, .free__clip--1, .free__clip--2 { grid-column: 1; grid-row: auto; margin-top: 0; padding-top: 0; }
  .free__copy { margin-bottom: var(--sc-5); }

  .any { grid-template-columns: 1fr; }
  .any__index { order: -1; }
  .any__index .work__names { margin-top: var(--sc-5); }

  .one__nodes img { height: 8.5rem; object-fit: cover; object-position: 46% 50%; }
  /* log, then the looks: one row, edge to edge, a frame at a time */
  .fan { display: flex; margin-inline: calc(var(--g) * -1); overflow-x: auto; overflow-y: hidden; scroll-snap-type: x mandatory; overscroll-behavior-x: contain; scrollbar-width: none; }
  .fan::-webkit-scrollbar { display: none; }
  .fan > * { flex: none; margin: 0; }
  .fan__log { display: flex; flex-direction: column-reverse; justify-content: flex-end; }
  .fan__log figcaption { margin: var(--sc-3) 0 0; }

  .said__grid { grid-template-columns: 1fr; }
  .quote--1, .quote--2, .quote--3 { grid-column: 1; margin-top: 0; }
  .quote--1 blockquote { font-size: var(--sc-t-xl); }

  .again__name { font-size: var(--name-vw, 9vw); }
  .again__name span { margin-inline: auto; }
  .again__row { flex-direction: column-reverse; align-items: center; gap: var(--sc-5); margin-top: var(--sc-5); }
  .again__pack { width: 56vw; margin-right: 0; }
  .again__title { font-size: var(--sc-t-3xl); max-width: none; }
}

@media (prefers-reduced-motion: reduce) {
  .store .bar .btn { transition-duration: 1ms; }
}
