/* ==========================================================================
   YD TAXI - Premium Chennai Intercity Cabs
   Design System & Modern Stylesheet
   ========================================================================== */

/* --- Design Tokens --- */
:root {
  color-scheme: light;

  /* Brand Palette */
  --brand-yellow: #f5b400;
  --brand-yellow-hover: #e5a700;
  --brand-yellow-light: #fff9ea;
  --brand-gold: #b45309;
  --whatsapp: #25d366;
  --whatsapp-hover: #20bd5a;
  --whatsapp-dark: #128c7e;

  /* Neutrals & Text */
  --ink-950: #0f172a;
  --ink-900: #111827;
  --ink-800: #1f2937;
  --ink-700: #374151;
  --ink-500: #6b7280;
  --ink-400: #9ca3af;
  --ink-200: #e5e7eb;
  --ink-100: #f3f4f6;

  /* Semantic UI Colors */
  --text-primary: #111827;
  --text-secondary: #4b5563;
  --text-muted: #6b7280;
  --text-inverted: #ffffff;

  --bg-page: #faf7f0;
  --bg-alt: #ffffff;
  --bg-surface: #ffffff;
  --bg-surface-elevated: #ffffff;

  --border: #e5e7eb;
  --border-subtle: #f3f4f6;
  --border-strong: #d1d5db;
  --border-focus: #f5b400;

  --status-success: #15803d;
  --status-success-bg: #f0fdf4;
  --status-danger: #dc2626;
  --status-danger-bg: #fef2f2;

  /* Typography Scale */
  --font-body: "Manrope", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --font-heading: "Sora", "Manrope", sans-serif;

  --text-xs: 0.875rem;    /* 14px - strictly never below 14px */
  --text-sm: 0.9375rem;   /* 15px */
  --text-base: 1rem;      /* 16px */
  --text-lg: 1.125rem;    /* 18px */
  --text-xl: 1.25rem;     /* 20px */
  --text-2xl: 1.5rem;     /* 24px */
  --text-h2: clamp(1.5rem, 2.5vw, 2.25rem);
  --text-h1: clamp(2rem, 4vw, 3.25rem);

  /* Spacing Scale (4, 8, 12, 16, 24, 32, 48, 64, 96) */
  --space-1: 4px;
  --space-2: 8px;
  --space-3: 12px;
  --space-4: 16px;
  --space-5: 24px;
  --space-6: 32px;
  --space-7: 48px;
  --space-8: 64px;
  --space-9: 96px;

  /* Radius */
  --radius-sm: 8px;
  --radius-card: 12px;
  --radius-pill: 9999px;

  /* Shadows (Two distinct levels) */
  --shadow-card: 0 1px 3px rgba(17, 24, 39, 0.05), 0 1px 2px rgba(17, 24, 39, 0.03);
  --shadow-elevated: 0 10px 25px -3px rgba(17, 24, 39, 0.08), 0 4px 6px -4px rgba(17, 24, 39, 0.03);

  /* Dimensions */
  --max-width: 1200px;
  --header-height: 68px;

  /* Hero Background Image */
  /* TODO: Replace placeholder URL with 'assets/hero-bg.webp' once local asset is ready */
  --hero-bg-image: url("https://images.unsplash.com/photo-1449965408869-eaa3f722e40d?auto=format&fit=crop&w=1920&q=70");
}

/* Mobile 800px hero background variant */
@media (max-width: 767px) {
  :root {
    /* TODO: Switch to url("assets/hero-bg-mobile.webp") when 800px mobile asset is added */
    --hero-bg-image: url("https://images.unsplash.com/photo-1449965408869-eaa3f722e40d?auto=format&fit=crop&w=1920&q=70");
  }
}

/* --- Base & Reset --- */
*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-height) + 16px);
  overflow-x: clip;
  scrollbar-width: none; /* Firefox */
  -ms-overflow-style: none; /* IE and Edge */
}

/* Hide default side scrollbar across WebKit/Blink browsers */
html::-webkit-scrollbar,
body::-webkit-scrollbar {
  display: none;
  width: 0;
  height: 0;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: var(--font-body);
  font-size: var(--text-base);
  line-height: 1.6;
  color: var(--text-primary);
  background-color: var(--bg-page);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: clip;
  scrollbar-width: none;
  -ms-overflow-style: none;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: inherit;
  text-decoration: none;
  transition: color 0.2s ease;
}

button,
input,
select,
textarea {
  font: inherit;
}

button {
  cursor: pointer;
  border: none;
  background: none;
}

/* Screen reader only utility */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* Container */
.container {
  width: 100%;
  max-width: var(--max-width);
  margin-inline: auto;
  padding-inline: 20px;
}

@media (min-width: 768px) {
  .container {
    padding-inline: 32px;
  }
}

/* Sections - Alternating backgrounds & smooth anchor margins */
.section {
  padding-block: var(--space-8);
  scroll-margin-top: var(--header-height);
}

@media (min-width: 1024px) {
  .section {
    padding-block: var(--space-9);
  }
}

.hero-section {
  position: relative;
  background-color: var(--bg-page); /* Solid cream fallback */
  background-image:
    linear-gradient(rgba(250, 247, 240, 0.88), rgba(250, 247, 240, 0.88)),
    var(--hero-bg-image);
  background-size: cover, cover;
  background-position: center center, right center;
  background-repeat: no-repeat, no-repeat;
  background-attachment: scroll, scroll; /* Respects reduced motion, avoids iOS fixed-background glitches */
  padding-top: var(--space-5);
  padding-bottom: var(--space-7);
  overflow-x: clip; /* Prevent horizontal scroll without clipping autocomplete popups */
}

.fleet-section {
  background-color: var(--bg-alt);
  border-block: 1px solid var(--border);
}

.routes-section {
  background-color: var(--bg-page);
}

.why-us-section {
  background-color: var(--bg-alt);
  border-block: 1px solid var(--border);
}

.faq-section {
  background-color: var(--bg-page);
}

.contact-section {
  background-color: var(--bg-alt);
  border-top: 1px solid var(--border);
}

/* --- Section Headings (Standardized & full width rhythm) --- */
.section-heading {
  margin-bottom: var(--space-6);
}

.section-heading.centered {
  text-align: center;
  margin-inline: auto;
  max-width: 720px;
}

.section-kicker,
.hero-kicker {
  display: inline-block;
  margin: 0 0 var(--space-2);
  font-size: var(--text-xs);
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--brand-gold);
}

.section-heading h2 {
  margin: 0 0 var(--space-2);
  font-family: var(--font-heading);
  font-size: var(--text-h2);
  font-weight: 700;
  line-height: 1.2;
  color: var(--ink-950);
  max-width: 44ch;
}

.section-heading.centered h2 {
  max-width: 100%;
}

.section-subtext {
  margin: 0;
  font-size: var(--text-base);
  color: var(--text-secondary);
  line-height: 1.6;
  max-width: 60ch;
}

.section-heading.centered .section-subtext {
  margin-inline: auto;
}

/* --- Buttons --- */
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  min-height: 46px;
  padding: 0 20px;
  border-radius: var(--radius-pill);
  font-size: var(--text-sm);
  font-weight: 700;
  line-height: 1;
  text-align: center;
  white-space: nowrap;
  border: 1px solid transparent;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  user-select: none;
}

.button:focus-visible {
  outline: 2px solid var(--brand-yellow);
  outline-offset: 2px;
}

.button:active {
  transform: scale(0.98);
}

.button-icon {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
  display: inline-block;
  object-fit: contain;
}

.wa-btn-icon {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
  display: inline-block;
  object-fit: contain;
}

.button-primary {
  background-color: var(--brand-yellow);
  color: var(--ink-950);
  box-shadow: 0 2px 8px rgba(245, 180, 0, 0.28);
}

.button-primary:hover {
  background-color: var(--brand-yellow-hover);
  box-shadow: 0 4px 12px rgba(245, 180, 0, 0.35);
  transform: translateY(-1px);
}

.button-secondary {
  background-color: var(--bg-surface);
  color: var(--ink-900);
  border-color: var(--border);
  box-shadow: var(--shadow-card);
}

.button-secondary:hover {
  background-color: var(--ink-100);
  border-color: var(--ink-400);
  transform: translateY(-1px);
}

.button-ghost {
  background-color: transparent;
  color: var(--ink-900);
  border-color: var(--border);
}

.button-ghost:hover {
  background-color: var(--ink-100);
  border-color: var(--ink-400);
}

.button-whatsapp {
  background-color: var(--whatsapp);
  color: #ffffff;
  box-shadow: 0 4px 12px rgba(37, 211, 102, 0.28);
}

.button-whatsapp:hover {
  background-color: var(--whatsapp-hover);
  box-shadow: 0 6px 16px rgba(37, 211, 102, 0.36);
  transform: translateY(-1px);
}

.button-call {
  background-color: var(--ink-950);
  color: #ffffff;
  box-shadow: 0 2px 8px rgba(15, 23, 42, 0.2);
}

.button-call:hover {
  background-color: var(--ink-800);
  transform: translateY(-1px);
}

/* ==========================================================================
   HEADER
   ========================================================================== */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  height: var(--header-height);
  background-color: rgba(255, 255, 255, 0.96);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
  box-shadow: 0 1px 4px rgba(17, 24, 39, 0.04);
}

.header-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 100%;
  max-width: var(--max-width);
  margin-inline: auto;
  padding-inline: 20px;
  gap: var(--space-4);
}

@media (min-width: 768px) {
  .header-container {
    padding-inline: 32px;
  }
}

.brand {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  flex-shrink: 0;
}

.brand-logo {
  width: 40px;
  height: 40px;
  border-radius: 50%;
}

.brand-name {
  font-family: var(--font-heading);
  font-size: 1.25rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--ink-950);
}

/* Desktop Navigation (Exactly 5 links) */
.site-nav {
  display: none;
  align-items: center;
  gap: var(--space-6);
}

.site-nav a {
  font-size: var(--text-sm);
  font-weight: 600;
  color: var(--text-secondary);
  padding: 6px 2px;
  position: relative;
}

.site-nav a:hover {
  color: var(--text-primary);
}

.site-nav a.is-active {
  color: var(--ink-950);
  font-weight: 700;
}

.site-nav a.is-active::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 2px;
  background-color: var(--brand-yellow);
  border-radius: var(--radius-pill);
}

@media (min-width: 960px) {
  .site-nav {
    display: flex;
  }
}

.header-actions {
  display: flex;
  align-items: center;
  gap: var(--space-3);
}

.header-call-btn {
  min-height: 40px;
  padding: 0 16px;
  font-size: var(--text-xs);
  gap: var(--space-2);
}

.header-call-btn .call-icon {
  width: 15px;
  height: 15px;
}

/* Mobile Menu Toggle */
.menu-toggle {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 5px;
  width: 44px;
  height: 44px;
  padding: 0;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background-color: var(--bg-surface);
}

.menu-toggle span:not(.sr-only) {
  display: block;
  width: 20px;
  height: 2px;
  background-color: var(--ink-900);
  border-radius: 2px;
  transition: transform 0.25s ease, opacity 0.25s ease;
}

.menu-toggle[aria-expanded="true"] span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.menu-toggle[aria-expanded="true"] span:nth-child(2) {
  opacity: 0;
}

.menu-toggle[aria-expanded="true"] span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

@media (min-width: 960px) {
  .menu-toggle {
    display: none;
  }
}

/* Mobile Slide-down Menu */
@media (max-width: 959px) {
  .site-nav {
    display: flex;
    pointer-events: none;
    position: absolute;
    top: var(--header-height);
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: stretch;
    background-color: var(--bg-surface);
    border-bottom: 1px solid var(--border);
    box-shadow: var(--shadow-elevated);
    padding: 0 var(--space-5);
    gap: 0;
    max-height: 0;
    overflow: hidden;
    opacity: 0;
    transition: max-height 0.3s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.25s ease, padding 0.3s ease;
  }

  .site-nav.is-open {
    pointer-events: auto;
    max-height: 380px;
    opacity: 1;
    padding: var(--space-4) var(--space-5) var(--space-6);
    gap: var(--space-3);
  }

  .site-nav a {
    padding: var(--space-3) 0;
    font-size: var(--text-base);
    border-bottom: 1px solid var(--border-subtle);
  }

  .site-nav a:last-child {
    border-bottom: none;
  }

  .site-nav a.is-active::after {
    display: none;
  }
}

/* ==========================================================================
   HERO & BOOKING SECTION
   ========================================================================== */
.hero-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-6);
  align-items: start;
}

/* Mobile layout (<1024px): Hero copy first -> Booking form */
@media (max-width: 1023px) {
  .hero-grid {
    display: flex;
    flex-direction: column;
    gap: var(--space-5);
  }

  .hero-copy {
    display: flex;
    flex-direction: column;
    gap: var(--space-4);
    max-width: 100%;
  }

  .hero-intro h1 {
    font-size: clamp(1.85rem, 5.5vw, 2.35rem);
    line-height: 1.15;
    margin-bottom: var(--space-2);
  }

  .hero-text {
    font-size: var(--text-sm);
    line-height: 1.6;
    color: var(--ink-800);
  }

  .hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: var(--space-3);
    margin-top: var(--space-1);
  }

  .booking-panel {
    width: 100%;
  }

  .booking-top-bar {
    display: contents;
  }

}

.hero-copy {
  display: flex;
  flex-direction: column;
  gap: var(--space-4);
  max-width: 640px;
}

.hero-intro h1 {
  margin: 0 0 var(--space-3);
  font-family: var(--font-heading);
  font-size: var(--text-h1);
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -0.03em;
  color: var(--ink-950);
}

.hero-text {
  margin: 0;
  font-size: var(--text-base);
  color: var(--ink-800);
  line-height: 1.6;
  max-width: 58ch;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-3);
  margin-top: var(--space-1);
}

.hero-actions .button {
  min-width: 140px;
}

/* ==========================================================================
   BOOKING CARD (Form Panel)
   ========================================================================== */
.booking-panel {
  background-color: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-card);
  padding: var(--space-5);
  box-shadow: var(--shadow-elevated);
}

@media (max-width: 639px) {
  .booking-panel {
    padding: var(--space-4) var(--space-3);
  }
}

.panel-topline {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: var(--space-4);
}

.panel-badge {
  font-size: var(--text-xs);
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--brand-gold);
}

.maps-status {
  display: none !important;
}

/* Service Category Tabs (Wrapping cleanly without side scroll bar) */
.service-toggle {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  flex-wrap: wrap;
  overflow: visible;
  scrollbar-width: none;
  -ms-overflow-style: none;
  margin-bottom: var(--space-4);
  padding-bottom: 0;
}

.service-toggle::-webkit-scrollbar {
  display: none;
  width: 0;
  height: 0;
}

.service-toggle-button {
  flex-shrink: 0;
  padding: 8px 14px;
  border-radius: var(--radius-pill);
  font-size: var(--text-xs);
  font-weight: 700;
  color: var(--text-secondary);
  background-color: var(--ink-100);
  border: 1px solid transparent;
  transition: all 0.2s ease;
}

.service-toggle-button:hover {
  background-color: #e5e7eb;
  color: var(--text-primary);
}

.service-toggle-button.is-active {
  background-color: var(--ink-950);
  color: #ffffff;
}

/* One Way / Round Trip Segmented Control */
.trip-toggle {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4px;
  padding: 4px;
  background-color: var(--ink-100);
  border-radius: var(--radius-pill);
  margin-bottom: var(--space-4);
}

.trip-toggle-button {
  min-height: 40px;
  border-radius: var(--radius-pill);
  font-size: var(--text-xs);
  font-weight: 700;
  color: var(--text-secondary);
  transition: all 0.2s ease;
}

.trip-toggle-button.is-active {
  background-color: var(--bg-surface);
  color: var(--ink-950);
  box-shadow: 0 1px 3px rgba(17, 24, 39, 0.1);
}

/* Form Steps */
.form-step-group {
  margin: 0 0 var(--space-4);
  padding: var(--space-4);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-card);
  background-color: #fafaf9;
}

.form-step-title {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  padding: 0 var(--space-2);
  font-size: var(--text-xs);
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--ink-700);
}

.step-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background-color: var(--brand-yellow);
  color: var(--ink-950);
  font-size: 0.75rem;
  font-weight: 800;
}

.field-grid {
  display: grid;
  gap: var(--space-3);
}

.field-grid.two-col {
  grid-template-columns: 1fr;
}

@media (min-width: 480px) {
  .field-grid.two-col {
    grid-template-columns: 1fr 1fr;
  }
}

.field-grid + .field-grid {
  margin-top: var(--space-3);
}

.field {
  display: flex;
  flex-direction: column;
}

.field label {
  margin-bottom: 6px;
  font-size: var(--text-xs);
  font-weight: 700;
  color: var(--ink-800);
}

.field input,
.field select,
.field textarea {
  width: 100%;
  padding: 10px 14px;
  font-size: var(--text-base); /* 16px strictly prevents iOS Safari viewport auto-zoom */
  color: var(--text-primary);
  background-color: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  transition: border-color 0.2s ease, box-shadow 0.2s ease, background-color 0.2s ease;
}

/* Dropdowns maintain website warm cream color palette with brand gold chevrons */
.field select,
.phone-group select {
  background-color: var(--bg-page);
  border-color: #e2ddd3;
  color: var(--ink-950);
  cursor: pointer;
  appearance: none;
  -webkit-appearance: none;
  -moz-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='%23b45309' stroke-width='2.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 14px center;
  background-size: 16px 16px;
  padding-right: 38px;
}

.phone-group select {
  background-position: right 8px center;
  padding-left: 10px;
  padding-right: 24px;
}

.field select:hover,
.phone-group select:hover {
  border-color: var(--brand-yellow);
}

.field select:focus,
.phone-group select:focus {
  outline: none;
  border-color: var(--brand-yellow);
  background-color: #ffffff;
  box-shadow: 0 0 0 3px rgba(245, 180, 0, 0.22);
}

.field select option,
.phone-group select option {
  background-color: var(--bg-page);
  color: var(--ink-950);
  padding: 8px 12px;
}

.field input:focus,
.field textarea:focus {
  outline: none;
  border-color: var(--brand-yellow);
  box-shadow: 0 0 0 3px rgba(245, 180, 0, 0.2);
}

.field input.is-invalid,
.field select.is-invalid,
.field textarea.is-invalid {
  border-color: var(--status-danger);
  box-shadow: 0 0 0 3px rgba(220, 38, 38, 0.15);
}

.field-help {
  margin: 4px 0 0;
  font-size: var(--text-xs);
  color: var(--text-muted);
}

.field-error {
  margin: 4px 0 0;
  font-size: var(--text-xs);
  color: var(--status-danger);
  min-height: 1.2em;
}

.is-hidden {
  display: none !important;
}

/* Phone input group */
.phone-group {
  display: grid;
  grid-template-columns: 88px minmax(0, 1fr);
  gap: var(--space-2);
}

/* AC / Non-AC Toggle */
.ac-toggle {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4px;
  padding: 3px;
  background-color: var(--ink-100);
  border-radius: var(--radius-sm);
}

.ac-toggle-button {
  min-height: 38px;
  border-radius: 6px;
  font-size: var(--text-xs);
  font-weight: 700;
  color: var(--text-secondary);
  transition: all 0.2s ease;
}

.ac-toggle-button.is-active {
  background-color: var(--bg-surface);
  color: var(--ink-950);
  box-shadow: 0 1px 2px rgba(17, 24, 39, 0.08);
}

/* Autocomplete container and dropdown */
.autocomplete-shell {
  position: relative;
}

.autocomplete-list {
  position: absolute;
  top: calc(100% + 4px);
  left: 0;
  right: 0;
  z-index: 60;
  display: none;
  max-height: 220px;
  overflow-y: auto;
  background-color: var(--bg-page);
  border: 1px solid #e2ddd3;
  border-radius: var(--radius-sm);
  box-shadow: 0 10px 25px -5px rgba(17, 24, 39, 0.12), 0 8px 10px -6px rgba(17, 24, 39, 0.08);
}

.autocomplete-list.is-open {
  display: block;
}

.autocomplete-item {
  width: 100%;
  padding: 10px 14px;
  text-align: left;
  border-bottom: 1px solid rgba(0, 0, 0, 0.05);
  background-color: transparent;
  transition: background-color 0.15s ease;
  cursor: pointer;
}

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

.autocomplete-item:hover,
.autocomplete-item:focus-visible {
  background-color: var(--brand-yellow-light);
  outline: none;
}

.autocomplete-main {
  display: block;
  font-size: var(--text-xs);
  font-weight: 700;
  color: var(--ink-950);
}

.autocomplete-secondary {
  display: block;
  font-size: var(--text-xs);
  color: var(--ink-700);
}

.autocomplete-empty {
  padding: 10px 14px;
  font-size: var(--text-xs);
  color: var(--text-muted);
}

/* Route Preview Section */
.route-preview {
  margin-top: var(--space-3);
  margin-bottom: var(--space-3);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  overflow: hidden;
  background-color: var(--bg-surface);
}

.route-preview[hidden] {
  display: none;
}

.route-preview-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 14px;
  background-color: var(--ink-100);
}

.route-preview-kicker {
  margin: 0;
  font-size: 0.75rem;
  font-weight: 800;
  text-transform: uppercase;
  color: var(--brand-gold);
}

.route-preview h3 {
  margin: 0;
  font-size: var(--text-xs);
  font-weight: 700;
}

.route-distance {
  font-size: var(--text-xs);
  font-weight: 800;
  color: var(--brand-gold);
  background-color: var(--brand-yellow-light);
  padding: 4px 8px;
  border-radius: var(--radius-pill);
}

.route-map {
  height: 220px;
  background-color: #e5e7eb;
}

/* Notes Collapsible Disclosure */
.notes-disclosure {
  margin-top: var(--space-3);
  border: 1px dashed var(--border);
  border-radius: var(--radius-sm);
  background-color: var(--bg-surface);
}

.notes-toggle {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  padding: 10px 14px;
  font-size: var(--text-xs);
  font-weight: 700;
  color: var(--ink-700);
  cursor: pointer;
  list-style: none;
  user-select: none;
}

.notes-toggle::-webkit-details-marker {
  display: none;
}

.notes-toggle-icon {
  font-size: 1rem;
  font-weight: 800;
  color: var(--brand-gold);
}

.notes-body {
  padding: 0 14px 14px;
}

.notes-body textarea {
  resize: vertical;
  min-height: 80px;
}

/* --- Fare Estimate Panel (Inside Form, Above Buttons) --- */
.fare-card {
  margin-block: var(--space-2);
  transition: all 0.25s ease;
  width: 100%;
  box-sizing: border-box;
}

/* Empty State: Single clean, subtle text line under the form fields */
.fare-card.is-empty,
.fare-card:has(.fare-card-empty) {
  background: transparent;
  box-shadow: none;
  border: none;
  padding: 0;
  margin: var(--space-2) auto var(--space-3);
  text-align: center;
  display: flex;
  justify-content: center;
}

.fare-card-empty {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  font-size: var(--text-xs);
  color: var(--text-muted);
  line-height: 1.4;
  padding: 4px 8px;
  text-align: center;
}

.fare-empty-icon {
  width: 15px;
  height: 15px;
  flex-shrink: 0;
  color: var(--brand-gold);
}

/* Calculated State: Beautiful, well-aligned, structured theme card */
.fare-card:not(.is-empty):not(:has(.fare-card-empty)) {
  display: block;
  background-color: var(--bg-page);
  border: 1px solid #e2ddd3;
  color: var(--ink-950);
  border-radius: var(--radius-card);
  padding: var(--space-4) var(--space-5);
  box-shadow: 0 4px 20px rgba(17, 24, 39, 0.06);
  max-width: 640px;
  margin: var(--space-3) auto;
  box-sizing: border-box;
}

.fare-summary-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-3);
  margin-bottom: var(--space-3);
  border-bottom: 1px solid #e2ddd3;
  padding-bottom: var(--space-3);
}

.fare-title {
  margin: 0 0 2px;
  font-family: var(--font-heading);
  font-size: 1.125rem;
  font-weight: 700;
  color: var(--ink-950);
  line-height: 1.25;
}

.fare-note {
  margin: 0;
  font-size: var(--text-xs);
  color: var(--text-muted);
}

.fare-schedule {
  margin: 0;
  font-size: var(--text-xs);
  color: var(--text-muted);
  line-height: 1.4;
}

.fare-reference {
  display: inline-flex;
  align-items: center;
  font-family: var(--font-heading);
  font-size: 0.8125rem;
  font-weight: 800;
  letter-spacing: 0.5px;
  color: var(--brand-gold);
  background-color: rgba(245, 180, 0, 0.18);
  padding: 4px 10px;
  border-radius: var(--radius-pill);
  white-space: nowrap;
}

/* 2-column balanced grid on tablet/desktop, 1-col on mobile */
.fare-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px 24px;
}

@media (max-width: 559px) {
  .fare-card:not(.is-empty):not(:has(.fare-card-empty)) {
    padding: var(--space-4) var(--space-3);
  }

  .fare-grid {
    grid-template-columns: 1fr;
    gap: 4px;
  }

  .fare-row {
    font-size: 13px;
    padding: 5px 0;
  }
}

.fare-row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: var(--space-2);
  padding: 6px 0;
  border-bottom: 1px solid rgba(0, 0, 0, 0.05);
  font-size: 13.5px;
  line-height: 1.4;
}

.fare-row span {
  color: var(--text-secondary);
  font-weight: 500;
  white-space: nowrap;
}

.fare-row strong {
  color: var(--ink-950);
  font-weight: 700;
  text-align: right;
  white-space: nowrap;
}

/* Prominent full-width Total Estimate banner */
.fare-row.total {
  grid-column: 1 / -1;
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: var(--space-3);
  padding: 12px 16px;
  background: rgba(245, 180, 0, 0.1);
  border: 1px solid rgba(245, 180, 0, 0.25);
  border-radius: var(--radius-sm);
}

.fare-row.total span {
  font-family: var(--font-heading);
  font-size: var(--text-sm);
  font-weight: 700;
  color: var(--ink-950);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.fare-row.total strong {
  font-family: var(--font-heading);
  font-size: 1.35rem;
  font-weight: 800;
  color: var(--brand-gold);
}

/* Full-width Cancellation Policy Footer */
.fare-note.fare-policy {
  margin: var(--space-3) 0 0;
  padding-top: var(--space-3);
  border-top: 1px solid #e2ddd3;
  font-size: 12px;
  line-height: 1.5;
  color: var(--text-muted);
  text-align: center;
}

.fare-note.fare-policy strong {
  color: var(--ink-800);
}

/* Status Banner */
.status-banner {
  display: none;
  padding: 12px 14px;
  border-radius: var(--radius-sm);
  font-size: var(--text-xs);
  font-weight: 600;
  margin-bottom: var(--space-4);
}

.status-banner.is-visible {
  display: block;
}

.status-banner.is-success {
  background-color: var(--status-success-bg);
  color: var(--status-success);
  border: 1px solid rgba(21, 128, 61, 0.2);
}

.status-banner.is-error {
  background-color: var(--status-danger-bg);
  color: var(--status-danger);
  border: 1px solid rgba(220, 38, 38, 0.2);
}

/* Action Row (Centered, Equal-sized buttons, not taking entire form width) */
.booking-actions {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: var(--space-3);
  width: 100%;
  text-align: center;
}

.booking-actions-buttons {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: var(--space-3);
  width: 100%;
  max-width: 600px;
  margin-inline: auto;
  align-items: stretch;
}

.action-subrow {
  display: contents;
}

.action-primary,
.action-calc,
.action-call {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  width: 100%;
  min-height: 42px;
  height: 42px;
  padding: 0 10px;
  font-size: 13.5px;
  font-weight: 700;
  white-space: nowrap;
  border-radius: var(--radius-sm);
  box-sizing: border-box;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.action-primary {
  background-color: var(--whatsapp);
  color: #ffffff;
  border: 1px solid transparent;
  box-shadow: 0 2px 8px rgba(37, 211, 102, 0.25);
}

.action-primary:hover {
  background-color: var(--whatsapp-hover);
  box-shadow: 0 4px 12px rgba(37, 211, 102, 0.32);
  transform: translateY(-1px);
}

.action-calc {
  background-color: var(--bg-page);
  color: var(--ink-900);
  border: 1px solid #e2ddd3;
  box-shadow: 0 1px 2px rgba(17, 24, 39, 0.05);
}

.action-calc:hover {
  background-color: var(--brand-yellow-light);
  border-color: var(--brand-yellow);
  color: var(--ink-950);
  transform: translateY(-1px);
}

.action-call {
  background-color: var(--bg-page);
  color: var(--ink-900);
  border: 1px solid #e2ddd3;
  box-shadow: 0 1px 2px rgba(17, 24, 39, 0.05);
}

.action-call:hover {
  background-color: var(--brand-yellow-light);
  border-color: var(--brand-yellow);
  color: var(--ink-950);
  transform: translateY(-1px);
}

@media (max-width: 639px) {
  .booking-actions-buttons {
    grid-template-columns: 1fr;
    width: 100%;
    max-width: 100%;
    gap: 10px;
  }

  .action-primary,
  .action-calc,
  .action-call {
    min-height: 46px;
    height: 46px;
    font-size: 14.5px;
  }
}

.phone-assist-line {
  margin: var(--space-1) 0 0;
  font-size: var(--text-xs);
  color: var(--text-muted);
  text-align: center;
}

.phone-assist-line a {
  font-weight: 700;
  color: var(--ink-900);
  text-decoration: underline;
}

/* Cancellation Policy Disclosure inside card */
.policy-disclosure {
  margin-top: var(--space-4);
  border-top: 1px solid var(--border);
  padding-top: var(--space-3);
}

.policy-disclosure-summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-2);
  cursor: pointer;
  list-style: none;
  font-size: var(--text-xs);
  font-weight: 700;
  color: var(--text-secondary);
}

.policy-disclosure-summary::-webkit-details-marker {
  display: none;
}

.policy-icon {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
  color: var(--brand-gold);
}

.disclosure-chevron {
  width: 16px;
  height: 16px;
  transition: transform 0.2s ease;
  margin-left: auto;
}

.policy-disclosure[open] .disclosure-chevron {
  transform: rotate(180deg);
}

.policy-disclosure-content {
  padding-top: var(--space-2);
}

.policy-list {
  margin: 0;
  padding-left: var(--space-4);
  font-size: var(--text-xs);
  color: var(--text-secondary);
  line-height: 1.55;
}

.policy-list li + li {
  margin-top: 6px;
}

/* ==========================================================================
   FLEET & PRICING (Merged Section)
   ========================================================================== */
.fleet-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-5);
  margin-bottom: var(--space-7);
}

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

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

.fleet-card {
  display: flex;
  flex-direction: column;
  background-color: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-card);
  padding: var(--space-5);
  box-shadow: var(--shadow-card);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.fleet-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-elevated);
}

.fleet-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: var(--space-3);
}

.fleet-badge {
  font-size: var(--text-xs);
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--brand-gold);
  background-color: var(--brand-yellow-light);
  padding: 4px 10px;
  border-radius: var(--radius-pill);
}

.fleet-capacity {
  font-size: var(--text-xs);
  font-weight: 700;
  color: var(--text-muted);
}

.fleet-icon-wrapper {
  width: 52px;
  height: 52px;
  border-radius: var(--radius-sm);
  background-color: var(--ink-100);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--ink-800);
  margin-bottom: var(--space-3);
}

.fleet-icon-wrapper svg {
  width: 28px;
  height: 28px;
}

.fleet-card h3 {
  margin: 0 0 var(--space-2);
  font-family: var(--font-heading);
  font-size: var(--text-lg);
  font-weight: 700;
  color: var(--ink-950);
}

.fleet-desc {
  margin: 0 0 var(--space-4);
  font-size: var(--text-xs);
  color: var(--text-secondary);
  line-height: 1.5;
  flex-grow: 1;
}

.fleet-pricing-block {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: var(--space-3);
  background-color: var(--ink-100);
  border-radius: var(--radius-sm);
  margin-bottom: var(--space-4);
}

.rate-row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
}

.rate-type {
  font-size: var(--text-xs);
  color: var(--text-secondary);
  font-weight: 600;
}

.rate-val {
  font-family: var(--font-heading);
  font-size: var(--text-sm);
  font-weight: 800;
  color: var(--ink-950);
}

.rate-val .per-km {
  font-size: 0.75rem;
  font-weight: 500;
  color: var(--text-muted);
}

.select-cab-btn {
  width: 100%;
}

/* Compact Pricing Rules Strip */
.pricing-rules-strip {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-4);
  background-color: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-card);
  padding: var(--space-5);
  box-shadow: var(--shadow-card);
}

@media (min-width: 768px) {
  .pricing-rules-strip {
    grid-template-columns: repeat(4, 1fr);
    align-items: center;
    gap: var(--space-4);
  }

  .rule-divider {
    display: none;
  }
}

.rule-column {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.rule-heading {
  font-size: var(--text-xs);
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.rule-stat {
  margin: 0;
  font-family: var(--font-heading);
  font-size: var(--text-base);
  font-weight: 800;
  color: var(--ink-950);
}

.rule-subtext {
  font-size: var(--text-xs);
  color: var(--text-secondary);
}

.rule-link {
  font-size: var(--text-xs);
  font-weight: 700;
  color: var(--brand-gold);
  text-decoration: underline;
}

.rule-divider {
  width: 100%;
  height: 1px;
  background-color: var(--border-subtle);
}

/* ==========================================================================
   POPULAR ROUTES SECTION
   ========================================================================== */
.routes-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-3);
}

@media (min-width: 560px) {
  .routes-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 768px) {
  .routes-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: var(--space-4);
  }
}

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

.route-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 16px;
  background-color: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-card);
  box-shadow: var(--shadow-card);
  text-align: left;
  transition: all 0.2s ease;
  min-height: 52px;
}

.route-card:hover {
  border-color: var(--brand-yellow);
  box-shadow: var(--shadow-elevated);
  transform: translateY(-1px);
}

.route-origin {
  font-size: var(--text-xs);
  font-weight: 600;
  color: var(--text-muted);
}

.route-arrow {
  color: var(--brand-gold);
  margin-inline: 4px;
}

.route-destination {
  font-size: var(--text-xs);
  font-weight: 800;
  color: var(--ink-950);
  flex-grow: 1;
}

.route-pill {
  font-size: 0.75rem;
  font-weight: 800;
  color: var(--brand-gold);
  background-color: var(--brand-yellow-light);
  padding: 3px 8px;
  border-radius: var(--radius-pill);
  flex-shrink: 0;
}

/* ==========================================================================
   WHY RIDE WITH US (Formerly Drivers)
   ========================================================================== */
.why-us-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-5);
}

@media (min-width: 768px) {
  .why-us-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

.feature-card {
  display: flex;
  flex-direction: column;
  background-color: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-card);
  padding: var(--space-6);
  box-shadow: var(--shadow-card);
  text-align: left;
  height: 100%;
}

.feature-icon {
  width: 48px;
  height: 48px;
  border-radius: var(--radius-sm);
  background-color: var(--brand-yellow-light);
  color: var(--brand-gold);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: var(--space-4);
  flex-shrink: 0;
}

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

.feature-card h3 {
  margin: 0 0 var(--space-2);
  font-family: var(--font-heading);
  font-size: var(--text-lg);
  font-weight: 700;
  color: var(--ink-950);
}

.feature-card p {
  margin: 0;
  font-size: var(--text-sm);
  color: var(--text-secondary);
  line-height: 1.6;
}

/* ==========================================================================
   FAQ SECTION (Single column, max-width ~800px)
   ========================================================================== */
.faq-list {
  max-width: 800px;
  margin-inline: auto;
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
}

.faq-item {
  background-color: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-card);
  box-shadow: var(--shadow-card);
  overflow: hidden;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.faq-item[open] {
  border-color: var(--brand-yellow);
  box-shadow: var(--shadow-elevated);
}

.faq-question {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-4);
  padding: 18px 20px;
  font-size: var(--text-base);
  font-weight: 700;
  color: var(--ink-900);
  cursor: pointer;
  list-style: none;
  user-select: none;
}

.faq-question::-webkit-details-marker {
  display: none;
}

.faq-chevron {
  width: 20px;
  height: 20px;
  color: var(--brand-gold);
  flex-shrink: 0;
  transition: transform 0.25s ease;
}

.faq-item[open] .faq-chevron {
  transform: rotate(180deg);
}

.faq-answer {
  padding: 0 20px 20px;
}

.faq-answer p {
  margin: 0;
  font-size: var(--text-sm);
  color: var(--text-secondary);
  line-height: 1.65;
}

/* ==========================================================================
   CONTACT SECTION (3 Equal Cards in a 3-column Grid)
   ========================================================================== */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-5);
}

@media (min-width: 768px) {
  .contact-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

.contact-card {
  display: flex;
  flex-direction: column;
  background-color: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-card);
  padding: var(--space-6);
  box-shadow: var(--shadow-card);
  transition: all 0.2s ease;
}

.contact-card:hover {
  border-color: var(--brand-yellow);
  transform: translateY(-2px);
  box-shadow: var(--shadow-elevated);
}

.contact-card-icon {
  width: 48px;
  height: 48px;
  border-radius: var(--radius-sm);
  background-color: var(--ink-100);
  color: var(--ink-950);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: var(--space-4);
  flex-shrink: 0;
}

.contact-card-icon.whatsapp-icon-bg {
  background-color: #eafaf1;
  color: var(--whatsapp);
}

.contact-card-icon svg,
.contact-card-icon img,
.contact-wa-img {
  width: 26px;
  height: 26px;
  display: block;
  object-fit: contain;
}

.contact-label {
  margin: 0 0 6px;
  font-size: var(--text-xs);
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.contact-card h3 {
  margin: 0 0 var(--space-2);
  font-family: var(--font-heading);
  font-size: var(--text-lg);
  font-weight: 700;
  color: var(--ink-950);
}

.contact-card p {
  margin: 0 0 var(--space-4);
  font-size: var(--text-xs);
  color: var(--text-secondary);
  line-height: 1.5;
  flex-grow: 1;
}

.contact-card-cta {
  font-size: var(--text-xs);
  font-weight: 700;
  color: var(--brand-gold);
}

/* ==========================================================================
   FOOTER (Proper 4-Column Layout)
   ========================================================================== */
.site-footer {
  background-color: var(--ink-950);
  color: #94a3b8;
  padding-top: var(--space-8);
  padding-bottom: var(--space-6);
}

.footer-container {
  display: flex;
  flex-direction: column;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-6);
  margin-bottom: var(--space-7);
}

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

@media (min-width: 1024px) {
  .footer-grid {
    grid-template-columns: 1.4fr 1fr 1fr 1.2fr;
  }
}

.footer-brand {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  margin-bottom: var(--space-2);
}

.footer-logo {
  width: 36px;
  height: 36px;
}

.footer-brand-title {
  font-family: var(--font-heading);
  font-size: 1.25rem;
  font-weight: 800;
  color: #ffffff;
}

.footer-tagline {
  margin: 0 0 var(--space-2);
  font-size: var(--text-xs);
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--brand-yellow);
}

.footer-desc {
  margin: 0;
  font-size: var(--text-xs);
  line-height: 1.6;
  color: #94a3b8;
  max-width: 36ch;
}

.footer-heading {
  margin: 0 0 var(--space-4);
  font-family: var(--font-heading);
  font-size: var(--text-sm);
  font-weight: 700;
  color: #ffffff;
  letter-spacing: 0.02em;
}

.footer-links {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
}

.footer-links a {
  font-size: var(--text-xs);
  color: #cbd5e1;
  transition: color 0.2s ease;
}

.footer-links a:hover {
  color: var(--brand-yellow);
}

.footer-contact-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
  font-size: var(--text-xs);
  color: #cbd5e1;
}

.footer-contact-list strong {
  color: #ffffff;
  margin-right: 4px;
}

.footer-contact-list a {
  color: #cbd5e1;
}

.footer-contact-list a:hover {
  color: var(--brand-yellow);
}

.footer-divider {
  width: 100%;
  height: 1px;
  background-color: rgba(255, 255, 255, 0.1);
  margin-bottom: var(--space-5);
}

.footer-bottom {
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
  font-size: var(--text-xs);
  color: #64748b;
}

@media (min-width: 768px) {
  .footer-bottom {
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
  }
}

.footer-bottom p {
  margin: 0;
}

/* ==========================================================================
   FLOATING ACTIONS & MOBILE STICKY BAR
   ========================================================================== */
/* Desktop Floating WhatsApp Button (Single circle, bottom-right) */
.floating-whatsapp {
  position: fixed;
  right: 24px;
  bottom: 24px;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background-color: var(--whatsapp);
  color: #ffffff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 6px 18px rgba(37, 211, 102, 0.35);
  z-index: 40;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.floating-whatsapp:hover {
  transform: translateY(-2px) scale(1.04);
  box-shadow: 0 10px 24px rgba(37, 211, 102, 0.45);
}

.floating-whatsapp svg,
.floating-whatsapp img,
.floating-wa-img {
  width: 26px;
  height: 26px;
  display: block;
  object-fit: contain;
}

/* Mobile Sticky Bottom Bar */
.mobile-sticky-bar {
  display: none;
}

@media (max-width: 767px) {
  /* Hide the floating circle on mobile in favor of sticky bottom bar */
  .floating-whatsapp {
    display: none;
  }

  body {
    padding-bottom: 72px; /* Prevent footer & actions from being covered */
  }

  .mobile-sticky-bar {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 45;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--space-2);
    padding: 10px 16px;
    background-color: rgba(255, 255, 255, 0.96);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-top: 1px solid var(--border);
    box-shadow: 0 -4px 16px rgba(17, 24, 39, 0.08);
  }

  .mobile-bar-btn {
    min-height: 44px;
    font-size: var(--text-xs);
    width: 100%;
  }
}

/* ==========================================================================
   SCROLL REVEAL ANIMATIONS
   ========================================================================== */
.reveal {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.5s cubic-bezier(0.16, 1, 0.3, 1), transform 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

.reveal.in-view {
  opacity: 1;
  transform: translateY(0);
}

/* ==========================================================================
   ACCESSIBILITY & REDUCED MOTION
   ========================================================================== */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }

  .reveal {
    opacity: 1 !important;
    transform: none !important;
  }
}

/* ==========================================================================
   DESKTOP BOOKING PANEL & HERO LAYOUT (>=1024px)
   ========================================================================== */
@media (min-width: 1024px) {
  /* 1. Hero: Compact, single row, full width above the form with background image */
  .hero-section {
    background-image:
      linear-gradient(to right, rgba(250, 247, 240, 0.96) 0%, rgba(250, 247, 240, 0.90) 42%, rgba(250, 247, 240, 0) 65%),
      var(--hero-bg-image);
    padding-top: var(--space-6);
    padding-bottom: 72px; /* Provides 32px breathing room for the -40px booking panel overlap */
  }

  .hero-grid {
    display: flex;
    flex-direction: column;
    gap: 0;
  }

  .hero-copy {
    display: flex;
    flex-direction: column;
    gap: var(--space-4);
    max-width: 640px;
    width: 100%;
    padding-bottom: 56px; /* Space for the 40px negative overlap of the booking panel */
  }

  .hero-intro h1 {
    font-size: clamp(2rem, 4vw, 3.25rem);
    line-height: 1.15;
    margin-bottom: var(--space-3);
  }

  .hero-text {
    font-size: var(--text-base);
    line-height: 1.6;
    max-width: 60ch;
    color: var(--ink-800);
    margin: 0;
  }

  .hero-actions {
    display: flex;
    align-items: center;
    gap: var(--space-3);
    margin-top: var(--space-2);
  }

  /* 2. Booking panel: Wide horizontal card overlapping hero by -40px */
  .booking-panel {
    position: relative;
    z-index: 20;
    width: 100%;
    max-width: var(--max-width);
    margin-inline: auto;
    margin-top: -40px;
    background-color: var(--bg-surface);
    border-radius: 16px;
    border: 1px solid var(--border);
    box-shadow: 0 10px 30px rgba(17, 24, 39, 0.08), 0 1px 3px rgba(17, 24, 39, 0.05);
    padding: var(--space-5) var(--space-6);
    scroll-margin-top: calc(var(--header-height) + 16px);
    overflow: visible;
  }

  .panel-topline {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: var(--space-4);
  }

  /* 3. 12-Column Grid for #bookingForm */
  #bookingForm {
    display: grid;
    grid-template-columns: repeat(12, 1fr);
    column-gap: var(--space-4);
    row-gap: var(--space-4);
    align-items: start;
    overflow: visible;
  }

  /* Dissolve step wrappers and hide step headers on desktop */
  .form-step-group {
    display: contents;
    border: none;
    padding: 0;
    margin: 0;
    background: transparent;
  }

  .form-step-title {
    display: none;
  }

  .field-grid {
    display: contents;
  }

  .field {
    position: relative;
    display: flex;
    flex-direction: column;
    min-width: 0;
    overflow: visible;
  }

  .field label {
    margin-bottom: 6px;
    font-size: var(--text-xs);
    font-weight: 700;
    color: var(--ink-800);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .field input,
  .field select {
    height: 48px;
    min-height: 48px;
    padding: 0 14px;
    font-size: var(--text-sm);
    line-height: 48px;
    border-radius: var(--radius-sm);
  }

  .field input {
    background-color: var(--bg-surface);
    border: 1px solid var(--border);
  }

  .field select {
    background-color: var(--bg-page);
    border: 1px solid #e2ddd3;
    padding-right: 38px;
  }

  /* Reserve 18px for validation errors so neighbouring fields never jump */
  .field-error {
    margin: 3px 0 0;
    font-size: 0.8125rem;
    line-height: 1.2;
    min-height: 18px;
    color: var(--status-danger);
  }

  .field-help {
    margin: 3px 0 0;
    font-size: 0.8125rem;
    line-height: 1.2;
    min-height: 18px;
    color: var(--text-muted);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  /* Autocomplete Dropdown overlay */
  .autocomplete-shell {
    position: relative;
    overflow: visible;
  }

  .autocomplete-list {
    position: absolute;
    top: calc(100% + 4px);
    left: 0;
    right: 0;
    z-index: 60;
    max-height: 240px;
    overflow-y: auto;
    background-color: var(--bg-page);
    border: 1px solid #e2ddd3;
    border-radius: var(--radius-sm);
    box-shadow: 0 12px 28px rgba(17, 24, 39, 0.16);
  }

  /* Row A (Top Bar): Service Tabs + Segmented Trip Toggle */
  .booking-top-bar {
    grid-column: 1 / 13;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: var(--space-3);
    flex-wrap: wrap;
    padding-bottom: var(--space-3);
    border-bottom: 1px solid var(--border-subtle);
    order: 1;
  }

  .service-toggle {
    display: flex;
    align-items: center;
    gap: 6px;
    flex-wrap: wrap;
    margin-bottom: 0;
    padding-bottom: 0;
    overflow: visible;
  }

  .service-toggle-button {
    padding: 8px 14px;
    font-size: var(--text-xs);
    white-space: nowrap;
    border-radius: var(--radius-pill);
  }

  .trip-toggle {
    margin-bottom: 0;
    flex-shrink: 0;
  }

  .trip-toggle-button {
    min-height: 38px;
    padding: 0 16px;
    white-space: nowrap;
  }

  /* Row B: Traveller Details (Personal Details First) */
  .field-name {
    grid-column: span 3;
    order: 2;
  }

  .field-mobile {
    grid-column: span 3;
    order: 3;
  }

  .phone-group {
    display: grid;
    grid-template-columns: 84px minmax(0, 1fr);
    gap: var(--space-2);
  }

  .phone-group select {
    height: 48px;
    min-height: 48px;
    background-color: var(--bg-page);
    border: 1px solid #e2ddd3;
    padding-left: 10px;
    padding-right: 24px;
  }

  .phone-group input {
    height: 48px;
    min-height: 48px;
    background-color: var(--bg-surface);
    border: 1px solid var(--border);
  }

  .field-passengers {
    grid-column: span 3;
    order: 4;
  }

  .field-luggage {
    grid-column: span 3;
    order: 5;
  }

  /* Row C: Vehicle Preference & Schedule */
  .field-ac {
    grid-column: span 4;
    order: 6;
  }

  .ac-toggle {
    height: 48px;
    min-height: 48px;
    padding: 4px;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4px;
    align-items: stretch;
    background-color: var(--ink-100);
    border-radius: var(--radius-sm);
  }

  .ac-toggle-button {
    min-height: 40px;
    height: 100%;
    font-size: var(--text-xs);
    border-radius: 6px;
  }

  /* One-way schedule fields */
  .field-date {
    grid-column: span 4;
    order: 7;
  }

  .field-time {
    grid-column: span 4;
    order: 8;
  }

  /* Round-trip schedule fields */
  .field-start-date {
    grid-column: span 2;
    order: 7;
  }

  .field-start-time {
    grid-column: span 2;
    order: 8;
  }

  .field-return-date {
    grid-column: span 2;
    order: 9;
  }

  .field-return-time {
    grid-column: span 2;
    order: 10;
  }

  /* Row D: Location Details & Cab Type (Under personal details, vehicle preference, schedule & luggage) */
  .field-pickup {
    grid-column: span 3;
    order: 11;
  }

  .field-drop {
    grid-column: span 3;
    order: 12;
  }

  .field-distance {
    grid-column: span 3;
    order: 13;
  }

  .field-cab {
    grid-column: span 3;
    order: 14;
  }

  /* Notes Disclosure (Expandable toggle) */
  .notes-disclosure {
    grid-column: 1 / 13;
    order: 15;
    margin-top: 0;
  }

  .notes-toggle {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: var(--text-xs);
    font-weight: 700;
    color: var(--brand-gold);
    cursor: pointer;
    user-select: none;
    list-style: none;
  }

  .notes-toggle::-webkit-details-marker {
    display: none;
  }

  .notes-body {
    margin-top: var(--space-2);
  }

  .notes-body textarea {
    width: 100%;
    min-height: 72px;
  }

  /* Row D: Result + Actions Strip */
  /* Default when routePreview is hidden: collapse the space, fare and actions span full width (1 / 13) */
  #routePreview[hidden] {
    display: none !important;
  }

  #fareSummary {
    grid-column: 1 / 13;
    order: 17;
    margin-block: 0;
    width: 100%;
  }

  #fareSummary.is-empty,
  #fareSummary:has(.fare-card-empty) {
    display: flex;
    justify-content: center;
  }

  #statusBanner {
    grid-column: 1 / 13;
    order: 18;
    margin-bottom: 0;
  }

  .booking-actions {
    grid-column: 1 / 13;
    order: 19;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: var(--space-3);
    width: 100%;
  }

  .booking-actions-buttons {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: var(--space-3);
    width: 100%;
    max-width: 600px;
    margin-inline: auto;
  }

  .action-subrow {
    display: contents;
  }

  .action-primary,
  .action-calc,
  .action-call {
    width: 100%;
    height: 42px;
    min-height: 42px;
    font-size: 13.5px;
    padding: 0 10px;
  }

  .phone-assist-line {
    text-align: center;
    font-size: var(--text-xs);
    color: var(--text-muted);
    margin: 0;
  }

  /* When route is calculated: routePreview is visible -> 40/60 split with Map on left and Fare/Actions on right */
  #bookingForm:has(#routePreview:not([hidden])) #routePreview {
    grid-column: 1 / 6;
    order: 16;
    display: flex;
    flex-direction: column;
    height: 100%;
    min-height: 220px;
    max-height: 250px;
    margin: 0;
    border-radius: var(--radius-card);
    overflow: hidden;
  }

  #bookingForm:has(#routePreview:not([hidden])) .route-preview-heading {
    padding: 8px 12px;
  }

  #bookingForm:has(#routePreview:not([hidden])) .route-map {
    flex-grow: 1;
    min-height: 160px;
    height: 100%;
  }

  #bookingForm:has(#routePreview:not([hidden])) #fareSummary {
    grid-column: 6 / 13;
    order: 17;
  }

  #bookingForm:has(#routePreview:not([hidden])) #statusBanner {
    grid-column: 6 / 13;
    order: 18;
  }

  #bookingForm:has(#routePreview:not([hidden])) .booking-actions {
    grid-column: 6 / 13;
    order: 19;
  }

  #bookingForm:has(#routePreview:not([hidden])) .booking-actions-buttons {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    max-width: 520px;
    gap: 8px;
  }

  /* Responsive tuning for 1024-1200px in 40/60 split */
  @media (max-width: 1200px) {
    #bookingForm:has(#routePreview:not([hidden])) .booking-actions-buttons {
      grid-template-columns: 1fr;
      max-width: 280px;
    }
  }

  /* Cancellation Policy Disclosure at bottom */
  #booking-policy {
    grid-column: 1 / 13;
    order: 30;
    margin-top: var(--space-2);
    border-top: 1px solid var(--border-subtle);
    padding-top: var(--space-3);
  }
}

