

:root {
  color-scheme: light;
  --bg: #f1f5f9;
  --bg-soft: #e8f4ef;
  --bg-elevated: #ffffff;
  --bg-card: #ffffff;
  --border: rgba(15, 23, 42, 0.08);
  --text: #0f172a;
  --text-muted: #64748b;
  --accent: #16a34a;
  --accent-hover: #15803d;
  --accent-dim: rgba(22, 163, 74, 0.12);
  --danger: #dc2626;
  --radius: 12px;
  --radius-sm: 8px;
  --shadow: 0 4px 24px rgba(15, 23, 42, 0.06), 0 1px 3px rgba(15, 23, 42, 0.04);
  --shadow-md: 0 12px 40px rgba(15, 23, 42, 0.08);
  --font: "DM Sans", system-ui, sans-serif;
  --transition: 0.2s ease;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: var(--font);
  background: linear-gradient(165deg, var(--bg-soft) 0%, var(--bg) 45%, #eef2f7 100%);
  color: var(--text);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  position: relative;
  overflow-x: hidden;
}

.bg-photo {
  position: fixed;
  inset: 0;
  z-index: -4;
  pointer-events: none;
  background-image: linear-gradient(
      120deg,
      rgba(255, 255, 255, 0.92) 0%,
      rgba(241, 245, 249, 0.88) 40%,
      rgba(232, 244, 239, 0.85) 100%
    ),
    url("https://images.unsplash.com/photo-1449965408869-eaa3f722e40d?auto=format&fit=crop&w=1920&q=80");
  background-size: cover;
  background-position: center 35%;
  opacity: 0.45;
}

.bg-orb {
  position: fixed;
  border-radius: 999px;
  filter: blur(72px);
  z-index: -2;
  pointer-events: none;
}

.bg-orb-1 {
  width: 380px;
  height: 380px;
  background: rgba(34, 197, 94, 0.22);
  top: -100px;
  left: -100px;
}

.bg-orb-2 {
  width: 420px;
  height: 420px;
  background: rgba(125, 211, 252, 0.35);
  right: -140px;
  bottom: -100px;
}

.bg-grid {
  position: fixed;
  inset: 0;
  z-index: -3;
  pointer-events: none;
  background-image: linear-gradient(rgba(148, 163, 184, 0.12) 1px, transparent 1px),
    linear-gradient(90deg, rgba(148, 163, 184, 0.12) 1px, transparent 1px);
  background-size: 48px 48px;
  mask-image: radial-gradient(ellipse 85% 70% at 50% 0%, black 0%, transparent 72%);
  opacity: 0.6;
}

/* Header / navbar */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 255, 255, 0.82);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--border);
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.8) inset;
}

.header-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0.75rem 1.25rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.logo {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  text-decoration: none;
  color: var(--text);
  font-weight: 700;
  font-size: 1.125rem;
  transition: opacity var(--transition);
}

.logo:hover {
  opacity: 0.9;
}

.logo-mark {
  width: 36px;
  height: 36px;
  border-radius: var(--radius-sm);
  background: linear-gradient(135deg, var(--accent), var(--accent-hover));
  color: #ffffff;
  display: grid;
  place-items: center;
  font-weight: 800;
  box-shadow: 0 2px 8px rgba(22, 163, 74, 0.25);
}

.logo-text .accent {
  color: var(--accent);
}

.main-nav {
  display: none;
  align-items: center;
  gap: 0.25rem;
}

@media (min-width: 768px) {
  .main-nav {
    display: flex;
  }
}

.nav-link {
  background: transparent;
  border: none;
  color: var(--text-muted);
  font-family: inherit;
  font-size: 0.9375rem;
  font-weight: 500;
  padding: 0.5rem 0.875rem;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: color var(--transition), background var(--transition);
}

.nav-link:hover {
  color: var(--text);
  background: rgba(15, 23, 42, 0.05);
}

.nav-link.active {
  color: var(--accent);
  background: var(--accent-dim);
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.profile-dropdown {
  position: relative;
}

.profile-circle {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--accent);
  color: white;
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 600;
  font-size: 1rem;
  transition: background var(--transition);
}

.profile-circle:hover {
  background: var(--accent-hover);
}

.profile-menu {
  position: absolute;
  top: 100%;
  right: 0;
  margin-top: 0.5rem;
  background: white;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.1);
  min-width: 120px;
  z-index: 100;
}

.profile-menu-item {
  display: block;
  width: 100%;
  padding: 0.75rem 1rem;
  background: none;
  border: none;
  text-align: left;
  cursor: pointer;
  font-size: 0.875rem;
  color: var(--text);
  transition: background var(--transition);
}

.profile-menu-item:hover {
  background: var(--bg-muted);
}

.user-email {
  display: none;
  max-width: 160px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 0.8125rem;
  color: var(--text-muted);
}

@media (min-width: 480px) {
  .user-email {
    display: inline;
  }
}

.btn {
  font-family: inherit;
  font-size: 0.875rem;
  font-weight: 600;
  padding: 0.5rem 1rem;
  border-radius: var(--radius-sm);
  border: none;
  cursor: pointer;
  transition: background var(--transition), color var(--transition), transform 0.15s ease, box-shadow var(--transition);
}

.btn:hover {
  filter: brightness(1.02);
}

.btn:active {
  transform: translateY(1px);
}

.btn:disabled,
.btn[disabled] {
  opacity: 0.6;
  cursor: not-allowed;
  filter: none;
  transform: none;
}

.btn-primary {
  background: var(--accent);
  color: #ffffff;
}

.btn-primary:hover {
  background: var(--accent-hover);
  box-shadow: 0 4px 16px rgba(22, 163, 74, 0.3);
}

.btn-ghost {
  background: transparent;
  color: var(--text-muted);
}

.btn-ghost:hover {
  color: var(--text);
  background: rgba(15, 23, 42, 0.06);
}

.btn-cancel {
  color: var(--danger);
  border: 1px solid rgba(220, 38, 38, 0.25);
}

.btn-cancel:hover {
  color: #991b1b;
  background: rgba(220, 38, 38, 0.10);
  border-color: rgba(220, 38, 38, 0.35);
}

.btn-outline {
  background: transparent;
  color: var(--accent);
  border: 1px solid var(--accent);
}

.btn-outline:hover {
  background: var(--accent-dim);
}

.btn-block {
  width: 100%;
  padding: 0.75rem 1rem;
}

.nav-toggle {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 40px;
  height: 40px;
  padding: 0;
  background: transparent;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  cursor: pointer;
}

.nav-toggle span {
  display: block;
  height: 2px;
  background: var(--text);
  border-radius: 1px;
  margin: 0 8px;
}

@media (min-width: 768px) {
  .nav-toggle {
    display: none;
  }
}

.mobile-nav {
  display: flex;
  flex-direction: column;
  padding: 0 1rem 1rem;
  gap: 0.25rem;
  border-top: 1px solid var(--border);
}

.mobile-nav[hidden] {
  display: none;
}

@media (min-width: 768px) {
  .mobile-nav {
    display: none !important;
  }
}

.mobile-nav .nav-link {
  text-align: left;
  width: 100%;
}

.hidden {
  display: none !important;
}

/* Main */
.main-content {
  position: relative;
  max-width: 1200px;
  margin: 0 auto;
  padding: 2rem 1.25rem 4rem;
}

.page-section {
  display: none;
  animation: fadeIn 0.35s ease;
}

.page-section.active {
  display: block;
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.section-head {
  margin-bottom: 2rem;
}

.hero-strip {
  margin-bottom: 1.5rem;
  display: grid;
  gap: 0.9rem;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  padding: 1rem;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.95), rgba(232, 244, 239, 0.65));
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
}

 .hero-strip--plain {
   padding: 0;
   background: transparent;
   border: none;
   box-shadow: none;
 }

 .hero-strip--plain .hero-item {
   background: transparent;
   border: 1px solid var(--border);
 }

.hero-item {
  padding: 0.9rem;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.75);
}

.hero-label {
  margin: 0 0 0.35rem;
  color: var(--text-muted);
  font-size: 0.8125rem;
}

.hero-item h3 {
  margin: 0;
  font-size: 1rem;
  color: var(--text);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.75rem;
  margin: 0.25rem 0 1.5rem;
}

.hero-action-hint {
  margin: 0;
  color: var(--text-muted);
  font-size: 0.875rem;
}

.shop-page-card {
  max-width: 720px;
  padding: 0;
  overflow: hidden;
}

 .shop-page-card--plain {
   background: transparent;
   border: none;
   box-shadow: none;
   overflow: visible;
   max-width: 900px;
 }

 .shop-page-card--plain .shop-page-block {
   background: transparent;
 }

 .shop-settings-form {
   max-width: 900px;
   padding: 1.5rem;
   margin-bottom: 1.5rem;
 }

 .shop-settings-title {
   margin: 0 0 0.35rem;
 }

 .shop-settings-grid {
   margin-top: 1rem;
   display: grid;
   gap: 0.9rem;
   grid-template-columns: repeat(2, minmax(0, 1fr));
 }

 @media (max-width: 700px) {
   .shop-settings-grid {
     grid-template-columns: 1fr;
   }
 }

 .shop-settings-form label {
   display: block;
   font-size: 0.875rem;
   font-weight: 500;
   color: var(--text-muted);
 }

 .shop-settings-form input {
   margin-top: 0.35rem;
   width: 100%;
   padding: 0.65rem 0.85rem;
   border-radius: var(--radius-sm);
   border: 1px solid var(--border);
   background: var(--bg);
   color: var(--text);
   font-family: inherit;
   font-size: 1rem;
 }

 .shop-settings-form input:focus {
   outline: none;
   border-color: var(--accent);
   box-shadow: 0 0 0 3px var(--accent-dim);
 }

.shop-page-inner {
  display: grid;
  gap: 0;
  grid-template-columns: 1fr;
}

@media (min-width: 640px) {
  .shop-page-inner {
    grid-template-columns: 1.2fr 1fr;
  }
}

.shop-page-block {
  padding: 1.5rem 1.75rem;
  border-bottom: 1px solid var(--border);
}

@media (min-width: 640px) {
  .shop-page-block {
    border-bottom: none;
    border-right: 1px solid var(--border);
  }
  .shop-page-hours {
    border-right: none;
  }
}

.shop-page-label {
  margin: 0 0 0.5rem;
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--accent);
  font-weight: 600;
}

.shop-page-strong {
  margin: 0 0 0.75rem;
  line-height: 1.45;
  font-size: 1.05rem;
}

.shop-location-hint {
  margin: 0 0 0.75rem;
  font-size: 0.875rem;
  color: var(--text-muted);
}

.shop-page-text {
  margin: 0 0 0.35rem;
  color: var(--text);
}

.shop-page-text.muted {
  color: var(--text-muted);
  font-size: 0.875rem;
}

.shop-map-link {
  color: var(--accent);
  font-weight: 600;
  text-decoration: none;
}

.shop-map-link:hover {
  text-decoration: underline;
}

.payment-options {
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
  margin: 1rem 0;
}

.modal-cash .cash-copy {
  margin: 0 0 1rem;
  color: var(--text-muted);
  font-size: 0.9375rem;
}

.shop-box {
  padding: 1rem;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: linear-gradient(180deg, #f8fafc 0%, #f1f5f9 100%);
  margin-bottom: 1.25rem;
}

.shop-box-label {
  margin: 0 0 0.35rem;
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-muted);
}

.shop-box-text {
  margin: 0 0 0.5rem;
  line-height: 1.45;
}

.section-head h1,
.section-head h2 {
  margin: 0 0 0.5rem;
  font-size: clamp(1.75rem, 4vw, 2.25rem);
  font-weight: 700;
  letter-spacing: -0.02em;
}

.lead {
  margin: 0;
  color: var(--text-muted);
  font-size: 1rem;
}

/* Car grid */
.cars-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(220px, 1fr));
  gap: 1.5rem;
}

@media (max-width: 1200px) {
  .cars-grid {
    grid-template-columns: repeat(2, minmax(220px, 1fr));
  }
}

@media (max-width: 700px) {
  .cars-grid {
    grid-template-columns: 1fr;
  }
}

.car-card {
  background: var(--bg-card);
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
  transition: transform var(--transition), border-color var(--transition), box-shadow var(--transition);
}

.car-card-image {
  width: 100%;
  height: 180px;
  background: #f3f7f9;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.car-card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.car-details-gallery {
  position: relative;
  margin: 1rem 0;
  text-align: center;
}

 .car-details-availability {
   margin: 0.5rem 0 0.25rem;
 }

.car-details-gallery img {
  width: 100%;
  border-radius: var(--radius);
  max-height: 300px;
  object-fit: cover;
  display: block;
}

.gallery-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 2.2rem;
  height: 2.2rem;
  border: 1px solid var(--border);
  border-radius: 50%;
  background: var(--bg-card);
  cursor: pointer;
}

.gallery-prev { left: 0.5rem; }
.gallery-next { right: 0.5rem; }

.car-details-description { margin: 0.75rem 0; }
.car-details-price { font-weight: 700; margin: 0.25rem 0 1rem; }
.car-details-link { display: inline-block; margin-bottom: 1rem; color: var(--accent); font-weight: 600; }

.car-card:hover {
  transform: translateY(-4px);
  border-color: rgba(22, 163, 74, 0.35);
  box-shadow: var(--shadow-md);
}

.car-card-body {
  padding: 1.25rem;
}

.car-card-title {
  margin: 0 0 0.5rem;
  font-size: 1.125rem;
  font-weight: 600;
}

.car-card-price {
  margin: 0 0 1rem;
  color: var(--accent);
  font-size: 1.25rem;
  font-weight: 700;
}

.car-card-price small {
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--text-muted);
}

.car-category-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin: 1rem 0 1.25rem;
}

.category-btn {
  padding: 0.35rem 0.75rem;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--bg-card);
  color: var(--text);
  font-size: 0.8rem;
  cursor: pointer;
  transition: background var(--transition), border-color var(--transition);
}

.category-btn.active,
.category-btn:hover {
  background: var(--accent-dim);
  border-color: var(--accent);
  color: var(--accent);
}

.car-card-category {
  margin: 0 0 0.5rem;
  color: var(--text-muted);
  font-size: 0.75rem;
  letter-spacing: 0.02em;
  text-transform: uppercase;
}

.empty-state,
.loading-state,
.hint {
  text-align: center;
  color: var(--text-muted);
  padding: 2rem;
}

.loading-state {
  grid-column: 1 / -1;
}

/* Bookings list */
.bookings-list {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.booking-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.25rem;
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 0.75rem;
  box-shadow: var(--shadow);
  transition: border-color var(--transition);
}

.booking-card-top {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
  width: 100%;
}

.booking-card:hover {
  border-color: rgba(22, 163, 74, 0.28);
}

.booking-card-user {
  flex-direction: row;
  align-items: center;
  justify-content: space-between;
}

.booking-meta {
  font-size: 0.875rem;
  color: var(--text-muted);
}

.booking-status {
  display: inline-block;
  padding: 0.25rem 0.65rem;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 600;
  background: var(--accent-dim);
  color: var(--accent);
}

/* Admin form */
.admin-form {
  max-width: 480px;
  padding: 1.5rem;
}

.admin-addcar-status-wrap {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5rem;
  align-items: start;
}

@media (max-width: 1024px) {
  .admin-addcar-status-wrap {
    grid-template-columns: 1fr;
  }
}

.admin-fleet-card {
  padding: 1.5rem;
  min-width: 0;
}

.admin-fleet-head {
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--border);
  margin-bottom: 1rem;
}

.admin-fleet-head h3 {
  margin: 0 0 0.35rem;
}

.fleet-status-list {
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}

.fleet-status-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.85rem 1rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: linear-gradient(180deg, rgba(248, 250, 252, 0.95), rgba(241, 245, 249, 0.85));
}

.fleet-status-car {
  min-width: 0;
}

.fleet-status-car strong {
  display: block;
  font-size: 0.95rem;
  line-height: 1.25;
}

.fleet-status-meta {
  margin: 0.15rem 0 0;
  color: var(--text-muted);
  font-size: 0.8125rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.status-badge {
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.25rem 0.65rem;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.01em;
  border: 1px solid transparent;
}

.status-badge::before {
  content: "";
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: currentColor;
  opacity: 0.9;
}

.status-badge--available {
  background: rgba(22, 163, 74, 0.12);
  border-color: rgba(22, 163, 74, 0.22);
  color: #166534;
}

.status-badge--booked {
  background: rgba(234, 179, 8, 0.14);
  border-color: rgba(234, 179, 8, 0.24);
  color: #854d0e;
}

.status-badge--ongoing {
  background: rgba(220, 38, 38, 0.12);
  border-color: rgba(220, 38, 38, 0.22);
  color: #991b1b;
}

.admin-bookings {
  margin-top: 1.25rem;
  padding: 1.25rem;
}

 #admin-bookings-wrap .booking-card {
   padding: 1rem;
 }

 #admin-bookings-wrap .booking-meta {
   font-size: 0.8125rem;
 }

 #admin-bookings-wrap .booking-card strong {
   font-size: 0.95rem;
 }

.admin-bookings h3 {
  margin-top: 0;
}

.admin-subsection-title {
  margin-top: 2rem;
  padding: 0.35rem 0.75rem;
  border: 1px solid var(--border);
  border-radius: 999px;
  display: inline-block;
  width: fit-content;
  background: rgba(15, 23, 42, 0.04);
}

.admin-success-title {
  margin-top: 2rem;
  padding: 0.35rem 0.75rem;
  border: 1px solid var(--border);
  border-radius: 999px;
  display: inline-block;
  width: fit-content;
  background: rgba(15, 23, 42, 0.04);
}

.admin-two-column-wrap {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1.5rem;
  margin-top: 2rem;
}

.admin-column {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.admin-column .lead {
  min-height: 2.6rem;
}

.admin-column h3 {
  margin-top: 0;
  padding: 0.35rem 0.75rem;
  border: 1px solid var(--border);
  border-radius: 999px;
  display: inline-block;
  width: fit-content;
  background: rgba(15, 23, 42, 0.04);
}

@media (max-width: 1024px) {
  .admin-two-column-wrap {
    grid-template-columns: 1fr;
  }
}

.bookings-groups {
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

.bookings-group-title {
  margin: 0 0 0.25rem;
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--text);
  padding: 0.35rem 0.75rem;
  border: 1px solid var(--border);
  border-radius: 999px;
  display: inline-block;
  width: fit-content;
  background: rgba(15, 23, 42, 0.04);
}

.bookings-group-hint {
  margin: 0 0 0.75rem;
  font-size: 0.8125rem;
  color: var(--text-muted);
}

.profile-page-card {
  max-width: 520px;
  padding: 1.5rem;
}

.profile-account-block {
  margin-bottom: 1.5rem;
  padding-bottom: 1.25rem;
  border-bottom: 1px solid var(--border);
}

.profile-page-label {
  margin: 0 0 0.35rem;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--text-muted);
}

.profile-page-email {
  margin: 0;
  font-size: 1rem;
  font-weight: 600;
  color: var(--text);
  word-break: break-all;
}

.profile-settings-title {
  margin: 0 0 0.35rem;
  font-size: 1.1rem;
}

.profile-settings-lead {
  margin: 0 0 1rem;
  font-size: 0.9rem;
}

.profile-settings-form label {
  display: block;
  margin-bottom: 1rem;
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--text-muted);
}

.profile-settings-form input {
  margin-top: 0.35rem;
  width: 100%;
  padding: 0.65rem 0.85rem;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: var(--bg);
  color: var(--text);
  font-family: inherit;
  font-size: 1rem;
}

.profile-settings-form input:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-dim);
}

.booking-admin-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 0.75rem;
  width: 100%;
  justify-content: flex-end;
}

.booking-kv {
  margin-top: 0.75rem;
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

.booking-kv-row {
  display: grid;
  grid-template-columns: 120px 1fr;
  gap: 0.75rem;
  align-items: baseline;
}

.booking-kv-key {
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--text-muted);
}

.booking-kv-val {
  font-size: 0.9rem;
  color: var(--text);
  word-break: break-word;
}

.booking-card .btn-sm {
  padding: 0.35rem 0.75rem;
  font-size: 0.8125rem;
}

.booking-status--completed {
  background: rgba(22, 163, 74, 0.15);
  color: #166534;
}

 .booking-status--canceled {
   background: rgba(220, 38, 38, 0.12);
   color: #991b1b;
 }

/* Toast (in-app success / info) */
.toast-root {
  position: fixed;
  bottom: 1.25rem;
  left: 50%;
  transform: translateX(-50%);
  z-index: 400;
  pointer-events: none;
  max-width: min(420px, calc(100vw - 2rem));
}

.toast {
  pointer-events: auto;
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  padding: 1rem 1rem 1rem 1.1rem;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-md);
  animation: toast-in 0.28s ease;
}

@keyframes toast-in {
  from {
    opacity: 0;
    transform: translateY(0.5rem);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.toast--success {
  border-color: rgba(22, 163, 74, 0.35);
}

.toast--error {
  border-color: rgba(220, 38, 38, 0.3);
}

.toast-icon {
  flex-shrink: 0;
  width: 2rem;
  height: 2rem;
  border-radius: 999px;
  background: var(--accent-dim);
  color: var(--accent);
  font-weight: 800;
  font-size: 1rem;
  display: grid;
  place-items: center;
  line-height: 1;
}

.toast--error .toast-icon {
  background: rgba(220, 38, 38, 0.12);
  color: #b91c1c;
}

.toast-body {
  flex: 1;
  min-width: 0;
}

.toast-title {
  margin: 0 0 0.2rem;
  font-size: 0.9375rem;
  font-weight: 700;
  color: var(--text);
}

.toast-car {
  margin: 0 0 0.35rem;
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--accent);
}

.toast-msg {
  margin: 0;
  font-size: 0.875rem;
  color: var(--text-muted);
  line-height: 1.45;
}

.toast .toast-dismiss {
  flex-shrink: 0;
  align-self: center;
  padding: 0.4rem 0.9rem;
  font-size: 0.8125rem;
}

.admin-form label {
  display: block;
  margin-bottom: 1rem;
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--text-muted);
}

.admin-form input {
  margin-top: 0.35rem;
  width: 100%;
  padding: 0.65rem 0.85rem;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: var(--bg);
  color: var(--text);
  font-family: inherit;
  font-size: 1rem;
  transition: border-color var(--transition), box-shadow var(--transition);
}

.admin-form input:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-dim);
}

.card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.about-card {
  max-width: 760px;
  padding: 1.25rem 1.5rem;
}

.about-card ol {
  margin: 0;
  padding-left: 1.2rem;
  color: var(--text);
}

.about-card li {
  margin: 0.65rem 0;
}

/* Footer */
.site-footer {
  text-align: center;
  padding: 2rem 1rem;
  border-top: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.5);
  color: var(--text-muted);
  font-size: 0.8125rem;
}

/* Modals */
.modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 200;
  background: rgba(15, 23, 42, 0.4);
  backdrop-filter: blur(6px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  animation: overlayIn 0.25s ease;
}

.modal-overlay.hidden {
  display: none;
}

@keyframes overlayIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

.modal {
  position: relative;
  width: 100%;
  max-width: 420px;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.75rem;
  box-shadow: var(--shadow-md);
  animation: modalIn 0.3s ease;
}

@keyframes modalIn {
  from {
    opacity: 0;
    transform: scale(0.96) translateY(10px);
  }
  to {
    opacity: 1;
    transform: scale(1) translateY(0);
  }
}

.modal h2 {
  margin: 0 0 1.25rem;
  font-size: 1.35rem;
}

.modal-booking {
  max-width: 460px;
  max-height: min(92vh, 720px);
  overflow-y: auto;
}

 .modal-car-details {
   max-height: min(92vh, 720px);
   overflow-y: auto;
 }

.modal textarea {
  margin-top: 0.35rem;
  width: 100%;
  padding: 0.65rem 0.85rem;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: var(--bg);
  color: var(--text);
  font-family: inherit;
  font-size: 0.9375rem;
  resize: vertical;
  min-height: 72px;
}

.modal textarea:focus {
  outline: none;
  border-color: var(--accent);
}

.modal label {
  display: block;
  margin-bottom: 1rem;
  font-size: 0.875rem;
  color: var(--text-muted);
}

.modal input {
  margin-top: 0.35rem;
  width: 100%;
  padding: 0.65rem 0.85rem;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: var(--bg);
  color: var(--text);
  font-family: inherit;
}

.modal input:focus {
  outline: none;
  border-color: var(--accent);
}

.auth-switch {
  margin: 0.75rem 0 0;
  color: var(--text-muted);
  font-size: 0.875rem;
}

.text-link {
  border: none;
  background: none;
  color: var(--accent);
  cursor: pointer;
  padding: 0;
  font: inherit;
  font-weight: 600;
}

.text-link:hover {
  text-decoration: underline;
}

.modal-close {
  position: absolute;
  top: 0.75rem;
  right: 0.75rem;
  background: transparent;
  border: none;
  color: var(--text-muted);
  font-size: 1.5rem;
  line-height: 1;
  cursor: pointer;
  padding: 0.25rem;
  transition: color var(--transition);
}

.modal-close:hover {
  color: var(--text);
}

.modal-gcash .gcash-brand {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 1rem;
}

.gcash-icon {
  width: 44px;
  height: 44px;
  border-radius: var(--radius-sm);
  background: linear-gradient(135deg, #0074e0, #0052a3);
  color: #fff;
  display: grid;
  place-items: center;
  font-weight: 800;
  font-size: 1.25rem;
}

.modal-gcash h2 {
  margin: 0;
}

.gcash-instructions {
  margin: 0 0 0.5rem;
  color: var(--text-muted);
  font-size: 0.9375rem;
}

.gcash-number {
  margin: 0 0 1rem;
  font-size: 1.5rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  color: var(--accent);
  font-variant-numeric: tabular-nums;
}

.gcash-car {
  margin: 0 0 1.5rem;
  font-size: 0.9375rem;
  color: var(--text);
}

.modal-actions {
  display: flex;
  gap: 0.75rem;
  justify-content: flex-end;
}

.payment-qr-wrap {
  margin: 0.75rem 0 1rem;
  display: flex;
  justify-content: center;
}

.payment-qr-img {
  width: min(260px, 100%);
  height: auto;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: #fff;
}

.payment-qr-missing {
  margin: 0 0 0.75rem;
  font-size: 0.875rem;
  color: var(--text-muted);
  text-align: center;
}

.modal-actions .btn {
  flex: 1;
}

@media (min-width: 400px) {
  .modal-actions .btn {
    flex: 0 1 auto;
    min-width: 120px;
  }
}

/* Full-screen auth gate (before main app) */
.auth-gate {
  position: relative;
  z-index: 1;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem 1.25rem 3rem;
}

.auth-gate-inner {
  width: 100%;
  max-width: 440px;
}

.auth-gate-brand {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  margin-bottom: 1.5rem;
}

.auth-gate-brand .logo-mark {
  width: 48px;
  height: 48px;
  font-size: 1.35rem;
}

.auth-gate-title {
  margin: 0;
  font-size: 1.5rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--text);
}

.auth-gate-title .accent {
  color: var(--accent);
}

.auth-gate-tagline {
  margin: 0.2rem 0 0;
  font-size: 0.875rem;
  color: var(--text-muted);
}

.auth-gate-card {
  padding: 0;
  overflow: hidden;
  border-radius: calc(var(--radius) + 4px);
  box-shadow: var(--shadow-md);
  border: 1px solid rgba(15, 23, 42, 0.06);
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(12px);
}

.auth-tabs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0;
  padding: 0.35rem;
  margin: 0;
  background: rgba(241, 245, 249, 0.9);
  border-bottom: 1px solid var(--border);
}

.auth-tab {
  appearance: none;
  border: none;
  background: transparent;
  padding: 0.65rem 0.75rem;
  font: inherit;
  font-size: 0.9375rem;
  font-weight: 600;
  color: var(--text-muted);
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: background var(--transition), color var(--transition), box-shadow var(--transition);
}

.auth-tab:hover {
  color: var(--text);
  background: rgba(255, 255, 255, 0.6);
}

.auth-tab.active {
  color: var(--text);
  background: var(--bg-elevated);
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.08);
}

.auth-panel {
  padding: 1.5rem 1.5rem 1.4rem;
}

.auth-gate-login-head {
  padding: 1.35rem 1.5rem 1rem;
  border-bottom: 1px solid var(--border);
  text-align: center;
}

.auth-gate-login-head .auth-panel-title {
  margin: 0 0 0.35rem;
  font-size: 1.25rem;
  font-weight: 700;
}

.auth-gate-login-head .auth-panel-lead {
  margin: 0;
  font-size: 0.9rem;
  color: var(--text-muted);
  line-height: 1.5;
}

.auth-panel-single {
  padding-top: 1.25rem;
}

.auth-panel-title {
  margin: 0 0 0.35rem;
  font-size: 1.25rem;
  font-weight: 700;
}

.auth-panel-lead {
  margin: 0 0 1rem;
  font-size: 0.9rem;
  color: var(--text-muted);
  line-height: 1.5;
}

.auth-message {
  padding: 0.65rem 0.85rem;
  border-radius: var(--radius-sm);
  font-size: 0.875rem;
  line-height: 1.45;
  margin-bottom: 1rem;
}

.auth-message--error {
  background: rgba(220, 38, 38, 0.08);
  border: 1px solid rgba(220, 38, 38, 0.2);
  color: #991b1b;
}

.auth-message--success {
  background: rgba(22, 163, 74, 0.1);
  border: 1px solid rgba(22, 163, 74, 0.25);
  color: #166534;
}

.validation-message {
  font-size: 0.875rem;
  margin-top: 0.25rem;
  display: block;
}

.validation-message.valid {
  color: #166534;
}

.validation-message.invalid {
  color: #991b1b;
}

input.valid {
  border-color: #16a34a;
  box-shadow: 0 0 0 1px #16a34a;
}

input.invalid {
  border-color: #dc2626;
  box-shadow: 0 0 0 1px #dc2626;
}

.auth-form {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.auth-field {
  display: block;
  margin-bottom: 1rem;
}

.auth-field-label {
  display: block;
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: var(--text);
  margin-bottom: 0.35rem;
}

.auth-field input {
  width: 100%;
  padding: 0.7rem 0.9rem;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: var(--bg-elevated);
  color: var(--text);
  font-family: inherit;
  font-size: 1rem;
  transition: border-color var(--transition), box-shadow var(--transition);
}

.auth-field input::placeholder {
  color: #94a3b8;
}

.auth-field input:hover {
  border-color: rgba(15, 23, 42, 0.14);
}

.auth-field input:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-dim);
}

.auth-field input:disabled {
  opacity: 0.65;
  cursor: not-allowed;
}

.auth-password-wrap {
  position: relative;
  display: block;
}

.auth-field .auth-password-wrap input {
  padding-right: 2.75rem;
}

.auth-password-toggle {
  position: absolute;
  right: 0.4rem;
  top: 50%;
  transform: translateY(-50%);
  display: grid;
  place-items: center;
  width: 2.25rem;
  height: 2.25rem;
  padding: 0;
  border: none;
  border-radius: var(--radius-sm);
  background: transparent;
  color: var(--text-muted);
  cursor: pointer;
  transition: color var(--transition), background var(--transition);
}

.auth-password-toggle:hover {
  color: var(--text);
  background: rgba(15, 23, 42, 0.05);
}

.auth-password-toggle:focus-visible {
  outline: none;
  box-shadow: 0 0 0 2px var(--bg-elevated), 0 0 0 4px var(--accent);
}

.auth-password-toggle:disabled {
  opacity: 0.45;
  cursor: not-allowed;
  pointer-events: none;
}

.auth-password-icon {
  display: grid;
  place-items: center;
  line-height: 0;
}

.auth-password-icon svg {
  display: block;
}

.auth-password-hint {
  display: block;
  margin-top: 0.4rem;
  font-size: 0.75rem;
  line-height: 1.4;
  color: var(--text-muted);
}

.auth-row-actions {
  display: flex;
  justify-content: flex-end;
  margin: -0.35rem 0 1rem;
}

.auth-forgot {
  font-size: 0.8125rem;
}

.auth-forgot:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.auth-gate-card .btn-primary.btn-block {
  margin-top: 0.15rem;
  padding-top: 0.75rem;
  padding-bottom: 0.75rem;
  font-weight: 600;
}

.auth-gate-card .auth-switch {
  margin-top: 1.1rem;
  padding-top: 1rem;
  border-top: 1px solid var(--border);
  text-align: center;
}

#app-shell {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

#app-shell .main-content {
  flex: 1;
}
