/* 🎯 BUY NOW INTEGRATION FINAL OVERRIDES - PERFECT DISPLAY */

/* Force Integrated Design - Match Other Info Items */
.buy-now-price-item {
    display: flex !important;
    position: relative !important;
    grid-column: 1 / -1 !important;
    margin: 0 0 0.75rem 0 !important;
    padding: 0 !important;
    background: none !important;
    border: none !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    max-width: none !important;
    width: 100% !important;
    order: 2 !important;
}

/* Ensure Info Item Container Matches Others */
.buy-now-price-item .info-item {
    background: rgba(255, 255, 255, 0.05) !important;
    border: 1px solid rgba(255, 255, 255, 0.1) !important;
    padding: 0.75rem !important;
    margin: 0 !important;
    border-radius: 6px !important;
    box-shadow: none !important;
    display: flex !important;
    justify-content: space-between !important;
    align-items: center !important;
    width: 100% !important;
    overflow: hidden !important;
}

/* Label Styling - Match Other Info Items */
.buy-now-price-item .label {
    color: rgba(255, 255, 255, 0.7) !important;
    font-size: 0.8rem !important;
    font-weight: 500 !important;
    margin-bottom: 0 !important;
    flex-shrink: 0 !important;
    display: block !important;
    position: static !important;
    top: auto !important;
    left: auto !important;
    transform: none !important;
    width: auto !important;
    text-align: left !important;
    background: none !important;
    border: none !important;
    padding: 0 !important;
}

/* Value Container - Match Info Item Style */
.buy-now-price-item .value {
    display: block !important;
    width: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
    background: none !important;
    border: none !important;
    flex: 1 !important;
    grid-column: auto !important;
    grid-row: auto !important;
    text-align: right !important;
}

/* Buy Now Value Container - Integrated Styling */
.buy-now-price-item .buy-now-price-value {
    display: flex !important;
    flex-direction: row !important;
    align-items: center !important;
    justify-content: space-between !important;
    text-align: left !important;
    width: 100% !important;
    margin: 0 !important;
    box-sizing: border-box !important;
    padding: 0.75rem 1rem !important;
    border-radius: 8px !important;
    background: linear-gradient(135deg, #ff0844 0%, #ff3366 25%, #ff6b35 75%, #ff0844 100%) !important;
    background-size: 300% 300% !important;
    animation: premiumPulse 4s ease-in-out infinite !important;
    border: 1px solid rgba(255, 255, 255, 0.3) !important;
    box-shadow: 0 6px 20px rgba(255, 8, 68, 0.3) !important;
}

/* Remove Any Inherited Flex or Grid Properties */
.buy-now-price-item * {
    box-sizing: border-box !important;
}

/* Ensure Icons Don't Get Overridden */
.buy-now-badge::before,
.buy-now-badge::after,
.buy-now-price-item .label::before {
    display: inline-block !important;
    vertical-align: middle !important;
}

/* Force Z-Index Stacking */
.buy-now-price-item {
    z-index: 10 !important;
    isolation: isolate !important;
}

.buy-now-price-value {
    z-index: 11 !important;
}

.buy-now-price-item .label {
    z-index: 12 !important;
}

/* Mobile Specific Overrides */
@media (max-width: 768px) {
    .buy-now-price-item {
        margin: 0 0 0.5rem 0 !important;
    }
    
    .buy-now-price-item .label {
        font-size: 0.75rem !important;
    }
    
    .buy-now-price-value {
        padding: 0.6rem 0.8rem !important;
        flex-direction: column !important;
        gap: 0.5rem !important;
        text-align: center !important;
    }
}

@media (max-width: 480px) {
    .buy-now-price-item {
        margin: 0 0 0.5rem 0 !important;
    }
    
    .buy-now-price-item .label {
        font-size: 0.7rem !important;
    }
    
    .buy-now-price-value {
        padding: 0.5rem 0.6rem !important;
    }
}

/* Animation Performance Optimization */
.buy-now-price-item,
.buy-now-price-value,
.buy-now-amount,
.buy-now-badge {
    transform: translateZ(0) !important;
    backface-visibility: hidden !important;
    perspective: 1000px !important;
}

/* Prevent Text Selection on Animated Elements */
.buy-now-badge,
.buy-now-amount,
.buy-now-price-item .label {
    user-select: none !important;
    -webkit-user-select: none !important;
    -moz-user-select: none !important;
    -ms-user-select: none !important;
}

/* High DPI Display Optimization */
@media (-webkit-min-device-pixel-ratio: 2), (min-resolution: 192dpi) {
    .buy-now-price-value {
        transform: translate3d(0, 0, 0) !important;
    }
}

/* Dark Mode Compatibility */
@media (prefers-color-scheme: dark) {
    .buy-now-price-item {
        /* Premium styling already optimized for dark backgrounds */
    }
}

/* Light Mode Compatibility */
@media (prefers-color-scheme: light) {
    .buy-now-price-item {
        /* Ensure visibility on light backgrounds */
        filter: contrast(1.1) !important;
    }
}

/* Ensure Critical Animations Work */
@supports (animation: gradient) {
    .buy-now-price-value {
        animation-play-state: running !important;
    }
}

/* Fallback for Browsers Without Gradient Support */
@supports not (background: linear-gradient(45deg, red, blue)) {
    .buy-now-price-value {
        background: #ff0844 !important;
    }
    
    .buy-now-price-item .label {
        background: #ff6b35 !important;
    }
}

/* Print Styles - Hide Animations */
@media print {
    .buy-now-price-item,
    .buy-now-price-value,
    .buy-now-badge,
    .buy-now-amount {
        animation: none !important;
        transition: none !important;
        transform: none !important;
        filter: none !important;
    }
}

/* Container Query Support (Future-proofing) */
@container (max-width: 600px) {
    .buy-now-price-value {
        padding: 1.5rem 1rem !important;
    }
}

/* Focus-Visible Support for Better Accessibility */
.buy-now-price-item:focus-visible {
    outline: 3px solid rgba(255, 255, 255, 0.6) !important;
    outline-offset: 4px !important;
}

/* Remove Default Button/Link Styling If Applied */
.buy-now-price-item button,
.buy-now-price-item a {
    all: unset !important;
    display: block !important;
    width: 100% !important;
    cursor: pointer !important;
}

/* Ensure Proper Text Rendering */
.buy-now-amount,
.buy-now-badge,
.buy-now-price-item .label {
    text-rendering: optimizeLegibility !important;
    -webkit-font-smoothing: antialiased !important;
    -moz-osx-font-smoothing: grayscale !important;
}

/* Final Quality Assurance */
.buy-now-price-item {
    /* Ensure the tile is always visible and properly styled */
    visibility: visible !important;
    opacity: 1 !important;
    pointer-events: auto !important;
    contain: layout style paint !important;
}
