/* === BASE === */
body {
  font-family: 'Poppins', sans-serif;
}

.text-rojo {
  color: #FF2124;
}

.btn-danger {
  background-color: #FF2124;
  border: none;
  font-weight: 600;
}

.btn-danger:hover {
  background-color: #c51c1f;
}

/* === PESTAÑAS DE PRODUCTO === */
.product-tabs {
  max-width: 1000px;
  margin: 1.5rem auto 1rem auto; /* menos espacio arriba */
}


.product-tabs .nav-tabs {
  display: flex;
  justify-content: center;
  width: 100%;
  border-bottom: 0;
}

.product-tabs .nav-tabs .nav-item {
  flex: 1; /* cada pestaña ocupa el mismo ancho */
  text-align: center;
}

.product-tabs .nav-tabs .nav-link {
  width: 100%;
  border: 0;
  border-radius: 0;
  padding: 0.85rem 1.25rem;
  font-weight: 600;
  letter-spacing: 0.3px;
  color: #8f9aa7;
  background: #f2f3f5;
  transition: color 0.2s ease, background 0.2s ease;
}

.product-tabs .nav-tabs .nav-link:not(.active):hover {
  color: #495057;
}

.product-tabs .nav-tabs .nav-link.active {
  color: #FF2124;
  background: #ffffff;
  box-shadow: inset 0 -3px 0 #FF2124;
}

.product-tabs .tab-content {
  background: #ffffff;
  border: 1px solid #dee2e6;
  border-top: 0;
  border-radius: 0 0 0.5rem 0.5rem;
  font-size: 0.95rem;
  width: 100%;          /* igual ancho que las pestañas */
  margin: 0 auto;
}

/* Responsive tweaks */
@media (max-width: 767.98px) {
  .product-tabs .nav-tabs .nav-link {
    padding: 0.75rem 1rem;
    font-size: 0.9rem;
  }
}

/* === WRAPPER GENERAL === */
.producto-detalle {
  background-color: #f8f9fa;
}

.producto-wrapper {
  display: flex;
  flex-direction: column;
  gap: 2rem;
  max-width: 1100px;
  width: 100%;
  margin: 0 auto;
}

@media (min-width: 768px) {
  .producto-wrapper {
    flex-direction: row;
    align-items: flex-start;
    justify-content: space-between;
  }

  .producto-detalle {
    height: auto;
    min-height: 80vh;
    display: block;
  }
}

/* === MINIATURAS VERTICALES EN ESCRITORIO === */
.thumbnails {
  overflow-y: visible;
  padding-right: 0.5rem;
  padding-top: 20px;
  width: 100px;
  height: 500px;
}

.thumbnails img,
.miniatura-mobile {
  width: 80px;
  height: 80px;
  object-fit: contain;
  background-color: white;
  padding: 4px;
  box-sizing: border-box;
  border-radius: 6px;
  border: 2px solid transparent;
  cursor: pointer;
  transition: transform 0.2s ease, border-color 0.2s ease;
}

.thumbnails img:hover,
.thumbnails img.active-thumbnail,
.miniatura-mobile:hover,
.miniatura-mobile.active-thumbnail {
  border-color: #FF2124;
  transform: scale(1.05);
}

/* === IMAGEN PRINCIPAL === */
.main-image-wrapper {
  flex: 1;
  max-width: 500px;
  margin: 0 auto;
  text-align: center;
}

.main-image {
  max-height: 400px;
  width: 100%;
  object-fit: contain;
}

/* === INFORMACIÓN DEL PRODUCTO === */
.producto-info {
  flex: 1;
  min-width: 260px;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.producto-info h2 {
  font-size: 1.8rem;
}

.producto-descripcion {
  max-width: 100%;
  margin-left: auto;
  margin-right: auto;
}

.producto-descripcion p {
  font-size: 1rem;
}

/* === CONTACTO === */
.contacto-section input,
.contacto-section textarea {
  border: 1px solid #ccc;
  font-size: 0.95rem;
}

.contacto-section .form-control:focus {
  box-shadow: none;
  border-color: #FF2124;
}

.contacto-icon {
  width: 40px;
  height: 40px;
  min-width: 40px;
  min-height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: #FF2124;
  border-radius: 50%;
  font-size: 1rem;
}

.contacto-section h2 {
  font-size: 2.5rem;
}

.btn-enviar {
  background-color: #FF2124 !important;
  border: none;
  color: white;
  font-weight: 600;
  border-radius: 6px;
  transition: background-color 0.2s ease;
}

.btn-enviar:hover {
  background-color: #A50F11 !important;
  color: white;
}

/* === MINIATURAS EN ESCRITORIO HORIZONTALES === */
@media (min-width: 768px) {
  .thumbnails {
    display: flex;
    flex-direction: row;
    overflow-x: auto;
    overflow-y: hidden;
    gap: 0.5rem;
    max-height: none;
  }

  .thumbnails img {
    margin-bottom: 0;
  }
}

/* === RESPONSIVE: MÓVILES === */
@media (max-width: 767.98px) {
  .producto-wrapper {
    flex-direction: column;
    align-items: center;
  }

  .producto-info {
    width: 100%;
    padding: 0 1rem;
    margin-top: 2rem;
  }

  .main-image {
    max-height: 280px;
  }

  .miniatura-mobile {
    width: 70px;
    height: 70px;
    border-radius: 4px;
  }

  .main-image-wrapper h2 {
    font-size: 1.4rem;
    margin-bottom: 1rem;
  }

  .producto-info h2 {
    display: none;
  }

  .miniatura.active-thumbnail {
    border-color: #FF2124 !important;
  }
}

/* === SUB-ARRIENDO === */
.etiqueta-subarriendo {
  display: inline-block;
  background-color: #FFD600;
  color: #212529;
  font-weight: 700;
  font-size: 0.8rem;
  padding: 0.5rem 1rem;
  text-transform: uppercase;
  clip-path: polygon(12% 0%, 100% 0%, 100% 100%, 0% 100%);
}
