/* ==========================================================================
   Upgrader.ie — Site-wide styles
   Design tokens + shared header/footer + homepage sections.
   No framework/build step: plain, semantic, mobile-first CSS.
   ========================================================================== */

:root {
  /* Brand */
  --up-green: #188942;
  --up-green-dark: #126c34;
  --up-green-light: #e8f5ec;
  --up-charcoal: #1c2321;
  --up-charcoal-soft: #3a4340;
  --up-body: #4b5450;

  /* Warm accent tints — variety for cards further down the page */
  --up-amber: #b5871f;
  --up-amber-light: #faf3e2;
  --up-teal: #1b8aa8;
  --up-teal-light: #e6f2f5;
  --up-clay: #a5522f;
  --up-clay-light: #f7e9e2;

  /* Neutrals */
  --up-white: #ffffff;
  --up-off-white: #f7f8f7;
  --up-cream: #faf8f4;
  --up-mist: #f0f4f6;
  --up-border: #e3e7e4;

  /* Type */
  --font-sans: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --font-display: "Fraunces", Georgia, "Times New Roman", serif;

  /* Layout */
  --max-width: 1360px;
  --gutter: clamp(1.25rem, 4vw, 3rem);
  --section-pad: 3rem;
  --section-pad-panel: 2.25rem;
  --radius-sm: 10px;
  --radius-md: 16px;
  --radius-lg: 26px;
  --radius-xl: 32px;
  --shadow-sm: 0 1px 2px rgba(28, 35, 33, 0.06), 0 1px 1px rgba(28, 35, 33, 0.04);
  --shadow-md: 0 10px 28px rgba(28, 35, 33, 0.09);
  --shadow-lg: 0 24px 60px rgba(28, 35, 33, 0.18);

  --transition: 180ms ease;
}

/* --------------------------------------------------------------------- */
/* Reset                                                                  */
/* --------------------------------------------------------------------- */

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

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font-sans);
  color: var(--up-body);
  background: var(--up-white);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img {
  max-width: 100%;
  display: block;
}

a {
  color: inherit;
  text-decoration: none;
}

ul {
  margin: 0;
  padding: 0;
  list-style: none;
}

h1, h2, h3, h4 {
  color: var(--up-charcoal);
  line-height: 1.15;
  margin: 0 0 0.6em;
  font-family: var(--font-display);
  font-weight: 600;
  letter-spacing: -0.01em;
  text-wrap: balance;
}

h1 {
  font-weight: 620;
}

p {
  margin: 0 0 1em;
}

button {
  font-family: inherit;
}

/* Focus states — visible everywhere, no exceptions */
a:focus-visible,
button:focus-visible,
input:focus-visible,
summary:focus-visible {
  outline: 3px solid var(--up-green);
  outline-offset: 2px;
  border-radius: 4px;
}

.skip-link {
  position: absolute;
  left: 1rem;
  top: 1rem;
  background: var(--up-charcoal);
  color: var(--up-white);
  padding: 0.75rem 1.25rem;
  border-radius: var(--radius-sm);
  z-index: 1000;
  /* Pushed off-screen by a large multiple of its own height (rather than a
     fixed rem offset) so no sliver of it can ever peek into the viewport,
     regardless of its rendered height. */
  transform: translateY(-999%);
  transition: transform var(--transition);
}

.skip-link:focus {
  transform: translateY(0);
}

/* --------------------------------------------------------------------- */
/* Layout helpers                                                        */
/* --------------------------------------------------------------------- */

.wrap {
  max-width: var(--max-width);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

section {
  padding-block: var(--section-pad);
}

@media (min-width: 640px) {
  :root {
    --section-pad: 3.75rem;
    --section-pad-panel: 2.75rem;
  }
}

@media (min-width: 1024px) {
  :root {
    --section-pad: 4.5rem;
    --section-pad-panel: 3.25rem;
  }
}

/* Large feature panels (grants band, final CTA) already carry their own
   background/shadow separation, so the section wrapping them needs less
   outer whitespace than a standard text section. */
section:has(> .wrap > .grants-band),
section:has(> .wrap > .final-cta) {
  padding-block: var(--section-pad-panel);
}

.section-head {
  max-width: 640px;
  margin-bottom: clamp(2.25rem, 4vw, 3.5rem);
}

.section-head.center {
  margin-inline: auto;
  text-align: center;
}

.section-head h2 {
  font-size: clamp(1.9rem, 3.4vw, 2.6rem);
}

.eyebrow {
  display: inline-block;
  color: var(--up-green-dark);
  font-family: var(--font-sans);
  font-weight: 700;
  font-size: 0.8rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  margin-bottom: 0.85rem;
}

.eyebrow::before {
  content: "";
  display: inline-block;
  width: 1.4em;
  height: 2px;
  background: currentColor;
  margin-right: 0.6em;
  vertical-align: middle;
  opacity: 0.6;
}

.section-head p {
  font-size: 1.1rem;
}

.bg-soft {
  background: var(--up-off-white);
}

/* --------------------------------------------------------------------- */
/* Buttons                                                                */
/* --------------------------------------------------------------------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.95rem 1.85rem;
  border-radius: 999px;
  font-weight: 600;
  font-size: 1.02rem;
  border: 2px solid transparent;
  cursor: pointer;
  transition: transform var(--transition), background var(--transition), border-color var(--transition), color var(--transition), box-shadow var(--transition);
  white-space: nowrap;
}

.btn-primary {
  background: var(--up-green);
  color: var(--up-white);
  box-shadow: var(--shadow-sm);
}

.btn-primary:hover {
  background: var(--up-green-dark);
  transform: translateY(-1px);
}

.btn-secondary {
  background: transparent;
  color: var(--up-charcoal);
  border-color: var(--up-border);
}

.btn-secondary:hover {
  border-color: var(--up-charcoal);
  transform: translateY(-1px);
}

.btn-on-dark {
  background: var(--up-white);
  color: var(--up-charcoal);
}

.btn-on-dark:hover {
  background: var(--up-green-light);
  transform: translateY(-1px);
}

.btn-outline-on-dark {
  background: transparent;
  color: var(--up-white);
  border-color: rgba(255, 255, 255, 0.5);
}

.btn-outline-on-dark:hover {
  border-color: var(--up-white);
  transform: translateY(-1px);
}

.link-arrow {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-weight: 600;
  color: var(--up-green-dark);
}

.link-arrow svg {
  transition: transform var(--transition);
}

.link-arrow:hover svg {
  transform: translateX(3px);
}

/* --------------------------------------------------------------------- */
/* Header                                                                 */
/* --------------------------------------------------------------------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: saturate(180%) blur(10px);
  border-bottom: 1px solid var(--up-border);
}

.site-header .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.85rem;
  padding-block: 0.85rem;
}

.logo {
  flex-shrink: 0;
}

.logo img {
  height: 40px;
  width: auto;
}

@media (min-width: 820px) {
  .logo img {
    height: 48px;
  }
}

@media (min-width: 1100px) {
  .site-header .wrap {
    gap: 1.5rem;
    padding-block: 0.4rem;
  }

  .logo img {
    height: 58px;
  }
}

.primary-nav {
  display: none;
}

.primary-nav ul {
  display: flex;
  align-items: center;
  gap: 1.5rem;
}

.primary-nav a {
  display: inline-block;
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--up-charcoal-soft);
  padding-block: 0.4rem;
  border-bottom: 2px solid transparent;
  transition: color var(--transition), border-color var(--transition);
}

.primary-nav a:hover {
  color: var(--up-green-dark);
  border-color: var(--up-green);
}

/* Home Upgrades dropdown — native <details>/<summary>, keyboard- and
   screen-reader-accessible with no custom ARIA required. */
.nav-dropdown {
  position: relative;
}

.nav-dropdown-toggle {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--up-charcoal-soft);
  padding-block: 0.4rem;
  border-bottom: 2px solid transparent;
  cursor: pointer;
  list-style: none;
  transition: color var(--transition), border-color var(--transition);
}

.nav-dropdown-toggle::-webkit-details-marker {
  display: none;
}

.nav-dropdown-toggle svg {
  transition: transform var(--transition);
  flex-shrink: 0;
}

.nav-dropdown:hover .nav-dropdown-toggle,
.nav-dropdown-toggle:focus-visible {
  color: var(--up-green-dark);
  border-color: var(--up-green);
}

.nav-dropdown[open] .nav-dropdown-toggle svg {
  transform: rotate(180deg);
}

.nav-dropdown-menu {
  position: absolute;
  top: calc(100% + 0.6rem);
  left: 0;
  z-index: 60;
  min-width: 210px;
  background: var(--up-white);
  border: 1px solid var(--up-border);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-md);
  padding: 0.5rem;
}

.nav-dropdown-menu li a {
  display: block;
  padding: 0.65rem 0.85rem;
  border-radius: var(--radius-sm);
  font-weight: 600;
  font-size: 0.94rem;
  color: var(--up-charcoal-soft);
  border-bottom: none;
}

.nav-dropdown-menu li a:hover,
.nav-dropdown-menu li a:focus-visible {
  background: var(--up-green-light);
  color: var(--up-green-dark);
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.header-actions .btn {
  padding: 0.65rem 1.3rem;
  font-size: 0.9rem;
}

.header-actions .btn-secondary {
  display: none;
}

@media (max-width: 399px) {
  .header-actions {
    gap: 0.5rem;
  }

  .header-actions .btn {
    padding: 0.6rem 0.85rem;
    font-size: 0.85rem;
  }
}

/* Below 360px the logo plus the Find Installers button and menu toggle no
   longer fit on one line at the standard gutter, causing page-wide
   horizontal overflow. Tighten only the header's own spacing at this
   narrow range; 360px and above are untouched. */
@media (max-width: 359px) {
  .site-header .wrap {
    padding-inline: 0.7rem;
    gap: 0.45rem;
  }

  .header-actions {
    gap: 0.3rem;
  }

  .header-actions .btn-primary {
    padding: 0.5rem 0.6rem;
    font-size: 0.7rem;
  }
}

.nav-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border: 1px solid var(--up-border);
  border-radius: var(--radius-sm);
  background: var(--up-white);
  cursor: pointer;
}

.nav-toggle svg {
  width: 22px;
  height: 22px;
}

.mobile-nav {
  display: none;
  border-top: 1px solid var(--up-border);
  background: var(--up-white);
}

.mobile-nav.is-open {
  display: block;
}

.mobile-nav ul {
  padding: 0.5rem var(--gutter) 1.25rem;
  display: flex;
  flex-direction: column;
}

.mobile-nav a {
  display: block;
  padding: 0.75rem 0;
  font-weight: 600;
  color: var(--up-charcoal-soft);
  border-bottom: 1px solid var(--up-border);
}

.mobile-nav .mobile-cta {
  margin-top: 1rem;
  display: flex;
  gap: 0.75rem;
}

/* Home Upgrades accordion inside the mobile menu */
.mobile-nav-dropdown {
  border-bottom: 1px solid var(--up-border);
}

.mobile-nav-dropdown-toggle {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  padding: 0.75rem 0;
  font-weight: 600;
  color: var(--up-charcoal-soft);
  cursor: pointer;
  list-style: none;
}

.mobile-nav-dropdown-toggle::-webkit-details-marker {
  display: none;
}

.mobile-nav-dropdown-toggle svg {
  transition: transform var(--transition);
  flex-shrink: 0;
  color: var(--up-charcoal-soft);
}

.mobile-nav-dropdown[open] .mobile-nav-dropdown-toggle svg {
  transform: rotate(180deg);
}

.mobile-nav-dropdown-menu {
  padding-bottom: 0.5rem;
}

.mobile-nav-dropdown-menu li a {
  padding: 0.65rem 0 0.65rem 1rem;
  border-bottom: none;
  font-weight: 500;
  font-size: 0.95rem;
}

@media (min-width: 1100px) {
  .primary-nav {
    display: block;
  }

  .nav-toggle {
    display: none;
  }
}

@media (min-width: 1300px) {
  .header-actions .btn-secondary {
    display: inline-flex;
  }
}

/* --------------------------------------------------------------------- */
/* Hero                                                                   */
/* --------------------------------------------------------------------- */

.hero {
  position: relative;
  overflow: hidden;
  /* The hero's own copy block and full-bleed photo already provide top/
     bottom breathing room, so the standard section padding would double
     up here. */
  padding-block: 0;
}

.hero .wrap {
  position: relative;
  z-index: 1;
}

.hero-copy {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding-block: clamp(2.25rem, 5vw, 3rem);
}

.hero-copy h1 {
  font-size: clamp(2.5rem, 4.6vw, 4rem);
  max-width: 15ch;
  line-height: 1.06;
}

.hero-copy .lede {
  font-size: 1.2rem;
  max-width: 44ch;
  color: var(--up-body);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  margin-top: 2rem;
}

.hero-trust {
  margin-top: 2.5rem;
  display: flex;
  flex-wrap: wrap;
  gap: 1.5rem 2rem;
}

.hero-trust-item {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-size: 0.92rem;
  font-weight: 600;
  color: var(--up-charcoal-soft);
}

.hero-trust-item svg {
  flex-shrink: 0;
  color: var(--up-green);
}

/* Photo: plain, full-width, stacked below the copy on small screens */
.hero-photo {
  position: relative;
  width: 100%;
  aspect-ratio: 4 / 3;
}

.hero-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 58% 20%;
  display: block;
}

.hero-scrim {
  display: none;
}

@media (min-width: 860px) {
  .hero {
    display: flex;
    align-items: center;
    --hero-h: clamp(480px, 26vw, 500px);
    height: var(--hero-h);
  }

  .hero .wrap {
    width: 100%;
  }

  .hero-copy {
    max-width: 600px;
    padding-block: 0;
  }

  .hero-copy h1 {
    font-size: clamp(2.1rem, 3vw, 2.75rem);
    margin-bottom: 0.4em;
  }

  .hero-copy .lede {
    font-size: 1.05rem;
    margin-bottom: 0;
  }

  .hero-actions {
    margin-top: 1.5rem;
  }

  .hero-trust {
    margin-top: 1.5rem;
  }

  /* Full-bleed photo layer behind the whole section. The image is shown at
     its own natural aspect ratio (no cover-crop, no transform/scale) and
     anchored to the right edge of the viewport, so it always reaches the
     right edge with zero gap regardless of viewport width, instead of a
     left-percentage offset (whose gap to the right edge grew with viewport
     width). The white fade is a separate overlay on top and never affects
     how the photo is cropped. */
  .hero-photo {
    position: absolute;
    inset: 0;
    aspect-ratio: auto;
    z-index: 0;
  }

  .hero-photo img {
    position: absolute;
    top: 0;
    right: 0;
    left: auto;
    width: auto;
    max-width: none;
    height: 100%;
    object-fit: initial;
    object-position: initial;
  }

  /* Sized and positioned to exactly match the image's own box (same
     right:0 anchor, same aspect-ratio-derived width via --hero-h) so the
     fade always sits precisely at the photo's real left edge, however
     wide that photo happens to be at a given viewport, instead of being
     a fixed percentage of the much wider hero section. */
  .hero-scrim {
    display: block;
    position: absolute;
    top: 0;
    right: 0;
    height: var(--hero-h);
    width: calc(var(--hero-h) * 1672 / 941);
    background: linear-gradient(
      90deg,
      var(--up-white) 0%,
      var(--up-white) 6%,
      rgba(255, 255, 255, 0.88) 18%,
      rgba(255, 255, 255, 0.6) 28%,
      rgba(255, 255, 255, 0.28) 38%,
      rgba(255, 255, 255, 0) 48%
    );
  }
}

@media (min-width: 1160px) {
  .hero-copy {
    max-width: 640px;
  }
}

/* --------------------------------------------------------------------- */
/* Category cards                                                        */
/* --------------------------------------------------------------------- */

.category-grid {
  display: grid;
  gap: 1.5rem;
  grid-template-columns: repeat(2, 1fr);
}

.category-card {
  border-radius: var(--radius-lg);
  overflow: hidden;
  background: var(--up-white);
  box-shadow: var(--shadow-md);
  transition: box-shadow var(--transition), transform var(--transition);
  display: flex;
  flex-direction: column;
}

.category-card:hover {
  box-shadow: var(--shadow-lg);
  transform: translateY(-4px);
}

.category-media {
  min-height: 108px;
  position: relative;
  color: var(--up-white);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 0.85rem 1.1rem 0.8rem;
}

.category-media::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(10, 16, 12, 0.55) 0%, rgba(10, 16, 12, 0.05) 70%);
}

.category-icon {
  display: inline-flex;
  position: relative;
  z-index: 1;
  width: 30px;
  height: 30px;
  opacity: 0.9;
  flex-shrink: 0;
}

.category-icon svg {
  width: 100%;
  height: 100%;
}

.category-overlay {
  position: relative;
  z-index: 1;
}

.category-overlay .category-tag {
  display: block;
  font-size: 0.66rem;
  font-weight: 700;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  opacity: 0.85;
  margin-bottom: 0.25rem;
}

.category-overlay h3 {
  color: var(--up-white);
  font-size: 1.15rem;
  margin-bottom: 0;
}

.category-media--solar {
  background: linear-gradient(155deg, #a46900 0%, #8b5800 55%, #704700 100%);
}

.category-media--heatpump {
  background: linear-gradient(155deg, #137b9b 0%, #0f6c8c 55%, #0b5875 100%);
}

.category-media--insulation {
  background: linear-gradient(155deg, #a13d4f 0%, #853041 55%, #6e2635 100%);
}

.category-media--windows {
  background: linear-gradient(155deg, #2b3a55 0%, #435d84 55%, #6c85ac 100%);
}

.category-media--service-electricity {
  background: linear-gradient(155deg, #c2410c 0%, #ac3a0f 55%, #9a3412 100%);
}

.category-media--service-broadband {
  background: linear-gradient(155deg, #1d4ed8 0%, #1e43ad 55%, #1e3a8a 100%);
}

.category-media--service-waste {
  background: linear-gradient(155deg, #2e6b48 0%, #215b3c 55%, #174d32 100%);
}

.category-media--service-insurance {
  background: linear-gradient(155deg, #3d3166 0%, #5b4a94 55%, #8172bd 100%);
}

.category-body {
  padding: 1rem 1.1rem 1.25rem;
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
  flex: 1;
}

.category-body p {
  font-size: 0.9rem;
  flex: 1;
}

@media (max-width: 640px) {
  .category-grid {
    grid-template-columns: 1fr;
  }
}

@media (min-width: 1024px) {
  .category-grid {
    grid-template-columns: repeat(4, 1fr);
    gap: 1.5rem;
  }

  .category-overlay h3 {
    font-size: 1.05rem;
  }
}

/* --------------------------------------------------------------------- */
/* Benefits                                                               */
/* --------------------------------------------------------------------- */

.benefit-grid {
  display: grid;
  gap: 1.5rem;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
}

.benefit-card {
  padding: 1.5rem 1.75rem;
  background: var(--up-white);
  border: 1px solid var(--up-border);
  border-top: 3px solid var(--up-green);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  transition: box-shadow var(--transition), transform var(--transition);
}

.benefit-card:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-3px);
}

.benefit-label {
  display: block;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--up-green);
  margin-bottom: 0.5rem;
}

.benefit-card h3 {
  font-size: 1.15rem;
}

.benefit-card p {
  font-size: 0.96rem;
  margin-bottom: 0;
}

/* --------------------------------------------------------------------- */
/* Latest data                                                           */
/* Editorial, research-led snapshot: three Home Upgrade stat cards carry */
/* the visual weight; Broadband shares the same card treatment as the   */
/* three Home Upgrade cards, distinguished only by its own accent colour */
/* and its Home Services tag.                                           */
/* --------------------------------------------------------------------- */

.data-grid {
  display: grid;
  gap: 1.5rem;
  grid-template-columns: 1fr;
}

.data-card {
  position: relative;
  overflow: hidden;
  padding: 1.85rem 1.6rem 1.6rem;
  background: var(--up-white);
  border: 1px solid var(--up-border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  display: flex;
  flex-direction: column;
  transition: box-shadow var(--transition), transform var(--transition);
}

.data-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: var(--accent, var(--up-green));
}

.data-card:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-3px);
}

.data-card--solar {
  --accent: var(--up-green);
}

.data-card--heatpump {
  --accent: var(--up-teal);
}

.data-card--efficiency {
  --accent: var(--up-clay);
}

.data-card--broadband {
  --accent: var(--up-charcoal-soft);
}

.data-card-tag {
  display: inline-block;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--accent, var(--up-green-dark));
  margin-bottom: 1rem;
}

.data-stat {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(2.1rem, 4.5vw, 2.6rem);
  line-height: 1;
  color: var(--up-charcoal);
  margin-bottom: 0.5rem;
}

.data-card h3 {
  font-size: 1.08rem;
  margin-bottom: 0.55rem;
}

.data-detail {
  font-size: 0.92rem;
  color: var(--up-body);
  margin-bottom: 1.1rem;
  flex: 1;
}

.data-source {
  font-size: 0.78rem;
  color: var(--up-charcoal-soft);
  margin-bottom: 0;
  padding-top: 0.9rem;
  border-top: 1px solid var(--up-border);
}

.data-takeaway {
  margin-top: 2.5rem;
  max-width: 860px;
  margin-inline: auto;
}

.data-takeaway-label {
  display: block;
  font-weight: 700;
  font-size: 0.82rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--up-green-dark);
  margin-bottom: 0.65rem;
}

.data-takeaway p {
  font-size: 1.04rem;
  color: var(--up-charcoal-soft);
  margin-bottom: 0;
}

.data-freshness {
  margin-top: 1.5rem;
  max-width: 860px;
  margin-inline: auto;
  font-size: 0.82rem;
  color: var(--up-charcoal-soft);
  opacity: 0.85;
  margin-bottom: 0;
}

@media (min-width: 640px) {
  .data-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 1024px) {
  .data-grid {
    grid-template-columns: repeat(4, 1fr);
  }
}

/* --------------------------------------------------------------------- */
/* Grants band                                                           */
/* --------------------------------------------------------------------- */

.grants-band {
  position: relative;
  overflow: hidden;
  background: radial-gradient(120% 160% at 100% 0%, #1f6b3c 0%, var(--up-charcoal) 55%);
  color: rgba(255, 255, 255, 0.85);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-lg);
}

.grants-band-icon {
  position: absolute;
  right: clamp(-3rem, -1vw, 1rem);
  top: 50%;
  transform: translateY(-50%);
  width: clamp(180px, 20vw, 280px);
  height: clamp(180px, 20vw, 280px);
  opacity: 0.14;
  color: var(--up-white);
  pointer-events: none;
}

.grants-band-icon svg {
  width: 100%;
  height: 100%;
}

.grants-band .wrap {
  position: relative;
  max-width: none;
  padding: clamp(2.75rem, 6vw, 4.5rem);
  display: grid;
  gap: 2rem;
  align-items: center;
}

.grants-band h2,
.grants-band .eyebrow {
  color: var(--up-white);
}

.grants-band .eyebrow {
  color: #9fe0b8;
}

.grants-band h2 {
  font-size: clamp(1.9rem, 3.2vw, 2.4rem);
}

.grants-band p {
  color: rgba(255, 255, 255, 0.78);
  font-size: 1.08rem;
  max-width: 56ch;
}

.grants-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.9rem;
}

@media (min-width: 860px) {
  .grants-band .wrap {
    grid-template-columns: 1.4fr auto;
  }
}

/* --------------------------------------------------------------------- */
/* How it works                                                          */
/* --------------------------------------------------------------------- */

.steps-grid {
  display: grid;
  gap: 1.5rem;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  counter-reset: step;
}

.step-card {
  position: relative;
  padding: 2rem 1.75rem 1.75rem;
  background: var(--up-cream);
  border: 1px solid var(--up-border);
  border-radius: var(--radius-lg);
}

/* Solar PV page only: fresher pale cool blue-grey neutral in place of the
   warm cream used elsewhere (e.g. the homepage's own step cards). */
.page-solar-pv .step-card {
  background: var(--up-mist);
}

.step-number {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: var(--up-green);
  color: var(--up-white);
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.2rem;
  margin-bottom: 1.25rem;
  box-shadow: var(--shadow-sm);
}

.step-card h3 {
  font-size: 1.12rem;
}

.step-card p {
  font-size: 0.96rem;
  margin-bottom: 0;
}

@media (min-width: 1024px) {
  .steps-grid {
    grid-template-columns: repeat(12, 1fr);
  }

  .steps-grid .step-card {
    grid-column: span 3;
  }

  .steps-grid .step-card:nth-child(n + 5) {
    grid-column: span 4;
  }
}

/* Solar PV page only: the same deliberate 4-then-3 row pattern used at    */
/* desktop, extended down to tablet so the seven installation steps never  */
/* leave a single orphaned card on its own row at this width.              */
@media (min-width: 768px) and (max-width: 1023px) {
  .page-solar-pv .steps-grid {
    grid-template-columns: repeat(12, 1fr);
  }

  .page-solar-pv .steps-grid .step-card {
    grid-column: span 3;
  }

  .page-solar-pv .steps-grid .step-card:nth-child(n + 5) {
    grid-column: span 4;
  }
}

.feature-photo {
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  aspect-ratio: 21 / 9;
  margin: 2rem 0 2.75rem;
}

.feature-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* --------------------------------------------------------------------- */
/* Guides                                                                 */
/* --------------------------------------------------------------------- */

.guides-grid {
  display: grid;
  gap: 1.25rem;
  grid-template-columns: repeat(2, 1fr);
}

.guide-card {
  border-radius: var(--radius-md);
  overflow: hidden;
  background: var(--up-white);
  box-shadow: var(--shadow-sm);
  transition: box-shadow var(--transition), transform var(--transition);
  display: flex;
  flex-direction: column;
}

.guide-card:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-3px);
}

.guide-media {
  aspect-ratio: 21 / 8;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--up-white);
}

.guide-media::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(10, 16, 12, 0.5) 0%, rgba(10, 16, 12, 0) 45%);
}

.guide-media svg {
  width: 26px;
  height: 26px;
  opacity: 0.9;
}

.guide-tag {
  position: absolute;
  top: 0.7rem;
  left: 0.7rem;
  z-index: 1;
  background: rgba(255, 255, 255, 0.95);
  color: var(--up-charcoal-soft);
  font-size: 0.62rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: 0.28rem 0.6rem;
  border-radius: 999px;
  box-shadow: var(--shadow-sm);
}

.guide-body {
  padding: 1rem 1.1rem 1.25rem;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.guide-body h3 {
  font-size: 1rem;
  margin-bottom: 0.4rem;
}

.guide-body p {
  font-size: 0.85rem;
  margin-bottom: 0.75rem;
  flex: 1;
}

@media (max-width: 640px) {
  .guides-grid {
    grid-template-columns: 1fr;
  }
}

@media (min-width: 1024px) {
  .guides-grid {
    grid-template-columns: repeat(4, 1fr);
  }
}

/* --------------------------------------------------------------------- */
/* Household services                                                    */
/* Distinct from the photo-led Home Upgrade cards on purpose — these are */
/* a separate, lighter-weight product tier. Built with headroom for a    */
/* future secondary action (e.g. "Compare options") without a redesign.  */
/* --------------------------------------------------------------------- */

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

@media (max-width: 640px) {
  .service-grid {
    grid-template-columns: 1fr;
  }
}

@media (min-width: 1024px) {
  .service-grid {
    grid-template-columns: repeat(4, 1fr);
  }
}

/* --------------------------------------------------------------------- */
/* Find installers                                                       */
/* --------------------------------------------------------------------- */

.installers {
  display: grid;
  gap: clamp(2.5rem, 5vw, 4rem);
  align-items: center;
}

.installers-media {
  aspect-ratio: 4 / 3;
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
}

.installers-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 62% 42%;
  display: block;
}

.installers-list {
  display: grid;
  gap: 0.9rem;
  margin: 1.5rem 0 2rem;
}

.installers-list li {
  display: flex;
  align-items: flex-start;
  gap: 0.7rem;
  font-size: 0.96rem;
  color: var(--up-charcoal-soft);
}

.installers-list svg {
  color: var(--up-green);
  flex-shrink: 0;
  margin-top: 0.15rem;
}

.disclosure-note {
  font-size: 0.85rem;
  color: var(--up-charcoal-soft);
  background: var(--up-off-white);
  border: 1px solid var(--up-border);
  border-radius: var(--radius-sm);
  padding: 0.9rem 1.1rem;
  margin-top: 1.5rem;
}

@media (min-width: 900px) {
  .installers {
    grid-template-columns: 1fr 1fr;
  }

  .installers.reverse .installers-media {
    order: 2;
  }
}

/* --------------------------------------------------------------------- */
/* Placeholder tiles (used where real photography has not been supplied) */
/* --------------------------------------------------------------------- */

.placeholder-tile {
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--up-white);
}

.placeholder-tile svg {
  width: 48px;
  height: 48px;
  opacity: 0.9;
}

/* --------------------------------------------------------------------- */
/* Final CTA                                                             */
/* --------------------------------------------------------------------- */

.final-cta {
  background: linear-gradient(155deg, var(--up-green) 0%, var(--up-green-dark) 100%);
  color: var(--up-white);
  border-radius: var(--radius-xl);
  text-align: center;
  box-shadow: var(--shadow-lg);
}

.final-cta .wrap {
  max-width: 720px;
  padding-block: clamp(3rem, 6vw, 4.5rem);
}

.final-cta h2 {
  color: var(--up-white);
  font-size: clamp(1.8rem, 3.6vw, 2.4rem);
}

.final-cta p {
  color: rgba(255, 255, 255, 0.9);
  font-size: 1.05rem;
  max-width: 50ch;
  margin-inline: auto;
}

.final-cta .hero-actions {
  justify-content: center;
}

/* --------------------------------------------------------------------- */
/* Footer                                                                 */
/* --------------------------------------------------------------------- */

.site-footer {
  background: var(--up-charcoal);
  color: rgba(255, 255, 255, 0.75);
}

.footer-top {
  padding-block: clamp(3.5rem, 6vw, 5rem) 2.75rem;
  display: grid;
  gap: 2.75rem;
}

.footer-brand .logo img {
  height: 32px;
}

.footer-brand p {
  margin-top: 1rem;
  font-size: 0.92rem;
  color: rgba(255, 255, 255, 0.6);
  max-width: 34ch;
}

.footer-cols {
  display: grid;
  gap: 2rem;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
}

.footer-col h3 {
  color: var(--up-white);
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin-bottom: 1rem;
}

.footer-col ul {
  display: grid;
  gap: 0.65rem;
}

.footer-col a {
  font-size: 0.92rem;
  color: rgba(255, 255, 255, 0.68);
  transition: color var(--transition);
}

.footer-col a:hover {
  color: var(--up-white);
}

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  padding-block: 1.5rem;
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  align-items: center;
  justify-content: space-between;
  font-size: 0.82rem;
  color: rgba(255, 255, 255, 0.55);
}

.footer-bottom-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem 1.1rem;
}

@media (min-width: 820px) {
  .footer-top {
    grid-template-columns: 1.1fr 2fr;
  }
}

/* --------------------------------------------------------------------- */
/* Utility                                                                */
/* --------------------------------------------------------------------- */

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* ==========================================================================
   Solar PV hub page
   ========================================================================== */

/* --------------------------------------------------------------------- */
/* Breadcrumb                                                             */
/* --------------------------------------------------------------------- */

.breadcrumb-nav {
  font-size: 0.85rem;
  color: var(--up-charcoal-soft);
  padding-block: 1rem;
}

.breadcrumb-nav a {
  color: var(--up-green-dark);
  font-weight: 600;
}

.breadcrumb-nav a:hover {
  text-decoration: underline;
}

.breadcrumb-nav .crumb-sep {
  margin: 0 0.45rem;
  opacity: 0.5;
}

.breadcrumb-nav .crumb-current {
  color: var(--up-charcoal-soft);
}

/* --------------------------------------------------------------------- */
/* Page hero (photo sourced at a different aspect ratio to the homepage   */
/* hero. The box is sized using the same ratio as the homepage photo so   */
/* the white-to-photo fade begins at the same horizontal position on      */
/* both pages; the image is cover-cropped to fill that box cleanly since  */
/* its own natural ratio does not match it.)                              */
/* --------------------------------------------------------------------- */

.hero--page .hero-photo img {
  object-position: 78% 30%;
}

@media (min-width: 860px) {
  .hero--page .hero-photo img {
    width: calc(var(--hero-h) * 1672 / 941);
    object-fit: cover;
  }
}

/* --------------------------------------------------------------------- */
/* Design system tokens — standard widths and heading scale reused        */
/* across every editorial section below the hero.                        */
/* --------------------------------------------------------------------- */

.page-solar-pv {
  --solar-editorial-width: 45rem; /* ~720px: standard editorial text width */
  --solar-h2-size: clamp(1.75rem, 2.4vw, 2rem); /* one H2 scale for every major heading */
}

/* --------------------------------------------------------------------- */
/* Intro                                                                  */
/* --------------------------------------------------------------------- */

/* The editorial column itself is centred within the (much wider) .wrap,   */
/* while every element inside it (eyebrow, H2, paragraphs, lists,          */
/* callouts) stays left aligned, sharing one consistent left edge.         */
.page-intro {
  max-width: var(--solar-editorial-width);
  margin-inline: auto;
  text-align: left;
}

.page-intro > p:not(.disclosure-note) {
  font-size: 1.08rem;
}

.page-solar-pv .section-head {
  max-width: var(--solar-editorial-width);
  margin-inline: auto;
  text-align: left;
}

.page-solar-pv .section-head--tool {
  margin-top: clamp(2.5rem, 5vw, 3.5rem);
}

.page-solar-pv .section-head h2,
.page-intro h2,
.content-panel-copy h2 {
  font-size: var(--solar-h2-size);
}

/* --------------------------------------------------------------------- */
/* Content panel (media + copy, alternating sides)                       */
/* --------------------------------------------------------------------- */

.content-panel {
  display: grid;
  gap: clamp(2rem, 5vw, 3.5rem);
  align-items: start;
}

/* Every ordinary feature photograph on the page (Suitability, Generation,
   Batteries, Find Installers) renders at this same ratio, regardless of
   its native dimensions, so the photos read as one consistent system. */
.content-panel-media {
  aspect-ratio: 4 / 3;
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
}

.content-panel-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.content-panel-copy > p:not(.disclosure-note) {
  font-size: 1.08rem;
}

.factor-list {
  display: grid;
  gap: 0.85rem;
  margin: 1.25rem 0 0;
}

.factor-list li {
  display: flex;
  align-items: flex-start;
  gap: 0.7rem;
  font-size: 0.97rem;
  color: var(--up-charcoal-soft);
}

.factor-list svg {
  color: var(--up-green);
  flex-shrink: 0;
  margin-top: 0.15rem;
}

@media (min-width: 900px) {
  .content-panel {
    grid-template-columns: 1fr 1fr;
  }

  .content-panel.reverse .content-panel-media {
    order: 2;
  }
}

/* --------------------------------------------------------------------- */
/* Callouts                                                               */
/* --------------------------------------------------------------------- */

.callout {
  max-width: var(--solar-editorial-width, none);
  margin-top: 2rem;
  border-radius: var(--radius-md);
  padding: 1.35rem 1.5rem;
  font-size: 0.96rem;
  border: 1px solid var(--up-border);
}

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

.callout-label {
  display: block;
  font-weight: 700;
  font-size: 0.78rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  margin-bottom: 0.5rem;
}

.callout--info {
  background: var(--up-teal-light);
  border-color: rgba(27, 138, 168, 0.25);
}

.callout--info .callout-label {
  color: var(--up-teal);
}

.callout--caution {
  background: var(--up-amber-light);
  border-color: rgba(181, 135, 31, 0.3);
}

.callout--caution .callout-label {
  color: var(--up-amber);
}

.callout + .callout {
  margin-top: 1rem;
}

/* A callout that belongs to a whole section (media + copy row, or a two   */
/* column checklist) rather than to one text column: centred under the    */
/* full row instead of hugging the left edge of a text column.            */
.callout--section {
  margin-inline: auto;
}

/* --------------------------------------------------------------------- */
/* Component list (what a system includes)                               */
/* --------------------------------------------------------------------- */

.component-grid {
  display: grid;
  gap: 1.25rem;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  margin-top: 2rem;
}

.component-card {
  padding: 1.5rem;
  background: var(--up-mist);
  border: 1px solid var(--up-border);
  border-radius: var(--radius-lg);
}

.component-card .category-icon {
  margin-bottom: 1rem;
}

.component-card h3 {
  font-size: 1.12rem;
}

.component-card p {
  font-size: 0.94rem;
  margin-bottom: 0;
}

/* Desktop: 3 cards on the first row, 2 cards centred on the second row,   */
/* rather than an arbitrary auto-fit count based on viewport width.        */
@media (min-width: 1024px) {
  .component-grid {
    grid-template-columns: repeat(6, 1fr);
  }

  .component-card:nth-child(1) {
    grid-column: 1 / 3;
  }

  .component-card:nth-child(2) {
    grid-column: 3 / 5;
  }

  .component-card:nth-child(3) {
    grid-column: 5 / 7;
  }

  .component-card:nth-child(4) {
    grid-column: 2 / 4;
  }

  .component-card:nth-child(5) {
    grid-column: 4 / 6;
  }
}

/* --------------------------------------------------------------------- */
/* Quotation checklist                                                    */
/* --------------------------------------------------------------------- */

.checklist-grid {
  display: grid;
  gap: 0.6rem 2rem;
  margin-top: 2rem;
  grid-template-columns: 1fr;
}

.checklist-item {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  padding: 0.85rem 0;
  border-bottom: 1px solid var(--up-border);
}

.checklist-item svg {
  color: var(--up-green);
  flex-shrink: 0;
  margin-top: 0.2rem;
}

.checklist-item strong {
  color: var(--up-charcoal);
  display: block;
  font-size: 0.98rem;
}

.checklist-item span {
  font-size: 0.9rem;
  color: var(--up-charcoal-soft);
}

@media (min-width: 900px) {
  .checklist-grid {
    grid-template-columns: 1fr 1fr;
    column-gap: 3rem;
  }
}

/* --------------------------------------------------------------------- */
/* Solar Payback Explorer                                                 */
/* --------------------------------------------------------------------- */

.calculator {
  background: var(--up-mist);
  border: 1px solid var(--up-border);
  border-radius: var(--radius-xl);
  padding: clamp(1.5rem, 4vw, 2.75rem);
  margin-top: 2rem;
  display: grid;
  gap: 2.25rem;
}

.calc-form {
  display: grid;
  gap: 1.25rem;
}

.calc-field label {
  display: block;
  font-weight: 600;
  font-size: 0.92rem;
  color: var(--up-charcoal);
  margin-bottom: 0.4rem;
}

.calc-field .calc-hint {
  display: block;
  font-weight: 400;
  font-size: 0.82rem;
  color: var(--up-charcoal-soft);
  margin-top: 0.35rem;
}

.calc-field input {
  width: 100%;
  font: inherit;
  font-size: 1rem;
  padding: 0.7rem 0.85rem;
  border: 1px solid var(--up-border);
  border-radius: var(--radius-sm);
  background: var(--up-white);
  color: var(--up-charcoal);
}

.calc-field input:focus-visible {
  outline: 3px solid var(--up-green);
  outline-offset: 1px;
}

.calc-results {
  background: var(--up-white);
  border-radius: var(--radius-lg);
  padding: 1.75rem;
  box-shadow: var(--shadow-sm);
}

.calc-result-stat {
  margin-bottom: 1.5rem;
}

.calc-result-stat:last-of-type {
  margin-bottom: 0;
}

.calc-result-label {
  font-size: 0.82rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--up-green-dark);
}

.calc-result-value {
  font-family: var(--font-display);
  font-size: clamp(1.9rem, 4vw, 2.4rem);
  color: var(--up-charcoal);
  font-weight: 600;
  margin-top: 0.25rem;
}

.calc-result-note {
  font-size: 0.85rem;
  color: var(--up-charcoal-soft);
  margin-top: 1.25rem;
  padding-top: 1.25rem;
  border-top: 1px solid var(--up-border);
}

.calc-methodology {
  font-size: 0.9rem;
  color: var(--up-charcoal-soft);
  margin-top: 1.5rem;
}

.calc-methodology summary {
  cursor: pointer;
  font-weight: 600;
  color: var(--up-charcoal);
}

.calc-methodology[open] {
  border: 2px solid var(--up-green);
  border-radius: var(--radius-md);
  padding: 1rem 1.25rem;
}

.calc-methodology[open] summary {
  margin-bottom: 0.75rem;
}

.calc-methodology[open] p:last-child {
  margin-bottom: 0;
}

@media (min-width: 900px) {
  .calculator {
    grid-template-columns: 1.1fr 1fr;
  }
}

/* --------------------------------------------------------------------- */
/* FAQ accordion                                                          */
/* --------------------------------------------------------------------- */

.faq-list {
  display: grid;
  gap: 0.9rem;
  margin-top: 2rem;
  max-width: var(--solar-editorial-width, none);
  margin-inline: auto;
}

.faq-item {
  border: 1px solid var(--up-border);
  border-radius: var(--radius-md);
  padding: 0.3rem 1.4rem;
  background: var(--up-white);
}

.faq-item summary {
  cursor: pointer;
  padding-block: 1.1rem;
  font-weight: 600;
  color: var(--up-charcoal);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  list-style: none;
}

.faq-item summary::-webkit-details-marker {
  display: none;
}

.faq-item summary svg {
  flex-shrink: 0;
  transition: transform var(--transition);
  color: var(--up-green);
}

.faq-item[open] summary svg {
  transform: rotate(180deg);
}

.faq-item p {
  padding-bottom: 1.1rem;
  margin: 0;
  font-size: 0.96rem;
}

/* --------------------------------------------------------------------- */
/* Stat analysis card                                                     */
/* --------------------------------------------------------------------- */

.stat-analysis {
  display: grid;
  gap: 2rem;
  align-items: center;
  background: var(--up-off-white);
  border-radius: var(--radius-xl);
  padding: clamp(1.75rem, 4vw, 2.75rem);
}

.stat-analysis-figure {
  text-align: center;
  padding: 1.5rem;
  background: var(--up-white);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
}

.stat-analysis-figure .data-stat {
  margin: 0;
}

.stat-analysis-figure .data-source {
  margin-top: 0.5rem;
}

.stat-analysis-copy h3 {
  font-size: 1.2rem;
}

.stat-analysis-copy p:last-child {
  margin-bottom: 0;
}

@media (min-width: 780px) {
  .stat-analysis {
    grid-template-columns: 260px 1fr;
  }
}

/* --------------------------------------------------------------------- */
/* Heat Pumps page                                                       */
/* Mirrors the .page-solar-pv scoping below: same editorial width and    */
/* H2 scale, applied additively so the approved Solar page is untouched. */
/* --------------------------------------------------------------------- */

.page-heat-pumps {
  --solar-editorial-width: 45rem;
  --solar-h2-size: clamp(1.75rem, 2.4vw, 2rem);
}

.page-heat-pumps .section-head {
  max-width: var(--solar-editorial-width);
  margin-inline: auto;
  text-align: left;
}

.page-heat-pumps .section-head--tool {
  margin-top: clamp(2.5rem, 5vw, 3.5rem);
}

.page-heat-pumps .section-head h2,
.page-heat-pumps .page-intro h2,
.page-heat-pumps .content-panel-copy h2 {
  font-size: var(--solar-h2-size);
}

.page-heat-pumps .step-card {
  background: var(--up-mist);
}

/* Six installation steps: a balanced 3-then-3 desktop grid rather than
   the seven-card 4-then-3 split used on Solar. */
@media (min-width: 1024px) {
  .page-heat-pumps .steps-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

/* --------------------------------------------------------------------- */
/* Heat Pump Readiness Check                                             */
/* Reuses .calculator/.calc-results/.calc-result-label/.factor-list as   */
/* established on Solar's Payback Explorer. Only the question/option     */
/* controls below are new, since Solar has no equivalent radio input UI. */
/* --------------------------------------------------------------------- */

.readiness-form {
  display: grid;
  gap: 1.5rem;
}

.readiness-question {
  border: 0;
  padding: 0;
  margin: 0;
}

.readiness-question legend {
  font-weight: 600;
  font-size: 0.92rem;
  color: var(--up-charcoal);
  margin-bottom: 0.6rem;
  padding: 0;
}

.readiness-options {
  display: grid;
  gap: 0.5rem;
}

.readiness-option {
  display: flex;
  align-items: flex-start;
  gap: 0.6rem;
  font-size: 0.92rem;
  color: var(--up-charcoal-soft);
  padding: 0.55rem 0.7rem;
  border: 1px solid var(--up-border);
  border-radius: var(--radius-sm);
  background: var(--up-white);
  cursor: pointer;
}

.readiness-option input {
  margin-top: 0.2rem;
  flex-shrink: 0;
  accent-color: var(--up-green);
}

.readiness-option:has(input:checked) {
  border-color: var(--up-green);
  background: var(--up-green-light);
  color: var(--up-charcoal);
}

.readiness-option input:focus-visible {
  outline: 3px solid var(--up-green);
  outline-offset: 2px;
}

.readiness-group {
  margin-top: 1.5rem;
}

.readiness-group:first-of-type {
  margin-top: 1.25rem;
}

.readiness-group h3 {
  font-size: 1rem;
  margin-bottom: 0.75rem;
}

.readiness-group .factor-list {
  margin-top: 0;
}

/* The Readiness Check form has more fields than Solar's calculator, so its
   results panel is kept in view while scrolling through the questions
   rather than scrolling away above the fold. */
@media (min-width: 900px) {
  #readiness-results {
    position: sticky;
    top: 6rem;
    align-self: start;
  }
}
