@tailwind base;
@tailwind components;
@tailwind utilities;

html {
    scroll-behavior: smooth;
}

/* Custom Scroll bar */
html::-webkit-scrollbar {
    width: 10px;
}

html::-webkit-scrollbar-track {
    box-shadow: 0 0 5px #c8cdd5;
    border-radius: 10px;
}

html::-webkit-scrollbar-thumb {
    background-image: linear-gradient(#211c5f, #4b476c);
    border-radius: 10px;
}

@layer utilities {
    .fade-in {
        animation: fadeIn 1.5s ease-in-out;
    }

    @keyframes fadeIn {
        from {
            opacity: 0;
        }

        to {
            opacity: 1;
        }
    }
}


/* Default Styling for Background */
.bg-fixed {
    background-attachment: scroll;
    /* Default for mobile devices */
    background-size: cover;
    background-position: center;
}

/* Fixed Background for Large Devices */
@media (min-width: 1024px) {
    .bg-fixed {
        background-attachment: fixed;
    }
}


#event-section,
#mission,

#contact,

#about,
#gallery {
    padding-top: 150px;
}

/* Skeleton Loading Animation */
.skeleton {
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 200% 100%;
    animation: shimmer 1.5s infinite;
    border-radius: 8px;
}

@keyframes shimmer {
    0% {
        background-position: -200% 0;
    }

    100% {
        background-position: 200% 0;
    }
}

/* Home Section  */

.carousel-slide {
opacity: 0;
transition: opacity 1s ease-in-out;
}

.carousel-slide.active {
opacity: 1;
}

.news-carousel {
display: flex;
animation: scroll 25s linear infinite;
width: max-content;
}

@keyframes scroll {
    from {
        transform: translateX(0);
    }

    to {
        transform: translateX(-50%);
    }
}


/* Seamless marquee ticker */
#tickerTrack {
  --distance: 0px;           /* JS sets exact width */
  --duration: 30s;           /* JS sets dynamic speed */
  animation: tickerMove var(--duration) linear infinite;
  will-change: transform;
}

@keyframes tickerMove {
  from { transform: translateX(0); }
  to   { transform: translateX(calc(-1 * var(--distance))); }
}

.news-item {
  display: inline-flex;
  align-items: center;
}

