/**
 * MB4 Category 12 — Mobile Header Cleanup
 * Simplify to 4 elements: hamburger | title | notifications | profile
 * Move less-used items (language, theme, logout) into the side drawer.
 */

@media (max-width: 768px) {
  .header {
    padding: 10px 14px !important;
    height: auto !important;
    min-height: 54px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    gap: 10px !important;
    position: sticky !important;
    top: 0 !important;
    z-index: 100 !important;
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    background: rgba(10, 10, 10, 0.82) !important;
    border-bottom: 1px solid rgba(245, 158, 11, 0.14) !important;
  }

  .header-actions {
    display: flex !important;
    align-items: center !important;
    gap: 6px !important;
    flex-shrink: 0 !important;
  }

  /* Hide less-important header elements on mobile — moved to drawer */
  #langToggleBtn,
  .lang-toggle,
  #themeToggleBtn,
  #themeToggleBtnV2,
  .logout-btn,
  #logoutBtn,
  .user-badge,
  .breadcrumbs {
    display: none !important;
  }

  /* Re-show theme toggle only if explicitly opted in */
  .header-actions .keep-on-mobile {
    display: inline-flex !important;
  }

  /* Bell icon — ensure 44x44 tap zone + badge visibility */
  #bellBtn {
    min-width: 44px !important;
    min-height: 44px !important;
    padding: 8px !important;
    position: relative;
  }
  #bellBadge {
    font-size: 10px !important;
    min-width: 16px !important;
    padding: 2px 6px !important;
    line-height: 1.2 !important;
  }

  /* Page title clipped sensibly */
  #pageTitle,
  .header-title {
    flex: 1 1 auto !important;
    text-align: center !important;
    font-family: 'Playfair Display', Georgia, serif !important;
    font-weight: 700 !important;
    font-size: clamp(14px, 4.2vw, 18px) !important;
    color: #F3F4F6 !important;
    white-space: nowrap !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    padding: 0 8px !important;
  }

  /* Profile avatar slot — right side */
  .mobile-profile-avatar {
    width: 34px !important;
    height: 34px !important;
    border-radius: 50% !important;
    background: linear-gradient(135deg, #F59E0B, #D97706);
    color: #0a0a0a;
    font-weight: 700;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 13px;
    cursor: pointer;
    flex-shrink: 0;
    position: relative;
  }
  .mobile-profile-avatar::after {
    /* online/away dot */
    content: '';
    position: absolute;
    right: -2px;
    bottom: -2px;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: #10B981;
    border: 2px solid #0a0a0a;
  }
  .mobile-profile-avatar.status-away::after { background: #F59E0B; }
  .mobile-profile-avatar.status-offline::after { background: #6B7280; }
}
