/* Custom CSS for RLS International School */

/* Animations */
@keyframes fade-in-down {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fade-in-up {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fade-in {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

.animate-fade-in-down {
    animation: fade-in-down 0.8s ease-out;
}

.animate-fade-in-up {
    animation: fade-in-up 0.8s ease-out 0.2s both;
}

.animate-fade-in {
    animation: fade-in 0.8s ease-out 0.4s both;
}

/* Smooth Scrolling */
html {
    scroll-behavior: smooth;
}

/* Scroll to Top Button Visibility */
#scroll-to-top.show {
    opacity: 1 !important;
    visibility: visible !important;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 10px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
}

::-webkit-scrollbar-thumb {
    background: #dc2626;
    border-radius: 5px;
}

::-webkit-scrollbar-thumb:hover {
    background: #b91c1c;
}

/* Hover Effects */
.hover-lift {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.hover-lift:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.15);
}

/* Form Focus States */
input:focus,
textarea:focus,
select:focus {
    outline: none;
}

/* Loading Spinner */
.spinner {
    border: 3px solid #f3f3f3;
    border-top: 3px solid #dc2626;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}

/* Responsive Typography */
@media (max-width: 640px) {
    h1 {
        font-size: 2rem;
    }

    h2 {
        font-size: 1.75rem;
    }

    h3 {
        font-size: 1.5rem;
    }
}

/* Print Styles */
@media print {

    header,
    footer,
    #scroll-to-top,
    .no-print {
        display: none !important;
    }
}

/* Utility Classes */
.text-shadow {
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
}

.bg-pattern {
    background-image:
        linear-gradient(45deg, rgba(220, 38, 38, 0.05) 25%, transparent 25%),
        linear-gradient(-45deg, rgba(220, 38, 38, 0.05) 25%, transparent 25%),
        linear-gradient(45deg, transparent 75%, rgba(220, 38, 38, 0.05) 75%),
        linear-gradient(-45deg, transparent 75%, rgba(220, 38, 38, 0.05) 75%);
    background-size: 20px 20px;
    background-position: 0 0, 0 10px, 10px -10px, -10px 0px;
}

/* Active Navigation Link */
.nav-link.active {
    color: #dc2626;
    background-color: #fef2f2;
}

.nav-link-enhanced.active {
    color: #dc2626;
}

.nav-link-enhanced.active span {
    width: 100%;
}

/* Glassmorphism fallback for non-supporting browsers */
@supports not (backdrop-filter: blur(10px)) {
    header {
        background-color: rgba(255, 255, 255, 0.98);
    }
}

/* Header shadow refinement on scroll - optional refinement via JS */
header.scrolled {
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
}