/*
 * Final mobile scoring layer.
 * Loaded after the terminal layer so mobile IA cannot be overridden by legacy score CSS.
 */

@media (max-width: 760px) {
  html body.tenant-app-body[data-app-surface="workspace"] .tenant-mobile-console-nav {
    display: none !important;
  }

  html body.tenant-app-body[data-app-surface="workspace"] .tenant-mobile-nav {
    display: grid !important;
    grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
    position: fixed !important;
    right: 0 !important;
    bottom: 0 !important;
    left: 0 !important;
    z-index: 90 !important;
    min-height: 76px !important;
    padding: 8px 8px max(16px, env(safe-area-inset-bottom)) !important;
    border-top: 1px solid #cbd5e1 !important;
    background: rgba(255, 255, 255, .99) !important;
    box-shadow: 0 -4px 10px rgba(15, 23, 42, .05) !important;
  }

  html body.tenant-app-body[data-app-surface="workspace"] .tenant-mobile-admin-entry,
  html body.tenant-app-body[data-app-surface="workspace"] .tenant-mobile-nav-btn.hidden {
    display: none !important;
  }

  html body.tenant-app-body[data-app-surface="workspace"] .tenant-mobile-nav-btn {
    display: grid !important;
    grid-template-rows: auto !important;
    place-items: center !important;
    align-content: center !important;
    gap: 3px !important;
    min-height: 44px !important;
    padding: 6px 3px !important;
    border: 1px solid transparent !important;
    border-radius: 4px !important;
    background: transparent !important;
    color: #475569 !important;
    box-shadow: none !important;
  }

  html body.tenant-app-body[data-app-surface="workspace"] .tenant-mobile-nav-btn.is-active {
    border-color: #cbd5e1 !important;
    background: #f8fafc !important;
    color: #0f172a !important;
    box-shadow: none !important;
  }

  html body.tenant-app-body[data-app-surface="workspace"] .tenant-mobile-nav-btn::before,
  html body.tenant-app-body[data-app-surface="workspace"] .tenant-mobile-nav-btn::after,
  html body.tenant-app-body[data-app-surface="workspace"] .tenant-mobile-nav-btn.is-active::before,
  html body.tenant-app-body[data-app-surface="workspace"] .tenant-mobile-nav-btn.is-active::after {
    display: none !important;
    content: none !important;
  }

  html body.tenant-app-body[data-app-surface="workspace"] .tenant-mobile-nav-icon {
    display: none !important;
  }

  html body.tenant-app-body[data-app-surface="workspace"] .tenant-mobile-nav-label {
    display: block !important;
    margin: 0 !important;
    padding: 0 !important;
    color: inherit !important;
    font-size: .68rem !important;
    font-weight: 900 !important;
    line-height: 1 !important;
    text-align: center !important;
    white-space: nowrap !important;
  }

  html body.tenant-app-body[data-app-surface="workspace"] .tenant-mobile-nav-status {
    display: none !important;
  }

  html body.tenant-app-body[data-app-surface="workspace"] .tenant-mobile-nav-btn.is-active .tenant-mobile-nav-status {
    color: #334155 !important;
  }

  html body.tenant-app-body[data-app-surface="workspace"] .tenant-app-shell {
    padding-bottom: 84px !important;
  }

  html body.tenant-app-body[data-app-surface="workspace"] #app-stage-title {
    margin: 10px 0 8px !important;
    font-size: 1.14rem !important;
  }

  html body.tenant-app-body[data-app-surface="workspace"] #app-stage-timeline .hvx360-mobile-inline-action {
    grid-template-columns: minmax(0, 1fr) !important;
    gap: 6px !important;
  }

  html body.tenant-app-body[data-app-surface="workspace"] #app-stage-timeline .hvx360-mobile-inline-action span {
    display: none !important;
  }

  html body.tenant-app-body[data-app-surface="workspace"] #app-stage-timeline .hvx360-mobile-inline-action .hvx100-mobile-primary-action {
    width: 100% !important;
    min-height: 36px !important;
    justify-self: stretch !important;
  }
}
