/*
 * Block style variations and pattern styles.
 *
 * Enqueued with enqueue_block_assets, so this loads on the front end and inside
 * the block editor canvas, and patterns look the same in both. Front-end-only
 * behaviour (whole-card links) lives in style.css.
 */

/* --------------------------------------------------------------------------
   Paragraph styles
   -------------------------------------------------------------------------- */

p.is-style-eyebrow {
	color: var(--wp--preset--color--blue);
	font-size: var(--wp--preset--font-size--eyebrow);
	font-weight: 600;
	letter-spacing: var(--wp--custom--letter-spacing--eyebrow);
	line-height: 1.2;
	text-transform: uppercase;
}

p.is-style-meta {
	color: var(--wp--preset--color--muted);
	font-family: var(--wp--preset--font-family--mono);
	font-size: var(--wp--preset--font-size--caption);
	font-weight: 500;
	line-height: 1.6;
}

p.has-lead-font-size {
	line-height: 1.5;
}

/* --------------------------------------------------------------------------
   Navy grounds
   Headings white, body text muted, eyebrows blue-500. Preset text colours
   set on a block still win.
   -------------------------------------------------------------------------- */

.has-navy-background-color :is(h1, h2, h3, h4, h5, h6),
.is-style-card-dark :is(h1, h2, h3, h4, h5, h6) {
	color: var(--wp--preset--color--white);
}

.has-navy-background-color :is(p, li) {
	color: var(--wp--preset--color--on-dark-muted);
}

.is-style-card-dark p {
	color: var(--wp--preset--color--white);
}

.has-navy-background-color p.is-style-eyebrow,
.is-style-card-dark p.is-style-eyebrow {
	color: var(--wp--preset--color--blue-500);
}

.has-navy-background-color a:where(:not(.wp-element-button)) {
	color: var(--wp--preset--color--white);
}

/* --------------------------------------------------------------------------
   Cards
   1px border, 8px radius, a hairline of shadow, 32px padding.
   -------------------------------------------------------------------------- */

.wp-block-group:is(.is-style-card, .is-style-card-tint, .is-style-card-dark, .is-style-card-outline) {
	border: 1px solid var(--wp--preset--color--neutral-200);
	border-radius: var(--wp--custom--radius--lg);
	box-shadow: var(--wp--preset--shadow--card);
	padding: var(--wp--preset--spacing--6);
}

.wp-block-group.is-style-card {
	background-color: var(--wp--preset--color--white);
}

.wp-block-group.is-style-card-tint {
	background-color: var(--wp--preset--color--tint);
	border-color: var(--wp--preset--color--tint-200);
}

.wp-block-group.is-style-card-dark {
	background-color: var(--wp--preset--color--navy-700);
	border-color: var(--wp--custom--border--on-dark);
	color: var(--wp--preset--color--white);
}

.wp-block-group.is-style-card-outline {
	background-color: transparent;
	border-color: var(--wp--preset--color--neutral-300);
}

/* Recent finding: the closing mono line sits under a rule. */
.is-style-card-dark > p.is-style-meta:last-child {
	border-top: 1px solid var(--wp--custom--border--on-dark);
	color: rgba(255, 255, 255, .6);
	margin-block-start: 20px;
	padding-top: 14px;
}

/*
 * Pattern headings are selected as .wp-block-heading.kx-… (two classes) so a
 * one-class-plus-element rule from outside the theme, such as a page builder's
 * ".kit h3", can't override their size or line-height.
 */
.wp-block-heading.kx-card-title {
	font-size: 19px;
	letter-spacing: -.01em;
	line-height: 1.35;
}

.wp-block-heading.kx-service-link {
	font-size: 17px;
	letter-spacing: 0;
	line-height: 1.4;
}

.is-style-card .wp-block-heading.kx-service-link + .wp-block-heading.kx-service-link {
	margin-block-start: 8px;
}

:is(.wp-block-heading.kx-card-title, .wp-block-heading.kx-service-link) a {
	color: var(--wp--preset--color--navy);
	text-decoration: none;
}

:is(.wp-block-heading.kx-card-title, .wp-block-heading.kx-service-link) a:hover {
	color: var(--wp--preset--color--blue-700);
}

/* --------------------------------------------------------------------------
   Headings used by the section patterns
   -------------------------------------------------------------------------- */

.kx-section-heading p.has-lead-font-size {
	max-width: 52ch;
}

.wp-block-heading.kx-hero-title {
	letter-spacing: var(--wp--custom--letter-spacing--display, -.022em);
	line-height: var(--wp--custom--line-height--tight, 1.08);
	max-width: 18ch;
	text-wrap: pretty;
}

p.kx-hero-lead {
	max-width: 48ch;
}

p.kx-intro-lead {
	line-height: 1.6;
	max-width: 70ch;
}

.kx-hero-lead + .wp-block-buttons {
	margin-block-start: 32px;
}

.wp-block-heading.kx-band-title {
	font-size: clamp(26px, 2.6vw, 36px);
	font-weight: 700;
	letter-spacing: -.02em;
	line-height: 1.15;
}

.wp-block-heading.kx-band-title + p {
	margin-block-start: 10px;
}

p.kx-band-lead {
	font-size: 18px;
	line-height: 1.55;
	max-width: 50ch;
}

.wp-block-heading.kx-subsection-title {
	font-size: 24px;
	letter-spacing: -.015em;
	line-height: var(--wp--custom--line-height--heading, 1.18);
}

.wp-block-heading.kx-group-title {
	font-size: 22px;
	letter-spacing: -.01em;
	line-height: var(--wp--custom--line-height--heading, 1.18);
}

.wp-block-group.kx-group-header {
	align-items: baseline;
	border-bottom: 1px solid var(--wp--preset--color--tint-200);
	gap: 14px;
	padding-bottom: 14px;
}

.wp-block-group.kx-related {
	border-top: 1px solid var(--wp--preset--color--neutral-200);
	padding-top: 28px;
}

.kx-related .wp-block-buttons {
	gap: 10px;
}

/* --------------------------------------------------------------------------
   Rows: Columns with a hairline under each row
   Consecutive rows share borders; the first in a run gets a top rule.
   -------------------------------------------------------------------------- */

.wp-block-columns.is-style-row {
	border-bottom: 1px solid var(--wp--preset--color--neutral-200);
	margin-bottom: 0;
	padding-block: 18px;
}

.wp-block-columns.is-style-row:not(.is-style-row + .is-style-row) {
	border-top: 1px solid var(--wp--preset--color--neutral-200);
}

.is-style-row + .wp-block-columns.is-style-row {
	margin-block-start: 0;
}

p.kx-row-title {
	color: var(--wp--preset--color--navy);
	font-size: 17px;
	font-weight: 600;
	line-height: 1.4;
}

p.kx-row-title + * {
	margin-block-start: 4px;
}

p.kx-step-number {
	color: var(--wp--preset--color--blue);
	font-family: var(--wp--preset--font-family--mono);
	font-size: 14px;
	font-weight: 700;
	line-height: 1.7;
}

p.kx-stage-number {
	color: var(--wp--preset--color--blue-500);
	font-size: 32px;
	font-weight: 700;
	letter-spacing: -.02em;
	line-height: 1;
}

.wp-block-heading.kx-stage-title {
	font-size: 21px;
	letter-spacing: -.01em;
	line-height: var(--wp--custom--line-height--snug, 1.35);
}

.kx-stage-title ~ p {
	max-width: 72ch;
}

/* --------------------------------------------------------------------------
   Callouts: 2px left rule, tone by style
   -------------------------------------------------------------------------- */

.wp-block-group:is(.is-style-callout-info, .is-style-callout-caution, .is-style-callout-critical, .is-style-callout-quiet) {
	background-color: var(--wp--preset--color--tint);
	border-left: var(--wp--custom--border--rule-strong) solid var(--wp--preset--color--blue);
	border-radius: 0 var(--wp--custom--radius--md) var(--wp--custom--radius--md) 0;
	font-size: var(--wp--preset--font-size--small);
	line-height: 1.6;
	padding: 16px 20px;
}

.wp-block-group.is-style-callout-caution {
	background-color: var(--wp--custom--status--warn--bg);
	border-left-color: var(--wp--custom--status--warn--fg);
}

.wp-block-group.is-style-callout-critical {
	background-color: var(--wp--custom--status--fail--bg);
	border-left-color: var(--wp--custom--status--fail--fg);
}

.wp-block-group.is-style-callout-quiet {
	background-color: var(--wp--preset--color--neutral-50);
	border-left-color: var(--wp--preset--color--neutral-300);
}

.wp-block-group[class*="is-style-callout-"] > * + * {
	margin-block-start: 12px;
}

.wp-block-group[class*="is-style-callout-"] > .kx-callout-title + * {
	margin-block-start: 4px;
}

p.kx-callout-title {
	color: var(--wp--preset--color--navy);
	font-weight: 600;
}

/* --------------------------------------------------------------------------
   FAQ list: Details blocks between hairlines, "+" turning to "×"
   -------------------------------------------------------------------------- */

.wp-block-group.is-style-faq {
	border-top: 1px solid var(--wp--preset--color--neutral-200);
	margin-block-start: 28px;
}

.wp-block-group.is-style-faq > * + * {
	margin-block-start: 0;
}

.is-style-faq .wp-block-details {
	border-bottom: 1px solid var(--wp--preset--color--neutral-200);
}

.is-style-faq .wp-block-details summary {
	align-items: center;
	color: var(--wp--preset--color--navy);
	cursor: pointer;
	display: flex;
	font-size: var(--wp--preset--font-size--h-4);
	font-weight: 600;
	gap: 16px;
	justify-content: space-between;
	list-style: none;
	padding: 18px 0;
}

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

.is-style-faq .wp-block-details summary::after {
	color: var(--wp--preset--color--blue);
	content: "+";
	flex: none;
	font-size: 20px;
	line-height: 1;
	transition: transform var(--wp--custom--motion--dur-base) var(--wp--custom--motion--ease-out);
}

.is-style-faq .wp-block-details[open] summary::after {
	transform: rotate(45deg);
}

.is-style-faq .wp-block-details > :not(summary) {
	margin-block: 0 20px;
	max-width: 66ch;
}

/* --------------------------------------------------------------------------
   Buttons
   Default is the blue secondary; "outline" is quiet. Gold "primary" is for one
   element per page.
   -------------------------------------------------------------------------- */

.wp-block-button.kx-button-lg > .wp-block-button__link {
	font-size: 17px;
	padding: 14px 26px;
}

.wp-block-button.is-style-primary > .wp-block-button__link {
	background-color: var(--wp--preset--color--gold);
	color: var(--wp--preset--color--navy-900);
}

.wp-block-button.is-style-primary > .wp-block-button__link:hover,
.wp-block-button.is-style-primary > .wp-block-button__link:focus,
.wp-block-button.is-style-primary > .wp-block-button__link:active {
	background-color: var(--wp--preset--color--gold-600);
	color: var(--wp--preset--color--navy-900);
}

.wp-block-button.is-style-on-dark > .wp-block-button__link {
	background-color: var(--wp--preset--color--white);
	color: var(--wp--preset--color--navy);
}

.wp-block-button.is-style-on-dark > .wp-block-button__link:hover,
.wp-block-button.is-style-on-dark > .wp-block-button__link:focus,
.wp-block-button.is-style-on-dark > .wp-block-button__link:active {
	background-color: var(--wp--preset--color--tint);
	color: var(--wp--preset--color--navy);
}

.wp-block-button.is-style-pill > .wp-block-button__link {
	background-color: transparent;
	border: 1px solid var(--wp--preset--color--neutral-200);
	border-radius: var(--wp--custom--radius--pill);
	color: var(--wp--preset--color--body);
	font-size: var(--wp--preset--font-size--small);
	font-weight: 400;
	letter-spacing: 0;
	line-height: 1.4;
	padding: 5px 12px;
}

.wp-block-button.is-style-pill > .wp-block-button__link:hover,
.wp-block-button.is-style-pill > .wp-block-button__link:focus,
.wp-block-button.is-style-pill > .wp-block-button__link:active {
	background-color: var(--wp--preset--color--tint);
	border-color: var(--wp--preset--color--blue-500);
	color: var(--wp--preset--color--blue-700);
}

/* --------------------------------------------------------------------------
   Evidence table
   Tinted header, mono cells, hairline rows, never coloured rows. A badge is
   highlighted text: select it, Highlight > Text > a "Severity" colour.
   -------------------------------------------------------------------------- */

.wp-block-table.is-style-evidence {
	background-color: var(--wp--preset--color--white);
	border: 1px solid var(--wp--preset--color--neutral-200);
	border-radius: var(--wp--custom--radius--lg);
}

.wp-block-table.is-style-evidence table {
	border-collapse: collapse;
	font-size: 14px;
	width: 100%;
}

.wp-block-table.is-style-evidence thead {
	border-bottom: 0;
}

.wp-block-table.is-style-evidence :is(th, td) {
	border: 0;
	border-bottom: 1px solid var(--wp--preset--color--neutral-200);
	padding: 14px 16px;
	text-align: left;
	vertical-align: middle;
}

.wp-block-table.is-style-evidence th {
	background-color: var(--wp--preset--color--tint);
	color: var(--wp--preset--color--navy);
	font-size: var(--wp--preset--font-size--eyebrow);
	font-weight: 600;
	letter-spacing: .08em;
	padding-block: 12px;
	text-transform: uppercase;
}

.wp-block-table.is-style-evidence td {
	color: var(--wp--preset--color--body);
	font-family: var(--wp--preset--font-family--mono);
	font-size: var(--wp--preset--font-size--caption);
	overflow-wrap: anywhere;
}

.wp-block-table.is-style-evidence tbody tr:last-child td {
	border-bottom: 0;
}

.wp-block-table.is-style-evidence mark {
	background-color: var(--wp--custom--status--info--bg) !important;
	border-radius: var(--wp--custom--radius--sm);
	color: var(--wp--custom--status--info--fg);
	display: inline-flex;
	font-family: var(--wp--preset--font-family--inter);
	font-size: var(--wp--preset--font-size--caption);
	font-weight: 600;
	letter-spacing: .01em;
	line-height: 1.5;
	padding: 3px 9px;
	white-space: nowrap;
}

.wp-block-table.is-style-evidence mark.has-severity-pass-color {
	background-color: var(--wp--custom--status--pass--bg) !important;
}

.wp-block-table.is-style-evidence mark.has-severity-warn-color {
	background-color: var(--wp--custom--status--warn--bg) !important;
}

.wp-block-table.is-style-evidence mark.has-severity-fail-color {
	background-color: var(--wp--custom--status--fail--bg) !important;
}

/* --------------------------------------------------------------------------
   Audit page
   -------------------------------------------------------------------------- */

p.kx-question {
	color: var(--wp--preset--color--navy);
	font-size: 22px;
	font-weight: 600;
	letter-spacing: -.01em;
	line-height: 1.3;
}

/* Five stages: numbered nodes joined by a hairline down the left. */
.wp-block-columns.kx-step {
	margin-bottom: 0;
	padding-bottom: var(--wp--preset--spacing--7);
	position: relative;
}

.kx-steps > .kx-step + .kx-step {
	margin-block-start: 0;
}

.wp-block-columns.kx-step:not(:last-child)::before {
	background-color: var(--wp--preset--color--neutral-300);
	bottom: 0;
	content: "";
	left: 27.5px;
	position: absolute;
	top: 56px;
	width: 1px;
}

.wp-block-columns.kx-step:last-child {
	padding-bottom: 0;
}

p.kx-step-node {
	align-items: center;
	background-color: var(--wp--preset--color--white);
	border: 1px solid var(--wp--preset--color--blue-100);
	border-radius: 50%;
	box-sizing: border-box;
	color: var(--wp--preset--color--blue);
	display: flex;
	font-size: 21px;
	font-weight: 700;
	height: 56px;
	justify-content: center;
	line-height: 1;
	width: 56px;
}

.kx-step .wp-block-heading.kx-stage-title {
	padding-top: 14px;
}

/* Twelve areas: two numbered lists as hairline rows; the second starts at 7. */
ol.kx-numbered-list {
	border-top: 1px solid var(--wp--preset--color--neutral-200);
	list-style: decimal-leading-zero inside;
	margin: 0;
	padding: 0;
}

ol.kx-numbered-list > li {
	border-bottom: 1px solid var(--wp--preset--color--neutral-200);
	color: var(--wp--preset--color--navy);
	font-size: 16px;
	line-height: 1.6;
	padding: 13px 0;
}

ol.kx-numbered-list > li::marker {
	color: var(--wp--preset--color--blue);
	font-family: var(--wp--preset--font-family--mono);
	font-size: 13px;
	font-weight: 700;
}

ul.kx-spaced-list > li + li {
	margin-top: 12px;
}

/* A callout that carries a whole section: body-size text and more room. */
.wp-block-group.kx-callout-lg {
	font-size: var(--wp--preset--font-size--body);
	line-height: var(--wp--custom--line-height--body, 1.62);
	padding: 28px 32px;
}

p.kx-link-row {
	font-size: var(--wp--preset--font-size--small);
	font-weight: 500;
}

/* --------------------------------------------------------------------------
   About page
   -------------------------------------------------------------------------- */

.kx-intro-lead + .wp-block-buttons {
	margin-block-start: 32px;
}

/* Outline (quiet) buttons on navy: white text on a solid muted border. */
.has-navy-background-color .wp-block-button.is-style-outline > .wp-block-button__link {
	background-color: transparent;
	border-color: var(--wp--preset--color--on-dark-muted);
	color: var(--wp--preset--color--white);
}

.has-navy-background-color .wp-block-button.is-style-outline > .wp-block-button__link:hover,
.has-navy-background-color .wp-block-button.is-style-outline > .wp-block-button__link:focus {
	background-color: var(--wp--preset--color--navy-700);
	border-color: var(--wp--preset--color--white);
	color: var(--wp--preset--color--white);
}

/* Portrait: an Image block cropped to a 4:5 frame. */
.wp-block-image.kx-portrait {
	margin: 0;
	max-width: 340px;
}

.wp-block-image.kx-portrait img {
	aspect-ratio: 4 / 5;
	border-radius: var(--wp--custom--radius--lg);
	display: block;
	height: auto;
	object-fit: cover;
	width: 100%;
}

/* --------------------------------------------------------------------------
   Contact page cards
   -------------------------------------------------------------------------- */

.wp-block-heading.kx-card-heading {
	font-size: 22px;
	letter-spacing: -.01em;
	line-height: 1.3;
}

.wp-block-group.kx-fact {
	font-size: var(--wp--preset--font-size--small);
	gap: 12px;
	line-height: 1.6;
}

.wp-block-group.kx-fact > .kx-fact__label {
	flex: 0 0 110px;
}

.wp-block-group.kx-fact > :last-child {
	flex: 1 1 auto;
	min-width: 0;
}

/* --------------------------------------------------------------------------
   Quote, rule left
   -------------------------------------------------------------------------- */

.wp-block-quote.is-style-rule-left {
	background: none;
	border: 0;
	border-left: var(--wp--custom--border--rule-strong) solid var(--wp--preset--color--blue);
	font-style: normal;
	margin-block: 28px;
	padding: 0 0 0 20px;
}

.wp-block-quote.is-style-rule-left p {
	color: var(--wp--preset--color--navy);
	font-size: 21px;
	font-weight: 500;
	letter-spacing: -.01em;
	line-height: 1.5;
}

/* --------------------------------------------------------------------------
   Service pages
   Under the Service template's header, a service page is a run of bands. A
   band is a full-width Group with the "Service band" style, holding one block
   type or two side by side under its own eyebrow and H2. The markup is built in
   inc/service-blocks.php; nothing here belongs to one page.
   -------------------------------------------------------------------------- */

/*
 * Grounds belong to position, not to the block. Bands alternate tint and white
 * in document order, starting on tint under the white header, so skipping or
 * reordering blocks never breaks the rhythm. --kx-ground passes the band's
 * colour to anything that has to match it, such as the stage numbers.
 */
.wp-block-group.is-style-band {
	--kx-ground: var(--wp--preset--color--white);
	background-color: var(--kx-ground);
	padding-block: var(--wp--custom--spacing--band, 64px);
}

.wp-block-group.is-style-band:nth-child(odd of .is-style-band) {
	--kx-ground: var(--wp--preset--color--tint);
}

.wp-block-group.is-style-band + .wp-block-group.is-style-band {
	margin-block-start: 0;
}

/* Eyebrow, H2, then the block. */
.wp-block-heading.kx-block-title {
	font-size: 26px;
	letter-spacing: -.015em;
	line-height: 1.22;
}

.is-style-band p.is-style-eyebrow + .wp-block-heading.kx-block-title {
	margin-block-start: 14px;
}

.is-style-band .wp-block-heading.kx-block-title + * {
	margin-block-start: 18px;
}

.is-style-band .wp-block-heading.kx-block-title + :is(.is-style-row, .kx-cards, .is-style-card, .is-style-faq) {
	margin-block-start: 28px;
}

.is-style-band .wp-block-heading.kx-block-title + .wp-block-group.kx-sections,
.is-style-band .kx-band-inner > * + .wp-block-group.kx-sequence {
	margin-block-start: 32px;
}

/* Two blocks in one band, stacking on narrow screens. */
.wp-block-columns.kx-pair {
	gap: 48px;
}

/* Running text keeps to the 760px prose width; beside another block, 60ch. */
.kx-band-inner > :is(p, ul, ol),
.kx-band-inner > .wp-block-group:is([class*="is-style-callout-"], .is-style-faq) {
	max-width: 760px;
}

.kx-pair > .wp-block-column > :is(p, ul, ol) {
	max-width: 60ch;
}

.is-style-band .wp-block-group[class*="is-style-callout-"] + .wp-block-group[class*="is-style-callout-"] {
	margin-block-start: 14px;
}

/* A closing line under a block: one sentence in the heading colour. */
p.kx-closer {
	color: var(--wp--preset--color--navy);
	font-weight: 600;
}

.is-style-band .wp-block-group[class*="is-style-callout-"] + p.kx-closer {
	margin-block-start: 18px;
}

/* 01 Labelled rows */
.is-style-band .wp-block-columns.is-style-row {
	gap: 8px 32px;
}

.is-style-band .is-style-row p:not(.kx-row-title) {
	max-width: 66ch;
}

/* Rows with a lead-in or a closing line around them. */
.kx-band-inner > p + .wp-block-columns.is-style-row,
.kx-band-inner > .wp-block-columns.is-style-row + p {
	margin-block-start: 24px;
}

/* 02 Sub-headed sections, with sub-items behind a 1px rule */
.wp-block-group.kx-sections {
	max-width: 860px;
}

.wp-block-heading.kx-item-title {
	font-size: 21px;
	letter-spacing: -.01em;
	line-height: 1.3;
}

.wp-block-group.kx-sections > * + * {
	margin-block-start: 12px;
}

.wp-block-group.kx-sections > .wp-block-heading.kx-item-title + * {
	margin-block-start: 10px;
}

.wp-block-group.kx-sections > * + .wp-block-heading.kx-item-title {
	margin-block-start: 36px;
}

.wp-block-group.kx-sections > * + .wp-block-group.is-style-sub-items,
.wp-block-group.kx-sections > .wp-block-group.is-style-sub-items + p {
	margin-block-start: 16px;
}

.wp-block-group.kx-sections > :is(p, ul, ol) {
	max-width: 66ch;
}

.wp-block-group.is-style-sub-items {
	border-left: 1px solid var(--wp--preset--color--neutral-300);
	padding-left: 20px;
}

.wp-block-group.is-style-sub-items > * + * {
	margin-block-start: 14px;
}

.wp-block-group.is-style-sub-items > p.kx-row-title + * {
	margin-block-start: 4px;
}

.wp-block-group.is-style-sub-items > p:not(.kx-row-title) {
	font-size: 16px;
	line-height: 1.65;
	max-width: 62ch;
}

/* 04 Cards: three across, 24px padding */
.wp-block-columns.kx-cards {
	gap: 16px;
}

.kx-cards > .wp-block-column > .wp-block-group.is-style-card {
	box-sizing: border-box;
	height: 100%;
	padding: 24px;
}

.kx-cards .is-style-card > p.kx-row-title + * {
	margin-block-start: 6px;
}

.kx-cards .is-style-card > p:not(.kx-row-title) {
	font-size: var(--wp--preset--font-size--small);
	line-height: 1.6;
}

/* 07 Proof */
.wp-block-columns.kx-proof {
	gap: 40px;
}

p.kx-proof-figure {
	color: var(--wp--preset--color--navy);
	font-size: clamp(34px, 4vw, 48px);
	font-weight: 700;
	letter-spacing: -.02em;
	line-height: 1;
}

.kx-proof p.is-style-eyebrow + p,
.kx-proof p.kx-proof-figure + p.kx-proof-text,
.kx-proof p.kx-proof-text + p.kx-proof-text {
	margin-block-start: 12px;
}

/* Context set above the figure gets more room before it. */
.kx-proof p.kx-proof-text + p.kx-proof-figure {
	margin-block-start: 24px;
}

p.kx-proof-text {
	font-size: 16px;
	line-height: 1.65;
	max-width: 42ch;
}

.kx-proof .wp-block-image {
	margin: 0;
}

.kx-proof .wp-block-image img {
	display: block;
	height: auto;
	width: 100%;
}

.kx-proof .wp-block-image figcaption {
	color: var(--wp--preset--color--muted);
	font-size: var(--wp--preset--font-size--caption);
	font-weight: 400;
	line-height: 1.6;
	margin: 12px 0 0;
	text-align: left;
}

/* 08 Numbered stages: 36px mono numbers joined by a line */
.wp-block-group.kx-sequence {
	max-width: 760px;
}

.wp-block-columns.kx-sequence-step {
	gap: 20px;
	margin-bottom: 0;
	padding-bottom: 28px;
	position: relative;
}

.kx-sequence > .wp-block-columns.kx-sequence-step + .kx-sequence-step {
	margin-block-start: 0;
}

.wp-block-columns.kx-sequence-step:last-child {
	padding-bottom: 0;
}

.wp-block-columns.kx-sequence-step:not(:last-child)::before {
	background-color: var(--wp--preset--color--neutral-300);
	bottom: 0;
	content: "";
	left: 17px;
	position: absolute;
	top: 36px;
	width: 1px;
}

.kx-sequence-step > .wp-block-column:first-child {
	flex: 0 0 36px;
}

.kx-sequence-step > .wp-block-column:last-child {
	padding-top: 6px;
}

p.kx-sequence-node {
	align-items: center;
	background-color: var(--kx-ground, var(--wp--preset--color--white));
	border: 1px solid var(--wp--preset--color--neutral-300);
	border-radius: 50%;
	box-sizing: border-box;
	color: var(--wp--preset--color--blue);
	display: flex;
	font-family: var(--wp--preset--font-family--mono);
	font-size: 14px;
	font-weight: 700;
	height: 36px;
	justify-content: center;
	line-height: 1;
	width: 36px;
}

.wp-block-heading.kx-sequence-title {
	font-size: 19px;
	letter-spacing: -.01em;
	line-height: 1.35;
}

.kx-sequence-step .wp-block-heading.kx-sequence-title + p {
	margin-block-start: 6px;
}

.kx-sequence-step p:not(.kx-sequence-node) + p {
	margin-block-start: 12px;
}

.kx-sequence-step p:not(.kx-sequence-node) {
	font-size: 16px;
	line-height: 1.65;
	max-width: 60ch;
}

/* Closing band: scoping and buttons left, related services right */
.kx-closing > .wp-block-column:first-child > * {
	max-width: 620px;
}

.kx-closing .wp-block-heading.kx-block-title + p {
	margin-block-start: 16px;
}

.kx-closing .wp-block-column > .wp-block-buttons.kx-service-actions {
	margin-block-start: 22px;
}

.kx-closing p.is-style-eyebrow + .wp-block-buttons.kx-related-pills {
	margin-block-start: 16px;
}

.wp-block-buttons.kx-service-actions {
	gap: 12px;
}

.wp-block-buttons.kx-related-pills {
	gap: 10px;
}

/* --------------------------------------------------------------------------
   Badges
   A finding area, coloured by tone. Used by case study cards (the archive
   template and the home page). Here rather than style.css so they show in the
   editor too.
   -------------------------------------------------------------------------- */

.kx-badge {
	align-items: center;
	background-color: var(--wp--custom--status--info--bg);
	border-radius: var(--wp--custom--radius--sm);
	color: var(--wp--custom--status--info--fg);
	display: inline-flex;
	font-size: var(--wp--preset--font-size--caption);
	font-weight: 600;
	letter-spacing: .01em;
	line-height: 1.5;
	padding: 3px 9px;
}

.kx-badge--info {
	background-color: var(--wp--custom--status--info--bg);
	color: var(--wp--custom--status--info--fg);
}

.kx-badge--pass {
	background-color: var(--wp--custom--status--pass--bg);
	color: var(--wp--custom--status--pass--fg);
}

.kx-badge--warn {
	background-color: var(--wp--custom--status--warn--bg);
	color: var(--wp--custom--status--warn--fg);
}

.kx-badge--fail {
	background-color: var(--wp--custom--status--fail--bg);
	color: var(--wp--custom--status--fail--fg);
}

/* Badge and platform line on one row, above a card title. */
.wp-block-group.kx-card-meta {
	gap: 10px;
	margin-bottom: 6px;
}

/*
 * A page's H1 when the page opens on white rather than on a navy hero: the
 * page-heading size, so it stays the largest text on the page.
 */
.wp-block-heading.kx-section-title {
	font-size: var(--wp--preset--font-size--h-1);
	font-weight: 700;
	letter-spacing: -.02em;
	line-height: 1.12;
}

/* A card's icon: a 22px Image block above the card title. */
.wp-block-image.kx-card-icon {
	margin: 0 0 6px;
}

.wp-block-image.kx-card-icon img {
	display: block;
}

/* A statement set large in the heading colour, on a band of its own. */
p.kx-statement {
	color: var(--wp--preset--color--navy);
	font-size: clamp(19px, 1.7vw, 22px);
	letter-spacing: -.01em;
	line-height: 1.5;
	text-wrap: pretty;
}

/* A testimonial: the quotation inside a card, attribution below in the meta style. */
.is-style-card > .wp-block-quote.kx-testimonial {
	border: 0;
	font-size: var(--wp--preset--font-size--body);
	font-style: normal;
	margin: 0;
	padding: 0;
}

.is-style-card > .wp-block-quote.kx-testimonial + p.is-style-meta {
	margin-block-start: 16px;
}

/* --------------------------------------------------------------------------
   Home page proof strip
   One paragraph of facts under a hairline; the separators are literal "·"
   characters in the border colour, spaced here.
   -------------------------------------------------------------------------- */

.wp-block-group.kx-proof-strip {
	border-bottom: 1px solid var(--wp--preset--color--neutral-200);
	padding-block: 22px;
}

p.kx-proof-items {
	color: var(--wp--preset--color--navy);
	font-size: var(--wp--preset--font-size--small);
	font-weight: 500;
	line-height: 1.6;
}

p.kx-proof-items mark {
	padding-inline: .75em;
}

/* --------------------------------------------------------------------------
   Inline code
   Literal strings in running text: file names, user agents, directives.
   Code blocks (pre) keep their own style.
   -------------------------------------------------------------------------- */

:not(pre) > code {
	background-color: var(--wp--preset--color--neutral-50);
	border: 1px solid var(--wp--preset--color--neutral-200);
	border-radius: var(--wp--custom--radius--sm);
	font-family: var(--wp--preset--font-family--mono);
	font-size: .88em;
	padding: 1px 5px;
}
