/*=====================================
Estilos globales del layout (plantilla.php)
Extraidos de los <style> inline para que el navegador los pueda cachear.
======================================*/

/* Fix scroll unico: evita el doble scrollbar de layout-fixed */
html, body { height: auto !important; overflow-y: auto !important; }
.wrapper    { overflow: visible !important; height: auto !important; }
.content-wrapper {
  overflow-y: visible !important;
  height: auto !important;
  min-height: calc(100vh - 57px) !important;
}

/* Fix select en modales con tema oscuro */
#modalVerificarPw select.form-control {
  background-color: #2f343a;
  color: #ffffff;
  border: 1px solid #555;
  height: 38px;
  padding: 6px 12px;
}

/* Opciones del select */
#modalVerificarPw select.form-control option {
  background-color: #2f343a;
  color: #ffffff;
}

.select2-search__field {
  color: black !important;
}

.select2-selection__choice {
  background-color: #007bff !important;
  color: white !important;
  font-weight: bold;
}

.select2-dropdown {
  background-color: white !important;
  color: black !important;
}

/* Evita que botones de acciones en DataTables se partan en varias lineas */
.dataTable td .btn,
table.table td .btn {
  white-space: nowrap;
  min-width: 92px;
}

.dataTable td .btn.btn-sm,
table.table td .btn.btn-sm {
  min-width: 80px;
}

/* Modal de detalle de orden: ajustes en pantallas pequenas */
@media (max-width: 767.98px) {
  #modalDetalleOrden .modal-dialog {
    max-width: 96vw;
    margin: 0.5rem auto;
  }

  #modalDetalleOrden .modal-body {
    padding: 0.75rem;
  }

  #modalDetalleOrden .table {
    font-size: 0.86rem;
  }
}

/* Boton flotante de instalacion PWA */
#pwa-install-fab {
  display: none;
  position: fixed;
  bottom: 20px;
  right: 20px;
  width: 60px;
  height: 60px;
  border-radius: 50%;
  background: linear-gradient(135deg, #1094c4 0%, #0d7a9e 100%);
  color: white;
  border: none;
  box-shadow: 0 4px 15px rgba(16, 148, 196, 0.4);
  cursor: pointer;
  z-index: 9999;
  font-size: 24px;
  align-items: center;
  justify-content: center;
  transition: transform 0.2s, box-shadow 0.2s;
}
#pwa-install-fab:hover {
  transform: scale(1.1);
  box-shadow: 0 6px 20px rgba(16, 148, 196, 0.6);
}
#pwa-install-fab:active {
  transform: scale(0.95);
}
