/* V7.3: jerarquia de capas definitiva */

/* El contenedor principal no debe crear una capa por encima de la cabecera. */
#app {
  position: relative !important;
  isolation: isolate !important;
}

/* Cabecera y pestañas en capas superiores, opacas y aceleradas. */
#app > header.top,
#app > .top {
  position: sticky !important;
  top: 0 !important;
  z-index: 2147483647 !important;
  background: #4F4D46 !important;
  isolation: isolate !important;
  transform: translateZ(0) !important;
  backface-visibility: hidden !important;
}

#app > nav.tabs,
#app > .tabs {
  position: sticky !important;
  top: 100px !important;
  z-index: 2147483646 !important;
  background: #F8F6EA !important;
  isolation: isolate !important;
  transform: translateZ(0) !important;
  backface-visibility: hidden !important;
}

/* Toda la zona de contenido queda dentro de una única capa baja. */
#app > main,
#app > .content,
#app .view {
  position: relative !important;
  z-index: 0 !important;
  transform: none !important;
}

#app .section,
#app .grid,
#app .item {
  position: relative !important;
  z-index: auto !important;
  transform: none !important;
  filter: none !important;
  perspective: none !important;
}

/* La X solo está por encima del contenido de su propia tarjeta. */
#app .item > .delete-card-v5 {
  position: absolute !important;
  top: 10px !important;
  right: 10px !important;
  left: auto !important;
  bottom: auto !important;
  z-index: 2 !important;
  transform: none !important;
}

/* Ventanas y menú lateral sí deben superar a la cabecera. */
#drawer,
#shade,
.v3-modal,
.photo-zoom-modal,
.example-final-modal,
.accounts-modal,
.v5-prompt,
.v6-dialog,
.dialog-v61 {
  z-index: 2147483647 !important;
}

@media (max-width: 700px) {
  #app > nav.tabs,
  #app > .tabs {
    top: 100px !important;
  }
}
