/* =====================================================================
   NovelaClip · Sistema de diseño
   Oscuro, sobrio y de estudio de cine. Un solo acento (degradado de marca).
   ===================================================================== */
:root {
  color-scheme: dark;
  /* Superficies */
  --bg: #07070b;
  --bg-2: #0b0b11;
  --surface: #101017;
  --surface-2: #16161f;
  --surface-3: #1e1e29;
  --surface-4: #262633;
  /* Texto */
  --text: #f4f4f7;
  --text-2: #c9c9d4;
  --muted: #8d8d9e;
  --faint: #5d5d6e;
  /* Bordes */
  --line: rgba(255, 255, 255, 0.075);
  --line-2: rgba(255, 255, 255, 0.12);
  --line-3: rgba(255, 255, 255, 0.2);
  /* Marca */
  --accent: #ff4d8d;
  --accent-2: #a78bfa;
  --violet: #8b5cf6;
  --gold: #f5b942;
  --grad: linear-gradient(120deg, #ff4d8d 0%, #c04cf5 55%, #6d5dfc 100%);
  --grad-soft: linear-gradient(120deg, rgba(255, 77, 141, 0.14), rgba(109, 93, 252, 0.14));
  --soft: rgba(255, 77, 141, 0.1);
  --ring: 0 0 0 1px rgba(255, 77, 141, 0.55), 0 0 0 4px rgba(255, 77, 141, 0.12);
  --ok: #34d399;
  --warn: #fbbf24;
  --err: #f87171;
  /* Forma */
  --r-xs: 8px;
  --r-sm: 10px;
  --r: 14px;
  --r-lg: 18px;
  --r-xl: 24px;
  --radius: var(--r-lg);
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.4);
  --shadow: 0 1px 0 rgba(255, 255, 255, 0.04) inset, 0 10px 30px -12px rgba(0, 0, 0, 0.6);
  --shadow-lg: 0 30px 80px -20px rgba(0, 0, 0, 0.75);
  /* Tipografía */
  --font: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --font-display: "Plus Jakarta Sans", var(--font);
  --ease: cubic-bezier(0.2, 0.7, 0.2, 1);
  --side: 264px;
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html, body { margin: 0; }
html, body { overflow-x: clip; }
html { scroll-behavior: smooth; scroll-padding-top: 84px; }
body {
  font-family: var(--font);
  font-size: 15px;
  line-height: 1.5;
  background: var(--bg);
  min-height: 100vh;
  color: var(--text);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  font-feature-settings: "cv11", "ss01";
}
[hidden] { display: none !important; }
h1, h2, h3, h4 { margin: 0; font-family: var(--font-display); font-weight: 700; letter-spacing: -0.02em; line-height: 1.2; }
p { line-height: 1.6; }
a { color: var(--accent-2); }
img, video { max-width: 100%; }
::selection { background: rgba(255, 77, 141, 0.35); }
.muted { color: var(--muted); }
.small { font-size: 0.86rem; }
.center { text-align: center; }
.error { color: var(--err); min-height: 1.2em; margin: 4px 0; }
.grad { background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
code { font-family: ui-monospace, "SF Mono", Menlo, monospace; font-size: 0.88em; background: var(--surface-3); padding: 1px 6px; border-radius: 6px; }

.ic { width: 18px; height: 18px; flex: none; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.logo { width: 30px; height: 30px; flex: none; border-radius: 9px; box-shadow: 0 6px 18px -6px rgba(192, 76, 245, 0.7); }

/* Barras de desplazamiento discretas */
* { scrollbar-width: thin; scrollbar-color: var(--surface-4) transparent; }
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-thumb { background: var(--surface-4); border-radius: 99px; border: 3px solid transparent; background-clip: padding-box; }
::-webkit-scrollbar-track { background: transparent; }

/* Foco visible accesible */
:focus-visible { outline: 2px solid var(--accent-2); outline-offset: 2px; }
button:focus:not(:focus-visible) { outline: none; }
button, a { -webkit-tap-highlight-color: transparent; touch-action: manipulation; }

/* ---------- Botones ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  border: 1px solid transparent; border-radius: var(--r-sm); padding: 10px 16px;
  font: inherit; font-size: 0.92rem; font-weight: 600; letter-spacing: -0.005em; line-height: 1.2;
  cursor: pointer; text-decoration: none; white-space: nowrap;
  transition: transform 0.12s var(--ease), background 0.18s, border-color 0.18s, box-shadow 0.2s, opacity 0.2s, filter 0.2s;
}
.btn:active { transform: translateY(1px) scale(0.99); }
.btn:disabled { opacity: 0.5; cursor: not-allowed; }
.btn .ic { width: 17px; height: 17px; }
.btn.primary {
  background: var(--grad); color: #fff;
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.25) inset, 0 8px 24px -8px rgba(192, 76, 245, 0.65);
}
.btn.primary:hover:not(:disabled) { filter: brightness(1.08) saturate(1.05); box-shadow: 0 1px 0 rgba(255, 255, 255, 0.3) inset, 0 12px 30px -8px rgba(192, 76, 245, 0.8); }
.btn.ghost { background: rgba(255, 255, 255, 0.04); color: var(--text); border-color: var(--line-2); }
.btn.ghost:hover:not(:disabled) { background: rgba(255, 255, 255, 0.08); border-color: var(--line-3); }
.btn.soft { background: var(--grad-soft); color: #ffb3cf; border-color: rgba(255, 77, 141, 0.22); }
.btn.soft:hover:not(:disabled) { border-color: rgba(255, 77, 141, 0.45); color: #fff; }
.btn.lg { padding: 14px 22px; font-size: 1rem; border-radius: var(--r); }
.btn.sm { padding: 7px 12px; font-size: 0.84rem; border-radius: var(--r-xs); }
.btn.block { width: 100%; }
.link { background: none; border: 0; color: var(--accent-2); font: inherit; font-weight: 600; cursor: pointer; padding: 4px; text-decoration: none; }
.link:hover { color: #c4b5fd; text-decoration: underline; text-underline-offset: 3px; }
.icon-link { display: grid; place-items: center; width: 32px; height: 32px; border-radius: var(--r-xs); border: 0; background: none; color: var(--muted); cursor: pointer; }
.icon-link:hover { background: var(--surface-3); color: var(--text); }
.chip {
  display: inline-flex; align-items: center; gap: 6px;
  border: 1px solid var(--line-2); background: rgba(255, 255, 255, 0.03); color: var(--text-2); border-radius: 999px;
  padding: 7px 14px; font: inherit; font-size: 0.86rem; font-weight: 500; cursor: pointer; transition: all 0.15s;
}
.chip:hover { border-color: var(--line-3); color: var(--text); background: rgba(255, 255, 255, 0.06); }
.chip.on { border-color: rgba(255, 77, 141, 0.6); background: var(--soft); color: #fff; }

/* ---------- Formularios ---------- */
textarea, input, select {
  width: 100%; font: inherit; font-size: 0.95rem; color: var(--text); background: var(--bg-2);
  border: 1px solid var(--line-2); border-radius: var(--r-sm); padding: 11px 13px; outline: none;
  transition: border-color 0.15s, background 0.15s, box-shadow 0.15s;
}
textarea:hover, input:hover, select:hover { border-color: var(--line-3); }
textarea:focus, input:focus, select:focus { border-color: rgba(167, 139, 250, 0.7); background: var(--surface); box-shadow: 0 0 0 4px rgba(167, 139, 250, 0.14); }
::placeholder { color: var(--faint); }
select {
  appearance: none; -webkit-appearance: none; cursor: pointer; padding-right: 36px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%238d8d9e' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 13px center;
}
select option { background: var(--surface-2); color: var(--text); }
textarea { resize: vertical; line-height: 1.55; }
input[type="checkbox"] { width: auto; accent-color: var(--accent); }
select:disabled, input:disabled { opacity: 0.55; cursor: not-allowed; }
.label { display: flex; align-items: baseline; gap: 6px; flex-wrap: wrap; font-weight: 600; font-size: 0.84rem; margin: 20px 0 8px; color: var(--text-2); }
.label small { font-weight: 400; }

/* ======================================================================
   PORTADA
   ====================================================================== */
#landing { position: relative; overflow-x: clip; }
#landing::before {
  content: ""; position: absolute; inset: 0 0 auto 0; height: 1100px; pointer-events: none; z-index: 0;
  background:
    radial-gradient(800px 480px at 78% 4%, rgba(139, 92, 246, 0.2), transparent 65%),
    radial-gradient(680px 440px at 10% 0%, rgba(255, 77, 141, 0.13), transparent 65%);
}
#landing::after {
  content: ""; position: absolute; inset: 0 0 auto 0; height: 900px; pointer-events: none; z-index: 0; opacity: 0.5;
  background-image: linear-gradient(var(--line) 1px, transparent 1px), linear-gradient(90deg, var(--line) 1px, transparent 1px);
  background-size: 64px 64px;
  -webkit-mask-image: radial-gradient(ellipse 70% 60% at 50% 0%, #000 20%, transparent 75%);
  mask-image: radial-gradient(ellipse 70% 60% at 50% 0%, #000 20%, transparent 75%);
}
#landing > * { position: relative; z-index: 1; }
#landing > .topbar { position: sticky; top: 0; z-index: 40; }

.topbar {
  padding-top: env(safe-area-inset-top);
  background: rgba(7, 7, 11, 0.72); backdrop-filter: saturate(160%) blur(16px); -webkit-backdrop-filter: saturate(160%) blur(16px);
  border-bottom: 1px solid var(--line);
}
.topbar-in { display: flex; align-items: center; gap: 28px; max-width: 1200px; margin: 0 auto; padding: 14px 24px; }
.brand { display: inline-flex; align-items: center; gap: 10px; font-family: var(--font-display); font-weight: 800; font-size: 1.08rem; letter-spacing: -0.02em; color: var(--text); text-decoration: none; }
.top-links { display: flex; gap: 4px; margin-right: auto; }
.top-links a { color: var(--muted); text-decoration: none; font-size: 0.9rem; font-weight: 500; padding: 8px 12px; border-radius: var(--r-xs); transition: color 0.15s, background 0.15s; }
.top-links a:hover { color: var(--text); background: rgba(255, 255, 255, 0.05); }
.top-actions { display: flex; gap: 10px; }

.section { max-width: 1200px; margin: 0 auto; padding: 96px 24px 0; }
.section-head { text-align: center; max-width: 680px; margin: 0 auto 44px; }
.section-head h2 { font-size: clamp(1.75rem, 3.6vw, 2.6rem); letter-spacing: -0.035em; line-height: 1.1; font-weight: 800; }
.section-head p { margin: 14px auto 0; font-size: 1.05rem; max-width: 560px; }
.kicker { display: inline-block; font-size: 0.78rem; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; color: var(--accent); margin-bottom: 14px; }

/* Hero */
.hero {
  max-width: 1200px; margin: 0 auto; padding: 72px 24px 56px;
  display: grid; grid-template-columns: 1.05fr 0.95fr; gap: 56px; align-items: center;
}
.eyebrow {
  display: inline-flex; align-items: center; gap: 10px; font-size: 0.84rem; font-weight: 600; color: var(--text-2);
  padding: 6px 14px 6px 10px; border-radius: 999px; border: 1px solid var(--line-2); background: rgba(255, 255, 255, 0.03);
}
.eyebrow i { width: 8px; height: 8px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 0 4px rgba(255, 77, 141, 0.18); animation: livePulse 2s ease-in-out infinite; }
@keyframes livePulse { 50% { box-shadow: 0 0 0 7px rgba(255, 77, 141, 0.05); } }
.hero h1 { font-size: clamp(2.4rem, 5.4vw, 4.2rem); line-height: 1.02; margin: 22px 0 20px; font-weight: 800; letter-spacing: -0.045em; }
.lead { font-size: 1.15rem; color: var(--muted); max-width: 560px; margin: 0; line-height: 1.6; }
.hero-cta { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin-top: 32px; }
.hero-trust { list-style: none; display: flex; flex-wrap: wrap; gap: 8px 22px; padding: 0; margin: 26px 0 0; color: var(--muted); font-size: 0.9rem; }
.hero-trust li { display: inline-flex; align-items: center; gap: 7px; }
.hero-trust .ic { width: 16px; height: 16px; color: var(--ok); stroke-width: 2.4; }

.hero-visual { position: relative; height: 560px; display: grid; place-items: center; }
.hv-phone {
  position: absolute; width: 230px; aspect-ratio: 9 / 16; border-radius: 30px; overflow: hidden; background: #000;
  border: 1px solid var(--line-2); box-shadow: var(--shadow-lg), 0 0 0 6px rgba(255, 255, 255, 0.025);
}
.hv-phone img, .hv-phone video { width: 100%; height: 100%; object-fit: cover; display: block; }
.hv-main { width: 268px; z-index: 2; box-shadow: 0 40px 100px -20px rgba(139, 92, 246, 0.55), 0 0 0 6px rgba(255, 255, 255, 0.04); }
.hv-left { transform: translateX(-58%) rotate(-7deg) scale(0.88); opacity: 0.7; }
.hv-right { transform: translateX(58%) rotate(7deg) scale(0.88); opacity: 0.7; }
.hv-left::after, .hv-right::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(7, 7, 11, 0.1), rgba(7, 7, 11, 0.55)); }
.hv-badge {
  position: absolute; bottom: 14px; left: 14px; display: inline-flex; align-items: center; gap: 6px;
  padding: 6px 10px; border-radius: 999px; font-size: 0.74rem; font-weight: 600; color: #fff;
  background: rgba(0, 0, 0, 0.5); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); border: 1px solid rgba(255, 255, 255, 0.15);
}
.hv-badge .ic { width: 13px; height: 13px; }
.hv-chip {
  position: absolute; z-index: 3; display: flex; align-items: center; gap: 10px; padding: 10px 14px 10px 10px;
  border-radius: var(--r); background: rgba(22, 22, 31, 0.82); border: 1px solid var(--line-2);
  backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); box-shadow: var(--shadow-lg);
  animation: floaty 6s ease-in-out infinite;
}
.hv-chip .ic { width: 34px; height: 34px; padding: 8px; border-radius: 10px; background: var(--grad); color: #fff; stroke-width: 2; }
.hv-chip div { display: flex; flex-direction: column; }
.hv-chip b { font-size: 0.85rem; }
.hv-chip small { font-size: 0.74rem; color: var(--muted); }
.hv-chip-a { left: 0; top: 22%; }
.hv-chip-b { right: 0; bottom: 18%; animation-delay: -3s; }
@keyframes floaty { 50% { transform: translateY(-8px); } }

/* Franja "todo en una herramienta" */
.pipeline { max-width: 1200px; margin: 0 auto; padding: 8px 24px 0; display: flex; flex-direction: column; align-items: center; gap: 16px; }
.pipeline > span { font-size: 0.8rem; font-weight: 600; letter-spacing: 0.1em; text-transform: uppercase; color: var(--faint); }
.pipeline ul { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; }
.pipeline li { display: inline-flex; align-items: center; gap: 8px; padding: 9px 16px; border-radius: 999px; border: 1px solid var(--line); background: rgba(255, 255, 255, 0.02); color: var(--text-2); font-size: 0.9rem; font-weight: 500; }
.pipeline li .ic { width: 16px; height: 16px; color: var(--accent-2); }

/* Ejemplos */
.show-row { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 16px; }
.show-card {
  position: relative; margin: 0; border-radius: var(--r-lg); overflow: hidden; background: #000; cursor: pointer; aspect-ratio: 9 / 16;
  border: 1px solid var(--line-2); box-shadow: var(--shadow); transition: transform 0.3s var(--ease), border-color 0.3s, box-shadow 0.3s;
}
.show-card:hover { transform: translateY(-4px); border-color: var(--line-3); box-shadow: 0 24px 60px -20px rgba(139, 92, 246, 0.45); }
.show-card video { width: 100%; height: 100%; object-fit: cover; display: block; }
.show-card figcaption { position: absolute; left: 0; right: 0; bottom: 0; padding: 40px 14px 14px; text-align: left; background: linear-gradient(transparent, rgba(0, 0, 0, 0.88)); }
.show-card figcaption b { display: block; font-size: 0.95rem; font-family: var(--font-display); }
.show-card figcaption small { color: rgba(255, 255, 255, 0.72); font-size: 0.76rem; line-height: 1.35; display: block; margin-top: 2px; }
.show-sound { position: absolute; top: 10px; right: 10px; width: 32px; height: 32px; display: grid; place-items: center; border-radius: 50%; background: rgba(0, 0, 0, 0.5); backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); border: 1px solid rgba(255, 255, 255, 0.15); font-size: 14px; }

/* Funciones (bento) */
.feat-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.feat {
  position: relative; padding: 26px; border-radius: var(--r-lg); background: linear-gradient(180deg, rgba(255, 255, 255, 0.035), rgba(255, 255, 255, 0.01));
  border: 1px solid var(--line); overflow: hidden; transition: border-color 0.25s, transform 0.25s var(--ease);
}
.feat:hover { border-color: var(--line-2); transform: translateY(-2px); }
.feat-wide { grid-column: span 2; background: radial-gradient(500px 240px at 100% 0%, rgba(139, 92, 246, 0.14), transparent 70%), linear-gradient(180deg, rgba(255, 255, 255, 0.04), rgba(255, 255, 255, 0.01)); }
.feat-ico { display: grid; place-items: center; width: 42px; height: 42px; border-radius: 12px; background: var(--grad-soft); border: 1px solid rgba(255, 77, 141, 0.22); color: #ffb3cf; margin-bottom: 18px; }
.feat-ico .ic { width: 20px; height: 20px; }
.feat h3 { font-size: 1.08rem; margin-bottom: 8px; }
.feat p { margin: 0; color: var(--muted); font-size: 0.93rem; }

/* Pasos */
.steps-strip { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; counter-reset: s; }
.strip-item { position: relative; padding: 28px; border-radius: var(--r-lg); border: 1px solid var(--line); background: var(--surface); }
.strip-item b { display: block; font-family: var(--font-display); font-size: 0.85rem; font-weight: 800; letter-spacing: 0.08em; margin-bottom: 18px; }
.strip-item b { background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.strip-item h4 { font-size: 1.12rem; margin-bottom: 8px; }
.strip-item p { margin: 0; color: var(--muted); font-size: 0.93rem; }

/* Precios */
.pricing { text-align: center; }
.pricing .packs.plans { max-width: 820px; margin-left: auto; margin-right: auto; }
.packs { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 16px; margin-top: 18px; text-align: left; }
.pack {
  position: relative; display: flex; flex-direction: column; gap: 6px; padding: 26px; border-radius: var(--r-lg);
  background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow); transition: border-color 0.2s, transform 0.2s var(--ease);
}
.pack:hover { border-color: var(--line-2); transform: translateY(-2px); }
.pack.featured {
  border: 1px solid transparent;
  background: linear-gradient(180deg, rgba(139, 92, 246, 0.1), transparent 45%) padding-box, linear-gradient(var(--surface), var(--surface)) padding-box, var(--grad) border-box;
  box-shadow: 0 24px 60px -24px rgba(192, 76, 245, 0.55);
}
.pack h4 { font-size: 1rem; color: var(--text-2); font-weight: 600; }
.pack .tag { position: absolute; top: -11px; right: 18px; background: var(--grad); color: #fff; font-size: 0.72rem; font-weight: 700; padding: 4px 10px; border-radius: 999px; box-shadow: 0 6px 16px -4px rgba(192, 76, 245, 0.6); }
.pack .price { font-family: var(--font-display); font-size: 2.3rem; font-weight: 800; letter-spacing: -0.04em; margin-top: 4px; }
.pack .price small { font-size: 0.95rem; font-weight: 500; color: var(--muted); letter-spacing: 0; }
.pack .get { font-size: 0.98rem; color: var(--text-2); }
.pack .get b { color: var(--text); font-size: 1.1rem; }
.pack .per { color: var(--muted); font-size: 0.84rem; margin-bottom: 10px; padding-bottom: 14px; border-bottom: 1px solid var(--line); }
.pack ul { list-style: none; padding: 0; margin: 4px 0 20px; color: var(--text-2); font-size: 0.9rem; flex: 1; display: grid; gap: 9px; align-content: start; }
.pack li { position: relative; padding-left: 24px; }
.pack li::before {
  content: ""; position: absolute; left: 0; top: 3px; width: 16px; height: 16px; border-radius: 50%;
  background: rgba(52, 211, 153, 0.14) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2334d399' stroke-width='3.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M20 6 9 17l-5-5'/%3E%3C/svg%3E") center / 9px no-repeat;
}
.buy-title { margin: 34px 0 6px; font-size: 1.08rem; display: flex; flex-wrap: wrap; align-items: baseline; gap: 10px; }
.buy-title small { font-size: 0.86rem; font-weight: 400; font-family: var(--font); letter-spacing: 0; }
.pricing .buy-title { justify-content: center; }
.pricing .buy-title:first-of-type { margin-top: 0; }

/* Preguntas */
.faq-list { max-width: 780px; margin: 0 auto; display: grid; gap: 10px; }
.faq-list details { border: 1px solid var(--line); border-radius: var(--r); background: var(--surface); transition: border-color 0.2s, background 0.2s; }
.faq-list details[open] { border-color: var(--line-2); background: var(--surface-2); }
.faq-list summary { list-style: none; cursor: pointer; padding: 18px 22px; font-weight: 600; font-size: 1rem; display: flex; justify-content: space-between; align-items: center; gap: 16px; }
.faq-list summary::-webkit-details-marker { display: none; }
.faq-list summary::after { content: "+"; font-size: 1.4rem; font-weight: 300; color: var(--muted); transition: transform 0.2s; line-height: 1; }
.faq-list details[open] summary::after { transform: rotate(45deg); }
.faq-list p { margin: 0; padding: 0 22px 20px; color: var(--muted); }

/* Llamada final */
.final-cta { max-width: 1200px; margin: 0 auto; padding: 110px 24px 0; }
.final-in {
  position: relative; overflow: hidden; text-align: center; padding: 72px 24px; border-radius: var(--r-xl);
  border: 1px solid var(--line-2);
  background: radial-gradient(600px 300px at 50% 0%, rgba(255, 77, 141, 0.22), transparent 70%), radial-gradient(600px 300px at 50% 100%, rgba(109, 93, 252, 0.22), transparent 70%), var(--surface);
}
.final-in h2 { font-size: clamp(1.8rem, 4vw, 2.8rem); font-weight: 800; letter-spacing: -0.04em; }
.final-in p { color: var(--muted); font-size: 1.08rem; margin: 12px 0 28px; }

/* Pie */
.foot { margin-top: 96px; border-top: 1px solid var(--line); }
.foot-in { max-width: 1200px; margin: 0 auto; padding: 48px 24px 32px; display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 32px; }
.foot-brand p { margin: 12px 0 0; max-width: 300px; }
.foot-col { display: flex; flex-direction: column; gap: 10px; font-size: 0.9rem; }
.foot-col b { font-size: 0.8rem; text-transform: uppercase; letter-spacing: 0.08em; color: var(--text-2); margin-bottom: 4px; }
.foot-col a { color: var(--muted); text-decoration: none; }
.foot-col a:hover { color: var(--text); }
.foot-bottom { max-width: 1200px; margin: 0 auto; padding: 20px 24px calc(28px + env(safe-area-inset-bottom)); border-top: 1px solid var(--line); }

/* ======================================================================
   APP
   ====================================================================== */
#app { display: grid; grid-template-columns: var(--side) minmax(0, 1fr); min-height: 100vh; overflow-x: clip; max-width: 100vw; }
#app::before { content: ""; position: fixed; inset: 0; pointer-events: none; z-index: 0; background: radial-gradient(900px 500px at 90% -10%, rgba(139, 92, 246, 0.09), transparent 60%); }
.sidebar {
  position: sticky; top: 0; height: 100vh; z-index: 20; display: flex; flex-direction: column; gap: 22px;
  padding: 20px 14px 16px; background: var(--bg-2); border-right: 1px solid var(--line); overflow-y: auto;
}
.sidebar > .brand { padding: 4px 8px; }
.menu { display: flex; flex-direction: column; gap: 2px; }
.menu-label { font-size: 0.7rem; font-weight: 600; letter-spacing: 0.1em; text-transform: uppercase; color: var(--faint); padding: 16px 10px 6px; }
.menu-label:first-child { padding-top: 4px; }
.menu button {
  position: relative; display: flex; align-items: center; gap: 11px; padding: 9px 10px; border: 0; border-radius: var(--r-sm);
  background: none; font: inherit; font-size: 0.9rem; font-weight: 500; color: var(--muted); cursor: pointer; text-align: left; transition: background 0.15s, color 0.15s;
}
.menu button .ic { width: 18px; height: 18px; }
.menu button:hover { background: rgba(255, 255, 255, 0.04); color: var(--text); }
.menu button.active { background: rgba(255, 255, 255, 0.07); color: var(--text); }
.menu button.active .ic { color: var(--accent); }
.menu button.active::before { content: ""; position: absolute; left: -14px; top: 9px; bottom: 9px; width: 3px; border-radius: 0 3px 3px 0; background: var(--grad); }
.qbadge { font-style: normal; background: var(--accent); color: #fff; font-size: 0.68rem; font-weight: 700; border-radius: 99px; padding: 1px 7px; margin-left: auto; }
.side-bottom { margin-top: auto; display: flex; flex-direction: column; gap: 10px; }
.credit-card {
  position: relative; overflow: hidden; display: flex; flex-direction: column; gap: 4px; padding: 14px; border-radius: var(--r);
  border: 1px solid var(--line-2); background: radial-gradient(240px 120px at 100% 0%, rgba(192, 76, 245, 0.2), transparent 70%), var(--surface-2);
}
.cc-top { display: flex; justify-content: space-between; align-items: center; }
.cc-top .ic { width: 16px; height: 16px; color: var(--accent-2); }
.credit-card strong { font-family: var(--font-display); font-size: 1.9rem; font-weight: 800; letter-spacing: -0.03em; line-height: 1.1; margin-bottom: 8px; }
.user-row { display: flex; justify-content: space-between; align-items: center; gap: 8px; padding: 4px 4px 0 8px; overflow: hidden; }
.user-row span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

.main { position: relative; z-index: 1; padding: 36px clamp(20px, 4vw, 56px) 64px; max-width: 1280px; width: 100%; min-width: 0; margin: 0 auto; }
.panel-head { margin-bottom: 26px; }
.panel-head h2 { font-size: 1.75rem; font-weight: 800; letter-spacing: -0.035em; }
.panel-head p { margin: 8px 0 0; max-width: 720px; }
.banner { background: rgba(251, 191, 36, 0.08); border: 1px solid rgba(251, 191, 36, 0.3); color: #fcd34d; padding: 12px 16px; border-radius: var(--r-sm); margin-bottom: 20px; font-size: 0.9rem; }

.card { position: relative; min-width: 0; background: var(--surface); border-radius: var(--r-lg); padding: 24px; border: 1px solid var(--line); box-shadow: var(--shadow); }
.card-step { display: flex; align-items: center; gap: 10px; font-family: var(--font-display); font-weight: 700; font-size: 1.02rem; margin-bottom: 6px; }
.card-step small { font-family: var(--font); font-weight: 400; }
.card-step b { display: grid; place-items: center; width: 26px; height: 26px; border-radius: 8px; background: var(--grad); color: #fff; font-size: 0.8rem; box-shadow: 0 4px 12px -2px rgba(192, 76, 245, 0.5); }

/* Instalar app */
.install { position: relative; display: flex; align-items: center; gap: 12px; background: var(--surface); border: 1px solid var(--line-2); border-radius: var(--r); padding: 12px 44px 12px 12px; margin-bottom: 20px; }
.install img { width: 42px; height: 42px; border-radius: 11px; }
.install div { display: flex; flex-direction: column; flex: 1; min-width: 0; }
.x { position: absolute; top: 14px; right: 14px; width: 32px; height: 32px; display: grid; place-items: center; background: none; border: 0; border-radius: var(--r-xs); font-size: 1.4rem; line-height: 1; cursor: pointer; color: var(--muted); }
.x:hover { background: var(--surface-3); color: var(--text); }
.install .x { top: 50%; transform: translateY(-50%); right: 8px; }

/* ---------- Crear ---------- */
.create-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 18px; align-items: start; }
.create-grid > * { min-width: 0; }

.tpl-wrap { margin-bottom: 22px; min-width: 0; }
.tpl-wrap.off { display: none !important; }
.tpl-head { display: flex; align-items: baseline; gap: 10px; margin-bottom: 12px; flex-wrap: wrap; }
.tpl-head b { font-family: var(--font-display); font-size: 1rem; }
.tpl-strip { display: flex; gap: 10px; overflow-x: auto; padding: 2px 2px 8px; -webkit-mask-image: linear-gradient(90deg, #000 90%, transparent); mask-image: linear-gradient(90deg, #000 90%, transparent); scroll-snap-type: x mandatory; -webkit-overflow-scrolling: touch; }
.tpl-card {
  flex: 0 0 168px; scroll-snap-align: start; text-align: left; display: flex; flex-direction: column; gap: 4px; padding: 14px;
  border-radius: var(--r); border: 1px solid var(--line); background: var(--surface); color: var(--text); font: inherit; cursor: pointer;
  transition: transform 0.15s var(--ease), border-color 0.15s, background 0.15s;
}
.tpl-card:hover { transform: translateY(-2px); border-color: var(--line-3); background: var(--surface-2); }
.tpl-card.on { border-color: rgba(255, 77, 141, 0.6); background: var(--soft); box-shadow: var(--ring); }
.tpl-card b { font-size: 0.9rem; font-weight: 600; }
.tpl-ico { display: grid; place-items: center; width: 36px; height: 36px; border-radius: 10px; background: var(--surface-3); font-size: 18px; margin-bottom: 6px; }
.tpl-card small { color: var(--muted); font-size: 0.76rem; line-height: 1.35; }

/* Tarjetas de opción (formato / tipo de video) */
.format-opts { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; margin: 14px 0 4px; }
.format-opt, .motion-opt {
  position: relative; display: flex; flex-direction: column; align-items: flex-start; gap: 3px; text-align: left; padding: 13px;
  border: 1px solid var(--line-2); border-radius: var(--r); background: var(--bg-2); color: var(--text); font: inherit; cursor: pointer;
  transition: border-color 0.15s, background 0.15s, box-shadow 0.15s, transform 0.15s var(--ease);
}
.format-opt:hover, .motion-opt:hover { border-color: var(--line-3); background: var(--surface-2); }
.format-opt.on, .motion-opt.on { border-color: rgba(255, 77, 141, 0.7); background: linear-gradient(180deg, rgba(255, 77, 141, 0.09), rgba(139, 92, 246, 0.05)); box-shadow: var(--ring); }
.format-opt > span, .motion-opt .m-ico { display: grid; place-items: center; width: 34px; height: 34px; border-radius: 10px; background: var(--surface-3); font-size: 1.1rem; margin-bottom: 6px; }
.format-opt.on > span, .motion-opt.on .m-ico { background: rgba(255, 77, 141, 0.16); }
.format-opt b, .motion-opt b { font-size: 0.9rem; font-weight: 600; }
.format-opt small, .motion-opt small { color: var(--muted); font-size: 0.76rem; line-height: 1.35; }

.motion-opts { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.motion-opt { padding: 14px; }
.motion-opt .m-badge { position: absolute; top: 12px; right: 12px; background: var(--grad); color: #fff; font-size: 0.62rem; font-weight: 700; padding: 3px 7px; border-radius: 6px; letter-spacing: 0.06em; }
.motion-opt .m-badge.hd { background: linear-gradient(120deg, #0ea5e9, #6366f1); }
.motion-opt .m-badge.save { background: linear-gradient(120deg, #16a34a, #22c55e); }
.motion-opt .m-badge.cine { background: linear-gradient(120deg, #f59e0b, #ef4444); }
.motion-opt .m-price { font-style: normal; font-weight: 600; font-size: 0.78rem; color: #ffb3cf; margin-top: 6px; }
.motion-opt[data-m="cine"] { background: linear-gradient(135deg, rgba(245, 185, 66, 0.07), rgba(239, 68, 68, 0.05)), var(--bg-2); }
.motion-opt[data-m="cine"].on { border-color: var(--gold); box-shadow: 0 0 0 1px var(--gold), 0 0 0 4px rgba(245, 185, 66, 0.12); }

/* Chips de opción (género, estilo) */
.options { display: flex; flex-wrap: wrap; gap: 8px; }
.opt {
  position: relative; border: 1px solid var(--line-2); background: var(--bg-2); color: var(--text-2); border-radius: var(--r-sm);
  padding: 8px 13px; font: inherit; font-weight: 500; font-size: 0.87rem; cursor: pointer; transition: all 0.15s;
}
.opt:hover { border-color: var(--line-3); color: var(--text); }
.opt.on { border-color: rgba(255, 77, 141, 0.7); background: var(--soft); color: #fff; }
.options.styles { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); }
.style-opt { display: flex; flex-direction: column; align-items: center; gap: 7px; padding: 7px; font-size: 0.8rem; }
.style-opt .sw { width: 100%; aspect-ratio: 9 / 12; border-radius: 7px; }

/* Selector segmentado */
.seg { display: flex; background: var(--bg-2); border: 1px solid var(--line); padding: 4px; border-radius: var(--r-sm); gap: 4px; }
.seg button {
  position: relative; flex: 1; min-width: 0; border: 0; background: none; padding: 8px 6px; border-radius: 7px; font: inherit; font-size: 0.88rem; font-weight: 600;
  cursor: pointer; color: var(--muted); display: flex; flex-direction: column; align-items: center; gap: 1px; transition: background 0.15s, color 0.15s;
}
.seg button:hover { color: var(--text); }
.seg button small { font-weight: 500; font-size: 0.7rem; color: var(--faint); }
.seg button.on { background: var(--surface-4); color: var(--text); box-shadow: 0 1px 0 rgba(255, 255, 255, 0.06) inset, 0 2px 8px rgba(0, 0, 0, 0.35); }
.seg button.on small { color: var(--muted); }
.seg.dur button { padding: 8px 2px; }
.seg.dur button small { color: #ffb3cf; font-weight: 600; }
#editBox .seg button small { color: var(--muted); }

.row2 { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.idea-tools { display: flex; align-items: center; gap: 12px; margin-top: 10px; flex-wrap: wrap; }
.voice-note, .plan-note, .script-info {
  margin: 12px 0 0; font-size: 0.84rem; color: var(--muted); background: var(--bg-2); border: 1px solid var(--line); border-radius: var(--r-sm); padding: 10px 12px;
}
.plan-note { grid-column: 1; margin: 4px 0; }
.plan-note .link { padding: 0; font-size: inherit; }
.script-info { color: var(--text-2); background: var(--soft); border-color: rgba(255, 77, 141, 0.2); }
.admin-estimate { grid-column: 1; margin: 4px 0; font-size: 0.84rem; color: #fcd34d; background: rgba(251, 191, 36, 0.06); border: 1px solid rgba(251, 191, 36, 0.25); border-radius: var(--r-sm); padding: 8px 10px; }
.lipsync-row { margin-top: 12px; background: var(--bg-2); border: 1px solid var(--line); border-radius: var(--r); padding: 4px 12px 12px; }
.lipsync-row .label { margin-top: 10px; }

.more-opts { margin-top: 18px; border: 1px solid var(--line); border-radius: var(--r); padding: 0 14px; background: rgba(255, 255, 255, 0.015); }
.more-opts[open] { padding-bottom: 14px; }
.more-opts > summary { cursor: pointer; font-weight: 600; font-size: 0.92rem; list-style: none; display: flex; gap: 8px; align-items: baseline; padding: 14px 0; }
.more-opts > summary small { font-weight: 400; }
.more-opts > summary::-webkit-details-marker { display: none; }
.more-opts > summary::after { content: ""; margin-left: auto; align-self: center; width: 8px; height: 8px; border-right: 2px solid var(--muted); border-bottom: 2px solid var(--muted); transform: rotate(45deg) translateY(-3px); transition: transform 0.2s; }
.more-opts[open] > summary::after { transform: rotate(-135deg) translateY(-1px); }
.more-opts[open] > summary { border-bottom: 1px solid var(--line); margin-bottom: 4px; }

.upload-drop { display: flex; flex-direction: column; align-items: center; gap: 4px; margin-top: 10px; padding: 20px; border: 1.5px dashed var(--line-3); border-radius: var(--r); background: var(--bg-2); cursor: pointer; font-weight: 600; text-align: center; transition: border-color 0.15s; }
.upload-drop small { color: var(--muted); font-weight: 400; }
.upload-drop:hover { border-color: var(--accent); }
.edit-check { margin-top: 14px; }

.generate-card {
  grid-column: 1 / -1; display: grid; grid-template-columns: 1fr auto; align-items: center; gap: 6px 24px;
  background: radial-gradient(600px 200px at 100% 50%, rgba(192, 76, 245, 0.12), transparent 70%), var(--surface);
}
.generate-card .card-step { margin: 0; }
.generate-card p { margin: 0; grid-column: 1; }
.generate-card .btn.lg { grid-column: 2; grid-row: 1 / span 3; width: auto; min-width: 300px; padding: 16px 26px; }
.generate-card .link { grid-column: 1; justify-self: start; }

/* Interruptor */
.switch-row { position: relative; grid-column: 1; display: flex; align-items: center; gap: 12px; cursor: pointer; margin: 8px 0; }
.switch-row input { position: absolute; opacity: 0; pointer-events: none; left: 0; top: 0; width: 1px; height: 1px; }
.switch-row .switch { flex: 0 0 auto; width: 40px; height: 24px; border-radius: 99px; background: var(--surface-4); position: relative; transition: background 0.2s; }
.switch-row .switch::after { content: ""; position: absolute; top: 3px; left: 3px; width: 18px; height: 18px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(0, 0, 0, 0.3); transition: transform 0.2s var(--ease); }
.switch-row input:checked + .switch { background: var(--accent); }
.switch-row input:checked + .switch::after { transform: translateX(16px); }
.switch-row input:focus-visible + .switch { outline: 2px solid var(--accent-2); outline-offset: 2px; }
.switch-row b { font-weight: 600; font-size: 0.92rem; }
.switch-row small { display: block; color: var(--muted); font-size: 0.8rem; }
.mini-check { display: flex; align-items: center; gap: 8px; font-size: 0.87rem; font-weight: 500; white-space: nowrap; cursor: pointer; }
.mini-check input { width: auto; accent-color: var(--accent); }

/* Bloqueado en plan gratis */
.locked { position: relative; opacity: 0.5; }
.locked::after { content: "🔒"; position: absolute; top: 6px; left: 8px; font-size: 0.72rem; }
.seg button.locked::after { top: 2px; left: 4px; font-size: 0.6rem; }
.locked-note { display: block; margin-top: 4px; font-size: 12px; color: var(--muted); }
.locked-note .link { font-size: 12px; }

/* Estilos de subtítulos */
.sub-opts { display: grid; grid-template-columns: repeat(auto-fit, minmax(86px, 1fr)); gap: 8px; margin: 6px 0 10px; }
.sub-opt { display: flex; flex-direction: column; align-items: center; gap: 7px; padding: 7px 7px 9px; border-radius: var(--r-sm); border: 1px solid var(--line-2); background: var(--bg-2); color: inherit; cursor: pointer; font: inherit; transition: border-color 0.15s; }
.sub-opt:hover { border-color: var(--line-3); }
.sub-opt.on { border-color: rgba(255, 77, 141, 0.7); box-shadow: var(--ring); }
.sub-opt small { font-size: 0.74rem; color: var(--text-2); text-align: center; }
.sub-prev { display: flex; align-items: center; justify-content: center; width: 100%; height: 46px; border-radius: 6px; background: linear-gradient(160deg, #3a3550, #12121a); font-family: Anton, Impact, sans-serif; font-size: 0.9rem; color: #fff; letter-spacing: 0.5px; text-shadow: 0 0 3px #000, 0 2px 2px #000; }
.sub-prev i { font-style: normal; color: #ffe800; }
.sp-palabra { font-size: 1.35rem; }
.sp-neon { text-shadow: 0 0 6px #ff3cb4, 0 0 2px #ff3cb4; }
.sp-neon i { color: #00ffff; }
.sp-caja { font-family: Arial, sans-serif; font-weight: 800; font-size: 0.74rem; text-shadow: none; }
.sp-caja b { background: rgba(0, 0, 0, 0.85); padding: 4px 7px; border-radius: 4px; }
.sp-clasico { font-family: Arial, sans-serif; font-weight: 800; font-size: 0.74rem; }
.sp-clasico i { color: #fff; }

/* ---------- Progreso / resultado ---------- */
.job { margin-top: 4px; }
.job-card { padding: 32px; }
.bar { height: 8px; background: var(--surface-3); border-radius: 99px; overflow: hidden; }
.bar i { display: block; height: 100%; width: 0; background: var(--grad); border-radius: 99px; transition: width 0.6s var(--ease); }
.job-steps { list-style: none; padding: 0; margin: 20px 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 8px; }
.job-steps li { padding: 11px 12px; border-radius: var(--r-sm); background: var(--bg-2); border: 1px solid var(--line); color: var(--muted); font-weight: 500; font-size: 0.86rem; text-align: center; transition: all 0.3s; }
.job-steps li.active { background: var(--soft); border-color: rgba(255, 77, 141, 0.4); color: #fff; animation: pulse 1.6s ease-in-out infinite; }
.job-steps li.done { background: rgba(52, 211, 153, 0.07); border-color: rgba(52, 211, 153, 0.25); color: var(--ok); }
@keyframes pulse { 50% { opacity: 0.65; } }
#newWhile { margin-top: 6px; }

.gen-stage { display: grid; grid-template-columns: 210px 1fr; gap: 36px; align-items: center; margin-bottom: 22px; }
.gen-phone { width: 210px; aspect-ratio: 9 / 16; border-radius: 30px; padding: 7px; background: linear-gradient(160deg, #26263a, #0b0b12); box-shadow: 0 30px 60px -10px rgba(0, 0, 0, 0.6), 0 0 0 1px rgba(255, 255, 255, 0.07) inset, 0 0 80px rgba(192, 76, 245, 0.2); }
.gen-screen { position: relative; width: 100%; height: 100%; border-radius: 24px; overflow: hidden; background: radial-gradient(120% 80% at 30% 20%, #34184a 0%, #110d1c 60%, #07070b 100%); }
.gen-screen img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: 0; transition: opacity 1.2s ease; }
.gen-screen img.on { opacity: 1; animation: genKen 6s ease-in-out forwards; }
@keyframes genKen { from { transform: scale(1.02); } to { transform: scale(1.14) translateY(-2%); } }
.gen-glow { position: absolute; inset: -40%; background: conic-gradient(from 0deg, transparent, rgba(255, 77, 141, 0.35), transparent 30%, rgba(139, 92, 246, 0.35), transparent 60%); animation: genSpin 6s linear infinite; mix-blend-mode: screen; opacity: 0.55; }
.gen-screen.has-img .gen-glow { opacity: 0.18; }
@keyframes genSpin { to { transform: rotate(360deg); } }
.gen-scan { position: absolute; left: 0; right: 0; height: 30%; background: linear-gradient(180deg, transparent, rgba(255, 255, 255, 0.12), transparent); animation: genScan 2.6s ease-in-out infinite; }
@keyframes genScan { from { top: -30%; } to { top: 100%; } }
.gen-icon { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); font-size: 50px; filter: drop-shadow(0 6px 18px rgba(0, 0, 0, 0.5)); animation: genFloat 2.4s ease-in-out infinite; }
.gen-screen.has-img .gen-icon { top: auto; bottom: 14px; left: 14px; transform: none; font-size: 24px; animation: none; }
@keyframes genFloat { 50% { transform: translate(-50%, -58%); } }
.gen-count { position: absolute; right: 10px; bottom: 12px; font-size: 11px; font-weight: 600; padding: 4px 8px; border-radius: 99px; background: rgba(0, 0, 0, 0.55); color: #fff; }
.gen-count:empty { display: none; }
.gen-info h3 { font-size: 1.35rem; margin-bottom: 14px; }
.gen-ring { position: relative; width: 112px; height: 112px; margin: 4px 0 12px; }
.gen-ring svg { width: 100%; height: 100%; transform: rotate(-90deg); }
.gen-ring circle { fill: none; stroke-width: 8; }
.gen-ring-bg { stroke: var(--surface-3); }
.gen-ring-fg { stroke: url(#genGrad); stroke-linecap: round; stroke-dasharray: 326.7; stroke-dashoffset: 326.7; transition: stroke-dashoffset 0.8s ease; }
.gen-ring b { position: absolute; inset: 0; display: grid; place-items: center; font-family: var(--font-display); font-size: 24px; font-weight: 800; }
.gen-step { font-size: 1.08rem; font-weight: 600; margin: 0 0 6px; }
.gen-tip { color: var(--muted); font-size: 0.92rem; min-height: 2.6em; transition: opacity 0.4s; margin: 0; }
.gen-tip.fade { opacity: 0; }

.job-result { display: grid; grid-template-columns: 320px 1fr; gap: 32px; }
.job-result video { width: 100%; aspect-ratio: 9 / 16; border-radius: var(--r-lg); background: #000; border: 1px solid var(--line-2); box-shadow: var(--shadow-lg); }
.result-side { display: flex; flex-direction: column; gap: 10px; min-width: 0; }
.result-side h3 { font-size: 1.45rem; letter-spacing: -0.03em; }
.result-side .label { margin-top: 8px; }
.result-actions { display: flex; gap: 10px; }
.result-actions .btn { flex: 1; padding-left: 10px; padding-right: 10px; }
.wm-note { background: var(--soft); border: 1px solid rgba(255, 77, 141, 0.2); color: var(--text-2); border-radius: var(--r-sm); padding: 10px 12px; font-size: 0.86rem; margin: 0; }
.wm-note .link { padding: 0; }
.ref-nudge { display: flex; gap: 10px; align-items: center; width: 100%; margin-top: 8px; padding: 12px 14px; border-radius: var(--r-sm); border: 1px dashed rgba(255, 77, 141, 0.45); background: rgba(255, 77, 141, 0.05); color: var(--text-2); font: inherit; font-size: 0.88rem; text-align: left; cursor: pointer; transition: background 0.15s; }
.ref-nudge:hover { background: rgba(255, 77, 141, 0.1); }
.job-error { text-align: center; padding: 28px; }
.job-error h3 { font-size: 1.3rem; }

/* Editor de escenas */
.review-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; margin-bottom: 18px; }
.review-head h3 { font-size: 1.3rem; }
.review-head p { margin: 4px 0 0; }
.review-tools { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; justify-content: flex-end; }
.chip-info { flex: 0 0 auto; background: var(--surface-3); border: 1px solid var(--line); border-radius: 99px; padding: 5px 12px; font-size: 0.8rem; font-weight: 500; color: var(--text-2); }
.critic-chip { color: var(--gold); background: rgba(245, 185, 66, 0.1); border-color: rgba(245, 185, 66, 0.25); cursor: help; }
.scenes { display: grid; grid-template-columns: repeat(auto-fill, minmax(380px, 1fr)); gap: 12px; }
.scene { display: grid; grid-template-columns: 108px 1fr; gap: 12px; background: var(--bg-2); border: 1px solid var(--line); border-radius: var(--r); padding: 10px; transition: border-color 0.15s; }
.scene:hover { border-color: var(--line-2); }
.scene-img { position: relative; aspect-ratio: 9 / 16; border-radius: var(--r-xs); overflow: hidden; background: var(--surface-3); }
.scene-img img { width: 100%; height: 100%; object-fit: cover; }
.scene-num { position: absolute; top: 6px; left: 6px; background: rgba(0, 0, 0, 0.6); color: #fff; font-weight: 700; font-size: 0.72rem; width: 22px; height: 22px; display: grid; place-items: center; border-radius: 50%; }
.scene-loading { position: absolute; inset: 0; background: rgba(12, 10, 20, 0.7); color: #fff; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px; font-size: 0.74rem; font-weight: 500; text-align: center; padding: 6px; }
.scene-loading i { width: 24px; height: 24px; border: 3px solid rgba(255, 255, 255, 0.25); border-top-color: #fff; border-radius: 50%; animation: spin 0.8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.scene-body { display: flex; flex-direction: column; gap: 8px; min-width: 0; }
.scene-row { display: flex; gap: 8px; align-items: center; justify-content: space-between; }
.scene-row select { padding: 7px 30px 7px 10px; font-size: 0.84rem; border-radius: var(--r-xs); width: auto; flex: 1; min-width: 0; background-position: right 9px center; }
.scene-body textarea { padding: 9px 11px; font-size: 0.9rem; line-height: 1.45; }
.scene-tools { display: flex; gap: 4px; }
.icon-btn { width: 32px; height: 32px; border-radius: var(--r-xs); border: 1px solid var(--line-2); background: var(--surface-2); color: var(--text); cursor: pointer; font-size: 0.88rem; transition: border-color 0.15s, background 0.15s; }
.icon-btn:hover:not(:disabled) { background: var(--surface-3); border-color: var(--line-3); }
.icon-btn:disabled { opacity: 0.35; cursor: default; }
.icon-btn.danger:hover { border-color: var(--err); }
.regen { display: flex; gap: 6px; }
.regen input { padding: 7px 10px; font-size: 0.82rem; border-radius: var(--r-xs); min-width: 0; }
.regen .btn { white-space: nowrap; }
#scenesList.locked { opacity: 1; }
#scenesList.locked::after { display: none; }
#scenesList.locked .scene-tools { display: none; }
.fx-panel { margin-top: 22px; padding-top: 4px; border-top: 1px solid var(--line); }
.fx-chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.fx { border: 1px solid var(--line-2); background: var(--bg-2); color: var(--muted); border-radius: 99px; padding: 7px 13px; font: inherit; font-size: 0.84rem; font-weight: 500; cursor: pointer; transition: all 0.15s; }
.fx:hover { color: var(--text); }
.fx.on { border-color: rgba(255, 77, 141, 0.6); background: var(--soft); color: #fff; }
.history { margin-bottom: 14px; display: flex; flex-direction: column; gap: 6px; max-height: 340px; overflow-y: auto; }
.ver { display: flex; justify-content: space-between; align-items: center; gap: 10px; border-top: 1px solid var(--line); padding: 8px 0; }
.ver div { display: flex; flex-direction: column; min-width: 0; }
.ver small { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.wm-field { margin-top: 14px; display: flex; flex-direction: column; gap: 6px; max-width: 520px; }
.wm-field .label { margin-bottom: 2px; }
.wm-field input:disabled { opacity: 0.6; }
.review-bar { position: sticky; bottom: 0; z-index: 5; display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-top: 20px; padding: 16px 0 4px; background: linear-gradient(transparent, var(--surface) 35%); }

/* ---------- Biblioteca ---------- */
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 16px; }
.vcard { display: flex; flex-direction: column; background: var(--surface); border-radius: var(--r-lg); overflow: hidden; border: 1px solid var(--line); box-shadow: var(--shadow); transition: transform 0.2s var(--ease), border-color 0.2s; }
.vcard:hover { transform: translateY(-3px); border-color: var(--line-2); }
.vthumb { position: relative; aspect-ratio: 9 / 14; background: linear-gradient(160deg, #241243, #6b1f45); display: grid; place-items: center; color: #fff; cursor: pointer; overflow: hidden; }
.vthumb img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.4s var(--ease); }
.vcard:hover .vthumb img { transform: scale(1.04); }
.vthumb::after { content: ""; position: absolute; inset: 0; background: linear-gradient(transparent 55%, rgba(0, 0, 0, 0.45)); pointer-events: none; }
.vthumb .play { position: absolute; z-index: 1; width: 46px; height: 46px; border-radius: 50%; background: rgba(0, 0, 0, 0.45); border: 1px solid rgba(255, 255, 255, 0.2); display: grid; place-items: center; font-size: 1rem; backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); transition: transform 0.2s var(--ease), background 0.2s; }
.vcard:hover .vthumb .play { transform: scale(1.08); background: rgba(255, 77, 141, 0.8); }
.vthumb .ep { position: absolute; z-index: 1; top: 10px; left: 10px; background: rgba(0, 0, 0, 0.55); backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); color: #fff; font-size: 0.7rem; font-weight: 600; padding: 3px 8px; border-radius: 6px; }
.vbody { padding: 12px; display: flex; flex-direction: column; gap: 8px; }
.vbody h4 { font-family: var(--font); font-size: 0.92rem; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; letter-spacing: -0.01em; }
.vactions { display: flex; gap: 6px; }
.vactions .btn { flex: 1; padding: 7px; font-size: 0.8rem; }
.status { font-size: 0.78rem; font-weight: 600; }
.status.failed { color: var(--err); }
.status.working, .status.queued { color: var(--accent-2); }
.status.review { color: #ffb3cf; }
.empty { text-align: center; padding: 72px 20px; color: var(--muted); border: 1px dashed var(--line-2); border-radius: var(--r-lg); }
.empty-ico { font-size: 2.6rem; margin-bottom: 4px; }

/* ---------- Guionista ---------- */
.chat { display: flex; flex-direction: column; gap: 12px; padding: 18px; max-width: 900px; }
.chat-log { display: flex; flex-direction: column; gap: 10px; min-height: 340px; max-height: 58vh; overflow-y: auto; padding: 4px; }
.msg { max-width: 82%; padding: 11px 15px; border-radius: 16px; line-height: 1.55; font-size: 0.94rem; overflow-wrap: anywhere; }
.msg.ai { align-self: flex-start; background: var(--surface-2); border: 1px solid var(--line); border-bottom-left-radius: 5px; }
.msg.me { align-self: flex-end; background: var(--grad); color: #fff; border-bottom-right-radius: 5px; }
.msg.typing { display: flex; gap: 5px; }
.msg.typing i { width: 7px; height: 7px; border-radius: 50%; background: var(--muted); animation: blink 1.2s infinite; }
.msg.typing i:nth-child(2) { animation-delay: 0.2s; }
.msg.typing i:nth-child(3) { animation-delay: 0.4s; }
@keyframes blink { 0%, 100% { opacity: 0.25; } 50% { opacity: 1; } }
.chat-suggest { display: flex; flex-wrap: wrap; gap: 8px; }
.chat-input { display: flex; gap: 8px; align-items: flex-end; }
.chat-input textarea { resize: none; max-height: 140px; }
.chat-input .btn { height: 46px; width: 50px; padding: 0; font-size: 1.05rem; }
.chat-actions { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; padding-top: 4px; border-top: 1px solid var(--line); }

/* ---------- Estudio de series ---------- */
.studio-form { display: flex; flex-direction: column; gap: 2px; max-width: 780px; }
.studio-form .label:first-child { margin-top: 0; }
.studio-form .btn { margin-top: 20px; }
.studio-row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.studio-list-title { margin: 32px 0 12px; font-size: 1.1rem; }
.project-list { display: grid; gap: 10px; max-width: 780px; }
.project-card { display: flex; align-items: center; gap: 14px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 12px 16px; cursor: pointer; transition: border-color 0.15s, background 0.15s; }
.project-card:hover { border-color: var(--line-3); background: var(--surface-2); }
.pc-info { display: flex; flex-direction: column; flex: 1; min-width: 0; }
.pc-info b { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pc-go { font-size: 1.5rem; color: var(--muted); }
.score-badge { display: flex; flex-direction: column; align-items: center; justify-content: center; min-width: 76px; height: 76px; border-radius: var(--r-lg); background: var(--surface-2); color: var(--muted); font-weight: 800; font-family: var(--font-display); }
.score-badge strong { font-size: 1.7rem; line-height: 1; }
.score-badge small { font-size: 0.7rem; font-weight: 500; font-family: var(--font); }
.score-badge.sm { min-width: 46px; height: 46px; border-radius: 12px; font-size: 1rem; }
.score-badge.great { background: rgba(52, 211, 153, 0.12); color: #34d399; }
.score-badge.good { background: rgba(56, 189, 248, 0.12); color: #38bdf8; }
.score-badge.ok { background: rgba(251, 191, 36, 0.12); color: #fbbf24; }
.score-badge.low { background: rgba(248, 113, 113, 0.12); color: #f87171; }
#projectBack { margin-bottom: 6px; }
.project-head { display: flex; justify-content: space-between; gap: 16px; align-items: flex-start; margin: 10px 0 14px; }
.project-head h3 { font-size: 1.5rem; letter-spacing: -0.03em; }
.project-head p { margin: 6px 0; }
.pv-meta { display: flex; flex-wrap: wrap; gap: 6px; }
.pv-meta span { background: var(--surface-3); border-radius: 6px; padding: 4px 10px; font-size: 0.78rem; font-weight: 500; color: var(--text-2); }
#pvProgress { margin-bottom: 14px; display: flex; flex-direction: column; gap: 10px; }
.pv-actions { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; justify-content: space-between; margin-bottom: 14px; }
.pilot-box { display: flex; gap: 8px; flex-wrap: wrap; }
.pilot-box select { width: auto; padding-top: 9px; padding-bottom: 9px; }
.pv-tabs { display: flex; gap: 8px; margin-bottom: 12px; flex-wrap: wrap; }
.pv-body h4 { margin: 20px 0 6px; }
.pv-body h4:first-child { margin-top: 0; }
.pv-body p { margin: 6px 0; line-height: 1.6; color: var(--text-2); }
.chars { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 10px; }
.char { background: var(--bg-2); border: 1px solid var(--line); border-radius: var(--r); padding: 14px; }
.char small { display: block; color: var(--muted); margin-bottom: 4px; }
.char p { font-size: 0.86rem; margin: 4px 0; }
.ep { border-top: 1px solid var(--line); padding: 12px 2px; }
.ep summary { cursor: pointer; font-size: 0.94rem; }
.ep.paywall summary { color: #ffb3cf; }
.ep .pw { background: var(--soft); color: #ffb3cf; font-size: 0.7rem; font-weight: 600; padding: 2px 8px; border-radius: 6px; margin-left: 6px; }
.ep .script { background: var(--bg-2); border: 1px solid var(--line); border-radius: var(--r-sm); padding: 12px 14px; margin-top: 10px; font-family: ui-monospace, "SF Mono", Menlo, "Courier New", monospace; font-size: 0.83rem; }
.sc { margin-bottom: 10px; }
.sc b:first-child { display: block; }
.sc i { display: block; color: var(--muted); margin: 2px 0 4px; }
.rev { display: flex; gap: 12px; align-items: flex-start; border-top: 1px solid var(--line); padding: 12px 0; }
.good-txt { color: var(--ok); font-size: 0.86rem; }
.portraits { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 12px; margin-top: 12px; }
.portrait { display: flex; flex-direction: column; align-items: center; gap: 4px; background: var(--bg-2); border: 1px solid var(--line); border-radius: var(--r); padding: 10px; text-align: center; }
.portrait img, .portrait .ph { width: 100%; aspect-ratio: 3 / 4; object-fit: cover; border-radius: var(--r-xs); background: var(--surface-3); display: grid; place-items: center; font-size: 2.4rem; }
.portrait small { color: var(--muted); font-size: 0.76rem; }

/* ---------- Agente ---------- */
.agent-card { margin-bottom: 16px; max-width: 900px; display: flex; flex-direction: column; gap: 12px; }
.agent-card > .btn { align-self: flex-start; }
.agent-suggest { display: flex; flex-wrap: wrap; gap: 8px; }
.ajob { display: grid; grid-template-columns: auto 1fr auto; gap: 12px; align-items: start; padding: 12px 14px; border: 1px solid var(--line); border-radius: var(--r-sm); background: var(--bg-2); cursor: pointer; margin-bottom: 8px; transition: border-color 0.15s; }
.ajob:hover { border-color: var(--line-3); }
.ajob input { width: auto; margin-top: 4px; accent-color: var(--accent); }
.ajob div { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.ajob small { font-size: 0.8rem; }
.ajob-cr { font-weight: 700; color: #ffb3cf; white-space: nowrap; }
.agent-run { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; padding-top: 6px; }
.qrow { display: grid; grid-template-columns: 1fr 140px 60px; gap: 10px; align-items: center; padding: 10px 0; border-top: 1px solid var(--line); font-size: 0.9rem; }
.qrow span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.qrow.done { grid-template-columns: 1fr auto; }
.qrow .bar { height: 6px; }

/* ---------- Invita ---------- */
.invite-card { max-width: 680px; display: flex; flex-direction: column; gap: 12px; }
.invite-card .label { margin-top: 0; }
.invite-link { display: flex; gap: 8px; }
.invite-link input { font-weight: 600; color: var(--accent-2); }
.invite-stats { grid-template-columns: repeat(3, 1fr) !important; margin: 4px 0 !important; }
.invite-stats .stat strong { font-size: 1.4rem; }

/* ---------- Ajustes ---------- */
.settings-card { margin-bottom: 16px; max-width: 900px; }
.settings-card .card-step { margin-bottom: 14px; }
.settings-card h4 { margin: 18px 0 8px; font-size: 0.95rem; }
.set-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 12px; margin-bottom: 14px; }
.set-grid label { display: flex; flex-direction: column; gap: 6px; font-size: 0.84rem; font-weight: 500; color: var(--text-2); }
.set-check { align-self: end; padding-bottom: 12px; color: var(--text); }
label.mini-check.set-check { flex-direction: row !important; align-items: center; justify-content: flex-start; text-align: left; white-space: normal; gap: 10px; padding: 6px 0; }
label.mini-check.set-check input { width: 18px !important; height: 18px; flex: 0 0 auto; margin: 0; }
.set-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.acct-head { display: flex; align-items: center; gap: 14px; margin: 4px 0 16px; min-width: 0; }
.acct-head > div:last-child { display: flex; flex-direction: column; min-width: 0; overflow-wrap: anywhere; }
.acct-avatar { flex: none; width: 48px; height: 48px; border-radius: 50%; background: var(--grad); display: grid; place-items: center; font-weight: 700; font-size: 20px; color: #fff; font-family: var(--font-display); }
.acct-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-bottom: 12px; }
.acct-stats > div { background: var(--bg-2); border: 1px solid var(--line); border-radius: var(--r-sm); padding: 12px; text-align: center; }
.acct-stats strong { display: block; font-family: var(--font-display); font-size: 1.4rem; font-weight: 800; }
.acct-stats span { font-size: 0.76rem; color: var(--muted); }
.acct-plan { background: var(--soft); border: 1px solid rgba(255, 77, 141, 0.2); border-radius: var(--r-sm); padding: 10px 12px; margin: 0 0 14px; font-size: 0.9rem; }
.danger-text { color: var(--err) !important; }
.danger-text:hover { border-color: rgba(248, 113, 113, 0.5) !important; }

/* ---------- Créditos ---------- */
.balance { display: flex; justify-content: space-between; align-items: center; gap: 16px; margin-bottom: 16px; flex-wrap: wrap; background: radial-gradient(500px 200px at 0% 0%, rgba(192, 76, 245, 0.16), transparent 70%), var(--surface); }
.balance > div:first-child { display: flex; flex-direction: column; }
.balance strong { font-family: var(--font-display); font-size: 2.8rem; font-weight: 800; letter-spacing: -0.04em; line-height: 1.1; background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.balance-eq { display: flex; flex-direction: column; gap: 4px; color: var(--muted); font-size: 0.9rem; }
.perks { margin: 0 0 8px; }
.perks.is-pro { border-color: rgba(245, 185, 66, 0.4); }
.perks-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 8px; margin: 14px 0 10px; }
.perk { display: flex; gap: 12px; align-items: flex-start; padding: 12px; border-radius: var(--r-sm); background: var(--bg-2); border: 1px solid var(--line); min-width: 0; }
.perk > span { display: grid; place-items: center; flex: none; width: 34px; height: 34px; border-radius: 9px; background: var(--surface-3); font-size: 17px; }
.perk b { display: block; font-size: 0.88rem; font-weight: 600; }
.perk small { display: block; color: var(--muted); font-size: 0.78rem; line-height: 1.4; }
.sub-box { display: grid; gap: 6px; margin-bottom: 12px; border-color: rgba(52, 211, 153, 0.35); }
.sub-box .btn { justify-self: start; }
.purchases { margin-top: 18px; }
.prow { display: flex; justify-content: space-between; gap: 10px; padding: 10px 2px; border-top: 1px solid var(--line); font-size: 0.9rem; }
.buy-done .buy-ico { font-size: 3rem; }
.buy-done .buy-amount { font-family: var(--font-display); font-size: 2.6rem; font-weight: 800; letter-spacing: -0.04em; margin: 4px 0 10px; background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.buy-done .btn { margin-top: 10px; }

/* ---------- Tutorial ---------- */
.tutorial { display: grid; gap: 12px; margin-bottom: 20px; max-width: 900px; }
.tut-step { display: flex; gap: 18px; align-items: flex-start; }
.tut-step .num { display: grid; place-items: center; min-width: 38px; height: 38px; border-radius: 11px; background: var(--grad); color: #fff; font-weight: 700; font-family: var(--font-display); }
.tut-step h4 { font-size: 1.05rem; }
.tut-step p { margin: 6px 0 0; color: var(--muted); }
.tut-step p b { color: var(--text-2); }
.tut-tips h4 { font-size: 1.05rem; }
.tut-tips ul { margin: 10px 0 0; padding-left: 20px; color: var(--muted); line-height: 1.8; }

/* ---------- Administrador ---------- */
.stats { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 12px; margin-bottom: 18px; }
.stats.mini { grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); margin-bottom: 4px; }
.stat { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 16px; display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.stat span { color: var(--muted); font-size: 0.82rem; font-weight: 500; }
.stat strong { font-family: var(--font-display); font-size: 1.6rem; font-weight: 800; letter-spacing: -0.03em; }
.stat small { color: var(--muted); font-size: 0.76rem; }
.admin-feats, .admin-costs { margin-bottom: 18px; }
.admin-feats .switch-row { margin: 10px 0; }
.admin-costs h4, .admin-feats h4 { margin: 20px 0 8px; font-size: 0.95rem; }
.admin-search { display: flex; gap: 8px; margin-bottom: 12px; }
.urow { display: grid; grid-template-columns: 1fr auto auto; gap: 14px; align-items: center; padding: 12px 4px; border-top: 1px solid var(--line); }
.uinfo { display: flex; flex-direction: column; min-width: 0; }
.uinfo b { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ucredits { display: flex; flex-direction: column; align-items: center; min-width: 64px; }
.ucredits strong { font-size: 1.3rem; }
.ucredits small { color: var(--muted); font-size: 0.72rem; }
.uactions { display: flex; gap: 6px; align-items: center; }
.uamount { width: 76px; padding: 7px 8px; }
.model-list { margin: 0; padding-left: 18px; color: var(--muted); line-height: 1.8; font-size: 0.9rem; }
.model-list b { color: var(--text); }
.table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--r-sm); }
.tbl { width: 100%; border-collapse: collapse; font-size: 0.86rem; }
.tbl th, .tbl td { padding: 10px 12px; text-align: left; border-bottom: 1px solid var(--line); white-space: nowrap; }
.tbl th { background: var(--surface-2); color: var(--muted); font-weight: 600; font-size: 0.74rem; text-transform: uppercase; letter-spacing: 0.05em; }
.tbl tr:last-child td { border-bottom: 0; }
.tbl tbody tr:hover td { background: rgba(255, 255, 255, 0.02); }
.margin { font-weight: 700; padding: 2px 8px; border-radius: 6px; }
.margin.great { background: rgba(52, 211, 153, 0.12); color: #34d399; }
.margin.ok { background: rgba(251, 191, 36, 0.12); color: #fbbf24; }
.margin.low { background: rgba(248, 113, 113, 0.12); color: #f87171; }
.admin-fails { margin: 16px 0; padding: 14px 16px; border: 1px solid rgba(248, 113, 113, 0.25); border-radius: var(--r); background: rgba(248, 113, 113, 0.04); }
.admin-fails h3 { margin: 0 0 8px; font-size: 15px; }
.admin-fails ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.admin-fails li { font-size: 13px; line-height: 1.4; padding-bottom: 8px; border-bottom: 1px solid var(--line); overflow-wrap: anywhere; }
.admin-fails small { opacity: 0.65; }
.disk-bar { height: 8px; border-radius: 99px; background: var(--surface-3); overflow: hidden; margin: 6px 0; }
.disk-bar i { display: block; height: 100%; background: var(--ok); }
.disk-bar.bad i { background: var(--err); }

/* ---------- Modales, tour, toast ---------- */
.modal, .tour { position: fixed; inset: 0; background: rgba(3, 3, 6, 0.7); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); display: grid; place-items: center; padding: 16px; z-index: 70; animation: fadeIn 0.18s ease-out; }
@keyframes fadeIn { from { opacity: 0; } }
.modal-box, .tour-box { position: relative; width: 100%; max-width: 420px; background: var(--surface); border: 1px solid var(--line-2); border-radius: var(--r-xl); padding: 32px; box-shadow: var(--shadow-lg); animation: popIn 0.22s var(--ease); }
@keyframes popIn { from { opacity: 0; transform: translateY(8px) scale(0.98); } }
.modal-box h3 { font-size: 1.5rem; letter-spacing: -0.03em; padding-right: 30px; }
.modal-box > p { margin: 6px 0 0; }
.modal-box form { display: flex; flex-direction: column; gap: 14px; margin-top: 20px; }
.modal-box label { display: flex; flex-direction: column; gap: 6px; font-weight: 500; font-size: 0.86rem; color: var(--text-2); }
.google-btn { margin-top: 20px; gap: 10px; padding: 12px 16px; }
.or { display: flex; align-items: center; gap: 12px; color: var(--faint); font-size: 0.8rem; margin: 18px 0 0; }
.or::before, .or::after { content: ""; flex: 1; height: 1px; background: var(--line-2); }
#forgotBtn { align-self: center; }
.legal-note { margin-top: 12px; }
.legal-note a, .foot-bottom a { color: inherit; text-decoration: underline; text-underline-offset: 2px; }
.tour-box { text-align: center; max-width: 440px; }
.tour-art { font-size: 3rem; margin-bottom: 12px; }
.tour-box h3 { font-size: 1.35rem; }
.tour-dots { display: flex; justify-content: center; gap: 6px; margin: 18px 0; }
.tour-dots i { width: 7px; height: 7px; border-radius: 99px; background: var(--surface-4); transition: all 0.2s; }
.tour-dots i.on { width: 22px; background: var(--grad); }
.tour-actions { display: flex; justify-content: space-between; align-items: center; }
.toast { position: fixed; bottom: calc(28px + env(safe-area-inset-bottom)); left: 50%; transform: translateX(-50%); background: var(--surface-3); border: 1px solid var(--line-2); color: #fff; padding: 12px 18px; border-radius: var(--r-sm); font-weight: 500; font-size: 0.92rem; z-index: 80; box-shadow: var(--shadow-lg); max-width: calc(100% - 32px); animation: toastIn 0.25s var(--ease); }
@keyframes toastIn { from { opacity: 0; transform: translate(-50%, 8px); } }

/* Menú inferior y hoja "Más" solo en teléfono */
.mnav, .mgen, .sheet { display: none; }

/* ======================================================================
   RESPONSIVE
   ====================================================================== */
@media (max-width: 1100px) {
  .feat-grid { grid-template-columns: repeat(2, 1fr); }
  .feat-wide:last-child { grid-column: auto; }
  .show-row { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .show-row .show-card:nth-child(n + 4) { display: none; }
}
@media (max-width: 1100px) and (min-width: 901px) {
  .format-opts { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 1180px) and (min-width: 901px) {
  .create-grid { grid-template-columns: 1fr; }
}

@media (max-width: 900px) {
  body { font-size: 15px; }
  html { scroll-padding-top: 70px; }
  textarea, input, select { font-size: 16px; } /* evita el zoom automático en iPhone */

  /* Portada */
  .top-links { display: none; }
  .topbar-in { padding: 12px 16px; justify-content: space-between; }
  .hero { grid-template-columns: 1fr; text-align: center; padding: 48px 16px 40px; gap: 40px; }
  .hero-text { display: flex; flex-direction: column; align-items: center; }
  .lead { margin: 0 auto; font-size: 1.05rem; }
  .hero-cta { justify-content: center; }
  .hero-trust { justify-content: center; }
  .hero-visual { height: 440px; width: 100%; }
  .hv-phone { width: 180px; }
  .hv-main { width: 214px; }
  .hv-chip-a { left: 0; top: 12%; }
  .hv-chip-b { right: 0; bottom: 10%; }
  .section { padding: 72px 16px 0; }
  .section-head { margin-bottom: 32px; }
  .steps-strip { grid-template-columns: 1fr; }
  .final-cta { padding: 80px 16px 0; }
  .foot-in { grid-template-columns: 1fr 1fr; padding: 40px 16px 24px; }
  .foot-brand { grid-column: 1 / -1; }
  .foot-bottom { padding-left: 16px; padding-right: 16px; }

  /* App: barra superior + menú inferior como app nativa */
  #app { grid-template-columns: 1fr; }
  #app::before { display: none; }
  .sidebar {
    position: sticky; top: 0; z-index: 30; height: auto; flex-direction: row; align-items: center; overflow: visible;
    padding: calc(10px + env(safe-area-inset-top)) 14px 10px; gap: 10px;
    background: rgba(7, 7, 11, 0.94); border-right: 0; border-bottom: 1px solid var(--line);
  }
  .sidebar > .brand { padding: 0; font-size: 1rem; }
  .sidebar .logo { width: 28px; height: 28px; }
  .sidebar .menu, .user-row { display: none; }
  .side-bottom { margin: 0 0 0 auto; flex-direction: row; align-items: center; gap: 8px; }
  .credit-card { flex-direction: row; align-items: center; gap: 8px; padding: 4px 4px 4px 12px; border-radius: 999px; cursor: pointer; background: var(--surface-2); }
  .cc-top .muted { display: none; }
  .cc-top .ic { width: 15px; height: 15px; }
  .credit-card strong { font-size: 1rem; margin: 0; }
  .credit-card .btn { width: auto; border-radius: 999px; padding: 6px 12px; font-size: 0.8rem; }

  .mnav {
    display: flex; position: fixed; left: 0; right: 0; bottom: 0; z-index: 40;
    background: rgba(10, 10, 15, 0.96); backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px);
    border-top: 1px solid var(--line); padding: 6px 4px calc(6px + env(safe-area-inset-bottom));
  }
  .mnav button { position: relative; flex: 1; display: flex; flex-direction: column; align-items: center; gap: 3px; background: none; border: 0; color: var(--muted); font: inherit; font-size: 0.68rem; font-weight: 600; padding: 6px 0 4px; border-radius: 12px; cursor: pointer; }
  .mnav button .ic { width: 22px; height: 22px; }
  .mnav button.active { color: var(--text); }
  .mnav button.active .ic { color: var(--accent); }
  .mnav button.active::before { content: ""; position: absolute; top: -7px; width: 28px; height: 3px; border-radius: 0 0 3px 3px; background: var(--grad); }

  .sheet { display: block; position: fixed; inset: 0; z-index: 60; background: rgba(3, 3, 6, 0.6); animation: fadeIn 0.15s; }
  .sheet[hidden] { display: none; }
  .sheet-box { position: absolute; left: 0; right: 0; bottom: 0; background: var(--surface); border-radius: 22px 22px 0 0; border-top: 1px solid var(--line-2); padding: 8px 10px calc(16px + env(safe-area-inset-bottom)); display: flex; flex-direction: column; gap: 2px; animation: up 0.22s var(--ease); }
  @keyframes up { from { transform: translateY(40px); opacity: 0; } }
  .sheet-grip { width: 38px; height: 4px; border-radius: 4px; background: var(--surface-4); margin: 4px auto 10px; }
  .sheet-box button { display: flex; align-items: center; gap: 14px; text-align: left; background: none; border: 0; color: var(--text); font: inherit; padding: 11px 12px; border-radius: var(--r); cursor: pointer; }
  .sheet-box button:active { background: var(--surface-2); }
  .sheet-box button > span { display: grid; place-items: center; width: 40px; height: 40px; border-radius: 11px; background: var(--surface-3); color: var(--accent-2); flex: none; }
  .sheet-box button > span .ic { width: 20px; height: 20px; }
  .sheet-box button div { display: flex; flex-direction: column; }
  .sheet-box b { font-weight: 600; font-size: 0.95rem; }
  .sheet-box small { color: var(--muted); font-size: 0.8rem; }

  /* Barra fija "Generar" encima del menú (solo en Crear con el formulario visible) */
  body[data-tab="create"] .mgen { display: block; position: fixed; left: 0; right: 0; bottom: calc(64px + env(safe-area-inset-bottom)); z-index: 35; padding: 14px 14px 10px; background: linear-gradient(transparent, rgba(7, 7, 11, 0.97) 40%); box-sizing: border-box; }
  body[data-tab="create"]:has(#createForm[hidden]) .mgen { display: none; }
  .generate-card #generateBtn { display: none; }

  .main { padding: 18px 14px calc(150px + env(safe-area-inset-bottom)); }
  .panel-head { margin-bottom: 16px; }
  .panel-head h2 { font-size: 1.4rem; }
  .panel-head p { font-size: 0.9rem; }
  .card { padding: 18px; border-radius: var(--r); }
  .create-grid { grid-template-columns: 1fr; gap: 12px; }
  .generate-card { grid-template-columns: 1fr; }
  .generate-card .btn { grid-column: 1; grid-row: auto; min-width: 0; width: 100%; }
  .format-opts { grid-template-columns: 1fr 1fr; }
  .label { margin: 16px 0 7px; }
  .options { gap: 6px; }
  .opt { padding: 8px 11px; font-size: 0.85rem; }
  .style-opt { padding: 5px; font-size: 0.7rem; }
  .style-opt .sw { aspect-ratio: 3 / 4; }
  .seg button { padding: 8px 4px; font-size: 0.84rem; }
  .seg.dur button { font-size: 0.8rem; }
  .job-card { padding: 20px; }
  .job-steps { grid-template-columns: 1fr 1fr; }
  .job-result { grid-template-columns: 1fr; }
  .job-result video { max-width: 320px; margin: 0 auto; }
  .grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .toast { bottom: calc(140px + env(safe-area-inset-bottom)); }
  .review-bar { bottom: calc(64px + env(safe-area-inset-bottom)); }
  .modal { align-items: end; padding: 0; }
  .modal-box { border-radius: 24px 24px 0 0; padding: 28px 22px calc(28px + env(safe-area-inset-bottom)); max-width: none; animation: up 0.25s var(--ease); }
  .qbadge { position: absolute; top: 2px; left: 50%; margin: 0 0 0 6px; }
  .qrow { grid-template-columns: 1fr 80px 44px; }
}

@media (max-width: 700px) {
  .show-row { display: flex; overflow-x: auto; scroll-snap-type: x mandatory; gap: 12px; margin: 0 -16px; padding: 0 16px 8px; scrollbar-width: none; }
  .show-row::-webkit-scrollbar { display: none; }
  .show-row .show-card:nth-child(n + 4) { display: block; }
  .show-card { flex: 0 0 64%; scroll-snap-align: center; }
  .feat-grid { grid-template-columns: 1fr; }
  .feat-wide { grid-column: auto; }
  .motion-opts { grid-template-columns: 1fr 1fr; gap: 8px; }
  .motion-opt { padding: 11px; }
  .motion-opt small { font-size: 0.72rem; }
  .motion-opt .m-badge { top: 9px; right: 9px; font-size: 0.56rem; }
  .urow { grid-template-columns: 1fr auto; }
  .uactions { grid-column: 1 / -1; flex-wrap: wrap; }
}

@media (max-width: 640px) {
  .gen-stage { grid-template-columns: 1fr; justify-items: center; text-align: center; gap: 18px; }
  .gen-phone { width: 168px; }
  .gen-ring { margin: 4px auto 10px; }
  .stats, .stats.mini { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
  .stat { padding: 12px; }
  .stat strong { font-size: 1.25rem; overflow-wrap: anywhere; }
  .stat span { font-size: 0.75rem; }
  .stat small { font-size: 0.7rem; }
  .card-step { flex-wrap: wrap; row-gap: 2px; }
  .card-step small { flex-basis: 100%; }
  /* Tablas → tarjetas apiladas */
  .table-wrap { border: 0; overflow: visible; }
  .tbl thead { display: none; }
  .tbl, .tbl tbody, .tbl tr, .tbl td { display: block; width: 100%; }
  .tbl tr { border: 1px solid var(--line); border-radius: var(--r-sm); padding: 8px 12px; margin-bottom: 8px; background: var(--surface); }
  .tbl td { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; padding: 3px 0 !important; border: 0 !important; text-align: right; font-size: 13px; overflow-wrap: anywhere; white-space: normal; }
  .tbl td::before { content: attr(data-label); color: var(--muted); text-align: left; flex: 0 0 auto; font-size: 12px; }
  .tbl td:first-child { font-weight: 600; text-align: left; justify-content: flex-start; font-size: 14px; }
  .tbl td:first-child::before, .tbl td[colspan]::before { display: none; }
  .tbl td[colspan] { justify-content: center; }
  .urow { flex-wrap: wrap; gap: 8px; }
  .uactions { flex-wrap: wrap; width: 100%; }
}

@media (max-width: 600px) {
  .studio-row { grid-template-columns: 1fr; }
  .project-head { flex-direction: column-reverse; }
  .pv-actions .btn, .pilot-box, .pilot-box .btn { width: 100%; }
  .pilot-box select { flex: 1; }
  .perks-grid { grid-template-columns: 1fr; gap: 6px; }
  .perk { padding: 10px; }
}

@media (max-width: 520px) {
  .top-actions { gap: 6px; }
  .top-actions .btn { padding: 8px 12px; font-size: 0.85rem; }
  .topbar .brand span { font-size: 0.98rem; }
  .hero h1 { font-size: 2.3rem; }
  .hero-cta { flex-direction: column; width: 100%; }
  .hero-cta .btn { width: 100%; }
  .hero-visual { height: 380px; }
  .hv-phone { width: 150px; }
  .hv-main { width: 190px; }
  .hv-left { transform: translateX(-52%) rotate(-7deg) scale(0.86); }
  .hv-right { transform: translateX(52%) rotate(7deg) scale(0.86); }
  .hv-chip { padding: 8px 10px 8px 8px; }
  .hv-chip .ic { width: 28px; height: 28px; padding: 6px; }
  .hv-chip small { display: none; }
  .pipeline li { padding: 7px 12px; font-size: 0.84rem; }
  .final-in { padding: 52px 20px; }
  .options.styles { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .row2 { grid-template-columns: 1fr; }
  .msg { max-width: 92%; }
  .chat-log { max-height: 55vh; }
  .scenes { grid-template-columns: 1fr; }
  .scene { grid-template-columns: 92px 1fr; }
  .regen { flex-direction: column; }
  .review-head { flex-direction: column; }
  .review-bar { padding: 10px 0 6px; }
  .review-bar .btn { flex: 1; white-space: nowrap; padding: 13px 16px; font-size: 1rem; }
  .review-bar #saveState { display: none; }
  .scene-row { flex-wrap: wrap; }
  .scene-row select.sp { flex-basis: 100%; }
  .scene-tools { margin-left: auto; }
  .invite-stats .stat { padding: 10px; }
  .invite-stats .stat span { font-size: 0.72rem; }
  .acct-stats strong { font-size: 1.15rem; }
}
@media (max-width: 380px) {
  .options.styles { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .hv-left, .hv-right { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; scroll-behavior: auto !important; }
}

/* Administradores */
.admin-list { margin-bottom: 18px; }
.admin-list > p { margin: 12px 0 0; }
.arow { display: flex; align-items: center; gap: 12px; padding: 12px 4px; border-top: 1px solid var(--line); }
.arow .uinfo { flex: 1; }
.acct-avatar.sm { width: 36px; height: 36px; font-size: 15px; }
.tag-admin { flex: none; display: inline-block; vertical-align: middle; font-family: var(--font); font-size: 0.64rem; font-weight: 700; letter-spacing: 0.06em; padding: 3px 7px; border-radius: 6px; color: var(--gold); background: rgba(245, 185, 66, 0.12); border: 1px solid rgba(245, 185, 66, 0.3); }
.tag-you { display: inline-block; vertical-align: middle; font-size: 0.66rem; font-weight: 600; padding: 2px 7px; border-radius: 6px; color: var(--accent-2); background: rgba(167, 139, 250, 0.12); margin-left: 4px; }

/* Tus personajes */
.cast-box { margin-top: 4px; }
.cast-row { display: flex; flex-wrap: wrap; gap: 8px; }
.cast-chip, .cast-add {
  position: relative; display: inline-flex; align-items: center; gap: 8px; height: 44px; padding: 4px 12px 4px 4px;
  border-radius: 999px; border: 1px solid var(--line-2); background: var(--bg-2); color: var(--text-2);
  font: inherit; font-size: 0.88rem; font-weight: 500; cursor: pointer; transition: border-color 0.15s, background 0.15s;
}
.cast-chip img { width: 34px; height: 34px; border-radius: 50%; object-fit: cover; }
.cast-chip:hover, .cast-add:hover { border-color: var(--line-3); color: var(--text); }
.cast-chip.on { border-color: rgba(255, 77, 141, 0.7); background: var(--soft); color: #fff; box-shadow: var(--ring); }
.cast-chip.on img { box-shadow: 0 0 0 2px var(--accent); }
.cast-del { display: grid; place-items: center; width: 18px; height: 18px; margin-left: 2px; border-radius: 50%; font-style: normal; font-size: 0.85rem; line-height: 1; color: var(--muted); background: var(--surface-3); }
.cast-del:hover { color: #fff; background: var(--err); }
.cast-add { padding: 4px 16px 4px 4px; border-style: dashed; color: var(--muted); }
.cast-add span { display: grid; place-items: center; width: 34px; height: 34px; border-radius: 50%; background: var(--surface-3); font-size: 1.2rem; color: var(--accent-2); }
.cast-hint { margin: 8px 0 0; }
.cast-drop { display: grid !important; place-items: center; height: 220px; border: 1.5px dashed var(--line-3); border-radius: var(--r); background: var(--bg-2); cursor: pointer; overflow: hidden; }
.cast-drop:hover { border-color: var(--accent); }
.cast-drop img { width: 100%; height: 100%; object-fit: contain; }
.cast-drop span { display: flex; flex-direction: column; align-items: center; gap: 4px; text-align: center; color: var(--text); }
.cast-drop small { color: var(--muted); font-weight: 400; }
label.mini-check.cast-consent { flex-direction: row; align-items: flex-start; white-space: normal; gap: 10px; color: var(--text-2); font-weight: 400; font-size: 0.84rem; }
label.mini-check.cast-consent input { margin-top: 3px; flex: none; }

/* Tour: primer paso con video real */
.tour-art.has-video { width: 168px; aspect-ratio: 9 / 16; margin: 0 auto 16px; border-radius: 18px; overflow: hidden; border: 1px solid var(--line-2); box-shadow: 0 20px 50px -12px rgba(139, 92, 246, 0.5); font-size: 0; }
.tour-art.has-video video { width: 100%; height: 100%; object-fit: cover; display: block; }

/* Ayuda */
.help-fab {
  position: fixed; right: 22px; bottom: 22px; z-index: 45; display: inline-flex; align-items: center; gap: 8px;
  padding: 11px 16px 11px 12px; border-radius: 999px; border: 1px solid var(--line-2); background: rgba(22, 22, 31, 0.92);
  backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); color: var(--text); font: inherit; font-size: 0.88rem; font-weight: 600;
  cursor: pointer; box-shadow: var(--shadow-lg); transition: border-color 0.15s, transform 0.15s var(--ease);
}
.help-fab:hover { border-color: var(--line-3); transform: translateY(-1px); }
.help-fab .ic { width: 20px; height: 20px; color: var(--accent-2); }
.help-quick { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 14px; }
.help-quick .chip { font-size: 0.8rem; padding: 6px 11px; }
#helpForm { margin-top: 14px; }
@media (max-width: 900px) {
  .help-fab { display: none; }
}

/* Panel: gráfico diario */
.admin-chart { margin-bottom: 18px; }
.chart-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; }
.chart-head .card-step { margin: 0; }
.chart-seg button { padding: 6px 12px; font-size: 0.82rem; }
.chart-total { margin: 14px 0 10px; font-size: 0.95rem; }
.chart-total b { font-family: var(--font-display); font-size: 1.5rem; margin-right: 4px; }
.chart { display: flex; align-items: flex-end; gap: 4px; height: 170px; padding-top: 6px; border-bottom: 1px solid var(--line-2); }
.bar-col { flex: 1; min-width: 0; height: 100%; display: flex; flex-direction: column; justify-content: flex-end; align-items: center; gap: 4px; }
.bar-col i { display: block; width: 100%; max-width: 22px; border-radius: 4px 4px 0 0; background: var(--grad); opacity: 0.85; transition: opacity 0.15s; }
.bar-col:hover i { opacity: 1; }
.bar-col small { font-size: 0.62rem; color: var(--faint); }
@media (max-width: 640px) {
  .bar-col small { display: none; }
  .bar-col:nth-child(5n + 1) small { display: block; }
  .chart { gap: 2px; height: 140px; }
}

/* Conservación (plan gratis) */
.keep-note { margin: -8px 0 18px; padding: 10px 14px; border-radius: var(--r-sm); border: 1px solid var(--line-2); background: var(--surface); color: var(--text-2); font-size: 0.88rem; }
.keep-note .link { padding: 0; }
.expiry { font-size: 0.74rem; color: var(--muted); }
.expiry.soon { color: var(--warn); font-weight: 600; }

/* Calendario de publicación (Agente) */
.agent-cal .label { margin-top: 4px; }
.publish-at { font-size: 0.74rem; color: var(--accent-2); font-weight: 500; }

/* Resultado en el teléfono: video más bajo para ver Descargar/Compartir sin bajar tanto */
@media (max-width: 900px) {
  .job-result video { max-height: 58vh; width: auto; max-width: 100%; display: block; }
  .job-result { gap: 18px; }
}

/* Confirmaciones */
#askModal { z-index: 90; }
.ask-box { max-width: 400px; }
.ask-box h3 { padding-right: 0; font-size: 1.25rem; }
.ask-box p { margin: 10px 0 0; line-height: 1.55; }
.ask-box input { margin-top: 14px; text-transform: uppercase; letter-spacing: 0.08em; font-weight: 600; }
.ask-actions { display: flex; justify-content: flex-end; gap: 10px; margin-top: 22px; }
.btn.danger { background: #dc2626; color: #fff; box-shadow: 0 8px 24px -10px rgba(220, 38, 38, 0.7); }
.btn.danger:hover:not(:disabled) { background: #ef4444; }
@media (max-width: 900px) {
  .ask-actions { flex-direction: column-reverse; }
  .ask-actions .btn { width: 100%; padding: 13px; }
}

/* Editor: la etiqueta larga baja de línea en vez de salirse de la pantalla */
.review-tools .chip-info { white-space: normal; flex: 0 1 auto; min-width: 0; max-width: 100%; line-height: 1.4; }
.panel-head p:empty { display: none; }
@media (max-width: 900px) {
  .review-tools { justify-content: flex-start; width: 100%; }
}

/* Funciones: etiqueta "Nuevo" */
.feat-new { border-color: rgba(255, 77, 141, 0.3); background: radial-gradient(320px 180px at 100% 0%, rgba(255, 77, 141, 0.12), transparent 70%), linear-gradient(180deg, rgba(255, 77, 141, 0.05), rgba(255, 255, 255, 0.01)); }
.feat-badge { position: absolute; top: 18px; right: 18px; font-size: 0.68rem; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; padding: 3px 8px; border-radius: 6px; color: #fff; background: var(--grad); }

/* Plan Productora */
.pack.premium { border: 1px solid rgba(245, 185, 66, 0.55); background: radial-gradient(420px 220px at 100% 0%, rgba(245, 185, 66, 0.12), transparent 70%), var(--surface); box-shadow: 0 24px 60px -24px rgba(245, 185, 66, 0.35); }
.pack.premium .tag { background: linear-gradient(120deg, #f5b942, #f97316); }
.pack li.perk-plus { color: var(--text); font-weight: 500; }
.pack li.perk-plus::before { background: rgba(245, 185, 66, 0.16) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%23f5b942'%3E%3Cpath d='m12 2 3.09 6.26L22 9.27l-5 4.87 1.18 6.88L12 17.77l-6.18 3.25L7 14.14 2 9.27l6.91-1.01L12 2z'/%3E%3C/svg%3E") center / 10px no-repeat; }
.pricing .packs.plans { max-width: 1100px; }

/* Agente: cada video del plan se puede ajustar */
.ajob { cursor: default; align-items: start; }
.ajob.off { opacity: 0.5; }
.ajob > input { margin-top: 5px; cursor: pointer; }
.ajob-main { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.ajob-main small.muted { overflow-wrap: anywhere; }
.ajob-opts { display: flex; flex-wrap: wrap; gap: 8px 14px; margin-top: 6px; }
.ajob-opts label { display: flex; align-items: center; gap: 6px; font-size: 0.8rem; color: var(--muted); }
.ajob-opts select { width: auto; padding: 6px 30px 6px 10px; font-size: 0.84rem; border-radius: var(--r-xs); background-position: right 9px center; }
@media (max-width: 520px) {
  .ajob-opts { flex-direction: column; align-items: stretch; }
  .ajob-opts label { justify-content: space-between; }
  .ajob-opts select { flex: 1; max-width: 62%; }
}

/* Plan Élite: logo */
.logo-box { display: flex; gap: 16px; align-items: center; margin: 4px 0 16px; padding: 14px; border: 1px solid var(--line); border-radius: var(--r); background: var(--bg-2); }
.logo-prev { flex: none; width: 96px; height: 96px; border-radius: var(--r-sm); display: grid; place-items: center; overflow: hidden;
  background: repeating-conic-gradient(#2a2a35 0% 25%, #1c1c25 0% 50%) 50% / 16px 16px; color: var(--faint); font-size: 0.75rem; }
.logo-prev img { max-width: 86%; max-height: 86%; object-fit: contain; }
.logo-info { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.logo-info .set-actions { margin-top: 4px; }
.logo-box.locked-elite .logo-prev { opacity: 0.5; }
.tag-elite { display: inline-block; vertical-align: middle; font-size: 0.64rem; font-weight: 700; letter-spacing: 0.05em; padding: 2px 7px; border-radius: 6px; color: #1a1205; background: linear-gradient(120deg, #f5b942, #f97316); margin-left: 4px; }

/* Voz clonada */
.voice-prev { background: var(--grad-soft); color: #ffb3cf; border: 1px solid rgba(255, 77, 141, 0.25); }
.voice-prev .ic { width: 34px; height: 34px; }
.voice-box audio { width: 100%; max-width: 360px; height: 36px; margin-top: 4px; }
.voice-box.locked-elite .voice-prev { opacity: 0.5; }
.btn.busy { opacity: 0.7; pointer-events: none; }
.myvoice-row select { max-width: 320px; }

/* Minutos destacados en cada plan */
.pack .mins { display: inline-flex; align-self: flex-start; gap: 4px; margin: 2px 0 2px; padding: 4px 10px; border-radius: 999px; font-size: 0.82rem; color: var(--text-2); background: rgba(52, 211, 153, 0.1); border: 1px solid rgba(52, 211, 153, 0.25); }
.pack .mins b { color: #6ee7b7; }

/* Modo: tengo mi guion / solo tengo una idea */
.mode-seg { margin: 14px 0 4px; }
.mode-seg button { padding: 9px 6px; }
.mode-seg button small { font-weight: 500; }

/* ===== Portada: probar con una idea, prueba social y selector de precios ===== */
.hero-try { margin-top: 30px; width: 100%; max-width: 580px; }
.ht-formats { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 10px; }
.ht-formats button {
  font: inherit; font-size: 0.86rem; font-weight: 600; padding: 7px 13px; border-radius: 999px; cursor: pointer;
  border: 1px solid var(--line-2); background: rgba(255, 255, 255, 0.03); color: var(--text-2); transition: 0.15s;
}
.ht-formats button.on { border-color: var(--accent); color: #fff; background: rgba(255, 77, 141, 0.14); }
.ht-box {
  display: flex; gap: 8px; padding: 6px; border-radius: 16px; border: 1px solid var(--line-2); background: var(--surface);
  box-shadow: 0 20px 60px -24px rgba(139, 92, 246, 0.5);
}
.ht-box:focus-within { border-color: var(--accent); }
.ht-box input { flex: 1; min-width: 0; background: transparent; border: 0; outline: 0; color: var(--text); font: inherit; font-size: 1rem; padding: 10px 12px; }
.ht-box .btn { white-space: nowrap; }
.hero-try small { display: block; margin-top: 9px; font-size: 0.84rem; }
.hero-try + .hero-cta { margin-top: 18px; }
.proof {
  max-width: 760px; margin: 34px auto 0; padding: 18px 22px; border-radius: var(--r-lg); border: 1px solid var(--line-2);
  background: var(--surface); display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap;
}
.proof p { margin: 0; color: var(--text-2); flex: 1 1 320px; }
.price-switch { display: flex; flex-direction: column; align-items: center; gap: 10px; margin: 8px 0 28px; }
.price-switch .seg { display: inline-flex; padding: 4px; border-radius: 999px; border: 1px solid var(--line-2); background: var(--surface); }
.price-switch .seg button {
  font: inherit; font-weight: 700; padding: 9px 20px; border-radius: 999px; border: 0; cursor: pointer; background: transparent; color: var(--muted);
}
.price-switch .seg button.on { background: var(--grad); color: #fff; }
.price-switch .seg small { font-weight: 600; opacity: 0.85; margin-left: 4px; }
.price-switch .seg button { white-space: nowrap; }
.price-switch p { margin: 0; }

@media (max-width: 900px) {
  /* En móvil: un video ya en la primera pantalla, justo después del título. */
  .hero { display: flex; flex-direction: column; align-items: center; gap: 0; padding-top: 30px; }
  .hero-text { display: contents; }
  .hero .eyebrow { order: 1; }
  .hero h1 { order: 2; margin: 16px 0 14px; }
  .hero-visual { order: 3; height: 340px; margin: 0 0 18px; }
  .hv-phone { width: 140px; }
  .hv-main { width: 176px; }
  .lead { order: 4; }
  .hero-try { order: 5; }
  .hero-cta { order: 6; }
  .hero-trust { order: 7; }
  .ht-formats { justify-content: center; }
}
@media (max-width: 520px) {
  .hero h1 { font-size: 2.1rem; }
  .hero-visual { height: 300px; }
  .hv-main { width: 160px; }
  .hv-phone { width: 128px; }
  .hero .lead { display: none; }
  .ht-formats { gap: 6px; flex-wrap: nowrap; }
  .ht-formats button { font-size: 0.78rem; padding: 6px 10px; }
  .hv-badge { display: none; }
  .hero-visual { height: 290px; margin-bottom: 8px; }
  .ht-box { flex-direction: column; }
  .ht-box .btn { width: 100%; }
  .ht-box input { text-align: center; }
  .proof { text-align: center; justify-content: center; }
  .proof .btn { width: 100%; }
  .price-switch .seg button { padding: 9px 16px; }
  .price-switch .seg small { display: none; }
}

/* ===== Dame ideas ===== */
.chip-ideas { border-color: var(--accent); color: #fff; background: rgba(255, 77, 141, 0.12); }
.ideas-box { max-width: 560px; width: 100%; max-height: 88vh; overflow-y: auto; }
.ideas-filter { display: flex; gap: 8px; margin: 14px 0; flex-wrap: wrap; }
.ideas-filter select, .ideas-filter input {
  flex: 1 1 160px; min-width: 0; background: var(--surface-2); color: var(--text); border: 1px solid var(--line-2);
  border-radius: var(--r-sm); padding: 10px 12px; font: inherit;
}
.ideas-list { display: flex; flex-direction: column; gap: 10px; margin-bottom: 14px; }
.idea-card {
  text-align: left; font: inherit; color: var(--text); cursor: pointer; display: flex; flex-direction: column; gap: 5px;
  padding: 14px 16px; border-radius: var(--r); border: 1px solid var(--line-2); background: var(--surface-2); transition: 0.15s;
}
.idea-card:hover { border-color: var(--accent); transform: translateY(-1px); }
.idea-card b { font-size: 1.02rem; }
.idea-card em { color: var(--accent); font-style: normal; font-size: 0.9rem; }
.idea-card p { margin: 0; color: var(--text-2); font-size: 0.9rem; line-height: 1.45; }
.idea-genre { font-size: 0.74rem; color: var(--muted); }
.idea-use { font-size: 0.82rem; font-weight: 700; color: var(--accent); margin-top: 2px; }
.idea-card.skeleton { height: 112px; cursor: default; background: linear-gradient(90deg, var(--surface-2), var(--surface-3), var(--surface-2)); background-size: 200% 100%; animation: ideasShimmer 1.2s linear infinite; }
@keyframes ideasShimmer { to { background-position: -200% 0; } }

/* ===== Alargar con IA ===== */
.extend-row { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin-top: 10px; font-size: 0.86rem; color: var(--text-2); }
.extend-row .chip { padding: 5px 11px; font-size: 0.82rem; }
.extend-row .chip:disabled { opacity: 0.6; cursor: wait; }

/* ===== Avisos del administrador ===== */
.admin-alerts .card-step { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.admin-alerts .card-step .btn { margin-left: auto; }
.alert-row { display: flex; gap: 10px; align-items: flex-start; padding: 12px 0; border-top: 1px solid var(--line); }
.alert-row:first-child { border-top: 0; }
.alert-row > div { flex: 1; min-width: 0; }
.alert-row pre { white-space: pre-wrap; word-break: break-word; font: inherit; font-size: 0.84rem; color: var(--text-2); margin: 6px 0 0; }
.alert-row.seen { opacity: 0.5; }
.alert-row.lvl-error:not(.seen) b { color: #ff7a8a; }
.alert-ico { font-size: 0.9rem; line-height: 1.6; }
.alert-badge {
  display: inline-grid; place-items: center; min-width: 18px; height: 18px; padding: 0 5px; margin-left: 6px; border-radius: 999px;
  background: #ef4444; color: #fff; font-size: 0.7rem; font-weight: 800; vertical-align: middle;
}
.btn.sm { padding: 6px 12px; font-size: 0.8rem; }

/* ===== Película: modo Short o Película ===== */
.cine-row { margin-top: 14px; }
.cine-row .seg button small { display: block; font-size: 0.72rem; opacity: 0.8; }
.cine-row p { margin: 8px 0 0; }
