/* Custom Styles */

/* Smooth transitions */
* {
    transition: background-color 0.3s ease, color 0.3s ease;
}

/* Custom scrollbar */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
}

.dark ::-webkit-scrollbar-track {
    background: #1f2937;
}

::-webkit-scrollbar-thumb {
    background: #888;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #555;
}

/* Print styles */
@media print {
    .no-print {
        display: none !important;
    }
}

/* Loading spinner */
.spinner {
    border: 4px solid #f3f3f3;
    border-top: 4px solid #3498db;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Table responsive */
.table-responsive {
    overflow-x: auto;
}

/* Button styles */
.btn {
    padding: 0.5rem 1rem;
    border-radius: 0.375rem;
    font-weight: 500;
    transition: all 0.2s;
}

.btn-primary {
    background-color: #3b82f6;
    color: white;
}

.btn-primary:hover {
    background-color: #2563eb;
}

.btn-danger {
    background-color: #ef4444;
    color: white;
}

.btn-danger:hover {
    background-color: #dc2626;
}

.btn-success {
    background-color: #10b981;
    color: white;
}

.btn-success:hover {
    background-color: #059669;
}

/* Layout fixes */
body {
    overflow-x: hidden;
}

/* Responsive sidebar styles */
@media (max-width: 1023px) {
    body {
        overflow-x: hidden;
    }
}

/* Smooth scrollbar for sidebar */
#sidebar::-webkit-scrollbar,
#mobileSidebar::-webkit-scrollbar {
    width: 6px;
}

#sidebar::-webkit-scrollbar-track,
#mobileSidebar::-webkit-scrollbar-track {
    background: rgba(0, 0, 0, 0.1);
}

#sidebar::-webkit-scrollbar-thumb,
#mobileSidebar::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.2);
    border-radius: 3px;
}

#sidebar::-webkit-scrollbar-thumb:hover,
#mobileSidebar::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.3);
}

/* Modern card styling */
.bg-white.dark\:bg-gray-800,
.bg-white {
    border-radius: 0.75rem;
    box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px 0 rgba(0, 0, 0, 0.06);
    transition: all 0.3s ease;
}

.dark .bg-white.dark\:bg-gray-800 {
    box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.3), 0 1px 2px 0 rgba(0, 0, 0, 0.2);
}

/* Modern table styling */
table {
    border-collapse: separate;
    border-spacing: 0;
}

thead th {
    font-weight: 600;
    letter-spacing: 0.05em;
}

tbody tr {
    transition: background-color 0.2s ease;
}

tbody tr:hover {
    background-color: rgba(0, 0, 0, 0.02);
}

.dark tbody tr:hover {
    background-color: rgba(255, 255, 255, 0.05);
}

/* Modern button styles */
button, .btn, a[class*="bg-"] {
    transition: all 0.2s ease;
}

button:hover, .btn:hover, a[class*="bg-"]:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
}

button:active, .btn:active, a[class*="bg-"]:active {
    transform: translateY(0);
}

/* Input field modern styling */
input[type="text"],
input[type="email"],
input[type="password"],
input[type="number"],
input[type="date"],
select,
textarea {
    transition: all 0.2s ease;
}

input[type="text"]:focus,
input[type="email"]:focus,
input[type="password"]:focus,
input[type="number"]:focus,
input[type="date"]:focus,
select:focus,
textarea:focus {
    outline: none;
    ring: 2px;
    ring-color: rgba(59, 130, 246, 0.5);
    border-color: #3b82f6;
}

/* Ensure proper layout flow */
.flex {
    display: flex;
}

.flex-col {
    flex-direction: column;
}

.flex-1 {
    flex: 1 1 0%;
}

.min-h-screen {
    min-height: 100vh;
}

