/* Beat `lp-missions` of the landing page (LP, 2026-11-14; .scratch/ui_integration/briefs/LP_DESIGN.md §5): its OWN styles
   only (its object, inside templates/dashboard/landing/missions.html). The type, the content box, the night band, the
   strings and the dock are the frame's (static/css/a2/landing.css). Flat, every class lp-.

   THE RAIL: the blue string's run, five flat picture pearls centred on it in the catalogue's order, the chosen one
   twice the size of the others. Wide: the row FILLS the rail, from the content box's left edge to 80px before the
   string's bend, the five spread with equal gaps (never under 28px); the chosen one follows the screen
   (clamp(220px, 18vw, 320px)), the others are half of it, and where the rail is too short for that at 28px gaps the
   sizes give way (--mi-s, from the object box's own width, a container). A new choice changes two sizes by the same
   amount, so the same rule re-spaces the row. Phone (< 700px): the rail is swiped, the chosen 176px and the others
   96px, each settling at the rail's start (scroll-snap); the place after the last pearl lets the last one settle.
   THE PLACE under the rail: the chosen mission's two small capitals (when it is the seasonal one coming up), its
   title and its line; the five stacked in one grid cell, so the place keeps the height of the tallest. */

/* the object's box is a size container: the rail measures itself against it */
.lp-missions-ob{min-height:0;container-type:inline-size}
/* --mi-r: how far inside the content box's right edge the rail stops. The blue string comes down its lane at
   --lp-m + 3 * --lp-lane from the page's right edge and turns on a 48px radius (static/js/a2/landing.js: R0; no lane
   runs on its left at this beat), so its straight run starts --lp-lane + --lp-gap - 48px beyond the content box: the
   rail ends 80px before that. */
.lp-missions-run{--mi-r:calc(128px - var(--lp-lane) - var(--lp-gap));--mi-s:min(calc(clamp(220px, 18vw, 320px) / 2), calc((100cqw - var(--mi-r) - 112px) / 6));--mi-l:calc(var(--mi-s) * 2);--mi-g:28px;--mi-e:cubic-bezier(.3,1.25,.5,1);position:relative;height:var(--mi-l);margin-right:var(--mi-r)}
/* the string's run ends under the first pearl (the dot hidden by its glass), so the pearls read as threaded on it */
.lp-missions-hook{left:calc(var(--mi-s) * .3)}

.lp-missions-rail{position:relative;display:flex;align-items:center;justify-content:space-between;column-gap:var(--mi-g);height:100%}
.lp-missions-p{position:relative;flex:none;display:block;width:var(--mi-s);height:var(--mi-s);border-radius:50%;transition:width .5s var(--mi-e),height .5s var(--mi-e)}
.lp-missions-p.on{width:var(--mi-l);height:var(--mi-l);cursor:default}
.lp-missions-p:focus-visible{outline:none;box-shadow:0 0 0 4px #F4EFE6,0 0 0 7px var(--ink)}
.lp-missions-p:focus:not(:focus-visible){outline:none}

/* a pearl: the kit's canvas (its picture handed over late, missions.js); without script its own picture, a plain
   round img in a <noscript> */
.lp-missions-pl,.lp-missions-ns{position:absolute;left:0;top:0;display:block;width:100%;height:100%;border-radius:50%}
.lp-missions-ns{object-fit:cover;filter:drop-shadow(0 8px 8px rgba(10,14,40,.24))}
.lp-missions-pl{filter:drop-shadow(0 8px 8px rgba(10,14,40,.24));transition:transform .45s var(--mi-e)}
.lp-missions-p:not(.on):hover .lp-missions-pl,.lp-missions-p:not(.on):hover .lp-missions-gl{transform:scale(1.04)}

/* the living pearl: the poster and the film under the kit's glass (missions.js paints the two glass layers: the
   shade, multiplied; the light, added), all inside one round clip with the neighbours' shadow */
.lp-missions-gl{position:absolute;left:0;top:0;display:block;width:100%;height:100%;border-radius:50%;overflow:hidden;isolation:isolate;filter:drop-shadow(0 8px 8px rgba(10,14,40,.24));transition:transform .45s var(--mi-e)}
.lp-missions-gl .lp-missions-im,.lp-missions-v,.lp-missions-mul,.lp-missions-add{position:absolute;left:0;top:0;display:block;width:100%;height:100%;border-radius:50%}
/* THE FILM'S FRAMING (coordinator, 2026-11-14, re-check R4: all four faces wholly inside the circle, at least 10px
   from the rim at every size; the heads high, no blank band above them wider than a sixth; the table at the foot).
   The file is the film's 1080 frame on a 1450 square of its own cream (#FCF7EC, the film's ground), the faces' middle
   on the square's middle and the heads' top at a sixth: at that framing the faces stay 10px inside the rim even on
   the 96px pearl of a phone. The chosen pearl zooms in on the heads' top (x 50%, y 16.7%) to a 1100 square (x1.318):
   the family fills it with its faces 11–19px inside the rim at 176–311px, the table in its lower third. The zoom
   runs with the pearl's growth. */
.lp-missions-gl .lp-missions-im,.lp-missions-v{object-fit:cover;transform-origin:50% 16.69%;transform:none;transition:transform .5s var(--mi-e),clip-path .5s var(--mi-e)}
.lp-missions-film.on .lp-missions-gl .lp-missions-im,.lp-missions-film.on .lp-missions-v{transform:scale(1.318)}
/* WebKit does not clip a composited <video> (nor, with it, the poster's layer) to its rounded overflow:hidden box: the
   film showed as a white square with the glass drawn over it, and the pearl's drop shadow, taken from the square,
   was square (iOS Safari, 2026-11-15). So every layer is clipped round ITSELF, and the glass's drop shadow sees a
   round picture whatever the box does. The poster and the film are scaled about (50%, 16.69%): their own circle is
   the pearl's circle taken back through that zoom, 50% / 1.318 = 37.94% wide, centred at 16.69% + 33.31% / 1.318 =
   41.96% down, so after the zoom it lies exactly on the pearl's rim; it moves with the zoom (same time, same easing).
   In Chromium the box's own clip already held: nothing there changes. */
.lp-missions-gl .lp-missions-im,.lp-missions-v,.lp-missions-mul,.lp-missions-add{clip-path:circle(50% at 50% 50%)}
.lp-missions-film.on .lp-missions-gl .lp-missions-im,.lp-missions-film.on .lp-missions-v{clip-path:circle(37.94% at 50% 41.96%)}
/* the film is out of the picture until it is woken (missions.js), shown from its first presented frame, and leaves
   with a short fade back to the poster (a video that is merely transparent still covers the poster in some
   engines, and with no script there is no film at all) */
.lp-missions-v{opacity:0;visibility:hidden;transition:opacity .35s,visibility 0s .35s,transform .5s var(--mi-e),clip-path .5s var(--mi-e)}
.lp-mi-wake .lp-missions-v{visibility:visible;transition:opacity .35s,transform .5s var(--mi-e),clip-path .5s var(--mi-e)}
.lp-mi-play .lp-missions-v{opacity:1;visibility:visible;transition:transform .5s var(--mi-e),clip-path .5s var(--mi-e)}
/* the two glass layers exist only once missions.js has painted them (an unpainted canvas under a blend mode
   hides the picture when there is no script) */
.lp-missions-mul,.lp-missions-add{display:none;pointer-events:none}
.lp-mi-glass .lp-missions-mul,.lp-mi-glass .lp-missions-add{display:block}
.lp-missions-mul{mix-blend-mode:multiply}
.lp-missions-add{mix-blend-mode:screen;mix-blend-mode:plus-lighter}
/* the glass's shade is painted at 1/1.05 (a flat pearl's lit side is up to 4% brighter than its picture); the picture
   is lifted by the same so the product is the kit's */
.lp-mi-glass .lp-missions-gl .lp-missions-im,.lp-mi-glass .lp-missions-v{filter:brightness(1.05)}

/* -- the place under the rail ------------------------------------------------------------------------------- */
.lp-missions-say{display:grid;max-width:34em;margin-top:clamp(20px,3vh,30px)}
.lp-missions-c{grid-area:1/1;visibility:hidden;opacity:0;transition:opacity .18s,visibility 0s .18s}
.lp-missions-c.on{visibility:visible;opacity:1;transition:opacity .22s .06s}
.lp-missions-k{display:block;height:22px;margin:0;font:700 12.5px/22px var(--fd);letter-spacing:.16em;text-transform:uppercase;color:#1C39BB;white-space:nowrap}
.lp-missions-k > span[hidden]{display:none}
.lp-missions-t{margin:2px 0 0;font:800 clamp(24px,2.4vw,36px)/1.1 var(--fd);letter-spacing:-.015em;color:var(--ink);text-wrap:balance}
.lp-missions-c .lp-missions-l{margin-top:8px}

/* -- phones: the rail is swiped -------------------------------------------------------------------------------- */
@media (max-width:699px),(orientation:portrait) and (max-width:1199px){
  /* --mi-b: the rail's clip stands this far left of the content box (and 20px above, 30px below), so a settled
     pearl's shadow and focus ring are never cut; it is less than the gap, so no sliver of the pearl before shows */
  .lp-missions-run{--mi-s:96px;--mi-l:176px;--mi-g:24px;--mi-b:14px;margin-right:0}
  /* QC2 O3 (owner, 2026-11-21: "make both these pearls centered on the thread"): the rail's -20px top margin collapses through the run and lifts it, so the run's middle (where the thread's hook stands) was 20px above the pearls' */
  .lp-missions-hook{top:calc(50% + 20px)}
  .lp-missions-rail{justify-content:flex-start;box-sizing:content-box;margin:-20px 0 -30px calc(-1 * var(--mi-b));padding:20px 0 30px var(--mi-b);scroll-padding-left:var(--mi-b);overflow-x:auto;overflow-y:hidden;overscroll-behavior-x:contain;scroll-snap-type:x mandatory;scrollbar-width:none;-webkit-overflow-scrolling:touch}
  .lp-missions-rail::-webkit-scrollbar{display:none}
  /* the room after the last pearl, so it too can settle at the start */
  .lp-missions-rail::after{content:"";flex:none;align-self:stretch;width:calc(100% - var(--mi-s) - var(--mi-g))}
  .lp-missions-p{scroll-snap-align:start}
  .lp-missions-rail.lp-mi-free{scroll-snap-type:none}
  .lp-missions-p:not(.on):hover .lp-missions-pl,.lp-missions-p:not(.on):hover .lp-missions-gl{transform:none}
  .lp-missions-say{margin-top:26px}
}

@media (prefers-reduced-motion:reduce){
  .lp-missions-p,.lp-missions-pl,.lp-missions-gl,.lp-missions-c,.lp-missions-c.on,.lp-missions-v,.lp-missions-gl .lp-missions-im{transition:none}
}
