/* TERRA Lab · The air over the land. Forest scope like every Lab page: square corners, gold for the place and the chosen answer, a warm smoke tone for particles over the WHO line, sand for the depth of air. */
:root {
  --forest-deep: #161e19; --forest: #1f2a23; --sand: #e8e2d6; --sand-2: rgba(232,226,214,.8);
  --sand-3: rgba(232,226,214,.62); --line: rgba(232,226,214,.18); --line-2: rgba(232,226,214,.08);
  --gold: #c6a76a; --smoke: #d39a5c; --clear: #86b7a1; --depth: rgba(232,226,214,.22);
  --serif: "Source Serif 4", Georgia, "Times New Roman", serif;
  --sans: Inter, -apple-system, "Helvetica Neue", Arial, sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, Menlo, monospace;
  --descend: cubic-bezier(.22,1,.36,1);
  color-scheme: dark;
}
* { box-sizing: border-box; }
html, body { margin: 0; background: var(--forest-deep); color: var(--sand); font: 400 14px/1.5 var(--sans); }
button, input { font: inherit; color: inherit; }
a { color: var(--gold); }
:focus-visible { outline: 2px solid var(--gold); outline-offset: 2px; }
.mono { font-family: var(--mono); }
.micro { margin: 0; font: 500 12px var(--mono); letter-spacing: .12em; color: var(--sand-3); text-transform: uppercase; }
.fine { margin: 0; font-size: 12.5px; color: var(--sand-3); min-height: 1em; }
.fine:empty { display: none; }

.bar { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 16px; padding: 6px 20px; border-bottom: 1px solid var(--line); }
.mark { font-weight: 500; letter-spacing: .22em; font-size: 15px; }
.lablink { display: inline-flex; align-items: center; min-height: 44px; color: var(--sand); text-decoration: none; }
.lablink span { margin-left: .5em; letter-spacing: .08em; font-weight: 400; color: var(--gold); }
.lablink:hover, .lablink:hover span { color: var(--gold); text-decoration: underline; text-underline-offset: 4px; text-decoration-thickness: 1px; }
.exp { font-size: 11px; letter-spacing: .12em; color: var(--gold); border: 1px solid rgba(198,167,106,.45); padding: 2px 7px; }

/* the finder beside the reading on a wide screen, above it on a phone */
.air { display: grid; gap: 24px 36px; padding: 28px 20px 40px; max-width: 1180px; margin: 0 auto; grid-template-columns: minmax(280px, 380px) minmax(0, 1fr); align-items: start; }
@media (max-width: 860px) { .air { grid-template-columns: minmax(0, 1fr); padding: 18px 16px 32px; } }
.intro { display: flex; flex-direction: column; gap: 14px; }
@media (min-width: 861px) { .intro { position: sticky; top: 16px; } }
.eyebrow { margin: 0; font: 500 11px var(--mono); letter-spacing: .12em; color: var(--gold); text-transform: uppercase; }
h1 { margin: 0; font: 300 34px/1.1 var(--serif); letter-spacing: -.018em; text-wrap: balance; }
h2 { margin: 0; font: 300 28px/1.15 var(--serif); letter-spacing: -.018em; text-wrap: balance; }
.lede { margin: 0; font-size: 15px; line-height: 1.65; color: var(--sand-2); max-width: 46ch; }

.find { display: flex; flex-direction: column; gap: 8px; padding-top: 4px; }
.findrow { display: flex; gap: 6px; }
.findrow input { flex: 1; min-width: 0; min-height: 44px; padding: 0 12px; background: var(--forest); border: 1px solid var(--line); border-radius: 0; }
.findrow input:focus-visible { outline-offset: 0; }
.btn { min-height: 44px; padding: 0 14px; background: var(--sand); color: var(--forest-deep); border: 1px solid var(--sand); cursor: pointer; font-weight: 500; transition: background-color .18s var(--descend), color .18s var(--descend); }
.btn:hover { background: transparent; color: var(--sand); }
.btn.ghost { background: transparent; color: var(--sand); border-color: rgba(232,226,214,.35); align-self: flex-start; }
.btn.ghost:hover { border-color: var(--sand); }
.btn[disabled] { opacity: .5; cursor: progress; }

.places { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 6px; }
@media (max-width: 420px) { .places { grid-template-columns: minmax(0, 1fr); } }
.place { min-height: 52px; padding: 8px 10px; text-align: left; background: transparent; border: 1px solid var(--line); cursor: pointer; transition: border-color .18s var(--descend), background-color .18s var(--descend); }
.place:hover { border-color: rgba(232,226,214,.5); }
.place[aria-pressed="true"] { background: var(--forest); border-color: var(--gold); }
.place b { display: block; font-weight: 500; font-size: 13.5px; }
.place span { display: block; margin-top: 2px; font-size: 12px; line-height: 1.35; color: var(--sand-3); }

.reading { position: relative; display: flex; flex-direction: column; gap: 26px; min-width: 0; }
.loading { position: absolute; top: 0; right: 0; font-size: 11px; letter-spacing: .12em; color: var(--gold); opacity: 0; transition: opacity .3s var(--descend); }
.reading[aria-busy="true"] .loading { opacity: 1; }
.err { color: var(--smoke); }

.now { display: flex; flex-direction: column; gap: 10px; padding-bottom: 20px; border-bottom: 1px solid var(--line); }
.nowrow { display: flex; flex-wrap: wrap; align-items: baseline; gap: 6px 18px; }
.big { margin: 0; font: 300 64px/1 var(--serif); letter-spacing: -.02em; font-variant-numeric: tabular-nums; }
.big small { font: 400 13px var(--mono); color: var(--sand-3); margin-left: 6px; letter-spacing: .04em; }
.band { margin: 0; font: 500 12px var(--mono); letter-spacing: .12em; text-transform: uppercase; color: var(--clear); }
.band.over { color: var(--smoke); }
.nowline { margin: 0; font-size: 15px; color: var(--sand-2); max-width: 60ch; }

.block { display: flex; flex-direction: column; gap: 10px; border-top: 1px solid var(--line); padding-top: 14px; min-width: 0; }
.say { margin: 0; font-size: 15px; line-height: 1.6; color: var(--sand-2); max-width: 62ch; }
.say b { color: var(--sand); font-weight: 500; }
figure { margin: 0; display: flex; flex-direction: column; gap: 8px; }
figcaption { font-size: 12px; color: var(--sand-3); display: flex; flex-wrap: wrap; align-items: center; gap: 4px 8px; }
.sw { display: inline-block; width: 10px; height: 10px; }
.sw.smoke { background: var(--smoke); }
.sw.depth { background: var(--depth); }
svg.chart { width: 100%; max-width: 600px; height: auto; display: block; overflow: visible; }
svg.chart text { font: 400 9.5px var(--mono); fill: var(--sand-3); }
svg.chart text.hi { fill: var(--sand); }
svg.chart text.warm { fill: var(--smoke); }
svg.chart .grid { stroke: var(--line-2); stroke-width: 1; }
svg.chart .axis { stroke: var(--line); stroke-width: 1; }
svg.chart .depth { fill: var(--depth); }
svg.chart .pm { fill: rgba(232,226,214,.55); }
svg.chart .pm.over { fill: var(--smoke); }
svg.chart .who { stroke: var(--clear); stroke-dasharray: 3 3; stroke-width: 1; }
svg.chart .eu { stroke: var(--gold); stroke-dasharray: 3 3; stroke-width: 1; opacity: .8; }
svg.chart .us { stroke: var(--smoke); stroke-dasharray: 3 3; stroke-width: 1; opacity: .8; }
svg.chart .line { fill: none; stroke: var(--sand); stroke-width: 1.4; }
svg.chart .win { fill: rgba(134,183,161,.18); }
svg.chart .nowmark { stroke: var(--gold); stroke-width: 1.5; }
svg.chart .band-w { fill: rgba(211,154,92,.12); }
svg.chart .band-c { fill: rgba(134,183,161,.12); }

.sensors, .airing { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--line-2); }
.sensors li, .airing li { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 12px; padding: 9px 0; border-bottom: 1px solid var(--line-2); font-variant-numeric: tabular-nums; }
.sensors li span:first-child, .airing li span:first-child { min-width: 0; overflow-wrap: anywhere; }
.sensors small { display: block; color: var(--sand-3); font-size: 12px; }
.sensors b, .airing b { font: 300 20px/1.2 var(--serif); }
.sensors b.over { color: var(--smoke); }

.shares { margin: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.shares div { padding: 10px 10px 10px 0; display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.shares div + div { padding-left: 12px; border-left: 1px solid var(--line-2); }
.shares dd { margin: 0; font: 300 30px/1 var(--serif); font-variant-numeric: tabular-nums; }
.shares dd.over { color: var(--smoke); }
.shares dt { font: 400 10.5px/1.35 var(--mono); letter-spacing: .08em; text-transform: uppercase; color: var(--sand-3); order: 2; }

.notes { border-top: 1px solid var(--line); padding-top: 14px; }
.notes ul { margin: 8px 0 0; padding-left: 18px; color: var(--sand-2); display: flex; flex-direction: column; gap: 6px; max-width: 64ch; }
.cta { align-self: flex-start; display: inline-flex; align-items: center; min-height: 44px; padding: 0 16px; background: var(--sand); color: var(--forest-deep); text-decoration: none; font-weight: 500; border: 1px solid var(--sand); }
.cta:hover { background: transparent; color: var(--sand); }
.foot { padding: 16px 20px 28px; font-size: 11px; letter-spacing: .08em; color: var(--sand-3); border-top: 1px solid var(--line); }
@media (prefers-reduced-motion: reduce) { * { transition: none !important; } }
