/* Chips & Truths mobile/tablet header hotfix v1.0.47.
   Cache-busted because the prior immutable BaseLayout filename could leave older CSS in browser/CDN caches. */
@media screen and (max-width: 1100px) {
  :root { --sticky-offset: 64px; }
  html, body { max-width: 100%; overflow-x: clip; }
  .topbar { width: 100%; max-width: 100%; overflow: visible; }
  .topbar .topbar-row-1 {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
    width: 100%;
    max-width: 100%;
    min-height: 64px;
    margin: 0;
    padding: 10px 16px;
    gap: 10px;
    border-bottom: 0;
  }
  .topbar .brand {
    display: inline-flex !important;
    align-items: center;
    min-width: 0;
    max-width: 100%;
    overflow: hidden;
    white-space: nowrap;
    font-size: clamp(18px, 4.8vw, 22px);
    line-height: 1.1;
  }
  .topbar .brand > span:first-child {
    display: block;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: clip;
  }
  .topbar .brand-tag { display: none !important; }
  .topbar .header-actions {
    display: inline-flex !important;
    align-items: center;
    justify-content: flex-end;
    margin-left: 0;
    flex: 0 0 auto;
    gap: 8px;
  }
  .topbar .utility,
  .topbar .nav-wrapper,
  .topbar .topbar-row-2,
  .topbar .mega-panel,
  .mega-backdrop {
    display: none !important;
    visibility: hidden !important;
  }
  .topbar .mobile-search-btn,
  .topbar .mobile-menu-toggle {
    display: inline-flex !important;
    visibility: visible !important;
    opacity: 1 !important;
  }
  .topbar .mobile-search-btn {
    align-items: center;
    justify-content: center;
    min-height: 42px;
    padding: 0 12px;
    white-space: nowrap;
  }
  .topbar .mobile-menu-toggle { flex: 0 0 42px; }
  .topbar .mobile-nav-panel {
    display: block !important;
    visibility: visible !important;
    width: 100%;
    max-width: 100%;
    max-height: 0;
    opacity: 0;
    overflow: hidden;
    transform: translateY(-8px);
    transition: max-height .24s ease, opacity .18s ease, transform .2s ease;
    border-top: 1px solid var(--line-soft);
    background: var(--surface);
  }
  .topbar .mobile-nav-panel.open {
    max-height: calc(100vh - 64px);
    max-height: calc(100dvh - 64px);
    opacity: 1;
    overflow-y: auto;
    overscroll-behavior: contain;
    transform: translateY(0);
  }
  body.mobile-menu-open { overflow: hidden; }
}

@media screen and (max-width: 420px) {
  .topbar .topbar-row-1 { padding-inline: 12px; gap: 6px; }
  .topbar .mobile-search-btn { padding-inline: 9px; }
}
