/* ─────────────────────────────────────────────────────────────
   Page 11 — Product Architecture
   ───────────────────────────────────────────────────────────── */

/* The cosmos overview — six concentric rings with primitive labels */
.cosmos-map {
  position: relative;
  padding: 80px 24px 60px;
  border-radius: var(--radius-2xl);
  background:
    radial-gradient(ellipse 80% 60% at 50% 50%, rgba(47,55,255,0.16), transparent 65%),
    linear-gradient(180deg, #000000, #050818);
  border: 1px solid rgba(255,255,255,0.10);
  isolation: isolate;
  overflow: hidden;
}
.cosmos-map::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background-image:
    radial-gradient(circle, rgba(255,255,255,0.55) 0.5px, transparent 0.5px),
    radial-gradient(circle, rgba(255,255,255,0.32) 0.5px, transparent 0.5px);
  background-size: 220px 220px, 360px 360px;
  background-position: 30px 30px, 160px 90px;
  opacity: 0.45;
  mask-image: radial-gradient(ellipse 80% 80% at 50% 50%, black, transparent 85%);
}
.cosmos-map .stage {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 10;
  margin: 0 auto;
  max-width: 980px;
}
.cosmos-map .stage svg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  overflow: visible;
}
.cosmos-map .label {
  position: absolute;
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.78);
  white-space: nowrap;
}
.cosmos-map .label b {
  font-weight: 500;
  color: #FFFFFF;
  display: block;
  font-family: var(--font-sans);
  font-size: 14px;
  letter-spacing: -0.005em;
  text-transform: none;
  margin-top: 4px;
}
.cosmos-map .legend {
  margin: 56px auto 0;
  max-width: 720px;
  font-size: 14px;
  line-height: 1.55;
  color: rgba(255,255,255,0.78);
  text-align: center;
  text-wrap: balance;
}
.cosmos-map .legend em {
  font-style: normal;
  color: var(--blue-300);
}

/* Primitive deep-dive cards */
.primitive-list { display: flex; flex-direction: column; gap: 14px; }
.primitive-card {
  display: grid;
  grid-template-columns: 88px 1fr 1.2fr;
  border: 1px solid var(--border-default);
  border-radius: var(--radius-xl);
  overflow: hidden;
  background: rgba(255,255,255,0.02);
}
@media (max-width: 900px) {
  .primitive-card { grid-template-columns: 1fr; }
  .primitive-card .glyph { min-height: 90px; }
}
.primitive-card .glyph {
  border-right: 1px solid var(--border-subtle);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  background:
    radial-gradient(circle at 50% 50%, rgba(47,55,255,0.16), transparent 70%);
  position: relative;
  overflow: hidden;
}
.primitive-card .glyph svg {
  width: 72px;
  height: 72px;
  overflow: visible;
  stroke: #FFFFFF;
  fill: none;
  stroke-width: 1.6;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.primitive-card .glyph svg .fill { fill: #FFFFFF; stroke: none; }
.primitive-card .glyph svg .dust { fill: rgba(195,179,255,0.6); stroke: none; }
.primitive-card .glyph svg .stardust { fill: rgba(133,160,255,0.5); stroke: none; }

/* ── Atom animation — pulsing single dot */
.primitive-card .glyph svg.atom .core {
  transform-origin: center;
  transform-box: fill-box;
  animation: atomPulse 3.2s ease-in-out infinite;
}
.primitive-card .glyph svg.atom .core-glow {
  fill: rgba(255,255,255,0.18);
  stroke: none;
  transform-origin: center;
  transform-box: fill-box;
  animation: atomGlow 3.2s ease-in-out infinite;
}
@keyframes atomPulse {
  0%, 100% { transform: scale(0.92); }
  50% { transform: scale(1.08); }
}
@keyframes atomGlow {
  0%, 100% { transform: scale(0.8); opacity: 0.4; }
  50% { transform: scale(1.6); opacity: 0.9; }
}

/* ── Molecule — three overlapping circles, breath */
.primitive-card .glyph svg.molecule .c {
  transform-origin: center;
  transform-box: fill-box;
  animation: molBreath 4.8s ease-in-out infinite;
}
.primitive-card .glyph svg.molecule .c.c2 { animation-delay: 0.5s; }
.primitive-card .glyph svg.molecule .c.c3 { animation-delay: 1s; }
@keyframes molBreath {
  0%, 100% { opacity: 0.55; transform: scale(1); }
  50% { opacity: 1; transform: scale(1.06); }
}

/* ── Organism — 16-circle grid, ripple highlight */
.primitive-card .glyph svg.organism .o {
  transform-origin: center;
  transform-box: fill-box;
  opacity: 0.4;
  animation: orgRipple 5s ease-in-out infinite;
}
@keyframes orgRipple {
  0%, 100% { opacity: 0.4; }
  50% { opacity: 1; }
}

/* ── Planet — Saturn with rotating ring */
.primitive-card .glyph svg.planet .ring {
  transform-origin: center;
  transform-box: fill-box;
  animation: planetRing 24s linear infinite;
}
@keyframes planetRing {
  to { transform: rotate(360deg); }
}

/* ── Solar System — concentric orbits with planets */
.primitive-card .glyph svg.solar .orbit { stroke: rgba(255,255,255,0.45); }
.primitive-card .glyph svg.solar .planet-1,
.primitive-card .glyph svg.solar .planet-2,
.primitive-card .glyph svg.solar .planet-3 {
  transform-origin: center;
  transform-box: fill-box;
}
.primitive-card .glyph svg.solar .planet-1 { animation: solarSpin 18s linear infinite; }
.primitive-card .glyph svg.solar .planet-2 { animation: solarSpin 28s linear infinite reverse; }
.primitive-card .glyph svg.solar .planet-3 { animation: solarSpin 40s linear infinite; }
@keyframes solarSpin { to { transform: rotate(360deg); } }

/* ── Galaxy — multi-cluster spiral drift */
.primitive-card .glyph svg.galaxy .g {
  transform-origin: center;
  transform-box: fill-box;
}
.primitive-card .glyph svg.galaxy .g-1 { animation: galaxyDrift 14s linear infinite; }
.primitive-card .glyph svg.galaxy .g-2 { animation: galaxyDrift 20s linear infinite reverse; }
.primitive-card .glyph svg.galaxy .g-3 { animation: galaxyDrift 16s linear infinite; }
.primitive-card .glyph svg.galaxy .dust-cloud {
  opacity: 0.55;
  animation: galaxyDustDrift 7s ease-in-out infinite;
}
@keyframes galaxyDrift { to { transform: rotate(360deg); } }
@keyframes galaxyDustDrift {
  0%, 100% { opacity: 0.4; }
  50% { opacity: 0.85; }
}

@media (prefers-reduced-motion: reduce) {
  .primitive-card .glyph svg * { animation: none !important; }
}

/* ─────────────────────────────────────────────────────────────
   Architecture lineup — full-row hero matching the reference
   ───────────────────────────────────────────────────────────── */
.lineup {
  border: 1px solid rgba(255,255,255,0.10);
  border-radius: var(--radius-2xl);
  background:
    radial-gradient(ellipse 90% 80% at 50% 50%, rgba(47,55,255,0.12), transparent 65%),
    linear-gradient(180deg, #000000, #050818);
  padding: 56px 32px 48px;
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 18px;
  position: relative;
  overflow: hidden;
  isolation: isolate;
}
.lineup::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background-image: radial-gradient(circle, rgba(255,255,255,0.55) 0.5px, transparent 0.5px);
  background-size: 220px 220px;
  background-position: 30px 20px;
  opacity: 0.35;
  mask-image: radial-gradient(ellipse 90% 80% at 50% 50%, black, transparent 85%);
}
.lineup > * { position: relative; z-index: 1; }
.lineup .col {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 22px;
  text-align: center;
}
.lineup .col .top,
.lineup .col .bottom {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.78);
  line-height: 1.4;
}
.lineup .col .bottom { color: rgba(255,255,255,0.6); }
.lineup .col .glyph {
  width: 100%;
  aspect-ratio: 1;
  max-width: 120px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.lineup .col .glyph svg {
  width: 100%;
  height: 100%;
  overflow: visible;
  stroke: #FFFFFF;
  fill: none;
  stroke-width: 1.2;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.lineup .col .glyph svg .fill { fill: #FFFFFF; stroke: none; }
.lineup .col .glyph svg .dust { fill: rgba(195,179,255,0.6); stroke: none; }

/* Reuse the same animations for the lineup glyphs */
.lineup .glyph svg.atom .core { transform-origin: center; transform-box: fill-box; animation: atomPulse 3.2s ease-in-out infinite; }
.lineup .glyph svg.atom .core-glow { fill: rgba(255,255,255,0.18); stroke: none; transform-origin: center; transform-box: fill-box; animation: atomGlow 3.2s ease-in-out infinite; }
.lineup .glyph svg.molecule .c { transform-origin: center; transform-box: fill-box; animation: molBreath 4.8s ease-in-out infinite; }
.lineup .glyph svg.molecule .c.c2 { animation-delay: 0.5s; }
.lineup .glyph svg.molecule .c.c3 { animation-delay: 1s; }
.lineup .glyph svg.organism .o { transform-origin: center; transform-box: fill-box; opacity: 0.4; animation: orgRipple 5s ease-in-out infinite; }
.lineup .glyph svg.planet .ring { transform-origin: center; transform-box: fill-box; animation: planetRing 24s linear infinite; }
.lineup .glyph svg.solar .orbit { stroke: rgba(255,255,255,0.45); }
.lineup .glyph svg.solar .planet-1 { transform-origin: center; transform-box: fill-box; animation: solarSpin 18s linear infinite; }
.lineup .glyph svg.solar .planet-2 { transform-origin: center; transform-box: fill-box; animation: solarSpin 28s linear infinite reverse; }
.lineup .glyph svg.solar .planet-3 { transform-origin: center; transform-box: fill-box; animation: solarSpin 40s linear infinite; }
.lineup .glyph svg.galaxy .g { transform-origin: center; transform-box: fill-box; }
.lineup .glyph svg.galaxy .g-1 { animation: galaxyDrift 14s linear infinite; }
.lineup .glyph svg.galaxy .g-2 { animation: galaxyDrift 20s linear infinite reverse; }
.lineup .glyph svg.galaxy .g-3 { animation: galaxyDrift 16s linear infinite; }
.lineup .glyph svg.galaxy .dust-cloud { opacity: 0.55; animation: galaxyDustDrift 7s ease-in-out infinite; }

@media (prefers-reduced-motion: reduce) {
  .lineup .glyph svg * { animation: none !important; }
}
@media (max-width: 1100px) { .lineup { grid-template-columns: repeat(3, 1fr); padding: 36px 20px; } }
@media (max-width: 540px) { .lineup { grid-template-columns: repeat(2, 1fr); } }

/* Stagger reveal for the lineup cols */
.lineup[data-reveal] .col {
  opacity: 0;
  transform: translateY(12px);
  transition: opacity 700ms ease, transform 700ms cubic-bezier(0.22, 1, 0.36, 1);
}
.lineup[data-reveal].is-revealed .col { opacity: 1; transform: translateY(0); }
.lineup[data-reveal].is-revealed .col:nth-child(1) { transition-delay: 100ms; }
.lineup[data-reveal].is-revealed .col:nth-child(2) { transition-delay: 220ms; }
.lineup[data-reveal].is-revealed .col:nth-child(3) { transition-delay: 340ms; }
.lineup[data-reveal].is-revealed .col:nth-child(4) { transition-delay: 460ms; }
.lineup[data-reveal].is-revealed .col:nth-child(5) { transition-delay: 580ms; }
.lineup[data-reveal].is-revealed .col:nth-child(6) { transition-delay: 700ms; }

/* ─────────────────────────────────────────────────────────────
   Per-primitive feature blocks — atom / chain / entity / etc
   Big editorial visuals matching the user references
   ───────────────────────────────────────────────────────────── */
.feature-block {
  border-radius: var(--radius-2xl);
  background:
    radial-gradient(ellipse 80% 100% at 50% 50%, rgba(47,55,255,0.20), transparent 65%),
    linear-gradient(180deg, #000000, #050818 50%, #0A0F2E);
  border: 1px solid rgba(255,255,255,0.10);
  padding: 56px 56px;
  position: relative;
  overflow: hidden;
  isolation: isolate;
  margin-top: 14px;
}
.feature-block::after {
  content: "";
  position: absolute;
  inset: 0;
  background-image: radial-gradient(circle, rgba(255,255,255,0.5) 0.5px, transparent 0.5px);
  background-size: 200px 200px;
  background-position: 30px 20px;
  opacity: 0.35;
  mask-image: radial-gradient(ellipse 90% 80% at 50% 50%, black, transparent 85%);
  pointer-events: none;
}
.feature-block > * { position: relative; z-index: 1; }
.feature-block .lbl {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--blue-300);
  margin-bottom: 8px;
}
.feature-block h4 {
  font-size: clamp(22px, 2.4vw, 30px);
  letter-spacing: -0.022em;
  font-weight: 600;
  margin: 0 0 32px;
  color: #FFFFFF;
}
.feature-block .stage {
  position: relative;
  display: grid;
  place-items: center;
  min-height: 240px;
  padding: 8px;
}
.feature-block .stage svg { width: 100%; max-width: 720px; height: auto; overflow: visible; }
@media (max-width: 720px) { .feature-block { padding: 32px 24px; } }

/* Atom feature — POTENTIAL → DECISION → REALITY */
.fb-atom .stage svg .arrow {
  fill: none;
  stroke: rgba(255,255,255,0.78);
  stroke-width: 1.4;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.fb-atom .stage svg .arrow-head {
  fill: rgba(255,255,255,0.78);
  stroke: none;
}
.fb-atom .stage svg .lbl {
  font-family: var(--font-mono);
  font-size: 13px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  fill: #FFFFFF;
}
.fb-atom .stage svg .lbl.muted { fill: rgba(255,255,255,0.78); }
.fb-atom .stage svg .core {
  fill: #FFFFFF;
  filter: drop-shadow(0 0 24px rgba(133,160,255,0.6));
  transform-origin: center;
  transform-box: fill-box;
  animation: fbAtomCore 3.6s ease-in-out infinite;
}
.fb-atom .stage svg .core-halo {
  fill: rgba(133,160,255,0.18);
  stroke: none;
  transform-origin: center;
  transform-box: fill-box;
  animation: fbAtomHalo 3.6s ease-in-out infinite;
}
.fb-atom .stage svg .arrow {
  stroke-dasharray: 200;
  stroke-dashoffset: 200;
  animation: fbAtomArrow 4s cubic-bezier(0.22, 1, 0.36, 1) infinite;
}
.fb-atom .stage svg .arrow-r { animation-delay: 0.8s; }
.fb-atom .stage svg .arrow-head { opacity: 0; animation: fbAtomHead 4s ease-in-out infinite 0.6s; }
.fb-atom .stage svg .arrow-head-r { animation-delay: 1.4s; }
@keyframes fbAtomCore {
  0%, 100% { transform: scale(0.95); }
  50% { transform: scale(1.05); }
}
@keyframes fbAtomHalo {
  0%, 100% { transform: scale(1); opacity: 0.4; }
  50% { transform: scale(1.6); opacity: 0.85; }
}
@keyframes fbAtomArrow {
  0%, 10% { stroke-dashoffset: 200; }
  40%, 70% { stroke-dashoffset: 0; }
  100% { stroke-dashoffset: 0; opacity: 0; }
}
@keyframes fbAtomHead {
  0%, 25% { opacity: 0; }
  45%, 75% { opacity: 1; }
  100% { opacity: 0; }
}

/* Chain feature — sequence of decision dots + delay arrow */
.fb-chain .stage svg .node {
  fill: #FFFFFF;
  filter: drop-shadow(0 0 16px rgba(133,160,255,0.5));
  opacity: 0;
  transform-origin: center;
  transform-box: fill-box;
  animation: fbChainLight 6s ease-in-out infinite;
}
.fb-chain .stage svg .node-1 { animation-delay: 0s; }
.fb-chain .stage svg .node-2 { animation-delay: 0.4s; }
.fb-chain .stage svg .node-3 { animation-delay: 0.8s; }
.fb-chain .stage svg .node-4 { animation-delay: 2.2s; }
.fb-chain .stage svg .arrow {
  fill: none;
  stroke: rgba(255,255,255,0.78);
  stroke-width: 1.4;
  stroke-linecap: round;
  stroke-dasharray: 120;
  stroke-dashoffset: 120;
}
.fb-chain .stage svg .arrow.a-1 { animation: fbChainArrow 6s ease-out infinite 0.2s; }
.fb-chain .stage svg .arrow.a-2 { animation: fbChainArrow 6s ease-out infinite 0.6s; }
.fb-chain .stage svg .arrow.a-3 { animation: fbChainArrow 6s ease-out infinite 2.4s; }
.fb-chain .stage svg .result {
  fill: none;
  stroke: #FFFFFF;
  stroke-width: 1.4;
  opacity: 0;
  animation: fbChainResult 6s ease-in-out infinite 2.8s;
}
.fb-chain .stage svg .delay {
  fill: rgba(255,255,255,0.55);
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  opacity: 0;
  animation: fbChainDelayShow 6s ease-in-out infinite 1s;
}
.fb-chain .stage svg .delay-arrow {
  stroke: rgba(255,255,255,0.55);
  stroke-width: 1.2;
  stroke-dasharray: 30;
  stroke-dashoffset: 30;
  animation: fbChainDelayArrow 6s ease-in-out infinite 1.2s;
  fill: none;
}
.fb-chain .stage svg .lbl {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  fill: rgba(255,255,255,0.62);
}
@keyframes fbChainLight {
  0%, 5% { opacity: 0; transform: scale(0.6); }
  18%, 90% { opacity: 1; transform: scale(1); }
  100% { opacity: 0; transform: scale(0.6); }
}
@keyframes fbChainArrow {
  0%, 8% { stroke-dashoffset: 120; }
  18%, 90% { stroke-dashoffset: 0; }
  100% { stroke-dashoffset: 0; opacity: 0; }
}
@keyframes fbChainResult {
  0%, 10% { opacity: 0; transform: scale(0.6); }
  30%, 90% { opacity: 1; transform: scale(1); }
  100% { opacity: 0; }
}
@keyframes fbChainDelayShow {
  0%, 15% { opacity: 0; }
  25%, 50% { opacity: 1; }
  60%, 100% { opacity: 0; }
}
@keyframes fbChainDelayArrow {
  0%, 15% { stroke-dashoffset: 30; }
  25%, 60% { stroke-dashoffset: 0; }
  70%, 100% { stroke-dashoffset: 0; opacity: 0; }
}

/* Entity feature — 4 overlapping circles Venn */
.fb-entity .stage svg .ring {
  fill: none;
  stroke: rgba(255,255,255,0.6);
  stroke-width: 1.2;
  transform-origin: center;
  transform-box: fill-box;
  animation: fbEntityRing 3.6s ease-in-out infinite;
}
.fb-entity .stage svg .ring-2 { animation-delay: 0.2s; }
.fb-entity .stage svg .ring-3 { animation-delay: 0.4s; }
.fb-entity .stage svg .ring-4 { animation-delay: 0.6s; }
.fb-entity .stage svg .outer {
  fill: none;
  stroke: rgba(255,255,255,0.45);
  stroke-width: 1;
}
.fb-entity .stage svg .overlap {
  fill: rgba(133,160,255,0.18);
  stroke: rgba(133,160,255,0.45);
  stroke-width: 0.8;
}
.fb-entity .stage svg .lbl {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  fill: #FFFFFF;
}
.fb-entity .stage svg .overlap-lbl {
  font-family: var(--font-mono);
  font-size: 9px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  fill: rgba(133,160,255,0.95);
}
.fb-entity .stage svg .title-lbl {
  font-family: var(--font-mono);
  font-size: 14px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  fill: #FFFFFF;
}
@keyframes fbEntityRing {
  0%, 100% { transform: scale(0.98); opacity: 0.85; }
  50% { transform: scale(1.02); opacity: 1; }
}

/* Solar System feature — strategy core + 4 orbiting domains */
.fb-solar .stage svg .orbit {
  fill: none;
  stroke: rgba(255,255,255,0.4);
  stroke-width: 1;
  transform-origin: center;
  transform-box: fill-box;
}
.fb-solar .stage svg .o-1 { animation: solarSpin 32s linear infinite; }
.fb-solar .stage svg .o-2 { animation: solarSpin 22s linear infinite reverse; }
.fb-solar .stage svg .o-3 { animation: solarSpin 16s linear infinite; }
.fb-solar .stage svg .o-4 { animation: solarSpin 12s linear infinite reverse; }
.fb-solar .stage svg .planet {
  fill: #FFFFFF;
  stroke: rgba(255,255,255,0.5);
}
.fb-solar .stage svg .sun {
  fill: #FFFFFF;
  filter: drop-shadow(0 0 24px rgba(255,255,255,0.8));
}
.fb-solar .stage svg .lbl {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  fill: #FFFFFF;
}
.fb-solar .stage svg .sun-lbl {
  font-family: var(--font-mono);
  font-size: 13px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  fill: #FFFFFF;
}
.fb-solar .stage svg .star {
  fill: rgba(255,255,255,0.85);
  stroke: none;
}

/* Galaxy feature — multi-cluster spiral drift */
.fb-galaxy .stage svg .ellipse {
  fill: none;
  stroke: rgba(255,255,255,0.55);
  stroke-width: 1.1;
  transform-origin: center;
  transform-box: fill-box;
}
.fb-galaxy .stage svg .core {
  fill: #FFFFFF;
}
.fb-galaxy .stage svg .group { transform-origin: center; transform-box: fill-box; }
.fb-galaxy .stage svg .group.g-1 { animation: galaxyDrift 26s linear infinite; }
.fb-galaxy .stage svg .group.g-2 { animation: galaxyDrift 34s linear infinite reverse; }
.fb-galaxy .stage svg .group.g-3 { animation: galaxyDrift 20s linear infinite; }
.fb-galaxy .stage svg .dust-cloud {
  fill: rgba(132,82,255,0.45);
  stroke: none;
  filter: blur(1px);
  animation: galaxyDustDrift 6s ease-in-out infinite;
}
.fb-galaxy .stage svg .dust-dot { fill: rgba(195,179,255,0.55); }

@media (prefers-reduced-motion: reduce) {
  .feature-block .stage svg *, .lineup .glyph svg * { animation: none !important; }
}
.primitive-card .meta {
  padding: 22px 24px;
  border-right: 1px solid var(--border-subtle);
}
.primitive-card .meta .layer {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--blue-300);
  margin-bottom: 6px;
}
.primitive-card .meta h4 {
  font-size: 22px;
  font-weight: 600;
  letter-spacing: -0.018em;
  margin: 0 0 6px;
  color: var(--fg-default);
}
.primitive-card .meta .sub {
  font-size: 13px;
  color: var(--fg-muted);
  line-height: 1.5;
  margin: 0;
  font-style: italic;
}
.primitive-card .body {
  padding: 22px 24px;
}
.primitive-card .body p {
  font-size: 14px;
  line-height: 1.6;
  color: var(--fg-secondary);
  margin: 0 0 12px;
}
.primitive-card .body p:last-child { margin-bottom: 0; }
.primitive-card .body p .em {
  color: var(--blue-300);
  font-weight: 500;
}
.primitive-card .body .examples {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.04em;
  color: var(--fg-muted);
  border-top: 1px solid var(--border-subtle);
  padding-top: 12px;
  margin-top: 10px;
  display: flex;
  flex-wrap: wrap;
  gap: 4px 18px;
}
.primitive-card .body .examples b {
  color: var(--fg-default);
  font-weight: 500;
  margin-right: 4px;
}

/* Five domains as planets */
.domains-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 12px;
}
@media (max-width: 1000px) { .domains-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px)  { .domains-grid { grid-template-columns: 1fr; } }
.domain-card {
  border: 1px solid var(--border-default);
  border-radius: var(--radius-xl);
  padding: 24px 20px 22px;
  background: rgba(255,255,255,0.02);
  display: flex;
  flex-direction: column;
  gap: 14px;
  position: relative;
  overflow: hidden;
}
.domain-card.sun {
  background:
    radial-gradient(circle at 50% 0%, rgba(225,240,102,0.16), transparent 65%),
    rgba(255,255,255,0.02);
  border-color: rgba(225,240,102,0.28);
}
.domain-card .ico {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: rgba(255,255,255,0.04);
  border: 1px solid var(--border-default);
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
}
.domain-card.sun .ico {
  background: radial-gradient(circle at 30% 30%, #FFFCD7, #E1F066 60%, #948114);
  border-color: rgba(225,240,102,0.5);
}
.domain-card .ico svg { width: 24px; height: 24px; stroke: currentColor; fill: none; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; color: var(--fg-default); }
.domain-card .layer {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--blue-300);
}
.domain-card.sun .layer { color: var(--yellow-300); }
.domain-card h4 {
  font-size: 18px;
  font-weight: 600;
  letter-spacing: -0.012em;
  margin: 0;
  color: var(--fg-default);
}
.domain-card p {
  font-size: 13px;
  color: var(--fg-secondary);
  line-height: 1.55;
  margin: 0;
}
.domain-card .cadence {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--fg-muted);
  border-top: 1px solid var(--border-subtle);
  padding-top: 10px;
  margin-top: auto;
}
.domain-card .cadence b { color: var(--fg-default); font-weight: 500; }

/* Emma at each layer table */
.layer-table {
  border: 1px solid var(--border-default);
  border-radius: var(--radius-xl);
  overflow: hidden;
}
.layer-table .row {
  display: grid;
  grid-template-columns: 200px 1fr;
  padding: 18px 24px;
  border-bottom: 1px solid var(--border-subtle);
  align-items: baseline;
  gap: 24px;
}
.layer-table .row:last-child { border-bottom: 0; }
@media (max-width: 720px) {
  .layer-table .row { grid-template-columns: 1fr; gap: 6px; }
}
.layer-table .row.head {
  background: rgba(255,255,255,0.025);
  padding: 14px 24px;
}
.layer-table .row.head > div {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--fg-muted);
}
.layer-table .k {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--blue-300);
}
.layer-table .v {
  font-size: 15px;
  color: var(--fg-default);
  line-height: 1.55;
}

/* Closing rule banner */
.rule-closing {
  padding: 56px 56px 60px;
  border-radius: var(--radius-2xl);
  background:
    radial-gradient(ellipse 80% 100% at 50% 0%, rgba(47,55,255,0.20), transparent 65%),
    linear-gradient(180deg, #050818, #000000);
  border: 1px solid rgba(133,160,255,0.32);
  position: relative;
  overflow: hidden;
  text-align: center;
  isolation: isolate;
}
.rule-closing::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background-image:
    radial-gradient(circle, rgba(255,255,255,0.55) 0.5px, transparent 0.5px);
  background-size: 180px 180px;
  background-position: 30px 20px;
  opacity: 0.45;
  mask-image: radial-gradient(ellipse 80% 80% at 50% 50%, black, transparent 85%);
}
.rule-closing > * { position: relative; z-index: 1; }
.rule-closing .eye {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.55);
  margin-bottom: 22px;
}
.rule-closing .eye span { color: var(--blue-300); }
.rule-closing h3 {
  font-size: clamp(28px, 3.4vw, 44px);
  letter-spacing: -0.022em;
  line-height: 1.2;
  font-weight: 600;
  margin: 0;
  color: #FFFFFF;
  text-wrap: balance;
  max-width: 26ch;
  margin-inline: auto;
}
.rule-closing h3 em {
  font-style: normal;
  color: var(--blue-300);
}
@media (max-width: 720px) { .rule-closing { padding: 36px 24px 40px; } }
