/* Animated Shapes Fix - Keep All Decorative Elements Behind Text */
/* Updated with proper header z-index consideration */

/* Z-index hierarchy:
   - Header/Navigation: 9999+
   - Interactive elements in content: 15
   - Text content: 10
   - Light overlay: 1
   - Background & decorative shapes: 0
*/

/* Common animated shape selectors - force behind text */
.tp-caption[data-type="image"],
.tp-caption[data-type="shape"],
.tp-static[data-type="image"],
.tp-static[data-type="shape"],
.rs-layer[data-type="image"],
.rs-layer[data-type="shape"] {
    z-index: 0 !important;
    pointer-events: none !important;
}

/* Specific animated elements that commonly appear in sliders */
.floating-circle,
.animated-circle,
.hero-decoration,
.slider-decoration,
.background-animation,
.particle-animation,
.geometric-shape,
.abstract-shape {
    z-index: 0 !important;
    pointer-events: none !important;
}

/* Revolution Slider specific animated layers */
.tp-parallax-wrap,
.tp-loop-wrap,
.tp-mask-wrap {
    z-index: 0 !important;
}

/* Any element with animation classes that should be decorative */
[data-frames*="animation"],
[data-transform*="animation"],
[class*="animate__"],
[class*="aos-"],
.fadeIn,
.fadeInUp,
.bounceIn,
.zoomIn,
.rotateIn {
    z-index: 0 !important;
}

/* Ensure all text captions stay on top */
.tp-caption[data-type="text"],
.tp-caption h1,
.tp-caption h2,
.tp-caption h3,
.tp-caption h4,
.tp-caption p,
.tp-caption span,
.slider_01 .tp-caption,
.slider_02 .tp-caption,
.slider_03 .tp-caption {
    z-index: 10 !important;
    position: relative !important;
}

/* Buttons and interactive elements even higher */
.tp-caption .qu_btn,
.tp-caption a,
.tp-caption button,
.slider_01 .qu_btn,
.slider_02 .qu_btn,
.slider_03 .qu_btn {
    z-index: 15 !important;
    position: relative !important;
}

/* Override any inline z-index styles on decorative elements */
[style*="z-index"][data-type="image"],
[style*="z-index"][data-type="shape"] {
    z-index: 0 !important;
}

/* Override any inline z-index styles on text elements */
[style*="z-index"][data-type="text"] {
    z-index: 10 !important;
}
