/* Base */
:root {
  --bg: #05060c;
  --panel: rgba(255, 255, 255, 0.07);
  --panel-strong: rgba(255, 255, 255, 0.12);
  --text: #f4f4f8;
  --muted: #c7cad4;
  --accent: #6dd3ff;
  --accent-2: #c9a0ff;
  --accent-3: #3ef3c2;
  --shadow: 0 20px 70px rgba(0, 0, 0, 0.45);
  --radius: 18px;
  --radius-small: 12px;
  --blur: 18px;
  --speed: 220ms;
  --font-heading: "Space Grotesk", "Sora", sans-serif;
  --font-body: "Sora", "Space Grotesk", sans-serif;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--text);
  background: radial-gradient(circle at 20% 20%, #0c1220, #05060c 40%),
              radial-gradient(circle at 80% 10%, #0d101c, transparent 35%),
              #05060c;
  font-family: var(--font-body);
  -webkit-font-smoothing: antialiased;
}

a {
  color: var(--muted);
  text-decoration: none;
  transition: color var(--speed) ease;
}

a:hover {
  color: var(--text);
}

button,
input,
textarea {
  font-family: var(--font-body);
}

.shell {
  width: min(1180px, 92vw);
  margin: 0 auto;
}

.bg-aurora {
  position: fixed;
  inset: 0;
  background: radial-gradient(48% 48% at 20% 20%, rgba(108, 223, 255, 0.18), transparent 60%),
              radial-gradient(50% 50% at 80% 0%, rgba(179, 112, 255, 0.16), transparent 60%),
              radial-gradient(70% 70% at 60% 70%, rgba(62, 243, 194, 0.12), transparent 70%);
  filter: blur(0);
  z-index: -2;
  animation: drift 16s ease-in-out infinite alternate;
}

.bg-aurora.second {
  animation-delay: 4s;
  opacity: 0.6;
}

@keyframes drift {
  from { transform: translate3d(-10px, 6px, 0) scale(1); }
  to { transform: translate3d(12px, -4px, 0) scale(1.04); }
}

/* Header */
.header {
  padding: 22px 0 10px;
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 18px;
  position: sticky;
  top: 0;
  z-index: 10;
  backdrop-filter: blur(var(--blur));
}

.brand {
  display: grid;
  grid-template-columns: auto auto;
  gap: 10px;
  align-items: center;
}

.logo {
  width: 44px;
  height: 44px;
  border-radius: 14px;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  display: grid;
  place-items: center;
  font-size: 20px;
  color: #05060c;
  font-weight: 700;
  box-shadow: var(--shadow);
}

.brand-title {
  font-weight: 700;
  letter-spacing: -0.5px;
  font-size: 18px;
  font-family: var(--font-heading);
}

.brand-sub {
  color: var(--muted);
  font-size: 13px;
}

.nav {
  display: flex;
  gap: 18px;
  justify-content: center;
}

.nav a {
  padding: 10px 12px;
  border-radius: var(--radius-small);
  background: transparent;
}

.nav a:hover {
  background: rgba(255, 255, 255, 0.06);
}

.header-actions {
  display: flex;
  gap: 10px;
  align-items: center;
}

/* Buttons */
button {
  border: none;
  border-radius: var(--radius-small);
  padding: 12px 18px;
  cursor: pointer;
  font-weight: 600;
  letter-spacing: -0.1px;
  transition: transform var(--speed) ease, box-shadow var(--speed) ease, opacity var(--speed) ease;
}

button:hover {
  transform: translateY(-1px);
}

button:active {
  transform: translateY(0);
}

.primary {
  background: linear-gradient(120deg, var(--accent), var(--accent-2));
  color: #05060c;
  box-shadow: 0 15px 40px rgba(109, 211, 255, 0.32);
}

.secondary {
  background: linear-gradient(120deg, rgba(201, 160, 255, 0.25), rgba(62, 243, 194, 0.25));
  color: var(--text);
  border: 1px solid rgba(255, 255, 255, 0.14);
  box-shadow: 0 15px 30px rgba(0, 0, 0, 0.25);
}

.ghost {
  background: rgba(255, 255, 255, 0.08);
  color: var(--text);
  border: 1px solid rgba(255, 255, 255, 0.12);
}

.ghost.small,
.secondary.small,
.primary.small {
  padding: 8px 12px;
  font-size: 13px;
}

.ghosted {
  border: 1px solid rgba(255, 255, 255, 0.25);
}

.full {
  width: 100%;
}

/* Hero */
.hero {
  padding: 40px 0 10px;
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 28px;
  align-items: stretch;
}

.hero-text,
.hero-panel {
  min-height: 100%;
}

.hero-text,
.hero-panel {
  display: flex;
  flex-direction: column;
}

.hero-text h1 {
  font-size: clamp(32px, 4vw, 44px);
  line-height: 1.15;
  letter-spacing: -1px;
  margin: 10px 0 8px;
  font-family: var(--font-heading);
}

.lede {
  color: var(--muted);
  font-size: 16px;
  line-height: 1.6;
}

.lede.small {
  font-size: 15px;
}

.hero-actions {
  display: flex;
  gap: 12px;
  margin: 18px 0;
  flex-wrap: wrap;
}

.hero-meta {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.meta-chip {
  background: rgba(255, 255, 255, 0.08);
  padding: 10px 12px;
  border-radius: var(--radius-small);
  color: var(--muted);
  font-size: 14px;
}

.hero-panel {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: var(--radius);
  padding: 18px;
  box-shadow: var(--shadow);
  backdrop-filter: blur(var(--blur));
  overflow: hidden;
  transition: max-height 0.4s ease, padding 0.4s ease;
}

.hero-panel.collapsed {
  max-height: 220px;
  padding-bottom: 0;
  overflow: hidden;
}

.collapse-toggle {
  display: flex;
  justify-content: center;
  margin-top: 10px;
}

.collapse-toggle .arrow {
  display: inline-block;
  transition: transform 0.3s ease;
}

.hero-panel.expanded .collapse-toggle .arrow {
  transform: rotate(180deg);
}

.panel-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.panel-title {
  font-size: 18px;
  margin: 6px 0 0;
}

.panel-body {
  display: grid;
  gap: 12px;
  margin: 14px 0;
}

.inline-card {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 14px;
  background: var(--panel);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: var(--radius-small);
}

.card-title {
  margin: 4px 0 0;
  font-weight: 600;
}

.badge {
  padding: 6px 10px;
  border-radius: 12px;
  background: linear-gradient(120deg, rgba(109, 211, 255, 0.35), rgba(201, 160, 255, 0.35));
  color: var(--text);
  font-size: 12px;
  border: 1px solid rgba(255, 255, 255, 0.15);
}

.badge.soft {
  background: rgba(255, 255, 255, 0.07);
}

.ai-preview {
  padding: 14px;
  border-radius: var(--radius-small);
  background: linear-gradient(145deg, rgba(109, 211, 255, 0.12), rgba(201, 160, 255, 0.12));
}

.ai-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.ai-line {
  margin: 10px 0 12px;
  color: var(--text);
  line-height: 1.4;
}

.spark {
  font-size: 14px;
}

.panel-foot {
  color: var(--muted);
  font-size: 13px;
  margin: 6px 0 0;
}

.pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 10px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  color: var(--muted);
  font-size: 13px;
}

.pill.subtle {
  background: rgba(255, 255, 255, 0.05);
}

.micro {
  margin: 0;
  color: var(--muted);
  font-size: 12px;
  letter-spacing: 0.2px;
}

.section {
  padding: 50px 0 10px;
}

.systems-banner {
  padding-top: 20px;
}

.systems-wrap {
  position: relative;
  overflow: hidden;
  padding: 22px;
  border-radius: calc(var(--radius) + 6px);
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: linear-gradient(135deg, rgba(109, 211, 255, 0.08), rgba(201, 160, 255, 0.08));
  box-shadow: var(--shadow);
}

.systems-wrap::before,
.systems-wrap::after {
  content: "";
  position: absolute;
  width: 240px;
  height: 240px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.1), transparent 55%);
  filter: blur(20px);
  opacity: 0.35;
}

.systems-wrap::before {
  top: -80px;
  right: -60px;
}

.systems-wrap::after {
  bottom: -120px;
  left: -80px;
}

.systems-grid {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 1.05fr 1fr;
  gap: 18px;
  align-items: stretch;
}

.systems-copy {
  display: grid;
  gap: 12px;
  align-content: flex-start;
}

.systems-copy h2 {
  margin: 4px 0 6px;
  font-size: 28px;
  letter-spacing: -0.6px;
}

.data-chips {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 2px;
}

.chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 12px;
  background: rgba(5, 6, 12, 0.3);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 999px;
  color: var(--text);
  font-size: 14px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.25);
  animation: slideChip 6s ease-in-out infinite;
}

.chip:nth-child(2) { animation-delay: 0.2s; }
.chip:nth-child(3) { animation-delay: 0.4s; }

.systems-visuals {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 14px;
}

.systems-wrap.compact {
  padding: 18px;
}

.systems-head {
  display: grid;
  gap: 10px;
  margin-bottom: 18px;
}

.systems-visuals.compact {
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
}

.demo-card {
  background: rgba(5, 6, 12, 0.45);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: var(--radius);
  padding: 16px;
  position: relative;
  overflow: hidden;
  box-shadow: var(--shadow);
}

.demo-card::after {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 70% 10%, rgba(109, 211, 255, 0.08), transparent 55%);
  pointer-events: none;
}

.demo-card .demo-head h3 {
  margin: 4px 0 0;
}

.destiny-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 6px;
  margin: 12px 0;
}

.matrix-frame {
  position: relative;
  margin: 12px 0;
  border-radius: 14px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.12);
  box-shadow: var(--shadow);
}

.matrix-frame canvas {
  width: 100%;
  height: auto;
  aspect-ratio: 1 / 1;
  display: block;
}

.matrix-node.active text.value {
  fill: #ffffff;
  font-weight: 700;
}

.matrix-number {
  position: absolute;
  top: 12px;
  right: 12px;
  padding: 8px 12px;
  background: rgba(5, 6, 12, 0.72);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 12px;
  font-weight: 700;
  letter-spacing: 0.4px;
  color: var(--text);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.35);
}

.matrix-legend {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 8px;
  margin-top: 6px;
}

.legend-chip {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 10px;
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.03);
  color: var(--muted);
  font-size: 13px;
  transition: border var(--speed) ease, background var(--speed) ease, color var(--speed) ease;
}

.legend-chip .dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  border: 1px solid rgba(0,0,0,0.25);
  flex-shrink: 0;
}

.legend-chip.active {
  border-color: rgba(255, 255, 255, 0.3);
  background: rgba(255, 255, 255, 0.07);
  color: var(--text);
}

.bodygraph-wrap {
  display: grid;
  grid-template-columns: auto;
  justify-items: center;
  align-items: center;
  gap: 10px;
  margin: 10px 0;
}

.bodygraph-embed {
  width: 100%;
  max-width: 520px;
  aspect-ratio: 9 / 13;
  border-radius: 16px;
  overflow: hidden;
  background: transparent;
  box-shadow: none;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 8px;
}

.bodygraph-embed svg {
  width: 100%;
  height: auto;
  max-height: 720px;
  background: transparent;
  display: block;
}

.bodygraph-embed path {
  stroke: rgba(255, 255, 255, 0.9);
  stroke-width: 3;
  fill: none;
  stroke-dasharray: 2400;
  stroke-dashoffset: 2400;
  animation: drawSvg 10s ease-in-out infinite;
  transition: stroke-dasharray 1s ease, stroke-dashoffset 1s ease, opacity 0.8s ease, stroke 0.6s ease;
}

.bodygraph-embed g[id] path {
  stroke: #ffffff;
  stroke-width: 2.6;
  fill: rgba(255, 255, 255, 0.32);
}

.bodygraph-embed path[id*="\\-"] {
  stroke: rgba(255, 255, 255, 0.95);
  stroke-width: 3;
}
.bodygraph-embed .channel-red {
  filter: drop-shadow(0 0 10px rgba(255, 107, 107, 0.85));
}

/* Центры — ближе к палитре приложения */
.bodygraph-embed g#head path { fill: rgba(255, 255, 255, 0.44); stroke: #ffffff; }
.bodygraph-embed g#ajna path { fill: rgba(255, 255, 255, 0.4); stroke: #ffffff; }
.bodygraph-embed g#throat path { fill: rgba(255, 255, 255, 0.4); stroke: #ffffff; }
.bodygraph-embed g#g path { fill: rgba(255, 255, 255, 0.4); stroke: #ffffff; }
.bodygraph-embed g#sacral path { fill: rgba(255, 255, 255, 0.4); stroke: #ffffff; }
.bodygraph-embed g#root path { fill: rgba(255, 255, 255, 0.36); stroke: #ffffff; }
.bodygraph-embed g#spleen path { fill: rgba(255, 255, 255, 0.36); stroke: #ffffff; }
.bodygraph-embed g#solar path { fill: rgba(255, 255, 255, 0.36); stroke: #ffffff; }
.bodygraph-embed g#ego path { fill: rgba(255, 255, 255, 0.36); stroke: #ffffff; }

.bodygraph-embed text {
  fill: #ffffff !important;
  font-weight: 700;
  font-size: 22px;
}

.bodygraph-legend {
  width: 100%;
  max-width: 360px;
  display: grid;
  gap: 6px;
}

.legend-line {
  display: flex;
  justify-content: space-between;
  font-size: 14px;
  color: var(--text);
  padding: 8px 10px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 10px;
}

.legend-line.small {
  font-size: 13px;
  color: var(--muted);
}

@keyframes cellPulse {
  0%, 15% { transform: scale(0.96); box-shadow: 0 0 0 0 rgba(109, 211, 255, 0); }
  25%, 55% { transform: scale(1); box-shadow: 0 6px 22px rgba(109, 211, 255, 0.24); }
  80%, 100% { transform: scale(0.98); box-shadow: 0 0 0 0 rgba(109, 211, 255, 0); }
}

@keyframes fillBar {
  0% { width: 0%; }
  30% { width: 42%; }
  60% { width: 86%; }
  90%, 100% { width: 100%; }
}

@keyframes slideChip {
  0%, 15% { transform: translateY(6px); opacity: 0.4; }
  25%, 70% { transform: translateY(0); opacity: 1; }
  100% { transform: translateY(4px); opacity: 0.6; }
}

@keyframes drawSvg {
  0%, 10% { stroke-dashoffset: 1400; opacity: 0.35; }
  35%, 70% { stroke-dashoffset: 0; opacity: 0.95; }
  100% { stroke-dashoffset: 1400; opacity: 0.4; }
}

@keyframes slowPulse {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.01); }
}

.section-head {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  align-items: flex-start;
  margin-bottom: 18px;
}

.section-head-actions {
  display: flex;
  gap: 10px;
}

.grid {
  display: grid;
  gap: 18px;
}

.grid.three {
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
}

.grid.two {
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
}

.chart-wrap {
  margin-top: 18px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 18px;
}

.wheel-holder {
  width: 100%;
  aspect-ratio: 1 / 1;
  background: radial-gradient(circle at 50% 50%, rgba(255, 255, 255, 0.04), transparent 55%);
  border-radius: var(--radius);
  border: 1px solid rgba(255, 255, 255, 0.06);
  display: grid;
  place-items: center;
}

#natalWheel {
  width: 100%;
  height: 100%;
}

.card,
.ai-card,
.natal-card {
  padding: 18px;
  background: var(--panel);
  border-radius: var(--radius);
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: var(--shadow);
}

.natal-card.collapsed .chart-wrap,
.natal-card.collapsed .result {
  display: none;
}

.natal-card.collapsed .card-head {
  opacity: 0;
  height: 0;
  overflow: hidden;
}

.natal-card.collapsed .natal-hint {
  padding: 12px;
  background: rgba(255, 255, 255, 0.04);
  border-radius: var(--radius-small);
  margin-bottom: 12px;
  color: var(--muted);
}

.natal-card.expanded .natal-hint {
  display: none;
}

.card-head,
.ai-card header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
}

.card h3,
.ai-card h3 {
  margin: 4px 0 0;
  font-size: 20px;
}

h4 {
  margin: 12px 0 6px;
  font-size: 16px;
  font-weight: 600;
}

.stack {
  display: grid;
  gap: 10px;
  margin: 12px 0;
}

.stack.duo {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.align-end {
  align-items: end;
}

.tz-row {
  display: flex;
  align-items: flex-end;
  gap: 8px;
}

label {
  color: var(--muted);
  font-size: 14px;
  display: grid;
  gap: 6px;
}

input,
textarea {
  width: 100%;
  padding: 12px 12px;
  border-radius: var(--radius-small);
  border: 1px solid rgba(255, 255, 255, 0.16);
  background: rgba(255, 255, 255, 0.04);
  color: var(--text);
  outline: none;
  transition: border var(--speed) ease, background var(--speed) ease;
}

select {
  width: 100%;
  padding: 12px 12px;
  border-radius: var(--radius-small);
  border: 1px solid rgba(255, 255, 255, 0.16);
  background: rgba(255, 255, 255, 0.08);
  color: var(--text);
}

input:focus,
textarea:focus {
  border-color: var(--accent);
  background: rgba(255, 255, 255, 0.07);
}

textarea {
  resize: vertical;
  min-height: 90px;
}

.result,
.ai-result {
  color: var(--muted);
  font-size: 14px;
  line-height: 1.5;
  padding: 12px;
  border-radius: var(--radius-small);
  background: rgba(255, 255, 255, 0.04);
  border: 1px dashed rgba(255, 255, 255, 0.14);
}

.summary-grid {
  display: grid;
  gap: 10px;
}

.summary-row {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  border-bottom: 1px dashed rgba(255, 255, 255, 0.08);
  padding: 4px 0;
}

.summary-row:last-child {
  border-bottom: none;
}

.tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 999px;
  padding: 4px 9px;
  font-size: 12px;
  color: var(--text);
}

.ai-actions {
  display: flex;
  gap: 10px;
  align-items: center;
  flex-wrap: wrap;
  margin: 12px 0 6px;
}

.ai-card button {
  min-width: 140px;
}

.ai-card .ghost.full {
  margin: 8px 0;
}

.ai-card {
  position: relative;
  overflow: hidden;
}

.geocode-block {
  display: grid;
  gap: 6px;
}

.chart-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

/* Live AI cards — glow border */
.ai-card.ai-live {
  border-color: rgba(109, 211, 255, 0.35);
  background: linear-gradient(145deg, rgba(109, 211, 255, 0.06), var(--panel));
}

.ai-card.ai-live::after {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 80% 20%, rgba(109, 211, 255, 0.12), transparent 40%);
  pointer-events: none;
}

.badge.live {
  background: linear-gradient(120deg, rgba(62, 243, 194, 0.45), rgba(109, 211, 255, 0.45));
  color: #fff;
  font-weight: 700;
}

/* Promo cards — dimmed, with overlay */
.ai-card.ai-promo {
  position: relative;
  border-color: rgba(255, 255, 255, 0.06);
  background: rgba(255, 255, 255, 0.03);
}

.ai-card.ai-promo::after {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 50% 50%, rgba(201, 160, 255, 0.05), transparent 60%);
  pointer-events: none;
}

.ai-card.ai-promo header,
.ai-card.ai-promo .promo-desc {
  opacity: 0.7;
}

.promo-overlay {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  background: rgba(5, 6, 12, 0.55);
  backdrop-filter: blur(2px);
  border-radius: var(--radius);
  opacity: 0;
  transition: opacity var(--speed) ease;
}

.ai-card.ai-promo:hover .promo-overlay {
  opacity: 1;
}

.promo-label {
  color: var(--accent-2);
  font-weight: 600;
  font-size: 15px;
  letter-spacing: -0.2px;
}

.promo-cta {
  z-index: 3;
}

.badge.promo {
  background: rgba(201, 160, 255, 0.2);
  color: var(--accent-2);
  border-color: rgba(201, 160, 255, 0.25);
}

.promo-desc {
  color: var(--muted);
  font-size: 14px;
  line-height: 1.5;
  margin: 10px 0 0;
}

/* Loading state for live cards */
.ai-result.loading {
  opacity: 0.6;
  position: relative;
}

.ai-result.loading::after {
  content: "";
  display: inline-block;
  width: 14px;
  height: 14px;
  border: 2px solid var(--accent);
  border-top-color: transparent;
  border-radius: 50%;
  animation: spin 0.6s linear infinite;
  margin-left: 8px;
  vertical-align: middle;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

.cta {
  padding: 70px 0;
}

.cta-card {
  background: linear-gradient(145deg, rgba(109, 211, 255, 0.08), rgba(201, 160, 255, 0.1));
  border: 1px solid rgba(255, 255, 255, 0.12);
  padding: 24px;
  border-radius: calc(var(--radius) + 4px);
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 18px;
  align-items: center;
  box-shadow: var(--shadow);
}

.cta-badge {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.14);
  padding: 12px 16px;
  border-radius: var(--radius-small);
  text-align: center;
}

.badge-title {
  margin: 0;
  font-size: 28px;
  font-weight: 700;
}

.footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 30px 0 40px;
  color: var(--muted);
  font-size: 14px;
}

.footer-links {
  display: flex;
  gap: 14px;
}

.section .card,
.ai-card {
  backdrop-filter: blur(calc(var(--blur) - 4px));
}

.section-head h2 {
  margin: 6px 0 6px;
  font-size: 28px;
  letter-spacing: -0.6px;
}

.section-head .pill {
  margin-bottom: 6px;
}

.section-head .lede {
  margin-top: 4px;
}

.ghost:disabled,
.primary:disabled,
.secondary:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

.modal {
  position: fixed;
  inset: 0;
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 20;
}

.modal.active {
  display: flex;
}

.modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.45);
  backdrop-filter: blur(10px);
}

.modal-body {
  position: relative;
  background: rgba(12, 14, 26, 0.95);
  border: 1px solid rgba(255, 255, 255, 0.12);
  padding: 22px;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  width: min(420px, 90vw);
  z-index: 1;
}

.modal-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
}

.modal-result {
  margin-top: 12px;
  color: var(--muted);
}

.pulse {
  animation: pulse 1.2s ease;
}

@keyframes pulse {
  0% { box-shadow: 0 0 0 0 rgba(109, 211, 255, 0.5); }
  70% { box-shadow: 0 0 0 16px rgba(109, 211, 255, 0); }
  100% { box-shadow: 0 0 0 0 rgba(109, 211, 255, 0); }
}

.muted {
  color: var(--muted);
}

/* Responsive */
@media (max-width: 960px) {
  .header {
    grid-template-columns: 1fr;
    grid-template-rows: auto auto auto;
    gap: 12px;
  }

  .nav {
    justify-content: flex-start;
  }

  .hero {
    grid-template-columns: 1fr;
  }

  .cta-card {
    grid-template-columns: 1fr;
  }

  .stack.duo {
    grid-template-columns: 1fr;
  }

  .chart-wrap {
    grid-template-columns: 1fr;
  }

  .systems-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 600px) {
  .header-actions {
    flex-wrap: wrap;
  }

  .hero-actions {
    flex-direction: column;
  }

  .ai-actions {
    flex-direction: column;
    align-items: stretch;
  }
}
