/* =====================================================================
   HERTS INCLUSIVE THEATRE — THEME STYLES ("Living Archive")
   ---------------------------------------------------------------------
   Works with theme.json: colours and fonts come from the theme.json
   presets, so the block editor shows the same palette and type.

   ACCESSIBILITY (WCAG 2.1 AA) — what this file guarantees:
   - Text contrast: body ink #13235E on white is 14.7:1; secondary text
     #44506E is 7.6:1; white on HIT blue #2C64C2 is 5.7:1; navy on gold
     buttons is 8.6:1. Decorative colours (violet, sky) never carry text.
   - Dyslexia-friendly reading: Atkinson Hyperlegible body at 18px, 1.65
     line height, ~65-character lines, left-aligned (never justified),
     bold rather than italics for emphasis.
   - Visible focus: 3px brand-red outline with a white halo on everything
     focusable (SC 2.4.7). Yellow outline on dark bands.
   - Touch targets: buttons and form controls at least 48px tall.
   - Motion: all animation stops under prefers-reduced-motion or the
     "Reduce motion" display setting.
   - Display settings (assets/js/hit.js) add classes to <html>:
     text-lg, text-xl, readable, dyslexic, spacing, hc, reduce-motion.
   ===================================================================== */

:root {
  /* Brand tokens (sourced from theme.json presets, with fallbacks) */
  --hit-blue:   var(--wp--preset--color--hit-blue, #2C64C2);
  --hit-blue-d: var(--wp--preset--color--hit-blue-dark, #2458B5);
  --hit-red:    var(--wp--preset--color--hit-red, #B3202A);
  --hit-yellow: var(--wp--preset--color--hit-yellow, #F5D547);
  --hit-gold:   var(--wp--preset--color--hit-gold, #F2BD5F);
  --hit-sky:    var(--wp--preset--color--hit-sky, #81C1EF);
  --hit-violet: var(--wp--preset--color--hit-violet, #B55CE2);
  --navy:       var(--wp--preset--color--navy, #12245F);
  --ink:        var(--wp--preset--color--ink, #13235E);
  --ink-2:      var(--wp--preset--color--ink-soft, #44506E);
  --mist:       var(--wp--preset--color--mist, #F3F6FC);
  --paper:      var(--wp--preset--color--white, #FFFFFF);
  --on-navy-2:  #C9D6F2;  /* secondary text on navy: 10:1 */
  --line:       #D3DCEE;
  --field:      #56627F;  /* form borders 6.2:1 (SC 1.4.11) */
  --focus:      var(--hit-red);
  --error:      #A3141F;
  --ok:         #1D6B34;

  --hit-font-body: var(--wp--preset--font-family--body, "Atkinson Hyperlegible", "Segoe UI", Verdana, sans-serif);
  --hit-font-display: var(--wp--preset--font-family--display, "Bricolage Grotesque", "Lexend", "Segoe UI", sans-serif);

  --s-1: 1rem; --s0: 1.125rem; --s1: 1.4rem; --s2: 1.85rem;
  --s3: clamp(2.1rem, 1.5rem + 2.6vw, 3.1rem);
  --s4: clamp(2.5rem, 1.5rem + 4.2vw, 4.4rem);
  --s5: clamp(2.7rem, 1.4rem + 5.6vw, 5.6rem);
  --leading: 1.65; --tracking: 0.01em; --word-gap: 0.05em; --measure: 64ch;
  --r: 16px;
  --gutter-l: max(16px, env(safe-area-inset-left, 0px));
  --gutter-r: max(16px, env(safe-area-inset-right, 0px));
  --section-y: clamp(56px, 8vw, 112px);
}

/* ---------- Display settings (set by hit.js on <html>) ---------- */
:root.text-lg { font-size: 112.5%; }
:root.text-xl { font-size: 125%; }
:root.readable { --hit-font-body: "Lexend", Verdana, sans-serif; --hit-font-display: "Lexend", Verdana, sans-serif; --tracking: 0.04em; --word-gap: 0.16em; --leading: 1.8; }
:root.dyslexic { --hit-font-body: "OpenDyslexic", "Lexend", Verdana, sans-serif; --hit-font-display: "OpenDyslexic", "Lexend", Verdana, sans-serif; --tracking: 0.02em; --word-gap: 0.12em; --leading: 1.8; }
:root.spacing { --leading: 2; --tracking: 0.06em; --word-gap: 0.2em; }
:root.hc {
  --hit-blue:#000; --hit-blue-d:#000; --navy:#000; --ink:#000; --ink-2:#000; --on-navy-2:#fff;
  --mist:#fff; --line:#000; --field:#000; --hit-gold:#FFE600; --hit-yellow:#FFE600; --hit-red:#000; --focus:#0050FF;
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-padding-top: 24px; }
body {
  margin: 0; background: var(--paper); color: var(--ink);
  font-family: var(--hit-font-body); font-size: var(--s0);
  line-height: var(--leading); letter-spacing: var(--tracking); word-spacing: var(--word-gap);
  text-align: left;            /* never justified: uneven gaps create "rivers" */
  -webkit-font-smoothing: antialiased;
}
h1, h2, h3, h4 { font-family: var(--hit-font-display); color: var(--ink); line-height: 1.1; text-wrap: balance; margin: 0; letter-spacing: -0.01em; }
:root.readable :is(h1,h2,h3,h4), :root.dyslexic :is(h1,h2,h3,h4) { letter-spacing: 0; line-height: 1.2; }
h1 { font-size: var(--s4); font-weight: 800; }
h2 { font-size: var(--s3); font-weight: 800; }
h3 { font-size: var(--s1); font-weight: 700; line-height: 1.25; }
h4 { font-size: var(--s0); font-weight: 700; }
p, li { max-width: var(--measure); }
p { margin: 0; }
a { color: var(--hit-blue-d); text-decoration: underline; text-decoration-thickness: 2px; text-underline-offset: 0.2em; }
a:hover { text-decoration-thickness: 3px; }
strong, b { font-weight: 700; }
em, i { font-style: normal; font-weight: 700; }   /* italics are harder for many dyslexic readers */
img { max-width: 100%; height: auto; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 3px; box-shadow: 0 0 0 7px #fff; border-radius: 6px; }
.is-navy :focus-visible, .site-footer :focus-visible, .brandbar :focus-visible { outline-color: var(--hit-yellow); box-shadow: 0 0 0 7px var(--navy); }

/* Skip link added by WordPress core for block themes (SC 2.4.1) */
.skip-link.screen-reader-text:focus {
  clip: auto !important; clip-path: none; width: auto; height: auto;
  top: 8px; left: 16px; z-index: 100000; padding: 12px 18px;
  background: var(--navy); color: #fff; font-weight: 700; border-radius: 8px; text-decoration: none;
}
.screen-reader-text, .visually-hidden { position: absolute !important; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }

/* WordPress flow layout adds block-gap margins between siblings. Inside
   our grid/flex components we control spacing with `gap`, so reset. */
.hit :is(.grid-2, .grid-3, .grid-4, .doors, .tiles, .voices, .stats, .hero-ctas, .tag-list, .split, .mosaic, .page-hero__grid, .header-row, .brandbar__row, .footer-grid, .badges, .steps, .chip-list, .people) > * { margin-block: 0; }

/* ---------- Layout ---------- */
.wrap { max-width: 1220px; margin-inline: auto !important; padding-left: var(--gutter-l); padding-right: var(--gutter-r); width: 100%; }
.wrap.is-narrow { max-width: 860px; }
.hit-section { padding-block: var(--section-y); }
.hit-section.is-tight-top { padding-top: 0; }
.hit .wrap > * + * { margin-block-start: 1.25rem; }
.hit .wrap > .marker + * { margin-block-start: 0.6rem; }
.stack { display: grid; gap: 18px; align-content: start; }
.hit .stack > * { margin-block: 0; }
.grid-2, .grid-3, .grid-4 { display: grid; gap: 24px; }
.grid-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
@media (max-width: 960px) { .grid-3, .grid-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 640px) { .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; } }
.hit .grid-2, .hit .grid-3, .hit .grid-4, .hit .doors, .hit .tiles, .hit .voices, .hit .people { margin-block-start: 32px; }

/* Section colour bands */
.is-mist { background: var(--mist); }
.is-navy { background: var(--navy); color: #fff; }
.is-navy :is(h1, h2, h3, h4) { color: #fff; }
.is-navy .lead, .is-navy .meta { color: var(--on-navy-2); }
.is-navy a:not(.wp-block-button__link) { color: #fff; }
.is-blue { background: var(--hit-blue); color: #fff; }
.is-blue :is(h2, h3) { color: #fff; }
.is-blue p { color: #EEF3FC; }
.is-blue a:not(.wp-block-button__link) { color: #fff; }
.is-yellow { background: var(--hit-yellow); }
:root.hc :is(.is-navy, .is-blue) { background: #000; }

/* ---------- Type helpers ---------- */
.lead { font-size: var(--s1); color: var(--ink-2); }
.meta { font-size: var(--s-1); color: var(--ink-2); }
.big-statement { font-family: var(--hit-font-display); font-weight: 700; font-size: clamp(1.6rem, 1.1rem + 1.8vw, 2.4rem); line-height: 1.3; max-width: 30ch; color: var(--ink); }
.big-statement mark, .highlight { background: none; color: var(--hit-blue-d); box-shadow: inset 0 -0.3em 0 rgba(245, 213, 71, .65); }
:root.hc .big-statement mark { box-shadow: none; text-decoration: underline; }

/* Section marker: mini logo ring + label — the recurring Living Archive motif */
.marker {
  display: inline-flex; align-items: center; gap: 10px;
  font-family: var(--hit-font-display); font-weight: 700; font-size: var(--s-1);
  letter-spacing: 0.08em; text-transform: uppercase; color: var(--hit-red);
}
.marker::before { content: ""; width: 28px; height: 28px; flex: none; background: url("../images/ring.svg") center / contain no-repeat; }
.is-navy .marker, .is-blue .marker { color: var(--hit-yellow); }
.is-blue .marker { color: #fff; }

/* ---------- Buttons (core/button with registered block styles) ---------- */
.wp-block-buttons { display: flex; flex-wrap: wrap; gap: 12px; }
.hit .wp-block-buttons > * { margin: 0; }
.wp-block-button__link, .hit-btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 52px; padding: 12px 26px; border-radius: 999px;
  font-family: var(--hit-font-display); font-weight: 700; font-size: var(--s0); line-height: 1.2;
  text-decoration: none; border: 2px solid transparent; cursor: pointer; white-space: nowrap;
  background: var(--hit-blue); color: #fff;
}
.wp-block-button__link:hover, .hit-btn:hover { background: var(--navy); color: #fff; text-decoration: underline; }
.is-style-hit-gold .wp-block-button__link, .hit-btn.is-gold { background: var(--hit-gold); color: var(--ink); }
.is-style-hit-gold .wp-block-button__link:hover, .hit-btn.is-gold:hover { background: var(--hit-yellow); color: var(--ink); }
.is-style-hit-outline .wp-block-button__link, .hit-btn.is-outline { background: transparent; color: var(--ink); border-color: var(--ink); }
.is-style-hit-outline .wp-block-button__link:hover, .hit-btn.is-outline:hover { background: var(--ink); color: #fff; }
:is(.is-navy, .is-blue) .is-style-hit-outline .wp-block-button__link { color: #fff; border-color: #fff; }
:is(.is-navy, .is-blue) .is-style-hit-outline .wp-block-button__link:hover { background: #fff; color: var(--navy); }
:root.hc .wp-block-button__link { background: #000; color: #fff; border-color: #fff; }
:root.hc .is-style-hit-gold .wp-block-button__link { background: #FFE600; color: #000; }
@media (max-width: 420px) { .wp-block-button__link { white-space: normal; text-align: center; } }

.arrow-link { font-weight: 700; }
.arrow-link a::after, a.arrow-link::after { content: " \2192"; }

/* ---------- Brand bar + header ---------- */
.brandbar { background: var(--hit-blue); color: #fff; font-size: var(--s-1); }
.brandbar__row { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 6px 18px; padding-block: 6px; }
.brandbar a, .brandbar button { color: #fff; }
.brandbar__contact { display: flex; flex-wrap: wrap; gap: 4px 20px; align-items: center; list-style: none; margin: 0; padding: 0; }
.brandbar__actions { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; }
.brandbar .settings-btn {
  display: inline-flex; gap: 8px; align-items: center; min-height: 40px; padding: 4px 14px;
  border-radius: 999px; border: 1.5px solid #fff; background: none; font: inherit; font-weight: 700; cursor: pointer;
}
.brandbar .settings-btn svg { width: 18px; height: 18px; }
.brandbar .donate { min-height: 40px; padding: 6px 20px; font-size: 1rem; background: var(--hit-gold); color: var(--ink); }
.brandbar .donate:hover { background: var(--hit-yellow); color: var(--ink); }
@media (max-width: 640px) { .brandbar .hide-sm { display: none; } }

.site-header { background: #fff; border-bottom: 1px solid var(--line); position: relative; z-index: 20; }
.header-row { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 88px; }
.site-header .wp-block-site-logo img, .site-header .wp-block-site-logo a { width: 72px; height: auto; display: block; }
.site-header .header-cta { margin-left: auto; }
@media (min-width: 1100px) { .site-header .header-cta { margin-left: 0; } }
@media (max-width: 520px) { .site-header .header-cta { display: none; } .site-header .wp-block-site-logo img { width: 60px; } }

/* Core navigation block, restyled. Below 1100px we force the accessible
   overlay (hamburger) mode that core normally only uses below 600px. */
.main-nav .wp-block-navigation__container { gap: 2px; }
.main-nav .wp-block-navigation-item__content { display: block; padding: 10px 12px; font-weight: 700; color: var(--ink); text-decoration: none; border-radius: 8px; font-size: 1rem; white-space: nowrap; }
.main-nav .wp-block-navigation-item__content:hover { background: var(--mist); text-decoration: underline; }
.main-nav .current-menu-item > .wp-block-navigation-item__content,
.main-nav [aria-current="page"] { box-shadow: inset 0 -3px 0 var(--hit-red); border-radius: 0; }
.main-nav .wp-block-navigation__responsive-container-open,
.main-nav .wp-block-navigation__responsive-container-close {
  min-width: 48px; min-height: 48px; border: 2px solid var(--ink); border-radius: 999px; color: var(--ink); background: #fff;
  align-items: center; justify-content: center; gap: 6px; padding: 8px 14px; font-weight: 700;
}
.main-nav .wp-block-navigation__responsive-container-open::after { content: "Menu"; }
@media (max-width: 1099px) {
  .main-nav .wp-block-navigation__responsive-container-open:not(.always-shown) { display: inline-flex !important; }
  .main-nav .wp-block-navigation__responsive-container:not(.hidden-by-default):not(.is-menu-open) { display: none !important; }
}
.main-nav .wp-block-navigation__responsive-container.is-menu-open { background: #fff; padding: 24px var(--gutter-r) 24px var(--gutter-l); }
.main-nav .is-menu-open .wp-block-navigation__container { gap: 0; width: 100%; }
.main-nav .is-menu-open .wp-block-navigation-item { width: 100%; border-bottom: 1px solid var(--line); }
.main-nav .is-menu-open .wp-block-navigation-item__content { font-size: var(--s1); padding: 14px 6px; }

/* ---------- Page hero (all cornerstone pages) ---------- */
.page-hero { position: relative; overflow: hidden; padding-block: clamp(40px, 6vw, 88px) clamp(40px, 6vw, 72px); }
.page-hero::after {   /* logo ring motif, decorative */
  content: ""; position: absolute; right: -10%; top: -30%; width: min(640px, 70vw); aspect-ratio: 1;
  background: url("../images/ring.svg") center / contain no-repeat; pointer-events: none; z-index: 0;
}
.page-hero > * { position: relative; z-index: 1; }
@media (max-width: 1100px) { .page-hero::after { display: none; } }
:root.hc .page-hero::after { display: none; }
.page-hero__grid { display: grid; grid-template-columns: 1.15fr 0.85fr; gap: clamp(28px, 5vw, 64px); align-items: center; }
@media (max-width: 900px) { .page-hero__grid { grid-template-columns: 1fr; } }
.page-hero h1 { font-size: var(--s4); max-width: 18ch; }
.page-hero.is-home h1 { font-size: var(--s5); line-height: 1; letter-spacing: -0.02em; max-width: 16ch; }
.page-hero h1 mark { background: none; color: var(--hit-blue-d); }
.page-hero .tagline { font-family: var(--hit-font-display); font-weight: 700; font-size: var(--s1); color: var(--hit-red); }
.page-hero .hero-media { margin: 0; border-radius: 22px; overflow: hidden; aspect-ratio: 4 / 3; }
.page-hero .hero-media img { width: 100%; height: 100%; object-fit: cover; display: block; }
.hero-ctas { display: flex; flex-wrap: wrap; gap: 12px; }
.on-this-page { display: flex; flex-wrap: wrap; gap: 8px 18px; list-style: none; padding: 0; margin: 0; font-weight: 700; font-size: var(--s-1); }

/* ---------- Mosaic (home) ---------- */
.mosaic { display: grid; grid-template-columns: 1.2fr 1fr 1fr 1.4fr; grid-template-rows: 200px 200px; gap: 12px; margin-top: 40px !important; }
.mosaic > figure { margin: 0; border-radius: var(--r); overflow: hidden; background: var(--mist); }
.mosaic > figure:nth-child(1), .mosaic > figure:nth-child(4) { grid-row: span 2; }
.mosaic img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 30%; display: block; }
@media (max-width: 860px) {
  .mosaic { grid-template-columns: 1fr 1fr; grid-template-rows: 220px 160px 160px; }
  .mosaic > figure:nth-child(4) { grid-row: auto; }
  .mosaic > figure:nth-child(n+5) { display: none; }
}

/* ---------- Cards, doors, tiles ---------- */
.card { position: relative; display: grid; gap: 12px; align-content: start; padding: 26px; border-radius: 20px; border: 2px solid var(--line); background: #fff; }
.hit .card > * { margin-block: 0; }
.card .card-media { margin: -26px -26px 4px; border-radius: 18px 18px 0 0; overflow: hidden; aspect-ratio: 3 / 2; }
.card .card-media img { width: 100%; height: 100%; object-fit: cover; display: block; }
.card ul { margin: 0; padding-left: 1.2em; color: var(--ink-2); }
.card .wp-block-buttons { margin-top: auto; }
/* Doors: coloured bar picks up the logo's three colours */
.door::before { content: ""; height: 8px; width: 64px; border-radius: 8px; background: var(--c, var(--hit-blue)); }
.door:nth-child(3n+2) { --c: var(--hit-red); }
.door:nth-child(3n+3) { --c: var(--hit-yellow); }
.door h3 { font-size: var(--s2); }
.card:hover { border-color: var(--hit-blue); }
/* Whole-card link pattern: the heading link stretches over the card */
.card.is-linked h3 a { color: var(--ink); text-decoration: none; }
.card.is-linked h3 a::after { content: ""; position: absolute; inset: 0; border-radius: 20px; }
.card.is-linked h3 a:focus-visible { outline: none; box-shadow: none; }
.card.is-linked:has(a:focus-visible) { outline: 3px solid var(--focus); outline-offset: 3px; }
.card.is-linked .more { font-weight: 700; color: var(--hit-blue-d); text-decoration: underline; text-underline-offset: .2em; }
.is-navy .card { background: rgba(255,255,255,.04); border-color: rgba(255,255,255,.3); }
.is-navy .card ul { color: var(--on-navy-2); }

.tile { display: grid; gap: 10px; align-content: start; padding: 24px; border-radius: var(--r); background: #fff; border-top: 6px solid var(--c, var(--hit-blue)); }
.hit .tile > * { margin-block: 0; }
.tile:nth-child(4n+2) { --c: var(--hit-red); }
.tile:nth-child(4n+3) { --c: var(--hit-yellow); }
.tile:nth-child(4n+4) { --c: var(--hit-violet); }
.tile p { color: var(--ink-2); }
.is-mist .tile { border-left: 1px solid var(--line); border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); }

/* Labels / chips */
.chip-list { display: flex; flex-wrap: wrap; gap: 8px; list-style: none; padding: 0 !important; margin: 0; }
.chip-list li { padding: 6px 14px; border-radius: 999px; background: var(--mist); font-weight: 700; color: var(--ink); max-width: none; }
.is-mist .chip-list li { background: #fff; border: 1px solid var(--line); }
.is-navy .chip-list li { background: transparent; border: 1.5px solid rgba(255,255,255,.6); color: #fff; }
.pill { display: inline-block; font-size: 0.95rem; font-weight: 700; padding: 3px 12px; border-radius: 999px; background: var(--hit-yellow); color: var(--navy); }

/* ---------- Split (text + media) and alternating features ---------- */
.split { display: grid; grid-template-columns: 1.05fr 0.95fr; gap: clamp(24px, 5vw, 64px); align-items: center; }
.split.is-reversed > :first-child { order: 2; }
.split.is-top { align-items: start; }
@media (max-width: 900px) { .split { grid-template-columns: 1fr; } .split.is-reversed > :first-child { order: 0; } }
.split + .split { margin-top: clamp(48px, 7vw, 96px) !important; }
.media-frame { margin: 0; border-radius: 22px; overflow: hidden; aspect-ratio: 16 / 10; background: var(--navy); }
.media-frame img { width: 100%; height: 100%; object-fit: cover; display: block; }
.split h2, .split h3.is-large { font-size: var(--s3); font-weight: 800; }

/* ---------- Steps (a real sequence) ---------- */
.steps { list-style: none; counter-reset: step; padding: 0 !important; display: grid; grid-template-columns: repeat(4, minmax(0,1fr)); gap: 20px; margin-top: 32px !important; }
@media (max-width: 960px) { .steps { grid-template-columns: repeat(2, minmax(0,1fr)); } }
@media (max-width: 560px) { .steps { grid-template-columns: 1fr; } }
.steps li { counter-increment: step; position: relative; padding: 64px 22px 22px; border-radius: var(--r); background: #fff; border: 2px solid var(--line); max-width: none; }
.steps li::before { content: counter(step); position: absolute; left: 22px; top: 18px; width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center; background: var(--hit-blue); color: #fff; font-family: var(--hit-font-display); font-weight: 800; }
.steps li strong { display: block; font-family: var(--hit-font-display); font-size: var(--s1); margin-bottom: 6px; }

/* ---------- Tables (schedules) ---------- */
.hit-table { margin: 24px 0 0; overflow-x: auto; }
.hit-table table { width: 100%; border-collapse: collapse; min-width: 560px; font-size: var(--s0); }
.hit-table th, .hit-table td { text-align: left; padding: 14px 16px; border-bottom: 1px solid var(--line); vertical-align: top; }
.hit-table thead th { background: var(--navy); color: #fff; font-family: var(--hit-font-display); font-weight: 700; }
.hit-table thead th:first-child { border-radius: 12px 0 0 0; } .hit-table thead th:last-child { border-radius: 0 12px 0 0; }
.hit-table tbody tr:nth-child(even) td { background: var(--mist); }
.hit-table figcaption { margin-top: 10px; color: var(--ink-2); font-size: var(--s-1); }
:root.hc .hit-table thead th { background: #000; }

/* ---------- Quotes / voices ---------- */
.voices { display: grid; grid-template-columns: repeat(3, minmax(0,1fr)); gap: 20px; }
@media (max-width: 900px) { .voices { grid-template-columns: 1fr; } }
.wp-block-quote.voice { margin: 0; padding: 26px; border-radius: 20px; background: #fff; border: 2px solid var(--line); display: grid; gap: 14px; align-content: start; }
.wp-block-quote.voice:first-child { background: var(--hit-yellow); border-color: var(--hit-yellow); }
.wp-block-quote.voice p { font-family: var(--hit-font-display); font-weight: 700; font-size: var(--s1); line-height: 1.35; margin: 0; }
.wp-block-quote.voice p::before { content: "\201C"; } .wp-block-quote.voice p::after { content: "\201D"; }
.wp-block-quote.voice cite { font-style: normal; font-size: var(--s-1); color: var(--ink); }
.wp-block-quote.voice cite small { display: block; color: var(--ink-2); margin-top: 4px; }
.wp-block-quote.pull { margin: 0; border: 0; padding: 0; }
.wp-block-quote.pull p { font-family: var(--hit-font-display); font-weight: 700; font-size: var(--s2); line-height: 1.3; }
.wp-block-quote.pull p::before { content: "\201C"; color: var(--hit-red); } .wp-block-quote.pull p::after { content: "\201D"; color: var(--hit-red); }
.wp-block-quote.pull cite { font-style: normal; color: var(--ink-2); font-size: var(--s-1); }

/* ---------- Stats ---------- */
.stats { list-style: none; padding: 0 !important; display: grid; grid-template-columns: repeat(4, minmax(0,1fr)); gap: 1px; background: var(--line); border-radius: var(--r); overflow: hidden; margin-top: 32px !important; }
@media (max-width: 860px) { .stats { grid-template-columns: repeat(2, minmax(0,1fr)); } }
.stats li { background: #fff; padding: 24px 20px; max-width: none; }
.stats strong { display: block; font-family: var(--hit-font-display); font-weight: 800; font-size: clamp(2rem, 1.5rem + 2vw, 2.8rem); line-height: 1; color: var(--hit-blue-d); font-variant-numeric: tabular-nums; margin-bottom: 6px; }
.stats li:nth-child(2) strong { color: var(--hit-red); }
.stats li:nth-child(3) strong { color: #7C3AA8; }

/* ---------- FAQs (core/details: native, keyboard and screen-reader friendly) ---------- */
.faq { display: grid; gap: 12px; margin-top: 28px !important; max-width: 860px; }
.hit .faq > * { margin-block: 0; }
.wp-block-details { border: 2px solid var(--line); border-radius: 14px; padding: 0 20px; background: #fff; }
.wp-block-details summary { cursor: pointer; font-weight: 700; font-size: var(--s0); min-height: 56px; display: flex; align-items: center; gap: 12px; list-style: none; padding-block: 12px; }
.wp-block-details summary::-webkit-details-marker { display: none; }
.wp-block-details summary::before { content: "+"; flex: none; width: 28px; height: 28px; border-radius: 50%; display: grid; place-items: center; background: var(--mist); font-weight: 800; }
.wp-block-details[open] summary::before { content: "\2212"; }
.wp-block-details > :not(summary) { padding-bottom: 16px; color: var(--ink-2); }

/* ---------- People ---------- */
.people { display: grid; grid-template-columns: repeat(4, minmax(0,1fr)); gap: 20px; }
@media (max-width: 960px) { .people { grid-template-columns: repeat(2, minmax(0,1fr)); } }
.person { display: grid; gap: 6px; align-content: start; }
.hit .person > * { margin-block: 0; }
.person figure { margin: 0 0 8px; border-radius: 50%; overflow: hidden; aspect-ratio: 1; max-width: 180px; background: var(--mist); }
.person figure img { width: 100%; height: 100%; object-fit: cover; }

/* ---------- Badges (trust) ---------- */
.badges { display: flex; flex-wrap: wrap; gap: 10px; list-style: none; padding: 0 !important; }
.badges li { padding: 8px 14px; border: 1.5px solid currentColor; border-radius: 10px; font-weight: 700; font-size: var(--s-1); max-width: none; }

/* ---------- CTA band ---------- */
.cta-band { border-radius: 24px; padding: clamp(28px, 4vw, 52px); display: grid; grid-template-columns: 1fr auto; gap: 24px; align-items: center; }
@media (max-width: 760px) { .cta-band { grid-template-columns: 1fr; } }
.hit .cta-band > * { margin-block: 0; }

/* ---------- Project archive (query loop of hit_project posts) ---------- */
.archive-query .wp-block-post-template { list-style: none; padding: 0; margin: 28px 0 0; display: grid; grid-template-columns: repeat(3, minmax(0,1fr)); gap: 32px 24px; }
@media (max-width: 960px) { .archive-query .wp-block-post-template { grid-template-columns: repeat(2, minmax(0,1fr)); } }
@media (max-width: 600px) { .archive-query .wp-block-post-template { grid-template-columns: 1fr; } }
.hit .archive-query .wp-block-post-template > * { margin-block: 0; }
.archive-query .wp-block-post { position: relative; display: grid; gap: 10px; align-content: start; max-width: none; }
.hit .archive-query .wp-block-post > * { margin-block: 0; }
.archive-query .wp-block-post-featured-image { margin: 0; border-radius: var(--r); overflow: hidden; aspect-ratio: 4 / 3; }
.archive-query .wp-block-post-featured-image img { width: 100%; height: 100%; object-fit: cover; }
.archive-query .wp-block-post-title { font-size: var(--s1); }
.archive-query .wp-block-post-title a { text-decoration: none; color: inherit; }
.archive-query .wp-block-post-title a::after { content: ""; position: absolute; inset: 0; }  /* whole card clickable */
.archive-query .wp-block-post-title a:hover { text-decoration: underline; }
.archive-query .wp-block-post:has(.wp-block-post-title a:focus-visible) { outline: 3px solid var(--focus); outline-offset: 6px; border-radius: var(--r); }
.archive-query .wp-block-post-title a:focus-visible { outline: none; box-shadow: none; }
.is-navy .archive-query .wp-block-post:has(.wp-block-post-title a:focus-visible) { outline-color: var(--hit-yellow); }
.archive-query .wp-block-post-terms { display: flex; flex-wrap: wrap; gap: 6px; font-size: 0.95rem; font-weight: 700; }
.archive-query .wp-block-post-terms a { position: relative; z-index: 1; padding: 2px 10px; border-radius: 999px; border: 1.5px solid currentColor; text-decoration: none; }
.archive-query .wp-block-post-terms .wp-block-post-terms__separator { display: none; }
.archive-query .wp-block-post-excerpt { margin: 0; }
.archive-query .wp-block-post-excerpt__excerpt { color: var(--ink-2); font-size: var(--s-1); }
.is-navy .archive-query .wp-block-post-excerpt__excerpt { color: var(--on-navy-2); }
.archive-query .wp-block-query-pagination { margin-top: 32px; gap: 12px; font-weight: 700; }
.type-filter { display: flex; flex-wrap: wrap; gap: 8px; list-style: none; padding: 0 !important; margin: 28px 0 0 !important; }
.type-filter li { max-width: none; }
.type-filter a { display: inline-flex; align-items: center; min-height: 48px; padding: 8px 18px; border-radius: 999px; border: 2px solid currentColor; font-weight: 700; text-decoration: none; }
.type-filter a[aria-current="page"], .type-filter li.is-current a { background: var(--hit-yellow); color: var(--navy); border-color: var(--hit-yellow); }

/* Single project */
.project-meta { display: flex; flex-wrap: wrap; gap: 8px 20px; color: var(--ink-2); font-weight: 700; }
.prose { max-width: 760px; }
.prose > * + * { margin-block-start: 1.1em !important; }
.prose h2 { font-size: var(--s2); margin-top: 1.6em !important; }
.prose ul, .prose ol { padding-left: 1.3em; }

/* ---------- Forms (enquiry + newsletter, rendered by the HIT Core plugin) ---------- */
.hit-form { background: #fff; color: var(--ink); border-radius: 24px; padding: clamp(22px, 3.5vw, 40px); display: grid; gap: 18px; }
.is-mist .hit-form { border: 2px solid var(--line); }
.hit-form fieldset { border: 0; padding: 0; margin: 0; display: grid; gap: 12px; min-width: 0; }
.hit-form legend { font-family: var(--hit-font-display); font-weight: 800; font-size: var(--s2); color: var(--ink); margin-bottom: 12px; padding: 0; }
.hit-form .field { display: grid; gap: 6px; min-width: 0; }
.hit-form label, .hit-form .label { font-weight: 700; }
.hit-form .hint { font-size: var(--s-1); color: var(--ink-2); }
.hit-form input[type="text"], .hit-form input[type="email"], .hit-form input[type="tel"], .hit-form select, .hit-form textarea {
  font: inherit; letter-spacing: inherit; color: var(--ink); background: #fff;
  border: 2px solid var(--field); border-radius: 10px; min-height: 52px; padding: 10px 14px; width: 100%;
}
.hit-form textarea { min-height: 120px; resize: vertical; }
.hit-form [aria-invalid="true"] { border-color: var(--error); }
.hit-form .choice { display: flex; align-items: center; gap: 12px; min-height: 56px; padding: 10px 16px; border: 2px solid var(--field); border-radius: 12px; cursor: pointer; font-weight: 700; }
.hit-form .choice:has(input:checked) { border-color: var(--hit-blue); background: var(--mist); box-shadow: inset 0 0 0 2px var(--hit-blue); }
.hit-form .choice input, .hit-form .check input { width: 22px; height: 22px; accent-color: var(--hit-blue); flex: none; }
.hit-form .check { display: flex; align-items: flex-start; gap: 12px; font-weight: 400; }
.hit-form .err { color: var(--error); font-weight: 700; font-size: var(--s-1); }
.hit-form .form-status { font-weight: 700; padding: 14px 16px; border-radius: 12px; }
.hit-form .form-status.is-ok { background: #E6F4EA; color: var(--ok); }
.hit-form .form-status.is-error { background: #FCE8EA; color: var(--error); }
.hit-form .progress { display: flex; gap: 8px; list-style: none; padding: 0; margin: 0; }
.hit-form .progress li { flex: 1; height: 8px; border-radius: 8px; background: var(--line); max-width: none; }
.hit-form .progress li.is-done { background: var(--hit-blue); }
.hit-form .step-label { font-weight: 700; color: var(--ink-2); }
.hit-form .step-nav { display: flex; flex-wrap: wrap; gap: 10px; }
.hit-form .hp { position: absolute; left: -9999px; }   /* spam honeypot, hidden from everyone */
.hit-form.is-inline { grid-template-columns: 1fr auto; align-items: end; padding: 0; background: transparent; border: 0; }
@media (max-width: 520px) { .hit-form.is-inline { grid-template-columns: 1fr; } }

/* ---------- Footer ---------- */
.site-footer { background: var(--navy); color: #fff; padding-block: 56px 32px; }
.site-footer a { color: #fff; }
.site-footer h2 { font-size: var(--s0); color: #fff; margin-bottom: 10px !important; }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: 32px; }
@media (max-width: 900px) { .footer-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 520px) { .footer-grid { grid-template-columns: 1fr; } }
.site-footer ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 8px; }
.site-footer .meta, .site-footer p { color: var(--on-navy-2); }
.site-footer .badges { color: #fff; margin-top: 32px !important; }
.footer-legal { margin-top: 28px !important; padding-top: 18px; border-top: 1px solid rgba(255,255,255,.3); display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px 24px; font-size: var(--s-1); }
.hit .footer-legal > * { margin: 0; }
:root.hc .site-footer { background: #000; }

/* ---------- Display settings dialog ---------- */
dialog.hit-settings { border: 2px solid var(--ink); border-radius: 18px; padding: 0; width: 100%; max-width: min(540px, calc(100vw - 32px)); background: #fff; color: var(--ink); font-family: var(--hit-font-body); }
dialog.hit-settings::backdrop { background: rgba(10, 16, 40, .6); }
.hit-settings__head { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 18px 24px; border-bottom: 1px solid var(--line); }
.hit-settings__head h2 { font-size: var(--s1); }
.hit-settings__body { padding: 20px 24px; display: grid; gap: 18px; }
.hit-settings fieldset { border: 0; padding: 0; margin: 0; display: grid; gap: 8px; }
.hit-settings legend { font-weight: 700; margin-bottom: 6px; }
.hit-settings .seg { display: flex; flex-wrap: wrap; gap: 8px; }
.hit-settings label { display: flex; align-items: center; gap: 10px; min-height: 48px; padding: 8px 14px; border: 2px solid var(--field); border-radius: 10px; cursor: pointer; }
.hit-settings input { width: 22px; height: 22px; accent-color: var(--hit-blue); }
.hit-settings .close { min-width: 48px; min-height: 48px; border-radius: 50%; border: 2px solid var(--ink); background: #fff; color: var(--ink); font: inherit; font-weight: 700; cursor: pointer; }
.hit-settings .reset { justify-self: start; }

/* ---------- Motion ---------- */
@media (prefers-reduced-motion: no-preference) {
  :root:not(.reduce-motion) .wp-block-button__link, :root:not(.reduce-motion) .card, :root:not(.reduce-motion) .hit-form .choice { transition: background-color .2s, border-color .2s, color .2s; }
}
:root.reduce-motion *, :root.reduce-motion *::before, :root.reduce-motion *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }

/* Card variants */
.card.is-blue { background: var(--hit-blue); border-color: var(--hit-blue); color: #fff; }
.card.is-blue :is(h2, h3) { color: #fff; }
.card.is-blue .marker { color: #fff; }
.card.is-navy { background: var(--navy); border-color: var(--navy); }
:root.hc .card.is-blue { background: #000; }
.hit-table table { table-layout: auto; }

/* Fixes: hidden attribute must always win over component display rules */
[hidden] { display: none !important; }
.site-footer ul.badges { display: flex; }
.is-navy .hit-form a, .is-blue .hit-form a { color: var(--hit-blue-d); }

h2.is-small { font-size: var(--s1); font-weight: 700; line-height: 1.25; }
.archive-query h2.wp-block-post-title { font-size: var(--s1); }

/* Mobile/overlay menu: left-aligned, large targets */
.main-nav .is-menu-open .wp-block-navigation__responsive-container-content,
.main-nav .is-menu-open .wp-block-navigation__container { align-items: flex-start !important; }
.main-nav .is-menu-open .wp-block-navigation-item { justify-content: flex-start; }

/* Larger text or wider fonts need more room: switch to the menu button earlier,
   and hide the decorative ring so it never sits behind enlarged headings. */
@media (max-width: 1599px) {
  :root:is(.text-lg, .text-xl, .readable, .dyslexic, .spacing) .main-nav .wp-block-navigation__responsive-container-open:not(.always-shown) { display: inline-flex !important; }
  :root:is(.text-lg, .text-xl, .readable, .dyslexic, .spacing) .main-nav .wp-block-navigation__responsive-container:not(.hidden-by-default):not(.is-menu-open) { display: none !important; }
}
:root:is(.text-lg, .text-xl, .readable, .dyslexic, .spacing) .page-hero::after { display: none; }
.page-hero .wrap.stack > p { max-width: 56ch; }

/* =====================================================================
   NEWS, POSTS AND COMMENTS (1.1.0)
   ===================================================================== */
/* "News" marker on a single post links back to the news page */
.marker.back-to-news a { color: inherit; text-decoration: none; }
.marker.back-to-news a:hover { text-decoration: underline; }
.page-hero.is-post h1 { max-width: 26ch; font-size: var(--s3); }
.post-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 0; font-size: var(--s-1); color: var(--ink-2); font-weight: 700; }
.hit .post-meta > * { margin: 0; }
.post-meta > :not(:first-child)::before { content: "·"; margin-inline: 10px; color: var(--ink-2); }
.post-meta > .post-meta__author::before { content: "By "; margin: 0 0.3em 0 0; }
.post-meta > .post-meta__author:not(:first-child)::before { content: "· By "; margin: 0 0.3em 0 10px; }
.post-meta a { color: var(--hit-blue-d); }

/* Featured image on a post: shown whole, never cropped */
.post-body > * { max-width: 860px; width: 100%; }
.post-image { margin: 0; }
.post-image img { width: 100%; height: auto; max-height: 560px; object-fit: contain; border-radius: 20px; background: var(--mist); display: block; }

/* Post content written in the editor (including older posts) */
.prose h3 { font-size: var(--s1); margin-top: 1.4em !important; }
.prose h4 { margin-top: 1.2em !important; }
.prose figure { margin-inline: 0; }
.prose img { border-radius: 12px; height: auto; }
.prose figcaption, .prose .wp-caption-text { font-size: var(--s-1); color: var(--ink-2); margin-top: 8px; }
.prose .wp-caption { max-width: 100%; }
.prose .alignleft { float: left; margin: 0.3em 1.5em 1em 0; max-width: 50%; }
.prose .alignright { float: right; margin: 0.3em 0 1em 1.5em; max-width: 50%; }
.prose .aligncenter { margin-inline: auto; display: block; }
.prose::after { content: ""; display: table; clear: both; }
@media (max-width: 600px) { .prose .alignleft, .prose .alignright { float: none; margin: 1em 0; max-width: 100%; } }
.prose blockquote:not(.voice):not(.pull) { margin-inline: 0; padding: 4px 0 4px 22px; border-left: 6px solid var(--hit-yellow); font-size: var(--s1); }
.prose blockquote cite { display: block; font-style: normal; font-size: var(--s-1); color: var(--ink-2); margin-top: 8px; }
.prose table { width: 100%; border-collapse: collapse; }
.prose th, .prose td { text-align: left; padding: 10px 12px; border-bottom: 1px solid var(--line); vertical-align: top; }
.prose .wp-block-table { overflow-x: auto; }
.prose .wp-block-gallery { gap: 12px; }
.prose .wp-block-embed iframe, .prose iframe { max-width: 100%; border: 0; border-radius: 12px; }
.prose code, .prose pre { font-size: 0.95em; background: var(--mist); border-radius: 6px; padding: 2px 6px; }
.prose pre { padding: 16px; overflow-x: auto; }
.prose hr { border: 0; border-top: 2px solid var(--line); }
.prose .wp-block-file { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; }
.prose .wp-block-file__button { display: inline-flex; min-height: 48px; align-items: center; padding: 8px 20px; border-radius: 999px; background: var(--hit-blue); color: #fff; text-decoration: none; font-weight: 700; }

/* Password-protected posts */
.post-password-form { display: grid; gap: 12px; max-width: 520px; }
.post-password-form p { display: grid; gap: 8px; }
.post-password-form label { font-weight: 700; display: grid; gap: 6px; }
.post-password-form input[type="password"] { font: inherit; min-height: 52px; padding: 10px 14px; border: 2px solid var(--field); border-radius: 10px; }
.post-password-form input[type="submit"] { justify-self: start; }

/* Tags and older/newer links */
.post-tags { font-weight: 700; display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.post-tags a { padding: 4px 12px; border-radius: 999px; border: 1.5px solid var(--line); text-decoration: none; font-weight: 700; }
.post-tags a:hover { border-color: var(--hit-blue); text-decoration: underline; }
.post-tags .wp-block-post-terms__separator { display: none; }
.post-nav { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; border-top: 2px solid var(--line); padding-top: 24px; }
.hit .post-nav > * { margin: 0; }
.post-nav__next { text-align: right; justify-self: end; }
.post-nav a { font-weight: 700; }
.post-nav .post-navigation-link__label { display: block; font-size: var(--s-1); color: var(--ink-2); font-weight: 400; }
@media (max-width: 600px) { .post-nav { grid-template-columns: 1fr; } .post-nav__next { text-align: left; justify-self: start; } }

/* News cards */
.news-query .card-meta { display: flex; flex-wrap: wrap; gap: 6px 12px; align-items: center; font-size: var(--s-1); color: var(--ink-2); font-weight: 700; }
.hit .news-query .card-meta > * { margin: 0; }
.news-query .card-meta .wp-block-post-terms a { position: relative; z-index: 1; }
.news-query .type-page .card-meta, .news-query .type-hit_project .wp-block-post-date { display: none; }
.is-navy .news-query .card-meta { color: var(--on-navy-2); }
.hero-search { max-width: 640px; }
.wp-block-search__inside-wrapper { gap: 8px; }
.wp-block-search__input { font: inherit; min-height: 52px; padding: 10px 14px; border: 2px solid var(--field) !important; border-radius: 10px; }
.wp-block-search__label { font-weight: 700; }
.wp-block-search__button { min-height: 52px; padding: 10px 22px; border-radius: 999px; background: var(--hit-blue); color: #fff; border: 0; font-family: var(--hit-font-display); font-weight: 700; cursor: pointer; margin-left: 0; }
.wp-block-term-description p { max-width: var(--measure); }

/* Comments: only approved comments are shown (WordPress > Comments to approve) */
.post-comments { border-top: 2px solid var(--line); padding-top: 32px; display: grid; gap: 20px; }
.hit .post-comments > * { margin: 0; }
.post-comments .wp-block-comments-title { font-size: var(--s2); }
.post-comments .wp-block-comment-template { list-style: none; padding: 0; margin: 0; display: grid; gap: 16px; }
.post-comments .wp-block-comment-template ol { list-style: none; padding-left: clamp(16px, 4vw, 40px); margin: 16px 0 0; display: grid; gap: 16px; }
.comment-card { padding: 20px 22px; border-radius: 16px; background: var(--mist); display: grid; gap: 10px; }
.hit .comment-card > * { margin: 0; }
.comment-head { display: flex; flex-wrap: wrap; gap: 4px 14px; align-items: baseline; }
.hit .comment-head > * { margin: 0; }
.comment-head .wp-block-comment-author-name { font-weight: 700; }
.comment-head .wp-block-comment-date { font-size: var(--s-1); color: var(--ink-2); }
.comment-card .wp-block-comment-content p + p { margin-top: .8em; }
.comment-card .wp-block-comment-content .comment-awaiting-moderation { display: block; font-weight: 700; color: var(--ink-2); margin-bottom: 8px; }
.comment-actions { display: flex; gap: 16px; font-weight: 700; font-size: var(--s-1); }
.hit .comment-actions > * { margin: 0; }
.comment-respond { display: grid; gap: 14px; }
.comment-respond .comment-reply-title { font-size: var(--s2); }
.comment-respond .comment-reply-title small { display: block; font-size: var(--s-1); margin-top: 6px; font-family: var(--hit-font-body); }
.comment-form { display: grid; gap: 16px; max-width: 760px; }
.comment-form p { margin: 0; display: grid; gap: 6px; max-width: none; }
.comment-form label { font-weight: 700; }
.comment-form input[type="text"], .comment-form input[type="email"], .comment-form input[type="url"], .comment-form textarea {
  font: inherit; letter-spacing: inherit; color: var(--ink); background: #fff; width: 100%;
  border: 2px solid var(--field); border-radius: 10px; min-height: 52px; padding: 10px 14px;
}
.comment-form textarea { min-height: 160px; resize: vertical; }
.comment-form .comment-form-cookies-consent { display: flex; gap: 12px; align-items: flex-start; }
.comment-form .comment-form-cookies-consent input { width: 22px; height: 22px; flex: none; accent-color: var(--hit-blue); margin-top: 3px; }
.comment-form .comment-form-cookies-consent label { font-weight: 400; }
.comment-form .comment-notes, .comment-form .logged-in-as { color: var(--ink-2); font-size: var(--s-1); }
.comment-form .form-submit { display: block; }
.comment-pending { font-weight: 700; padding: 14px 16px; border-radius: 12px; background: #E6F4EA; color: var(--ok); }
.wp-block-comments-pagination { gap: 12px; font-weight: 700; }
:root.hc .comment-card { background: #fff; border: 2px solid #000; }

/* Latest news section on the homepage */
.news-latest .wp-block-post-template { margin-top: 28px; }
.cta-band.is-plain { padding: 0; }

/* News cards without a featured image get a branded panel, so the grid stays even */
.news-query .wp-block-post:not(:has(.wp-block-post-featured-image))::before {
  content: ""; display: block; aspect-ratio: 4 / 3; border-radius: var(--r);
  background: var(--mist) url("../images/ring.svg") center / 38% no-repeat;
}
.is-navy .news-query .wp-block-post:not(:has(.wp-block-post-featured-image))::before { background-color: rgba(255,255,255,.08); }
/* "Uncategorised" is WordPress's default bucket, not a useful label */
.wp-block-post-terms a[href*="/category/uncategorized/"], .wp-block-post-terms a[href*="/category/uncategorised/"] { display: none; }
.wp-block-post-terms:has(> a[href*="/category/uncategori"]:only-of-type) { display: none; }
/* Pagination: large, clear targets */
.wp-block-query-pagination { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; font-weight: 700; }
.wp-block-query-pagination-numbers { display: flex; flex-wrap: wrap; gap: 8px; }
.wp-block-query-pagination .page-numbers, .wp-block-query-pagination-previous, .wp-block-query-pagination-next {
  display: inline-flex; align-items: center; justify-content: center; min-width: 48px; min-height: 48px; padding: 8px 16px;
  border-radius: 999px; border: 2px solid var(--line); text-decoration: none; color: var(--ink);
}
.wp-block-query-pagination .page-numbers.current { background: var(--navy); border-color: var(--navy); color: #fff; }
.wp-block-query-pagination .page-numbers.dots { border-color: transparent; }
.wp-block-query-pagination a:hover { border-color: var(--hit-blue); text-decoration: underline; }
.is-navy .wp-block-query-pagination a { color: #fff; }
/* Galleries from older posts ([gallery] shortcode) */
.prose .gallery { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.prose .gallery-columns-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.prose .gallery-columns-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.prose .gallery-item { margin: 0; }
.prose .gallery-item img { width: 100%; height: auto; aspect-ratio: 1; object-fit: cover; }
.prose .gallery br { display: none; }
@media (max-width: 600px) { .prose .gallery { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

/* Older pages built with Elementor: use HIT's accessible colours and fonts instead of
   Elementor's defaults (its default light blue and grey text fail WCAG contrast). */
.hit .elementor {
  --e-global-color-primary: var(--ink); --e-global-color-secondary: var(--ink-2);
  --e-global-color-text: var(--ink); --e-global-color-accent: var(--hit-blue-d);
  --e-global-typography-primary-font-family: var(--hit-font-display); --e-global-typography-secondary-font-family: var(--hit-font-display);
  --e-global-typography-text-font-family: var(--hit-font-body); --e-global-typography-accent-font-family: var(--hit-font-body);
  font-family: var(--hit-font-body);
}
.hit .elementor .elementor-heading-title { font-family: var(--hit-font-display); }
/* Block editor only: keep menu labels and the header button on one line in the narrower editing canvas */
.editor-styles-wrapper .main-nav .wp-block-navigation-item__content,
.editor-styles-wrapper .main-nav [contenteditable],
.editor-styles-wrapper .header-cta .wp-block-button__link,
.editor-styles-wrapper .header-cta [contenteditable] { white-space: nowrap !important; }
.editor-styles-wrapper .main-nav .wp-block-navigation__container { flex-wrap: nowrap; }
.page-hero.is-post::after { display: none; }   /* long post titles must never sit over the decorative ring */
