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

/* ── Container ──────────────────────────────────────────────── */
#countdownContainer {
    padding: 0 10px 12px;
    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; }
}

/* ═══════════════════════════════════════════════════════════════ */
/* YONO BAZAAR — BANNER CAROUSEL STYLES                           */
/* Image ratio: 2172×724 = 3:1                                    */
/* ═══════════════════════════════════════════════════════════════ */

/* ── Animated border keyframes ────────────────────────────────── */
@keyframes borderGlow {
    0%   { border-color: #FFD700; box-shadow: 0 0 8px 2px rgba(255,215,0,0.55), 0 6px 24px rgba(0,0,0,0.35); }
    25%  { border-color: #FF9500; box-shadow: 0 0 12px 3px rgba(255,149,0,0.5),  0 6px 24px rgba(0,0,0,0.35); }
    50%  { border-color: #FF3CAC; box-shadow: 0 0 14px 4px rgba(255,60,172,0.5), 0 6px 24px rgba(0,0,0,0.35); }
    75%  { border-color: #784BA0; box-shadow: 0 0 12px 3px rgba(120,75,160,0.5), 0 6px 24px rgba(0,0,0,0.35); }
    100% { border-color: #FFD700; box-shadow: 0 0 8px 2px rgba(255,215,0,0.55),  0 6px 24px rgba(0,0,0,0.35); }
}

@keyframes bannerFadeIn {
    from { opacity: 0; transform: translateY(10px) scale(0.98); }
    to   { opacity: 1; transform: translateY(0)    scale(1);    }
}

@keyframes imgReveal {
    from { opacity: 0; transform: scale(1.04); }
    to   { opacity: 1; transform: scale(1);    }
}

/* ── Outer wrapper — holds the glowing border ─────────────────── */
.yb-banner-outer {
    padding: 3px;                          /* border thickness */
    border-radius: 18px;
    background: linear-gradient(135deg, #FFD700, #FF9500, #FF3CAC, #784BA0, #FFD700);
    background-size: 300% 300%;
    animation:
        bannerFadeIn 0.45s ease both,
        borderShift 4s linear infinite;
    box-shadow:
        0 0 10px 2px rgba(255, 215, 0, 0.4),
        0 8px 28px rgba(0, 0, 0, 0.4);
}

@keyframes borderShift {
    0%   { background-position: 0%   50%; }
    50%  { background-position: 100% 50%; }
    100% { background-position: 0%   50%; }
}

/* ── Carousel wrapper (inside the glowing border) ─────────────── */
.yb-banner-carousel {
    position: relative;
    width: 100%;
    border-radius: 15px;                   /* slightly less than outer */
    overflow: hidden;
    background: #0a0a14;
}

/* ── Track ────────────────────────────────────────────────────── */
.yb-banner-track {
    display: flex;
    transition: transform 0.55s cubic-bezier(0.4, 0, 0.2, 1);
    will-change: transform;
    backface-visibility: hidden;
}

/* ── Individual slide ─────────────────────────────────────────── */
.yb-banner-slide {
    flex: 0 0 100%;
    min-width: 100%;
    display: block;
    position: relative;
    background: #0a0a14;
    cursor: pointer;
    text-decoration: none;
    -webkit-tap-highlight-color: transparent;
    overflow: hidden;
    /* ~3.8:1 aspect ratio — wider, shorter banner */
    aspect-ratio: 3.8 / 1;
}

/* Subtle light sweep on hover (desktop) */
.yb-banner-slide::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(
        115deg,
        transparent 35%,
        rgba(255,255,255,0.07) 50%,
        transparent 65%
    );
    opacity: 0;
    transition: opacity 0.35s;
    pointer-events: none;
}
.yb-banner-slide:hover::after { opacity: 1; }

/* Tap press feedback */
.yb-banner-slide:active {
    transform: scale(0.988);
    transition: transform 0.1s;
}

/* ── Banner image — fills the 3:1 card perfectly ─────────────── */
.yb-banner-img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    animation: imgReveal 0.4s ease both;
}

/* ── Dot indicators ───────────────────────────────────────────── */
.yb-banner-dots {
    position: absolute;
    bottom: 9px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 6px;
    z-index: 10;
}

.yb-banner-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    border: none;
    padding: 0;
    background: rgba(255, 255, 255, 0.3);
    cursor: pointer;
    transition: background 0.3s, width 0.35s, border-radius 0.35s;
    flex-shrink: 0;
    -webkit-tap-highlight-color: transparent;
}

.yb-banner-dot.active {
    background: #FFD700;
    width: 20px;
    border-radius: 4px;
    box-shadow: 0 0 7px rgba(255, 215, 0, 0.7);
}

/* ── Reduced motion ───────────────────────────────────────────── */
@media (prefers-reduced-motion: reduce) {
    .yb-banner-outer    { animation: bannerFadeIn 0.3s ease both; }
    .yb-banner-track    { transition: none; }
    .yb-banner-slide    { animation: none; }
    .yb-banner-img      { animation: none; }
    .yb-banner-dot      { transition: none; }
}
