/* 1.1 CAROUSEL JOURNEY */

.carousel-wrapper {
  position: relative;
  width: 100%;
}

.carousel {
  width: 100%;
  overflow: hidden;
}

.carousel-track {
  display: flex;
  gap: 24px;
  transition: transform 0.45s ease;
  will-change: transform;
}

.carousel-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 10;

  width: 48px;
  height: 48px;
  border-radius: 50%;
  border: none;

  background-color: #2f6df6;
  color: white;
  font-size: 22px;

  cursor: pointer;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}

.carousel-btn.prev {
  left: -90px;
}

.carousel-btn.next {
  right: -90px;
}

.carousel-btn:hover {
  background-color: #103cb5;
}

.carousel-dots {
  display: flex;
  justify-content: center;
  gap: 10px;
  margin-top: 40px;
}

.carousel-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background-color: rgba(0, 0, 0, 0.25);
  transition: all 0.25s ease;
}

.carousel-dot.active {
  width: 18px;
  border-radius: 999px;
  background-color: #2f6df6;
}

/* 1.2 WEEK CARD in the Carousel (Journey Section) */

.week-card {
  flex: 0 0 calc((100% - (3 * 24px)) / 4);
  background-color: #ffffff;
  border-radius: 28px;
  padding: 26px;
  min-height: 340px;

  display: flex;
  flex-direction: column;
  justify-content: space-between;

  text-decoration: none;
  color: inherit;

  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.week-card:hover {
  transform: translateY(30px);
  box-shadow: 0 25px 25px rgba(0, 0, 0, 0.205);
}

.week-number {
  font-size: 0.85rem;
  font-weight: 700;
  color: #2f6df6;
}

.week-card h3 {
  font-size: 1.2rem;
  font-weight: 800;
  margin: 8px 0;
}

.week-card img {
  width: 100%;
  height: 150px;
  object-fit: cover;
  border-radius: 18px;
}

.week-card p {
  font-size: 0.95rem;
  opacity: 0.85;
}

/* 2 INFINITE CAROUSEL */
.inf-carousel {
  overflow: hidden;
  width: 100%;
  padding: 40px 0;
}

.inf-carousel-track {
  display: flex;
  gap: 32px;
  width: max-content;
  animation: scroll 30s linear infinite;
}

.inf-carousel-item {
  position: relative;
  flex-shrink: 0;
  width: 320px;
  height: 200px;
  border-radius: 16px;
  overflow: hidden;
}

.inf-carousel-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* hover text */
.inf-caption {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0,0,0,0.55);
  color: white;
  font-size: 1rem;
  font-weight: 500;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.inf-carousel-item:hover .caption {
  opacity: 1;
}

/* pause animation on hover */
.inf-carousel:hover .carousel-track {
  animation-play-state: paused;
}

/* 3 FOLDER TABS */

.tabs-wrapper {
  max-width: 1800px;
  margin: 0 auto;
  font-family: sans-serif;
}

.slanted-tabs {
  display: flex;
  margin-left: 20px;
  position: relative;
  overflow: hidden; /* 🔥 Evita que el pico se salga */
}

.tab-link {
  position: relative;
  padding: 12px 30px;
  border: none;
  border-radius: 0 15px 0px 0;
  background: none;
  cursor: pointer;
  font-weight: bold;
  color: white; /* Color del texto en pestañas inactivas */
  transition: 0.3s;
  z-index: 1;
  overflow: hidden; /* 🔥 Asegura que el pseudo-elemento no sobresalga */
}

/* Fondo inclinado tipo folder */
.tab-link::before {
  content: '';
  position: absolute;
  inset: 0; /* reemplaza top/left/right/bottom */
  background: #2f72f0;
  transform: skewX(-15deg);
  transform-origin: left bottom; /* 🔥 controla dirección del pico */
  border-radius: 15px 15px 0 0;
  z-index: -1;
  transition: 0.3s;
}

/* Pestaña Activa */
.tab-link.active {
  color: #2f72f0;
}

.tab-link.active::before {
  background: white;
  transform: skewX(-15deg) translateY(0px);
}

/* Contenedor de contenido blanco */
.tab-main-content {
  background: white;
  padding: 40px;
  border-radius: 15px 15px 15px 15px;
  min-height: 300px;
  position: relative;
  z-index: 2;
  margin-top: 0px; /* Une la pestaña con el cuadro */
}

/* Control de visibilidad */
.tab-panel {
  display: none;
  animation: fadeIn 0.4s ease;
}

.tab-panel.active {
  display: block;
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}


/* Contenedor principal */
.step-carousel-container {
  position: relative;
  width: 100%;
  margin: 20px 0;
}

/* La ventana que recorta el contenido */
.step-carousel-window {
  overflow: hidden;
  width: 100%;
  border-radius: 15px;
}

/* La tira larga que se mueve */
.step-carousel-track {
  display: flex;
  transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Cada grupo de 2 pasos */
.step-slide {
  min-width: 100%; /* Cada slide ocupa todo el ancho */
  display: grid;
  grid-template-columns: 1fr 1fr; /* Dividir en 2 columnas iguales */
  gap: 20px;
  padding: 10px;
}

/* Estilo de cada paso individual mejorado */
.step-item {
  background: white;
  padding: 15px;
  border-radius: 12px;
  box-shadow: 0 4px 10px rgba(0,0,0,0.05);
  text-align: center;
  display: flex;         /* Agregado para centrar contenido */
  flex-direction: column; /* Agregado para alinear verticalmente */
  align-items: center;    /* Centra todo horizontalmente */
}

.step-item img {
  width: auto;            /* Cambiado de 100% a auto */
  max-width: 100%;       /* Asegura que no se salga del cuadro */
  max-height: 350px;      /* Evita que imágenes verticales sean demasiado largas */
  border-radius: 8px;
  margin-top: 15px;
  display: block;
}

/* Botones de navegación flotantes */
.step-nav-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: #2f72f0;
  color: white;
  border: none;
  width: 45px;
  height: 45px;
  border-radius: 50%;
  cursor: pointer;
  z-index: 10;
  font-size: 20px;
}

.step-nav-btn.prev { left: -25px; }
.step-nav-btn.next { right: -25px; }
.step-nav-btn:hover { background: #103cb5; }