:root {
	--ink: #17242f;
	--muted: #61717f;
	--line: #e6edf1;
	--surface: #ffffff;
	--box: #f1f8f6;
	--box-strong: #e6f2ef;
	--soft: #eef6f3;
	--brand: #0f766e;
	--brand-dark: #0b4f4a;
	--accent: #b46b45;
}

html {
	scroll-behavior: smooth;
}

body {
	color: var(--ink);
	font-family: "DM Sans", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
	background: #fbfcfc;
}

.reveal {
	opacity: 0;
	transform: translateY(26px);
	transition: opacity .7s ease, transform .7s ease;
	transition-delay: var(--reveal-delay, 0ms);
	will-change: opacity, transform;
}

.reveal.is-visible {
	opacity: 1;
	transform: translateY(0);
}

.navbar {
	min-height: 72px;
}

.navbar-brand {
	color: var(--brand-dark);
	font-size: 1.35rem;
	font-weight: 700;
	letter-spacing: 0;
}

.nav-link {
	color: var(--ink);
	font-weight: 600;
	position: relative;
}

.nav-link:hover,
.nav-link.active {
	color: var(--brand);
}

.navbar-nav .nav-link {
	border-radius: 6px;
	padding-left: .75rem;
	padding-right: .75rem;
}

.navbar-nav .nav-item + .nav-item {
	align-items: center;
	display: flex;
}

.navbar-nav .nav-item + .nav-item::before {
	color: var(--line);
	content: "|";
	font-weight: 700;
	padding: 0 .2rem;
}

.navbar-nav .nav-link.active {
	background: #e8f4f1;
	box-shadow: none;
}

.navbar-nav .nav-link.active::after {
	background: var(--brand);
	bottom: -16px;
	content: "";
	height: 3px;
	left: 0;
	position: absolute;
	right: 0;
}

.hero {
	position: relative;
	min-height: 82vh;
	margin-top: 72px;
	overflow: hidden;
}

.hero-image {
	width: 100%;
	height: 82vh;
	min-height: 520px;
	object-fit: cover;
	display: block;
	filter: brightness(1.08) contrast(1.06) saturate(1.18) sepia(.04);
}

.hero-overlay {
	position: absolute;
	inset: 0;
	display: flex;
	align-items: flex-end;
	padding: 0 0 72px;
	background:
		linear-gradient(90deg, rgba(10, 28, 34, .48), rgba(10, 28, 34, .16) 58%, rgba(10, 28, 34, 0)),
		linear-gradient(0deg, rgba(12, 74, 69, .22), rgba(180, 107, 69, .10));
	color: #fff;
}

.hero-copy {
	max-width: 680px;
}

.hero h1 {
	font-size: clamp(3rem, 7vw, 6.8rem);
	font-weight: 800;
	line-height: .95;
	margin: 0 0 18px;
}

.hero p {
	font-size: 1.25rem;
	margin-bottom: 28px;
}

.eyebrow {
	color: var(--accent);
	font-size: .82rem;
	font-weight: 800;
	letter-spacing: .08em;
	margin-bottom: 10px;
	text-transform: uppercase;
}

.hero .eyebrow {
	color: #f4c7ac;
}

.btn {
	border-radius: 6px;
	font-weight: 700;
	padding: .78rem 1.05rem;
}

.btn-primary {
	background: var(--brand);
	border-color: var(--brand);
}

.btn-primary:hover {
	background: var(--brand-dark);
	border-color: var(--brand-dark);
}

.btn-outline-primary {
	color: var(--brand);
	border-color: var(--brand);
}

.btn-outline-primary:hover {
	background: var(--brand);
	border-color: var(--brand);
}

.section {
	padding: 88px 0;
	scroll-margin-top: 86px;
}

.section-muted {
	background: var(--soft);
	border-bottom: 1px solid var(--line);
	border-top: 1px solid var(--line);
}

.section-heading {
	max-width: 720px;
	margin-bottom: 36px;
}

.section-heading h2 {
	font-size: clamp(2rem, 4vw, 3.4rem);
	font-weight: 800;
	letter-spacing: 0;
	line-height: 1.05;
	margin: 0;
}

.clinic-card,
.contact-panel,
.weekend-panel,
.news-card {
	background: var(--box);
	border: 1px solid var(--line);
	border-radius: 8px;
	box-shadow: 0 16px 34px rgba(19, 45, 54, .06);
}

.clinic-card {
	position: relative;
	padding: 30px;
}

.clinic-header {
	align-items: flex-start;
	display: flex;
	gap: 18px;
	justify-content: space-between;
	margin-bottom: 22px;
}

.clinic-header h3,
.news-card h3,
.weekend-title h3 {
	font-size: 1.45rem;
	font-weight: 800;
	margin: 0;
}

.phone-link,
.contact-panel a,
.emergency-card a,
.weekend-location a {
	color: var(--brand-dark);
	font-weight: 800;
	text-decoration: none;
}

.staff-list {
	display: grid;
	gap: 12px;
	margin-bottom: 26px;
}

.staff-list div,
.hours-row,
.contact-panel > div {
	border-top: 1px solid var(--line);
	display: flex;
	gap: 16px;
	justify-content: space-between;
	padding-top: 12px;
}

dt,
.contact-panel span,
.weekend-location span {
	color: var(--muted);
	font-size: .82rem;
	font-weight: 800;
	text-transform: uppercase;
}

dd {
	margin: 0;
	text-align: right;
}

.clinic-card h4 {
	font-size: 1rem;
	font-weight: 800;
	margin: 26px 0 12px;
}

.hours-list {
	display: grid;
	gap: 8px;
}

.hours-row {
	background: rgba(255, 255, 255, .62);
	border: 1px solid var(--line);
	border-radius: 6px;
	padding: 10px 12px;
}

.insurance ul {
	display: grid;
	gap: 8px;
	margin: 0;
	padding-left: 1.1rem;
}

.insurance-item {
	padding-right: 86px;
	position: relative;
}

.insurance-delete-form {
	margin: 0;
	position: absolute;
	right: 0;
	top: -4px;
}

.insurance-delete-form button,
.insurance-add-form button {
	border: 1px solid rgba(15, 118, 110, .32);
	border-radius: 6px;
	font-size: .78rem;
	font-weight: 800;
	padding: 6px 8px;
}

.insurance-delete-form button {
	background: #fff1f0;
	border-color: #f3b8b3;
	color: #9f2f24;
}

.insurance-add-form {
	display: grid;
	gap: 8px;
	grid-template-columns: minmax(0, 1fr) auto;
	margin-top: 12px;
}

.insurance-add-form input {
	border: 1px solid var(--line);
	border-radius: 6px;
	font: inherit;
	padding: 8px 10px;
	width: 100%;
}

.insurance-add-form button {
	background: #e8f4f1;
	color: var(--brand-dark);
}

.news-grid {
	display: grid;
	gap: 18px;
	grid-template-columns: repeat(3, minmax(0, 1fr));
}

.news-card {
	display: flex;
	flex-direction: column;
	min-height: 260px;
	padding: 28px;
	position: relative;
}

.news-card span {
	color: var(--accent);
	font-size: .78rem;
	font-weight: 800;
	margin-bottom: 18px;
	text-transform: uppercase;
}

.news-card p {
	color: var(--muted);
	margin: 12px 0 22px;
}

.news-link {
	color: var(--brand-dark);
	font-weight: 800;
	margin-top: auto;
	text-decoration: none;
}

.news-link:hover {
	color: var(--brand);
}

.contact-panel {
	display: grid;
	gap: 18px;
	padding: 30px;
}

.contact-panel strong {
	text-align: right;
}

.emergency-section {
	background: #f8fbfb;
}

.emergency-grid {
	display: grid;
	gap: 16px;
	grid-template-columns: repeat(5, minmax(0, 1fr));
}

.emergency-card {
	background: var(--box);
	border: 1px solid var(--line);
	border-radius: 8px;
	display: flex;
	flex-direction: column;
	min-height: 230px;
	padding: 22px;
	box-shadow: 0 14px 30px rgba(19, 45, 54, .055);
}

.emergency-card .day {
	color: var(--accent);
	font-weight: 800;
}

.emergency-card .time {
	font-size: .9rem;
	font-weight: 800;
	margin: 8px 0 20px;
}

.emergency-card h3 {
	font-size: 1.08rem;
	font-weight: 800;
	margin: 0 0 10px;
}

.emergency-card p {
	color: var(--muted);
	margin-bottom: 16px;
}

.emergency-card a {
	margin-top: auto;
}

.weekend-panel {
	margin-top: 30px;
	padding: 30px;
}

.weekend-title {
	align-items: center;
	border-bottom: 1px solid var(--line);
	display: flex;
	justify-content: space-between;
	margin-bottom: 22px;
	padding-bottom: 18px;
}

.weekend-title strong {
	color: var(--brand-dark);
	font-size: 1.4rem;
}

.weekend-location {
	background: var(--box-strong);
	border: 1px solid var(--line);
	border-radius: 8px;
	height: 100%;
	padding: 20px;
}

.weekend-location h4 {
	font-size: 1.05rem;
	font-weight: 800;
	margin: 8px 0;
	text-transform: uppercase;
}

.weekend-location p {
	color: var(--muted);
	margin-bottom: 8px;
	text-transform: uppercase;
}

.gallery-grid {
	display: grid;
	gap: 14px;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	margin-top: 34px;
}

.gallery-item-wrap {
	position: relative;
}

.is-editing .gallery-item-wrap {
	cursor: grab;
}

.is-editing .gallery-item-wrap.is-dragging {
	cursor: grabbing;
	opacity: .55;
	transform: scale(.98);
}

.gallery-item {
	aspect-ratio: 4 / 3;
	background: #dfe8ec;
	border-radius: 8px;
	display: block;
	overflow: hidden;
}

.gallery-item img {
	height: 100%;
	object-fit: cover;
	transition: transform .25s ease;
	width: 100%;
}

.gallery-item:hover img {
	transform: scale(1.04);
}

.site-footer {
	background: var(--brand-dark);
	color: #fff;
	padding: 26px 0;
}

.admin-footer-link {
	background: transparent;
	border: 0;
	color: #fff;
	font: inherit;
	font-weight: 800;
	padding: 0;
	text-decoration: underline;
	text-underline-offset: 3px;
}

.footer-separator {
	opacity: .62;
	padding: 0 8px 0 10px;
}

.admin-toolbar {
	align-items: center;
	background: #102f2d;
	border-top: 1px solid rgba(255, 255, 255, .18);
	bottom: 0;
	color: #fff;
	display: flex;
	gap: 14px;
	justify-content: center;
	left: 0;
	padding: 10px 16px;
	position: fixed;
	right: 0;
	z-index: 1050;
}

.admin-toolbar form {
	margin: 0;
}

.admin-toolbar button,
.inline-admin-button,
.inline-delete-form button {
	border: 1px solid rgba(15, 118, 110, .32);
	border-radius: 6px;
	font-weight: 800;
	line-height: 1;
	padding: 8px 10px;
}

.admin-toolbar button {
	background: #fff;
	color: var(--brand-dark);
}

.admin-toolbar-error {
	color: #ffd7d2;
}

.inline-admin-button {
	background: #e8f4f1;
	color: var(--brand-dark);
	margin-bottom: 14px;
}

.inline-admin-button-light {
	background: rgba(255, 255, 255, .92);
	color: var(--brand-dark);
}

[data-inline-edit] {
	border-radius: 5px;
	cursor: text;
	outline: 0;
	transition: background-color .16s ease, box-shadow .16s ease;
}

.is-editing [data-inline-edit]:hover,
.is-editing [data-inline-edit]:focus {
	background: rgba(255, 255, 255, .68);
	box-shadow: 0 0 0 2px rgba(15, 118, 110, .28);
}

.is-editing .section [data-inline-edit]:hover,
.is-editing .section [data-inline-edit]:focus,
.is-editing .navbar [data-inline-edit]:hover,
.is-editing .navbar [data-inline-edit]:focus {
	background: #e8f4f1;
}

.is-editing [data-inline-edit].inline-saving {
	box-shadow: 0 0 0 2px #f3c77b;
}

.is-editing [data-inline-edit].inline-saved {
	box-shadow: 0 0 0 2px #58b889;
}

.is-editing [data-inline-edit].inline-error {
	box-shadow: 0 0 0 2px #d65b4f;
}

.inline-delete-form {
	margin: 0;
	position: absolute;
	right: 12px;
	top: 12px;
	z-index: 2;
}

.inline-delete-form button {
	background: #fff1f0;
	border-color: #f3b8b3;
	color: #9f2f24;
}

.gallery-delete-form {
	right: 10px;
	top: 10px;
}

.gallery-upload-form {
	align-items: center;
	background: #fff;
	border: 0;
	border-radius: 8px;
	display: grid;
	gap: 12px;
	grid-template-columns: 1.4fr 1fr .5fr auto;
	margin-top: 20px;
	padding: 16px;
}

.gallery-upload-form input {
	border: 1px solid var(--line);
	border-radius: 6px;
	font: inherit;
	padding: 10px 12px;
	width: 100%;
}

.admin-edit-modal h2,
.admin-edit-modal h3 {
	font-weight: 800;
}

.admin-edit-modal h3 {
	font-size: 1.05rem;
	margin: 18px 0 4px;
}

.admin-panel {
	background: #f4f8f7;
	padding: 64px 0;
}

.admin-panel-heading {
	align-items: flex-start;
	display: flex;
	gap: 24px;
	justify-content: space-between;
	margin-bottom: 26px;
}

.admin-panel-heading h2,
.admin-card h3,
.admin-login-modal h2 {
	font-size: 1.4rem;
	font-weight: 800;
	margin: 0;
}

.admin-card {
	background: #fff;
	border: 1px solid var(--line);
	border-radius: 8px;
	box-shadow: 0 18px 44px rgba(19, 45, 54, .08);
	margin-top: 18px;
	padding: 24px;
}

.admin-card form {
	margin-top: 18px;
}

.admin-grid {
	display: grid;
	gap: 14px;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	margin-bottom: 18px;
}

.admin-card label,
.admin-login-modal label {
	color: var(--muted);
	display: grid;
	font-size: .82rem;
	font-weight: 800;
	gap: 6px;
	text-transform: uppercase;
}

.admin-card input,
.admin-card textarea,
.admin-login-modal input {
	border: 1px solid var(--line);
	border-radius: 6px;
	color: var(--ink);
	font: inherit;
	font-weight: 500;
	padding: 10px 12px;
	text-transform: none;
	width: 100%;
}

.admin-row,
.admin-add-form {
	border-top: 1px solid var(--line);
	display: grid;
	gap: 10px;
	grid-template-columns: repeat(6, minmax(0, 1fr));
	padding: 14px 0;
}

.admin-row textarea,
.admin-add-form textarea {
	grid-column: span 2;
}

.admin-row-small {
	grid-template-columns: repeat(3, minmax(0, 1fr));
	margin-left: 24px;
}

.admin-add-form {
	align-items: start;
	background: #f7faf9;
	border: 0;
	border-radius: 8px;
	margin-top: 20px;
	padding: 16px;
}

.admin-add-form .btn {
	white-space: nowrap;
}

.admin-delete-list {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
	margin-top: 16px;
}

.admin-delete-list form {
	margin: 0;
}

.admin-delete-list button {
	background: #fff1f0;
	border: 1px solid #f3b8b3;
	border-radius: 6px;
	color: #9f2f24;
	font-weight: 800;
	padding: 8px 10px;
}

.admin-login-modal label + label {
	margin-top: 14px;
}

#galleryModal .modal-content {
	background: transparent;
	border: 0;
}

#galleryModal .btn-close {
	background-color: #fff;
	border-radius: 6px;
	margin: 0 0 10px auto;
	opacity: 1;
}

#galleryModalImage {
	background: #fff;
	border-radius: 8px;
	max-height: 82vh;
	object-fit: contain;
	width: 100%;
}

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

@media (max-width: 991px) {
	.hero,
	.hero-image {
		min-height: 620px;
	}

	.navbar-nav .nav-link.active::after {
		bottom: 4px;
	}

	.navbar-nav .nav-item + .nav-item {
		display: block;
	}

	.navbar-nav .nav-item + .nav-item::before {
		content: none;
	}

	.hero-overlay {
		background:
			linear-gradient(0deg, rgba(10, 28, 34, .56), rgba(10, 28, 34, .10)),
			linear-gradient(90deg, rgba(12, 74, 69, .18), rgba(180, 107, 69, .10));
		padding-bottom: 48px;
	}

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

	.gallery-upload-form {
		grid-template-columns: 1fr;
	}

	.admin-panel-heading {
		flex-direction: column;
	}

	.admin-grid,
	.admin-row,
	.admin-row-small,
	.admin-add-form {
		grid-template-columns: 1fr;
		margin-left: 0;
	}

	.admin-row textarea,
	.admin-add-form textarea {
		grid-column: auto;
	}
}

@media (max-width: 767px) {
	.section {
		padding: 64px 0;
	}

	.hero h1 {
		font-size: 3.1rem;
	}

	.clinic-card,
	.contact-panel,
	.weekend-panel,
	.news-card {
		padding: 22px;
	}

	.clinic-header,
	.staff-list div,
	.contact-panel > div,
	.weekend-title {
		align-items: flex-start;
		flex-direction: column;
	}

	dd,
	.contact-panel strong {
		text-align: left;
	}

	.insurance-add-form {
		grid-template-columns: 1fr;
	}

	.emergency-grid,
	.gallery-grid {
		grid-template-columns: 1fr;
	}
}

@media (prefers-reduced-motion: reduce) {
	.reveal {
		opacity: 1;
		transform: none;
		transition: none;
	}
}
