/*
Theme Name: SD Fence Pros
Theme URI: https://sdfencepros.com/
Description: Child theme of OceanWP for SD Fence Pros. Design tokens are pushed
 into OceanWP's own Customizer settings from inc/customizer-defaults.php, so
 this file carries only what those settings cannot express: the header, section
 furniture and card components.
Author: SD Fence Pros
Author URI: https://sdfencepros.com/
Template: oceanwp
Version: 2.13.0
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: ocfence
Tags: two-columns, custom-menu, featured-images, translation-ready
*/

/* ---------------------------------------------------------------------------
 * A note on where things live
 * ---------------------------------------------------------------------------
 * Colours, the type scale, the logo, the menu and the button shape are NOT in
 * this file. OceanWP generates CSS for all of those from theme mods and prints
 * it inline at the end of <head> — after every stylesheet, this one included.
 * Anything declared here at the same specificity would lose on source order.
 *
 * So those tokens go through inc/customizer-defaults.php, which feeds the
 * theme's own generator, and this file styles only what the theme has no
 * setting for. Where a rule below does have to beat that inline block, it says
 * so and wins on specificity rather than !important.
 * --------------------------------------------------------------------------- */

/* ---------------------------------------------------------------------------
 * A second note: do not use rem in this theme
 * ---------------------------------------------------------------------------
 * OceanWP sets the root font size to 62.5%, so 1rem is 10px here, not 16px.
 * Every rem value written against the usual assumption comes out at 62.5% of
 * its intended size — which is what made the first build read as "cramped":
 * a 0.8rem label rendered at 8px and section padding at 34px instead of 54px.
 *
 * Everything in this file, in theme.json and in the patterns is therefore px.
 * em is still fine: it is relative to the element's own font size, not the root.
 * --------------------------------------------------------------------------- */

/* ---------------------------------------------------------------------------
 * The design language, in eight lines
 * ---------------------------------------------------------------------------
 * Two colours carry meaning and never swap jobs: red means "this does
 * something", ink means "this is structure". Everything else is neutral.
 *
 * Surfaces are flat. A card is a 1px outline and a 12px radius, not a shadow —
 * shadows are spent only where something genuinely floats above the page (the
 * phone action bar, an open menu).
 *
 * Headings are set, not shouted: bold, sentence case, tightened. The previous
 * build set every heading in tracked-out caps, which at 64px costs legibility
 * and buys nothing.
 * --------------------------------------------------------------------------- */

:root {
	--ocf-red: #BE5319;
	--ocf-red-dark: #954114;
	--ocf-gold: #E8B04A;
	--ocf-ink: #123640;
	--ocf-ink-soft: #46494A;
	--ocf-mist: #EDF2F4;
	--ocf-line: #D0D9DC;
	--ocf-muted: #656D70;

	/* Three radii, used consistently: controls and cards, photographs, pills. */
	--ocf-r-card: 12px;
	--ocf-r-media: 18px;
	--ocf-r-pill: 999px;
}

/* ---------------------------------------------------------------------------
 * Header
 * ---------------------------------------------------------------------------
 * One dark block, two bands, and it sticks.
 *
 * The previous build cloned the header into a separate fixed bar that slid in
 * on scroll — two sets of markup for one component, and every change had to be
 * made twice. `position: sticky` on the header itself does the same job with no
 * duplicate DOM: the whole thing travels, and the utility band folds away once
 * the page has scrolled so the travelling header stays shallow.
 * --------------------------------------------------------------------------- */

.ocf-wrap {
	max-width: 1366px;
	margin-inline: auto;
	padding-inline: 24px;
}

.ocf-headerwrap {
	position: sticky;
	top: 0;
	z-index: 100;
	background-color: var(--ocf-ink);
	color: #fff;

	/*
	 * The header is sticky, so it is still in the flow: when the utility band
	 * folds away, everything below it moves up by the band's height. Chrome
	 * sees content above the viewport change size and "helpfully" scrolls back
	 * by the same amount to keep the view steady — which moved the page across
	 * the threshold that had just folded the band, so it unfolded, and the
	 * header flickered while the page juddered under the pointer.
	 *
	 * This takes the header out of that calculation. Its height is allowed to
	 * change without the browser trying to compensate for it.
	 */
	overflow-anchor: none;
}

/*
 * OceanWP styles the element by id: `#site-header { background-color: #fff;
 * border-bottom: 1px solid #f1f1f1 }`. Our header keeps that id — the parent's
 * own scripts and anchor links use it — so the parent's white paints straight
 * over the dark wrapper, and the white logo and white menu sitting on it become
 * invisible. That is exactly what it looked like on production: a blank white
 * band with a red button floating in it.
 *
 * A class inside the id is (1,1,0) against the parent's (1,0,0), so it wins on
 * specificity without !important and without touching the parent.
 */
.ocf-headerwrap #site-header {
	background-color: transparent;
	border-bottom: 0;
}

.admin-bar .ocf-headerwrap { top: 32px; }

@media (max-width: 782px) {
	/* The admin bar stops being fixed at this width, so the offset has to go
	   with it or the header hangs 46px below the top of the viewport. */
	.admin-bar .ocf-headerwrap { top: 0; }
}

/* --------------------------------------------------------- band 1: utility */

.ocf-topbar {
	border-bottom: 1px solid rgba(255, 255, 255, 0.12);
	font-size: 14px;
	overflow: hidden;
	max-height: 60px;
	transition: max-height 0.2s ease, opacity 0.2s ease;
}

/* Folded away once the page scrolls. max-height rather than display:none so the
   fold animates, and the band is still in the DOM for anyone tabbing back up. */
.is-stuck .ocf-topbar {
	max-height: 0;
	opacity: 0;
}

.ocf-topbar__inner {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: 4px 28px;
	padding-block: 10px;
}

.ocf-topbar ul {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 4px 24px;
	margin: 0;
	padding: 0;
	list-style: none;
}

.ocf-topbar a {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	color: rgba(255, 255, 255, 0.82);
	text-decoration: none;
	padding-block: 6px;
}

.ocf-topbar a:hover,
.ocf-topbar a:focus-visible {
	color: #fff;
}

.ocf-topbar .ocf-icon {
	width: 15px;
	height: 15px;
	color: var(--ocf-red);
}

/* The phone number is the one thing in this band that is not an errand. */
.ocf-topbar__phone {
	display: inline-flex;
	align-items: center;
	gap: 9px;
	color: #fff;
	font-weight: 700;
	white-space: nowrap;
	text-decoration: none;
	padding-block: 6px;
}

.ocf-topbar__phone .ocf-icon {
	width: 16px;
	height: 16px;
	color: var(--ocf-red);
}

.ocf-topbar__phone:hover,
.ocf-topbar__phone:focus-visible {
	color: var(--ocf-gold);
}

/* --------------------------------------------- band 2: brand, menu, action */

.ocf-header__inner {
	display: flex;
	align-items: center;
	gap: 28px;
	padding-block: 14px;
}

.ocf-brand {
	display: block;
	text-decoration: none;
	flex: none;
}

.ocf-brand__logo {
	display: block;
	max-height: 52px;
	width: auto;
}

.ocf-brand__mark {
	display: block;
	font-weight: 800;
	font-size: 26px;
	line-height: 1.05;
	letter-spacing: -0.01em;
	text-transform: uppercase;
	color: #fff;
}

.ocf-brand__tag {
	display: block;
	margin-top: 3px;
	font-size: 11px;
	font-weight: 600;
	letter-spacing: 0.16em;
	text-transform: uppercase;
	color: var(--ocf-red);
}

/* -------------------------------------------------------------------- menu */

.ocf-nav {
	margin-left: auto;
}

.ocf-menu {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 0 26px;
	margin: 0;
	padding: 0;
	list-style: none;
}

.ocf-menu a {
	display: block;
	padding: 10px 0;
	color: rgba(255, 255, 255, 0.88);
	text-decoration: none;
	font-size: 15px;
	font-weight: 500;
	border-bottom: 2px solid transparent;
	transition: color 0.15s ease, border-color 0.15s ease;
}

.ocf-menu a:hover,
.ocf-menu a:focus-visible,
.ocf-menu .current-menu-item > a,
.ocf-menu .current-menu-ancestor > a {
	color: #fff;
	border-bottom-color: var(--ocf-red);
}

.ocf-menu-empty {
	margin: 0;
	padding: 12px 0;
	font-size: 14px;
	color: rgba(255, 255, 255, 0.6);
}

.ocf-menu > li {
	position: relative;
}

.ocf-menu .sub-menu {
	display: none;
	position: absolute;
	top: 100%;
	left: 0;
	z-index: 30;
	min-width: 240px;
	margin: 0;
	padding: 8px 0;
	list-style: none;
	background-color: #fff;
	border: 1px solid var(--ocf-line);
	border-radius: var(--ocf-r-card);
	box-shadow: 0 18px 40px rgba(21, 51, 43, 0.20);
}

.ocf-menu > li:hover > .sub-menu,
.ocf-menu > li:focus-within > .sub-menu {
	display: block;
}

.ocf-menu .sub-menu a {
	padding: 9px 18px;
	color: var(--ocf-ink);
	font-size: 15px;
	border-bottom: 0;
	text-align: left;
}

.ocf-menu .sub-menu a:hover,
.ocf-menu .sub-menu a:focus-visible {
	color: var(--ocf-red);
}

/* ------------------------------------------------------------- the actions */

.ocf-actions {
	display: flex;
	align-items: center;
	gap: 10px;
	flex: none;
}

.ocf-icon {
	flex: none;
}

.ocf-cta {
	display: inline-flex;
	align-items: center;
	gap: 9px;
	background-color: var(--ocf-red);
	color: #fff;
	text-decoration: none;
	font-weight: 600;
	font-size: 15px;
	line-height: 1.2;
	padding: 13px 22px;
	border-radius: var(--ocf-r-card);
	white-space: nowrap;
	transition: background-color 0.15s ease;
}

.ocf-cta:hover,
.ocf-cta:focus-visible {
	background-color: var(--ocf-red-dark);
	color: #fff;
}

.ocf-cta .ocf-icon {
	width: 17px;
	height: 17px;
}

/* A second action, present but visibly secondary: outline, not fill. */
.ocf-ghost {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 46px;
	height: 46px;
	padding: 0;
	border: 1px solid rgba(255, 255, 255, 0.28);
	border-radius: var(--ocf-r-card);
	background: none;
	color: #fff;
	cursor: pointer;
	transition: border-color 0.15s ease, background-color 0.15s ease;
}

.ocf-ghost:hover,
.ocf-ghost:focus-visible,
.ocf-ghost[aria-expanded="true"] {
	border-color: var(--ocf-red);
	background-color: var(--ocf-red);
}

/* ------------------------------------------------------------------ search */

.ocf-search {
	background-color: #fff;
	border-top: 1px solid var(--ocf-line);
	padding-block: 16px;
}

.ocf-searchform {
	display: flex;
	gap: 10px;
}

.ocf-searchform input[type="search"] {
	flex: 1;
	min-width: 0;
	padding: 13px 16px;
	font-family: inherit;
	font-size: 16px;
	color: var(--ocf-ink);
	background-color: #fff;
	border: 1px solid var(--ocf-line);
	border-radius: var(--ocf-r-card);
}

.ocf-searchform input[type="search"]:focus {
	outline: 2px solid var(--ocf-red);
	outline-offset: 1px;
	border-color: var(--ocf-red);
}

.ocf-searchform button {
	flex: none;
	padding: 13px 24px;
	border: 0;
	border-radius: var(--ocf-r-card);
	cursor: pointer;
	background-color: var(--ocf-ink);
	color: #fff;
	font-family: inherit;
	font-size: 15px;
	font-weight: 600;
}

.ocf-searchform button:hover {
	background-color: var(--ocf-red);
}

/* ------------------------------------------------------------------ burger */

.ocf-burger {
	display: none;
	align-items: center;
	justify-content: center;
	width: 46px;
	height: 46px;
	/* OceanWP styles every button with `padding: 15px 28px`. Border-box cannot
	   shrink content below zero, so that padding pushed this square out to 58px
	   wide and it never matched the search button beside it. */
	padding: 0;
	background: none;
	border: 1px solid rgba(255, 255, 255, 0.28);
	border-radius: var(--ocf-r-card);
	cursor: pointer;
	color: #fff;
}

.ocf-burger__bars,
.ocf-burger__bars::before,
.ocf-burger__bars::after {
	display: block;
	width: 20px;
	height: 2px;
	background-color: currentColor;
}

.ocf-burger__bars {
	position: relative;
}

.ocf-burger__bars::before,
.ocf-burger__bars::after {
	content: "";
	position: absolute;
	left: 0;
}

.ocf-burger__bars::before { top: -6px; }
.ocf-burger__bars::after  { top: 6px; }

@media (prefers-reduced-motion: reduce) {
	.ocf-topbar { transition: none; }
}

/* ------------------------------------------------------------ header, small */

@media (max-width: 1200px) {
	.ocf-menu { gap: 0 18px; }
	.ocf-header__inner { gap: 18px; }
}

@media (max-width: 1024px) {
	.ocf-burger { display: inline-flex; }

	.ocf-nav {
		display: none;
		order: 10;
		width: 100%;
		margin-left: 0;
		border-top: 1px solid rgba(255, 255, 255, 0.12);
		padding-block: 6px;
	}

	.ocf-nav.is-open { display: block; }

	.ocf-header__inner { flex-wrap: wrap; }

	.ocf-menu {
		flex-direction: column;
		align-items: stretch;
		gap: 0;
	}

	.ocf-menu a {
		padding: 13px 0;
		border-bottom: 1px solid rgba(255, 255, 255, 0.1);
	}

	.ocf-menu .sub-menu {
		position: static;
		display: block;
		border: 0;
		border-radius: 0;
		box-shadow: none;
		background: none;
		padding: 0 0 0 16px;
	}

	.ocf-menu .sub-menu a { color: rgba(255, 255, 255, 0.8); }

	/* The header CTA duplicates the phone action bar at the bottom of the
	   screen; two of the same button on one small viewport is one too many. */
	.ocf-cta__label { display: none; }
	.ocf-cta { padding: 13px 15px; }
}

/*
 * The header on a phone.
 *
 * It was 168px tall on a 375px screen — a fifth of the viewport, permanently
 * stuck to the top of it. The cause was arithmetic rather than design: the
 * logo is 163px, the three action buttons 171px, and with the 28px gap between
 * them that is 362px of content in 327px of usable width. Flex wrapped the
 * buttons onto a second row under the logo, left-aligned, which is why the
 * header looked like two headers.
 *
 * Taking the quote button out is what makes one row possible. It is not a loss:
 * the bar pinned to the bottom of every phone screen carries "Request Free
 * Quote" already, so the header's copy of it was the second of two identical
 * buttons on one small screen.
 */
@media (max-width: 640px) {
	.ocf-topbar__inner {
		justify-content: center;
		padding-block: 8px;
	}

	.ocf-topbar ul { display: none; }

	.ocf-header__inner {
		justify-content: space-between;
		gap: 12px;
		padding-block: 12px;
	}

	/* Allowed to shrink rather than forcing the wrap it used to cause. */
	.ocf-brand {
		flex: 0 1 auto;
		min-width: 0;
	}

	.ocf-brand__mark { font-size: 21px; }
	.ocf-brand__tag { font-size: 10px; }

	.ocf-actions { gap: 8px; }

	/* Its twin is at the bottom of the screen, a thumb away. */
	.ocf-actions .ocf-cta { display: none; }

	.ocf-burger,
	.ocf-search-toggle {
		width: 44px;
		height: 44px;
	}

	.ocf-searchform { flex-wrap: wrap; }
	.ocf-searchform button { width: 100%; }
}

/* ---------------------------------------------------------------------------
 * The phone action bar
 * ---------------------------------------------------------------------------
 * On a phone the two actions that matter are "quote" and "call", and both are
 * at the top of a page the visitor has already scrolled away from. A floating
 * bar keeps them one thumb away the whole way down.
 *
 * It is the one element on the site with a real shadow: it genuinely floats
 * over the content, and needs to read that way to stay separate from it.
 * --------------------------------------------------------------------------- */

.ocf-actionbar {
	display: none;
	position: fixed;
	left: 16px;
	right: 16px;
	bottom: 16px;
	z-index: 90;
	gap: 10px;
	align-items: center;
}

.ocf-actionbar__main,
.ocf-actionbar__call {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 10px;
	background-color: var(--ocf-ink);
	color: #fff;
	text-decoration: none;
	font-weight: 600;
	font-size: 16px;
	border-radius: var(--ocf-r-pill);
	box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4), inset 0 1px 0 rgba(255, 255, 255, 0.25);
}

.ocf-actionbar__main {
	flex: 1;
	min-width: 0;
	padding: 16px 20px;
}

.ocf-actionbar__call {
	flex: none;
	width: 56px;
	height: 56px;
	background-color: var(--ocf-red);
}

.ocf-actionbar .ocf-icon {
	width: 19px;
	height: 19px;
}

@media (max-width: 1024px) {
	.ocf-actionbar { display: flex; }

	/* Nothing should end up underneath it. */
	body { padding-bottom: 88px; }
}

/* --------------------------------------------------------------- breadcrumbs */

.ocf-crumbs {
	background-color: var(--ocf-mist);
	border-bottom: 1px solid var(--ocf-line);
	font-size: 14px;
}

.ocf-crumbs .site-breadcrumbs {
	padding-block: 12px;
	color: var(--ocf-muted);
}

.ocf-crumbs a {
	color: var(--ocf-ink);
	text-decoration: none;
}

.ocf-crumbs a:hover,
.ocf-crumbs a:focus-visible {
	color: var(--ocf-red);
}

/* ---------------------------------------------------- flush full-bleed top */

/*
 * OceanWP pads #content-wrap by 50px top and bottom. Right for an ordinary
 * page, wrong for one that opens with an edge-to-edge hero or closes with a
 * full-bleed call to action: it leaves a white band against the header and
 * another against the footer. The classes are added in inc/header.php by
 * looking at the page's first and last blocks, so this applies to any page
 * built from these patterns, not just the front page.
 *
 * The parent's rule is `#main #content-wrap` — two ids, specificity (2,0,0).
 * A single id plus a class loses to that, so these match the same two ids and
 * add the body class on top. No !important needed, and nothing in the parent
 * is touched.
 */
.ocf-flush-top #main #content-wrap {
	padding-top: 0;
}

.ocf-flush-bottom #main #content-wrap {
	padding-bottom: 0;
}

/* ------------------------------------------------------ full-bleed content */

/*
 * OceanWP is a classic theme: page content is rendered inside .container, so a
 * block marked "Full width" in the editor still stops at the container edge.
 * These rules give alignfull and alignwide their meaning back.
 *
 * `overflow-x: clip` rather than `hidden` on the wrapper: hidden would create a
 * scroll container and silently break position: sticky — including the header.
 * 100vw includes the scrollbar, which is what makes the clip necessary at all.
 */
#main {
	overflow-x: clip;
}

.entry .alignfull,
.entry-content .alignfull {
	width: 100vw;
	max-width: 100vw;
	margin-left: calc(50% - 50vw);
	margin-right: calc(50% - 50vw);
}

.entry .alignwide,
.entry-content .alignwide {
	width: auto;
	max-width: min(1600px, 100vw - 40px);
	margin-left: calc(50% - min(800px, 50vw - 20px));
	margin-right: calc(50% - min(800px, 50vw - 20px));
}

/*
 * A full-bleed section still needs a gutter for the text inside it.
 *
 * This rule used to target `> .wp-block-group__inner-container`, the wrapper a
 * group block printed in WordPress 5.x. Constrained layout stopped printing it,
 * so the selector matched nothing at all and every full-width band on the site
 * had its words flat against the edge of the screen. Invisible on a desktop,
 * where the content is capped at 1366px and centred with room to spare;
 * unmissable on a phone, where the heading starts at x = 0.
 *
 * The padding belongs on the section itself: the background still spans the
 * viewport, only the content moves in. padding-inline rather than the
 * shorthand, because the sections set their own top and bottom padding in the
 * block markup and a shorthand here would overwrite it.
 */
.entry .alignfull,
.entry-content .alignfull {
	padding-inline: 20px;
}

/*
 * A cover's overlay and background image are absolutely positioned children of
 * the cover. Constrained layout sets max-width and auto margins on children,
 * which on an inset:0 element narrows and centres the paint — the overlay stops
 * short of the section edges while the section itself is still full width.
 */
.wp-block-cover > .wp-block-cover__background,
.wp-block-cover > .wp-block-cover__image-background {
	max-width: none;
	margin: 0;
}

/* ---------------------------------------------------------------- sections */

/*
 * The small label above a section heading, with a red dot for a bullet. The dot
 * is drawn rather than typed so it keeps its size when the label wraps, and it
 * is the smallest possible use of the action colour: enough to tie the section
 * to the rest of the page, not enough to compete with the heading under it.
 */
.ocf-eyebrow {
	display: flex;
	align-items: center;
	gap: 9px;
	font-weight: 600;
	font-size: 13px;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	margin-bottom: 10px;
}

.ocf-eyebrow::before {
	content: "";
	flex: none;
	width: 7px;
	height: 7px;
	border-radius: 50%;
	background-color: var(--ocf-red);
}

/* Only the colour is conditional, so a label that brings its own colour on a
   dark band keeps the weight, size and tracking. */
.ocf-eyebrow:not(.has-text-color) {
	color: var(--ocf-ink);
}

.ocf-eyebrow.has-text-align-center {
	justify-content: center;
}

/* A centred paragraph running the full 1366px container is unreadable; cap the
   measure without touching the block's own alignment. */
.ocf-measure {
	max-width: 68ch;
	margin-inline: auto;
}

/* The lead paragraph under an h1 or a section heading. */
.ocf-lead {
	font-size: 19px;
	line-height: 1.55;
	color: var(--ocf-ink-soft);
}

/* ---------------------------------------------------------------------------
 * Hero
 * ---------------------------------------------------------------------------
 * Text on the left, a column of tall photographs on the right. The collage is
 * three portrait frames rather than one landscape one because a fence is a
 * vertical subject: a wide crop of a fence is mostly lawn and sky.
 * --------------------------------------------------------------------------- */

.ocf-collage {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: 14px;
}

/* ---------------------------------------------------------------------------
 * Grid children and WordPress's own margins
 * ---------------------------------------------------------------------------
 * A group block is a flow container, and WordPress prints margins for that:
 * `:where(.is-layout-flow) > * { margin-block-start: 24px }` with
 * `:first-child { margin-block-start: 0 }`, on top of core's
 * `.wp-block-image { margin-bottom: 1em }`.
 *
 * Turning the group into a grid does not remove those margins — it hands them
 * to the grid items, and the first and last item have different ones from the
 * rest. The row then sizes to the tallest margin box and every other item gets
 * stretched, so the image inside sits at the top of a box 24px too tall. On
 * production that read as a gallery with a ragged top edge and a 60px gap
 * between rows instead of the 16px the grid asks for. Measured: item 1 was 380
 * tall, items 2-7 were 356, item 8 was 376.
 *
 * `:where()` contributes no specificity, so a single class would be enough to
 * beat the layout rule — but not core's `.wp-block-image`, which is (0,1,0)
 * and may print after this file. Two classes settles both.
 */
.ocf-gallery > .wp-block-image,
.ocf-collage > .wp-block-image {
	margin-block: 0;
}

/* Nothing is stretched, so an image can never be repositioned inside a taller
   box even if a margin sneaks back in. */
.ocf-gallery,
.ocf-collage {
	align-items: start;
}

.ocf-collage img {
	display: block;
	width: 100%;
	height: 100%;
	aspect-ratio: 1 / 2;
	object-fit: cover;
	object-position: center;
	border-radius: var(--ocf-r-media);
}

/*
 * The three frames sit level. An earlier version dropped the middle one by 28px
 * for a bit of rhythm; with real photographs in the frames it just read as a
 * misalignment, which is what it was being mistaken for.
 */

/*
 * On a phone the three frames were 110px wide each — three thumbnails of a
 * fence, which proves nothing about the work. Two frames and a wide one below
 * them use the same space to show something you can actually see.
 */
@media (max-width: 781px) {
	.ocf-collage {
		grid-template-columns: repeat(2, 1fr);
		gap: 12px;
	}

	.ocf-collage img {
		aspect-ratio: 3 / 4;
	}

	.ocf-collage > .wp-block-image:nth-child(3) {
		grid-column: 1 / -1;
	}

	.ocf-collage > .wp-block-image:nth-child(3) img {
		aspect-ratio: 16 / 9;
	}
}

/* The pair of hero actions. */
.ocf-herobuttons .wp-block-button__link {
	padding: 16px 28px;
	font-size: 16px;
}

.ocf-herobuttons .is-style-outline .wp-block-button__link {
	border-width: 1px;
}

/* ------------------------------------------------------------------- cards */

/*
 * Flat: an outline and a radius, no shadow. A grid of shadowed cards makes a
 * page look like a pile of receipts; the outline does the same separating job
 * for a fraction of the visual noise, and reads correctly when a section has a
 * tinted background.
 */
.ocf-card {
	background-color: #fff;
	border: 1px solid var(--ocf-line);
	border-radius: var(--ocf-r-card);
	/*
	 * The photograph sits inset with a radius of its own rather than running to
	 * the card's edges. It costs 14px of width and buys the thing that makes a
	 * grid of cards read as objects rather than as a wall: a margin of white all
	 * the way round each one, so the eye can find the edges.
	 */
	padding: 14px;
	/*
	 * No height: 100% here. The card IS the column, and a definite cross size on
	 * a flex item switches off the stretch that equalises a row — measured: the
	 * four "why choose us" cards came out 200/178/154/178 with it, and 200 each
	 * without. The service cards happened to match anyway because every one of
	 * them carries a two-line description, which is exactly the kind of accident
	 * that hides a bug until the copy changes.
	 */
	transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

/* Red, not ink: hover is the one place a card is doing something, and the
   action colour is what says so. */
.ocf-card:hover {
	border-color: var(--ocf-red);
	box-shadow: 0 8px 24px rgba(21, 51, 43, 0.09);
}

.ocf-card__body {
	padding: 16px 8px 6px;
}

.ocf-card h3,
.ocf-card h4 {
	margin-top: 0;
	margin-bottom: 8px;
}

.ocf-card p {
	margin-bottom: 0;
	font-size: 16px;
	line-height: 1.5;
	color: var(--ocf-ink-soft);
}

.ocf-card a {
	text-decoration: none;
}

/*
 * The heading is the card's link, so it is a control, not a phrase inside a
 * sentence — and at a 20px line box it was a 20px tap target. inline-block plus
 * a little vertical padding takes the box past the 24px minimum without moving
 * the text or changing the line rhythm.
 */
.ocf-card h3 a,
.ocf-card h4 a,
.ocf-linklist h3 a {
	display: inline-block;
	padding-block: 3px;
}

.ocf-card h3 a,
.ocf-card h4 a {
	color: var(--ocf-ink);
}

.ocf-card:hover h3 a,
.ocf-card:hover h4 a {
	color: var(--ocf-red);
}

/* ---------------------------------------------------------------------------
 * The tinted band's texture
 * ---------------------------------------------------------------------------
 * A very faint line grid behind the alternating sections. It exists to stop a
 * large flat tint from reading as an empty area — at 4% opacity it is not
 * something a visitor notices, only something they would miss.
 *
 * Drawn as a data URI rather than a file: two triangles of line work are a few
 * hundred bytes inline against a request plus a cache entry, and it can never
 * go missing from the upload.
 */
.wp-block-group.has-mist-background-color {
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='120' height='104' viewBox='0 0 120 104'%3E%3Cg fill='none' stroke='%2315332b' stroke-opacity='0.055' stroke-width='1'%3E%3Cpath d='M0 0 L60 104 L120 0 Z'/%3E%3Cpath d='M60 0 L120 104'/%3E%3Cpath d='M60 0 L0 104'/%3E%3Cpath d='M0 52 L120 52'/%3E%3C/g%3E%3C/svg%3E");
	background-size: 120px 104px;
}

/* ---------------------------------------------------------------------------
 * Card images
 * ---------------------------------------------------------------------------
 * The frame decides the shape, not the file. Without this, a portrait photo
 * makes its card taller than the two beside it and the row stops being a row —
 * which is exactly what happened the first time a real photograph replaced a
 * placeholder.
 *
 * What this means for photography: upload whatever the phone took. Landscape
 * needs no thought; a portrait shot is centre-cropped, so keep the fence in the
 * middle of the frame. Nothing needs resizing by hand.
 */
.ocf-media {
	overflow: hidden;
	border-radius: var(--ocf-r-media);
}

.ocf-media img {
	display: block;
	width: 100%;
	height: auto;
	aspect-ratio: 4 / 3;
	object-fit: cover;
	object-position: center;
	transition: transform 0.45s ease;
}

.ocf-media:hover img {
	transform: scale(1.04);
}

/* Inset inside the card's padding, so it carries the card's radius rather than
   the larger free-standing photo one. */
.ocf-card .ocf-media,
.ocf-card .ocf-media img {
	border-radius: var(--ocf-r-card);
}

/*
 * The two-column image beside body copy is a different job: there the picture
 * sits next to a paragraph whose length it cannot know, so a taller frame
 * balances the pair better than a card crop would.
 */
.ocf-feature .ocf-media img {
	aspect-ratio: 3 / 2;
}

@media (prefers-reduced-motion: reduce) {
	.ocf-media img { transition: none; }
	.ocf-media:hover img { transform: none; }
}

/* --------------------------------------------------------------- gallery */

/*
 * Finished work, at the size where the workmanship is visible. A gallery of
 * thumbnails proves nothing; four larger frames do.
 */
.ocf-gallery {
	display: grid;
	grid-template-columns: repeat(4, 1fr);
	gap: 16px;
}

.ocf-gallery img {
	display: block;
	width: 100%;
	height: auto;
	aspect-ratio: 4 / 5;
	object-fit: cover;
	border-radius: var(--ocf-r-media);
}

@media (max-width: 900px) {
	.ocf-gallery { grid-template-columns: repeat(2, 1fr); }
}

/* ------------------------------------------------------------------- steps */

/*
 * The number is content, not ornament: it tells the reader how many steps there
 * are before they commit to reading any of them.
 */
.ocf-step__n {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 44px;
	height: 44px;
	margin: 0 0 14px;
	font-size: 18px;
	font-weight: 700;
	line-height: 1;
	color: #fff;
	background-color: var(--ocf-red);
	border-radius: 50%;
}

.ocf-step h3 {
	margin-top: 0;
}

/* --------------------------------------------------------------- link list */

/*
 * Fifteen illustrated cards would be a wall. Fifteen linked lines with one
 * sentence each can be read in the time it takes to scroll past them.
 *
 * The rule sits on the item, not on the link. An underline on an inline <a>
 * is painted per line box, so a two-line title gets a stray line under its
 * second half and nothing under the first.
 */
.ocf-linklist > * {
	border-top: 1px solid var(--ocf-line);
	padding-top: 14px;
	margin-bottom: 18px;
}

.ocf-linklist h3 {
	margin: 0 0 5px;
	font-size: 19px;
	line-height: 1.25;
}

.ocf-linklist h3 a {
	color: var(--ocf-ink);
	text-decoration: none;
}

.ocf-linklist > *:hover {
	border-top-color: var(--ocf-red);
}

.ocf-linklist h3 a:hover,
.ocf-linklist h3 a:focus-visible {
	color: var(--ocf-red);
}

.ocf-linklist p {
	margin: 0;
	font-size: 16px;
	line-height: 1.5;
	color: var(--ocf-ink-soft);
}

/* ---------------------------------------------------------- the form slot */

/*
 * A marker, not a design. WordPress has no form of its own, so this is where
 * the shortcode from whichever form plugin gets installed goes. Styled as an
 * obvious placeholder so it cannot be mistaken for finished work and shipped.
 */
.ocf-formslot {
	background-color: var(--ocf-mist);
	border: 2px dashed var(--ocf-line);
	border-radius: var(--ocf-r-card);
	padding: 30px 28px;
}

/* ---------------------------------------------------------------------------
 * Reviews
 * ---------------------------------------------------------------------------
 * The shell only. Real reviews come from a Google Reviews widget dropped into
 * this slot — writing testimonials would be a fabricated endorsement, which is
 * illegal in California and an FTC matter besides, and it is the one thing on a
 * contractor site a visitor can check in ten seconds.
 * --------------------------------------------------------------------------- */

.ocf-rating {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 12px;
	margin-bottom: 8px;
	font-weight: 700;
	color: var(--ocf-ink);
}

/* The score is the number a visitor is looking for, so it is set at the size of
   one: big enough to read from the scroll, not so big it outruns the heading
   above it. */
.ocf-rating__score {
	font-size: 44px;
	line-height: 1;
	letter-spacing: -0.02em;
}

.ocf-rating__stars {
	color: var(--ocf-gold);
	letter-spacing: 0.1em;
	font-size: 22px;
}

/* The reviews panel is a real panel now, not a placeholder: solid border rather
   than the dashed outline that marks a slot waiting to be filled. */
.ocf-reviewpanel {
	border: 1px solid var(--ocf-line);
	border-radius: var(--ocf-r-card);
	background-color: #fff;
	padding: 38px 30px;
	text-align: center;
}

.ocf-reviewpanel .wp-block-buttons {
	margin-top: 26px;
	margin-bottom: 0;
}

/* Two kinds of small print, one treatment.

   .ocf-note is a demo note: visible to the site owner in the editor and on the
   page, and unmistakably not part of the copy. Every one of these is a line
   that has to be replaced before launch.

   .ocf-fineprint is the opposite — a line that stays. A disclaimer under a
   summary of a statute, for instance. It looks the same because it reads the
   same way: quieter than the copy, and clearly an aside to it. Keeping them
   apart matters when someone sweeps the site for notes to remove. */
.ocf-note,
.ocf-fineprint {
	margin-top: 14px;
	padding: 10px 12px;
	border-left: 3px solid var(--ocf-gold);
	background-color: var(--ocf-mist);
	color: var(--ocf-muted);
	font-size: 13px;
	line-height: 1.45;
}

/* --------------------------------------------------------------- panels */

/* A quiet boxed aside: contact details, an office address, a founder's note. */
.ocf-panel {
	background-color: #fff;
	border: 1px solid var(--ocf-line);
	border-radius: var(--ocf-r-card);
	padding: 30px 28px;
	height: 100%;
}

.ocf-panel h2,
.ocf-panel h3 {
	margin-top: 0;
}

.ocf-panel ul {
	margin: 0 0 22px;
	padding: 0;
	list-style: none;
}

.ocf-panel li {
	position: relative;
	padding-left: 26px;
	margin-bottom: 10px;
	font-size: 16px;
	line-height: 1.45;
	color: var(--ocf-ink-soft);
}

.ocf-panel li::before {
	content: "";
	position: absolute;
	left: 0;
	top: 7px;
	width: 12px;
	height: 6px;
	border-left: 2.5px solid var(--ocf-red);
	border-bottom: 2.5px solid var(--ocf-red);
	transform: rotate(-45deg);
}

.ocf-panel .wp-block-buttons {
	margin-bottom: 0;
}

.ocf-panel--center {
	text-align: center;
}

/* ---------------------------------------------------------------------------
 * The hero strip
 * ---------------------------------------------------------------------------
 * Three boxes of one height. They carry different things — a paragraph, a
 * rating, a photograph — and left to themselves each sized to its own contents,
 * which read as three unrelated boxes that happen to sit in a row.
 *
 * The columns already stretch; what was missing is that the contents did not
 * fill the stretched column. So the panels take the column's height, and the
 * photograph fills its own with object-fit rather than setting the row height
 * from its aspect ratio.
 */
.ocf-herostrip .wp-block-column {
	display: flex;
}

.ocf-herostrip .wp-block-column > * {
	flex: 1;
	min-height: 240px;
	margin-block: 0;
}

/* The photograph takes the panels' radius, not the larger free-standing one:
   in a row of three boxes, one corner radius that disagrees with the other two
   is exactly the kind of half-millimetre difference that reads as sloppy
   without being nameable. */
.ocf-herostrip .wp-block-image {
	overflow: hidden;
	border-radius: var(--ocf-r-card);
}

.ocf-herostrip .wp-block-image img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	object-position: center;
}

/* The rating sits in the middle of its panel rather than at the top: it is
   three short lines in a box sized by the paragraph next to it, and pinned to
   the top it would leave a pool of white underneath. */
.ocf-herostrip .ocf-panel--center {
	display: flex;
	flex-direction: column;
	justify-content: center;
}

@media (max-width: 781px) {
	/* Stacked, a 240px floor on a box holding two lines is just empty space. */
	.ocf-herostrip .wp-block-column > * { min-height: 0; }
	.ocf-herostrip .wp-block-image img { height: auto; aspect-ratio: 16 / 10; }
}

/* Two panels side by side should end on the same line. */
.ocf-contact-cards > .wp-block-column > .wp-block-group {
	height: 100%;
}

/* ----------------------------------------------------------- city pills */

.ocf-cities .wp-block-button__link {
	border: 1px solid rgba(255, 255, 255, 0.28);
	background-color: transparent;
	color: #fff;
	font-weight: 500;
	text-transform: none;
	padding: 9px 18px;
	font-size: 15px;
	border-radius: var(--ocf-r-pill);
}

.ocf-cities .wp-block-button__link:hover {
	background-color: var(--ocf-red);
	border-color: var(--ocf-red);
}

/*
 * The same pills on a light band. Same specificity as the rule above, so this
 * has to sit after it — declared further up the file it lost on source order
 * and rendered white on white.
 */
.ocf-cities--light .wp-block-button__link {
	border-color: var(--ocf-line);
	color: var(--ocf-ink);
	background-color: #fff;
}

.ocf-cities--light .wp-block-button__link:hover {
	background-color: var(--ocf-red);
	border-color: var(--ocf-red);
	color: #fff;
}

/* ---------------------------------------------------------------------------
 * The enquiry form
 * ---------------------------------------------------------------------------
 * Contact Form 7 prints bare inputs and leaves the styling to the theme. These
 * rules are scoped to the panel the form sits in rather than applied to every
 * input on the site, so the search field and anything a plugin adds later are
 * left alone.
 *
 * One column, labels above fields. A two-column form looks tidier and is
 * measurably slower to fill: the eye has to travel back up and across for every
 * field.
 */
.ocf-formpanel label {
	display: block;
	margin-bottom: 16px;
	font-weight: 600;
	font-size: 15px;
	color: var(--ocf-ink);
}

.ocf-formpanel input[type="text"],
.ocf-formpanel input[type="tel"],
.ocf-formpanel input[type="email"],
.ocf-formpanel input[type="number"],
.ocf-formpanel select,
.ocf-formpanel textarea {
	display: block;
	width: 100%;
	margin-top: 6px;
	padding: 12px 14px;
	font-family: inherit;
	font-size: 16px;
	font-weight: 400;
	color: var(--ocf-ink);
	background-color: #fff;
	border: 1px solid var(--ocf-line);
	border-radius: var(--ocf-r-card);
}

/* 16px on the inputs is not a style choice: iOS zooms the whole page in when a
   focused field is smaller than that, and the zoom does not undo itself. */

.ocf-formpanel textarea {
	min-height: 120px;
	resize: vertical;
}

.ocf-formpanel input:focus,
.ocf-formpanel select:focus,
.ocf-formpanel textarea:focus {
	outline: 2px solid var(--ocf-red);
	outline-offset: 1px;
	border-color: var(--ocf-red);
}

.ocf-formpanel .ocf-req {
	color: var(--ocf-red);
}

/* The consent line is a sentence with a checkbox in it, not a field. */
.ocf-formpanel .wpcf7-acceptance .wpcf7-list-item {
	margin: 0;
}

.ocf-formpanel .wpcf7-acceptance label {
	display: flex;
	align-items: flex-start;
	gap: 10px;
	font-weight: 400;
	font-size: 14px;
	color: var(--ocf-ink-soft);
}

.ocf-formpanel .wpcf7-acceptance input {
	width: auto;
	margin-top: 3px;
}

.ocf-formpanel input[type="submit"] {
	width: 100%;
	padding: 16px 28px;
	border: 0;
	border-radius: var(--ocf-r-card);
	background-color: var(--ocf-red);
	color: #fff;
	font-family: inherit;
	font-size: 17px;
	font-weight: 600;
	cursor: pointer;
	transition: background-color 0.15s ease;
}

.ocf-formpanel input[type="submit"]:hover {
	background-color: var(--ocf-red-dark);
}

/* CF7's own status messages, which otherwise arrive as an unstyled block with a
   coloured border in a palette that is not ours. */
.ocf-formpanel .wpcf7-response-output {
	margin: 18px 0 0;
	padding: 14px 16px;
	border-width: 1px;
	border-radius: var(--ocf-r-card);
	font-size: 15px;
}

.ocf-formpanel .wpcf7-not-valid-tip {
	margin-top: 5px;
	font-size: 14px;
	font-weight: 400;
	color: var(--ocf-red);
}

/* The map sits in a panel of its own; an embed has no intrinsic height. */
.ocf-mapslot iframe {
	display: block;
	width: 100%;
	min-height: 320px;
	border: 0;
	border-radius: var(--ocf-r-card);
}

/* --------------------------------------------------------------------- FAQ */

/* Core's details block, styled as an accordion. No plugin needed. */
.wp-block-details {
	border: 1px solid var(--ocf-line);
	border-radius: var(--ocf-r-card);
	background-color: #fff;
	padding: 18px 22px;
	margin-bottom: 12px;
}

.wp-block-details summary {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 16px;
	cursor: pointer;
	list-style: none;
	font-weight: 600;
	font-size: 17px;
	color: var(--ocf-ink);
}

.wp-block-details summary::-webkit-details-marker {
	display: none;
}

.wp-block-details summary::after {
	content: "+";
	flex: none;
	font-size: 1.5em;
	line-height: 1;
	color: var(--ocf-red);
}

.wp-block-details[open] summary::after {
	content: "\2013";
}

.wp-block-details summary:hover {
	color: var(--ocf-red);
}

.wp-block-details > :not(summary) {
	margin-top: 13px;
	max-width: 72ch;
	color: var(--ocf-ink-soft);
}

/* ---------------------------------------------------------------------------
 * Footer
 * ---------------------------------------------------------------------------
 * The footer is the header's bookend, so it is the same forest. Four columns
 * that collapse to two and then one, and a thin line along the bottom.
 *
 * The first column is wider than the other three: it carries the wordmark, a
 * sentence and the phone number, and at an equal quarter it wrapped into a
 * column of five-word lines.
 * --------------------------------------------------------------------------- */

.ocf-footer {
	background-color: var(--ocf-ink);
	color: rgba(255, 255, 255, 0.76);
	font-size: 16px;
}

.ocf-footer__top {
	display: grid;
	grid-template-columns: 1.6fr 1fr 1fr 1.2fr;
	gap: 40px;
	padding-block: 64px 48px;
}

.ocf-footer__title {
	margin: 0 0 18px;
	font-size: 15px;
	font-weight: 700;
	letter-spacing: 0.06em;
	text-transform: uppercase;
	color: #fff;
}

.ocf-footer__list {
	margin: 0;
	padding: 0;
	list-style: none;
}

.ocf-footer__list li {
	margin-bottom: 11px;
	line-height: 1.45;
}

.ocf-footer a {
	color: rgba(255, 255, 255, 0.82);
	text-decoration: none;
}

.ocf-footer a:hover,
.ocf-footer a:focus-visible {
	color: #fff;
	text-decoration: underline;
	text-underline-offset: 3px;
}

/* --------------------------------------------------------- column one */

.ocf-footer .ocf-brand {
	margin-bottom: 18px;
}

.ocf-footer .ocf-brand__mark {
	font-size: 23px;
}

.ocf-footer__blurb {
	margin: 0 0 18px;
	max-width: 42ch;
	line-height: 1.55;
}

.ocf-footer__badges {
	margin: 0 0 18px;
	font-size: 14px;
	color: var(--ocf-gold);
	line-height: 1.6;
}

/* The phone is the largest thing in the footer on purpose: someone who has
   scrolled this far and is still reading is deciding whether to call. */
.ocf-footer__phone {
	display: inline-flex;
	align-items: center;
	gap: 10px;
	font-size: 22px;
	font-weight: 700;
	color: #fff;
	white-space: nowrap;
}

.ocf-footer__phone .ocf-icon {
	width: 19px;
	height: 19px;
	color: var(--ocf-red);
}

/* -------------------------------------------------------- column four */

.ocf-footer__list--plain li {
	margin-bottom: 9px;
}

.ocf-footer .ocf-cta {
	margin-top: 22px;
}

/* An administrator-only nudge, styled as a note rather than as content. */
.ocf-footer__hint {
	margin: 14px 0 0;
	padding: 10px 12px;
	border-left: 3px solid var(--ocf-gold);
	background-color: rgba(255, 255, 255, 0.06);
	font-size: 13px;
	line-height: 1.45;
}

/* ----------------------------------------------------------- the line */

.ocf-footer__bottom {
	border-top: 1px solid rgba(255, 255, 255, 0.14);
}

.ocf-footer__bottominner {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: 8px 28px;
	padding-block: 20px;
	font-size: 14px;
}

.ocf-footer__copy,
.ocf-footer__legal {
	margin: 0;
}

.ocf-footer__legal {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
}

@media (max-width: 1024px) {
	.ocf-footer__top {
		grid-template-columns: 1fr 1fr;
		gap: 36px;
		padding-block: 48px 36px;
	}
}

@media (max-width: 640px) {
	.ocf-footer__top {
		grid-template-columns: 1fr;
		gap: 32px;
	}

	.ocf-footer__bottominner {
		justify-content: flex-start;
	}
}

/* ---------------------------------------------------------------------------
 * The estimate calculator
 * ---------------------------------------------------------------------------
 * Three numbered steps on the left, the running range on the right. The range
 * is sticky on a wide screen: the whole point of a live calculator is watching
 * the number move while you change your mind, and a figure that has scrolled
 * off the top cannot do that.
 *
 * On a phone the panel goes back into the flow and sits at the end, because a
 * bar pinned over a form on a 600px-tall screen takes the space the form needs.
 * --------------------------------------------------------------------------- */

.ocf-calc {
	margin-block: 8px;
}

.ocf-calc__grid {
	display: grid;
	grid-template-columns: 1.55fr 1fr;
	gap: 32px;
	align-items: start;
}

.ocf-calc__step {
	margin: 0 0 26px;
	padding: 26px 26px 22px;
	border: 1px solid var(--ocf-line);
	border-radius: var(--ocf-r-card);
	background-color: #fff;
}

.ocf-calc__step legend {
	display: flex;
	align-items: center;
	gap: 12px;
	padding: 0;
	margin-bottom: 18px;
	font-size: 21px;
	font-weight: 700;
	line-height: 1.2;
	letter-spacing: -0.01em;
	color: var(--ocf-ink);
}

.ocf-calc__n {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	flex: none;
	width: 34px;
	height: 34px;
	border-radius: 50%;
	background-color: var(--ocf-red);
	color: #fff;
	font-size: 16px;
}

/* ------------------------------------------------------------ the types */

.ocf-calc__types {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(170px, 1fr));
	gap: 12px;
}

.ocf-calc__type input {
	position: absolute;
	opacity: 0;
	width: 1px;
	height: 1px;
}

.ocf-calc__typecard {
	display: block;
	height: 100%;
	border: 1px solid var(--ocf-line);
	border-radius: var(--ocf-r-card);
	overflow: hidden;
	cursor: pointer;
	transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.ocf-calc__typecard img {
	display: block;
	width: 100%;
	aspect-ratio: 4 / 3;
	object-fit: cover;
}

.ocf-calc__typebody {
	display: block;
	padding: 12px 14px 14px;
}

.ocf-calc__typename {
	display: block;
	font-weight: 700;
	font-size: 16px;
	line-height: 1.25;
	color: var(--ocf-ink);
}

.ocf-calc__typeblurb {
	display: block;
	margin-top: 4px;
	font-size: 14px;
	line-height: 1.4;
	color: var(--ocf-muted);
}

.ocf-calc__type input:checked + .ocf-calc__typecard {
	border-color: var(--ocf-red);
	box-shadow: 0 0 0 1px var(--ocf-red);
}

/* The keyboard has to be able to see the selection too — the radio itself is
   off-screen, so the ring goes on the card it controls. */
.ocf-calc__type input:focus-visible + .ocf-calc__typecard {
	outline: 2px solid var(--ocf-ink);
	outline-offset: 3px;
}

/* ----------------------------------------------------------- the fields */

.ocf-calc__row {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
	gap: 18px;
}

.ocf-calc__label {
	display: block;
	margin-bottom: 7px;
	font-size: 15px;
	font-weight: 600;
	color: var(--ocf-ink);
}

.ocf-calc input[type="text"],
.ocf-calc input[type="tel"],
.ocf-calc input[type="email"],
.ocf-calc input[type="number"],
.ocf-calc textarea,
.ocf-calc select {
	width: 100%;
	padding: 12px 14px;
	font-family: inherit;
	font-size: 16px;
	color: var(--ocf-ink);
	background-color: #fff;
	border: 1px solid var(--ocf-line);
	border-radius: var(--ocf-r-card);
}

/*
 * OceanWP ships `form input[type="number"] { max-width: 50px; padding: 0 0 0 8px }`.
 * Our rule above sets width and padding but never max-width, so the parent's
 * cap survived: every number field on the calculator was 50px wide with 28px of
 * our own padding inside it, leaving about 22px for the digits and the spinner
 * arrows. "Length in feet" showed a sliver of a number and looked broken,
 * because it was.
 *
 * Undoing the cap rather than raising it: these fields are laid out by the grid
 * they sit in, and a second opinion about their width is what caused this.
 */
.ocf-calc input[type="number"],
.ocf-formpanel input[type="number"],
.entry form input[type="number"] {
	max-width: 100%;
}

.ocf-calc input:focus,
.ocf-calc textarea:focus,
.ocf-calc select:focus {
	outline: 2px solid var(--ocf-red);
	outline-offset: 1px;
	border-color: var(--ocf-red);
}

.ocf-calc__help {
	margin: 7px 0 0;
	font-size: 14px;
	line-height: 1.45;
	color: var(--ocf-muted);
}

.ocf-calc__chips {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
}

.ocf-calc__chip {
	padding: 10px 16px;
	border: 1px solid var(--ocf-line);
	border-radius: var(--ocf-r-pill);
	background: #fff;
	font-family: inherit;
	font-size: 15px;
	font-weight: 600;
	color: var(--ocf-ink);
	cursor: pointer;
}

.ocf-calc__chip.is-on {
	background-color: var(--ocf-ink);
	border-color: var(--ocf-ink);
	color: #fff;
}

.ocf-calc__check {
	display: flex;
	align-items: flex-start;
	gap: 11px;
	margin-top: 14px;
	font-size: 16px;
	line-height: 1.45;
	color: var(--ocf-ink-soft);
	cursor: pointer;
}

.ocf-calc__check input {
	margin-top: 3px;
	width: 18px;
	height: 18px;
	flex: none;
	accent-color: var(--ocf-red);
}

/* A field for robots. Off-screen rather than display:none, which some bots
   check for. */
.ocf-calc__hp {
	position: absolute !important;
	left: -9999px;
	width: 1px;
	height: 1px;
	overflow: hidden;
}

/* ---------------------------------------------------------- the drawing */

.ocf-calc__draw {
	margin-top: 22px;
	padding-top: 22px;
	border-top: 1px solid var(--ocf-line);
}

.ocf-calc__drawhead h3 {
	margin: 0 0 6px;
	font-size: 18px;
}

.ocf-calc__drawhead p {
	margin: 0 0 14px;
	font-size: 15px;
	line-height: 1.5;
	color: var(--ocf-ink-soft);
}

.ocf-calc__canvaswrap {
	border: 1px solid var(--ocf-line);
	border-radius: var(--ocf-r-card);
	overflow: hidden;
	background-color: #fff;
}

/*
 * touch-action is deliberately `manipulation`, not `none`.
 *
 * `none` tells the browser that this element handles every touch gesture
 * itself, which includes the one gesture it must not handle: panning. The
 * canvas fills 39% of a phone screen, so a swipe that started anywhere on the
 * drawing area did nothing at all and the page looked frozen.
 *
 * `manipulation` keeps panning and pinch-zoom with the browser and only drops
 * double-tap-to-zoom, which is what removes the 300ms delay before a tap
 * registers. Taps still reach the click handler; scrolling still scrolls.
 */
.ocf-calc__canvaswrap canvas {
	display: block;
	width: 100%;
	cursor: crosshair;
	touch-action: manipulation;
}

.ocf-calc__drawbar {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 12px 18px;
	margin-top: 14px;
}

.ocf-calc__scale {
	display: inline-flex;
	align-items: center;
	gap: 9px;
	font-size: 15px;
	font-weight: 600;
	color: var(--ocf-ink);
}

.ocf-calc__scale select {
	width: auto;
	padding: 8px 12px;
}

.ocf-calc__drawtotal {
	margin: 0;
	margin-right: auto;
	font-size: 17px;
	font-weight: 700;
	color: var(--ocf-red);
}

.ocf-calc__drawbtns {
	display: inline-flex;
	flex-wrap: wrap;
	gap: 8px;
}

.ocf-calc__ghost {
	padding: 9px 16px;
	border: 1px solid var(--ocf-line);
	border-radius: var(--ocf-r-card);
	background: #fff;
	font-family: inherit;
	font-size: 14px;
	font-weight: 600;
	color: var(--ocf-ink);
	cursor: pointer;
}

.ocf-calc__ghost:hover {
	border-color: var(--ocf-ink);
}

/* ----------------------------------------------------------- the result */

.ocf-calc__side {
	display: flex;
	flex-direction: column;
	gap: 18px;
}

/*
 * Not sticky, and that is the second time this box has been told so.
 *
 * Sticking the whole aside did almost nothing: it was 1090px of a 1351px
 * column, so it travelled 261px and then scrolled away with everything else.
 * Sticking the result box alone gave it the contact form's height to travel
 * through — and that is exactly the problem, because travelling through the
 * form means being painted on top of it. A price panel sitting over the name
 * and phone fields is worse than a price panel that scrolls away.
 *
 * Sticky cannot push a sibling aside; it can only overlap it. So for the price
 * to follow the page without covering anything, the contact fields would have
 * to leave this column — which would also put the price after the submit button
 * on a phone, where the single column stacks in DOM order. Not worth it. The
 * price sits at the top of the column, beside the choices that change it.
 */
.ocf-calc__result {
	padding: 26px 24px;
	border-radius: var(--ocf-r-card);
	background-color: var(--ocf-ink);
	color: rgba(255, 255, 255, 0.82);
}

.ocf-calc__resultlabel {
	margin: 0 0 6px;
	font-size: 13px;
	font-weight: 600;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	color: var(--ocf-gold);
}

.ocf-calc__range {
	margin: 0 0 18px;
	font-size: 34px;
	font-weight: 800;
	line-height: 1.1;
	letter-spacing: -0.02em;
	color: #fff;
}

.ocf-calc__lines {
	margin: 0 0 16px;
	padding: 0;
	list-style: none;
	border-top: 1px solid rgba(255, 255, 255, 0.16);
}

.ocf-calc__lines li {
	display: flex;
	justify-content: space-between;
	gap: 14px;
	padding: 9px 0;
	border-bottom: 1px solid rgba(255, 255, 255, 0.1);
	font-size: 14px;
	line-height: 1.4;
}

.ocf-calc__lines li span:last-child {
	white-space: nowrap;
	font-weight: 600;
	color: #fff;
}

.ocf-calc__caveat {
	margin: 0;
	font-size: 13px;
	line-height: 1.5;
	color: rgba(255, 255, 255, 0.62);
}

.ocf-calc__contact {
	padding: 26px 24px;
	border: 1px solid var(--ocf-line);
	border-radius: var(--ocf-r-card);
	background-color: #fff;
}

.ocf-calc__contact h3 {
	margin: 0 0 16px;
	font-size: 20px;
}

.ocf-calc__contact input,
.ocf-calc__contact textarea {
	margin-bottom: 14px;
}

.ocf-calc__submit {
	width: 100%;
	padding: 16px 24px;
	border: 0;
	border-radius: var(--ocf-r-card);
	background-color: var(--ocf-red);
	color: #fff;
	font-family: inherit;
	font-size: 17px;
	font-weight: 600;
	cursor: pointer;
	transition: background-color 0.15s ease;
}

.ocf-calc__submit:hover {
	background-color: var(--ocf-red-dark);
}

.ocf-calc__banner {
	margin-bottom: 22px;
	padding: 16px 18px;
	border-radius: var(--ocf-r-card);
	font-size: 16px;
	line-height: 1.5;
}

.ocf-calc__banner--ok {
	background-color: var(--ocf-mist);
	border-left: 4px solid var(--ocf-ink);
	color: var(--ocf-ink);
}

.ocf-calc__banner--bad {
	background-color: #FDF2EC;
	border-left: 4px solid var(--ocf-red);
	color: var(--ocf-ink);
}

@media (max-width: 1024px) {
	.ocf-calc__grid {
		grid-template-columns: 1fr;
		gap: 22px;
	}

	.ocf-calc__side {
		position: static;
	}
}

@media (max-width: 560px) {
	.ocf-calc__step {
		padding: 20px 18px 18px;
	}

	.ocf-calc__range {
		font-size: 28px;
	}
}

/* ---------------------------------------------------------------------------
 * Compatibility with pages built before the redesign
 * ---------------------------------------------------------------------------
 * A pattern is copied into a page when it is inserted, so every page built
 * before v2.0.0 still carries the old colour slugs in its markup: navy, ground,
 * copper. Those slugs no longer exist in theme.json, and WordPress prints no
 * rule at all for a slug it does not know — so those sections lost their
 * background entirely. On the contact page that meant white text on white: a
 * hero that was, in practice, blank.
 *
 * This maps the old names onto the current palette so no page is broken while
 * it waits its turn to be re-pasted. It is a bridge, not a design: every rule
 * here can be deleted once the last page has been migrated, and nothing new
 * should ever be written against these class names.
 *
 * No !important needed — WordPress only prints preset rules for slugs that
 * exist, so there is nothing here to outrank.
 * --------------------------------------------------------------------------- */

.has-navy-background-color { background-color: var(--ocf-ink); }
.has-navy-mid-background-color { background-color: #304750; }
.has-ground-background-color { background-color: var(--ocf-mist); }
.has-copper-background-color { background-color: var(--ocf-red); }
.has-copper-dark-background-color { background-color: var(--ocf-red-dark); }
.has-line-background-color { background-color: var(--ocf-line); }

.has-navy-color { color: var(--ocf-ink); }
.has-navy-mid-color { color: #304750; }
.has-copper-color { color: var(--ocf-red); }
.has-copper-dark-color { color: var(--ocf-red-dark); }
.has-body-color { color: var(--ocf-ink-soft); }
.has-ground-color { color: var(--ocf-mist); }

/* The old hero card, styled as the panel that replaced it. */
.ocf-quote {
	background-color: #fff;
	border: 1px solid var(--ocf-line);
	border-radius: var(--ocf-r-card);
	padding: 30px 28px;
	height: 100%;
}

.ocf-quote h2,
.ocf-quote h3 {
	margin-top: 0;
}

.ocf-quote ul {
	margin: 0 0 22px;
	padding: 0;
	list-style: none;
}

.ocf-quote li {
	position: relative;
	padding-left: 26px;
	margin-bottom: 10px;
	font-size: 16px;
	line-height: 1.45;
	color: var(--ocf-ink-soft);
}

.ocf-quote li::before {
	content: "";
	position: absolute;
	left: 0;
	top: 7px;
	width: 12px;
	height: 6px;
	border-left: 2.5px solid var(--ocf-red);
	border-bottom: 2.5px solid var(--ocf-red);
	transform: rotate(-45deg);
}

/* ---------------------------------------------------------------- a11y ---- */

.ocf-headerwrap .screen-reader-text {
	position: absolute !important;
	width: 1px;
	height: 1px;
	overflow: hidden;
	clip: rect(1px, 1px, 1px, 1px);
	white-space: nowrap;
}

/* Never remove a focus ring without replacing it. On ink, gold is the only one
   of our colours that clears 3:1 against both the dark header and white. */
.ocf-headerwrap a:focus-visible,
.ocf-headerwrap button:focus-visible,
.ocf-actionbar a:focus-visible {
	outline: 2px solid var(--ocf-gold);
	outline-offset: 3px;
}

.ocf-card a:focus-visible {
	outline: 2px solid var(--ocf-red);
	outline-offset: 3px;
}


/* ---------------------------------------------------------------------------
 * The desktop call button
 * ---------------------------------------------------------------------------
 * The phone action bar stops at 1024px, so a desktop visitor three screens down
 * had no way to ring anyone without scrolling back up. This is that button for
 * a mouse: bottom right, every page, always there.
 *
 * Collapsed to a circle and opening on hover or focus. A permanent bar with the
 * number in it would be read as an advert and sit on the content all day; a
 * circle is a button, and the number is one hover away.
 */

.ocf-callfab {
	display: none;
	position: fixed;
	right: 20px;
	bottom: 20px;
	z-index: 95;
	align-items: center;
	gap: 0;
	height: 60px;
	padding: 0;
	border-radius: var(--ocf-r-pill);
	background-color: var(--ocf-red);
	color: #fff;
	text-decoration: none;
	font-weight: 700;
	font-size: 17px;
	box-shadow: 0 10px 28px rgba(21, 51, 43, 0.28), inset 0 1px 0 rgba(255, 255, 255, 0.22);
}

.ocf-callfab:hover,
.ocf-callfab:focus {
	color: #fff;
}

.ocf-callfab__icon {
	display: flex;
	align-items: center;
	justify-content: center;
	flex: none;
	width: 60px;
	height: 60px;
}

.ocf-callfab .ocf-icon {
	width: 23px;
	height: 23px;
}

/* The label is laid out at full size and clipped to nothing, so opening it is a
   width transition rather than a reflow of the text inside it. */
.ocf-callfab__label {
	max-width: 0;
	overflow: hidden;
	white-space: nowrap;
	opacity: 0;
}

.ocf-callfab:hover .ocf-callfab__label,
.ocf-callfab:focus-visible .ocf-callfab__label {
	max-width: 220px;
	opacity: 1;
	padding-right: 24px;
}

@media (prefers-reduced-motion: no-preference) {
	.ocf-callfab__label {
		transition: max-height 0.2s ease, max-width 0.25s ease, opacity 0.2s ease, padding 0.25s ease;
	}
}

.ocf-callfab:focus-visible {
	outline: 3px solid var(--ocf-ink);
	outline-offset: 3px;
}

@media (min-width: 1025px) {
	.ocf-callfab {
		display: inline-flex;
	}

	/*
	 * OceanWP's back-to-top button is fixed at right:10px bottom:10px, which is
	 * underneath this one. Stack them instead of overlapping: call at the
	 * bottom, where the thumb and the cursor already are, back-to-top above it.
	 */
	body a#scroll-top.scroll-top-right {
		bottom: 96px;
	}
}

/* ---------------------------------------------------------------------------
 * Actions on a phone
 * ---------------------------------------------------------------------------
 * Two buttons side by side become two buttons of different widths stacked in a
 * ragged left-hand column the moment they stop fitting — which is what the hero
 * looked like on a 390px screen. Full width instead: equal, unmissable, and a
 * tap target the width of the thumb's reach rather than the width of whatever
 * words happen to be on it.
 */
@media (max-width: 560px) {
	.entry .wp-block-buttons {
		gap: 12px;
	}

	.entry .wp-block-buttons > .wp-block-button {
		flex: 1 0 100%;
	}

	.entry .wp-block-button__link {
		display: block;
		width: 100%;
		text-align: center;
	}
}

/* ---------------------------------------------------------------------------
 * Length on a phone
 * ---------------------------------------------------------------------------
 * The home page runs to roughly 17,000px on a 390px screen — twenty-one
 * screenfuls, most of it photographs cropped 4:3 in a single column. A wider
 * crop shows the same fence and gives back about 90px per card, which is around
 * two screenfuls across the page. The pictures are of long horizontal things;
 * they lose nothing by being wide.
 */
@media (max-width: 560px) {
	.ocf-card .ocf-media img,
	.ocf-feature .ocf-media img {
		aspect-ratio: 16 / 10;
	}
}
