/* WordPress adds block gap between direct children of .wp-site-blocks */
.wp-site-blocks > main {
	margin-block-start: 0 !important;
	padding-top: 0 !important;
}

.wp-site-blocks > footer.wp-block-template-part {
	margin-block-start: 0;
	margin-block-end: 0;
}

.wp-site-blocks > .wp-block-template-part:has( .theme-header ),
.wp-site-blocks > header.wp-block-template-part {
	margin-block-start: 0;
	margin-block-end: 0;
}

/* -------------------------------------------------------------------------
   Header — transparent, in flow (one-page)
   ------------------------------------------------------------------------- */

.theme-header {
	background: transparent;
	color: var(--wp--preset--color--navy, #0d1f32);
}

.theme-header__inner {
	display: flex;
	flex-wrap: nowrap;
	justify-content: space-between;
	align-items: center;
	gap: 1rem;
	padding-block: clamp(1.25rem, 3vw, 2rem);
}

@media (min-width: 1800px) {
	.theme-header .theme-container,
	.theme-footer .theme-container {
		width: min(calc(100% - 2.5rem), 1600px);
	}
}

.theme-header__logo {
	flex-shrink: 0;
	margin: 0;
	line-height: 0;
}

.theme-header__logo .theme-logo__link {
	display: block;
	text-decoration: none;
	color: inherit;
}

.theme-header__logo .theme-logo__link:has(.theme-logo__img) {
	line-height: 0;
}

.theme-header__logo .theme-logo__text {
	font-size: var(--wp--preset--font-size--nav, 0.875rem);
	font-weight: 500;
	letter-spacing: 0.04em;
	line-height: 1.2;
	text-transform: uppercase;
}

.theme-header__logo .theme-logo__img {
	display: block;
	width: auto;
	height: clamp(2.5rem, 4.5vw, 3.5rem);
	max-width: min(16rem, 58vw);
	object-fit: contain;
}

.theme-header__cta {
	flex-shrink: 0;
	margin: 0;
	gap: 0;
}

/* Wrapper only — visual styles live on the link (avoids double padding). */
.theme-header__cta .wp-block-button {
	margin: 0;
	padding: 0;
	border: 0;
	background: transparent;
	min-height: 0;
}

.theme-header__cta .wp-block-button__link {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	box-sizing: border-box;
	min-height: 2.75rem;
	margin: 0;
	padding: 0.7rem 1.35rem !important;
	border: 1px solid var(--wp--preset--color--navy, #0d1f32) !important;
	border-radius: 6px !important;
	background: var(--wp--preset--color--navy, #0d1f32) !important;
	color: var(--wp--preset--color--beige, #f8f2e7) !important;
	font-family: inherit;
	font-size: var(--wp--preset--font-size--nav, 0.875rem);
	font-weight: 500;
	letter-spacing: 0.08em;
	line-height: 1;
	text-decoration: none;
	text-transform: uppercase;
	transition:
		color var(--theme-duration) var(--theme-ease),
		background-color var(--theme-duration) var(--theme-ease),
		border-color var(--theme-duration) var(--theme-ease);
}

.theme-header__cta .wp-block-button__link:hover,
.theme-header__cta .wp-block-button__link:focus-visible {
	background: color-mix(in srgb, var(--wp--preset--color--navy, #0d1f32) 88%, white) !important;
	border-color: color-mix(in srgb, var(--wp--preset--color--navy, #0d1f32) 88%, white) !important;
	color: var(--wp--preset--color--beige, #f8f2e7) !important;
}

@media (max-width: 480px) {
	.theme-header__cta .wp-block-button__link {
		min-height: 2.5rem;
		padding: 0.6rem 0.9rem !important;
		font-size: 0.75rem;
		letter-spacing: 0.06em;
	}

	.theme-header__logo .theme-logo__img {
		height: clamp(2rem, 9vw, 2.5rem);
		max-width: min(11rem, 48vw);
	}
}

/* -------------------------------------------------------------------------
   Footer
   ------------------------------------------------------------------------- */

.theme-footer {
	background: var(--wp--preset--color--navy, #0d1f32);
	color: var(--wp--preset--color--beige, #f8f2e7);
}

.theme-footer a {
	color: inherit;
	text-decoration: none;
}

.theme-footer .is-layout-flow > * {
	margin-block-start: 0;
}

.theme-footer__inner {
	padding-block: clamp(3rem, 6vw, 4.5rem) 0;
}

.theme-footer__main {
	display: grid;
	grid-template-columns: minmax(16rem, 1.4fr) minmax(10rem, 0.8fr) minmax(10rem, 0.9fr);
	gap: clamp(2rem, 4vw, 4rem);
	align-items: start;
	padding-bottom: clamp(2.5rem, 5vw, 3.5rem);
}

.theme-footer .theme-footer__brand {
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	gap: 0;
}

.theme-footer .theme-footer__brand > * {
	margin-block: 0;
}

.theme-footer .theme-footer__lead {
	margin-block-start: clamp(1.25rem, 2.2vw, 1.75rem);
}

.theme-footer__lead {
	max-width: 28rem;
	margin: 0;
	color: color-mix(in srgb, var(--wp--preset--color--beige, #f8f2e7) 88%, transparent);
	font-size: var(--wp--preset--font-size--small-body, 0.9375rem);
	line-height: 1.55;
}

.theme-footer__column {
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	gap: 0;
	min-width: 0;
	text-align: left;
}

.theme-footer__column > * {
	margin-inline: 0;
	max-width: none;
}

.theme-footer__column-title {
	margin: 0 0 1rem;
	color: var(--wp--preset--color--beige, #f8f2e7);
	font-size: var(--wp--preset--font-size--small-body, 0.875rem);
	font-weight: 500;
	letter-spacing: 0.12em;
	line-height: 1.3;
	text-align: left;
	text-transform: uppercase;
	width: 100%;
}

.theme-footer__meta,
.theme-footer__address,
.theme-footer__contact {
	margin: 0;
	font-size: var(--wp--preset--font-size--small-body, 0.9375rem);
	line-height: 1.55;
	color: color-mix(in srgb, var(--wp--preset--color--beige, #f8f2e7) 88%, transparent);
}

.theme-footer__meta + .theme-footer__meta,
.theme-footer__contact + .theme-footer__meta,
.theme-footer__meta + .theme-footer__address,
.theme-footer__contact + .theme-footer__address {
	margin-top: 0.15rem;
}

.theme-footer__contact a {
	font-weight: 400;
	position: relative;
	text-decoration: none;
}

.theme-footer__contact a::before {
	content: "";
	position: absolute;
	bottom: var(--theme-underline-offset);
	left: 0;
	width: 100%;
	height: var(--theme-underline-thickness);
	background-color: currentColor;
	transition: transform var(--theme-underline-duration) var(--theme-ease);
	transform-origin: right;
	transform: scaleX(0) rotate(0.001deg);
	pointer-events: none;
}

@media (hover: hover) and (pointer: fine) {
	.theme-footer__contact a:hover::before,
	.theme-footer__contact a:focus-visible::before {
		transform-origin: left;
		transform: scaleX(1) rotate(0.001deg);
	}
}

.theme-footer__logo {
	margin: 0;
	line-height: 0;
}

.theme-footer__logo .theme-logo__link {
	display: block;
	text-decoration: none;
	color: inherit;
}

.theme-footer__logo .theme-logo__link:has(.theme-logo__img) {
	line-height: 0;
}

.theme-footer__logo .theme-logo__text {
	font-size: var(--wp--preset--font-size--body, 1.125rem);
	font-weight: 500;
	letter-spacing: 0.04em;
	line-height: 1.2;
	text-transform: uppercase;
}

.theme-footer__logo .theme-logo__img {
	display: block;
	width: auto;
	height: clamp(2.75rem, 4.5vw, 3.5rem);
	max-width: min(16rem, 70vw);
}

.theme-footer__bar-inner {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: 1rem;
	padding-block: 1.15rem;
	border-top: 1px solid color-mix(in srgb, var(--wp--preset--color--beige, #f8f2e7) 22%, transparent);
	color: color-mix(in srgb, var(--wp--preset--color--beige, #f8f2e7) 72%, transparent);
	font-size: 0.8125rem;
	line-height: 1.3;
}

.theme-footer__legal-copy {
	margin: 0;
}

.theme-footer__legal {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 1.25rem;
	margin: 0;
	text-align: right;
}

.theme-footer__legal a {
	text-decoration: none;
	transition: opacity var(--theme-duration) var(--theme-ease);
}

.theme-footer__legal a:hover,
.theme-footer__legal a:focus-visible {
	opacity: 0.75;
}

@media (max-width: 991px) {
	.theme-footer__main {
		grid-template-columns: 1fr 1fr;
	}

	.theme-footer__brand {
		grid-column: 1 / -1;
	}
}

@media (max-width: 640px) {
	.theme-footer__main {
		grid-template-columns: 1fr;
	}
}
