/* Casa Pizza Hotfix 95 — phone header deduplication and dine-in service actions. */

@media (max-width: 820px) {
  .site-header { position:fixed !important; top:0 !important; left:0 !important; right:0 !important; z-index:2500 !important; width:100% !important; }
  body { padding-top:var(--header-h,70px) !important; }
  /* Home/Menu/Cart/Order already live in the mobile bottom navigation. */
  .site-header .order-status-trigger,
  .site-header .menu-toggle {
    display: none !important;
  }

  /* Keep the order-status panel itself alive: the bottom-nav “Պատվեր” button opens it. */
  .site-header .order-status-widget {
    display: block !important;
    position: static !important;
    width: 0 !important;
    min-width: 0 !important;
  }

  /* Dine-in service actions now belong to the header instead of a floating bar. */
  .site-header .design-service-tools {
    position: static !important;
    width: auto !important;
    min-width: 0 !important;
    padding: 0 !important;
    border: 0 !important;
    border-radius: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
    display: flex !important;
    align-items: center !important;
    gap: 4px !important;
  }

  .site-header .service-header-actions {
    position: static !important;
    inset: auto !important;
    width: auto !important;
    padding: 0 !important;
    border: 0 !important;
    border-radius: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
    grid-template-columns: none !important;
    display: flex;
    align-items: center;
    gap: 4px !important;
  }

  .site-header .service-header-actions[hidden] {
    display: none !important;
  }

  .site-header .service-header-button {
    min-width: 0 !important;
    min-height: 40px !important;
    padding: 6px 8px !important;
    font-size: .68rem !important;
    line-height: 1.05 !important;
    border-radius: 11px !important;
  }

  /* There is no longer a second fixed service bar above the bottom nav. */
  body { padding-bottom: 72px !important; }

  /* Order status opens directly above the mobile bottom navigation. */
  .order-status-panel {
    position: fixed !important;
    top: auto !important;
    left: 8px !important;
    right: 8px !important;
    bottom: calc(76px + env(safe-area-inset-bottom)) !important;
    width: auto !important;
  }

  .design-system-toast,
  .toast {
    bottom: calc(78px + env(safe-area-inset-bottom)) !important;
  }
}

@media (max-width: 430px) {
  .site-header .header-tools { gap: 4px !important; }
  .site-header .service-header-button { padding-inline: 7px !important; }
}

@media (max-width: 360px) {
  /* Preserve room for both table-service controls on the narrowest phones. */
  html[data-restaurant-service="active"] .site-header .brand-copy {
    display: none !important;
  }
  html[data-restaurant-service="active"] .site-header .brand {
    flex: 0 1 auto !important;
  }
  html[data-restaurant-service="active"] .site-header .service-header-button {
    padding-inline: 6px !important;
    font-size: .65rem !important;
  }
}
