/*
 * ⚡ live-flash 2.0.0 — "OFERTAS RELÁMPAGO" rows and group boxes (design 2026-12-03).
 * Yellow = flash deal. White rows, a black "TERMINA" clock box (red in the last 2 minutes),
 * "Quedan 3 · 40 % vendido" + a yellow → red bar, a red ¡LO QUIERO!.
 * The same row is used inside 🏁 RONDA FINAL (.cs-lv-row-ronda), so rules are not scoped to ②.
 * Replaces live-flash_1-0-0.css (kept for rollback).
 */

#cshow-live.cs-screen .cs-lv-rows { display: flex; flex-direction: column; gap: 10px; margin-bottom: 8px; }

/* ---------------------------------------------------------------- one row */

#cshow-live.cs-screen .cs-lv-row {
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding: 12px;
    border: 1px solid #F1E3B5;
    border-radius: 18px;
    background: #FFFFFF;
    box-shadow: 0 6px 18px rgba(255, 194, 26, 0.16);
}

#cshow-live.cs-screen .cs-lv-row.is-tv { border-color: var(--lv-yellow); box-shadow: 0 0 0 2px rgba(255, 194, 26, 0.45), 0 6px 18px rgba(255, 194, 26, 0.22); }
#cshow-live.cs-screen .cs-lv-row.cs-lv-row-ronda { border-color: var(--lv-line); box-shadow: none; background: var(--lv-soft); }
#cshow-live.cs-screen .cs-lv-row.is-gone { opacity: 0.6; }

#cshow-live.cs-screen .cs-lv-row .cs-lv-frow-top { display: flex; align-items: flex-start; gap: 10px; }

#cshow-live.cs-screen .cs-lv-row .cs-lv-row-photo {
    flex: 0 0 auto;
    width: 72px;
    height: 72px;
    border-radius: 12px;
}

#cshow-live.cs-screen .cs-lv-row .cs-lv-row-photo img { width: 88%; height: 88%; }

#cshow-live.cs-screen .cs-lv-row .cs-lv-row-info {
    display: flex;
    flex: 1 1 auto;
    flex-direction: column;
    align-items: flex-start;
    gap: 5px;
    min-width: 0;
}

#cshow-live.cs-screen .cs-lv-row .cs-lv-row-name {
    display: -webkit-box;
    margin: 0;
    overflow: hidden;
    font-size: 15px;
    font-weight: 600;
    line-height: 1.25;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

/* "TERMINA 4:10" — black box, red in the last 2 minutes (is-soon, live-app.js) */
#cshow-live.cs-screen .cs-lv-cbox {
    display: flex;
    flex: 0 0 auto;
    flex-direction: column;
    align-items: center;
    gap: 3px;
    padding: 7px 10px;
    border-radius: 12px;
    background: var(--lv-ink);
    color: #FFFFFF;
    transition: background 0.3s;
}

#cshow-live.cs-screen .cs-lv-cbox .cs-lv-cbox-k { color: #B4B4BE; font-size: 10px; font-weight: 800; letter-spacing: 0.12em; }
#cshow-live.cs-screen .cs-lv-cbox .cs-lv-clock { font-size: 22px; color: #FFFFFF; }
#cshow-live.cs-screen .cs-lv-cbox .cs-lv-clock-icon { display: none; }
#cshow-live.cs-screen .cs-lv-cbox:has(.cs-lv-clock.is-soon) { background: var(--lv-red); }
#cshow-live.cs-screen .cs-lv-cbox:has(.cs-lv-clock.is-soon) .cs-lv-cbox-k { color: #FFD6D6; }
#cshow-live.cs-screen .cs-lv-cbox .cs-lv-clock.is-last10 { color: #FFFFFF; }
#cshow-live.cs-screen .cs-lv-cbox:has(.cs-lv-clock.is-zero) { background: #E4E4EA; }
#cshow-live.cs-screen .cs-lv-cbox .cs-lv-clock.is-zero { color: var(--lv-mute); }

#cshow-live.cs-screen .cs-lv-row .cs-lv-frow-bot { display: flex; align-items: center; gap: 12px; }

#cshow-live.cs-screen .cs-lv-row .cs-lv-frow-side {
    display: flex;
    flex: 0 0 auto;
    flex-direction: column;
    align-items: stretch;
    gap: 4px;
}

#cshow-live.cs-screen .cs-lv-row .cs-lv-frow-up {
    display: none;
    color: var(--lv-mute);
    font-size: 14px;
    font-weight: 800;
    text-align: center;
}

/* 0:00 on the phone: the button hides until the server's next file */
#cshow-live.cs-screen .cs-lv-row.is-timeup .cs-lv-buy:not(.is-mine),
#cshow-live.cs-screen .cs-lv-gbox.is-timeup .cs-lv-buy:not(.is-mine) { display: none; }
#cshow-live.cs-screen .cs-lv-row.is-timeup .cs-lv-frow-up { display: block; }

/* ---------------------------------------------------------------- sold bar */

#cshow-live.cs-screen .cs-lv-soldbar {
    display: flex;
    flex: 1 1 auto;
    flex-direction: column;
    gap: 6px;
    min-width: 0;
}

#cshow-live.cs-screen .cs-lv-soldbar .cs-lv-soldbar-txt {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 8px;
    color: var(--lv-dim);
    font-size: 12px;
    font-weight: 600;
}

#cshow-live.cs-screen .cs-lv-soldbar .cs-lv-soldbar-txt b { color: var(--lv-red); font-size: 15px; font-weight: 800; }

#cshow-live.cs-screen .cs-lv-soldbar .cs-lv-soldbar-track {
    display: block;
    height: 8px;
    overflow: hidden;
    border-radius: 4px;
    background: #F1F1F4;
}

#cshow-live.cs-screen .cs-lv-soldbar .cs-lv-soldbar-fill {
    display: block;
    width: 0;
    height: 100%;
    border-radius: 4px;
    background: linear-gradient(90deg, var(--lv-yellow) 0%, var(--lv-red) 100%);
}

#cshow-live.cs-screen .cs-lv-soldbar-fill.is-p1, #cshow-live.cs-screen .cs-lv-ubar.is-cont i.is-p1 { width: 10%; }
#cshow-live.cs-screen .cs-lv-soldbar-fill.is-p2, #cshow-live.cs-screen .cs-lv-ubar.is-cont i.is-p2 { width: 20%; }
#cshow-live.cs-screen .cs-lv-soldbar-fill.is-p3, #cshow-live.cs-screen .cs-lv-ubar.is-cont i.is-p3 { width: 30%; }
#cshow-live.cs-screen .cs-lv-soldbar-fill.is-p4, #cshow-live.cs-screen .cs-lv-ubar.is-cont i.is-p4 { width: 40%; }
#cshow-live.cs-screen .cs-lv-soldbar-fill.is-p5, #cshow-live.cs-screen .cs-lv-ubar.is-cont i.is-p5 { width: 50%; }
#cshow-live.cs-screen .cs-lv-soldbar-fill.is-p6, #cshow-live.cs-screen .cs-lv-ubar.is-cont i.is-p6 { width: 60%; }
#cshow-live.cs-screen .cs-lv-soldbar-fill.is-p7, #cshow-live.cs-screen .cs-lv-ubar.is-cont i.is-p7 { width: 70%; }
#cshow-live.cs-screen .cs-lv-soldbar-fill.is-p8, #cshow-live.cs-screen .cs-lv-ubar.is-cont i.is-p8 { width: 80%; }
#cshow-live.cs-screen .cs-lv-soldbar-fill.is-p9, #cshow-live.cs-screen .cs-lv-ubar.is-cont i.is-p9 { width: 90%; }
#cshow-live.cs-screen .cs-lv-soldbar-fill.is-p10, #cshow-live.cs-screen .cs-lv-ubar.is-cont i.is-p10 { width: 100%; }
#cshow-live.cs-screen .cs-lv-ubar.is-cont i.is-p0 { width: 0; }

#cshow-live.cs-screen .cs-lv-soldbar.is-gone b {
    align-self: flex-start;
    padding: 4px 10px;
    border-radius: 8px;
    background: var(--lv-ink);
    color: #FFFFFF;
    font-family: var(--lv-cond);
    font-size: 16px;
}

/* ---------------------------------------------------------------- 📺 EN LA TV */

#cshow-live.cs-screen .cs-lv-tvtag {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 3px 8px;
    border-radius: 999px;
    background: var(--lv-ink);
    color: #FFFFFF;
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 0.06em;
}

#cshow-live.cs-screen .cs-lv-tvtag .cs-lv-tvico { width: 11px; height: 8px; border-width: 1.5px; }
#cshow-live.cs-screen .cs-lv-tvtag .cs-lv-tvico::after { bottom: -4px; height: 1.5px; }

/* ---------------------------------------------------------------- ⚡ GRUPO box (one clock) */

#cshow-live.cs-screen .cs-lv-gbox {
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding: 12px;
    border: 1.5px solid var(--lv-yellow);
    border-radius: 20px;
    background: #FFFBEB;
    box-shadow: 0 8px 22px rgba(255, 194, 26, 0.22);
}

#cshow-live.cs-screen .cs-lv-gbox.is-tv { box-shadow: 0 0 0 2px rgba(255, 194, 26, 0.55), 0 8px 22px rgba(255, 194, 26, 0.30); }
#cshow-live.cs-screen .cs-lv-gbox .cs-lv-gbox-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; }
#cshow-live.cs-screen .cs-lv-gbox .cs-lv-gbox-title { flex: 1 1 auto; min-width: 0; }
#cshow-live.cs-screen .cs-lv-gbox .cs-lv-gbox-title p { margin: 0; }

#cshow-live.cs-screen .cs-lv-gbox .cs-lv-gbox-kicker {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 6px;
    color: #8A6400;
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 0.1em;
}

#cshow-live.cs-screen .cs-lv-gbox .cs-lv-gbox-name { margin-top: 3px; font-family: var(--lv-cond); font-size: 24px; font-weight: 800; line-height: 1.05; }
#cshow-live.cs-screen .cs-lv-gbox .cs-lv-gbox-sub { margin-top: 3px; color: var(--lv-dim); font-size: 13px; }

#cshow-live.cs-screen .cs-lv-gbox .cs-lv-gbox-up {
    display: none;
    margin: 0;
    padding: 8px 10px;
    border-radius: 10px;
    background: #FFFFFF;
    color: var(--lv-dim);
    font-weight: 800;
    text-align: center;
}

#cshow-live.cs-screen .cs-lv-gbox.is-timeup .cs-lv-gbox-up { display: block; }
#cshow-live.cs-screen .cs-lv-gbox .cs-lv-gbox-list { display: flex; flex-direction: column; gap: 8px; }
#cshow-live.cs-screen .cs-lv-gbox .cs-lv-gbox-list .cs-lv-row { box-shadow: none; }

/* ---------------------------------------------------------------- "Ver todas (5) ▾" */

#cshow-live.cs-screen .cs-lv-more-btn {
    display: block;
    width: 100%;
    min-height: 44px;
    margin: 0 0 8px;
    border: 1px solid var(--lv-line);
    border-radius: 12px;
    background: #FFFFFF;
    color: var(--lv-ink);
    font: inherit;
    font-size: 15px;
    font-weight: 700;
    cursor: pointer;
}

/* ---------------------------------------------------------------- ⚡ more shine (owner 2026-12-03)
 * The deals in ② "pump": a soft heartbeat (scale) + a yellow glow that breathes, and a light
 * sweep that crosses each card. Only transform / opacity / box-shadow. The Ronda rows stay calm.
 * "Reduce motion" on the phone turns it off (shared animations css).
 */

#cshow-live.cs-screen .cs-lv-flash .cs-lv-rows > .cs-lv-row,
#cshow-live.cs-screen .cs-lv-flash .cs-lv-gbox {
    position: relative;
    overflow: hidden;
    border: 2px solid var(--lv-yellow);
    background: linear-gradient(180deg, #FFFBEB 0%, #FFFFFF 45%);
    animation: cs-lv-flash-pump 1.8s ease-in-out infinite, cs-lv-flash-glow 1.8s ease-in-out infinite;
}

/* the cards don't all beat together */
#cshow-live.cs-screen .cs-lv-flash .cs-lv-rows > :nth-child(2) { animation-delay: 0.3s; }
#cshow-live.cs-screen .cs-lv-flash .cs-lv-rows > :nth-child(3) { animation-delay: 0.6s; }

/* a light sweep across the card */
#cshow-live.cs-screen .cs-lv-flash .cs-lv-rows > .cs-lv-row::after,
#cshow-live.cs-screen .cs-lv-flash .cs-lv-gbox::after {
    content: "";
    position: absolute;
    top: 0;
    bottom: 0;
    left: -60%;
    z-index: 0;
    width: 40%;
    background: linear-gradient(100deg, rgba(255, 194, 26, 0) 0%, rgba(255, 214, 90, 0.45) 50%, rgba(255, 194, 26, 0) 100%);
    transform: skewX(-20deg);
    pointer-events: none;
    animation: cs-lv-sweep 3.2s ease-in-out infinite;
}

#cshow-live.cs-screen .cs-lv-flash .cs-lv-row > *,
#cshow-live.cs-screen .cs-lv-flash .cs-lv-gbox > * { position: relative; z-index: 1; }

/* sold out / time up: no more shine */
#cshow-live.cs-screen .cs-lv-flash .cs-lv-row.is-gone,
#cshow-live.cs-screen .cs-lv-flash .cs-lv-row.is-timeup,
#cshow-live.cs-screen .cs-lv-flash .cs-lv-gbox.is-timeup { animation: none; border-color: #E4E4EA; box-shadow: none; }
#cshow-live.cs-screen .cs-lv-flash .cs-lv-row.is-gone::after,
#cshow-live.cs-screen .cs-lv-flash .cs-lv-row.is-timeup::after,
#cshow-live.cs-screen .cs-lv-flash .cs-lv-gbox.is-timeup::after { display: none; }

/* rows inside a group box: the box pumps, not each row */
#cshow-live.cs-screen .cs-lv-flash .cs-lv-gbox .cs-lv-gbox-list .cs-lv-row { animation: none; border-width: 1px; }

/* the ⚡ square of the title beats too */
#cshow-live.cs-screen .cs-lv-flash .cs-lv-sec-ico {
    box-shadow: 0 0 0 0 rgba(255, 194, 26, 0.7);
    animation: cs-lv-flash-ring 1.8s ease-out infinite;
}

@keyframes cs-lv-flash-pump {
    0%, 100% { transform: scale(1); }
    12%      { transform: scale(1.025); }
    24%      { transform: scale(1); }
    36%      { transform: scale(1.015); }
    48%      { transform: scale(1); }
}

@keyframes cs-lv-flash-glow {
    0%, 100% { box-shadow: 0 0 0 0 rgba(255, 194, 26, 0.0), 0 6px 18px rgba(255, 194, 26, 0.25); }
    15%      { box-shadow: 0 0 0 5px rgba(255, 194, 26, 0.35), 0 8px 28px rgba(255, 194, 26, 0.60); }
    50%      { box-shadow: 0 0 0 2px rgba(255, 194, 26, 0.20), 0 6px 22px rgba(255, 194, 26, 0.40); }
}

@keyframes cs-lv-flash-ring {
    0%   { box-shadow: 0 0 0 0 rgba(255, 194, 26, 0.7); }
    70%  { box-shadow: 0 0 0 10px rgba(255, 194, 26, 0); }
    100% { box-shadow: 0 0 0 0 rgba(255, 194, 26, 0); }
}
