/* =========================================================
   FindMyBid Design System
   A professional real-estate-tech visual language.
   ========================================================= */

:root {
  /* Brand palette — deep navy + slate, single confident accent */
  --navy-950: #0b1220;
  --navy-900: #0f1a2e;
  --navy-800: #16233d;
  --navy-700: #1f314f;
  --navy-600: #2c4267;
  --slate-500: #64748b;
  --slate-400: #94a3b8;
  --slate-300: #cbd5e1;
  --slate-200: #e2e8f0;
  --slate-100: #f1f5f9;
  --slate-50: #f8fafc;
  --white: #ffffff;

  --accent-600: #2563eb;
  --accent-500: #3b82f6;
  --accent-100: #dbeafe;
  --accent-50: #eff6ff;

  --success-600: #059669;
  --success-100: #d1fae5;
  --warning-600: #d97706;
  --warning-100: #fef3c7;
  --danger-600: #dc2626;
  --danger-100: #fee2e2;
  --violet-600: #7c3aed;
  --violet-100: #ede9fe;

  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 16px;
  --radius-xl: 22px;

  --shadow-sm: 0 1px 2px rgba(15, 26, 46, 0.06);
  --shadow-md: 0 4px 16px rgba(15, 26, 46, 0.08);
  --shadow-lg: 0 12px 32px rgba(15, 26, 46, 0.12);
  --shadow-focus: 0 0 0 3px rgba(37, 99, 235, 0.25);

  --font-sans: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;

  --max-width: 1200px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font-sans);
  color: var(--navy-900);
  background: var(--slate-50);
  -webkit-font-smoothing: antialiased;
  line-height: 1.5;
}

img { max-width: 100%; display: block; }

a { color: inherit; text-decoration: none; }

h1, h2, h3, h4, h5 { margin: 0; font-weight: 700; letter-spacing: -0.02em; color: var(--navy-950); }
p { margin: 0; }
ul { margin: 0; padding: 0; list-style: none; }
button { font-family: inherit; }
input, select, textarea { font-family: inherit; }

/* ---------- Layout ---------- */
.wrap {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
}
.section { padding: 72px 0; }
.section-sm { padding: 40px 0; }

@media (max-width: 720px) {
  .section { padding: 44px 0; }
  .wrap { padding: 0 16px; }
}

/* ---------- Top Nav ---------- */
.topnav {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255,255,255,0.92);
  backdrop-filter: saturate(180%) blur(10px);
  border-bottom: 1px solid var(--slate-200);
}
.topnav-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
  height: 68px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  font-size: 19px;
  color: var(--navy-950);
}
.brand-mark {
  width: 32px; height: 32px;
  border-radius: 9px;
  background: linear-gradient(135deg, var(--accent-600), var(--navy-700));
  display: flex; align-items: center; justify-content: center;
  color: white; font-weight: 800; font-size: 15px;
  flex-shrink: 0;
}
.nav-links {
  display: flex;
  align-items: center;
  gap: 4px;
}
.nav-link {
  padding: 9px 14px;
  border-radius: 8px;
  font-size: 14.5px;
  font-weight: 600;
  color: var(--slate-500);
  white-space: nowrap;
}
.nav-link:hover { background: var(--slate-100); color: var(--navy-900); }
.nav-link.active { color: var(--accent-600); background: var(--accent-50); }
.nav-right { display: flex; align-items: center; gap: 10px; }

.role-toggle {
  display: flex;
  background: var(--slate-100);
  border-radius: 9px;
  padding: 3px;
  gap: 2px;
  border: 1px solid var(--slate-200);
}
.role-toggle button {
  border: none;
  background: transparent;
  padding: 7px 12px;
  border-radius: 7px;
  font-size: 13px;
  font-weight: 600;
  color: var(--slate-500);
  cursor: pointer;
}
.role-toggle button.active {
  background: var(--navy-950);
  color: white;
}

.nav-toggle-btn {
  display: none;
  border: 1px solid var(--slate-200);
  background: white;
  border-radius: 8px;
  padding: 8px 10px;
  cursor: pointer;
}

.mobile-nav-panel { display: none; }
.role-toggle-mobile { display: none; margin-top: 10px; }
@media (max-width: 900px) {
  .nav-links { display: none; }
  .nav-toggle-btn { display: inline-flex; }
  .mobile-nav-panel {
    flex-direction: column;
    padding: 8px 16px 14px;
    border-top: 1px solid var(--slate-200);
    background: white;
  }
  .mobile-nav-panel:not([hidden]) { display: flex; }
  .mobile-nav-panel .nav-link { padding: 12px 10px; }
}
@media (max-width: 560px) {
  .nav-right > .role-toggle:not(.role-toggle-mobile) { display: none; }
  .role-toggle-mobile { display: flex; width: fit-content; }
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-weight: 650;
  font-size: 14.5px;
  padding: 11px 20px;
  border-radius: 9px;
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform .05s ease, box-shadow .15s ease, background .15s ease, border-color .15s ease;
  white-space: nowrap;
}
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--accent-600); color: white; box-shadow: var(--shadow-sm); }
.btn-primary:hover { background: #1d4fd8; }
.btn-dark { background: var(--navy-950); color: white; }
.btn-dark:hover { background: var(--navy-800); }
.btn-outline { background: white; color: var(--navy-900); border-color: var(--slate-300); }
.btn-outline:hover { border-color: var(--slate-400); background: var(--slate-50); }
.btn-ghost { background: transparent; color: var(--navy-900); }
.btn-ghost:hover { background: var(--slate-100); }
.btn-danger-outline { background: white; color: var(--danger-600); border-color: var(--danger-100); }
.btn-danger-outline:hover { background: var(--danger-100); }
.btn-sm { padding: 7px 13px; font-size: 13px; border-radius: 7px; }
.btn-lg { padding: 15px 26px; font-size: 16px; border-radius: 11px; }
.btn-block { width: 100%; }
.btn:disabled { opacity: .5; cursor: not-allowed; }

/* ---------- Cards ---------- */
.card {
  background: white;
  border: 1px solid var(--slate-200);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
}
.card-pad { padding: 24px; }
.card-hover:hover { box-shadow: var(--shadow-md); border-color: var(--slate-300); }

/* ---------- Badges / Status ---------- */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 11px;
  border-radius: 999px;
  font-size: 12.5px;
  font-weight: 650;
  white-space: nowrap;
}
.badge-dot { width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.badge-slate { background: var(--slate-100); color: var(--slate-500); }
.badge-blue { background: var(--accent-100); color: var(--accent-600); }
.badge-green { background: var(--success-100); color: var(--success-600); }
.badge-amber { background: var(--warning-100); color: var(--warning-600); }
.badge-red { background: var(--danger-100); color: var(--danger-600); }
.badge-violet { background: var(--violet-100); color: var(--violet-600); }

/* ---------- Forms ---------- */
.field { display: flex; flex-direction: column; gap: 7px; margin-bottom: 18px; }
.field label { font-size: 13.5px; font-weight: 650; color: var(--navy-800); }
.field .hint { font-size: 12.5px; color: var(--slate-500); font-weight: 400; }
.input, .select, .textarea {
  border: 1px solid var(--slate-300);
  border-radius: 9px;
  padding: 11px 13px;
  font-size: 14.5px;
  color: var(--navy-950);
  background: white;
  width: 100%;
  outline: none;
  transition: border-color .15s, box-shadow .15s;
}
.input:focus, .select:focus, .textarea:focus {
  border-color: var(--accent-500);
  box-shadow: var(--shadow-focus);
}
.textarea { resize: vertical; min-height: 90px; }
.input-prefix-wrap { position: relative; }
.input-prefix { position: absolute; left: 13px; top: 50%; transform: translateY(-50%); color: var(--slate-400); font-weight: 600; }
.input-prefix-wrap .input { padding-left: 26px; }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
@media (max-width: 640px) { .field-row { grid-template-columns: 1fr; } }

.chip-grid { display: flex; flex-wrap: wrap; gap: 8px; }
.chip {
  border: 1.5px solid var(--slate-300);
  background: white;
  padding: 9px 14px;
  border-radius: 9px;
  font-size: 13.5px;
  font-weight: 600;
  color: var(--navy-800);
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 7px;
  user-select: none;
}
.chip:hover { border-color: var(--accent-500); }
.chip.selected { border-color: var(--accent-600); background: var(--accent-50); color: var(--accent-600); }
.chip .chip-icon { font-size: 15px; }

/* ---------- Grid helpers ---------- */
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
@media (max-width: 900px) { .grid-3, .grid-4 { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 640px) { .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; } }

/* ---------- App shell w/ sidebar ---------- */
.app-shell { display: flex; min-height: calc(100vh - 68px); }
.sidebar {
  width: 240px;
  flex-shrink: 0;
  border-right: 1px solid var(--slate-200);
  background: white;
  padding: 24px 14px;
}
.sidebar-link {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border-radius: 9px;
  font-size: 14px;
  font-weight: 600;
  color: var(--slate-500);
  margin-bottom: 2px;
}
.sidebar-link:hover { background: var(--slate-100); color: var(--navy-900); }
.sidebar-link.active { background: var(--navy-950); color: white; }
.sidebar-section-label {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--slate-400);
  padding: 18px 12px 8px;
}
.main-col { flex: 1; min-width: 0; padding: 32px 36px 80px; }
@media (max-width: 860px) {
  .app-shell { flex-direction: column; }
  .sidebar { width: 100%; border-right: none; border-bottom: 1px solid var(--slate-200); display: flex; overflow-x: auto; padding: 10px 14px; gap: 4px; }
  .sidebar-section-label { display: none; }
  .sidebar-link { white-space: nowrap; }
  .main-col { padding: 22px 16px 60px; }
}

.page-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 28px;
  flex-wrap: wrap;
}
.page-head h1 { font-size: 26px; }
.eyebrow {
  font-size: 12.5px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--accent-600);
  margin-bottom: 8px;
}
.subtle { color: var(--slate-500); }

/* ---------- Table ---------- */
.table-wrap { overflow-x: auto; border-radius: var(--radius-lg); border: 1px solid var(--slate-200); background: white; }
table { width: 100%; border-collapse: collapse; font-size: 14px; }
th { text-align: left; padding: 13px 16px; background: var(--slate-50); font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.04em; color: var(--slate-500); border-bottom: 1px solid var(--slate-200); }
td { padding: 14px 16px; border-bottom: 1px solid var(--slate-100); vertical-align: middle; }
tr:last-child td { border-bottom: none; }

/* ---------- Hero ---------- */
.hero {
  position: relative;
  background: radial-gradient(circle at 15% 20%, #16233d, #0b1220 65%);
  color: white;
  overflow: hidden;
}
.hero-grid {
  position: absolute; inset: 0;
  background-image: linear-gradient(rgba(255,255,255,0.05) 1px, transparent 1px), linear-gradient(90deg, rgba(255,255,255,0.05) 1px, transparent 1px);
  background-size: 44px 44px;
  mask-image: radial-gradient(circle at 30% 20%, black, transparent 70%);
}
.hero-inner { position: relative; padding: 96px 0 88px; text-align: center; }
.hero h1 { color: white; font-size: 52px; line-height: 1.08; max-width: 780px; margin: 0 auto 22px; }
.hero p.lead { color: var(--slate-300); font-size: 18px; max-width: 560px; margin: 0 auto 36px; }
.hero-ctas { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; margin-bottom: 18px; }
.hero-subctas { font-size: 13px; color: var(--slate-400); }
@media (max-width: 640px) {
  .hero h1 { font-size: 34px; }
  .hero-inner { padding: 60px 0 56px; }
}

.stat-strip { display: flex; justify-content: center; gap: 56px; margin-top: 56px; flex-wrap: wrap; }
.stat-strip .stat-num { font-size: 30px; font-weight: 800; color: white; }
.stat-strip .stat-label { font-size: 13px; color: var(--slate-400); margin-top: 4px; }

/* ---------- Steps / how it works ---------- */
.step-flow { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
@media (max-width: 900px) { .step-flow { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .step-flow { grid-template-columns: 1fr; } }
.step-card { position: relative; padding-top: 6px; }
.step-num {
  width: 40px; height: 40px; border-radius: 11px;
  background: var(--navy-950); color: white;
  display: flex; align-items: center; justify-content: center;
  font-weight: 800; font-size: 16px; margin-bottom: 16px;
}

/* ---------- Photo upload dropzone ---------- */
.dropzone {
  border: 2px dashed var(--slate-300);
  border-radius: var(--radius-lg);
  padding: 36px 20px;
  text-align: center;
  color: var(--slate-500);
  background: var(--slate-50);
  cursor: pointer;
  transition: border-color .15s, background .15s;
}
.dropzone:hover { border-color: var(--accent-500); background: var(--accent-50); }
.photo-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(120px, 1fr)); gap: 12px; margin-top: 16px; }
.photo-thumb { position: relative; border-radius: 10px; overflow: hidden; aspect-ratio: 4/3; background: var(--slate-200); }
.photo-thumb img { width: 100%; height: 100%; object-fit: cover; }
.photo-thumb .photo-primary-tag {
  position: absolute; top: 6px; left: 6px;
  background: var(--navy-950); color: white; font-size: 10.5px; font-weight: 700;
  padding: 3px 8px; border-radius: 999px;
}
.photo-thumb .photo-remove {
  position: absolute; top: 6px; right: 6px;
  width: 22px; height: 22px; border-radius: 50%;
  background: rgba(11,18,32,0.75); color: white; border: none;
  display: flex; align-items: center; justify-content: center; cursor: pointer; font-size: 13px;
}

/* ---------- Stepper (wizard) ---------- */
.wizard-steps { display: flex; align-items: center; gap: 0; margin-bottom: 36px; flex-wrap: wrap; }
.wizard-step { display: flex; align-items: center; gap: 10px; }
.wizard-step .circle {
  width: 30px; height: 30px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-weight: 700; font-size: 13px;
  background: var(--slate-200); color: var(--slate-500);
  flex-shrink: 0;
}
.wizard-step.done .circle { background: var(--success-600); color: white; }
.wizard-step.current .circle { background: var(--accent-600); color: white; }
.wizard-step .label { font-size: 13.5px; font-weight: 650; color: var(--slate-400); }
.wizard-step.current .label, .wizard-step.done .label { color: var(--navy-900); }
.wizard-connector { width: 34px; height: 2px; background: var(--slate-200); margin: 0 8px; }
@media (max-width: 720px) {
  .wizard-step .label { display: none; }
  .wizard-connector { width: 16px; }
}

/* ---------- Repair scope builder ---------- */
.category-item-card {
  border: 1px solid var(--slate-200);
  border-radius: var(--radius-md);
  padding: 18px;
  margin-bottom: 12px;
  background: white;
}
.category-item-head { display: flex; align-items: center; justify-content: between; justify-content: space-between; gap: 12px; margin-bottom: 4px; }
.category-item-head .name { font-weight: 700; font-size: 15px; display: flex; align-items: center; gap: 8px; }

/* ---------- Bid comparison table ---------- */
.compare-table th.contractor-col { min-width: 168px; }
.compare-table .total-row td { font-weight: 800; font-size: 15px; background: var(--slate-50); }
.compare-table .lowest { color: var(--success-600); font-weight: 700; }
.contractor-col-head { display: flex; flex-direction: column; gap: 6px; }
.avatar-circle {
  width: 34px; height: 34px; border-radius: 50%;
  background: var(--navy-700); color: white;
  display: flex; align-items: center; justify-content: center;
  font-weight: 700; font-size: 13px;
}

/* ---------- Footer ---------- */
.site-footer { border-top: 1px solid var(--slate-200); background: white; padding: 48px 0 32px; margin-top: 40px; }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 32px; margin-bottom: 32px; }
@media (max-width: 720px) { .footer-grid { grid-template-columns: 1fr 1fr; } }
.footer-col h4 { font-size: 13px; margin-bottom: 12px; color: var(--navy-900); }
.footer-col a { display: block; font-size: 13.5px; color: var(--slate-500); padding: 5px 0; }
.footer-col a:hover { color: var(--accent-600); }
.footer-bottom { display: flex; justify-content: space-between; align-items: center; padding-top: 24px; border-top: 1px solid var(--slate-200); font-size: 13px; color: var(--slate-400); flex-wrap: wrap; gap: 10px; }

/* ---------- Misc utility ---------- */
.flex { display: flex; }
.flex-col { display: flex; flex-direction: column; }
.items-center { align-items: center; }
.justify-between { justify-content: space-between; }
.gap-6 { gap: 6px; } .gap-8 { gap: 8px; } .gap-10 { gap: 10px; } .gap-12 { gap: 12px; } .gap-16 { gap: 16px; } .gap-20 { gap: 20px; }
.mt-4{margin-top:4px;} .mt-8{margin-top:8px;} .mt-12{margin-top:12px;} .mt-16{margin-top:16px;} .mt-24{margin-top:24px;} .mt-32{margin-top:32px;} .mt-40{margin-top:40px;}
.mb-8{margin-bottom:8px;} .mb-12{margin-bottom:12px;} .mb-16{margin-bottom:16px;} .mb-24{margin-bottom:24px;}
.text-sm { font-size: 13px; } .text-xs { font-size: 12px; }
.text-slate { color: var(--slate-500); }
.text-right { text-align: right; }
.text-center { text-align: center; }
.fw-600 { font-weight: 600; } .fw-700 { font-weight: 700; }
.divider { height: 1px; background: var(--slate-200); margin: 20px 0; }
.empty-state { text-align: center; padding: 60px 20px; color: var(--slate-500); }
.empty-state .icon { font-size: 40px; margin-bottom: 14px; }
.toast-container { position: fixed; bottom: 24px; right: 24px; z-index: 200; display: flex; flex-direction: column; gap: 10px; }
.toast { background: var(--navy-950); color: white; padding: 13px 18px; border-radius: 10px; box-shadow: var(--shadow-lg); font-size: 14px; font-weight: 600; display: flex; align-items: center; gap: 10px; animation: toastIn .2s ease; }
@keyframes toastIn { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: translateY(0); } }
.kicker-pill { display: inline-flex; align-items: center; gap: 8px; background: var(--slate-100); padding: 6px 14px; border-radius: 999px; font-size: 13px; font-weight: 650; color: var(--slate-500); }

.property-photo-hero { width: 100%; aspect-ratio: 16/9; object-fit: cover; border-radius: var(--radius-lg); background: var(--slate-200); }
.icon-btn { width: 36px; height: 36px; border-radius: 9px; border: 1px solid var(--slate-300); background: white; display: flex; align-items: center; justify-content: center; cursor: pointer; }
.icon-btn:hover { background: var(--slate-50); }

.locked-note { display: flex; gap: 10px; align-items: flex-start; background: var(--accent-50); border: 1px solid var(--accent-100); padding: 14px 16px; border-radius: 10px; font-size: 13.5px; color: var(--navy-800); }
