/* ---------- Boot & shell ---------- */
.boot { min-height: 100vh; display: grid; place-items: center; color: var(--muted); }
.muted { color: var(--muted); }
.small { font-size: 13px; }
.center { text-align: center; }
.i { width: 18px; height: 18px; flex: none; }
.btn .i { width: 16px; height: 16px; }
hr { border: 0; border-top: 1px solid var(--line); margin: 18px 0; }

.shell { display: grid; grid-template-columns: 252px minmax(0, 1fr); min-height: 100vh; }
.side { position: sticky; top: 0; height: 100vh; display: flex; flex-direction: column; gap: 18px; padding: 18px 14px;
  background: var(--surface); border-right: 1px solid var(--line); }
.side-top { display: flex; align-items: center; justify-content: space-between; padding: 2px 6px; }
.side-close { display: none; }
.new-btn { height: 40px; }
.side-nav { display: flex; flex-direction: column; gap: 2px; }
.side-nav a { display: flex; align-items: center; gap: 11px; padding: 8px 10px; border-radius: 9px; color: var(--muted); text-decoration: none;
  font-weight: 550; font-size: 14px; transition: background .12s, color .12s; }
.side-nav a:hover { background: var(--surface-2); color: var(--text); }
.side-nav a.on { background: var(--accent-soft); color: var(--accent-text); }
.side-label { font-size: 11.5px; font-weight: 700; letter-spacing: .07em; text-transform: uppercase; color: var(--faint); margin: 16px 10px 4px; }
.side-foot { margin-top: auto; display: flex; flex-direction: column; gap: 12px; }
.usage { background: var(--surface-2); border: 1px solid var(--line); border-radius: var(--r); padding: 12px; display: flex; flex-direction: column; gap: 9px; }
.usage-row { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.usage-num { font-size: 12.5px; color: var(--muted); font-weight: 550; }
.usage-up { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; font-weight: 600; text-decoration: none; color: var(--accent-text); }
.usage-up .i { width: 15px; height: 15px; }
.meter { height: 6px; border-radius: 999px; background: var(--surface-3); overflow: hidden; }
.meter.lg { height: 9px; }
.meter span { display: block; height: 100%; border-radius: inherit; background: var(--accent); transition: width .4s; }
.meter.high span { background: var(--warn); }
.meter.full span { background: var(--err); }
.whoami { display: flex; align-items: center; gap: 10px; padding: 4px 2px 0 4px; }
.avatar { width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center; background: var(--ink); color: #fff; font-weight: 700; font-size: 13px; flex: none; }
.who { display: flex; flex-direction: column; min-width: 0; flex: 1; line-height: 1.3; }
.who b { font-size: 13.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.who small { font-size: 12px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

.main { min-width: 0; }
.mobile-bar { display: none; }
.scrim { display: none; }
@media (max-width: 900px) {
  .shell { grid-template-columns: 1fr; }
  .side { position: fixed; z-index: 50; left: 0; width: 280px; transform: translateX(-100%); transition: transform .22s ease; box-shadow: var(--shadow-lg); }
  body.side-open .side { transform: none; }
  .side-close { display: inline-flex; }
  body.side-open .scrim { display: block; position: fixed; inset: 0; background: rgba(0,0,0,.35); z-index: 40; }
  .mobile-bar { display: flex; align-items: center; gap: 10px; position: sticky; top: 0; z-index: 30; height: 56px; padding: 0 12px;
    background: color-mix(in srgb, var(--surface) 92%, transparent); backdrop-filter: blur(10px); border-bottom: 1px solid var(--line); }
  .mobile-bar .brand { margin-right: auto; font-size: 17px; }
}

/* ---------- Page scaffolding ---------- */
.page { padding: 34px clamp(16px, 4vw, 48px) 64px; max-width: 1240px; margin: 0 auto; }
.narrow-page { max-width: 1120px; }
.page-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; margin-bottom: 26px; flex-wrap: wrap; }
.page-head h1 { font-family: var(--display); font-size: 30px; font-weight: 700; letter-spacing: -.025em; }
.page-head p { margin-top: 4px; }
.crumb { display: inline-flex; align-items: center; gap: 4px; color: var(--muted); text-decoration: none; font-size: 13.5px; font-weight: 550; margin: 0 0 14px -4px; }
.crumb:hover { color: var(--text); }
.crumb .i { width: 16px; height: 16px; }
.note { padding: 12px 14px; border-radius: var(--r); font-size: 14px; background: var(--surface-2); border: 1px solid var(--line); margin-bottom: 18px; }
.note.err { background: var(--err-soft); border-color: transparent; color: var(--err); }
.note.info { display: flex; gap: 10px; align-items: flex-start; background: var(--accent-soft); border-color: transparent; }
.note.info .i { color: var(--accent-text); margin-top: 1px; }
.banner { display: flex; align-items: center; gap: 12px; padding: 14px 16px; border-radius: var(--r); margin-bottom: 20px;
  background: linear-gradient(95deg, var(--accent-soft), var(--surface)); border: 1px solid var(--line); }
.banner > .i { color: var(--accent-text); }
.banner > div { flex: 1; font-size: 14px; }
.block-label { font-size: 12px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--faint); margin-bottom: 10px; }
.row-actions { display: flex; gap: 10px; flex-wrap: wrap; }
.two { display: grid; grid-template-columns: 1fr 1fr; gap: 0 14px; }
@media (max-width: 640px) { .two { grid-template-columns: 1fr; } }

/* ---------- Auth ---------- */
.auth { min-height: 100vh; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, .9fr); }
@media (max-width: 900px) { .auth { grid-template-columns: 1fr; } .auth-aside { display: none; } }
.auth-panel { display: flex; flex-direction: column; padding: 28px clamp(20px, 5vw, 64px); }
.auth-card { width: min(400px, 100%); margin: auto; padding: 40px 0; }
.auth-card h1 { font-family: var(--display); font-size: 32px; letter-spacing: -.03em; margin-bottom: 8px; }
.auth-card > p { margin-bottom: 28px; }
.switch-auth { margin-top: 22px; font-size: 14px; color: var(--muted); text-align: center; }
.auth-foot { font-size: 12.5px; color: var(--faint); text-align: center; }
.auth-aside { background: radial-gradient(700px 500px at 70% 20%, rgba(91,76,255,.35), transparent 65%), var(--ink); color: #fff;
  display: flex; align-items: center; padding: 48px; }
.aside-in { max-width: 420px; margin: 0 auto; }
.aside-quote { font-family: var(--display); font-size: 30px; font-weight: 700; line-height: 1.15; letter-spacing: -.02em; margin-bottom: 32px; }
.aside-list { list-style: none; padding: 0; margin: 0; display: grid; gap: 14px; color: rgba(255,255,255,.72); }
.aside-list li { padding-left: 22px; position: relative; }
.aside-list li::before { content: ""; position: absolute; left: 0; top: 8px; width: 8px; height: 8px; border-radius: 50%; background: var(--accent); }
.aside-list b { color: #fff; }

/* ---------- Demos grid ---------- */
.toolbar { margin-bottom: 20px; }
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(270px, 1fr)); gap: 18px; }
.grid-skel { display: contents; }
.grid-skel div, .demo-skel div, .scene-skel div { border-radius: var(--r-lg); background: linear-gradient(90deg, var(--surface-2), var(--surface-3), var(--surface-2));
  background-size: 200% 100%; animation: shimmer 1.3s infinite; }
.grid-skel div { aspect-ratio: 16 / 12; }
@keyframes shimmer { to { background-position: -200% 0; } }
.demo-card { display: flex; flex-direction: column; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); overflow: hidden;
  text-decoration: none; color: inherit; transition: transform .15s, box-shadow .15s, border-color .15s; }
.demo-card:hover { transform: translateY(-2px); box-shadow: var(--shadow); border-color: var(--line-strong); }
.thumb { position: relative; aspect-ratio: 16 / 9; background: var(--surface-2); border-bottom: 1px solid var(--line); overflow: hidden; }
.thumb img { width: 100%; height: 100%; object-fit: cover; }
.thumb-ph { height: 100%; display: grid; place-items: center; color: var(--faint); }
.thumb-ph .i { width: 28px; height: 28px; }
.dur { position: absolute; left: 8px; bottom: 8px; font-size: 11.5px; font-weight: 700; color: #fff; background: rgba(0,0,0,.65); padding: 2px 7px; border-radius: 6px; }
.play { position: absolute; left: 50%; top: 50%; width: 46px; height: 46px; margin: -23px 0 0 -23px; border-radius: 50%; display: grid; place-items: center;
  background: rgba(13,14,19,.62); color: #fff; opacity: 0; transform: scale(.9); transition: opacity .15s, transform .15s; backdrop-filter: blur(4px); }
.play .i { width: 18px; height: 18px; margin-left: 2px; }
.demo-card:hover .play { opacity: 1; transform: none; }
.demo-meta { padding: 12px 14px 14px; display: flex; flex-direction: column; gap: 7px; }
.demo-title { display: flex; align-items: center; gap: 6px; }
.demo-title b { font-size: 14.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.shared { color: var(--accent-text); display: grid; }
.shared .i { width: 14px; height: 14px; }
.demo-sub { display: flex; align-items: center; gap: 6px; font-size: 12.5px; color: var(--muted); white-space: nowrap; overflow: hidden; }
.demo-sub span:not(.pill) { overflow: hidden; text-overflow: ellipsis; }

.empty { display: flex; flex-direction: column; align-items: center; text-align: center; padding: 64px 20px; max-width: 520px; margin: 0 auto; gap: 14px; }
.empty.small { padding: 48px 20px; }
.empty h2 { font-family: var(--display); font-size: 26px; letter-spacing: -.02em; }
.empty .fine { font-size: 13px; }
.empty-art { position: relative; width: 260px; height: 160px; border-radius: 16px; background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow); margin-bottom: 14px; overflow: hidden; }
.ea-win { display: flex; gap: 5px; padding: 10px 12px; border-bottom: 1px solid var(--line); background: var(--surface-2); }
.ea-win i { width: 8px; height: 8px; border-radius: 50%; background: var(--line-strong); }
.ea-cap { position: absolute; left: 30px; right: 30px; bottom: 16px; height: 22px; border-radius: 7px; background: var(--ink); border-left: 3px solid var(--accent); }
.ea-cursor { position: absolute; width: 18px; height: 18px; left: 70px; top: 60px; background: var(--text);
  clip-path: polygon(0 0, 0 100%, 30% 72%, 52% 100%, 64% 94%, 44% 66%, 80% 66%); animation: roam 5s ease-in-out infinite; }
@keyframes roam { 0%,100% { transform: translate(0,0); } 35% { transform: translate(110px,-20px); } 65% { transform: translate(50px,20px); } }

/* ---------- New demo ---------- */
.compose { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 24px; align-items: start; }
@media (max-width: 1000px) { .compose { grid-template-columns: 1fr; } }
.compose-form { padding: 26px; }
.compose-form fieldset { border: 0; padding: 0; margin: 0; min-width: 0; }
.examples { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; margin-top: 4px; }
.chip-btn { border: 1px solid var(--line); background: var(--surface-2); border-radius: 999px; padding: 3px 11px; font-size: 12.5px; font-weight: 550; cursor: pointer; color: var(--muted); }
.chip-btn:hover { border-color: var(--accent); color: var(--accent-text); }
.advanced { border: 1px solid var(--line); border-radius: var(--r); margin: 0 0 18px; }
.advanced summary { cursor: pointer; padding: 12px 14px; font-weight: 600; font-size: 14px; list-style: none; display: flex; align-items: center; gap: 8px; }
.advanced summary::-webkit-details-marker { display: none; }
.advanced summary::before { content: ""; width: 7px; height: 7px; border-right: 2px solid var(--muted); border-bottom: 2px solid var(--muted); transform: rotate(-45deg); transition: transform .15s; }
.advanced[open] summary::before { transform: rotate(45deg); }
.adv-grid { display: grid; grid-template-columns: auto 1fr; gap: 0 24px; padding: 4px 14px 0; }
.adv-grid .model-field { grid-column: 1 / -1; }
@media (max-width: 640px) { .adv-grid { grid-template-columns: 1fr; } }
.color-row { display: flex; align-items: center; gap: 10px; }
.model-field .pill .i { width: 12px; height: 12px; }
.review-toggle { align-items: flex-start; margin: 4px 0 20px; }
.review-toggle input { margin-top: 2px; }
.compose-foot { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding-top: 18px; border-top: 1px solid var(--line); flex-wrap: wrap; }
.compose-side { position: sticky; top: 24px; padding: 4px 4px; }
.compose-side h3 { font-size: 14px; margin-bottom: 14px; }
.next-steps { margin: 0 0 22px; padding: 0; list-style: none; counter-reset: n; display: grid; gap: 14px; }
.next-steps li { counter-increment: n; position: relative; padding-left: 34px; font-size: 14px; color: var(--muted); }
.next-steps li::before { content: counter(n); position: absolute; left: 0; top: -1px; width: 22px; height: 22px; border-radius: 7px; background: var(--accent-soft);
  color: var(--accent-text); display: grid; place-items: center; font-size: 12px; font-weight: 800; }
.next-steps b { color: var(--text); }
.side-tip { display: flex; gap: 10px; padding: 14px; border-radius: var(--r); background: var(--surface); border: 1px solid var(--line); font-size: 13.5px; color: var(--muted); }
.side-tip .i { color: var(--text); margin-top: 1px; }
.side-tip b { color: var(--text); }

/* ---------- Demo detail ---------- */
.demo-skel { display: grid; gap: 16px; }
.demo-skel div:first-child { height: 64px; }
.demo-skel div:last-child { aspect-ratio: 16 / 7; }
.demo-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; flex-wrap: wrap; margin-bottom: 22px; }
.dh-main { min-width: 0; flex: 1; }
.dh-main h1 { font-family: var(--display); font-size: 28px; letter-spacing: -.025em; overflow-wrap: anywhere; }
.dh-sub { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-top: 8px; font-size: 13.5px; }
.dh-sub a { color: var(--muted); }
.dh-sub .i { width: 14px; height: 14px; display: inline; vertical-align: -2px; margin-right: 4px; }
.model-tag { font-family: var(--mono); font-size: 12px; }
.dh-actions { display: flex; gap: 8px; flex-wrap: wrap; }

.stepper { display: flex; list-style: none; padding: 0; margin: 0 0 26px; gap: 0; }
.stepper li { flex: 1; display: flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 600; color: var(--faint); position: relative; padding-right: 10px; }
.stepper li:not(:last-child)::after { content: ""; flex: 1; height: 2px; background: var(--line); border-radius: 2px; margin-left: 4px; }
.stepper li.done::after { background: var(--accent); }
.sd { width: 18px; height: 18px; border-radius: 50%; border: 2px solid var(--line-strong); background: var(--surface); flex: none; }
.stepper li.done { color: var(--text); }
.stepper li.done .sd { border-color: var(--accent); background: var(--accent) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M4 8.5l2.5 2.5L12 5.5' stroke='white' stroke-width='2.2' fill='none'/%3E%3C/svg%3E") center/12px no-repeat; }
.stepper li.active { color: var(--accent-text); }
.stepper li.active .sd { border-color: var(--accent); border-right-color: transparent; animation: spin .8s linear infinite; }
.stepper li.wait { color: var(--warn); }
.stepper li.wait .sd { border-color: var(--warn); background: var(--warn-soft); }
.stepper li.fail { color: var(--err); }
.stepper li.fail .sd { border-color: var(--err); background: var(--err); }
@media (max-width: 640px) { .stepper li { font-size: 0; } .stepper li.active, .stepper li.wait, .stepper li.fail { font-size: 12.5px; } }

.wait-card { display: flex; gap: 16px; align-items: flex-start; padding: 20px 22px; margin-bottom: 16px; }
.wait-card .spinner { width: 20px; height: 20px; color: var(--accent); margin-top: 2px; }
.wait-card p { margin-top: 3px; font-size: 14px; }
.scene-skel { display: grid; gap: 12px; }
.scene-skel div { height: 132px; }

.review { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 22px; align-items: start; }
@media (max-width: 1000px) { .review { grid-template-columns: 1fr; } .review-side { order: -1; } }
.cards-block { padding: 18px 18px 2px; margin-bottom: 14px; }
.scenes { list-style: none; padding: 0; margin: 0 0 12px; display: grid; gap: 12px; }
.scene { padding: 14px 18px 2px; }
.scene-head { display: flex; align-items: center; gap: 10px; margin-bottom: 12px; }
.scene-n { width: 28px; height: 28px; border-radius: 8px; background: var(--accent-soft); color: var(--accent-text); display: grid; place-items: center; font-weight: 800; font-size: 13px; flex: none; }
.scene-title { font-weight: 700; font-size: 15px; border-color: transparent !important; background: transparent !important; padding-left: 6px !important; }
.scene-title:hover { background: var(--surface-2) !important; }
.scene-title:focus { border-color: var(--accent) !important; background: var(--surface) !important; }
.scene-tools { display: flex; gap: 2px; }
.btn.icon.sm { width: 30px; height: 30px; }
.add-scene { width: 100%; border-style: dashed; height: 44px; color: var(--muted); }
.scene-limit { margin: 8px 0 18px; }
.review-side .sticky { position: sticky; top: 20px; padding: 18px; }
.review-side hr { margin: 18px -18px; }

.live { display: grid; grid-template-columns: minmax(0, 1fr) 280px; gap: 18px; }
@media (max-width: 1100px) { .live { grid-template-columns: 1fr; } }
.screen { position: relative; aspect-ratio: 16 / 9; border-radius: var(--r-lg); overflow: hidden; background: #0b0d12; border: 1px solid var(--line); }
.screen img { width: 100%; height: 100%; object-fit: contain; }
.live-tag { position: absolute; top: 12px; left: 12px; display: flex; align-items: center; gap: 7px; font-size: 12px; font-weight: 700; color: #fff;
  background: rgba(0,0,0,.6); padding: 5px 11px; border-radius: 999px; backdrop-filter: blur(6px); }
.live-tag.recording::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--rec); animation: blink 1.2s infinite; }
.screen-over { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; gap: 12px; color: #fff; font-weight: 600;
  background: rgba(11,13,18,.72); backdrop-filter: blur(3px); }
.live-side { padding: 18px; }
.live-side h3 { font-size: 14px; margin-bottom: 12px; }
.live-side .small { margin-top: 14px; }
.progress { list-style: none; margin: 0; padding: 0; display: grid; gap: 4px; }
.progress li { display: flex; gap: 10px; align-items: center; font-size: 14px; padding: 7px 8px; border-radius: 9px; color: var(--muted); }
.progress .dot { width: 22px; height: 22px; border-radius: 7px; display: grid; place-items: center; font-size: 11.5px; font-weight: 700; background: var(--surface-2); flex: none; }
.progress .dot .i { width: 13px; height: 13px; }
.progress li.now { background: var(--accent-soft); color: var(--text); font-weight: 600; }
.progress li.now .dot { background: var(--accent); color: #fff; }
.progress li.ok { color: var(--text); }
.progress li.ok .dot { background: var(--ok-soft); color: var(--ok); }
.progress li.partial .dot { background: var(--warn-soft); color: var(--warn); }

.player { border-radius: var(--r-lg); overflow: hidden; background: #0b0d12; box-shadow: var(--shadow); }
.player video { width: 100%; aspect-ratio: 16 / 9; background: #0b0d12; }
.done-row { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin: 14px 0 20px; flex-wrap: wrap; }
.chips { display: flex; gap: 6px; flex-wrap: wrap; }
.chip { display: inline-flex; align-items: center; gap: 5px; font-size: 12.5px; font-weight: 600; padding: 3px 10px; border-radius: 999px; background: var(--ok-soft); color: var(--ok); }
.chip .i { width: 13px; height: 13px; }
.chip.partial, .chip.skipped { background: var(--warn-soft); color: var(--warn); }
.retake { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 16px 18px; flex-wrap: wrap; }
.retake p { margin-top: 2px; }

.activity { margin-top: 28px; }
.activity summary { cursor: pointer; color: var(--muted); font-size: 13.5px; font-weight: 600; }
.log { margin-top: 12px; max-height: 260px; overflow: auto; font: 12.5px/1.6 var(--mono); background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 12px 14px; }
.log div { white-space: pre-wrap; word-break: break-word; }
.log .t { color: var(--faint); margin-right: 10px; }
.log .action { color: var(--accent-text); }
.log .warn { color: var(--warn); }
.log .error { color: var(--err); }

.share-switch { align-items: flex-start; margin-bottom: 16px; }
.share-switch input { margin-top: 2px; }
.share-link { display: flex; gap: 8px; }
.share-link input { font-family: var(--mono); font-size: 13px; }

/* ---------- Settings ---------- */
.tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--line); margin-bottom: 28px; overflow-x: auto; }
.tabs a, .tabs button { padding: 10px 12px; margin-bottom: -1px; border: 0; border-bottom: 2px solid transparent; background: none; color: var(--muted);
  text-decoration: none; font-weight: 600; font-size: 14px; cursor: pointer; white-space: nowrap; }
.tabs a:hover, .tabs button:hover { color: var(--text); }
.tabs .on { color: var(--text); border-bottom-color: var(--accent); }
.tabs.mini { margin-bottom: 16px; }
.set-section { display: grid; grid-template-columns: 260px minmax(0, 1fr); gap: 24px; padding: 0 0 30px; margin-bottom: 30px; border-bottom: 1px solid var(--line); }
.set-section:last-child { border-bottom: 0; }
@media (max-width: 900px) { .set-section { grid-template-columns: 1fr; gap: 12px; } }
.set-intro h2 { font-size: 16px; margin-bottom: 4px; }
.set-intro p { font-size: 14px; }
.set-card { padding: 22px; max-width: 640px; }
.set-foot { display: flex; justify-content: flex-end; }
.danger-card { display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; border-color: color-mix(in srgb, var(--err) 30%, var(--line)); }
.locked { display: flex; gap: 12px; align-items: flex-start; }
.locked > .i { color: var(--muted); margin-top: 2px; }
.locked > div { flex: 1; }
.locked b { font-family: var(--mono); font-size: 13.5px; }

.plan-now { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.2fr) auto; gap: 28px; align-items: center; padding: 24px; margin-bottom: 36px; }
@media (max-width: 900px) { .plan-now { grid-template-columns: 1fr; } }
.pn-main h2 { font-family: var(--display); font-size: 28px; display: flex; align-items: center; gap: 10px; margin-bottom: 4px; }
.pn-usage { display: grid; gap: 8px; }
.section-title { font-size: 17px; margin-bottom: 16px; }
.plan-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin-bottom: 16px; max-width: 1100px; }
@media (max-width: 1000px) { .plan-grid { grid-template-columns: 1fr; max-width: 460px; } }
.plan-card { padding: 22px; display: flex; flex-direction: column; }
.plan-card.featured:not(.current) { border-color: var(--accent); box-shadow: 0 0 0 1px var(--accent); }
.plan-card.current { background: var(--surface-2); }
.pc-head { display: flex; align-items: center; justify-content: space-between; }
.pc-head h3 { font-family: var(--display); font-size: 20px; }
.pc-price { display: flex; align-items: baseline; gap: 5px; margin: 10px 0 2px; }
.pc-price b { font-family: var(--display); font-size: 34px; letter-spacing: -.03em; }
.pc-price span { color: var(--muted); font-size: 13.5px; }
.pc-tag { min-height: 2.8em; }
.plan-card ul { list-style: none; padding: 0; margin: 14px 0 20px; display: grid; gap: 8px; flex: 1; align-content: start; }
.plan-card li { display: flex; gap: 8px; font-size: 14px; }
.plan-card li .i { width: 16px; height: 16px; color: var(--accent); margin-top: 2px; }

.key-list { list-style: none; padding: 0; margin: 0 0 16px; }
.key-list li { display: grid; grid-template-columns: 1fr auto; gap: 2px 12px; padding: 12px 0; border-bottom: 1px solid var(--line); align-items: center; }
.key-list li > div { display: flex; align-items: center; gap: 10px; }
.key-list li > span { grid-column: 1; }
.key-list li > button { grid-column: 2; grid-row: 1 / span 2; }
.empty-keys { margin-bottom: 16px; }
.new-key { display: flex; gap: 8px; }
.code { position: relative; background: var(--ink); border-radius: var(--r); margin: 8px 0 0; }
.code pre { margin: 0; padding: 14px 96px 14px 16px; color: #e6e6ee; font: 12.5px/1.65 var(--mono); white-space: pre-wrap; overflow-wrap: anywhere; }
.code .btn { position: absolute; top: 8px; right: 8px; background: rgba(255,255,255,.08); border-color: rgba(255,255,255,.12); color: #fff; }
.code .btn:hover { background: rgba(255,255,255,.16); }
.prompt-eg { margin: 0; padding: 12px 16px; border-left: 3px solid var(--accent); background: var(--surface-2); border-radius: 0 var(--r-sm) var(--r-sm) 0; font-size: 14px; color: var(--muted); }
.tools-list { margin-top: 18px; }
.tools-list summary { cursor: pointer; font-weight: 600; font-size: 14px; }
.tools-list table { border-collapse: collapse; margin-top: 10px; font-size: 13.5px; }
.tools-list td { padding: 7px 12px 7px 0; border-bottom: 1px solid var(--line); vertical-align: top; color: var(--muted); }
.tools-list td:first-child { white-space: nowrap; }

/* ---------- Modal & toasts ---------- */
.modal-wrap { position: fixed; inset: 0; z-index: 100; display: grid; place-items: center; padding: 16px; background: rgba(10,11,15,.5);
  opacity: 0; transition: opacity .18s; backdrop-filter: blur(2px); }
.modal-wrap.in { opacity: 1; }
.modal { width: min(460px, 100%); background: var(--surface); border-radius: var(--r-lg); box-shadow: var(--shadow-lg); border: 1px solid var(--line);
  transform: translateY(8px) scale(.98); transition: transform .18s; max-height: calc(100vh - 32px); overflow: auto; }
.modal.wide { width: min(640px, 100%); }
.modal-wrap.in .modal { transform: none; }
.modal-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 18px 18px 0 22px; }
.modal-head h2 { font-size: 18px; }
.modal-body { padding: 12px 22px 6px; }
.modal-foot { display: flex; justify-content: flex-end; gap: 8px; padding: 18px 22px 20px; }
.upgrade-art { width: 48px; height: 48px; border-radius: 14px; display: grid; place-items: center; background: var(--accent-soft); color: var(--accent-text); margin-bottom: 14px; }
.upgrade-art .i { width: 24px; height: 24px; }

.toasts { position: fixed; bottom: 18px; left: 50%; transform: translateX(-50%); z-index: 200; display: flex; flex-direction: column; gap: 8px; align-items: center; pointer-events: none; }
.toast { pointer-events: auto; background: var(--ink); color: #fff; padding: 10px 16px; border-radius: 10px; font-size: 14px; font-weight: 500; box-shadow: var(--shadow-lg);
  opacity: 0; transform: translateY(8px); transition: opacity .2s, transform .2s; max-width: min(520px, calc(100vw - 32px)); }
.toast.in { opacity: 1; transform: none; }
.toast.ok { border-left: 3px solid #4fcf9c; }
.toast.error { border-left: 3px solid #ff7b8b; }

/* ---------- Auto mode & voice-over ---------- */
.mode-switch { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-bottom: 22px; }
@media (max-width: 560px) { .mode-switch { grid-template-columns: 1fr; } }
.mode-switch label { position: relative; cursor: pointer; }
.mode-switch input { position: absolute; opacity: 0; pointer-events: none; }
.mode-switch span { display: flex; flex-direction: column; gap: 3px; height: 100%; padding: 13px 14px; border: 1px solid var(--line-strong);
  border-radius: var(--r); background: var(--surface); transition: border-color .15s, box-shadow .15s, background .15s; }
.mode-switch b { display: flex; align-items: center; gap: 8px; font-size: 14.5px; }
.mode-switch b .i { width: 16px; height: 16px; color: var(--muted); }
.mode-switch small { color: var(--muted); font-size: 12.5px; }
.mode-switch input:checked + span { border-color: var(--accent); box-shadow: 0 0 0 1px var(--accent); background: var(--accent-soft); }
.mode-switch input:checked + span b .i { color: var(--accent-text); }
.mode-switch input:focus-visible + span { outline: 2px solid var(--accent); outline-offset: 2px; }

.voice-field { grid-column: 1 / -1; padding: 14px; border: 1px solid var(--line); border-radius: var(--r); background: var(--surface-2); }
.voice-row { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.voice-row select { width: auto; min-width: 200px; flex: 1; }
.voice-field .pill .i { width: 12px; height: 12px; }

.stories { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin-bottom: 18px; }
@media (max-width: 1100px) { .stories { grid-template-columns: 1fr; } }
.story { padding: 20px; display: flex; flex-direction: column; gap: 10px; }
.story-aud { font-size: 12px; font-weight: 700; letter-spacing: .05em; text-transform: uppercase; color: var(--accent-text); }
.story h3 { font-family: var(--display); font-size: 19px; letter-spacing: -.015em; }
.story-body { color: var(--text); font-size: 14.5px; flex: 1; }
.story-why { display: flex; gap: 8px; color: var(--muted); font-size: 13.5px; }
.story-why .i { width: 15px; height: 15px; color: var(--accent-text); margin-top: 2px; }
.story-login { display: flex; gap: 7px; align-items: center; color: var(--warn); font-size: 13px; }
.story-login .i { width: 14px; height: 14px; }
.own-story { padding: 20px; max-width: 760px; }

.field.narration { margin-bottom: 12px; }
.field.narration .label .i { width: 15px; height: 15px; color: var(--accent-text); }
.field.narration textarea { background: color-mix(in srgb, var(--accent-soft) 45%, var(--surface)); }

/* ---------- Pay per demo ---------- */
.banner.paywall { flex-wrap: wrap; }
.paywall-actions { display: flex; gap: 8px; }
.buy-points { list-style: none; padding: 0; margin: 14px 0 0; display: grid; gap: 8px; font-size: 14px; }
.buy-points li { display: flex; gap: 8px; align-items: center; }
.buy-points .i { width: 16px; height: 16px; color: var(--accent); }
.pn-actions { display: flex; flex-direction: column; gap: 8px; }
.plan-grid.two-up { grid-template-columns: repeat(2, 1fr); max-width: 760px; }
@media (max-width: 800px) { .plan-grid.two-up { grid-template-columns: 1fr; } }
.section-sub { margin: -10px 0 16px; }
#side-buy { margin-top: 2px; }

.label-row { justify-content: space-between; }
.forgot { font-weight: 500; font-size: 13px; }
.auth-foot a { color: inherit; }

/* ---------- Moves in the script editor ---------- */
.move-row { display: grid; grid-template-columns: minmax(0, 220px) minmax(0, 1fr) minmax(0, 200px); gap: 0 12px; align-items: end; }
.move-row .field:only-child { max-width: 260px; }
@media (max-width: 760px) { .move-row { grid-template-columns: 1fr; } }
.zoom-toggle { grid-column: 1 / -1; align-items: flex-start; margin: 0 0 16px; }
.zoom-toggle input { margin-top: 2px; }

/* Connector: recording apps on the user's computer */
.local-note { margin-top: 18px; padding: 14px 16px; border: 1px solid var(--line); border-radius: var(--r); background: var(--surface-2); }
.local-note .block-label { margin: 0 0 4px; }
.agent-setup { margin-bottom: 4px; }
.agent-setup .block-label { margin: 0 0 4px; }

/* Terms consent (sign-up checkbox and the accept prompt) */
.consent { display: flex; gap: 10px; align-items: flex-start; margin: 4px 0 16px; font-size: 13.5px; line-height: 1.5; color: var(--muted); cursor: pointer; }
.consent input { width: 17px; height: 17px; margin: 2px 0 0; flex: none; accent-color: var(--accent); cursor: pointer; }
.terms-gate { z-index: 150; }
.terms-gate .modal-body > p { margin-bottom: 14px; }

/* "Continue with Google" */
.google-btn { gap: 10px; background: var(--surface); }
.google-btn svg { flex: none; }
.or { display: flex; align-items: center; gap: 12px; margin: 18px 0; color: var(--faint); font-size: 13px; }
.or::before, .or::after { content: ""; flex: 1; height: 1px; background: var(--line); }
