/* TDL — Inventario mobile v1 (solo celular). El inventario se carga dentro de /inventario en un marco (?embedded=1). */
@media (max-width: 767px) {
  /* Dentro del marco no hay header: sacar el espacio que se reservaba para él */
  html body.page-inventario:not(#a):not(#b):not(#c):not(#d):not(#e) .app-shell-offset:has(> main.embedded-inventory-shell) { padding-top: 6px !important; min-height: 0 !important; }
  html body.page-inventario:not(#x):not(#y) main.embedded-inventory-shell { padding: 0 !important; }

  /* Vistas (Inventario, Usos, Dinos guardados, Evento): una sola fila de 4 */
  html body.page-inventario:not(#x):not(#y) .inventory-view-switcher {
    display: grid !important; grid-template-columns: repeat(4, minmax(0,1fr)) !important; gap: 6px !important; padding: 6px !important;
  }
  html body.page-inventario:not(#x):not(#y) .inventory-view-btn {
    min-height: 58px !important; height: auto !important; padding: 8px 4px !important; font-size: 11px !important; line-height: 1.2 !important;
    flex-direction: column !important; gap: 4px !important; white-space: normal !important; text-align: center !important;
  }
  html body.page-inventario:not(#x):not(#y) .inventory-view-btn i { font-size: 15px !important; }
  html body.page-inventario:not(#x):not(#y) .inventory-view-count { font-size: 11px !important; }

  /* Filtros: fila de botones que se desliza de costado */
  html body.page-inventario:not(#x):not(#y) div:has(> .inventory-filter-btn) {
    display: flex !important; flex-wrap: nowrap !important; gap: 8px !important; overflow-x: auto !important; scrollbar-width: none;
    margin-bottom: 18px !important; padding-bottom: 2px !important;
  }
  html body.page-inventario:not(#x):not(#y) div:has(> .inventory-filter-btn)::-webkit-scrollbar { display: none; }
  html body.page-inventario:not(#x):not(#y) .inventory-filter-btn {
    flex: 0 0 auto !important; width: auto !important; min-height: 40px !important; padding: 0 16px !important; font-size: 13px !important;
    white-space: nowrap !important; border-radius: 999px !important;
  }

  /* Tickets de caja: 2 columnas compactas */
  html body.page-inventario:not(#x):not(#y) .tdl-tk-grid { grid-template-columns: repeat(2, minmax(0,1fr)) !important; gap: 10px !important; }
  html body.page-inventario:not(#x):not(#y) .tdl-tk { padding: 10px !important; gap: 4px !important; }
  html body.page-inventario:not(#x):not(#y) .tdl-tk-art { height: auto !important; margin-bottom: 4px !important; }
  html body.page-inventario:not(#x):not(#y) .tdl-tk-art img { height: auto !important; max-height: 70px !important; width: 100% !important; object-fit: contain !important; }
  html body.page-inventario:not(#x):not(#y) .tdl-tk-label { font-size: 11px !important; }
  html body.page-inventario:not(#x):not(#y) .tdl-tk-name { font-size: 18px !important; line-height: 1.15 !important; }
  html body.page-inventario:not(#x):not(#y) .tdl-tk-count { font-size: 17px !important; }
  html body.page-inventario:not(#x):not(#y) .tdl-tk-btn { min-height: 40px !important; font-size: 12px !important; padding: 0 6px !important; }
  html body.page-inventario:not(#x):not(#y) .tdl-tk-kicker { font-size: 12px !important; }

  /* El regalo (dino Prime) ocupa las dos columnas para que no quede apretado */
  html body.page-inventario:not(#x):not(#y) .tdl-tk-grid > .item-card { grid-column: 1 / -1 !important; }

  /* Tarjetas de dinos y objetos: textos legibles */
  html body.page-inventario:not(#x):not(#y) .item-card h4 { font-size: 15px !important; }
  html body.page-inventario:not(#x):not(#y) .item-card button.w-full,
  html body.page-inventario:not(#x):not(#y) .item-card a.w-full { font-size: 11px !important; line-height: 1.2 !important; padding: 9px 6px !important; white-space: normal !important; }
  html body.page-inventario:not(#x):not(#y) .item-card .flex span,
  html body.page-inventario:not(#x):not(#y) .item-card span.px-2\.5 { font-size: 11px !important; }
  html body.page-inventario:not(#x):not(#y) .rank-ticket-label { font-size: 11px !important; }
  html body.page-inventario:not(#x):not(#y) .gift-inventory-ribbon,
  html body.page-inventario:not(#x):not(#y) .gift-inventory-eyebrow { font-size: 11px !important; }
  html body.page-inventario:not(#x):not(#y) .item-card .trash-btn { width: 36px !important; height: 36px !important; }
}
