/* Wind Arrow Animation */
@keyframes wiggle {
    0%, 100% {
        top: 0;
        transform: rotate(0deg);
    }
    15% {
        transform: rotate(7deg);
    }
    30% {
        transform: rotate(-7deg);
    }
    50% {
        top: -1.25rem;
        transform: rotate(0deg);
    }
}

.animate-wiggle-arrow {
animation: wiggle 2s ease-in-out infinite;
}

/* Current Weather Icon Animation */
@keyframes float {
    0% {
        transform: translateY(0px);
    }
    50% {
        transform: translateY(-8px);
    }
    100% {
        transform: translateY(0px);
    }
}

.animate-float {
    animation: float 4s ease-in-out infinite;
}

/* Clothing pop effect */
@keyframes pop-in {
0% {
    opacity: 0;
    transform: scale(0.5);
}
100% {
    opacity: 1;
    transform: scale(1);
}
}

/* Wiggle Worm Animation */
@keyframes wiggle-worm {
    0%, 100% { transform: rotate(0deg); }
    25% { transform: rotate(8deg) translateX(5px); }
    75% { transform: rotate(-8deg) translateX(-5px); }
}

.animate-wiggle-worm {
    display: inline-block; /* Important for transform to work */
    animation: wiggle-worm 1.5s ease-in-out infinite;
}

/* Raindrop Animation */
.raindrop {
    position: absolute;
    bottom: 100%;
    width: 2px;
    height: 15px;
    background: linear-gradient(to bottom, rgba(255,255,255,0), #19c9e0); /* Use a teal color */
    border-radius: 50%;
    animation: fall 1s linear infinite;
}

@keyframes fall {
    to {
        transform: translateY(150px); /* Adjust based on card height */
        opacity: 0;
    }
}

/* Daytime Slider */
/* Hides the default thumb across browsers */
input[type="range"].custom-slider-track::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 0;
    height: 0;
    background: transparent;
    border: none;
}

input[type="range"].custom-slider-track::-moz-range-thumb {
    width: 0;
    height: 0;
    background: transparent;
    border: none;
}

/* Add the gradient colors for the slider track */
.custom-slider-track::-webkit-slider-runnable-track {
    width: 100%;
    height: 100%;
    background: linear-gradient(
        to right,
        #2c3e50 0%,     /* Deep Night */
        #ff6b6b 25%,    /* Sunrise */
        #ffe66d 50%,    /* Midday */
        #ff9f43 75%,    /* Sunset */
        #2c3e50 100%    /* Deep Night */
    );
    border-radius: 9999px;
}

.custom-slider-track::-moz-range-track {
    width: 100%;
    height: 100%;
    background: linear-gradient(
        to right,
        #2c3e50 0%,
        #ff6b6b 25%,
        #ffe66d 50%,
        #ff9f43 75%,
        #2c3e50 100%
    );
    border-radius: 9999px;
}

/* Path Animation */
@keyframes draw-in {
    to {
        stroke-dashoffset: 0;
    }
}

/* This class will be added by JavaScript to trigger the animation */
.is-drawing {
    animation: draw-in 3.5s ease-out forwards;
}

.content-on-top {
    position: relative;
    z-index: 1;
    background-color: rgba(203, 233, 255, 0.462); /* Translucent background */
    backdrop-filter: blur(2px); /* Optional: blurs the background behind it */
    border-radius: 1rem; /* Rounded corners */
    border: 4px solid rgba(147, 196, 253, 0.274); /* Semi-transparent blue border */
    box-shadow: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
}

.sun-background {
    position: absolute;
    top: 5rem;
    left: 0;
    width: 100%;
    height: 90%;
    pointer-events: none;
    overflow: hidden;
    z-index: -3; /* Behind Clouds */
}

.weather-background {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
    z-index: -2; /* Sits on top of the sun/rays */
}

.cloud {
    position: absolute;
    /* The background-image is set by JavaScript */
    background-repeat: no-repeat;
    background-size: contain;
    width: 200px;
    height: 100px;
    animation: drift linear infinite;
}

@keyframes drift {
    from { transform: translateX(-250px); }
    to { transform: translateX(100vw); }
}

.sun-icon {
    position: absolute;
    z-index: -1;
    top: -20px;
    left: -20px;
    width: 120px;
    height: 120px;
}

.sun-ray {
    position: absolute;
    z-index: -2;
    top: 0;
    left: 0;
    width: 150%;
    height: 10px;
    background: linear-gradient(to right, rgba(255, 223, 109, 0.7), transparent);
    transform-origin: top left;
    border-radius: 9999px;
    animation: shimmer 3s ease-in-out infinite;
}

@keyframes shimmer {
    0%, 100% {
        opacity: 0.4;
    }
    50% {
        opacity: 0.9;
    }
}
@keyframes spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}