* {
  box-sizing: border-box;
  min-width: 0;
}

body {
  min-height: 100dvh;
  background:
    radial-gradient(ellipse 70% 60% at 12% 30%, rgba(0,210,255,0.22) 0%, transparent 60%),
    radial-gradient(ellipse 65% 70% at 88% 70%, rgba(138,43,226,0.26) 0%, transparent 60%),
    #020610;
}

/* Fine dot-grid */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  background-image: radial-gradient(circle, rgba(0, 229, 255, 0.07) 1px, transparent 1px);
  background-size: 44px 44px;
  pointer-events: none;
  z-index: -1;
}

h1, h2, h3, h4, h5, h6 {
  text-wrap: balance;
}

p {
  text-wrap: pretty;
  padding-bottom: 1rem;
}

/* ─── Design tokens ─────────────────────────────── */

.gradient-text {
  background: linear-gradient(135deg, #22d3ee 0%, #818cf8 50%, #c084fc 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  color: #0f172a;
  background-color: #0f172a;
}

.gradient-text-cyan {
  background: linear-gradient(135deg, #ecfeff 0%, #67e8f9 50%, #06b6d4 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  color: transparent;
}

/* Glass */
.glass {
  background: rgba(6, 12, 26, 0.75);
  border: 1px solid rgba(255, 255, 255, 0.07);
}

@supports (backdrop-filter: blur(1px)) {
  .glass {
    backdrop-filter: blur(20px) saturate(1.5);
    -webkit-backdrop-filter: blur(20px) saturate(1.5);
    background: rgba(6, 12, 26, 0.6);
  }
}

.neon-border {
  border: 1px solid rgba(0, 229, 255, 0.28);
  box-shadow: 0 0 28px rgba(0, 229, 255, 0.08), inset 0 0 20px rgba(0, 229, 255, 0.03);
}

.neon-border-violet {
  border: 1px solid rgba(124, 58, 237, 0.4);
  box-shadow: 0 0 28px rgba(124, 58, 237, 0.12);
}

/* ─── Scroll-reveal ─────────────────────────────── */

.animate-on-scroll {
  opacity: 0;
  transform: translateY(32px);
  transition: opacity 0.65s ease, transform 0.65s ease;
}

.animate-on-scroll.is-visible {
  opacity: 1;
  transform: translateY(0);
}

/* Stagger delays */
.stagger-children > *:nth-child(1) { transition-delay: 0s; }
.stagger-children > *:nth-child(2) { transition-delay: 0.12s; }
.stagger-children > *:nth-child(3) { transition-delay: 0.24s; }
.stagger-children > *:nth-child(4) { transition-delay: 0.36s; }

/* ─── Glowing ring animations ─────────────────── */

@keyframes ringPulse {
  0%, 100% { opacity: 0.45; transform: scale(1); }
  50%       { opacity: 0.9;  transform: scale(1.02); }
}

@keyframes ringRotate {
  from { transform: rotate(0deg); }
  to   { transform: rotate(360deg); }
}

@keyframes scanLine {
  0%   { top: -2px; opacity: 0; }
  2%   { opacity: 1; }
  46%  { top: 100%; opacity: 1; }
  50%  { top: 100%; opacity: 0; }
  54%  { top: 100%; opacity: 1; }
  98%  { top: -2px; opacity: 1; }
  100% { top: -2px; opacity: 0; }
}

@keyframes scanLineText {
  0%   { top: 0; opacity: 0; }
  2%   { opacity: 1; }
  48%  { top: 100%; opacity: 1; }
  52%  { top: 100%; opacity: 1; }
  98%  { top: 0; opacity: 1; }
  100% { top: 0; opacity: 0; }
}

.hero-scan-line {
  position: absolute;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, transparent 0%, rgba(0,229,255,0.7) 30%, rgba(139,92,246,0.7) 70%, transparent 100%);
  box-shadow: 0 0 20px rgba(0,229,255,0.6), 0 0 40px rgba(0,229,255,0.3);
  will-change: transform;
  animation: scanLine 9s ease-in-out infinite;
  pointer-events: none;
  z-index: 1;
}

.text-scan-line {
  position: relative;
  display: inline-block;
}

.text-scan-line .scan-bar {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 2px;
  background: linear-gradient(90deg, 
    transparent 0%, 
    rgba(0,229,255,0.7) 30%, 
    rgba(139,92,246,0.7) 70%, 
    transparent 100%);
  box-shadow: 0 0 16px rgba(0,229,255,0.6), 0 0 32px rgba(139,92,246,0.3);
  will-change: transform;
  animation: scanLineText 4s linear infinite;
  pointer-events: none;
}

/* ─── Small floating orbs ─────────────────────── */

@keyframes orbFloat1 {
  0%, 100% { transform: translate(0, 0) scale(1); }
  33%       { transform: translate(20px, -18px) scale(1.15); }
  66%       { transform: translate(-12px, 10px) scale(0.9); }
}

@keyframes orbFloat2 {
  0%, 100% { transform: translate(0, 0) scale(1); }
  50%       { transform: translate(-16px, 20px) scale(1.1); }
}

.orb-cyan {
  border-radius: 50%;
  background: radial-gradient(circle, rgba(0,229,255,0.9) 0%, rgba(0,180,255,0.5) 40%, transparent 70%);
  filter: blur(8px);
  animation: orbFloat1 8s ease-in-out infinite;
  pointer-events: none;
}

.orb-violet {
  border-radius: 50%;
  background: radial-gradient(circle, rgba(139,92,246,0.95) 0%, rgba(124,58,237,0.55) 40%, transparent 70%);
  filter: blur(8px);
  animation: orbFloat2 10s ease-in-out infinite;
  pointer-events: none;
}

/* ─── Float animation ─────────────────────────── */
@keyframes float {
  0%, 100% { transform: translateY(0px); }
  50%       { transform: translateY(-16px); }
}

.animate-float { animation: float 6s ease-in-out infinite; }
.animate-pulse-slow { animation: pulse 4s cubic-bezier(0.4, 0, 0.6, 1) infinite; }
@keyframes pulse {
  0%, 100% { opacity: 1; }
  50%       { opacity: 0.25; }
}

/* ─── 3D card hover ─────────────────────────────── */

.card-3d {
  transform-style: preserve-3d;
  transition: transform 0.35s ease, box-shadow 0.35s ease;
}

.card-3d:hover {
  transform: perspective(1000px) rotateX(-4deg) rotateY(4deg) translateY(-10px);
  box-shadow: 0 32px 70px rgba(0, 229, 255, 0.22), 0 0 0 1px rgba(0,229,255,0.15);
}

/* ─── CTA Button variants ─────────────────────── */

.btn-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.85rem 2rem;
  border-radius: 9999px;
  font-weight: 700;
  font-size: 1rem;
  color: white;
  background: linear-gradient(135deg, #06b6d4 0%, #3b82f6 50%, #7c3aed 100%);
  background-size: 200% auto;
  background-position: left center;
  box-shadow: 0 4px 32px rgba(0, 229, 255, 0.45), 0 0 0 1px rgba(0,229,255,0.15);
  transition: background-position 0.45s ease, box-shadow 0.3s ease, transform 0.2s ease;
  text-decoration: none;
  cursor: pointer;
  border: none;
}

.btn-primary:hover {
  background-position: right center;
  box-shadow: 0 6px 50px rgba(0, 229, 255, 0.7), 0 0 0 1px rgba(0,229,255,0.35);
  transform: translateY(-3px);
}

.btn-outline {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.85rem 2rem;
  border-radius: 9999px;
  font-weight: 700;
  font-size: 1rem;
  color: #67e8f9;
  background: transparent;
  border: 1.5px solid rgba(0, 229, 255, 0.45);
  box-shadow: 0 0 20px rgba(0, 229, 255, 0.06);
  transition: all 0.3s ease;
  text-decoration: none;
  cursor: pointer;
}

.btn-outline:hover {
  background: rgba(0, 229, 255, 0.1);
  border-color: rgba(0, 229, 255, 0.8);
  box-shadow: 0 0 35px rgba(0, 229, 255, 0.25);
  transform: translateY(-3px);
}

/* ─── Clip-path section dividers ─────────────── */

.clip-diagonal-top {
  clip-path: polygon(0 5%, 100% 0, 100% 100%, 0 100%);
  margin-top: -2rem;
  padding-top: 5rem;
}

/* ─── Newsletter section ──────────────────────── */
.mc-field-group input,
.mc-field-group label { color: #cbd5e1; }

/* ─── VAPI button ─────────────────────────────── */
.vapi-btn {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 99998;
  width: 50px;
  height: 50px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  border: none;
  padding: 0;
  transition: background 0.3s ease, box-shadow 0.3s ease, opacity 0.3s ease;
}

.vapi-btn img {
  width: 20px;
  height: 20px;
}

@keyframes vapiBounce {
  30% { transform: translateY(0); }
  40% { transform: translateY(-5%); }
  50% { transform: translateY(-10%); }
  60% { transform: translateY(-5%); }
  70% { transform: translateY(0); }
}

/* Idle state - green */
.vapi-btn.idle {
  background: #22C55E;
  box-shadow: 1px 1px 10px #22C55E;
  animation: vapiBounce 2s ease-in-out infinite;
}

.vapi-btn.idle img {
  filter: brightness(0) invert(1);
}

/* Loading state - yellow */
.vapi-btn.loading {
  background: #EAB308;
  box-shadow: 1px 1px 10px #EAB308;
}

.vapi-btn.loading img {
  filter: brightness(0) invert(1);
  animation: spin 1s linear infinite;
}

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

/* Active state - red (in call) */
.vapi-btn.active {
  background: #EF4444;
  box-shadow: 1px 1px 10px #EF4444;
  animation: pulse 1.5s ease-in-out infinite;
}

.vapi-btn.active img {
  filter: brightness(0) invert(1);
}

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

/* Hover effects */
.vapi-btn.idle:hover,
.vapi-btn.active:hover {
  animation: none;
  transform: translateY(-5px);
}
