/* ===== CRITICAL BASE STYLES ===== */
* {
  box-sizing: border-box;
}
html {
  scroll-behavior: smooth;
  font-size: 16px;
}
body {
  overflow-x: hidden;
  overflow-y: scroll;
  margin: 0;
  padding: 0;
  font-family: Arial, sans-serif; /* Consistent system font only */
  line-height: 1.6;
  color: #333;
  min-height: 100vh; /* Prevent height variations */
  position: relative; /* Establish positioning context */
}

/* ===== PREVENT LAYOUT SHIFTS ===== */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 15px;
}

.row {
  display: flex;
  flex-wrap: wrap;
  margin: 0 -15px;
}

.col-12,
.col-md-6,
.col-lg-4,
.col-lg-6 {
  padding: 0 15px;
  width: 100%;
}

@media (min-width: 768px) {
  .col-md-6 {
    width: 50%;
  }
}

@media (min-width: 992px) {
  .col-lg-4 {
    width: 33.333333%;
  }
  .col-lg-6 {
    width: 50%;
  }
}
/* ===== NAVBAR MINIMAL STYLES ===== */
#navbar-container {
  position: relative;
  /* Natural height - no fixed dimensions */
}
.navbar-wrapper {
  position: relative;
  z-index: 1030;
  background: #ffffff;
  transition: box-shadow 0.3s ease;
  will-change: box-shadow, padding;
  /* Natural height - no fixed dimensions */
}
.navbar-wrapper.fixed {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  width: 100%;
}
.navbar-wrapper.scrolled {
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}
.navbar-wrapper .navbar {
  margin-bottom: 0;
  transition: padding 0.3s ease;
}
.navbar-wrapper.scrolled .navbar {
  padding-top: 0.5rem !important;
  padding-bottom: 0.5rem !important;
}
.navbar-wrapper .navbar-brand img {
  transition: height 0.3s ease;
}
.navbar-wrapper.scrolled .navbar-brand img {
  height: 48px !important;
}
.top-bar {
  position: relative;
  z-index: 1000;
}
body {
  padding-top: 0;
}
.navbar-wrapper + * {
  margin-top: 0;
}
body.has-fixed-navbar {
  padding-top: 0;
}
@media (max-width: 991px) {
  .navbar-wrapper.scrolled .navbar-brand img {
    height: 44px !important;
  }
}

/* ===== CRITICAL MOBILE STYLES ===== */
.hero-slider {
  position: relative;
  width: 100%;
  height: 60vh;
  min-height: 400px;
  max-height: 600px;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #1a365d; /* Solid fallback - faster than gradient */
  color: white;
}

.hero-slider picture {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 1;
}

.hero-slider img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
}

.hero-content {
  position: relative;
  z-index: 3;
  text-align: center;
  color: white;
  padding: 15px 10px;
  max-width: 1200px;
  margin: 0 auto;
}

.hero-content-inner {
  text-align: left;
}

/* Ultra-minimal typography for fast paint */
.hero-main-title {
  font-family: Arial, sans-serif;
  font-size: 1.1rem;
  font-weight: 700;
  line-height: 1.15;
  margin: 0 0 0.3rem 0;
  color: white;
}

.hero-subtitle {
  font-family: Arial, sans-serif;
  font-size: 0.8rem;
  font-weight: 400;
  line-height: 1.25;
  margin: 0 0 0.6rem 0;
  color: rgba(255, 255, 255, 0.95);
}

.hero-badge {
  display: inline-block;
  padding: 0.25rem 0.6rem;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 50px;
  font-size: 0.7rem;
  margin-bottom: 0.4rem;
}

.hero-features {
  display: flex;
  gap: 0.25rem;
  margin-bottom: 0.75rem;
  flex-wrap: nowrap !important;
  justify-content: flex-start;
  flex-direction: row !important;
}

.hero-feature-item {
  display: inline-block;
  font-size: 0.55rem;
  white-space: nowrap;
  flex-shrink: 0;
  line-height: 4.8;
  padding: 0.2rem 0;
}

.hero-cta-group {
  display: flex;
  gap: 0.6rem;
  flex-wrap: wrap;
}

.hero-blue-filter {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(26, 54, 93, 0.5);
  z-index: 2;
}

.hero-scroll-indicator {
  position: absolute;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 4;
  cursor: pointer;
  text-align: center;
  color: white;
  font-size: 0.85rem;
}

/* ===== PREVENT LAYOUT SHIFTS ===== */
.search-car-section {
  min-height: 200px;
  padding: 2rem 0;
}

.search-car-bg {
  border: 2px solid #1a365d;
  border-radius: 16px;
  box-shadow: 0 2px 16px rgba(0, 0, 0, 0.07);
  overflow: hidden;
  background: #fff;
  /* Natural sizing - no forced heights */
}

.search-car-form {
  background: #fff;
  border-radius: 18px;
  box-shadow: 0 2px 16px rgba(0, 0, 0, 0.08);
  padding: 32px 24px;
  max-width: 440px;
  margin: 0 auto;
}

.form-group {
  margin-bottom: 1rem;
}

.form-control {
  width: 100%;
  padding: 0.75rem;
  border: 1px solid #ddd;
  border-radius: 8px;
  font-size: 1rem;
  line-height: 1.5;
  height: 48px; /* Fixed height to prevent shifts */
  box-sizing: border-box;
}

.form-label {
  display: block;
  margin-bottom: 0.5rem;
  font-weight: 600;
  color: #333;
  font-family: Arial, sans-serif;
}

select.form-control {
  height: 48px; /* Same as inputs */
  appearance: none;
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 20 20'%3e%3cpath stroke='%236b7280' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='m6 8 4 4 4-4'/%3e%3c/svg%3e");
  background-position: right 0.75rem center;
  background-repeat: no-repeat;
  background-size: 1.5em 1.5em;
  padding-right: 2.5rem;
}

/* Fix select dropdown z-index issues on desktop */
@media (min-width: 768px) {
  select.form-control {
    position: relative;
    z-index: 10;
  }

  /* Ensure dropdown appears above other elements */
  select.form-control:focus {
    z-index: 20;
  }
}

.btn-modern {
  display: inline-block;
  padding: 10px 20px;
  background: #1a365d;
  color: white !important;
  text-decoration: none;
  border-radius: 8px;
  border: none;
  font-family: Arial, sans-serif;
  font-size: 0.85rem;
  font-weight: 600;
  text-align: center;
  cursor: pointer;
  transition: background 0.2s ease;
}

.btn-modern:hover {
  background: #0d1b2e;
  color: white !important;
  text-decoration: none;
}

.btn-hero-primary {
  background: #ffd700;
  color: #1a365d !important;
  font-weight: 700;
}

.btn-hero-primary:hover {
  background: #ffed4e;
  color: #1a365d !important;
}

.btn-hero-secondary {
  background: transparent;
  border: 2px solid white;
  color: white !important;
}

.btn-hero-secondary:hover {
  background: rgba(255, 255, 255, 0.1);
  color: white !important;
}

/* ===== CITY BAR STYLES - Ultra stable ===== */
.city-bar-wrapper {
  height: 50px;
  overflow: hidden;
  background: #f8f9fa;
  display: flex;
  align-items: center;
  border-top: 1px solid #e9ecef;
  border-bottom: 1px solid #e9ecef;
  position: relative; /* Prevent any positioning shifts */
  width: 100%; /* Prevent width changes */
}

.city-bar-track {
  display: flex;
  animation: scroll 20s linear infinite;
  white-space: nowrap;
  height: 50px;
  align-items: center;
}

.city-bar-item {
  display: inline-block;
  padding: 0 2rem;
  font-weight: 600;
  color: #1a365d;
  font-size: 0.9rem;
  font-family: "Inter", Arial, sans-serif;
  line-height: 50px;
  flex-shrink: 0;
  min-width: 120px;
  text-align: center;
}

@keyframes scroll {
  0% {
    transform: translateX(0);
  }
  100% {
    transform: translateX(-50%);
  }
}

/* ===== FLATPICKR CALENDAR FIX ===== */
/* Hide flatpickr calendars when not open */
.flatpickr-calendar:not(.open) {
  display: none !important;
}

/* Ensure flatpickr appears above all content */
.flatpickr-calendar.open {
  z-index: 9999 !important;
}

/* ===== RESPONSIVE STYLES ===== */
@media (max-width: 767.98px) {
  .top-bar {
    display: none !important;
  }
  .hero-slider {
    height: 60vh;
    min-height: 400px;
    max-height: 500px;
  }
  .hero-main-title {
    font-size: 2rem;
    margin-bottom: 0.75rem;
  }
  .hero-subtitle {
    font-size: 1rem;
    margin-bottom: 1.25rem;
  }
  .hero-content {
    padding: 1rem;
  }
  .hero-badge {
    font-size: 0.8rem;
    padding: 0.4rem 0.8rem;
  }
  .hero-features {
    gap: 0.25rem !important;
    margin-bottom: 0.75rem !important;
    flex-wrap: nowrap !important;
    justify-content: flex-start !important;
  }
  .hero-feature-item {
    font-size: 0.55rem !important;
    white-space: nowrap !important;
    padding: 0.2rem 0 !important;
    line-height: 4.8 !important;
  }
  .hero-cta-group {
    flex-direction: column;
    gap: 0.75rem;
  }
  .btn-modern {
    width: 100%;
    padding: 12px 20px;
    font-size: 0.95rem;
  }
  .hero-scroll-indicator {
    display: none;
  }
}

/* ===== MINIMAL DYNAMIC CONTENT APPROACH ===== */
/* Let content load naturally without reserved space */ /* Ensure no layout shifts from images */
img {
  max-width: 100%;
  height: auto;
  display: block; /* Prevent inline spacing issues */
}

/* Prevent shifts from loading states */
.loading-placeholder {
  background: #f8f9fa;
  border-radius: 8px;
  animation: pulse 1.5s ease-in-out infinite alternate;
}

@keyframes pulse {
  0% {
    opacity: 1;
  }
  100% {
    opacity: 0.7;
  }
}

/* Desktop hero adjustments - align left */
@media (min-width: 768px) {
  .hero-content {
    padding: 20px 40px 20px 60px !important;
    max-width: 100% !important;
    margin: 0 !important;
  }

  .hero-content-inner {
    max-width: 1200px;
    margin-left: 0;
  }

  .hero-main-title {
    font-size: 2.2rem !important;
  }

  .hero-subtitle {
    font-size: 1rem !important;
  }

  .hero-feature-item {
    font-size: 1rem !important;
    line-height: 2 !important;
  }
}

@media (min-width: 992px) {
  .mobile-menu-overlay-separator {
    display: none;
  }

  /* Desktop select improvements for better visibility */
  .booking-one__input-box select,
  .form-control {
    padding: 16px 20px !important;
    min-height: 58px !important;
    font-size: 1rem !important;
    line-height: 1.4 !important;
  }

  /* Extra space for location and hour selects */
  .booking-one__input-box select[name*="location"],
  .booking-one__input-box select[id*="location"],
  .booking-one__input-box select[name*="hour"],
  .booking-one__input-box select[id*="hour"] {
    padding: 18px 20px !important;
    min-height: 62px !important;
    font-size: 1.05rem !important;
    line-height: 1.5 !important;
  }

  .booking-one__input-box input {
    padding: 16px 20px !important;
    min-height: 58px !important;
    font-size: 1rem !important;
    line-height: 1.4 !important;
  }
}

/* Scroll to Top Button */
.scroll-top-btn {
  position: fixed;
  bottom: 30px;
  right: 30px;
  width: 50px;
  height: 50px;
  background: var(--mauno-base, #1a365d);
  color: white;
  border: none;
  border-radius: 50%;
  cursor: pointer;
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s ease;
  z-index: 999;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.scroll-top-btn.show {
  opacity: 1;
  visibility: visible;
}

.scroll-top-btn:hover {
  background: var(--mauno-primary, #ff6b35);
  transform: translateY(-3px);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.2);
}
