/* assets/css/pages/vdp.css */

.vdp-page {
  background: #f7f9fc;
}

.vdp-shell {
  max-width: 1180px;
  margin: 0 auto;
  padding: 22px 18px 76px;
}

.vdp-back-row {
  margin-bottom: 16px;
}

.vdp-back-link {
  display: inline-flex;
  align-items: center;
  color: #2563eb;
  font-size: 14px;
  font-weight: 800;
  text-decoration: none;
}

.vdp-back-link:hover {
  text-decoration: underline;
}

.vdp-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  gap: 24px;
  align-items: start;
}

.vdp-main {
  display: grid;
  gap: 20px;
}

.vdp-image-card,
.vdp-summary-card,
.vdp-details-card,
.vdp-action-card,
.vdp-error-card {
  background: #ffffff;
  border: 1px solid #e5ebf3;
  border-radius: 20px;
  box-shadow: 0 16px 42px rgba(15, 23, 42, 0.06);
}

.vdp-image-card {
  overflow: hidden;
}

.vdp-image {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 10;
  object-fit: cover;
  background: #eef2f7;
}

.vdp-summary-card,
.vdp-details-card,
.vdp-action-card {
  padding: 22px;
}

.vdp-eyebrow {
  margin-bottom: 8px;
  color: #64748b;
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.vdp-summary-card h1 {
  margin: 0;
  color: #111827;
  font-size: clamp(28px, 4vw, 42px);
  line-height: 1.06;
  letter-spacing: -0.045em;
}

.vdp-location {
  margin: 10px 0 0;
  color: #64748b;
  font-size: 16px;
  line-height: 1.5;
}

.vdp-highlight-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin-top: 22px;
}

.vdp-highlight {
  padding: 14px;
  border: 1px solid #e5ebf3;
  border-radius: 16px;
  background: #f8fafc;
}

.vdp-highlight span,
.vdp-price-label,
.vdp-dealer-box span,
.vdp-spec-label {
  display: block;
  color: #64748b;
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.vdp-highlight strong {
  display: block;
  margin-top: 5px;
  color: #172033;
  font-size: 17px;
  line-height: 1.25;
}

.vdp-sidebar {
  position: sticky;
  top: 92px;
}

.vdp-price {
  margin-top: 6px;
  color: #0f172a;
  font-size: 38px;
  font-weight: 950;
  line-height: 1;
  letter-spacing: -0.045em;
}

.vdp-cta {
  display: flex;
  width: 100%;
  min-height: 54px;
  margin-top: 18px;
  align-items: center;
  justify-content: center;
  border-radius: 14px;
  background: #2563eb;
  color: #ffffff;
  font-size: 16px;
  font-weight: 950;
  text-decoration: none;
  box-shadow: 0 14px 28px rgba(37, 99, 235, 0.24);
}

.vdp-cta:hover {
  background: #1d4ed8;
  transform: translateY(-1px);
}

.vdp-cta-note {
  margin: 12px 0 0;
  color: #64748b;
  font-size: 13px;
  line-height: 1.45;
  text-align: center;
}

.vdp-dealer-box {
  margin-top: 18px;
  padding-top: 18px;
  border-top: 1px solid #e5ebf3;
}

.vdp-dealer-box strong {
  display: block;
  margin-top: 6px;
  color: #172033;
  font-size: 17px;
}

.vdp-dealer-box p {
  margin: 4px 0 0;
  color: #64748b;
  font-size: 14px;
}

.vdp-trust-list {
  display: grid;
  gap: 10px;
  margin-top: 18px;
  padding-top: 18px;
  border-top: 1px solid #e5ebf3;
  color: #334155;
  font-size: 14px;
  line-height: 1.35;
}

.vdp-details-card h2 {
  margin: 0 0 16px;
  color: #111827;
  font-size: 22px;
  letter-spacing: -0.035em;
}

.vdp-spec-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.vdp-spec {
  padding: 13px 14px;
  border: 1px solid #e5ebf3;
  border-radius: 14px;
  background: #f8fafc;
}

.vdp-spec-value {
  display: block;
  margin-top: 5px;
  color: #172033;
  font-size: 15px;
  font-weight: 850;
  overflow-wrap: anywhere;
}

.vdp-disclaimer,
.vdp-small-note,
.vdp-muted {
  color: #64748b;
  font-size: 12px;
  line-height: 1.5;
}

.vdp-disclaimer {
  margin-top: 18px;
}

.vdp-mobile-cta {
  display: none;
}

.vdp-error-card {
  max-width: 720px;
  margin: 60px auto;
  padding: 34px;
  text-align: center;
}

.vdp-error-card h1 {
  margin: 0;
  color: #111827;
  font-size: 32px;
  letter-spacing: -0.04em;
}

.vdp-error-card p {
  color: #64748b;
  line-height: 1.6;
}

.vdp-error-actions {
  display: flex;
  justify-content: center;
  gap: 12px;
  margin-top: 22px;
  flex-wrap: wrap;
}

.vdp-primary-button,
.vdp-secondary-button {
  display: inline-flex;
  min-height: 46px;
  align-items: center;
  justify-content: center;
  padding: 0 18px;
  border-radius: 13px;
  font-weight: 900;
  text-decoration: none;
}

.vdp-primary-button {
  background: #2563eb;
  color: #ffffff;
}

.vdp-secondary-button {
  background: #eef4ff;
  color: #2563eb;
}

@media (max-width: 900px) {
  .vdp-shell {
    padding: 12px 12px 92px;
  }

  .vdp-layout {
    grid-template-columns: 1fr;
    gap: 16px;
  }

  .vdp-sidebar {
    position: static;
    order: -1;
  }

  .vdp-action-card {
    padding: 18px;
  }

  .vdp-summary-card,
  .vdp-details-card {
    padding: 18px;
  }

  .vdp-image {
    aspect-ratio: 4 / 3;
  }

  .vdp-highlight-grid,
  .vdp-spec-grid {
    grid-template-columns: 1fr;
  }

  .vdp-price {
    font-size: 34px;
  }

  .vdp-mobile-cta {
    display: block;
    position: fixed;
    z-index: 50;
    left: 0;
    right: 0;
    bottom: 0;
    padding: 10px 14px 14px;
    background: rgba(255, 255, 255, 0.95);
    border-top: 1px solid #e5ebf3;
    backdrop-filter: blur(12px);
  }

  .vdp-mobile-cta .vdp-cta {
    margin: 0;
  }

  .vdp-action-card .vdp-cta {
    display: none;
  }
}

/* =========================
   SIMILAR VEHICLES
========================= */

.vdp-similar-card-block {
  margin-top: 18px;
  padding: 18px;
  background: #ffffff;
  border: 1px solid #e5ebf3;
  border-radius: 20px;
  box-shadow: 0 16px 42px rgba(15, 23, 42, 0.06);
}

.vdp-similar-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
}

.vdp-similar-heading h2 {
  margin: 0;
  color: #111827;
  font-size: 19px;
  letter-spacing: -0.035em;
}

.vdp-similar-heading a {
  color: #2563eb;
  font-size: 13px;
  font-weight: 900;
  text-decoration: none;
  white-space: nowrap;
}

.vdp-similar-heading a:hover {
  text-decoration: underline;
}

.vdp-similar-list {
  display: grid;
  gap: 12px;
}

.vdp-similar-card {
  display: grid;
  grid-template-columns: 96px minmax(0, 1fr);
  gap: 12px;
  padding: 10px;
  border: 1px solid #e5ebf3;
  border-radius: 15px;
  background: #f8fafc;
  color: inherit;
  text-decoration: none;
  transition: transform 0.16s ease, border-color 0.16s ease, box-shadow 0.16s ease;
}

.vdp-similar-card:hover {
  transform: translateY(-1px);
  border-color: #bfdbfe;
  box-shadow: 0 12px 26px rgba(15, 23, 42, 0.08);
}

.vdp-similar-image-wrap {
  width: 96px;
  height: 72px;
  overflow: hidden;
  border-radius: 12px;
  background: #eef2f7;
}

.vdp-similar-image {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.vdp-similar-body {
  min-width: 0;
}

.vdp-similar-body h3 {
  margin: 0;
  color: #172033;
  font-size: 14px;
  line-height: 1.25;
  font-weight: 900;
  letter-spacing: -0.02em;
}

.vdp-similar-price {
  margin-top: 5px;
  color: #0f172a;
  font-size: 15px;
  font-weight: 950;
}

.vdp-similar-meta {
  display: grid;
  gap: 2px;
  margin-top: 5px;
  color: #64748b;
  font-size: 12px;
  line-height: 1.25;
}

/* On mobile, move similar vehicles into the normal page flow
   and make them easier to browse. */
@media (max-width: 900px) {
  .vdp-similar-card-block {
    margin-top: 16px;
    padding: 16px;
  }

  .vdp-similar-list {
    display: grid;
    grid-template-columns: 1fr;
  }

  .vdp-similar-card {
    grid-template-columns: 104px minmax(0, 1fr);
  }

  .vdp-similar-image-wrap {
    width: 104px;
    height: 78px;
  }
}

/* =========================
   VDP MOBILE REORDER / POLISH
========================= */

.vdp-similar-mobile {
  display: none;
}

.vdp-details-disclosure {
  display: block;
}

.vdp-details-summary {
  list-style: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}

.vdp-details-summary::-webkit-details-marker {
  display: none;
}

.vdp-details-summary span:first-child {
  color: #111827;
  font-size: 22px;
  font-weight: 900;
  letter-spacing: -0.035em;
}

.vdp-details-summary-icon {
  width: 30px;
  height: 30px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  background: #eef4ff;
  color: #2563eb;
  font-size: 20px;
  font-weight: 900;
  line-height: 1;
  transition: transform 0.18s ease;
}

.vdp-details-disclosure[open] .vdp-details-summary-icon {
  transform: rotate(180deg);
}

.vdp-details-content {
  margin-top: 16px;
}

@media (max-width: 900px) {
  /*
    Mobile order:
    1. Action card
    2. Image
    3. Basic info
    4. Collapsed details
    5. Similar vehicles
  */

  .vdp-sidebar {
    order: -1;
    display: block;
  }

  .vdp-action-card {
    padding: 18px;
  }

  .vdp-action-card .vdp-cta {
    display: none;
  }

  .vdp-action-card .vdp-cta-note,
  .vdp-action-card .vdp-trust-list {
    display: none;
  }

  .vdp-dealer-box {
    margin-top: 16px;
    padding-top: 16px;
  }

  .vdp-main {
    gap: 16px;
  }

  .vdp-details-card {
    padding: 18px;
  }

  .vdp-details-card h2 {
    display: none;
  }

  .vdp-details-summary span:first-child {
    font-size: 20px;
  }

  .vdp-similar-desktop {
    display: none;
  }

  .vdp-similar-mobile {
    display: block;
    margin-top: 0;
  }

  .vdp-mobile-cta {
    display: block;
    position: fixed;
    z-index: 50;
    left: 0;
    right: 0;
    bottom: 0;
    padding: 10px 14px 10px;
    background: rgba(255, 255, 255, 0.96);
    border-top: 1px solid #e5ebf3;
    backdrop-filter: blur(12px);
  }

  .vdp-mobile-cta .vdp-cta {
    margin: 0;
    min-height: 54px;
  }

  .vdp-mobile-cta-note {
    margin: 7px auto 0;
    max-width: 330px;
    color: #64748b;
    font-size: 11px;
    line-height: 1.35;
    text-align: center;
  }

  .vdp-shell {
    padding-bottom: 120px;
  }
}