/* ========================= */
/* Página detalle camión     */
/* ========================= */
.detalle-camion { 
  margin-top:20px; 
}

.detalle-header { 
  display:flex; 
  flex-wrap:wrap; 
  gap:20px; 
  margin-bottom:30px; 
}

.detalle-header .galeria-detalle { 
  margin-top:20px;
  flex:2; 
  min-width:300px; 
}

/* ========================= */
/* Galería                   */
/* ========================= */
.galeria-detalle {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.galeria-detalle .galeria-principal img { 
  width:100%; 
  max-height:400px; 
  object-fit:cover; 
  border-radius:6px; 
  border: 1px solid #e5e7eb;
}

.galeria-detalle .galeria-miniaturas { 
  display:flex; 
  gap:10px; 
  overflow-x: auto; 
  padding-bottom: 6px;
}

.galeria-detalle .galeria-miniaturas img { 
  width:100px; 
  height:70px; 
  object-fit:cover; 
  cursor:pointer; 
  border:2px solid transparent; 
  border-radius:4px; 
  transition: border 0.2s ease, transform 0.2s ease;
  flex-shrink: 0;
}

.galeria-detalle .galeria-miniaturas img:hover,
.galeria-detalle .galeria-miniaturas img.activa { 
  border-color: var(--brand); 
  transform: scale(1.05);
}


/* ========================= */
/* Fichas estilo minimalista */
/* ========================= */
.ficha {
  margin-bottom: 30px;
}

.ficha h2 {
  font-size: 1.3rem;
  font-weight: 600;
  margin-bottom: 15px;
  border-bottom: 2px solid #eee;
  padding-bottom: 4px;
}

.ficha table {
  width: 100%;
  border-collapse: collapse;
}

.ficha table tr {
  border-bottom: 1px solid #e5e7eb;
}

.ficha table th {
  text-align: left;
  font-weight: 500;
  color: #444;
  padding: 10px;
  width: 40%;
  font-size: 14px;
}

.ficha table td {
  text-align: left;
  font-weight: 600;
  color: #000;
  padding: 10px;
  width: 60%;
  font-size: 14px;
}

/* ========================= */
/* Responsive grid           */
/* ========================= */

/* Escritorio: 4 columnas (Enunciado/Valor/Enunciado/Valor) */
@media (min-width: 992px) {
  .ficha table tr {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr 1fr;
  }
  .ficha table th, 
  .ficha table td {
    border: none;  /* quitamos cuadricula interna */
    padding: 12px 15px;
  }
  .ficha table tr {
    border-bottom: 1px solid #eee;
  }
}

/* Móvil: 2 columnas (Enunciado/Valor) */
@media (max-width: 991px) {
  .ficha table tr {
    display: grid;
    grid-template-columns: 1fr 1fr;
  }
  .ficha table th, .ficha table td {
    padding: 10px;
  }
}

/* ========================= */
/* Configuración de ejes     */
/* ========================= */
.eje-block {
  margin-bottom: 30px;
  background: #fff;
  border: 1px solid #e5e7eb;
  border-radius: 6px;
  overflow: hidden;
  box-shadow: 0 1px 2px rgba(0,0,0,0.05);
}

.eje-block h3 {
  font-size: 1.2rem;
  font-weight: 600;
  margin: 0;
  padding: 12px 15px;
  background: #f9fafb;
  border-bottom: 1px solid #e5e7eb;
}

.eje-block table {
  width: 100%;
  border-collapse: collapse;
}

.eje-block table tr {
  border-bottom: 1px solid #e5e7eb;
  display: grid;
  grid-template-columns: 1fr 1fr; /* por defecto en móvil */
}

.eje-block table th {
  text-align: left;
  font-weight: 500;
  color: #444;
  padding: 10px;
  font-size: 14px;
}

.eje-block table td {
  text-align: left;
  font-weight: 600;
  color: #000;
  padding: 10px;
  font-size: 14px;
}

/* Escritorio: 4 columnas */
@media (min-width: 992px) {
  .eje-block table tr {
    grid-template-columns: 1fr 1fr 1fr 1fr;
  }
}

/* ========================= */
/* Contacto asesor (tarjeta) */
/* ========================= */
.contacto-asesor {
  background: #fff;
  border: 1px solid #e5e7eb;
  border-radius: 6px;
  padding: 15px;
  margin-top: 20px;
  box-shadow: 0 1px 2px rgba(0,0,0,0.05);
}

.contacto-asesor h1 {
  font-size: 1.5rem;
  margin-bottom: 5px;
}

.contacto-asesor .precio {
  font-size: 1.8rem;
  font-weight: bold;
  color: var(--brand);
  margin-bottom: 15px;
}

.contacto-asesor ul {
  list-style: none;
  padding: 0;
  margin: 0 0 15px 0;
}

.contacto-asesor li {
  border-bottom: 1px solid #eee;
  padding: 6px 0;
  font-size: 14px;
}

.contacto-asesor li strong {
  font-weight: 500;
  color: #444;
  min-width: 100px;
  display: inline-block;
}

.asesor-info h3 {
  font-size: 1.2rem;
  margin-bottom: 5px;
}

.asesor-info p {
  margin: 0 0 8px;
  font-size: 14px;
  color: #555;
}

.asesor-nombre {
  font-weight: 600;
  color: #000;
}

.asesor-acciones {
  margin-top: 15px;
}

.asesor-acciones .telefono {
  font-weight: 600;
  margin-bottom: 10px;
}

.asesor-acciones .botones {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.asesor-acciones button,
.asesor-acciones .btn-secundario {
  padding: 6px 12px;
  font-size: 14px;
  font-weight: 600;
  border-radius: 4px;
  text-decoration: none;
  border: none;
  cursor: pointer;
}

.asesor-acciones button {
  background: var(--brand);
  color: #fff;
}

.asesor-acciones button:hover {
  background: #c53027;
}

.asesor-acciones .btn-secundario {
  background: #f1f5f9;
  color: #333;
}

.asesor-acciones .btn-secundario:hover {
  background: #e2e8f0;
}

/* ===== Icono WhatsApp dentro del botón secundario ===== */
.asesor-acciones .btn-secundario i {
  color: #25D366;            /* verde oficial WhatsApp */
  margin-right: 6px;         /* separación respecto al texto */
  font-size: 1.1rem;         /* tamaño equilibrado */
  vertical-align: middle;    /* centra verticalmente con el texto */
  transition: transform 0.2s ease, color 0.2s ease;
}

/* efecto al pasar el ratón */
.asesor-acciones .btn-secundario:hover i {
  transform: scale(1.2);
  color: #1ebe5d;
}

.tabla-resumen {
  width: 100%;
  border-collapse: collapse;
  margin-top: 10px;
}

.tabla-resumen tr {
  border-bottom: 1px solid #eee;
}

.tabla-resumen th,
.tabla-resumen td {
  padding: 8px 6px;
  font-size: 14px;
  text-align: left;
}

.tabla-resumen th {
  font-weight: 500;
  color: #555;
  width: 40%;
}

.tabla-resumen td {
  font-weight: 400; /* texto normal */
  color: #111;      /* un negro un poco más suave que el brand */
}


.botones {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 5px;
}

.botones .btn {
  padding: 6px 10px;
  font-size: 14px;
  font-weight: 600;
  border-radius: 4px;
  text-decoration: none;
  cursor: pointer;
  border: none;
}

.btn-primario {
  background: var(--brand);
  color: #fff;
}

.btn-primario:hover {
  background: #c53027;
}

.btn-secundario {
  background: #f1f5f9;
  color: #333;
}

.btn-secundario:hover {
  background: #e2e8f0;
}

/* ========================= */
/* Modal disponibilidad      */
/* ========================= */
.modal {
  display: none;
  position: fixed;
  z-index: 1000;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  overflow: auto;
  background-color: rgba(0,0,0,0.6);
  padding: 40px 10px;
}

/* Contenido del modal (similar a .resumen) */
.modal-contenido {
  background: #fff;
  margin: auto;
  padding: 20px;
  border: 1px solid #e5e7eb;
  border-radius: 6px;
  width: 90%;
  max-width: 500px;
  box-shadow: 0 2px 6px rgba(0,0,0,0.2);
  position: relative;
  animation: modal-entrada 0.3s ease;
}

/* Animación de entrada */
@keyframes modal-entrada {
  from { opacity: 0; transform: translateY(-20px); }
  to { opacity: 1; transform: translateY(0); }
}

/* Botón de cerrar */
.modal-cerrar {
  color: #aaa;
  position: absolute;
  top: 12px;
  right: 18px;
  font-size: 24px;
  font-weight: bold;
  cursor: pointer;
}

.modal-cerrar:hover {
  color: #000;
}

/* Título del modal */
.modal-contenido h2 {
  font-size: 1.4rem;
  margin-top: 0;
  margin-bottom: 15px;
  border-bottom: 2px solid #f1f1f1;
  padding-bottom: 8px;
}

/* ========================= */
/* Formulario dentro modal   */
/* ========================= */
.form-consulta {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.form-consulta label {
  font-weight: 500;
  font-size: 14px;
  color: #444;
  margin-bottom: 2px;
}

.form-consulta input,
.form-consulta textarea {
  width: 100%;
  padding: 8px 10px;
  border: 1px solid #d1d5db;
  border-radius: 4px;
  font-size: 14px;
  color: #111;
  transition: border-color 0.2s;
}

.form-consulta input:focus,
.form-consulta textarea:focus {
  border-color: var(--brand);
  outline: none;
}

/* Botón enviar */
.form-consulta button {
  background: var(--brand);
  color: #fff;
  font-weight: 600;
  padding: 10px 14px;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  transition: background 0.2s;
}

.form-consulta button:hover {
  background: #c53027;
}

/* ========================= */
/* Modal estilo Ecoparts FIX */
/* ========================= */
.galeria-lightbox {
  display: none;
  position: fixed !important;
  inset: 0;
  z-index: 9999 !important;
  width: 100vw;
  height: 100vh;
  background: rgba(30,30,30,0.95);
  justify-content: center;
  align-items: center;
  overflow: hidden;
}

.galeria-lightbox.activa {
  display: flex;
  animation: fadeInModal 0.25s ease;
}

/* Contenedor principal centrado */
.galeria-lightbox-contenido {
  position: relative;
  width: 100%;
  height: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
}

/* Imagen principal */
.galeria-lightbox-imagen {
  max-width: 90vw;
  max-height: 90vh;
  object-fit: contain;
  border-radius: 6px;
  background: #000;
  box-shadow: 0 0 20px rgba(0,0,0,0.6);
}

/* Flechas dentro de la imagen */
.galeria-lightbox-flecha {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  font-size: 48px;
  color: rgba(255,255,255,0.9);
  cursor: pointer;
  user-select: none;
  transition: color 0.2s, background 0.2s;
  background: rgba(0,0,0,0.3);
  border-radius: 50%;
  padding: 10px 16px;
  z-index: 10000;
}

.galeria-lightbox-flecha:hover {
  color: var(--brand);
  background: rgba(0,0,0,0.6);
}

.galeria-lightbox-flecha.izquierda { left: 30px; }
.galeria-lightbox-flecha.derecha { right: 30px; }

/* Botón de cerrar (X) arriba a la derecha */
.galeria-lightbox-cerrar {
  position: fixed;
  top: 20px;
  right: 35px;
  color: #fff;
  font-size: 36px;
  font-weight: bold;
  cursor: pointer;
  user-select: none;
  z-index: 10001;
  transition: color 0.2s;
}

.galeria-lightbox-cerrar:hover {
  color: var(--brand);
}

/* Contador (1 / N) */
.galeria-contador {
  position: fixed;
  top: 20px;
  left: 30px;
  color: #fff;
  font-size: 14px;
  background: rgba(0,0,0,0.4);
  padding: 4px 8px;
  border-radius: 4px;
  font-weight: 500;
  z-index: 10001;
}

@keyframes fadeInModal {
  from { opacity: 0; }
  to { opacity: 1; }
}

/* ========================= */
/* Lupa táctil para móviles  */
/* ========================= */
.galeria-lupa {
  position: absolute;
  width: 500px;       /* 🔍 tamaño físico más grande */
  height: 500px;
  border-radius: 5%;
  border: 3px solid #fff;
  background-repeat: no-repeat;
  background-size: 300% 300%; /* más detalle en la ampliación */
  display: none;
  pointer-events: none;
  z-index: 10005;
  box-shadow: 0 0 12px rgba(0,0,0,0.6);
  transition: opacity 0.2s ease;
}
/* Bloqueo de scroll al usar la lupa */
body.no-scroll {
  overflow: hidden !important;
  touch-action: none !important;
}
