/*
 * Cutting Hedge — pattern & section support styles.
 * Small, buildless CSS for things theme.json can't express per-section.
 */

/* Sticky footer: keep the footer at the viewport bottom on short pages. */
.wp-site-blocks {
	display: flex;
	flex-direction: column;
	min-height: 100vh;
}

.wp-site-blocks > main {
	flex: 1 0 auto;
}

/*
 * Sections control their own vertical spacing, so header / main / footer sit
 * flush — no 30px block-gap strips framing full-bleed coloured sections
 * (e.g. the graphite Tech for Trades block against the header and footer).
 */
.wp-site-blocks > * {
	margin-block-start: 0;
	margin-block-end: 0;
}

/* Two-tone headline: never show the browser's default <mark> highlight. */
mark.has-inline-color {
	background-color: transparent;
}

/* Service cards fill their column so a 3-up row stays even in height. */
.ch-card {
	height: 100%;
}

/*
 * Soft elevation: a gentle downward shadow (not an all-round glow) on the
 * service cards and the before/after images, with a subtle lift on hover.
 */
.ch-card,
.ch-ba-unit .wp-block-image img {
	box-shadow: 0 2px 4px rgba(0, 0, 0, 0.04), 0 10px 28px rgba(0, 0, 0, 0.10);
	transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.ch-card:hover,
.ch-ba-unit .wp-block-image:hover img {
	transform: translateY(-4px);
	box-shadow: 0 4px 8px rgba(0, 0, 0, 0.06), 0 18px 40px rgba(0, 0, 0, 0.14);
}

/* Respect users who prefer less motion. */
@media (prefers-reduced-motion: reduce) {
	.ch-card,
	.ch-ba-unit .wp-block-image img {
		transition: none;
	}

	.ch-card:hover,
	.ch-ba-unit .wp-block-image:hover img {
		transform: none;
	}
}

/*
 * Brand logo lockup — icon SVG + wordmark as real text (Poppins).
 * The icon-to-wordmark spacing is the `gap` value below — change it here.
 */
.ch-logo {
	display: inline-flex;
	align-items: center;
	gap: 0.7rem; /* <-- spacing between the hedge mark and "Cutting Hedge" */
	text-decoration: none;
	line-height: 1;
}

.ch-logo__mark {
	display: block;
	width: auto;
	height: 40px;
	flex: none;
}

.ch-logo__word {
	font-family: var(--wp--preset--font-family--heading);
	font-weight: 400; /* lighter, elegant wordmark to contrast the bold icon */
	font-size: 1.7rem;
	letter-spacing: 0;
	color: var(--wp--preset--color--contrast);
	white-space: nowrap;
}

.ch-logo:hover .ch-logo__word,
.ch-logo:focus-visible .ch-logo__word {
	color: var(--wp--preset--color--accent);
}

/* Smaller variant for the footer. */
.ch-logo--sm .ch-logo__mark {
	height: 34px;
}

.ch-logo--sm .ch-logo__word {
	font-size: 1.45rem;
}

/*
 * Tech for Trades keeps the graphite "workshop" mood — one green, two moods.
 * Green is the gardening accent only; here links stay light and CTAs stay white.
 */
.ch-tech a {
	color: #ffffff;
}

/* Headings default to ink in theme.json; on graphite they must be light. */
.ch-tech h1,
.ch-tech h2,
.ch-tech h3,
.ch-tech h4,
.ch-tech h5,
.ch-tech h6 {
	color: #ffffff;
}

.ch-tech a:hover,
.ch-tech a:focus {
	opacity: 0.85;
}

/* White CTA on graphite: hold white on hover (no green flash from the global button style). */
.ch-tech .wp-block-button__link:hover,
.ch-tech .wp-block-button__link:focus {
	background-color: rgba(255, 255, 255, 0.88) !important;
	color: var(--wp--preset--color--graphite) !important;
}

/* Visible keyboard focus everywhere (accent on light, white on graphite). */
a:focus-visible,
.wp-element-button:focus-visible,
button:focus-visible,
input:focus-visible,
summary:focus-visible {
	outline: 2px solid var(--wp--preset--color--accent);
	outline-offset: 2px;
	border-radius: 2px;
}

.ch-tech a:focus-visible,
.ch-tech .wp-element-button:focus-visible {
	outline-color: #ffffff;
}
