/* rezbee.app/ara — search with a map (site/search.js). Tokens follow index.html. */
:root { --sr-line: #E3EBED; --sr-muted: #6B7A7E; --sr-ink: #1A1A2E; --sr-cyan: #00BCD4; --sr-cyan-ink: #00747F; --nav-h: 64px; }
* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; }
body { font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif; color: #333; background: #F4F8F9; -webkit-font-smoothing: antialiased; }
button, input, select { font: inherit; }

.sr-nav { height: var(--nav-h); background: #fff; border-bottom: 1px solid var(--sr-line); position: sticky; top: 0; z-index: 30; }
.sr-nav-inner { height: 100%; max-width: 1600px; margin: 0 auto; padding: 0 16px; display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.brand { display: inline-flex; align-items: center; gap: 8px; color: var(--sr-ink); text-decoration: none; font-weight: 800; font-size: 1.2rem; }
.brand img { width: 34px; height: 34px; border-radius: 9px; }
.sr-nav-right { display: flex; align-items: center; gap: 10px; }
.sr-nav-right .d-btn { padding: .5rem .9rem; font-size: .9rem; }

/* Two columns: the list scrolls with the page, the map stays put */
.search { display: grid; grid-template-columns: minmax(0, 1fr) minmax(380px, 46%); min-height: calc(100vh - var(--nav-h)); }
.search > * { min-width: 0; }
.sr-left { padding: 14px 16px 90px; max-width: 820px; width: 100%; margin: 0 auto; min-width: 0; }
.sr-right { position: sticky; top: var(--nav-h); height: calc(100vh - var(--nav-h)); }
#sr-map { width: 100%; height: 100%; background: #E6EEF0; }
.sr-mapfail { padding: 2rem; text-align: center; color: var(--sr-muted); }

/* Search bar */
.sr-form { min-width: 0; display: grid; grid-template-columns: minmax(0, 1fr) auto auto auto; gap: 8px; background: #fff; border: 1px solid var(--sr-line); border-radius: 999px; padding: 6px; box-shadow: 0 10px 30px rgba(10,30,35,.06); }
.sr-form .sr-field { display: flex; align-items: center; gap: 8px; min-width: 0; padding: 0 6px 0 12px; }
.sr-form .sr-field i { color: var(--sr-cyan); flex: none; }
.sr-form input { flex: 1; min-width: 0; border: 0; outline: 0; background: transparent; font-size: 1rem; color: var(--sr-ink); padding: 10px 0; }
.sr-form select { min-width: 0; border: 0; border-left: 1px solid var(--sr-line); background: transparent; color: var(--sr-ink); font-weight: 600; font-size: .92rem; padding: 10px 10px; max-width: 190px; cursor: pointer; outline: 0; }
.sr-form button { border: 0; background: var(--sr-cyan); color: #fff; font-weight: 800; padding: 0 20px; border-radius: 999px; cursor: pointer; }
.sr-form button:hover { background: #00A5BA; }

.sr-chips { min-width: 0; display: flex; gap: 8px; overflow-x: auto; padding: 12px 0 4px; scrollbar-width: none; }
.sr-chips::-webkit-scrollbar { display: none; }
.sr-chip { flex: none; display: inline-flex; align-items: center; gap: 6px; border: 1.5px solid var(--sr-line); background: #fff; color: var(--sr-ink); font-size: .86rem; font-weight: 600; padding: 7px 13px; border-radius: 999px; cursor: pointer; }
.sr-chip i { color: var(--sr-cyan); font-size: .8rem; }
.sr-chip.active { background: var(--sr-cyan); border-color: var(--sr-cyan); color: #fff; }
.sr-chip.active i { color: #fff; }

.sr-head { min-width: 0; display: flex; align-items: center; justify-content: space-between; gap: 10px; margin: 10px 0 8px; }
.sr-head h1 { margin: 0; font-size: 1.05rem; font-weight: 800; color: var(--sr-ink); }
.sr-sortwrap { display: inline-flex; align-items: center; gap: 6px; font-size: .84rem; color: var(--sr-muted); }
.sr-sortwrap select { border: 1px solid var(--sr-line); background: #fff; border-radius: 999px; padding: 6px 10px; font-size: .86rem; font-weight: 600; color: var(--sr-ink); }
.sr-note { margin: 0 0 8px; font-size: .8rem; color: var(--sr-muted); }
.sr-note:empty { display: none; }

/* Cards: a photo carousel on top, then name + rating, distance · city, category · reviews */
.sr-cards { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 22px 18px; }
.sr-card { position: relative; border-radius: 18px; transition: transform .15s; }
.sr-card.hover .sr-shots, .sr-card:hover .sr-shots { box-shadow: 0 14px 30px rgba(10,30,35,.16); }
.sr-card.active .sr-shots { box-shadow: 0 0 0 3px #F59E0B, 0 14px 30px rgba(10,30,35,.16); }
.sr-shots { position: relative; aspect-ratio: 4 / 3; border-radius: 18px; overflow: hidden; background: #E6EEF0; box-shadow: 0 6px 18px rgba(10,30,35,.08); transition: box-shadow .15s; cursor: pointer; }
.sr-track { display: flex; height: 100%; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; -webkit-overflow-scrolling: touch; }
.sr-track::-webkit-scrollbar { display: none; }
.sr-track img, .sr-track .sr-photo-empty { flex: none; width: 100%; height: 100%; object-fit: cover; scroll-snap-align: start; display: block; }
.sr-photo-empty { display: grid; place-items: center; font-size: 3rem; font-weight: 800; color: #fff; background: linear-gradient(135deg, #00BCD4, #0097A7); }
.sr-arrow { position: absolute; top: 50%; transform: translateY(-50%); width: 36px; height: 36px; border-radius: 50%; border: 0; background: rgba(255,255,255,.92); color: var(--sr-ink); display: grid; place-items: center; cursor: pointer; opacity: 0; transition: opacity .15s; box-shadow: 0 4px 12px rgba(0,0,0,.18); }
.sr-arrow.prev { left: 10px; } .sr-arrow.next { right: 10px; }
.sr-shots:hover .sr-arrow { opacity: 1; }
.sr-dots { position: absolute; left: 0; right: 0; bottom: 10px; display: flex; justify-content: center; gap: 5px; pointer-events: none; }
.sr-dots i { width: 6px; height: 6px; border-radius: 50%; background: rgba(255,255,255,.55); }
.sr-dots i.on { background: #fff; }
.sr-flag { position: absolute; left: 12px; top: 12px; font-size: .8rem; font-weight: 700; padding: 6px 12px; border-radius: 999px; background: rgba(255,255,255,.92); color: var(--sr-ink); }
.sr-flag.off { background: rgba(26,26,46,.8); color: #fff; }
.sr-link { display: block; padding: 12px 2px 0; text-decoration: none; color: var(--sr-ink); }
.sr-link h3 { margin: 0 0 4px; display: flex; align-items: baseline; justify-content: space-between; gap: 10px; font-size: 1.05rem; font-weight: 800; line-height: 1.25; }
.sr-name { min-width: 0; overflow-wrap: anywhere; }
.sr-rating { flex: none; font-weight: 800; }
.sr-rating .star { color: #F5A524; }
.sr-link p { margin: 0 0 2px; font-size: .9rem; color: var(--sr-muted); }
.sr-link .dot { margin: 0 2px; }
.sr-link .sr-off { color: #8B1D1D; font-weight: 600; }
.sr-head-right { display: flex; align-items: center; gap: 10px; }
.sr-hide { border: 1.5px solid var(--sr-line); background: #fff; color: var(--sr-ink); font-weight: 700; font-size: .86rem; padding: 7px 13px; border-radius: 999px; cursor: pointer; display: inline-flex; align-items: center; gap: 6px; }
.sr-hide i { color: var(--sr-cyan); }
.search.no-map { grid-template-columns: 1fr; }
.search.no-map .sr-right { display: none; }
.search.no-map .sr-left { max-width: 1180px; }
.search.no-map .sr-cards { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.sr-empty { padding: 2.4rem 1rem; text-align: center; color: var(--sr-muted); }
.sr-empty p { margin: 0 0 1rem; }
.d-btn { display: inline-flex; align-items: center; gap: .45rem; border: 0; background: var(--sr-cyan); color: #fff; font: inherit; font-weight: 700; padding: .62rem 1.1rem; border-radius: 999px; cursor: pointer; text-decoration: none; }
.d-btn.secondary { background: #fff; color: var(--sr-cyan-ink); border: 1px solid var(--sr-line); }

/* Pins are map layers (search.js setupPinLayers); only the popup and the visitor dot are DOM */
.sr-popup { z-index: 7; }
.sr-popup .mapboxgl-popup-content { padding: 0; border-radius: 14px; overflow: hidden; box-shadow: 0 14px 34px rgba(10,30,35,.25); }
.sr-popup .mapboxgl-popup-tip { border-top-color: #fff; }
.sr-pop { display: grid; grid-template-columns: 84px minmax(0, 1fr); gap: 10px; width: 272px; padding: 10px; text-decoration: none; color: var(--sr-ink); font-family: inherit; }
.sr-pop img, .sr-pop-empty { width: 84px; height: 84px; border-radius: 10px; object-fit: cover; display: grid; place-items: center; background: linear-gradient(135deg, #00BCD4, #0097A7); color: #fff; font-weight: 800; font-size: 1.6rem; }
.sr-pop-body { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.sr-pop strong { font-size: .95rem; line-height: 1.2; }
.sr-pop small { font-size: .78rem; color: var(--sr-muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sr-pop small .star { color: #F5A524; }
.sr-pop em { font-style: normal; font-size: .8rem; font-weight: 800; color: var(--sr-cyan-ink); margin-top: auto; }
.sr-me { width: 18px; height: 18px; border-radius: 50%; background: #2563EB; border: 3px solid #fff; box-shadow: 0 0 0 6px rgba(37,99,235,.25); }

/* Phones: one column, the map swapped in by the floating button */
.sr-toggle { display: none; }
.sr-sheet { display: none; }
@media (max-width: 900px) {
  .search { grid-template-columns: 1fr; }
  .sr-left { padding: 12px 12px 110px; }
  .sr-right { position: fixed; inset: var(--nav-h) 0 0 0; height: auto; display: none; z-index: 20; }
  .search.view-map .sr-right { display: block; }
  .search.view-map .sr-left { display: none; }
  .sr-toggle { display: inline-flex; align-items: center; gap: 8px; position: fixed; left: 50%; bottom: 18px; transform: translateX(-50%); z-index: 40; border: 0; background: var(--sr-cyan); color: #fff; font-weight: 800; font-size: .95rem; padding: 12px 20px; border-radius: 999px; box-shadow: 0 12px 30px rgba(0,0,0,.3); cursor: pointer; }
  .sr-toggle i { color: #fff; }
  .sr-sheet { display: block; position: fixed; left: 10px; right: 10px; bottom: 74px; z-index: 25; }
  .sr-sheet[hidden] { display: none; }
  .sr-form { grid-template-columns: minmax(0, 1fr) auto; border-radius: 18px; }
  .sr-form select { border-left: 0; border-top: 1px solid var(--sr-line); max-width: none; width: 100%; }
  .sr-form .sr-field { grid-column: 1; }
  .sr-form button { grid-column: 2; grid-row: 1; }
  .sr-form select:nth-of-type(1) { grid-column: 1 / 2; grid-row: 2; }
  .sr-form select:nth-of-type(2) { grid-column: 2 / 3; grid-row: 2; }
  .sr-cards { grid-template-columns: 1fr; gap: 18px; }
  .sr-hide { display: none; }
  .sr-arrow { opacity: 1; width: 30px; height: 30px; }
  .sr-sheet .sr-shots { aspect-ratio: 16 / 7; }
}
