/* =========================================
   1. Main Wrapper (স্টেজ)
   ========================================= */
.roottx-slider-wrapper {
    position: relative;
    width: 100%;
    max-width: 100%;
    margin: 50px auto;
    display: flex;
    justify-content: center;
    align-items: center;
    /* কার্ডের সাইজগুলো ভেরিয়েবল থেকে আসবে */
    height: calc(var(--card-height) + 100px); 
    overflow: hidden; /* স্টেজের বাইরে কিছু দেখা যাবে না */
}

/* =========================================
   2. 3D Container (ম্যাজিক বক্স)
   ========================================= */
.roottx-slides-container {
    position: relative;
    width: 100%;
    height: 100%;
    /* এটাই হলো 3D এফেক্টের চাবিকাঠি */
    perspective: 1000px; 
    transform-style: preserve-3d;
    display: flex;
    justify-content: center;
    align-items: center;
}

/* =========================================
   3. Slide Item (কার্ড)
   ========================================= */
.roottx-slide-item {
    position: absolute;
    width: var(--card-width);
    height: var(--card-height);
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 15px 40px rgba(0,0,0,0.2); /* সুন্দর ছায়া */
    transition: all 0.5s ease-out; /* স্মুথ নড়াচড়া */
    
    /* ডিফল্ট অবস্থায় সব কার্ড মাঝখানে থাকবে, JS দিয়ে সরাব */
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%) scale(0.8);
    opacity: 0; 
    z-index: 0;
    
    /* লাইটবক্সের জন্য কার্সার */
    cursor: pointer;
}

/* যখন কার্ড মাঝখানে (Active) থাকবে */
.roottx-slide-item.active {
    z-index: 100; /* সবার উপরে */
    box-shadow: 0 20px 50px rgba(0,0,0,0.3);
}

/* =========================================
   4. Image Scroller (লিফট / জানালা)
   ========================================= */
.roottx-image-scroller {
    width: 100%;
    height: 100%;
    overflow: hidden; /* জানালার বাইরের লম্বা অংশ লুকানো থাকবে */
    border-radius: 12px;
    position: relative;
    background: #f0f0f0; /* ছবি লোড হওয়ার আগে ব্যাকগ্রাউন্ড */
}

/* ছবির স্টাইল */
.roottx-slide-img {
    width: 100%;
    display: block;
    /* হাইট অটো, যাতে রেশিও ঠিক থাকে */
    height: auto; 
    transition: transform 0.1s linear; /* স্ক্রলিং এর জন্য */
    will-change: transform;
}

/* =========================================
   5. Slide Content (টাইটেল ও বাটন)
   ========================================= */
.roottx-slide-content {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    padding: 20px;
    background: linear-gradient(to top, rgba(0,0,0,0.9), transparent); /* নিচে কালো শেড */
    color: #fff;
    border-radius: 0 0 12px 12px;
    opacity: 0; /* পাশে থাকলে দেখা যাবে না */
    transition: opacity 0.3s ease;
    transform: translateY(10px);
}

/* শুধু মাঝখানের কার্ডে লেখা দেখা যাবে */
.roottx-slide-item.active .roottx-slide-content {
    opacity: 1;
    transform: translateY(0);
}

.slide-title {
    margin: 0 0 10px;
    font-size: 20px;
    font-weight: 700;
    color: #fff;
    text-shadow: 0 2px 4px rgba(0,0,0,0.5);
}

.slide-btn {
    display: inline-block;
    padding: 8px 16px;
    background: #ff4757; /* লালচে বাটন */
    color: #fff;
    text-decoration: none;
    border-radius: 4px;
    font-size: 14px;
    font-weight: 600;
    transition: background 0.3s;
}

.slide-btn:hover {
    background: #ff6b81;
}

/* =========================================
   6. Navigation Arrows (তীর চিহ্ন)
   ========================================= */
.roottx-nav-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 50px;
    height: 50px;
    background: #fff;
    border-radius: 50%;
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
    display: flex;
    justify-content: center;
    align-items: center;
    cursor: pointer;
    z-index: 200;
    transition: all 0.3s ease;
    color: #333;
    font-size: 24px;
}

.roottx-nav-btn:hover {
    background: #333;
    color: #fff;
    transform: translateY(-50%) scale(1.1);
}

.prev-btn { left: 20px; }
.next-btn { right: 20px; }

/* =========================================
   7. Lightbox (পপআপ)
   ========================================= */
.roottx-lightbox-modal {
    display: none; /* শুরুতে লুকানো */
    position: fixed;
    z-index: 99999; /* সবকিছুর উপরে */
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0,0,0,0.9); /* কালো পর্দা */
    justify-content: center;
    align-items: center;
    animation: fadeIn 0.3s;
}

.roottx-lightbox-content {
    margin: auto;
    display: block;
    max-width: 90%;
    max-height: 90vh;
    border-radius: 5px;
    box-shadow: 0 0 20px rgba(255,255,255,0.2);
    animation: zoomIn 0.3s;
}

.roottx-lightbox-close {
    position: absolute;
    top: 20px;
    right: 35px;
    color: #f1f1f1;
    font-size: 40px;
    font-weight: bold;
    cursor: pointer;
    transition: 0.3s;
}

.roottx-lightbox-close:hover {
    color: #ff4757;
}

/* Lightbox Animations */
@keyframes fadeIn {
    from {opacity: 0} 
    to {opacity: 1}
}
@keyframes zoomIn {
    from {transform: scale(0.8)} 
    to {transform: scale(1)}
}

/* =========================================
   8. Responsive (মোবাইল)
   ========================================= */
@media screen and (max-width: 768px) {
    /* মোবাইলে কার্ড ছোট হবে */
    .roottx-slider-wrapper {
        --card-width: 300px !important;
        --card-height: 450px !important;
        height: 500px;
    }
    
    .roottx-nav-btn {
        width: 40px;
        height: 40px;
        font-size: 18px;
    }
    
    .prev-btn { left: 10px; }
    .next-btn { right: 10px; }
}