/* Best Selection Automotive - shared styles */
:root {
  --orange: #f7931e;
  --orange-dark: #d97b0c;
  --black: #16181c;
  --dark-gray: #2a2d33;
  --light-gray: #f4f5f7;
  --border: #e3e5e9;
  --text: #202225;
  --muted: #6b7078;
  --white: #ffffff;
  --radius: 10px;
  --shadow: 0 4px 16px rgba(0,0,0,0.08);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
  color: var(--text);
  background: var(--white);
  line-height: 1.55;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
.container { max-width: 1180px; margin: 0 auto; padding: 0 24px; }
section { padding: 64px 0; }
h1, h2, h3 { line-height: 1.2; margin: 0 0 16px; }
h2 { font-size: 2rem; }
h2.center { text-align: center; }
p.lead { color: var(--muted); max-width: 640px; }
p.lead.center { margin-left: auto; margin-right: auto; text-align: center; }

/* Top bar */
.topbar {
  background: var(--black);
  color: #cfd2d8;
  font-size: 0.85rem;
}
.topbar .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 8px;
  padding-bottom: 8px;
  flex-wrap: wrap;
  gap: 10px;
}
.topbar a.phone { color: var(--orange); font-weight: 600; }
.topbar-actions { display: flex; align-items: center; gap: 10px; margin: 0 auto; flex-wrap: wrap; justify-content: center; }
.topbar .btn { padding: 7px 16px; font-size: 0.82rem; }
.topbar .btn-outline { color: var(--white); }
.topbar .btn-outline:hover { background: var(--orange); border-color: var(--orange); color: var(--black); }
.topbar .btn-call-now { padding-left: 12px; gap: 6px; }
.topbar .point-finger { font-size: 1.3rem; }

/* Header / nav */
header.site-header {
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  background: var(--white);
  z-index: 100;
}
.nav-wrap {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 6px 24px;
  flex-wrap: wrap;
  gap: 10px 20px;
}
.tire-marks {
  position: absolute;
  left: 0;
  top: 0;
  width: 230px;
  height: 100%;
  z-index: 0;
  pointer-events: none;
}
.brand {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 1.25rem;
  font-weight: 800;
  color: var(--black);
}
.brand span { color: var(--orange); }
.brand-mark { width: 40px; height: 40px; flex-shrink: 0; }
.brand-logo { height: 148px; width: auto; display: block; max-width: 100%; }
.footer-logo-wrap { position: relative; display: inline-block; margin-bottom: 16px; }
.footer-logo-card {
  position: relative;
  z-index: 1;
  display: inline-block;
  background: var(--white);
  border-radius: 12px;
  padding: 10px 14px;
  margin-bottom: 0;
}
.footer-logo-card img { height: 90px; width: auto; display: block; }
.footer-gears {
  position: absolute;
  top: -20px;
  right: -36px;
  width: 92px;
  height: auto;
  z-index: 0;
  opacity: 0.65;
  pointer-events: none;
}
.footer-gears .gear-a, .footer-gears .gear-b {
  transform-box: fill-box;
  transform-origin: center;
}
.footer-gears .gear-a { animation: spinCW 9s linear infinite; }
.footer-gears .gear-b { animation: spinCCW 6.3s linear infinite; }
@keyframes spinCW { from { transform: rotate(0deg); } to { transform: rotate(360deg); } }
@keyframes spinCCW { from { transform: rotate(0deg); } to { transform: rotate(-360deg); } }

.btn-call-now { display: inline-flex; align-items: center; gap: 9px; padding-left: 16px; }
.point-finger { display: inline-block; line-height: 1; font-size: 1.9rem; animation: pointWiggle 1.1s ease-in-out infinite; }
@keyframes pointWiggle {
  0%, 100% { transform: translateX(0) rotate(0deg); }
  50% { transform: translateX(4px) rotate(-8deg); }
}
nav.main-nav {
  position: relative;
  z-index: 1;
  display: flex;
  gap: 28px;
}
nav.main-nav a {
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--text);
  padding: 6px 0;
  border-bottom: 2px solid transparent;
}
nav.main-nav a.active,
nav.main-nav a:hover { border-bottom-color: var(--orange); color: var(--orange-dark); }

.nav-cta {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  gap: 14px;
}
.btn {
  display: inline-block;
  padding: 12px 22px;
  border-radius: var(--radius);
  font-weight: 700;
  font-size: 0.92rem;
  border: 2px solid var(--orange);
  cursor: pointer;
}
.btn-primary { background: var(--orange); color: var(--black); }
.btn-primary:hover { background: var(--orange-dark); border-color: var(--orange-dark); }
.btn-outline { background: transparent; color: var(--black); }
.btn-outline:hover { background: var(--black); border-color: var(--black); color: var(--white); }
.menu-toggle { display: none; background: none; border: none; font-size: 1.6rem; cursor: pointer; }

/* Hero */
.hero {
  position: relative;
  overflow: hidden;
  color: var(--white);
  background: var(--black);
  padding: 100px 0;
  text-align: center;
}
.hero-slideshow { position: absolute; inset: 0; z-index: 0; }
.hero-slide {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  animation: heroFade 24s infinite;
}
.hero-slide:nth-child(1) { animation-delay: 0s; }
.hero-slide:nth-child(2) { animation-delay: 4s; }
.hero-slide:nth-child(3) { animation-delay: 8s; }
.hero-slide:nth-child(4) { animation-delay: 12s; }
.hero-slide:nth-child(5) { animation-delay: 16s; }
.hero-slide:nth-child(6) { animation-delay: 20s; }
@keyframes heroFade {
  0% { opacity: 0; }
  3% { opacity: 1; }
  14% { opacity: 1; }
  18% { opacity: 0; }
  100% { opacity: 0; }
}
.hero-overlay {
  position: absolute;
  inset: 0;
  z-index: 1;
  background: linear-gradient(180deg, rgba(22,24,28,0.55), rgba(22,24,28,0.85));
}
.hero .container { position: relative; z-index: 2; }
.hero h1 { font-size: 2.6rem; max-width: 780px; margin: 0 auto 18px; }
.hero p { max-width: 560px; margin: 0 auto 30px; color: #dcdde0; }
.hero .btn-row { display: flex; gap: 16px; justify-content: center; flex-wrap: wrap; }

.page-hero {
  background: var(--black);
  color: var(--white);
  padding: 60px 0;
  text-align: center;
}
.page-hero h1 { font-size: 2.1rem; margin-bottom: 8px; }
.page-hero p { color: #c9cbd0; margin: 0; }

/* Inventory grid */
.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 24px;
  margin-top: 36px;
}
.card {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--white);
  box-shadow: var(--shadow);
  transition: transform .15s ease;
}
.card:hover { transform: translateY(-4px); }
.card img { height: 190px; width: 100%; object-fit: cover; background: var(--light-gray); }
.card-body { padding: 18px; }
.card-body h3 { font-size: 1.1rem; margin-bottom: 4px; }
.card-body .trim { color: var(--muted); font-size: 0.9rem; margin-bottom: 2px; }
.card-body .vin { color: var(--muted); font-size: 0.72rem; letter-spacing: .02em; margin-bottom: 12px; }
.card-stats {
  display: flex;
  justify-content: space-between;
  border-top: 1px solid var(--border);
  padding-top: 12px;
  margin-bottom: 14px;
  font-size: 0.9rem;
}
.card-stats strong { display: block; color: var(--black); font-size: 1.05rem; }
.card-stats .stat-label { color: var(--muted); font-size: 0.78rem; text-transform: uppercase; letter-spacing: .04em; }
.card .btn { width: 100%; text-align: center; }
.card { position: relative; }
.card.card-sold img { filter: grayscale(45%); opacity: 0.75; }
.sold-ribbon {
  position: absolute;
  top: 14px;
  right: -34px;
  background: var(--black);
  color: var(--white);
  font-weight: 800;
  font-size: 0.78rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 5px 40px;
  transform: rotate(35deg);
  z-index: 2;
  box-shadow: 0 2px 6px rgba(0,0,0,0.25);
}
.photo-badge {
  position: absolute;
  top: 14px;
  left: 14px;
  background: rgba(22,24,28,0.72);
  color: var(--white);
  font-size: 0.72rem;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: 20px;
  z-index: 2;
}

/* Body styles / makes */
.chip-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 16px;
  margin-top: 32px;
}
.chip {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 22px 16px;
  text-align: center;
  font-weight: 700;
  background: var(--light-gray);
}
.chip:hover { background: var(--orange); color: var(--black); border-color: var(--orange); }
.chip .count { display: block; font-weight: 400; font-size: 0.82rem; color: var(--muted); margin-top: 4px; }
.chip:hover .count { color: var(--black); }

/* Steps */
.steps {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 24px;
  margin-top: 32px;
}
.step { padding: 22px; border-radius: var(--radius); background: var(--light-gray); }
.step .num { color: var(--orange-dark); font-weight: 800; font-size: 0.85rem; margin-bottom: 8px; }

.dark-section { background: var(--black); color: var(--white); }
.dark-section p.lead { color: #c9cbd0; }
.dark-section .step { background: var(--dark-gray); }

/* Commitment / feature list */
.feature-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 24px;
  margin-top: 32px;
}
.feature .eyebrow { color: var(--orange-dark); font-weight: 700; font-size: 0.8rem; text-transform: uppercase; letter-spacing: .05em; margin-bottom: 6px; }
.feature h3 { margin-bottom: 8px; }
.feature p { color: var(--muted); margin-bottom: 14px; }

/* Icon badges */
.icon-badge {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: var(--light-gray);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 16px;
}
.icon-badge svg { width: 28px; height: 28px; color: var(--orange-dark); }
.dark-section .icon-badge { background: rgba(255,255,255,0.08); }
.dark-section .icon-badge svg { color: var(--orange); }
.step .icon-badge { width: 48px; height: 48px; margin-bottom: 12px; }
.step .icon-badge svg { width: 24px; height: 24px; }

/* Forms */
.form-card {
  background: var(--light-gray);
  border-radius: var(--radius);
  padding: 32px;
  max-width: 640px;
  margin: 32px auto 0;
}
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.form-row.single { grid-template-columns: 1fr; }
.field { margin-bottom: 16px; }
.field label { display: block; font-weight: 600; font-size: 0.88rem; margin-bottom: 6px; }
.field input, .field textarea, .field select {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid var(--border);
  border-radius: 8px;
  font-size: 0.95rem;
  font-family: inherit;
  background: var(--white);
}
.field textarea { resize: vertical; min-height: 100px; }
.consent { font-size: 0.78rem; color: var(--muted); margin-bottom: 18px; }
.form-success {
  display: none;
  background: #e7f6ec;
  border: 1px solid #b9e5c6;
  color: #1e6b34;
  padding: 12px 16px;
  border-radius: 8px;
  margin-top: 14px;
  font-weight: 600;
}

/* Testimonials */
.testimonial {
  background: var(--light-gray);
  border-radius: var(--radius);
  padding: 26px;
  border-left: 4px solid var(--orange);
}
.testimonial .stars { color: var(--orange); margin-bottom: 10px; letter-spacing: 2px; }
.testimonial .name { font-weight: 700; margin-top: 12px; }
.testimonial .role { color: var(--muted); font-size: 0.85rem; }

/* Contact info blocks */
.info-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 40px; margin-top: 32px; }
.info-block { }
.info-item { display: flex; gap: 14px; margin-bottom: 22px; }
.info-item .icon { width: 42px; height: 42px; border-radius: 50%; background: var(--orange); color: var(--black); display: flex; align-items: center; justify-content: center; font-weight: 800; flex-shrink: 0; }
.info-item h3 { margin: 0 0 4px; font-size: 1rem; }
.info-item p { margin: 0; color: var(--muted); }
.map-embed { width: 100%; height: 320px; border: 0; border-radius: var(--radius); filter: grayscale(20%); }

/* Footer */
footer.site-footer {
  background: var(--black);
  color: #c9cbd0;
  padding: 56px 0 24px;
  margin-top: 40px;
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: 32px;
  margin-bottom: 36px;
}
.footer-grid h4 { color: var(--white); font-size: 0.95rem; margin-bottom: 16px; display: flex; align-items: center; gap: 10px; }
.footer-grid h4 .brand-mark { width: 28px; height: 28px; }
.footer-grid a, .footer-grid p { display: block; color: #c9cbd0; font-size: 0.9rem; margin-bottom: 10px; }
.footer-grid a:hover { color: var(--orange); }
.footer-bottom {
  border-top: 1px solid #33363c;
  padding-top: 20px;
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 10px;
  font-size: 0.82rem;
  color: #8b8f97;
}

/* Inventory search + sort toolbar */
.inventory-toolbar { display: flex; gap: 14px; flex-wrap: wrap; margin-bottom: 8px; }
.inv-search-input { flex: 1; min-width: 220px; padding: 12px 16px; border: 1px solid var(--border); border-radius: 8px; font-size: 0.95rem; font-family: inherit; }
.inv-sort-select { padding: 12px 16px; border: 1px solid var(--border); border-radius: 8px; font-size: 0.95rem; font-family: inherit; background: var(--white); min-width: 200px; }
.inv-search-input:focus, .inv-sort-select:focus { outline: none; border-color: var(--orange); }

/* Vehicle detail page */
.breadcrumb { font-size: 0.85rem; color: var(--muted); }
.breadcrumb a { color: var(--muted); }
.breadcrumb a:hover { color: var(--orange-dark); }
.vehicle-detail-wrap { display: grid; grid-template-columns: 1.4fr 1fr; gap: 32px; margin-top: 18px; align-items: start; }
.vehicle-gallery { }
.gallery-main { border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); background: var(--light-gray); }
.gallery-main img { width: 100%; height: 420px; object-fit: cover; display: block; }
.gallery-thumbs { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 12px; }
.gallery-thumb { padding: 0; border: 2px solid transparent; border-radius: 8px; overflow: hidden; width: 84px; height: 62px; cursor: pointer; background: none; }
.gallery-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.gallery-thumb.active { border-color: var(--orange); }
.vehicle-info-card { position: relative; background: var(--white); border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow); padding: 26px 28px; }
.vehicle-info-card h1 { font-size: 1.6rem; margin-bottom: 2px; }
.vehicle-info-card .vehicle-trim { color: var(--muted); margin-bottom: 14px; }
.vehicle-info-card .vehicle-price { font-size: 2rem; font-weight: 800; color: var(--black); margin-bottom: 18px; }
.vehicle-info-card.is-sold .vehicle-price { color: var(--muted); }
.vehicle-sold-badge { display: inline-block; vertical-align: middle; background: var(--black); color: var(--white); font-size: 0.7rem; font-weight: 800; text-transform: uppercase; letter-spacing: .04em; padding: 4px 10px; border-radius: 20px; margin-left: 6px; }
.vehicle-specs-list { display: grid; grid-template-columns: 1fr 1fr; gap: 12px 16px; border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); padding: 16px 0; margin-bottom: 20px; }
.vehicle-specs-list span { display: block; color: var(--muted); font-size: 0.75rem; text-transform: uppercase; letter-spacing: .04em; margin-bottom: 2px; }
.vehicle-specs-list strong { font-size: 0.95rem; }
.vehicle-cta-row { display: flex; flex-direction: column; gap: 10px; }
.vehicle-cta-row .btn { width: 100%; text-align: center; }
.vehicle-description-card, .loan-calc-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 28px;
  margin-top: 28px;
}
.vehicle-description-card h3, .loan-calc-card h3 { margin-bottom: 14px; }
.vehicle-description-card p { color: var(--muted); white-space: pre-line; }
.loan-calc-result {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: var(--light-gray);
  border-radius: 8px;
  padding: 16px 20px;
  margin-top: 6px;
}
.loan-calc-result span { color: var(--muted); font-size: 0.85rem; }
.loan-calc-result strong { font-size: 1.6rem; color: var(--black); }

@media (max-width: 860px) {
  .nav-wrap nav.main-nav, .nav-wrap .nav-cta .btn-outline { display: none; }
  .menu-toggle { display: block; }
  nav.main-nav.open {
    display: flex;
    flex-direction: column;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--white);
    padding: 16px 24px;
    border-bottom: 1px solid var(--border);
    gap: 14px;
  }
  .info-grid { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .form-row { grid-template-columns: 1fr; }
  .hero h1 { font-size: 2rem; }
  .brand-logo { height: 88px; }
  .vehicle-detail-wrap { grid-template-columns: 1fr; }
  .gallery-main img { height: 260px; }
}
