.back-button {
    position: fixed;
    bottom: 20px;
    right: 20px;
    padding: 10px 20px;
    background-color: var(--tg-theme-button-color, #697bb4) !important;
    color: var(--tg-theme-button-text-color, #ffffff);
    border: none;
    border-radius: 30px;
    cursor: pointer;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
    z-index: 9999;
}

@keyframes intenseBurn {
    0%, 100% {
        text-shadow: 
            0 0 8px #ff7700,
            0 0 16px #ff5500,
            0 0 24px #ff3300,
            0 0 32px #ff2200,
            0 0 40px #ff0000;
        transform: scale(1);
    }
    25% {
        text-shadow: 
            0 0 12px #ffaa00,
            0 0 20px #ff7700,
            0 0 28px #ff5500,
            0 0 36px #ff3300,
            0 0 44px #ff2200;
        transform: scale(1.04);
    }
    50% {
        text-shadow: 
            0 0 18px #ffdd00,
            0 0 26px #ffaa00,
            0 0 34px #ff7700,
            0 0 42px #ff5500,
            0 0 50px #ff3300;
        transform: scale(1.08);
    }
    75% {
        text-shadow: 
            0 0 12px #ffaa00,
            0 0 20px #ff7700,
            0 0 28px #ff5500,
            0 0 36px #ff3300,
            0 0 44px #ff2200;
        transform: scale(1.04);
    }
}

.burning-price {
    animation: intenseBurn 1.6s ease-in-out infinite;
    background: linear-gradient(135deg, #FFE53B, #FF6A00, #fac003);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    font-weight: 900;
    display: inline-block;
    text-shadow: 
    0 0 8px #ff7700,
    0 0 16px #ff5500,
    0 0 24px #ff3300,
    0 0 24px #ff2200,
    0 0 26px #ff0000;
}

@keyframes flickerGlow {
    0%, 100% { opacity: 1; filter: brightness(1); }
    20% { opacity: 0.9; filter: brightness(1.2); }
    40% { opacity: 1; filter: brightness(1.4); }
    60% { opacity: 0.95; filter: brightness(1.1); }
    80% { opacity: 1; filter: brightness(1.3); }
}

.timer-glow {
    animation: flickerGlow 1.2s ease-in-out infinite;
}

/* Premium Temu Gradient Header */
.temu-gradient {
    background: linear-gradient(356deg,rgba(0, 212, 255, 1) 0%, rgba(9, 9, 121, 1) 100%);
    /* background:  linear-gradient(to right, #dc2626, #ea580c, #f59e0b); linear-gradient(105deg, #0A0C10 0%, #1A1D26 50%, #0F1117 100%); */
    border-bottom: 3px solid #FF6600;
    position: sticky;
    top: 0;
    z-index: 1000;
    width: 100%;
    box-shadow: 0 12px 35px -12px rgba(0,0,0,0.6);
}

/* CRITICAL: ONE ROW LAYOUT for Image, Title, Price, Timer on ALL devices */
.one-row-master {
    display: flex;
    flex-direction: row;
    flex-wrap: nowrap;
    align-items: center;
    gap: 0.75rem;
}

/* Responsive scaling - but always keep row layout */
@media (max-width: 480px) {
    .one-row-master {
        gap: 0.5rem;
    }
    .product-img-mega {
        width: 68px !important;
        height: 68px !important;
        min-width: 68px;
    }
    .price-card {
        padding: 0.35rem 0.5rem !important;
    }
    .timer-card {
        padding: 0.35rem 0.5rem !important;
    }
    .price-value {
        font-size: 1.35rem !important;
    }
    .timer-digit-big {
        font-size: 1rem !important;
        padding: 0.15rem 0.35rem !important;
    }
    .product-title-mobile {
        font-size: 0.7rem !important;
        line-height: 1.2;
    }
    .product-badge {
        font-size: 0.65rem !important;
    }
    .discount-chip {
        font-size: 0.6rem !important;
    }
    .timer-label {
        font-size: 0.55rem !important;
    }
}

@media (min-width: 481px) and (max-width: 640px) {
    .one-row-master {
        gap: 0.7rem;
    }
    .product-img-mega {
        width: 82px !important;
        height: 82px !important;
    }
    .price-value {
        font-size: 1.6rem !important;
    }
    .timer-digit-big {
        font-size: 1.2rem !important;
    }
    .product-title-mobile {
        font-size: 0.8rem !important;
    }
}

@media (min-width: 641px) and (max-width: 768px) {
    .one-row-master {
        gap: 1rem;
    }
    .product-img-mega {
        width: 98px !important;
        height: 98px !important;
    }
    .price-value {
        font-size: 1.9rem !important;
    }
}

@media (min-width: 769px) {
    .one-row-master {
        gap: 1.5rem;
    }
    .product-img-mega {
        width: 120px !important;
        height: 120px !important;
    }
}

.product-img-mega {
    width: 85px;
    height: 85px;
    object-fit: cover;
    border-radius: 1.25rem;
    border: 2.5px solid #FF8C00;
    box-shadow: 0 12px 22px -6px rgba(0,0,0,0.5);
    transition: transform 0.25s ease, box-shadow 0.3s;
}

.product-img-mega:hover {
    transform: scale(1.02);
    box-shadow: 0 15px 28px -8px rgba(255, 100, 0, 0.4);
}

.price-card {
    background: linear-gradient(135deg, #1E1B1B, #2A2424);
    border: 1px solid #FF8C40;
    border-radius: 1rem;
    box-shadow: 0 6px 14px rgba(0,0,0,0.3);
}

.timer-card {
    background: rgba(0, 0, 0, 0.65);
    backdrop-filter: blur(8px);
    border: 1px solid #FFAA55;
    border-radius: 1rem;
    box-shadow: 0 6px 14px rgba(0,0,0,0.3);
}

.timer-digit-big {
    background: #0B0E14;
    border-radius: 10px;
    padding: 0.2rem 0.5rem;
    font-weight: 800;
    font-family: 'Courier New', monospace;
    color: #FFB347;
    box-shadow: inset 0 1px 2px rgba(0,0,0,0.3), 0 2px 5px rgba(255,102,0,0.3);
}

.temu-cta-active {
    background: linear-gradient(95deg, #FF4D00, #FF8C00, #FFB347);
    box-shadow: 0 8px 22px rgba(255, 60, 0, 0.55);
    transition: all 0.2s cubic-bezier(0.2, 0.9, 0.4, 1.1);
}

.temu-cta-active:active {
    transform: scale(0.97);
}

@keyframes shine {
    0% { background-position: -200% 0; }
    100% { background-position: 200% 0; }
}

.shimmer-text {
    background: linear-gradient(90deg, #FFD966, #FFA500, #FFD966);
    background-size: 200% auto;
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    animation: shine 2s linear infinite;
}

/* Temu pulse effect */
@keyframes softPulse {
    0%, 100% { opacity: 0.8; transform: scale(1); }
    50% { opacity: 1; transform: scale(1.02); }
}
.urgency-badge {
    animation: softPulse 1.4s ease-in-out infinite;
}

/* remove any progress bar traces */
.no-progress {
    display: none;
}

@media (max-width: 640px) {
    .burning-price,
    .timer-glow,
    .shimmer-text,
    .urgency-badge {
        animation: none !important;
    }
}
