:root {
  --bg: #f7f7f5;
  --surface: #ffffff;
  --surface-alt: #f0f0ec;
  --text: #1a1a1a;
  --text-muted: #555;
  --border: #d9d9d3;
  --accent: #e8621c;
  --accent-dark: #c44d0f;
  --radius: 10px;
  --shadow: 0 1px 2px rgba(0,0,0,0.06), 0 4px 14px rgba(0,0,0,0.04);
  --max-width: 1180px;
}
* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.55;
  font-size: 16px;
}
.container { max-width: var(--max-width); margin: 0 auto; padding: 0 20px; }
a { color: var(--accent-dark); }
a:hover { color: var(--accent); }

.site-header {
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 50;
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 20px;
  gap: 16px;
  flex-wrap: wrap;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--text);
  font-weight: 700;
  font-size: 18px;
}
.brand-mark { display: block; }
.brand-accent { color: var(--accent); }
.site-nav {
  display: flex;
  gap: 18px;
  flex-wrap: wrap;
}
.site-nav a {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 14px;
  font-weight: 500;
}
.site-nav a:hover { color: var(--accent); }

.hero {
  background: linear-gradient(180deg, #1f1f1f 0%, #2a2a2a 100%);
  color: #fff;
  padding: 56px 0 48px;
}
.hero h1 {
  font-size: clamp(28px, 4vw, 42px);
  margin: 0 0 14px;
  line-height: 1.15;
  max-width: 780px;
}
.hero-sub {
  font-size: 17px;
  color: #d4d4d4;
  max-width: 640px;
  margin: 0;
}

.workspace { padding: 40px 0; }
.workspace-grid {
  display: grid;
  grid-template-columns: 320px 1fr;
  gap: 28px;
  align-items: start;
}
.profile-panel {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 22px;
  box-shadow: var(--shadow);
  position: sticky;
  top: 80px;
}
.profile-panel h2 {
  margin: 0 0 4px;
  font-size: 18px;
}
.panel-hint {
  color: var(--text-muted);
  font-size: 13px;
  margin: 0 0 16px;
}
.field {
  display: block;
  margin-bottom: 12px;
}
.field span {
  display: block;
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--text-muted);
  margin-bottom: 4px;
}
.field select, .field input {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid var(--border);
  border-radius: 6px;
  font-size: 15px;
  background: var(--surface);
  color: var(--text);
  font-family: inherit;
}
.field select:disabled { background: var(--surface-alt); color: #999; }
.field select:focus, .field input:focus {
  outline: 2px solid var(--accent);
  outline-offset: 1px;
}
.preset-row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: center;
  margin: 14px 0;
}
.preset-label {
  font-size: 12px;
  color: var(--text-muted);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.chip {
  background: var(--surface-alt);
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 5px 10px;
  font-size: 12px;
  cursor: pointer;
  font-family: inherit;
  color: var(--text);
}
.chip:hover { border-color: var(--accent); color: var(--accent-dark); }
.profile-actions {
  display: flex;
  gap: 8px;
  margin-top: 14px;
}
.btn {
  padding: 10px 14px;
  border-radius: 6px;
  border: 1px solid var(--border);
  background: var(--surface);
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  font-family: inherit;
  color: var(--text);
}
.btn-primary {
  background: var(--accent);
  color: #fff;
  border-color: var(--accent);
}
.btn-primary:hover { background: var(--accent-dark); border-color: var(--accent-dark); }
.btn-primary:disabled { opacity: 0.5; cursor: not-allowed; }
.btn-ghost:hover { background: var(--surface-alt); }
.saved-profiles {
  margin-top: 16px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.saved-profile-chip {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: var(--surface-alt);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 6px 10px;
  font-size: 13px;
}
.saved-profile-chip button {
  background: none;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  font-size: 16px;
  line-height: 1;
}
.saved-profile-chip button:hover { color: var(--accent); }

.results-panel {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 22px;
  box-shadow: var(--shadow);
  min-height: 320px;
}
.results-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 16px;
}
.results-header h2 { margin: 0; font-size: 18px; }
.results-controls {
  display: flex;
  gap: 8px;
  align-items: center;
  flex-wrap: wrap;
}
#result-search {
  padding: 8px 12px;
  border: 1px solid var(--border);
  border-radius: 6px;
  font-size: 14px;
  min-width: 200px;
  font-family: inherit;
}
#result-search:focus { outline: 2px solid var(--accent); outline-offset: 1px; }
.results-empty {
  text-align: center;
  padding: 48px 20px;
  color: var(--text-muted);
}
.results-empty p { max-width: 360px; margin: 12px auto 0; }
.results-table-wrap { overflow-x: auto; }
.results-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
}
.results-table th, .results-table td {
  text-align: left;
  padding: 10px 12px;
  border-bottom: 1px solid var(--border);
}
.results-table th {
  background: var(--surface-alt);
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--text-muted);
  font-weight: 600;
}
.results-table tr:hover td { background: #fafafa; }
.result-meta {
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 12px;
}

.how-it-works {
  background: var(--surface);
  padding: 48px 0;
  border-top: 1px solid var(--border);
}
.how-it-works h2, .junkyard-tips h2, .faq h2 {
  font-size: 24px;
  margin: 0 0 24px;
}
.steps-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 20px;
}
.step {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
}
.step-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  background: var(--accent);
  color: #fff;
  border-radius: 50%;
  font-weight: 700;
  font-size: 14px;
  margin-bottom: 10px;
}
.step h3 { margin: 0 0 6px; font-size: 16px; }
.step p { margin: 0; color: var(--text-muted); font-size: 14px; }

.junkyard-tips { padding: 48px 0; }
.tips-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 16px;
}
.tip-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 18px;
}
.tip-card h3 { margin: 0 0 6px; font-size: 15px; }
.tip-card p { margin: 0; color: var(--text-muted); font-size: 14px; }

.faq {
  background: var(--surface);
  padding: 48px 0;
  border-top: 1px solid var(--border);
}
.faq-list { margin: 0; }
.faq-list dt {
  font-weight: 600;
  margin-top: 18px;
  font-size: 15px;
}
.faq-list dd {
  margin: 4px 0 0;
  color: var(--text-muted);
  font-size: 14px;
}

.site-footer {
  background: #1f1f1f;
  color: #c9c9c9;
  padding: 32px 0;
  font-size: 13px;
}
.footer-inner { display: flex; flex-direction: column; gap: 8px; }
.footer-meta { color: #888; font-size: 12px; margin: 0; }
.footer-nav { display: flex; gap: 14px; flex-wrap: wrap; margin-top: 8px; }
.footer-nav a { color: #c9c9c9; text-decoration: none; }
.footer-nav a:hover { color: #fff; }

@media (max-width: 860px) {
  .workspace-grid { grid-template-columns: 1fr; }
  .profile-panel { position: static; }
  .hero { padding: 40px 0 32px; }
  .site-nav { gap: 12px; }
}
@media print {
  .site-header, .site-footer, .profile-panel, .results-controls, .how-it-works, .junkyard-tips, .faq { display: none; }
  .results-panel { box-shadow: none; border: none; }
  body { background: #fff; }
}



/* Factory-injected deployment helpers. The AI owns the site design above this block. */
.ad-unit {
  width: min(100%, 720px);
  min-height: 120px;
  margin: 24px auto;
  display: block;
}

.legal-page {
  width: min(900px, calc(100% - 32px));
  margin: 40px auto;
}

.factory-fallback-nav {
  width: min(900px, calc(100% - 32px));
  margin: 24px auto 0;
  display: flex;
  flex-wrap: wrap;
  gap: 10px 16px;
  align-items: center;
  font-size: 0.95rem;
}

.factory-fallback-nav a {
  color: inherit;
  text-decoration: none;
  border-bottom: 1px solid currentColor;
}
