/* culturerealty.com: homepage search, "Just listed" rail, /homes/ results, agent photo fix.
   Brand: Plus Jakarta Sans; ink #0B0B0C, gold #C9A86A, navy #12223D, blue #234E9C. */
:root { --crc-ink: #0B0B0C; --crc-navy: #12223D; --crc-line: #ECECEC; --crc-muted: #4A4A4F; --crc-gold: #C9A86A; --crc-gold-dk: #6E531F; }

/* ---------- Agent photo fix (homepage team cards, /team/, Warren's portrait) ----------
   Forces every agent photo into the same 4:5 frame, cropped from the top,
   no matter how tall the original JPG is. */
img[src*="/images/warren-hall.jpg"],
img[src*="/images/connie-mester.jpg"],
img[src*="/images/jordan-powell.jpg"],
img[src*="/images/andrew-jayne.jpg"],
img[src*="/images/bradlee-davis.jpg"] {
  display: block !important; width: 100% !important; height: auto !important; max-height: none !important;
  aspect-ratio: 4 / 5 !important; object-fit: cover !important; object-position: center top !important;
  min-height: 0 !important; flex: 0 0 auto !important; border-radius: 16px;
}
img[src*="/images/warren-hall-portrait.jpg"] {
  display: block !important; width: 100% !important; height: auto !important;
  aspect-ratio: 600 / 700 !important; object-fit: cover !important; object-position: center top !important; min-height: 0 !important;
}

/* ---------- Search panel ---------- */
.crc-search { background: var(--crc-navy); color: #fff; border-radius: 26px; padding: 28px 28px 24px; display: flex; flex-direction: column; gap: 18px; box-shadow: 0 18px 50px rgba(18,34,61,.18); font-family: 'Plus Jakarta Sans', system-ui, sans-serif; }
.crc-search-top { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: baseline; gap: 6px 24px; }
.crc-search-top h2 { margin: 0; font-weight: 800; font-size: clamp(24px, 2.4vw, 32px); letter-spacing: -.02em; line-height: 1.15; }
.crc-search-top span { color: #C9D3E3; font-size: 14px; }
.crc-fields { display: grid; grid-template-columns: 2.2fr 1.3fr 1fr 1.3fr auto; gap: 10px; }
.crc-field { background: #fff; color: var(--crc-ink); border-radius: 14px; padding: 10px 16px; display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.crc-field label { font-size: 11px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--crc-gold-dk); }
.crc-field input, .crc-field select { border: 0; background: transparent; font: inherit; font-size: 16px; font-weight: 600; color: var(--crc-ink); padding: 2px 0; width: 100%; min-width: 0; }
.crc-go { background: var(--crc-gold); color: var(--crc-ink); border: 0; border-radius: 14px; padding: 0 30px; font: inherit; font-weight: 800; font-size: 16px; min-height: 64px; cursor: pointer; }
.crc-go:hover { background: #D6B87E; }
.crc-chips { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; font-size: 14px; }
.crc-chips > span { color: #C9D3E3; font-weight: 600; }
.crc-chip { border: 1px solid #3A4E70; color: #fff; border-radius: 999px; padding: 7px 14px; text-decoration: none; }
.crc-chip:hover { border-color: var(--crc-gold); color: #fff; }
.crc-gold, .crc-gold:hover { background: var(--crc-gold); border-color: var(--crc-gold); color: var(--crc-ink); font-weight: 700; }
@media (max-width: 900px) { .crc-fields { grid-template-columns: 1fr 1fr; } .crc-loc, .crc-go { grid-column: 1 / -1; } }
@media (max-width: 520px) { .crc-search { padding: 22px 18px; } }

/* ---------- "Just listed" rail ---------- */
.crc-rail-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: flex-end; gap: 14px 32px; margin: 56px 0 22px; }
.crc-eyebrow { font-size: 13px; font-weight: 700; letter-spacing: .14em; color: #866528; }
.crc-rail-head h3 { margin: 8px 0 0; font-weight: 800; font-size: clamp(24px, 2.4vw, 32px); letter-spacing: -.02em; line-height: 1.15; }
.crc-tabs { display: flex; flex-wrap: wrap; gap: 8px; }
.crc-tabs button { border: 1.5px solid var(--crc-ink); background: #fff; color: var(--crc-ink); border-radius: 999px; padding: 8px 16px; font: inherit; font-size: 14px; font-weight: 700; cursor: pointer; }
.crc-tabs button[aria-selected="true"] { background: var(--crc-ink); color: #fff; }
.crc-rail-foot { margin-top: 22px; }
.crc-more { display: inline-block; background: var(--crc-ink); color: #fff; text-decoration: none; padding: 14px 22px; border-radius: 12px; font-weight: 700; }
.crc-more:hover { color: #fff; }

/* ---------- Listing cards (homepage + /homes/) ---------- */
.idx-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 18px; }
.crc-results-page .idx-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
@media (max-width: 1100px) { .idx-grid, .crc-results-page .idx-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 560px)  { .idx-grid, .crc-results-page .idx-grid { grid-template-columns: 1fr; } }
.idx-card { border: 1px solid var(--crc-line); border-radius: 22px; overflow: hidden; background: #fff; min-width: 0; }
.idx-photo { position: relative; aspect-ratio: 4 / 3; background: #DDD; overflow: hidden; }
.idx-photo img { width: 100%; height: 100%; object-fit: cover; display: block; }
.idx-badge { position: absolute; left: 12px; top: 12px; background: #fff; font-size: 12px; font-weight: 700; padding: 5px 11px; border-radius: 999px; }
.idx-body { padding: 16px 18px 18px; }
.idx-body p { margin: 0; }
.idx-price { font-size: 23px; font-weight: 800; letter-spacing: -.02em; font-variant-numeric: tabular-nums; }
.idx-address { font-weight: 600; font-size: 15px; }
.idx-facts { font-size: 14px; color: var(--crc-muted); }
.idx-attribution { display: flex; flex-direction: column; gap: 2px; font-size: 12px; color: #6B6B70; margin-top: 10px !important; padding-top: 10px; border-top: 1px solid var(--crc-line); }
.idx-disclaimer { font-size: 12px; color: #6B6B70; max-width: 760px; margin-top: 22px; }
.idx-empty { color: var(--crc-muted); }

/* ---------- /homes/ results page ---------- */
.crc-wrap { max-width: 1320px; margin: 0 auto; padding: 40px 28px 72px; }
.crc-wrap h1 { font-weight: 800; font-size: clamp(32px, 3.6vw, 48px); letter-spacing: -.03em; margin: 0 0 24px; }
.crc-results-bar { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 10px; margin: 28px 0 14px; font-size: 14px; }
.crc-results-bar a, .crc-pager a { color: #234E9C; font-weight: 700; }
.crc-pager { display: flex; gap: 18px; justify-content: center; margin-top: 28px; }
