/* V5: shared header geometry and mobile menu anchored to the actual commandbar. */
@media (min-width:701px) {
  /* Match the regular page's entry-v2 header rules, without importing its page styles. */
  body.game-page .archive-commandbar .archive-live {
    display:flex; align-items:center; gap:6px;
    font-family:Arial,Helvetica,sans-serif; letter-spacing:.04em; font-size:9px;
    flex:0 0 auto; width:auto; min-width:0; margin:0; white-space:nowrap;
  }
  body.game-page .archive-live .cp-total-item {display:inline-block; margin:0; padding:0;}
  body.game-page .archive-live .cp-total-divider {display:inline; font-style:normal; color:#59616e; margin:0;}
  body.game-page .archive-live > span {display:inline-block; width:6px; height:6px; margin-right:7px; vertical-align:middle;}
}
@media (max-width:700px) {
  html body .site-shell > .archive-rail {
    position:relative; top:auto; inset:auto; z-index:70; height:56px;
    width:100%; flex-direction:row; align-items:center; padding:8px 12px;
  }
  .site-shell > .archive-rail .rail-brand {min-width:0; flex:0 1 auto;}
  .site-shell > .archive-rail .rail-brand img {max-width:min(46vw,180px);height:auto;}
  html body .site-shell > .archive-rail > .archive-live {
    display:flex; position:relative; flex-direction:column; align-items:flex-end;
    justify-content:center; gap:2px; margin-left:auto; padding-left:13px;
    white-space:nowrap; font-size:9px; letter-spacing:0; line-height:1.25;
  }
  .site-shell > .archive-rail > .archive-live > span {
    display:block; position:absolute; left:0; top:2px; transform:none;
    width:6px; height:6px; margin:0; border-radius:50%;
    background:var(--mint,#63f5c5); box-shadow:0 0 12px var(--mint,#63f5c5);
  }
  .site-shell > .archive-rail > .archive-live .cp-total-item {display:block;}
  .site-shell > .archive-rail > .archive-live .cp-total-divider {display:none;}
  html body .site-shell > .archive-commandbar {
    position:sticky; top:0; z-index:90; height:64px; padding:8px 12px;
    gap:9px; margin:0; transform:none; background:#08090c; backdrop-filter:none;
  }
  html body .site-shell > .archive-commandbar > .archive-live {display:none;}
  html body .site-shell > .archive-commandbar > .global-search-wrap {
    flex:1 1 0; min-width:0; max-width:none; margin:0;
  }
  html body .site-shell > .archive-commandbar > .menu-btn {
    display:block; flex:0 0 auto; margin:0; min-width:50px; min-height:44px;
    padding:8px 11px; cursor:pointer;
  }
  .site-shell > .archive-rail > .menu-btn {display:none;}
  /* JS updates --csp-nav-top from commandbar.getBoundingClientRect().bottom. */
  html body .site-shell > .archive-rail > .top-nav {
    position:fixed; top:var(--csp-nav-top,120px); left:0; right:0; z-index:130;
    max-height:calc(100dvh - var(--csp-nav-top,120px)); overflow-y:auto;
    margin:0; background:#0b0d11; border-bottom:1px solid #2a2f38;
  }
  .site-shell > .archive-rail > .top-nav.open {display:grid; grid-template-columns:1fr 1fr;}
  html body .site-shell > .archive-commandbar.csp-sticky-fixed {
    position:fixed; top:0; left:0; right:0; width:100%; z-index:100;
  }
  html body .site-shell > .csp-sticky-spacer {height:64px;display:none;}
  html body .site-shell > .csp-sticky-spacer.csp-sticky-active {display:block;}
}
@media(max-width:350px) {
  .site-shell > .archive-rail .archive-live {font-size:8px;}
  .site-shell > .archive-rail .rail-brand img {max-width:145px;}
}
