/* =========================================================
   GS PRODUCT HERO – FULL WIDTH + SAFE REVEAL
   - Layout mobile stabile: GRID invece di FLEX su __inner
   - Reveal mask: non può mai “chiudere” il contenuto per sempre
   ========================================================= */

.gs-product-hero{
  position: relative;
  width: 100%;
  padding: clamp(20px, 3vw, 40px) 0;
}

/* Full-bleed su desktop anche dentro container */
@media (min-width: 769px){
  .gs-product-hero{
    width: 100vw;
    max-width: 100vw;
    position: relative;
    left: 50%;
    right: 50%;
    margin-left: -50vw;
    margin-right: -50vw;
  }
}

/* =========================
   LAYOUT BASE (GRID)
   ========================= */
@media (min-width: 769px){

  .gs-product-hero__inner{
    position: relative;
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: clamp(16px, 2vw, 32px);
    align-items: stretch;
  }
}

/* Colonne */
.gs-product-hero__media,
.gs-product-hero__content{
  position: relative;
  min-width: 0;
}

@media (min-width: 769px){

/* Media */
.gs-product-hero__media{
  min-height: 600px;
  overflow: hidden;
  position: relative; /* per la mask */
  display: block;
}
}

/* =========================
   IMMAGINE – FULL COVER
   ========================= */
.gs-product-hero__img{
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
  object-position: left center;
}

/* Placeholder se manca l’immagine */
.gs-product-hero__img-placeholder{
  width: 100%;
  min-height: 280px;
  display: grid;
  place-items: center;
  background: #f3f3f3;
}

/* =========================
   REVEAL MASK (SAFE)
   - DEFAULT: fuori (non copre)
   - is-reveal: copre
   - is-in: anima via e torna fuori
   ========================= */
.gs-product-hero__media::after{
  content: "";
  position: absolute;
  inset: 0;
  background: #fff;
  transform: translateX(100%); /* default: fuori => NON copre */
  z-index: 2;
  pointer-events: none;
  will-change: transform;
}

.gs-product-hero__media.is-reveal::after{
  transform: translateX(0);
}

.gs-product-hero__media.is-in::after{
  animation: gsRevealMask 900ms cubic-bezier(.4,0,.2,1) forwards;
}

@keyframes gsRevealMask{
  from { transform: translateX(0); }
  to   { transform: translateX(100%); }
}

/* Accessibilità / iOS: se reduce motion è attivo, la mask deve essere SEMPRE fuori */
@media (prefers-reduced-motion: reduce){
  .gs-product-hero__media::after,
  .gs-product-hero__media.is-reveal::after,
  .gs-product-hero__media.is-in::after{
    animation: none !important;
    transform: translateX(100%) !important;
  }
}

/* =========================
   TITOLO OVERLAY
   ========================= */
.gs-product-hero__title{
  position: absolute;
  z-index: 3;
  padding: 8px 13px;
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  height: 80px;
  border-radius: 7px;
}

.gs-product-hero__title--desktop{
  top: 18px;
  left: -29%;
  max-width: 120%;
}

.gs-product-hero__title--mobile{
  display: none;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  text-align: center;
  max-width: calc(100% - 32px);
}

/* =========================
   CONTENUTO
   ========================= */
.gs-product-hero__description{
  padding-top: 120px;
  width: 70%;
  margin: auto;
}

.gs-product-hero .gs-product-hero__description p{
  font-size: 16px !important;
  line-height: 1.6;
}

.gs-product-hero__cta{
  margin-top: 18px;
}

.gs-product-hero__link{
  display: inline-block;
  padding: 12px 18px;
  border: 1px solid currentColor;
  text-decoration: none;
}

/* =========================
   MOBILE
   ========================= */
@media (max-width: 768px){
  .gs-product-hero__inner{
    grid-template-columns: 1fr;
  }

  .gs-product-hero__media{
    /* min-height: 55vh; */
  }

  .gs-product-hero__title--desktop{
    display: none;
  }

  .gs-product-hero__title--mobile{
    display: block;
  }

  .gs-product-hero__description{
    padding-top: 0;
    margin-top: 14px;
    width: 90%;
  }
}
