/* ═══════════════════════════════════════════
   SAMEE'S BIKE SHOP — Dashboard Styles
   Black + Gold premium theme
   Mobile-first, 48px min tap targets
   ═══════════════════════════════════════════ */

:root {
  --bg: #000000;
  --surface: #0a0a0a;
  --card: #111111;
  --card-hover: #161616;
  --border: #1a1a1a;
  --border-light: #222222;
  --gold: #D4AF37;
  --gold-dim: #B8962E;
  --gold-glow: rgba(212, 175, 55, 0.15);
  --gold-glow-strong: rgba(212, 175, 55, 0.3);
  --white: #FFFFFF;
  --text: #F0F0F0;
  --text-muted: #999999;
  --text-dim: #666666;
  --danger: #E53935;
  --danger-bg: rgba(229, 57, 53, 0.1);
  --success: #43A047;
  --success-bg: rgba(67, 160, 71, 0.1);
  --warning: #F9A825;
  --warning-bg: rgba(249, 168, 37, 0.1);
  --blue: #1E88E5;
  --blue-bg: rgba(30, 136, 229, 0.1);
  --amber: #FF8F00;
  --amber-bg: rgba(255, 143, 0, 0.1);
  --gray: #616161;
  --gray-bg: rgba(97, 97, 97, 0.1);
  --radius: 12px;
  --radius-sm: 8px;
  --radius-lg: 16px;
  --shadow: 0 4px 24px rgba(0, 0, 0, 0.5);
  --shadow-lg: 0 8px 48px rgba(0, 0, 0, 0.7);
  --transition: 0.2s ease;
  --font: 'DM Sans', -apple-system, BlinkMacSystemFont, sans-serif;
}

/* ── Reset ── */

*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-size: 16px;
  -webkit-text-size-adjust: 100%;
  -webkit-tap-highlight-color: transparent;
}

body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  min-height: 100dvh;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

input, select, textarea, button {
  font-family: inherit;
  font-size: inherit;
}

.hidden { display: none !important; }

/* ── Scrollbar ── */

::-webkit-scrollbar { width: 4px; height: 4px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--border-light); border-radius: 4px; }

/* ═══════════════════════════════════════════
   LOGIN SCREEN
   ═══════════════════════════════════════════ */

.login-screen {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100dvh;
  padding: 24px;
  background: var(--bg);
}

.login-container {
  width: 100%;
  max-width: 320px;
  text-align: center;
}

.login-brand {
  margin-bottom: 48px;
}

.login-logo {
  width: 72px;
  height: 72px;
  margin: 0 auto 16px;
  background: linear-gradient(135deg, var(--gold), var(--gold-dim));
  border-radius: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 36px;
  font-weight: 700;
  color: var(--bg);
  box-shadow: 0 0 40px var(--gold-glow);
}

.login-title {
  font-size: 28px;
  font-weight: 700;
  letter-spacing: 6px;
  color: var(--gold);
}

.login-subtitle {
  font-size: 13px;
  color: var(--text-muted);
  margin-top: 4px;
  letter-spacing: 2px;
  text-transform: uppercase;
}

/* PIN Entry */

.pin-entry {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 24px;
}

.pin-dots {
  display: flex;
  gap: 16px;
}

.pin-dot {
  width: 16px;
  height: 16px;
  border-radius: 50%;
  border: 2px solid var(--border-light);
  background: transparent;
  transition: all var(--transition);
}

.pin-dot.filled {
  background: var(--gold);
  border-color: var(--gold);
  box-shadow: 0 0 12px var(--gold-glow);
}

.pin-dot.error {
  border-color: var(--danger);
  background: var(--danger);
  animation: shake 0.4s ease;
}

.pin-error {
  min-height: 20px;
  font-size: 13px;
  color: var(--danger);
}

.pin-pad {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  width: 100%;
  max-width: 280px;
}

.pin-key {
  height: 64px;
  border: none;
  border-radius: var(--radius);
  background: var(--card);
  color: var(--text);
  font-size: 24px;
  font-weight: 500;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all var(--transition);
  -webkit-user-select: none;
  user-select: none;
}

.pin-key:active {
  background: var(--gold);
  color: var(--bg);
  transform: scale(0.95);
}

.pin-key-empty {
  background: transparent;
  cursor: default;
}

.pin-key-delete {
  color: var(--text-muted);
}

.pin-key-delete:active {
  background: var(--card-hover);
  color: var(--text);
}

@keyframes shake {
  0%, 100% { transform: translateX(0); }
  20%, 60% { transform: translateX(-8px); }
  40%, 80% { transform: translateX(8px); }
}

/* ═══════════════════════════════════════════
   TOP BAR
   ═══════════════════════════════════════════ */

.topbar {
  position: sticky;
  top: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 16px;
  height: 56px;
  background: var(--bg);
  border-bottom: 1px solid var(--border);
  backdrop-filter: blur(12px);
}

.topbar-brand {
  font-size: 16px;
  font-weight: 700;
  letter-spacing: 4px;
  color: var(--gold);
}

.topbar-clock {
  font-size: 14px;
  color: var(--text-muted);
  font-variant-numeric: tabular-nums;
}

.topbar-right {
  display: flex;
  gap: 4px;
}

.topbar-btn {
  width: 48px;
  height: 48px;
  border: none;
  border-radius: var(--radius-sm);
  background: transparent;
  color: var(--text-muted);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all var(--transition);
}

.topbar-btn:active {
  background: var(--card);
  color: var(--gold);
}

#newJobBtn {
  color: var(--gold);
}

/* ═══════════════════════════════════════════
   OFFLINE BANNER
   ═══════════════════════════════════════════ */

.offline-banner {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 16px;
  background: var(--danger-bg);
  color: var(--danger);
  font-size: 13px;
  border-bottom: 1px solid rgba(229, 57, 53, 0.2);
}

/* ═══════════════════════════════════════════
   KANBAN BOARD
   ═══════════════════════════════════════════ */

.kanban-container {
  height: calc(100dvh - 57px);
  overflow-x: auto;
  overflow-y: hidden;
  -webkit-overflow-scrolling: touch;
}

.kanban-board {
  display: flex;
  gap: 2px;
  padding: 12px 8px;
  height: 100%;
  min-width: min-content;
}

.kanban-column {
  flex: 0 0 280px;
  display: flex;
  flex-direction: column;
  background: var(--surface);
  border-radius: var(--radius);
  overflow: hidden;
}

.kanban-column-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 14px;
  border-bottom: 1px solid var(--border);
  flex-shrink: 0;
}

.kanban-column-title {
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--text);
}

.kanban-column-count {
  font-size: 11px;
  font-weight: 600;
  color: var(--bg);
  background: var(--text-dim);
  border-radius: 10px;
  padding: 2px 8px;
  min-width: 20px;
  text-align: center;
}

.kanban-column-body {
  flex: 1;
  overflow-y: auto;
  padding: 8px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.kanban-column-empty {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 80px;
  color: var(--text-dim);
  font-size: 13px;
}

/* ── Kanban Cards ── */

.kanban-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 12px 14px;
  transition: all var(--transition);
  position: relative;
}

.kanban-card:has(.kanban-card-advance) {
  padding-bottom: 4px;
}

.kanban-card-body {
  cursor: pointer;
  position: relative;
}

.kanban-card-body:active {
  opacity: 0.8;
}

.kanban-card-model {
  font-size: 14px;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 4px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.kanban-card-customer {
  font-size: 12px;
  color: var(--text);
  margin-bottom: 8px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.kanban-card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.kanban-card-time {
  font-size: 11px;
  color: #BBBBBB;
  font-variant-numeric: tabular-nums;
}

.kanban-card-staff {
  font-size: 11px;
  color: #BBBBBB;
  background: var(--border);
  padding: 2px 6px;
  border-radius: 4px;
}

.kanban-card-review {
  position: absolute;
  top: 8px;
  right: 8px;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--gold);
  box-shadow: 0 0 8px var(--gold-glow-strong);
  animation: pulse-gold 2s ease-in-out infinite;
}

@keyframes pulse-gold {
  0%, 100% { opacity: 1; box-shadow: 0 0 8px var(--gold-glow-strong); }
  50% { opacity: 0.6; box-shadow: 0 0 16px var(--gold-glow-strong); }
}

.kanban-card-photos {
  display: flex;
  gap: 2px;
  margin-top: 8px;
}

.kanban-card-photo {
  width: 28px;
  height: 28px;
  border-radius: 4px;
  object-fit: cover;
  border: 1px solid var(--border);
}

.kanban-card-photo-more {
  width: 28px;
  height: 28px;
  border-radius: 4px;
  background: var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 10px;
  color: var(--text-muted);
}

/* ── Quick advance button ── */

.kanban-card-advance {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  min-height: 48px;
  padding: 8px 14px;
  margin-top: 8px;
  border: 1px solid var(--border-light);
  border-radius: 0 0 6px 6px;
  background: var(--surface);
  color: var(--text);
  font-size: 12px;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  transition: all var(--transition);
  letter-spacing: 0.5px;
}

.kanban-card-advance:active {
  background: var(--gold-glow);
  color: var(--gold);
  border-color: var(--gold);
}

/* Status-colored left border on cards */
.kanban-card[data-status="Received"] { border-left: 3px solid var(--gold); }
.kanban-card[data-status="Diagnosing"] { border-left: 3px solid var(--amber); }
.kanban-card[data-status="Awaiting Approval"] { border-left: 3px solid var(--danger); }
.kanban-card[data-status="Approved"] { border-left: 3px solid var(--success); }
.kanban-card[data-status="Awaiting Parts"] { border-left: 3px solid var(--blue); }
.kanban-card[data-status="In Repair"] { border-left: 3px solid var(--amber); }
.kanban-card[data-status="Test Ride"] { border-left: 3px solid var(--blue); }
.kanban-card[data-status="Ready for Pickup"] { border-left: 3px solid var(--success); }

/* ═══════════════════════════════════════════
   STATUS BADGES
   ═══════════════════════════════════════════ */

.status-badge {
  display: inline-flex;
  align-items: center;
  padding: 4px 10px;
  border-radius: 20px;
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  white-space: nowrap;
}

.status-badge[data-status="Received"] { background: var(--gold-glow); color: var(--gold); }
.status-badge[data-status="Diagnosing"] { background: var(--amber-bg); color: var(--amber); }
.status-badge[data-status="Awaiting Approval"] { background: var(--danger-bg); color: var(--danger); }
.status-badge[data-status="Approved"] { background: var(--success-bg); color: var(--success); }
.status-badge[data-status="Awaiting Parts"] { background: var(--blue-bg); color: var(--blue); }
.status-badge[data-status="In Repair"] { background: var(--amber-bg); color: var(--amber); }
.status-badge[data-status="Test Ride"] { background: var(--blue-bg); color: var(--blue); }
.status-badge[data-status="Ready for Pickup"] { background: var(--success-bg); color: var(--success); }
.status-badge[data-status="Collected"] { background: var(--gray-bg); color: var(--gray); }
.status-badge[data-status="Declined"] { background: var(--danger-bg); color: var(--danger); }

/* ═══════════════════════════════════════════
   PANELS (slide-up detail view)
   ═══════════════════════════════════════════ */

.panel {
  position: fixed;
  inset: 0;
  z-index: 200;
}

.panel-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
  animation: fadeIn 0.2s ease;
}

.panel-sheet {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  max-height: 92dvh;
  background: var(--surface);
  border-radius: var(--radius-lg) var(--radius-lg) 0 0;
  display: flex;
  flex-direction: column;
  animation: slideUp 0.3s ease;
  box-shadow: var(--shadow-lg);
}

.panel-handle {
  width: 36px;
  height: 4px;
  background: var(--border-light);
  border-radius: 2px;
  margin: 8px auto;
  flex-shrink: 0;
}

.panel-header {
  padding: 8px 20px 16px;
  border-bottom: 1px solid var(--border);
  flex-shrink: 0;
}

.panel-title-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.panel-title {
  font-size: 20px;
  font-weight: 700;
  color: var(--text);
}

.panel-subtitle {
  font-size: 14px;
  color: var(--text-muted);
  margin-top: 2px;
}

.panel-body {
  flex: 1;
  overflow-y: auto;
  padding: 16px 20px;
}

.panel-footer {
  display: flex;
  gap: 12px;
  padding: 16px 20px;
  border-top: 1px solid var(--border);
  flex-shrink: 0;
}

.btn-status-link {
  color: var(--gold);
  border-color: var(--gold);
  gap: 6px;
  font-size: 13px;
  padding: 12px 14px;
}

.btn-status-link:active:not(:disabled) {
  background: var(--gold-glow);
}

/* ── Detail sections ── */

.detail-section {
  padding: 16px 0;
  border-bottom: 1px solid var(--border);
}

.detail-section:last-child {
  border-bottom: none;
}

.detail-section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
}

.detail-section-header h3 {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 1px;
}

.detail-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 0;
}

.detail-label {
  font-size: 13px;
  color: var(--text-dim);
}

.detail-value {
  font-size: 14px;
  color: var(--text);
  font-weight: 500;
}

.detail-phone {
  color: var(--gold);
  text-decoration: none;
}

/* ── Cost section ── */

.cost-row {
  display: flex;
  align-items: flex-end;
  gap: 12px;
  margin-bottom: 12px;
}

.cost-field {
  flex: 1;
}

.cost-version {
  font-size: 13px;
  color: var(--text-dim);
  padding-bottom: 12px;
  font-weight: 600;
}

/* ═══════════════════════════════════════════
   MODALS
   ═══════════════════════════════════════════ */

.modal {
  position: fixed;
  inset: 0;
  z-index: 300;
  display: flex;
  align-items: flex-end;
  justify-content: center;
}

.modal-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
  animation: fadeIn 0.2s ease;
}

.modal-content {
  position: relative;
  width: 100%;
  max-height: 92dvh;
  background: var(--surface);
  border-radius: var(--radius-lg) var(--radius-lg) 0 0;
  display: flex;
  flex-direction: column;
  animation: slideUp 0.3s ease;
  box-shadow: var(--shadow-lg);
}

.modal-large {
  max-width: 540px;
}

.modal-small {
  max-width: 400px;
}

.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 20px 16px;
  border-bottom: 1px solid var(--border);
  flex-shrink: 0;
}

.modal-header h2 {
  font-size: 18px;
  font-weight: 700;
}

.modal-close {
  width: 48px;
  height: 48px;
  border: none;
  border-radius: 50%;
  background: var(--card);
  color: var(--text-muted);
  font-size: 20px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

.modal-body {
  flex: 1;
  overflow-y: auto;
  padding: 20px;
}

.modal-footer {
  display: flex;
  gap: 12px;
  padding: 16px 20px;
  border-top: 1px solid var(--border);
  flex-shrink: 0;
}

.confirm-message {
  font-size: 15px;
  color: var(--text-muted);
  line-height: 1.5;
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes slideUp {
  from { transform: translateY(100%); }
  to { transform: translateY(0); }
}

/* ═══════════════════════════════════════════
   FORM ELEMENTS
   ═══════════════════════════════════════════ */

.form-group {
  margin-bottom: 16px;
}

.field-label {
  display: block;
  font-size: 12px;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 6px;
}

.field-hint {
  font-weight: 400;
  text-transform: none;
  letter-spacing: 0;
  color: var(--text-dim);
}

.required {
  color: var(--gold);
}

.field-input,
.field-textarea,
.field-select {
  width: 100%;
  padding: 12px 14px;
  min-height: 48px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text);
  font-size: 15px;
  transition: border-color var(--transition);
  -webkit-appearance: none;
}

.field-input:focus,
.field-textarea:focus,
.field-select:focus {
  outline: none;
  border-color: var(--gold);
  box-shadow: 0 0 0 3px var(--gold-glow);
}

.field-input::placeholder,
.field-textarea::placeholder {
  color: var(--text-dim);
}

.field-input-large {
  font-size: 24px;
  font-weight: 700;
  text-align: center;
  padding: 16px;
}

.field-select-large {
  font-size: 15px;
  font-weight: 600;
  padding: 14px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%23999' stroke-width='2'%3E%3Cpolyline points='6 9 12 15 18 9'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  padding-right: 40px;
}

.field-select {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%23999' stroke-width='2'%3E%3Cpolyline points='6 9 12 15 18 9'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  padding-right: 40px;
}

.field-textarea {
  min-height: 80px;
  resize: vertical;
  line-height: 1.5;
}

/* Toggle group */

.toggle-group {
  display: flex;
  gap: 8px;
  margin-bottom: 12px;
}

.toggle-btn {
  flex: 1;
  min-height: 48px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--card);
  color: var(--text-muted);
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: all var(--transition);
}

.toggle-btn.active {
  border-color: var(--gold);
  color: var(--gold);
  background: var(--gold-glow);
}

/* Checkbox */

.consent-group {
  padding: 12px 0;
}

.checkbox-label {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 13px;
  color: var(--text-muted);
  cursor: pointer;
  line-height: 1.4;
}

.checkbox-label input[type="checkbox"] {
  width: 20px;
  height: 20px;
  margin-top: 1px;
  accent-color: var(--gold);
  flex-shrink: 0;
}

/* ═══════════════════════════════════════════
   BUTTONS
   ═══════════════════════════════════════════ */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 48px;
  padding: 12px 24px;
  border: none;
  border-radius: var(--radius-sm);
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  transition: all var(--transition);
  white-space: nowrap;
}

.btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.btn-gold {
  background: linear-gradient(135deg, var(--gold), var(--gold-dim));
  color: var(--bg);
  box-shadow: 0 2px 12px var(--gold-glow);
}

.btn-gold:active:not(:disabled) {
  transform: scale(0.97);
  box-shadow: 0 1px 8px var(--gold-glow);
}

.btn-ghost {
  background: var(--card);
  color: var(--text);
  border: 1px solid var(--border);
}

.btn-ghost:active:not(:disabled) {
  background: var(--card-hover);
}

.btn-danger {
  background: var(--danger);
  color: var(--white);
}

.btn-full {
  width: 100%;
}

.btn-sm {
  min-height: 48px;
  padding: 10px 14px;
  font-size: 13px;
}

/* ═══════════════════════════════════════════
   PHOTOS
   ═══════════════════════════════════════════ */

.photo-gallery {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.photo-thumb {
  width: 72px;
  height: 72px;
  border-radius: var(--radius-sm);
  object-fit: cover;
  border: 1px solid var(--border);
  cursor: pointer;
  transition: border-color var(--transition);
}

.photo-thumb:active {
  border-color: var(--gold);
}

.photo-capture-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  width: 100%;
  min-height: 80px;
  border: 2px dashed var(--border-light);
  border-radius: var(--radius);
  background: transparent;
  color: var(--text-dim);
  font-size: 13px;
  cursor: pointer;
  transition: all var(--transition);
  margin-bottom: 12px;
}

.photo-capture-btn:active {
  border-color: var(--gold);
  color: var(--gold);
}

.intake-photo-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.intake-photo-thumb {
  width: 64px;
  height: 64px;
  border-radius: var(--radius-sm);
  object-fit: cover;
  border: 1px solid var(--border);
  position: relative;
}

.photo-upload-progress {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 0;
}

.progress-bar {
  flex: 1;
  height: 4px;
  background: var(--border);
  border-radius: 2px;
  overflow: hidden;
}

.progress-fill {
  height: 100%;
  background: var(--gold);
  border-radius: 2px;
  width: 0%;
  transition: width 0.3s ease;
}

.progress-text {
  font-size: 12px;
  color: var(--text-muted);
  white-space: nowrap;
}

/* ═══════════════════════════════════════════
   LIGHTBOX
   ═══════════════════════════════════════════ */

.lightbox {
  position: fixed;
  inset: 0;
  z-index: 500;
  background: rgba(0, 0, 0, 0.95);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  animation: fadeIn 0.2s ease;
}

.lightbox-close {
  position: absolute;
  top: 16px;
  right: 16px;
  width: 44px;
  height: 44px;
  border: none;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.1);
  color: var(--white);
  font-size: 24px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

.lightbox-img {
  max-width: 90vw;
  max-height: 80dvh;
  object-fit: contain;
  border-radius: var(--radius-sm);
}

.lightbox-nav {
  display: flex;
  align-items: center;
  gap: 24px;
  margin-top: 16px;
}

.lightbox-arrow {
  width: 44px;
  height: 44px;
  border: none;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.1);
  color: var(--white);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

.lightbox-counter {
  font-size: 14px;
  color: var(--text-muted);
}

/* ═══════════════════════════════════════════
   REVIEW BANNER
   ═══════════════════════════════════════════ */

.review-banner {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 14px 16px;
  background: var(--gold-glow);
  border: 1px solid var(--gold);
  border-radius: var(--radius-sm);
  margin-top: 16px;
}

.review-banner-icon {
  color: var(--gold);
  flex-shrink: 0;
  margin-top: 2px;
}

.review-banner-text {
  flex: 1;
  font-size: 13px;
  line-height: 1.4;
}

.review-banner-text strong {
  display: block;
  color: var(--gold);
  margin-bottom: 2px;
}

.review-banner-text span {
  color: var(--text-muted);
}

/* ═══════════════════════════════════════════
   DUPLICATE WARNING
   ═══════════════════════════════════════════ */

.duplicate-warning {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 12px 14px;
  background: var(--warning-bg);
  border: 1px solid rgba(249, 168, 37, 0.3);
  border-radius: var(--radius-sm);
  color: var(--warning);
  font-size: 13px;
}

/* ═══════════════════════════════════════════
   HISTORY VIEW
   ═══════════════════════════════════════════ */

.history-view {
  padding: 16px;
}

.history-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 16px;
}

.history-header h2 {
  font-size: 18px;
  font-weight: 700;
}

.history-filters {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.filter-select,
.filter-input {
  min-height: 48px;
  padding: 8px 12px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text);
  font-size: 13px;
}

.history-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.history-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 16px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: border-color var(--transition);
}

.history-item:active {
  border-color: var(--gold);
}

.history-item-left {
  flex: 1;
}

.history-item-model {
  font-size: 14px;
  font-weight: 600;
  margin-bottom: 2px;
}

.history-item-customer {
  font-size: 12px;
  color: var(--text-muted);
}

.history-item-date {
  font-size: 12px;
  color: var(--text-dim);
  text-align: right;
}

/* ═══════════════════════════════════════════
   DRAWER (menu)
   ═══════════════════════════════════════════ */

.drawer {
  position: fixed;
  inset: 0;
  z-index: 250;
}

.drawer-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.5);
  animation: fadeIn 0.2s ease;
}

.drawer-panel {
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  width: 280px;
  background: var(--surface);
  border-left: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  animation: slideLeft 0.3s ease;
}

.drawer-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  border-bottom: 1px solid var(--border);
}

.drawer-header h3 {
  font-size: 16px;
  font-weight: 700;
}

.drawer-close {
  width: 48px;
  height: 48px;
  border: none;
  border-radius: 50%;
  background: var(--card);
  color: var(--text-muted);
  font-size: 20px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

.drawer-body {
  flex: 1;
  padding: 20px;
}

.menu-section {
  margin-bottom: 20px;
}

.menu-label {
  display: block;
  font-size: 11px;
  font-weight: 600;
  color: var(--text-dim);
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 8px;
}

.menu-select {
  width: 100%;
  min-height: 48px;
  padding: 12px 14px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text);
  font-size: 15px;
  -webkit-appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%23999' stroke-width='2'%3E%3Cpolyline points='6 9 12 15 18 9'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  padding-right: 40px;
}

.menu-stat {
  font-size: 28px;
  font-weight: 700;
  color: var(--text);
}

.menu-stat-warning {
  color: var(--gold);
}

.menu-divider {
  height: 1px;
  background: var(--border);
  margin: 20px 0;
}

.menu-action {
  width: 100%;
  min-height: 48px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: transparent;
  color: var(--text-muted);
  font-size: 14px;
  cursor: pointer;
  transition: all var(--transition);
}

.menu-action:active {
  background: var(--card);
}

@keyframes slideLeft {
  from { transform: translateX(100%); }
  to { transform: translateX(0); }
}

/* ═══════════════════════════════════════════
   TOASTS
   ═══════════════════════════════════════════ */

.toast-container {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 600;
  display: flex;
  flex-direction: column;
  gap: 8px;
  width: calc(100% - 32px);
  max-width: 400px;
  pointer-events: none;
}

.toast {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 18px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  animation: toastIn 0.3s ease;
  pointer-events: auto;
}

.toast-success { border-left: 3px solid var(--success); }
.toast-error { border-left: 3px solid var(--danger); }
.toast-info { border-left: 3px solid var(--blue); }

.toast-text {
  flex: 1;
  font-size: 14px;
  color: var(--text);
}

@keyframes toastIn {
  from { opacity: 0; transform: translateY(16px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ═══════════════════════════════════════════
   LOADING / SPINNER
   ═══════════════════════════════════════════ */

.spinner-inline {
  width: 18px;
  height: 18px;
  border: 2px solid var(--border);
  border-top-color: var(--gold);
  border-radius: 50%;
  animation: spin 0.6s linear infinite;
  display: inline-block;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

.loading-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.3);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 50;
  border-radius: var(--radius);
}

/* ═══════════════════════════════════════════
   RESPONSIVE
   ═══════════════════════════════════════════ */

@media (min-width: 768px) {
  .modal-content {
    max-height: 85vh;
    border-radius: var(--radius-lg);
    margin: auto;
    align-self: center;
  }

  .panel-sheet {
    max-width: 540px;
    left: auto;
    right: 0;
    max-height: 100dvh;
    border-radius: var(--radius-lg) 0 0 var(--radius-lg);
    animation: slideFromRight 0.3s ease;
  }

  .kanban-column {
    flex: 0 0 300px;
  }
}

@keyframes slideFromRight {
  from { transform: translateX(100%); }
  to { transform: translateX(0); }
}

@media (min-width: 1024px) {
  .kanban-column {
    flex: 1;
    min-width: 200px;
    max-width: 320px;
  }
}
