/* RESET + BASE (Escala de 8px) */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: 'Inter', sans-serif;
  min-height: 100vh;
  background: #0a0f0c;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 10px;
  position: relative;
}

/* Background Slideshow */
.bg-slideshow {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
  z-index: 0;
}

.bg-slide {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-size: cover;
  background-position: center;
  opacity: 0;
  transition: opacity 1.2s ease-in-out;
  z-index: 1;
}

.bg-slide.active {
  opacity: 1;
  z-index: 2;
}

.overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(135deg, rgba(0,0,0,0.7) 0%, rgba(0,0,0,0.5) 100%);
  z-index: 3;
}

/* Contenedor principal */
.form-container {
  position: relative;
  z-index: 10;
  max-width: 580px;
  width: 100%;
  background: rgba(255, 255, 255, 0.98);
  border-radius: 28px;
  padding: 28px 32px;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
  transition: all 0.3s ease;
}

/* Header */
.form-header {
  text-align: center;
  margin-bottom: 28px;
  padding-bottom: 16px;
  border-bottom: 2px solid #eef2ee;
}

.form-header h1 {
  font-size: 1.8rem;
  font-weight: 700;
  color: #2c5e2d;
  letter-spacing: -0.5px;
  margin-bottom: 6px;
}

.form-header p {
  font-size: 0.85rem;
  color: #6f7c6b;
  font-weight: 400;
}

/* Indicador de pasos - VERSIÓN COMPACTA SIN WRAP */
.steps-indicator {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 32px;
  gap: 4px;
  overflow-x: auto;
  overflow-y: visible;
  scrollbar-width: thin;
  -webkit-overflow-scrolling: touch;
  padding-bottom: 8px;
}

/* Ocultar scrollbar en navegadores WebKit (opcional) */
.steps-indicator::-webkit-scrollbar {
  height: 3px;
}

.steps-indicator::-webkit-scrollbar-track {
  background: #e8efe6;
  border-radius: 10px;
}

.steps-indicator::-webkit-scrollbar-thumb {
  background: #4F7942;
  border-radius: 10px;
}

.step-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
  cursor: pointer;
}

.step-circle {
  width: 36px;
  height: 36px;
  background-color: #f0f4ef;
  border-radius: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.9rem;
  color: #5a7c55;
  transition: all 0.3s;
}

.step-item.active .step-circle {
  background-color: #4F7942;
  color: white;
  box-shadow: 0 4px 12px rgba(79, 121, 66, 0.3);
  transform: scale(1.05);
}

.step-label {
  font-size: 0.65rem;
  font-weight: 600;
  color: #4a6741;
  text-transform: uppercase;
  letter-spacing: 0.3px;
  white-space: nowrap;
}

.step-line {
  height: 2px;
  background: #e0e8df;
  flex-shrink: 0;
  width: 24px;
  min-width: 16px;
}

/* Form steps */
.form-step {
  display: none;
  animation: fadeInUp 0.35s ease;
}

.form-step.active {
  display: block;
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(12px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.step-header {
  margin-bottom: 24px;
}

.step-header h2 {
  font-size: 1.4rem;
  font-weight: 700;
  color: #1f3b2c;
  margin-bottom: 6px;
  letter-spacing: -0.3px;
}

.step-header p {
  font-size: 0.8rem;
  color: #7a8a76;
}

/* Inputs */
.input-group {
  margin-bottom: 5px;
}

.input-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-bottom: 8px;
}

label {
  display: block;
  font-weight: 600;
  margin-bottom: 8px;
  font-size: 0.75rem;
  color: #3a5536;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

input {
  width: 100%;
  padding: 10px 14px;
  font-family: 'Inter', sans-serif;
  font-size: 0.9rem;
  border: 1.5px solid #e2e8e2;
  border-radius: 14px;
  background: #fff;
  transition: all 0.2s;
  outline: none;
}

input:focus {
  border-color: #4F7942;
  box-shadow: 0 0 0 3px rgba(79, 121, 66, 0.1);
}

/* Flatpickr Input */
.flatpickr-datetime {
  cursor: pointer;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='20' height='20' viewBox='0 0 24 24' fill='none' stroke='%234F7942' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='3' y='4' width='18' height='18' rx='2' ry='2'%3E%3C/rect%3E%3Cline x1='16' y1='2' x2='16' y2='6'%3E%3C/line%3E%3Cline x1='8' y1='2' x2='8' y2='6'%3E%3C/line%3E%3Cline x1='3' y1='10' x2='21' y2='10'%3E%3C/line%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  background-size: 18px;
  padding-right: 40px;
}

/* Flatpickr Calendar Custom Styles */
.flatpickr-calendar {
  background: #ffffff;
  border-radius: 20px;
  border: none;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
  font-family: 'Inter', sans-serif;
  padding: 12px;
  width: 320px;
}

.flatpickr-months {
  margin-bottom: 12px;
}

.flatpickr-month {
  height: 48px;
}

.flatpickr-current-month {
  font-size: 1rem;
  font-weight: 600;
  color: #2c5e2d;
  padding-top: 8px;
}

.flatpickr-prev-month,
.flatpickr-next-month {
  fill: #4F7942;
  padding: 8px;
}

.flatpickr-prev-month:hover,
.flatpickr-next-month:hover {
  background: #ecf6e8;
  border-radius: 12px;
}

.flatpickr-weekdays {
  margin-bottom: 8px;
}

.flatpickr-weekday {
  font-size: 0.75rem;
  font-weight: 600;
  color: #4a6741;
  text-transform: uppercase;
}

.flatpickr-day {
  color: #2c3e2b;
  font-weight: 500;
  border-radius: 12px;
  height: 36px;
  line-height: 36px;
  margin: 2px;
  transition: all 0.2s;
}

.flatpickr-day:hover {
  background: #ecf6e8;
  border-color: transparent;
}

.flatpickr-day.selected,
.flatpickr-day.startRange,
.flatpickr-day.endRange {
  background: #4F7942;
  border-color: #4F7942;
  color: white;
  font-weight: 600;
}

.flatpickr-day.selected:hover {
  background: #3d6133;
}

.flatpickr-day.today {
  border-color: #4F7942;
  color: #4F7942;
  font-weight: 700;
}

.flatpickr-day.today.selected {
  border-color: #4F7942;
  color: white;
}

.flatpickr-day.disabled,
.flatpickr-day.prevMonthDay,
.flatpickr-day.nextMonthDay {
  color: #c0ccc0;
}

.flatpickr-time {
  border-top: 1px solid #e8efe6;
  border-radius: 0 0 16px 16px;
  max-height: 50px;
}

.flatpickr-time input {
  font-family: 'Inter', sans-serif;
  color: #2c3e2b;
  font-weight: 500;
}

.flatpickr-time .numInputWrapper:hover {
  background: #ecf6e8;
}

/* Error messages */
.error-message {
  font-size: 0.7rem;
  color: #dc3545;
  margin-top: 6px;
  min-height: 18px;
}

/* Botones */
.form-navigation {
  display: flex;
  justify-content: space-between;
  margin-top: 28px;
  gap: 16px;
}

button {
  font-family: 'Inter', sans-serif;
  font-weight: 600;
  font-size: 0.85rem;
  padding: 10px 24px;
  border-radius: 40px;
  border: none;
  cursor: pointer;
  transition: all 0.2s;
  background: #f2f6f0;
  color: #2d4a2c;
}

.btn-next, .btn-submit {
  background-color: #4F7942;
  color: white;
  box-shadow: 0 2px 6px rgba(0,0,0,0.08);
}

.btn-next:hover, .btn-submit:hover {
  background-color: #3d6133;
  transform: translateY(-2px);
  box-shadow: 0 6px 14px rgba(79, 121, 66, 0.3);
}

.btn-prev {
  background: #f0f4ef;
  color: #3a6135;
}

.btn-prev:hover {
  background: #e4ece1;
  transform: translateX(-2px);
}

/* Vehicle Cards */
.vehicle-selector {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-bottom: 24px;
}

.vehicle-card {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 18px;
  border: 2px solid #edf3ea;
  border-radius: 20px;
  background: #ffffff;
  cursor: pointer;
  transition: all 0.25s;
}

.vehicle-card:hover {
  border-color: #9bbf8f;
  background: #fafef7;
  transform: translateX(4px);
}

.vehicle-card input[type="radio"] {
  width: 18px;
  height: 18px;
  accent-color: #4F7942;
  margin: 0;
  flex-shrink: 0;
}

.vehicle-icon {
  font-size: 1.8rem;
  flex-shrink: 0;
}

.vehicle-info {
  flex: 1;
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 6px;
}

.vehicle-info strong {
  font-size: 1rem;
  color: #1f3b2c;
  min-width: 90px;
}

.vehicle-info span {
  font-weight: 700;
  color: #4F7942;
  background: #eef5ea;
  padding: 4px 12px;
  border-radius: 30px;
  font-size: 0.8rem;
}

.quote-badge {
  background: #fef3e2 !important;
  color: #c27d2e !important;
}

.vehicle-info small {
  width: 100%;
  color: #8b9a87;
  font-size: 0.7rem;
}

/* Precio sugerido */
.price-suggestion {
  background: linear-gradient(135deg, #ecf6e8 0%, #e2efe0 100%);
  padding: 14px 20px;
  border-radius: 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin: 20px 0 8px;
}

.price-label {
  font-size: 0.85rem;
  font-weight: 600;
  color: #2c5530;
}

.price-value {
  font-size: 1.5rem;
  font-weight: 800;
  color: #2a6b2f;
}

/* ============================================ */
/* MODAL PROFESIONAL - TAMAÑO OPTIMIZADO */
/* ============================================ */

.modal {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.8);
  z-index: 1000;
  align-items: center;
  justify-content: center;
  backdrop-filter: blur(8px);
}

.professional-modal {
  max-width: 480px;
  width: 90%;
  max-height: 85vh;
  overflow-y: auto;
  padding: 0;
  border-radius: 28px;
  background: #ffffff;
  position: relative;
  animation: slideUp 0.3s ease;
}

/* Scrollbar personalizada para el modal */
.professional-modal::-webkit-scrollbar {
  width: 6px;
}

.professional-modal::-webkit-scrollbar-track {
  background: #e8efe6;
  border-radius: 10px;
}

.professional-modal::-webkit-scrollbar-thumb {
  background: #4F7942;
  border-radius: 10px;
}

@keyframes slideUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Modal Header - Compacto */
.modal-header {
  background: linear-gradient(135deg, #f8fbf7 0%, #ffffff 100%);
  padding: 20px 24px 16px;
  text-align: center;
  border-bottom: 1px solid #e8efe6;
  position: sticky;
  top: 0;
  background: white;
  z-index: 5;
}

.success-icon {
  margin-bottom: 12px;
  display: inline-block;
}

.success-icon svg {
  width: 48px;
  height: 48px;
}

.modal-header h3 {
  font-size: 1.4rem;
  font-weight: 700;
  color: #2c5e2d;
  margin-bottom: 6px;
}

.modal-subtitle {
  font-size: 0.8rem;
  color: #6f7c6b;
  font-weight: 400;
}

/* Modal Body - Compacto */
.modal-body {
  padding: 20px 24px;
  background: #ffffff;
}

.info-section {
  background: #fafdf9;
  border-radius: 16px;
  padding: 14px 16px;
  margin-bottom: 16px;
  border: 1px solid #e8efe6;
}

.info-row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  padding: 8px 0;
  font-size: 0.85rem;
}

.info-label {
  font-weight: 600;
  color: #4a6741;
  min-width: 85px;
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.3px;
}

.info-value {
  color: #2c3e2b;
  font-weight: 500;
  text-align: right;
  flex: 1;
  word-break: break-word;
  font-size: 0.85rem;
}

.divider {
  height: 1px;
  background: #e0e8df;
  margin: 10px 0;
}

.highlight {
  background: #ecf6e8;
  margin: 0 -16px -14px -16px;
  padding: 10px 16px;
  border-radius: 0 0 16px 16px;
}

.price-highlight {
  font-size: 1.2rem;
  font-weight: 800;
  color: #4F7942;
}

.confirmation-message {
  background: #f0f6ef;
  padding: 12px 14px;
  border-radius: 14px;
  margin-top: 8px;
}

.confirmation-message p {
  font-size: 0.75rem;
  color: #4a6741;
  margin-bottom: 6px;
  line-height: 1.4;
}

.confirmation-message p:last-child {
  margin-bottom: 0;
}

/* Modal Footer - Compacto */
.modal-footer {
  padding: 16px 24px 20px;
  text-align: center;
  border-top: 1px solid #e8efe6;
  background: #fafdf9;
  position: sticky;
  bottom: 0;
  background: white;
}

.btn-new-reservation {
  background: #4F7942;
  color: white;
  padding: 10px 24px;
  border-radius: 40px;
  font-weight: 600;
  font-size: 0.85rem;
  border: none;
  cursor: pointer;
  transition: all 0.3s;
  width: 100%;
}

.btn-new-reservation:hover {
  background: #3d6133;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(79, 121, 66, 0.3);
}

.modal-close {
  position: absolute;
  top: 16px;
  right: 20px;
  font-size: 1.6rem;
  cursor: pointer;
  color: #9aae95;
  background: none;
  padding: 0;
  width: auto;
  transition: all 0.2s;
}

.modal-close:hover {
  color: #4a6741;
  transform: none;
  box-shadow: none;
}

/* Responsive */
@media (max-width: 560px) {
  .form-container {
    padding: 15px;
    max-width: 100%;
  }
  
  /* Pasos aún más compactos en móviles */
  .steps-indicator {
    gap: 2px;
    margin-bottom: 24px;
  }
  
  .step-circle {
    width: 32px;
    height: 32px;
    font-size: 0.8rem;
  }
  
  .step-label {
    font-size: 0.55rem;
  }
  
  .step-line {
    width: 16px;
    min-width: 12px;
  }
  
  .input-row {
    grid-template-columns: 1fr;
    gap: 0;
  }
  
  .vehicle-info {
    flex-direction: column;
    align-items: flex-start;
  }
  
  .modal-body {
    padding: 16px 20px;
  }
  
  .info-row {
    flex-direction: column;
    align-items: flex-start;
    gap: 4px;
  }
  
  .info-value {
    text-align: left;
  }
  
  .modal-header h3 {
    font-size: 1.3rem;
  }
  
  .professional-modal {
    width: 95%;
    max-height: 90vh;
  }
  
  .flatpickr-calendar {
    width: 280px;
  }
}

/* Para pantallas muy pequeñas (menos de 400px) */
@media (max-width: 400px) {
  .step-circle {
    width: 28px;
    height: 28px;
    font-size: 0.7rem;
  }
  
  .step-label {
    font-size: 0.5rem;
  }
  
  .step-line {
    width: 12px;
    min-width: 8px;
  }
  
  .steps-indicator {
    gap: 1px;
  }
}