/* ============================================================
   BEACON — Landing page styles
   Depends on assets/css/tokens.css
   ============================================================ */

/* ----------------------------------------------------------------
   Global page rhythm
---------------------------------------------------------------- */
main { display: block; padding-top: var(--nav-h); }
section { padding-block: var(--space-12); position: relative; }
@media (max-width: 768px) {
  section { padding-block: var(--space-9); }
}

.section__head { max-width: 880px; margin-bottom: var(--space-9); }
.section__head .uppercase-label { margin-bottom: var(--space-3); display: inline-block; }
.section__h2 {
  font-size: clamp(1.875rem, 3.4vw, 2.75rem);
  letter-spacing: var(--tracking-tighter);
  font-weight: 500;
  line-height: 1.08;
  margin: 0;
  color: var(--fg);
  max-width: 22ch;
}
.section__h2.section__h2--wide { max-width: 32ch; }

/* ----------------------------------------------------------------
   1) Nav
---------------------------------------------------------------- */
.nav {
  position: fixed; inset: 0 0 auto 0;
  z-index: 50;
  height: var(--nav-h);
  display: flex; align-items: center;
  background: rgba(250, 250, 247, 0.78);
  backdrop-filter: saturate(140%) blur(14px);
  -webkit-backdrop-filter: saturate(140%) blur(14px);
  border-bottom: 1px solid transparent;
  transition: border-color var(--dur-base) var(--ease-soft),
              background var(--dur-base) var(--ease-soft);
}
.nav.is-scrolled {
  border-bottom-color: var(--border);
  background: rgba(250, 250, 247, 0.92);
}
.nav__inner {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: var(--space-7);
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  font-weight: 500;
  letter-spacing: -0.01em;
}
.brand__mark { color: var(--signal); }
.brand__word { font-size: 0.95rem; letter-spacing: 0.04em; }

.nav__meta {
  color: var(--fg-muted);
  font-size: var(--text-xs);
  letter-spacing: 0.04em;
  text-transform: uppercase;
  justify-self: center;
}

.nav__links {
  display: inline-flex;
  align-items: center;
  gap: var(--space-6);
}
.nav__links a {
  font-size: var(--text-sm);
  color: var(--fg-secondary);
  transition: color var(--dur-fast) var(--ease-soft);
}
.nav__links a:hover { color: var(--fg); }
.nav__links a.btn { color: var(--bg); }
.nav__cta { padding: 8px 14px; }

@media (max-width: 980px) {
  .nav__meta { display: none; }
  .nav__inner { grid-template-columns: auto 1fr; gap: var(--space-4); }
  .nav__links { gap: var(--space-4); }
  .nav__links a:not(.btn) { display: none; }
  .nav__links a.btn { display: inline-flex; }
}

/* ----------------------------------------------------------------
   2) Hero
---------------------------------------------------------------- */
.hero { padding-top: calc(var(--space-12) + var(--space-3)); padding-bottom: var(--space-12); overflow: clip; }
.hero__grid {
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(0, 1fr);
  gap: var(--space-10);
  align-items: start;
}
@media (max-width: 1024px) {
  .hero__grid { grid-template-columns: 1fr; gap: var(--space-9); }
}

.hero__eyebrow {
  margin-bottom: var(--space-5);
  letter-spacing: 0.14em;
}
.hero__h1 {
  font-size: clamp(2.25rem, 5vw, 4.25rem);
  line-height: 1.05;
  font-weight: 500;
  letter-spacing: -0.035em;
  margin: 0 0 var(--space-5);
  max-width: 18ch;
}
.hero__sub {
  font-size: var(--text-md);
  color: var(--fg-secondary);
  max-width: 56ch;
  line-height: 1.55;
  margin: 0 0 var(--space-7);
}
.hero__ctas {
  display: inline-flex;
  flex-wrap: wrap;
  gap: var(--space-3);
  align-items: center;
}
.hero__ctas .btn { padding: 12px 18px; font-size: var(--text-sm); }
.hero__walkthrough {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  margin-top: var(--space-5);
  color: var(--fg-secondary);
  font-size: var(--text-sm);
}
.hero__walkthrough:hover { color: var(--fg); }
.hero__walkthrough-dur {
  color: var(--fg-muted);
  font-size: 11px;
  padding: 2px 6px;
  background: var(--bg-subtle);
  border-radius: var(--radius-sm);
  margin-left: 2px;
}

/* Marquee */
.hero__marquee {
  margin-top: var(--space-9);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  overflow: hidden;
  padding-block: var(--space-3);
  -webkit-mask-image: linear-gradient(90deg, transparent 0, black 8%, black 92%, transparent 100%);
          mask-image: linear-gradient(90deg, transparent 0, black 8%, black 92%, transparent 100%);
}
.hero__marquee-inner {
  display: inline-flex;
  gap: var(--space-9);
  white-space: nowrap;
  animation: marquee 64s linear infinite;
  font-family: var(--font-mono);
  font-size: var(--text-xs);
  color: var(--fg-muted);
  letter-spacing: 0.06em;
}
.hero__marquee-inner .mq-item { display: inline-flex; align-items: center; gap: var(--space-2); }
.hero__marquee-inner .mq-item .dot { width: 5px; height: 5px; }
@keyframes marquee {
  0% { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}

/* Snapshot card */
.snap {
  position: relative;
  background: var(--bg-elev);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  padding: var(--space-6);
  box-shadow: var(--shadow-diffuse), var(--shadow-md);
  display: flex;
  flex-direction: column;
  gap: var(--space-5);
}
.snap::before {
  content: "";
  position: absolute;
  inset: -1px;
  border-radius: var(--radius-xl);
  pointer-events: none;
  background: linear-gradient(180deg, rgba(255,255,255,0.7), transparent 30%);
  mix-blend-mode: overlay;
}
.snap__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-4);
}
.snap__head-l {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
}
.snap__elapsed {
  font-size: var(--text-sm);
  color: var(--fg-secondary);
  padding: 4px 8px;
  background: var(--bg-subtle);
  border-radius: var(--radius-sm);
}
.snap__title { display: flex; flex-direction: column; gap: 4px; }
.snap__event-id {
  font-size: var(--text-xs);
  color: var(--fg-muted);
  letter-spacing: 0.05em;
}
.snap__title h3 {
  font-size: var(--text-lg);
  font-weight: 500;
  margin: 0;
  letter-spacing: -0.02em;
}
.snap__region {
  font-size: var(--text-xs);
  color: var(--fg-muted);
  letter-spacing: 0.02em;
}

.snap__stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-2);
  padding: var(--space-4) 0;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}
.snap__stat {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding-right: var(--space-2);
}
.snap__stat + .snap__stat { border-left: 1px solid var(--border); padding-left: var(--space-4); }
.snap__stat-num {
  font-size: 1.65rem;
  font-weight: 500;
  letter-spacing: -0.03em;
  color: var(--fg);
  line-height: 1.05;
  transition: transform var(--dur-base) var(--ease-soft);
}
.snap__stat-num.is-flicker { transform: translateY(-2px); }
.snap__stat-cap {
  font-size: 11px;
  color: var(--fg-muted);
  letter-spacing: 0.02em;
}

.snap__spark {
  position: relative;
  height: 64px;
}
.snap__spark svg { display: block; width: 100%; height: 60px; }
.snap__spark-labels {
  display: flex;
  justify-content: space-between;
  font-size: 10px;
  color: var(--fg-faint);
  margin-top: 2px;
  letter-spacing: 0.05em;
}

.snap__feed { display: flex; flex-direction: column; gap: var(--space-3); }
.snap__feed-head {
  display: flex; justify-content: space-between; align-items: center;
}
.snap__feed-count { font-size: 11px; color: var(--fg-muted); }
.snap__list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 1px;
  background: var(--border);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  overflow: hidden;
}
.snap__list-item {
  display: grid;
  grid-template-columns: 28px 1fr auto;
  gap: var(--space-3);
  align-items: center;
  padding: 10px var(--space-3);
  background: var(--bg-elev);
  transition: background var(--dur-base) var(--ease-soft);
}
.snap__list-item.is-fresh { background: var(--signal-soft); }
.snap__list-item .grade { width: 24px; height: 24px; font-size: 11px; }
.snap__li-text { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.snap__li-id { font-family: var(--font-mono); font-size: 11px; color: var(--fg-muted); letter-spacing: 0.02em; }
.snap__li-name {
  font-size: var(--text-sm);
  color: var(--fg);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.snap__li-cred {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 4px;
}
.snap__li-cred-num { font-family: var(--font-mono); font-size: 11px; color: var(--fg-secondary); }
.snap__li-cred-bar { width: 60px; height: 4px; background: var(--bg-subtle); border-radius: 999px; overflow: hidden; }
.snap__li-cred-bar > span { display: block; height: 100%; background: var(--verified); border-radius: inherit; transition: width var(--dur-base) var(--ease-soft); }
.snap__li-cred-bar > span.is-warn { background: var(--warn); }
.snap__li-cred-bar > span.is-low { background: var(--signal); }

.snap__foot {
  display: flex; align-items: center; justify-content: space-between;
  font-size: 11px;
  color: var(--fg-muted);
  letter-spacing: 0.04em;
  text-transform: uppercase;
}
.snap__foot .dot { margin-right: 6px; }

/* ----------------------------------------------------------------
   3) Problem strip
---------------------------------------------------------------- */
.problem {
  padding-block: var(--space-9);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  background: var(--bg);
}
.problem__row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0;
}
.problem__cell {
  padding: var(--space-2) var(--space-7) var(--space-2) 0;
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
}
.problem__cell + .problem__cell {
  border-left: 1px solid var(--border);
  padding-left: var(--space-7);
}
.problem__num {
  font-size: clamp(1.875rem, 3.6vw, 2.5rem);
  font-weight: 500;
  letter-spacing: -0.04em;
  color: var(--fg);
  line-height: 1;
}
.problem__num em {
  font-style: normal;
  color: var(--signal);
}
.problem__cap {
  font-size: var(--text-sm);
  color: var(--fg-muted);
  max-width: 32ch;
}
@media (max-width: 880px) {
  .problem__row { grid-template-columns: 1fr; gap: var(--space-7); }
  .problem__cell + .problem__cell { border-left: 0; padding-left: 0; border-top: 1px solid var(--border); padding-top: var(--space-7); }
}

/* ----------------------------------------------------------------
   4) Pipeline
---------------------------------------------------------------- */
.how { padding-bottom: var(--space-12); }
.pipeline {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 0;
  position: relative;
  border-top: 1px dashed var(--border-strong);
  padding-top: var(--space-7);
}
.pipe-node {
  position: relative;
  padding: 0 var(--space-5) 0 0;
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
}
.pipe-node + .pipe-node {
  padding-left: var(--space-5);
  border-left: 1px solid var(--border);
}
.pipe-node::before {
  content: "";
  position: absolute;
  top: calc(-1 * var(--space-7) - 5px);
  left: 0;
  width: 9px; height: 9px;
  background: var(--bg);
  border: 1px solid var(--border-strong);
  border-radius: 50%;
}
.pipe-num {
  font-size: 11px;
  color: var(--fg-muted);
  letter-spacing: 0.1em;
}
.pipe-name {
  font-size: var(--text-md);
  font-weight: 500;
  margin: 0;
  letter-spacing: -0.02em;
}
.pipe-cap {
  font-size: var(--text-sm);
  color: var(--fg-secondary);
  margin: 0;
  line-height: 1.45;
}
.pipe-detail {
  margin-top: var(--space-2);
  padding: var(--space-3);
  background: var(--bg-subtle);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  font-size: var(--text-sm);
  color: var(--fg-secondary);
  opacity: 0;
  transform: translateY(4px);
  transition: opacity var(--dur-base) var(--ease-soft),
              transform var(--dur-base) var(--ease-soft);
  pointer-events: none;
}
.pipe-detail p { margin: 4px 0 0 0; font-size: 12px; }
.pipe-node:hover .pipe-detail,
.pipe-node:focus-within .pipe-detail {
  opacity: 1;
  transform: translateY(0);
}
.pipe-node:hover .pipe-num { color: var(--signal); }

@media (max-width: 980px) {
  .pipeline {
    grid-template-columns: 1fr;
    border-top: 0;
    padding-top: 0;
  }
  .pipe-node {
    padding: var(--space-6) 0;
    border-bottom: 1px solid var(--border);
  }
  .pipe-node + .pipe-node { padding-left: 0; border-left: 0; }
  .pipe-node::before { display: none; }
  .pipe-detail { opacity: 1; transform: none; pointer-events: auto; }
}

/* ----------------------------------------------------------------
   5) Demos showcase
---------------------------------------------------------------- */
.demos { background: linear-gradient(180deg, var(--bg) 0, var(--bg-subtle) 100%); padding-bottom: var(--space-12); }
.demos__grid {
  display: grid;
  grid-template-columns: 1.25fr 1fr;
  grid-template-rows: 1fr 1fr;
  gap: var(--space-5);
  min-height: 720px;
}
.demos__grid .demo-card--tall { grid-row: 1 / span 2; }

@media (max-width: 960px) {
  .demos__grid {
    grid-template-columns: 1fr;
    grid-template-rows: auto auto auto;
    min-height: 0;
  }
  .demos__grid .demo-card--tall { grid-row: auto; }
}

.demo-card {
  position: relative;
  display: flex;
  flex-direction: column;
  background: var(--bg-elev);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  overflow: hidden;
  cursor: pointer;
  transition: transform var(--dur-base) var(--ease-soft),
              box-shadow var(--dur-base) var(--ease-soft),
              border-color var(--dur-base) var(--ease-soft);
}
.demo-card::before {
  content: "";
  position: absolute;
  top: 14px; bottom: 14px; left: 0;
  width: 3px;
  background: var(--signal);
  border-radius: 0 3px 3px 0;
  opacity: 0;
  transform: translateX(-3px);
  transition: opacity var(--dur-base) var(--ease-soft),
              transform var(--dur-base) var(--ease-soft);
}
.demo-card:hover {
  transform: translateY(-1px);
  box-shadow: var(--shadow-xl);
  border-color: var(--border-strong);
}
.demo-card:hover::before {
  opacity: 1;
  transform: translateX(0);
}

.demo-card__preview {
  position: relative;
  flex: 1 1 auto;
  min-height: 280px;
  background: var(--bg-deep);
  overflow: hidden;
}
.demo-card__bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  filter: saturate(110%);
}
.demo-card__corner {
  position: absolute;
  bottom: var(--space-3);
  right: var(--space-3);
  font-size: 10px;
  letter-spacing: 0.08em;
  color: var(--fg-on-dark-muted);
  background: rgba(14, 14, 16, 0.7);
  padding: 4px 8px;
  border-radius: var(--radius-sm);
  backdrop-filter: blur(8px);
  z-index: 2;
}

.demo-card__body {
  padding: var(--space-6);
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
  border-top: 1px solid var(--border);
  background: var(--bg-elev);
}
.demo-card__top { display: flex; flex-direction: column; gap: 4px; }
.demo-card__title {
  font-size: var(--text-lg);
  font-weight: 500;
  letter-spacing: -0.02em;
  color: var(--fg);
}
.demo-card__desc {
  font-size: var(--text-sm);
  color: var(--fg-secondary);
  margin: 0;
  line-height: 1.5;
  max-width: 48ch;
}
.demo-card__cta {
  margin-top: var(--space-3);
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  color: var(--fg);
  font-size: var(--text-sm);
  font-weight: 500;
}
.demo-card__cta svg { transition: transform var(--dur-fast) var(--ease-soft); }
.demo-card:hover .demo-card__cta svg { transform: translate(2px, -2px); }

/* Demo mock previews */
.demo-mock {
  position: absolute;
  inset: var(--space-6);
  background: var(--bg-elev);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: 0 30px 60px -25px rgba(14,14,16,0.45);
  overflow: hidden;
  z-index: 1;
  display: flex;
  flex-direction: column;
}
.demo-mock--user { inset: auto 24px 24px 24px; height: 64%; }
.demo-mock__bar {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  padding: 8px var(--space-3);
  background: var(--bg-subtle);
  border-bottom: 1px solid var(--border);
  font-size: 11px;
  color: var(--fg-muted);
  letter-spacing: 0.02em;
}
.demo-mock__bar-right { margin-left: auto; color: var(--fg-faint); font-size: 10px; }

.demo-mock__wiz { display: flex; flex-direction: column; padding: var(--space-3); gap: var(--space-3); flex: 1; }
.demo-mock__step {
  font-size: 11px;
  color: var(--fg-muted);
  letter-spacing: 0.02em;
}
.demo-mock__map {
  flex: 1;
  min-height: 90px;
  border-radius: var(--radius-md);
  overflow: hidden;
  background: var(--bg-deep);
}
.demo-mock__ctas { display: flex; gap: var(--space-2); justify-content: space-between; align-items: center; }
.demo-mock__chip {
  padding: 6px 10px;
  border-radius: var(--radius-pill);
  background: var(--bg-subtle);
  border: 1px solid var(--border);
  font-size: 11px;
  color: var(--fg-secondary);
}
.demo-mock__chip--signal {
  background: var(--signal);
  color: white;
  border-color: var(--signal);
}

.demo-mock--qa {
  inset: var(--space-6);
  background: var(--bg-elev);
  display: flex;
  flex-direction: column;
}
.demo-mock__cred {
  flex: 1;
  padding: var(--space-4);
  display: flex;
  flex-direction: column;
  gap: 8px;
  font-size: 11px;
}

/* Credibility rows (used in demo mocks + tile) */
.cred-row {
  display: grid;
  grid-template-columns: minmax(110px, 1.4fr) 1fr 28px;
  align-items: center;
  gap: var(--space-3);
  font-size: 11px;
  color: var(--fg-secondary);
}
.cred-bar {
  height: 4px;
  border-radius: 999px;
  background: var(--bg-subtle);
  overflow: hidden;
  display: block;
}
.cred-bar > span {
  display: block;
  height: 100%;
  background: var(--verified);
  border-radius: inherit;
}
.cred-check {
  font-family: var(--font-mono);
  font-size: 10px;
  padding: 1px 6px;
  border-radius: 999px;
  letter-spacing: 0.05em;
}
.cred-check.ok { background: var(--verified-soft); color: var(--verified-deep); }
.cred-check.warn { background: var(--warn-soft); color: var(--warn); }

/* Phone frame */
.demo-card--mobile .demo-card__preview {
  display: flex;
  align-items: center;
  justify-content: center;
  background:
    radial-gradient(ellipse 60% 60% at 50% 50%, #1a1a1d 0%, #0E0E10 100%);
  padding: var(--space-7) 0;
  min-height: 280px;
}
.phone-frame {
  position: relative;
  width: 168px;
  height: 320px;
  background: #1a1a1d;
  border: 1px solid #3F3F46;
  border-radius: 22px;
  padding: 6px;
  box-shadow: 0 20px 50px -10px rgba(0,0,0,0.6), inset 0 1px 0 rgba(255,255,255,0.08);
}
.phone-frame__notch {
  position: absolute;
  top: 6px; left: 50%;
  transform: translateX(-50%);
  width: 40px; height: 10px;
  background: #0E0E10;
  border-radius: 0 0 8px 8px;
  z-index: 2;
}
.phone-frame__screen {
  background: var(--bg-elev);
  border-radius: 16px;
  height: 100%;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}
.phone-bar {
  display: flex; justify-content: space-between;
  padding: 4px 10px 4px 10px;
  font-size: 10px;
  color: var(--fg-secondary);
  border-bottom: 1px solid var(--border);
  align-items: center;
}
.phone-bar__right { display: inline-flex; align-items: center; gap: 4px; }
.phone-content {
  padding: var(--space-3);
  display: flex; flex-direction: column;
  gap: var(--space-3);
  flex: 1;
}
.phone-greet { font-size: 9px; }
.phone-title { font-size: 14px; font-weight: 500; letter-spacing: -0.02em; }
.phone-shutter {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  padding: var(--space-4) 0;
  background: var(--signal);
  color: white;
  border-radius: var(--radius-md);
  font-size: 11px;
  letter-spacing: 0.02em;
}
.phone-queue {
  margin-top: auto;
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.phone-queue__row {
  display: flex; align-items: center; gap: 6px;
  font-size: 10px;
  padding: 6px;
  background: var(--bg-subtle);
  border-radius: var(--radius-sm);
  color: var(--fg-secondary);
}
.phone-queue__pill {
  margin-left: auto;
  padding: 1px 5px;
  font-size: 9px;
  background: var(--warn-soft);
  color: var(--warn);
  border-radius: 999px;
  letter-spacing: 0.05em;
}

/* ----------------------------------------------------------------
   6) Bento
---------------------------------------------------------------- */
.features { padding-top: var(--space-12); }
.bento {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  grid-auto-rows: minmax(220px, auto);
  gap: var(--space-5);
}
.tile {
  background: var(--bg-elev);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  padding: var(--space-7);
  display: flex;
  flex-direction: column;
  gap: var(--space-5);
  transition: border-color var(--dur-base) var(--ease-soft),
              transform var(--dur-base) var(--ease-soft);
}
.tile:hover { border-color: var(--border-strong); transform: translateY(-1px); }
.tile--span-2 { grid-column: span 2; }
@media (max-width: 980px) {
  .bento { grid-template-columns: 1fr 1fr; }
  .tile--span-2 { grid-column: span 2; }
}
@media (max-width: 640px) {
  .bento { grid-template-columns: 1fr; }
  .tile--span-2 { grid-column: span 1; }
}
.tile__head { display: flex; flex-direction: column; gap: 6px; }
.tile__h {
  font-size: var(--text-lg);
  font-weight: 500;
  letter-spacing: -0.02em;
  margin: 0;
  color: var(--fg);
}
.tile__desc {
  font-size: var(--text-sm);
  color: var(--fg-secondary);
  line-height: 1.55;
  margin: 0;
  max-width: 52ch;
}
.tile__viz {
  margin-top: auto;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  background: var(--bg-subtle);
  padding: var(--space-4);
}
.tile__viz--cred { display: flex; flex-direction: column; gap: 10px; }
.tile__viz--cred .cred-row {
  grid-template-columns: minmax(140px, 1.6fr) auto 1fr 32px;
}
.tile__viz--blur { padding: 0; overflow: hidden; aspect-ratio: 200/130; }
.tile__viz--blur svg { display: block; }

.tile__viz--queue { display: flex; flex-direction: column; gap: 6px; }
.queue-row {
  display: grid;
  grid-template-columns: 16px auto 1fr auto;
  align-items: center;
  gap: var(--space-3);
  padding: 10px var(--space-3);
  background: var(--bg-elev);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  font-size: 11px;
  color: var(--fg-secondary);
}
.queue-row__id { color: var(--fg); }
.queue-row__meta { color: var(--fg-muted); font-size: 10px; }
.queue-row__pill {
  padding: 2px 8px;
  font-size: 10px;
  background: var(--warn-soft);
  color: var(--warn);
  border-radius: 999px;
  letter-spacing: 0.06em;
}
.queue-row--note {
  display: flex; justify-content: space-between;
  background: transparent;
  border: 0;
  padding: 6px 4px 0;
  color: var(--fg-muted);
  font-size: 10px;
}
.queue-row__since { color: var(--fg-faint); }

.tile__viz--langs {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  background: var(--bg-subtle);
}
.lang-chip {
  font-size: 11px;
  padding: 5px 10px;
  background: var(--bg-elev);
  border: 1px solid var(--border);
  border-radius: 999px;
  color: var(--fg-secondary);
  letter-spacing: 0.02em;
}
.lang-chip--accent {
  border-color: var(--signal);
  color: var(--signal-deep);
  background: var(--signal-soft);
}

.tile__viz--landmark {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: var(--space-2);
}
.landmark-input, .landmark-result {
  display: flex; flex-direction: column; gap: 4px;
  padding: var(--space-3);
  background: var(--bg-elev);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  font-size: 11px;
}
.landmark-input__label, .landmark-result__pin {
  font-size: 10px;
  color: var(--fg-muted);
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
.landmark-input__value { color: var(--fg); font-style: italic; }
.landmark-arrow {
  align-self: center;
  color: var(--fg-faint);
}
.landmark-result {
  flex-direction: row;
  align-items: center;
  gap: var(--space-3);
}
.landmark-result__pin {
  display: inline-flex; align-items: center; justify-content: center;
  width: 22px; height: 22px;
  background: var(--signal-soft);
  color: var(--signal-deep);
  border-radius: var(--radius-sm);
}
.landmark-result__ok {
  margin-left: auto;
  padding: 1px 7px;
  background: var(--verified-soft);
  color: var(--verified-deep);
  border-radius: 999px;
  font-size: 10px;
  letter-spacing: 0.05em;
}

.tile__viz--escalate { display: flex; flex-direction: column; gap: var(--space-3); }
.esc-row {
  display: flex; align-items: center; justify-content: space-between;
}
.esc-msg {
  font-size: 12px;
  font-style: italic;
  color: var(--fg-secondary);
  padding: var(--space-3);
  background: var(--bg-elev);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  line-height: 1.5;
}
.esc-actions { display: flex; gap: var(--space-2); }
.esc-btn {
  padding: 6px 12px;
  font-size: 11px;
  background: var(--fg);
  color: var(--bg);
  border-radius: 999px;
}
.esc-btn--ghost {
  background: transparent;
  color: var(--fg-secondary);
  border: 1px solid var(--border);
}

/* ----------------------------------------------------------------
   7) Architecture
---------------------------------------------------------------- */
.arch__wrap {
  display: grid;
  grid-template-columns: minmax(0, 1.6fr) minmax(280px, 1fr);
  gap: var(--space-7);
  align-items: start;
}
@media (max-width: 1024px) {
  .arch__wrap { grid-template-columns: 1fr; }
}
.arch__diagram {
  background: var(--bg-elev);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  padding: var(--space-7);
  display: flex;
  flex-direction: column;
  gap: 0;
}
.arch-layer {
  display: grid;
  grid-template-columns: 88px 1fr;
  align-items: center;
  gap: var(--space-5);
  padding: var(--space-4) 0;
}
.arch-layer__label {
  letter-spacing: 0.12em;
  color: var(--fg-muted);
}
.arch-layer__cells {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-3);
}
.arch-cell {
  padding: var(--space-3) var(--space-4);
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-height: 64px;
  justify-content: center;
}
.arch-cell__name { font-size: var(--text-sm); font-weight: 500; color: var(--fg); letter-spacing: -0.01em; }
.arch-cell__sub { font-size: 10px; color: var(--fg-muted); letter-spacing: 0.04em; }
.arch-cell--wide { grid-column: span 1; }
.arch-cell--planned { opacity: 0.7; border-style: dashed; }
.arch-cell__tag {
  display: inline-block;
  padding: 1px 5px;
  margin-left: 6px;
  font-size: 9px;
  background: var(--bg-subtle);
  color: var(--fg-muted);
  border-radius: 999px;
  letter-spacing: 0.08em;
}
.arch-cell--out { background: var(--signal-soft); border-color: rgba(233, 75, 27, 0.25); }
.arch-cell--out .arch-cell__name { color: var(--signal-deep); }
.arch-cell--out .arch-cell__sub { color: var(--signal-deep); opacity: 0.7; }

.arch__connector { padding: 0; line-height: 0; }

/* Backend layer: 2 wide cells */
.arch-layer--backend .arch-layer__cells { grid-template-columns: 1fr 1fr; }

/* Outbound layer: 4 cells */
.arch-layer--outbound .arch-layer__cells { grid-template-columns: repeat(4, 1fr); }

@media (max-width: 720px) {
  .arch-layer { grid-template-columns: 1fr; gap: var(--space-2); }
  .arch-layer__cells { grid-template-columns: 1fr !important; }
}

.arch__oss {
  background: var(--bg-elev);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  padding: var(--space-6);
  display: flex; flex-direction: column; gap: var(--space-3);
  position: sticky;
  top: calc(var(--nav-h) + var(--space-5));
}
.arch__oss-head { display: flex; justify-content: space-between; align-items: center; }
.arch__oss-count { font-size: 11px; color: var(--fg-muted); }
.oss-list { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 0; }
.oss-item {
  display: grid;
  grid-template-columns: 1fr auto;
  grid-template-rows: auto auto;
  gap: 2px var(--space-2);
  padding: 10px 0;
  border-top: 1px solid var(--border);
  font-size: var(--text-sm);
}
.oss-item:first-child { border-top: 0; }
.oss-item__name { font-weight: 500; color: var(--fg); }
.oss-item__lic {
  font-size: 10px;
  letter-spacing: 0.06em;
  color: var(--fg-secondary);
  padding: 2px 6px;
  background: var(--bg-subtle);
  border-radius: var(--radius-xs);
  justify-self: end;
}
.oss-item__url {
  grid-column: 1 / span 2;
  font-size: 11px;
  color: var(--fg-muted);
}
.oss-item__url:hover { color: var(--fg); }

/* ----------------------------------------------------------------
   8) Comparison table
---------------------------------------------------------------- */
.cmp__wrap { overflow-x: auto; border: 1px solid var(--border); border-radius: var(--radius-xl); background: var(--bg-elev); }
.cmp {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  font-size: var(--text-sm);
  min-width: 720px;
}
.cmp th, .cmp td {
  padding: 14px var(--space-4);
  text-align: left;
  vertical-align: middle;
  border-bottom: 1px solid var(--border);
}
.cmp thead th {
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--fg-muted);
  font-weight: 500;
  background: var(--bg-subtle);
  border-bottom-color: var(--border-strong);
}
.cmp thead th.cmp__beacon { color: var(--signal-deep); }
.cmp tbody th { font-weight: 500; color: var(--fg); }
.cmp tbody tr:nth-child(odd) td:not(.cmp__beacon),
.cmp tbody tr:nth-child(odd) th { background: rgba(244, 244, 240, 0.5); }
.cmp tbody tr.is-visible td { animation: cmpFadeIn 0.5s var(--ease-soft) both; }
.cmp tbody tr:last-child th, .cmp tbody tr:last-child td { border-bottom: 0; }
.cmp__beacon { background: var(--signal-soft); }

@keyframes cmpFadeIn {
  from { opacity: 0; transform: translateY(6px); }
  to { opacity: 1; transform: none; }
}

.cmp-yes, .cmp-no, .cmp-partial {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.04em;
  padding: 3px 8px;
  border-radius: 999px;
}
.cmp-yes {
  background: var(--verified-soft);
  color: var(--verified-deep);
}
.cmp-yes::before { content: "✓"; font-weight: 600; }
.cmp-no {
  background: var(--bg-subtle);
  color: var(--fg-muted);
}
.cmp-no::before { content: "×"; font-weight: 600; font-size: 14px; line-height: 1; }
.cmp-partial {
  background: var(--warn-soft);
  color: var(--warn);
}
.cmp-partial::before { content: "—"; font-weight: 600; }

.cmp tbody tr {
  opacity: 0;
  transform: translateY(8px);
  transition: opacity 0.55s var(--ease-soft), transform 0.55s var(--ease-soft);
}
.cmp tbody tr.is-visible {
  opacity: 1;
  transform: none;
}
@media (prefers-reduced-motion: reduce) {
  .cmp tbody tr { opacity: 1; transform: none; }
}

/* ----------------------------------------------------------------
   9) Timeline
---------------------------------------------------------------- */
.timeline { padding-bottom: var(--space-12); }
.tl {
  list-style: none; padding: 0; margin: 0;
  display: flex; flex-direction: column;
  gap: 0;
}
.tl__row {
  display: grid;
  grid-template-columns: 96px 24px 1fr;
  gap: var(--space-5);
  padding: var(--space-5) 0;
  border-top: 1px solid var(--border);
  position: relative;
  align-items: start;
}
.tl__row:first-child { border-top: 0; }
.tl__row:last-child::after { display: none; }
.tl__t {
  font-size: var(--text-sm);
  font-weight: 500;
  color: var(--fg);
  letter-spacing: -0.01em;
  padding-top: 2px;
}
.tl__dot {
  width: 14px; height: 14px;
  margin-left: 5px;
  margin-top: 6px;
  background: var(--bg-elev);
  border: 2px solid var(--fg);
  border-radius: 50%;
  position: relative;
  z-index: 1;
}
.tl__row:not(:last-child) .tl__dot::after {
  content: "";
  position: absolute;
  top: 16px;
  left: 50%;
  transform: translateX(-50%);
  width: 1px;
  height: calc(100% + var(--space-5) * 2 - 14px);
  background: var(--border);
}
.tl__dot--end { background: var(--signal); border-color: var(--signal); }
.tl__body { padding-top: 0; }
.tl__name {
  font-size: var(--text-md);
  font-weight: 500;
  letter-spacing: -0.02em;
  margin: 0 0 var(--space-2);
}
.tl__body p {
  font-size: var(--text-sm);
  color: var(--fg-secondary);
  margin: 0;
  max-width: 72ch;
  line-height: 1.55;
}
@media (max-width: 640px) {
  .tl__row { grid-template-columns: 72px 18px 1fr; gap: var(--space-3); }
}

/* ----------------------------------------------------------------
   10) For UNDP
---------------------------------------------------------------- */
.undp { padding-bottom: var(--space-12); }
.undp__panel {
  background: var(--bg-deep);
  color: var(--fg-on-dark);
  border-radius: var(--radius-2xl);
  padding: var(--space-10) var(--space-9);
  display: grid;
  grid-template-columns: 1fr 1.4fr;
  gap: var(--space-9);
  position: relative;
  overflow: hidden;
}
.undp__panel::before {
  content: "";
  position: absolute;
  top: -40%; right: -10%;
  width: 70%; height: 140%;
  background: radial-gradient(ellipse at center, rgba(233,75,27,0.18) 0%, transparent 60%);
  pointer-events: none;
}
.undp__head { position: relative; z-index: 1; }
.undp__head .uppercase-label { color: var(--fg-on-dark-muted); }
.undp__h {
  font-size: clamp(1.75rem, 2.5vw, 2.25rem);
  letter-spacing: -0.03em;
  font-weight: 500;
  margin: var(--space-2) 0 var(--space-4);
  color: var(--fg-on-dark);
}
.undp__sub {
  font-size: var(--text-md);
  color: var(--fg-on-dark-muted);
  max-width: 42ch;
  margin: 0;
  line-height: 1.55;
}

.undp__steps {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 0;
  position: relative;
  z-index: 1;
}
.undp__step {
  display: grid;
  grid-template-columns: 40px 1fr;
  gap: var(--space-4);
  padding: var(--space-5) 0;
  border-top: 1px solid rgba(255,255,255,0.08);
}
.undp__step:first-child { border-top: 0; }
.undp__step-num {
  width: 32px; height: 32px;
  border: 1px solid rgba(255,255,255,0.18);
  border-radius: 50%;
  display: inline-flex; align-items: center; justify-content: center;
  font-size: 13px;
  color: var(--fg-on-dark);
}
.undp__step-where {
  font-size: 11px;
  color: var(--signal);
  letter-spacing: 0.04em;
}
.undp__step-name {
  font-size: var(--text-md);
  font-weight: 500;
  letter-spacing: -0.02em;
  margin: 4px 0 6px;
  color: var(--fg-on-dark);
}
.undp__step-body p {
  font-size: var(--text-sm);
  color: var(--fg-on-dark-muted);
  margin: 0;
  line-height: 1.55;
}
.undp__step-body p strong { color: var(--fg-on-dark); font-weight: 500; }
.undp__inline-id {
  color: var(--signal);
  background: rgba(233,75,27,0.12);
  padding: 1px 6px;
  border-radius: var(--radius-xs);
  font-size: 12px;
}

.undp__ip {
  grid-column: 1 / -1;
  margin-top: var(--space-4);
  padding-top: var(--space-7);
  border-top: 1px solid rgba(255,255,255,0.08);
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-7);
  position: relative;
  z-index: 1;
}
.undp__ip-row { display: flex; flex-direction: column; gap: var(--space-2); }
.undp__ip-row .uppercase-label { color: var(--fg-on-dark-muted); }
.undp__ip-row p {
  font-size: var(--text-sm);
  color: var(--fg-on-dark-muted);
  margin: 0;
  line-height: 1.55;
}
.undp__ip-row p strong { color: var(--fg-on-dark); font-weight: 500; }
.undp__ip-row .mono { color: var(--fg-on-dark); background: rgba(255,255,255,0.06); padding: 1px 6px; border-radius: 4px; }

@media (max-width: 880px) {
  .undp__panel { grid-template-columns: 1fr; padding: var(--space-7) var(--space-6); }
  .undp__ip { grid-template-columns: 1fr; }
}

/* ----------------------------------------------------------------
   11) Footer
---------------------------------------------------------------- */
.footer {
  border-top: 1px solid var(--border);
  padding-block: var(--space-7);
  background: var(--bg);
}
.footer__inner {
  display: grid;
  grid-template-columns: 1.5fr 1fr;
  gap: var(--space-7);
  align-items: start;
}
.footer__brand {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  font-weight: 500;
  font-size: var(--text-md);
  color: var(--fg);
}
.footer__brand svg { color: var(--signal); }
.footer__tag {
  font-size: var(--text-sm);
  color: var(--fg-muted);
  margin: var(--space-3) 0 0;
  max-width: 48ch;
}
.footer__links {
  justify-self: end;
  display: inline-flex;
  gap: var(--space-5);
  align-self: center;
}
.footer__links a {
  font-size: var(--text-sm);
  color: var(--fg-secondary);
}
.footer__links a:hover { color: var(--fg); }
.footer__legal {
  grid-column: 1 / -1;
  font-size: 11px;
  color: var(--fg-faint);
  letter-spacing: 0.02em;
  border-top: 1px solid var(--border);
  padding-top: var(--space-5);
  max-width: 72ch;
}
@media (max-width: 720px) {
  .footer__inner { grid-template-columns: 1fr; }
  .footer__links { justify-self: start; }
}
