/* ============================================================
   EDITOR DE VIDEO (escritorio) — estilos
   Siempre oscuro (como los editores profesionales), sin depender
   del tema claro/oscuro de la app. Prefijo: lbve-
   ============================================================ */
.lbve-sheet {
    position: fixed;
    inset: 0;
    z-index: 100016;
    display: none;
    align-items: center;
    justify-content: center;
    background: rgba(0, 0, 0, 0.78);
    padding: 16px;
}
.lbve-sheet.open { display: flex; }
.lbve {
    position: relative;
    --ve-bg: #12131C;
    --ve-bg2: #1B1D2A;
    --ve-bg3: #262938;
    --ve-line: #2F3345;
    --ve-text: #FFFFFF;
    --ve-dim: #9DA2B8;
    --ve-pink: #FF3CAC;
    --ve-grad: linear-gradient(135deg, #FF6B35 0%, #FF3CAC 58%, #784BA0 100%);
    --ve-label: 104px;
    width: min(1240px, 97vw);
    height: min(880px, 97vh);
    display: flex;
    flex-direction: column;
    border-radius: 18px;
    overflow: hidden;
    background: var(--ve-bg);
    color: var(--ve-text);
    font-family: inherit;
    box-shadow: 0 24px 70px rgba(0, 0, 0, 0.6);
}
.lbve *, .lbve *::before, .lbve *::after { box-sizing: border-box; }
.lbve button { font-family: inherit; }

/* Barra superior */
.lbve-top {
    height: 54px;
    flex: none;
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 0 16px;
    background: var(--ve-bg2);
    border-bottom: 1px solid var(--ve-line);
}
.lbve-ttl { display: flex; align-items: center; gap: 9px; font-weight: 700; font-size: 15.5px; }
.lbve-ttl i { color: var(--ve-pink); }
.lbve-sp { flex: 1; }
.lbve-ib {
    width: 34px; height: 34px; border-radius: 10px; border: 0;
    background: var(--ve-bg3); color: #C9CCDA; cursor: pointer; font-size: 14px;
}
.lbve-ib:hover:not(:disabled) { color: #fff; }
.lbve-ib:disabled { opacity: 0.35; cursor: default; }
.lbve-bg {
    border: 0; background: var(--ve-bg3); color: #E8EAF3; font-weight: 700; font-size: 13.5px;
    padding: 9px 18px; border-radius: 999px; cursor: pointer;
}
.lbve-bm {
    border: 0; background: var(--ve-grad); color: #fff; font-weight: 700; font-size: 13.5px;
    padding: 9px 20px; border-radius: 999px; cursor: pointer;
    display: inline-flex; align-items: center; gap: 7px;
}
.lbve-bm:disabled { opacity: 0.45; cursor: not-allowed; }

/* Zona central: video + herramientas */
.lbve-mid {
    flex: 1;
    min-height: 0;
    display: flex;
    justify-content: center;
    container-type: size;
}
.lbve-stage {
    min-width: 0;
    min-height: 0;
    display: flex;
    align-items: center;
    justify-content: flex-start;
    padding: 10px 16px 10px 28px;
    flex: none;
    /* ancho = el del celular (9:16 del alto disponible) + sus márgenes,
       para que el panel de opciones quede pegado al video */
    width: 340px;
    width: calc((100cqh - 20px) * 9 / 16 + 44px);
    background: radial-gradient(ellipse at center, #1d2030, #12131C);
}
.lbve-screen {
    position: relative;
    height: 100%;
    max-height: 100%;
    aspect-ratio: 9 / 16;
    max-width: 100%;
    border-radius: 14px;
    overflow: hidden;
    background: #000;
    cursor: pointer;
}
.lbve-video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; background: #000; }
.lbve-ov { position: absolute; left: 0; top: 0; width: 100%; height: 100%; pointer-events: none; overflow: visible; --lbov-u: 1px; }
.lbve-ov > * { pointer-events: auto; }
.lbve-play {
    position: absolute; left: 50%; top: 50%; width: 58px; height: 58px; margin: -29px 0 0 -29px;
    border-radius: 50%; border: 0; background: rgba(10, 12, 24, 0.55); color: #fff; font-size: 20px;
    display: grid; place-items: center; cursor: pointer; transition: opacity .15s;
}
.lbve-play i { margin-left: 3px; }
.lbve-play.playing { opacity: 0; }
.lbve-screen:hover .lbve-play.playing { opacity: 0.85; }
.lbve-time {
    position: absolute; left: 50%; bottom: 10px; transform: translateX(-50%);
    background: rgba(10, 12, 24, 0.62); padding: 5px 12px; border-radius: 999px;
    font-size: 11.5px; font-weight: 700; white-space: nowrap; pointer-events: none;
    font-variant-numeric: tabular-nums;
}
.lbve-err {
    position: absolute; inset: 0; display: flex; align-items: center; justify-content: center;
    text-align: center; padding: 24px; background: rgba(0, 0, 0, 0.8); font-size: 13.5px; line-height: 1.5;
}

/* Panel derecho */
.lbve-right {
    flex: 1;
    min-width: 0;
    max-width: none;
    background: var(--ve-bg2);
    border-left: 1px solid var(--ve-line);
    display: flex;
    flex-direction: column;
    min-height: 0;
}
.lbve-toolbar {
    display: flex;
    gap: 2px;
    padding: 8px 12px 0;
    border-bottom: 1px solid var(--ve-line);
    overflow-x: auto;
    flex: none;
}
.lbve-tool {
    border: 0; background: transparent; color: #B7BBCC; cursor: pointer;
    display: flex; flex-direction: column; align-items: center; gap: 3px;
    padding: 6px 12px 9px; border-bottom: 2.5px solid transparent; flex: none;
}
.lbve-tool .lbve-tic { width: 34px; height: 34px; display: grid; place-items: center; font-size: 16px; }
.lbve-tool small { font-size: 11px; font-weight: 700; }
.lbve-tool:hover { color: #fff; }
.lbve-tool.on { color: #fff; border-bottom-color: var(--ve-pink); }
.lbve-tool.on .lbve-tic { color: var(--ve-pink); }
.lbve-rbody { flex: 1; min-height: 0; overflow-y: auto; }
.lbve-panel { padding: 20px 24px; display: flex; flex-direction: column; gap: 16px; }
.lbve-panel h4 { margin: 0; font-size: 13px; letter-spacing: .5px; text-transform: uppercase; color: var(--ve-dim); }
.lbve-hint { margin: 0; font-size: 12px; color: var(--ve-dim); line-height: 1.5; }
.lbve-warn {
    display: flex; gap: 8px; align-items: flex-start; font-size: 12.5px; line-height: 1.45;
    background: rgba(255, 170, 0, 0.12); border: 1px solid rgba(255, 170, 0, 0.35);
    color: #FFD58A; padding: 9px 11px; border-radius: 10px;
}
.lbve-tm { display: flex; gap: 10px; }
.lbve-field {
    flex: 1; background: var(--ve-bg3); border: 1px solid var(--ve-line); border-radius: 12px;
    padding: 8px 12px; display: flex; flex-direction: column; gap: 2px; min-width: 0;
}
.lbve-field small { font-size: 11px; color: var(--ve-dim); }
.lbve-field input {
    background: transparent; border: 0; outline: 0; color: #fff; font-size: 15px; font-weight: 700;
    width: 100%; padding: 0; font-variant-numeric: tabular-nums; font-family: inherit;
}
.lbve-field:focus-within { border-color: var(--ve-pink); }
.lbve-chip {
    flex: 1; border: 1px solid var(--ve-line); background: var(--ve-bg3); color: #E8EAF3;
    border-radius: 999px; font-size: 12px; font-weight: 700; padding: 8px 10px; cursor: pointer;
    display: inline-flex; align-items: center; justify-content: center; gap: 6px; white-space: nowrap;
}
.lbve-chip:hover { border-color: var(--ve-pink); }
.lbve-chip kbd {
    font-family: inherit; font-size: 10.5px; background: rgba(255, 255, 255, 0.12);
    border-radius: 4px; padding: 0 5px; margin-left: 2px;
}
.lbve-info { display: flex; gap: 14px; flex-wrap: wrap; font-size: 12px; color: var(--ve-dim); }
.lbve-info b { color: #fff; }

/* Línea de tiempo */
.lbve-tl {
    flex: none;
    max-height: 46%;
    overflow-y: auto;
    background: var(--ve-bg2);
    border-top: 1px solid var(--ve-line);
    padding: 2px 16px 8px;
}
.lbve-tracks { position: relative; --ph: 0; --ve-sb: 0px; }
.lbve-ruler {
    position: relative; height: 20px; margin-left: var(--ve-label); margin-right: var(--ve-sb); cursor: pointer; touch-action: none;
}
.lbve-tick {
    position: absolute; bottom: 0; height: 13px; border-left: 1px solid #3A3E52; padding-left: 4px;
    font-size: 10px; line-height: 13px; color: #7F849A; white-space: nowrap; user-select: none;
    font-variant-numeric: tabular-nums;
}
.lbve-trk { display: flex; align-items: center; min-height: 28px; margin-top: 4px; }
.lbve-trk-video { height: 44px; margin-top: 4px; margin-right: var(--ve-sb); }
.lbve-lab {
    width: var(--ve-label); flex: none; display: flex; align-items: center; gap: 7px;
    font-size: 11.5px; font-weight: 700; color: var(--ve-dim);
}
.lbve-lane { flex: 1; position: relative; height: 100%; min-height: 30px; border-radius: 8px; background: rgba(255, 255, 255, 0.03); }
.lbve-strip {
    position: absolute; inset: 0; display: flex; border-radius: 10px; overflow: hidden;
    background: #232637; cursor: pointer;
}
.lbve-frame { flex: 1 1 0; min-width: 0; height: 100%; display: block; }
.lbve-dim { position: absolute; top: 0; bottom: 0; background: rgba(10, 11, 18, 0.72); pointer-events: none; border-radius: 10px; }
.lbve-dim-l { left: 0; }
.lbve-trimbox {
    position: absolute; top: -4px; bottom: -4px; border: 3px solid var(--ve-pink); border-radius: 11px;
    pointer-events: none; z-index: 2;
}
.lbve-grip {
    position: absolute; left: 14px; right: 14px; top: -3px; height: 8px; background: var(--ve-pink);
    border-radius: 0 0 6px 6px; pointer-events: auto; cursor: grab; touch-action: none;
}
.lbve-grip:active { cursor: grabbing; }
.lbve-h {
    position: absolute; top: -3px; bottom: -3px; width: 16px; background: var(--ve-pink);
    pointer-events: auto; cursor: ew-resize; touch-action: none; display: block;
}
.lbve-h::after {
    content: ""; position: absolute; left: 50%; top: 50%; width: 3px; height: 22px; margin: -11px 0 0 -1.5px;
    border-radius: 2px; background: #fff;
}
.lbve-h-s { left: -3px; border-radius: 9px 0 0 9px; }
.lbve-h-e { right: -3px; border-radius: 0 9px 9px 0; }
.lbve-playhead {
    position: absolute; top: 0; bottom: 0; width: 2px; background: #fff; z-index: 5; pointer-events: none;
    left: calc(var(--ve-label) + (100% - var(--ve-label) - var(--ve-sb)) * var(--ph));
    margin-left: -1px;
}
.lbve-playhead::before {
    content: ""; position: absolute; top: 0; left: -4px; width: 10px; height: 10px;
    border-radius: 3px 3px 50% 50%; background: #fff;
}

@media (max-width: 1000px) {
    .lbve-txform { grid-template-columns: 1fr; }
}

/* ---- Herramienta Texto ---- */
.lbve-actions { display: flex; gap: 8px; align-items: center; }
.lbve-add {
    border: 0; background: var(--ve-grad); color: #fff; font-weight: 700; font-size: 12px;
    padding: 6px 14px; border-radius: 999px; cursor: pointer; display: inline-flex; align-items: center; justify-content: center; gap: 6px; flex: none;
}
.lbve-add i, .lbve-danger i { font-size: 10.5px; }
.lbve-add:disabled { opacity: 0.45; cursor: not-allowed; }
.lbve-txform { display: grid; grid-template-columns: 1fr 1fr; gap: 16px 24px; align-items: start; }
.lbve-col { display: flex; flex-direction: column; gap: 14px; min-width: 0; }
.lbve-fld { display: flex; flex-direction: column; gap: 8px; min-width: 0; }
.lbve-txform .lbve-sub { margin-bottom: 0; }
.lbve-ta {
    width: 100%; resize: none; background: var(--ve-bg3); border: 1px solid var(--ve-line); border-radius: 12px;
    color: #fff; font-family: inherit; font-size: 14px; padding: 10px 12px; outline: 0; line-height: 1.4;
}
.lbve-ta:focus { border-color: var(--ve-pink); }
.lbve-sub { font-size: 11.5px; font-weight: 700; color: var(--ve-dim); letter-spacing: .4px; text-transform: uppercase; margin-bottom: -6px; }
.lbve-stylebtn {
    width: 100%; display: flex; align-items: center; gap: 10px; text-align: left;
    background: var(--ve-bg3); border: 1px solid var(--ve-line); color: #fff; border-radius: 12px;
    padding: 9px 14px; cursor: pointer; font-size: 17px; line-height: 1.25;
}
.lbve-stylebtn:hover, .lbve-stylebtn.open { border-color: var(--ve-pink); }
.lbve-stylename { flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.lbve-stylebtn small { font-size: 11px; color: var(--ve-dim); font-weight: 700; flex: none; }
.lbve-stylebtn i { font-size: 12px; color: var(--ve-dim); transition: transform .15s; flex: none; }
.lbve-stylebtn.open i { transform: rotate(180deg); }
.lbve-pop {
    position: absolute; z-index: 50; display: flex; flex-direction: column;
    background: #1E2132; border: 1px solid #3A3F57; border-radius: 14px; overflow: hidden;
    box-shadow: 0 16px 40px rgba(0, 0, 0, 0.55);
}
.lbve-pop-search { display: flex; align-items: center; gap: 8px; padding: 10px 12px; border-bottom: 1px solid var(--ve-line); flex: none; }
.lbve-pop-search i { color: var(--ve-dim); font-size: 13px; }
.lbve-pop-search input { flex: 1; min-width: 0; background: transparent; border: 0; outline: 0; color: #fff; font-family: inherit; font-size: 13.5px; }
.lbve-pop-list { overflow-y: auto; flex: 1; min-height: 0; padding: 0 6px 8px; overscroll-behavior: contain; }
.lbve-pop-cat {
    position: sticky; top: 0; z-index: 1; background: #1E2132; padding: 10px 8px 6px;
    font-size: 10.5px; font-weight: 800; letter-spacing: .7px; text-transform: uppercase; color: var(--ve-pink);
}
.lbve-fi {
    width: 100%; display: flex; align-items: center; justify-content: space-between; gap: 8px; text-align: left;
    background: transparent; border: 0; color: #fff; border-radius: 9px; padding: 8px 10px; cursor: pointer; font-size: 19px; line-height: 1.3;
}
.lbve-fi:hover { background: rgba(255, 255, 255, 0.08); }
.lbve-fi.on { background: rgba(255, 60, 172, 0.18); }
.lbve-fi-n { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.lbve-fi i { color: var(--ve-pink); font-size: 12px; flex: none; }
.lbve-pop-none { padding: 18px 10px; color: var(--ve-dim); font-size: 13px; text-align: center; }
/* Efectos con color propio */
.lbve-fx { display: inline-flex; align-items: center; gap: 8px; padding-right: 8px; }
.lbve-fxdot {
    width: 17px; height: 17px; border-radius: 50%; flex: none; cursor: pointer;
    border: 2px solid rgba(255, 255, 255, 0.6); box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.45);
}
.lbve-fxdot:hover { transform: scale(1.15); }
.lbve-pill.on .lbve-fxdot { border-color: rgba(20, 22, 31, 0.4); box-shadow: none; }
.lbve-more {
    background: conic-gradient(#FF3B3B, #FFD23F, #3EE06E, #2ED8E8, #3E5BF0, #C03EF0, #FF3B3B);
    display: inline-flex; align-items: center; justify-content: center; color: #fff; font-size: 11px;
}
.lbve-more i { text-shadow: 0 1px 3px rgba(0, 0, 0, 0.7); }
.lbve-more.custom i { display: none; }
/* Paleta */
.lbve-palpop { overflow-y: auto; padding-bottom: 6px; overscroll-behavior: contain; }
.lbve-pal-head {
    position: sticky; top: 0; z-index: 2; display: flex; align-items: center; justify-content: space-between;
    background: #1E2132; padding: 12px 14px 8px; font-size: 13px; font-weight: 800;
}
.lbve-pal-x { border: 0; background: transparent; color: var(--ve-dim); cursor: pointer; font-size: 14px; padding: 2px 4px; }
.lbve-pal-x:hover { color: #fff; }
.lbve-pal { padding: 0 14px 10px; display: flex; flex-direction: column; gap: 8px; }
.lbve-pal-cat { font-size: 10.5px; font-weight: 800; letter-spacing: .7px; text-transform: uppercase; color: var(--ve-pink); margin-top: 4px; }
.lbve-pal-row { display: flex; flex-wrap: wrap; gap: 6px; }
.lbve-pal-grid { display: grid; grid-template-columns: repeat(18, 1fr); gap: 4px; }
.lbve-pc {
    width: 100%; aspect-ratio: 1; min-width: 18px; border-radius: 6px; border: 1.5px solid rgba(255, 255, 255, 0.14);
    cursor: pointer; padding: 0;
}
.lbve-pal-row .lbve-pc { width: 26px; height: 26px; aspect-ratio: auto; border-radius: 50%; }
.lbve-pc:hover { transform: scale(1.12); }
.lbve-pc.on { border-color: #fff; box-shadow: 0 0 0 2px #FF3CAC; }
.lbve-pal-custom { display: flex; gap: 10px; align-items: center; }
.lbve-pal-custom input[type="color"] { width: 44px; height: 34px; border: 0; background: transparent; padding: 0; cursor: pointer; }
.lbve-pal-custom input[type="text"] {
    flex: 1; min-width: 0; background: var(--ve-bg3); border: 1px solid var(--ve-line); border-radius: 10px;
    color: #fff; padding: 8px 12px; font-family: inherit; font-size: 13.5px; outline: 0; text-transform: uppercase;
}
.lbve-pal-custom input[type="text"]:focus { border-color: var(--ve-pink); }
.lbve-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.lbve-pill {
    border: 1px solid var(--ve-line); background: var(--ve-bg3); color: #E8EAF3; border-radius: 999px;
    font-size: 12px; font-weight: 700; padding: 6px 12px; cursor: pointer;
}
.lbve-pill:hover { border-color: var(--ve-pink); }
.lbve-pill.on { background: #fff; color: #14161F; border-color: #fff; }
.lbve-seg { display: flex; background: var(--ve-bg3); border-radius: 999px; padding: 3px; gap: 2px; }
.lbve-seg button { flex: 1; border: 0; background: transparent; color: #B7BBCC; padding: 7px 8px; border-radius: 999px; cursor: pointer; font-size: 13px; }
.lbve-seg button.on { background: #fff; color: #14161F; }
.lbve-sw { display: flex; flex-wrap: wrap; gap: 8px; }
.lbve-swatch { width: 26px; height: 26px; border-radius: 50%; border: 2px solid var(--ve-bg2); box-shadow: 0 0 0 1.5px #4A4E63; cursor: pointer; padding: 0; }
.lbve-swatch.on { box-shadow: 0 0 0 2px #fff; }
.lbve-rg { display: flex; flex-direction: column; gap: 6px; font-size: 12.5px; color: #C9CCDA; }
.lbve-rl { display: flex; justify-content: space-between; }
.lbve-rl b { color: #fff; }
.lbve-rg input[type="range"] { width: 100%; accent-color: var(--ve-pink); }
.lbve-danger {
    border: 1px solid rgba(239, 68, 68, 0.5); background: transparent; color: #FF8A8A; font-weight: 700; font-size: 12px;
    border-radius: 999px; padding: 5px 13px; cursor: pointer; display: inline-flex; align-items: center; justify-content: center; gap: 6px; flex: none;
}
.lbve-danger:hover { background: rgba(239, 68, 68, 0.12); }

/* Elementos sobre el video (selección y manijas) */
.lbve-ov-item { cursor: move; touch-action: none; }
.lbve-sel { outline: 1.5px dashed #fff; outline-offset: 6px; }
.lbve-hdl {
    display: none; position: absolute; width: 22px; height: 22px; border-radius: 50%;
    background: #fff; color: #14161F; font-size: 10px; align-items: center; justify-content: center;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.5); cursor: pointer; font-family: 'Poppins', system-ui, sans-serif; font-weight: 400;
    text-shadow: none; letter-spacing: 0; line-height: 1; font-style: normal;
    transform: scale(calc(1 / var(--s, 1)));
}
.lbve-sel .lbve-hdl { display: flex; }
.lbve-hdl-del { left: -18px; top: -18px; transform-origin: center; }
.lbve-hdl-rot { right: -18px; bottom: -18px; cursor: nwse-resize; background: var(--ve-pink); color: #fff; }

/* Clips de la línea de tiempo */
.lbve-lane-text { background: rgba(255, 255, 255, 0.03); }
.lbve-clip {
    position: absolute; border-radius: 7px; font-size: 11px; font-weight: 700; display: flex; align-items: center;
    overflow: hidden; cursor: grab; touch-action: none; user-select: none;
}
.lbve-clip:active { cursor: grabbing; }
.lbve-clip.t { background: #3E6DF0; color: #fff; }
.lbve-clip.sel { outline: 2px solid #fff; outline-offset: 0; z-index: 2; }
.lbve-cl { padding: 0 10px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; pointer-events: none; flex: 1; }
.lbve-ch { position: absolute; top: 0; bottom: 0; width: 8px; cursor: ew-resize; background: rgba(255, 255, 255, 0.25); }
.lbve-ch-l { left: 0; border-radius: 7px 0 0 7px; }
.lbve-ch-r { right: 0; border-radius: 0 7px 7px 0; }
.lbve-subnote { text-transform: none; letter-spacing: 0; font-weight: 500; opacity: .7; margin-left: 6px; }
.lbve-mspeed { margin-top: 8px; max-width: 300px; }

/* ---- Herramienta Música ---- */
.lbve-mu { display: flex; flex-direction: column; gap: 16px; max-width: none; }
.lbve-mu > #lbveMuEmpty, .lbve-mu > #lbveMuForm, .lbve-mu > #lbveMuMsg { max-width: 640px; }
.lbve-mu-btns { flex-wrap: wrap; }
.lbve-add.lbve-alt { background: #2A2E44; color: #E9EBF5; border: 1px solid #3A3E52; }
.lbve-add.lbve-alt:hover { border-color: var(--ve-pink); }
.lbve-mu-card { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border-radius: 14px; background: #232637; border: 1px solid #343850; }
.lbve-mu-ic { width: 38px; height: 38px; border-radius: 50%; display: grid; place-items: center; background: var(--ve-grad); color: #fff; flex: none; }
.lbve-mu-meta { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.lbve-mu-meta b { font-size: 14px; color: #fff; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.lbve-mu-meta small { font-size: 12px; color: var(--ve-dim); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.lbve-mr {
    position: relative; height: 54px; border-radius: 12px; margin: 8px 0 12px; touch-action: none;
    background:
        repeating-linear-gradient(90deg, rgba(255,255,255,.16) 0 2px, transparent 2px 6px),
        #232637;
    background-size: 100% 60%, auto; background-position: center; background-repeat: no-repeat;
}
.lbve-mr.loading { opacity: .6; }
.lbve-mr-sel {
    position: absolute; top: -3px; bottom: -3px; min-width: 14px; box-sizing: border-box;
    background: rgba(255, 60, 172, .22); border: 2px solid var(--ve-pink); border-radius: 10px; cursor: grab; touch-action: none;
}
.lbve-mr-sel:active { cursor: grabbing; }
.lbve-mr-h { position: absolute; top: -2px; bottom: -2px; width: 14px; background: var(--ve-pink); cursor: ew-resize; }
.lbve-mr-h[data-h="s"] { left: -2px; border-radius: 9px 0 0 9px; }
.lbve-mr-h[data-h="e"] { right: -2px; border-radius: 0 9px 9px 0; }
.lbve-mr-h::after { content: ""; position: absolute; left: 50%; top: 30%; bottom: 30%; width: 2px; margin-left: -1px; background: rgba(255,255,255,.85); border-radius: 2px; }
.lbve-mr-ctl { display: flex; gap: 10px; align-items: flex-end; }
.lbve-mr-ctl .lbve-field { flex: 1; }
.lbve-mu-play {
    width: 42px; height: 42px; border-radius: 50%; border: 0; cursor: pointer; flex: none;
    background: #fff; color: #14161F; display: grid; place-items: center; font-size: 14px;
}
.lbve-mu-play:hover { background: #FFE3F4; }
.lbve-lane-music { background: rgba(255, 255, 255, 0.03); }
.lbve-clip.m { background: linear-gradient(90deg, #FF3CAC, #B36BFF); color: #fff; cursor: pointer; }
.lbve-clip.m .lbve-cl i { font-size: 10px; margin-right: 4px; }
.lbve-mu-empty {
    border: 0; background: transparent; color: var(--ve-dim); font-size: 11.5px; font-weight: 700; cursor: pointer;
    height: 100%; width: 100%; text-align: left; padding: 0 12px; border-radius: 8px;
}
.lbve-mu-empty:hover { color: #fff; background: rgba(255, 255, 255, 0.05); }

/* Silenciar el sonido original del video */
.lbve-mutepill {
    position: absolute; left: 10px; top: 10px; z-index: 6; height: 30px; padding: 0 12px; border: 0;
    border-radius: 999px; background: rgba(10, 12, 24, 0.62); color: #fff; font: inherit;
    font-size: 11.5px; font-weight: 700; display: inline-flex; align-items: center; gap: 6px;
    cursor: pointer; -webkit-backdrop-filter: blur(4px); backdrop-filter: blur(4px);
}
.lbve-mutepill:hover { background: rgba(10, 12, 24, 0.82); }
.lbve-mutepill.on { background: var(--ve-pink); }
.lbve-mute-trk {
    margin-left: auto; margin-right: 10px; width: 24px; height: 24px; flex: none; border-radius: 50%;
    border: 1px solid var(--ve-line); background: rgba(255, 255, 255, 0.05); color: var(--ve-dim);
    display: grid; place-items: center; font-size: 11px; cursor: pointer; padding: 0;
}
.lbve-mute-trk:hover { color: #fff; border-color: var(--ve-pink); }
.lbve-mute-trk.on { background: var(--ve-pink); border-color: var(--ve-pink); color: #fff; }

/* Ampliar el video dentro del editor (botón de la esquina + X para cerrar) */
.lbve-zoom, .lbve-zoomx {
    position: absolute; right: 10px; top: 10px; z-index: 6; width: 30px; height: 30px; border: 0;
    border-radius: 50%; background: rgba(10, 12, 24, 0.62); color: #fff; font-size: 13px; padding: 0;
    display: grid; place-items: center; cursor: pointer;
    -webkit-backdrop-filter: blur(4px); backdrop-filter: blur(4px);
}
.lbve-zoom:hover, .lbve-zoomx:hover { background: rgba(10, 12, 24, 0.85); }
.lbve-zoomx { display: none; }
.lbve-sheet.zoomed .lbve-zoom { display: none; }
.lbve-sheet.zoomed .lbve-zoomx { display: grid; width: 40px; height: 40px; font-size: 18px; right: 12px; top: 12px; background: var(--ve-pink); }
.lbve-sheet.zoomed .lbve-zoomx:hover { background: #ff5cbd; }
.lbve-sheet.zoomed .lbve-screen {
    position: fixed; left: 50%; top: 50%; transform: translate(-50%, -50%);
    /* pantalla completa con la proporción del video: ancho o alto, lo que llegue primero */
    width: min(94vw, calc(94vh * var(--ve-ar, 0.5625))) !important; height: auto !important;
    max-height: none; max-width: none;
    aspect-ratio: var(--ve-ar, 0.5625); z-index: 100030; border-radius: 18px;
    box-shadow: 0 0 0 100vmax rgba(0, 0, 0, 0.9);
}

/* ---- Narración con micrófono (dentro de Música) ---- */
.lbve-vo-host { border-top: 1px solid var(--ve-line); padding-top: 16px; }
.lbve-vo { display: flex; flex-direction: column; gap: 12px; }
.lbve-vo-idle { display: flex; flex-direction: column; gap: 10px; align-items: flex-start; }
.lbve-rec {
    display: inline-flex; align-items: center; gap: 8px; height: 40px; padding: 0 18px; border: 0; border-radius: 999px;
    background: #E5354F; color: #fff; font: inherit; font-size: 13.5px; font-weight: 700; cursor: pointer;
}
.lbve-rec:hover { background: #F0485F; }
.lbve-rec:disabled { opacity: .45; cursor: not-allowed; }
.lbve-rec.stop { background: #fff; color: #14161F; }
.lbve-rec.stop:hover { background: #FFE3F4; }
.lbve-vo-live-box { display: flex; flex-direction: column; gap: 10px; background: var(--ve-bg3); border: 1px solid var(--ve-line); border-radius: 12px; padding: 12px 14px; align-items: flex-start; }
.lbve-vo-live-box.on { border-color: #E5354F; }
.lbve-vo-state { display: flex; align-items: center; gap: 10px; font-size: 13px; }
.lbve-vo-state span { font-variant-numeric: tabular-nums; color: var(--ve-dim); }
.lbve-vo-dot { width: 10px; height: 10px; border-radius: 50%; background: var(--ve-dim); }
.lbve-vo-live-box.on .lbve-vo-dot { background: #E5354F; animation: lbveVoPulse 1s infinite; }
@keyframes lbveVoPulse { 50% { opacity: .25; } }
.lbve-vo-meter { width: 100%; height: 6px; border-radius: 99px; background: rgba(255,255,255,.1); overflow: hidden; }
.lbve-vo-meter i { display: block; height: 100%; width: 0; background: linear-gradient(90deg, #3DDC84, #FFD24A 75%, #E5354F); transition: width .07s linear; }
.lbve-vo-list { display: flex; flex-direction: column; gap: 6px; }
.lbve-vo-row {
    display: flex; align-items: center; gap: 10px; padding: 8px 12px; border-radius: 10px; border: 1px solid var(--ve-line);
    background: var(--ve-bg3); color: #E8EAF3; font: inherit; font-size: 12.5px; cursor: pointer; text-align: left;
}
.lbve-vo-row i { color: #4DB6FF; }
.lbve-vo-row small { margin-left: auto; color: var(--ve-dim); font-size: 11px; }
.lbve-vo-row.sel { border-color: var(--ve-pink); }
.lbve-vo-ctl { display: flex; flex-direction: column; gap: 12px; }
.lbve-vo-btns { flex-wrap: wrap; }
.lbve-vo-soon i { margin-right: 4px; }
.lbve-lane-voice { background: rgba(255, 255, 255, 0.03); }
.lbve-clip.v { background: linear-gradient(90deg, #2F7BFF, #19B6C9); color: #fff; }
.lbve-clip.v .lbve-cl { position: relative; z-index: 1; text-shadow: 0 1px 2px rgba(0,0,0,.4); }
.lbve-clip.v .lbve-cl i { font-size: 10px; }
.lbve-clip.v .lbve-wv { position: absolute; left: 8px; right: 8px; top: 0; width: calc(100% - 16px); height: 100%; pointer-events: none; }
.lbve-vo-ov {
    position: absolute; inset: 0; z-index: 7; display: flex; flex-direction: column; align-items: center; justify-content: center;
    gap: 8px; background: rgba(8, 9, 16, 0.45); color: #fff; pointer-events: none; text-align: center;
}
.lbve-vo-ov b { font-size: 72px; line-height: 1; }
.lbve-vo-ov span { font-size: 13px; font-weight: 700; }
.lbve-vo-ov .lbve-vo-live { position: absolute; top: 12px; right: 12px; display: inline-flex; align-items: center; gap: 6px; background: rgba(10,12,24,.65); border-radius: 999px; padding: 6px 12px; font-size: 12px; }
.lbve-vo-ov .lbve-vo-live i { width: 9px; height: 9px; border-radius: 50%; background: #E5354F; animation: lbveVoPulse 1s infinite; }
.lbve-vo-ov:has(.lbve-vo-live) { background: transparent; justify-content: flex-start; }

.lbve-rec-bar { position: absolute; top: 3px; height: 24px; border-radius: 7px; background: rgba(229, 53, 79, .85); pointer-events: none; }

.lbve-vo-dev { display: flex; flex-direction: column; gap: 4px; width: 100%; max-width: 420px; }
.lbve-vo-dev small { font-size: 11px; color: var(--ve-dim); }
.lbve-vo-dev select { height: 38px; border-radius: 10px; border: 1px solid var(--ve-line); background: var(--ve-bg3); color: #E8EAF3; font: inherit; font-size: 12.5px; padding: 0 10px; }
.lbve-vo-dev select:focus { outline: none; border-color: var(--ve-pink); }

.lbve-vo-chk { display: flex; align-items: center; gap: 8px; font-size: 12.5px; color: #E8EAF3; cursor: pointer; }
.lbve-vo-chk input { accent-color: var(--ve-pink); width: 16px; height: 16px; }
.lbve-vo-chk small { color: var(--ve-dim); font-size: 11px; }

/* Editor de onda con zoom */
.lbve-we { display: flex; flex-direction: column; gap: 8px; background: var(--ve-bg3); border: 1px solid var(--ve-line); border-radius: 12px; padding: 12px; }
.lbve-we-top { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; }
.lbve-we-zoom { display: flex; align-items: center; gap: 6px; }
.lbve-we-zoom button { height: 28px; min-width: 28px; border: 1px solid var(--ve-line); background: #2A2E44; color: #E9EBF5; border-radius: 8px; cursor: pointer; font: inherit; font-size: 11px; font-weight: 700; padding: 0 8px; }
.lbve-we-zoom button:hover { border-color: var(--ve-pink); }
.lbve-we-zoom button i { font-size: 10px; }
.lbve-we-zoom input[type=range] { width: 110px; accent-color: var(--ve-pink); }
.lbve-we-zoom b { min-width: 36px; text-align: center; font-size: 12px; font-variant-numeric: tabular-nums; }
.lbve-we-cv { width: 100%; height: 150px; display: block; border-radius: 8px; touch-action: none; cursor: pointer; background: #171927; }
.lbve-we-pan { width: 100%; accent-color: var(--ve-pink); margin: 0; }
.lbve-we-bar { font-size: 11.5px; color: var(--ve-dim); font-variant-numeric: tabular-nums; }

.lbve-vo-gate { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.lbve-vo-lv { display: flex; align-items: center; gap: 8px; font-size: 12px; color: var(--ve-dim); }
.lbve-vo-lv select { height: 32px; border-radius: 8px; border: 1px solid var(--ve-line); background: var(--ve-bg3); color: #E8EAF3; font: inherit; font-size: 12.5px; padding: 0 8px; }
.lbve-vo-lv select:disabled { opacity: .45; }

.lbve-vo .lbve-hint { max-width: 900px; }

/* Mezcla de sonidos: volumen del sonido original */
.lbve-mixbox { display: flex; flex-direction: column; gap: 12px; padding: 12px 14px; margin-bottom: 14px; border-radius: 12px; background: rgba(255,255,255,.04); border: 1px solid rgba(255,255,255,.08); }
.lbve-mixbox .lbve-hint { margin: 0; }
.lbve-mixbox input[type="range"]:disabled { opacity: .45; }

/* ---- Pegatinas ---- */
.lbve-sk { display: flex; flex-direction: column; gap: 12px; }
.lbve-sk-tabs { max-width: 480px; }
.lbve-sk-sel { display: flex; flex-direction: column; gap: 10px; padding: 12px 14px; border-radius: 12px; background: rgba(255,255,255,.04); border: 1px solid rgba(255,255,255,.08); max-width: 640px; }
.lbve-sk-selhead { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.lbve-sk-selhead b { color: #fff; font-size: 14px; }
.lbve-sk-pane { display: flex; flex-direction: column; gap: 8px; }
.lbve-sk-cat { margin-top: 4px; }
#lbveSkPackGrid .lbve-sk-cat, #lbveSkFlagGrid .lbve-sk-cat { margin: 16px 0 10px; }
#lbveSkPackGrid .lbve-sk-cat:first-child, #lbveSkFlagGrid .lbve-sk-cat:first-child { margin-top: 8px; }
.lbve-sk-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(64px, 1fr)); gap: 8px; max-width: 640px; }
.lbve-sk-cell { aspect-ratio: 1; display: flex; align-items: center; justify-content: center; padding: 8px; border: 1px solid rgba(255,255,255,.08); border-radius: 12px; background: var(--ve-bg3); cursor: pointer; transition: border-color .12s, transform .12s; }
.lbve-sk-cell:hover { border-color: var(--ve-pink); transform: translateY(-1px); }
.lbve-sk-cell:disabled { opacity: .4; cursor: not-allowed; transform: none; }
.lbve-sk-cell svg, .lbve-sk-cell img { width: 100%; height: 100%; object-fit: contain; display: block; pointer-events: none; }
.lbve-sk-cell span { font-size: 28px; line-height: 1; font-family: 'Apple Color Emoji', 'Segoe UI Emoji', 'Noto Color Emoji', sans-serif; }
.lbve-sk-em .lbve-sk-cell { padding: 4px; }
.lbve-sk-maker { display: flex; flex-direction: column; gap: 12px; max-width: 640px; }
.lbve-sk-maker > div { display: flex; flex-direction: column; gap: 12px; }
.lbve-sk-prevwrap { display: flex; align-items: center; justify-content: center; padding: 12px; border-radius: 12px; border: 1px solid rgba(255,255,255,.08); background: repeating-conic-gradient(#2a2e42 0% 25%, #343952 0% 50%) 0 0 / 18px 18px; }
.lbve-sk-prevwrap canvas { max-width: 100%; max-height: 220px; width: auto; height: auto; }
.lbve-sk-msg { color: #FFB4C4; }

/* ---- Pistas extra: se ven dos a la vez y el resto con scroll ---- */
#lbVeExtraTracks {
    position: relative;
    max-height: 74px;
    overflow-y: auto;
    overflow-x: hidden;
    overscroll-behavior: contain;
    scrollbar-width: thin;
    scrollbar-color: #5A5F7A transparent;
}
#lbVeExtraTracks::-webkit-scrollbar { width: 8px; }
#lbVeExtraTracks::-webkit-scrollbar-track { background: rgba(255, 255, 255, 0.04); border-radius: 8px; }
#lbVeExtraTracks::-webkit-scrollbar-thumb { background: #5A5F7A; border-radius: 8px; }
#lbVeExtraTracks::-webkit-scrollbar-thumb:hover { background: var(--ve-pink); }

/* La etiqueta de una pista alta (varias filas de clips) se queda arriba para verla al hacer scroll */
#lbVeExtraTracks .lbve-lab { align-self: flex-start; min-height: 30px; }

/* Stickers de Latinchat: más grandes porque llevan texto */

/* Carrusel de filtros: una sola fila que se desliza de lado */
.lbve-car { position: relative; display: flex; align-items: center; max-width: 640px; min-width: 0; }
.lbve-car-track { display: flex; flex-wrap: nowrap; gap: 6px; flex: 1 1 auto; min-width: 0; overflow-x: auto; overflow-y: hidden; scroll-behavior: auto; scrollbar-width: none; -ms-overflow-style: none; padding: 2px 0; position: relative; overscroll-behavior-x: contain; cursor: grab; }
.lbve-car-track::-webkit-scrollbar { display: none; }
.lbve-car-track.drag { cursor: grabbing; user-select: none; }
.lbve-car-track .lbve-pill { flex: 0 0 auto; white-space: nowrap; }
.lbve-car-btn { flex: 0 0 auto; width: 28px; height: 28px; border-radius: 50%; border: 1px solid rgba(255,255,255,.14); background: var(--ve-bg3); color: #fff; font-size: 11px; display: none; align-items: center; justify-content: center; cursor: pointer; z-index: 2; transition: border-color .12s, background .12s; }
.lbve-car-btn:hover { border-color: var(--ve-pink); }
.lbve-car-prev { margin-right: 6px; }
.lbve-car-next { margin-left: 6px; }
.lbve-car.can-prev .lbve-car-prev, .lbve-car.can-next .lbve-car-next { display: flex; }

/* Álbum Banderas */
.lbve-sk-search { width: 100%; max-width: 640px; box-sizing: border-box; padding: 9px 12px; border-radius: 10px; border: 1px solid rgba(255,255,255,.12); background: var(--ve-bg3); color: #fff; font-size: 13px; outline: none; }
.lbve-sk-search:focus { border-color: var(--ve-pink); }
.lbve-sk-flags { grid-template-columns: repeat(auto-fill, minmax(92px, 1fr)); }
.lbve-sk-cell.lbve-sk-flag { aspect-ratio: auto; flex-direction: column; gap: 6px; padding: 8px 6px 6px; min-width: 0; }
.lbve-sk-flag img { width: 100%; height: auto; aspect-ratio: 3 / 2; object-fit: cover; border-radius: 3px; box-shadow: 0 0 0 1px rgba(255,255,255,.18); }
.lbve-sk-flag .lbve-fl-name { font-family: inherit; font-size: 10.5px; line-height: 1.15; color: #C9CDE0; text-align: center; max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.lbve-sk-chat { grid-template-columns: repeat(auto-fill, minmax(112px, 1fr)); }
.lbve-sk-chat .lbve-sk-cell { padding: 6px; }
