/* ==========================================================================
   CARPOOL - Premium Vehicle & Visit Management System Stylesheet
   Mobile-First & Android Optimized UI
   ========================================================================== */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&family=Oswald:wght@600;700&display=swap');

:root {
  --bg-dark: #0f172a;
  --bg-card: #1e293b;
  --bg-card-hover: #334155;
  --border-color: #334155;
  --text-main: #f8fafc;
  --text-muted: #94a3b8;
  --primary: #6366f1;
  --primary-hover: #4f46e5;
  --accent-blue: #38bdf8;
  --success: #10b981;
  --warning: #f59e0b;
  --danger: #ef4444;
  --purple: #a855f7;
  --uk-yellow: #facc15;
  --uk-black: #0f172a;
  --radius-lg: 16px;
  --radius-md: 10px;
  --radius-sm: 6px;
  --shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.4), 0 8px 10px -6px rgba(0, 0, 0, 0.3);
  --shadow-hover: 0 20px 30px -10px rgba(0, 0, 0, 0.6);
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  -webkit-tap-highlight-color: transparent;
}

body {
  font-family: 'Inter', system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
  background-color: var(--bg-dark);
  color: var(--text-main);
  line-height: 1.5;
  min-height: 100vh;
  padding-bottom: 90px; /* Space for mobile bottom bar */
}

.container {
  max-width: 1320px;
  margin: 0 auto;
  padding: 0 16px;
}

/* Navbar & Header */
.navbar {
  background: rgba(30, 41, 59, 0.95);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border-color);
  position: sticky;
  top: 0;
  z-index: 100;
  padding: 12px 0;
  margin-bottom: 20px;
}

.nav-wrapper {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
}

.brand-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--text-main);
  font-size: 1.3rem;
  font-weight: 800;
  letter-spacing: -0.5px;
}

.brand-logo .logo-icon {
  background: linear-gradient(135deg, var(--primary), var(--accent-blue));
  width: 38px;
  height: 38px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
  box-shadow: 0 4px 12px rgba(99, 102, 241, 0.4);
}

.nav-actions {
  display: flex;
  gap: 10px;
  align-items: center;
}

/* Custom UK Reg Badge */
.uk-reg-badge {
  display: inline-flex;
  align-items: center;
  background: var(--uk-yellow);
  color: var(--uk-black);
  font-family: 'Oswald', sans-serif;
  font-weight: 700;
  font-size: 1.15rem;
  letter-spacing: 2px;
  padding: 4px 10px;
  border-radius: 6px;
  border: 2px solid #000;
  box-shadow: 0 2px 4px rgba(0,0,0,0.3);
  text-transform: uppercase;
  white-space: nowrap;
}

.uk-reg-badge::before {
  content: 'GB';
  display: inline-block;
  background: #003399;
  color: #fff;
  font-size: 0.6rem;
  font-family: 'Inter', sans-serif;
  font-weight: 700;
  padding: 2px 4px;
  border-radius: 3px;
  margin-right: 8px;
  letter-spacing: 0;
}

/* Control Bar / Toolbar */
.toolbar {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 16px;
  margin-bottom: 20px;
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  justify-content: space-between;
  align-items: center;
  box-shadow: var(--shadow);
}

.search-box {
  position: relative;
  flex: 1;
  min-width: 220px;
}

.search-box input {
  width: 100%;
  padding: 12px 16px 12px 42px;
  background: #0f172a;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  color: var(--text-main);
  font-size: 0.95rem;
  transition: all 0.2s ease;
  min-height: 48px; /* Android touch target */
}

.search-box input:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.2);
}

.search-box .search-icon {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-muted);
}

.filter-group {
  display: flex;
  gap: 10px;
  align-items: center;
  flex-wrap: wrap;
  width: 100%;
}

@media (min-width: 768px) {
  .filter-group {
    width: auto;
  }
}

.select-input {
  background: #0f172a;
  border: 1px solid var(--border-color);
  color: var(--text-main);
  padding: 12px 14px;
  border-radius: var(--radius-md);
  font-size: 0.9rem;
  outline: none;
  cursor: pointer;
  min-height: 48px;
  flex: 1;
}

.select-input:focus {
  border-color: var(--primary);
}

/* Action Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 18px;
  border-radius: var(--radius-md);
  font-weight: 600;
  font-size: 0.9rem;
  cursor: pointer;
  border: none;
  text-decoration: none;
  transition: all 0.2s ease;
  min-height: 44px; /* Touch target minimum */
  user-select: none;
}

.btn-primary {
  background: linear-gradient(135deg, var(--primary), var(--primary-hover));
  color: #fff;
  box-shadow: 0 4px 12px rgba(99, 102, 241, 0.35);
}

.btn-primary:active {
  transform: scale(0.97);
}

.btn-secondary {
  background: #334155;
  color: var(--text-main);
}

.btn-secondary:active {
  background: #475569;
}

.btn-gov {
  background: #00703c;
  color: #ffffff;
  font-weight: 600;
}

.btn-gov:active {
  background: #005a30;
}

.btn-maps {
  background: #1a73e8;
  color: #ffffff;
  font-weight: 600;
}

.btn-maps:active {
  background: #1557b0;
}

.btn-camera {
  background: linear-gradient(135deg, #ec4899, #d946ef);
  color: #ffffff;
  font-weight: 700;
  box-shadow: 0 4px 12px rgba(217, 70, 239, 0.35);
}

.btn-camera:active {
  transform: scale(0.96);
}

.btn-danger {
  background: rgba(239, 68, 68, 0.15);
  color: #f87171;
  border: 1px solid rgba(239, 68, 68, 0.3);
}

.btn-danger:active {
  background: rgba(239, 68, 68, 0.3);
}

.btn-sm {
  padding: 8px 12px;
  font-size: 0.82rem;
  border-radius: var(--radius-sm);
  min-height: 38px;
}

.btn-print {
  background: linear-gradient(135deg, #0ea5e9, #0284c7);
  color: white;
}

/* Status Badges */
.badge-status {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  border-radius: 20px;
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.status-24hour-sticker {
  background: rgba(245, 158, 11, 0.15);
  color: #fbbf24;
  border: 1px solid rgba(245, 158, 11, 0.3);
}

.status-15-days-sticker {
  background: rgba(234, 179, 8, 0.15);
  color: #fde047;
  border: 1px solid rgba(234, 179, 8, 0.3);
}

.status-notification {
  background: rgba(56, 189, 248, 0.15);
  color: #38bdf8;
  border: 1px solid rgba(56, 189, 248, 0.3);
}

.status-re-visit {
  background: rgba(168, 85, 247, 0.15);
  color: #c084fc;
  border: 1px solid rgba(168, 85, 247, 0.3);
}

.status-sent-to-contractor {
  background: rgba(239, 68, 68, 0.15);
  color: #f87171;
  border: 1px solid rgba(239, 68, 68, 0.3);
}

.status-collected-closed {
  background: rgba(16, 185, 129, 0.15);
  color: #34d399;
  border: 1px solid rgba(16, 185, 129, 0.3);
}

/* Vehicle List Cards (Mobile Optimized Layout) */
.records-container {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.car-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 16px;
  display: grid;
  grid-template-columns: 28px 80px 1fr;
  gap: 12px;
  align-items: start;
  box-shadow: var(--shadow);
  transition: all 0.2s ease;
  position: relative;
}

.car-location-box {
  grid-column: 1 / -1;
  background: #0f172a;
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-color);
  font-size: 0.85rem;
  color: var(--text-muted);
  width: 100%;
}

.last-visit-box {
  grid-column: 1 / -1;
  background: #0f172a;
  border-left: 4px solid var(--primary);
  padding: 12px;
  border-radius: var(--radius-sm);
  font-size: 0.85rem;
  display: flex;
  flex-direction: column;
  gap: 4px;
  width: 100%;
}

.last-visit-box div {
  max-width: 100% !important;
  white-space: normal !important;
  word-break: break-word;
}

.car-card-actions {
  grid-column: 1 / -1;
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 6px;
  padding-top: 10px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  width: 100%;
}

@media (min-width: 900px) {
  .car-card {
    grid-template-columns: 40px 100px 1.5fr 1.5fr 1.2fr 180px;
    align-items: center;
    padding: 20px;
  }

  .car-location-box {
    grid-column: auto;
    background: transparent;
    border: none;
    padding: 0;
  }

  .last-visit-box {
    grid-column: auto;
    width: auto;
  }

  .car-card-actions {
    grid-column: auto;
    border-top: none;
    padding-top: 0;
    margin-top: 0;
    flex-direction: column;
    width: auto;
  }
}

.custom-checkbox {
  width: 24px;
  height: 24px;
  accent-color: var(--primary);
  cursor: pointer;
}

.car-thumb-box {
  width: 85px;
  height: 85px;
  border-radius: var(--radius-md);
  overflow: hidden;
  background: #0f172a;
  border: 1px solid var(--border-color);
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
}

.car-thumb-box img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  cursor: pointer;
}

.car-thumb-placeholder {
  font-size: 2.2rem;
  color: var(--text-muted);
}

.car-specs {
  font-size: 0.85rem;
  color: var(--text-muted);
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  margin-top: 4px;
}

.spec-pill {
  display: inline-block;
  background: #0f172a;
  padding: 3px 8px;
  border-radius: 4px;
  border: 1px solid var(--border-color);
  font-size: 0.78rem;
  color: var(--text-main);
}

.last-visit-box {
  background: #0f172a;
  border-left: 4px solid var(--primary);
  padding: 12px;
  border-radius: var(--radius-sm);
  font-size: 0.85rem;
  display: flex;
  flex-direction: column;
  gap: 4px;
  margin-top: 6px;
}

.last-visit-header {
  font-size: 0.72rem;
  text-transform: uppercase;
  color: var(--text-muted);
  font-weight: 700;
  letter-spacing: 0.5px;
}

/* Modals Mobile Bottom Sheet Styling */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(15, 23, 42, 0.85);
  backdrop-filter: blur(8px);
  z-index: 1000;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: all 0.3s ease;
}

@media (min-width: 640px) {
  .modal-overlay {
    align-items: center;
    padding: 20px;
  }
}

.modal-overlay.active {
  opacity: 1;
  pointer-events: auto;
}

.modal-container {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 24px 24px 0 0;
  width: 100%;
  max-height: 92vh;
  overflow-y: auto;
  box-shadow: 0 -10px 40px rgba(0, 0, 0, 0.7);
  padding: 24px 20px;
  position: relative;
}

@media (min-width: 640px) {
  .modal-container {
    border-radius: var(--radius-lg);
    max-width: 650px;
    max-height: 90vh;
  }
}

.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 18px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--border-color);
}

.modal-title {
  font-size: 1.15rem;
  font-weight: 700;
}

.modal-close {
  background: #334155;
  border: none;
  color: var(--text-main);
  width: 36px;
  height: 36px;
  border-radius: 50%;
  font-size: 1.2rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Form Controls Touch Sized */
.form-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
}

@media (min-width: 600px) {
  .form-grid {
    grid-template-columns: 1fr 1fr;
  }
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-bottom: 12px;
}

.form-group.full-width {
  grid-column: 1 / -1;
}

.form-label {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-muted);
}

.form-control {
  background: #0f172a;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 12px 14px;
  color: var(--text-main);
  font-size: 0.95rem;
  transition: border-color 0.2s ease;
  min-height: 48px; /* Touch target size */
}

.form-control:focus {
  outline: none;
  border-color: var(--primary);
}

textarea.form-control {
  resize: vertical;
  min-height: 90px;
}

/* Drag Drop File Upload & Camera Buttons */
.upload-dropzone {
  border: 2px dashed var(--border-color);
  border-radius: var(--radius-lg);
  padding: 24px 16px;
  text-align: center;
  cursor: pointer;
  background: #0f172a;
  transition: all 0.2s ease;
}

.upload-dropzone:active, .upload-dropzone.dragover {
  border-color: var(--primary);
  background: rgba(99, 102, 241, 0.08);
}

.upload-preview {
  max-height: 220px;
  width: 100%;
  border-radius: var(--radius-md);
  margin-top: 12px;
  object-fit: cover;
}

/* Mobile Bottom Navigation Bar (Android Fixed Dock) */
.mobile-bottom-nav {
  display: flex;
  position: fixed;
  bottom: 0;
  left: 0;
  width: 100%;
  background: rgba(15, 23, 42, 0.96);
  backdrop-filter: blur(16px);
  border-top: 1px solid var(--border-color);
  padding: 10px 16px;
  justify-content: space-around;
  align-items: center;
  z-index: 900;
  box-shadow: 0 -5px 25px rgba(0,0,0,0.5);
}

@media (min-width: 768px) {
  .mobile-bottom-nav {
    display: none;
  }
  body {
    padding-bottom: 40px;
  }
}

.mobile-nav-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
  color: var(--text-muted);
  text-decoration: none;
  font-size: 0.72rem;
  font-weight: 600;
  padding: 6px 12px;
  border-radius: 8px;
}

.mobile-nav-item.active, .mobile-nav-item:active {
  color: var(--accent-blue);
  background: rgba(56, 189, 248, 0.1);
}

.mobile-nav-item .nav-icon {
  font-size: 1.3rem;
}

/* Timeline for Visits */
.visit-timeline {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: 14px;
}

.visit-item {
  background: #0f172a;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 14px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

@media (min-width: 500px) {
  .visit-item {
    flex-direction: row;
    justify-content: space-between;
    align-items: flex-start;
  }
}

/* Print Styles */
@media print {
  body {
    background: #ffffff !important;
    color: #000000 !important;
    padding-bottom: 0 !important;
  }
  .navbar, .toolbar, .mobile-bottom-nav, .no-print {
    display: none !important;
  }
  .container {
    max-width: 100% !important;
    padding: 0 !important;
  }
  .car-card {
    background: #ffffff !important;
    border: 1px solid #ccc !important;
    color: #000000 !important;
    page-break-inside: avoid;
    margin-bottom: 20px;
    box-shadow: none !important;
    grid-template-columns: 90px 1.5fr 1.5fr 1.2fr;
  }
  .custom-checkbox {
    display: none !important;
  }
  .car-card-actions {
    display: none !important;
  }
  .last-visit-box {
    background: #f8fafc !important;
    border-left: 3px solid #000000 !important;
    color: #000000 !important;
  }
  .spec-pill {
    background: #f1f5f9 !important;
    color: #000000 !important;
    border: 1px solid #cbd5e1 !important;
  }
}

/* ========================================================
   4-PICTURE UPLOAD GRID & REMINDER STYLES
   ======================================================== */

.multi-photos-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
  margin-top: 8px;
}

@media (min-width: 640px) {
  .multi-photos-grid {
    grid-template-columns: repeat(4, 1fr);
  }
}

.photo-slot-card {
  background: #0f172a;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 10px;
  display: flex;
  flex-direction: column;
}

.photo-slot-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.76rem;
  font-weight: 700;
  color: var(--text-muted);
  margin-bottom: 6px;
}

.btn-slot-clear {
  background: transparent;
  border: none;
  color: #f87171;
  font-size: 0.72rem;
  font-weight: 600;
  cursor: pointer;
  padding: 0;
}

.btn-slot-clear:hover {
  text-decoration: underline;
}

.slot-dropzone {
  min-height: 110px;
  padding: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 2px dashed var(--border-color);
  border-radius: 8px;
  background: rgba(15, 23, 42, 0.6);
  cursor: pointer;
}

.slot-placeholder {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.slot-preview {
  max-height: 100px;
  width: 100%;
  object-fit: cover;
  border-radius: 6px;
  margin-top: 0;
}

/* Dashboard Thumbnails & Mini-Thumbs */
.thumb-wrapper {
  position: relative;
  width: 100%;
  height: 90px;
  cursor: pointer;
}

.thumb-wrapper img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-color);
}

.photo-count-badge {
  position: absolute;
  bottom: 4px;
  right: 4px;
  background: rgba(15, 23, 42, 0.88);
  color: #38bdf8;
  font-size: 0.7rem;
  font-weight: 700;
  padding: 2px 6px;
  border-radius: 6px;
  border: 1px solid rgba(56, 189, 248, 0.4);
  backdrop-filter: blur(4px);
}

.mini-thumbs-row {
  display: flex;
  gap: 4px;
  margin-top: 6px;
}

.mini-thumb {
  width: 26px;
  height: 26px;
  object-fit: cover;
  border-radius: 4px;
  border: 1px solid var(--border-color);
  cursor: pointer;
  transition: transform 0.15s ease;
}

.mini-thumb:hover {
  transform: scale(1.15);
  border-color: var(--primary);
}

/* Lift Reminders Alert Banner */
.reminder-alert-banner {
  background: linear-gradient(135deg, rgba(239, 68, 68, 0.18), rgba(185, 28, 28, 0.28));
  border: 1px solid rgba(239, 68, 68, 0.4);
  border-radius: var(--radius-lg);
  padding: 16px 20px;
  margin-bottom: 20px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  box-shadow: 0 4px 20px rgba(239, 68, 68, 0.15);
}

@media (min-width: 640px) {
  .reminder-alert-banner {
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
  }
}

.reminder-banner-content {
  display: flex;
  align-items: center;
  gap: 14px;
}

.reminder-banner-icon {
  font-size: 2.2rem;
  animation: pulse-ring 2s infinite;
}

@keyframes pulse-ring {
  0% { transform: scale(1); }
  50% { transform: scale(1.1); }
  100% { transform: scale(1); }
}

.reminder-banner-title {
  font-size: 1.05rem;
  font-weight: 800;
  color: #f87171;
}

.reminder-banner-sub {
  font-size: 0.84rem;
  color: #cbd5e1;
  margin-top: 2px;
}

.reminder-banner-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

/* Lift Due Card Highlighting & Badges */
.card-lift-overdue {
  border-color: rgba(239, 68, 68, 0.5) !important;
  background: linear-gradient(180deg, rgba(239, 68, 68, 0.04), var(--bg-card)) !important;
}

.badge-lift-due {
  background: rgba(239, 68, 68, 0.2);
  border: 1px solid rgba(239, 68, 68, 0.4);
  color: #f87171;
  font-size: 0.72rem;
  font-weight: 800;
  padding: 3px 8px;
  border-radius: 6px;
  letter-spacing: 0.5px;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

/* Lightbox Modal & Interactive Zoom */
.lightbox-modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 2500;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s ease;
}

.lightbox-modal.active {
  opacity: 1;
  pointer-events: auto;
}

.lightbox-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(10, 15, 30, 0.94);
  backdrop-filter: blur(12px);
}

.lightbox-content {
  position: relative;
  z-index: 2501;
  max-width: 92vw;
  max-height: 88vh;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.lightbox-img-container {
  position: relative;
  overflow: hidden;
  max-width: 90vw;
  max-height: 75vh;
  border-radius: 12px;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.85);
  border: 1px solid rgba(255, 255, 255, 0.15);
  background: #090d16;
  display: flex;
  align-items: center;
  justify-content: center;
  user-select: none;
  touch-action: none;
}

.lightbox-content img {
  max-width: 90vw;
  max-height: 75vh;
  object-fit: contain;
  border-radius: 12px;
  cursor: zoom-in;
  transition: transform 0.25s cubic-bezier(0.25, 1, 0.5, 1);
  transform-origin: center center;
  display: block;
}

.lightbox-content img.is-zoomed {
  cursor: grab;
}

.lightbox-content img.is-zoomed:active {
  cursor: grabbing;
}

.lightbox-toolbar {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 10px;
  background: rgba(15, 23, 42, 0.85);
  border: 1px solid rgba(255, 255, 255, 0.15);
  padding: 6px 14px;
  border-radius: 30px;
  backdrop-filter: blur(8px);
  z-index: 2502;
  flex-wrap: wrap;
  justify-content: center;
}

.lightbox-toolbar button {
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: #ffffff;
  font-size: 0.82rem;
  font-weight: 600;
  padding: 4px 12px;
  border-radius: 16px;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 4px;
  transition: all 0.2s;
}

.lightbox-toolbar button:hover {
  background: rgba(255, 255, 255, 0.25);
}

.lightbox-zoom-hint {
  color: #94a3b8;
  font-size: 0.8rem;
  font-weight: 500;
}

.lightbox-close {
  position: absolute;
  top: -45px;
  right: 0;
  background: rgba(255, 255, 255, 0.2);
  border: none;
  color: #ffffff;
  font-size: 1.4rem;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

.lightbox-prev, .lightbox-next {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(15, 23, 42, 0.75);
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: #ffffff;
  font-size: 1.5rem;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  backdrop-filter: blur(4px);
  z-index: 2503;
}

.lightbox-prev { left: -60px; }
.lightbox-next { right: -60px; }

@media (max-width: 640px) {
  .lightbox-prev { left: 10px; }
  .lightbox-next { right: 10px; }
}

.lightbox-caption {
  margin-top: 4px;
  color: #94a3b8;
  font-size: 0.85rem;
  font-weight: 600;
}

/* ==========================================================================
   LEGALITY CHECKLIST & EXPORT STYLES
   ========================================================================== */

/* Assessment Badges on Vehicle Cards */
.badge-assessment {
  font-size: 0.78rem;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: 6px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.badge-assessment:hover {
  transform: translateY(-1px);
}

.badge-assessment.auth-immediate {
  background: rgba(239, 68, 68, 0.2);
  color: #f87171;
  border: 1px solid rgba(239, 68, 68, 0.4);
}

.badge-assessment.auth-notice {
  background: rgba(245, 158, 11, 0.2);
  color: #fbbf24;
  border: 1px solid rgba(245, 158, 11, 0.4);
}

.badge-assessment.auth-pause {
  background: rgba(16, 185, 129, 0.2);
  color: #34d399;
  border: 1px solid rgba(16, 185, 129, 0.4);
}

.badge-assessment.auth-none {
  background: rgba(148, 163, 184, 0.15);
  color: #cbd5e1;
  border: 1px dashed rgba(148, 163, 184, 0.4);
}

/* Assessment Modal Authorization Header Banner */
.auth-banner {
  font-size: 0.88rem;
  font-weight: 800;
  padding: 4px 12px;
  border-radius: 8px;
  display: inline-block;
  letter-spacing: 0.5px;
}

.auth-banner-immediate {
  background: #ef4444;
  color: #ffffff;
  box-shadow: 0 0 12px rgba(239, 68, 68, 0.5);
}

.auth-banner-notice {
  background: #f59e0b;
  color: #0f172a;
  box-shadow: 0 0 12px rgba(245, 158, 11, 0.4);
}

.auth-banner-pause {
  background: #10b981;
  color: #ffffff;
  box-shadow: 0 0 12px rgba(16, 185, 129, 0.4);
}

/* Assessment Form Layout */
.assessment-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}

@media (max-width: 640px) {
  .assessment-grid {
    grid-template-columns: 1fr;
  }
}

.assess-group {
  display: flex;
  flex-direction: column;
}

.assess-group.full-width {
  grid-column: 1 / -1;
}

.assess-label {
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--text-main);
  margin-bottom: 4px;
}

.assess-sub {
  font-size: 0.72rem;
  color: var(--text-muted);
  margin-top: 3px;
  font-style: italic;
}

/* Export Photos Grid in Export Modal */
.export-photo-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
}

@media (max-width: 640px) {
  .export-photo-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

.export-photo-card {
  background: #0f172a;
  border: 1px solid var(--border-color);
  border-radius: 8px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.export-photo-thumb {
  width: 100%;
  height: 90px;
  object-fit: cover;
  background: #000000;
}

.export-photo-empty {
  width: 100%;
  height: 90px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
  font-size: 0.75rem;
  background: #1e293b;
}

.export-photo-btn {
  width: 100%;
  padding: 6px 4px;
  font-size: 0.75rem;
  font-weight: 600;
  text-align: center;
  background: var(--bg-card);
  color: var(--text-main);
  border-top: 1px solid var(--border-color);
  text-decoration: none;
  display: block;
  transition: background 0.15s ease;
}

.export-photo-btn:hover {
  background: var(--primary);
  color: #ffffff;
}

/* Mobile Touch & Layout Optimizations */
@media (max-width: 640px) {
  .modal-container {
    padding: 16px 12px;
    max-height: 92vh;
    border-radius: 12px;
  }
  
  .form-control, select.form-control {
    min-height: 48px;
    font-size: 0.95rem;
  }
  
  .btn-sm {
    min-height: 42px;
    padding: 6px 10px;
    font-size: 0.82rem;
  }
  
  .modal-sticky-actions {
    position: sticky;
    bottom: -16px;
    background: var(--bg-card);
    padding: 12px 0 4px 0;
    border-top: 1px solid var(--border-color);
    z-index: 10;
  }
}

