@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&display=swap');

:root {
  --primary: #593CFB;
  --primary-hover: #4829EB;
  --black: #121214;
  --dark-gray: #4A4A52;
  --light-gray: #E0E0E6;
  --bg-color: #F4F4F8;
  --white: #FFFFFF;
  --radius: 12px;
  --shadow-sm: 0 4px 12px rgba(0, 0, 0, 0.05);
  --shadow-md: 0 8px 24px rgba(0, 0, 0, 0.08);
  --shadow-lg: 0 12px 32px rgba(0, 0, 0, 0.12);
  --transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: 'Inter', -apple-system, sans-serif;
  background-color: var(--white);
  color: var(--black);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

/* Typography */
h1,
h2,
h3,
h4,
h5,
h6 {
  font-weight: 700;
  color: var(--black);
}

p {
  color: var(--dark-gray);
}

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

/* Layout */
.container {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 24px;
}

/* Button */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 24px;
  border-radius: 8px;
  font-weight: 600;
  font-size: 16px;
  cursor: pointer;
  transition: var(--transition);
  border: none;
}

.btn-primary {
  background-color: var(--primary);
  color: var(--white);
}

.btn-primary:hover {
  background-color: var(--primary-hover);
  transform: translateY(-1px);
}

.btn-outline {
  background-color: transparent;
  border: 1px solid var(--light-gray);
  color: var(--black);
}

.btn-outline:hover {
  border-color: var(--black);
}

/* Header Navbar */
header {
  border-bottom: 1px solid var(--light-gray);
  position: sticky;
  top: 0;
  background-color: var(--white);
  z-index: 100;
}

.navbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  height: 80px;
}

.logo {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
}

.logo-mark {
  width: 40px;
  height: 40px;
  background: var(--primary);
  color: var(--white);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  font-weight: 800;
  font-style: italic;
  box-shadow: 0 4px 12px rgba(89, 60, 251, 0.3);
}

.logo-text {
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.brand-name {
  font-size: 20px;
  font-weight: 800;
  color: var(--black);
  line-height: 1;
  letter-spacing: -0.5px;
}

.brand-desc {
  font-size: 11px;
  font-weight: 600;
  color: var(--dark-gray);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-top: 2px;
}

.nav-links {
  display: flex;
  gap: 32px;
  list-style: none;
}

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

/* Social Links Header */
.social-links {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-right: 8px;
}

.social-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--white);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  transition: var(--transition);
  text-decoration: none;
}

.social-icon.facebook {
  color: #1877F2;
}

.social-icon.google-maps {
  color: #EA4335;
}

.social-icon:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
}

.social-icon.facebook:hover {
  background: #1877F2;
  color: var(--white);
}

.social-icon.google-maps:hover {
  background: #EA4335;
  color: var(--white);
}

.social-icon svg {
  width: 20px;
  height: 20px;
}

.user-item {
  position: relative;
}

.profile-dropdown {
  position: absolute;
  top: calc(100% + 12px);
  right: 0;
  background: var(--white);
  border: 1px solid var(--light-gray);
  border-radius: 12px;
  box-shadow: var(--shadow-md);
  min-width: 180px;
  display: none;
  flex-direction: column;
  padding: 8px;
  z-index: 200;
}

.profile-dropdown.show {
  display: flex;
}

.dropdown-item {
  padding: 10px 16px;
  font-size: 14px;
  font-weight: 500;
  color: var(--dark-gray);
  border-radius: 8px;
  display: flex;
  align-items: center;
  gap: 10px;
  transition: var(--transition);
}

.dropdown-item:hover {
  background: #f3f4f6;
  color: var(--black);
}

.dropdown-divider {
  height: 1px;
  background: var(--light-gray);
  margin: 8px 0;
}

/* User Profile Header */
.user-profile {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 6px 16px;
  background: #f3f4f6;
  border-radius: 100px;
  color: var(--black);
  font-weight: 600;
  font-size: 14px;
  transition: var(--transition);
  cursor: pointer;
}

.user-profile:hover {
  background: #e5e7eb;
}

.user-avatar {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  object-fit: cover;
  background: var(--light-gray);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.user-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.user-avatar span {
  font-size: 16px;
  font-weight: 700;
  color: var(--dark-gray);
}

.nav-links li {
  display: flex;
  align-items: center;
  gap: 15px;
}

.nav-logout-btn {
  background: #ef4444;
  color: white !important;
  padding: 6px 16px;
  border-radius: 100px;
  font-size: 13px;
  font-weight: 700;
  text-decoration: none;
  transition: var(--transition);
}

.nav-logout-btn:hover {
  background: #dc2626;
  transform: translateY(-1px);
  box-shadow: 0 4px 6px rgba(220, 38, 38, 0.2);
}

.my-trips-capsule {
  background: var(--primary);
  color: white !important;
  padding: 8px 20px;
  border-radius: 100px;
  font-size: 14px;
  font-weight: 700;
  text-decoration: none;
  transition: var(--transition);
  display: inline-flex;
  align-items: center;
  gap: 8px;
  box-shadow: 0 4px 12px rgba(89, 60, 251, 0.3);
}

.my-trips-capsule:hover {
  background: var(--primary-hover);
  transform: translateY(-1px);
  box-shadow: 0 6px 16px rgba(89, 60, 251, 0.4);
}

/* Success Actions */
.success-actions {
  margin-top: 32px;
  display: flex;
  justify-content: center;
  gap: 16px;
}

.btn-manage-trips {
  background: var(--primary);
  color: white;
  padding: 14px 28px;
  border-radius: 12px;
  font-weight: 700;
  font-size: 16px;
  transition: var(--transition);
  display: inline-flex;
  align-items: center;
  gap: 10px;
  box-shadow: 0 4px 12px rgba(89, 60, 251, 0.3);
}

.btn-manage-trips:hover {
  background: var(--primary-hover);
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(89, 60, 251, 0.4);
}

/* Hero Section */
.hero {
  padding: 100px 0;
  text-align: center;
  background-image: linear-gradient(rgba(0, 0, 0, 0.4), rgba(0, 0, 0, 0.6)), url('../images/hero-oregon-coast.png');
  background-size: cover;
  background-position: center;
  color: var(--white);
}

.hero h1 {
  font-size: 56px;
  line-height: 1.1;
  margin-bottom: 24px;
  letter-spacing: -1.5px;
  color: var(--white);
  text-shadow: 0 2px 12px rgba(0, 0, 0, 0.3);
}

.hero p {
  font-size: 20px;
  max-width: 600px;
  margin: 0 auto 40px;
  color: var(--white);
  text-shadow: 0 1px 4px rgba(0, 0, 0, 0.5);
}

/* Search Bar Mockup */
.search-bar {
  display: flex;
  background: var(--white);
  border-radius: 100px;
  padding: 8px;
  width: 100%;
  max-width: 800px;
  margin: 0 auto;
  box-shadow: var(--shadow-md);
  align-items: center;
  gap: 16px;
}

.search-input {
  flex: 1;
  display: flex;
  flex-direction: column;
  padding: 12px 16px;
  border-right: 1px solid var(--light-gray);
  text-align: left;
  min-width: 0;
}

.search-input:last-of-type {
  border-right: none;
}

.search-input label {
  font-size: 12px;
  font-weight: 700;
  margin-bottom: 4px;
  color: var(--black);
  text-transform: uppercase;
}

.search-input span {
  font-size: 16px;
  color: var(--dark-gray);
}

.time-select {
  padding: 8px 8px;
  border-radius: 8px;
  background-color: var(--bg-color);
  color: var(--black);
  cursor: pointer;
  transition: var(--transition);
  font-weight: 500;
  width: 100%;
  min-width: 90px;
}

.time-select:hover {
  background-color: var(--light-gray);
}

.time-select:focus {
  outline: 2px solid var(--primary);
  background-color: var(--white);
}

.search-btn {
  background-color: var(--primary);
  color: var(--white);
  border: none;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: var(--transition);
}

.search-btn:hover {
  background-color: var(--primary-hover);
  transform: scale(1.05);
}

/* Vehicles Grid */
.cars-section {
  padding: 80px 0;
  background-color: var(--white);
}

.cars-header {
  margin-bottom: 40px;
}

.cars-header h2 {
  font-size: 32px;
}

.grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 32px;
}

/* Car Card */
.car-card {
  border-radius: 20px;
  overflow: hidden;
  transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
  cursor: pointer;
  border: 1px solid rgba(0, 0, 0, 0.05);
  background: var(--white);
  display: flex;
  flex-direction: column;
  height: 100%;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05), 0 2px 4px -1px rgba(0, 0, 0, 0.03);
}

.car-card:hover {
  box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
  transform: translateY(-8px);
}

.car-image-wrapper {
  position: relative;
  padding-top: 62%;
  background-color: #f8fafc;
  overflow: hidden;
}

.car-image {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.8s cubic-bezier(0.165, 0.84, 0.44, 1);
}

.car-card:hover .car-image {
  transform: scale(1.08);
}

.car-details {
  padding: 24px;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.car-title {
  font-size: 20px;
  font-weight: 800;
  margin-bottom: 6px;
  color: #1e293b;
  letter-spacing: -0.5px;
}

.car-subtitle {
  font-size: 13px;
  font-weight: 600;
  color: #64748b;
  margin-bottom: 16px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.car-specs {
  display: flex;
  gap: 20px;
  font-size: 14px;
  color: #475569;
  margin-bottom: 20px;
  padding: 12px 0;
  border-top: 1px solid #f1f5f9;
  border-bottom: 1px solid #f1f5f9;
}

.spec-item {
  display: flex;
  align-items: center;
  gap: 6px;
  font-weight: 500;
}

.spec-highlight {
  color: #059669;
  font-weight: 700;
}

.car-features {
  display: none;
  /* Hide features to unclutter the main grid */
}

.car-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: auto;
}

.car-price {
  display: flex;
  align-items: baseline;
  gap: 2px;
}

.car-price .amount {
  font-size: 26px;
  font-weight: 900;
  color: #0f172a;
}

.car-price .unit {
  font-size: 14px;
  font-weight: 600;
  color: #64748b;
}

.btn-book-now {
  background-color: #0f172a;
  color: white;
  font-weight: 700;
  padding: 12px 24px;
  border-radius: 12px;
  border: none;
  cursor: pointer;
  font-size: 14px;
  transition: all 0.3s ease;
}

.btn-book-now:hover {
  background-color: #334155;
  transform: scale(1.05);
}

/* Badges styling */
.car-rating {
  background: var(--white);
  padding: 6px 12px;
  border-radius: 8px;
  font-weight: 700;
  font-size: 14px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.car-rating .review-count {
  color: var(--dark-gray);
  font-weight: 400;
}

.badge-electric {
  position: absolute;
  top: 12px;
  left: 12px;
  background-color: #16a34a;
  color: var(--white);
  padding: 6px 12px;
  border-radius: 100px;
  font-size: 13px;
  font-weight: 600;
  z-index: 10;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.top-right-badges {
  position: absolute;
  top: 12px;
  right: 12px;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 8px;
  z-index: 10;
}

/* Default position if single */
.car-image-wrapper>.car-rating {
  position: absolute;
  top: 12px;
  right: 12px;
  z-index: 10;
}

.badge-fsd {
  background: rgba(0, 0, 0, 0.7);
  color: var(--white);
  padding: 2px 6px;
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.5px;
  border-radius: 4px;
  text-transform: uppercase;
}

/* Footer */
footer {
  background-color: var(--bg-color);
  padding: 60px 0;
  border-top: 1px solid var(--light-gray);
}

.footer-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.footer-logo {
  font-size: 20px;
  font-weight: 700;
  color: var(--black);
}

.footer-links {
  display: flex;
  gap: 24px;
}

.footer-links a {
  color: var(--dark-gray);
  font-size: 14px;
}

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

/* Badge (Sold or Unavailable) */
.badge {
  position: absolute;
  top: 12px;
  left: 12px;
  background-color: var(--black);
  color: var(--white);
  padding: 4px 12px;
  border-radius: 100px;
  font-size: 12px;
  font-weight: 600;
  z-index: 10;
}

/* Utilities */
.hidden {
  display: none !important;
}

/* Responsive adjustments */
@media (max-width: 768px) {
  .container {
    padding: 0 16px;
  }

  .navbar {
    flex-direction: column;
    height: auto;
    padding: 16px 0;
    gap: 16px;
  }

  .logo-mark {
    width: 32px;
    height: 32px;
    font-size: 20px;
    border-radius: 8px;
  }

  .brand-name {
    font-size: 18px;
  }

  .brand-desc {
    font-size: 10px;
  }

  .nav-links {
    gap: 16px;
    flex-wrap: wrap;
    justify-content: center;
  }

  .hero {
    padding: 60px 0;
  }

  .hero h1 {
    font-size: 36px;
  }

  .hero p {
    font-size: 16px;
  }

  .grid {
    grid-template-columns: 1fr;
  }

  .search-bar {
    flex-direction: column;
    border-radius: 16px;
    padding: 12px;
  }

  .search-input {
    width: 100%;
    border-right: none;
    border-bottom: 1px solid var(--light-gray);
    padding: 12px 16px;
  }

  .search-input:last-of-type {
    border-bottom: none;
  }

  .search-btn {
    width: 100%;
    border-radius: 12px;
    margin-top: 8px;
  }
}

/* WhatsApp Floating Action Button */
.whatsapp-fab {
  position: fixed;
  bottom: 24px;
  right: 24px;
  background-color: #25D366;
  color: white;
  width: 60px;
  height: 60px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 32px;
  box-shadow: var(--shadow-lg);
  z-index: 1000;
  cursor: pointer;
  transition: var(--transition);
  text-decoration: none;
}

.whatsapp-fab:hover {
  transform: scale(1.1) translateY(-4px);
  background-color: #1EBE55;
  box-shadow: 0 16px 40px rgba(37, 211, 102, 0.4);
}

.whatsapp-fab svg {
  width: 32px;
  height: 32px;
  fill: currentColor;
}