/* Button Components */
.btn {
  transition: all 0.3s ease;
  font-weight: 600;
  border: none;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.btn-primary {
  background: linear-gradient(135deg, var(--primary), var(--accent));
  color: white;
  padding: 12px 24px;
  border-radius: 12px;
  box-shadow: 0 4px 15px rgba(6, 182, 212, 0.3);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(6, 182, 212, 0.4);
}

.btn-primary:active {
  transform: translateY(0);
}

.btn-secondary {
  background: white;
  color: var(--text);
  padding: 12px 24px;
  border-radius: 12px;
  border: 1px solid #e5e7eb;
}

.btn-secondary:hover {
  border-color: var(--primary);
  color: var(--primary);
  transform: translateY(-1px);
}

.btn-danger {
  background: linear-gradient(135deg, var(--danger), #dc2626);
  color: white;
  padding: 12px 24px;
  border-radius: 12px;
}

.btn-success {
  background: linear-gradient(135deg, var(--success), #059669);
  color: white;
  padding: 12px 24px;
  border-radius: 12px;
}

.btn-sm {
  padding: 8px 16px;
  font-size: 0.875rem;
}

.btn-lg {
  padding: 16px 32px;
  font-size: 1.125rem;
}

/* Card Components */
.card {
  background: white;
  border-radius: 16px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.5);
  transition: all 0.3s ease;
}

.card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.12);
}

.card-header {
  padding: 20px 24px 0;
  border-bottom: 1px solid #f3f4f6;
}

.card-body {
  padding: 24px;
}

.card-footer {
  padding: 0 24px 20px;
  border-top: 1px solid #f3f4f6;
}

/* Form Components */
.form-group {
  margin-bottom: 20px;
}

.form-label {
  display: block;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 8px;
  font-size: 0.875rem;
}

.form-control {
  width: 100%;
  padding: 12px 16px;
  border: 2px solid #e5e7eb;
  border-radius: 12px;
  font-size: 14px;
  transition: all 0.3s ease;
  background: white;
}

.form-control:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(6, 182, 212, 0.1);
}

.form-control.error {
  border-color: var(--danger);
  box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.1);
}

.form-text {
  font-size: 0.75rem;
  color: var(--text-light);
  margin-top: 4px;
}

.form-text.error {
  color: var(--danger);
}

/* Modal Components */
.modal {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.5);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  padding: 20px;
}

.modal-content {
  background: white;
  border-radius: 20px;
  padding: 24px;
  box-shadow: 0 25px 50px rgba(0, 0, 0, 0.2);
  animation: modalSlideIn 0.3s ease-out;
  max-width: 90vw;
  max-height: 90vh;
  overflow-y: auto;
}

.modal-lg {
  max-width: 800px;
}

.modal-md {
  max-width: 600px;
}

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

@keyframes modalSlideIn {
  from {
    opacity: 0;
    transform: translateY(-20px) scale(0.95);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

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

/* Badge Components */
.badge {
  display: inline-flex;
  align-items: center;
  padding: 4px 12px;
  border-radius: 20px;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.badge-primary {
  background: linear-gradient(135deg, var(--primary), var(--accent));
  color: white;
}

.badge-success {
  background: var(--success);
  color: white;
}

.badge-warning {
  background: var(--warning);
  color: white;
}

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

.badge-info {
  background: var(--primary);
  color: white;
}

.badge-outline {
  background: transparent;
  border: 1px solid currentColor;
}

/* Alert Components */
.alert {
  padding: 16px 20px;
  border-radius: 12px;
  margin-bottom: 20px;
  border-left: 4px solid;
}

.alert-success {
  background: #f0fdf4;
  border-color: var(--success);
  color: #166534;
}

.alert-warning {
  background: #fffbeb;
  border-color: var(--warning);
  color: #92400e;
}

.alert-danger {
  background: #fef2f2;
  border-color: var(--danger);
  color: #991b1b;
}

.alert-info {
  background: #f0f9ff;
  border-color: var(--primary);
  color: #0c4a6e;
}

/* Car Card Components */
.car-card {
  background: white;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
  transition: all 0.3s ease;
  border: 1px solid rgba(255, 255, 255, 0.5);
}

.car-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
}

.car-image {
  width: 100%;
  height: 200px;
  object-fit: cover;
  background: linear-gradient(135deg, #a5f3fc, #f0abfc);
}

.car-image-placeholder {
  width: 100%;
  height: 200px;
  background: linear-gradient(135deg, #a5f3fc, #f0abfc);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 3rem;
}

.price-tag {
  background: linear-gradient(135deg, var(--success), var(--primary));
  color: white;
  padding: 8px 16px;
  border-radius: 20px;
  font-weight: 700;
  font-size: 1.25rem;
  box-shadow: 0 4px 12px rgba(6, 182, 212, 0.3);
}

/* Navigation Components */
.nav-tabs {
  display: flex;
  border-bottom: 2px solid #e5e7eb;
  margin-bottom: 24px;
}

.nav-tab {
  padding: 12px 24px;
  background: none;
  border: none;
  color: var(--text-light);
  font-weight: 600;
  cursor: pointer;
  border-bottom: 2px solid transparent;
  transition: all 0.3s ease;
}

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

.nav-tab:hover:not(.active) {
  color: var(--text);
}

/* Payment System Components */
.payment-tab {
  background: white;
  border: 2px solid #e5e7eb;
  color: #6b7280;
  transition: all 0.3s ease;
  padding: 12px 16px;
  border-radius: 12px;
  font-weight: 600;
  cursor: pointer;
}

.payment-tab.active {
  background: linear-gradient(135deg, var(--primary), var(--accent));
  border-color: var(--primary);
  color: white;
  box-shadow: 0 4px 15px rgba(6, 182, 212, 0.3);
}

.payment-tab:hover:not(.active) {
  border-color: var(--primary);
  color: var(--primary);
  transform: translateY(-1px);
}

.payment-method {
  transition: all 0.3s ease;
}

.payment-method.hidden {
  display: none;
}

.payment-method.active {
  display: block;
  animation: fadeIn 0.3s ease;
}

/* Message Components */
.message-bubble {
  max-width: 70%;
  padding: 12px 16px;
  border-radius: 18px;
  margin-bottom: 8px;
  position: relative;
}

.message-bubble.own {
  background: linear-gradient(135deg, var(--primary), var(--accent));
  color: white;
  margin-left: auto;
  border-bottom-right-radius: 4px;
}

.message-bubble.other {
  background: #f3f4f6;
  color: var(--text);
  margin-right: auto;
  border-bottom-left-radius: 4px;
}

.message-sender {
  font-size: 0.75rem;
  font-weight: 600;
  margin-bottom: 4px;
  opacity: 0.8;
}

.message-time {
  font-size: 0.7rem;
  opacity: 0.6;
  text-align: right;
  margin-top: 4px;
}

/* Loading Components */
.loading-spinner {
  width: 40px;
  height: 40px;
  border: 4px solid #f3f4f6;
  border-top: 4px solid var(--primary);
  border-radius: 50%;
  animation: spin 1s linear infinite;
  margin: 20px auto;
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

.loading-overlay {
  position: fixed;
  inset: 0;
  background: rgba(255, 255, 255, 0.8);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  backdrop-filter: blur(4px);
}

/* Image Upload Components */
.image-upload-area {
  border: 2px dashed #d1d5db;
  border-radius: 12px;
  padding: 40px 20px;
  text-align: center;
  transition: all 0.3s ease;
  background: #f9fafb;
  cursor: pointer;
}

.image-upload-area:hover {
  border-color: var(--primary);
  background: #f0f9ff;
}

.image-upload-area.dragover {
  border-color: var(--primary);
  background: #e0f2fe;
  transform: scale(1.02);
}

.image-preview {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
  gap: 12px;
  margin-top: 16px;
}

.image-preview-item {
  position: relative;
  border-radius: 8px;
  overflow: hidden;
}

.image-preview-item img {
  width: 100%;
  height: 100px;
  object-fit: cover;
}

.image-preview-remove {
  position: absolute;
  top: 4px;
  right: 4px;
  background: rgba(239, 68, 68, 0.9);
  color: white;
  border: none;
  border-radius: 50%;
  width: 24px;
  height: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.image-preview-item:hover .image-preview-remove {
  opacity: 1;
}

/* Search and Filter Components */
.search-box {
  background: white;
  border-radius: 12px;
  padding: 20px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
  margin-bottom: 24px;
}

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

.filter-label {
  display: block;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 8px;
  font-size: 0.875rem;
}

/* Stats Components */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 16px;
  margin-bottom: 24px;
}

.stat-card {
  background: white;
  padding: 20px;
  border-radius: 12px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
  text-align: center;
}

.stat-value {
  font-size: 2rem;
  font-weight: 800;
  color: var(--primary);
  margin-bottom: 4px;
}

.stat-label {
  color: var(--text-light);
  font-size: 0.875rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

/* Booking Status Components */
.status-badge {
  padding: 4px 12px;
  border-radius: 20px;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
}

.status-pending {
  background: #fef3c7;
  color: #92400e;
}

.status-approved {
  background: #d1fae5;
  color: #065f46;
}

.status-paid {
  background: #dbeafe;
  color: #1e40af;
}

.status-completed {
  background: #f3e8ff;
  color: #6b21a8;
}

.status-cancelled {
  background: #fee2e2;
  color: #991b1b;
}

/* Review Components */
.rating-stars {
  display: flex;
  gap: 2px;
  margin-bottom: 8px;
}

.rating-star {
  color: #fbbf24;
  font-size: 1.25rem;
}

.rating-star.empty {
  color: #d1d5db;
}

.review-card {
  background: white;
  padding: 20px;
  border-radius: 12px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
  margin-bottom: 16px;
}

.review-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 12px;
}

.reviewer-name {
  font-weight: 600;
  color: var(--text);
}

.review-date {
  color: var(--text-light);
  font-size: 0.875rem;
}

/* Utility Classes */
.text-gradient {
  background: linear-gradient(135deg, var(--primary), var(--accent));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.shadow-soft {
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
}

.shadow-medium {
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.12);
}

.shadow-strong {
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.15);
}

.border-gradient {
  border: 2px solid;
  border-image: linear-gradient(135deg, var(--primary), var(--accent)) 1;
}

/* Responsive Design */
@media (max-width: 768px) {
  .modal-content {
    margin: 20px;
    padding: 16px;
  }
  
  .car-card {
    margin-bottom: 16px;
  }
  
  .message-bubble {
    max-width: 85%;
  }
  
  .stats-grid {
    grid-template-columns: 1fr;
  }
  
  .nav-tabs {
    flex-wrap: wrap;
  }
  
  .nav-tab {
    flex: 1;
    min-width: 120px;
    text-align: center;
  }
}

/* Add any other base/utility styles that aren't component-specific */

/* Notification Components */
.notification {
  background: white;
  border-radius: 12px;
  padding: 16px 24px;
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.12);
  display: flex;
  align-items: center;
  gap: 16px;
  min-width: 320px;
  margin-top: 16px;
  animation: slideInUp 0.5s ease-out;
  border-left: 4px solid;
}

.notification.success {
  border-color: var(--success);
}

.notification.error {
  border-color: var(--danger);
}

.notification-icon {
  font-size: 24px;
}

.notification.success .notification-icon {
  color: var(--success);
}

.notification.error .notification-icon {
  color: var(--danger);
}

.notification-content p {
  margin: 0;
  font-weight: 600;
  color: var(--text);
}

.notification-content span {
  font-size: 0.875rem;
  color: var(--text-light);
}

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