/* GN PropTx Sync — frontend styles.
   Themeable via CSS custom properties: override in your theme stylesheet. */
:root {
	--gn-accent: #3b82f6;
	--gn-accent-dark: #2563eb;
	--gn-text: #1d2433;
	--gn-muted: #5b6472;
	--gn-card-bg: #ffffff;
	--gn-line: #e4e7ec;
	--gn-radius: 14px;
}

.gn-container { max-width: 1140px; margin: 0 auto; padding: 0 20px; }
.gn-page-head { padding: 36px 0 8px; }
.gn-page-title { margin: 0 0 6px; }
.gn-page-sub { color: var(--gn-muted); margin: 0 0 18px; }
.gn-empty { color: var(--gn-muted); padding: 30px 0; }

/* Grid */
.gn-listings-grid { display: grid; gap: 22px; grid-template-columns: repeat(3, 1fr); margin: 18px 0 30px; }
.gn-listings-grid.gn-cols-1 { grid-template-columns: 1fr; }
.gn-listings-grid.gn-cols-2 { grid-template-columns: repeat(2, 1fr); }
.gn-listings-grid.gn-cols-4 { grid-template-columns: repeat(4, 1fr); }
@media (max-width: 900px) { .gn-listings-grid, .gn-listings-grid.gn-cols-4 { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 580px) { .gn-listings-grid, .gn-listings-grid.gn-cols-2, .gn-listings-grid.gn-cols-4 { grid-template-columns: 1fr; } }

/* Card */
.gn-card { background: var(--gn-card-bg); border: 1px solid var(--gn-line); border-radius: var(--gn-radius); overflow: hidden; transition: box-shadow .18s ease, transform .18s ease; display: flex; flex-direction: column; }
.gn-card:hover { transform: translateY(-3px); box-shadow: 0 14px 34px rgba(16, 24, 40, .12); }
.gn-card-photo { display: block; position: relative; aspect-ratio: 4 / 3; background: #eef1f5; overflow: hidden; }
.gn-card-photo img { width: 100%; height: 100%; object-fit: cover; display: block; }
.gn-card-nophoto { display: grid; place-items: center; height: 100%; color: #b8c0cc; }
.gn-card-badge { position: absolute; top: 10px; left: 10px; background: rgba(17, 24, 39, .82); color: #fff; font-size: 11px; font-weight: 600; letter-spacing: .05em; text-transform: uppercase; padding: 4px 10px; border-radius: 6px; }
.gn-card-deal { position: absolute; bottom: 10px; left: 10px; font-size: 11px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; padding: 4px 10px; border-radius: 6px; }
.gn-deal-sale { background: #16a34a; color: #fff; }
.gn-deal-lease { background: #7c3aed; color: #fff; }
.gn-card-body { padding: 16px 18px 18px; display: flex; flex-direction: column; gap: 4px; }
.gn-card-price { font-size: 1.2rem; font-weight: 700; color: var(--gn-text); }
.gn-card-address { margin: 0; font-size: 1rem; line-height: 1.35; }
.gn-card-address a { color: var(--gn-text); text-decoration: none; }
.gn-card-address a:hover { color: var(--gn-accent-dark); }
.gn-card-city { color: var(--gn-muted); font-size: .86rem; }
.gn-card-specs { list-style: none; display: flex; flex-wrap: wrap; gap: 8px; margin: 10px 0 0; padding: 10px 0 0; border-top: 1px solid var(--gn-line); }
.gn-card-specs li { margin: 0; display: inline-flex; align-items: center; gap: 5px; background: rgba(59,130,246,.06); border: 1px solid rgba(59,130,246,.15); border-radius: 8px; padding: 5px 10px; font-size: .82rem; }
.gn-card-specs strong { color: var(--gn-text); font-size: .9rem; }
.gn-spec-icon { width: 15px; height: 15px; color: var(--gn-accent); flex: none; }
.gn-spec-lbl { color: var(--gn-muted); }

/* Single-listing stat bar */
.gn-stat-bar { display: flex; flex-wrap: wrap; gap: 10px; margin: 16px 0 6px; }
.gn-stat { display: flex; flex-direction: column; align-items: center; justify-content: center; background: var(--gn-card-bg); border: 1px solid var(--gn-line); border-radius: 14px; padding: 14px 20px; min-width: 80px; text-align: center; gap: 4px; box-shadow: 0 1px 4px rgba(16,24,40,.06); }
.gn-stat-icon { width: 22px; height: 22px; color: var(--gn-accent); }
.gn-stat-val { font-size: 1.35rem; font-weight: 700; color: var(--gn-text); line-height: 1; }
.gn-stat-lbl { font-size: .68rem; color: var(--gn-muted); font-weight: 600; text-transform: uppercase; letter-spacing: .04em; }
@media (max-width: 480px) { .gn-stat { padding: 11px 16px; min-width: 68px; } .gn-stat-val { font-size: 1.15rem; } }

/* Property type badge on single listing */
.gn-prop-type-badge { display: inline-block; background: rgba(59,130,246,.1); color: var(--gn-accent-dark); font-size: .78rem; font-weight: 600; padding: 4px 12px; border-radius: 99px; margin-bottom: 10px; letter-spacing: .02em; }
.gn-card-meta { display: flex; flex-wrap: wrap; gap: 4px 10px; margin-top: 8px; font-size: .74rem; color: var(--gn-muted); border-top: 1px solid var(--gn-line); padding-top: 8px; }
.gn-card-mlskey { font-weight: 600; letter-spacing: .02em; }
.gn-card-mlskey::before { content: "MLS® "; }
.gn-card-office { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 100%; }
.gn-card-also-listed { font-style: italic; }
.gn-also-listed { font-size: .82rem; color: var(--gn-muted); margin: 6px 0 14px; }

/* Pagination */
.gn-pagination { margin: 12px 0 40px; }
.gn-pagination ul { list-style: none; display: flex; justify-content: center; align-items: center; gap: 4px; padding: 0; margin: 0; flex-wrap: wrap; }
.gn-pagination li { margin: 0; }
.gn-pagination .page-numbers { display: inline-flex; align-items: center; justify-content: center; min-width: 40px; height: 40px; padding: 0 10px; border: 1px solid var(--gn-line); border-radius: 10px; text-decoration: none; color: var(--gn-text); font-size: .9rem; font-weight: 500; transition: background .15s ease, border-color .15s ease, color .15s ease; background: var(--gn-card-bg); }
.gn-pagination a.page-numbers:hover { border-color: var(--gn-accent); color: var(--gn-accent-dark); background: rgba(59,130,246,.06); }
.gn-pagination .page-numbers.current { background: var(--gn-accent); border-color: var(--gn-accent); color: #fff; font-weight: 700; box-shadow: 0 2px 8px rgba(59,130,246,.3); }
.gn-pagination .page-numbers.dots { border: none; background: none; color: var(--gn-muted); cursor: default; min-width: 28px; }
.gn-pagination .page-numbers.prev, .gn-pagination .page-numbers.next { font-size: 1.1rem; font-weight: 700; }

/* Single */
.gn-single { padding: 28px 0 50px; }

/* Photo mosaic (Zillow/HouseSigma-style — constrained height, not oversized) */
.gn-mosaic { position: relative; display: grid; grid-template-columns: 2fr 1fr; gap: 8px; height: 440px; border-radius: var(--gn-radius); overflow: hidden; }
.gn-mosaic-hero, .gn-mosaic-cell { padding: 0; border: 0; cursor: pointer; background: #eef1f5; overflow: hidden; position: relative; }
.gn-mosaic-hero img, .gn-mosaic-cell img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .25s ease; }
.gn-mosaic-hero:hover img, .gn-mosaic-cell:hover img { transform: scale(1.04); }
.gn-mosaic-side { display: grid; grid-template-columns: 1fr 1fr; grid-template-rows: 1fr 1fr; gap: 8px; }
.gn-mosaic-overlay { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 10px; background: rgba(17, 24, 39, .5); color: #fff; }
.gn-mosaic-more { font-size: 1.3rem; font-weight: 700; line-height: 1; }
.gn-mosaic-viewall { display: inline-flex; align-items: center; gap: 8px; background: #fff; color: var(--gn-text); border: 1px solid var(--gn-line); border-radius: 10px; padding: 9px 14px; font-size: .82rem; font-weight: 600; cursor: pointer; box-shadow: 0 2px 8px rgba(16,24,40,.2); white-space: nowrap; }
.gn-mosaic-cell:hover .gn-mosaic-viewall { background: var(--gn-accent); color: #fff; border-color: var(--gn-accent); }
.gn-mosaic-viewall-solo { position: absolute; right: 14px; bottom: 14px; }
/* When there's no +X overflow, the overlay only holds the button: keep it subtle until hover */
.gn-mosaic-cell-last .gn-mosaic-overlay { background: rgba(17,24,39,.18); }
.gn-mosaic-cell-last .gn-mosaic-overlay.has-more { background: rgba(17,24,39,.5); }
.gn-mosaic-cell-last:hover .gn-mosaic-overlay { background: rgba(17,24,39,.45); }
.gn-mosaic-mobile-count { display: none; }
@media (max-width: 760px) {
	.gn-mosaic { grid-template-columns: 1fr; height: auto; }
	.gn-mosaic-hero { aspect-ratio: 4 / 3; }
	.gn-mosaic-side { display: none; }
	.gn-mosaic-mobile-count { display: inline-flex; align-items: center; gap: 6px; position: absolute; right: 12px; bottom: 12px; z-index: 4; background: rgba(17,24,39,.78); color: #fff; font-size: .82rem; font-weight: 600; padding: 8px 13px; border-radius: 8px; }
	.gn-mosaic-mobile-count::before { content: ""; width: 15px; height: 15px; background: currentColor; -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='2'%3E%3Crect x='3' y='3' width='7' height='7' rx='1'/%3E%3Crect x='14' y='3' width='7' height='7' rx='1'/%3E%3Crect x='3' y='14' width='7' height='7' rx='1'/%3E%3Crect x='14' y='14' width='7' height='7' rx='1'/%3E%3C/svg%3E") center/contain no-repeat; mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='2'%3E%3Crect x='3' y='3' width='7' height='7' rx='1'/%3E%3Crect x='14' y='3' width='7' height='7' rx='1'/%3E%3Crect x='3' y='14' width='7' height='7' rx='1'/%3E%3Crect x='14' y='14' width='7' height='7' rx='1'/%3E%3C/svg%3E") center/contain no-repeat; }
}

/* Lightbox */
.gn-lightbox { position: fixed; inset: 0; z-index: 9999; background: rgba(10, 15, 25, .94); display: flex; align-items: center; justify-content: center; }
.gn-lightbox[hidden] { display: none; }
.gn-lb-stage { margin: 0; max-width: 92vw; max-height: 86vh; display: flex; flex-direction: column; align-items: center; }
.gn-lb-stage img { max-width: 92vw; max-height: 80vh; object-fit: contain; border-radius: 6px; }
.gn-lb-counter { color: #cbd5e1; font-size: .85rem; margin-top: 12px; }
.gn-lb-close { position: absolute; top: 18px; right: 24px; display: flex; align-items: center; justify-content: center; width: 44px; height: 44px; padding: 0; background: none; border: 0; color: #fff; font-size: 2.2rem; line-height: 1; cursor: pointer; z-index: 3; }
/* Arrows are absolutely centered on the viewport edges (not flex siblings of the
   image) so they never drift out of alignment with the photo. */
.gn-lb-nav { position: absolute; top: 50%; transform: translateY(-50%); display: flex; align-items: center; justify-content: center; width: 52px; height: 52px; padding: 0; margin: 0; background: rgba(255,255,255,.14); border: 0; border-radius: 50%; color: #fff; font-size: 2rem; line-height: 1; cursor: pointer; z-index: 2; }
.gn-lb-nav:hover { background: rgba(255,255,255,.28); }
.gn-lb-prev { left: 20px; }
.gn-lb-next { right: 20px; }
@media (max-width: 600px) {
	.gn-lb-nav { width: 44px; height: 44px; font-size: 1.7rem; background: rgba(0,0,0,.45); }
	.gn-lb-prev { left: 10px; }
	.gn-lb-next { right: 10px; }
}

.gn-single-grid { display: grid; grid-template-columns: 1fr 320px; gap: 34px; margin-top: 28px; }
@media (max-width: 880px) { .gn-single-grid { grid-template-columns: 1fr; } }
.gn-single-price { font-size: 1.7rem; font-weight: 700; color: var(--gn-text); }
.gn-single-address { margin: 4px 0 2px; font-size: 1.4rem; }
.gn-single-city { color: var(--gn-muted); margin: 0 0 12px; }

.gn-single-section { margin-top: 30px; }
.gn-single-section h2 { font-size: 1.15rem; margin: 0 0 12px; }
.gn-single-content { color: var(--gn-text); line-height: 1.7; }

.gn-details-table { width: 100%; border-collapse: collapse; font-size: .92rem; }
.gn-details-table th, .gn-details-table td { text-align: left; padding: 10px 12px; border-bottom: 1px solid var(--gn-line); }
.gn-details-table th { color: var(--gn-muted); font-weight: 500; width: 40%; }

.gn-contact-card { background: var(--gn-card-bg); border: 1px solid var(--gn-line); border-radius: var(--gn-radius); padding: 22px; position: sticky; top: 90px; }
.gn-contact-card h3 { margin: 0 0 8px; font-size: 1.05rem; }
.gn-contact-card p { color: var(--gn-muted); font-size: .9rem; margin: 0 0 14px; }
.gn-agent-line { margin-top: 14px !important; border-top: 1px solid var(--gn-line); padding-top: 12px; font-size: .85rem !important; }

.gn-btn { display: inline-block; padding: 12px 20px; border-radius: 10px; font-weight: 600; text-decoration: none; text-align: center; transition: background .15s ease; }
.gn-btn-primary { background: var(--gn-accent); color: #fff !important; width: 100%; box-sizing: border-box; }
.gn-btn-primary:hover { background: var(--gn-accent-dark); }
.gn-btn-ghost { border: 1px solid var(--gn-line); color: var(--gn-text); }
.gn-btn-ghost:hover { border-color: var(--gn-accent); color: var(--gn-accent-dark); }

.gn-disclaimer { margin-top: 40px; font-size: .74rem; color: var(--gn-muted); line-height: 1.6; border-top: 1px solid var(--gn-line); padding-top: 16px; }

@media (prefers-reduced-motion: reduce) {
	.gn-card, .gn-btn { transition: none; }
}

/* Search & filters */
.gn-filter-form { background: var(--gn-card-bg); border: 1px solid var(--gn-line); border-radius: var(--gn-radius); padding: 18px 18px 14px; margin: 10px 0 22px; }
.gn-filter-row { display: grid; gap: 14px; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); align-items: end; }
.gn-filter-row + .gn-filter-row, .gn-filter-more, .gn-filter-actions { margin-top: 14px; }
.gn-filter-field label { display: block; font-size: .74rem; font-weight: 600; letter-spacing: .03em; text-transform: uppercase; color: var(--gn-muted); margin-bottom: 5px; }
.gn-filter-field input, .gn-filter-field select { width: 100%; box-sizing: border-box; padding: 10px 12px; border: 1px solid var(--gn-line); border-radius: 9px; font-size: .92rem; color: var(--gn-text); background: #fff; }
.gn-filter-field input:focus, .gn-filter-field select:focus { outline: 2px solid var(--gn-accent); outline-offset: 1px; border-color: var(--gn-accent); }
.gn-filter-keyword { grid-column: span 2; }
@media (max-width: 580px) { .gn-filter-keyword { grid-column: span 1; } }
.gn-filter-more summary { cursor: pointer; font-size: .88rem; font-weight: 600; color: var(--gn-accent-dark); padding: 4px 0; }
.gn-filter-more[open] summary { margin-bottom: 10px; }
.gn-filter-actions { display: flex; align-items: center; gap: 16px; }
.gn-filter-actions .gn-filter-submit { min-width: 200px; }
@media (max-width: 580px) { .gn-filter-actions { flex-direction: column; align-items: stretch; } }
.gn-filter-submit { border: none; cursor: pointer; font-size: .95rem; }
.gn-filter-reset { align-self: center; font-size: .86rem; color: var(--gn-muted); text-decoration: underline; }
.gn-filter-reset:hover { color: var(--gn-accent-dark); }
.gn-results-count { color: var(--gn-muted); font-size: .9rem; margin: 0 0 6px; }

/* AJAX loading state */
[data-gn-results].gn-loading { opacity: .45; pointer-events: none; transition: opacity .15s ease; }

/* Save search */
.gn-save-search { margin-top: 14px; border-top: 1px dashed var(--gn-line); padding-top: 12px; }
.gn-save-search summary { cursor: pointer; font-size: .88rem; font-weight: 600; color: var(--gn-accent-dark); }
.gn-save-row { margin-top: 12px; grid-template-columns: 1fr 1fr auto; }
@media (max-width: 700px) { .gn-save-row { grid-template-columns: 1fr; } }
.gn-save-msg { font-size: .85rem; margin: 8px 0 0; }
.gn-save-msg.is-ok { color: #047857; }
.gn-save-msg.is-err { color: #b91c1c; }

/* Saved searches manager */
.gn-saved-list { list-style: none; padding: 0; margin: 16px 0; }
.gn-saved-item { display: grid; grid-template-columns: 1fr 2fr auto; gap: 14px; align-items: center; background: var(--gn-card-bg); border: 1px solid var(--gn-line); border-radius: 12px; padding: 14px 18px; margin-bottom: 10px; }
@media (max-width: 700px) { .gn-saved-item { grid-template-columns: 1fr; gap: 6px; } }
.gn-saved-name { font-weight: 700; color: var(--gn-text); }
.gn-saved-meta { color: var(--gn-muted); font-size: .85rem; }
.gn-saved-actions .gn-btn { padding: 8px 14px; font-size: .84rem; }
.gn-saved-delete { cursor: pointer; }

/* Key facts grid */
.gn-facts-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 10px; }
.gn-facts { display: flex; flex-direction: column; gap: 22px; }
.gn-fact-group-title { font-size: .8rem; text-transform: uppercase; letter-spacing: .06em; color: var(--gn-muted); margin: 0 0 10px; padding-bottom: 8px; border-bottom: 2px solid var(--gn-accent); display: inline-block; }
.gn-fact { background: var(--gn-card-bg); border: 1px solid var(--gn-line); border-radius: 10px; padding: 12px 14px; }
.gn-fact-label { display: block; font-size: .7rem; font-weight: 600; text-transform: uppercase; letter-spacing: .04em; color: var(--gn-muted); }
.gn-fact-value { display: block; font-size: .92rem; color: var(--gn-text); margin-top: 2px; }
.gn-original-price { color: var(--gn-muted); font-size: .88rem; margin: 0 0 10px; }

/* Feature chips */
.gn-feature-group { margin-bottom: 14px; }
.gn-feature-title { font-size: .8rem; text-transform: uppercase; letter-spacing: .05em; color: var(--gn-muted); margin: 0 0 8px; }
.gn-chips { list-style: none; display: flex; flex-wrap: wrap; gap: 8px; padding: 0; margin: 0; }
.gn-chip-item { background: var(--gn-card-bg); border: 1px solid var(--gn-line); border-radius: 99px; padding: 6px 14px; font-size: .82rem; color: var(--gn-text); }

/* Rooms table */
.gn-rooms-table thead th { color: var(--gn-muted); font-weight: 600; font-size: .78rem; text-transform: uppercase; letter-spacing: .04em; }

/* Lead form */
.gn-lead-form .gn-filter-field { margin-bottom: 12px; }
.gn-lead-form textarea { width: 100%; box-sizing: border-box; padding: 10px 12px; border: 1px solid var(--gn-line); border-radius: 9px; font-size: .92rem; color: var(--gn-text); font-family: inherit; resize: vertical; }
.gn-lead-form textarea:focus { outline: 2px solid var(--gn-accent); outline-offset: 1px; border-color: var(--gn-accent); }
.gn-lead-form .gn-btn { width: 100%; border: none; cursor: pointer; }

/* Active filter chips */
.gn-active-filters { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin: 0 0 18px; }
.gn-active-label { font-size: .82rem; color: var(--gn-muted); font-weight: 600; }
.gn-chip-remove { display: inline-flex; align-items: center; gap: 8px; background: var(--gn-accent); color: #fff; border: none; border-radius: 99px; padding: 6px 12px; font-size: .82rem; cursor: pointer; transition: background .15s ease; }
.gn-chip-remove:hover { background: var(--gn-accent-dark); }
.gn-chip-remove span[aria-hidden] { font-size: 1.05rem; line-height: 1; opacity: .85; }
.gn-chip-clear { background: transparent; border: 1px solid var(--gn-line); color: var(--gn-muted); border-radius: 99px; padding: 6px 14px; font-size: .82rem; cursor: pointer; }
.gn-chip-clear:hover { border-color: var(--gn-accent); color: var(--gn-accent-dark); }
.screen-reader-text { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(1px,1px,1px,1px); white-space: nowrap; }

/* Breadcrumb */
.gn-breadcrumb { margin: 4px 0 16px; font-size: .82rem; }
.gn-breadcrumb ol { list-style: none; display: flex; flex-wrap: wrap; align-items: center; gap: 6px; padding: 0; margin: 0; }
.gn-breadcrumb li { display: inline-flex; align-items: center; gap: 6px; color: var(--gn-muted); }
.gn-breadcrumb li:not(:last-child)::after { content: "/"; color: var(--gn-line); margin-left: 6px; }
.gn-breadcrumb a { color: var(--gn-accent-dark); text-decoration: none; }
.gn-breadcrumb a:hover { text-decoration: underline; }
.gn-breadcrumb span[aria-current] { color: var(--gn-text); font-weight: 600; max-width: 280px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
@media (max-width: 600px) { .gn-breadcrumb span[aria-current] { max-width: 160px; } }

/* Multi-select checkbox dropdown */
.gn-ms { position: relative; }
.gn-ms-toggle { width: 100%; box-sizing: border-box; display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 10px 12px; border: 1px solid var(--gn-line); border-radius: 9px; background: #fff; color: var(--gn-text); font-size: .92rem; cursor: pointer; text-align: left; }
.gn-ms-toggle:focus { outline: 2px solid var(--gn-accent); outline-offset: 1px; }
.gn-ms.has-selection .gn-ms-toggle { border-color: var(--gn-accent); color: var(--gn-accent-dark); font-weight: 600; }
.gn-ms-caret { color: var(--gn-muted); font-size: .8rem; }
.gn-ms-menu { position: absolute; z-index: 30; top: calc(100% + 4px); left: 0; right: 0; background: #fff; border: 1px solid var(--gn-line); border-radius: 10px; box-shadow: 0 12px 30px rgba(16,24,40,.16); padding: 6px; }
.gn-ms-menu[hidden] { display: none; }
.gn-ms-search { padding: 2px 2px 6px; position: sticky; top: 0; background: #fff; }
.gn-ms-search input { width: 100%; box-sizing: border-box; padding: 8px 10px; border: 1px solid var(--gn-line); border-radius: 8px; font-size: .88rem; }
.gn-ms-search input:focus { outline: 2px solid var(--gn-accent); outline-offset: 1px; border-color: var(--gn-accent); }
.gn-ms-options { max-height: 230px; overflow-y: auto; }
.gn-ms-option { display: flex; align-items: center; gap: 10px; padding: 9px 10px; border-radius: 8px; font-size: .9rem; cursor: pointer; color: var(--gn-text); user-select: none; }
.gn-ms-option:hover { background: rgba(59,130,246,.08); }
/* Self-contained checkbox so themes can't desync the box and the tick. */
.gn-ms-option input[type="checkbox"] {
	appearance: none; -webkit-appearance: none; -moz-appearance: none;
	width: 18px; height: 18px; min-width: 18px; margin: 0; padding: 0; flex: none;
	border: 1.5px solid #c4cad4; border-radius: 4px; background: #fff;
	position: relative; cursor: pointer; box-shadow: none; vertical-align: middle;
	transition: background .12s ease, border-color .12s ease;
}
.gn-ms-option input[type="checkbox"]::before { content: none !important; }
.gn-ms-option input[type="checkbox"]:checked { background: var(--gn-accent); border-color: var(--gn-accent); }
.gn-ms-option input[type="checkbox"]:checked::after {
	content: ""; position: absolute; left: 5px; top: 2px; width: 4px; height: 8px;
	border: solid #fff; border-width: 0 2px 2px 0; transform: rotate(45deg); box-sizing: content-box;
}
.gn-ms-option input[type="checkbox"]:focus-visible { outline: 2px solid var(--gn-accent); outline-offset: 1px; }
.gn-ms-option span { line-height: 1.3; }
.gn-ms-empty { color: var(--gn-muted); font-size: .85rem; padding: 10px; margin: 0; }
.gn-ms.is-disabled { opacity: .6; }
.gn-ms.is-disabled .gn-ms-toggle { cursor: not-allowed; background: #f6f7f9; color: var(--gn-muted); border-color: var(--gn-line); font-weight: 400; }

/* Filter header: deal toggle (left) + sort (right) */
.gn-filter-header { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 12px; margin-bottom: 14px; }
.gn-filter-header .gn-deal-toggle { margin: 0; }
.gn-sort { display: inline-flex; align-items: center; gap: 8px; margin-left: auto; }
.gn-sort label { font-size: .74rem; font-weight: 600; letter-spacing: .03em; text-transform: uppercase; color: var(--gn-muted); white-space: nowrap; }
.gn-sort select { padding: 9px 12px; border: 1px solid var(--gn-line); border-radius: 9px; font-size: .9rem; color: var(--gn-text); background: #fff; cursor: pointer; }
.gn-sort select:focus { outline: 2px solid var(--gn-accent); outline-offset: 1px; border-color: var(--gn-accent); }

/* Property-type segmented toggle + connected More dropdown */
.gn-type-filter { margin: 0 0 14px; }
.gn-type-filter-label { display: block; font-size: .74rem; font-weight: 600; letter-spacing: .03em; text-transform: uppercase; color: var(--gn-muted); margin-bottom: 6px; }
.gn-type-seg { display: inline-flex; flex-wrap: wrap; border: 1px solid var(--gn-line); border-radius: 10px; overflow: visible; background: var(--gn-card-bg); }
.gn-type-btn { position: relative; margin: 0; display: inline-flex; align-items: center; padding: 10px 18px; font-size: .88rem; font-weight: 600; color: var(--gn-muted); cursor: pointer; border-left: 1px solid var(--gn-line); transition: background .15s ease, color .15s ease; }
.gn-type-btn:first-child { border-left: 0; border-radius: 10px 0 0 10px; }
.gn-type-btn input { position: absolute; opacity: 0; width: 0; height: 0; pointer-events: none; }
.gn-type-btn:hover { color: var(--gn-accent-dark); background: rgba(59,130,246,.06); }
.gn-type-btn.is-active { background: var(--gn-accent); color: #fff; }
.gn-type-more { position: relative; border-left: 1px solid var(--gn-line); }
.gn-type-more-toggle { height: 100%; display: inline-flex; align-items: center; gap: 6px; border: 0; background: var(--gn-card-bg); color: var(--gn-muted); padding: 10px 16px; font-size: .88rem; font-weight: 600; cursor: pointer; border-radius: 0 10px 10px 0; }
.gn-type-more-toggle:hover { color: var(--gn-accent-dark); background: rgba(59,130,246,.06); }
.gn-type-more-toggle.has-selection { color: var(--gn-accent-dark); }
.gn-type-more-menu { position: absolute; z-index: 30; top: calc(100% + 4px); right: 0; min-width: 200px; background: #fff; border: 1px solid var(--gn-line); border-radius: 10px; box-shadow: 0 12px 30px rgba(16,24,40,.16); padding: 6px; }
.gn-type-more-menu[hidden] { display: none; }
@media (max-width: 560px) {
	.gn-type-seg { display: flex; width: 100%; }
	.gn-type-btn { flex: 1 1 auto; justify-content: center; padding: 10px 8px; }
}

/* Sale / Lease toggle */
.gn-deal-toggle { display: inline-flex; border: 1px solid var(--gn-line); border-radius: 10px; overflow: hidden; margin: 0 0 14px; }
.gn-deal-btn { border: none; background: var(--gn-card-bg); color: var(--gn-muted); padding: 9px 18px; font-size: .88rem; font-weight: 600; cursor: pointer; }
.gn-deal-btn + .gn-deal-btn { border-left: 1px solid var(--gn-line); }
.gn-deal-btn.is-active { background: var(--gn-accent); color: #fff; }

/* Image loading spinner + fade-in */
.gn-img-loader { position: absolute; inset: 0; display: grid; place-items: center; background: linear-gradient(110deg, #eef1f5 8%, #e3e7ee 18%, #eef1f5 33%); background-size: 200% 100%; animation: gn-shimmer 1.4s linear infinite; z-index: 1; }
.gn-img-loader.is-hidden { display: none; }
.gn-spinner-svg { width: 38px; height: 38px; animation: gn-rotate 1s linear infinite; }
.gn-spinner-track { stroke: rgba(59,130,246,.18); }
.gn-spinner-arc { stroke: var(--gn-accent); stroke-linecap: round; stroke-dasharray: 90 150; }
/* Card images: simple opacity fade in normal flow. */
.gn-card-photo .gn-img-fade { opacity: 0; transition: opacity .35s ease; }
.gn-card-photo .gn-img-fade.is-loaded { opacity: 1; }
/* Mosaic images: keep them absolutely filling their cell so the relative
   loader never alters layout (was causing overflow / repeated images). */
.gn-mosaic-hero .gn-img-fade, .gn-mosaic-cell .gn-img-fade { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: 0; transition: opacity .35s ease; z-index: 2; }
.gn-mosaic-hero .gn-img-fade.is-loaded, .gn-mosaic-cell .gn-img-fade.is-loaded { opacity: 1; }
/* Overlay must sit above the faded image. */
.gn-mosaic-overlay { z-index: 3; }
@keyframes gn-rotate { to { transform: rotate(360deg); } }
@keyframes gn-shimmer { to { background-position: -200% 0; } }
@media (prefers-reduced-motion: reduce) {
	.gn-img-loader { animation: none; }
	.gn-spinner-svg { animation-duration: 2s; }
	.gn-img-fade { transition: none; }
}

/* Mobile: keep mosaic overlay/loader legible on the single hero */
@media (max-width: 760px) {
	.gn-mosaic-viewall { font-size: .8rem; padding: 8px 12px; }
	.gn-mosaic-more { font-size: 1.1rem; }
	.gn-img-loader .gn-spinner-svg { width: 32px; height: 32px; }
}
