.demo-ref {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 14px 0 16px;
  margin-bottom: 4px;
  border-bottom: 1px solid var(--line);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  font-size: 10px;
  font-weight: 600;
  color: var(--muted);
}

.demo-ref strong {
  font-family: var(--serif);
  font-size: 1.25rem;
  letter-spacing: -0.01em;
  text-transform: none;
  font-weight: 600;
  color: var(--navy);
  line-height: 1.2;
}

.demo-ref.demo-ref-clean {
  border-bottom: none;
  margin-bottom: 0;
  padding-bottom: 10px;
}

.demo-map-mount {
  margin: 0 0 24px;
}

.demo-map-mount-top {
  margin-top: 0;
}

.demo-map-rail {
  padding: 0 0 4px;
  border-bottom: 1px solid var(--line);
  margin-bottom: 4px;
}

.demo-map-label {
  margin: 0 0 10px;
  font-size: 10px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  font-weight: 700;
  color: var(--muted);
}

.demo-map-mount[hidden],
#demo-linear-mount[hidden] {
  display: none;
}

.demo-map {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
}

.demo-pill {
  display: grid;
  grid-template-columns: 44px 1fr;
  gap: 12px;
  align-items: center;
  padding: 14px 16px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  text-decoration: none;
  color: var(--ink);
  min-height: 68px;
  transition: border-color 0.15s ease, box-shadow 0.15s ease, transform 0.15s ease;
  box-shadow: var(--shadow-sm);
}

.demo-pill:hover {
  border-color: var(--gold);
  box-shadow: var(--shadow);
  transform: translateY(-1px);
}

.demo-pill.active {
  border-color: var(--gold);
  box-shadow: var(--shadow);
  background: linear-gradient(180deg, #fffdf7 0%, var(--surface-muted) 100%);
}

.demo-pill.demo-pill-next {
  border-color: var(--gold);
  background: linear-gradient(180deg, #fff 0%, var(--surface-muted) 100%);
}

.demo-pill.demo-pill-done {
  border-color: var(--line);
  background: var(--surface);
}

.demo-pill .num {
  width: 44px;
  height: 44px;
  border-radius: 14px;
  background: #eef1f5;
  color: var(--navy-mid);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 15px;
  font-weight: 700;
  font-family: var(--serif);
  transition: background 0.15s ease, color 0.15s ease, box-shadow 0.15s ease;
}

.demo-pill.active .num {
  background: linear-gradient(180deg, #e0c078 0%, var(--gold) 100%);
  color: var(--navy-deep);
  box-shadow: 0 0 0 2px var(--navy);
}

.demo-pill.demo-pill-next .num {
  background: var(--navy);
  color: #fff;
  box-shadow: 0 0 0 2px var(--gold);
}

.demo-pill.demo-pill-done .num {
  background: var(--navy-mid);
  color: #fff;
}

.demo-pill.demo-pill-next small {
  color: var(--navy);
  font-weight: 500;
}

.demo-pill.active small {
  color: var(--navy-mid);
  font-weight: 500;
}

.demo-pill b {
  display: block;
  font-size: 15px;
  font-weight: 600;
  line-height: 1.2;
  color: var(--navy);
}

.demo-pill small {
  display: block;
  font-size: 12px;
  color: var(--muted);
  font-weight: 400;
  line-height: 1.4;
  margin-top: 3px;
}

.demo-start-wrap { margin: 0 0 28px; text-align: center; }
.demo-start { display: inline-block; text-decoration: none; min-width: 220px; }

body.demo-hub .hub-cta {
  margin: 8px 0 36px;
}

body.demo-hub .hub-cta .demo-start {
  min-width: 280px;
  padding: 16px 32px;
  font-size: 13px;
  background: linear-gradient(180deg, #d4b56a 0%, var(--gold) 100%);
  color: var(--navy-deep);
  box-shadow: var(--shadow);
}

body.demo-hub .hub-cta .demo-start:hover {
  background: linear-gradient(180deg, #e0c078 0%, #d4b56a 100%);
}

@media (max-width: 820px) {
  body.demo-hub .hub-cta .demo-start {
    width: 100%;
    min-width: 0;
  }
}

.demo-catalog-link {
  margin: 0 0 28px;
  font-size: 14px;
  color: var(--muted);
  line-height: 1.5;
  padding: 12px 16px;
  background: var(--surface-muted);
  border-radius: var(--radius-sm);
  border: 1px solid var(--line);
}

.demo-catalog-link a {
  color: var(--navy);
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 2px;
}

.hub-hero { padding-bottom: 4px; }
.hub-hero .lede { max-width: none; }

.demo-guide {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
  padding: 24px 26px;
  margin: 0 0 24px;
}

.demo-guide h2 {
  font-family: var(--serif);
  font-size: 1.35rem;
  font-weight: 600;
  margin: 0 0 10px;
  color: var(--navy-deep);
  letter-spacing: -0.02em;
}

.demo-flow {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 10px;
}

.demo-flow li {
  display: grid;
  grid-template-columns: 36px 1fr;
  gap: 14px;
  align-items: start;
  padding: 14px 16px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface-muted);
  font-size: 14px;
  line-height: 1.5;
}

.demo-flow .flow-num {
  width: 36px;
  height: 36px;
  border-radius: 12px;
  background: var(--navy);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 13px;
  font-family: var(--serif);
}

.demo-flow b { color: var(--navy); font-weight: 600; }

.demo-here {
  margin: 0 0 18px;
  padding: 14px 16px;
  border-radius: var(--radius);
  background: rgba(10, 27, 51, 0.04);
  border: 1px solid var(--line);
  font-size: 14px;
  line-height: 1.5;
  color: var(--ink);
}

.demo-here a {
  color: var(--navy);
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 2px;
}

.demo-linear {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin: 28px 0 8px;
  padding: 20px 0 0;
  border-top: 1px solid var(--line);
}

.demo-linear-count {
  font-size: 11px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
  font-weight: 700;
}

.demo-nav-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 11px 18px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 600;
  text-decoration: none;
  background: var(--navy);
  color: #fff;
  transition: background 0.15s ease;
  box-shadow: var(--shadow-sm);
}

.demo-nav-btn:hover { background: var(--navy-mid); }

.demo-nav-btn.ghost {
  background: var(--surface);
  color: var(--navy);
  border: 1px solid var(--line-strong);
  box-shadow: none;
}

.demo-nav-btn.ghost:hover {
  border-color: var(--gold);
  background: var(--surface-muted);
}

.demo-nav-spacer {
  flex: 1;
  min-width: 80px;
}

@media (min-width: 640px) {
  .demo-map { grid-template-columns: repeat(3, 1fr); }
}

@media (max-width: 820px) {
  .demo-pill { min-height: 62px; padding: 12px 14px; }
  .demo-pill b { font-size: 14px; }
  .demo-pill .num { width: 40px; height: 40px; font-size: 14px; }
  .demo-linear { flex-direction: column; align-items: stretch; }
  .demo-linear-count { text-align: center; order: -1; }
  .demo-nav-btn { width: 100%; justify-content: center; }
}

/* Present mode for screen sharing */
body.present-mode {
  font-size: 17px;
}

body.present-mode .footnote,
body.present-mode .demo-catalog-link,
body.present-mode .demo-guide {
  display: none;
}

body.present-mode h1 {
  font-size: clamp(1.85rem, 1.5rem + 2vw, 2.6rem);
}

body.present-mode .demo-map-mount {
  margin-bottom: 16px;
}

body.present-mode .demo-pill small {
  display: none;
}

body.present-mode .demo-here {
  padding: 10px 12px;
  font-size: 13px;
}

body.present-mode .wrap {
  width: min(900px, calc(100% - 32px));
}

body.present-mode .wizard-card {
  padding: 28px 30px;
}

body.present-mode .choice {
  min-height: 56px;
  font-size: 16px;
}
