/* ===== 123FoodNearMe — Clean White Theme with Inter ===== */

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

:root {
  --bg: #FFFFFF;
  --bg-card: #FFFFFF;
  --bg-elevated: #F5F5F7;
  --bg-surface: #F8F8FA;
  --border: #E5E5EA;
  --border-light: #D1D1D6;
  --primary: #DA3743;
  --primary-dark: #C22D38;
  --primary-light: #E8505A;
  --primary-glow: rgba(218,55,67,.08);
  --white: #FFFFFF;
  --text: #1D1D1F;
  --text-light: #6E6E73;
  --text-lighter: #AEAEB2;
  --accent: #1D1D1F;
  --red: #DA3743;
  --green: #34A853;
  --blue: #1A73E8;
  --shadow: 0 1px 3px rgba(0,0,0,.08), 0 1px 2px rgba(0,0,0,.06);
  --shadow-lg: 0 10px 25px rgba(0,0,0,.1);
  --shadow-gold: 0 4px 14px rgba(218,55,67,.12);
  --shadow-card: 0 1px 4px rgba(0,0,0,.05);
  --radius: 12px;
  --radius-sm: 8px;
  --radius-lg: 16px;
  --max-width: 1240px;
  --nav-height: 64px;
  --star-color: #FF8C00;
  --font-heading: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-body: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --transition: .2s ease;
}

html { scroll-behavior: smooth; }
body {
  font-family: var(--font-body);
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
a { color: var(--primary); text-decoration: none; transition: color var(--transition); }
a:hover { color: var(--primary-dark); }
img { max-width: 100%; display: block; }
button { cursor: pointer; font-family: inherit; }
input, select, textarea { font-family: inherit; font-size: 1rem; }

/* ===== SCROLL REVEAL ===== */
.reveal {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity .5s ease, transform .5s ease;
}
.reveal.revealed {
  opacity: 1;
  transform: translateY(0);
}

/* ===== NAVIGATION ===== */
.nav {
  position: sticky; top: 0; z-index: 1000;
  background: rgba(255,255,255,.95);
  backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
  height: var(--nav-height);
}
.nav-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 20px;
  display: flex;
  align-items: center;
  height: 100%;
  gap: 16px;
}
.nav-logo {
  font-family: var(--font-heading);
  font-size: 1.3rem;
  font-weight: 800;
  color: var(--primary);
  white-space: nowrap;
  letter-spacing: -.5px;
}
.nav-logo span { color: var(--text); font-weight: 600; }
.nav-links { display: flex; gap: 4px; }
.nav-link {
  color: var(--text-light);
  font-size: .85rem;
  font-weight: 500;
  padding: 6px 12px;
  border-radius: var(--radius-sm);
  transition: all var(--transition);
}
.nav-link:hover { color: var(--text); background: var(--bg-elevated); }
.nav-search {
  flex: 1;
  max-width: 420px;
  display: flex;
  position: relative;
}
.nav-search-icon {
  position: absolute;
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-lighter);
  pointer-events: none;
}
.nav-search input {
  flex: 1;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  color: var(--text);
  padding: 9px 14px 9px 38px;
  border-radius: var(--radius-sm) 0 0 var(--radius-sm);
  outline: none;
  font-size: .88rem;
  transition: border-color var(--transition), box-shadow var(--transition);
}
.nav-search input:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px var(--primary-glow);
}
.nav-search input::placeholder { color: var(--text-lighter); }
.nav-search button {
  background: var(--primary);
  color: #fff;
  border: none;
  padding: 9px 18px;
  font-weight: 600;
  font-size: .85rem;
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  transition: background var(--transition);
}
.nav-search button:hover { background: var(--primary-dark); }
.nav-auth { display: flex; align-items: center; gap: 8px; margin-left: auto; white-space: nowrap; }
.user-name { color: var(--text); font-size: .9rem; font-weight: 500; }

/* ===== BUTTONS ===== */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 10px 22px;
  border-radius: var(--radius-sm);
  font-weight: 600;
  font-size: .9rem;
  transition: all var(--transition);
  border: none;
  text-decoration: none;
}
.btn-primary { background: var(--primary); color: #fff; }
.btn-primary:hover { background: var(--primary-dark); color: #fff; box-shadow: var(--shadow-gold); transform: translateY(-1px); }
.btn-outline { background: transparent; color: var(--primary); border: 1.5px solid var(--primary); }
.btn-outline:hover { background: var(--primary); color: #fff; }
.btn-ghost { background: transparent; color: var(--text-light); border: 1px solid var(--border); }
.btn-ghost:hover { border-color: var(--text-light); color: var(--text); }
.btn-sm { padding: 6px 14px; font-size: .82rem; }
.btn-lg { padding: 14px 32px; font-size: 1.05rem; border-radius: var(--radius); }

/* ===== HERO SECTION ===== */
.hero {
  position: relative;
  min-height: 480px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 80px 20px 60px;
  overflow: hidden;
}
.hero::before {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: var(--border);
}
.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(0,0,0,.45);
  border: 1px solid rgba(255,255,255,.4);
  color: #fff;
  padding: 6px 16px;
  border-radius: 50px;
  font-size: .8rem;
  font-weight: 600;
  margin-bottom: 20px;
  letter-spacing: .3px;
  text-transform: uppercase;
  backdrop-filter: blur(4px);
}
.hero h1 {
  font-family: var(--font-heading);
  font-size: clamp(2.4rem, 5vw, 3.8rem);
  font-weight: 800;
  color: #fff;
  margin-bottom: 14px;
  line-height: 1.15;
  letter-spacing: -1px;
  text-shadow: 0 2px 12px rgba(0,0,0,.3);
}
.hero h1 .gold { color: var(--primary-light); }
.hero-sub {
  color: #fff;
  font-size: 1.1rem;
  margin-bottom: 32px;
  max-width: 540px;
  line-height: 1.6;
  text-shadow: 0 1px 6px rgba(0,0,0,.4);
}
.hero-search {
  display: flex;
  width: 100%;
  max-width: 560px;
  background: rgba(255,255,255,.95);
  border: none;
  border-radius: 50px;
  overflow: hidden;
  box-shadow: 0 8px 32px rgba(0,0,0,.2);
  transition: box-shadow var(--transition);
  backdrop-filter: blur(8px);
}
.hero-search:focus-within { box-shadow: 0 8px 32px rgba(0,0,0,.3), 0 0 0 3px var(--primary-glow); }
.hero-search input {
  flex: 1;
  background: transparent;
  border: none;
  color: var(--text);
  padding: 16px 24px;
  font-size: 1rem;
  outline: none;
}
.hero-search input::placeholder { color: var(--text-lighter); }
.hero-search button[type="submit"] {
  background: var(--primary);
  color: #fff;
  border: none;
  padding: 16px 32px;
  font-size: .95rem;
  font-weight: 700;
  white-space: nowrap;
  border-radius: 0 50px 50px 0;
  transition: background var(--transition);
}
.hero-search button[type="submit"]:hover { background: var(--primary-dark); }

/* Hero Banner BG */
.hero-banner-bg {
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
}
.hero-banner-bg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 1;
  filter: none;
}
.hero-banner-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(0,0,0,.55) 0%, rgba(0,0,0,.72) 100%);
}
.hero > *:not(.hero-banner-bg) { position: relative; z-index: 1; }

/* Hero Stats */
.hero-stats {
  display: flex;
  gap: 40px;
  margin-top: 36px;
  padding-top: 24px;
  border-top: 1px solid rgba(255,255,255,.2);
}
.hero-stats span {
  color: #fff;
  font-size: .88rem;
  text-shadow: 0 1px 4px rgba(0,0,0,.3);
}
.hero-stats strong {
  color: #fff;
  font-size: 1.2rem;
  display: block;
  font-weight: 700;
}

/* Geolocation Button */
.geo-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  min-width: 48px;
  min-height: 48px;
  height: 100%;
  background: transparent;
  border: none;
  border-left: 1px solid #E5E5EA;
  color: #636366;
  transition: all var(--transition);
  cursor: pointer;
  padding: 0;
}
.geo-btn:hover { color: var(--primary); background: var(--primary-glow); }
.geo-btn.located { color: var(--green); }
.geo-btn svg { width: 20px; height: 20px; }

/* ===== SECTION CONTAINERS ===== */
.section {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 60px 20px;
}
.section-dark {
  background: var(--bg-surface);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}
.section-header {
  text-align: center;
  margin-bottom: 36px;
}
.section-header h2 {
  font-family: var(--font-heading);
  font-size: 1.7rem;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 8px;
}
.section-header p {
  color: var(--text-light);
  font-size: 1rem;
  max-width: 560px;
  margin: 0 auto;
}
.section-label {
  display: inline-block;
  font-size: .72rem;
  font-weight: 700;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: var(--primary);
  margin-bottom: 6px;
}

/* City/Category shared section styling */
.city-section {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 48px 20px;
}

/* ===== FILTER CHIPS ===== */
.filter-chips {
  display: flex;
  gap: 10px;
  justify-content: center;
  flex-wrap: wrap;
  margin-top: 20px;
}
.filter-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 10px 20px;
  min-height: 44px;
  border-radius: 50px;
  border: 1px solid rgba(255,255,255,.4);
  background: rgba(0,0,0,.35);
  color: #fff;
  font-size: .85rem;
  font-weight: 500;
  text-decoration: none;
  transition: all var(--transition);
  position: relative;
  overflow: hidden;
  backdrop-filter: blur(4px);
}
.filter-chip:hover {
  border-color: rgba(255,255,255,.6);
  color: #fff;
  background: rgba(255,255,255,.2);
}
.chip-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  display: inline-block;
}
.filter-chip-open .chip-dot { background: var(--green); }
.filter-chip-deals .chip-dot { background: var(--primary); }
.filter-chip-delivery .chip-dot { background: var(--blue); }

/* ===== DIETARY CHIPS ===== */
.dietary-chips {
  display: flex;
  gap: 8px;
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: 24px;
}
.dietary-chip {
  display: inline-flex;
  align-items: center;
  padding: 8px 16px;
  min-height: 44px;
  border-radius: 50px;
  border: 1px solid var(--border);
  background: var(--white);
  color: #48484A;
  font-size: .78rem;
  font-weight: 600;
  text-decoration: none;
  text-transform: uppercase;
  letter-spacing: .5px;
  transition: all var(--transition);
}
.dietary-chip:hover {
  border-color: var(--green);
  color: var(--green);
  background: rgba(52,168,83,.06);
}

/* ===== CATEGORY CARDS ===== */
.cat-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 20px;
}
.cat-card {
  position: relative;
  border-radius: var(--radius);
  overflow: hidden;
  height: 140px;
  display: flex;
  align-items: flex-end;
  justify-content: flex-start;
  padding: 16px;
  text-decoration: none;
  color: #fff;
  cursor: pointer;
  border: 1px solid var(--border);
  transition: transform var(--transition), box-shadow var(--transition);
}
.cat-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
  color: #fff;
}
.cat-card::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 30%, rgba(0,0,0,.65) 100%);
  z-index: 1;
}
.cat-card .cat-icon {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -60%);
  font-size: 2.4rem;
  z-index: 0;
}
.cat-card .cat-name {
  position: relative;
  z-index: 2;
  font-weight: 700;
  font-size: .88rem;
  text-transform: uppercase;
  letter-spacing: .8px;
  text-shadow: 0 1px 4px rgba(0,0,0,.5);
}
/* Category card gradients */
.cat-pizza { background: linear-gradient(135deg, #7a3300, #bf5600); }
.cat-sushi { background: linear-gradient(135deg, #0d3312, #1b5e20); }
.cat-mexican { background: linear-gradient(135deg, #7a3300, #a67c00); }
.cat-italian { background: linear-gradient(135deg, #6e1313, #a12020); }
.cat-chinese { background: linear-gradient(135deg, #7a1919, #b83030); }
.cat-burgers { background: linear-gradient(135deg, #2e1e17, #5a3f33); }
.cat-thai { background: linear-gradient(135deg, #2a0b52, #6a1fa0); }
.cat-indian { background: linear-gradient(135deg, #7a3300, #a87000); }
.cat-default { background: linear-gradient(135deg, #333, #555); }

/* ===== PHOTO CATEGORY GRID ===== */
.cat-photo-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
}
.cat-photo-card {
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  height: 200px;
  text-decoration: none;
  color: #fff;
  display: block;
  cursor: pointer;
  box-shadow: 0 2px 12px rgba(0,0,0,.1);
}
.cat-photo-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .6s ease;
}
.cat-photo-card:hover img {
  transform: scale(1.08);
}
.cat-photo-card::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 30%, rgba(0,0,0,.75) 100%);
  z-index: 1;
  pointer-events: none;
}
.cat-photo-label {
  position: absolute;
  bottom: 16px;
  left: 16px;
  z-index: 2;
  font-weight: 700;
  font-size: 1.05rem;
  text-transform: uppercase;
  letter-spacing: .8px;
  text-shadow: 0 2px 8px rgba(0,0,0,.5);
}
.cat-photo-count {
  position: absolute;
  bottom: 16px;
  right: 16px;
  z-index: 2;
  font-size: .75rem;
  color: #fff;
  font-weight: 500;
  background: rgba(0,0,0,.5);
  padding: 3px 10px;
  border-radius: 50px;
  backdrop-filter: blur(4px);
}

/* ===== BUSINESS CARDS — Horizontal / Landscape ===== */
.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
  gap: 16px;
  align-items: start;
}
.biz-card {
  display: flex;
  flex-direction: row;
  background: var(--bg-card);
  border-radius: var(--radius);
  overflow: hidden;
  cursor: pointer;
  text-decoration: none;
  color: var(--text);
  border: 1px solid var(--border);
  transition: transform .25s ease, box-shadow .25s ease;
  box-shadow: var(--shadow-card);
  height: 180px;
}
.biz-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 28px rgba(0,0,0,.12);
  color: var(--text);
}
.biz-card-img {
  position: relative;
  width: 180px;
  min-height: 100%;
  flex-shrink: 0;
  overflow: hidden;
  background: var(--bg-elevated);
}
.biz-card-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .4s ease;
}
.biz-card:hover .biz-card-img img {
  transform: scale(1.05);
}
.biz-card-img.img-error {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 180px;
  min-height: 100%;
  background: linear-gradient(135deg, #f0e6e0 0%, #e8ddd6 50%, #f5ece6 100%);
}
.biz-card-img.img-error::after {
  content: '';
  width: 56px;
  height: 56px;
  opacity: .25;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%231D1D1F'%3E%3Cpath d='M11 9H9V2H7v7H5V2H3v7c0 2.12 1.66 3.84 3.75 3.97V22h2.5v-9.03C11.34 12.84 13 11.12 13 9V2h-2v7zm5-3v8h2.5v8H21V2c-2.76 0-5 2.24-5 4z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: center;
  background-size: contain;
}
.biz-card-img-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 50%, rgba(0,0,0,.3) 100%);
  pointer-events: none;
}
.biz-card-badge {
  position: absolute;
  top: 8px;
  z-index: 2;
  padding: 3px 8px;
  border-radius: 4px;
  font-size: .68rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .3px;
}
.biz-card-badge.featured-badge {
  left: 8px;
  background: var(--primary);
  color: #fff;
}
.biz-card-badge.biz-card-score {
  right: 8px;
  background: rgba(52,168,83,.9);
  color: #fff;
}
.biz-card-rating-overlay {
  position: absolute;
  bottom: 8px;
  left: 8px;
  z-index: 2;
  display: flex;
  align-items: center;
  gap: 4px;
  color: #fff;
  font-weight: 700;
  font-size: .82rem;
  text-shadow: 0 1px 3px rgba(0,0,0,.5);
}
.biz-card-review-count {
  font-size: .7rem;
  font-weight: 400;
  color: rgba(255,255,255,.75);
  margin-left: 1px;
}
.biz-card-body {
  padding: 12px 14px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  flex: 1;
  min-width: 0;
}
.biz-card-name {
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: .95rem;
  color: var(--text);
  line-height: 1.3;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.biz-card-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: .8rem;
  color: var(--text-light);
}
.biz-card-reviews { color: var(--text-light); }
.biz-card-addr {
  font-size: .78rem;
  color: var(--text-lighter);
  display: -webkit-box;
  -webkit-line-clamp: 1;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* ===== CARD ACTIONS ===== */
.card-actions {
  display: flex;
  gap: 5px;
  margin-top: auto;
  padding-top: 6px;
  flex-wrap: wrap;
}
.card-action-btn {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  padding: 4px 8px;
  border-radius: 4px;
  font-size: .7rem;
  font-weight: 600;
  text-decoration: none;
  transition: all var(--transition);
  white-space: nowrap;
}
.card-action-call { background: rgba(26,115,232,.08); color: #1A73E8; }
.card-action-call:hover { background: rgba(26,115,232,.15); }
.card-action-directions { background: rgba(52,168,83,.08); color: #34A853; }
.card-action-directions:hover { background: rgba(52,168,83,.15); }
.card-action-order { background: rgba(218,55,67,.06); color: var(--primary); }
.card-action-order:hover { background: rgba(218,55,67,.12); }
.card-action-menu { background: rgba(142,68,173,.08); color: #8E44AD; }
.card-action-menu:hover { background: rgba(142,68,173,.15); }

/* ===== CATEGORY PILLS ===== */
.category-pills { display: flex; flex-wrap: wrap; gap: 4px; }
.category-pill {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 4px;
  font-size: .68rem;
  font-weight: 600;
  background: var(--bg-elevated);
  color: var(--text-light);
  text-transform: uppercase;
  letter-spacing: .3px;
}

/* ===== STARS ===== */
.stars { display: inline-flex; align-items: center; gap: 1px; vertical-align: middle; }
.stars svg path.filled { fill: var(--star-color); }
.stars svg path.empty { fill: #DDD; }
.stars-count { font-weight: 700; color: var(--text); margin-left: 4px; }
.price { color: var(--green); font-weight: 700; letter-spacing: .5px; }

/* ===== SCORE BADGES ===== */
.score-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 3px 10px;
  border-radius: 6px;
  font-size: .78rem;
  font-weight: 700;
  color: #fff;
}
.score-badge-green { background: #34A853; }
.score-badge-yellow { background: #FBBC04; color: #333; }
.score-badge-orange { background: #EA8600; }
.score-badge-red { background: #EA4335; }
.featured-badge {
  display: inline-block;
  padding: 4px 10px;
  border-radius: 6px;
  font-size: .72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .5px;
  background: var(--primary);
  color: #fff;
}

/* ===== FEATURED SECTION ===== */
.featured-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
  gap: 16px;
}

/* ===== DELIVERY HUB ===== */
.delivery-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  max-width: 640px;
  margin: 0 auto;
}
.delivery-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  padding: 24px 16px;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  text-decoration: none;
  color: var(--text);
  transition: all var(--transition);
}
.delivery-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
  border-color: transparent;
  color: var(--text);
}
.delivery-card-icon {
  width: 56px;
  height: 56px;
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.delivery-doordash .delivery-card-icon { background: #FFF0ED; }
.delivery-ubereats .delivery-card-icon { background: #E8F9EF; }
.delivery-grubhub .delivery-card-icon { background: #FFECEE; }
.delivery-card-name { font-weight: 700; font-size: .92rem; }
.delivery-card-sub { font-size: .78rem; color: var(--text-lighter); text-align: center; }
.delivery-chip {
  display: inline-block;
  padding: 3px 10px;
  border-radius: 20px;
  font-size: .68rem;
  font-weight: 600;
  margin-top: 4px;
}
.delivery-chip-open { background: rgba(52,168,83,.1); color: var(--green); }
.delivery-chip-price { background: rgba(218,55,67,.06); color: var(--primary); }

/* ===== CITIES GRID ===== */
.city-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 12px;
}
.city-grid-compact {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
}
.city-card {
  display: block;
  padding: 16px;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  text-decoration: none;
  color: var(--text);
  transition: all var(--transition);
}
.city-card:hover {
  border-color: var(--primary);
  box-shadow: var(--shadow);
  transform: translateY(-2px);
  color: var(--text);
}
.city-card-name { font-weight: 600; font-size: .92rem; color: var(--text); margin-bottom: 2px; }
.city-card-count { font-size: .78rem; color: var(--text-light); }
.city-see-all {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  border: 2px dashed var(--border);
  border-radius: var(--radius-sm);
  color: var(--primary);
  font-weight: 600;
  font-size: .88rem;
  text-decoration: none;
  transition: all var(--transition);
  background: transparent;
}
.city-see-all:hover {
  border-color: var(--primary);
  background: var(--primary-glow);
}

/* ===== HOW IT WORKS ===== */
.steps-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}
.step-card {
  text-align: center;
  padding: 32px 20px;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  transition: all var(--transition);
}
.step-card:hover {
  box-shadow: var(--shadow-lg);
  border-color: transparent;
}
.step-number {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: var(--primary);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
  font-weight: 700;
  margin: 0 auto 16px;
}
.step-card h3 {
  font-family: var(--font-heading);
  font-size: 1.05rem;
  color: var(--text);
  margin-bottom: 8px;
}
.step-card p { color: var(--text-light); font-size: .88rem; line-height: 1.5; }

/* ===== SMART MATCH ===== */
.smart-match-inner {
  max-width: 700px;
  margin: 0 auto;
  text-align: center;
}
.sm-step { display: none; animation: fadeSlide .35s ease; }
.sm-step.active { display: block; }
.sm-step h3 {
  font-family: var(--font-heading);
  font-size: 1.2rem;
  color: var(--text);
  margin-bottom: 20px;
  font-weight: 600;
}
.sm-options {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: center;
}
.sm-option {
  padding: 10px 22px;
  border-radius: 50px;
  border: 1px solid var(--border);
  background: var(--white);
  color: var(--text);
  font-size: .9rem;
  font-weight: 500;
  cursor: pointer;
  transition: all var(--transition);
}
.sm-option:hover { border-color: var(--primary); color: var(--primary); }
.sm-option.selected {
  background: var(--primary);
  color: #fff;
  border-color: var(--primary);
  font-weight: 600;
}
.sm-results {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 16px;
  margin-top: 20px;
  text-align: left;
}

/* Smart Match progress bar */
.sm-progress {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 8px;
  margin-bottom: 28px;
}
.sm-progress-step {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: .8rem;
  color: var(--text-lighter);
  transition: all var(--transition);
}
.sm-progress-step.active { color: var(--primary); font-weight: 600; }
.sm-progress-step.done { color: var(--green); }
.sm-progress-dot {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--bg-elevated);
  border: 2px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: .75rem;
  font-weight: 700;
  color: var(--text-lighter);
  transition: all var(--transition);
}
.sm-progress-step.active .sm-progress-dot {
  background: var(--primary);
  border-color: var(--primary);
  color: #fff;
}
.sm-progress-step.done .sm-progress-dot {
  background: var(--green);
  border-color: var(--green);
  color: #fff;
}
.sm-progress-line {
  width: 40px;
  height: 2px;
  background: var(--border);
  margin: 0 4px;
  transition: background var(--transition);
}
.sm-progress-step.done + .sm-progress-line { background: var(--green); }

/* ===== EMAIL SIGNUP ===== */
.email-signup {
  text-align: center;
  padding: 60px 20px;
}
.email-signup h2 {
  font-family: var(--font-heading);
  font-size: 1.5rem;
  color: var(--text);
  margin-bottom: 8px;
}
.email-signup p { color: var(--text-light); margin-bottom: 24px; }
.email-form {
  display: flex;
  max-width: 440px;
  margin: 0 auto;
  border-radius: 50px;
  overflow: hidden;
  border: 2px solid var(--border);
  background: var(--white);
}
.email-form input {
  flex: 1;
  background: transparent;
  border: none;
  color: var(--text);
  padding: 12px 20px;
  outline: none;
}
.email-form input::placeholder { color: var(--text-lighter); }
.email-form button {
  background: var(--primary);
  color: #fff;
  border: none;
  padding: 12px 24px;
  font-weight: 700;
  font-size: .9rem;
  border-radius: 0 50px 50px 0;
  transition: background var(--transition);
}
.email-form button:hover { background: var(--primary-dark); }

/* ===== CAROUSEL ===== */
.carousel {
  position: relative;
  overflow: hidden;
  padding: 0 0 40px;
}
.carousel-track {
  display: flex;
  transition: transform .4s cubic-bezier(.4,0,.2,1);
  will-change: transform;
}
.carousel-track > * { flex-shrink: 0; }
.carousel-arrow {
  position: absolute;
  top: calc(50% - 20px);
  transform: translateY(-50%);
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: 1px solid var(--border);
  background: rgba(255,255,255,.95);
  color: var(--text);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 5;
  cursor: pointer;
  transition: all var(--transition);
  font-size: 1.1rem;
  box-shadow: var(--shadow);
}
.carousel-arrow:hover {
  border-color: var(--primary);
  color: var(--primary);
  box-shadow: var(--shadow-lg);
}
.carousel-arrow.prev { left: 8px; }
.carousel-arrow.next { right: 8px; }
.carousel-dots {
  display: flex;
  justify-content: center;
  gap: 8px;
  position: absolute;
  bottom: 10px;
  left: 0;
  right: 0;
}
.carousel-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--border);
  border: none;
  cursor: pointer;
  transition: all var(--transition);
  padding: 0;
}
.carousel-dot.active {
  background: var(--primary);
  transform: scale(1.3);
}

/* ===== SEARCH PAGE ===== */
.search-layout {
  display: grid;
  grid-template-columns: 250px 1fr 380px;
  gap: 0;
  min-height: calc(100vh - var(--nav-height));
}
.search-sidebar {
  padding: 24px 20px;
  border-right: 1px solid var(--border);
  position: sticky;
  top: var(--nav-height);
  height: fit-content;
  max-height: calc(100vh - var(--nav-height));
  overflow-y: auto;
  background: var(--bg-surface);
}
.filter-group { margin-bottom: 24px; }
.filter-group h4 {
  font-family: var(--font-heading);
  font-size: .92rem;
  color: var(--text);
  margin-bottom: 12px;
  font-weight: 600;
}
.filter-group label {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 5px 0;
  font-size: .86rem;
  color: var(--text-light);
  cursor: pointer;
  transition: color var(--transition);
}
.filter-group label:hover { color: var(--text); }
.filter-group input[type="radio"] { accent-color: var(--primary); }
.filter-group select {
  width: 100%;
  padding: 10px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--white);
  color: var(--text);
  font-size: .86rem;
}
.search-results { padding: 24px; }
.results-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
}
.results-header h2 {
  font-family: var(--font-heading);
  font-size: 1.15rem;
  color: var(--text);
}
.results-header select {
  background: var(--white);
  border: 1px solid var(--border);
  color: var(--text);
  padding: 8px 12px;
  border-radius: var(--radius-sm);
  font-size: .86rem;
}

/* Search Result Cards */
.result-card {
  display: flex;
  gap: 16px;
  padding: 14px;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  margin-bottom: 12px;
  cursor: pointer;
  transition: all var(--transition);
}
.result-card:hover {
  box-shadow: var(--shadow-lg);
  border-color: transparent;
}
.result-img {
  width: 140px;
  min-height: 110px;
  border-radius: var(--radius-sm);
  overflow: hidden;
  flex-shrink: 0;
  position: relative;
  background: var(--bg-elevated);
}
.result-img img { width: 100%; height: 100%; object-fit: cover; }
.result-info { flex: 1; display: flex; flex-direction: column; gap: 4px; }
.result-name {
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 1rem;
  color: var(--text);
}
.result-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: .86rem;
  color: var(--text-light);
  flex-wrap: wrap;
}
.result-addr {
  font-size: .8rem;
  color: var(--text-lighter);
  margin-top: 2px;
}

/* Search Map */
.search-map {
  position: sticky;
  top: var(--nav-height);
  height: calc(100vh - var(--nav-height));
  border-left: 1px solid var(--border);
}
.search-map #map { height: 100%; }

/* Pagination */
.pagination {
  display: flex;
  gap: 6px;
  justify-content: center;
  padding: 20px 0;
  flex-wrap: wrap;
}
.pagination button {
  padding: 8px 14px;
  border: 1px solid var(--border);
  background: var(--white);
  color: var(--text);
  border-radius: var(--radius-sm);
  font-size: .86rem;
  transition: all var(--transition);
}
.pagination button:hover:not(:disabled) { border-color: var(--primary); color: var(--primary); }
.pagination button.active {
  background: var(--primary);
  color: #fff;
  border-color: var(--primary);
  font-weight: 700;
}
.pagination button:disabled { opacity: .4; cursor: default; }

/* Map toggle */
.map-toggle {
  display: none;
  position: fixed;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 100;
  padding: 12px 28px;
  background: var(--primary);
  color: #fff;
  border: none;
  border-radius: 50px;
  font-weight: 700;
  font-size: .92rem;
  box-shadow: var(--shadow-lg);
}

/* ===== BUSINESS DETAIL PAGE ===== */
.biz-hero {
  position: relative;
  min-height: 260px;
  display: flex;
  align-items: flex-end;
  padding: 0 0 32px;
  overflow: hidden;
}
.biz-hero-bg {
  position: absolute;
  inset: 0;
  z-index: 0;
}
.biz-hero-bg img { width: 100%; height: 100%; object-fit: cover; }
.biz-hero-bg::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(0,0,0,.15) 0%, rgba(0,0,0,.6) 60%, rgba(255,255,255,1) 100%);
}
.biz-hero-content {
  position: relative;
  z-index: 1;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 20px;
  width: 100%;
}
.biz-hero-content h1 {
  font-family: var(--font-heading);
  font-size: 2rem;
  color: var(--text);
  margin-bottom: 6px;
}
.biz-meta-row {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  font-size: .92rem;
  color: var(--text-light);
}

/* CTA Bar */
.biz-cta-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 16px 20px;
  border-bottom: 1px solid var(--border);
}
.biz-cta-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 16px;
  border-radius: var(--radius-sm);
  font-size: .84rem;
  font-weight: 600;
  text-decoration: none;
  transition: all var(--transition);
  background: var(--bg-elevated);
  color: var(--text);
  border: 1px solid var(--border);
}
.biz-cta-btn:hover { border-color: var(--primary); color: var(--primary); }
.biz-cta-call { color: #1A73E8; }
.biz-cta-directions { color: #34A853; }
.biz-cta-menu { color: #8E44AD; }
.biz-cta-website { color: #1A73E8; }
.biz-cta-review { color: var(--primary); }
.biz-cta-share { color: var(--text-light); }
.biz-cta-compare { color: var(--primary); }

/* Business content layout */
.biz-content {
  display: grid;
  grid-template-columns: 1fr 340px;
  gap: 32px;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 32px 20px;
}
.biz-main { min-width: 0; }
.biz-sidebar {
  position: sticky;
  top: calc(var(--nav-height) + 20px);
  height: fit-content;
}

/* Info box */
.info-box, .hours-box {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
  margin-bottom: 16px;
}
.info-box h3, .hours-box h3 {
  font-family: var(--font-heading);
  font-size: 1rem;
  color: var(--text);
  margin-bottom: 14px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--border);
}
.info-row {
  display: flex;
  justify-content: space-between;
  padding: 8px 0;
  font-size: .86rem;
  border-bottom: 1px solid var(--bg-elevated);
}
.info-label { color: var(--text-lighter); }
.info-value { color: var(--text); text-align: right; }
.info-value a { color: var(--primary); }

/* Hours grid */
.hours-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4px 16px;
  font-size: .86rem;
}
.hours-day { color: var(--text-light); padding: 4px 0; }
.hours-time { color: var(--text); padding: 4px 0; text-align: right; }

/* Description */
.biz-description {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
  margin-bottom: 24px;
}
.biz-description h3 { font-family: var(--font-heading); color: var(--text); margin-bottom: 10px; }
.biz-description p { color: var(--text-light); line-height: 1.7; }

/* Delivery section */
.delivery-box { margin-bottom: 24px; }
.delivery-box h3 {
  font-family: var(--font-heading);
  font-size: 1.05rem;
  color: var(--text);
  margin-bottom: 14px;
}
.branded-delivery-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}
.branded-delivery-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 14px 16px;
  border-radius: var(--radius-sm);
  font-weight: 700;
  font-size: .88rem;
  text-decoration: none;
  color: #fff;
  transition: all var(--transition);
}
.branded-delivery-btn:hover { transform: translateY(-2px); box-shadow: var(--shadow-lg); color: #fff; }
.branded-delivery-doordash { background: #FF3A14; }
.branded-delivery-ubereats { background: #06C167; }
.branded-delivery-grubhub { background: #F63440; }

/* Reviews */
.reviews-section h3 {
  font-family: var(--font-heading);
  font-size: 1.15rem;
  color: var(--text);
  margin-bottom: 16px;
}
.review-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 18px;
  margin-bottom: 12px;
}
.review-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 10px;
}
.review-user { font-weight: 600; color: var(--text); }
.review-date { font-size: .8rem; color: var(--text-lighter); }
.review-title { font-weight: 600; color: var(--text); margin-bottom: 6px; }
.review-body { color: var(--text-light); font-size: .9rem; line-height: 1.6; }
.review-footer { margin-top: 10px; }
.review-helpful {
  background: none;
  border: 1px solid var(--border);
  color: var(--text-lighter);
  padding: 4px 12px;
  border-radius: 20px;
  font-size: .78rem;
  transition: all var(--transition);
}
.review-helpful:hover { border-color: var(--primary); color: var(--primary); }

/* Review form */
.review-form {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
  margin-top: 16px;
}
.review-form h3 { font-family: var(--font-heading); color: var(--text); margin-bottom: 16px; }
#star-input { display: flex; gap: 4px; margin-bottom: 16px; }
#star-input svg { cursor: pointer; fill: #DDD; transition: fill var(--transition); }
#star-input svg.active { fill: var(--star-color); }
#star-input svg:hover { fill: var(--primary); }
.form-group { margin-bottom: 14px; }
.form-group label {
  display: block;
  font-size: .86rem;
  color: var(--text-light);
  margin-bottom: 6px;
  font-weight: 500;
}
.form-group input, .form-group textarea {
  width: 100%;
  padding: 10px 14px;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text);
  outline: none;
  transition: border-color var(--transition);
}
.form-group input:focus, .form-group textarea:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px var(--primary-glow);
}
.form-group textarea { min-height: 100px; resize: vertical; }

/* Mini map */
#mini-map {
  height: 200px;
  border-radius: var(--radius-sm);
  margin-bottom: 16px;
  border: 1px solid var(--border);
}

/* Nearby/Similar sections */
.nearby-section, .similar-section, .intent-links-section {
  padding: 40px 0;
  border-top: 1px solid var(--border);
}
/* Full-width sections outside biz-main */
section.city-section {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 40px 20px;
}
.nearby-section h2, .nearby-section h3, .similar-section h2, .similar-section h3, .intent-links-section h2, .intent-links-section h3 {
  font-family: var(--font-heading);
  font-size: 1.2rem;
  color: var(--text);
  margin-bottom: 20px;
}

/* Vertical cards inside biz-main (narrow container next to sidebar) */
.biz-main .card-grid {
  grid-template-columns: repeat(2, 1fr);
}
.biz-main .card-grid .biz-card {
  flex-direction: column;
  height: auto;
}
.biz-main .card-grid .biz-card-img {
  width: 100%;
  height: 180px;
  min-height: 180px;
}
.biz-main .card-grid .biz-card-img.img-error {
  width: 100%;
  height: 180px;
  min-height: 180px;
}
.biz-main .card-grid .biz-card-body {
  padding: 14px 16px;
}

/* Intent link cards — photo-based */
.intent-links-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 16px;
}
.intent-link-card {
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  height: 160px;
  text-decoration: none;
  color: #fff;
  display: block;
  cursor: pointer;
  box-shadow: 0 2px 12px rgba(0,0,0,.1);
}
.intent-link-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .6s ease;
}
.intent-link-card:hover img {
  transform: scale(1.08);
}
.intent-link-card::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 20%, rgba(0,0,0,.7) 100%);
  z-index: 1;
  pointer-events: none;
}
.intent-link-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 24px rgba(0,0,0,.15);
  color: #fff;
}
.intent-link-label {
  position: absolute;
  bottom: 14px;
  left: 14px;
  z-index: 2;
  font-weight: 700;
  font-size: .95rem;
  text-transform: uppercase;
  letter-spacing: .8px;
  text-shadow: 0 2px 8px rgba(0,0,0,.5);
}

/* ===== CITY HERO & CATEGORY HERO ===== */
.city-hero, .category-hero {
  position: relative;
  padding: 60px 20px 48px;
  text-align: center;
  overflow: hidden;
  background: var(--bg-surface);
  border-bottom: 1px solid var(--border);
}
.city-hero h1, .category-hero h1 {
  font-family: var(--font-heading);
  font-size: 1.9rem;
  color: var(--text);
  margin-bottom: 10px;
}
.city-hero p, .category-hero p {
  color: var(--text-light);
  font-size: 1rem;
  max-width: 560px;
  margin: 0 auto 20px;
}
.city-stats, .category-stats {
  display: flex;
  justify-content: center;
  gap: 32px;
}
.city-stats span, .category-stats span { font-size: .9rem; color: var(--text-light); }
.city-stats strong, .category-stats strong { color: var(--primary); font-size: 1.1rem; display: block; font-weight: 700; }

/* City map */
#city-map { height: 400px; border-radius: var(--radius); border: 1px solid var(--border); margin-bottom: 8px; }

/* SEO content blocks */
.city-seo-block, .seo-block {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
  margin-bottom: 16px;
}
.city-seo-block h3, .seo-block h3 { font-family: var(--font-heading); font-size: 1.05rem; color: var(--text); margin-bottom: 10px; }
.city-seo-block p, .seo-block p { color: var(--text-light); line-height: 1.7; font-size: .9rem; }

/* ===== FAQ ===== */
.faq-section { border-top: 1px solid var(--border); }
.faq-item {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  margin-bottom: 8px;
  overflow: hidden;
}
.faq-item summary {
  padding: 16px 20px;
  font-weight: 600;
  color: var(--text);
  cursor: pointer;
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  transition: background var(--transition);
}
.faq-item summary:hover { background: var(--bg-elevated); }
.faq-item summary::after { content: '+'; font-size: 1.2rem; color: var(--primary); }
.faq-item[open] summary::after { content: '-'; }
.faq-item p { padding: 0 20px 16px; color: var(--text-light); line-height: 1.6; font-size: .9rem; }

/* ===== BREADCRUMBS ===== */
.breadcrumb { max-width: var(--max-width); margin: 0 auto; padding: 12px 20px; }
.breadcrumb ol { list-style: none; display: flex; gap: 8px; align-items: center; font-size: .8rem; }
.breadcrumb li { color: var(--text-lighter); }
.breadcrumb li + li::before { content: '/'; margin-right: 8px; color: var(--text-lighter); }
.breadcrumb a { color: var(--text-light); }
.breadcrumb a:hover { color: var(--primary); }

/* ===== COMPARE PAGE ===== */
.compare-table { display: grid; gap: 20px; margin-top: 20px; }
.compare-col {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}
.compare-col.compare-winner { border-color: var(--primary); box-shadow: var(--shadow-gold); }
.compare-img { height: 200px; overflow: hidden; position: relative; }
.compare-img img { width: 100%; height: 100%; object-fit: cover; }
.compare-img-overlay { position: absolute; inset: 0; background: linear-gradient(180deg, transparent 40%, rgba(0,0,0,.4) 100%); }
.compare-winner-badge {
  position: absolute; top: 12px; right: 12px; background: var(--primary); color: #fff;
  padding: 4px 12px; border-radius: 6px; font-size: .72rem; font-weight: 700; text-transform: uppercase; z-index: 2;
}
.compare-body { padding: 20px; }
.compare-body h3 { font-family: var(--font-heading); font-size: 1.15rem; color: var(--text); margin-bottom: 12px; }
.compare-row {
  display: flex; justify-content: space-between; align-items: center;
  padding: 10px 0; border-bottom: 1px solid var(--bg-elevated); font-size: .88rem;
}
.compare-label { color: var(--text-lighter); }
.compare-value { color: var(--text); font-weight: 500; text-align: right; }
.compare-score-bar { height: 8px; border-radius: 4px; background: var(--bg-elevated); overflow: hidden; margin-top: 4px; }
.compare-score-fill { height: 100%; border-radius: 4px; transition: width .8s ease; }

/* ===== INTENT PAGE ===== */
.intent-hero {
  position: relative;
  padding: 60px 20px 48px;
  text-align: center;
  overflow: hidden;
  background: var(--bg-surface);
  border-bottom: 1px solid var(--border);
}
.intent-hero h1 { font-family: var(--font-heading); font-size: 1.9rem; color: var(--text); }

/* ===== FOOTER ===== */
.footer {
  background: #1D1D1F;
  border-top: 1px solid var(--border);
  padding: 48px 20px 24px;
  margin-top: 40px;
}
.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 32px;
  max-width: var(--max-width);
  margin: 0 auto;
}
.footer-col h4, .footer-heading { font-family: var(--font-heading); color: #fff; font-size: .92rem; margin-bottom: 14px; font-weight: 700; }
.footer-col p { color: #999; font-size: .86rem; line-height: 1.6; }
.footer-col a { display: block; color: #BBB; font-size: .86rem; padding: 6px 0; transition: color var(--transition); }
.footer-col a:hover { color: #fff; }
.footer-bottom {
  text-align: center;
  padding-top: 24px;
  margin-top: 32px;
  border-top: 1px solid #333;
}
.footer-bottom p { color: #888; font-size: .8rem; }

/* ===== MODAL ===== */
.modal-overlay {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 2000;
  background: rgba(0,0,0,.5);
  backdrop-filter: blur(4px);
  align-items: center;
  justify-content: center;
}
.modal-overlay.active { display: flex; }
.modal {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 32px;
  width: 90%;
  max-width: 420px;
  position: relative;
  box-shadow: var(--shadow-lg);
}
.modal-close {
  position: absolute; top: 12px; right: 16px; background: none; border: none;
  color: var(--text-lighter); font-size: 1.5rem; transition: color var(--transition);
}
.modal-close:hover { color: var(--text); }
.modal-tabs {
  display: flex; gap: 4px; margin-bottom: 20px;
  background: var(--bg-elevated); border-radius: var(--radius-sm); padding: 3px;
}
.modal-tab {
  flex: 1; padding: 10px; border: none; background: transparent;
  color: var(--text-light); font-weight: 600; font-size: .88rem; border-radius: 6px; transition: all var(--transition);
}
.modal-tab.active { background: var(--primary); color: #fff; }
.modal-error { color: var(--red); font-size: .86rem; min-height: 1.2em; margin-bottom: 8px; }

/* ===== LOADING ===== */
.loading {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  padding: 60px 20px;
  color: var(--text-light);
  font-size: .92rem;
}
.loading-spinner {
  width: 32px;
  height: 32px;
  border: 3px solid var(--border);
  border-top-color: var(--primary);
  border-radius: 50%;
  animation: spin .8s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* Empty state */
.empty-state { text-align: center; padding: 48px 20px; color: var(--text-light); }
.empty-state h3 { color: var(--text); margin-bottom: 8px; font-family: var(--font-heading); }

/* ===== ANIMATIONS ===== */
@keyframes fadeSlide {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: translateY(0); }
}
@keyframes pulseGold {
  0%, 100% { box-shadow: 0 0 0 0 rgba(218,55,67,.2); }
  50% { box-shadow: 0 0 0 8px rgba(218,55,67,0); }
}
@keyframes shimmer {
  0% { background-position: -200% 0; }
  100% { background-position: 200% 0; }
}

/* Loading skeleton */
.skeleton {
  background: linear-gradient(90deg, var(--bg-elevated) 25%, #eee 50%, var(--bg-elevated) 75%);
  background-size: 200% 100%;
  animation: shimmer 1.5s infinite;
  border-radius: var(--radius-sm);
}

/* ===== 3D TILT / GLOW / RIPPLE ===== */
.tilt-card { transition: transform var(--transition), box-shadow var(--transition); will-change: transform; }
.glow-card { position: relative; }
.ripple { position: relative; overflow: hidden; }
.ripple-wave {
  position: absolute; border-radius: 50%; background: rgba(218,55,67,.15);
  transform: scale(0); animation: rippleExpand .5s ease-out; pointer-events: none; z-index: 10;
}
@keyframes rippleExpand { to { transform: scale(4); opacity: 0; } }

/* ===== LEAFLET ===== */
.leaflet-container { background: var(--bg-elevated); }
.leaflet-control-attribution { background: rgba(255,255,255,.9) !important; color: var(--text-lighter) !important; }
.leaflet-control-attribution a { color: var(--primary) !important; }
.leaflet-popup-content-wrapper { background: var(--white) !important; color: var(--text) !important; border-radius: var(--radius-sm) !important; box-shadow: var(--shadow) !important; }
.leaflet-popup-tip { background: var(--white) !important; }
.leaflet-popup-content a { color: var(--primary) !important; }

/* ===== RESPONSIVE ===== */
@media (max-width: 1024px) {
  .search-layout { grid-template-columns: 240px 1fr; }
  .search-map { display: none; }
  .search-map.show { display: block; position: fixed; inset: var(--nav-height) 0 0 0; z-index: 99; }
  .map-toggle { display: block; }
  .biz-content { grid-template-columns: 1fr; }
  .biz-sidebar { position: static; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .nav-links { display: none; }
}
@media (max-width: 768px) {
  .search-layout { grid-template-columns: 1fr; }
  .search-sidebar {
    position: static; border-right: none; border-bottom: 1px solid var(--border);
    max-height: none; display: grid; grid-template-columns: 1fr 1fr; gap: 12px;
  }
  .hero { min-height: 400px; padding: 60px 20px 48px; }
  .hero h1 { font-size: 1.9rem; }
  .hero-stats { flex-wrap: wrap; gap: 20px; }
  .hero-search { flex-direction: column; border-radius: var(--radius-sm); }
  .hero-search button[type="submit"] { border-radius: 0 0 var(--radius-sm) var(--radius-sm); }
  .cat-grid { grid-template-columns: repeat(2, 1fr); }
  .cat-photo-grid { grid-template-columns: repeat(2, 1fr); }
  .steps-grid { grid-template-columns: 1fr; }
  .delivery-grid { grid-template-columns: 1fr; }
  .biz-card { height: auto; }
  .branded-delivery-grid { grid-template-columns: 1fr; }
  .biz-cta-bar { overflow-x: auto; flex-wrap: nowrap; }
  .biz-cta-btn { white-space: nowrap; }
  .footer-grid { grid-template-columns: 1fr; }
  .compare-table { grid-template-columns: 1fr; }
  .nav-search { display: none; }
  .result-card { flex-direction: column; }
  .result-img { width: 100%; min-height: 150px; }
  .card-grid { grid-template-columns: 1fr; }
  .biz-card { flex-direction: row; }
  .biz-main .card-grid { grid-template-columns: 1fr; }
  .biz-main .card-grid .biz-card { flex-direction: row; height: auto; }
  .biz-main .card-grid .biz-card-img { width: 120px; height: auto; min-height: 100%; }
  .biz-main .card-grid .biz-card-img.img-error { width: 120px; height: auto; min-height: 100%; }
  .carousel-arrow { display: none; }
  .city-grid-compact { grid-template-columns: repeat(2, 1fr); }
  .filter-chip { padding: 8px 14px; min-height: 44px; font-size: .8rem; }
  .dietary-chip { padding: 6px 10px; min-height: 44px; font-size: .72rem; }
  .cat-photo-card { height: 120px; }
}
@media (max-width: 480px) {
  .hero h1 { font-size: 1.6rem; }
  .hero-sub { font-size: .95rem; }
  .cat-grid { grid-template-columns: 1fr 1fr; gap: 10px; }
  .cat-photo-grid { grid-template-columns: 1fr 1fr; gap: 10px; }
  .cat-card { height: 110px; }
  .cat-photo-card { height: 130px; }
  .card-grid { grid-template-columns: 1fr; }
  .biz-card-img { width: 120px; min-height: 100%; }
  .biz-card-img.img-error { width: 120px; min-height: 100%; }
  .city-grid { grid-template-columns: 1fr 1fr; }
  .city-grid-compact { grid-template-columns: 1fr 1fr; }
  .biz-hero-content h1 { font-size: 1.5rem; }
  .search-sidebar { grid-template-columns: 1fr; }
}
@media (hover: none) {
  .tilt-card { transform: none !important; }
}

/* ========================================
   PREMIUM UI MODERNIZATION — v6
   ======================================== */

/* ===== SKELETON LOADING SYSTEM ===== */
.skeleton-card {
  background: var(--bg-card);
  border-radius: var(--radius);
  border: 1px solid var(--border);
  overflow: hidden;
}
.skeleton-card-v {
  background: var(--bg-card);
  border-radius: var(--radius);
  border: 1px solid var(--border);
  overflow: hidden;
  display: flex;
  flex-direction: column;
}
.skeleton-card-h {
  background: var(--bg-card);
  border-radius: var(--radius);
  border: 1px solid var(--border);
  overflow: hidden;
  display: flex;
  flex-direction: row;
  height: 180px;
}
.skeleton-img {
  background: linear-gradient(90deg, var(--bg-elevated) 25%, #eee 50%, var(--bg-elevated) 75%);
  background-size: 200% 100%;
  animation: shimmer 1.5s infinite;
}
.skeleton-img-v {
  width: 100%;
  height: 200px;
}
.skeleton-img-h {
  width: 180px;
  min-height: 100%;
  flex-shrink: 0;
}
.skeleton-body {
  padding: 14px 16px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  flex: 1;
}
.skeleton-line {
  height: 12px;
  border-radius: 6px;
  background: linear-gradient(90deg, var(--bg-elevated) 25%, #eee 50%, var(--bg-elevated) 75%);
  background-size: 200% 100%;
  animation: shimmer 1.5s infinite;
}
.skeleton-line-sm { width: 40%; }
.skeleton-line-md { width: 65%; }
.skeleton-line-lg { width: 90%; }
.skeleton-pills {
  display: flex;
  gap: 6px;
  margin-top: 4px;
}
.skeleton-pill {
  width: 60px;
  height: 20px;
  border-radius: 4px;
  background: linear-gradient(90deg, var(--bg-elevated) 25%, #eee 50%, var(--bg-elevated) 75%);
  background-size: 200% 100%;
  animation: shimmer 1.5s infinite;
}
.skeleton-cat {
  height: 200px;
  border-radius: 16px;
  background: linear-gradient(90deg, var(--bg-elevated) 25%, #eee 50%, var(--bg-elevated) 75%);
  background-size: 200% 100%;
  animation: shimmer 1.5s infinite;
}

/* ===== VERTICAL BUSINESS CARDS ===== */
.card-grid-v {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 20px;
  align-items: start;
}
.biz-card-v {
  display: flex;
  flex-direction: column;
  background: var(--bg-card);
  border-radius: var(--radius);
  overflow: hidden;
  text-decoration: none;
  color: var(--text);
  cursor: pointer;
  border: 1px solid var(--border);
  transition: transform .25s ease, box-shadow .25s ease;
  box-shadow: var(--shadow-card);
}
.biz-card-v:hover {
  transform: translateY(-6px);
  box-shadow: 0 16px 32px rgba(0,0,0,.12);
  color: var(--text);
}
.biz-card-v .biz-card-img {
  position: relative;
  width: 100%;
  height: 200px;
  flex-shrink: 0;
  overflow: hidden;
  background: var(--bg-elevated);
}
.biz-card-v .biz-card-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .4s ease;
}
.biz-card-v:hover .biz-card-img img {
  transform: scale(1.05);
}
.biz-card-v .biz-card-img.img-error {
  width: 100%;
  height: 200px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, #f0e6e0 0%, #e8ddd6 50%, #f5ece6 100%);
}
.biz-card-v .biz-card-body {
  padding: 14px 16px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  flex: 1;
  min-width: 0;
}

/* ===== TOAST NOTIFICATION SYSTEM ===== */
.toast-container {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 3000;
  display: flex;
  flex-direction: column;
  gap: 8px;
  pointer-events: none;
}
.toast {
  background: var(--text);
  color: #fff;
  padding: 12px 20px;
  border-radius: var(--radius-sm);
  font-size: .88rem;
  font-weight: 500;
  box-shadow: 0 8px 24px rgba(0,0,0,.2);
  transform: translateX(120%);
  transition: transform .3s cubic-bezier(.4,0,.2,1), opacity .3s ease;
  opacity: 0;
  pointer-events: auto;
  max-width: 360px;
}
.toast-visible {
  transform: translateX(0);
  opacity: 1;
}
.toast-info { background: #1A73E8; }
.toast-success { background: #34A853; }
.toast-error { background: #EA4335; }

/* ===== SEARCH FILTER CHIP BAR (v2) ===== */
.search-layout-v2 {
  min-height: calc(100vh - var(--nav-height));
}
.search-filter-bar {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 16px 20px;
  border-bottom: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.search-filter-chips {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  padding-bottom: 2px;
}
.search-filter-chips::-webkit-scrollbar { display: none; }
.search-chip {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 8px 18px;
  border-radius: 50px;
  border: 1px solid var(--border);
  background: var(--white);
  color: var(--text-light);
  font-size: .85rem;
  font-weight: 500;
  cursor: pointer;
  white-space: nowrap;
  transition: all var(--transition);
  flex-shrink: 0;
}
.search-chip:hover {
  border-color: var(--primary);
  color: var(--primary);
}
.search-chip.active {
  background: var(--primary);
  color: #fff;
  border-color: var(--primary);
  font-weight: 600;
}
.search-filter-row {
  display: flex;
  gap: 12px;
  align-items: center;
  flex-wrap: wrap;
}
.search-filter-row select {
  padding: 8px 14px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--white);
  color: var(--text);
  font-size: .86rem;
}
.search-content {
  display: grid;
  grid-template-columns: 1fr 380px;
  gap: 0;
}
.search-content .search-results {
  padding: 24px;
}
.search-content .search-map {
  position: sticky;
  top: var(--nav-height);
  height: calc(100vh - var(--nav-height));
  border-left: 1px solid var(--border);
}
.search-content .search-map #map { height: 100%; }

/* ===== BUTTON LOADING STATE ===== */
.btn-spinner {
  display: inline-block;
  width: 14px;
  height: 14px;
  border: 2px solid rgba(255,255,255,.3);
  border-top-color: #fff;
  border-radius: 50%;
  animation: spin .6s linear infinite;
  vertical-align: middle;
}
.btn[disabled] {
  opacity: .6;
  cursor: not-allowed;
}

/* ===== SMART MATCH MODAL ===== */
.sm-modal-overlay {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 2500;
  background: rgba(0,0,0,.5);
  backdrop-filter: blur(4px);
  align-items: center;
  justify-content: center;
}
.sm-modal-overlay.active { display: flex; }
.sm-modal-content {
  background: var(--white);
  border-radius: var(--radius-lg);
  padding: 32px;
  width: 95%;
  max-width: 600px;
  max-height: 90vh;
  overflow-y: auto;
  position: relative;
  box-shadow: 0 20px 60px rgba(0,0,0,.25);
  animation: fadeSlide .3s ease;
}
.sm-modal-close {
  position: absolute;
  top: 12px;
  right: 16px;
  background: none;
  border: none;
  color: var(--text-lighter);
  font-size: 1.5rem;
  cursor: pointer;
  transition: color var(--transition);
}
.sm-modal-close:hover { color: var(--text); }

/* ===== MICRO-INTERACTIONS ===== */
@keyframes heartBounce {
  0% { transform: scale(1); }
  25% { transform: scale(1.3); }
  50% { transform: scale(.9); }
  100% { transform: scale(1); }
}
.btn-primary:active { transform: scale(.97); }
.biz-card:active, .biz-card-v:active { transform: scale(.98); }

/* ===== IMPROVED CARD ACTIONS ===== */
.card-action-btn {
  padding: 6px 10px;
  font-size: .73rem;
}

/* ===== ACCESSIBILITY — REDUCED MOTION ===== */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  .reveal { opacity: 1; transform: none; }
  .carousel-track { transition: none !important; }
}

/* ===== RESPONSIVE — v2 SEARCH ===== */
@media (max-width: 1024px) {
  .search-content { grid-template-columns: 1fr; }
  .search-content .search-map { display: none; }
  .search-content .search-map.show {
    display: block;
    position: fixed;
    inset: var(--nav-height) 0 0 0;
    z-index: 99;
  }
}
@media (max-width: 768px) {
  .search-filter-bar {
    padding: 12px 16px;
  }
  .search-filter-row {
    flex-direction: column;
    gap: 8px;
  }
  .search-filter-row select { width: 100%; }
  .card-grid-v {
    grid-template-columns: 1fr;
  }
  .biz-card-v .biz-card-img { height: 160px; }
  .skeleton-cat { height: 120px; }
  /* Mobile CTA scroll */
  .biz-cta-bar {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scroll-snap-type: x mandatory;
    flex-wrap: nowrap;
  }
  .biz-cta-btn {
    scroll-snap-align: start;
    white-space: nowrap;
  }
  .toast-container {
    left: 16px;
    right: 16px;
    bottom: 16px;
  }
  .toast { max-width: 100%; }
}
@media (max-width: 480px) {
  .card-grid-v { grid-template-columns: 1fr; }
  .biz-card-v .biz-card-img { height: 140px; }
}

/* ===== City Skyline Carousel ===== */
.city-carousel-wrap {
  position: relative;
  overflow: hidden;
  padding: 0 40px;
  margin: 0 -20px;
  cursor: grab;
  user-select: none;
  -webkit-user-select: none;
}
.city-carousel-wrap:active { cursor: grabbing; }
.city-carousel-wrap.dragging { cursor: grabbing; }
.city-carousel-track {
  display: flex;
  gap: 16px;
  transition: transform .45s cubic-bezier(.4,0,.2,1);
  will-change: transform;
}
.city-carousel-wrap.dragging .city-carousel-track {
  transition: none;
}
.city-skyline-card {
  flex: 0 0 calc(33.333% - 11px);
  position: relative;
  border-radius: 16px;
  overflow: hidden;
  height: 220px;
  text-decoration: none;
  color: #fff;
  display: block;
  box-shadow: 0 4px 16px rgba(0,0,0,.12);
  transition: transform .3s ease, box-shadow .3s ease;
}
.city-skyline-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 28px rgba(0,0,0,.18);
}
.city-skyline-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .5s ease;
}
.city-skyline-card:hover img { transform: scale(1.06); }
.city-skyline-card::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 30%, rgba(0,0,0,.7) 100%);
  z-index: 1;
  pointer-events: none;
}
.city-skyline-info {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 20px;
  z-index: 2;
}
.city-skyline-name {
  font-family: var(--font-heading);
  font-size: 1.2rem;
  font-weight: 700;
  letter-spacing: -.3px;
  text-shadow: 0 2px 8px rgba(0,0,0,.4);
  margin-bottom: 2px;
}
.city-skyline-count {
  font-size: .78rem;
  color: #fff;
}
.city-skyline-badge {
  position: absolute;
  top: 14px;
  right: 14px;
  z-index: 2;
  background: rgba(255,255,255,.2);
  backdrop-filter: blur(6px);
  padding: 4px 12px;
  border-radius: 50px;
  font-size: .7rem;
  font-weight: 600;
  color: #fff;
  letter-spacing: .3px;
}
.city-carousel-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--white);
  border: 1px solid var(--border);
  box-shadow: 0 2px 8px rgba(0,0,0,.1);
  font-size: 1.4rem;
  line-height: 1;
  color: var(--text);
  cursor: pointer;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all var(--transition);
}
.city-carousel-arrow:hover { background: var(--bg-elevated); box-shadow: 0 4px 12px rgba(0,0,0,.15); }
.city-carousel-prev { left: 4px; }
.city-carousel-next { right: 4px; }
.city-carousel-arrow[disabled] { opacity: .3; pointer-events: none; }

@media (max-width: 1024px) {
  .city-skyline-card { flex: 0 0 calc(50% - 8px); height: 180px; }
}
@media (max-width: 768px) {
  .city-carousel-wrap { padding: 0 24px; }
  .city-skyline-card { flex: 0 0 calc(80% - 8px); height: 180px; }
  .city-skyline-name { font-size: 1.05rem; }
  .city-carousel-arrow { display: none; }
}
@media (max-width: 480px) {
  .city-skyline-card { flex: 0 0 calc(85%); height: 160px; }
}

/* ========================================
   FEATURE EXPANSION — v7
   ======================================== */

/* ===== Status Badges on Cards ===== */
.biz-card-badges-row {
  position: absolute;
  top: 32px;
  left: 8px;
  display: flex;
  gap: 4px;
  z-index: 3;
}
.biz-card-badge-status {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 3px 10px;
  border-radius: 50px;
  font-size: .68rem;
  font-weight: 700;
  letter-spacing: .3px;
  text-transform: uppercase;
  color: #fff;
  backdrop-filter: blur(4px);
  box-shadow: 0 1px 4px rgba(0,0,0,.2);
}
.badge-open { background: #2e7d32; }
.badge-top-rated { background: #F59E0B; }
.badge-new { background: var(--blue); }
.badge-popular { background: #8B5CF6; }

/* ===== Smart Match Enhancements ===== */
.sm-options-multi {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: center;
}
.sm-options-multi .sm-option {
  padding: 10px 22px;
  border-radius: 50px;
  border: 1px solid var(--border);
  background: var(--white);
  color: var(--text);
  font-size: .9rem;
  font-weight: 500;
  cursor: pointer;
  transition: all var(--transition);
}
.sm-options-multi .sm-option:hover {
  border-color: var(--primary);
  color: var(--primary);
}
.sm-options-multi .sm-option.selected {
  background: var(--primary);
  color: #fff;
  border-color: var(--primary);
  font-weight: 600;
}
.sm-range {
  width: 100%;
  max-width: 400px;
  margin: 0 auto;
  display: block;
  -webkit-appearance: none;
  appearance: none;
  height: 6px;
  background: var(--bg-elevated);
  border-radius: 3px;
  outline: none;
}
.sm-range::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--primary);
  cursor: pointer;
  box-shadow: 0 2px 6px rgba(0,0,0,.2);
}
.sm-range::-moz-range-thumb {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--primary);
  cursor: pointer;
  border: none;
  box-shadow: 0 2px 6px rgba(0,0,0,.2);
}
.sm-distance-label {
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--text);
  text-align: center;
  margin-bottom: 16px;
}
.sm-match-why {
  margin-top: 10px;
  padding: 10px 12px;
  background: var(--bg-surface);
  border-radius: var(--radius-sm);
  font-size: .82rem;
  color: var(--text-light);
  line-height: 1.5;
  display: none;
}
.sm-match-why.open { display: block; }
.sm-match-toggle {
  background: none;
  border: none;
  color: var(--primary);
  font-size: .8rem;
  font-weight: 600;
  cursor: pointer;
  margin-top: 8px;
  padding: 0;
}
.sm-actions {
  display: flex;
  gap: 10px;
  justify-content: center;
  margin-top: 20px;
}

/* ===== Compare Page Enhancements ===== */
.compare-toolbar {
  display: flex;
  gap: 10px;
  margin-bottom: 20px;
  justify-content: flex-end;
}
.compare-toolbar .btn svg { margin-right: 4px; }

.compare-add-bar {
  position: relative;
  margin-bottom: 24px;
}
.compare-add-bar input {
  width: 100%;
  padding: 12px 20px;
  border: 2px solid var(--border);
  border-radius: 50px;
  font-size: .95rem;
  outline: none;
  background: var(--white);
  color: var(--text);
}
.compare-add-bar input:focus { border-color: var(--primary); }
.compare-add-dropdown {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-lg);
  z-index: 100;
  max-height: 240px;
  overflow-y: auto;
  display: none;
}
.compare-add-dropdown.open { display: block; }
.compare-add-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 16px;
  cursor: pointer;
  transition: background var(--transition);
  text-decoration: none;
  color: var(--text);
}
.compare-add-item:hover { background: var(--bg-elevated); }
.compare-add-item img {
  width: 40px;
  height: 40px;
  border-radius: var(--radius-sm);
  object-fit: cover;
}
.compare-add-item-info { flex: 1; }
.compare-add-item-name { font-weight: 600; font-size: .9rem; }
.compare-add-item-meta { font-size: .78rem; color: var(--text-light); }

.compare-value-best {
  color: #2e7d32;
  font-weight: 700;
}
.compare-value-worst {
  color: var(--red);
  font-weight: 600;
  opacity: .7;
}
.compare-remove-btn {
  position: absolute;
  top: 8px;
  right: 8px;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: rgba(0,0,0,.5);
  color: #fff;
  border: none;
  font-size: 1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 5;
  transition: background var(--transition);
}
.compare-remove-btn:hover { background: var(--red); }

/* Radar Chart */
.compare-radar-section {
  margin: 28px 0;
  text-align: center;
}
.compare-radar-section h3 {
  font-family: var(--font-heading);
  font-size: 1.2rem;
  margin-bottom: 16px;
  color: var(--text);
}
.compare-radar-legend {
  display: flex;
  gap: 16px;
  justify-content: center;
  flex-wrap: wrap;
  margin-top: 12px;
}
.compare-radar-legend-item {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: .82rem;
  color: var(--text-light);
}
.compare-radar-legend-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
}

/* Hours Comparison Table */
.compare-hours-section {
  margin: 28px 0;
}
.compare-hours-section h3 {
  font-family: var(--font-heading);
  font-size: 1.2rem;
  margin-bottom: 16px;
  color: var(--text);
  text-align: center;
}
.compare-hours-table {
  width: 100%;
  border-collapse: collapse;
  font-size: .85rem;
}
.compare-hours-table th {
  padding: 10px 12px;
  background: var(--bg-elevated);
  font-weight: 600;
  text-align: left;
  border-bottom: 2px solid var(--border);
}
.compare-hours-table td {
  padding: 8px 12px;
  border-bottom: 1px solid var(--border);
}
.compare-hours-table tr.hours-diff {
  background: rgba(218,55,67,.04);
}
.compare-hours-table .hours-closed {
  color: var(--red);
  font-weight: 600;
}

/* Category Overlap */
.compare-category-section {
  margin: 28px 0;
}
.compare-category-section h3 {
  font-family: var(--font-heading);
  font-size: 1.2rem;
  margin-bottom: 16px;
  color: var(--text);
  text-align: center;
}
.compare-cat-group {
  margin-bottom: 12px;
}
.compare-cat-group-label {
  font-size: .78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .5px;
  color: var(--text-light);
  margin-bottom: 6px;
}
.compare-cat-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.compare-cat-pill {
  display: inline-flex;
  padding: 4px 12px;
  border-radius: 50px;
  font-size: .78rem;
  font-weight: 600;
}
.compare-cat-pill-shared {
  background: rgba(46,125,50,.1);
  color: #2e7d32;
}
.compare-cat-pill-unique {
  color: #fff;
}

/* Verdict Section */
.compare-verdict-section {
  margin: 28px 0;
  padding: 24px;
  background: var(--bg-surface);
  border-radius: var(--radius);
  border: 1px solid var(--border);
}
.compare-verdict-section h3 {
  font-family: var(--font-heading);
  font-size: 1.2rem;
  margin-bottom: 12px;
  color: var(--text);
}
.compare-verdict-section p {
  font-size: .92rem;
  color: var(--text-light);
  line-height: 1.7;
  margin-bottom: 8px;
}
.compare-verdict-winner {
  font-weight: 700;
  color: var(--primary);
}

/* ===== CAN'T DECIDE GAME ===== */

/* Phase visibility */
.cd-phase { display: none; }
.cd-phase.active { display: block; }

/* Page wrapper */
.cd-page {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 48px 20px;
  min-height: 60vh;
}

/* Start screen */
.cd-start {
  text-align: center;
  max-width: 560px;
  margin: 0 auto;
  padding: 60px 0 40px;
}
.cd-start h1 {
  font-family: var(--font-heading);
  font-size: 2.2rem;
  font-weight: 800;
  color: var(--text);
  margin-bottom: 10px;
}
.cd-start-sub {
  color: var(--text-light);
  font-size: 1.05rem;
  margin-bottom: 32px;
  line-height: 1.6;
}
.cd-zip-form {
  display: flex;
  max-width: 400px;
  margin: 0 auto 40px;
  border-radius: 50px;
  overflow: hidden;
  box-shadow: var(--shadow-lg);
  border: 1px solid var(--border);
}
.cd-zip-form input {
  flex: 1;
  border: none;
  padding: 16px 24px;
  font-size: 1.05rem;
  outline: none;
  background: var(--white);
  color: var(--text);
  min-width: 0;
}
.cd-zip-form input::placeholder { color: var(--text-lighter); }
.cd-zip-form button {
  background: var(--primary);
  color: #fff;
  border: none;
  padding: 16px 28px;
  font-size: .95rem;
  font-weight: 700;
  white-space: nowrap;
  transition: background var(--transition);
}
.cd-zip-form button:hover { background: var(--primary-dark); }
.cd-zip-error {
  color: var(--red);
  font-size: .85rem;
  margin-top: -30px;
  margin-bottom: 20px;
}

/* How it works mini-guide */
.cd-how {
  display: flex;
  gap: 24px;
  justify-content: center;
  margin-top: 16px;
}
.cd-how-step {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  max-width: 150px;
}
.cd-how-num {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--primary);
  color: #fff;
  font-weight: 700;
  font-size: .9rem;
  display: flex;
  align-items: center;
  justify-content: center;
}
.cd-how-text {
  font-size: .82rem;
  color: var(--text-light);
  text-align: center;
  line-height: 1.4;
}

/* Loading */
.cd-loading {
  text-align: center;
  padding: 80px 0;
}
.cd-loading-text {
  color: var(--text-light);
  margin-top: 16px;
  font-size: .95rem;
}

/* Progress bar */
.cd-progress {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0;
  margin-bottom: 32px;
}
.cd-progress-step {
  display: flex;
  align-items: center;
  gap: 8px;
}
.cd-progress-dot {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--bg-elevated);
  border: 2px solid var(--border);
  color: var(--text-lighter);
  font-weight: 700;
  font-size: .8rem;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all .3s ease;
}
.cd-progress-dot.done {
  background: var(--green);
  border-color: var(--green);
  color: #fff;
}
.cd-progress-dot.active {
  background: var(--primary);
  border-color: var(--primary);
  color: #fff;
  box-shadow: 0 0 0 4px rgba(218,55,67,.15);
}
.cd-progress-label {
  font-size: .78rem;
  font-weight: 600;
  color: var(--text-lighter);
  margin-right: 8px;
}
.cd-progress-label.active { color: var(--text); }
.cd-progress-label.done { color: var(--green); }
.cd-progress-line {
  width: 40px;
  height: 2px;
  background: var(--border);
  margin: 0 4px;
}
.cd-progress-line.done { background: var(--green); }

/* Turn indicator */
.cd-turn {
  text-align: center;
  margin-bottom: 24px;
}
.cd-turn-players {
  display: flex;
  justify-content: center;
  gap: 16px;
  margin-bottom: 12px;
}
.cd-turn-player {
  padding: 8px 24px;
  border-radius: 50px;
  font-weight: 700;
  font-size: .9rem;
  border: 2px solid var(--border);
  color: var(--text-lighter);
  background: var(--bg-elevated);
  transition: all .3s ease;
}
.cd-turn-player.p1.active {
  border-color: var(--blue);
  background: rgba(26,115,232,.08);
  color: var(--blue);
  box-shadow: 0 0 0 4px rgba(26,115,232,.1);
}
.cd-turn-player.p2.active {
  border-color: var(--primary);
  background: var(--primary-glow);
  color: var(--primary);
  box-shadow: 0 0 0 4px rgba(218,55,67,.1);
}
.cd-turn-instruction {
  font-size: .9rem;
  color: var(--text-light);
  margin-bottom: 8px;
}
.cd-turn-instruction strong { color: var(--text); }

/* Elimination counter dots */
.cd-elim-dots {
  display: flex;
  justify-content: center;
  gap: 6px;
  margin-bottom: 20px;
}
.cd-elim-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--border);
  transition: background .3s ease;
}
.cd-elim-dot.filled { background: var(--primary); }

/* Game card grid */
.cd-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 16px;
}

/* Game cards */
.cd-card {
  background: var(--bg-card);
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--border);
  cursor: pointer;
  transition: transform .2s ease, box-shadow .2s ease, opacity .4s ease;
  position: relative;
}
.cd-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
}
.cd-card-img {
  height: 140px;
  overflow: hidden;
  position: relative;
}
.cd-card-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.cd-card-rating {
  position: absolute;
  bottom: 8px;
  left: 8px;
  background: rgba(0,0,0,.65);
  color: #fff;
  padding: 3px 8px;
  border-radius: 6px;
  font-size: .75rem;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 4px;
  backdrop-filter: blur(4px);
}
.cd-card-body {
  padding: 12px;
}
.cd-card-name {
  font-weight: 700;
  font-size: .9rem;
  color: var(--text);
  margin-bottom: 4px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.cd-card-city {
  font-size: .78rem;
  color: var(--text-light);
  margin-bottom: 6px;
}

/* Elimination animation */
@keyframes cdEliminate {
  0% { transform: scale(1); opacity: 1; }
  50% { transform: scale(.92); opacity: .6; }
  100% { transform: scale(.88); opacity: .35; }
}
.cd-card-eliminating {
  animation: cdEliminate .4s ease forwards;
  pointer-events: none;
}
.cd-card-eliminated {
  opacity: .3;
  pointer-events: none;
  filter: grayscale(1);
  position: relative;
  transform: scale(.88);
}
.cd-card-eliminated::after {
  content: '\2715';
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 3rem;
  color: var(--red);
  background: rgba(255,255,255,.4);
  font-weight: 900;
}

/* Turn transition overlay */
.cd-transition {
  position: fixed;
  inset: 0;
  z-index: 2000;
  background: rgba(0,0,0,.75);
  display: flex;
  align-items: center;
  justify-content: center;
  backdrop-filter: blur(6px);
  opacity: 0;
  pointer-events: none;
  transition: opacity .3s ease;
}
.cd-transition.active {
  opacity: 1;
  pointer-events: auto;
}
.cd-transition-text {
  color: #fff;
  font-family: var(--font-heading);
  font-size: 2.2rem;
  font-weight: 800;
  animation: cdBounceIn .5s ease;
}
.cd-transition-text.p1 { color: #8AB4F8; }
.cd-transition-text.p2 { color: #E8505A; }
@keyframes cdBounceIn {
  0% { transform: scale(.5); opacity: 0; }
  60% { transform: scale(1.1); }
  100% { transform: scale(1); opacity: 1; }
}

/* Winner section */
.cd-winner {
  text-align: center;
  padding: 40px 0;
}
.cd-winner-badge {
  display: inline-block;
  background: linear-gradient(135deg, var(--primary), #FF6B6B);
  color: #fff;
  padding: 8px 28px;
  border-radius: 50px;
  font-size: .8rem;
  font-weight: 800;
  letter-spacing: 2px;
  text-transform: uppercase;
  margin-bottom: 24px;
}
.cd-winner-card {
  max-width: 420px;
  margin: 0 auto 32px;
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 2px solid var(--primary);
  box-shadow: 0 8px 32px rgba(218,55,67,.15);
}
.cd-winner-img {
  height: 220px;
  overflow: hidden;
}
.cd-winner-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.cd-winner-body {
  padding: 20px;
}
.cd-winner-name {
  font-family: var(--font-heading);
  font-size: 1.4rem;
  font-weight: 800;
  color: var(--text);
  margin-bottom: 8px;
}
.cd-winner-meta {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  margin-bottom: 8px;
}
.cd-winner-addr {
  color: var(--text-light);
  font-size: .88rem;
  margin-bottom: 10px;
}
.cd-winner-actions {
  display: flex;
  gap: 12px;
  justify-content: center;
  margin-top: 28px;
  flex-wrap: wrap;
}

/* Confetti */
.cd-confetti-container {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 1500;
  overflow: hidden;
}
.cd-confetti-piece {
  position: absolute;
  top: -20px;
  width: 10px;
  height: 10px;
  border-radius: 2px;
  animation: cdConfettiFall linear forwards;
}
@keyframes cdConfettiFall {
  0% { transform: translateY(0) rotate(0deg); opacity: 1; }
  80% { opacity: 1; }
  100% { transform: translateY(110vh) rotate(720deg); opacity: 0; }
}

/* Mobile */
@media (max-width: 768px) {
  .cd-start h1 { font-size: 1.6rem; }
  .cd-zip-form {
    flex-direction: column;
    border-radius: var(--radius);
  }
  .cd-zip-form button {
    border-radius: 0 0 var(--radius) var(--radius);
  }
  .cd-how { flex-direction: column; align-items: center; gap: 16px; }
  .cd-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
  }
  .cd-card-img { height: 110px; }
  .cd-progress-label { display: none; }
  .cd-progress-line { width: 24px; }
  .cd-turn-player { padding: 6px 16px; font-size: .82rem; }
  .cd-winner-actions {
    flex-direction: column;
    align-items: stretch;
  }
  .cd-winner-img { height: 180px; }
  .cd-transition-text { font-size: 1.6rem; }
}

/* ===== Print Stylesheet ===== */
@media print {
  .nav, .footer, .breadcrumb, .compare-toolbar, .compare-add-bar,
  .modal-overlay, #similar-section, .card-actions, .card-action-btn,
  .sm-modal-overlay, #auth-modal { display: none !important; }
  .compare-col { break-inside: avoid; border: 1px solid #ccc; }
  body { background: #fff; color: #000; }
}

/* ===== Smart Match Mobile Full-Screen ===== */
@media (max-width: 768px) {
  .sm-modal-content {
    width: 100%;
    height: 100%;
    max-height: 100vh;
    border-radius: 0;
    padding: 24px 16px;
  }
  .sm-progress-step span { display: none; }
  .sm-progress-line { width: 24px; }
  .compare-hours-table { font-size: .75rem; }
  .compare-hours-table th,
  .compare-hours-table td { padding: 6px 8px; }
}
