:root {
  --bg: #000;
  --fg: #fff;
  --dim: rgba(255, 255, 255, 0.45);
  --ring: rgba(255, 255, 255, 0.22);
  --font: "Jost", "Futura", "Helvetica Neue", sans-serif;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  background: var(--bg);
  color: var(--fg);
  font-family: var(--font);
  font-weight: 300;
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; }

.top {
  position: absolute; inset: 0 0 auto 0; z-index: 10;
  display: flex; justify-content: space-between; align-items: flex-start;
  padding: 22px 28px;
  font-size: 13px; letter-spacing: 0.22em; text-transform: uppercase;
  pointer-events: none;
}
.top a { pointer-events: auto; }

/* Directory-tree block under VAD/02 (├ └ connectors drawn with borders) */
.tree ul { list-style: none; }
.tree > ul { margin-top: 14px; }
.tree li {
  position: relative; padding-left: 22px;
  font-family: ui-monospace, "SF Mono", Menlo, monospace;
  font-size: 12px; letter-spacing: 0.04em; text-transform: none; line-height: 26px;
}
.tree li::before {
  content: ""; position: absolute; left: 4px; top: 0; bottom: 0;
  border-left: 1px solid var(--ring);
}
.tree li:last-child::before { bottom: auto; height: 13px; }
.tree li::after {
  content: ""; position: absolute; left: 4px; top: 13px; width: 12px;
  border-top: 1px solid var(--ring);
}
.tree .node { color: var(--dim); }
.tree .leaf { color: var(--fg); text-decoration: none; }
.tree .leaf img { display: inline-block; vertical-align: middle; height: 15px; width: auto; opacity: 0.9; }
.tree a.leaf:hover img { opacity: 1; }
.top-link { text-decoration: none; opacity: 0.7; }
.top-link:hover { opacity: 1; }

/* Hero: globe fills the viewport, title sits under it */
.hero { position: relative; height: 100svh; min-height: 560px; overflow: hidden; }
#globe { position: absolute; inset: 0; cursor: grab; }
#globe:active { cursor: grabbing; }
#globe canvas { display: block; }
#labels { position: absolute; inset: 0; pointer-events: none; }

.city-label {
  position: absolute; left: 0; top: 0;
  pointer-events: auto;
  font-size: 11px; letter-spacing: 0.18em; text-transform: uppercase;
  text-decoration: none; white-space: nowrap;
  padding: 3px 6px 3px 16px;
  background: rgba(0, 0, 0, 0.72);
  transition: opacity 0.25s;
  will-change: transform;
}
.city-label::before {
  content: ""; position: absolute; left: 0; top: 50%;
  width: 10px; height: 1px; background: var(--fg);
}
.city-label.left { padding: 3px 16px 3px 6px; }
.city-label.left::before { left: auto; right: 0; }
.city-label.soon { color: rgba(255, 255, 255, 0.7); cursor: default; }
.city-label:not(.soon):hover { text-decoration: underline; text-underline-offset: 4px; }

.hero-text {
  position: absolute; left: 0; right: 0; bottom: 9svh;
  text-align: center; pointer-events: none;
  padding: 0 20px;
}
h1 {
  font-weight: 200;
  font-size: clamp(44px, 9vw, 128px);
  letter-spacing: 0.08em;
  line-height: 1;
}
.tagline { margin-top: 18px; font-size: clamp(15px, 1.6vw, 19px); }
.meta {
  margin-top: 10px; font-size: 12px; letter-spacing: 0.24em;
  text-transform: uppercase; color: var(--dim);
}
.scroll-cue {
  position: absolute; left: 50%; bottom: 22px; transform: translateX(-50%);
  font-size: 11px; letter-spacing: 0.24em; text-transform: uppercase;
  text-decoration: none; color: var(--dim);
}
.scroll-cue:hover { color: var(--fg); }

/* Clock grid, after the "THE FORM" poster: thin rings, white hands */
.cities { padding: 18vh 24px 12vh; max-width: 980px; margin: 0 auto; }
h2 {
  text-align: center; font-weight: 300;
  font-size: clamp(22px, 3vw, 34px); letter-spacing: 0.02em;
  margin-bottom: 72px;
}
.clocks {
  display: grid; grid-template-columns: repeat(3, 1fr);
  gap: 56px 32px;
}
.clock {
  display: flex; flex-direction: column; align-items: center;
  text-decoration: none; gap: 14px;
}
.clock-city { font-size: 19px; font-weight: 400; }
.clock svg { width: min(100%, 180px); height: auto; overflow: visible; }
.clock .face { fill: none; stroke: var(--ring); stroke-width: 1.2; transition: stroke 0.3s; }
.clock .hand { stroke: var(--fg); stroke-linecap: round; }
.clock .hand.h { stroke-width: 2.4; }
.clock .hand.m { stroke-width: 1.8; }
.clock .pin { fill: var(--fg); }
.clock-status {
  text-align: center; white-space: nowrap;
  font-size: 11px; letter-spacing: 0.22em; text-transform: uppercase; color: var(--dim);
}
a.clock:not(.soon):hover .face { stroke: var(--fg); }
a.clock:not(.soon) .clock-status { color: var(--fg); }
.clock.soon { cursor: default; }

/* Word-search box + footer share the last screen; the sentence lights up
   word by word once the box is in view. */
.finale { min-height: 100svh; display: flex; flex-direction: column; }
.about { flex: 1; display: flex; align-items: center; justify-content: center; padding: 48px 16px; }
.letter-grid {
  display: grid; grid-template-columns: repeat(var(--cols), 1fr);
  gap: clamp(6px, 1.3vw, 14px) clamp(4px, 1.2vw, 14px);
  font-weight: 400; font-size: clamp(13px, 2.1vw, 22px);
  text-align: center; user-select: none;
}
.letter-grid span {
  width: 1.6em; line-height: 1.6em;
  color: rgba(255, 255, 255, 0.2);
  transition: color 0.35s, font-weight 0.35s;
}
.letter-grid span.lit { color: var(--fg); font-weight: 500; }
.sr-only {
  position: absolute; width: 1px; height: 1px; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap;
}

.foot {
  border-top: 1px solid var(--ring);
  padding: 28px; display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap;
  font-size: 12px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--dim);
}
.foot a { color: var(--fg); text-underline-offset: 4px; }

@media (max-width: 640px) {
  .clocks { gap: 40px 14px; }
  .clock-city { font-size: 14px; }
  .city-label { font-size: 9px; letter-spacing: 0.12em; }
  .top { padding: 18px 18px; }
  .tree li { font-size: 10px; line-height: 20px; padding-left: 18px; }
  .tree li:last-child::before { height: 10px; }
  .tree li::after { top: 10px; width: 9px; }
  .tree .leaf img { height: 12px; }
  .letter-grid span { width: 1.3em; line-height: 1.5em; }
  .clock-status { font-size: 9px; letter-spacing: 0.14em; }
  .meta { letter-spacing: 0.14em; font-size: 11px; }
}

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