/*
|--------------------------------------------------------------------------
| Hero
|--------------------------------------------------------------------------
*/
.cf-hero {
  min-height: calc(100vh - var(--cf-size-hero-offset));
  display: flex;
  align-items: center;
  background: var(--cf-color-surface-alt);
}
.cf-hero-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 5rem;
  align-items: center;
}
.cf-hero-content {
  max-width: var(--cf-size-hero-max-width);
}
.cf-hero-label {
  display: inline-flex;
  margin-bottom: 1rem;
  color: var(--cf-color-primary);
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.cf-hero p {
  font-size: 1.125rem;
  color: var(--cf-color-text-muted-strong);
  margin-bottom: 2rem;
}
.cf-hero-buttons {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
}
.cf-hero-visual {
  display: flex;
  justify-content: center;
}
.cf-hero-stage {
  width: 100%;
  max-width: var(--cf-size-hero-max-width);
  aspect-ratio: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}
.cf-three-placeholder {
  width: 85%;
  height: 85%;
  border-radius: var(--cf-radius-card);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--cf-color-text-muted);
  font-size: 1.25rem;
  font-weight: 600;
}
@media (max-width: 61.9375rem) {
  .cf-hero {
    padding: 4rem 0;
  }
  .cf-hero-grid {
    grid-template-columns: 1fr;
    gap: 3rem;
  }
  .cf-hero-content {
    max-width: 100%;
    text-align: center;
  }
  .cf-hero-buttons {
    justify-content: center;
  }
}
/*
|--------------------------------------------------------------------------
| Three.js Hero Scene
|--------------------------------------------------------------------------
*/
.cf-three-scene {
  position: relative;
  width: 100%;
  height: 100%;
  min-height: 32rem;
  overflow: hidden;
  border-radius: var(--cf-radius-hero);
  background: linear-gradient(
    145deg,
    color-mix(in srgb, var(--cf-color-background) 98%, transparent),
    var(--cf-color-surface)
  );
  box-shadow: var(--cf-shadow-lg);
}
.cf-three-canvas {
  display: block;
  width: 100%;
  height: 100%;
}
/*
|--------------------------------------------------------------------------
| Scene Overlay
|--------------------------------------------------------------------------
*/
.cf-three-scene::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: radial-gradient(circle at 50% 45%, rgba(255, 255, 255, 0.25), transparent 55%);
}
/*
|--------------------------------------------------------------------------
| Mobile
|--------------------------------------------------------------------------
*/
@media (max-width: 48rem) {
  .cf-three-scene {
    min-height: 24rem;
  }
}
.cf-three-placeholder {
  position: relative;
  width: 100%;
  height: 100%;
  min-height: 32rem;
  overflow: hidden;
}
.cf-three-canvas {
  display: block;
  width: 100%;
  height: 100%;
}
@media (max-width: 64rem) {
  .cf-three-placeholder {
    min-height: 28rem;
  }
}
@media (max-width: 48rem) {
  .cf-three-placeholder {
    min-height: 24rem;
  }
}
@media (prefers-reduced-motion: reduce) {
  .cf-three-canvas {
    animation: none;
  }
}
/*
|--------------------------------------------------------------------------
| Three.js Loading / Fallback
|--------------------------------------------------------------------------
*/
.cf-three-placeholder {
  position: relative;
  width: 100%;
  height: 100%;
  min-height: 32rem;
  overflow: hidden;
}
.cf-three-canvas {
  position: relative;
  z-index: 2;
  display: block;
  width: 100%;
  height: 100%;
  opacity: 0;
  transition: opacity var(--cf-transition-base);
}
.cf-three-placeholder.is-ready .cf-three-canvas {
  opacity: 1;
}
.cf-three-fallback {
  position: absolute;
  z-index: 1;
  top: 50%;
  left: 50%;
  width: min(65%, 18rem);
  height: auto;
  transform: translate(-50%, -50%);
  object-fit: contain;
  border-radius: var(--cf-radius-sm);
  opacity: 0.85;
  transition: opacity var(--cf-transition-base);
}
.cf-three-placeholder.is-ready .cf-three-fallback {
  opacity: 0;
  pointer-events: none;
}
.cf-three-loading {
  position: absolute;
  z-index: 3;
  top: 50%;
  left: 50%;
  width: 1.75rem;
  height: 1.75rem;
  margin: -0.875rem;
  border: 2px solid rgba(41, 39, 39, 0.15);
  border-top-color: var(--cf-color-primary);
  border-radius: var(--cf-radius-full);
  animation: cf-three-loading 0.8s linear infinite;
  transition: opacity var(--cf-transition-fast);
}
.cf-three-placeholder.is-ready .cf-three-loading {
  opacity: 0;
  pointer-events: none;
}
@keyframes cf-three-loading {
  to {
    transform: rotate(360deg);
  }
}
@media (max-width: 64rem) {
  .cf-three-placeholder {
    min-height: 28rem;
  }
}
@media (max-width: 48rem) {
  .cf-three-placeholder {
    min-height: 24rem;
  }
  .cf-three-fallback {
    width: min(70%, 15rem);
  }
}
