* {
    box-sizing: border-box;
}

html {
	--main-background-color: #e8e7f0;
	--main-text-color: #252022;
	--secondary-text-color: #a7abad;
	--highlight-color: #758088;
	--content-max-width: 48rem;
	--section-padding: 2rem 5vw;
	/* Subtle bottom-of-section darkening; next section reads lighter at the top */
	--section-shade: linear-gradient(
		to bottom,
		rgba(0, 0, 0, 0) 0%,
		rgba(64, 48, 48, 0.10) 100%
	);
	background-color: var(--main-background-color);
	color: var(--main-text-color);
	text-size-adjust: none;
	-webkit-text-size-adjust: none;
	font-size: clamp(15px, 2vw, 20px);
    font-family: "Open Sans", system-ui, sans-serif;
    line-height: 1.5;
	font-weight: 375;
	letter-spacing: 0.1px;
}

body {
    margin: 0;
    padding: 0;
    min-height: 100vh;
}

h1, h2, h3, h4, h5, h6 {
	margin-block: 0;
	padding-block: 0;
	font-family: "Cormorant", Georgia, "Times New Roman", serif;
	font-weight: 500;
	line-height: 1.25;
	letter-spacing: 1%;	
	text-align: center;
}

h1 {
	font-size: 3rem;
}

.hero h1 {
	font-size: 4rem;
	font-weight: 600;
}

h2 {
	font-size: 2.4rem;
	color: var(--highlight-color);
}

h3 {
	font-size: 2rem;
}

h4 {
	font-size: 1.5rem;
	font-weight: 600;
}

h5 {
	font-size: 1.3rem;
	color: var(--highlight-color);
	font-style: italic;
}

h6 {
	font-size: 1.2rem;
	font-style: italic;
}

a {
	color: inherit;
	text-decoration: underline;
}

ul li {
	margin-block: 0.25em;
}

/* Full-bleed chrome (background shade) like main > section */
header,
main,
footer {
	width: 100%;
	max-width: none;
	margin: 0;
	padding: 0;
	box-sizing: border-box;
}

main > * {
	margin: 0 auto;
	padding: 1rem 5vw;
}

header {
	text-align: center;
	background-image: var(--section-shade);
	background-repeat: no-repeat;
	padding: var(--section-padding);
}

#site-logo {
	display: block;
	width: 50vw;
	min-width: 1in;
	max-width: 3in;
	margin-inline: auto;
}

#site-logo img {
	display: inline-block;
	width: 100%;
	height: auto;
}

nav {
	display: flex;
	flex-wrap: nowrap;
	justify-content: center;
	gap: 0.75rem 1.25rem;
	font-family: Cormorant, sans-serif;
	font-weight: 400;
	font-size: 1.6rem;
}

nav > a {
	text-decoration: none;
}

nav > a:hover {
	text-decoration: underline;
}

footer {
	padding: var(--section-padding);
	text-align: center;
	color: var(--main-text-color);
	font-size: 0.9rem;
	font-weight: 300;
	background-image: var(--section-shade);
	background-repeat: no-repeat;
}

/* Vertical rhythm between top-level sections in main (full-bleed like menu) */
main > section {
	margin: 0;
	padding: var(--section-padding);
	width: 100%;
	max-width: none;
	margin-inline: 0;
	box-sizing: border-box;
	background-image: var(--section-shade);
	background-repeat: no-repeat;
}

main > section > * {
	max-width: min(calc(var(--content-max-width) - 2rem), calc(100vw - 4rem));
	margin-inline: auto;
}

/* Headers with cool lines */
section:not(.hero) > h1:first-child,
section:not(.hero) > h2:first-child {
	display: grid;
	grid-template-columns: minmax(1ch,1fr) auto minmax(1ch,1fr);
	align-items: center;
	gap: 0 1rem;
	width: 100%;
	margin-block: 0 2rem;
	text-align: center;
}

section:not(.hero) > h1:first-child::before,
section:not(.hero) > h1:first-child::after,
section:not(.hero) > h2:first-child::before,
section:not(.hero) > h2:first-child::after {
	content: "";
	height: 0;
	border-top: 1px solid var(--highlight-color);
}

/* Box-list layout for semantic <menu> (front page), no classes needed */
main > section > menu {
	display: grid;
	--min-box-width: 18em;
	grid-template-columns: repeat(auto-fit, minmax(min(var(--min-box-width), 100%), 1fr));
	gap: 1rem 1.25rem;
	align-items: stretch;

	/* Wide grid like the services cards */
	width: 100%;
	max-width: none;
	margin: 2rem auto 1rem;
	padding-inline: 0;
	padding-block: 0;
	box-sizing: border-box;

	list-style: none;
}

/* This keeps it two-by-two */
menu.four-way {
	max-width: 54em;
}

section > menu > li {
	position: relative;
	--menu-item-padding: 1rem 1.5rem;
	padding: var(--menu-item-padding);
	border: 1px solid rgba(17, 24, 39, 0.18);
	border-radius: 4px;
	box-shadow:
		0 1px 0 rgba(255, 255, 255, 0.45) inset,
		0 2px 4px rgba(17, 24, 39, 0.08),
		0 8px 20px rgba(17, 24, 39, 0.12);
	background: var(--main-background-color);
}

section > menu > li > *:first-child {
	margin-top: 0;
}

section > menu > li > *:last-child {
	margin-bottom: 0;
}

section > menu > li > figure {
	margin: -1rem -1rem 1rem -1rem !important;
	width: calc(100% + 2 * var(--menu-item-padding)) !important;
	max-width: none !important;
}


div.pricing {
	margin-top: 1rem;
	text-align: center;
	color: var(--highlight-color);
}


/*
 * Hero: photo + min-height (inherits full-bleed section from main > section)
 * Set the image in CSS: background-image on .hero
 */
.hero {
	position: relative;
	padding-block: 4rem;
	min-height: min(50vh, 26rem);
	background-image: url("/images/hero.jpg");
	background-size: cover;
	background-position: center 85%;
	background-repeat: no-repeat;
	text-align: center;
}

.hero * {
	position: relative;
	z-index: 2;
	text-shadow: 0 2px 6px rgba(255, 255, 255, 0.45);
	max-width: 35rem;
	font-weight: 500;
}

figure {
	position: relative;
}

figure:not(.placeholder)::after {
	content: "";
	position: absolute;
	inset: 0;
	z-index: 1;
	pointer-events: none;
	border-radius: inherit;
	background: rgba(255, 255, 255, 0.333);
	mix-blend-mode: saturation;
}

/*
 * Image placeholder: dashed frame + X (replace with <img> later)
 * <figure class="placeholder" aria-hidden="true"></figure>
 */
section > menu > li > figure {
	position: relative;
	display: block;
	margin: 0;
	width: 100%;
	aspect-ratio: 4 / 3;
	overflow: hidden;
}

section > menu > li > figure > img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	object-position: center;
}

figure.placeholder {
	border: 1px dashed rgba(44, 47, 49, 0.22);
	border-radius: 6px;
	background: rgba(255, 255, 255, 0.35);
	overflow: hidden;
}

figure.placeholder::before,
figure.placeholder::after {
	content: "";
	position: absolute;
	left: 50%;
	top: 50%;
	width: 141.42%;
	height: 1px;
	background: rgba(44, 47, 49, 0.14);
	transform: translate(-50%, -50%) rotate(45deg);
}

figure.placeholder::after {
	transform: translate(-50%, -50%) rotate(-45deg);
}

p:has(> a.button) {
	margin-top: 2rem;
	text-align: center;
}

button, a.button {
	display: inline-block;
	padding: 0.5em 1em;
	background: var(--highlight-color);
	color: white;
	text-decoration: none;
	font-size: 90%;
	text-shadow: none;
	box-shadow: 0 4px 18px rgba(17, 24, 39, 0.1);
}

button:active, a.button:active {
	background: #333;
}

img.float-left {
	float: left;
	margin: 0 1rem 1rem 0;
	width: 33%;
	min-width: 1in;
	max-width: 3in;
}

img.float-right {
	float: right;
	margin: 0 0rem 1rem 1rem;
	width: 33%;
	min-width: 1in;
	max-width: 3in;
}

#signature {
	margin-top: 0;
	text-align: right;
	font-family: "Qwitcher Grypen", Zapfino, script;
	font-size: 0.667in;
}

form input[type=text],
form input[type=password],
form textarea {
	width: 100%;
}

/* Contact: form + photo aligned grid, equal column heights */
.contact-intro .contact-grid {
	display: grid;
	grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
	align-items: stretch;
	gap: clamp(1rem, 4vw, 2rem);
	width: 100%;
}

.contact-photo {
	margin: 0;
	min-height: 0;
	height: 100%;
	border-radius: 6px;
	overflow: hidden;
	border: 1px solid rgba(17, 24, 39, 0.12);
	box-shadow: 0 4px 18px rgba(17, 24, 39, 0.1);
}

.contact-photo img {
	display: block;
	width: 100%;
	height: 100%;
	min-height: 16rem;
	object-fit: cover;
	object-position: center;
}

.contact-form {
	display: flex;
	flex-direction: column;
	height: 100%;
	min-width: 0;
	gap: 0.875rem;
	margin: 0;
}

.contact-form p {
	margin: 0;
}

.contact-form label {
	display: block;
	margin-bottom: 0.3em;
	/* font-weight: 500; */
	font-size: smaller;
}

.contact-form input[type="text"],
.contact-form input[type="email"],
.contact-form input[type="tel"],
.contact-form textarea {
	width: 100%;
	max-width: 100%;
	margin: 0;
	padding: 0.55em 0.65em;
	font: inherit;
	line-height: 1.45;
	border: 1px solid rgba(17, 24, 39, 0.22);
	border-radius: 4px;
	background: rgba(255, 255, 255, 0.75);
	color: inherit;
}

.contact-form textarea {
	resize: vertical;
	min-height: 6rem;
}

.contact-form .contact-form-message {
	flex: 1 1 auto;
	display: flex;
	flex-direction: column;
	min-height: 0;
	gap: 0.3em;
}

.contact-form .contact-form-message textarea {
	flex: 1 1 auto;
	min-height: 7rem;
}

.contact-form-actions {
	margin-top: 0.25rem;
	flex-shrink: 0;
}

.contact-form-actions button {
	width: 100%;
	cursor: pointer;
	border: none;
	border-radius: 4px;
	font: inherit;
	font-size: 100%;
	padding: 0.65em 1.25em;
}

@media (max-width: 42rem) {
	.contact-intro .contact-grid {
		grid-template-columns: 1fr;
	}

	.contact-photo img {
		min-height: 14rem;
		max-height: min(40vh, 20rem);
	}

	.contact-form {
		height: auto;
	}

	.contact-form .contact-form-message textarea {
		flex: none;
		min-height: 8rem;
	}
}
