* { margin: 0; padding: 0; box-sizing: border-box; }
body { font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Arial, sans-serif; background: #f5f7fa; color: #333; line-height: 1.6; }
.app { display: flex; min-height: 100vh; }
.sidebar { width: 220px; background: #2c3e50; color: #ecf0f1; position: fixed; height: 100vh; overflow-y: auto; }
.logo { padding: 20px; border-bottom: 1px solid #34495e; }
.logo h1 { font-size: 18px; }
.menu { padding: 10px 0; }
.menu-group { padding: 12px 20px 8px; font-size: 11px; color: #95a5a6; text-transform: uppercase; }
.menu-item { display: flex; align-items: center; padding: 12px 20px; cursor: pointer; transition: all 0.2s; color: #bdc3c7; }
.menu-item:hover { background: #34495e; color: #fff; }
.menu-item.active { background: #3498db; color: #fff; }
.menu-item .icon { margin-right: 10px; font-size: 16px; width: 20px; text-align: center; }
.menu-item.has-submenu { justify-content: space-between; }
.menu-item .arrow { font-size: 10px; color: #95a5a6; transition: transform 0.2s; }
.menu-item.has-submenu.active .arrow { transform: rotate(90deg); }
.submenu { display: none; background: #34495e; }
.submenu.show { display: block; }
.submenu .menu-item { padding-left: 52px; font-size: 13px; }
.main-content { flex: 1; margin-left: 220px; min-height: 100vh; }
.header { background: #fff; padding: 20px 30px; box-shadow: 0 2px 4px rgba(0,0,0,0.1); display: flex; justify-content: space-between; align-items: center; }
.header h2 { font-size: 22px; color: #2c3e50; }
.user-info { color: #7f8c8d; font-size: 14px; }
.content { padding: 30px; }
.card { background: #fff; border-radius: 8px; padding: 20px; margin-bottom: 20px; box-shadow: 0 2px 8px rgba(0,0,0,0.08); }
.card-title { font-size: 16px; font-weight: 600; color: #2c3e50; margin-bottom: 15px; padding-bottom: 10px; border-bottom: 2px solid #3498db; }
.stats-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 20px; margin-bottom: 30px; }
.stat-card { background: #fff; padding: 20px; border-radius: 8px; box-shadow: 0 2px 8px rgba(0,0,0,0.08); border-left: 4px solid #3498db; }
.stat-card.warning { border-left-color: #f39c12; }
.stat-card.success { border-left-color: #27ae60; }
.stat-card.danger { border-left-color: #e74c3c; }
.stat-value { font-size: 28px; font-weight: 700; color: #2c3e50; margin: 8px 0; }
.stat-label { font-size: 13px; color: #7f8c8d; }
.btn { padding: 8px 16px; border: none; border-radius: 6px; cursor: pointer; font-size: 13px; font-weight: 500; transition: all 0.2s; }
.btn-primary { background: #3498db; color: #fff; }
.btn-primary:hover { background: #2980b9; }
.btn-success { background: #27ae60; color: #fff; }
.btn-success:hover { background: #219a52; }
.btn-warning { background: #f39c12; color: #fff; }
.btn-warning:hover { background: #d68910; }
.btn-danger { background: #e74c3c; color: #fff; }
.btn-danger:hover { background: #c0392b; }
.btn-info { background: #17a2b8; color: #fff; }
.btn-info:hover { background: #138496; }
.btn-sm { padding: 5px 10px; font-size: 12px; }
.toolbar { display: flex; justify-content: space-between; align-items: center; margin-bottom: 20px; gap: 15px; flex-wrap: wrap; }
.search-box { display: flex; gap: 10px; }
.search-box input { padding: 8px 12px; border: 1px solid #ddd; border-radius: 6px; font-size: 13px; min-width: 200px; }
.table-container { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; }
th, td { padding: 10px 12px; text-align: left; border-bottom: 1px solid #ecf0f1; }
th { background: #f8f9fa; font-weight: 600; color: #2c3e50; font-size: 12px; text-transform: uppercase; }
tr:hover { background: #f8f9fa; }
.status-badge { display: inline-block; padding: 3px 10px; border-radius: 12px; font-size: 11px; font-weight: 500; }
.status-pending { background: #fef3cd; color: #856404; }
.status-completed, .status-delivered { background: #d4edda; color: #155724; }
.status-cancelled { background: #f8d7da; color: #721c24; }
.modal { display: none; position: fixed; top: 0; left: 0; width: 100%; height: 100%; background: rgba(0,0,0,0.5); z-index: 1000; justify-content: center; align-items: center; }
.modal.show { display: flex; }
.modal-content { background: #fff; border-radius: 8px; width: 90%; max-width: 550px; max-height: 80vh; overflow-y: auto; }
.modal-header { padding: 15px 20px; border-bottom: 1px solid #ecf0f1; display: flex; justify-content: space-between; align-items: center; }
.modal-header h3 { font-size: 16px; color: #2c3e50; }
.close-btn { background: none; border: none; font-size: 22px; cursor: pointer; color: #95a5a6; }
.modal-body { padding: 20px; }
.modal-footer { padding: 15px 20px; border-top: 1px solid #ecf0f1; display: flex; justify-content: flex-end; gap: 10px; }
.form-group { margin-bottom: 15px; }
.form-label { display: block; margin-bottom: 6px; font-weight: 500; color: #2c3e50; font-size: 13px; }
.form-control { width: 100%; padding: 8px 12px; border: 1px solid #ddd; border-radius: 6px; font-size: 13px; }
.form-control:focus { outline: none; border-color: #3498db; }
.form-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 12px; }
.loading { text-align: center; padding: 40px; color: #95a5a6; }
.spinner { border: 3px solid #f3f3f3; border-top: 3px solid #3498db; border-radius: 50%; width: 35px; height: 35px; animation: spin 1s linear infinite; margin: 0 auto 15px; }
@keyframes spin { 0% { transform: rotate(0deg); } 100% { transform: rotate(360deg); } }
.toast { position: fixed; top: 20px; right: 20px; padding: 12px 20px; border-radius: 6px; color: #fff; font-weight: 500; z-index: 2000; animation: slideIn 0.3s ease; }
.toast-success { background: #27ae60; }
.toast-error { background: #e74c3c; }
.toast-warning { background: #f39c12; }
@keyframes slideIn { from { transform: translateX(100%); opacity: 0; } to { transform: translateX(0); opacity: 1; } }
.product-item:hover { background-color: #f5f7fa; }
.product-item.selected { background-color: #e3f2fd; font-weight: bold; }
