/* ════════════════════════════════════════════════════════════════════════════
   Phone film: one phone that plays the whole app like a short video.
   Chapters sit either side of it on desktop and become story-style bars on phones.
   Needs the page's --primary, --accent, --text, --sub, --border, --surface, --dark.
   ════════════════════════════════════════════════════════════════════════════ */

.film { position: relative; margin-top: 48px; }
.film__grid { display: grid; grid-template-columns: 1fr; justify-items: center; gap: 18px; }
.film__glow {
  position: absolute; inset: -40px -20px; pointer-events: none;
  background: radial-gradient(ellipse 46% 52% at 50% 50%, rgba(91,79,217,.16) 0%, transparent 70%);
}

/* ── chapters (desktop) ── */
.film__side { display: none; flex-direction: column; gap: 10px; width: 100%; max-width: 300px; }
.film-ch {
  display: block; width: 100%; text-align: left; border: 1px solid transparent; background: transparent;
  padding: 14px 16px 16px; border-radius: 16px; cursor: pointer; font: inherit; color: inherit;
  transition: background .25s, border-color .25s, box-shadow .25s, opacity .25s; opacity: .55;
}
.film-ch:hover { opacity: .85; }
.film-ch.on {
  opacity: 1; background: var(--surface, #fff); border-color: var(--border);
  box-shadow: 0 10px 32px rgba(91,79,217,.12);
}
.film-ch__head { display: flex; align-items: baseline; gap: 10px; }
.film-ch__num { font-size: 12px; font-weight: 800; color: var(--primary); font-variant-numeric: tabular-nums; }
.film-ch__title { font-size: 16px; font-weight: 800; letter-spacing: -.3px; color: var(--text); }
.film-ch__desc { font-size: 13.5px; color: var(--sub); line-height: 1.55; margin-top: 4px; }
.film-ch__bar { display: block; height: 3px; border-radius: 3px; background: rgba(91,79,217,.12); margin-top: 12px; overflow: hidden; }
.film-ch__bar i { display: block; height: 100%; width: 0; background: var(--primary); border-radius: 3px; }
.film-ch.done .film-ch__bar i { width: 100%; }
.film-ch.on .film-ch__bar i { animation: filmFill var(--dur, 4s) linear forwards; }
.film.paused .film-ch.on .film-ch__bar i, .film.paused .film-seg.on i { animation-play-state: paused; }
@keyframes filmFill { from { width: 0; } to { width: 100%; } }

/* ── story bars + caption (phones) ── */
.film__segs { display: flex; gap: 5px; width: min(300px, 78vw); }
.film-seg { flex: 1; height: 3px; border-radius: 3px; background: rgba(91,79,217,.15); overflow: hidden; border: none; padding: 0; cursor: pointer; }
.film-seg i { display: block; height: 100%; width: 0; background: var(--primary); }
.film-seg.done i { width: 100%; }
.film-seg.on i { animation: filmFill var(--dur, 4s) linear forwards; }
.film__caption { text-align: center; min-height: 64px; max-width: 320px; }
.film__caption b { display: block; font-size: 17px; font-weight: 800; letter-spacing: -.3px; }
.film__caption span { display: block; font-size: 14px; color: var(--sub); line-height: 1.55; margin-top: 2px; }

/* ── the phone ── */
.film__phone { position: relative; width: min(272px, 70vw); z-index: 2; }
.fp-phone { position: relative; width: 100%; aspect-ratio: 272 / 570.7; }
.fp-phone > .fp-frame { position: absolute; left: 0; top: 0; width: 272px; transform: scale(var(--fp-s, 1)); transform-origin: 0 0; }
.fp-frame {
  background: linear-gradient(155deg, #2C2C32 0%, #16161B 55%, #2A2A30 100%);
  border-radius: 46px; padding: 8px; position: relative;
  box-shadow: inset 0 0 0 1px rgba(255,255,255,.12), 0 40px 80px -20px rgba(46,38,120,.45), 0 12px 28px rgba(0,0,0,.18);
}
.fp-frame::before, .fp-frame::after { content: ''; position: absolute; width: 3px; background: #3A3A42; }
.fp-frame::before { left: -3px; top: 104px; height: 58px; border-radius: 2px 0 0 2px; box-shadow: 0 -38px 0 -12px #3A3A42; }
.fp-frame::after { right: -3px; top: 130px; height: 70px; border-radius: 0 2px 2px 0; }
.fp-screen {
  position: relative; overflow: hidden; border-radius: 38px; aspect-ratio: 9 / 19.5;
  background: #F5F5FF; color: var(--text); isolation: isolate; text-align: left; line-height: 1.35;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}
.fp-island { position: absolute; top: 9px; left: 50%; transform: translateX(-50%); width: 88px; height: 25px; background: #000; border-radius: 20px; z-index: 30; }
.fp-status {
  position: absolute; top: 0; left: 0; right: 0; height: 42px; z-index: 29;
  display: flex; align-items: center; justify-content: space-between; padding: 4px 24px 0 26px;
  font-size: 12px; font-weight: 700; color: var(--text); transition: color .35s;
}
.fp-status__icons { display: flex; gap: 4px; align-items: center; }
.fp-status__icons i { display: block; width: 3px; border-radius: 1px; background: currentColor; }
.fp-status__icons i:nth-child(1) { height: 4px; } .fp-status__icons i:nth-child(2) { height: 6px; }
.fp-status__icons i:nth-child(3) { height: 8px; } .fp-status__icons i:nth-child(4) { height: 10px; margin-right: 4px; }
.fp-status__icons b { display: block; width: 20px; height: 10px; border-radius: 3px; border: 1.5px solid currentColor; position: relative; }
.fp-status__icons b::after { content: ''; position: absolute; inset: 1.5px 5px 1.5px 1.5px; background: currentColor; border-radius: 1px; }
.fp-home { position: absolute; bottom: 7px; left: 50%; transform: translateX(-50%); width: 36%; height: 4px; border-radius: 3px; background: rgba(0,0,0,.28); z-index: 29; transition: background .35s; }
.fp-screen.is-dark { background: #0B0A12; }
.fp-screen.is-dark .fp-status { color: #fff; }
.fp-screen.is-dark .fp-home { background: rgba(255,255,255,.35); }

/* ── scenes ── */
.scene {
  position: absolute; inset: 0; padding-top: 42px; display: flex; flex-direction: column;
  opacity: 0; transform: translateX(14%) scale(.98); pointer-events: none;
  transition: opacity .45s ease, transform .55s cubic-bezier(.2,.8,.2,1);
}
.scene.on { opacity: 1; transform: none; }
.scene.gone { opacity: 0; transform: translateX(-10%) scale(.98); }
.fp-bar { display: flex; align-items: center; gap: 8px; padding: 8px 14px 10px; flex-shrink: 0; }
.fp-bar__back { font-size: 22px; line-height: 1; color: var(--primary); font-weight: 400; margin-top: -3px; }
.fp-bar__title { font-size: 15px; font-weight: 800; letter-spacing: -.3px; }
.fp-bar__sub { font-size: 10.5px; color: var(--sub); font-weight: 500; }
.fp-live { margin-left: auto; display: flex; align-items: center; gap: 4px; font-size: 9px; font-weight: 800; letter-spacing: .6px; color: #16A34A; }
.fp-live::before { content: ''; width: 6px; height: 6px; border-radius: 50%; background: #22C55E; animation: fpBlink 1.2s ease-in-out infinite; }
@keyframes fpBlink { 50% { opacity: .3; } }

/* touch indicator */
.fp-touch {
  position: absolute; width: 34px; height: 34px; margin: -17px 0 0 -17px; border-radius: 50%; z-index: 40; pointer-events: none;
  background: rgba(91,79,217,.25); border: 2px solid rgba(91,79,217,.55); opacity: 0; transform: scale(.4);
}
.fp-touch.go { animation: fpTouch .6s ease-out; }
@keyframes fpTouch { 0% { opacity: 0; transform: scale(.4); } 25% { opacity: 1; transform: scale(1); } 100% { opacity: 0; transform: scale(1.5); } }

/* in-app toast */
.fp-toast {
  position: absolute; left: 10px; right: 10px; top: 46px; z-index: 20;
  display: flex; align-items: center; gap: 8px; padding: 6px 12px 6px 6px; border-radius: 999px;
  background: rgba(28,27,31,.86); color: #fff; font-size: 11px; font-weight: 600;
  backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  box-shadow: 0 8px 24px rgba(0,0,0,.25);
  opacity: 0; transform: translateY(-12px) scale(.94); transition: opacity .3s, transform .4s cubic-bezier(.34,1.56,.64,1);
}
.fp-toast.show { opacity: 1; transform: none; }
.fp-toast__av { width: 24px; height: 24px; border-radius: 50%; display: grid; place-items: center; font-size: 10px; font-weight: 800; color: #3B326F; flex-shrink: 0; }
.fp-toast__txt { flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* photo tiles, drawn in CSS: a sky, the ground, and people */
.tile { position: relative; overflow: hidden; border-radius: 3px; aspect-ratio: 1; background: linear-gradient(var(--s1), var(--s2) 64%, var(--g) 64%); }
.fig { position: absolute; bottom: -4%; width: var(--w, 40%); aspect-ratio: 1 / 1.3; transform: translateX(-50%); }
.fig::before { content: ''; position: absolute; left: 28%; top: 0; width: 44%; aspect-ratio: 1 / 1.08; border-radius: 50%; background: var(--skin); transition: box-shadow .3s; z-index: 1; }
.fig::after { content: ''; position: absolute; left: 0; right: 0; top: 36%; bottom: 0; border-radius: 46% 46% 8% 8%; background: var(--shirt); }
.tile--arrive { animation: tileIn .5s cubic-bezier(.34,1.56,.64,1) both; }
@keyframes tileIn { from { transform: scale(.2) rotate(-8deg); opacity: 0; } to { transform: none; opacity: 1; } }

/* 1 · create */
.cr-body { padding: 6px 16px; display: flex; flex-direction: column; gap: 7px; }
.cr-label { font-size: 10.5px; font-weight: 700; color: var(--sub); margin-top: 6px; }
.cr-input { display: flex; align-items: center; height: 38px; padding: 0 12px; border-radius: 12px; border: 1.5px solid var(--primary); background: #fff; font-size: 14px; font-weight: 600; }
.cr-caret { width: 1.5px; height: 16px; background: var(--primary); margin-left: 1px; animation: fpBlink .9s step-end infinite; }
.cr-plan { display: flex; align-items: center; gap: 10px; padding: 9px 12px; border-radius: 12px; background: #fff; border: 1.5px solid transparent; transition: border-color .25s, background .25s; }
.cr-plan div { flex: 1; min-width: 0; }
.cr-plan b { display: block; font-size: 12.5px; }
.cr-plan span { display: block; font-size: 9.5px; color: var(--sub); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cr-plan em { font-style: normal; font-size: 11px; font-weight: 800; color: var(--text); }
.cr-radio { width: 16px; height: 16px; border-radius: 50%; border: 2px solid #D1D5DB; flex-shrink: 0; transition: border-color .25s, box-shadow .25s; }
.cr-plan.sel { border-color: var(--primary); background: #F5F3FF; }
.cr-plan.sel .cr-radio { border-color: var(--primary); box-shadow: inset 0 0 0 3px #fff, inset 0 0 0 8px var(--primary); }
.cr-plan.sel em { color: var(--primary); }
.cr-btn { margin-top: auto; margin: 14px 0 0; height: 44px; border-radius: 14px; background: var(--primary); color: #fff; display: grid; place-items: center; font-size: 14px; font-weight: 800; transition: transform .15s, background .2s; }
.cr-btn.press { transform: scale(.96); background: #4338CA; }

/* 2 · QR */
.qr-wrap { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 12px; padding: 0 16px 40px; }
.qr-big { width: 72%; aspect-ratio: 1; padding: 12px; border-radius: 22px; background: #fff; box-shadow: 0 14px 34px rgba(91,79,217,.18); position: relative; overflow: hidden;
  display: grid; grid-template-columns: repeat(13, 1fr); gap: 1.5px; }
.qr-big i { border-radius: 1.5px; }
.qr-big i.on { background: var(--dark, #0E0A24); }
.qr-scan { position: absolute; left: 8px; right: 8px; height: 2.5px; border-radius: 2px; background: linear-gradient(90deg, transparent, var(--primary), transparent); animation: qrSweep 2s ease-in-out infinite; }
@keyframes qrSweep { 0% { top: 8px; opacity: 0; } 10%, 90% { opacity: 1; } 100% { top: calc(100% - 10px); opacity: 0; } }
.qr-code { font-size: 11px; font-weight: 700; color: var(--sub); letter-spacing: .4px; }
.qr-code b { color: var(--text); font-family: ui-monospace, Menlo, monospace; }
.qr-joined { display: flex; align-items: center; gap: 8px; min-height: 30px; }
.qr-avs { display: flex; }
.qr-av { width: 28px; height: 28px; border-radius: 50%; border: 2px solid #F5F5FF; margin-left: -8px; display: grid; place-items: center; font-size: 11px; font-weight: 800; color: #3B326F; animation: avPop .45s cubic-bezier(.34,1.56,.64,1) both; }
.qr-av:first-child { margin-left: 0; }
@keyframes avPop { from { transform: scale(0); } to { transform: none; } }
.qr-count { font-size: 12px; font-weight: 700; color: var(--text); }

/* 3 · camera */
.cam-top { display: flex; justify-content: center; padding: 4px 0 8px; }
.cam-pill { display: flex; align-items: center; gap: 6px; padding: 5px 11px; border-radius: 999px; background: rgba(255,255,255,.12); color: #fff; font-size: 11px; font-weight: 700; }
.cam-pill i { width: 6px; height: 6px; border-radius: 50%; background: #EF4444; }
.cam-view { position: relative; flex: 1; margin: 0 0; overflow: hidden; background: linear-gradient(#7DD3FC, #BAE6FD 52%, #FDE68A 52%, #FCD34D); }
.cam-view .fig { bottom: -2%; }
.cam-sun { position: absolute; right: 16%; top: 12%; width: 18%; aspect-ratio: 1; border-radius: 50%; background: #FEF3C7; box-shadow: 0 0 30px #FEF08A; }
.cam-focus { position: absolute; width: 22%; aspect-ratio: 1; border: 1.5px solid #FACC15; opacity: 0; transform: scale(1.25); transition: opacity .2s, transform .3s; }
.cam-focus.show { opacity: 1; transform: none; }
.cam-flash { position: absolute; inset: 0; background: #fff; opacity: 0; pointer-events: none; }
.cam-flash.go { animation: camFlash .35s ease-out; }
@keyframes camFlash { 0% { opacity: .9; } 100% { opacity: 0; } }
.cam-up { position: absolute; left: 50%; bottom: 10px; transform: translate(-50%, 8px); padding: 5px 11px; border-radius: 999px; background: rgba(0,0,0,.55); color: #fff; font-size: 10.5px; font-weight: 700; white-space: nowrap; opacity: 0; transition: opacity .3s, transform .3s; }
.cam-up.show { opacity: 1; transform: translate(-50%, 0); }
.cam-lens { display: flex; justify-content: center; gap: 8px; padding: 10px 0 4px; }
.cam-lens span { width: 26px; height: 26px; border-radius: 50%; background: rgba(255,255,255,.1); color: #fff; font-size: 9.5px; font-weight: 700; display: grid; place-items: center; }
.cam-lens span.on { background: rgba(124,108,240,.9); }
.cam-modes { display: flex; justify-content: center; gap: 18px; font-size: 10.5px; font-weight: 800; letter-spacing: .8px; color: rgba(255,255,255,.5); padding: 4px 0 8px; }
.cam-modes b { color: #A78BFA; }
.cam-row { display: flex; align-items: center; justify-content: space-between; padding: 4px 28px 30px; }
.cam-thumb { position: relative; width: 38px; height: 38px; border-radius: 10px; background: #26243A; border: 1.5px solid rgba(255,255,255,.25); }
.cam-thumb .tile { position: absolute; inset: 0; border-radius: 8px; }
.cam-badge { position: absolute; top: -6px; right: -6px; min-width: 17px; height: 17px; padding: 0 4px; border-radius: 9px; background: var(--primary); color: #fff; font-size: 9.5px; font-weight: 800; display: grid; place-items: center; z-index: 2; }
.cam-shutter { width: 58px; height: 58px; border-radius: 50%; border: 3.5px solid #fff; display: grid; place-items: center; }
.cam-shutter::after { content: ''; width: 46px; height: 46px; border-radius: 50%; background: var(--primary); transition: transform .12s; }
.cam-shutter.press::after { transform: scale(.82); }
.cam-flip { width: 38px; height: 38px; border-radius: 50%; background: rgba(255,255,255,.12); }

/* 4 · album */
.al-tabs { display: flex; gap: 18px; padding: 0 16px; border-bottom: 1px solid var(--border); flex-shrink: 0; }
.al-tabs span { font-size: 11.5px; font-weight: 700; color: var(--sub); padding: 0 0 8px; }
.al-tabs span.on { color: var(--primary); box-shadow: inset 0 -2px 0 var(--primary); }
.al-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 2px; padding: 2px; flex: none; }

/* 5 · faces */
.fc-people { display: flex; gap: 10px; padding: 4px 14px 10px; flex-shrink: 0; }
.fc-person { display: flex; flex-direction: column; align-items: center; gap: 3px; font-size: 9.5px; font-weight: 700; color: var(--sub); }
.fc-person i { width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; font-style: normal; font-size: 14px; font-weight: 800; color: #3B326F; border: 2.5px solid transparent; transition: border-color .25s, transform .25s; }
.fc-person.sel i { border-color: var(--primary); transform: scale(1.06); }
.fc-person.sel { color: var(--primary); }
.fc-banner { margin: 0 12px 8px; padding: 8px 12px; border-radius: 12px; background: #EEF2FF; color: var(--primary); font-size: 12px; font-weight: 800; display: flex; align-items: center; gap: 6px; white-space: nowrap; opacity: 0; transform: translateY(-6px); transition: opacity .3s, transform .3s; flex-shrink: 0; }
.fc-banner.show { opacity: 1; transform: none; }
.fc-grid .tile { transition: opacity .35s, filter .35s; }
.fc-grid.filtering .tile:not(.me) { opacity: .18; filter: grayscale(1); }
.fc-grid .tile.hit .fig.me::before { box-shadow: 0 0 0 2px #fff, 0 0 0 4px var(--primary); }

/* 6 · originals */
.og-view { position: relative; flex: 1; background: #000; display: flex; align-items: center; }
.og-view .tile { width: 100%; border-radius: 0; aspect-ratio: 3 / 4; }
.og-meta { position: absolute; top: 10px; left: 12px; right: 12px; display: flex; justify-content: space-between; color: #fff; font-size: 10.5px; font-weight: 700; }
.og-meta span { padding: 4px 9px; border-radius: 999px; background: rgba(0,0,0,.45); }
.og-sheet { background: #fff; padding: 12px 14px 30px; border-radius: 18px 18px 0 0; margin-top: -14px; position: relative; z-index: 2; }
.og-btn { height: 42px; border-radius: 13px; background: var(--primary); color: #fff; font-size: 13px; font-weight: 800; display: grid; place-items: center; position: relative; overflow: hidden; transition: transform .15s; }
.og-btn.press { transform: scale(.97); }
.og-btn__fill { position: absolute; left: 0; top: 0; bottom: 0; width: 0; background: rgba(255,255,255,.22); transition: width 1.6s cubic-bezier(.4,0,.2,1); }
.og-btn span { position: relative; }
.og-note { margin-top: 9px; text-align: center; font-size: 11px; font-weight: 600; color: var(--sub); }
.og-note.ok { color: #059669; }

/* 4 · gallery import */
.gl-head { display: flex; align-items: center; padding: 6px 14px 8px; flex-shrink: 0; }
.gl-x { font-size: 14px; width: 24px; }
.gl-center { flex: 1; text-align: center; }
.gl-all { font-size: 12px; font-weight: 800; color: var(--primary); width: 24px; text-align: right; }
.gl-user { display: flex; align-items: center; gap: 8px; margin: 0 12px 8px; padding: 7px 10px; border-radius: 12px; background: #fff; font-size: 11px; flex-shrink: 0; }
.gl-user i { width: 22px; height: 22px; border-radius: 50%; display: grid; place-items: center; font-style: normal; font-size: 10px; font-weight: 800; color: #3B326F; }
.gl-user span { flex: 1; } .gl-user em { font-style: normal; font-weight: 800; color: var(--primary); font-size: 10.5px; }
.gl-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 2px; padding: 0 2px; flex: none; }
.gl-cell { position: relative; }
.gl-cell .tile { border-radius: 2px; transition: transform .2s; }
.gl-cell.sel .tile { transform: scale(.9); border-radius: 6px; }
.gl-check { position: absolute; top: 5px; right: 5px; width: 16px; height: 16px; border-radius: 50%; border: 1.5px solid #fff; background: rgba(0,0,0,.15); transition: background .2s; }
.gl-cell.sel .gl-check { background: var(--primary); }
.gl-cell.sel .gl-check::after { content: '✓'; position: absolute; inset: 0; display: grid; place-items: center; color: #fff; font-size: 9px; font-weight: 900; }
.gl-foot { position: absolute; left: 0; right: 0; bottom: 0; display: flex; align-items: center; gap: 10px; padding: 10px 12px 26px; background: rgba(255,255,255,.96); border-top: 1px solid var(--border); }
.gl-count { flex: 1; font-size: 11px; font-weight: 600; color: var(--sub); }
.gl-btn { position: relative; overflow: hidden; height: 36px; padding: 0 16px; border-radius: 12px; background: #E5E7EB; color: var(--sub); font-size: 12px; font-weight: 800; display: grid; place-items: center; transition: background .2s, color .2s; white-space: nowrap; }
.gl-btn.on { background: var(--primary); color: #fff; }
.gl-btn__fill { position: absolute; left: 0; top: 0; bottom: 0; width: 0; background: rgba(255,255,255,.25); transition: width 1.3s cubic-bezier(.4,0,.2,1); }
.gl-btn span { position: relative; }

/* 5 · laptop (web upload) */
.fp-laptop { position: relative; width: 100%; }
.lp-fit { position: absolute; left: 0; top: 0; width: 460px; transform: scale(var(--lp-s, 1)); transform-origin: 0 0; }
.lp-lid { background: linear-gradient(160deg, #2C2C32, #16161B); border-radius: 16px 16px 4px 4px; padding: 10px 10px 14px; box-shadow: inset 0 0 0 1px rgba(255,255,255,.1), 0 30px 60px -20px rgba(46,38,120,.45); }
.lp-screen { position: relative; overflow: hidden; border-radius: 5px; aspect-ratio: 16 / 10; background: #F5F5FF; text-align: left; line-height: 1.35; font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif; color: var(--text); }
.lp-base { height: 12px; margin: 0 -7%; border-radius: 0 0 14px 14px; background: linear-gradient(#D4D4DA, #A1A1AA); position: relative; }
.lp-base::before { content: ''; position: absolute; left: 50%; top: 0; transform: translateX(-50%); width: 16%; height: 5px; border-radius: 0 0 6px 6px; background: #8E8E96; }
.lp-screen .scene { padding-top: 0; transform: none; }
.lp-chrome { display: flex; align-items: center; gap: 5px; padding: 7px 10px; background: #E9E8F3; flex-shrink: 0; }
.lp-chrome i { width: 7px; height: 7px; border-radius: 50%; background: #F87171; } .lp-chrome i:nth-child(2) { background: #FBBF24; } .lp-chrome i:nth-child(3) { background: #34D399; }
.lp-url { margin-left: 10px; flex: 1; padding: 3px 10px; border-radius: 6px; background: #fff; font-size: 9.5px; color: var(--sub); }
.lp-page { padding: 12px 18px; display: flex; flex-direction: column; gap: 6px; }
.lp-title { font-size: 15px; font-weight: 900; letter-spacing: -.3px; }
.lp-sub { font-size: 9.5px; color: var(--sub); margin-top: -3px; }
.lp-drop { border: 1.5px dashed #C7C3F0; border-radius: 10px; padding: 10px; text-align: center; font-size: 10px; font-weight: 600; color: var(--sub); background: #fff; transition: background .2s, border-color .2s, transform .2s; }
.lp-drop.over { background: #EEF2FF; border-color: var(--primary); transform: scale(1.02); }
.lp-btns { display: flex; gap: 6px; justify-content: center; margin-top: 6px; }
.lp-btns b { padding: 4px 10px; border-radius: 7px; background: var(--primary); color: #fff; font-size: 9px; }
.lp-btns b.light { background: #EEF2FF; color: var(--primary); }
.lp-prog { opacity: 0; transform: translateY(6px); transition: opacity .3s, transform .3s; }
.lp-prog.show { opacity: 1; transform: none; }
.lp-line { display: flex; justify-content: space-between; font-size: 9.5px; font-weight: 700; }
.lp-line .lp-bytes { color: var(--sub); font-weight: 600; }
.lp-bar { height: 5px; border-radius: 5px; background: #E5E7EB; margin: 4px 0; overflow: hidden; }
.lp-bar i { display: block; height: 100%; width: 0; background: var(--primary); border-radius: 5px; transition: width .15s linear; }
.lp-list { list-style: none; margin: 0; padding: 0; }
.lp-list li { display: flex; justify-content: space-between; font-size: 9px; font-family: ui-monospace, Menlo, monospace; color: var(--sub); padding: 1px 0; animation: tileIn .3s both; }
.lp-list b { color: #059669; }
.lp-folder { position: absolute; left: 8%; top: 18%; display: flex; flex-direction: column; align-items: center; gap: 1px; font-size: 9px; padding: 6px 8px; border-radius: 8px; background: rgba(255,255,255,.95); box-shadow: 0 8px 20px rgba(0,0,0,.15); opacity: 0; transition: transform 1s cubic-bezier(.5,0,.3,1), opacity .3s; z-index: 3; }
.lp-folder span { font-size: 22px; line-height: 1; } .lp-folder b { font-size: 9px; } .lp-folder em { font-style: normal; color: var(--sub); font-size: 8.5px; }
.lp-folder.drag { opacity: 1; transform: translate(170%, 115%) rotate(-4deg); }
.lp-folder.drop { opacity: 0; transform: translate(170%, 125%) scale(.4); transition: transform .3s, opacity .3s; }
.lp-cursor { position: absolute; left: calc(8% + 44px); top: calc(18% + 34px); width: 0; height: 0; border-left: 7px solid transparent; border-right: 7px solid transparent; border-bottom: 14px solid #111; transform: rotate(-30deg); opacity: 0; transition: transform 1s cubic-bezier(.5,0,.3,1), opacity .3s; z-index: 4; filter: drop-shadow(0 0 1px #fff) drop-shadow(0 0 1px #fff); }
.lp-cursor.drag { opacity: 1; transform: translate(245%, 380%) rotate(-30deg); }
.lp-cursor.drop { opacity: 0; transform: translate(290%, 380%) rotate(-30deg); }
.lp-folder.drag, .lp-cursor.drag { transition-delay: .15s; }

/* the film's phone turns into the laptop for the web chapter */
.film__center { display: flex; flex-direction: column; align-items: center; gap: 18px; }
.film__phone { display: grid; }
.film__phone > .fp-phone, .film__phone > .fp-laptop { grid-area: 1 / 1; transition: transform .7s cubic-bezier(.6,0,.2,1), opacity .5s ease; }
.film__phone > .fp-laptop { align-self: center; justify-self: center; width: 165%; opacity: 0; transform: rotate(90deg) scale(.45); pointer-events: none; }
.film__phone.is-laptop > .fp-phone { opacity: 0; transform: rotate(-90deg) scale(.6); }
.film__phone.is-laptop > .fp-laptop { opacity: 1; transform: none; transition-delay: .12s; }

/* video */
.vd-meter { margin: 8px 12px 6px; padding: 8px 12px; border-radius: 12px; background: #fff; display: flex; flex-wrap: wrap; justify-content: space-between; font-size: 11px; font-weight: 600; color: var(--sub); flex-shrink: 0; }
.vd-meter b { color: var(--text); }
.vd-bar { flex-basis: 100%; height: 5px; border-radius: 5px; background: #FCE7F3; margin-top: 6px; overflow: hidden; }
.vd-bar i { display: block; height: 100%; width: 0; background: #EC4899; border-radius: 5px; transition: width 1.2s cubic-bezier(.2,.8,.2,1); }
.vd-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 3px; padding: 2px; flex: none; }
.vd-tile { position: relative; }
.vd-tile .tile { aspect-ratio: 4 / 3; border-radius: 4px; }
.vd-tile em { position: absolute; right: 5px; bottom: 5px; font-style: normal; font-size: 9.5px; font-weight: 800; color: #fff; background: rgba(0,0,0,.55); padding: 1px 6px; border-radius: 6px; }
.vd-play { position: absolute; left: 50%; top: 50%; width: 26px; height: 26px; margin: -13px 0 0 -13px; border-radius: 50%; background: rgba(0,0,0,.4); }
.vd-play::after, .vd-big-play::after { content: ''; position: absolute; left: 54%; top: 50%; transform: translate(-50%, -50%); border-left: 9px solid #fff; border-top: 6px solid transparent; border-bottom: 6px solid transparent; }
.vd-player { position: absolute; inset: 0; background: #000; display: flex; flex-direction: column; justify-content: center; z-index: 5;
  opacity: 0; transform: translateY(30%); transition: opacity .35s, transform .45s cubic-bezier(.2,.8,.2,1); pointer-events: none; }
.vd-player.open { opacity: 1; transform: none; }
.vd-screen { position: relative; }
.vd-screen .tile { aspect-ratio: 4 / 3; border-radius: 0; }
.vd-big-play { position: absolute; left: 50%; top: 50%; width: 46px; height: 46px; margin: -23px 0 0 -23px; border-radius: 50%; background: rgba(0,0,0,.45); transition: opacity .3s; }
.vd-big-play::after { border-left-width: 14px; border-top-width: 9px; border-bottom-width: 9px; }
.vd-player.playing .vd-big-play { opacity: 0; }
.vd-controls { padding: 16px 16px 0; }
.vd-seek { position: relative; height: 4px; border-radius: 4px; background: rgba(255,255,255,.25); }
.vd-fill { position: absolute; left: 0; top: 0; bottom: 0; width: 0; background: #fff; border-radius: 4px; transition: width .15s linear; }
.vd-knob { position: absolute; top: 50%; left: 0; width: 12px; height: 12px; margin: -6px 0 0 -6px; border-radius: 50%; background: #fff; transition: left .15s linear, transform .2s; }
.vd-player.seeking .vd-knob { transform: scale(1.4); }
.vd-bubble { position: absolute; bottom: 16px; left: 50%; transform: translateX(-50%); padding: 2px 7px; border-radius: 6px; background: #fff; color: #000; font-size: 9px; font-weight: 800; white-space: nowrap; opacity: 0; transition: opacity .2s; }
.vd-player.seeking .vd-bubble { opacity: 1; }
.vd-time { margin-top: 10px; font-size: 10.5px; font-weight: 700; color: #fff; font-variant-numeric: tabular-nums; }
.vd-time span:last-child { color: rgba(255,255,255,.55); }

/* event details */
.mg-rings { position: relative; width: 40%; margin: 0 auto 2px; }
.mg-rings svg { display: block; width: 100%; }
.mg-rings span { position: absolute; inset: 0; display: grid; place-items: center; font-size: 22px; }
.mg-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 4px; padding: 0 12px 8px; text-align: center; font-size: 9px; color: var(--sub); font-weight: 600; }
.mg-stats b { display: block; font-size: 15px; font-weight: 900; font-variant-numeric: tabular-nums; }
.mg-web { margin: 0 12px 8px; padding: 9px 12px; border-radius: 12px; background: #fff; }
.mg-web__head { display: flex; align-items: center; justify-content: space-between; }
.mg-web__head { gap: 8px; }
.mg-web__head b { font-size: 11.5px; white-space: nowrap; }
.mg-create { white-space: nowrap; font-style: normal; font-size: 10px; font-weight: 800; padding: 4px 10px; border-radius: 8px; background: var(--primary); color: #fff; transition: opacity .2s, transform .2s; }
.mg-web.on .mg-create { opacity: 0; transform: scale(.8); visibility: hidden; }
.mg-web__body { max-height: 0; opacity: 0; overflow: hidden; transition: max-height .45s cubic-bezier(.2,.8,.2,1), opacity .3s, margin .3s; }
.mg-web.on .mg-web__body { max-height: 140px; opacity: 1; margin-top: 7px; }
.mg-url { font-size: 10px; font-weight: 700; color: var(--primary); background: #EEF2FF; padding: 5px 8px; border-radius: 7px; font-family: ui-monospace, Menlo, monospace; }
.mg-web__body p { font-size: 9px; color: var(--sub); margin: 5px 0 6px; line-height: 1.4; }
.mg-btns { display: flex; flex-wrap: wrap; gap: 4px; }
.mg-btns em { font-style: normal; font-size: 9px; font-weight: 800; padding: 4px 7px; border-radius: 7px; background: #EEF2FF; color: var(--primary); white-space: nowrap; transition: background .2s, color .2s; }
.mg-btns em.done { background: #D1FAE5; color: #059669; }
.mg-btns .mg-off { background: #FEF2F2; color: #DC2626; }
.mg-label { padding: 0 16px 4px; font-size: 10px; font-weight: 800; letter-spacing: .6px; text-transform: uppercase; color: var(--sub); }
.mg-list { margin: 0 12px; border-radius: 12px; background: #fff; overflow: hidden; }
.mg-member { display: flex; align-items: center; gap: 8px; padding: 7px 10px; font-size: 12px; font-weight: 600; border-bottom: 1px solid #F3F4F6; max-height: 44px; transition: opacity .3s, max-height .35s .1s, padding .35s .1s; }
.mg-member i { width: 24px; height: 24px; border-radius: 50%; display: grid; place-items: center; font-style: normal; font-size: 10px; font-weight: 800; color: #3B326F; }
.mg-member span { flex: 1; }
.mg-member em { font-style: normal; font-size: 10px; font-weight: 800; padding: 3px 8px; border-radius: 8px; }
.mg-org { background: #EEF2FF; color: var(--primary); }
.mg-remove { background: #FEF2F2; color: #DC2626; }
.mg-member.gone { opacity: 0; max-height: 0; padding-top: 0; padding-bottom: 0; }

/* ══════════════ Scroller: one sticky phone, the page scrolls past it ══════════════ */
.scroller { position: relative; --band: 60vh; padding-top: 64px; }   /* the sticky phone sits under the 64px nav; start the flow there too */
.scroller__grid { display: grid; grid-template-columns: 1fr; }
.scroller__stage { order: -1; position: sticky; top: 64px; z-index: 5; height: var(--band);
  background: var(--bg, #F5F4FF); display: grid; place-items: center; }
.scroller__stage::after { content: ''; position: absolute; left: 0; right: 0; bottom: -20px; height: 20px; background: linear-gradient(var(--bg, #F5F4FF), transparent); pointer-events: none; }
.scroller__sticky { position: relative; display: flex; align-items: center; gap: 18px; }
.scroller__device { width: calc((var(--band) - 36px) * .462); }
.scroller__phone { width: 100%; transition: transform .5s cubic-bezier(.2,.8,.2,1); }
.scroller__phone > .fp-laptop { width: min(190%, 92vw); }
.scroller__phone.dip { animation: scrollerDip .6s cubic-bezier(.3,.7,.3,1); }
@keyframes scrollerDip { 0% { transform: none; } 40% { transform: translateY(16px) scale(.95); } 100% { transform: none; } }
.scroller__glow { position: absolute; inset: -30% -40%; background: radial-gradient(ellipse 50% 50% at 50% 50%, rgba(91,79,217,.16), transparent 70%); pointer-events: none; z-index: -1; }
.scroller__dots { display: flex; flex-direction: column; gap: 8px; }
.scroller__dots button { width: 8px; height: 8px; padding: 0; border: none; border-radius: 8px; background: rgba(91,79,217,.2); cursor: pointer; transition: height .3s, background .3s; }
.scroller__dots button.on { height: 24px; background: var(--primary); }
/* Scrolling itself comes to rest on a step: the browser picks the stopping point while the
   momentum is still carrying the page, so it settles with the text where it reads best.
   "proximity" only snaps when the scroll ends near a step; the rest of the page is free. */
/* While the reader is inside the steps, every scroll ends on one (set from phone-film.js). The
   start of the next section is a resting point too, so scrolling past the last step lets go;
   once it has been reached, snapping switches off and the rest of the page scrolls freely. */
html.snap-steps { scroll-snap-type: y mandatory; }
html.snap-steps [data-scroller] + * { scroll-snap-align: start; scroll-margin-top: 64px; }
.scroller__step { display: flex; align-items: center; padding: 24px 0 20px; transition: opacity .4s;
  scroll-snap-align: start; scroll-margin-top: calc(64px + var(--band) + 8px);
  /* every scroll stops at the very next step, however fast it is, so steps go one at a time */
  scroll-snap-stop: always;
  /* exactly the room left under the sticky phone, so each stop shows one whole step */
  min-height: calc(100vh - 72px - var(--band)); }
.fr-body--short, .fr-more { display: none; }
@media (max-width: 899px) {
  /* The text has to fit in the room under the sticky phone: a short description with a
     "Show more" that opens the full one (and its tags), and no icon. */
  .scroller__step .fr-body { display: none; }
  .scroller__step .fr-body--short { display: block; }
  .scroller__step .fr-tags { display: none; }
  .scroller__step .fr-icon { display: none; }
  .scroller__step.open .fr-body { display: block; }
  .scroller__step.open .fr-body--short { display: none; }
  .scroller__step.open .fr-tags { display: flex; }
  .fr-more { display: inline-block; align-self: flex-start; margin-top: -4px; padding: 4px 0; border: none; background: none; cursor: pointer;
    font: inherit; font-size: 13.5px; font-weight: 700; color: var(--primary); }
  .scroller__step .fr-title { font-size: 22px; }
  .scroller__step .fr-body { font-size: 15px; line-height: 1.6; }
  .scroller__step .fr-text { gap: 10px; }
}

@media (min-width: 900px) {
  .scroller { --band: 100vh; padding-top: 0; }
  .scroller__grid { grid-template-columns: 1fr 1fr; gap: 48px; align-items: start; }
  .scroller__stage { order: 0; grid-column: 2; grid-row: 1; top: 0; height: 100vh; background: none; z-index: 1; }
  .scroller__stage::after { display: none; }
  .scroller__steps { grid-column: 1; grid-row: 1; }
  .scroller__step { min-height: 100vh; opacity: .28; scroll-snap-align: center; scroll-margin-top: 0; align-items: center; padding: 28px 0; }
  .scroller__step:last-child { min-height: 100vh; }
  .scroller__step.on { opacity: 1; }
  .scroller__device { width: 280px; }
  .scroller__dots { position: absolute; left: calc(100% + 100px); top: 50%; transform: translateY(-50%); }
  .scroller__phone > .fp-laptop { width: 165%; }
}
@media (prefers-reduced-motion: reduce) { .scroller__phone.dip { animation: none; } }

/* ══════════════ Single-screen shots on the inner pages ══════════════ */
.shot { position: relative; display: grid; place-items: center; padding: 30px 0; perspective: 1400px; }
.shot__glow { position: absolute; inset: 0; background: radial-gradient(ellipse 50% 50% at 50% 50%, rgba(91,79,217,.16), transparent 70%); pointer-events: none; opacity: 0; transition: opacity .8s; }
.shot.in .shot__glow { opacity: 1; }
.shot__stage { position: relative; transform-style: preserve-3d; }
.shot__device { width: min(260px, 66vw); transition: transform 1.1s cubic-bezier(.2,.8,.2,1), opacity .7s ease, filter .7s ease; transform-origin: 50% 40%; }
.shot--laptop .shot__device { width: min(460px, 88vw); }
.shot--laptop .lp-fit { perspective: 1400px; }

/* tilt: swings in from the side in 3D, settles at a slight angle, swings back out */
.shot--tilt-l .shot__device { opacity: 0; transform: rotateY(48deg) rotateX(8deg) translateX(-60px) scale(.82); }
.shot--tilt-l.in .shot__device { opacity: 1; transform: rotateY(16deg) rotateX(4deg) rotateZ(-2deg); }
.shot--tilt-r .shot__device { opacity: 0; transform: rotateY(-48deg) rotateX(8deg) translateX(60px) scale(.82); }
.shot--tilt-r.in .shot__device { opacity: 1; transform: rotateY(-16deg) rotateX(4deg) rotateZ(2deg); }
.shot--tilt-l .fp-frame { box-shadow: inset 0 0 0 1px rgba(255,255,255,.12), -30px 40px 70px -20px rgba(46,38,120,.45); }
.shot--tilt-r .fp-frame { box-shadow: inset 0 0 0 1px rgba(255,255,255,.12), 30px 40px 70px -20px rgba(46,38,120,.45); }

/* zoom: a window onto the phone that pushes in on the part that matters */
.shot--zoom .shot__stage { width: min(340px, 84vw); height: min(420px, 104vw); border-radius: 32px; overflow: hidden;
  background: linear-gradient(160deg, #EEF2FF, #E4DEFF); box-shadow: 0 30px 70px -24px rgba(46,38,120,.35); }
.shot--zoom .shot__device { position: absolute; left: 50%; top: 28px; margin-left: calc(min(260px, 66vw) / -2); transform-origin: 50% 12%; opacity: 0; transform: scale(.7) translateY(60px); }
.shot--zoom.in .shot__device { opacity: 1; transform: scale(1.32) translateY(0); transition-duration: 1.6s, .6s, .6s; }

/* float: flat and upright, with the moments popping out around it */
.shot--float .shot__device { opacity: 0; transform: translateY(80px) scale(.9); }
.shot--float.in .shot__device { opacity: 1; transform: none; animation: shotBob 6s ease-in-out 1.2s infinite; }
@keyframes shotBob { 50% { transform: translateY(-10px); } }
.shot__pops { position: absolute; inset: 0; pointer-events: none; }
.shot-pop { position: absolute; display: flex; align-items: center; gap: 8px; white-space: nowrap; padding: 9px 14px 9px 10px; border-radius: 999px;
  background: rgba(255,255,255,.94); border: 1px solid var(--border); box-shadow: 0 12px 30px rgba(91,79,217,.16); font-size: 13px; font-weight: 700; color: var(--text);
  opacity: 0; transform: scale(.6); transition: opacity .5s, transform .6s cubic-bezier(.34,1.56,.64,1); }
.shot-pop span { width: 26px; height: 26px; border-radius: 50%; background: #EEF2FF; display: grid; place-items: center; font-size: 13px; }
.shot-pop--0 { left: -34%; top: 18%; } .shot-pop--1 { right: -38%; top: 44%; } .shot-pop--2 { left: -26%; top: 72%; }
.shot.in .shot-pop { opacity: 1; transform: none; }
.shot.in .shot-pop--0 { transition-delay: .7s; } .shot.in .shot-pop--1 { transition-delay: 1.1s; } .shot.in .shot-pop--2 { transition-delay: 1.5s; }

/* laptop: opens up from flat as it arrives */
.shot--laptop .lp-lid { transform-origin: 50% 100%; transition: transform 1.1s cubic-bezier(.2,.8,.2,1) .15s; transform: rotateX(-88deg); }
.shot--laptop.in .lp-lid { transform: rotateX(-6deg); }
.shot--laptop .shot__device { opacity: 0; transform: translateY(50px) scale(.92); }
.shot--laptop.in .shot__device { opacity: 1; transform: rotateX(10deg); }

@media (max-width: 899px) {
  .film__phone > .fp-laptop { width: 126%; }
}
@media (max-width: 640px) {
  .shot-pop { font-size: 11.5px; padding: 7px 11px 7px 8px; }
  .shot-pop--0 { left: -14%; } .shot-pop--1 { right: -14%; } .shot-pop--2 { left: -8%; }
  .shot--tilt-l.in .shot__device { transform: rotateY(10deg) rotateZ(-1.5deg); }
  .shot--tilt-r.in .shot__device { transform: rotateY(-10deg) rotateZ(1.5deg); }
}

/* ── layout breakpoints ── */
@media (min-width: 900px) {
  .film__grid { grid-template-columns: 1fr auto 1fr; align-items: center; gap: 88px; }
  .film__side { max-width: 268px; }
  .film__side { display: flex; }
  .film__side--l { justify-self: end; }
  .film__side--l .film-ch { text-align: right; }
  .film__side--l .film-ch__head { justify-content: flex-end; }
  .film__side--r { justify-self: start; }
  .film__segs, .film__caption { display: none; }
  .film__phone { width: 272px; }
}

@media (prefers-reduced-motion: reduce) {
  .scene { transition: opacity .2s; transform: none !important; }
  .shot__device, .shot--laptop .lp-lid, .shot-pop { transition: opacity .3s !important; animation: none !important; }
  .qr-scan, .fp-live::before, .cr-caret { animation: none; }
}
