/**
 * NSBM Real Estate Manager — frontend styles.
 * Every colour, radius and font comes from the settings screen via CSS variables.
 */

.nsbmre-scope {
	--nsbmre-gap: 24px;
	color: var(--nsbmre-text);
	font-family: var(--nsbmre-font-body);
	font-size: var(--nsbmre-font-size);
	line-height: 1.55;
	box-sizing: border-box;
}

.nsbmre-scope *,
.nsbmre-scope *::before,
.nsbmre-scope *::after {
	box-sizing: inherit;
}

/*
 * The hidden attribute is only display:none in the browser's own stylesheet, so
 * any author rule that sets display (the spinner is display:flex) silently wins
 * and the element stays visible. This keeps hidden meaning hidden.
 */
.nsbmre-scope [hidden] {
	display: none !important;
}

.nsbmre-scope h1,
.nsbmre-scope h2,
.nsbmre-scope h3 {
	font-family: var(--nsbmre-font-heading);
	color: var(--nsbmre-accent);
	margin: 0 0 .5em;
	line-height: 1.25;
}

.nsbmre-container {
	max-width: 1240px;
	margin: 0 auto;
	padding: 32px 16px 64px;
}

/* ------------------------------------------------------------------ Layout */

.nsbmre-listings {
	display: grid;
	grid-template-columns: 300px minmax(0, 1fr);
	gap: var(--nsbmre-gap);
	align-items: start;
}

.nsbmre-listings.nsbmre-sidebar-right {
	grid-template-columns: minmax(0, 1fr) 300px;
}

.nsbmre-listings.nsbmre-sidebar-right .nsbmre-sidebar {
	order: 2;
}

.nsbmre-listings.nsbmre-sidebar-none {
	grid-template-columns: minmax(0, 1fr);
}

.nsbmre-listings.nsbmre-sidebar-none .nsbmre-sidebar {
	display: none;
}

.nsbmre-main {
	min-width: 0;
}

/* ----------------------------------------------------------------- Sidebar */

.nsbmre-sidebar {
	background: var(--nsbmre-card-bg);
	border: 1px solid var(--nsbmre-border);
	border-radius: var(--nsbmre-radius);
	padding: 20px;
	box-shadow: var(--nsbmre-shadow);
	position: sticky;
	top: 24px;
}

.nsbmre-filter-group {
	margin-bottom: 18px;
}

.nsbmre-filter-group:last-of-type {
	margin-bottom: 0;
}

.nsbmre-filter-label {
	display: block;
	font-size: .78em;
	font-weight: 600;
	letter-spacing: .04em;
	text-transform: uppercase;
	color: var(--nsbmre-accent);
	margin-bottom: 6px;
}

.nsbmre-scope select,
.nsbmre-scope input[type="text"],
.nsbmre-scope input[type="search"],
.nsbmre-scope input[type="number"],
.nsbmre-scope input[type="email"] {
	width: 100%;
	padding: 9px 11px;
	border: 1px solid var(--nsbmre-border);
	border-radius: var(--nsbmre-radius);
	background: #fff;
	color: var(--nsbmre-text);
	font-size: .95em;
	font-family: inherit;
	line-height: 1.4;
	max-width: 100%;
}

.nsbmre-scope select:focus,
.nsbmre-scope input:focus {
	outline: 2px solid color-mix(in srgb, var(--nsbmre-highlight) 45%, transparent);
	outline-offset: 1px;
	border-color: var(--nsbmre-highlight);
}

.nsbmre-search-wrap {
	position: relative;
}

.nsbmre-suggestions {
	position: absolute;
	z-index: 40;
	top: calc(100% + 4px);
	left: 0;
	right: 0;
	margin: 0;
	padding: 4px;
	list-style: none;
	background: #fff;
	border: 1px solid var(--nsbmre-border);
	border-radius: var(--nsbmre-radius);
	box-shadow: 0 8px 24px rgba(16, 24, 40, .12);
	max-height: 280px;
	overflow-y: auto;
}

.nsbmre-suggestions li {
	margin: 0;
}

.nsbmre-suggestions button {
	display: flex;
	justify-content: space-between;
	gap: 8px;
	width: 100%;
	padding: 8px 10px;
	background: none;
	border: 0;
	border-radius: var(--nsbmre-radius);
	text-align: left;
	cursor: pointer;
	font: inherit;
	color: var(--nsbmre-text);
}

.nsbmre-suggestions button:hover,
.nsbmre-suggestions button:focus {
	background: color-mix(in srgb, var(--nsbmre-highlight) 12%, transparent);
}

.nsbmre-suggestions .nsbmre-suggestion-type {
	color: var(--nsbmre-muted);
	font-size: .82em;
	white-space: nowrap;
}

.nsbmre-range-inputs {
	display: flex;
	align-items: center;
	gap: 8px;
}

.nsbmre-range-dash {
	color: var(--nsbmre-muted);
}

.nsbmre-range-hint,
.nsbmre-range-output {
	margin: 6px 0 0;
	font-size: .82em;
	color: var(--nsbmre-muted);
}

.nsbmre-checklist {
	list-style: none;
	margin: 0;
	padding: 0;
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 4px 10px;
}

.nsbmre-checklist label,
.nsbmre-check-inline {
	display: flex;
	align-items: center;
	gap: 6px;
	font-size: .9em;
	cursor: pointer;
}

.nsbmre-checklist input,
.nsbmre-check-inline input {
	margin: 0;
	flex: 0 0 auto;
}

.nsbmre-collapse-toggle {
	display: flex;
	justify-content: space-between;
	align-items: center;
	width: 100%;
	padding: 0 0 6px;
	background: none;
	border: 0;
	border-bottom: 1px solid var(--nsbmre-border);
	margin-bottom: 10px;
	font: inherit;
	font-size: .78em;
	font-weight: 600;
	letter-spacing: .04em;
	text-transform: uppercase;
	color: var(--nsbmre-accent);
	cursor: pointer;
}

.nsbmre-collapse-toggle::after {
	content: "−";
	font-size: 1.3em;
	line-height: 1;
}

.nsbmre-collapse-toggle[aria-expanded="false"]::after {
	content: "+";
}

.nsbmre-filter-actions {
	margin-top: 18px;
	padding-top: 14px;
	border-top: 1px solid var(--nsbmre-border);
}

/* ------------------------------------------------------- Dual range slider */

.nsbmre-dual-range {
	position: relative;
	height: 28px;
	margin-top: 6px;
}

.nsbmre-dual-track {
	position: absolute;
	top: 12px;
	left: 0;
	right: 0;
	height: 4px;
	background: var(--nsbmre-border);
	border-radius: 4px;
}

.nsbmre-dual-fill {
	position: absolute;
	top: 0;
	bottom: 0;
	background: var(--nsbmre-highlight);
	border-radius: 4px;
}

.nsbmre-dual-range input[type="range"] {
	position: absolute;
	top: 4px;
	left: 0;
	width: 100%;
	margin: 0;
	background: none;
	pointer-events: none;
	-webkit-appearance: none;
	appearance: none;
	height: 20px;
}

.nsbmre-dual-range input[type="range"]::-webkit-slider-thumb {
	pointer-events: auto;
	-webkit-appearance: none;
	appearance: none;
	width: 16px;
	height: 16px;
	border-radius: 50%;
	background: var(--nsbmre-highlight);
	border: 2px solid #fff;
	box-shadow: 0 1px 3px rgba(16, 24, 40, .3);
	cursor: pointer;
}

.nsbmre-dual-range input[type="range"]::-moz-range-thumb {
	pointer-events: auto;
	width: 16px;
	height: 16px;
	border-radius: 50%;
	background: var(--nsbmre-highlight);
	border: 2px solid #fff;
	box-shadow: 0 1px 3px rgba(16, 24, 40, .3);
	cursor: pointer;
}

.nsbmre-dual-range input[type="range"]::-moz-range-track {
	background: none;
}

/* ----------------------------------------------------------------- Toolbar */

.nsbmre-toolbar {
	display: flex;
	flex-wrap: wrap;
	gap: 12px;
	align-items: center;
	justify-content: space-between;
	margin-bottom: 18px;
}

.nsbmre-toolbar-heading {
	margin: 0;
	font-size: 1.15em;
}

.nsbmre-count {
	color: var(--nsbmre-muted);
	font-size: .92em;
}

.nsbmre-count strong {
	color: var(--nsbmre-accent);
}

.nsbmre-toolbar-actions {
	display: flex;
	gap: 8px;
	align-items: center;
	flex-wrap: wrap;
}

.nsbmre-sort select {
	width: auto;
	min-width: 170px;
}

.nsbmre-filters-toggle {
	display: none;
}

/* ----------------------------------------------------------------- Buttons */

.nsbmre-scope .nsbmre-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 6px;
	padding: 9px 16px;
	border: 1px solid var(--nsbmre-primary);
	border-radius: var(--nsbmre-radius);
	background: var(--nsbmre-primary);
	color: #fff;
	font: inherit;
	font-size: .92em;
	font-weight: 500;
	line-height: 1.3;
	cursor: pointer;
	text-decoration: none;
	transition: filter .15s ease, background-color .15s ease;
}

.nsbmre-scope .nsbmre-btn:hover,
.nsbmre-scope .nsbmre-btn:focus {
	background: color-mix(in srgb, var(--nsbmre-primary) 84%, #fff);
	border-color: color-mix(in srgb, var(--nsbmre-primary) 84%, #fff);
	color: #fff;
}

.nsbmre-scope .nsbmre-btn-ghost {
	background: transparent;
	color: var(--nsbmre-accent);
	border-color: var(--nsbmre-border);
}

.nsbmre-scope .nsbmre-btn-ghost:hover,
.nsbmre-scope .nsbmre-btn-ghost:focus {
	color: var(--nsbmre-accent);
	background: color-mix(in srgb, var(--nsbmre-highlight) 10%, transparent);
}

.nsbmre-scope .nsbmre-btn-block {
	width: 100%;
}

/* -------------------------------------------------------------------- Grid */

.nsbmre-grid {
	display: grid;
	gap: var(--nsbmre-gap);
	grid-template-columns: repeat(3, minmax(0, 1fr));
}

.nsbmre-cols-1 { grid-template-columns: minmax(0, 1fr); }
.nsbmre-cols-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.nsbmre-cols-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.nsbmre-cols-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }

/* -------------------------------------------------------------------- Card */

.nsbmre-card {
	display: flex;
	flex-direction: column;
	background: var(--nsbmre-card-bg);
	border: 1px solid var(--nsbmre-border);
	border-radius: var(--nsbmre-radius);
	overflow: hidden;
	box-shadow: var(--nsbmre-shadow);
	transition: transform .18s ease, box-shadow .18s ease;
}

.nsbmre-card:hover {
	transform: translateY(-2px);
	box-shadow: 0 8px 24px rgba(16, 24, 40, .12);
}

.nsbmre-card-media {
	position: relative;
	display: block;
	aspect-ratio: 4 / 3;
	background: #eef1f4;
	overflow: hidden;
}

.nsbmre-card-media img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
	transition: transform .4s ease;
}

.nsbmre-card:hover .nsbmre-card-media img {
	transform: scale(1.04);
}

.nsbmre-card-noimage {
	position: absolute;
	inset: 0;
	background: repeating-linear-gradient(45deg, #eef1f4, #eef1f4 10px, #e6eaee 10px, #e6eaee 20px);
}

.nsbmre-card-badges {
	position: absolute;
	top: 10px;
	left: 10px;
	display: flex;
	gap: 6px;
	flex-wrap: wrap;
}

.nsbmre-badge {
	display: inline-block;
	padding: 4px 9px;
	border-radius: var(--nsbmre-radius);
	background: rgba(47, 61, 76, .88);
	color: #fff;
	font-size: .72em;
	font-weight: 600;
	letter-spacing: .03em;
	text-transform: uppercase;
}

.nsbmre-badge-featured {
	background: var(--nsbmre-highlight);
	color: #060606;
}

.nsbmre-badge-taken {
	background: #cc3232;
}

/* Rented / sold, shown only when the site keeps them in the list. */

.nsbmre-card-taken .nsbmre-card-media img {
	filter: grayscale(1);
	opacity: .75;
}

.nsbmre-card-taken .nsbmre-card-price {
	background: var(--nsbmre-muted);
}

.nsbmre-card-taken .nsbmre-card-title a {
	color: var(--nsbmre-muted);
}

.nsbmre-single-taken-notice {
	display: flex;
	align-items: center;
	gap: 8px;
	padding: 12px 16px;
	margin-bottom: 20px;
	border-left: 3px solid #cc3232;
	background: #fdf0f0;
	color: #8a1f1f;
	border-radius: var(--nsbmre-radius);
	font-size: .92em;
}

.nsbmre-card-body {
	padding: 16px 16px 12px;
	flex: 1 1 auto;
}

.nsbmre-card-type {
	display: block;
	font-size: .74em;
	font-weight: 600;
	letter-spacing: .06em;
	text-transform: uppercase;
	color: color-mix(in srgb, var(--nsbmre-highlight) 72%, #000);
	margin-bottom: 4px;
}

.nsbmre-card-title {
	font-size: 1.02em;
	margin: 0 0 4px;
	text-transform: var(--nsbmre-title-transform, none);
	letter-spacing: .01em;
}

.nsbmre-card-title a {
	color: var(--nsbmre-accent);
	text-decoration: none;
}

.nsbmre-card-title a:hover {
	color: var(--nsbmre-highlight);
}

.nsbmre-card-address {
	margin: 0 0 10px;
	font-size: .86em;
	color: var(--nsbmre-muted);
}

.nsbmre-card-specs {
	list-style: none;
	display: flex;
	flex-wrap: wrap;
	gap: 14px;
	margin: 0;
	padding: 0;
	font-size: .84em;
	color: var(--nsbmre-muted);
}

.nsbmre-card-specs li {
	display: flex;
	align-items: center;
	gap: 5px;
}

.nsbmre-card-excerpt {
	margin: 10px 0 0;
	font-size: .88em;
	color: var(--nsbmre-muted);
}

.nsbmre-card-footer {
	display: flex;
	align-items: stretch;
	justify-content: space-between;
	gap: 8px;
	border-top: 1px solid var(--nsbmre-border);
	background: color-mix(in srgb, var(--nsbmre-border) 45%, #fff);
}

.nsbmre-card-location {
	display: flex;
	align-items: center;
	gap: 6px;
	padding: 10px 14px;
	font-size: .85em;
	color: var(--nsbmre-muted);
	min-width: 0;
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
}

.nsbmre-card-price {
	display: flex;
	align-items: center;
	gap: 6px;
	padding: 10px 14px;
	background: var(--nsbmre-price-bg);
	color: #fff;
	font-weight: 600;
	white-space: nowrap;
}

.nsbmre-price-old {
	opacity: .7;
	font-weight: 400;
	font-size: .85em;
}

.nsbmre-price-period {
	font-weight: 400;
	font-size: .82em;
	opacity: .9;
}

/* ------------------------------------------------------------------- Icons */

.nsbmre-icon {
	display: inline-block;
	width: 14px;
	height: 14px;
	background: currentColor;
	flex: 0 0 auto;
	-webkit-mask-repeat: no-repeat;
	mask-repeat: no-repeat;
	-webkit-mask-position: center;
	mask-position: center;
	-webkit-mask-size: contain;
	mask-size: contain;
}

.nsbmre-icon-area {
	-webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M3 3h18v18H3z' fill='none' stroke='%23000' stroke-width='2'/%3E%3Cpath d='M7 3v4M3 7h4M17 21v-4M21 17h-4' stroke='%23000' stroke-width='2'/%3E%3C/svg%3E");
	mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M3 3h18v18H3z' fill='none' stroke='%23000' stroke-width='2'/%3E%3Cpath d='M7 3v4M3 7h4M17 21v-4M21 17h-4' stroke='%23000' stroke-width='2'/%3E%3C/svg%3E");
}

.nsbmre-icon-bed {
	-webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M2 18v-7a2 2 0 0 1 2-2h16a2 2 0 0 1 2 2v7M2 14h20M6 9V7a2 2 0 0 1 2-2h8a2 2 0 0 1 2 2v2' fill='none' stroke='%23000' stroke-width='2'/%3E%3C/svg%3E");
	mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M2 18v-7a2 2 0 0 1 2-2h16a2 2 0 0 1 2 2v7M2 14h20M6 9V7a2 2 0 0 1 2-2h8a2 2 0 0 1 2 2v2' fill='none' stroke='%23000' stroke-width='2'/%3E%3C/svg%3E");
}

.nsbmre-icon-bath {
	-webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M3 12h18v3a4 4 0 0 1-4 4H7a4 4 0 0 1-4-4v-3zM6 12V6a2 2 0 0 1 4 0' fill='none' stroke='%23000' stroke-width='2'/%3E%3C/svg%3E");
	mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M3 12h18v3a4 4 0 0 1-4 4H7a4 4 0 0 1-4-4v-3zM6 12V6a2 2 0 0 1 4 0' fill='none' stroke='%23000' stroke-width='2'/%3E%3C/svg%3E");
}

.nsbmre-icon-pin,
.nsbmre-icon-pin.nsbmre-icon {
	display: inline-block;
	width: 12px;
	height: 14px;
	background: currentColor;
	flex: 0 0 auto;
	-webkit-mask-repeat: no-repeat;
	mask-repeat: no-repeat;
	-webkit-mask-position: center;
	mask-position: center;
	-webkit-mask-size: contain;
	mask-size: contain;
	-webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M12 22s8-6.4 8-12a8 8 0 1 0-16 0c0 5.6 8 12 8 12z' fill='none' stroke='%23000' stroke-width='2'/%3E%3Ccircle cx='12' cy='10' r='3' fill='none' stroke='%23000' stroke-width='2'/%3E%3C/svg%3E");
	mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M12 22s8-6.4 8-12a8 8 0 1 0-16 0c0 5.6 8 12 8 12z' fill='none' stroke='%23000' stroke-width='2'/%3E%3Ccircle cx='12' cy='10' r='3' fill='none' stroke='%23000' stroke-width='2'/%3E%3C/svg%3E");
}

/*
 * Themes style h1–h4 aggressively and their selectors are often more specific
 * than a bare class, which made card titles balloon on some sites. These rules
 * are scoped and specific enough to win, so the plugin looks the same anywhere.
 */
.nsbmre-scope .nsbmre-card-title {
	font-size: 1.02em;
	line-height: 1.35;
	margin: 0 0 4px;
	font-weight: 600;
}

.nsbmre-scope .nsbmre-section-title {
	font-size: 1.1em;
	line-height: 1.35;
	margin: 0 0 14px;
}

.nsbmre-scope .nsbmre-single-title {
	font-size: 1.7em;
	line-height: 1.25;
	margin: 0 0 6px;
}

.nsbmre-scope .nsbmre-toolbar-heading {
	font-size: 1.15em;
	line-height: 1.3;
	margin: 0;
}

.nsbmre-scope .nsbmre-archive-title {
	font-size: 1.6em;
	line-height: 1.25;
	margin: 0;
}

.nsbmre-scope .nsbmre-card-body p,
.nsbmre-scope .nsbmre-card-specs {
	margin-top: 0;
}

/* --------------------------------------------------------------- Pagination */

.nsbmre-pagination {
	display: flex;
	flex-wrap: wrap;
	gap: 6px;
	justify-content: center;
	margin-top: 28px;
}

.nsbmre-scope .nsbmre-page {
	min-width: 38px;
	padding: 8px 12px;
	border: 1px solid var(--nsbmre-border);
	border-radius: var(--nsbmre-radius);
	background: var(--nsbmre-card-bg);
	color: var(--nsbmre-accent);
	font: inherit;
	font-size: .9em;
	cursor: pointer;
}

.nsbmre-scope .nsbmre-page:hover {
	border-color: var(--nsbmre-highlight);
	color: var(--nsbmre-highlight);
}

.nsbmre-scope .nsbmre-page.is-current {
	background: var(--nsbmre-highlight);
	border-color: var(--nsbmre-highlight);
	color: #060606;
	cursor: default;
}

.nsbmre-page-dots {
	padding: 8px 4px;
	color: var(--nsbmre-muted);
}

/* ------------------------------------------------------------ Empty/loading */

.nsbmre-empty {
	padding: 48px 24px;
	text-align: center;
	background: var(--nsbmre-card-bg);
	border: 1px dashed var(--nsbmre-border);
	border-radius: var(--nsbmre-radius);
	color: var(--nsbmre-muted);
}

.nsbmre-empty p {
	margin: 0 0 14px;
}

.nsbmre-results {
	position: relative;
	transition: opacity .15s ease;
}

.nsbmre-listings.is-loading .nsbmre-results {
	opacity: .45;
	pointer-events: none;
}

.nsbmre-loading {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	padding: 16px;
	color: var(--nsbmre-muted);
	font-size: .9em;
}

.nsbmre-spinner {
	width: 16px;
	height: 16px;
	border: 2px solid var(--nsbmre-border);
	border-top-color: var(--nsbmre-highlight);
	border-radius: 50%;
	animation: nsbmre-spin .7s linear infinite;
}

@keyframes nsbmre-spin {
	to { transform: rotate(360deg); }
}

/* --------------------------------------------------------------------- Map */

.nsbmre-map-wrap {
	margin-bottom: 20px;
	border: 1px solid var(--nsbmre-border);
	border-radius: var(--nsbmre-radius);
	overflow: hidden;
}

.nsbmre-map,
.nsbmre-standalone-map {
	width: 100%;
	height: var(--nsbmre-map-height, 520px);
	background: #e8ecef;
}

.nsbmre-single-map {
	height: 360px;
	border: 1px solid var(--nsbmre-border);
	border-radius: var(--nsbmre-radius);
}

.nsbmre-map-popup {
	display: flex;
	gap: 10px;
	width: 240px;
	font-family: var(--nsbmre-font-body);
}

.nsbmre-map-popup img {
	width: 82px;
	height: 62px;
	object-fit: cover;
	border-radius: var(--nsbmre-radius);
	flex: 0 0 auto;
}

.nsbmre-map-popup strong {
	display: block;
	font-size: .92em;
	margin-bottom: 2px;
	color: var(--nsbmre-accent);
}

.nsbmre-map-popup a {
	text-decoration: none;
	color: inherit;
}

.nsbmre-map-popup .nsbmre-map-price {
	color: var(--nsbmre-primary);
	font-weight: 600;
	font-size: .9em;
}

.nsbmre-cluster-icon {
	display: flex;
	align-items: center;
	justify-content: center;
	background: var(--nsbmre-highlight);
	color: #060606;
	border: 3px solid rgba(255, 255, 255, .75);
	border-radius: 50%;
	font-weight: 700;
	font-size: 13px;
	box-shadow: 0 2px 8px rgba(16, 24, 40, .25);
}

.nsbmre-price-marker {
	display: inline-block;
	padding: 4px 8px;
	background: var(--nsbmre-price-bg);
	color: #fff;
	font-size: 12px;
	font-weight: 600;
	white-space: nowrap;
	border-radius: var(--nsbmre-radius);
	box-shadow: 0 2px 6px rgba(16, 24, 40, .3);
	transform: translate(-50%, -100%);
}

/* ------------------------------------------------------------- Search form */

.nsbmre-search-form {
	display: flex;
	gap: 10px;
	flex-wrap: wrap;
	align-items: center;
	background: var(--nsbmre-card-bg);
	border: 1px solid var(--nsbmre-border);
	border-radius: var(--nsbmre-radius);
	padding: 12px;
	box-shadow: var(--nsbmre-shadow);
}

.nsbmre-search-field {
	flex: 1 1 170px;
	min-width: 150px;
}

.nsbmre-search-stacked {
	flex-direction: column;
	align-items: stretch;
}

.nsbmre-search-stacked .nsbmre-search-field {
	flex: 1 1 auto;
	width: 100%;
}

/* ------------------------------------------------------------ Single layout */

.nsbmre-single-header {
	display: flex;
	flex-wrap: wrap;
	gap: 16px;
	justify-content: space-between;
	align-items: flex-start;
	margin-bottom: 20px;
}

.nsbmre-single-title {
	font-size: 1.7em;
	margin: 0 0 6px;
}

.nsbmre-single-location {
	display: flex;
	align-items: center;
	gap: 6px;
	margin: 0 0 8px;
	color: var(--nsbmre-muted);
}

.nsbmre-single-tags {
	display: flex;
	gap: 6px;
	margin: 0;
}

.nsbmre-single-price {
	font-size: 1.6em;
	font-weight: 700;
	color: var(--nsbmre-price-bg);
	white-space: nowrap;
}

.nsbmre-single-layout {
	display: grid;
	grid-template-columns: minmax(0, 1fr) 320px;
	gap: var(--nsbmre-gap);
	align-items: start;
	margin-top: 28px;
}

.nsbmre-section {
	margin-bottom: 32px;
}

.nsbmre-section-title {
	font-size: 1.1em;
	padding-bottom: 8px;
	border-bottom: 1px solid var(--nsbmre-border);
	margin-bottom: 14px;
}

.nsbmre-facts {
	list-style: none;
	margin: 0;
	padding: 0;
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
	gap: 10px 20px;
}

.nsbmre-fact {
	display: flex;
	justify-content: space-between;
	gap: 10px;
	padding-bottom: 8px;
	border-bottom: 1px dashed var(--nsbmre-border);
	font-size: .92em;
}

.nsbmre-fact-label {
	color: var(--nsbmre-muted);
}

.nsbmre-fact-value {
	font-weight: 600;
	color: var(--nsbmre-accent);
	text-align: right;
}

.nsbmre-tag-list {
	list-style: none;
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
	margin: 0;
	padding: 0;
}

.nsbmre-tag-list li {
	padding: 5px 12px;
	background: color-mix(in srgb, var(--nsbmre-highlight) 12%, transparent);
	color: var(--nsbmre-accent);
	border-radius: var(--nsbmre-radius);
	font-size: .86em;
}

.nsbmre-contact-box {
	background: var(--nsbmre-card-bg);
	border: 1px solid var(--nsbmre-border);
	border-radius: var(--nsbmre-radius);
	padding: 20px;
	box-shadow: var(--nsbmre-shadow);
	margin-bottom: 24px;
}

.nsbmre-contact-name {
	font-weight: 600;
	margin: 0 0 10px;
}

.nsbmre-contact-line {
	margin: 0 0 8px;
}

.nsbmre-contact-ref {
	margin: 12px 0 0;
	font-size: .82em;
	color: var(--nsbmre-muted);
}

/* ----------------------------------------------------------------- Gallery */

.nsbmre-gallery {
	--nsbmre-gallery-ratio: 4 / 3;
}

.nsbmre-gallery-main {
	position: relative;
	background: #eef1f4;
	border-radius: var(--nsbmre-radius);
	overflow: hidden;
	aspect-ratio: var(--nsbmre-gallery-ratio);
}

.nsbmre-gallery-main img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}

/* Prefiks .nsbmre-scope .nsbmre-gallery da tema (npr. Hello [type=button]) ne menja dugmad. */
.nsbmre-scope .nsbmre-gallery .nsbmre-gallery-nav {
	position: absolute;
	top: 50%;
	transform: translateY(-50%);
	display: flex;
	align-items: center;
	justify-content: center;
	width: 40px;
	height: 40px;
	padding: 0 0 3px;
	border: 0;
	border-radius: 50%;
	background: rgba(255, 255, 255, .9);
	color: var(--nsbmre-accent);
	font-size: 26px;
	line-height: 1;
	cursor: pointer;
	box-shadow: 0 2px 8px rgba(16, 24, 40, .2);
}

.nsbmre-scope .nsbmre-gallery .nsbmre-gallery-nav:hover,
.nsbmre-scope .nsbmre-gallery .nsbmre-gallery-nav:focus {
	background: #fff;
	color: var(--nsbmre-accent);
	border: 0;
}

.nsbmre-scope .nsbmre-gallery .nsbmre-gallery-nav:focus-visible {
	outline: 2px solid var(--nsbmre-highlight);
	outline-offset: 2px;
}

.nsbmre-scope .nsbmre-gallery .nsbmre-gallery-prev { left: 12px; }
.nsbmre-scope .nsbmre-gallery .nsbmre-gallery-next { right: 12px; }

.nsbmre-gallery-thumbs {
	list-style: none;
	display: flex;
	gap: 8px;
	margin: 10px 0 0;
	padding: 0 0 4px;
	overflow-x: auto;
}

.nsbmre-scope .nsbmre-gallery .nsbmre-gallery-thumb,
.nsbmre-scope .nsbmre-gallery .nsbmre-gallery-thumb:hover,
.nsbmre-scope .nsbmre-gallery .nsbmre-gallery-thumb:focus {
	padding: 0;
	border: 2px solid transparent;
	border-radius: var(--nsbmre-radius);
	background: none;
	cursor: pointer;
	line-height: 0;
	overflow: hidden;
}

.nsbmre-scope .nsbmre-gallery .nsbmre-gallery-thumb:hover {
	border-color: color-mix(in srgb, var(--nsbmre-highlight) 45%, transparent);
}

.nsbmre-scope .nsbmre-gallery .nsbmre-gallery-thumb.is-active {
	border-color: var(--nsbmre-highlight);
}

.nsbmre-scope .nsbmre-gallery .nsbmre-gallery-thumb:focus-visible {
	outline: 2px solid var(--nsbmre-highlight);
	outline-offset: 1px;
}

.nsbmre-gallery-thumb img {
	width: 88px;
	height: 66px;
	object-fit: cover;
	display: block;
}

/* Desktop: glavna slika na pola širine, sličice u mreži desno, iste visine. */
@media (min-width: 783px) {
	.nsbmre-gallery {
		max-width: calc(50% - 6px);
	}

	.nsbmre-gallery.has-thumbs {
		display: grid;
		grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
		gap: 12px;
		max-width: none;
	}

	.nsbmre-gallery.has-thumbs .nsbmre-gallery-thumbs {
		display: grid;
		grid-template-columns: repeat(var(--nsbmre-thumb-cols, 4), minmax(0, 1fr));
		align-content: start;
		gap: 8px;
		margin: 0;
		padding: 0 4px 0 0;
		aspect-ratio: var(--nsbmre-gallery-ratio);
		overflow-x: hidden;
		overflow-y: auto;
	}

	.nsbmre-thumb-cols-2 { --nsbmre-thumb-cols: 2; }
	.nsbmre-thumb-cols-3 { --nsbmre-thumb-cols: 3; }
	.nsbmre-thumb-cols-4 { --nsbmre-thumb-cols: 4; }

	.nsbmre-scope .nsbmre-gallery.has-thumbs .nsbmre-gallery-thumb {
		display: block;
		width: 100%;
	}

	.nsbmre-gallery.has-thumbs .nsbmre-gallery-thumb img {
		width: 100%;
		height: auto;
		aspect-ratio: var(--nsbmre-gallery-ratio);
	}
}

.nsbmre-floorplan img,
.nsbmre-video iframe {
	max-width: 100%;
	height: auto;
}

/* ----------------------------------------------------------------- Archive */

.nsbmre-scope.nsbmre-page {
	background: var(--nsbmre-page-bg);
}

.nsbmre-archive-header {
	margin-bottom: 24px;
}

.nsbmre-archive-title {
	font-size: 1.6em;
	margin: 0;
}

/* -------------------------------------------------------------- Responsive */

@media (max-width: 1024px) {
	.nsbmre-listings,
	.nsbmre-listings.nsbmre-sidebar-right {
		grid-template-columns: minmax(0, 1fr);
	}

	.nsbmre-sidebar {
		position: static;
		display: none;
	}

	.nsbmre-listings.is-filters-open .nsbmre-sidebar {
		display: block;
	}

	.nsbmre-filters-toggle {
		display: inline-flex;
	}

	.nsbmre-single-layout {
		grid-template-columns: minmax(0, 1fr);
	}

	.nsbmre-cols-4 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

@media (max-width: 782px) {
	.nsbmre-cols-3,
	.nsbmre-cols-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }

	.nsbmre-single-title { font-size: 1.35em; }
}

@media (max-width: 540px) {
	.nsbmre-grid,
	.nsbmre-cols-2,
	.nsbmre-cols-3,
	.nsbmre-cols-4 { grid-template-columns: minmax(0, 1fr); }

	.nsbmre-checklist { grid-template-columns: 1fr; }

	.nsbmre-toolbar { flex-direction: column; align-items: stretch; }

	.nsbmre-toolbar-actions { justify-content: space-between; }

	.nsbmre-sort select { min-width: 0; flex: 1; }
}
