/* Sunward Electric and Solar — shared stylesheet */

:root {
  --bg: #FBFBF7;
  --surface: #FFFFFF;
  --forest: #0E3B2E;
  --forest-deep: #0A2C22;
  --forest-soft: rgba(14, 59, 46, 0.08);
  --sun: #F6C343;
  --sun-hover: #EDB52A;
  --sun-soft: #FDF1C7;
  --sky: #D6EBF5;
  --sky-deep: #BFDDED;
  --ink: #1E2522;
  --muted: #45514C;
  --line: rgba(14, 59, 46, 0.14);
  --gold-line: #7A5B00;
  --error: #A8261B;
  --panel-blue: #2D5F7A;

  --radius: 16px;
  --radius-lg: 24px;
  --gutter: clamp(16px, 4vw, 32px);
  --max: 1160px;
  --shadow: 0 1px 2px rgba(14, 59, 46, 0.06), 0 8px 24px -12px rgba(14, 59, 46, 0.18);

  --font-head: "Outfit", "Segoe UI", system-ui, sans-serif;
  --font-body: "Manrope", "Segoe UI", system-ui, sans-serif;
}

/* ---------- Base ---------- */

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

html { -webkit-text-size-adjust: 100%; }

@media (prefers-reduced-motion: no-preference) {
  html { scroll-behavior: smooth; }
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-body);
  font-weight: 400;
  font-size: 1.0625rem;
  line-height: 1.65;
  overflow-x: hidden;
}

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

h1, h2, h3 {
  font-family: var(--font-head);
  font-weight: 600;
  color: var(--forest);
  line-height: 1.15;
  letter-spacing: -0.015em;
  margin: 0 0 0.6em;
}

h1 { font-size: clamp(2.1rem, 1.4rem + 3.2vw, 3.6rem); }
h2 { font-size: clamp(1.65rem, 1.25rem + 1.7vw, 2.4rem); }
h3 { font-size: clamp(1.18rem, 1.08rem + 0.45vw, 1.4rem); }

p { margin: 0 0 1em; }
p:last-child { margin-bottom: 0; }

strong { font-weight: 500; color: var(--forest); }

a { color: var(--forest); text-decoration-thickness: 1.5px; text-underline-offset: 3px; }
a:hover { text-decoration-thickness: 2.5px; }

ul, ol { padding-left: 1.2em; }

:focus-visible {
  outline: 3px solid var(--forest);
  outline-offset: 3px;
  border-radius: 6px;
}

.on-dark :focus-visible,
.site-footer :focus-visible {
  outline-color: var(--sun);
}

.skip-link {
  position: absolute;
  left: 16px;
  top: -100px;
  z-index: 100;
  background: var(--forest);
  color: #fff;
  padding: 10px 16px;
  border-radius: 10px;
  font-weight: 500;
}
.skip-link:focus { top: 12px; }

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

.container {
  width: 100%;
  max-width: calc(var(--max) + 2 * var(--gutter));
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.section { padding-block: clamp(56px, 8vw, 104px); }
.section + .section { border-top: 1px solid var(--line); }
.section--tight { padding-block: clamp(40px, 6vw, 72px); }

.lede {
  font-size: clamp(1.08rem, 1rem + 0.4vw, 1.25rem);
  color: var(--muted);
  max-width: 38em;
}

.measure { max-width: 40em; }

/* Eyebrow with the sun-path arc motif */
.eyebrow {
  display: inline-flex;
  align-items: flex-end;
  gap: 10px;
  margin: 0 0 14px;
  font-family: var(--font-body);
  font-weight: 500;
  font-size: 0.8rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--forest);
}
.eyebrow::before {
  content: "";
  width: 30px;
  height: 15px;
  border: 2.5px solid var(--forest);
  border-bottom: 0;
  border-radius: 30px 30px 0 0;
  background: radial-gradient(circle at 78% 62%, var(--sun) 0 4px, transparent 4.5px);
  flex: none;
  margin-bottom: 3px;
}
.on-dark .eyebrow { color: var(--sun); }
.on-dark .eyebrow::before { border-color: var(--sun); }

.section-head { max-width: 44em; margin-bottom: clamp(28px, 4vw, 48px); }
.section-head p { color: var(--muted); font-size: 1.1rem; }

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

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 48px;
  padding: 12px 24px;
  border-radius: 999px;
  border: 2px solid transparent;
  font-family: var(--font-body);
  font-weight: 500;
  font-size: 1rem;
  line-height: 1.2;
  text-align: center;
  text-decoration: none;
  cursor: pointer;
  transition: background-color 0.18s ease, border-color 0.18s ease, color 0.18s ease, transform 0.18s ease;
}
.btn:hover { text-decoration: none; }

.btn--primary {
  background: var(--sun);
  color: var(--forest);
  border-color: var(--sun);
  box-shadow: 0 6px 16px -8px rgba(122, 91, 0, 0.55);
}
.btn--primary:hover { background: var(--sun-hover); border-color: var(--sun-hover); }

.btn--secondary {
  background: transparent;
  color: var(--forest);
  border-color: var(--forest);
}
.btn--secondary:hover { background: var(--forest-soft); }

.on-dark .btn--secondary { color: #fff; border-color: rgba(255, 255, 255, 0.85); }
.on-dark .btn--secondary:hover { background: rgba(255, 255, 255, 0.1); }

.btn--small { min-height: 42px; padding: 9px 18px; font-size: 0.95rem; }

@media (prefers-reduced-motion: no-preference) {
  .btn:hover { transform: translateY(-1px); }
}

.btn-row { display: flex; flex-wrap: wrap; gap: 12px; }

.text-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-weight: 500;
  color: var(--forest);
}
.text-link::after {
  content: "\2192";
  transition: transform 0.18s ease;
}
@media (prefers-reduced-motion: no-preference) {
  .text-link:hover::after { transform: translateX(3px); }
}

/* ---------- Placeholders (owner must fill these in) ---------- */

.ph {
  background: var(--sun-soft);
  color: var(--forest);
  border-bottom: 2px dashed var(--gold-line);
  padding: 0 4px;
  border-radius: 4px;
  font-weight: 500;
}

.ph-block {
  position: relative;
  margin: 0;
  padding: 36px 22px 22px;
  border: 2px dashed var(--gold-line);
  border-radius: var(--radius);
  background:
    repeating-linear-gradient(135deg, rgba(246, 195, 67, 0.16) 0 12px, rgba(246, 195, 67, 0.05) 12px 24px),
    var(--sun-soft);
  color: var(--forest);
  font-weight: 500;
  font-size: 1.05rem;
}
.ph-block::before {
  content: "To fill in";
  position: absolute;
  top: 10px;
  left: 14px;
  padding: 2px 10px;
  border-radius: 999px;
  background: var(--forest);
  color: #fff;
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(251, 251, 247, 0.94);
  border-bottom: 1px solid var(--line);
}
@supports (backdrop-filter: blur(8px)) {
  .site-header { background: rgba(251, 251, 247, 0.82); backdrop-filter: blur(10px); }
}

.header-inner {
  display: grid;
  grid-template-columns: auto 1fr auto;
  grid-template-areas: "logo nav actions";
  align-items: center;
  gap: 16px 28px;
  min-height: 76px;
  padding-block: 10px;
}

.logo {
  grid-area: logo;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--forest);
  line-height: 1;
}
.logo-mark { width: 34px; height: 34px; flex: none; }
.logo-text { display: flex; flex-direction: column; gap: 3px; }
.logo-name {
  font-family: var(--font-head);
  font-weight: 600;
  font-size: 1.4rem;
  letter-spacing: -0.02em;
}
.logo-sub {
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
}

.site-nav { grid-area: nav; justify-self: center; }
.site-nav ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  gap: 4px;
}
.site-nav a {
  display: block;
  padding: 8px 14px;
  border-radius: 999px;
  text-decoration: none;
  font-weight: 500;
  font-size: 0.98rem;
  color: var(--ink);
  white-space: nowrap;
}
.site-nav a:hover { background: var(--forest-soft); color: var(--forest); }
.site-nav a[aria-current="page"] { background: var(--sky); color: var(--forest); }
.nav-phone { display: none; }

.header-actions {
  grid-area: actions;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 4px;
}
.header-phone {
  font-size: 0.86rem;
  font-weight: 500;
  color: var(--forest);
  text-decoration: none;
  white-space: nowrap;
}
.header-phone:hover { text-decoration: underline; }
.header-cta { white-space: nowrap; }

.nav-toggle {
  grid-area: toggle;
  display: none;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 44px;
  min-width: 44px;
  padding: 8px 12px;
  border: 2px solid var(--line);
  border-radius: 12px;
  background: var(--surface);
  color: var(--forest);
  font: 500 0.95rem var(--font-body);
  cursor: pointer;
}
.nav-toggle-icon,
.nav-toggle-icon::before,
.nav-toggle-icon::after {
  display: block;
  width: 18px;
  height: 2px;
  background: currentColor;
  border-radius: 2px;
  transition: transform 0.2s ease, background-color 0.2s ease;
}
.nav-toggle-icon { position: relative; }
.nav-toggle-icon::before,
.nav-toggle-icon::after { content: ""; position: absolute; left: 0; }
.nav-toggle-icon::before { top: -6px; }
.nav-toggle-icon::after { top: 6px; }
.nav-toggle[aria-expanded="true"] .nav-toggle-icon { background: transparent; }
.nav-toggle[aria-expanded="true"] .nav-toggle-icon::before { transform: translateY(6px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] .nav-toggle-icon::after { transform: translateY(-6px) rotate(-45deg); }

@media (max-width: 1079px) {
  .header-inner {
    grid-template-columns: 1fr auto auto;
    grid-template-areas: "logo actions toggle" "nav nav nav";
    gap: 0 12px;
  }
  .nav-toggle { display: inline-flex; }
  .site-nav { justify-self: stretch; }
  .site-nav ul { flex-direction: column; gap: 2px; padding: 8px 0 14px; }
  .site-nav a { padding: 12px 14px; border-radius: 12px; font-size: 1.05rem; }
  .js .site-nav { display: none; }
  .js .site-header.nav-open .site-nav { display: block; }
  .nav-phone { display: block; }
  .nav-phone a { color: var(--forest); }
}

@media (max-width: 640px) {
  .header-phone { display: none; }
}

@media (max-width: 479px) {
  .header-inner {
    grid-template-columns: 1fr auto;
    grid-template-areas: "logo toggle" "actions actions" "nav nav";
    gap: 10px 12px;
    min-height: 0;
  }
  .header-actions { align-items: stretch; }
  .header-cta { width: 100%; }
  .logo-name { font-size: 1.25rem; }
  .logo-mark { width: 30px; height: 30px; }
  .toggle-label { display: none; }
}

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

.hero {
  position: relative;
  overflow: hidden;
  background: linear-gradient(180deg, var(--sky) 0%, #E9F4F8 55%, var(--bg) 100%);
  padding-block: clamp(40px, 7vw, 96px) clamp(40px, 6vw, 80px);
}
.hero-grid {
  display: grid;
  gap: 32px;
  align-items: center;
}
.hero h1 { max-width: 13em; }
.hero .lede { color: #34413B; margin-bottom: 28px; }
.hero-art { width: 100%; max-width: 560px; justify-self: center; }
.hero-art svg { width: 100%; height: auto; }

@media (min-width: 900px) {
  .hero-grid { grid-template-columns: 1.05fr 0.95fr; gap: 48px; }
}

/* Inner-page hero */
.page-hero {
  position: relative;
  overflow: hidden;
  background: linear-gradient(180deg, var(--sky) 0%, var(--bg) 100%);
  padding-block: clamp(48px, 7vw, 88px) clamp(40px, 5vw, 64px);
}
.page-hero::after {
  content: "";
  position: absolute;
  right: -120px;
  bottom: -260px;
  width: 520px;
  height: 520px;
  border-radius: 50%;
  border: 2px dashed rgba(14, 59, 46, 0.22);
  pointer-events: none;
}
.page-hero::before {
  content: "";
  position: absolute;
  right: 150px;
  top: 40px;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--sun);
  box-shadow: 0 0 0 10px rgba(246, 195, 67, 0.25);
  pointer-events: none;
}
.page-hero .container { position: relative; z-index: 1; }
.page-hero h1 { max-width: 16em; }

.page-hero--split .page-hero-grid { display: grid; gap: 28px; align-items: center; }
.page-hero--split .page-hero-art { max-width: 420px; width: 100%; justify-self: center; }
.page-hero--split .page-hero-art svg { width: 100%; height: auto; }
@media (min-width: 860px) {
  .page-hero--split .page-hero-grid { grid-template-columns: 1.2fr 0.8fr; }
}

@media (max-width: 700px) {
  .page-hero::before { right: 24px; top: 20px; width: 30px; height: 30px; box-shadow: 0 0 0 7px rgba(246, 195, 67, 0.25); }
  .page-hero::after { width: 300px; height: 300px; right: -200px; bottom: -230px; }
}

/* ---------- Service cards ---------- */

.card-grid {
  display: grid;
  gap: 20px;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 1fr));
}

.card {
  display: flex;
  flex-direction: column;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
}
.card-art {
  position: relative;
  background: var(--sky);
  padding: 18px 18px 0;
}
.card-art svg { width: 100%; height: auto; margin-inline: auto; max-width: 300px; }
.card-body { padding: 22px 22px 26px; display: flex; flex-direction: column; flex: 1; }
.card-body p { color: var(--muted); }
.card-body .text-link { margin-top: auto; padding-top: 10px; }

/* ---------- Fit checklist ---------- */

.fit-grid { display: grid; gap: 36px; }
@media (min-width: 900px) {
  .fit-grid { grid-template-columns: 0.85fr 1.15fr; gap: 64px; align-items: start; }
  .fit-grid .section-head { position: sticky; top: 120px; }
}

.checklist { list-style: none; margin: 0; padding: 0; display: grid; gap: 14px; }
.checklist li {
  display: grid;
  grid-template-columns: 40px 1fr;
  gap: 16px;
  align-items: start;
  padding: 18px 20px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}
.checklist h3 { font-size: 1.12rem; margin: 6px 0 4px; }
.checklist p { color: var(--muted); margin: 0; }
.check-icon {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--sky);
  display: grid;
  place-items: center;
  color: var(--forest);
}
.check-icon svg { width: 20px; height: 20px; }

.checklist--simple li { grid-template-columns: 36px 1fr; padding: 14px 18px; }
.checklist--simple .check-icon { width: 36px; height: 36px; }
.checklist--simple p { color: var(--ink); align-self: center; }

.fit-close {
  margin-top: 22px;
  padding: 18px 22px;
  border-radius: var(--radius);
  background: var(--forest);
  color: #fff;
  font-family: var(--font-head);
  font-weight: 600;
  font-size: 1.2rem;
  display: flex;
  align-items: center;
  gap: 14px;
}
.fit-close a { color: var(--sun); }
.fit-close::before {
  content: "";
  flex: none;
  width: 28px;
  height: 14px;
  border: 2.5px solid var(--sun);
  border-bottom: 0;
  border-radius: 28px 28px 0 0;
}

/* ---------- How it works (dark band with the sun arc) ---------- */

.how {
  background: var(--forest);
  color: #E8F0EC;
  position: relative;
  overflow: hidden;
}
.how h2, .how h3 { color: #fff; }
.how .section-head p { color: #C9D8D1; }
.section + .how, .how + .section { border-top: 0; }

.steps {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 28px;
  position: relative;
  counter-reset: step;
}
.step { position: relative; padding-left: 72px; }
.step p { color: #C9D8D1; margin: 0; }
.step h3 { margin-bottom: 6px; }
.step-num {
  position: absolute;
  left: 0;
  top: -6px;
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: var(--sun);
  color: var(--forest);
  display: grid;
  place-items: center;
  font-family: var(--font-head);
  font-weight: 600;
  font-size: 1.35rem;
  box-shadow: 0 0 0 8px rgba(246, 195, 67, 0.16);
}
.steps::before {
  content: "";
  position: absolute;
  left: 25px;
  top: 30px;
  bottom: 30px;
  border-left: 2px dashed rgba(246, 195, 67, 0.55);
}
.steps-wrap { position: relative; }
.steps-arc { display: none; }

@media (min-width: 900px) {
  .steps { grid-template-columns: repeat(4, 1fr); gap: 0; padding-top: 30px; }
  .steps::before { display: none; }
  .steps-arc {
    display: block;
    position: absolute;
    top: 30px;
    z-index: 0;
    left: 0;
    width: 100%;
    height: 120px;
    overflow: visible;
  }
  .step { padding: 110px 18px 0; text-align: center; z-index: 1; }
  .step-num { left: 50%; transform: translateX(-50%); top: 18px; }
  .step:nth-child(2) .step-num,
  .step:nth-child(3) .step-num { top: -13px; }
}

/* ---------- Questions ---------- */

.faq-grid { display: grid; gap: 32px; }
@media (min-width: 900px) {
  .faq-grid { grid-template-columns: 0.75fr 1.25fr; gap: 64px; align-items: start; }
}
.faq { display: grid; gap: 12px; }
.faq details {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}
.faq details[open] { border-color: rgba(14, 59, 46, 0.3); box-shadow: var(--shadow); }
.faq summary {
  list-style: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 18px 20px;
  border-radius: var(--radius);
  font-family: var(--font-head);
  font-weight: 600;
  font-size: 1.12rem;
  color: var(--forest);
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "";
  flex: none;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background:
    linear-gradient(var(--forest), var(--forest)) center / 12px 2px no-repeat,
    linear-gradient(var(--forest), var(--forest)) center / 2px 12px no-repeat,
    var(--sky);
  transition: transform 0.25s ease;
}
.faq details[open] summary::after {
  transform: rotate(45deg);
  background:
    linear-gradient(var(--forest), var(--forest)) center / 12px 2px no-repeat,
    linear-gradient(var(--forest), var(--forest)) center / 2px 12px no-repeat,
    var(--sun);
}
.faq-answer { padding: 0 20px 20px; color: var(--ink); }
.faq-answer p { max-width: 42em; }

/* ---------- Panels: incentives, reviews ---------- */

.panel {
  background: var(--sky);
  border-radius: var(--radius-lg);
  padding: clamp(24px, 4vw, 48px);
  display: grid;
  gap: 24px;
  position: relative;
  overflow: hidden;
}
.panel > * { position: relative; }
.panel::after {
  content: "";
  position: absolute;
  right: -70px;
  top: -70px;
  width: 220px;
  height: 220px;
  border-radius: 50%;
  border: 2px dashed rgba(14, 59, 46, 0.2);
}
.panel p { color: #2C3833; }
@media (max-width: 700px) {
  .panel::after { width: 140px; height: 140px; right: -80px; top: -80px; }
}
@media (min-width: 900px) {
  .panel--split { grid-template-columns: 1fr 1fr; gap: 48px; align-items: center; }
}

.reviews-block { max-width: 760px; }

/* ---------- Booking band ---------- */

.booking-band {
  position: relative;
  overflow: hidden;
  background: var(--forest);
  color: #E8F0EC;
  border-radius: var(--radius-lg);
  padding: clamp(32px, 5vw, 64px);
  display: grid;
  gap: 24px;
  align-items: center;
}
.booking-band h2 { color: #fff; max-width: 15em; }
.booking-band p { color: #C9D8D1; max-width: 34em; }
.booking-band > * { position: relative; z-index: 1; }
.booking-band::before {
  content: "";
  position: absolute;
  right: -90px;
  bottom: -300px;
  width: 520px;
  height: 520px;
  border-radius: 50%;
  border: 2px dashed rgba(246, 195, 67, 0.5);
}
.booking-band::after {
  content: "";
  position: absolute;
  right: 40px;
  top: 32px;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--sun);
  box-shadow: 0 0 0 12px rgba(246, 195, 67, 0.15), 0 0 0 26px rgba(246, 195, 67, 0.07);
}
@media (min-width: 900px) {
  .booking-band { grid-template-columns: 1.4fr auto; gap: 40px; }
  .booking-band .btn-row { flex-direction: column; align-items: stretch; }
}
@media (max-width: 600px) {
  .booking-band::after { right: 24px; top: 22px; width: 34px; height: 34px; }
  .booking-band h2 { padding-right: 48px; }
}

/* ---------- Detail sections (solar, battery, EV) ---------- */

.topic { scroll-margin-top: 110px; }
.topic-head { display: flex; align-items: center; gap: 16px; margin-bottom: 20px; }
.topic-head h2 { margin: 0; }
.topic-icon {
  flex: none;
  width: 56px;
  height: 56px;
  border-radius: 16px;
  background: var(--sky);
  display: grid;
  place-items: center;
}
.topic-icon svg { width: 34px; height: 34px; }

.explain-grid { display: grid; gap: 32px; margin-top: 36px; }
@media (min-width: 960px) {
  .explain-grid { grid-template-columns: 1fr 1fr; gap: 56px; align-items: start; }
}

.diagram {
  margin: 0;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: clamp(16px, 3vw, 28px);
  box-shadow: var(--shadow);
}
.diagram svg { width: 100%; height: auto; }
.diagram figcaption { margin-top: 12px; font-size: 0.92rem; color: var(--muted); text-align: center; }

.flow-steps { margin: 0; padding: 0; list-style: none; counter-reset: flow; display: grid; gap: 14px; }
.flow-steps li {
  counter-increment: flow;
  position: relative;
  padding-left: 46px;
}
.flow-steps li::before {
  content: counter(flow);
  position: absolute;
  left: 0;
  top: 1px;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: var(--sun);
  color: var(--forest);
  font-family: var(--font-head);
  font-weight: 600;
  font-size: 0.95rem;
  display: grid;
  place-items: center;
}

.term {
  display: block;
  margin-top: 6px;
  padding: 10px 14px;
  border-left: 3px solid var(--sun);
  background: var(--sun-soft);
  border-radius: 0 10px 10px 0;
  font-size: 0.95rem;
  color: var(--ink);
}

.detail-cards { display: grid; gap: 20px; margin-top: 40px; }
@media (min-width: 860px) {
  .detail-cards { grid-template-columns: 1fr 1fr; }
}
.detail-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: clamp(22px, 3vw, 32px);
}
.detail-card h3 { display: flex; align-items: center; gap: 12px; }
.detail-card h3::before {
  content: "";
  flex: none;
  width: 24px;
  height: 12px;
  border: 2.5px solid var(--forest);
  border-bottom: 0;
  border-radius: 24px 24px 0 0;
}
.tick-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.tick-list li { position: relative; padding-left: 30px; }
.tick-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.3em;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: var(--sky)
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M5 10.5l3.2 3L15 7' fill='none' stroke='%230E3B2E' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E")
    center / 14px no-repeat;
}

.phase-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 16px; }
.phase-list li { padding-left: 18px; border-left: 3px solid var(--sky-deep); }
.phase-list strong { display: block; font-family: var(--font-head); font-weight: 600; font-size: 1.05rem; }

.pair-grid { display: grid; gap: 20px; margin-top: 32px; }
@media (min-width: 860px) { .pair-grid { grid-template-columns: 1fr 1fr; } }
.pair-note { margin-top: 28px; }
.pair-card { border-radius: var(--radius); padding: clamp(22px, 3vw, 32px); }
.pair-card--yes { background: var(--sky); }
.pair-card--maybe { background: var(--surface); border: 1px solid var(--line); }

/* Energy-flow diagram */
.flow text {
  font-family: var(--font-body);
  font-weight: 500;
  font-size: 21px;
  fill: var(--forest);
}
.flow .line {
  fill: none;
  stroke: var(--forest);
  stroke-width: 3;
  stroke-linecap: round;
  stroke-linejoin: round;
  opacity: 0.35;
}
.flow .line.hot { opacity: 1; stroke-dasharray: 9 7; }
@media (prefers-reduced-motion: no-preference) {
  .flow .line.hot { animation: flow-dash 1.4s linear infinite; }
  .flow .line.hot.reverse { animation-direction: reverse; }
}
@keyframes flow-dash {
  to { stroke-dashoffset: -32; }
}

/* EV comparison */
.compare { display: grid; gap: 20px; margin-top: 32px; }
@media (min-width: 820px) { .compare { grid-template-columns: 1fr 1fr; } }
.compare-card {
  border-radius: var(--radius);
  padding: clamp(22px, 3vw, 32px);
  background: var(--surface);
  border: 1px solid var(--line);
}
.compare-card--featured { background: var(--sky); border-color: transparent; }
.compare-tag {
  display: inline-block;
  margin-bottom: 10px;
  padding: 3px 12px;
  border-radius: 999px;
  background: var(--forest);
  color: #fff;
  font-size: 0.78rem;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.compare-card--plain .compare-tag { background: var(--forest-soft); color: var(--forest); }
.compare-card .tick-list { margin-top: 14px; }
.compare-card--featured .tick-list li::before,
.pair-card--yes .tick-list li::before { background-color: var(--surface); }

.factor-grid {
  display: grid;
  gap: 20px;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 250px), 1fr));
}
.factor {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 24px;
}
.factor-icon {
  width: 52px;
  height: 52px;
  border-radius: 14px;
  background: var(--sky);
  display: grid;
  place-items: center;
  margin-bottom: 16px;
}
.factor-icon svg { width: 30px; height: 30px; }
.factor p { color: var(--muted); }

/* ---------- Booking page ---------- */

.book-grid { display: grid; gap: 32px; align-items: start; }
@media (min-width: 960px) {
  .book-grid { grid-template-columns: 1.35fr 0.65fr; gap: 48px; }
  .book-aside { position: sticky; top: 110px; }
}

.form-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: clamp(20px, 4vw, 40px);
  box-shadow: var(--shadow);
}
.form-intro { color: var(--muted); font-size: 0.95rem; margin-bottom: 24px; }
.req { color: var(--error); font-weight: 500; }

.form-grid { display: grid; gap: 22px; }
@media (min-width: 640px) {
  .form-grid { grid-template-columns: 1fr 1fr; }
  .field--full { grid-column: 1 / -1; }
}

.field { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.field label,
.field legend {
  font-weight: 500;
  color: var(--forest);
  font-size: 1rem;
}
.hint-inline { font-weight: 400; color: var(--muted); font-size: 0.92rem; }
.field .hint { font-size: 0.88rem; color: var(--muted); margin: -2px 0 2px; }
fieldset.field { border: 0; margin: 0; padding: 0; }
fieldset.field legend { padding: 0; margin-bottom: 8px; }

.input,
.select,
.textarea {
  width: 100%;
  min-height: 50px;
  padding: 12px 14px;
  border: 1.5px solid #8B9792;
  border-radius: 12px;
  background: var(--surface);
  color: var(--ink);
  font: 400 1rem var(--font-body);
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}
.textarea { min-height: 120px; resize: vertical; }
.select {
  appearance: none;
  -webkit-appearance: none;
  padding-right: 44px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M5 7.5l5 5 5-5' fill='none' stroke='%230E3B2E' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  background-size: 18px;
}
.input:hover, .select:hover, .textarea:hover { border-color: var(--forest); }
.input:focus-visible, .select:focus-visible, .textarea:focus-visible {
  outline: 3px solid var(--forest);
  outline-offset: 1px;
  border-color: var(--forest);
}
[aria-invalid="true"].input,
[aria-invalid="true"].select { border-color: var(--error); background-color: #FFF8F7; }

.choices { display: flex; flex-wrap: wrap; gap: 10px; }
.choice { position: relative; }
.choice input {
  position: absolute;
  opacity: 0;
  width: 1px;
  height: 1px;
}
.choice label {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 46px;
  padding: 10px 16px;
  border: 1.5px solid #8B9792;
  border-radius: 999px;
  background: var(--surface);
  color: var(--ink);
  font-weight: 500;
  font-size: 0.97rem;
  cursor: pointer;
  transition: background-color 0.15s ease, border-color 0.15s ease;
}
.choice label::before {
  content: "";
  flex: none;
  width: 18px;
  height: 18px;
  border: 2px solid var(--forest);
  border-radius: 5px;
  background: var(--surface) center / 12px no-repeat;
}
.choice input[type="radio"] + label::before { border-radius: 50%; }
.choice label:hover { border-color: var(--forest); }
.choice input:checked + label { background: var(--sky); border-color: var(--forest); color: var(--forest); }
.choice input[type="checkbox"]:checked + label::before {
  background-color: var(--forest);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M4.5 10.5l3.5 3.2L15.5 6.5' fill='none' stroke='%23FFFFFF' stroke-width='2.8' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
}
.choice input[type="radio"]:checked + label::before {
  background: radial-gradient(circle, var(--forest) 0 4px, var(--surface) 4.5px);
}
.choice input:focus-visible + label { outline: 3px solid var(--forest); outline-offset: 2px; }
fieldset[aria-invalid="true"] .choice label { border-color: var(--error); }

.error {
  display: none;
  align-items: flex-start;
  gap: 6px;
  color: var(--error);
  font-size: 0.92rem;
  font-weight: 500;
}
.error.is-visible { display: flex; }
.error::before { content: "!"; flex: none; width: 18px; height: 18px; margin-top: 2px; border-radius: 50%; background: var(--error); color: #fff; font-size: 0.75rem; display: grid; place-items: center; }

.form-actions { margin-top: 28px; display: flex; flex-direction: column; gap: 16px; align-items: flex-start; }
.form-actions .btn { min-width: 240px; }
@media (max-width: 479px) { .form-actions .btn { width: 100%; min-width: 0; } }

.form-status {
  display: none;
  width: 100%;
  padding: 16px 18px;
  border-radius: 14px;
  background: var(--sun-soft);
  border: 2px solid var(--gold-line);
  color: var(--forest);
  font-weight: 500;
}
.form-status.is-visible { display: block; }

.aside-card {
  background: var(--sky);
  border-radius: var(--radius-lg);
  padding: clamp(22px, 3vw, 32px);
  position: relative;
  overflow: hidden;
}
.aside-card::after {
  content: "";
  position: absolute;
  right: -60px;
  bottom: -110px;
  width: 200px;
  height: 200px;
  border-radius: 50%;
  border: 2px dashed rgba(14, 59, 46, 0.22);
}
.aside-card > * { position: relative; }
.aside-steps { list-style: none; margin: 0 0 20px; padding: 0; display: grid; gap: 16px; }
.aside-steps li { display: grid; grid-template-columns: 36px 1fr; gap: 12px; align-items: start; }
.aside-steps .num {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--surface);
  color: var(--forest);
  display: grid;
  place-items: center;
  font-family: var(--font-head);
  font-weight: 600;
}
.aside-steps h3 { font-size: 1.05rem; margin: 6px 0 2px; }
.aside-steps p { margin: 5px 0 0; color: #2C3833; }
.aside-call {
  margin-top: 16px;
  padding-top: 18px;
  border-top: 1px solid rgba(14, 59, 46, 0.18);
  font-size: 0.97rem;
}
.aside-call a { font-weight: 500; }

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

.site-footer {
  background: var(--forest-deep);
  color: #DCE6E1;
  padding-block: clamp(48px, 7vw, 80px) 28px;
  margin-top: clamp(24px, 4vw, 48px);
  position: relative;
  overflow: hidden;
}
.site-footer::before {
  content: "";
  position: absolute;
  left: 50%;
  top: -1px;
  transform: translateX(-50%);
  width: 140%;
  height: 40px;
  border-radius: 0 0 50% 50%;
  border-bottom: 2px dashed rgba(246, 195, 67, 0.35);
  pointer-events: none;
}
.site-footer a { color: #fff; }
.site-footer a:hover { color: var(--sun); }
.footer-grid { display: grid; gap: 32px; position: relative; }
@media (min-width: 720px) { .footer-grid { grid-template-columns: 1fr 1fr; } }
@media (min-width: 1000px) { .footer-grid { grid-template-columns: 1.3fr 1fr 1fr 0.8fr; gap: 40px; } }
.footer-brand .logo { color: #fff; }
.footer-brand .logo-sub { color: #B9CBC3; }
.footer-brand p { margin-top: 16px; color: #C3D3CC; max-width: 24em; }
.footer-title {
  font-family: var(--font-head);
  font-weight: 600;
  font-size: 1rem;
  color: var(--sun);
  margin: 0 0 12px;
  letter-spacing: 0.02em;
}
.footer-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.footer-list .label { display: block; font-size: 0.8rem; letter-spacing: 0.08em; text-transform: uppercase; color: #A9BDB4; }
.footer-bottom {
  margin-top: 40px;
  padding-top: 20px;
  border-top: 1px solid rgba(255, 255, 255, 0.14);
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 12px;
  font-size: 0.9rem;
  color: #A9BDB4;
}
.site-footer .ph { color: var(--forest); }

/* ---------- Motion ---------- */

@media (prefers-reduced-motion: no-preference) {
  .hero-flow { stroke-dasharray: 4 9; animation: flow-dash 1.6s linear infinite; }
  .sun-glow { animation: sun-glow 5s ease-in-out infinite; transform-origin: center; transform-box: fill-box; }
}
@keyframes sun-glow {
  0%, 100% { opacity: 0.35; transform: scale(1); }
  50% { opacity: 0.55; transform: scale(1.08); }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
