/* ===========================================================
   ReviewsNote.com - Public site styles
   Mobile-first, Google-Reviews inspired look.
   =========================================================== */

:root {
  --blue: #1a73e8;
  --blue-dark: #174ea6;
  --gold: #fbbc04;
  --gold-dim: #e0e0e0;
  --green: #188038;
  --text: #202124;
  --text-secondary: #5f6368;
  --border: #e3e5e8;
  --bg: #f7f8fa;
  --card-bg: #ffffff;
  --radius: 14px;
  --radius-sm: 8px;
  --shadow: 0 1px 2px rgba(0,0,0,.08), 0 1px 6px rgba(0,0,0,.06);
  --shadow-hover: 0 4px 14px rgba(0,0,0,.12);
  --max-width: 1120px;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
  color: var(--text);
  background: var(--bg);
  line-height: 1.5;
}
a { color: var(--blue); text-decoration: none; }
a:hover { text-decoration: underline; }
img { max-width: 100%; display: block; }
h1,h2,h3,h4 { line-height: 1.25; margin: 0 0 8px; }
p { margin: 0 0 12px; }
.container { max-width: var(--max-width); margin: 0 auto; padding: 0 16px; }
.muted { color: var(--text-secondary); }
button { font-family: inherit; cursor: pointer; }

/* ---------------- Header ---------------- */
.site-header {
  background: #fff;
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 50;
}
.header-inner {
  display: flex;
  align-items: center;
  gap: 12px;
  height: 60px;
}
.logo {
  font-size: 20px;
  font-weight: 700;
  color: var(--text);
  display: flex;
  align-items: center;
  gap: 6px;
  white-space: nowrap;
}
.logo:hover { text-decoration: none; }
.logo-mark { color: var(--gold); font-size: 22px; }
.header-search {
  flex: 1;
  display: flex;
  max-width: 480px;
  border: 1px solid var(--border);
  border-radius: 24px;
  overflow: hidden;
  background: var(--bg);
}
.header-search input {
  flex: 1;
  border: none;
  background: transparent;
  padding: 10px 14px;
  font-size: 14px;
  outline: none;
  min-width: 0;
}
.header-search button {
  border: none;
  background: transparent;
  padding: 0 14px;
  font-size: 15px;
}
.nav-toggle {
  display: none;
  border: none;
  background: transparent;
  font-size: 22px;
  padding: 6px 10px;
}
.site-nav { display: flex; gap: 20px; white-space: nowrap; }
.site-nav a { color: var(--text); font-size: 14px; font-weight: 500; }

@media (max-width: 720px) {
  .header-inner { flex-wrap: wrap; height: auto; padding: 10px 16px; }
  .logo { order: 1; }
  .nav-toggle { order: 2; display: block; margin-left: auto; }
  .header-search { order: 3; max-width: 100%; margin-top: 8px; flex-basis: 100%; }
  .site-nav {
    order: 4; flex-basis: 100%; flex-direction: column; gap: 0;
    max-height: 0; overflow: hidden; transition: max-height .2s ease;
  }
  .site-nav.open { max-height: 200px; margin-top: 8px; }
  .site-nav a { padding: 10px 0; border-top: 1px solid var(--border); }
}

/* ---------------- Breadcrumbs ---------------- */
.breadcrumb-bar { background: #fff; border-bottom: 1px solid var(--border); }
.breadcrumbs { padding: 10px 0; font-size: 13px; color: var(--text-secondary); }
.breadcrumbs .sep { margin: 0 6px; }
.breadcrumbs .current { color: var(--text); font-weight: 500; }

/* ---------------- Hero ---------------- */
.hero {
  background: linear-gradient(135deg, var(--blue) 0%, var(--blue-dark) 100%);
  color: #fff;
  padding: 40px 0 32px;
  text-align: center;
}
.hero h1 { font-size: 28px; margin-bottom: 6px; }
.hero p { color: rgba(255,255,255,.9); font-size: 15px; }

/* ---------------- Section headings ---------------- */
.section { padding: 28px 0; }
.section-title { font-size: 20px; margin-bottom: 16px; }

/* ---------------- Card grids ---------------- */
.grid {
  display: grid;
  gap: 16px;
  grid-template-columns: repeat(2, 1fr);
}
@media (min-width: 560px) { .grid { grid-template-columns: repeat(3, 1fr); } }
@media (min-width: 860px) { .grid { grid-template-columns: repeat(4, 1fr); } }

.card {
  background: var(--card-bg);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
  transition: box-shadow .15s ease, transform .15s ease;
  display: block;
  color: inherit;
}
.card:hover { box-shadow: var(--shadow-hover); text-decoration: none; transform: translateY(-2px); }
.card-img {
  width: 100%; aspect-ratio: 4/3; object-fit: cover; background: #eee;
}
.card-body { padding: 12px 14px; }
.card-title { font-size: 15px; font-weight: 600; margin: 0 0 4px; }
.card-sub { font-size: 12.5px; color: var(--text-secondary); margin: 0; }

/* City card specific */
.city-card .card-img { aspect-ratio: 16/10; }
.city-card .card-body { text-align: center; }

/* Service card */
.service-card { text-align: center; padding: 22px 12px; }
.service-icon { font-size: 30px; margin-bottom: 8px; }

/* Business list card (row style) */
.biz-card {
  display: flex;
  gap: 14px;
  background: var(--card-bg);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 14px;
  margin-bottom: 14px;
  align-items: flex-start;
}
.biz-card .thumb { width: 92px; height: 92px; border-radius: var(--radius-sm); object-fit: cover; flex-shrink: 0; background: #eee; }
.biz-card .biz-info { flex: 1; min-width: 0; }
.biz-card h3 { font-size: 16px; margin-bottom: 2px; }
.biz-card .addr { font-size: 13px; color: var(--text-secondary); margin-bottom: 6px; }
.biz-badge { display: inline-block; font-size: 11px; background: #e8f0fe; color: var(--blue); padding: 2px 8px; border-radius: 10px; margin-bottom: 6px; }

/* ---------------- Star ratings (Google gold style) ---------------- */
.stars { display: inline-flex; letter-spacing: -1px; line-height: 1; }
.star { position: relative; color: var(--gold-dim); }
.star-full { color: var(--gold); }
.star-half {
  background: linear-gradient(90deg, var(--gold) 50%, var(--gold-dim) 50%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.rating-row { display: flex; align-items: center; gap: 6px; font-size: 13px; color: var(--text-secondary); }
.rating-number { font-weight: 700; color: var(--text); }

/* Interactive rating picker (review form) */
.star-picker { display: inline-flex; gap: 4px; font-size: 32px; cursor: pointer; }
.star-picker .sp-star { color: var(--gold-dim); transition: color .1s; }
.star-picker .sp-star.active { color: var(--gold); }

/* ---------------- Buttons ---------------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 11px 18px; border-radius: 24px; border: 1px solid var(--border);
  background: #fff; color: var(--text); font-size: 14px; font-weight: 600;
  cursor: pointer; text-decoration: none;
}
.btn:hover { background: var(--bg); text-decoration: none; }
.btn-primary { background: var(--blue); border-color: var(--blue); color: #fff; }
.btn-primary:hover { background: var(--blue-dark); }
.btn-whatsapp { background: #25d366; border-color: #25d366; color: #fff; }
.btn-whatsapp:hover { background: #1ebe57; }
.btn-block { width: 100%; }
.btn:disabled { opacity: .55; cursor: not-allowed; }
.btn-row { display: flex; flex-wrap: wrap; gap: 10px; }

/* ---------------- Business detail page ---------------- */
.biz-header { background: #fff; border-bottom: 1px solid var(--border); padding: 20px 0; }
.biz-cover { width: 100%; max-height: 280px; object-fit: cover; border-radius: var(--radius); margin-bottom: 16px; background: #eee; }
.biz-top { display: flex; gap: 16px; align-items: flex-start; flex-wrap: wrap; }
.biz-logo { width: 72px; height: 72px; border-radius: 12px; object-fit: cover; background: #eee; flex-shrink: 0; }
.biz-title h1 { font-size: 24px; margin-bottom: 4px; }
.biz-meta { font-size: 13.5px; color: var(--text-secondary); }

.gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(90px, 1fr)); gap: 8px; margin: 16px 0; }
.gallery img { width: 100%; aspect-ratio: 1; object-fit: cover; border-radius: var(--radius-sm); cursor: pointer; background: #eee; }

.lightbox {
  position: fixed; inset: 0; background: rgba(0,0,0,.88); display: none;
  align-items: center; justify-content: center; z-index: 200; padding: 20px;
}
.lightbox.open { display: flex; }
.lightbox img { max-width: 100%; max-height: 90vh; border-radius: 8px; }
.lightbox-close { position: absolute; top: 18px; right: 24px; color: #fff; font-size: 30px; background: none; border: none; }

.map-embed { width: 100%; height: 260px; border: 0; border-radius: var(--radius); margin: 16px 0; }

/* ---------------- Reviews list ---------------- */
.review-summary {
  display: flex; align-items: center; gap: 18px; background: #fff;
  border-radius: var(--radius); box-shadow: var(--shadow); padding: 20px; margin-bottom: 20px;
}
.review-summary .avg { font-size: 44px; font-weight: 700; line-height: 1; }
.review-item {
  background: #fff; border-radius: var(--radius); box-shadow: var(--shadow);
  padding: 16px; margin-bottom: 12px;
}
.review-item .rh { display: flex; justify-content: space-between; align-items: center; margin-bottom: 6px; flex-wrap: wrap; gap: 6px; }
.review-avatar {
  width: 36px; height: 36px; border-radius: 50%; background: var(--blue);
  color: #fff; display: inline-flex; align-items: center; justify-content: center;
  font-weight: 700; margin-right: 8px; font-size: 14px;
}
.review-name-row { display: flex; align-items: center; }
.review-date { font-size: 12px; color: var(--text-secondary); }
.verified-badge {
  display: inline-flex; align-items: center; gap: 3px;
  color: var(--green); font-size: 12px; font-weight: 600; margin-left: 6px;
}
.verified-badge svg { width: 13px; height: 13px; flex-shrink: 0; }
.source-badge {
  display: inline-flex; align-items: center; gap: 3px;
  color: var(--text-secondary); font-size: 11.5px; font-weight: 600; margin-left: 6px;
  background: var(--bg); border: 1px solid var(--border); padding: 1px 8px; border-radius: 10px;
}
.review-imgs { display: flex; gap: 8px; margin-top: 10px; flex-wrap: wrap; }
.review-imgs img { width: 70px; height: 70px; object-fit: cover; border-radius: var(--radius-sm); cursor: pointer; }
.admin-reply { background: var(--bg); border-radius: var(--radius-sm); padding: 10px 12px; margin-top: 10px; font-size: 13.5px; }

/* ---------------- Review form ---------------- */
.review-form-card {
  background: #fff; border-radius: var(--radius); box-shadow: var(--shadow); padding: 20px; margin-bottom: 24px;
}
.form-group { margin-bottom: 14px; }
.form-group label { display: block; font-size: 13px; font-weight: 600; margin-bottom: 6px; }
.form-control {
  width: 100%; padding: 11px 13px; border: 1px solid var(--border); border-radius: var(--radius-sm);
  font-size: 14px; font-family: inherit; background: #fff;
}
.form-control:focus { outline: 2px solid var(--blue); outline-offset: -1px; }
.form-hint { font-size: 12px; color: var(--text-secondary); margin-top: 4px; }
.form-row { display: flex; gap: 10px; flex-wrap: wrap; }
.form-row .form-control { flex: 1; min-width: 140px; }
.otp-block { display: none; }
.otp-block.show { display: block; }
.alert { padding: 12px 14px; border-radius: var(--radius-sm); font-size: 13.5px; margin-bottom: 14px; }
.alert-success { background: #e6f4ea; color: var(--green); }
.alert-error { background: #fce8e6; color: #c5221f; }
.alert-info { background: #e8f0fe; color: var(--blue-dark); }

/* ---------------- Empty state ---------------- */
.empty-state { text-align: center; padding: 60px 20px; color: var(--text-secondary); }
.empty-state .big { font-size: 40px; margin-bottom: 10px; }

/* ---------------- Footer ---------------- */
.site-footer { background: #202124; color: #cfd2d6; padding: 36px 0 24px; margin-top: 40px; }
.footer-inner { display: grid; gap: 24px; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); }
.site-footer h4 { color: #fff; font-size: 14px; margin-bottom: 10px; }
.site-footer a { color: #cfd2d6; display: block; margin-bottom: 6px; font-size: 13.5px; }
.site-footer .logo { color: #fff; margin-bottom: 8px; }
.site-footer .muted { color: #9aa0a6; font-size: 13px; }

/* ---------------- Misc ---------------- */
.text-center { text-align: center; }
.mt-0 { margin-top: 0; }
.mb-0 { margin-bottom: 0; }
