:root {
  --primary: #1d4ed8;
  --primary-dark: #1e3a8a;
  --primary-light: #3b82f6;
  --dark: #0f172a;
  --gray-900: #111827;
  --gray-700: #374151;
  --gray-500: #6b7280;
  --gray-300: #d1d5db;
  --gray-200: #e5e7eb;
  --gray-100: #f3f4f6;
  --gray-50: #f9fafb;
  --white: #ffffff;
  --accent: #f59e0b;
  --success: #10b981;
  --danger: #ef4444;
  --shadow-sm: 0 1px 2px rgba(0,0,0,0.05);
  --shadow: 0 4px 6px -1px rgba(0,0,0,0.1), 0 2px 4px -1px rgba(0,0,0,0.06);
  --shadow-lg: 0 10px 15px -3px rgba(0,0,0,0.1), 0 4px 6px -2px rgba(0,0,0,0.05);
  --radius: 10px;
  --radius-sm: 6px;
  --transition: all 0.2s ease;
}

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

html { scroll-behavior: smooth; }

body {
  font-family: 'Segoe UI', system-ui, -apple-system, Roboto, sans-serif;
  color: var(--gray-900);
  background: var(--white);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

a { color: var(--primary); text-decoration: none; transition: var(--transition); }
a:hover { color: var(--primary-dark); }

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

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

/* ===== TOP BAR ===== */
.topbar {
  background: var(--dark);
  color: var(--gray-200);
  padding: 8px 0;
  font-size: 13px;
}
.topbar .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
}
.topbar a { color: var(--gray-200); }
.topbar a:hover { color: var(--white); }
.topbar-info { display: flex; gap: 22px; flex-wrap: wrap; }
.topbar-info span { display: inline-flex; align-items: center; gap: 6px; }

/* ===== HEADER ===== */
.header {
  background: var(--white);
  box-shadow: var(--shadow-sm);
  position: sticky;
  top: 0;
  z-index: 100;
  border-bottom: 3px solid var(--primary);
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 0;
  gap: 20px;
}
.logo { display: flex; align-items: center; gap: 10px; }
.logo img { height: 60px; width: auto; }

.main-nav { display: flex; align-items: center; gap: 4px; }
.main-nav a {
  color: var(--gray-700);
  font-weight: 600;
  padding: 10px 16px;
  border-radius: var(--radius-sm);
  font-size: 14px;
  transition: var(--transition);
}
.main-nav a:hover, .main-nav a.active {
  background: var(--gray-100);
  color: var(--primary);
}
.menu-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
}
.menu-toggle span {
  display: block;
  width: 24px;
  height: 3px;
  background: var(--gray-900);
  margin: 5px 0;
  border-radius: 2px;
  transition: var(--transition);
}

.btn-call {
  background: var(--primary);
  color: var(--white) !important;
  padding: 10px 18px !important;
  border-radius: var(--radius-sm);
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.btn-call:hover { background: var(--primary-dark); color: var(--white) !important; }

/* ===== HERO ===== */
.hero {
  background: linear-gradient(135deg, var(--primary-dark) 0%, var(--primary) 100%);
  color: var(--white);
  padding: 60px 0 80px;
  position: relative;
  overflow: hidden;
}
.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 80% 20%, rgba(96,165,250,0.4), transparent 50%);
}
.hero-inner {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 40px;
  align-items: center;
  position: relative;
}
.hero h1 {
  font-size: 44px;
  line-height: 1.15;
  font-weight: 900;
  margin-bottom: 18px;
  letter-spacing: -0.5px;
}
.hero h1 span { color: #fbbf24; }
.hero p {
  font-size: 17px;
  opacity: 0.95;
  margin-bottom: 28px;
  max-width: 540px;
}
.hero-actions { display: flex; gap: 12px; flex-wrap: wrap; }
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 28px;
  border-radius: var(--radius-sm);
  font-weight: 700;
  font-size: 15px;
  cursor: pointer;
  border: none;
  transition: var(--transition);
}
.btn-primary {
  background: var(--white);
  color: var(--primary-dark);
}
.btn-primary:hover { background: var(--gray-100); transform: translateY(-1px); }
.btn-outline {
  background: transparent;
  border: 2px solid var(--white);
  color: var(--white);
}
.btn-outline:hover { background: var(--white); color: var(--primary-dark); }

.hero-card {
  background: rgba(255,255,255,0.1);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255,255,255,0.2);
  border-radius: 16px;
  padding: 30px;
  text-align: center;
}
.hero-card-stat {
  font-size: 48px;
  font-weight: 900;
  color: #fbbf24;
  display: block;
  line-height: 1;
}
.hero-card-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
  margin-top: 8px;
}
.hero-card-row > div {
  background: rgba(255,255,255,0.08);
  padding: 18px 10px;
  border-radius: 10px;
}
.hero-card-row .num { font-size: 24px; font-weight: 900; color: var(--white); display: block; }
.hero-card-row .lbl { font-size: 12px; opacity: 0.85; }

/* ===== SECTIONS ===== */
.section { padding: 70px 0; }
.section-light { background: var(--gray-50); }
.section-title {
  text-align: center;
  margin-bottom: 40px;
}
.section-title h2 {
  font-size: 32px;
  font-weight: 900;
  color: var(--gray-900);
  margin-bottom: 8px;
}
.section-title p {
  color: var(--gray-500);
  font-size: 16px;
}
.section-title .accent {
  color: var(--primary);
  display: block;
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 2px;
  margin-bottom: 8px;
}

/* ===== CATEGORIES ===== */
.cat-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 16px;
}
.cat-card {
  background: var(--white);
  border: 2px solid var(--gray-200);
  border-radius: var(--radius);
  padding: 24px 16px;
  text-align: center;
  transition: var(--transition);
  cursor: pointer;
  text-decoration: none;
  color: var(--gray-900);
}
.cat-card:hover {
  border-color: var(--primary);
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
  color: var(--gray-900);
}
.cat-icon {
  width: 56px;
  height: 56px;
  margin: 0 auto 12px;
  background: var(--gray-100);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 26px;
  transition: var(--transition);
}
.cat-card:hover .cat-icon {
  background: var(--primary);
  color: var(--white);
}
.cat-card h3 { font-size: 14px; font-weight: 700; margin-bottom: 4px; }
.cat-card p { font-size: 12px; color: var(--gray-500); }

/* ===== LISTINGS ===== */
.listings-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 20px;
}
.listing-card {
  background: var(--white);
  border: 1px solid var(--gray-200);
  border-radius: var(--radius);
  overflow: hidden;
  transition: var(--transition);
  display: flex;
  flex-direction: column;
}
.listing-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
  border-color: var(--primary);
}
.listing-image {
  position: relative;
  background: var(--gray-100);
  aspect-ratio: 4/3;
  overflow: hidden;
}
.listing-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s;
}
.listing-card:hover .listing-image img { transform: scale(1.05); }
.listing-image-placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, var(--gray-100), var(--gray-200));
  color: var(--gray-500);
  font-size: 48px;
}
.featured-badge {
  position: absolute;
  top: 10px;
  left: 10px;
  background: var(--accent);
  color: var(--white);
  padding: 4px 10px;
  border-radius: 4px;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}
.condition-badge {
  position: absolute;
  top: 10px;
  right: 10px;
  background: var(--success);
  color: var(--white);
  padding: 4px 10px;
  border-radius: 4px;
  font-size: 11px;
  font-weight: 700;
}
.condition-badge.used { background: var(--gray-500); }

.listing-body { padding: 16px; flex: 1; display: flex; flex-direction: column; }
.listing-category {
  font-size: 11px;
  font-weight: 700;
  color: var(--primary);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 6px;
}
.listing-title {
  font-size: 16px;
  font-weight: 700;
  color: var(--gray-900);
  margin-bottom: 6px;
  line-height: 1.3;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.listing-meta {
  font-size: 13px;
  color: var(--gray-500);
  margin-bottom: 10px;
  display: -webkit-box;
  -webkit-line-clamp: 1;
  line-clamp: 1;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.stock-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: auto;
  padding-top: 10px;
  border-top: 1px solid var(--gray-100);
}
.stock-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: #ecfdf5;
  color: #047857;
  border: 1px solid #a7f3d0;
  padding: 5px 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
}
.stock-dot {
  width: 8px;
  height: 8px;
  background: var(--success);
  border-radius: 50%;
  display: inline-block;
  box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.2);
  animation: stockPulse 2s ease-in-out infinite;
}
@keyframes stockPulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.5; }
}
.stock-cta {
  font-size: 12px;
  font-weight: 700;
  color: var(--primary);
}
.stock-banner {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  background: #ecfdf5;
  border: 1px solid #a7f3d0;
  padding: 14px 18px;
  border-radius: var(--radius);
  margin-bottom: 20px;
}
.stock-banner .stock-pill {
  font-size: 13px;
  padding: 6px 14px;
}

/* ===== FILTER BAR ===== */
.filter-bar {
  background: var(--white);
  padding: 20px;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  margin-bottom: 30px;
  display: grid;
  grid-template-columns: 1fr auto auto;
  gap: 12px;
}
.filter-bar-search { grid-template-columns: 1fr auto; }
.filter-bar input, .filter-bar select {
  padding: 12px 14px;
  border: 1px solid var(--gray-300);
  border-radius: var(--radius-sm);
  font-size: 14px;
  background: var(--white);
}
.filter-bar input:focus, .filter-bar select:focus {
  outline: none;
  border-color: var(--primary);
}
.filter-bar button {
  background: var(--primary);
  color: var(--white);
  border: none;
  padding: 12px 24px;
  border-radius: var(--radius-sm);
  font-weight: 700;
  cursor: pointer;
}
.filter-bar button:hover { background: var(--primary-dark); }

/* ===== FEATURES ===== */
.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 24px;
}
.feature {
  text-align: center;
  padding: 30px 20px;
}
.feature-icon {
  width: 70px;
  height: 70px;
  margin: 0 auto 18px;
  background: var(--primary);
  color: var(--white);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 30px;
}
.feature h3 { font-size: 18px; font-weight: 700; margin-bottom: 8px; }
.feature p { color: var(--gray-500); font-size: 14px; }

/* ===== CTA BAR ===== */
.cta-bar {
  background: linear-gradient(135deg, var(--dark), var(--primary-dark));
  color: var(--white);
  padding: 50px 0;
  text-align: center;
}
.cta-bar h2 { font-size: 28px; font-weight: 900; margin-bottom: 10px; }
.cta-bar p { opacity: 0.9; margin-bottom: 24px; font-size: 16px; }
.cta-bar .btn { font-size: 17px; }

/* ===== FOOTER ===== */
.footer {
  background: var(--dark);
  color: var(--gray-300);
  padding: 50px 0 0;
}
.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1.2fr;
  gap: 40px;
  margin-bottom: 40px;
}
.footer h4 {
  color: var(--white);
  font-size: 15px;
  font-weight: 700;
  margin-bottom: 16px;
  text-transform: uppercase;
  letter-spacing: 1px;
}
.footer p, .footer a, .footer li { font-size: 14px; color: var(--gray-300); }
.footer a:hover { color: var(--white); }
.footer ul { list-style: none; }
.footer ul li { margin-bottom: 8px; }
.footer-logo img { height: 70px; margin-bottom: 14px; background: #fff; padding: 6px; border-radius: 8px; }
.footer-contact div {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin-bottom: 12px;
  font-size: 14px;
}
.footer-contact span:first-child {
  color: var(--primary-light);
  font-size: 18px;
  flex-shrink: 0;
  width: 22px;
}
.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.1);
  padding: 20px 0;
  text-align: center;
  font-size: 13px;
  color: var(--gray-500);
}

/* ===== LISTING DETAIL ===== */
.detail-wrap { display: grid; grid-template-columns: 1.3fr 1fr; gap: 36px; padding: 40px 0; }
.gallery-main {
  background: var(--gray-100);
  border-radius: var(--radius);
  aspect-ratio: 4/3;
  overflow: hidden;
  margin-bottom: 12px;
}
.gallery-main img { width: 100%; height: 100%; object-fit: contain; background: var(--white); }
.gallery-thumbs { display: flex; gap: 8px; flex-wrap: wrap; }
.gallery-thumbs img {
  width: 80px;
  height: 80px;
  object-fit: cover;
  border-radius: var(--radius-sm);
  border: 2px solid transparent;
  cursor: pointer;
  transition: var(--transition);
}
.gallery-thumbs img.active, .gallery-thumbs img:hover { border-color: var(--primary); }

.detail-info h1 { font-size: 28px; font-weight: 900; margin-bottom: 12px; }
.detail-meta-row {
  display: flex;
  gap: 20px;
  font-size: 14px;
  color: var(--gray-500);
  margin-bottom: 18px;
  padding-bottom: 18px;
  border-bottom: 1px solid var(--gray-200);
}
.detail-table {
  margin-bottom: 24px;
  border: 1px solid var(--gray-200);
  border-radius: var(--radius);
  overflow: hidden;
}
.detail-table .row {
  display: grid;
  grid-template-columns: 140px 1fr;
  border-bottom: 1px solid var(--gray-200);
}
.detail-table .row:last-child { border-bottom: none; }
.detail-table .row > div {
  padding: 12px 16px;
  font-size: 14px;
}
.detail-table .row .key {
  background: var(--gray-50);
  color: var(--gray-700);
  font-weight: 600;
}
.detail-description {
  background: var(--gray-50);
  padding: 20px;
  border-radius: var(--radius);
  margin-bottom: 24px;
  white-space: pre-wrap;
  font-size: 14px;
  line-height: 1.7;
  color: var(--gray-700);
}
.contact-box {
  background: var(--white);
  border: 2px solid var(--primary);
  border-radius: var(--radius);
  padding: 22px;
  text-align: center;
}
.contact-box h3 { font-size: 16px; margin-bottom: 14px; color: var(--gray-700); }
.contact-box .btn { width: 100%; justify-content: center; margin-bottom: 10px; }
.contact-box .btn:last-child { margin-bottom: 0; }
.btn-whatsapp { background: #25D366; color: var(--white); }
.btn-whatsapp:hover { background: #1da955; color: var(--white); }
.btn-phone { background: var(--primary); color: var(--white); }
.btn-phone:hover { background: var(--primary-dark); color: var(--white); }

/* ===== CONTACT PAGE ===== */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1.3fr;
  gap: 40px;
}
.contact-info-card {
  background: var(--white);
  border: 1px solid var(--gray-200);
  border-radius: var(--radius);
  padding: 30px;
}
.contact-info-card h3 {
  font-size: 20px;
  margin-bottom: 20px;
  color: var(--gray-900);
}
.contact-row {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  padding: 16px 0;
  border-bottom: 1px solid var(--gray-200);
}
.contact-row:last-child { border-bottom: none; }
.contact-icon {
  width: 42px;
  height: 42px;
  background: var(--gray-100);
  color: var(--primary);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  flex-shrink: 0;
}
.contact-row strong {
  display: block;
  font-size: 13px;
  color: var(--gray-500);
  margin-bottom: 4px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}
.contact-row span { font-size: 15px; color: var(--gray-900); }
.contact-row a { font-size: 15px; color: var(--gray-900); }
.contact-row a:hover { color: var(--primary); }

.map-frame {
  width: 100%;
  height: 100%;
  min-height: 400px;
  border: 0;
  border-radius: var(--radius);
}

/* ===== CATEGORY SIDEBAR ===== */
.cat-sidebar {
  background: var(--white);
  border: 1px solid var(--gray-200);
  border-radius: var(--radius);
  overflow: hidden;
  position: sticky;
  top: 84px;
}
.cat-sidebar-header {
  background: var(--primary);
  color: var(--white);
  padding: 14px 18px;
  font-weight: 700;
  font-size: 15px;
  display: flex;
  align-items: center;
  gap: 8px;
}
.cat-sidebar ul {
  list-style: none;
  max-height: 560px;
  overflow-y: auto;
}
.cat-sidebar li a {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 9px 14px;
  border-bottom: 1px solid var(--gray-100);
  color: var(--gray-700);
  font-size: 13px;
  font-weight: 500;
  transition: var(--transition);
}
.cat-sidebar li:last-child a { border-bottom: none; }
.cat-sidebar li a:hover {
  background: var(--gray-50);
  color: var(--primary);
  padding-left: 18px;
}
.cat-sidebar li a.active {
  background: var(--gray-100);
  color: var(--primary);
  font-weight: 700;
  border-left: 3px solid var(--primary);
}
.cat-sidebar .cat-icon-mini {
  width: 22px;
  flex-shrink: 0;
  font-size: 14px;
  text-align: center;
}
.cat-sidebar .cat-name {
  flex: 1;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.cat-sidebar .cat-count {
  background: var(--gray-100);
  color: var(--gray-500);
  font-size: 11px;
  font-weight: 700;
  padding: 1px 7px;
  border-radius: 10px;
  flex-shrink: 0;
}
.cat-sidebar li a:hover .cat-count,
.cat-sidebar li a.active .cat-count {
  background: var(--primary);
  color: var(--white);
}

.listings-layout {
  display: grid;
  grid-template-columns: 240px 1fr;
  gap: 26px;
  align-items: start;
}

@media (max-width: 900px) {
  .listings-layout { grid-template-columns: 1fr; }
  .cat-sidebar { position: static; }
  .cat-sidebar ul { max-height: 280px; }
}

/* ===== EMPTY ===== */
.empty-state {
  text-align: center;
  padding: 60px 20px;
  background: var(--gray-50);
  border-radius: var(--radius);
}
.empty-state-icon { font-size: 60px; margin-bottom: 16px; opacity: 0.4; }
.empty-state h3 { font-size: 20px; margin-bottom: 8px; color: var(--gray-700); }
.empty-state p { color: var(--gray-500); }

.loader {
  text-align: center;
  padding: 40px;
  color: var(--gray-500);
}

/* ===== WHATSAPP FAB ===== */
.whatsapp-fab {
  position: fixed;
  bottom: 22px;
  right: 22px;
  width: 58px;
  height: 58px;
  background: #25D366;
  color: var(--white);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 30px;
  box-shadow: 0 8px 24px rgba(37, 211, 102, 0.45);
  z-index: 90;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  text-decoration: none;
}
.whatsapp-fab:hover {
  transform: scale(1.08);
  color: var(--white);
  box-shadow: 0 10px 28px rgba(37, 211, 102, 0.6);
}
.whatsapp-fab::after {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: 50%;
  border: 3px solid #25D366;
  animation: fabRing 2.2s ease-out infinite;
}
@keyframes fabRing {
  0% { transform: scale(1); opacity: 0.6; }
  100% { transform: scale(1.6); opacity: 0; }
}

/* ===== NAV BACKDROP ===== */
.nav-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.55);
  backdrop-filter: blur(2px);
  z-index: 95;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
}
.nav-backdrop.show { opacity: 1; visibility: visible; }
body.nav-open { overflow: hidden; }

/* ===== STICKY DETAIL ACTION BAR (mobile) ===== */
.detail-action-bar {
  display: none;
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: var(--white);
  border-top: 1px solid var(--gray-200);
  padding: 10px 14px;
  padding-bottom: calc(10px + env(safe-area-inset-bottom, 0px));
  box-shadow: 0 -6px 22px rgba(0, 0, 0, 0.08);
  z-index: 80;
  gap: 10px;
}
.detail-action-bar .btn {
  flex: 1;
  justify-content: center;
  padding: 13px 8px;
  font-size: 14px;
  margin: 0;
}

/* ===== RESPONSIVE - 1024px (tablet landscape) ===== */
@media (max-width: 1024px) {
  .container { padding: 0 18px; }
  .hero h1 { font-size: 38px; }
  .section { padding: 60px 0; }
}

/* ===== RESPONSIVE - 900px (tablet) ===== */
@media (max-width: 900px) {
  .hero-inner { grid-template-columns: 1fr; gap: 28px; }
  .hero h1 { font-size: 32px; }
  .detail-wrap { grid-template-columns: 1fr; gap: 24px; padding: 24px 0; }
  .contact-grid { grid-template-columns: 1fr; gap: 24px; }
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 30px; }
  .filter-bar { grid-template-columns: 1fr; gap: 10px; }
  .filter-bar button { width: 100%; padding: 13px 24px; }
  .map-frame { min-height: 320px; }

  /* Sticky action bar visible on tablet & below */
  .detail-action-bar { display: flex; }
  body.detail-page { padding-bottom: 88px; }
  .detail-action-bar + .whatsapp-fab,
  body.detail-page .whatsapp-fab { bottom: 92px; }
}

/* ===== RESPONSIVE - 700px (mobile) ===== */
@media (max-width: 700px) {
  .container { padding: 0 14px; }

  /* Topbar - compact, single row */
  .topbar { padding: 6px 0; font-size: 11.5px; }
  .topbar .container { justify-content: center; gap: 14px; flex-wrap: nowrap; }
  .topbar-info { gap: 12px; font-size: 11.5px; }
  .topbar-info:last-child { display: none; }

  /* Header */
  .header-inner { padding: 10px 0; gap: 10px; }
  .logo img { height: 48px; }

  /* Hamburger toggle */
  .menu-toggle {
    display: block;
    position: relative;
    z-index: 110;
    width: 42px;
    height: 42px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
  }
  .menu-toggle span {
    margin: 3px 0;
    transition: transform 0.3s ease, opacity 0.2s ease;
  }
  .menu-toggle.open span:nth-child(1) { transform: translateY(8px) rotate(45deg); }
  .menu-toggle.open span:nth-child(2) { opacity: 0; transform: scaleX(0); }
  .menu-toggle.open span:nth-child(3) { transform: translateY(-8px) rotate(-45deg); }

  /* Slide-in nav from right */
  .main-nav {
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    width: 280px;
    max-width: 82vw;
    background: var(--white);
    flex-direction: column;
    align-items: stretch;
    padding: 78px 18px 28px;
    box-shadow: -16px 0 40px rgba(0, 0, 0, 0.18);
    transform: translateX(100%);
    transition: transform 0.32s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 100;
    gap: 4px;
    display: flex;
    overflow-y: auto;
  }
  .main-nav.open { transform: translateX(0); }
  .main-nav a {
    padding: 14px 16px;
    font-size: 15px;
    border-radius: 10px;
    font-weight: 600;
  }
  .main-nav a:hover, .main-nav a.active {
    background: var(--gray-100);
    color: var(--primary);
  }
  .main-nav .btn-call {
    margin-top: 12px;
    justify-content: center;
    text-align: center;
    padding: 14px 18px !important;
    font-size: 15px;
  }

  /* Hero */
  .hero { padding: 40px 0 56px; }
  .hero h1 { font-size: 26px; margin-bottom: 14px; line-height: 1.2; }
  .hero p { font-size: 15px; margin-bottom: 22px; }
  .hero-actions { gap: 10px; }
  .hero-actions .btn {
    flex: 1;
    min-width: 0;
    padding: 13px 14px;
    font-size: 14px;
    justify-content: center;
  }

  /* Sections */
  .section { padding: 44px 0; }
  .section-title { margin-bottom: 28px; }
  .section-title h2 { font-size: 22px; }
  .section-title p { font-size: 14px; }
  .section-title .accent { font-size: 11px; letter-spacing: 1.5px; }

  /* Categories grid */
  .cat-grid { grid-template-columns: repeat(2, 1fr); gap: 10px; }
  .cat-card { padding: 18px 10px; }
  .cat-icon { width: 44px; height: 44px; font-size: 22px; margin-bottom: 8px; }
  .cat-card h3 { font-size: 13px; line-height: 1.25; }
  .cat-card p { font-size: 11px; }

  /* Listings grid */
  .listings-grid { grid-template-columns: repeat(2, 1fr); gap: 12px; }
  .listing-body { padding: 12px; }
  .listing-category { font-size: 10px; }
  .listing-title { font-size: 14px; }
  .listing-meta { font-size: 12px; margin-bottom: 8px; }
  .stock-row { padding-top: 8px; gap: 6px; }
  .stock-pill { font-size: 10.5px; padding: 4px 8px; gap: 4px; }
  .stock-cta { font-size: 11px; }
  .featured-badge, .condition-badge { font-size: 10px; padding: 3px 8px; top: 8px; }
  .featured-badge { left: 8px; }
  .condition-badge { right: 8px; }

  /* Filter bar / forms */
  .filter-bar { padding: 14px; }
  .filter-bar input, .filter-bar select { font-size: 16px; padding: 13px 14px; }

  /* Listing detail */
  .detail-info h1 { font-size: 22px; margin-bottom: 10px; }
  .detail-meta-row { gap: 14px; font-size: 13px; padding-bottom: 14px; margin-bottom: 14px; }
  .detail-table .row { grid-template-columns: 110px 1fr; }
  .detail-table .row > div { padding: 10px 12px; font-size: 13px; }
  .detail-description { padding: 16px; font-size: 13.5px; }
  .gallery-thumbs {
    overflow-x: auto;
    flex-wrap: nowrap;
    padding-bottom: 4px;
    -webkit-overflow-scrolling: touch;
  }
  .gallery-thumbs::-webkit-scrollbar { height: 4px; }
  .gallery-thumbs::-webkit-scrollbar-thumb { background: var(--gray-300); border-radius: 4px; }
  .gallery-thumbs img { width: 64px; height: 64px; flex-shrink: 0; }
  .contact-box { padding: 18px; }

  /* Contact page */
  .contact-info-card { padding: 22px; }
  .map-frame { min-height: 280px; }

  /* CTA bar */
  .cta-bar { padding: 36px 0; }
  .cta-bar h2 { font-size: 22px; }
  .cta-bar p { font-size: 14px; margin-bottom: 18px; }
  .cta-bar .btn { padding: 14px 24px; font-size: 16px; }

  /* Category sidebar - become collapsible card */
  .cat-sidebar ul { max-height: 240px; }

  /* Footer */
  .footer { padding: 36px 0 0; }
  .footer-grid { grid-template-columns: 1fr; gap: 28px; margin-bottom: 28px; }
  .footer-logo img { height: 64px; }
  .footer h4 { font-size: 14px; margin-bottom: 12px; }
  .footer-bottom { padding: 16px 0; font-size: 12px; }

  /* WhatsApp FAB - smaller on mobile */
  .whatsapp-fab {
    bottom: 16px;
    right: 16px;
    width: 52px;
    height: 52px;
    font-size: 26px;
  }

  /* Empty / loader */
  .empty-state { padding: 40px 16px; }
  .empty-state-icon { font-size: 48px; }
}

/* ===== RESPONSIVE - 480px (small phone) ===== */
@media (max-width: 480px) {
  .hero h1 { font-size: 22px; }
  .hero p { font-size: 14px; }
  .hero-actions { flex-direction: column; }
  .hero-actions .btn { width: 100%; }

  .listings-grid { grid-template-columns: 1fr; gap: 14px; }
  .listing-image { aspect-ratio: 16/10; }
  .listing-title { font-size: 15px; }
  .listing-meta { font-size: 13px; }

  .cat-grid { gap: 8px; }

  .topbar-info { font-size: 10.5px; gap: 10px; }
  .topbar-info span:first-child { display: none; } /* hide first phone, keep mobile */

  /* Detail table - stacked rows on tiny screens */
  .detail-table .row { grid-template-columns: 1fr; }
  .detail-table .row .key {
    background: var(--gray-100);
    border-bottom: 1px solid var(--gray-200);
    font-size: 11px;
    padding: 7px 12px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
  }
  .detail-table .row .val { padding: 10px 12px; }

  .section-title h2 { font-size: 20px; }
  .section { padding: 36px 0; }

  /* Section-title accent badge tighter */
  .section-title .accent { letter-spacing: 1px; }
}
