/* Grid Background Pattern */
.bg-grid-pattern {
    background-image: 
        linear-gradient(rgba(34, 211, 238, 0.1) 1px, transparent 1px),
        linear-gradient(90deg, rgba(34, 211, 238, 0.1) 1px, transparent 1px);
    background-size: 50px 50px;
}

/* Animations */
@keyframes pulse-slow {
    0%, 100% {
        opacity: 0.1;
    }
    50% {
        opacity: 0.2;
    }
}

@keyframes float {
    0%, 100% {
        transform: translateY(0px);
    }
    50% {
        transform: translateY(-20px);
    }
}

@keyframes glow {
    0%, 100% {
        box-shadow: 0 0 20px rgba(34, 211, 238, 0.3);
    }
    50% {
        box-shadow: 0 0 40px rgba(34, 211, 238, 0.6);
    }
}

@keyframes slide-in {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Apply animations */
.animate-pulse {
    animation: pulse-slow 3s ease-in-out infinite;
}

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

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

.animate-slide-in {
    animation: slide-in 0.6s ease-out;
}

/* Input focus states */
input:focus,
textarea:focus,
select:focus {
    box-shadow: 0 0 20px rgba(34, 211, 238, 0.3);
}

/* Smooth transitions */
* {
    transition-property: color, background-color, border-color, box-shadow;
    transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
}

/* Disable transitions on animations */
@media (prefers-reduced-motion: reduce) {
    * {
        animation: none !important;
        transition: none !important;
    }
}

/* Scroll behavior */
html {
    scroll-behavior: smooth;
}

/* Custom scrollbar */
::-webkit-scrollbar {
    width: 10px;
    height: 10px;
}

::-webkit-scrollbar-track {
    background: #f3f4f6;
}

::-webkit-scrollbar-thumb {
    background: linear-gradient(180deg, #06b6d4 0%, #3b82f6 100%);
    border-radius: 5px;
}

::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(180deg, #22d3ee 0%, #60a5fa 100%);
}

/* Table Container with Scrolling */
.table-container {
    max-height: 600px;
    overflow-y: auto;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

.table-container table {
    min-width: 100%;
}

/* Responsive text adjustments */
@media (max-width: 640px) {
    h1 {
        font-size: 2.25rem !important;
    }
    
    h2 {
        font-size: 1.875rem !important;
    }
}

/* Loading state */
.loading {
    pointer-events: none;
    opacity: 0.6;
}

/* Success message */
.success-message {
    animation: slide-in 0.3s ease-out;
    background: rgba(34, 211, 238, 0.1);
    border: 1px solid rgba(34, 211, 238, 0.5);
    border-radius: 0.5rem;
    padding: 1rem;
    margin-top: 1rem;
    color: #22d3ee;
}

/* Error message */
.error-message {
    animation: slide-in 0.3s ease-out;
    background: rgba(239, 68, 68, 0.1);
    border: 1px solid rgba(239, 68, 68, 0.5);
    border-radius: 0.5rem;
    padding: 1rem;
    margin-top: 1rem;
    color: #ef4444;
}

/* Button hover effects */
button:hover:not(:disabled) {
    transform: translateY(-2px);
}

button:active:not(:disabled) {
    transform: translateY(0);
}

/* Link animations */
a {
    position: relative;
}

a::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 2px;
    background: currentColor;
    transition: width 0.3s ease;
}

a:hover::after {
    width: 100%;
}

a[class*="text-"] {
    position: relative;
}

/* Form styling */
input,
textarea,
select {
    transition: all 0.3s ease;
}

input::placeholder,
textarea::placeholder {
    color: rgba(107, 114, 128, 0.7);
}

/* Cards hover effect */
.hover\:shadow-lg:hover {
    transform: translateY(-4px);
}
