/* CLS OPTIMIZATION CSS - /css/cls-optimization.css */
/* Non-critical CLS prevention styles that can be loaded externally */

/* Container responsive behavior without device detection */
.container {
    width: 100%;
    padding-right: 15px;
    padding-left: 15px;
    margin-right: auto;
    margin-left: auto;
}

@media (min-width: 576px) {
    .container {
        max-width: 540px;
    }
}

@media (min-width: 768px) {
    .container {
        max-width: 720px;
    }
}

@media (min-width: 992px) {
    .container {
        max-width: 960px;
    }
}

@media (min-width: 1200px) {
    .container {
        max-width: 1140px;
    }
}

/* Grid system without device detection */
.col-xs-12,
.col-sm-12,
.col-md-12,
.col-lg-12 {
    position: relative;
    width: 100%;
    padding-right: 15px;
    padding-left: 15px;
}

/* Image optimizations */
img {
    max-width: 100%;
    height: auto;
    vertical-align: middle;
}

/* Prevent layout shifts from dynamic content */
.superbox-show {
    position: relative;
    min-height: 400px;
}

@media (min-width: 768px) {
    .superbox-show {
        min-height: 600px;
    }
}

/* Force hardware acceleration for smoother rendering */
.superbox-img-holder,
.superbox-current-img,
.related-items {
    transform: translateZ(0);
    will-change: transform;
}

/* Override external CSS that might cause shifts */
* {
    box-sizing: border-box;
}

/* Consistent rendering across browsers */
body,
html {
    margin: 0;
    padding: 0;
    height: 100%;
    overflow-x: hidden;
}

/* Font loading optimization */
body {
    font-display: swap;
}

/* Remove all problematic animations */
.animated.fadeInDown,
.animated.fadeIn,
.animated.slideIn {
    animation: none !important;
    opacity: 1 !important;
    transform: none !important;
}