/* assets/css/hero.css — Cinematic hero with atmospheric depth, parallax, and particle system */

:root {
  /* Cinematic color grading tokens */
  --hero-bg: #05080f;
  --hero-fg: #f1f5f9;
  --hero-muted: #94a3b8;
  --hero-accent: #FF6A00;
  --hero-accent-glow: rgba(255, 106, 0, 0.4);
  --hero-card: rgba(14, 17, 19, 0.72);
  --hero-border: rgba(255, 255, 255, 0.08);
  --hero-glass: rgba(20, 23, 28, 0.6);
  --hero-glass-border: rgba(255, 255, 255, 0.12);
}

/* ============================================================
   CINEMATIC HERO CONTAINER
   ============================================================ */
.hero-cinematic {
  position: relative;
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  overflow: clip;
  background: var(--hero-bg);
  color: var(--hero-fg);
  padding: 4rem 0 3rem;
  box-sizing: border-box;
  isolation: isolate;
  font-family: var(--font-ui);
}

/* Prevent horizontal scroll from particles/rays */
.hero-cinematic,
.hero-atmosphere,
.hero-slides {
  overflow-x: hidden;
}

/* ============================================================
   ATMOSPHERIC LAYERS (background effects)
   ============================================================ */
.hero-atmosphere {
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  overflow: hidden;
}

/* Particle canvas */
.hero-particles {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block;
}

/* Volumetric light rays */
.hero-light-rays {
  position: absolute;
  inset: -20%;
  background:
    radial-gradient(ellipse 80% 50% at 50% -10%, rgba(255, 106, 0, 0.08) 0%, transparent 70%),
    radial-gradient(ellipse 60% 40% at 20% 10%, rgba(255, 106, 0, 0.05) 0%, transparent 60%),
    radial-gradient(ellipse 50% 30% at 80% 20%, rgba(255, 106, 0, 0.04) 0%, transparent 50%);
  animation: rays-drift 20s ease-in-out infinite alternate;
  opacity: 0.6;
}

@keyframes rays-drift {
  0% { transform: translate(-2%, -1%) rotate(-0.5deg); opacity: 0.5; }
  50% { transform: translate(2%, 1%) rotate(0.5deg); opacity: 0.7; }
  100% { transform: translate(-2%, -1%) rotate(-0.5deg); opacity: 0.5; }
}

/* Atmospheric fog layer */
.hero-fog {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, rgba(5, 8, 15, 0) 0%, rgba(5, 8, 15, 0.3) 60%, rgba(5, 8, 15, 0.8) 100%),
    radial-gradient(ellipse at 50% 80%, rgba(255, 106, 0, 0.03) 0%, transparent 70%);
  animation: fog-breathe 15s ease-in-out infinite alternate;
}

@keyframes fog-breathe {
  0% { opacity: 0.7; }
  100% { opacity: 1; }
}

/* Cinematic vignette */
.hero-vignette {
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at center, transparent 40%, rgba(5, 8, 15, 0.6) 100%);
  pointer-events: none;
}

/* ============================================================
   BACKGROUND SLIDES WITH PARALLAX DEPTH
   ============================================================ */
.hero-slides {
  position: absolute;
  inset: 0;
  z-index: 1;
  overflow: hidden;
}

.hero-slide {
  position: absolute;
  inset: 0;
  z-index: 1;
  opacity: 0;
  visibility: hidden;
  /* Bleed margin: must always exceed the max JS parallax shift (±7.5px),
     otherwise edges expose the section background mid-swipe on touch. */
  transform: scale(1.12);
  transition: opacity 1.2s cubic-bezier(0.25, 0.46, 0.45, 0.94), visibility 0s linear 1.2s, transform 1.2s cubic-bezier(0.25, 0.46, 0.45, 0.94);
  will-change: opacity, transform;
}

.hero-slide.active {
  opacity: 1;
  visibility: visible;
  transform: scale(1.12);
  transition: opacity 1.2s cubic-bezier(0.25, 0.46, 0.45, 0.94), transform 1.2s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.hero-slide.active img {
  animation: hero-ken-burns 18s ease-out forwards;
}

@keyframes hero-ken-burns {
  0% { transform: scale(1.02); }
  100% { transform: scale(1.15); }
}

.hero-slide img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  will-change: transform;
}

/* Slide overlay for color grading */
.hero-slide-overlay {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(4, 7, 13, 0.92) 0%, rgba(4, 7, 13, 0.72) 40%, rgba(4, 7, 13, 0.35) 100%),
    linear-gradient(0deg, rgba(4, 7, 13, 0.85) 0%, rgba(4, 7, 13, 0.25) 50%, rgba(4, 7, 13, 0.5) 100%);
  mix-blend-mode: multiply;
}

/* ============================================================
   FOREGROUND CONTENT
   ============================================================ */
.hero-content {
  position: relative;
  z-index: 10;
  width: 100%;
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 2rem;
  text-align: left;
  will-change: transform;
}

.hero-inner {
  position: relative;
  z-index: 2;
}

/* ============================================================
   CINEMATIC BADGE
   ============================================================ */
.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 1rem;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--hero-accent);
  background: linear-gradient(135deg, rgba(255, 106, 0, 0.12), rgba(255, 106, 0, 0.04));
  border: 1px solid rgba(255, 106, 0, 0.25);
  padding: 0.65rem 1.25rem;
  border-radius: 100px;
  margin-bottom: 1.75rem;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  box-shadow:
    0 4px 24px rgba(255, 106, 0, 0.12),
    inset 0 1px 0 rgba(255, 255, 255, 0.06);
}

.hero-badge-pulse {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--hero-accent);
  box-shadow: 0 0 12px var(--hero-accent-glow), 0 0 24px var(--hero-accent-glow);
  animation: badge-pulse 2.5s ease-in-out infinite;
}

@keyframes badge-pulse {
  0%, 100% { opacity: 1; transform: scale(1); box-shadow: 0 0 12px var(--hero-accent-glow), 0 0 24px var(--hero-accent-glow); }
  50% { opacity: 0.5; transform: scale(0.85); box-shadow: 0 0 6px var(--hero-accent-glow), 0 0 12px var(--hero-accent-glow); }
}

.hero-badge-stats {
  font-variant-numeric: tabular-nums;
  color: var(--hero-fg);
  opacity: 0.9;
}

/* ============================================================
   CINEMATIC TYPOGRAPHY
   ============================================================ */
.hero-title {
  font-size: clamp(2.5rem, 5.8vw, 4.75rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.02;
  color: #f8fafc;
  margin: 0 0 1.5rem;
  text-wrap: balance;
  text-shadow: 0 4px 32px rgba(0, 0, 0, 0.4);
}

.hero-title-accent {
  display: inline-block;
  background: linear-gradient(135deg, var(--hero-accent) 0%, #ffaa00 50%, var(--hero-accent) 100%);
  background-size: 200% 100%;
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  animation: gradient-shift 4s ease-in-out infinite;
  position: relative;
}

.hero-title-accent::after {
  content: '';
  position: absolute;
  inset: 0;
  background: inherit;
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  filter: blur(8px);
  opacity: 0.4;
  z-index: -1;
}

@keyframes gradient-shift {
  0%, 100% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
}

.hero-sub {
  font-size: clamp(1rem, 1.8vw, 1.15rem);
  line-height: 1.75;
  color: var(--hero-muted);
  max-width: 42rem;
  margin: 0 0 2.5rem;
  font-weight: 400;
}

.hero-sub strong {
  color: #e2e8f0;
  font-weight: 600;
}

/* ============================================================
   CINEMATIC BUTTONS
   ============================================================ */
.hero-ctas {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
  margin-bottom: 2.5rem;
}

.hero-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  font-weight: 700;
  font-size: 0.95rem;
  letter-spacing: 0.01em;
  padding: 1rem 2rem;
  border-radius: 14px;
  border: none;
  cursor: pointer;
  text-decoration: none;
  transition: transform 0.2s cubic-bezier(0.25, 0.46, 0.45, 0.94), box-shadow 0.2s ease, background 0.2s ease;
  position: relative;
  overflow: hidden;
}

.hero-btn::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.1), transparent);
  opacity: 0;
  transition: opacity 0.2s ease;
}

.hero-btn:hover::before { opacity: 1; }

.hero-btn:focus-visible {
  outline: 2px solid var(--hero-accent);
  outline-offset: 3px;
}

.hero-btn-icon {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
  transition: transform 0.2s ease;
}

.hero-btn:hover .hero-btn-icon { transform: translateX(3px); }

.hero-btn-primary {
  background: linear-gradient(135deg, var(--hero-accent) 0%, #ff8533 100%);
  color: #0e1013;
  box-shadow:
    0 8px 32px rgba(255, 106, 0, 0.35),
    0 4px 16px rgba(255, 106, 0, 0.2),
    inset 0 1px 0 rgba(255, 255, 255, 0.15);
}

.hero-btn-primary:hover {
  transform: translateY(-3px);
  box-shadow:
    0 16px 48px rgba(255, 106, 0, 0.45),
    0 8px 24px rgba(255, 106, 0, 0.25),
    inset 0 1px 0 rgba(255, 255, 255, 0.2);
}

.hero-btn-primary:active { transform: translateY(-1px); }

.hero-btn-secondary {
  background: rgba(14, 17, 19, 0.6);
  color: var(--hero-fg);
  border: 1px solid rgba(255, 255, 255, 0.18);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  box-shadow:
    0 8px 32px rgba(0, 0, 0, 0.3),
    inset 0 1px 0 rgba(255, 255, 255, 0.05);
}

.hero-btn-secondary:hover {
  background: rgba(14, 17, 19, 0.85);
  border-color: rgba(255, 106, 0, 0.4);
  transform: translateY(-3px);
  box-shadow:
    0 16px 48px rgba(0, 0, 0, 0.4),
    0 0 0 1px rgba(255, 106, 0, 0.2),
    inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

/* ============================================================
   SOCIAL PROOF BAR
   ============================================================ */
.hero-proof {
  display: flex;
  align-items: center;
  gap: 1.25rem;
  margin-top: 1.5rem;
  padding-top: 1.25rem;
  position: relative;
}

.hero-avatars {
  display: flex;
  flex-shrink: 0;
}

.hero-ava {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.7rem;
  font-weight: 800;
  color: #fff;
  border: 2px solid var(--hero-bg);
  margin-left: -12px;
  background: var(--hero-card);
  backdrop-filter: blur(8px);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.3);
  transition: transform 0.2s ease, border-color 0.2s ease;
}

.hero-ava:first-child { margin-left: 0; }

.hero-ava:hover {
  transform: translateY(-4px) scale(1.08);
  border-color: var(--hero-accent);
  z-index: 10;
}

.hero-ava-accent {
  background: linear-gradient(135deg, var(--hero-accent) 0%, #ff8533 100%);
  color: #0e1013;
  border-color: var(--hero-bg);
}

.hero-proof-content {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.hero-proof-headline {
  font-size: 0.9rem;
  font-weight: 700;
  color: #e2e8f0;
  letter-spacing: -0.01em;
}

.hero-proof-rating {
  font-size: 0.8rem;
  color: var(--hero-accent);
  letter-spacing: 0.08em;
  font-weight: 600;
}

.hero-proof-rating em {
  font-style: normal;
  color: var(--hero-muted);
  font-weight: 400;
  letter-spacing: 0;
  margin-left: 0.4rem;
}

/* ============================================================
   TRUST BADGES
   ============================================================ */
.hero-trust {
  list-style: none;
  margin: 2rem 0 0;
  padding: 1.5rem 0 0;
  border-top: 1px solid var(--hero-border);
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}

.hero-trust-item {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.6rem 1rem;
  border-radius: 10px;
  background: rgba(14, 17, 19, 0.5);
  border: 1px solid rgba(255, 255, 255, 0.08);
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--hero-muted);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  transition: all 0.2s ease;
  white-space: nowrap;
}

.hero-trust-item:hover {
  background: rgba(14, 17, 19, 0.8);
  border-color: rgba(255, 106, 0, 0.3);
  color: var(--hero-fg);
  transform: translateY(-2px);
}

.hero-trust-item svg {
  width: 16px;
  height: 16px;
  flex: 0 0 16px;
  color: var(--hero-accent);
}

/* ============================================================
   SCROLL INDICATOR
   ============================================================ */
.hero-scroll {
  position: absolute;
  bottom: 2.5rem;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  color: var(--hero-muted);
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  opacity: 0.7;
  animation: scroll-bounce 2.5s ease-in-out infinite;
}

.hero-scroll svg {
  width: 24px;
  height: 24px;
  animation: scroll-arrow 1.5s ease-in-out infinite;
}

@keyframes scroll-bounce {
  0%, 100% { opacity: 0.5; transform: translateX(-50%) translateY(0); }
  50% { opacity: 0.9; transform: translateX(-50%) translateY(4px); }
}

@keyframes scroll-arrow {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(6px); }
}

/* ============================================================
   NAVIGATION DOTS
   ============================================================ */
.hero-dots {
  position: absolute;
  bottom: 2.5rem;
  right: 2.5rem;
  z-index: 20;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.hero-dots button {
  width: 12px;
  height: 12px;
  border: none;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.25);
  cursor: pointer;
  padding: 0;
  transition: all 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
  position: relative;
  box-shadow: 0 0 0 0 rgba(255, 106, 0, 0);
}

.hero-dots button::before {
  content: '';
  position: absolute;
  inset: -4px;
  border-radius: 50%;
  border: 1px solid transparent;
  transition: border-color 0.3s ease;
}

.hero-dots button:hover {
  background: rgba(255, 255, 255, 0.5);
  transform: scale(1.2);
}

.hero-dots button.active {
  background: var(--hero-accent);
  box-shadow: 0 0 0 3px rgba(255, 106, 0, 0.2), 0 0 20px rgba(255, 106, 0, 0.3);
}

.hero-dots button.active::before {
  border-color: var(--hero-accent);
}

/* ============================================================
   SCROLL REVEAL ANIMATIONS
   ============================================================ */
[data-reveal] {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94), transform 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

[data-reveal].is-visible {
  opacity: 1;
  transform: translateY(0);
}

[data-reveal="fade-up"] { transform: translateY(40px); }
[data-reveal="fade-in"] { transform: none; }

/* Stagger delays */
[data-delay="100"] { transition-delay: 100ms; }
[data-delay="200"] { transition-delay: 200ms; }
[data-delay="300"] { transition-delay: 300ms; }
[data-delay="400"] { transition-delay: 400ms; }
[data-delay="500"] { transition-delay: 500ms; }
[data-delay="600"] { transition-delay: 600ms; }
[data-delay="700"] { transition-delay: 700ms; }
[data-delay="800"] { transition-delay: 800ms; }

/* ============================================================
   REDUCED MOTION
   ============================================================ */
@media (prefers-reduced-motion: reduce) {
  .hero-slide,
  .hero-slide.active,
  .hero-slide.active img,
  .hero-light-rays,
  .hero-fog,
  .hero-badge-pulse,
  .hero-title-accent,
  .hero-scroll,
  .hero-dots button,
  [data-reveal] {
    animation: none !important;
    transition: none !important;
  }
  .hero-slide { transition: opacity 0.3s ease; }
  .hero-slide.active { opacity: 1; transform: scale(1.12); }
  [data-reveal] { opacity: 1; transform: none; }
}

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 1024px) {
  .hero-cinematic { min-height: 90vh; min-height: 90dvh; padding: 4rem 0; }
  .hero-dots { bottom: 1.5rem; right: 1.5rem; }
  .hero-scroll { bottom: 1.5rem; }
}

@media (max-width: 768px) {
  .hero-cinematic {
    min-height: auto;
    padding: 5rem 0 4rem;
    align-items: flex-start;
  }

  .hero-content { padding: 0 1.25rem; }

  .hero-badge {
    font-size: 0.65rem;
    padding: 0.5rem 1rem;
    margin-bottom: 1.25rem;
    max-width: 100%;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .hero-title { font-size: clamp(1.9rem, 8.5vw, 2.6rem); line-height: 1.12; margin-bottom: 1rem; }

  .hero-sub { font-size: 0.9rem; line-height: 1.65; margin-bottom: 1.75rem; }

  .hero-ctas { flex-direction: column; align-items: stretch; gap: 0.75rem; }

  .hero-btn {
    width: 100%;
    padding: 1rem 1.5rem;
    font-size: 0.9rem;
    border-radius: 12px;
  }

  .hero-proof { margin-top: 1.25rem; padding-top: 1.5rem; gap: 0.85rem; }

  .hero-avatars span { width: 34px; height: 34px; font-size: 0.6rem; }

  .hero-trust {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0.5rem;
    margin-top: 1.25rem;
    padding-top: 1rem;
  }

  .hero-trust-item {
    flex-direction: column;
    justify-content: center;
    gap: 0.3rem;
    padding: 0.55rem 0.4rem;
    text-align: center;
    font-size: 0.58rem;
    letter-spacing: 0.02em;
    white-space: normal;
  }

  .hero-trust-item svg { width: 16px; height: 16px; }

  .hero-dots { bottom: 1rem; right: 1rem; flex-direction: row; }
  .hero-dots button { width: 10px; height: 10px; }

  .hero-scroll { display: none; }
}

@media (max-width: 480px) {
  .hero-trust { grid-template-columns: 1fr 1fr; }
}