/*
Theme Name: Cardinal Security Services
Theme URI: https://cardinal-ng.com/
Description: Custom theme for Cardinal Security Services Limited. Creates the site's pages, news and guides when activated. See README.md.
Version: 1.0.0
Requires at least: 6.3
Requires PHP: 7.4
License: Proprietary
Text Domain: cardinal
*/

/* Cardinal Security Services — site styles
   Direction: international security agency. Dark operations-room navy, sharp edges,
   thin rules, line icons, maps and diagrams instead of photography.
   Brand: Cardinal navy and orange (orange used as a signal colour only).
   Type: IBM Plex Sans, with IBM Plex Mono for coordinates. */

:root {
  --night: #07111F;
  --navy: #0A1A2E;
  --panel: #0E1C30;
  --line-d: rgba(255, 255, 255, .10);
  --on-dark: #C3CEDD;
  --on-dark-2: #8C9BB1;
  --orange: #EE6212;
  --orange-dk: #C94E0A;
  --link: #B4521A;
  --ink: #101C2E;
  --muted: #56627A;
  --line: #DCE2EA;
  --soft: #F3F5F8;
  --white: #FFFFFF;
  --radius: 2px;
  --maxw: 1240px;
  --gutter: clamp(16px, 4vw, 36px);
  --sans: "IBM Plex Sans", system-ui, -apple-system, "Segoe UI", Arial, sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, "SFMono-Regular", Menlo, monospace;
  --grid: linear-gradient(rgba(255,255,255,.035) 1px, transparent 1px) 0 0 / 56px 56px,
          linear-gradient(90deg, rgba(255,255,255,.035) 1px, transparent 1px) 0 0 / 56px 56px;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body { margin: 0; font-family: var(--sans); font-size: 1.0625rem; line-height: 1.65; color: var(--ink); background: var(--white); -webkit-font-smoothing: antialiased; }
img, svg { max-width: 100%; }
img { display: block; }
a { color: var(--link); text-underline-offset: 3px; }
a:hover { color: var(--ink); }
[id] { scroll-margin-top: 110px; }

h1, h2, h3, h4 { font-family: var(--sans); color: var(--navy); line-height: 1.12; margin: 0 0 .5em; text-wrap: balance; }
h1 { font-size: clamp(2.3rem, 4.8vw, 3.7rem); font-weight: 600; letter-spacing: -.025em; }
h2 { font-size: clamp(1.75rem, 3vw, 2.5rem); font-weight: 600; letter-spacing: -.02em; }
h3 { font-size: 1.22rem; font-weight: 600; letter-spacing: -.005em; }
p { margin: 0 0 1em; max-width: 68ch; }
ul, ol { padding-left: 1.2em; }
.muted { color: var(--muted); }
.vh { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.wrap { max-width: var(--maxw); margin: 0 auto; padding-inline: var(--gutter); }
.skip { position: absolute; left: -9999px; }
.skip:focus { left: 16px; top: 16px; background: var(--white); padding: 8px 14px; z-index: 200; }
:focus-visible { outline: 2px solid var(--orange); outline-offset: 3px; }
.ico { width: 28px; height: 28px; flex: none; }

/* ---------- Buttons: square, quiet, deliberate ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 10px; font-family: var(--sans); font-weight: 600; font-size: .97rem; letter-spacing: .01em; text-decoration: none; line-height: 1.2; padding: 1em 1.6em; border-radius: var(--radius); border: 1px solid transparent; cursor: pointer; transition: background-color .2s, border-color .2s, color .2s; }
.btn-red { background: var(--orange-dk); color: var(--white); }
.btn-red:hover { background: #A94108; color: var(--white); }
.btn-dark { background: var(--navy); color: var(--white); margin-top: 6px; }
.btn-dark:hover { background: var(--night); color: var(--white); }
.btn-ghost { border-color: rgba(255,255,255,.4); color: var(--white); background: transparent; }
.btn-ghost:hover { border-color: var(--white); background: rgba(255,255,255,.06); color: var(--white); }
.btn-line { border-color: var(--navy); color: var(--navy); background: transparent; }
.btn-line:hover { background: var(--navy); color: var(--white); }
.btn-white { background: var(--white); color: var(--navy); }
.btn-white:hover { background: var(--soft); color: var(--navy); }
.btn-sm { padding: .72em 1.2em; font-size: .9rem; }

/* ---------- Top bar + header ---------- */
.topbar { background: var(--night); color: var(--on-dark-2); font-size: .84rem; border-bottom: 1px solid var(--line-d); }
.topbar .wrap { display: flex; justify-content: space-between; gap: 16px; padding-block: 9px; }
.topbar-links { display: flex; gap: 24px; }
.topbar a { color: var(--white); text-decoration: none; }
.topbar a:hover { color: var(--orange); }
.site-header { position: sticky; top: 0; z-index: 60; background: var(--white); border-bottom: 1px solid var(--line); transition: box-shadow .2s; }
.site-header.scrolled { box-shadow: 0 1px 0 var(--line), 0 10px 30px rgba(7,17,31,.06); }
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; gap: 24px; min-height: 82px; }
.brand img { height: 54px; width: auto; }
.nav { display: flex; align-items: center; gap: 28px; }
.nav > ul { display: flex; align-items: center; gap: 2px; list-style: none; margin: 0; padding: 0; }
.nav > ul > li { position: relative; display: flex; align-items: center; }
.nav > ul > li > a { font-weight: 500; font-size: .97rem; color: var(--ink); text-decoration: none; padding: 29px 14px 27px; border-bottom: 2px solid transparent; transition: color .2s, border-color .2s; }
.nav > ul > li > a:hover { color: var(--orange-dk); }
.nav > ul > li > a[aria-current="page"] { color: var(--navy); font-weight: 600; border-bottom-color: var(--orange); }
.sub-toggle { display: none; }
.has-sub > a::after { content: ""; display: inline-block; width: 6px; height: 6px; margin-left: 8px; border-right: 1.5px solid currentColor; border-bottom: 1.5px solid currentColor; transform: translateY(-3px) rotate(45deg); }
.sub { position: absolute; top: 100%; left: 0; min-width: 320px; list-style: none; margin: 0; padding: 8px 0; background: var(--white); border: 1px solid var(--line); border-top: 2px solid var(--orange); box-shadow: 0 20px 40px rgba(7,17,31,.12); opacity: 0; visibility: hidden; transform: translateY(4px); transition: opacity .15s, transform .15s, visibility .15s; }
.has-sub:hover .sub, .has-sub:focus-within .sub { opacity: 1; visibility: visible; transform: none; }
.sub a { display: block; padding: 11px 20px; color: var(--ink); text-decoration: none; font-weight: 500; font-size: .95rem; }
.sub a:hover { background: var(--soft); color: var(--orange-dk); }
.nav-toggle { display: none; background: none; border: 0; width: 44px; height: 44px; cursor: pointer; position: relative; }
.bars, .bars::before, .bars::after { position: absolute; left: 10px; width: 24px; height: 2px; background: var(--navy); transition: transform .2s; }
.bars { top: 21px; }
.bars::before { content: ""; left: 0; top: -7px; }
.bars::after { content: ""; left: 0; top: 7px; }
.nav-toggle[aria-expanded="true"] .bars { background: transparent; }
.nav-toggle[aria-expanded="true"] .bars::before { transform: translateY(7px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] .bars::after { transform: translateY(-7px) rotate(-45deg); }

/* ---------- Home hero: operations map ---------- */
.hero { position: relative; color: var(--white); background: var(--grid), radial-gradient(1200px 600px at 78% 40%, #0F2442 0%, var(--night) 70%); background-color: var(--night); padding-top: clamp(56px, 8vw, 96px); overflow: hidden; }
.hero-grid { display: grid; grid-template-columns: 1.05fr .95fr; gap: 40px; align-items: center; }
.hero h1 { color: var(--white); }
.hero .lede { font-size: clamp(1.08rem, 1.5vw, 1.22rem); color: var(--on-dark); max-width: 600px; margin: 22px 0 34px; }
.coord { font-family: var(--mono); font-size: .86rem; color: var(--orange); letter-spacing: .04em; margin: 0 0 22px; display: flex; flex-wrap: wrap; gap: 14px; align-items: center; }
.coord span { color: var(--on-dark-2); font-family: var(--sans); letter-spacing: 0; }
.coord::before { content: ""; width: 8px; height: 8px; background: var(--orange); border-radius: 50%; box-shadow: 0 0 0 4px rgba(232,112,42,.2); }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; }
.hero-map { margin: 0; position: relative; }
.stats { margin: clamp(48px, 7vw, 80px) 0 0; display: grid; grid-template-columns: repeat(4, 1fr); border-top: 1px solid var(--line-d); }
.stats > div { padding: 28px 24px 36px; border-left: 1px solid var(--line-d); }
.stats > div:first-child { border-left: 0; padding-left: 0; }
.stats dt { font-size: clamp(1.9rem, 3vw, 2.6rem); font-weight: 600; color: var(--white); line-height: 1; letter-spacing: -.03em; }
.stats dd { margin: 10px 0 0; color: var(--on-dark-2); font-size: .95rem; line-height: 1.45; }

/* Maps */
.map .c { fill: #12233B; stroke: #22385A; stroke-width: .8; }
.map .c.sup { fill: #1C3B66; }
.map .c.hq { fill: var(--orange); stroke: #F39A62; }
.map .link { fill: none; stroke: var(--orange); stroke-width: 1.2; stroke-dasharray: 3 4; opacity: .75; }
.map .pin { fill: var(--white); stroke: var(--orange); stroke-width: 2; }
.map .lab { fill: var(--on-dark); font: 600 13px var(--sans); }
.map .hqlab, .map .lab.hq { fill: var(--white); }
.map .lab.op { fill: var(--on-dark-2); font-weight: 500; }
.map .pulse { fill: none; stroke: var(--orange); stroke-width: 2; transform-box: fill-box; transform-origin: center; animation: pulse 2.4s ease-out infinite; }
.map .ng { fill: #12233B; stroke: #3A5680; stroke-width: 1.2; }
.map .city { fill: var(--white); stroke: var(--orange); stroke-width: 2; }
.map .city.op { fill: #7F93B0; stroke: none; }
.map .city.hq { fill: var(--orange); stroke: var(--white); }
@keyframes pulse { 0% { transform: scale(.7); opacity: .9; } 100% { transform: scale(2.4); opacity: 0; } }

/* ---------- Sections ---------- */
.section { padding-block: clamp(64px, 9vw, 112px); }
.section-white { background: var(--white); }
.section-soft { background: var(--soft); }
.section-navy, .section-ink { background: var(--grid), var(--night); background-color: var(--night); color: var(--on-dark); }
.section-navy h2, .section-navy h3, .section-ink h2, .section-ink h3 { color: var(--white); }
.section-navy p, .section-ink p { color: var(--on-dark); }
.section-head { display: grid; grid-template-columns: 1fr 1fr; gap: 16px 64px; align-items: end; margin-bottom: 48px; padding-top: 22px; border-top: 1px solid var(--line); position: relative; }
.section-head::before { content: ""; position: absolute; top: -1px; left: 0; width: 56px; height: 3px; background: var(--orange); }
.section-navy .section-head { border-top-color: var(--line-d); }
.section-head h2 { margin: 0; }
.section-head p { margin: 0; color: var(--muted); }
.section-navy .section-head p { color: var(--on-dark-2); }
.small-h { font-size: .95rem; font-weight: 500; color: var(--muted); margin-bottom: 26px; text-align: center; }

/* Services: ruled grid, line icons */
.svc-grid { display: grid; grid-template-columns: repeat(3, 1fr); border-top: 1px solid var(--line); border-left: 1px solid var(--line); }
.svc { position: relative; padding: 36px 32px 34px; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); display: flex; flex-direction: column; background: var(--white); transition: background-color .25s; }
.svc::before { content: ""; position: absolute; left: -1px; top: -1px; height: 2px; width: 0; background: var(--orange); transition: width .3s; }
.svc:hover { background: var(--soft); }
.svc:hover::before { width: calc(100% + 2px); }
.svc-ico { color: var(--orange); margin-bottom: 26px; }
.svc-ico .ico { width: 40px; height: 40px; }
.svc h3 a { color: var(--navy); text-decoration: none; }
.svc h3 a::after { content: ""; position: absolute; inset: 0; }
.svc p { color: var(--muted); font-size: .99rem; }
.more { margin-top: auto; font-weight: 600; font-size: .93rem; color: var(--navy); text-decoration: none; display: inline-flex; align-items: center; gap: 10px; }
.more::after { content: ""; width: 18px; height: 1px; background: var(--orange); transition: width .2s; }
.svc:hover .more::after, .more:hover::after { width: 28px; }

/* Split */
.split { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(40px, 6vw, 88px); align-items: center; }
.ticks { list-style: none; padding: 0; margin: 26px 0 30px; display: grid; gap: 12px; }
.ticks.two { grid-template-columns: 1fr 1fr; column-gap: 28px; }
.ticks li { position: relative; padding-left: 26px; font-weight: 500; font-size: .99rem; }
.ticks li::before { content: ""; position: absolute; left: 0; top: .62em; width: 12px; height: 2px; background: var(--orange); }

/* Diagrams */
.diagram { margin: 0; position: relative; }
.rings-fig { padding: 28px; background: var(--white); border: 1px solid var(--line); }
.rings-fig::before, .rings-fig::after { content: ""; position: absolute; width: 18px; height: 18px; border-color: var(--orange); border-style: solid; }
.rings-fig::before { top: -1px; left: -1px; border-width: 2px 0 0 2px; }
.rings-fig::after { bottom: -1px; right: -1px; border-width: 0 2px 2px 0; }
.rings-fig svg { display: block; width: 100%; max-width: 440px; margin: 0 auto; }
.ring { stroke: var(--white); stroke-width: 2; }
.ring.r0 { fill: #E4E9F0; } .ring.r1 { fill: #CBD5E3; } .ring.r2 { fill: #A9B9CF; } .ring.r3 { fill: #6E86A6; } .ring.r4 { fill: #3B5578; }
.ring-core { fill: var(--navy); stroke: var(--orange); stroke-width: 2; }
.ring-lab { font: 600 12.5px var(--sans); fill: var(--navy); }
.ring-lab.on-dark { fill: var(--white); }
.ring-core-lab { font: 600 13px var(--sans); fill: var(--white); }
.rings-fig figcaption { font-size: .92rem; color: var(--muted); text-align: center; margin-top: 16px; }
.prose .rings-fig { margin: 0 0 40px; }

.flow { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(4, 1fr); counter-reset: f; }
.flow.flow-5 { grid-template-columns: repeat(5, 1fr); }
.flow li { position: relative; padding: 0 20px 0 0; counter-increment: f; }
.flow li::before { content: ""; position: absolute; top: 32px; left: 72px; right: 8px; height: 1px; background: repeating-linear-gradient(90deg, var(--orange) 0 6px, transparent 6px 11px); }
.flow li:last-child::before { display: none; }
.flow-ico { width: 64px; height: 64px; display: grid; place-items: center; border: 1px solid rgba(255,255,255,.22); color: var(--orange); background: var(--panel); margin-bottom: 20px; position: relative; }
.flow-ico::after { content: counter(f); position: absolute; top: -9px; right: -9px; width: 20px; height: 20px; background: var(--orange); color: var(--white); font: 600 .72rem/20px var(--sans); text-align: center; }
.flow b { display: block; color: var(--white); font-size: 1.08rem; font-weight: 600; margin-bottom: 6px; }
.flow span:not(.flow-ico) { display: block; color: var(--on-dark-2); font-size: .94rem; line-height: 1.5; }
.flow-light .flow-ico { background: var(--white); border-color: var(--line); }
.flow-light b { color: var(--navy); }
.flow-light span:not(.flow-ico) { color: var(--muted); }
.prose .flow { margin: 16px 0 40px; }
.prose .flow li { padding-right: 14px; }

/* Sectors */
.sectors { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 0; border-top: 1px solid var(--line); }
.sectors a { display: grid; grid-template-columns: 44px 1fr; gap: 2px 18px; align-items: start; padding: 28px 24px 28px 0; border-bottom: 1px solid var(--line); text-decoration: none; color: var(--ink); }
.sectors .ico { grid-row: span 2; width: 36px; height: 36px; color: var(--navy); transition: color .2s; }
.sectors b { font-size: 1.1rem; font-weight: 600; color: var(--navy); }
.sectors span { color: var(--muted); font-size: .95rem; }
.sectors a:hover .ico, .sectors a:hover b { color: var(--orange-dk); }

/* Badges + timeline */
.badges { list-style: none; padding: 0; margin: 0 0 64px; display: grid; grid-template-columns: repeat(5, 1fr); border-top: 1px solid var(--line); border-left: 1px solid var(--line); background: var(--white); }
.badges li { padding: 26px 22px; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.badges .ico { color: var(--orange); width: 30px; height: 30px; margin-bottom: 18px; }
.badges b { display: block; font-size: 1.15rem; font-weight: 600; color: var(--navy); margin-bottom: 6px; }
.badges span { font-size: .9rem; line-height: 1.45; color: var(--muted); }
.timeline-h { font-size: 1.1rem; margin-bottom: 26px; }
.timeline { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(5, 1fr); position: relative; }
.timeline::before { content: ""; position: absolute; top: 7px; left: 0; right: 0; height: 1px; background: var(--line); }
.timeline li { position: relative; padding: 32px 18px 0 0; }
.timeline li::before { content: ""; position: absolute; top: 0; left: 0; width: 15px; height: 15px; background: var(--soft); border: 2px solid var(--orange); }
.timeline b { display: block; font-family: var(--mono); font-weight: 500; color: var(--orange-dk); margin-bottom: 6px; }
.timeline span { display: block; color: var(--navy); font-weight: 500; font-size: .95rem; line-height: 1.4; margin-bottom: 6px; }

/* Where we operate */
.where { display: grid; grid-template-columns: 1.1fr .9fr; gap: 48px; align-items: center; }
.map-fig { position: relative; }
.map-key { list-style: none; padding: 0; margin: 14px 0 0; display: flex; flex-wrap: wrap; gap: 8px 22px; font-size: .88rem; color: var(--on-dark-2); }
.map-key .k { display: inline-block; width: 11px; height: 11px; border-radius: 50%; margin-right: 8px; vertical-align: -1px; }
.map-key .k.hq { background: var(--orange); }
.map-key .k.reg { background: var(--white); border: 2px solid var(--orange); }
.map-key .k.op { background: #7F93B0; }
.where-lists { display: grid; gap: 26px; }
.where h3 { font-size: .98rem; margin-bottom: .7em; color: var(--white); }
.where p { margin: 0; font-weight: 500; color: var(--white); }
.chips { list-style: none; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.chips li { border: 1px solid var(--line-d); background: rgba(255,255,255,.03); padding: 5px 12px; font-size: .9rem; color: var(--on-dark); }
.prose .where, .prose .where-lists { color: var(--ink); }
.prose .where { grid-template-columns: 1fr; background: var(--night); padding: 28px; }

/* Clients */
.clients-band { padding-block: 64px; border-bottom: 1px solid var(--line); }
.clients { list-style: none; padding: 0; margin: 0; display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 28px 40px; }
.clients li { display: flex; align-items: center; }
.clients img { width: auto; max-width: 150px; object-fit: contain; filter: grayscale(1); opacity: .65; transition: filter .3s, opacity .3s; }
.clients li:hover img { filter: none; opacity: 1; }

/* Strip (sister company) */
.strip { background: var(--soft); border-bottom: 1px solid var(--line); }
.strip .wrap { display: flex; align-items: center; gap: 22px; padding-block: 28px; }
.strip-ico { color: var(--orange); }
.strip p { margin: 0; flex: 1; color: var(--muted); }
.strip b { color: var(--navy); }

/* ---------- Contact band ---------- */
.band-red { background: var(--grid), var(--night); background-color: var(--night); color: var(--white); }
.band-red .wrap { display: grid; grid-template-columns: 1.05fr .95fr; gap: 40px 72px; align-items: center; padding-block: clamp(64px, 8vw, 104px); }
.band-red h2 { color: var(--white); }
.band-red p { color: var(--on-dark); }
.band-contacts { list-style: none; margin: 28px 0 0; padding: 0; border-top: 1px solid var(--line-d); }
.band-contacts li { padding: 14px 0; border-bottom: 1px solid var(--line-d); }
.band-contacts a { color: var(--white); text-decoration: none; font-weight: 500; font-size: clamp(1.1rem, 1.8vw, 1.35rem); }
.band-contacts a:hover { color: var(--orange); }
.band-form .wrap { align-items: start; }

/* ---------- Inner page header ---------- */
.page-head { background: var(--grid), radial-gradient(900px 500px at 85% 50%, #10264A 0%, var(--night) 70%); background-color: var(--night); color: var(--white); padding-block: clamp(64px, 9vw, 112px) clamp(56px, 7vw, 88px); overflow: hidden; }
.page-head .wrap { display: grid; grid-template-columns: 1fr auto; gap: 40px; align-items: center; }
.page-head h1 { color: var(--white); max-width: 20ch; }
.page-head .lede { color: var(--on-dark); font-size: clamp(1.05rem, 1.5vw, 1.18rem); max-width: 60ch; margin: 18px 0 0; }
.page-mark { width: clamp(150px, 18vw, 230px); aspect-ratio: 1; display: grid; place-items: center; border: 1px solid var(--line-d); position: relative; color: var(--orange); }
.page-mark::before, .page-mark::after { content: ""; position: absolute; width: 20px; height: 20px; border-color: var(--orange); border-style: solid; }
.page-mark::before { top: -1px; left: -1px; border-width: 2px 0 0 2px; }
.page-mark::after { bottom: -1px; right: -1px; border-width: 0 2px 2px 0; }
.page-ico { width: 46%; height: 46%; stroke-width: 1.1; }
.crumbs { list-style: none; padding: 0; margin: 0 0 22px; display: flex; flex-wrap: wrap; gap: 6px; font-size: .88rem; color: var(--on-dark-2); }
.crumbs li + li::before { content: "/"; margin-right: 6px; color: #4E6385; }
.crumbs a { color: var(--on-dark); text-decoration: none; }
.crumbs a:hover { color: var(--orange); }
.post-meta { color: var(--on-dark-2); margin: 14px 0 0; }

/* ---------- Content layout ---------- */
.layout { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: clamp(36px, 5vw, 80px); align-items: start; }
.prose { max-width: 76ch; min-width: 0; }
.prose > p, .prose li { color: #33415A; }
.prose h2 { font-size: clamp(1.5rem, 2.3vw, 1.9rem); margin-top: 1.8em; padding-top: 18px; border-top: 1px solid var(--line); position: relative; }
.prose h2::before { content: ""; position: absolute; top: -1px; left: 0; width: 40px; height: 2px; background: var(--orange); }
.prose > h2:first-child, .prose > .diagram + h2 { margin-top: 0; }
.prose h3 { margin-top: 1.4em; }
.prose li { margin-bottom: .45em; }
.prose ul:not([class]) { padding-left: 0; list-style: none; }
.prose ul:not([class]) li { position: relative; padding-left: 24px; }
.prose ul:not([class]) li::before { content: ""; position: absolute; left: 0; top: .78em; width: 12px; height: 2px; background: var(--orange); }

.rows { margin: 12px 0 28px; display: grid; border-top: 1px solid var(--line); }
.rows > div { display: grid; grid-template-columns: minmax(180px, .8fr) 1.6fr; gap: 6px 32px; padding: 18px 0; border-bottom: 1px solid var(--line); }
.rows dt { font-weight: 600; color: var(--navy); line-height: 1.4; }
.rows dd { margin: 0; color: var(--muted); }

.facts { list-style: none; padding: 0; margin: 12px 0 28px; display: grid; grid-template-columns: repeat(2, 1fr); border-top: 1px solid var(--line); border-left: 1px solid var(--line); }
.facts li { padding: 20px 22px; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.facts strong { display: block; font-size: 1.05rem; font-weight: 600; color: var(--navy); margin-bottom: 4px; }
.facts span { color: var(--muted); font-size: .94rem; }

.steps { counter-reset: step; list-style: none; padding: 0; margin: 12px 0 28px; display: grid; gap: 18px; }
.steps li { counter-increment: step; position: relative; padding-left: 56px; min-height: 36px; }
.steps li::before { content: counter(step); position: absolute; left: 0; top: 0; width: 36px; height: 36px; border: 1px solid var(--navy); color: var(--navy); font-family: var(--mono); font-weight: 500; display: grid; place-items: center; }
.steps strong { color: var(--navy); }
.checklist { list-style: none; padding: 0; }
.checklist li { position: relative; padding-left: 32px; }
.checklist li::before { content: ""; position: absolute; left: 2px; top: .32em; width: 15px; height: 15px; border: 1.5px solid var(--orange); }

.person { display: flex; gap: 22px; align-items: center; margin: 8px 0 22px; padding: 22px; border: 1px solid var(--line); }
.monogram { width: 84px; height: 84px; flex: none; display: grid; place-items: center; background: var(--navy); color: var(--white); font-size: 1.6rem; font-weight: 600; letter-spacing: .04em; border-bottom: 3px solid var(--orange); }
.person h3 { font-size: 1.5rem; margin-bottom: .15em; }
.person-role { color: var(--muted); margin: 0; font-weight: 500; }

.aside { position: sticky; top: 104px; display: grid; gap: 20px; }
.aside-box { border: 1px solid var(--line); padding: 28px; background: var(--white); }
.aside-box:first-child { background: var(--night); border-color: var(--night); color: var(--on-dark); border-top: 3px solid var(--orange); }
.aside-box:first-child h2 { color: var(--white); }
.aside-box:first-child p { color: var(--on-dark); }
.aside-box:first-child a:not(.btn) { color: var(--white); }
.aside-box h2 { font-size: 1.22rem; margin-bottom: .5em; border: 0; padding: 0; }
.aside-box h2::before { display: none; }
.aside-box p { font-size: .96rem; color: var(--muted); }
.aside-box ul { list-style: none; padding: 0; margin: 0; }
.aside-box li { border-bottom: 1px solid var(--line); }
.aside-box:first-child li { border-bottom-color: var(--line-d); }
.aside-box li:last-child { border-bottom: 0; }
.aside-box li a { display: block; padding: 11px 0; text-decoration: none; font-weight: 500; color: var(--ink); }
.aside-box li a:hover, .aside-box li a[aria-current="page"] { color: var(--orange-dk); }
.aside-box .facts-list li { padding: 10px 0; font-weight: 500; color: var(--white); }
.aside-box .btn { width: 100%; margin-top: 4px; }

.svc-row { display: grid; grid-template-columns: 280px 1fr; gap: clamp(28px, 5vw, 64px); align-items: center; padding-block: 44px; border-bottom: 1px solid var(--line); }
.svc-row:first-child { padding-top: 0; }
.svc-row:last-child { border-bottom: 0; padding-bottom: 0; }
.svc-row-img { aspect-ratio: 1; display: grid; place-items: center; background: var(--grid), var(--night); background-color: var(--night); color: var(--orange); position: relative; }
.svc-row-img::before, .svc-row-img::after { content: ""; position: absolute; width: 18px; height: 18px; border-color: var(--orange); border-style: solid; }
.svc-row-img::before { top: 0; left: 0; border-width: 2px 0 0 2px; }
.svc-row-img::after { bottom: 0; right: 0; border-width: 0 2px 2px 0; }
.row-ico { width: 42%; height: 42%; stroke-width: 1.1; }
.svc-row p { color: var(--muted); }

.post-grid { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.post-card a { display: flex; flex-direction: column; height: 100%; text-decoration: none; color: var(--ink); border: 1px solid var(--line); background: var(--white); transition: border-color .2s; }
.post-card a:hover { border-color: var(--navy); color: var(--ink); }
.post-card-art { aspect-ratio: 16 / 8; display: grid; place-items: center; background: var(--grid), var(--night); background-color: var(--night); color: var(--orange); }
.post-ico { width: 64px; height: 64px; stroke-width: 1.2; }
.post-card-body { display: flex; flex-direction: column; gap: 10px; padding: 24px; flex: 1; }
.post-card time { font-family: var(--mono); font-size: .82rem; color: var(--muted); }
.post-card-title { font-weight: 600; font-size: 1.2rem; color: var(--navy); line-height: 1.3; }
.post-card-text { color: var(--muted); font-size: .96rem; }

/* ---------- Forms ---------- */
.form { display: grid; gap: 18px; background: var(--white); color: var(--ink); padding: clamp(24px, 4vw, 38px); border-top: 3px solid var(--orange); position: relative; }
.form h2 { color: var(--navy); font-size: clamp(1.4rem, 2.4vw, 1.75rem); }
.form .two { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.form label { display: block; font-weight: 600; font-size: .9rem; color: var(--navy); margin-bottom: 6px; }
.form .opt { font-weight: 400; color: var(--muted); }
.form input, .form select, .form textarea { width: 100%; font: inherit; font-size: 1rem; color: var(--ink); background: var(--white); border: 1px solid #C9D1DC; border-radius: var(--radius); padding: 12px 14px; transition: border-color .2s; }
.form textarea { min-height: 140px; resize: vertical; }
.form input:focus, .form select:focus, .form textarea:focus { outline: none; border-color: var(--navy); box-shadow: inset 0 -2px 0 var(--orange); }
.form .btn { width: 100%; }
.form-note { font-size: .88rem; color: var(--muted); margin: 0; }
.form-status { font-weight: 600; margin: 0; }
.form-status:empty { display: none; }
.form-status.is-error { color: #B42318; }
.form-status.is-ok { color: #1F7A45; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.contact-grid { display: grid; grid-template-columns: .9fr 1.1fr; gap: clamp(36px, 5vw, 72px); align-items: start; }
.contact-grid .form { border: 1px solid var(--line); border-top: 3px solid var(--orange); }
.contact-list { margin: 0; border-top: 1px solid var(--line); }
.contact-list > div { padding: 18px 0; border-bottom: 1px solid var(--line); }
.contact-list dt { font-weight: 600; color: var(--navy); }
.contact-list dd { margin: 4px 0 0; color: var(--muted); }
div.map { margin-top: 28px; border: 1px solid var(--line); }
div.map iframe { display: block; width: 100%; height: 320px; border: 0; filter: grayscale(.6); }

/* ---------- Footer ---------- */
.site-footer { background: var(--night); color: var(--on-dark-2); font-size: .95rem; border-top: 3px solid var(--orange); }
.site-footer .wrap { padding-block: 72px 28px; }
.footer-grid { display: grid; grid-template-columns: 1.5fr 1.3fr .8fr 1.2fr; gap: 40px; }
.footer-logo { display: inline-block; margin-bottom: 20px; }
.footer-logo img { height: 52px; width: auto; }
.site-footer h2 { font-size: .98rem; color: var(--white); margin-bottom: 1em; }
.site-footer ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 10px; }
.site-footer a { color: var(--on-dark); text-decoration: none; }
.site-footer a:hover { color: var(--orange); }
.footer-base { border-top: 1px solid var(--line-d); margin-top: 52px; padding-top: 24px; display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px; font-size: .88rem; }

/* ---------- Responsive ---------- */
@media (max-width: 1100px) {
  .nav { gap: 14px; }
  .nav > ul > li > a { padding-inline: 9px; }
  .badges { grid-template-columns: repeat(3, 1fr); }
  .flow.flow-5 { grid-template-columns: repeat(3, 1fr); row-gap: 34px; }
  .flow.flow-5 li:nth-child(3)::before { display: none; }
}
@media (max-width: 960px) {
  .topbar > .wrap > span:first-child { display: none; }
  .topbar .wrap { justify-content: center; }
  .nav-toggle { display: block; }
  .nav { display: none; position: absolute; top: 100%; left: 0; right: 0; background: var(--white); flex-direction: column; align-items: stretch; gap: 0; padding: 8px var(--gutter) 24px; border-bottom: 1px solid var(--line); box-shadow: 0 20px 40px rgba(7,17,31,.12); max-height: calc(100vh - 120px); overflow-y: auto; }
  .nav.open { display: flex; }
  .nav > ul { flex-direction: column; align-items: stretch; gap: 0; }
  .nav > ul > li { flex-wrap: wrap; border-bottom: 1px solid var(--line); }
  .nav > ul > li > a { flex: 1; padding: 14px 0; border-bottom: 0; }
  .nav > ul > li > a[aria-current="page"] { color: var(--orange-dk); }
  .has-sub > a::after { display: none; }
  .sub-toggle { display: grid; place-items: center; width: 44px; height: 44px; background: none; border: 0; cursor: pointer; }
  .sub-toggle span { width: 8px; height: 8px; border-right: 2px solid var(--navy); border-bottom: 2px solid var(--navy); transform: rotate(45deg); transition: transform .2s; }
  .sub-toggle[aria-expanded="true"] span { transform: rotate(-135deg); }
  .sub { position: static; display: none; opacity: 1; visibility: visible; transform: none; box-shadow: none; border: 0; min-width: 0; width: 100%; padding: 0 0 10px 12px; }
  .has-sub:hover .sub, .has-sub:focus-within .sub { display: none; }
  .has-sub.open .sub { display: block; }
  .nav .btn { margin-top: 18px; }
  .hero-grid, .split, .layout, .contact-grid, .band-red .wrap, .where, .section-head { grid-template-columns: 1fr; }
  .hero-map { max-width: 520px; }
  .stats { grid-template-columns: repeat(2, 1fr); }
  .stats > div:nth-child(3) { border-left: 0; padding-left: 0; }
  .stats > div:nth-child(n+3) { border-top: 1px solid var(--line-d); }
  .svc-grid, .post-grid, .sectors { grid-template-columns: repeat(2, 1fr); }
  .flow { grid-template-columns: repeat(2, 1fr); row-gap: 34px; }
  .flow li:nth-child(2)::before { display: none; }
  .timeline { grid-template-columns: repeat(3, 1fr); row-gap: 28px; }
  .svc-row { grid-template-columns: 180px 1fr; }
  .aside { position: static; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .page-mark { display: none; }
  .page-head .wrap { grid-template-columns: 1fr; }
}
@media (max-width: 640px) {
  body { font-size: 1rem; }
  .topbar-links { gap: 14px; font-size: .8rem; }
  .brand img { height: 44px; }
  .site-header .wrap { min-height: 70px; }
  .svc-grid, .post-grid, .badges, .facts, .form .two, .footer-grid, .ticks.two, .sectors, .flow, .flow.flow-5, .timeline { grid-template-columns: 1fr; }
  .flow li::before { display: none; }
  .flow li { display: grid; grid-template-columns: 64px 1fr; column-gap: 18px; padding: 0; }
  .flow-ico { grid-row: span 2; margin: 0; }
  .timeline::before { display: none; }
  .rows > div { grid-template-columns: 1fr; }
  .svc-row { grid-template-columns: 1fr; }
  .svc-row-img { max-width: 140px; }
  .strip .wrap { flex-wrap: wrap; }
  .clients { gap: 22px 30px; }
  .clients img { max-width: 120px; transform: scale(.85); }
  .rings-fig { padding: 16px; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; animation: none !important; }
}

/* ---------- News (external stories) ---------- */
.news-grid { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.news-card { display: flex; flex-direction: column; background: var(--white); border: 1px solid var(--line); transition: border-color .2s; }
.news-card:hover { border-color: var(--navy); }
.news-img { position: relative; display: block; aspect-ratio: 16 / 9; overflow: hidden; background: var(--grid), var(--night); background-color: var(--night); }
.news-img img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform .5s; }
.news-card:hover .news-img img { transform: scale(1.04); }
.news-fallback { position: absolute; inset: 0; display: grid; place-items: center; color: var(--orange); }
.news-body { display: flex; flex-direction: column; padding: 22px 24px 24px; flex: 1; }
.news-meta { display: flex; flex-wrap: wrap; gap: 4px 14px; margin: 0 0 10px; font-size: .84rem; color: var(--muted); }
.news-meta span { font-weight: 600; color: var(--orange-dk); }
.news-meta time { font-family: var(--mono); font-size: .8rem; }
.news-card h3 { font-size: 1.12rem; line-height: 1.35; margin-bottom: .55em; }
.news-card h3 a { color: var(--navy); text-decoration: none; }
.news-card h3 a:hover { color: var(--orange-dk); text-decoration: underline; }
.news-sum { color: #33415A; font-size: .95rem; margin-bottom: .8em; }
.news-why { font-size: .9rem; color: var(--muted); padding: 12px 0 0; border-top: 1px solid var(--line); margin-bottom: 16px; }
.news-why b { color: var(--navy); font-weight: 600; }
.section-head p a { color: var(--link); font-weight: 600; }
.nav-cta[aria-current="page"] { box-shadow: inset 0 -3px 0 rgba(0,0,0,.18); }
@media (max-width: 960px) { .news-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 640px) { .news-grid { grid-template-columns: 1fr; } }

/* ---------- Formatting fixes ---------- */
/* Map panel is always dark, wherever it appears */
.where { background: var(--grid), var(--night); background-color: var(--night); padding: clamp(24px, 4vw, 40px); }
.section-navy .where { background: none; padding: 0; }
.where .chips li, .prose .where .chips li { color: var(--on-dark); }
.prose .where h3 { color: var(--white); margin-top: 0; }
.prose .where p { color: var(--white); }
/* Links at the foot of cards keep their own width */
.more { align-self: flex-start; max-width: 100%; }
.more::after { flex: none; }
/* Five-step process inside a text column: vertical timeline */
.prose .flow-5, .prose .flow-light { grid-template-columns: 1fr; row-gap: 0; }
.prose .flow-5 li, .prose .flow-light li { display: grid; grid-template-columns: 56px 1fr; column-gap: 20px; padding: 0 0 22px; }
.prose .flow-5 li::before, .prose .flow-light li::before { display: block; top: 56px; bottom: 0; left: 27px; right: auto; width: 1px; height: auto; background: repeating-linear-gradient(180deg, var(--orange) 0 5px, transparent 5px 10px); }
.prose .flow-5 li:last-child::before, .prose .flow-light li:last-child::before { display: none; }
.prose .flow .flow-ico { width: 56px; height: 56px; grid-row: span 2; margin: 0; }
.prose .flow b { margin: 6px 0 2px; }
@media (max-width: 1100px) { .prose .flow.flow-5 li:nth-child(3)::before { display: block; } }

/* ---------- Page headers with a photo ---------- */
.page-head { position: relative; isolation: isolate; }
.page-head.has-photo { min-height: clamp(340px, 42vw, 480px); display: flex; align-items: flex-end; }
.page-head.has-photo .wrap { width: 100%; }
.page-photo { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: -2; }
.page-head.has-photo::before { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(90deg, rgba(7,17,31,.94) 0%, rgba(7,17,31,.78) 45%, rgba(7,17,31,.35) 100%), linear-gradient(0deg, rgba(7,17,31,.6) 0%, rgba(7,17,31,0) 45%); }
@media (max-width: 640px) { .page-head.has-photo::before { background: rgba(7,17,31,.78); } }
.news-img img.fit-contain { object-fit: contain; background: var(--white); padding: 12px; }


/* WordPress additions */
.wp-block-image img, .prose img { max-width: 100%; height: auto; }
.nav-links { display: flex; gap: 12px; margin-top: 32px; }
.admin-bar .site-header { top: 32px; }
@media (max-width: 782px) { .admin-bar .site-header { top: 46px; } }
