/* =======================================
   CARD DE CLIENTE
   ======================================= */

/* Mismas columnas que .cliente-info — así el header de arriba queda
   siempre alineado con el contenido, tenga lo que tenga cada cliente. */
.clientes-header {
  display: grid;
  grid-template-columns: 28px 18px 1fr 68px 66px 58px 52px;
  column-gap: 8px;
  padding: 6px 10px;
  font-size: 9.5px;
  font-weight: 700;
  color: #9ca3af;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  border-bottom: 1px solid #e5e7eb;
  flex-shrink: 0;
}
.clientes-header span:nth-child(4),
.clientes-header span:nth-child(5),
.clientes-header span:nth-child(6) {
  text-align: center;
}
.clientes-header span:nth-child(7) {
  text-align: right;
}

.cliente-info {
  display: grid;
  grid-template-columns: 28px 18px 1fr 68px 66px 58px 52px;
  align-items: center;
  column-gap: 8px;

  padding: 5px 10px;
  margin-bottom: 0;
  min-height: 36px;

  border: none;
  border-bottom: 1px solid #eef1f5;
  border-left: 3px solid #dfebf8;
  background: #fff;
  border-radius: 0;
  box-shadow: none;
  transition: background 0.1s, border-color 0.2s;
  position: relative;
}

.cliente-info:last-child { border-bottom: none; }

.cliente-info:hover {
  background: #f8fafc;
}

.cliente-checkbox { grid-column: 2; justify-self: start; }

/* ── IZQUIERDA (fila tipo tabla) ────── */

.info-izq {
  grid-column: 3;
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 12px;
  overflow: hidden;
}

.cliente-nombre {
  font-size: 0.78rem;
  font-weight: 700;
  color: #111827;
  text-transform: uppercase;
  letter-spacing: 0.02em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  margin-bottom: 0;
  flex: 0 1 auto;
  min-width: 40px;
  max-width: 180px;
}

.cliente-horario,
.cliente-franja,
.cliente-nota,
.cliente-telefono,
.cliente-observaciones {
  display: flex;
  align-items: center;
  gap: 4px;
  flex-shrink: 0;
}

.cliente-horario i,
.cliente-franja i,
.cliente-nota i,
.cliente-telefono i,
.cliente-observaciones i {
  width: 11px;
  font-size: 0.62rem;
  text-align: center;
  flex-shrink: 0;
}

.cliente-horario {
  font-size: 0.68rem;
  color: #9ca3af;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  margin-bottom: 0;
  max-width: 90px;
}

.cliente-franja {
  font-size: 0.68rem;
  color: #111111;
  font-weight: 600;
  margin-bottom: 0;
  white-space: nowrap;
}

.cliente-nota {
  font-size: 0.68rem;
  color: #B45309;
  font-style: italic;
  margin-bottom: 0;
}

.cliente-telefono {
  font-size: 0.68rem;
  color: #6b7280;
  margin-bottom: 0;
  white-space: nowrap;
}

.cliente-observaciones {
  font-size: 0.68rem;
  color: #B45309;
  font-style: italic;
  margin-bottom: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  max-width: 90px;
}

.cajones-label {
  grid-column: 4;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 3px;
  font-size: 0.72rem;
  color: #4b5563;
  white-space: nowrap;
}

.cajones-input {
  width: 38px !important;
  font-size: 0.72rem !important;
  border: 1px solid #d1d5db;
  border-radius: 5px;
  padding: 2px 4px;
  text-align: center;
  background: #fff;
  color: #374151;
}

.cajones-input:focus {
  outline: none;
  border-color: #111111;
  box-shadow: 0 0 0 2px rgba(17,17,17,0.15);
}

.hora-llegada-estimada {
  grid-column: 5;
  justify-self: center;
  font-size: 0.66rem;
  font-weight: 600;
  color: #1d4ed8;
  background: #eff6ff;
  border: 1px solid #bfdbfe;
  border-radius: 4px;
  padding: 1px 5px;
  white-space: nowrap;
  line-height: 1.6;
}

.hora-llegada-estimada:empty {
  display: none;
}

/* ── DERECHA ──────────────────────── */

.color-options {
  grid-column: 6;
  justify-self: center;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 3px;
  max-width: 58px;
}

.color-btn {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  border: 2px solid transparent;
  cursor: pointer;
  padding: 0;
  transition: transform 0.12s, border-color 0.12s;
}

.color-btn:hover {
  transform: scale(1.35);
  border-color: rgba(0, 0, 0, 0.3);
}

.acciones-clientes {
  grid-column: 7;
  justify-self: end;
  display: flex;
  gap: 2px;
}

.btn-eliminar,
.btn-editar-cliente {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  background: none;
  border: none;
  font-size: 0.72rem;
  color: #9ca3af;
  cursor: pointer;
  border-radius: 6px;
  transition: color 0.15s, background 0.15s;
  line-height: 1;
}

.btn-editar-cliente:hover {
  color: #111111;
  background: #F3F4F6;
}

.btn-eliminar:hover {
  color: #dc2626;
  background: #fee2e2;
}

/* ── COLORES DE BORDE POR CAMIÓN ───── */

.border-red     { border-left-color: #DC143C !important; }
.border-green   { border-left-color: #16a34a !important; }
.border-blue    { border-left-color: #1E90FF !important; }
.border-default { border-left-color: #dfebf8 !important; }
.border-gray    { border-left-color: #708090 !important; }
.border-orange  { border-left-color: orange  !important; }
.border-violeta { border-left-color: #8A2BE2 !important; }

/* .fila-cliente es solo un marcador para selectores JS — el layout
   real de la fila lo define .cliente-info (grid). */
