/* Ri Cruden new site: styles theme.json cannot express.
   Colours come from the theme.json palette (--wp--preset--color--*). */

:root {
	--ric-ease: cubic-bezier(0.22, 1, 0.36, 1);
	--ric-navy: var(--wp--preset--color--navy-900);
	--ric-hairline: var(--wp--preset--color--grey-200);
	--ric-gutter: clamp(20px, 4vw, 32px);
}

/* ---------- Focus and motion ---------- */
:where(a, button, input, select, textarea, summary):focus-visible {
	outline: 3px solid var(--wp--preset--color--green-500);
	outline-offset: 2px;
	border-radius: 4px;
}
@media (prefers-reduced-motion: reduce) {
	*, *::before, *::after { transition: none !important; animation: none !important; scroll-behavior: auto !important; }
}

/* ---------- Header ---------- */
.ric-header {
	position: sticky;
	top: 0;
	z-index: 100;
	background: #FFFFFF;
	border-bottom: 1px solid var(--ric-hairline);
}
.admin-bar .ric-header { top: 32px; }
@media (max-width: 782px) { .admin-bar .ric-header { top: 46px; } }
/* Blocks inside the header sit flush; the header handles its own spacing. */
.ric-header > * { margin-block: 0; }

.ric-topbar { background: var(--wp--preset--color--grey-50); border-bottom: 1px solid var(--ric-hairline); }
.ric-topbar__inner {
	max-width: 1200px;
	margin: 0 auto;
	padding: 6px var(--ric-gutter);
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 16px;
	font-size: 13px;
}
.ric-switch { display: flex; gap: 4px; }
/* Pull the links back by their padding so the first label lines up with
   the page text below; a highlighted pill then sits just outside the edge. */
.ric-switch { margin-inline-start: -12px; }
.ric-switch a {
	padding: 6px 12px;
	border-radius: 8px;
	font-weight: 600;
	color: var(--wp--preset--color--grey-700);
	text-decoration: none;
	transition: background 140ms var(--ric-ease), color 140ms var(--ric-ease);
}
.ric-switch a:hover { background: #FFFFFF; color: var(--ric-navy); }
.ric-switch a.is-current { background: var(--ric-navy); color: #FFFFFF; }
.ric-topbar__phone { font-weight: 700; color: var(--ric-navy); text-decoration: none; }

.ric-mainbar { padding: 14px var(--ric-gutter); }
.ric-logo img { --ric-logo-h: 60px; height: var(--ric-logo-h); width: auto; display: block; }
/* The logo file has blank space around the artwork (137px of 732px tall
   in the master file). Pull it left by that amount so the visible logo
   lines up with the page text. The space itself is kept as clear space. */
.ric-logo img { margin-inline-start: calc(var(--ric-logo-h) * -0.187); }
.ric-header .wp-block-navigation { font-weight: 600; font-size: 15px; }
.ric-header .wp-block-navigation a { color: var(--wp--preset--color--grey-700); text-decoration: none; }
.ric-header .wp-block-navigation a:hover,
.ric-header .wp-block-navigation .current-menu-item > a { color: var(--ric-navy); }
.ric-header .wp-block-navigation .current-menu-item > a { box-shadow: inset 0 -2px 0 var(--wp--preset--color--green-500); }

@media (max-width: 600px) {
	.ric-logo img { --ric-logo-h: 46px; }
	.ric-topbar__phone { display: none; }
}

/* ---------- Page layout ---------- */
.ric-main { padding-block: clamp(32px, 5vw, 64px) clamp(64px, 9vw, 112px); }
/* A full-width "More …" band at the end of main sits flush on the footer. */
.ric-main:has(> .ric-section:last-child) { padding-bottom: 0; }
.ric-breadcrumbs ol { list-style: none; margin: 0 0 16px; padding: 0; display: flex; flex-wrap: wrap; gap: 6px; font-size: 13px; color: var(--wp--preset--color--grey-500); }
.ric-breadcrumbs li + li::before { content: "›"; margin-right: 6px; color: var(--wp--preset--color--grey-500); }
.ric-breadcrumbs a { color: var(--wp--preset--color--grey-500); text-decoration: none; }
.ric-breadcrumbs a:hover { color: var(--ric-navy); text-decoration: underline; }

/* ---------- Eyebrow paragraph style ---------- */
.is-style-eyebrow {
	font-size: 13px !important;
	font-weight: 700;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	color: var(--wp--preset--color--green-800);
}
.has-navy-900-background-color .is-style-eyebrow { color: var(--wp--preset--color--green-500); }

/* ---------- Buttons ---------- */
.wp-block-button__link, .cx-btn { transition: background 180ms var(--ric-ease), color 180ms var(--ric-ease), border-color 180ms var(--ric-ease), transform 180ms var(--ric-ease); }
.wp-block-button__link:active, .cx-btn:active { transform: translateY(1px); }
/* Button hover rule: every button turns to the other brand colour.
   Navy, white and white-outline buttons turn green (navy text); green turns navy (white text); navy outline fills navy. */
.wp-block-button.is-style-accent .wp-block-button__link { background: var(--wp--preset--color--green-500); color: var(--ric-navy); }
.wp-block-button.is-style-accent .wp-block-button__link:hover { background: var(--ric-navy); color: #FFFFFF; }
.wp-block-button.is-style-outline .wp-block-button__link { background: transparent; color: var(--ric-navy); border: 1.5px solid var(--ric-navy); }
.wp-block-button.is-style-outline .wp-block-button__link:hover { background: var(--ric-navy); color: #FFFFFF; }

/* Link arrows (added by inc/arrows.php): → page on this site, ↓ same page, ↗ other site or new tab. */
.ric-arr { display: inline-block; margin-left: .5em; font-size: 1.15em; line-height: 1; transition: transform 180ms var(--ric-ease); }
a:hover > .ric-arr, a:focus-visible > .ric-arr { transform: translateX(3px); }
a:hover > .ric-arr--down, a:focus-visible > .ric-arr--down { transform: translateY(3px); }
a:hover > .ric-arr--out, a:focus-visible > .ric-arr--out { transform: translate(2px, -2px); }
@media (prefers-reduced-motion: reduce) { .ric-arr { transition: none; } a:hover > .ric-arr, a:focus-visible > .ric-arr { transform: none; } }

.is-style-rounded-soft img { border-radius: 10px; box-shadow: var(--wp--preset--shadow--md); }

/* ---------- Gateway (placeholder) ---------- */
.ric-gateway { padding: clamp(48px, 8vw, 112px) var(--ric-gutter); }
.ric-choices { gap: 24px !important; margin-top: 40px; }
.ric-choice {
	position: relative;
	padding: clamp(24px, 3vw, 40px);
	border: 1px solid var(--ric-hairline);
	border-radius: 10px;
	background: #FFFFFF;
	box-shadow: var(--wp--preset--shadow--md);
	transition: box-shadow 200ms var(--ric-ease), transform 200ms var(--ric-ease);
}
.ric-choice::before {
	content: "";
	position: absolute;
	inset: 0 0 auto 0;
	height: 4px;
	border-radius: 10px 10px 0 0;
	background: var(--wp--preset--gradient--leaf);
}
.ric-choice:hover { box-shadow: var(--wp--preset--shadow--lg); transform: translateY(-2px); }
/* Whole card is clickable through its button link. */
.ric-choice .wp-block-button__link::after { content: ""; position: absolute; inset: 0; }

/* ---------- News grid ---------- */
.ric-post-grid { gap: 32px !important; }
.ric-post-grid .wp-block-post-featured-image img { border-radius: 10px; }
.ric-meta { font-size: 13px; color: var(--wp--preset--color--grey-500); }
.ric-post-grid .wp-block-post-title a { text-decoration: none; }

/* ---------- Footer ---------- */
.ric-footer {
	background: #FFFFFF;
	border-top: 4px solid var(--wp--preset--color--green-500);
	padding: clamp(40px, 6vw, 72px) var(--ric-gutter) 24px;
	font-size: 15px;
}
.ric-footer__cols { gap: 32px !important; }
.ric-footer__heading {
	font-size: 13px !important;
	letter-spacing: 0.08em;
	margin-bottom: 12px;
}
.ric-footer__links { list-style: none; padding: 0; margin: 0; }
.ric-footer__links li { margin: 0 0 8px; }
.ric-footer a { color: var(--wp--preset--color--grey-700); text-decoration: none; }
.ric-footer a:hover { color: var(--ric-navy); text-decoration: underline; }
.ric-footer__contact { line-height: 1.7; }
.ric-legal {
	margin-top: 40px;
	padding-top: 20px;
	border-top: 1px solid var(--ric-hairline);
	font-size: 13px;
	color: var(--wp--preset--color--grey-500);
}
.ric-legal p { margin: 0; }
.ric-legal a { color: var(--wp--preset--color--grey-500); }

/* ---------- Project and vacancy facts (basic, refined in Phase 4) ---------- */
.ric-lead { font-size: var(--wp--preset--font-size--medium); color: var(--wp--preset--color--grey-700); }
.ric-facts {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
	gap: 16px 24px;
	margin: 24px 0;
	padding: 20px 0;
	border-block: 1px solid var(--ric-hairline);
}
.ric-facts dt { font-size: 13px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--wp--preset--color--green-800); }
.ric-facts dd { margin: 4px 0 0; color: var(--ric-navy); font-weight: 600; }
.ric-gallery { display: grid; grid-template-columns: repeat(var(--n, 3), minmax(0, 1fr)); gap: 16px; margin-block: 40px; }
.ric-gallery img { width: 100%; height: 100%; aspect-ratio: 3 / 2; object-fit: cover; border-radius: 10px; }
.ric-notice { padding: 12px 16px; border-left: 4px solid var(--wp--preset--color--green-500); background: var(--wp--preset--color--grey-50); font-weight: 600; }
.ric-apply { margin-top: 40px; padding: 24px; border-radius: 10px; background: var(--wp--preset--color--green-50); }
.ric-apply h2 { font-size: var(--wp--preset--font-size--large); margin-top: 0; }

/* =====================================================================
   Phase 4: page sections
   ===================================================================== */

/* Sections */
.ric-landing > .wp-block-post-content > *,
.ric-landing > .wp-block-post-content > .alignfull { margin-block: 0; }
.ric-landing__crumbs { padding-top: 24px; }
.ric-landing__crumbs .ric-breadcrumbs ol { margin: 0; }
.ric-section { padding-block: clamp(56px, 8vw, 104px); }
.ric-section--tight { padding-block: clamp(40px, 5vw, 64px); }
.ric-section--grey { background: var(--wp--preset--color--grey-50); }
.ric-section__head { margin-bottom: 32px; }
.ric-section__head > * { margin-block: 0; }
.ric-section__head h2 { margin-top: 8px; }
.ric-section__head p:not(.is-style-eyebrow) { margin-top: 12px; max-width: 640px; }
.ric-section__more { margin-top: 32px; }
.wp-block-post-content > .ric-section + .ric-section:not(.ric-section--grey):not(.ric-cta):not(.ric-section--grey + *) { padding-top: 0; }
.ric-lead { font-size: var(--wp--preset--font-size--medium); max-width: 640px; }

/* Hero */
.ric-hero { padding-block: clamp(32px, 5vw, 64px) clamp(48px, 7vw, 88px); }
.ric-hero h1 { margin-block: 8px 16px; }
.ric-hero__cols { gap: clamp(24px, 4vw, 64px) !important; align-items: center !important; }
.ric-hero__cols img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; }
.ric-hero--simple { padding-bottom: clamp(24px, 4vw, 48px); }

/* Gateway choices (photo cards) */
.ric-gateway { padding-block: clamp(32px, 5vw, 64px) clamp(56px, 8vw, 104px); }
.ric-gateway h1 { margin-block: 8px 16px; }
.ric-choices { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 24px; margin-top: 40px; }
.ric-choices .ric-choice { padding: 0; overflow: hidden; }
.ric-choices .ric-choice > :not(.ric-choice__img) { margin-inline: clamp(24px, 3vw, 36px); }
.ric-choices .ric-choice > .wp-block-buttons { margin-bottom: clamp(24px, 3vw, 36px); }
.ric-choice__img { margin: 0; }
.ric-choice__img img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; display: block; }

/* Service cards */
.ric-service-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 24px; }
.ric-service-card {
	display: flex; flex-direction: column;
	padding: 28px; border: 1px solid var(--ric-hairline); border-radius: 10px; background: #FFFFFF;
	transition: box-shadow 200ms var(--ric-ease), transform 200ms var(--ric-ease);
}
.ric-service-card:hover { box-shadow: var(--wp--preset--shadow--md); transform: translateY(-2px); }
.ric-service-card > * { margin-block: 0; }
.ric-service-card :is(h2, h3) { margin-top: 20px; }
.ric-service-card p { margin-top: 8px; flex: 1; }
.ric-service-card .wp-block-buttons { margin-top: 20px; }
.ric-service-card__mark { margin: 0; width: 56px; height: 56px; padding: 10px; border-radius: 14px; background: var(--wp--preset--color--green-50); }
.ric-service-card__mark img { width: 100%; height: 100%; object-fit: contain; }

/* Figures (published figures only) */
.ric-figures { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 24px; }
.ric-figure { border-left: 3px solid var(--wp--preset--color--green-500); padding-left: 20px; }
.ric-figure > * { margin: 0; }
.ric-figure__num { font-size: var(--wp--preset--font-size--x-large); font-weight: 800; color: var(--ric-navy); line-height: 1.1; }
.ric-figure__label { font-size: 14px; color: var(--wp--preset--color--grey-700); margin-top: 4px; }

/* Steps */
.ric-steps { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 24px; }
.ric-step { background: #FFFFFF; border-radius: 10px; padding: 28px; border-top: 4px solid var(--wp--preset--color--green-500); }
.ric-step > * { margin-block: 0; }
.ric-step p { margin-top: 8px; }

/* FAQ */
.ric-faq { max-width: 820px; border-top: 1px solid var(--ric-hairline); }
.ric-faq .wp-block-details { border-bottom: 1px solid var(--ric-hairline); padding: 0; margin: 0; }
.ric-faq summary {
	cursor: pointer; list-style: none; padding: 20px 40px 20px 0; position: relative;
	font-weight: 700; color: var(--ric-navy); font-size: var(--wp--preset--font-size--medium);
}
.ric-faq summary::-webkit-details-marker { display: none; }
.ric-faq summary::after { content: "+"; position: absolute; right: 4px; top: 50%; transform: translateY(-50%); font-size: 24px; color: var(--wp--preset--color--green-700); }
.ric-faq details[open] summary::after { content: "−"; }
.ric-faq details > p { margin: 0 0 20px; max-width: 680px; }

/* Navy call-to-action band (no logo on navy) */
.ric-cta { background: var(--wp--preset--gradient--ink); color: var(--wp--preset--color--navy-200); }
.ric-cta h2 { color: #FFFFFF; margin-top: 0; }
.ric-cta p { max-width: 640px; }
.ric-cta a:not(.wp-block-button__link) { color: #FFFFFF; }
.wp-block-button.is-style-light .wp-block-button__link { background: #FFFFFF; color: var(--ric-navy); }
.wp-block-button.is-style-light .wp-block-button__link:hover { background: var(--wp--preset--color--green-500); color: var(--ric-navy); }

/* Pills (accreditations) */
.ric-pills { list-style: none; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 10px; }
.ric-pills li { padding: 10px 16px; border: 1px solid var(--ric-hairline); border-radius: 999px; font-weight: 700; color: var(--ric-navy); font-size: 14px; }

/* Split and prose */
.ric-split { gap: clamp(24px, 4vw, 64px) !important; }
.ric-prose > * { max-width: 760px; }
.ric-ticks { list-style: none; padding: 0; }
.ric-ticks li { padding-left: 28px; position: relative; margin-bottom: 10px; }
.ric-ticks li::before { content: ""; position: absolute; left: 0; top: 0.45em; width: 14px; height: 8px; border-left: 3px solid var(--wp--preset--color--green-700); border-bottom: 3px solid var(--wp--preset--color--green-700); transform: rotate(-45deg); }

/* Principles */
.ric-principles { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 20px; }
.ric-principle { background: #FFFFFF; border-radius: 10px; padding: 24px; }
.ric-principle > * { margin-block: 0; }
.ric-principle p { margin-top: 8px; }

/* Contact */
.ric-contact__cols { gap: clamp(24px, 4vw, 64px) !important; }
.ric-contact__cols .wp-block-heading { font-size: 13px; letter-spacing: 0.08em; margin: 24px 0 4px; color: var(--wp--preset--color--green-800); }
.ric-contact__cols .wp-block-column > :is(h2, h3):first-child { margin-top: 0; }
.ric-contact__cols .wp-block-column > p { margin-top: 0; }
.ric-enquiry-wrap .wp-block-heading { margin-top: 0 !important; }

/* Feed: cards */
.ric-cards { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 24px; }
.ric-card__link { display: flex; flex-direction: column; height: 100%; text-decoration: none; color: inherit; border-radius: 10px; background: #FFFFFF; overflow: hidden; box-shadow: var(--wp--preset--shadow--md); transition: box-shadow 200ms var(--ric-ease), transform 200ms var(--ric-ease); }
.ric-card__link:hover { box-shadow: var(--wp--preset--shadow--lg); transform: translateY(-2px); }
.ric-card__img { display: block; aspect-ratio: 3 / 2; background: var(--wp--preset--color--grey-200); overflow: hidden; }
.ric-card__img img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform 400ms var(--ric-ease); }
.ric-card__link:hover .ric-card__img img { transform: scale(1.03); }
.ric-card__noimg { display: block; width: 100%; height: 100%; background: var(--wp--preset--gradient--ink); }
.ric-card__body { display: block; padding: 20px 22px 24px; }
.ric-card__meta { display: block; font-size: 13px; font-weight: 600; color: var(--wp--preset--color--grey-500); margin-bottom: 6px; }
.ric-card__title { margin: 0; font-size: 18px; line-height: 1.25; text-transform: none; letter-spacing: 0; font-weight: 700; color: var(--ric-navy); }
.ric-feed__empty { padding: 24px; border: 1px dashed var(--ric-hairline); border-radius: 10px; color: var(--wp--preset--color--grey-500); text-align: center; }
.ric-feed__pages { display: flex; gap: 16px; align-items: center; justify-content: center; margin-top: 32px; font-weight: 600; }

/* Feed: vacancies */
.ric-jobs { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--ric-hairline); }
.ric-job a, .ric-job__static { display: grid; grid-template-columns: 1fr auto; gap: 4px 16px; padding: 20px 4px; border-bottom: 1px solid var(--ric-hairline); text-decoration: none; color: inherit; }
.ric-job a:hover .ric-job__title { color: var(--wp--preset--color--green-800); }
.ric-job__title { margin: 0; font-size: 18px; text-transform: none; letter-spacing: 0; font-weight: 700; grid-column: 1; }
.ric-job__meta { grid-column: 1; font-size: 14px; color: var(--wp--preset--color--grey-500); }
.ric-job__go { grid-column: 2; grid-row: 1 / span 2; align-self: center; display: inline-grid; place-items: center; width: 36px; height: 36px; border-radius: 50%; background: var(--wp--preset--color--green-50); font-size: 16px; color: var(--wp--preset--color--green-800); transition: transform 160ms var(--ric-ease); }
.ric-job a:hover .ric-job__go { transform: translateX(4px); }
.ric-jobs--more { border-top: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 32px; }
.ric-jobs--more .ric-job { margin: 0; }
.ric-jobs--more .ric-job a { border-top: 0; }

/* Featured vacancy: white panel (title, summary, button) beside a navy panel of facts. */
.ric-jobfeat { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); border-radius: 10px; overflow: hidden; box-shadow: 0 1px 2px rgba(0,20,58,.06), 0 8px 24px rgba(0,20,58,.08); margin-bottom: 24px; background: #FFFFFF; }
.ric-jobfeat__main { padding: 40px; }
.ric-jobfeat__tag { display: inline-block; font-size: 13px; font-weight: 600; color: var(--ric-navy); background: var(--wp--preset--color--green-50); border-radius: 999px; padding: 4px 12px; }
.ric-jobfeat__title { margin: 12px 0 16px; font-size: clamp(22px, 2.2vw, 26px); line-height: 1.1; }
.ric-jobfeat__main p { max-width: 520px; margin: 0 0 24px; }
.ric-jobfeat__btn { display: inline-flex; align-items: center; gap: 8px; font-weight: 700; font-size: 14px; text-decoration: none; color: #FFFFFF; background: var(--ric-navy); border-radius: 10px; padding: 12px 20px; transition: background 140ms var(--ric-ease), transform 140ms var(--ric-ease); }
.ric-jobfeat__btn:hover { background: var(--wp--preset--color--green-500); color: var(--ric-navy); }
.ric-jobfeat__facts { margin: 0; padding: 40px; display: grid; gap: 18px; align-content: center; background: var(--ric-navy); color: var(--wp--preset--color--navy-200); }
.ric-jobfeat__facts > div { margin: 0; }
.ric-jobfeat__facts dt { font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: .08em; color: var(--wp--preset--color--green-500); }
.ric-jobfeat__facts dd { margin: 2px 0 0; font-size: 18px; font-weight: 600; color: #FFFFFF; }
@media (max-width: 900px) {
	.ric-jobfeat { grid-template-columns: 1fr; }
	.ric-jobs--more { grid-template-columns: 1fr; }
}
@media (max-width: 640px) {
	.ric-jobfeat__main, .ric-jobfeat__facts { padding: 28px 22px; }
}

@media (max-width: 781px) {
	.ric-hero__cols .wp-block-column:last-child { order: -1; }
}

/* Related project card on a news story */
.ric-related-project { margin-top: 48px; padding-top: 32px; border-top: 1px solid var(--ric-hairline); }
.ric-related-project .ric-cards { grid-template-columns: minmax(0, 420px); }

/* Grid children: cancel the flow-layout gap margin so items line up. */
.ric-service-grid > *, .ric-choices > *, .ric-steps > *, .ric-figures > *,
.ric-principles > *, .ric-cards > * { margin: 0 !important; }

/* Readable line length without breaking the 1200px alignment:
   pad the right side instead of narrowing (which would centre the text). */
.ric-section > .ric-lead, .ric-cta > p, .ric-prose > p {
	box-sizing: border-box;
	max-width: 1200px;
	/* 100% is the full-width section, so cap it at the 1200px box first:
	   otherwise on very wide screens the padding swallows the text. */
	padding-inline-end: max(0px, calc(min(100%, 1200px) - 680px));
}
.ric-faq { max-width: 1200px; border-top: 0; }

/* Single project / news: main photo at a sensible height. */
.wp-block-post-featured-image.alignwide img { width: 100%; aspect-ratio: 16 / 9; max-height: 620px; object-fit: cover; }
.ric-main > .ric-lead { max-width: var(--wp--style--global--content-size, 760px); }
.ric-faq .wp-block-details { max-width: 820px; }
.ric-faq .wp-block-details:first-child { border-top: 1px solid var(--ric-hairline); }

/* A heading that is an h2 for the page outline but looks like an h3
   (used where a list or panel comes straight after the page title). */
h2.ric-h3 { font-size: 22px; letter-spacing: 0.04em; }

/* Enquiry forms */
.ric-enquiry-wrap { background: var(--wp--preset--color--grey-50); border-radius: 10px; padding: clamp(20px, 3vw, 32px); }
.ric-enquiry-wrap .wp-block-heading { margin-top: 0; }
.ric-form { display: grid; gap: 16px; }
.ric-form p { margin: 0; }
.ric-form__note { color: var(--wp--preset--color--grey-700); font-size: 14px; }
.ric-form label { display: block; font-weight: 700; color: var(--ric-navy); margin-bottom: 6px; }
.ric-form__opt { font-weight: 400; color: var(--wp--preset--color--grey-700); }
.ric-form input[type="text"], .ric-form input[type="email"], .ric-form input[type="tel"], .ric-form select, .ric-form textarea {
	width: 100%; box-sizing: border-box; font: inherit; color: var(--wp--preset--color--grey-700);
	padding: 12px 14px; background: #fff; border: 1px solid #8A92A6; border-radius: 10px;
}
.ric-form textarea { min-height: 150px; resize: vertical; }
.ric-form input:focus-visible, .ric-form select:focus-visible, .ric-form textarea:focus-visible, .ric-form button:focus-visible {
	outline: 3px solid var(--ric-navy); outline-offset: 2px;
}
.ric-form__help, .ric-form__error { display: block; font-size: 14px; margin-top: 6px; }
.ric-form__help { color: var(--wp--preset--color--grey-700); }
.ric-form__error { color: #A61B1B; font-weight: 600; }
.ric-form .has-error input, .ric-form .has-error select, .ric-form .has-error textarea { border-color: #A61B1B; border-width: 2px; }
.ric-form__errors { background: #fff; border-left: 4px solid #A61B1B; border-radius: 4px; padding: 14px 18px; }
.ric-form__errors ul { margin: 6px 0 0; padding-left: 20px; }
.ric-form__errors a { color: #A61B1B; font-weight: 600; }
.ric-form__check { display: grid; grid-template-columns: 22px 1fr; gap: 10px; align-items: start; }
.ric-form__check input { width: 22px; height: 22px; margin: 2px 0 0; accent-color: var(--ric-navy); }
.ric-form__check label { font-weight: 400; color: var(--wp--preset--color--grey-700); margin: 0; }
.ric-form__check.has-error label { color: #A61B1B; font-weight: 600; }
.ric-form__check a { color: var(--ric-navy); }
.ric-form__trap { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.ric-form--sent { background: #fff; border-left: 4px solid var(--wp--preset--color--green-600); border-radius: 4px; padding: 18px 22px; }
.ric-form--sent:focus { outline: none; }
@media (min-width: 700px) {
	.ric-form { grid-template-columns: 1fr 1fr; }
	.ric-form > * { grid-column: 1 / -1; }
	.ric-form__field--text, .ric-form__field--email, .ric-form__field--tel, .ric-form__field--select { grid-column: auto; }
	.ric-form__field--wide { grid-column: 1 / -1; }
}

/* Tables in page text (for example the cookie policy). */
.wp-block-table table { width: 100%; border-collapse: collapse; table-layout: fixed; font-size: 15px; }
.wp-block-table th, .wp-block-table td { text-align: left; vertical-align: top; padding: 12px 14px; border: 1px solid var(--ric-hairline); overflow-wrap: anywhere; }
.wp-block-table th { background: var(--wp--preset--color--grey-50); color: var(--ric-navy); font-weight: 700; }
.wp-block-table code { font-size: 14px; background: none; padding: 0; }
@media (max-width: 600px) { .wp-block-table table { font-size: 14px; } .wp-block-table th, .wp-block-table td { padding: 10px; } }

/* =====================================================================
   Design export (homepage Option A revised 4): video hero, photo tiles,
   service marks, careers and contact bands. Overrides earlier rules.
   ===================================================================== */
:root {
	--ric-leaf: var(--wp--preset--gradient--leaf);
	--ric-shade: linear-gradient(to top, rgba(0,20,58,.88) 0%, rgba(0,20,58,.35) 55%, rgba(0,20,58,.05) 100%);
}

/* Translucent header (the logo still sits on a light ground) and leaf rule on the footer. */
.ric-header { background: rgba(255,255,255,.92); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); }
.ric-footer { border-top: 0; position: relative; }
.ric-footer::before { content: ""; position: absolute; inset: 0 0 auto 0; height: 6px; background: var(--ric-leaf); }

/* Feeds: three across, so three items fill the row. */
.ric-cards { grid-template-columns: repeat(3, minmax(0, 1fr)); }
@media (max-width: 900px) { .ric-cards { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 600px) { .ric-cards { grid-template-columns: minmax(0, 1fr); } }
/* Four cards sit as two rows of two, not three and one. */
@media (min-width: 901px) { .ric-cards:has(> :nth-child(4):last-child) { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

/* Figures: rule on top, as in the design. */
.ric-figure { border-left: 0; border-top: 4px solid var(--wp--preset--color--green-500); padding: 24px 0 0; }
.ric-figure__num { font-size: clamp(40px, 4vw, 52px); letter-spacing: -0.02em; line-height: 1; }
.ric-figure__label { font-size: 15px; font-weight: 600; color: var(--ric-navy); margin-top: 8px; }

/* Button styles */
.wp-block-button.is-style-outline-light .wp-block-button__link { background: transparent; color: #FFFFFF; border: 1.5px solid rgba(255,255,255,.7); }
.wp-block-button.is-style-outline-light .wp-block-button__link:hover { background: #FFFFFF; color: var(--ric-navy); border-color: #FFFFFF; }
.ric-linkrule a { color: inherit; font-weight: 700; font-size: 15px; text-decoration: underline; text-decoration-color: var(--wp--preset--color--green-500); text-decoration-thickness: 2px; text-underline-offset: 6px; transition: color 180ms var(--ric-ease), text-decoration-color 180ms var(--ric-ease); }
.ric-linkrule a:hover { color: var(--wp--preset--color--green-800); text-decoration-color: var(--wp--preset--color--green-800); }

/* ---------- Service marks (play once on scroll, again on hover) ---------- */
.sm { margin: 0; }
.sm img { display: block; width: 100%; height: 100%; object-fit: contain; transform-origin: 50% 50%; }
.sm-wrench img { transform-origin: 30% 70%; }
.js .ric-reveal .sm img { opacity: 0; }
.js .ric-reveal.is-visible .sm img { opacity: 1; }
.is-visible .sm-gear img   { animation: ric-gear-in 1.1s var(--ric-ease) both; }
.is-visible .sm-bolt img   { animation: ric-bolt-in 1.1s var(--ric-ease) both; }
.is-visible .sm-bulb img   { animation: ric-bulb-in 1.2s var(--ric-ease) both; }
.is-visible .sm-wrench img { animation: ric-wrench-in 1.1s var(--ric-ease) both; }
.hov:hover .sm-gear img   { animation: ric-gear-spin 2.4s linear infinite; animation-delay: 0s !important; }
.hov:hover .sm-bolt img   { animation: ric-bolt-flash .7s ease-out both; animation-delay: 0s !important; }
.hov:hover .sm-bulb img   { animation: ric-bulb-glow 1s ease-out both; animation-delay: 0s !important; }
.hov:hover .sm-wrench img { animation: ric-wrench-turn .8s var(--ric-ease) both; animation-delay: 0s !important; }
:is(.ric-chip, .ric-tile):nth-child(2) .sm img { animation-delay: .25s; }
:is(.ric-chip, .ric-tile):nth-child(3) .sm img { animation-delay: .5s; }
:is(.ric-chip, .ric-tile):nth-child(4) .sm img { animation-delay: .75s; }
:is(.ric-chip, .ric-tile):nth-child(5) .sm img { animation-delay: 1s; }
@keyframes ric-gear-in { from { opacity: 0; transform: rotate(-150deg) scale(.6); } to { opacity: 1; transform: none; } }
@keyframes ric-gear-spin { to { transform: rotate(360deg); } }
@keyframes ric-bolt-in { 0% { opacity: 0; transform: translateY(-10px); } 35% { opacity: 1; transform: none; } 45% { opacity: .25; } 55% { opacity: 1; } 65% { opacity: .5; } 75% { opacity: 1; filter: drop-shadow(0 0 10px rgba(81,207,148,.95)); } 100% { opacity: 1; filter: drop-shadow(0 0 0 rgba(81,207,148,0)); } }
@keyframes ric-bolt-flash { 0% { opacity: 1; } 20% { opacity: .25; } 35% { opacity: 1; filter: drop-shadow(0 0 12px rgba(81,207,148,.95)); } 100% { filter: drop-shadow(0 0 0 rgba(81,207,148,0)); } }
@keyframes ric-bulb-in { 0% { opacity: 0; transform: scale(.5); } 60% { opacity: 1; transform: scale(1.08); filter: drop-shadow(0 0 14px rgba(81,207,148,.9)); } 100% { transform: none; filter: drop-shadow(0 0 0 rgba(81,207,148,0)); } }
@keyframes ric-bulb-glow { 0% { filter: drop-shadow(0 0 0 rgba(81,207,148,0)); } 40% { transform: scale(1.08); filter: drop-shadow(0 0 16px rgba(81,207,148,.95)); } 100% { transform: none; filter: drop-shadow(0 0 0 rgba(81,207,148,0)); } }
@keyframes ric-wrench-in { 0% { opacity: 0; transform: rotate(-60deg); } 60% { opacity: 1; transform: rotate(14deg); } 100% { transform: none; } }
@keyframes ric-wrench-turn { 0% { transform: none; } 35% { transform: rotate(-28deg); } 70% { transform: rotate(10deg); } 100% { transform: none; } }
@media (prefers-reduced-motion: reduce) { .sm img { animation: none !important; opacity: 1 !important; } }

/* ---------- Background media (video or photo) with a navy shade ---------- */
.ric-vmedia { position: absolute; inset: 0; max-width: none !important; margin: 0 !important; }
.ric-vmedia__el { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.ric-vmedia__shade { position: absolute; inset: 0; background: var(--ric-shade); }
.ric-vmedia__btn {
	display: none; position: absolute; z-index: 3; top: 20px; right: max(16px, calc((100% - 1200px) / 2));
	padding: 9px 16px; border-radius: 999px; cursor: pointer;
	background: rgba(0,20,58,.65); color: #FFFFFF; border: 1px solid rgba(255,255,255,.55);
	font: 700 13px/1 Montserrat, "Helvetica Neue", Arial, sans-serif;
}
.ric-vmedia__btn:hover { background: rgba(0,20,58,.85); }
.js .ric-vmedia--video .ric-vmedia__btn { display: inline-flex; }
/* Light photos need a stronger shade so the white text keeps 4.5:1. */
.ric-vmedia:not(.ric-vmedia--video) .ric-vmedia__shade { background: linear-gradient(to top, rgba(0,20,58,.94) 0%, rgba(0,20,58,.7) 55%, rgba(0,20,58,.45) 100%); }

/* ---------- Hero over video or photo ---------- */
.ric-vhero {
	position: relative; overflow: hidden; display: flex; align-items: flex-end;
	min-height: clamp(460px, 62vh, 680px); padding-block: 0 !important;
	background: var(--ric-navy); color: #FFFFFF;
}
.ric-vhero::after { content: ""; position: absolute; inset: auto 0 0 0; height: 6px; background: var(--ric-leaf); z-index: 3; }
.ric-vhero__inner { position: relative; z-index: 2; width: 100%; padding-block: 96px 56px; }
.ric-vhero__inner > * { margin-block: 0; }
.ric-vhero h1 { color: #FFFFFF; font-size: clamp(34px, 4.6vw, 64px); line-height: 1.05; max-width: 860px; }
.ric-vhero .is-style-eyebrow { color: var(--wp--preset--color--green-500); }
.ric-vhero .ric-lead { color: var(--wp--preset--color--navy-200); margin-top: 16px; }
.ric-vhero .wp-block-buttons, .ric-vhero .ric-linkrule { margin-top: 28px; }
.ric-vhero .ric-linkrule a { color: #FFFFFF; }
.ric-vhero__marks { display: flex; flex-wrap: wrap; gap: 16px 32px; margin-bottom: 28px !important; }
.ric-chip { display: flex; align-items: center; gap: 12px; margin: 0 !important; }
.ric-chip .sm, .ric-choice__mark, .ric-tile__mark {
	box-sizing: border-box; border-radius: 16px; background: rgba(255,255,255,.08);
	border: 1px solid rgba(81,207,148,.55); backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px);
}
.ric-chip .sm { width: 64px; height: 64px; padding: 14px; flex: none; }
.ric-chip__label { margin: 0 !important; font-size: 13px !important; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: #FFFFFF; }

/* ---------- Audience choices: photo tiles ---------- */
.ric-gateway-choices { padding-block: clamp(24px, 4vw, 48px) 0; }
.ric-choices { margin-top: 0; }
.ric-choices .ric-choice {
	position: relative; display: flex; flex-direction: column; justify-content: flex-end;
	min-height: clamp(340px, 34vw, 460px); padding: 0 0 clamp(24px, 3vw, 36px); border: 0; border-radius: 10px;
	overflow: hidden; background: var(--ric-navy); color: #FFFFFF;
}
.ric-choices .ric-choice::before { inset: auto 0 0 0; height: 4px; border-radius: 0; z-index: 3; }
.ric-choice__img { position: absolute; inset: 0; margin: 0 !important; }
.ric-choice__img img { height: 100%; aspect-ratio: auto; }
.ric-choice__img::after { content: ""; position: absolute; inset: 0; background: linear-gradient(to top, rgba(0,20,58,.94) 0%, rgba(0,20,58,.7) 50%, rgba(0,20,58,.1) 100%); }
.ric-choice > :is(h2, p, .wp-block-buttons) { position: relative; z-index: 2; }
.ric-choice h2 { color: #FFFFFF; margin-bottom: 8px; }
.ric-choice p { color: var(--wp--preset--color--navy-100, #E3E7F1); }
.ric-choice__mark, .ric-tile__mark { position: absolute; top: 24px; left: 24px; z-index: 2; width: 88px; height: 88px; padding: 18px; margin: 0 !important; background: rgba(0,20,58,.55); border: 1.5px solid var(--wp--preset--color--green-500); border-radius: 20px; backdrop-filter: blur(8px); }

/* ---------- Statement ---------- */
.ric-statement-wrap { text-align: center; padding-block: clamp(64px, 9vw, 120px) clamp(32px, 5vw, 64px) !important; }
.ric-statement-wrap .ric-statement { font-size: clamp(22px, 2.3vw, 30px); line-height: 1.5; color: var(--ric-navy); max-width: 920px; margin-inline: auto !important; }

/* ---------- Service photo tiles (full width, tight gaps) ---------- */
.ric-tiles { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 4px; padding: 0; }
.ric-tiles > * { margin: 0 !important; grid-column: span 4; }
.ric-tiles--2 > * { grid-column: span 6; }
.ric-tiles--4 > * { grid-column: span 3; }
.ric-tiles--5 > :nth-child(n+4) { grid-column: span 6; }
@media (max-width: 1100px) {
	.ric-tiles > * { grid-column: span 6 !important; }
	.ric-tiles > :last-child:nth-child(odd) { grid-column: span 12 !important; }
}
@media (max-width: 600px) { .ric-tiles > * { grid-column: span 12 !important; } }
.ric-tile {
	position: relative; display: flex; flex-direction: column; justify-content: flex-end; overflow: hidden;
	aspect-ratio: 3 / 2; min-height: 340px; width: 100%; min-width: 0; padding: 28px; background: var(--wp--preset--color--navy-800); color: #FFFFFF;
}
.ric-tiles--2 > .ric-tile, .ric-tiles--5 > .ric-tile:nth-child(n+4) { aspect-ratio: 2 / 1; }
@media (max-width: 1100px) { .ric-tile { aspect-ratio: auto !important; } }
/* The section heading above the tiles keeps its own space. */
.wp-block-post-content > .ric-section--tight:has(+ .ric-tiles) { padding-top: clamp(40px, 5vw, 64px) !important; }
.ric-tile::before { content: ""; position: absolute; inset: auto 0 0 0; height: 4px; background: var(--ric-leaf); z-index: 3; }
.ric-tile__img { position: absolute; inset: 0; margin: 0 !important; }
.ric-tile__img img { width: 100%; height: 100%; object-fit: cover; transition: transform 400ms var(--ric-ease); }
.ric-tile:hover .ric-tile__img img { transform: scale(1.03); }
.ric-tile__img::after { content: ""; position: absolute; inset: 0; background: linear-gradient(to top, rgba(0,20,58,.94) 0%, rgba(0,20,58,.65) 45%, rgba(0,20,58,.1) 80%); }
.ric-tile > :is(h2, h3, p, .wp-block-buttons) { position: relative; z-index: 2; margin: 0; }
.ric-tile__title { color: #FFFFFF; font-size: 22px; letter-spacing: .04em; }
.ric-tile p { margin-top: 6px; color: var(--wp--preset--color--navy-200); font-size: 15px; }
.ric-tile .wp-block-buttons { margin-top: 14px; }
.ric-tile .wp-block-button__link { padding: 10px 18px; font-size: 14px; }
.ric-tile .wp-block-button__link::after { content: ""; position: absolute; inset: 0; }

/* ---------- Careers band over video ---------- */
.ric-careers { position: relative; overflow: hidden; display: flex; align-items: center; min-height: 600px; padding-block: 0 !important; background: var(--ric-navy); color: #FFFFFF; }
.ric-careers .ric-vmedia__shade { background: linear-gradient(to right, rgba(0,20,58,.92) 0%, rgba(0,20,58,.6) 45%, rgba(0,20,58,.1) 100%); }
.ric-careers__inner { position: relative; z-index: 2; width: 100%; padding-block: 96px; }
.ric-careers__inner > * { max-width: 580px; margin-left: 0 !important; margin-block: 0; }
.ric-careers h2 { color: #FFFFFF; margin: 12px 0 20px; font-size: clamp(30px, 3.4vw, 46px); }
.ric-careers p:not(.is-style-eyebrow) { color: var(--wp--preset--color--navy-200); font-size: 19px; line-height: 1.7; margin-bottom: 24px; }
.ric-careers .is-style-eyebrow { color: var(--wp--preset--color--green-500); }
.ric-careers .ric-pills { margin-bottom: 32px; }
.ric-pills--dark li { background: rgba(255,255,255,.08); border-color: rgba(255,255,255,.18); color: #FFFFFF; }

/* ---------- Accreditations as text ---------- */
.ric-accred { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; justify-content: space-between; gap: 16px 36px; color: var(--wp--preset--color--grey-500); font-weight: 700; font-size: 14px; letter-spacing: .04em; }
.ric-accred li { margin: 0; }
.ric-accred-wrap { padding-block: clamp(40px, 5vw, 64px) !important; }

/* ---------- Contact band: soft green glow ---------- */
.ric-cta { position: relative; overflow: hidden; }
.ric-cta::before { content: ""; position: absolute; right: -160px; top: -200px; width: 560px; height: 560px; border-radius: 50%; background: radial-gradient(circle, rgba(81,207,148,.22) 0%, rgba(81,207,148,0) 70%); pointer-events: none; }
.ric-cta > * { position: relative; }

/* A section straight after a hero keeps its own top space. */
.wp-block-post-content > .ric-vhero + .ric-section { padding-top: clamp(48px, 6vw, 80px) !important; }

/* Social icons (header top bar and footer) */
.ric-topbar__right { display: flex; align-items: center; gap: 16px; }
.ric-social { list-style: none; margin: 0; padding: 0; display: flex; align-items: center; gap: 2px; }
.ric-social li { margin: 0; }
.ric-social a { display: inline-flex; align-items: center; justify-content: center; width: 32px; height: 32px; border-radius: 8px; color: var(--ric-navy); text-decoration: none; transition: background 140ms var(--ric-ease), color 140ms var(--ric-ease); }
.ric-social a:hover { background: #FFFFFF; color: var(--wp--preset--color--green-800); }
.ric-social svg { width: 18px; height: 18px; }
.ric-social--footer { margin-top: 12px; margin-inline-start: -8px; }
.ric-social--footer a { width: 40px; height: 40px; }
.ric-social--footer a:hover { background: var(--wp--preset--color--grey-50); }
.ric-social--footer svg { width: 22px; height: 22px; }

/* Footer accreditation logos (images from assets/images/accreditations/). */
.ric-accred-logos { list-style: none; margin: 32px 0 0; padding: 24px 0 0; border-top: 1px solid var(--ric-hairline); display: flex; flex-wrap: wrap; align-items: center; gap: 16px 28px; }
.ric-accred-logos li { margin: 0; }
.ric-accred-logos img { display: block; height: 36px; width: auto; }

/* ---------- Page head band (news, projects, vacancies, archives) ---------- */
.ric-pagehead { position: relative; background: var(--wp--preset--gradient--ink); color: #FFFFFF; padding-block: clamp(32px, 4vw, 56px) clamp(40px, 5vw, 64px); margin-block: 0 !important; }
.ric-pagehead::after { content: ""; position: absolute; inset: auto 0 0 0; height: 6px; background: var(--ric-leaf); }
.ric-pagehead > * { margin-block: 0; }
.ric-pagehead > * { max-width: 1200px !important; margin-inline: auto !important; }
.ric-pagehead h1 { color: #FFFFFF; margin-top: 8px; text-wrap: balance; }
.ric-pagehead .ric-meta { color: var(--wp--preset--color--green-500); margin-top: 8px; }
.ric-pagehead .ric-breadcrumbs ol, .ric-pagehead .ric-breadcrumbs li + li::before, .ric-pagehead .ric-breadcrumbs a { color: var(--wp--preset--color--navy-200); }
.ric-pagehead .ric-breadcrumbs a:hover { color: #FFFFFF; }
.ric-pagehead .ric-breadcrumbs li[aria-current] { color: #FFFFFF; }
.ric-pagehead + .ric-main { padding-top: clamp(32px, 4vw, 56px); }

/* ---------- Design update: "Home / Business switch" canvas (visual only) ---------- */
/* Navy switch bar with a pill toggle */
.ric-topbar { background: var(--ric-navy); border-bottom: 0; color: #FFFFFF; }
.ric-topbar__inner { padding-block: 8px; }
.ric-switch { margin-inline-start: 0; padding: 4px; gap: 0; border-radius: 999px; background: rgba(255,255,255,.06); border: 1px solid rgba(255,255,255,.2); }
.ric-switch::before { content: none; }
.ric-switch a { display: inline-flex; align-items: center; min-height: 36px; padding: 0 18px; border-radius: 999px; color: #FFFFFF; font-weight: 700; font-size: 14px; }
.ric-switch a:hover { background: rgba(255,255,255,.14); color: #FFFFFF; }
.ric-switch a.is-current { background: #FFFFFF; color: var(--ric-navy); }
.ric-topbar__phone, .ric-topbar a:not(.ric-switch a) { color: #FFFFFF; }
.ric-topbar__right { color: #FFFFFF; }

/* Hero: headline sits low, larger, over a bottom-up navy shade */
.ric-vhero { min-height: clamp(480px, 68vh, 720px); }
.ric-vhero__inner { padding-block: 96px 64px; }
.ric-vhero h1 { font-size: clamp(36px, 5vw, 72px); line-height: 1.02; letter-spacing: -.01em; max-width: 980px; }
.ric-vmedia--video .ric-vmedia__shade { background: linear-gradient(to top, rgba(0,20,58,.9) 0%, rgba(0,20,58,.35) 55%, rgba(0,20,58,.05) 100%); }

/* Section headings larger and tighter */
.ric-section__head h2 { font-size: clamp(32px, 3.6vw, 52px); line-height: 1.02; }

/* Rounder, softer cards and tiles; slower image zoom on hover */
.ric-card__link { border-radius: 12px; box-shadow: var(--wp--preset--shadow--md); }
.ric-tile, .ric-choice { border-radius: 16px; }
.ric-card__img img, .ric-tile__img img { transition: transform 900ms var(--ric-ease); }
.ric-card__link:hover .ric-card__img img, .ric-tile:hover .ric-tile__img img { transform: scale(1.06); }

/* Contact band: ink gradient with a soft leaf-green glow */
.ric-cta { position: relative; overflow: hidden; }
.ric-cta::before { content: ""; position: absolute; right: -160px; top: -200px; width: 560px; height: 560px; border-radius: 50%; background: radial-gradient(circle, rgba(81,207,148,.22) 0%, rgba(81,207,148,0) 70%); pointer-events: none; }
.ric-cta > * { position: relative; }

/* Scroll-linked reveal where the browser supports it; elsewhere everything simply shows */
@supports (animation-timeline: view()) {
	@media (prefers-reduced-motion: no-preference) {
		:is(.ric-tiles, .ric-cards, .ric-figures, .ric-steps, .ric-choices) > *, .ric-section__head { animation: ric-rv-up linear backwards; animation-timeline: view(); animation-range: entry 0% cover 28%; }
	}
}
@keyframes ric-rv-up { from { opacity: 0; transform: translateY(56px); } to { opacity: 1; transform: none; } }
/* Service tiles sit inside the 1200px page box, with the canvas's gap */
.ric-tiles { max-width: 1200px; margin-inline: auto !important; gap: 24px; }

/* ---------- Canvas follow-up: switch label and icons, side badge, steps, footer legal ---------- */
.ric-switchbar { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; }
.ric-switch__label { font-size: 12px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--wp--preset--color--navy-200); }
.ric-switch a { gap: 8px; min-height: 40px; }
.ric-switch:has(.is-current) a:not(.is-current) { color: var(--wp--preset--color--navy-200); font-weight: 600; }
.ric-switch:has(.is-current) a:not(.is-current):hover { color: #FFFFFF; }
.ric-switch a.is-current { background: var(--wp--preset--color--green-500); color: var(--ric-navy); box-shadow: 0 0 0 3px rgba(81,207,148,.25); }
.ric-switch svg { flex-shrink: 0; }
@media (max-width: 600px) { .ric-switch__label { display: none; } }
.ric-brandrow { align-items: center; gap: 20px; }
.ric-brandrow > * { margin-block: 0; }
.ric-sidebadge { display: inline-flex; align-items: center; gap: 8px; padding: 8px 14px; border-radius: 999px; background: var(--wp--preset--color--green-50); border: 1px solid var(--wp--preset--color--green-500); color: var(--ric-navy); font-size: 13px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; white-space: nowrap; }
.ric-sidebadge svg { width: 16px; height: 16px; }
@media (max-width: 782px) { .ric-sidebadge { display: none; } }

/* How it works: open columns with a leaf rule, no white cards */
.ric-steps { gap: 32px; }
.ric-step { background: transparent; border-radius: 0; padding: 24px 0 0; }
.ric-step h3 { text-transform: uppercase; }

/* Footer legal line: centred, with a hairline above */
.ric-legal { justify-content: center !important; text-align: center; gap: 4px 24px; border-top: 1px solid var(--ric-hairline); padding-top: 24px; }
@media (max-width: 600px) { .ric-switch a { padding: 0 12px; white-space: nowrap; font-size: 13px; } .ric-switch svg { display: none; } }

/* Canvas rebuild (0.12.0): large step numbers, numbered routes, section spacing */
.ric-steps { counter-reset: ric-step; }
.ric-step { counter-increment: ric-step; }
.ric-step::before { content: counter(ric-step, decimal-leading-zero); display: block; font-size: clamp(40px, 4vw, 56px); font-weight: 800; line-height: 1; color: var(--wp--preset--color--green-500); margin-bottom: 12px; }
.ric-choices { counter-reset: ric-route; }
.ric-choice { counter-increment: ric-route; }
.ric-choice::after { content: counter(ric-route, decimal-leading-zero); position: absolute; top: 16px; left: 20px; z-index: 3; font-weight: 800; font-size: 14px; letter-spacing: .08em; color: #FFFFFF; }
@media (min-width: 900px) { .ric-choices { grid-template-columns: repeat(3, 1fr); } }
.ric-section .wp-block-columns .wp-block-heading { margin-top: 0; }

/* Footer: which side the visitor is on. */
.ric-footer__here { font-weight: 700; color: var(--ric-navy); }

/* Header: every menu link on one line (the home side has seven). */
@media (min-width: 1280px) {
	.ric-mainbar > * { max-width: 1360px; }
	.ric-header .wp-block-navigation { gap: 20px; font-size: 14px; flex-wrap: nowrap; }
	.ric-header .wp-block-navigation .wp-block-navigation__container { gap: 20px; flex-wrap: nowrap; }
	.ric-header .wp-block-navigation a { white-space: nowrap; }
	.ric-mainbar__right { gap: 20px !important; }
}

/* Funding schemes: banner per scheme, photo left, panel right. */
.ric-feed--funding { max-width: 1216px; width: calc(100% - 2 * var(--ric-gutter)); margin-inline: auto; }
.ric-funds { list-style: none; margin: 0; padding: 0; display: grid; gap: 32px; }
.ric-fund { margin: 0; min-height: 220px; display: grid; grid-template-columns: 0.8fr 1.4fr; border-radius: 10px; overflow: hidden; background: #ECFBF3; box-shadow: 0 8px 24px rgba(0,20,58,.08); }
.ric-fund:not(:has(.ric-fund__img)) { grid-template-columns: 1fr; }
.ric-fund__img { position: relative; }
.ric-fund__img img { position: absolute; inset: 0; display: block; width: 100%; height: 100%; object-fit: cover; }
.ric-fund__panel { padding: clamp(20px, 2.4vw, 32px); display: flex; flex-direction: column; align-items: flex-start; justify-content: center; gap: 12px; color: #333A4A; }
.ric-fund__title { margin: 0; font-size: clamp(20px, 2vw, 26px); line-height: 1.1; color: #00143A; text-transform: uppercase; font-weight: 800; letter-spacing: -.01em; }
.ric-fund__panel p { margin: 0; font-size: 16px; line-height: 1.55; max-width: 620px; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.ric-fund__btn { display: inline-flex; align-items: center; gap: 20px; padding: 4px 4px 4px 22px; border-radius: 999px; background: #00143A; color: #fff !important; font-weight: 700; font-size: 15px; text-decoration: none; transition: background .25s var(--ric-ease); }
.ric-fund__btn:hover { background: var(--wp--preset--color--green-500); color: var(--ric-navy); }
.ric-fund__arrow { width: 38px; height: 38px; border-radius: 50%; background: #fff; color: #00143A; display: grid; place-items: center; font-size: 20px; }
/* Same height for every scheme: the photo fills its box and never sets the height. */
@media (min-width: 901px) { .ric-funds { grid-auto-rows: 1fr; } }
@media (max-width: 900px) { .ric-fund { grid-template-columns: 1fr; min-height: 0; } .ric-fund__img { aspect-ratio: 16 / 9; } }

/* ---------- Project page: subtitle, works, quote, photo viewer ---------- */
.ric-subtitle { margin: 8px 0 0; font-size: var(--wp--preset--font-size--medium); font-weight: 600; color: var(--wp--preset--color--navy-200); }
.ric-photo a { display: block; cursor: zoom-in; }
.ric-photo img, .ric-gallery a { display: block; }
.ric-gallery a, .wp-block-image a[data-ric-photo] { cursor: zoom-in; }
.ric-gallery a:focus-visible, .ric-photo a:focus-visible, .wp-block-image a[data-ric-photo]:focus-visible { outline: 3px solid var(--wp--preset--color--navy-900); outline-offset: 3px; border-radius: 10px; }
.ric-works { box-sizing: border-box; padding-left: 1.25em; }
.ric-works li { margin-bottom: 8px; }
.ric-works li::marker { color: var(--wp--preset--color--green-600); }
.ric-quote { box-sizing: border-box; margin: 32px auto; padding: 20px 24px; border-left: 4px solid var(--wp--preset--color--green-500); background: var(--wp--preset--color--grey-50); border-radius: 0 10px 10px 0; }
.ric-quote blockquote { margin: 0; padding: 0; border: 0; font-size: var(--wp--preset--font-size--medium); font-style: italic; color: var(--wp--preset--color--navy-900); }
.ric-quote blockquote p { margin: 0; }
.ric-quote figcaption { margin-top: 12px; font-size: 14px; font-weight: 700; color: var(--wp--preset--color--grey-700); }
.ric-pdlg { border: 0; padding: 0; background: transparent; max-width: none; max-height: none; width: 100%; height: 100%; color: #fff; overflow: hidden; }
.ric-pdlg::backdrop { background: rgba(0, 20, 58, 0.92); }
.ric-pdlg[open] { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 16px; padding: 56px 16px 24px; box-sizing: border-box; }
.ric-pdlg__fig { margin: 0; display: flex; flex-direction: column; align-items: center; gap: 12px; min-height: 0; max-width: 100%; }
.ric-pdlg__fig img { max-width: 100%; max-height: calc(100vh - 190px); object-fit: contain; border-radius: 10px; }
.ric-pdlg figcaption { font-size: 14px; color: var(--wp--preset--color--navy-200); text-align: center; }
.ric-pdlg__nav { display: flex; align-items: center; gap: 20px; font-weight: 600; }
.ric-pdlg__nav[hidden] { display: none; }
.ric-pdlg button { font: inherit; color: #fff; background: rgba(255, 255, 255, 0.12); border: 1px solid rgba(255, 255, 255, 0.4); border-radius: 10px; cursor: pointer; width: 48px; height: 48px; font-size: 28px; line-height: 1; }
.ric-pdlg button:hover { background: rgba(255, 255, 255, 0.25); }
.ric-pdlg button:focus-visible { outline: 3px solid #fff; outline-offset: 2px; }
.ric-pdlg__x { position: absolute; top: 8px; right: 12px; }
@media (max-width: 781px) { .ric-photo img { height: auto; aspect-ratio: 3 / 2; } }
@media (max-width: 781px) { .ric-gallery { gap: 8px; } .ric-gallery[style*="--n:3"] { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

/* ---------- Apprentice story page ---------- */
.ric-story { margin-block: 8px 48px; }
.ric-story__top { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); gap: clamp(24px, 5vw, 64px); align-items: center; margin-bottom: 40px; }
.ric-story__role, .ric-story__label { margin: 0 0 12px; font-size: 13px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.08em; }
.ric-story__role { color: var(--wp--preset--color--green-800); }
.ric-story__label { color: var(--wp--preset--color--grey-700); margin-bottom: 8px; }
.ric-story__lead { margin: 0 0 28px; font-size: 20px; line-height: 1.5; color: var(--ric-navy); }
.ric-story__words { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.ric-story__words li { margin: 0; background: var(--wp--preset--color--green-50); color: var(--ric-navy); font-weight: 700; border-radius: 999px; padding: 8px 18px; }
.ric-story__photo { margin: 0; }
.ric-story__photo img { display: block; width: 100%; height: auto; aspect-ratio: 4 / 3; object-fit: cover; border-radius: 10px; box-shadow: 0 8px 24px rgba(0,20,58,.12); }
.ric-story__qa { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px; }
.ric-story__card { margin: 0; background: var(--wp--preset--color--grey-50); border-radius: 10px; border-top: 4px solid var(--wp--preset--color--green-500); padding: 24px 28px; }
.ric-story__q { margin: 0 0 8px !important; font-size: 13px !important; font-weight: 700 !important; letter-spacing: 0.08em !important; color: var(--wp--preset--color--green-800) !important; }
.ric-story__card p { margin: 0; }
.ric-story__h { margin-top: 48px; }
.ric-story__advice { box-sizing: border-box; margin-block: 40px; padding: 32px 36px; border-radius: 10px; background: linear-gradient(135deg, #0A1B45, #00143A); color: var(--wp--preset--color--navy-200); }
.ric-story__advice-t { margin: 0 !important; font-size: 13px !important; font-weight: 700 !important; letter-spacing: 0.08em !important; color: var(--wp--preset--color--green-500) !important; }
.ric-story__advice blockquote { margin: 12px 0 0; padding: 0; border: 0; font-size: clamp(22px, 2.4vw, 30px); font-weight: 700; line-height: 1.3; color: #FFFFFF; }
.ric-story__advice blockquote p { margin: 0; }
@media (max-width: 781px) {
	.ric-story__top, .ric-story__qa { grid-template-columns: minmax(0, 1fr); }
	.ric-story__photo { order: -1; }
	.ric-story__advice { padding: 24px 22px; }
}

/* Header: the logo is never squeezed, whichever side's menu is showing. The side badge
   (the top bar already shows the side) goes first when space is short, then the menu
   collapses to the menu button, so nothing is pushed off the screen. */
.ric-logo, .ric-logo a { flex: none; }
.ric-logo img { max-width: none; flex: none; }
@media (max-width: 1399px) { .ric-sidebadge { display: none; } }
@media (min-width: 601px) and (max-width: 1139px) {
	.ric-side-homeowner .ric-header .wp-block-navigation__responsive-container:not(.is-menu-open),
	.ric-side-commercial .ric-header .wp-block-navigation__responsive-container:not(.is-menu-open) { display: none !important; }
	.ric-side-homeowner .ric-header .wp-block-navigation__responsive-container-open,
	.ric-side-commercial .ric-header .wp-block-navigation__responsive-container-open { display: flex !important; }
}
/* A blurred header becomes the box a fixed menu is measured against, which cut the open
   menu down to the height of the header. Switch the blur off while the menu is open. */
.ric-header:has(.wp-block-navigation__responsive-container.is-menu-open) { backdrop-filter: none; -webkit-backdrop-filter: none; }
/* Smallest phones: a smaller logo and button so the header still fits at 320px. */
@media (max-width: 380px) {
	.ric-logo img { --ric-logo-h: 38px; }
	.ric-header-cta .wp-block-button__link { font-size: 13px !important; padding: 9px 12px !important; }
	.ric-mainbar__right { gap: 12px !important; }
}
.ric-header .wp-block-navigation__responsive-container.is-menu-open { padding: 24px var(--ric-gutter); }

/* Projects page: filter buttons (who it is for, and technology). Plain links. */
.ric-filters { display: flex; flex-wrap: wrap; gap: 16px 40px; margin: 0 0 32px; }
.ric-filters__group { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 14px; }
.ric-filters__label { font-size: 13px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--wp--preset--color--grey-700); }
.ric-filters ul { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.ric-filters li { margin: 0; }
.ric-filters__btn { display: inline-block; padding: 8px 16px; border-radius: 999px; font-weight: 600; font-size: 14px; color: var(--ric-navy); background: #FFFFFF; box-shadow: inset 0 0 0 1.5px var(--wp--preset--color--grey-200); text-decoration: none; transition: box-shadow 140ms var(--ric-ease), background 140ms var(--ric-ease), color 140ms var(--ric-ease); }
.ric-filters__btn:hover { box-shadow: inset 0 0 0 1.5px var(--ric-navy); }
.ric-filters__btn.is-active { background: var(--ric-navy); color: #FFFFFF; box-shadow: none; }

/* Close buttons: use the site font, not the browser default. */
.ric-popup__close, .ric-vdlg__x { font-family: inherit; }

/* ---------- Phone and tablet header ---------- */
/* The phone number never wraps in the top bar. */
.ric-topbar__phone { white-space: nowrap; }
/* Menu and close buttons: a 44px touch area around the icon. */
.wp-block-navigation__responsive-container-open, .wp-block-navigation__responsive-container-close { min-width: 44px; min-height: 44px; align-items: center; justify-content: center; }
/* Extra items that only appear inside the opened menu: side switch, phone, button. */
.ric-menu-only { display: none !important; }
.is-menu-open .ric-menu-only { display: block !important; }
.ric-header .is-menu-open .wp-block-navigation-item__content { display: block; padding-block: 11px !important; }
.ric-header .is-menu-open .ric-menu-only--first { margin-top: 12px; padding-top: 12px; border-top: 1px solid var(--wp--preset--color--grey-200); }
.ric-header .is-menu-open .ric-menu-only.is-side .wp-block-navigation-item__content { color: var(--ric-navy); box-shadow: inset 0 -3px 0 var(--wp--preset--color--green-500); }
.ric-header .is-menu-open .ric-menu-only--phone .wp-block-navigation-item__content { font-weight: 800; color: var(--ric-navy); }
.ric-header .is-menu-open .ric-menu-only--cta { margin-top: 8px; }
.ric-header .is-menu-open .ric-menu-only--cta .wp-block-navigation-item__content { display: inline-block; padding: 13px 22px !important; border-radius: 10px; background: var(--wp--preset--color--green-500); color: var(--ric-navy); font-weight: 700; transition: background 180ms var(--ric-ease), color 180ms var(--ric-ease); }
.ric-header .is-menu-open .ric-menu-only--cta .wp-block-navigation-item__content:hover { background: var(--ric-navy); color: #FFFFFF; }
/* Where the menu is a button, only the menu bar stays on screen while scrolling (the top bar
   scrolls away). The header wrappers drop out so the bar sticks to the whole page. */
@media (max-width: 1139px) {
	.wp-site-blocks > header.wp-block-template-part, .ric-header { display: contents; }
	.ric-topbar, .ric-mainbar { margin-block: 0 !important; }
	.ric-mainbar { position: sticky; top: 0; z-index: 100; background: #FFFFFF; border-bottom: 1px solid var(--ric-hairline); }
	.admin-bar .ric-mainbar { top: 32px; }
}
@media (max-width: 782px) { .admin-bar .ric-mainbar { top: 46px; } }
/* Phones: the 44px menu button needs the room back, so the button and gaps tighten. */
@media (max-width: 430px) {
	.ric-header-cta .wp-block-button__link { font-size: 13px !important; padding: 10px 12px !important; }
	.ric-header-cta .ric-arr { display: none; }
	.ric-mainbar__right { gap: 4px !important; }
	.wp-block-navigation__responsive-container-open { margin-inline: -6px; }
}
@media (max-height: 700px) { .ric-header .is-menu-open .wp-block-navigation-item__content { padding-block: 8px !important; } }
.wp-block-navigation__responsive-container-close { display: flex; justify-content: flex-end; margin-inline: 0; }
