:root {
  --bg: #f5f7f4;
  --surface: #ffffff;
  --surface-2: #eef4ef;
  --text: #17231c;
  --muted: #68756e;
  --line: #dde6df;
  --primary: #0f6b55;
  --primary-dark: #0a4e3e;
  --accent: #3d8b75;
  --danger: #ba3f3f;
  --shadow: 0 18px 45px rgba(18, 42, 30, 0.11);
  --radius: 14px;
}

* { box-sizing: border-box; }
html, body {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  overflow-x: hidden;
}
body {
  margin: 0;
  font-family: Tahoma, Arial, sans-serif;
  background: var(--bg);
  color: var(--text);
  direction: rtl;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}
body.menu-open {
  overflow: hidden;
}
body.capacitor-app .site-header,
body.capacitor-app .mobile-tabs {
  -webkit-transform: translateZ(0);
  transform: translateZ(0);
}

body.admin-session .site-header,
body.admin-session .site-footer,
body.admin-session .mobile-tabs {
  display: none !important;
}

body.admin-session .app-shell {
  padding-top: 0;
}
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; }
.hidden { display: none !important; }

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgba(255, 255, 255, 0.94);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(14px);
}
.header-inner {
  max-width: 1240px;
  margin: auto;
  min-height: 82px;
  padding: 0 20px;
  display: flex;
  align-items: center;
  gap: 16px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 160px;
}
.brand-logo {
  width: auto;
  height: 50px;
  display: block;
  object-fit: contain;
  flex: 0 0 auto;
}
.brand-header {
  width: auto;
  height: 42px;
  display: block;
  object-fit: contain;
  flex: 0 0 auto;
  align-self: center;
}
.brand strong { display: block; font-size: 20px; white-space: nowrap; }
.brand small { color: var(--muted); }
.header-search {
  flex: 1;
  display: grid;
  grid-template-columns: minmax(180px, 1fr) 120px auto;
  gap: 8px;
  max-width: 430px;
}
.header-search input,
.header-search select {
  min-height: 40px;
  background: #f8fbf9;
}
.main-nav {
  display: flex;
  align-items: center;
  gap: 6px;
}
.main-nav a {
  padding: 9px 9px;
  border-radius: 10px;
  color: #34433a;
  font-size: 14px;
}
.main-nav a:hover { background: var(--surface-2); color: var(--primary); }
.header-actions { display: flex; gap: 10px; align-items: center; }
.user-menu { position: relative; }
.user-menu-toggle {
  max-width: 150px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.user-dropdown {
  position: absolute;
  top: calc(100% + 10px);
  left: 0;
  width: 190px;
  display: none;
  padding: 8px;
  background: white;
  border: 1px solid var(--line);
  border-radius: 14px;
  box-shadow: var(--shadow);
  z-index: 35;
}
.user-menu.open .user-dropdown { display: grid; gap: 3px; }
.user-dropdown a,
.user-dropdown button {
  min-height: 38px;
  border: 0;
  border-radius: 9px;
  background: transparent;
  color: #2d3d34;
  text-align: right;
  padding: 9px 10px;
  cursor: pointer;
}
.user-dropdown a:hover,
.user-dropdown button:hover { background: var(--surface-2); color: var(--primary); }
.btn, .icon-btn {
  border: 0;
  border-radius: 11px;
  min-height: 42px;
  padding: 0 16px;
  cursor: pointer;
  transition: 0.18s ease;
}
.btn-primary { background: var(--primary); color: white; box-shadow: 0 10px 24px rgba(15, 107, 85, .18); }
.btn-primary:hover { background: var(--primary-dark); }
.btn-ghost { background: var(--surface-2); color: var(--primary); }
.btn-danger { background: #feecec; color: var(--danger); }
.icon-btn { width: 44px; padding: 0; background: var(--surface-2); display: none; }

.app-shell {
  width: 100%;
  max-width: 1240px;
  margin: 0 auto;
  padding: 22px 20px 72px;
  flex: 1;
}
.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(300px, .8fr);
  gap: 24px;
  align-items: stretch;
  margin-bottom: 28px;
}
.hero-main {
  width: 100%;
  min-width: 0;
  min-height: 320px;
  height: auto;
  padding: 34px;
  border-radius: 16px;
  background:
    linear-gradient(135deg, rgba(15,107,85,.94), rgba(17,38,31,.92)),
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='900' height='520'%3E%3Crect width='900' height='520' fill='%230f6b55'/%3E%3Cg fill='none' stroke='%23ffffff' stroke-opacity='.13' stroke-width='2'%3E%3Cpath d='M80 430h720M140 380h620M220 330h480M120 250h660'/%3E%3Ccircle cx='690' cy='150' r='90'/%3E%3Crect x='120' y='110' width='210' height='130' rx='18'/%3E%3C/g%3E%3C/svg%3E");
  background-size: cover;
  background-position: center;
  color: white;
  box-shadow: var(--shadow);
  overflow: hidden;
}
.eyebrow { color: #cce7da; font-weight: 700; margin-bottom: 12px; }
.hero h1 { margin: 0 0 14px; font-size: 44px; line-height: 1.2; letter-spacing: 0; }
.hero p { margin: 0 0 24px; max-width: 650px; color: #e8f4ee; line-height: 1.8; }
.search-box {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(130px, 170px) minmax(130px, 170px) auto;
  gap: 10px;
  background: rgba(255,255,255,.12);
  border: 1px solid rgba(255,255,255,.2);
  padding: 12px;
  border-radius: 14px;
}
.home-layout {
  display: grid;
  grid-template-columns: 220px minmax(0, 1fr) 260px;
  grid-template-areas: "categories main ads";
  gap: 24px;
  align-items: start;
  margin-bottom: 24px;
  isolation: isolate;
}
.category-rail { grid-area: categories; }
.home-main {
  grid-area: main;
  display: grid;
  gap: 18px;
  min-width: 0;
}
.top-banner {
  width: 100%;
  min-height: 0;
  margin-bottom: 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 20px 24px;
  border-radius: 16px;
  position: static;
  z-index: auto;
}
.ad-slot,
.ad-box {
  background:
    linear-gradient(135deg, rgba(15,107,85,.1), rgba(61,139,117,.06)),
    white;
  border: 1px dashed #aac9bc;
  color: var(--text);
}
.top-banner span,
.ad-box span {
  display: block;
  color: var(--primary);
  font-size: 13px;
  font-weight: 800;
  margin-bottom: 5px;
}
.top-banner strong { font-size: 22px; }
.ad-column {
  grid-area: ads;
  display: grid;
  gap: 16px;
  align-content: start;
  min-width: 0;
  width: 100%;
  position: static;
  z-index: auto;
}
.ad-box {
  min-height: 150px;
  border-radius: 16px;
  padding: 18px;
  box-shadow: 0 10px 24px rgba(18,42,30,.05);
  position: static;
}
.ad-box strong { display: block; margin-bottom: 8px; }
.ad-box p { margin: 0; color: var(--muted); line-height: 1.7; }
.category-rail {
  width: 100%;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 16px;
  box-shadow: 0 12px 34px rgba(18,42,30,.07);
  padding: 12px;
  position: static;
  min-width: 0;
}
.rail-title {
  padding: 11px 12px 13px;
  font-weight: 800;
  color: var(--primary);
  border-bottom: 1px solid var(--line);
  margin-bottom: 6px;
}
.category-row { position: static; }
.category-row > a {
  min-height: 42px;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 10px;
  border-radius: 11px;
  color: #283a31;
}
.category-row:hover > a { background: var(--surface-2); color: var(--primary); }
.menu-icon {
  width: 28px;
  height: 28px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  background: #e6f0ea;
  font-size: 17px;
  line-height: 1;
  flex: 0 0 auto;
}
.category-name {
  flex: 1;
  display: grid;
  gap: 2px;
}
.category-name small,
.submenu small {
  color: var(--muted);
  font-size: 11px;
}
.submenu {
  position: static;
  min-width: 0;
  display: none;
  margin: 4px 38px 8px 0;
  padding: 8px;
  background: var(--surface-2);
  border: 0;
  border-radius: 12px;
  box-shadow: none;
  z-index: auto;
}
.category-row:hover .submenu { display: grid; gap: 4px; }
.submenu a {
  padding: 10px;
  border-radius: 9px;
  color: #34433a;
}
.submenu a:hover { background: var(--surface-2); color: var(--primary); }
.show-all {
  display: block;
  margin: 10px 8px 0;
  padding: 10px;
  border-radius: 10px;
  background: var(--surface-2);
  color: var(--primary);
  text-align: center;
  font-weight: 700;
}
.hero-search {
  margin-top: 22px;
  grid-template-columns: minmax(0, 1fr) minmax(130px, 170px) minmax(130px, 170px) auto;
  width: 100%;
  min-width: 0;
  overflow: hidden;
}
.hero-links,
.quick-links {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
  margin-top: 18px;
}
.hero-links a,
.quick-links a {
  padding: 8px 12px;
  border: 1px solid rgba(255,255,255,.24);
  border-radius: 999px;
  color: #edf8f2;
  background: rgba(255,255,255,.1);
}
.quick-links a:hover { background: rgba(255,255,255,.18); }
.compact-head { margin-top: 0; }
.showcase-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  align-items: stretch;
}
.trust-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  margin-bottom: 6px;
}
.trust-row div {
  background: white;
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 15px 18px;
  box-shadow: 0 10px 24px rgba(18,42,30,.05);
}
.trust-row b { display: block; margin-bottom: 5px; }
.trust-row span { color: var(--muted); font-size: 14px; }
input, select, textarea {
  width: 100%;
  min-height: 44px;
  border: 1px solid var(--line);
  border-radius: 11px;
  background: white;
  color: var(--text);
  padding: 0 13px;
  outline: none;
}
textarea { min-height: 120px; padding: 12px 13px; resize: vertical; }
input:focus, select:focus, textarea:focus { border-color: var(--primary); box-shadow: 0 0 0 3px rgba(15,107,85,.1); }

.hero-side, .panel, .card, .stat, .listing-card, .detail-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: 0 12px 34px rgba(18,42,30,.07);
}
.hero-side { padding: 24px; display: grid; gap: 14px; }
.quick-item { padding: 16px; border-radius: 12px; background: var(--surface-2); }
.quick-item b { display: block; margin-bottom: 6px; }
.quick-item span { color: var(--muted); font-size: 14px; }

.section-head { display: flex; justify-content: space-between; align-items: center; margin: 28px 0 14px; gap: 16px; }
.section-head h2 { margin: 0; font-size: 24px; }
.grid { display: grid; gap: 16px; }
.category-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.listing-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.city-grid { grid-template-columns: repeat(6, minmax(0, 1fr)); }
.card { padding: 18px; }
.card,
.listing-card,
.panel,
.stat,
.ad-box,
.top-banner,
.trust-row div {
  min-width: 0;
}
.category-card { cursor: pointer; }
.category-card strong { display: block; margin: 10px 0 5px; }
.category-card span, .muted { color: var(--muted); }
.icon-bubble {
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  background: var(--surface-2);
  font-size: 24px;
  line-height: 1;
}

.layout {
  display: grid;
  grid-template-columns: 300px minmax(0, 1fr);
  gap: 18px;
  align-items: start;
  min-height: 460px;
}
.filters { position: sticky; top: 104px; padding: 18px; }
.filters .stack { gap: 10px; }
.vehicle-filter-fields {
  display: grid;
  gap: 10px;
}
.real-estate-filter-fields {
  display: grid;
  gap: 12px;
}
.filter-grid-2 {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}
.filter-group {
  display: grid;
  gap: 6px;
}
.filter-group label {
  font-size: 12px;
  font-weight: 700;
  color: var(--muted);
}
.mobile-filter { display: none; margin-bottom: 14px; }
.listing-card { overflow: hidden; position: relative; min-height: 100%; }
.listing-image {
  height: 180px;
  width: 100%;
  background: linear-gradient(135deg, #dfe9e3, #f7faf8);
  display: grid;
  place-items: center;
  color: var(--muted);
}
.listing-body { padding: 16px; }
.listing-title {
  margin: 0 0 10px;
  font-size: 18px;
  line-height: 1.45;
  overflow-wrap: anywhere;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.vehicle-card-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 0 0 10px;
}
.vehicle-card-meta span,
.mobile-vehicle-meta span {
  max-width: 100%;
  padding: 4px 8px;
  border-radius: 999px;
  background: var(--surface-2);
  color: var(--primary);
  font-size: 12px;
  font-weight: 700;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.compact-card .listing-image { height: 118px; }
.compact-card .listing-body { padding: 12px; }
.compact-card .listing-title {
  min-height: 42px;
  font-size: 14px;
  margin-bottom: 6px;
}
.compact-card .price { font-size: 15px; }
.compact-card .listing-meta { font-size: 12px; margin-top: 8px; }
.price { color: var(--primary); font-weight: 800; font-size: 20px; overflow-wrap: anywhere; }
.listing-meta { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; color: var(--muted); font-size: 13px; }
.badge {
  display: inline-flex;
  align-items: center;
  min-height: 26px;
  padding: 0 9px;
  border-radius: 999px;
  background: #e5f2ed;
  color: var(--primary-dark);
  font-size: 12px;
  font-weight: 700;
}
.badge-warning { background: #fff0d9; color: #8a5a00; }
.badge-danger { background: #fde8e8; color: #b13b3b; }
.fav-btn {
  position: absolute;
  left: 12px;
  top: 12px;
  width: 38px;
  height: 38px;
  border: 0;
  border-radius: 50%;
  background: white;
  color: var(--danger);
  box-shadow: var(--shadow);
  cursor: pointer;
}

.detail-desktop {
  display: grid;
  gap: 16px;
}
.detail-header-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
}
.detail-breadcrumb {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  color: var(--primary);
  font-size: 12px;
  font-weight: 700;
}
.detail-breadcrumb b { color: var(--muted); font-weight: 400; }
.detail-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}
.detail-mini-action {
  min-height: 34px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: white;
  color: var(--primary);
  padding: 0 12px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  cursor: pointer;
}
.detail-mini-action span { font-size: 12px; }
.detail-title {
  margin: 0;
  font-size: 30px;
  line-height: 1.25;
  letter-spacing: 0;
}
.detail-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.12fr) minmax(280px, .72fr) 320px;
  gap: 18px;
  align-items: start;
}
.detail-gallery-col,
.detail-info-col,
.seller-card {
  min-width: 0;
}
.detail-gallery-col {
  display: grid;
  gap: 12px;
}
.detail-gallery-shell {
  position: relative;
}
.detail-gallery-shell .photo-count {
  left: 14px;
  bottom: 14px;
}
.desktop-tabs {
  margin-bottom: 12px;
}
.desktop-tab-panels {
  display: grid;
}
.desktop-tab-panel {
  display: none;
}
.desktop-tab-panel.active {
  display: block;
}
.desktop-description {
  line-height: 1.9;
  color: #26362d;
  white-space: pre-wrap;
  text-align: right;
  overflow-wrap: anywhere;
}
.desktop-info-table {
  display: grid;
}
.desktop-info-row {
  min-height: 42px;
  display: grid;
  grid-template-columns: minmax(0, 180px) minmax(0, 1fr);
  gap: 16px;
  align-items: center;
  padding: 10px 0;
  border-bottom: 1px solid var(--line);
}
.desktop-info-row:last-child { border-bottom: 0; }
.desktop-info-row span {
  color: var(--muted);
  font-weight: 700;
}
.desktop-info-row b {
  overflow-wrap: anywhere;
}
.empty-inline {
  padding: 12px 0;
}
.detail-price-card,
.detail-spec-card,
.detail-section {
  padding: 18px;
}
.detail-price {
  margin: 0 0 8px;
  font-size: 30px;
}
.detail-location {
  color: var(--muted);
  line-height: 1.6;
}
.detail-section-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: baseline;
  margin-bottom: 12px;
}
.detail-section-head strong {
  font-size: 18px;
}
.detail-section-head span {
  color: var(--muted);
  font-size: 12px;
}
.detail-info-col {
  display: grid;
  gap: 12px;
}
.mobile-detail { display: none; }
.gallery-main {
  height: 430px;
  border-radius: var(--radius);
  background: linear-gradient(135deg, #dfe9e3, #f7faf8);
  display: grid;
  place-items: center;
  overflow: hidden;
}
.gallery-main img, .listing-image img { width: 100%; height: 100%; object-fit: cover; }
.thumbs { display: flex; gap: 8px; margin-top: 10px; overflow-x: auto; }
.thumbs img { width: 92px; height: 68px; object-fit: cover; border-radius: 9px; border: 2px solid var(--line); cursor: pointer; flex: 0 0 auto; }
.seller-card {
  padding: 18px;
  position: sticky;
  top: 104px;
  display: grid;
  gap: 14px;
}

.real-estate-detail {
  max-width: 1240px;
  margin: 0 auto;
  padding: 18px 18px 48px;
  color: #222;
  direction: rtl;
}
.real-estate-path {
  min-height: 34px;
  display: flex;
  align-items: center;
  gap: 7px;
  flex-wrap: wrap;
  border-bottom: 1px solid #d7dce2;
  color: var(--primary);
  font-size: 13px;
  font-weight: 700;
}
.real-estate-path b {
  color: #8a96a3;
  font-weight: 400;
}
.real-estate-title {
  margin: 14px 0 8px;
  font-size: 25px;
  line-height: 1.3;
  letter-spacing: 0;
}
.real-estate-topbar {
  display: flex;
  justify-content: flex-end;
  min-height: 30px;
  margin-bottom: 10px;
}
.real-estate-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}
.real-estate-actions button {
  border: 0;
  background: transparent;
  color: var(--primary);
  font-weight: 700;
  cursor: pointer;
}
.real-estate-layout {
  display: grid;
  grid-template-columns: minmax(420px, 1.05fr) minmax(320px, .78fr) 300px;
  gap: 18px;
  align-items: start;
}
.real-estate-media,
.real-estate-info,
.real-estate-seller {
  min-width: 0;
}
.real-estate-listing-id {
  color: #8b8b8b;
  font-size: 12px;
  margin-bottom: 8px;
}
.real-estate-main-photo {
  width: 100%;
  height: 470px;
  border: 1px solid #d4d4d4;
  background: #f4f5f6;
  display: grid;
  place-items: center;
  padding: 0;
  cursor: zoom-in;
  overflow: hidden;
}
.real-estate-main-photo img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  background: #fff;
}
.real-estate-main-photo span {
  color: #555;
}
.real-estate-photo-strip {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 8px;
  border: 1px solid #d7dce2;
  border-top: 0;
  padding: 10px;
  background: #fafafa;
}
.real-estate-photo-strip button {
  height: 82px;
  padding: 0;
  border: 1px solid #c9d2df;
  background: #fff;
  cursor: pointer;
  overflow: hidden;
}
.real-estate-photo-strip img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.real-estate-photo-count {
  padding-top: 8px;
  font-size: 13px;
  color: #333;
}
.real-estate-info {
  padding-top: 4px;
}
.real-estate-price {
  color: var(--primary);
  font-size: 24px;
  font-weight: 800;
  margin-bottom: 10px;
}
.real-estate-location {
  color: var(--primary);
  font-weight: 800;
  line-height: 1.7;
  margin-bottom: 12px;
}
.real-estate-spec-table {
  border-top: 1px solid #d4d4d4;
}
.real-estate-spec-row {
  min-height: 31px;
  display: grid;
  grid-template-columns: minmax(115px, .68fr) minmax(0, 1fr);
  gap: 10px;
  align-items: center;
  border-bottom: 1px solid #d4d4d4;
  font-size: 13px;
}
.real-estate-spec-row span {
  font-weight: 800;
  color: #202020;
}
.real-estate-spec-row b {
  font-weight: 600;
  color: #111;
  overflow-wrap: anywhere;
}
.real-estate-spec-row .info-id {
  color: var(--primary);
}
.real-estate-seller {
  border: 1px solid #d4d4d4;
  background: #fafafa;
  padding: 16px;
}
.real-estate-seller h2 {
  margin: 0 0 10px;
  font-size: 17px;
}
.real-estate-seller p {
  margin: 8px 0 14px;
  color: #6d7378;
  line-height: 1.6;
}
.real-estate-phone-box {
  min-height: 48px;
  display: grid;
  grid-template-columns: 70px 1fr;
  align-items: center;
  border: 1px solid #d4d4d4;
  background: #fff;
  margin-bottom: 12px;
}
.real-estate-phone-box span {
  padding-inline-start: 12px;
  color: #333;
}
.real-estate-phone-box button {
  height: 100%;
  border: 0;
  background: transparent;
  color: #111;
  font-weight: 800;
  cursor: pointer;
}
.real-estate-message,
.real-estate-whatsapp {
  width: 100%;
  min-height: 42px;
  display: grid;
  place-items: center;
  border: 0;
  background: #eef5f1;
  color: var(--primary);
  font-weight: 800;
  margin-top: 10px;
  text-decoration: none;
  cursor: pointer;
}
.real-estate-safety {
  margin-top: 16px;
  padding: 14px;
  background: #f3f8f6;
  border: 1px solid #dce9e4;
}
.real-estate-safety p {
  margin-bottom: 0;
}
.real-estate-adbox {
  min-height: 150px;
  margin-top: 14px;
  border: 1px dashed #a9cfc2;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 6px;
  color: #40544b;
}
.real-estate-adbox span {
  color: var(--primary);
  font-weight: 800;
}
.real-estate-tabs {
  display: flex;
  align-items: end;
  gap: 8px;
  margin-top: 42px;
  border-bottom: 3px solid var(--primary);
}
.real-estate-tabs button {
  min-height: 42px;
  padding: 0 22px;
  border: 1px solid #c8cfd6;
  border-bottom: 0;
  background: #f8f8f8;
  color: var(--primary);
  font-weight: 800;
  cursor: pointer;
}
.real-estate-tabs button.active {
  background: #e8f3ee;
  color: var(--primary-dark);
}
.real-estate-panel {
  display: none;
  border: 1px solid #d4d4d4;
  border-top: 0;
  background: #fff;
  padding: 16px;
}
.real-estate-panel.active {
  display: block;
}
.real-estate-panel h3 {
  margin: 0 0 12px;
  font-size: 17px;
}
.real-estate-panel p {
  margin: 0;
  line-height: 1.9;
  white-space: pre-wrap;
}
.real-estate-feature-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0;
  border-top: 1px solid var(--line);
  border-right: 1px solid var(--line);
}
.real-estate-feature-grid div {
  min-height: 44px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  align-items: center;
  padding: 8px 12px;
  background: #f7faf8;
  border-left: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}
.real-estate-feature-grid span {
  color: #6b6b6b;
  font-weight: 700;
}
.real-estate-feature-grid b {
  color: #111;
  overflow-wrap: anywhere;
}

.vehicle-detail-page {
  max-width: 1240px;
  margin: 0 auto;
  padding: 18px 18px 48px;
  color: #222;
  direction: rtl;
}
.vehicle-detail-path {
  min-height: 34px;
  display: flex;
  align-items: center;
  gap: 7px;
  flex-wrap: wrap;
  border-bottom: 1px solid var(--line);
  color: var(--primary);
  font-size: 13px;
  font-weight: 700;
}
.vehicle-detail-path b {
  color: var(--muted);
  font-weight: 400;
}
.vehicle-detail-heading {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: start;
  margin: 14px 0 12px;
}
.vehicle-detail-heading h1 {
  margin: 0;
  font-size: 25px;
  line-height: 1.3;
  letter-spacing: 0;
}
.vehicle-detail-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}
.vehicle-detail-actions button {
  border: 0;
  background: transparent;
  color: var(--primary);
  font-weight: 700;
  cursor: pointer;
}
.vehicle-detail-layout {
  display: grid;
  grid-template-columns: minmax(420px, 1.05fr) minmax(320px, .78fr) 300px;
  gap: 18px;
  align-items: start;
}
.vehicle-detail-media,
.vehicle-detail-info,
.vehicle-seller-card {
  min-width: 0;
}
.vehicle-listing-id {
  color: var(--muted);
  font-size: 12px;
  margin-bottom: 8px;
}
.vehicle-main-photo {
  width: 100%;
  height: 420px;
  border: 1px solid var(--line);
  background: #f4f5f6;
  display: grid;
  place-items: center;
  padding: 0;
  cursor: zoom-in;
  overflow: hidden;
}
.vehicle-main-photo img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  background: #fff;
}
.vehicle-main-photo span {
  color: var(--muted);
}
.vehicle-gallery-tools {
  min-height: 38px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  border: 1px solid var(--line);
  border-top: 0;
  padding: 0 12px;
  background: #f7faf8;
  color: #333;
  font-size: 13px;
}
.vehicle-gallery-tools button {
  border: 0;
  background: transparent;
  color: var(--primary);
  font-weight: 800;
  cursor: pointer;
}
.vehicle-thumbs {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 8px;
  border: 1px solid var(--line);
  border-top: 0;
  padding: 10px;
  background: #fff;
}
.vehicle-thumbs button {
  height: 78px;
  padding: 0;
  border: 1px solid var(--line);
  background: #fff;
  cursor: pointer;
  overflow: hidden;
}
.vehicle-thumbs img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.vehicle-price {
  color: var(--primary);
  font-size: 24px;
  font-weight: 800;
  margin-bottom: 10px;
}
.vehicle-location {
  color: var(--primary);
  font-weight: 800;
  line-height: 1.7;
  margin-bottom: 12px;
}
.vehicle-spec-table {
  border-top: 1px solid var(--line);
}
.vehicle-spec-row {
  min-height: 31px;
  display: grid;
  grid-template-columns: minmax(120px, .7fr) minmax(0, 1fr);
  gap: 10px;
  align-items: center;
  border-bottom: 1px solid var(--line);
  font-size: 13px;
}
.vehicle-spec-row span {
  font-weight: 800;
  color: #202020;
}
.vehicle-spec-row b {
  font-weight: 600;
  color: #111;
  overflow-wrap: anywhere;
}
.vehicle-spec-row .info-id {
  color: var(--primary);
}
.vehicle-seller-card {
  border: 1px solid var(--line);
  background: #fafafa;
  padding: 16px;
}
.vehicle-seller-card h2 {
  margin: 0 0 10px;
  font-size: 17px;
}
.vehicle-seller-card p {
  margin: 8px 0 14px;
  color: var(--muted);
  line-height: 1.6;
}
.vehicle-phone-box {
  min-height: 48px;
  display: grid;
  grid-template-columns: 70px 1fr;
  align-items: center;
  border: 1px solid var(--line);
  background: #fff;
  margin-bottom: 12px;
}
.vehicle-phone-box span {
  padding-inline-start: 12px;
}
.vehicle-phone-box button {
  height: 100%;
  border: 0;
  background: transparent;
  color: #111;
  font-weight: 800;
  cursor: pointer;
}
.vehicle-message,
.vehicle-whatsapp {
  width: 100%;
  min-height: 42px;
  display: grid;
  place-items: center;
  border: 0;
  background: #eef5f1;
  color: var(--primary);
  font-weight: 800;
  margin-top: 10px;
  text-decoration: none;
  cursor: pointer;
}
.vehicle-safety {
  margin-top: 16px;
  padding: 14px;
  background: #f3f8f6;
  border: 1px solid #dce9e4;
}
.vehicle-safety p {
  margin-bottom: 0;
}
.vehicle-adbox {
  min-height: 150px;
  margin-top: 14px;
  border: 1px dashed #a9cfc2;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 6px;
  color: #40544b;
}
.vehicle-adbox span {
  color: var(--primary);
  font-weight: 800;
}
.vehicle-service-links {
  display: flex;
  justify-content: center;
  gap: 26px;
  flex-wrap: wrap;
  margin: 24px 0 16px;
  color: var(--primary);
  font-weight: 800;
  font-size: 13px;
}
.vehicle-tabs {
  display: flex;
  align-items: end;
  gap: 8px;
  border-bottom: 3px solid var(--primary);
}
.vehicle-tabs button {
  min-height: 42px;
  padding: 0 22px;
  border: 1px solid var(--line);
  border-bottom: 0;
  background: #f8f8f8;
  color: var(--primary);
  font-weight: 800;
  cursor: pointer;
}
.vehicle-tabs button.active {
  background: #e8f3ee;
  color: var(--primary-dark);
}
.vehicle-panel {
  display: none;
  border: 1px solid var(--line);
  border-top: 0;
  background: #fff;
  padding: 16px;
}
.vehicle-panel.active {
  display: block;
}
.vehicle-panel h3 {
  margin: 0 0 12px;
  font-size: 17px;
}
.vehicle-panel p {
  margin: 0;
  line-height: 1.9;
  white-space: pre-wrap;
}
.vehicle-feature-card {
  margin-top: 16px;
  display: grid;
  gap: 18px;
}
.vehicle-feature-head {
  min-height: 38px;
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
  border: 1px solid var(--line);
  background: #f7faf8;
  padding: 8px 12px;
}
.vehicle-feature-head strong {
  color: var(--primary);
}
.vehicle-feature-head span {
  color: var(--muted);
  font-size: 13px;
}
.vehicle-paint-card {
  border: 1px solid var(--line);
  background: var(--surface);
  padding: 14px;
}
.vehicle-paint-card h4,
.vehicle-equipment-group h4 {
  margin: 0 0 12px;
  color: var(--primary);
  font-size: 15px;
}
.vehicle-paint-layout {
  display: grid;
  grid-template-columns: minmax(260px, 430px) minmax(220px, 1fr);
  gap: 24px;
  align-items: center;
}
.vehicle-paint-visual {
  min-height: 360px;
  display: grid;
  place-items: center;
}
.car-map {
  position: relative;
  width: min(100%, 460px);
  aspect-ratio: 1459 / 1078;
  display: grid;
  place-items: center;
}
.paint-car-template {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
  pointer-events: none;
  user-select: none;
}
.paint-car-overlay {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  overflow: visible;
  pointer-events: none;
  display: none;
}
.vehicle-paint-list {
  align-self: start;
  display: grid;
  gap: 10px;
  color: #26362d;
}
.vehicle-paint-list ul {
  margin: 0;
  padding: 0;
  display: grid;
  gap: 10px;
  list-style: none;
}
.vehicle-paint-list li {
  display: flex;
  align-items: center;
  gap: 8px;
  line-height: 1.6;
}
.vehicle-paint-list b {
  color: var(--primary);
  margin-inline-start: 4px;
}
.paint-dot {
  width: 8px;
  height: 8px;
  flex: 0 0 auto;
  background: #a3a3a3;
}
.paint-dot.is-local-painted { background: #fb923c; }
.paint-dot.is-painted { background: #3b82f6; }
.paint-dot.is-replaced { background: #ef4444; }
.vehicle-equipment-card {
  display: grid;
  gap: 16px;
}
.vehicle-equipment-group {
  border: 1px solid var(--line);
  background: var(--surface-2);
  padding: 12px 14px;
}
.vehicle-equipment-list {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px 18px;
}
.vehicle-equipment-list span {
  min-height: 24px;
  color: #26362d;
  font-weight: 700;
  overflow-wrap: anywhere;
}
.seller-top h2 {
  margin: 0 0 4px;
  font-size: 20px;
}
.seller-meta {
  display: grid;
  gap: 10px;
}
.seller-meta div {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--line);
}
.seller-meta div:last-child {
  border-bottom: 0;
  padding-bottom: 0;
}
.seller-meta span {
  color: var(--muted);
  font-size: 12px;
}
.seller-actions { display: grid; gap: 10px; margin-top: 4px; }
.security-box {
  padding: 14px;
  border-radius: 14px;
  background: #eff6f2;
  color: #284036;
}
.security-box strong {
  display: block;
  margin-bottom: 6px;
}
.security-box p {
  margin: 0;
  color: var(--muted);
  line-height: 1.7;
}
.detail-ad-box {
  min-height: 180px;
}
.attributes { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; margin-top: 14px; }
.attr { padding: 12px; background: var(--surface-2); border-radius: 10px; }

.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.full { grid-column: 1 / -1; }
.stack { display: grid; gap: 12px; }
.panel { padding: 22px; }
.form-grid input[readonly] {
  background: #f5f7f6;
  color: #40534a;
  cursor: not-allowed;
}
.vehicle-select-block {
  display: grid;
  gap: 8px;
  min-width: 0;
}
.desktop-add-shell {
  max-width: 1200px;
  margin: 0 auto;
  padding: 20px 0 44px;
}
.desktop-add-head {
  display: grid;
  gap: 16px;
  margin-bottom: 20px;
}
.desktop-stepper {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}
.desktop-stepper .step {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 10px;
  align-items: center;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
  color: var(--muted);
}
.desktop-stepper .step span {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--line);
  color: var(--text);
  font-weight: 700;
}
.desktop-stepper .step.active {
  border-color: var(--primary);
  color: var(--primary);
}
.desktop-stepper .step.active span {
  background: var(--primary);
  color: #fff;
}
.desktop-stepper .step.completed {
  border-color: #cfe5dc;
  background: #f3f8f6;
  color: var(--primary-dark);
}
.desktop-stepper .step.completed span {
  background: #dcebe5;
  color: var(--primary-dark);
}
.desktop-add-content {
  background: #fff;
  border: 1px solid #eef2f7;
  border-radius: 14px;
  padding: 22px;
  box-shadow: 0 10px 28px rgba(15, 23, 42, 0.05);
}
.desktop-category-prompt { margin-bottom: 16px; }
.desktop-category-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
}
.desktop-category-card {
  display: grid;
  gap: 10px;
  padding: 18px 16px;
  border: 1px solid #e5e7eb;
  border-top: 4px solid var(--primary);
  border-radius: 12px;
  background: #fff;
  text-align: right;
  cursor: pointer;
}
.desktop-category-icon {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: #effaf4;
  font-size: 20px;
}
.desktop-category-flow {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(0, 1.2fr) minmax(0, 1.2fr) 220px;
  gap: 14px;
  align-items: start;
}
.spare-category-shell {
  display: grid;
  gap: 16px;
  background: #fff;
}
.spare-category-head {
  display: grid;
  gap: 10px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--line);
}
.spare-category-head h3 {
  margin: 0;
  font-size: 24px;
}
.spare-breadcrumb,
.desktop-form-path {
  min-height: 38px;
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  color: var(--muted);
}
.spare-breadcrumb span,
.desktop-form-path span {
  color: var(--text);
  font-weight: 700;
}
.spare-breadcrumb b,
.desktop-form-path b {
  color: #9aa4ad;
  font-weight: 400;
}
.spare-category-board {
  direction: rtl;
  display: grid;
  grid-template-columns: repeat(5, minmax(170px, 1fr));
  align-items: stretch;
  border: 1px solid #d8dde3;
  background: #fff;
  overflow-x: auto;
}
.spare-category-column {
  min-height: 330px;
  border-left: 1px solid #d8dde3;
  background: #fff;
}
.spare-category-column:last-child {
  border-left: 0;
}
.spare-category-column h4 {
  margin: 0;
  padding: 12px 14px;
  border-bottom: 1px solid #e7eaee;
  background: #f7f8fa;
  color: #333b44;
  font-size: 14px;
}
.spare-category-list {
  display: grid;
  align-content: start;
}
.spare-category-item {
  width: 100%;
  min-height: 38px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 18px;
  align-items: center;
  gap: 8px;
  border: 0;
  border-bottom: 1px solid #edf0f2;
  background: #fff;
  color: #2f3740;
  text-align: right;
  padding: 9px 12px;
  cursor: pointer;
}
.spare-category-item:hover,
.spare-category-item.active {
  background: #eef0f2;
}
.spare-category-item span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.spare-category-item i {
  color: #6b7280;
  font-style: normal;
  transform: scaleX(-1);
}
.spare-continue-panel {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  padding: 14px;
  border: 1px solid var(--line);
  background: #f8fafc;
}
.spare-continue-panel span {
  color: var(--muted);
  overflow-wrap: anywhere;
}
.spare-add-panel {
  border: 1px solid var(--line);
  background: #fff;
}
.spare-add-panel summary {
  min-height: 46px;
  display: flex;
  align-items: center;
  padding: 0 14px;
  cursor: pointer;
  font-weight: 800;
}
.spare-add-form {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr)) auto;
  gap: 10px;
  padding: 0 14px 14px;
}
.desktop-vehicle-flow {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: 220px;
  gap: 14px;
  align-items: start;
  overflow-x: auto;
  padding-bottom: 6px;
}
.desktop-vehicle-flow-col,
.desktop-vehicle-flow-summary {
  min-height: 240px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
}
.desktop-vehicle-flow-col h4,
.desktop-vehicle-flow-summary h4 {
  margin: 0 0 12px;
}
.desktop-vehicle-summary {
  display: grid;
  gap: 14px;
  padding: 14px 16px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #f8fafc;
}
.desktop-vehicle-brand {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}
.desktop-vehicle-logo {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: #e8f6ee;
  font-size: 22px;
}
.desktop-vehicle-meta {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}
.desktop-vehicle-path {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 7px;
}
.desktop-vehicle-path span {
  max-width: 130px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  padding: 4px 8px;
  border-radius: 999px;
  background: #eef6f1;
  color: #51645a;
  font-size: 12px;
  font-weight: 700;
}
.desktop-vehicle-meta span {
  padding: 6px 10px;
  border-radius: 999px;
  background: #edf7f1;
  color: var(--primary);
  font-size: 12px;
  font-weight: 700;
}
.desktop-flow-col,
.desktop-flow-summary {
  min-height: 240px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
}
.desktop-flow-item {
  width: 100%;
  display: block;
  margin-bottom: 8px;
  padding: 10px 12px;
  border: 1px solid #edf2f7;
  border-radius: 8px;
  background: #f8fafc;
  text-align: right;
}
.desktop-success-box {
  background: #ecfdf3;
  color: #166534;
  border: 1px solid #bbf7d0;
  padding: 10px 12px;
  border-radius: 10px;
  font-weight: 700;
}
.desktop-selected-path { margin: 14px 0; color: var(--text); font-weight: 600; }
.desktop-form-shell { display: grid; gap: 16px; }
.desktop-form-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}
.desktop-form-path {
  min-width: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.8;
}
.desktop-form-path span {
  display: inline-flex;
  max-width: 150px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.desktop-add-form { max-width: none; }
.listing-form-map-wrap { display: grid; gap: 10px; }
.listing-form-map {
  width: 100%;
  min-height: 360px;
  border: 1px solid var(--line);
  border-radius: 12px;
  overflow: hidden;
}
.desktop-preview-card {
  margin-top: 20px;
  border: 1px solid #e5e7eb;
  border-radius: 12px;
  padding: 16px;
  background: #f8fafc;
}
.desktop-preview-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 10px;
}
.desktop-preview-grid {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
  color: var(--muted);
  margin: 10px 0 16px;
}
.desktop-preview-stack {
  display: grid;
  gap: 10px;
  margin-bottom: 16px;
}
.desktop-preview-stack strong {
  display: block;
  margin-bottom: 4px;
}
.desktop-preview-stack p {
  margin: 0;
  color: var(--muted);
}
.published-like-preview {
  position: relative;
  overflow: hidden;
  border: 1px solid var(--line);
  background: #fff;
}
.preview-watermark {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  pointer-events: none;
  color: rgba(16, 117, 92, .08);
  font-size: clamp(64px, 12vw, 160px);
  font-weight: 900;
  transform: rotate(-18deg);
  z-index: 0;
}
.published-like-preview > *:not(.preview-watermark) {
  position: relative;
  z-index: 1;
}
.published-preview-layout {
  display: grid;
  grid-template-columns: minmax(260px, 420px) minmax(0, 1fr);
  gap: 18px;
  align-items: start;
}
.published-preview-media {
  min-height: 280px;
  border: 1px solid var(--line);
  background: #f7faf8;
  display: grid;
  place-items: center;
  overflow: hidden;
}
.published-preview-media img {
  width: 100%;
  height: 100%;
  max-height: 360px;
  object-fit: contain;
  background: #fff;
}
.published-preview-media span {
  color: var(--muted);
}
.published-preview-main {
  display: grid;
  gap: 10px;
}
.published-preview-path {
  color: var(--primary);
  font-size: 13px;
  font-weight: 800;
}
.published-preview-main h3 {
  margin: 0;
  font-size: 24px;
  line-height: 1.35;
}
.published-preview-price {
  color: var(--primary);
  font-size: 26px;
  font-weight: 900;
}
.published-preview-location {
  color: var(--primary-dark);
  font-weight: 800;
}
.published-preview-main p {
  margin: 0;
  line-height: 1.9;
  white-space: pre-wrap;
}
.published-preview-meta {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin-top: 16px;
}
.published-preview-meta span {
  min-height: 38px;
  display: flex;
  align-items: center;
  padding: 8px 12px;
  border: 1px solid var(--line);
  background: #f7faf8;
  color: #26362d;
  font-weight: 700;
}
.published-preview-actions {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: center;
  margin-top: 18px;
  padding-top: 16px;
  border-top: 1px solid var(--line);
}
.published-preview-actions p {
  margin: 0;
  color: var(--muted);
  line-height: 1.7;
}
.published-preview-actions .btn {
  min-width: 180px;
}
.detail-extra-section,
.mobile-extra-section {
  display: grid;
  gap: 12px;
  margin-top: 14px;
  padding: 16px;
  border-radius: 12px;
  border: 1px solid #e5e7eb;
  background: #fff;
}
.detail-extra-section h3,
.mobile-extra-section h3 {
  margin: 0;
  font-size: 17px;
}
.paint-info-list,
.equipment-groups {
  display: grid;
  gap: 10px;
}
.paint-info-row,
.equipment-group {
  display: grid;
  gap: 6px;
  padding: 10px 12px;
  border: 1px solid #edf2f7;
  border-radius: 10px;
  background: #f8fafc;
}
.paint-info-row strong,
.equipment-group strong {
  color: var(--text);
}
.paint-status {
  color: var(--primary);
  font-weight: 700;
}
.equipment-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(220px, 1fr));
  gap: 10px;
  align-items: start;
}
.equipment-card {
  min-width: 0;
  display: grid;
  gap: 8px;
  padding: 10px;
  border: 1px solid #edf2f7;
  border-radius: 10px;
  background: #fff;
}
.equipment-card summary {
  cursor: pointer;
  font-size: 14px;
  font-weight: 800;
  line-height: 1.5;
}
.equipment-options {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(118px, 1fr));
  gap: 7px;
}
.equipment-option {
  min-width: 0;
  min-height: 34px;
  display: grid;
  grid-template-columns: 18px minmax(0, 1fr);
  align-items: center;
  gap: 7px;
  padding: 6px 8px;
  border: 1px solid #edf2f7;
  border-radius: 8px;
  background: #f8fafc;
  font-size: 13px;
  line-height: 1.35;
}
.equipment-option span {
  min-width: 0;
  overflow-wrap: anywhere;
}
.equipment-option input[type="checkbox"] {
  width: 16px;
  height: 16px;
  min-height: 16px;
  margin: 0;
  padding: 0;
  accent-color: var(--primary);
}
.equipment-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.equipment-item {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 6px 10px;
  border-radius: 999px;
  background: #effaf4;
  color: var(--primary);
  font-size: 13px;
  font-weight: 700;
}
.car-paint-grid {
  display: grid;
  gap: 8px;
  margin-top: 8px;
}
.car-paint-grid-modern {
  display: grid;
  gap: 10px;
}
.car-paint-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.car-paint-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 9px;
  border-radius: 999px;
  border: 1px solid #e5e7eb;
  background: #fff;
  font-size: 11px;
  font-weight: 700;
}
.car-paint-chip i {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  display: inline-block;
  background: #a3a3a3;
}
.car-paint-chip[data-state="local-painted"] i { background: #fb923c; }
.car-paint-chip[data-state="painted"] i { background: #3b82f6; }
.car-paint-chip[data-state="replaced"] i { background: #ef4444; }
.car-paint-layout {
  display: grid;
  grid-template-columns: minmax(260px, 340px) minmax(0, 1fr);
  gap: 18px;
  align-items: start;
}
.car-paint-diagram {
  position: relative;
  min-height: 460px;
  padding: 18px;
  border: 1px solid #edf2f7;
  border-radius: 12px;
  background: linear-gradient(180deg, #f9fafb, #fff);
  overflow: hidden;
}
.car-outline {
  width: 100%;
  height: 100%;
  display: block;
}
.car-outline rect,
.car-outline circle {
  fill: #d1d5db;
  stroke: #a3a3a3;
  stroke-width: 1.2;
}
.car-hotspot {
  position: absolute;
  width: 24px;
  height: 24px;
  margin-left: -12px;
  margin-top: -12px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: #fff;
  border: 2px solid #60a5fa;
  color: #2563eb;
  font-weight: 800;
  line-height: 1;
}
.car-hotspot[data-state="original"] { background: #a3a3a3; color: #fff; border-color: #a3a3a3; }
.car-hotspot[data-state="local-painted"] { background: #fb923c; color: #fff; border-color: #fb923c; }
.car-hotspot[data-state="painted"] { background: #3b82f6; color: #fff; border-color: #3b82f6; }
.car-hotspot[data-state="replaced"] { background: #ef4444; color: #fff; border-color: #ef4444; }
.car-paint-table-wrap {
  display: grid;
  gap: 5px;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}
.car-paint-table-head,
.car-paint-row {
  display: grid;
  grid-template-columns: minmax(160px, 1.4fr) repeat(4, 76px) 42px;
  gap: 6px;
  align-items: center;
  min-width: 560px;
}
.car-paint-table-head {
  padding: 0 2px 2px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 700;
}
.car-paint-table-head span,
.car-paint-row strong,
.car-paint-row label,
.car-paint-detail {
  white-space: nowrap;
}
.car-paint-row {
  min-height: 42px;
  padding: 5px 6px;
  border: 1px solid #edf2f7;
  border-radius: 8px;
  background: #fff;
  width: 100%;
}
.car-paint-row[data-state="original"] { box-shadow: inset 0 0 0 1px rgba(163,163,163,.18); }
.car-paint-row[data-state="local-painted"] { box-shadow: inset 0 0 0 1px rgba(251,146,60,.20); }
.car-paint-row[data-state="painted"] { box-shadow: inset 0 0 0 1px rgba(59,130,246,.20); }
.car-paint-row[data-state="replaced"] { box-shadow: inset 0 0 0 1px rgba(239,68,68,.20); }
.car-paint-row strong {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  font-size: 12px;
  line-height: 1.35;
}
.car-paint-row label {
  display: grid;
  place-items: center;
  min-height: 24px;
}
.car-paint-row input[type="radio"] {
  width: 16px;
  height: 16px;
  min-height: 16px;
  margin: 0;
  padding: 0;
}
.car-paint-row input[type="radio"] { accent-color: var(--primary); }
.car-paint-detail {
  width: 26px;
  height: 26px;
  min-height: 26px;
  padding: 0;
  border: 0;
  border-radius: 7px;
  background: transparent;
  color: var(--primary);
  font-size: 14px;
  line-height: 1;
}
.car-paint-footer {
  font-size: 11px;
}
.car-paint-nochange {
  padding: 8px 10px;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  background: #f8fafc;
}
.car-paint-nochange label {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  white-space: nowrap;
  font-size: 13px;
}
.car-paint-nochange input[type="checkbox"] {
  width: 16px;
  height: 16px;
  min-height: 16px;
  margin: 0;
  padding: 0;
  accent-color: var(--primary);
}
.equipment-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(220px, 1fr));
  gap: 10px;
  align-items: start;
}
.equipment-card {
  min-width: 0;
  display: grid;
  gap: 8px;
  padding: 10px;
  border: 1px solid #edf2f7;
  border-radius: 10px;
  background: #fff;
}
.equipment-card summary {
  cursor: pointer;
  font-size: 14px;
  font-weight: 800;
  line-height: 1.5;
}
.equipment-options {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(118px, 1fr));
  gap: 7px;
}
.equipment-option {
  min-width: 0;
  min-height: 34px;
  display: grid;
  grid-template-columns: 18px minmax(0, 1fr);
  align-items: center;
  gap: 7px;
  padding: 6px 8px;
  border: 1px solid #edf2f7;
  border-radius: 8px;
  background: #f8fafc;
  font-size: 13px;
  line-height: 1.35;
}
.equipment-option span {
  min-width: 0;
  overflow-wrap: anywhere;
}
.equipment-option input[type="checkbox"] {
  width: 16px;
  height: 16px;
  min-height: 16px;
  margin: 0;
  padding: 0;
  accent-color: var(--primary);
}
.car-paint-table-wrap {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  display: grid;
  gap: 5px;
}
.car-paint-table-head,
.car-paint-row {
  display: grid;
  grid-template-columns: minmax(160px, 1.4fr) repeat(4, 76px) 42px;
  gap: 6px;
  align-items: center;
  min-width: 560px;
}
.car-paint-table-head {
  padding: 0 2px 2px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 700;
}
.car-paint-table-head span,
.car-paint-row strong,
.car-paint-row label,
.car-paint-detail {
  white-space: nowrap;
}
.car-paint-row {
  min-height: 42px;
  padding: 5px 6px;
  border: 1px solid #edf2f7;
  border-radius: 8px;
  background: #fff;
  width: 100%;
}
.car-paint-row[data-state="original"] { box-shadow: inset 0 0 0 1px rgba(163,163,163,.18); }
.car-paint-row[data-state="local-painted"] { box-shadow: inset 0 0 0 1px rgba(251,146,60,.20); }
.car-paint-row[data-state="painted"] { box-shadow: inset 0 0 0 1px rgba(59,130,246,.20); }
.car-paint-row[data-state="replaced"] { box-shadow: inset 0 0 0 1px rgba(239,68,68,.20); }
.car-paint-row strong {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  font-size: 12px;
  line-height: 1.35;
}
.car-paint-row label {
  display: grid;
  place-items: center;
  min-height: 24px;
}
.car-paint-row input[type="radio"] {
  width: 16px;
  height: 16px;
  min-height: 16px;
  margin: 0;
  padding: 0;
  accent-color: var(--primary);
}
.car-paint-detail {
  width: 26px;
  height: 26px;
  min-height: 26px;
  padding: 0;
  border: 0;
  border-radius: 7px;
  background: transparent;
  color: var(--primary);
  font-size: 14px;
  line-height: 1;
}
.car-paint-footer {
  font-size: 11px;
}
.desktop-generic-box {
  display: grid;
  gap: 14px;
  padding: 20px;
  border: 1px dashed var(--line);
  border-radius: 12px;
  background: #f8fafc;
}
.vehicle-add-btn {
  width: fit-content;
  min-height: 34px;
  padding: 0 12px;
  font-size: 12px;
  justify-self: start;
}
.suggest-modal {
  width: min(460px, 100%);
}
.suggest-modal .stack {
  gap: 10px;
}
.dashboard {
  display: grid;
  grid-template-columns: 240px minmax(0, 1fr);
  gap: 18px;
}
.side-menu { display: grid; gap: 8px; align-self: start; }
.side-menu button {
  text-align: right;
  border: 0;
  border-radius: 10px;
  padding: 13px;
  background: transparent;
  cursor: pointer;
}
.side-menu button.active, .side-menu button:hover { background: var(--surface-2); color: var(--primary); }
.stats-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.stat { padding: 18px; }
.stat strong { display: block; font-size: 28px; margin-top: 8px; color: var(--primary); }
.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; min-width: 720px; }
th, td { text-align: right; padding: 12px; border-bottom: 1px solid var(--line); }
th { color: var(--muted); font-weight: 700; }
.admin-approval-table { min-width: 980px; }
.admin-approval-table td { vertical-align: middle; }
.admin-thumb {
  width: 74px;
  height: 56px;
  display: grid;
  place-items: center;
  border-radius: 10px;
  background: var(--surface-2);
  color: var(--muted);
  font-size: 12px;
  overflow: hidden;
}
.admin-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.empty-state {
  min-height: 280px;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 12px;
  padding: 34px 18px;
  background: white;
  border: 1px solid var(--line);
  border-radius: 16px;
  box-shadow: 0 12px 34px rgba(18,42,30,.07);
  text-align: center;
}
.empty-state strong {
  font-size: 22px;
}
.empty-state p {
  margin: 0;
  color: var(--muted);
}

.admin-shell {
  display: grid;
  grid-template-columns: 270px minmax(0, 1fr);
  gap: 18px;
  min-height: calc(100vh - 160px);
}
.admin-sidebar {
  position: sticky;
  top: 104px;
  align-self: start;
  padding: 18px;
  border-radius: 18px;
  background: #0f1720;
  color: #e8eff5;
  box-shadow: 0 18px 42px rgba(9, 18, 28, .22);
}
.admin-brand {
  padding-bottom: 14px;
  border-bottom: 1px solid rgba(255,255,255,.08);
  margin-bottom: 14px;
}
.admin-brand strong,
.admin-brand small,
.admin-topbar strong,
.admin-topbar span,
.admin-section-head p,
.admin-kpi span,
.admin-system-card span,
.admin-denied-card p {
  display: block;
}
.admin-brand strong { font-size: 20px; }
.admin-brand small { color: #95a7b7; margin-top: 4px; }
.admin-nav { display: grid; gap: 8px; }
.admin-nav button {
  border: 0;
  border-radius: 12px;
  padding: 13px 14px;
  background: transparent;
  color: #c7d3dd;
  text-align: right;
  cursor: pointer;
}
.admin-nav button.active,
.admin-nav button:hover {
  background: rgba(255,255,255,.08);
  color: #fff;
}
.admin-main {
  min-width: 0;
  display: grid;
  gap: 16px;
}
.admin-topbar {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: center;
  padding: 18px 22px;
  border-radius: 18px;
  background: linear-gradient(135deg, #102331, #183347);
  color: white;
  box-shadow: 0 18px 42px rgba(9, 18, 28, .16);
}
.admin-topbar span { font-size: 12px; color: #a8bfd0; margin-bottom: 4px; }
.admin-topbar strong { font-size: 20px; }
.admin-content {
  padding: 22px;
  border-radius: 18px;
  background: #0f1720;
  color: #e6eef4;
  box-shadow: 0 18px 42px rgba(9, 18, 28, .14);
}
.admin-content h1,
.admin-content h2,
.admin-content th,
.admin-content td,
.admin-content .muted { color: inherit; }
.admin-content .muted { color: #91a3b3; }
.admin-section-head { margin-bottom: 16px; }
.admin-section-head h1 { margin: 0 0 6px; font-size: 28px; color: #fff; }
.admin-section-head p { margin: 0; color: #91a3b3; line-height: 1.6; }
.admin-kpi-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
}
.admin-kpi {
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 16px;
  padding: 18px;
  background: linear-gradient(180deg, rgba(18,28,39,.98), rgba(14,22,32,.98));
  color: #fff;
  text-align: right;
  cursor: pointer;
  box-shadow: inset 0 1px 0 rgba(255,255,255,.03);
}
.admin-kpi span { color: #9db1c2; font-size: 13px; margin-bottom: 8px; }
.admin-kpi strong { display: block; font-size: 30px; color: #7ad3b3; }
.admin-system-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}
.admin-system-card {
  padding: 18px;
  border-radius: 16px;
  border: 1px solid rgba(255,255,255,.08);
  background: rgba(255,255,255,.03);
}
.admin-system-card strong {
  display: block;
  margin-bottom: 8px;
  color: #fff;
}
.admin-system-card span { color: #9db1c2; line-height: 1.6; }
.admin-denied {
  min-height: 58vh;
  display: grid;
  place-items: center;
}
.admin-denied-card {
  width: min(520px, 100%);
  padding: 32px;
  border-radius: 20px;
  background: #0f1720;
  color: #e6eef4;
  text-align: center;
  box-shadow: 0 18px 42px rgba(9, 18, 28, .18);
}
.admin-denied-card span {
  display: inline-grid;
  place-items: center;
  width: 64px;
  height: 64px;
  margin-bottom: 12px;
  border-radius: 50%;
  background: rgba(122,211,179,.12);
  color: #7ad3b3;
  font-size: 20px;
  font-weight: 800;
}
.admin-denied-card h1 { margin: 0 0 10px; font-size: 28px; }
.admin-denied-card p { margin: 0 0 18px; color: #91a3b3; }
.admin-approval-table thead th,
.admin-approval-table tbody td { color: #e6eef4; border-bottom-color: rgba(255,255,255,.08); }
.admin-approval-table .btn,
.admin-content .btn { min-height: 38px; }
.admin-thumb { background: rgba(255,255,255,.05); }

.gallery-overlay {
  position: fixed;
  inset: 0;
  z-index: 80;
  background: rgba(8, 22, 17, .94);
  display: grid;
  place-items: center;
  padding: 24px;
}
.gallery-close {
  position: fixed;
  top: calc(18px + env(safe-area-inset-top));
  left: 18px;
  width: 42px;
  height: 42px;
  border: 0;
  border-radius: 50%;
  background: white;
  color: var(--text);
  font-size: 28px;
  z-index: 3;
}
.gallery-nav {
  position: fixed;
  top: 50%;
  transform: translateY(-50%);
  width: 52px;
  height: 52px;
  border: 0;
  border-radius: 50%;
  background: rgba(255,255,255,.95);
  color: var(--primary);
  font-size: 34px;
  z-index: 3;
}
.gallery-prev { right: 24px; }
.gallery-next { left: 24px; }
.gallery-overlay .gallery-nav:only-child {
  display: none;
}
.gallery-overlay figure {
  margin: 0;
  width: 100%;
  height: 100%;
  display: grid;
  place-items: center;
  color: white;
}
.gallery-overlay img {
  max-width: min(1100px, 92vw);
  max-height: 84vh;
  object-fit: contain;
}
.gallery-overlay figcaption {
  align-self: start;
  color: white;
}

.site-footer {
  max-width: 1240px;
  width: 100%;
  margin: 0 auto 24px;
  padding: 24px 20px 88px;
  display: grid;
  grid-template-columns: 1.3fr repeat(3, minmax(0, 1fr));
  gap: 20px;
  color: var(--muted);
}
.site-footer h4 { margin: 0 0 10px; color: var(--text); }
.footer-brand p { max-width: 360px; line-height: 1.7; }
.footer-links { display: grid; gap: 8px; }
.mobile-tabs { display: none; }
.modal {
  position: fixed;
  inset: 0;
  display: none;
  place-items: center;
  background: rgba(8, 22, 17, .48);
  z-index: 50;
  padding: 18px;
}
.modal.open { display: grid; }
.modal-card { width: min(430px, 100%); background: white; border-radius: 18px; padding: 22px; position: relative; box-shadow: var(--shadow); }
.modal-close { position: absolute; left: 14px; top: 12px; border: 0; background: transparent; font-size: 26px; cursor: pointer; }
.tabs, .detail-tabs { display: flex; background: var(--surface-2); padding: 4px; border-radius: 12px; margin-bottom: 16px; gap: 6px; overflow-x: auto; }
.tab { flex: 1; border: 0; border-radius: 9px; background: transparent; min-height: 40px; cursor: pointer; }
.tab.active { background: white; color: var(--primary); box-shadow: 0 6px 16px rgba(18,42,30,.08); }
.detail-tabs button {
  flex: 1 0 auto;
  min-height: 40px;
  border: 0;
  border-radius: 9px;
  background: transparent;
  cursor: pointer;
  color: var(--muted);
}
.detail-tabs button.active {
  background: white;
  color: var(--primary);
  box-shadow: 0 6px 16px rgba(18,42,30,.08);
}
.toast {
  position: fixed;
  bottom: 24px;
  left: 24px;
  background: #11261f;
  color: white;
  padding: 13px 16px;
  border-radius: 12px;
  box-shadow: var(--shadow);
  transform: translateY(90px);
  transition: .2s ease;
  z-index: 70;
  white-space: pre-line;
}
.toast.show { transform: translateY(0); }

.mobile-flow,
.mobile-results-head {
  display: none;
}

@media (min-width: 921px) and (max-width: 1100px) {
  .home-layout {
    grid-template-columns: 220px minmax(0, 1fr);
    grid-template-areas:
      "categories main"
      "ads ads";
    gap: 20px;
  }
  .ad-column {
    grid-column: 1 / -1;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .showcase-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
  .listing-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 920px) {
  .real-estate-detail {
    padding: 14px 12px 86px;
  }
  .real-estate-title {
    font-size: 21px;
  }
  .real-estate-topbar {
    justify-content: flex-start;
  }
  .real-estate-layout {
    grid-template-columns: 1fr;
  }
  .real-estate-main-photo {
    height: 300px;
  }
  .real-estate-photo-strip {
    grid-template-columns: repeat(4, 1fr);
  }
  .real-estate-photo-strip button {
    height: 70px;
  }
  .real-estate-info,
  .real-estate-seller {
    padding: 14px;
    border: 1px solid var(--line);
    background: #fff;
  }
  .real-estate-spec-row {
    grid-template-columns: minmax(98px, .72fr) minmax(0, 1fr);
  }
  .real-estate-tabs {
    margin-top: 22px;
    overflow-x: auto;
  }
  .real-estate-tabs button {
    flex: 0 0 auto;
    padding: 0 14px;
  }
  .real-estate-feature-grid {
    grid-template-columns: 1fr;
  }
  .vehicle-detail-page {
    padding: 14px 12px 86px;
  }
  .vehicle-detail-heading {
    display: grid;
  }
  .vehicle-detail-heading h1 {
    font-size: 21px;
  }
  .vehicle-detail-layout {
    grid-template-columns: 1fr;
  }
  .vehicle-main-photo {
    height: 300px;
  }
  .vehicle-thumbs {
    grid-template-columns: repeat(4, 1fr);
  }
  .vehicle-thumbs button {
    height: 70px;
  }
  .vehicle-detail-info,
  .vehicle-seller-card {
    padding: 14px;
    border: 1px solid var(--line);
    background: #fff;
  }
  .vehicle-spec-row {
    grid-template-columns: minmax(105px, .75fr) minmax(0, 1fr);
  }
  .vehicle-tabs {
    overflow-x: auto;
  }
  .vehicle-tabs button {
    flex: 0 0 auto;
    padding: 0 14px;
  }
  .published-preview-layout,
  .published-preview-meta {
    grid-template-columns: 1fr;
  }
  .published-preview-media {
    min-height: 220px;
  }
  .published-preview-actions {
    display: grid;
  }
  .published-preview-actions .btn {
    width: 100%;
  }
  body {
    padding-bottom: calc(76px + env(safe-area-inset-bottom));
  }
  .site-header {
    top: 0;
  }
  .header-inner { min-height: 68px; }
  .brand {
    min-width: auto;
    gap: 8px;
  }
  .brand-logo {
    height: 55px;
    max-width: 150px;
  }
  .brand-header {
    height: 28px;
    max-width: 110px;
    opacity: 0.96;
  }
  .header-search {
    order: 3;
    grid-column: 1 / -1;
    max-width: none;
    width: 100%;
    grid-template-columns: 1fr;
    padding-bottom: 12px;
  }
  .main-nav {
    position: fixed;
    top: 68px;
    right: 14px;
    left: 14px;
    display: none;
    flex-direction: column;
    align-items: stretch;
    background: white;
    border: 1px solid var(--line);
    border-radius: 14px;
    padding: 12px;
    box-shadow: var(--shadow);
    z-index: 70;
  }
  .main-nav.open { display: flex; }
  .icon-btn { display: grid; place-items: center; }
  .header-actions .btn { display: none; }
  .user-menu { display: none; }
  .hero h1,
  .hero-title,
  .headline {
    font-size: clamp(30px, 7vw, 44px) !important;
    line-height: 1.35 !important;
  }
  .brand-logo,
  .brand-header,
  header img {
    max-height: 42px !important;
    max-width: 160px !important;
    object-fit: contain;
  }
  .app-shell {
    padding: 14px 12px calc(96px + env(safe-area-inset-bottom));
  }
  .mobile-flow {
    display: block;
  }
  .mobile-flow-header {
    position: sticky;
    top: 68px;
    z-index: 15;
    display: grid;
    grid-template-columns: 44px 1fr 44px;
    align-items: center;
    min-height: 54px;
    margin: -14px -12px 14px;
    padding: 0 12px;
    background: rgba(255,255,255,.96);
    border-bottom: 1px solid var(--line);
    backdrop-filter: blur(14px);
  }
  .mobile-flow-header a {
    width: 38px;
    height: 38px;
    display: grid;
    place-items: center;
    border-radius: 12px;
    background: var(--surface-2);
    color: var(--primary);
    font-size: 28px;
    line-height: 1;
  }
  .mobile-flow-header strong {
    text-align: center;
    font-size: 18px;
  }
  .mobile-search-box {
    margin-bottom: 12px;
  }
  .mobile-search-box input {
    min-height: 48px;
    border-radius: 14px;
    background: white;
  }
  .mobile-category-list {
    display: grid;
    gap: 9px;
  }
  .mobile-category-row {
    min-height: 66px;
    display: grid;
    grid-template-columns: 42px minmax(0, 1fr) auto 24px;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
    background: white;
    border: 1px solid var(--line);
    border-radius: 14px;
    box-shadow: 0 8px 22px rgba(18,42,30,.05);
  }
  .mobile-row-icon {
    width: 38px;
    height: 38px;
    display: grid;
    place-items: center;
    border-radius: 12px;
    background: var(--surface-2);
    font-size: 21px;
  }
  .mobile-row-main {
    min-width: 0;
    display: grid;
    gap: 3px;
  }
  .mobile-row-main b {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }
  .mobile-row-main small,
  .mobile-row-count {
    color: var(--muted);
    font-size: 12px;
  }
  .mobile-row-arrow {
    color: var(--primary);
    font-size: 24px;
    line-height: 1;
  }
  .mobile-results-head {
    display: block;
    margin-bottom: 12px;
  }
  .mobile-results-head p {
    margin: 0 0 10px;
    color: var(--muted);
    text-align: center;
  }
  .mobile-filter-bar {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 8px;
  }
  .mobile-filter-bar button {
    min-height: 38px;
    border: 1px solid var(--line);
    border-radius: 12px;
    background: white;
    color: var(--primary);
  }
  .mobile-results-list {
    display: grid;
    grid-template-columns: 1fr !important;
    gap: 10px;
  }
  .mobile-results-list .listing-card {
    display: none;
  }
  .mobile-listing-card {
    position: relative;
    min-width: 0;
    background: white;
    border: 1px solid var(--line);
    border-radius: 14px;
    overflow: hidden;
    box-shadow: 0 8px 22px rgba(18,42,30,.06);
  }
  .detail-layout {
    display: none;
  }
  .mobile-detail {
    display: block;
    margin: -14px -12px 0;
    padding: 0 12px calc(154px + env(safe-area-inset-bottom));
  }
  .mobile-detail-header {
    position: sticky;
    top: 68px;
    z-index: 18;
    min-height: 54px;
    display: grid;
    grid-template-columns: 44px 1fr auto;
    align-items: center;
    gap: 8px;
    margin: 0 -12px 12px;
    padding: 0 12px;
    background: rgba(255,255,255,.97);
    border-bottom: 1px solid var(--line);
    backdrop-filter: blur(14px);
  }
  .mobile-detail-header > a,
  .mobile-icon-action {
    width: 38px;
    height: 38px;
    border: 0;
    border-radius: 12px;
    display: inline-grid;
    place-items: center;
    background: var(--surface-2);
    color: var(--primary);
    font-size: 22px;
  }
  .mobile-detail-header > a {
    font-size: 28px;
    line-height: 1;
  }
  .mobile-detail-header strong {
    text-align: center;
    font-size: 17px;
  }
  .mobile-detail-header div {
    display: flex;
    gap: 6px;
  }
  .mobile-detail-title {
    margin: 0 0 12px;
    font-size: 20px;
    line-height: 1.45;
    overflow-wrap: anywhere;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
  }
  .mobile-gallery {
    position: relative;
    width: 100%;
    aspect-ratio: 4 / 3;
    display: grid;
    place-items: center;
    overflow: hidden;
    border-radius: 16px;
    background: linear-gradient(135deg, #dfe9e3, #f7faf8);
    color: var(--muted);
  }
  .mobile-gallery img {
    width: 100%;
    height: 100%;
    object-fit: cover;
  }
  .photo-count {
    position: absolute;
    left: 12px;
    bottom: 12px;
    padding: 5px 10px;
    border-radius: 999px;
    background: rgba(17,38,31,.76);
    color: white;
    font-size: 12px;
  }
  .mobile-seller-box,
  .mobile-breadcrumb,
  .mobile-tab-panel {
    margin-top: 12px;
    padding: 14px;
    background: white;
    border: 1px solid var(--line);
    border-radius: 14px;
    box-shadow: 0 8px 22px rgba(18,42,30,.05);
  }
  .mobile-seller-box > div {
    display: flex;
    justify-content: space-between;
    gap: 10px;
    align-items: center;
  }
  .seller-name {
    color: var(--primary);
    font-weight: 800;
  }
  .seller-badge {
    padding: 5px 9px;
    border-radius: 999px;
    background: var(--surface-2);
    color: var(--primary);
    font-size: 12px;
  }
  .mobile-seller-box p {
    margin: 8px 0 0;
    color: var(--muted);
  }
  .mobile-breadcrumb {
    display: flex;
    gap: 6px;
    overflow-x: auto;
    white-space: nowrap;
    color: var(--muted);
    font-size: 12px;
  }
  .mobile-breadcrumb b {
    color: var(--primary);
  }
  .mobile-detail-tabs {
    position: sticky;
    top: 122px;
    z-index: 12;
    display: flex;
    gap: 8px;
    margin: 12px 0 0;
    padding: 8px 0;
    width: 100%;
    box-sizing: border-box;
    overflow-x: auto;
    background: var(--bg);
  }
  .mobile-detail-tabs button {
    flex: 1 1 0;
    min-width: 0;
    min-height: 40px;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: white;
    color: var(--muted);
    padding: 0 10px;
  }
  .mobile-detail-tabs button.active {
    background: var(--primary);
    color: white;
    border-color: var(--primary);
  }
  .mobile-tab-panel {
    display: none;
  }
  .mobile-tab-panel.active {
    display: block;
  }
  .mobile-info-table {
    display: grid;
  }
  .mobile-info-table div {
    min-height: 44px;
    display: flex;
    justify-content: space-between;
    gap: 12px;
    padding: 10px 0;
    border-bottom: 1px solid var(--line);
  }
  .mobile-info-table div:last-child {
    border-bottom: 0;
  }
  .mobile-info-table span {
    color: var(--muted);
  }
  .mobile-info-table b {
    text-align: left;
    overflow-wrap: anywhere;
  }
  .mobile-info-table .info-price {
    color: var(--primary);
    font-size: 18px;
  }
  .mobile-info-table .info-id {
    color: var(--accent);
  }
  .mobile-description {
    margin: 0;
    line-height: 1.9;
    color: #26362d;
    overflow-wrap: anywhere;
  }
  .location-summary {
    margin-bottom: 12px;
    color: var(--text);
  }
  .map-placeholder {
    min-height: 280px;
  }
  .leaflet-map {
    min-height: 280px;
    height: 320px;
  }
  .leaflet-map-go {
    top: 10px;
    right: 10px;
    font-size: 13px;
  }
.map-placeholder {
  width: 100%;
  min-height: 320px;
  height: 360px;
  border: 1px dashed #aac9bc;
  border-radius: 14px;
  background: var(--surface-2);
  color: var(--muted);
  overflow: hidden;
}
.map-placeholder-desktop {
  min-height: 380px;
  height: 420px;
  width: 100%;
  display: block;
}
.leaflet-map-wrap {
  display: grid;
  gap: 10px;
  height: 100%;
  grid-template-rows: minmax(0, 1fr) auto;
}
.leaflet-map-shell {
  position: relative;
  width: 100%;
  height: 100%;
}
.leaflet-map {
  width: 100%;
  min-height: 320px;
  height: 100%;
  border-radius: 14px;
  overflow: hidden;
  background: var(--surface-2);
}
.leaflet-map-go {
  position: absolute;
  top: 12px;
  right: 12px;
  z-index: 2;
  min-height: 36px;
  padding: 0 12px;
  border-radius: 999px;
  background: rgba(255,255,255,.94);
  border: 1px solid rgba(0,0,0,.08);
  color: var(--primary);
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  box-shadow: 0 8px 20px rgba(18,42,30,.12);
}
.leaflet-map-note {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.6;
}
  .mobile-contact-bar {
    position: fixed;
    right: 0;
    left: 0;
    bottom: calc(58px + env(safe-area-inset-bottom));
    z-index: 28;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
    padding: 10px 12px;
    background: rgba(255,255,255,.96);
    border-top: 1px solid var(--line);
    box-shadow: 0 -10px 28px rgba(18,42,30,.08);
  }
  .mobile-contact-bar a,
  .mobile-contact-bar button {
    min-height: 44px;
    border: 0;
    border-radius: 12px;
    display: grid;
    place-items: center;
    background: var(--primary);
    color: white;
  }
  .mobile-contact-bar button {
    background: var(--surface-2);
    color: var(--primary);
  }
  .floating-contact {
    position: fixed;
    left: 14px;
    bottom: calc(124px + env(safe-area-inset-bottom));
    z-index: 29;
    width: 46px;
    height: 46px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    background: var(--primary);
    color: white;
    box-shadow: var(--shadow);
  }
  .mobile-listing-link {
    display: grid;
    grid-template-columns: 118px minmax(0, 1fr);
    gap: 12px;
    padding: 10px;
  }
  .mobile-listing-image {
    width: 118px;
    height: 94px;
    display: grid;
    place-items: center;
    overflow: hidden;
    border-radius: 12px;
    background: linear-gradient(135deg, #dfe9e3, #f7faf8);
    color: var(--muted);
    font-size: 12px;
  }
  .mobile-listing-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
  }
  .mobile-listing-body {
    min-width: 0;
    display: grid;
    align-content: start;
    gap: 5px;
    padding-left: 34px;
  }
  .mobile-listing-body h3 {
    margin: 0;
    font-size: 15px;
    line-height: 1.45;
    overflow-wrap: anywhere;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
  }
  .mobile-location {
    color: var(--muted);
    font-size: 12px;
  }
  .mobile-vehicle-meta {
    min-width: 0;
    display: flex;
    gap: 5px;
    overflow: hidden;
  }
  .mobile-price {
    color: var(--primary);
    font-weight: 800;
    font-size: 17px;
  }
  .mobile-fav {
    left: 10px;
    top: 10px;
    width: 34px;
    height: 34px;
  }
  .hero, .layout, .detail-layout, .dashboard { grid-template-columns: 1fr; }
  .admin-shell {
    grid-template-columns: 1fr;
  }
  .admin-sidebar {
    position: static;
  }
  .admin-topbar {
    align-items: flex-start;
    flex-direction: column;
  }
  .admin-kpi-grid,
  .admin-system-grid {
    grid-template-columns: 1fr;
  }
  .admin-content {
    padding: 18px;
  }
  .filter-grid-2 {
    grid-template-columns: 1fr;
  }
  .home-layout {
    display: flex;
    flex-direction: column;
    grid-template-areas:
      "categories"
      "main"
      "ads";
  }
  .category-rail,
  .ad-column,
  .home-main,
  .card,
  .ad-box {
    width: 100%;
    max-width: 100%;
  }
  .ad-column {
    display: grid;
    grid-template-columns: 1fr;
  }
  .category-rail { order: 1; }
  .home-main { order: 2; }
  .ad-column { order: 3; }
  .top-banner {
    align-items: flex-start;
    flex-direction: column;
    min-height: auto;
  }
  .top-banner strong { font-size: 18px; }
  .category-rail { order: 1; }
  .home-main { order: 2; }
  .ad-column { grid-template-columns: 1fr; order: 3; }
  .category-row > a { justify-content: space-between; }
  .submenu {
    position: static;
    display: none;
    min-width: 0;
    box-shadow: none;
    border: 0;
    border-radius: 10px;
    background: var(--surface-2);
    margin: 4px 38px 8px 0;
  }
  .category-row:hover .submenu { display: grid; }
  .hero-main { padding: 24px; min-height: auto; }
  .hero h1 { font-size: 31px; }
  .search-box, .hero-search { grid-template-columns: 1fr; }
  .category-grid, .listing-grid, .city-grid, .stats-grid, .trust-row, .showcase-grid { grid-template-columns: 1fr; }
  .trust-row { order: 3; }
  .showcase-grid { order: 2; }
  .filters { display: none; position: static; }
  .filters.open {
    position: fixed;
    inset: 0;
    z-index: 60;
    display: block;
    overflow-y: auto;
    padding: 82px 14px calc(100px + env(safe-area-inset-bottom));
    border-radius: 0;
    background: rgba(245,247,244,.98);
  }
  .filters.open::before {
    content: "تصفية الإعلانات";
    position: fixed;
    top: 0;
    right: 0;
    left: 0;
    min-height: 58px;
    display: grid;
    place-items: center;
    background: white;
    border-bottom: 1px solid var(--line);
    color: var(--text);
    font-weight: 800;
  }
  .desktop-add-shell, .desktop-add-content {
    padding: 0;
    border: 0;
    box-shadow: none;
    background: transparent;
  }
  .desktop-add-shell {
    padding-inline: 12px;
  }
  .desktop-add-shell .panel {
    padding: 16px;
  }
  .desktop-add-form {
    width: 100%;
  }
  .desktop-form-topbar {
    flex-direction: column;
    align-items: stretch;
  }
  .desktop-form-path span {
    max-width: none;
    white-space: normal;
  }
  .desktop-stepper,
  .desktop-category-grid,
  .desktop-category-flow {
    grid-template-columns: 1fr;
  }
  .spare-category-board {
    grid-template-columns: 1fr;
    border: 0;
    gap: 10px;
    overflow: visible;
  }
  .spare-category-column {
    min-height: 0;
    border: 1px solid var(--line);
  }
  .spare-category-column:last-child {
    border-left: 1px solid var(--line);
  }
  .spare-continue-panel,
  .spare-add-form {
    grid-template-columns: 1fr;
  }
  .listing-form-map {
    min-height: 240px;
  }
  .desktop-add-form input[type="file"] {
    width: 100%;
    max-width: 100%;
    display: block;
    overflow: hidden;
  }
  .desktop-add-form input,
  .desktop-add-form select,
  .desktop-add-form textarea,
  .desktop-add-form button {
    min-width: 0;
  }
  .car-paint-table-head,
  .car-paint-row {
    grid-template-columns: 150px repeat(4, 68px) 38px;
    gap: 5px;
    min-width: 480px;
  }
  .car-paint-row {
    padding: 5px 6px;
  }
  .car-paint-row strong {
    margin-bottom: 0;
  }
  .car-paint-row label {
    min-height: 22px;
  }
  .car-paint-detail {
    justify-self: end;
  }
  .equipment-grid {
    grid-template-columns: 1fr;
  }
  .equipment-options {
    grid-template-columns: repeat(auto-fit, minmax(105px, 1fr));
  }
  .mobile-filter { display: inline-flex; }
  .detail-desktop { display: none; }
  .detail-layout .seller-card { position: static; }
  .form-grid { grid-template-columns: 1fr; }
  .gallery-main { height: 280px; }
  .site-footer { display: grid; grid-template-columns: 1fr; }
  .mobile-tabs {
    position: fixed;
    inset-inline: 0;
    bottom: 0;
    z-index: 30;
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    background: white;
    border-top: 1px solid var(--line);
    box-shadow: 0 -10px 30px rgba(18,42,30,.08);
    padding-bottom: env(safe-area-inset-bottom);
    width: 100vw;
    max-width: 100vw;
    box-sizing: border-box;
  }
  .mobile-tabs a {
    min-height: 58px;
    display: grid;
    place-items: center;
    text-align: center;
    padding: 10px 4px;
    color: var(--muted);
    font-size: 12px;
  }
  .mobile-tabs .mobile-add-tab {
    position: relative;
    color: var(--primary);
    font-weight: 800;
  }
  .mobile-tabs .mobile-add-tab::before {
    content: "+";
    width: 42px;
    height: 42px;
    display: grid;
    place-items: center;
    margin-bottom: -2px;
    border-radius: 50%;
    background: var(--primary);
    color: white;
    font-size: 28px;
    line-height: 1;
    box-shadow: 0 10px 24px rgba(15, 107, 85, .24);
  }
  .modal {
    padding: 12px;
    align-items: end;
    width: 100vw;
    max-width: 100vw;
    left: 0;
    right: 0;
  }
  .modal-card {
    width: min(calc(100vw - 24px), 430px);
    max-height: calc(100vh - 24px);
    overflow: auto;
  }
  html, body {
    overflow-x: hidden;
  }
}

@media (max-width: 480px) {
  body {
    padding-bottom: calc(90px + env(safe-area-inset-bottom));
  }
  .hero h1,
  .hero-title,
  .headline {
    font-size: clamp(28px, 8vw, 42px) !important;
    line-height: 1.35 !important;
  }
  .brand,
  .site-header .brand {
    min-width: 0;
    gap: 8px;
  }
  .brand-logo,
  .brand-header,
  header img {
    max-height: 42px !important;
    max-width: 160px !important;
    width: auto !important;
    object-fit: contain;
  }
  .brand-logo {
    height: 58px !important;
    max-width: 150px !important;
  }
  .brand-header {
    height: 30px !important;
    max-width: 112px !important;
  }
  .header-inner {
    padding-inline: 10px;
    gap: 10px;
  }
  .header-search input,
  .header-search select,
  .header-search button {
    min-height: 46px;
  }
  .app-shell {
    padding-inline: 10px;
    padding-bottom: calc(104px + env(safe-area-inset-bottom));
  }
  .home-layout,
  .hero,
  .layout,
  .detail-layout,
  .dashboard {
    display: grid;
    grid-template-columns: 1fr;
  }
  .category-rail,
  .ad-column,
  .home-main,
  .card,
  .ad-box,
  .panel,
  .listing-card {
    width: 100%;
    max-width: 100%;
  }
  .ad-column {
    display: grid;
    grid-template-columns: 1fr;
    gap: 12px;
  }
  .ad-box {
    min-height: 0;
  }
  .mobile-tabs {
    z-index: 40;
  }
  .main-nav {
    z-index: 80;
  }
  .hero-main {
    padding: 20px;
  }
  .hero p {
    font-size: 14px;
    line-height: 1.75;
  }
  .search-box,
  .hero-search {
    grid-template-columns: 1fr;
  }
  .mobile-detail-header strong,
  .mobile-flow-header strong {
    font-size: 16px;
  }
  .mobile-listing-body {
    padding-left: 28px;
  }
}
