/* hero-module */

.hero-module {
  position: relative;
  overflow: visible;
}

/* hero video */

.hero-background-video {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 1;
  overflow: hidden;
}

.hero-background-video::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: transparent;
}

.hero-background-video .hero-video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.hero-video-toggle {
  position: absolute;
  bottom: 40px;
  right: 60px;
  z-index: 10;
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 0;
  width: 30px;
  height: 30px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.hero-video-toggle .icon-play {
  display: none;
}

.hero-video-toggle.is-paused .icon-pause {
  display: none;
}

.hero-video-toggle.is-paused .icon-play {
  display: flex;
}

/* Hero-full */

.hero-module.hero-full {
  display: flex;
  align-items: center;
}

.hero-module.hero-full .container-hero-slider {
  width: 100%;
  height: 85vh;
}

.hero-module.hero-full .hero-slide {
  position: relative;
  height: 100%;
  display: flex;
  align-items: center;
}

.hero-module.hero-full .hero-background-image {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 1;
}

.hero-module.hero-full .hero-background-image::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
}

.hero-module.hero-full .hero-background-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-module.hero-full .hero-content {
  position: relative;
  z-index: 2;
  max-width: 500px;
  padding: 33px 36px 53px;
  margin-left: 60px;
}

.hero-module .lpm-form__title,.hero-module .lpm-form .panel__first .step-01__amounts label{
  color: var(--color-primary) !important;
  font-family: var(--typo-title-1-font)!important;
  font-size: var(--typo-title-1-size)!important;
  font-weight: var(--typo-title-1-fw)!important;
  line-height: var(--typo-title-1-lh)!important;
  letter-spacing: var(--typo-title-1-ls)!important;
  text-transform: uppercase !important;
}

.hero-module .lpm-form .panel__first .step-01__amounts a.text--tooltip{
  color: var(--color-primary) !important;
}

.hero-module .lpm-form .panel__first .step-01__amounts .d-grid.col button{
  padding: 13px 24px !important;
  border: 2px solid var(--color-primary) !important;
  color: var(--color-primary) !important;
  border-radius: 16px !important;
  font-family: var(--typo-display-2-font) !important;
  font-size: var(--typo-display-2-size) !important;
  font-weight: var(--typo-display-2-fw) !important;
  line-height: var(--typo-display-2-lh) !important;
  letter-spacing: var(--typo-display-2-ls) !important;
}

.hero-module .lpm-embed .lpm-form .panel__first .step-01__amounts .d-grid.col button.btn-outline-dark.active,.hero-module .lpm-embed .lpm-form .panel__first .step-01__amounts .d-grid.col button:hover{
  background-color: var(--color-primary) !important;
  color: var(--color-background-white) !important;
}

.hero-module .lpm-form .panel__first .row.g-2.justify-content-end button{
  padding: 13px 40px !important;
  border: 2px solid var(--color-primary) !important;
  color: var(--color-background-white) !important;
  border-radius: 36px !important;
  font-family: var(--typo-title-2-bold-font);
  font-size: var(--typo-title-2-size);
  font-weight: var(--typo-title-2-bold-fw);
  line-height: var(--typo-title-2-bold-lh);
  letter-spacing: var(--typo-title-2-bold-ls);
  background-color: var(--color-primary) !important;
  text-transform: uppercase !important;
}

.hero-module .lpm-form .panel__second .step-02__recordstype .d-grid.col-md-6 button{
  padding: 13px 24px !important;
  border: 2px solid var(--color-primary) !important;
  color: var(--color-primary) !important;
  border-radius: 16px !important;
  font-family: var(--typo-display-2-font) !important;
  font-size: var(--typo-display-2-size) !important;
  font-weight: var(--typo-display-2-fw) !important;
  line-height: var(--typo-display-2-lh) !important;
  letter-spacing: var(--typo-display-2-ls) !important;
  background: var(--color-background-white) !important;
}

.hero-module .lpm-form .panel__second .step-02__recordstype .d-grid.col-md-6 button:hover{
  background-color: var(--color-primary) !important;
  color: var(--color-background-white) !important;
}

.hero-module .lpm-form .panel__second .step-02__recordstype label{
  font-family: var(--typo-title-2-bold-font);
  font-size: var(--typo-title-2-size);
  font-weight: var(--typo-title-2-bold-fw);
  line-height: var(--typo-title-2-bold-lh);
  letter-spacing: var(--typo-title-2-bold-ls);
}

.hero-module .lpm-form .panel__second .form-check label{
  font-family: var(--typo-title-2-bold-font);
  font-size: var(--typo-title-2-size);
  font-weight: var(--typo-title-2-bold-fw);
  line-height: var(--typo-title-2-bold-lh);
  letter-spacing: var(--typo-title-2-bold-ls);
}

.hero-module .lpm-form .panel__second .form-check label a{
  color: var(--color-primary) !important;
}

.hero-module .lpm-form .panel__second .row.g-2.justify-content-end .d-grid.col-md:first-of-type button{
  padding: 13px 40px !important;
  border: 2px solid var(--color-primary) !important;
  color: var(--color-primary) !important;
  border-radius: 36px !important;
  font-family: var(--typo-title-2-bold-font);
  font-size: var(--typo-title-2-size);
  font-weight: var(--typo-title-2-bold-fw);
  line-height: var(--typo-title-2-bold-lh);
  letter-spacing: var(--typo-title-2-bold-ls);
  background-color: var(--color-background-white) !important;
  text-transform: uppercase !important;
}

.hero-module .lpm-form .panel__second .row.g-2.justify-content-end .col-md.d-grid button{
  padding: 13px 40px !important;
  border: 2px solid var(--color-primary) !important;
  color: var(--color-background-white) !important;
  border-radius: 36px !important;
  font-family: var(--typo-title-2-bold-font);
  font-size: var(--typo-title-2-size);
  font-weight: var(--typo-title-2-bold-fw);
  line-height: var(--typo-title-2-bold-lh);
  letter-spacing: var(--typo-title-2-bold-ls);
  background-color: var(--color-primary) !important;
  text-transform: uppercase !important;
}

.hero-module .lpm-form .panel__second .row.g-2.justify-content-end .col-md.d-grid button:disabled{
  padding: 13px 40px !important;
  border: 2px solid var(--color-primary) !important;
  color: var(--color-primary) !important;
  border-radius: 36px !important;
  font-family: var(--typo-title-2-bold-font);
  font-size: var(--typo-title-2-size);
  font-weight: var(--typo-title-2-bold-fw);
  line-height: var(--typo-title-2-bold-lh);
  letter-spacing: var(--typo-title-2-bold-ls);
  background-color: var(--color-background-white) !important;
  text-transform: uppercase !important;
}

.hero-module.hero-full .hero-title {
  margin-bottom: 20px;
  margin-top: 0;
}

.hero-module.hero-full .hero-text {
  margin-bottom: 0px;
}

.hero-module.hero-full .hero-text p{
  margin: 0;
}

.hero-module.hero-full .hero-btn {
  position: absolute;
  bottom: 0;
  right: 37px;
  transform: translateY(50%); 
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--color-background-white);
  padding: 15px;
  text-decoration: none;
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  overflow: hidden;
  white-space: nowrap;
}

.hero-module.hero-full .hero-btn span {
  display: inline-block;
  max-width: 0;
  opacity: 0;
  margin-right: 0;
  overflow: hidden;
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  text-transform: uppercase;
}

.hero-module.hero-full .hero-btn::after {
  content: '';
  width: 24px;
  height: 24px;
  background-image: url('../../assets/east.svg');
  background-size: contain;
  background-repeat: no-repeat;
  background-position: center;
  transition: transform 0.3s ease;
  flex-shrink: 0;
}

.hero-module.hero-full .hero-btn:hover {
  width: auto;
}

.hero-module.hero-full .hero-btn:hover span {
  opacity: 1;
  transform: translateX(0);
  max-width: 300px;
  margin-right: 10px;
}

.hero-module.hero-full .hero-btn:hover::after {
  transform: translateX(5px);
}

/* Pagination */
.hero-module.hero-full .swiper-pagination {
  position: absolute;
  bottom: 40px;
  left: 0;
  right: 0;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: flex-end; 
  gap: 20px;
  z-index: 10;
  counter-reset: pagination;
  padding-right: 140px;
  padding-left: 60px; 
}

.hero-module.hero-full .swiper-pagination-bullet {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  width: auto;
  height: auto;
  background: transparent;
  opacity: 1;
  margin: 0;
  border-radius: 0;
  font-family: var(--typo-title-2-bold-font);
  font-size: var(--typo-title-2-size);
  font-weight: var(--typo-title-2-bold-fw);
  line-height: var(--typo-title-2-bold-lh);
  letter-spacing: var(--typo-title-2-bold-ls);
  position: relative;
  padding-bottom: 10px;
  transition: all 0.3s ease;
  cursor: pointer;
}

.hero-module.hero-full .swiper-pagination-bullet::before {
  content: counter(pagination, decimal-leading-zero) '.';
  counter-increment: pagination;
  margin-bottom: 5px;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.hero-module.hero-full .swiper-pagination-bullet::after {
  content: '';
  width: 60px;
  height: 2px;
  background: var(--color-background-white);
  transition: all 0.3s ease;
}

.hero-module.hero-full .swiper-pagination-bullet-active {
  color: var(--color-background-white);
}

.hero-module.hero-full .swiper-pagination-bullet-active::before {
  opacity: 1; 
}

.hero-module.hero-full .swiper-pagination-bullet-active::after {
  background: var(--color-primary);
  height: 6px;
}

/* Navigation Buttons */
.hero-module.hero-full .hero-nav-prev,
.hero-module.hero-full .hero-nav-next {
  position: absolute;
  bottom: 50px;
  width: 30px;
  height: 30px;
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 0;
  transition: all 0.3s ease;
  z-index: 10;
}

.hero-module.hero-full .hero-nav-prev svg,
.hero-module.hero-full .hero-nav-next svg {
  display: block;
  width: 16px;
  height: 24px;
  transition: transform 0.3s ease, filter 0.3s ease;
}

.hero-module.hero-full .hero-nav-prev svg path,
.hero-module.hero-full .hero-nav-next svg path {
  stroke: var(--color-background-white);
}

.hero-module.hero-full .hero-nav-prev svg {
  transform: rotate(180deg);
}

.hero-module.hero-full .hero-nav-prev {
  right: 80px;
}

.hero-module.hero-full .hero-nav-next {
  right: 40px;
}

.hero-module.hero-full .hero-nav-prev.swiper-button-disabled svg ,
.hero-module.hero-full .hero-nav-next.swiper-button-disabled svg {
  opacity: 0.5;
}

.hero-module.hero-full .hero-nav-prev.swiper-button-disabled,
.hero-module.hero-full .hero-nav-next.swiper-button-disabled {
  cursor: default;
}

/* Hero-mid */

.hero-module.hero-mid {
  min-height: 60vh;
  position: relative;
  margin-bottom: 0;
}

.hero-module.hero-mid .container-hero-slider {
  width: 100%;
  height: 67vh;
  position: relative;
  overflow: visible;
}

.hero-module.hero-mid .hero-slide {
  position: relative;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: visible;
}

.hero-module.hero-mid .hero-background-image {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 1;
}

.hero-module.hero-mid .hero-background-image picture {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.hero-module.hero-mid .hero-background-image::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 1;
}

.hero-module.hero-mid .hero-background-image.has-gradient::after {
  background: linear-gradient(0deg, rgba(0, 0, 0, 0) 0%, rgba(0, 0, 0, 0.15) 63.42%, rgba(0, 0, 0, 0.5) 76.31%);
}

.hero-module.hero-mid .hero-background-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-module.hero-mid .hero-content {
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translate(-50%, 50%);
  z-index: 100; 
  padding: 40px;
  width: 100%;
  max-width: 70%;
  pointer-events: auto; 
}

.hero-module.hero-mid .hero-content:has(.container-content-right) {
  display: flex;
  align-items: center;
  gap: 16px;
}

.hero-module.hero-mid .hero-content:has(.container-content-right) .container-content-right {
  display: flex;
}

.hero-module.hero-mid .hero-content:has(.container-content-right) .container-content-right img {
  max-width: 179px;
  aspect-ratio: 1 / 1;
  object-fit: cover;
}

.hero-module.hero-mid .hero-title {
  margin-bottom: 16px;
  margin-top: 16px;
}

.hero-module.hero-mid .hero-text {
  margin-bottom: 0;
}

.hero-module.hero-mid .hero-content.has-cta .hero-text {
  margin-bottom: 40px;
}

.hero-module.hero-mid .hero-btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--color-background-white);
  padding: 14px 35px;
  text-decoration: none;
  text-transform: uppercase;
  border-radius: 50px;
}

.hero-module.hero-mid .swiper-pagination,
.hero-module.hero-mid .hero-nav-prev,
.hero-module.hero-mid .hero-nav-next {
  display: none;
}

.hero-module.hero-mid .swiper,
.hero-module.hero-mid .swiper-wrapper,
.hero-module.hero-mid .swiper-slide {
  overflow: visible;
}

.hero-mid + * {
  position: relative;
  transition: padding-top 0.3s ease;
}

/* Hero-small */

.hero-module.hero-small {
  min-height: 200px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 60px 20px;
}

.hero-module.hero-small .hero-content-small {
  text-align: center;
  margin: 0 auto;
}

.hero-module.hero-small .hero-title {
  margin: 0;
}



/* Nascondi il modale all'inizio */
.custom-video-modal-overlay {
    display: none; 
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background-color: rgba(0, 0, 0, 0.85); /* Sfondo scuro semitrasparente */
    z-index: 9999; /* Sopra tutto il resto */
    backdrop-filter: blur(5px);
}

/* Contenitore centrato */
.custom-video-modal-content {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 90%;
    max-width: 900px;
    background: #000;
    border-radius: 8px;
    overflow: hidden;
}

/* Bottone di chiusura */
.close-video-modal {
    position: absolute;
    background: transparent;
    border: none;
    color: white;
    font-size: 25px;
    cursor: pointer;
}

/* Container del video */
.video-container {
    width: 100%;
    aspect-ratio: 16 / 9; /* Mantiene le proporzioni classiche del video */
    background: #000;
    display: flex;
    justify-content: center;
    align-items: center;
}

@media (min-width: 992px) {
    .hero-mid + * {
        opacity: 0;
        transition: opacity 0.3s ease;
    }

    .hero-mid + *.hero-spacing-ready {
        opacity: 1;
    }
}

@media (max-width: 1024px) {
  .hero-module.hero-mid .hero-content {
    width: 85%;
  }
}

@media (max-width: 992px) {
  .hero-module.hero-full .hero-content {
    margin-left: 5%;
    margin-right: 5%;
    padding: 40px 30px;
  }

  .hero-module.hero-mid .hero-content:has(.container-content-right) {
    flex-direction: column;
  }

  .hero-module.hero-mid .hero-content:has(.container-content-right) .container-content-right {
    width: 100%;
  }

  .hero-module.hero-full .hero-btn {
    width: auto;
  }
  
  .hero-module.hero-full .hero-btn span {
    opacity: 1;
    transform: translateX(0);
    max-width: none;
    margin-right: 10px;
  }

  .hero-module.hero-full .swiper-pagination {
    justify-content: flex-start;
    padding-left: 20px;
    padding-right: 120px;
    gap: 15px;
  }
  
  .hero-module.hero-full .swiper-pagination-bullet::after {
    width: 30px;
  }
  
  .hero-module.hero-full .hero-nav-prev {
    right: 60px;
  }
  
  .hero-module.hero-full .hero-nav-next {
    right: 20px;
  }

  .hero-module.hero-mid {
    min-height: auto;
  }

  .hero-module.hero-mid .container-hero-slider {
    height: auto;
  }

  .hero-module.hero-mid .hero-slide {
    height: auto;
    flex-direction: column;
    align-items: stretch;
  }

  .hero-module.hero-mid .hero-background-image {
    position: relative;
    width: 100%;
    height: 50vh;
  }

  .hero-module.hero-mid .hero-content {
    max-width: 100%;
    padding: 30px 20px;
    margin: 0;
    transform: translate(-50%, 80%);
  }

  .hero-module.hero-mid .hero-btn {
    padding: 12px 28px;
  }

  .hero-module.hero-mid .hero-topics-container {
    flex-direction: column;
  }

  .hero-module.hero-mid .hero-topics-container .hero-topic-badge{
    width: fit-content;
  }

  .hero-video-toggle {
    right: 20px;
  }

  .hero-module.hero-mid .hero-content:has(.container-content-right) .container-content-right img {
    max-width: 100%;
    aspect-ratio: 1 / 1;
    object-fit: cover;
  }
}
