/*
 * Styles for the vacation-rentals plugin: the /rentals/ layout, the property
 * cards, the booking box, and a standalone header/footer frame for the archive and
 * single templates. The shortcode listing sits on the site's own page and uses
 * that page's header, so there it draws on only the grid and card rules.
 */

:root {
	--vr-muted: #6b7280;
	--vr-accent: #037173;
	--vr-brand: #037173;
	--vr-brand-dark: #025a5c;
}

.vr-container {
	max-width: 1200px;
	margin-inline: auto;
	padding-inline: 20px;
}

/* ---- Gallery lightbox (single template) ---- */

.vr-lightbox-thumb {
	cursor: zoom-in;
}

body.vr-lightbox-open {
	overflow: hidden;
}

.vr-lightbox {
	position: fixed;
	inset: 0;
	z-index: 9999;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: clamp(12px, 4vw, 48px);
	background: rgba(11, 17, 20, 0.92);
}

.vr-lightbox[hidden] {
	display: none;
}

.vr-lightbox__stage {
	display: flex;
	align-items: center;
	justify-content: center;
	max-width: 100%;
	max-height: 100%;
}

.vr-lightbox__image {
	max-width: min(1600px, 92vw);
	max-height: 82vh;
	width: auto;
	height: auto;
	object-fit: contain;
	border-radius: 4px;
	box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5);
}

.vr-lightbox__caption {
	position: absolute;
	inset-inline: 0;
	bottom: 16px;
	margin: 0;
	padding-inline: 20px;
	text-align: center;
	color: #f3f4f6;
	font-size: 0.95rem;
}

.vr-lightbox__counter {
	position: absolute;
	top: 18px;
	left: 20px;
	margin: 0;
	color: #cbd5e1;
	font-size: 0.85rem;
	letter-spacing: 0.03em;
}

.vr-lightbox__close,
.vr-lightbox__nav {
	position: absolute;
	display: flex;
	align-items: center;
	justify-content: center;
	background: rgba(255, 255, 255, 0.12);
	color: #ffffff;
	border: 0;
	border-radius: 50%;
	cursor: pointer;
	line-height: 1;
	transition: background 0.15s ease;
}

.vr-lightbox__close:hover,
.vr-lightbox__nav:hover,
.vr-lightbox__close:focus-visible,
.vr-lightbox__nav:focus-visible {
	background: var(--vr-brand);
	outline: none;
}

.vr-lightbox__close {
	top: 12px;
	right: 16px;
	width: 44px;
	height: 44px;
	font-size: 1.8rem;
}

.vr-lightbox__nav {
	top: 50%;
	transform: translateY(-50%);
	width: 52px;
	height: 52px;
	font-size: 2.2rem;
}

.vr-lightbox__nav--prev {
	left: clamp(8px, 2vw, 28px);
}

.vr-lightbox__nav--next {
	right: clamp(8px, 2vw, 28px);
}

@media (max-width: 600px) {
	.vr-lightbox__nav {
		width: 42px;
		height: 42px;
		font-size: 1.8rem;
	}
}

/* ---- Page frame: header + footer (archive + single templates) ---- */
/* Styled in the site's brand teal to echo the Elementor-built header/footer. */

.vr-site-header {
	background: var(--vr-brand);
	color: #ffffff;
}

.vr-site-header__inner {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 20px;
	min-height: 76px;
	padding-block: 10px;
}

.vr-site-header__title {
	font-size: 1.2rem;
	font-weight: 700;
	letter-spacing: 0.01em;
	color: #ffffff;
	text-decoration: none;
}

.vr-site-header .custom-logo-link {
	display: inline-flex;
	align-items: center;
}

.vr-site-header .custom-logo {
	max-height: 76px;
	width: auto;
	height: auto;
	display: block;
}

.vr-site-nav {
	display: flex;
	align-items: center;
	justify-content: flex-end;
	flex-wrap: wrap;
	gap: 12px 16px;
}

/* A real WordPress menu, when the site has one: plain white links. */
.vr-site-nav__list {
	list-style: none;
	margin: 0;
	padding: 0;
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 8px 24px;
}

.vr-site-nav__list a {
	color: #ffffff;
	text-decoration: none;
	font-size: 0.95rem;
	font-weight: 600;
}

.vr-site-nav__list a:hover,
.vr-site-nav__list a:focus-visible {
	opacity: 0.8;
}

/* Fallback links (no WordPress menu): pill buttons. */
.vr-site-nav__link {
	display: inline-block;
	padding: 9px 18px;
	border: 1px solid rgba(255, 255, 255, 0.75);
	border-radius: 999px;
	color: #ffffff;
	text-decoration: none;
	font-size: 0.95rem;
	font-weight: 600;
}

.vr-site-nav__link:hover,
.vr-site-nav__link:focus-visible {
	background: #ffffff;
	color: var(--vr-brand);
}

.vr-site-footer {
	margin-top: 64px;
	background: var(--vr-brand-dark);
	color: #e6f1ee;
}

.vr-site-footer__inner {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: 12px 32px;
	padding-block: 28px;
}

.vr-site-footer__brand {
	margin: 0;
	font-weight: 700;
	color: #ffffff;
}

.vr-site-footer__meta {
	margin: 0;
	width: 100%;
	color: rgba(255, 255, 255, 0.7);
	font-size: 0.85rem;
}

/* ---- Listing (/rentals/) ---- */

.vr-rentals {
	padding-block: 48px 64px;
}

/* Embedded via the shortcode on a page that already has its own hero/heading. */
.vr-rentals--embedded {
	padding-block: 8px 40px;
}

.vr-rentals__intro {
	margin-bottom: 32px;
	text-align: center;
}

.vr-rentals__title {
	margin: 0;
}

.vr-rentals__grid {
	list-style: none;
	margin: 0;
	padding: 0;
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(280px, 360px));
	justify-content: center;
	gap: 28px;
}

.vr-card {
	display: flex;
}

.vr-card__link {
	display: flex;
	flex-direction: column;
	width: 100%;
	border-radius: 12px;
	overflow: hidden;
	background: #fff;
	box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08), 0 8px 24px rgba(0, 0, 0, 0.06);
	text-decoration: none;
	color: inherit;
	transition: transform 0.18s ease, box-shadow 0.18s ease;
}

.vr-card__link:hover,
.vr-card__link:focus-visible {
	transform: translateY(-4px);
	box-shadow: 0 2px 6px rgba(0, 0, 0, 0.10), 0 16px 40px rgba(0, 0, 0, 0.12);
}

.vr-card__media {
	aspect-ratio: 4 / 3;
	overflow: hidden;
}

.vr-card__image {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}

.vr-card__body {
	padding: 18px 20px 22px;
	display: flex;
	flex-direction: column;
	gap: 6px;
}

.vr-card__title {
	margin: 0;
	font-size: 1.25rem;
	line-height: 1.25;
}

.vr-card__location {
	margin: 0;
	opacity: 0.7;
	font-size: 0.95rem;
}

.vr-card__facts {
	list-style: none;
	margin: 6px 0 0;
	padding: 0;
	display: flex;
	flex-wrap: wrap;
	gap: 6px 16px;
	font-size: 0.9rem;
	opacity: 0.85;
}

.vr-card__facts li {
	position: relative;
}

.vr-card__facts li + li::before {
	content: "\00b7";
	position: absolute;
	left: -10px;
}

.vr-card__price {
	margin: 10px 0 0;
	font-weight: 700;
	color: var(--vr-accent);
}

.vr-card__cta {
	margin-top: 4px;
	font-size: 0.9rem;
	font-weight: 600;
	color: var(--vr-accent);
	text-decoration: underline;
}

.vr-rentals__empty {
	text-align: center;
	opacity: 0.7;
	padding-block: 40px;
}

/* ---- Single property ---- */

.vr-property {
	padding-block: 32px 64px;
}

.vr-property__back a {
	text-decoration: none;
	color: var(--vr-muted);
	font-size: 0.95rem;
}

.vr-property__back a:hover,
.vr-property__back a:focus-visible {
	color: var(--vr-accent);
}

.vr-property__title {
	margin: 8px 0 4px;
}

.vr-property__location {
	margin: 0 0 20px;
	opacity: 0.7;
}

.vr-property__hero {
	border-radius: 14px;
	overflow: hidden;
	margin-bottom: 32px;
}

.vr-property__hero-image {
	width: 100%;
	height: auto;
	display: block;
}

/* ---- Hero photo carousel (single template) ---- */

.vr-carousel {
	position: relative;
	border-radius: 14px;
	overflow: hidden;
	margin-bottom: 32px;
	background: #0b1114;
}

/*
 * The track is a native horizontal scroller with snap points, so a swipe or a
 * touchpad scrolls photo to photo even with JavaScript off; the arrow buttons just
 * drive this same scroll. The scrollbar is hidden because the arrows and counter
 * already show position.
 */
.vr-carousel__track {
	display: flex;
	overflow-x: auto;
	scroll-snap-type: x mandatory;
	scrollbar-width: none;
	-ms-overflow-style: none;
	-webkit-overflow-scrolling: touch;
}

.vr-carousel__track::-webkit-scrollbar {
	display: none;
}

.vr-carousel__slide {
	flex: 0 0 100%;
	margin: 0;
	scroll-snap-align: start;
	aspect-ratio: 3 / 2;
}

.vr-carousel__image {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
	cursor: zoom-in;
}

.vr-carousel__nav {
	position: absolute;
	top: 50%;
	transform: translateY(-50%);
	display: flex;
	align-items: center;
	justify-content: center;
	width: 48px;
	height: 48px;
	padding: 0;
	border: 0;
	border-radius: 50%;
	background: rgba(11, 17, 20, 0.55);
	color: #ffffff;
	font-size: 2rem;
	line-height: 1;
	cursor: pointer;
	transition: background 0.15s ease, opacity 0.15s ease;
}

.vr-carousel__nav:hover,
.vr-carousel__nav:focus-visible {
	background: var(--vr-brand);
	outline: none;
}

.vr-carousel__nav--prev {
	left: 14px;
}

.vr-carousel__nav--next {
	right: 14px;
}

/* Dim, but keep visible, the arrow that points past the first or last photo. */
.vr-carousel__nav[disabled] {
	opacity: 0.35;
	cursor: default;
}

.vr-carousel__counter {
	position: absolute;
	right: 14px;
	bottom: 12px;
	margin: 0;
	padding: 4px 11px;
	border-radius: 999px;
	background: rgba(11, 17, 20, 0.6);
	color: #ffffff;
	font-size: 0.85rem;
	letter-spacing: 0.02em;
}

@media (max-width: 600px) {
	.vr-carousel__slide {
		aspect-ratio: 4 / 3;
	}

	.vr-carousel__nav {
		width: 40px;
		height: 40px;
		font-size: 1.6rem;
	}
}

.vr-property__layout {
	display: grid;
	grid-template-columns: 1fr;
	gap: 40px;
}

@media (min-width: 900px) {
	.vr-property__layout {
		grid-template-columns: minmax(0, 1fr) 400px;
		align-items: start;
	}

	.vr-property__content {
		grid-column: 1;
		grid-row: 1;
	}

	.vr-property__gallery {
		grid-column: 1;
		grid-row: 2;
	}

	.vr-property__booking {
		grid-column: 2;
		grid-row: 1 / 3;
	}
}

.vr-property__facts {
	list-style: none;
	margin: 0 0 28px;
	padding: 0 0 20px;
	border-bottom: 1px solid rgba(0, 0, 0, 0.1);
	display: flex;
	flex-wrap: wrap;
	gap: 12px 32px;
}

.vr-property__fact-value {
	font-weight: 700;
	font-size: 1.15rem;
}

.vr-property__description {
	line-height: 1.7;
}

/*
 * The gallery is a separate grid item placed after the booking in source order, so
 * on a phone (one column) it falls below the booking widget and keeps the calendar
 * on the first screen. On desktop it is placed back into the left column under the
 * description (see the media query below), so the booking keeps its own column and
 * the sticky widget can never travel across the photos.
 */

/*
 * No card around the booking column: Hospitable's iframe has a fixed height with
 * empty space below the calendar, and a border/background would draw a box around
 * that emptiness. Left frameless, the widget sits flat and the unused height is
 * just blank page instead of a visible empty box.
 */
.vr-property__booking {
	padding: 0;
}

@media (min-width: 900px) {
	.vr-property__booking {
		position: sticky;
		top: 24px;
	}
}

.vr-property__price {
	margin: 0 0 16px;
	font-size: 1.5rem;
	font-weight: 700;
}

.vr-property__price-unit {
	font-size: 1rem;
	font-weight: 400;
	opacity: 0.7;
}

.vr-property__widget {
	min-height: 320px;
}

/*
 * The Hospitable booking widget renders as a fixed-height iframe (Hospitable's own
 * 900px, the size they recommend so the expanded price-details step fits). Only the
 * box model is normalised here: the height stays as the embed sets it, because the
 * cross-origin widget does not report its content height and so cannot be auto-fitted.
 */
.vr-property__widget iframe {
	display: block;
	width: 100%;
	border: 0;
}

.vr-property__booking-note {
	margin: 0;
	opacity: 0.7;
	font-size: 0.95rem;
}
