/* =============================================
   HERO 4-BOX MOTION GALLERY
   ============================================= */

/* CTA Button Styling */
.cta-button {
    background: linear-gradient(135deg, #ff6b35, #ff8c42);
    color: white;
    font-size: 1.1rem;
    font-weight: 600;
    padding: 14px 32px;
    border: none;
    border-radius: 50px;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    margin-top: 24px;
    box-shadow: 0 4px 15px rgba(255, 107, 53, 0.4);
    transition: all 0.3s ease;
}

.cta-button:hover {
    background: linear-gradient(135deg, #ff8c42, #ff6b35);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(255, 107, 53, 0.5);
}

.cta-button:active {
    transform: translateY(0);
}

.cta-button i {
    font-size: 1rem;
    transition: transform 0.3s ease;
}

.cta-button:hover i {
    transform: translateX(4px);
}


/* Motion Gallery Container */
.hero-motion-gallery {
    display: flex;
    gap: 20px;
    width: 100%;
    max-width: 600px;
    height: 600px;
    overflow: hidden;
    padding: 20px 0;
    margin: 0 auto;
}

/* Gallery Columns */
.gallery-col {
    display: flex;
    flex-direction: column;
    gap: 20px;
    width: 50%;
    will-change: transform;
}

/* Removed Continuous Floating Animations */
.gallery-col.up {
    /* animation: floatUp 15s ease-in-out infinite alternate; */
}

.gallery-col.down {
    /* animation: floatDown 15s ease-in-out infinite alternate; */
}

@keyframes floatUp {
    0% { transform: translateY(0); }
    100% { transform: translateY(-30%); }
}

@keyframes floatDown {
    0% { transform: translateY(-30%); }
    100% { transform: translateY(0); }
}

/* Individual box */
.hero-box {
    position: relative;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4);
    border: 2px solid rgba(255, 255, 255, 0.25);
    transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275), box-shadow 0.4s ease, border-color 0.4s ease;
    aspect-ratio: 4/5;
    background: linear-gradient(135deg, rgba(255,255,255,0.1), rgba(255,255,255,0));
    backdrop-filter: blur(10px);
}

.hero-box:hover {
    transform: translateZ(40px) scale(1.05);
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.6);
    border-color: rgba(251, 146, 60, 0.6);
    z-index: 10;
}

/* Box carousel container */
.box-carousel {
    width: 100%;
    height: 100%;
    position: relative;
}

.box-slide {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    border-radius: 0;
}


/* Loading/placeholder state */
.box-slide[src=""],
.box-slide:not([src]) {
    background: linear-gradient(135deg, var(--bg-secondary) 0%, var(--bg-primary) 100%);
}

/* ========================================
   RESPONSIVE DESIGN
   ======================================== */

@media (max-width: 992px) {
    .hero-motion-gallery {
        height: 500px;
        transform: rotateY(0deg) rotateX(0deg); /* Disable 3D tilt on smaller screens */
    }

    .hero-box {
        border-radius: 16px;
    }
}

@media (max-width: 768px) {
    .hero-motion-gallery {
        max-width: 100%;
        gap: 15px;
        height: 400px;
    }

    .gallery-col {
        gap: 15px;
    }
}

@media (max-width: 480px) {
    .hero-motion-gallery {
        gap: 10px;
        height: 350px;
    }

    .gallery-col {
        gap: 10px;
    }

    .hero-box {
        border-radius: 12px;
        aspect-ratio: 1; /* Make them square on mobile for better fit */
    }

    .hero-box:hover {
        transform: scale(1.02);
    }
}

/* Dark mode support */
[data-theme="dark"] .hero-box {
    box-shadow: none;
}

[data-theme="dark"] .hero-box:hover {
    box-shadow: none;
}

/* ========================================
   CUSTOM HERO BUTTON RESPONSIVE FIXES
   ======================================== */
@media (max-width: 768px) {
    /* Ignore the dragged coordinates on mobile because aspect ratio changes */
    /* Force the button to sit nicely at the bottom center */
    .custom-hero-btn-wrap {
        top: auto !important;
        bottom: 12% !important;
        left: 50% !important;
        transform: translate(-50%, 0) !important;
    }
    
    /* Scale the button down so it doesn't look gigantic */
    .custom-hero-btn {
        padding: 10px 24px !important;
        font-size: 0.9rem !important;
    }
}

@media (max-width: 480px) {
    .custom-hero-btn-wrap {
        bottom: 10% !important;
    }
    .custom-hero-btn {
        padding: 8px 18px !important;
        font-size: 0.8rem !important;
    }
}