/*
 * BigSpace Premium — homepage hero.
 *
 * Photo-led and light. Three full-bleed slides crossfade on a ten-second cycle
 * with a slow drift, the only overlay is a soft gradient behind the headline,
 * and the bottom of the hero dissolves into the white page so the search card
 * sits half in the photograph and half on paper. The earlier hairline grid and
 * heavy navy scrim were removed on request.
 *
 * Scoped under `.bsp-hero`. The search card's own styles live in bsp.css.
 */

.bsp-hero {
	position: relative;
	isolation: isolate;
	overflow: hidden;
	background: var(--bsp-navy-800);
	color: #fff;
	min-height: 520px;
	display: flex;
	align-items: flex-end;
}

@media (min-width: 1024px) {
	.bsp-hero { min-height: 600px; }
}

/* Slides ------------------------------------------------------------------ */

.bsp-hero__slides { position: absolute; inset: 0; z-index: -2; margin: 0; }

.bsp-hero__slide {
	position: absolute;
	inset: 0;
	margin: 0;
	opacity: 0;
	transition: opacity 1.6s var(--bsp-ease);
	will-change: opacity;
}

.bsp-hero__slide img,
.bsp-hero__slide picture { width: 100%; height: 100%; display: block; }

.bsp-hero__slide img {
	object-fit: cover;
	object-position: center;
	transform: scale(1.04);
	transition: transform 14s linear;
}

.bsp-hero__slide.is-active { opacity: 1; z-index: 1; }

/* A slow drift while a slide is on screen; the scale resets when .is-active
   is removed, so it restarts on each change. */
.bsp-hero__slide.is-active img { transform: scale(1.12); }

/* A soft navy wash on the left where the headline sits, and a fade to white at
   the foot so the page begins inside the photograph. */
.bsp-hero__scrim {
	position: absolute;
	inset: 0;
	z-index: -1;
	background:
		linear-gradient(180deg, transparent 58%, rgba(255, 255, 255, .55) 88%, #fff 100%),
		linear-gradient(100deg, rgba(8, 24, 41, .82) 0%, rgba(8, 24, 41, .55) 45%, rgba(8, 24, 41, .15) 78%, transparent 100%);
}

/* Slide caption: which market this photograph stands for. */
.bsp-hero__tag {
	position: absolute;
	top: 22px;
	right: 22px;
	z-index: 2;
	display: inline-flex;
	align-items: center;
	gap: 8px;
	padding: 8px 13px;
	border-radius: 999px;
	background: rgba(255, 255, 255, .86);
	box-shadow: 0 6px 20px -8px rgba(8, 24, 41, .35);
	backdrop-filter: blur(10px);
	color: var(--bsp-navy-800);
	font-size: .75rem;
	font-weight: 650;
	opacity: 0;
	transform: translateY(-6px);
	transition: opacity .6s var(--bsp-ease) .5s, transform .6s var(--bsp-ease) .5s;
}

.bsp-hero__tag::before {
	content: "";
	width: 7px;
	height: 7px;
	border-radius: 50%;
	background: var(--bsp-gold-500);
}

.bsp-hero__slide.is-active .bsp-hero__tag { opacity: 1; transform: none; }

@media (max-width: 700px) { .bsp-hero__tag { display: none; } }

.bsp-hero__dots {
	position: absolute;
	right: 24px;
	bottom: 24px;
	z-index: 3;
	display: flex;
	gap: 7px;
	margin: 0;
	padding: 0;
	list-style: none;
}

.bsp-hero__dot {
	width: 24px;
	height: 4px;
	border: 0;
	border-radius: 2px;
	padding: 0;
	background: rgba(8, 24, 41, .22);
	cursor: pointer;
	transition: background .3s var(--bsp-ease), width .3s var(--bsp-ease);
}

.bsp-hero__dot[aria-current="true"] { width: 40px; background: var(--bsp-gold-500); }

@media (max-width: 700px) { .bsp-hero__dots { display: none; } }

/* Copy --------------------------------------------------------------------- */

.bsp-hero__inner { position: relative; z-index: 2; width: 100%; padding-top: 72px; }

@media (min-width: 1024px) { .bsp-hero__inner { padding-top: 96px; } }

.bsp-hero .bsp-hero__title {
	max-width: 22ch;
	color: #fff;
	font-size: clamp(1.9rem, 1.2rem + 2.6vw, 3.1rem);
	line-height: 1.08;
	letter-spacing: -.033em;
	text-shadow: 0 2px 24px rgba(8, 24, 41, .35);
	white-space: normal;
}

.bsp-hero__title em { font-style: normal; color: var(--bsp-gold-300); }

.bsp-hero__lede {
	margin-top: 12px;
	max-width: 70ch;
	font-size: clamp(.96rem, .92rem + .3vw, 1.1rem);
	line-height: 1.55;
	color: rgba(255, 255, 255, .92);
	text-shadow: 0 1px 12px rgba(8, 24, 41, .35);
}

/* Entrance ----------------------------------------------------------------- */

.bsp-hero__inner > * {
	opacity: 0;
	transform: translateY(14px);
	animation: bsp-rise .9s var(--bsp-ease) forwards;
}

.bsp-hero__inner > :nth-child(1) { animation-delay: .1s; }
.bsp-hero__inner > :nth-child(2) { animation-delay: .22s; }
.bsp-hero__inner > :nth-child(3) { animation-delay: .34s; }
.bsp-hero__inner > :nth-child(4) { animation-delay: .5s; }

@keyframes bsp-rise { to { opacity: 1; transform: none; } }

.bsp-hero .bsp-search { margin-top: 24px; margin-bottom: 24px; }

/* Stats ------------------------------------------------------------------- */

/* On paper, under the hero: white space is what makes a page feel light, and
   the numbers count up as they come into view. */
.bsp-hero-stats { background: #fff; border-bottom: 1px solid var(--bsp-line); }

.bsp-hero-stats__list {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	margin: 0;
	padding: 0;
	list-style: none;
}

@media (min-width: 800px) { .bsp-hero-stats__list { grid-template-columns: repeat(4, minmax(0, 1fr)); } }

.bsp-hero-stats__item { padding: 20px 20px 20px 0; display: flex; flex-direction: column; gap: 5px; }

@media (min-width: 800px) {
	.bsp-hero-stats__item + .bsp-hero-stats__item { padding-left: 24px; border-left: 1px solid var(--bsp-line); }
}

.bsp-hero-stats__item b {
	font-size: clamp(1.7rem, 1.3rem + 1.2vw, 2.3rem);
	font-weight: 700;
	letter-spacing: -.035em;
	line-height: 1;
	color: var(--bsp-navy-800);
	font-variant-numeric: tabular-nums;
}

.bsp-hero-stats__item b small { font-size: .55em; font-weight: 700; color: var(--bsp-gold-500); margin-left: 2px; }

.bsp-hero-stats__item span { font-size: .74rem; letter-spacing: .07em; text-transform: uppercase; color: var(--bsp-muted); }

@media (prefers-reduced-motion: reduce) {
	.bsp-hero__slide, .bsp-hero__slide img, .bsp-hero__tag { transition: none; }
	.bsp-hero__slide.is-active img { transform: scale(1.04); }
	.bsp-hero__inner > * { animation: none; opacity: 1; transform: none; }
}
