/* Car-page table and footer stability — Aug 30 */
.data-table-wrap {
  position: relative;
  z-index: 1;
  display: block;
  width: 100%;
  overflow-x: auto;
}

.data-table th,
.data-table td {
  white-space: normal;
  overflow-wrap: anywhere;
  word-break: normal;
}

.data-table th {
  letter-spacing: .08em;
  line-height: 1.35;
}

.market-table {
  table-layout: fixed;
  min-width: 760px;
}

.market-table th:nth-child(1),
.market-table td:nth-child(1) { width: 23%; }
.market-table th:nth-child(2),
.market-table td:nth-child(2) { width: 27%; }
.market-table th:nth-child(3),
.market-table td:nth-child(3) { width: 34%; }
.market-table th:nth-child(4),
.market-table td:nth-child(4) { width: 16%; }

.issue-table {
  table-layout: fixed;
  min-width: 760px;
}

.issue-table th:nth-child(1),
.issue-table td:nth-child(1) { width: 46%; }
.issue-table th:nth-child(2),
.issue-table td:nth-child(2) { width: 20%; }
.issue-table th:nth-child(3),
.issue-table td:nth-child(3) { width: 34%; }

.data-chip {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  padding: 5px 10px;
  border-radius: 999px;
  font-family: var(--mono);
  font-size: .76rem;
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: .04em;
  white-space: nowrap;
}

.data-chip-na {
  background: #eee9e0;
  color: #5f5a53;
}

.data-chip-unknown {
  background: #f3eadb;
  color: #6e5d42;
}

.car-page {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.car-page > main {
  display: block;
  flex: 1 0 auto;
}

.car-page .section,
.car-page .article,
.car-page .article .content,
.vehicle-data-section {
  min-width: 0;
}

.car-page .article {
  align-items: start;
  padding-bottom: 20px;
}

.car-page .article .content {
  display: flow-root;
  padding-bottom: 26px;
}

.car-page > .footer {
  position: static !important;
  z-index: auto;
  clear: both !important;
  flex: 0 0 auto;
  margin-top: 70px !important;
  background: var(--bg);
}

.footer .wrap > div { min-width: 0; }

.footer .wrap > .small {
  max-width: 640px;
  margin-left: auto;
  text-align: right;
  overflow-wrap: anywhere;
}

@media (max-width: 680px) {
  .footer .wrap {
    display: grid;
    grid-template-columns: 1fr;
  }

  .footer .wrap > .small {
    margin-left: 0;
    text-align: left;
  }

  .data-table th,
  .data-table td { padding: 12px; }
  .market-table,
  .issue-table { min-width: 680px; }
}

/* Fact-backed Waghoon snapshot — Aug 30 */
.wagon-snapshot-section {
  margin-top: 46px;
  padding: 28px;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: #f8f5ef;
}

.snapshot-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 20px;
}

.snapshot-heading h2 { margin: 0 0 8px; }

.snapshot-kicker,
.snapshot-label {
  display: block;
  font-family: var(--mono);
  font-size: .7rem;
  font-weight: 700;
  letter-spacing: .12em;
  line-height: 1.35;
  text-transform: uppercase;
  color: var(--muted);
}

.snapshot-kicker { margin-bottom: 8px; }

.snapshot-verified {
  flex: 0 0 auto;
  padding: 8px 11px;
  border-radius: 999px;
  background: #172019;
  color: #fff;
  font-family: var(--mono);
  font-size: .68rem;
  font-weight: 700;
  letter-spacing: .1em;
  text-transform: uppercase;
}

.snapshot-primary-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin-top: 20px;
}

.snapshot-card,
.snapshot-extra {
  min-width: 0;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: #fff;
}

.snapshot-card { min-height: 190px; }

.snapshot-value,
.snapshot-extra strong {
  display: block;
  margin: 9px 0 8px;
  font-size: 1.25rem;
  line-height: 1.16;
  overflow-wrap: anywhere;
}

.snapshot-note {
  display: block;
  color: var(--muted);
  font-size: .78rem;
  line-height: 1.4;
  overflow-wrap: anywhere;
}

.snapshot-note a,
.snapshot-method a {
  text-decoration: underline;
  text-underline-offset: 3px;
}

.snapshot-compare {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-top: 17px;
  padding-top: 15px;
  border-top: 1px solid var(--line);
}

.snapshot-compare > span { min-width: 0; }

.snapshot-compare small {
  display: block;
  margin-bottom: 3px;
  color: var(--muted);
  font-family: var(--mono);
  font-size: .58rem;
  font-weight: 700;
  letter-spacing: .06em;
  line-height: 1.3;
  text-transform: uppercase;
}

.snapshot-compare strong {
  display: block;
  font-size: .76rem;
  line-height: 1.35;
  overflow-wrap: anywhere;
}

.snapshot-proof {
  display: grid;
  grid-template-columns: minmax(210px, .85fr) minmax(0, 1.65fr);
  align-items: center;
  gap: 24px;
  margin-top: 12px;
  padding: 20px;
  border-left: 6px solid #92794f;
  border-radius: 18px;
  background: #eee8de;
}

.snapshot-proof-copy > strong {
  display: block;
  margin-top: 7px;
  font-size: 1rem;
  line-height: 1.35;
}

.snapshot-proof-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
  gap: 8px;
}

.snapshot-proof-item {
  min-width: 0;
  padding: 13px 14px;
  border: 1px solid #d4c9b8;
  border-radius: 14px;
  background: #f8f4ed;
}

.snapshot-proof-item strong {
  display: block;
  margin-top: 5px;
  font-size: .82rem;
  line-height: 1.35;
  overflow-wrap: anywhere;
}

.snapshot-extras {
  margin-top: 22px;
  padding-top: 20px;
  border-top: 1px solid var(--line);
}

.snapshot-extras h3 {
  margin: 0 0 12px;
  font-family: var(--serif);
  font-size: 1.15rem;
}

.snapshot-extras-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.snapshot-extra strong { font-size: .95rem; }

.snapshot-method {
  margin: 18px 0 0;
  color: var(--muted);
  font-size: .72rem;
  line-height: 1.55;
}

@media (max-width: 1024px) {
  .snapshot-extras-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 820px) {
  .snapshot-primary-grid { grid-template-columns: 1fr; }
  .snapshot-card { min-height: 0; }
  .snapshot-proof { grid-template-columns: 1fr; gap: 16px; }
}

@media (max-width: 680px) {
  .wagon-snapshot-section { padding: 20px; }
  .snapshot-heading { display: grid; }
  .snapshot-verified { justify-self: start; }
  .snapshot-primary-grid,
  .snapshot-extras-grid { grid-template-columns: 1fr; }
  .snapshot-proof-grid { grid-template-columns: 1fr; }
}

@media (max-width: 420px) {
  .snapshot-compare { grid-template-columns: 1fr; }
}

/* Waghoon-first inventory profiles — Sep 5 */
.profile-hero-card {
  width: 100%;
  max-width: none;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 22px;
  background: #fff;
}

.profile-hero-card .card-body { padding: 24px; }

.profile-source-cta { margin-top: 18px; }

.profile-source-cta a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  max-width: 100%;
  padding: 13px 18px;
  border-radius: 999px;
  background: var(--ink);
  color: #fff;
  font-weight: 800;
  line-height: 1.25;
  text-align: center;
}

.profile-source-cta a:hover { transform: translateY(-1px); }

.issue-table td > strong,
.issue-table td > span {
  display: block;
}

.issue-table td > strong { margin-bottom: 7px; }

.issue-table td > span {
  color: var(--muted);
  font-size: .86rem;
  line-height: 1.5;
}

.snapshot-proof-item small {
  display: block;
  color: var(--muted);
  font-family: var(--mono);
  font-size: .58rem;
  font-weight: 700;
  letter-spacing: .07em;
  text-transform: uppercase;
}

@media (max-width: 680px) {
  .profile-hero-card .card-body { padding: 18px; }
  .profile-source-cta a { width: 100%; }
}
