/* ==========================================================================
   Hanna Theme
   Design reference: Figma "Hanna Plastic Surgery | Website" (1920 desktop,
   550 mobile). Fluid values interpolate between a 390px and 1920px viewport.
   ========================================================================== */

/* Fonts ------------------------------------------------------------------- */

@font-face { font-family: "Satoshi"; src: url("../fonts/satoshi-400-normal.woff2") format("woff2"); font-weight: 400; font-style: normal; font-display: swap; }
@font-face { font-family: "Satoshi"; src: url("../fonts/satoshi-400-italic.woff2") format("woff2"); font-weight: 400; font-style: italic; font-display: swap; }
@font-face { font-family: "Satoshi"; src: url("../fonts/satoshi-500-normal.woff2") format("woff2"); font-weight: 500; font-style: normal; font-display: swap; }
@font-face { font-family: "Satoshi"; src: url("../fonts/satoshi-700-normal.woff2") format("woff2"); font-weight: 700; font-style: normal; font-display: swap; }
/* Free stand-in for Canela (closest widths), and the fallback for characters the
   Canela Trial files lack. "Canela Web" is declared in inc/enqueue.php when its files are present. */
@font-face { font-family: "Boska"; src: url("../fonts/boska-300-normal.woff2") format("woff2"); font-weight: 300; font-style: normal; font-display: swap; }
@font-face { font-family: "Boska"; src: url("../fonts/boska-300-italic.woff2") format("woff2"); font-weight: 300; font-style: italic; font-display: swap; }

/* Tokens ------------------------------------------------------------------ */

:root {
	--color-black: #000;
	--color-ink: #231f1b;
	--color-white: #fff;
	--color-subtle: #f0f0ee;
	--color-footer: #fffaf0;
	--color-accent: #b39e9d;
	--color-accent-hover: #a28b8a;
	--color-accent-dark: #9b746d;
	--color-strong: #3c3c3c;
	--color-divider: #d0d0c6;
	--color-border-muted: #aeaeae;
	--color-placeholder: #e5e5e3;

	--font-serif: "Canela Web", "Boska", Georgia, "Times New Roman", serif;
	--font-sans: "Satoshi", "Helvetica Neue", Arial, sans-serif;

	--fluid: (100vw - 390px) / 1530;
	--fs-display: clamp(46px, calc(46px + 65 * var(--fluid)), 111px);
	--fs-h1: clamp(44px, calc(44px + 56 * var(--fluid)), 100px);
	--fs-h2: clamp(38px, calc(38px + 37 * var(--fluid)), 75px);
	--fs-h3: clamp(34px, calc(34px + 26 * var(--fluid)), 60px);
	--fs-h4: clamp(25px, calc(25px + 15 * var(--fluid)), 40px);
	--fs-h5: clamp(21px, calc(21px + 10 * var(--fluid)), 31px);
	--fs-body: clamp(17px, calc(17px + 5 * var(--fluid)), 22px);
	--fs-lead: clamp(18px, calc(18px + 7 * var(--fluid)), 25px);
	--fs-button: clamp(16px, calc(16px + 2 * var(--fluid)), 18px);

	--gutter: clamp(20px, calc(20px + 105 * var(--fluid)), 125px);
	--inset: clamp(0px, calc(25 * var(--fluid)), 25px);
	--section-gap: clamp(72px, calc(72px + 98 * var(--fluid)), 170px);
	--content-max: 1670px;
	--radius: 12px;
	--radius-card: 12px;
	--shadow-soft: 0 10px 50px rgba(0, 0, 0, 0.1);

	/* Motion: one soft ease-out site-wide. Appearances use the reveal times (see
	   "Motion" at the end of this file), the header's changes the state time,
	   hovers the hover time. */
	--ease-soft: cubic-bezier(0.22, 1, 0.36, 1);
	--motion-reveal: 700ms;
	--motion-image: 900ms;
	--motion-state: 350ms;
	--motion-hover: 300ms;
	--motion-travel: 16px;
	--motion-stagger: 100ms;

	/* Height of the compact header bar once the page scrolls. */
	--header-stuck-h: 64px;
}

/* Phones scale from 390px up to the 550px mobile artboard, then hold its values. */
@media (max-width: 767px) {
	:root {
		--fluid-m: (100vw - 390px) / 160;
		--fs-display: clamp(46px, calc(46px + 14 * var(--fluid-m)), 60px);
		--fs-h1: clamp(44px, calc(44px + 16 * var(--fluid-m)), 60px);
		--fs-h2: clamp(38px, calc(38px + 17 * var(--fluid-m)), 55px);
		--fs-h3: clamp(34px, calc(34px + 16 * var(--fluid-m)), 50px);
		--fs-h4: clamp(25px, calc(25px + 10 * var(--fluid-m)), 35px);
		--fs-h5: clamp(21px, calc(21px + 4 * var(--fluid-m)), 25px);
		--fs-body: clamp(17px, calc(17px + 5 * var(--fluid-m)), 22px);
		--fs-lead: clamp(18px, calc(18px + 4 * var(--fluid-m)), 22px);
		--fs-button: clamp(16px, calc(16px + 4 * var(--fluid-m)), 20px);

		--gutter: clamp(20px, calc(20px + 15 * var(--fluid-m)), 35px);
		--inset: 0px;
		--section-gap: clamp(72px, calc(72px + 28 * var(--fluid-m)), 100px);
		--radius-card: 0px;
	}
}

/* Base -------------------------------------------------------------------- */

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

html {
	-webkit-text-size-adjust: 100%;
}

/* In-page links land below the header (and the WordPress toolbar when logged in). */
:root {
	scroll-padding-top: calc(var(--header-stuck-h) + var(--wp-admin--admin-bar--height, 0px));
}

body {
	margin: 0;
	background: var(--color-white);
	color: var(--color-black);
	font-family: var(--font-sans);
	font-size: var(--fs-body);
	line-height: 1.5;
	-webkit-font-smoothing: antialiased;
	-moz-osx-font-smoothing: grayscale;
}

body.menu-open {
	overflow: hidden;
}

img,
svg {
	display: block;
	max-width: 100%;
	height: auto;
}

a {
	color: inherit;
}

h1, h2, h3, h4, h5, h6, p, figure, blockquote {
	margin: 0;
}

button {
	padding: 0;
	border: 0;
	background: none;
	color: inherit;
	font: inherit;
	cursor: pointer;
}

:focus-visible {
	outline: 2px solid var(--color-accent);
	outline-offset: 3px;
}

.screen-reader-text {
	position: absolute !important;
	width: 1px;
	height: 1px;
	overflow: hidden;
	clip: rect(1px, 1px, 1px, 1px);
	clip-path: inset(50%);
	white-space: nowrap;
}

.skip-link:focus {
	z-index: 100;
	top: calc(12px + var(--wp-admin--admin-bar--height, 0px));
	left: 12px;
	width: auto;
	height: auto;
	padding: 12px 20px;
	clip: auto;
	clip-path: none;
	background: var(--color-white);
	color: var(--color-black);
}

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

.container {
	width: 100%;
	max-width: calc(var(--content-max) + 2 * var(--gutter));
	margin-inline: auto;
	padding-inline: var(--gutter);
}

.site-main--home {
	display: flex;
	flex-direction: column;
	gap: var(--section-gap);
	padding-bottom: var(--section-gap);
}

.stack-tight {
	display: flex;
	flex-direction: column;
	gap: clamp(10px, calc(10px + 20 * var(--fluid)), 30px);
}

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

/* Typography -------------------------------------------------------------- */

.heading-display,
.heading-1,
.heading-2,
.heading-3,
.heading-4,
.heading-5 {
	font-family: var(--font-serif);
	font-weight: 300;
}

.heading-display em,
.heading-1 em,
.heading-2 em,
.heading-3 em,
.heading-4 em,
.heading-5 em {
	font-style: italic;
	color: var(--color-accent);
}

.heading-display {
	font-size: var(--fs-display);
	line-height: 0.91;
	letter-spacing: -0.01em;
}

.heading-1 {
	font-size: var(--fs-h1);
	line-height: 1;
	letter-spacing: -0.02em;
}

.heading-2 {
	font-size: var(--fs-h2);
	line-height: 0.94;
	letter-spacing: -0.027em;
}

.heading-3 {
	font-size: var(--fs-h3);
	line-height: 1;
	letter-spacing: -0.033em;
}

.heading-4 {
	font-size: var(--fs-h4);
	line-height: 1.125;
	letter-spacing: -1px;
}

.heading-5 {
	font-size: var(--fs-h5);
	line-height: 1.1;
}

/* Line breaks typed into headings are tuned for full desktop widths. */
@media (max-width: 1439px) {
	.heading-2 br,
	.heading-display br {
		display: none;
	}
}

@media (max-width: 767px) {
	.heading-display,
	.heading-1 {
		line-height: 1;
	}

	.heading-2 {
		line-height: 1.09;
	}

	.heading-3,
	.heading-5 {
		line-height: 1.2;
	}

	.heading-4 {
		line-height: 1;
	}

	.heading-1,
	.heading-2,
	.heading-3 {
		letter-spacing: -2px;
	}
}

.rich-text,
.post-content,
.page-content {
	font-size: var(--fs-body);
	line-height: 1.5;
}

.rich-text p + p,
.rich-text p + ul,
.rich-text ul + p {
	margin-top: 0.77em;
}

.rich-text a,
.post-content a,
.page-content a {
	text-decoration: underline;
	text-decoration-thickness: 1px;
	text-underline-offset: 0.18em;
}

.rich-text a:hover,
.post-content a:hover,
.page-content a:hover {
	text-decoration-thickness: 2px;
}

.rich-text ul {
	margin: 0;
	padding-left: 1.2em;
}

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

.btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 10px;
	padding: 20px 30px;
	border-radius: 200px;
	font-family: var(--font-sans);
	font-size: var(--fs-button);
	font-weight: 500;
	line-height: 26px;
	letter-spacing: -0.03em;
	text-decoration: none;
	white-space: nowrap;
	transition: background-color var(--motion-hover) var(--ease-soft), color var(--motion-hover) var(--ease-soft);
}

.btn__icon {
	flex: none;
	width: 9.833px;
	height: 9.333px;
	transform: rotate(-42.6deg);
	transition: transform var(--motion-hover) var(--ease-soft);
}

.btn:hover .btn__icon {
	transform: rotate(-42.6deg) translateX(3px);
}

/* Hover "wave", as on dev3: main.js splits each label into letters, and on
   hover they fade and blur for a moment, one after another (24ms apart). */
.btn-wave__word,
.btn-wave__char {
	display: inline-block;
}

.btn-wave__word {
	white-space: nowrap;
}

@media (prefers-reduced-motion: no-preference) {
	.btn:hover .btn-wave__char,
	.btn:focus-visible .btn-wave__char {
		animation: btn-wave 550ms ease-out both;
		animation-delay: calc(var(--i) * 24ms);
	}
}

@keyframes btn-wave {
	0% {
		opacity: 1;
		filter: blur(0);
	}

	35% {
		opacity: 0.2;
		filter: blur(2px);
	}

	100% {
		opacity: 1;
		filter: blur(0);
	}
}

.btn--dark { background: var(--color-black); color: var(--color-subtle); }
.btn--dark:hover { background: var(--color-strong); }
.btn--light { background: var(--color-subtle); color: var(--color-black); }
.btn--light:hover { background: var(--color-white); }
.btn--strong { background: var(--color-strong); color: var(--color-subtle); }
.btn--strong:hover { background: var(--color-black); }
.btn--accent { background: var(--color-accent); color: var(--color-subtle); }
.btn--accent:hover { background: var(--color-accent-hover); }

.btn--sm {
	padding: 10px 20px;
}

.btn--xl {
	min-width: 335px;
	min-height: 84px;
	font-size: 22px;
	font-weight: 700;
}

.btn--xl .btn__icon {
	width: 14.4px;
	height: 13.7px;
}

@media (max-width: 767px) {
	.btn--lg {
		padding: clamp(17px, calc(17px + 3 * var(--fluid-m)), 20px) clamp(26px, calc(26px + 4 * var(--fluid-m)), 30px);
	}
}

.button-row {
	display: flex;
	flex-wrap: wrap;
	gap: 18px;
}

.arrow-link {
	display: inline-flex;
	align-items: center;
	gap: 13px;
	font-size: var(--fs-body);
	line-height: 1.5;
	text-decoration: none;
}

.arrow-link__icon {
	flex: none;
	width: 9.833px;
	height: 9.333px;
	transform: rotate(-42.6deg);
	transition: transform var(--motion-hover) var(--ease-soft);
}

.arrow-link:hover {
	text-decoration: underline;
	text-underline-offset: 0.18em;
}

.arrow-link:hover .arrow-link__icon {
	transform: rotate(-42.6deg) translateX(3px);
}

/* Header ------------------------------------------------------------------ */

/* The header stays at the top of the screen (the same behaviour as the dev3
   site's). At the top of the page it sits over the hero or the page with no
   background, as on the boards. Once the page scrolls 10px (main.js adds
   .is-stuck) it becomes a compact white bar: less height and padding, dark
   text, and the "Hanna" wordmark crossfades to the smaller "H" monogram. It
   is out of the page flow, so nothing below moves. Back at the top it returns
   to the transparent state. Every change takes the state time (350ms).
   When logged in, WordPress sets --wp-admin--admin-bar--height (32px, 46px on
   narrow screens) and the toolbar pushes the page down; the header, the phone
   menu and the sticky side column move down with it. Anything else that pushes
   the page down (a cookie bar, a browser extension) is caught too: main.js
   measures where the page starts (--page-top), and the header keeps its place
   over the hero. */
.site-header {
	--header-top: clamp(22px, calc(22px + 39 * var(--fluid)), 61px);
	position: fixed;
	z-index: 50;
	top: calc(var(--header-top) + var(--page-top, var(--wp-admin--admin-bar--height, 0px)));
	right: 0;
	left: 0;
	transition:
		top var(--motion-state) var(--ease-soft),
		padding var(--motion-state) var(--ease-soft),
		background-color var(--motion-state) var(--ease-soft),
		box-shadow var(--motion-state) var(--ease-soft),
		color var(--motion-state) var(--ease-soft);
}

.site-header.is-stuck {
	top: var(--wp-admin--admin-bar--height, 0px);
	padding-block: calc((var(--header-stuck-h) - 40px) / 2);
	background-color: var(--color-white);
	box-shadow: 0 2px 12px rgba(0, 0, 0, 0.06);
	color: var(--color-black);
}

/* The button gets more compact on the bar (46px to 40px tall). */
.site-header__cta {
	transition:
		padding var(--motion-state) var(--ease-soft),
		background-color var(--motion-hover) var(--ease-soft),
		color var(--motion-hover) var(--ease-soft);
}

.site-header.is-stuck .site-header__cta {
	padding-block: 7px;
}

/* Over a hero the button is near-white; on the white bar it takes the accent. */
.site-header.is-stuck .btn--light {
	background: var(--color-accent);
	color: var(--color-subtle);
}

.site-header.is-stuck .btn--light:hover {
	background: var(--color-accent-hover);
}

.site-header--overlay {
	color: var(--color-subtle);
}

.site-header--solid {
	color: var(--color-black);
}

.site-header__inner {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 40px;
	width: 100%;
	max-width: calc(var(--content-max) + 2 * var(--gutter));
	margin-inline: auto;
	padding-inline: var(--gutter);
}

/* The wordmark and the monogram share one spot and crossfade. */
.site-header__logo {
	display: grid;
	flex: none;
	align-items: center;
	color: inherit;
}

.site-logo,
.site-logo-mark {
	grid-area: 1 / 1;
	transition:
		opacity var(--motion-state) var(--ease-soft),
		visibility var(--motion-state);
}

.site-logo {
	width: 128px;
}

.site-logo-mark {
	width: 34px;
	opacity: 0;
	visibility: hidden;
}

.site-header.is-stuck .site-logo {
	opacity: 0;
	visibility: hidden;
}

.site-header.is-stuck .site-logo-mark {
	opacity: 1;
	visibility: visible;
}

.site-header__actions {
	display: flex;
	align-items: center;
	gap: 40px;
}

.site-nav__menu,
.site-nav .sub-menu {
	margin: 0;
	padding: 0;
	list-style: none;
}

.site-nav__menu {
	display: flex;
	align-items: center;
	gap: 20px;
}

.site-nav__menu > .menu-item {
	position: relative;
	display: flex;
	align-items: center;
	gap: 6px;
}

.site-nav__menu > .menu-item > a,
.menu-parent {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	font-size: 18px;
	font-weight: 500;
	line-height: 26px;
	letter-spacing: -0.03em;
	text-decoration: none;
}

.site-nav__menu > .menu-item > a:hover,
.menu-parent:hover {
	opacity: 0.75;
}

.menu-chevron {
	width: 8.43px;
	height: 8px;
	transform: rotate(33deg);
	transition: transform var(--motion-hover) var(--ease-soft);
}

.menu-item.is-open > .submenu-toggle .menu-chevron {
	transform: rotate(-57deg);
}

.site-nav .sub-menu {
	position: absolute;
	top: calc(100% + 16px);
	left: -20px;
	min-width: 280px;
	padding: 14px 0;
	border-radius: var(--radius);
	background: var(--color-white);
	box-shadow: var(--shadow-soft);
	color: var(--color-black);
	opacity: 0;
	visibility: hidden;
	transform: translateY(6px);
	transition: opacity var(--motion-hover) var(--ease-soft), transform var(--motion-hover) var(--ease-soft), visibility var(--motion-hover);
}

/* Keeps hover alive while the pointer crosses the gap to the panel. */
.site-nav .sub-menu::before {
	position: absolute;
	right: 0;
	bottom: 100%;
	left: 0;
	height: 16px;
	content: "";
}

.site-nav .menu-item:hover > .sub-menu,
.site-nav .menu-item:focus-within > .sub-menu,
.site-nav .menu-item.is-open > .sub-menu {
	opacity: 1;
	visibility: visible;
	transform: none;
}

.site-nav .sub-menu a {
	display: block;
	padding: 8px 24px;
	font-size: 17px;
	line-height: 1.4;
	text-decoration: none;
}

.site-nav .sub-menu a:hover {
	color: var(--color-accent);
}

.menu-toggle {
	display: none;
	padding: 12px 0 12px 12px;
}

.menu-toggle__bars {
	display: flex;
	flex-direction: column;
	align-items: flex-end;
	gap: 5px;
	width: 32px;
}

.menu-toggle__bars span {
	display: block;
	width: 100%;
	height: 2px;
	background: currentColor;
	transition: transform var(--motion-hover) var(--ease-soft), opacity var(--motion-hover) var(--ease-soft);
}

.menu-toggle__bars span:last-child {
	width: 22px;
}

.menu-toggle[aria-expanded="true"] .menu-toggle__bars span:nth-child(1) {
	transform: translateY(7px) rotate(45deg);
}

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

.menu-toggle[aria-expanded="true"] .menu-toggle__bars span:nth-child(3) {
	width: 100%;
	transform: translateY(-7px) rotate(-45deg);
}

@media (max-width: 767px) {
	.site-header {
		--header-top: clamp(22px, calc(22px + 13 * var(--fluid-m)), 35px);
	}
}

@media (max-width: 1279px) {
	.site-header__actions {
		display: none;
	}

	.menu-toggle {
		display: block;
	}
}

/* Mobile menu panel */

.mobile-menu {
	position: fixed;
	z-index: 45;
	inset: var(--wp-admin--admin-bar--height, 0px) 0 0;
	overflow-y: auto;
	background: var(--color-black) url("../images/texture-card.jpg") center / cover;
	color: var(--color-subtle);
}

.menu-open .site-header {
	background-color: transparent;
	box-shadow: none;
	color: var(--color-subtle);
}

.mobile-menu__inner {
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	gap: 40px;
	min-height: 100%;
	padding: 120px var(--gutter) 48px;
}

.mobile-menu__list,
.mobile-menu__list .sub-menu {
	margin: 0;
	padding: 0;
	list-style: none;
}

.mobile-menu__list > .menu-item {
	border-bottom: 1px solid rgba(240, 240, 238, 0.15);
}

.mobile-menu__list > .menu-item > a,
.mobile-menu__list .menu-parent {
	display: flex;
	align-items: center;
	justify-content: space-between;
	width: 100%;
	padding: 14px 0;
	font-family: var(--font-serif);
	font-size: 34px;
	font-weight: 300;
	line-height: 1.1;
	text-align: left;
	text-decoration: none;
}

.mobile-menu__list > .menu-item {
	position: relative;
}

.mobile-menu__list .submenu-toggle--icon {
	position: absolute;
	top: 14px;
	right: 0;
	padding: 10px;
}

.mobile-menu__list .menu-chevron {
	width: 12px;
	height: 12px;
}

.mobile-menu__list .sub-menu {
	display: none;
	padding: 0 0 16px;
}

.mobile-menu__list .menu-item.is-open > .sub-menu {
	display: block;
}

.mobile-menu__list .sub-menu a {
	display: block;
	padding: 7px 0;
	font-size: 18px;
	text-decoration: none;
}

.mobile-menu__list {
	width: 100%;
}

/* Hero -------------------------------------------------------------------- */

.hero {
	--hero-inset: clamp(0px, calc(16 * var(--fluid)), 16px);
	position: relative;
	display: flex;
	margin: clamp(0px, calc(14 * var(--fluid)), 14px) var(--hero-inset) 0;
	overflow: hidden;
	border-radius: var(--radius-card);
	background: var(--color-strong);
	box-shadow: var(--shadow-soft);
	color: var(--color-white);
}

.hero__media {
	position: absolute;
	inset: 0;
	display: block;
}

.hero__media::after {
	position: absolute;
	inset: 0;
	background: rgba(0, 0, 0, 0.32);
	content: "";
}

.hero__img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	object-position: 70% 30%;
}

.hero__inner {
	position: relative;
	z-index: 1;
	display: flex;
	flex-direction: column;
	justify-content: space-between;
	gap: clamp(48px, calc(48px + 195 * var(--fluid)), 243px);
	width: 100%;
	max-width: calc(var(--content-max) + 2 * var(--gutter) - 2 * var(--hero-inset));
	margin-inline: auto;
	padding: clamp(150px, calc(150px + 224 * var(--fluid)), 374px) calc(var(--gutter) - var(--hero-inset)) 55px;
}

.hero__content {
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	gap: 40px;
}

.hero__text {
	display: flex;
	flex-direction: column;
	gap: 15px;
	max-width: 1218px;
}

/* The eyebrow is the page's h1, set small; the large tagline under it is a p. */
.hero__eyebrow {
	font-size: clamp(18px, calc(18px + 4 * var(--fluid)), 22px);
	font-weight: inherit;
	line-height: 1.5;
}

.hero__lead {
	font-size: var(--fs-lead);
	line-height: 1.4;
}

/* Over the photo the italic accent stays white. */
.hero__heading em {
	color: inherit;
}

.hero__featured {
	display: flex;
	flex-direction: column;
	gap: 15px;
}

.hero__featured-label {
	font-size: 20px;
	font-weight: 700;
	line-height: 1.75;
}

.logo-marquee {
	display: flex;
	overflow: hidden;
}

.logo-marquee__list {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 20px clamp(32px, calc(32px + 21 * var(--fluid)), 53px);
	margin: 0;
	padding: 0;
	list-style: none;
}

.logo-marquee__list[aria-hidden="true"] {
	display: none;
}

.logo-marquee__item img {
	width: auto;
	height: var(--logo-h);
	max-width: none;
}

@media (max-width: 767px) {
	.hero {
		--hero-inset: 0px;
		min-height: min(171vw, 100svh);
		margin: 0;
		box-shadow: none;
	}

	.hero__inner {
		justify-content: flex-end;
		gap: 60px;
		padding-top: 120px;
		padding-bottom: 35px;
	}

	.hero__text {
		gap: 13px;
	}

	/* The phone board runs the tagline on ("Surgery. Results ..."); typed line
	   breaks are for wider screens. */
	.hero__heading br {
		display: none;
	}

	.hero__eyebrow {
		font-size: clamp(18px, calc(18px + 2 * var(--fluid-m)), 20px);
		line-height: 1.2;
	}

	.hero__lead {
		line-height: 1.5;
	}

	.hero__featured {
		gap: 20px;
	}

	.hero__media::after {
		background: rgba(0, 0, 0, 0.43);
	}

	.hero__img {
		object-position: 50% 20%;
	}

	.hero__featured-label {
		font-size: 18px;
		font-weight: 500;
		line-height: 30px;
	}

	.logo-marquee {
		margin-inline: calc(-1 * var(--gutter));
	}

	.logo-marquee__list,
	.logo-marquee__list[aria-hidden="true"] {
		display: flex;
		flex: none;
		flex-wrap: nowrap;
		gap: 25px;
		padding-right: 25px;
		animation: marquee var(--marquee-duration, 28s) linear infinite;
	}

	.logo-marquee__item img {
		height: calc(var(--logo-h) * 0.8);
	}
}

@keyframes marquee {
	to {
		transform: translateX(-100%);
	}
}

/* Section helpers --------------------------------------------------------- */

.section-title {
	text-align: center;
}

.section-header {
	display: flex;
	flex-direction: column;
	gap: 10px;
	max-width: 780px;
	margin-inline: auto;
	text-align: center;
}

.section-header__intro {
	font-size: var(--fs-body);
	line-height: 1.5;
}

/* Faint "H" watermark behind a centred heading. */
.has-watermark {
	position: relative;
	isolation: isolate;
}

.has-watermark::before {
	position: absolute;
	z-index: -1;
	top: 50%;
	left: 50%;
	width: clamp(160px, calc(160px + 175 * var(--fluid)), 335px);
	aspect-ratio: 335 / 319;
	background: url("../images/watermark.svg") center / contain no-repeat;
	content: "";
	pointer-events: none;
	transform: translate(-50%, -88%);
}

/* More faint "H"s in the Home page's background, placed as on the Homepage
   board (1920px): above the procedure cards, under the approach, above each
   surgeon's bio, above the Instagram band and under the service areas. Offsets
   are shares of the H's width, so they scale with it. Phones skip them (the
   phone board has none), and the surgeons' ones go once the bios stack.

   As on the board, they all sit on one layer under every section: the page is
   their stacking context and the sections they hang from don't make one, so
   an H runs behind the approach card, the bio cards, the Instagram band and
   their text instead of over them. Each fades out towards its exposed end:
   the foot when a section above covers its top, the top (turned 180deg) when
   a card or band below covers its foot. */
.site-main--home {
	--wm-w: clamp(160px, calc(160px + 175 * var(--fluid)), 335px);
	isolation: isolate;
}

.site-main--home > .stack-tight,
.site-main--home > .conversation,
.site-main--home > .surgeons,
.site-main--home .surgeon,
.site-main--home > .locations {
	position: relative;
}

.site-main--home > .stack-tight::before,
.site-main--home > .conversation::before,
.site-main--home > .surgeons::after,
.site-main--home .surgeon::before,
.site-main--home > .locations::after {
	position: absolute;
	z-index: -1;
	left: 50%;
	width: var(--wm-w);
	aspect-ratio: 335 / 319;
	background: url("../images/watermark.svg") center / contain no-repeat;
	content: "";
	pointer-events: none;
	transform: translateX(-50%);
}

/* Above the services: its foot 104px into the first card, which covers it, so
   it fades towards the top (the board has it the other way up). */
.site-main--home > .stack-tight::before {
	top: calc(var(--wm-w) * -215 / 335);
	transform: translateX(-50%) rotate(180deg);
}

/* Below "why choose us" (the approach), just above the conversation heading. */
.site-main--home > .conversation::before {
	bottom: calc(100% - 27px);
}

/* Above each bio card, a little right of its centre (left on even rows); the
   card covers its foot, so it fades towards the top. */
.site-main--home .surgeon::before {
	top: calc(var(--wm-w) * -99 / 335);
	left: 73.2%;
	transform: translateX(-50%) rotate(180deg);
}

.site-main--home .surgeon:nth-of-type(even)::before {
	top: calc(var(--wm-w) * -132 / 335);
	left: 26.6%;
}

/* Above the Instagram band, which covers its foot: it fades towards the top. */
.site-main--home > .surgeons::after {
	top: calc(100% - var(--wm-w) * 49 / 335);
	transform: translateX(-50%) rotate(180deg);
}

/* Below the service areas, a smaller one. The consultation banner covers its
   foot (the banner sits outside the page, so it's lifted above the page's H
   layer), so it fades towards the top. */
.site-main--home > .locations::after {
	top: calc(100% - var(--wm-w) * 14 / 335);
	width: calc(var(--wm-w) * 281 / 335);
	transform: translateX(-50%) rotate(180deg);
}

.site-main--home ~ .site-end {
	position: relative;
	z-index: 1;
}

@media (max-width: 1023px) {
	.site-main--home .surgeon::before {
		display: none;
	}
}

@media (max-width: 767px) {
	.site-main--home > .stack-tight::before,
	.site-main--home > .conversation::before,
	.site-main--home > .surgeons::after,
	.site-main--home > .locations::after {
		display: none;
	}
}

/* Before & after ---------------------------------------------------------- */

.ba-gallery {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: clamp(30px, calc(30px + 25 * var(--fluid)), 55px);
}

.ba-gallery__grid {
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: 21px;
	width: 100%;
}

/* One or two cases keep a third of the row each and sit centred. */
.ba-gallery__grid--few {
	grid-template-columns: repeat(var(--ba-count), calc((100% - 2 * 21px) / 3));
	justify-content: center;
}

/* Each photo's column follows its proportions (set inline from the image), and
   the row is the card's height, so the photos show whole rather than cropped.
   The card's shape is the board's 544 x 361, or 544 x the section's "Card
   height" (--ba-card-ratio, set inline), kept at every width. */
.ba-card {
	display: grid;
	grid-template-columns: 1fr 1fr;
	grid-template-rows: minmax(0, 1fr);
	aspect-ratio: var(--ba-card-ratio, 544 / 361);
	overflow: hidden;
	border-radius: var(--radius);
	background: var(--color-placeholder);
}

.ba-card__img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	object-position: center bottom;
}

/* Each photo is a button that opens the lightbox (main.js). */
.ba-card__zoom {
	display: block;
	min-width: 0;
	height: 100%;
	min-height: 0;
	padding: 0;
	border: 0;
	background: none;
	cursor: zoom-in;
}

.ba-card__zoom:focus-visible {
	outline: 2px solid var(--color-black);
	outline-offset: -4px;
}

/* One combined before & after photo fills the card, centred. */
.ba-card--single {
	grid-template-columns: minmax(0, 1fr);
}

.ba-card--single .ba-card__img {
	object-position: center;
}

@media (max-width: 767px) {
	.ba-gallery {
		align-items: flex-start;
		gap: 30px;
	}

	.ba-gallery .section-title {
		text-align: left;
	}

	.ba-gallery .has-watermark::before {
		display: none;
	}

	.ba-gallery__grid {
		grid-template-columns: 1fr;
		gap: 21px;
	}
}

/* Experience -------------------------------------------------------------- */

.experience {
	display: grid;
	grid-template-columns: minmax(0, 623fr) minmax(0, 244fr) minmax(0, 801fr);
	align-items: center;
}

.experience__media {
	grid-column: 1;
	aspect-ratio: 623 / 929;
	overflow: hidden;
	border-radius: var(--radius);
}

.experience__content {
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	grid-column: 3;
}

.experience__content .rich-text {
	margin-top: 10px;
}

.experience__button {
	margin-top: 40px;
}

@media (max-width: 1439px) {
	.experience {
		grid-template-columns: minmax(0, 623fr) minmax(0, 120fr) minmax(0, 801fr);
	}
}

@media (max-width: 1023px) {
	.experience {
		grid-template-columns: 1fr;
		gap: 50px;
	}

	.experience__media,
	.experience__content {
		grid-column: 1;
	}

	.experience__media {
		order: 2;
		aspect-ratio: 480 / 630;
		max-height: 80vh;
	}
}

@media (max-width: 767px) {
	.experience__content .rich-text {
		margin-top: 25px;
	}

	.experience__button {
		margin-top: 25px;
	}
}

/* Divider ----------------------------------------------------------------- */

.divider {
	display: flex;
	align-items: center;
	gap: clamp(28px, calc(28px + 100 * var(--fluid)), 128px);
	width: 100%;
	max-width: calc(var(--content-max) + 2 * var(--gutter));
	margin-inline: auto;
	padding-inline: var(--gutter);
	color: var(--color-accent);
}

.divider__line {
	flex: 1;
	height: 1px;
	background: var(--color-divider);
}

.divider__mark {
	flex: none;
	width: clamp(32px, calc(32px + 31 * var(--fluid)), 63px);
}

@media (max-width: 767px) {
	.divider {
		gap: 30px;
	}

	.divider + .testimonial {
		margin-top: calc(70px - var(--section-gap));
	}

	.divider__mark {
		width: 32px;
	}
}

/* Testimonial ------------------------------------------------------------- */

.testimonial {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 30px;
	text-align: center;
}

.testimonial__figure {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 25px;
	max-width: 1334px;
}

.testimonial__quote {
	color: var(--color-ink);
	letter-spacing: 0;
}

.testimonial__cite {
	color: var(--color-accent);
	font-family: var(--font-serif);
	font-size: var(--fs-h5);
	font-style: italic;
	font-weight: 300;
	line-height: 1;
}

.testimonial__actions {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 20px;
}

.rating-line {
	display: inline-flex;
	align-items: center;
	gap: 15px;
	color: var(--color-ink);
	font-size: 18px;
	line-height: 20px;
	text-decoration: none;
}

a.rating-line:hover span {
	text-decoration: underline;
}

.rating-line__stars {
	width: 83px;
}

/* Procedure cards --------------------------------------------------------- */

.procedures {
	display: flex;
	flex-direction: column;
	gap: clamp(10px, calc(10px + 20 * var(--fluid)), 30px);
	margin-inline: var(--inset);
}

.procedure-card {
	position: relative;
	display: grid;
	grid-template-areas: "text . links";
	grid-template-columns: minmax(0, 622px) 1fr minmax(max-content, 336px);
	align-items: center;
	column-gap: 40px;
	min-height: clamp(520px, 42.7vw, 820px);
	padding: 80px clamp(40px, calc(40px + 64 * var(--fluid)), 104px);
	overflow: hidden;
	border-radius: var(--radius-card);
	background: var(--color-black);
	box-shadow: var(--shadow-soft);
	color: var(--color-white);
}

.procedure-card:nth-child(even) {
	grid-template-areas: "links . text";
	grid-template-columns: minmax(max-content, 336px) 1fr minmax(0, 629px);
}

.procedure-card__media {
	position: absolute;
	inset: 0;
}

/* The photos are cropped to the card's proportions as on the board (2560px,
   from the Figma originals), so on wide screens they show whole. */
.procedure-card__media img {
	width: 100%;
	height: 100%;
	object-fit: cover;
}

.procedure-card__text {
	position: relative;
	display: flex;
	flex-direction: column;
	gap: 15px;
	grid-area: text;
}

.procedure-card:nth-child(even) .procedure-card__text {
	max-width: 583px;
}

.procedure-card__links {
	position: relative;
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	gap: 20px;
	grid-area: links;
	margin: 0;
	padding: 0;
	list-style: none;
}

/* Narrower cards: the sculpture moves under the copy, so shade that side. */
@media (min-width: 1024px) and (max-width: 1599px) {
	.procedure-card {
		grid-template-columns: minmax(0, 480px) 1fr minmax(max-content, 280px);
	}

	.procedure-card:nth-child(even) {
		grid-template-columns: minmax(max-content, 280px) 1fr minmax(0, 480px);
	}

	.procedure-card__media::after {
		position: absolute;
		inset: 0;
		background: linear-gradient(90deg, rgba(0, 0, 0, 0.8) 0%, rgba(0, 0, 0, 0.5) 35%, transparent 55%);
		content: "";
	}

	.procedure-card:nth-child(even) .procedure-card__media::after {
		background: linear-gradient(270deg, rgba(0, 0, 0, 0.8) 0%, rgba(0, 0, 0, 0.5) 35%, transparent 55%);
	}
}

@media (max-width: 1023px) {
	.procedure-card,
	.procedure-card:nth-child(even) {
		display: flex;
		flex-direction: column;
		align-items: flex-start;
		gap: 40px;
		min-height: 0;
		padding: 64px var(--gutter) 82vw;
	}

	/* The sculpture sits below the copy, enlarged and shifted. Each photo is
	   framed differently, so each card sets the photo's width and left offset
	   (as a share of the card's width) and how far it drops (a share of its
	   own height), placing the sculptures as in the mobile artboard. */
	.procedure-card__media {
		inset: auto 0 0;
		transform: translateY(var(--photo-drop, 0%));
	}

	.procedure-card:nth-child(1) {
		--photo-width: 264.8%;
		--photo-left: -70.2%;
		--photo-drop: 1.5%;
	}

	.procedure-card:nth-child(2) {
		--photo-width: 240.2%;
		--photo-left: -56%;
		--photo-drop: 5.7%;
	}

	.procedure-card:nth-child(3) {
		--photo-width: 256.4%;
		--photo-left: -68.6%;
		--photo-drop: 7.4%;
	}

	.procedure-card__media::before {
		position: absolute;
		inset: 0 0 auto;
		height: 45%;
		background: linear-gradient(var(--color-black), transparent);
		content: "";
	}

	/* A card with its own mobile image: the image fills the card, anchored to
	   its foot, with the copy over its top (still shaded by ::before). */
	.procedure-card.has-mobile-image .procedure-card__media {
		inset: 0;
		transform: none;
	}

	.procedure-card.has-mobile-image .procedure-card__media img {
		width: 100%;
		height: 100%;
		margin-left: 0;
		object-fit: cover;
		object-position: center bottom;
	}

	.procedure-card:not(.has-mobile-image) .procedure-card__media img {
		width: var(--photo-width, 250%);
		max-width: none;
		height: auto;
		margin-left: var(--photo-left, -65%);
	}

	.procedure-card__links {
		gap: 14px;
	}
}

/* Phones: full-bleed cards stacked edge to edge, sculpture behind the links. */
@media (max-width: 767px) {
	.stack-tight,
	.procedures {
		gap: 0;
	}

	.procedure-card,
	.procedure-card:nth-child(even) {
		gap: 70px;
		min-height: 169vw;
		padding: 100px var(--gutter);
	}

	.procedure-card__text {
		gap: 10px;
	}

	/* Each sculpture's place in the mobile artboard (see the tablet rules above). */
	.procedure-card:nth-child(1) {
		--photo-width: 288.9%;
		--photo-left: -79.2%;
		--photo-drop: 24%;
	}

	.procedure-card:nth-child(2) {
		--photo-width: 207.4%;
		--photo-left: -6.9%;
		--photo-drop: 5.7%;
	}

	.procedure-card:nth-child(3) {
		--photo-width: 256.4%;
		--photo-left: -75.6%;
		--photo-drop: 16.6%;
	}

	.procedure-card__links {
		gap: 20px;
	}

	.procedure-card__links > li {
		display: flex;
	}

	.procedure-card__links .arrow-link {
		font-size: var(--fs-button);
		font-weight: 500;
		line-height: 26px;
		letter-spacing: -0.03em;
	}
}

/* Approach ---------------------------------------------------------------- */

.approach {
	position: relative;
	display: flex;
	flex-direction: column;
	gap: clamp(56px, calc(56px + 45 * var(--fluid)), 101px);
	margin-inline: var(--inset);
	padding: clamp(64px, calc(64px + 71 * var(--fluid)), 135px) calc(var(--gutter) - var(--inset)) clamp(64px, calc(64px + 73 * var(--fluid)), 137px);
	overflow: hidden;
	border: 1px solid var(--color-subtle);
	border-radius: var(--radius-card);
	background: var(--color-subtle) var(--approach-bg, url("../images/texture-approach.jpg")) center / cover;
}

.approach__mark {
	position: absolute;
	top: -24px;
	max-width: none;
	mix-blend-mode: screen;
	pointer-events: none;
}

.approach__mark--small {
	left: calc(50% - 936px);
	width: 335px;
}

.approach__mark--large {
	left: calc(50% - 268px);
	width: 1367px;
	transform: scaleX(-1);
}

.approach__intro,
.approach__features {
	position: relative;
	z-index: 1;
	width: 100%;
	max-width: var(--content-max);
	margin-inline: auto;
}

.approach__intro {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 40px;
}

.approach__text {
	display: flex;
	flex: 0 1 728px;
	flex-direction: column;
	gap: 20px;
}

.approach__media {
	flex: 0 1 799px;
	aspect-ratio: 799 / 521;
	overflow: hidden;
	border-radius: var(--radius);
}

.approach__features {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 44px;
}

.approach__features-title {
	text-align: center;
}

.feature-grid {
	display: grid;
	grid-template-columns: repeat(5, minmax(0, 1fr));
	gap: 20px;
	width: 100%;
	margin: 0;
	padding: 0;
	list-style: none;
}

.feature-card {
	display: flex;
	flex-direction: column;
	gap: 17px;
	padding: clamp(28px, calc(28px + 12 * var(--fluid)), 40px);
	border-radius: var(--radius);
	background: var(--color-white);
	font-size: var(--fs-body);
	line-height: 1.5;
}

.feature-card__icon {
	width: 54px;
	height: 54px;
}

@media (max-width: 1439px) {
	.feature-grid {
		grid-template-columns: repeat(3, minmax(0, 1fr));
	}
}

@media (max-width: 1023px) {
	.approach__intro {
		flex-direction: column;
		align-items: stretch;
	}

	.approach__text,
	.approach__media {
		flex-basis: auto;
	}

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

@media (max-width: 767px) {
	.approach {
		gap: 40px;
		padding: 80px var(--gutter);
		border: 0;
	}

	.approach__mark {
		display: none;
	}

	.approach__text {
		gap: 10px;
	}

	.approach__features {
		align-items: flex-start;
		gap: 40px;
	}

	.feature-card {
		padding: clamp(28px, calc(28px + 12 * var(--fluid-m)), 40px);
	}

	.approach__features-title {
		text-align: left;
	}

	.feature-grid {
		grid-template-columns: 1fr;
	}
}

/* Conversation ------------------------------------------------------------ */

.conversation {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 50px;
	padding-top: 40px;
	text-align: center;
}

.conversation .heading-display {
	max-width: 1107px;
}

@media (max-width: 767px) {
	.conversation {
		align-items: flex-start;
		gap: 30px;
		padding-top: 0;
		text-align: left;
	}

	/* The phone board sets this statement at the H2 size. */
	.conversation .heading-display {
		font-size: var(--fs-h2);
		line-height: 1.09;
		letter-spacing: -2px;
	}
}

/* Surgeons ---------------------------------------------------------------- */

.surgeons {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 72px;
}

.surgeons .section-header {
	max-width: 739px;
}

.surgeon {
	display: grid;
	grid-template-columns: minmax(0, 618fr) minmax(0, 106fr) minmax(0, 687fr);
	align-items: start;
	width: 100%;
	max-width: 1411px;
}

.surgeon__media {
	grid-row: 1;
	grid-column: 1 / 3;
	aspect-ratio: 724 / 627;
	overflow: hidden;
	border-radius: var(--radius);
}

.surgeon__card {
	position: relative;
	z-index: 1;
	display: flex;
	flex-direction: column;
	gap: 15px;
	grid-row: 1;
	grid-column: 2 / 4;
	margin-top: 128px;
	padding: clamp(36px, calc(36px + 29 * var(--fluid)), 65px) clamp(24px, calc(24px + 46 * var(--fluid)), 70px);
	border-radius: var(--radius);
	background: var(--color-black) url("../images/texture-card.jpg") center / cover;
	color: var(--color-subtle);
	filter: drop-shadow(0 10px 25px rgba(0, 0, 0, 0.04));
}

.surgeon:nth-of-type(even) {
	grid-template-columns: minmax(0, 687fr) minmax(0, 106fr) minmax(0, 618fr);
}

.surgeon:nth-of-type(even) .surgeon__media {
	grid-column: 2 / 4;
	aspect-ratio: 724 / 564;
}

.surgeon:nth-of-type(even) .surgeon__card {
	grid-column: 1 / 3;
	margin-top: 122px;
}

.surgeon__card .btn {
	align-self: flex-start;
	margin-top: 15px;
}

@media (max-width: 1023px) {
	.surgeons {
		align-items: stretch;
		gap: 50px;
	}

	.surgeon,
	.surgeon:nth-of-type(even) {
		display: flex;
		flex-direction: column;
		gap: 20px;
	}

	.surgeon__card,
	.surgeon:nth-of-type(even) .surgeon__card {
		margin-top: 0;
	}

	.surgeon__media,
	.surgeon:nth-of-type(even) .surgeon__media {
		aspect-ratio: 480 / 416;
	}
}

@media (max-width: 767px) {
	.surgeons .section-header {
		gap: 20px;
		text-align: left;
	}

	.surgeon__card {
		padding: clamp(36px, calc(36px + 19 * var(--fluid-m)), 55px) clamp(24px, calc(24px + 16 * var(--fluid-m)), 40px);
	}

	.surgeon:nth-of-type(even) .surgeon__media {
		aspect-ratio: 480 / 374;
	}
}

/* Instagram --------------------------------------------------------------- */

.instagram {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: clamp(36px, calc(36px + 19 * var(--fluid)), 55px);
	margin-inline: var(--inset);
	padding: clamp(80px, calc(80px + 70 * var(--fluid)), 150px) 0;
	overflow: hidden;
	border-radius: var(--radius-card);
	background: var(--color-black);
	color: var(--color-white);
}

.section-header--light {
	max-width: calc(817px + 2 * var(--gutter));
	padding-inline: var(--gutter);
}

.section-header--light .heading-2 em {
	color: inherit;
}

.section-header--light .section-header__intro {
	color: var(--color-subtle);
}

.instagram__strip {
	position: relative;
	width: 100%;
	overflow: hidden;
}

.instagram__track {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 33px;
	margin: 0;
	padding: 0;
	list-style: none;
}

.instagram__tile {
	flex: none;
	width: 246px;
	aspect-ratio: 246 / 269;
	overflow: hidden;
	border-radius: var(--radius);
}

.instagram__tile.is-featured {
	width: 355px;
	aspect-ratio: 355 / 389;
}

.instagram__tile a {
	display: block;
	height: 100%;
}

.instagram__tile img {
	transition: transform var(--motion-hover) var(--ease-soft);
}

.instagram__tile a:hover img {
	transform: scale(1.03);
}

@media (max-width: 767px) {
	.instagram__strip {
		overflow-x: auto;
		scroll-snap-type: x mandatory;
		scrollbar-width: none;
	}

	.instagram__strip::-webkit-scrollbar {
		display: none;
	}

	.instagram__track {
		justify-content: flex-start;
		gap: 18px;
		padding-inline: var(--gutter);
	}

	.instagram__tile,
	.instagram__tile.is-featured {
		width: 42vw;
		aspect-ratio: 231 / 270;
		scroll-snap-align: center;
	}

	.instagram .section-header {
		text-align: left;
	}

	.instagram {
		align-items: flex-start;
		gap: 35px;
		padding-block: 80px;
	}

	.instagram > .btn {
		margin-inline: var(--gutter);
	}
}

/* Stepping strip. main.js adds .is-stepping (and copies of the row, so the
   loop never runs out) when there are more than four posts and reduced motion
   isn't preferred: every 2.8s the posts glide one along (--step-move), all the
   same size, and the one that stops in the middle grows to 1.3x
   (.is-current). The spacing leaves room for it. It doesn't stop under the
   pointer. Otherwise the strip stays still with the middle post larger, as on
   the board. */
.instagram__strip.is-stepping {
	--tile-w: 246px;
	--tile-h: 269px;
	--tile-gap: calc(var(--tile-w) * 0.15 + 6px);
	--step-move: 800ms;
	display: flex;
	overflow: hidden;
	padding-block: calc(var(--tile-h) * 0.15);
	scroll-snap-type: none;
}

.instagram__strip.is-stepping .instagram__track {
	flex: none;
	justify-content: flex-start;
	gap: var(--tile-gap);
	padding: 0 var(--tile-gap) 0 0;
	transform: translateX(var(--step-x, 0px));
	transition: transform var(--step-move) var(--ease-soft);
}

.instagram__strip.is-stepping .instagram__tile {
	width: var(--tile-w);
	height: var(--tile-h);
	aspect-ratio: auto;
	transition: scale var(--step-move) var(--ease-soft);
}

.instagram__strip.is-stepping .instagram__tile.is-current {
	scale: 1.3;
}

/* Looping back a row (to an identical place) and resizing happen at once. */
.instagram__strip.is-jumping :is(.instagram__track, .instagram__tile) {
	transition: none;
}

@media (max-width: 767px) {
	.instagram__strip.is-stepping {
		--tile-w: 42vw;
		--tile-h: calc(42vw * 270 / 231);
	}
}

/* Locations --------------------------------------------------------------- */

.locations {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 31px;
}

.locations .section-header {
	gap: 20px;
	max-width: 778px;
}

.locations__list {
	display: flex;
	flex-wrap: wrap;
	justify-content: center;
	gap: 25px 35px;
	max-width: 1100px;
	margin: 0;
	padding: 0;
	list-style: none;
}

.locations__item {
	display: inline-flex;
	align-items: center;
	gap: 15px;
	font-size: clamp(17px, calc(17px + 3 * var(--fluid)), 20px);
	font-weight: 500;
	line-height: 1.5;
}

.locations__link {
	color: inherit;
	text-decoration: underline;
	text-underline-offset: 4px;
}

.locations__item .icon {
	width: 14.4px;
	height: 17px;
}

@media (max-width: 767px) {
	.locations {
		align-items: flex-start;
	}

	.locations .section-header {
		gap: 30px;
		text-align: left;
	}

	.locations {
		gap: 30px;
	}

	.locations__list {
		justify-content: flex-start;
		gap: 25px 35px;
	}

	.locations__item {
		font-size: clamp(17px, calc(17px + 3 * var(--fluid-m)), 20px);
		line-height: 30px;
	}
}

/* Consultation banner + footer -------------------------------------------- */

.site-end {
	padding: clamp(72px, calc(72px + 74 * var(--fluid)), 146px) 0 clamp(0px, calc(32 * var(--fluid)), 32px);
	background: var(--color-subtle) url("../images/texture-cta.jpg") center top / cover;
}

/* Without the consultation banner the footer follows the page directly. */
.site-end.site-end--plain {
	padding: 0 0 var(--inset);
	background: none;
}

.site-end--plain .site-footer {
	margin-top: var(--inset);
}

.cta-banner {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 29px;
	max-width: calc(937px + 2 * var(--gutter));
	margin-inline: auto;
	padding-inline: var(--gutter);
	text-align: center;
}

.cta-banner__text {
	display: flex;
	flex-direction: column;
	gap: 20px;
}

.cta-banner__body {
	max-width: 891px;
	margin-inline: auto;
}

/* Service pages that end on related procedures: the banner is a textured band
   in the page; right after the FAQ band it joins it, square where they meet. */
.cta-band {
	margin-inline: var(--inset);
	padding-block: clamp(72px, calc(72px + 74 * var(--fluid)), 146px);
	border-radius: var(--radius-card);
	background: var(--color-subtle) url("../images/texture-cta.jpg") center / cover;
}

.service-faq:has(+ .cta-band) {
	border-bottom-right-radius: 0;
	border-bottom-left-radius: 0;
}

.service-faq + .cta-band {
	margin-top: calc(-1 * var(--service-gap));
	border-top-left-radius: 0;
	border-top-right-radius: 0;
}

@media (max-width: 767px) {
	.site-end {
		padding-top: clamp(72px, calc(72px + 18 * var(--fluid-m)), 90px);
		padding-bottom: 0;
	}

	.cta-banner,
	.cta-banner__text {
		gap: 25px;
	}

	.cta-banner {
		align-items: flex-start;
		text-align: left;
	}
}

.site-footer {
	display: grid;
	grid-template-areas:
		"c1 c2 c3 c4"
		"badge badge badge badge"
		"mark mark mark mark"
		"bottom bottom bottom bottom";
	grid-template-columns: repeat(4, max-content);
	justify-content: space-between;
	column-gap: 40px;
	margin: clamp(72px, calc(72px + 67 * var(--fluid)), 139px) var(--inset) 0;
	padding: clamp(56px, calc(56px + 41 * var(--fluid)), 97px) calc(var(--gutter) - var(--inset) - 1px) clamp(48px, calc(48px + 34 * var(--fluid)), 82px);
	border-radius: var(--radius-card);
	background: var(--color-black);
	color: var(--color-footer);
}

.site-footer__col:nth-child(1) { grid-area: c1; }
.site-footer__col:nth-child(2) { grid-area: c2; }
.site-footer__col:nth-child(3) { grid-area: c3; }
.site-footer__col:nth-child(4) { grid-area: c4; }

.site-footer__heading {
	margin-bottom: 30px;
	font-size: clamp(21px, calc(21px + 4 * var(--fluid)), 25px);
	font-weight: 500;
	line-height: 1;
}

.site-footer__links,
.site-footer__legal-links {
	margin: 0;
	padding: 0;
	list-style: none;
}

.site-footer__links {
	display: flex;
	flex-direction: column;
	gap: 10px;
}

.site-footer__links a,
.site-footer__address,
.site-footer__phone {
	font-size: 17px;
	letter-spacing: 0.01em;
}

.site-footer__links a {
	display: inline-block;
	line-height: 18px;
	text-decoration: none;
}

.site-footer a:hover {
	text-decoration: underline;
	text-underline-offset: 0.2em;
}

.site-footer__address {
	font-style: normal;
	line-height: 23px;
}

.site-footer__address a,
.contact__address a {
	text-decoration: none;
}

.site-footer__phone {
	display: inline-flex;
	align-items: center;
	gap: 15px;
	line-height: 1;
	text-decoration: none;
}

.site-footer__phone .icon {
	width: 18.75px;
	margin: 0.6px;
}

.social-links {
	display: flex;
	gap: 10px;
	margin: 20px 0 0;
	padding: 0;
	list-style: none;
}

.social-links__link {
	display: grid;
	width: 40px;
	height: 40px;
	place-items: center;
	border-radius: 50%;
	background: rgba(255, 255, 255, 0.18);
	color: var(--color-white);
	-webkit-backdrop-filter: blur(15px);
	backdrop-filter: blur(15px);
	transition: background-color var(--motion-hover) var(--ease-soft);
}

.social-links__link:hover {
	background: rgba(255, 255, 255, 0.3);
}

.social-links .icon--facebook { width: 8.6px; }
.social-links .icon--youtube { width: 17px; }
.social-links .icon--instagram { width: 19.2px; }

.rating-badge {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 10px;
	grid-area: badge;
	justify-self: end;
	width: 222px;
	margin-top: 12px;
	color: var(--color-footer);
	text-decoration: none;
}

.site-footer a.rating-badge:hover {
	text-decoration: none;
}

.rating-badge__score {
	display: flex;
	align-items: center;
	gap: 10px;
}

.rating-badge__laurel {
	width: 33px;
	height: 72px;
}

.rating-badge__label {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 10px;
	width: 136px;
	font-size: 20px;
	line-height: 1;
}

.rating-badge__stars {
	width: 83px;
}

.rating-badge__count {
	font-size: 12px;
	font-weight: 700;
	line-height: 1;
}

.rating-badge__avatars {
	width: 120px;
}

.site-footer__wordmark {
	grid-area: mark;
	margin-top: -11px;
	/* Keep the large image from sizing the max-content columns. */
	contain: inline-size;
}

.site-footer__wordmark img {
	width: 100%;
}

.site-footer__bottom {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: 16px;
	grid-area: bottom;
	margin-top: 36px;
	padding-top: 30px;
	border-top: 0.5px solid var(--color-footer);
	font-size: 15.4px;
	font-weight: 500;
	line-height: 1;
}

.site-footer__legal-links {
	display: flex;
	gap: 15px;
}

.site-footer__legal-links a {
	text-decoration: none;
}

@media (max-width: 1023px) {
	.site-footer {
		grid-template-areas:
			"c1 c2"
			"c3 c4"
			"bottom bottom"
			"mark mark"
			"badge badge";
		grid-template-columns: repeat(2, minmax(0, 1fr));
		row-gap: 56px;
		padding-inline: var(--gutter);
	}

	.site-footer__links a {
		line-height: 1.35;
	}

	.site-footer__bottom {
		flex-direction: column;
		align-items: flex-start;
		margin-top: 0;
	}

	.site-footer__wordmark {
		margin: 0 calc(-1 * var(--gutter) + 4px);
	}

	.rating-badge {
		justify-self: center;
		margin-top: -24px;
	}
}

@media (max-width: 767px) {
	.site-footer {
		--footer-gap: clamp(56px, calc(56px + 44 * var(--fluid-m)), 100px);
		row-gap: 0;
		margin-top: clamp(72px, calc(72px + 18 * var(--fluid-m)), 90px);
		/* The bottom padding also clears the pinned Book / Call bar. */
		padding-top: clamp(56px, calc(56px + 19 * var(--fluid-m)), 75px);
		padding-bottom: clamp(124px, calc(124px + 124 * var(--fluid-m)), 248px);
	}

	.site-footer__col:nth-child(n + 3) {
		margin-top: var(--footer-gap);
	}

	.site-footer__heading {
		font-size: clamp(21px, calc(21px + 4 * var(--fluid-m)), 25px);
		line-height: 17px;
	}

	.site-footer__links {
		gap: 3px;
	}

	.site-footer__links > li {
		display: flex;
	}

	.site-footer__links a {
		line-height: 25px;
	}

	.site-footer__phone {
		display: flex;
		width: fit-content;
	}

	.site-footer__bottom {
		gap: 26px;
		margin-top: calc(var(--footer-gap) + 16px);
	}

	.site-footer__wordmark {
		margin: calc(var(--footer-gap) - 17px) calc(-1 * var(--gutter)) 0;
	}

	.rating-badge {
		margin-top: 36px;
	}
}

/* Pinned calls to action ---------------------------------------------------- */

.floating-cta {
	position: fixed;
	z-index: 40;
	right: 39px;
	bottom: 33px;
	box-shadow: var(--shadow-soft);
	transition: background-color var(--motion-hover) var(--ease-soft), opacity var(--motion-hover) var(--ease-soft), transform var(--motion-hover) var(--ease-soft), visibility var(--motion-hover);
}

.floating-cta.is-hidden {
	opacity: 0;
	visibility: hidden;
	transform: translateY(16px);
}

.mobile-cta-bar {
	display: none;
}

.menu-open .floating-cta,
.menu-open .mobile-cta-bar {
	visibility: hidden;
}

/* Beside a sticky side column (blog posts, text pages) the floating button
   would sit on the column's foot; the header's button is there instead, and
   the column only has to scroll when it's taller than the screen. */
@media (min-width: 1280px) {
	body:has(.post-aside__inner) .floating-cta {
		display: none;
	}
}

@media (max-width: 767px) {
	.floating-cta {
		display: none;
	}

	.mobile-cta-bar {
		position: fixed;
		z-index: 40;
		right: 10px;
		bottom: 10px;
		left: 10px;
		display: grid;
		grid-template-columns: 1fr 1fr;
		gap: 7px;
	}

	.mobile-cta-bar__btn {
		display: flex;
		align-items: center;
		justify-content: center;
		min-height: clamp(56px, calc(56px + 24 * var(--fluid-m)), 80px);
		border-radius: 6px;
		color: var(--color-white);
		font-size: clamp(18px, calc(18px + 5 * var(--fluid-m)), 23px);
		font-weight: 500;
		line-height: 20px;
		letter-spacing: -0.04em;
		text-decoration: none;
	}

	.mobile-cta-bar__btn--book { background: #7e7a7a; }
	.mobile-cta-bar__btn--call { background: #936f6d; }
}

/* Contact and 404 backgrounds ---------------------------------------------- */

.site-main--contact,
.site-main--error {
	position: relative;
	isolation: isolate;
	overflow: hidden;
}

/* Large faint "H" behind the page. */
.site-main--contact::before,
.site-main--error::before,
.site-main--error::after {
	position: absolute;
	z-index: -1;
	aspect-ratio: 838 / 797;
	background: url("../images/watermark-peak.svg") center / contain no-repeat;
	content: "";
	pointer-events: none;
}

@media (max-width: 767px) {
	.site-main--contact::before,
	.site-main--error::before,
	.site-main--error::after {
		display: none;
	}
}

/* Contact ------------------------------------------------------------------ */

.site-main--contact {
	padding: clamp(150px, calc(150px + 134 * var(--fluid)), 284px) 0 var(--section-gap);
}

.site-main--contact::before {
	bottom: 0;
	left: 50%;
	width: 31.7vw;
	transform: translateX(-50%);
}

.contact {
	display: grid;
	grid-template-areas:
		"heading form"
		"details form";
	grid-template-columns: minmax(0, 1fr) minmax(0, 578px);
	grid-template-rows: auto 1fr;
	align-items: start;
	column-gap: 40px;
}

.contact__heading {
	grid-area: heading;
}

.contact__form {
	grid-area: form;
}

.contact__details {
	display: flex;
	flex-direction: column;
	gap: 80px;
	grid-area: details;
	margin-top: clamp(40px, calc(40px + 31 * var(--fluid)), 71px);
}

.contact__block {
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	gap: 30px;
}

.contact__label {
	font-size: clamp(22px, calc(22px + 5 * var(--fluid)), 27px);
	font-weight: 500;
	line-height: 35px;
}

.contact__address,
.contact__phone {
	font-size: clamp(18px, calc(18px + 2 * var(--fluid)), 20px);
	font-style: normal;
	line-height: 33px;
}

/* Trim the half-leading so the block is as tall as its three lines. */
.contact__address {
	margin-block: -8.5px;
}

.contact__phone {
	line-height: 1;
	text-decoration: none;
}

.contact__phone:hover,
.contact__address a:hover {
	text-decoration: underline;
	text-underline-offset: 0.2em;
}

.contact__social {
	display: flex;
	align-items: center;
	gap: 20px;
	margin: 0;
	padding: 0;
	list-style: none;
}

.contact__social a {
	display: block;
	transition: color var(--motion-hover) var(--ease-soft);
}

.contact__social a:hover {
	color: var(--color-accent);
}

.contact__social .icon--facebook { width: 8.6px; }
.contact__social .icon--youtube { width: 23px; }
.contact__social .icon--instagram { width: 19.2px; }

/* Contact Form 7 form, laid out by the markup in seed/data/forms.php. */

.contact__form .wpcf7-form {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
}

.contact-form__fields,
.contact-form__consent,
.contact__form .wpcf7-response-output {
	flex: 0 0 100%;
}

.contact-form__fields {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 15px 28px;
}

.contact-form__field--wide {
	grid-column: 1 / -1;
}

.contact-form__field input,
.contact-form__field textarea {
	display: block;
	width: 100%;
	padding: 26px 0;
	border: 0;
	border-bottom: 0.5px solid var(--color-border-muted);
	border-radius: 0;
	background: transparent;
	color: var(--color-black);
	font: 500 clamp(18px, calc(18px + 2 * var(--fluid)), 20px) / 26px var(--font-sans);
	transition: border-color var(--motion-hover) var(--ease-soft), box-shadow var(--motion-hover) var(--ease-soft);
}

.contact-form__field textarea {
	height: 183px;
	padding-top: 25px;
	resize: vertical;
}

.contact-form__field ::placeholder {
	color: var(--color-black);
	opacity: 1;
	transition: opacity var(--motion-hover) var(--ease-soft);
}

.contact-form__field :focus::placeholder {
	opacity: 0.4;
}

.contact-form__field input:focus,
.contact-form__field textarea:focus {
	border-bottom-color: var(--color-black);
	outline: none;
	box-shadow: 0 1px 0 var(--color-black);
}

.contact-form__field [aria-invalid="true"] {
	border-bottom-color: #b42318;
}

.contact__form .wpcf7-not-valid-tip {
	margin-top: 8px;
	color: #b42318;
	font-size: 15px;
	line-height: 1.3;
}

.contact-form__consent {
	margin-top: 30px;
	font-size: clamp(18px, calc(18px + 2 * var(--fluid)), 20px);
	font-weight: 500;
	line-height: 30px;
}

.contact-form__consent .wpcf7-list-item {
	margin: 0;
}

.contact-form__consent label {
	display: flex;
	align-items: flex-start;
	gap: 12px;
	cursor: pointer;
}

.contact-form__consent input {
	flex: none;
	width: 25px;
	height: 25px;
	margin: 2.5px 0 0;
	border: 1px solid var(--color-border-muted);
	border-radius: 0;
	background: var(--color-white);
	appearance: none;
	cursor: pointer;
}

.contact-form__consent input:checked {
	border-color: var(--color-black);
	background: var(--color-black) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 14 11'%3E%3Cpath d='M1 5.5l4 4 8-8' fill='none' stroke='%23f0f0ee' stroke-width='2'/%3E%3C/svg%3E") center / 14px no-repeat;
}

.contact-form__consent a {
	color: var(--color-accent);
	text-decoration: none;
}

.contact-form__consent a:hover {
	text-decoration: underline;
	text-underline-offset: 0.18em;
}

.contact-form__submit {
	margin-top: 45px;
}

/* The button is plain markup in the form, so its arrow comes from CSS. */
.contact-form__submit::after {
	flex: none;
	width: 9.833px;
	height: 9.333px;
	background: currentColor;
	content: "";
	-webkit-mask: url("../images/icons/arrow.svg") center / contain no-repeat;
	mask: url("../images/icons/arrow.svg") center / contain no-repeat;
	transform: rotate(-42.6deg);
	transition: transform var(--motion-hover) var(--ease-soft);
}

.contact-form__submit:hover::after {
	transform: rotate(-42.6deg) translateX(3px);
}

.contact__form .wpcf7-spinner {
	margin: 45px 0 0 16px;
}

.contact__form .wpcf7-form .wpcf7-response-output {
	margin: 24px 0 0;
	padding: 14px 18px;
	border-width: 1px;
	border-radius: 6px;
	font-size: 17px;
	line-height: 1.4;
}

@media (max-width: 1023px) {
	.contact {
		grid-template-areas:
			"heading"
			"form"
			"details";
		grid-template-columns: minmax(0, 1fr);
	}

	.contact__form {
		margin-top: 27px;
	}

	.contact__details {
		flex-direction: row;
		flex-wrap: wrap;
		gap: 40px 72px;
		margin-top: 84px;
	}
}

@media (max-width: 767px) {
	.site-main--contact {
		padding-top: clamp(130px, calc(130px + 47 * var(--fluid-m)), 177px);
	}

	.contact-form__fields {
		grid-template-columns: minmax(0, 1fr);
		gap: 0;
	}

	.contact-form__field input,
	.contact-form__field textarea {
		padding-block: 30px;
	}

	.contact-form__field textarea {
		height: 174px;
	}

	.contact__label {
		font-size: clamp(22px, calc(22px + 5 * var(--fluid-m)), 27px);
		line-height: 30px;
	}

	.contact__address {
		font-size: var(--fs-body);
		line-height: 50px;
	}

	.contact__phone {
		font-size: var(--fs-body);
		line-height: 33px;
	}
}

/* Thank you ---------------------------------------------------------------- */

.thank-you {
	position: relative;
	display: flex;
	align-items: center;
	justify-content: center;
	min-height: max(560px, 45.2vw);
	margin: clamp(0px, calc(24 * var(--fluid)), 24px) var(--inset) 0;
	padding: 150px var(--gutter);
	overflow: hidden;
	border-radius: var(--radius-card);
	background: var(--color-black);
	color: var(--color-subtle);
	text-align: center;
}

.thank-you__media {
	position: absolute;
	inset: 0;
}

.thank-you__img {
	position: absolute;
	top: -15.32%;
	left: -38.06%;
	width: 139.12%;
	max-width: none;
}

/* Darkened and softly blurred behind the text. */
.thank-you__media::after {
	position: absolute;
	inset: 0;
	background: rgba(0, 0, 0, 0.52);
	-webkit-backdrop-filter: blur(21px);
	backdrop-filter: blur(21px);
	content: "";
}

.thank-you__inner {
	position: relative;
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 20px;
	max-width: 1173px;
}

.thank-you__heading {
	text-wrap: balance;
}

.thank-you__heading em {
	color: inherit;
}

.thank-you__text {
	font-size: var(--fs-lead);
	font-weight: 500;
	line-height: 1.4;
}

/* On desktop the header menu covers it; phones get a way back. */
.thank-you__button {
	display: none;
}

@media (max-width: 767px) {
	.thank-you {
		align-items: flex-end;
		justify-content: flex-start;
		min-height: min(149vw, 100svh);
		margin: 0;
		padding: 140px var(--gutter) clamp(72px, calc(72px + 35 * var(--fluid-m)), 107px);
		text-align: left;
	}

	.thank-you__img {
		inset: 0;
		width: 100%;
		height: 100%;
		object-fit: cover;
	}

	.thank-you__inner {
		align-items: flex-start;
		gap: 13px;
	}

	.thank-you__text {
		font-weight: 400;
		line-height: 1.5;
	}

	.thank-you__button {
		display: inline-flex;
		margin-top: 17px;
	}
}

/* 404 ---------------------------------------------------------------------- */

.site-main--error {
	padding: 107px 0 var(--section-gap);
}

.site-main--error::before {
	bottom: -9px;
	left: -0.9vw;
	width: 43.6vw;
}

.site-main--error::after {
	top: -95px;
	left: 58.1vw;
	width: 43.6vw;
}

.error-page {
	display: flex;
	flex-direction: column;
	align-items: center;
	text-align: center;
}

/* "4", bust, "4": positions are percentages of the 913 × 697 artboard group. */
.error-art {
	position: relative;
	width: min(100%, 913px);
	aspect-ratio: 913 / 697;
}

.error-art > * {
	position: absolute;
	max-width: none;
}

.error-art__digit--left { top: 41.32%; left: -1.2%; width: 36.47%; }
.error-art__digit--zero { top: 40.32%; left: 31.54%; width: 38.44%; }
.error-art__digit--right { top: 41.32%; left: 64.62%; width: 36.58%; }

.error-art__bust {
	top: 0;
	left: 28.48%;
	width: 44.8%;
	height: 93.54%;
	overflow: hidden;
	border-radius: 30.81% / 19.33%;
}

.error-art__bust img {
	position: absolute;
	top: 14.1%;
	left: -8.13%;
	width: 113.53%;
	max-width: none;
	height: 106.76%;
}

/* A second copy clipped to the "0", so the bust ends on the numeral's curve. */
.error-art__bust--in-zero {
	top: 39.84%;
	left: 31.18%;
	width: 39.13%;
	height: 60.15%;
	border-radius: 0;
	-webkit-mask: url("../images/404/zero-mask.svg") center / 98.06% 98.22% no-repeat;
	mask: url("../images/404/zero-mask.svg") center / 98.06% 98.22% no-repeat;
}

.error-art__bust--in-zero img {
	top: -44.32%;
	left: -16.09%;
	width: 129.81%;
	height: 165.92%;
}

.error-page__message {
	margin: 40px 0 35px;
	font-size: clamp(18px, calc(18px + 7 * var(--fluid)), 25px);
	font-weight: 500;
	line-height: 1.4;
}

@media (max-width: 767px) {
	/* With no footer below, the page's foot keeps clear of the pinned Book / Call
	   bar (its buttons plus 10px), with 40px to spare. */
	.site-main--error {
		padding-top: clamp(130px, calc(130px + 51 * var(--fluid-m)), 181px);
		padding-bottom: calc(clamp(56px, calc(56px + 24 * var(--fluid-m)), 80px) + 50px);
	}

	/* The phone board crops the bust as a pill and drops the clipped copy. */
	.error-art {
		width: min(100%, 465px);
		aspect-ratio: 465 / 360;
	}

	.error-art__digit--left { top: 40.67%; left: -1.2%; width: 36.39%; }
	.error-art__digit--zero { top: 39.83%; left: 31.48%; width: 38.54%; }
	.error-art__digit--right { top: 40.67%; left: 64.6%; width: 36.6%; }

	.error-art__bust {
		left: 30.97%;
		width: 39.57%;
		height: 100%;
		border-radius: 999px;
	}

	.error-art__bust img {
		top: 14.02%;
		left: -20.22%;
		width: 138.21%;
		height: 106.17%;
	}

	.error-art__bust--in-zero {
		display: none;
	}

	.error-page__message {
		margin: 51px 0 38px;
		line-height: 30px;
	}
}

/* Service ------------------------------------------------------------------ */

.site-main--service {
	--service-gap: clamp(72px, calc(72px + 128 * var(--fluid)), 200px);
	display: flex;
	flex-direction: column;
	gap: var(--service-gap);
	padding-bottom: var(--service-gap);
}

/* The board leaves a little less room under the hero than between sections. */
.site-main--service > .hero + * {
	margin-top: calc(var(--section-gap) - var(--service-gap));
}

.site-main--no-hero {
	padding-top: clamp(130px, calc(130px + 70 * var(--fluid)), 200px);
}

/* The service, about and surgeon boards keep italic words in section headings
   the text colour; only the home board sets them in the accent. */
.site-main--service .heading-2 em,
.site-main--about .heading-2 em,
.site-main--surgeon .heading-2 em {
	color: inherit;
}

.site-main--service .ba-gallery {
	gap: clamp(30px, calc(30px + 14 * var(--fluid)), 44px);
}

.hero--service .hero__inner {
	gap: clamp(48px, calc(48px + 151 * var(--fluid)), 199px);
}

/* 909px on the board; the Boska stand-in sets a little wider than Canela. */
.hero--service .hero__text {
	max-width: 950px;
}

@media (max-width: 767px) {
	.site-main--service {
		--service-gap: var(--section-gap);
	}

	.site-main--service > .hero + * {
		margin-top: calc(55px - var(--service-gap));
	}

	/* The phone board runs the candidate and expectations copy together. */
	.divider--wide {
		display: none;
	}
}

/* Service copy: 22px paragraphs; bulleted lists get check marks. */
.rich-text.service-copy p + ul,
.rich-text.service-copy ul + p {
	margin-top: 20px;
}

.service-copy ul {
	display: flex;
	flex-direction: column;
	gap: 10px;
	padding: 0;
	list-style: none;
}

.service-copy li {
	position: relative;
	padding-left: 30px;
}

.service-copy li::before {
	position: absolute;
	top: calc(0.75em - 7.5px);
	left: 0;
	width: 15px;
	height: 15px;
	background: url("../images/icons/check.svg") center / contain no-repeat;
	content: "";
}

/* Introduction: heading above a wide photo, copy centred beside them. */
.service-intro {
	display: grid;
	grid-template-areas:
		"heading body"
		"media body";
	grid-template-columns: minmax(0, 704fr) minmax(0, 754fr);
	align-items: center;
	gap: 53px clamp(40px, calc(40px + 171 * var(--fluid)), 211px);
}

.service-intro--text {
	grid-template-areas: "heading body";
}

.service-intro__heading {
	grid-area: heading;
	align-self: end;
}

.service-intro__body {
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	gap: 36px;
	grid-area: body;
}

.service-intro__media {
	grid-area: media;
	align-self: start;
	aspect-ratio: 704 / 350;
	overflow: hidden;
	border-radius: var(--radius);
}

/* Check-mark copy beside a tall photo that grows with the text. */
.checklist {
	display: grid;
	grid-template-columns: minmax(0, 881fr) minmax(0, 623fr);
	align-items: center;
	column-gap: clamp(40px, calc(40px + 128 * var(--fluid)), 168px);
}

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

.checklist__text {
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	gap: 20px;
}

.checklist__media {
	position: relative;
	align-self: stretch;
	overflow: hidden;
	border-radius: var(--radius);
}

.checklist__media::before {
	display: block;
	padding-top: 124.4%;
	content: "";
}

.checklist__media img {
	position: absolute;
	inset: 0;
}

/* Mirrored: photo on the left (cost, which sits right above why choose us). */
.checklist--flip {
	grid-template-columns: minmax(0, 623fr) minmax(0, 881fr);
}

.checklist--flip .checklist__media {
	order: -1;
}

/* Why choose us shows the surgeon: crop from the top so the head stays in. */
.checklist--why .checklist__media img {
	object-position: center top;
}

@media (max-width: 1023px) {
	.service-intro,
	.service-intro--text {
		grid-template-areas:
			"heading"
			"body"
			"media";
		grid-template-columns: minmax(0, 1fr);
		gap: 25px;
	}

	.service-intro__body {
		gap: 25px;
	}

	.service-intro__media {
		margin-top: 25px;
		aspect-ratio: 480 / 324;
	}

	.checklist {
		grid-template-columns: minmax(0, 1fr);
		gap: 40px;
	}

	.checklist__text {
		gap: 25px;
	}

	.checklist--flip .checklist__media {
		order: 0;
	}

	.checklist__media::before {
		padding-top: 94.8%;
	}
}

/* Dark bands: a photo behind, darkened (options, recovery timeline). */
.service-band {
	position: relative;
	isolation: isolate;
	margin-inline: var(--inset);
	overflow: hidden;
	border-radius: var(--radius-card);
	background: var(--color-black);
	color: var(--color-subtle);
}

.service-band__media {
	position: absolute;
	z-index: -1;
	inset: 0;
}

.service-band__media img {
	width: 100%;
	height: 100%;
	object-fit: cover;
}

.service-band__media::after {
	position: absolute;
	inset: 0;
	content: "";
}

.service-band__inner {
	width: 100%;
	max-width: calc(var(--content-max) + 2 * (var(--gutter) - var(--inset)));
	margin-inline: auto;
	padding-inline: calc(var(--gutter) - var(--inset));
}

.service-band .heading-2 em {
	color: inherit;
}

.service-options {
	padding-block: clamp(100px, calc(100px + 50 * var(--fluid)), 150px);
}

.service-options .service-band__media::after {
	background: rgba(0, 0, 0, 0.39);
}

.service-options__header {
	display: flex;
	flex-direction: column;
	gap: 10px;
	max-width: 728px;
}

.service-options__intro,
.service-timeline__intro {
	font-size: var(--fs-body);
	line-height: 1.5;
}

/* Option cards are as tall as their text, and each row as tall as its tallest
   card (grid rows stretch their cards). Desktop gives each card a column, up
   to four (--columns, set inline); five or more go three to a row on a six-
   column grid, the cards of a short last row widening to fill it (5 = 3 + 2).
   Below 1280px it's two columns, with an odd card out across the last row,
   and on phones one. */
.service-options__grid {
	display: grid;
	grid-template-columns: repeat(var(--columns, 4), minmax(0, 1fr));
	align-items: stretch;
	gap: 22px;
	margin: 40px 0 0;
	padding: 0;
	list-style: none;
}

@media (min-width: 1280px) {
	.service-options__grid--rows {
		grid-template-columns: repeat(6, minmax(0, 1fr));
	}

	.service-options__grid--rows > .glass-card {
		grid-column: span 2;
	}

	.service-options__grid--rows > .glass-card:nth-child(3n + 1):nth-last-child(2),
	.service-options__grid--rows > .glass-card:nth-child(3n + 2):last-child {
		grid-column: span 3;
	}

	.service-options__grid--rows > .glass-card:nth-child(3n + 1):last-child {
		grid-column: span 6;
	}
}

.glass-card {
	display: flex;
	flex-direction: column;
	gap: 20px;
	padding: 45px 45px 40px;
	border: 0.5px solid rgba(255, 255, 255, 0.1);
	border-radius: var(--radius);
	background: linear-gradient(rgba(155, 155, 155, 0.08), rgba(5, 5, 5, 0.08));
	-webkit-backdrop-filter: blur(37.5px);
	backdrop-filter: blur(37.5px);
}

.glass-card__text p,
.glass-card__text {
	font-size: clamp(17px, calc(17px + 3 * var(--fluid)), 20px);
	line-height: 1.5;
}

/* Title-only option cards: glass chips that wrap like tags. */
.service-options__chips {
	display: flex;
	flex-wrap: wrap;
	gap: 14px;
	max-width: 1100px;
	margin: 40px 0 0;
	padding: 0;
	list-style: none;
}

.service-options__grid + .service-options__chips {
	margin-top: 22px;
}

.glass-chip {
	padding: 14px 28px;
	border: 0.5px solid rgba(255, 255, 255, 0.1);
	border-radius: 999px;
	background: linear-gradient(rgba(155, 155, 155, 0.08), rgba(5, 5, 5, 0.08));
	-webkit-backdrop-filter: blur(37.5px);
	backdrop-filter: blur(37.5px);
	font-size: clamp(17px, calc(17px + 3 * var(--fluid)), 20px);
	line-height: 1.3;
}

/* A "Full width" card takes its own row, below the others. */
.service-options__grid > .glass-card--wide {
	grid-column: 1 / -1;
}

/* Sub-headings inside a card (e.g. the approaches under one procedure). */
.glass-card__text h4 {
	margin-top: 10px;
	font-family: var(--font-serif);
	font-size: clamp(21px, calc(21px + 4 * var(--fluid)), 25px);
	font-weight: 300;
	line-height: 1.2;
}

.glass-card__text h4 + p {
	margin-top: 8px;
}

.service-timeline {
	padding-block: clamp(100px, calc(100px + 79 * var(--fluid)), 179px) clamp(100px, calc(100px + 50 * var(--fluid)), 150px);
}

.service-timeline .service-band__media::after {
	background: rgba(0, 0, 0, 0.62);
	-webkit-backdrop-filter: blur(25px);
	backdrop-filter: blur(25px);
}

.service-timeline__header {
	display: flex;
	flex-direction: column;
	gap: 10px;
	max-width: 886px;
	margin-inline: auto;
	text-align: center;
}

.service-timeline__intro {
	max-width: 732px;
	margin-inline: auto;
}

.service-timeline__button {
	display: flex;
	width: fit-content;
	margin: clamp(40px, calc(40px + 40 * var(--fluid)), 80px) auto 0;
}

/* Wide screens: three stages a row on a line that runs out to the right
   edge at the end of each row and back in from the left on the next. */
.service-timeline__stages {
	--stage-gap: clamp(40px, calc(40px + 40 * var(--fluid)), 80px);
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: 55px var(--stage-gap);
	max-width: 1368px;
	margin: 65px auto 0;
	padding: 0;
	list-style: none;
}

.service-timeline__stage {
	position: relative;
	padding-top: 71px;
}

.service-timeline__dot {
	position: absolute;
	z-index: 1;
	top: 0;
	left: 0;
	width: 16px;
	height: 16px;
	border-radius: 50%;
	background: var(--color-divider);
}

.service-timeline__stage:first-child .service-timeline__dot {
	background: var(--color-white);
}

.service-timeline__stage::before,
.service-timeline__stage::after {
	position: absolute;
	top: 7.5px;
	height: 1px;
	background: rgba(208, 208, 198, 0.55);
	content: "";
}

/* Line on to the next dot; the first stretch is drawn brighter. */
.service-timeline__stage::after {
	left: 8px;
	width: calc(100% + var(--stage-gap));
}

.service-timeline__stage:first-child::after {
	background: var(--color-divider);
}

.service-timeline__stage:nth-child(3n)::after {
	width: 100vw;
}

.service-timeline__stage:last-child::after {
	display: none;
}

/* Lead-in from the left edge at the start of every row after the first. */
.service-timeline__stage:nth-child(3n + 4)::before {
	right: calc(100% - 8px);
	width: 100vw;
}

.service-timeline__title {
	margin-bottom: 20px;
	font-family: var(--font-serif);
	font-size: clamp(25px, calc(25px + 5 * var(--fluid)), 30px);
	font-weight: 300;
	line-height: 1;
}

.service-timeline__stage p:not(.service-timeline__title) {
	font-size: var(--fs-body);
	line-height: 1.5;
}

/* Narrow screens: one column on a vertical line through the dots. */
@media (max-width: 1023px) {
	.service-timeline__header {
		text-align: left;
	}

	.service-timeline__intro {
		margin-inline: 0;
	}

	.service-timeline__button {
		margin-inline: 0;
	}

	.service-timeline__stages {
		grid-template-columns: minmax(0, 1fr);
		row-gap: 40px;
		margin-top: 40px;
	}

	.service-timeline__stage {
		padding: 0 0 0 30px;
	}

	.service-timeline__dot {
		top: 10px;
		width: 10px;
		height: 10px;
	}

	.service-timeline__stage::before {
		display: none;
	}

	.service-timeline__stage::after,
	.service-timeline__stage:nth-child(3n)::after {
		top: 15px;
		left: 4.5px;
		display: block;
		width: 1px;
		height: calc(100% + 40px);
	}

	.service-timeline__stage:last-child::after {
		display: none;
	}

	.service-timeline__title {
		margin-bottom: 15px;
		line-height: 30px;
	}
}

@media (max-width: 1279px) {
	.service-options__grid {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}

	.service-options__grid > .glass-card:nth-child(odd):last-child {
		grid-column: 1 / -1;
	}
}

@media (max-width: 767px) {
	.service-options__grid {
		grid-template-columns: minmax(0, 1fr);
		gap: 20px;
	}

	.service-options .service-band__media::after {
		background: linear-gradient(270deg, rgba(17, 17, 17, 0.69), rgba(12, 12, 12, 0.69));
	}

	.service-options .service-band__media img {
		object-position: 60% center;
	}

	.service-options__header {
		max-width: none;
	}

	.glass-card {
		padding: 45px 30px;
	}

	.glass-card__title,
	.service-expect__step .heading-5 {
		font-size: clamp(25px, calc(25px + 5 * var(--fluid-m)), 30px);
		letter-spacing: -1px;
	}

	.glass-card__text p,
	.glass-card__text {
		font-size: var(--fs-body);
	}
}

/* What to expect: three steps split by hairlines. */
.service-expect {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: clamp(40px, calc(40px + 60 * var(--fluid)), 100px);
}

.service-expect__heading {
	max-width: 1200px;
	text-align: center;
}

.service-expect__steps {
	--step-gap: clamp(40px, calc(40px + 105 * var(--fluid)), 145px);
	display: grid;
	grid-template-columns: repeat(var(--columns, 3), minmax(0, 1fr));
	column-gap: var(--step-gap);
	width: 100%;
	margin: 0;
	padding: 0;
	list-style: none;
}

.service-expect__step {
	position: relative;
	display: flex;
	flex-direction: column;
	gap: 15px;
	padding-block: 30px;
}

.service-expect__text ul {
	font-size: var(--fs-body);
	line-height: 1.5;
	margin: 10px 0 0;
	padding-left: 1.2em;
	list-style: disc;
	text-align: left;
}

.service-expect__text li + li {
	margin-top: 6px;
}

.service-expect__text p + p,
.service-expect__text p + ul {
	margin-top: 10px;
}

.service-expect__step + .service-expect__step::before {
	position: absolute;
	top: 0;
	bottom: 0;
	left: calc(var(--step-gap) / -2);
	width: 1px;
	background: var(--color-divider);
	content: "";
}

.service-expect__icon {
	width: 54px;
	height: 54px;
	margin-bottom: 15px;
}

.service-expect__step p:not(.heading-5) {
	font-size: var(--fs-body);
	line-height: 1.5;
}

@media (max-width: 1023px) {
	.service-expect {
		align-items: stretch;
		gap: 25px;
	}

	.service-expect__heading {
		text-align: left;
	}

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

	.service-expect__step + .service-expect__step {
		margin-top: 41px;
	}

	.service-expect__step + .service-expect__step::before {
		top: -20.5px;
		right: 0;
		bottom: auto;
		left: 0;
		width: auto;
		height: 1px;
	}
}

/* FAQ accordion on a black band. */
.service-faq {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 40px;
	margin-inline: var(--inset);
	padding: clamp(70px, calc(70px + 80 * var(--fluid)), 150px) calc(var(--gutter) - var(--inset));
	border-radius: var(--radius-card);
	background: var(--color-black);
	color: var(--color-subtle);
}

.service-faq__heading {
	max-width: 751px;
	text-align: center;
}

.service-faq__heading em {
	color: inherit;
}

.service-faq__list {
	display: flex;
	flex-direction: column;
	gap: 20px;
	width: 100%;
	max-width: 738px;
}

.faq-item {
	position: relative;
	border-radius: var(--radius);
	background: rgba(255, 255, 255, 0.2);
	-webkit-backdrop-filter: blur(25px);
	backdrop-filter: blur(25px);
}

/* The board's 0.5px stroke: white at the top fading to black at the foot, at
   34%. A ring cut from a gradient, since borders can't take one with rounded
   corners. */
.faq-item::before {
	position: absolute;
	inset: 0;
	padding: 0.5px;
	border-radius: inherit;
	background: linear-gradient(rgba(255, 255, 255, 0.34), rgba(0, 0, 0, 0.34));
	content: "";
	pointer-events: none;
	-webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
	-webkit-mask-composite: xor;
	mask: linear-gradient(#000 0 0) content-box exclude, linear-gradient(#000 0 0);
}

.faq-item__question {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 40px;
	padding: 30px 40px;
	border-radius: var(--radius);
	font-size: var(--fs-lead);
	line-height: 1.4;
	list-style: none;
	cursor: pointer;
}

.faq-item__question::-webkit-details-marker {
	display: none;
}

.faq-item__icon {
	flex: none;
	width: 12px;
	height: 12px;
	transition: transform var(--motion-hover) var(--ease-soft);
}

.faq-item[open] .faq-item__icon {
	transform: rotate(45deg);
}

.faq-item__answer {
	padding: 0 40px 30px;
	color: rgba(240, 240, 238, 0.82);
	font-size: clamp(17px, calc(17px + 3 * var(--fluid)), 20px);
}

/* Open and close smoothly where the browser can animate to auto height. */
@supports (interpolate-size: allow-keywords) {
	.service-faq {
		interpolate-size: allow-keywords;
	}

	.faq-item::details-content {
		height: 0;
		overflow: clip;
		transition: height var(--motion-hover) var(--ease-soft), content-visibility var(--motion-hover) allow-discrete;
	}

	.faq-item[open]::details-content {
		height: auto;
	}
}

@media (max-width: 767px) {
	.service-faq {
		align-items: stretch;
	}

	.service-faq__heading {
		text-align: left;
	}

	.faq-item__question {
		padding: 30px;
		font-size: clamp(20px, calc(20px + 3 * var(--fluid-m)), 23px);
		line-height: 30px;
	}

	.faq-item__answer {
		padding: 0 30px 30px;
	}
}

/* Related procedures: pill links with small sculpture photos between. */
.service-explore {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: clamp(30px, calc(30px + 50 * var(--fluid)), 80px);
}

.service-explore .section-title {
	max-width: 939px;
}

.service-explore__list {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: center;
	gap: 50px 51px;
	width: 100%;
	margin: 0;
	padding: 0;
	list-style: none;
	container-type: inline-size;
}

/* Sized so three links and two photos share a row, as on the board. */
.service-explore__link {
	display: flex;
	align-items: center;
	justify-content: center;
	width: min(340px, (100cqi - 384px) / 3);
	min-height: 90px;
	padding: 20px 30px;
	border-radius: 6px;
	background: var(--color-subtle);
	font-family: var(--font-serif);
	font-size: var(--fs-h5);
	font-weight: 300;
	line-height: 1;
	text-align: center;
	text-decoration: none;
	transition: background-color var(--motion-hover) var(--ease-soft);
}

.service-explore__link:hover {
	background: var(--color-placeholder);
}

.service-explore__photo {
	width: 90px;
	height: 90px;
	overflow: hidden;
	border-radius: 6px;
}

/* Too narrow for that row: links only. */
@container (max-width: 1163px) {
	.service-explore__link {
		width: 300px;
	}

	.service-explore__photo {
		display: none;
	}
}

@media (max-width: 1023px) {
	.service-explore__list {
		gap: 20px;
	}
}

@media (max-width: 767px) {
	.service-explore {
		align-items: flex-start;
	}

	.service-explore .section-title {
		text-align: left;
	}

	.service-explore__list {
		justify-content: flex-start;
	}

	.service-explore__link {
		width: auto;
		min-height: 0;
		padding: 20px 45px;
		font-size: 25px;
		line-height: 30px;
	}
}

/* About -------------------------------------------------------------------- */

.site-main--about {
	--about-gap: clamp(72px, calc(72px + 128 * var(--fluid)), 200px);
	--about-hero-gap: clamp(55px, calc(55px + 96 * var(--fluid)), 151px);
	position: relative;
	isolation: isolate;
	display: flex;
	flex-direction: column;
	gap: var(--about-gap);
	padding-bottom: var(--section-gap);
}

.site-main--about > .hero + * {
	margin-top: calc(var(--about-hero-gap) - var(--about-gap));
}

/* The Instagram band runs straight into the consultation banner. */
.site-main--about:has(> .instagram:last-child) {
	padding-bottom: var(--inset);
}

.hero--about .hero__inner {
	gap: clamp(48px, calc(48px + 81 * var(--fluid)), 129px);
}

.hero--about .hero__text {
	max-width: 773px;
}

/* Surgeon profiles: bio beside the portrait (sides alternate), then affiliations. */
.profile {
	position: relative;
	display: flex;
	flex-direction: column;
	gap: var(--about-gap);
}

.profile__row {
	display: grid;
	grid-template-areas: "text media";
	grid-template-columns: minmax(0, 779fr) minmax(0, 623fr);
	align-items: center;
	column-gap: clamp(40px, calc(40px + 226 * var(--fluid)), 266px);
}

.profile--reverse .profile__row {
	grid-template-areas: "media text";
	grid-template-columns: minmax(0, 623fr) minmax(0, 779fr);
}

.profile--text .profile__row {
	grid-template-areas: "text";
	grid-template-columns: minmax(0, 1fr);
}

.profile__text {
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	gap: 10px;
	grid-area: text;
}

.profile__button {
	margin-top: 10px;
}

.profile__media {
	position: relative;
	grid-area: media;
}

.profile__photo {
	aspect-ratio: 623 / 681;
	overflow: hidden;
	border-radius: var(--radius);
}

/* Faint "H" monograms: one under the hero, one peeking out below each portrait. */
.profile__media::before,
.site-main--about > .hero + .profile::before {
	position: absolute;
	z-index: -1;
	width: 335px;
	aspect-ratio: 335 / 319;
	background: url("../images/watermark.svg") center / contain no-repeat;
	content: "";
	pointer-events: none;
}

.profile__media::before {
	top: calc(100% - 85px);
	left: 40%;
}

.profile--reverse .profile__media::before {
	top: calc(100% - 68px);
	left: 2%;
}

.site-main--about > .hero + .profile::before {
	top: calc(-1 * var(--about-hero-gap) - 112px);
	left: 50%;
	transform: translateX(-50%);
}

/* Affiliation logos (About, Surgeon pages) run as a marquee on tablets and
   phones however many there are. Wider, four or fewer spread across the row
   and more run as a marquee. A row takes about 7s a logo to go round (6.5s
   on phones), so a longer row runs longer rather than faster; main.js adds
   copies to fill a short one. The row pauses under the pointer; beyond
   phones the logos fade in and out at its ends (phones run them to the edges
   of the screen). Phones are under "About" below. */
.logo-marquee--spread {
	--marquee-duration: calc(var(--marquee-count, 5) * 7s);
	--marquee-gap: clamp(60px, calc(60px + 40 * var(--fluid)), 100px);
	--marquee-fade: clamp(30px, calc(30px + 50 * var(--fluid)), 80px);
}

.logo-marquee--spread .logo-marquee__list {
	flex: 1;
	justify-content: space-between;
}

/* The same marquee twice: every row on tablets, rows of five or more wider. */
@media (prefers-reduced-motion: no-preference) and (min-width: 768px) and (max-width: 1023px) {
	.logo-marquee--spread {
		mask-image: linear-gradient(to right, transparent, #000 var(--marquee-fade), #000 calc(100% - var(--marquee-fade)), transparent);
	}

	.logo-marquee--spread .logo-marquee__list,
	.logo-marquee--spread .logo-marquee__list[aria-hidden="true"] {
		display: flex;
		flex: none;
		flex-wrap: nowrap;
		gap: var(--marquee-gap);
		padding-right: var(--marquee-gap);
		animation: marquee var(--marquee-duration) linear infinite;
	}
}

@media (prefers-reduced-motion: no-preference) and (min-width: 1024px) {
	.logo-marquee--spread:not(.logo-marquee--static) {
		mask-image: linear-gradient(to right, transparent, #000 var(--marquee-fade), #000 calc(100% - var(--marquee-fade)), transparent);
	}

	.logo-marquee--spread:not(.logo-marquee--static) .logo-marquee__list,
	.logo-marquee--spread:not(.logo-marquee--static) .logo-marquee__list[aria-hidden="true"] {
		display: flex;
		flex: none;
		flex-wrap: nowrap;
		gap: var(--marquee-gap);
		padding-right: var(--marquee-gap);
		animation: marquee var(--marquee-duration) linear infinite;
	}
}

.logo-marquee--spread:hover :is(.logo-marquee__list, .logo-marquee__item) {
	animation-play-state: paused;
}

@media (max-width: 1279px) {
	.logo-marquee--spread .logo-marquee__list {
		justify-content: center;
	}

	.logo-marquee--spread .logo-marquee__item img {
		height: calc(var(--logo-h) * 0.8);
	}
}

@media (max-width: 1023px) {
	.profile__row,
	.profile--reverse .profile__row {
		grid-template-areas:
			"media"
			"text";
		grid-template-columns: minmax(0, 1fr);
		gap: 50px;
	}

	.profile__text {
		gap: 25px;
	}

	.profile__button {
		margin-top: 0;
	}

	.profile__photo {
		aspect-ratio: 480 / 525;
	}
}

@media (max-width: 767px) {
	.site-main--about {
		--about-gap: var(--section-gap);
	}

	.site-main--about > .hero + * {
		margin-top: calc(55px - var(--about-gap));
	}

	.profile {
		gap: 50px;
	}

	.profile__media::before,
	.site-main--about > .hero + .profile::before {
		display: none;
	}

	.logo-marquee--spread .logo-marquee__list,
	.logo-marquee--spread .logo-marquee__list[aria-hidden="true"] {
		flex: none;
		justify-content: flex-start;
		gap: 60px;
		padding-right: 60px;
	}

	.logo-marquee--spread {
		--marquee-duration: calc(var(--marquee-count, 5) * 6.5s);
	}

	.logo-marquee--spread .logo-marquee__item img {
		height: calc(var(--logo-h) * 0.7);
	}
}

/* Surgeon ------------------------------------------------------------------ */

.site-main--surgeon {
	--surgeon-gap: clamp(80px, calc(80px + 68 * var(--fluid)), 148px);
	display: flex;
	flex-direction: column;
	gap: var(--surgeon-gap);
	padding: clamp(150px, calc(150px + 22 * var(--fluid)), 172px) 0 var(--surgeon-gap);
}

/* Intro: name and bio beside the portrait with its credential card and caption. */
.surgeon-intro {
	display: grid;
	grid-template-columns: minmax(0, 741fr) minmax(0, 703fr);
	align-items: center;
	column-gap: clamp(40px, calc(40px + 184 * var(--fluid)), 224px);
}

.surgeon-intro--text {
	grid-template-columns: minmax(0, 1fr);
}

.surgeon-intro__text {
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	gap: 20px;
}

.surgeon-intro__credentials,
.surgeon-affiliations__label {
	font-size: clamp(18px, calc(18px + 2 * var(--fluid)), 20px);
	font-weight: 500;
	line-height: 1.5;
}

.surgeon-intro__portrait {
	position: relative;
	container: surgeon-portrait / inline-size;
}

.surgeon-intro__photo {
	aspect-ratio: 703 / 777;
	overflow: hidden;
	border-radius: var(--radius);
}

.surgeon-intro__badge,
.surgeon-intro__caption {
	position: absolute;
	right: 24px;
	box-shadow: var(--shadow-soft);
}

.surgeon-intro__badge {
	top: 25px;
	display: flex;
	flex-direction: column;
	gap: 5px;
	padding: 30px;
	border-radius: var(--radius);
	background: var(--color-white);
	font-size: 15px;
	font-weight: 500;
	line-height: 16px;
}

.surgeon-intro__badge-label {
	color: var(--color-accent-dark);
}

.surgeon-intro__caption {
	bottom: 21px;
	width: min(385px, calc(100% - 48px));
	padding: 20px 30px;
	border-radius: var(--radius);
	background: rgba(37, 37, 37, 0.87);
	color: var(--color-white);
	font-size: 17px;
	line-height: 24px;
}

.surgeon-affiliations {
	display: flex;
	flex-direction: column;
	gap: 57px;
	margin-top: calc(44px - var(--surgeon-gap));
}

/* The board leaves a little more room under the logos than between sections. */
.surgeon-affiliations + .profile {
	margin-top: clamp(11px, calc(11px + 15 * var(--fluid)), 26px);
}

/* Sections: photos keep their own proportions; sub-headings come from Heading 3. */
.profile--section .profile__text {
	gap: 15px;
}

.profile--section .profile__photo {
	aspect-ratio: auto;
}

.profile--section .profile__photo img {
	height: auto;
}

.profile--section .profile__media::before {
	display: none;
}

.profile--section .profile__bio h3 {
	margin: 40px 0 15px;
	font-family: var(--font-serif);
	font-size: var(--fs-h5);
	font-weight: 300;
	line-height: 1;
}

/* The intro stacks from 1279px down, before the portrait gets narrow enough for
   the credential card to cover the surgeon's face; the photo then keeps to
   about its desktop size. */
@media (max-width: 1279px) {
	.surgeon-intro {
		grid-template-columns: minmax(0, 1fr);
		row-gap: clamp(60px, calc(60px + 40 * var(--fluid)), 100px);
	}

	.surgeon-intro__portrait {
		width: 100%;
		max-width: 703px;
	}

	.surgeon-intro__photo {
		aspect-ratio: 480 / 531;
	}
}

@media (max-width: 1023px) {
	.profile--section .profile__row {
		grid-template-areas:
			"text"
			"media";
	}

	.profile--section .profile__text {
		gap: 25px;
	}

	.profile--section .profile__photo {
		aspect-ratio: 480 / 476;
	}

	.profile--section .profile__photo img {
		height: 100%;
	}

	.profile--section .profile__bio h3 {
		margin: 25px 0;
	}
}

@media (max-width: 767px) {
	.site-main--surgeon {
		padding-top: clamp(150px, calc(150px + 39 * var(--fluid-m)), 189px);
	}

	.surgeon-intro__name {
		font-size: var(--fs-h1);
		line-height: 1;
	}

	.surgeon-intro__badge {
		top: 18px;
		right: 20px;
		padding: 10px 20px;
		border-radius: 6px;
		font-size: 16px;
	}

	.surgeon-intro__caption {
		right: 15px;
		bottom: 17px;
		width: min(344px, calc(100% - 30px));
		padding: 15px 20px;
		border-radius: 6px;
		font-size: 15px;
		line-height: 19px;
	}

	.surgeon-affiliations {
		gap: 35px;
		margin-top: calc(74px - var(--surgeon-gap));
	}

	.profile--section .profile__bio h3 {
		font-size: 30px;
		letter-spacing: -1px;
	}
}

/* The card sits top right, as designed. A surgeon page set to "Lower down"
   (when the card would cover the face) drops it below the face line, in the
   top third of the photo, wherever the portrait is narrower than 650px. */
@container surgeon-portrait (max-width: 649px) {
	.surgeon-intro__badge--lower {
		top: 40%;
	}
}

/* Blog --------------------------------------------------------------------- */

.site-main--blog {
	--blog-gap: clamp(60px, calc(60px + 92 * var(--fluid)), 152px);
	position: relative;
	isolation: isolate;
	padding: clamp(150px, calc(150px + 183 * var(--fluid)), 333px) 0 93px;
}

/* Faint "H" at the top of the page, behind the header (blog and gallery). */
.site-main--blog::before,
.site-main--gallery::before {
	position: absolute;
	z-index: -1;
	top: -13px;
	left: 50%;
	width: clamp(160px, calc(160px + 175 * var(--fluid)), 335px);
	aspect-ratio: 335 / 319;
	background: url("../images/watermark.svg") center / contain no-repeat;
	content: "";
	pointer-events: none;
	transform: translateX(-50%);
}

.blog-header {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 27px;
	text-align: center;
}

/* Filter bar (blog categories, gallery procedures): pill tabs, or a drop-down
   on phones. Blog filters are links; gallery filters are buttons. */
.filter-bar__tabs,
.filter-bar__options {
	margin: 0;
	padding: 0;
	list-style: none;
}

.filter-bar__tabs {
	display: flex;
	flex-wrap: wrap;
	justify-content: center;
	padding: 11px 12px;
	border-radius: 200px;
	background: var(--color-subtle);
}

.filter-bar__tab,
.filter-bar__toggle,
.filter-bar__option {
	font-size: 18px;
	font-weight: 500;
	line-height: 26px;
	letter-spacing: -0.03em;
	text-decoration: none;
}

.filter-bar__tab {
	display: block;
	padding: 9px 24px;
	border-radius: 200px;
	transition: background-color var(--motion-hover) var(--ease-soft), color var(--motion-hover) var(--ease-soft);
}

.filter-bar__tab:hover {
	color: var(--color-accent-dark);
}

.filter-bar__tab.is-active {
	background: var(--color-black);
	box-shadow: 0 1px 1px rgba(155, 155, 155, 0.06), 0 4px 4px rgba(213, 213, 213, 0.06);
	color: var(--color-white);
}

.filter-bar__menu {
	position: relative;
	display: none;
}

.filter-bar__toggle {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 20px;
	min-width: 268px;
	padding: 12px 30px;
	border-radius: 200px;
	background: var(--color-subtle);
	cursor: pointer;
	list-style: none;
}

.filter-bar__toggle::-webkit-details-marker {
	display: none;
}

.filter-bar__toggle .icon {
	flex: none;
	transition: transform var(--motion-hover) var(--ease-soft);
}

.filter-bar__menu[open] .filter-bar__toggle .icon {
	transform: rotate(180deg);
}

.filter-bar__options {
	position: absolute;
	z-index: 5;
	top: calc(100% + 8px);
	left: 0;
	min-width: 100%;
	padding: 14px 0;
	border-radius: var(--radius);
	background: var(--color-white);
	box-shadow: var(--shadow-soft);
}

.filter-bar__option {
	display: block;
	width: 100%;
	padding: 8px 30px;
	text-align: left;
}

.filter-bar__option:hover,
.filter-bar__option.is-active {
	color: var(--color-accent-dark);
}

/* Articles, divided by hairlines: three to a row, two on tablets, one on phones. */
.blog-grid {
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	column-gap: var(--blog-gap);
	margin-top: clamp(50px, calc(50px + 29 * var(--fluid)), 79px);
}

.blog-card {
	position: relative;
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	gap: 40px;
	padding-block: clamp(40px, calc(40px + 24.5 * var(--fluid)), 64.5px);
}

.blog-card::before,
.blog-card::after {
	position: absolute;
	background: var(--color-divider);
	pointer-events: none;
}

.post-badge.blog-card__badge {
	position: relative;
	z-index: 1;
	padding: 8px 24px 10px;
	font-size: 15px;
	line-height: 16px;
}

.blog-card__text {
	display: flex;
	flex-direction: column;
	gap: 8px;
}

.blog-card__title {
	font-family: var(--font-serif);
	font-size: 30px;
	font-weight: 300;
	line-height: 1.25;
}

/* The title isn't underlined on hover; the whole card opens the article. */
.blog-card__link {
	text-decoration: none;
}

.blog-card__link::after {
	position: absolute;
	inset: 0;
	content: "";
}

.blog-card__excerpt {
	color: #717171;
	font-size: 17px;
	line-height: 24px;
}

@media (min-width: 1280px) {
	.blog-card:not(:nth-child(3n + 1))::before {
		top: 0;
		bottom: 0;
		left: calc(var(--blog-gap) / -2);
		width: 1px;
		content: "";
	}

	.blog-card:nth-child(n + 4)::after {
		top: 0;
		right: calc(var(--blog-gap) / -2);
		left: calc(var(--blog-gap) / -2);
		height: 1px;
		content: "";
	}

	.blog-card:nth-child(3n + 1)::after {
		left: 0;
	}

	.blog-card:nth-child(3n)::after,
	.blog-card:last-child::after {
		right: 0;
	}

	/* A short last row still gets a line across the whole grid. */
	.blog-card:nth-child(3n + 1):last-child::after {
		right: calc(-200% - 2 * var(--blog-gap));
	}

	.blog-card:nth-child(3n + 2):last-child::after {
		right: calc(-100% - var(--blog-gap));
	}
}

@media (min-width: 768px) and (max-width: 1279px) {
	.blog-grid {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}

	.blog-card:nth-child(2n)::before {
		top: 0;
		bottom: 0;
		left: calc(var(--blog-gap) / -2);
		width: 1px;
		content: "";
	}

	.blog-card:nth-child(n + 3)::after {
		top: 0;
		right: calc(var(--blog-gap) / -2);
		left: 0;
		height: 1px;
		content: "";
	}

	.blog-card:nth-child(2n)::after,
	.blog-card:last-child::after {
		right: 0;
	}

	.blog-card:nth-child(2n)::after {
		left: calc(var(--blog-gap) / -2);
	}

	/* A last card on its own still gets a line across the whole grid. */
	.blog-card:nth-child(2n + 1):last-child::after {
		right: calc(-100% - var(--blog-gap));
	}
}

.blog-empty {
	margin-top: 60px;
	text-align: center;
}

/* Page links: Previous, the page numbers, Next. */
.blog-pagination {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: center;
	gap: 30px;
	margin-top: clamp(50px, calc(50px + 27 * var(--fluid)), 77px);
	font-size: var(--fs-button);
	font-weight: 500;
	line-height: 26px;
	letter-spacing: -0.03em;
}

.blog-pagination a {
	text-decoration: none;
	transition: color var(--motion-hover) var(--ease-soft);
}

.blog-pagination a:hover {
	color: var(--color-accent);
}

.blog-pagination__pages {
	display: flex;
	align-items: center;
	gap: 0.75em;
}

.blog-pagination .current {
	color: var(--color-accent);
}

.blog-pagination .dots {
	margin-inline: -0.5em;
}

.blog-pagination__step.is-disabled {
	color: var(--color-border-muted);
}

@media (max-width: 767px) {
	.site-main--blog {
		padding: clamp(150px, calc(150px + 27 * var(--fluid-m)), 177px) 0 clamp(80px, calc(80px + 25 * var(--fluid-m)), 105px);
	}

	.site-main--blog::before,
	.site-main--gallery::before {
		display: none;
	}

	.blog-header {
		align-items: flex-start;
		gap: 23px;
		text-align: left;
	}

	.blog-header__title {
		font-size: var(--fs-h1);
		line-height: 1;
	}

	.filter-bar__tabs {
		display: none;
	}

	.filter-bar__menu {
		display: block;
	}

	.blog-grid {
		grid-template-columns: minmax(0, 1fr);
		margin-top: clamp(60px, calc(60px + 21 * var(--fluid-m)), 81px);
	}

	.blog-card {
		padding-block: 40px;
	}

	.blog-card:first-child {
		padding-top: 0;
	}

	.blog-card:last-child {
		padding-bottom: 0;
	}

	.blog-card + .blog-card::after {
		top: 0;
		right: 0;
		left: 0;
		height: 1px;
		content: "";
	}

	.blog-card__title {
		font-size: clamp(32px, calc(32px + 8 * var(--fluid-m)), 40px);
		line-height: 1;
	}

	.blog-card__excerpt {
		font-size: var(--fs-body);
		line-height: 1.5;
	}

	.blog-empty {
		margin-top: 40px;
		text-align: left;
	}

	.blog-pagination {
		justify-content: flex-start;
		margin-top: clamp(40px, calc(40px + 12 * var(--fluid-m)), 52px);
	}
}

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

.site-main--gallery {
	position: relative;
	isolation: isolate;
	padding: clamp(150px, calc(150px + 119 * var(--fluid)), 269px) 0 123px;
}

.gallery {
	display: flex;
	flex-direction: column;
	align-items: center;
}

.gallery-header {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 10px;
	text-align: center;
}

.gallery-header__eyebrow {
	font-size: clamp(18px, calc(18px + 2 * var(--fluid)), 20px);
	font-weight: 500;
	line-height: 1.5;
}

.gallery-header__title {
	line-height: 1.03;
}

.gallery-header__intro {
	max-width: 660px;
	font-size: var(--fs-body);
	line-height: 1.5;
}

.gallery-header .filter-bar {
	margin-top: 33px;
}

/* Cases: a masonry of two columns from tablets up (main.js places them; without
   it they sit in rows), one column on phones. */
.gallery-grid {
	--gallery-cols: 1;
	--gallery-gap: 30px;
	display: grid;
	gap: var(--gallery-gap);
	width: 100%;
	max-width: 1200px; /* 1469px on the board; narrowed in feedback */
	margin-top: clamp(40px, calc(40px + 13 * var(--fluid)), 53px);
}

@media (min-width: 768px) {
	.gallery-grid {
		--gallery-cols: 2;
		--gallery-gap: 10px;
		grid-template-columns: repeat(2, minmax(0, 1fr));
		align-items: start;
	}

	.gallery-grid.is-masonry {
		position: relative;
		display: block;
	}

	.gallery-grid.is-masonry > .gallery-case {
		position: absolute;
		top: 0;
		left: 0;
		width: calc((100% - var(--gallery-gap)) / 2);
	}
}

.gallery-case {
	display: flex;
	flex-direction: column;
	overflow: hidden;
	border: 1px solid var(--color-divider);
	border-radius: var(--radius);
	background: var(--color-white);
}

.gallery-case[hidden] {
	display: none;
}

/* Photos: the first sets the shape; with several they slide (swipe or arrows).
   Every photo covers that frame, so one cropped or sized differently from the
   first fills it (trimmed evenly from the centre) instead of leaving bands of
   background; the lightbox still shows each one whole. min-height: 0 keeps
   the frame to the first photo's shape (case.php sets its aspect-ratio):
   otherwise a taller photo in the group stretches it. */
.gallery-case__media {
	position: relative;
	min-height: 0;
	background: var(--color-subtle);
}

.gallery-case__slides {
	display: flex;
	height: 100%;
	overflow-x: auto;
	overscroll-behavior-x: contain;
	scroll-snap-type: x mandatory;
	scrollbar-width: none;
}

.gallery-case__slides::-webkit-scrollbar {
	display: none;
}

.gallery-case__slide {
	position: relative;
	flex: 0 0 100%;
	height: 100%;
	cursor: zoom-in;
	scroll-snap-align: start;
}

.gallery-case__img {
	width: 100%;
	height: 100%;
	object-fit: cover;
}

/* Before / After labels, placed for photos side by side or stacked. */
.photo-label {
	--label-inset: clamp(14px, calc(14px + 24 * var(--fluid)), 38px);
	position: absolute;
	bottom: 16px;
	padding: 10px 20px;
	border-radius: 200px;
	background: rgba(255, 255, 255, 0.46);
	-webkit-backdrop-filter: blur(15px);
	backdrop-filter: blur(15px);
	color: var(--color-subtle);
	font-size: 15px;
	font-weight: 700;
	line-height: 16px;
	text-transform: uppercase;
	pointer-events: none;
}

.photo-label--before {
	left: var(--label-inset);
}

[data-labels="side"] .photo-label--after {
	left: calc(50% + var(--label-inset));
}

[data-labels="stacked"] .photo-label--before {
	bottom: calc(50% + 16px);
}

[data-labels="stacked"] .photo-label--after {
	left: var(--label-inset);
}

[data-labels="none"] .photo-label {
	display: none;
}

.slide-arrow {
	position: absolute;
	z-index: 1;
	top: 50%;
	display: grid;
	place-items: center;
	width: 38px;
	height: 38px;
	border-radius: 50%;
	background: var(--color-strong);
	color: var(--color-white);
	transform: translateY(-50%);
	transition: background-color var(--motion-hover) var(--ease-soft);
}

.slide-arrow:hover {
	background: var(--color-black);
}

.slide-arrow--prev {
	left: clamp(16px, calc(16px + 4 * var(--fluid)), 20px);
}

.slide-arrow--next {
	right: clamp(16px, calc(16px + 4 * var(--fluid)), 20px);
}

.slide-arrow--prev .icon {
	transform: rotate(90deg);
}

.slide-arrow--next .icon {
	transform: rotate(-90deg);
}

.gallery-case__details {
	display: flex;
	flex-direction: column;
	gap: 30px;
	padding: clamp(25px, calc(25px + 15 * var(--fluid)), 40px);
}

/* Procedure tags on the left, the age on the right, each in its own column: the
   tags wrap within theirs rather than pushing the age onto a line of its own.
   On tablets and phones the age goes under the tags (see below). */
.gallery-case__meta {
	display: flex;
	align-items: flex-start;
	gap: 10px;
}

.gallery-case__tags {
	display: flex;
	flex: 0 1 auto;
	flex-wrap: wrap;
	gap: 10px;
	min-width: 0;
	margin: 0;
	padding: 0;
	list-style: none;
}

.gallery-tag {
	padding: 8px 24px 10px;
	border-radius: 200px;
	background: var(--color-black);
	color: var(--color-subtle);
	font-size: 15px;
	font-weight: 500;
	line-height: 16px;
	white-space: nowrap;
}

.gallery-tag--age {
	flex: none;
	margin-left: auto;
	background: var(--color-subtle);
	color: #717171;
}

@media (max-width: 1023px) {
	.gallery-case__meta {
		flex-direction: column;
		gap: 20px;
	}

	.gallery-tag--age {
		margin-left: 0;
	}
}

.gallery-case__text {
	font-size: clamp(17px, calc(17px + 3 * var(--fluid)), 20px);
	line-height: 1.25;
}

.gallery-empty {
	margin-top: 60px;
	text-align: center;
}

/* Pop-ups: the gallery's notice (e.g. Labiaplasty) and the lightbox. */
html:has(dialog[open]) {
	overflow: hidden;
}

.dialog-close {
	position: absolute;
	top: 14px;
	right: 14px;
	display: grid;
	place-items: center;
	width: 44px;
	height: 44px;
	border-radius: 50%;
	transition: background-color var(--motion-hover) var(--ease-soft);
}

.dialog-close:hover {
	background: rgba(0, 0, 0, 0.06);
}

.dialog-close .icon {
	width: 16px;
	height: 16px;
	transform: rotate(45deg);
}

.gallery-notice {
	width: min(560px, calc(100% - 40px));
	padding: 70px clamp(30px, calc(30px + 20 * var(--fluid)), 50px) 50px;
	border: 0;
	border-radius: var(--radius);
	background: var(--color-white);
	color: var(--color-black);
	text-align: center;
}

.gallery-notice[open] {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 30px;
}

.gallery-notice::backdrop {
	background: rgba(0, 0, 0, 0.6);
}

.lightbox {
	width: 100%;
	max-width: none;
	height: 100%;
	max-height: none;
	margin: 0;
	padding: 70px 20px;
	border: 0;
	background: transparent;
	color: var(--color-white);
}

.lightbox[open] {
	display: flex;
	align-items: center;
	justify-content: center;
}

.lightbox::backdrop {
	background: rgba(0, 0, 0, 0.92);
}

.lightbox__figure {
	position: relative;
	margin: 0;
}

.lightbox__img {
	width: auto;
	max-width: min(calc(100vw - 180px), 1600px);
	height: auto;
	max-height: calc(100vh - 140px);
	border-radius: var(--radius);
}

.lightbox .dialog-close {
	top: 20px;
	right: 20px;
	background: rgba(255, 255, 255, 0.12);
}

.lightbox .dialog-close:hover {
	background: rgba(255, 255, 255, 0.24);
}

.lightbox .slide-arrow {
	position: absolute;
}

.lightbox__prev {
	left: 20px;
}

.lightbox__next {
	right: 20px;
}

.lightbox__count {
	position: absolute;
	bottom: 24px;
	left: 50%;
	font-size: 16px;
	font-weight: 500;
	transform: translateX(-50%);
}

.lightbox[data-count="1"] .slide-arrow,
.lightbox[data-count="1"] .lightbox__count {
	display: none;
}

@media (max-width: 767px) {
	.site-main--gallery {
		padding: clamp(150px, calc(150px + 39 * var(--fluid-m)), 189px) 0 69px;
	}

	.gallery {
		align-items: stretch;
	}

	.gallery-header {
		align-items: flex-start;
		gap: 20px;
		text-align: left;
	}

	.gallery-header__eyebrow {
		line-height: 26px;
	}

	.gallery-header__title {
		font-size: var(--fs-h1);
		line-height: 1;
	}

	.gallery-header .filter-bar {
		margin-top: 0;
	}

	.gallery-grid {
		margin-top: clamp(40px, calc(40px + 19 * var(--fluid-m)), 59px);
	}

	.photo-label {
		bottom: 12px;
		font-size: 16px;
	}

	.gallery-case__details {
		padding: clamp(28px, calc(28px + 7 * var(--fluid-m)), 35px) clamp(20px, calc(20px + 10 * var(--fluid-m)), 30px);
	}

	.gallery-case__text {
		font-size: var(--fs-body);
		line-height: 1.5;
	}

	.gallery-empty {
		text-align: left;
	}

	.lightbox__img {
		max-width: 100%;
	}
}

/* Blog post ---------------------------------------------------------------- */

.site-main--post {
	--post-gap: 40px;
	--post-media-gap: 60px;
	padding: clamp(150px, calc(150px + 90 * var(--fluid)), 240px) 0 clamp(73px, calc(73px + 4 * var(--fluid)), 77px);
}

/* Article (995 wide with its call to action), a gap, then the side column:
   467 wide at 1920, easing to 340 at 1280 so laptops keep room for the article. */
.post-layout {
	display: grid;
	grid-template-columns: minmax(0, 995fr) minmax(60px, 209fr) clamp(340px, calc(340px + 127 * (100vw - 1280px) / 640), 467px);
}

.post-article {
	grid-column: 1;
	display: flex;
	flex-direction: column;
	gap: var(--post-gap);
}

.post-header,
.post-points,
.post-content {
	width: 100%;
	max-width: 893px;
}

.post-header {
	display: flex;
	flex-direction: column;
	gap: var(--post-gap);
}

.post-header__meta {
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	gap: 26px;
}

.post-badge {
	padding: 8px 24px;
	border-radius: 200px;
	background: var(--color-accent);
	color: var(--color-subtle);
	font-size: 20px;
	font-weight: 500;
	line-height: 30px;
	text-decoration: none;
	transition: background-color var(--motion-hover) var(--ease-soft);
}

.post-badge:hover {
	background: var(--color-accent-hover);
}

.post-byline {
	font-size: var(--fs-body);
	line-height: 1.5;
}

.post-byline__name {
	font-size: calc(var(--fs-body) - 2px);
	font-weight: 500;
	text-decoration: none;
}

a.post-byline__name:hover {
	text-decoration: underline;
	text-underline-offset: 0.18em;
}

.post-header__title,
.post-content h2 {
	scroll-margin-top: 30px;
}

/* Key Points: 36px from one line to the next, as on the board; the list's
   half-leading is trimmed so the box keeps the board's height. */
.post-points {
	display: flex;
	flex-direction: column;
	gap: 30px;
	padding: 45px;
	border-radius: var(--radius);
	background: var(--color-subtle);
}

.post-points__title {
	font-size: 23px;
	font-weight: 700;
	line-height: 25px;
	letter-spacing: 0.01em;
}

.post-points__list {
	display: flex;
	flex-direction: column;
	gap: 10px;
	margin: -5px 0;
	padding: 0;
	list-style: none;
	font-size: 20px;
	font-weight: 500;
	line-height: 26px;
}

/* Article body: 60px before each heading and around photos and videos. */
.post-content > * {
	margin-block: 0;
}

.post-content > * + * {
	margin-top: 0.77em;
}

.post-content > * + :where(h2, h3, h4) {
	margin-top: 60px;
}

.post-content > * + :where(figure, .wp-block-image, .wp-block-embed, .wp-block-video, .wp-block-gallery),
.post-content > :where(figure, .wp-block-image, .wp-block-embed, .wp-block-video, .wp-block-gallery) + * {
	margin-top: var(--post-media-gap);
}

.post-content > :where(h2, h3, h4) + * {
	margin-top: 20px;
}

.post-content h2,
.post-content h3,
.post-content h4 {
	font-family: var(--font-serif);
	font-weight: 300;
}

.post-content h2 {
	font-size: var(--fs-h3);
	line-height: 1;
	letter-spacing: -2px;
}

.post-content h3 {
	font-size: clamp(30px, calc(30px + 10 * var(--fluid)), 40px);
	line-height: 1.125;
	letter-spacing: -1px;
}

.post-content h4 {
	font-size: var(--fs-h5);
	line-height: 1.1;
}

.post-content :is(h2, h3, h4) em {
	color: var(--color-accent);
}

.post-content ul,
.post-content ol {
	padding-left: 1.5em;
}

.post-content img,
.post-content iframe,
.post-content video {
	border-radius: var(--radius);
}

.post-content .wp-block-embed__wrapper {
	overflow: hidden;
	border-radius: var(--radius);
}

.post-content figcaption {
	margin-top: 12px;
	font-size: 16px;
	line-height: 1.5;
	text-align: left;
}

.post-content .aligncenter {
	margin-inline: auto;
}

.post-content blockquote {
	padding-left: 30px;
	border-left: 3px solid var(--color-accent);
	font-family: var(--font-serif);
	font-size: var(--fs-h5);
	line-height: 1.3;
}

/* Take the Next Step: the textured panel of the consultation banner. */
.post-next {
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	gap: 40px;
	margin-top: 26px;
	padding: clamp(50px, calc(50px + 34 * var(--fluid)), 84px) clamp(40px, calc(40px + 30 * var(--fluid)), 70px) clamp(50px, calc(50px + 34 * var(--fluid)), 84px) clamp(40px, calc(40px + 34 * var(--fluid)), 74px);
	border-radius: var(--radius);
	background: var(--color-subtle) url("../images/texture-cta.jpg") center bottom / cover;
}

.post-next__text {
	display: flex;
	flex-direction: column;
	gap: 20px;
	max-width: 834px;
}

/* Side column: sticks beside the article. main.js moves it up a little when
   that keeps it clear of the floating button. */
.post-aside__inner {
	display: flex;
	flex-direction: column;
	gap: 50px;
}

.post-aside {
	grid-column: 3;
}

@media (min-width: 1280px) {
	.post-aside__inner {
		position: sticky;
		top: calc(var(--post-aside-top, 40px) + var(--header-stuck-h) + var(--wp-admin--admin-bar--height, 0px));
		max-height: var(--post-aside-max, none);
		overflow-y: auto;
		overscroll-behavior: contain;
		scrollbar-width: thin;
	}
}

.post-toc {
	display: flex;
	flex-direction: column;
	gap: 30px;
}

.post-toc__title,
.post-related__title {
	font-size: 23px;
	font-weight: 500;
	line-height: 25px;
	letter-spacing: 0.01em;
}

.post-toc__list,
.post-related__list {
	display: flex;
	flex-direction: column;
	margin: 0;
	padding: 0;
	list-style: none;
	font-size: 19px;
	font-weight: 500;
	line-height: 30px;
	letter-spacing: -0.5px;
}

/* A 3px line with the marker on the current section. */
.post-toc__list {
	position: relative;
	gap: 20px;
	padding: 5px 0 5px 33px;
}

.post-toc__list::before,
.post-toc__list::after {
	content: "";
	position: absolute;
	left: 0;
	width: 3px;
	border-radius: 200px;
}

.post-toc__list::before {
	top: 0;
	bottom: 0;
	background: var(--color-subtle);
}

.post-toc__list::after {
	top: var(--toc-y, 0px);
	height: var(--toc-h, 40px);
	background: var(--color-accent);
	transition: top var(--motion-hover) var(--ease-soft), height var(--motion-hover) var(--ease-soft);
}

.post-toc__item a {
	display: block;
	color: var(--color-border-muted);
	text-decoration: none;
	transition: color var(--motion-hover) var(--ease-soft);
}

.post-toc__item a:hover,
.post-toc__item.is-active a {
	color: var(--color-black);
}

.post-related {
	display: flex;
	flex-direction: column;
	gap: 25px;
	padding: 45px clamp(30px, calc(30px + 20 * var(--fluid)), 50px) 50px;
	border: 1px solid var(--color-divider);
	border-radius: var(--radius);
}

.post-related__list {
	gap: 9px;
}

.post-related__list a {
	text-decoration: none;
}

.post-related__list a:hover {
	text-decoration: underline;
	text-underline-offset: 0.18em;
}

@media (prefers-reduced-motion: no-preference) {
	html:has(.post-toc) {
		scroll-behavior: smooth;
	}
}

/* Narrower screens: one column, the side column after the article. */
@media (max-width: 1279px) {
	.post-layout {
		display: block;
		max-width: calc(995px + 2 * var(--gutter));
	}

	.post-aside {
		margin-top: 50px;
	}
}

@media (max-width: 767px) {
	.site-main--post {
		--post-gap: 36px;
		--post-media-gap: 36px;
		padding-top: clamp(150px, calc(150px + 27 * var(--fluid-m)), 177px);
	}

	.post-badge {
		font-size: 18px;
	}

	.post-byline__name {
		font-size: clamp(16px, calc(16px + 2 * var(--fluid-m)), 18px);
	}

	.post-points {
		gap: clamp(24px, calc(24px + 6 * var(--fluid-m)), 30px);
		padding: clamp(30px, calc(30px + 15 * var(--fluid-m)), 45px);
	}

	.post-points__list {
		gap: 8px;
		margin-block: -3.5px;
		font-size: 18px;
		line-height: 23px;
	}

	.post-content h2 {
		line-height: 1.2;
	}

	.post-content h3 {
		font-size: clamp(25px, calc(25px + 5 * var(--fluid-m)), 30px);
		line-height: 1;
	}

	/* Edge to edge on phones. */
	.post-next {
		gap: 40px;
		margin: 52px calc(-1 * var(--gutter)) 0;
		padding: 70px clamp(20px, calc(20px + 20 * var(--fluid-m)), 40px);
		border-radius: 0;
	}

	.post-next__text {
		gap: 10px;
	}

	.post-toc__list,
	.post-related__list {
		font-size: 18px;
		letter-spacing: 0;
	}

	.post-related {
		padding-inline: clamp(30px, calc(30px + 20 * var(--fluid-m)), 50px);
	}
}

/* Text pages (page.php: Privacy Policy, Terms of Use) ---------------------- */

.site-main--page {
	padding: clamp(150px, calc(150px + 155 * var(--fluid)), 305px) 0 103px;
}

/* The text (989 wide at 1920), a gap, then "On this page" (388, easing to 320
   at 1280). */
.page-layout {
	grid-template-columns: minmax(0, 989fr) minmax(60px, 293fr) clamp(320px, calc(320px + 68 * (100vw - 1280px) / 640), 388px);
}

.page-article {
	grid-column: 1;
	display: flex;
	flex-direction: column;
	gap: 30px;
}

/* 60px before each heading; the first sits a little closer to the introduction. */
.page-content > * {
	margin-block: 0;
}

.page-content > * + * {
	margin-top: 0.77em;
}

.page-content > * + :where(h2, h3, h4) {
	margin-top: 60px;
}

.page-content > * + h2:first-of-type {
	margin-top: 42px;
}

.page-content > :where(h2, h3, h4) + * {
	margin-top: 20px;
}

.page-content h2,
.page-content h3,
.page-content h4 {
	font-family: var(--font-serif);
	font-weight: 300;
}

.page-content h2 {
	font-size: var(--fs-h4);
	line-height: 1.125;
	letter-spacing: -1px;
	scroll-margin-top: 30px;
}

.page-content h3 {
	font-size: var(--fs-h5);
	line-height: 1.2;
}

.page-content h4 {
	font-size: var(--fs-lead);
	line-height: 1.2;
}

.page-content ul,
.page-content ol {
	padding-left: 1.5em;
}

.page-content li + li {
	margin-top: 0.4em;
}

@media (max-width: 1279px) {
	.page-aside {
		display: none;
	}
}

@media (max-width: 767px) {
	.site-main--page {
		padding: clamp(150px, calc(150px + 27 * var(--fluid-m)), 177px) 0 66px;
	}

	.page-article {
		gap: 20px;
	}

	.page-content > * + h2:first-of-type {
		margin-top: 47px;
	}

	.page-content h2 {
		font-size: clamp(25px, calc(25px + 5 * var(--fluid-m)), 30px);
		line-height: 1;
	}
}

/* Default template ------------------------------------------------------- */

.site-main--default {
	padding-top: clamp(130px, calc(130px + 70 * var(--fluid)), 200px);
	padding-bottom: var(--section-gap);
}

.entry + .entry {
	margin-top: 64px;
}

.entry__title {
	margin-bottom: 32px;
}

.entry__content {
	max-width: 900px;
}

/* Motion ------------------------------------------------------------------ */

/* Appearances. main.js marks what appears and reveals each element once, as it
   enters the screen; elements entering together follow one another by the
   stagger time. Text and cards fade up, photos fade in from a slight zoom, hero
   photos settle from that zoom, and before & after cards just fade. One motion
   per element: nothing inside an appearing element moves on its own. Without
   JavaScript, or with reduced motion preferred, nothing is hidden. */
@media (prefers-reduced-motion: no-preference) {
	/* Until main.js has marked what will appear (a <head> fallback lifts this
	   after 2s). */
	.motion-pending main,
	.motion-pending .site-end {
		opacity: 0;
	}

	[data-reveal] {
		transition:
			opacity var(--motion-reveal) var(--ease-soft) var(--reveal-delay, 0ms),
			translate var(--motion-reveal) var(--ease-soft) var(--reveal-delay, 0ms),
			scale var(--motion-image) var(--ease-soft) var(--reveal-delay, 0ms);
	}

	[data-reveal="image"],
	[data-reveal="zoom"] {
		transition-duration: var(--motion-image);
	}

	[data-reveal]:not(.is-revealed) {
		opacity: 0;
	}

	[data-reveal="up"]:not(.is-revealed) {
		translate: 0 var(--motion-travel);
	}

	[data-reveal="image"]:not(.is-revealed) {
		scale: 1.03;
	}

	[data-reveal="zoom"]:not(.is-revealed) {
		opacity: 1;
		scale: 1.03;
	}
}

/* Procedure cards (Home) stack like a deck as the page scrolls: each card pins
   below the header while the next slides up over it, a peek lower so the
   edges of the cards beneath show. A covered card settles back, narrower and
   shaded, by --stack-shrink and --stack-shade for each card that has landed on
   it. It narrows by trimming its sides rather than scaling, so its photo and
   text stay put and sharp. main.js adds .is-stacked, sets each card's place in
   the deck (--stack-index), height (--stack-h) and depth (--stack-depth, eased
   in as the next card slides up), and marks covered cards .is-covered. A card
   too tall for the screen pins once its foot is in view; cards pin on whole
   pixels so they stay crisp. Without JavaScript, or with reduced motion
   preferred, the cards simply follow one another. */
@media (prefers-reduced-motion: no-preference) {
	.procedures {
		--stack-space: clamp(0px, calc(20 * var(--fluid)), 20px);
		--stack-peek: clamp(8px, calc(8px + 8 * var(--fluid)), 16px);
		--stack-shrink: 0.04;
		--stack-shade: 0.3;
	}

	/* Phones: the cards run edge to edge, right under the header, and each
	   lands squarely on the one before (a peek would slice through its text). */
	@media (max-width: 767px) {
		.procedures {
			--stack-space: 0px;
			--stack-peek: 0px;
		}
	}

	.procedures.is-stacked > .procedure-card {
		--stack-top: min(
			calc(var(--wp-admin--admin-bar--height, 0px) + var(--header-stuck-h) + var(--stack-space) + var(--stack-index, 0) * var(--stack-peek)),
			calc(100svh - var(--stack-h, 0px) - var(--stack-space))
		);
		position: sticky;
		top: var(--stack-top);
	}

	@supports (top: round(1.5px, 1px)) {
		.procedures.is-stacked > .procedure-card {
			top: round(var(--stack-top), 1px);
		}
	}

	/* Covered cards only, so the card on top keeps its shadow. */
	.procedures.is-stacked > .procedure-card.is-covered {
		clip-path: inset(0 calc(var(--stack-depth, 0) * var(--stack-shrink) * 50%) round var(--radius-card));
	}

	.procedures.is-stacked > .procedure-card::after {
		position: absolute;
		inset: 0;
		z-index: 1;
		background: var(--color-black);
		opacity: calc(var(--stack-depth, 0) * var(--stack-shade));
		pointer-events: none;
		content: "";
	}
}

/* Printing shows everything, whether or not it has scrolled into view, with the
   header printed once at the top. */
@media print {
	[data-reveal] {
		opacity: 1 !important;
		translate: none !important;
		scale: none !important;
	}

	.site-header {
		position: absolute;
	}
}

/* Before & after photos lift a touch under the pointer. */
@media (hover: hover) {
	.ba-card,
	.gallery-case {
		transition: box-shadow var(--motion-hover) var(--ease-soft);
	}

	.ba-card__img,
	.gallery-case__img {
		transition: scale var(--motion-hover) var(--ease-soft);
	}

	.ba-card:hover,
	.gallery-case:has(.gallery-case__slide:hover) {
		box-shadow: 0 12px 34px rgba(0, 0, 0, 0.08);
	}

	.ba-card:hover .ba-card__img,
	.gallery-case__slide:hover .gallery-case__img {
		scale: 1.02;
	}
}

/* Logo marquees (phones): the logo passing the middle grows gently (main.js
   times each logo from its place in the row). In the hero, rows of four
   logos or fewer stay still, two to a row (spread rows always run, see
   "About"). */
@media (max-width: 767px) {
	.logo-marquee__item {
		animation: marquee-focus var(--marquee-duration, 28s) linear infinite;
		animation-delay: var(--focus-delay, 0s);
	}

	.logo-marquee--static:not(.logo-marquee--spread) {
		margin-inline: 0;
	}

	.logo-marquee--static:not(.logo-marquee--spread) .logo-marquee__list {
		display: grid;
		flex: 1 1 auto;
		grid-template-columns: repeat(2, minmax(0, 1fr));
		align-items: center;
		justify-items: center;
		gap: 28px 24px;
		padding-right: 0;
		animation: none;
	}

	.logo-marquee--static:not(.logo-marquee--spread) .logo-marquee__item img {
		max-width: 100%;
		height: auto;
		max-height: calc(var(--logo-h) * 0.7);
	}

	.logo-marquee--static:not(.logo-marquee--spread) .logo-marquee__list[aria-hidden="true"] {
		display: none;
	}

	.logo-marquee--static:not(.logo-marquee--spread) .logo-marquee__item {
		animation: none;
	}
}

@keyframes marquee-focus {
	0% {
		scale: 1.12;
		animation-timing-function: ease-in-out;
	}

	9% {
		scale: 1;
	}

	91% {
		scale: 1;
		animation-timing-function: ease-in-out;
	}

	100% {
		scale: 1.12;
	}
}

@media (prefers-reduced-motion: reduce) {
	/* Still logo rows wrap instead of running off the screen. */
	.logo-marquee__list {
		flex-wrap: wrap !important;
		justify-content: center !important;
	}

	.logo-marquee__list[aria-hidden="true"] {
		display: none !important;
	}

	*,
	*::before,
	*::after {
		animation: none !important;
		transition: none !important;
	}
}

/* On phones still logo rows sit two to a row, as a hero row of four or fewer
   does, rather than in one line running off the screen. */
@media (prefers-reduced-motion: reduce) and (max-width: 767px) {
	.logo-marquee {
		margin-inline: 0;
	}

	.logo-marquee .logo-marquee__list {
		display: grid;
		flex: 1 1 auto;
		grid-template-columns: repeat(2, minmax(0, 1fr));
		align-items: center;
		justify-items: center;
		gap: 28px 24px;
		padding-right: 0;
	}

	.logo-marquee .logo-marquee__item img {
		max-width: 100%;
		height: auto;
		max-height: calc(var(--logo-h) * 0.7);
	}
}
