/* ============================================
   ANIMATED MINT LEAVES BACKGROUND
   For auth pages (login/register)
   ============================================ */

/* Auth page background with gradient */
.auth-container {
    position: relative;
    overflow: hidden;
}

[data-theme="dark"] .auth-container {
    overflow: hidden;
}

/* Floating leaves container */
.floating-leaves {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 1;
    overflow: hidden;
}

/* Individual leaf styling */
.leaf {
    position: absolute;
    font-size: 2rem;
    opacity: 0.3;
    animation: float linear infinite;
    filter: blur(0.5px);
}

/* Leaf variations with random starting positions */
.leaf:nth-child(1) {
    left: 10%;
    animation-duration: 15s;
    animation-delay: 0s;
    font-size: 1.5rem;
    top: -20%;
}

.leaf:nth-child(2) {
    left: 20%;
    animation-duration: 18s;
    animation-delay: 2s;
    font-size: 2rem;
    top: -45%;
}

.leaf:nth-child(3) {
    left: 30%;
    animation-duration: 20s;
    animation-delay: 4s;
    font-size: 1.8rem;
    top: -10%;
}

.leaf:nth-child(4) {
    left: 40%;
    animation-duration: 22s;
    animation-delay: 1s;
    font-size: 2.2rem;
    top: -35%;
}

.leaf:nth-child(5) {
    left: 50%;
    animation-duration: 17s;
    animation-delay: 3s;
    font-size: 1.6rem;
    top: -60%;
}

.leaf:nth-child(6) {
    left: 60%;
    animation-duration: 19s;
    animation-delay: 5s;
    font-size: 2.4rem;
    top: -25%;
}

.leaf:nth-child(7) {
    left: 70%;
    animation-duration: 21s;
    animation-delay: 2.5s;
    font-size: 1.7rem;
    top: -50%;
}

.leaf:nth-child(8) {
    left: 80%;
    animation-duration: 16s;
    animation-delay: 4.5s;
    font-size: 2.1rem;
    top: -15%;
}

.leaf:nth-child(9) {
    left: 90%;
    animation-duration: 23s;
    animation-delay: 1.5s;
    font-size: 1.9rem;
    top: -40%;
}

.leaf:nth-child(10) {
    left: 15%;
    animation-duration: 24s;
    animation-delay: 3.5s;
    font-size: 2.3rem;
    top: -55%;
}

.leaf:nth-child(11) {
    left: 25%;
    animation-duration: 18s;
    animation-delay: 0.5s;
    font-size: 1.4rem;
    top: -30%;
}

.leaf:nth-child(12) {
    left: 35%;
    animation-duration: 20s;
    animation-delay: 2.8s;
    font-size: 2.5rem;
    top: -65%;
}

.leaf:nth-child(13) {
    left: 45%;
    animation-duration: 19s;
    animation-delay: 4.2s;
    font-size: 1.8rem;
    top: -18%;
}

.leaf:nth-child(14) {
    left: 55%;
    animation-duration: 22s;
    animation-delay: 1.8s;
    font-size: 2rem;
    top: -42%;
}

.leaf:nth-child(15) {
    left: 65%;
    animation-duration: 17s;
    animation-delay: 3.2s;
    font-size: 1.6rem;
    top: -28%;
}

.leaf:nth-child(16) {
    left: 75%;
    animation-duration: 21s;
    animation-delay: 5.5s;
    font-size: 2.2rem;
    top: -52%;
}

.leaf:nth-child(17) {
    left: 85%;
    animation-duration: 16s;
    animation-delay: 0.8s;
    font-size: 1.5rem;
    top: -38%;
}

.leaf:nth-child(18) {
    left: 95%;
    animation-duration: 23s;
    animation-delay: 2.2s;
    font-size: 2.4rem;
    top: -48%;
}

.leaf:nth-child(19) {
    left: 5%;
    animation-duration: 20s;
    animation-delay: 4.8s;
    font-size: 1.7rem;
    top: -22%;
}

.leaf:nth-child(20) {
    left: 48%;
    animation-duration: 18s;
    animation-delay: 1.2s;
    font-size: 2.1rem;
    top: -58%;
}

/* Floating animation */
@keyframes float {
    0% {
        transform: translateY(-100px) rotate(0deg);
        opacity: 0;
    }

    10% {
        opacity: 0.3;
    }

    90% {
        opacity: 0.3;
    }

    100% {
        transform: translateY(100vh) rotate(360deg);
        opacity: 0;
    }
}

/* Swaying animation for more natural movement */
.leaf:nth-child(odd) {
    animation-name: floatSway;
}

@keyframes floatSway {
    0% {
        transform: translateY(-100px) translateX(0) rotate(0deg);
        opacity: 0;
    }

    10% {
        opacity: 0.3;
    }

    25% {
        transform: translateY(25vh) translateX(20px) rotate(90deg);
    }

    50% {
        transform: translateY(50vh) translateX(-20px) rotate(180deg);
    }

    75% {
        transform: translateY(75vh) translateX(15px) rotate(270deg);
    }

    90% {
        opacity: 0.3;
    }

    100% {
        transform: translateY(100vh) translateX(0) rotate(360deg);
        opacity: 0;
    }
}

/* Ensure auth card is above leaves */
.auth-card {
    position: relative;
    z-index: 10;
}

/* Add subtle glow effect to leaves in dark mode */
[data-theme="dark"] .leaf {
    opacity: 0.2;
    filter: blur(0.5px) drop-shadow(0 0 5px rgba(0, 184, 148, 0.3));
}

/* Reduce motion for accessibility */
@media (prefers-reduced-motion: reduce) {
    .leaf {
        animation: none;
        display: none;
    }
}

/* Mobile optimization - fewer leaves */
@media (max-width: 768px) {
    .leaf:nth-child(n+11) {
        display: none;
    }

    .leaf {
        font-size: 1.5rem !important;
    }
}

/* Tablet optimization */
@media (min-width: 769px) and (max-width: 1024px) {
    .leaf:nth-child(n+16) {
        display: none;
    }
}