/* ==========================================================================
   EUROMIG — the theme stylesheet.

   One file, one request, no @import chain, no build step. Organised in the
   order a browser reads it and a person reasons about it:

     1  Design tokens
     2  Reset and base elements
     3  Accessibility utilities
     4  Layout containers
     5  Site header
     6  Primary navigation (six levels)
     7  Language switcher
     8  Site footer
     9  Entries and migrated content
    10  Components: buttons, forms, cards, badges, tables, pagination
    11  Post-type surfaces
    12  Homepage
    13  Page and service hierarchy
    14  Editorial
    15  Responsive and motion

   CASE 11.1 REFACTORED THIS FILE RATHER THAN APPENDING TO IT. Twelve of the
   fifteen sections were replaced in place, so a refined rule sits where the
   rule it supersedes used to be and the file gained no second copy of
   anything. Three components MOVED to where they belonged — the section
   header and the accent button out of 12 into 10, the brand mark into 10 as
   a component both navy surfaces share — and two rules were deleted outright
   rather than overridden: the `:nth-of-type(even)` band that tinted every
   second homepage section, and the unlabelled gold border on a featured
   listing.

   There is no override layer, no numeric WordPress id in a selector, and no
   rule that contradicts an earlier one. `!important` appears NINE times:

     - four in the reduced-motion block;
     - three holding the two visually-hidden utilities in place — a
       screen-reader label that a component rule could otherwise reveal is a
       defect, not a style preference;
     - TWO added by CASE 11.3, both in section 9, both on the same rule, and
       both there for a reason no selector can solve: five migrated tables
       carry `style="width: …px; height: …px"` in their stored markup, an
       inline style outranks every author rule, and rewriting stored content
       is out of scope for this project. They are named at the point of use.

   CASE 11.3 ALSO REMOVED A TOKEN RATHER THAN OVERRIDING IT. `--em-measure`
   (66ch) is gone from section 1, and the three rules that used it — in
   sections 4, 10 and 13 — were rewritten where they stand. Nothing was piled
   at the end of the file.

   Every `ch` value that survives is on a HEADING, a LEAD, an EXCERPT or the
   footer statement — a single short line that would read as an accident if it
   ran the full 1,204px. Not one is on `.entry-content` or on generic page
   content, which is the distinction CASE 11.3 draws.
   ========================================================================== */


/* ==========================================================================
   0  INTER TIGHT — SELF-HOSTED

   Rasmus Andersson's Inter Tight, under the SIL Open Font License 1.1. The
   licence travels with the files, in `assets/fonts/OFL.txt`, because the OFL
   requires it of a redistributed copy.

   THERE IS NO EXTERNAL REQUEST. No Google Fonts stylesheet, no gstatic, no
   font loader script: the files are in this theme and the browser fetches
   them from this origin.

   Split by `unicode-range` rather than shipped as one file, which is what
   makes a self-hosted variable font cheap on a bilingual site: an English
   page downloads the Latin roman and nothing else; a Russian page downloads
   the Cyrillic roman. Neither pays for the other's alphabet, and neither
   pays for Greek or Vietnamese, which are not shipped at all.

   One variable axis, weight 100-900, so every weight this design uses comes
   out of the same file. `font-display: swap` keeps text readable while it
   loads, and the fallback stack below is metric-similar enough that the swap
   is not a jolt.
   ========================================================================== */

/* latin, normal — 44872 bytes */
@font-face {
	font-family: "Inter Tight";
	font-style: normal;
	font-weight: 100 900;
	font-display: swap;
	src: url("../fonts/inter-tight-latin-normal.woff2") format("woff2");
	unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

/* cyrillic, normal — 16996 bytes */
@font-face {
	font-family: "Inter Tight";
	font-style: normal;
	font-weight: 100 900;
	font-display: swap;
	src: url("../fonts/inter-tight-cyrillic-normal.woff2") format("woff2");
	unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}

/* latin-ext, normal — 89800 bytes */
@font-face {
	font-family: "Inter Tight";
	font-style: normal;
	font-weight: 100 900;
	font-display: swap;
	src: url("../fonts/inter-tight-latin-ext-normal.woff2") format("woff2");
	unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

/* cyrillic-ext, normal — 26660 bytes */
@font-face {
	font-family: "Inter Tight";
	font-style: normal;
	font-weight: 100 900;
	font-display: swap;
	src: url("../fonts/inter-tight-cyrillic-ext-normal.woff2") format("woff2");
	unicode-range: U+0460-052F, U+1C80-1C8A, U+20B4, U+2DE0-2DFF, U+A640-A69F, U+FE2E-FE2F;
}

/* latin, italic — 47912 bytes */
@font-face {
	font-family: "Inter Tight";
	font-style: italic;
	font-weight: 100 900;
	font-display: swap;
	src: url("../fonts/inter-tight-latin-italic.woff2") format("woff2");
	unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

/* cyrillic, italic — 17856 bytes */
@font-face {
	font-family: "Inter Tight";
	font-style: italic;
	font-weight: 100 900;
	font-display: swap;
	src: url("../fonts/inter-tight-cyrillic-italic.woff2") format("woff2");
	unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}

/* latin-ext, italic — 95128 bytes */
@font-face {
	font-family: "Inter Tight";
	font-style: italic;
	font-weight: 100 900;
	font-display: swap;
	src: url("../fonts/inter-tight-latin-ext-italic.woff2") format("woff2");
	unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

/* cyrillic-ext, italic — 27916 bytes */
@font-face {
	font-family: "Inter Tight";
	font-style: italic;
	font-weight: 100 900;
	font-display: swap;
	src: url("../fonts/inter-tight-cyrillic-ext-italic.woff2") format("woff2");
	unicode-range: U+0460-052F, U+1C80-1C8A, U+20B4, U+2DE0-2DFF, U+A640-A69F, U+FE2E-FE2F;
}

/* ==========================================================================
   1  DESIGN TOKENS — EUROMIG BUSINESS

   The visual reference the client supplied is a business-consultancy theme.
   What actually makes that reference work is not a colour or a photograph: it
   is SCALE and AIR. Its headings are three to four times its body size, its
   sections breathe, its components are large, and it almost never uses a
   border where whitespace would do.

   So this candidate is built on a wider type range than anything before it in
   this project — 5.3:1 from metadata to display — a single-tier white header,
   and a 1300px composition grid.
   ========================================================================== */

:root {
	/* --------------------------------------------------------------------
	   Brand. MEASURED in CASE 10 from the authoritative logo: 50.3% of its
	   opaque pixels are #ffbe00 and 41.5% are #001c72.

	   The rule the whole file obeys is unchanged and non-negotiable: gold is
	   1.66:1 on white, so it is a SURFACE and an ACCENT, never text on white.
	   Gold carries dark ink; never the reverse.
	   -------------------------------------------------------------------- */
	--em-color-brand: #001c72;          /* 14.90:1 on white */
	--em-color-brand-dark: #001350;
	--em-color-brand-tint: #eaeef8;
	--em-color-brand-wash: #f5f7fc;

	--em-color-accent: #ffbe00;
	--em-color-accent-hover: #ffcd33;
	--em-color-accent-ink: #16181d;     /* 10.67:1 on the accent */
	--em-color-accent-soft: #fff4d1;

	/* Neutrals. Every pair used for text clears WCAG AA. */
	--em-color-text: #14161b;           /* 18.4:1 on white */
	--em-color-text-muted: #545c6b;     /*  6.9:1 on white */
	--em-color-bg: #ffffff;
	--em-color-surface: #f6f8fb;
	--em-color-surface-strong: #e8ecf3;
	--em-color-border: #e2e6ed;
	--em-color-border-strong: #c3cad6;

	/*
	 * TABLES ONLY, and named separately because human review named the VALUE:
	 * "content table borders must use #eee". It is lighter and more neutral
	 * than `--em-color-border`, which is very slightly blue; on a table of 73
	 * rows that difference is the whole character of the grid.
	 *
	 * It is a 1.19:1 line on white. That is correct for a rule — it separates
	 * without competing — and it carries no text, so no contrast minimum
	 * applies to it.
	 */
	--em-color-table-border: #eeeeee;

	/* Ink on the navy ground, named once. */
	--em-color-on-brand: #ffffff;
	--em-color-on-brand-muted: rgba(255, 255, 255, 0.8);
	--em-color-on-brand-faint: rgba(255, 255, 255, 0.6);
	--em-color-on-brand-line: rgba(255, 255, 255, 0.18);
	--em-color-on-brand-wash: rgba(255, 255, 255, 0.07);

	/* Status. */
	--em-color-success: #146c43;
	--em-color-warning: #8a5200;
	--em-color-danger: #b3261e;
	--em-color-on-status: #ffffff;

	/* --------------------------------------------------------------------
	   Type — Inter Tight, self-hosted, section 0.

	   The fallback stack is metric-similar so the `font-display: swap` handover
	   is not a jolt. No Google Fonts, no CDN, no loader script.
	   -------------------------------------------------------------------- */
	--em-font-sans: "Inter Tight", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, "Noto Sans", sans-serif;
	--em-font-mono: ui-monospace, SFMono-Regular, "SF Mono", Consolas, "Liberation Mono", Menlo, monospace;

	/*
	 * THE SCALE. 13px to 69px at 1440, a range of 5.3:1.
	 *
	 * Inter Tight is narrower than a system UI face at the same size, which is
	 * the point: a 69px headline in Inter Tight occupies roughly the width of a
	 * 62px system heading, so the scale can be more confident without the line
	 * breaking earlier. Every step is a clamp, so a phone compresses the scale
	 * rather than switching to a second one.
	 */
	--em-text-xs: 0.8125rem;                                         /* 13px */
	--em-text-sm: 0.9375rem;                                         /* 15px */
	--em-text-base: 1.125rem;                                        /* 18px — body */
	--em-text-md: 1.1875rem;                                         /* 19px */
	--em-text-lead: clamp(1.1875rem, 1.05rem + 0.6vw, 1.4375rem);    /* 19 → 23px */
	--em-text-lg: clamp(1.375rem, 1.1rem + 1.05vw, 1.9375rem);       /* 22 → 31px — h3/card */
	--em-text-xl: clamp(1.875rem, 1.35rem + 2.05vw, 3.125rem);       /* 30 → 50px — h2 */
	--em-text-2xl: clamp(2.125rem, 1.5rem + 2.5vw, 3.5rem);          /* 34 → 56px — page h1 */
	--em-text-display: clamp(2.5rem, 1.6rem + 3.9vw, 4.3125rem);     /* 40 → 69px — home h1 */

	--em-text-nav: 1rem;
	--em-text-button: 1rem;

	--em-weight-regular: 400;
	--em-weight-medium: 500;
	--em-weight-semibold: 600;
	--em-weight-bold: 700;

	--em-leading-tight: 1.06;
	--em-leading-snug: 1.28;
	--em-leading-normal: 1.62;
	--em-leading-loose: 1.78;

	--em-tracking-tight: -0.022em;
	--em-tracking-wide: 0.1em;

	/* Spacing — a 4px base. */
	--em-space-1: 0.25rem;
	--em-space-2: 0.5rem;
	--em-space-3: 0.75rem;
	--em-space-4: 1rem;
	--em-space-5: 1.5rem;
	--em-space-6: 2rem;
	--em-space-7: 3rem;
	--em-space-8: 4rem;
	--em-space-9: 6rem;

	/*
	 * Section rhythm. CASE 11.3 CUT THIS SCALE BY ROUGHLY 43 PER CENT.
	 *
	 * CASE 11.2 separated sections by about 120px at each edge, on the theory
	 * that generosity is what makes a page read as premium. Human review of
	 * the built page disagreed with the theory: "too white, too vertically
	 * large", and "more businesses in less vertical space".
	 *
	 * The measured cost was concrete. Four homepage sections at 120px top and
	 * bottom is 960 pixels of nothing, which at a 1000px viewport is a whole
	 * screen the visitor scrolls past to reach the next fact.
	 *
	 * So the scale is smaller but still a SCALE: three steps, each still fluid,
	 * still 1.55:1 from the smallest to the largest, so the rhythm survives
	 * even though the absolute values do not. Compaction is a change of
	 * spacing, never of type size — nothing here makes the text smaller.
	 *
	 *   sm  32 → 44px   (was 48 → 72)
	 *   md  44 → 68px   (was 64 → 120)
	 *   lg  56 → 88px   (was 80 → 152)
	 */
	--em-section-sm: clamp(2rem, 1.6rem + 1.6vw, 2.75rem);
	--em-section-md: clamp(2.75rem, 2.1rem + 2.6vw, 4.25rem);
	--em-section-lg: clamp(3.5rem, 2.6rem + 3.6vw, 5.5rem);

	/*
	 * Layout.
	 *
	 * `--em-measure: 66ch` USED TO LIVE HERE AND IS GONE.
	 *
	 * It capped `.entry-content` at about 687 real pixels — inside a column
	 * that offered 1204 at 1440, and 868 on a page with a sidebar. Every
	 * migrated page therefore set its text in just over half the width it had
	 * been given, and every legacy table had to scroll sideways inside a box
	 * narrower than the table. Human review asked for the cap to be removed;
	 * section 4 now gives generic content the whole of its column.
	 *
	 * What replaces it is NOT a smaller cap. `--em-measure-lede` is for short
	 * standalone paragraphs that are not body content — an archive
	 * description, the 404 sentence, a section lead — where a single line
	 * running the full 1204px would read as a mistake. It is never applied to
	 * `.entry-content`.
	 *
	 * `--em-container` stays at 1300px: inside CASE 11.3's 1280–1360
	 * recommendation, aligned with the header grid, and the only global width
	 * limit in the theme. It is now the ONLY width limit in the theme.
	 *
	 * `--em-container-narrow` (900px) and `--em-container-reading` (46rem) went
	 * with the measure. Between them they capped a page body, a homepage
	 * introduction and every single article, and each was the same instruction
	 * under a different name. A token nothing uses is a token somebody will
	 * use again by accident.
	 */
	--em-container: 1300px;
	--em-measure-lede: 60ch;
	--em-gutter: clamp(1.25rem, 4vw, 3rem);
	--em-masthead-height: 5.5rem;
	--em-header-height: 5.5rem;
	--em-admin-bar-height: 0px;

	/* Surface treatment. Softer and larger than the baseline's. */
	--em-radius-sm: 4px;
	--em-radius: 10px;
	--em-radius-lg: 18px;
	--em-radius-xl: 28px;
	--em-shadow-sm: 0 1px 2px rgba(20, 22, 27, 0.05), 0 2px 6px rgba(20, 22, 27, 0.05);
	--em-shadow: 0 4px 12px rgba(20, 22, 27, 0.06), 0 12px 32px rgba(20, 22, 27, 0.07);
	--em-shadow-lg: 0 12px 40px rgba(0, 28, 114, 0.14);

	/* Interaction. */
	--em-focus-ring: 3px solid var(--em-color-brand);
	--em-focus-offset: 2px;
	--em-duration: 180ms;
	--em-easing: cubic-bezier(0.2, 0, 0.2, 1);

	--em-z-header: 100;
	--em-z-submenu: 110;
}


/* ==========================================================================
   2  RESET AND BASE ELEMENTS

   Scoped to the front end by the enqueue, so nothing here can reach wp-admin
   and disturb the Corporate Sales editor.
   ========================================================================== */

*,
*::before,
*::after {
	box-sizing: border-box;
}

html {
	-webkit-text-size-adjust: 100%;
	text-size-adjust: 100%;
	scroll-behavior: smooth;
}

body {
	margin: 0;
	background-color: var(--em-color-bg);
	color: var(--em-color-text);
	font-family: var(--em-font-sans);
	font-size: var(--em-text-base);
	line-height: var(--em-leading-normal);
	-webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4, h5, h6 {
	margin: 0 0 var(--em-space-4);
	color: var(--em-color-brand);
	font-weight: var(--em-weight-semibold);
	line-height: var(--em-leading-tight);
	text-wrap: balance;
}

/*
 * Tracking tightens as size grows, which is what keeps a 48px heading from
 * reading as loose beside 17px body copy set at its natural spacing. Applied
 * to the two display sizes only — pulling 19px type together makes it harder
 * to read, and it makes Cyrillic noticeably harder.
 */
h1, h2 {
	letter-spacing: var(--em-tracking-tight);
}

h1 { font-size: var(--em-text-2xl); }
h2 { font-size: var(--em-text-xl); }
h3 { font-size: var(--em-text-lg); }
h4 { font-size: var(--em-text-md); }
h5, h6 { font-size: var(--em-text-base); }

p, ul, ol, dl, table, figure, blockquote, pre {
	margin: 0 0 var(--em-space-4);
}

:where(p, li) {
	text-wrap: pretty;
}

a {
	color: var(--em-color-brand);
	text-decoration-thickness: 1px;
	text-underline-offset: 0.15em;
}

a:hover,
a:focus-visible {
	color: var(--em-color-brand-dark);
}

ul, ol {
	padding-left: var(--em-space-5);
}

li + li {
	margin-top: var(--em-space-1);
}

img,
picture,
video,
canvas,
svg {
	display: block;
	max-width: 100%;
	height: auto;
}

figure {
	margin-inline: 0;
}

figcaption {
	margin-top: var(--em-space-2);
	color: var(--em-color-text-muted);
	font-size: var(--em-text-sm);
}

blockquote {
	margin-inline: 0;
	padding: var(--em-space-3) var(--em-space-5);
	border-left: 4px solid var(--em-color-accent);
	background-color: var(--em-color-surface);
	color: var(--em-color-text);
}

blockquote > :last-child {
	margin-bottom: 0;
}

hr {
	height: 0;
	margin: var(--em-space-6) 0;
	border: 0;
	border-top: 1px solid var(--em-color-border);
}

code, kbd, samp, pre {
	font-family: var(--em-font-mono);
	font-size: 0.9em;
}

code {
	padding: 0.1em 0.35em;
	border-radius: var(--em-radius-sm);
	background-color: var(--em-color-surface-strong);
}

pre {
	overflow-x: auto;
	padding: var(--em-space-4);
	border: 1px solid var(--em-color-border);
	border-radius: var(--em-radius);
	background-color: var(--em-color-surface);
	tab-size: 4;
}

pre code {
	padding: 0;
	background: none;
}

table {
	width: 100%;
	border-collapse: collapse;
}

th, td {
	padding: var(--em-space-2) var(--em-space-3);
	border-bottom: 1px solid var(--em-color-border);
	text-align: left;
	vertical-align: top;
}

th {
	font-weight: var(--em-weight-semibold);
}

thead th {
	border-bottom-width: 2px;
	border-bottom-color: var(--em-color-border-strong);
}

iframe,
embed,
object {
	max-width: 100%;
}

/* --------------------------------------------------------------------------
   Focus.

   The outline is never removed without a replacement. `:focus-visible` keeps
   it off for mouse clicks and on for keyboard use; the `:focus` fallback below
   it covers browsers that do not support the newer selector.
   -------------------------------------------------------------------------- */

:focus {
	outline: var(--em-focus-ring);
	outline-offset: var(--em-focus-offset);
}

:focus:not(:focus-visible) {
	outline: none;
}

:focus-visible {
	outline: var(--em-focus-ring);
	outline-offset: var(--em-focus-offset);
}


/* ==========================================================================
   3  ACCESSIBILITY UTILITIES
   ========================================================================== */

.screen-reader-text {
	position: absolute !important;
	width: 1px;
	height: 1px;
	padding: 0;
	margin: -1px;
	overflow: hidden;
	clip-path: inset(50%);
	white-space: nowrap;
	border: 0;
}

.skip-link.screen-reader-text:focus {
	position: fixed !important;
	top: calc(var(--em-admin-bar-height) + var(--em-space-2));
	left: var(--em-space-2);
	z-index: 1000;
	width: auto;
	height: auto;
	padding: var(--em-space-2) var(--em-space-4);
	clip-path: none;
	border-radius: var(--em-radius);
	background-color: var(--em-color-bg);
	box-shadow: var(--em-shadow-lg);
	color: var(--em-color-brand);
	font-weight: var(--em-weight-semibold);
	text-decoration: none;
}

/* The skip target must not show a permanent outline when focused by script. */
.site-main:focus {
	outline: none;
}

.site-main:focus-visible {
	outline: var(--em-focus-ring);
	outline-offset: calc(var(--em-focus-offset) * -1);
}


/* ==========================================================================
   4  LAYOUT

   ONE grid, not several. Every full-width surface — the header's two tiers,
   the hero, each homepage section, the page body and the footer — puts its
   content inside `.site-container`, so the logo, the first navigation label,
   the headline, the first card and the first footer column all begin on the
   same vertical line at every width. Human review found the old page "composed
   from separate blocks"; that was the cause.
   ========================================================================== */

.site-wrapper {
	display: flex;
	flex-direction: column;
	min-height: 100vh;
}

.site-container {
	width: 100%;
	max-width: var(--em-container);
	margin-inline: auto;
	padding-inline: var(--em-gutter);
}

/*
 * Templates own their own top spacing, because each opens with a surface that
 * already has some: a hero, a page header or an article header. Only the three
 * post-type singles begin straight into content, and they say so.
 */
.site-main {
	flex: 1 0 auto;
	padding-block: 0 var(--em-section-md);
}

/*
 * `--sales-single` LEFT THIS GROUP IN CASE 12. The rule gives a template that
 * opens straight into content some room to breathe, which is still right for
 * a consultant and a real-estate record. A Sales listing no longer opens into
 * content: it opens into its own tinted header, which supplies its own
 * padding, and the two together were leaving a white strip between the site
 * header and the listing header.
 */
.site-main--consultant-single,
.site-main--realestate-single {
	padding-top: var(--em-section-sm);
}

/*
 * The marketplace and a listing both start with a full-bleed tinted band, so
 * the main element contributes nothing at the top and nothing at the bottom —
 * the footer follows the last section directly.
 */
.site-main--marketplace,
.site-main--sales-single {
	padding-block: 0;
}

.site-main--home {
	padding-bottom: 0;
}

/* --------------------------------------------------------------------------
   THE CONTENT WIDTH CONTRACT.

   ONE RULE, STATED ONCE: content fills the column it was given, and the
   COLUMN decides how wide that is. `.site-container` caps the composition at
   1300px, the page grid decides how much of it the article gets, and nothing
   inside the article narrows it again.

   This replaces three rules that each imposed a reading measure of their own —
   `.entry-content` at 66ch, `.entry--page`/`.entry--single` at
   `min(66ch, 900px)`, and `.page-layout .entry-content` at 66ch again in
   section 13. The result was that a page with a sidebar and a page without
   both set their text at the same 687 pixels, and the sidebar page's extra
   181px of column simply stayed empty.

   READABILITY IS NOT ABANDONED — it moves to where it belongs. Line height,
   paragraph spacing, heading rhythm and list spacing do that work in section 9
   for migrated content and in section 14 for long-form articles. What is gone
   is the single blunt instrument that also broke every table.
   -------------------------------------------------------------------------- */

.entry-content {
	width: 100%;
	max-width: none;
}

/*
 * NOT `.entry-content`. These two are single short paragraphs that introduce a
 * listing page — one sentence each — and a sentence set across 1204 pixels
 * reads as an accident rather than as a decision. The cap is on them
 * specifically and is documented here as intentional.
 */
.archive-description,
.error-404__message {
	max-width: var(--em-measure-lede);
}

.page-header {
	margin-bottom: var(--em-space-6);
}

.page-title {
	margin-bottom: var(--em-space-2);
}

.section-title {
	margin-top: var(--em-space-7);
	padding-bottom: var(--em-space-3);
	border-bottom: 2px solid var(--em-color-accent);
	font-size: var(--em-text-lg);
}


/* ==========================================================================
   5  SITE HEADER — EUROMIG BUSINESS

   ONE ROW. That is the most visible difference from the baseline, and it is
   the thing the supplied reference does that the previous design could not: a
   white masthead about 88px tall carrying the wordmark, the whole navigation
   and the language control on a single line.

   It fits now because two things changed. Inter Tight at 16px is materially
   narrower than the 17px system stack it replaces, and the language control is
   two flags rather than two spelled-out language names — together roughly
   190px of the row given back, which is what six root items needed.

   The structure is in `header.php` rather than here: branding, navigation and
   the utility cluster are siblings in one flex row, so nothing is lifted onto
   the row by negative margin.
   ========================================================================== */

.site-header {
	position: sticky;
	top: var(--em-admin-bar-height);
	z-index: var(--em-z-header);
	border-bottom: 1px solid var(--em-color-border);
	background-color: var(--em-color-bg);
}

.site-header__inner {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: var(--em-space-3) var(--em-space-5);
	min-height: var(--em-masthead-height);
	padding-block: var(--em-space-3);
}

/* The wordmark does not shrink; the utility cluster gives way instead. */
.site-branding {
	flex: 0 0 auto;
	min-width: 0;
	margin-right: auto;
}

.site-logo,
.custom-logo {
	display: block;
	width: auto;
	max-height: 2rem;
}

.site-title {
	margin: 0;
	font-size: var(--em-text-lg);
	font-weight: var(--em-weight-bold);
	letter-spacing: var(--em-tracking-tight);
}

.site-title a {
	text-decoration: none;
}

.site-header__utility {
	display: flex;
	flex: 0 0 auto;
	align-items: center;
	gap: var(--em-space-3);
}

.menu-placeholder {
	margin: 0;
	padding-block: var(--em-space-3);
	font-size: var(--em-text-sm);
}

/* -- Small screens: the navigation is a panel below the row --------------- */

.site-header__nav {
	flex-basis: 100%;
	order: 3;
	min-width: 0;
}

@media (min-width: 62rem) {
	.site-logo,
	.custom-logo {
		max-height: 2.5rem;
	}

	.site-header__inner {
		flex-wrap: nowrap;
		gap: var(--em-space-6);
		min-height: 5.5rem;
	}

	/*
	 * On the row, between the wordmark and the flags, and pushed to the right
	 * so the navigation ends where the language control begins rather than
	 * floating in the middle of the available space.
	 */
	.site-header__nav {
		flex: 0 1 auto;
		flex-basis: auto;
		order: 0;
	}
}


/* ==========================================================================
   6  PRIMARY NAVIGATION — EUROMIG BUSINESS

   Authored mobile-first AND no-JS-first, exactly as CASE 10 built it. The
   walker, the markup, the disclosure buttons, their `aria-controls` pairs and
   `assets/js/navigation.js` are untouched: sixty-three items per language, six
   levels deep, usable with the keyboard and usable with scripting off.

   What changed is that at desktop the roots sit ON THE WHITE MASTHEAD instead
   of on a navy strip of their own, and the current section is marked by a gold
   rule under the label rather than by a bar on a coloured ground.
   ========================================================================== */

.menu,
.sub-menu {
	margin: 0;
	padding: 0;
	list-style: none;
}

.menu li + li {
	margin-top: 0;
}

.menu-item {
	position: relative;
}

.menu-item__link {
	display: block;
	padding: var(--em-space-3);
	color: var(--em-color-text);
	font-weight: var(--em-weight-medium);
	text-decoration: none;
}

.menu-item__link:hover,
.menu-item__link:focus-visible {
	color: var(--em-color-brand);
	text-decoration: underline;
}

/* A navigation label with no public route. Not a link, and not pretending. */
.menu-item__link--static {
	color: var(--em-color-text-muted);
	cursor: default;
}

.menu-item__link--static:hover {
	text-decoration: none;
}

.menu-item.current-menu-item > .menu-item__link,
.menu-item.current_page_item > .menu-item__link {
	color: var(--em-color-brand);
	font-weight: var(--em-weight-semibold);
	box-shadow: inset 3px 0 0 var(--em-color-accent);
}

.menu-item.current-menu-ancestor > .menu-item__link,
.menu-item.current-menu-parent > .menu-item__link,
.menu-item.current_page_ancestor > .menu-item__link {
	color: var(--em-color-brand);
	font-weight: var(--em-weight-semibold);
}

/* Depth is expressed as indentation in the stacked layout. */
.sub-menu .menu-item__link { padding-left: calc(var(--em-space-3) + var(--em-space-4)); }
.sub-menu .sub-menu .menu-item__link { padding-left: calc(var(--em-space-3) + var(--em-space-4) * 2); }
.sub-menu .sub-menu .sub-menu .menu-item__link { padding-left: calc(var(--em-space-3) + var(--em-space-4) * 3); }
.sub-menu .sub-menu .sub-menu .sub-menu .menu-item__link { padding-left: calc(var(--em-space-3) + var(--em-space-4) * 4); }
.sub-menu .sub-menu .sub-menu .sub-menu .sub-menu .menu-item__link { padding-left: calc(var(--em-space-3) + var(--em-space-4) * 5); }

.submenu-toggle,
.menu-toggle {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: var(--em-space-2);
	border: 1px solid transparent;
	background: none;
	color: inherit;
	cursor: pointer;
	font: inherit;
}

.submenu-toggle {
	position: absolute;
	top: 0;
	right: 0;
	width: 2.75rem;
	height: 2.75rem;
	border-radius: var(--em-radius);
}

.submenu-toggle__icon {
	width: 0.55rem;
	height: 0.55rem;
	border-right: 2px solid currentColor;
	border-bottom: 2px solid currentColor;
	transform: rotate(45deg) translate(-15%, -15%);
	transition: transform var(--em-duration) var(--em-easing);
}

.submenu-toggle[aria-expanded="true"] .submenu-toggle__icon {
	transform: rotate(-135deg) translate(-15%, -15%);
}

.menu-toggle {
	min-height: 2.75rem;
	padding: var(--em-space-2) var(--em-space-4);
	border-color: var(--em-color-border-strong);
	border-radius: var(--em-radius);
	font-size: var(--em-text-sm);
	font-weight: var(--em-weight-semibold);
	letter-spacing: 0.03em;
	text-transform: uppercase;
}

.menu-toggle:hover,
.menu-toggle:focus-visible {
	border-color: var(--em-color-brand);
	color: var(--em-color-brand);
}

.menu-toggle__icon,
.menu-toggle__icon::before,
.menu-toggle__icon::after {
	display: block;
	width: 1.25rem;
	height: 2px;
	background-color: currentColor;
}

.menu-toggle__icon {
	position: relative;
}

.menu-toggle__icon::before,
.menu-toggle__icon::after {
	position: absolute;
	left: 0;
	content: "";
}

.menu-toggle__icon::before { top: -6px; }
.menu-toggle__icon::after { top: 6px; }

/* --------------------------------------------------------------------------
   NO JAVASCRIPT — everything visible, nothing that needs a script to open.
   -------------------------------------------------------------------------- */

html:not(.js) .menu-toggle,
html:not(.js) .submenu-toggle {
	display: none;
}

html:not(.js) .site-header__nav {
	padding-block: var(--em-space-4);
	border-top: 1px solid var(--em-color-border);
}

/* -- With JavaScript, small screens --------------------------------------- */

.js .site-header__nav {
	display: none;
}

.js .site-header__nav.is-open {
	display: block;
	padding-block: var(--em-space-3) var(--em-space-5);
	border-top: 1px solid var(--em-color-border);
}

.js .sub-menu {
	display: none;
}

.js .menu-item.is-open > .sub-menu {
	display: block;
}

/* -- With JavaScript, desktop --------------------------------------------- */

@media (min-width: 62rem) {
	.js .site-header__nav {
		display: block;
		padding-block: 0;
		border-top: 0;
	}

	.js .menu-toggle {
		display: none;
	}

	.js .menu--primary {
		display: flex;
		flex-wrap: nowrap;
		align-items: center;
	}

	.js .menu--primary > .menu-item > .menu-item__link {
		display: flex;
		align-items: center;
		padding: var(--em-space-3) var(--em-space-4);
		color: var(--em-color-text);
		font-size: var(--em-text-nav);
		font-weight: var(--em-weight-medium);
		letter-spacing: -0.004em;
		white-space: nowrap;
	}

	.js .menu--primary > .menu-item > .menu-item__link:hover,
	.js .menu--primary > .menu-item:hover > .menu-item__link,
	.js .menu--primary > .menu-item:focus-within > .menu-item__link {
		color: var(--em-color-brand);
		text-decoration: none;
	}

	/* The gold marker, under the label, on the masthead's own white. */
	.js .menu--primary > .menu-item > .menu-item__link::after {
		position: absolute;
		right: var(--em-space-4);
		bottom: -2px;
		left: var(--em-space-4);
		height: 3px;
		background-color: transparent;
		content: "";
		transition: background-color var(--em-duration) var(--em-easing);
	}

	.js .menu--primary > .menu-item:hover > .menu-item__link::after,
	.js .menu--primary > .menu-item:focus-within > .menu-item__link::after,
	.js .menu--primary > .menu-item.current-menu-item > .menu-item__link::after,
	.js .menu--primary > .menu-item.current-menu-ancestor > .menu-item__link::after,
	.js .menu--primary > .menu-item.current_page_item > .menu-item__link::after,
	.js .menu--primary > .menu-item.current_page_ancestor > .menu-item__link::after {
		background-color: var(--em-color-accent);
	}

	.js .menu--primary > .menu-item.current-menu-item > .menu-item__link,
	.js .menu--primary > .menu-item.current_page_item > .menu-item__link,
	.js .menu--primary > .menu-item.current-menu-ancestor > .menu-item__link,
	.js .menu--primary > .menu-item.current-menu-parent > .menu-item__link,
	.js .menu--primary > .menu-item.current_page_ancestor > .menu-item__link {
		box-shadow: none;
		color: var(--em-color-brand);
		font-weight: var(--em-weight-semibold);
	}

	.js .menu--primary > .menu-item > .menu-item__link--static {
		color: var(--em-color-text-muted);
	}

	.js .menu--primary .menu-item-has-children > .menu-item__link {
		padding-right: var(--em-space-6);
	}

	.js .menu--primary .sub-menu {
		position: absolute;
		z-index: var(--em-z-submenu);
		min-width: 17rem;
		max-width: min(24rem, 90vw);
		padding: var(--em-space-3) 0;
		border: 1px solid var(--em-color-border);
		border-radius: var(--em-radius-lg);
		background-color: var(--em-color-bg);
		box-shadow: var(--em-shadow);
	}

	.js .menu--primary .sub-menu .menu-item__link {
		font-size: var(--em-text-sm);
	}

	.js .menu--primary > .menu-item > .sub-menu {
		top: calc(100% + 0.5rem);
		left: 0;
	}

	.js .menu--primary .sub-menu .sub-menu {
		top: calc(var(--em-space-3) * -1);
		left: 100%;
	}

	.js .menu--primary .sub-menu.is-flipped {
		left: auto;
		right: 100%;
	}

	.js .menu--primary > .menu-item > .sub-menu.is-flipped {
		left: auto;
		right: 0;
	}

	.js .menu--primary .sub-menu .menu-item__link {
		padding-left: var(--em-space-5);
		padding-right: var(--em-space-6);
	}

	.js .menu--primary .menu-item:hover > .sub-menu,
	.js .menu--primary .menu-item:focus-within > .sub-menu,
	.js .menu--primary .menu-item.is-open > .sub-menu {
		display: block;
	}

	.js .menu--primary .submenu-toggle {
		width: 2rem;
		height: 2rem;
	}

	.js .menu--primary > .menu-item > .submenu-toggle {
		top: 50%;
		right: var(--em-space-1);
		transform: translateY(-50%);
	}

	.js .menu--primary .sub-menu .menu-item-has-children > .submenu-toggle .submenu-toggle__icon {
		transform: rotate(-45deg) translate(-15%, -15%);
	}

	.js .menu--primary .sub-menu .menu-item-has-children > .submenu-toggle[aria-expanded="true"] .submenu-toggle__icon {
		transform: rotate(135deg) translate(-15%, -15%);
	}
}

/*
 * Between 62rem and 78rem the six roots plus the wordmark and the flags are a
 * few pixels tight. The roots give up padding before anything wraps, which is
 * far less visible than a wrapped menu and keeps the one-row promise.
 */
@media (min-width: 62rem) and (max-width: 78rem) {
	.js .menu--primary > .menu-item > .menu-item__link {
		padding-inline: var(--em-space-2);
		font-size: var(--em-text-sm);
	}

	.js .menu--primary > .menu-item > .menu-item__link::after {
		right: var(--em-space-2);
		left: var(--em-space-2);
	}

	.js .menu--primary .menu-item-has-children > .menu-item__link {
		padding-right: var(--em-space-5);
	}
}


/* ==========================================================================
   7  LANGUAGE SWITCHER — EUROMIG BUSINESS

   FLAGS. Two local SVG files in this theme — not emoji, which render as a
   different picture on every platform and as nothing at all on some, and not a
   third-party icon set, which would be an external request and a licence.

   Each flag is drawn at its own true ratio: the Union Flag is 1:2, the Russian
   tricolour 2:3. They share a height rather than a box, because forcing both
   into one box would mean cropping or distorting a national flag.

   ACCESSIBILITY. A flag is a country, not a language, and an image carries no
   accessible name. Every entry keeps the language's own native name as REAL
   TEXT in a visually-hidden span — real text rather than `aria-label`, because
   it survives a stylesheet that fails to load. The image is `alt=""` and
   `aria-hidden`, so the name is announced exactly once.
   ========================================================================== */

.language-switcher__list {
	display: flex;
	align-items: center;
	gap: var(--em-space-1);
	margin: 0;
	padding: 0;
	list-style: none;
}

.language-switcher__item {
	margin: 0;
}

.language-switcher__item + .language-switcher__item {
	margin-top: 0;
}

.language-switcher__label {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-width: 2.75rem;
	min-height: 2.75rem;
	padding: var(--em-space-2);
	border: 1px solid transparent;
	border-radius: var(--em-radius);
	text-decoration: none;
	transition: border-color var(--em-duration) var(--em-easing),
	            background-color var(--em-duration) var(--em-easing),
	            opacity var(--em-duration) var(--em-easing);
}

.language-switcher__flag {
	display: block;
	width: auto;
	height: 0.9375rem;
	border-radius: 2px;
	/* A hairline, so a flag with a white band keeps its edge on white. */
	box-shadow: 0 0 0 1px rgba(20, 22, 27, 0.16);
}

/*
 * An unselected language is legible but quiet, and comes fully forward on
 * hover or focus. Opacity alone would fail contrast if it carried text; it
 * carries only a flag, and the accessible name is unaffected by it.
 */
a.language-switcher__label {
	opacity: 0.55;
}

a.language-switcher__label:hover,
a.language-switcher__label:focus-visible {
	background-color: var(--em-color-surface);
	opacity: 1;
}

.language-switcher__item.is-current .language-switcher__label {
	border-color: var(--em-color-brand);
	opacity: 1;
}

/* No translation exists. Shown, plainly not on offer, and not a link. */
.language-switcher__item.is-unavailable .language-switcher__label {
	cursor: not-allowed;
	opacity: 0.3;
}

.language-switcher__item.is-unavailable .language-switcher__flag {
	filter: grayscale(1);
}


/* ==========================================================================
   8  SITE FOOTER — EUROMIG BUSINESS

   A LIGHT footer with a narrow navy bar under it, rather than the full navy
   sitemap the baseline used. Navigation is easier to read on a neutral ground,
   and the dark band is reserved for the one line that is genuinely closing
   matter: the name, the year and the language control.

   No contact block. The telephone numbers, addresses and bank details all live
   on the Contacts page, and a second copy in a template is a second thing to
   maintain.
   ========================================================================== */

.site-footer {
	flex-shrink: 0;
	margin-top: 0;
	border-top: 1px solid var(--em-color-border);
	background-color: var(--em-color-surface);
	color: var(--em-color-text);
}

.site-footer a {
	color: var(--em-color-text);
	text-decoration: none;
}

.site-footer a:hover,
.site-footer a:focus-visible {
	color: var(--em-color-brand);
	text-decoration: underline;
}

.site-footer__inner {
	display: grid;
	gap: var(--em-space-6);
	padding-block: var(--em-section-sm) var(--em-space-6);
}

.site-footer__brand .site-branding {
	margin-bottom: var(--em-space-4);
}

/*
 * No white plate here, and none needed: the footer ground is light, so the
 * wordmark's navy half reads as it does in the header.
 */
.site-footer__brand .site-logo,
.site-footer__brand .custom-logo {
	max-height: 2.75rem;
}

.site-footer__statement {
	max-width: 34ch;
	margin: 0 0 var(--em-space-4);
	color: var(--em-color-text-muted);
	font-size: var(--em-text-base);
	line-height: var(--em-leading-normal);
}

.site-footer__action {
	margin: 0;
}

.site-footer__nav {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(min(100%, 10rem), 1fr));
	gap: var(--em-space-5);
}

.site-footer__heading {
	margin: 0 0 var(--em-space-4);
	color: var(--em-color-brand);
	font-size: var(--em-text-sm);
	font-weight: var(--em-weight-semibold);
	letter-spacing: var(--em-tracking-wide);
	text-transform: uppercase;
}

/*
 * A HEADING THAT IS ALSO A LINK IS A CONTROL, and this one was 19 pixels tall
 * — under the 24px WCAG 2.5.8 asks of a target that is not inside a sentence.
 * The `inline` exception does not apply to a column heading. Padding rather
 * than a larger type size, so the footer keeps the height CASE 11.3 just took
 * out of it.
 */
.site-footer__heading a {
	display: inline-block;
	padding-block: var(--em-space-3);
	margin-block: calc(var(--em-space-3) * -1) 0;
	color: var(--em-color-brand);
}

.site-footer__links {
	margin: 0;
	padding: 0;
	list-style: none;
	font-size: var(--em-text-sm);
	line-height: var(--em-leading-snug);
}

/*
 * 8px between links rather than 12. Four groups of five links is 20 rows; the
 * change takes 80 pixels off the footer and the rows are still 15px text on a
 * 1.28 leading, which keeps each one comfortably above a 24px target.
 */
.site-footer__links li + li {
	margin-top: var(--em-space-2);
}

.site-footer__links a {
	color: var(--em-color-text-muted);
}

/* -- The closing bar ------------------------------------------------------ */

.site-footer__bar {
	border-top: 3px solid var(--em-color-accent);
	background-color: var(--em-color-brand);
	color: var(--em-color-on-brand);
}

.site-footer__bar-inner {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: var(--em-space-3) var(--em-space-5);
	padding-block: var(--em-space-4);
}

.site-footer__bar a {
	color: var(--em-color-on-brand);
}

.site-footer__bar a:hover,
.site-footer__bar a:focus-visible {
	color: var(--em-color-accent);
}

.site-footer__bar :focus-visible {
	outline-color: var(--em-color-accent);
}

.site-footer__legal {
	display: flex;
	flex-wrap: wrap;
	gap: var(--em-space-2) var(--em-space-4);
	margin: 0;
	color: var(--em-color-on-brand-muted);
	font-size: var(--em-text-sm);
}

.site-footer__name {
	color: var(--em-color-on-brand);
	font-weight: var(--em-weight-semibold);
}

/* The flags invert on the navy bar. */
.site-footer__bar .language-switcher__label {
	min-width: 2.5rem;
	min-height: 2.5rem;
}

.site-footer__bar a.language-switcher__label:hover,
.site-footer__bar a.language-switcher__label:focus-visible {
	background-color: var(--em-color-on-brand-wash);
}

.site-footer__bar .language-switcher__item.is-current .language-switcher__label {
	border-color: var(--em-color-accent);
}

@media (min-width: 62rem) {
	.site-footer__inner {
		grid-template-columns: minmax(15rem, 20rem) 1fr;
		column-gap: var(--em-space-8);
		padding-block: var(--em-section-sm) var(--em-space-6);
	}
}


/* ==========================================================================
   9  ENTRIES AND MIGRATED CLASSIC CONTENT

   Years of hand-written HTML live in `post_content`. None of it is rewritten
   at render time — these rules make it behave.
   ========================================================================== */

.entry + .entry,
.entry + .post-navigation {
	margin-top: var(--em-space-7);
}

.entry-header {
	margin-bottom: var(--em-space-5);
}

.entry-meta {
	color: var(--em-color-text-muted);
	font-size: var(--em-text-sm);
}

.entry-meta > * + * {
	margin-left: var(--em-space-3);
}

.entry-image {
	display: block;
	margin-bottom: var(--em-space-5);
}

.entry-image img {
	border-radius: var(--em-radius);
}

.entry-content > :last-child {
	margin-bottom: 0;
}

/* --------------------------------------------------------------------------
   READING RHYTHM.

   This is the half of the 66ch removal that is easy to forget. A wider column
   is harder to read at the same leading, because the eye has further to travel
   to find the start of the next line — so the leading goes up, the space
   between paragraphs goes up, and the headings get a stronger step, exactly as
   CASE 11.3 TASK 4 requires.

   None of it makes the text smaller: body copy stays at 18px.
   -------------------------------------------------------------------------- */

.entry-content {
	line-height: var(--em-leading-loose);
}

.entry-content p,
.entry-content ul,
.entry-content ol,
.entry-content blockquote,
.entry-content figure {
	margin-bottom: var(--em-space-5);
}

.entry-content li + li {
	margin-top: var(--em-space-2);
}

.entry-content ul,
.entry-content ol {
	padding-left: var(--em-space-6);
}

/*
 * A clear step at each level, and more air above a heading than below it, so a
 * heading belongs to what follows rather than floating between two blocks.
 */
.entry-content h2 {
	margin-top: var(--em-space-8);
	margin-bottom: var(--em-space-4);
	font-size: var(--em-text-lg);
	letter-spacing: var(--em-tracking-tight);
	line-height: var(--em-leading-snug);
}

.entry-content h3 {
	margin-top: var(--em-space-7);
	margin-bottom: var(--em-space-3);
	font-size: var(--em-text-md);
	line-height: var(--em-leading-snug);
}

.entry-content h4,
.entry-content h5,
.entry-content h6 {
	margin-top: var(--em-space-6);
	margin-bottom: var(--em-space-3);
}

/* Classic alignment classes, still in the stored HTML. */
.alignleft {
	float: left;
	margin: 0 var(--em-space-5) var(--em-space-4) 0;
}

.alignright {
	float: right;
	margin: 0 0 var(--em-space-4) var(--em-space-5);
}

.aligncenter {
	display: block;
	margin-inline: auto;
}

.alignnone {
	margin-bottom: var(--em-space-4);
}

.entry-content::after {
	display: table;
	clear: both;
	content: "";
}

/* Captions and galleries, in both the old and the html5 markup. */
.wp-caption {
	max-width: 100%;
	margin-bottom: var(--em-space-4);
}

.wp-caption img {
	border-radius: var(--em-radius);
}

.wp-caption-text,
.wp-caption .wp-caption-text {
	margin-top: var(--em-space-2);
	color: var(--em-color-text-muted);
	font-size: var(--em-text-sm);
	text-align: center;
}

.gallery {
	display: flex;
	flex-wrap: wrap;
	gap: var(--em-space-3);
	margin-bottom: var(--em-space-5);
}

.gallery-item {
	flex: 1 1 8rem;
	margin: 0;
	text-align: center;
}

.gallery-columns-2 .gallery-item { flex-basis: calc(50% - var(--em-space-3)); }
.gallery-columns-3 .gallery-item { flex-basis: calc(33.333% - var(--em-space-3)); }
.gallery-columns-4 .gallery-item { flex-basis: calc(25% - var(--em-space-3)); }

/* --------------------------------------------------------------------------
   MIGRATED TABLES.

   THE ROOT CAUSE OF THE SCROLLBARS HUMAN REVIEW REPORTED, in full, because it
   was one rule doing two unintended things.

   The rule that used to stand here was:

       .entry-content table { display: block; max-width: 100%; overflow-x: auto }

   `display: block` stops a table being a table — it becomes a box with the
   rows laid out inside it — and `overflow-x: auto` makes that box scroll. Two
   consequences followed, and both were visible on `/contacts/`:

     1. HORIZONTAL. The stored markup of page 192 opens with
        `<table style="width: 956px; height: 467px" align="left" border="1">`.
        Inside a `.entry-content` capped at 66ch — 687 pixels — a 956-pixel box
        must scroll. Removing the cap (section 4) removes this cause outright.

     2. VERTICAL, and this is the one that was not obvious. CSS says that when
        one overflow axis is not `visible`, the other computes to `auto` too.
        So `overflow-x: auto` silently made `overflow-y: auto` as well, and the
        inline `height: 467px` then clipped a table whose real content is about
        1,345 pixels tall. The measured result was 878 pixels of content behind
        an internal vertical scrollbar — bank details, opening hours and the
        e-mail address among them.

   THE FIX IS NOT `overflow: hidden`. That would hide the scrollbar and keep
   the clipping, which CASE 11.3's own status rule calls a BLOCKED outcome. The
   table is made a table again, told to use the width it now has, and released
   from the stored height.

   `!important` APPEARS TWICE BELOW AND ONLY TWICE. An inline `style` attribute
   outranks every author selector, so `width` and `height` on that one element
   cannot be reached any other way — not by specificity, not by order. The
   alternatives were rewriting stored `post_content`, which this case forbids,
   or a PHP filter that re-parses every page's HTML on every request. Two
   declarations, named, in the rule that owns tables, is the smaller cost.
   Nothing else in this section uses it.
   -------------------------------------------------------------------------- */

.entry-content table {
	display: table;
	width: 100% !important;   /* beats style="width: 956px" on 5 legacy tables */
	max-width: 100%;
	height: auto !important;  /* beats style="height: 467px" — the vertical clip */
	table-layout: auto;
	border-collapse: collapse;
	border-spacing: 0;
	float: none;              /* legacy align="left" on 3 tables */
	margin-bottom: var(--em-space-5);
	font-size: var(--em-text-sm);
	line-height: var(--em-leading-snug);
	overflow: visible;
	white-space: normal;
}

/*
 * `table-layout: auto` treats a `width` attribute as a hint, so the 1,090
 * legacy `td width="…"` values still influence the proportions of a table
 * without being able to force one wider than its column. `overflow-wrap`
 * covers the long IBANs and SWIFT codes in the Contacts table, which are
 * single unbreakable tokens.
 */
.entry-content th,
.entry-content td {
	max-width: 100%;
	padding: var(--em-space-3) var(--em-space-4);
	border: 1px solid var(--em-color-table-border);
	vertical-align: top;
	overflow-wrap: anywhere;
	word-break: normal;
}

.entry-content th {
	background-color: var(--em-color-surface);
	font-weight: var(--em-weight-semibold);
	text-align: left;
}

.entry-content caption {
	margin-bottom: var(--em-space-2);
	color: var(--em-color-text-muted);
	font-size: var(--em-text-sm);
	text-align: left;
}

/*
 * Legacy `<img width="80" height="19">` inside a cell. The attributes are
 * presentational hints, so ordinary declarations beat them; what matters is
 * that a 300-pixel photograph in a narrow column shrinks with the column
 * instead of forcing it open.
 */
.entry-content td img,
.entry-content th img {
	max-width: 100%;
	height: auto;
}

/*
 * A table that genuinely cannot fit — 73 rows of four columns of Lithuanian
 * job titles, at 320 pixels — may still be handed a scrolling parent by the
 * stored markup. The wrapper keeps working for that case; nothing in the
 * theme creates one.
 */
.table-scroll {
	max-width: 100%;
	overflow-x: auto;
}

.table-scroll > table {
	width: 100%;
}

/* Old fixed-width iframes and embeds. */
.entry-content iframe,
.entry-content embed,
.entry-content object,
.entry-content video {
	max-width: 100%;
}

.entry-content iframe[src*="youtube"],
.entry-content iframe[src*="youtu.be"],
.entry-content iframe[src*="vimeo"] {
	aspect-ratio: 16 / 9;
	width: 100%;
	height: auto;
}

/* Long unbroken URLs in old content must not push the page wide. */
.entry-content a {
	overflow-wrap: anywhere;
}

.no-results {
	padding: var(--em-space-6);
	border: 1px solid var(--em-color-border);
	border-radius: var(--em-radius);
	background-color: var(--em-color-surface);
}

.plugin-notice {
	padding: var(--em-space-3) var(--em-space-4);
	border-left: 4px solid var(--em-color-warning);
	background-color: var(--em-color-surface);
	color: var(--em-color-text);
}


/* ==========================================================================
   10  COMPONENTS
   ========================================================================== */

/* -- The no-image treatment ---------------------------------------------- */
/*
 * A listing with no photograph. Not a grey rectangle and not a collapsed card:
 * the brand ground at the same ratio as a photograph, carrying a quiet
 * diagonal rule pattern in the accent colour.
 *
 * IT IS NOT THE BASELINE'S CONCENTRIC-RING MARK. That graphic belonged to the
 * design this candidate replaces, and reusing it here would blur the one thing
 * the comparison is for. The rules are two repeating gradients — no file, no
 * request, nothing to load — and they say nothing, which is why the element
 * that carries them is empty and `aria-hidden`.
 */

.card__mark {
	position: absolute;
	inset: 0;
	overflow: hidden;
	background-color: var(--em-color-brand);
	background-image:
		repeating-linear-gradient(135deg, rgba(255, 190, 0, 0.16) 0 1px, transparent 1px 14px),
		repeating-linear-gradient(45deg, rgba(255, 255, 255, 0.07) 0 1px, transparent 1px 28px);
	pointer-events: none;
}

/* -- Buttons ------------------------------------------------------------- */
/*
 * Sized as controls, not as links with a background. 2.875rem of height at
 * every breakpoint clears the 44px touch target with room to spare, and the
 * primary and secondary weights are far enough apart that the secondary reads
 * as a choice rather than as something switched off.
 */

/*
 * Larger than the baseline's, because the reference's are: a call to action on
 * a consultancy homepage is a component, not a styled link.
 */
.button,
button.button {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: var(--em-space-2);
	min-height: 3rem;
	padding: var(--em-space-3) var(--em-space-6);
	border: 2px solid transparent;
	border-radius: var(--em-radius);
	font-family: inherit;
	font-size: var(--em-text-button);
	font-weight: var(--em-weight-semibold);
	line-height: var(--em-leading-snug);
	text-align: center;
	text-decoration: none;
	cursor: pointer;
	transition: background-color var(--em-duration) var(--em-easing),
	            border-color var(--em-duration) var(--em-easing),
	            color var(--em-duration) var(--em-easing);
}

/* The hero's pair, sized to carry the composition beneath a 69px headline. */
.button--large {
	min-height: 3.5rem;
	padding-inline: var(--em-space-7);
	font-size: var(--em-text-base);
}

.button--primary {
	border-color: var(--em-color-brand);
	background-color: var(--em-color-brand);
	color: var(--em-color-on-brand);
}

.button--primary:hover,
.button--primary:focus-visible {
	border-color: var(--em-color-brand-dark);
	background-color: var(--em-color-brand-dark);
	color: var(--em-color-on-brand);
}

.button--secondary {
	border-color: var(--em-color-brand);
	background-color: transparent;
	color: var(--em-color-brand);
}

.button--secondary:hover,
.button--secondary:focus-visible {
	background-color: var(--em-color-brand-tint);
	color: var(--em-color-brand-dark);
}

.button--accent {
	border-color: var(--em-color-accent);
	background-color: var(--em-color-accent);
	color: var(--em-color-accent-ink);
}

.button--accent:hover,
.button--accent:focus-visible {
	border-color: var(--em-color-accent-hover);
	background-color: var(--em-color-accent-hover);
	color: var(--em-color-accent-ink);
}

/*
 * A text action. It keeps the button's vertical size so that a row mixing the
 * two does not look ragged, and it carries an arrow rather than an underline —
 * the arrow marks it as a route onward instead of a footnote.
 */
.button--text {
	min-height: 2.5rem;
	padding-inline: 0;
	border-color: transparent;
	background: none;
	color: var(--em-color-brand);
	font-size: var(--em-text-base);
	text-decoration: none;
}

.button--text::after {
	content: "\2192";
	font-weight: var(--em-weight-regular);
	transition: transform var(--em-duration) var(--em-easing);
}

.button--text:hover,
.button--text:focus-visible {
	color: var(--em-color-brand-dark);
	text-decoration: underline;
}

.button--text:hover::after {
	transform: translateX(3px);
}

.button[disabled],
.button.is-disabled,
button[disabled] {
	opacity: 0.55;
	cursor: not-allowed;
	pointer-events: none;
}

/* -- Section headers ----------------------------------------------------- */
/*
 * One heading device for the whole site: a short gold rule, an optional
 * eyebrow, the heading, and an optional lead held to a reading measure. Used
 * by every homepage section, so their headings cannot drift apart.
 */

/*
 * No rule across the top. The baseline used a gold hairline above every
 * heading; at this scale and this section rhythm the space does the separating,
 * and an eyebrow above the heading gives the section its label.
 */
.section-header {
	margin-bottom: var(--em-section-sm);
}

.section-header--centred {
	max-width: 46rem;
	margin-inline: auto;
	text-align: center;
}

.section-header--centred .section-header__lead {
	margin-inline: auto;
}

.section-header__eyebrow {
	margin: 0 0 var(--em-space-3);
	color: var(--em-color-text-muted);
	font-size: var(--em-text-xs);
	font-weight: var(--em-weight-semibold);
	letter-spacing: var(--em-tracking-wide);
	text-transform: uppercase;
}

.section-header--split {
	display: flex;
	flex-wrap: wrap;
	align-items: flex-end;
	justify-content: space-between;
	gap: var(--em-space-4) var(--em-space-6);
}

/* A heading and one sentence, not body copy — see `--em-measure-lede`. */
.section-header--split > :first-child {
	max-width: var(--em-measure-lede);
}

.section-header__title {
	max-width: 20ch;
	margin: 0;
	font-size: var(--em-text-xl);
	font-weight: var(--em-weight-bold);
	letter-spacing: var(--em-tracking-tight);
	line-height: var(--em-leading-tight);
}

.section-header--centred .section-header__title {
	max-width: none;
}

.section-header__lead {
	max-width: 56ch;
	margin: var(--em-space-3) 0 0;
	color: var(--em-color-text-muted);
	font-size: var(--em-text-base);
	line-height: var(--em-leading-normal);
}

.section-header__action {
	flex: 0 0 auto;
}

/* -- Form primitives ----------------------------------------------------- */
/*
 * The look of a form, ready for CASE 13 to attach a real one to. There is no
 * form here that submits anywhere, and there is no handler in the theme.
 */

.form-field {
	margin-bottom: var(--em-space-4);
}

label,
.form-label {
	display: block;
	margin-bottom: var(--em-space-2);
	font-size: var(--em-text-sm);
	font-weight: var(--em-weight-medium);
}

input[type="text"],
input[type="email"],
input[type="url"],
input[type="tel"],
input[type="number"],
input[type="password"],
input[type="search"],
input[type="date"],
select,
textarea {
	width: 100%;
	max-width: 100%;
	min-height: 2.875rem;
	padding: var(--em-space-3);
	border: 1px solid var(--em-color-border-strong);
	border-radius: var(--em-radius);
	background-color: var(--em-color-bg);
	color: var(--em-color-text);
	font-family: inherit;
	font-size: var(--em-text-base);
	line-height: var(--em-leading-snug);
}

textarea {
	min-height: 8rem;
	resize: vertical;
}

input:hover,
select:hover,
textarea:hover {
	border-color: var(--em-color-brand);
}

input[aria-invalid="true"],
select[aria-invalid="true"],
textarea[aria-invalid="true"] {
	border-color: var(--em-color-danger);
}

.form-help {
	margin-top: var(--em-space-1);
	color: var(--em-color-text-muted);
	font-size: var(--em-text-sm);
}

.form-error {
	margin-top: var(--em-space-1);
	color: var(--em-color-danger);
	font-size: var(--em-text-sm);
	font-weight: var(--em-weight-medium);
}

.form-choice {
	display: flex;
	align-items: flex-start;
	gap: var(--em-space-2);
}

.form-choice input[type="checkbox"],
.form-choice input[type="radio"] {
	width: auto;
	min-height: 0;
	margin-top: 0.3em;
	accent-color: var(--em-color-brand);
}

.form-choice label {
	margin-bottom: 0;
	font-weight: var(--em-weight-regular);
}

/* -- Search form --------------------------------------------------------- */

.search-form {
	max-width: 34rem;
	margin-bottom: var(--em-space-5);
}

.search-form__label {
	position: absolute !important;
	width: 1px;
	height: 1px;
	overflow: hidden;
	clip-path: inset(50%);
	white-space: nowrap;
}

.search-form__controls {
	display: flex;
	gap: var(--em-space-2);
}

.search-form__input {
	flex: 1 1 auto;
	min-width: 0;
}

.search-form__submit {
	flex: 0 0 auto;
}

/* -- Cards --------------------------------------------------------------- */
/*
 * ONE information hierarchy, in this order and no other: picture, status,
 * name, price, sector. Human review found the CASE 11 card competing with
 * itself — four text sizes inside 300 pixels, uppercase metadata as small as
 * the badge, and a price that landed at a different height in every column.
 *
 * The fixes are structural. The media has a fixed ratio so a row of cards is a
 * row rather than a staircase; the status badge moved ONTO the picture, which
 * removed a whole text row from the body; the title is clamped to two lines;
 * and the price is pinned to the bottom of the body with the sector beneath it
 * on a rule, so prices align across a row whatever the titles did.
 */

.card {
	position: relative;
	display: flex;
	flex-direction: column;
	overflow: hidden;
	border: 1px solid var(--em-color-border);
	border-radius: var(--em-radius-lg);
	background-color: var(--em-color-bg);
	transition: border-color var(--em-duration) var(--em-easing),
	            box-shadow var(--em-duration) var(--em-easing),
	            transform var(--em-duration) var(--em-easing);
}

.card:hover,
.card:focus-within {
	border-color: transparent;
	box-shadow: var(--em-shadow);
	transform: translateY(-3px);
}

.card__media {
	position: relative;
	overflow: hidden;
	background-color: var(--em-color-surface-strong);
}

/*
 * 3:2 rather than 3:2-or-whatever-the-file-is. The source images are a genuine
 * mixture — 275x183 photographs beside 1654x1654 renders — and a shared ratio
 * with `object-fit: cover` is the only thing that makes six of them read as one
 * component. Nothing is stretched: cover crops, it never distorts.
 */
.card__media img,
.card__image {
	width: 100%;
	aspect-ratio: 3 / 2;
	object-fit: cover;
	object-position: center;
}

.card__body {
	display: flex;
	flex: 1 1 auto;
	flex-direction: column;
	gap: var(--em-space-3);
	padding: var(--em-space-6);
}

.card__title {
	margin: 0;
	font-size: var(--em-text-lg);
	font-weight: var(--em-weight-semibold);
	line-height: var(--em-leading-snug);
	letter-spacing: -0.008em;
}

.card__title a {
	text-decoration: none;
}

.card__title a:hover,
.card__title a:focus-visible {
	text-decoration: underline;
}

.card__meta {
	display: flex;
	flex-wrap: wrap;
	gap: var(--em-space-2) var(--em-space-3);
	margin: 0;
	color: var(--em-color-text-muted);
	font-size: var(--em-text-sm);
}

.card__meta > * + * {
	margin-left: 0;
}

.card__excerpt {
	color: var(--em-color-text);
	font-size: var(--em-text-sm);
	line-height: var(--em-leading-normal);
}

.card__excerpt p:last-child {
	margin-bottom: 0;
}

.card__price {
	margin: auto 0 0;
}

.card__actions {
	display: flex;
	flex-wrap: wrap;
	gap: var(--em-space-2);
	margin-top: auto;
	padding-top: var(--em-space-2);
}

/*
 * A card with no picture. Not a grey rectangle and not a collapsed card: the
 * brand mark on the brand ground, at the same ratio as a photograph, so a row
 * containing one still reads as a row.
 */
.card__media--empty {
	position: relative;
	aspect-ratio: 3 / 2;
	background-color: var(--em-color-brand);
}

/* -- Badges -------------------------------------------------------------- */
/*
 * The status TEXT always comes from the domain layer. These rules colour a
 * token the plugin emitted; they encode no business meaning of their own.
 */

.badge {
	display: inline-block;
	padding: 0.3em 0.75em;
	border-radius: var(--em-radius-sm);
	background-color: var(--em-color-surface-strong);
	color: var(--em-color-text);
	font-size: var(--em-text-xs);
	font-weight: var(--em-weight-semibold);
	letter-spacing: 0.04em;
	line-height: 1.4;
	text-transform: uppercase;
	white-space: nowrap;
}

.badge.is-available,
.badge.is-re-status-0 {
	background-color: var(--em-color-success);
	color: var(--em-color-on-status);
}

.badge.is-reserved,
.badge.is-re-status-2 {
	background-color: var(--em-color-warning);
	color: var(--em-color-on-status);
}

.badge.is-sold,
.badge.is-re-status-1 {
	background-color: var(--em-color-danger);
	color: var(--em-color-on-status);
}

.badge.is-coming-soon,
.badge.is-re-status-3 {
	background-color: var(--em-color-accent);
	color: var(--em-color-accent-ink);
}

/* -- Prices -------------------------------------------------------------- */

.price {
	color: var(--em-color-brand);
	font-size: var(--em-text-lg);
	font-weight: var(--em-weight-bold);
	letter-spacing: -0.01em;
	font-variant-numeric: tabular-nums;
}

.price--unspecified {
	color: var(--em-color-text-muted);
	font-size: var(--em-text-base);
	font-weight: var(--em-weight-medium);
}

/* -- Facts tables -------------------------------------------------------- */

.facts-table th {
	width: 40%;
	color: var(--em-color-text-muted);
	font-weight: var(--em-weight-medium);
}

/* -- Pagination and post navigation -------------------------------------- */

.pagination {
	margin-top: var(--em-space-8);
}

/*
 * TWO MARKUP SHAPES, ONE LOOK. Core's `the_posts_pagination()` emits
 * `.nav-links` and `.page-numbers`; the marketplace builds its own control,
 * because it paginates the plugin's result set rather than the main query and
 * has to work on a page route as well as an archive route. Rather than write a
 * second visual language for it, its class names join these rules.
 */
.pagination .nav-links,
.pagination__list {
	display: flex;
	flex-wrap: wrap;
	gap: var(--em-space-2);
	align-items: center;
	margin: 0;
	padding: 0;
	list-style: none;
}

.pagination__item {
	margin: 0;
}

.pagination .page-numbers,
.pagination__link {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-width: 2.75rem;
	height: 2.75rem;
	padding-inline: var(--em-space-3);
	border: 1px solid var(--em-color-border);
	border-radius: var(--em-radius);
	font-size: var(--em-text-sm);
	font-weight: var(--em-weight-medium);
	text-decoration: none;
}

.pagination a.page-numbers:hover,
.pagination a.page-numbers:focus-visible,
a.pagination__link:hover,
a.pagination__link:focus-visible {
	border-color: var(--em-color-brand);
	background-color: var(--em-color-brand-tint);
}

.pagination .page-numbers.current,
.pagination__link.is-current {
	border-color: var(--em-color-brand);
	background-color: var(--em-color-brand);
	color: var(--em-color-on-brand);
	font-weight: var(--em-weight-semibold);
}

.pagination__item--gap {
	padding-inline: var(--em-space-2);
	color: var(--em-color-text-muted);
}

.pagination .page-numbers.dots {
	border-color: transparent;
}

.post-navigation {
	margin-top: var(--em-space-8);
	padding-top: var(--em-space-6);
	border-top: 1px solid var(--em-color-border);
}

.post-navigation .nav-links {
	display: flex;
	flex-wrap: wrap;
	justify-content: space-between;
	gap: var(--em-space-5);
}

.post-navigation a {
	text-decoration: none;
}

.post-nav__direction {
	display: block;
	margin-bottom: var(--em-space-1);
	color: var(--em-color-text-muted);
	font-size: var(--em-text-xs);
	text-transform: uppercase;
	letter-spacing: var(--em-tracking-wide);
}

.post-nav__title {
	font-size: var(--em-text-base);
	font-weight: var(--em-weight-medium);
	text-decoration: underline;
}

.page-links {
	margin-top: var(--em-space-5);
	font-weight: var(--em-weight-medium);
}


/* ==========================================================================
   11  POST-TYPE SURFACES
   ========================================================================== */

.post-list,
.listing-grid,
.consultant-grid {
	display: grid;
	gap: var(--em-space-6);
}

.post-list {
	grid-template-columns: 1fr;
}

.listing-grid,
.consultant-grid {
	grid-template-columns: repeat(auto-fill, minmax(min(100%, 18rem), 1fr));
}

/*
 * The marketplace renders its grid as a LIST, because twelve businesses are a
 * list of twelve businesses and a screen reader should be told how many there
 * are before reading the first. The list semantics cost nothing visually.
 */
.listing-grid {
	margin: 0;
	padding: 0;
	list-style: none;
}

.listing-grid__item {
	display: flex;
	margin: 0;
}

.listing-grid__item > .card {
	width: 100%;
}

.post-list--search {
	gap: var(--em-space-6);
}

.entry--search .entry-title {
	font-size: var(--em-text-lg);
}

.entry-meta__type {
	display: inline-block;
	padding: 0.2em 0.6em;
	border-radius: var(--em-radius-sm);
	background-color: var(--em-color-surface-strong);
	font-size: var(--em-text-xs);
	text-transform: uppercase;
	letter-spacing: 0.04em;
}

/* -- The listing card ---------------------------------------------------- */

/*
 * The badge sits on the picture. That is one fewer row of text in the body,
 * and it puts the single most decisive fact — whether this business can still
 * be bought — where the eye already is.
 */
.sales-card__status {
	position: absolute;
	top: var(--em-space-3);
	left: var(--em-space-3);
	z-index: 1;
	margin: 0;
}

.sales-card__status .badge {
	box-shadow: 0 1px 3px rgba(22, 24, 29, 0.35);
}

/* Three lines, then an ellipsis. Titles here run from 9 to 96 characters. */
.sales-card .card__title {
	display: -webkit-box;
	overflow: hidden;
	-webkit-box-orient: vertical;
	-webkit-line-clamp: 3;
	line-clamp: 3;
	font-size: var(--em-text-md);
}

.sales-card .card__excerpt {
	display: -webkit-box;
	overflow: hidden;
	color: var(--em-color-text-muted);
	-webkit-box-orient: vertical;
	-webkit-line-clamp: 2;
	line-clamp: 2;
}

/*
 * The excerpt takes the slack, so the price lands on the same line across a
 * row whatever the title length or an extra note did to one card.
 */
.sales-card__body .card__excerpt {
	flex: 1 1 auto;
}

.sales-card .card__price {
	padding-top: var(--em-space-1);
}

/*
 * Sector and country, on a rule, below the price. Small, but no longer the
 * same size as the badge it used to sit beside — it is the least important
 * line on the card and now looks like it.
 */
.sales-card__terms {
	gap: var(--em-space-1) var(--em-space-3);
	margin-top: var(--em-space-3);
	padding-top: var(--em-space-3);
	border-top: 1px solid var(--em-color-border);
	color: var(--em-color-text-muted);
	font-size: var(--em-text-xs);
	letter-spacing: 0.03em;
	text-transform: uppercase;
}

/* Only between the two, never in front of a country that stands alone. */
.sales-card__activity + .sales-card__country::before {
	margin-right: var(--em-space-3);
	color: var(--em-color-border-strong);
	content: "\2022";
}

/*
 * `is_featured` no longer draws anything. It was a gold border with no label,
 * which told a visitor nothing and read in a row of six as a rendering fault.
 * The flag still does its real job — it floats a listing to the front of the
 * homepage teaser — which is ordering, not decoration.
 */

.sales-meta,
.realestate-meta {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: var(--em-space-3);
}

.sales-meta > * + *,
.realestate-meta > * + * {
	margin-left: 0;
}

/* -- Consultants --------------------------------------------------------- */

.consultant-card {
	flex-direction: row;
	align-items: flex-start;
	gap: var(--em-space-4);
	padding: var(--em-space-5);
}

.consultant-card .card__body {
	padding: 0;
}

.consultant-card__media {
	flex: 0 0 6rem;
	border-radius: var(--em-radius);
}

.consultant-card .consultant-card__photo {
	aspect-ratio: 1 / 1;
	object-fit: cover;
}

.consultant-card__contact {
	margin: 0;
	padding: 0;
	list-style: none;
	font-size: var(--em-text-sm);
}

.consultant-grid .consultant-card {
	flex-direction: column;
}

.consultant-grid .consultant-card__media {
	flex-basis: auto;
	width: 100%;
}


/* ==========================================================================
   12  HOMEPAGE — EUROMIG BUSINESS

   Large sections, generous rhythm, and one tinted band. The reference the
   client supplied works because its sections are big and its components are
   big; the composition below follows that, using only content this site
   actually publishes.
   ========================================================================== */

.home-section {
	padding-block: var(--em-section-md);
}

.home-section--tinted {
	background-color: var(--em-color-surface);
}

/* --------------------------------------------------------------------------
   Hero — statement left, capability panel right.

   The right column is a designed CONTENT block rather than a photograph,
   because there is no photograph this site can honestly put there: all 27
   landscape images wide enough belong to a named listing, consultant or
   article, and downloading stock is prohibited.
   -------------------------------------------------------------------------- */

/*
 * THE HERO GROUND. Human review: "the homepage currently feels too white",
 * and the hero was the largest white surface on it — 720 pixels of #ffffff
 * with a navy panel floating in the middle of it.
 *
 * What is here is three layers of CSS and nothing else. No image is requested,
 * no file is added to the theme, and the whole treatment costs zero bytes of
 * transfer beyond the rule itself:
 *
 *   1. a page-wide wash from #f4f6fb at the top to #ffffff at the bottom, so
 *      the hero has a ground and the section under it still starts on white;
 *   2. a wide, very soft navy glow behind the top right, which is where the
 *      capability panel sits — it gives the panel something to sit ON;
 *   3. a small gold wash at the bottom left, under the actions, at 10 %.
 *
 * The decorative layer in `::before` is a set of PARALLEL DIAGONAL RULES at
 * 116°, one pixel wide, 68 pixels apart, in navy at 5.5 % — measured at
 * roughly 1.04:1 against the wash, which is at the edge of visible and is the
 * point. Routes across a map, not a target: nothing here is concentric,
 * nothing radiates from a centre, and nothing marks a place. The mask fades
 * the rules out before they reach the headline, so they never cross the H1.
 *
 * The whole layer is `pointer-events: none` and sits at `z-index: -1` inside
 * an isolated stacking context, so it cannot intercept a click and cannot
 * escape the section.
 */
.home-hero {
	position: relative;
	z-index: 0;
	isolation: isolate;
	overflow: hidden;
	padding-block: var(--em-section-md);
	background-image:
		radial-gradient(70rem 34rem at 78% -14%, rgba(0, 28, 114, 0.085) 0%, rgba(0, 28, 114, 0) 62%),
		radial-gradient(38rem 24rem at 2% 112%, rgba(255, 190, 0, 0.10) 0%, rgba(255, 190, 0, 0) 60%),
		linear-gradient(178deg, #f4f6fb 0%, #f7f8fb 48%, #ffffff 100%);
}

.home-hero::before {
	position: absolute;
	z-index: -1;
	inset: 0;
	background-image: repeating-linear-gradient(
		116deg,
		rgba(0, 28, 114, 0.055) 0 1px,
		rgba(0, 28, 114, 0) 1px 68px
	);
	-webkit-mask-image: linear-gradient(102deg, rgba(0, 0, 0, 0) 0%, rgba(0, 0, 0, 0) 30%, rgba(0, 0, 0, 1) 58%, rgba(0, 0, 0, 1) 82%, rgba(0, 0, 0, 0) 100%);
	mask-image: linear-gradient(102deg, rgba(0, 0, 0, 0) 0%, rgba(0, 0, 0, 0) 30%, rgba(0, 0, 0, 1) 58%, rgba(0, 0, 0, 1) 82%, rgba(0, 0, 0, 0) 100%);
	content: "";
	pointer-events: none;
}

.home-hero__inner {
	display: grid;
	gap: var(--em-space-7);
	align-items: center;
}

.home-hero__eyebrow {
	display: flex;
	align-items: center;
	gap: var(--em-space-3);
	margin: 0 0 var(--em-space-4);
	color: var(--em-color-brand);
	font-size: var(--em-text-xs);
	font-weight: var(--em-weight-semibold);
	letter-spacing: var(--em-tracking-wide);
	text-transform: uppercase;
}

.home-hero__eyebrow::before {
	flex: 0 0 auto;
	width: 2.25rem;
	height: 3px;
	background-color: var(--em-color-accent);
	content: "";
}

/*
 * The H1 is still the largest thing on the site and still the widest step in
 * the scale. It is 62px at 1440 rather than 69, on a 1.02 leading rather than
 * 1.06 — about 40 pixels off a three-line headline, taken from the space
 * between the lines rather than from the words. The 15ch cap is what keeps it
 * to three lines; it is a headline, not body copy.
 */
.home-hero__title {
	max-width: 15ch;
	margin: 0 0 var(--em-space-4);
	color: var(--em-color-brand);
	font-size: clamp(2.375rem, 1.55rem + 3.6vw, 3.875rem);
	font-weight: var(--em-weight-bold);
	letter-spacing: var(--em-tracking-tight);
	line-height: 1.02;
}

.home-hero__lead {
	max-width: 52ch;
	margin: 0 0 var(--em-space-5);
	color: var(--em-color-text-muted);
	font-size: var(--em-text-lead);
	line-height: var(--em-leading-normal);
}

.home-hero__actions {
	display: flex;
	flex-wrap: wrap;
	gap: var(--em-space-3);
}

/* -- The capability panel -------------------------------------------------- */

.home-hero__panel {
	position: relative;
	overflow: hidden;
	padding: clamp(1.25rem, 0.95rem + 1.2vw, 1.875rem);
	border-radius: var(--em-radius-xl);
	background-color: var(--em-color-brand);
	color: var(--em-color-on-brand);
	box-shadow: var(--em-shadow-lg);
}

/*
 * A single soft gold wash in the corner. Not a motif, not a mark, and
 * deliberately not the concentric-ring graphic this design replaces — just
 * enough light to stop a large navy rectangle reading as flat.
 */
.home-hero__panel::before {
	position: absolute;
	top: -30%;
	right: -20%;
	width: 26rem;
	aspect-ratio: 1;
	background: radial-gradient(circle, rgba(255, 190, 0, 0.22) 0%, rgba(255, 190, 0, 0) 62%);
	content: "";
	pointer-events: none;
}

.capabilities {
	position: relative;
	margin: 0;
	padding: 0;
	list-style: none;
}

/*
 * 12px above and below each row rather than 24. Four rows, so the panel loses
 * 96 pixels; the rows are still 46px tall, which is above the 44px this
 * project holds every control to, and neither the label nor the note gets
 * smaller.
 */
.capabilities__item {
	display: flex;
	gap: var(--em-space-4);
	margin: 0;
	padding-block: var(--em-space-3);
}

.capabilities__item + .capabilities__item {
	border-top: 1px solid var(--em-color-on-brand-line);
}

.capabilities__item:first-child {
	padding-top: 0;
}

.capabilities__index {
	flex: 0 0 auto;
	color: var(--em-color-accent);
	font-size: var(--em-text-sm);
	font-weight: var(--em-weight-semibold);
	font-variant-numeric: tabular-nums;
	line-height: 1.6;
}

.capabilities__text {
	display: block;
	min-width: 0;
}

.capabilities__label {
	display: block;
	color: var(--em-color-on-brand);
	font-size: var(--em-text-md);
	font-weight: var(--em-weight-semibold);
	line-height: var(--em-leading-snug);
}

.capabilities__note {
	display: block;
	color: var(--em-color-on-brand-muted);
	font-size: var(--em-text-sm);
	line-height: var(--em-leading-snug);
}

.home-hero__stat {
	position: relative;
	display: flex;
	align-items: baseline;
	gap: var(--em-space-3);
	margin-top: var(--em-space-4);
	padding-top: var(--em-space-4);
	border-top: 1px solid var(--em-color-on-brand-line);
	color: var(--em-color-on-brand);
	text-decoration: none;
}

.home-hero__stat::after {
	color: var(--em-color-accent);
	content: "\2192";
	transition: transform var(--em-duration) var(--em-easing);
}

.home-hero__stat:hover::after {
	transform: translateX(4px);
}

.home-hero__stat-figure {
	color: var(--em-color-accent);
	font-size: var(--em-text-lg);
	font-weight: var(--em-weight-bold);
	font-variant-numeric: tabular-nums;
	line-height: 1;
}

.home-hero__stat-label {
	max-width: 20ch;
	color: var(--em-color-on-brand-muted);
	font-size: var(--em-text-sm);
	line-height: var(--em-leading-snug);
}

.home-hero :focus-visible,
.home-hero__panel :focus-visible {
	outline-color: var(--em-color-accent);
}

/* -- The Home page's own body, when it has one --------------------------- */

.home-intro {
	padding-block: var(--em-section-md);
}

/*
 * NO `max-width` HERE EITHER. This element carries the class `entry-content`,
 * so a 46rem cap on it would have been the 66ch rule under another name — the
 * exact thing CASE 11.3 removed. It is empty today (both Home pages are
 * routing anchors with no body), and the moment an editor writes one it gets
 * the same full column every other page's content gets.
 */
.home-intro__body {
	font-size: var(--em-text-md);
	line-height: var(--em-leading-loose);
}

/* --------------------------------------------------------------------------
   Services — three substantial modules.

   Raised surfaces with real padding, not three lists under a heading. The gold
   rule at the top fills across on hover, which is the one piece of motion on
   the page and is decoration rather than information.
   -------------------------------------------------------------------------- */

.service-grid {
	display: grid;
	grid-template-columns: 1fr;
	gap: var(--em-space-6);
	margin: 0;
	padding: 0;
	list-style: none;
}

.service {
	position: relative;
	display: flex;
	flex-direction: column;
	overflow: hidden;
	margin: 0;
	padding: clamp(1.25rem, 1rem + 1vw, 1.75rem);
	border: 1px solid var(--em-color-border);
	border-radius: var(--em-radius-lg);
	background-color: var(--em-color-bg);
	transition: border-color var(--em-duration) var(--em-easing),
	            box-shadow var(--em-duration) var(--em-easing),
	            transform var(--em-duration) var(--em-easing);
}

.service::before {
	position: absolute;
	top: 0;
	left: 0;
	width: 3.5rem;
	height: 4px;
	background-color: var(--em-color-accent);
	content: "";
	transition: width var(--em-duration) var(--em-easing);
}

.service:hover,
.service:focus-within {
	border-color: transparent;
	box-shadow: var(--em-shadow);
	transform: translateY(-3px);
}

.service:hover::before,
.service:focus-within::before {
	width: 100%;
}

/*
 * `--em-color-border-strong` USED TO COLOUR THIS, and it is a border colour:
 * #c3cad6 is 1.65:1 on white, which is correct for a hairline and not for a
 * numeral somebody might try to read. It is decorative — `aria-hidden` in the
 * template, and the order it states is already the order of the cards — but
 * "decorative" is not a licence for text nobody can see.
 *
 * #8b96a8 is 3.24:1, past the 3:1 that WCAG asks of large text, and this is
 * 19px bold. Still recessive; now legible.
 */
.service__index {
	display: block;
	margin-bottom: var(--em-space-2);
	color: #8b96a8;
	font-size: var(--em-text-md);
	font-weight: var(--em-weight-bold);
	font-variant-numeric: tabular-nums;
	line-height: 1;
}

.service__title {
	margin: 0 0 var(--em-space-4);
	font-size: var(--em-text-lg);
	letter-spacing: var(--em-tracking-tight);
	line-height: var(--em-leading-snug);
}

.service__title a {
	text-decoration: none;
}

.service__title a:hover,
.service__title a:focus-visible {
	text-decoration: underline;
}

.service__links {
	flex: 1 1 auto;
	margin: 0 0 var(--em-space-4);
	padding: 0;
	list-style: none;
	font-size: var(--em-text-sm);
}

.service__links li {
	margin: 0;
}

.service__links li + li {
	margin-top: 0;
}

/*
 * 9px above and below rather than 12. Five rows a card, three cards, so 90
 * pixels off the section — and a row is still 15px text on a 1.28 leading
 * inside a 37px box, which stays a comfortable pointer target. It is not
 * reduced further: CASE 11.3 asks for compaction and says in the same breath
 * not to make the links cramped.
 */
.service__links a {
	display: block;
	padding-block: 0.5625rem;
	border-bottom: 1px solid var(--em-color-border);
	color: var(--em-color-text-muted);
	line-height: var(--em-leading-snug);
	text-decoration: none;
}

.service__links a:hover,
.service__links a:focus-visible {
	color: var(--em-color-brand);
}

.service__more {
	margin: 0;
}

/* --------------------------------------------------------------------------
   THE MARKETPLACE — a compact carousel.

   WHAT THIS REPLACES. CASE 11.2 gave the section one feature listing at
   16:10 with two ordinary cards stacked beside it: three businesses in about
   760 pixels of page. Human review asked for "more businesses in less
   vertical space" and named the mechanism — a Swiper carousel with roughly
   six listings and several cards visible at once.

   So it is now six listings in one row, four of them on screen at 1440, in a
   single card height. The listings and their order are unchanged: the same
   `euromig_sales_query()` call with the same "available" filter, the same
   plugin-side ordering, the same photograph-first presentation ordering the
   theme applied before. Only the number requested moved, from three to six.

   THE SLIDER IS AN ENHANCEMENT, NEVER A GATE. Every rule that depends on
   Swiper is written against Swiper's own class names, and the
   `html:not(.js)` block at the end of this component turns the track back
   into an ordinary responsive grid of all six cards. Nothing is hidden by
   default and nothing needs script to be reachable.
   -------------------------------------------------------------------------- */

.sales-carousel {
	position: relative;
}

/*
 * Swiper's core stylesheet already gives `.swiper` `overflow: hidden` and its
 * wrapper `display: flex`. This element carries BOTH class names — the
 * vendor's, so the library recognises it, and the theme's, so the theme has
 * something to address that is not the vendor's.
 *
 * The negative margin and matching padding let a card's hover shadow spill
 * past the track edge without being clipped, and pull the first card back to
 * the container's own left edge so the section still lines up with the
 * heading above it.
 */
.sales-carousel__viewport {
	margin-inline: calc(var(--em-space-2) * -1);
	padding-inline: var(--em-space-2);
	padding-block: var(--em-space-2);
}

.sales-carousel__track {
	margin: 0;
	padding: 0;
	list-style: none;
}

/* `height: auto` on the slide, `100%` on the card: a row of equal cards. */
.sales-carousel__slide {
	height: auto;
}

.sales-carousel__slide > .card {
	height: 100%;
}

/* -- The controls -------------------------------------------------------- */
/*
 * Real `<button>` elements in the section header, beside "View all
 * businesses", rather than Swiper's own absolutely positioned arrows over the
 * slides — which is why `modules/navigation.min.css` is not installed. They
 * are 44px, they take the focus ring every other control in this theme takes,
 * and their accessible names are written by PHP and translated by WPML.
 *
 * The two class names below are SWIPER'S, applied by the Navigation module:
 * `swiper-button-disabled` when the track cannot move further in that
 * direction, `swiper-button-lock` when every slide already fits and there is
 * nothing to navigate at all.
 */
/*
 * `max-width` IS LOAD-BEARING. This element is also a `.section-header__action`,
 * and that component is `flex: 0 0 auto` — so without a cap it takes its
 * max-content width, which is 44 + 44 + "View all businesses" = 320 pixels.
 * At a 320px viewport the container offers 280, and the row ran 40 pixels off
 * the right of the DOCUMENT: the one horizontal overflow this case introduced,
 * caught at 320 and fixed here rather than by shrinking the button.
 */
.sales-carousel__controls {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	max-width: 100%;
	gap: var(--em-space-3);
}

.sales-carousel__nav {
	display: inline-flex;
	flex: 0 0 auto;
	align-items: center;
	justify-content: center;
	width: 2.75rem;
	height: 2.75rem;
	padding: 0;
	border: 1px solid var(--em-color-border-strong);
	border-radius: 50%;
	background-color: var(--em-color-bg);
	color: var(--em-color-brand);
	cursor: pointer;
	transition: background-color var(--em-duration) var(--em-easing),
	            border-color var(--em-duration) var(--em-easing),
	            color var(--em-duration) var(--em-easing);
}

.sales-carousel__nav svg {
	width: 1.0625rem;
	height: 1.0625rem;
	fill: none;
	stroke: currentColor;
	stroke-width: 2;
	stroke-linecap: round;
	stroke-linejoin: round;
}

.sales-carousel__nav:hover {
	border-color: var(--em-color-brand);
	background-color: var(--em-color-brand);
	color: var(--em-color-on-brand);
}

.sales-carousel__nav.swiper-button-disabled {
	border-color: var(--em-color-border);
	color: var(--em-color-border-strong);
	cursor: default;
	pointer-events: none;
}

.sales-carousel__nav.swiper-button-lock {
	display: none;
}

/* -- The compact card ---------------------------------------------------- */
/*
 * Materially shorter than the catalogue card, and shorter by STRUCTURE rather
 * than by shrinking the type:
 *
 *   - 16:10 media instead of 3:2 — about 45 pixels in a 300px column;
 *   - no excerpt — three to five lines, and the one fact on the old card that
 *     a visitor scanning six businesses does not read;
 *   - 16px body padding instead of 32;
 *   - the price at the card scale rather than the section scale. It is still
 *     the boldest thing in the body, in brand navy, on its own line — it is
 *     no longer larger than the name of the business it belongs to.
 */
.sales-card--compact .card__media img,
.sales-card--compact .card__image,
.sales-card--compact .card__media--empty {
	aspect-ratio: 16 / 10;
}

.sales-card--compact .card__body {
	gap: var(--em-space-2);
	padding: var(--em-space-4);
}

.sales-card--compact .card__title {
	-webkit-line-clamp: 2;
	line-clamp: 2;
	font-size: var(--em-text-base);
}

.sales-card--compact .card__price {
	margin-top: auto;
	padding-top: var(--em-space-2);
}

.sales-card--compact .price {
	font-size: var(--em-text-md);
}

.sales-card--compact .sales-card__terms {
	margin-top: var(--em-space-2);
	padding-top: var(--em-space-2);
}

/* -- Without JavaScript -------------------------------------------------- */
/*
 * Every one of the six listings, as a plain responsive grid. These selectors
 * are three classes deep against the vendor's one, so they win on specificity
 * and no `!important` is needed anywhere in this block.
 *
 * The arrows are removed rather than disabled: a button that cannot do
 * anything is worse than no button.
 */
html:not(.js) .sales-carousel__viewport {
	overflow: visible;
	margin-inline: 0;
	padding-inline: 0;
}

html:not(.js) .sales-carousel__track {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(min(100%, 15rem), 1fr));
	gap: var(--em-space-5);
	transform: none;
}

html:not(.js) .sales-carousel__slide {
	width: auto;
}

html:not(.js) .sales-carousel__nav {
	display: none;
}

/* --------------------------------------------------------------------------
   Business information — one story at size, three beneath it.

   Typography does the work, because it has to: NOT ONE of the six most recent
   articles carries a featured image, and 298 of 319 have none at all. A card
   grid here would be four empty rectangles.
   -------------------------------------------------------------------------- */

.insight-grid {
	display: grid;
	gap: var(--em-space-5);
	margin: 0;
	padding: 0;
	list-style: none;
}

.insight {
	display: flex;
	flex-direction: column;
	gap: var(--em-space-2);
	margin: 0;
}

.insight__media {
	display: block;
	margin-bottom: var(--em-space-2);
	overflow: hidden;
	border-radius: var(--em-radius);
	background-color: var(--em-color-surface-strong);
}

.insight__image {
	width: 100%;
	aspect-ratio: 16 / 10;
	object-fit: cover;
}

.insight__meta {
	margin: 0;
	color: var(--em-color-text-muted);
	font-size: var(--em-text-xs);
	font-weight: var(--em-weight-medium);
	letter-spacing: 0.05em;
	text-transform: uppercase;
}

.insight__title {
	margin: 0;
	font-size: var(--em-text-md);
	letter-spacing: -0.01em;
	line-height: var(--em-leading-snug);
}

.insight__title a {
	text-decoration: none;
}

.insight__title a:hover,
.insight__title a:focus-visible {
	text-decoration: underline;
}

.insight__excerpt {
	margin: 0;
	color: var(--em-color-text-muted);
	font-size: var(--em-text-sm);
	line-height: var(--em-leading-normal);
}

.insight__more {
	margin: var(--em-space-1) 0 0;
}

.insight--lead .insight__title {
	font-size: var(--em-text-lg);
	letter-spacing: var(--em-tracking-tight);
}

.insight--lead .insight__excerpt {
	max-width: 50ch;
	color: var(--em-color-text);
	font-size: var(--em-text-base);
}

.insight--secondary {
	padding-top: var(--em-space-4);
	border-top: 1px solid var(--em-color-border);
}

/* --------------------------------------------------------------------------
   Closing call to action — a full-width brand band, sized by its content.
   -------------------------------------------------------------------------- */

/*
 * The band keeps its full width and its colour — it is the last thing on the
 * page and the only place a visitor is asked to do something. What it loses
 * is the padding: 32px above and below at desktop rather than 72, sized to the
 * one line of text and one button it actually carries.
 */
.home-cta {
	padding-block: var(--em-space-7);
	background-color: var(--em-color-brand);
	color: var(--em-color-on-brand);
}

.home-cta__panel {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: var(--em-space-5) var(--em-space-8);
}

.home-cta__body {
	max-width: 46ch;
}

.home-cta__title {
	margin: 0 0 var(--em-space-2);
	color: var(--em-color-on-brand);
	font-size: var(--em-text-lg);
	letter-spacing: var(--em-tracking-tight);
}

.home-cta__lead {
	margin: 0;
	color: var(--em-color-on-brand-muted);
	font-size: var(--em-text-base);
	line-height: var(--em-leading-normal);
}

.home-cta :focus-visible {
	outline-color: var(--em-color-accent);
}


/* ==========================================================================
   13  PAGE AND SERVICE HIERARCHY

   The 166 migrated pages have to feel like the same site as the homepage, and
   they were not going to on the old scale: a 44px title over a grey band, 14px
   breadcrumbs and a 14px sidebar list. The title now uses the page scale, the
   band is gone in favour of space and a rule, and the section navigation is a
   real component rather than an unstyled list of links.
   ========================================================================== */

.page-hero {
	padding-block: var(--em-section-sm) var(--em-space-6);
	border-bottom: 1px solid var(--em-color-border);
	background-color: var(--em-color-bg);
}

.page-hero--compact {
	padding-block: var(--em-section-sm) var(--em-space-5);
}

.page-hero__title {
	max-width: 22ch;
	margin: 0;
	font-size: var(--em-text-2xl);
	letter-spacing: var(--em-tracking-tight);
}

.page-hero__lead {
	max-width: 58ch;
	margin: var(--em-space-4) 0 0;
	color: var(--em-color-text-muted);
	font-size: var(--em-text-lead);
	line-height: var(--em-leading-normal);
}

.page-hero__form {
	margin-top: var(--em-space-5);
}

.page-hero__form .search-form {
	margin-bottom: 0;
}

.page-hero--image .page-hero__media {
	margin: var(--em-space-6) 0 0;
	overflow: hidden;
	border-radius: var(--em-radius-lg);
}

/*
 * 20rem rather than 26. A service page's banner was taking 416 pixels of a
 * 1000-pixel viewport before the first sentence; at 320 it supports the page
 * instead of being it. `cover` still crops rather than distorts, and only
 * images at least 1000px wide are shown here at all.
 */
.page-hero__image {
	width: 100%;
	max-height: 20rem;
	object-fit: cover;
}

/* -- Breadcrumbs (presentation only; CASE 14 owns structured data) -------- */
/*
 * Smaller than the title, muted but past AA at 6.35:1, and wrapping rather
 * than truncating — a six-level path is long, and a visitor four levels deep
 * needs to be able to read where they are.
 */

.breadcrumbs {
	margin-bottom: var(--em-space-4);
}

.breadcrumbs__list {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: var(--em-space-1) var(--em-space-2);
	margin: 0;
	padding: 0;
	list-style: none;
	color: var(--em-color-text-muted);
	font-size: var(--em-text-sm);
}

.breadcrumbs__item + .breadcrumbs__item::before {
	margin-right: var(--em-space-2);
	color: var(--em-color-border-strong);
	content: "\002F";
}

.breadcrumbs__item {
	margin: 0;
}

.breadcrumbs__item a {
	color: var(--em-color-text-muted);
	text-decoration: none;
}

.breadcrumbs__item a:hover,
.breadcrumbs__item a:focus-visible {
	color: var(--em-color-brand);
	text-decoration: underline;
}

.breadcrumbs__item:last-child {
	color: var(--em-color-text);
	font-weight: var(--em-weight-medium);
}

/* -- The page body and its local navigation ------------------------------ */

.page-layout {
	display: grid;
	gap: var(--em-space-8);
	padding-block: var(--em-section-sm);
}

.page-layout__main {
	min-width: 0;
}

/*
 * NO `max-width`. This rule used to cap the article at 66ch INSIDE a grid
 * column that was already 868 pixels wide, so a page with a sidebar set its
 * text at 687 and left 181 pixels of its own column empty. The column is the
 * only thing that decides the width now.
 *
 * The leading is `loose` rather than `normal` for the same reason section 9
 * raised it: a wider column needs a longer descent to the next line.
 */
.page-layout .entry-content {
	font-size: var(--em-text-base);
	line-height: var(--em-leading-loose);
}

/*
 * A panel, not a sidebar list. The rows are 44px targets, the current page
 * carries the same gold marker the navigation bar uses, and on a phone the
 * whole thing simply follows the article in the document flow.
 */
.local-nav {
	padding: var(--em-space-5);
	border: 1px solid var(--em-color-border);
	border-radius: var(--em-radius-lg);
	background-color: var(--em-color-surface);
}

.local-nav__heading {
	margin: 0 0 var(--em-space-4);
	padding-bottom: var(--em-space-3);
	border-bottom: 2px solid var(--em-color-accent);
	color: var(--em-color-text-muted);
	font-size: var(--em-text-xs);
	font-weight: var(--em-weight-semibold);
	letter-spacing: var(--em-tracking-wide);
	text-transform: uppercase;
}

.local-nav__list {
	margin: 0;
	padding: 0;
	list-style: none;
	font-size: var(--em-text-sm);
}

.local-nav__item {
	margin: 0;
}

.local-nav__item + .local-nav__item {
	border-top: 1px solid var(--em-color-border);
}

.local-nav__item a {
	display: block;
	padding-block: var(--em-space-3);
	color: var(--em-color-text);
	line-height: var(--em-leading-snug);
	text-decoration: none;
}

.local-nav__item a:hover,
.local-nav__item a:focus-visible {
	color: var(--em-color-brand);
	text-decoration: underline;
}

.local-nav__item.is-current a {
	padding-left: var(--em-space-3);
	box-shadow: inset 3px 0 0 var(--em-color-accent);
	color: var(--em-color-brand);
	font-weight: var(--em-weight-semibold);
}

@media (min-width: 62rem) {
	/*
	 * 900 / 1204 at 1440 — the main column takes 75 % of the container, which
	 * is the top of the proportion CASE 11.3 recommends, and the section panel
	 * still holds a six-level branch at 256px without wrapping a title.
	 */
	.page-layout--with-aside {
		grid-template-columns: minmax(0, 1fr) 16rem;
		column-gap: var(--em-space-7);
	}

	.page-layout__aside {
		position: sticky;
		top: calc(var(--em-admin-bar-height) + var(--em-header-height) + var(--em-space-4));
		align-self: start;
	}
}

/* -- 404 ------------------------------------------------------------------ */

.error-404__routes {
	padding-block: var(--em-section-sm);
}

.error-404__list {
	display: flex;
	flex-wrap: wrap;
	gap: var(--em-space-3) var(--em-space-6);
	margin: var(--em-space-5) 0 0;
	padding: 0;
	list-style: none;
	font-size: var(--em-text-base);
	font-weight: var(--em-weight-medium);
}

.error-404__list li {
	margin: 0;
}


/* ==========================================================================
   14  EDITORIAL

   An editorial hierarchy rather than a uniform grid: only 21 of 319 articles
   carry a featured image, so a picture-led layout would be mostly empty boxes.
   CASE 11.1 did not change that decision — it gave the typography the size to
   carry it. The archive's lead headline is now 38px against a 26px follower
   and a 15px dateline, where all three used to sit within a few pixels of one
   another and the hierarchy had to be inferred from position alone.
   ========================================================================== */

.editorial {
	display: grid;
	gap: var(--em-space-7);
	padding-block: var(--em-section-sm);
}

.article-lead {
	display: grid;
	gap: var(--em-space-5);
	padding-bottom: var(--em-space-7);
	border-bottom: 2px solid var(--em-color-border-strong);
}

.article-lead__media {
	display: block;
	overflow: hidden;
	border-radius: var(--em-radius-lg);
	background-color: var(--em-color-surface-strong);
}

.article-lead__image {
	width: 100%;
	aspect-ratio: 16 / 9;
	object-fit: cover;
}

/*
 * The dateline. Small, lettered apart and set in capitals so it reads as a
 * label rather than as the first line of the headline.
 */
.article-lead__meta,
.article-item__meta {
	margin: 0 0 var(--em-space-3);
	color: var(--em-color-text-muted);
	font-size: var(--em-text-xs);
	font-weight: var(--em-weight-medium);
	letter-spacing: 0.04em;
	text-transform: uppercase;
}

.article-lead__title {
	max-width: 20ch;
	margin: 0 0 var(--em-space-4);
	font-size: var(--em-text-xl);
	letter-spacing: var(--em-tracking-tight);
	line-height: var(--em-leading-tight);
}

.article-lead__excerpt {
	max-width: 60ch;
	margin: 0 0 var(--em-space-5);
	color: var(--em-color-text);
	font-size: var(--em-text-lead);
	line-height: var(--em-leading-normal);
}

.article-lead__more {
	margin: 0;
}

.article-lead__title a,
.article-item__title a {
	text-decoration: none;
}

.article-lead__title a:hover,
.article-lead__title a:focus-visible,
.article-item__title a:hover,
.article-item__title a:focus-visible {
	text-decoration: underline;
}

.article-item {
	display: grid;
	gap: var(--em-space-4);
	padding-bottom: var(--em-space-6);
	border-bottom: 1px solid var(--em-color-border);
}

.article-item__media {
	display: block;
	overflow: hidden;
	border-radius: var(--em-radius);
	background-color: var(--em-color-surface-strong);
}

.article-item__image {
	width: 100%;
	aspect-ratio: 3 / 2;
	object-fit: cover;
}

.article-item__title {
	/*
	 * The same measure the extract uses. Left unbounded, a long headline ran
	 * the full 1,280px container while the extract below it wrapped at 500 —
	 * two different left-to-right rhythms in one entry.
	 */
	max-width: 34ch;
	margin: 0 0 var(--em-space-3);
	font-size: var(--em-text-lg);
	line-height: var(--em-leading-snug);
}

.article-item__excerpt {
	max-width: 68ch;
	margin: 0;
	color: var(--em-color-text-muted);
	font-size: var(--em-text-base);
	line-height: var(--em-leading-normal);
}

@media (min-width: 48rem) {
	.article-lead {
		grid-template-columns: 1.15fr 1fr;
		align-items: center;
		gap: var(--em-space-8);
	}

	/*
	 * NO PICTURE IS THE NORMAL CASE — 298 of 319 articles have none — so the
	 * imageless lead is not a fallback, it is the layout. Collapsing it to one
	 * column left the headline and the extract stacked down the left half of a
	 * 1,280px page with the right half empty: a hole where the design should
	 * be. Split across two columns instead, headline against extract, which is
	 * an editorial device rather than an apology for a missing image.
	 */
	.article-lead:not(:has(.article-lead__media)) {
		grid-template-columns: 1fr;
	}

	.article-lead:not(:has(.article-lead__media)) .article-lead__body {
		display: grid;
		grid-template-columns: 1.05fr 1fr;
		grid-template-rows: auto 1fr auto;
		column-gap: var(--em-space-8);
		align-items: start;
	}

	.article-lead:not(:has(.article-lead__media)) .article-lead__meta {
		grid-column: 1;
		grid-row: 1;
	}

	.article-lead:not(:has(.article-lead__media)) .article-lead__title {
		grid-column: 1;
		grid-row: 2;
		max-width: none;
		margin-bottom: 0;
	}

	.article-lead:not(:has(.article-lead__media)) .article-lead__excerpt {
		grid-column: 2;
		grid-row: 1 / span 2;
		margin-bottom: var(--em-space-4);
	}

	.article-lead:not(:has(.article-lead__media)) .article-lead__more {
		grid-column: 2;
		grid-row: 3;
	}

	.article-item {
		grid-template-columns: 13rem 1fr;
		align-items: start;
		gap: var(--em-space-6);
	}

	.article-item:not(:has(.article-item__media)) {
		grid-template-columns: 1fr;
	}
}

/* -- Long-form article --------------------------------------------------- */

/*
 * `.site-container--narrow` USED TO STAND HERE, at 46rem, and single.php no
 * longer applies it.
 *
 * It was the last hidden prose cap in the theme. CASE 11.3's instruction is
 * that the full-width rule applies globally and that readability is bought
 * with leading and spacing rather than with a narrow strip — so an article
 * now uses the same container every other template uses, and the rules below
 * pay for the wider column.
 *
 * THIS IS THE ONE CHANGE IN THIS CASE MOST WORTH A SECOND OPINION, and it is
 * reversible in one line: adding `site-container--narrow` back to the two
 * containers in `single.php` restores the old measure without touching
 * anything else. The report says so in section 6.
 */

.article-hero {
	padding-block: var(--em-section-sm) var(--em-space-5);
}

.article-hero__title {
	margin: 0 0 var(--em-space-4);
	font-size: var(--em-text-2xl);
	letter-spacing: var(--em-tracking-tight);
}

.article-hero__meta {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: var(--em-space-3);
	margin: 0;
	color: var(--em-color-text-muted);
	font-size: var(--em-text-sm);
}

.article-hero__meta > * + * {
	margin-left: 0;
}

.article-hero__category {
	padding: 0.2em 0.7em;
	border-radius: 999px;
	background-color: var(--em-color-accent-soft);
	color: var(--em-color-accent-ink);
	font-size: var(--em-text-xs);
	font-weight: var(--em-weight-semibold);
	letter-spacing: 0.03em;
	text-transform: uppercase;
}

.article-media {
	margin: 0 0 var(--em-space-7);
	overflow: hidden;
	border-radius: var(--em-radius-lg);
}

.article-media__image {
	width: 100%;
	max-height: 22rem;
	object-fit: cover;
}

/*
 * Long-form reading in a full-width column: 19px on a 1.85 leading, 24 pixels
 * between blocks, and a heading step that is unmistakable at a glance. The
 * stored HTML of years of migrated articles is still not rewritten — every
 * one of these is a CSS rule over markup nobody touched.
 */
.entry-content--longform {
	font-size: var(--em-text-md);
	line-height: 1.85;
}

.entry-content--longform > * + * {
	margin-top: var(--em-space-5);
}

.entry-content--longform h2 {
	margin-top: var(--em-space-8);
	font-size: var(--em-text-lg);
}

.entry-content--longform h3 {
	margin-top: var(--em-space-7);
	font-size: var(--em-text-md);
}

.entry-content--longform ul,
.entry-content--longform ol {
	padding-left: var(--em-space-6);
}

.entry-content--longform li + li {
	margin-top: var(--em-space-2);
}

.search-results {
	display: grid;
	gap: var(--em-space-6);
	padding-block: var(--em-section-sm);
}

.entry--search {
	padding-bottom: var(--em-space-6);
	border-bottom: 1px solid var(--em-color-border);
}


/* ==========================================================================
   15  CORPORATE SALES MARKETPLACE

   The catalogue, its filters and one listing. Built on the tokens the rest of
   the site uses — nothing here introduces a colour, a type size or a spacing
   value of its own — so a marketplace page reads as part of the same site
   rather than as a bolted-on application.

   THE DENSITY PHILOSOPHY IS CASE 11.3's, CONTINUED. Compact section rhythm,
   16:10 media, one body padding step, prices at the card scale. The archive's
   job is to get several businesses in front of somebody at once.

   Order below: marketplace header, filters, the drawer, active filters, the
   result toolbar and sort, the catalogue card, empty states, the help panel,
   then the single listing — hero, layout, summary rail, consultant, facts.
   ========================================================================== */

/* --------------------------------------------------------------------------
   Marketplace header.

   Compact on purpose. CASE 12 is explicit that the page prioritises inventory
   over a marketing hero: the whole header is an eyebrow, a heading and one
   sentence, and at 1440 the first cards are on screen with it.
   -------------------------------------------------------------------------- */

/*
 * EVERY PIXEL HERE IS A PIXEL OF INVENTORY. At 1440x1000 the first row of
 * cards begins at 696 and the header is the largest thing above it, so the
 * padding is one step below the section rhythm rather than at it — the page
 * prioritises the catalogue, which is CASE 12's instruction, and a marketing
 * hero is exactly what it forbids.
 */
.marketplace__header {
	padding-block: var(--em-space-6) var(--em-space-5);
	border-bottom: 1px solid var(--em-color-border);
	background-image: linear-gradient(178deg, #f6f8fc 0%, #ffffff 100%);
}

.marketplace__eyebrow {
	margin: 0 0 var(--em-space-2);
	color: var(--em-color-text-muted);
	font-size: var(--em-text-xs);
	font-weight: var(--em-weight-semibold);
	letter-spacing: var(--em-tracking-wide);
	text-transform: uppercase;
}

.marketplace__title {
	max-width: 20ch;
	margin: 0;
	color: var(--em-color-brand);
	font-size: var(--em-text-2xl);
	letter-spacing: var(--em-tracking-tight);
	line-height: var(--em-leading-tight);
}

.marketplace__lead {
	max-width: 58ch;
	margin: var(--em-space-3) 0 0;
	color: var(--em-color-text-muted);
	font-size: var(--em-text-lead);
	line-height: var(--em-leading-normal);
}

.marketplace__body {
	padding-block: var(--em-space-6) var(--em-section-md);
}

/* --------------------------------------------------------------------------
   Filters.

   ONE TOOLBAR, NOT A SIDEBAR. Four controls do not justify surrendering a
   quarter of the page: CASE 12 asks for a sidebar only if real filter
   complexity requires one, and the measured filter set is keyword, sector,
   availability and a price range. A sidebar would push the inventory right and
   leave three quarters of itself empty.
   -------------------------------------------------------------------------- */

.sales-filters {
	margin-bottom: var(--em-space-5);
}

.sales-filters__panel {
	padding: var(--em-space-4);
	border: 1px solid var(--em-color-border);
	border-radius: var(--em-radius-lg);
	background-color: var(--em-color-surface);
}

.sales-filters__fields {
	display: grid;
	gap: var(--em-space-3);
}

.sales-filters__field {
	display: flex;
	flex-direction: column;
	gap: var(--em-space-1);
	margin: 0;
	min-width: 0;
}

.sales-filters__field--price {
	padding: 0;
	border: 0;
}

.sales-filters__label {
	padding: 0;
	color: var(--em-color-text-muted);
	font-size: var(--em-text-xs);
	font-weight: var(--em-weight-semibold);
	letter-spacing: 0.04em;
	text-transform: uppercase;
}

.sales-filters__input,
.sales-filters__select {
	width: 100%;
	min-height: 2.75rem;
	padding: var(--em-space-2) var(--em-space-3);
	border: 1px solid var(--em-color-border-strong);
	border-radius: var(--em-radius);
	background-color: var(--em-color-bg);
	color: var(--em-color-text);
	font-family: inherit;
	font-size: var(--em-text-sm);
}

.sales-filters__select {
	/* leave room for the native arrow so a long sector name never sits under it */
	padding-right: var(--em-space-6);
}

.sales-filters__range {
	display: flex;
	align-items: center;
	gap: var(--em-space-2);
}

.sales-filters__input--number {
	min-width: 0;
}

.sales-filters__range-sep {
	flex: 0 0 auto;
	color: var(--em-color-text-muted);
}

.sales-filters__actions {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: var(--em-space-3);
	margin-top: var(--em-space-4);
}

.sales-filters__panel-head {
	display: none;
}

/* -- The drawer trigger ---------------------------------------------------- */
/*
 * Hidden at desktop, where the panel is simply the toolbar. It exists in the
 * markup at every width so that the mobile behaviour needs no second template,
 * and it is REMOVED ENTIRELY without JavaScript — a button that cannot open
 * anything is worse than no button, and the panel is open in that case anyway.
 */

.sales-filters__toggle {
	display: none;
	align-items: center;
	gap: var(--em-space-2);
	width: 100%;
	min-height: 2.75rem;
	padding: var(--em-space-2) var(--em-space-4);
	border: 1px solid var(--em-color-border-strong);
	border-radius: var(--em-radius);
	background-color: var(--em-color-bg);
	color: var(--em-color-brand);
	font-family: inherit;
	font-size: var(--em-text-base);
	font-weight: var(--em-weight-semibold);
	cursor: pointer;
}

.sales-filters__toggle svg {
	width: 1.125rem;
	height: 1.125rem;
	fill: none;
	stroke: currentColor;
	stroke-width: 2;
	stroke-linecap: round;
}

.sales-filters__badge {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-width: 1.375rem;
	height: 1.375rem;
	margin-left: auto;
	border-radius: 999px;
	background-color: var(--em-color-brand);
	color: var(--em-color-on-brand);
	font-size: var(--em-text-xs);
}

.sales-filters__close {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 2.75rem;
	height: 2.75rem;
	padding: 0;
	border: 0;
	background: none;
	color: var(--em-color-text);
	cursor: pointer;
}

.sales-filters__close svg {
	width: 1.25rem;
	height: 1.25rem;
	fill: none;
	stroke: currentColor;
	stroke-width: 2;
	stroke-linecap: round;
}

/* --------------------------------------------------------------------------
   Active filters.

   Every chip is a link that removes one filter and keeps the rest, so the
   control needs no script and a filtered view stays shareable.
   -------------------------------------------------------------------------- */

.active-filters {
	margin-bottom: var(--em-space-5);
}

.active-filters__list {
	display: flex;
	flex-wrap: wrap;
	gap: var(--em-space-2);
	margin: 0;
	padding: 0;
	list-style: none;
}

.active-filters__item {
	display: inline-flex;
	align-items: center;
	gap: var(--em-space-2);
	margin: 0;
	padding: var(--em-space-1) var(--em-space-1) var(--em-space-1) var(--em-space-3);
	border: 1px solid var(--em-color-border-strong);
	border-radius: 999px;
	background-color: var(--em-color-bg);
	font-size: var(--em-text-sm);
	line-height: 1.4;
}

.active-filters__group {
	color: var(--em-color-text-muted);
}

.active-filters__group::after {
	content: ":";
}

.active-filters__value {
	color: var(--em-color-text);
	font-weight: var(--em-weight-medium);
}

/*
 * 32px, not 28. A chip's remove control is a real target and 28px was under
 * the 32px minimum this project holds every control to — comfortably past
 * WCAG 2.5.8's 24px, but the project's own bar is the stricter one and it is
 * the one that gets measured.
 */
.active-filters__remove {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 2rem;
	height: 2rem;
	border-radius: 999px;
	color: var(--em-color-text-muted);
}

.active-filters__remove svg {
	width: 0.875rem;
	height: 0.875rem;
	fill: none;
	stroke: currentColor;
	stroke-width: 2.5;
	stroke-linecap: round;
}

.active-filters__remove:hover,
.active-filters__remove:focus-visible {
	background-color: var(--em-color-brand);
	color: var(--em-color-on-brand);
}

.active-filters__item--clear {
	border-color: transparent;
	background: none;
	padding-inline: var(--em-space-2);
}

/*
 * "Clear all" is a control in a row of controls, so it takes the same 32px
 * minimum the remove buttons beside it do. It was 21px tall — a text link
 * in a chip row, which is exactly the case WCAG 2.5.8's inline exception does
 * NOT cover.
 */
.active-filters__clear {
	display: inline-flex;
	align-items: center;
	min-height: 2rem;
	padding-inline: var(--em-space-2);
	color: var(--em-color-brand);
	font-weight: var(--em-weight-medium);
}

/* --------------------------------------------------------------------------
   The result toolbar.
   -------------------------------------------------------------------------- */

.marketplace__toolbar {
	display: flex;
	flex-wrap: wrap;
	align-items: baseline;
	justify-content: space-between;
	gap: var(--em-space-3) var(--em-space-5);
	margin-bottom: var(--em-space-4);
	padding-bottom: var(--em-space-3);
	border-bottom: 1px solid var(--em-color-border);
}

.marketplace__count {
	margin: 0;
	color: var(--em-color-text);
	font-size: var(--em-text-base);
}

.marketplace__count strong {
	color: var(--em-color-brand);
	font-weight: var(--em-weight-bold);
}

.marketplace__range {
	color: var(--em-color-text-muted);
	font-size: var(--em-text-sm);
}

.sales-sort {
	display: flex;
	flex-wrap: wrap;
	align-items: baseline;
	gap: var(--em-space-2) var(--em-space-3);
}

.sales-sort__label {
	margin: 0;
	color: var(--em-color-text-muted);
	font-size: var(--em-text-xs);
	font-weight: var(--em-weight-semibold);
	letter-spacing: 0.04em;
	text-transform: uppercase;
}

.sales-sort__list {
	display: flex;
	flex-wrap: wrap;
	gap: var(--em-space-1) var(--em-space-3);
	margin: 0;
	padding: 0;
	list-style: none;
}

.sales-sort__item {
	margin: 0;
}

.sales-sort__link {
	display: inline-block;
	padding-block: var(--em-space-2);
	color: var(--em-color-text-muted);
	font-size: var(--em-text-sm);
	text-decoration: none;
}

.sales-sort__link:hover,
.sales-sort__link:focus-visible {
	color: var(--em-color-brand);
	text-decoration: underline;
}

/*
 * The current sort is marked by WEIGHT AND A RULE, not by colour alone —
 * WCAG 1.4.1, and the same reason the featured badge carries a word.
 */
.sales-sort__link.is-current {
	color: var(--em-color-brand);
	font-weight: var(--em-weight-semibold);
	box-shadow: inset 0 -2px 0 var(--em-color-accent);
}

/* --------------------------------------------------------------------------
   The catalogue card.

   Shares every primitive with the homepage card in section 10 — the same
   media frame, badge, title clamp and price component — and differs only in
   what it carries: a catalogue card is being COMPARED, so it keeps the extract
   and the location the teaser drops.
   -------------------------------------------------------------------------- */

.marketplace__grid {
	gap: var(--em-space-5);
}

.sales-card--catalogue .card__media img,
.sales-card--catalogue .card__image,
.sales-card--catalogue .card__media--empty {
	aspect-ratio: 16 / 10;
}

.sales-card--catalogue .card__body {
	gap: var(--em-space-2);
	padding: var(--em-space-4);
}

/*
 * THE TITLE IS A FIXED TWO-LINE BOX, and that is what makes a row of cards a
 * row. Listing names here run from 9 characters to 96: clamping to two lines
 * stops the long ones, but without a matching MINIMUM the short ones collapse
 * to one line and every card in the row puts its price at a different height.
 * A price a buyer is comparing across four businesses has to be on one line.
 *
 * `2lh` is two of this element's own line boxes, so it follows the type scale
 * instead of hard-coding a pixel height that a clamp() would invalidate.
 */
.sales-card--catalogue .card__title {
	-webkit-line-clamp: 2;
	line-clamp: 2;
	min-height: 2lh;
	font-size: var(--em-text-base);
}

/*
 * The excerpt takes the slack. It is optional — 20 of 212 English listings
 * have one — so it is the only element on the card that can absorb the
 * difference without moving anything a visitor is comparing.
 */
.sales-card--catalogue .card__excerpt {
	flex: 1 1 auto;
	-webkit-line-clamp: 2;
	line-clamp: 2;
	font-size: var(--em-text-sm);
}

/*
 * `margin-top: 0` CANCELS SECTION 10's `margin: auto 0 0`.
 *
 * That rule pins the price to the bottom of a card whose body has nothing
 * else to give, which is right for the homepage teaser and wrong here: with
 * the terms line ALSO auto-margined, the free space went above the price, so
 * a card with no extract put its price 36 pixels lower than the card beside
 * it. Prices a buyer is comparing across four businesses have to be level.
 * One auto margin per column, and it belongs to the last element.
 */
.sales-card--catalogue .card__price {
	margin-top: 0;
	padding-top: var(--em-space-1);
}

/* Pinned to the bottom, so the sector line is level across a row. */
.sales-card--catalogue .sales-card__terms {
	margin-top: auto;
}

.sales-card--catalogue .price {
	font-size: var(--em-text-md);
}

.sales-card--catalogue .sales-card__terms {
	padding-top: var(--em-space-2);
}

/*
 * Two badges can sit on one picture — Featured and the status — so they are a
 * flex row rather than a single absolutely positioned element.
 */
.sales-card__flags {
	position: absolute;
	top: var(--em-space-3);
	left: var(--em-space-3);
	right: var(--em-space-3);
	z-index: 1;
	display: flex;
	flex-wrap: wrap;
	gap: var(--em-space-2);
	margin: 0;
}

.badge--featured {
	background-color: var(--em-color-accent);
	color: var(--em-color-accent-ink);
}

.sales-card__flags .badge {
	box-shadow: 0 1px 3px rgba(22, 24, 29, 0.35);
}

/*
 * A featured listing gets a gold hairline and nothing else. CASE 11.1 deleted
 * an unlabelled gold border on a featured card because a colour that means
 * something and says nothing is not information; this one accompanies a badge
 * that says "Featured", so it is emphasis rather than a secret code.
 */
.sales-card--catalogue.is-featured {
	border-color: var(--em-color-accent);
}

.sales-card__term + .sales-card__term::before {
	margin-inline: 0.4em;
	color: var(--em-color-border-strong);
	content: "\00B7";
}

/* --------------------------------------------------------------------------
   Empty states and the help panel.
   -------------------------------------------------------------------------- */

.marketplace__empty {
	padding: var(--em-section-sm) var(--em-space-5);
	border: 1px solid var(--em-color-border);
	border-radius: var(--em-radius-lg);
	background-color: var(--em-color-surface);
	text-align: center;
}

.marketplace__empty-title {
	margin: 0 0 var(--em-space-2);
	color: var(--em-color-brand);
	font-size: var(--em-text-lg);
	letter-spacing: var(--em-tracking-tight);
}

.marketplace__empty-lead {
	max-width: 46ch;
	margin: 0 auto;
	color: var(--em-color-text-muted);
	font-size: var(--em-text-base);
}

.marketplace__empty-actions {
	margin: var(--em-space-5) 0 0;
}

.marketplace__help {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: var(--em-space-4) var(--em-space-7);
	margin-top: var(--em-section-sm);
	padding: var(--em-space-6);
	border-radius: var(--em-radius-lg);
	background-color: var(--em-color-brand);
	color: var(--em-color-on-brand);
}

.marketplace__help-title {
	margin: 0 0 var(--em-space-2);
	color: var(--em-color-on-brand);
	font-size: var(--em-text-lg);
	letter-spacing: var(--em-tracking-tight);
}

.marketplace__help-lead {
	max-width: 52ch;
	margin: 0;
	color: var(--em-color-on-brand-muted);
	font-size: var(--em-text-base);
}

.marketplace__help :focus-visible {
	outline-color: var(--em-color-accent);
}

.marketplace__pagination {
	margin-top: var(--em-space-7);
}

/* --------------------------------------------------------------------------
   One listing.
   -------------------------------------------------------------------------- */

.sales-detail__header {
	padding-block: var(--em-section-sm) var(--em-space-6);
	border-bottom: 1px solid var(--em-color-border);
	background-image: linear-gradient(178deg, #f6f8fc 0%, #ffffff 100%);
}

.sales-detail__flags {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: var(--em-space-2) var(--em-space-3);
	margin: 0 0 var(--em-space-3);
}

.sales-detail__sector {
	color: var(--em-color-text-muted);
	font-size: var(--em-text-xs);
	font-weight: var(--em-weight-semibold);
	letter-spacing: 0.04em;
	text-transform: uppercase;
}

.sales-detail__title {
	max-width: 26ch;
	margin: 0;
	color: var(--em-color-brand);
	font-size: var(--em-text-2xl);
	letter-spacing: var(--em-tracking-tight);
	line-height: var(--em-leading-tight);
}

.sales-detail__summary {
	display: flex;
	flex-wrap: wrap;
	align-items: baseline;
	gap: var(--em-space-2) var(--em-space-4);
	margin: var(--em-space-3) 0 0;
}

.sales-detail__summary .price {
	font-size: var(--em-text-lg);
}

.sales-detail__place {
	color: var(--em-color-text-muted);
	font-size: var(--em-text-base);
}

.sales-detail__layout {
	display: grid;
	gap: var(--em-space-7);
	padding-block: var(--em-section-sm);
}

.sales-detail__main {
	min-width: 0;
}

.sales-detail__media {
	margin: 0 0 var(--em-space-6);
	overflow: hidden;
	border-radius: var(--em-radius-lg);
}

.sales-detail__image {
	width: 100%;
	max-height: 26rem;
	object-fit: cover;
}

.sales-detail__content {
	margin-bottom: var(--em-section-sm);
}

/* -- The summary rail ------------------------------------------------------ */

.sales-summary {
	padding: var(--em-space-5);
	border: 1px solid var(--em-color-border);
	border-radius: var(--em-radius-lg);
	background-color: var(--em-color-surface);
}

.sales-summary__status {
	margin: 0 0 var(--em-space-4);
}

.sales-summary__price {
	display: flex;
	flex-direction: column;
	gap: var(--em-space-1);
	margin: 0 0 var(--em-space-5);
	padding-bottom: var(--em-space-4);
	border-bottom: 1px solid var(--em-color-border);
}

.sales-summary__price-label {
	color: var(--em-color-text-muted);
	font-size: var(--em-text-xs);
	font-weight: var(--em-weight-semibold);
	letter-spacing: 0.04em;
	text-transform: uppercase;
}

/*
 * ONE STEP DOWN FROM THE HEADER'S. The price is already set large at the top
 * of the page; in a 320px rail the same size broke "€86 000 – €165 000" across
 * two lines, and a range split over a line break is harder to read than the
 * same range one step smaller.
 */
.sales-summary__price .price {
	font-size: var(--em-text-md);
}

.sales-summary__facts {
	margin: 0 0 var(--em-space-5);
}

.sales-summary__fact {
	display: flex;
	align-items: baseline;
	justify-content: space-between;
	gap: var(--em-space-3);
	padding-block: var(--em-space-2);
	font-size: var(--em-text-sm);
}

.sales-summary__fact + .sales-summary__fact {
	border-top: 1px solid var(--em-color-border);
}

.sales-summary__fact dt {
	flex: 0 0 auto;
	color: var(--em-color-text-muted);
	font-weight: var(--em-weight-regular);
}

.sales-summary__fact dd {
	margin: 0;
	color: var(--em-color-text);
	font-weight: var(--em-weight-medium);
	text-align: right;
}

.sales-summary__actions {
	display: grid;
	gap: var(--em-space-2);
}

.sales-summary__action {
	justify-content: center;
	width: 100%;
}

.sales-summary__note {
	margin: 0 0 var(--em-space-3);
	color: var(--em-color-text-muted);
	font-size: var(--em-text-sm);
	line-height: var(--em-leading-normal);
}

.sales-summary__reference {
	display: flex;
	flex-wrap: wrap;
	align-items: baseline;
	gap: var(--em-space-2);
	margin: var(--em-space-5) 0 0;
	padding-top: var(--em-space-4);
	border-top: 1px solid var(--em-color-border);
	font-size: var(--em-text-xs);
}

.sales-summary__reference-label {
	color: var(--em-color-text-muted);
	letter-spacing: 0.04em;
	text-transform: uppercase;
}

.sales-summary__reference-value {
	color: var(--em-color-text);
	font-variant-numeric: tabular-nums;
	font-weight: var(--em-weight-semibold);
}

/* -- The consultant panel -------------------------------------------------- */

.sales-consultant {
	margin-top: var(--em-space-5);
	padding: var(--em-space-5);
	border: 1px solid var(--em-color-border);
	border-radius: var(--em-radius-lg);
}

.sales-consultant__heading {
	margin: 0 0 var(--em-space-4);
	color: var(--em-color-text-muted);
	font-size: var(--em-text-xs);
	font-weight: var(--em-weight-semibold);
	letter-spacing: var(--em-tracking-wide);
	text-transform: uppercase;
}

.sales-consultant__person {
	display: flex;
	align-items: center;
	gap: var(--em-space-3);
}

.sales-consultant__photo {
	flex: 0 0 auto;
	overflow: hidden;
	border-radius: 999px;
}

.sales-consultant__image {
	display: block;
	width: 3.5rem;
	height: 3.5rem;
	object-fit: cover;
}

.sales-consultant__identity {
	min-width: 0;
}

.sales-consultant__name {
	margin: 0;
	font-size: var(--em-text-base);
	font-weight: var(--em-weight-semibold);
	line-height: var(--em-leading-snug);
}

.sales-consultant__name a {
	text-decoration: none;
}

.sales-consultant__name a:hover,
.sales-consultant__name a:focus-visible {
	text-decoration: underline;
}

.sales-consultant__role {
	margin: var(--em-space-1) 0 0;
	color: var(--em-color-text-muted);
	font-size: var(--em-text-sm);
	line-height: var(--em-leading-snug);
}

.sales-consultant__contact {
	margin: var(--em-space-4) 0 0;
	padding: 0;
	list-style: none;
	font-size: var(--em-text-sm);
}

.sales-consultant__contact li + li {
	margin-top: var(--em-space-2);
}

.sales-consultant__contact a {
	display: inline-block;
	padding-block: var(--em-space-1);
	overflow-wrap: anywhere;
}

/* -- Business information -------------------------------------------------- */

.sales-facts {
	padding-top: var(--em-section-sm);
	border-top: 1px solid var(--em-color-border);
}

.sales-facts__groups {
	display: grid;
	gap: var(--em-space-6);
	margin-bottom: var(--em-space-6);
}

.sales-facts__group-title,
.sales-facts__note-title {
	margin: 0 0 var(--em-space-3);
	color: var(--em-color-text-muted);
	font-size: var(--em-text-xs);
	font-weight: var(--em-weight-semibold);
	letter-spacing: var(--em-tracking-wide);
	text-transform: uppercase;
}

.sales-facts__list {
	margin: 0;
}

.sales-facts__row {
	display: flex;
	align-items: baseline;
	justify-content: space-between;
	gap: var(--em-space-4);
	padding-block: var(--em-space-3);
	border-bottom: 1px solid var(--em-color-table-border);
	font-size: var(--em-text-sm);
}

.sales-facts__row dt {
	flex: 0 0 auto;
	color: var(--em-color-text-muted);
}

.sales-facts__row dd {
	margin: 0;
	color: var(--em-color-text);
	font-weight: var(--em-weight-medium);
	text-align: right;
	overflow-wrap: anywhere;
}

.sales-facts__notes {
	display: grid;
	gap: var(--em-space-5);
}

.sales-facts__note p {
	margin: 0;
	color: var(--em-color-text);
	font-size: var(--em-text-base);
	line-height: var(--em-leading-loose);
}

.sales-similar {
	padding-block: var(--em-section-sm);
	background-color: var(--em-color-surface);
}

.sales-similar__grid {
	gap: var(--em-space-5);
}


/* ==========================================================================
   16  INQUIRY FORMS — EUROMIG BUSINESS

   CASE 13. The general consultation form on Contacts, and the business inquiry
   form on a Sales listing.

   THE PLUGIN OWNS THE FIELDS; THIS OWNS THE LOOK. `euromig-inquiries` emits
   structural markup and no colour, and this theme declares
   `add_theme_support( 'euromig-inquiries-styles' )` so the plugin's own
   fallback stylesheet is never enqueued here — one stylesheet, already in the
   head, no second request and no flash of unstyled form.

   IT IS BUILT ON THE FORM PRIMITIVES THAT ALREADY EXISTED. `.form-field`,
   `.form-label`, `.form-help`, `.form-error` and `.form-choice` were written in
   CASE 10 "ready for CASE 13 to attach a real one to", and they are used as
   they stand. What is added below is the section frame, the two-column grid,
   the listing-context panel and the result states.
   ========================================================================== */

.contact-form-section,
.sales-inquiry {
	padding-block: var(--em-section-md);
	background-color: var(--em-color-surface);
	border-top: 1px solid var(--em-color-border);
}

/*
 * On a listing page the form follows the description inside the same article,
 * so it needs a little more separation from the text above it than the Contacts
 * page does.
 */
.sales-inquiry {
	margin-top: var(--em-section-sm);
}

.inquiry {
	max-width: 46rem;
}

/* -- The listing context ------------------------------------------------- */
/*
 * WHAT THE INQUIRY IS ABOUT, stated once and quietly. No photograph and no
 * price: both are already on this page, and repeating them turns an inquiry box
 * into a second product card competing with the first.
 */

.inquiry__context {
	margin-bottom: var(--em-space-5);
	padding: var(--em-space-4);
	border-left: 4px solid var(--em-color-accent);
	background-color: var(--em-color-brand-tint);
}

.inquiry__context-label {
	margin: 0 0 var(--em-space-1);
	color: var(--em-color-text-muted);
	font-size: var(--em-text-sm);
	font-weight: var(--em-weight-medium);
	letter-spacing: 0.04em;
	text-transform: uppercase;
}

.inquiry__context-title {
	margin: 0;
	color: var(--em-color-brand);
	font-size: var(--em-text-lg);
	font-weight: var(--em-weight-semibold);
	line-height: var(--em-leading-snug);
}

.inquiry__context-reference {
	margin: var(--em-space-2) 0 0;
	color: var(--em-color-text-muted);
	font-size: var(--em-text-sm);
}

/* -- Result and error states --------------------------------------------- */
/*
 * BOTH STATES CARRY A LEFT RULE AND A LABEL, not colour alone. A visitor who
 * cannot distinguish green from red still sees which of the two happened from
 * the words and the position.
 *
 * COMPACT, AS OF CASE 13.1 TASK 45. The first version of these panels used the
 * section's own padding and heading size, which made a two-line error message
 * occupy a quarter of a phone screen and pushed the fields the visitor needed to
 * fix below the fold — so correcting one mistake began with scrolling past the
 * notice about it. The rule, the colour and the wording are unchanged; only the
 * space they take is. Red is confined to the rule, the title and the links, and
 * never fills the panel: an error is one thing to fix, not an alarm.
 */

.inquiry__result,
.inquiry__errors {
	margin-bottom: var(--em-space-4);
	padding: var(--em-space-3) var(--em-space-4);
	border: 1px solid var(--em-color-border);
	border-left-width: 3px;
	border-radius: var(--em-radius-sm);
	background-color: var(--em-color-bg);
}

.inquiry__result--success {
	border-left-color: var(--em-color-success);
}

.inquiry__result--error,
.inquiry__errors {
	border-left-color: var(--em-color-danger);
}

/*
 * The banner is focused programmatically — after the redirect on the no-JS
 * path, and after the fetch resolves on the enhanced one — so it must not paint
 * a focus ring: the visitor did not tab to it. Keyboard focus on the links
 * INSIDE it is unaffected.
 */
.inquiry__result:focus,
.inquiry__errors:focus {
	outline: none;
}

.inquiry__result-title {
	margin: 0;
	color: var(--em-color-brand);
	font-size: var(--em-text-base);
	font-weight: var(--em-weight-semibold);
	line-height: var(--em-leading-snug);
}

/*
 * A SMALL GOLD MARK, NOT A BANNER — CASE 13.1 TASK 46. The confirmation is a
 * quiet, finished thing: the house accent, one tick, and the sentence. It is
 * decorative and hidden from assistive technology, which reads `role="status"`
 * and the sentence itself.
 */
.inquiry__result--success .inquiry__result-title::before {
	content: "\2713";
	display: inline-block;
	margin-right: var(--em-space-2);
	color: var(--em-color-accent);
	font-weight: var(--em-weight-bold);
}

.inquiry__reference {
	margin: var(--em-space-1) 0 0;
	color: var(--em-color-text-muted);
	font-size: var(--em-text-sm);
}

.inquiry__result--error p {
	margin: 0;
	font-size: var(--em-text-sm);
}

.inquiry__errors-title {
	margin: 0;
	color: var(--em-color-danger);
	font-size: var(--em-text-sm);
	font-weight: var(--em-weight-semibold);
}

.inquiry__errors-list {
	margin: var(--em-space-1) 0 0;
	padding-left: var(--em-space-4);
	font-size: var(--em-text-sm);
	line-height: var(--em-leading-snug);
}

/*
 * EACH ENTRY IS A TARGET, NOT JUST A WORD — CASE 13.1 TASK 45 and TASK 28.
 *
 * The compaction above shrank these links to about 18 CSS pixels tall, which
 * the browser pass measured and flagged. They are the shortcut from "you have
 * four problems" to the field with the first one, so on a phone they are tapped
 * — and a target under 24x24 is below WCAG 2.5.8. They are inline text links in
 * a block of text, which is that rule's named exception, so they are not held
 * to this project's stricter 32px figure for standalone buttons; they are held
 * to the 24px minimum, which costs four pixels of padding and no more.
 */
.inquiry__errors-list li + li {
	margin-top: 0.1rem;
}

.inquiry__errors-list a {
	display: inline-block;
	padding-block: 0.2rem;
	color: var(--em-color-danger);
}

/* -- The form ------------------------------------------------------------- */

.inquiry-form__grid {
	display: grid;
	gap: 0 var(--em-space-4);
}

.inquiry-form__field {
	margin-bottom: var(--em-space-4);
}

/*
 * TWO COLUMNS FOR THE SHORT FIELDS, one for the message and the consent —
 * CASE 13 TASK 48. Name beside email is the pairing people expect; a message
 * box half the width of its container looks like a mistake.
 */
@media (min-width: 48rem) {
	.inquiry-form__grid {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}

	.inquiry-form__field {
		grid-column: 1 / -1;
	}

	.inquiry-form__field--half {
		grid-column: span 1;
	}
}

/*
 * The required marker is decorative — the word "(required)" is what assistive
 * technology announces, and the `required` attribute is what the browser acts
 * on. Colour here adds emphasis for sighted users and carries nothing alone.
 */
.inquiry-form__required {
	color: var(--em-color-danger);
	font-weight: var(--em-weight-bold);
}

.inquiry-form__field--consent {
	margin-top: var(--em-space-2);
	padding: var(--em-space-3) var(--em-space-4);
	border: 1px solid var(--em-color-border);
	border-radius: var(--em-radius);
	background-color: var(--em-color-bg);
}

.inquiry-form__field--consent label {
	font-size: var(--em-text-sm);
	line-height: var(--em-leading-normal);
}

/*
 * THE CONSENT BOX IS SIZED UP FROM THE BROWSER DEFAULT.
 *
 * Left alone it renders at 13x13 CSS pixels, which the CASE 13 browser pass
 * measured and flagged. Its label is clickable, so the effective hit area was
 * always larger — but the control a person aims at on a phone was thirteen
 * pixels square, and this is the one tick standing between them and sending
 * their message. 24px is the WCAG 2.5.8 minimum and is what it now gets.
 *
 * `.form-choice` sets `min-height: 0` on checkboxes for compact use elsewhere;
 * this overrides it for the consent row only.
 */
.inquiry-form__field--consent input[type="checkbox"] {
	width: 1.5rem;
	height: 1.5rem;
	min-height: 1.5rem;
	margin-top: 0.05em;
	flex: 0 0 auto;
}

.inquiry-form__policy {
	margin-left: var(--em-space-1);
	white-space: nowrap;
}

.inquiry-form__field.is-invalid input,
.inquiry-form__field.is-invalid textarea {
	border-color: var(--em-color-danger);
}

.inquiry-form__actions {
	margin-top: var(--em-space-5);
}

/*
 * A comfortable target on a phone without becoming a full-width slab on a
 * desktop, where a button that spans 46rem reads as a banner rather than a
 * control.
 */
.inquiry-form__submit {
	min-height: 3rem;
	padding-inline: var(--em-space-6);
}

@media (max-width: 29.99rem) {
	.inquiry-form__submit {
		width: 100%;
	}
}

.inquiry-form__submit[aria-disabled="true"] {
	opacity: 0.6;
	cursor: progress;
}

/*
 * THE SENDING STATE — CASE 13.1 TASK 16 and TASK 47.
 *
 * The label sits in its own span and the script pins the button's width before
 * swapping the text, so "Send message" becoming "Sending…" — or, in Russian,
 * "Отправить сообщение" becoming "Отправка…" — does not resize the control
 * under the pointer that just clicked it.
 *
 * THE SPINNER IS SIX LINES OF CSS. A library for one indeterminate circle would
 * be a dependency and a request; a rotating half-border is the same thing. It is
 * decorative — the button's own `aria-disabled` and changed label are what
 * assistive technology reads, so nothing here is information available only as
 * animation.
 */
.inquiry-form__submit-label {
	display: inline-block;
}

.inquiry-form__submit.is-sending .inquiry-form__submit-label::before {
	content: "";
	display: inline-block;
	width: 0.85em;
	height: 0.85em;
	margin-right: var(--em-space-2);
	border: 2px solid currentColor;
	border-top-color: transparent;
	border-radius: 50%;
	vertical-align: -0.1em;
	animation: em-inquiry-spin 0.7s linear infinite;
}

@keyframes em-inquiry-spin {
	to {
		transform: rotate(360deg);
	}
}

/*
 * REDUCED MOTION GETS A STILL MARK, NOT A MISSING ONE. Dropping the animation
 * without replacing it would leave a static broken circle beside the label; the
 * ring is completed instead, so the button still reads as busy.
 */
@media (prefers-reduced-motion: reduce) {
	.inquiry-form__submit.is-sending .inquiry-form__submit-label::before {
		border-top-color: currentColor;
		opacity: 0.5;
		animation: none;
	}
}

/*
 * THE HONEYPOT IS NOT STYLED HERE, and that is deliberate.
 *
 * The plugin's template carries the positioning on the element itself, and an
 * inline style outranks every rule in this file — so a copy here would need
 * five `!important` declarations to say the same thing, and would then be
 * overriding a rule it agrees with. This stylesheet's `!important` budget is
 * nine, each one accounted for in the preamble and each one earning its place
 * against stored inline HTML from the legacy site. Spending five more to
 * duplicate a rule that already applies would be the opposite of that
 * discipline.
 *
 * The plugin's own fallback stylesheet carries the rule for themes that do not
 * declare `euromig-inquiries-styles`.
 */
/* ==========================================================================
   17  RESPONSIVE AND MOTION — EUROMIG BUSINESS

   The type scale and the section rhythm are already fluid, so what changes at
   a breakpoint is COMPOSITION — how many columns a grid has, whether the
   navigation is a row or a panel — rather than a second set of sizes.
   ========================================================================== */

@media (min-width: 48rem) {
	.post-list {
		grid-template-columns: repeat(auto-fill, minmax(min(100%, 20rem), 1fr));
	}

	.post-list--search {
		grid-template-columns: 1fr;
	}

	.service-grid {
		grid-template-columns: repeat(2, 1fr);
	}

	/* The editorial lead takes the full width; the three followers share it. */
	.insight-grid {
		grid-template-columns: repeat(3, 1fr);
	}

	.insight--lead {
		grid-column: 1 / -1;
	}
}

@media (min-width: 62rem) {
	:root {
		/* One tier. What a sticky element below the header has to clear. */
		--em-header-height: 5.5rem;
	}

	/*
	 * The hero: statement and panel side by side, the statement given the
	 * larger share so the headline sets in three lines rather than five.
	 */
	.home-hero__inner {
		grid-template-columns: 1.2fr 1fr;
		gap: var(--em-space-8);
	}

	/* Three services, three columns. Never 2 + 1 with a hole beside it. */
	.service-grid {
		grid-template-columns: repeat(3, 1fr);
	}

	/*
	 * The carousel needs no breakpoint of its own: Swiper reads its own
	 * `breakpoints` map — 1.15 slides on a phone, 2 from 600, 3 from 1024, 4
	 * from 1440 — and the no-JS grid in section 12 is `auto-fill`, so both
	 * paths already respond without a rule here.
	 */

	/*
	 * The editorial lead is set beside its followers rather than above them at
	 * this width, which reads as a front page rather than as a list.
	 */
	.insight-grid {
		grid-template-columns: 1.4fr 1fr;
		column-gap: var(--em-space-8);
		align-items: start;
	}

	.insight--lead {
		grid-column: 1;
		grid-row: 1 / span 3;
	}

	.insight--secondary {
		grid-column: 2;
	}
}

/* --------------------------------------------------------------------------
   The marketplace.

   THE DRAWER IS A MOBILE-ONLY BEHAVIOUR, and it is expressed as one: below
   48rem the panel is a fixed sheet the trigger opens, and above it the panel is
   simply the toolbar and the trigger does not exist. Nothing is toggled by
   script at desktop.
   -------------------------------------------------------------------------- */

@media (max-width: 47.99rem) {
	/*
	 * `html.js` GATES THE TRIGGER TOO, and it was missing. The panel was
	 * correctly gated, so with JavaScript off the filter form stayed open —
	 * but the Filters button appeared anyway, above an already-open form,
	 * doing nothing when pressed. The comment beside the component says a
	 * button that cannot open anything is worse than no button; this is the
	 * rule that makes it true.
	 */
	html.js .sales-filters__toggle {
		display: flex;
	}

	/*
	 * `html.js` GATES THE WHOLE DRAWER. With no JavaScript the panel is never
	 * hidden, the trigger is removed, and the form is an ordinary stacked
	 * filter above the inventory — usable, if longer. Core marketplace
	 * function must not depend on script.
	 */
	html.js .sales-filters__panel {
		position: fixed;
		inset: 0;
		z-index: 200;
		display: flex;
		flex-direction: column;
		visibility: hidden;
		overflow-y: auto;
		padding: var(--em-space-4);
		border: 0;
		border-radius: 0;
		background-color: var(--em-color-bg);
		opacity: 0;
		transform: translateY(1.5rem);
		/*
		 * `visibility` IS SWITCHED, NEVER TRANSITIONED, and this was a real
		 * defect rather than a nicety. A transitioned `visibility` is a
		 * discrete property: it flips at the MIDPOINT of the duration, so with
		 * a 180ms transition the panel was still computed `hidden` for the
		 * first 90 milliseconds after it opened — and `focus()` on a hidden
		 * element is silently ignored, so the drawer opened with focus left
		 * behind it on the trigger.
		 *
		 * Opening flips it at once (`0s`); closing delays it until the fade has
		 * finished (`0s linear <duration>`), which is what keeps the panel from
		 * disappearing before it has faded.
		 */
		transition: opacity var(--em-duration) var(--em-easing),
		            transform var(--em-duration) var(--em-easing),
		            visibility 0s linear var(--em-duration);
	}

	html.js .sales-filters__panel.is-open {
		visibility: visible;
		opacity: 1;
		transform: none;
		transition: opacity var(--em-duration) var(--em-easing),
		            transform var(--em-duration) var(--em-easing),
		            visibility 0s;
	}

	html.js .sales-filters__panel-head {
		display: flex;
		align-items: center;
		justify-content: space-between;
		gap: var(--em-space-3);
		margin-bottom: var(--em-space-4);
		padding-bottom: var(--em-space-3);
		border-bottom: 1px solid var(--em-color-border);
	}

	.sales-filters__panel-title {
		margin: 0;
		color: var(--em-color-brand);
		font-size: var(--em-text-lg);
		font-weight: var(--em-weight-semibold);
	}

	html.js .sales-filters__actions {
		margin-top: auto;
		padding-top: var(--em-space-5);
	}

	html.js .sales-filters__submit {
		flex: 1 1 auto;
		justify-content: center;
	}

	.marketplace__toolbar {
		align-items: flex-start;
	}
}

@media (min-width: 37.5rem) {
	.sales-filters__fields {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}

	.marketplace__grid {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}
}

@media (min-width: 48rem) {
	/*
	 * The toolbar shape. `--search` takes twice the width of a select because
	 * a keyword needs room and a sector name does not, and the actions sit on
	 * the same row so the whole control is one band rather than two.
	 */
	.sales-filters__fields {
		grid-template-columns: repeat(2, minmax(0, 1fr));
		align-items: end;
	}

	.sales-filters__actions {
		margin-top: var(--em-space-3);
	}
}

@media (min-width: 64rem) {
	/*
	 * ONE ROW, SIZED BY THE CONTROLS THAT EXIST. The class carries the count,
	 * so the row is laid out for the filters this dataset justifies rather
	 * than for a fixed set — the day a second country appears the facet gains
	 * an option, the count becomes 5, and the row re-proportions itself
	 * without anyone editing a template.
	 *
	 * Keyword gets twice a select's width because a business name needs room
	 * and "All sectors" does not; price gets a little extra for two numbers
	 * and a dash.
	 */
	.sales-filters__fields--3 {
		grid-template-columns: 2fr 1fr 1.2fr;
	}

	.sales-filters__fields--4 {
		grid-template-columns: 2fr 1.1fr 1fr 1.3fr;
	}

	.sales-filters__fields--5 {
		grid-template-columns: 1.8fr 1.1fr 1fr 1fr 1.3fr;
	}
}

@media (min-width: 64rem) {
	.marketplace__grid {
		grid-template-columns: repeat(3, minmax(0, 1fr));
	}

	.sales-similar__grid {
		grid-template-columns: repeat(4, minmax(0, 1fr));
	}

	/*
	 * One listing: description left, the decision right. 68 / 32 at this
	 * width, which keeps the rail wide enough for a consultant's name and
	 * telephone number on one line.
	 */
	.sales-detail__layout {
		grid-template-columns: minmax(0, 1fr) 20rem;
		column-gap: var(--em-space-8);
		align-items: start;
	}

	/*
	 * STICKY, BUT ONLY WHEN IT FITS. A rail taller than the viewport that is
	 * also sticky simply never scrolls to its own bottom, so the visitor can
	 * never reach the consultant. `max-height` plus its own scroll would be
	 * worse. This sticks the rail and lets a tall one scroll with the page.
	 */
	.sales-detail__rail {
		position: sticky;
		top: calc(var(--em-admin-bar-height) + var(--em-header-height) + var(--em-space-4));
		align-self: start;
	}

	.sales-facts__groups {
		grid-template-columns: repeat(2, minmax(0, 1fr));
		gap: var(--em-space-7);
	}
}

@media (min-width: 90rem) {
	/*
	 * FOUR ACROSS AT 1440. Measured rather than assumed: a card is 281px at
	 * this width, the same width the homepage carousel card was accepted at in
	 * CASE 11.3, and the catalogue card carries one more line than that one.
	 */
	.marketplace__grid {
		grid-template-columns: repeat(4, minmax(0, 1fr));
	}
}

/*
 * Motion is decoration here, never information: no state in this theme is
 * communicated only by an animation, so switching them off loses nothing.
 */
@media (prefers-reduced-motion: reduce) {
	html {
		scroll-behavior: auto;
	}

	*,
	*::before,
	*::after {
		animation-duration: 0.01ms !important;
		animation-iteration-count: 1 !important;
		transition-duration: 0.01ms !important;
		scroll-behavior: auto !important;
	}
}

@media print {
	.site-header,
	.site-footer,
	.skip-link,
	.pagination,
	.search-form {
		display: none;
	}

	body {
		color: #000000;
	}
}
