/* WF STREAM Admin — dark glass / spatial UI. No framework, no external assets. */

/* Copias: superficies suaves, jerarquía clara y movimiento discreto. */
.copies-panel { display: grid; gap: 24px; max-width: 1180px; margin: 0 auto; }
.copies-tabs { justify-self: start; }
.copies-history-tools { display:flex; flex-wrap:wrap; gap:12px; align-items:end; }
.copies-history-tools > input[type=search] { flex:1; min-width:180px; }
.copies-history-tools input,.copies-history-tools select { padding:10px 12px; background:var(--surface-solid); border:1px solid var(--line-strong); border-radius:11px; }
.copies-history-tools label { display:grid; gap:6px; color:var(--text-2); font-size:12px; }
.copies-history-row { display:grid; grid-template-columns:150px minmax(0,1fr) auto; gap:20px; padding:20px 0; border-top:1px solid var(--line); align-items:start; }
.copies-history-date { color:var(--text-2); font-size:12px; }
.copies-history-detail strong { font-weight:540; overflow-wrap:anywhere; }
.copies-history-detail p { margin:7px 0; color:var(--text-2); font-size:13px; }
.copies-history-detail small { color:var(--text-3); overflow-wrap:anywhere; }
.copies-pagination { display:flex; justify-content:flex-end; gap:12px; margin-top:20px; }
.copies-pending { padding:12px 16px; border-radius:12px; background:var(--warn-soft); color:var(--warn) !important; }
@media(max-width:600px) { .copies-history-row { grid-template-columns:1fr; gap:10px; } .copies-history-tools label { flex:1; } .copies-history-tools label input { width:100%; min-width:0; } }
.copies-hero { position: relative; overflow: hidden; padding: 38px 40px 24px; border-radius: 30px; border: 1px solid rgba(255,255,255,.12); background: radial-gradient(ellipse at 80% 0%,rgba(92,145,255,.16),transparent 60%),linear-gradient(145deg,rgba(35,39,52,.9),rgba(16,19,27,.9)); box-shadow: 0 20px 65px rgba(0,0,0,.18),inset 0 1px rgba(255,255,255,.05); }
.copies-status { display: flex; gap: 8px; align-items: center; font-size: 12px; color: var(--text-2); }
.copies-status i { width: 7px; height: 7px; border-radius: 50%; background: var(--text-3); }
.copies-status.is-live i { background: #65ddb0; box-shadow: 0 0 12px rgba(101,221,176,.35); }
.copies-hero h2 { font-size: clamp(27px,3.4vw,42px); font-weight: 600; letter-spacing: -.045em; line-height: 1.15; margin: 26px 0 12px; }
.copies-hero > p { color: var(--text-2); max-width: 580px; font-size: 15px; line-height: 1.7; }
.copies-cloud-route { position: absolute; right: 40px; top: 42px; display: flex; align-items: center; gap: 15px; color: var(--text-3); }
.copies-cloud { display: grid; place-items: center; width: 46px; height: 46px; border-radius: 15px; font-size: 21px; font-weight: 650; border: 1px solid rgba(255,255,255,.12); }
.copies-cloud.terabox { color: #85bbff; background: rgba(60,132,242,.12); }
.copies-cloud.drive { color: #80ddb9; background: rgba(60,189,132,.12); }
.copies-route-line { width: 28px; height: 1px; background: var(--line-strong); }
.copies-metrics { display: grid; grid-template-columns: repeat(4,1fr); gap: 20px; margin-top: 32px; padding: 24px 0; border-top: 1px solid var(--line); }
.copies-metric { display: grid; gap: 9px; }
.copies-metric > span { color: var(--text-2); font-size: 12px; }
.copies-metric > strong { font-size: 25px; font-weight: 550; letter-spacing: -.04em; font-variant-numeric: tabular-nums; }
.copies-caption { color: var(--text-3); font-size: 11px; line-height: 1.6; }
.copies-card { background: rgba(23,26,35,.75); border: 1px solid var(--line); border-radius: 24px; padding: 24px; min-width: 0; }
.copies-heading { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 18px; }
.copies-heading h3 { font-weight: 580; font-size: 17px; letter-spacing: -.02em; margin: 0; }
.copies-file { display: flex; align-items: center; gap: 18px; padding: 20px 0; border-top: 1px solid var(--line); }
.copies-file-icon { width: 48px; height: 56px; display: grid; place-items: center; flex: none; border: 1px solid var(--line-strong); border-radius: 12px; background: linear-gradient(145deg,rgba(255,255,255,.07),rgba(255,255,255,.02)); color: #b4c5e2; }
.copies-file-body { flex: 1; min-width: 0; }
.copies-file-heading,.copies-file-meta { display: flex; justify-content: space-between; gap: 15px; font-variant-numeric: tabular-nums; }
.copies-file-heading strong { font-weight: 520; overflow-wrap: anywhere; }
.copies-file-heading > span { white-space: nowrap; color: #8db6ff; }
.copies-progress { display: block; appearance: none; width: 100%; height: 5px; margin: 14px 0 10px; border: 0; border-radius: 9px; overflow: hidden; background: rgba(255,255,255,.07); }
.copies-progress::-webkit-progress-bar { background: rgba(255,255,255,.07); border-radius: 9px; }
.copies-progress::-webkit-progress-value { background: linear-gradient(90deg,#639aff,#9cc2ff); border-radius: 9px; transition: width .6s ease; }
.copies-progress::-moz-progress-bar { background: #80acff; border-radius: 9px; }
.copies-file-meta { flex-wrap: wrap; color: var(--text-2); font-size: 12px; }
.copies-bottom { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; align-items: start; }
.copies-folder { display: flex; align-items: center; gap: 12px; padding: 15px 0; border-top: 1px solid var(--line); }
.copies-folder > span:not(.chip) { flex: 1; overflow-wrap: anywhere; }
.copies-folder > .icon { flex: none; color: var(--text-3); }
.copies-folder strong { font-size: 13px; font-weight: 500; overflow-wrap: anywhere; }
@media(max-width:900px) { .copies-bottom { grid-template-columns: 1fr; } .copies-cloud-route { position: static; margin-top: 24px; } }
@media(max-width:600px) { .copies-hero { padding: 26px 22px 20px; } .copies-metrics { grid-template-columns: 1fr 1fr; gap: 22px; } .copies-card { padding: 20px; } .copies-folder { flex-wrap: wrap; } .copies-file-icon { display:none; } }
@media(prefers-reduced-motion:reduce) { .copies-progress::-webkit-progress-value { transition:none; } }

:root {
  --bg: #06070b;
  --surface: rgba(23, 26, 37, 0.64);
  --surface-2: rgba(33, 37, 52, 0.5);
  --surface-solid: #11131c;
  --hover: rgba(255, 255, 255, 0.045);
  --line: rgba(255, 255, 255, 0.075);
  --line-strong: rgba(255, 255, 255, 0.14);
  --text: #eef0f6;
  --text-2: #a6abbd;
  --text-3: #6f7488;
  --accent: #6e8bff;
  --accent-2: #9b7bff;
  --accent-grad: linear-gradient(135deg, #5b7cff 0%, #8f6bff 100%);
  --accent-soft: rgba(110, 139, 255, 0.14);
  --ok: #4fd1a1; --ok-soft: rgba(79, 209, 161, 0.13);
  --warn: #f0b35a; --warn-soft: rgba(240, 179, 90, 0.13);
  --danger: #ff6b81; --danger-soft: rgba(255, 107, 129, 0.13);
  --info: #7fb2ff; --info-soft: rgba(127, 178, 255, 0.13);
  --r-lg: 22px; --r: 16px; --r-sm: 11px;
  --shadow: 0 24px 60px -28px rgba(0, 0, 0, 0.75);
  --blur: saturate(150%) blur(22px);
  --font: -apple-system, BlinkMacSystemFont, "SF Pro Display", "SF Pro Text", "Segoe UI Variable Display", "Segoe UI", Inter, Roboto, system-ui, sans-serif;
  --mono: ui-monospace, "SF Mono", "Cascadia Code", Menlo, Consolas, monospace;
  --sidebar: 250px;
}

* { box-sizing: border-box; }
html, body { height: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: 14.5px;
  line-height: 1.45;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
button, input, select, textarea { font: inherit; color: inherit; }
a { color: var(--accent); text-decoration: none; }
::selection { background: rgba(110, 139, 255, 0.35); }
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-thumb { background: rgba(255, 255, 255, 0.1); border-radius: 8px; border: 3px solid transparent; background-clip: content-box; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

/* ---------- ambient background ---------- */
.backdrop { position: fixed; inset: 0; z-index: -1; overflow: hidden; background: radial-gradient(120% 90% at 15% -10%, #101427 0%, #06070b 55%); }
.orb { position: absolute; border-radius: 50%; filter: blur(80px); opacity: 0.5; }
.orb-a { width: 520px; height: 520px; left: -140px; top: -180px; background: radial-gradient(circle, rgba(91, 124, 255, 0.55), transparent 65%); }
.orb-b { width: 620px; height: 620px; right: -220px; top: 60px; background: radial-gradient(circle, rgba(143, 107, 255, 0.4), transparent 65%); }
.orb-c { width: 480px; height: 480px; left: 35%; bottom: -260px; background: radial-gradient(circle, rgba(79, 209, 161, 0.14), transparent 65%); }

/* ---------- boot ---------- */
.boot { display: grid; place-items: center; min-height: 100vh; }
.boot-mark { width: 34px; height: 34px; border-radius: 12px; background: var(--accent-grad); animation: pulse 1.4s ease-in-out infinite; }
@keyframes pulse { 0%, 100% { transform: scale(0.85); opacity: 0.55; } 50% { transform: scale(1); opacity: 1; } }
@keyframes rise { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
@keyframes spin { to { transform: rotate(360deg); } }

/* ---------- login ---------- */
.login { min-height: 100vh; display: grid; place-items: center; padding: 24px; }
.login-card { width: 100%; max-width: 400px; padding: 34px 32px 30px; border-radius: var(--r-lg); border: 1px solid var(--line); background: var(--surface); backdrop-filter: var(--blur); -webkit-backdrop-filter: var(--blur); box-shadow: var(--shadow); animation: rise 0.45s ease both; }
.brand { display: flex; align-items: center; gap: 12px; }
.brand-mark { width: 40px; height: 40px; border-radius: 13px; background: var(--accent-grad); display: grid; place-items: center; font-weight: 700; font-size: 15px; letter-spacing: -0.5px; color: #fff; box-shadow: 0 8px 22px -8px rgba(110, 139, 255, 0.8); }
.brand-name { font-weight: 640; letter-spacing: 0.14em; font-size: 12.5px; text-transform: uppercase; }
.brand-sub { color: var(--text-3); font-size: 11.5px; letter-spacing: 0.1em; text-transform: uppercase; }
.login-title { margin: 26px 0 4px; font-size: 21px; font-weight: 620; letter-spacing: -0.3px; }
.login-hint { margin: 0 0 22px; color: var(--text-2); font-size: 13px; }
.field { display: block; margin-bottom: 14px; }
.field > span { display: block; margin-bottom: 7px; font-size: 12px; color: var(--text-2); letter-spacing: 0.02em; }
.input-wrap { position: relative; display: flex; align-items: center; }
input[type="text"], input[type="tel"], input[type="password"], input[type="search"], select {
  width: 100%; padding: 11px 13px; border-radius: var(--r-sm); border: 1px solid var(--line);
  background: rgba(10, 12, 18, 0.6); color: var(--text); transition: border-color 0.16s, background 0.16s, box-shadow 0.16s;
}
input::placeholder { color: var(--text-3); }
input:focus, select:focus { outline: none; border-color: rgba(110, 139, 255, 0.6); box-shadow: 0 0 0 4px var(--accent-soft); }
.ghost-toggle { position: absolute; right: 6px; padding: 6px 9px; border: 0; background: transparent; color: var(--text-3); border-radius: 8px; cursor: pointer; font-size: 12px; }
.ghost-toggle:hover { color: var(--text); background: var(--hover); }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 10px 16px; border-radius: var(--r-sm); border: 1px solid var(--line-strong); background: var(--surface-2); color: var(--text); cursor: pointer; font-weight: 520; transition: transform 0.12s, background 0.16s, border-color 0.16s, opacity 0.16s; }
.btn:hover { background: var(--hover); border-color: rgba(255, 255, 255, 0.2); }
.btn:active { transform: scale(0.985); }
.btn[disabled] { opacity: 0.5; cursor: not-allowed; }
.btn-primary { background: var(--accent-grad); border: 0; color: #fff; box-shadow: 0 10px 26px -12px rgba(110, 139, 255, 0.9); }
.btn-primary:hover { filter: brightness(1.07); background: var(--accent-grad); }
.btn-danger { background: var(--danger-soft); border-color: rgba(255, 107, 129, 0.35); color: #ffb7c2; }
.btn-block { width: 100%; padding: 12px; }
.btn-sm { padding: 6px 11px; font-size: 13px; }
.spinner { width: 15px; height: 15px; border-radius: 50%; border: 2px solid rgba(255, 255, 255, 0.3); border-top-color: #fff; animation: spin 0.7s linear infinite; }
.form-error { margin: 2px 0 14px; padding: 10px 12px; border-radius: var(--r-sm); background: var(--danger-soft); border: 1px solid rgba(255, 107, 129, 0.3); color: #ffc0ca; font-size: 13px; }
.login-foot { margin: 18px 0 0; color: var(--text-3); font-size: 11.5px; text-align: center; }

/* ---------- shell ---------- */
.shell { display: grid; grid-template-columns: var(--sidebar) 1fr; min-height: 100vh; }
.sidebar { position: sticky; top: 0; height: 100vh; display: flex; flex-direction: column; gap: 6px; padding: 22px 16px; border-right: 1px solid var(--line); background: rgba(12, 14, 20, 0.55); backdrop-filter: var(--blur); -webkit-backdrop-filter: var(--blur); }
.sidebar .brand { padding: 0 6px 18px; }
.nav { display: flex; flex-direction: column; gap: 3px; }
.nav-item { display: flex; align-items: center; gap: 11px; padding: 9px 11px; border-radius: 12px; border: 0; background: transparent; color: var(--text-2); cursor: pointer; text-align: left; width: 100%; font-size: 13.8px; transition: background 0.15s, color 0.15s; }
.nav-item:hover { background: var(--hover); color: var(--text); }
.nav-item.active { background: var(--accent-soft); color: #dfe4ff; box-shadow: inset 0 0 0 1px rgba(110, 139, 255, 0.25); }
.nav-item .icon { flex: none; }
.nav-badge { margin-left: auto; min-width: 20px; padding: 1px 6px; border-radius: 999px; background: var(--info-soft); color: var(--info); font-size: 11px; font-weight: 600; text-align: center; }
.sidebar-foot { margin-top: auto; display: flex; flex-direction: column; gap: 10px; }
.admin-chip { display: flex; align-items: center; gap: 10px; padding: 10px; border-radius: 14px; border: 1px solid var(--line); background: var(--surface-2); }
.admin-chip .meta { min-width: 0; }
.admin-chip .name { font-size: 13px; font-weight: 560; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.admin-chip .role { font-size: 10.5px; letter-spacing: 0.08em; color: var(--accent); text-transform: uppercase; }
.avatar { flex: none; width: 34px; height: 34px; border-radius: 11px; display: grid; place-items: center; font-size: 12.5px; font-weight: 620; color: #e9ecff; background: linear-gradient(135deg, rgba(91, 124, 255, 0.55), rgba(143, 107, 255, 0.45)); border: 1px solid var(--line); }
.avatar-lg { width: 56px; height: 56px; border-radius: 18px; font-size: 18px; }
.icon { width: 18px; height: 18px; stroke: currentColor; fill: none; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.icon-sm { width: 15px; height: 15px; }

.main { min-width: 0; display: flex; flex-direction: column; }
.topbar { position: sticky; top: 0; z-index: 5; display: flex; align-items: center; gap: 14px; padding: 18px 40px; border-bottom: 1px solid var(--line); background: rgba(6, 7, 11, 0.72); backdrop-filter: var(--blur); -webkit-backdrop-filter: var(--blur); }
.topbar h1 { margin: 0; font-size: 17px; font-weight: 600; letter-spacing: -0.2px; }
.topbar .crumb { color: var(--text-3); font-size: 12px; }
.topbar-right { margin-left: auto; display: flex; align-items: center; gap: 10px; }
.kbd { padding: 2px 6px; border-radius: 6px; border: 1px solid var(--line-strong); background: rgba(255, 255, 255, 0.04); font-family: var(--mono); font-size: 11px; color: var(--text-3); }
.menu-btn { display: none; }
/* Centrado en pantallas anchas: sin esto el panel queda pegado a la izquierda
   y deja un vacío grande a la derecha en monitores grandes. */
.content { padding: 34px 40px 80px; max-width: 1560px; width: 100%; margin-inline: auto; animation: rise 0.3s ease both; }

/* ---------- cards / layout ---------- */
.card { border: 1px solid var(--line); border-radius: var(--r-lg); background: var(--surface); backdrop-filter: var(--blur); -webkit-backdrop-filter: var(--blur); box-shadow: var(--shadow); }
.card-pad { padding: 24px 26px; }
.card-head { display: flex; align-items: center; gap: 12px; padding: 18px 24px; border-bottom: 1px solid var(--line); }
.card-head h2 { margin: 0; font-size: 14px; font-weight: 600; letter-spacing: 0.01em; }
.card-head .sub { color: var(--text-3); font-size: 12px; }
.card-head .right { margin-left: auto; display: flex; gap: 8px; align-items: center; }
.grid { display: grid; gap: 22px; }
/* `gap` separa solo DENTRO de cada rejilla: la separación entre la fila de
   KPIs y el bloque siguiente tiene que ser un margen explícito. */
.grid-kpi { grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); margin-bottom: 26px; }
.grid + .grid, .grid + .card, .card + .grid { margin-top: 26px; }
.grid-kpi + .grid-2 { margin-top: 0; }
.grid-2 { grid-template-columns: minmax(0, 1.12fr) minmax(0, 0.88fr); gap: 26px; align-items: start; }
.grid-2 > .grid { gap: 26px; }
/* La columna derecha acompaña el scroll y su lista larga no estira la fila. */
.col-sticky { position: sticky; top: 88px; }
.card-scroll { max-height: 560px; overflow-y: auto; overscroll-behavior: contain; }
.row { display: flex; align-items: center; gap: 12px; }
.row-wrap { flex-wrap: wrap; }
.spacer { flex: 1; }
.section-title { margin: 38px 0 16px; font-size: 12px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--text-3); }
.hello { margin: 0 0 6px; font-size: 25px; font-weight: 620; letter-spacing: -0.5px; }
.hello-sub { margin: 0 0 30px; color: var(--text-2); font-size: 13.5px; }

.kpi { padding: 24px 26px 22px; display: flex; flex-direction: column; gap: 4px; position: relative; overflow: hidden; min-height: 132px; }
.kpi .label { color: var(--text-2); font-size: 12.5px; }
.kpi .value { margin: 6px 0 2px; font-size: 34px; font-weight: 650; letter-spacing: -1.2px; line-height: 1.1; font-variant-numeric: tabular-nums; }
.kpi .foot { margin-top: auto; color: var(--text-3); font-size: 11.5px; }
.kpi .glow { position: absolute; right: -30px; top: -40px; width: 120px; height: 120px; border-radius: 50%; filter: blur(30px); opacity: 0.35; background: var(--accent); }
.kpi.ok .glow { background: var(--ok); }
.kpi.warn .glow { background: var(--warn); }
.kpi.info .glow { background: var(--info); }

/* ---------- lists / tables ---------- */
.list { display: flex; flex-direction: column; }
.list-row { display: flex; align-items: center; gap: 16px; padding: 15px 24px; border-bottom: 1px solid var(--line); background: none; border-left: 0; border-right: 0; border-top: 0; width: 100%; text-align: left; cursor: pointer; transition: background 0.14s; color: inherit; }
.list-row:last-child { border-bottom: 0; }
.list-row:hover { background: var(--hover); }
.list-row.static { cursor: default; }
.list-row.static:hover { background: none; }
.cell { min-width: 0; }
.cell-grow { flex: 1; min-width: 0; }
.cell-w { width: 150px; flex: none; }
.cell-w-sm { width: 110px; flex: none; }
.primary-text { font-size: 14px; font-weight: 545; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.muted { color: var(--text-2); font-size: 12.5px; }
.muted-2 { color: var(--text-3); font-size: 11.5px; }
.mono { font-family: var(--mono); }
.list-head { display: flex; gap: 16px; padding: 11px 24px; border-bottom: 1px solid var(--line); color: var(--text-3); font-size: 11px; letter-spacing: 0.08em; text-transform: uppercase; }
.chev { flex: none; color: var(--text-3); }
.empty { display: grid; place-items: center; gap: 10px; padding: 58px 24px; text-align: center; color: var(--text-3); }
.empty .icon { width: 26px; height: 26px; opacity: 0.6; }
.empty strong { color: var(--text-2); font-weight: 560; font-size: 13.5px; }

.pill { display: inline-flex; align-items: center; gap: 6px; padding: 3px 10px; border-radius: 999px; font-size: 11.5px; font-weight: 560; letter-spacing: 0.01em; white-space: nowrap; }
.pill::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.pill-ok { background: var(--ok-soft); color: var(--ok); }
.pill-warn { background: var(--warn-soft); color: var(--warn); }
.pill-danger { background: var(--danger-soft); color: var(--danger); }
.pill-info { background: var(--info-soft); color: var(--info); }
.pill-mute { background: rgba(255, 255, 255, 0.06); color: var(--text-3); }
.tag { padding: 2px 8px; border-radius: 7px; background: rgba(255, 255, 255, 0.055); color: var(--text-2); font-size: 11.5px; }

.segmented { display: inline-flex; padding: 3px; border-radius: 12px; border: 1px solid var(--line); background: rgba(10, 12, 18, 0.5); }
.segmented button { padding: 6px 13px; border: 0; border-radius: 9px; background: transparent; color: var(--text-2); cursor: pointer; font-size: 13px; transition: background 0.15s, color 0.15s; }
.segmented button:hover { color: var(--text); }
.segmented button.active { background: var(--surface-2); color: var(--text); box-shadow: inset 0 0 0 1px var(--line); }
.search { position: relative; flex: 1; min-width: 200px; max-width: 380px; }
.search input { padding-left: 36px; }
.search .icon { position: absolute; left: 11px; top: 50%; transform: translateY(-50%); color: var(--text-3); pointer-events: none; }
.toolbar { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin-bottom: 22px; }

.banner { display: flex; gap: 12px; align-items: flex-start; padding: 13px 16px; border-radius: var(--r); border: 1px solid rgba(127, 178, 255, 0.22); background: var(--info-soft); color: #cfe0ff; font-size: 13px; margin-bottom: 16px; }
.banner .icon { flex: none; margin-top: 1px; color: var(--info); }
.banner b { color: #fff; font-weight: 600; }

.back-link { display: inline-flex; align-items: center; gap: 7px; margin-bottom: 14px; padding: 5px 10px 5px 6px; border-radius: 9px; border: 0; background: transparent; color: var(--text-2); cursor: pointer; font-size: 13px; }
.back-link:hover { background: var(--hover); color: var(--text); }
.detail-head { display: flex; align-items: center; gap: 18px; padding: 26px; flex-wrap: wrap; }
.detail-head .who { min-width: 0; }
.detail-head h2 { margin: 0 0 3px; font-size: 20px; font-weight: 620; letter-spacing: -0.3px; }
.detail-actions { margin-left: auto; display: flex; gap: 8px; flex-wrap: wrap; }
.facts { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 1px; background: var(--line); border-top: 1px solid var(--line); }
.fact { padding: 16px 22px; background: rgba(17, 19, 28, 0.6); }
.fact .k { color: var(--text-3); font-size: 11px; letter-spacing: 0.07em; text-transform: uppercase; }
.fact .v { margin-top: 4px; font-size: 13.5px; }

.timeline { display: flex; flex-direction: column; }
.tl-day { padding: 11px 24px; border-bottom: 1px solid var(--line); color: var(--text-3); font-size: 11px; letter-spacing: 0.08em; text-transform: uppercase; background: rgba(255, 255, 255, 0.015); }
.tl-item { display: flex; align-items: flex-start; gap: 16px; padding: 15px 24px; border-bottom: 1px solid var(--line); }
.tl-item:last-child { border-bottom: 0; }
.tl-time { flex: none; width: 58px; color: var(--text-3); font-size: 12px; font-variant-numeric: tabular-nums; padding-top: 1px; line-height: 1.3; }
.tl-body { flex: 1; }
.tl-text { margin-top: 2px; }
.tl-body { min-width: 0; }
.tl-actor { font-size: 11px; letter-spacing: 0.07em; text-transform: uppercase; color: var(--accent); }
.tl-text { font-size: 13.5px; }
.tl-meta { color: var(--text-3); font-size: 11.5px; margin-top: 2px; }

.code-chip { font-family: var(--mono); font-size: 15px; letter-spacing: 3px; padding: 5px 11px; border-radius: 10px; background: rgba(110, 139, 255, 0.12); border: 1px solid rgba(110, 139, 255, 0.3); color: #dce3ff; }
.code-xl { display: inline-block; font-family: var(--mono); font-size: 40px; letter-spacing: 10px; padding: 14px 10px 14px 20px; border-radius: 16px; background: rgba(110, 139, 255, 0.1); border: 1px solid rgba(110, 139, 255, 0.28); color: #e7ecff; }
.countdown { font-variant-numeric: tabular-nums; font-family: var(--mono); font-size: 13px; }
.countdown.low { color: var(--warn); }
.countdown.out { color: var(--text-3); }

/* ---------- overlays ---------- */
.scrim { position: fixed; inset: 0; z-index: 40; background: rgba(4, 5, 9, 0.62); backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); display: grid; place-items: center; padding: 20px; animation: rise 0.18s ease both; }
.modal { width: 100%; max-width: 440px; border-radius: var(--r-lg); border: 1px solid var(--line-strong); background: rgba(19, 21, 31, 0.92); backdrop-filter: var(--blur); box-shadow: 0 40px 90px -30px #000; }
.modal-head { padding: 20px 22px 0; }
.modal-head h3 { margin: 0 0 4px; font-size: 17px; font-weight: 610; letter-spacing: -0.2px; }
.modal-head p { margin: 0; color: var(--text-2); font-size: 13px; }
.modal-body { padding: 18px 22px 4px; }
.modal-foot { display: flex; justify-content: flex-end; gap: 9px; padding: 16px 22px 20px; }
.drawer-scrim { position: fixed; inset: 0; z-index: 40; background: rgba(4, 5, 9, 0.55); backdrop-filter: blur(4px); animation: rise 0.18s ease both; }
.drawer { position: fixed; top: 0; right: 0; bottom: 0; z-index: 41; width: min(440px, 100%); overflow-y: auto; border-left: 1px solid var(--line-strong); background: rgba(16, 18, 27, 0.96); backdrop-filter: var(--blur); box-shadow: -30px 0 70px -30px #000; animation: rise 0.2s ease both; }
.drawer-head { display: flex; align-items: center; gap: 10px; padding: 18px 20px; border-bottom: 1px solid var(--line); }
.drawer-head h3 { margin: 0; font-size: 15px; font-weight: 600; }
.icon-btn { padding: 6px; border-radius: 9px; border: 0; background: transparent; color: var(--text-3); cursor: pointer; display: grid; place-items: center; }
.icon-btn:hover { background: var(--hover); color: var(--text); }
.drawer-body { padding: 18px 20px 30px; }
.note { margin-top: 14px; padding: 11px 13px; border-radius: var(--r-sm); border: 1px dashed var(--line-strong); color: var(--text-3); font-size: 12.5px; }

.toasts { position: fixed; z-index: 60; right: 18px; bottom: 18px; display: flex; flex-direction: column; gap: 9px; max-width: 340px; }
.toast { display: flex; align-items: center; gap: 10px; padding: 11px 14px; border-radius: 13px; border: 1px solid var(--line-strong); background: rgba(22, 25, 36, 0.95); backdrop-filter: var(--blur); box-shadow: var(--shadow); font-size: 13px; animation: rise 0.22s ease both; }
.toast .icon { flex: none; }
.toast.ok .icon { color: var(--ok); }
.toast.err .icon { color: var(--danger); }
.palette { width: 100%; max-width: 520px; align-self: start; margin-top: 12vh; border-radius: var(--r-lg); border: 1px solid var(--line-strong); background: rgba(19, 21, 31, 0.95); backdrop-filter: var(--blur); box-shadow: 0 40px 90px -30px #000; overflow: hidden; }
.palette input { border: 0; border-radius: 0; border-bottom: 1px solid var(--line); background: transparent; padding: 16px 18px; font-size: 15px; }
.palette input:focus { box-shadow: none; border-color: var(--line); }
.palette-results { max-height: 320px; overflow-y: auto; }

.skeleton { height: 54px; border-bottom: 1px solid var(--line); background: linear-gradient(90deg, rgba(255,255,255,0.02), rgba(255,255,255,0.05), rgba(255,255,255,0.02)); background-size: 200% 100%; animation: shimmer 1.2s linear infinite; }
@keyframes shimmer { to { background-position: -200% 0; } }

/* ---------- responsive ---------- */
@media (max-width: 1100px) {
  /* minmax(0,…): una fila larga nunca ensancha la página (causaba scroll lateral). */
  .grid-2 { grid-template-columns: minmax(0, 1fr); }
  .cell-w { width: 120px; }
}
@media (max-width: 900px) {
  :root { --sidebar: 76px; }
  .sidebar { padding: 18px 12px; align-items: center; }
  .sidebar .brand-text, .nav-item span.label, .admin-chip .meta, .sidebar-foot .btn span { display: none; }
  .nav-item { justify-content: center; padding: 11px; }
  .nav-badge { position: absolute; margin: 0; transform: translate(14px, -12px); }
  .nav-item { position: relative; }
  .admin-chip { justify-content: center; }
  .content { padding: 20px 18px 50px; }
  .topbar { padding: 14px 18px; }
}
@media (max-width: 640px) {
  .shell { grid-template-columns: 1fr; }
  .sidebar { position: fixed; inset: 0 auto 0 0; z-index: 30; width: 250px; transform: translateX(-100%); transition: transform 0.22s ease; align-items: stretch; padding: 20px 14px; }
  .sidebar.open { transform: none; }
  .sidebar .brand-text, .nav-item span.label, .admin-chip .meta, .sidebar-foot .btn span { display: block; }
  .nav-item { justify-content: flex-start; padding: 10px 11px; }
  .nav-badge { position: static; transform: none; margin-left: auto; }
  .menu-btn { display: grid; }
  .cell-w, .cell-w-sm, .hide-sm { display: none; }
  .content { padding: 18px 14px 50px; }
  .toasts { left: 14px; right: 14px; max-width: none; }
}
@media (prefers-reduced-motion: reduce) { * { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; } }

/* ---------- WF LINK (FASE 2) ---------- */
.pill-violet { background: rgba(155, 123, 255, 0.16); color: #c3aeff; }
.code-chip-sm { font-size: 12px; letter-spacing: 2px; padding: 2px 7px; }

/* Solicitudes que esperan decisión: prioridad visual, sin arcoíris. */
.list-row.priority { background: linear-gradient(90deg, rgba(155, 123, 255, 0.09), transparent 60%); box-shadow: inset 2px 0 0 var(--accent-2); }
.list-row.priority:hover { background: linear-gradient(90deg, rgba(155, 123, 255, 0.14), rgba(255, 255, 255, 0.03) 60%); }

.code-search { display: flex; align-items: center; gap: 10px; padding: 5px 14px 5px 12px; border-radius: 13px; border: 1px solid rgba(110, 139, 255, 0.28); background: rgba(110, 139, 255, 0.07); }
.code-search .icon { color: var(--accent); flex: none; }
.code-search-label { color: var(--text-2); font-size: 12.5px; white-space: nowrap; }
.code-input { width: 104px; padding: 7px 10px; border-radius: 9px; border: 1px solid var(--line); background: rgba(8, 10, 16, 0.6); font-family: var(--mono); font-size: 16px; letter-spacing: 4px; text-align: center; }

.live-dot { display: inline-flex; align-items: center; gap: 7px; color: var(--text-3); font-size: 12px; }
.live-dot i { width: 7px; height: 7px; border-radius: 50%; background: var(--ok); box-shadow: 0 0 0 0 rgba(79, 209, 161, 0.5); animation: live 2.2s ease-out infinite; }
@keyframes live { 0% { box-shadow: 0 0 0 0 rgba(79, 209, 161, 0.5); } 70% { box-shadow: 0 0 0 7px rgba(79, 209, 161, 0); } 100% { box-shadow: 0 0 0 0 rgba(79, 209, 161, 0); } }

.link-user { margin-top: 18px; padding: 16px; border-radius: var(--r); border: 1px solid var(--line); background: var(--surface-2); }
.link-user .field { margin-bottom: 0; }
.link-user-tag { margin-bottom: 12px; font-size: 11px; letter-spacing: 0.1em; text-transform: uppercase; }
.link-user.existing { border-color: rgba(79, 209, 161, 0.3); }
.link-user.existing .link-user-tag { color: var(--ok); }
.link-user.nuevo { border-color: rgba(155, 123, 255, 0.32); }
.link-user.nuevo .link-user-tag { color: var(--accent-2); }
.drawer-actions { margin-top: 20px; gap: 10px; }

/* ---------- Reproduciendo ahora / incidencias (FASE 3C-lite) ---------- */
/* Fila con carátula. Alto total = 111 px, igual que la fila anterior: la
   tarjeta "Reproduciendo ahora" conserva exactamente su tamaño. */
.play-row { display: flex; align-items: flex-start; gap: 16px; height: 111px; padding: 13px 24px; border-bottom: 1px solid var(--line); }
.play-row:last-child { border-bottom: 0; }
.play-glyph { flex: none; display: grid; place-items: center; width: 34px; height: 34px; border-radius: 11px; font-size: 14px; border: 1px solid var(--line); background: var(--surface-2); color: var(--text-3); }
.play-glyph.stopped { color: var(--text-3); }
.play-body { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.play-title { font-size: 14.5px; line-height: 18px; font-weight: 620; letter-spacing: -0.1px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.play-user { align-self: flex-start; max-width: 100%; padding: 0; border: 0; background: none; color: var(--text); font: inherit; font-size: 13px; line-height: 17px; font-weight: 520; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; cursor: pointer; transition: color 0.14s; }
button.play-user:hover, button.play-user:focus-visible { color: #c9d3ff; }
div.play-user { cursor: default; }
.play-line { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; font-size: 12px; line-height: 16px; color: var(--text-3); }
.play-device { min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.play-time { flex: none; font-size: 11.5px; color: var(--text-2); letter-spacing: 0.02em; }
.play-progress { height: 3px; margin: 4px 0 6px; border-radius: 99px; background: rgba(255, 255, 255, 0.075); overflow: hidden; }
.play-progress-fill { display: block; height: 100%; width: 0; border-radius: 99px; background: linear-gradient(90deg, rgba(91, 124, 255, 0.85), #8f6bff); transition: width 0.6s ease; }
.play-meta { display: flex; align-items: center; gap: 6px; min-width: 0; white-space: nowrap; overflow: hidden; }
.play-ago { margin-left: 4px; font-size: 11.5px; color: var(--text-3); }
.media-ep { font-weight: 480; color: var(--text-2); }

/* Pills discretos: fondo neutro; el color solo va en un punto pequeño. */
.chip { display: inline-flex; align-items: center; gap: 6px; height: 19px; padding: 0 8px; border-radius: 999px; font-size: 11px; font-weight: 560; line-height: 1; letter-spacing: 0.01em; color: var(--text-2); background: rgba(255, 255, 255, 0.05); box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.06); white-space: nowrap; }
.chip i { width: 5px; height: 5px; border-radius: 50%; background: var(--text-3); }
.chip.playing i { background: var(--ok); }
.chip.paused i { background: var(--warn); }
.chip.buffering i { background: var(--info); }
.chip.end-ended i { background: var(--ok); }
.chip.end-stopped i { background: var(--text-3); }
.chip.end-timeout i { background: var(--warn); }

/* Carátulas pequeñas (2:3), con placeholder del mismo tamaño. */
.poster { flex: none; display: block; position: relative; overflow: hidden; border-radius: 8px; background: linear-gradient(160deg, #1c2030 0%, #0f1119 100%); box-shadow: 0 8px 18px -10px rgba(0, 0, 0, 0.9), inset 0 0 0 1px rgba(255, 255, 255, 0.07); }
.poster img { display: block; width: 100%; height: 100%; object-fit: cover; }
.poster-md { width: 54px; height: 81px; }
.poster-sm { width: 36px; height: 54px; border-radius: 6px; }
.poster-ph { display: grid; place-items: center; width: 100%; height: 100%; color: var(--text-3); }
.poster-ph .icon { width: 42%; height: 42%; opacity: 0.55; }

/* Historial de hoy: filas horizontales compactas. */
.hist-row { display: flex; align-items: center; gap: 14px; width: 100%; padding: 11px 24px; border: 0; border-bottom: 1px solid var(--line); background: none; color: inherit; font: inherit; text-align: left; transition: background 0.14s; }
.hist-row:last-child { border-bottom: 0; }
button.hist-row { cursor: pointer; }
.hist-row:hover, .hist-row:focus-visible { background: var(--hover); outline: none; box-shadow: inset 2px 0 0 rgba(110, 139, 255, 0.55); }
.hist-body { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.hist-title { font-size: 13.5px; line-height: 17px; font-weight: 580; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.hist-who { font-size: 12px; line-height: 16px; color: var(--text-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.hist-meta { display: flex; align-items: center; flex-wrap: wrap; gap: 4px 7px; margin-top: 3px; font-size: 11.5px; line-height: 19px; color: var(--text-3); }
.hist-meta .mono { font-size: 11px; color: var(--text-2); }
.hist-meta .sep { opacity: 0.5; }
.hist-list .hist-row { padding: 10px 2px; }
.hist-drawer-sub { margin: 0 0 8px; color: var(--text-3); font-size: 12.5px; }
.hist-drawer-head { display: flex; align-items: center; justify-content: space-between; margin: 18px 0 2px; font-size: 11px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--text-3); }
.hist-empty { margin: 8px 0 4px; font-size: 12.5px; }
.section-title-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.section-title-row .btn { text-transform: none; letter-spacing: 0; }
.incident-glyph { flex: none; display: grid; place-items: center; width: 34px; height: 34px; border-radius: 11px; color: var(--warn); background: var(--warn-soft); border: 1px solid rgba(240, 179, 90, 0.3); }
.incident-row .primary-text { display: flex; align-items: center; gap: 8px; }
.tag-test { background: rgba(155, 123, 255, 0.16); color: #c3aeff; font-size: 10.5px; letter-spacing: 0.06em; }
.incident-desc { margin: 14px 0 16px; color: var(--text); font-size: 14px; }
.device-play { display: flex; align-items: center; gap: 12px; margin: 14px 0 4px; padding: 12px 14px; border-radius: var(--r); border: 1px solid var(--line); background: var(--surface-2); }
.device-play .primary-text { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.device-play.active { border-color: rgba(79, 209, 161, 0.3); }
.card-head .live-dot { margin-right: -4px; }

/* Confirmación de activación dentro del propio modal, antes de cerrarse. */
.link-success { display: grid; place-items: center; gap: 8px; padding: 54px 20px; text-align: center; animation: rise 0.25s ease both; }
.link-success-mark { display: grid; place-items: center; width: 56px; height: 56px; margin-bottom: 6px; border-radius: 50%; background: var(--ok-soft); border: 1px solid rgba(79, 209, 161, 0.35); color: var(--ok); }
.link-success-mark .icon { width: 26px; height: 26px; stroke-width: 2.2; }
.link-success-title { font-size: 12px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--ok); }
.link-success-name { font-size: 19px; font-weight: 620; letter-spacing: -0.3px; }

.toast-body { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.toast-title { font-weight: 570; }
.toast-sub { display: flex; align-items: center; gap: 8px; color: var(--text-2); font-size: 12.5px; }
.toast.link { border-color: rgba(155, 123, 255, 0.4); }
.toast.link .icon { color: var(--accent-2); }

/* ---------------- Biblioteca editorial (orden, oculto, retirado) ---------------- */
.lib-head { margin-bottom: 18px; align-items: center; gap: 14px; }
.note-inline { margin: 0; padding: 7px 12px; font-size: 12px; }
.lib-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 20px; }
.lib-card { display: flex; flex-direction: column; gap: 0; padding: 0; overflow: hidden; text-align: left; cursor: pointer; border: 1px solid var(--line); border-radius: var(--r-lg); background: var(--surface); backdrop-filter: var(--blur); box-shadow: var(--shadow); color: inherit; font: inherit; transition: transform 0.16s, border-color 0.16s, box-shadow 0.16s; }
.lib-card:hover, .lib-card:focus-visible { transform: translateY(-2px); border-color: var(--line-strong); box-shadow: 0 30px 60px -30px rgba(0, 0, 0, 0.9); outline: none; }
.lib-collage { position: relative; display: flex; height: 132px; gap: 2px; padding: 12px 12px 0; overflow: hidden; background: linear-gradient(180deg, rgba(110, 139, 255, 0.08), transparent); }
.lib-collage-item { flex: 1; min-width: 0; border-radius: 9px 9px 0 0; overflow: hidden; box-shadow: 0 10px 22px -14px #000; }
.lib-collage-item img { width: 100%; height: 100%; object-fit: cover; display: block; }
.lib-collage-item.i1 { margin-top: 10px; } .lib-collage-item.i2 { margin-top: 20px; } .lib-collage-item.i3 { margin-top: 30px; }
.lib-body { display: flex; flex-direction: column; gap: 6px; padding: 16px 18px 18px; }
.lib-name { font-size: 16px; font-weight: 640; letter-spacing: -0.2px; }
.lib-counts { display: flex; align-items: center; flex-wrap: wrap; gap: 6px; font-size: 12.5px; color: var(--text-2); }
.lib-foot { font-size: 12px; color: var(--text-3); }

.lib-toolbar { flex-wrap: wrap; gap: 10px; }
.lib-toolbar input[type="search"] { width: 190px; padding: 7px 11px; font-size: 13px; }
.lib-toolbar .segmented button { padding: 6px 12px; font-size: 12.5px; }
.sel-bar:not(:empty) { display: flex; align-items: center; gap: 12px; padding: 12px 24px; border-bottom: 1px solid var(--line); background: rgba(110, 139, 255, 0.06); }

.poster-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(132px, 1fr)); gap: 18px; padding: 22px 24px 26px; }
.poster-card { position: relative; display: flex; flex-direction: column; gap: 8px; cursor: grab; transition: transform 0.16s, opacity 0.16s; }
.poster-card:active { cursor: grabbing; }
.poster-card:hover { transform: translateY(-3px); }
.poster-card.dragging { opacity: 0.35; }
.poster-card.drop-target { transform: translateX(6px); }
.poster-card.drop-target::before { content: ""; position: absolute; left: -9px; top: 0; bottom: 30px; width: 3px; border-radius: 3px; background: var(--accent); box-shadow: 0 0 12px var(--accent); }
.poster-grid-item { width: 100%; aspect-ratio: 2 / 3; height: auto; border-radius: 12px; }
.poster-grid-item img { width: 100%; height: 100%; object-fit: cover; }
.poster-card.is-hidden .poster-grid-item, .poster-card.is-removed .poster-grid-item { opacity: 0.38; filter: grayscale(0.6); }
.poster-card.is-selected .poster-grid-item { box-shadow: 0 0 0 3px var(--accent), 0 8px 18px -10px #000; }
.poster-card.is-pinned .poster-grid-item { box-shadow: inset 0 0 0 1px rgba(232, 196, 106, 0.55), 0 8px 18px -10px #000; }
.poster-pin { position: absolute; top: 8px; left: 8px; min-width: 22px; height: 22px; padding: 0 6px; display: grid; place-items: center; border-radius: 8px; background: linear-gradient(135deg, #ffd568, #b68117); color: #1a1305; font-size: 11.5px; font-weight: 700; }
.poster-flag { position: absolute; top: 8px; right: 8px; padding: 2px 8px; border-radius: 999px; background: rgba(10, 12, 18, 0.82); color: var(--text-2); font-size: 10px; font-weight: 640; letter-spacing: 0.08em; }
.poster-flag.removed { background: rgba(255, 107, 129, 0.2); color: #ffc2cc; }
.poster-meta { display: flex; flex-direction: column; gap: 1px; min-width: 0; }
.poster-title { font-size: 12.5px; font-weight: 560; line-height: 16px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.poster-year { font-size: 11.5px; color: var(--text-3); }
.poster-menu { position: absolute; right: 6px; bottom: 34px; width: 28px; height: 28px; display: grid; place-items: center; border: 0; border-radius: 50%; background: rgba(10, 12, 18, 0.72); color: var(--text); font-size: 15px; line-height: 1; cursor: pointer; opacity: 0; transition: opacity 0.14s; }
.poster-card:hover .poster-menu, .poster-menu:focus-visible { opacity: 1; }
.poster-md { width: 96px; height: 144px; }

.preview-list { display: flex; flex-direction: column; }
.preview-row { display: flex; align-items: center; gap: 12px; padding: 9px 0; border-bottom: 1px solid var(--line); }
.preview-row:last-child { border-bottom: 0; }
.preview-num { width: 26px; flex: none; font-family: var(--mono); font-size: 12px; color: var(--text-3); text-align: right; }

/* Menú del clic derecho sobre una carátula */
.ctx-menu { position: fixed; z-index: 60; min-width: 250px; padding: 6px; border-radius: 14px; border: 1px solid var(--line-strong); background: rgba(19, 21, 31, 0.96); backdrop-filter: var(--blur); -webkit-backdrop-filter: var(--blur); box-shadow: 0 24px 60px -18px #000; animation: rise 0.12s ease both; }
.ctx-title { padding: 8px 10px 7px; font-size: 11.5px; color: var(--text-3); letter-spacing: 0.02em; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 280px; }
.ctx-item { position: relative; display: flex; align-items: center; gap: 10px; width: 100%; padding: 8px 10px; border: 0; border-radius: 9px; background: none; color: var(--text); font: inherit; font-size: 13px; text-align: left; cursor: pointer; }
.ctx-item:hover, .ctx-item:focus-visible, .ctx-has-sub:focus-within { background: var(--hover); outline: none; }
.ctx-item .icon { width: 15px; height: 15px; color: var(--text-2); flex: none; }
.ctx-spacer { width: 15px; flex: none; }
.ctx-item.danger { color: #ff9aaa; }
.ctx-item.danger .icon { color: #ff9aaa; }
.ctx-arrow { margin-left: auto; color: var(--text-3); font-size: 16px; line-height: 1; }
.ctx-sep { height: 1px; margin: 5px 6px; background: var(--line); }
.ctx-sub { display: none; position: absolute; top: -6px; left: calc(100% + 4px); min-width: 220px; padding: 6px; border-radius: 14px; border: 1px solid var(--line-strong); background: rgba(19, 21, 31, 0.97); box-shadow: 0 24px 60px -18px #000; }
.ctx-menu.sub-left .ctx-sub { left: auto; right: calc(100% + 4px); }
.ctx-has-sub:hover > .ctx-sub, .ctx-has-sub:focus-within > .ctx-sub { display: block; }
.ctx-empty { padding: 8px 10px; font-size: 12.5px; color: var(--text-3); }
.poster-flag.moved { background: rgba(110, 139, 255, 0.28); color: #d6ddff; }
.ctx-hint { margin-top: 12px; font-size: 12px; }


/* =====================================================================
   RESPONSIVE — celular y tableta: cómodo, táctil y sin scroll lateral
   ===================================================================== */
.nav-scrim { display: none; }
html, body { max-width: 100%; overflow-x: hidden; }
img { max-width: 100%; }

@media (hover: none) {
  /* Sin cursor no hay "pasar por encima": acciones siempre visibles. */
  .poster-menu { opacity: 1; }
  .poster-card:hover { transform: none; }
  .lib-card:hover { transform: none; }
}

/* ---------- tableta (≤ 900 px) ---------- */
@media (max-width: 900px) {
  .grid-kpi { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; margin-bottom: 20px; }
  .lib-grid { grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 16px; }
  .lib-toolbar .right { width: 100%; justify-content: flex-start; }
  .lib-toolbar input[type="search"] { flex: 1 1 200px; width: auto; }
  .poster-grid { grid-template-columns: repeat(auto-fill, minmax(118px, 1fr)); gap: 14px; padding: 18px; }
}

/* ---------- celular (≤ 640 px) ---------- */
@media (max-width: 640px) {
  .nav-scrim { display: block; position: fixed; inset: 0; z-index: 29; background: rgba(3, 4, 8, 0.6); backdrop-filter: blur(3px); opacity: 0; pointer-events: none; transition: opacity 0.2s ease; }
  .nav-scrim.show { opacity: 1; pointer-events: auto; }
  body.nav-locked { overflow: hidden; }
  .sidebar { box-shadow: 30px 0 60px -30px #000; }
  .nav-item { min-height: 44px; }

  .topbar { padding: 10px 14px; gap: 10px; }
  .topbar h1 { font-size: 17px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .topbar .crumb { font-size: 11.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; display: block; }
  .topbar > div:nth-child(2) { min-width: 0; flex: 1; }

  .hello { font-size: 22px; }
  .hello-sub { margin-bottom: 18px; }

  /* Cifras del inicio: 2 por fila, compactas. */
  .grid-kpi { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .kpi { padding: 14px 14px 13px; min-height: 0; }
  .kpi .label { font-size: 11.5px; }
  .kpi .value { font-size: 26px; margin: 4px 0 2px; }
  .kpi .foot { font-size: 11px; }

  .grid, .grid-2 { gap: 16px; }
  .grid-2 > .grid { gap: 16px; }
  .card { border-radius: 18px; }
  .card-head { padding: 14px 16px; flex-wrap: wrap; row-gap: 8px; }
  .card-head h2 { font-size: 15px; }
  .list-row, .hist-row, .play-row, .tl-item { padding-left: 16px; padding-right: 16px; }
  .play-row { gap: 12px; }
  .col-sticky { position: static; max-height: none; }
  .card-scroll { max-height: 420px; }

  /* Formularios: 16 px evita el zoom automático de iOS al escribir. */
  input, select, textarea { font-size: 16px; }

  .drawer { width: 100%; border-left: 0; }
  .drawer-body { padding: 16px 16px 40px; }
  .drawer-actions .btn { flex: 1 1 auto; }
  .modal { max-width: none; margin: 0 10px; }
  .facts { grid-template-columns: 1fr 1fr; }

  /* Biblioteca */
  .lib-head { margin-bottom: 14px; }
  .lib-grid { grid-template-columns: minmax(0, 1fr); gap: 14px; }
  .lib-collage { height: 104px; }
  .lib-toolbar { padding: 14px 16px; }
  .lib-toolbar .right { gap: 8px; }
  .lib-toolbar input[type="search"] { flex: 1 1 100%; }
  .lib-toolbar .segmented { width: 100%; overflow-x: auto; scrollbar-width: none; }
  .lib-toolbar .segmented::-webkit-scrollbar { display: none; }
  .lib-toolbar .segmented button { flex: 1 0 auto; }
  .lib-toolbar .right > .btn { flex: 1 1 auto; }
  .poster-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; padding: 14px 12px 20px; }
  .poster-title { font-size: 11.5px; }
  .poster-year { font-size: 10.5px; }
  .poster-menu { width: 30px; height: 30px; right: 4px; bottom: 30px; }
  .poster-card { -webkit-touch-callout: none; user-select: none; }
  .sel-bar:not(:empty) { flex-wrap: wrap; padding: 10px 14px; }

  /* Menú de acciones como hoja inferior, cómodo para el pulgar. */
  .ctx-scrim { position: fixed; inset: 0; z-index: 59; background: rgba(3, 4, 8, 0.55); animation: rise 0.15s ease both; }
  .ctx-menu.ctx-sheet { left: 8px !important; right: 8px; top: auto !important; bottom: 8px; min-width: 0; max-height: 78vh; overflow-y: auto; border-radius: 18px; padding: 8px 8px calc(8px + env(safe-area-inset-bottom)); }
  .ctx-sheet .ctx-item { min-height: 46px; font-size: 15px; }
  .ctx-sheet .ctx-title { max-width: none; font-size: 12.5px; }
  .ctx-sheet .ctx-sub { position: static; display: none; margin: 4px 0 4px 26px; min-width: 0; box-shadow: none; border-radius: 12px; background: rgba(255, 255, 255, 0.03); }
  .ctx-sheet .ctx-has-sub { flex-wrap: wrap; }
  .ctx-sheet .ctx-has-sub.open > .ctx-sub { display: block; flex-basis: 100%; }
  .ctx-sheet .ctx-has-sub:hover > .ctx-sub { display: none; }
  .ctx-sheet .ctx-has-sub.open:hover > .ctx-sub { display: block; }
}

/* ---------- celulares pequeños (≤ 380 px) ---------- */
@media (max-width: 380px) {
  .poster-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .kpi .value { font-size: 23px; }
}
@media (max-width: 640px) {
  .empty { padding: 30px 18px; gap: 8px; }
  .empty strong { font-size: 13px; }
}
.ctx-arrow { transition: transform 0.15s ease; }
.ctx-has-sub.open .ctx-arrow { transform: rotate(90deg); }

/* ---------- WF Conversion Engine ---------- */
.conv-heading { display:flex; align-items:flex-end; justify-content:space-between; gap:22px; margin-bottom:22px; }
.conv-heading h2 { margin:3px 0 4px; font-size:26px; letter-spacing:-.6px; }
.conv-heading p { margin:0; }
.eyebrow { color:var(--accent); font-size:10.5px; font-weight:700; letter-spacing:.17em; }
.agent-state { display:flex; align-items:center; gap:8px; padding:8px 12px; border:1px solid var(--line); border-radius:999px; background:var(--surface-2); color:var(--text-2); font-size:12px; white-space:nowrap; }
.agent-dot { width:8px; height:8px; border-radius:50%; background:var(--text-3); }
.agent-dot.online { background:var(--ok); box-shadow:0 0 12px var(--ok); }
.agent-dot.offline { background:var(--danger); }
.conv-tabs { margin-bottom:20px; overflow-x:auto; max-width:100%; }
.conv-tabs button { min-width:105px; letter-spacing:.06em; font-size:11.5px; font-weight:650; }
.conv-body { display:grid; gap:18px; }
.conv-hero { position:relative; display:grid; grid-template-columns:180px minmax(0,1fr); gap:28px; padding:26px; overflow:hidden; }
.conv-hero::after { content:""; position:absolute; width:360px; height:360px; right:-150px; top:-210px; border-radius:50%; background:rgba(110,139,255,.16); filter:blur(55px); pointer-events:none; }
.conv-art { flex:none; display:grid; place-items:center; width:48px; height:66px; border-radius:11px; border:1px solid var(--line); background:linear-gradient(145deg,#22283b,#11131c); color:var(--text-3); }
.conv-art .icon { width:22px; height:22px; }
.conv-art { overflow:hidden; position:relative; }
.conv-art.has-img { background:#0b0d14; }
.conv-art img { width:100%; height:100%; object-fit:cover; display:block; }
.conv-hero > .conv-art.has-img { background:#0b0d14; box-shadow:0 24px 48px -24px rgba(0,0,0,.75); }
.list-row .conv-art { width:36px; height:52px; border-radius:8px; }
.conv-hero > .conv-art { width:180px; height:255px; border-radius:18px; background:radial-gradient(circle at 35% 25%,rgba(110,139,255,.35),transparent 42%),linear-gradient(145deg,#242941,#10121a); }
.conv-hero > .conv-art .icon { width:45px; height:45px; color:#aebcff; }
.conv-current { min-width:0; position:relative; z-index:1; padding-top:4px; }
.conv-agent-alert { display:grid; gap:2px; margin:0 0 14px; padding:10px 12px; border:1px solid var(--line); border-radius:11px; font-size:12px; line-height:1.45; }
.conv-agent-alert strong { font-size:12px; }
.conv-agent-alert span { color:var(--text-2); }
.conv-agent-alert.danger { border-color:rgba(255,91,115,.35); background:var(--danger-soft); }
.conv-agent-alert.danger strong { color:#ff9aaa; }
.conv-agent-alert.warn { border-color:rgba(255,190,79,.32); background:var(--warn-soft); }
.conv-agent-alert.warn strong { color:var(--warn); }
.conv-current h3 { margin:10px 0 2px; font-size:24px; letter-spacing:-.5px; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.conv-current > p { margin:0 0 22px; }
.conv-live { display:flex; align-items:center; gap:8px; color:#bfc9ff; font-size:11px; font-weight:750; letter-spacing:.12em; }
.conv-live i { width:7px; height:7px; border-radius:50%; background:var(--accent); box-shadow:0 0 12px var(--accent); }
.conv-progress { display:block; width:100%; height:7px; overflow:hidden; border:0; border-radius:999px; background:rgba(255,255,255,.07); }
.conv-progress::-webkit-progress-bar { background:rgba(255,255,255,.07); border-radius:999px; }
.conv-progress::-webkit-progress-value { background:var(--accent-grad); border-radius:999px; }
.conv-progress::-moz-progress-bar { background:var(--accent); border-radius:999px; }
.conv-progress-meta { display:flex; justify-content:space-between; margin-top:7px; color:var(--text-3); font-size:11.5px; font-variant-numeric:tabular-nums; }
.conv-metrics { display:grid; grid-template-columns:repeat(5,minmax(90px,1fr)); gap:9px; margin-top:20px; }
.conv-metric { padding:10px 12px; border:1px solid var(--line); border-radius:11px; background:rgba(255,255,255,.025); }
.conv-metric span { display:block; color:var(--text-3); font-size:10px; text-transform:uppercase; letter-spacing:.07em; }
.conv-metric strong { display:block; margin-top:3px; font-size:13px; font-weight:620; white-space:nowrap; }
.conv-controls { display:flex; flex-wrap:wrap; gap:9px; margin-top:20px; }
.queue-rank { width:30px; height:30px; display:grid; place-items:center; border-radius:9px; background:var(--accent-soft); color:#dbe1ff; font-size:12px; font-weight:700; }
.conv-list,.conv-files { display:flex; flex-direction:column; }
.conv-row,.conv-file { display:flex; align-items:center; gap:14px; padding:14px 20px; border-bottom:1px solid var(--line); }
.conv-row:last-child,.conv-file:last-child { border-bottom:0; }
.conv-badges { display:flex; flex-wrap:wrap; gap:6px; margin-top:7px; }
.conv-badges .chip.ok,.chip.ok { background:var(--ok-soft); color:var(--ok); }
.conv-badges .chip.warn,.chip.warn { background:var(--warn-soft); color:var(--warn); }
.conv-badges .chip.danger,.chip.danger { background:var(--danger-soft); color:#ff9aaa; }
.conv-explorer { display:grid; grid-template-columns:230px minmax(0,1fr); gap:18px; align-items:start; }
.conv-folders { display:flex; flex-direction:column; padding:7px; border:1px solid var(--line); border-radius:16px; background:var(--surface); }
.conv-folders button { display:flex; justify-content:space-between; gap:10px; width:100%; padding:10px 11px; border:0; border-radius:10px; background:transparent; color:var(--text-2); text-align:left; cursor:pointer; }
.conv-folders button:hover { background:var(--hover); color:var(--text); }
.conv-folders button.active { background:var(--accent-soft); color:#e3e7ff; }
.conv-folders small { color:var(--text-3); }
.conv-file .pill { margin-top:6px; }
.conv-history-tools { justify-content:space-between; margin-bottom:0; }
.conv-history-tools select { width:auto; min-width:190px; padding:7px 10px; }

@media (max-width:900px) {
  .conv-hero { grid-template-columns:120px minmax(0,1fr); padding:20px; gap:20px; }
  .conv-hero > .conv-art { width:120px; height:180px; }
  .conv-metrics { grid-template-columns:repeat(3,1fr); }
  .conv-explorer { grid-template-columns:1fr; }
  .conv-folders { flex-direction:row; overflow-x:auto; }
  .conv-folders button { flex:0 0 auto; width:auto; }
}

@media (max-width:640px) {
  .conv-heading { align-items:flex-start; flex-direction:column; }
  .conv-heading h2 { font-size:22px; }
  .agent-state { white-space:normal; }
  .conv-tabs { display:flex; width:100%; }
  .conv-tabs button { min-width:92px; flex:1 0 auto; }
  .conv-hero { grid-template-columns:74px minmax(0,1fr); gap:14px; padding:16px; }
  .conv-hero > .conv-art { width:74px; height:110px; border-radius:13px; }
  .conv-current h3 { font-size:18px; }
  .conv-current > p { margin-bottom:14px; }
  .conv-metrics { grid-column:1/-1; grid-template-columns:repeat(2,1fr); }
  .conv-controls { grid-column:1/-1; }
  .conv-controls .btn { flex:1 1 90px; }
  .conv-row,.conv-file { padding:12px 14px; align-items:flex-start; }
  .conv-row .conv-art,.conv-file .conv-art { width:40px; height:56px; }
  .conv-file { flex-wrap:wrap; }
  .conv-file > .btn { margin-left:54px; width:calc(100% - 54px); }
  .conv-history-tools { align-items:stretch; }
  .conv-history-tools .segmented { width:100%; overflow-x:auto; }
  .conv-history-tools select { width:100%; }
}

/* ---------- Cambiar carátula / imagen de fondo ---------- */
.art-editor { display:flex; gap:18px; align-items:flex-start; }
.art-preview { flex:none; display:grid; place-items:center; overflow:hidden; border-radius:14px; border:1px solid var(--line); background:linear-gradient(145deg,#191d2b,#0d0f16); }
.art-preview img { width:100%; height:100%; object-fit:cover; display:block; }
.art-preview.art-vertical { width:190px; height:285px; }
.art-preview.art-panoramica { width:300px; height:169px; }
.art-empty { display:grid; justify-items:center; gap:6px; color:var(--text-3); font-size:12.5px; }
.art-empty .icon { width:26px; height:26px; }
.art-side { flex:1 1 auto; min-width:0; display:flex; flex-direction:column; gap:10px; }
.art-pick { position:relative; overflow:hidden; cursor:pointer; align-self:flex-start; }
.art-file { position:absolute; inset:0; opacity:0; cursor:pointer; font-size:0; }
.art-note { margin:0; font-size:12.5px; line-height:1.5; color:var(--text-3); }
.art-own { color:var(--text-2); }

@media (max-width: 640px) {
  .art-editor { flex-direction:column; align-items:center; }
  .art-preview.art-panoramica { width:100%; height:auto; aspect-ratio:16/9; }
  .art-side { width:100%; }
}

/* ---------- Carátulas sugeridas (búsqueda automática) ---------- */
.art-suggest { margin-top:18px; border-top:1px solid var(--line); padding-top:14px; }
.art-suggest-head { display:flex; align-items:center; justify-content:space-between; gap:12px; margin-bottom:6px; }
.art-suggest-head h4 { margin:0; font-size:14px; letter-spacing:.2px; }
.art-gallery { display:grid; grid-template-columns:repeat(auto-fill,minmax(96px,1fr)); gap:10px; max-height:280px; overflow-y:auto; padding:2px; }
.art-option { padding:0; border:1px solid var(--line); border-radius:10px; overflow:hidden; background:#0d0f16; cursor:pointer; aspect-ratio:2/3; transition:transform .12s ease, border-color .12s ease; }
.art-option img { width:100%; height:100%; object-fit:cover; display:block; }
.art-option:hover { transform:translateY(-2px); border-color:var(--accent,#6e8bff); }
.art-option.is-selected { border-color:var(--accent,#6e8bff); box-shadow:0 0 0 2px rgba(110,139,255,.45); }
.art-suggest.art-wide .art-gallery { grid-template-columns:repeat(auto-fill,minmax(168px,1fr)); }
.art-suggest.art-wide .art-option { aspect-ratio:16/9; }

@media (max-width: 640px) {
  .art-gallery { grid-template-columns:repeat(auto-fill,minmax(80px,1fr)); max-height:220px; }
}

/* La ventana de imágenes necesita más ancho: carátula grande + galería. */
.modal:has(.art-editor) { max-width: 760px; }
.art-option { position:relative; }
.art-option-tag { position:absolute; left:0; right:0; bottom:0; padding:4px 5px; font-size:10px; line-height:1.2; text-align:left; color:#fff; background:linear-gradient(transparent,rgba(0,0,0,.85)); opacity:0; transition:opacity .12s ease; pointer-events:none; }
.art-option:hover .art-option-tag, .art-option.is-selected .art-option-tag { opacity:1; }

.art-fix { display:flex; align-items:center; gap:8px; font-size:12.5px; color:var(--text-2); cursor:pointer; }
.art-fix input { accent-color:var(--accent,#6e8bff); width:15px; height:15px; }

/* 2026-09-26: "Reproduciendo ahora" en vidrio líquido; la carátula siempre dentro. */
.card-glass { position: relative; overflow: hidden; border-radius: 22px; border: 1px solid rgba(255,255,255,0.14);
  background: linear-gradient(155deg, rgba(255,255,255,0.10) 0%, rgba(255,255,255,0.035) 45%, rgba(255,255,255,0.06) 100%), rgba(18,20,30,0.55);
  backdrop-filter: blur(22px) saturate(160%); -webkit-backdrop-filter: blur(22px) saturate(160%);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.22), inset 0 -1px 0 rgba(255,255,255,0.05), 0 18px 40px -18px rgba(0,0,0,0.75); }
.card-glass::before { content: ''; position: absolute; inset: 0 0 auto 0; height: 46%; pointer-events: none;
  background: linear-gradient(180deg, rgba(255,255,255,0.08), rgba(255,255,255,0)); }
.card-glass > * { position: relative; }
.card-glass .play-row { align-items: center; height: auto; min-height: 111px; padding: 14px 20px; overflow: hidden; border-bottom-color: rgba(255,255,255,0.07); }
.card-glass .play-row .poster { align-self: center; border-radius: 10px; box-shadow: 0 6px 14px -8px rgba(0,0,0,0.9), inset 0 0 0 1px rgba(255,255,255,0.14); }

/* 2026-09-26: detalle premium de "Reproduciendo ahora" en las mismas 5 líneas. */
.card-glass .play-top { display: flex; align-items: baseline; gap: 10px; min-width: 0; }
.card-glass .play-top .play-title { flex: 1; min-width: 0; }
.card-glass .play-top .play-ago { flex: none; margin: 0; font-size: 11px; }
.play-who { display: flex; align-items: baseline; gap: 7px; min-width: 0; font-size: 12px; line-height: 17px; color: var(--text-3); white-space: nowrap; overflow: hidden; }
.play-who .play-user { flex: none; max-width: 45%; }
.play-who > * + *::before { content: '·'; margin-right: 7px; opacity: 0.5; }
.play-who .play-device { min-width: 0; overflow: hidden; text-overflow: ellipsis; }
.play-ip { flex: none; font-size: 11px; letter-spacing: 0.02em; color: var(--text-3); }
.play-when { display: inline-flex; align-items: baseline; gap: 5px; min-width: 0; white-space: nowrap; overflow: hidden; color: var(--text-2); }
.play-k { font-size: 10px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--text-3); }
.play-k + span { margin-right: 6px; }
.card-glass .play-meta { gap: 5px; }
.play-delivery { display: inline-flex; align-items: center; gap: 6px; height: 19px; padding: 0 9px; border-radius: 999px; font-size: 11px; font-weight: 600;
  background: linear-gradient(180deg, rgba(255,255,255,0.10), rgba(255,255,255,0.03)); box-shadow: inset 0 1px 0 rgba(255,255,255,0.18), inset 0 0 0 1px rgba(255,255,255,0.08); }
.play-delivery i { width: 6px; height: 6px; border-radius: 50%; }
.play-delivery.direct { color: #7fe3bd; }
.play-delivery.direct i { background: var(--ok); box-shadow: 0 0 8px var(--ok); }
.play-delivery.server { color: #f5c77e; }
.play-delivery.server i { background: var(--warn); box-shadow: 0 0 8px var(--warn); }
.play-mbps { font-size: 11px; color: var(--text-2); padding: 0 2px; }
.play-health { font-size: 11px; color: var(--text-3); overflow: hidden; text-overflow: ellipsis; }
.play-health.warn { color: #f0c27a; }
.play-health.bad { color: #ff9b9b; }
.card-glass .play-meta .play-health { margin-left: auto; padding-left: 6px; flex: none; }
.play-who .play-mbps { flex: none; padding: 0; color: var(--text-2); }
.card-glass .play-meta .chip { padding: 0 7px; }
.card-glass .play-top .play-health { flex: none; margin: 0; font-size: 11px; }
.card-glass .play-meta .play-ago { margin-left: auto; flex: none; font-size: 11px; }
/* El nombre del equipo nunca se recorta; si falta espacio, cede la IP. */
.play-who .play-device { flex: none; }
.play-who .play-ip { flex: 0 1 auto; min-width: 0; overflow: hidden; text-overflow: ellipsis; }
/* 2026-09-26: más aire. El texto ocupa toda la altura de la carátula (que ya
   fija el alto de la fila) y reparte el espacio entre líneas: la tarjeta no crece. */
.card-glass .play-row { align-items: stretch; }
.card-glass .play-body { align-self: stretch; justify-content: space-between; padding: 2px 0; }
.card-glass .play-top .play-title { font-size: 15px; }
.card-glass .play-who { margin-top: 2px; }
.card-glass .play-who > * + *::before { margin: 0 9px 0 2px; }
.card-glass .play-when { gap: 6px; }
.card-glass .play-k + span { margin-right: 12px; }
.card-glass .play-progress { margin: 0; }
.card-glass .play-meta { gap: 7px; }

/* 2026-09-27: buscador general en vidrio líquido. */
.palette.palette-glass { max-width: 620px; margin-top: 10vh; border-radius: 20px; border: 1px solid rgba(255,255,255,0.14);
  background: linear-gradient(155deg, rgba(255,255,255,0.10), rgba(255,255,255,0.03) 45%, rgba(255,255,255,0.05)), rgba(16,18,27,0.86);
  backdrop-filter: blur(24px) saturate(160%); -webkit-backdrop-filter: blur(24px) saturate(160%);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.2), 0 40px 90px -30px #000; animation: rise 0.16s ease both; }
.palette-input { display: flex; align-items: center; gap: 10px; padding: 0 18px; border-bottom: 1px solid rgba(255,255,255,0.08); }
.palette-input .icon { flex: none; width: 18px; height: 18px; color: var(--text-3); }
.palette-glass .palette-input input { flex: 1; border: 0; padding: 17px 0; font-size: 15.5px; background: transparent; }
.palette-glass .palette-results { max-height: min(460px, 60vh); padding: 6px; }
.pal-group { padding: 10px 12px 4px; font-size: 10.5px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--text-3); }
.pal-row { display: flex; align-items: center; gap: 12px; width: 100%; padding: 8px 12px; border: 0; border-radius: 12px; background: none; color: inherit; font: inherit; text-align: left; cursor: pointer; }
.pal-row.active { background: rgba(255,255,255,0.08); box-shadow: inset 0 0 0 1px rgba(255,255,255,0.1); }
.pal-row .avatar { flex: none; }
.pal-icon { flex: none; display: grid; place-items: center; width: 32px; height: 32px; border-radius: 10px; background: rgba(255,255,255,0.06); color: var(--text-2); }
.pal-icon .icon { width: 16px; height: 16px; }
.pal-poster { flex: none; width: 32px; height: 48px; border-radius: 6px; object-fit: cover; background: rgba(255,255,255,0.05); box-shadow: inset 0 0 0 1px rgba(255,255,255,0.08); }
.pal-text { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.pal-title { font-size: 14px; font-weight: 560; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pal-title mark { background: none; color: #c9d3ff; font-weight: 700; }
.pal-sub { font-size: 12px; color: var(--text-3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.palette-foot { display: flex; gap: 16px; padding: 9px 16px; border-top: 1px solid rgba(255,255,255,0.07); font-size: 11.5px; color: var(--text-3); }
.palette-foot .kbd { margin-right: 2px; }
@media (max-width: 640px) { .palette.palette-glass { margin-top: 6vh; } .palette-foot { display: none; } }

/* Interfaz — fondos de la biblioteca de las apps (2026-09-30) */
.ui-bg-title { margin: 26px 4px 12px; font-size: 13px; font-weight: 600; letter-spacing: 0.04em; text-transform: uppercase; color: var(--text-3); }
.ui-bg-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 20px; }
.ui-bg-card { overflow: hidden; }
.ui-bg-preview { aspect-ratio: 16 / 9; background: rgba(255, 255, 255, 0.03); border-bottom: 1px solid var(--line); display: flex; align-items: center; justify-content: center; }
.ui-bg-preview img { width: 100%; height: 100%; object-fit: cover; display: block; }
.ui-bg-empty { display: flex; flex-direction: column; align-items: center; gap: 8px; color: var(--text-3); font-size: 12px; text-align: center; padding: 0 18px; }
.ui-bg-empty .icon { width: 26px; height: 26px; }
.ui-bg-actions { margin-top: 12px; gap: 8px; align-items: center; }

.copies-now { display:grid; grid-template-columns:170px minmax(0,1fr); gap:30px; padding:28px; border-radius:28px; background:linear-gradient(135deg,rgba(54,69,105,.28),rgba(20,23,33,.9)); }
.copies-now-art { width:100%; aspect-ratio:2/3; border-radius:17px; overflow:hidden; display:grid; place-items:center; background:linear-gradient(150deg,#30384f,#131720); box-shadow:0 16px 38px rgba(0,0,0,.35); }
.copies-now-art img { width:100%; height:100%; object-fit:cover; }
.copies-now-art .icon { width:45px; height:45px; color:var(--text-3); }
.copies-now-body { align-self:center; min-width:0; }
.copies-now-label { font-size:11px; letter-spacing:.11em; color:#8faeff; font-weight:600; }
.copies-now h2 { font-size:clamp(24px,3vw,38px); letter-spacing:-.035em; line-height:1.15; margin:12px 0; }
.copies-now-episode { font-size:16px; color:var(--text-2); }
.copies-now-filename { overflow-wrap:anywhere; font-size:12px; color:var(--text-3); margin:16px 0; }
.copies-now-stats { display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); gap:16px; margin:20px 0 0; }
.copies-now-stats .copies-metric strong { font-size:19px; }
.copies-now + .copies-hero { padding:24px 28px; }
.copies-now + .copies-hero h2 { font-size:24px; margin:18px 0 10px; }
.copies-now + .copies-hero .copies-cloud-route { display:none; }
.copies-tabs { max-width:100%; flex-wrap:wrap; }
@media(max-width:600px) { .copies-now { grid-template-columns:85px minmax(0,1fr); gap:17px; padding:20px; } .copies-now h2 { font-size:23px; } .copies-now-stats { grid-template-columns:repeat(2,minmax(0,1fr)); gap:15px; } .copies-now-episode { font-size:13px; } .copies-now-stats .copies-metric strong { font-size:15px; } .copies-now-label { font-size:9px; letter-spacing:.04em; } }
