/* ============================================================
   Sertone Demo Pages — Complete Standalone Stylesheet
   Self-contained: includes all base + demo-specific styles.
   Colors: white #ffffff, dark slate #1e293b, teal #00b894
   ============================================================ */

/* ---------- Reset & Base ---------- */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
    Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;
  background: #f8fafc;
  color: #334155;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

a {
  color: #00b894;
  text-decoration: none;
  transition: color 0.2s;
}
a:hover { color: #00a381; }

img { max-width: 100%; display: block; }

/* ---------- Typography ---------- */
h1, h2, h3, h4 {
  color: #1e293b;
  font-weight: 700;
  line-height: 1.2;
}
h1 { font-size: 2.75rem; letter-spacing: -0.03em; }
h2 { font-size: 1.85rem; letter-spacing: -0.02em; }
h3 { font-size: 1.25rem; }
h4 { font-size: 1.05rem; }
p  { max-width: 52rem; }

/* ---------- Layout ---------- */
.container {
  width: 100%;
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

/* Demo pages use a narrower centered column */
.demo-container {
  width: 100%;
  max-width: 860px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

section { padding: 4rem 0; }

/* ---------- Navigation ---------- */
.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  background: rgba(255, 255, 255, 0.97);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid #e2e8f0;
}

.nav .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 3.75rem;
}

.nav-logo {
  font-size: 1.25rem;
  font-weight: 800;
  color: #1e293b;
  letter-spacing: -0.02em;
}
.nav-logo span { color: #00b894; }

.nav-links {
  display: flex;
  gap: 2rem;
  list-style: none;
}
.nav-links a {
  color: #64748b;
  font-size: 0.9rem;
  font-weight: 500;
  transition: color 0.2s;
}
.nav-links a:hover,
.nav-links a.active { color: #1e293b; }

.nav-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.25rem;
}
.nav-toggle span {
  display: block;
  width: 1.5rem;
  height: 2px;
  background: #475569;
  margin: 5px 0;
  transition: transform 0.3s, opacity 0.3s;
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-block;
  padding: 0.75rem 1.75rem;
  font-size: 0.95rem;
  font-weight: 600;
  color: #ffffff;
  background: #00b894;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  transition: transform 0.15s, box-shadow 0.15s, background 0.2s;
  text-decoration: none;
  white-space: nowrap;
}
.btn:hover {
  background: #00a381;
  color: #ffffff;
  transform: translateY(-1px);
  box-shadow: 0 4px 20px rgba(0, 184, 148, 0.3);
}
.btn:active { transform: translateY(0); }

.btn-secondary {
  background: transparent;
  color: #00b894;
  border: 1.5px solid rgba(0, 184, 148, 0.4);
}
.btn-secondary:hover {
  background: rgba(0, 184, 148, 0.06);
  color: #00a381;
  border-color: #00b894;
  box-shadow: none;
}

/* ---------- Section Labels ---------- */
.section-label {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: #00b894;
  margin-bottom: 0.6rem;
}

/* ---------- Footer ---------- */
.footer {
  background: #f1f5f9;
  border-top: 1px solid #e2e8f0;
  padding: 2rem 0;
  margin-top: 5rem;
}
.footer .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.footer-copy { color: #94a3b8; font-size: 0.8rem; }

/* ============================================================
   DEMO PAGE LAYOUT
   ============================================================ */

/* Breadcrumb */
.demo-breadcrumb {
  padding: 1rem 1.5rem;
  font-size: 0.82rem;
  color: #94a3b8;
  margin-top: 3.75rem; /* clear fixed nav */
}
.demo-breadcrumb a { color: #64748b; }
.demo-breadcrumb a:hover { color: #00b894; }
.demo-breadcrumb span { margin: 0 0.4rem; color: #cbd5e1; }

/* Hero section */
.demo-hero {
  padding: 3rem 0 2.5rem;
  background:
    radial-gradient(ellipse 80% 60% at 50% -10%, rgba(0, 184, 148, 0.07) 0%, transparent 70%),
    linear-gradient(180deg, #ffffff 0%, #f8fafc 100%);
  border-bottom: 1px solid #e2e8f0;
}

.demo-hero h1 {
  font-size: 2.25rem;
  margin-bottom: 0.75rem;
  color: #0f172a;
}

.demo-tagline {
  font-size: 1.05rem;
  color: #64748b;
  max-width: 44rem;
  line-height: 1.65;
  margin-top: 0.5rem;
}

/* Live / testnet banner */
.demo-testnet-banner {
  background: rgba(0, 184, 148, 0.06);
  border: 1px solid rgba(0, 184, 148, 0.2);
  border-radius: 10px;
  padding: 0.85rem 1.25rem;
  font-size: 0.88rem;
  color: #475569;
  margin: 1.5rem 0;
  line-height: 1.55;
}
.demo-testnet-banner strong { color: #00b894; }

/* ---------- Content sections ---------- */
.demo-business {
  margin: 2rem 0;
}
.demo-business h2 {
  font-size: 1.5rem;
  margin-bottom: 1.25rem;
  color: #0f172a;
}

.demo-interactive {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 16px;
  padding: 1.75rem;
  box-shadow: 0 1px 8px rgba(0, 0, 0, 0.05);
  margin: 2rem 0;
}
.demo-interactive h2 {
  font-size: 1.4rem;
  margin-bottom: 0.5rem;
}
.demo-interactive h3 {
  font-size: 1rem;
  color: #1e293b;
  margin: 1rem 0 0.4rem;
}

/* Self-host / how-to section */
.demo-selfhost {
  margin: 2rem 0;
}
.demo-selfhost h2 {
  font-size: 1.5rem;
  margin-bottom: 1.5rem;
  color: #0f172a;
}

.selfhost-steps {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.selfhost-step {
  display: flex;
  gap: 1.25rem;
  position: relative;
  padding-bottom: 2rem;
}
.selfhost-step:last-child { padding-bottom: 0; }
.selfhost-step:not(:last-child)::before {
  content: "";
  position: absolute;
  left: 1.375rem;
  top: 2.75rem;
  bottom: 0;
  width: 1px;
  background: rgba(0, 184, 148, 0.2);
}

.selfhost-step-num {
  flex-shrink: 0;
  width: 2.75rem;
  height: 2.75rem;
  border-radius: 50%;
  background: rgba(0, 184, 148, 0.08);
  color: #00b894;
  font-size: 1rem;
  font-weight: 700;
  border: 1.5px solid rgba(0, 184, 148, 0.25);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.selfhost-step h4 {
  font-size: 1rem;
  color: #1e293b;
  margin-bottom: 0.35rem;
  padding-top: 0.5rem;
}
.selfhost-step p {
  color: #64748b;
  font-size: 0.9rem;
  line-height: 1.65;
  margin-bottom: 0.5rem;
}

/* Callout box */
.callout {
  border-radius: 10px;
  padding: 1rem 1.25rem;
  margin: 1rem 0;
  font-size: 0.88rem;
  line-height: 1.6;
}
.callout-info {
  background: rgba(56, 189, 248, 0.06);
  border: 1px solid rgba(56, 189, 248, 0.25);
  color: #475569;
}
.callout-info strong { color: #0369a1; }
.callout-warn {
  background: rgba(245, 158, 11, 0.06);
  border: 1px solid rgba(245, 158, 11, 0.25);
  color: #475569;
}

/* ============================================================
   CODE BLOCKS
   ============================================================ */
.code-block {
  position: relative;
  background: #0f172a;
  border-radius: 10px;
  padding: 1rem 1.25rem;
  font-family: "SF Mono", SFMono-Regular, Consolas, "Liberation Mono", Menlo, monospace;
  font-size: 0.82rem;
  color: #e2e8f0;
  overflow-x: auto;
  line-height: 1.7;
  margin: 0.75rem 0;
}
.code-block code { font-family: inherit; font-size: inherit; color: #e2e8f0; }
.code-block .prompt { color: #00b894; user-select: none; }
.code-block .comment { color: #64748b; }

/* ============================================================
   DEMO HUB CARDS  (demos/index.html)
   ============================================================ */
.demo-hub-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.25rem;
  margin-top: 2rem;
}

.demo-card {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 14px;
  padding: 1.75rem 1.5rem;
  text-decoration: none;
  color: inherit;
  transition: border-color 0.2s, box-shadow 0.2s, transform 0.15s;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.04);
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}
.demo-card:hover {
  border-color: rgba(0, 184, 148, 0.45);
  box-shadow: 0 6px 24px rgba(0, 0, 0, 0.08), 0 0 0 3px rgba(0,184,148,0.06);
  transform: translateY(-2px);
  color: inherit;
}

.demo-card-icon {
  width: 2.75rem;
  height: 2.75rem;
  border-radius: 9px;
  background: rgba(0, 184, 148, 0.08);
  color: #00b894;
  display: flex;
  align-items: center;
  justify-content: center;
}

.demo-card h3 {
  font-size: 1.05rem;
  color: #1e293b;
  margin: 0;
}

.demo-card p {
  color: #64748b;
  font-size: 0.875rem;
  line-height: 1.6;
  margin: 0;
  max-width: none;
  flex: 1;
}

.demo-card-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  margin-top: auto;
  padding-top: 0.4rem;
}

.demo-tag {
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.03em;
  color: #00b894;
  background: rgba(0, 184, 148, 0.07);
  border: 1px solid rgba(0, 184, 148, 0.18);
  border-radius: 100px;
  padding: 0.15rem 0.55rem;
  font-family: "SF Mono", SFMono-Regular, Consolas, "Liberation Mono", Menlo, monospace;
}

/* ============================================================
   ARCHITECTURE DIAGRAM (shared pattern)
   ============================================================ */
.arch-diagram {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 14px;
  padding: 2rem 1.5rem;
  text-align: center;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.04);
  overflow-x: auto;
  margin: 1.5rem 0;
}

.arch-flow {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0;
  flex-wrap: wrap;
  min-width: 480px;
}

.arch-node {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  padding: 1rem 1.25rem;
  min-width: 130px;
  text-align: center;
}
.arch-node.accent {
  background: rgba(0, 184, 148, 0.05);
  border-color: rgba(0, 184, 148, 0.3);
}
.arch-node .node-label {
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: #00b894;
  margin-bottom: 0.25rem;
}
.arch-node .node-desc {
  font-size: 0.82rem;
  color: #64748b;
  line-height: 1.4;
  max-width: none;
}

.arch-arrow {
  color: #cbd5e1;
  font-size: 1.4rem;
  padding: 0 0.6rem;
  flex-shrink: 0;
  user-select: none;
}

/* ============================================================
   INTERACTIVE DEMO (macOS-style terminal + form)
   ============================================================ */
.demo-interactive-header {
  background: #f1f5f9;
  border-bottom: 1px solid #e2e8f0;
  padding: 0.75rem 1.25rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  border-radius: 12px 12px 0 0;
  margin: -1.75rem -1.75rem 1.25rem;
}
.demo-interactive-header .dot {
  width: 11px; height: 11px; border-radius: 50%;
}
.demo-interactive-header .dot.red   { background: #fc6058; }
.demo-interactive-header .dot.amber { background: #fec02f; }
.demo-interactive-header .dot.green { background: #2bc940; }
.demo-interactive-header .header-title {
  margin-left: 0.5rem;
  font-size: 0.82rem;
  color: #94a3b8;
  font-family: "SF Mono", SFMono-Regular, Consolas, "Liberation Mono", Menlo, monospace;
}

/* Form */
.demo-form-row {
  display: flex;
  gap: 0.75rem;
  align-items: flex-end;
  flex-wrap: wrap;
  margin-bottom: 1.25rem;
}

.demo-form-field {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
  flex: 1;
  min-width: 150px;
}
.demo-form-field label {
  font-size: 0.78rem;
  font-weight: 600;
  color: #475569;
  letter-spacing: 0.02em;
}
.demo-form-field input,
.demo-form-field select,
.demo-form-field textarea {
  padding: 0.6rem 0.85rem;
  font-size: 0.88rem;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  background: #f8fafc;
  color: #1e293b;
  outline: none;
  font-family: "SF Mono", SFMono-Regular, Consolas, "Liberation Mono", Menlo, monospace;
  transition: border-color 0.2s, box-shadow 0.2s;
}
.demo-form-field textarea {
  font-size: 0.8rem;
  resize: vertical;
  min-height: 90px;
}
.demo-form-field input:focus,
.demo-form-field select:focus,
.demo-form-field textarea:focus {
  border-color: #00b894;
  box-shadow: 0 0 0 3px rgba(0, 184, 148, 0.12);
  background: #ffffff;
}

/* Run button */
.btn-run {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.6rem 1.4rem;
  font-size: 0.9rem;
  font-weight: 600;
  color: #ffffff;
  background: #00b894;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  transition: background 0.2s, transform 0.15s, box-shadow 0.15s;
  white-space: nowrap;
  flex-shrink: 0;
}
.btn-run:hover {
  background: #00a381;
  transform: translateY(-1px);
  box-shadow: 0 4px 16px rgba(0, 184, 148, 0.3);
}
.btn-run:active { transform: translateY(0); }
.btn-run.loading { opacity: 0.65; pointer-events: none; }

/* ============================================================
   RESULT PANEL (dark terminal)
   ============================================================ */
.demo-result {
  background: #0f172a;
  border-radius: 10px;
  overflow: hidden;
  font-family: "SF Mono", SFMono-Regular, Consolas, "Liberation Mono", Menlo, monospace;
  font-size: 0.82rem;
  line-height: 1.7;
  color: #e2e8f0;
  min-height: 120px;
  margin-top: 1rem;
}

.demo-result-bar {
  background: #1e293b;
  padding: 0.5rem 1rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid #334155;
}
.demo-result-bar .result-status { font-size: 0.72rem; color: #64748b; }
.demo-result-bar .result-status.ok    { color: #4ade80; }
.demo-result-bar .result-status.error { color: #f87171; }

.latency-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  padding: 0.18rem 0.6rem;
  background: rgba(0, 184, 148, 0.15);
  color: #34d399;
  border-radius: 100px;
  font-size: 0.7rem;
  font-weight: 600;
  font-family: "SF Mono", SFMono-Regular, Consolas, "Liberation Mono", Menlo, monospace;
}
.latency-badge.hidden { visibility: hidden; }

.demo-result-body {
  padding: 1rem;
  overflow-x: auto;
  white-space: pre;
}

.demo-result-placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100px;
  color: #475569;
  font-style: italic;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  font-size: 0.875rem;
}

/* JSON syntax highlighting */
.json-key  { color: #93c5fd; }
.json-str  { color: #86efac; }
.json-num  { color: #fbbf24; }
.json-bool { color: #c084fc; }
.json-null { color: #94a3b8; }

/* ============================================================
   CODE TABS
   ============================================================ */
.demo-code {
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  overflow: hidden;
  margin-top: 1rem;
}
.demo-code-tabs {
  display: flex;
  background: #f1f5f9;
  border-bottom: 1px solid #e2e8f0;
  overflow-x: auto;
}
.demo-code-tab {
  padding: 0.6rem 1.1rem;
  font-size: 0.8rem;
  font-weight: 600;
  color: #64748b;
  cursor: pointer;
  border: none;
  background: none;
  border-bottom: 2px solid transparent;
  transition: color 0.2s, border-color 0.2s;
  font-family: "SF Mono", SFMono-Regular, Consolas, "Liberation Mono", Menlo, monospace;
  white-space: nowrap;
}
.demo-code-tab:hover { color: #1e293b; }
.demo-code-tab.active {
  color: #00b894;
  border-bottom-color: #00b894;
  background: #ffffff;
}
.demo-code-panel {
  display: none;
  background: #0f172a;
  padding: 1.25rem 1.5rem;
  font-family: "SF Mono", SFMono-Regular, Consolas, "Liberation Mono", Menlo, monospace;
  font-size: 0.82rem;
  line-height: 1.75;
  color: #e2e8f0;
  overflow-x: auto;
  white-space: pre;
}
.demo-code-panel.active { display: block; }

/* Code syntax */
.c-comment { color: #64748b; }
.c-keyword { color: #c084fc; }
.c-string  { color: #86efac; }
.c-func    { color: #93c5fd; }
.c-num     { color: #fbbf24; }
.c-var     { color: #e2e8f0; }
.c-prompt  { color: #00b894; user-select: none; }
.c-url     { color: #38bdf8; }

/* ============================================================
   NODE CALLOUTS  (latency stats row)
   ============================================================ */
.node-callouts {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1rem;
  margin-top: 1.5rem;
}
.node-callout {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  padding: 1rem;
  text-align: center;
}
.node-callout .nc-location {
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #00b894;
  margin-bottom: 0.25rem;
}
.node-callout .nc-latency {
  font-size: 1.1rem;
  font-weight: 700;
  color: #1e293b;
  font-family: "SF Mono", SFMono-Regular, Consolas, "Liberation Mono", Menlo, monospace;
}
.node-callout .nc-label {
  font-size: 0.75rem;
  color: #94a3b8;
  margin-top: 0.2rem;
}

/* ============================================================
   STREAM LOG  (live event feed)
   ============================================================ */
.stream-log {
  background: #0f172a;
  border-radius: 10px;
  font-family: "SF Mono", SFMono-Regular, Consolas, "Liberation Mono", Menlo, monospace;
  font-size: 0.82rem;
  color: #e2e8f0;
  overflow: hidden;
  margin-top: 1rem;
}
.stream-log-bar {
  background: #1e293b;
  padding: 0.5rem 1rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid #334155;
  font-size: 0.72rem;
  color: #64748b;
}
.stream-log-bar .indicator {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
}
.stream-log-bar .indicator .dot-live {
  width: 7px; height: 7px;
  border-radius: 50%;
  background: #4ade80;
  animation: pulse-dot 1.5s infinite;
}
@keyframes pulse-dot {
  0%, 100% { opacity: 1; }
  50%       { opacity: 0.3; }
}
.stream-log-body {
  padding: 1rem;
  min-height: 140px;
  max-height: 280px;
  overflow-y: auto;
}
.stream-log-line {
  display: block;
  line-height: 1.8;
  opacity: 0;
  transform: translateY(4px);
  transition: opacity 0.25s, transform 0.25s;
}
.stream-log-line.visible { opacity: 1; transform: translateY(0); }
.stream-log-line .ts  { color: #64748b; margin-right: 0.75rem; user-select: none; }
.stream-log-line .ev  { color: #00b894; margin-right: 0.5rem; }
.stream-log-line .val { color: #fbbf24; }

/* ============================================================
   SETTLEMENT FLOW
   ============================================================ */
.settlement-flow {
  display: flex;
  flex-direction: column;
  gap: 0;
  margin: 1.5rem 0;
}
.settlement-step {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  padding: 1rem 0;
}
.settlement-step:not(:last-child) { border-bottom: 1px solid #f1f5f9; }
.settlement-step-num {
  flex-shrink: 0;
  width: 2rem; height: 2rem;
  border-radius: 50%;
  background: rgba(0, 184, 148, 0.08);
  color: #00b894;
  font-size: 0.82rem;
  font-weight: 700;
  border: 1px solid rgba(0, 184, 148, 0.2);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: 0.15rem;
}
.settlement-step-text h4 { font-size: 0.92rem; color: #1e293b; margin-bottom: 0.2rem; }
.settlement-step-text p  { font-size: 0.85rem; color: #64748b; line-height: 1.55; max-width: none; }

/* ============================================================
   INLINE INFO BOX
   ============================================================ */
.info-box {
  background: rgba(0, 184, 148, 0.04);
  border: 1px solid rgba(0, 184, 148, 0.18);
  border-radius: 10px;
  padding: 1.1rem 1.4rem;
  margin: 1.25rem 0;
}
.info-box p { color: #475569; font-size: 0.9rem; line-height: 1.65; margin: 0; max-width: none; }
.info-box strong { color: #1e293b; }

/* ============================================================
   PROTOCOL TABLE
   ============================================================ */
.protocol-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.88rem;
}
.protocol-table th {
  text-align: left;
  padding: 0.6rem 1rem;
  background: #f8fafc;
  color: #64748b;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  border-bottom: 1px solid #e2e8f0;
}
.protocol-table td {
  padding: 0.6rem 1rem;
  border-bottom: 1px solid #f1f5f9;
  color: #334155;
  vertical-align: top;
}
.protocol-table tr:last-child td { border-bottom: none; }
.protocol-table tr:hover td { background: rgba(0, 184, 148, 0.02); }
.protocol-table .check { color: #00b894; font-weight: 700; }

/* ============================================================
   METRIC ROW
   ============================================================ */
.metric-row {
  display: flex;
  gap: 1.5rem;
  flex-wrap: wrap;
  margin: 1.25rem 0;
}
.metric-item { display: flex; flex-direction: column; gap: 0.15rem; }
.metric-item .metric-val {
  font-size: 1.6rem;
  font-weight: 800;
  color: #1e293b;
  letter-spacing: -0.03em;
  font-family: "SF Mono", SFMono-Regular, Consolas, "Liberation Mono", Menlo, monospace;
}
.metric-item .metric-val span { color: #00b894; font-size: 1rem; }
.metric-item .metric-label {
  font-size: 0.75rem;
  color: #94a3b8;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  font-weight: 600;
}

/* ============================================================
   "HOW IT WORKS" NETWORK GRAPHIC  (demos/index.html)
   ============================================================ */
.arch-v {
  display: flex;
  flex-direction: column;
  align-items: center;
  max-width: 600px;
  margin: 0 auto;
}
.arch-v-row {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  padding: 1.25rem 1.5rem;
  background: #f1f5f9;
  position: relative;
}
.arch-v-row.top    { border-radius: 16px 16px 0 0; }
.arch-v-row.bottom { border-radius: 0 0 16px 16px; }
.arch-v-box {
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  padding: 0.6rem 1rem;
  text-align: center;
  font-size: 0.82rem;
  font-weight: 600;
  color: #1e293b;
  min-width: 120px;
}
.arch-v-box-user    { background: #fff; border: 2px solid #1e293b; border-radius: 12px; padding: 0.9rem 1.3rem; font-size: 1rem; font-weight: 700; color: #1e293b; box-shadow: 0 2px 8px rgba(0,0,0,0.08); min-width: 120px; text-align: center; }
.arch-v-box-sertone { background: linear-gradient(135deg, rgba(0,184,148,0.08), rgba(0,184,148,0.03)); border: 1.5px solid rgba(0,184,148,0.4); color: #047857; font-size: 0.78rem; padding: 0.5rem 0.8rem; }
.arch-v-arrow-h     { color: #94a3b8; font-size: 1.2rem; }
.arch-v-label       { font-size: 0.65rem; font-weight: 700; color: #64748b; letter-spacing: 0.06em; text-transform: uppercase; margin-bottom: 0.3rem; }
.arch-v-sub         { font-size: 0.7rem; color: #94a3b8; margin-top: 0.3rem; }
.arch-v-between     { display: flex; justify-content: center; gap: 2rem; padding: 0.4rem 0; }
.arch-v-between span { font-size: 0.75rem; font-weight: 600; }

.arch-v-network {
  width: 100%;
  border-radius: 24px;
  background: linear-gradient(135deg, #00b894 0%, #00a381 55%, #007d65 100%);
  padding: 1.5rem;
  text-align: center;
  box-shadow: 0 6px 32px rgba(0, 184, 148, 0.3);
  position: relative;
  overflow: hidden;
}
.arch-v-network-title    { font-size: 1rem; font-weight: 800; color: #fff; letter-spacing: 0.06em; }
.arch-v-network-features { display: flex; justify-content: center; gap: 0.75rem; margin-top: 0.6rem; flex-wrap: wrap; }
.arch-v-network-features span {
  background: rgba(255,255,255,0.18);
  padding: 0.25rem 0.75rem;
  border-radius: 12px;
  font-size: 0.72rem;
  color: rgba(255,255,255,0.95);
  font-weight: 600;
  backdrop-filter: blur(4px);
}
.arch-v-network-tag { font-size: 0.72rem; color: rgba(255,255,255,0.7); margin-top: 0.5rem; }

@keyframes pulse-ring {
  0%   { transform: scale(0.8); opacity: 0.5; }
  100% { transform: scale(2.5); opacity: 0; }
}
.arch-v-network::before,
.arch-v-network::after {
  content: '';
  position: absolute;
  top: 50%; left: 50%;
  width: 60px; height: 60px;
  border-radius: 50%;
  border: 2px solid rgba(255,255,255,0.2);
  transform: translate(-50%,-50%);
  animation: pulse-ring 3s ease-out infinite;
}
.arch-v-network::after { animation-delay: 1.5s; }

/* ============================================================
   P2P MAP
   ============================================================ */
.p2p-map {
  background: #0f172a;
  border-radius: 14px;
  padding: 2rem;
  position: relative;
  min-height: 220px;
  overflow: hidden;
}
.p2p-map svg { width: 100%; height: 180px; }

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 1024px) {
  .demo-hub-grid    { grid-template-columns: repeat(2, 1fr); }
  .node-callouts    { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 768px) {
  h1 { font-size: 1.9rem; }
  h2 { font-size: 1.55rem; }

  .demo-hub-grid { grid-template-columns: 1fr; }

  .nav-toggle { display: block; }
  .nav-links {
    position: fixed;
    top: 3.75rem; left: 0; right: 0;
    background: rgba(255, 255, 255, 0.98);
    flex-direction: column;
    padding: 1.5rem;
    gap: 1rem;
    border-bottom: 1px solid #e2e8f0;
    transform: translateY(-100%);
    opacity: 0;
    pointer-events: none;
    transition: transform 0.3s, opacity 0.3s;
    z-index: 99;
  }
  .nav-links.open {
    transform: translateY(0);
    opacity: 1;
    pointer-events: auto;
  }

  .footer .container { flex-direction: column; gap: 1rem; text-align: center; }

  .arch-flow { flex-direction: column; min-width: 0; }
  .arch-arrow { transform: rotate(90deg); padding: 0.3rem 0; }

  .node-callouts  { grid-template-columns: repeat(2, 1fr); }
  .demo-form-row  { flex-direction: column; }
  .demo-form-field { min-width: 0; }
  .metric-row     { gap: 1rem; }

  .demo-interactive { padding: 1.25rem; }
  .demo-interactive-header { margin: -1.25rem -1.25rem 1rem; }

  .arch-v-network-features { gap: 0.5rem; }
}

@media (max-width: 480px) {
  .node-callouts { grid-template-columns: 1fr 1fr; }
  .demo-hero h1  { font-size: 1.65rem; }
  .demo-card     { padding: 1.25rem; }
}
