/* Navegación inferior móvil: cinco accesos y lanzador central. */
.app-dock { display: none; }
.mobile-app-launcher, .mobile-app-launcher-overlay { display: none; }

@media (max-width: 767px) {
  .app-main { padding-bottom: calc(5.75rem + env(safe-area-inset-bottom)); }
  .app-dock { position: fixed; inset: auto 0 0; z-index: var(--z-header); display: grid; grid-template-columns: repeat(5, 1fr); align-items: end; height: calc(4.25rem + env(safe-area-inset-bottom)); padding: 0.35rem var(--space-2) max(0.35rem, env(safe-area-inset-bottom)); border-top: 1px solid var(--border-color); background: color-mix(in srgb, var(--bg-elevated) 90%, transparent); box-shadow: 0 -8px 24px rgba(0, 0, 0, 0.1); backdrop-filter: blur(20px) saturate(180%); -webkit-backdrop-filter: blur(20px) saturate(180%); }
  .dock-item { position: relative; display: flex; align-items: center; justify-content: center; flex-direction: column; gap: 0.15rem; min-width: 0; min-height: 3.5rem; padding: 0.25rem; color: var(--text-secondary); border: 0; border-radius: var(--radius-md); background: transparent; }
  .dock-item:hover { text-decoration: none; }
  .dock-item.active { color: var(--accent); }
  .dock-item__icon { display: inline-flex; width: 1.35rem; height: 1.35rem; }
  .dock-item__icon svg { width: 100%; height: 100%; }
  .dock-item__label { width: 100%; overflow: hidden; font-size: 0.625rem; font-weight: var(--font-medium); text-align: center; text-overflow: ellipsis; white-space: nowrap; }
  .dock-item--launcher { align-self: start; color: var(--text-inverse); }
  .dock-item--launcher .dock-item__icon { display: grid; place-items: center; width: 3.25rem; height: 3.25rem; margin-top: -1.15rem; border: 4px solid var(--bg-primary); border-radius: 50%; background: var(--accent); box-shadow: var(--shadow-md); }
  .dock-item--launcher .dock-item__icon svg { width: 1.35rem; height: 1.35rem; }
  .dock-item--launcher .dock-item__label { color: var(--text-secondary); }
  .mobile-app-launcher-overlay { position: fixed; inset: 0; z-index: calc(var(--z-modal) - 2); background: rgba(0, 0, 0, 0.5); opacity: 0; transition: opacity var(--transition-fast); }
  .mobile-app-launcher-overlay.open { display: block; opacity: 1; }
  .mobile-app-launcher { position: fixed; inset: auto 0 0; z-index: calc(var(--z-modal) - 1); display: block; max-height: min(82vh, 46rem); padding: var(--space-2) var(--space-4) calc(var(--space-5) + env(safe-area-inset-bottom)); overflow-y: auto; border: 1px solid var(--border-color); border-radius: var(--radius-xl) var(--radius-xl) 0 0; background: var(--bg-elevated); box-shadow: var(--shadow-lg); transform: translateY(105%); transition: transform 240ms ease; }
  .mobile-app-launcher.open { transform: translateY(0); }
  .mobile-app-launcher__handle { width: 2.75rem; height: 0.25rem; margin: 0 auto var(--space-3); border-radius: var(--radius-full); background: var(--border-strong); }
  .mobile-app-launcher__header { display: flex; align-items: center; justify-content: space-between; margin-bottom: var(--space-4); }
  .mobile-app-launcher__header > div { display: flex; flex-direction: column; }
  .mobile-app-launcher__header span { color: var(--text-secondary); font-size: var(--text-xs); }
  .mobile-app-launcher__grid { display: grid; grid-template-columns: 1fr; gap: var(--space-3); }
  .mobile-app-group { overflow: hidden; border: 1px solid var(--border-color); border-radius: var(--radius-lg); background: var(--bg-primary); }
  .mobile-app-group__title { display: flex; align-items: center; gap: var(--space-2); padding: var(--space-3); color: var(--text-primary); font-size: var(--text-sm); font-weight: var(--font-semibold); background: var(--bg-secondary); }
  .mobile-app-group__title span { display: inline-flex; width: 1rem; height: 1rem; color: var(--accent); }
  .mobile-app-group__title svg { width: 100%; height: 100%; }
  .mobile-app-group a { display: flex; align-items: center; justify-content: space-between; gap: var(--space-2); min-height: 2.75rem; padding: var(--space-2) var(--space-3); color: var(--text-primary); font-size: var(--text-sm); border-top: 1px solid var(--border-color); }
  .mobile-app-group a > span { display: inline-flex; width: 0.875rem; height: 0.875rem; color: var(--text-tertiary); }
  .mobile-app-group a svg { width: 100%; height: 100%; }
  body.launcher-open { overflow: hidden; }
  .app-menu-bar__toggle { display: none; }
}

@media (min-width: 560px) and (max-width: 767px) { .mobile-app-launcher__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
