/* VD-25b: the Overview is the Plane Poster composition (owner decision ADR-VD25-PLANE-POSTER-2026-11-16),
   ported from docs/design/intro_option_plane.html. Colours come only from design/tokens.css, so this
   file holds no hex literals. The hero, the four task bands and the schedule bleed to the viewport with
   the VD-22 technique: a 100vmax box-shadow clipped by inset(0 -100vmax). Shadows are paint, not layout,
   so they add no scrollable width. */

.atlas-overview {
  width: 100%;
}

/* [hidden] must win over the display rules below: a count group or note with no value is hidden. */
.atlas-overview [hidden] {
  display: none !important;
}

.atlas-overview :focus-visible {
  outline: 3px solid var(--atlas-accent);
  outline-offset: 3px;
}

/* A hidden label for the hero search. The shell has no global visually-hidden utility. */
.atlas-overview .visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}

.overview-caps {
  margin: 0;
  color: var(--atlas-muted);
  font: 600 0.75rem / 1.3 var(--atlas-font-display);
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

/* Hero: copy on the left, the four-plane figure on the right. Paper ground, no outline. */
.overview-hero,
.overview-band,
.overview-clock {
  position: relative;
  clip-path: inset(0 -100vmax);
}

.overview-hero {
  padding-block: clamp(2rem, 4.5vw, 3.75rem);
  background: var(--atlas-page);
  box-shadow: 0 0 0 100vmax var(--atlas-page);
}

.overview-hero__grid {
  display: grid;
  grid-template-columns: minmax(0, 0.95fr) minmax(0, 1.05fr);
  gap: clamp(1.5rem, 4vw, 4rem);
  align-items: center;
}

.overview-hero__copy {
  min-width: 0;
}

#observablehq-main .overview-title {
  margin: 0;
  color: var(--atlas-ink);
  font-family: var(--atlas-font-display);
  font-size: clamp(2.6rem, 1.5rem + 4vw, 4.75rem);
  font-weight: 800;
  font-stretch: var(--atlas-display-stretch);
  line-height: 0.95;
  letter-spacing: -0.02em;
  text-wrap: balance;
}

#observablehq-main .overview-lead {
  max-width: 46ch;
  margin: 1.4rem 0 0;
  color: var(--atlas-muted);
  font-size: 1.15rem;
  line-height: 1.5;
}

/* The four doors: swatch, task, count. Each row is the link; the count reserves its column. */
.overview-doors {
  max-width: none;
  margin: 2rem 0 0;
  padding: 0;
  list-style: none;
  border-top: 2px solid var(--atlas-ink);
}

#observablehq-main .overview-door,
#observablehq-main .overview-door:hover,
#observablehq-main .overview-door:focus-visible {
  position: relative;
  display: grid;
  grid-template-columns: 1.875rem minmax(0, 1fr) minmax(8.5rem, max-content);
  gap: 1.125rem;
  align-items: center;
  padding: 1rem 3.25rem 1rem 0;
  border-bottom: 1px solid var(--atlas-line);
  color: var(--atlas-ink);
  text-decoration: none;
  transition: padding-left 180ms cubic-bezier(0.2, 0.7, 0.2, 1);
}

.overview-door__swatch {
  display: block;
  width: 1.875rem;
  height: 1.875rem;
  background: var(--c);
}

.overview-door__task {
  font-family: var(--atlas-font-display);
  font-size: clamp(1.35rem, 1.1rem + 0.7vw, 1.75rem);
  font-weight: 700;
  font-stretch: 94%;
  line-height: 1.1;
  letter-spacing: -0.01em;
}

/* min-height reserves the count's line before the live value arrives (CLS). */
.overview-door__count {
  min-height: 1.4em;
  color: var(--atlas-muted);
  font-size: 0.9rem;
  font-variant-numeric: tabular-nums;
  text-align: right;
  white-space: nowrap;
}

.overview-door::after {
  content: "";
  position: absolute;
  top: 50%;
  right: 0;
  width: 2.125rem;
  height: 2.125rem;
  translate: 0 -50%;
  background: linear-gradient(135deg, transparent 50%, var(--atlas-ink) 50%), var(--c);
  clip-path: polygon(0 0, 100% 0, 100% 100%, 0 100%);
  opacity: 0;
  transform: scale(0.6);
  transition: opacity 180ms, transform 180ms;
}

.overview-door:hover,
.overview-door:focus-visible,
.overview-door.is-lit {
  padding-left: 0.625rem;
}

.overview-door:hover::after,
.overview-door:focus-visible::after,
.overview-door.is-lit::after {
  opacity: 1;
  transform: scale(1);
}

/* Site-wide search: the shared combobox attaches to form[data-atlas-site-search] and its first input. */
.overview-search {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 0.5rem;
  max-width: 34rem;
  margin: 1.875rem 0 0;
}

.overview-search__field {
  display: flex;
  min-width: 0;
}

.overview-search input {
  flex: 1 1 0;
  min-width: 0;
  min-height: 2.75rem;
  padding: 0.75rem 1rem;
  border: 2px solid var(--atlas-ink);
  border-right: 0;
  border-radius: var(--atlas-radius-control);
  background: var(--atlas-page);
  color: var(--atlas-ink);
  font: 400 1rem var(--atlas-font-body);
}

.overview-search input::placeholder {
  color: var(--atlas-faint);
}

.overview-search button {
  min-height: 2.75rem;
  padding: 0 1.625rem;
  border: 0;
  border-radius: var(--atlas-radius-control);
  background: linear-gradient(135deg, var(--atlas-ink) 74%, var(--atlas-vermilion) 74%);
  color: var(--atlas-on-brand);
  font: 700 0.85rem / 1 var(--atlas-font-display);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  cursor: pointer;
}

.overview-search button:hover {
  background: linear-gradient(135deg, var(--atlas-ink) 62%, var(--atlas-vermilion) 62%);
}

/* The figure: a clipPath of California with four flat planes. The planes take their colour from
   CSS (so the lit state can override it); the others fall back to the line tone. */
.overview-figure {
  position: relative;
  margin: 0;
  min-width: 0;
}

.overview-figure svg {
  display: block;
  width: 100%;
  height: auto;
  max-height: 86vh;
  overflow: hidden;
}

.overview-plane {
  cursor: pointer;
  transition: fill 220ms ease;
}

.overview-plane[data-plane="people"] {
  fill: var(--atlas-task-people);
}

.overview-plane[data-plane="water"] {
  fill: var(--atlas-task-water);
}

.overview-plane[data-plane="money"] {
  fill: var(--atlas-task-money);
}

.overview-plane[data-plane="evidence"] {
  fill: var(--atlas-task-evidence);
}

.overview-figure.has-lit .overview-plane:not(.is-lit) {
  fill: var(--atlas-line);
}

.overview-figure figcaption {
  position: absolute;
  right: 0;
  bottom: 0;
  writing-mode: vertical-rl;
}

@keyframes overview-settle {
  from {
    transform: translate(var(--dx), var(--dy));
  }

  to {
    transform: none;
  }
}

.overview-plane-g {
  animation: overview-settle 900ms cubic-bezier(0.16, 1, 0.3, 1) both;
}

/* Task bands: swatch, title, text, facts and the Explore links. Each band has a 1px rule on top
   that bleeds to the viewport (a pseudo-element with the same 100vmax paint, so no layout width). */
.overview-band {
  padding-block: clamp(1.75rem, 3.5vw, 3.25rem);
  background: var(--atlas-page);
  box-shadow: 0 0 0 100vmax var(--atlas-page);
}

.overview-band::before {
  content: "";
  position: absolute;
  inset: 0 0 auto;
  height: 1px;
  background: var(--atlas-line);
  box-shadow: 0 0 0 100vmax var(--atlas-line);
  clip-path: inset(0 -100vmax);
}

.overview-band__grid {
  display: grid;
  grid-template-columns: minmax(11rem, 18.75rem) minmax(0, 1fr);
  gap: clamp(1.25rem, 4vw, 3.5rem);
}

.overview-band__swatch {
  position: relative;
  min-height: 13.75rem;
  overflow: hidden;
  background: var(--c);
}

.overview-band__swatch svg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

#observablehq-main .overview-band__title {
  margin: 0;
  color: var(--atlas-ink);
  font-family: var(--atlas-font-display);
  font-size: clamp(1.9rem, 1.4rem + 1.8vw, 2.75rem);
  font-weight: 800;
  font-stretch: 90%;
  line-height: 1.02;
  letter-spacing: -0.02em;
  text-wrap: balance;
}

#observablehq-main .overview-band__text {
  max-width: 62ch;
  margin: 0.875rem 0 0;
}

/* Facts reserve one line per number (min-height on the figure, min-width on its digits), so a live
   value does not reflow the band. */
.overview-facts {
  display: flex;
  flex-wrap: wrap;
  gap: 0.875rem 2.5rem;
  max-width: none;
  margin: 1.375rem 0 0;
  padding: 0;
  list-style: none;
}

.overview-facts li {
  display: grid;
  min-width: 0;
  gap: 0.125rem;
  margin: 0;
}

.overview-facts b {
  min-width: 4.5ch;
  min-height: 1em;
  font: 800 2.25rem / 1 var(--atlas-font-display);
  font-stretch: 85%;
  font-variant-numeric: tabular-nums;
}

.overview-facts span {
  color: var(--atlas-muted);
}

.overview-go {
  display: flex;
  flex-wrap: wrap;
  gap: 0.625rem;
  margin-top: 1.5rem;
}

#observablehq-main .overview-go a,
#observablehq-main .overview-go a:visited,
#observablehq-main .overview-go a:hover {
  display: inline-flex;
  align-items: center;
  gap: 0.625rem;
  min-height: 2.75rem;
  padding: 0.6875rem 1rem;
  border: 2px solid var(--atlas-ink);
  color: var(--atlas-ink);
  font-weight: 600;
  text-decoration: none;
}

#observablehq-main .overview-go a:hover {
  background: var(--atlas-ink);
  color: var(--atlas-on-brand);
}

#observablehq-main .overview-go a::after {
  content: "";
  width: 0;
  height: 0;
  border-left: 7px solid var(--atlas-ink);
  border-block: 5px solid transparent;
}

#observablehq-main .overview-go a:hover::after {
  border-left-color: var(--c-arrow, var(--c));
}

/* How the Atlas stays current: the dark schedule section. */
.overview-clock {
  padding-block: clamp(2.25rem, 5vw, 4rem);
  background: var(--atlas-ink);
  color: var(--atlas-on-brand);
  box-shadow: 0 0 0 100vmax var(--atlas-ink);
}

#observablehq-main .overview-clock__title {
  margin: 0;
  color: var(--atlas-on-brand);
  font-family: var(--atlas-font-display);
  font-size: clamp(1.9rem, 1.4rem + 1.8vw, 2.75rem);
  font-weight: 800;
  font-stretch: 90%;
  line-height: 1.02;
  letter-spacing: -0.02em;
}

#observablehq-main .overview-clock__text {
  max-width: 62ch;
  margin: 0.875rem 0 0;
  color: var(--atlas-on-brand-muted);
}

/* The chart frame has the chart's own aspect ratio and a 760 px floor, so the SVG is sized before
   the script draws it and the notes below do not move. The wrapper scrolls on narrow screens. */
.overview-chart {
  margin-top: 1.625rem;
  overflow-x: auto;
}

.overview-chart__frame {
  width: 100%;
  min-width: 760px;
  aspect-ratio: 1000 / 260;
}

.overview-chart svg {
  display: block;
  width: 100%;
  height: 100%;
}

.overview-chart text {
  fill: var(--atlas-on-brand);
  font-family: var(--atlas-font-display);
}

.overview-notes {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(15rem, 1fr));
  gap: 1.125rem 2.5rem;
  margin-top: 1.875rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--atlas-faint);
}

.overview-notes h3 {
  margin: 0 0 0.375rem;
  color: var(--atlas-on-brand);
  font: 700 1.15rem / 1.2 var(--atlas-font-display);
}

#observablehq-main .overview-notes p {
  margin: 0;
  max-width: none;
  color: var(--atlas-on-brand-muted);
}

#observablehq-main .overview-notes .stat-note {
  margin-top: 0.5rem;
  font-size: var(--atlas-type-small-size);
  line-height: 1.45;
}

#observablehq-main .overview-notes .overview-refresh {
  min-height: 1.5em;
  margin-top: 0.5rem;
}

/* A 24 px hit area for the inline "Read the methods" and "glossary" links (WCAG 2.5.8). */
#observablehq-main .overview-notes a {
  display: inline-flex;
  align-items: center;
  min-height: 1.5rem;
}

#observablehq-main .overview-clock a,
#observablehq-main .overview-clock a:visited {
  color: var(--atlas-gold);
  text-underline-offset: 3px;
}

@media (max-width: 64rem) {
  .overview-hero__grid,
  .overview-band__grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .overview-figure {
    justify-self: center;
    width: 100%;
    max-width: 30rem;
  }

  .overview-band__swatch {
    min-height: 7.5rem;
  }
}

@media (max-width: 42rem) {
  .overview-figure {
    order: -1;
    max-width: 26rem;
  }

  .overview-figure figcaption {
    display: none;
  }
}

@media (max-width: 26rem) {
  #observablehq-main .overview-door,
  #observablehq-main .overview-door:hover,
  #observablehq-main .overview-door:focus-visible {
    grid-template-columns: 1.375rem minmax(0, 1fr);
    padding-right: 2.5rem;
  }

  .overview-door__swatch {
    width: 1.375rem;
    height: 1.375rem;
  }

  .overview-door__count {
    grid-column: 2;
    text-align: left;
  }
}

@media (prefers-reduced-motion: reduce) {
  .overview-door,
  .overview-door::after,
  .overview-plane,
  .overview-plane-g,
  .overview-go a {
    transition: none;
    animation: none;
  }
}

/* VD-27 (owner 2026-11-17): what the pipeline does, before the schedule. Four numbered task planes. */
.overview-engine {
  padding-block: clamp(2.25rem, 5vw, 4rem);
  background: var(--atlas-surface);
  box-shadow: 0 0 0 100vmax var(--atlas-surface);
  clip-path: inset(0 -100vmax);
}

.overview-engine__head {
  max-width: 62rem;
}

#observablehq-main .overview-engine__title {
  margin: 0.25rem 0 0;
  font-family: var(--atlas-font-display);
  font-size: clamp(1.9rem, 1.4rem + 1.8vw, 2.75rem);
  font-weight: 800;
  line-height: 1.05;
}

#observablehq-main .overview-engine__lead,
#observablehq-main .overview-engine__types {
  max-width: 62rem;
  margin: 0.875rem 0 0;
  font-size: 1.08rem;
}

#observablehq-main .overview-engine__types {
  min-height: 1.5em;
  color: var(--atlas-muted);
  font-size: var(--atlas-type-small-size);
  font-variant-numeric: tabular-nums;
}

.overview-pipeline {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(14.5rem, 1fr));
  gap: var(--atlas-space-4);
  margin: var(--atlas-space-8) 0 0;
  padding: 0;
  list-style: none;
}

.overview-pipe {
  position: relative;
  padding: var(--atlas-space-6) var(--atlas-space-5) var(--atlas-space-5);
  border: 1px solid var(--atlas-line);
  border-top: 6px solid var(--c);
  background: var(--atlas-page);
  transition: transform 160ms ease-out, box-shadow 160ms ease-out;
}

.overview-pipe:hover,
.overview-pipe:focus-within {
  box-shadow: 6px 6px 0 var(--c);
  transform: translate(-3px, -3px);
}

.overview-pipe__n {
  position: absolute;
  top: var(--atlas-space-4);
  right: var(--atlas-space-4);
  display: grid;
  width: 2rem;
  height: 2rem;
  place-items: center;
  background: var(--c);
  color: var(--atlas-on-brand);
  font: 800 1rem / 1 var(--atlas-font-display);
}

.overview-pipe[style*="task-money"] .overview-pipe__n {
  color: var(--atlas-ink);
}

#observablehq-main .overview-pipe h3 {
  margin: 0 2.5rem var(--atlas-space-2) 0;
  font: 800 1.3rem / 1.15 var(--atlas-font-display);
}

#observablehq-main .overview-pipe p {
  max-width: none;
  margin: 0;
  font-size: 0.95rem;
  line-height: 1.5;
}

#observablehq-main .overview-pipe .overview-pipe__also {
  margin-top: var(--atlas-space-3);
  padding-top: var(--atlas-space-3);
  border-top: 1px solid var(--atlas-line);
  color: var(--atlas-muted);
  font-size: var(--atlas-type-small-size);
}

@media (prefers-reduced-motion: reduce) {
  .overview-pipe {
    transition: none;
  }

  .overview-pipe:hover,
  .overview-pipe:focus-within {
    transform: none;
  }
}

#observablehq-main .overview-pipeline {
  max-width: none;
}

#observablehq-main .overview-pipe a {
  display: inline;
  min-height: 0;
}
