/* xprhub.com shared header, tools row and footer (2026-11-07). Every page loads this after its own stylesheet. Everything
   here is namespaced (site-*), with its own colour tokens, so it looks the same on every page and never clashes with a
   page's own styles. Top right is the account only (owner: "the top right should be the connected and xpr account
   stuff"), plus the owner's Admin link beside it (2026-11-08); the tools sit in a slim row under the header, and scroll
   sideways on a phone instead of wrapping. */
:root {
  --site-panel: #17112a; --site-panel2: #1e1636; --site-line: #2e2350; --site-ink: #f6f4ff; --site-muted: #a9a0c9;
  --site-purple: #7543e3; --site-purple-hi: #9b7bff; --site-bad: #ff8f8f;
  --site-font: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
}
.site-top, .site-foot {
  box-sizing: border-box; width: 100%; max-width: 1040px; margin-left: auto; margin-right: auto;
  padding-left: 20px; padding-right: 20px; font-family: var(--site-font);
}
.site-top *, .site-foot * { box-sizing: border-box; }
.site-top [hidden] { display: none !important; }

/* ---- header: brand on the left, the account on the right ---- */
.site-top { position: relative; z-index: 30; display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 74px; padding-top: 16px; padding-bottom: 8px; }
.site-brand { flex: none; display: inline-flex; align-items: center; gap: 10px; color: var(--site-ink); text-decoration: none; font: 800 22px/1 var(--site-font); letter-spacing: -.02em; }
.site-brand img { display: block; width: 34px; height: 34px; }
.site-account { position: relative; display: flex; align-items: center; justify-content: flex-end; gap: 10px; min-width: 0; min-height: 46px; }
.site-acct-wrap { position: relative; min-width: 0; max-width: 100%; }

.site-connect { font: 700 14px/1 var(--site-font); color: #fff; background: var(--site-purple); border: 1px solid var(--site-purple); border-radius: 12px; padding: 13px 20px; cursor: pointer; }
.site-connect:hover { background: #8455f0; border-color: #8455f0; }

.site-acct { display: flex; align-items: center; gap: 10px; min-width: 0; max-width: 100%; margin: 0; padding: 5px 12px 5px 5px; font: inherit; color: var(--site-ink); text-align: left; cursor: pointer;
  background: rgba(23, 17, 42, .75); border: 1px solid var(--site-line); border-radius: 999px; }
.site-acct:hover, .site-acct[aria-expanded="true"] { border-color: var(--site-purple-hi); }
.site-avatar { flex: none; display: block; width: 34px; height: 34px; border-radius: 50%; background: var(--site-panel2); object-fit: cover; }
.site-acct-text { display: flex; flex-direction: column; min-width: 0; }
.site-acct-name { font: 700 14px/1.25 var(--site-font); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.site-acct-bal { min-height: 15px; font: 500 12px/1.25 var(--site-font); color: var(--site-muted); font-variant-numeric: tabular-nums; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.site-caret { flex: none; width: 12px; height: 12px; color: var(--site-muted); transition: transform .15s ease; }
.site-acct[aria-expanded="true"] .site-caret { transform: rotate(180deg); }

.site-menu { position: absolute; right: 0; top: calc(100% + 8px); min-width: 170px; padding: 6px; background: var(--site-panel); border: 1px solid var(--site-line); border-radius: 14px; box-shadow: 0 16px 40px rgba(0, 0, 0, .5); }
.site-menu-item { display: block; width: 100%; margin: 0; padding: 10px 12px; font: 600 14px/1.2 var(--site-font); color: var(--site-ink); text-align: left; background: none; border: 0; border-radius: 9px; cursor: pointer; }
.site-menu-item:hover { background: var(--site-panel2); }

/* the unread count on the account menu's Messages item (hidden at 0) */
.site-menu-item .site-badge { display: inline-block; min-width: 18px; margin-left: 8px; padding: 2px 6px; font: 700 11px/1.2 var(--site-font); text-align: center; color: #fff; background: var(--site-purple-hi); border-radius: 999px; }
.site-badge[hidden] { display: none; }
a.site-menu-item { text-decoration: none; box-sizing: border-box; }

/* the owner's Admin link (2026-11-08, owner: "put it in the site wide nav"): left of the account, for xprpoker only. A quiet
   pill the height of the account button; on the admin page itself it shows as the current page. */
.site-admin { flex: none; display: inline-flex; align-items: center; min-height: 46px; padding: 0 16px; font: 600 14px/1 var(--site-font); color: var(--site-muted); text-decoration: none;
  background: rgba(23, 17, 42, .75); border: 1px solid var(--site-line); border-radius: 999px; }
.site-admin:hover { color: var(--site-ink); border-color: var(--site-purple-hi); }
.site-admin[aria-current="page"] { color: var(--site-ink); background: rgba(117, 67, 227, .22); border-color: var(--site-purple-hi); }

/* a wallet error from the header's Connect, under the account area for a few seconds */
.site-note { position: absolute; right: 0; top: calc(100% + 6px); width: max-content; max-width: min(320px, calc(100vw - 32px)); margin: 0; padding: 8px 12px;
  font: 500 13px/1.4 var(--site-font); color: var(--site-bad); background: var(--site-panel); border: 1px solid var(--site-line); border-radius: 10px; overflow-wrap: anywhere; }

/* ---- the notice bar (set on the admin page, 2026-11-07): slim, right under the header, plain text ---- */
.site-notice { box-sizing: border-box; width: 100%; max-width: 1040px; margin: 2px auto 0; padding: 0 20px; font-family: var(--site-font); }
.site-notice * { box-sizing: border-box; }
.site-notice-text { display: flex; align-items: flex-start; gap: 10px; margin: 0; padding: 9px 14px; font: 500 14px/1.45 var(--site-font); color: var(--site-ink);
  background: rgba(117, 67, 227, .16); border: 1px solid rgba(155, 123, 255, .42); border-radius: 12px; overflow-wrap: anywhere; }
.site-notice-text::before { content: ""; flex: none; width: 8px; height: 8px; margin-top: 6px; border-radius: 50%; background: var(--site-purple-hi); }

/* ---- tools row: slim, left aligned, one line; the current tool underlined ---- */

/* ---- footer ---- */
.site-foot { margin-top: 0; padding-top: 20px; padding-bottom: 30px; border-top: 1px solid var(--site-line); color: var(--site-muted); font: 14px/1.6 var(--site-font); }
.site-foot p { margin: 0; }
.site-foot a { color: var(--site-purple-hi); text-decoration: underline; text-underline-offset: 3px; font-weight: 500; }
.site-foot a:hover { color: var(--site-ink); }

.site-brand:focus-visible, .site-connect:focus-visible, .site-acct:focus-visible, .site-admin:focus-visible, .site-menu-item:focus-visible, .site-foot a:focus-visible { outline: 3px solid var(--site-purple-hi); outline-offset: 2px; }
.site-brand:focus-visible, .site-foot a:focus-visible { border-radius: 6px; }

@media (max-width: 520px) {
  .site-top, .site-foot, .site-notice { padding-left: 16px; padding-right: 16px; }
  .site-top { min-height: 66px; padding-top: 12px; }
  .site-brand { gap: 8px; font-size: 20px; }
  .site-brand img { width: 30px; height: 30px; }
  .site-account { gap: 8px; }
  .site-admin { min-height: 42px; padding: 0 13px; }
  .site-acct { gap: 8px; padding-right: 10px; }
  .site-avatar { width: 30px; height: 30px; }
}
@media (prefers-reduced-motion: reduce) {
  .site-caret { transition: none; }
}
