/* Hero demo — Q&A insight card */
.hero-demo {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  max-width: 520px;
  margin: 0 auto;
  padding: 8px 0;
}

.demo-ambient {
  position: absolute;
  inset: 10% 0;
  background: radial-gradient(
    ellipse 80% 70% at 50% 45%,
    rgba(111, 231, 200, 0.14) 0%,
    transparent 65%
  );
  filter: blur(24px);
  pointer-events: none;
  animation: demo-glow 8s ease-in-out infinite;
}

@keyframes demo-glow {
  0%,
  100% {
    opacity: 0.7;
    transform: scale(1);
  }
  50% {
    opacity: 1;
    transform: scale(1.04);
  }
}

.insight-card {
  --card-height: 548px;
  --query-slot: 5.75rem;
  --answer-slot: 13.75rem;

  position: relative;
  display: flex;
  flex-direction: column;
  width: 100%;
  height: var(--card-height);
  min-height: var(--card-height);
  max-height: var(--card-height);
  padding: 28px 28px 24px;
  box-sizing: border-box;
  background: linear-gradient(
    165deg,
    rgba(255, 255, 255, 0.07) 0%,
    rgba(255, 255, 255, 0.02) 40%,
    rgba(0, 0, 0, 0.2) 100%
  );
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 24px;
  box-shadow:
    0 0 0 1px rgba(111, 231, 200, 0.06) inset,
    0 32px 80px -24px rgba(0, 0, 0, 0.65),
    0 0 48px -12px rgba(111, 231, 200, 0.12);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  cursor: pointer;
  transition: border-color 0.25s ease, box-shadow 0.25s ease, transform 0.25s ease;
}

.insight-card:hover {
  border-color: rgba(111, 231, 200, 0.22);
  box-shadow:
    0 0 0 1px rgba(111, 231, 200, 0.1) inset,
    0 40px 90px -20px rgba(0, 0, 0, 0.7),
    0 0 56px -8px rgba(111, 231, 200, 0.18);
  transform: translateY(-2px);
}

.insight-card__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 24px;
}

.insight-card__segment {
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: var(--text-primary);
}

.insight-card__badge {
  padding: 5px 10px;
  font-size: 0.6875rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: var(--mint);
  background: rgba(111, 231, 200, 0.1);
  border: 1px solid rgba(111, 231, 200, 0.22);
  border-radius: 999px;
}

.insight-card__block--ask {
  margin-bottom: 0;
}

.insight-card__label {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 10px;
  font-size: 0.6875rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.insight-card__label svg {
  width: 14px;
  height: 14px;
  color: var(--mint);
}

.insight-card__query {
  margin: 0;
  min-height: var(--query-slot);
  max-height: var(--query-slot);
  overflow: hidden;
  font-size: 1.25rem;
  font-weight: 500;
  line-height: 1.45;
  letter-spacing: -0.02em;
  color: var(--text-primary);
}

.insight-card__bridge {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 22px 0;
  height: 28px;
}

.insight-card__bridge-line {
  position: absolute;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(111, 231, 200, 0.35) 30%,
    rgba(111, 231, 200, 0.35) 70%,
    transparent
  );
}

.insight-card__bridge-icon {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  color: var(--mint);
  background: var(--bg-secondary);
  border: 1px solid rgba(111, 231, 200, 0.25);
  border-radius: 50%;
  box-shadow: 0 0 20px rgba(111, 231, 200, 0.2);
}

.insight-card__bridge-icon svg {
  width: 14px;
  height: 14px;
}

.insight-card__block--answer {
  flex: 1;
  min-height: 0;
  padding: 20px 20px 18px;
  background: rgba(111, 231, 200, 0.04);
  border: 1px solid rgba(111, 231, 200, 0.12);
  border-radius: 16px;
  border-left: 3px solid var(--mint);
}

.insight-card__answer {
  margin: 0;
  min-height: var(--answer-slot);
  max-height: var(--answer-slot);
  overflow: hidden;
  font-size: 1.0625rem;
  line-height: 1.55;
  color: var(--text-primary);
}

.insight-card__answer strong {
  color: var(--text-primary);
  font-weight: 600;
}

.insight-card__footer {
  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: auto;
  padding-top: 20px;
  flex-shrink: 0;
}

.insight-card__dots {
  display: flex;
  gap: 8px;
}

.demo-dot {
  width: 8px;
  height: 8px;
  padding: 0;
  border: none;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.15);
  cursor: pointer;
  transition: background 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
}

.demo-dot:hover {
  background: rgba(111, 231, 200, 0.45);
}

.demo-dot[aria-selected="true"] {
  background: var(--mint);
  box-shadow: 0 0 12px var(--mint-glow);
  transform: scale(1.15);
}

/* Transitions */
.insight-card.is-transitioning .insight-card__query,
.insight-card.is-transitioning .insight-card__answer {
  opacity: 0;
  transform: translateY(8px);
}

.insight-card__query,
.insight-card__answer {
  transition: opacity 0.35s ease, transform 0.35s ease;
}

@media (prefers-reduced-motion: reduce) {
  .demo-ambient {
    animation: none;
  }

  .insight-card:hover {
    transform: none;
  }
}

@media (max-width: 960px) {
  .hero-demo {
    max-width: none;
  }

  .insight-card {
    height: auto;
    min-height: unset;
    max-height: none;
  }

  .insight-card__query,
  .insight-card__answer {
    max-height: none;
    overflow: visible;
  }
}

@media (max-width: 640px) {
  .insight-card {
    padding: 22px 20px 20px;
  }

  .insight-card__header {
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
  }

  .insight-card__query {
    font-size: 1.125rem;
  }
}
