/* ==========================================================================
   Hufan — landing page
   ========================================================================== */

html { scroll-behavior: smooth; scroll-padding-top: 88px; }
body.landing main { overflow-x: clip; }
.container { width: 100%; max-width: 1200px; margin: 0 auto; padding: 0 32px; }

/* ------------------------------------------------------------------ Nav */
/* One frosted-glass surface: a floating bar on desktop that expands into the menu on phones */
.nav { position: fixed; inset: 0 0 auto 0; z-index: 60; padding: 10px 16px; pointer-events: none; }
.nav-inner {
  --glass: rgba(255, 255, 255, 0);
  --glass-line: rgba(0, 0, 0, 0);
  position: relative; pointer-events: auto;
  max-width: 1200px; margin: 0 auto; border-radius: 18px;
  background: var(--glass);
  border: 1px solid var(--glass-line);
  -webkit-backdrop-filter: saturate(1.6) blur(0px); backdrop-filter: saturate(1.6) blur(0px);
  transition: background-color 420ms var(--ease), border-color 420ms var(--ease), box-shadow 420ms var(--ease), backdrop-filter 420ms var(--ease), -webkit-backdrop-filter 420ms var(--ease), border-radius 420ms var(--ease-out);
}
.nav.is-scrolled .nav-inner, .nav.is-open .nav-inner {
  --glass: rgba(255, 255, 255, 0.62);
  --glass-line: rgba(0, 0, 0, 0.07);
  -webkit-backdrop-filter: saturate(1.8) blur(22px); backdrop-filter: saturate(1.8) blur(22px);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.7), 0 1px 2px rgba(0, 0, 0, 0.04), 0 14px 40px -20px rgba(0, 0, 0, 0.28);
}
.nav.is-open .nav-inner { --glass: rgba(255, 255, 255, 0.74); border-radius: 22px; }
@supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
  .nav.is-scrolled .nav-inner, .nav.is-open .nav-inner { --glass: rgba(255, 255, 255, 0.96); }
}
.nav-bar { height: 58px; display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; padding: 0 10px; }
.nav-logo { justify-self: start; display: inline-flex; padding: 6px 4px; border-radius: 8px; }

/* Desktop links with a pill that slides to the hovered or current section */
.nav-links { position: relative; display: flex; gap: 2px; }
.nav-links a {
  position: relative; z-index: 1; height: 36px; padding: 0 14px; border-radius: 10px;
  display: inline-flex; align-items: center; font-size: 14px; color: rgba(17, 17, 17, 0.66);
  transition: color var(--t) var(--ease);
}
.nav-links a:hover, .nav-links a.is-current { color: var(--ink); }
.nav-links a.is-current { font-weight: 500; }
.nav-pill {
  position: absolute; z-index: 0; top: 0; left: 0; height: 36px; width: 0; border-radius: 10px;
  background: rgba(0, 0, 0, 0.055); opacity: 0; pointer-events: none;
  transition: transform 380ms var(--ease-out), width 380ms var(--ease-out), opacity 220ms var(--ease);
}
.nav-pill.is-on { opacity: 1; }
.nav-actions { justify-self: end; display: flex; align-items: center; gap: 4px; }

/* Hamburger that turns into an X */
.nav-burger { display: none; position: relative; width: 40px; height: 40px; border-radius: 11px; transition: background-color var(--t) var(--ease); }
.nav-burger:hover { background: rgba(0, 0, 0, 0.05); }
.nav-burger span { position: absolute; left: 11px; right: 11px; height: 1.6px; border-radius: 2px; background: var(--ink); transition: transform 420ms var(--ease-out), top 420ms var(--ease-out); }
.nav-burger span:nth-child(1) { top: 16px; }
.nav-burger span:nth-child(2) { top: 22.5px; }
.nav.is-open .nav-burger span:nth-child(1) { top: 19.2px; transform: rotate(45deg); }
.nav.is-open .nav-burger span:nth-child(2) { top: 19.2px; transform: rotate(-45deg); }

/* Phone menu: the bar grows downward */
.nav-panel { display: none; }
.nav-scrim {
  position: fixed; inset: 0; z-index: 59; pointer-events: none; opacity: 0;
  background: rgba(247, 247, 247, 0.45);
  -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px);
  transition: opacity 380ms var(--ease);
}
.nav.is-open ~ .nav-scrim { opacity: 1; pointer-events: auto; }

/* ------------------------------------------------------------------ Hero */
.hero { position: relative; padding-top: 150px; }
.hero-inner { position: relative; z-index: 3; display: flex; flex-direction: column; align-items: center; text-align: center; }
.hero-title { margin-top: 24px; max-width: 1000px; }
.hero-sub { margin-top: 26px; max-width: 540px; }
.hero-ctas { display: flex; gap: 10px; margin-top: 34px; flex-wrap: wrap; justify-content: center; }

.hero-in { opacity: 0; animation: heroIn 1100ms var(--ease-out) forwards; animation-delay: calc(140ms + var(--i, 0) * 140ms); }
.eyebrow.hero-in { animation-name: fadeIn; animation-duration: 900ms; }
.hero-sub.hero-in, .hero-ctas.hero-in { animation-name: heroInSm; }
@keyframes heroIn { from { opacity: 0; transform: translateY(20px); } to { opacity: 1; transform: none; } }
@keyframes heroInSm { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }

/* Rotating headline: phrases share one grid cell so height never jumps */
.rot { display: grid; }
.rot .phrase { grid-area: 1 / 1; text-wrap: balance; }
.rot .w { display: inline-block; overflow: hidden; vertical-align: top; padding: 0 0.02em 0.1em; margin: 0 -0.02em -0.1em; }
.rot .w > span { display: inline-block; transform: translateY(108%); transition: transform 900ms var(--ease-out); transition-delay: calc(var(--k) * 36ms); }
.rot .phrase.is-active .w > span { transform: none; }
.rot .phrase.is-leaving .w > span { transform: translateY(-108%); transition: transform 600ms var(--ease-in-out); transition-delay: calc(var(--k) * 22ms); }
.rot .phrase:not(.is-active):not(.is-leaving) { visibility: hidden; }
.rot.is-still .w > span { transition: none; }

/* Command bar */
.cmd {
  width: min(760px, 100%); margin-top: 48px; text-align: left;
  background: #fff; border: 1px solid var(--line-2); border-radius: 18px;
  box-shadow: 0 1px 2px rgba(0,0,0,0.04), 0 30px 60px -28px rgba(0,0,0,0.28);
  transition: border-color var(--t) var(--ease), box-shadow var(--t) var(--ease);
  animation-name: cmdIn;
}
@keyframes cmdIn { from { opacity: 0; transform: translateY(14px) scale(0.985); } to { opacity: 1; transform: none; } }
.cmd:focus-within { border-color: rgba(0,0,0,0.22); box-shadow: 0 1px 2px rgba(0,0,0,0.04), 0 30px 60px -28px rgba(0,0,0,0.28), 0 0 0 5px rgba(17,17,17,0.04); }
.cmd-main { display: flex; align-items: flex-start; gap: 10px; padding: 10px; }
.cmd-add {
  flex: none; display: inline-flex; align-items: center; gap: 9px; height: 44px; padding: 0 14px 0 6px;
  border-radius: 12px; background: var(--s2); font-size: 13.5px; font-weight: 500; color: var(--ink-2);
  transition: background-color var(--t) var(--ease), transform var(--t-fast) var(--ease);
}
.cmd-add:hover { background: var(--s3); }
.cmd-add:active { transform: translateY(1px); }
.cmd-add-icon { width: 32px; height: 32px; border-radius: 9px; background: #fff; display: grid; place-items: center; box-shadow: var(--sh-1); overflow: hidden; flex: none; }
.cmd-add-icon img { width: 100%; height: 100%; object-fit: cover; }
.cmd-add.has-product { padding-right: 10px; }
.cmd-add.has-product .cmd-add-label { max-width: 140px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cmd-field { position: relative; flex: 1; min-width: 0; }
.cmd-field textarea {
  display: block; width: 100%; border: 0; outline: 0; resize: none; background: transparent;
  font-size: 15px; line-height: 22px; padding: 11px 4px; height: 44px; max-height: 132px; overflow-y: auto; color: var(--ink);
}
.cmd-field textarea::placeholder { color: transparent; }
.cmd-ghost { position: absolute; left: 4px; right: 4px; top: 11px; pointer-events: none; color: var(--faint); font-size: 15px; line-height: 22px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cmd-ghost.is-typing::after { content: ""; display: inline-block; width: 1.5px; height: 17px; background: var(--muted); margin-left: 1px; vertical-align: -3px; animation: blink 1s steps(1) infinite; }
.cmd-go { flex: none; height: 44px; }
.cmd-tools { display: flex; align-items: center; gap: 2px; padding: 7px 10px; border-top: 1px solid var(--line); overflow-x: auto; scrollbar-width: none; }
.cmd-tools::-webkit-scrollbar { display: none; }
.cmd-tool {
  height: 28px; padding: 0 10px; border-radius: 8px; font-size: 12.5px; font-weight: 500; color: var(--muted);
  display: inline-flex; align-items: center; gap: 6px; white-space: nowrap; transition: all var(--t) var(--ease);
}
.cmd-tool .i { width: 15px; height: 15px; }
.cmd-tool:hover { background: var(--s3); color: var(--ink); }
.cmd-tool.is-on { color: var(--ink); background: var(--s3); }
.cmd-hint { margin-left: auto; padding-left: 12px; font-size: 12px; color: var(--faint); display: inline-flex; gap: 6px; align-items: center; white-space: nowrap; }
.cmd-hint .i { width: 14px; height: 14px; }

/* Picker popover for "Add product" */
.pick { position: fixed; z-index: 70; width: 300px; padding: 8px; background: #fff; border: 1px solid var(--line); border-radius: 14px; box-shadow: var(--sh-3); opacity: 0; transform: translateY(-4px); transition: all 160ms var(--ease); }
.pick.is-open { opacity: 1; transform: none; }
.pick-upload { display: flex; align-items: center; gap: 10px; width: 100%; padding: 10px; border-radius: 10px; font-size: 13.5px; font-weight: 500; border: 1px dashed var(--line-3); position: relative; transition: all var(--t) var(--ease); }
.pick-upload:hover, .pick-upload.is-drag { border-color: var(--ink); background: var(--s1); }
.pick-upload input { position: absolute; inset: 0; opacity: 0; cursor: pointer; }
.pick-label { font-size: 11.5px; color: var(--faint); font-weight: 500; padding: 12px 6px 6px; }
.pick-item { display: flex; align-items: center; gap: 10px; width: 100%; padding: 6px; border-radius: 10px; text-align: left; transition: background-color var(--t-fast) var(--ease); }
.pick-item:hover { background: var(--s3); }
.pick-item img { width: 36px; height: 36px; border-radius: 8px; object-fit: cover; }
.pick-item b { display: block; font-size: 13.5px; font-weight: 500; }
.pick-item span { font-size: 12px; color: var(--muted); }

/* Hero stage — asymmetric UGC composition */
.hero-stage { position: relative; z-index: 1; height: 700px; margin: 72px auto 0; max-width: 1560px; }
.hero-stage::after { content: ""; position: absolute; left: 0; right: 0; bottom: -2px; height: 180px; z-index: 6; pointer-events: none; background: linear-gradient(to bottom, rgba(255,255,255,0), #fff 92%); }
.stage-card { position: absolute; left: 50%; will-change: transform; opacity: 0; animation: stageIn 1300ms var(--ease-out) forwards; }
.stage-card .media { border-radius: 18px; box-shadow: 0 2px 6px rgba(0,0,0,0.05), 0 30px 60px -30px rgba(0,0,0,0.35); }
.stage-card .tag-glass { position: absolute; left: 12px; top: 12px; z-index: 3; }
.stage-inner { transform: translateY(var(--py, 0px)); will-change: transform; }
@keyframes stageIn { from { opacity: 0; transform: translateY(48px); } to { opacity: 1; transform: none; } }
.s-main { width: 320px; margin-left: -160px; top: 0; z-index: 4; animation-delay: 900ms; }
.s-back-l { width: 232px; margin-left: calc(-160px - 232px - 40px); top: 110px; z-index: 3; animation-delay: 1040ms; }
.s-back-r { width: 232px; margin-left: calc(160px + 40px); top: 56px; z-index: 3; animation-delay: 1120ms; }
.s-edge-l { width: 210px; left: 0; margin-left: -46px; top: 250px; z-index: 2; animation-delay: 1240ms; }
.s-edge-r { width: 210px; left: auto; right: -40px; top: 190px; z-index: 2; animation-delay: 1300ms; }
.s-main .media-meta .tag { font-variant-numeric: tabular-nums; }

.stage-note {
  position: absolute; z-index: 5; right: -178px; top: 56%;
  width: 214px; padding: 12px 14px 12px; border-radius: 14px; background: rgba(255,255,255,0.94);
  -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px);
  border: 1px solid var(--line); box-shadow: var(--sh-3);
  opacity: 0; animation: riseSm 800ms var(--ease-out) 1900ms forwards;
}
.stage-note-head { display: flex; align-items: center; gap: 8px; font-size: 12.5px; font-weight: 500; padding-bottom: 8px; border-bottom: 1px solid var(--line); }
.stage-note-head .i { width: 15px; height: 15px; color: var(--accent); }
.stage-note ul { display: grid; gap: 6px; padding-top: 9px; }
.stage-note li { display: flex; align-items: center; gap: 8px; font-size: 12.5px; color: var(--ink-2); opacity: 0; animation: riseSm 600ms var(--ease-out) forwards; }
.stage-note li:nth-child(1) { animation-delay: 2150ms; }
.stage-note li:nth-child(2) { animation-delay: 2300ms; }
.stage-note li:nth-child(3) { animation-delay: 2450ms; }
.stage-note li .i { width: 14px; height: 14px; color: var(--muted); }

.hero-edge { position: absolute; z-index: 1; width: 176px; opacity: 0; animation: fadeIn 1400ms var(--ease-out) 1400ms forwards; }
.hero-edge .media { border-radius: 16px; box-shadow: 0 20px 50px -30px rgba(0,0,0,0.35); }
.hero-edge-l { left: -54px; top: 168px; }
.hero-edge-r { right: -48px; top: 330px; width: 164px; }

/* ------------------------------------------------------------------ Section scaffolding */
.section-index { display: inline-block; }
.feat-label { display: inline-flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 500; color: var(--ink); }
.feat-label .i { width: 16px; height: 16px; color: var(--muted); }

/* ------------------------------------------------------------------ Models */
.models { padding: 36px 0 8px; }
.models-inner { display: grid; justify-items: center; gap: 22px; }
.models-title { font-size: 13px; font-weight: 500; letter-spacing: 0.02em; color: var(--muted); }
.models-row { display: grid; grid-template-columns: repeat(3, auto); justify-content: center; gap: 10px; }
@media (min-width: 1240px) { .models-row { grid-template-columns: repeat(6, auto); } }
.model-chip {
  display: flex; align-items: center; gap: 11px; padding: 9px 16px 9px 9px;
  background: #fff; border: 1px solid var(--line); border-radius: 14px; box-shadow: 0 1px 2px rgba(0, 0, 0, 0.03);
  transition: border-color var(--t) var(--ease), box-shadow var(--t) var(--ease), transform var(--t) var(--ease-out);
}
.model-chip:hover { border-color: var(--line-2); box-shadow: var(--sh-2); transform: translateY(-1px); }
.mc-t { display: grid; line-height: 1.3; }
.mc-t b { font-size: 14px; font-weight: 500; letter-spacing: -0.01em; }
.mc-t span { font-size: 12px; color: var(--muted); }

/* ------------------------------------------------------------------ Idea → UGC */
.idea { padding-top: 110px; }
.idea-head { text-align: center; display: grid; justify-items: center; gap: 18px; }
.idea-lead { max-width: 560px; }
.idea-track { position: relative; height: 330vh; margin-top: 8px; }
.idea-sticky { position: sticky; top: 0; height: 100vh; height: 100svh; display: flex; align-items: center; }
.idea-grid { display: grid; grid-template-columns: 196px minmax(0, 460px) 300px; gap: 56px; justify-content: center; align-items: center; }
.idea-stage { display: contents; }

.idea-steps { display: grid; }
.idea-steps li { display: grid; grid-template-columns: 30px 1fr; padding: 14px 0; color: var(--ghost); transition: color 500ms var(--ease); }
.idea-steps .n { grid-row: span 3; font-size: 12px; font-variant-numeric: tabular-nums; padding-top: 4px; }
.idea-steps .t { font-size: 18px; font-weight: 500; letter-spacing: -0.015em; line-height: 1.3; }
.idea-steps .d { font-size: 13px; line-height: 1.4; margin-top: 2px; }
.idea-steps .bar { display: block; height: 2px; background: var(--s4); margin-top: 12px; border-radius: 2px; overflow: hidden; }
.idea-steps .bar b { display: block; height: 100%; width: calc(var(--p, 0) * 100%); background: var(--ink); border-radius: 2px; }
.idea-steps li.is-done { color: var(--muted); }
.idea-steps li.is-active { color: var(--ink); }
.idea-steps li.is-active .d { color: var(--muted); }

.idea-composer {
  position: relative; display: grid; gap: 14px; padding: 18px; overflow: hidden;
  background: #fff; border: 1px solid var(--line); border-radius: 20px;
  box-shadow: 0 2px 6px rgba(0,0,0,0.03), 0 40px 80px -40px rgba(0,0,0,0.25);
}
.ic-head { display: flex; justify-content: space-between; align-items: center; }
.ic-refs { display: flex; gap: 14px; align-items: center; padding: 10px; background: var(--s1); border-radius: 13px; }
.ic-slot { position: relative; width: 60px; height: 60px; flex: none; border-radius: 11px; border: 1px dashed var(--line-3); background: #fff; display: grid; place-items: center; color: var(--faint); overflow: hidden; transition: border-color 400ms var(--ease); }
.ic-slot-img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: 0; transform: translateY(-36px) scale(1.15); transition: opacity 600ms var(--ease-out), transform 800ms var(--ease-out); }
.ic-ref-meta { display: grid; gap: 1px; min-width: 0; flex: 1; }
.ic-ref-k { font-size: 12px; color: var(--faint); }
.ic-ref-v { font-size: 14px; font-weight: 500; position: relative; height: 21px; }
.ic-ref-name, .ic-ref-empty { position: absolute; left: 0; top: 0; white-space: nowrap; transition: opacity 400ms var(--ease), transform 400ms var(--ease); }
.ic-ref-name { opacity: 0; transform: translateY(6px); }
.ic-ref-empty { color: var(--faint); font-weight: 400; }
.ic-lock { justify-self: start; margin-top: 4px; opacity: 0; transition: opacity 400ms var(--ease) 200ms; }
.idea-track.has-product .ic-slot { border-style: solid; border-color: transparent; }
.idea-track.has-product .ic-slot-img { opacity: 1; transform: none; }
.idea-track.has-product .ic-ref-name { opacity: 1; transform: none; }
.idea-track.has-product .ic-ref-empty { opacity: 0; transform: translateY(-6px); }
.idea-track.has-product .ic-lock { opacity: 1; }

.ic-prompt { position: relative; min-height: 52px; font-size: 17px; line-height: 1.5; letter-spacing: -0.01em; padding: 2px; }
.ic-placeholder { position: absolute; left: 2px; top: 2px; color: var(--faint); transition: opacity 200ms; }
.idea-track.has-text .ic-placeholder { opacity: 0; }
.ic-caret { display: inline-block; width: 1.5px; height: 1.05em; background: var(--ink); vertical-align: -0.16em; margin-left: 1px; animation: blink 1s steps(1) infinite; }
.idea-track:not([data-step="1"]) .ic-prompt .ic-caret { opacity: 0; }

.ic-director { display: grid; gap: 10px; padding: 14px; border-radius: 13px; background: var(--s1); border: 1px solid var(--line); min-height: 206px; align-content: start; }
.ic-dir-head { display: flex; align-items: center; gap: 9px; font-size: 13px; }
.ic-dir-mark { width: 24px; height: 24px; border-radius: 7px; background: var(--ink); color: #fff; display: grid; place-items: center; }
.ic-dir-mark .i { width: 14px; height: 14px; }
.ic-dir-head::after { content: "Standing by"; margin-left: auto; font-size: 11.5px; color: var(--faint); transition: opacity 300ms; }
.idea-track.is-directing .ic-dir-head::after { content: "Directing"; color: var(--accent-ink); }
.idea-track.is-directed .ic-dir-head::after { content: "Applied"; color: var(--muted); }
.ic-dir-msg, .ic-dir-prompt, .ic-dir-chips { opacity: 0; transform: translateY(6px); transition: opacity 500ms var(--ease), transform 500ms var(--ease-out); }
.ic-dir-msg { font-size: 13.5px; color: var(--ink-2); }
.ic-dir-prompt { font-size: 13px; line-height: 1.6; color: var(--muted); transition-delay: 120ms; }
.ic-dir-prompt mark { background: transparent; color: var(--ink); background-image: linear-gradient(var(--accent-soft), var(--accent-soft)); background-size: 0% 100%; background-repeat: no-repeat; transition: background-size 900ms var(--ease-out) 400ms; border-radius: 3px; box-decoration-break: clone; -webkit-box-decoration-break: clone; }
.ic-dir-chips { display: flex; gap: 6px; flex-wrap: wrap; transition-delay: 240ms; }
.idea-track.is-directed .ic-dir-msg, .idea-track.is-directed .ic-dir-prompt, .idea-track.is-directed .ic-dir-chips { opacity: 1; transform: none; }
.idea-track.is-directed .ic-dir-prompt mark { background-size: 100% 100%; }

.ic-foot { display: flex; align-items: center; justify-content: space-between; }
.ic-go { pointer-events: none; }
.ic-progress { position: absolute; left: 0; right: 0; bottom: 0; height: 2px; border-radius: 0; background: transparent; }
.ic-progress > i { background: var(--accent); }

.idea-output { display: grid; justify-items: center; }
.io-frame { position: relative; width: 300px; aspect-ratio: 9 / 16; border-radius: 22px; background: var(--canvas); overflow: hidden; box-shadow: inset 0 0 0 1px rgba(0,0,0,0.05); }
.io-empty { position: absolute; inset: 0; display: grid; place-content: center; justify-items: center; gap: 12px; color: var(--faint); font-size: 13px; transition: opacity 400ms var(--ease); }
.io-empty .i { stroke-width: 1.2; }
.io-scan { position: absolute; inset: 0; opacity: 0; transition: opacity 500ms var(--ease); }
.io-grid { position: absolute; inset: 0; background-image: linear-gradient(rgba(0,0,0,0.07) 1px, transparent 1px), linear-gradient(90deg, rgba(0,0,0,0.07) 1px, transparent 1px); background-size: 33.34% 33.34%; background-position: -1px -1px; }
.io-scanline { position: absolute; left: 0; right: 0; top: 0; height: 90px; margin-top: -90px; background: linear-gradient(to bottom, rgba(239,90,42,0), rgba(239,90,42,0.12)); border-bottom: 1px solid rgba(239,90,42,0.55); animation: scan 2.4s var(--ease-in-out) infinite alternate; }
.io-stage-msg { position: absolute; left: 12px; bottom: 12px; display: inline-flex; gap: 8px; align-items: center; font-size: 12px; font-weight: 500; background: rgba(255,255,255,0.92); padding: 6px 10px; border-radius: 8px; box-shadow: var(--sh-1); }
.io-video { position: absolute; inset: 0; opacity: 0; transform: scale(1.02); transition: opacity 900ms var(--ease), transform 1200ms var(--ease-out); }
.io-video .media { position: absolute; inset: 0; border-radius: 0; aspect-ratio: auto; }
.io-meta { position: absolute; left: 12px; bottom: 12px; z-index: 3; display: flex; gap: 6px; opacity: 0; transition: opacity 500ms var(--ease) 500ms; }
.idea-track[data-step="2"] .io-scan, .idea-track[data-step="3"]:not(.is-video) .io-scan { opacity: 1; }
.idea-track[data-step="2"] .io-empty, .idea-track[data-step="3"] .io-empty { opacity: 0; }
.idea-track.is-video .io-video { opacity: 1; transform: none; }
.idea-track.is-video .io-meta { opacity: 1; }
.idea-track.is-video .io-scan { opacity: 0; }

/* ------------------------------------------------------------------ Features */
.features { padding-top: 150px; }
.features-head { text-align: center; display: grid; justify-items: center; gap: 18px; margin-bottom: 72px; }
.feat { padding-top: 72px; padding-bottom: 72px; }
.feat-copy { display: grid; gap: 16px; align-content: start; }
.feat-copy .body { font-size: 16px; line-height: 1.6; max-width: 440px; }
.feat-copy-center { text-align: center; justify-items: center; max-width: 640px; margin: 0 auto 48px; }
.feat-copy-center .body { max-width: 540px; }
.feat-split { display: grid; grid-template-columns: minmax(0, 380px) minmax(0, 1fr); gap: 88px; align-items: center; }
.feat-reverse { grid-template-columns: minmax(0, 1fr) minmax(0, 380px); }
.feat-reverse .feat-copy { order: 2; }

/* Text to UGC */
.tt-composer { max-width: 960px; margin: 0 auto; padding: 18px; border-radius: 26px; background: var(--s1); border: 1px solid var(--line); }
.tt-bar { display: flex; gap: 12px; align-items: center; min-height: 76px; padding: 12px 12px 12px 20px; background: #fff; border: 1px solid var(--line-2); border-radius: 17px; box-shadow: 0 1px 2px rgba(0,0,0,0.04), 0 18px 40px -26px rgba(0,0,0,0.25); }
.tt-field { flex: 1; min-width: 0; font-size: 18px; line-height: 1.45; letter-spacing: -0.012em; color: var(--ink); }
.tt-spark { display: inline-block; width: 17px; height: 17px; color: var(--accent); vertical-align: -2px; margin-right: 10px; }
.tt-go { flex: none; }
.tt-examples { display: flex; gap: 6px; padding: 14px 2px 16px; overflow-x: auto; scrollbar-width: none; }
.tt-examples::-webkit-scrollbar { display: none; }
.tt-results { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.tt-result { position: relative; }
.tt-result .media { border-radius: 14px; }
.tt-result .skeleton { position: absolute; inset: 0; border-radius: 14px; opacity: 0; transition: opacity 300ms var(--ease); z-index: 4; }
.tt-results.is-loading .skeleton { opacity: 1; }
.tt-results .media { transition: opacity 500ms var(--ease), transform 700ms var(--ease-out); }
.tt-results.is-loading .media { opacity: 0; transform: scale(0.985); }
.tt-result .media-meta { opacity: 1; }

/* Image to Video */
.i2v { display: grid; grid-template-columns: 190px minmax(0, 1fr) 250px; gap: 28px; align-items: center; }
.i2v figure { display: grid; gap: 10px; }
.i2v figcaption { display: flex; justify-content: space-between; }
.i2v-img { border-radius: 14px; box-shadow: var(--sh-2); }
.i2v-img img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.i2v-vid .media { border-radius: 16px; box-shadow: 0 30px 60px -30px rgba(0,0,0,0.35); }
.i2v-mid { display: grid; gap: 18px; }
.i2v-analysis { display: grid; border-top: 1px solid var(--line); }
.i2v-row { display: flex; justify-content: space-between; align-items: center; padding: 9px 0; border-bottom: 1px solid var(--line); font-size: 13px; color: var(--muted); opacity: 0; transform: translateX(-6px); transition: opacity 500ms var(--ease), transform 500ms var(--ease-out); }
.i2v-row b { font-weight: 500; color: var(--ink); display: inline-flex; align-items: center; gap: 7px; }
.i2v-row b::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: #2f9e5b; }
.i2v-line { position: relative; height: 1px; background: var(--line-2); }
.i2v-line i { position: absolute; left: 0; top: -2px; width: 5px; height: 5px; border-radius: 50%; background: var(--accent); opacity: 0; }
.i2v-suggest { display: flex; gap: 10px; font-size: 13.5px; line-height: 1.5; color: var(--ink-2); opacity: 0; transition: opacity 600ms var(--ease) 1300ms; }
.i2v-suggest .i { flex: none; width: 16px; height: 16px; color: var(--accent); margin-top: 2px; }
.i2v-video { opacity: 0.001; transform: translateX(-12px); transition: opacity 900ms var(--ease) 1600ms, transform 900ms var(--ease-out) 1600ms; }
.i2v.is-in .i2v-row { opacity: 1; transform: none; }
.i2v.is-in .i2v-row:nth-child(2) { transition-delay: 140ms; }
.i2v.is-in .i2v-row:nth-child(3) { transition-delay: 280ms; }
.i2v.is-in .i2v-row:nth-child(4) { transition-delay: 420ms; }
.i2v.is-in .i2v-line i { animation: travel 2.6s var(--ease-in-out) 700ms infinite; }
.i2v.is-in .i2v-suggest { opacity: 1; }
.i2v.is-in .i2v-video { opacity: 1; transform: none; }
@keyframes travel { 0% { left: 0; opacity: 0; } 15% { opacity: 1; } 85% { opacity: 1; } 100% { left: calc(100% - 5px); opacity: 0; } }

.feat-locks { display: grid; grid-template-columns: 1fr 1fr; gap: 0 20px; margin-top: 8px; }
.feat-locks li { display: flex; align-items: center; gap: 9px; font-size: 13.5px; color: var(--ink-2); padding: 10px 0; border-bottom: 1px solid var(--line); }
.feat-locks .i { width: 15px; height: 15px; color: var(--muted); }

/* Product UGC */
.pu { position: relative; height: 580px; }
.pu-upload { position: absolute; left: 0; top: 70px; width: 230px; background: #fff; border: 1px solid var(--line); border-radius: 16px; padding: 10px; box-shadow: var(--sh-2); display: grid; gap: 10px; z-index: 2; }
.pu-upload-head { display: flex; align-items: center; gap: 8px; font-size: 12.5px; color: var(--muted); padding: 2px 4px; }
.pu-upload-head .i { width: 15px; height: 15px; }
.pu-upload-head span { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pu-upload-img { aspect-ratio: 1; border-radius: 10px; overflow: hidden; background: var(--s3); }
.pu-upload-img img { width: 100%; height: 100%; object-fit: cover; }
.pu-path { position: absolute; left: 212px; right: 300px; top: 150px; height: 140px; z-index: 1; }
.pu-path svg { width: 100%; height: 100%; overflow: visible; }
.pu-path-m { display: none; }
.pu-path path { fill: none; stroke: var(--ink); stroke-width: 1.2; stroke-dasharray: 3 5; vector-effect: non-scaling-stroke; opacity: 0.35; stroke-dashoffset: 0; }
.pu.is-in .pu-path path { animation: dash 1.2s linear infinite; }
@keyframes dash { to { stroke-dashoffset: -16; } }
.pu-scene { position: absolute; right: 0; top: 0; width: 320px; }
.pu-vid .media { border-radius: 18px; box-shadow: 0 30px 60px -30px rgba(0,0,0,0.35); }
.pu-token { position: absolute; left: -24px; bottom: 56px; z-index: 3; display: flex; align-items: center; gap: 9px; padding: 6px 12px 6px 6px; border-radius: 12px; background: #fff; box-shadow: var(--sh-3); font-size: 12.5px; font-weight: 500; opacity: 0; transform: translate(var(--tx, -220px), var(--ty, -250px)) scale(1.25); }
.pu-token img { width: 34px; height: 34px; border-radius: 8px; object-fit: cover; }
.pu-token .i { color: var(--muted); }
.pu.is-in .pu-token { animation: tokenIn 1.6s var(--ease-out) 500ms forwards; }
@keyframes tokenIn { 0% { opacity: 0; transform: translate(var(--tx, -220px), var(--ty, -250px)) scale(1.25); } 30% { opacity: 1; } 100% { opacity: 1; transform: none; } }

.feat-facts { display: grid; margin-top: 8px; border-top: 1px solid var(--line); }
.feat-facts div { display: flex; justify-content: space-between; gap: 16px; padding: 11px 0; border-bottom: 1px solid var(--line); font-size: 13.5px; }
.feat-facts dt { color: var(--muted); }
.feat-facts dd { margin: 0; color: var(--ink); font-weight: 500; }

/* Fix image */
.fx { display: grid; grid-template-columns: minmax(0, 520px) 340px; gap: 40px; justify-content: center; align-items: center; }
.ba { position: relative; aspect-ratio: 4 / 5; border-radius: 20px; overflow: hidden; cursor: ew-resize; user-select: none; -webkit-user-select: none; touch-action: pan-y; --x: 50%; background: var(--s3); box-shadow: 0 30px 70px -40px rgba(0,0,0,0.4); }
.ba img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; pointer-events: none; }
.ba-before { position: absolute; inset: 0; clip-path: inset(0 calc(100% - var(--x)) 0 0); }
.ba-before > img:first-child { filter: saturate(0.9) contrast(0.96) brightness(1.02); }
.ba-warp { filter: url(#hufanWarp); -webkit-mask-image: radial-gradient(ellipse 24% 27% at 47% 45%, #000 50%, transparent 100%); mask-image: radial-gradient(ellipse 24% 27% at 47% 45%, #000 50%, transparent 100%); }
.ba-mark { position: absolute; display: grid; justify-items: center; gap: 6px; transform: translate(-50%, -50%); pointer-events: none; }
.ba-mark i { display: block; width: 92px; height: 92px; border-radius: 50%; border: 1.5px dashed rgba(255,255,255,0.95); box-shadow: 0 0 0 1px rgba(0,0,0,0.08); }
.ba-mark em { font-style: normal; font-size: 11.5px; font-weight: 500; color: var(--ink); background: #fff; padding: 3px 8px; border-radius: 6px; box-shadow: var(--sh-1); }
.ba-mark-1 { left: 42%; top: 55%; }
.ba-mark-2 { left: 52%; top: 31%; }
.ba-mark-2 i { width: 70px; height: 70px; }
.ba-handle { position: absolute; top: 0; bottom: 0; left: var(--x); width: 0; z-index: 4; }
.ba-handle::before { content: ""; position: absolute; top: 0; bottom: 0; left: -1px; width: 2px; background: #fff; box-shadow: 0 0 0 0.5px rgba(0,0,0,0.12), 0 0 12px rgba(0,0,0,0.15); }
.ba-handle span { position: absolute; top: 50%; left: 0; transform: translate(-50%, -50%); width: 44px; height: 44px; border-radius: 50%; background: #fff; box-shadow: var(--sh-2); display: grid; grid-auto-flow: column; place-content: center; transition: transform var(--t) var(--ease); }
.ba-handle span .i { width: 14px; height: 14px; margin: 0 -2px; }
.ba:hover .ba-handle span, .ba.is-drag .ba-handle span { transform: translate(-50%, -50%) scale(1.06); }
.ba-tag { position: absolute; top: 14px; z-index: 5; font-size: 12px; font-weight: 500; color: var(--ink); padding: 4px 9px; border-radius: 7px; background: rgba(255,255,255,0.9); pointer-events: none; }
.ba-tag-l { left: 14px; }
.ba-tag-r { right: 14px; }
.ba:focus-visible { outline: 2px solid var(--accent); outline-offset: 4px; }

.fx-panel { display: grid; gap: 22px; }
.fx-head { display: flex; align-items: center; gap: 9px; font-size: 14px; }
.fx-head .i { color: var(--muted); }
.diag { display: grid; border-top: 1px solid var(--line); }
.diag-row { display: flex; justify-content: space-between; align-items: center; padding: 11px 0; border-bottom: 1px solid var(--line); font-size: 13.5px; color: var(--muted); }
.diag-row .status { font-size: 13px; font-weight: 500; }
.fx-rec { display: grid; gap: 8px; padding: 14px 16px; border-radius: 12px; background: var(--s1); }
.fx-rec p { font-size: 14px; line-height: 1.55; color: var(--ink-2); }

/* ------------------------------------------------------------------ Director */
.director { padding: 150px 0 140px; }
.director-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 540px); gap: 88px; align-items: start; }
.director-copy { display: grid; gap: 20px; align-content: start; padding-top: 12px; }
.director-copy .lead { max-width: 480px; }
.detects { margin-top: 20px; }
.detects ul { display: grid; grid-template-columns: 1fr 1fr; gap: 0 24px; margin-top: 10px; border-top: 1px solid var(--line); }
.detects li { display: flex; gap: 10px; align-items: center; padding: 11px 0; border-bottom: 1px solid var(--line); font-size: 14px; color: var(--ink-2); }
.detects li .i { width: 16px; height: 16px; color: var(--muted); }

.dir-demo { position: sticky; top: 104px; padding: 12px; background: #fff; border: 1px solid var(--line); border-radius: 22px; box-shadow: 0 2px 6px rgba(0,0,0,0.03), 0 40px 80px -40px rgba(0,0,0,0.3); }
.dir-input { display: flex; gap: 8px; align-items: center; padding: 6px 6px 6px 16px; border: 1px solid var(--line-2); border-radius: 14px; background: var(--s1); transition: border-color var(--t) var(--ease), background-color var(--t) var(--ease); }
.dir-input:focus-within { border-color: var(--ink); background: #fff; }
.dir-field { flex: 1; min-width: 0; border: 0; outline: 0; background: transparent; font-size: 15px; height: 36px; }
.dir-out { padding: 18px 8px 8px; display: grid; gap: 16px; min-height: 380px; align-content: start; }
.dir-say { display: flex; gap: 12px; align-items: flex-start; }
.dir-avatar { width: 28px; height: 28px; border-radius: 8px; background: var(--ink); color: #fff; display: grid; place-items: center; flex: none; }
.dir-avatar .i { width: 15px; height: 15px; }
.dir-say p { font-size: 14.5px; line-height: 1.55; color: var(--ink); padding-top: 3px; }
.dir-say .who { font-size: 12px; color: var(--faint); display: block; margin-bottom: 2px; }
.dir-prompt { font-size: 14.5px; line-height: 1.7; color: var(--ink-2); padding: 14px 16px; border-radius: 13px; background: var(--s1); border: 1px solid var(--line); outline: none; transition: border-color var(--t) var(--ease), background-color var(--t) var(--ease); }
.dir-prompt[contenteditable="true"] { background: #fff; border-color: var(--ink); }
.dir-prompt mark { background: var(--accent-soft); color: var(--ink); border-radius: 4px; padding: 1px 2px; -webkit-box-decoration-break: clone; box-decoration-break: clone; }
.dir-prompt.is-original { color: var(--muted); }
.dir-chips { display: flex; gap: 6px; flex-wrap: wrap; }
.dir-warns { display: grid; gap: 8px; }
.dir-warn { display: flex; gap: 10px; padding: 10px 12px; border-radius: 11px; border: 1px solid var(--line); font-size: 13px; line-height: 1.45; color: var(--ink-2); }
.dir-warn .i { width: 16px; height: 16px; color: #b7791f; flex: none; margin-top: 1px; }
.dir-warn b { font-weight: 500; display: block; color: var(--ink); }
.dir-actions { display: flex; gap: 6px; flex-wrap: wrap; }
.dir-thinking { display: grid; gap: 10px; }
.dir-thinking .skeleton { height: 12px; }
.fade-in { animation: riseSm 500ms var(--ease-out) both; }

/* ------------------------------------------------------------------ Realism */
.realism { padding: 20px 0 150px; }
.handles { display: grid; grid-template-columns: 340px 1fr; gap: 48px; align-items: center; padding: 40px 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); margin-bottom: 140px; }
.handles-lead { font-size: 26px; line-height: 1.25; letter-spacing: -0.028em; font-weight: 500; }
.handles-list { display: flex; flex-wrap: wrap; row-gap: 8px; }
.handles-list li { font-size: 15px; color: var(--ink-2); display: inline-flex; align-items: center; }
.handles-list li:not(:last-child)::after { content: ""; width: 4px; height: 4px; border-radius: 50%; background: var(--ghost); margin: 0 14px; }
.realism-grid { display: grid; grid-template-columns: minmax(0, 1fr) 380px; gap: 110px; align-items: center; }
.realism-copy { display: grid; gap: 20px; }
.realism-lists { display: grid; grid-template-columns: 1.5fr 1fr; gap: 40px; margin-top: 24px; }
.r-list { columns: 2; column-gap: 24px; margin-top: 12px; }
.r-list li { break-inside: avoid; display: flex; gap: 10px; align-items: baseline; font-size: 14px; padding: 6px 0; color: var(--ink-2); }
.r-list li::before { content: ""; width: 5px; height: 5px; border-radius: 50%; background: var(--ink); flex: none; transform: translateY(-2px); }
.r-avoid { columns: 1; }
.r-avoid li { color: var(--faint); }
.r-avoid li::before { background: transparent; box-shadow: inset 0 0 0 1px var(--ghost); }
.realism-visual { position: relative; }
.rv-media .media { border-radius: 22px; box-shadow: 0 40px 80px -40px rgba(0,0,0,0.4); }
.rv-pin { position: absolute; z-index: 3; display: inline-flex; align-items: center; gap: 9px; padding: 7px 13px 7px 9px; border-radius: 999px; background: #fff; box-shadow: var(--sh-2); font-size: 12.5px; font-weight: 500; white-space: nowrap; }
.rv-pin i { width: 8px; height: 8px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
.rv-pin-1 { left: -70px; top: 20%; }
.rv-pin-2 { right: -54px; top: 46%; }
.rv-pin-3 { left: -44px; bottom: 16%; }

/* ------------------------------------------------------------------ Showcase */
.showcase { padding: 130px 0 140px; }
.showcase-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 32px; margin-bottom: 40px; }
.showcase-head .h1 { margin-top: 14px; }
.showcase-head .lead { margin-top: 12px; }
.showcase-filters { display: flex; gap: 6px; overflow-x: auto; flex-wrap: wrap; justify-content: flex-end; max-width: 620px; }
.sc-grid { columns: 4 250px; column-gap: 14px; transition: opacity 220ms var(--ease); }
.sc-grid.is-swapping { opacity: 0; }
.sc-item { position: relative; display: block; width: 100%; margin: 0 0 14px; break-inside: avoid; cursor: pointer; border-radius: 14px; opacity: 0; }
.sc-grid.is-in .sc-item { animation: riseSm 700ms var(--ease-out) both; animation-delay: calc(var(--n, 0) * 45ms); }
.sc-item .media { border-radius: 14px; transition: transform 500ms var(--ease-out), box-shadow var(--t) var(--ease); }
.sc-item:hover .media { box-shadow: var(--sh-2); }
.sc-item .media-meta { opacity: 0; transform: translateY(4px); transition: opacity var(--t) var(--ease), transform var(--t) var(--ease); }
.sc-item:hover .media-meta, .sc-item:focus-visible .media-meta { opacity: 1; transform: none; }
.sc-item:hover .media-shade::after, .sc-item:focus-visible .media-shade::after { opacity: 1; }
.sc-item .sc-expand { position: absolute; top: 10px; right: 10px; z-index: 3; width: 30px; height: 30px; border-radius: 8px; display: grid; place-items: center; background: rgba(255,255,255,0.9); color: var(--ink); opacity: 0; transform: scale(0.94); transition: all var(--t) var(--ease); }
.sc-item .sc-expand .i { width: 15px; height: 15px; }
.sc-item:hover .sc-expand { opacity: 1; transform: none; }
/* Touch screens have no hover: details show while the clip plays */
@media (hover: none) {
  .sc-item .sc-expand { opacity: 1; transform: none; }
  .sc-item .media.is-playing .media-meta { opacity: 1; transform: none; }
  .sc-item .media.is-playing.media-shade::after { opacity: 1; }
}
.sc-more { display: flex; justify-content: center; margin-top: 28px; }

/* Immersive preview */
.viewer { position: relative; width: 100%; height: 100%; display: flex; align-items: center; justify-content: center; gap: 48px; padding: 48px 96px; color: #fff; transform: scale(0.98); opacity: 0; transition: transform 320ms var(--ease-out), opacity 240ms var(--ease); }
.overlay.is-open .viewer { transform: none; opacity: 1; }
.viewer-media { position: relative; height: min(84vh, 860px); aspect-ratio: 9 / 16; border-radius: 20px; overflow: hidden; background: #000; flex: none; box-shadow: 0 40px 120px -20px rgba(0,0,0,0.6); }
.viewer-media video { width: 100%; height: 100%; object-fit: cover; background: #000; }
.viewer-info { width: 320px; display: grid; gap: 22px; align-content: center; }
.viewer-info .k { font-size: 12px; color: rgba(255,255,255,0.5); }
.viewer-title { font-size: 26px; letter-spacing: -0.03em; font-weight: 500; line-height: 1.15; }
.viewer-prompt { font-size: 14px; line-height: 1.6; color: rgba(255,255,255,0.78); }
.viewer-specs { display: grid; grid-template-columns: 1fr 1fr; border-top: 1px solid rgba(255,255,255,0.12); }
.viewer-specs div { padding: 10px 0; border-bottom: 1px solid rgba(255,255,255,0.12); font-size: 13px; }
.viewer-specs div span { display: block; font-size: 11.5px; color: rgba(255,255,255,0.5); }
.viewer .btn-primary { background: #fff; color: var(--ink); }
.viewer .btn-primary:hover { background: #f1f1f1; }
.viewer-close, .viewer-nav { position: absolute; width: 44px; height: 44px; border-radius: 50%; display: grid; place-items: center; color: #fff; background: rgba(255,255,255,0.08); transition: background-color var(--t) var(--ease); }
.viewer-close:hover, .viewer-nav:hover { background: rgba(255,255,255,0.16); }
.viewer-close { top: 20px; right: 20px; }
.viewer-nav { top: 50%; transform: translateY(-50%); }
.viewer-prev { left: 24px; }
.viewer-next { right: 24px; }
.viewer-sound { position: absolute; right: 12px; bottom: 12px; width: 36px; height: 36px; border-radius: 50%; background: rgba(0,0,0,0.4); color: #fff; display: grid; place-items: center; backdrop-filter: blur(8px); }

/* ------------------------------------------------------------------ Pricing */
.pricing { padding: 130px 0 140px; background: var(--s1); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.pricing-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 32px; margin-bottom: 44px; }
.pricing-head .h1 { margin-top: 14px; max-width: 640px; }
.pricing-head .lead { margin-top: 14px; max-width: 540px; }
/* Plan cards (.plans, .plan …) live in core.css: the Studio’s Billing page uses the same cards */

.compare { margin-top: 24px; }
.compare summary { list-style: none; cursor: pointer; display: inline-flex; align-items: center; gap: 8px; font-size: 14px; font-weight: 500; padding: 8px 2px; }
.compare summary::-webkit-details-marker { display: none; }
.compare summary .i { transition: transform var(--t) var(--ease); }
.compare[open] summary .i { transform: rotate(180deg); }
.compare-wrap { margin-top: 12px; overflow-x: auto; background: #fff; border: 1px solid var(--line); border-radius: 16px; animation: riseSm 400ms var(--ease-out); }
.compare-table th:not(:first-child), .compare-table td:not(:first-child) { text-align: center; }
.compare-table th { font-size: 13px; color: var(--ink); padding: 14px; }
.compare-table td:first-child { color: var(--muted); }
.compare-table .i { width: 16px; height: 16px; margin: 0 auto; }
.compare-table .no { color: var(--ghost); }

/* ------------------------------------------------------------------ Final */
.final { padding: 200px 0 190px; text-align: center; }
.final-inner { display: grid; justify-items: center; }
.final-title { font-size: clamp(44px, 7.4vw, 108px); letter-spacing: -0.052em; line-height: 0.98; font-weight: 500; max-width: 1040px; }
.final .lead { margin-top: 26px; }
.final-cta { margin-top: 40px; display: flex; flex-direction: column; align-items: center; gap: 14px; }

/* ------------------------------------------------------------------ Footer */
.footer { border-top: 1px solid var(--line); padding: 56px 0 32px; }
.footer-top { display: flex; justify-content: space-between; gap: 48px; flex-wrap: wrap; }
.footer-brand { display: grid; gap: 12px; align-content: start; }
.footer-cols { display: grid; grid-template-columns: repeat(3, 160px); gap: 24px; }
.footer-cols div { display: grid; gap: 10px; align-content: start; }
.footer-cols .label { margin-bottom: 4px; }
.footer-cols a { font-size: 14px; color: var(--ink-2); transition: color var(--t) var(--ease); }
.footer-cols a:hover { color: var(--ink); }
.footer-bottom { display: flex; justify-content: space-between; align-items: center; gap: 16px; margin-top: 56px; padding-top: 22px; border-top: 1px solid var(--line); flex-wrap: wrap; }
.footer-bottom .row { gap: 18px; }

/* ------------------------------------------------------------------ Responsive */
@media (max-width: 1240px) {
  .hero-edge { display: none; }
  .s-edge-l { margin-left: -120px; }
  .s-edge-r { right: -110px; }
}
@media (max-width: 1080px) {
  .idea-grid { grid-template-columns: minmax(0, 1fr) 260px; gap: 32px; }
  .idea-steps { grid-column: 1 / -1; grid-template-columns: repeat(4, 1fr); gap: 16px; }
  .idea-steps li { grid-template-columns: 1fr; padding: 0; }
  .idea-steps .n { grid-row: auto; padding: 0 0 4px; }
  .idea-steps .d { display: none; }
  .io-frame { width: 260px; }
  .idea-sticky .idea-grid { padding-top: 64px; }
  .feat-split, .feat-reverse { grid-template-columns: 1fr; gap: 48px; }
  .feat-reverse .feat-copy { order: 0; }
  .director-grid { grid-template-columns: 1fr; gap: 48px; }
  .dir-demo { position: relative; top: 0; }
  .realism-grid { grid-template-columns: minmax(0, 1fr) 320px; gap: 72px; }
  .handles { grid-template-columns: 1fr; gap: 16px; }
  .plans { grid-template-columns: repeat(2, 1fr); }
  .plan:nth-child(3) { border-left: 0; }
  .plan:nth-child(n + 3) { border-top: 1px solid var(--line); }
  .s-edge-l, .s-edge-r { display: none; }
}
@media (max-width: 860px) {
  .nav-links, .nav-bar .nav-signin { display: none; }
  .nav-burger { display: inline-block; }
  .nav-bar { grid-template-columns: 1fr auto; padding-right: 6px; }
  .nav-panel { display: grid; grid-template-rows: 0fr; transition: grid-template-rows 480ms var(--ease-out); }
  .nav-panel-inner { overflow: hidden; min-height: 0; }
  .nav.is-open .nav-panel { grid-template-rows: 1fr; }
  .nav-bar .nav-cta { transition: opacity 260ms var(--ease), transform 260ms var(--ease); }
  .nav.is-open .nav-bar .nav-cta { opacity: 0; transform: scale(0.96); pointer-events: none; }
  .nav-panel-links { display: grid; padding: 4px 10px 0; }
  .nav-panel-links a {
    display: grid; grid-template-columns: 30px 1fr; align-items: baseline; row-gap: 1px;
    padding: 14px 6px; border-top: 1px solid rgba(0, 0, 0, 0.06);
    opacity: 0; transform: translateY(-8px);
    transition: opacity 360ms var(--ease), transform 480ms var(--ease-out);
  }
  .nav-panel-links a:first-child { border-top: 0; }
  .nav-panel-links .n { grid-row: span 2; font-size: 12px; color: var(--faint); font-variant-numeric: tabular-nums; }
  .nav-panel-links .t { font-size: 26px; font-weight: 500; letter-spacing: -0.03em; line-height: 1.15; color: var(--ink); }
  .nav-panel-links .d { font-size: 13px; color: var(--muted); }
  .nav-panel-links a.is-current .t::after { content: ""; display: inline-block; width: 6px; height: 6px; border-radius: 50%; background: var(--accent); margin-left: 10px; vertical-align: 6px; }
  .nav-panel-foot { display: grid; gap: 8px; padding: 14px 16px 16px; opacity: 0; transform: translateY(-8px); transition: opacity 360ms var(--ease), transform 480ms var(--ease-out); }
  .nav.is-open .nav-panel-links a, .nav.is-open .nav-panel-foot { opacity: 1; transform: none; transition-delay: calc(90ms + var(--k) * 45ms); }
  .hero-stage { height: 620px; }
  .s-main { width: 280px; margin-left: -140px; }
  .s-back-l { width: 200px; margin-left: calc(-140px - 200px + 40px); top: 90px; }
  .s-back-r { width: 200px; margin-left: calc(140px - 40px); top: 50px; }
  .stage-note { right: -70px; top: auto; bottom: 14%; width: 200px; }
  .fx { grid-template-columns: 1fr; max-width: 520px; margin: 0 auto; }
  .realism-grid { grid-template-columns: 1fr; }
  .realism-visual { max-width: 340px; margin: 0 auto; }
  .showcase-head, .pricing-head { flex-direction: column; align-items: flex-start; }
  .showcase-filters { justify-content: flex-start; flex-wrap: nowrap; max-width: 100%; width: 100%; }
}
@media (max-width: 720px) {
  .container { padding: 0 16px; }
  .models { padding-top: 24px; }
  .models-row { display: grid; grid-template-columns: 1fr 1fr; width: 100%; gap: 8px; }
  .model-chip { padding: 8px 10px 8px 8px; gap: 9px; }
  .model-chip .brand-logo.lg { width: 34px; height: 34px; border-radius: 10px; }
  .mc-t b { font-size: 13px; }
  .nav { padding: 8px 10px; }
  .nav-bar { height: 54px; padding-left: 12px; }
  .hero { padding-top: 116px; }
  .hero-sub { margin-top: 18px; }
  .hero-ctas { margin-top: 26px; width: 100%; }
  .hero-ctas .btn { flex: 1; }
  .cmd { margin-top: 32px; }
  .cmd-main { flex-wrap: wrap; }
  .cmd-field { order: -1; flex-basis: 100%; }
  .cmd-field textarea { height: 66px; }
  .cmd-ghost { white-space: normal; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
  .cmd-go { margin-left: auto; }
  .cmd-hint { display: none; }
  .hero-stage { height: 520px; margin-top: 48px; }
  .s-main { width: 230px; margin-left: -115px; }
  .s-back-l { width: 160px; margin-left: calc(-115px - 160px + 56px); top: 70px; }
  .s-back-r { width: 160px; margin-left: calc(115px - 56px); top: 40px; }
  .stage-note { right: -52px; bottom: 12%; width: 176px; padding: 10px 12px; }
  .stage-note-head, .stage-note li { font-size: 12px; }
  .idea { padding-top: 80px; }
  /* Same scroll-driven demo as desktop: the composer hands over to the video at step 4 */
  .idea-sticky { padding: 66px 0 10px; }
  .idea-grid, .idea-sticky .idea-grid { grid-template-columns: minmax(0, 1fr); gap: 18px; padding-top: 0; width: 100%; }
  .idea-steps { grid-template-columns: repeat(4, 1fr); gap: 10px; }
  .idea-steps .t { font-size: 14px; }
  .idea-stage { display: grid; place-items: center; }
  .idea-stage > * { grid-area: 1 / 1; }
  .idea-composer { width: 100%; padding: 14px; gap: 12px; transition: opacity 500ms var(--ease), transform 700ms var(--ease-out); }
  .idea-output { opacity: 0; transform: translateY(28px) scale(0.96); pointer-events: none; transition: opacity 600ms var(--ease) 80ms, transform 800ms var(--ease-out) 80ms; }
  .idea-track[data-step="3"] .idea-composer { opacity: 0; transform: translateY(-20px) scale(0.97); pointer-events: none; }
  .idea-track[data-step="3"] .idea-output { opacity: 1; transform: none; }
  .io-frame { width: min(280px, 78vw); }
  .ic-director { min-height: 0; }
  .features { padding-top: 110px; }
  .features-head { margin-bottom: 32px; }
  .feat { padding-top: 48px; padding-bottom: 48px; }
  .tt-composer { padding: 10px; border-radius: 20px; }
  .tt-bar { flex-direction: column; align-items: stretch; padding: 14px; }
  .tt-field { font-size: 16px; }
  .tt-results { grid-template-columns: repeat(3, minmax(140px, 1fr)); overflow-x: auto; scroll-snap-type: x mandatory; gap: 10px; }
  .tt-result { scroll-snap-align: start; }
  .i2v { grid-template-columns: 1fr 1fr; gap: 16px; }
  .i2v-mid { grid-column: 1 / -1; order: 3; }
  /* Product photo top-left, video bottom-right, the dotted path runs between them */
  .pu { height: auto; container-type: inline-size; }
  .pu-upload { top: 0; width: 44%; padding: 8px; gap: 8px; }
  .pu-upload-head { font-size: 11.5px; }
  .pu-scene { position: relative; right: auto; top: auto; width: 56%; margin: 96px 0 0 auto; }
  .pu-path { left: 22%; right: auto; width: 27%; top: calc(44cqw + 78px); height: calc(18cqw + 14px); }
  .pu-path svg:not(.pu-path-m) { display: none; }
  .pu-path .pu-path-m { display: block; }
  .pu-token { left: 8px; bottom: 12px; }
  .detects ul { grid-template-columns: 1fr; }
  .director { padding: 100px 0; }
  .dir-out { min-height: 0; }
  .realism { padding-bottom: 100px; }
  .handles { margin-bottom: 80px; }
  .handles-lead { font-size: 22px; }
  .realism-lists { grid-template-columns: 1fr; gap: 24px; }
  .rv-pin-1 { left: -8px; }
  .rv-pin-2 { right: -8px; }
  .rv-pin-3 { left: -8px; }
  .showcase { padding: 90px 0 100px; }
  .sc-grid { columns: 2; column-gap: 10px; }
  .sc-item { margin-bottom: 10px; }
  .pricing { padding: 90px 0 100px; }
  .plans { grid-template-columns: 1fr; }
  .plan { border-left: 0; border-top: 1px solid var(--line); }
  .plan:first-child { border-top: 0; }
  .final { padding: 130px 0 120px; }
  .footer-cols { grid-template-columns: repeat(2, 1fr); width: 100%; }
  .viewer { flex-direction: column; justify-content: flex-start; gap: 20px; padding: 64px 16px 32px; overflow-y: auto; }
  .viewer-media { height: auto; width: min(100%, 360px); }
  .viewer-info { width: min(100%, 360px); }
  .viewer-nav { display: none; }
}
@media (max-width: 370px) { .nav-bar .nav-cta { display: none; } }
/* the $1 trial, shown once above the plans */
.pricing-trial { flex: none; height: 32px; padding: 0 12px; border-radius: 999px; font-size: 13px; background: var(--accent-soft); color: var(--accent-ink); }
.pricing-trial .i { width: 14px; height: 14px; }
