/* OpenVidSI — uses the lihaila.com design tokens so it reads as the same site. */

/* Inter, served from this site (Google Fonts is blocked in mainland China). SIL OFL: fonts/OFL.txt */
@font-face {
  font-family: 'Inter'; font-style: normal; font-weight: 100 900; font-display: swap;
  src: url(fonts/inter-latin.woff2) format('woff2');
  unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD;
}
@font-face {
  font-family: 'Inter'; font-style: normal; font-weight: 100 900; font-display: swap;
  src: url(fonts/inter-latin-ext.woff2) format('woff2');
  unicode-range: U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF;
}

:root {
  --bg: #fbfbfa; --bg-raised: #ffffff; --bg-sunken: #f3f3f1;
  --text: #16161a; --text-muted: #5c5c66; --text-faint: #8a8a94;
  --border: #e4e4e0; --border-strong: #d2d2cc;
  --accent: #2f5d50; --accent-text: #ffffff; --accent-soft: #e8f0ed;
  --good: #2f7d4f; --warn: #9a6a00; --warn-soft: #fbf1d9; --bad: #b23b3b; --bad-soft: #f9e6e6;
  --radius: 14px; --radius-s: 9px; --maxw: 1080px;
  --gutter: clamp(16px, 5vw, 48px);
  --shadow-1: 0 1px 2px rgba(20,20,26,.05), 0 1px 3px rgba(20,20,26,.04);
  --shadow-2: 0 4px 6px -2px rgba(20,20,26,.06), 0 12px 24px -6px rgba(20,20,26,.09);
  --font: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --serif: 'Iowan Old Style', 'Palatino Linotype', Palatino, Georgia, serif;
  /* art pass: a projector-warm amber beside the house green */
  --ink-deep: #1d3f36; --amber: #c9822b; --rose: #c4553f;
  --glow-a: rgba(47, 93, 80, .17); --glow-b: rgba(201, 130, 43, .11); --glow-c: rgba(196, 85, 63, .07);
  --screen: #0e1412;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #121215; --bg-raised: #1a1a1f; --bg-sunken: #0d0d10;
    --text: #f0f0ee; --text-muted: #a3a3ad; --text-faint: #74747e;
    --border: #2a2a31; --border-strong: #3a3a43;
    --accent: #7fbfa8; --accent-text: #0d1f1a; --accent-soft: #1b2a25;
    --good: #6cc08f; --warn: #e0b04a; --warn-soft: #2a2312; --bad: #e57d7d; --bad-soft: #2c1a1a;
    --shadow-1: 0 1px 2px rgba(0,0,0,.4);
    --shadow-2: 0 4px 6px -2px rgba(0,0,0,.4), 0 12px 24px -6px rgba(0,0,0,.5);
    --ink-deep: #0f2621; --amber: #e3a556; --rose: #e07a63;
    --glow-a: rgba(127, 191, 168, .13); --glow-b: rgba(227, 165, 86, .09); --glow-c: rgba(224, 122, 99, .06);
    --screen: #08090a;
  }
}
:root[data-theme="dark"] {
  --bg: #121215; --bg-raised: #1a1a1f; --bg-sunken: #0d0d10;
  --text: #f0f0ee; --text-muted: #a3a3ad; --text-faint: #74747e;
  --border: #2a2a31; --border-strong: #3a3a43;
  --accent: #7fbfa8; --accent-text: #0d1f1a; --accent-soft: #1b2a25;
  --good: #6cc08f; --warn: #e0b04a; --warn-soft: #2a2312; --bad: #e57d7d; --bad-soft: #2c1a1a;
  --shadow-1: 0 1px 2px rgba(0,0,0,.4);
  --shadow-2: 0 4px 6px -2px rgba(0,0,0,.4), 0 12px 24px -6px rgba(0,0,0,.5);
  --ink-deep: #0f2621; --amber: #e3a556; --rose: #e07a63;
  --glow-a: rgba(127, 191, 168, .13); --glow-b: rgba(227, 165, 86, .09); --glow-c: rgba(224, 122, 99, .06);
  --screen: #08090a;
}

*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; }
html { -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}
body { font-family: var(--font); background: var(--bg); color: var(--text); line-height: 1.6; -webkit-font-smoothing: antialiased; overflow-x: hidden; }
.container { width: 100%; max-width: var(--maxw); margin-inline: auto; padding-inline: var(--gutter); }
h1, h2, h3, h4 { line-height: 1.15; letter-spacing: -0.021em; font-weight: 640; text-wrap: balance; }
h2 { font-size: clamp(1.45rem, 1.1rem + 1.4vw, 2rem); letter-spacing: -0.026em; }
h3 { font-size: 1.08rem; }
h4 { font-size: .76rem; text-transform: uppercase; letter-spacing: .09em; font-weight: 600; color: var(--text-faint); }
p { text-wrap: pretty; }
a { color: inherit; }
svg { display: block; }
button { font: inherit; color: inherit; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 4px; }
[hidden] { display: none !important; }

/* ---------- header / footer (same as lihaila.com) ---------- */
.skip-link { position: absolute; left: 12px; top: -48px; z-index: 100; background: var(--accent); color: var(--accent-text); padding: 9px 16px; border-radius: 0 0 var(--radius-s) var(--radius-s); text-decoration: none; }
.skip-link:focus { top: 0; }
.site-header { position: sticky; top: 0; z-index: 50; background: color-mix(in srgb, var(--bg) 82%, transparent); backdrop-filter: saturate(180%) blur(14px); -webkit-backdrop-filter: saturate(180%) blur(14px); border-bottom: 1px solid var(--border); }
.nav { display: flex; align-items: center; gap: 14px; height: 62px; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; font-weight: 650; letter-spacing: -0.02em; }
.brand .logo, .footer-brand .logo { width: 24px; height: 24px; fill: var(--accent); flex: none; }
.product-name { display: inline-flex; align-items: center; gap: 8px; text-decoration: none; font-weight: 650; color: var(--text); margin-right: auto; letter-spacing: -0.02em; padding-left: 14px; border-left: 1px solid var(--border-strong); }
.product-name svg { width: 22px; height: 22px; flex: none; }
.nav-links { display: flex; align-items: center; gap: 4px; list-style: none; padding: 0; }
.nav-links a { text-decoration: none; color: var(--text-muted); font-size: .93rem; font-weight: 500; padding: 7px 11px; border-radius: var(--radius-s); transition: color .15s, background .15s; white-space: nowrap; }
.nav-links a:hover { color: var(--text); background: var(--bg-sunken); }
.theme-toggle { display: inline-grid; place-items: center; width: 34px; height: 34px; flex: none; padding: 0; cursor: pointer; color: var(--text-muted); background: none; border: 0; border-radius: 9px; }
.theme-toggle:hover { color: var(--text); background: var(--bg-sunken); }
.theme-toggle svg { width: 17px; height: 17px; grid-area: 1 / 1; }
.theme-toggle .icon-sun { display: none; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .theme-toggle .icon-sun { display: block; }
  :root:not([data-theme="light"]) .theme-toggle .icon-moon { display: none; }
}
:root[data-theme="dark"] .theme-toggle .icon-sun { display: block; }
:root[data-theme="dark"] .theme-toggle .icon-moon { display: none; }
@media (max-width: 640px) {
  .nav { gap: 6px; }
  .brand span { display: none; }
  .product-name { padding-left: 10px; margin-left: 4px; }
  .nav-links a { padding: 7px 8px; }
}

.site-footer { border-top: 1px solid var(--border); background: var(--bg-sunken); padding: 46px 0 28px; margin-top: 72px; }
.footer-grid { display: grid; grid-template-columns: 1.7fr repeat(3, 1fr); gap: 32px; }
.footer-brand { display: flex; align-items: center; gap: 9px; font-weight: 640; margin-bottom: 9px; }
.footer-col p { color: var(--text-muted); font-size: .88rem; max-width: 34ch; }
.footer-col h4 { margin-bottom: 12px; }
.footer-col a { display: block; color: var(--text-muted); text-decoration: none; font-size: .89rem; padding: 3px 0; }
.footer-col a:hover { color: var(--text); }
.social-links { display: flex; gap: 8px; margin-top: 10px; }
.social-links a { padding: 0; }
.social-links svg { width: 17px; height: 17px; fill: var(--text-muted); transition: fill .15s; }
.social-links a:hover svg { fill: var(--text); }
.footer-bottom { border-top: 1px solid var(--border); margin-top: 34px; padding-top: 20px; display: flex; flex-wrap: wrap; gap: 10px; justify-content: space-between; color: var(--text-faint); font-size: .84rem; }
@media (max-width: 860px) { .footer-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 520px) { .footer-grid { grid-template-columns: 1fr; } }

/* ---------- language picker (same look as lihaila.com) ---------- */
.dropdown { position: relative; }
.dropdown-menu[hidden] { display: none; }
.dropdown-menu { position: absolute; top: calc(100% + 7px); right: 0; min-width: 172px; z-index: 60; background: var(--bg-raised); border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow-2); padding: 6px; display: grid; gap: 1px; }
.dropdown-menu a { padding: 9px 12px; border-radius: 8px; font-size: .9rem; color: var(--text); text-decoration: none; display: flex; align-items: center; gap: 10px; white-space: nowrap; }
.dropdown-menu a:hover { background: var(--bg-sunken); }
.dropdown-menu a[aria-current="true"] { color: var(--accent); font-weight: 600; }
.flag { display: block; width: 22px; height: 15px; border-radius: 2.5px; flex: none; box-shadow: 0 0 0 1px color-mix(in srgb, var(--text) 22%, transparent); }
.lang-pick > button { padding: 0; width: 34px; height: 34px; display: grid; place-items: center; background: none; border: 1px solid transparent; border-radius: 9px; cursor: pointer; }
.lang-pick > button:hover { background: var(--bg-sunken); border-color: var(--border); }

/* ================================================================ the page */
main { position: relative; isolation: isolate; }
main::before {
  content: ''; position: absolute; inset: -80px 0 auto 0; height: 820px; z-index: -1; pointer-events: none;
  background:
    radial-gradient(40% 50% at 18% 28%, var(--glow-a), transparent 70%),
    radial-gradient(34% 44% at 82% 18%, var(--glow-b), transparent 70%),
    radial-gradient(28% 38% at 64% 72%, var(--glow-c), transparent 70%);
  filter: blur(8px);
}
/* a whisper of film grain over the wash */
main::after {
  content: ''; position: absolute; inset: -80px 0 auto 0; height: 820px; z-index: -1; pointer-events: none; opacity: .14; mix-blend-mode: soft-light;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='.5'/%3E%3C/svg%3E");
  -webkit-mask: linear-gradient(#000 60%, transparent); mask: linear-gradient(#000 60%, transparent);
}

.hero { padding-top: clamp(44px, 8vw, 96px); text-align: center; }
.eyebrow { display: inline-flex; align-items: center; gap: 8px; font-size: .82rem; font-weight: 550; color: var(--text-muted); padding: 6px 13px; border-radius: 999px; border: 1px solid var(--border); background: color-mix(in srgb, var(--bg-raised) 70%, transparent); backdrop-filter: blur(6px); }
.eyebrow .rec { width: 7px; height: 7px; border-radius: 50%; background: var(--rose); box-shadow: 0 0 0 3px color-mix(in srgb, var(--rose) 22%, transparent); animation: rec 1.6s ease-in-out infinite; }
@keyframes rec { 50% { opacity: .35; } }
.hero h1 { margin: 22px auto 0; font-size: clamp(2.5rem, 1.3rem + 5vw, 4.6rem); letter-spacing: -0.048em; line-height: 1; max-width: 13ch; }
.hero h1 em { font-family: var(--serif); font-style: italic; font-weight: 500; letter-spacing: -0.02em; padding-right: .06em;
  background: linear-gradient(100deg, var(--accent) 10%, var(--amber) 60%, var(--rose)); -webkit-background-clip: text; background-clip: text; color: transparent; }
.hero .lede { margin: 22px auto 0; max-width: 60ch; color: var(--text-muted); font-size: clamp(1.02rem, .96rem + .35vw, 1.18rem); line-height: 1.6; }

/* the storyboard reel: abstract scenes sliding past, sprockets top and bottom */
.reel { margin: 46px calc(var(--gutter) * -1) 0; overflow: hidden; -webkit-mask: linear-gradient(90deg, transparent, #000 12%, #000 88%, transparent); mask: linear-gradient(90deg, transparent, #000 12%, #000 88%, transparent); }
.reel-track { display: flex; width: max-content; padding: 16px 0; gap: 6px; background: #121614; position: relative; animation: roll 70s linear infinite; }
.reel-track::before, .reel-track::after { content: ''; position: absolute; left: 0; right: 0; height: 7px; background: repeating-linear-gradient(90deg, transparent 0 9px, rgba(255,255,255,.75) 9px 19px, transparent 19px 28px); opacity: .55; border-radius: 2px; }
.reel-track::before { top: 4px; } .reel-track::after { bottom: 4px; }
@keyframes roll { to { transform: translateX(-50%); } }
.frame { width: 168px; aspect-ratio: 16 / 9; border-radius: 3px; flex: none; position: relative; overflow: hidden; }
.f1 { background: radial-gradient(circle at 50% 78%, #ffd7a1 0 12%, #f59e5b 13%, transparent 14%), linear-gradient(#2d1b4e, #c4553f 62%, #f2a65a 63%, #3a2a3f 64%, #1b1626); }
.f2 { background: repeating-radial-gradient(ellipse at 50% 120%, #2f6b8a 0 6px, #3d8bb0 6px 12px), #2f6b8a; }
.f3 { background: linear-gradient(#0d1a2b 0 55%, transparent 55%), repeating-linear-gradient(90deg, #1b2b44 0 14px, #f6c35b 14px 16px, #1b2b44 16px 22px, #26385a 22px 34px), #0d1a2b; }
.f4 { background: conic-gradient(from 160deg at 30% 100%, #1e4d3a 0 40deg, transparent 0), conic-gradient(from 160deg at 70% 100%, #2f6b4f 0 40deg, transparent 0), linear-gradient(#d9ecd9, #9cc9a8); }
.f5 { background: radial-gradient(circle at 70% 30%, #fff6 0 6%, transparent 7%), radial-gradient(circle at 30% 60%, #ffffff22 0 22%, transparent 23%), linear-gradient(135deg, #3b2f63, #7b4b94 50%, #e08aa3); }
.f6 { background: radial-gradient(circle at 50% 50%, #f7efe3 0 18%, #c9822b 19% 21%, transparent 22%), linear-gradient(#5a3a22, #2a1b12); }
.f7 { background: linear-gradient(170deg, #e9e4da 0 48%, #6e8f8a 48% 52%, #3e5f63 52%); }
.f8 { background: radial-gradient(ellipse at 50% 100%, #ffb36b55, transparent 60%), repeating-linear-gradient(100deg, #101c1a 0 10px, #16302a 10px 20px); }

/* ---------- the director's box ---------- */
.studio { margin-top: 48px; }
.director { position: relative; border-radius: 24px; border: 1px solid var(--border); background: color-mix(in srgb, var(--bg-raised) 90%, transparent); backdrop-filter: blur(12px); padding: clamp(16px, 3vw, 26px);
  box-shadow: 0 1px 0 rgba(255,255,255,.5) inset, 0 26px 60px -28px rgba(20,40,34,.32), var(--shadow-1); max-width: 820px; margin-inline: auto; }
.director::before { content: ''; position: absolute; inset: -1px; border-radius: inherit; padding: 1.5px; pointer-events: none;
  background: linear-gradient(120deg, var(--accent), var(--amber), var(--rose), var(--accent)); background-size: 300% 300%;
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0); -webkit-mask-composite: xor; mask-composite: exclude; opacity: 0; transition: opacity .3s; }
.director:focus-within { border-color: transparent; }
.director:focus-within::before { opacity: 1; animation: edge 7s linear infinite; }
@keyframes edge { to { background-position: 300% 0; } }

.slate { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 14px; }
.slate-label { display: flex; align-items: center; gap: 10px; font-size: .78rem; text-transform: uppercase; letter-spacing: .12em; font-weight: 600; color: var(--text-faint); }
.slate-label .clap { width: 30px; height: 22px; }
.director textarea { width: 100%; min-height: 128px; resize: vertical; border: 0; background: transparent; color: var(--text); font: inherit; font-size: clamp(1.05rem, 1rem + .3vw, 1.2rem); line-height: 1.55; padding: 4px 2px; outline: none; }
.director textarea::placeholder { color: var(--text-faint); }
.chips { display: flex; flex-wrap: wrap; gap: 8px; margin: 6px 0 4px; }
.chip { border: 1px solid var(--border); background: color-mix(in srgb, var(--bg-sunken) 70%, transparent); color: var(--text-muted); font-size: .82rem; padding: 5px 11px; border-radius: 999px; cursor: pointer; transition: color .15s, border-color .15s, transform .15s; }
.chip:hover { color: var(--text); border-color: var(--border-strong); transform: translateY(-1px); }

.controls { display: flex; flex-wrap: wrap; align-items: center; gap: 14px 22px; padding-top: 16px; margin-top: 14px; border-top: 1px dashed var(--border-strong); }
.ctrl { display: flex; align-items: center; gap: 10px; }
.ctrl-label { font-size: .76rem; text-transform: uppercase; letter-spacing: .09em; font-weight: 600; color: var(--text-faint); }
.seg { display: inline-flex; padding: 3px; border-radius: 11px; background: var(--bg-sunken); border: 1px solid var(--border); }
.seg button { border: 0; background: transparent; padding: 6px 12px; border-radius: 8px; cursor: pointer; font-size: .88rem; font-weight: 550; color: var(--text-muted); display: inline-flex; align-items: center; gap: 7px; font-variant-numeric: tabular-nums; }
.seg button[aria-pressed="true"] { background: var(--bg-raised); color: var(--text); box-shadow: var(--shadow-1); }
.shape { display: inline-block; border: 1.6px solid currentColor; border-radius: 2px; }
.shape.wide { width: 16px; height: 9px; } .shape.tall { width: 9px; height: 15px; }

.keyline { display: flex; gap: 8px; align-items: center; flex: 1 1 320px; min-width: 0; }
.key-field { flex: 1; min-width: 0; display: flex; align-items: center; gap: 8px; background: var(--bg-sunken); border: 1px solid var(--border); border-radius: 11px; padding: 0 10px; }
.key-field svg { width: 15px; height: 15px; color: var(--text-faint); flex: none; }
.key-field input { flex: 1; min-width: 0; border: 0; background: transparent; color: var(--text); font: inherit; font-size: .9rem; padding: 9px 0; outline: none; font-family: ui-monospace, SFMono-Regular, Menlo, monospace; }
.key-field:focus-within { border-color: var(--accent); }
.key-ok { color: var(--good) !important; }

.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; border-radius: 11px; border: 1px solid var(--border); background: var(--bg-raised); color: var(--text); padding: 9px 14px; font-size: .9rem; font-weight: 550; cursor: pointer; white-space: nowrap; text-decoration: none; transition: transform .15s, box-shadow .15s, background .15s; }
.btn:hover { background: var(--bg-sunken); }
.btn-primary { background: var(--accent); color: var(--accent-text); border-color: transparent; padding: 13px 24px; font-size: 1rem; font-weight: 620; box-shadow: 0 10px 24px -10px color-mix(in srgb, var(--accent) 75%, transparent); }
.btn-primary:hover { background: color-mix(in srgb, var(--accent) 88%, #000); transform: translateY(-1px); }
.btn-primary svg { width: 16px; height: 16px; }
.btn:disabled { opacity: .55; cursor: wait; transform: none; }

.action { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 14px; margin-top: 20px; }
.estimate { color: var(--text-muted); font-size: .92rem; }
.estimate b { color: var(--text); font-weight: 650; font-variant-numeric: tabular-nums; }
.note { color: var(--text-faint); font-size: .8rem; margin-top: 10px; }
.err { color: var(--bad); background: var(--bad-soft); border-radius: 10px; padding: 9px 12px; font-size: .9rem; margin-top: 14px; }

/* ---------- three promises ---------- */
.section { margin-top: clamp(64px, 9vw, 104px); }
.section-head { text-align: center; max-width: 640px; margin: 0 auto 30px; }
.section-head p { color: var(--text-muted); margin-top: 10px; }
.promises { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.promise { position: relative; border: 1px solid var(--border); border-radius: 20px; padding: 24px 22px 22px; background: var(--bg-raised); overflow: hidden; }
.promise .num { position: absolute; right: 14px; top: -6px; font-family: var(--serif); font-style: italic; font-size: 5.4rem; line-height: 1; color: var(--accent); opacity: .08; }
.promise .ico { width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center; background: var(--accent-soft); color: var(--accent); margin-bottom: 16px; }
.promise .ico svg { width: 20px; height: 20px; }
.promise h3 { font-size: 1.12rem; }
.promise p { color: var(--text-muted); font-size: .92rem; margin-top: 7px; }
@media (max-width: 760px) { .promises { grid-template-columns: 1fr; } }

/* ---------- the crew: end credits ---------- */
.credits { position: relative; border-radius: 28px; padding: clamp(36px, 6vw, 64px) var(--gutter); text-align: center; color: #eef4f1; overflow: hidden;
  background: radial-gradient(90% 120% at 50% -10%, #2c5a4d, #10211c 62%, #0b1412); box-shadow: 0 40px 80px -40px rgba(10, 30, 25, .6); }
.credits::before { content: ''; position: absolute; inset: 0; pointer-events: none; background: radial-gradient(50% 30% at 50% 0%, rgba(255, 220, 160, .18), transparent 70%); }
.credits h2 { color: #fff; }
.credits .sub { color: rgba(238, 244, 241, .66); max-width: 54ch; margin: 10px auto 0; font-size: .95rem; }
.roll { list-style: none; padding: 0; margin: 34px auto 0; max-width: 560px; display: grid; gap: 22px; }
.roll li { display: grid; gap: 3px; }
.roll .role { font-size: .72rem; text-transform: uppercase; letter-spacing: .22em; color: rgba(238, 244, 241, .55); }
.roll .who { font-family: var(--serif); font-size: clamp(1.25rem, 1.1rem + .8vw, 1.7rem); font-weight: 500; letter-spacing: -0.01em; }
.roll .id { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: .74rem; color: rgba(238, 244, 241, .42); }
.roll .main .who { color: #ffd9a8; }
.credits .fine { margin-top: 30px; color: rgba(238, 244, 241, .5); font-size: .82rem; }
.credits .fine b { color: rgba(238, 244, 241, .8); font-weight: 600; }

/* ---------- screening room (progress + result) ---------- */
.screening { padding-top: clamp(32px, 6vw, 64px); }
.screening-head { text-align: center; max-width: 760px; margin: 0 auto; }
.screening-head .s-title { font-size: clamp(1.9rem, 1.2rem + 3vw, 3rem); font-weight: 640; line-height: 1.15; letter-spacing: -0.04em; margin-top: 16px; text-wrap: balance; }
.screening-head .prompt { color: var(--text-muted); margin-top: 10px; font-family: var(--serif); font-style: italic; font-size: 1.08rem; }

.theater { margin: 30px auto 0; max-width: 920px; background: var(--screen); border-radius: 26px; padding: clamp(10px, 2vw, 18px); box-shadow: 0 50px 90px -50px rgba(0,0,0,.65), 0 0 0 1px rgba(255,255,255,.04) inset; }
.screen { position: relative; border-radius: 16px; overflow: hidden; aspect-ratio: 16 / 9; background: #000; display: grid; place-items: center; }
.tall .screen { aspect-ratio: 9 / 16; max-height: 72vh; margin-inline: auto; }
.screen video { width: 100%; height: 100%; object-fit: contain; display: block; background: #000; }
.screen .still { position: absolute; inset: 0; pointer-events: none; width: 100%; height: 100%; object-fit: cover; opacity: 0; transition: opacity 1.2s ease; animation: kenburns 14s ease-in-out infinite alternate; }
.screen .still.on { opacity: .9; }
@keyframes kenburns { from { transform: scale(1.02); } to { transform: scale(1.1) translate(-1.5%, -1%); } }
.screen .veil { position: absolute; inset: 0; background: radial-gradient(70% 70% at 50% 50%, transparent, rgba(0,0,0,.55)); pointer-events: none; }
.screen .status { position: relative; z-index: 2; text-align: center; color: #f3f1ea; padding: 20px; }
.screen .status .big { font-family: var(--serif); font-style: italic; font-size: clamp(1.2rem, 1rem + 1.4vw, 2rem); text-shadow: 0 2px 20px rgba(0,0,0,.6); }
.screen .status .small { font-size: .84rem; opacity: .75; margin-top: 6px; letter-spacing: .02em; font-variant-numeric: tabular-nums; }
.leader { width: 76px; height: 76px; margin: 0 auto 14px; border-radius: 50%; border: 2px solid rgba(255,255,255,.55); position: relative; display: grid; place-items: center; font-family: var(--serif); font-size: 1.9rem; }
.leader::before { content: ''; position: absolute; inset: -2px; border-radius: 50%; background: conic-gradient(rgba(255,255,255,.35) var(--p, 0%), transparent 0); -webkit-mask: radial-gradient(circle, transparent 60%, #000 61%); mask: radial-gradient(circle, transparent 60%, #000 61%); }
.leader::after { content: ''; position: absolute; inset: 0; border-radius: 50%; border-top: 2px solid #fff; animation: sweep 1.4s linear infinite; }
@keyframes sweep { to { transform: rotate(360deg); } }

.timeline { display: grid; grid-template-columns: repeat(var(--cols, 5), 1fr); gap: 6px; margin-top: 14px; }
.tl { position: relative; padding: 10px 10px 9px; border-radius: 12px; background: rgba(255,255,255,.04); color: rgba(243,241,234,.5); font-size: .78rem; overflow: hidden; }
.tl b { display: block; font-weight: 600; font-size: .8rem; color: rgba(243,241,234,.78); }
.tl span { display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-variant-numeric: tabular-nums; }
.tl::after { content: ''; position: absolute; left: 0; bottom: 0; height: 2px; width: 0; background: var(--amber); transition: width .6s; }
.tl.running { background: rgba(227,165,86,.1); }
.tl.running::after { width: 60%; animation: work 1.8s ease-in-out infinite; }
.tl.done::after { width: 100%; background: #7fbfa8; }
.tl.done b { color: #f3f1ea; }
.tl.error::after { width: 100%; background: #e07a63; }
.tl.skipped::after { width: 100%; background: #e0b04a; opacity: .6; }
@keyframes work { 0% { left: -60%; } 100% { left: 100%; } }
@media (max-width: 760px) { .timeline { grid-template-columns: repeat(3, 1fr); } }

/* storyboard: the scenes on a strip of film */
.board { margin: 28px auto 0; max-width: 920px; }
.board-head { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; margin-bottom: 12px; }
.ledger { color: var(--text-muted); font-size: .86rem; font-variant-numeric: tabular-nums; }
.ledger b { color: var(--text); }
.strip { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 14px; }
.cell { border-radius: 14px; overflow: hidden; background: var(--bg-raised); border: 1px solid var(--border); animation: rise .5s cubic-bezier(.2,.7,.2,1) both; }
.cell .pic { position: relative; aspect-ratio: 16 / 9; background: #121614; }
.tall .cell .pic { aspect-ratio: 9 / 16; }
.cell .pic::before, .cell .pic::after { content: ''; position: absolute; left: 0; right: 0; height: 6px; z-index: 2; background: repeating-linear-gradient(90deg, transparent 0 6px, rgba(255,255,255,.5) 6px 12px, transparent 12px 18px); opacity: .5; }
.cell .pic::before { top: 3px; } .cell .pic::after { bottom: 3px; }
.cell img { width: 100%; height: 100%; object-fit: cover; display: block; animation: develop 1.4s ease both; }
@keyframes develop { from { filter: sepia(1) brightness(.4) blur(6px); } to { filter: none; } }
.cell .wait { position: absolute; inset: 0; background: linear-gradient(90deg, #121614 25%, #1d2522 50%, #121614 75%); background-size: 200% 100%; animation: sh 1.6s infinite; }
@keyframes sh { to { background-position: -200% 0; } }
.cell .tag { position: absolute; z-index: 3; left: 8px; top: 12px; font-size: .68rem; font-weight: 600; letter-spacing: .04em; color: #fff; background: rgba(0,0,0,.55); backdrop-filter: blur(4px); padding: 2px 8px; border-radius: 999px; }
.cell .tag.done { background: color-mix(in srgb, #2f7d4f 80%, transparent); }
.cell p { padding: 10px 12px 12px; font-size: .84rem; color: var(--text-muted); line-height: 1.45; }
.cell p::before { content: '“'; } .cell p::after { content: '”'; }
@keyframes rise { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }

.after { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; margin-top: 20px; }
.warns { max-width: 920px; margin: 16px auto 0; }
.warn { color: var(--warn); background: var(--warn-soft); border-radius: 10px; padding: 8px 12px; font-size: .84rem; margin-top: 8px; }
.hint { text-align: center; color: var(--text-faint); font-size: .84rem; margin-top: 22px; }

@media (max-width: 560px) {
  .keyline { flex-basis: 100%; }
  .strip { grid-template-columns: repeat(2, 1fr); gap: 10px; }
  .cell p { font-size: .78rem; padding: 8px 10px 10px; }
  .action .btn-primary { flex: 1; }
}

/* ---------- questions ---------- */
.credits .kicker { color: rgba(238, 244, 241, .55); }
.credits h2 { margin-top: 8px; }
.faq { max-width: 760px; margin: 0 auto; display: grid; gap: 10px; }
.faq details { border: 1px solid var(--border); border-radius: 16px; background: var(--bg-raised); padding: 0 20px; transition: border-color .2s; }
.faq details[open] { border-color: var(--border-strong); }
.faq summary { cursor: pointer; list-style: none; padding: 17px 28px 17px 0; font-weight: 600; position: relative; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: ''; position: absolute; right: 2px; top: 50%; width: 9px; height: 9px; border-right: 2px solid var(--text-faint); border-bottom: 2px solid var(--text-faint); transform: translateY(-70%) rotate(45deg); transition: transform .2s; }
.faq details[open] summary::after { transform: translateY(-30%) rotate(-135deg); }
.faq details p { color: var(--text-muted); padding: 0 0 18px; font-size: .95rem; }

/* CJK has no true italic: the serif-italic accents fall back to slanted sans, so keep them upright. */
:lang(zh) .hero h1 em, :lang(ja) .hero h1 em, :lang(ko) .hero h1 em { font-family: var(--font); font-style: normal; font-weight: 700; letter-spacing: -0.02em; }
:lang(zh) .screening-head .prompt, :lang(ja) .screening-head .prompt, :lang(ko) .screening-head .prompt,
:lang(zh) .screen .status .big, :lang(ja) .screen .status .big, :lang(ko) .screen .status .big { font-family: var(--font); font-style: normal; }
:lang(zh) .hero h1, :lang(ja) .hero h1, :lang(ko) .hero h1 { letter-spacing: -0.02em; line-height: 1.12; max-width: 16ch; }

/* ---------- account, sign-in and top-up ---------- */
.account { margin-left: auto; display: flex; align-items: center; }
.product-name { margin-right: 0; }
.btn-small { padding: 7px 14px; font-size: .88rem; border-radius: 10px; }
.credit-pill { display: inline-flex; align-items: center; gap: 8px; border: 1px solid var(--border); background: var(--bg-raised); border-radius: 999px; padding: 5px 12px 5px 13px; cursor: pointer; font-size: .86rem; }
.credit-pill span { color: var(--text-faint); }
.credit-pill b { font-variant-numeric: tabular-nums; color: var(--accent); }
.credit-pill:hover { border-color: var(--border-strong); }
.acct .dropdown-menu { min-width: 210px; }
.acct-email { padding: 8px 12px 10px; font-size: .8rem; color: var(--text-faint); border-bottom: 1px solid var(--border); margin-bottom: 4px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

.modal { position: fixed; inset: 0; z-index: 100; display: grid; place-items: center; padding: 16px; background: rgba(10, 14, 12, .52); backdrop-filter: blur(6px); animation: fadein .2s ease; }
@keyframes fadein { from { opacity: 0; } }
.modal-card { position: relative; width: min(440px, 100%); max-height: calc(100vh - 32px); overflow: auto; background: var(--bg-raised); border: 1px solid var(--border); border-radius: 22px; padding: 28px 26px 24px; box-shadow: 0 40px 90px -30px rgba(0,0,0,.5); animation: rise .3s cubic-bezier(.2,.7,.2,1); }
.modal-card h3 { font-size: 1.3rem; letter-spacing: -0.02em; }
.modal-card .muted { color: var(--text-muted); font-size: .9rem; margin: 6px 0 18px; }
.modal-x { position: absolute; top: 12px; right: 12px; width: 32px; height: 32px; border-radius: 9px; border: 0; background: none; font-size: 1.4rem; line-height: 1; color: var(--text-faint); cursor: pointer; }
.modal-x:hover { background: var(--bg-sunken); color: var(--text); }
.btn.google { width: 100%; gap: 10px; padding: 11px; }
.btn.google svg { width: 18px; height: 18px; }
.or { display: flex; align-items: center; gap: 12px; color: var(--text-faint); font-size: .8rem; margin: 16px 0; }
.or::before, .or::after { content: ''; flex: 1; height: 1px; background: var(--border); }
.field { display: grid; gap: 6px; margin-bottom: 12px; font-size: .84rem; color: var(--text-muted); }
.field input { border: 1px solid var(--border); background: var(--bg-sunken); color: var(--text); border-radius: 11px; padding: 11px 12px; font: inherit; font-size: .95rem; outline: none; }
.field input:focus { border-color: var(--accent); }
.wide { width: 100%; margin-top: 4px; }
.auth-links { display: flex; justify-content: space-between; gap: 10px; margin-top: 14px; flex-wrap: wrap; }
.linkish { border: 0; background: none; padding: 0; color: var(--accent); font-size: .86rem; cursor: pointer; }
.linkish:hover { text-decoration: underline; }

.packs { display: grid; gap: 10px; }
.pack { display: grid; grid-template-columns: 1fr auto; align-items: center; gap: 2px 14px; text-align: left; border: 1px solid var(--border); background: var(--bg-raised); border-radius: 16px; padding: 14px 16px; cursor: pointer; transition: border-color .15s, transform .15s, box-shadow .15s; }
.pack:hover { border-color: var(--accent); transform: translateY(-1px); box-shadow: var(--shadow-2); }
.pack b { font-size: 1.05rem; }
.pack .pay { grid-row: span 2; font-weight: 650; color: var(--accent-text); background: var(--accent); padding: 7px 12px; border-radius: 10px; font-size: .9rem; white-space: nowrap; }
.pack small { color: var(--text-faint); font-size: .8rem; }
.pack.best { border-color: color-mix(in srgb, var(--accent) 55%, var(--border)); background: color-mix(in srgb, var(--accent-soft) 60%, var(--bg-raised)); }
.pack:disabled { opacity: .6; cursor: wait; }

.toast { position: fixed; left: 50%; bottom: 24px; transform: translateX(-50%); z-index: 120; background: var(--text); color: var(--bg); padding: 11px 18px; border-radius: 12px; font-size: .9rem; box-shadow: var(--shadow-2); animation: rise .3s ease; max-width: calc(100vw - 32px); }

.recent { max-width: 820px; margin: 18px auto 0; }
.recent h4 { margin-bottom: 10px; }
.recent-list { display: flex; flex-wrap: wrap; gap: 8px; }
.recent-item { display: inline-flex; gap: 10px; align-items: baseline; border: 1px solid var(--border); background: var(--bg-raised); border-radius: 999px; padding: 7px 14px; cursor: pointer; font-size: .86rem; max-width: 100%; }
.recent-item span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 30ch; }
.recent-item small { color: var(--text-faint); }
.recent-item.running::before { content: ''; width: 7px; height: 7px; border-radius: 50%; background: var(--rose); align-self: center; animation: rec 1.6s infinite; }
.recent-item.error { opacity: .6; }
.charge { text-align: center; color: var(--text-faint); font-size: .84rem; margin-top: 14px; font-variant-numeric: tabular-nums; }
.estimate b { color: var(--text); }

/* ---------- my videos ---------- */
.library { padding-top: clamp(32px, 6vw, 64px); min-height: 60vh; }
.library-head { max-width: 640px; margin-bottom: 28px; }
.library-head h1 { font-size: clamp(1.9rem, 1.2rem + 2.6vw, 2.8rem); letter-spacing: -0.035em; }
.library-head p { color: var(--text-muted); margin-top: 8px; }
.lib-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 18px; }
.lib-card { display: block; text-decoration: none; color: inherit; border: 1px solid var(--border); background: var(--bg-raised); border-radius: 16px; overflow: hidden; transition: transform .15s, box-shadow .15s, border-color .15s; animation: rise .4s cubic-bezier(.2,.7,.2,1) both; }
a.lib-card:hover { transform: translateY(-2px); box-shadow: var(--shadow-2); border-color: var(--border-strong); }
.lib-card.dim { opacity: .6; }
.lib-thumb { position: relative; aspect-ratio: 16 / 9; background: linear-gradient(135deg, #16211e, #0d1311); }
.lib-card.tall .lib-thumb { aspect-ratio: 16 / 9; }
.lib-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.lib-card.tall .lib-thumb img { object-fit: contain; background: #000; }
.lib-badge { position: absolute; left: 10px; top: 10px; font-size: .72rem; font-weight: 600; color: #fff; background: rgba(0,0,0,.6); backdrop-filter: blur(4px); padding: 3px 9px; border-radius: 999px; }
.lib-badge.live::before { content: ''; display: inline-block; width: 6px; height: 6px; border-radius: 50%; background: var(--rose); margin-right: 6px; vertical-align: 1px; animation: rec 1.6s infinite; }
.lib-play { position: absolute; inset: 0; margin: auto; width: 46px; height: 46px; border-radius: 50%; background: rgba(0,0,0,.55); backdrop-filter: blur(4px); opacity: 0; transition: opacity .15s; }
.lib-play::after { content: ''; position: absolute; left: 18px; top: 14px; border-left: 14px solid #fff; border-top: 9px solid transparent; border-bottom: 9px solid transparent; }
a.lib-card:hover .lib-play { opacity: 1; }
.lib-body { padding: 12px 14px 14px; display: grid; gap: 3px; }
.lib-body b { font-weight: 620; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.lib-body span { color: var(--text-faint); font-size: .82rem; font-variant-numeric: tabular-nums; }
.lib-body small { color: var(--text-faint); font-size: .76rem; }
.lib-empty { grid-column: 1 / -1; text-align: center; padding: 48px 0; color: var(--text-muted); display: grid; gap: 16px; justify-items: center; }
.lib-loading { grid-column: 1 / -1; height: 160px; border-radius: 16px; background: linear-gradient(90deg, var(--bg-sunken) 25%, var(--border) 50%, var(--bg-sunken) 75%); background-size: 200% 100%; animation: sh 1.4s infinite; }
.back-link { display: inline-block; color: var(--text-muted); text-decoration: none; font-size: .88rem; margin-bottom: 14px; }
.back-link:hover { color: var(--text); }
.screening-head .back-link { display: block; }
.recent-head { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 10px; }
.recent-head h4 { margin: 0; }
.recent-head a { color: var(--accent); font-size: .84rem; text-decoration: none; }

/* ---------- your logo ---------- */
.logo-btn { display: inline-flex; align-items: center; gap: 7px; border: 1px dashed var(--border-strong); background: transparent; color: var(--text-muted); border-radius: 11px; padding: 7px 12px; font-size: .86rem; font-weight: 550; cursor: pointer; transition: color .15s, border-color .15s; }
.logo-btn:hover { color: var(--accent); border-color: var(--accent); }
.logo-btn svg { width: 15px; height: 15px; }
.logo-chip { display: inline-flex; align-items: center; gap: 4px; border: 1px solid var(--border); border-radius: 11px; padding: 4px 4px 4px 10px; background: repeating-conic-gradient(var(--bg-sunken) 0 25%, var(--bg-raised) 0 50%) 0 0 / 10px 10px; }
.logo-chip img { height: 26px; max-width: 110px; object-fit: contain; display: block; }
.logo-chip button { border: 0; background: none; color: var(--text-faint); font-size: 1.15rem; line-height: 1; width: 26px; height: 26px; border-radius: 7px; cursor: pointer; }
.logo-chip button:hover { background: var(--bg-sunken); color: var(--text); }
.lang-select { font: inherit; font-size: .88rem; font-weight: 550; color: var(--text); background: var(--bg-sunken); border: 1px solid var(--border); border-radius: 11px; padding: 7px 30px 7px 12px; cursor: pointer; appearance: none;
  background-image: linear-gradient(45deg, transparent 50%, var(--text-faint) 50%), linear-gradient(135deg, var(--text-faint) 50%, transparent 50%);
  background-position: calc(100% - 15px) 52%, calc(100% - 10px) 52%; background-size: 5px 5px; background-repeat: no-repeat; }
.lang-select:focus { outline: none; border-color: var(--accent); }

/* ---------- billing ---------- */
.bill-card { display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; border: 1px solid var(--border); background: var(--bg-raised); border-radius: 18px; padding: 20px 22px; margin-bottom: 22px; max-width: 520px; }
.bill-card span { display: block; color: var(--text-faint); font-size: .8rem; text-transform: uppercase; letter-spacing: .08em; font-weight: 600; }
.bill-card b { font-size: 2rem; letter-spacing: -0.03em; font-variant-numeric: tabular-nums; color: var(--accent); }
.bill-table-wrap { border: 1px solid var(--border); border-radius: 16px; overflow: hidden; background: var(--bg-raised); }
.bill-table { width: 100%; border-collapse: collapse; font-size: .9rem; }
.bill-table th { text-align: left; font-size: .72rem; text-transform: uppercase; letter-spacing: .08em; color: var(--text-faint); font-weight: 600; padding: 12px 16px; border-bottom: 1px solid var(--border); background: var(--bg-sunken); }
.bill-table td { padding: 12px 16px; border-bottom: 1px solid var(--border); vertical-align: top; }
.bill-table tr:last-child td { border-bottom: 0; }
.bill-table .r, .b-amt, .b-bal { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
.b-date { color: var(--text-muted); white-space: nowrap; }
.b-item b { display: block; font-weight: 600; }
.b-item span { color: var(--text-muted); font-size: .84rem; }
.b-item a, .b-docs a { color: var(--accent); text-decoration: none; }
.b-item a:hover, .b-docs a:hover { text-decoration: underline; }
.b-amt.plus { color: var(--good); font-weight: 600; }
.b-amt.minus { color: var(--text); }
.b-bal { color: var(--text-muted); }
.b-docs { white-space: nowrap; font-size: .84rem; }
@media (max-width: 640px) {
  .bill-table thead { display: none; }
  .bill-table tr { display: grid; grid-template-columns: 1fr auto; gap: 2px 12px; padding: 12px 14px; border-bottom: 1px solid var(--border); }
  .bill-table td { padding: 0; border: 0; }
  .b-date { grid-column: 1; font-size: .78rem; } .b-amt { grid-column: 2; grid-row: 1 / span 2; align-self: center; }
  .b-item { grid-column: 1; } .b-bal { display: none; } .b-docs { grid-column: 1; }
}

/* ---------- square 1:1 ---------- */
.shape.square { width: 12px; height: 12px; }
.square .screen { aspect-ratio: 1 / 1; max-height: 72vh; margin-inline: auto; }
.square .cell .pic { aspect-ratio: 1 / 1; }
.lib-card.square .lib-thumb img { object-fit: contain; background: #000; }

/* ---------- demo reel: one video strip, two copies, clickable tiles ---------- */
.strip { position: relative; flex: none; height: 112px; aspect-ratio: calc(var(--n) * 332) / 180; }
.strip video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: fill; display: block; }
.tile { position: absolute; top: 0; height: 100%; left: calc(var(--i) / var(--n) * 100%); width: calc(320 / (var(--n) * 332) * 100%); padding: 0; border: 0; background: transparent; cursor: pointer; border-radius: 3px; }
.tile::after { content: ''; position: absolute; inset: 0; margin: auto; width: 34px; height: 34px; border-radius: 50%; background: rgba(0,0,0,.55) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M9 6.5v11l9-5.5z' fill='white'/%3E%3C/svg%3E") center / 18px no-repeat; opacity: 0; transition: opacity .15s; }
.tile:hover, .tile:focus-visible { outline: 2px solid rgba(255,255,255,.85); outline-offset: -2px; }
.tile:hover::after, .tile:focus-visible::after { opacity: 1; }
.reel:hover .reel-track, .reel:focus-within .reel-track { animation-play-state: paused; }
.reel-track:has(.strip) { gap: 0; }
.modal-card.wide { width: min(760px, 100%); }
.demo-video { width: 100%; border-radius: 12px; background: #000; display: block; margin-top: 8px; aspect-ratio: 16 / 9; }
.demo-made { color: var(--text-faint); font-size: .8rem; margin-top: 14px; }
.demo-prompt { font-family: var(--serif); font-style: italic; font-size: 1.05rem; margin: 4px 0 16px; }
:lang(zh) .demo-prompt, :lang(ja) .demo-prompt, :lang(ko) .demo-prompt { font-family: var(--font); font-style: normal; }

/* ---------- improve prompt ---------- */
.slate { flex-direction: row-reverse; }
.slate-tools { display: inline-flex; align-items: center; gap: 12px; }
.enhance-btn { display: inline-flex; align-items: center; gap: 7px; border: 1px solid color-mix(in srgb, var(--accent) 35%, var(--border)); background: color-mix(in srgb, var(--accent-soft) 70%, transparent); color: var(--accent); border-radius: 999px; padding: 6px 13px; font-size: .84rem; font-weight: 600; cursor: pointer; transition: background .15s, transform .15s; }
.enhance-btn:hover { background: var(--accent-soft); transform: translateY(-1px); }
.enhance-btn svg { width: 15px; height: 15px; }
.enhance-btn.busy svg { animation: spin 1.2s linear infinite; }
.enhance-btn:disabled { cursor: wait; opacity: .8; transform: none; }
@keyframes spin { to { transform: rotate(360deg); } }
.demo-actions { display: flex; flex-wrap: wrap; gap: 10px; }
.share-x svg { width: 15px; height: 15px; }
.demo-actions .btn svg { width: 15px; height: 15px; }
.demo-actions .btn:disabled { opacity: .55; cursor: progress; }

/* ---------- sign in / create account ---------- */
.account { gap: 8px; }
.btn-ghost { background: transparent; border-color: transparent; color: var(--text-muted); }
.btn-ghost:hover { color: var(--text); background: var(--bg-sunken); }
.account .btn-primary { padding: 7px 14px; font-size: .88rem; box-shadow: none; }
.auth-tabs { display: grid; grid-template-columns: 1fr 1fr; gap: 4px; padding: 4px; background: var(--bg-sunken); border: 1px solid var(--border); border-radius: 12px; margin: 4px 36px 18px 0; }
.auth-tabs button { border: 0; background: transparent; padding: 8px; border-radius: 9px; font-weight: 600; font-size: .9rem; color: var(--text-muted); cursor: pointer; }
.auth-tabs button[aria-selected="true"] { background: var(--bg-raised); color: var(--text); box-shadow: var(--shadow-1); }
.pw-rule { color: var(--text-faint); font-size: .8rem; margin: -4px 0 12px; }
.pw-field { position: relative; display: block; }
.pw-field input { width: 100%; padding-right: 44px; }
.pw-eye { position: absolute; right: 6px; top: 50%; transform: translateY(-50%); width: 32px; height: 32px; display: grid; place-items: center; border: 0; background: none; color: var(--text-faint); border-radius: 8px; cursor: pointer; }
.pw-eye:hover { color: var(--text); background: var(--bg-raised); }
.pw-eye svg { width: 18px; height: 18px; }
.pw-rules { list-style: none; padding: 0; margin: -4px 0 12px; display: flex; flex-wrap: wrap; gap: 4px 14px; font-size: .8rem; color: var(--text-faint); }
.pw-rules li::before { content: '○'; margin-right: 5px; }
.pw-rules li.ok { color: var(--good); }
.pw-rules li.ok::before { content: '✓'; }
.dots { display: inline-flex; gap: 3px; vertical-align: middle; margin-right: 4px; }
.dots i { width: 5px; height: 5px; border-radius: 50%; background: currentColor; animation: rec 1s infinite; }
.dots i:nth-child(2) { animation-delay: .15s; } .dots i:nth-child(3) { animation-delay: .3s; }

/* ---------- a failed video: calm, refunded, try again ---------- */
.failed .timeline, .failed .board, .failed .hint, .failed .leader { display: none; }
.failed .screen .status .big { font-size: 1.1rem; }
.fail-note { text-align: center; color: var(--text-muted); max-width: 520px; margin: 18px auto 0; }

/* ---------- delete ---------- */
.btn-danger { color: var(--bad); border-color: color-mix(in srgb, var(--bad) 35%, var(--border)); background: var(--bg-raised); }
.btn-danger:hover { background: var(--bad-soft); }
.lib-del { position: absolute; top: 8px; right: 8px; width: 32px; height: 32px; display: grid; place-items: center; border: 0; border-radius: 9px; background: rgba(0,0,0,.55); color: #fff; cursor: pointer; opacity: 0; transition: opacity .15s, background .15s; backdrop-filter: blur(4px); }
.lib-del svg { width: 16px; height: 16px; }
.lib-del:hover { background: #b23b3b; }
a.lib-card:hover .lib-del, .lib-del:focus-visible { opacity: 1; }
@media (hover: none) { .lib-del { opacity: 1; } }
