/* ============================================
   Hero Section — animated aurora + gradient title
   ============================================ */
.hero {
  position: relative;
  padding: calc(var(--header-height) + var(--space-3xl)) 0 var(--space-4xl);
  overflow: hidden;
  min-height: 560px;
  display: flex;
  align-items: center;
}

/* ── Aurora background (theme-aware) ── */
.hero-bg {
  position: absolute;
  inset: 0;
  z-index: 0;
  overflow: hidden;
  background:
    radial-gradient(110% 90% at 50% -10%, rgba(0,87,184,0.08) 0%, transparent 55%),
    var(--color-bg-primary);
}

/* faint grid overlay */
.hero-bg::before {
  content: '';
  position: absolute;
  inset: -2px;
  background-image:
    linear-gradient(var(--color-border) 1px, transparent 1px),
    linear-gradient(90deg, var(--color-border) 1px, transparent 1px);
  background-size: 48px 48px;
  -webkit-mask-image: radial-gradient(ellipse 80% 70% at 50% 35%, #000 30%, transparent 75%);
          mask-image: radial-gradient(ellipse 80% 70% at 50% 35%, #000 30%, transparent 75%);
  opacity: 0.7;
  pointer-events: none;
}

/* drifting aurora blobs */
.aurora {
  position: absolute;
  border-radius: 50%;
  filter: blur(70px);
  opacity: 0.55;
  pointer-events: none;
  will-change: transform;
}
.aurora-1 { width: 520px; height: 520px; top: -160px; left: -80px;  background: radial-gradient(circle, var(--color-accent-blue), transparent 70%);   animation: aurora-drift-1 22s ease-in-out infinite; }
.aurora-2 { width: 460px; height: 460px; top: -60px;  right: -60px; background: radial-gradient(circle, var(--color-accent-violet), transparent 70%); animation: aurora-drift-2 26s ease-in-out infinite; }
.aurora-3 { width: 420px; height: 420px; bottom: -200px; left: 40%; background: radial-gradient(circle, var(--color-accent-cyan), transparent 70%);   animation: aurora-drift-3 30s ease-in-out infinite; }

[data-theme="light"] .aurora { opacity: 0.32; }

@keyframes aurora-drift-1 {
  0%,100% { transform: translate3d(0,0,0) scale(1); }
  50%     { transform: translate3d(120px,80px,0) scale(1.15); }
}
@keyframes aurora-drift-2 {
  0%,100% { transform: translate3d(0,0,0) scale(1.05); }
  50%     { transform: translate3d(-100px,120px,0) scale(0.9); }
}
@keyframes aurora-drift-3 {
  0%,100% { transform: translate3d(0,0,0) scale(0.95); }
  50%     { transform: translate3d(-140px,-90px,0) scale(1.2); }
}

/* ── Content ── */
.hero-inner {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-3xl);
}

.hero-content {
  flex: 1;
  width: 640px;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  font-weight: var(--font-weight-semibold);
  letter-spacing: 0.12em;
  color: var(--color-text-primary);
  padding: 7px 16px;
  border-radius: var(--radius-full);
  background: var(--grad-brand-soft);
  border: 1px solid var(--color-border-strong);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  margin-bottom: var(--space-lg);
}
.hero-badge::before {
  content: '';
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--color-signal);
  box-shadow: 0 0 12px var(--color-signal);
  animation: badge-pulse 2.4s ease-in-out infinite;
}
@keyframes badge-pulse { 0%,100% { opacity: 1; } 50% { opacity: 0.35; } }

.hero-title {
  font-family: var(--font-family-head);
  font-size: clamp(38px, 5vw, 64px);
  font-weight: var(--font-weight-bold);
  line-height: 1.1;
  letter-spacing: -0.02em;
  margin-bottom: var(--space-lg);
  width: 100%;
  text-align: left;
  /* reserve 3 lines so typewriter phrase changes never reflow layout */
  min-height: calc(1.1em * 3);
  background: linear-gradient(120deg, var(--color-text-primary) 0%, var(--color-accent-cyan) 55%, var(--color-accent-violet) 100%);
  -webkit-background-clip: text;
          background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;
}

.typewriter-cursor {
  display: inline-block;
  font-weight: 300;
  -webkit-text-fill-color: var(--color-accent-cyan);
  color: var(--color-accent-cyan);
  animation: blink .8s step-end infinite;
  margin-left: 2px;
}
@keyframes blink { 50% { opacity: 0; } }

.hero-description {
  font-size: var(--font-size-sm);
  color: var(--color-text-secondary);
  line-height: var(--line-height-relaxed);
  max-width: 540px;
}

/* ── Illustration ── */
.hero-illustration {
  flex-shrink: 0;
  width: 460px;
  height: 460px;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
}
.hero-illustration::before {
  content: '';
  position: absolute;
  inset: 8%;
  border-radius: 50%;
  background: var(--grad-brand-soft);
  filter: blur(40px);
  z-index: -1;
  animation: aurora-drift-2 18s ease-in-out infinite;
}
.hero-illustration img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
}
.parallax-layer { will-change: transform; }

@media (prefers-reduced-motion: reduce) {
  .aurora, .hero-illustration::before, .hero-badge::before { animation: none; }
}

@media (max-width: 900px) {
  .hero-inner { flex-direction: column; text-align: center; }
  .hero-illustration { width: 320px; height: 320px; }
  .hero-description { margin-inline: auto; }
}
