/* ═══════════════════════════════════════════════════════════════════════════
   RESET & VARIABLES
   ═══════════════════════════════════════════════════════════════════════════ */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

:root {
  --primary: #0255A3;
  --primary-dark: #024482;
  --primary-light: #3387CF;
  --primary-50: #E6F0F9;
  --primary-100: #CCE1F3;

  --secondary: #0093CC;
  --secondary-50: #E6F6FB;

  --text: #1A1A2E;
  --text-secondary: #4A5568;
  --text-muted: #718096;
  --text-inverse: #FFFFFF;

  --surface: #FFFFFF;
  --surface-muted: #F7FAFC;
  --surface-accent: #E6F4F9;
  --border: #E2E8F0;
  --border-focus: var(--primary);

  --success: #38A169;
  --success-light: #E6F5ED;
  --success-dark: #276E48;

  --error: #E53E3E;
  --error-light: #FEE8E8;

  --warning: #DD6B20;
  --warning-light: #FFFBEB;

  --font: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;

  --shadow-sm: 0 1px 3px rgba(0,0,0,0.08);
  --shadow: 0 4px 12px rgba(2, 85, 163, 0.08);
  --shadow-lg: 0 8px 30px rgba(2, 85, 163, 0.12);
  --shadow-xl: 0 20px 40px rgba(2, 85, 163, 0.15);

  --transition: 200ms ease;
  --transition-slow: 400ms ease;

  --radius: 0.75rem;
  --radius-lg: 1rem;
  --radius-xl: 1.5rem;
}

html {
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
}

body {
  font-family: var(--font);
  font-size: 1.125rem;
  line-height: 1.6;
  color: var(--text);
  background: linear-gradient(135deg, var(--primary) 0%, var(--secondary) 50%, var(--primary-dark) 100%);
  min-height: 100vh;
}

a {
  color: inherit;
  text-decoration: none;
}

/* ═══════════════════════════════════════════════════════════════════════════
   LAYOUT
   ═══════════════════════════════════════════════════════════════════════════ */
.page {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.header {
  padding: 1rem 1.5rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.logo {
  display: flex;
  align-items: center;
}

.logo img {
  height: 36px;
  width: auto;
  filter: brightness(0) invert(1);
}

.header-phone {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  color: white;
  font-weight: 600;
  font-size: 1.125rem;
  padding: 0.625rem 1rem;
  background: rgba(255,255,255,0.15);
  border-radius: 50px;
  transition: all var(--transition);
}

.header-phone:hover {
  background: rgba(255,255,255,0.25);
}

.header-phone svg {
  width: 1.25rem;
  height: 1.25rem;
}

.main {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem 1.5rem 4rem;
}

.booking-container {
  width: 100%;
  max-width: 600px;
}

/* ═══════════════════════════════════════════════════════════════════════════
   BOOKING CARD
   ═══════════════════════════════════════════════════════════════════════════ */
.booking-card {
  background: white;
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-xl);
  overflow: hidden;
  position: relative;
}

.booking-header {
  padding: 2rem 2rem 1.5rem;
  text-align: center;
  border-bottom: 1px solid var(--border);
  background: var(--surface-muted);
}

.booking-header h1 {
  font-size: 1.75rem;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 0.5rem;
}

.booking-header p {
  color: var(--text-secondary);
  font-size: 1.0625rem;
}

/* Progress Steps */
.progress-container {
  padding: 1.5rem 2rem;
  background: white;
  border-bottom: 1px solid var(--border);
}

.progress-steps {
  display: flex;
  justify-content: space-between;
  position: relative;
}

.progress-steps::before {
  content: '';
  position: absolute;
  top: 20px;
  left: 40px;
  right: 40px;
  height: 3px;
  background: var(--border);
  z-index: 0;
}

.progress-line {
  position: absolute;
  top: 20px;
  left: 40px;
  height: 3px;
  background: linear-gradient(90deg, var(--primary), var(--secondary));
  z-index: 1;
  transition: width var(--transition-slow);
  border-radius: 2px;
}

.progress-step {
  display: flex;
  flex-direction: column;
  align-items: center;
  position: relative;
  z-index: 2;
}

.step-circle {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 600;
  font-size: 1rem;
  color: var(--text-muted);
  transition: all var(--transition);
  border: 3px solid white;
  box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.step-circle svg {
  width: 20px;
  height: 20px;
  display: none;
}

.progress-step.active .step-circle {
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  color: white;
  transform: scale(1.1);
  box-shadow: 0 4px 15px rgba(2, 85, 163, 0.4);
}

.progress-step.completed .step-circle {
  background: var(--success);
  color: white;
}

.progress-step.completed .step-circle span {
  display: none;
}

.progress-step.completed .step-circle svg {
  display: block;
}

.step-label {
  margin-top: 0.5rem;
  font-size: 0.8125rem;
  font-weight: 500;
  color: var(--text-muted);
  transition: color var(--transition);
}

.progress-step.active .step-label,
.progress-step.completed .step-label {
  color: var(--text);
}

/* Form Container */
.form-container {
  padding: 2rem;
}

/* Form Steps */
.form-step {
  display: none;
  animation: fadeIn 0.3s ease;
}

.form-step.active {
  display: block;
}

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

/* Form Groups */
.form-group {
  margin-bottom: 1.5rem;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}

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

.form-label .required {
  color: var(--error);
  margin-left: 0.25rem;
}

.form-input {
  width: 100%;
  padding: 1rem 1.25rem;
  font-family: var(--font);
  font-size: 1.125rem;
  color: var(--text);
  background: var(--surface);
  border: 2px solid var(--border);
  border-radius: var(--radius);
  transition: all var(--transition);
  -webkit-appearance: none;
}

.form-input:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 4px var(--primary-50);
}

.form-input::placeholder {
  color: var(--text-muted);
}

.form-input:disabled {
  background: var(--surface-muted);
  cursor: not-allowed;
}

.form-input.error {
  border-color: var(--error);
  background: var(--error-light);
}

.form-input.error:focus {
  box-shadow: 0 0 0 4px rgba(229, 62, 62, 0.15);
}

/* Select */
.form-select {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='%234A5568' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 1rem center;
  background-size: 1.25rem;
  padding-right: 3rem;
  cursor: pointer;
}

/* Textarea */
.form-textarea {
  min-height: 100px;
  resize: vertical;
}

/* Radio & Checkbox Cards */
.option-cards {
  display: grid;
  gap: 0.75rem;
}

.option-cards.cols-2 {
  grid-template-columns: 1fr 1fr;
}

.option-card {
  position: relative;
}

.option-card input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.option-card label {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1.25rem;
  background: var(--surface);
  border: 2px solid var(--border);
  border-radius: var(--radius);
  cursor: pointer;
  height: 100%;
  transition: all var(--transition);
}

.option-card label:hover {
  border-color: var(--primary-light);
  background: var(--primary-50);
}

.option-card input:checked + label {
  border-color: var(--primary);
  background: var(--primary-50);
  box-shadow: 0 0 0 4px var(--primary-100);
}

.option-card input:focus + label {
  box-shadow: 0 0 0 4px var(--primary-100);
}

.option-icon {
  width: 48px;
  height: 48px;
  background: linear-gradient(135deg, var(--primary-50), var(--secondary-50));
  border-radius: 0.625rem;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--primary);
  flex-shrink: 0;
}

.option-card input:checked + label .option-icon {
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  color: white;
}

.option-icon svg {
  width: 24px;
  height: 24px;
}

.option-content h4 {
  font-size: 1.0625rem;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 0.125rem;
}

.option-content p {
  font-size: 0.875rem;
  color: var(--text-secondary);
  margin: 0;
}

/* Date/Time Inputs */
.datetime-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}

.form-input[type="date"],
.form-input[type="time"] {
  cursor: pointer;
}

/* Helper Text */
.form-helper {
  margin-top: 0.5rem;
  font-size: 0.875rem;
  color: var(--text-muted);
  display: flex;
  align-items: flex-start;
  gap: 0.375rem;
}

.form-helper svg {
  width: 1rem;
  height: 1rem;
  flex-shrink: 0;
  margin-top: 0.125rem;
}

.form-error {
  margin-top: 0.5rem;
  font-size: 0.875rem;
  color: var(--error);
  display: flex;
  align-items: center;
  gap: 0.375rem;
}

.form-error svg {
  width: 1rem;
  height: 1rem;
  flex-shrink: 0;
}

/* Section Title within form */
.form-section-title {
  font-size: 1.125rem;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 1rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.form-section-title svg {
  width: 1.25rem;
  height: 1.25rem;
  color: var(--primary);
}

/* Divider */
.form-divider {
  height: 1px;
  background: var(--border);
  margin: 1.5rem 0;
}

/* Buttons */
.form-actions {
  display: flex;
  gap: 1rem;
  margin-top: 2rem;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.625rem;
  padding: 1rem 1.75rem;
  font-family: var(--font);
  font-size: 1.125rem;
  font-weight: 600;
  border-radius: var(--radius);
  border: none;
  cursor: pointer;
  transition: all var(--transition);
  text-decoration: none;
  flex: 1;
}

.btn svg {
  width: 1.25rem;
  height: 1.25rem;
}

.btn-primary {
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  color: white;
  box-shadow: 0 4px 15px rgba(2, 85, 163, 0.3);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(2, 85, 163, 0.4);
}

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

.btn-secondary {
  background: var(--surface-muted);
  color: var(--text-secondary);
  border: 2px solid var(--border);
}

.btn-secondary:hover {
  background: var(--border);
  color: var(--text);
}

.btn-lg {
  padding: 1.25rem 2rem;
  font-size: 1.25rem;
}

.btn:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  transform: none !important;
}

/* Trust Indicators */
.trust-indicators {
  display: flex;
  justify-content: center;
  gap: 1.5rem;
  padding: 1.5rem 2rem;
  background: var(--surface-muted);
  border-top: 1px solid var(--border);
}

.trust-item {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.875rem;
  color: var(--text-secondary);
}

.trust-item svg {
  width: 1.125rem;
  height: 1.125rem;
  color: var(--success);
}

/* ═══════════════════════════════════════════════════════════════════════════
   SUMMARY STEP
   ═══════════════════════════════════════════════════════════════════════════ */
.summary-section {
  background: var(--surface-muted);
  border-radius: var(--radius);
  padding: 1.5rem;
  margin-bottom: 1.5rem;
}

.summary-section h3 {
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 1rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.summary-section h3 svg {
  width: 1rem;
  height: 1rem;
}

.summary-row {
  display: flex;
  justify-content: space-between;
  padding: 0.625rem 0;
  border-bottom: 1px solid var(--border);
}

.summary-row:last-child {
  border-bottom: none;
}

.summary-label {
  color: var(--text-secondary);
  font-size: 1rem;
}

.summary-value {
  font-weight: 600;
  color: var(--text);
  font-size: 1rem;
  text-align: right;
}

.edit-link {
  color: var(--primary);
  font-size: 0.875rem;
  font-weight: 500;
  cursor: pointer;
  margin-left: 0.5rem;
}

.edit-link:hover {
  text-decoration: underline;
}

/* Cost Info */
.cost-info {
  background: var(--success-light);
  border: 2px solid var(--success);
  border-radius: var(--radius);
  padding: 1.25rem;
  margin-bottom: 1.5rem;
}

.cost-info-header {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 0.5rem;
}

.cost-info-header svg {
  width: 1.5rem;
  height: 1.5rem;
  color: var(--success);
}

.cost-info-header h4 {
  font-size: 1.125rem;
  font-weight: 600;
  color: var(--success-dark);
}

.cost-info p {
  color: var(--success-dark);
  font-size: 0.9375rem;
  margin: 0;
}

/* Checkbox Agreement */
.checkbox-group {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  margin-bottom: 1.5rem;
}

.checkbox-group input[type="checkbox"] {
  width: 24px;
  height: 24px;
  margin-top: 0.125rem;
  cursor: pointer;
  accent-color: var(--primary);
}

.checkbox-group label {
  font-size: 0.9375rem;
  color: var(--text-secondary);
  cursor: pointer;
  line-height: 1.5;
}

.checkbox-group label a {
  color: var(--primary);
  text-decoration: underline;
}

/* ═══════════════════════════════════════════════════════════════════════════
   SUCCESS STATE
   ═══════════════════════════════════════════════════════════════════════════ */
.success-state {
  text-align: center;
  padding: 3rem 2rem;
}

.success-icon {
  width: 100px;
  height: 100px;
  background: linear-gradient(135deg, var(--success), #68D391);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 2rem;
  animation: scaleIn 0.5s ease;
}

.success-icon svg {
  width: 50px;
  height: 50px;
  color: white;
}

@keyframes scaleIn {
  0% { transform: scale(0); opacity: 0; }
  50% { transform: scale(1.1); }
  100% { transform: scale(1); opacity: 1; }
}

.success-state h2 {
  font-size: 1.75rem;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 0.75rem;
}

.success-state p {
  font-size: 1.0625rem;
  color: var(--text-secondary);
  margin-bottom: 0.5rem;
}

.success-state .booking-number {
  display: inline-block;
  background: var(--primary-50);
  color: var(--primary);
  font-weight: 700;
  font-size: 1.25rem;
  padding: 0.75rem 1.5rem;
  border-radius: var(--radius);
  margin: 1.5rem 0;
}

.success-details {
  background: var(--surface-muted);
  border-radius: var(--radius);
  padding: 1.5rem;
  text-align: left;
  margin: 2rem 0;
}

.success-details h4 {
  font-size: 1rem;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 1rem;
}

.success-detail-row {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.75rem 0;
  font-size: 0.9375rem;
  border-bottom: 1px solid var(--border);
}

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

.success-detail-row span:first-child {
  color: var(--text-muted);
  flex-shrink: 0;
  min-width: 80px;
}

.success-detail-row span:last-child {
  font-weight: 500;
  color: var(--text);
  text-align: right;
  word-break: break-word;
}

.success-actions {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  margin-top: 2rem;
}

.success-actions .btn {
  width: 100%;
}

/* ═══════════════════════════════════════════════════════════════════════════
   PHONE CTA SIDEBAR
   ═══════════════════════════════════════════════════════════════════════════ */
.phone-cta {
  background: rgba(255,255,255,0.1);
  backdrop-filter: blur(10px);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  margin-top: 1.5rem;
  text-align: center;
  border: 1px solid rgba(255,255,255,0.2);
}

.phone-cta p {
  color: rgba(255,255,255,0.9);
  font-size: 1rem;
  margin-bottom: 1rem;
}

.phone-cta a {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.625rem;
  background: white;
  color: var(--primary);
  padding: 1rem 1.5rem;
  border-radius: var(--radius);
  font-weight: 700;
  font-size: 1.25rem;
  transition: all var(--transition);
  box-shadow: var(--shadow-lg);
}

.phone-cta a:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-xl);
}

.phone-cta a svg {
  width: 1.5rem;
  height: 1.5rem;
}

.phone-cta .available {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.375rem;
  margin-top: 0.75rem;
  font-size: 0.875rem;
  color: rgba(255,255,255,0.8);
}

.phone-cta .available::before {
  content: '';
  width: 8px;
  height: 8px;
  background: #68D391;
  border-radius: 50%;
  animation: pulse 2s infinite;
}

@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.5; }
}

/* ═══════════════════════════════════════════════════════════════════════════
   ADDRESS AUTOCOMPLETE
   ═══════════════════════════════════════════════════════════════════════════ */
.autocomplete-wrapper {
  position: relative;
  width: 100%;
}

.autocomplete-dropdown {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  background: white;
  border: 1px solid var(--border);
  border-top: none;
  border-radius: 0 0 0.625rem 0.625rem;
  box-shadow: 0 8px 24px rgba(0,0,0,0.12);
  z-index: 100;
  display: none;
  max-height: 280px;
  overflow-y: auto;
}

.autocomplete-item {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  padding: 0.875rem 1rem;
  cursor: pointer;
  transition: background var(--transition);
  border-bottom: 1px solid var(--border);
}

.autocomplete-item:last-child {
  border-bottom: none;
}

.autocomplete-item:hover {
  background: var(--primary-50);
}

.autocomplete-item svg {
  width: 1.25rem;
  height: 1.25rem;
  flex-shrink: 0;
  color: var(--primary);
  margin-top: 0.125rem;
}

.autocomplete-item span {
  font-size: 0.9375rem;
  line-height: 1.4;
  color: var(--text);
}

/* ═══════════════════════════════════════════════════════════════════════════
   RESPONSIVE
   ═══════════════════════════════════════════════════════════════════════════ */
@media (max-width: 640px) {
  .header {
    padding: 1rem;
  }

  .header-phone {
    display: none;
  }

  .main {
    padding: 1rem 1rem 2rem;
  }

  .booking-header {
    padding: 1.5rem 1.25rem 1.25rem;
  }

  .booking-header h1 {
    font-size: 1.5rem;
  }

  .progress-container {
    padding: 1.25rem 1rem;
  }

  .step-label {
    font-size: 0.6875rem;
  }

  .step-circle {
    width: 36px;
    height: 36px;
    font-size: 0.875rem;
  }

  .progress-steps::before {
    top: 18px;
    left: 30px;
    right: 30px;
  }

  .progress-line {
    top: 18px;
    left: 30px;
  }

  .form-container {
    padding: 1.5rem 1.25rem;
  }

  .form-row,
  .datetime-row {
    grid-template-columns: 1fr;
  }

  .option-cards.cols-2 {
    grid-template-columns: 1fr;
  }

  .form-actions {
    flex-direction: column-reverse;
  }

  .trust-indicators {
    flex-direction: column;
    align-items: center;
    gap: 0.75rem;
    padding: 1.25rem;
  }

  .phone-cta {
    margin-top: 1rem;
  }

  .success-state {
    padding: 2rem 1.25rem;
  }

  .success-icon {
    width: 80px;
    height: 80px;
  }

  .success-icon svg {
    width: 40px;
    height: 40px;
  }
}
