/* Setsu — "command deck" theme: deep space, neon, glass. Loaded after app.css (it only adds and overrides).
   Every animation stops for people who ask for less motion (prefers-reduced-motion, at the end). */

/* ---------------------------------------------------------------- space background */
html { background: var(--ink); }
body { background: transparent; position: relative; isolation: isolate; font-family: var(--sans); }
body::before {
  content: ""; position: fixed; inset: -50%; z-index: -2; pointer-events: none;
  background-image:
    radial-gradient(1.2px 1.2px at 20px 30px, rgba(255, 255, 255, 0.9), transparent 60%),
    radial-gradient(1px 1px at 120px 80px, rgba(180, 220, 255, 0.8), transparent 60%),
    radial-gradient(1.4px 1.4px at 200px 160px, rgba(255, 200, 240, 0.85), transparent 60%),
    radial-gradient(1px 1px at 60px 200px, rgba(255, 255, 255, 0.7), transparent 60%),
    radial-gradient(1.6px 1.6px at 280px 40px, rgba(140, 240, 255, 0.9), transparent 60%),
    radial-gradient(1px 1px at 330px 250px, rgba(255, 255, 255, 0.6), transparent 60%);
  background-size: 360px 300px;
  animation: deriva 160s linear infinite;
  opacity: 0.75;
}
body::after {
  content: ""; position: fixed; inset: 0; z-index: -1; pointer-events: none;
  background:
    radial-gradient(60vw 50vh at 8% -10%, rgba(139, 92, 246, 0.28), transparent 60%),
    radial-gradient(55vw 45vh at 105% 10%, rgba(34, 225, 255, 0.18), transparent 60%),
    radial-gradient(70vw 60vh at 60% 115%, rgba(255, 61, 129, 0.18), transparent 60%),
    linear-gradient(rgba(140, 155, 255, 0.045) 1px, transparent 1px) 0 0 / 100% 64px,
    linear-gradient(90deg, rgba(140, 155, 255, 0.045) 1px, transparent 1px) 0 0 / 64px 100%;
  -webkit-mask-image: linear-gradient(180deg, #000 0%, rgba(0, 0, 0, 0.55) 60%, rgba(0, 0, 0, 0.9) 100%);
          mask-image: linear-gradient(180deg, #000 0%, rgba(0, 0, 0, 0.55) 60%, rgba(0, 0, 0, 0.9) 100%);
}
@keyframes deriva { from { transform: translate3d(0, 0, 0); } to { transform: translate3d(-360px, -300px, 0); } }

::selection { background: var(--cyan); color: var(--ink); }

/* ---------------------------------------------------------------- type */
.hud { font-family: var(--hud); font-weight: 700; letter-spacing: 0.14em; text-transform: uppercase; font-size: 11px; color: var(--cyan); }
.glow-text { background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.word { font: 800 19px/1 var(--hud); letter-spacing: 0.22em; text-transform: uppercase; }
.seal {
  background: var(--grad); color: #fff; border-radius: 9px; transform: rotate(-6deg);
  box-shadow: 0 0 22px rgba(139, 92, 246, 0.65), inset 0 0 0 1px rgba(255, 255, 255, 0.35);
  text-shadow: 0 1px 6px rgba(0, 0, 0, 0.35);
}
.seal-ghost { background: var(--ink-3); box-shadow: none; color: var(--faint); }
.intake h1, .page-title, .auth-card h1, .job-head h1 { font-family: var(--serif); font-weight: 700; letter-spacing: -0.03em; }
.intake h1 em, .auth-card h1 em, .page-title em {
  font-style: normal; background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent;
}

/* ---------------------------------------------------------------- top bar */
.topbar {
  background: rgba(6, 7, 20, 0.6); border-bottom: 1px solid transparent;
  border-image: linear-gradient(90deg, transparent, rgba(34, 225, 255, 0.55), rgba(139, 92, 246, 0.55), rgba(255, 61, 129, 0.55), transparent) 1;
}
.tabs a { position: relative; transition: color 0.2s, background 0.2s, box-shadow 0.2s; }
.tabs a.on {
  background: linear-gradient(180deg, rgba(139, 92, 246, 0.28), rgba(34, 225, 255, 0.12));
  color: #fff; box-shadow: inset 0 0 0 1px rgba(140, 155, 255, 0.35), 0 0 18px rgba(139, 92, 246, 0.35);
}
.tabs .tab-live { display: inline-flex; align-items: center; gap: 7px; }
.tabs .tab-live i {
  width: 7px; height: 7px; border-radius: 50%; background: #ff2e63; box-shadow: 0 0 10px #ff2e63; animation: latido 1.6s ease-in-out infinite;
}
.tabs .tab-live b { font: 700 10.5px/1 var(--hud); color: #ff8fb0; letter-spacing: 0.06em; }

/* ---------------------------------------------------------------- buttons and fields */
.btn {
  position: relative; overflow: hidden; background: var(--grad); color: #fff; font-weight: 600; letter-spacing: 0.01em;
  box-shadow: 0 8px 26px -10px rgba(139, 92, 246, 0.85), inset 0 0 0 1px rgba(255, 255, 255, 0.22);
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.25);
}
.btn::after {
  content: ""; position: absolute; inset: 0; transform: translateX(-120%);
  background: linear-gradient(100deg, transparent 30%, rgba(255, 255, 255, 0.35) 50%, transparent 70%);
  transition: transform 0.7s;
}
.btn:hover { background: var(--grad); filter: brightness(1.12); box-shadow: 0 12px 34px -10px rgba(34, 225, 255, 0.9), inset 0 0 0 1px rgba(255, 255, 255, 0.3); }
.btn:hover::after { transform: translateX(120%); }
.btn-ghost {
  background: rgba(20, 24, 56, 0.55); color: var(--paper); box-shadow: inset 0 0 0 1px var(--line-2); text-shadow: none;
}
.btn-ghost:hover { background: rgba(34, 225, 255, 0.1); box-shadow: inset 0 0 0 1px rgba(34, 225, 255, 0.6), 0 0 22px rgba(34, 225, 255, 0.25); filter: none; }
.btn-live { background: linear-gradient(120deg, #ff2e63, #ff7a1a); box-shadow: 0 8px 26px -8px rgba(255, 46, 99, 0.9), inset 0 0 0 1px rgba(255, 255, 255, 0.25); }
.btn-live:hover { background: linear-gradient(120deg, #ff2e63, #ff7a1a); }
input[type="email"], input[type="password"], input[type="url"], input[type="search"], input[type="text"], input[type="number"], select, textarea {
  background: rgba(10, 12, 32, 0.7); border-color: var(--line-2); color: var(--paper);
}
input:focus, select:focus, textarea:focus {
  border-color: var(--cyan) !important; background: rgba(14, 18, 46, 0.85) !important;
  box-shadow: 0 0 0 4px rgba(34, 225, 255, 0.14), 0 0 26px rgba(34, 225, 255, 0.2);
}
textarea {
  width: 100%; min-height: 96px; padding: 12px 16px; border-radius: 12px; border: 1px solid var(--line-2);
  font: 400 14.5px/1.5 var(--sans); resize: vertical; outline: none;
}

/* ---------------------------------------------------------------- glass panels (existing pieces) */
.usage, .job, .clip, .plan, .pack, .admin-card, .stat, .live-panel, .twofa, .auth-card {
  background: var(--glass); border: 1px solid var(--line); box-shadow: var(--glow);
  backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
}
.auth-card { padding: 36px 32px; border-radius: 22px; }
.usage { border-radius: 18px; }
.job { border-radius: 16px; transition: transform 0.25s, box-shadow 0.25s, border-color 0.25s; }
.job:hover { transform: translateY(-2px); border-color: rgba(34, 225, 255, 0.45); box-shadow: 0 0 0 1px rgba(34, 225, 255, 0.25), 0 18px 50px -18px rgba(34, 225, 255, 0.45); }
.clip { border-radius: 18px; overflow: hidden; transition: transform 0.25s, box-shadow 0.25s; }
.clip:hover { transform: translateY(-3px); box-shadow: 0 0 0 1px rgba(139, 92, 246, 0.4), 0 22px 60px -20px rgba(139, 92, 246, 0.6); }
.plan-featured { border-color: rgba(139, 92, 246, 0.7); box-shadow: 0 0 0 1px rgba(139, 92, 246, 0.6), 0 20px 70px -20px rgba(139, 92, 246, 0.8); }
.meter, .bar { background: rgba(140, 155, 255, 0.12); }
.meter i, .bar i { background: var(--grad); box-shadow: 0 0 14px rgba(34, 225, 255, 0.6); }
.pill-live, .live-badge { color: #ff8fb0; }
.pill-done { color: var(--ok); }
.notice-ok { border-color: rgba(61, 255, 168, 0.45); }
.app-foot { border-top-color: var(--line); }

/* ---------------------------------------------------------------- shared bits */
.chip {
  display: inline-flex; align-items: center; gap: 6px; height: 24px; padding: 0 10px; border-radius: 999px;
  font: 600 11.5px/1 var(--sans); background: rgba(140, 155, 255, 0.12); color: var(--paper-2); white-space: nowrap;
}
.chip-live { background: rgba(255, 46, 99, 0.92); color: #fff; font-family: var(--hud); letter-spacing: 0.1em; font-size: 10.5px; box-shadow: 0 0 16px rgba(255, 46, 99, 0.7); }
.chip-live::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: #fff; animation: latido 1.4s ease-in-out infinite; }
.chip-dark { background: rgba(4, 5, 13, 0.72); color: #fff; backdrop-filter: blur(6px); }
.plat { --c: var(--violet); display: inline-flex; align-items: center; gap: 6px; color: var(--c); font: 700 12px/1 var(--sans); }
.plat svg { width: 14px; height: 14px; fill: currentColor; }
.plat-twitch { --c: var(--twitch); }
.plat-youtube { --c: var(--youtube); }
.plat-kick { --c: var(--kick); }
@keyframes latido { 0%, 100% { opacity: 1; transform: scale(1); } 50% { opacity: 0.35; transform: scale(0.7); } }
@keyframes ecualizador { 0%, 100% { transform: scaleY(0.3); } 50% { transform: scaleY(1); } }
.eq { display: inline-flex; align-items: flex-end; gap: 2px; height: 12px; }
.eq i { width: 3px; height: 100%; background: currentColor; border-radius: 2px; transform-origin: bottom; animation: ecualizador 0.9s ease-in-out infinite; }
.eq i:nth-child(2) { animation-delay: -0.3s; } .eq i:nth-child(3) { animation-delay: -0.6s; }

/* ---------------------------------------------------------------- dashboard: launch console */
.intake h1 { font-size: clamp(40px, 6vw, 70px); line-height: 0.98; }
.paste {
  position: relative; padding: 10px; border-radius: 20px; background: var(--glass); border: 1px solid var(--line);
  box-shadow: var(--glow);
}
.paste::before {
  content: ""; position: absolute; inset: -1px; border-radius: 21px; padding: 1px; pointer-events: none;
  background: var(--grad); opacity: 0.55;
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0); -webkit-mask-composite: xor; mask-composite: exclude;
}
.launch-strip { margin-top: 34px; }
.launch-strip .strip-head { display: flex; align-items: baseline; justify-content: space-between; gap: 14px; margin-bottom: 14px; }
.launch-strip .strip-head a { color: var(--cyan); font-size: 13.5px; text-decoration: none; }
.launch-strip .strip-head a:hover { text-decoration: underline; }
.strip { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(150px, 1fr); gap: 12px; overflow-x: auto; padding-bottom: 8px; }
* { scrollbar-width: thin; scrollbar-color: rgba(139, 92, 246, 0.6) transparent; }
::-webkit-scrollbar { width: 10px; height: 8px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: linear-gradient(90deg, rgba(34, 225, 255, 0.55), rgba(139, 92, 246, 0.7)); border-radius: 999px; }

/* ---------------------------------------------------------------- explore */
.ex-hero { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; flex-wrap: wrap; }
.ex-hero h1 { font: 700 clamp(38px, 5.4vw, 62px)/1 var(--serif); letter-spacing: -0.03em; }
.ex-hero p { margin-top: 12px; color: var(--muted); max-width: 560px; }
.radar { display: flex; gap: 10px; flex-wrap: wrap; }
.radar div {
  min-width: 110px; padding: 12px 14px; border-radius: 14px; background: var(--glass); border: 1px solid var(--line);
  box-shadow: var(--glow);
}
.radar b { display: block; font: 800 26px/1 var(--hud); }
.radar span { display: block; margin-top: 6px; font-size: 12px; color: var(--muted); }
.radar .r-twitch b { color: var(--twitch); text-shadow: 0 0 18px rgba(155, 92, 255, 0.7); }
.radar .r-youtube b { color: var(--youtube); text-shadow: 0 0 18px rgba(255, 31, 68, 0.6); }
.radar .r-kick b { color: var(--kick); text-shadow: 0 0 18px rgba(83, 252, 24, 0.55); }

.ex-bar { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; margin: 34px 0 26px; }
.ex-tabs { display: flex; gap: 6px; padding: 5px; border-radius: 999px; background: rgba(10, 12, 32, 0.7); border: 1px solid var(--line); }
.ex-tabs a {
  --c: var(--paper); display: inline-flex; align-items: center; gap: 7px; padding: 8px 15px; border-radius: 999px;
  color: var(--muted); text-decoration: none; font-weight: 600; font-size: 13.5px; transition: all 0.2s;
}
.ex-tabs a svg { width: 14px; height: 14px; fill: currentColor; }
.ex-tabs a:hover { color: #fff; }
.ex-tabs a.on { color: #fff; background: color-mix(in srgb, var(--c) 26%, transparent); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--c) 70%, transparent), 0 0 20px color-mix(in srgb, var(--c) 45%, transparent); }
.ex-tabs a.t-twitch { --c: var(--twitch); } .ex-tabs a.t-youtube { --c: var(--youtube); } .ex-tabs a.t-kick { --c: var(--kick); }
.ex-tabs a.t-all { --c: var(--cyan); }
.ex-search { flex: 1 1 320px; display: flex; gap: 8px; }
.ex-search input { height: 44px; border-radius: 999px; padding: 0 18px; }
.ex-search select { width: auto; height: 44px; border-radius: 999px; padding: 0 14px; }

.ex-section { margin-top: 30px; }
.ex-section h2 { display: flex; align-items: center; gap: 10px; font: 700 15px/1 var(--hud); letter-spacing: 0.16em; text-transform: uppercase; margin-bottom: 16px; }
.ex-section h2 .count { color: var(--muted); font-family: var(--sans); letter-spacing: 0; font-weight: 500; text-transform: none; font-size: 13px; }
.ex-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(258px, 1fr)); gap: 18px; }
.ex-card {
  --c: var(--violet); position: relative; display: flex; flex-direction: column; border-radius: 18px; overflow: hidden;
  background: var(--glass); border: 1px solid var(--line); box-shadow: var(--glow); transition: transform 0.25s, box-shadow 0.25s, border-color 0.25s;
}
.ex-card.p-twitch { --c: var(--twitch); } .ex-card.p-youtube { --c: var(--youtube); } .ex-card.p-kick { --c: var(--kick); }
.ex-card:hover {
  transform: translateY(-4px) scale(1.01); border-color: color-mix(in srgb, var(--c) 70%, transparent);
  box-shadow: 0 0 0 1px color-mix(in srgb, var(--c) 45%, transparent), 0 24px 60px -18px color-mix(in srgb, var(--c) 70%, transparent);
}
.ex-thumb { position: relative; aspect-ratio: 16 / 9; background: linear-gradient(135deg, color-mix(in srgb, var(--c) 45%, #0a0c1f), #0a0c1f); overflow: hidden; }
.ex-thumb img { position: relative; z-index: 1; width: 100%; height: 100%; object-fit: cover; display: block; transition: transform 0.5s; }
/* cover drawn under every picture: shows when there is none (Kick) or it fails to load */
.ex-thumb .cover {
  position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; gap: 14px;
  background:
    repeating-linear-gradient(115deg, rgba(255, 255, 255, 0.04) 0 2px, transparent 2px 14px),
    radial-gradient(120% 90% at 30% 20%, color-mix(in srgb, var(--c) 55%, transparent), transparent 60%),
    linear-gradient(135deg, color-mix(in srgb, var(--c) 35%, #070818), #070818);
}
.ex-thumb .cover .avatar { width: 58px; height: 58px; font-size: 18px; }
.ex-thumb .cover svg { width: 30px; height: 30px; fill: var(--c); filter: drop-shadow(0 0 12px var(--c)); }
.ex-thumb img.roto { display: none; }
.ex-card:hover .ex-thumb img { transform: scale(1.06); }
.ex-thumb::after { content: ""; position: absolute; inset: 0; z-index: 1; background: linear-gradient(180deg, transparent 50%, rgba(4, 5, 13, 0.85)); pointer-events: none; }
.ex-thumb .chip-live { position: absolute; top: 10px; left: 10px; z-index: 2; }
.ex-thumb .viewers { position: absolute; top: 10px; right: 10px; z-index: 2; }
.ex-thumb .since { position: absolute; bottom: 10px; right: 10px; z-index: 2; }
.ex-body { display: flex; flex-direction: column; gap: 8px; padding: 14px 16px 16px; flex: 1; }
.ex-who { display: flex; align-items: center; gap: 10px; }
.avatar {
  --c: var(--violet); flex: none; display: grid; place-items: center; width: 38px; height: 38px; border-radius: 50%;
  font: 800 13px/1 var(--hud); color: #fff;
  background: radial-gradient(circle at 30% 25%, color-mix(in srgb, var(--c) 85%, #fff), color-mix(in srgb, var(--c) 55%, #05060f));
  box-shadow: 0 0 0 2px #05060f, 0 0 0 3.5px color-mix(in srgb, var(--c) 90%, transparent), 0 0 18px color-mix(in srgb, var(--c) 60%, transparent);
}
.avatar.p-twitch { --c: var(--twitch); } .avatar.p-youtube { --c: var(--youtube); } .avatar.p-kick { --c: var(--kick); }
.avatar.is-live { animation: aura 2.2s ease-in-out infinite; }
@keyframes aura { 0%, 100% { box-shadow: 0 0 0 2px #05060f, 0 0 0 3.5px #ff2e63, 0 0 12px rgba(255, 46, 99, 0.6); } 50% { box-shadow: 0 0 0 2px #05060f, 0 0 0 3.5px #ff2e63, 0 0 26px rgba(255, 46, 99, 0.95); } }
.ex-name { font-weight: 700; font-size: 15.5px; line-height: 1.2; }
.ex-title { color: var(--paper-2); font-size: 13.5px; line-height: 1.4; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; min-height: 2.8em; }
.ex-cat { color: var(--muted); font-size: 12px; }
.ex-actions { display: flex; gap: 8px; margin-top: auto; padding-top: 6px; }
.ex-actions .btn { flex: 1; }

.ex-roster { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 10px; }
.ex-chip {
  --c: var(--violet); display: flex; align-items: center; gap: 11px; padding: 10px 12px; border-radius: 14px; cursor: pointer;
  background: rgba(14, 17, 42, 0.6); border: 1px solid var(--line); color: var(--paper); font: inherit; text-align: left;
  transition: border-color 0.2s, background 0.2s, transform 0.2s;
}
.ex-chip.p-twitch { --c: var(--twitch); } .ex-chip.p-youtube { --c: var(--youtube); } .ex-chip.p-kick { --c: var(--kick); }
.ex-chip:hover { transform: translateY(-2px); border-color: color-mix(in srgb, var(--c) 70%, transparent); background: color-mix(in srgb, var(--c) 12%, rgba(14, 17, 42, 0.6)); }
.ex-chip .avatar { width: 34px; height: 34px; font-size: 11.5px; }
.ex-chip small { display: block; color: var(--muted); font-size: 12px; margin-top: 2px; }
.ex-empty { padding: 28px; border-radius: 18px; border: 1px dashed var(--line-2); color: var(--muted); text-align: center; }

/* drawer with a streamer's live + recent streams */
.sx-scrim { position: fixed; inset: 0; z-index: 60; background: rgba(2, 3, 10, 0.66); backdrop-filter: blur(6px); opacity: 0; transition: opacity 0.25s; }
.sx-scrim.on { opacity: 1; }
.sx-drawer {
  position: fixed; top: 0; right: 0; bottom: 0; z-index: 61; width: min(560px, 100vw); overflow-y: auto;
  background: linear-gradient(180deg, rgba(16, 19, 48, 0.97), rgba(6, 7, 20, 0.98)); border-left: 1px solid var(--line-2);
  box-shadow: -30px 0 80px -20px rgba(139, 92, 246, 0.5); transform: translateX(105%); transition: transform 0.35s cubic-bezier(0.2, 0.8, 0.2, 1);
  padding: 26px 24px 40px;
}
.sx-drawer.on { transform: none; }
.sx-drawer .close { position: absolute; top: 16px; right: 16px; }
.sx-head { display: flex; align-items: center; gap: 14px; padding-right: 50px; }
.sx-head .avatar { width: 54px; height: 54px; font-size: 17px; }
.sx-head h2 { font: 700 24px/1.1 var(--serif); }
.sx-live { margin-top: 20px; }
.sx-vods { display: grid; gap: 12px; margin-top: 14px; }
.vod { display: grid; grid-template-columns: 148px 1fr; gap: 14px; padding: 10px; border-radius: 14px; background: rgba(14, 17, 42, 0.7); border: 1px solid var(--line); }
.vod .ex-thumb { border-radius: 10px; }
.vod .ex-thumb::after { display: none; }
.vod h4 { font-size: 13.5px; font-weight: 600; line-height: 1.35; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.vod .meta { color: var(--muted); font-size: 12px; margin-top: 4px; }
.vod .btn { margin-top: 8px; }
.sx-loading { display: grid; place-items: center; padding: 40px 0; color: var(--muted); }
.spinner { width: 34px; height: 34px; border-radius: 50%; border: 3px solid rgba(140, 155, 255, 0.2); border-top-color: var(--cyan); animation: gira 0.8s linear infinite; margin-bottom: 12px; }
@keyframes gira { to { transform: rotate(360deg); } }

/* confirm dialog */
.sx-modal {
  position: fixed; left: 50%; top: 50%; z-index: 70; width: min(460px, calc(100vw - 32px)); transform: translate(-50%, -46%) scale(0.96);
  opacity: 0; pointer-events: none; transition: all 0.25s; padding: 26px; border-radius: 22px;
  background: linear-gradient(180deg, rgba(22, 26, 64, 0.98), rgba(8, 10, 26, 0.98)); border: 1px solid var(--line-2); box-shadow: var(--glow);
}
.sx-modal.on { opacity: 1; pointer-events: auto; transform: translate(-50%, -50%) scale(1); }
.sx-modal h3 { font: 700 21px/1.2 var(--serif); }
.sx-modal p { color: var(--muted); margin-top: 8px; font-size: 14px; }
.sx-modal .what { margin-top: 14px; padding: 12px 14px; border-radius: 12px; background: rgba(140, 155, 255, 0.08); font-size: 13.5px; word-break: break-word; }
.sx-modal .rights { margin-top: 16px; }
.sx-modal .row-btns { display: flex; gap: 10px; margin-top: 18px; }
.sx-modal .row-btns .btn { flex: 1; }

/* ---------------------------------------------------------------- clip cards: edit button */
.clip .actions { flex-wrap: wrap; }
.clip .edited { margin-left: 6px; }
.render-badge { display: inline-flex; align-items: center; gap: 8px; margin-top: 8px; color: var(--cyan); font-size: 13px; }
.render-badge .spinner { width: 14px; height: 14px; border-width: 2px; margin: 0; }

/* ---------------------------------------------------------------- editor */
.ed-wrap { display: grid; grid-template-columns: minmax(280px, 380px) 1fr; gap: 34px; align-items: start; margin-top: 26px; }
.ed-stage { position: sticky; top: 90px; }
.ed-phone {
  position: relative; margin: 0 auto; width: 100%; max-width: 340px; border-radius: 34px; padding: 12px;
  background: linear-gradient(160deg, #1d2250, #090b1e); box-shadow: 0 0 0 1px rgba(140, 155, 255, 0.3), 0 30px 80px -20px rgba(139, 92, 246, 0.7), inset 0 0 30px rgba(34, 225, 255, 0.08);
}
.ed-screen { position: relative; border-radius: 24px; overflow: hidden; background: #000; aspect-ratio: 9 / 16; display: grid; place-items: center; transition: aspect-ratio 0.35s; }
.ed-screen video { width: 100%; height: 100%; object-fit: contain; background: #000; }
.ed-screen[data-shape="cuadrado"] { aspect-ratio: 1 / 1; }
.ed-screen[data-shape="retrato"] { aspect-ratio: 4 / 5; }
.ed-screen[data-shape="horizontal"] { aspect-ratio: 16 / 9; }
.ed-hook {
  position: absolute; left: 50%; top: 14%; transform: translateX(-50%); max-width: 86%; padding: 6px 12px; border-radius: 6px;
  background: #ffd400; color: #000; font: 900 15px/1.15 "Arial Black", var(--sans); text-align: center; text-transform: uppercase;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.45); pointer-events: none; transition: opacity 0.2s;
}
.ed-hook[hidden] { display: block; opacity: 0; }
.ed-note { margin-top: 12px; text-align: center; color: var(--muted); font-size: 12.5px; }
.ed-tabs { display: flex; gap: 4px; padding: 4px; margin: 0 auto 14px; width: max-content; max-width: 100%; border-radius: 999px; background: rgba(10, 12, 32, 0.7); border: 1px solid var(--line); }
.ed-tabs button { border: 0; background: none; color: var(--muted); font: 600 13px var(--sans); padding: 7px 14px; border-radius: 999px; cursor: pointer; }
.ed-tabs button.on { color: #fff; background: var(--grad); box-shadow: 0 0 18px rgba(139, 92, 246, 0.5); }
/* live preview: the 16:9 source framed like the chosen format */
.ed-screen.previa { background: radial-gradient(120% 80% at 50% 30%, rgba(139, 92, 246, 0.35), #03040c 70%); }
.ed-screen.previa video { object-fit: contain; }
.ed-screen.previa[data-fmt="recorte"] video, .ed-screen.previa[data-fmt="camara"] video { object-fit: cover; }
.ed-screen.previa[data-fmt="borroso"] video, .ed-screen.previa[data-fmt="cuadrado"] video, .ed-screen.previa[data-fmt="retrato"] video { transform: scale(1.0); }
.ed-cap {
  position: absolute; left: 50%; top: 68%; transform: translateX(-50%); white-space: nowrap; pointer-events: none;
  font: 900 17px/1 "Arial Black", var(--sans); color: #fff; letter-spacing: 0.01em;
  text-shadow: 0 0 2px #000, 2px 2px 0 #000, -2px -2px 0 #000, 2px -2px 0 #000, -2px 2px 0 #000, 0 4px 10px rgba(0, 0, 0, 0.6);
}
.ed-cap b { color: var(--sub, #ffd700); font-weight: 900; }
.ed-cap[hidden] { display: none; }
.ed-screen[data-shape="horizontal"] .ed-cap { top: 80%; font-size: 13px; }
.ed-screen[data-shape="horizontal"] .ed-hook { top: 8%; font-size: 11px; }
.ed-screen[data-shape="cuadrado"] .ed-hook, .ed-screen[data-shape="retrato"] .ed-hook { top: 9%; }
.ed-screen[data-shape="cuadrado"] .ed-cap { top: 80%; }
fieldset.ed-box { min-width: 0; }
fieldset.ed-box[disabled] { opacity: 0.45; }
.clip .actions .btn-edit { background: linear-gradient(120deg, rgba(34, 225, 255, 0.18), rgba(139, 92, 246, 0.22)); box-shadow: inset 0 0 0 1px rgba(34, 225, 255, 0.55), 0 0 18px rgba(34, 225, 255, 0.25); }
.ed-panel { display: grid; gap: 18px; }
.ed-box { padding: 20px 22px; border-radius: 18px; background: var(--glass); border: 1px solid var(--line); box-shadow: var(--glow); }
.ed-box h3 { display: flex; align-items: center; gap: 10px; font: 700 12px/1 var(--hud); letter-spacing: 0.16em; text-transform: uppercase; color: var(--cyan); margin-bottom: 14px; }
.ed-box h3 .n { display: grid; place-items: center; width: 22px; height: 22px; border-radius: 7px; background: var(--grad); color: #fff; font-size: 11px; letter-spacing: 0; }
.formats { display: grid; grid-template-columns: repeat(auto-fill, minmax(118px, 1fr)); gap: 10px; }
.fmt { position: relative; cursor: pointer; }
.fmt input { position: absolute; opacity: 0; pointer-events: none; }
.fmt span {
  display: flex; flex-direction: column; align-items: center; gap: 9px; padding: 14px 8px 12px; border-radius: 14px; text-align: center;
  background: rgba(10, 12, 32, 0.6); border: 1px solid var(--line); font-size: 12.5px; font-weight: 600; line-height: 1.25; transition: all 0.2s;
}
.fmt small { display: block; color: var(--muted); font-weight: 400; font-size: 11.5px; }
.fmt:hover span { border-color: rgba(34, 225, 255, 0.5); }
.fmt input:checked + span { border-color: var(--cyan); background: rgba(34, 225, 255, 0.1); box-shadow: 0 0 0 1px var(--cyan), 0 0 24px rgba(34, 225, 255, 0.35); }
.fmt input:disabled + span { opacity: 0.35; cursor: not-allowed; }
.fmt input:focus-visible + span { outline: 2px solid var(--cyan); outline-offset: 2px; }
.shape { position: relative; display: block; background: rgba(140, 155, 255, 0.16); border: 1.5px solid rgba(200, 210, 255, 0.55); border-radius: 4px; overflow: hidden; }
.shape.s-916 { width: 30px; height: 52px; } .shape.s-11 { width: 44px; height: 44px; } .shape.s-45 { width: 38px; height: 47px; } .shape.s-169 { width: 60px; height: 34px; }
.shape .cam { position: absolute; left: 0; right: 0; top: 0; height: 38%; background: rgba(255, 61, 129, 0.55); }
.shape .game { position: absolute; left: 0; right: 0; background: rgba(34, 225, 255, 0.55); }
.shape.s-916 .game.full { top: 0; bottom: 0; }
.shape.s-916 .game.mid { top: 30%; height: 40%; }
.shape.s-916 .game.low { top: 38%; bottom: 0; }
.shape .game.c169 { top: 50%; height: 56%; transform: translateY(-50%); }
.shape.s-169 .game.all { inset: 0; }
.ed-row { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; }
.ed-row label { font-size: 13.5px; }
.ed-field { display: grid; gap: 7px; }
.ed-field > span { font-size: 13px; color: var(--muted); }
.ed-field input[type="text"] { height: 46px; padding: 0 14px; border-radius: 12px; border: 1px solid var(--line-2); width: 100%; outline: none; font: 600 15px var(--sans); }
.ed-count { font-size: 12px; color: var(--faint); text-align: right; }
.toggle { display: inline-flex; align-items: center; gap: 10px; cursor: pointer; font-size: 14px; user-select: none; }
.toggle input { position: absolute; opacity: 0; }
.toggle i { position: relative; width: 44px; height: 24px; border-radius: 999px; background: rgba(140, 155, 255, 0.22); transition: background 0.2s, box-shadow 0.2s; }
.toggle i::after { content: ""; position: absolute; top: 3px; left: 3px; width: 18px; height: 18px; border-radius: 50%; background: #fff; transition: transform 0.2s; }
.toggle input:checked + i { background: var(--grad); box-shadow: 0 0 16px rgba(139, 92, 246, 0.6); }
.toggle input:checked + i::after { transform: translateX(20px); }
.toggle input:focus-visible + i { outline: 2px solid var(--cyan); outline-offset: 2px; }
.swatches { display: flex; gap: 10px; flex-wrap: wrap; }
.sw { position: relative; cursor: pointer; }
.sw input { position: absolute; opacity: 0; }
.sw i { display: block; width: 34px; height: 34px; border-radius: 50%; background: var(--c); box-shadow: 0 0 0 2px #05060f, 0 0 0 3px rgba(255, 255, 255, 0.2); transition: transform 0.15s, box-shadow 0.15s; }
.sw input:checked + i { transform: scale(1.12); box-shadow: 0 0 0 2px #05060f, 0 0 0 4px #fff, 0 0 20px var(--c); }
.sw input:focus-visible + i { outline: 2px solid var(--cyan); outline-offset: 3px; }
.ed-go { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; }
.ed-go .btn { height: 52px; padding: 0 30px; font-size: 16px; }
.ed-status { display: inline-flex; align-items: center; gap: 10px; color: var(--cyan); font-size: 14px; }
.ed-status .spinner { width: 18px; height: 18px; border-width: 2px; margin: 0; }
.ed-status.bad { color: #ff8fb0; }
.ed-locked { padding: 14px 16px; border-radius: 12px; background: rgba(255, 209, 102, 0.08); border: 1px solid rgba(255, 209, 102, 0.35); color: #ffe3a3; font-size: 13.5px; }

/* ---------------------------------------------------------------- top bar on smaller screens (one more tab now) */
@media (max-width: 1100px) {
  .topbar { gap: 20px; }
  .who { gap: 12px; }
  .who .email { display: none; }
}
@media (max-width: 640px) {
  .topbar { flex-wrap: wrap; row-gap: 10px; }
  .tabs { order: 3; width: 100%; overflow-x: auto; scrollbar-width: none; }
  .tabs::-webkit-scrollbar { display: none; }
  .tabs a { flex: none; }
}

/* ---------------------------------------------------------------- phones */
@media (max-width: 860px) {
  .ed-wrap { grid-template-columns: 1fr; }
  .ed-stage { position: static; }
  .ex-bar { margin: 24px 0 18px; }
  .ex-tabs { overflow-x: auto; max-width: 100%; }
  .vod { grid-template-columns: 112px 1fr; }
}

/* ---------------------------------------------------------------- less motion */
/* ---------------------------------------------------------------- editor: title ideas (free, no AI) */
.ed-ideas { margin-top: 14px; padding-top: 14px; border-top: 1px dashed var(--line-2); }
.ed-ideas-h { font: 700 11px/1 var(--hud); letter-spacing: 0.12em; text-transform: uppercase; color: var(--cyan); margin-bottom: 10px; }
.ideas { display: flex; flex-wrap: wrap; gap: 8px; }
.idea {
  border: 1px solid var(--line-2); background: rgba(10, 12, 32, 0.6); color: var(--paper); cursor: pointer;
  padding: 8px 12px; border-radius: 10px; font: 800 12px/1.25 var(--sans); letter-spacing: 0.01em; text-align: left;
  transition: border-color 0.2s, box-shadow 0.2s, transform 0.15s;
}
.idea:hover { border-color: var(--cyan); box-shadow: 0 0 14px rgba(34, 225, 255, 0.35); transform: translateY(-1px); }
.idea.on { border-color: transparent; background: #ffd700; color: #000; box-shadow: 0 0 18px rgba(255, 215, 0, 0.45); }
.idea:focus-visible, .idea-mas:focus-visible { outline: 2px solid var(--cyan); outline-offset: 2px; }
.idea-mas { margin-top: 10px; border: 0; background: none; color: var(--cyan); font: 600 13px var(--sans); cursor: pointer; padding: 4px 0; }
.idea-mas:hover { text-decoration: underline; }
.idea-mas:disabled { opacity: 0.5; cursor: wait; }

@media (prefers-reduced-motion: reduce) {
  body::before, .chip-live::before, .tabs .tab-live i, .avatar.is-live, .eq i, .spinner { animation: none !important; }
  .btn::after { display: none; }
  .ex-card, .job, .clip, .ex-chip, .sx-drawer, .sx-modal, .idea { transition: none !important; }
}

/* ---------------------------------------------------------------- show / hide password (app.js verClave) */
.pw-wrap { position: relative; display: block; }
.pw-wrap .pw-input {
  width: 100%; height: 48px; padding: 0 52px 0 18px; border-radius: 12px; border: 1px solid var(--line-2);
  background: rgba(10, 12, 32, 0.7); color: var(--paper); font: 400 15px var(--sans); outline: none;
}
.pw-wrap .pw-input::-ms-reveal, .pw-wrap .pw-input::-ms-clear { display: none; }   /* Edge's own eye: one is enough */
.pw-eye {
  position: absolute; right: 6px; top: 50%; transform: translateY(-50%); width: 38px; height: 38px;
  display: grid; place-items: center; border: 0; border-radius: 10px; background: transparent; color: var(--muted); cursor: pointer;
}
.pw-eye:hover { color: var(--paper); background: rgba(140, 155, 255, 0.12); }
.pw-eye[aria-pressed="true"] { color: var(--cyan); }
.pw-eye:focus-visible { outline: 2px solid var(--cyan); outline-offset: 1px; }
.pw-eye svg { width: 20px; height: 20px; }

/* ---------------------------------------------------------------- stream page: "Download all" */
.clips-bar { display: flex; align-items: center; flex-wrap: wrap; gap: 10px 16px; margin: 6px 0 16px; }
.clips-bar-note { font-size: 12.5px; color: var(--faint); }
.idea-post { font-weight: 600; text-transform: none; font-size: 12.5px; }

/* ---------------------------------------------------------------- clip card: why Setsu picked it */
.why { display: flex; flex-wrap: wrap; gap: 6px; margin: 2px 0 10px; }
.why-tag { padding: 4px 9px; border-radius: 999px; font: 600 11.5px/1.2 var(--sans); color: var(--paper);
  background: rgba(139, 92, 246, 0.16); box-shadow: inset 0 0 0 1px rgba(139, 92, 246, 0.4); }
.stack-tight .toggle-line { display: flex; align-items: center; gap: 10px; color: var(--paper); font-size: 14px; margin: 4px 0 6px; }
.stack-tight .toggle-line input { height: auto; }
