/* Stage-matching chrome for electrical calculators.
   Header + footer only — calculator body continues to use pe-shared.css.
   Colour tokens mirror globals.css so the two stay in sync visually. */

@import url("https://fonts.googleapis.com/css2?family=Poppins:wght@500;600;700&family=Heebo:wght@400;500;600&display=swap");

.pe-stage-header,
.pe-stage-footer {
  --pe-navy-950: #1A0D2E;
  --pe-navy-900: #2D1650;
  --pe-navy-800: #623895;
  --pe-navy-700: #7B4EAD;
  --pe-green-700: #6B8F12;
  --pe-green-600: #8AB51E;
  --pe-green-500: #B3D337;
  --pe-green-400: #C5DE5E;
  --pe-cream-50: #F6F7F9;
  --pe-cream-200: #D5D9E0;
  --pe-cream-300: #B8BEC9;
  --pe-cream-400: #8E96A6;
  font-family: "Heebo", system-ui, -apple-system, sans-serif;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  box-sizing: border-box;
}

.pe-stage-header *,
.pe-stage-header *::before,
.pe-stage-header *::after,
.pe-stage-footer *,
.pe-stage-footer *::before,
.pe-stage-footer *::after { box-sizing: border-box; }

/* ──────────────────────────────────────────
   HEADER
   ────────────────────────────────────────── */
.pe-stage-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: var(--pe-navy-800);
  border-bottom: 1px solid rgba(255,255,255,0.08);
}

.pe-stage-nav {
  max-width: 1280px;
  margin: 0 auto;
  padding: 12px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.pe-stage-logo { display: inline-flex; align-items: center; flex-shrink: 0; }
.pe-stage-logo img { height: 40px; width: auto; display: block; }

.pe-stage-nav-links {
  list-style: none;
  margin: 0;
  padding: 0;
  display: none;
  align-items: center;
  gap: 2px;
}

.pe-stage-nav-item { position: relative; }

.pe-stage-nav-link {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 8px 12px;
  font-size: 14px;
  font-weight: 500;
  font-family: inherit;
  color: rgba(255,255,255,0.85);
  background: none;
  border: 0;
  cursor: pointer;
  text-decoration: none;
  transition: color 150ms ease;
}
.pe-stage-nav-link:hover,
.pe-stage-nav-link:focus-visible,
.pe-stage-nav-link[aria-expanded="true"] { color: #fff; outline: none; }
.pe-stage-nav-link[aria-expanded="true"] { color: var(--pe-green-400); }

.pe-stage-chevron { transition: transform 200ms ease; }
.pe-stage-nav-link[aria-expanded="true"] .pe-stage-chevron { transform: rotate(180deg); }

.pe-stage-dropdown {
  position: absolute;
  top: calc(100% + 8px);
  left: 50%;
  transform: translateX(-50%) translateY(-4px);
  min-width: 280px;
  padding: 8px;
  background: #fff;
  border: 1px solid var(--pe-cream-200);
  border-radius: 4px;
  box-shadow: 0 12px 32px rgba(12,14,18,0.12);
  display: flex;
  flex-direction: column;
  gap: 2px;
  opacity: 0;
  visibility: hidden;
  transition: opacity 180ms ease, transform 180ms ease, visibility 0s linear 180ms;
}
.pe-stage-has-dropdown:hover > .pe-stage-dropdown,
.pe-stage-has-dropdown:focus-within > .pe-stage-dropdown,
.pe-stage-has-dropdown.pe-stage-open > .pe-stage-dropdown {
  opacity: 1;
  visibility: visible;
  transform: translateX(-50%) translateY(0);
  transition-delay: 0s;
}

.pe-stage-dropdown a {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 10px 12px;
  border-radius: 4px;
  color: #1A1D24;
  text-decoration: none;
  transition: background 120ms ease;
}
.pe-stage-dropdown a:hover,
.pe-stage-dropdown a:focus-visible {
  background: var(--pe-cream-50);
  outline: none;
}
.pe-stage-dropdown span { font-size: 14px; font-weight: 500; color: #1A1D24; }
.pe-stage-dropdown small { font-size: 12px; color: #5A6272; }

.pe-stage-nav-cta { display: none; align-items: center; gap: 12px; flex-shrink: 0; }

.pe-stage-customer-link {
  font-size: 14px;
  font-weight: 500;
  color: rgba(255,255,255,0.85);
  text-decoration: none;
  padding: 8px 12px;
  transition: color 150ms ease;
}
.pe-stage-customer-link:hover { color: #fff; }

.pe-stage-cta-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 16px;
  background: var(--pe-green-500);
  color: var(--pe-navy-950);
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
  border-radius: 4px;
  transition: background 150ms ease;
}
.pe-stage-cta-btn:hover { background: var(--pe-green-600); }
.pe-stage-cta-btn:active { background: var(--pe-green-700); }

.pe-stage-hamburger {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  background: none;
  border: 0;
  color: rgba(255,255,255,0.85);
  cursor: pointer;
  border-radius: 4px;
  transition: color 150ms ease, background 150ms ease;
}
.pe-stage-hamburger:hover,
.pe-stage-hamburger:focus-visible { color: #fff; background: rgba(255,255,255,0.08); outline: none; }

@media (min-width: 1024px) {
  .pe-stage-nav-links,
  .pe-stage-nav-cta { display: flex; }
  .pe-stage-hamburger { display: none; }
}

/* ──────────────────────────────────────────
   MOBILE MENU
   ────────────────────────────────────────── */
.pe-stage-mobile {
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  background: var(--pe-navy-900);
  padding: 72px 24px 24px;
  overflow-y: auto;
  z-index: 40;
}
.pe-stage-mobile[hidden] { display: none; }

.pe-stage-mobile-inner { display: flex; flex-direction: column; gap: 4px; }

.pe-stage-mobile-group,
.pe-stage-mobile-link {
  border-bottom: 1px solid rgba(255,255,255,0.1);
}

.pe-stage-mobile-group summary {
  padding: 14px 0;
  font-size: 17px;
  font-weight: 500;
  color: #fff;
  cursor: pointer;
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.pe-stage-mobile-group summary::-webkit-details-marker { display: none; }
.pe-stage-mobile-group summary::after {
  content: "";
  width: 10px; height: 10px;
  border-right: 2px solid rgba(255,255,255,0.7);
  border-bottom: 2px solid rgba(255,255,255,0.7);
  transform: rotate(45deg);
  transition: transform 200ms ease;
}
.pe-stage-mobile-group[open] summary::after { transform: rotate(-135deg); }
.pe-stage-mobile-group a {
  display: block;
  padding: 10px 0 10px 16px;
  font-size: 15px;
  color: rgba(255,255,255,0.8);
  text-decoration: none;
}
.pe-stage-mobile-group a:hover { color: #fff; }

.pe-stage-mobile-link {
  display: block;
  padding: 14px 0;
  font-size: 17px;
  font-weight: 500;
  color: #fff;
  text-decoration: none;
}

.pe-stage-mobile-cta {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: 24px;
  padding-top: 24px;
  border-top: 1px solid rgba(255,255,255,0.1);
}
.pe-stage-mobile-cta .pe-stage-customer-link,
.pe-stage-mobile-cta .pe-stage-cta-btn {
  justify-content: center;
  padding: 12px 16px;
  font-size: 15px;
}
.pe-stage-mobile-cta .pe-stage-customer-link {
  border: 1px solid rgba(255,255,255,0.2);
  border-radius: 4px;
  text-align: center;
}

@media (min-width: 1024px) {
  .pe-stage-mobile { display: none !important; }
}

/* ──────────────────────────────────────────
   FOOTER
   ────────────────────────────────────────── */
.pe-stage-footer { background: var(--pe-navy-800); color: var(--pe-cream-300); }

.pe-stage-footer-inner { max-width: 1280px; margin: 0 auto; padding: 0 24px; }

.pe-stage-footer-top {
  padding: 56px 0;
  border-bottom: 1px solid rgba(255,255,255,0.1);
  display: grid;
  grid-template-columns: 1fr;
  gap: 40px;
}
@media (min-width: 1024px) {
  .pe-stage-footer-top { grid-template-columns: 1fr 2fr; gap: 32px; }
}

.pe-stage-footer-brand { display: flex; flex-direction: column; gap: 16px; max-width: 280px; }
.pe-stage-footer-logo { height: 40px; width: auto; filter: brightness(0) invert(1); }
.pe-stage-footer-tagline { font-size: 14px; line-height: 1.6; color: rgba(184,190,201,0.8); margin: 0; }

.pe-stage-footer-contact { display: flex; flex-direction: column; gap: 10px; margin-top: 12px; }
.pe-stage-footer-contact a {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 14px;
  color: rgba(184,190,201,0.8);
  text-decoration: none;
  transition: color 150ms ease;
}
.pe-stage-footer-contact a svg { color: rgba(142,150,166,0.7); flex-shrink: 0; }
.pe-stage-footer-contact a:hover { color: var(--pe-cream-50); }

.pe-stage-footer-cols {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 32px;
}
@media (min-width: 640px) { .pe-stage-footer-cols { grid-template-columns: repeat(3, 1fr); } }
@media (min-width: 1024px) { .pe-stage-footer-cols { grid-template-columns: repeat(6, 1fr); } }

.pe-stage-footer-col h3 {
  font-family: "Poppins", system-ui, sans-serif;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.04em;
  color: var(--pe-cream-200);
  margin: 0 0 20px;
}
.pe-stage-footer-col h3 a { color: inherit; text-decoration: none; transition: color 150ms ease; }
.pe-stage-footer-col h3 a:hover { color: var(--pe-cream-50); }

.pe-stage-footer-col ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 12px; }
.pe-stage-footer-col a {
  font-size: 14px;
  color: rgba(184,190,201,0.8);
  text-decoration: none;
  transition: color 150ms ease;
}
.pe-stage-footer-col a:hover { color: var(--pe-cream-50); }

.pe-stage-footer-certs {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 32px;
  padding: 32px 0;
  border-bottom: 1px solid rgba(255,255,255,0.1);
}
.pe-stage-footer-certs img { height: 48px; width: auto; opacity: 0.8; transition: opacity 150ms ease; }
.pe-stage-footer-certs img:hover { opacity: 1; }

.pe-stage-footer-bottom {
  padding: 28px 0;
  display: flex;
  flex-direction: column;
  gap: 16px;
}
@media (min-width: 640px) {
  .pe-stage-footer-bottom { flex-direction: row; align-items: center; justify-content: space-between; }
}

.pe-stage-footer-legal p { font-size: 12px; margin: 0 0 4px; color: rgba(142,150,166,0.7); }
.pe-stage-footer-legal p:first-child { color: rgba(142,150,166,0.85); }

.pe-stage-footer-utility {
  margin-top: 8px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px 16px;
  font-size: 12px;
  color: rgba(142,150,166,0.7);
}
.pe-stage-footer-utility a { color: inherit; text-decoration: none; transition: color 150ms ease; }
.pe-stage-footer-utility a:hover { color: var(--pe-cream-50); }
.pe-stage-footer-utility span { color: rgba(142,150,166,0.4); }

.pe-stage-footer-attribution {
  font-family: "JetBrains Mono", ui-monospace, Consolas, monospace;
  font-size: 12px;
  color: rgba(142,150,166,0.65);
  margin: 0;
}
