/**
 * Haiku Hospitality — home page.
 *
 * Ported from the Figma frame "20260810" (1440 x 4887). Desktop values match the
 * comp one-to-one; everything scales down through clamp() and the breakpoints at
 * the bottom of the file.
 */

:root {
	--haiku-teal: #022e37;
	--haiku-gold: #c9a44c;
	--haiku-gold-dark: #9a7523;
	--haiku-cream: #fef7ec;
	--haiku-ink: #1e1e1e;
	--haiku-muted: #6b6c6e;
	--haiku-slate: #274053;
	--haiku-steel: #80969b;

	--haiku-serif: "Bodoni Moda", "Didot", Georgia, serif;
	--haiku-sans: "Jost", -apple-system, "Segoe UI", Roboto, sans-serif;
	--haiku-display: "Chonburi", Georgia, serif;

	--haiku-max: 1196px;
	--haiku-gutter: clamp(20px, 8.47vw, 122px);
}

/* ---------------------------------------------------------------- base ---- */

.haiku-page {
	margin: 0;
	background: var(--haiku-cream);
	color: var(--haiku-ink);
	font-family: var(--haiku-sans);
	font-weight: 300;
	-webkit-font-smoothing: antialiased;
	overflow-x: hidden;
}

.haiku-page *,
.haiku-page *::before,
.haiku-page *::after {
	box-sizing: border-box;
}

/*
 * Element resets are wrapped in :where() so they carry zero specificity. A plain
 * `.haiku-page a` rule would outrank the single-class component rules below and
 * silently win — which is exactly how the nav, footer links and blockquote
 * centring broke the first time round.
 */
:where(.haiku-page) img {
	display: block;
	max-width: 100%;
}

:where(.haiku-page) :is(h1, h2, h3, p, figure, blockquote) {
	margin: 0;
}

:where(.haiku-page) a {
	color: inherit;
	text-decoration: none;
}

:where(.haiku-page) button {
	font: inherit;
	color: inherit;
	background: none;
	border: 0;
	padding: 0;
	cursor: pointer;
}

.haiku-page :focus-visible {
	outline: 2px solid var(--haiku-gold);
	outline-offset: 3px;
}

.haiku-skip-link {
	position: absolute;
	left: -9999px;
	top: 0;
	z-index: 100;
	background: var(--haiku-gold);
	color: var(--haiku-teal);
	padding: 12px 20px;
	font-size: 14px;
	letter-spacing: 0.05em;
	text-transform: uppercase;
}

.haiku-skip-link:focus {
	left: 12px;
	top: 12px;
}

/* Shared inner width used by most sections. */
.haiku-header__inner,
.haiku-partners__inner,
.haiku-gallery__inner,
.haiku-experience__grid,
.haiku-footer__inner {
	max-width: calc(var(--haiku-max) + var(--haiku-gutter) * 2);
	margin-inline: auto;
	padding-inline: var(--haiku-gutter);
}

/* ----------------------------------------------------------------- cta ---- */

.haiku-cta {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 10px;
	padding: 15.569px 31.138px;
	border-radius: 7.784px;
	font-family: var(--haiku-sans);
	font-weight: 400;
	font-size: clamp(13px, 1.11vw, 16px);
	letter-spacing: 0.05em;
	text-transform: uppercase;
	white-space: nowrap;
	transition: transform 0.25s ease, box-shadow 0.25s ease, background-color 0.25s ease;
}

/*
 * The exported Figma icons are hardcoded fill="white", which leaves the phone
 * invisible on the white button and the envelope off-palette on the gold one.
 * Painting them as a mask lets each icon inherit its button's text colour, so
 * both stay legible and follow the hover state without extra assets.
 */
.haiku-cta__icon {
	flex: none;
	width: 18px;
	height: 18px;
	background-color: currentColor;
	-webkit-mask: var(--haiku-cta-icon) center / contain no-repeat;
	mask: var(--haiku-cta-icon) center / contain no-repeat;
}

.haiku-cta__icon--envelope {
	--haiku-cta-icon: url("../images/icon-envelope.svg");
}

.haiku-cta__icon--phone {
	--haiku-cta-icon: url("../images/icon-phone.svg");
}

.haiku-cta--gold {
	background: var(--haiku-gold);
	color: var(--haiku-teal);
}

.haiku-cta--white {
	background: #fff;
	color: var(--haiku-teal);
}

.haiku-cta:hover {
	transform: translateY(-2px);
	box-shadow: 0 10px 26px rgba(2, 46, 55, 0.22);
}

/* -------------------------------------------------------------- header ---- */

.haiku-header {
	position: absolute;
	inset: 0 0 auto 0;
	z-index: 20;
	padding-block: 55px;
}

.haiku-header__inner {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 24px;
}

.haiku-header__logo img {
	width: clamp(120px, 11.4vw, 164px);
	height: auto;
}

.haiku-header__toggle {
	display: none;
	width: 44px;
	height: 44px;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	gap: 6px;
}

.haiku-header__toggle span {
	display: block;
	width: 26px;
	height: 1.5px;
	background: #fff;
	transition: transform 0.3s ease, opacity 0.2s ease;
}

.haiku-header__toggle[aria-expanded="true"] span:nth-child(1) {
	transform: translateY(7.5px) rotate(45deg);
}

.haiku-header__toggle[aria-expanded="true"] span:nth-child(2) {
	opacity: 0;
}

.haiku-header__toggle[aria-expanded="true"] span:nth-child(3) {
	transform: translateY(-7.5px) rotate(-45deg);
}

.haiku-nav {
	display: flex;
	align-items: center;
	gap: clamp(20px, 3.4vw, 49px);
}

.haiku-nav__link {
	font-family: var(--haiku-serif);
	font-variation-settings: "opsz" 11;
	font-weight: 400;
	font-size: clamp(13px, 1.25vw, 18px);
	color: #fff;
	text-transform: uppercase;
	white-space: nowrap;
	position: relative;
	padding-block: 4px;
}

.haiku-nav__link::after {
	content: "";
	position: absolute;
	left: 0;
	right: 0;
	bottom: 0;
	height: 1px;
	background: var(--haiku-gold);
	transform: scaleX(0);
	transform-origin: left;
	transition: transform 0.3s ease;
}

.haiku-nav__link:hover::after {
	transform: scaleX(1);
}

/* ---------------------------------------------------------------- hero ---- */

.haiku-hero {
	position: relative;
	min-height: 700px;
	background: var(--haiku-teal);
	display: flex;
	justify-content: center;
	overflow: hidden;
}

.haiku-hero__media {
	position: absolute;
	inset: 0;
	opacity: 0.9;
}

.haiku-hero__slide {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	object-fit: cover;
	object-position: center 30%;
	opacity: 0;
	transform: scale(1.06);
	transition: opacity 2s ease-in-out;
}

/*
 * Both states declare an identical animation so the drift carries on across
 * the class swap rather than restarting — the outgoing frame keeps gliding
 * while it fades instead of snapping back to the start scale. The zoom outruns
 * the 5s hold plus the 2s fade out, so it never visibly settles either.
 */
.haiku-hero__slide.is-active,
.haiku-hero__slide.is-leaving {
	animation: haiku-hero-drift 8s linear forwards;
}

.haiku-hero__slide.is-active {
	opacity: 1;
}

.haiku-hero__slide.is-leaving {
	opacity: 0;
}

@keyframes haiku-hero-drift {
	from {
		transform: scale(1.06);
	}

	to {
		transform: scale(1.14);
	}
}

@media ( prefers-reduced-motion: reduce ) {
	.haiku-hero__slide {
		transition-duration: 0.01ms;
		transform: none;
	}

	.haiku-hero__slide.is-active,
	.haiku-hero__slide.is-leaving {
		animation: none;
		transform: none;
	}
}

.haiku-hero__scrim {
	position: absolute;
	inset: 0;
	background:

		linear-gradient( 174deg, rgba(0, 0, 0, 0) 16.688%, #022e3700 112.81%), 
		linear-gradient(180deg, #022e371a 13.438%, rgb(0 0 0 / 0%) 56.938% 56.938%);

}

.haiku-hero__content {
	position: relative;
	z-index: 2;
	display: flex;
	flex-direction: column;
	align-items: center;
	text-align: center;
	padding: clamp(120px, 11.9vw, 172px) var(--haiku-gutter) clamp(60px, 6vw, 86px);
	width: 100%;
}

.haiku-hero__emblem {
	width: clamp(44px, 4.5vw, 65px);
	height: auto;
}

.haiku-hero__title {
	margin-top: clamp(24px, 2.8vw, 40px);
	font-family: var(--haiku-serif);
	font-variation-settings: "opsz" 28;
	font-weight: 500;
	font-size: clamp(64px, 10.4vw, 150px);
	line-height: 1;
	color: #fff;
	text-transform: uppercase;
}

.haiku-hero__tagline {
	margin-top: clamp(20px, 2.6vw, 38px);
	font-weight: 300;
	font-size: clamp(11px, 1.53vw, 22px);
	line-height: 1.4;
	letter-spacing: 0.26em;
	color: #fff;
	text-transform: uppercase;
	max-width: 1216px;
}

.haiku-hero__content .haiku-cta {
	margin-top: clamp(28px, 3.1vw, 45px);
}

/* ------------------------------------------------------------ partners ---- */

.haiku-partners {
	background: #fff;
}

.haiku-partners__inner {
	width: 100%;
	min-height: 127px;
	display: flex;
	align-items: center;
	gap: clamp(24px, 4.8vw, 68px);
}

.haiku-partners__label {
	flex: none;
	width: 140px;
	font-weight: 400;
	font-size: clamp(14px, 1.39vw, 20px);
	line-height: 1.2;
	color: var(--haiku-teal);
	text-transform: uppercase;
	text-align: right;
}

.haiku-partners__viewport {
	flex: 1;
	/* The track inside is max-content wide. Without both of these it sets the
	   flex base size (row) or the fit-content cross size (column, where the
	   parent centres rather than stretches) and drags the document wider than
	   the viewport. */
	min-width: 0;
	width: 100%;
	overflow: hidden;
	-webkit-mask-image: linear-gradient(90deg, transparent, #000 4%, #000 96%, transparent);
	mask-image: linear-gradient(90deg, transparent, #000 4%, #000 96%, transparent);
}

.haiku-partners__track {
	display: flex;
	align-items: center;
	gap: clamp(40px, 5.74vw, 82.629px);
	width: max-content;
	/* Paced per logo, not per loop, so adding partners lengthens the cycle
	   instead of speeding the scroll up. Falls back to the original 7-logo
	   timing if the inline count is ever missing. */
	animation: haiku-marquee calc(var(--haiku-partner-count, 7) * 5.43s) linear infinite;
}

.haiku-partners__viewport:hover .haiku-partners__track {
	animation-play-state: paused;
}

.haiku-partners__logo {
	flex: none;
	display: flex;
	align-items: center;
	justify-content: center;
	height: 70px;
}

.haiku-partners__logo img {
	/* Pinned rather than capped so the painted size matches the width/height
	   attributes the template measures, leaving the track width fixed. */
	height: 70px;
	width: auto;
	object-fit: contain;
}

@keyframes haiku-marquee {
	from { transform: translateX(0); }
	to   { transform: translateX(calc(-50% - clamp(40px, 5.74vw, 82.629px) / 2)); }
}

@media (prefers-reduced-motion: reduce) {
	.haiku-partners__track {
		animation: none;
	}

	.haiku-partners__viewport {
		overflow-x: auto;
	}
}

/* ------------------------------------------------------------- gallery ---- */

.haiku-gallery {
	padding-top: clamp(48px, 8.1vw, 117px);
}

.haiku-gallery__inner {
	display: flex;
	gap: clamp(10px, 1.74vw, 25px);
	height: clamp(140px, 17.4vw, 250px);
}

.haiku-gallery__item {
	position: relative;
	flex: 250 1 0;
	overflow: hidden;
	background: var(--haiku-gold);
}

.haiku-gallery__item.is-edge {
	flex: 173 1 0;
}

.haiku-gallery__item img {
	width: 100%;
	height: 100%;
	object-fit: cover;
}

.haiku-gallery__item.is-edge::after {
	content: "";
	position: absolute;
	inset: 0;
}

/*
 * The two outer frames feather into the cream so the band has no hard vertical
 * cut at either end. Keep the wash short and short of opaque — it is there to
 * soften the edge, not to veil the photograph, and anything heavier reads as
 * an out-of-focus image rather than a fade.
 */
.haiku-gallery__item.is-edge--start::after {
	background: linear-gradient(90deg, rgba(254, 247, 236, 0.7) 0%, rgba(254, 247, 236, 0) 26%);
}

.haiku-gallery__item.is-edge--end::after {
	background: linear-gradient(90deg, rgba(254, 247, 236, 0) 74%, rgba(254, 247, 236, 0.7) 100%);
}

/* --------------------------------------------------------------- story ---- */

.haiku-story {
	padding-top: clamp(48px, 4.4vw, 63px);
}

.haiku-story__inner {
	position: relative;
	max-width: 1440px;
	margin-inline: auto;
	padding-inline: var(--haiku-gutter);
	padding-bottom: clamp(0px, 1vw, 12px);
}

.haiku-story__text {
	max-width: 662px;
}

.haiku-story__heading {
	font-family: var(--haiku-serif);
	font-variation-settings: "opsz" 20;
	font-style: italic;
	font-weight: 400;
	font-size: clamp(26px, 2.78vw, 40px);
	line-height: 1.25;
	color: var(--haiku-teal);
	max-width: 711px;
}

.haiku-story__heading em {
	font-style: inherit;
	color: var(--haiku-gold-dark);
}

.haiku-story__body {
	margin-top: clamp(24px, 2.15vw, 31px);
	font-size: 16px;
	line-height: 28px;
	color: var(--haiku-ink);
}

.haiku-story__body p + p {
	margin-top: 28px;
}

.haiku-story__media {
	position: absolute;
	inset: 0;
	pointer-events: none;
}

.haiku-story__photo {
	position: absolute;
}

.haiku-story__photo::after {
	content: "";
	position: absolute;
	inset: 0;
}

.haiku-story__photo img {
	width: 100%;
	height: 100%;
	object-fit: cover;
}

.haiku-story__photo--one {
	left: 58.78%;
	width: 30.76%;
	top: 0;
	aspect-ratio: 443 / 332;
}

.haiku-story__photo--one::after {
	background: linear-gradient(180deg, rgba(254, 247, 236, 0) 72%, var(--haiku-cream) 100%);
}

.haiku-story__photo--two {
	left: 70.04%;
	width: 24.96%;
	top: 179px;
	aspect-ratio: 417 / 380;
}

.haiku-story__photo--two::after {
	background: linear-gradient(180deg, rgba(254, 247, 236, 0) 85%, var(--haiku-cream) 100%);
}

/* -------------------------------------------------------- destinations ---- */

.haiku-destinations {
	padding-top: clamp(64px, 7.9vw, 114px);
}

.haiku-destinations__heading {
	font-family: var(--haiku-serif);
	font-variation-settings: "opsz" 15;
	font-weight: 400;
	font-size: clamp(26px, 3.33vw, 48px);
	line-height: 1.15;
	color: var(--haiku-teal);
	text-transform: uppercase;
	text-align: center;
	padding-inline: var(--haiku-gutter);
}

/*
 * Ten destinations outrun one line on anything but a very wide desktop, so the
 * strip scrolls sideways. On a laptop that leaves the names at either end
 * sliced off at the viewport edge with nothing to say the rest are there — the
 * arrows are that signal. They page the strip along, and each one dims at the
 * end it can no longer travel towards. Phones keep the bare scroller: a swipe
 * is its own affordance there and the arrows would only eat width.
 */
.haiku-destinations__strip {
	display: flex;
	align-items: center;
	gap: clamp(6px, 0.8vw, 12px);
	margin-top: clamp(28px, 3.6vw, 52px);
	padding-inline: clamp(12px, 3vw, 44px);
}

.haiku-destinations__tabs {
	flex: 1 1 auto;
	min-width: 0;
	display: flex;
	align-items: center;
	justify-content: flex-start;
	gap: clamp(20px, 2.38vw, 34.317px);
	overflow-x: auto;
	scrollbar-width: none;
	scroll-behavior: smooth;
}

.haiku-destinations__tabs::-webkit-scrollbar {
	display: none;
}

/*
 * Centring an overflowing scroller strands its first item out of reach in some
 * browsers, so the strip only centres once the script has confirmed the whole
 * set fits. Left alone — no script — it stays scrollable from the start edge,
 * which is always reachable.
 */
.haiku-destinations__strip.is-static .haiku-destinations__tabs {
	justify-content: center;
}

.haiku-tabnav {
	flex: none;
	display: flex;
	align-items: center;
	justify-content: center;
	opacity: 0.85;
	transition: opacity 0.2s ease, transform 0.2s ease;
}

/* Bare chevron, kept to the 24:44 of the artwork so it cannot squash. */
.haiku-tabnav img {
	width: clamp(11px, 1vw, 14px);
	height: clamp(20px, 1.8vw, 26px);
}

.haiku-tabnav--prev img {
	transform: rotate(180deg);
}

.haiku-tabnav:hover {
	opacity: 1;
	transform: scale(1.06);
}

.haiku-tabnav[disabled] {
	opacity: 0.2;
	cursor: default;
}

.haiku-destinations__strip.is-static .haiku-tabnav {
	display: none;
}

@media (prefers-reduced-motion: reduce) {
	.haiku-destinations__tabs {
		scroll-behavior: auto;
	}
}

.haiku-tab {
	flex: none;
	display: flex;
	align-items: center;
	gap: 12.412px;
	min-height: 53.3px;
}

/* The rule tracks its own label, so a three-line name keeps a full-height rule. */
.haiku-tab__rule {
	flex: none;
	align-self: stretch;
	width: 2.921px;
	min-height: 53.3px;
	background: rgba(0, 0, 0, 0.1);
	transition: background-color 0.3s ease;
}

.haiku-tab__label {
	display: flex;
	flex-direction: column;
	font-family: var(--haiku-serif);
	font-variation-settings: "opsz" 11;
	font-weight: 400;
	font-size: clamp(13px, 1.22vw, 17.52px);
	line-height: 20.444px;
	color: rgba(0, 0, 0, 0.5);
	text-transform: uppercase;
	text-align: left;
	white-space: nowrap;
	transition: color 0.3s ease;
}

.haiku-tab:hover .haiku-tab__label {
	color: rgba(2, 46, 55, 0.8);
}

.haiku-tab.is-active .haiku-tab__rule {
	background: var(--haiku-gold);
}

.haiku-tab.is-active .haiku-tab__label {
	color: var(--haiku-teal);
}

.haiku-panel {
	position: relative;
	/* Ground under the plates, and the whole surface for a section whose
	   artwork has not landed yet — the gold title needs the dark behind it. */
	background: var(--haiku-teal);
	margin-top: clamp(28px, 3.7vw, 53px);
	min-height: clamp(420px, 45.5vw, 655px);
	display: flex;
	align-items: center;
	overflow: hidden;
}

.haiku-panel[hidden] {
	display: none;
}

/*
 * The plates stack and crossfade; the bars under the CTA pick which one shows.
 * Only the active plate is painted, so the inactive ones cost nothing but the
 * download.
 */
.haiku-panel__media {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	object-fit: cover;
	opacity: 0;
	transition: opacity 0.6s ease-in-out;
}

.haiku-panel__media.is-active {
	opacity: 1;
}

@media ( prefers-reduced-motion: reduce ) {
	.haiku-panel__media {
		transition-duration: 0.01ms;
	}
}

.haiku-panel__inner {
	position: relative;
	z-index: 2;
	width: 100%;
	display: flex;
	flex-direction: column;
	gap: clamp(24px, 2.4vw, 34px);
	padding: clamp(48px, 5.7vw, 82px) clamp(24px, 8.5vw, 123px);
}

.haiku-panel__copy {
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	gap: 23px;
	max-width: 500px;
}

.haiku-panel__title {
	display: flex;
	flex-direction: column;
	font-family: var(--haiku-serif);
	font-variation-settings: "opsz" 25;
	font-weight: 400;
	font-size: clamp(36px, 4.44vw, 64px);
	line-height: 1.125;
	letter-spacing: -0.02em;
	color: var(--haiku-gold);
	text-transform: uppercase;
}

/*
 * A name that carries its own qualifier — "Cruises, Yachts and Private Jets" —
 * outruns the copy column at the display size and stacks the CTA off the plate,
 * so it steps down instead. The template picks this per destination.
 */
.haiku-panel__title--compact {
	font-size: clamp(26px, 3.06vw, 44px);
}

.haiku-panel__subtitle {
	font-weight: 300;
	font-size: clamp(16px, 1.53vw, 22px);
	line-height: 1.36;
	letter-spacing: -0.02em;
	color: #fff;
	text-transform: uppercase;
}

.haiku-panel__body {
	font-weight: 300;
	font-size: 16px;
	line-height: 25px;
	color: #fff;
	max-width: 323px;
}

.haiku-panel__bars {
	display: flex;
	align-items: center;
	gap: 14.382px;
	flex-wrap: wrap;
}

.haiku-panel__bar {
	width: clamp(36px, 4.8vw, 69.294px);
	height: 5.23px;
	background: rgba(255, 255, 255, 0.3);
	transition: background-color 0.3s ease;
}

.haiku-panel__bar.is-active,
.haiku-panel__bar:hover {
	background: #fff;
}

/* ---------------------------------------------------------- experience ---- */

.haiku-experience {
	padding-top: clamp(64px, 9.6vw, 138px);
}

.haiku-experience__inner {
	position: relative;
	max-width: 1440px;
	margin-inline: auto;
	padding-inline: var(--haiku-gutter);
	display: grid;
	grid-template-columns: minmax(0, 576px) minmax(0, 1fr);
	/* gap: clamp(32px, 4vw, 58px); */
	align-items: start;
}

.haiku-experience__eyebrow {
	font-family: var(--haiku-serif);
	font-variation-settings: "opsz" 11;
	font-weight: 500;
	font-size: clamp(18px, 1.67vw, 24px);
	line-height: 1.2;
	color: var(--haiku-gold);
	text-transform: uppercase;
}

.haiku-experience__heading {
	margin-top: clamp(16px, 1.2vw, 17px);
	font-family: var(--haiku-serif);
	font-variation-settings: "opsz" 16;
	font-style: italic;
	font-weight: 400;
	font-size: clamp(26px, 2.78vw, 40px);
	line-height: 1.25;
	letter-spacing: -0.02em;
	color: var(--haiku-teal);
}

.haiku-experience__body {
	margin-top: clamp(24px, 3.5vw, 50px);
	font-size: 16px;
	line-height: 28px;
	color: var(--haiku-ink);
	max-width: 534px;
	margin-bottom: 20px;
}

.haiku-experience__hero {
	background: #d9d9d9;
	aspect-ratio: 588 / 392;
	overflow: hidden;
}

.haiku-experience__hero img {
	width: 100%;
	height: 100%;
	object-fit: cover;
}

.haiku-experience__grid {
	margin-top: clamp(32px, 3vw, 43px);
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: clamp(12px, 2.9vw, 42px);
}

.haiku-experience__tile {
	background: #d9d9d9;
	aspect-ratio: 370 / 480;
	overflow: hidden;
}

.haiku-experience__tile img {
	width: 100%;
	height: 100%;
	object-fit: cover;
}

/* -------------------------------------------------------- testimonials ---- */

.haiku-testimonials {
	position: relative;
	padding: clamp(60px, 8.75vw, 126px) var(--haiku-gutter) clamp(60px, 6vw, 86px);
	text-align: center;
	overflow: hidden;
}

.haiku-testimonials__mark {
	position: absolute;
	top: 0;
	left: 50%;
	transform: translateX(-50%);
	font-family: var(--haiku-display);
	font-size: clamp(180px, 26vw, 374px);
	line-height: 1.2;
	letter-spacing: -0.03em;
	color: rgba(2, 46, 55, 0.05);
	pointer-events: none;
	user-select: none;
}

.haiku-testimonials__heading {
	position: relative;
	z-index: 2;
	font-family: var(--haiku-serif);
	font-variation-settings: "opsz" 16;
	font-weight: 400;
	font-size: clamp(26px, 3.33vw, 48px);
	line-height: 1.15;
	color: var(--haiku-teal);
	text-transform: uppercase;
}

/*
 * Three quotes sit side by side and the track slides one card per arrow click.
 * The viewport clips the overflow; the track itself is the only thing that
 * moves, so nothing below the section ever shifts. Card widths come from the
 * --haiku-quotes-per-view custom property, which the media queries below step
 * down — the script reads the rendered card width back off the DOM rather than
 * duplicating the breakpoints.
 */
.haiku-testimonials__viewport {
	--haiku-quotes-per-view: 3;
	--haiku-quotes-gap: 24px;
	--haiku-quote-lines: 12;
	position: relative;
	z-index: 2;
	margin-top: clamp(28px, 2.9vw, 42px);
	margin-inline: auto;
	max-width: 1240px;
	overflow: hidden;
}

.haiku-testimonials__track {
	display: flex;
	align-items: stretch;
	gap: var(--haiku-quotes-gap);
	transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1);
	will-change: transform;
}

.haiku-quote {
	flex: 0 0 calc(
		(100% - var(--haiku-quotes-gap) * (var(--haiku-quotes-per-view) - 1)) /
		var(--haiku-quotes-per-view)
	);
	display: flex;
	flex-direction: column;
	padding: clamp(24px, 2.4vw, 34px) clamp(20px, 2.1vw, 30px);
	border: 1px solid rgba(2, 46, 55, 0.12);
	border-radius: 4px;
	text-align: center;
}

@media ( prefers-reduced-motion: reduce ) {
	.haiku-testimonials__track,
	.haiku-testimonials__viewport {
		transition-duration: 0.01ms;
	}
}

/*
 * margin-top:auto on the author below keeps all three names on the card floor
 * whether a card is clamped, open, or neither.
 */
.haiku-quote__text {
	flex: 0 1 auto;
	font-weight: 300;
	font-size: 17px;
	line-height: 30px;
	color: var(--haiku-muted);
}

/*
 * The track stretches every card to the tallest one, so a single very long
 * quote would set the height of the whole row. Clamping is opt-in per
 * testimonial rather than blanket: only a quote flagged long in the data gets
 * --long, so every other one still renders in full, exactly as before.
 */
.haiku-quote--long .haiku-quote__text {
	display: -webkit-box;
	-webkit-box-orient: vertical;
	-webkit-line-clamp: var(--haiku-quote-lines, 12);
	line-clamp: var(--haiku-quote-lines, 12);
	overflow: hidden;
}

/* Same specificity as the rule above, and after it, so opening wins. */
.haiku-quote--open .haiku-quote__text {
	display: block;
	-webkit-line-clamp: none;
	line-clamp: none;
	overflow: visible;
}

/* Only clipped cards get one of these, and only once the script has measured. */
.haiku-quote__more {
	align-self: center;
	margin-top: 14px;
	padding: 0;
	border: 0;
	border-bottom: 1px solid currentColor;
	background: none;
	font-family: inherit;
	font-size: 13px;
	font-weight: 400;
	letter-spacing: 0.12em;
	line-height: 1.6;
	text-transform: uppercase;
	color: var(--haiku-teal);
	cursor: pointer;
	transition: opacity 0.2s ease;
}

.haiku-quote__more:hover,
.haiku-quote__more:focus-visible {
	opacity: 0.6;
}

.haiku-quote__author {
	margin-top: auto;
	padding-top: 24px;
	font-family: var(--haiku-serif);
	font-variation-settings: "opsz" 21;
	font-style: italic;
	font-weight: 400;
	font-size: 24px;
	line-height: 35px;
	color: var(--haiku-slate);
}

.haiku-testimonials__controls {
	position: relative;
	z-index: 2;
	margin-top: clamp(24px, 2.2vw, 31px);
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 12px;
}

.haiku-arrow img {
	width: 49px;
	height: 49px;
}

.haiku-arrow--prev img {
	transform: rotate(180deg);
}

.haiku-arrow {
	transition: opacity 0.2s ease, transform 0.2s ease;
	opacity: 0.85;
}

.haiku-arrow:hover {
	opacity: 1;
	transform: scale(1.06);
}

/* -------------------------------------------------------------- curate ---- */

.haiku-curate {
	background: rgba(2, 46, 55, 0.9);
	padding: clamp(64px, 7.3vw, 105px) var(--haiku-gutter) clamp(64px, 7.4vw, 106px);
}

.haiku-curate__inner {
	max-width: 765px;
	margin-inline: auto;
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 25px;
	text-align: center;
}

.haiku-curate__heading {
	font-family: var(--haiku-serif);
	font-variation-settings: "opsz" 16;
	font-weight: 400;
	font-size: clamp(26px, 3.33vw, 48px);
	line-height: 1.25;
	color: #fff;
	text-transform: uppercase;
}

.haiku-curate__heading em {
	font-style: normal;
	color: var(--haiku-gold);
}

.haiku-curate__actions {
	display: flex;
	align-items: center;
	gap: 16px;
	flex-wrap: wrap;
	justify-content: center;
}

/* -------------------------------------------------------------- footer ---- */

.haiku-footer {
	background: var(--haiku-teal);
	display: flex;
	align-items: center;
}

.haiku-footer__inner {
	width: 100%;
	display: flex;
	align-items: center;
	justify-content: space-between;
	column-gap: clamp(20px, 3vw, 44px);
	row-gap: 10px;
	padding-block: 20px;

	/*
	 * One strip of logo | email | copyright, and it stays one strip right down
	 * to the 1024px rules that stack it. Letting it wrap instead is what breaks
	 * the dividers: flex chooses its line breaks from each item's content width
	 * before any shrinking happens, so the copyright drops to a second row while
	 * there is still room to shrink it — and takes the divider down its left
	 * with it, ruling off the empty space beside the logo. Held on one line it
	 * shrinks as intended and the sentence wraps inside its own box.
	 */
	flex-wrap: nowrap;
}

.haiku-footer__logo img {
	width: clamp(160px, 17.3vw, 248px);
	height: auto;
}

.haiku-footer__contact {
	display: flex;
	align-items: center;
	gap: 13.32px;
	height: 80px;
	font-family: var(--haiku-serif);
	font-variation-settings: "opsz" 11;
	font-weight: 400;
	font-size: clamp(15px, 1.45vw, 20.935px);
	color: #fff;
	text-transform: uppercase;
	white-space: nowrap;
	transition: color 0.25s ease;
}

.haiku-footer__contact img {
	width: 24.424px;
	height: 24.424px;
	flex: none;
}

.haiku-footer__contact:hover {
	color: var(--haiku-gold);
}

/* Everything after the logo is fenced off from what precedes it. */
.haiku-footer__contact--divided,
.haiku-footer__copyright {
	border-left: 1px solid rgba(255, 255, 255, 0.25);
	padding-left: clamp(20px, 3vw, 44px);
}

/*
 * Dropping the phone freed the width for one strip — logo | email | copyright —
 * rather than the copyright taking a second row to itself. It stretches to the
 * row height the email sets so its divider matches that one instead of ruling
 * off only its own line of text.
 *
 * min-width lets it shrink past its text, so when the strip runs short it is
 * the sentence that wraps to two lines and not the block that drops to a row of
 * its own. A block that dropped would carry its divider down with it and rule
 * off the empty space beside the logo.
 */
.haiku-footer__copyright {
	align-self: stretch;
	display: flex;
	align-items: center;
	min-width: 0;
	font-weight: 300;
	font-size: 14px;
	line-height: 20px;
	color: #fff;
}

/* ------------------------------------------------- astra scroll-to-top ---- */

/*
 * Astra prints #ast-scroll-top on wp_footer and this template drops Astra's
 * stylesheet, so the button arrives unstyled. Two constraints shape the rules
 * below:
 *
 * 1. Astra's frontend.js owns `display` — it writes inline `display:block` past
 *    300px of scroll and `display:none` above that. So the base state here is
 *    `display:none` (JS reveals it) and the glyph is centred with line-height
 *    rather than flex, which the inline `display:block` would clobber.
 * 2. The arrow SVG ships without a fill attribute and points down, hence the
 *    `fill: currentColor` and the 180deg rotation.
 */
#ast-scroll-top {
	display: none;
	position: fixed;
	bottom: clamp(20px, 2.2vw, 32px);
	z-index: 25;
	width: 48px;
	height: 48px;
	line-height: 48px;
	text-align: center;
	border-radius: 50%;
	background: var(--haiku-gold);
	color: var(--haiku-teal);
	cursor: pointer;
	box-shadow: 0 6px 20px rgba(2, 46, 55, 0.25);
	transition: transform 0.25s ease, background-color 0.25s ease, box-shadow 0.25s ease;
}

#ast-scroll-top.ast-scroll-to-top-right {
	right: clamp(20px, 2.2vw, 32px);
}

#ast-scroll-top.ast-scroll-to-top-left {
	left: clamp(20px, 2.2vw, 32px);
}

#ast-scroll-top svg {
	display: inline-block;
	vertical-align: middle;
	width: 18px;
	height: auto;
	fill: currentColor;
	transform: rotate(180deg);
}

#ast-scroll-top:hover {
	background: #fff;
	transform: translateY(-3px);
	box-shadow: 0 12px 28px rgba(2, 46, 55, 0.32);
}

/* Astra normally supplies this; without its stylesheet the label renders. */
.haiku-page .screen-reader-text {
	position: absolute;
	width: 1px;
	height: 1px;
	margin: -1px;
	padding: 0;
	overflow: hidden;
	clip: rect(0, 0, 0, 0);
	clip-path: inset(50%);
	border: 0;
	white-space: nowrap;
}

/* --------------------------------------------------------- breakpoints ---- */

@media (max-width: 1200px) {
	.haiku-story__photo--two {
		top: 14vw;
	}

}

@media (max-width: 1024px) {
	.haiku-testimonials__viewport {
		--haiku-quotes-per-view: 2;
		--haiku-quotes-gap: 20px;
	}

	.haiku-header__toggle {
		display: flex;
	}

	.haiku-nav {
		position: fixed;
		inset: 0;
		flex-direction: column;
		justify-content: center;
		gap: 28px;
		background: var(--haiku-teal);
		transform: translateX(100%);
		transition: transform 0.35s ease;
		z-index: 30;
	}

	.haiku-nav.is-open {
		transform: translateX(0);
	}

	.haiku-nav__link {
		font-size: 22px;
	}

	.haiku-header__toggle {
		position: relative;
		z-index: 40;
	}

	.haiku-story__inner {
		display: flex;
		flex-direction: column;
		gap: 40px;
	}

	.haiku-story__text {
		max-width: none;
		order: 2;
	}

	.haiku-story__media {
		position: relative;
		inset: auto;
		order: 1;
		display: flex;
		gap: 16px;
		height: auto;
	}

	.haiku-story__photo {
		position: relative;
		left: auto;
		top: auto;
		width: 50%;
	}

	.haiku-experience__inner {
		grid-template-columns: minmax(0, 1fr);
	}

	.haiku-footer__inner {
		justify-content: center;
		text-align: center;
		padding-block: 32px;
		/* Stacked now, so the strip is free to break into rows again. */
		flex-wrap: wrap;
	}

	/* Stacked, so the dividers and the fixed strip height go. */
	.haiku-footer__contact {
		height: auto;
		border-left: 0;
		padding-left: 0;
	}

	/*
	 * The copyright is what drops to its own row here, so its divider would
	 * rule off the space beside the logo rather than separating anything.
	 * Centred under the stack instead, like the rest of it.
	 */
	.haiku-footer__copyright {
		align-self: center;
		justify-content: center;
		border-left: 0;
		padding-left: 0;
	}
}

@media (max-width: 768px) {
	.haiku-testimonials__viewport {
		--haiku-quotes-per-view: 1;
		--haiku-quotes-gap: 16px;
		max-width: 520px;
		transition: height 0.5s cubic-bezier(0.4, 0, 0.2, 1);
	}

	/*
	 * Phones keep the plain scroller they always had: a swipe already says
	 * there is more, and two arrows would take width the names need.
	 */
	.haiku-destinations__strip {
		padding-inline: 0;
	}

	.haiku-destinations__tabs {
		padding-inline: var(--haiku-gutter);
	}

	.haiku-tabnav {
		display: none;
	}

	/*
	 * One card per view: stretching every card to the tallest quote leaves a
	 * long empty run under the short ones and strands the arrows far below the
	 * text. Let each card keep its own height instead — the script sizes the
	 * viewport to the active card so nothing under the section jumps.
	 */
	.haiku-testimonials__track {
		align-items: flex-start;
	}

	/*
	 * The hero is only ~700px of stage for a much shorter stack on phones, so
	 * the block reads as pinned to the top. Fill the screen instead and centre
	 * the stack in it, with the top padding kept larger than the bottom so the
	 * content clears the header that floats over the hero.
	 */
	.haiku-hero {
		min-height: 100svh;
		align-items: center;
	}

	.haiku-hero__content {
		padding-top: 160px;
		padding-bottom: 80px;
	}

	.haiku-partners__inner {
		flex-direction: column;
		align-items: stretch;
		gap: 16px;
		padding-block: 24px;
	}

	.haiku-partners__label {
		width: auto;
		text-align: center;
	}

	.haiku-gallery__inner {
		height: 130px;
	}

	/*
	 * On phones the story reads first and the founder photos close it out, so
	 * flip the tablet order: copy on top, the pair of images beneath it.
	 */
	.haiku-story__text {
		order: 1;
	}

	.haiku-story__media {
		order: 2;
		align-items: flex-start;
	}

	/*
	 * The two cutouts have different source ratios (575x431 vs 361x330), so
	 * side by side one box ends up shorter and its face reads smaller. Give
	 * both the same portrait box, crop to the subject, and nudge the wider
	 * photo up in scale so the two faces land at a similar size.
	 */
	.haiku-story__photo--one,
	.haiku-story__photo--two {
		width: 50%;
		aspect-ratio: 4 / 5;
		overflow: hidden;
	}

	.haiku-story__photo--one img {
		object-position: 43% 50%;
		transform: scale(1.15);
		transform-origin: 50% 12%;
	}

	.haiku-story__photo--two img {
		object-position: 47% 50%;
	}

	/* Match the bottom fade too, so neither photo reads as washed out. */
	.haiku-story__photo--one::after {
		background: linear-gradient(180deg, rgba(254, 247, 236, 0) 85%, var(--haiku-cream) 100%);
	}

	.haiku-experience__grid {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}

	.haiku-experience__tile:last-child {
		grid-column: span 2;
		aspect-ratio: 16 / 9;
	}

	.haiku-curate__actions {
		flex-direction: column;
		align-items: stretch;
		width: 100%;
	}

	.haiku-curate__actions .haiku-cta {
		width: 100%;
	}

	#ast-scroll-top {
		width: 42px;
		height: 42px;
		line-height: 42px;
	}

	#ast-scroll-top svg {
		width: 16px;
	}
}

@media (max-width: 560px) {
	.haiku-gallery__item:nth-child(4),
	.haiku-gallery__item:nth-child(5) {
		display: none;
	}

	/* Keep the two founder photos side by side, even on the narrowest phones. */
	.haiku-story__media {
		flex-direction: row;
		gap: 12px;
	}

	.haiku-story__photo {
		width: 50%;
	}

	.haiku-quote__text {
		font-size: 16px;
		line-height: 30px;
	}

}

/* ---------------------------------------------------- elementor build ---- */

/*
 * The Elementor import wraps every section in a container and an HTML widget.
 * Neither may contribute a box of its own: the design's own sections already
 * own their width, gutters and vertical rhythm, and the Kit's default content
 * width would otherwise pull the full-bleed sections in. Flatten the wrappers
 * rather than fight them section by section.
 *
 * Only wrappers inside .haiku-section are touched, so any other Elementor page
 * on the site keeps its normal layout.
 */
.haiku-page .haiku-section,
.haiku-page .haiku-section > .e-con-inner,
.haiku-page .haiku-section .elementor-widget,
.haiku-page .haiku-section .elementor-widget-container {
	width: 100%;
	max-width: none;
	margin: 0;
	padding: 0;
	border: 0;
	background: none;
}

.haiku-page .haiku-section {
	--content-width: 100%;
	display: block;
}

/* Elementor adds its own top-level wrapper around the builder output. */
.haiku-page .elementor,
.haiku-page .elementor-inner,
.haiku-page .elementor-section-wrap {
	width: 100%;
	max-width: none;
	margin: 0;
	padding: 0;
}
