/* ═══════════════════════════════════════════════════════════
   HEXLAND — Shared page header  (lobby, leaderboard, …)
   ═══════════════════════════════════════════════════════════ */

/* Fixed full-width bar */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: 70px;
  z-index: 100;
  display: flex;
  align-items: center;
  padding: 6px 14px 0;
  background: rgba(var(--ink-rgb), .06);
  border-bottom: 1px solid rgba(var(--ink-rgb), .1);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
}

/* ── Left: logo ─────────────────────────────────────────── */
.sh-logo-link {
  display: flex;
  align-items: center;
  flex-shrink: 0;
  text-decoration: none;
}

.sh-logo {
  height: 72px;
  width: auto;
  object-fit: contain;
  filter: drop-shadow(0 1px 6px rgba(255,200,80,.4));
}

/* ── Centre: page title — true-centred regardless of left/right zone widths */
.sh-title {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  font-family: 'Cinzel', serif;
  font-size: 1.9rem;
  font-weight: 900;
  color: var(--text-cream);
  letter-spacing: 3px;
  text-transform: uppercase;
  white-space: nowrap;
  pointer-events: none;
  user-select: none;
  text-shadow: 0 1px 10px rgba(240,160,48,.3);
}

/* ── Right: auth bar + extra buttons ────────────────────── */
.sh-right {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 8px;
}

/* Strip the pill from auth-bar when inside the site-header */
.site-header .auth-bar {
  position: static;
  top: auto;
  right: auto;
  left: auto;
  background: none;
  border: none;
  border-radius: 0;
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
  padding: 0;
  justify-content: flex-start;
  gap: 8px;
}

/* Strip fixed position from btn-go-pro when inside the site-header */
.site-header .btn-go-pro {
  position: static;
  top: auto;
  right: auto;
  z-index: auto;
}

/* ── "Back to lobby" link shown in headers of non-lobby pages ── */
.sh-back-link {
  font-size: .8rem;
  color: rgba(var(--ink-rgb), .6);
  text-decoration: none;
  padding: 5px 10px;
  border-radius: 6px;
  border: 1px solid rgba(var(--ink-rgb), .16);
  background: rgba(var(--ink-rgb), .06);
  transition: background .15s, color .15s;
  white-space: nowrap;
  flex-shrink: 0;
}

.sh-back-link:hover {
  background: rgba(var(--ink-rgb), .14);
  color: rgba(var(--ink-rgb), .9);
}

/* ── Mobile: two-row layout ──────────────────────────────── */
/* Row 1: logo (left) + right controls (right)               */
/* Row 2: page title, full-width, centred                    */
@media (max-width: 540px) {
  .site-header {
    height: 86px;
    padding: 6px 10px 0;
    flex-wrap: wrap;
    align-items: center;
    align-content: space-between;
  }
  .sh-logo { height: 52px; }
  .sh-title {
    position: static;
    transform: none;
    order: 3;          /* pushes title after logo + sh-right into row 2 */
    flex: 0 0 100%;
    text-align: center;
    font-size: 1.3rem;
    letter-spacing: 2px;
    line-height: 1;
    padding-bottom: 6px;
  }
  /* Hide the back-link on mobile — navigation lives in the ham-menu */
  .sh-back-link { display: none; }
}
