:root {
	color-scheme: light;
	font-family: Helvetica, Arial, sans-serif;
	background: #f2f1f1;
	color: #4e4852;
}

* {
	box-sizing: border-box;
}

body {
	margin: 0;
	min-width: 320px;
	background: linear-gradient(180deg, #f2f1f1 0%, #e8e7e7 100%);
	color: #4e4852;
	line-height: 1.6;
}

a {
	color: #174d86;
}

a:focus-visible {
	outline: 3px solid #80cfff;
	outline-offset: 4px;
}

.clinic-site-header {
	position: sticky;
	top: 0;
	z-index: 100;
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 1.5rem;
	padding: 1rem clamp(1rem, 4vw, 3rem);
	background: radial-gradient(ellipse at top, #1a2f59 0, #030b1e 65%);
	color: #fff;
	border-bottom: 1px solid rgb(255 255 255 / 18%);
}

.clinic-site-header a {
	color: #fff;
}

.clinic-site-header img {
	display: block;
	width: min(11rem, 38vw);
	height: auto;
}

.clinic-site-header a:last-child {
	font-weight: 700;
}

.clinic-page {
	width: min(72rem, calc(100% - 2rem));
	margin: 0 auto;
	padding: clamp(2rem, 6vw, 5rem) 0;
}

.clinic-page h1 {
	margin: 0;
	font-size: clamp(2rem, 5vw, 3.5rem);
	line-height: 1.15;
}

.clinic-subtitle {
	margin: 0.75rem 0 2rem;
	color: #4e4852;
	font-size: clamp(1.1rem, 2vw, 1.35rem);
}

.clinic-contact {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 1rem 2rem;
	margin-bottom: 3rem;
	padding: clamp(1.25rem, 3vw, 2rem);
	border: 1px solid rgb(78 72 82 / 20%);
	border-radius: 0.75rem;
	background: rgb(255 255 255 / 45%);
}

.clinic-contact address {
	font-style: normal;
}

.clinic-actions {
	display: flex;
	flex-wrap: wrap;
	gap: 0.75rem;
	margin-left: auto;
}

.clinic-actions a {
	display: inline-block;
	padding: 0.65rem 1rem;
	border: 1px solid #174d86;
	border-radius: 0.35rem;
	text-decoration: none;
	font-weight: 700;
}

.clinic-actions a:hover {
	background: #0065d1;
	color: #fff;
}

.clinic-page h2 {
	margin: 0 0 1rem;
	font-size: clamp(1.5rem, 3vw, 2rem);
}

.clinic-gallery {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 1rem;
}

.clinic-gallery figure {
	margin: 0;
	overflow: hidden;
	border-radius: 0.5rem;
	background: rgb(255 255 255 / 45%);
}

.clinic-gallery-trigger {
	display: block;
	width: 100%;
	padding: 0;
	border: 0;
	background: transparent;
	cursor: zoom-in;
}

.clinic-gallery-trigger:focus-visible {
	position: relative;
	z-index: 1;
	outline: 3px solid #174d86;
	outline-offset: -3px;
}

.clinic-gallery-trigger img {
	transition: transform 180ms ease;
}

.clinic-gallery-trigger:hover img {
	transform: scale(1.025);
}

.clinic-gallery img {
	display: block;
	width: 100%;
	aspect-ratio: 4 / 3;
	object-fit: cover;
}

.clinic-gallery figcaption {
	padding: 0.75rem 1rem;
	color: #4e4852;
}

.clinic-map {
	width: 100%;
	min-height: 24rem;
	margin-top: 1.5rem;
	border: 0;
	border-radius: 0.5rem;
}

.clinic-back {
	display: inline-block;
	margin-top: 2rem;
}

.clinic-lightbox {
	width: min(96vw, 76rem);
	max-width: none;
	max-height: 96dvh;
	padding: 1rem;
	border: 1px solid rgb(255 255 255 / 20%);
	border-radius: 0.75rem;
	background: #10131a;
	color: #fff;
}

.clinic-lightbox::backdrop {
	background: rgb(0 0 0 / 88%);
}

.clinic-lightbox-layout {
	display: grid;
	grid-template-columns: auto minmax(0, 1fr) auto;
	grid-template-rows: auto minmax(0, 1fr) auto;
	align-items: center;
	gap: 0.75rem;
	max-height: calc(96dvh - 2rem);
}

.clinic-lightbox-close {
	grid-column: 3;
	justify-self: end;
}

.clinic-lightbox-image-wrap {
	grid-column: 1 / -1;
	grid-row: 2;
	display: grid;
	min-height: 0;
	place-items: center;
	position: relative;
	touch-action: pan-y;
}

.clinic-lightbox-image {
	display: block;
	width: auto;
	max-width: 100%;
	max-height: calc(96dvh - 9rem);
	object-fit: contain;
	transition: opacity 180ms ease-out;
}

.clinic-lightbox-image-next {
	position: absolute;
	top: 50%;
	left: 50%;
	opacity: 0;
	transform: translate(-50%, -50%);
	pointer-events: none;
}

.clinic-lightbox-image-next.is-visible {
	opacity: 1;
}

.clinic-lightbox-image.is-fading-out {
	opacity: 0;
}

.clinic-lightbox-caption {
	grid-column: 1 / -1;
	grid-row: 3;
	margin: 0;
	text-align: center;
}

.clinic-lightbox-count {
	display: block;
	color: #d3d7df;
	font-size: 0.9rem;
}

.clinic-lightbox button {
	display: inline-grid;
	min-width: 2.75rem;
	min-height: 2.75rem;
	place-items: center;
	padding: 0.5rem;
	border: 1px solid rgb(255 255 255 / 35%);
	border-radius: 0.4rem;
	background: rgb(255 255 255 / 10%);
	color: #fff;
	font: inherit;
	font-size: 1.25rem;
	cursor: pointer;
}

.clinic-lightbox button:hover {
	background: rgb(255 255 255 / 22%);
}

.clinic-lightbox button:focus-visible {
	outline: 3px solid #80cfff;
	outline-offset: 3px;
}

.clinic-lightbox button:disabled {
	opacity: 0.45;
	cursor: not-allowed;
}

.clinic-lightbox-previous {
	grid-column: 1;
	grid-row: 2;
	z-index: 1;
}

.clinic-lightbox-next {
	grid-column: 3;
	grid-row: 2;
	z-index: 1;
}

@media (max-width: 600px) {
	.clinic-gallery {
		grid-template-columns: 1fr;
	}

	.clinic-actions {
		margin-left: 0;
	}

	.clinic-lightbox {
		width: 100%;
		max-height: 100dvh;
		padding: 0.5rem;
		border-radius: 0;
	}

	.clinic-lightbox-layout {
		max-height: calc(100dvh - 1rem);
		gap: 0.5rem;
	}

	.clinic-lightbox-image {
		max-height: calc(100dvh - 8rem);
	}
}

@media (prefers-reduced-motion: reduce) {
	.clinic-lightbox-image-next {
		transition: none;
	}
}

@media (prefers-reduced-motion: reduce) {
	.clinic-gallery-trigger img {
		transition: none;
	}
}
