/* ==========================================================================
   NORTHSTAR ELECTRICAL — base: tokens, font, reset, type, utilities
   Mobile-first. Plain, legible, fast.
   ========================================================================== */

@font-face {
  font-family: "Figtree";
  src: url("../assets/fonts/figtree-var-latin.woff2") format("woff2");
  font-weight: 400 800;
  font-style: normal;
  font-display: swap;
}

:root {
  --white: #ffffff;
  --snow: #f4f6f9;
  --mist: #e9edf3;
  --line: #d9dfe8;
  --charcoal: #1b1f26;
  --charcoal-2: #252b34;
  --charcoal-3: #323a46;
  --ink: #1b1f26;
  --ink-2: #4a5361;
  --mute: #6b7482;
  --blue: #1657d9;
  --blue-dk: #0f43ad;
  --blue-lt: #e8f0ff;
  --blue-on-dark: #6d9bff;
  --wa: #0f7a41;
  --wa-dk: #0a5f32;
  --amber: #ffb400;
  --line-d: rgba(255, 255, 255, 0.16);

  --font: "Figtree", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;

  --gutter: clamp(18px, 4.4vw, 56px);
  --maxw: 1240px;
  --section-y: clamp(56px, 8vw, 112px);
  --radius: 10px;
  --bar-h: 72px; /* mobile action bar height */
  --ease: cubic-bezier(0.2, 0.7, 0.2, 1);
}

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

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: 88px;
}

body {
  margin: 0;
  background: var(--white);
  color: var(--ink);
  font-family: var(--font);
  font-size: 1.0625rem;
  line-height: 1.6;
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
  padding-bottom: calc(var(--bar-h) + env(safe-area-inset-bottom));
}

body.is-locked {
  overflow: hidden;
}

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

img {
  height: auto;
}

h1, h2, h3, h4, p, figure, blockquote, dl, dd, ul, ol {
  margin: 0;
  padding: 0;
}

ul, ol {
  list-style: none;
}

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

button {
  font: inherit;
  color: inherit;
  background: none;
  border: 0;
  padding: 0;
  cursor: pointer;
}

address {
  font-style: normal;
}

::selection {
  background: var(--blue);
  color: var(--white);
}

:focus-visible {
  outline: 3px solid var(--blue);
  outline-offset: 3px;
}

.dark :focus-visible,
.topbar :focus-visible,
.footer :focus-visible {
  outline-color: #9cbaff;
}

.skip-link {
  position: fixed;
  top: 10px;
  left: 10px;
  z-index: 500;
  padding: 0.8em 1.2em;
  background: var(--charcoal);
  color: var(--white);
  font-weight: 700;
  border-radius: 6px;
  transform: translateY(-200%);
  transition: transform 0.2s var(--ease);
}

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

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

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

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

.section {
  padding-block: var(--section-y);
}

.section--snow {
  background: var(--snow);
}

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

/* --------------------------------------------------------------------------
   Type
   -------------------------------------------------------------------------- */

.h1,
.h2 {
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.02;
  text-transform: uppercase;
  text-wrap: balance;
}

.h1 {
  font-size: clamp(2.7rem, 9.4vw, 5.8rem);
}

.h2 {
  font-size: clamp(2rem, 5.4vw, 3.6rem);
}

.blue {
  color: var(--blue);
}

.dark .blue {
  color: var(--blue-on-dark);
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.6em;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--blue);
}

.dark .eyebrow {
  color: var(--blue-on-dark);
}

.eyebrow::before {
  content: "";
  width: 22px;
  height: 3px;
  border-radius: 2px;
  background: currentColor;
}

.lede {
  font-size: clamp(1.08rem, 2.2vw, 1.25rem);
  line-height: 1.55;
  color: var(--ink-2);
  max-width: 34em;
}

.dark .lede {
  color: #c9d0da;
}

.section-head {
  display: grid;
  gap: 14px;
  margin-bottom: clamp(28px, 4vw, 52px);
  max-width: 44rem;
}

.section-head--split {
  max-width: none;
}

@media (min-width: 900px) {
  .section-head--split {
    grid-template-columns: 1.2fr 1fr;
    align-items: end;
    gap: 56px;
  }
}

/* --------------------------------------------------------------------------
   Reveal (subtle, only when JS runs)
   -------------------------------------------------------------------------- */

.js [data-reveal] {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.6s var(--ease), transform 0.6s var(--ease);
  transition-delay: var(--d, 0ms);
}

.js [data-reveal].is-in {
  opacity: 1;
  transform: none;
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .js [data-reveal] {
    opacity: 1;
    transform: none;
    transition: none;
  }
}

/* sprite icons */
.i {
  width: 1.25em;
  height: 1.25em;
  flex: none;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.9;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.i--fill {
  fill: currentColor;
  stroke: none;
}
