/* ==========================================================================
   Concave Panoramic Screen (Wraps around the user)
   ========================================================================== */

/* The Pinned Scroll Track */
.cx-master-scroll {
  position: relative;
  width: 100%;
  /* height: 250vh; */
  /* background-color: #1a1a1c; */
  color: #ffffff;
}

.cx-sticky-frame {
  position: sticky;
  top: 0;
  width: 100%;
  height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  overflow: hidden; /* Crucial: Hides the parts of the cylinder wrapping behind the camera */
  box-sizing: border-box;
}

/* --- Header Formatting --- */
.cx-text-content {
  text-align: center;
  max-width: 820px;
  padding: 0 24px;
  margin-bottom: 5vh;
  z-index: 10;
}

.cx-header-main {
  font-family: var(--font-body, "Plus Jakarta Sans", sans-serif);
  font-size: 0.92rem;
  color: #d1d1d6;
  line-height: 1.6;
  margin-bottom: 16px;
}

.cx-header-sub {
  font-family: var(--font-body, "Plus Jakarta Sans", sans-serif);
  font-size: 0.85rem;
  color: #8e8e93;
  line-height: 1.5;
  margin-bottom: 16px;
}

.cx-header-tagline {
  font-family: var(--font-body, "Plus Jakarta Sans", sans-serif);
  font-size: 0.8rem;
  color: #8e8e93;
  letter-spacing: 1px;
}

.cx-header-tagline span {
  color: #ffffff;
  font-weight: 600;
  letter-spacing: 1.5px;
}

/* --- 3D Viewport --- */
.cx-3d-viewport {
  position: relative;
  width: 100%;
  height: 320px;
  perspective: 1000px; /* Deeper perspective puts user right inside the curve */
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: grab;
  user-select: none;
  -webkit-user-select: none;
}

.cx-3d-viewport:active {
  cursor: grabbing;
}

/* .cx-vignette {
  position: absolute;
  top: 0;
  width: 18vw;
  height: 100%;
  z-index: 20;
  pointer-events: none;
}
.cx-vignette.cx-left {
  left: 0;
  background: linear-gradient(to right, #1a1a1c 0%, transparent 100%);
}
.cx-vignette.cx-right {
  right: 0;
  background: linear-gradient(to left, #1a1a1c 0%, transparent 100%);
} */

/* --- The VR Engine --- */
.cx-3d-prism {
  position: relative;

  /* Desktop Layout */
  --card-width: 480px;
  --radius: 580px;

  width: var(--card-width);
  height: 270px;
  transform-style: preserve-3d;

  /* THE MAGIC: Pushing the cylinder forward by its exact radius places the center 
     image flat on the glass, while the side images pop out and wrap around you */
  transform: translateZ(var(--radius)) rotateY(var(--rotation, 0deg));
}

.cx-prism-face {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  backface-visibility: hidden;

  /* Inverted math: Angled inward (-45deg) and pushed back into the screen */
  transform: rotateY(calc(var(--i) * -45deg))
    translateZ(calc(-1 * var(--radius)));
}

.cx-prism-face img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  pointer-events: none;
  box-shadow: 0 0 25px rgba(0, 0, 0, 0.8);
}

/* --- Navigation Dots --- */
.cx-dots-wrapper {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-top: 50px;
  z-index: 10;
}

.cx-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background-color: rgba(255, 255, 255, 0.2);
  cursor: pointer;
  transition: all 0.3s ease;
}

.cx-dot.active {
  background-color: #ffffff;
  transform: scale(1.3);
}

/* --- Responsive Scaling --- */
@media (max-width: 1024px) {
  .cx-3d-prism {
    --card-width: 380px;
    --radius: 459px;
    height: 214px;
  }
}

@media (max-width: 768px) {
  .cx-3d-viewport {
    perspective: 800px;
    height: 200px;
  }
  .cx-3d-prism {
    --card-width: 280px;
    --radius: 338px;
    height: 158px;
  }
  .cx-text-content {
    margin-bottom: 3vh;
  }
  .cx-header-main {
    font-size: 0.8rem;
    margin-bottom: 10px;
  }
  .cx-header-sub {
    font-size: 0.75rem;
  }
}
