:root {
    --primary: #FF5722;
    --dark: #1a1a1a;
    --light: #f4f4f4;
    --white: #fff;
    --gray: #666;
    --border: #ddd;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: 'Tajawal', sans-serif;
    background: var(--light);
    height: 100vh;
    overflow: hidden;
}

/* Login */
.login-body {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 100vh;
    background: var(--dark);
}

.login-container {
    background: var(--white);
    padding: 40px;
    border-radius: 12px;
    width: 100%;
    max-width: 400px;
    text-align: center;
}

.login-header h1 {
    color: var(--primary);
    margin-bottom: 10px;
}

.login-header p {
    color: var(--gray);
    margin-bottom: 30px;
}

/* Layout */
.app-container {
    display: flex;
    height: 100vh;
}

.sidebar {
    width: 250px;
    background: var(--dark);
    color: var(--white);
    display: flex;
    flex-direction: column;
}

.logo {
    padding: 20px;
    font-size: 1.2rem;
    font-weight: bold;
    border-bottom: 1px solid #333;
    display: flex;
    align-items: center;
    gap: 10px;
}

.nav-menu {
    flex: 1;
    padding: 20px 0;
}

.nav-link {
    display: block;
    padding: 12px 20px;
    color: #aaa;
    text-decoration: none;
    transition: 0.3s;
}

.nav-link:hover,
.nav-link.active {
    background: var(--primary);
    color: var(--white);
}

.nav-link i {
    margin-left: 10px;
    width: 20px;
}

.user-info {
    padding: 20px;
    border-top: 1px solid #333;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.main-content {
    flex: 1;
    padding: 30px;
    overflow-y: auto;
}

.view {
    display: none;
}

.view.active {
    display: block;
}

.view-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.page-title {
    font-size: 1.5rem;
    color: var(--dark);
}

/* Stats */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
}

.stat-card {
    background: var(--white);
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
    display: flex;
    align-items: center;
    gap: 20px;
}

.stat-card i {
    font-size: 2rem;
    color: var(--primary);
    opacity: 0.8;
}

.stat-info h3 {
    font-size: 0.9rem;
    color: var(--gray);
    margin-bottom: 5px;
}

.stat-info span {
    font-size: 1.5rem;
    font-weight: bold;
}

/* Tables */
.table-container {
    background: var(--white);
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
}

.data-table {
    width: 100%;
    border-collapse: collapse;
}

.data-table th,
.data-table td {
    padding: 15px;
    text-align: right;
    border-bottom: 1px solid var(--light);
}

.data-table th {
    background: #f9f9f9;
    font-weight: 600;
}

.table-img {
    width: 50px;
    height: 50px;
    object-fit: cover;
    border-radius: 5px;
}

/* Forms & Buttons */
.form-group {
    margin-bottom: 20px;
    text-align: right;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 10px;
    border: 1px solid var(--border);
    border-radius: 5px;
}

.btn-primary {
    background: var(--primary);
    color: var(--white);
    border: none;
    padding: 10px 20px;
    border-radius: 5px;
    cursor: pointer;
}

.btn-secondary {
    background: var(--gray);
    color: var(--white);
    border: none;
    padding: 10px 20px;
    border-radius: 5px;
    cursor: pointer;
}

.btn-sm {
    padding: 5px 10px;
    font-size: 0.8rem;
}

.btn-danger {
    background: #dc3545;
    color: white;
}

/* Modal */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 1000;
}

.modal.active {
    display: flex;
}

.modal-content {
    background: var(--white);
    padding: 30px;
    border-radius: 10px;
    width: 500px;
    max-width: 90%;
}

.modal-content h3 {
    margin-bottom: 20px;
}

.error-msg {
    color: #dc3545;
    margin-top: 10px;
    font-size: 0.9rem;
}

.hidden {
    display: none;
}

/* ═══════════════════════════════════════════════════════════════
   Orders Management - Enhanced Styles
   ═══════════════════════════════════════════════════════════════ */

/* Orders Header */
.orders-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    flex-wrap: wrap;
    gap: 15px;
}

.orders-controls {
    display: flex;
    align-items: center;
    gap: 15px;
}

/* Filter Buttons */
.order-filters {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.filter-btn {
    padding: 8px 16px;
    border: 2px solid var(--border);
    border-radius: 8px;
    background: var(--white);
    cursor: pointer;
    font-family: inherit;
    font-weight: 500;
    transition: all 0.3s ease;
}

.filter-btn:hover {
    border-color: var(--primary);
    color: var(--primary);
}

.filter-btn.active {
    background: var(--primary);
    color: var(--white);
    border-color: var(--primary);
}

/* Sound Toggle */
.sound-toggle-btn {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: none;
    background: #22c55e;
    color: white;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 1rem;
}

.sound-toggle-btn:hover {
    transform: scale(1.1);
}

.sound-toggle-btn.muted {
    background: #ef4444;
}

/* Orders Stats */
.orders-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 15px;
    margin-bottom: 20px;
}

.order-stat {
    background: var(--white);
    padding: 15px;
    border-radius: 10px;
    text-align: center;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
    border-right: 4px solid var(--gray);
    transition: all 0.3s ease;
}

.order-stat:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
}

.order-stat.new {
    border-color: #3b82f6;
}

.order-stat.preparing {
    border-color: #f97316;
}

.order-stat.ready {
    border-color: #22c55e;
}

.order-stat.revenue {
    border-color: #d4a853;
}

.stat-label {
    display: block;
    font-size: 0.85rem;
    color: var(--gray);
    margin-bottom: 5px;
}

.stat-value {
    font-size: 1.5rem;
    font-weight: bold;
    color: var(--dark);
}

/* Orders Grid */
.orders-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 20px;
}

/* Order Card */
.order-card {
    background: var(--white);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    border-right: 5px solid var(--gray);
    transition: all 0.3s ease;
}

.order-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.12);
}

.order-card.new {
    border-color: #3b82f6;
}

.order-card.preparing {
    border-color: #f97316;
}

.order-card.ready {
    border-color: #22c55e;
}

.order-card.delivered {
    border-color: #7c3aed;
    opacity: 0.8;
}

.order-card.cancelled {
    border-color: #ef4444;
    opacity: 0.6;
}

/* Card Header */
.card-header {
    padding: 12px 15px;
    background: #f9f9f9;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.order-id {
    font-weight: bold;
    color: var(--primary);
    font-size: 1.1rem;
}

.status-badge {
    padding: 4px 12px;
    border-radius: 15px;
    font-size: 0.8rem;
    font-weight: 600;
}

.status-badge.new {
    background: #dbeafe;
    color: #1d4ed8;
}

.status-badge.preparing {
    background: #ffedd5;
    color: #c2410c;
}

.status-badge.ready {
    background: #dcfce7;
    color: #15803d;
}

.status-badge.delivered {
    background: #f3e8ff;
    color: #7c3aed;
}

.status-badge.cancelled {
    background: #fee2e2;
    color: #dc2626;
}

/* Card Body */
.card-body {
    padding: 15px;
}

.customer-info {
    margin-bottom: 10px;
}

.customer-name {
    font-weight: 600;
    font-size: 1.1rem;
    margin-bottom: 5px;
}

.customer-phone {
    color: #22c55e;
    font-weight: 500;
}

.customer-phone i {
    margin-left: 5px;
}

.order-type {
    color: var(--gray);
    font-size: 0.9rem;
    margin-bottom: 8px;
}

.order-type i {
    margin-left: 5px;
}

.order-address,
.order-car {
    font-size: 0.85rem;
    color: var(--gray);
    margin-bottom: 5px;
}

.order-address i,
.order-car i {
    margin-left: 5px;
}

.order-items {
    padding: 10px;
    background: #f9f9f9;
    border-radius: 8px;
    margin-top: 10px;
    font-size: 0.9rem;
    line-height: 1.6;
}

.order-notes {
    padding: 10px;
    background: #fff3cd;
    border-radius: 8px;
    margin-top: 8px;
    font-size: 0.85rem;
    color: #856404;
    border-right: 3px solid #ffc107;
}

.order-notes i {
    margin-left: 5px;
    color: #ffc107;
}

/* Card Footer */
.card-footer {
    padding: 12px 15px;
    background: #fafafa;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 10px;
}

.order-total {
    font-size: 1.2rem;
    font-weight: bold;
    color: #22c55e;
}

.card-actions {
    display: flex;
    gap: 8px;
}

.btn-action {
    padding: 8px 14px;
    border-radius: 6px;
    border: none;
    cursor: pointer;
    font-family: inherit;
    font-weight: 500;
    font-size: 0.85rem;
    transition: all 0.3s ease;
}

.btn-action i {
    margin-left: 5px;
}

.btn-next {
    background: #dcfce7;
    color: #15803d;
    border: 1px solid #22c55e;
}

.btn-next:hover {
    background: #22c55e;
    color: white;
}

.btn-cancel {
    background: #fee2e2;
    color: #dc2626;
    border: 1px solid #ef4444;
}

.btn-cancel:hover {
    background: #ef4444;
    color: white;
}

/* Toast Notifications */
.toast-container {
    position: fixed;
    top: 20px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 9999;
    display: flex;
    flex-direction: column;
    gap: 10px;
    pointer-events: none;
}

.toast {
    padding: 15px 25px;
    border-radius: 10px;
    color: white;
    font-weight: 500;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    animation: slideIn 0.3s ease;
    pointer-events: auto;
}

.toast.success {
    background: linear-gradient(135deg, #22c55e, #16a34a);
}

.toast.error {
    background: linear-gradient(135deg, #ef4444, #dc2626);
}

.toast.info {
    background: linear-gradient(135deg, #3b82f6, #2563eb);
}

.toast.warning {
    background: linear-gradient(135deg, #f97316, #ea580c);
}

@keyframes slideIn {
    from {
        transform: translateY(-20px);
        opacity: 0;
    }

    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.toast.hide {
    animation: slideOut 0.3s ease forwards;
}

@keyframes slideOut {
    to {
        transform: translateY(-20px);
        opacity: 0;
    }
}

/* Empty State */
.empty-state {
    text-align: center;
    padding: 60px 20px;
    color: var(--gray);
    grid-column: 1 / -1;
}

.empty-state i {
    font-size: 4rem;
    margin-bottom: 15px;
    opacity: 0.5;
    display: block;
}

.empty-state h3 {
    margin-bottom: 10px;
    font-size: 1.2rem;
}

/* Loading Spinner */
.loading-spinner {
    text-align: center;
    padding: 40px;
    color: var(--gray);
    grid-column: 1 / -1;
}

.loading-spinner i {
    margin-left: 10px;
}

/* New Order Animation */
@keyframes newOrderPulse {

    0%,
    100% {
        box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    }

    50% {
        box-shadow: 0 0 20px rgba(59, 130, 246, 0.4);
    }
}

.order-card.new-arrival {
    animation: newOrderPulse 1s ease 3;
}

/* Stat Highlight Animation */
@keyframes statPulse {

    0%,
    100% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.05);
    }
}

.order-stat.highlight {
    animation: statPulse 0.5s ease;
}

/* Responsive */
@media (max-width: 768px) {
    .orders-grid {
        grid-template-columns: 1fr;
    }

    .orders-header {
        flex-direction: column;
        align-items: stretch;
    }

    .orders-controls {
        justify-content: space-between;
    }

    .order-filters {
        flex-wrap: wrap;
        justify-content: center;
    }

    .filter-btn {
        padding: 6px 12px;
        font-size: 0.85rem;
    }

    .orders-stats {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* ═══════════════════════════════════════════════════════════════
   Inventory Management
   ═══════════════════════════════════════════════════════════════ */

.inventory-category-section {
    margin-bottom: 30px;
    background: var(--white);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.inventory-category-header {
    padding: 15px 20px;
    background: #f8f9fa;
    border-bottom: 1px solid var(--border);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.inventory-category-title {
    font-size: 1.1rem;
    font-weight: bold;
    color: var(--dark);
    display: flex;
    align-items: center;
    gap: 10px;
}

.category-badge {
    background: var(--primary);
    color: white;
    padding: 2px 8px;
    border-radius: 12px;
    font-size: 0.8rem;
}

.inventory-list {
    padding: 0;
}

.inventory-item {
    display: flex;
    align-items: center;
    padding: 15px 20px;
    border-bottom: 1px solid var(--light);
    gap: 20px;
    transition: background 0.2s;
}

.inventory-item:last-child {
    border-bottom: none;
}

.inventory-item:hover {
    background: #fdfdfd;
}

.inv-item-info {
    flex: 1;
    display: flex;
    align-items: center;
    gap: 15px;
}

.inv-item-img {
    width: 60px;
    height: 60px;
    object-fit: cover;
    border-radius: 8px;
    background: #eee;
}

.inv-item-details h4 {
    margin-bottom: 5px;
    color: var(--dark);
}

.inv-item-price {
    color: var(--gray);
    font-size: 0.9rem;
}

.inv-stock-controls {
    display: flex;
    align-items: center;
    gap: 15px;
}

.stock-adjuster {
    display: flex;
    align-items: center;
    border: 1px solid var(--border);
    border-radius: 8px;
    overflow: hidden;
}

.stock-btn {
    width: 36px;
    height: 36px;
    border: none;
    background: #f8f9fa;
    cursor: pointer;
    font-size: 1rem;
    color: var(--dark);
    transition: 0.2s;
}

.stock-btn:hover {
    background: #e9ecef;
}

.stock-input {
    width: 60px;
    height: 36px;
    border: none;
    border-left: 1px solid var(--border);
    border-right: 1px solid var(--border);
    text-align: center;
    font-size: 1rem;
    font-weight: bold;
    -moz-appearance: textfield;
    appearance: textfield;
}

.stock-input::-webkit-outer-spin-button,
.stock-input::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

/* Toggle Switch */
.switch {
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
}

.switch input {
    display: none;
}

.slider {
    position: relative;
    width: 46px;
    height: 24px;
    background-color: #ccc;
    border-radius: 24px;
    transition: .4s;
}

.slider:before {
    position: absolute;
    content: "";
    height: 18px;
    width: 18px;
    left: 3px;
    bottom: 3px;
    background-color: white;
    border-radius: 50%;
    transition: .4s;
}

input:checked+.slider {
    background-color: #22c55e;
}

input:checked+.slider:before {
    transform: translateX(22px);
}

.stock-status {
    width: 100px;
    text-align: center;
    font-size: 0.9rem;
    font-weight: 500;
}

.status-in-stock {
    color: #22c55e;
}

.status-low-stock {
    color: #f97316;
}

.status-out-of-stock {
    color: #ef4444;
}

/* Search Box */
.search-box {
    position: relative;
    width: 300px;
}

.search-box i {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--gray);
}

.search-box input {
    width: 100%;
    padding: 10px 35px 10px 15px;
    border: 1px solid var(--border);
    border-radius: 20px;
    outline: none;
    transition: border-color 0.3s;
}

.search-box input:focus {
    border-color: var(--primary);
}



/* ═══════════════════════════════════════════════════════════════
   Dashboard Sections - Best Sellers & Low Stock
   ═══════════════════════════════════════════════════════════════ */

.dashboard-section {
    background: var(--white);
    border-radius: 12px;
    padding: 20px;
    margin-top: 25px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
}

.dashboard-section.warning-section {
    border-right: 4px solid #f97316;
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--light);
}

.section-header h3 {
    font-size: 1.1rem;
    color: var(--dark);
    margin: 0;
    display: flex;
    align-items: center;
    gap: 8px;
}

.section-header h3 i {
    color: var(--primary);
}

.warning-section .section-header h3 i {
    color: #f97316;
}

/* Period Filter */
.period-filter {
    display: flex;
    gap: 8px;
}

.period-btn {
    padding: 6px 14px;
    border: 1px solid var(--border);
    border-radius: 20px;
    background: var(--white);
    font-family: inherit;
    font-size: 0.85rem;
    cursor: pointer;
    transition: all 0.2s ease;
}

.period-btn:hover {
    border-color: var(--primary);
    color: var(--primary);
}

.period-btn.active {
    background: var(--primary);
    color: var(--white);
    border-color: var(--primary);
}

/* Best Sellers List */
.best-sellers-list {
    max-height: 350px;
    overflow-y: auto;
}

.best-seller-item {
    display: flex;
    align-items: center;
    padding: 12px 0;
    border-bottom: 1px solid var(--light);
    transition: background 0.2s;
}

.best-seller-item:last-child {
    border-bottom: none;
}

.best-seller-item:hover {
    background: #f9f9f9;
    padding-right: 10px;
    margin-right: -10px;
    padding-left: 10px;
    margin-left: -10px;
}

.best-seller-item .rank {
    width: 30px;
    height: 30px;
    background: linear-gradient(135deg, var(--primary), #ff7043);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 0.9rem;
    margin-left: 12px;
}

.best-seller-item:nth-child(1) .rank {
    background: linear-gradient(135deg, #facc15, #f59e0b);
}

.best-seller-item:nth-child(2) .rank {
    background: linear-gradient(135deg, #cbd5e1, #94a3b8);
}

.best-seller-item:nth-child(3) .rank {
    background: linear-gradient(135deg, #c2883f, #a16207);
}

.best-seller-item .name {
    flex: 1;
    font-weight: 500;
}

.best-seller-item .quantity {
    color: var(--gray);
    font-size: 0.9rem;
    margin-left: 15px;
}

.best-seller-item .revenue {
    font-weight: bold;
    color: #22c55e;
    min-width: 70px;
    text-align: left;
}

/* Low Stock List */
.low-stock-list {
    max-height: 250px;
    overflow-y: auto;
}

.low-stock-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 15px;
    background: #fff7ed;
    border-radius: 8px;
    margin-bottom: 8px;
    border-right: 3px solid #fb923c;
}

.low-stock-item:last-child {
    margin-bottom: 0;
}

.low-stock-item.critical {
    background: #fef2f2;
    border-right-color: #ef4444;
}

.low-stock-item .name {
    font-weight: 500;
}

.low-stock-item .stock {
    background: #fff;
    padding: 4px 12px;
    border-radius: 15px;
    font-weight: bold;
    font-size: 0.85rem;
    color: #f97316;
}

.low-stock-item.critical .stock {
    color: #ef4444;
}

/* Empty State for Dashboard Sections */
.dashboard-section .empty-state {
    padding: 30px;
    font-size: 0.95rem;
}

.dashboard-section .empty-state i {
    font-size: 2rem;
    margin-bottom: 10px;
}

.dashboard-section .empty-state.success {
    color: #22c55e;
}

.dashboard-section .empty-state.success i {
    color: #22c55e;
}

/* Loading Spinner for Dashboard Sections */
.dashboard-section .loading-spinner {
    padding: 30px;
}

@media (max-width: 768px) {
    .section-header {
        flex-direction: column;
        gap: 10px;
        align-items: flex-start;
    }

    .period-filter {
        width: 100%;
        justify-content: center;
    }

    .best-seller-item {
        flex-wrap: wrap;
        gap: 5px;
    }

    .best-seller-item .quantity,
    .best-seller-item .revenue {
        font-size: 0.8rem;
    }
}

/* ═══════════════════════════════════════════════════════════════
   Customers Management Styles
   ═══════════════════════════════════════════════════════════════ */

/* Stats Grid للزبائن */
.customers-stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 15px;
    margin-bottom: 20px;
}

.customer-stat {
    background: var(--white);
    padding: 15px;
    border-radius: 10px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
    display: flex;
    align-items: center;
    gap: 15px;
}

.customer-stat i {
    font-size: 1.5rem;
    color: var(--primary);
    opacity: 0.8;
}

/* Controls */
.customers-controls {
    display: flex;
    gap: 15px;
    align-items: center;
}

/* Filters */
.customers-filters {
    display: flex;
    gap: 15px;
    margin-bottom: 20px;
    flex-wrap: wrap;
    align-items: center;
    background: var(--white);
    padding: 15px;
    border-radius: 10px;
}

.customers-filters .filter-group {
    display: flex;
    align-items: center;
    gap: 8px;
}

.customers-filters label {
    color: var(--gray);
    font-size: 0.9rem;
}

.customers-filters select {
    padding: 8px 12px;
    border: 1px solid var(--border);
    border-radius: 6px;
    font-family: inherit;
    font-size: 0.9rem;
}

/* Customer Table Specific */
.customer-cell {
    display: flex;
    align-items: center;
    gap: 12px;
}

.customer-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary), #ff7043);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    color: white;
    font-size: 14px;
    flex-shrink: 0;
}

.customer-info-cell {
    display: flex;
    flex-direction: column;
}

.customer-name {
    font-weight: 600;
    color: var(--dark);
}

.customer-id {
    font-size: 11px;
    color: var(--gray);
    font-family: monospace;
}

/* Status Badge */
.customer-status-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 4px 10px;
    border-radius: 15px;
    font-size: 0.8rem;
    font-weight: 600;
}

.customer-status-badge.active {
    background: rgba(34, 197, 94, 0.15);
    color: #22c55e;
}

.customer-status-badge.blocked {
    background: rgba(239, 68, 68, 0.15);
    color: #ef4444;
}

.customer-status-badge.suspicious {
    background: rgba(249, 115, 22, 0.15);
    color: #f97316;
}

/* Action Buttons */
.customer-actions {
    display: flex;
    gap: 6px;
}

.btn-sm {
    padding: 6px 10px;
    font-size: 0.8rem;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    transition: all 0.2s;
}

.btn-sm:hover {
    transform: translateY(-1px);
    box-shadow: 0 2px 5px rgba(0,0,0,0.15);
}

.btn-success {
    background: #22c55e;
    color: white;
}

.btn-warning {
    background: #f97316;
    color: white;
}

.btn-info {
    background: #3b82f6;
    color: white;
}

.btn-danger {
    background: #ef4444;
    color: white;
}

.text-success {
    color: #22c55e;
}

/* Pagination */
.customers-pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
    margin-top: 20px;
}

.customers-pagination .page-btn {
    padding: 8px 14px;
    border: 1px solid var(--border);
    border-radius: 6px;
    background: var(--white);
    cursor: pointer;
    transition: all 0.2s;
    font-family: inherit;
}

.customers-pagination .page-btn:hover:not(:disabled) {
    border-color: var(--primary);
    color: var(--primary);
}

.customers-pagination .page-btn.active {
    background: var(--primary);
    color: white;
    border-color: var(--primary);
}

.customers-pagination .page-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.customers-pagination .page-info {
    color: var(--gray);
    font-size: 0.9rem;
    padding: 0 10px;
}

/* Modal Large */
.modal-large {
    width: 700px;
    max-width: 90%;
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-bottom: 15px;
    border-bottom: 1px solid var(--border);
    margin-bottom: 20px;
}

.modal-actions {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    margin-top: 20px;
}

.btn-close {
    background: none;
    border: none;
    font-size: 24px;
    color: var(--gray);
    cursor: pointer;
}

.btn-close:hover {
    color: #ef4444;
}

/* Customer Detail Modal */
.customer-detail-header {
    display: flex;
    align-items: center;
    gap: 20px;
    padding-bottom: 20px;
    border-bottom: 1px solid var(--light);
    margin-bottom: 20px;
}

.customer-detail-avatar {
    width: 70px;
    height: 70px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary), #ff7043);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    color: white;
    font-size: 28px;
    flex-shrink: 0;
}

.customer-detail-info h3 {
    font-size: 1.3rem;
    margin-bottom: 5px;
}

.customer-id-detail {
    font-size: 11px;
    color: var(--gray);
    font-family: monospace;
    margin-top: 5px;
}

/* Customer Stats in Detail */
.customer-stats-detail {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 15px;
    margin-bottom: 20px;
}

.customer-stats-detail .stat-item {
    background: var(--light);
    padding: 15px;
    border-radius: 8px;
    text-align: center;
}

.customer-stats-detail .stat-label {
    display: block;
    font-size: 0.8rem;
    color: var(--gray);
    margin-bottom: 5px;
}

.customer-stats-detail .stat-value {
    font-size: 1.2rem;
    font-weight: bold;
    color: var(--primary);
}

/* Tabs */
.customer-tabs {
    display: flex;
    gap: 8px;
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 1px solid var(--light);
}

.tab-btn {
    padding: 8px 16px;
    border: none;
    background: transparent;
    color: var(--gray);
    cursor: pointer;
    border-radius: 6px;
    font-family: inherit;
    font-size: 0.9rem;
    transition: all 0.2s;
}

.tab-btn:hover {
    background: var(--light);
    color: var(--dark);
}

.tab-btn.active {
    background: var(--primary);
    color: white;
}

.customer-tab-content {
    display: none;
}

.customer-tab-content.active {
    display: block;
}

/* Customer Order Item */
.customer-order-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px;
    background: var(--light);
    border-radius: 8px;
    margin-bottom: 8px;
}

.customer-order-item .order-info {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.customer-order-item .order-id {
    font-weight: bold;
    color: var(--primary);
}

.customer-order-item .order-date {
    font-size: 0.8rem;
    color: var(--gray);
}

.customer-order-item .order-total {
    font-size: 1.1rem;
    font-weight: bold;
    color: #22c55e;
}

/* Notes List */
.notes-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.note-item {
    background: var(--light);
    padding: 15px;
    border-radius: 8px;
    border-right: 3px solid var(--primary);
}

.note-content {
    margin-bottom: 10px;
    line-height: 1.6;
}

.note-meta {
    display: flex;
    justify-content: space-between;
    font-size: 0.8rem;
    color: var(--gray);
}

/* Block History */
.block-history {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.block-item {
    background: var(--light);
    padding: 15px;
    border-radius: 8px;
    border-right: 4px solid;
}

.block-item.blocked {
    border-color: #ef4444;
}

.block-item.unblocked {
    border-color: #22c55e;
}

.block-meta {
    display: flex;
    justify-content: space-between;
    font-size: 0.8rem;
    color: var(--gray);
    margin-top: 10px;
}

/* Warning Text */
.warning-text {
    color: #f97316;
    background: rgba(249, 115, 22, 0.1);
    padding: 12px;
    border-radius: 8px;
    margin-bottom: 15px;
}

/* Empty Message */
.empty-message {
    text-align: center;
    color: var(--gray);
    padding: 20px;
}

/* Responsive for Customers */
@media (max-width: 768px) {
    .customers-stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .customers-filters {
        flex-direction: column;
        align-items: stretch;
    }

    .customers-filters .filter-group {
        width: 100%;
    }

    .customers-filters select {
        flex: 1;
    }

    .customer-avatar {
        display: none;
    }

    .customer-actions {
        flex-wrap: wrap;
    }

    .customers-table th:nth-child(2),
    .customers-table td:nth-child(2),
    .customers-table th:nth-child(6),
    .customers-table td:nth-child(6) {
        display: none;
    }

    .customer-detail-header {
        flex-direction: column;
        text-align: center;
    }

    .customer-stats-detail {
        grid-template-columns: repeat(2, 1fr);
    }

    .customer-tabs {
        flex-wrap: wrap;
        justify-content: center;
    }
}