/* Clavelio — learn page stage: one room, one wall per chapter, light rising from night to morning.
   Loaded only by sections/clavelio-stage.liquid. Colours of the room are written by clavelio-stage.js from the
   light level; the defaults below are the night state (also the no-JS state). */

.cl-stage {
  --u: min(1vw, 1.65vh);
  --P: calc(62 * var(--u));
  --w: calc(100 * var(--u));
  --h: calc(62 * var(--u));
  --R: calc(var(--w) * 0.851);
  --st-bg: #06080c; --st-wall: #121721; --st-floor: #0c1018; --st-ceil: #0a0d13; --st-glow: 0;
  --st-ink: #FAF8F4; --st-ink-2: rgb(250 248 244 / 0.62); --st-line: rgb(250 248 244 / 0.22);
  --st-ease: cubic-bezier(0.7, 0, 0.2, 1);
  --st-serif: var(--cl-font-display, Georgia, serif);
  --st-text: var(--cl-font-serif, Georgia, serif);
  --st-sans: var(--cl-font-ui, system-ui, sans-serif);
  --st-left: max(var(--cl-gutter, 32px), calc((100vw - var(--cl-max, 1200px)) / 2));
  position: relative; background: var(--st-bg); color: var(--st-ink); font-family: var(--st-sans);
}
.cl-stage[data-ink='dark'] { --st-ink: #161616; --st-ink-2: rgb(22 22 22 / 0.66); --st-line: rgb(22 22 22 / 0.2); }
/* the room starts under the announcement bar and the header, so it fills the screen from the first frame */
#MainContent > .shopify-section:first-child > .cl-stage { margin-top: calc(-1 * var(--st-top, var(--cl-hd-h, 64px))); }
/* the site header stays on top of the room, transparent, in the room's ink */
.cl-hd.cl-hd--stage { --fg: var(--cl-on-night); --fg-2: var(--cl-on-night-2); background-color: transparent; border-bottom-color: transparent; color: var(--cl-on-night); }
.cl-hd.cl-hd--stage.is-dark { --fg: var(--cl-ink); --fg-2: var(--cl-ink-2); color: var(--cl-ink); }
.cl-hd.cl-hd--stage.is-hidden { transform: none; }
body:has(.cl-stage) #header-group > .shopify-section:first-child:not(:has(.cl-hd)) { position: relative; z-index: 41; }

/* track and pin: one viewport of scroll per chapter, plus one more in which the next section slides over the room
   (with JS). Each chapter is a snap point the browser won't skip; the sections after the stage snap at their top. */
.cl-stage__track { position: relative; }
/* as the room steps back under the Questions sheet, the margin it leaves is day-white, not black */
.cl-stage.is-js .cl-stage__track { background: var(--cl-day, #FAF8F4); }
/* one screen of scroll per chapter (K in clavelio-stage.js), plus one for the last chapter and one for the sheet */
.cl-stage.is-js .cl-stage__track { height: calc((var(--n) + 1) * 100svh); }
.cl-stage__snap { position: absolute; left: 0; width: 1px; height: 100svh; top: calc(var(--i) * 100svh); pointer-events: none; }
.cl-snap { scroll-snap-type: y mandatory; }
.cl-snap .cl-stage.is-js .cl-stage__snap { scroll-snap-align: start; scroll-snap-stop: always; }
.cl-snap #MainContent > .shopify-section:has(.cl-stage) + .shopify-section { scroll-snap-align: start; }
#MainContent > .shopify-section:has(.cl-stage.is-js) + .shopify-section { position: relative; z-index: 5; margin-top: -100svh; }
#MainContent > .shopify-section:has(.cl-stage.is-js) + .shopify-section > :not(link, script, style) { min-height: 100svh; box-sizing: border-box; }
.cl-stage__pin { position: relative; height: 100svh; overflow: hidden; color: var(--st-ink); transition: color 0.7s ease; }
.cl-stage.is-js .cl-stage__pin { position: sticky; top: 0; transform: scale(calc(1 - var(--sheet, 0) * 0.06)); transform-origin: 50% 0; }
/* under the Questions sheet the room fades into morning daylight (not to black), so dark room and light page meet softly */
.cl-stage__pin::after { content: ''; position: absolute; inset: 0; z-index: 6; background: var(--cl-day, #FAF8F4); opacity: calc(var(--sheet, 0) * var(--sheet, 0) * 0.9); pointer-events: none; }

/* the room */
.cl-stage__room { position: absolute; inset: 0; perspective: var(--P); overflow: hidden; pointer-events: none; transition: opacity 1.4s ease; }
.cl-stage.is-js:not(.is-in) .cl-stage__room { opacity: 0; }
.cl-stage__world {
  position: absolute; left: 50%; top: 50%; width: 0; height: 0; transform-style: preserve-3d;
  transform: translateZ(var(--P)) translate3d(0px, 0px, calc(-46 * var(--u))) rotateX(-3deg) rotateY(-46deg);
  will-change: transform;
}
/* Shading: each wall is one flat tone, darker the more it turns away from you (--shade, set by the script), with
   soft contact shadow only where it meets the next wall, the floor and the ceiling. Eased stops, so no visible bands. */
.cl-stage__wall, .cl-stage__plane { position: absolute; transform-style: preserve-3d; }
.cl-stage__wall {
  left: calc(var(--w) / -2); top: calc(var(--h) / -2); width: var(--w); height: var(--h);
  transform: rotateY(calc(var(--i) * -360deg / var(--n))) translateZ(calc(var(--w) * var(--ap) * -1));
  background-color: color-mix(in srgb, var(--st-wall), #000 calc(var(--shade, 0) * 100%));
  background-image:
    linear-gradient(to right, rgb(0 0 0 / 0.14), rgb(0 0 0 / 0.07) 1.5%, rgb(0 0 0 / 0.03) 4%, rgb(0 0 0 / 0.01) 7%, transparent 10%, transparent 90%, rgb(0 0 0 / 0.01) 93%, rgb(0 0 0 / 0.03) 96%, rgb(0 0 0 / 0.07) 98.5%, rgb(0 0 0 / 0.14)),
    linear-gradient(to bottom, rgb(0 0 0 / 0.08), rgb(0 0 0 / 0.03) 3%, transparent 8%, transparent 90%, rgb(0 0 0 / 0.04) 96%, rgb(0 0 0 / 0.12));
}
.cl-stage__plane { left: calc(var(--R) * -1); top: calc(var(--R) * -1); width: calc(var(--R) * 2); height: calc(var(--R) * 2); }
.cl-stage__plane--floor {
  transform: translateY(calc(var(--h) / 2)) rotateX(90deg);
  background: radial-gradient(closest-side, rgb(246 190 120 / calc(var(--st-glow) * 0.45)), rgb(246 190 120 / calc(var(--st-glow) * 0.12)) 60%, transparent), var(--st-floor);
}
.cl-stage__plane--ceil {
  transform: translateY(calc(var(--h) / -2)) rotateX(-90deg);
  background: radial-gradient(closest-side, rgb(255 255 255 / 0.03), rgb(0 0 0 / 0.08) 70%, rgb(0 0 0 / 0.14)), var(--st-ceil);
}
.cl-stage__photo {
  position: absolute; left: 21%; width: 58%; top: 18%; aspect-ratio: 16 / 9; overflow: hidden;
  background: rgb(255 255 255 / 0.05); outline: 1px solid rgb(0 0 0 / 0.14);
}
.cl-stage__photo > * { width: 100%; height: 100%; aspect-ratio: auto; }
.cl-stage__photo img, .cl-stage__photo video { width: 100%; height: 100%; object-fit: cover; }
/* a photo on a wall you see at an angle takes that wall's light: dimmer at night, almost full in daylight */
.cl-stage__photo :is(img, video) { filter: brightness(calc(1 - var(--shade, 0) * (2.8 - 2 * var(--st-L, 0)))); }
.cl-stage__photo .cl-chip, .cl-stage__photo button { display: none; }
.cl-stage__photo .cl-ph { background: rgb(255 255 255 / 0.06); }

/* WebGL room: the canvas replaces the CSS walls; film grain and a lens vignette over it */
.cl-room-gl { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
.cl-stage.is-gl .cl-stage__world { display: none; }
.cl-stage.is-gl .cl-stage__room::after {
  content: ''; position: absolute; inset: 0; pointer-events: none; opacity: 0.045; mix-blend-mode: screen;
  background-image: var(--st-grain); background-size: 160px 160px;
}
.cl-stage.is-gl .cl-stage__room::before { content: ''; position: absolute; inset: 0; z-index: 1; pointer-events: none; background: radial-gradient(130% 100% at 50% 45%, transparent 62%, rgb(0 0 0 / 0.32)); }

/* page title, links */
.cl-stage__h1 { position: absolute; width: 1px; height: 1px; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.cl-stage a, .cl-stage button { color: inherit; }
.cl-stage button { background: none; border: 0; padding: 0; cursor: pointer; font: inherit; }
.cl-stage__read, .cl-stage__close {
  font-size: 0.9375rem; font-weight: 500; text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 6px;
  text-decoration-color: var(--st-line); transition: text-decoration-color 0.3s ease;
}
.cl-stage__read:focus-visible { text-decoration-color: currentColor; }
@media (hover: hover) { .cl-stage__read:hover, .cl-stage__close:hover { text-decoration-color: currentColor; } }
.cl-stage :focus-visible { outline: 1px solid currentColor; outline-offset: 5px; }

/* the clock display */
.cl-stage__time {
  position: absolute; z-index: 2; left: 50%; top: calc(var(--st-top, 64px) + 4px); transform: translateX(-50%); margin: 0; display: flex; align-items: flex-start;
  font-size: clamp(3rem, 5.6vw, 6.25rem); line-height: 1; font-weight: 200; letter-spacing: -0.03em; font-variant-numeric: tabular-nums; pointer-events: none;
}
.cl-stage__digit { display: block; height: 1em; overflow: hidden; }
.cl-stage__reel { display: block; transition: transform 1.1s var(--st-ease); }
.cl-stage__reel > span { display: block; height: 1em; }
.cl-stage__digit:nth-child(1) .cl-stage__reel { transition-delay: 0.08s; }
.cl-stage__colon { display: block; height: 1em; margin: -0.04em 0.02em 0; animation: cl-stage-blink 2s steps(1) infinite; }
@keyframes cl-stage-blink { 50% { opacity: 0.25; } }

/* chapters: short text bottom left; lines roll in from below and out to the top */
.cl-stage__chapters { position: absolute; z-index: 3; left: var(--st-left); bottom: 104px; width: min(27rem, 29vw); }
.cl-stage__ch { position: absolute; left: 0; bottom: 0; width: 100%; visibility: hidden; transition: visibility 0s linear 0.9s; }
.cl-stage__ch.is-on { visibility: visible; transition: none; }
.cl-stage__line { display: block; overflow: hidden; padding-bottom: 0.08em; }
.cl-stage__line > span { display: block; transform: translateY(108%); transition: transform 0.45s var(--st-ease); }
.cl-stage__ch.is-past .cl-stage__line > span { transform: translateY(-108%); }
.cl-stage__ch.is-on .cl-stage__line > span { transform: none; transition-duration: 0.85s; transition-delay: 0.3s; }
.cl-stage__ch.is-on .cl-stage__title .cl-stage__line > span { transition-delay: 0.38s; }
.cl-stage__ch.is-on .cl-stage__short .cl-stage__line > span { transition-delay: 0.46s; }
.cl-stage__ch.is-on .cl-stage__read .cl-stage__line > span { transition-delay: 0.54s; }
.cl-stage__title { margin: 0 0 14px; font-family: var(--st-serif); font-weight: 400; font-size: clamp(1.75rem, 2.5vw, 2.75rem); line-height: 1.05; letter-spacing: -0.015em; }
.cl-stage__short { margin: 0 0 20px; font-size: 1.0625rem; line-height: 1.45; color: var(--st-ink-2); max-width: 30em; }
.cl-stage__read { display: inline-block; }

/* Read more: the chapter opens in place */
.cl-stage__more { display: none; }
.cl-stage__more:focus { outline: none; }
.cl-stage__close { display: block; margin: 28px 0 0; }
.cl-stage.is-open .cl-stage__chapters { bottom: 96px; }
.cl-stage.is-open .cl-stage__ch.is-on {
  max-height: calc(100svh - 196px); overflow: auto; overscroll-behavior: contain; scrollbar-width: thin;
  margin: 0 -28px -28px; width: calc(100% + 56px); padding: 28px;
  /* no separate box: a warm shade of the room itself, with feathered edges (the spread shadow in the same colour),
     so the text reads as lying in the room's shadow. Light chapters (dark ink) get the same in warm daylight. */
  --pn: rgb(16 12 9 / 0.74);
  background: var(--pn); box-shadow: 0 0 56px 28px var(--pn); border-radius: 24px;
  backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
}
.cl-stage[data-ink='dark'].is-open .cl-stage__ch.is-on { --pn: rgb(247 241 231 / 0.8); }
.cl-stage.is-open .cl-stage__ch.is-on .cl-stage__more { display: block; animation: cl-stage-up 0.6s var(--st-ease) both; }
.cl-stage.is-open .cl-stage__ch.is-on .cl-stage__read { display: none; }
@keyframes cl-stage-up { from { opacity: 0; transform: translateY(16px); } }
.cl-stage__rte { font-size: 1rem; line-height: 1.55; }
.cl-stage__rte p, .cl-stage__rte ul, .cl-stage__rte ol { margin: 0 0 0.85em; }
.cl-stage__rte ul, .cl-stage__rte ol { padding-left: 1.1em; }
.cl-stage__rte li { margin-bottom: 0.4em; }
.cl-stage__rte p:has(> strong:only-child) { margin: 1.5em 0 0.4em; font-family: var(--st-text); font-size: 1.2rem; line-height: 1.25; }
.cl-stage__rte p:first-child:has(> strong:only-child) { margin-top: 0; }
.cl-stage__rte p > strong:only-child { font-weight: 400; }
.cl-stage__rte a { color: inherit; text-underline-offset: 3px; word-break: break-word; }
.cl-stage__rte p:last-child { color: var(--st-ink-2); }

/* time ticks (chapter nav) and the light button */
.cl-stage__ticks { position: absolute; z-index: 3; left: 50%; bottom: 30px; transform: translateX(-50%); display: flex; gap: 34px; margin: 0; padding: 0; list-style: none; }
.cl-stage__tick { display: flex; flex-direction: column; justify-content: flex-end; align-items: center; gap: 8px; height: 50px; font-size: 11px; font-weight: 500; letter-spacing: 0.06em; font-variant-numeric: tabular-nums; color: var(--st-ink-2); transition: color 0.4s; }
.cl-stage__tick::before { content: ''; width: 1px; height: 8px; background: currentColor; transition: height 0.6s var(--st-ease); }
.cl-stage__tick[aria-current='true'] { color: var(--st-ink); }
.cl-stage__tick[aria-current='true']::before { height: 22px; }
@media (hover: hover) { .cl-stage__tick:hover { color: var(--st-ink); } }

/* intro */
.cl-stage.is-js:not(.is-in) .cl-stage__reel { transform: translateY(0) !important; }
.cl-stage__ticks, .cl-stage__chapters { transition: opacity 1s ease 0.6s; }
.cl-stage.is-js:not(.is-in) :is(.cl-stage__ticks, .cl-stage__chapters) { opacity: 0; }

/* without JS the chapters read as a plain list under the room */
.cl-stage:not(.is-js) .cl-stage__chapters { position: relative; left: auto; bottom: auto; width: auto; padding: 48px 32px; }
.cl-stage:not(.is-js) .cl-stage__ch { position: static; visibility: visible; margin-bottom: 48px; }
.cl-stage:not(.is-js) .cl-stage__line > span { transform: none; }
.cl-stage:not(.is-js) .cl-stage__more { display: block; }
.cl-stage:not(.is-js) :is(.cl-stage__read, .cl-stage__close, .cl-stage__ticks) { display: none; }

@media (max-width: 749px) {
  .cl-stage { --P: calc(96 * var(--u)); }
  .cl-stage__time { top: calc(var(--st-top, 56px) + 8px); font-size: 56px; }
  .cl-stage__chapters { left: var(--cl-gutter, 20px); right: var(--cl-gutter, 20px); width: auto; bottom: 86px; }
  .cl-stage__title { font-size: 1.75rem; margin-bottom: 10px; }
  .cl-stage__short { font-size: 0.9375rem; margin-bottom: 14px; }
  .cl-stage.is-open .cl-stage__chapters { bottom: 76px; }
  .cl-stage.is-open .cl-stage__ch.is-on { max-height: calc(100svh - 150px); margin: 0 -12px -12px; width: calc(100% + 24px); padding: 22px 18px; }
  .cl-stage__ticks { gap: 16px; bottom: 22px; }
  .cl-stage__tick-t { display: none; }
  .cl-stage__tick { padding: 6px 4px; }
}

@media (prefers-reduced-motion: reduce) {
  .cl-stage *, .cl-stage { transition: none !important; animation: none !important; }
  .cl-stage__room::after { animation: none !important; }
}

/* ---------- Learn questions (after the stage, morning register) ---------- */
.cl-ask {
  padding-inline: max(var(--cl-gutter, 32px), calc((100vw - var(--cl-max, 1200px)) / 2)) !important;
  --ask-ink: var(--cl-ink, #161616); --ask-ink-2: var(--cl-ink-2, #4a525e); --ask-line: var(--cl-line, #d9d4c8);
  display: grid; grid-template-columns: minmax(0, 4fr) minmax(0, 8fr); gap: 48px;
  padding: clamp(88px, 11vw, 168px) 32px; background: var(--cl-day, #FAF8F4); color: var(--ask-ink);
  font-family: var(--cl-font-ui, 'Hanken Grotesk', system-ui, sans-serif);
}
.cl-ask__side { display: flex; flex-direction: column; gap: 32px; position: sticky; top: calc(var(--cl-hd-h, 72px) + 40px); align-self: start; }
.cl-ask__h { margin: 0; }
.cl-ask__who { max-width: 22rem; }
.cl-ask__name { margin: 0 0 6px; font-size: 1rem; font-weight: 500; }
.cl-ask__name span { font-weight: 400; color: var(--ask-ink-2); }
.cl-ask__intro { margin: 0 0 18px; color: var(--ask-ink-2); }
.cl-ask__mail { display: flex; align-items: baseline; gap: 16px; margin: 0; flex-wrap: wrap; }
.cl-ask__mail a { color: inherit; font-family: var(--cl-font-serif, 'Libre Caslon Text', serif); font-size: 1.25rem; text-underline-offset: 4px; text-decoration-thickness: 1px; }
.cl-ask__copy { background: none; border: 0; padding: 0; cursor: pointer; color: var(--ask-ink-2); font: inherit; font-size: 0.875rem; text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 4px; }
.cl-ask__flip { display: inline-block; height: 1.2em; line-height: 1.2em; overflow: hidden; vertical-align: bottom; }
.cl-ask__flip > span { display: block; transition: transform 0.5s var(--cl-ease, cubic-bezier(0.7, 0, 0.2, 1)); }
.cl-ask__copy.is-done .cl-ask__flip > span { transform: translateY(-100%); }
.cl-ask__list { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--ask-line); }
.cl-ask__item { border-bottom: 1px solid var(--ask-line); }
.cl-ask__q { margin: 0; font: inherit; }
.cl-ask__btn {
  display: grid; grid-template-columns: minmax(0, 1fr) 20px; gap: 24px; align-items: baseline; width: 100%; padding: 26px 0;
  background: none; border: 0; cursor: pointer; color: inherit; text-align: left; font: inherit;
}
.cl-ask__t { font-family: var(--cl-font-serif, 'Libre Caslon Text', serif); font-size: clamp(1.25rem, 1.9vw, 1.75rem); line-height: 1.25; }
.cl-ask__btn:focus-visible .cl-ask__t { text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 6px; text-decoration-color: var(--ask-line); }
@media (hover: hover) { .cl-ask__btn:hover .cl-ask__t { text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 6px; text-decoration-color: var(--ask-line); } }
.cl-ask__x { position: relative; width: 14px; height: 14px; align-self: center; transition: transform 0.6s var(--cl-ease, cubic-bezier(0.7, 0, 0.2, 1)); }
.cl-ask__x::before, .cl-ask__x::after { content: ''; position: absolute; left: 0; top: 50%; width: 100%; height: 1px; background: currentColor; }
.cl-ask__x::after { transform: rotate(90deg); }
.cl-ask__item.is-open .cl-ask__x { transform: rotate(135deg); }
.cl-ask__a { display: grid; grid-template-rows: 0fr; transition: grid-template-rows 0.6s var(--cl-ease, cubic-bezier(0.7, 0, 0.2, 1)); }
.cl-ask__in { overflow: hidden; max-width: 44rem; font-family: var(--cl-font-serif, 'Libre Caslon Text', serif); font-size: 1.0625rem; line-height: 1.6; color: var(--ask-ink-2); }
.cl-ask__in > :first-child { margin-top: 0; }
.cl-ask__in > :last-child { margin-bottom: 28px; }
.cl-ask__item.is-open .cl-ask__a, .cl-ask:not(.is-js) .cl-ask__a { grid-template-rows: 1fr; }
.cl-ask__btn:focus-visible { outline: 1px solid currentColor; outline-offset: 4px; }
/* entrance, once: each row's rule draws from the left and its question rises out of the line; nothing is sticky */
.cl-ask__item, .cl-ask__list { position: relative; }
.cl-ask.is-wait .cl-ask__list { border-top-color: transparent; }
.cl-ask.is-wait .cl-ask__item { border-bottom-color: transparent; }
.cl-ask.is-wait .cl-ask__item::after, .cl-ask.is-wait .cl-ask__item:first-child::before {
  content: ''; position: absolute; left: 0; right: 0; bottom: -1px; height: 1px; background: var(--ask-line);
  transform: scaleX(0); transform-origin: 0 50%; transition: transform 1s cubic-bezier(0.16, 1, 0.3, 1) calc(var(--k, 0) * 90ms);
}
.cl-ask.is-wait .cl-ask__item:first-child::before { top: -1px; bottom: auto; }
.cl-ask.is-wait .cl-ask__t { clip-path: inset(100% 0 -0.3em 0); transform: translateY(0.5em); transition: clip-path 0.9s cubic-bezier(0.16, 1, 0.3, 1) calc(var(--k, 0) * 90ms + 120ms), transform 0.9s cubic-bezier(0.16, 1, 0.3, 1) calc(var(--k, 0) * 90ms + 120ms); }
.cl-ask.is-wait .cl-ask__x { opacity: 0; transition: opacity 0.6s ease calc(var(--k, 0) * 90ms + 400ms), transform 0.6s var(--cl-ease, cubic-bezier(0.7, 0, 0.2, 1)); }
.cl-ask.is-wait .cl-ask__item.is-in::after, .cl-ask.is-wait .cl-ask__item.is-in:first-child::before { transform: none; }
.cl-ask.is-wait .cl-ask__item.is-in .cl-ask__t { clip-path: inset(-0.5em -0.5em -0.5em -0.5em); transform: none; }
.cl-ask.is-wait .cl-ask__item.is-in .cl-ask__x { opacity: 1; }
.cl-ask.is-wait .cl-ask__h { clip-path: inset(100% 0 -0.3em 0); transform: translateY(0.5em); transition: clip-path 0.9s cubic-bezier(0.16, 1, 0.3, 1), transform 0.9s cubic-bezier(0.16, 1, 0.3, 1); }
.cl-ask.is-wait .cl-ask__side.is-in .cl-ask__h { clip-path: inset(-0.5em -0.5em -0.5em -0.5em); }
.cl-ask.is-wait .cl-ask__who { clip-path: inset(0 0 100% 0); transition: clip-path 1.1s cubic-bezier(0.16, 1, 0.3, 1) 0.25s; }
.cl-ask.is-wait .cl-ask__side.is-in .cl-ask__h { transform: none; }
.cl-ask.is-wait .cl-ask__side.is-in .cl-ask__who { clip-path: inset(-8px -8px -8px -8px); }

/* ---------- Learn closing ---------- */
.cl-fin {
  padding-inline: max(var(--cl-gutter, 32px), calc((100vw - var(--cl-max, 1200px)) / 2)) !important;
  display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); align-items: center; gap: 48px;
  min-height: 100svh; padding: 64px 32px; background: var(--cl-day, #FAF8F4); color: var(--cl-ink, #161616);
  font-family: var(--cl-font-ui, 'Hanken Grotesk', system-ui, sans-serif);
}
.cl-fin__stage { position: relative; max-width: 640px; width: 100%; justify-self: center; }
.cl-fin__media { position: relative; }
.cl-fin__media .cl-media { background: transparent; }
/* the light-off photo sits on the light-on one; the pair is multiplied onto the page together, so the cross-fade
   stays true and the photos' white turns into the page colour */
.cl-fin__off { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; pointer-events: none; opacity: calc(1 - var(--lit, 1)); }
.cl-fin__horizon { display: none; }
/* below the horizon is hidden while the clock rises; once its light is on, the horizon goes and its shadow shows */
.cl-fin.has-rise .cl-fin__stage { background: var(--cl-day, #FAF8F4); clip-path: inset(-40% -40% calc(16% * (1 - var(--lit, 0))) -40%); }
.cl-fin.has-rise .cl-fin__media { mix-blend-mode: multiply; transform: translate3d(0, calc((1 - var(--rise, 0)) * 74%), 0); will-change: transform; }
.cl-fin.has-rise .cl-fin__media .cl-media--blend > img { mix-blend-mode: normal; }
/* the warm light the clock gives off, on the page behind it; it is below the horizon until the clock is up */
.cl-fin.has-rise .cl-fin__stage::before {
  content: ''; position: absolute; inset: -14% -22%; pointer-events: none;
  background: radial-gradient(40% 38% at 50% 50%, var(--cl-light-soft, #f8dfb9), rgb(248 223 185 / 0) 72%);
  opacity: calc(var(--lit, 0) * 0.9);
}
.cl-fin.has-rise .cl-fin__stage > .cl-fin__media { z-index: 1; }
.cl-fin.has-rise .cl-fin__horizon {
  display: block; position: absolute; z-index: 2; left: -14%; right: 0; top: calc(84% - 1px); height: 1px; background: var(--cl-field, #8B8780);
  transform: scaleX(var(--line, 0)); transform-origin: 50% 50%; opacity: calc(0.6 * (1 - var(--lit, 0)));
}
.cl-fin__text { max-width: 36rem; }
.cl-fin__h { margin: 0; font-family: var(--cl-font-display, 'Libre Caslon Display', serif); font-weight: 400; font-size: clamp(1.75rem, 2.6vw, 2.5rem); line-height: 1.05; }
.cl-fin__price { margin: 6px 0 4px; display: flex; font-size: clamp(5rem, 11vw, 11rem); line-height: 1; font-weight: 200; letter-spacing: -0.04em; font-variant-numeric: tabular-nums; }
.cl-fin__price > span[aria-hidden] { display: flex; }
.cl-fin__digit { display: block; height: 1em; overflow: hidden; }
.cl-fin__reel { display: block; transform: translateY(calc(var(--d) * -10%)); transition: transform 1.6s var(--cl-ease, cubic-bezier(0.7, 0, 0.2, 1)); }
.cl-fin__reel > span { display: block; height: 1em; }
.cl-fin__digit:nth-child(3) .cl-fin__reel { transition-delay: 0.1s; }
.cl-fin__digit:nth-child(4) .cl-fin__reel { transition-delay: 0.2s; }
.cl-fin.is-js:not(.is-in) .cl-fin__reel { transform: translateY(0); }
.cl-fin__sym { display: block; font-size: 0.5em; margin: 0.12em 0.04em 0 0; }
.cl-fin__lead { margin: 0 0 36px; font-family: var(--cl-font-serif, 'Libre Caslon Text', serif); font-size: 1.125rem; color: var(--cl-ink-2, #4a525e); }
.cl-fin__sets { list-style: none; margin: 0 0 36px; padding: 0; border-top: 1px solid var(--cl-line, #d9d4c8); }
.cl-fin__sets li { border-bottom: 1px solid var(--cl-line, #d9d4c8); }
.cl-fin__set { display: grid; grid-template-columns: minmax(0, 1fr) auto; column-gap: 24px; padding: 18px 0; color: inherit; text-decoration: none; transition: padding 0.45s var(--cl-ease, cubic-bezier(0.7, 0, 0.2, 1)); }
.cl-fin__set:focus-visible { padding-left: 10px; }
@media (hover: hover) { .cl-fin__set:hover { padding-left: 10px; } }
.cl-fin__name { font-family: var(--cl-font-serif, 'Libre Caslon Text', serif); font-size: 1.25rem; }
.cl-fin__p { grid-row: 1 / 3; grid-column: 2; align-self: center; font-size: 1.25rem; font-variant-numeric: tabular-nums; }
.cl-fin__inside { font-size: 0.875rem; color: var(--cl-ink-2, #4a525e); margin-top: 4px; }
.cl-fin__save { display: block; margin-top: 2px; }
.cl-fin__name .cl-mark { margin-left: 6px; vertical-align: 2px; font-family: var(--cl-font-ui); font-size: 0.8125rem; }

@media (max-width: 749px) {
  .cl-ask { grid-template-columns: minmax(0, 1fr); gap: 32px; padding: 80px 20px; }
  .cl-ask__side { position: static; }
  .cl-ask__btn { padding: 22px 0; }
  .cl-fin { grid-template-columns: minmax(0, 1fr); gap: 24px; padding: 48px 20px 64px; min-height: 0; }
  .cl-fin__stage { max-width: 78vw; }
  .cl-fin.has-rise .cl-fin__horizon { left: -11vw; right: -11vw; }
}
@media (prefers-reduced-motion: reduce) {
  .cl-ask *, .cl-fin * { transition: none !important; }
}

/* the clock is a switch: tap to turn its light off and on */
.cl-fin__stage[data-cl-switch] { cursor: pointer; -webkit-tap-highlight-color: transparent; }
.cl-fin__stage[data-cl-switch]:focus-visible { outline: 2px solid var(--cl-ink, #121212); outline-offset: 6px; }
.cl-fin__off, .cl-fin.has-rise .cl-fin__stage::before { transition: opacity 0.6s cubic-bezier(0.16, 1, 0.3, 1); }
.cl-fin.is-dark .cl-fin__off { opacity: 1; }
.cl-fin.has-rise.is-dark .cl-fin__stage::before { opacity: 0; }
.cl-fin__hint { position: absolute; left: 0; right: 0; top: calc(84% + 14px); margin: 0; text-align: center; font-size: 0.8125rem; color: var(--cl-ink-2, #575757); opacity: var(--lit, 1); }
@media (prefers-reduced-motion: reduce) { .cl-fin__off, .cl-fin.has-rise .cl-fin__stage::before { transition: none; } }

/* no horizon line: the clock simply rises and lights */
.cl-fin.has-rise .cl-fin__horizon { display: none; }

/* the sleeper's comment at 7:05 (clavelio-room.js places it above the head) */
.cl-room-say { position: absolute; left: 0; top: 0; z-index: 3; display: grid; justify-items: start; gap: 6px; pointer-events: none; opacity: 0; will-change: transform, opacity; }
.cl-room-say__b { position: relative; padding: 7px 14px 8px; border: 1.5px solid #14171c; border-radius: 18px; background: #fbfaf7; color: #14171c; font: 600 1.0625rem/1.2 var(--st-sans); letter-spacing: 0.01em; }
.cl-room-say__b::after { content: ''; position: absolute; left: 22px; bottom: -9px; width: 14px; height: 14px; border-right: 1.5px solid #14171c; border-bottom: 1.5px solid #14171c; background: #fbfaf7; transform: skewX(-24deg) rotate(45deg); }
.cl-room-say__a { padding-left: 10px; color: var(--st-ink); font: italic 400 1rem/1.2 var(--st-text); text-shadow: 0 1px 8px rgb(0 0 0 / 0.5); }

/* the Questions sheet arrives with a soft top edge: a tall fade from clear to daylight above it */
#MainContent > .shopify-section:has(.cl-stage.is-js) + .shopify-section .cl-ask { position: relative; }
#MainContent > .shopify-section:has(.cl-stage.is-js) + .shopify-section .cl-ask::before {
  content: ''; position: absolute; left: 0; right: 0; bottom: 100%; height: 14svh; pointer-events: none; /* short, so the 7:05 text above stays readable */
  background: linear-gradient(to bottom, rgb(250 248 244 / 0), rgb(250 248 244 / 0.55) 55%, var(--cl-day, #FAF8F4));
}

/* a small muted loop under a chapter's short text (7:05: the ASCII phone) */
.cl-stage__loop { width: min(300px, 62vw); margin-bottom: 20px; border-radius: 12px; overflow: hidden; background: #000; box-shadow: 0 0 0 1px rgb(255 255 255 / 0.08); }
.cl-stage__loop video { display: block; width: 100%; height: auto; aspect-ratio: 3 / 2; object-fit: cover; }
