/* ── How Kama World is made ─────────────────────────────────────────────────
 * The policy page's article (legal.css), widened for the system diagram:
 * four lanes of stage cards, and a state diagram of a piece's life.
 */

.kw-main { max-width: 1040px; }
.kw-main > p,
.kw-main > ul,
.kw-main > h2,
.kw-main > h3,
.kw-main > blockquote,
.kw-main > .kz-legal-summary,
.kw-main > .kz-legal-kicker,
.kw-main > h1,
.kw-main > .kz-legal-updated,
.kw-main > .kw-legend { max-width: 760px; margin-left: auto; margin-right: auto; }

.kw-quote {
  margin: 8px 0 18px;
  padding: 6px 0 6px 22px;
  border-left: 1px solid rgba(216, 163, 94, 0.45);
}
.kw-quote p {
  font-family: 'Instrument Serif', Georgia, serif;
  font-style: italic;
  font-size: clamp(1.15rem, 2vw, 1.35rem);
  line-height: 1.45;
  color: var(--silk);
  margin-bottom: 8px;
}
.kw-quote footer {
  text-align: left;
  font-size: 0.66rem; font-weight: 600;
  letter-spacing: 0.2em; text-transform: uppercase;
  color: var(--candle);
}

/* ── Tags: what is live, and what is on its way ── */
.kw-legend { display: flex; gap: 10px; margin: 18px 0 16px; }
.kw-tag {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 3px 10px;
  border-radius: 999px;
  font-size: 0.64rem; font-weight: 600;
  letter-spacing: 0.08em; text-transform: uppercase;
  white-space: nowrap;
}
.kw-tag::before { content: ''; width: 6px; height: 6px; border-radius: 50%; }
.kw-tag--live { background: rgba(143, 181, 138, 0.14); color: #b9d6b4; }
.kw-tag--live::before { background: #8fb58a; box-shadow: 0 0 8px #8fb58a; }
.kw-tag--soon { border: 1px dashed rgba(216, 163, 94, 0.45); color: var(--candle); }
.kw-tag--soon::before { border: 1px solid var(--candle); width: 5px; height: 5px; }
.kw-tag--inline { margin-left: 6px; vertical-align: 2px; }

/* ── The four lanes ── */
.kw-flow {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 26px;
  margin-top: 8px;
}
.kw-lane { position: relative; display: flex; flex-direction: column; gap: 12px; }
/* The arrow from one lane into the next. */
.kw-lane:not(:last-child)::after {
  content: '';
  position: absolute; top: 12px; right: -20px;
  width: 14px; height: 14px;
  border-top: 1.5px solid var(--candle);
  border-right: 1.5px solid var(--candle);
  transform: rotate(45deg);
  opacity: 0.7;
}
.kw-lane-name {
  display: flex; align-items: center; gap: 10px;
  margin: 0 0 4px !important;
  font-size: 0.72rem !important; font-weight: 600;
  letter-spacing: 0.22em; text-transform: uppercase;
  color: var(--candle) !important;
}
.kw-lane-name span {
  display: inline-grid; place-items: center;
  width: 26px; height: 26px;
  border: 1px solid rgba(216, 163, 94, 0.5);
  border-radius: 50%;
  font-family: 'Instrument Serif', Georgia, serif;
  font-size: 0.95rem; letter-spacing: 0;
  color: var(--silk);
}
.kw-stage {
  padding: 16px 16px 14px;
  border: 1px solid rgba(216, 163, 94, 0.16);
  border-radius: 16px;
  background: linear-gradient(180deg, rgba(42, 18, 28, 0.55), rgba(21, 10, 14, 0.55));
}
.kw-stage h3 { margin: 0 0 6px !important; font-size: 0.92rem !important; }
.kw-stage p,
.kw-stage li { font-size: 0.8rem !important; line-height: 1.55 !important; margin-bottom: 8px !important; }
.kw-stage ul { padding-left: 16px; margin-bottom: 8px; }
.kw-stage li { margin-bottom: 2px !important; }
.kw-stage--gate { border-color: rgba(216, 163, 94, 0.4); box-shadow: 0 0 0 1px rgba(216, 163, 94, 0.08), 0 18px 50px rgba(0, 0, 0, 0.3); }
.kw-stage--human { border-color: rgba(143, 181, 138, 0.35); }
.kw-stage--alert { border-color: rgba(224, 68, 110, 0.4); }
.kw-out {
  padding: 8px 10px;
  border-radius: 10px;
  background: rgba(0, 0, 0, 0.25);
  color: var(--silk) !important;
}
.kw-out b { color: var(--candle); font-weight: 600; }

.kw-loop {
  display: flex; align-items: center; justify-content: center; gap: 10px;
  margin: 18px 0 0 !important;
  padding: 10px;
  border: 1px dashed rgba(216, 163, 94, 0.3);
  border-radius: 999px;
  font-size: 0.8rem !important;
  color: var(--candle) !important;
  max-width: none !important;
}
.kw-loop span { font-size: 1.1rem; }

/* ── The state diagram ── */
.kw-states {
  margin: 14px 0 10px;
  padding: 18px 12px;
  border: 1px solid rgba(216, 163, 94, 0.14);
  border-radius: 18px;
  background: rgba(21, 10, 14, 0.6);
  overflow-x: auto;
}
.kw-states svg { display: block; width: 100%; min-width: 720px; height: auto; }
.kw-edges path { fill: none; stroke: rgba(216, 163, 94, 0.75); stroke-width: 1.5; }
.kw-edges .kw-edge-red { stroke: rgba(224, 68, 110, 0.8); }
.kw-edge-labels text { fill: rgba(244, 233, 228, 0.55); font: 500 11px 'Inter', system-ui, sans-serif; }
.kw-nodes rect { fill: #221019; stroke: rgba(216, 163, 94, 0.55); stroke-width: 1.2; }
.kw-nodes .kw-node-good { fill: rgba(143, 181, 138, 0.16); stroke: #8fb58a; }
.kw-nodes .kw-node-bad  { fill: rgba(224, 68, 110, 0.14); stroke: #e0446e; }
.kw-nodes .kw-node-hold { stroke-dasharray: 4 3; }
.kw-nodes text {
  fill: var(--silk, #f4e9e4);
  font: 500 13px 'Inter', system-ui, sans-serif;
  text-anchor: middle;
}

.kw-specs li { margin-bottom: 12px; }
.kw-cta { margin-top: 24px; }

@media (max-width: 980px) {
  .kw-flow { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .kw-lane:nth-child(2)::after { display: none; }
}
@media (max-width: 620px) {
  .kw-flow { grid-template-columns: minmax(0, 1fr); gap: 30px; }
  .kw-lane::after { display: none; }
  .kw-legend { flex-wrap: wrap; }
}
