/* ═══════════════════════════════════════════════════════
   ImobiliarePro — Main Stylesheet (Warm Theme)
   Based on model-3-warm wireframe
   ═══════════════════════════════════════════════════════ */

/* ── CSS Variables ── */
:root {
  --accent: #e8742a;
  --accent-hover: #d4631f;
  --accent-light: #fef5ee;
  --accent-dim: rgba(232,116,42,0.08);
  --bg: #faf8f5;
  --bg2: #ffffff;
  --bg3: #f5f0eb;
  --text: #3b2314;
  --text-muted: #a89585;
  --text-soft: #7a6455;
  --border: #e8ddd2;
  --border2: #f0e8df;
  --radius: 14px;
  --radius-sm: 10px;
  --nav-h: 64px;
  --success: #16a34a;
  --error: #dc2626;
  --warning: #f59e0b;
  --info: #3b82f6;
}

/* ── Reset ── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: 'Segoe UI', -apple-system, BlinkMacSystemFont, Roboto, sans-serif;
  background: var(--bg);
  color: var(--text);
  font-size: 14px;
  line-height: 1.6;
  overflow-x: hidden;
}
a { color: var(--accent); text-decoration: none; }
a:hover { color: var(--accent-hover); }
img { max-width: 100%; height: auto; display: block; }

/* ── Container ── */
.container { max-width: 1200px; margin: 0 auto; padding: 0 40px; }

/* ═══ NAVIGATION ═══ */
.nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 1000;
  height: var(--nav-h); background: var(--bg2);
  border-bottom: 1px solid var(--border);
  display: flex; align-items: center; padding: 0 40px;
  box-shadow: 0 1px 8px rgba(0,0,0,0.04);
}
.nav-logo { display: flex; align-items: center; gap: 8px; margin-right: 32px; text-decoration: none; }
.nav-logo-icon {
  width: 34px; height: 34px; border-radius: 10px; background: var(--accent);
  display: flex; align-items: center; justify-content: center; font-size: 18px;
  color: #fff;
}
.nav-logo-text { font-size: 17px; font-weight: 800; color: var(--text); letter-spacing: -0.3px; }
.nav-links { display: flex; gap: 2px; flex: 1; }
.nav-link {
  padding: 7px 16px; border: none; background: transparent;
  font-size: 14px; color: var(--text-soft); border-radius: var(--radius-sm);
  cursor: pointer; font-family: inherit; transition: all 0.15s;
  white-space: nowrap; text-decoration: none; display: inline-flex; align-items: center;
}
.nav-link:hover { background: var(--bg3); color: var(--text); }
.nav-link.active { background: var(--accent-dim); color: var(--accent); font-weight: 600; }
.nav-actions { display: flex; gap: 8px; align-items: center; }
.nav-act {
  padding: 9px 20px; border-radius: var(--radius-sm); font-size: 13px;
  font-weight: 600; cursor: pointer; font-family: inherit; border: none;
  transition: all 0.15s; text-decoration: none; display: inline-flex; align-items: center;
}
.nav-act.ghost { background: transparent; border: 1.5px solid var(--border2); color: var(--text-soft); }
.nav-act.ghost:hover { border-color: var(--accent); color: var(--accent); }
.nav-act.solid { background: var(--accent); color: #fff; }
.nav-act.solid:hover { background: var(--accent-hover); }

/* Nav favorites button */
.nav-fav {
  position: relative; width: 42px; height: 42px; border-radius: 50%;
  border: 1.5px solid var(--border2); background: var(--bg2);
  cursor: pointer; display: flex; align-items: center; justify-content: center;
  transition: all 0.2s ease; flex-shrink: 0;
}
.nav-fav:hover { border-color: var(--accent); background: var(--accent-light); transform: scale(1.08); }
.nav-fav-icon { width: 18px; height: 18px; fill: #a8a29e; transition: fill 0.2s; }
.nav-fav:hover .nav-fav-icon { fill: var(--accent); }
.nav-fav-badge {
  position: absolute; top: -5px; right: -5px;
  min-width: 19px; height: 19px; padding: 0 5px;
  background: var(--accent); color: #fff; border-radius: 10px;
  font-size: 11px; font-weight: 700; line-height: 19px; text-align: center;
  border: 2px solid var(--bg2); box-sizing: content-box;
}

/* Mobile menu */
.nav-toggle { display: none; background: none; border: none; font-size: 24px; cursor: pointer; padding: 8px; }
.nav-mobile-auth { display: none; }

/* User dropdown */
.nav-user { position: relative; }
.nav-user-btn {
  display: flex; align-items: center; gap: 8px;
  padding: 6px 14px; border-radius: var(--radius-sm);
  border: 1.5px solid var(--border2); background: var(--bg2);
  cursor: pointer; font-family: inherit; font-size: 13px; font-weight: 600;
  color: var(--text-soft); transition: all 0.15s;
}
.nav-user-btn:hover { border-color: var(--accent); color: var(--accent); }
.nav-user-avatar {
  width: 28px; height: 28px; border-radius: 50%;
  background: var(--accent-light); border: 1.5px solid var(--accent);
  display: flex; align-items: center; justify-content: center;
  color: var(--accent); font-weight: 800; font-size: 11px;
}
.nav-dropdown {
  position: absolute; top: calc(100% + 8px); right: 0;
  background: var(--bg2); border: 1.5px solid var(--border);
  border-radius: var(--radius-sm); padding: 8px;
  min-width: 180px; box-shadow: 0 12px 36px rgba(0,0,0,0.1);
  display: none; z-index: 1001;
}
.nav-dropdown.open { display: block; }
.nav-dropdown a {
  display: block; padding: 8px 14px; font-size: 13px;
  color: var(--text-soft); border-radius: 8px; transition: all 0.15s;
}
.nav-dropdown a:hover { background: var(--bg3); color: var(--text); }
.nav-dropdown-divider { height: 1px; background: var(--border); margin: 6px 0; }

/* ── Language Switcher ── */
.lang-switcher { position: relative; }
.lang-btn {
  display: flex; align-items: center; gap: 6px;
  padding: 6px 10px; border: 1.5px solid var(--border);
  border-radius: var(--radius-sm); background: var(--bg2);
  cursor: pointer; font-size: 13px; font-weight: 600;
  color: var(--text-soft); font-family: inherit;
  transition: all 0.15s;
}
.lang-btn:hover { border-color: var(--accent); color: var(--text); }
.lang-flag { font-size: 16px; line-height: 1; }
.lang-code { font-size: 12px; letter-spacing: 0.5px; }
.lang-dropdown {
  position: absolute; top: calc(100% + 6px); right: 0;
  background: var(--bg2); border: 1.5px solid var(--border);
  border-radius: var(--radius-sm); padding: 6px;
  min-width: 140px; box-shadow: 0 8px 24px rgba(0,0,0,0.1);
  display: none; z-index: 1002;
}
.lang-dropdown.open { display: block; }
.lang-option {
  display: flex; align-items: center; gap: 8px;
  padding: 8px 12px; font-size: 13px; color: var(--text-soft);
  border-radius: 8px; transition: all 0.15s; text-decoration: none;
}
.lang-option:hover { background: var(--bg3); color: var(--text); }
.lang-option.active { color: var(--accent); font-weight: 600; }

/* ═══ BUTTONS ═══ */
.btn {
  padding: 10px 20px; border-radius: var(--radius-sm); font-size: 14px;
  font-weight: 600; cursor: pointer; border: none; font-family: inherit;
  transition: all 0.15s; display: inline-flex; align-items: center; justify-content: center; gap: 6px;
}
.btn-primary { background: var(--accent); color: #fff; }
.btn-primary:hover { background: var(--accent-hover); transform: translateY(-1px); box-shadow: 0 4px 12px rgba(249,115,22,0.3); }
.btn-secondary { background: var(--bg3); color: var(--text-soft); border: 1.5px solid var(--border2); }
.btn-secondary:hover { border-color: var(--accent); color: var(--accent); background: var(--accent-light); }
.btn-danger { background: #fef2f2; color: #dc2626; border: 1.5px solid #fecaca; }
.btn-danger:hover { background: #dc2626; color: #fff; }
.btn-sm { padding: 7px 14px; font-size: 13px; }
.btn-lg { padding: 14px 28px; font-size: 16px; }
.btn-block { width: 100%; }
.btn:disabled, .btn[disabled] { opacity: 0.45; cursor: not-allowed; pointer-events: none; }

/* ═══ FORMS ═══ */
.form-group { margin-bottom: 18px; }
.form-label { font-size: 13px; font-weight: 600; color: var(--text-soft); display: block; margin-bottom: 6px; }
.form-hint { font-size: 12px; color: var(--text-muted); margin-top: 4px; }
.input {
  width: 100%; padding: 11px 16px; border: 1.5px solid var(--border2);
  border-radius: var(--radius-sm); font-size: 14px; font-family: inherit;
  background: var(--bg2); color: var(--text); outline: none; transition: all 0.15s;
}
.input:focus { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-dim); }
.input.error { border-color: var(--error); }
.input-error { font-size: 12px; color: var(--error); margin-top: 4px; }
.select {
  width: 100%; padding: 11px 36px 11px 16px; border: 1.5px solid var(--border2);
  border-radius: var(--radius-sm); font-size: 14px; font-family: inherit;
  background: var(--bg2); color: var(--text); cursor: pointer; outline: none;
  transition: border-color 0.15s, box-shadow 0.15s;
  appearance: none; -webkit-appearance: none; -moz-appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%239a8a78' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 12px center; background-size: 12px;
}
.select:hover { border-color: #d4c8bc; }
.select:focus { border-color: var(--accent); box-shadow: 0 0 0 3px rgba(232,116,42,0.12); }
textarea.input { resize: vertical; min-height: 100px; }

/* ═══ BADGES & TAGS ═══ */
.badge {
  display: inline-flex; align-items: center; gap: 6px; padding: 5px 14px;
  background: var(--accent-light); color: var(--accent); border-radius: 20px;
  font-size: 13px; font-weight: 600;
}
.tag {
  display: inline-block; padding: 4px 12px; background: var(--bg3);
  border: 1px solid var(--border); border-radius: 20px; font-size: 12px; color: var(--text-soft);
}
.pill {
  display: inline-block; padding: 3px 12px; border-radius: 20px;
  font-size: 12px; font-weight: 600;
}
.pill-orange { background: #fff7ed; color: #ea580c; border: 1px solid #fed7aa; }
.pill-green { background: #f0fdf4; color: #15803d; border: 1px solid #bbf7d0; }
.pill-blue { background: #eff6ff; color: #1d4ed8; border: 1px solid #bfdbfe; }
.pill-red { background: #fef2f2; color: #dc2626; border: 1px solid #fecaca; }

/* ═══ CARDS ═══ */
.card {
  background: var(--bg2); border: 1.5px solid var(--border); border-radius: var(--radius);
  overflow: hidden; transition: all 0.2s;
}
.card:hover { box-shadow: 0 12px 32px rgba(0,0,0,0.08); transform: translateY(-3px); border-color: var(--accent); }
.card-img {
  background: var(--bg3); height: 190px; display: flex; align-items: center;
  justify-content: center; font-size: 36px; position: relative; overflow: hidden;
}
.card-img img { width: 100%; height: 100%; object-fit: cover; transition: opacity 0.3s ease; }
.card-img img[src=""] { display: none; }
.card-badge { position: absolute; top: 12px; left: 12px; }
.card-fav {
  position: absolute; top: 12px; right: 12px; width: 32px; height: 32px;
  background: rgba(255,255,255,0.9); border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 14px; cursor: pointer; border: none; transition: all 0.15s;
}
.card-fav:hover { transform: scale(1.15); }
.card-fav.active { color: #ef4444; }
.card-body { padding: 18px; }
.card-price { font-size: 22px; font-weight: 800; color: var(--accent); letter-spacing: -0.5px; }
.card-title { font-size: 14px; font-weight: 600; margin: 5px 0; color: var(--text); }
.card-loc { font-size: 13px; color: var(--text-muted); }
.card-meta {
  font-size: 13px; color: var(--text-soft); display: flex; gap: 16px;
  margin-top: 10px; padding-top: 10px; border-top: 1px solid var(--border);
}

/* ═══ GRIDS ═══ */
.grid-2 { display: grid; grid-template-columns: repeat(2,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; }

/* ═══ HERO SECTION ═══ */
.hero { padding: 72px 0 80px; text-align: center; }
.hero-eyebrow { display: flex; align-items: center; justify-content: center; gap: 8px; margin-bottom: 20px; }
.hero h1 { font-size: 56px; font-weight: 900; line-height: 1.08; letter-spacing: -2.5px; margin-bottom: 20px; }
.hero h1 .hl { color: var(--accent); position: relative; display: inline-block; }
.hero h1 .hl::after {
  content: ''; position: absolute; bottom: -4px; left: 0; right: 0;
  height: 4px; background: var(--accent); border-radius: 4px; opacity: 0.4;
}
.hero-sub { font-size: 18px; color: var(--text-muted); max-width: 520px; margin: 0 auto 40px; line-height: 1.7; }

/* Search bar */
.search-tabs { display: flex; gap: 4px; justify-content: center; margin-bottom: 20px; }
.stab {
  padding: 9px 24px; border-radius: 30px; font-size: 14px; font-weight: 600;
  cursor: pointer; border: 2px solid var(--border2); background: var(--bg2);
  color: var(--text-soft); font-family: inherit; transition: all 0.15s;
  display: inline-flex; align-items: center; gap: 6px;
}
.stab.active { background: var(--accent); color: #fff; border-color: var(--accent); }
.search-card {
  max-width: 780px; margin: 0 auto; background: var(--bg2);
  border: 1.5px solid var(--border); border-radius: 20px; padding: 20px 24px;
  box-shadow: 0 8px 40px rgba(0,0,0,0.07);
  position: relative; z-index: 100; overflow: visible;
}
.search-card-row {
  display: flex; gap: 12px; align-items: stretch;
}
.search-field {
  flex: 1; display: flex; flex-direction: column; gap: 5px; justify-content: flex-end;
}
.search-field-label {
  font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.6px;
  color: var(--text-muted); padding-left: 2px;
  display: flex; align-items: center; gap: 4px;
}
.search-field .input,
.search-field .select {
  border-color: var(--border); background: var(--bg);
}
.search-field .input:hover,
.search-field .select:hover {
  border-color: var(--accent); background: var(--accent-light);
}
.search-field .input:focus,
.search-field .select:focus {
  border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-dim); background: var(--bg2);
}
.search-field .select {
  color: var(--text);
}
.search-btn-wrap {
  display: flex; flex-direction: column; justify-content: flex-end;
}
.search-btn-wrap .btn {
  padding: 11px 28px; font-size: 15px; white-space: nowrap; border-radius: var(--radius-sm);
  height: 42px; display: flex; align-items: center; gap: 6px;
}
.search-field .input,
.search-field .select { height: 42px; box-sizing: border-box; }

/* ═══ AUTOCOMPLETE ═══ */
.ac-wrap { position: relative; width: 100%; }
.ac-dropdown {
  position: absolute; top: 100%; left: 0; right: 0; z-index: 9999;
  background: var(--bg2); border: 1.5px solid var(--border);
  border-radius: var(--radius-sm); margin-top: 4px;
  box-shadow: 0 8px 30px rgba(0,0,0,0.10);
  max-height: 320px; overflow-y: auto;
}
.ac-item {
  display: flex; align-items: center; justify-content: space-between;
  padding: 10px 14px; cursor: pointer; transition: background 0.12s;
  gap: 8px; border-bottom: 1px solid var(--border2);
}
.ac-item:last-child { border-bottom: none; }
.ac-item:hover, .ac-item.ac-active { background: var(--accent-light); }
.ac-name {
  font-size: 14px; font-weight: 600; color: var(--text);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.ac-meta {
  display: flex; align-items: center; gap: 6px; flex-shrink: 0;
  font-size: 12px; color: var(--text-muted);
}
.ac-badge {
  display: inline-block; padding: 2px 7px; border-radius: 6px;
  font-size: 10px; font-weight: 700; text-transform: uppercase;
  letter-spacing: 0.4px; line-height: 1.4;
}
.ac-badge-municipiu { background: var(--accent); color: #fff; }
.ac-badge-oras { background: #e0d4c7; color: var(--text); }
.ac-badge-sector { background: #d4a76a; color: #fff; }
.ac-badge-comuna { background: var(--bg3); color: var(--text-soft); }
.ac-badge-sat { background: var(--bg3); color: var(--text-muted); }
/* Scrollbar styling for the dropdown */
.ac-dropdown::-webkit-scrollbar { width: 6px; }
.ac-dropdown::-webkit-scrollbar-track { background: transparent; }
.ac-dropdown::-webkit-scrollbar-thumb { background: var(--border); border-radius: 3px; }

/* Stats section */
.stats-section { background: var(--bg2); border-top: 1.5px solid var(--border); border-bottom: 1.5px solid var(--border); padding: 32px 0; margin: 56px 0 0; position: relative; z-index: 1; }
.stats-row { display: grid; grid-template-columns: repeat(4,1fr); text-align: center; }
.stat-cell { padding: 16px; border-right: 1.5px solid var(--border); }
.stat-cell:last-child { border-right: none; }
.stat-cell-link { cursor: pointer; transition: background 0.15s; display: block; }
.stat-cell-link:hover { background: var(--accent-light); }
.stat-num { font-size: 32px; font-weight: 900; color: var(--accent); letter-spacing: -1px; display: flex; align-items: center; justify-content: center; gap: 4px; }
.stat-lbl { font-size: 13px; color: var(--text-muted); margin-top: 4px; }

/* Featured / Sections */
.featured { padding: 64px 0; }
.sec-hdr { display: flex; align-items: center; justify-content: space-between; margin-bottom: 28px; }
.sec-hdr h2 { font-size: 26px; font-weight: 800; letter-spacing: -0.5px; }
.chip-row { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 24px; }
.fchip {
  padding: 7px 18px; border-radius: 20px; border: 1.5px solid var(--border2);
  font-size: 13px; color: var(--text-soft); background: var(--bg2);
  cursor: pointer; font-family: inherit; transition: all 0.15s; font-weight: 500;
}
.fchip.active { border-color: var(--accent); color: var(--accent); background: var(--accent-light); }

/* Why cards */
.why-card {
  padding: 28px; background: var(--bg2); border: 1.5px solid var(--border);
  border-radius: var(--radius); transition: all 0.2s;
}
.why-card:hover { box-shadow: 0 8px 24px rgba(0,0,0,0.06); border-color: var(--accent); }
.why-card-icon { font-size: 32px; margin-bottom: 6px; }
.why-card-icon svg { width: 36px; height: 36px; stroke-width: 1.5; }
.why-card h3 { font-size: 15px; margin-bottom: 8px; }
.why-card p { font-size: 13px; color: var(--text-muted); line-height: 1.6; }

/* ═══ PRICING ═══ */
.pricing-wrap { padding: 80px 0; background: var(--bg2); border-top: 1.5px solid var(--border); }
.pricing-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; max-width: 860px; margin: 0 auto; }
.price-card { background: var(--bg3); border: 1.5px solid var(--border); border-radius: 22px; padding: 38px; }
.price-card.featured { background: var(--accent); border-color: var(--accent); color: #fff; position: relative; }
.price-badge {
  position: absolute; top: -14px; left: 50%; transform: translateX(-50%);
  background: #fbbf24; color: #78350f; font-size: 11px; font-weight: 800;
  padding: 5px 16px; border-radius: 20px; white-space: nowrap;
}
.price-label { font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.7px; margin-bottom: 16px; color: var(--text-muted); }
.price-card.featured .price-label { color: rgba(255,255,255,0.75); }
.price-amount { font-size: 58px; font-weight: 900; letter-spacing: -3px; line-height: 1; color: var(--text); }
.price-card.featured .price-amount { color: #fff; }
.price-amount span { font-size: 26px; font-weight: 600; }
.price-period { font-size: 20px; opacity: 0.6; }
.price-sub { font-size: 14px; color: var(--text-muted); margin-top: 6px; margin-bottom: 28px; }
.price-card.featured .price-sub { color: rgba(255,255,255,0.7); }
.price-features { display: flex; flex-direction: column; gap: 12px; margin-bottom: 32px; }
.price-feature { font-size: 14px; display: flex; align-items: center; gap: 10px; color: var(--text-soft); }
.price-card.featured .price-feature { color: rgba(255,255,255,0.9); }
.price-check { font-size: 16px; font-weight: 700; color: var(--accent); flex-shrink: 0; }
.price-check-w { font-size: 16px; font-weight: 700; flex-shrink: 0; }

/* ═══ PROPERTY LIST PAGE ═══ */
.lista-wrap { display: grid; grid-template-columns: 280px 1fr; min-height: calc(100vh - 64px); }
.lista-side { border-right: 1.5px solid var(--border); padding: 28px 24px; background: var(--bg2); overflow-y: auto; }
.lista-main { padding: 28px 32px; background: var(--bg); }

/* Filters */
.filter-group { margin-bottom: 24px; }
.filter-lbl { font-size: 12px; font-weight: 700; color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.7px; display: block; margin-bottom: 12px; }
.toggle-pair { display: flex; background: var(--bg3); border-radius: var(--radius-sm); padding: 3px; gap: 2px; }
.tpair-btn {
  flex: 1; padding: 8px; border-radius: 8px; font-size: 13px; font-weight: 600;
  cursor: pointer; font-family: inherit; border: none; background: transparent;
  color: var(--text-soft); transition: all 0.15s;
  display: flex; align-items: center; justify-content: center; gap: 5px;
}
.search-input-wrap {
  position: relative; display: flex; align-items: center;
}
.search-input-wrap svg {
  position: absolute; left: 12px; color: var(--text-muted); pointer-events: none; z-index: 1;
}
.search-input-wrap .input {
  padding-left: 34px; width: 100%;
}
.tpair-btn.active { background: var(--bg2); color: var(--accent); box-shadow: 0 2px 8px rgba(0,0,0,0.08); }
.chk-list { display: flex; flex-direction: column; gap: 12px; }
.chk-item { display: flex; align-items: center; gap: 10px; font-size: 14px; color: var(--text-soft); cursor: pointer; }
.chk-item input { accent-color: var(--accent); width: 16px; height: 16px; }
.range-pair { display: flex; gap: 8px; align-items: center; }
.range-pair .input { padding: 9px 12px; font-size: 13px; }
.range-sep { color: var(--text-muted); font-weight: 600; flex-shrink: 0; }
.rooms-row { display: flex; gap: 8px; flex-wrap: wrap; }
.rbtn {
  width: 44px; height: 44px; border-radius: var(--radius-sm); border: 1.5px solid var(--border2);
  background: var(--bg2); color: var(--text-soft); cursor: pointer;
  font-size: 14px; font-weight: 600; font-family: inherit; transition: all 0.15s;
}
.rbtn.active { border-color: var(--accent); background: var(--accent-light); color: var(--accent); }

/* Filter toggle (mobile) */
.filter-toggle-btn {
  display: none; padding: 10px 20px; background: var(--accent); color: #fff;
  border: none; border-radius: var(--radius-sm); font-size: 14px; font-weight: 600;
  cursor: pointer; font-family: inherit; margin-bottom: 16px; width: 100%;
  justify-content: center; gap: 8px; align-items: center;
}
.filter-overlay {
  display: none; position: fixed; inset: 0; z-index: 99;
  background: rgba(0,0,0,0.4);
}
.filter-overlay.open { display: block; }

/* Sort row */
.sort-row { display: flex; align-items: center; justify-content: space-between; margin-bottom: 20px; }
.prop-grid { display: grid; grid-template-columns: repeat(3,1fr); gap: 16px; }

/* Pagination */
.pager { display: flex; justify-content: center; gap: 6px; margin-top: 32px; }
.pgbtn {
  width: 40px; height: 40px; border-radius: var(--radius-sm); border: 1.5px solid var(--border2);
  background: var(--bg2); color: var(--text-soft); cursor: pointer;
  font-size: 14px; font-weight: 600; transition: all 0.15s;
  display: flex; align-items: center; justify-content: center; text-decoration: none;
}
.pgbtn.active { background: var(--accent); color: #fff; border-color: var(--accent); }
.pgbtn:hover:not(.active) { border-color: var(--accent); color: var(--accent); }
.pgbtn.disabled { opacity: 0.4; cursor: default; pointer-events: none; }

/* ═══ DETAIL PAGE ═══ */
.detail-container { max-width: 1200px; margin: 0 auto; padding: 0 40px 60px; }
.breadcrumb { display: flex; align-items: center; gap: 8px; font-size: 14px; color: var(--text-muted); padding: 20px 0; flex-wrap: wrap; }
.breadcrumb a { color: var(--accent); font-weight: 500; }

/* Gallery */
.gal-grid { display: grid; grid-template-columns: 3fr 1fr; grid-template-rows: 1fr 1fr; height: 75vh; min-height: 500px; gap: 8px; border-radius: var(--radius); overflow: hidden; }
.gal-main { grid-row: 1/3; background: var(--bg3); display: flex; align-items: center; justify-content: center; font-size: 64px; cursor: pointer; overflow: hidden; }
.gal-main img { width: 100%; height: 100%; object-fit: cover; transition: opacity 0.3s ease; }
.gal-sm { background: #ede9fe; display: flex; align-items: center; justify-content: center; font-size: 32px; position: relative; cursor: pointer; overflow: hidden; }
.gal-sm:nth-child(3) { background: #fce7f3; }
.gal-sm img { width: 100%; height: 100%; object-fit: cover; transition: opacity 0.3s ease; }
.gal-ov {
  position: absolute; inset: 0; background: rgba(0,0,0,0.4);
  display: flex; align-items: center; justify-content: center;
  color: #fff; font-size: 16px; font-weight: 700;
}

/* Detail top (title + price) */
.detail-top { display: flex; justify-content: space-between; align-items: flex-start; margin-top: 28px; gap: 20px; }
.detail-title { font-size: 30px; font-weight: 900; letter-spacing: -0.8px; }
.detail-price-box { text-align: right; flex-shrink: 0; }

/* Detail layout */
.detail-layout { display: grid; grid-template-columns: 1fr 360px; gap: 48px; margin-top: 28px; }
.detail-price { font-size: 36px; font-weight: 900; color: var(--accent); letter-spacing: -1px; }
.detail-addr { font-size: 15px; color: var(--text-muted); margin-top: 6px; }

/* Features grid */
.feats { display: grid; grid-template-columns: repeat(3,1fr); gap: 12px; margin: 24px 0; }
.feat { padding: 16px; background: var(--bg3); border-radius: var(--radius-sm); }
.feat-icon { font-size: 20px; }
.feat-val { font-size: 18px; font-weight: 700; margin-top: 6px; }
.feat-lbl { font-size: 12px; color: var(--text-muted); margin-top: 2px; }

/* Tabs */
.tabs { display: flex; background: var(--bg3); border-radius: var(--radius-sm); padding: 3px; gap: 2px; margin: 24px 0; }
.tab {
  flex: 1; padding: 9px 16px; font-size: 14px; color: var(--text-soft);
  border: none; background: transparent; cursor: pointer; border-radius: 10px;
  font-family: inherit; font-weight: 500; transition: all 0.15s; text-align: center;
}
.tab.active { background: var(--bg2); color: var(--accent); font-weight: 600; box-shadow: 0 2px 8px rgba(0,0,0,0.08); }
.tab-content { display: none; }
.tab-content.active { display: block; }

/* Contact card (sticky sidebar) */
.contact-card {
  background: var(--bg2); border: 1.5px solid var(--border); border-radius: 20px;
  padding: 28px; position: sticky; top: 80px; box-shadow: 0 8px 32px rgba(0,0,0,0.06);
}
.agent-row { display: flex; align-items: center; gap: 14px; margin-bottom: 24px; }
.agent-av {
  width: 52px; height: 52px; border-radius: 50%; background: var(--accent-light);
  border: 2px solid var(--accent); display: flex; align-items: center; justify-content: center;
  color: var(--accent); font-weight: 800; font-size: 18px; flex-shrink: 0;
}
.cta-stack { display: flex; flex-direction: column; gap: 10px; }
.cta-stack .btn { padding: 13px; text-align: center; width: 100%; font-size: 14px; }
.map-box {
  background: #fef3c7; border-radius: var(--radius-sm); height: 200px;
  margin-top: 18px; display: flex; align-items: center; justify-content: center;
  color: #92400e; font-size: 14px; border: 1.5px solid #fde68a;
}

/* ═══ AGENT PAGES ═══ */
.agent-card { text-align: center; }
.agent-card .agent-av { width: 72px; height: 72px; font-size: 24px; margin: 0 auto 14px; }

/* ═══ TESTIMONIALS ═══ */
.testimonial { text-align: center; }
.testimonial-stars { font-size: 28px; margin-bottom: 14px; color: #facc15; }
.testimonial-stars svg { width: 24px; height: 24px; fill: #facc15; stroke: #facc15; }
.testimonial-text { font-size: 14px; color: var(--text-soft); line-height: 1.7; font-style: italic; margin-bottom: 18px; }
.testimonial-name { font-size: 14px; font-weight: 700; color: var(--text); }
.testimonial-loc { font-size: 13px; color: var(--text-muted); }

/* ═══ AUTH PAGES ═══ */
.auth-page { min-height: calc(100vh - 64px); display: flex; align-items: center; justify-content: center; background: var(--bg); }
.auth-box { width: 100%; max-width: 420px; padding: 40px; }
.auth-card { background: var(--bg2); border: 1.5px solid var(--border); border-radius: var(--radius); padding: 32px; }

/* ═══ AI CHAT ═══ */
.ai-wrap { display: grid; grid-template-columns: 1fr 380px; min-height: calc(100vh - 64px); }
.chat-col { display: flex; flex-direction: column; border-right: 1.5px solid var(--border); }
.chat-hdr { padding: 18px 28px; border-bottom: 1.5px solid var(--border); background: var(--bg2); display: flex; align-items: center; gap: 14px; }
.ai-av { width: 40px; height: 40px; border-radius: 50%; background: var(--accent); display: flex; align-items: center; justify-content: center; color: #fff; font-size: 14px; font-weight: 800; flex-shrink: 0; }
.chat-msgs { flex: 1; padding: 28px; display: flex; flex-direction: column; gap: 18px; overflow-y: auto; background: var(--bg3); }
.msg { display: flex; gap: 12px; max-width: 80%; }
.msg.user { align-self: flex-end; flex-direction: row-reverse; }
.bubble { padding: 14px 18px; border-radius: 18px; font-size: 14px; line-height: 1.6; }
.msg.ai .bubble { background: var(--bg2); border: 1.5px solid var(--border); border-radius: 4px 18px 18px 18px; color: var(--text); box-shadow: 0 2px 8px rgba(0,0,0,0.04); }
.msg.user .bubble { background: var(--accent); color: #fff; border-radius: 18px 4px 18px 18px; }
.suggestions { display: flex; flex-wrap: wrap; gap: 8px; padding: 14px 28px; background: var(--bg2); border-top: 1.5px solid var(--border); }
.sugg {
  padding: 7px 16px; background: var(--bg3); border: 1.5px solid var(--border2);
  border-radius: 20px; font-size: 13px; color: var(--text-soft); cursor: pointer;
  font-family: inherit; font-weight: 500; transition: all 0.15s;
}
.sugg:hover { border-color: var(--accent); color: var(--accent); background: var(--accent-light); }
.chat-input { padding: 18px 28px; border-top: 1.5px solid var(--border); display: flex; gap: 10px; background: var(--bg2); }
.results-panel { padding: 28px 24px; overflow-y: auto; background: var(--bg2); }
.res-h { font-size: 12px; font-weight: 700; color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.7px; margin-bottom: 18px; }
.res-card { border: 1.5px solid var(--border); border-radius: var(--radius-sm); overflow: hidden; margin-bottom: 12px; cursor: pointer; transition: all 0.15s; background: var(--bg2); }
.res-card:hover { box-shadow: 0 6px 18px rgba(0,0,0,0.08); border-color: var(--accent); transform: translateY(-1px); }
.res-img { height: 100px; background: var(--bg3); display: flex; align-items: center; justify-content: center; font-size: 32px; overflow: hidden; }
.res-img img { width: 100%; height: 100%; object-fit: cover; }
.res-info { padding: 14px; }
.res-price { font-size: 17px; font-weight: 800; color: var(--accent); letter-spacing: -0.5px; }
.res-title { font-size: 13px; color: var(--text-muted); margin-top: 3px; }
.res-tags { display: flex; gap: 6px; margin-top: 10px; flex-wrap: wrap; }

/* AI FAB */
.ai-fab {
  position: fixed; bottom: 28px; right: 28px; z-index: 999;
  width: 62px; height: 62px; border-radius: 50%; background: var(--accent);
  color: #fff; font-size: 26px; border: none; cursor: pointer;
  box-shadow: 0 8px 28px rgba(249,115,22,0.45);
  transition: all 0.2s; display: flex; align-items: center; justify-content: center;
  text-decoration: none;
}
.ai-fab:hover { transform: scale(1.1) translateY(-2px); box-shadow: 0 14px 36px rgba(249,115,22,0.55); }
.ai-fab-tooltip {
  position: fixed; bottom: 40px; right: 100px; z-index: 999;
  background: var(--text); color: #fff; font-size: 12px; font-weight: 500;
  padding: 7px 14px; border-radius: 8px; white-space: nowrap;
  pointer-events: none; opacity: 0; transition: opacity 0.2s;
}
.ai-fab:hover + .ai-fab-tooltip { opacity: 1; }

/* ═══ COOKIE BANNER ═══ */
.cookie-banner {
  position: fixed; bottom: 0; left: 0; right: 0; z-index: 1001;
  background: var(--bg2); border-top: 1.5px solid var(--border);
  padding: 18px 40px; display: flex; align-items: center;
  justify-content: space-between; gap: 20px; box-shadow: 0 -4px 20px rgba(0,0,0,0.08);
}

/* ═══ FLASH MESSAGES ═══ */
.flash {
  padding: 14px 20px; border-radius: var(--radius-sm); margin-bottom: 16px;
  font-size: 14px; display: flex; align-items: center; gap: 10px;
  animation: flashIn 0.3s ease;
  transition: opacity 0.3s ease, transform 0.3s ease;
}
.flash-success { background: #f0fdf4; color: #15803d; border: 1.5px solid #bbf7d0; }
.flash-eroare { background: #fef2f2; color: #dc2626; border: 1.5px solid #fecaca; }
.flash-info { background: #eff6ff; color: #1d4ed8; border: 1.5px solid #bfdbfe; }
.flash-warning { background: #fffbeb; color: #b45309; border: 1.5px solid #fde68a; }
.flash-close { margin-left: auto; cursor: pointer; font-size: 18px; background: none; border: none; color: inherit; opacity: 0.6; }
.flash-close:hover { opacity: 1; }

@keyframes flashIn {
  from { opacity: 0; transform: translateY(-10px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ═══ FOOTER ═══ */
.footer { background: #1c1917; color: #78716c; padding: 56px 0 32px; }
.footer a { color: #a8a29e; text-decoration: none; transition: color 0.15s; }
.footer a:hover { color: var(--accent); }
.footer-grid { display: grid; grid-template-columns: 1.5fr 1fr 1fr 1fr; gap: 40px; margin-bottom: 40px; }
.footer-brand { color: #f5f5f4; font-size: 18px; font-weight: 800; margin-bottom: 12px; display: flex; align-items: center; gap: 6px; }
.footer-desc { font-size: 13px; line-height: 1.7; color: #a8a29e; }
.footer-title { color: #f5f5f4; font-size: 13px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.5px; margin-bottom: 16px; }
.footer-links { display: flex; flex-direction: column; gap: 10px; font-size: 13px; }
.footer-bottom { border-top: 1px solid #292524; padding-top: 24px; display: flex; justify-content: space-between; align-items: center; font-size: 13px; }
.footer-social { display: flex; gap: 16px; font-size: 18px; }
.footer-social a { cursor: pointer; }

/* ═══ LIGHTBOX ═══ */
.lightbox {
  position: fixed; inset: 0; z-index: 2000; background: rgba(0,0,0,0.9);
  display: none; align-items: center; justify-content: center;
}
.lightbox.open { display: flex; }
.lightbox-img { width: auto; height: 92vh; max-width: 95vw; object-fit: contain; border-radius: 8px; }
.lightbox-close {
  position: absolute; top: 20px; right: 20px; color: #fff;
  font-size: 32px; cursor: pointer; background: none; border: none;
  width: 48px; height: 48px; display: flex; align-items: center; justify-content: center;
}
.lightbox-nav {
  position: absolute; top: 50%; transform: translateY(-50%);
  color: #fff; font-size: 36px; cursor: pointer; background: rgba(255,255,255,0.1);
  border: none; width: 48px; height: 48px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center; transition: background 0.15s;
}
.lightbox-nav:hover { background: rgba(255,255,255,0.2); }
.lightbox-prev { left: 20px; }
.lightbox-next { right: 20px; }
.lightbox-counter { position: absolute; bottom: 20px; left: 50%; transform: translateX(-50%); color: #fff; font-size: 14px; }

/* ═══ PAGE TOP PADDING ═══ */
.page-content { padding-top: var(--nav-h); min-height: 100vh; }

/* ═══ EMPTY STATE ═══ */
.empty-state { text-align: center; padding: 80px 0; }
.empty-state-icon { font-size: 48px; margin-bottom: 16px; }
.empty-state h2 { font-size: 22px; font-weight: 800; }
.empty-state p { font-size: 15px; color: var(--text-muted); margin-top: 8px; max-width: 400px; margin-left: auto; margin-right: auto; }

/* ═══ TABLE ═══ */
.panel { background: var(--bg2); border: 1.5px solid var(--border); border-radius: var(--radius); overflow: hidden; }
.panel-hdr { padding: 18px 22px; border-bottom: 1.5px solid var(--border); display: flex; justify-content: space-between; align-items: center; }
.tbl { width: 100%; border-collapse: collapse; }
.tbl th { padding: 12px 18px; text-align: left; font-size: 12px; font-weight: 700; color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.5px; background: var(--bg3); border-bottom: 1.5px solid var(--border); }
.tbl td { padding: 15px 18px; font-size: 14px; border-bottom: 1px solid var(--border); color: var(--text-soft); }
.tbl td:first-child { color: var(--text); font-weight: 600; }
.tbl tr:last-child td { border-bottom: none; }
.tbl tr:hover td { background: var(--bg3); }

/* ═══ AUTH: Google Button + Separator ═══ */
.auth-separator {
  display: flex; align-items: center; gap: 12px;
  margin: 20px 0; color: var(--text-muted); font-size: 13px;
}
.auth-separator::before,
.auth-separator::after {
  content: ''; flex: 1; height: 1px; background: var(--border);
}
.btn-google {
  display: flex; align-items: center; justify-content: center; gap: 10px;
  width: 100%; padding: 12px 16px;
  background: #fff; color: var(--text); font-size: 14px; font-weight: 600;
  border: 1.5px solid var(--border); border-radius: var(--radius-sm);
  cursor: pointer; transition: all 0.2s;
  text-decoration: none;
}
.btn-google:hover {
  border-color: var(--border2); box-shadow: 0 2px 8px rgba(0,0,0,0.08);
  color: var(--text);
}
.btn-google svg { flex-shrink: 0; }

/* ═══ HERO BACKGROUND ═══ */
.hero {
  background: linear-gradient(135deg, #fefce8 0%, #fff7ed 40%, #fef3c7 100%);
  position: relative;
}
.hero::before {
  content: ''; position: absolute; inset: 0;
  background: radial-gradient(ellipse at 70% 20%, rgba(249,115,22,0.08) 0%, transparent 60%),
              radial-gradient(ellipse at 30% 80%, rgba(251,191,36,0.06) 0%, transparent 50%);
  pointer-events: none;
}
.hero .container { position: relative; z-index: 10; }

/* ═══ PROPERTY TAGS ═══ */
.card-tags { display: flex; gap: 4px; position: absolute; top: 12px; left: 12px; flex-wrap: wrap; }
.card-tag {
  padding: 3px 10px; border-radius: 6px; font-size: 11px; font-weight: 700;
  text-transform: uppercase; letter-spacing: 0.3px;
}
.card-tag-nou { background: #16a34a; color: #fff; }
.card-tag-redus { background: #dc2626; color: #fff; }
.card-tag-exclusiv { background: #7c3aed; color: #fff; }
.card-tag-premium { background: #f59e0b; color: #fff; }

/* ═══ SHARE BUTTONS ═══ */
.share-row { display: flex; gap: 8px; margin-top: 16px; flex-wrap: wrap; }
.share-btn {
  display: inline-flex; align-items: center; gap: 6px; padding: 8px 16px;
  border: 1.5px solid var(--border2); border-radius: var(--radius-sm); font-size: 13px;
  color: var(--text-soft); background: var(--bg2); cursor: pointer; transition: all 0.15s;
  text-decoration: none; font-family: inherit;
}
.share-btn:hover { border-color: var(--accent); color: var(--accent); background: var(--accent-light); }

/* ═══ WHATSAPP FAB ═══ */
.whatsapp-fab {
  position: fixed; bottom: 100px; right: 28px; z-index: 998;
  width: 54px; height: 54px; border-radius: 50%; background: #25D366;
  color: #fff; font-size: 26px; border: none; cursor: pointer;
  box-shadow: 0 6px 20px rgba(37,211,102,0.4);
  transition: all 0.2s; display: flex; align-items: center; justify-content: center;
  text-decoration: none;
}
.whatsapp-fab:hover { transform: scale(1.1); box-shadow: 0 10px 28px rgba(37,211,102,0.5); color: #fff; }

/* ═══ VIEW TOGGLE (GRID/LIST) ═══ */
.view-toggle { display: flex; gap: 4px; background: var(--bg3); border-radius: var(--radius-sm); padding: 3px; }
.view-btn {
  padding: 7px 12px; border: none; background: transparent; cursor: pointer;
  border-radius: 8px; color: var(--text-muted); font-size: 16px; transition: all 0.15s;
  display: flex; align-items: center; justify-content: center;
}
.view-btn.active { background: var(--bg2); color: var(--accent); box-shadow: 0 2px 6px rgba(0,0,0,0.06); }
.prop-grid.list-view { grid-template-columns: 1fr; }
.prop-grid.list-view .card { display: grid; grid-template-columns: 260px 1fr; }
.prop-grid.list-view .card-img { height: 100%; min-height: 180px; }
.prop-grid.list-view .card-body { display: flex; flex-direction: column; justify-content: center; }

/* ═══ RESPONSIVE ═══ */
@media (max-width: 1024px) {
  .grid-4 { grid-template-columns: repeat(2,1fr); }
  .lista-wrap { grid-template-columns: 1fr; }
  .lista-side { display: none; }
  .lista-side.open { display: block; position: fixed; top: var(--nav-h); left: 0; bottom: 0; width: 300px; z-index: 100; box-shadow: 4px 0 20px rgba(0,0,0,0.1); overflow-y: auto; background: var(--bg2); }
  .filter-toggle-btn { display: flex; }
  .detail-layout { grid-template-columns: 1fr; }
  .contact-card { position: static; }
  .ai-wrap { grid-template-columns: 1fr; }
  .results-panel { display: none; }
  .pricing-grid { grid-template-columns: 1fr; max-width: 480px; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 768px) {
  .container { padding: 0 16px; }
  .nav { padding: 0 12px; gap: 6px; }
  .nav-logo { margin-right: auto; flex-shrink: 0; }
  .nav-logo-text { font-size: 16px; }
  .nav-logo-icon { width: 32px; height: 32px; font-size: 16px; }
  .nav-links { display: none; }
  .nav-links.open {
    display: flex; flex-direction: column; position: fixed;
    top: var(--nav-h); left: 0; right: 0; bottom: 0;
    background: var(--bg2); padding: 16px;
    z-index: 999; box-shadow: 0 8px 24px rgba(0,0,0,0.1);
    overflow-y: auto;
  }
  .nav-links.open .nav-link { padding: 12px 16px; font-size: 16px; }
  .nav-toggle { display: flex; flex-shrink: 0; }
  .nav-actions { gap: 4px; flex-shrink: 0; }
  /* Hide login/register text buttons on mobile — move to hamburger */
  .nav-actions .nav-act { display: none; }
  .nav-mobile-auth { display: flex; flex-direction: column; gap: 8px; padding: 16px 16px 0; border-top: 1.5px solid var(--border); margin-top: 8px; }
  .nav-mobile-auth .nav-act { display: inline-flex; text-align: center; justify-content: center; }
  /* Logged-in: hide name, show only avatar */
  .nav-user-btn { padding: 4px; border: none; background: none; }
  .nav-user-btn .nav-user-name-text { display: none; }
  .nav-user-btn .nav-user-avatar { width: 32px; height: 32px; font-size: 12px; }
  .nav-fav { width: 34px; height: 34px; }
  .nav-fav-icon { width: 15px; height: 15px; }
  .lang-btn { padding: 4px 6px; }
  .lang-code { display: none; }
  .lang-flag { font-size: 18px; }

  .hero { padding: 48px 0 56px; }
  .hero h1 { font-size: 38px; letter-spacing: -1.5px; }
  .hero-sub { font-size: 15px; margin-bottom: 28px; }
  .search-card { padding: 16px; }
  .search-card-row { flex-direction: column; gap: 10px; }
  .search-btn-wrap { width: 100%; }
  .search-btn-wrap .btn { width: 100%; justify-content: center; }
  .stats-row { grid-template-columns: repeat(2,1fr); }
  .stat-cell:nth-child(2) { border-right: none; }
  .stat-num { font-size: 26px; }
  .sec-hdr { flex-direction: column; align-items: flex-start; gap: 12px; }
  .sec-hdr h2 { font-size: 22px; }
  .grid-3, .prop-grid { grid-template-columns: 1fr; }
  .grid-2 { grid-template-columns: 1fr; }
  .prop-grid.list-view .card { grid-template-columns: 1fr; }
  .lista-main { padding: 20px 16px; }
  .lista-main h1 { font-size: 20px !important; }
  .sort-row { flex-wrap: wrap; gap: 8px; }
  .whatsapp-fab { bottom: 90px; right: 16px; width: 48px; height: 48px; font-size: 22px; }
  .ai-fab { right: 16px; bottom: 24px; width: 48px; height: 48px; font-size: 20px; }
  .ai-fab-tooltip { display: none; }
  .feats { grid-template-columns: repeat(2,1fr); }
  .gal-grid { grid-template-columns: 1fr; grid-template-rows: 280px; height: auto; min-height: 0; gap: 4px; }
  .gal-main { grid-row: auto; grid-column: 1; }
  .gal-sm { display: none; }
  .detail-container { padding: 0 16px 40px; }
  .detail-top { flex-direction: column; gap: 12px; margin-top: 20px; }
  .detail-title { font-size: 24px; }
  .detail-price-box { text-align: left; }
  .detail-price { font-size: 28px; }
  .tabs { overflow-x: auto; -webkit-overflow-scrolling: touch; }
  .tab { white-space: nowrap; flex: 0 0 auto; }
  .footer-grid { grid-template-columns: 1fr; gap: 28px; }
  .footer { padding: 40px 0 24px; }
  .footer-bottom { flex-direction: column; gap: 12px; text-align: center; }
  .cookie-banner { flex-direction: column; padding: 16px; text-align: center; gap: 12px; }
  .cookie-banner .btn { width: 100%; }
  .auth-box { padding: 20px 16px; }
  .auth-card { padding: 24px 20px; }

  /* Lightbox mobile */
  .lightbox-img { height: auto; max-height: 80vh; max-width: 100vw; border-radius: 0; }
  .lightbox-close { top: 10px; right: 10px; font-size: 28px; width: 44px; height: 44px; }
  .lightbox-nav { width: 40px; height: 40px; font-size: 24px; }
  .lightbox-prev { left: 8px; }
  .lightbox-next { right: 8px; }
  .lightbox-counter { bottom: 12px; font-size: 13px; }

  /* AI chat mobile */
  .chat-hdr { padding: 14px 16px; }
  .chat-msgs { padding: 16px; }
  .chat-input { padding: 12px 16px; }
  .suggestions { padding: 10px 16px; }
  .msg { max-width: 90%; }
}

@media (max-width: 480px) {
  .hero h1 { font-size: 32px; letter-spacing: -1px; }
  .hero-sub { font-size: 14px; }
  .card-img { height: 180px; }
  .card-body { padding: 14px; }
  .card-price { font-size: 20px; }
  .card-meta { gap: 10px; font-size: 12px; }
  .stat-num { font-size: 22px; }
  .feats { grid-template-columns: 1fr; }
  .feat { padding: 12px; }
  .breadcrumb { font-size: 13px; padding: 14px 0; }
  .price-amount { font-size: 42px; }
  .price-amount span { font-size: 20px; }
  .pager { flex-wrap: wrap; }
}

/* ═══ HEATMAP FEATURE ═══ */
.heatmap-container {
  display: none; border-radius: var(--radius); overflow: hidden;
  border: 2px solid var(--accent); position: relative; background: var(--bg2);
  box-shadow: 0 8px 32px rgba(232,116,42,0.12);
}
.heatmap-container.active { display: block; }
.heatmap-map { height: 620px; width: 100%; z-index: 1; }
.heatmap-legend {
  position: absolute; bottom: 20px; right: 20px; z-index: 1000;
  background: rgba(255,255,255,0.97); border-radius: var(--radius-sm);
  padding: 14px 18px; box-shadow: 0 6px 24px rgba(0,0,0,0.15);
  border: 1.5px solid var(--border); min-width: 180px;
}
.heatmap-legend-title {
  font-size: 12px; font-weight: 700; text-transform: uppercase;
  letter-spacing: 0.5px; color: var(--text); margin-bottom: 10px;
}
.heatmap-legend-bar {
  height: 14px; border-radius: 7px;
  background: linear-gradient(to right, #22c55e, #84cc16, #eab308, #f97316, #ef4444);
  margin-bottom: 8px; border: 1px solid rgba(0,0,0,0.08);
}
.heatmap-legend-labels {
  display: flex; justify-content: space-between; font-size: 12px;
  color: var(--text-soft); font-weight: 700;
}
.heatmap-loading {
  position: absolute; inset: 0; z-index: 1001;
  background: rgba(255,255,255,0.8); display: flex;
  align-items: center; justify-content: center;
  font-size: 14px; color: var(--text-muted); font-weight: 600;
}

@media (max-width: 768px) {
  .heatmap-map { height: 400px; }
  .heatmap-legend { bottom: 10px; right: 10px; padding: 8px 12px; min-width: 130px; }
}
@media (max-width: 480px) {
  .heatmap-map { height: 320px; }
}

/* ═══ COMPARE FEATURE ═══ */

/* Compare button on card */
.card-compare {
  position: absolute; bottom: 12px; right: 12px; width: 32px; height: 32px;
  background: rgba(255,255,255,0.9); border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 14px; cursor: pointer; border: none; transition: all 0.15s;
  z-index: 2;
}
.card-compare:hover { transform: scale(1.15); background: #fff; }
.card-compare.active { background: var(--accent); color: #fff; box-shadow: 0 2px 8px rgba(232,116,42,0.3); }

/* Floating compare bar */
.compare-bar {
  position: fixed; bottom: 0; left: 0; right: 0; z-index: 2000;
  background: var(--bg2); border-top: 2px solid var(--accent);
  box-shadow: 0 -4px 24px rgba(0,0,0,0.12);
  padding: 12px 24px; display: none; align-items: center; gap: 16px;
  animation: compareBarSlide 0.3s ease;
}
.compare-bar.visible { display: flex; }
@keyframes compareBarSlide {
  from { transform: translateY(100%); }
  to { transform: translateY(0); }
}
.compare-bar-items {
  display: flex; gap: 10px; flex: 1; overflow-x: auto;
}
.compare-bar-item {
  display: flex; align-items: center; gap: 8px; background: var(--bg3);
  border-radius: var(--radius-sm); padding: 6px 10px; min-width: 0; flex-shrink: 0;
}
.compare-bar-item img {
  width: 44px; height: 44px; border-radius: 8px; object-fit: cover; flex-shrink: 0;
}
.compare-bar-item-info {
  min-width: 0;
}
.compare-bar-item-title {
  font-size: 12px; font-weight: 600; color: var(--text);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 140px;
}
.compare-bar-item-price {
  font-size: 11px; color: var(--accent); font-weight: 700;
}
.compare-bar-item-remove {
  background: none; border: none; cursor: pointer; font-size: 16px;
  color: var(--text-muted); padding: 2px; line-height: 1; flex-shrink: 0;
}
.compare-bar-item-remove:hover { color: var(--error); }
.compare-bar-actions {
  display: flex; gap: 8px; flex-shrink: 0;
}
.compare-bar-count {
  font-size: 12px; color: var(--text-muted); white-space: nowrap; flex-shrink: 0;
}

/* Compare modal */
.compare-modal {
  position: fixed; inset: 0; z-index: 2100;
  background: rgba(0,0,0,0.6); backdrop-filter: blur(4px);
  display: none; align-items: flex-start; justify-content: center;
  overflow-y: auto; padding: 40px 20px;
}
.compare-modal.visible { display: flex; }
.compare-modal-content {
  background: var(--bg2); border-radius: var(--radius); width: 100%; max-width: 1100px;
  box-shadow: 0 24px 64px rgba(0,0,0,0.2); animation: compareModalIn 0.25s ease;
}
@keyframes compareModalIn {
  from { opacity: 0; transform: translateY(20px) scale(0.97); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}
.compare-modal-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 20px 28px; border-bottom: 1px solid var(--border);
}
.compare-modal-header h2 { font-size: 20px; font-weight: 700; color: var(--text); }
.compare-modal-close {
  background: none; border: none; font-size: 28px; cursor: pointer;
  color: var(--text-muted); line-height: 1; padding: 4px;
}
.compare-modal-close:hover { color: var(--text); }
.compare-modal-body {
  padding: 0; overflow-x: auto;
}

/* Compare table */
.compare-table {
  width: 100%; border-collapse: collapse; font-size: 14px;
}
.compare-table th, .compare-table td {
  padding: 12px 20px; text-align: left; border-bottom: 1px solid var(--border2);
  vertical-align: top;
}
.compare-table thead th {
  background: var(--bg3); font-weight: 700; color: var(--text); position: sticky; top: 0;
  font-size: 13px; text-transform: uppercase; letter-spacing: 0.3px;
}
.compare-table thead th:first-child { min-width: 140px; }
.compare-table .compare-prop-header {
  text-align: center; padding: 16px 12px;
}
.compare-prop-header img {
  width: 100%; height: 120px; object-fit: cover; border-radius: var(--radius-sm);
  margin-bottom: 8px;
}
.compare-prop-header .compare-prop-title {
  font-size: 13px; font-weight: 600; color: var(--text);
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.compare-prop-header .compare-prop-link {
  font-size: 12px; color: var(--accent); margin-top: 4px; display: inline-block;
}
.compare-table tbody tr:hover { background: var(--accent-dim); }
.compare-table .row-label {
  font-weight: 600; color: var(--text-soft); white-space: nowrap; background: var(--bg);
}
.compare-table .best-value {
  color: var(--success); font-weight: 700;
}
.compare-table .best-value-bg {
  background: rgba(22,163,74,0.06);
}

/* Responsive compare */
@media (max-width: 768px) {
  .compare-bar {
    padding: 10px 12px; gap: 8px; flex-direction: column; align-items: center;
  }
  .compare-bar-items { justify-content: center; flex-wrap: wrap; }
  .compare-bar-item-title { max-width: 80px; }
  .compare-bar-item img { width: 36px; height: 36px; }
  .compare-modal { padding: 8px; }
  .compare-modal-content { border-radius: var(--radius-sm); }
  .compare-modal-header { padding: 14px 16px; }
  .compare-modal-header h2 { font-size: 16px; }
  .compare-table th, .compare-table td { padding: 8px 10px; font-size: 12px; white-space: nowrap; }
  .compare-prop-header img { height: 60px; }
  .compare-prop-header .compare-prop-title { font-size: 11px; }
}

/* ═══════════════════════════════════════════════
   QUIZ / RECOMANDARI
   ═══════════════════════════════════════════════ */

/* CTA on homepage */
.quiz-cta {
  margin-top: 56px;
  background: linear-gradient(135deg, var(--accent) 0%, #1e40af 100%);
  border-radius: var(--radius);
  padding: 56px 40px;
  text-align: center;
  position: relative;
  overflow: hidden;
}
.quiz-cta::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 20% 50%, rgba(255,255,255,0.1) 0%, transparent 50%);
  pointer-events: none;
}
.quiz-cta-content { position: relative; z-index: 1; max-width: 540px; margin: 0 auto; }
.quiz-cta-icon { font-size: 48px; margin-bottom: 8px; color: #fff; }
.quiz-cta-icon svg { width: 72px; height: 72px; }
.quiz-cta h2 { font-size: 28px; font-weight: 800; color: #fff; margin-bottom: 12px; }
.quiz-cta p { font-size: 16px; color: rgba(255,255,255,0.85); margin-bottom: 28px; line-height: 1.6; }
.quiz-cta .btn {
  background: #fff;
  color: var(--accent);
  font-weight: 700;
  padding: 14px 32px;
  font-size: 15px;
  border: none;
}
.quiz-cta .btn:hover { background: rgba(255,255,255,0.9); transform: translateY(-2px); }

@media (max-width: 768px) {
  .quiz-cta { padding: 40px 24px; }
  .quiz-cta h2 { font-size: 22px; }
}

/* Quiz page */
.quiz-page { padding: 40px 0 80px; min-height: 60vh; }

.quiz-wrap {
  max-width: 700px;
  margin: 0 auto;
  background: var(--bg);
  border: 1px solid var(--border2);
  border-radius: var(--radius);
  padding: 40px;
  box-shadow: 0 4px 24px rgba(0,0,0,0.06);
}

.quiz-header { text-align: center; margin-bottom: 36px; }
.quiz-header h1 { font-size: 28px; font-weight: 800; color: var(--text); margin-bottom: 8px; }
.quiz-header p { color: var(--text-muted); font-size: 15px; }

/* Progress bar */
.quiz-progress {
  margin-top: 28px;
  position: relative;
  background: var(--bg3);
  border-radius: 20px;
  height: 8px;
  overflow: visible;
}
.quiz-progress-bar {
  height: 100%;
  background: var(--accent);
  border-radius: 20px;
  width: 0%;
  transition: width 0.4s ease;
}
.quiz-progress-steps {
  display: flex;
  justify-content: space-between;
  position: absolute;
  top: 50%;
  left: 0;
  right: 0;
  transform: translateY(-50%);
  pointer-events: none;
}
.quiz-step-dot {
  width: 28px; height: 28px;
  border-radius: 50%;
  background: var(--bg);
  border: 2px solid var(--border2);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: 700;
  color: var(--text-muted);
  transition: all 0.3s ease;
}
.quiz-step-dot.active {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
}
.quiz-step-dot.completed {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
}

/* Steps */
.quiz-step {
  display: none;
  transition: opacity 0.3s ease, transform 0.3s ease;
}
.quiz-step.active { display: block; }
.quiz-step h2 { font-size: 22px; font-weight: 700; color: var(--text); margin-bottom: 8px; text-align: center; }
.quiz-step-sub { text-align: center; color: var(--text-muted); font-size: 14px; margin-bottom: 8px; }

/* Cards grid */
.quiz-cards-grid {
  display: grid;
  gap: 14px;
  margin-top: 24px;
}
.quiz-cards-grid.cols-2 { grid-template-columns: repeat(2, 1fr); }
.quiz-cards-grid.cols-3 { grid-template-columns: repeat(3, 1fr); }
.quiz-cards-grid.cols-5 { grid-template-columns: repeat(5, 1fr); }

/* Quiz card */
.quiz-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 24px 16px;
  background: var(--bg);
  border: 2px solid var(--border2);
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: all 0.2s ease;
  font-family: inherit;
  font-size: inherit;
  color: var(--text);
  text-align: center;
}
.quiz-card:hover {
  border-color: var(--accent);
  background: var(--accent-dim);
  transform: translateY(-2px);
}
.quiz-card.selected {
  border-color: var(--accent);
  background: var(--accent-dim);
  box-shadow: 0 0 0 3px rgba(37,99,235,0.15);
}
.quiz-card-icon { font-size: 32px; line-height: 1; }
.quiz-card-label { font-size: 15px; font-weight: 600; }
.quiz-card-desc { font-size: 13px; color: var(--text-muted); line-height: 1.4; }

.quiz-card-sm { padding: 20px 12px; }
.quiz-card-sm .quiz-card-label { font-size: 20px; font-weight: 800; }

/* City input */
.quiz-city-wrap { margin-top: 24px; position: relative; max-width: 400px; margin-left: auto; margin-right: auto; }
.quiz-city-input { width: 100%; padding: 14px 18px; font-size: 16px; text-align: center; box-sizing: border-box; }
.quiz-city-suggestions {
  position: absolute; top: 100%; left: 0; right: 0; z-index: 10;
  background: var(--bg); border: 1px solid var(--border2); border-top: none;
  border-radius: 0 0 var(--radius-sm) var(--radius-sm);
  box-shadow: 0 8px 24px rgba(0,0,0,0.1);
  display: none;
}
.quiz-city-option {
  padding: 12px 18px;
  cursor: pointer;
  font-size: 15px;
  transition: background 0.15s;
}
.quiz-city-option:hover { background: var(--accent-dim); }

.quiz-city-popular {
  display: flex; flex-wrap: wrap; gap: 8px;
  justify-content: center; margin-top: 20px;
  align-items: center;
}
.quiz-city-label { font-size: 13px; color: var(--text-muted); font-weight: 600; }
.quiz-city-tag {
  padding: 8px 16px;
  background: var(--bg3);
  border: 1px solid var(--border2);
  border-radius: 20px;
  font-size: 13px;
  font-weight: 600;
  font-family: inherit;
  color: var(--text-soft);
  cursor: pointer;
  transition: all 0.2s ease;
}
.quiz-city-tag:hover { border-color: var(--accent); color: var(--accent); }
.quiz-city-tag.selected {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
}

/* Footer nav */
.quiz-footer {
  display: flex;
  justify-content: space-between;
  margin-top: 36px;
  padding-top: 24px;
  border-top: 1px solid var(--border2);
}

/* Results */
.quiz-results { max-width: 1100px; margin: 0 auto; }
.quiz-results-header {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 28px; flex-wrap: wrap; gap: 12px;
}
.quiz-results-header h2 { font-size: 22px; font-weight: 700; color: var(--text); }
.quiz-results-header h2 strong { color: var(--accent); }
.quiz-results-grid { margin-bottom: 40px; }

/* Match badge */
.match-badge {
  position: absolute;
  top: 12px;
  right: 12px;
  background: rgba(0,0,0,0.75);
  color: #fff;
  font-size: 12px;
  font-weight: 700;
  padding: 6px 12px;
  border-radius: 20px;
  backdrop-filter: blur(4px);
  z-index: 2;
}
.match-badge.match-high { background: rgba(22,163,74,0.9); }
.match-badge.match-mid { background: rgba(234,179,8,0.9); color: #1a1a1a; }

/* Empty state */
.quiz-empty {
  text-align: center;
  padding: 60px 20px;
}
.quiz-empty-icon { font-size: 56px; margin-bottom: 16px; }
.quiz-empty h3 { font-size: 22px; font-weight: 700; color: var(--text); margin-bottom: 10px; }
.quiz-empty p { color: var(--text-muted); margin-bottom: 24px; font-size: 15px; }

/* Custom input toggles */
.quiz-custom-wrap {
  margin-top: 20px;
  text-align: center;
}
.quiz-custom-toggle {
  background: none;
  border: 1px dashed var(--border);
  color: var(--text-soft);
  padding: 10px 20px;
  border-radius: var(--radius-sm);
  cursor: pointer;
  font-size: 14px;
  font-family: inherit;
  transition: all 0.2s;
}
.quiz-custom-toggle:hover {
  border-color: var(--accent);
  color: var(--accent);
  background: var(--accent-dim);
}
.quiz-custom-fields {
  margin-top: 16px;
  display: flex;
  justify-content: center;
  animation: quizFadeIn 0.25s ease;
}
@keyframes quizFadeIn {
  from { opacity: 0; transform: translateY(-8px); }
  to { opacity: 1; transform: translateY(0); }
}
.quiz-custom-row {
  display: flex;
  align-items: flex-end;
  gap: 12px;
}
.quiz-custom-sep {
  color: var(--text-muted);
  font-size: 18px;
  padding-bottom: 10px;
}
.quiz-custom-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
  max-width: 200px;
}
.quiz-custom-field label {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-soft);
}
.quiz-custom-field textarea {
  resize: vertical;
  min-height: 70px;
  font-family: inherit;
  font-size: 14px;
}

/* Grid cols-4 for camere */
.quiz-cards-grid.cols-4 { grid-template-columns: repeat(4, 1fr); }

/* Responsive quiz */
@media (max-width: 768px) {
  .quiz-page { padding: 24px 0 60px; }
  .quiz-wrap { padding: 24px 16px; }
  .quiz-header h1 { font-size: 20px; }
  .quiz-header p { font-size: 14px; }
  .quiz-cards-grid.cols-2 { grid-template-columns: repeat(2, 1fr); }
  .quiz-cards-grid.cols-3 { grid-template-columns: repeat(2, 1fr); }
  .quiz-cards-grid.cols-4 { grid-template-columns: repeat(2, 1fr); }
  .quiz-cards-grid.cols-5 { grid-template-columns: repeat(3, 1fr); }
  .quiz-card { padding: 16px 10px; }
  .quiz-card-icon { font-size: 24px; }
  .quiz-card-label { font-size: 13px; }
  .quiz-card-desc { font-size: 12px; }
  .quiz-step h2 { font-size: 17px; }
  .quiz-step-dot { width: 24px; height: 24px; font-size: 10px; }
  .quiz-results-header { flex-direction: column; text-align: center; }
  .quiz-custom-row { flex-direction: column; align-items: stretch; }
  .quiz-custom-sep { display: none; }
  .quiz-custom-field { max-width: 100%; }
  .quiz-footer { margin-top: 24px; padding-top: 16px; }
  .quiz-city-input { font-size: 15px; padding: 12px 14px; }
}

@media (max-width: 480px) {
  .quiz-cards-grid.cols-2 { grid-template-columns: 1fr; }
  .quiz-cards-grid.cols-3 { grid-template-columns: 1fr; }
  .quiz-cards-grid.cols-4 { grid-template-columns: repeat(2, 1fr); }
  .quiz-cards-grid.cols-5 { grid-template-columns: repeat(2, 1fr); }
  .quiz-step-dot { width: 20px; height: 20px; font-size: 9px; }
  .quiz-footer .btn { padding: 10px 16px; font-size: 13px; }
}

/* ═══ REVIEWS ═══ */

/* Star displays */
.review-stars-inline .star,
.review-stars-display .star,
.review-stars-small .star {
  color: #d4d0cc; transition: color 0.15s;
}
.review-stars-inline .star.filled,
.review-stars-display .star.filled,
.review-stars-small .star.filled {
  color: #f59e0b;
}
.review-stars-inline { display: inline-flex; gap: 1px; font-size: 14px; vertical-align: middle; }
.review-stars-display { display: flex; gap: 2px; font-size: 20px; justify-content: center; margin: 4px 0; }
.review-stars-small { display: inline-flex; gap: 1px; font-size: 13px; }

/* Rating breakdown */
.review-breakdown {
  display: flex; gap: 28px; align-items: center;
  background: var(--bg3); border-radius: var(--radius); padding: 20px 24px;
}
.review-summary { text-align: center; min-width: 100px; }
.review-avg { font-size: 36px; font-weight: 900; letter-spacing: -1px; color: var(--text); }
.review-bars { flex: 1; display: flex; flex-direction: column; gap: 6px; }
.review-bar-row { display: flex; align-items: center; gap: 8px; }
.review-bar-label { font-size: 13px; width: 36px; text-align: right; color: var(--text-soft); white-space: nowrap; }
.review-bar-track { flex: 1; height: 8px; background: var(--border); border-radius: 4px; overflow: hidden; }
.review-bar-fill { height: 100%; background: #f59e0b; border-radius: 4px; transition: width 0.3s ease; }
.review-bar-count { font-size: 12px; color: var(--text-muted); width: 24px; }

/* Star picker */
.review-star-picker { display: flex; gap: 4px; }
.star-pick {
  font-size: 28px; cursor: pointer; color: #d4d0cc;
  transition: color 0.15s, transform 0.1s; user-select: none;
}
.star-pick:hover, .star-pick.active { color: #f59e0b; }
.star-pick:hover { transform: scale(1.15); }

/* Review form wrap */
.review-form-wrap {
  background: var(--bg2); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 20px;
}

/* Review items */
.review-item {
  padding: 18px 0; border-bottom: 1px solid var(--border2);
}
.review-item:last-child { border-bottom: none; }
.review-header { display: flex; align-items: center; gap: 12px; margin-bottom: 8px; }
.review-text { font-size: 14px; line-height: 1.7; color: var(--text-soft); margin: 0; }

/* Back arrow */
.back-arrow {
  display: inline-flex; align-items: center; gap: 4px;
  font-size: 14px; font-weight: 600; color: var(--text-soft);
  text-decoration: none; margin-bottom: 12px; padding: 6px 12px;
  border-radius: var(--radius-sm); transition: all 0.15s;
}
.back-arrow:hover { background: var(--bg3); color: var(--accent); }

/* Review 3-dot menu */
.review-menu { position: relative; }
.review-menu-btn {
  background: none; border: none; cursor: pointer; font-size: 20px;
  color: var(--text-muted); padding: 4px 8px; border-radius: var(--radius-sm);
  line-height: 1; transition: all 0.15s;
}
.review-menu-btn:hover { background: var(--bg3); color: var(--text); }
.review-menu-dropdown {
  display: none; position: absolute; right: 0; top: 100%; z-index: 10;
  background: var(--bg2); border: 1px solid var(--border); border-radius: var(--radius-sm);
  box-shadow: 0 4px 16px rgba(0,0,0,0.1); min-width: 140px; overflow: hidden;
}
.review-menu.open .review-menu-dropdown { display: block; }
.review-menu-item {
  display: block; width: 100%; padding: 10px 16px; border: none; background: none;
  font-size: 13px; color: var(--text); cursor: pointer; text-align: left;
  font-family: inherit; transition: background 0.1s;
}
.review-menu-item:hover { background: var(--bg3); }
.review-delete-btn { color: var(--error); }
.review-delete-btn:hover { background: #fef2f2; }

/* Inline edit form */
.review-edit-form .review-star-picker { margin-top: 4px; }
.btn-sm { padding: 8px 16px; font-size: 13px; }

/* Responsive reviews */
@media (max-width: 640px) {
  .review-breakdown { flex-direction: column; gap: 16px; }
  .review-summary { min-width: auto; }
  .star-pick { font-size: 32px; }
}
