.masthead-prod {
  margin-top: 3.7rem;
  position: relative;
  height: 20vh;
  display: flex;
  justify-content: center;
  align-items: center;
  text-align: center;
  color: var(--blanco);
  background: url('../img/productos/bg-prod.webp') center/cover no-repeat;
  overflow: hidden;
  box-shadow: 1px 1px 5px #000;
}

.vynks-hero {
  display: block;
  text-align: center;
  font-family: "BankGothic Md BT", Montserrat, sans-serif;
  font-size: 7rem;
  color: #ffcc99;
  text-shadow: 3px 3px #ff6600;
  line-height: 1.1;
  letter-spacing: -20px;   
  transform: skewX(-20deg); 
  display: inline-block;
  opacity: .8;
}

.vynks-hero:hover {
  text-shadow: -1px -1px 20px rgb(244, 135, 10), 0px 0px 20px rgb(244, 135, 10);
  transition: 100ms;
}

@media (max-width: 1002px) {
  .masthead-prod { margin-top: 3rem; }
  .vynks-hero { font-size: 6.7rem; }
}

@media (max-width: 880px) {
  .vynks-hero { font-size: 6.5rem; }
}

@media (max-width: 768px) {
  .vynks-hero { font-size: 6rem; letter-spacing: -18px; margin-top: 1.2rem}
}

@media (max-width: 600px) {
  .vynks-hero { font-size: 5.5rem; letter-spacing: -17px; }
}

@media (max-width: 480px) {
  .vynks-hero { font-size: 5rem; letter-spacing: -17px }
}

.titulo-prod {
  text-align: center;
  margin-bottom: 2rem;
}

.producto-ficha {
  background: var(--blanco);
  color: var(--oscuro);
  border-radius: 15px;
  padding: 2.5rem 2rem;
  margin: 0 auto;
  max-width: 750px;
  box-shadow: 0 10px 30px rgba(0,0,0,0.2);
  text-align: left;
}

.producto-ficha h3 {
  color: var(--naranja);
  margin-bottom: 1rem;
  font-size: 1.4rem;
}

.producto-ficha p {
  line-height: 1.6;
  font-size: 1rem;
  color: #eee;
}

.producto-tagline {
  margin: 0 auto 1.8rem;
  max-width: 760px;
  color: var(--oscuro);
  font-size: 1.05rem;
  line-height: 1.75;
  text-align: center;
}

.producto-intro {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 1.5rem;
  align-items: flex-start;
  margin-bottom: 2rem;
}

.producto-intro .marco-foto-industrial {
  flex: 1 1 380px;
  min-width: 280px;
  max-width: 520px;
}

.producto-grid {
  display: grid;
  gap: 1.5rem;
  grid-template-columns: minmax(280px, 1.25fr) minmax(260px, 0.85fr);
  align-items: start;
  margin-bottom: 2.5rem;
}

.marco-foto-industrial {
  background: #fff;
  padding: 1rem;
  border-radius: 18px;
  box-shadow: 0 12px 25px rgba(0,0,0,0.12);
}

.boton-cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  padding: 0.95rem 1.4rem;
  border-radius: 30px;
  background: linear-gradient(90deg, #540f25, #921940);
  color: #fff;
  text-decoration: none;
  font-weight: 600;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.boton-cta:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 25px rgba(0, 0, 0, 0.18);
}

.boton-cta.secundario {
  background: #1d1d1d;
  border: 1px solid rgba(255, 255, 255, 0.13);
}

@media (max-width: 880px) {
  .producto-grid {
    grid-template-columns: 1fr;
  }
  .producto-intro {
    flex-direction: column;
  }
  .pdf-botones {
    justify-content: center;
  }
  .section-center {
    text-align: center;
  }
}

@media (max-width: 997px) {
  .producto-ficha { padding: 1.5rem 1rem; }
  .titulo-prod { font-size: 2rem; }
}

.producto-detalle .section-title {
  text-align: center;
  margin: -1rem auto 2rem;
}

.producto-detalle .section-subtitle {
  font-weight: 200;
  color: #333;
  text-align: center;
  max-width: 900px;
  margin: 0 auto 2rem;
}

.foto-principal {
  width: 100%;
  max-width: 400px;
  display: block;
  margin: 0 auto 2rem;
  border-radius: 15px;
  box-shadow: 0 6px 22px rgba(0,0,0,0.25);
  transition: 0.3s ease;
}

.foto-principal:hover { transform: scale(1.03); }

.lista-caracteristicas li {
  display: flex;
  align-items: center;
  gap: 10px;
  color: #f5f5f5;
  font-size: 0.98rem;
  margin-bottom: 0.5rem;
}

.lista-caracteristicas li::before {
  content: "⚙️";
  font-size: 1rem;
}

.lista-caracteristicas {
    list-style: none;
    padding: 0;
    margin: 1.2rem auto;
    text-align: center;
    width: fit-content;
}

.doble-flecha {
  color: var(--naranja);
  font-size: 1.3rem;
}

.galeria-producto {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 1.5rem;
  margin-top: 3rem;
}

.galeria-producto img {
  width: 260px;
  border-radius: 12px;
  box-shadow: 0 6px 25px rgba(0,0,0,0.25);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.galeria-producto img:hover {
  transform: scale(1.05);
  box-shadow: 0 10px 30px rgba(255,102,0,0.5);
}

.producto-detalle .container {
  padding-bottom: 7rem;
  margin-bottom: 7rem;
  border-bottom: 1px solid #000;
  width: 80%;
  margin-left: auto;
  margin-right: auto;
}

.producto-detalle .container:last-of-type {
  border-bottom: none;
  margin-bottom: 0;
  padding-bottom: 0;
}

.boton-volver {
  display: inline-block;
  margin-top: 3rem;
  padding: 0.9rem 2rem;
  background: linear-gradient(90deg, #540f25, #921940);
  color: #fff;
  border-radius: 30px;
  text-decoration: none;
  font-weight: 600;
  letter-spacing: 1px;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.boton-volver:hover {
  transform: scale(1.05);
  box-shadow: 0 0 20px rgba(255,102,0,0.5);
}

@media (max-width: 768px) {
  .producto-ficha {
    padding: 1.8rem;
  }
  .galeria-producto img {
    width: 90%;
    max-width: 300px;
  }
  .producto-detalle {
    padding: 70px 15px;
  }
  .foto-principal {
    max-width: 300px;
  }
  .titulo-aplicacion {
    font-size: 1.7rem !important;
  }
  .galeria-producto img {
    width: 100%;
    max-width: 280px;
  }
}

/* ======= SECCIÓN COMPLETA DE RELACIONADOS ======= */

.relation-section,
.relacionados-section {
  margin-top: 3rem;
  padding: 3rem 1rem;
  border-radius: 20px;
}

.relacionados-title {
  text-align: center;
  font-size: 2rem;
  font-weight: 700;
  letter-spacing: 1px;
  margin-bottom: 2rem;
  color: var(--bordo);
}

/* CONTENEDOR GENERAL */
.relacionados-container {
  display: flex;
  gap: 1.5rem;
  overflow-x: auto;
  padding-bottom: 1rem;
  scroll-snap-type: x mandatory;
  padding: 0 2.5rem 1rem;
}

.relacionados-container::-webkit-scrollbar { display: none; }

/* TARJETAS */
.rel-card {
  min-width: 230px;
  max-width: 240px;
  background: #fff;
  border-radius: 14px;
  padding: 1rem;
  text-align: center;
  text-decoration: none;
  color: inherit;
  border: 1px solid rgba(0,0,0,0.1);
  box-shadow: 0 4px 10px rgba(0,0,0,0.08);
  transition: 0.25s ease;
  scroll-snap-align: center;
}

.rel-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 20px rgba(0,0,0,0.15);
  border-color: var(--azul);
}

/* IMAGEN */
.rel-img {
  width: 100%;
  height: 140px;
  display: flex;
  justify-content: center;
  align-items: center;
}

.rel-img img {
  max-height: 100%;
  width: auto;
  object-fit: contain;
}

/* TEXTOS */
.rel-card h4 {
  margin-top: 1rem;
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--azul-oscuro);
}

.rel-card p {
  font-weight: 600;
  margin-top: 0.5rem;
  color: var(--azul);
}

/* WRAPPER para posicionar flechas como overlay a cada costado */
.relacionados-wrapper {
  position: relative;
  display: block;
}

/* Aseguramos altura para centrar verticalmente las flechas en la vista móvil */
.relacionados-container {
  padding: 0 2.5rem; /* deja espacio visual a los lados para las flechas */
}

/* ===== Flechas del carrusel (FIX MOBILE) ===== */

.relacionados-wrapper {
  position: relative;
}

/* Carrusel */
.relacionados-container {
  display: flex;
  gap: 1.5rem;
  overflow-x: auto;
  padding: 0 3rem;
}

/* Flechas */
.rel-arrow.side {
  position: absolute;
  top: 0;
  bottom: 0;
  margin: auto 0;              /* 👈 centrado vertical REAL */
  z-index: 50;
  border: none;
  background: rgba(84,15,37,0.95);
  color: #fff;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: 0 6px 20px rgba(0,0,0,0.25);
}

/* Posición lateral */
.rel-arrow.side.left  { left: 6px; }
.rel-arrow.side.right { right: 6px; }

/* Mobile */
@media (max-width: 600px) {
  .rel-arrow.side {
    width: 42px;
    height: 42px;
  }
}


@media (max-width: 420px) {
  .relacionados-container { padding: 0 1.5rem; }
}

.flex {
  display: flex;
}

.flex-center {
  display: flex;
  justify-content: center;
  align-items: center;
}

.flex-column {
  display: flex;
  flex-direction: column;
}

.gap-1 { gap: 1rem; }
.gap-2 { gap: 2rem; }
.gap-3 { gap: 3rem; }

/* Anchos y límites reutilizables */
.w-auto { width: auto; }
.max-w-420 { max-width: 420px; }
.max-w-500 { max-width: 500px; }
.min-w-280 { min-width: 280px; }

/* Asegura altura real para centrar flechas correctamente */
.relacionados-wrapper {
  position: relative;
}

/* El contenedor define la altura real */
.relacionados-container {
  min-height: 260px; /* igual o un poco más que la altura de las cards */
}

/* Flechas centradas contra el carrusel */
.rel-arrow.side {
  top: 50%;
  transform: translateY(-50%);
}


/* ================================
   LAYOUT DEL PRODUCTO
================================ */

/* Fila características + foto */
.fila-caract-foto {
  display: flex;
  justify-content: center;
  align-items: center;   /* centrado vertical */
  gap: 2.5rem;
  flex-wrap: wrap;
  margin-top: 3rem;
}

/* Tarjeta de características */
.ficha-lado {
  flex: 0 1 auto;        /* NO se estira */
  width: auto;           /* usa ancho natural */
  max-width: 420px;      /* límite visual */
  min-width: 280px;      /* no se achica demasiado */
}

/* Foto lateral */
.foto-lado {
  display: flex;
  justify-content: center;
  align-items: center;
  flex: 1;
  min-width: 280px;
}

.foto-lado img {
  width: 100%;
  max-width: 360px;
  border-radius: 12px;
  box-shadow: 0 6px 22px rgba(0,0,0,0.25);
}


/* Descripción separada */
.desc-prod {
  margin-top: 1rem !important;
  text-align: center;
  max-width: 900px;
}

/* Título aplicación */
.titulo-aplicacion {
  text-align: center;
  font-size: 2rem;
  font-weight: 700;
  letter-spacing: 1px;
  margin-top: 4rem;
  color: var(--bordo);
}

/* Botones PDF */
.pdf-botones {
  display: flex;
  justify-content: center;
  gap: 2rem;
  flex-wrap: wrap;
  margin-top: 3rem;
}


/* ========================== */
/*         RESPONSIVE         */
/* ========================== */

@media (max-width: 900px) {
  .fila-caract-foto {
    flex-direction: column;
    align-items: center;
  }

  .ficha-lado, 
  .foto-lado {
    max-width: 500px;
  }
}

@media (max-width: 600px) {
  .foto-lado img {
    max-width: 280px;
  }

  .pdf-botones {
    flex-direction: column;
    gap: 1.2rem;
  }

  .boton-pdf {
    width: 85%;
    text-align: center;
  }
}

@media (max-width: 900px) {
  .fila-caract-foto {
    flex-direction: column;
  }

  .ficha-lado,
  .foto-lado {
    max-width: 500px;
  }
}

@media (max-width: 600px) {
  .foto-lado img {
    max-width: 280px;
  }

  .pdf-botones {
    flex-direction: column;
    gap: 1.2rem;
  }

  .boton-pdf {
    width: 85%;
    text-align: center;
  }
}

@media (max-width: 600px) {

  .relacionados-wrapper {
    overflow: visible;
  }

  .rel-arrow.side.left  { left: -4px; }
  .rel-arrow.side.right { right: -4px; }

  .relacionados-container {
    padding: 0 1rem;
  }
}

@media (max-width: 600px) {

  .relacionados-container {
    min-height: 240px;
  }

  .rel-arrow.side.left  { left: 6px; }
  .rel-arrow.side.right { right: 6px; }
}


/* --- ESTILOS B2B INDUSTRIALES --- */

/* Tabla de Especificaciones */
.tabla-industrial-b2b {
  width: 100%;
  border-collapse: collapse;
  margin-top: 15px;
  font-family: 'Inter', 'Roboto', sans-serif; /* Fuentes limpias para lectura técnica */
  font-size: 0.95rem;
}

.tabla-industrial-b2b th, 
.tabla-industrial-b2b td {
  padding: 12px 15px;
  border-bottom: 1px solid #e0e0e0;
  text-align: left;
}

.tabla-industrial-b2b th {
  background-color: #f8f9fa;
  color: #333;
  width: 35%;
  font-weight: 600;
  border-right: 1px solid #e0e0e0;
}

.tabla-industrial-b2b td {
  color: #555;
}

.tabla-industrial-b2b tr:hover {
  background-color: #f1f5f9; /* Leve resaltado al pasar el mouse */
}

/* Descripción Estructurada */
.desc-prod-b2b {
  font-family: 'Inter', 'Roboto', sans-serif;
  line-height: 1.7;
  color: #444;
  margin-bottom: 30px;
}

.desc-prod-b2b h4 {
  margin-top: 20px;
  margin-bottom: 10px;
  color: #222;
  font-family: 'Rajdhani', sans-serif;
  font-size: 1.2rem;
}

.desc-prod-b2b ul {
  padding-left: 20px;
}

.desc-prod-b2b ul li {
  margin-bottom: 10px;
}

/* Botones de Acción B2B */
.acciones-industriales {
  display: flex;
  gap: 15px;
  margin-top: 30px;
  flex-wrap: wrap;
}

.btn-cotizar, .btn-doc {
  padding: 12px 24px;
  text-decoration: none;
  font-weight: bold;
  border-radius: 4px;
  transition: all 0.3s ease;
  font-family: 'Inter', 'Roboto', sans-serif;
  display: flex;
  align-items: center;
  gap: 8px;
}

.btn-cotizar {
  background-color: #FF6600; /* Color industrial de alta visibilidad */
  color: #fff;
  border: 2px solid #FF6600;
}

.btn-cotizar:hover {
  background-color: #CC5200;
  border-color: #CC5200;
}

.btn-doc {
  background-color: #fff;
  color: #333;
  border: 2px solid #ccc;
}

.btn-doc:hover {
  background-color: #f0f0f0;
  border-color: #999;
}

/* Contenedor estilo ficha para imágenes técnicas */
.marco-foto-industrial {
  background-color: #ffffff;
  padding: 30px;               /* Espacio entre la imagen y el borde blanco */
  border-radius: 12px;         /* Puntas redondeadas */
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1); /* Sombreado suave */
  display: inline-block;       /* Ajusta el cuadro al tamaño de la imagen */
  margin: 20px auto;           /* Centrado y margen vertical */
  border: 1px solid #e0e0e0;   /* Un borde muy fino para dar definición */
}

.marco-foto-industrial img {
  display: block;
  border-radius: 4px;          /* Un leve redondeado a la foto misma */
}
.section-title.titulo-prod {
    font-family: 'Roboto', 'Helvetica Neue', sans-serif;
    color: #555555; /* Gris medio para la descripción */
    font-size: 24px;
    font-weight: 400; /* Peso normal para la descripción */
    line-height: 1.4;
    border-left: 5px solid #ff6600; /* Una barra lateral roja/naranja le da un aspecto muy industrial */
    padding-left: 15px;
    letter-spacing: 0px;
}

.titulo-prod .modelo {
    color: #111111; /* Casi negro para máximo contraste */
    font-weight: 900; /* Extra negrita para el código del hardware */
    letter-spacing: 0px;
}

/* Correcciones para m��viles */
@media (max-width: 768px) {
    /* 1. Hace que la tabla y la foto se apilen verticalmente en celulares */
    .fila-caract-foto {
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 20px;
    }

    /* 2. Evita que la tabla rompa el dise?o si tiene textos muy largos */
    .producto-ficha {
        width: 100%;
        overflow-x: auto; /* Permite scroll horizontal solo en la tabla si es necesario */
    }

    /* 3. Asegura que los contenedores de las fotos no superen el ancho de la pantalla */
    .marco-foto-industrial {
        width: 100%;
        text-align: center;
    }
    
    /* 4. Refuerzo de seguridad para todas las im��genes dentro del detalle */
    .producto-detalle img {
        max-width: 100% !important;
        height: auto !important;
    }
}