/* Generated reference pages: LiDAR map hubs, place pages, guides, the 404.
   Tokens from _shared.css. Typographic hierarchy over boxes: rules and spacing
   separate sections; the only framed objects are the figures and the map key. */

.seo-main { padding-top: 132px; padding-bottom: var(--sp-xxl); }
.seo-head { max-width: 820px; }
.seo-crumbs { font: 500 11px/1.5 var(--font-mono); letter-spacing: 0.06em; text-transform: uppercase; color: var(--t2); margin-bottom: 22px; }
.seo-crumbs a { color: var(--t2); border-bottom: 1px solid transparent; transition: color var(--dur-fast), border-color var(--dur-fast); }
.seo-crumbs a:hover { color: var(--gold); border-color: var(--rule-strong); }
.seo-crumbs span[aria-hidden] { margin: 0 6px; color: var(--t3); }

.seo h1 { font-family: var(--font-display); font-weight: 400; font-size: clamp(38px, 5.4vw, 64px); line-height: 1.04; color: var(--t1); letter-spacing: -0.005em; }
.seo-lede { margin-top: 22px; font: 400 18px/1.65 var(--font-body); color: var(--t1-soft); max-width: 720px; }
.seo-actions { margin-top: 30px; display: flex; flex-wrap: wrap; gap: 14px; align-items: center; }
.seo-note { font: 400 13px/1.6 var(--font-body); color: var(--t2); }

.seo-figure { margin: 48px 0 0; }
.seo-figure img { display: block; width: 100%; height: auto; border-radius: var(--r-md); border: 1px solid var(--border); background: var(--surface); }
.seo-figure figcaption { margin-top: 12px; font: 400 13px/1.55 var(--font-body); color: var(--t2); max-width: 820px; }

.seo-body { max-width: 760px; }
.seo-body h2 { font-family: var(--font-display); font-weight: 400; font-size: clamp(26px, 3.2vw, 36px); line-height: 1.14; color: var(--t1); margin-top: 64px; padding-top: 26px; border-top: 1px solid var(--border); }
.seo-body h3 { font-family: var(--font-display); font-weight: 500; font-size: 22px; line-height: 1.25; color: var(--t1); margin-top: 34px; }
.seo-body p, .seo-body li { font: 400 16px/1.72 var(--font-body); color: var(--t1-soft); }
.seo-body p + p { margin-top: 1em; }
.seo-body ul, .seo-body ol { padding-left: 1.3em; margin-top: 1em; }
.seo-body li + li { margin-top: 0.45em; }
.seo-body a, .seo-facts a, .seo-list a, .seo-head a:not(.btn) { color: var(--gold); border-bottom: 1px solid var(--rule); transition: color var(--dur-fast), border-color var(--dur-fast); }
.seo-body a:hover, .seo-facts a:hover, .seo-list a:hover, .seo-head a:not(.btn):hover { color: var(--gold-bright); border-color: var(--gold); }
.seo-body strong { color: var(--t1); font-weight: 600; }
.seo-body code { font: 400 14px/1 var(--font-mono); color: var(--t1); }

/* Facts: a two-column definition list, ruled like a register entry. */
.seo-facts { margin-top: 40px; display: grid; grid-template-columns: minmax(150px, 220px) 1fr; max-width: 760px; border-top: 1px solid var(--border); }
.seo-facts dt, .seo-facts dd { padding: 13px 0; border-bottom: 1px solid var(--border); }
.seo-facts dt { font: 500 11px/1.6 var(--font-mono); letter-spacing: 0.06em; text-transform: uppercase; color: var(--t2); padding-right: 18px; }
.seo-facts dd { font: 400 15px/1.6 var(--font-body); color: var(--t1); }

/* Lists of places / counties: plain columns, name then a quiet second line. */
.seo-list { list-style: none; padding: 0; margin-top: 22px; columns: 3 240px; column-gap: 40px; }
.seo-list li { break-inside: avoid; padding: 9px 0; border-bottom: 1px solid var(--border); font: 400 15px/1.45 var(--font-body); color: var(--t1); }
.seo-list li small { display: block; margin-top: 2px; font: 400 12.5px/1.45 var(--font-body); color: var(--t2); }
.seo-list--wide { columns: 2 320px; }

.seo-stats { margin-top: 36px; display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 0; border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); max-width: 900px; }
.seo-stats div { padding: 18px 20px 18px 0; }
.seo-stats b { display: block; font: 400 32px/1.05 var(--font-display); color: var(--t1); }
.seo-stats span { display: block; margin-top: 6px; font: 500 11px/1.5 var(--font-mono); letter-spacing: 0.06em; text-transform: uppercase; color: var(--t2); }

.seo-sources { margin-top: 64px; padding-top: 22px; border-top: 1px solid var(--border); max-width: 820px; }
.seo-sources h2 { font: 600 10.5px/1 var(--font-body); letter-spacing: var(--tr-label); text-transform: uppercase; color: var(--gold-dim); margin: 0 0 14px; padding: 0; border: 0; }
.seo-sources p, .seo-sources li { font: 400 13px/1.65 var(--font-body); color: var(--t2); }
.seo-sources ul { padding-left: 1.2em; }

@media (max-width: 640px) {
  .seo-main { padding-top: 112px; }
  .seo-facts { grid-template-columns: 1fr; }
  .seo-facts dt { padding-bottom: 0; border-bottom: 0; }
  .seo-lede { font-size: 17px; }
}
.seo-subhead { font-family: var(--font-display); font-weight: 500; font-size: 22px; color: var(--t1); margin-top: 40px; max-width: 760px; }
.seo-figure figcaption a { color: var(--gold); border-bottom: 1px solid var(--rule); }

/* near-me finder */
.nm-form { margin-top: 30px; max-width: 760px; }
.nm-label { display: block; font: 500 11px/1 var(--font-mono); letter-spacing: 0.06em; text-transform: uppercase; color: var(--t2); margin-bottom: 10px; }
.nm-row { display: flex; flex-wrap: wrap; gap: 12px; align-items: stretch; }
.nm-row input { flex: 1 1 260px; min-height: 50px; padding: 0 16px; border-radius: var(--r-md); border: 1px solid var(--rule-strong);
  background: var(--surface); color: var(--t1); font: 400 16px/1 var(--font-body); }
.nm-row input:focus-visible { outline: 1px solid var(--gold-ink); outline-offset: 2px; }
#nm-status { margin-top: 12px; min-height: 1.4em; }
#nm-out .btn { margin-top: 6px; }

/* ── The live map in the page: a window onto the app (generated.window_html, seo-window.js) ──────────
   A framed object in the page, not the page: a key per layer along its top, the app in a 16:9 frame (square on a
   phone) with the still as its poster, what the layer is under it, and the call to open the whole of Waystone in a
   ruled band at its foot. Gold only as state: the selected key, the live mark, the lit filament of the call. */
.ws-window { margin-top: 44px; max-width: 1000px; border: 1px solid var(--rule-strong); border-radius: var(--r-card); overflow: hidden;
  background: var(--surface); box-shadow: inset 0 1px 0 rgba(255,255,255,0.03), 0 30px 70px -20px rgba(0,0,0,0.6), 0 2px 8px rgba(0,0,0,0.3); }
.ws-window-head { display: flex; align-items: stretch; justify-content: space-between; gap: 12px; padding: 0 14px 0 6px;
  background: var(--raised); border-bottom: 1px solid var(--border); }
.ws-window-tabs { display: flex; min-width: 0; overflow-x: auto; scrollbar-width: none; }
.ws-window-tabs::-webkit-scrollbar { display: none; }
.ws-window-tabs button { flex: 0 0 auto; padding: 16px 14px 14px; background: none; border: 0; border-bottom: 2px solid transparent; cursor: pointer;
  color: var(--t2); font: 500 13.5px/1 var(--font-body); white-space: nowrap; transition: color var(--dur-fast), border-color var(--dur-fast); }
.ws-window-tabs button:hover { color: var(--t1); }
.ws-window-tabs button[aria-selected="true"] { color: var(--gold-ink); border-bottom-color: var(--gold); }
.ws-window-tabs button:focus-visible { outline: 1px solid var(--gold-ink); outline-offset: -4px; }
.ws-window-tools { flex: 0 0 auto; display: flex; align-items: center; gap: 18px; }
.ws-window-state { display: inline-flex; align-items: center; gap: 8px; font: 500 10.5px/1 var(--font-mono); letter-spacing: 0.12em; text-transform: uppercase; color: var(--t2); }
.ws-window-state::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--t3); transition: background var(--dur-base), box-shadow var(--dur-base); }
.ws-window[data-state="loading"] .ws-window-state::before { background: var(--gold-dim); animation: ws-window-blink 1.1s var(--ease-in-out) infinite alternate; }
.ws-window[data-state="live"] .ws-window-state { color: var(--gold-ink); }
.ws-window[data-state="live"] .ws-window-state::before { background: var(--gold-ink); box-shadow: 0 0 0 3px rgba(244,213,141,0.14), 0 0 10px rgba(244,213,141,0.45); }
@keyframes ws-window-blink { from { opacity: 0.35; } to { opacity: 1; } }
.ws-window-full { font: 500 12.5px/1 var(--font-body); color: var(--t1-soft); padding: 8px 0; border-bottom: 1px solid var(--rule-strong); transition: color var(--dur-fast), border-color var(--dur-fast); }
.ws-window-full:hover { color: var(--gold-bright); border-color: var(--gold); }

.ws-window-frame { position: relative; aspect-ratio: 16 / 9; background: #0a0f1a; overflow: hidden; }
.ws-window-frame > img, .ws-window-app { position: absolute; inset: 0; width: 100%; height: 100%; display: block; border: 0; }
.ws-window-frame > img { object-fit: cover; }
.ws-window-app { opacity: 0; background: #0a0f1a; transition: opacity var(--dur-slow) var(--ease-out); }
.ws-window-app.is-in { opacity: 1; }
.ws-window-status { position: absolute; left: 14px; bottom: 14px; z-index: 2; pointer-events: none; padding: 8px 12px 9px; border-radius: var(--r-sm);
  background: rgba(10,15,26,0.86); border: 1px solid var(--rule); color: var(--t1-soft); font: 500 11px/1 var(--font-mono); letter-spacing: 0.06em; }
.ws-window-status:empty { display: none; }
.ws-window-veil { position: absolute; inset: 0; z-index: 3; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 14px; padding: 20px;
  background: radial-gradient(70% 60% at 50% 50%, rgba(11,13,18,0.62), rgba(11,13,18,0.18)); }
.ws-window-veil[hidden] { display: none; }
.ws-window-hint { max-width: 280px; text-align: center; font: 400 13.5px/1.45 var(--font-body); color: var(--t1); text-shadow: 0 1px 10px rgba(0,0,0,0.9); }

.ws-window-cap { padding: 16px 22px 0; }
.ws-window-cap p { max-width: 820px; font: 400 13.5px/1.6 var(--font-body); color: var(--t2); }
.ws-window-cap b { color: var(--t1); font-weight: 600; }
.ws-window-cap a { color: var(--gold); border-bottom: 1px solid var(--rule); white-space: nowrap; }
.ws-window-cap a:hover { color: var(--gold-bright); border-color: var(--gold); }

.ws-window-cta { margin-top: 18px; display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 28px; align-items: center; padding: 24px 24px 26px;
  border-top: 1px solid var(--rule); background: linear-gradient(180deg, rgba(201,168,76,0.075), rgba(201,168,76,0.015)); }
.ws-window-cta h2 { font-family: var(--font-display); font-weight: 400; font-size: clamp(25px, 2.6vw, 31px); line-height: 1.12; color: var(--t1); }
.ws-window-cta p { margin-top: 8px; max-width: 580px; font: 400 14.5px/1.6 var(--font-body); color: var(--t1-soft); }
.ws-window-go { padding: 20px 30px 21px; font-size: 12.5px; white-space: nowrap; }

/* the call again on a phone, once the window has scrolled away: the same lit key, held at the foot */
.seo-sticky-cta { position: fixed; left: 12px; right: 12px; bottom: calc(12px + env(safe-area-inset-bottom)); z-index: 50; display: flex; justify-content: center; gap: 10px;
  padding: 17px 18px 19px; border-radius: var(--r-key); color: var(--gold-ink); font: 500 12px/1.2 var(--font-body); letter-spacing: 0.16em; text-transform: uppercase; text-align: center;
  background: linear-gradient(145deg, rgba(9,13,23,0.97), rgba(26,31,44,0.95)); border: 1px solid var(--rule-strong);
  box-shadow: 0 14px 34px rgba(0,0,0,0.6), inset 0 0 26px rgba(244,213,141,0.12);
  transform: translateY(0); transition: transform 260ms var(--ease-out), opacity 260ms; }
.seo-sticky-cta::after { content: ""; position: absolute; left: 14px; right: 14px; bottom: 6px; height: 2.5px; border-radius: 2px;
  background: linear-gradient(90deg, rgba(201,168,76,0.5), var(--gold-ink) 55%, var(--gold-ink)); box-shadow: 0 0 6px rgba(244,213,141,0.5); }
.seo-sticky-cta[hidden] { display: flex; transform: translateY(150%); opacity: 0; pointer-events: none; }
@media (min-width: 981px) { .seo-sticky-cta { display: none !important; } }

@media (max-width: 760px) {
  .ws-window { margin-top: 32px; border-radius: var(--r-lg); }
  .ws-window-head { padding: 0 2px; }
  .ws-window-tabs { flex: 1 1 auto; }
  .ws-window-tabs button { flex: 1 0 auto; padding: 15px 8px 13px; font-size: 12.5px; }
  .ws-window-tools { display: none; }
  .ws-window-frame { aspect-ratio: 1 / 1; }
  .ws-window-cap { padding: 14px 16px 0; }
  .ws-window-cta { grid-template-columns: 1fr; gap: 18px; padding: 20px 16px 20px; }
  .ws-window-go { justify-content: center; white-space: normal; text-align: center; line-height: 1.35; }
}
@media (prefers-reduced-motion: reduce) {
  .ws-window-app, .seo-sticky-cta { transition: none; }
  .ws-window[data-state="loading"] .ws-window-state::before { animation: none; }
}

/* layer pages: slivers of the live app, each loaded on request (seo-layers.js) */
.seo-layers { margin-top: 8px; }
.layer-slot, .layer-frame { margin-top: 16px; width: 100%; aspect-ratio: 16 / 10; border-radius: var(--r-md); border: 1px solid var(--border); }
.layer-slot { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 12px;
  background: radial-gradient(120% 90% at 50% 0%, rgba(201,168,76,0.08), transparent 60%), var(--surface); }
.layer-frame { display: block; background: #0a0f1a; }
@media (max-width: 760px) {
  .layer-slot, .layer-frame { aspect-ratio: 4 / 5; }
}

/* monument-type pages: examples on the LiDAR */
.type-examples { list-style: none; padding: 0; margin-top: 18px; display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 16px; }
.type-ex a { display: block; color: var(--t1); }
.type-ex img { display: block; width: 100%; height: auto; aspect-ratio: 16 / 10; object-fit: cover; border-radius: var(--r-md); border: 1px solid var(--border); }
.type-ex span { display: block; margin-top: 8px; font: 500 15px/1.3 var(--font-body); }
.type-ex small { display: block; font: 400 12.5px var(--font-body); color: var(--t2); }
.seo-what { margin-left: 8px; font: 400 12px var(--font-body); color: var(--t2); }

/* layer landing pages: worked examples, each its own live map */
.feature-exs { display: grid; grid-template-columns: repeat(auto-fill, minmax(420px, 1fr)); gap: 26px; margin-top: 8px; }
.feature-ex h3 { margin-top: 0; font-family: var(--font-display); font-weight: 500; font-size: 22px; color: var(--t1); }
.feature-ex p { margin-top: 6px; font: 400 14.5px/1.6 var(--font-body); color: var(--t1-soft); }
@media (max-width: 760px) { .feature-exs { grid-template-columns: 1fr; } }

/* the signature on guides and type pages: who publishes it, and when it last changed */
.seo-byline { margin-top: 14px; font: 500 11px/1.5 var(--font-mono); letter-spacing: 0.06em; text-transform: uppercase; color: var(--t2); }
.seo-head .seo-byline a { color: var(--t1-soft); border-bottom: 1px solid var(--rule-strong); }
.seo-head .seo-byline a:hover { color: var(--gold-bright); border-color: var(--gold); }

/* /embed/: the builder (seo-embed.js), the choices on the left and the map with its code on the right */
.em { margin-top: 36px; display: grid; grid-template-columns: minmax(0, 340px) minmax(0, 1fr); gap: 36px; align-items: start; }
.em-form .nm-row input { width: 100%; }
.em-hits { list-style: none; padding: 0; margin: 10px 0 0; border-top: 1px solid var(--border); }
.em-hits:empty { display: none; }
.em-hits li { border-bottom: 1px solid var(--border); }
.em-hits button { display: block; width: 100%; padding: 10px 2px; background: none; border: 0; text-align: left; cursor: pointer; color: var(--t1); font: 400 15px/1.4 var(--font-body); }
.em-hits button:hover, .em-hits button:focus-visible { color: var(--gold-bright); }
.em-hits small { display: block; font: 400 12.5px/1.4 var(--font-body); color: var(--t2); }
.em-set { margin-top: 26px; border: 0; padding: 0; }
.em-opt { display: flex; align-items: center; gap: 10px; padding: 7px 0; font: 400 15px/1.4 var(--font-body); color: var(--t1-soft); cursor: pointer; }
.em-opt input { accent-color: #C9A84C; }
.em-place { font: 400 14px/1.5 var(--font-body); color: var(--t2); min-height: 1.5em; }
.em-place b { color: var(--t1); font-weight: 600; }
.em-preview { margin-top: 12px; width: 100%; aspect-ratio: 16 / 9; border: 1px solid var(--rule-strong); border-radius: var(--r-card); overflow: hidden;
  background: radial-gradient(120% 90% at 50% 0%, rgba(201,168,76,0.07), transparent 60%), var(--surface); }
.em-preview iframe { display: block; width: 100%; height: 100%; border: 0; }
.em-out .nm-label { margin-top: 22px; }
.em-code { display: block; width: 100%; padding: 14px 16px; border-radius: var(--r-md); border: 1px solid var(--rule-strong); background: var(--surface);
  color: var(--t1); font: 400 12.5px/1.6 var(--font-mono); resize: vertical; }
.em-code:focus-visible { outline: 1px solid var(--gold-ink); outline-offset: 2px; }
@media (max-width: 900px) { .em { grid-template-columns: 1fr; gap: 28px; } }

/* updates by email, in the footer (seo-updates.js; on with SEO_UPDATES=1) */
.foot-updates { margin-top: 28px; }
.foot-updates h4 { font: 600 10px/1 var(--font-body); letter-spacing: var(--tr-label); text-transform: uppercase; color: var(--gold-dim); }
.foot-updates p { margin-top: 8px; max-width: 300px; font: 400 13px/1.55 var(--font-body); color: var(--t2); }
.foot-updates-row { margin-top: 12px; display: flex; gap: 8px; flex-wrap: wrap; }
.foot-updates-row input { flex: 1 1 180px; min-height: 44px; padding: 0 12px; border-radius: var(--r-md); border: 1px solid var(--rule-strong);
  background: var(--surface); color: var(--t1); font: 400 14px/1 var(--font-body); }
.foot-updates-row input:focus-visible { outline: 1px solid var(--gold-ink); outline-offset: 2px; }
.foot-updates-row .btn { padding: 13px 20px 14px; }
.foot-updates-status { min-height: 1.5em; }

/* a place's reel (seo/videos.json): vertical, at the width a phone shows it */
.seo-reel video { display: block; margin-top: 18px; width: min(360px, 100%); height: auto; aspect-ratio: 9 / 16; border-radius: var(--r-card); border: 1px solid var(--rule-strong); background: #0a0f1a; }
