/* clipit.gg — one accent (yellow #FFD60A), everything else neutral.
   Light and dark are both designed; depth comes from soft light, not borders.
   No build step, no web fonts, no external assets. */

:root {
  color-scheme: dark;

  --yellow: #FFD60A;
  --on-yellow: #0A0A0A;
  --accent-text: #FFD60A;          /* yellow as *text*, dark enough in light mode */
  --accent-soft: rgba(255, 214, 10, 0.14);
  --accent-line: rgba(255, 214, 10, 0.34);
  --red: #FF6B5E;

  --bg: #000;
  --panel: #0C0C0E;                /* alternating section background */
  --card: #141416;                 /* raised card */
  --card-2: #1C1C1F;               /* raised card, one step lighter */
  --ink: #F5F5F7;
  --ink-dim: #9A9A9F;
  --ink-faint: rgba(245, 245, 247, 0.55);

  --fill-1: rgba(255, 255, 255, 0.045);
  --fill-2: rgba(255, 255, 255, 0.08);
  --fill-3: rgba(255, 255, 255, 0.14);
  --line: rgba(255, 255, 255, 0.12);
  --hairline: rgba(255, 255, 255, 0.09);
  --bar-bg: rgba(0, 0, 0, 0.72);
  --bar-bg-solid: rgba(0, 0, 0, 0.88);
  --capsule: rgba(255, 255, 255, 0.06);
  --screen: #0B0B0C;

  --shadow-s: 0 2px 10px rgba(0, 0, 0, 0.4);
  --shadow-m: 0 18px 40px -16px rgba(0, 0, 0, 0.7);
  --shadow-l: 0 40px 90px -30px rgba(0, 0, 0, 0.85);
  --glow: rgba(255, 214, 10, 0.13);
  --glow-2: rgba(255, 214, 10, 0.045);
  --fan-glow: rgba(90, 160, 255, 0.18);

  --radius: 16px;
  --tap: 44px;
  --pad: 20px;
  --bar: 48px;
  --bar-top: env(safe-area-inset-top, 0px);
  --wrap: 980px;
  --font: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Inter", "Segoe UI", Roboto, sans-serif;
  --display: -apple-system, BlinkMacSystemFont, "SF Pro Display", "SF Pro Text", "Inter", "Segoe UI", Roboto, sans-serif;
}

@media (prefers-color-scheme: light) {
  :root {
    color-scheme: light;

    --accent-text: #8A6300;        /* AA on the light background */
    --accent-soft: rgba(255, 214, 10, 0.22);
    --accent-line: rgba(176, 130, 0, 0.38);
    --red: #C7382B;

    --bg: #FBFBFD;
    --panel: #F1F1F4;
    --card: #FFF;
    --card-2: #FFF;
    --ink: #0F0F12;
    --ink-dim: #65656E;
    --ink-faint: rgba(15, 15, 18, 0.58);

    --fill-1: rgba(0, 0, 0, 0.035);
    --fill-2: rgba(0, 0, 0, 0.06);
    --fill-3: rgba(0, 0, 0, 0.1);
    --line: rgba(0, 0, 0, 0.1);
    --hairline: rgba(0, 0, 0, 0.07);
    --bar-bg: rgba(251, 251, 253, 0.72);
    --bar-bg-solid: rgba(251, 251, 253, 0.92);
    --capsule: #FFF;
    --screen: #E9E9ED;

    --shadow-s: 0 2px 8px rgba(0, 0, 0, 0.08);
    --shadow-m: 0 18px 40px -18px rgba(0, 0, 0, 0.24);
    --shadow-l: 0 40px 90px -34px rgba(0, 0, 0, 0.3);
    --glow: rgba(255, 199, 0, 0.15);
    --glow-2: rgba(255, 199, 0, 0.05);
    --fan-glow: rgba(90, 160, 255, 0.14);
  }
}

* { box-sizing: border-box; }

[hidden] { display: none !important; }

/* No `scroll-behavior: smooth` here on purpose: it would make every
   programmatic scroll animate. Anchor links are smoothed in app.js instead. */
html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font);
  font-size: 17px;
  line-height: 1.5;
  overflow-x: hidden;
}

h1, h2, h3 {
  margin: 0;
  font-family: var(--display);
  font-weight: 600;
  line-height: 1.06;
  letter-spacing: -0.025em;
}
p { margin: 0; }
img, svg { max-width: 100%; }

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}

:focus-visible {
  outline: 2px solid var(--accent-text);
  outline-offset: 3px;
}

/* ============================================================ menu bar */

.topbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 60;
  padding-top: var(--bar-top);
  background: var(--bar-bg-solid);
  border-bottom: 1px solid var(--hairline);
}

@supports ((backdrop-filter: blur(20px)) or (-webkit-backdrop-filter: blur(20px))) {
  .topbar {
    background: var(--bar-bg);
    -webkit-backdrop-filter: saturate(180%) blur(20px);
    backdrop-filter: saturate(180%) blur(20px);
  }
}

.topbar-inner {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  height: var(--bar);
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 max(14px, env(safe-area-inset-right, 0px)) 0 max(14px, env(safe-area-inset-left, 0px));
}

.wordmark {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: var(--tap);
  min-width: var(--tap);
  color: var(--ink);
  text-decoration: none;
  flex: none;
}
.wordmark-mark { width: 22px; height: 22px; flex: none; }
.wordmark-text {
  font-family: var(--display);
  font-size: 19px;
  font-weight: 700;
  letter-spacing: -0.03em;
}

.topnav {
  display: none;
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  gap: 4px;
}
.topnav a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: var(--tap);
  min-width: var(--tap);
  padding: 0 12px;
  font-size: 13px;
  color: var(--ink);
  opacity: 0.75;
  text-decoration: none;
  border-radius: 10px;
  white-space: nowrap;
}
.topnav a:hover { opacity: 1; }

.topbar-right {
  display: flex;
  align-items: center;
  gap: 6px;
  flex: none;
}

.auth-actions { display: flex; align-items: center; gap: 4px; }

.bar-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: var(--tap);
  min-width: var(--tap);
  padding: 0 10px;
  font-family: inherit;
  font-size: 13px;
  color: var(--ink);
  opacity: 0.75;
  background: none;
  border: 0;
  border-radius: 10px;
  cursor: pointer;
  white-space: nowrap;
  -webkit-tap-highlight-color: transparent;
}
.bar-link:hover { opacity: 1; }

/* the tap target is 44px tall; background-clip keeps the pill reading as a
   compact 30px Apple-style capsule */
.bar-pill {
  display: none;
  align-items: center;
  justify-content: center;
  height: var(--tap);
  min-width: 100px;
  padding: 7px 18px;
  font-family: inherit;
  font-size: 13px;
  font-weight: 600;
  color: var(--on-yellow);
  background: var(--yellow);
  background-clip: content-box;
  border: 0;
  border-radius: 999px;
  cursor: pointer;
  white-space: nowrap;
  transition: transform 160ms ease, filter 160ms ease;
  -webkit-tap-highlight-color: transparent;
}
.bar-pill:hover { filter: brightness(1.06); }
.bar-pill:active { transform: scale(0.97); }

/* signed-in avatar */
.account { position: relative; }
.avatar {
  display: flex;
  align-items: center;
  justify-content: center;
  width: var(--tap);
  height: var(--tap);
  padding: 0;
  background: none;
  border: 0;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
.avatar-letter {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  font-size: 15px;
  font-weight: 600;
  color: var(--on-yellow);
  background: var(--yellow);
  border-radius: 50%;
  text-transform: uppercase;
}
.account-menu {
  position: absolute;
  top: calc(100% + 6px);
  right: 0;
  min-width: 210px;
  max-width: min(260px, calc(100vw - 28px));
  padding: 12px;
  background: var(--card-2);
  border: 1px solid var(--line);
  border-radius: 14px;
  box-shadow: var(--shadow-m);
}
.account-email {
  font-size: 13px;
  color: var(--ink-dim);
  overflow-wrap: anywhere;
}
.account-signout {
  display: flex;
  align-items: center;
  width: 100%;
  min-height: var(--tap);
  margin-top: 6px;
  padding: 0 10px;
  font-family: inherit;
  font-size: 15px;
  font-weight: 500;
  color: var(--ink);
  background: none;
  border: 0;
  border-radius: 10px;
  cursor: pointer;
}
.account-signout:hover { background: var(--fill-2); }

/* phone menu button */
.menu-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: var(--tap);
  height: var(--tap);
  padding: 0;
  background: none;
  border: 0;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
.menu-bars {
  position: relative;
  display: block;
  width: 17px;
  height: 9px;
}
.menu-bars::before,
.menu-bars::after {
  content: "";
  position: absolute;
  left: 0;
  width: 17px;
  height: 1.5px;
  background: var(--ink);
  border-radius: 2px;
  transition: transform 220ms ease, opacity 220ms ease;
}
.menu-bars::before { top: 0; }
.menu-bars::after { bottom: 0; }
.menu-btn[aria-expanded="true"] .menu-bars::before { transform: translateY(3.75px) rotate(45deg); }
.menu-btn[aria-expanded="true"] .menu-bars::after { transform: translateY(-3.75px) rotate(-45deg); }

.menu-sheet {
  overflow: hidden;
  max-height: 0;
  opacity: 0;
  padding: 0 max(14px, env(safe-area-inset-left, 0px));
  border-top: 1px solid var(--hairline);
  transition: max-height 260ms ease, opacity 200ms ease;
}
.menu-sheet.is-open { max-height: 320px; opacity: 1; }
.menu-sheet-nav { display: flex; flex-direction: column; padding-top: 6px; }
.menu-sheet-nav a {
  display: flex;
  align-items: center;
  min-height: 48px;
  padding: 0 4px;
  font-size: 16px;
  color: var(--ink);
  text-decoration: none;
  border-bottom: 1px solid var(--hairline);
}
.bar-pill--block {
  display: flex;
  width: 100%;
  height: 50px;
  margin: 14px 0 16px;
  padding: 0 16px;
  font-size: 16px;
  background-clip: border-box;
}

@media (min-width: 734px) {
  :root { --bar: 48px; }
  .topnav { display: flex; }
  .menu-btn { display: none; }
  .menu-sheet { display: none; }
  .bar-pill { display: inline-flex; }
}

/* ============================================================ first screen */

.hero {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  min-height: 100svh;
  padding: calc(var(--bar) + var(--bar-top) + 16px) var(--pad) calc(58px + env(safe-area-inset-bottom, 0px));
  overflow: hidden;
  text-align: center;
}

/* the one soft glow behind the capsule — a pseudo-element so it can overhang
   the viewport without counting as horizontal overflow */
.hero::before {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: min(900px, 132vw);
  height: min(520px, 64vh);
  transform: translate(-50%, -56%);
  background: radial-gradient(closest-side, var(--glow), var(--glow-2) 45%, transparent 75%);
  pointer-events: none;
  animation: breathe 11s ease-in-out infinite;
}
@keyframes breathe {
  0%, 100% { opacity: 0.85; transform: translate(-50%, -54%) scale(1); }
  50%      { opacity: 1;    transform: translate(-50%, -54%) scale(1.07); }
}

/* three real clips rising from the bottom edge, ~40% of them above the fold */
.herofan::before {
  content: "";
  position: absolute;
  left: 50%;
  bottom: -8%;
  width: 150%;
  height: 150%;
  transform: translateX(-50%);
  background: radial-gradient(closest-side, var(--fan-glow), transparent 72%);
  pointer-events: none;
}
.herofan {
  position: absolute;
  left: 50%;
  bottom: 0;
  width: min(820px, 100%);
  transform: translateX(-50%);
  pointer-events: none;
  perspective: 1200px;
}
.herofan-inner {
  display: flex;
  align-items: flex-end;
  justify-content: center;
  gap: clamp(8px, 2.4vw, 22px);
  padding: 0 4px;
  transform: translate3d(0, var(--fan-y, 0), 0) rotateX(7deg);
  transform-origin: 50% 100%;
}
/* translateY is a share of the phone's own height, so ~40% of every clip
   stays above the fold whatever the viewport does to its width */
/* the lift as the page starts to move, on the compositor where supported
   (app.js keeps a JS fallback and skips it here) */
@supports (animation-timeline: scroll()) {
  @media (prefers-reduced-motion: no-preference) {
    .herofan-inner {
      animation: fan-lift linear both;
      animation-timeline: scroll(root block);
      animation-range: 0px 572px;
    }
  }
}
@keyframes fan-lift {
  from { transform: translate3d(0, 0, 0) rotateX(7deg); }
  to   { transform: translate3d(0, -160px, 0) rotateX(7deg); }
}
.phone--fan {
  width: clamp(92px, 21vw, 248px);
  opacity: 0;
  transform: translateY(var(--rise, 58%)) rotate(var(--tilt, 0deg));
  animation: fan-rise 1.1s cubic-bezier(0.22, 0.9, 0.26, 1) 0.25s forwards;
}
.phone--fan-l { --tilt: -7deg; --rise: 63%; animation-delay: 0.1s; }
.phone--fan-c { --rise: 55%; z-index: 2; }
.phone--fan-r { --tilt: 7deg; --rise: 63%; animation-delay: 0.4s; }
@keyframes fan-rise {
  from { opacity: 0; translate: 0 44px; }
  to   { opacity: 1; translate: 0 0; }
}

/* a phone sitting over the fan would fight the capsule for the centre */
/* a phone is too narrow for three clips side by side at a size worth looking
   at, so there they overlap into a real fan: centre in front, sides tucked
   behind it */
@media (max-width: 520px) {
  .herofan-inner { gap: 0; }
  .phone--fan { width: 33vw; }
  .phone--fan-l { margin-right: -5vw; }
  .phone--fan-r { margin-left: -5vw; }
}

@media (max-height: 620px), (max-width: 319px) {
  .herofan { display: none; }
}

.clip-form {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: min(640px, 90vw);
}

/* the capsule: pill within a pill */
.capsule {
  display: flex;
  align-items: center;
  gap: 8px;
  width: 100%;
  height: 58px;
  padding: 6px;
  background: var(--capsule);
  border: 1px solid var(--line);
  border-radius: 999px;
  box-shadow: var(--shadow-m);
  transition: border-color 180ms ease, box-shadow 180ms ease;
}
@supports ((backdrop-filter: blur(14px)) or (-webkit-backdrop-filter: blur(14px))) {
  .capsule {
    -webkit-backdrop-filter: saturate(140%) blur(14px);
    backdrop-filter: saturate(140%) blur(14px);
  }
}
.capsule:focus-within {
  border-color: var(--accent-line);
  box-shadow: 0 0 0 3px var(--accent-soft), var(--shadow-m);
}
.capsule.is-invalid { border-color: var(--red); }

.capsule-input {
  flex: 1 1 auto;
  min-width: 0;
  height: 100%;
  padding: 0 8px 0 16px;
  font-family: inherit;
  font-size: 17px;
  color: var(--ink);
  background: none;
  border: 0;
  border-radius: 999px;
  appearance: none;
}
.capsule-input::placeholder { color: var(--ink-faint); }
.capsule-input:focus { outline: none; }
.capsule-input:focus-visible { outline: none; }

.clip-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  flex: none;
  min-height: var(--tap);
  min-width: 92px;
  padding: 0 20px;
  font-family: inherit;
  font-size: 17px;
  font-weight: 600;
  letter-spacing: -0.01em;
  color: var(--on-yellow);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.45), rgba(255, 255, 255, 0) 55%),
    var(--yellow);
  border: 0;
  border-radius: 999px;
  cursor: pointer;
  box-shadow: 0 6px 18px rgba(255, 214, 10, 0.22), inset 0 -1px 0 rgba(0, 0, 0, 0.12);
  transition: transform 170ms ease, box-shadow 170ms ease, filter 170ms ease;
  -webkit-tap-highlight-color: transparent;
}
.capsule .clip-btn { height: 46px; }
.clip-btn:hover { transform: translateY(-1px); box-shadow: 0 10px 26px rgba(255, 214, 10, 0.3); }
.clip-btn:active { transform: scale(0.97); }
.clip-btn[aria-busy="true"] { filter: brightness(0.94); cursor: progress; }
.clip-btn--block { display: flex; width: 100%; min-height: 52px; }
.clip-btn--wide { min-width: 180px; min-height: 52px; }

.spinner { display: none; }
.clip-btn[aria-busy="true"] .spinner {
  display: block;
  width: 16px;
  height: 16px;
  border: 2.5px solid rgba(10, 10, 10, 0.25);
  border-top-color: var(--on-yellow);
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* error slot: fixed height so the capsule never moves */
.capsule-errors {
  position: relative;
  min-height: 24px;
  margin-top: 10px;
}
.capsule-errors .error {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
}

.error {
  font-size: 13px;
  line-height: 1.35;
  color: var(--red);
  text-align: center;
}

.rights-note {
  max-width: 420px;
  margin: 6px auto 0;
  font-size: 13px;
  line-height: 1.4;
  color: var(--ink-faint);
}
.rights-note a { color: inherit; text-underline-offset: 2px; }
.rights-note a:hover { color: var(--ink); }

.scroll-cue {
  position: absolute;
  left: 50%;
  bottom: calc(10px + env(safe-area-inset-bottom, 0px));
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: center;
  width: var(--tap);
  height: var(--tap);
  margin-left: calc(var(--tap) / -2);
  padding: 0;
  color: var(--ink);
  background: none;
  border: 0;
  opacity: 0.3;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
.scroll-cue:hover { opacity: 0.65; }
/* the chevron floats, not the button: a moving hit area is hostile to
   pointers and to automation */
.scroll-cue svg {
  width: 22px;
  height: 22px;
  animation: float 2s ease-in-out infinite;
}
@keyframes float {
  0%, 100% { transform: translateY(-3px); }
  50%      { transform: translateY(3px); }
}

/* ============================================================ phone frame */

.phone {
  position: relative;
  flex: none;
  padding: 2.6%;
  background: linear-gradient(152deg, #35353A 0%, #0E0E10 44%, #1A1A1D 100%);
  /* elliptical radii keep a device-true corner at any width */
  border-radius: 12.5% / 7%;
  box-shadow: var(--shadow-m), 0 0 0 0.5px rgba(0, 0, 0, 0.5);
}
/* one soft reflection across the glass, not a border */
.phone::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: linear-gradient(118deg,
    rgba(255, 255, 255, 0.16) 0%, rgba(255, 255, 255, 0.04) 16%,
    rgba(255, 255, 255, 0) 34%, rgba(255, 255, 255, 0) 100%);
  pointer-events: none;
}
.phone-screen {
  position: relative;
  overflow: hidden;
  aspect-ratio: 9 / 16;
  background: var(--screen);
  border-radius: 10.5% / 6%;
}
.phone-screen > img,
.phone-screen > video {
  position: absolute;
  inset: 0;
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.phone-video { opacity: 0; transition: opacity 420ms ease; }
.phone.is-playing .phone-video { opacity: 1; }

/* ============================================================ sections */

.section {
  position: relative;
  width: 100%;
  max-width: 100%;
  padding: 84px var(--pad);
}
.section > * { max-width: var(--wrap); margin-left: auto; margin-right: auto; }
.section--panel { background: var(--panel); }

.section > h2 {
  font-size: clamp(32px, 7vw, 58px);
  letter-spacing: -0.03em;
}
.lede {
  margin-top: 16px;
  max-width: 560px;
  color: var(--ink-dim);
  font-size: 18px;
}
.fineprint {
  margin-top: 22px;
  max-width: 620px;
  font-size: 14px;
  line-height: 1.5;
  color: var(--ink-faint);
}

:where(#how, #what, #price, #faq, #top, #watch, #made, #start) {
  scroll-margin-top: calc(var(--bar) + 12px);
}

/* scroll reveal — only armed by JS, so content shows without it */
.js-anim .reveal {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 700ms cubic-bezier(0.22, 0.9, 0.26, 1),
              transform 700ms cubic-bezier(0.22, 0.9, 0.26, 1);
}
.js-anim .reveal.is-in { opacity: 1; transform: none; }

.ghost-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: var(--tap);
  min-width: 112px;
  padding: 0 18px;
  font-family: inherit;
  font-size: 15px;
  font-weight: 500;
  color: var(--ink);
  background: var(--fill-1);
  border: 1px solid var(--line);
  border-radius: 999px;
  cursor: pointer;
  text-decoration: none;
  transition: background-color 160ms ease, transform 160ms ease;
  -webkit-tap-highlight-color: transparent;
}
.ghost-btn:hover { background: var(--fill-2); }
.ghost-btn:active { transform: scale(0.98); }

/* ======================================================= the swarm (editor) */

.swarm { padding-bottom: 56px; }
.swarm-head { text-align: left; }
.swarm-scroll { max-width: 100%; padding-bottom: 8px; }
.swarm-sticky {
  max-width: var(--wrap);
  margin: 34px auto 0;
}

.editor {
  position: relative;
  overflow: hidden;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 20px;
  box-shadow: var(--shadow-l);
}

.editor-bar {
  display: flex;
  align-items: center;
  gap: 12px;
  height: 38px;
  padding: 0 14px;
  background: var(--fill-1);
  border-bottom: 1px solid var(--hairline);
}
.editor-dots { display: flex; gap: 6px; flex: none; }
.editor-dots i {
  width: 9px;
  height: 9px;
  background: var(--fill-3);
  border-radius: 50%;
}
.editor-file {
  font-size: 12px;
  color: var(--ink-dim);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  font-variant-numeric: tabular-nums;
}

.editor-body {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 14px;
  padding: 14px;
}
.editor-main { min-width: 0; }

/* ---------- program monitor ---------- */

.monitor {
  position: relative;
  overflow: hidden;
  contain: paint;
  aspect-ratio: 16 / 9;
  background: #050506;
  border-radius: 12px;
}
.monitor-poster,
.monitor-video {
  position: absolute;
  inset: 0;
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.monitor-video { opacity: 0; transition: opacity 400ms ease; }
.monitor.is-playing .monitor-video { opacity: 1; }
.monitor-tag {
  position: absolute;
  top: 8px;
  left: 8px;
  padding: 2px 7px;
  font-size: 12px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.78);
  /* the source frame has its own HUD up here, so the tag needs its own ground */
  background: rgba(0, 0, 0, 0.55);
  border-radius: 5px;
}

/* the 9:16 crop box the Framer drags onto the face */
.crop {
  position: absolute;
  top: 0;
  left: 0;
  height: 86%;
  width: auto;
  aspect-ratio: 9 / 16;
  opacity: 0;
  border: 1.5px solid var(--yellow);
  border-radius: 6px;
  /* spread sized to the monitor, not 9999px: the crop is its own composited
     layer and the shadow sets that layer's size */
  box-shadow: 0 0 0 1400px rgba(0, 0, 0, 0.42);
  transform: translate3d(0, 0, 0);
  transition: opacity 320ms ease;
}
.crop.is-on { opacity: 1; }
.crop-label {
  position: absolute;
  top: -1px;
  left: -1px;
  padding: 1px 6px;
  font-size: 12px;
  font-weight: 600;
  color: var(--on-yellow);
  background: var(--yellow);
  border-radius: 5px 0 5px 0;
}

/* the caption the Captioner types */
.monitor-caption {
  position: absolute;
  left: 50%;
  bottom: 9%;
  max-width: 84%;
  padding: 4px 8px;
  opacity: 0;
  font-family: var(--display);
  font-size: clamp(13px, 1.8vw, 19px);
  font-weight: 700;
  letter-spacing: -0.01em;
  line-height: 1.2;
  color: #FFF;
  background: rgba(0, 0, 0, 0.72);
  border-radius: 6px;
  transform: translateX(-50%);
  transition: opacity 220ms ease;
  text-align: center;
}
.monitor-caption.is-on { opacity: 1; }
.cap-text > b { color: var(--yellow); font-weight: 700; }
.cap-caret {
  display: inline-block;
  width: 2px;
  height: 1em;
  margin-left: 2px;
  vertical-align: -0.14em;
  background: var(--yellow);
  opacity: 0;
}
.monitor-caption.is-typing .cap-caret { opacity: 1; animation: caret 1s steps(1) infinite; }
@keyframes caret { 0%, 49% { opacity: 1; } 50%, 100% { opacity: 0.1; } }

/* ---------- timeline ---------- */

.timeline {
  position: relative;
  display: grid;
  gap: 5px;
  margin-top: 12px;
  padding: 8px 8px 10px;
  background: var(--fill-1);
  border-radius: 12px;
}

.tl-ruler {
  position: relative;
  height: 18px;
  font-variant-numeric: tabular-nums;
}
.tl-time {
  position: absolute;
  top: 0;
  left: var(--at, 0%);
  font-size: 12px;
  line-height: 18px;
  color: var(--ink-faint);
  white-space: nowrap;
}
.tl-time::before {
  content: "";
  position: absolute;
  left: 0;
  bottom: -3px;
  width: 1px;
  height: 4px;
  background: var(--fill-3);
}
.tl-time--end { left: auto; right: 0; }
.tl-time--end::before { left: auto; right: 0; }

.tl-track {
  position: relative;
  overflow: hidden;
  border-radius: 6px;
  background: var(--fill-1);
}
.tl-video { height: clamp(34px, 6vw, 46px); }
.tl-audio { height: clamp(30px, 5vw, 42px); background: var(--fill-2); }
.tl-caps { height: 14px; }

.tl-strip {
  display: flex;
  height: 100%;
  opacity: 0.85;
}
.tl-strip img {
  flex: 1 1 0;
  min-width: 0;
  height: 100%;
  object-fit: cover;
  object-position: 50% 26%;
  border-right: 1px solid rgba(0, 0, 0, 0.35);
}

/* the in / out selection the Cutter drags */
.tl-select {
  position: absolute;
  top: 0;
  bottom: 0;
  left: 0;
  width: 0;
  opacity: 0;
  background: var(--accent-soft);
  border: 1.5px solid var(--yellow);
  border-radius: 4px;
  box-shadow: 0 0 18px rgba(255, 214, 10, 0.25);
  transition: opacity 180ms ease;
}
.tl-select.is-on { opacity: 1; }
.tl-handle {
  position: absolute;
  top: -1.5px;
  bottom: -1.5px;
  width: 7px;
  background: var(--yellow);
}
.tl-handle--in { left: -1.5px; border-radius: 4px 0 0 4px; }
.tl-handle--out { right: -1.5px; border-radius: 0 4px 4px 0; }

/* the selected range lifting off the track on its way to the shelf */
.tl-lift {
  position: absolute;
  top: 0;
  left: 0;
  width: 0;
  height: 100%;
  opacity: 0;
  background: var(--yellow);
  border-radius: 4px;
}

.tl-wave { display: block; width: 100%; height: 100%; }
.tl-wave path {
  fill: none;
  stroke: var(--ink-dim);
  opacity: 0.55;
  transform: scaleY(var(--gain, 1));
  transform-origin: 50% 50%;
  transition: stroke 400ms ease, opacity 400ms ease;
}
.tl-wave.is-hot path { stroke: var(--accent-text); opacity: 0.48; }

.tl-markers { position: absolute; inset: 0; pointer-events: none; }
.tl-marker {
  position: absolute;
  top: 0;
  bottom: 0;
  width: 2px;
  margin-left: -1px;
  background: var(--yellow);
  box-shadow: 0 0 12px 1px rgba(255, 214, 10, 0.55);
  opacity: 0;
  transform: scaleY(0.2);
  transform-origin: 50% 100%;
  transition: opacity 240ms ease, transform 320ms cubic-bezier(0.2, 1.3, 0.4, 1);
}
.tl-marker.is-on { opacity: 1; transform: scaleY(1); }
.tl-marker::before {
  content: "";
  position: absolute;
  top: -3px;
  left: -3px;
  width: 8px;
  height: 8px;
  background: var(--yellow);
  border-radius: 50%;
}

.tl-chip {
  position: absolute;
  top: 2px;
  padding: 1px 6px;
  font-size: 12px;
  font-weight: 700;
  line-height: 16px;
  color: var(--on-yellow);
  background: var(--yellow);
  border-radius: 5px;
  opacity: 0;
  transform: translate(-50%, 6px) scale(0.8);
  transition: opacity 200ms ease, transform 300ms cubic-bezier(0.2, 1.4, 0.4, 1);
  font-variant-numeric: tabular-nums;
}
.tl-chip.is-on { opacity: 1; transform: translate(-50%, 0); }

.tl-capblocks { position: relative; height: 100%; }
.tl-capblocks i {
  position: absolute;
  top: 3px;
  height: 8px;
  background: var(--fill-3);
  border-radius: 3px;
  opacity: 0.5;
  transition: opacity 300ms ease, background-color 300ms ease;
}
.tl-capblocks i.is-on { opacity: 1; background: var(--ink-dim); }

.tl-playhead {
  position: absolute;
  top: 20px;
  bottom: 10px;
  left: 0;
  width: 1.5px;
  background: var(--ink);
  opacity: 0;
  transform: translate3d(0, 0, 0);
}
.tl-playhead::before {
  content: "";
  position: absolute;
  top: -4px;
  left: -4px;
  border: 5px solid transparent;
  border-top-color: var(--ink);
}
.tl-playhead.is-on { opacity: 0.75; }

/* ---------- output shelf ---------- */

.shelf {
  min-width: 0;
  padding: 10px;
  background: var(--fill-1);
  border-radius: 12px;
}
.shelf-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 8px;
}
.shelf-title {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--ink-dim);
}
.shelf-count {
  font-size: 12px;
  color: var(--ink-faint);
  font-variant-numeric: tabular-nums;
}
.shelf-slots {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.slot {
  position: relative;
  aspect-ratio: 9 / 16;
  overflow: hidden;
  border: 1px dashed var(--line);
  border-radius: 8px;
  background: var(--fill-1);
}
.slot.is-filled {
  border-style: solid;
  border-color: transparent;
  background: var(--screen);
  box-shadow: var(--shadow-s);
}
.slot-media { position: absolute; inset: 0; }
.slot-media img,
.slot-media video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.slot-media video { opacity: 0; transition: opacity 400ms ease; }
.slot.is-playing .slot-media video { opacity: 1; }
.slot-rank {
  position: absolute;
  top: 4px;
  left: 4px;
  padding: 0 5px;
  font-size: 12px;
  font-weight: 700;
  line-height: 17px;
  color: var(--ink);
  background: rgba(0, 0, 0, 0.55);
  border-radius: 5px;
}
.slot.is-top .slot-rank { color: var(--on-yellow); background: var(--yellow); }
.slot-dl {
  position: absolute;
  left: 4px;
  right: 4px;
  bottom: 4px;
  padding: 2px 0;
  font-size: 12px;
  font-weight: 600;
  text-align: center;
  color: var(--ink);
  background: rgba(0, 0, 0, 0.55);
  border-radius: 999px;
  opacity: 0;
  transition: opacity 300ms ease;
}
@supports ((backdrop-filter: blur(8px)) or (-webkit-backdrop-filter: blur(8px))) {
  .slot-dl { -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px); }
}
.slot.is-done .slot-dl { opacity: 1; }

/* a segment in flight from the timeline to a slot */
.flyer {
  position: absolute;
  top: 0;
  left: 0;
  width: 64px;
  overflow: hidden;
  background: var(--screen);
  border-radius: 8px;
  box-shadow: var(--shadow-m);
  pointer-events: none;
  will-change: transform, opacity;
}
.flyer img { display: block; width: 100%; aspect-ratio: 9 / 16; object-fit: cover; }

/* ---------- the cursors ---------- */

.cursors {
  position: absolute;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
}
.cursor {
  position: absolute;
  top: 0;
  left: 0;
  width: 0;
  height: 0;
  opacity: 0;
  transform: translate3d(-100px, -100px, 0);
  will-change: transform, opacity;
}
.cursor-arrow {
  position: absolute;
  top: 0;
  left: 0;
  width: 19px;
  height: 19px;
  color: var(--c, var(--yellow));
  filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.45));
}
.cursor-name {
  position: absolute;
  top: 10px;
  left: 13px;
  padding: 1px 7px;
  font-size: 12px;
  font-weight: 600;
  line-height: 17px;
  white-space: nowrap;
  color: #FFF;
  background: var(--c, var(--yellow));
  border-radius: 999px;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.3);
}
.cursor.is-dark .cursor-name { color: #0A0A0A; }
.cursor.is-flip .cursor-name { left: auto; right: -2px; }

/* ---------- swarm footer ---------- */

.swarm-foot {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-top: 22px;
}
.swarm-foot .fineprint { margin-top: 0; flex: 1 1 320px; }

@media (min-width: 900px) {
  .editor-body { grid-template-columns: minmax(0, 1fr) 208px; }
  .shelf-slots { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .swarm-sticky {
    position: sticky;
    top: calc(var(--bar) + var(--bar-top) + 16px);
    max-width: min(1060px, 106vh);
  }
  .swarm-scroll { padding-bottom: 140px; }
  .swarm-head { max-width: var(--wrap); }
}
@media (max-height: 560px) {
  .swarm-sticky { position: static; }
  .swarm-scroll { padding-bottom: 8px; }
}

/* ============================================================ how it works */

.beats {
  list-style: none;
  display: grid;
  gap: 32px;
  margin: 40px auto 0;
  padding: 0;
  counter-reset: beat;
}
.beat { text-align: center; }
.beat .phone {
  width: min(214px, 62vw);
  margin: 0 auto 20px;
}
.beat h3 { font-size: 20px; }
.beat h3::before {
  counter-increment: beat;
  content: counter(beat) ". ";
  color: var(--accent-text);
}
.beat p { margin-top: 8px; color: var(--ink-dim); font-size: 16px; }

/* the recreated job-page UI inside the beat phones */
.phone-screen--ui {
  background: var(--card);
  color: var(--ink);
}
.ui-bar {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  z-index: 2;
  display: flex;
  align-items: center;
  gap: 5px;
  height: 26px;
  padding: 0 10px;
  background: var(--card);
  border-bottom: 1px solid var(--hairline);
}
.ui-bar svg { width: 12px; height: 12px; flex: none; }
.ui-bar b {
  font-family: var(--display);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: -0.03em;
}
.ui-fan {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  gap: 5px;
  padding: 0 10px;
}
/* the height attribute on the file is a presentational hint, so it has to be
   cleared before aspect-ratio can shape these */
.ui-fan img {
  width: 27%;
  height: auto;
  aspect-ratio: 9 / 16;
  object-fit: cover;
  object-position: 50% 8%;
  border-radius: 6px 6px 0 0;
  box-shadow: 0 -4px 14px -6px rgba(0, 0, 0, 0.5);
  transform: translateY(66%);
}
.ui-fan img:nth-child(1) { transform: translateY(72%) rotate(-7deg); }
.ui-fan img:nth-child(3) { transform: translateY(72%) rotate(7deg); }
.ui {
  position: absolute;
  inset: 26px 0 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 10px;
  padding: 14px;
  text-align: left;
}
.ui-paste { justify-content: center; text-align: center; }
.ui-paste .ui-fine { margin: 0 auto; max-width: 15ch; }
.ui-capsule {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 4px 4px 4px 10px;
  background: var(--fill-1);
  border: 1px solid var(--line);
  border-radius: 999px;
}
.ui-url {
  flex: 1 1 auto;
  min-width: 0;
  font-size: 12px;
  color: var(--ink-faint);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.ui-go {
  flex: none;
  padding: 3px 9px;
  font-size: 12px;
  font-weight: 600;
  color: var(--on-yellow);
  background: var(--yellow);
  border-radius: 999px;
}
.ui-fine { font-size: 12px; line-height: 1.35; color: var(--ink-faint); }

.ui-progress { justify-content: flex-start; padding-top: 16px; }
.ui-stage { font-size: 14px; font-weight: 600; letter-spacing: -0.01em; }
.ui-pct {
  font-size: 26px;
  font-weight: 700;
  letter-spacing: -0.03em;
  color: var(--accent-text);
  font-variant-numeric: tabular-nums;
}
.ui-rail {
  display: block;
  height: 4px;
  overflow: hidden;
  background: var(--fill-2);
  border-radius: 999px;
}
.ui-rail i {
  display: block;
  width: 48%;
  height: 100%;
  background: var(--yellow);
  border-radius: 999px;
}
.ui-eta { font-size: 12px; color: var(--ink-dim); }
.ui-stages {
  display: grid;
  gap: 6px;
  margin: 6px 0 0;
  padding: 0;
  list-style: none;
}
.ui-stages li {
  position: relative;
  padding-left: 14px;
  font-size: 12px;
  color: var(--ink-faint);
}
.ui-stages li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 6px;
  width: 6px;
  height: 6px;
  background: var(--fill-3);
  border-radius: 50%;
}
.ui-stages .is-done { color: var(--ink-dim); }
.ui-stages .is-done::before { background: var(--accent-line); }
.ui-stages .is-now { color: var(--ink); font-weight: 600; }
.ui-stages .is-now::before { background: var(--yellow); box-shadow: 0 0 0 3px var(--accent-soft); }

.ui-done { justify-content: flex-start; padding-top: 16px; }
.ui-cards {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 6px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.ui-cards li {
  position: relative;
  aspect-ratio: 9 / 16;
  overflow: hidden;
  border-radius: 6px;
  background: var(--screen);
}
.ui-cards img { width: 100%; height: 100%; object-fit: cover; }
.ui-rank {
  position: absolute;
  top: 3px;
  left: 3px;
  padding: 0 4px;
  font-size: 12px;
  font-weight: 700;
  line-height: 16px;
  color: var(--ink);
  background: rgba(0, 0, 0, 0.55);
  border-radius: 4px;
}
.ui-cards li:first-child .ui-rank { color: var(--on-yellow); background: var(--yellow); }
.ui-score {
  position: absolute;
  right: 3px;
  bottom: 3px;
  font-size: 12px;
  font-weight: 600;
  color: #FFF;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.8);
}
.ui-dl {
  margin-top: 2px;
  padding: 5px 0;
  font-size: 12px;
  font-weight: 600;
  text-align: center;
  color: var(--ink);
  background: var(--fill-2);
  border: 1px solid var(--line);
  border-radius: 999px;
}

@media (min-width: 734px) {
  .beats { grid-template-columns: repeat(3, 1fr); gap: 26px; }
}

/* ============================================================ the clip reel */

.reel-section > .reel-wrap,
.reel-section > .reel-head,
.reel-section > .fineprint { max-width: var(--wrap); }

.reel-wrap {
  position: relative;
  margin-top: 34px;
}

.reel {
  display: flex;
  gap: 14px;
  margin: 0;
  padding: 4px 0 18px;
  list-style: none;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-padding-left: 2px;
  scrollbar-width: thin;
  -webkit-overflow-scrolling: touch;
}
.reel:focus-visible { outline-offset: 6px; }
.reel-item {
  flex: 0 0 auto;
  width: clamp(150px, 46vw, 212px);
  scroll-snap-align: start;
}
.reel-item .phone { width: 100%; }
.reel-title {
  margin-top: 14px;
  font-size: 15px;
  font-weight: 600;
  line-height: 1.32;
  letter-spacing: -0.012em;
}
.reel-meta {
  margin-top: 5px;
  font-size: 13px;
  color: var(--ink-dim);
  font-variant-numeric: tabular-nums;
}
.reel-score {
  display: inline-block;
  min-width: 26px;
  margin-right: 2px;
  padding: 0 5px;
  font-weight: 700;
  color: var(--on-yellow);
  background: var(--yellow);
  border-radius: 5px;
  text-align: center;
}

.reel-arrow {
  position: absolute;
  top: calc(50% - 46px);
  z-index: 3;
  display: none;
  align-items: center;
  justify-content: center;
  width: var(--tap);
  height: var(--tap);
  padding: 0;
  color: var(--ink);
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 50%;
  box-shadow: var(--shadow-m);
  cursor: pointer;
  transition: transform 160ms ease, opacity 160ms ease, visibility 160ms;
}
.reel-arrow svg { width: 22px; height: 22px; }
.reel-arrow:hover { transform: scale(1.06); }
.reel-arrow[disabled] { opacity: 0; visibility: hidden; pointer-events: none; transform: none; }
.reel-arrow--prev { left: -18px; }
.reel-arrow--next { right: -18px; }
/* pointer-only, and only where the page is wide enough for the arrows to sit
   outside the rail without pushing the document sideways */
@media (hover: hover) and (pointer: fine) and (min-width: 900px) {
  .reel-arrow { display: flex; }
  /* soften the hard cut on the last visible card while there is more to see */
  .reel {
    -webkit-mask-image: linear-gradient(to right, #000 calc(100% - 72px), transparent);
    mask-image: linear-gradient(to right, #000 calc(100% - 72px), transparent);
  }
  .reel-wrap:has(.reel-arrow--next[disabled]) .reel {
    -webkit-mask-image: none;
    mask-image: none;
  }
}

/* ============================================================ what you get */

.tiles {
  display: grid;
  gap: 16px;
  margin: 36px auto 0;
  padding: 0;
  list-style: none;
}
.tile {
  overflow: hidden;
  padding: 16px 16px 20px;
  background: var(--card);
  border: 1px solid var(--hairline);
  border-radius: 22px;
  box-shadow: var(--shadow-s);
}
.tile h3 { margin-top: 16px; font-size: 19px; }
.tile p { margin-top: 7px; font-size: 15px; color: var(--ink-dim); }

.vig {
  position: relative;
  overflow: hidden;
  contain: paint;
  aspect-ratio: 16 / 10;
  background: var(--screen);
  border-radius: 14px;
}
.vig > img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* 1. three real clips trading places as their scores land */
.vig-rank {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  background: var(--panel);
}
.vigcard {
  position: relative;
  width: 23%;
  overflow: hidden;
  aspect-ratio: 9 / 16;
  background: var(--screen);
  border-radius: 7px;
  box-shadow: var(--shadow-s);
}
.vigcard img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 6%; }
.vig-score {
  position: absolute;
  left: 50%;
  bottom: 5px;
  padding: 0 5px;
  font-size: 12px;
  font-weight: 700;
  font-style: normal;
  line-height: 17px;
  color: #FFF;
  background: rgba(0, 0, 0, 0.6);
  border-radius: 5px;
  transform: translateX(-50%);
  font-variant-numeric: tabular-nums;
}
.vigcard-1 { box-shadow: 0 0 0 1.5px var(--yellow), var(--shadow-m); }
.vigcard-1 .vig-score { color: var(--on-yellow); background: var(--yellow); }
/* the best clip walks to the front and the one it passes steps back */
.is-live .vigcard-1 { animation: swap-1 4.6s cubic-bezier(0.3, 0.9, 0.3, 1) infinite; }
.is-live .vigcard-2 { animation: swap-2 4.6s cubic-bezier(0.3, 0.9, 0.3, 1) infinite; }
.is-live .vigcard-3 { animation: swap-3 4.6s ease-in-out infinite; }
@keyframes swap-1 {
  0%, 20% { transform: translateX(0) scale(1); }
  44%, 76% { transform: translateX(calc(-100% - 10px)) scale(1.08); }
  96%, 100% { transform: translateX(0) scale(1); }
}
@keyframes swap-2 {
  0%, 20% { transform: translateX(0) scale(1); }
  44%, 76% { transform: translateX(calc(100% + 10px)) scale(0.93); }
  96%, 100% { transform: translateX(0) scale(1); }
}
@keyframes swap-3 {
  0%, 100% { transform: scale(0.93); }
  50% { transform: scale(0.9); }
}

/* 2. word-by-word captions */
.vig-caption > img { object-position: 50% 5%; }
.vig-words {
  position: absolute;
  left: 50%;
  bottom: 14%;
  display: flex;
  justify-content: center;
  gap: 4px;
  max-width: 94%;
  transform: translateX(-50%);
}
.vig-words {
  padding: 3px 8px;
  background: rgba(0, 0, 0, 0.74);
  border-radius: 6px;
}
.vig-words i {
  font-family: var(--display);
  font-size: 12px;
  font-style: normal;
  font-weight: 700;
  color: #FFF;
  opacity: 0.4;
}
.is-live .vig-words i { animation: word 3.2s ease-in-out infinite; }
.is-live .vig-words i:nth-child(1) { animation-delay: 0s; }
.is-live .vig-words i:nth-child(2) { animation-delay: 0.32s; }
.is-live .vig-words i:nth-child(3) { animation-delay: 0.64s; }
.is-live .vig-words i:nth-child(4) { animation-delay: 0.96s; }
.is-live .vig-words i:nth-child(5) { animation-delay: 1.28s; }
@keyframes word {
  0%, 6% { opacity: 0.35; color: #FFF; }
  12%, 34% { opacity: 1; color: var(--yellow); }
  48%, 100% { opacity: 0.8; color: #FFF; }
}

/* 3. the 9:16 crop window gliding to the face */
.vig-crop {
  position: absolute;
  top: 6%;
  left: 8%;
  height: 88%;
  aspect-ratio: 9 / 16;
  border: 1.5px solid var(--yellow);
  border-radius: 5px;
  box-shadow: 0 0 0 900px rgba(0, 0, 0, 0.45);
}
.is-live .vig-crop { animation: crop-glide 5s cubic-bezier(0.4, 0, 0.2, 1) infinite; }
@keyframes crop-glide {
  0%, 12% { transform: translateX(0); }
  46%, 66% { transform: translateX(285%); }
  96%, 100% { transform: translateX(0); }
}

/* 4. the watermark coming off */
.vig-clean > img { object-position: 50% 8%; }
.vig-mark {
  position: absolute;
  right: 8%;
  bottom: 12%;
  padding: 2px 7px;
  font-size: 12px;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.85);
  background: rgba(0, 0, 0, 0.4);
  border-radius: 5px;
}
.is-live .vig-mark { animation: unmark 4.2s ease-in-out infinite; }
@keyframes unmark {
  0%, 32% { opacity: 1; transform: none; }
  58%, 100% { opacity: 0; transform: scale(1.3); }
}
.vig-badge {
  position: absolute;
  left: 8%;
  bottom: 12%;
  padding: 2px 7px;
  font-size: 12px;
  font-weight: 700;
  color: var(--on-yellow);
  background: var(--yellow);
  border-radius: 5px;
  opacity: 0;
}
.is-live .vig-badge { animation: badge-in 4.2s ease-in-out infinite; }
@keyframes badge-in {
  0%, 40% { opacity: 0; transform: translateY(4px); }
  62%, 100% { opacity: 1; transform: none; }
}

@media (min-width: 620px) {
  .tiles { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; }
}

/* ============================================================ price */

.price-card {
  max-width: 560px;
  margin: 34px auto 0;
  padding: 32px 28px;
  background: var(--card);
  border: 1px solid var(--accent-line);
  border-radius: 24px;
  box-shadow: var(--shadow-m), 0 0 70px -30px var(--glow);
  text-align: center;
}
.price-free {
  display: inline-block;
  padding: 6px 12px;
  font-size: 14px;
  font-weight: 600;
  color: var(--on-yellow);
  background: var(--yellow);
  border-radius: 999px;
}
.price-main { margin-top: 18px; font-size: 17px; }
.price-main strong {
  display: block;
  font-family: var(--display);
  font-size: clamp(52px, 11vw, 76px);
  font-weight: 600;
  letter-spacing: -0.04em;
  line-height: 1;
}
.price-alt { color: var(--ink-dim); }
.price-note {
  max-width: 340px;
  margin: 10px auto 0;
  font-size: 14px;
  line-height: 1.45;
  color: var(--ink-dim);
}
.price-unit { color: var(--ink-dim); }
.price-list {
  display: grid;
  gap: 10px;
  max-width: 300px;
  margin: 24px auto 0;
  padding: 0;
  list-style: none;
  color: var(--ink-dim);
  font-size: 16px;
  text-align: left;
}
.price-list li { position: relative; padding-left: 22px; }
.price-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 9px;
  width: 11px;
  height: 6px;
  border-left: 2px solid var(--accent-text);
  border-bottom: 2px solid var(--accent-text);
  transform: rotate(-45deg);
}

/* ============================================================ faq */

.faq {
  margin-top: 26px;
  border-top: 1px solid var(--hairline);
}
.faq details { border-bottom: 1px solid var(--hairline); }
.faq summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 62px;
  padding: 12px 2px;
  font-size: 18px;
  font-weight: 500;
  cursor: pointer;
  list-style: none;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "";
  flex: none;
  width: 10px;
  height: 10px;
  margin-right: 6px;
  border-right: 2px solid var(--accent-text);
  border-bottom: 2px solid var(--accent-text);
  transform: rotate(45deg) translateY(-2px);
  transition: transform 220ms ease;
}
.faq details[open] summary::after { transform: rotate(225deg) translateY(-2px); }
.answer { padding: 0 2px 18px; max-width: 680px; }
.answer p { color: var(--ink-dim); font-size: 16px; }
.answer-link {
  display: inline-flex;
  align-items: center;
  min-height: var(--tap);
  min-width: var(--tap);
  margin-top: 12px;
  padding: 0 14px;
  font-size: 15px;
  font-weight: 500;
  color: var(--accent-text);
  background: var(--fill-1);
  border: 1px solid var(--line);
  border-radius: 12px;
  text-decoration: none;
}
.answer-link:hover { background: var(--fill-2); }

/* ============================================================ closing */

.cta-end { text-align: center; }
.cta-end > h2 { max-width: 15ch; }
.cta-end .clip-form { margin: 30px auto 0; }

/* ============================================================ footer */

.footer {
  width: 100%;
  max-width: var(--wrap);
  margin: 0 auto;
  padding: 26px var(--pad) calc(34px + env(safe-area-inset-bottom, 0px));
  border-top: 1px solid var(--hairline);
}
.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 8px;
}
.footer-links a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: var(--tap);
  min-width: var(--tap);
  padding: 0 10px;
  font-size: 15px;
  color: var(--ink-dim);
  text-decoration: none;
  border-radius: 10px;
}
.footer-links a:hover { color: var(--ink); background: var(--fill-1); }
/* the job page runs wider than the landing copy column */
.footer--wide { max-width: 1120px; }
.copyright { margin-top: 8px; font-size: 14px; color: var(--ink-dim); }

/* ============================================================ auth sheet */

.sheet-backdrop {
  position: fixed;
  inset: 0;
  z-index: 90;
  background: rgba(0, 0, 0, 0.6);
  -webkit-backdrop-filter: blur(6px);
  backdrop-filter: blur(6px);
  opacity: 0;
  transition: opacity 220ms ease;
}
.sheet-backdrop.is-open { opacity: 1; }

.sheet {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  pointer-events: none;
}
.sheet-panel {
  position: relative;
  width: 100%;
  max-width: 440px;
  max-height: calc(100vh - 40px);
  overflow-y: auto;
  padding: 20px var(--pad) calc(24px + env(safe-area-inset-bottom, 0px));
  background: var(--card);
  border: 1px solid var(--line);
  border-bottom: 0;
  border-radius: 22px 22px 0 0;
  box-shadow: 0 -20px 60px rgba(0, 0, 0, 0.45);
  pointer-events: auto;
  transform: translateY(14px);
  opacity: 0;
  transition: transform 260ms cubic-bezier(.32, .72, 0, 1), opacity 200ms ease;
}
.sheet.is-open .sheet-panel { transform: none; opacity: 1; }

.sheet-grab {
  display: block;
  width: 38px;
  height: 4px;
  margin: -6px auto 14px;
  background: var(--fill-3);
  border-radius: 999px;
}
.sheet-close {
  position: absolute;
  top: 6px;
  right: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  width: var(--tap);
  height: var(--tap);
  padding: 0;
  color: var(--ink-dim);
  background: none;
  border: 0;
  cursor: pointer;
}
.sheet-close svg { width: 20px; height: 20px; }
.sheet-close:hover { color: var(--ink); }

.sheet-context {
  margin-bottom: 14px;
  padding-right: 40px;
  font-size: 15px;
  color: var(--ink);
}
.sheet-context .sheet-context-url {
  display: block;
  margin-top: 4px;
  font-size: 13px;
  color: var(--ink-dim);
  overflow-wrap: anywhere;
}

.sheet-tabs {
  display: flex;
  gap: 4px;
  padding: 4px;
  background: var(--fill-2);
  border-radius: 999px;
}
.sheet-tab {
  flex: 1 1 0;
  min-height: var(--tap);
  padding: 0 10px;
  font-family: inherit;
  font-size: 15px;
  font-weight: 500;
  color: var(--ink-dim);
  background: none;
  border: 0;
  border-radius: 999px;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
.sheet-tab[aria-selected="true"] {
  color: var(--ink);
  background: var(--card);
  box-shadow: var(--shadow-s);
}

.sheet-form { margin-top: 16px; }
.sheet-input {
  display: block;
  width: 100%;
  min-height: 52px;
  padding: 14px 16px;
  font-family: inherit;
  font-size: 17px;
  color: var(--ink);
  background: var(--fill-1);
  border: 1px solid var(--line);
  border-radius: 14px;
  appearance: none;
  transition: border-color 180ms ease, box-shadow 180ms ease;
}
.sheet-input::placeholder { color: var(--ink-faint); }
.sheet-input:focus {
  outline: none;
  border-color: var(--accent-line);
  box-shadow: 0 0 0 4px var(--accent-soft);
}
.sheet-input.is-invalid { border-color: var(--red); }
.sheet-form .error { margin-top: 8px; text-align: left; }
.sheet-form .clip-btn { margin-top: 12px; }

.sheet-fine {
  margin-top: 14px;
  font-size: 13px;
  line-height: 1.45;
  color: var(--ink-faint);
}
.sheet-fine a { color: var(--ink-dim); }

@media (min-width: 560px) {
  .sheet { align-items: center; }
  .sheet-panel {
    max-height: calc(100vh - 80px);
    padding: 24px;
    border: 1px solid var(--line);
    border-radius: 22px;
    transform: scale(0.96);
    box-shadow: var(--shadow-l);
  }
  .sheet.is-open .sheet-panel { transform: scale(1); }
  .sheet-grab { display: none; }
}

/* ============================================================ legal pages */

.page { padding-top: calc(var(--bar) + var(--bar-top) + 28px); }

.doc {
  width: 100%;
  max-width: 720px;
  margin: 0 auto;
  padding-left: var(--pad);
  padding-right: var(--pad);
  padding-bottom: 40px;
}
.doc h1 { font-size: clamp(30px, 6vw, 44px); }
.doc .updated { margin-top: 12px; font-size: 15px; color: var(--ink-dim); }
.doc h2 { font-size: 21px; margin-top: 32px; }
.doc p, .doc li { font-size: 16px; color: var(--ink); margin-top: 10px; }
.doc ul { padding-left: 20px; }
.back {
  display: inline-flex;
  align-items: center;
  min-height: var(--tap);
  min-width: var(--tap);
  margin-top: 28px;
  padding: 0 16px;
  font-size: 15px;
  font-weight: 500;
  color: var(--accent-text);
  background: var(--fill-1);
  border: 1px solid var(--line);
  border-radius: 12px;
  text-decoration: none;
}

/* ============================================================ job page */

.jobpage {
  width: 100%;
  max-width: 1120px;
  margin: 0 auto;
  padding-left: var(--pad);
  padding-right: var(--pad);
  padding-bottom: 64px;
}

a.clip-btn { text-decoration: none; }

/* small overlay chip: duration on a frame */
.jp-chip {
  padding: 3px 8px;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: -0.01em;
  color: #FFF;
  background: rgba(0, 0, 0, 0.55);
  border-radius: 8px;
  font-variant-numeric: tabular-nums;
}
@supports ((backdrop-filter: blur(8px)) or (-webkit-backdrop-filter: blur(8px))) {
  .jp-chip {
    background: rgba(0, 0, 0, 0.38);
    -webkit-backdrop-filter: blur(8px);
    backdrop-filter: blur(8px);
  }
}

/* ---------- first paint ---------- */

.jp-skeleton { display: grid; gap: 14px; max-width: 520px; }
.sk {
  background: linear-gradient(90deg, var(--fill-1), var(--fill-3), var(--fill-1));
  background-size: 220% 100%;
  border-radius: 12px;
  animation: sheen 1.5s linear infinite;
}
.sk-thumb { aspect-ratio: 16 / 9; border-radius: 18px; }
.sk-line-1 { height: 20px; max-width: 80%; }
.sk-line-2 { height: 14px; max-width: 40%; }
.sk-rail { height: 4px; margin-top: 10px; border-radius: 999px; }
@keyframes sheen {
  from { background-position: 120% 0; }
  to   { background-position: -120% 0; }
}

/* ---------- the video this job came from ---------- */

.jp-head { display: grid; gap: 18px; }

.jp-thumb {
  position: relative;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background: var(--screen);
  border: 1px solid var(--line);
  border-radius: 18px;
}
.jp-thumb-fallback {
  position: absolute;
  inset: 0;
  background: linear-gradient(150deg, var(--card-2), var(--screen));
}
.jp-thumb-img {
  position: relative;
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.jp-thumb-dur { position: absolute; right: 10px; bottom: 10px; }

.jp-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  color: var(--ink-dim);
}
.jp-eyebrow::before {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--fill-3);
}
.jp-eyebrow.is-live::before {
  background: var(--yellow);
  animation: pulse 1.9s ease-in-out infinite;
}
.jp-eyebrow.is-done::before { background: var(--yellow); }
@keyframes pulse {
  0%, 100% { opacity: 1; box-shadow: 0 0 0 0 rgba(255, 214, 10, 0.35); }
  60%      { opacity: 0.75; box-shadow: 0 0 0 6px rgba(255, 214, 10, 0); }
}

.jp-title {
  margin-top: 10px;
  font-size: clamp(26px, 5.4vw, 40px);
  letter-spacing: -0.028em;
}
.jp-source { margin-top: 8px; font-size: 15px; color: var(--ink-dim); }

@media (min-width: 734px) {
  .jobpage { padding-top: calc(var(--bar) + var(--bar-top) + 44px); }
  .jp-head {
    grid-template-columns: 312px minmax(0, 1fr);
    gap: 28px;
    align-items: center;
  }
}

/* ---------- progress ---------- */

.jp-progress {
  margin-top: 28px;
  padding: 20px 18px 22px;
  background: var(--card);
  border: 1px solid var(--hairline);
  border-radius: 20px;
  box-shadow: var(--shadow-s);
}
.jp-progress-top {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
}
.jp-stage-now { font-size: 19px; font-weight: 600; letter-spacing: -0.015em; }
.jp-pct {
  font-size: 19px;
  font-weight: 600;
  color: var(--accent-text);
  font-variant-numeric: tabular-nums;
}

.jp-rail {
  position: relative;
  height: 4px;
  margin-top: 14px;
  overflow: hidden;
  background: var(--fill-2);
  border-radius: 999px;
}
.jp-rail-fill {
  position: relative;
  display: block;
  width: 0;
  height: 100%;
  overflow: hidden;
  background: var(--yellow);
  border-radius: 999px;
  box-shadow: 0 0 16px rgba(255, 214, 10, 0.4);
  transition: width 700ms cubic-bezier(.4, 0, .2, 1);
}
/* a slow sheen so a stalled percentage still reads as "working" */
.jp-rail-fill::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg,
    rgba(255, 255, 255, 0) 0%, rgba(255, 255, 255, 0.55) 50%, rgba(255, 255, 255, 0) 100%);
  animation: railsheen 2.4s ease-in-out infinite;
}
@keyframes railsheen {
  0%   { transform: translateX(-100%); }
  60%, 100% { transform: translateX(100%); }
}

.jp-stages {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px 14px;
  margin: 18px 0 0;
  padding: 0;
  list-style: none;
}
.jp-stage {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  color: var(--ink-faint);
}
.jp-dot {
  flex: none;
  width: 7px;
  height: 7px;
  background: var(--fill-3);
  border-radius: 50%;
}
.jp-stage.is-done { color: var(--ink-dim); }
.jp-stage.is-done .jp-dot { background: var(--accent-line); }
.jp-stage.is-now { color: var(--ink); font-weight: 600; }
.jp-stage.is-now .jp-dot {
  background: var(--yellow);
  box-shadow: 0 0 0 4px var(--accent-soft);
}
@media (min-width: 560px) {
  .jp-stages { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}

.jp-meta {
  margin-top: 16px;
  font-size: 14px;
  color: var(--ink-dim);
  font-variant-numeric: tabular-nums;
}

/* ---------- keep this link ---------- */

.jp-keep {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-top: 14px;
  padding: 15px 18px;
  background: var(--fill-1);
  border: 1px solid var(--hairline);
  border-radius: 18px;
}
.jp-keep-title { font-size: 15px; font-weight: 600; }
.jp-keep-sub { margin-top: 3px; font-size: 13px; color: var(--ink-dim); }
.jp-copy {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  flex: none;
  min-height: var(--tap);
  padding: 0 16px;
  font-family: inherit;
  font-size: 15px;
  font-weight: 500;
  color: var(--ink);
  background: var(--fill-2);
  border: 1px solid var(--line);
  border-radius: 999px;
  cursor: pointer;
  transition: color 160ms ease, border-color 160ms ease;
  -webkit-tap-highlight-color: transparent;
}
.jp-copy svg { width: 17px; height: 17px; flex: none; }
.jp-copy:hover { background: var(--fill-3); }
.jp-copy.is-copied { color: var(--accent-text); border-color: var(--accent-line); }

@media (max-width: 559px) {
  .jp-keep { display: block; }
  .jp-copy { width: 100%; margin-top: 14px; }
}

/* ---------- failed ---------- */

.jp-fail { margin-top: 28px; }
.jp-fail-card {
  padding: 30px 20px;
  text-align: center;
  background: var(--card);
  border: 1px solid var(--red);
  border-radius: 22px;
}
.jp-fail-mark {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 46px;
  height: 46px;
  color: var(--red);
}
.jp-fail-mark svg { width: 34px; height: 34px; }
.jp-fail-title { margin-top: 10px; font-size: clamp(21px, 4.4vw, 26px); }
.jp-fail-msg {
  max-width: 440px;
  margin: 10px auto 0;
  font-size: 16px;
  color: var(--ink-dim);
}
.jp-fail .clip-btn { margin-top: 22px; }

/* ---------- unlock ---------- */

.jp-unlock { margin-top: 30px; }
.jp-unlock-card {
  padding: 24px 20px;
  background: var(--card);
  border: 1px solid var(--accent-line);
  border-radius: 22px;
  box-shadow: var(--shadow-s), 0 0 60px -34px var(--glow);
}
.jp-unlock.is-unlocked .jp-unlock-card {
  border-color: var(--hairline);
  box-shadow: var(--shadow-s);
}
.jp-unlock-eyebrow {
  display: inline-block;
  margin-bottom: 12px;
  padding: 5px 11px;
  font-size: 13px;
  font-weight: 600;
  color: var(--on-yellow);
  background: var(--yellow);
  border-radius: 999px;
}
.jp-unlock-title { font-size: clamp(20px, 4.2vw, 26px); letter-spacing: -0.022em; }
.jp-unlock-sub {
  max-width: 520px;
  margin-top: 10px;
  font-size: 15px;
  color: var(--ink-dim);
}
.jp-unlock-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 20px;
}
.jp-unlock-actions .clip-btn { min-height: 50px; }
.jp-unlock .clip-btn:disabled {
  opacity: 0.45;
  box-shadow: none;
  cursor: not-allowed;
}
.jp-unlock .clip-btn:disabled:hover { transform: none; }
.jp-ghost {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 50px;
  padding: 0 18px;
  font-size: 16px;
  font-weight: 500;
  color: var(--ink);
  background: var(--fill-2);
  border: 1px solid var(--line);
  border-radius: 999px;
  text-decoration: none;
}
.jp-ghost svg { width: 18px; height: 18px; color: var(--accent-text); }
.jp-ghost:hover { background: var(--fill-3); }
.jp-unlock-note { margin-top: 14px; font-size: 13px; color: var(--ink-dim); }

@media (max-width: 479px) {
  .jp-unlock-actions { display: grid; }
  .jp-unlock-actions .clip-btn,
  .jp-unlock-actions .jp-ghost { width: 100%; }
}

/* on a wide screen the card is a bar: the offer reads left, the action sits
   on the right instead of drifting under a very long line */
@media (min-width: 860px) {
  .jp-unlock-card {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
    gap: 10px 32px;
    padding: 26px 28px;
  }
  .jp-unlock-actions { margin-top: 0; justify-content: flex-end; }
  .jp-unlock-note { grid-column: 1 / -1; margin-top: 4px; }
}

/* ---------- clips ---------- */

.jp-clips { margin-top: 44px; }
.jp-clips-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 14px;
}
.jp-clips-title { font-size: clamp(22px, 4.6vw, 30px); letter-spacing: -0.025em; }
.jp-clips-sub { font-size: 14px; color: var(--ink-dim); text-align: right; }

.jp-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 14px;
  margin: 20px 0 0;
  padding: 0;
  list-style: none;
}
@media (min-width: 560px) { .jp-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 900px) { .jp-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; } }
@media (min-width: 1180px) { .jp-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); } }

.clipcard {
  display: flex;
  flex-direction: column;
  overflow: hidden;
  background: var(--card);
  border: 1px solid var(--hairline);
  border-radius: 18px;
  box-shadow: var(--shadow-s);
}
.clipcard.is-top { border-color: var(--accent-line); }

.clipcard-media {
  position: relative;
  aspect-ratio: 9 / 16;
  background: var(--screen);
}
/* the poster is a real image under the video: a <video poster> is at the
   mercy of the engine's media stack, and this also lazy-loads */
.clipcard-poster,
.clipcard-video {
  position: absolute;
  inset: 0;
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.clipcard-poster { background: var(--screen); }
.clipcard-video { opacity: 0; background: var(--screen); transition: opacity 200ms ease; }
.clipcard.is-playing .clipcard-video { opacity: 1; }
.clipcard-play {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  padding: 0;
  background: linear-gradient(180deg, rgba(0, 0, 0, 0.18), rgba(0, 0, 0, 0) 40%);
  border: 0;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
.clipcard-play-dot {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 56px;
  height: 56px;
  color: #FFF;
  background: rgba(10, 10, 10, 0.42);
  border: 1px solid rgba(255, 255, 255, 0.28);
  border-radius: 50%;
  transition: transform 180ms ease, background-color 180ms ease;
}
@supports ((backdrop-filter: blur(10px)) or (-webkit-backdrop-filter: blur(10px))) {
  .clipcard-play-dot {
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
  }
}
.clipcard-play-dot svg { width: 26px; height: 26px; margin-left: 2px; }
.clipcard-play:hover .clipcard-play-dot {
  transform: scale(1.06);
  background: rgba(10, 10, 10, 0.6);
}
.clipcard.is-playing .clipcard-play { display: none; }

.clipcard-rank {
  position: absolute;
  top: 10px;
  left: 10px;
  padding: 3px 9px;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: -0.01em;
  color: #FFF;
  background: rgba(0, 0, 0, 0.5);
  border-radius: 8px;
}
.clipcard.is-top .clipcard-rank { color: var(--on-yellow); background: var(--yellow); }
.clipcard-dur { position: absolute; right: 10px; bottom: 10px; }
.clipcard.is-playing .clipcard-dur { opacity: 0; }
.clipcard.is-playing .clipcard-rank { opacity: 0.55; }

.clipcard-body {
  display: flex;
  flex: 1 1 auto;
  flex-direction: column;
  gap: 12px;
  padding: 14px;
}
.clipcard-title {
  display: -webkit-box;
  overflow: hidden;
  font-size: 15px;
  font-weight: 600;
  line-height: 1.32;
  letter-spacing: -0.012em;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  line-clamp: 2;
}
.clipcard-score {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  margin-top: auto;
}
.clipcard-meter {
  flex: none;
  width: 72px;
  height: 3px;
  overflow: hidden;
  background: var(--fill-3);
  border-radius: 999px;
}
.clipcard-meter i {
  display: block;
  height: 100%;
  background: var(--yellow);
  border-radius: 999px;
}
.clipcard-scorenum {
  flex: none;
  font-size: 13px;
  color: var(--ink-dim);
  font-variant-numeric: tabular-nums;
}
.clipcard-dl {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: var(--tap);
  font-size: 15px;
  font-weight: 600;
  color: var(--ink);
  background: var(--fill-2);
  border: 1px solid var(--line);
  border-radius: 12px;
  text-decoration: none;
}
.clipcard-dl svg { width: 17px; height: 17px; color: var(--accent-text); }
.clipcard-dl:hover { background: var(--fill-3); }

/* ---------- no id / not found ---------- */

/* nothing to show: centre it in what is left of the screen rather than
   leaving it stranded under the bar */
.jp-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 56vh;
  max-width: 460px;
  margin: 0 auto;
  padding-bottom: 40px;
  text-align: center;
}
.jp-empty-mark {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 58px;
  height: 58px;
  color: var(--ink-dim);
  background: var(--fill-1);
  border: 1px solid var(--line);
  border-radius: 50%;
}
.jp-empty-mark svg { width: 26px; height: 26px; }
.jp-empty-title { margin-top: 20px; font-size: clamp(24px, 5vw, 32px); letter-spacing: -0.025em; }
.jp-empty-sub { margin-top: 10px; font-size: 16px; color: var(--ink-dim); }
.jp-empty .clip-btn { margin-top: 24px; }

/* ============================================================ wider screens */

@media (min-width: 620px) {
  :root { --pad: 28px; }
  .rights-note { max-width: 520px; }
  .capsule { height: 64px; }
  .capsule .clip-btn { height: 52px; }
  .capsule-input { font-size: 17px; padding-left: 20px; }
}

@media (min-width: 734px) {
  .section { padding-top: 116px; padding-bottom: 116px; }
  .swarm { padding-bottom: 72px; }
  .lede { font-size: 19px; }
}

@media (min-width: 1100px) {
  .section { padding-top: 144px; padding-bottom: 144px; }
  .swarm { padding-bottom: 88px; }
}

/* phone: keep the nested button, just tighter */
@media (max-width: 479px) {
  :root { --pad: 16px; }
  .clip-btn { min-width: 84px; padding: 0 16px; font-size: 16px; }
  .capsule-input { font-size: 16px; padding-left: 14px; }
  .editor-body { padding: 10px; gap: 10px; }
  .timeline { padding: 6px 6px 8px; }
  .tl-time--opt { display: none; }
  .editor-file { font-size: 12px; }
}

/* on a roomy screen the capsule sits a little above centre so the clips rising
   from the bottom edge belong to the same picture; a phone has no room to
   spare, so there it stays centred */
@media (min-height: 700px) and (min-width: 700px) {
  .clip-form { margin-bottom: clamp(24px, 8vh, 96px); }
  .cta-end .clip-form { margin-bottom: 0; }
}

/* very short viewports (landscape phones, foldable covers) */
@media (max-height: 520px) {
  .hero { padding-bottom: 46px; }
  .capsule { height: 58px; }          /* 44px input + 6px inset + 1px border */
  .capsule .clip-btn { height: 46px; }
  .scroll-cue { bottom: 2px; }
}

/* ============================================================ reduced motion */

@media (prefers-reduced-motion: reduce) {
  .hero::before,
  .scroll-cue svg,
  .spinner,
  .sk,
  .phone--fan,
  .cap-caret,
  .jp-eyebrow::before,
  .jp-rail-fill::after,
  .is-live .vigcard-1,
  .is-live .vigcard-2,
  .is-live .vigcard-3,
  .is-live .vig-words i,
  .is-live .vig-crop,
  .is-live .vig-mark,
  .is-live .vig-badge {
    animation: none !important;
  }
  .clip-btn,
  .bar-pill,
  .menu-sheet,
  .sheet-panel,
  .sheet-backdrop,
  .capsule,
  .js-anim .reveal,
  .jp-rail-fill,
  .jp-copy,
  .reel,
  .tl-marker,
  .tl-chip,
  .crop,
  .monitor-caption,
  .clipcard-play-dot {
    transition: none !important;
  }
  .jp-rail-fill::after { display: none; }
  .clip-btn:hover { transform: none; }
  .phone--fan { opacity: 1; }
  .vig-mark { opacity: 0.35; }
  .vig-badge { opacity: 1; }
  .vig-words i { opacity: 0.9; }
  .vig-words i:nth-child(2) { color: var(--yellow); }
  .reel { scroll-behavior: auto; }
  .clip-btn[aria-busy="true"] .spinner { border-top-color: transparent; }
}
