@font-face {
  font-family: "Archivo";
  src: url("/fonts/archivo.woff2") format("woff2-variations"), url("/fonts/archivo.woff2") format("woff2");
  font-weight: 100 900;
  font-stretch: 62% 125%;
  font-display: swap;
}

:root {
  --frost: #edf1f3;
  --slate: #16242f;
  --mist: #5a6a75;
  --rule: #c5cfd5;
  --cobalt: #2448c8;
  --wash: #d2dbf6;
  --measure: 36rem;
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root {
    --frost: #12202a;
    --slate: #e5ebee;
    --mist: #93a3ad;
    --rule: #2c3c47;
    --cobalt: #8ea6ff;
    --wash: #233566;
    color-scheme: dark;
  }
}

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

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

body {
  margin: 0;
  background: var(--frost);
  color: var(--slate);
  font-family: "Archivo", "Helvetica Neue", Arial, sans-serif;
  font-size: 1.125rem;
  line-height: 1.55;
  font-stretch: 100%;
  font-weight: 400;
}

a {
  color: var(--cobalt);
  text-decoration-thickness: 1px;
  text-underline-offset: 0.18em;
}
a:hover {
  text-decoration-thickness: 2px;
}
:focus-visible {
  outline: 2px solid var(--cobalt);
  outline-offset: 3px;
  border-radius: 2px;
}

.page {
  max-width: 75rem;
  margin: 0 auto;
  padding: 0 clamp(1rem, 4vw, 3rem);
}

.domain {
  margin: 0;
  padding: 1.5rem 0 0;
  font-size: 0.875rem;
  color: var(--mist);
}

/* Hero: the wordmark sits on the zero line of an energy graph. Above the line the car uses
   energy; the cobalt dips below it are energy coming back — regeneration. */
.hero {
  margin: clamp(2.5rem, 9vw, 6rem) 0 0;
}
.hero h1 {
  margin: 0;
}
.graph {
  display: block;
  width: calc(100% + clamp(1rem, 4vw, 3rem)); /* run off the right edge */
  height: clamp(8.5rem, 27vw, 20rem);
  overflow: visible;
}
.graph .wordmark {
  font-family: "Archivo", "Helvetica Neue", Arial, sans-serif;
  font-size: 176px;
  font-weight: 800;
  font-stretch: 125%;
  letter-spacing: -0.035em;
  fill: var(--slate);
}
.graph .axis {
  stroke: var(--rule);
  stroke-width: 1.5;
  vector-effect: non-scaling-stroke;
}
.graph .use {
  fill: none;
  stroke: var(--slate);
  stroke-width: 2.25;
  stroke-linejoin: round;
  stroke-linecap: round;
  vector-effect: non-scaling-stroke;
}
.graph .regen-line {
  fill: none;
  stroke: var(--cobalt);
  stroke-width: 2.25;
  stroke-linejoin: round;
  stroke-linecap: round;
  vector-effect: non-scaling-stroke;
}
.graph .regen-fill {
  fill: var(--wash);
}

@media (prefers-reduced-motion: no-preference) {
  .graph .use,
  .graph .regen-line {
    stroke-dasharray: 1;
    stroke-dashoffset: 1;
    animation: draw 2.2s cubic-bezier(0.45, 0, 0.2, 1) 0.25s forwards;
  }
  .graph .regen-fill {
    opacity: 0;
    animation: appear 0.8s ease-out 2.1s forwards;
  }
}
@keyframes draw {
  to {
    stroke-dashoffset: 0;
  }
}
@keyframes appear {
  to {
    opacity: 1;
  }
}

.lead {
  max-width: 30ch;
  margin: clamp(1.75rem, 4vw, 2.75rem) 0 0;
  font-size: clamp(1.5rem, 3.4vw, 2.25rem);
  line-height: 1.2;
  font-weight: 560;
  font-stretch: 108%;
  letter-spacing: -0.01em;
}
.status {
  margin: 1rem 0 0;
  color: var(--mist);
}

.details {
  display: grid;
  gap: 2.75rem 4rem;
  margin: clamp(3.5rem, 8vw, 6rem) 0 0;
  padding: 2.5rem 0 0;
  border-top: 1px solid var(--rule);
}
@media (min-width: 52rem) {
  .details {
    grid-template-columns: 1fr 1fr;
  }
}
.details section {
  max-width: var(--measure);
}
.details h2 {
  margin: 0 0 0.6rem;
  font-size: 1.3125rem;
  line-height: 1.3;
  font-weight: 650;
  font-stretch: 112%;
}
.details p {
  margin: 0;
}
.details section + section {
  margin-top: 2.25rem;
}
.details ul {
  margin: 0;
  padding: 0;
  list-style: none;
}
.details li {
  padding: 0.55rem 0;
  border-bottom: 1px solid var(--rule);
}
.details li:first-child {
  border-top: 1px solid var(--rule);
}

footer {
  margin: clamp(4rem, 10vw, 7rem) 0 0;
  padding: 1.5rem 0 2.5rem;
  font-size: 0.875rem;
  color: var(--mist);
}
footer p {
  margin: 0 0 0.25rem;
  max-width: var(--measure);
}

/* 404 */
.missing {
  margin: clamp(3rem, 12vw, 8rem) 0 0;
  max-width: var(--measure);
}
.missing h1 {
  margin: 0 0 0.75rem;
  font-size: clamp(2rem, 6vw, 3.25rem);
  line-height: 1.1;
  font-weight: 800;
  font-stretch: 125%;
  letter-spacing: -0.02em;
}
.missing p {
  margin: 0 0 0.5rem;
}
