/* TVS Booking WebApp (mobile-first) */

/* Hide Colibri theme chrome in booking app mode */
body.tvs-booking-page .colibri-header,
body.tvs-booking-page .colibri-hero,
body.tvs-booking-page .colibri-menu,
body.tvs-booking-page .colibri-page-header,
body.tvs-booking-page .colibri-navigation,
body.tvs-booking-page .colibri-footer,
body.tvs-booking-page .colibri-copyright,
body.tvs-booking-page .colibri-wp-copyright,
body.tvs-booking-body .colibri-header,
body.tvs-booking-body .colibri-hero,
body.tvs-booking-body .colibri-menu,
body.tvs-booking-body .colibri-page-header,
body.tvs-booking-body .colibri-navigation,
body.tvs-booking-body .colibri-footer,
body.tvs-booking-body .colibri-copyright,
body.tvs-booking-body .colibri-wp-copyright {
  display: none !important;
  visibility: hidden !important;
  height: 0 !important;
  overflow: hidden !important;
}


/* When JS is running, we add this class to body to hide theme chrome */
body.tvs-booking-page header,
body.tvs-booking-body header,
body.tvs-booking-page footer,
body.tvs-booking-body footer,
body.tvs-booking-page .site-header,
body.tvs-booking-body .site-header,
body.tvs-booking-page .site-footer,
body.tvs-booking-body .site-footer,
body.tvs-booking-page #masthead,
body.tvs-booking-body #masthead,
body.tvs-booking-page #colophon,
body.tvs-booking-body #colophon,
body.tvs-booking-page #wpadminbar,
body.tvs-booking-body #wpadminbar {
  /* keep wpadminbar hidden to avoid layout jumps on mobile */
  display: none !important;
}

body.tvs-booking-page,
body.tvs-booking-page html {
  margin: 0;
  padding: 0;
  height: 100%;
}

.tvs-booking-app {
  position: fixed;
  inset: 0;
  background: #f3f4f6;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
  color: #111827;
  z-index: 9999;
  overflow: hidden;
}

.tvs-app-topbar {
  height: 56px;
  background: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  border-bottom: 1px solid rgba(0,0,0,0.08);
}

.tvs-app-brand {
  font-weight: 700;
  font-size: 18px;
}

.tvs-step {
  position: absolute;
  inset: 56px 0 0 0;
  display: none;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}

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

/* Welcome */
.tvs-welcome-hero {
  padding: 28px 18px;
  text-align: center;
}

.tvs-welcome-icon {
  width: 84px;
  height: 84px;
  border-radius: 42px;
  background: #ffffff;
  margin: 20px auto 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 34px;
  box-shadow: 0 8px 20px rgba(0,0,0,0.08);
}

.tvs-welcome-hero h1 {
  font-size: 26px;
  line-height: 1.2;
  margin: 0 0 10px;
}

.tvs-welcome-hero p {
  margin: 0 0 18px;
  opacity: 0.85;
}

.tvs-welcome-bullets {
  list-style: none;
  padding: 0;
  margin: 18px 0 0;
  text-align: left;
  max-width: 320px;
  margin-left: auto;
  margin-right: auto;
}

.tvs-welcome-bullets li {
  margin: 10px 0;
  padding-left: 28px;
  position: relative;
  opacity: 0.9;
}

.tvs-welcome-bullets li:before {
  content: '✓';
  position: absolute;
  left: 0;
  top: 0;
  font-weight: 800;
}

/* Map screens */
.tvs-map {
  width: 100%;
  height: calc(100vh - 56px);
}

.tvs-mini-map {
  width: 100%;
  height: 260px;
}

.tvs-sheet {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  background: #ffffff;
  border-top-left-radius: 20px;
  border-top-right-radius: 20px;
  padding: 16px;
  box-shadow: 0 -10px 30px rgba(0,0,0,0.12);
}

.tvs-sheet-scroll {
  top: 56px;
  bottom: 0;
  overflow: auto;
}

.tvs-notice {
  background: #eef2ff;
  border: 1px solid rgba(99,102,241,0.2);
  color: #3730a3;
  padding: 10px 12px;
  border-radius: 12px;
  font-size: 13px;
  margin-bottom: 10px;
}

.tvs-muted {
  font-size: 13px;
  opacity: 0.85;
  margin: 8px 0 10px;
}

.tvs-form {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin: 10px 0 12px;
}

.tvs-field {
  background: #f9fafb;
  border: 1px solid rgba(0,0,0,0.08);
  border-radius: 16px;
  padding: 12px;
}

.tvs-field-label {
  font-size: 12px;
  letter-spacing: 0.08em;
  opacity: 0.65;
  margin-bottom: 6px;
}

.tvs-field-value {
  font-weight: 600;
}

.tvs-input {
  width: 100%;
  border: none;
  outline: none;
  background: transparent;
  font-size: 16px;
  padding: 2px 0;
}

.tvs-btn {
  width: 100%;
  border: none;
  border-radius: 14px;
  padding: 14px 14px;
  font-size: 16px;
  font-weight: 700;
  cursor: pointer;
}

.tvs-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.tvs-btn-primary {
  background: #111827;
  color: #ffffff;
}

.tvs-btn-secondary {
  background: #f3f4f6;
  color: #111827;
}

/* Price */
.tvs-price-summary {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.tvs-route {
  font-size: 14px;
  line-height: 1.4;
}

.tvs-metrics {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.tvs-metric {
  background: #f9fafb;
  border: 1px solid rgba(0,0,0,0.08);
  border-radius: 16px;
  padding: 14px;
  text-align: center;
}

.tvs-metric > div {
  font-size: 20px;
  font-weight: 800;
}

.tvs-metric small {
  opacity: 0.7;
  font-size: 11px;
  letter-spacing: 0.08em;
}

.tvs-info-box {
  background: #eff6ff;
  border-left: 4px solid #3b82f6;
  padding: 12px;
  border-radius: 12px;
  font-size: 13px;
}

.tvs-total {
  text-align: center;
  padding: 12px;
}

.tvs-total-label {
  opacity: 0.65;
  font-size: 12px;
  letter-spacing: 0.10em;
}

.tvs-total-amount {
  font-size: 40px;
  font-weight: 900;
  margin-top: 6px;
}

.tvs-breakdown {
  background: #f9fafb;
  border: 1px solid rgba(0,0,0,0.08);
  border-radius: 16px;
  padding: 14px;
}

.tvs-row {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  margin: 8px 0;
  font-size: 14px;
}

.tvs-row strong {
  font-weight: 800;
}

/* Contact/Confirm cards */
.tvs-card {
  background: #ffffff;
  border: 1px solid rgba(0,0,0,0.08);
  border-radius: 18px;
  padding: 14px;
  margin: 12px 0;
}

.tvs-card-title {
  font-size: 12px;
  letter-spacing: 0.10em;
  opacity: 0.65;
  margin-bottom: 10px;
}

.tvs-label {
  display: block;
  font-size: 12px;
  opacity: 0.75;
  margin: 10px 0 6px;
}

.tvs-textarea {
  width: 100%;
  min-height: 90px;
  border: 1px solid rgba(0,0,0,0.10);
  border-radius: 14px;
  padding: 12px;
  font-size: 14px;
  outline: none;
}

.tvs-qr {
  display: flex;
  justify-content: center;
  padding: 10px 0;
}

.tvs-booking-number {
  font-size: 22px;
  font-weight: 900;
}

.tvs-qr-expiry {
  text-align: center;
  color: #b91c1c;
  font-size: 12px;
  margin-top: 6px;
}

.tvs-steps {
  margin: 0;
  padding-left: 18px;
  font-size: 14px;
}

.tvs-footnote {
  opacity: 0.8;
  font-size: 12px;
  margin-top: 10px;
}


/* iOS safe-area bottom spacing */
body.tvs-booking-page .tvs-app,
body.tvs-booking-body .tvs-app {
  padding-bottom: calc(24px + env(safe-area-inset-bottom));
  min-height: 100vh;
}


/* Google Places Autocomplete dropdown should appear above the bottom sheet/buttons */
body .pac-container {
  z-index: 2147483647 !important;
  /* iOS/Safari tends to render it behind fixed elements unless we pin it */
  position: fixed !important;
  background: #fff;
  max-height: 40vh;
  overflow-y: auto;
  box-shadow: 0 12px 30px rgba(0,0,0,.18);
  border-radius: 12px;
  overflow: hidden;
}
body .pac-container .pac-item {
  font-size: 16px;
  padding: 10px 12px;
  color: #111;
}

/* Hide cookie banners inside the app-like booking flow */
#cookie-notice,
.cookie-notice-container,
.gdpr-cookie-consent,
.gdpr-cookie-consent-container,
.cc-window,
.cc-revoke {
  display: none !important;
}
body .pac-container:after { display:none !important; }

/* Ensure our sheet has a predictable stacking context below pac-container */
.tvs-sheet { z-index: 10; }

/* Price breakdown rows: keep everything aligned */
#tvs-breakdown .tvs-row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 12px;
}
#tvs-breakdown .tvs-row span { flex: 1 1 auto; }
#tvs-breakdown .tvs-row strong { flex: 0 0 auto; }

/* Hide cookie banners on the booking flow pages (app-like view).
   NOTE: These elements are injected by common cookie plugins. We scope to the booking page only. */
body.tvs-booking-page #cookie-law-info-bar,
body.tvs-booking-page .cli-bar-container,
body.tvs-booking-page .cli-modal,
body.tvs-booking-page #cookie-notice,
body.tvs-booking-page .cookie-notice-container,
body.tvs-booking-page #gdpr-cookie-message,
body.tvs-booking-page .gdpr-cookie-message,
body.tvs-booking-page .cc-window,
body.tvs-booking-page .cookiebanner,
body.tvs-booking-page .cookie-banner,
body.tvs-booking-page .cookie-consent,
body.tvs-booking-page .cookieConsent {
  display: none !important;
}

