:root {
  --primary-navy: #0e1c36;
  --accent-red: #d90429;
  --accent-red-hover: #b80322;
  --bg-light: #f8f9fa;
  --text-dark: #222222;
  --text-muted: #555555;
  --white: #ffffff;
  --border-color: #e2e8f0;
  --font-main: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: var(--font-main);
  color: var(--text-dark);
  background-color: var(--white);
  line-height: 1.7;
}

a {
  text-decoration: none;
  color: inherit;
}

/* Top bar */
.topbar {
  background-color: var(--primary-navy);
  color: var(--white);
  padding: 8px 5%;
  font-size: 0.9rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
}
.topbar a {
  color: #ffb703;
  font-weight: 600;
}

/* --- Logo Default (Desktop) --- */
.logo-container {
  display: flex;
  align-items: center;
}

.logo-container img {
  height: 52px;          /* Clean desktop height */
  max-width: 200px;      /* Prevents horizontal stretching */
  width: auto;
  object-fit: contain;
  display: block;
}

/* --- Mobile Logo Sizing (Phones & Tablets) --- */
@media (max-width: 768px) {
  .logo-container img {
    height: 40px;        /* Compact height on mobile screens */
    max-width: 200px;    /* Prevents the logo from taking up excessive width */
  }

  /* Keeps the logo and hamburger icon aligned on the same row */
  .nav-container {
    padding: 10px 4%;
    display: flex;
    flex-direction: row !important;
    justify-content: space-between;
    align-items: center;
  }
}

@media (max-width: 380px) {
  .logo-container img {
    height: 45px;        /* Extra compact for small phones */
    max-width: 200px;
  }
}
/* ================= Mobile Menu & Navigation ================= */
.nav-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 5%;
  max-width: 1280px;
  margin: auto;
  position: relative;
}

/* Mobile Hamburger Button */
.mobile-menu-btn {
  display: none;
  background: none;
  border: none;
  font-size: 1.8rem;
  color: var(--primary-navy);
  cursor: pointer;
  padding: 5px;
}

/* Desktop Navigation */
.nav-links {
  display: flex;
  list-style: none;
  gap: 22px;
  align-items: center;
}

.nav-links li {
  position: relative;
}

.nav-links a {
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--primary-navy);
  text-decoration: none;
  padding: 8px 0;
  display: inline-block;
  transition: color 0.2s ease;
}

.nav-links a:hover,
.nav-links a.active {
  color: var(--accent-red);
}

/* Dropdown (Desktop) */
.dropdown-menu {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  background: var(--white);
  min-width: 220px;
  box-shadow: 0 4px 15px rgba(0,0,0,0.12);
  border-radius: 4px;
  list-style: none;
  padding: 8px 0;
  z-index: 100;
}

.dropdown:hover .dropdown-menu {
  display: block;
}

.dropdown-menu li a {
  display: block;
  padding: 10px 16px;
  color: var(--text-dark);
}

.dropdown-menu li a:hover {
  background-color: var(--bg-light);
  color: var(--accent-red);
}

/* Mobile Screen Adjustments (Tablets & Phones) */
@media (max-width: 860px) {
  .mobile-menu-btn {
    display: block; /* Show hamburger button */
  }

  .nav-links {
    display: none; /* Hidden by default on mobile */
    flex-direction: column;
    position: absolute;
    top: 100%;
    left: 0;
    width: 100%;
    background: #ffffff;
    box-shadow: 0 8px 20px rgba(0,0,0,0.15);
    padding: 15px 5%;
    gap: 0;
    z-index: 999;
    border-top: 1px solid var(--border-color);
  }

  /* When mobile toggle is clicked */
  .nav-links.show {
    display: flex;
  }

  .nav-links li {
    width: 100%;
    border-bottom: 1px solid #f1f5f9;
  }

  .nav-links a {
    display: block;
    padding: 12px 0;
    width: 100%;
  }

  /* Mobile Dropdown */
  .dropdown-menu {
    position: static;
    box-shadow: none;
    background: #f8fafc;
    padding: 0 0 0 15px;
    border-radius: 0;
  }

  .dropdown.open .dropdown-menu {
    display: block;
  }

  .header-btn {
    text-align: center;
    margin: 12px 0 6px 0;
  }
}

/* ================= Mobile-Optimized Slider ================= */
.slider-container {
  position: relative;
  overflow: hidden;
  width: 100%;
  max-width: 1200px;
  margin: 10px auto;
  background: #ffffff;
  border-radius: 8px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.06);
  height: auto !important; /* Forces container to fit image height */
}

.slider-track {
  position: relative;
  width: 100%;
  height: auto !important;
  min-height: unset !important; /* Removes any previous minimum height */
}

.slide {
  display: none;
  width: 100%;
  position: relative;
}

.slide.active {
  display: block;
}

/* Base image styling */
.slide img {
  width: 100%;
  height: auto;
  max-height: 380px;
  object-fit: contain;
  display: block;
  margin: 0 auto;
  background: #ffffff;
}

/* Call-to-action button positioned over the banner */
.slide-overlay-action {
  position: absolute;
  bottom: 12px;
  right: 4%;
  z-index: 5;
}

/* Slider Controls (Arrows) */
.slider-controls button {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(14, 28, 54, 0.6);
  border: none;
  color: #ffffff;
  font-size: 18px;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  cursor: pointer;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.3s ease;
}

.slider-controls button:hover {
  background: var(--accent-red);
}

.prev-btn { left: 10px; }
.next-btn { right: 10px; }

/* Dots */
.slider-dots {
  position: absolute;
  bottom: 6px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 6px;
  z-index: 10;
}

.dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: rgba(14, 28, 54, 0.3);
  cursor: pointer;
  transition: background 0.3s ease;
}

.dot.active {
  background: var(--accent-red);
}

/* ================= STRICT MOBILE FIX ================= */
@media (max-width: 768px) {
  .slider-container {
    margin: 5px auto;
    border-radius: 4px;
  }

  /* Locks image to proportional mobile banner height */
  .slide img {
    height: auto !important;
    max-height: 135px !important; /* Perfect height for 3:1 banners on phones */
    width: 100% !important;
    object-fit: contain;
  }

  /* Hide the overlay button on mobile so it doesn't push the height down */
  .slide-overlay-action {
    display: none;
  }

  /* Compact arrows so they don't cover the car */
  .slider-controls button {
    width: 26px;
    height: 26px;
    font-size: 12px;
    background: rgba(14, 28, 54, 0.45);
  }

  .prev-btn { left: 4px; }
  .next-btn { right: 4px; }

  .slider-dots {
    bottom: 3px;
  }

  .dot {
    width: 6px;
    height: 6px;
  }
}

@media (max-width: 420px) {
  .slide img {
    max-height: 115px !important; /* Extra small phones */
  }
}

.mobile-quick-call {
  display: none;
}
@media (max-width: 768px) {
  .mobile-quick-call {
    display: block;
    padding: 10px 5% 0;
  }
}

/* Dropdown */
.dropdown-menu {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  background: var(--white);
  min-width: 220px;
  box-shadow: 0 4px 15px rgba(0,0,0,0.12);
  border-radius: 4px;
  list-style: none;
  padding: 8px 0;
  z-index: 10;
}
.dropdown:hover .dropdown-menu {
  display: block;
}
.dropdown-menu li a {
  display: block;
  padding: 10px 16px;
  color: var(--text-dark);
  font-weight: 500;
}
.dropdown-menu li a:hover {
  background-color: var(--bg-light);
  color: var(--accent-red);
}

.header-btn {
  background-color: var(--accent-red);
  color: var(--white) !important;
  padding: 10px 20px !important;
  border-radius: 4px;
  transition: background 0.3s ease;
}
.header-btn:hover {
  background-color: var(--accent-red-hover) !important;
}

/* --- Slider Section --- */
.slider-container {
  position: relative;
  overflow: hidden;
  width: 100%;
  max-width: 1300px;
  margin: 15px auto 0;
  background: #ffffff;
  border-radius: 8px;
  box-shadow: 0 4px 18px rgba(0, 0, 0, 0.08);
}

.slider-track {
  position: relative;
  width: 100%;
  min-height: 260px;
}

.slide {
  display: none;
  width: 100%;
  position: relative;
  text-align: center;
}

.slide.active {
  display: block;
}

.slide img {
  width: 100%;
  height: auto;
  max-height: 440px;
  object-fit: contain;
  display: block;
  margin: 0 auto;
  background-color: #ffffff;
}

/* Floating booking button */
.slide-overlay-action {
  position: absolute;
  bottom: 22px;
  right: 5%;
  z-index: 5;
}

.slider-controls button {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(14, 28, 54, 0.65);
  border: none;
  color: #ffffff;
  font-size: 22px;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  cursor: pointer;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.3s ease;
}

.slider-controls button:hover {
  background: var(--accent-red);
}

.prev-btn { left: 15px; }
.next-btn { right: 15px; }

.slider-dots {
  position: absolute;
  bottom: 8px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 8px;
  z-index: 10;
}

.dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: rgba(14, 28, 54, 0.35);
  cursor: pointer;
  transition: background 0.3s ease;
}

.dot.active {
  background: var(--accent-red);
}

@media(max-width: 768px) {
  .slide-overlay-action {
    position: static;
    padding: 10px 0 16px;
  }
  .slider-controls button {
    width: 34px;
    height: 34px;
    font-size: 18px;
  }
}

/* Standard Section Layout */
.page-header {
  background: linear-gradient(135deg, var(--primary-navy), #1e3a8a);
  color: var(--white);
  padding: 60px 5%;
  text-align: center;
}
.page-header h1 {
  font-size: 2.5rem;
  margin-bottom: 10px;
}

.content-section {
  max-width: 1200px;
  margin: 60px auto;
  padding: 0 20px;
}
.content-section h2 {
  font-size: 2rem;
  color: var(--primary-navy);
  margin-bottom: 20px;
}
.content-section p {
  font-size: 1.05rem;
  color: var(--text-muted);
  margin-bottom: 20px;
}

/* Call to Action Box */
.cta-box {
  background: var(--bg-light);
  border-left: 5px solid var(--accent-red);
  padding: 30px;
  border-radius: 4px;
  margin: 40px 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 20px;
}
.btn-primary {
  background: var(--accent-red);
  color: white;
  padding: 12px 28px;
  border-radius: 4px;
  font-weight: 700;
  display: inline-block;
  transition: 0.3s ease;
}
.btn-primary:hover {
  background: var(--accent-red-hover);
}

/* Features Grid */
.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 24px;
  margin: 40px 0;
}
.feature-card {
  background: white;
  padding: 24px;
  border-radius: 6px;
  border: 1px solid var(--border-color);
  box-shadow: 0 4px 6px rgba(0,0,0,0.03);
}
.feature-card h3 {
  color: var(--primary-navy);
  margin-bottom: 12px;
}

/* Tariff Table */
.tariff-table {
  width: 100%;
  border-collapse: collapse;
  margin: 30px 0;
}
.tariff-table th, .tariff-table td {
  border: 1px solid var(--border-color);
  padding: 14px 18px;
  text-align: left;
}
.tariff-table th {
  background: var(--primary-navy);
  color: white;
}
.tariff-table tr:nth-child(even) {
  background: var(--bg-light);
}

/* Forms */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
}
.contact-form input, .contact-form textarea, .contact-form select {
  width: 100%;
  padding: 12px;
  margin-bottom: 15px;
  border: 1px solid var(--border-color);
  border-radius: 4px;
  font-family: inherit;
}

/* Footer */
footer {
  background: var(--primary-navy);
  color: #cbd5e1;
  padding: 60px 5% 20px;
}
.footer-grid {
  max-width: 1200px;
  margin: auto;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 40px;
}
.footer-col h4 {
  color: white;
  font-size: 1.2rem;
  margin-bottom: 18px;
}
.footer-col ul {
  list-style: none;
}
.footer-col ul li {
  margin-bottom: 10px;
}
.footer-col ul li a:hover {
  color: var(--accent-red);
}
.footer-bottom {
  text-align: center;
  border-top: 1px solid #1e293b;
  margin-top: 40px;
  padding-top: 20px;
  font-size: 0.9rem;
}

@media(max-width: 768px) {
  .nav-container { flex-direction: column; gap: 15px; }
  .nav-links { flex-wrap: wrap; justify-content: center; gap: 12px; }
  .slider-container { height: 380px; }
  .slide-content h1 { font-size: 1.8rem; }
  .contact-grid { grid-template-columns: 1fr; }
}

/* ================= Landing Page Enhancements ================= */
.landing-hero {
  background: linear-gradient(135deg, rgba(14, 28, 54, 0.92), rgba(14, 28, 54, 0.85)), 
              url('images/Car-Hire-Chennai-Self-Drive.jpg') center/cover no-repeat;
  color: #fff;
  padding: 60px 5%;
}
.landing-hero-grid {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 40px;
  align-items: center;
}
.hero-tag {
  display: inline-block;
  background: var(--accent-red);
  color: #fff;
  font-size: 0.85rem;
  font-weight: 700;
  text-transform: uppercase;
  padding: 6px 14px;
  border-radius: 50px;
  margin-bottom: 15px;
  letter-spacing: 0.5px;
}
.landing-hero h1 {
  font-size: 2.5rem;
  line-height: 1.2;
  margin-bottom: 16px;
  color: #ffffff;
}
.landing-hero p {
  font-size: 1.05rem;
  color: #e2e8f0;
  margin-bottom: 25px;
}
.hero-highlights {
  display: flex;
  gap: 20px;
  flex-wrap: wrap;
}
.highlight-item {
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(4px);
  padding: 10px 16px;
  border-radius: 6px;
  font-size: 0.9rem;
  font-weight: 600;
  border: 1px solid rgba(255, 255, 255, 0.2);
}

/* Hero Quick Form Card */
.hero-quick-form {
  background: #ffffff;
  color: var(--text-dark);
  padding: 30px;
  border-radius: 8px;
  box-shadow: 0 10px 30px rgba(0,0,0,0.25);
}
.hero-quick-form h3 {
  color: var(--primary-navy);
  margin-bottom: 5px;
  font-size: 1.3rem;
}
.hero-quick-form p {
  color: var(--text-muted);
  font-size: 0.85rem;
  margin-bottom: 18px;
}
.form-compact {
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.form-compact input, .form-compact select {
  padding: 10px 12px;
  border: 1px solid var(--border-color);
  border-radius: 4px;
  font-family: inherit;
  font-size: 0.9rem;
}

/* Vehicle Cards Grid */
.car-fleet-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 24px;
  margin: 35px 0;
}
.car-card {
  border: 1px solid var(--border-color);
  border-radius: 8px;
  overflow: hidden;
  background: #fff;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.car-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 10px 20px rgba(0,0,0,0.08);
}
.car-card-img {
  width: 100%;
  height: 180px;
  background: #f1f5f9;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}
.car-card-img img {
  width: 90%;
  height: auto;
  max-height: 160px;
  object-fit: contain;
}
.car-card-body {
  padding: 20px;
}
.car-card-body h4 {
  font-size: 1.2rem;
  color: var(--primary-navy);
  margin-bottom: 6px;
}
.car-card-meta {
  color: var(--text-muted);
  font-size: 0.85rem;
  margin-bottom: 14px;
}
.car-card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-top: 1px solid var(--border-color);
  padding-top: 14px;
}
.car-price {
  font-size: 1.15rem;
  font-weight: 800;
  color: var(--accent-red);
}
.car-price span {
  font-size: 0.8rem;
  font-weight: normal;
  color: var(--text-muted);
}

/* Destinations Grid */
.dest-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 20px;
  margin: 30px 0;
}
.dest-card {
  background: var(--bg-light);
  border-left: 4px solid var(--primary-navy);
  padding: 20px;
  border-radius: 4px;
}
.dest-card h4 {
  color: var(--primary-navy);
  margin-bottom: 8px;
}
.dest-card p {
  margin: 0;
  font-size: 0.9rem;
}

/* Steps Block */
.steps-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 20px;
  margin: 35px 0;
  text-align: center;
}
.step-item {
  padding: 24px 16px;
  background: #ffffff;
  border: 1px solid var(--border-color);
  border-radius: 8px;
}
.step-number {
  width: 44px;
  height: 44px;
  background: var(--accent-red);
  color: #fff;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 14px;
  font-weight: 800;
  font-size: 1.1rem;
}

/* Responsive adjustments */
@media (max-width: 860px) {
  .landing-hero-grid {
    grid-template-columns: 1fr;
  }
  .landing-hero h1 {
    font-size: 2rem;
  }
}

/* ================= Floating Enquiry & Popup Widget ================= */

/* Floating Launcher Button (Desktop) */
.floating-enquiry-btn {
  position: fixed;
  bottom: 25px;
  right: 25px;
  background: var(--accent-red);
  color: #ffffff;
  padding: 12px 22px;
  border-radius: 50px;
  font-weight: 700;
  font-size: 0.95rem;
  box-shadow: 0 6px 20px rgba(217, 4, 41, 0.4);
  cursor: pointer;
  z-index: 999;
  display: flex;
  align-items: center;
  gap: 8px;
  border: none;
  transition: transform 0.2s ease, background 0.2s ease;
}
.floating-enquiry-btn:hover {
  transform: translateY(-3px);
  background: var(--accent-red-hover);
}

/* Modal Backdrop */
.popup-modal-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(14, 28, 54, 0.7);
  backdrop-filter: blur(4px);
  z-index: 10000;
  align-items: center;
  justify-content: center;
  padding: 15px;
}
.popup-modal-overlay.active {
  display: flex;
}

/* Modal Content Card */
.popup-modal-content {
  background: #ffffff;
  width: 100%;
  max-width: 440px;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 15px 35px rgba(0, 0, 0, 0.25);
  animation: modalFadeIn 0.3s ease;
  position: relative;
}
@keyframes modalFadeIn {
  from { opacity: 0; transform: translateY(15px); }
  to { opacity: 1; transform: translateY(0); }
}

.popup-header {
  background: var(--primary-navy);
  color: #ffffff;
  padding: 16px 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.popup-header h3 {
  margin: 0;
  font-size: 1.15rem;
}
.popup-close-btn {
  background: none;
  border: none;
  color: #ffffff;
  font-size: 1.6rem;
  cursor: pointer;
  line-height: 1;
}

.popup-body {
  padding: 20px;
}
.popup-body .form-group {
  margin-bottom: 12px;
}
.popup-body label {
  display: block;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--primary-navy);
  margin-bottom: 4px;
}
.popup-body input, 
.popup-body select {
  width: 100%;
  padding: 9px 12px;
  border: 1px solid var(--border-color);
  border-radius: 4px;
  font-family: inherit;
  font-size: 0.9rem;
}

/* Fixed Mobile Sticky Bar */
.mobile-sticky-bar {
  display: none;
}

@media (max-width: 768px) {
  /* Hide the round desktop button on phones */
  .floating-enquiry-btn {
    display: none;
  }

  /* Show dual-action bottom bar on mobile */
  .mobile-sticky-bar {
    display: flex;
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 54px;
    background: #ffffff;
    box-shadow: 0 -3px 12px rgba(0, 0, 0, 0.12);
    z-index: 999;
  }
  .mobile-sticky-bar a,
  .mobile-sticky-bar button {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.9rem;
    font-weight: 700;
    border: none;
    text-decoration: none;
    cursor: pointer;
  }
  .sticky-call {
    background: var(--primary-navy);
    color: #ffffff !important;
  }
  .sticky-enquire {
    background: var(--accent-red);
    color: #ffffff !important;
  }
}