.nido-hero {
  --nido-hero-accent: #6AA842;
  --nido-hero-text: #ffffff;
  position: relative;
  min-height: 100svh;
  display: flex;
  overflow: hidden;
  isolation: isolate;
  background-color: #06080b;
  background-image: var(--nido-hero-bg, none);
  background-repeat: no-repeat;
  background-position: center center;
  background-size: cover;
  color: var(--nido-hero-text);
  border-radius: 0;
}

.nido-hero__overlay {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.56);
  z-index: 0;
}

.nido-hero--gradient .nido-hero__overlay {
  background:
    radial-gradient(circle at 80% 22%, rgba(255, 255, 255, 0.18), transparent 20%),
    linear-gradient(90deg, rgba(0, 0, 0, 0.78) 0%, rgba(0, 0, 0, 0.58) 38%, rgba(0, 0, 0, 0.26) 62%, rgba(0, 0, 0, 0.2) 100%);
}

.nido-hero__inner {
  width: min(100%, 1540px);
  margin-inline: auto;
  padding: 56px 48px;
  min-height: inherit;
  display: grid;
  grid-template-columns: minmax(320px, 560px) 1fr;
  gap: clamp(24px, 4vw, 72px);
  align-items: center;
  position: relative;
  z-index: 1;
}

.nido-hero__content {
  max-width: 560px;
}

.nido-hero__eyebrow {
  margin-bottom: 20px;
  font-family: Montserrat, sans-serif;
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: #f1f5f9;
}

.nido-hero__title {
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 0.04em;
  font-family: Montserrat, sans-serif;
  font-size: clamp(50px, 7vw, 88px);
  line-height: 0.94;
  font-weight: 300;
  letter-spacing: -0.04em;
  color: var(--nido-hero-text);
}

.nido-hero__title-accent {
  color: var(--nido-hero-accent);
}

.nido-hero__description {
  margin-top: 26px;
  max-width: 30ch;
  font-family: Montserrat, sans-serif;
  font-size: clamp(18px, 1.5vw, 21px);
  line-height: 1.45;
  color: rgba(255, 255, 255, 0.9);
}

.nido-hero__buttons {
  margin-top: 36px;
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
}

.nido-hero__button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  min-height: 52px;
  padding: 13px 26px;
  border-radius: 999px;
  font-family: Montserrat, sans-serif;
  font-size: 0.72rem;
  font-weight: 600;
  line-height: 1;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  text-decoration: none;
  transition: transform 220ms ease, background-color 220ms ease, color 220ms ease, border-color 220ms ease, opacity 220ms ease;
}

.nido-hero__button:hover,
.nido-hero__button:focus-visible {
  transform: translateY(-1px);
}

.nido-hero__button--primary {
  background: var(--nido-hero-accent);
  color: #ffffff;
  box-shadow: 0 10px 30px rgba(106, 168, 66, 0.16);
}

.nido-hero__button--secondary {
  background: rgba(255, 255, 255, 0.03);
  color: #ffffff;
  border: 1px solid rgba(255, 255, 255, 0.28);
  backdrop-filter: blur(10px);
}

.nido-hero__button-icon {
  flex: 0 0 auto;
}

.nido-hero__media {
  position: relative;
  min-height: min(58svh, 760px);
  align-self: end;
  display: flex;
  align-items: end;
  justify-content: end;
}

.nido-hero__foreground {
  width: min(100%, 980px);
  max-height: 72svh;
  object-fit: contain;
  object-position: right bottom;
  filter: drop-shadow(0 32px 60px rgba(0, 0, 0, 0.45));
}

.nido-hero__scroll-indicator {
  position: absolute;
  left: 48px;
  bottom: 24px;
  display: inline-flex;
  align-items: center;
  gap: 12px;
  z-index: 1;
  color: rgba(255, 255, 255, 0.75);
  font-family: Montserrat, sans-serif;
  font-size: 12px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

.nido-hero__mouse {
  width: 24px;
  height: 38px;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,0.5);
  position: relative;
}

.nido-hero__mouse::before {
  content: '';
  position: absolute;
  top: 8px;
  left: 50%;
  width: 4px;
  height: 8px;
  border-radius: 999px;
  background: rgba(255,255,255,0.85);
  transform: translateX(-50%);
  animation: nidoHeroScroll 1.6s ease-in-out infinite;
}

@keyframes nidoHeroScroll {
  0% { opacity: 0; transform: translate(-50%, 0); }
  30% { opacity: 1; }
  100% { opacity: 0; transform: translate(-50%, 10px); }
}

@media (max-width: 1200px) {
  .nido-hero__inner {
    grid-template-columns: minmax(280px, 520px) 1fr;
    gap: 24px;
  }

  .nido-hero__foreground {
    width: min(100%, 820px);
  }
}

@media (max-width: 1024px) {
  .nido-hero {
    min-height: auto;
  }

  .nido-hero__inner {
    grid-template-columns: 1fr;
    grid-template-rows: auto auto;
    gap: 24px;
    align-items: end;
  }

  .nido-hero__content {
    max-width: 640px;
  }

  .nido-hero__media {
    min-height: auto;
    justify-content: center;
  }

  .nido-hero__foreground {
    width: min(100%, 760px);
    max-height: none;
    object-position: center bottom;
  }
}

@media (max-width: 767px) {
  .nido-hero__inner {
    padding: 32px 20px 32px;
    gap: 20px;
  }

  .nido-hero__eyebrow {
    margin-bottom: 16px;
    font-size: 12px;
  }

  .nido-hero__title {
    font-size: clamp(42px, 12vw, 58px);
    line-height: 0.98;
  }

  .nido-hero__description {
    margin-top: 20px;
    font-size: 17px;
    max-width: none;
  }

  .nido-hero__buttons {
    margin-top: 28px;
    flex-direction: column;
    align-items: stretch;
    gap: 12px;
  }

  .nido-hero__button {
    width: 100%;
    min-height: 52px;
    padding: 14px 20px;
  }

  .nido-hero__media {
    margin-top: 8px;
  }

  .nido-hero__foreground {
    width: 100%;
  }

  .nido-hero__scroll-indicator {
    display: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  .nido-hero__button,
  .nido-hero__mouse::before {
    transition: none;
    animation: none;
  }
}

/* Full viewport reale: usa variabili dedicate al widget, senza toccare quelle del tema. */
.elementor-widget-nido-hero-fullscreen .nido-hero.nido-hero--fit-viewport {
  min-height: calc(var(--nido-hero-viewport-height, 100dvh) - var(--nido-hero-header-height, 0px)) !important;
}

@supports not (height: 100dvh) {
  .elementor-widget-nido-hero-fullscreen .nido-hero.nido-hero--fit-viewport {
    min-height: calc(100vh - var(--nido-hero-header-height, 0px)) !important;
  }
}
