/* Custom styles */
html {
    scroll-behavior: smooth;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;
}

/* Smooth scrolling for anchor links */
a[href^="#"] {
    transition: all 0.3s ease;
}

/* Modern form styling */
input[type="datetime-local"] {
    appearance: none;
    background-color: white;
    border: 1px solid #e2e8f0;
    border-radius: 0.5rem;
    padding: 0.75rem;
    width: 100%;
    transition: all 0.2s ease-in-out;
}

input[type="datetime-local"]:focus {
    outline: none;
    border-color: #000;
    box-shadow: 0 0 0 2px rgba(0, 0, 0, 0.1);
}

input[type="file"] {
    background-color: white;
    border: 1px solid #e2e8f0;
    border-radius: 0.5rem;
    padding: 1rem;
    width: 100%;
    transition: all 0.2s ease-in-out;
}

/* Hover effects */
.hover-shadow {
    transition: box-shadow 0.3s ease-in-out;
}

.hover-shadow:hover {
    box-shadow: 0 10px 30px -5px rgba(0, 0, 0, 0.1);
}

/* Animation classes */
.fade-in {
    animation: fadeIn 0.5s ease-in;
    opacity: 0;
    animation-fill-mode: forwards;
}

.slide-up {
    animation: slideUp 0.5s ease-out;
    opacity: 0;
    animation-fill-mode: forwards;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Modal styles */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 1000;
    opacity: 0;
    transition: opacity 0.3s ease-in-out;
}

.modal-content {
    background-color: white;
    margin: 15% auto;
    padding: 2rem;
    border-radius: 1rem;
    max-width: 500px;
    position: relative;
    transform: translateY(20px);
    transition: transform 0.3s ease-in-out;
}

.modal.active {
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 1;
}

.modal.active .modal-content {
    transform: translateY(0);
}

/* Custom scrollbar */
/* 基本滚动条样式 */
.custom-scrollbar {
    scrollbar-width: thin; /* Firefox */
    scrollbar-color: #888 #f1f1f1; /* Firefox */
    overflow-y: auto !important; /* 强制启用垂直滚动 */
    max-height: 400px; /* 确保有最大高度限制 */
}

/* Webkit浏览器 (Chrome, Safari, Edge) */
.custom-scrollbar::-webkit-scrollbar {
    width: 8px;
}

.custom-scrollbar::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 4px;
}

.custom-scrollbar::-webkit-scrollbar-thumb {
    background: #888;
    border-radius: 4px;
}

.custom-scrollbar::-webkit-scrollbar-thumb:hover {
    background: #555;
}

/* IE和Edge旧版本 */
.custom-scrollbar {
    -ms-overflow-style: auto; /* IE和Edge */
}

/* Loading indicator */
.loading {
    position: relative;
}

.loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 24px;
    height: 24px;
    margin: -12px 0 0 -12px;
    border: 2px solid #000;
    border-top-color: transparent;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}
