/* =====================================================================
   Community Energy Greater Manchester — landing page styles
   Page: carbon.coop/community-energy/ (GeneratePress + core blocks)

   Everything is scoped to .cegm, the outer Group block on the page, so
   nothing leaks into the rest of carbon.coop. Tokens are prefixed
   --cegm- because GeneratePress already defines --accent, --base and
   --contrast, and the brand's own --accent would collide with them.

   Source of truth: the CEGM design system (tokens.json). When a token
   changes there, change it here and in the MailWizz template.
   ===================================================================== */

/* @font-face:start  — self-hosted Atkinson Hyperlegible (SIL OFL).
   Put the four woff2 files in /cegm/fonts/ next to this file. */
@font-face { font-family: "Atkinson Hyperlegible"; src: url("fonts/AtkinsonHyperlegible-Regular.woff2") format("woff2"); font-weight: 400; font-style: normal; font-display: swap; }
@font-face { font-family: "Atkinson Hyperlegible"; src: url("fonts/AtkinsonHyperlegible-Bold.woff2") format("woff2"); font-weight: 700; font-style: normal; font-display: swap; }
@font-face { font-family: "Atkinson Hyperlegible"; src: url("fonts/AtkinsonHyperlegible-Italic.woff2") format("woff2"); font-weight: 400; font-style: italic; font-display: swap; }
@font-face { font-family: "Atkinson Hyperlegible"; src: url("fonts/AtkinsonHyperlegible-BoldItalic.woff2") format("woff2"); font-weight: 700; font-style: italic; font-display: swap; }
/* @font-face:end */

/* ---------- Tokens ---------- */
.cegm {
  /* Palette */
  --cegm-navy-900: #1B2A4A;
  --cegm-navy-700: #3A4D78;
  --cegm-slate-600: #4A5873;
  --cegm-slate-300: #C3CCDB;
  --cegm-slate-200: #DDE2EA;
  --cegm-slate-050: #F3F5F8;
  --cegm-mist-200: #C9D3E3;
  --cegm-green-700: #166238;
  --cegm-green-600: #1E7A46;
  --cegm-lime-300: #A6E36B;
  --cegm-sky-300: #7CC4F0;
  --cegm-amber-200: #FFE08A;
  --cegm-white: #FFFFFF;

  /* Roles (light theme; carbon.coop has no dark mode) */
  --cegm-surface: var(--cegm-white);
  --cegm-surface-sunk: var(--cegm-slate-050);
  --cegm-surface-brand: var(--cegm-navy-900);
  --cegm-surface-brand-strong: var(--cegm-navy-900);
  --cegm-ink: var(--cegm-navy-900);
  --cegm-ink-muted: var(--cegm-slate-600);
  --cegm-ink-on-brand: var(--cegm-white);
  --cegm-ink-on-brand-muted: var(--cegm-mist-200);
  --cegm-accent: var(--cegm-lime-300);
  --cegm-accent-cool: var(--cegm-sky-300);
  --cegm-link: var(--cegm-green-600);
  --cegm-action: var(--cegm-green-600);
  --cegm-action-hover: var(--cegm-green-700);
  --cegm-on-action: var(--cegm-white);
  --cegm-rule: var(--cegm-slate-200);
  --cegm-border-control: #6B7A96;
  --cegm-focus: var(--cegm-navy-900);
  --cegm-focus-on-brand: var(--cegm-lime-300);
  --cegm-status-ink: var(--cegm-navy-900);

  /* Type, space, shape */
  --cegm-font: "Atkinson Hyperlegible", Arial, Helvetica, sans-serif;
  --cegm-space-1: 4px;
  --cegm-space-2: 8px;
  --cegm-space-3: 12px;
  --cegm-space-3-5: 14px;
  --cegm-space-4: 16px;
  --cegm-space-5: 20px;
  --cegm-space-6: 24px;
  --cegm-space-8: 32px;
  --cegm-space-12: 48px;
  --cegm-space-16: 64px;
  --cegm-space-24: 96px;
  --cegm-radius-xs: 2px;
  --cegm-radius-md: 8px;
  --cegm-radius-chip: 10px;
  --cegm-radius-lg: 12px;
  --cegm-width-page: 1120px;
  --cegm-gutter: var(--cegm-space-12);
  --cegm-section-gap: var(--cegm-space-24);
}

/* ---------- Base ---------- */
/* The site caps .entry-content at a reading width (765px) for blog posts.
   Lift that cap only on a page whose content is the network page. */
.site-main .entry-content:has(> .cegm) { max-width: none !important; width: 100%; margin-left: 0; margin-right: 0; padding-left: 0; padding-right: 0; }
.entry-content > .cegm.wp-block-group { margin: 0; }
.cegm {
  font-family: var(--cegm-font);
  font-size: 18px;
  line-height: 28px;
  color: var(--cegm-ink);
  background: var(--cegm-surface);
  -webkit-font-smoothing: antialiased;
  padding-bottom: var(--cegm-space-12);
}
.cegm *, .cegm *::before, .cegm *::after { box-sizing: border-box; }
/* Safety net: if WordPress still wraps a group in an inner container, take the
   wrapper out of the layout so flex and grid see the real children. */
.cegm .wp-block-group__inner-container { display: contents; }
.cegm .cegm-section { width: 100%; }
.cegm :where(p, h1, h2, h3, h4, ul, ol, figure) { margin: 0; }
.cegm :where(h1, h2, h3, h4) { font-family: var(--cegm-font); color: var(--cegm-ink); font-weight: 700; letter-spacing: 0; text-transform: none; text-wrap: balance; }
.cegm a { color: var(--cegm-link); text-decoration: underline; text-underline-offset: 2px; }
.cegm a:hover, .cegm a:focus { color: var(--cegm-link); text-decoration-thickness: 2px; }
.cegm :focus-visible { outline: 2px solid var(--cegm-focus); outline-offset: 2px; border-radius: 2px; }
.cegm img { max-width: 100%; height: auto; display: block; }
.cegm strong { font-weight: 700; }

/* ---------- Sections: the frame every block sits in ---------- */
.cegm .cegm-section {
  max-width: var(--cegm-width-page);
  margin: var(--cegm-section-gap) auto 0;
  padding: 0 var(--cegm-gutter);
}
.cegm .cegm-section > * + * { margin-top: var(--cegm-space-6); }

/* Section heading: sky bar, bold heading. The first paragraph straight
   after it is the intro line, set small and muted. */
.cegm h2.wp-block-heading { font-size: 28px; line-height: 34px; }
.cegm h2.wp-block-heading::before {
  content: ""; display: block; width: 32px; height: 4px;
  border-radius: var(--cegm-radius-xs); background: var(--cegm-accent-cool);
  margin-bottom: var(--cegm-space-3);
}
.cegm .cegm-section > h2 + p { margin-top: var(--cegm-space-1); font-size: 16px; line-height: 24px; color: var(--cegm-ink-muted); max-width: 68ch; }
.cegm h3.wp-block-heading { font-size: 21px; line-height: 28px; }
.cegm p + p { margin-top: var(--cegm-space-3-5); }
.cegm .cegm-section > p { max-width: 68ch; }

/* Paragraph styles (Styles panel in the editor) */
.cegm .is-style-cegm-lead { font-size: 20px; line-height: 30px; color: var(--cegm-ink); }
.cegm .is-style-cegm-meta { font-size: 16px; line-height: 24px; color: var(--cegm-ink-muted); }
.cegm .is-style-cegm-eyebrow { font-size: 14px; line-height: 20px; font-weight: 700; color: var(--cegm-ink-muted); }

/* ---------- Buttons ---------- */
.cegm .wp-block-buttons { display: flex; flex-wrap: wrap; gap: var(--cegm-space-3); }
.cegm .wp-block-button__link,
.cegm .nf-form-cont input[type="submit"],
.cegm .nf-form-cont input[type="button"] {
  display: inline-flex; align-items: center; justify-content: center; min-height: 46px;
  padding: 13px var(--cegm-space-6); border: 1px solid var(--cegm-action); border-radius: var(--cegm-radius-md);
  background: var(--cegm-action); color: var(--cegm-on-action);
  font: 700 16px/20px var(--cegm-font); text-decoration: none; cursor: pointer; width: auto;
}
.cegm .wp-block-button__link:hover,
.cegm .wp-block-button__link:focus,
.cegm .nf-form-cont input[type="submit"]:hover { background: var(--cegm-action-hover); border-color: var(--cegm-action-hover); color: var(--cegm-on-action); }
/* Core "Outline" style = secondary button */
.cegm .is-style-outline .wp-block-button__link { background: transparent; color: var(--cegm-ink); border-color: var(--cegm-border-control); }
.cegm .is-style-outline .wp-block-button__link:hover { background: var(--cegm-surface-sunk); border-color: var(--cegm-ink); color: var(--cegm-ink); }
/* "On navy" style, for buttons inside the navy band */
.cegm .is-style-cegm-on-brand .wp-block-button__link { background: var(--cegm-lime-300); border-color: var(--cegm-lime-300); color: var(--cegm-navy-900); }
.cegm .is-style-cegm-on-brand .wp-block-button__link:hover,
.cegm .is-style-cegm-on-brand .wp-block-button__link:focus { background: var(--cegm-white); border-color: var(--cegm-white); color: var(--cegm-navy-900); }

/* ---------- Status pills and notice tags (paragraph styles) ---------- */
.cegm .is-style-cegm-open, .cegm .is-style-cegm-soon, .cegm .is-style-cegm-expected,
.cegm .is-style-cegm-offer, .cegm .is-style-cegm-ask {
  display: inline-block; width: fit-content; padding: 2px 10px; border-radius: var(--cegm-radius-lg);
  border: 1px solid transparent; font: 700 13px/17px var(--cegm-font); white-space: nowrap;
}
.cegm .is-style-cegm-open { background: var(--cegm-action); color: var(--cegm-on-action); }
.cegm .is-style-cegm-soon { background: var(--cegm-amber-200); color: var(--cegm-status-ink); }
.cegm .is-style-cegm-expected { background: var(--cegm-slate-050); color: var(--cegm-status-ink); border-color: var(--cegm-slate-300); }
.cegm .is-style-cegm-offer { background: var(--cegm-action); color: var(--cegm-on-action); }
.cegm .is-style-cegm-ask { background: var(--cegm-surface-brand-strong); color: var(--cegm-ink-on-brand); }

/* ---------- Masthead band ---------- */
.cegm .cegm-s-masthead { margin-top: var(--cegm-space-8); }
.cegm .cegm-band {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: var(--cegm-space-5);
  background: var(--cegm-surface-brand); color: var(--cegm-ink-on-brand);
  border-radius: var(--cegm-radius-lg); padding: var(--cegm-space-8);
}
.cegm .cegm-band :focus-visible { outline-color: var(--cegm-focus-on-brand); }
.cegm .cegm-band__brand { display: flex; align-items: center; gap: var(--cegm-space-5); min-width: 0; }
.cegm .cegm-logo { flex: none; width: 112px; }
.cegm .cegm-logo img { width: 112px; height: auto; }
.cegm .cegm-band__name { min-width: 0; }
.cegm .cegm-wordmark { font-size: 32px; line-height: 36px; font-weight: 700; color: var(--cegm-ink-on-brand); }
.cegm .cegm-wordmark + .cegm-wordmark { margin-top: 0; color: var(--cegm-accent); }
.cegm .cegm-strapline { margin-top: var(--cegm-space-2) !important; font-size: 16px; line-height: 22px; color: var(--cegm-accent-cool); }
.cegm .cegm-band h2.wp-block-heading { color: var(--cegm-ink-on-brand); }
.cegm .cegm-band p { color: var(--cegm-ink-on-brand); }
.cegm .cegm-band a:not(.wp-block-button__link) { color: var(--cegm-ink-on-brand); }

/* ---------- Hero ---------- */
.cegm .cegm-s-hero { margin-top: var(--cegm-space-12); }
.cegm .wp-block-columns { display: flex; flex-wrap: nowrap; gap: var(--cegm-space-12); align-items: flex-start; }
.cegm .wp-block-column { flex: 1 1 0; min-width: 0; }
.cegm .wp-block-column[style*="flex-basis"] { flex-grow: 0; }
.cegm .wp-block-column > * + * { margin-top: var(--cegm-space-5); }
.cegm .cegm-display { font-size: 56px; line-height: 60px; letter-spacing: -0.01em; }
.cegm .cegm-hero__photo img, .cegm .cegm-photo img { border-radius: var(--cegm-radius-lg); width: 100%; aspect-ratio: 3 / 2; object-fit: cover; }
.cegm .cegm-hero__photo figcaption, .cegm .cegm-photo figcaption { margin-top: var(--cegm-space-2); font-size: 15px; line-height: 22px; color: var(--cegm-ink-muted); text-align: left; }

/* Sign-up box around the Ninja Form */
.cegm .cegm-hero { align-items: flex-start; }
.cegm .cegm-hero__pitch { padding-top: var(--cegm-space-3); }
.cegm .cegm-hero__pitch .is-style-cegm-eyebrow + .wp-block-list { margin-top: var(--cegm-space-2); }
.cegm .cegm-signup { background: var(--cegm-surface-sunk); border: 1px solid var(--cegm-rule); border-radius: var(--cegm-radius-lg); padding: var(--cegm-space-6); scroll-margin-top: var(--cegm-space-8); }
/* Form fields stack one per row at full width. */
.cegm .cegm-signup nf-fields-wrap, .cegm .cegm-signup nf-field { display: block; }
.cegm .cegm-signup .nf-field-container { width: 100%; max-width: none; margin: 0 0 var(--cegm-space-4); clear: both; }
.cegm .cegm-signup .nf-field-element { width: 100%; max-width: none; }
.cegm .cegm-signup .nf-form-cont input[type="email"],
.cegm .cegm-signup .nf-form-cont input[type="text"],
.cegm .cegm-signup .nf-form-cont select { width: 100% !important; max-width: none !important; }
/* Hidden fields, the honeypot and empty helper rows take no space. */
.cegm .cegm-signup .hidden-container,
.cegm .cegm-signup .nf-form-hp,
.cegm .cegm-signup .nf-before-form-content:empty,
.cegm .cegm-signup .nf-after-form-content:empty,
.cegm .cegm-signup .nf-error-wrap:empty,
.cegm .cegm-signup .nf-after-field:empty,
.cegm .cegm-signup .nf-before-field:empty { display: none !important; margin: 0 !important; padding: 0 !important; }
.cegm .cegm-signup .nf-before-form-content, .cegm .cegm-signup .nf-form-errors:empty, .cegm .cegm-signup .nf-response-msg:empty { margin: 0; padding: 0; min-height: 0; }
/* The privacy note sits close to the button; the button spans the card. */
.cegm .cegm-signup .html-container { margin-bottom: var(--cegm-space-4); }
/* Empty paragraphs left behind by Ninja Forms' rich-text editor take no space. */
.cegm .cegm-signup .html-container p:empty,
.cegm .cegm-signup .html-container p:has(> br:only-child) { display: none; }
.cegm .cegm-signup .html-container p { margin: 0 !important; }
.cegm .cegm-signup .submit-container { margin: 0; }
.cegm .cegm-signup .submit-container .nf-field-element { margin: 0; }
.cegm .cegm-signup .submit-container input[type="submit"],
.cegm .cegm-signup .submit-container input[type="button"] { width: 100% !important; }
/* No red asterisk: optional questions say "(optional)" in their labels instead. */
.cegm .cegm-signup .ninja-forms-req-symbol { display: none; }
.cegm .cegm-signup > * + * { margin-top: var(--cegm-space-3); }
.cegm .cegm-signup h2.wp-block-heading { font-size: 24px; line-height: 30px; }
.cegm .cegm-signup > h2 + p { margin-top: var(--cegm-space-1); font-size: 16px; line-height: 24px; color: var(--cegm-ink-muted); }
.cegm .cegm-signup > h2 + p + * { margin-top: var(--cegm-space-5); }

/* ---------- Ninja Forms (form 18) in the brand ---------- */
.cegm .nf-form-title, .cegm .nf-form-fields-required { display: none; }
.cegm .nf-field-container { margin-bottom: var(--cegm-space-4); }
.cegm .nf-field-label { margin-bottom: var(--cegm-space-1); }
.cegm .nf-field-label label, .cegm .nf-field-label .nf-label-span { font: 700 16px/22px var(--cegm-font); color: var(--cegm-ink); }
.cegm .nf-form-cont input[type="email"],
.cegm .nf-form-cont input[type="text"],
.cegm .nf-form-cont select {
  width: 100%; min-height: 46px; padding: 10px 12px;
  border: 1px solid var(--cegm-border-control); border-radius: var(--cegm-radius-md);
  background: var(--cegm-surface); color: var(--cegm-ink); font: 400 17px/24px var(--cegm-font);
}
.cegm .nf-form-cont input:focus-visible, .cegm .nf-form-cont select:focus-visible { outline: 2px solid var(--cegm-focus); outline-offset: 2px; }
.cegm .nf-form-cont select { appearance: auto; cursor: pointer; }
/* Radio list ("Which best describes you?") */
.cegm .nf-form-cont .listradio-wrap ul,
.cegm .nf-form-cont .nf-field-element ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.cegm .nf-form-cont .nf-field-element li { display: flex; gap: 10px; align-items: flex-start; margin: 0; padding: 0; }
.cegm .nf-form-cont input[type="radio"],
.cegm .nf-form-cont input[type="checkbox"] { flex: none; width: 20px; height: 20px; margin: 1px 0 0; accent-color: var(--cegm-action); cursor: pointer; }
.cegm .nf-form-cont .nf-field-element li label { margin: 0; font: 400 16px/22px var(--cegm-font); color: var(--cegm-ink); cursor: pointer; }
.cegm .nf-form-cont .nf-field-element li label::after,
.cegm .nf-form-cont .nf-field-element li label::before { display: none; }
/* Note before the button (a Ninja Forms HTML field) */
.cegm .nf-form-cont .html-container p { margin: 0; }
.cegm .nf-form-cont .html-wrap { margin-top: var(--cegm-space-1); }
.cegm .nf-form-cont .submit-container input[type="submit"] { width: 100%; }
.cegm .nf-field-description, .cegm .nf-form-cont .html-container { font-size: 15px; line-height: 22px; color: var(--cegm-ink-muted); }
.cegm .nf-error-msg, .cegm .nf-error .nf-error-msg { font-size: 15px; line-height: 22px; font-weight: 700; color: #A3262F; }
.cegm .nf-response-msg { font-size: 17px; line-height: 26px; font-weight: 700; color: var(--cegm-ink); }

/* ---------- Photo strip (after the hero) ---------- */
.cegm .cegm-s-photo { margin-top: var(--cegm-space-16); }
.cegm .cegm-strip { margin: 0; }
.cegm .cegm-strip img { width: 100%; aspect-ratio: 21 / 9; object-fit: cover; object-position: center; border-radius: var(--cegm-radius-lg); }
.cegm .cegm-strip figcaption { margin-top: var(--cegm-space-2); font-size: 15px; line-height: 22px; color: var(--cegm-ink-muted); text-align: left; }

/* ---------- Audience checklist ---------- */
.cegm .cegm-checklist { list-style: none; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--cegm-space-3) var(--cegm-space-12); max-width: 920px; }
.cegm .cegm-ticks { list-style: none; padding: 0; display: grid; gap: var(--cegm-space-3); }
.cegm .cegm-checklist li, .cegm .cegm-ticks li { position: relative; padding-left: 28px; font-size: 18px; line-height: 26px; margin: 0; }
.cegm .cegm-checklist li::before, .cegm .cegm-ticks li::before { content: ""; position: absolute; left: 2px; top: 9px; width: 10px; height: 10px; border-radius: 50%; background: var(--cegm-lime-300); box-shadow: 0 0 0 2px var(--cegm-navy-900); }

/* "Next meet-up" line at the foot of the hero pitch */
.cegm .cegm-hero__pitch .cegm-next { margin-top: var(--cegm-space-6); padding-top: var(--cegm-space-4); border-top: 1px solid var(--cegm-rule); font-size: 17px; line-height: 26px; }

/* Subheadings inside a section (e.g. Past editions) */
.cegm .cegm-section > h3.wp-block-heading { margin-top: var(--cegm-space-12); }
.cegm .cegm-section > h3.wp-block-heading + * { margin-top: var(--cegm-space-3); }
.cegm .wp-block-column > h3.wp-block-heading + .is-style-cegm-meta { margin-top: var(--cegm-space-1); }

/* ---------- Grids of boxes ---------- */
.cegm .cegm-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: var(--cegm-space-6); }
.cegm .cegm-grid > * { margin: 0; }
.cegm .cegm-grid--2 { grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); max-width: 920px; }
.cegm .cegm-box { border: 1px solid var(--cegm-rule); border-radius: var(--cegm-radius-lg); padding: var(--cegm-space-5); background: var(--cegm-surface); }
.cegm .cegm-box > * + * { margin-top: var(--cegm-space-2); }
.cegm .cegm-box h3.wp-block-heading { font-size: 19px; line-height: 25px; }
.cegm .cegm-box p { font-size: 16px; line-height: 24px; }
.cegm .cegm-box .wp-block-list { padding-left: 0; list-style: none; font-size: 16px; line-height: 24px; }
.cegm .cegm-box .wp-block-list li + li { margin-top: var(--cegm-space-2); }

/* ---------- Deadline list ---------- */
.cegm .cegm-deadlines { max-width: 760px; border: 1px solid var(--cegm-rule); border-radius: var(--cegm-radius-lg); padding: 2px var(--cegm-space-5); }
.cegm .cegm-deadline { display: grid; grid-template-columns: 88px minmax(0, 1fr); gap: 0 var(--cegm-space-3); padding: var(--cegm-space-4) 0; margin: 0; }
.cegm .cegm-deadline + .cegm-deadline { border-top: 1px solid var(--cegm-rule); }
.cegm .cegm-deadline__when p:first-child { font-size: 19px; line-height: 22px; font-weight: 700; font-variant-numeric: tabular-nums; }
.cegm .cegm-deadline__when p + p { margin-top: 0; font-size: 15px; line-height: 22px; color: var(--cegm-ink-muted); }
.cegm .cegm-deadline__body p { font-size: 16px; line-height: 23px; }
.cegm .cegm-deadline__body p + p { margin-top: var(--cegm-space-1); }
.cegm .cegm-deadline__body .is-style-cegm-meta { font-size: 15px; line-height: 22px; }

/* ---------- Events with date chip ---------- */
.cegm .cegm-events { max-width: 760px; display: grid; gap: var(--cegm-space-6); }
.cegm .cegm-event { display: grid; grid-template-columns: 64px minmax(0, 1fr); gap: var(--cegm-space-4); margin: 0; }
.cegm .cegm-event > * { margin: 0; }
.cegm .cegm-chip { width: 64px; border: 1px solid var(--cegm-rule); border-radius: var(--cegm-radius-chip); overflow: hidden; text-align: center; font-weight: 700; align-self: start; }
.cegm .cegm-chip p { margin: 0; }
.cegm .cegm-chip p:first-child { padding: 4px 0; background: var(--cegm-surface-brand-strong); color: var(--cegm-accent); font-size: 13px; line-height: 17px; }
.cegm .cegm-chip p + p { padding: 6px 0; font-size: 24px; line-height: 28px; color: var(--cegm-ink); }
.cegm .cegm-event__body p { font-size: 16px; line-height: 24px; }
.cegm .cegm-event__body p + p { margin-top: var(--cegm-space-1); }
.cegm .cegm-event__body .is-style-cegm-meta { font-size: 15px; line-height: 22px; }

/* ---------- Offers and asks ---------- */
.cegm .cegm-notices { max-width: 760px; }
.cegm .cegm-notice { padding: var(--cegm-space-3) 0; margin: 0; }
.cegm .cegm-notice + .cegm-notice { border-top: 1px solid var(--cegm-rule); }
.cegm .cegm-notice p { font-size: 16px; line-height: 24px; }
.cegm .cegm-notice p + p { margin-top: var(--cegm-space-1); }
.cegm .cegm-notice .is-style-cegm-meta { display: inline-block; margin: 0 0 0 var(--cegm-space-2); font-size: 15px; }

/* ---------- Spotlight and evidence (media + text) ---------- */
.cegm .cegm-qa p strong { display: block; }

/* ---------- Past editions (Latest Posts block) ---------- */
.cegm .wp-block-latest-posts.cegm-archive { max-width: 760px; padding: 0; list-style: none; border-top: 1px solid var(--cegm-rule); }
.cegm .cegm-archive li { display: flex; flex-wrap: wrap; justify-content: space-between; gap: var(--cegm-space-1) var(--cegm-space-4); padding: var(--cegm-space-3) 0; border-bottom: 1px solid var(--cegm-rule); margin: 0; }
.cegm .cegm-archive .wp-block-latest-posts__post-title { font-weight: 700; font-size: 17px; }
.cegm .cegm-archive .wp-block-latest-posts__post-date { color: var(--cegm-ink-muted); font-size: 15px; font-variant-numeric: tabular-nums; }

/* ---------- Closing call to action ---------- */
.cegm .cegm-band--cta { display: grid; gap: var(--cegm-space-4); justify-items: start; }
.cegm .cegm-band--cta > * { margin: 0; }
.cegm .cegm-band--cta p { max-width: 60ch; font-size: 18px; line-height: 28px; }

/* ---------- Network footer ---------- */
.cegm .cegm-footer { background: var(--cegm-surface-sunk); border-radius: var(--cegm-radius-lg); padding: var(--cegm-space-8); }
.cegm .cegm-footer > * + * { margin-top: var(--cegm-space-3); }
.cegm .cegm-footer p { font-size: 16px; line-height: 24px; }
.cegm .cegm-footer .cegm-footer__name { font-size: 19px; line-height: 25px; font-weight: 700; }
.cegm .cegm-footer .is-style-cegm-meta { font-size: 15px; line-height: 22px; }

/* ---------- Tablet ---------- */
@media (max-width: 1023px) {
  .cegm { --cegm-gutter: var(--cegm-space-8); }
  .cegm .wp-block-columns { gap: var(--cegm-space-8); }
}

/* ---------- Phone ---------- */
@media (max-width: 767px) {
  .cegm { --cegm-gutter: var(--cegm-space-5); --cegm-section-gap: var(--cegm-space-16); font-size: 17px; line-height: 26px; }
  .cegm .cegm-display { font-size: 40px; line-height: 44px; }
  .cegm h2.wp-block-heading { font-size: 24px; line-height: 30px; }
  .cegm .wp-block-columns { flex-direction: column; flex-wrap: wrap; }
  .cegm .wp-block-column, .cegm .wp-block-column[style*="flex-basis"] { flex-basis: 100% !important; width: 100%; }
  .cegm .cegm-s-masthead { margin-top: 0; padding: 0; }
  .cegm .cegm-band { border-radius: 0; padding: var(--cegm-space-5); }
  .cegm .cegm-s-cta .cegm-band, .cegm .cegm-footer { border-radius: var(--cegm-radius-lg); }
  .cegm .cegm-band__brand { gap: var(--cegm-space-4); }
  .cegm .cegm-logo, .cegm .cegm-logo img { width: 64px; }
  .cegm .cegm-wordmark { font-size: 24px; line-height: 28px; }
  .cegm .cegm-strapline { font-size: 15px; }
  /* Phones: the form follows straight after the headline, so the masthead button isn't needed. */
  .cegm .cegm-s-masthead .wp-block-buttons { display: none; }
  .cegm .cegm-checklist { grid-template-columns: 1fr; }
  .cegm .cegm-s-photo { margin-top: var(--cegm-space-12); }
  .cegm .cegm-strip img { aspect-ratio: 3 / 2; }
  /* Phones: drop the digest summary so the form starts sooner; the same sections follow further down. */
  .cegm .cegm-hero__pitch .is-style-cegm-eyebrow, .cegm .cegm-hero__pitch .cegm-ticks { display: none; }
  .cegm .cegm-hero__pitch .cegm-next { margin-top: var(--cegm-space-4); }
  .cegm .cegm-signup { padding: var(--cegm-space-5); }
  .cegm .cegm-footer, .cegm .cegm-band--cta { padding: var(--cegm-space-6) var(--cegm-space-5); }
}