/* Apple-Style Auto-Animated Hero - INVINAI v2.0.0 */
/* Animazione automatica temporizzata stile Apple */
/* ⚡ Workflow automatizzato con build-and-refresh.sh */

/* ===============================================
   SEZIONE CTA FINALE - ECLIPSE EFFECT (SCROLL PINNING)
   =============================================== */

/* Contenitore "binario" da 100vh - crea lo spazio di scroll */
.cta-track {
  position: relative;
  width: 100%;
  height: 100vh; /* Binario lungo 1x l'altezza dello schermo */
  background: #0A0F1D; /* Sfondo nero/blu notte profondo */
  z-index: 2; /* Sta SOPRA il footer */
  margin-bottom: -40vh; /* Tira su il footer per sovrapporsi */
}

/* Elemento sticky che si "pinna" durante lo scroll */
.eclipse-sticky-element {
  position: sticky;
  top: 0;
  width: 100%;
  height: 100vh; /* Occupa sempre 100% dell'altezza visibile */
  display: flex;
  align-items: center; /* Centra verticalmente il contenuto */
  justify-content: center; /* Centra orizzontalmente il contenuto */
  overflow: hidden;
}

/* Corona di luce ciano (TECNICA PRECISA) */
.eclipse-corona {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 900px;  /* Corona ciano a 900px */
  height: 900px;
  border-radius: 50%;
  z-index: 1;

  /* Gradiente semplice: anello più denso vicino al centro */
  background: radial-gradient(circle, rgba(165, 243, 252, 0.4) 50%, transparent 70%);

  /* Blur forte per ammorbidire l'anello */
  filter: blur(80px);

  /* Animazione pulsante leggera */
  animation: corona-glow 8s ease-in-out infinite;
}

@keyframes corona-glow {
  0%, 100% {
    opacity: 0.8;
    transform: translate(-50%, -50%) scale(1);
  }
  50% {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1.05);
  }
}

/* Cerchio nero perfetto (davanti alla corona) */
.eclipse-circle {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 750px;
  height: 750px;
  border-radius: 50%;
  background: #000000;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: center;

  /* Ombra sottile per profondità */
  box-shadow: 0 0 100px rgba(0, 0, 0, 0.9);
}

/* Contenuto interno (testo + pulsante) */
.eclipse-content {
  position: relative;
  z-index: 3;
  max-width: 600px;
  text-align: center;
  padding: 60px 40px;
  color: #FFFFFF;
}

/* Titolo H1 - Playfair Display CORSIVO, Peso LEGGERO */
.eclipse-title {
  font-family: 'Playfair Display', Georgia, serif;
  font-size: 3.5rem; /* Leggermente più piccolo come richiesto */
  font-weight: 400; /* Peso LEGGERO */
  font-style: italic; /* CORSIVO */
  line-height: 1.3;
  letter-spacing: -0.02em;
  color: #FFFFFF;
  margin: 0 0 28px 0;
}

/* Sottotitolo H2 - Inter, Grigio, 80% larghezza */
.eclipse-subtitle {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Inter", sans-serif;
  font-size: 1.1rem;
  font-weight: 300;
  line-height: 1.6;
  color: #A0A0B0;
  max-width: 80%;
  margin: 0 auto 36px auto;
}

/* Pulsante Stile Navbar - BIANCO su NERO */
.eclipse-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 24px;
  background: #FFFFFF;
  color: #0A0F1D;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Inter", sans-serif;
  font-size: 16px;
  font-weight: 500;
  text-decoration: none;
  border: none;
  border-radius: 999px; /* Completamente arrotondato */
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.eclipse-button:hover {
  background: #F5F5F5;
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(255, 255, 255, 0.3);
}

/* Mobile Responsive */
@media (max-width: 768px) {
  .eclipse-corona {
    width: 600px;
    height: 600px;
  }

  .eclipse-circle {
    width: 420px;
    height: 420px;
  }

  .eclipse-content {
    padding: 40px 28px;
    max-width: 340px;
  }

  .eclipse-title {
    font-size: 2.5rem;
  }

  .eclipse-subtitle {
    font-size: 1rem;
    max-width: 90%;
  }

  .eclipse-button {
    padding: 10px 20px;
    font-size: 15px;
  }
}

/* ===============================================
   HERO SECTION - LAYOUT BASE
   =============================================== */

.apple-hero {
  width: 100%;
  min-height: 100vh;
  background: #000000;
  color: #FFFFFF;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 80px 40px 140px;
  position: relative;
  overflow: hidden;
}

/* Particles Background Canvas */
.hero-particles-bg {
  position: absolute;
  top: 0;
  left: 0;
  width: 100% !important;
  height: 100% !important;
  z-index: 0;
  pointer-events: none;
  display: block;
}

/* ===============================================
   CONTENUTO - CENTRATO
   =============================================== */

.apple-hero-content {
  width: 100%;
  max-width: 980px;
  margin: 0 auto;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 40px;
  position: relative;
  z-index: 10;
}

/* ===============================================
   TIPOGRAFIA - STILE APPLE
   =============================================== */

/* Headline Principale */
.apple-headline {
  font-size: clamp(52px, 9vw, 112px);
  font-weight: 700;
  line-height: 1.05;
  letter-spacing: -0.015em;
  color: #FFFFFF;
  margin: 0;
  padding: 0;
  
  /* Animazione automatica - FASE 1 (più veloce) */
  opacity: 0;
  transform: translateY(30px) scale(0.96);
  animation: fadeInScale 0.7s cubic-bezier(0.4, 0, 0.2, 1) 0.2s forwards;
}

/* Subtitle - Secondario con contrasto forte */
.apple-subtitle {
  font-size: clamp(18px, 2vw, 26px);
  font-weight: 400;
  line-height: 1.15;
  letter-spacing: -0.005em;
  color: #D1D1D6;
  margin: 0;
  padding: 0;
  max-width: 820px;
  
  /* Animazione automatica - FASE 2 (più veloce - dopo 0.8s) */
  opacity: 0;
  transform: translateY(30px);
  animation: fadeInUp 0.7s cubic-bezier(0.4, 0, 0.2, 1) 0.8s forwards;
}

/* Description Paragraph - Terziario con contrasto forte */
.apple-description {
  font-size: clamp(20px, 1.5vw, 24px);
  font-weight: 400;
  line-height: 1.47;
  letter-spacing: -0.003em;
  color: #8E8E93;
  margin: 0;
  padding: 0;
  max-width: 690px;

  /* Animazione automatica - FASE 3 (più veloce - dopo 1.4s) */
  opacity: 0;
  transform: translateY(30px);
  animation: fadeInUp 0.7s cubic-bezier(0.4, 0, 0.2, 1) 1.4s forwards;
}

/* ===============================================
   KEYFRAMES - ANIMAZIONI
   =============================================== */

@keyframes fadeInScale {
  from {
    opacity: 0;
    transform: translateY(30px) scale(0.96);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes fadeInUpShort {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ===============================================
   BANNER FOOTER - STILE APPLE ONE
   =============================================== */

.apple-banner {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 32px 40px;
  background: rgba(255, 255, 255, 0.04);
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  z-index: 10;
  
  /* Animazione automatica - FASE 3 (più veloce - dopo 1.7s) */
  opacity: 0;
  transform: translateY(20px);
  animation: fadeInUpShort 0.6s cubic-bezier(0.4, 0, 0.2, 1) 1.7s forwards;
}

.apple-banner-content {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.apple-banner-left {
  display: flex;
  align-items: center;
  gap: 16px;
}

.apple-banner-icon {
  flex-shrink: 0;
}

.apple-banner-text {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.apple-banner-title {
  font-size: 17px;
  font-weight: 600;
  color: #FFFFFF;
  line-height: 1.3;
}

.apple-banner-subtitle {
  font-size: 14px;
  font-weight: 400;
  color: #A1A1A6;
  line-height: 1.4;
}

.apple-banner-cta {
  display: inline-flex;
  align-items: center;
  padding: 12px 24px;
  background: #FFFFFF;
  color: #000000;
  font-size: 14px;
  font-weight: 600;
  border-radius: 980px;
  text-decoration: none;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  white-space: nowrap;
  border: 1px solid rgba(255, 255, 255, 0.15);
}

.apple-banner-cta:hover {
  background: #F5F5F7;
  transform: scale(1.03);
}

.apple-banner-cta:active {
  transform: scale(0.98);
}

/* ===============================================
   RESPONSIVE - TABLET
   =============================================== */

@media (max-width: 1024px) {
  .apple-hero {
    padding: 60px 32px 180px;
  }
  
  .apple-hero-content {
    max-width: 692px;
    gap: 32px;
  }
  
  .apple-headline {
    font-size: clamp(48px, 7.5vw, 92px);
  }
  
  .apple-subtitle {
    font-size: clamp(16px, 1.9vw, 24px);
  }
  
  .apple-description {
    font-size: clamp(18px, 1.3vw, 19px);
  }
  
  .apple-banner {
    padding: 24px 32px;
  }
  
  .apple-banner-content {
    flex-direction: column;
    align-items: flex-start;
    gap: 20px;
  }
  
  .apple-banner-cta {
    width: 100%;
    justify-content: center;
  }
}

/* ===============================================
   RESPONSIVE - MOBILE
   =============================================== */

@media (max-width: 768px) {
  .apple-hero {
    min-height: 100vh;
    padding: 0 24px 200px;
    display: flex;
    align-items: center;
    justify-content: center;
  }

  .apple-hero-content {
    gap: 28px;
    margin-top: 200px;
  }

  .apple-headline {
    font-size: clamp(80px, 16vw, 110px);
    line-height: 0.95;
    margin-bottom: 16px;
  }

  .apple-subtitle {
    font-size: clamp(28px, 6vw, 36px);
    line-height: 1.25;
    margin-bottom: 12px;
  }

  .apple-description {
    font-size: clamp(20px, 5vw, 24px);
    line-height: 1.5;
    max-width: 100%;
  }
  
  .apple-banner {
    padding: 20px 24px;
  }
  
  .apple-banner-left {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
  }
  
  .apple-banner-title {
    font-size: 16px;
  }
  
  .apple-banner-subtitle {
    font-size: 13px;
  }
}

@media (max-width: 480px) {
  .apple-hero {
    padding: 0 20px 180px;
  }

  .apple-hero-content {
    gap: 32px;
    margin-top: 120px;
  }

  .apple-headline {
    font-size: 72px;
    margin-bottom: 20px;
    line-height: 0.92;
  }

  .apple-subtitle {
    font-size: 26px;
    margin-bottom: 16px;
    line-height: 1.3;
  }

  .apple-description {
    font-size: 18px;
    line-height: 1.55;
  }
}

/* ===============================================
   PERFORMANCE OPTIMIZATIONS
   =============================================== */

/* Hardware acceleration */
.apple-headline,
.apple-subtitle,
.apple-description,
.apple-banner {
  backface-visibility: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* ===============================================
   ACCESSIBILITÀ
   =============================================== */

.apple-banner-cta:focus {
  outline: 3px solid rgba(255, 255, 255, 0.6);
  outline-offset: 3px;
}

.apple-banner-cta:focus:not(:focus-visible) {
  outline: none;
}

/* Reduced Motion - Disabilita animazioni */
@media (prefers-reduced-motion: reduce) {
  .apple-headline,
  .apple-subtitle,
  .apple-description,
  .apple-banner {
    animation: none !important;
    opacity: 1 !important;
    transform: none !important;
  }
  
  .apple-banner-cta {
    transition: none !important;
  }
  
  .trust-bar-track {
    animation: none !important;
  }
}

/* ===============================================
   TRUST BAR - PARTNER TECNOLOGICI (Hero Bottom)
   =============================================== */

.trust-bar-hero {
  position: absolute;
  bottom: 24px;
  left: 40px;
  right: 40px;
  width: auto;
  z-index: 10;
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 40px;
  /* Sfondo nero puro */
  background: #000000;
  border-radius: 8px;
  padding: 12px 24px;

  /* Animazione automatica - FASE 4 (dopo apple-description - 2.0s) */
  opacity: 0;
  transform: translateY(20px);
  animation: fadeInUpShort 0.7s cubic-bezier(0.4, 0, 0.2, 1) 2.0s forwards;
}

/* Testo introduttivo - allineato a sinistra, sempre visibile, stessa linea */
.trust-bar-text {
  flex-shrink: 0;
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.4);
  margin: 0;
  white-space: nowrap;
}

/* Track container per animazione infinita */
.trust-bar-track {
  display: flex;
  align-items: center;
  flex: 1;
  overflow: hidden;
  position: relative;
  mask-image: linear-gradient(
    to right,
    transparent 0%,
    black 8%,
    black 92%,
    transparent 100%
  );
  -webkit-mask-image: linear-gradient(
    to right,
    transparent 0%,
    black 8%,
    black 92%,
    transparent 100%
  );
}

/* Contenitore loghi - duplicato per effetto seamless */
.trust-bar-logos {
  display: flex;
  align-items: center;
  gap: 80px;
  padding-right: 80px; /* Gap uniforme tra ultimo e primo logo */
  animation: scrollLogos 35s linear infinite;
  flex-shrink: 0;
}

/* Singolo logo */
.trust-logo {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  height: 36px;
  color: rgba(255, 255, 255, 0.3);
  transition: color 0.3s ease;
}

.trust-logo:hover {
  color: rgba(255, 255, 255, 0.65);
}

.trust-logo svg {
  height: 100%;
  width: auto;
  display: block;
}

/* Animazione scroll infinito - FIX gap uniforme */
@keyframes scrollLogos {
  0% {
    transform: translateX(0);
  }
  100% {
    /* Calcola: -100% (larghezza totale) */
    transform: translateX(-100%);
  }
}

/* Pausa animazione on hover */
.trust-bar-track:hover .trust-bar-logos {
  animation-play-state: paused;
}

/* Responsive */
@media (max-width: 768px) {
  .trust-bar-hero {
    bottom: 40px;
    left: 24px;
    right: 24px;
    gap: 28px;
  }

  .trust-bar-text {
    font-size: 11px;
    letter-spacing: 0.02em;
  }

  .trust-bar-logos {
    gap: 64px;
    padding-right: 64px;
  }

  .trust-logo {
    height: 36px;
  }
}

@media (max-width: 480px) {
  .trust-bar-hero {
    bottom: 32px;
    left: 20px;
    right: 20px;
    gap: 24px;
  }

  .trust-bar-text {
    font-size: 10px;
    letter-spacing: 0.02em;
  }

  .trust-bar-logos {
    gap: 56px;
    padding-right: 56px;
  }

  .trust-logo {
    height: 32px;
  }
}

/* ===============================================
   SMOOTH SCROLL
   =============================================== */

html {
  scroll-behavior: smooth;
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
}

/* ===============================================
   APPLE MUSIC STYLE VIDEO SECTION
   Video contenuto 16:9 + Testo sotto
   =============================================== */

.apple-video-hero {
  width: 100%;
  background: #000000;
  padding: 80px 0px;
}

/* Container principale */
.video-hero-container {
  max-width: 1600px;
  margin: 0 auto;
  
  /* Animazione ingresso */
  animation: videoContentFadeIn 1s cubic-bezier(0.4, 0, 0.2, 1) 0.2s backwards;
}

@keyframes videoContentFadeIn {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Video Wrapper - Aspect Ratio 35% (più basso) */
.video-wrapper {
  position: relative;
  width: 100%;
  padding-bottom: 35%; /* Aspect ratio panoramico (circa 2.85:1) */
  background: #000000;
  border-radius: 0px; /* Nessun border radius per arrivare ai bordi */
  overflow: hidden;
  box-shadow: none; /* Rimosso shadow per video a tutto schermo */
}

/* Video Content */
.video-content {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* Content Container - SOTTO il video */
.video-hero-content {
  padding: 32px 120px 0;
  max-width: 1400px;
  margin: 0 auto;
}

/* Contenuto a sinistra (badge + headline + features + CTA wrapper) */
.video-content-left {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

/* Wrapper per features + CTA - Grid a 2 colonne con CTA centrato */
.features-cta-row {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: 40px;
}

/* Badge superiore - Origin Style (NO animazione) - Più piccolo */
.video-badge {
  display: inline-flex;
  align-items: center;
  align-self: flex-start;
  gap: 5px;
  padding: 4px 10px;
  background: rgba(255, 255, 255, 0.05);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 5px;
  color: #FFFFFF;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.video-badge svg {
  width: 13px;
  height: 13px;
  color: rgba(255, 255, 255, 0.8);
}

/* Headline - Apple Music Style - 40px */
.video-headline {
  font-size: clamp(28px, 3vw, 40px);
  font-weight: 600;
  line-height: 1.2;
  letter-spacing: -0.01em;
  color: #FFFFFF;
  margin: 0 0 16px 0;
  text-align: left;
}

/* Features List - 2 colonne Grid */
.video-features {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px 24px;
}

.video-features li {
  font-size: 15px;
  font-weight: 400;
  color: rgba(255, 255, 255, 0.8);
  line-height: 1.5;
  padding-left: 24px;
  position: relative;
}

.video-features li::before {
  content: "✓";
  position: absolute;
  left: 0;
  color: #3B82F6;
  font-weight: 700;
  font-size: 18px;
}

/* CTA Buttons Group - Ora dentro features-cta-row */
.video-cta-group {
  display: flex;
  align-items: center;
  justify-content: flex-end;
}

.video-cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 28px;
  font-size: 13px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  line-height: 1.4;
  border-radius: 8px;
  text-decoration: none;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  white-space: pre-line;
  text-align: center;
  min-width: 200px;
  position: relative;
  overflow: visible;
}

/* Primary CTA - Blur bianco visibile + bordo trasparente */
.video-cta-primary {
  background: rgba(255, 255, 255, 0.15);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  color: #FFFFFF;
  border: 1px solid transparent;
}

/* Bordo animato CTA - Punto luminoso con scia lunga (conic-gradient) */
.video-cta-primary::before {
  content: '';
  position: absolute;
  inset: -2px;
  border-radius: 8px;
  padding: 2px;
  background: conic-gradient(
    from var(--angle),
    transparent 0%,
    transparent 85%,
    rgba(255, 255, 255, 0.1) 88%,
    rgba(255, 255, 255, 0.2) 91%,
    rgba(255, 255, 255, 0.4) 94%,
    rgba(255, 255, 255, 0.7) 97%,
    rgba(255, 255, 255, 1) 99%,
    rgba(255, 255, 255, 0.7) 99.5%,
    rgba(255, 255, 255, 0.3) 100%
  );
  -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  animation: rotateBorder 4s linear infinite;
  pointer-events: none;
}

/* Variabile CSS per angolo rotazione */
@property --angle {
  syntax: '<angle>';
  initial-value: 0deg;
  inherits: false;
}

@keyframes rotateBorder {
  0% {
    --angle: 0deg;
  }
  100% {
    --angle: 360deg;
  }
}

.video-cta-primary:hover {
  background: rgba(255, 255, 255, 0.22);
  transform: translateY(-2px);
  box-shadow: 0 12px 40px rgba(255, 255, 255, 0.2);
}

.video-cta-primary:active {
  transform: translateY(0);
}


/* ===============================================
   RESPONSIVE - VIDEO HERO TABLET
   =============================================== */

@media (max-width: 1024px) {
  .apple-video-hero {
    padding: 60px 0px;
  }
  
  .video-hero-content {
    padding: 32px 40px 0;
    gap: 28px;
  }
  
  .video-headline {
    font-size: clamp(22px, 3vw, 32px);
    margin-bottom: 12px;
  }
  
  .video-features li {
    font-size: 14px;
  }
  
  .video-cta {
    padding: 11px 24px;
    font-size: 14px;
    min-width: 130px;
  }
}

/* ===============================================
   RESPONSIVE - VIDEO HERO MOBILE
   =============================================== */

@media (max-width: 768px) {
  .apple-video-hero {
    padding: 48px 0px;
  }

  .video-hero-content {
    padding: 28px 24px 0;
  }

  .features-cta-row {
    grid-template-columns: 1fr;
    gap: 24px;
  }

  .video-cta-group {
    justify-content: stretch;
  }
  
  .video-content-left {
    gap: 10px;
  }
  
  .video-badge {
    font-size: 10px;
    padding: 4px 10px;
  }
  
  .video-badge svg {
    width: 14px;
    height: 14px;
  }
  
  .video-headline {
    font-size: clamp(18px, 4vw, 26px);
    line-height: 1.2;
    margin-bottom: 10px;
  }
  
  .video-features {
    gap: 6px;
  }
  
  .video-features li {
    font-size: 13px;
    padding-left: 20px;
  }
  
  .video-features li::before {
    font-size: 16px;
  }
  
  .video-cta-group {
    align-items: stretch;
    width: 100%;
  }
  
  .video-cta {
    width: 100%;
    padding: 13px 20px;
    font-size: 15px;
  }
}

@media (max-width: 480px) {
  .apple-video-hero {
    padding: 40px 0px;
  }
  
  .video-hero-content {
    padding: 20px 16px 0;
  }
  
  .video-headline {
    font-size: 16px;
  }
  
  .video-cta {
    font-size: 14px;
    padding: 12px 18px;
  }
}

/* ===============================================
   PERFORMANCE & ACCESSIBILITY - VIDEO HERO
   =============================================== */

/* Hardware acceleration */
.video-content,
.video-hero-content {
  backface-visibility: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Focus states */
.video-cta:focus {
  outline: 3px solid rgba(255, 255, 255, 0.6);
  outline-offset: 3px;
}

.video-cta:focus:not(:focus-visible) {
  outline: none;
}

/* Reduced Motion */
@media (prefers-reduced-motion: reduce) {
  .video-hero-container,
  .video-hero-content {
    animation: none !important;
    opacity: 1 !important;
    transform: none !important;
  }
  
  .video-cta {
    transition: none !important;
  }
}

/* ===============================================
   DEMO SECTIONS - 3 Opzioni Animate
   =============================================== */

.demo-section {
  width: 100%;
  min-height: 100vh;
  background: #000000;
  padding: 80px 40px;
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

/* Header demo */
.demo-header {
  text-align: center;
  margin-bottom: 60px;
  z-index: 10;
  position: relative;
}

.demo-label {
  display: inline-block;
  padding: 6px 16px;
  background: rgba(59, 130, 246, 0.1);
  border: 1px solid rgba(59, 130, 246, 0.3);
  border-radius: 100px;
  color: rgba(59, 130, 246, 1);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  margin-bottom: 16px;
}

.demo-title {
  font-size: 48px;
  font-weight: 700;
  color: #FFFFFF;
  margin: 0 0 12px 0;
}

.demo-subtitle {
  font-size: 18px;
  font-weight: 400;
  color: rgba(255, 255, 255, 0.6);
  margin: 0;
}

/* ===============================================
   SECTION 1: CSS Grid Animation
   =============================================== */

.grid-container-1 {
  width: 100%;
  max-width: 1400px;
  height: 600px;
  position: relative;
  background: rgba(10, 15, 30, 0.5);
  border-radius: 16px;
  overflow: hidden;
  border: 1px solid rgba(59, 130, 246, 0.2);
}

/* Griglia SVG */
.grid-svg {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  opacity: 0.6;
}

/* Nodi */
.grid-nodes-1 {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
}

.grid-node {
  position: absolute;
  transform: translate(-50%, -50%);
  z-index: 5;
}

.node-icon {
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  background: rgba(59, 130, 246, 0.2);
  border: 2px solid rgba(59, 130, 246, 0.6);
  border-radius: 50%;
  position: relative;
  z-index: 2;
  animation: nodeFloat 3s ease-in-out infinite;
}

.node-pulse {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: rgba(59, 130, 246, 0.3);
  animation: pulseRing 2s ease-out infinite;
}

@keyframes nodeFloat {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-10px); }
}

@keyframes pulseRing {
  0% {
    transform: translate(-50%, -50%) scale(1);
    opacity: 1;
  }
  100% {
    transform: translate(-50%, -50%) scale(2.5);
    opacity: 0;
  }
}

/* Linee animate */
.grid-lines-1 {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 1;
}

.animated-line {
  stroke-dasharray: 1000;
  stroke-dashoffset: 1000;
  animation: drawLine 3s ease-in-out infinite;
}

.animated-line.line-2 {
  animation-delay: 0.5s;
}

.animated-line.line-3 {
  animation-delay: 1s;
}

.animated-line.line-4 {
  animation-delay: 1.5s;
}

@keyframes drawLine {
  0%, 100% {
    stroke-dashoffset: 1000;
    opacity: 0.3;
  }
  50% {
    stroke-dashoffset: 0;
    opacity: 1;
  }
}

/* ===============================================
   SECTION 2: Canvas Network
   =============================================== */

.grid-container-2 {
  width: 100%;
  max-width: 1400px;
  height: 600px;
  position: relative;
  background: rgba(10, 15, 30, 0.5);
  border-radius: 16px;
  overflow: hidden;
  border: 1px solid rgba(59, 130, 246, 0.2);
}

.network-canvas {
  width: 100%;
  height: 100%;
  display: block;
}

/* ===============================================
   SECTION 3: Advanced Effects
   =============================================== */

.grid-container-3 {
  width: 100%;
  max-width: 1400px;
  height: 600px;
  position: relative;
  background: rgba(10, 15, 30, 0.5);
  border-radius: 16px;
  overflow: hidden;
  border: 1px solid rgba(59, 130, 246, 0.2);
}

.particles-canvas {
  width: 100%;
  height: 100%;
  display: block;
}

.grid-nodes-3 {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
}

.interactive-node {
  position: absolute;
  transform: translate(-50%, -50%);
  cursor: pointer;
  pointer-events: all;
  transition: all 0.3s ease;
}

.interactive-node:hover {
  transform: translate(-50%, -50%) scale(1.2);
}

.interactive-node:hover::after {
  content: attr(data-label);
  position: absolute;
  top: -40px;
  left: 50%;
  transform: translateX(-50%);
  background: rgba(59, 130, 246, 0.9);
  color: #FFFFFF;
  padding: 6px 12px;
  border-radius: 6px;
  font-size: 12px;
  font-weight: 600;
  white-space: nowrap;
  pointer-events: none;
}

.node-glow {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 80px;
  height: 80px;
  background: rgba(59, 130, 246, 0.2);
  border-radius: 50%;
  filter: blur(20px);
  animation: glowPulse 2s ease-in-out infinite;
}

@keyframes glowPulse {
  0%, 100% {
    opacity: 0.5;
    transform: translate(-50%, -50%) scale(1);
  }
  50% {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1.3);
  }
}

.node-core {
  width: 56px;
  height: 56px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 28px;
  background: linear-gradient(135deg, rgba(59, 130, 246, 0.8), rgba(139, 92, 246, 0.8));
  border: 3px solid rgba(255, 255, 255, 0.3);
  border-radius: 50%;
  position: relative;
  box-shadow: 0 8px 32px rgba(59, 130, 246, 0.4);
}

/* ===============================================
   SECTION 4: Fusion Network
   =============================================== */

.grid-container-4 {
  width: 100%;
  max-width: 1400px;
  height: 600px;
  position: relative;
  background: rgba(10, 15, 30, 0.5);
  border-radius: 16px;
  overflow: hidden;
  border: 1px solid rgba(59, 130, 246, 0.2);
}

.fusion-canvas {
  width: 100%;
  height: 100%;
  display: block;
}

/* ===============================================
   RESPONSIVE - DEMO SECTIONS
   =============================================== */

@media (max-width: 1024px) {
  .demo-section {
    padding: 60px 32px;
  }
  
  .grid-container-1,
  .grid-container-2,
  .grid-container-3,
  .grid-container-4 {
    height: 500px;
  }
  
  .demo-title {
    font-size: 36px;
  }
}

@media (max-width: 768px) {
  .demo-section {
    min-height: 80vh;
    padding: 48px 24px;
  }
  
  .grid-container-1,
  .grid-container-2,
  .grid-container-3,
  .grid-container-4 {
    height: 400px;
  }
  
  .demo-title {
    font-size: 28px;
  }
  
  .demo-subtitle {
    font-size: 16px;
  }
  
  .node-icon {
    width: 36px;
    height: 36px;
    font-size: 18px;
  }
  
  .node-core {
    width: 42px;
    height: 42px;
    font-size: 21px;
  }
}
/* ===============================================
   HERO PLEXUS - GRADIENTE DRAMMATICO VERTICALE
   =============================================== */

.section-hero-plexus {
  padding: 180px 24px;
  text-align: center;
  position: relative;
  background: linear-gradient(180deg, #0A0F1D 0%, #1E40AF 100%);
  overflow: hidden;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
}

.plexus-canvas {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
}

.hero-plexus-content {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  gap: 0;
  align-items: center;
}

.hero-plexus-brand {
  font-size: 96px;
  font-weight: 900;
  color: #FFFFFF;
  margin: 0 0 40px 0;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  line-height: 1;

  /* Animazione automatica - FASE 1 */
  opacity: 0;
  transform: translateY(30px) scale(0.96);
  animation: fadeInScale 0.7s cubic-bezier(0.4, 0, 0.2, 1) 0.2s forwards;
}

.hero-plexus-tagline {
  font-size: 32px;
  color: #D1D1D6;
  margin: 0 0 40px 0;
  font-weight: 500;
  line-height: 1.3;

  /* Animazione automatica - FASE 2 (dopo 0.8s) */
  opacity: 0;
  transform: translateY(30px);
  animation: fadeInUp 0.7s cubic-bezier(0.4, 0, 0.2, 1) 0.8s forwards;
}

.hero-plexus-desc {
  font-size: 19.2px;
  color: #A0A0B0;
  margin: 0;
  font-weight: 400;
  line-height: 1.7;
  max-width: 700px;
  margin-left: auto;
  margin-right: auto;

  /* Animazione automatica - FASE 3 (dopo 1.4s) */
  opacity: 0;
  transform: translateY(30px);
  animation: fadeInUp 0.7s cubic-bezier(0.4, 0, 0.2, 1) 1.4s forwards;
}

/* Trust Bar Plexus Hero - Partner Tecnologici */
.trust-bar-hero-plexus {
  position: absolute;
  bottom: 24px;
  left: 40px;
  right: 40px;
  width: auto;
  z-index: 10;
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 40px;
  background: rgba(0, 0, 0, 0.3);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-radius: 8px;
  padding: 12px 24px;
  border: 1px solid rgba(255, 255, 255, 0.1);

  /* Animazione automatica - FASE 4 (dopo description - 2.0s) */
  opacity: 0;
  transform: translateY(20px);
  animation: fadeInUpShort 0.7s cubic-bezier(0.4, 0, 0.2, 1) 2.0s forwards;
}

/* Responsive */
@media (max-width: 768px) {
  .hero-plexus-brand {
    font-size: 56px;
  }

  .hero-plexus-tagline {
    font-size: 24px;
  }

  .hero-plexus-desc {
    font-size: 16px;
  }

  .trust-bar-hero-plexus {
    bottom: 40px;
    left: 24px;
    right: 24px;
    gap: 28px;
  }

  .trust-bar-hero-plexus .trust-bar-logos {
    gap: 64px;
    padding-right: 64px;
  }

  .trust-bar-hero-plexus .trust-logo {
    height: 36px;
  }
}

@media (max-width: 480px) {
  .trust-bar-hero-plexus {
    bottom: 32px;
    left: 20px;
    right: 20px;
    gap: 24px;
  }

  .trust-bar-hero-plexus .trust-bar-text {
    font-size: 10px;
    letter-spacing: 0.02em;
  }

  .trust-bar-hero-plexus .trust-bar-logos {
    gap: 56px;
    padding-right: 56px;
  }

  .trust-bar-hero-plexus .trust-logo {
    height: 32px;
  }
}
