/* Super Admin Dashboard Styles */

.super-admin-dashboard {
    padding: 20px;
}

/* Stats Grid */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.stat-card {
    background: white;
    border-radius: 12px;
    padding: 25px;
    display: flex;
    align-items: center;
    gap: 20px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.08);
    transition: all 0.3s;
    border-left: 4px solid transparent;
}

.stat-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 5px 20px rgba(0,0,0,0.12);
}

.stat-card.primary {
    border-left-color: var(--primary-color);
}

.stat-card.success {
    border-left-color: #28a745;
}

.stat-card.warning {
    border-left-color: #ffc107;
}

.stat-card.danger {
    border-left-color: #dc3545;
}

.stat-card.info {
    border-left-color: #17a2b8;
}

.stat-card.secondary {
    border-left-color: #6c757d;
}

.stat-icon {
    width: 60px;
    height: 60px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 28px;
    color: white;
}

.stat-card.primary .stat-icon {
    background: var(--primary-color);
}

.stat-card.success .stat-icon {
    background: #28a745;
}

.stat-card.warning .stat-icon {
    background: #ffc107;
}

.stat-card.danger .stat-icon {
    background: #dc3545;
}

.stat-card.info .stat-icon {
    background: #17a2b8;
}

.stat-card.secondary .stat-icon {
    background: #6c757d;
}

.stat-content {
    flex: 1;
}

.stat-label {
    font-size: 14px;
    color: #6c757d;
    margin-bottom: 5px;
}

.stat-value {
    font-size: 32px;
    font-weight: 700;
    color: #2c3e50;
}

/* Admin Tabs */
.admin-tabs {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
    border-bottom: 2px solid #e9ecef;
    flex-wrap: wrap;
}

.admin-tab-btn {
    padding: 12px 24px;
    background: transparent;
    border: none;
    border-bottom: 3px solid transparent;
    cursor: pointer;
    font-size: 16px;
    font-weight: 600;
    color: #6c757d;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    gap: 8px;
}

.admin-tab-btn:hover {
    color: var(--primary-color);
    background: rgba(var(--primary-rgb), 0.05);
}

.admin-tab-btn.active {
    color: var(--primary-color);
    border-bottom-color: var(--primary-color);
}

.admin-tabs-content {
    background: white;
    border-radius: 12px;
    padding: 20px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.08);
}

.admin-tab-content {
    display: none;
}

.admin-tab-content.active {
    display: block;
}

/* Content Header */
.content-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    flex-wrap: wrap;
    gap: 15px;
}

.content-header h2 {
    margin: 0;
    color: #2c3e50;
    font-size: 24px;
}

.filters-row {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.filters-row select,
.filters-row input {
    padding: 8px 15px;
    border: 1px solid #dee2e6;
    border-radius: 6px;
    font-size: 14px;
}

.filters-row input {
    min-width: 250px;
}

/* Admin Table */
.table-container {
    overflow-x: auto;
}

.admin-table {
    width: 100%;
    border-collapse: collapse;
    background: white;
}

.admin-table thead {
    background: #f8f9fa;
}

.admin-table th {
    padding: 15px;
    text-align: left;
    font-weight: 600;
    color: #2c3e50;
    border-bottom: 2px solid #dee2e6;
    white-space: nowrap;
}

.admin-table td {
    padding: 15px;
    border-bottom: 1px solid #e9ecef;
    color: #495057;
}

.admin-table tr:hover {
    background: #f8f9fa;
}

.loading-cell,
.empty-cell {
    text-align: center;
    padding: 40px 20px !important;
    color: #6c757d;
}

.empty-cell i {
    font-size: 48px;
    color: #dee2e6;
    margin-bottom: 15px;
}

.empty-cell p {
    margin: 10px 0 0 0;
    font-size: 16px;
}

/* Action Buttons */
.action-buttons {
    display: flex;
    gap: 8px;
    justify-content: flex-start;
}

.btn-icon {
    width: 36px;
    height: 36px;
    border-radius: 6px;
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s;
    background: #f8f9fa;
    color: #495057;
}

.btn-icon:hover {
    transform: translateY(-2px);
}

.btn-icon.primary {
    background: rgba(var(--primary-rgb), 0.1);
    color: var(--primary-color);
}

.btn-icon.primary:hover {
    background: var(--primary-color);
    color: white;
}

.btn-icon.success {
    background: rgba(40, 167, 69, 0.1);
    color: #28a745;
}

.btn-icon.success:hover {
    background: #28a745;
    color: white;
}

.btn-icon.danger {
    background: rgba(220, 53, 69, 0.1);
    color: #dc3545;
}

.btn-icon.danger:hover {
    background: #dc3545;
    color: white;
}

/* Analytics Grid */
.analytics-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 20px;
}

.analytics-card {
    background: white;
    border-radius: 12px;
    padding: 20px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.08);
}

.analytics-card h3 {
    margin: 0 0 20px 0;
    color: #2c3e50;
    font-size: 18px;
}

/* Store Details */
.store-details {
    padding: 20px;
}

.store-details h3 {
    margin: 0 0 20px 0;
    color: #2c3e50;
    font-size: 24px;
    border-bottom: 2px solid #e9ecef;
    padding-bottom: 10px;
}

.details-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-top: 20px;
}

.detail-item {
    padding: 15px;
    background: #f8f9fa;
    border-radius: 8px;
}

.detail-item label {
    display: block;
    font-size: 12px;
    color: #6c757d;
    margin-bottom: 5px;
    font-weight: 600;
}

.detail-item span {
    font-size: 16px;
    color: #2c3e50;
    font-weight: 500;
}

/* Responsive */
@media (max-width: 1200px) {
    .stats-grid {
        grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    }
}

@media (max-width: 768px) {
    .stats-grid {
        grid-template-columns: 1fr;
    }
    
    .admin-tabs {
        flex-direction: column;
    }
    
    .admin-tab-btn {
        width: 100%;
        justify-content: center;
    }
    
    .content-header {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .filters-row {
        width: 100%;
        flex-direction: column;
    }
    
    .filters-row input {
        width: 100%;
    }
    
    .analytics-grid {
        grid-template-columns: 1fr;
    }
    
    .details-grid {
        grid-template-columns: 1fr;
    }
}

/* RTL Support */
[dir="rtl"] .admin-table th,
[dir="rtl"] .admin-table td {
    text-align: right;
}

[dir="rtl"] .stat-card {
    border-left: none;
    border-right: 4px solid transparent;
}

[dir="rtl"] .stat-card.primary {
    border-right-color: var(--primary-color);
}

[dir="rtl"] .stat-card.success {
    border-right-color: #28a745;
}

[dir="rtl"] .stat-card.warning {
    border-right-color: #ffc107;
}

[dir="rtl"] .stat-card.danger {
    border-right-color: #dc3545;
}

[dir="rtl"] .stat-card.info {
    border-right-color: #17a2b8;
}

[dir="rtl"] .stat-card.secondary {
    border-right-color: #6c757d;
}
