/* 3D Animations & Micro-interactions */

/* 3D Perspective Wrappers */
.perspective-container {
  perspective: 1200px;
  transform-style: preserve-3d;
}

.tilt-element {
  transition: transform 0.15s ease-out, box-shadow 0.25s ease-out;
  transform-style: preserve-3d;
  will-change: transform;
}

/* Realistic 3D Phone Mockup Styling */
.phone-3d-wrapper {
  position: relative;
  width: 320px;
  height: 650px;
  max-width: 100%;
  margin: 0 auto;
  perspective: 1400px;
  transform-style: preserve-3d;
}

.phone-hardware-chassis {
  width: 100%;
  height: 100%;
  background: #0F0F1A;
  border-radius: 50px;
  border: 7px solid #232338;
  box-shadow: 
    0 30px 80px rgba(0, 0, 0, 0.9),
    0 0 60px var(--crimson-glow),
    inset 0 0 14px rgba(255, 255, 255, 0.12);
  position: relative;
  overflow: hidden;
  transition: transform 0.25s ease-out, box-shadow 0.3s ease;
  transform-style: preserve-3d;
}

.phone-hardware-chassis:hover {
  box-shadow: 
    0 35px 90px rgba(0, 0, 0, 0.95),
    0 0 80px rgba(229, 9, 20, 0.65),
    inset 0 0 16px rgba(255, 255, 255, 0.18);
}

.phone-notch-bar {
  position: absolute;
  top: 12px;
  left: 50%;
  transform: translateX(-50%);
  width: 110px;
  height: 24px;
  background: #000000;
  border-radius: 20px;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 10px;
  box-shadow: 0 2px 6px rgba(0,0,0,0.8);
}

.notch-camera-lens {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #111122;
  border: 1px solid #33334d;
}

.notch-sensor {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #090914;
}

.phone-screen-display {
  width: 100%;
  height: 100%;
  position: relative;
  background: #000000;
  display: flex;
  flex-direction: column;
}

.phone-screen-display img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  border-radius: 42px;
}

/* Glass Reflection overlay */
.phone-glass-glare {
  position: absolute;
  top: 0;
  left: -50%;
  width: 200%;
  height: 100%;
  background: linear-gradient(
    135deg,
    rgba(255, 255, 255, 0.15) 0%,
    rgba(255, 255, 255, 0.03) 40%,
    transparent 60%
  );
  pointer-events: none;
  z-index: 40;
}

/* Shimmer Animation on Highlights */
@keyframes shimmerGold {
  0% { background-position: -200% 0; }
  100% { background-position: 200% 0; }
}

.shimmer-text {
  background: linear-gradient(90deg, #FFFFFF 0%, var(--gold-light) 50%, #FFFFFF 100%);
  background-size: 200% auto;
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  animation: shimmerGold 4s linear infinite;
}

/* Floating Card Animation */
@keyframes cardFloat {
  0% { transform: translateY(0px) rotate(0deg); }
  50% { transform: translateY(-10px) rotate(0.5deg); }
  100% { transform: translateY(0px) rotate(0deg); }
}

.floating-card {
  animation: cardFloat 6s ease-in-out infinite;
}

.floating-card-delayed {
  animation: cardFloat 7s ease-in-out infinite 2s;
}

/* Glowing Neon Border */
.neon-border-box {
  position: relative;
  border-radius: var(--radius-lg);
  background: var(--bg-card);
  border: 1px solid var(--border-medium);
  overflow: hidden;
  transition: var(--transition-smooth);
}

.neon-border-box::before {
  content: '';
  position: absolute;
  top: -2px;
  left: -2px;
  right: -2px;
  bottom: -2px;
  background: linear-gradient(45deg, var(--crimson-primary), transparent 40%, var(--gold-primary), transparent 80%);
  z-index: -1;
  opacity: 0;
  transition: opacity 0.4s ease;
  border-radius: calc(var(--radius-lg) + 2px);
}

.neon-border-box:hover::before {
  opacity: 0.8;
}

.neon-border-box:hover {
  transform: translateY(-6px);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.8), 0 0 25px var(--crimson-glow);
}

/* Pulse Glow */
@keyframes pulseGlow {
  0% { box-shadow: 0 0 15px rgba(229, 9, 20, 0.3); }
  50% { box-shadow: 0 0 35px rgba(229, 9, 20, 0.7); }
  100% { box-shadow: 0 0 15px rgba(229, 9, 20, 0.3); }
}

.pulse-glow {
  animation: pulseGlow 3s infinite ease-in-out;
}

/* Screen Reveal On Scroll */
.reveal-on-scroll {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

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