/* Admin Dashboard Styles */
:root {
    --sidebar-width: 250px;
    --header-height: 70px;
}

.admin-body {
    background: #f8fafc;
    min-height: 100vh;
}

/* Sidebar */
.sidebar {
    position: fixed;
    left: 0;
    top: 0;
    bottom: 0;
    width: var(--sidebar-width);
    background: linear-gradient(180deg, var(--dark-color), #0f3460);
    color: white;
    padding: 2rem 0;
    z-index: 1000;
    box-shadow: 5px 0 20px rgba(0, 0, 0, 0.1);
}

.admin-logo {
    padding: 0 1.5rem;
    margin-bottom: 2rem;
}

.admin-logo h2 {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--accent-color);
}

.nav-menu {
    list-style: none;
}

.nav-item {
    margin-bottom: 0.5rem;
}

.nav-link {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 1rem 1.5rem;
    color: rgba(255, 255, 255, 0.8);
    text-decoration: none;
    transition: var(--transition);
    border-left: 3px solid transparent;
}

.nav-link:hover,
.nav-link.active {
    background: rgba(255, 255, 255, 0.1);
    color: white;
    border-left-color: var(--accent-color);
}

/* Main Content */
.admin-main {
    margin-left: var(--sidebar-width);
    padding: 2rem;
}

.admin-header {
    background: white;
    border-radius: var(--border-radius);
    padding: 1.5rem;
    margin-bottom: 2rem;
    box-shadow: var(--box-shadow);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

/* Stats Grid */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.stat-card {
    background: white;
    border-radius: var(--border-radius);
    padding: 1.5rem;
    display: flex;
    align-items: center;
    gap: 1rem;
    box-shadow: var(--box-shadow);
    transition: var(--transition);
}

.stat-card:hover {
    transform: translateY(-5px);
}

.stat-icon {
    width: 60px;
    height: 60px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
}

.stat-content {
    flex: 1;
}

.stat-value {
    font-size: 2rem;
    font-weight: 800;
    line-height: 1;
}

.stat-label {
    color: var(--gray-color);
    font-size: 0.9rem;
}

/* Tables */
.table-responsive {
    background: white;
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: var(--box-shadow);
}

.data-table {
    width: 100%;
    border-collapse: collapse;
}

.data-table th {
    background: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
    color: white;
    padding: 1rem;
    text-align: left;
    font-weight: 600;
}

.data-table td {
    padding: 1rem;
    border-bottom: 1px solid #f1f5f9;
}

.data-table tr:hover {
    background: rgba(67, 97, 238, 0.05);
}

/* Form Groups */
.form-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1.5rem;
    margin-bottom: 1.5rem;
}

/* Image Upload */
.image-upload-container {
    border: 2px dashed #e2e8f0;
    border-radius: 12px;
    padding: 3rem;
    text-align: center;
    cursor: pointer;
    transition: var(--transition);
}

.image-upload-container:hover {
    border-color: var(--primary-color);
    background: rgba(67, 97, 238, 0.05);
}

.image-preview {
    width: 150px;
    height: 150px;
    border-radius: 50%;
    object-fit: cover;
    margin: 0 auto 1rem;
    display: block;
    border: 3px solid var(--light-color);
}

/* Bulk Upload */
.bulk-upload-card {
    background: white;
    border-radius: var(--border-radius);
    padding: 2rem;
    text-align: center;
    box-shadow: var(--box-shadow);
}

.upload-icon {
    font-size: 3rem;
    color: var(--primary-color);
    margin-bottom: 1rem;
}

/* Export Buttons */
.export-buttons {
    display: flex;
    gap: 1rem;
    margin-top: 2rem;
}

.btn-export {
    background: linear-gradient(135deg, var(--success-color), #3a8bc8);
    color: white;
}

.btn-export:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(76, 201, 240, 0.3);
}

/* Loading Spinner */
.loading-spinner {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    border-top-color: white;
    animation: spin 1s ease-in-out infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Modal */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 2000;
    align-items: center;
    justify-content: center;
}

.modal.active {
    display: flex;
}

.modal-content {
    background: white;
    border-radius: var(--border-radius);
    padding: 2rem;
    max-width: 500px;
    width: 90%;
    max-height: 90vh;
    overflow-y: auto;
}

/* Responsive Admin */
@media (max-width: 1024px) {
    .sidebar {
        width: 70px;
        overflow: hidden;
    }
    
    .admin-logo h2,
    .nav-link span {
        display: none;
    }
    
    .admin-main {
        margin-left: 70px;
    }
    
    .nav-link {
        justify-content: center;
        padding: 1rem;
    }
}

@media (max-width: 768px) {
    .admin-main {
        padding: 1rem;
        margin-left: 0;
    }
    
    .sidebar {
        transform: translateX(-100%);
        transition: transform 0.3s ease;
    }
    
    .sidebar.active {
        transform: translateX(0);
    }
    
    .mobile-menu-toggle {
        display: block;
        position: fixed;
        top: 20px;
        left: 20px;
        z-index: 1001;
        background: var(--primary-color);
        color: white;
        border: none;
        width: 50px;
        height: 50px;
        border-radius: 50%;
        font-size: 1.5rem;
        cursor: pointer;
    }
}