/* Full-viewport sections, shining headers, layered 3D depth */

/* ── Panel shell ─────────────────────────────────────────── */
.section-panel {
  position: relative;
  min-height: auto;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding-block: clamp(5rem, 12vh, 8rem);
  overflow: visible;
  isolation: auto;
}

.section-panel--auto {
  min-height: auto;
  justify-content: flex-start;
}

.section-panel--ticker {
  min-height: auto;
  justify-content: center;
  padding-block: clamp(2.5rem, 8vh, 4rem);
}

.section-panel--light {
  /* Mint wash owned by light-workloads.css — no opaque fill */
}

.section-panel:not(.section-panel--light) {
  background: transparent;
}

.section-panel__inner {
  position: relative;
  z-index: 1;
  width: 100%;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: clamp(1.5rem, 4vh, 2.5rem);
}

@keyframes glow-drift {
  0% { opacity: 0.75; transform: scale(1) translate(0, 0); }
  100% { opacity: 1; transform: scale(1.05) translate(2%, -2%); }
}

/* ── Shining section headers ───────────────────────────── */
.section-head {
  text-align: center;
  max-width: 52rem;
  margin-inline: auto;
}

.section-head__eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.72rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--color-accent-end);
  margin-bottom: 0.85rem;
  padding: 0.35rem 0.9rem;
  border-radius: var(--radius-pill);
  border: 1px solid rgba(124, 58, 237, 0.35);
  background: rgba(124, 58, 237, 0.08);
}

.section-head__title {
  font-family: var(--font-royal, var(--font-display));
  font-size: clamp(2rem, 5.5vw, 3.25rem);
  line-height: 1.08;
  margin-bottom: 0.85rem;
}

.section-head--shine .section-head__title {
  background: linear-gradient(
    105deg,
    #f8fafc 0%,
    #c4b5fd 18%,
    #22d3ee 38%,
    #f8fafc 52%,
    #a78bfa 68%,
    #22d3ee 82%,
    #f8fafc 100%
  );
  background-size: 220% auto;
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  animation: title-shine 5s linear infinite;
  filter: drop-shadow(0 0 28px rgba(124, 58, 237, 0.35));
}

.section-head__lead {
  font-size: clamp(1rem, 2.2vw, 1.15rem);
  line-height: 1.65;
  color: var(--color-text-muted);
  max-width: 46rem;
  margin-inline: auto;
}

.section-head__lead a {
  color: #22d3ee;
}

@keyframes title-shine {
  0% { background-position: 0% center; }
  100% { background-position: 220% center; }
}

/* Hero title shine */
.hero__title-royal.section-head__title--shine,
.hero__title-royal {
  background: linear-gradient(
    105deg,
    #f8fafc 0%,
    #c4b5fd 20%,
    #22d3ee 42%,
    #f8fafc 55%,
    #a78bfa 72%,
    #f8fafc 100%
  );
  background-size: 220% auto;
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  animation: title-shine 6s linear infinite;
}

/* ── Modules: categories inline + 3D stack ─────────────── */
#hero.section-panel {
  padding-block-start: clamp(5.5rem, 16vw, 8.5rem);
  padding-block-end: clamp(2.5rem, 8vw, 5rem);
}

.apps--organizer.section-panel--modules {
  justify-content: flex-start;
  padding-block: clamp(4rem, 10vh, 6rem);
}

.categories--inline {
  padding: 0;
  text-align: center;
}

.categories--inline .section-head__title,
.categories--inline h2 {
  display: none;
}

.categories--inline .category-pills {
  justify-content: center;
}

.organizer-modules__stage {
  perspective: 1400px;
  perspective-origin: 50% 40%;
  padding: 1rem 0 2rem;
  position: relative;
}

.organizer-modules__stage::before {
  content: '';
  position: absolute;
  left: 50%;
  top: 45%;
  width: min(90%, 720px);
  height: 280px;
  transform: translate(-50%, -50%);
  background: radial-gradient(ellipse, rgba(124, 58, 237, 0.2), transparent 70%);
  filter: blur(40px);
  pointer-events: none;
  z-index: 0;
}

.organizer-modules__grid.stack-3d {
  position: relative;
  z-index: 1;
  transform-style: preserve-3d;
}

@media (min-width: 900px) {
  .organizer-modules__grid.stack-3d .app-card--organizer {
    transition:
      transform var(--dur-base) var(--ease-out),
      box-shadow var(--dur-base) var(--ease-out),
      border-color var(--dur-fast);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.45);
  }

  .organizer-modules__grid.stack-3d .app-card--organizer:nth-child(6n + 1) {
    transform: rotateY(-5deg) rotateX(2deg) translateZ(24px);
  }
  .organizer-modules__grid.stack-3d .app-card--organizer:nth-child(6n + 2) {
    transform: rotateY(3deg) rotateX(-1deg) translateZ(48px);
    z-index: 2;
  }
  .organizer-modules__grid.stack-3d .app-card--organizer:nth-child(6n + 3) {
    transform: rotateY(-2deg) translateZ(12px);
  }
  .organizer-modules__grid.stack-3d .app-card--organizer:nth-child(6n + 4) {
    transform: rotateY(6deg) translateZ(36px);
    z-index: 3;
  }
  .organizer-modules__grid.stack-3d .app-card--organizer:nth-child(6n + 5) {
    transform: rotateY(-4deg) translateZ(20px);
  }
  .organizer-modules__grid.stack-3d .app-card--organizer:nth-child(6n + 6) {
    transform: rotateY(2deg) translateZ(56px);
    z-index: 4;
  }

  .organizer-modules__grid.stack-3d .app-card--organizer:hover {
    transform: rotateY(0deg) rotateX(0deg) translateZ(72px) scale(1.02);
    z-index: 20;
    box-shadow: 0 24px 60px rgba(124, 58, 237, 0.35);
  }
}

/* Stats / timeline / carousel depth */
.stats-grid,
.how-journey__steps,
.carousel__track {
  transform-style: preserve-3d;
}

.stat-card {
  transition: transform var(--dur-base) var(--ease-out), box-shadow var(--dur-base);
}

.stat-card:hover {
  transform: translateY(-6px) translateZ(12px);
  box-shadow: var(--shadow-glow);
}

.how-step {
  transition: transform var(--dur-base) var(--ease-out);
}

@media (min-width: 900px) {
  .how-step:nth-child(2) .how-step__card {
    transform: translateY(12px) translateZ(16px);
  }

  .how-step:nth-child(2).is-active .how-step__card {
    transform: translateY(4px) translateZ(20px);
  }
}

.why--stream.section-panel .why-stream {
  max-width: 920px;
}

.pricing--configurator.section-panel .section-panel__inner {
  gap: 1.5rem;
}

@media (prefers-reduced-motion: reduce) {
  .section-head--shine .section-head__title,
  .hero__title-royal,
  .organizer-modules__grid.stack-3d .app-card--organizer,
  .organizer-modules__grid.stack-3d .app-card--organizer:hover {
    transform: none;
  }
}

/* Pointer tilt on module cards (inner layer preserves stack-3d on parent) */
.app-card--organizer .app-card__inner {
  height: 100%;
  display: flex;
  flex-direction: column;
  transform: rotateX(var(--tilt-x, 0deg)) rotateY(var(--tilt-y, 0deg));
  transition: transform 0.15s var(--ease-out, ease-out);
  transform-style: preserve-3d;
}

.app-card--organizer:hover .app-card__inner {
  transition-duration: 0.08s;
}
