/*
  AVANZA CONTROL V5.6.1
  Navegación exclusiva del módulo Inventario.
*/

#inventorySection {
  width: 100%;
  min-width: 0;
}

.inventory-exclusive-header-v561 {
  display: none;
}

/* Vista de una operación seleccionada */

#inventorySection.inventory-exclusive-active-v561
> .page-heading,

#inventorySection.inventory-exclusive-active-v561
> #inventorySummary,

#inventorySection.inventory-exclusive-active-v561
> .hub-grid {
  display: none !important;
}

#inventorySection.inventory-exclusive-active-v561
> .inventory-exclusive-header-v561 {
  margin-bottom: 14px;
  padding: 16px 18px;

  display: grid;
  grid-template-columns:
    auto minmax(0, 1fr);

  align-items: center;
  gap: 15px;

  border: 1px solid #d7e3ed;
  border-radius: 17px;

  background:
    linear-gradient(
      135deg,
      #ffffff,
      #f2f7fb
    );

  box-shadow:
    0 8px 22px
    rgba(7, 31, 61, .06);
}

.inventory-exclusive-back-v561 {
  min-height: 42px;
  padding: 9px 13px;

  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;

  border: 1px solid #c5d9e8;
  border-radius: 11px;

  background: #ffffff;
  color: #0756a3;

  font-size: 10px;
  font-weight: 900;
  cursor: pointer;
}

.inventory-exclusive-back-v561 span {
  font-size: 21px;
  line-height: 1;
}

.inventory-exclusive-back-v561:hover {
  border-color: #92bddd;
  background: #edf6fd;
}

.inventory-exclusive-title-v561 {
  min-width: 0;
}

.inventory-exclusive-title-v561 > span {
  display: block;
  margin-bottom: 4px;

  color: #075fb3;
  font-size: 8px;
  font-weight: 950;
  letter-spacing: .15em;
}

.inventory-exclusive-title-v561 h2 {
  margin: 0;

  color: #071f3d;
  font-size: 22px;
  letter-spacing: -.02em;
}

.inventory-exclusive-title-v561 p {
  margin: 5px 0 0;

  color: #74869a;
  font-size: 10px;
  line-height: 1.45;
}

/* Mostrar únicamente el panel seleccionado */

#inventorySection.inventory-exclusive-active-v561
> .inventory-panel {
  display: none !important;
}

#inventorySection.inventory-exclusive-active-v561
> .inventory-panel.inventory-exclusive-panel-v561 {
  width: 100%;
  min-width: 0;
  margin: 0;

  display: block !important;

  animation:
    inventory-exclusive-in-v561
    .18s ease;
}

#inventorySection.inventory-exclusive-active-v561
> .inventory-panel.inventory-exclusive-panel-v561
> .card {
  width: 100%;
  max-width: none;
}

/* Separación uniforme entre tarjetas */

#inventorySection.inventory-exclusive-active-v561
.inventory-exclusive-panel-v561
> .card,

#inventorySection.inventory-exclusive-active-v561
.inventory-exclusive-panel-v561
> .commerce-subgrid,

#inventorySection.inventory-exclusive-active-v561
.inventory-exclusive-panel-v561
> .section-title,

#inventorySection.inventory-exclusive-active-v561
.inventory-exclusive-panel-v561
> .commerce-operation-grid {
  margin-top: 0;
  margin-bottom: 13px;
}

/* Computadora */

@media (min-width: 1100px) {
  #inventorySection.inventory-exclusive-active-v561 {
    min-height:
      calc(100vh - 145px);
  }

  #inventorySection.inventory-exclusive-active-v561
  > .inventory-panel.inventory-exclusive-panel-v561 {
    min-height:
      calc(100vh - 235px);
  }

  /*
    Las compras pueden aprovechar columnas,
    mientras las demás operaciones usan ancho total.
  */
  #inventoryEntryPanel
  .commerce-subgrid {
    grid-template-columns:
      repeat(2, minmax(0, 1fr));
  }
}

/* Tablet */

@media (
  min-width: 621px
) and (
  max-width: 1099px
) {
  #inventorySection.inventory-exclusive-active-v561
  .inventory-form-grid,

  #inventorySection.inventory-exclusive-active-v561
  .commerce-purchase-header,

  #inventorySection.inventory-exclusive-active-v561
  .commerce-line-builder,

  #inventorySection.inventory-exclusive-active-v561
  .inventory-filter-grid {
    grid-template-columns:
      repeat(2, minmax(0, 1fr));
  }
}

/* Teléfono */

@media (max-width: 620px) {
  #inventorySection.inventory-exclusive-active-v561
  > .inventory-exclusive-header-v561 {
    position: sticky;
    top: 0;
    z-index: 12;

    margin: -4px -4px 10px;
    padding: 11px;

    grid-template-columns: 1fr;

    border-radius: 13px;

    background:
      rgba(255, 255, 255, .97);

    backdrop-filter: blur(14px);
  }

  .inventory-exclusive-back-v561 {
    width: 100%;
  }

  .inventory-exclusive-title-v561 h2 {
    font-size: 19px;
  }

  #inventorySection.inventory-exclusive-active-v561
  > .inventory-panel.inventory-exclusive-panel-v561
  > .card {
    padding: 13px;
    border-radius: 13px;
  }

  #inventorySection.inventory-exclusive-active-v561
  .inventory-form-grid,

  #inventorySection.inventory-exclusive-active-v561
  .commerce-purchase-header,

  #inventorySection.inventory-exclusive-active-v561
  .commerce-line-builder,

  #inventorySection.inventory-exclusive-active-v561
  .inventory-filter-grid,

  #inventorySection.inventory-exclusive-active-v561
  .commerce-subgrid {
    grid-template-columns:
      1fr !important;
  }

  #inventorySection.inventory-exclusive-active-v561
  input,

  #inventorySection.inventory-exclusive-active-v561
  select,

  #inventorySection.inventory-exclusive-active-v561
  textarea,

  #inventorySection.inventory-exclusive-active-v561
  button {
    min-height: 44px;
  }

  /*
    Evitar que tablas y registros amplios deformen
    la pantalla del teléfono.
  */
  #inventorySection.inventory-exclusive-active-v561
  .card,

  #inventorySection.inventory-exclusive-active-v561
  .commerce-operation-grid,

  #inventorySection.inventory-exclusive-active-v561
  #inventoryUnitRows,

  #inventorySection.inventory-exclusive-active-v561
  #purchaseHistoryRows,

  #inventorySection.inventory-exclusive-active-v561
  #inventoryProductRows {
    min-width: 0;
    overflow-x: auto;
  }
}

@keyframes inventory-exclusive-in-v561 {
  from {
    opacity: 0;
    transform: translateY(5px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}
