/* ═══════════════════════════════════════════════════════════ */
/* YONO BAZAAR — COUNTDOWN STYLES                             */
/* Independent file. Loaded alongside style.css.              */
/* ═══════════════════════════════════════════════════════════ */

/* ── Container ──────────────────────────────────────────────── */
#countdownContainer {
    padding: 0 10px 10px;
    display: none;            /* shown by JS when active */
    contain: layout style;    /* layout isolation — no reflow bleed */
}

/* Hide countdown during search or Rummy category */
body.is-searching #countdownContainer {
    display: none !important;
}

/* ── Banner card ─────────────────────────────────────────────── */
.countdown-banner {
    background: linear-gradient(135deg, #2c3e50, #4ca1af);
    color: #fff;
    border-radius: var(--radius-card, 14px);
    padding: 8px 12px;
    display: flex;
    align-items: center;
    gap: 12px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.25);
    will-change: transform;   /* promote to compositor layer — smoother */
}

/* ── App poster ──────────────────────────────────────────────── */
.countdown-poster {
    width: 55px;
    height: 55px;
    border-radius: 12px;
    object-fit: cover;
    border: 2px solid var(--color-gold, #FFD700);
    flex-shrink: 0;
    aspect-ratio: 1 / 1;
}

/* ── Right column ────────────────────────────────────────────── */
.countdown-details {
    flex-grow: 1;
    text-align: center;
    min-width: 0;             /* prevent flex overflow */
}

/* ── App title — mirror right-to-left animation ──────────────── */
@keyframes mirrorRTL {
    0%   { background-position: 200% center; }
    100% { background-position: -200% center; }
}

.countdown-app-title {
    font-size: 18px;
    font-style: italic;
    font-weight: 900;
    margin: 4px 0;
    text-transform: uppercase;
    letter-spacing: 1.2px;
    background: linear-gradient(
        90deg,
        #FF5722 0%,
        #FFD700 25%,
        #fff    50%,
        #FFD700 75%,
        #FF5722 100%
    );
    background-size: 200% auto;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: mirrorRTL 2.5s linear infinite;
    filter: drop-shadow(0 2px 3px rgba(0, 0, 0, 0.4));
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* ── Lightning effect (decorative divider) ───────────────────── */
.lightning-effect {
    height: 2px;
    background: linear-gradient(90deg, transparent, #FFD700, transparent);
    margin: 3px 0;
    border-radius: 1px;
    opacity: 0.7;
}

/* ── Timer wrapper ───────────────────────────────────────────── */
.countdown-timer-wrapper {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin-top: 4px;
}

/* ── Individual block (Days / Hours / Mins / Secs) ───────────── */
.countdown-block {
    text-align: center;
    min-width: 36px;
}

/* ── Digit display ───────────────────────────────────────────── */
.countdown-number {
    font-size: 18px;
    font-weight: 700;
    background-color: rgba(255, 255, 255, 0.15);
    padding: 3px 6px;
    border-radius: 5px;
    min-width: 26px;
    display: inline-block;
    /* Stable width prevents layout shift on digit change */
    font-variant-numeric: tabular-nums;
    letter-spacing: 0.5px;
}

/* ── Label below digit ───────────────────────────────────────── */
.countdown-label {
    font-size: 9px;
    text-transform: uppercase;
    margin-top: 2px;
    color: #e0e0e0;
    letter-spacing: 0.5px;
}

/* ── Reduced motion ──────────────────────────────────────────── */
@media (prefers-reduced-motion: reduce) {
    .countdown-banner    { will-change: auto; }
    .countdown-app-title { animation: none !important; }
    .lightning-effect    { animation: none !important; }
}

/* ── Mobile tweaks ───────────────────────────────────────────── */
@media (max-width: 360px) {
    .countdown-app-title { font-size: 15px; letter-spacing: 0.8px; }
    .countdown-number    { font-size: 16px; padding: 2px 5px; }
    .countdown-poster    { width: 46px; height: 46px; }
    .countdown-timer-wrapper { gap: 5px; }
}
