/* ── Reset & Base ─────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
body { font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif; color: #1a1a2e; background: #f8f9fa; line-height: 1.6; }
a { text-decoration: none; color: inherit; }
img { max-width: 100%; display: block; }

/* ── Variables ────────────────────────────────────────────── */
:root {
  --primary: #2563eb;
  --primary-dark: #1d4ed8;
  --accent: #16a34a;
  --text: #1a1a2e;
  --text-muted: #6b7280;
  --border: #e5e7eb;
  --card-bg: #ffffff;
  --bg: #f8f9fa;
  --radius: 12px;
  --shadow: 0 1px 3px rgba(0,0,0,.07), 0 4px 16px rgba(0,0,0,.05);
  --shadow-hover: 0 8px 32px rgba(0,0,0,.12);
}

/* ── Nav ──────────────────────────────────────────────────── */
body > nav { background: #fff; border-bottom: 1px solid var(--border); position: sticky; top: 0; z-index: 200; }
.nav-inner { max-width: 1160px; margin: 0 auto; padding: 0 20px; height: 60px; display: flex; align-items: center; justify-content: space-between; }
.logo { font-size: 1.05rem; font-weight: 700; color: var(--primary); }
.logo span { color: var(--text); }
@media (max-width: 640px) {
  .nav-inner { padding: 0 16px; height: 52px; }
  .logo { font-size: .95rem; }
}

/* ── Hero (home) ──────────────────────────────────────────── */
.hero { background: linear-gradient(135deg, #1e3a5f 0%, #2563eb 100%); color: #fff; padding: 72px 20px 60px; text-align: center; }
.hero-home { padding: 80px 20px 64px; }
.hero-home-content { max-width: 640px; margin: 0 auto; }
.hero-eyebrow { font-size: .85rem; font-weight: 600; letter-spacing: .06em; opacity: .75; margin-bottom: 16px; text-transform: uppercase; }
.hero h1 { font-size: clamp(1.8rem, 4vw, 3rem); font-weight: 800; line-height: 1.2; margin-bottom: 16px; }
.hero p { font-size: 1.05rem; opacity: .85; max-width: 560px; margin: 0 auto 32px; }
.hero-search { display: flex; max-width: 540px; margin: 0 auto; background: #fff; border-radius: 50px; overflow: hidden; box-shadow: 0 4px 24px rgba(0,0,0,.2); }
.hero-search input { flex: 1; border: none; outline: none; padding: 14px 20px; font-size: 1rem; color: var(--text); min-width: 0; }
.hero-search button { background: var(--accent); color: #fff; border: none; padding: 14px 24px; font-weight: 600; cursor: pointer; font-size: .95rem; white-space: nowrap; }
.hero-search button:hover { background: #15803d; }
.hero-stats { display: flex; justify-content: center; gap: 40px; margin-top: 40px; flex-wrap: wrap; }
.hero-stat { text-align: center; }
.hero-stat .num { font-size: 1.8rem; font-weight: 800; }
.hero-stat .label { font-size: .8rem; opacity: .75; text-transform: uppercase; letter-spacing: .05em; }

/* ── Section ──────────────────────────────────────────────── */
.section { max-width: 1160px; margin: 0 auto; padding: 56px 20px; }
.section-title { font-size: 1.45rem; font-weight: 700; margin-bottom: 8px; }
.section-sub { color: var(--text-muted); margin-bottom: 28px; }

/* ── State grid (index.html) ──────────────────────────────── */
.state-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 18px; }
.state-card { border-radius: var(--radius); overflow: hidden; position: relative; cursor: pointer; box-shadow: var(--shadow); transition: transform .2s, box-shadow .2s; display: flex; flex-direction: column; }
.state-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-hover); }
.state-card-pattern { background: var(--sc, linear-gradient(135deg,#1e3a5f,#2563eb)); height: 110px; display: flex; align-items: center; justify-content: center; }
.state-flag { font-size: 2.8rem; filter: drop-shadow(0 2px 8px rgba(0,0,0,.3)); }
.state-card-body { background: #fff; padding: 16px 18px 18px; flex: 1; }
.state-live-badge { display: inline-block; background: #dcfce7; color: #15803d; font-size: .72rem; font-weight: 700; padding: 2px 8px; border-radius: 4px; text-transform: uppercase; letter-spacing: .04em; margin-bottom: 8px; }
.state-soon-badge { display: inline-block; background: #f3f4f6; color: #9ca3af; font-size: .72rem; font-weight: 600; padding: 2px 8px; border-radius: 4px; text-transform: uppercase; letter-spacing: .04em; margin-bottom: 8px; }
.state-card-name { font-size: 1.05rem; font-weight: 700; margin-bottom: 4px; }
.state-card-count { font-size: .82rem; color: var(--text-muted); margin-bottom: 10px; }
.state-card-cta { font-size: .85rem; font-weight: 600; color: var(--primary); }
.state-card.state-soon { opacity: .7; pointer-events: none; }
.state-card.state-soon:hover { transform: none; }

/* ── Why section ──────────────────────────────────────────── */
.why-section { background: #1e3a5f; color: #fff; padding: 56px 20px; }
.why-inner { max-width: 1160px; margin: 0 auto; }
.why-headline { font-size: 1.45rem; font-weight: 700; margin-bottom: 32px; }
.why-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 24px; }
.why-item { }
.why-icon { font-size: 1.8rem; margin-bottom: 10px; }
.why-title { font-weight: 700; margin-bottom: 8px; font-size: .95rem; }
.why-item p { font-size: .88rem; opacity: .75; line-height: 1.65; }

/* ── How it works ─────────────────────────────────────────── */
.how-steps { display: flex; flex-direction: column; gap: 0; margin-top: 32px; }
.how-step { display: flex; gap: 20px; padding: 20px 0; border-bottom: 1px solid var(--border); }
.how-step:last-child { border-bottom: none; }
.how-num { width: 36px; height: 36px; min-width: 36px; background: var(--primary); color: #fff; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-weight: 700; font-size: 1rem; margin-top: 2px; }
.how-text strong { font-size: .95rem; font-weight: 600; display: block; margin-bottom: 4px; }
.how-text p { font-size: .88rem; color: var(--text-muted); }

/* ── State hero (johor.html) ──────────────────────────────── */
.state-hero { background: linear-gradient(135deg, #1e3a5f 0%, #2563eb 100%); color: #fff; padding: 48px 20px 44px; }
.state-hero-inner { max-width: 1160px; margin: 0 auto; }
.state-hero h1 { font-size: clamp(1.5rem, 3vw, 2.4rem); font-weight: 800; margin-bottom: 10px; line-height: 1.2; }
.state-hero p { font-size: 1rem; opacity: .85; max-width: 560px; margin-bottom: 20px; }
.state-hero-search { max-width: 480px; }
.state-hero-search input { width: 100%; padding: 12px 18px; border: none; border-radius: 8px; font-size: .95rem; outline: none; color: var(--text); box-shadow: 0 2px 8px rgba(0,0,0,.15); }

/* ── Breadcrumb ────────────────────────────────────────────── */
.breadcrumb { display: flex; align-items: center; gap: 6px; font-size: .82rem; opacity: .75; margin-bottom: 14px; flex-wrap: wrap; }
.breadcrumb a { opacity: .85; }
.breadcrumb a:hover { opacity: 1; }
.breadcrumb span { opacity: .6; }

/* ── Filter bar ───────────────────────────────────────────── */
.filter-bar-wrap { background: #fff; border-bottom: 1px solid var(--border); position: sticky; top: 60px; z-index: 150; transition: box-shadow .2s; }
.filter-bar-wrap.stuck { box-shadow: 0 2px 8px rgba(0,0,0,.08); }
.filter-bar-inner { max-width: 1160px; margin: 0 auto; padding: 0 20px; display: flex; align-items: center; gap: 12px; height: 52px; }
.filter-scroll { display: flex; gap: 8px; overflow-x: auto; flex: 1; scrollbar-width: none; padding: 8px 0; }
.filter-scroll::-webkit-scrollbar { display: none; }
.filter-pill { padding: 6px 14px; border-radius: 50px; border: 1.5px solid var(--border); background: #fff; font-size: .82rem; cursor: pointer; color: var(--text-muted); transition: all .18s; white-space: nowrap; flex-shrink: 0; }
.filter-pill:hover { border-color: var(--primary); color: var(--primary); }
.filter-pill.active { background: var(--primary); color: #fff; border-color: var(--primary); }
.filter-right { display: flex; align-items: center; gap: 10px; flex-shrink: 0; }
.sort-select { padding: 6px 10px; border: 1.5px solid var(--border); border-radius: 8px; font-size: .82rem; background: #fff; cursor: pointer; color: var(--text); outline: none; }
.view-toggle { display: flex; border: 1.5px solid var(--border); border-radius: 8px; overflow: hidden; }
.view-btn { background: #fff; border: none; padding: 6px 10px; cursor: pointer; color: var(--text-muted); transition: all .18s; display: flex; align-items: center; }
.view-btn + .view-btn { border-left: 1.5px solid var(--border); }
.view-btn:hover { background: #f3f4f6; color: var(--text); }
.view-btn.active { background: var(--primary); color: #fff; }

/* ── Results bar ──────────────────────────────────────────── */
.results-bar { background: var(--bg); border-bottom: 1px solid var(--border); }
.results-inner { max-width: 1160px; margin: 0 auto; padding: 10px 20px; font-size: .82rem; color: var(--text-muted); display: flex; gap: 6px; }

/* ── Facility card grid ───────────────────────────────────── */
.state-content { max-width: 1160px; margin: 0 auto; padding: 24px 20px 60px; }
.fac-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 22px; }
@media (max-width: 680px) { .fac-grid { grid-template-columns: 1fr; gap: 16px; } }

/* ── Facility card ────────────────────────────────────────── */
.fac-card { background: var(--card-bg); border-radius: var(--radius); box-shadow: var(--shadow); border: 1px solid var(--border); overflow: hidden; display: flex; flex-direction: column; transition: transform .2s, box-shadow .2s; }
.fac-card:hover { box-shadow: var(--shadow-hover); }

/* Card photo area */
.fac-card-img { position: relative; height: 190px; background: linear-gradient(135deg, #cbd5e1, #94a3b8); overflow: hidden; flex-shrink: 0; }
.fac-card-img img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform .35s ease; will-change: transform; }
.fac-card:hover .fac-card-img img { transform: scale(1.04); }
.fac-card-img.no-photo { background: linear-gradient(135deg, #dbeafe, #bfdbfe); display: flex; align-items: center; justify-content: center; }
.fac-card-img.no-photo::after { content: '🏥'; font-size: 2.5rem; opacity: .4; }

/* Price badge on photo */
.fac-price-badge { position: absolute; bottom: 10px; left: 10px; background: rgba(22,163,74,.92); color: #fff; font-size: .78rem; font-weight: 700; padding: 4px 10px; border-radius: 6px; backdrop-filter: blur(4px); }
.fac-price-badge.unknown { background: rgba(75,85,99,.75); font-weight: 400; }

/* Group tag on photo */
.fac-group-tag { position: absolute; top: 10px; left: 10px; background: rgba(124,58,237,.88); color: #fff; font-size: .72rem; font-weight: 600; padding: 3px 8px; border-radius: 4px; backdrop-filter: blur(4px); }

/* Branch tag (on org page cards) */
.fac-branch-tag { position: absolute; top: 10px; right: 10px; background: rgba(37,99,235,.88); color: #fff; font-size: .72rem; font-weight: 600; padding: 3px 8px; border-radius: 4px; letter-spacing: .02em; }

/* Card body */
.fac-card-body { padding: 16px 18px 18px; display: flex; flex-direction: column; gap: 8px; flex: 1; }
.fac-card-name { font-size: .97rem; font-weight: 700; line-height: 1.35; color: var(--text); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.fac-card-meta { display: flex; align-items: center; justify-content: space-between; font-size: .8rem; color: var(--text-muted); }
.fac-area { flex-shrink: 0; }
.fac-rating { color: #f59e0b; font-weight: 600; white-space: nowrap; }
.fac-rating .fac-reviews { color: var(--text-muted); font-weight: 400; }
.fac-excerpt { font-size: .82rem; color: #4b5563; line-height: 1.55; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; flex-shrink: 0; }
.fac-card-tags { display: flex; flex-wrap: wrap; gap: 5px; margin-top: auto; padding-top: 4px; }
.tag { font-size: .72rem; padding: 3px 9px; border-radius: 50px; background: #eff6ff; color: var(--primary); font-weight: 500; }

/* Skeleton card */
.fac-card-skeleton { background: var(--card-bg); border-radius: var(--radius); border: 1px solid var(--border); overflow: hidden; animation: pulse 1.4s ease-in-out infinite; }
.fac-card-skeleton::before { content: ''; display: block; aspect-ratio: 16/9; background: linear-gradient(90deg, #f1f5f9 25%, #e2e8f0 50%, #f1f5f9 75%); background-size: 200% 100%; animation: shimmer 1.4s ease-in-out infinite; }
.fac-card-skeleton::after { content: ''; display: block; height: 100px; margin: 16px 18px; background: linear-gradient(90deg, #f1f5f9 25%, #e2e8f0 50%, #f1f5f9 75%); background-size: 200% 100%; border-radius: 6px; animation: shimmer 1.4s ease-in-out infinite; }
@keyframes shimmer { 0% { background-position: 200% 0; } 100% { background-position: -200% 0; } }

/* Empty state */
.empty-state { grid-column: 1/-1; text-align: center; padding: 48px; color: var(--text-muted); }
.empty-state button { margin-top: 12px; background: var(--primary); color: #fff; border: none; padding: 8px 18px; border-radius: 8px; cursor: pointer; font-size: .88rem; }

/* ── Leaflet map view ─────────────────────────────────────── */
#mapView { display: flex; height: calc(100vh - 170px); min-height: 520px; width: 100%; align-items: stretch; }
#mapSidebar { width: 340px; flex-shrink: 0; overflow-y: auto; background: #f8fafc; border-right: 1px solid var(--border); padding: 12px; }
#leafletMap { flex: 1; min-width: 0; height: 100%; }
.map-popup { font-family: 'Inter', sans-serif; font-size: .88rem; line-height: 1.5; min-width: 200px; }
.map-popup .mp-care { margin-top: 6px; font-size: .78rem; color: #374151; }
.map-popup .mp-rating { color: #f59e0b; font-weight: 600; }
.map-popup .mp-no-reviews { color: #9ca3af; font-size: .78rem; }
.leaflet-popup-content-wrapper { border-radius: 10px !important; box-shadow: 0 4px 24px rgba(0,0,0,.15) !important; }

/* Map sidebar mini-cards */
.mc-card { display: block; background: #fff; border: 1px solid var(--border); border-radius: 8px; padding: 10px 12px; margin-bottom: 8px; text-decoration: none; color: var(--text); transition: all .15s; }
.mc-card:hover { border-color: var(--primary); transform: translateY(-1px); box-shadow: 0 2px 8px rgba(0,0,0,.06); }
.mc-card.mc-active { border-color: var(--primary); box-shadow: 0 0 0 2px rgba(37,99,235,.18); }
.mc-name { font-weight: 600; font-size: .9rem; line-height: 1.3; margin-bottom: 4px; color: var(--text); }
.mc-meta { font-size: .78rem; color: var(--text-muted); margin-bottom: 2px; }
.mc-rating { color: #f59e0b; font-weight: 600; }
.mc-no-rating { color: var(--text-muted); font-weight: 400; }
.mc-price { color: #16a34a; font-weight: 600; }
.mc-tags { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 6px; }
.mc-tags .tag { font-size: .68rem; padding: 2px 7px; }
.mc-empty { padding: 20px; text-align: center; color: var(--text-muted); font-size: .85rem; }

/* Mobile: stack filter bar so area scroll doesn't get clipped by sort/view */
@media (max-width: 640px) {
  .filter-bar-inner { flex-direction: column; align-items: stretch; height: auto; padding: 8px 14px; gap: 6px; }
  .filter-scroll { width: 100%; padding: 4px 0; }
  .filter-right { width: 100%; justify-content: space-between; gap: 8px; }
  .sort-select { flex: 1; min-width: 0; }
  .filter-bar-wrap { top: 52px; }
}

/* Map view: stack on small screens */
@media (max-width: 800px) {
  #mapView { flex-direction: column; height: auto; min-height: 0; }
  #mapSidebar { width: 100%; max-height: 38vh; border-right: none; border-bottom: 1px solid var(--border); order: 2; }
  #leafletMap { height: 56vh; min-height: 320px; order: 1; }
}

/* ── Org page ─────────────────────────────────────────────── */
.org-hero { background: linear-gradient(135deg, #4c1d95 0%, #7c3aed 100%); color: #fff; padding: 48px 20px 44px; }
.org-hero-inner { max-width: 1060px; margin: 0 auto; }
.org-hero-badge { display: inline-block; background: rgba(255,255,255,.15); font-size: .75rem; font-weight: 600; padding: 4px 12px; border-radius: 4px; letter-spacing: .05em; text-transform: uppercase; margin-bottom: 14px; }
.org-hero-inner h1 { font-size: clamp(1.6rem, 3vw, 2.5rem); font-weight: 800; margin-bottom: 10px; line-height: 1.2; }
.org-tagline { font-size: 1rem; opacity: .85; margin-bottom: 14px; }
.org-hero-meta { display: flex; gap: 12px; font-size: .85rem; opacity: .75; flex-wrap: wrap; align-items: center; margin-bottom: 18px; }
.org-actions { display: flex; gap: 12px; flex-wrap: wrap; }
.org-website-btn { display: inline-block; background: rgba(255,255,255,.15); border: 1.5px solid rgba(255,255,255,.4); color: #fff; padding: 9px 20px; border-radius: 8px; font-size: .88rem; font-weight: 600; transition: background .2s; }
.org-website-btn:hover { background: rgba(255,255,255,.25); }

.org-body { max-width: 1060px; margin: 0 auto; padding: 28px 20px 60px; display: grid; grid-template-columns: 1fr 280px; gap: 24px; align-items: start; }
@media (max-width: 780px) { .org-body { grid-template-columns: 1fr; } }
.org-main { display: flex; flex-direction: column; gap: 20px; }
.org-sidebar { display: flex; flex-direction: column; gap: 20px; }
.org-branches-header { }

/* ── Org page – old .profile-card reuse ───────────────────── */
.profile-card { background: #fff; border-radius: var(--radius); border: 1px solid var(--border); padding: 24px 28px; box-shadow: var(--shadow); }
.profile-card h2 { font-size: 1rem; font-weight: 700; margin-bottom: 16px; padding-bottom: 10px; border-bottom: 2px solid #f1f5f9; color: var(--text); letter-spacing: -.01em; }
.info-row { display: flex; justify-content: space-between; align-items: flex-start; padding: 7px 0; border-bottom: 1px solid #f3f4f6; font-size: .88rem; gap: 12px; }
.info-row:last-child { border-bottom: none; }
.info-label { color: var(--text-muted); flex-shrink: 0; }
.info-value { font-weight: 500; text-align: right; }

/* ── Profile Hero (facility.html) ─────────────────────────── */
.profile-hero { background: linear-gradient(135deg, #1e3a5f 0%, #2563eb 100%); color: #fff; padding: 48px 20px 44px; }
.profile-hero-inner { max-width: 1060px; margin: 0 auto; }
.profile-hero h1 { font-size: clamp(1.4rem, 3vw, 2.4rem); font-weight: 800; margin-bottom: 10px; line-height: 1.2; }
.hero-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 16px; margin-bottom: 14px; font-size: .9rem; opacity: .85; }
.hero-rating { display: flex; align-items: center; gap: 4px; }
.hero-price { font-size: 1.1rem; font-weight: 700; margin-top: 12px; color: #86efac; }
.profile-hero .badges { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.badge { background: rgba(255,255,255,.15); padding: 5px 14px; border-radius: 50px; font-size: .82rem; }
.back-link-white { display: inline-flex; align-items: center; gap: 4px; color: rgba(255,255,255,.65); font-size: .85rem; margin-bottom: 16px; }
.back-link-white:hover { color: #fff; }
.hero-cta-btn { display: inline-block; padding: 11px 22px; border-radius: 8px; font-weight: 700; font-size: .9rem; cursor: pointer; transition: all .2s; }
.hero-cta-primary { background: var(--accent); color: #fff; }
.hero-cta-primary:hover { background: #15803d; }
.hero-cta-secondary { background: rgba(255,255,255,.15); color: #fff; border: 1.5px solid rgba(255,255,255,.4); }
.hero-cta-secondary:hover { background: rgba(255,255,255,.25); }

/* Group tag on facility profile header (light theme — readable on white bg) */
.profile-group-tag { display: inline-flex; align-items: center; gap: 6px; background: #f5f3ff; border: 1px solid #ddd6fe; color: #5b21b6; padding: 5px 12px; border-radius: 6px; font-size: .82rem; font-weight: 500; }
.profile-group-tag a { color: #5b21b6; text-decoration: underline; text-underline-offset: 2px; }
.profile-group-tag a:hover { color: #4c1d95; }

/* ── Tab Navigation (facility.html) ──────────────────────── */
.tabs-nav { background: #fff; border-bottom: 1px solid var(--border); z-index: 90; }
.tabs-nav.tabs-sticky { position: sticky; top: 60px; }
.tabs-nav-inner { max-width: 1060px; margin: 0 auto; padding: 0 20px; display: flex; gap: 0; overflow-x: auto; }
.tab-btn { padding: 14px 20px; border: none; background: none; font-size: .9rem; font-weight: 500; color: var(--text-muted); cursor: pointer; border-bottom: 3px solid transparent; white-space: nowrap; transition: all .2s; }
.tab-btn:hover { color: var(--primary); }
.tab-btn.active { color: var(--primary); border-bottom-color: var(--primary); font-weight: 600; }
.tab-panel { display: none; }
.tab-panel.active { display: flex; flex-direction: column; gap: 20px; }

/* ── Profile Page Body (facility.html) ────────────────────── */
.profile-page-body { max-width: 1060px; margin: 0 auto; padding: 28px 20px 60px; display: grid; grid-template-columns: 1fr 300px; gap: 24px; align-items: start; }
@media (max-width: 780px) { .profile-page-body { grid-template-columns: 1fr; } }
.profile-main { display: flex; flex-direction: column; gap: 0; min-width: 0; }
@media (max-width: 600px) { .profile-card { padding: 18px; } }
.text-muted { color: var(--text-muted); font-size: .88rem; }
.section-label { font-size: .78rem; font-weight: 600; text-transform: uppercase; letter-spacing: .05em; color: var(--text-muted); margin-bottom: 10px; }

/* ── Editorial box ────────────────────────────────────────── */
.editorial-box { background: #f0f9ff; border: 1px solid #bae6fd; border-radius: var(--radius); padding: 20px 24px; }
.editorial-label { font-size: .78rem; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; color: #0369a1; margin-bottom: 8px; }
.editorial-box p { font-size: .9rem; line-height: 1.7; color: #1e3a5f; }

/* ── Pricing Table ────────────────────────────────────────── */
.price-table { width: 100%; border-collapse: collapse; margin-bottom: 20px; }
.price-table th { font-size: .78rem; font-weight: 600; text-transform: uppercase; letter-spacing: .05em; color: var(--text-muted); padding: 8px 12px; text-align: left; border-bottom: 2px solid var(--border); }
.price-table td { padding: 9px 12px; font-size: .9rem; border-bottom: 1px solid #f3f4f6; }
.price-table tr:last-child td { border-bottom: none; }

/* ── Photo gallery (facility.html) ────────────────────────── */
.profile-hero.has-photo { background-color: #0f172a; }
.photo-gallery { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
.photo-gallery .gallery-item { display: block; aspect-ratio: 4/3; border-radius: 8px; overflow: hidden; background: #f3f4f6; cursor: zoom-in; }
.photo-gallery .gallery-item img { width: 100%; height: 100%; object-fit: cover; transition: transform .2s ease; }
.photo-gallery .gallery-item:hover img { transform: scale(1.04); }
@media (max-width: 720px) { .photo-gallery { grid-template-columns: repeat(2, 1fr); } }

/* ── Legacy card styles (facilities.html) ─────────────────── */
.filters { display: flex; gap: 10px; flex-wrap: wrap; margin-bottom: 24px; }
.filter-btn { padding: 7px 16px; border-radius: 50px; border: 1.5px solid var(--border); background: #fff; font-size: .85rem; cursor: pointer; color: var(--text-muted); transition: all .2s; }
.filter-btn:hover, .filter-btn.active { background: var(--primary); color: #fff; border-color: var(--primary); }
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 20px; }
.card { background: var(--card-bg); border-radius: var(--radius); box-shadow: var(--shadow); padding: 20px; display: flex; flex-direction: column; gap: 10px; transition: transform .2s, box-shadow .2s; border: 1px solid var(--border); }
.card:hover { transform: translateY(-3px); box-shadow: var(--shadow-hover); }
.card-name { font-size: 1rem; font-weight: 700; line-height: 1.3; color: var(--text); }
.card-area { font-size: .82rem; color: var(--text-muted); }
.card-price { background: #f0fdf4; color: var(--accent); font-weight: 700; font-size: .9rem; padding: 6px 12px; border-radius: 8px; display: inline-block; }
.card-price.unknown { background: #f3f4f6; color: var(--text-muted); font-weight: 400; }
.card-tags { display: flex; flex-wrap: wrap; gap: 6px; }
.card-rating { font-size: .82rem; color: var(--text-muted); display: flex; align-items: center; gap: 4px; margin-top: auto; }
.card-rating .stars { color: #f59e0b; }
.skeleton-card { background: var(--card-bg); border-radius: var(--radius); border: 1px solid var(--border); height: 160px; animation: pulse 1.4s ease-in-out infinite; }
.search-bar { display: flex; gap: 10px; margin-bottom: 20px; }
.search-bar input { flex: 1; padding: 10px 16px; border: 1.5px solid var(--border); border-radius: 8px; font-size: .95rem; outline: none; }
.search-bar input:focus { border-color: var(--primary); }

/* ── Footer ────────────────────────────────────────────────── */
footer { background: #1e3a5f; color: #cbd5e1; margin-top: 64px; padding: 48px 20px 32px; }
.footer-inner { max-width: 1160px; margin: 0 auto; display: flex; flex-direction: column; align-items: center; gap: 20px; text-align: center; }
.footer-logo { font-size: 1.1rem; font-weight: 700; color: #fff; letter-spacing: -.01em; }
.footer-tagline { font-size: .875rem; color: #94a3b8; margin-top: 6px; max-width: 340px; line-height: 1.5; }
.footer-links { display: flex; gap: 28px; }
.footer-links a { font-size: .875rem; color: #94a3b8; transition: color .15s; }
.footer-links a:hover { color: #fff; }
.footer-copy { font-size: .8rem; color: #64748b; border-top: 1px solid #2d4d6e; padding-top: 20px; width: 100%; text-align: center; }

@keyframes pulse { 0%,100%{opacity:1} 50%{opacity:.5} }

/* ── Ad slots — non-intrusive placeholders, ready for AdSense / Ezoic / direct fills ── */
.ad-slot {
  background: #fafafa;
  border: 1px solid #f1f5f9;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #94a3b8;
  font-size: .72rem;
  letter-spacing: .04em;
  text-transform: uppercase;
  text-align: center;
}
.ad-slot::before { content: 'Advertisement'; }
.ad-slot.sidebar { margin-top: 16px; min-height: 250px; }
.ad-slot.in-feed { grid-column: 1 / -1; min-height: 120px; margin: 8px 0; }
.ad-slot.banner  { max-width: 1160px; margin: 40px auto 0; min-height: 100px; }
@media (max-width: 720px) {
  .ad-slot.sidebar,
  .ad-slot.in-feed { min-height: 100px; }
  .ad-slot.banner  { min-height: 90px; margin: 24px 16px 0; }
}
