html {
  /* Activa el ajuste automático en el eje vertical */
  scroll-snap-type: y mandatory;
  scroll-behavior: smooth;
}

section {
  /* El margen de 20px que pediste originalmente */
  scroll-margin-top: 70px;

  /* Indica que la sección debe alinearse al inicio (start) del scroll */
  scroll-snap-align: start;

  /* Opcional: para asegurar que no se salte secciones al scrollear rápido */
  scroll-snap-stop: always;

}

.items {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  text-align: center;
}

.items div {
  padding: 10px 20px;
  border-radius: 10px;
  border: 1px solid gray;
  font-size: 20px;
  justify-content: center;
  display: grid;
  align-content: center;
  gap: 5px;
  backdrop-filter: blur(8px);
}

.items div span {
  font-size: 14px;
  display: block;
  color: gray;
}

.items div:hover,
.items div:hover span {
  color: white;
  background-color: gray;
}

.overlay {
  width: 100vw;
  height: 100%;
  position: absolute;
  left: 0px;
  top: 0px;
  z-index: -1;
}

.section-template {
  color: white;
  padding: 0px;
  min-height: calc(100vh - 70px);
  margin: 0px;
  position: relative;
  width: 100vw;
  max-width: 100vw;
  display: grid;
  align-items: center;
  justify-items: center;
}

.section-template h1,
.section-template p {
  color: white !important;
}

.section-template .title {
  font-size: 30px;
  text-transform: initial;
  margin-top: 0px;
}

.section-template .subtitle {
  font-size: 22px;
}

.section-template h2 {
  margin-top: 40px;
  margin-bottom: 5px;
  font-weight: 500;
  font-family: 'f2';
}

.content {
  display: grid;
  align-items: center;
  grid-template-columns: 70% 1fr;
  max-width: var(--anchoDesktop);
  min-width: var(--anchoDesktop);
  position: relative;
  margin: 0 auto;
  height: calc(100vh - 180px);
  font-size: 16px;
  /* overflow-y: scroll; */
  padding: 0px;

  overflow-y: hidden;
}

.content.to-right {
  justify-content: right;
  grid-template-columns: 1fr 70%;
}


.content.to-right h1 {
  text-align: right;
}

.slider-dots.to-right {
  right: inherit;
  left: 25px;
}

.content.to-right h1::after {
  right: 0px;
  left: inherit;
}

.content.to-right>div:nth-child(1) {
  grid-column: 2;
}

.content.to-right>div:nth-child(2) {
  grid-column: 1;
}

.content.to-right .btn3 {
  float: right;
}

.content.text-black,
.content.text-black h1 {
  color: var(--negro2) !important;
}

.content.white,
.content.white h1,
.content.white a {
  color: #ffffff !important;
}

.slider-template {
  position: absolute;
  top: 0px;
  right: 0px;
  height: 100%;
  gap: 15px;
  width: 100vw;
  z-index: -2;
  background-repeat: no-repeat;
  background-position: center right;
  background-size: cover;
  transition: all 1s;
}

.slider-dots {
  display: flex;
  justify-content: center;
  flex-direction: column;
  align-items: flex-end;
  position: absolute;
  right: 40px;
  top: 0px;
  height: 100%;
  gap: 10px;
}

.slider-template-image {
  object-fit: cover;
  object-position: center right;
  width: 100vw;
  height: 100%;
  border: none;
  position: absolute;
  right: 0px;
  top: 0px;
  opacity: 0;
  transition: opacity 1s;
}

.slider-template-image.active {
  opacity: 1;
}

.section-template .dot {
  background-color: white;
  cursor: pointer;
  opacity: 0.5;
  width: 15px;
  height: 15px;
  border-radius: 15px;
}



.section-template .dot:hover,
.section-template .dot.active {
  opacity: 1;
}

.scroll {
  display: grid;
  grid-template-columns: 40px 1fr;
  gap: 10px;
  height: calc(100vh - 220px);
}

.data {
  /* display: grid; */
  align-items: center;
  position: relative;
  height: calc(100vh - 280px);
  font-size: 16px;
  padding: 0px;
  scrollbar-width: none;
  -ms-overflow-style: none;

  &::-webkit-scrollbar {
    display: none;
  }

  overflow-y: auto;
  border-left: 1px solid #99999955;
  border-image: linear-gradient(to bottom, transparent 1%, #999999, transparent 90%) 1;
  padding-left: 20px;
}

.data ul {
  position: relative;
  text-align: left;
  /* padding: 0 25%; */
}

.data .btn-container {
  display: inline-block;
}

.data .btn3 {
  width: inherit;
  padding: 0px 20px;
}

.controls {
  display: grid;
  align-items: center;
  position: relative;
  top: -30px;
  height: 100px;
  margin: auto;
}

.up,
.down {
  background-image: url(/assets/images/flecha-abajo-2.svg);
  background-repeat: no-repeat;
  background-position: center;
  background-size: contain;
  width: 20px;
  height: 40px;
  filter: saturate(0);
  opacity: 0.7;
}

.up {
  transform: rotate(180deg);
}

.up:hover,
.down:hover {
  filter: none;
  cursor: pointer;
  opacity: 1;
}

.up.locked,
.down.locked {
  cursor: default;
  opacity: 0.3;
  pointer-events: none;
}

@media (width < 1280px) {
  .main .desktop {
    gap: 20px !important;
  }
}

@media (width < 600px) {
  html {
    scroll-snap-type: inherit;
    scroll-behavior: inherit;
  }

  section {
    scroll-margin-top: inherit;
    scroll-snap-align: inherit;
    scroll-snap-stop: inherit;
  }

  .headerTop {
    height: 70px;
  }

  .items {
    grid-template-columns: repeat(1, 1fr);
  }

  .content {
    grid-template-columns: 1fr;
    height: auto;
    overflow: inherit;
    padding: 30px;
    min-width: inherit;
  }

  .content.to-right h1 {
    justify-content: inherit;
    text-align: inherit;
    grid-template-columns: inherit;
  }

  .slider-dots {
    display: none;
  }

  .slider-dots.to-right {
    right: inherit;
    left: inherit;
  }

  .content.to-right h1::after {
    right: inherit;
    left: inherit;
    left: 0px;
  }

  .content.to-right>div:nth-child(1) {
    grid-column: inherit;
  }

  .content.to-right>div:nth-child(2) {
    grid-column: inherit;
  }

  .content.to-right .btn3 {
    float: none;
  }
}
