/* TERRA Lab · The land at dawn. Forest scope around the relief plate; the light comes up as flat layers thinning over it. Gold is the deed line and the bird that is singing. Square corners. */
: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);
  --gold: #c6a76a; --night: #121c26; --dawn: #d8874f;
  --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; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.mono { font-family: var(--mono); }
.micro { margin: 0; font: 500 12px var(--mono); letter-spacing: .12em; color: var(--sand-3); text-transform: uppercase; }

.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: 12px; letter-spacing: .12em; color: var(--gold); border: 1px solid rgba(198,167,106,.45); padding: 2px 7px; }

/* intro and the birds beside the plate on a wide screen, stacked in reading order on a phone */
.dawn { display: grid; gap: 20px 28px; padding: 24px 20px 40px; max-width: 1280px; margin: 0 auto;
  grid-template-columns: minmax(0, 78vh) minmax(300px, 400px); grid-template-areas: "stage intro" "stage read"; align-items: start; justify-content: center; }
.intro { grid-area: intro; display: flex; flex-direction: column; gap: 12px; }
.stagecol { grid-area: stage; display: flex; flex-direction: column; gap: 10px; min-width: 0; }
.read { grid-area: read; display: flex; flex-direction: column; gap: 16px; min-width: 0; }
@media (min-width: 861px) { .stagecol { position: sticky; top: 16px; } }
@media (max-width: 860px) {
  .dawn { grid-template-columns: minmax(0, 1fr); grid-template-areas: "intro" "stage" "read"; padding: 16px 16px 32px; }
}

.eyebrow { margin: 0; font: 500 12px var(--mono); letter-spacing: .12em; color: var(--gold); text-transform: uppercase; }
h1 { margin: 0; font: 300 34px/1.1 var(--serif); letter-spacing: -.018em; }
.lede { margin: 0; font-size: 15px; line-height: 1.65; color: var(--sand-2); max-width: 44ch; }

.lands { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 6px; margin-top: 4px; }
.land { display: flex; flex-direction: column; justify-content: flex-start; 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); }
.land:hover { border-color: rgba(232,226,214,.5); }
.land[aria-pressed="true"] { background: var(--forest); border-color: var(--gold); }
.land b { display: block; font-weight: 500; font-size: 13.5px; }
.land span { display: block; margin-top: 2px; font-size: 12px; line-height: 1.35; color: var(--sand-3); }
.land .count { font-family: var(--mono); letter-spacing: .04em; }

/* the plate: relief, then the night and the warm light as flat layers, then the deed line above them all */
.stage { position: relative; width: 100%; aspect-ratio: 1; max-height: 78vh; background: #c9cfc1; border: 1px solid rgba(232,226,214,.14); overflow: hidden; }
@media (min-width: 861px) { .stage { max-width: 78vh; } }
.stage > img, .stage > .layer, .stage > svg.ring { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
.stage > img { object-fit: fill; }
.layer { pointer-events: none; transition: opacity 1.2s linear; }
.layer.night { background: var(--night); opacity: .82; }
.layer.warm { background: var(--dawn); opacity: 0; mix-blend-mode: overlay; }
.ring { pointer-events: none; }

.where { position: absolute; top: 10px; right: 10px; width: 132px; padding: 6px 6px 4px; background: rgba(22,30,25,.72); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); border: 1px solid rgba(232,226,214,.14); pointer-events: none; }
.where svg { display: block; width: 100%; height: auto; }
.where p { margin: 2px 0 0; font: 500 12px/1.3 var(--mono); letter-spacing: .04em; color: var(--sand-3); text-transform: uppercase; text-align: center; }
.where .pt { fill: rgba(232,226,214,.55); transition: fill .3s var(--descend); }
.where .pt.on { fill: var(--gold); }
.caption { position: absolute; left: 10px; bottom: 10px; max-width: calc(100% - 20px); padding: 5px 8px; background: rgba(22,30,25,.72); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); border: 1px solid rgba(232,226,214,.14); font: 500 12px/1.4 var(--mono); letter-spacing: .08em; color: var(--sand); text-transform: uppercase; pointer-events: none; }
.caption b { font-weight: 500; color: var(--gold); }
@media (max-width: 480px) { .where { width: 108px; } .where p { letter-spacing: 0; } }

.controls { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px; }
.btn { min-height: 44px; padding: 0 18px; border: 1px solid var(--sand); background: var(--sand); color: var(--forest-deep); font-weight: 500; font-size: 13px; cursor: pointer; transition: background-color .18s var(--descend), color .18s var(--descend), border-color .18s var(--descend); }
.btn:hover:not([disabled]), .btn:active:not([disabled]) { background: transparent; color: var(--sand); }
.btn.ghost { background: transparent; color: var(--sand); border-color: rgba(232,226,214,.35); }
.btn.ghost:hover:not([disabled]) { border-color: var(--sand); }
.btn[disabled] { opacity: .45; cursor: not-allowed; }
.vol { display: inline-flex; align-items: center; gap: 10px; min-height: 44px; margin-left: auto; }
.vol input { width: 128px; height: 44px; margin: 0; background: transparent; cursor: pointer; -webkit-appearance: none; appearance: none; }
.vol input::-webkit-slider-runnable-track { height: 2px; background: rgba(232,226,214,.45); }
.vol input::-webkit-slider-thumb { -webkit-appearance: none; width: 14px; height: 14px; margin-top: -6px; background: var(--sand); border: 0; border-radius: 0; }
.vol input::-moz-range-track { height: 2px; background: rgba(232,226,214,.45); }
.vol input::-moz-range-thumb { width: 14px; height: 14px; background: var(--sand); border: 0; border-radius: 0; }
.vol input:focus-visible { outline-offset: 0; }
@media (max-width: 480px) { .vol { margin-left: 0; } }
.status { margin: 0; font-size: 13px; line-height: 1.55; color: var(--sand-2); }
.status.thin { border-left: 2px solid var(--gold); padding-left: 10px; color: var(--sand); }

.facts { margin: 0; font-size: 12px; letter-spacing: .1em; color: var(--sand-3); text-transform: uppercase; border-bottom: 1px solid var(--line); padding-bottom: 12px; }

/* the birds, in the order they come in */
.birds { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; }
.bird { border-bottom: 1px solid rgba(232,226,214,.08); border-left: 2px solid transparent; padding: 2px 0 8px 10px; transition: border-color .3s var(--descend), background-color .3s var(--descend); }
.bird.on { border-left-color: var(--gold); background: rgba(31,42,35,.9); }
.say { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: baseline; gap: 0 10px; width: 100%; min-height: 44px; padding: 6px 0 2px; text-align: left; background: transparent; border: 0; cursor: pointer; }
.say .nm { font-size: 14px; font-weight: 500; color: var(--sand-2); transition: color .3s var(--descend); }
.say .sci { grid-column: 1; font: italic 300 13px/1.35 var(--serif); color: var(--sand-3); }
.say .km { grid-column: 2; grid-row: 1; font-size: 12px; color: var(--sand-3); white-space: nowrap; }
.say:hover .nm, .bird.on .say .nm { color: var(--sand); }
.say[aria-pressed="true"] .nm { color: var(--gold); }
.say .hearone { grid-column: 2; grid-row: 2; font: 500 12px var(--mono); letter-spacing: .1em; color: var(--sand-3); text-transform: uppercase; opacity: 0; transition: opacity .18s var(--descend); }
.say:hover .hearone, .say:focus-visible .hearone, .say[aria-pressed="true"] .hearone { opacity: 1; }
.credit { margin: 0; font-size: 12px; line-height: 1.5; color: var(--sand-3); }
.credit a { color: var(--sand-2); text-underline-offset: 3px; text-decoration-thickness: 1px; display: inline-block; padding: 2px 0; }
.credit a:hover { color: var(--gold); }
.bird.failed .say { cursor: default; }
.empty { margin: 0; font-size: 13px; color: var(--sand-3); }
.small { margin: 0; font-size: 13px; line-height: 1.5; color: var(--sand-3); }

.figs { margin: 0; display: flex; flex-direction: column; gap: 14px; border-top: 1px solid var(--line); padding-top: 14px; }
.figs dd { margin: 4px 0 0; font: 300 18px/1.45 var(--serif); color: var(--sand); }
.figs dd .n { font: 400 15px var(--mono); color: var(--sand); }
.notes { border-top: 1px solid var(--line); padding-top: 12px; }
.notes ul { margin: 8px 0 0; padding-left: 18px; display: flex; flex-direction: column; gap: 6px; font-size: 13px; line-height: 1.55; color: var(--sand-2); }
.notes li::marker { color: var(--gold); }
.cta { display: inline-flex; align-items: center; min-height: 44px; font-size: 13px; letter-spacing: .12em; text-transform: uppercase; color: var(--gold); text-decoration: none; }
.cta:hover, .cta:active { color: var(--sand); }

.foot { max-width: 1280px; margin: 0 auto; padding: 16px 20px 28px; border-top: 1px solid var(--line); font-size: 12px; letter-spacing: .04em; color: var(--sand-3); }
.foot a { display: inline-block; padding: 12px 0; }

@media (prefers-reduced-motion: reduce) {
  .land, .btn, .bird, .say .nm, .say .hearone, .where .pt, .layer { transition: none; }
}
