/* site.css — Primapper base styles: colour tokens (light + dark), header/footer, content pages,
   region pages and the shared deal/rate components. The map adds map.css on top (bundled). */

@font-face { font-family: "Schibsted Grotesk"; src: url("/assets/fonts/schibsted-grotesk-latin-wght-normal.woff2") format("woff2"); font-weight: 400 900; font-style: normal; font-display: swap; }

/* PriMapper design tokens, direction 02 (light green and air). Light first, dark below. */
:root {
  --pm-bg: #eef6f0;
  --pm-surface: #ffffff;
  --pm-soft: #e2efe6;
  --pm-border: #c9dfd0;
  --pm-ink: #0a2a1f;
  --pm-ink2: #355446;
  --pm-muted: #4f6a5c;
  --pm-accent: #145c43;
  --pm-accent-ink: #ffffff;
  --pm-cta: #f2bf1d;
  --pm-cta-ink: #0a2a1f;
  --pm-forest: #0b3b2c;
  --pm-sea: #e2efe6;
  --pm-good: #17714f;
  --pm-warn: #8a5a00;
  --pm-note-bg: #fff4d6;
  --pm-note-ink: #5e4300;
  --pm-shadow: 0 10px 30px -12px rgba(11, 59, 44, .35);
  --pm-radius: 20px;
  --pm-font: "Schibsted Grotesk", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --pm-bg: #0b1a13; --pm-surface: #11261c; --pm-soft: #1a3326; --pm-border: #2a4636;
    --pm-ink: #e7f2ec; --pm-ink2: #b4cbbd; --pm-muted: #8fa89a; --pm-accent: #7fd18f; --pm-accent-ink: #0b1a13;
    --pm-forest: #e7f2ec; --pm-sea: #0f2218; --pm-good: #6fcf8a; --pm-warn: #f0b05a; --pm-note-bg: #3a2f12; --pm-note-ink: #f5d78a;
    --pm-shadow: 0 10px 30px rgba(0, 0, 0, .5);
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --pm-bg: #0b1a13; --pm-surface: #11261c; --pm-soft: #1a3326; --pm-border: #2a4636;
  --pm-ink: #e7f2ec; --pm-ink2: #b4cbbd; --pm-muted: #8fa89a; --pm-accent: #7fd18f; --pm-accent-ink: #0b1a13;
  --pm-forest: #e7f2ec; --pm-sea: #0f2218; --pm-good: #6fcf8a; --pm-warn: #f0b05a; --pm-note-bg: #3a2f12; --pm-note-ink: #f5d78a;
  --pm-shadow: 0 10px 30px rgba(0, 0, 0, .5);
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--pm-bg); color: var(--pm-ink); font: 16px/1.5 var(--pm-font); }
a { color: var(--pm-accent); }
button, input, select { font: inherit; }
.pm-wrap { width: min(1280px, 100%); margin: 0 auto; padding: 0 16px; }
.pm-muted { color: var(--pm-muted); }

/* ── Header / footer ── */
.pm-site-head { background: var(--pm-bg); border-bottom: 1px solid var(--pm-border); position: sticky; top: 0; z-index: 1000; }
.pm-site-head-in { display: flex; align-items: center; justify-content: space-between; gap: 1rem; min-height: 60px; flex-wrap: wrap; }
.pm-brand { display: inline-flex; align-items: center; gap: .45rem; color: var(--pm-ink); text-decoration: none; font-weight: 800; font-size: 1.35rem; letter-spacing: -.5px; }
.pm-brand-pin { width: 26px; height: 26px; fill: var(--pm-accent); }
.pm-brand-pin { fill: var(--pm-accent); }
.pm-brand-dot { fill: var(--pm-cta); }
.pm-site-nav { display: flex; align-items: center; gap: 1rem; flex-wrap: wrap; font-size: .92rem; }
.pm-site-nav a { color: var(--pm-ink2); text-decoration: none; font-weight: 600; }
.pm-site-nav a:hover { color: var(--pm-accent); }
.pm-nav-links { display: flex; align-items: center; gap: inherit; flex-wrap: wrap; }
.pm-theme-btn { border: 1px solid var(--pm-border); background: var(--pm-soft); color: var(--pm-ink2); border-radius: 999px; width: 34px; height: 34px; cursor: pointer; display: inline-grid; place-items: center; padding: 0; flex: none; }
.pm-theme-btn:hover { color: var(--pm-accent); }
.pm-site-foot { margin-top: 3rem; border-top: 1px solid var(--pm-border); background: var(--pm-surface); color: var(--pm-muted); font-size: .82rem; padding: 1.5rem 0 2rem; }
.pm-site-foot nav { display: flex; gap: 1rem; flex-wrap: wrap; margin-bottom: .6rem; }
.pm-site-foot nav a { color: var(--pm-ink2); text-decoration: none; font-weight: 600; }
.pm-site-foot p { margin: .35rem 0; max-width: 820px; }
.pm-attrib { font-size: .74rem; }

/* ── Content pages ── */
.pm-page { padding-top: 2rem; }
.pm-prose { max-width: 760px; }
.pm-prose h1 { font-size: clamp(1.8rem, 4vw, 2.5rem); line-height: 1.15; letter-spacing: -.8px; margin: .2rem 0 1rem; }
.pm-prose h2 { font-size: 1.3rem; margin: 2rem 0 .5rem; }
.pm-prose p, .pm-prose li { color: var(--pm-ink2); }
.pm-prose .pm-lede { font-size: 1.15rem; color: var(--pm-ink); }
.pm-draft { background: var(--pm-note-bg); color: var(--pm-note-ink); border-radius: 10px; padding: .6rem .9rem; font-size: .88rem; margin-bottom: 1.2rem; }

/* ── Shared components (map panel + region pages) ── */
.pm-btn { display: inline-block; border: 1px solid var(--pm-accent); background: var(--pm-accent); color: var(--pm-accent-ink); border-radius: 9px; padding: .55rem 1rem; font-weight: 700; text-decoration: none; cursor: pointer; }
.pm-btn-ghost { background: transparent; color: var(--pm-ink2); border-color: var(--pm-border); }
.pm-demo { background: var(--pm-note-bg); color: var(--pm-note-ink); border-radius: 10px; padding: .6rem .9rem; margin: 1rem 0; font-size: .88rem; line-height: 1.4; }
.pm-demo b { margin-right: .5rem; letter-spacing: .5px; }
.pm-rates { width: 100%; border-collapse: collapse; font-size: .8rem; margin: .35rem 0; }
.pm-rates th { font-weight: 600; color: var(--pm-muted); text-align: right; padding: .12rem .25rem; }
.pm-rates th:first-child, .pm-rates td:first-child { text-align: left; }
.pm-rates td { text-align: right; padding: .14rem .25rem; color: var(--pm-ink2); }
.pm-save { font-size: .76rem; font-weight: 700; color: var(--pm-good); }
.pm-save-none { color: var(--pm-muted); }
.pm-checked { font-size: .74rem; color: var(--pm-muted); margin-top: .35rem; }
.pm-chip { display: inline-block; font-size: .7rem; font-weight: 700; border-radius: 999px; padding: .05rem .5rem; margin-left: .35rem;
  background: var(--pm-soft); border: 1px solid var(--pm-border); color: var(--pm-ink2); vertical-align: middle; }
.pm-chip-green { color: var(--pm-good); }
.pm-switch { display: inline-block; background: var(--pm-accent); color: var(--pm-accent-ink) !important; text-decoration: none !important;
  font-weight: 800; font-size: .88rem; border-radius: 9px; padding: .45rem .85rem; transition: transform .1s, filter .1s; white-space: nowrap; }
.pm-switch:hover { filter: brightness(1.08); transform: translateY(-1px); }
.pm-switch-off { background: var(--pm-soft); color: var(--pm-muted) !important; font-weight: 600; cursor: default; }
.pm-switch-off:hover { transform: none; filter: none; }
.pm-deal { display: grid; grid-template-columns: 26px 1fr auto; gap: .6rem; border: 1px solid var(--pm-border); border-radius: 12px; padding: .75rem; background: var(--pm-surface); }
.pm-deal-rank { width: 24px; height: 24px; border-radius: 50%; background: var(--pm-soft); display: flex; align-items: center; justify-content: center; font-weight: 800; font-size: .8rem; }
.pm-deal-name { font-weight: 800; }
.pm-deal-tariff { font-size: .8rem; color: var(--pm-muted); }
.pm-deal-side { display: flex; flex-direction: column; align-items: flex-end; gap: .3rem; }
.pm-deal-yr { font-weight: 800; font-size: 1.15rem; }
.pm-deal-yr small { font-weight: 500; font-size: .75rem; color: var(--pm-muted); }
.pm-deal-list { display: flex; flex-direction: column; gap: .6rem; }
.pm-deal.pm-deal-solo { grid-template-columns: minmax(0, 1fr) auto; }
/* Narrow screens: the price and Switch button go under the tariff, so the rates table can't push them off the card. */
@media (max-width: 560px) {
  .pm-deal { grid-template-columns: 26px minmax(0, 1fr); }
  .pm-deal.pm-deal-solo { grid-template-columns: minmax(0, 1fr); }
  .pm-deal.pm-deal-solo .pm-deal-side { grid-column: 1; }
  .pm-deal-side { grid-column: 2; flex-direction: row; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: .5rem; padding-top: .55rem; border-top: 1px solid var(--pm-border); }
}
.pm-fine { font-size: .78rem; color: var(--pm-muted); line-height: 1.45; }

/* ── Region pages ── */
.pm-region-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 1rem; flex-wrap: wrap; }
.pm-region-grid { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 1.5rem; align-items: start; margin-top: 1rem; }
.pm-card { background: var(--pm-surface); border: 1px solid var(--pm-border); border-radius: var(--pm-radius); padding: 1rem 1.1rem; }
.pm-card h2 { margin: 0 0 .5rem; font-size: 1.05rem; }
.pm-big { font-size: 2rem; font-weight: 800; letter-spacing: -.5px; }
.pm-counties { columns: 2; font-size: .88rem; color: var(--pm-ink2); padding-left: 1.1rem; }
.pm-region-links { display: flex; flex-wrap: wrap; gap: .4rem; }
.pm-region-links a { font-size: .82rem; border: 1px solid var(--pm-border); border-radius: 999px; padding: .2rem .7rem; text-decoration: none; color: var(--pm-ink2); background: var(--pm-surface); }
@media (max-width: 860px) {
  .pm-region-grid { grid-template-columns: 1fr; }
  .pm-site-nav { gap: .7rem; font-size: .85rem; }
}
/* Phones: brand and theme button on one row, the links in one row that scrolls sideways. */
@media (max-width: 640px) {
  .pm-site-head { position: static; }
  .pm-site-head-in { display: grid; grid-template-columns: 1fr auto; gap: .25rem .75rem; min-height: 0; padding-block: .55rem .35rem; }
  .pm-brand { font-size: 1.2rem; }
  .pm-site-nav { display: contents; }
  .pm-site-nav .pm-theme-btn { grid-column: 2; grid-row: 1; }
  .pm-nav-links { grid-column: 1 / -1; display: flex; flex-wrap: nowrap; gap: 1.1rem; overflow-x: auto; scrollbar-width: none; padding-block: .35rem .2rem; white-space: nowrap; -webkit-mask-image: linear-gradient(90deg,#000 88%,transparent); mask-image: linear-gradient(90deg,#000 88%,transparent); }
  .pm-nav-links::-webkit-scrollbar { display: none; }
}
.pm-deal .pm-rates td:first-child { white-space: nowrap; }
.pm-deal .pm-rates th { white-space: nowrap; }

/* ── Private-preview gate ── */
.pm-preview-bar { background: var(--pm-ink); color: var(--pm-bg); font-size: .8rem; text-align: center; padding: .3rem 1rem; }
.pm-preview-bar a { color: inherit; }
.pm-gate-body { min-height: 100vh; display: flex; align-items: center; justify-content: center; padding: 16px; }
.pm-gate { width: min(400px, 100%); display: flex; flex-direction: column; align-items: center; gap: 1.2rem; }
.pm-gate-brand { font-size: 1.6rem; }
.pm-gate-card { width: 100%; background: var(--pm-surface); border: 1px solid var(--pm-border); border-radius: var(--pm-radius);
  padding: 1.5rem; display: flex; flex-direction: column; gap: .8rem; box-shadow: var(--pm-shadow); }
.pm-gate-card h1 { margin: 0; font-size: 1.4rem; }
.pm-gate-card p { margin: 0; }
.pm-gate-card label { display: flex; flex-direction: column; gap: .3rem; font-weight: 600; font-size: .9rem; }
.pm-gate-card input { border: 1px solid var(--pm-border); background: var(--pm-bg); color: var(--pm-ink); border-radius: 8px; padding: .55rem .65rem; font-size: 1rem; }
.pm-gate-err { color: var(--pm-warn); font-weight: 600; font-size: .9rem; }
.pm-gate-ok { color: var(--pm-good); font-weight: 600; font-size: .9rem; }

/* ── Grants (map panel, /grants pages, region pages) ── */
.pm-btn-sm { padding: .35rem .75rem; font-size: .85rem; }
.pm-chip-warn { color: var(--pm-warn); border-color: currentColor; }
.pm-linkbtn { background: none; border: none; padding: 0; color: var(--pm-accent); font: inherit; font-size: .85rem; font-weight: 600; cursor: pointer; text-decoration: underline; }
.pm-grants { border-top: 1px solid var(--pm-border); margin-top: 1.2rem; padding-top: 1rem; }
.pm-grants-head { display: flex; justify-content: space-between; align-items: flex-start; gap: .8rem; margin-bottom: .6rem; }
.pm-grants-head h3 { margin: 0 0 .2rem; font-size: 1.1rem; }
.pm-grants-head p { margin: 0; font-size: .85rem; }
.pm-grant { border: 1px solid var(--pm-border); border-radius: 12px; padding: .75rem .85rem; margin: .55rem 0; background: var(--pm-surface); }
.pm-grant-top { display: flex; justify-content: space-between; gap: .8rem; align-items: flex-start; }
.pm-grant-name { font-weight: 800; }
.pm-grant-short { font-size: .88rem; color: var(--pm-ink2); margin-top: .1rem; }
.pm-grant-amount { font-weight: 800; font-size: 1.05rem; text-align: right; white-space: nowrap; color: var(--pm-good); }
.pm-grant-who { font-size: .82rem; color: var(--pm-ink2); margin-top: .45rem; }
.pm-grant-text { font-size: .88rem; color: var(--pm-ink2); margin: .45rem 0 0; }
.pm-grant-foot { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem; margin-top: .55rem; }
.pm-grant-foot .pm-linkbtn { margin-right: auto; }
.pm-grant-unlikely { opacity: .62; }
.pm-verdict { display: inline-block; font-size: .78rem; font-weight: 700; border-radius: 6px; padding: .12rem .45rem; margin-top: .4rem; }
.pm-verdict-likely { background: color-mix(in srgb, var(--pm-good) 16%, transparent); color: var(--pm-good); }
.pm-verdict-maybe { background: var(--pm-note-bg); color: var(--pm-note-ink); }
.pm-verdict-unlikely { background: var(--pm-soft); color: var(--pm-muted); }
.pm-grant-table { width: 100%; border-collapse: collapse; font-size: .9rem; }
.pm-grant-table th, .pm-grant-table td { text-align: left; padding: .5rem .55rem; border-bottom: 1px solid var(--pm-border); vertical-align: top; }
.pm-grant-table th { font-size: .75rem; text-transform: uppercase; letter-spacing: .4px; color: var(--pm-muted); }
.pm-grant-table td:nth-child(3) { white-space: nowrap; font-weight: 700; }
.pm-table-scroll { overflow-x: auto; }
.pm-filter { display: flex; flex-wrap: wrap; gap: .35rem; margin: .6rem 0 1rem; }
.pm-filter a { font-size: .82rem; border: 1px solid var(--pm-border); border-radius: 999px; padding: .2rem .7rem; text-decoration: none; color: var(--pm-ink2); background: var(--pm-surface); }
.pm-filter a.pm-on { background: var(--pm-accent); border-color: var(--pm-accent); color: var(--pm-accent-ink); }
.pm-facts { display: grid; grid-template-columns: max-content 1fr; gap: .35rem 1rem; font-size: .92rem; margin: 0; }
.pm-facts dt { color: var(--pm-muted); font-weight: 600; }
.pm-facts dd { margin: 0; }

/* Checker */
.pm-checker { outline: none; }
.pm-checker-head { display: flex; justify-content: space-between; align-items: center; }
.pm-checker-head h3 { margin: 0; font-size: 1.25rem; }
.pm-checker .pm-panel-close { position: static; }
.pm-q { border: none; padding: 0; margin: 0 0 .9rem; }
.pm-q legend { font-weight: 700; font-size: .92rem; margin-bottom: .35rem; padding: 0; }
.pm-q-help { font-size: .8rem; margin-top: .3rem; }
/* "Find my rating" (EPC register) inside the grant checker */
.pm-epc-open { margin-top: .45rem; }
.pm-epc { margin-top: .5rem; padding: .7rem .8rem; border: 1px solid var(--pm-border); border-radius: 12px; background: var(--pm-soft); }
.pm-epc-form { display: flex; flex-wrap: wrap; align-items: flex-end; gap: .5rem; }
.pm-epc-label { display: flex; flex-direction: column; gap: .2rem; font-size: .8rem; font-weight: 700; color: var(--pm-ink2); }
.pm-epc-label input { font: inherit; font-size: 1rem; font-weight: 600; text-transform: uppercase; width: 9.5rem; padding: .4rem .6rem; border: 1px solid var(--pm-border); border-radius: 10px; background: var(--pm-surface); color: var(--pm-ink); }
.pm-epc-label input:focus-visible { outline: 2px solid var(--pm-accent); outline-offset: 1px; }
.pm-epc .pm-fine { margin: .4rem 0 0; }
.pm-epc-msg { font-size: .88rem; margin: .5rem 0 0; }
.pm-epc-list { margin-top: .5rem; max-height: 16rem; overflow-y: auto; }
.pm-epc-list .pm-muted { font-size: .82rem; margin: 0 0 .3rem; }
.pm-rank-row.pm-epc-row { grid-template-columns: 1fr auto; align-items: center; cursor: pointer; }
.pm-epc-band { display: inline-block; min-width: 1.6rem; text-align: center; font-weight: 800; font-size: .85rem; padding: .1rem .35rem; border-radius: 6px; color: #fff; }
.pm-epc-A { background: #008054; } .pm-epc-B { background: #19b459; color: #06210f; } .pm-epc-C { background: #8dce46; color: #10220a; } .pm-epc-D { background: #ffd500; color: #2a2300; }
.pm-epc-E { background: #fcaa65; color: #2b1600; } .pm-epc-F { background: #ef8023; color: #2b1300; } .pm-epc-G { background: #c8102e; }
.pm-checker .pm-seg button, .pm-seg-grants { border: 1px solid var(--pm-border); background: var(--pm-surface); color: var(--pm-ink2); border-radius: 999px;
  padding: .4rem .95rem; font-weight: 700; font-size: .88rem; cursor: pointer; }
.pm-checker .pm-seg button.pm-on { background: var(--pm-accent); border-color: var(--pm-accent); color: var(--pm-accent-ink); }
.pm-seg-grants { color: var(--pm-good); }
.pm-seg-grants.pm-on { background: var(--pm-good); border-color: var(--pm-good); color: #fff; }
.pm-modal { position: fixed; z-index: 2100; top: 50%; left: 50%; transform: translate(-50%, -50%); width: min(620px, calc(100vw - 32px));
  max-height: calc(100vh - 48px); overflow-y: auto; background: var(--pm-surface); color: var(--pm-ink); border: 1px solid var(--pm-border);
  border-radius: var(--pm-radius); box-shadow: var(--pm-shadow); padding: 1.2rem 1.2rem 1.4rem; }
.pm-scrim-top { z-index: 2090; }
.pm-checker-box { background: var(--pm-surface); border: 1px solid var(--pm-border); border-radius: var(--pm-radius); padding: 1.1rem 1.2rem; margin: 1rem 0; }

/* Grants view list (right of the map) */
.pm-glist { margin-bottom: .6rem; }
.pm-glist-nation { font-weight: 800; padding: .3rem .4rem .1rem; }
.pm-glist-nation small { color: var(--pm-muted); font-weight: 600; margin-left: .3rem; }
.pm-glist-row { text-decoration: none; grid-template-columns: 1fr auto !important; }
.pm-glist-btn { width: 100%; margin-top: .4rem; text-align: center; }
@media (max-width: 600px) {
  .pm-grants-head { flex-direction: column; }
  .pm-grant-top { flex-direction: column; gap: .2rem; }
  .pm-grant-amount { text-align: left; }
  .pm-facts { grid-template-columns: 1fr; }
}

/* Grants Phase 2: quote buttons (a lead, not a sale: outline style, never looks like Switch) */
.pm-quote { display: inline-block; border: 2px solid var(--pm-good); color: var(--pm-good); background: transparent; border-radius: 9px;
  padding: .3rem .8rem; font-weight: 800; font-size: .85rem; text-decoration: none; cursor: pointer; font-family: inherit; }
.pm-quote:hover { background: color-mix(in srgb, var(--pm-good) 12%, transparent); }
.pm-quote-note { font-size: .74rem; color: var(--pm-muted); margin-top: .35rem; }
.pm-quote-modal { width: min(760px, calc(100vw - 32px)); }
.pm-quote-frame { width: 100%; height: min(70vh, 640px); border: 1px solid var(--pm-border); border-radius: 10px; background: #fff; }

/* Map page quick guide */
.pm-howto { margin: .2rem 0 .4rem; font-size: .9rem; color: var(--pm-ink2); }
.pm-howto summary { cursor: pointer; font-weight: 700; color: var(--pm-accent); width: max-content; }
.pm-howto ol { margin: .4rem 0 0; padding-left: 1.3rem; }
.pm-howto li { margin: .2rem 0; }

/* ── Direction 02: hero, "No details needed" strip, postcode search ── */
h1, h2, h3 { letter-spacing: -.025em; }
/* Main USP and the start of the journey (Tom, 15 Nov): big, first thing on the page, one short line under it. No coloured side bar (Iñaki). */
.pm-nodetails { background: var(--pm-surface); border: 1px solid var(--pm-border); border-radius: 16px; margin: .6rem 0 .6rem;
  box-shadow: 0 14px 34px -22px rgba(11, 59, 44, .45); }
.pm-nodetails-in { display: flex; align-items: center; gap: 1rem; padding: .9rem 1.2rem; }
.pm-nodetails svg { width: 2.6rem; height: 2.6rem; padding: .5rem; box-sizing: border-box; border-radius: 50%; background: var(--pm-soft); flex: none; fill: none;
  stroke: var(--pm-accent); stroke-width: 1.75; stroke-linecap: round; stroke-linejoin: round; }
.pm-nodetails p { margin: 0; color: var(--pm-ink2); font-size: clamp(1rem, .95rem + .25vw, 1.15rem); line-height: 1.3; }
.pm-nodetails strong { display: block; color: var(--pm-ink); font-size: clamp(1.45rem, 1.1rem + 1.2vw, 2rem); font-weight: 800; letter-spacing: -.03em; line-height: 1.1; }
.pm-home-top { display: grid; gap: 1.5rem; padding: 1.5rem 0 1rem; align-items: start; }
.pm-home-top > * { min-width: 0; }
@media (min-width: 64rem) { .pm-home-top { grid-template-columns: minmax(0, 1.15fr) minmax(0, .85fr); gap: 3rem; padding-top: 2.5rem; } }
.pm-home-copy h1 { font-size: clamp(2.4rem, 1.2rem + 3.6vw, 4rem); font-weight: 700; line-height: .98; letter-spacing: -.045em; color: var(--pm-forest); margin: 0 0 1rem; }
.pm-home-copy h1 span { display: block; color: var(--pm-good); }
.pm-hero-sub { font-size: clamp(1.1rem, 1rem + .4vw, 1.35rem); color: var(--pm-ink2); max-width: 40ch; line-height: 1.45; margin: 0 0 1rem; }
.pm-hero-sub b { color: var(--pm-ink); font-weight: 600; }
.pm-pc { display: grid; grid-template-columns: minmax(0, 1fr); gap: .6rem; margin: 1rem 0 1.4rem; max-width: 36rem; }
.pm-pc-form { display: flex; align-items: center; gap: .4rem; background: var(--pm-surface); border-radius: 999px; padding: .35rem .35rem .35rem 1.1rem;
  box-shadow: 0 14px 34px -18px rgba(11, 59, 44, .45), 0 0 0 1px var(--pm-border); }
.pm-pc-form:focus-within { box-shadow: 0 14px 34px -18px rgba(11, 59, 44, .45), 0 0 0 3px var(--pm-accent); }
.pm-pc-form svg { width: 1.3rem; height: 1.3rem; flex: none; fill: none; stroke: var(--pm-muted); stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.pm-pc-form input { flex: 1; min-width: 0; width: 0; border: 0; outline: 0; background: transparent; color: var(--pm-ink); font-size: 1.2rem; padding: .7rem .2rem; }
.pm-pc-form input::placeholder { color: var(--pm-muted); }
.pm-pc-go { border: 0; background: var(--pm-accent); color: var(--pm-accent-ink); border-radius: 999px; font-weight: 700; font-size: 1.05rem; padding: .85rem 1.5rem; cursor: pointer; white-space: nowrap; }
.pm-pc-go:hover { filter: brightness(1.1); }
.pm-pc-note { margin: 0; font-size: .84rem; color: var(--pm-muted); }
.pm-pc-msg { margin: 0; padding: .7rem .9rem; border-radius: 12px; background: var(--pm-surface); box-shadow: 0 0 0 1px var(--pm-border); font-size: .98rem; }
.pm-pc-msg.is-err { background: var(--pm-note-bg); color: var(--pm-note-ink); box-shadow: none; }
.pm-pc-big { display: block; font-size: clamp(2.4rem, 1.6rem + 3vw, 3.6rem); font-weight: 800; letter-spacing: -.04em; color: var(--pm-forest); line-height: 1.05; margin-top: .3rem; }
.pm-pc-big small { font-size: 1rem; font-weight: 500; color: var(--pm-muted); letter-spacing: 0; }
.pm-pc-opts { display: flex; flex-wrap: wrap; gap: .4rem; margin-top: .5rem; }
.pm-pc-opts button { border: 1px solid var(--pm-border); background: var(--pm-soft); color: var(--pm-ink); border-radius: 999px; padding: .35rem .8rem; font-weight: 600; cursor: pointer; }
.pm-pc-more { margin-top: .6rem; }
.pm-pc-more button { border: 0; background: var(--pm-cta); color: var(--pm-cta-ink); border-radius: 999px; padding: .6rem 1.2rem; font-weight: 800; cursor: pointer; }
.pm-btn:focus-visible, .pm-pc-go:focus-visible, .pm-pc-opts button:focus-visible, .pm-pc-more button:focus-visible, .pm-seg button:focus-visible, .pm-rank-row:focus-visible, .pm-panel-close:focus-visible {
  outline: 3px solid var(--pm-accent); outline-offset: 2px; }
@media (max-width: 520px) { .pm-pc-go { padding-inline: 1rem; } .pm-pc-form input { font-size: 1.05rem; } }
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { transition-duration: .01ms !important; animation-duration: .01ms !important; } }

.pm-home-copy { min-width: 0; }

/* Postcode result: border or split-district warning */
.pm-pc-warn { display: block; margin-top: .55rem; padding: .6rem .75rem; border-radius: 12px; background: var(--pm-note-bg); color: var(--pm-note-ink); font-size: .9rem; line-height: 1.45; }

.pm-market { margin: 1.2rem 0 0; }
.pm-market[hidden] { display: none; }

/* Deal-end reminder (remind.js), shown after a Switch click. */
.pm-remind { position: fixed; right: 1rem; bottom: 1rem; z-index: 2000; width: min(24rem, calc(100vw - 2rem)); max-height: calc(100vh - 2rem); overflow: auto;
  background: var(--pm-surface, #fff); color: var(--pm-ink); border: 1px solid var(--pm-border); border-radius: 14px; padding: 1rem 1.1rem;
  box-shadow: 0 10px 30px rgba(10, 42, 31, .18); font-size: .95rem; }
.pm-remind h2 { font-size: 1.1rem; margin: 0 0 .35rem; }
.pm-remind p { margin: 0 0 .6rem; color: var(--pm-ink2); }
.pm-remind-form { display: grid; gap: .3rem; }
.pm-remind-form input[type=text], .pm-remind-form input[type=email] { font: inherit; padding: .5rem .6rem; border: 1px solid var(--pm-border); border-radius: 8px; background: var(--pm-bg); color: var(--pm-ink); }
.pm-remind-form > label { font-weight: 600; font-size: .88rem; margin-top: .2rem; }
.pm-remind-tick { display: grid !important; grid-template-columns: auto 1fr; gap: .5rem; align-items: start; font-weight: 500 !important; margin-top: .4rem !important; }
.pm-remind-tick input { margin-top: .2rem; width: 1.1rem; height: 1.1rem; }
.pm-remind-trap { position: absolute; left: -9999px; width: 1px; height: 1px; }
.pm-remind-actions { display: flex; gap: .6rem; margin-top: .5rem; }
.pm-remind-go { font: inherit; font-weight: 700; padding: .5rem 1rem; border-radius: 999px; border: 0; background: var(--pm-accent); color: var(--pm-accent-ink); cursor: pointer; }
.pm-remind-go:disabled { opacity: .6; cursor: wait; }
.pm-remind-no { font: inherit; padding: .5rem .9rem; border-radius: 999px; border: 1px solid var(--pm-border); background: none; color: var(--pm-ink); cursor: pointer; }
.pm-remind button:focus-visible, .pm-remind input:focus-visible, .pm-remind a:focus-visible { outline: 2px solid var(--pm-accent); outline-offset: 2px; }
.pm-remind-msg { color: var(--pm-warn, #a15c00) !important; font-weight: 600; margin: .3rem 0 0 !important; min-height: 0; }
.pm-remind-msg:empty { display: none; }
.pm-remind-small { font-size: .82rem; margin: .4rem 0 0 !important; }
.pm-remind-done { color: var(--pm-ink) !important; font-weight: 600; }
@media (max-width: 520px) { .pm-remind { right: .5rem; left: .5rem; bottom: .5rem; width: auto; } }

/* Next price cap: what changes on the next cap date. */
.pm-capnext { margin: .8rem 0 0; padding: .85rem 1rem .9rem; border-radius: 16px; background: var(--pm-surface); border: 1px solid var(--pm-border); font-size: .9rem; }
.pm-capnext-down { }
.pm-capnext > b { display: block; font-size: 1rem; margin-bottom: .2rem; }
.pm-capnext p { margin: 0 0 .55rem; color: var(--pm-ink2); line-height: 1.45; }
.pm-capnext p:last-child { margin-bottom: 0; }
.pm-capnext button { font: inherit; font-weight: 700; font-size: .85rem; padding: .35rem .9rem; border-radius: 999px; border: 1px solid var(--pm-forest); background: var(--pm-forest); color: var(--pm-bg); cursor: pointer; margin-right: .7rem; }
.pm-capnext a { font-size: .82rem; color: var(--pm-ink2); }
.pm-card .pm-capnext { margin-top: .9rem; }
.pm-hero-left .pm-capnext { margin-bottom: .9rem; }

/* Partner pages (/octopus): plain independence and affiliate note under the map. */
.pm-affiliate-note { margin: 1.5rem 0 .5rem; padding: 1rem 1.2rem; border: 1px solid var(--pm-border); border-radius: 14px; background: var(--pm-surface); color: var(--pm-ink2); font-size: .92rem; }
.pm-affiliate-note h2 { font-size: 1rem; margin: 0 0 .4rem; color: var(--pm-ink); }
.pm-affiliate-note p { margin: .35rem 0; }

/* Partner logo badge: the logo on its own dark plate (Octopus's logo is made for dark backgrounds), never on our cream. */
.pm-partner-badge { display: flex; align-items: center; justify-content: space-between; gap: .8rem; margin: .6rem 0; font-size: .85rem; font-weight: 700; color: var(--pm-ink2); }
.pm-partner-logo { display: inline-flex; padding: .55rem .8rem; border-radius: 12px; background: #100030; }
.pm-partner-logo img { display: block; height: auto; }

/* Estimated saving from 1 Jan if the cap rises as forecast (only until Ofgem confirms). */
.pm-save-jan { display: block; color: var(--pm-good); font-size: .78rem; font-weight: 700; }

/* Partner offers (Conectia brands): labelled as ads, plain cards, terms folded away. */
.pm-offers { margin: 1rem 0; }
.pm-offers-h { display: flex; align-items: center; justify-content: space-between; font-size: .78rem; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; color: var(--pm-ink2); margin-bottom: .45rem; }
.pm-ad { font-size: .7rem; letter-spacing: .04em; padding: .1rem .45rem; border: 1px solid var(--pm-border); border-radius: 6px; color: var(--pm-muted); }
.pm-offer { padding: .8rem .9rem; border: 1px solid var(--pm-border); border-radius: 14px; background: var(--pm-surface); margin-bottom: .6rem; }
.pm-offer-top { display: flex; align-items: center; gap: .7rem; margin-bottom: .35rem; }
.pm-offer-top img { border-radius: 8px; flex: none; }
.pm-offer-brand { font-size: 1rem; }
.pm-offer-head { font-weight: 800; color: var(--pm-ink); }
.pm-offer p { margin: .3rem 0; font-size: .86rem; color: var(--pm-ink2); line-height: 1.45; }
.pm-offer-cta { display: inline-block; margin-top: .35rem; text-decoration: none; }
.pm-offer-terms { margin-top: .5rem; font-size: .76rem; }
.pm-offer-terms summary { cursor: pointer; color: var(--pm-ink2); font-weight: 700; }
.pm-offer-terms p { font-size: .74rem; }

/* Octopus affiliate disclaimer under the hero (required by Octopus's affiliate guidelines) */
.pm-octo-disclaimer { margin: .6rem 0 0; font-size: .85rem; color: var(--pm-muted); }
.pm-octo-disclaimer a { color: inherit; text-decoration: underline; }
.pm-ad-tag { display: inline-block; font-size: .72rem; font-weight: 800; letter-spacing: .03em; text-transform: uppercase; padding: .1rem .45rem; border-radius: 6px; background: var(--pm-soft); color: var(--pm-ink, inherit); margin-right: .35rem; }

/* Grants table on phones: one card per scheme instead of a squeezed six-column table */
@media (max-width: 680px) {
  .pm-table-scroll { overflow-x: visible; }
  .pm-grant-table thead { display: none; }
  .pm-grant-table, .pm-grant-table tbody, .pm-grant-table tr, .pm-grant-table td { display: block; width: 100%; box-sizing: border-box; }
  .pm-grant-table tr { background: var(--pm-surface); border: 1px solid var(--pm-border); border-radius: 14px; padding: .35rem .9rem .6rem; margin: 0 0 .8rem; }
  .pm-grant-table td { border: 0; padding: .3rem 0; }
  .pm-grant-table td[data-label]:not(:first-child) { display: flex; gap: .75rem; justify-content: space-between; }
  .pm-grant-table td[data-label]:not(:first-child)::before { content: attr(data-label); flex: none; font-size: .75rem; font-weight: 700; text-transform: uppercase; letter-spacing: .4px; color: var(--pm-muted); padding-top: .1rem; }
  .pm-grant-table td:first-child { padding-top: .5rem; }
  .pm-grant-table td:nth-child(3) { white-space: normal; }
  .pm-grant-table td[data-label]:not(:first-child) { text-align: right; }
}

/* Phones: keep the top menu to the four main pages so nothing is cut off; About and How we make money stay in the footer */
@media (max-width: 520px) {
  .pm-nav-links .pm-nav-wide { display: none; }
  .pm-nav-links { -webkit-mask-image: none; mask-image: none; justify-content: space-between; }
}
