/* =========================================================
   ST7D v7.7.1 - NAVIGATION DISCOVERY + DENSITY PASS
   More of the site is visible without turning the header into
   a cramped toolbar. Mobile keeps the existing hamburger flow.
   ========================================================= */

/* New Explore menu */
.nav-explore-dropdown{width:min(610px,calc(100vw - 40px));padding:14px!important}
.nav-explore-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}
.nav-explore-grid>a{min-width:0;padding:12px 13px!important;border:1px solid rgba(255,255,255,.07);border-radius:10px;background:rgba(255,255,255,.018);text-decoration:none}
.nav-explore-grid>a>span{display:block;margin-bottom:5px;color:#79726f;font-size:8px;font-weight:900;letter-spacing:.13em}
.nav-explore-grid>a>strong{display:block;color:#ded8d4;font-size:11px;line-height:1.2}
.nav-explore-grid>a>strong em{margin-left:4px;color:#ef5d62;font-size:8px;font-style:normal;letter-spacing:.06em}
.nav-explore-grid>a>small{display:block;margin-top:5px;color:#716b68;font-size:9px;line-height:1.42}
.nav-explore-grid>a:hover,.nav-explore-grid>a:focus-visible,.nav-explore-grid>a.active-child{border-color:rgba(235,43,43,.26);background:linear-gradient(135deg,rgba(235,43,43,.065),rgba(255,255,255,.018));transform:none!important}
.nav-explore-grid>a:hover>strong,.nav-explore-grid>a:focus-visible>strong,.nav-explore-grid>a.active-child>strong{color:#fff}

@media(min-width:1281px){
  /* Spend less room per destination so important pages can live in the open. */
  .header{gap:7px!important;padding-left:clamp(12px,1.35vw,24px)!important;padding-right:clamp(12px,1.35vw,24px)!important}
  .header:after{left:clamp(12px,1.35vw,24px)!important;right:clamp(12px,1.35vw,24px)!important}
  .logo-wrap{width:88px!important;flex-basis:88px!important}
  .header .primary-nav{flex:1 1 auto!important;justify-content:flex-start!important;gap:5px!important;min-width:0}
  .header .primary-nav>.nav-primary-link,.header .nav-menu-toggle{min-height:36px!important;padding-left:4px!important;padding-right:4px!important;font-size:10.45px!important;letter-spacing:.10px!important;white-space:nowrap}
  .header .nav-menu-toggle{gap:2px!important}
  .header .nav-menu-toggle svg{width:8px!important;height:8px!important}

  /* Direct-discovery links are intentionally plain navigation, not oversized action chips. */
  .header .nav-events-link,.header .nav-mods-link{color:#c7c1bd!important}
  .header .nav-events-link.active-nav,.header .nav-mods-link.active-nav{color:#fff!important}

  /* Vote/Donor remain action chips, but stop spending unnecessary width. */
  .header .primary-nav>a[href="vote.html"]{min-height:32px!important;margin-left:1px!important;padding:0 8px!important}
  .header .primary-nav>.nav-donor-link{min-height:32px!important;padding:0 8px!important}

  /* Utility cluster: keep functionality, reclaim space. */
  .header-account-mount{gap:5px!important;margin-left:0!important;padding-left:8px!important}
  .portal-staff-hq-shortcut{height:40px!important;min-width:68px!important;padding:0 9px!important;font-size:10px!important}
  .portal-theme-toggle,.portal-notification-button{width:38px!important;height:38px!important;min-width:38px!important}
  .portal-chat-shortcut{height:38px!important;min-width:76px!important;padding:0 9px!important;gap:6px!important}
  .portal-chat-shortcut span{font-size:9.5px!important;letter-spacing:.35px!important}
  .portal-chat-shortcut svg{width:16px!important;height:16px!important}
  .portal-account-button{height:40px!important;min-width:112px!important;max-width:136px!important;padding-left:5px!important;padding-right:7px!important;gap:7px!important}
  .portal-account-button img,.portal-account-button .portal-avatar-fallback{width:30px!important;height:30px!important;flex-basis:30px!important}
  .portal-account-copy>strong{max-width:68px!important;font-size:10.5px!important}
  .portal-role{font-size:9.5px!important;letter-spacing:.65px!important}

  /* Discord becomes an icon control. The purple halo/status bead makes it obvious without a label. */
  .portal-discord-shortcut{position:relative;width:38px!important;height:38px!important;min-width:38px!important;padding:0!important;gap:0!important;border-radius:10px!important;color:#bec4ff!important;border-color:rgba(88,101,242,.42)!important;background:radial-gradient(circle at 50% 35%,rgba(111,122,255,.19),rgba(88,101,242,.08) 55%,#101116 76%)!important;box-shadow:0 0 0 1px rgba(88,101,242,.08),0 0 15px rgba(88,101,242,.10)!important}
  .portal-discord-shortcut span{display:none!important}
  .portal-discord-shortcut svg{width:19px!important;height:19px!important;stroke-width:1.85!important}
  .portal-discord-shortcut:after{content:"";position:absolute;right:5px;top:5px;width:5px;height:5px;border-radius:50%;background:#8c95ff;box-shadow:0 0 7px rgba(140,149,255,.92)}
  .portal-discord-shortcut:hover,.portal-discord-shortcut:focus-visible{color:#fff!important;border-color:rgba(111,122,255,.78)!important;background:radial-gradient(circle at 50% 35%,rgba(125,135,255,.34),rgba(88,101,242,.16) 58%,#141522 80%)!important;box-shadow:0 0 0 1px rgba(88,101,242,.18),0 0 22px rgba(88,101,242,.26)!important}

  .header .nav-explore-dropdown{max-height:min(650px,calc(100vh - 106px));overflow:auto;overscroll-behavior:contain;scrollbar-width:thin;scrollbar-color:rgba(235,43,43,.38) transparent}
}

/* Tight desktop band: keep all headline destinations visible before hamburger mode. */
@media(min-width:1281px) and (max-width:1500px){
  .header{gap:5px!important;padding-left:10px!important;padding-right:10px!important}
  .header:after{left:10px!important;right:10px!important}
  .logo-wrap{width:80px!important;flex-basis:80px!important}
  .header .primary-nav{gap:3px!important}
  .header .primary-nav>.nav-primary-link,.header .nav-menu-toggle{font-size:9.9px!important;padding-left:3px!important;padding-right:3px!important}
  .header .primary-nav>a[href="vote.html"],.header .primary-nav>.nav-donor-link{padding-left:7px!important;padding-right:7px!important}
  .header-account-mount{gap:4px!important;padding-left:6px!important}
  .portal-staff-hq-shortcut{min-width:48px!important;padding:0 7px!important}
  .portal-staff-hq-full{display:none!important}.portal-staff-hq-short{display:inline!important}
  .portal-chat-shortcut{width:38px!important;min-width:38px!important;padding:0!important}
  .portal-chat-shortcut span{display:none!important}
  .portal-account-button{min-width:98px!important;max-width:108px!important}
  .portal-account-copy>strong{max-width:46px!important}
}

@media(max-width:1280px){
  .nav-explore-grid{grid-template-columns:1fr 1fr;margin-right:4px}
  .header .nav-explore-dropdown{width:100%!important;max-height:none!important;overflow:visible!important}
  /* Discord remains icon-only on touch layouts too. */
  .portal-discord-shortcut span{display:none!important}
}
@media(max-width:620px){
  .nav-explore-grid{grid-template-columns:1fr}
  .nav-explore-grid>a>small{display:none}
  .nav-explore-grid>a{padding:10px 11px!important}
}

html[data-site-theme="light"] .nav-explore-grid>a{border-color:rgba(45,37,33,.10);background:rgba(45,37,33,.018)}
html[data-site-theme="light"] .nav-explore-grid>a>span,html[data-site-theme="light"] .nav-explore-grid>a>small{color:#746b66}
html[data-site-theme="light"] .nav-explore-grid>a>strong{color:#312b28}
html[data-site-theme="light"] .portal-discord-shortcut{color:#4f5bd5!important;background:radial-gradient(circle at 50% 35%,rgba(88,101,242,.10),#f2f3ff 62%,#eceeff 82%)!important;border-color:rgba(88,101,242,.32)!important}
