/* Lia product page: the film.
   The hero (.player) is one window tall. Every .scene is a layer of it. film.js plays them
   on a clock and writes four numbers on the scene that is on screen:
     --f  its backing closing over the scene before it      0 → 1
     --c  its content coming up out of that backing          0 → 1
     --p  its own story                                      0 → 1
     --o  the next scene arriving over it                    0 → 1
   Everything that moves reads those numbers. */

:root {
    --bg: #EBEBEB;
    --ink: #050505;
    --ink-rgb: 5 5 5;
    --inset: 12px;      /* light theme: scenes hang on the page like framed prints */
    --radius: 30px;
}
html.dark {
    --bg: #050505;
    --ink: #FAFAFA;
    --ink-rgb: 250 250 250;
    --inset: 0px;       /* dark theme: scenes run edge to edge */
    --radius: 0px;
}
@media (max-width: 767px) {
    :root { --inset: 8px; --radius: 24px; }
    html.dark { --inset: 0px; --radius: 0px; }
}

body { overflow-x: clip; }

/* ── Nav and floating button over a dark scene (light theme) ───────────── */
html.on-dark nav { color: #FAFAFA; }
html.on-dark .nav-glass::before { background: rgba(255, 255, 255, 0.08); border-color: rgba(255, 255, 255, 0.1); }
html.on-dark nav .bg-brand-black { background-color: #ffffff !important; color: #050505 !important; }

/* ── The player and its scenes ─────────────────────────────────────────── */
.player {
    position: relative;
    z-index: 10;
    height: 100vh;
    height: 100svh;
    overflow: hidden;
    cursor: pointer;                /* a tap pauses and resumes */
    touch-action: pan-y;            /* up and down is the page's; sideways is the film's (film.js) */
    overscroll-behavior-x: none;
    -webkit-user-select: none;
    user-select: none;
}
/* Every scene fills the player. --layer (film.js) puts the arriving one on top. */
.scene {
    position: absolute;
    inset: 0;
    z-index: var(--layer, 0);
    --p: 0;
    --e: 1;
    --f: 0;
    --c: 0;
}
.stage {
    position: absolute;
    inset: 0;
    overflow: hidden;
    pointer-events: none;           /* taps fall through to the player… */
}
/* …except on the links and buttons of the scene the viewer is looking at */
.scene.live a,
.scene.live .devs button { pointer-events: auto; }
.film {
    position: absolute;
    inset: var(--inset);
    border-radius: var(--radius);
    overflow: hidden;
    background: #000;
    color: #fff;
    isolation: isolate;
    opacity: var(--f);
    transition: inset 0.5s ease, border-radius 0.5s ease;
}
.film.plain { inset: 0; border-radius: 0; background: var(--bg); color: var(--ink); --curtain: var(--bg); }
/* The curtain: the scene's own backing colour over its content. It is closed while the scene
   arrives and leaves (film.js, --c), so two scenes' pictures and words never show together. */
.film::after {
    content: '';
    position: absolute;
    inset: 0;
    z-index: 60;
    background: var(--curtain, #000);
    opacity: calc(1 - var(--c, 0));
    pointer-events: none;
}
.creates .film { --curtain: #060606; }
.plans .film { --curtain: #0b0705; }
.duo .film { --curtain: #0a0d0f; }

.shot {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: var(--ox, 50%) var(--oy, 50%);
    /* --z: resting zoom, --sx: sideways shift that moves the subject clear of the words */
    transform: translateX(var(--sx, 0%)) scale(calc(var(--z, 1.03) + var(--p) * 0.07));
    will-change: transform, opacity;
}
/* A shot that dissolves in over the one before it, starting at --a */
.shot.fade { opacity: clamp(0, calc((var(--p) - var(--a)) * 7), 1); }

.scrim { position: absolute; inset: 0; pointer-events: none; }
.scrim.left {
    background:
        linear-gradient(90deg, rgba(0, 0, 0, 0.8) 0%, rgba(0, 0, 0, 0.5) 32%, rgba(0, 0, 0, 0) 62%),
        linear-gradient(180deg, rgba(0, 0, 0, 0.45) 0%, rgba(0, 0, 0, 0) 20%);
}

/* ── Scene copy ────────────────────────────────────────────────────────── */
.copy {
    position: absolute;
    z-index: 5;
    left: clamp(28px, 8vw, 150px);
    top: 50%;
    transform: translateY(-50%);
    width: min(600px, 46vw);
}
/* Lines rise in one after the other as the scene's content comes up */
.copy > * {
    --t: calc(clamp(0, calc((var(--c) - var(--d, 0) * 2) * 2.4), 1) * (1 - clamp(0, calc(var(--o, 0) * 2.6), 1)));
    opacity: var(--t);
    transform: translateY(calc((1 - var(--t)) * 30px));
}
.copy > :nth-child(2) { --d: 0.04; }
.copy > :nth-child(3) { --d: 0.08; }
.copy > :nth-child(4) { --d: 0.12; }

/* A block that leaves at --to, and one that arrives at --from */
.beat-out { opacity: calc(1 - clamp(0, calc((var(--p) - var(--to)) * 8), 1)); }
.beat-in  { opacity: clamp(0, calc((var(--p) - var(--from)) * 8), 1); }
.beat-in.copy > * { --t: calc(clamp(0, calc((var(--p) - var(--from) - var(--d, 0)) * 8), 1) * (1 - clamp(0, calc(var(--o, 0) * 2.6), 1))); }
/* The title writes itself first (.tok below). Whatever sits under it floats up once the title
   is nearly written (--wrote, film.js): --t flips from 0 to 1 at that moment, and the move
   itself is a transition with a soft landing. --float is that landing: it carries the line a
   little past its place and lets it settle back, so it never stops dead. */
:root { --float: 1s cubic-bezier(0.2, 1.65, 0.36, 1); }
.copy > .h ~ * {
    --t: calc(clamp(0, calc((var(--wrote, 1) - 0.84) * 1000), 1) * (1 - clamp(0, calc(var(--o, 0) * 2.6), 1)));
    transform: translateY(calc((1 - var(--t)) * 44px));
    transition: transform var(--float), opacity 0.55s ease;
}
/* one line after the other */
.copy > .h ~ * + * { transition-delay: 0.12s; }
.copy > .h ~ * + * + * { transition-delay: 0.24s; }

.k {
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 0.24em;
    text-transform: uppercase;
    color: rgb(255 255 255 / 0.6);
}
.film.plain .k { color: rgb(var(--ink-rgb) / 0.5); }
.h {
    font-size: clamp(38px, min(5.6vw, 10vh), 92px);
    line-height: 1.02;
    letter-spacing: -0.045em;
    font-weight: 500;
    margin: 18px 0 20px;
    text-wrap: balance;
}
.s {
    font-size: clamp(17px, 1.5vw, 22px);
    line-height: 1.45;
    font-weight: 300;
    color: rgb(255 255 255 / 0.74);
    max-width: 30ch;
    text-wrap: balance;
}
/* A narrower column, for scenes whose subject sits close to the words */
.copy.narrow { width: min(470px, 33vw); }

/* A title writes itself in pieces (film.js cuts it into .tok). --w is how far the writing
   has got, --at the moment a piece appears; each piece comes up quickly once its moment passes. */
/* Each piece fades up out of a soft blur over two fifths of the writing, so three or four
   are coming in at once and the line flows instead of ticking. --r is how far a piece has
   come, straight; --o eases it at both ends. (0.6: the last piece still finishes by --w = 1.) */
.tok {
    --r: clamp(0, calc((var(--w, 1) - var(--at, 0) * 0.6) * 2.5), 1);
    --o: calc(var(--r) * var(--r) * (3 - 2 * var(--r)));
    opacity: var(--o);
    filter: blur(calc((1 - var(--o)) * 5px));
}
/* Once a title is fully written its pieces are plain text again: no filter left on the type */
.written .tok { filter: none; }

/* A shimmering phrase cut into pieces is still one sweep. Each piece paints the phrase's
   gradient at the phrase's size (--pw, twice over, as .text-shimmer's 200%) and shifted
   back by where the piece starts (--left); film.js measures both. The sweep is the page's
   own shimmer: from 200% to -200% of the phrase in three seconds. */
.tok-shimmer {
    background-size: calc(var(--pw, 300px) * 2) auto;
    animation: tok-shimmer 3s linear infinite;
}
@keyframes tok-shimmer {
    from { background-position: calc(var(--pw, 300px) * -2 - var(--left, 0px)) center; }
    to   { background-position: calc(var(--pw, 300px) * 2 - var(--left, 0px)) center; }
}

/* Device buttons under the words: pick which device the scene shows */
.devs {
    display: flex;
    gap: 22px;
    margin-top: 34px;
}
.devs button {
    cursor: pointer;
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: rgb(255 255 255 / 0.36);
    padding: 6px 0 8px;
    border-bottom: 1px solid transparent;
    transition: color 0.4s ease, border-color 0.4s ease;
}
.devs button:hover { color: rgb(255 255 255 / 0.8); }
.devs button.on { color: #fff; border-bottom-color: rgb(255 255 255 / 0.85); }

/* A photo chosen by a device button. The chosen one fades in on top; the one it replaces
   stays whole underneath until that fade is done, so the picture never dips to black. */
.shot.pick { opacity: 0; z-index: 1; transition: opacity 0s linear 0.9s; }
.shot.pick.on { opacity: 1; z-index: 2; transition: opacity 0.9s ease; }
.scrim { z-index: 3; }

/* ── The opening scene ─────────────────────────────────────────────────── */
.film.hero {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 84px 24px 96px;        /* clear of the nav above and the film's bar below */
}
.hero-face {
    width: min(44vh, 82vw);
    aspect-ratio: 1;
    flex: none;
}
.hero-face video { width: 100%; height: 100%; object-fit: cover; }
.hero-h {
    margin-top: -5vh;
    font-size: clamp(40px, min(6.4vw, 10vh), 104px);
    line-height: 1.02;
    letter-spacing: -0.05em;
    font-weight: 500;
    text-wrap: balance;
}
.hero-s {
    /* floats up once the headline above it is nearly written, with the same soft landing */
    --t: clamp(0, calc((var(--wrote, 1) - 0.84) * 1000), 1);
    margin-top: 22px;
    font-size: clamp(17px, 1.5vw, 22px);
    font-weight: 300;
    color: rgb(var(--ink-rgb) / 0.62);
    opacity: var(--t);
    transform: translateY(calc((1 - var(--t)) * 44px));
    transition: transform var(--float), opacity 0.55s ease;
}
.hero-cta {
    margin-top: 34px;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 14px 18px;
}
.hero-cta > div { display: flex; flex-direction: column; align-items: center; gap: 10px; }
.meta { font-size: 12.5px; font-weight: 300; color: rgb(var(--ink-rgb) / 0.48); }
/* ── The film's bar: play or pause, the chapters, how far it has played ── */
/* One row: play, the chapters, and the two downloads at its right end. Its ink is the page's
   own over a plain scene and white over a dark one (.over-dark, set by film.js). Where the
   window is too narrow for one row, the downloads wrap to the line above (wrap-reverse). */
.bar {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 80;
    display: flex;
    flex-wrap: wrap-reverse;
    align-items: center;
    gap: 10px 24px;
    padding: 0 clamp(20px, 4vw, 56px) 24px;
    color: rgb(var(--ink-rgb));
    transition: color 0.4s ease;
    pointer-events: none;
}
.player.over-dark .bar { color: #fff; }
.bar button { pointer-events: auto; cursor: pointer; }
.bar-play {
    width: 36px;
    height: 36px;
    flex: none;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    border: 1px solid currentColor;
    opacity: 0.6;
    transition: opacity 0.3s ease;
}
.bar-play:hover { opacity: 1; }
.bar-play svg { width: 15px; height: 15px; }
.bar-play .is-paused { display: none; }
.player.paused .bar-play .is-paused { display: block; }
.player.paused .bar-play .is-playing { display: none; }
.bar-chapters { display: flex; gap: 22px; }
.bar-chapters button {
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    padding: 8px 0;
    opacity: 0.4;
    border-bottom: 1px solid transparent;
    transition: opacity 0.4s ease, border-color 0.4s ease;
}
.bar-chapters button:hover { opacity: 0.8; }
.bar-chapters button.on { opacity: 1; border-bottom-color: currentColor; }
/* The two downloads: the right end of the row, over every scene */
.bar-get {
    margin-left: auto;
    display: flex;
    align-items: center;
    gap: 10px;
}
.bar-get a { pointer-events: auto; height: 36px; padding-top: 0; padding-bottom: 0; }
/* Over a dark scene the pills wear the light ink, in either theme */
.player.over-dark .bar-get a { background-color: #ffffff !important; color: #050505 !important; }
.bar-line { position: absolute; left: 0; right: 0; bottom: 0; height: 2px; }
.bar-line::before { content: ''; position: absolute; inset: 0; background: currentColor; opacity: 0.16; }
.bar-line i { position: relative; display: block; height: 100%; background: currentColor; transform-origin: 0 50%; transform: scaleX(0); }

/* ── 02 Creates ────────────────────────────────────────────────────────── */
.creates .film { background: #060606; }
/* Title above, picture below (the Studio scene and the Duo scene): the two are one group,
   centred in the frame whatever its shape. In a tall window the picture stays under its
   title instead of dropping to the foot of the window. */
.creates .film,
.duo .film {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: clamp(28px, 5vh, 60px);
    padding: 92px 24px 104px;       /* clear of the nav above and the film's bar below */
}
.head-top {
    position: static;
    z-index: 5;
    text-align: center;
    width: auto;
    transform: none;
}
.head-top .h { margin: 14px auto 14px; max-width: 16ch; font-size: clamp(34px, min(4.6vw, 8vh), 76px); }
.head-top .s { margin: 0 auto; max-width: none; }
/* The Studio screen holds still. Its parts (top row, the three pictures, the bottom pills)
   rise into it one after the other. */
.screen-wrap {
    flex: none;
    width: min(90vw, calc(52vh * 1.523));
    max-width: 100%;
    opacity: calc(clamp(0, calc((var(--e) - 0.5) * 3), 1) * (1 - clamp(0, calc((var(--p) - 0.54) * 7), 1)));
}
.screen {
    position: relative;
    aspect-ratio: 2000 / 1313;
    border-radius: clamp(14px, 2vw, 30px);
    border: clamp(5px, 0.7vw, 11px) solid #0c0c0c;
    outline: 1px solid rgba(255, 255, 255, 0.16);
    box-shadow: 0 70px 130px -30px rgba(0, 0, 0, 0.95), 0 0 140px rgba(255, 255, 255, 0.07);
    overflow: hidden;
    background: #000;
}
/* One part of the screen. --a is when it starts, as a share of the scene; the places and sizes
   are the cuts of the 2000 x 1313 picture. */
.screen .part {
    --r: clamp(0, calc((var(--p) - var(--a)) * 8), 1);
    --o: calc(var(--r) * var(--r) * (3 - 2 * var(--r)));
    position: absolute;
    display: block;
    opacity: var(--o);
    transform: translateY(calc((1 - var(--o)) * 30px));
}
.part-top    { left: 0;     top: 0;        width: 100%;  height: 14.014%; }
.part-a      { left: 0;     top: 14.014%;  width: 33.6%; height: 76.161%; }
.part-b      { left: 33.6%; top: 14.014%;  width: 32.8%; height: 76.161%; }
.part-c      { left: 66.4%; top: 14.014%;  width: 33.6%; height: 76.161%; }
.part-bottom { left: 0;     top: 90.175%;  width: 100%;  height: 9.749%; }

.wall {
    position: absolute;
    inset: -12%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: clamp(10px, 1.3vw, 20px);
    transform: rotate(-6deg) scale(1.06);
    opacity: clamp(0, calc((var(--p) - 0.56) * 6), 1);
}
.wall-row { display: flex; gap: clamp(10px, 1.3vw, 20px); width: max-content; animation: wall-slide 90s linear infinite; }
.wall-row:nth-child(even) { animation-direction: reverse; }
.wall-row img { height: clamp(104px, 23vh, 250px); aspect-ratio: 16 / 9; border-radius: 12px; flex: none; }
@keyframes wall-slide { from { transform: translateX(0); } to { transform: translateX(-50%); } }
.wall-shade {
    position: absolute;
    inset: 0;
    background: radial-gradient(ellipse at center, rgba(0, 0, 0, 0.84) 0%, rgba(0, 0, 0, 0.5) 42%, rgba(0, 0, 0, 0.14) 100%);
    opacity: clamp(0, calc((var(--p) - 0.56) * 6), 1);
}
.head-mid {
    position: absolute;
    z-index: 5;
    inset: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 0 24px;
    width: auto;
    transform: none;
}
.head-mid .h { margin: 0 0 16px; font-size: clamp(44px, min(7.4vw, 13vh), 128px); }
.head-mid .s { max-width: none; color: rgb(255 255 255 / 0.85); }

/* ── 03 Plans ──────────────────────────────────────────────────────────── */
.plans .film { background: #0b0705; }
/* A photo that holds one side of the frame; --edge is the colour it melts into */
.half {
    --edge: 11 7 5;
    position: absolute;
    top: 0;
    right: 0;
    width: 54%;
    height: 100%;
    overflow: hidden;
}
.half::after {
    content: '';
    position: absolute;
    inset: 0 0 0 -2px;
    background: linear-gradient(90deg, rgb(var(--edge)) 0%, rgb(var(--edge)) 4%, rgb(var(--edge) / 0) 38%);
}
/* A half that arrives over a full-frame shot, with a veil that clears the other side for the words */
.half.fade, .veil { opacity: clamp(0, calc((var(--p) - var(--a)) * 7), 1); }
.veil { position: absolute; inset: 0; }
.steps { margin-top: 30px; }
.steps li {
    --on: clamp(0, calc((var(--p) - var(--a)) * 7), 1);
    padding: 16px 0;
    font-size: clamp(19px, 1.9vw, 28px);
    letter-spacing: -0.02em;
    color: rgb(255 255 255 / calc(0.24 + 0.76 * var(--on)));
    border-top: 1px solid rgb(255 255 255 / calc(0.1 + 0.2 * var(--on)));
}

/* ── 04 Researches ─────────────────────────────────────────────────────── */
.chips { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 30px; max-width: 520px; }
.chip {
    --c: clamp(0, calc((var(--p) - var(--a)) * 9), 1);
    padding: 10px 18px;
    border-radius: 999px;
    font-size: 14px;
    font-weight: 500;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.24);
    -webkit-backdrop-filter: blur(14px);
    backdrop-filter: blur(14px);
    opacity: var(--c);
    transform: translateY(calc((1 - var(--c)) * 16px)) scale(calc(0.94 + var(--c) * 0.06));
}

/* ── Duo ───────────────────────────────────────────────────────────────── */
.duo .film { background: radial-gradient(ellipse at 50% 60%, #1b2226 0%, #0c1012 62%, #070909 100%); }
.rig {
    /* The phone is already opening as the scene comes up (--c), never waiting folded and
       still: it sets off at once and lands softly, while the title writes itself. */
    /* Snappy off the mark, slow as it settles: most of the move is done in the first third
       of a longer run, and the rest eases in gently (a fourth-power ease out). */
    /* BAM: it snaps open the moment the scene is up (half the move in under 0.2 s, nine
       tenths in half a second), then takes its time over the last little bit (an
       eighth-power ease out). */
    --dr: clamp(0, calc((var(--c) - 0.85) * 0.2 + var(--p) * 2.4), 1);
    --dq: calc((1 - var(--dr)) * (1 - var(--dr)));
    --dq2: calc(var(--dq) * var(--dq));
    --d: calc(1 - var(--dq2) * var(--dq2));
    position: relative;
    flex: none;
    width: min(74vw, calc(50vh * 1.4));
    aspect-ratio: 1653 / 1181;
    margin-bottom: 4%;              /* the folded phone hangs a little below the open one */
    opacity: clamp(0, calc((var(--e) - 0.5) * 3), 1);
}
.rig .open {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    opacity: var(--d);
    transform: scale(calc(0.9 + var(--d) * 0.1));
    filter: drop-shadow(0 50px 70px rgba(0, 0, 0, 0.7));
}
.rig .folded {
    position: absolute;
    left: -7%;
    bottom: -11%;
    height: 80%;
    width: auto;
    transform: translate(calc((1 - var(--d)) * 92%), calc((1 - var(--d)) * -8%)) scale(calc(1 + (1 - var(--d)) * 0.22));
    filter: drop-shadow(0 40px 60px rgba(0, 0, 0, 0.75));
}

/* ── Yours ─────────────────────────────────────────────────────────────── */
.yours .film { display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; }
/* The four words write themselves like every other title (.tok) */
.word {
    font-size: clamp(52px, min(11vw, 18vh), 190px);
    line-height: 0.96;
    letter-spacing: -0.055em;
    font-weight: 600;
}
.yours .after {
    /* floats up once the four words are nearly written, with the same soft landing */
    --t: clamp(0, calc((var(--wrote, 1) - 0.9) * 1000), 1);
    margin-top: 4vh;
    font-size: clamp(16px, 1.4vw, 21px);
    font-weight: 300;
    color: rgb(var(--ink-rgb) / 0.6);
    opacity: var(--t);
    transform: translateY(calc((1 - var(--t)) * 44px));
    transition: transform var(--float), opacity 0.55s ease;
}

/* ── Everything she does: the five chapters as columns ─────────────────── */
.all .film {
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 0 clamp(28px, 8vw, 150px);
}
.cols {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: clamp(18px, 2.6vw, 52px);
    margin-top: clamp(28px, 6vh, 60px);
}
/* A column starts from nothing. At its moment (--a) the rule above it draws itself and its
   title writes itself (.tok, film.js); then its items rise in one after the other. */
.col {
    --on: clamp(0, calc((var(--p) - var(--a)) * 6), 1);
    position: relative;
    padding-top: 26px;
    border-top: 1px solid transparent;
}
/* The rule above a column draws itself as the column comes in */
.col::before {
    content: '';
    position: absolute;
    left: 0;
    top: -1px;
    width: 100%;
    height: 1px;
    background: rgb(var(--ink-rgb) / 0.9);
    transform-origin: 0 50%;
    transform: scaleX(var(--on));
}
.col h3 {
    font-size: clamp(24px, 2.7vw, 44px);
    line-height: 1.05;
    letter-spacing: -0.045em;
    font-weight: 500;
    margin-bottom: clamp(14px, 3vh, 28px);
}
/* Items wait for the title (0.08 of the scene after the column's moment), then come in
   one after the other (--n: the item's place in its list) */
.col li {
    --t: clamp(0, calc((var(--p) - var(--a) - 0.08 - var(--n, 0) * 0.016) * 14), 1);
    font-size: clamp(15px, 1.25vw, 19px);
    line-height: 2.15;
    font-weight: 300;
    white-space: nowrap;
    color: rgb(var(--ink-rgb) / 0.74);
    opacity: var(--t);
    transform: translateY(calc((1 - var(--t)) * 10px));
}
.col li:nth-child(2) { --n: 1; }
.col li:nth-child(3) { --n: 2; }
.col li:nth-child(4) { --n: 3; }
.col li:nth-child(5) { --n: 4; }
.col li:nth-child(6) { --n: 5; }

/* ── The closing screen ────────────────────────────────────────────────── */
/* The mark, the words, the downloads and the footer are one window tall together, so the
   page's last screen shows all of it: the mark clear of the nav, the footer at the foot.
   The gaps shrink with the window's height. */
.closing {
    position: relative;
    z-index: 10;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    min-height: 100svh;
}
#get {
    flex: 1 0 auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding-top: 84px;              /* clear of the nav */
    padding-bottom: clamp(20px, 4vh, 56px);
}
#get > svg { flex: none; margin-bottom: 40px; }
html.dark #get > svg { margin-bottom: clamp(56px, 11vh, 112px); }   /* the sunrise sits in this gap */
#get > h2 { margin-bottom: clamp(24px, 5vh, 48px); }
#get > p.meta { margin-top: clamp(16px, 4vh, 48px); }

/* The Lia mark draws itself. Each letter is masked by a pen line (products.html) whose dash
   runs from hidden to full: the L first, the A starting before the L has finished. The mark
   does not fade or slide in like the other .reveal pieces; the drawing is its entrance. */
svg.mark.reveal { opacity: 1; transform: none; }
.mark .pen {
    stroke-dasharray: 1;
    stroke-dashoffset: 1;
    transition: stroke-dashoffset 0.9s cubic-bezier(0.65, 0, 0.35, 1);
}
.mark .pen-a { transition-duration: 1s; transition-delay: 0.55s; }
.mark.active .pen { stroke-dashoffset: 0; }

/* ── The horizon behind the closing section ────────────────────────────── */
/* Full window width behind a centred column; its top and foot melt into the page. */
.horizon {
    position: absolute;
    z-index: -1;
    top: 0;
    left: 50%;
    width: 100vw;
    height: 100%;
    transform: translateX(-50%);
    pointer-events: none;
    -webkit-mask-image: linear-gradient(180deg, transparent 0%, #000 16%, #000 82%, transparent 100%);
    mask-image: linear-gradient(180deg, transparent 0%, #000 16%, #000 82%, transparent 100%);
}

/* ── Pricing ticks ─────────────────────────────────────────────────────── */
.feat { position: relative; padding-left: 32px; min-height: 20px; }
.feat::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: rgb(var(--ink-rgb) / 0.1);
}
.feat::after {
    content: '';
    position: absolute;
    left: 6px;
    top: 5px;
    width: 8px;
    height: 5px;
    border-left: 2px solid currentColor;
    border-bottom: 2px solid currentColor;
    transform: rotate(-45deg);
}

/* ── Phone ─────────────────────────────────────────────────────────────── */
@media (max-width: 767px) {
    /* While the film has the window, the page under it is out of focus, as through a camera:
       its top edge peeks in under the browser's bar. Scrolling down pulls it into focus
       (--focus, film.js). Once it is sharp the blur is switched off entirely. */
    #pricing {
        filter: blur(calc((1 - var(--focus, 1)) * 14px));
        opacity: calc(0.5 + var(--focus, 1) * 0.5);
    }
    html.page-in-focus #pricing { filter: none; opacity: 1; }

    /* The closing screen on a phone: tighter, so it all fits above the browser's bar */
    #get { padding-top: 66px; padding-bottom: 16px; }
    #get > svg { width: 64px; }
    html.dark #get > svg { margin-bottom: clamp(40px, 7vh, 80px); }
    #get > h2 { margin-bottom: clamp(20px, 3.5vh, 40px); }
    #get > p.meta { margin-top: clamp(14px, 2.5vh, 32px); }

    /* Photo sits in the lower part of the frame, the words above it */
    .shot { top: auto; bottom: 0; height: 76%; }
    .scrim.left { background: linear-gradient(180deg, #000 0%, #000 22%, rgba(0, 0, 0, 0.55) 38%, rgba(0, 0, 0, 0) 60%); }
    .copy { left: 24px; right: 24px; top: 92px; width: auto; transform: none; }
    .h { margin: 12px 0 12px; }
    .devs { margin-top: 14px; gap: 18px; }
    .devs button { font-size: 11px; padding: 10px 0; }
    .copy.narrow { width: auto; }
    .half { width: 100%; height: 66%; top: auto; bottom: 0; }
    .half .shot { height: 100%; }
    .half::after { inset: -2px 0 0 0; background: linear-gradient(180deg, rgb(var(--edge)) 0%, rgb(var(--edge)) 4%, rgb(var(--edge) / 0) 34%); }
    .plans .shot { object-position: 50% 84%; }
    .steps { margin-top: 14px; }
    .steps li { padding: 9px 0; font-size: 17px; }
    .chips { margin-top: 18px; gap: 8px; }
    .chip { padding: 8px 14px; font-size: 13px; }
    .creates .film, .duo .film { padding: 84px 16px 84px; gap: 30px; }
    .head-top { align-self: stretch; padding: 0 8px; text-align: left; }
    .head-top .h { margin: 12px 0; }
    .head-top .s { margin: 0; }
    .screen-wrap { width: 100%; }
    .wall { transform: rotate(-6deg) scale(1.5); }
    .wall-row img { height: 118px; }
    .rig { width: 78vw; margin-left: 9vw; }     /* room on the left for the folded phone */
    /* Photos frame themselves on a phone: no sideways shift, and wide scenes sit lower so the whole device shows */
    .shot { --z: 1.03 !important; --sx: 0% !important; }
    /* The phone crops are already cut around their subject */
    picture .shot { object-position: 50% 50%; }
    .shot.wide {
        height: 56%;
        -webkit-mask-image: linear-gradient(180deg, transparent 0%, #000 24%);
        mask-image: linear-gradient(180deg, transparent 0%, #000 24%);
    }
    .hero-face { width: min(34vh, 78vw); }
    .film.hero { padding: 72px 20px 76px; }
    /* Narrow windows: always one row. There is no room for five chapter names beside the
       downloads, so only the chapter that is playing is named. */
    .bar { flex-wrap: nowrap; gap: 12px; padding: 0 16px 18px; }
    .bar-play { width: 32px; height: 32px; }
    .bar-chapters button { font-size: 10px; letter-spacing: 0.14em; }
    .bar-chapters button:not(.on) { display: none; }
    .bar-get { gap: 8px; }
    .bar-get a { height: 32px; padding: 0 13px; font-size: 12.5px; white-space: nowrap; }
    /* Columns become rows: the chapter word on the left, its list flowing beside it */
    .all .film { padding: 0 24px; }
    .cols { grid-template-columns: 1fr; gap: 0; margin-top: 22px; }
    .col { display: grid; grid-template-columns: 132px 1fr; column-gap: 10px; align-items: baseline; padding: 16px 0; }
    .col h3 { font-size: 21px; margin-bottom: 0; }
    .col li { display: inline; font-size: 14.5px; line-height: 1.7; white-space: normal; transform: none; }
    .col li + li::before { content: ' · '; opacity: 0.5; }
}

/* The narrowest phones: the download pills drop their icons to keep the one row */
@media (max-width: 440px) {
    .bar-get a svg { display: none; }
}

@media (prefers-reduced-motion: reduce) {
    .shot { transform: none; }
    .wall-row { animation: none; }
    .copy > *, .chip, .screen .part { transform: none; }
    .mark .pen { stroke-dashoffset: 0; transition: none; }
}
