/* ==========================================================================
   Avery Cabin Company design system
   1. Tokens & brand themes   2. Base   3. Layout   4. Components   5. Pages
   ========================================================================== */

/* 1. Tokens & brand themes ------------------------------------------------ */
:root {
	--ink: #1d1b18;
	--ink-muted: #57534c;
	--paper: #fbf9f5;
	--surface: #ffffff;
	--line: #d9d4c9;

	/* Company (neutral) theme is the default */
	--brand: #2a2622;
	--on-brand: #ffffff;
	--on-brand-muted: #d8d2c6;
	--accent: #d6a84a;
	--accent-ink: #7a5200;
	--tint: #f1ece2;

	--font-body: system-ui, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
	--font-display: var(--font-body);

	--radius: 0.75rem;
	--shadow: 0 1px 2px rgb(0 0 0 / 0.08), 0 8px 24px rgb(0 0 0 / 0.08);
	--section-space: clamp(2.5rem, 6vw, 5rem);
	--container: 72rem;
}

/* Avery Cabin: forest green and warm timber */
[data-brand="cabins"] {
	--brand: #1f4a2e;
	--accent: #e0a458;
	--accent-ink: #8a4a14;
	--tint: #e9efe4;
	--font-display: "Iowan Old Style", "Palatino Linotype", Palatino, Georgia, serif;
}

/* Avery Homes: midnight and gold, matching the logo */
[data-brand="homes"] {
	--brand: #151d27;
	--accent: #d4af37;
	--accent-ink: #6f5200;
	--tint: #f5efdf;
}

/* 2. Base ------------------------------------------------------------------ */
*, *::before, *::after {
	box-sizing: border-box;
}

html {
	-webkit-text-size-adjust: 100%;
	scroll-padding-top: 1rem;
}

body {
	margin: 0;
	font-family: var(--font-body);
	font-size: 1.0625rem;
	line-height: 1.6;
	color: var(--ink);
	background: var(--paper);
}

img, svg {
	max-width: 100%;
	height: auto;
}

h1, h2, h3 {
	font-family: var(--font-display);
	line-height: 1.15;
	margin: 0 0 0.5em;
	text-wrap: balance;
}

h1 { font-size: clamp(2rem, 5vw + 0.5rem, 3.5rem); }
h2 { font-size: clamp(1.5rem, 2.5vw + 0.75rem, 2.25rem); }
h3 { font-size: 1.25rem; }

p { margin: 0 0 1em; }

a { color: var(--accent-ink); text-underline-offset: 0.2em; }
a:hover { text-decoration-thickness: 2px; }

/* Headings and main receive programmatic focus on navigation; no ring needed */
h1:focus, h1:focus-visible, main:focus, main:focus-visible {
	outline: none;
	box-shadow: none;
}

/* Two-tone focus ring: visible on both light and dark backgrounds */
:focus-visible {
	outline: 3px solid #ffdd00;
	outline-offset: 0;
	box-shadow: 0 0 0 6px #000;
}

address { font-style: normal; }

.plain-list {
	list-style: none;
	margin: 0;
	padding: 0;
}

.visually-hidden {
	position: absolute !important;
	width: 1px;
	height: 1px;
	margin: -1px;
	padding: 0;
	overflow: hidden;
	clip-path: inset(50%);
	white-space: nowrap;
	border: 0;
}

.skip-link {
	position: absolute;
	left: 0.5rem;
	top: -4rem;
	z-index: 100;
	padding: 0.75rem 1rem;
	background: #fff;
	color: #000;
	font-weight: 700;
	border-radius: 0.25rem;
}

.skip-link:focus {
	top: 0.5rem;
}

@media (prefers-reduced-motion: reduce) {
	*, *::before, *::after {
		animation-duration: 0.01ms !important;
		animation-iteration-count: 1 !important;
		transition-duration: 0.01ms !important;
		scroll-behavior: auto !important;
	}
}

/* 3. Layout ---------------------------------------------------------------- */
.site {
	min-height: 100vh;
	display: flex;
	flex-direction: column;
	background: var(--paper);
}

.site > main {
	flex: 1;
}

.container {
	width: min(100% - 2rem, var(--container));
	margin-inline: auto;
}

.section {
	padding-block: var(--section-space);
}

.section--tint {
	background: var(--tint);
}

.section__header {
	max-width: 44rem;
	margin-bottom: 2rem;
}

/* Long-form text pages (About) */
.prose {
	max-width: 46rem;
}

.prose h2 {
	margin-top: 2.25rem;
	margin-bottom: 0.5rem;
	font-size: clamp(1.25rem, 1.5vw + 0.9rem, 1.625rem);
}

.prose__actions {
	display: flex;
	flex-wrap: wrap;
	gap: 0.75rem;
	margin-top: 2.5rem;
}

/* Brand bar (top strip: brand switch + phone) */
.brand-bar {
	background: color-mix(in srgb, var(--brand), #000 35%);
	color: var(--on-brand);
	font-size: 0.9375rem;
}

.brand-bar a {
	color: var(--on-brand);
}

.brand-bar__inner {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: 0.25rem 1rem;
	min-height: 2.75rem;
}

.brand-bar__home,
.brand-bar__phone {
	display: inline-flex;
	align-items: center;
	min-height: 2.75rem;
	text-decoration: none;
}

.brand-bar__home:hover,
.brand-bar__phone:hover {
	text-decoration: underline;
}

.brand-switch {
	display: flex;
	gap: 0.25rem;
}

.brand-switch a {
	display: inline-flex;
	align-items: center;
	min-height: 2.75rem;
	padding-inline: 0.75rem;
	text-decoration: none;
	border-bottom: 3px solid transparent;
}

.brand-switch a:hover { border-bottom-color: var(--on-brand-muted); }
.brand-switch a[aria-current] { border-bottom-color: var(--accent); font-weight: 700; }

/* Header */
.site-header {
	background: var(--brand);
	color: var(--on-brand);
}

.site-header__inner {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: 0.5rem 1.5rem;
	padding-block: 0.75rem;
}

.logo-link {
	display: inline-flex;
	align-items: center;
	border-radius: 0.25rem;
}

.logo--cabin { height: 3rem; width: auto; }
.logo--homes { height: 5.5rem; width: auto; }

.wordmark {
	font-family: var(--font-display);
	font-size: 1.5rem;
	font-weight: 700;
	color: var(--on-brand);
	text-decoration: none;
	letter-spacing: 0.01em;
}

.wordmark span { color: var(--accent); }
.logo-link--wordmark { text-decoration: none; }

.primary-nav ul {
	display: flex;
	flex-wrap: wrap;
	gap: 0.25rem;
	list-style: none;
	margin: 0;
	padding: 0;
}

.primary-nav a {
	display: inline-flex;
	align-items: center;
	min-height: 2.75rem;
	padding-inline: 1rem;
	color: var(--on-brand);
	font-weight: 600;
	text-decoration: none;
	border-bottom: 3px solid transparent;
}

.primary-nav a:hover { border-bottom-color: var(--on-brand-muted); }
.primary-nav a[aria-current="page"] { border-bottom-color: var(--accent); }

.nav-toggle {
	display: none;
	align-items: center;
	gap: 0.5rem;
	min-height: 2.75rem;
	padding: 0 1rem;
	font: inherit;
	font-weight: 600;
	color: var(--on-brand);
	background: transparent;
	border: 2px solid var(--on-brand-muted);
	border-radius: 0.5rem;
	cursor: pointer;
}

.nav-toggle__icon,
.nav-toggle__icon::before,
.nav-toggle__icon::after {
	display: block;
	width: 1.25rem;
	height: 2px;
	background: currentColor;
	content: "";
	position: relative;
}

.nav-toggle__icon::before { position: absolute; top: -6px; }
.nav-toggle__icon::after { position: absolute; top: 6px; }

/* Without JavaScript the menu stays visible; with it, collapse on small screens */
@media (max-width: 47.99rem) {
	.js .nav-toggle { display: inline-flex; }
	.js .primary-nav { display: none; flex-basis: 100%; }
	.js .primary-nav[data-open="true"] { display: block; }
	.primary-nav ul { flex-direction: column; }
	.primary-nav a { width: 100%; }
}

/* Footer */
.site-footer {
	background: var(--brand);
	color: var(--on-brand);
	margin-top: auto;
}

.site-footer a { color: var(--on-brand); }
.site-footer h2 { font-size: 1.125rem; color: var(--accent); }

.site-footer__grid {
	display: grid;
	gap: 2rem;
	padding-block: 3rem 2rem;
	grid-template-columns: repeat(auto-fit, minmax(14rem, 1fr));
}

.site-footer .plain-list li a {
	display: inline-block;
	padding-block: 0.25rem;
}

.site-footer__legal {
	padding-block: 1rem 2rem;
	border-top: 1px solid color-mix(in srgb, var(--on-brand), transparent 75%);
	color: var(--on-brand-muted);
	font-size: 0.9375rem;
}

.site-footer__legal p { margin: 0; }

/* 4. Components ------------------------------------------------------------ */
.btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 0.5rem;
	min-height: 2.75rem;
	padding: 0.5rem 1.5rem;
	font: inherit;
	font-weight: 700;
	text-decoration: none;
	color: var(--on-brand);
	background: var(--brand);
	border: 2px solid var(--brand);
	border-radius: 999px;
	cursor: pointer;
}

.btn:hover { text-decoration: underline; }

.btn--accent {
	color: #1d1b18;
	background: var(--accent);
	border-color: var(--accent);
}

.btn--outline {
	color: var(--brand);
	background: transparent;
}

.eyebrow {
	margin: 0 0 0.5rem;
	font-size: 0.875rem;
	font-weight: 700;
	letter-spacing: 0.1em;
	text-transform: uppercase;
	color: var(--accent-ink);
}

.lead {
	font-size: 1.25rem;
	color: var(--ink-muted);
	max-width: 42rem;
}

.check-list {
	list-style: none;
	margin: 0 0 1.5rem;
	padding: 0;
}

.check-list li {
	position: relative;
	padding: 0.25rem 0 0.25rem 1.75rem;
}

.check-list li::before {
	content: "";
	position: absolute;
	left: 0.25rem;
	top: 0.75rem;
	width: 0.75rem;
	height: 0.4rem;
	border-left: 3px solid var(--accent-ink);
	border-bottom: 3px solid var(--accent-ink);
	transform: rotate(-45deg);
}

/* Two columns on wider screens; items never split across columns. */
@media (min-width: 48rem) {
	.check-list--columns { columns: 2; column-gap: 3rem; }
	.check-list--columns li { break-inside: avoid; }
}

/* "See more" disclosure built on <details>, so it works without JavaScript. */
.disclosure { margin-bottom: 1.5rem; }

.disclosure > summary {
	list-style: none;
	width: fit-content;
}

.disclosure > summary::-webkit-details-marker { display: none; }

.disclosure > summary:hover { text-decoration: underline; }

.disclosure[open] > summary .disclosure__closed { display: none; }
.disclosure:not([open]) > summary .disclosure__open { display: none; }

.disclosure__title { margin: 1.5rem 0 0.75rem; }

/* Choice cards: the two product lines on the home page */
.choices {
	display: grid;
	gap: 1.5rem;
	grid-template-columns: repeat(auto-fit, minmax(min(100%, 22rem), 1fr));
}

.choice {
	position: relative;
	display: flex;
	flex-direction: column;
	overflow: hidden;
	background: var(--surface);
	border-radius: var(--radius);
	box-shadow: var(--shadow);
	transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.choice:hover {
	transform: translateY(-4px);
}

.choice:has(a:focus-visible) {
	outline: 3px solid #ffdd00;
	box-shadow: 0 0 0 6px #000;
}

.choice__media {
	aspect-ratio: 16 / 9;
	overflow: hidden;
	background: var(--brand);
}

.choice__media img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}

.choice__media--logo {
	position: relative;
	background: #151d27;
}

.choice__media--cabin {
    background: #1f4a2e;
}

.choice__media--logo img {
	position: absolute;
	inset: 1rem;
	width: calc(100% - 2rem);
	height: calc(100% - 2rem);
	object-fit: contain;
}

.choice__body {
	display: flex;
	flex: 1;
	flex-direction: column;
	padding: 1.5rem;
}

.choice__body h2 {
	margin-bottom: 0.5rem;
	font-size: 1.75rem;
}

/* Stretched link makes the whole card clickable with a single tab stop */
.choice__body h2 a {
	color: var(--ink);
	text-decoration: none;
}

.choice__body h2 a::after {
	content: "";
	position: absolute;
	inset: 0;
}

.choice__body h2 a:focus-visible {
	outline: none;
	box-shadow: none;
}

.choice__cta {
	margin-top: auto;
	font-weight: 700;
}

.choice[data-theme="cabins"] { --accent-ink: #8a4a14; --brand: #1f4a2e; }
.choice[data-theme="homes"] { --accent-ink: #6f5200; --brand: #151d27; }

.choice__cta span {
	display: inline-block;
	padding: 0.5rem 1.5rem;
	color: var(--on-brand);
	background: var(--brand);
	border-radius: 999px;
}

.choice:hover .choice__cta span { text-decoration: underline; }

.badge {
	display: inline-block;
	margin-bottom: 0.75rem;
	padding: 0.125rem 0.75rem;
	font-size: 0.875rem;
	font-weight: 700;
	color: #1d1b18;
	background: var(--tint);
	border: 1px solid var(--line);
	border-radius: 999px;
	align-self: flex-start;
}

/* Two-up information columns */
.split {
	display: grid;
	gap: 2.5rem;
	grid-template-columns: repeat(auto-fit, minmax(min(100%, 22rem), 1fr));
}

.panel {
	padding: 2rem;
	background: var(--surface);
	border: 1px solid var(--line);
	border-top-width: 6px;
	border-radius: var(--radius);
}

.panel[data-theme="cabins"] { border-top-color: #1f4a2e; --accent-ink: #8a4a14; }
.panel[data-theme="homes"] { border-top-color: #d4af37; --accent-ink: #6f5200; }

.stats {
	display: grid;
	gap: 1.5rem;
	margin: 0;
	padding: 0;
	list-style: none;
	grid-template-columns: repeat(auto-fit, minmax(12rem, 1fr));
	text-align: center;
}

.stats strong {
	display: block;
	font-family: var(--font-display);
	font-size: clamp(2.25rem, 5vw, 3.25rem);
	line-height: 1.1;
	color: var(--accent-ink);
}

.cta-strip {
	background: var(--brand);
	color: var(--on-brand);
	text-align: center;
}

.cta-strip h2 { color: var(--on-brand); }
.cta-strip p { color: var(--on-brand-muted); }
.cta-strip a:not(.btn) { color: var(--on-brand); }

.cta-strip__actions {
	display: flex;
	flex-wrap: wrap;
	justify-content: center;
	gap: 1rem;
	margin-top: 1.5rem;
}

.cta-strip .btn--outline {
	color: var(--on-brand);
	border-color: var(--on-brand);
}

/* 5. Pages ----------------------------------------------------------------- */
.hero {
	padding-block: var(--section-space) 2rem;
	background:
		linear-gradient(180deg, var(--tint) 0%, var(--paper) 100%);
}

.hero__intro {
	max-width: 48rem;
	margin-bottom: 2.5rem;
}

.page-hero {
	position: relative;
	isolation: isolate;
	display: grid;
	align-items: end;
	min-height: clamp(20rem, 50vw, 32rem);
	color: #fff;
	background: var(--brand);
}

.page-hero > img {
	position: absolute;
	inset: 0;
	z-index: -2;
	width: 100%;
	height: 100%;
	object-fit: cover;
}

.page-hero::after {
	content: "";
	position: absolute;
	inset: 0;
	z-index: -1;
	background: linear-gradient(0deg, rgb(0 0 0 / 0.88) 0%, rgb(0 0 0 / 0.74) 50%, rgb(0 0 0 / 0.58) 100%);
}

.page-hero .eyebrow { color: #fff; }

.page-hero__content {
	padding-block: 3rem;
	max-width: 46rem;
}

.page-hero h1 { color: #fff; margin-bottom: 0.25em; }
.page-hero .lead { color: #fff; }
.page-hero .eyebrow { color: var(--accent); }

.page-hero--solid::after { display: none; }

.page-hero--solid {
	align-items: center;
	background: linear-gradient(135deg, var(--brand) 0%, color-mix(in srgb, var(--brand), #fff 12%) 100%);
}

.contact-grid {
	display: grid;
	gap: 2rem;
	grid-template-columns: repeat(auto-fit, minmax(min(100%, 20rem), 1fr));
}

.error-page {
	padding-block: var(--section-space);
}

/* Floor plans -------------------------------------------------------------- */
.breadcrumb ol {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.25rem 0.5rem;
    margin: 0 0 1rem;
    padding: 0;
    list-style: none;
    font-size: 0.9375rem;
}

.breadcrumb li + li::before {
    content: "/";
    margin-right: 0.5rem;
    opacity: 0.7;
}

.breadcrumb a,
.breadcrumb [aria-current] {

    display: inline-block;

    padding-block: 0.5rem;

}

.page-hero--solid .breadcrumb a { color: #fff; }
.page-hero--compact { min-height: 0; }
.page-hero--compact .page-hero__content { padding-block: 2rem; }

.plan-grid {
    display: grid;
    gap: 1.5rem;
    grid-template-columns: repeat(auto-fill, minmax(min(100%, 17rem), 1fr));
}

.plan-card {
    position: relative;
    height: 100%;
    overflow: hidden;
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.plan-card:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow);
}

.plan-card:has(a:focus-visible) {
    outline: 3px solid #ffdd00;
    box-shadow: 0 0 0 6px #000;
}

.plan-card__media {
    aspect-ratio: 4 / 3;
    background: var(--tint);
}

.plan-card__media img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.plan-card__body { padding: 1rem 1.25rem 1.25rem; }
.plan-card__body h3 { margin-bottom: 0.25rem; }

/* Stretched link: whole card is one tab stop */
.plan-card__body h3 a {
    color: var(--ink);
    text-decoration: none;
}

.plan-card__body h3 a::after {
    content: "";
    position: absolute;
    inset: 0;
}

.plan-card__body h3 a:focus-visible {
    outline: none;
    box-shadow: none;
}

.plan-card:hover h3 a { text-decoration: underline; }
.plan-card__specs { margin: 0 0 0.25rem; font-weight: 600; }
.plan-card__meta { margin: 0; color: var(--ink-muted); font-size: 0.9375rem; }
.section__more { margin-top: 2rem; }

.plan-header {
    padding-bottom: 1rem;
    background: linear-gradient(180deg, var(--tint) 0%, var(--paper) 100%);
}

.plan-header__grid {
    display: grid;
    gap: 1.5rem 3rem;
    align-items: end;
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 20rem), 1fr));
}

.plan-header__note { color: var(--ink-muted); }
.plan-description { max-width: 46rem; margin-top: 1.5rem; }

.specs {
    display: grid;
    gap: 0.75rem 1.5rem;
    margin: 0 0 1.25rem;
    grid-template-columns: repeat(auto-fit, minmax(7rem, 1fr));
}

.specs dt {
    font-size: 0.875rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--ink-muted);
}

.specs dd {
    margin: 0;
    font-family: var(--font-display);
    font-size: 1.75rem;
    line-height: 1.2;
}

.plan-body { padding-bottom: var(--section-space); }
.plan-section { margin-top: var(--section-space); }

.plan-figure {
    margin: 0 0 1.5rem;
    padding: 1rem;
    background: #fff;
    border: 1px solid var(--line);
    border-radius: var(--radius);
}

.plan-figure img { display: block; margin-inline: auto; }

.doc-list {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
}

.plan-video {
    display: block;
    width: 100%;
    max-width: 50rem;
    /* Keeps tall (vertical) video fully on screen; wide video still fills the column. */
    max-height: calc(100dvh - 8rem);
    border-radius: var(--radius);
    background: #000;
}

.plan-video__description { max-width: 50rem; margin-top: 0.75rem; color: var(--ink-muted); }

.plan-pager {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 0.5rem 1.5rem;
    margin-top: var(--section-space);
    padding-top: 1.5rem;
    border-top: 1px solid var(--line);
}

.plan-pager__link {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    min-height: 2.75rem;
    font-weight: 600;
}

/* Photo gallery ------------------------------------------------------------ */
.gallery__count { font-weight: 400; color: var(--ink-muted); }
.gallery__hint { color: var(--ink-muted); margin-bottom: 1rem; }

.gallery__grid {
    display: grid;
    gap: 0.75rem;
    margin: 0;
    padding: 0;
    list-style: none;
    grid-template-columns: repeat(2, 1fr);
}

@media (min-width: 40rem) {
    .gallery__grid { grid-template-columns: repeat(4, 1fr); }
}

.gallery__item:first-child {
    grid-column: span 2;
    grid-row: span 2;
}

.gallery__item a {
    display: block;
    height: 100%;
    overflow: hidden;
    border-radius: var(--radius);
    background: var(--tint);
}

.gallery__item img {
    display: block;
    width: 100%;
    height: 100%;
    min-height: 100%;
    aspect-ratio: 4 / 3;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.gallery__item:first-child img { aspect-ratio: auto; }
.gallery__item a:hover img { transform: scale(1.04); }

/* Lightbox (native <dialog>) */
body:has(dialog.lightbox[open]) { overflow: hidden; }

.lightbox {
    width: 100vw;
    max-width: none;
    height: 100dvh;
    max-height: none;
    margin: 0;
    padding: 0;
    color: #fff;
    background: #0b0b0b;
    border: 0;
}

.lightbox::backdrop { background: #000; }

.lightbox[open] {
    display: grid;
}

.lightbox__inner {
    display: grid;
    grid-template-rows: auto 1fr;
    min-height: 0;
    height: 100%;
}

.lightbox__bar {
    display: flex;
    align-items: center;
    gap: 0.5rem 1rem;
    padding: 0.75rem 1rem;
}

.lightbox__title {
    margin: 0;
    font-family: var(--font-body);
    font-size: 1rem;
    font-weight: 600;
}

.lightbox__count {
    margin: 0 auto 0 0;
    color: #d6d6d6;
}

.lightbox__btn {
    min-width: 2.75rem;
    min-height: 2.75rem;
    padding: 0.5rem 1.25rem;
    font: inherit;
    font-weight: 600;
    color: #fff;
    background: #2b2b2b;
    border: 2px solid #8a8a8a;
    border-radius: 999px;
    cursor: pointer;
}

.lightbox__btn:hover { background: #3d3d3d; }

.lightbox__body {
    display: grid;
    gap: 0.75rem;
    min-height: 0;
    padding: 0 1rem 1rem;
    grid-template-columns: 1fr 1fr;
    grid-template-rows: minmax(0, 1fr) auto;
    grid-template-areas: "fig fig" "prev next";
}

.lightbox__figure {
    grid-area: fig;
    display: grid;
    place-items: center;
    min-height: 0;
    margin: 0;
}

.lightbox__figure img {
    max-width: 100%;
    max-height: calc(100dvh - 10rem);
    width: auto;
    height: auto;
    object-fit: contain;
}

.lightbox__prev { grid-area: prev; }
.lightbox__next { grid-area: next; }

@media (min-width: 48rem) {
    .lightbox__body {
        grid-template-columns: auto 1fr auto;
        grid-template-rows: minmax(0, 1fr);
        grid-template-areas: "prev fig next";
        align-items: center;
    }

    .lightbox__figure img { max-height: calc(100dvh - 6rem); }
}

/* Contact form ------------------------------------------------------------- */
.contact-layout {
	display: grid;
	gap: 2rem;
	align-items: start;
	grid-template-columns: repeat(auto-fit, minmax(min(100%, 22rem), 1fr));
}

.contact-side { display: grid; gap: 1.5rem; }
.field { margin-bottom: 1.25rem; }

.field label {
	display: block;
	margin-bottom: 0.35rem;
	font-weight: 600;
}

.field .optional { font-weight: 400; color: var(--ink-muted); }

.field input,
.field select,
.field textarea {
	display: block;
	width: 100%;
	min-height: 2.75rem;
	padding: 0.5rem 0.75rem;
	font: inherit;
	color: var(--ink);
	background: #fff;
	border: 2px solid #6b665e;
	border-radius: 0.5rem;
}

.field textarea { min-height: 9rem; resize: vertical; }
.field [aria-invalid="true"] { border-color: #b00020; }

.field__error {
	margin: 0.35rem 0 0;
	font-weight: 600;
	color: #b00020;
}

.form-note { color: var(--ink-muted); margin-bottom: 1rem; }

.form-status {
	margin-bottom: 1.5rem;
	padding: 1rem 1.25rem;
	border: 2px solid;
	border-radius: 0.5rem;
	background: #fff;
}

.form-status p { margin: 0 0 0.5rem; }
.form-status ul { margin: 0; padding-left: 1.25rem; }
.form-status--error { border-color: #b00020; }
.form-status--error a { color: #b00020; }
.form-status--ok { border-color: #1b6b2f; }

/* Blazor framework UI ------------------------------------------------------- */
#blazor-error-ui {
	display: none;
	position: fixed;
	inset: auto 0 0 0;
	z-index: 1000;
	padding: 0.75rem 1.25rem;
	color: #1d1b18;
	background: #ffeb99;
	box-shadow: 0 -1px 2px rgb(0 0 0 / 0.2);
}

#blazor-error-ui .dismiss {
	position: absolute;
	right: 0.5rem;
	top: 0.25rem;
	min-width: 2.75rem;
	min-height: 2.75rem;
	font: inherit;
	background: transparent;
	border: 0;
	cursor: pointer;
}

.blazor-error-boundary {
	padding: 1rem;
	color: #fff;
	background: #b32121;
}

.blazor-error-boundary::after {
	content: "An error has occurred.";
}

.validation-message {
	color: #b00020;
}

/* Forced colors (Windows High Contrast) */
@media (forced-colors: active) {
	.btn, .choice__cta span {
		border: 2px solid ButtonText;
	}
}
