/**
 * Single-listing components: hero, facts, gallery, docs, location, broker card.
 * Token-driven; no raw values outside the token sheet.
 */

/* --- Hero --- */
.rb-shero__media {
	position: relative;
	aspect-ratio: 3 / 2;
	max-height: 520px;
	width: 100%;
	overflow: hidden;
	border-radius: var(--rb-radius-lg);
	background: var(--rb-muted);
}
.rb-shero__media img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}
.rb-shero__media .rb-badge {
	top: var(--rb-space-4);
	left: var(--rb-space-4);
}
.rb-shero--sold .rb-shero__media img {
	filter: grayscale(0.45);
}

.rb-shero__head {
	display: flex;
	justify-content: space-between;
	align-items: flex-start;
	gap: var(--rb-space-6);
	flex-wrap: wrap;
	margin-top: var(--rb-space-5);
}
.rb-shero__title {
	margin: 0 0 var(--rb-space-2);
}
.rb-shero__sub {
	display: flex;
	flex-wrap: wrap;
	gap: var(--rb-space-2) var(--rb-space-4);
	margin: 0 0 var(--rb-space-3);
	color: var(--rb-text-secondary);
	font-size: 15px;
}
.rb-shero__sub span + span::before {
	content: "·";
	margin-right: var(--rb-space-4);
	color: var(--rb-gray-400);
}

.rb-shero__stats {
	display: flex;
	gap: var(--rb-space-6);
	margin: 0;
	padding: var(--rb-space-4) var(--rb-space-5);
	background: var(--rb-surface);
	border: 1px solid var(--rb-border);
	border-radius: var(--rb-radius-md);
	flex-shrink: 0;
}
.rb-shero__stat dt {
	font-size: 12.5px;
	font-weight: 500;
	letter-spacing: 0.8px;
	text-transform: uppercase;
	color: var(--rb-text-secondary);
	margin-bottom: var(--rb-space-1);
}
.rb-shero__stat dd {
	margin: 0;
	font-size: 20px;
	font-weight: 600;
	color: var(--rb-text);
}
.rb-shero__stat .rb-shero__price {
	color: var(--rb-text);
	font-size: 24px;
}

/* --- Facts blocks --- */
.rb-facts__block {
	margin-bottom: var(--rb-space-6);
}
.rb-facts__block > h2 {
	font-size: 24px;
	margin: 0 0 var(--rb-space-4);
}
.rb-facts__highlights {
	list-style: none;
	margin: 0;
	padding: 0;
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: var(--rb-space-3);
}
.rb-facts__highlights li {
	position: relative;
	padding-left: var(--rb-space-5);
	line-height: 1.5;
}
.rb-facts__highlights li::before {
	content: "✓";
	position: absolute;
	left: 0;
	color: var(--rb-accent-dark);
	font-weight: 700;
}

.rb-facts__table {
	width: 100%;
	border-collapse: collapse;
}
.rb-facts__table th,
.rb-facts__table td {
	padding: var(--rb-space-3) var(--rb-space-2);
	border-bottom: 1px solid var(--rb-border);
	text-align: left;
	vertical-align: top;
	font-size: 15px;
	line-height: 1.5;
}
.rb-facts__table th {
	width: 42%;
	font-weight: 500;
	color: var(--rb-text-secondary);
}
.rb-facts__table td {
	font-weight: 500;
	color: var(--rb-text);
	font-variant-numeric: tabular-nums;
}

/* --- Gallery --- */
.rb-sgallery {
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: var(--rb-space-3);
}
.rb-sgallery__item {
	display: block;
	aspect-ratio: 3 / 2;
	overflow: hidden;
	border-radius: var(--rb-radius-md);
	background: var(--rb-muted);
}
.rb-sgallery__item img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
	transition: transform var(--rb-duration-slow) var(--rb-ease);
}
@media (hover: hover) {
	.rb-sgallery__item:hover img {
		transform: scale(1.04);
	}
}

.rb-sfloorplan img {
	max-width: 100%;
	height: auto;
	border: 1px solid var(--rb-border);
	border-radius: var(--rb-radius-md);
}

/* --- Documents --- */
.rb-sdocs {
	list-style: none;
	margin: 0;
	padding: 0;
	display: flex;
	flex-direction: column;
	gap: var(--rb-space-3);
}
.rb-sdocs__link {
	display: inline-flex;
	align-items: center;
	min-height: 44px;
	padding: 0 var(--rb-space-4);
	border: 1px solid var(--rb-primary);
	border-radius: var(--rb-radius-sm);
	color: var(--rb-primary);
	font-weight: 600;
	text-decoration: none;
}
.rb-sdocs__link:hover {
	background: var(--rb-primary);
	color: var(--rb-text-invert);
}
.rb-sdocs__gated {
	padding: var(--rb-space-3) var(--rb-space-4);
	background: var(--rb-primary-tint);
	border-radius: var(--rb-radius-sm);
	color: var(--rb-text);
	font-size: 14px;
	line-height: 1.5;
}

.rb-slocation__note {
	margin: var(--rb-space-3) 0 0;
	font-size: 14px;
	color: var(--rb-text-secondary);
}

/* --- Broker card (sidebar) --- */
.rb-broker {
	position: sticky;
	top: 96px;
	padding: var(--rb-space-5);
	background: var(--rb-bg);
	border: 1px solid var(--rb-border);
	border-radius: var(--rb-radius-md);
	box-shadow: var(--rb-shadow-sm);
}
.rb-broker__kicker {
	margin: 0 0 var(--rb-space-3);
	font-size: 12.5px;
	font-weight: 500;
	letter-spacing: 0.8px;
	text-transform: uppercase;
	color: var(--rb-text-secondary);
}
.rb-broker__head {
	display: flex;
	align-items: center;
	gap: var(--rb-space-3);
	margin-bottom: var(--rb-space-4);
}
.rb-broker__avatar {
	width: 56px;
	height: 56px;
	border-radius: var(--rb-radius-pill);
	object-fit: cover;
}
.rb-broker__name {
	font-weight: 600;
	font-size: 17px;
	color: var(--rb-text);
	text-decoration: none;
}
.rb-broker__name:hover {
	color: var(--rb-primary);
}
.rb-broker__position {
	margin: 2px 0 0;
	font-size: 13.5px;
	color: var(--rb-text-secondary);
}
.rb-broker__actions {
	display: flex;
	flex-direction: column;
	gap: var(--rb-space-2);
}
.rb-broker__btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-height: 48px;
	padding: 0 var(--rb-space-4);
	border-radius: var(--rb-radius-md);
	font-weight: 600;
	font-size: 15px;
	text-decoration: none;
	text-align: center;
	transition: background var(--rb-duration-fast) var(--rb-ease), color var(--rb-duration-fast) var(--rb-ease);
}
.rb-broker__btn--primary {
	background: var(--rb-secondary);
	color: var(--rb-text-invert);
}
.rb-broker__btn--primary:hover {
	background: var(--rb-text);
	color: var(--rb-text-invert);
}
.rb-broker__btn--ghost {
	border: 1px solid var(--rb-primary);
	color: var(--rb-primary);
	background: var(--rb-bg);
}
.rb-broker__btn--ghost:hover {
	background: var(--rb-primary-tint);
}
.rb-broker__note {
	margin: var(--rb-space-4) 0 0;
	font-size: 13px;
	color: var(--rb-text-secondary);
	text-align: center;
}

/* --- Responsive --- */
@media (max-width: 1024px) {
	.rb-shero__stats {
		width: 100%;
		justify-content: space-between;
	}
	.rb-broker {
		position: static;
	}
}
@media (max-width: 767px) {
	.rb-facts__highlights {
		grid-template-columns: 1fr;
	}
	.rb-sgallery {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}
	.rb-shero__stats {
		flex-wrap: wrap;
		gap: var(--rb-space-4);
	}
	.rb-facts__table th {
		width: 48%;
	}
}
