/* ===== Azure-inspired theme ===== */
:root {
  --azure-blue: #0078d4;
  --azure-blue-dark: #005a9e;
  --azure-blue-darker: #003c71;
  --azure-blue-light: #deecf9;
  --azure-blue-faint: #f3f9fd;
  --azure-cyan: #50e6ff;
  --ink: #1b1a19;
  --ink-2: #323130;
  --ink-3: #605e5c;
  --ink-4: #8a8886;
  --line: #edebe9;
  --line-2: #d2d0ce;
  --bg: #faf9f8;
  --card: #ffffff;
  --ok: #107c10;
  --ok-bg: #dff6dd;
  --warn: #b88217;
  --warn-bg: #fff4ce;
  --deny: #d13438;
  --deny-bg: #fde7e9;
  --neutral: #605e5c;
  --shadow: 0 1px 2px rgba(0, 0, 0, 0.06), 0 8px 24px rgba(0, 0, 0, 0.06);
  --radius: 10px;
  --radius-sm: 6px;
  --maxw: 1180px;
  --mono: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, monospace;
  --sans: "Segoe UI", system-ui, -apple-system, BlinkMacSystemFont, Roboto, Helvetica, Arial, sans-serif;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  font-family: var(--sans);
  background: var(--bg);
  color: var(--ink);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

a { color: var(--azure-blue-dark); text-decoration: none; }
a:hover { text-decoration: underline; }

.container {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 24px;
}

.skip-link {
  position: absolute;
  left: -10000px;
  top: 0;
  background: var(--azure-blue);
  color: white;
  padding: 8px 12px;
  z-index: 100;
}
.skip-link:focus { left: 8px; top: 8px; }

/* ===== Header ===== */
.site-header {
  background: white;
  border-bottom: 1px solid var(--line);
  position: sticky;
  top: 0;
  z-index: 10;
}
.header-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  height: 64px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--ink);
}
.brand:hover { text-decoration: none; }
.brand-text { display: flex; flex-direction: column; line-height: 1.1; }
.brand-title { font-weight: 600; font-size: 15px; color: var(--ink); }
.brand-sub { font-size: 12px; color: var(--ink-3); }
.site-nav { display: flex; gap: 4px; }
.site-nav a {
  padding: 8px 12px;
  border-radius: var(--radius-sm);
  color: var(--ink-2);
  font-size: 14px;
  font-weight: 500;
}
.site-nav a:hover { background: var(--azure-blue-faint); text-decoration: none; color: var(--azure-blue-dark); }
.site-nav a.active { background: var(--azure-blue-light); color: var(--azure-blue-darker); }

/* ===== Main / footer ===== */
.site-main { padding: 32px 0 64px; min-height: calc(100vh - 64px - 64px); }
.site-footer {
  border-top: 1px solid var(--line);
  background: white;
  font-size: 13px;
  color: var(--ink-3);
}
.footer-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  height: 64px;
  flex-wrap: wrap;
  gap: 8px;
}

/* ===== Hero ===== */
.hero {
  background: linear-gradient(135deg, var(--azure-blue-darker) 0%, var(--azure-blue) 60%, var(--azure-cyan) 130%);
  color: white;
  border-radius: 16px;
  padding: 48px 40px;
  margin-bottom: 40px;
  box-shadow: var(--shadow);
  position: relative;
  overflow: hidden;
}
.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 90% 20%, rgba(255,255,255,0.18) 0%, transparent 35%),
    radial-gradient(circle at 10% 90%, rgba(80,230,255,0.25) 0%, transparent 40%);
  pointer-events: none;
}
.hero h1 {
  font-size: 36px;
  margin: 0 0 12px;
  font-weight: 600;
  letter-spacing: -0.01em;
  position: relative;
}
.hero p { font-size: 17px; max-width: 720px; margin: 0; opacity: 0.95; position: relative; }

/* ===== Section / cards ===== */
.section-label {
  display: flex;
  align-items: baseline;
  gap: 12px;
  margin: 36px 0 14px;
}
.section-label h2 {
  font-size: 22px;
  margin: 0;
  color: var(--ink);
  font-weight: 600;
}
.section-label .badge { font-size: 12px; color: var(--ink-3); }
.section-desc { color: var(--ink-3); margin: 0 0 18px; max-width: 760px; }

.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 16px;
}
.card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 20px;
  text-decoration: none;
  color: inherit;
  transition: transform 120ms ease, box-shadow 120ms ease, border-color 120ms ease;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.card:hover {
  text-decoration: none;
  transform: translateY(-2px);
  box-shadow: var(--shadow);
  border-color: var(--azure-blue-light);
}
.card-title {
  font-weight: 600;
  font-size: 16px;
  color: var(--ink);
  display: flex;
  align-items: center;
  gap: 10px;
}
.card-icon {
  width: 28px; height: 28px;
  display: inline-flex; align-items: center; justify-content: center;
  border-radius: 6px;
  background: var(--azure-blue-faint);
  color: var(--azure-blue-dark);
  flex-shrink: 0;
}
.card-desc { color: var(--ink-3); font-size: 14px; margin: 0; }
.card-meta { display: flex; gap: 8px; flex-wrap: wrap; margin-top: auto; padding-top: 6px; }
.tag {
  font-size: 11px;
  padding: 2px 8px;
  border-radius: 999px;
  background: var(--azure-blue-faint);
  color: var(--azure-blue-darker);
  font-weight: 600;
  letter-spacing: 0.02em;
  text-transform: uppercase;
}
.tag.inbound { background: #e8f4ff; color: #003c71; }
.tag.outbound { background: #e6f7ec; color: #0b5d1e; }
.tag.security { background: #fde7e9; color: #8a1f23; }

/* ===== Categories on home ===== */
.category-block { margin-bottom: 32px; }

.question-banner {
  background: white;
  border: 1px solid var(--line);
  border-left: 4px solid var(--azure-blue);
  padding: 16px 20px;
  border-radius: var(--radius);
  margin-bottom: 14px;
}
.question-banner h3 { margin: 0 0 4px; font-size: 18px; font-weight: 600; }
.question-banner p { margin: 0; color: var(--ink-3); font-size: 14px; }

/* ===== Home: 3 catalog tiles (v2 monochrome design language) =====
   Visually aligned with .story-panel above — same white surface, same accent
   gradient hairline, same display typography. Per-category distinction is
   carried by the numeral colour only, matching the story panels. */
.cat-tile-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 24px;
  margin-bottom: 0;
  align-items: stretch;
}
@media (max-width: 1000px) { .cat-tile-grid { grid-template-columns: 1fr; } }

.cat-tile {
  position: relative;
  background: #fff;
  border: 1px solid rgba(0, 0, 0, 0.05);
  border-radius: 22px;
  padding: 36px 28px 28px;
  display: flex;
  flex-direction: column;
  box-shadow: 0 1px 1px rgba(0, 0, 0, 0.02), 0 10px 30px rgba(0, 0, 0, 0.04);
  overflow: hidden;
  transition: transform 280ms cubic-bezier(0.22, 1, 0.36, 1),
              box-shadow 280ms cubic-bezier(0.22, 1, 0.36, 1);
}
.cat-tile:hover {
  transform: translateY(-4px);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.03), 0 20px 50px rgba(0, 0, 0, 0.08);
}
.cat-tile::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 3px;
  background: linear-gradient(90deg, #0078d4 0%, #5dc6ff 50%, #9b8cff 100%);
  opacity: 0.85;
}

/* Per-category accent (only the numeral) — mirrors .story-panel--* */
.cat-tile--inbound  { --tile-num-color: #0078d4; }
.cat-tile--outbound { --tile-num-color: #5b8def; }
.cat-tile--security { --tile-num-color: #9b8cff; }

.cat-tile-header {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  margin-bottom: 16px;
}
.cat-tile-num {
  flex-shrink: 0;
  font-family: var(--font-display);
  font-size: 14px;
  font-weight: 600;
  color: var(--tile-num-color, #888);
  letter-spacing: 0.08em;
  padding-top: 4px;
  min-width: 22px;
}
.cat-tile-num::before { content: '0'; }
.cat-tile-title {
  font-family: var(--font-display);
  margin: 0 0 4px;
  font-size: 22px;
  font-weight: 600;
  color: #0a0a0a;
  letter-spacing: -0.01em;
}
.cat-tile-question {
  margin: 0;
  font-size: 13px;
  color: #6b6b6b;
  font-weight: 500;
}
.cat-tile-intro {
  margin: 0 0 18px;
  font-size: 14px;
  color: #444;
  line-height: 1.55;
}

.feature-link-list {
  list-style: none;
  margin: 0 0 20px;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.feature-link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 12px 14px;
  border-radius: 12px;
  background: transparent;
  border: 1px solid transparent;
  color: #1d1d1f;
  text-decoration: none;
  font-size: 14px;
  font-weight: 500;
  transition: background-color 180ms ease, border-color 180ms ease, transform 180ms ease;
}
.feature-link:hover {
  background: #f6f7f9;
  border-color: rgba(0, 0, 0, 0.06);
  color: #0a0a0a;
  text-decoration: none;
  transform: translateX(2px);
}
.feature-link-title { display: inline-block; }
.feature-link-arrow {
  color: #b0b0b0;
  font-weight: 500;
  font-size: 16px;
  opacity: 0.7;
  transition: opacity 180ms ease, transform 180ms ease, color 180ms ease;
}
.feature-link:hover .feature-link-arrow {
  opacity: 1;
  transform: translateX(3px);
  color: var(--tile-num-color, #0a0a0a);
}

.cat-tile-cta {
  margin-top: auto;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 8px 0 0;
  background: transparent;
  color: #0a0a0a;
  font-weight: 500;
  font-size: 14px;
  text-decoration: none;
  border-top: 1px solid rgba(0, 0, 0, 0.06);
  padding-top: 16px;
  transition: color 180ms ease, gap 180ms ease;
}
.cat-tile-cta:hover {
  color: var(--tile-num-color, #0a0a0a);
  text-decoration: none;
  gap: 8px;
}

/* ===== Provisioning + cost badges ===== */
.prov-legend {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin: 4px 0 20px 0;
  padding: 12px 14px;
  background: #f3f7fb;
  border: 1px solid #e1ebf3;
  border-radius: var(--radius-sm);
  font-size: 13px;
  color: var(--ink-2);
}
.prov-legend-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 12px;
}
.prov-legend-label { font-weight: 600; color: var(--ink-1); min-width: 160px; }
.prov-legend small { color: var(--ink-3); font-weight: 400; margin-left: 4px; }

.prov-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 2px 8px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 600;
  line-height: 1.6;
  white-space: nowrap;
  border: 1px solid transparent;
}
.prov-badge--lg {
  font-size: 12px;
  padding: 4px 10px;
}
.prov-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: currentColor;
  display: inline-block;
}
.prov-badge--native {
  background: #ecf8ee;
  color: #0b6a13;
  border-color: #c7e7cc;
}
.prov-badge--external {
  background: #fff4e5;
  color: #8a4a00;
  border-color: #f5d9b0;
}

/* Cost badges */
.cost-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 2px 8px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 700;
  line-height: 1.6;
  white-space: nowrap;
  border: 1px solid transparent;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}
.cost-badge--lg { font-size: 12px; padding: 4px 10px; }
.cost-badge small { font-weight: 400; font-family: inherit; color: var(--ink-3); }
.cost-badge--free  { background: #eef1f4; color: #4a5560; border-color: #d6dde4; }
.cost-badge--low   { background: #ecf8ee; color: #0b6a13; border-color: #c7e7cc; }
.cost-badge--mid   { background: #fff4e5; color: #8a4a00; border-color: #f5d9b0; }
.cost-badge--high  { background: #fde7e9; color: #a4262c; border-color: #f5c2c7; }

/* Place badges between title and arrow inside feature-link */
.feature-link { flex-wrap: wrap; }
.feature-link-main {
  display: inline-flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}
.feature-link-depends {
  font-size: 11px;
  color: var(--ink-3);
  font-weight: 400;
  font-style: italic;
}
.feature-link-badges {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-left: auto;
}
.feature-link .feature-link-arrow { margin-left: 6px; }

/* Builds-on callout on feature detail page */
.builds-on-callout {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 10px;
  margin: 0 0 20px 0;
  padding: 10px 14px;
  background: #fff8e6;
  border: 1px solid #f0d9a0;
  border-left: 3px solid #ca8a04;
  border-radius: var(--radius-sm);
  font-size: 13px;
  color: var(--ink-2);
}
.builds-on-label { font-weight: 700; color: #7c5f00; }
.depends-link {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 999px;
  background: #fff;
  border: 1px solid #f0d9a0;
  color: #7c5f00;
  font-weight: 600;
  font-size: 12px;
  text-decoration: none;
}
.depends-link:hover { background: #fef3c7; color: #7c5f00; text-decoration: none; }
.builds-on-note { color: var(--ink-3); font-size: 12px; flex-basis: 100%; }

/* Detail header tag stack */
.detail-header-tags {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 8px;
  flex-shrink: 0;
}

/* Card meta badge spacing */
.card-meta { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }

/* Required resources panel */
.req-note { margin: 0 0 10px 0; color: var(--ink-2); }
.req-note--native { color: #0b6a13; }
.req-note--external { color: #8a4a00; }
.req-note--cost-free { color: #4a5560; }
.req-note--cost-low { color: #0b6a13; }
.req-note--cost-mid { color: #8a4a00; }
.req-note--cost-high { color: #a4262c; }
.cost-detail { margin: 0 0 10px 0; color: var(--ink-2); font-size: 14px; line-height: 1.55; }
.cost-disclaimer { margin: 0; color: var(--ink-3); }
.cost-disclaimer a { color: var(--ink-3); text-decoration: underline; }
.req-list {
  margin: 0;
  padding-left: 20px;
  color: var(--ink-2);
  font-size: 14px;
  line-height: 1.6;
}
.req-list li { margin-bottom: 4px; }

/* ===== Feature detail page ===== */
.breadcrumb {
  font-size: 13px;
  color: var(--ink-3);
  margin-bottom: 8px;
  display: flex;
  gap: 6px;
  align-items: center;
}
.breadcrumb a { color: var(--ink-3); }
.breadcrumb .sep { opacity: 0.5; }

.detail-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 24px;
  flex-wrap: wrap;
  margin-bottom: 18px;
}
.detail-header h1 {
  font-size: 30px;
  margin: 0 0 6px;
  font-weight: 600;
  letter-spacing: -0.01em;
}
.detail-header .subtitle { color: var(--ink-3); margin: 0; max-width: 720px; }

.detail-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(280px, 1fr);
  gap: 24px;
}
@media (max-width: 900px) {
  .detail-layout { grid-template-columns: 1fr; }
}

.panel {
  background: white;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 20px;
  box-shadow: 0 1px 2px rgba(0,0,0,0.03);
}
.panel + .panel { margin-top: 16px; }
.panel h2 {
  margin: 0 0 12px;
  font-size: 18px;
  font-weight: 600;
  color: var(--ink-2);
}

/* ===== Diagram ===== */
.diagram-wrap {
  background: linear-gradient(180deg, #fbfdff 0%, #f3f8fd 100%);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 16px;
  position: relative;
}
.diagram-wrap svg {
  width: 100%;
  height: auto;
  display: block;
}
.diagram-controls {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  margin-top: 12px;
}
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 9px 16px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--line-2);
  background: white;
  color: var(--ink-2);
  font-weight: 600;
  font-size: 14px;
  cursor: pointer;
  font-family: inherit;
  transition: background 120ms, border-color 120ms, transform 50ms;
}
.btn:hover { background: var(--azure-blue-faint); border-color: var(--azure-blue); color: var(--azure-blue-darker); }
.btn:active { transform: translateY(1px); }
.btn.primary {
  background: var(--azure-blue);
  border-color: var(--azure-blue);
  color: white;
}
.btn.primary:hover { background: var(--azure-blue-dark); border-color: var(--azure-blue-dark); color: white; }
.btn.ghost { background: transparent; border-color: transparent; color: var(--ink-3); }
.step-readout {
  flex: 1 1 240px;
  font-size: 13px;
  color: var(--ink-3);
  min-height: 20px;
}
.step-readout strong { color: var(--ink); }

/* ===== Content blocks ===== */
.kv { display: grid; grid-template-columns: 160px 1fr; gap: 8px 12px; font-size: 14px; }
.kv dt { color: var(--ink-3); font-weight: 600; }
.kv dd { margin: 0; color: var(--ink-2); }

.list { margin: 0; padding-left: 20px; }
.list li { margin: 4px 0; color: var(--ink-2); font-size: 14px; }

.steps { counter-reset: step; padding: 0; margin: 0; list-style: none; }
.steps li {
  counter-increment: step;
  position: relative;
  padding: 10px 12px 10px 44px;
  border-radius: var(--radius-sm);
  font-size: 14px;
  color: var(--ink-2);
  margin-bottom: 4px;
  border-left: 3px solid transparent;
  transition: background 150ms, border-color 150ms;
}
.steps li::before {
  content: counter(step);
  position: absolute;
  left: 12px;
  top: 9px;
  width: 22px;
  height: 22px;
  border-radius: 999px;
  background: var(--azure-blue-faint);
  color: var(--azure-blue-darker);
  font-weight: 700;
  font-size: 12px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.steps li.active {
  background: var(--azure-blue-faint);
  border-left-color: var(--azure-blue);
}
.steps li.active::before {
  background: var(--azure-blue);
  color: white;
}

.pros-cons { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
@media (max-width: 600px) { .pros-cons { grid-template-columns: 1fr; } }
.pros-cons .panel-sub {
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  padding: 12px 14px;
  background: #fafafa;
}
.pros-cons .panel-sub h3 { margin: 0 0 6px; font-size: 13px; text-transform: uppercase; letter-spacing: 0.04em; color: var(--ink-3); }
.pros-cons .panel-sub.pros { border-color: #b8e6c2; background: #f3fbf5; }
.pros-cons .panel-sub.pros h3 { color: var(--ok); }
.pros-cons .panel-sub.cons { border-color: #f5c7c9; background: #fdf3f4; }
.pros-cons .panel-sub.cons h3 { color: var(--deny); }

.callout {
  border-left: 3px solid var(--azure-blue);
  background: var(--azure-blue-faint);
  padding: 10px 14px;
  border-radius: var(--radius-sm);
  font-size: 14px;
  color: var(--ink-2);
}
.callout.warn { border-color: var(--warn); background: var(--warn-bg); color: #5d4109; }

.placeholder-screen {
  border: 2px dashed var(--line-2);
  border-radius: var(--radius);
  background: #fafafa;
  text-align: center;
  padding: 24px;
  color: var(--ink-3);
  font-size: 13px;
}

/* ===== About ===== */
.about-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 16px;
}

/* ===== Diagram SVG primitives (used by JS-generated SVG) ===== */
.node-box {
  fill: white;
  stroke: var(--line-2);
  stroke-width: 1.5;
}
.node-box.app { fill: #eaf3fb; stroke: var(--azure-blue); }
.node-box.vnet {
  fill: #f6f0fb;
  stroke: #8764b8;
  stroke-dasharray: 6 4;
}
.node-box.subnet {
  fill: #efeaf7;
  stroke: #8764b8;
  stroke-dasharray: 4 3;
}
.node-box.bad { fill: #fde7e9; stroke: var(--deny); }
.node-box.ok { fill: #dff6dd; stroke: var(--ok); }

.node-label { font: 600 12px var(--sans); fill: var(--ink-2); }
.node-sub { font: 11px var(--sans); fill: var(--ink-3); }
.zone-label { font: 700 11px var(--sans); fill: #6b3fa0; letter-spacing: 0.06em; text-transform: uppercase; }

.flow-line { stroke: var(--azure-blue); stroke-width: 2.5; fill: none; stroke-linecap: round; }
.flow-line.allowed { stroke: var(--ok); }
.flow-line.denied  { stroke: var(--deny); stroke-dasharray: 4 4; opacity: 0.6; }
.flow-line.public  { stroke: var(--neutral); stroke-dasharray: 4 4; opacity: 0.55; }
.flow-line.private { stroke: var(--ok); }

.packet {
  fill: var(--azure-cyan);
  stroke: var(--azure-blue-dark);
  stroke-width: 1;
  opacity: 0;
}
.packet.run { opacity: 1; animation: packetMove 2.4s ease-in-out infinite; offset-rotate: 0deg; }

@keyframes packetMove {
  0%   { offset-distance: 0%; opacity: 0; }
  10%  { opacity: 1; }
  90%  { opacity: 1; }
  100% { offset-distance: 100%; opacity: 0; }
}

.pulse { animation: pulseGlow 1.6s ease-in-out infinite; }
@keyframes pulseGlow {
  0%, 100% { filter: drop-shadow(0 0 0 rgba(0,120,212,0)); }
  50%      { filter: drop-shadow(0 0 6px rgba(0,120,212,0.6)); }
}

.blink-allow text { animation: pulseColor 1.4s ease-in-out infinite; }
@keyframes pulseColor {
  0%, 100% { fill: var(--ink-2); }
  50% { fill: var(--ok); }
}

.cross-out {
  stroke: var(--deny);
  stroke-width: 3;
  stroke-linecap: round;
  opacity: 0;
  transition: opacity 250ms ease;
}
.cross-out.show { opacity: 0.9; }

.barrier {
  fill: rgba(209, 52, 56, 0.08);
  stroke: var(--deny);
  stroke-width: 2;
  stroke-dasharray: 6 4;
}

.legend {
  display: flex; flex-wrap: wrap; gap: 10px 16px;
  margin-top: 8px;
  font-size: 12px;
  color: var(--ink-3);
}
.legend .swatch {
  display: inline-block;
  width: 18px; height: 3px;
  vertical-align: middle;
  margin-right: 6px;
  border-radius: 2px;
}
.legend .swatch.priv  { background: var(--ok); }
.legend .swatch.pub   { background: var(--neutral); }
.legend .swatch.deny  { background: var(--deny); }
.legend .swatch.flow  { background: var(--azure-blue); }

/* ===== Category overview flow diagram ===== */
.category-flow .diagram-wrap { background: #fafbfc; border: 1px solid var(--line); border-radius: 10px; padding: 12px; }
.flow-overview { width: 100%; height: auto; max-height: 540px; display: block; }
.frontend-zone {
  fill: rgba(255, 176, 46, 0.06);
  stroke: #d9822b;
  stroke-width: 2;
  stroke-dasharray: 8 5;
}
.frontend-zone-label {
  font: 700 13px var(--sans);
  fill: #b65f15;
  letter-spacing: 0.04em;
}
.flow-col-labels text {
  font: 700 13px var(--sans);
  fill: var(--ink-2);
  letter-spacing: 0.02em;
}
.icon-node image { transform-box: fill-box; }
.icon-node-label { font: 600 13px var(--sans); fill: var(--ink); }
.icon-node-sub   { font: 11px var(--sans); fill: var(--ink-3); }

/* Print / accessibility */
@media (prefers-reduced-motion: reduce) {
  .packet.run, .pulse, .blink-allow text { animation: none !important; }
}

/* ================================================================== */
/* ===== ASN v2 — Apple-style hero + interactive system view ======== */
/* ================================================================== */

:root {
  --ink-0:   #050608;
  --ink-1:   #0b0f14;
  --ink-2:   #11171f;
  --ink-3:   #1a2230;
  --line-d:  rgba(255, 255, 255, 0.08);
  --line-d2: rgba(255, 255, 255, 0.14);
  --text-d:  rgba(255, 255, 255, 0.94);
  --text-d2: rgba(255, 255, 255, 0.68);
  --text-d3: rgba(255, 255, 255, 0.46);
  --accent:  #5dc6ff;
  --accent-2:#9b8cff;
  --accent-3:#3ee9b9;
  --warn-d:  #ffb86b;
  --maxw-v2: 1240px;
  --font-display: -apple-system, BlinkMacSystemFont, "SF Pro Display", "Segoe UI", "Inter", system-ui, sans-serif;
}

/* When the home view is active, let it run full-bleed (no container padding). */
body.is-home .site-main { padding: 0; }
body.is-home #view.container { max-width: none; padding: 0; }

/* Make the sticky header overlap the hero gracefully on home. */
body.is-home .site-header {
  background: rgba(255, 255, 255, 0.86);
  backdrop-filter: saturate(160%) blur(14px);
  -webkit-backdrop-filter: saturate(160%) blur(14px);
  border-bottom-color: rgba(0, 0, 0, 0.06);
}

/* ===== Reveal & motion primitives ===== */
.reveal {
  opacity: 0;
  transition: opacity 700ms cubic-bezier(0.22, 1, 0.36, 1),
              transform 700ms cubic-bezier(0.22, 1, 0.36, 1);
  will-change: opacity, transform;
}
.reveal--fade-up    { transform: translate3d(0, 24px, 0); }
.reveal--fade       { transform: none; }
.reveal--scale      { transform: scale(0.96); }
.reveal.is-revealed { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1 !important; transform: none !important; transition: none !important; }
}

/* ===== Shared section primitives ===== */
.asn-section-head {
  max-width: var(--maxw-v2);
  margin: 0 auto;
  padding: 96px 32px 36px;
  text-align: center;
}
.asn-section-head--dark { padding-top: 80px; padding-bottom: 28px; }
.asn-section-title {
  font-family: var(--font-display);
  font-size: clamp(28px, 4.6vw, 52px);
  line-height: 1.05;
  letter-spacing: -0.02em;
  font-weight: 600;
  color: #0a0a0a;
  margin: 8px auto 0;
  max-width: 22ch;
}
.asn-section-title--dark { color: var(--text-d); max-width: 26ch; }
.asn-section-lede {
  margin: 18px auto 0;
  max-width: 640px;
  font-size: clamp(15px, 1.4vw, 18px);
  line-height: 1.55;
  color: #4a4a4a;
}
.asn-section-lede--dark { color: var(--text-d2); }
.asn-eyebrow {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: #707070;
  margin: 0 0 6px;
}
.asn-eyebrow--dark { color: var(--text-d3); }

/* ===== Hero ===== */
.asn-hero {
  position: relative;
  min-height: clamp(560px, 92vh, 860px);
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  background:
    radial-gradient(ellipse 90% 60% at 50% 0%, rgba(93, 198, 255, 0.18), transparent 60%),
    radial-gradient(ellipse 70% 50% at 80% 100%, rgba(155, 140, 255, 0.14), transparent 60%),
    linear-gradient(180deg, #ffffff 0%, #f5f6f8 100%);
  overflow: hidden;
}
.asn-hero-grid {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(20, 30, 50, 0.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(20, 30, 50, 0.04) 1px, transparent 1px);
  background-size: 56px 56px;
  -webkit-mask-image: radial-gradient(circle at 50% 50%, black 0%, transparent 75%);
          mask-image: radial-gradient(circle at 50% 50%, black 0%, transparent 75%);
  pointer-events: none;
}
.asn-hero-inner {
  position: relative;
  max-width: 1080px;
  padding: 120px 32px 80px;
}
.asn-hero-title {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(48px, 9vw, 112px);
  line-height: 1;
  letter-spacing: -0.035em;
  color: #0a0a0a;
  margin: 12px 0 24px;
}
.asn-hero-title span { display: inline-block; }
.asn-hero-em {
  background: linear-gradient(120deg, #0078d4 0%, #5dc6ff 50%, #9b8cff 100%);
  -webkit-background-clip: text;
          background-clip: text;
  color: transparent;
  padding-left: 0.18em;
}
.asn-hero-lede {
  font-size: clamp(17px, 1.6vw, 22px);
  line-height: 1.5;
  color: #444;
  max-width: 680px;
  margin: 0 auto;
}
.asn-hero-cta {
  margin-top: 36px;
  display: inline-flex;
  gap: 12px;
  flex-wrap: wrap;
  justify-content: center;
}
.asn-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 14px 22px;
  border-radius: 999px;
  font-size: 15px;
  font-weight: 500;
  text-decoration: none;
  transition: transform 200ms cubic-bezier(0.22, 1, 0.36, 1),
              box-shadow 200ms cubic-bezier(0.22, 1, 0.36, 1),
              background-color 200ms ease, color 200ms ease;
  will-change: transform;
}
.asn-btn:hover { text-decoration: none; transform: translateY(-1px); }
.asn-btn--primary {
  background: #0a0a0a;
  color: #fff;
  box-shadow: 0 6px 24px rgba(0, 0, 0, 0.18);
}
.asn-btn--primary:hover { background: #1d1d1f; box-shadow: 0 10px 32px rgba(0, 0, 0, 0.22); color: #fff; }
.asn-btn--ghost {
  background: rgba(0, 0, 0, 0.04);
  color: #0a0a0a;
}
.asn-btn--ghost:hover { background: rgba(0, 0, 0, 0.08); color: #0a0a0a; }
.asn-hero-scroll {
  position: absolute;
  left: 50%;
  bottom: 36px;
  transform: translateX(-50%);
  font-size: 12px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: #777;
  display: inline-flex;
  align-items: center;
  gap: 10px;
}
.asn-hero-scroll-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #0a0a0a;
  animation: asn-scroll-bob 1.8s ease-in-out infinite;
}
@keyframes asn-scroll-bob {
  0%, 100% { transform: translateY(0); opacity: 0.6; }
  50%      { transform: translateY(6px); opacity: 1; }
}

/* ===== Story panels (3-up) ===== */
.asn-story {
  background: #fafafa;
  padding-bottom: 96px;
}
.asn-story-grid {
  max-width: var(--maxw-v2);
  margin: 24px auto 0;
  padding: 0 32px;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 24px;
}
.story-panel {
  background: #fff;
  border-radius: 22px;
  padding: 36px 28px;
  border: 1px solid rgba(0, 0, 0, 0.05);
  box-shadow: 0 1px 1px rgba(0, 0, 0, 0.02), 0 10px 30px rgba(0, 0, 0, 0.04);
  display: flex;
  flex-direction: column;
  min-height: 320px;
  transition: transform 280ms cubic-bezier(0.22, 1, 0.36, 1),
              box-shadow 280ms cubic-bezier(0.22, 1, 0.36, 1);
}
.story-panel:hover { transform: translateY(-4px); box-shadow: 0 2px 4px rgba(0, 0, 0, 0.03), 0 20px 50px rgba(0, 0, 0, 0.08); }
.story-num {
  font-family: var(--font-display);
  font-size: 14px;
  font-weight: 600;
  color: #b0b0b0;
  letter-spacing: 0.08em;
  margin-bottom: 18px;
}
.story-panel--inbound .story-num  { color: #0078d4; }
.story-panel--outbound .story-num { color: #5b8def; }
.story-panel--security .story-num { color: #9b8cff; }
.story-title {
  font-family: var(--font-display);
  font-size: 24px;
  letter-spacing: -0.01em;
  font-weight: 600;
  margin: 0 0 8px;
  color: #0a0a0a;
}
.story-question {
  font-size: 14px;
  color: #6b6b6b;
  margin: 0 0 16px;
}
.story-body {
  font-size: 15px;
  line-height: 1.55;
  color: #333;
  margin: 0 0 20px;
  flex: 1;
}
.story-cta {
  font-size: 14px;
  font-weight: 500;
  color: #0078d4;
  margin-top: auto;
}
.story-cta:hover { text-decoration: none; color: #005a9e; }

/* ===== System view (dark canvas) ===== */
.asn-system {
  position: relative;
  background: var(--ink-1);
  color: var(--text-d);
  overflow: hidden;
  padding-bottom: 80px;
  /* Smooth transition into the dark canvas from the light story section. */
  border-top-left-radius: 36px;
  border-top-right-radius: 36px;
  margin-top: -36px;
  box-shadow: 0 -24px 60px rgba(10, 14, 22, 0.18);
}
.asn-system-bg {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 60% 40% at 20% 10%, rgba(93, 198, 255, 0.12), transparent 60%),
    radial-gradient(ellipse 50% 40% at 85% 90%, rgba(155, 140, 255, 0.10), transparent 60%),
    linear-gradient(180deg, #0d1320 0%, #0b0f14 70%);
  pointer-events: none;
}
.asn-system-bg::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.04) 1px, transparent 1px);
  background-size: 48px 48px;
  -webkit-mask-image: radial-gradient(ellipse 80% 70% at 50% 50%, black, transparent 80%);
          mask-image: radial-gradient(ellipse 80% 70% at 50% 50%, black, transparent 80%);
}
.asn-system-canvas {
  position: relative;
  max-width: 1380px;
  margin: 12px auto 0;
  padding: 0 32px;
}
.sys-canvas {
  position: relative;
  border-radius: 22px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.02), rgba(255, 255, 255, 0) 60%);
  border: 1px solid var(--line-d);
  overflow: hidden;
}
.sys-svg {
  display: block;
  width: 100%;
  height: auto;
  font-family: var(--font-display);
}

/* Zones */
.sys-zone {
  fill: rgba(255, 255, 255, 0.015);
  stroke: rgba(255, 255, 255, 0.10);
  stroke-dasharray: 4 6;
}
.sys-zone--vnet     { stroke: rgba(93, 198, 255, 0.30); fill: rgba(93, 198, 255, 0.025); }
.sys-zone--frontend { stroke: rgba(255, 184, 107, 0.28); fill: rgba(255, 184, 107, 0.018); }
.sys-zone--app      { stroke: rgba(155, 140, 255, 0.32); fill: rgba(155, 140, 255, 0.030); }
.sys-zone--paas     { stroke: rgba(62, 233, 185, 0.28);  fill: rgba(62, 233, 185, 0.022); }
.sys-zone-label {
  fill: rgba(255, 255, 255, 0.72);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.04em;
}
.sys-zone-label--sub { fill: rgba(255, 255, 255, 0.46); font-size: 11px; font-weight: 500; }

/* Edges */
.sys-edge {
  stroke-width: 1.6;
  fill: none;
  transition: opacity 240ms ease, stroke 240ms ease, stroke-width 240ms ease;
}
.sys-edge--public  { stroke: rgba(93, 198, 255, 0.55); }
.sys-edge--private { stroke: rgba(62, 233, 185, 0.55); }
.sys-edge--egress  { stroke: rgba(155, 220, 200, 0.45); stroke-dasharray: 6 4; }
.sys-edge--mgmt    { stroke: rgba(255, 255, 255, 0.22); stroke-dasharray: 2 5; }
.sys-edge.is-active     { stroke-width: 2.4; filter: url(#sys-glow); }
.sys-edge.sys-edge--muted { opacity: 0.12; }

/* Particles (head-only; trail comes from the edge glow on focus) */
.sys-packet {
  pointer-events: none;
  transition: opacity 200ms ease;
}
.sys-packet--public  { fill: #5dc6ff; }
.sys-packet--private { fill: #3ee9b9; }
.sys-packet--egress  { fill: #b9e8d6; }
.sys-packet--mgmt    { fill: rgba(255, 255, 255, 0.55); r: 2.5; }

/* Nodes */
.sys-node {
  cursor: pointer;
  transition: opacity 240ms ease, transform 240ms cubic-bezier(0.22, 1, 0.36, 1);
  transform-box: fill-box;
  transform-origin: center;
}
.sys-node:focus { outline: none; }
.sys-node:focus-visible .sys-node-plate { stroke: var(--accent); stroke-width: 2; }
.sys-node-plate {
  fill: rgba(255, 255, 255, 0.04);
  stroke: rgba(255, 255, 255, 0.10);
  stroke-width: 1;
  transition: fill 200ms ease, stroke 200ms ease;
}
.sys-node-halo {
  fill: rgba(93, 198, 255, 0);
  transition: fill 280ms ease, r 280ms ease;
}
.sys-node-label {
  fill: var(--text-d);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.01em;
  pointer-events: none;
}
.sys-node-sub {
  fill: var(--text-d3);
  font-size: 10.5px;
  font-weight: 500;
  pointer-events: none;
}
.sys-node[data-dim="1"] { opacity: 0.78; }
.sys-node:hover .sys-node-plate { fill: rgba(255, 255, 255, 0.09); stroke: rgba(255, 255, 255, 0.22); }
.sys-node:hover .sys-node-halo  { fill: rgba(93, 198, 255, 0.10); }

.sys-node.is-active .sys-node-plate { stroke: var(--accent); stroke-width: 1.6; fill: rgba(93, 198, 255, 0.10); }
.sys-node.is-active .sys-node-halo  { fill: rgba(93, 198, 255, 0.16); animation: sys-pulse 2400ms ease-in-out infinite; }
.sys-node.is-active .sys-node-label { fill: #fff; }
.sys-node.is-dim    { opacity: 0.28; }

.sys-svg.has-focus .sys-zone { opacity: 0.55; }

@keyframes sys-pulse {
  0%   { transform: scale(1);   fill-opacity: 0.16; }
  50%  { transform: scale(1.06); fill-opacity: 0.28; }
  100% { transform: scale(1);   fill-opacity: 0.16; }
}

/* Tooltip */
.sys-tooltip {
  position: absolute;
  top: 0;
  left: 0;
  pointer-events: none;
  background: rgba(10, 14, 22, 0.92);
  border: 1px solid var(--line-d2);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border-radius: 10px;
  padding: 10px 12px;
  min-width: 180px;
  max-width: 220px;
  color: var(--text-d);
  font-size: 12px;
  opacity: 0;
  transition: opacity 160ms ease;
  z-index: 5;
  will-change: transform, opacity;
}
.sys-tooltip.is-visible { opacity: 1; }
.sys-tooltip-title { font-weight: 600; font-size: 13px; margin-bottom: 2px; }
.sys-tooltip-sub   { color: var(--text-d2); font-size: 11.5px; }
.sys-tooltip-hint  { color: var(--accent); font-size: 11px; margin-top: 6px; letter-spacing: 0.02em; }

/* Detail panel */
.sys-panel {
  position: absolute;
  top: 24px;
  right: 24px;
  width: 320px;
  background: rgba(11, 15, 20, 0.88);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid var(--line-d2);
  border-radius: 14px;
  padding: 22px 22px 20px;
  color: var(--text-d);
  opacity: 0;
  transform: translate3d(16px, 0, 0);
  pointer-events: none;
  transition: opacity 260ms cubic-bezier(0.22, 1, 0.36, 1),
              transform 260ms cubic-bezier(0.22, 1, 0.36, 1);
  z-index: 4;
}
.sys-panel.is-open { opacity: 1; transform: none; pointer-events: auto; }
.sys-panel-close {
  position: absolute;
  top: 10px;
  right: 12px;
  background: transparent;
  border: 0;
  color: var(--text-d2);
  font-size: 22px;
  line-height: 1;
  cursor: pointer;
  padding: 4px 8px;
  border-radius: 6px;
}
.sys-panel-close:hover { color: var(--text-d); background: rgba(255, 255, 255, 0.06); }
.sys-panel-eyebrow {
  font-size: 11px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 6px;
}
.sys-panel-title {
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: 600;
  margin: 0 0 4px;
  letter-spacing: -0.01em;
}
.sys-panel-sub { color: var(--text-d2); font-size: 13px; margin: 0 0 14px; }
.sys-panel-body { font-size: 13.5px; line-height: 1.55; color: var(--text-d2); }
.sys-panel-body p { margin: 0 0 10px; }
.sys-panel-list { margin: 8px 0 0; padding-left: 18px; }
.sys-panel-list li { margin: 4px 0; color: var(--text-d2); font-size: 13px; }
.sys-panel-list strong { color: var(--text-d); }
.sys-panel-link {
  display: inline-block;
  margin-top: 14px;
  padding: 8px 14px;
  background: var(--accent);
  color: #0a0a0a;
  font-weight: 600;
  font-size: 13px;
  border-radius: 999px;
  text-decoration: none;
  transition: background-color 200ms ease, transform 200ms ease;
}
.sys-panel-link:hover { background: #8fd8ff; transform: translateY(-1px); text-decoration: none; color: #0a0a0a; }
.sys-panel-link.is-hidden { display: none; }
.sys-panel-self {
  color: var(--text-d3);
  font-size: 12.5px;
  font-style: italic;
  margin-top: 8px;
}

/* Legend */
.sys-legend {
  position: absolute;
  bottom: 16px;
  left: 24px;
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  font-size: 11.5px;
  color: var(--text-d2);
  pointer-events: none;
}
.sys-legend span { display: inline-flex; align-items: center; gap: 6px; }
.sys-legend-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  display: inline-block;
}
.sys-legend-dot--public  { background: #5dc6ff; }
.sys-legend-dot--private { background: #3ee9b9; }
.sys-legend-dot--egress  { background: #b9e8d6; }
.sys-legend-dot--dns     { background: #ffb86b; }
.sys-legend-dot--mgmt    { background: rgba(255, 255, 255, 0.55); }

/* ===== Per-feature topology additions ===== */

/* DNS edges — amber dashed, distinct from data plane */
.sys-edge--dns {
  stroke: rgba(255, 184, 107, 0.55);
  stroke-dasharray: 3 4;
}
.sys-packet--dns { fill: #ffb86b; }

/* Blocked edges — red dashed; the "packet" is a static X marker */
.sys-edge--blocked {
  stroke: rgba(255, 96, 96, 0.65);
  stroke-dasharray: 6 4;
  stroke-width: 1.4;
}
.sys-packet--blocked line {
  stroke: #ff6060;
  stroke-width: 2.4;
  stroke-linecap: round;
}
.sys-packet--blocked {
  filter: drop-shadow(0 0 4px rgba(255, 96, 96, 0.55));
  pointer-events: none;
}

/* Edge mid-line label pill (e.g. "1. resolve", "deny") */
.sys-edge-label-bg {
  fill: rgba(11, 15, 20, 0.85);
  stroke: rgba(255, 255, 255, 0.12);
  stroke-width: 0.6;
  rx: 4;
  ry: 4;
}
.sys-edge-label-text {
  fill: rgba(245, 246, 248, 0.92);
  font-size: 10.5px;
  font-weight: 500;
  letter-spacing: 0.01em;
  pointer-events: none;
  font-family: 'Segoe UI', system-ui, sans-serif;
}
.sys-edge-label--blocked .sys-edge-label-bg {
  fill: rgba(60, 14, 14, 0.92);
  stroke: rgba(255, 96, 96, 0.55);
}
.sys-edge-label--blocked .sys-edge-label-text { fill: #ffb1b1; }

.sys-edge-label--dns .sys-edge-label-bg {
  stroke: rgba(255, 184, 107, 0.35);
}
.sys-edge-label--dns .sys-edge-label-text { fill: #ffd8a8; }

/* Node badge — small accent pill above-right (e.g. "WAF", "Static IP") */
.sys-node-badge-bg {
  fill: rgba(11, 15, 20, 0.9);
  stroke: rgba(93, 198, 255, 0.55);
  stroke-width: 0.8;
  rx: 8;
  ry: 8;
}
.sys-node-badge-text {
  fill: #cce8ff;
  font-size: 9.5px;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  pointer-events: none;
  font-family: 'Segoe UI', system-ui, sans-serif;
}

/* Dimmed node — shows that an endpoint is disabled/denied (not removed) */
.sys-node--dim { opacity: 0.42; }
.sys-node--dim .sys-node-plate {
  stroke-dasharray: 4 3;
  stroke: rgba(255, 96, 96, 0.55);
}

/* Direction header banner — sits at top-left of the canvas */
.sys-direction {
  position: absolute;
  top: 18px;
  left: 22px;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 6px 14px 6px 10px;
  border-radius: 999px;
  background: rgba(11, 15, 20, 0.72);
  border: 1px solid rgba(255, 255, 255, 0.10);
  backdrop-filter: blur(8px);
  font-size: 12px;
  font-weight: 600;
  color: rgba(245, 246, 248, 0.92);
  letter-spacing: 0.02em;
  z-index: 4;
  pointer-events: none;
}
.sys-direction-icon {
  width: 18px;
  height: 18px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 12px;
  font-weight: 700;
}
.sys-direction-text { font-weight: 600; }
.sys-direction-sub  { color: rgba(245, 246, 248, 0.62); font-weight: 500; margin-left: 4px; }

.sys-direction--inbound  .sys-direction-icon { background: linear-gradient(135deg, #5dc6ff, #2f7fff); }
.sys-direction--outbound .sys-direction-icon { background: linear-gradient(135deg, #3ee9b9, #19a373); }
.sys-direction--security .sys-direction-icon { background: linear-gradient(135deg, #c39bff, #7a4fff); }

.sys-direction--inbound  { border-color: rgba(93, 198, 255, 0.35); }
.sys-direction--outbound { border-color: rgba(62, 233, 185, 0.35); }
.sys-direction--security { border-color: rgba(195, 155, 255, 0.40); }

/* Adjust compact canvas so the badge isn't clipped by the panel */
.sys-canvas--compact .sys-direction { top: 14px; left: 18px; }

/* ===== Catalog (existing tiles, just spacing tweaks under the dark section) ===== */
.asn-catalog {
  background: #fafafa;
  padding-bottom: 96px;
}
.asn-catalog .cat-tile-grid,
.asn-catalog .prov-legend {
  max-width: var(--maxw-v2);
  margin-left: auto;
  margin-right: auto;
  padding: 0 32px;
}
.asn-catalog .prov-legend { margin-bottom: 22px; }

/* ===== Responsive ===== */
@media (max-width: 980px) {
  .asn-story-grid { grid-template-columns: 1fr; }
  .sys-panel { right: 16px; left: 16px; width: auto; }
  .asn-system-canvas { padding: 0 16px; }
  .asn-section-head { padding-left: 24px; padding-right: 24px; }
}
@media (max-width: 640px) {
  .asn-hero-inner { padding: 96px 24px 80px; }
  .asn-hero-cta { flex-direction: column; width: 100%; }
  .asn-btn { width: 100%; justify-content: center; }
  .sys-legend { position: static; padding: 14px 16px 18px; }
}

/* Honour reduced motion globally for v2. */
@media (prefers-reduced-motion: reduce) {
  .asn-hero-scroll-dot { animation: none !important; }
  .sys-node.is-active .sys-node-halo { animation: none !important; }
  .sys-packet { display: none; }
}

/* ===== Feature page — live topology in context =====
   Replaces the legacy static SVG + step controls. Inherits the dark .sys-*
   visual language so feature pages feel like a continuation of the home
   system view rather than a separate aesthetic. */
.feature-system {
  background:
    radial-gradient(ellipse 60% 40% at 20% 10%, rgba(93, 198, 255, 0.12), transparent 60%),
    radial-gradient(ellipse 50% 40% at 85% 90%, rgba(155, 140, 255, 0.10), transparent 60%),
    linear-gradient(180deg, #0d1320 0%, #0b0f14 70%);
  color: var(--text-d);
  border-radius: 22px;
  padding: 28px 28px 24px;
  margin-bottom: 16px;
  border: 1px solid var(--line-d);
  box-shadow: 0 24px 60px rgba(10, 14, 22, 0.18);
  overflow: hidden;
  position: relative;
}
.feature-system::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.04) 1px, transparent 1px);
  background-size: 48px 48px;
  -webkit-mask-image: radial-gradient(ellipse 80% 70% at 50% 50%, black, transparent 80%);
          mask-image: radial-gradient(ellipse 80% 70% at 50% 50%, black, transparent 80%);
  pointer-events: none;
  opacity: 0.6;
}
.feature-system-head {
  position: relative;
  max-width: 640px;
  margin: 0 0 18px;
}
.feature-system-title {
  font-family: var(--font-display);
  font-size: clamp(22px, 2.4vw, 28px);
  font-weight: 600;
  letter-spacing: -0.01em;
  color: var(--text-d);
  margin: 6px 0 8px;
}
.feature-system-lede {
  font-size: 14px;
  line-height: 1.55;
  color: var(--text-d2);
  margin: 0;
}
.feature-system-lede strong { color: var(--text-d); font-weight: 600; }
.feature-system-canvas {
  position: relative;
  margin: 0;
}
/* Compact mount tweaks — slightly tighter chrome inside feature pages. */
.sys-canvas--compact {
  border-radius: 16px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.025), rgba(255, 255, 255, 0) 60%);
}
.sys-canvas--compact .sys-panel {
  top: 16px;
  right: 16px;
  width: 280px;
  padding: 18px 18px 16px;
}
.sys-canvas--compact .sys-legend {
  bottom: 12px;
  left: 16px;
  font-size: 11px;
  gap: 12px;
}
@media (max-width: 980px) {
  .feature-system { padding: 22px 18px 18px; }
  .sys-canvas--compact .sys-panel { right: 12px; left: 12px; width: auto; top: 12px; }
}
