/* Jasper Mobile Home Center - Shared Styles */
:root {
  --bg: #0f0f0f;
  --bg-elev: #181818;
  --bg-card: #1c1c1c;
  --border: #2a2a2a;
  --gold: #C9A84C;
  --gold-soft: #d8bc6a;
  --gold-dark: #9d8538;
  --text: #f5f5f5;
  --text-dim: #b5b5b5;
  --text-muted: #8a8a8a;
  --danger: #d9534f;
  --success: #5cb85c;
  --info: #4a90e2;
  --warning: #f0ad4e;
  --shadow: 0 8px 24px rgba(0,0,0,0.4);
  --radius: 10px;
  --max-w: 1200px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

img { max-width: 100%; display: block; }
a { color: var(--gold); text-decoration: none; transition: color .2s; }
a:hover { color: var(--gold-soft); }

h1, h2, h3, h4 { font-weight: 700; line-height: 1.2; letter-spacing: -0.01em; }
h1 { font-size: clamp(2rem, 5vw, 3.5rem); }
h2 { font-size: clamp(1.6rem, 3.5vw, 2.4rem); margin-bottom: 1rem; }
h3 { font-size: 1.25rem; }

.container { max-width: var(--max-w); margin: 0 auto; padding: 0 1.5rem; }

/* ===== HEADER ===== */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(15,15,15,0.95);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
}
.nav-wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 1.5rem;
  max-width: var(--max-w);
  margin: 0 auto;
}
.logo {
  display: flex;
  align-items: center;
  gap: .65rem;
  font-weight: 800;
  font-size: 1.15rem;
  color: var(--text);
  letter-spacing: -0.01em;
}
.logo:hover { color: var(--gold); }
.logo svg { width: 28px; height: 28px; color: var(--gold); }
.logo-text { display: flex; flex-direction: column; line-height: 1; }
.logo-text .tagline { font-size: .65rem; color: var(--gold); font-weight: 500; letter-spacing: .05em; text-transform: uppercase; margin-top: 3px; }

.nav-links { display: flex; gap: 2rem; align-items: center; }
.nav-links a { color: var(--text-dim); font-weight: 500; font-size: .95rem; }
.nav-links a:hover, .nav-links a.active { color: var(--gold); }

.nav-phone {
  background: var(--gold);
  color: #111 !important;
  padding: .55rem 1.1rem;
  border-radius: 6px;
  font-weight: 700;
  font-size: .9rem;
}
.nav-phone:hover { background: var(--gold-soft); color: #111 !important; }

.mobile-toggle { display: none; background: none; border: none; color: var(--text); cursor: pointer; padding: .5rem; }

@media (max-width: 820px) {
  .nav-links { display: none; position: absolute; top: 100%; left: 0; right: 0; background: var(--bg-elev); flex-direction: column; padding: 1rem; border-bottom: 1px solid var(--border); gap: 1rem; }
  .nav-links.open { display: flex; }
  .mobile-toggle { display: block; }
}

/* ===== BUTTONS ===== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .5rem;
  padding: .85rem 1.5rem;
  border-radius: 8px;
  font-weight: 600;
  font-size: .95rem;
  cursor: pointer;
  border: none;
  transition: all .2s;
  text-align: center;
}
.btn-primary { background: var(--gold); color: #111; }
.btn-primary:hover { background: var(--gold-soft); transform: translateY(-1px); color: #111; }
.btn-outline { background: transparent; color: var(--text); border: 1.5px solid var(--gold); }
.btn-outline:hover { background: var(--gold); color: #111; }
.btn-ghost { background: var(--bg-card); color: var(--text); border: 1px solid var(--border); }
.btn-ghost:hover { border-color: var(--gold); color: var(--gold); }
.btn-sm { padding: .5rem 1rem; font-size: .85rem; }
.btn-danger { background: var(--danger); color: white; }
.btn-danger:hover { background: #c43e3a; }

/* ===== HERO ===== */
.hero {
  position: relative;
  min-height: 78vh;
  display: flex;
  align-items: center;
  background-size: cover;
  background-position: center;
  overflow: hidden;
}
.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(15,15,15,0.92), rgba(15,15,15,0.7) 50%, rgba(15,15,15,0.5));
}
.hero-inner {
  position: relative;
  z-index: 1;
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 5rem 1.5rem;
  width: 100%;
}
.hero-content { max-width: 680px; }
.hero-eyebrow {
  display: inline-block;
  color: var(--gold);
  font-weight: 600;
  font-size: .85rem;
  text-transform: uppercase;
  letter-spacing: .12em;
  margin-bottom: 1.25rem;
}
.hero h1 { margin-bottom: 1.25rem; }
.hero h1 .accent { color: var(--gold); }
.hero p.lead { font-size: 1.15rem; color: var(--text-dim); margin-bottom: 2rem; max-width: 560px; }
.hero-ctas { display: flex; gap: 1rem; flex-wrap: wrap; margin-bottom: 2.5rem; }
.hero-phone {
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  color: var(--text);
  font-weight: 500;
}
.hero-phone strong { color: var(--gold); font-size: 1.2rem; font-weight: 700; }

/* ===== SECTIONS ===== */
section { padding: 5rem 0; }
.section-header { text-align: center; margin-bottom: 3rem; }
.section-header .eyebrow {
  display: inline-block;
  color: var(--gold);
  font-weight: 600;
  font-size: .8rem;
  text-transform: uppercase;
  letter-spacing: .12em;
  margin-bottom: .75rem;
}
.section-header p { color: var(--text-dim); max-width: 600px; margin: 0 auto; font-size: 1.05rem; }

/* ===== TRUST BAR ===== */
.trust-bar {
  background: var(--bg-elev);
  padding: 2.5rem 0;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}
.trust-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.5rem;
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 1.5rem;
}
.trust-item { text-align: center; }
.trust-item svg { width: 38px; height: 38px; color: var(--gold); margin: 0 auto .65rem; display: block; }
.trust-item .label { font-weight: 600; color: var(--text); font-size: .95rem; }
.trust-item .sub { font-size: .8rem; color: var(--text-muted); margin-top: 2px; }
@media (max-width: 700px) {
  .trust-grid { grid-template-columns: repeat(2, 1fr); gap: 2rem 1rem; }
}

/* ===== HOME CARDS ===== */
.homes-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 1.5rem;
}
.home-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  transition: transform .25s, border-color .25s, box-shadow .25s;
  display: flex;
  flex-direction: column;
}
.home-card:hover {
  transform: translateY(-4px);
  border-color: var(--gold);
  box-shadow: var(--shadow);
}
.home-card-img {
  position: relative;
  aspect-ratio: 16/10;
  overflow: hidden;
  background: #222;
}
.home-card-img img {
  width: 100%; height: 100%; object-fit: cover;
  transition: transform .4s;
}
.home-card:hover .home-card-img img { transform: scale(1.05); }
.home-card-img .badge {
  position: absolute;
  top: 12px; left: 12px;
  background: var(--gold);
  color: #111;
  padding: 4px 10px;
  border-radius: 4px;
  font-size: .72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .05em;
}
.home-card-body { padding: 1.25rem; display: flex; flex-direction: column; flex: 1; gap: .75rem; }
.home-card-body h3 { color: var(--text); }
.home-specs {
  display: flex;
  flex-wrap: wrap;
  gap: .75rem;
  color: var(--text-dim);
  font-size: .85rem;
}
.home-specs span {
  display: inline-flex;
  align-items: center;
  gap: .35rem;
}
.home-specs span::before {
  content: '';
  width: 4px; height: 4px;
  border-radius: 50%;
  background: var(--gold);
  display: inline-block;
}
.home-price {
  color: var(--gold);
  font-size: 1.5rem;
  font-weight: 800;
  margin-top: auto;
}
.home-price small { font-size: .7rem; color: var(--text-muted); font-weight: 500; display: block; text-transform: uppercase; letter-spacing: .05em; }
.home-card-actions { display: flex; gap: .5rem; margin-top: .75rem; }
.home-card-actions .btn { flex: 1; }

/* ===== HOW IT WORKS ===== */
.steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
}
.step {
  background: var(--bg-card);
  padding: 2rem;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  text-align: center;
  position: relative;
}
.step-num {
  width: 50px; height: 50px;
  background: var(--gold);
  color: #111;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-weight: 800;
  font-size: 1.2rem;
  margin: 0 auto 1rem;
}
.step h3 { margin-bottom: .5rem; }
.step p { color: var(--text-dim); font-size: .95rem; }
@media (max-width: 800px) {
  .steps { grid-template-columns: 1fr; }
}

/* ===== CTA BANNER ===== */
.cta-banner {
  background: linear-gradient(135deg, var(--gold-dark), var(--gold));
  padding: 4rem 1.5rem;
  text-align: center;
  color: #1a1a1a;
}
.cta-banner h2 { color: #111; margin-bottom: .75rem; }
.cta-banner p { color: #2a2a2a; margin-bottom: 1.75rem; font-size: 1.1rem; }
.cta-banner .btn-dark {
  background: #111;
  color: var(--gold);
  padding: 1rem 2rem;
  border-radius: 8px;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  gap: .5rem;
}
.cta-banner .btn-dark:hover { background: #000; color: var(--gold-soft); }

/* ===== LOCATION ===== */
.location-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  align-items: center;
}
.location-info h3 { color: var(--gold); margin-bottom: 1rem; }
.location-info .info-row { display: flex; align-items: flex-start; gap: .75rem; margin-bottom: 1rem; }
.location-info .info-row svg { width: 20px; height: 20px; color: var(--gold); flex-shrink: 0; margin-top: 3px; }
.location-info .info-row .label { font-size: .85rem; color: var(--text-muted); text-transform: uppercase; letter-spacing: .05em; }
.location-info .info-row .value { color: var(--text); font-weight: 500; }
.location-map {
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--border);
  aspect-ratio: 4/3;
}
.location-map iframe { width: 100%; height: 100%; border: none; filter: invert(.9) hue-rotate(180deg) saturate(.8); }
@media (max-width: 800px) {
  .location-grid { grid-template-columns: 1fr; gap: 2rem; }
}

/* ===== FOOTER ===== */
.site-footer {
  background: #0a0a0a;
  border-top: 1px solid var(--border);
  padding: 3rem 0 1.5rem;
  margin-top: auto;
}
.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 2rem;
  margin-bottom: 2rem;
}
.footer-col h4 { color: var(--gold); font-size: .85rem; text-transform: uppercase; letter-spacing: .1em; margin-bottom: 1rem; }
.footer-col ul { list-style: none; }
.footer-col li { margin-bottom: .5rem; }
.footer-col a { color: var(--text-dim); font-size: .9rem; }
.footer-col a:hover { color: var(--gold); }
.footer-col p { color: var(--text-dim); font-size: .9rem; margin-bottom: .35rem; }
.footer-bottom {
  padding-top: 1.5rem;
  border-top: 1px solid var(--border);
  text-align: center;
  color: var(--text-muted);
  font-size: .8rem;
}
@media (max-width: 800px) {
  .footer-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 500px) {
  .footer-grid { grid-template-columns: 1fr; }
}

/* ===== FILTER BAR ===== */
.filter-bar {
  background: var(--bg-elev);
  padding: 1.25rem;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  display: grid;
  grid-template-columns: repeat(4, 1fr) auto;
  gap: 1rem;
  align-items: end;
  margin-bottom: 2rem;
}
.filter-field label {
  display: block;
  font-size: .75rem;
  text-transform: uppercase;
  letter-spacing: .08em;
  color: var(--text-muted);
  margin-bottom: .35rem;
  font-weight: 600;
}
.filter-field input, .filter-field select {
  width: 100%;
  background: var(--bg);
  border: 1px solid var(--border);
  color: var(--text);
  padding: .65rem .75rem;
  border-radius: 6px;
  font-family: inherit;
  font-size: .95rem;
}
.filter-field input:focus, .filter-field select:focus { outline: none; border-color: var(--gold); }
@media (max-width: 700px) {
  .filter-bar { grid-template-columns: 1fr 1fr; }
}

/* ===== FORMS ===== */
.form-page {
  padding: 4rem 0;
  flex: 1;
}
.form-wrap {
  max-width: 720px;
  margin: 0 auto;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 2.5rem;
}
.form-wrap h1 { margin-bottom: .5rem; }
.form-wrap .form-intro { color: var(--text-dim); margin-bottom: 2rem; }
.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.25rem;
}
.form-grid .full { grid-column: 1 / -1; }
.form-field label {
  display: block;
  font-size: .8rem;
  text-transform: uppercase;
  letter-spacing: .06em;
  color: var(--text-muted);
  margin-bottom: .4rem;
  font-weight: 600;
}
.form-field label .req { color: var(--gold); }
.form-field input, .form-field select, .form-field textarea {
  width: 100%;
  background: var(--bg);
  border: 1px solid var(--border);
  color: var(--text);
  padding: .8rem .9rem;
  border-radius: 6px;
  font-family: inherit;
  font-size: .95rem;
  transition: border-color .2s;
}
.form-field input:focus, .form-field select:focus, .form-field textarea:focus {
  outline: none;
  border-color: var(--gold);
}
.form-field textarea { min-height: 130px; resize: vertical; }
.form-footnote { color: var(--text-muted); font-size: .85rem; margin-top: 1rem; text-align: center; }
.form-submit-row { margin-top: 1.5rem; }
.form-submit-row .btn { width: 100%; padding: 1rem; font-size: 1rem; }

.alert {
  padding: 1rem 1.25rem;
  border-radius: 6px;
  margin-bottom: 1rem;
  font-size: .95rem;
  border: 1px solid;
}
.alert-success { background: rgba(92, 184, 92, 0.1); border-color: var(--success); color: #8edc8e; }
.alert-error { background: rgba(217, 83, 79, 0.1); border-color: var(--danger); color: #ee8e8a; }

@media (max-width: 600px) {
  .form-grid { grid-template-columns: 1fr; }
  .form-wrap { padding: 1.75rem; }
}

/* ===== CONTACT PAGE ===== */
.contact-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 3rem;
}
@media (max-width: 900px) {
  .contact-grid { grid-template-columns: 1fr; }
}

/* ===== PAGE HERO (sub-pages) ===== */
.page-hero {
  background: var(--bg-elev);
  border-bottom: 1px solid var(--border);
  padding: 4rem 0 3rem;
  text-align: center;
}
.page-hero .eyebrow {
  color: var(--gold);
  font-size: .8rem;
  text-transform: uppercase;
  letter-spacing: .12em;
  font-weight: 600;
  margin-bottom: .5rem;
}
.page-hero p { color: var(--text-dim); max-width: 620px; margin: 1rem auto 0; }

/* ===== UTILITY ===== */
.text-center { text-align: center; }
.mt-2 { margin-top: 1rem; }
.hidden { display: none !important; }

/* ===== CRM SPECIFIC ===== */
.crm-body { background: var(--bg); }
.crm-shell { display: flex; flex-direction: column; min-height: 100vh; }
.crm-header {
  background: var(--bg-elev);
  border-bottom: 1px solid var(--border);
  padding: 1rem 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
}
.crm-title { display: flex; align-items: center; gap: .65rem; font-weight: 700; }
.crm-title svg { color: var(--gold); width: 24px; height: 24px; }
.crm-actions { display: flex; gap: .5rem; flex-wrap: wrap; }

.crm-main { padding: 2rem 1.5rem; max-width: 1400px; margin: 0 auto; width: 100%; }

.stats-row {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1rem;
  margin-bottom: 2rem;
}
.stat-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.25rem 1.5rem;
}
.stat-card .label { color: var(--text-muted); font-size: .75rem; text-transform: uppercase; letter-spacing: .08em; font-weight: 600; }
.stat-card .value { font-size: 2rem; font-weight: 800; color: var(--gold); margin-top: .25rem; }
@media (max-width: 700px) {
  .stats-row { grid-template-columns: repeat(2, 1fr); }
}

.tabs {
  display: flex;
  gap: .25rem;
  margin-bottom: 1rem;
  border-bottom: 1px solid var(--border);
  flex-wrap: wrap;
}
.tab {
  padding: .65rem 1.1rem;
  background: none;
  border: none;
  color: var(--text-dim);
  cursor: pointer;
  font-family: inherit;
  font-size: .9rem;
  font-weight: 500;
  border-bottom: 2px solid transparent;
  margin-bottom: -1px;
  transition: all .15s;
}
.tab:hover { color: var(--text); }
.tab.active { color: var(--gold); border-bottom-color: var(--gold); }

.toolbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  margin-bottom: 1rem;
  flex-wrap: wrap;
}
.search-input {
  background: var(--bg-card);
  border: 1px solid var(--border);
  color: var(--text);
  padding: .65rem .9rem;
  border-radius: 6px;
  font-family: inherit;
  font-size: .9rem;
  width: 280px;
  max-width: 100%;
}
.search-input:focus { outline: none; border-color: var(--gold); }

.leads-table-wrap {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}
.leads-table {
  width: 100%;
  border-collapse: collapse;
  font-size: .9rem;
}
.leads-table th {
  text-align: left;
  padding: .85rem 1rem;
  background: var(--bg-elev);
  color: var(--text-muted);
  font-size: .75rem;
  text-transform: uppercase;
  letter-spacing: .08em;
  font-weight: 600;
  border-bottom: 1px solid var(--border);
  white-space: nowrap;
}
.leads-table td {
  padding: .85rem 1rem;
  border-bottom: 1px solid var(--border);
  color: var(--text);
}
.leads-table tbody tr { cursor: pointer; transition: background .15s; }
.leads-table tbody tr:hover { background: rgba(201,168,76,0.05); }
.leads-table tbody tr:last-child td { border-bottom: none; }
.leads-table .actions { display: flex; gap: .35rem; }
.empty-state {
  padding: 4rem 2rem;
  text-align: center;
  color: var(--text-muted);
}
.empty-state svg { width: 56px; height: 56px; color: var(--border); margin-bottom: 1rem; }

.status-badge {
  display: inline-block;
  padding: 3px 9px;
  border-radius: 4px;
  font-size: .72rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .04em;
}
.status-New { background: rgba(74,144,226,0.15); color: #6fa9e8; border: 1px solid rgba(74,144,226,0.35); }
.status-Contacted { background: rgba(240,173,78,0.15); color: #f4be72; border: 1px solid rgba(240,173,78,0.35); }
.status-PreQual { background: rgba(201,168,76,0.15); color: var(--gold-soft); border: 1px solid rgba(201,168,76,0.35); }
.status-Closed { background: rgba(92,184,92,0.15); color: #8edc8e; border: 1px solid rgba(92,184,92,0.35); }
.status-Lost { background: rgba(217,83,79,0.15); color: #ee8e8a; border: 1px solid rgba(217,83,79,0.35); }

/* CRM Login */
.login-screen {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  padding: 1rem;
}
.login-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 2.5rem;
  max-width: 400px;
  width: 100%;
  text-align: center;
}
.login-card svg { color: var(--gold); width: 48px; height: 48px; margin: 0 auto 1rem; }
.login-card h2 { margin-bottom: .5rem; }
.login-card p { color: var(--text-dim); margin-bottom: 1.5rem; font-size: .9rem; }
.login-card input {
  width: 100%;
  background: var(--bg);
  border: 1px solid var(--border);
  color: var(--text);
  padding: .85rem 1rem;
  border-radius: 6px;
  font-family: inherit;
  font-size: 1rem;
  margin-bottom: 1rem;
  text-align: center;
}
.login-card input:focus { outline: none; border-color: var(--gold); }
.login-error { color: var(--danger); font-size: .85rem; margin-top: .5rem; min-height: 1.2em; }

/* Side panel */
.side-panel-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.6);
  z-index: 199;
  opacity: 0;
  pointer-events: none;
  transition: opacity .2s;
}
.side-panel-backdrop.open { opacity: 1; pointer-events: auto; }
.side-panel {
  position: fixed;
  top: 0; right: 0; bottom: 0;
  width: 480px;
  max-width: 100%;
  background: var(--bg-elev);
  border-left: 1px solid var(--border);
  z-index: 200;
  transform: translateX(100%);
  transition: transform .25s ease;
  display: flex;
  flex-direction: column;
}
.side-panel.open { transform: translateX(0); }
.side-panel-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.25rem 1.5rem;
  border-bottom: 1px solid var(--border);
}
.side-panel-close {
  background: none;
  border: none;
  color: var(--text-dim);
  cursor: pointer;
  font-size: 1.5rem;
  padding: .25rem .5rem;
}
.side-panel-close:hover { color: var(--text); }
.side-panel-body { flex: 1; overflow-y: auto; padding: 1.5rem; }
.detail-field { margin-bottom: 1.25rem; }
.detail-field .label { font-size: .75rem; text-transform: uppercase; letter-spacing: .06em; color: var(--text-muted); font-weight: 600; margin-bottom: .25rem; }
.detail-field .value { color: var(--text); font-size: .95rem; word-break: break-word; }
.side-panel-footer {
  padding: 1.25rem 1.5rem;
  border-top: 1px solid var(--border);
  display: flex;
  gap: .5rem;
}

/* Modal */
.modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.7);
  z-index: 300;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}
.modal-backdrop.open { display: flex; }
.modal {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  max-width: 600px;
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
}
.modal-header {
  padding: 1.25rem 1.5rem;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.modal-body { padding: 1.5rem; }
.modal-footer {
  padding: 1.25rem 1.5rem;
  border-top: 1px solid var(--border);
  display: flex;
  justify-content: flex-end;
  gap: .5rem;
}

@media (max-width: 900px) {
  .leads-table-wrap { overflow-x: auto; }
  .leads-table { min-width: 800px; }
}

/* ===== REPO BADGE (cards + table) ===== */
.repo-badge {
  display: inline-block;
  padding: 3px 9px;
  border-radius: 4px;
  font-size: .7rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: .08em;
  background: linear-gradient(135deg, var(--gold-dark), var(--gold));
  color: #111;
  border: none;
  box-shadow: 0 2px 6px rgba(201,168,76,0.35);
}
.home-card-img .repo-badge {
  position: absolute;
  top: 12px;
  left: 12px;
  z-index: 2;
}
.home-card-img .badge.repo-badge { /* if used as .badge */
  background: linear-gradient(135deg, var(--gold-dark), var(--gold));
  color: #111;
}
.price-strike {
  color: var(--text-muted);
  text-decoration: line-through;
  font-size: .9rem;
  font-weight: 500;
  display: block;
  margin-bottom: 2px;
}

/* ===== INVENTORY (CRM) ===== */
.inv-toolbar {
  display: flex;
  gap: .75rem;
  flex-wrap: wrap;
  align-items: center;
  margin-bottom: 1rem;
}
.inv-toolbar select,
.inv-toolbar .search-input {
  background: var(--bg-card);
  border: 1px solid var(--border);
  color: var(--text);
  padding: .55rem .8rem;
  border-radius: 6px;
  font-family: inherit;
  font-size: .85rem;
}
.inv-toolbar select:focus,
.inv-toolbar .search-input:focus { outline: none; border-color: var(--gold); }

.inv-table-wrap {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}
.inv-table {
  width: 100%;
  border-collapse: collapse;
  font-size: .88rem;
}
.inv-table th {
  text-align: left;
  padding: .75rem .9rem;
  background: var(--bg-elev);
  color: var(--text-muted);
  font-size: .72rem;
  text-transform: uppercase;
  letter-spacing: .08em;
  font-weight: 600;
  border-bottom: 1px solid var(--border);
  white-space: nowrap;
}
.inv-table td {
  padding: .75rem .9rem;
  border-bottom: 1px solid var(--border);
  color: var(--text);
  vertical-align: middle;
}
.inv-table tbody tr:last-child td { border-bottom: none; }
.inv-table tbody tr:hover { background: rgba(201,168,76,0.04); }
.inv-table .actions { display: flex; gap: .35rem; }
.inv-status {
  display: inline-block;
  padding: 3px 8px;
  border-radius: 4px;
  font-size: .68rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .05em;
}
.inv-status-Available { background: rgba(92,184,92,0.15); color: #8edc8e; border: 1px solid rgba(92,184,92,0.35); }
.inv-status-UnderContract { background: rgba(240,173,78,0.15); color: #f4be72; border: 1px solid rgba(240,173,78,0.35); }
.inv-status-Sold { background: rgba(120,120,120,0.15); color: #aaa; border: 1px solid rgba(120,120,120,0.35); }
.inv-status-Repo { background: linear-gradient(135deg, var(--gold-dark), var(--gold)); color: #111; }

@media (max-width: 1000px) {
  .inv-table-wrap { overflow-x: auto; }
  .inv-table { min-width: 950px; }
}

/* ===== DEAL BUILDER (side panel) ===== */
.deal-section {
  margin-top: 1.5rem;
  padding-top: 1.25rem;
  border-top: 1px solid var(--border);
}
.deal-section h4 {
  color: var(--gold);
  font-size: .85rem;
  text-transform: uppercase;
  letter-spacing: .08em;
  margin-bottom: 1rem;
}
.deal-addons {
  display: flex;
  flex-direction: column;
  gap: .5rem;
  margin-top: .5rem;
}
.deal-addon {
  display: grid;
  grid-template-columns: 24px 1fr 110px;
  align-items: center;
  gap: .65rem;
  padding: .5rem .65rem;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 6px;
}
.deal-addon input[type="checkbox"] {
  width: 18px; height: 18px; accent-color: var(--gold); cursor: pointer;
}
.deal-addon label {
  color: var(--text);
  font-size: .9rem;
  cursor: pointer;
  margin: 0;
}
.deal-addon .addon-price-wrap {
  display: flex;
  align-items: center;
  gap: 4px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 4px;
  padding: 2px 6px;
}
.deal-addon .addon-price-wrap span {
  color: var(--text-muted);
  font-size: .85rem;
}
.deal-addon input[type="number"] {
  background: transparent;
  border: none;
  color: var(--text);
  font-family: inherit;
  font-size: .85rem;
  width: 80px;
  padding: 4px 2px;
  text-align: right;
}
.deal-addon input[type="number"]:focus { outline: none; }
.deal-total {
  margin-top: 1rem;
  padding: 1rem 1.25rem;
  background: linear-gradient(135deg, rgba(201,168,76,0.08), rgba(201,168,76,0.02));
  border: 1px solid var(--gold);
  border-radius: 8px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.deal-total .label {
  color: var(--text-muted);
  font-size: .75rem;
  text-transform: uppercase;
  letter-spacing: .08em;
  font-weight: 600;
}
.deal-total .value {
  color: var(--gold);
  font-size: 1.6rem;
  font-weight: 800;
}
