/**
 * @file
 * Estilos para el módulo de Tecnologías - Carrusel
 * Drupal 10 - Bootstrap 5
 */

/* Variables de colores */
:root {
  --h-tec-color-primary: #0066CC;
  --h-tec-color-secondary: #E20145;
  --h-tec-color-text: #333333;
  --h-tec-color-text-light: #666666;
}

/* Sección de Tecnologías */
.tecnologias-section {
  background-color: #ffffff;
  padding: 60px 0;
}

/* Header de la sección */
.tecnologias-section .section-header {
  display: flex;
  align-items: center;
  gap: 15px;
}

.tecnologias-section .red-bar {
  width: 11px;
  height: 70px;
  background-color: var(--h-tec-color-secondary);
  flex-shrink: 0;
}

.tecnologias-section {
  font-size: 2.5rem;
  font-weight: 400;
  color: var(--h-tec-color-primary);
  margin: 0;
}

/* Carrusel personalizado */
#tecnologiasCarousel {
  position: relative;
}

#tecnologiasCarousel .carousel-inner {
  border-radius: 0;
  max-width: 900px;
  margin: 0 auto;
}

/* Tarjeta del carrusel */
.tecnologias-section .carousel-card {
  background: #ffffff;
  border: 2px solid #d0d0d0;
  border-radius: 0;
  overflow: hidden;
  box-shadow: none;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.tecnologias-section .carousel-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

/* Contenedor de imagen */
.tecnologias-section .card-image-container {
  position: relative;
  width: 100%;
  height: 450px;
  overflow: hidden;
}

.tecnologias-section .card-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: none;
}

/* Overlay de la imagen */
.tecnologias-section .card-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(
    to bottom,
    rgba(0, 0, 0, 0) 0%,
    rgba(0, 0, 0, 0.3) 50%,
    rgba(0, 0, 0, 0.6) 100%
  );
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  padding: 40px;
}

/* Logo del proyecto */
.tecnologias-section .project-logo {
  margin-bottom: 20px;
  filter: drop-shadow(0 2px 8px rgba(0, 0, 0, 0.3));
}

.tecnologias-section .project-logo svg {
  display: block;
}

/* Título del proyecto */
.tecnologias-section .project-title {
  text-align: center;
  color: white;
}

.tecnologias-section .project-label {
  display: block;
  font-size: 1rem;
  font-weight: 300;
  letter-spacing: 1px;
  margin-bottom: 5px;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
}

.tecnologias-section .project-title h3 {
  font-size: 3rem;
  font-weight: 700;
  margin: 0;
  letter-spacing: 2px;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.7);
}

/* Contenido de la tarjeta */
.tecnologias-section .card-content {
  padding: 30px;
  background-color: #ffffff;
}

.tecnologias-section .card-title {
  font-size: 1.5rem;
  font-weight: 600;
  color: var(--h-tec-color-secondary);
  margin-bottom: 15px;
}

.tecnologias-section .card-description {
  font-size: 1rem;
  color: var(--h-tec-color-text-light);
  line-height: 1.6;
  margin-bottom: 20px;
}

/* Botón de reproducción */
.tecnologias-section .btn-play {
  background-color: transparent;
  border: none;
  color: var(--h-tec-color-text);
  font-size: 2rem;
  cursor: pointer;
  padding: 0;
  transition: color 0.3s ease, transform 0.3s ease;
  width: auto;
  display: inline-block;
  width: 100%;
}

.tecnologias-section .btn-play:hover {
  color: var(--h-tec-color-secondary);
  transform: scale(1.1);
}

.tecnologias-section .btn-play:focus {
  outline: 2px solid var(--h-tec-color-primary);
  outline-offset: 2px;
}

/* Controles del carrusel */
#tecnologiasCarousel .carousel-control-prev,
#tecnologiasCarousel .carousel-control-next {
  width: 100px;
  opacity: 1;
  transition: opacity 0.3s ease;
}

#tecnologiasCarousel .carousel-control-prev:hover,
#tecnologiasCarousel .carousel-control-next:hover {
  opacity: 0.7;
}

#tecnologiasCarousel .carousel-control-icon {
  background-color: transparent;
  border-radius: 0;
  width: auto;
  height: auto;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: none;
  transition: all 0.3s ease;
}

#tecnologiasCarousel .carousel-control-prev:hover .carousel-control-icon svg path,
#tecnologiasCarousel .carousel-control-next:hover .carousel-control-icon svg path {
  stroke: #000000;
}

#tecnologiasCarousel .carousel-control-prev {
  left: 20px;
  justify-content: flex-start;
}

#tecnologiasCarousel .carousel-control-next {
  right: 20px;
  justify-content: flex-end;
}

/* Indicadores del carrusel */
#tecnologiasCarousel .carousel-indicators {
  margin-bottom: -40px;
  display: none;
}

#tecnologiasCarousel .carousel-indicators [data-bs-target] {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background-color: #cccccc;
  border: none;
  opacity: 0.5;
  transition: all 0.3s ease;
}

#tecnologiasCarousel .carousel-indicators .active {
  opacity: 1;
  background-color: var(--h-tec-color-secondary);
  width: 14px;
  height: 14px;
}

/* Responsive */
@media (max-width: 992px) {
  .tecnologias-section .section-title {
    font-size: 2rem;
  }

  .tecnologias-section .card-image-container {
    height: 400px;
  }

  .tecnologias-section .project-title h3 {
    font-size: 2.5rem;
  }

  #tecnologiasCarousel .carousel-control-prev {
    left: 5px;
  }

  #tecnologiasCarousel .carousel-control-next {
    right: 5px;
  }

  #tecnologiasCarousel .carousel-control-prev,
  #tecnologiasCarousel .carousel-control-next {
    width: 60px;
  }

  #tecnologiasCarousel .carousel-control-icon svg {
    width: 30px;
    height: 50px;
  }
}

@media (max-width: 768px) {
  .tecnologias-section .section-title {
    font-size: 1.75rem;
  }

  .tecnologias-section .red-bar {
    height: 50px;
    width: 8px;
  }

  .tecnologias-section .card-image-container {
    height: 300px;
  }

  .tecnologias-section .project-title h3 {
    font-size: 2rem;
  }

  .tecnologias-section .card-content {
    padding: 20px;
  }

  #tecnologiasCarousel .carousel-control-icon {
    width: 50px;
    height: 50px;
  }

  #tecnologiasCarousel .carousel-control-icon svg {
    width: 25px;
    height: 45px;
  }

  #tecnologiasCarousel .carousel-control-prev,
  #tecnologiasCarousel .carousel-control-next {
    width: 50px;
  }
}

@media (max-width: 576px) {
  .tecnologias-section {
    padding: 40px 0;
  }

  .tecnologias-section .section-title {
    font-size: 1.5rem;
  }

  .tecnologias-section .card-image-container {
    height: 250px;
  }

  .tecnologias-section .project-title h3 {
    font-size: 1.5rem;
  }

  .tecnologias-section .project-label {
    font-size: 0.875rem;
  }

  .tecnologias-section .card-title {
    font-size: 1.25rem;
  }

  .tecnologias-section .card-description {
    font-size: 0.9rem;
  }
}

/* Botón pausa/play */
.tecnologias-section .carousel-pause-play {
  margin-top: 10px;
}

.tecnologias-section .btn-pause-play {
  background: none;
  border: none;
  cursor: pointer;
  color: var(--h-tec-color-text);
  padding: 5px;
  transition: color 0.3s ease;
}

.tecnologias-section .btn-pause-play:hover {
  color: var(--h-tec-color-secondary);
}

/* Enlaces dentro de la tarjeta */
.tecnologias-section .card-image-container a {
  display: block;
  height: 100%;
}

.tecnologias-section .card-content a {
  text-decoration: none;
  color: inherit;
}

.tecnologias-section .card-content a:hover .card-title {
  text-decoration: underline;
}

/* Animaciones para transiciones */
.tecnologias-section .carousel-item.animating {
  transition: transform 0.6s ease-in-out;
}
