@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800;900&display=swap');

/* ═══════════════════════════════════════════════════════
   SCOUTICS Shell — Maya Chen portfolio design system
  Blue nav · Coral hero · Inter · Flat · Zero shadows
  Light: blue + white + near-black
  Dark:  near-black + blue accent
   ═══════════════════════════════════════════════════════ */

:root {
  --yellow:            #4F7FFF;
  --coral:             #F28272;
  --ink:               #1a1a1a;
  --ink-2:             rgba(26,26,26,0.55);
  --ink-3:             rgba(26,26,26,0.35);
  --ink-4:             rgba(26,26,26,0.15);

  /* Shell tokens */
  --shell-paper:       #ffffff;
  --shell-paper-warm:  #f5f5f5;
  --shell-surface:     #ffffff;
  --shell-surface-2:   #f5f5f5;
  --shell-surface-3:   #ebebeb;
  --shell-ink:         #1a1a1a;
  --shell-ink-soft:    rgba(26,26,26,0.55);
  --shell-ink-faint:   rgba(26,26,26,0.35);
  --shell-rule:        rgba(26,26,26,0.10);
  --shell-rule-strong: rgba(26,26,26,0.18);
  --shell-red:         #1a1a1a;
  --shell-red-dim:     rgba(26,26,26,0.06);
  --shell-red-glow:    rgba(26,26,26,0.10);
  --shell-teal:        #1a1a1a;
  --shell-teal-dim:    rgba(26,26,26,0.06);
  --shell-indigo:      #1a1a1a;
  --brand-red:         #1a1a1a;

  --nav-bg:            #4F7FFF;
  --nav-border:        #4F7FFF;
  --tab-active-color:  #1a1a1a;
  --tab-active-bg:     rgba(26,26,26,0.07);
  --tab-hover-bg:      rgba(26,26,26,0.05);
  --tab-color:         rgba(26,26,26,0.50);

  --sans:         'Inter', system-ui, sans-serif;
  --serif:        'Inter', system-ui, sans-serif;
  --mono:         'Inter', system-ui, sans-serif;
  --brand-serif:  'Inter', system-ui, sans-serif;

  /* page aliases */
  --dark:       #ffffff;
  --bg:         #ffffff;
  --bg2:        #ffffff;
  --bg3:        #f5f5f5;
  --bg4:        #ebebeb;
  --panel:      #ffffff;
  --panel-2:    #f5f5f5;
  --surface:    #ffffff;
  --text:       #1a1a1a;
  --muted:      rgba(26,26,26,0.55);
  --faint:      rgba(26,26,26,0.35);
  --border:     rgba(26,26,26,0.10);
  --border-sub: rgba(26,26,26,0.06);
  --border-bright: rgba(26,26,26,0.20);
  --line:       rgba(26,26,26,0.10);
  --accent:     #1a1a1a;
  --accent2:    #333;
  --gold:       #1a1a1a;
  --gold2:      #333;
  --good:       #1a6a3a;
  --bad:        #c0392b;
  --warn:       #b87000;
  --chalk:      #1a1a1a;
  --shadow-panel: none;
  --shadow-float: 0 4px 20px rgba(0,0,0,0.08);
}

html[data-theme="dark"] {
  --yellow:            #4F7FFF;
  --coral:             #F28272;
  --shell-paper:       #111111;
  --shell-paper-warm:  #1a1a1a;
  --shell-surface:     #1a1a1a;
  --shell-surface-2:   #222222;
  --shell-surface-3:   #2a2a2a;
  --shell-ink:         #f0f0f0;
  --shell-ink-soft:    rgba(240,240,240,0.55);
  --shell-ink-faint:   rgba(240,240,240,0.35);
  --shell-rule:        rgba(240,240,240,0.10);
  --shell-rule-strong: rgba(240,240,240,0.18);
  --shell-red:         #4F7FFF;
  --shell-red-dim:     rgba(79,127,255,0.08);
  --shell-red-glow:    rgba(79,127,255,0.14);
  --shell-teal:        #4F7FFF;
  --shell-teal-dim:    rgba(79,127,255,0.08);
  --brand-red:         #4F7FFF;

  /* nav stays blue in dark too. */
  --nav-bg:            #4F7FFF;
  --nav-border:        #4F7FFF;
  --tab-active-color:  #1a1a1a;
  --tab-active-bg:     rgba(26,26,26,0.08);
  --tab-hover-bg:      rgba(26,26,26,0.06);
  --tab-color:         rgba(26,26,26,0.52);

  --dark:       #111111;
  --bg:         #111111;
  --bg2:        #1a1a1a;
  --bg3:        #222222;
  --bg4:        #2a2a2a;
  --panel:      #1a1a1a;
  --panel-2:    #222222;
  --surface:    #1a1a1a;
  --text:       #f0f0f0;
  --muted:      rgba(240,240,240,0.55);
  --faint:      rgba(240,240,240,0.35);
  --border:     rgba(240,240,240,0.09);
  --border-sub: rgba(240,240,240,0.05);
  --border-bright: rgba(79,127,255,0.22);
  --line:       rgba(240,240,240,0.09);
  --accent:     #4F7FFF;
  --accent2:    #4F7FFF;
  --gold:       #4F7FFF;
  --gold2:      #ffe066;
  --good:       #2ecc71;
  --bad:        #e74c3c;
  --warn:       #f39c12;
  --chalk:      #f0f0f0;
  --shadow-panel: none;
  --shadow-float: 0 4px 24px rgba(0,0,0,0.50);
}

/* ── dark mode overrides ─────────────────────────── */
html[data-theme="dark"] body {
  background: var(--shell-paper);
  color: var(--shell-ink);
}
html[data-theme="dark"] body::before { display: none; }

html[data-theme="dark"] nav.site-tabs {
  background: #4F7FFF;
  border-bottom-color: #4F7FFF;
}
html[data-theme="dark"] .site-tab { color: rgba(26,26,26,0.52); border-right-color: rgba(26,26,26,0.12); }
html[data-theme="dark"] .site-tab--active { color: #1a1a1a; background: rgba(26,26,26,0.07); }
html[data-theme="dark"] .site-tab--active::after { background: #1a1a1a; }
html[data-theme="dark"] .site-tab:hover { color: #1a1a1a; background: rgba(26,26,26,0.08); }
html[data-theme="dark"] .site-brand-lockup .oa-logo-title { color: #1a1a1a; }
html[data-theme="dark"] .site-brand-lockup .oa-logo-subtitle { color: rgba(26,26,26,0.52); }
html[data-theme="dark"] .site-auth-login { color: #1a1a1a; border-color: rgba(26,26,26,0.22); }
html[data-theme="dark"] .site-auth-login:hover { background: rgba(26,26,26,0.08); }
html[data-theme="dark"] .site-auth-name { color: #1a1a1a; }
html[data-theme="dark"] .site-auth-logout { color: rgba(26,26,26,0.52); border-left-color: rgba(26,26,26,0.16); }
html[data-theme="dark"] .site-auth-logout:hover { color: #1a1a1a; }
html[data-theme="dark"] .page-title { color: var(--shell-ink); }
html[data-theme="dark"] .header-eyebrow { color: var(--shell-ink-faint); }
html[data-theme="dark"] .header-sub { color: var(--shell-ink-soft); }
html[data-theme="dark"] .lab-header { border-bottom: none; }
html[data-theme="dark"] .lab-header-pitch {
  background: var(--shell-coral, #F28272);
}
html[data-theme="dark"] .lab-header-stripes { opacity: 0; }
html[data-theme="dark"] .scoutics-footer-settings-trigger { color: var(--shell-ink-faint); }
html[data-theme="dark"] .scoutics-footer-settings-trigger:hover { background: rgba(240,240,240,0.06); color: var(--shell-ink); }
html[data-theme="dark"] .scoutics-settings-panel { background: #1a1a1a; border-color: rgba(240,240,240,0.13); box-shadow: 0 16px 40px rgba(0,0,0,0.6); }
html[data-theme="dark"] .scoutics-settings-header { background: rgba(255,255,255,0.03); }
html[data-theme="dark"] .engine-note-card { background: var(--shell-surface); border-color: var(--shell-rule); }
html[data-theme="dark"] .engine-notes-title, html[data-theme="dark"] .engine-note-title { color: var(--shell-ink); }
html[data-theme="dark"] .engine-notes-intro, html[data-theme="dark"] .engine-note-body, html[data-theme="dark"] .engine-note-foot { color: var(--shell-ink-soft); }
html[data-theme="dark"] .live-card-head, html[data-theme="dark"] .table-head { background: rgba(255,255,255,0.02); border-color: var(--shell-rule); }
html[data-theme="dark"] .player-pitch-time { background: var(--shell-surface); border-color: var(--shell-rule); }
html[data-theme="dark"] .site-footer { background: rgba(255,255,255,0.02); border-top-color: var(--shell-rule); }

/* ── Dark mode for responsive nav ─────────────────── */
html[data-theme="dark"] .site-menu-icon {
  background: rgba(240,240,240,0.70);
}

html[data-theme="dark"] .site-tab-list {
  background: #4F7FFF;
}

html[data-theme="dark"] .site-tab {
  color: rgba(26,26,26,0.52);
  border-bottom-color: rgba(26,26,26,0.10);
}

html[data-theme="dark"] .site-tab:hover {
  color: #1a1a1a;
  background: rgba(26,26,26,0.08);
}

html[data-theme="dark"] .site-tab--active {
  color: #1a1a1a;
  background: rgba(26,26,26,0.07);
}

/* ═══════════════════════════════════════════════════════
   STRUCTURE
   ═══════════════════════════════════════════════════════ */
.site-shell { position: relative; z-index: 1; display: flex; flex-direction: column; min-height: 100vh; min-height: 100dvh; }
.site-shell--grid-body { display: grid; grid-template-rows: auto auto 1fr; min-height: 100vh; min-height: 100dvh; }

/* ── NAV — blue bar, bold Inter, flat ────────────── */
nav.site-tabs {
  position: sticky; top: 0; z-index: 200;
  width: 100%; background: #4F7FFF;
  border-bottom: none; box-sizing: border-box;
}
.site-tabs-inner {
  max-width: 1280px; margin: 0 auto;
  min-height: 56px; padding: 0 24px;
  display: flex; align-items: stretch;
  justify-content: space-between;
}

/* brand */
.site-brand { display: inline-flex; align-items: center; text-decoration: none; color: inherit; flex: 0 0 auto; min-height: 44px; }
.site-brand-lockup {
  display: inline-flex; align-items: center;
  min-height: 56px; padding: 0 24px 0 0;
  border-right: 1px solid rgba(26,26,26,0.12);
}
.site-brand-lockup > svg { display: block; width: min(200px, 52vw); height: auto; }
.site-brand-lockup .oa-logo-lockup { display: inline-flex; align-items: center; gap: 10px; }
.site-brand-lockup .oa-logo-mark { width: 28px; height: 28px; display: block; flex: 0 0 auto; }
.site-brand-lockup .oa-logo-text { display: inline-flex; flex-direction: column; align-items: flex-start; line-height: 1; }
.site-brand-lockup .oa-logo-title {
  font-family: 'Inter', system-ui, sans-serif;
  font-size: 0.95rem; font-weight: 800;
  letter-spacing: -0.02em; color: #1a1a1a;
  white-space: nowrap; text-transform: uppercase;
}
.site-brand-lockup .oa-logo-subtitle {
  margin-top: 3px; font-family: 'Inter', system-ui, sans-serif;
  font-size: 0.44rem; font-weight: 600;
  letter-spacing: 0.22em; color: rgba(26,26,26,0.50);
  text-transform: uppercase;
}

/* tabs */
.site-tab-list {
  display: flex; align-items: center; flex: 1 1 auto;
  justify-content: flex-end;
  flex-wrap: nowrap; gap: 0; overflow-x: auto;
  overflow-y: hidden; overscroll-behavior-x: contain;
  margin-left: auto; scrollbar-width: none;
}
.site-tab-list::-webkit-scrollbar { display: none; }
.site-tab {
  font-family: 'Inter', system-ui, sans-serif;
  font-size: 0.72rem; font-weight: 700;
  text-transform: uppercase; letter-spacing: 0.08em;
  min-height: 56px; padding: 0 16px;
  color: rgba(26,26,26,0.52); text-decoration: none;
  border-right: 1px solid rgba(26,26,26,0.10);
  transition: color 0.13s, background 0.13s;
  display: flex; align-items: center; white-space: nowrap;
  position: relative; box-sizing: border-box; flex: 0 0 auto;
}
.site-tab::after {
  content: ''; position: absolute; bottom: 0; left: 0; right: 0;
  height: 3px; background: #1a1a1a;
  transform: scaleX(0); transition: transform 0.13s; transform-origin: center;
}
.site-tab:last-of-type { border-right: 0; }
.site-tab:hover { color: #1a1a1a; background: rgba(26,26,26,0.06); }
.site-tab:hover::after { transform: scaleX(0.4); opacity: 0.3; }
.site-tab--active { color: #1a1a1a; background: rgba(26,26,26,0.06); }
.site-tab--active::after { transform: scaleX(1); }
.site-tab:focus-visible { outline: 2px solid #1a1a1a; outline-offset: -2px; }

/* auth */
.site-auth-login {
  display: inline-flex; align-items: center; gap: 7px;
  align-self: center; flex-shrink: 0; margin-left: 12px;
  padding: 6px 14px; border: 2px solid #1a1a1a; border-radius: 0;
  font-size: 0.72rem; font-weight: 700; font-family: 'Inter', system-ui, sans-serif;
  letter-spacing: 0.06em; text-transform: uppercase;
  color: #1a1a1a; text-decoration: none; white-space: nowrap;
  background: transparent; transition: background 0.13s, color 0.13s;
}
.site-auth-login:hover { background: #1a1a1a; color: #4F7FFF; }
.site-auth-google-icon { width: 14px; height: 14px; flex-shrink: 0; }
.site-auth-pill {
  display: inline-flex; align-items: center; gap: 8px;
  align-self: center; flex-shrink: 0; margin-left: 12px;
  padding: 3px 10px 3px 3px;
  border: 2px solid #1a1a1a; border-radius: 0;
  font-family: 'Inter', system-ui, sans-serif;
}
.site-auth-avatar { width: 24px; height: 24px; border-radius: 0; object-fit: cover; flex-shrink: 0; }
.site-auth-avatar-initials {
  display: inline-flex; align-items: center; justify-content: center;
  width: 24px; height: 24px; background: #1a1a1a;
  color: #4F7FFF; font-size: 0.65rem; font-weight: 700; flex-shrink: 0;
}
.site-auth-name { color: #1a1a1a; font-weight: 700; font-size: 0.72rem; max-width: 110px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.site-auth-logout { color: rgba(26,26,26,0.52); font-size: 0.70rem; text-decoration: none; border-left: 1px solid rgba(26,26,26,0.18); padding-left: 8px; white-space: nowrap; transition: color 0.13s; }
.site-auth-logout:hover { color: #1a1a1a; }

/* ── PAGE HEADER — coral background, big Inter ───── */
.lab-header {
  position: relative; padding: 24px 24px;
  overflow: visible; flex-shrink: 0;
  border-bottom: none;
  isolation: isolate;
}
.lab-header-bg { position: absolute; inset: 0; pointer-events: none; }
.lab-header-pitch {
  position: absolute; inset: 0;
  background: #F28272;
}
.lab-header-stripes { display: none; }
.lab-header-inner {
  position: relative; z-index: 1;
  max-width: 1280px; margin: 0 auto;
  display: flex; align-items: center;
  justify-content: space-between; gap: 20px; flex-wrap: wrap;
}
.lab-header-aside {
  display: flex; flex-direction: column;
  align-items: flex-end; gap: 8px; text-align: right; flex-shrink: 0;
}
.header-eyebrow {
  color: rgba(26,26,26,0.60); text-transform: uppercase;
  letter-spacing: 0.18em; font-family: 'Inter', system-ui, sans-serif;
  font-size: 0.65rem; font-weight: 600; margin-bottom: 6px;
}
.page-title {
  font-family: 'Inter', system-ui, sans-serif;
  letter-spacing: -0.04em;
  font-size: clamp(2.6rem, 6vw, 5rem);
  line-height: 1; font-weight: 900;
  color: #1a1a1a; text-transform: none;
  margin: 0;
}
.page-title-b { color: #1a1a1a; }
.header-sub {
  margin-top: 6px; margin-bottom: 0; color: rgba(26,26,26,0.68);
  font-family: 'Inter', system-ui, sans-serif;
  font-size: 1.05rem; line-height: 1.45; max-width: 60ch; font-weight: 400;
}
.header-sub code {
  font-family: 'Inter', system-ui, sans-serif; font-size: 0.82rem;
  color: #1a1a1a; background: rgba(26,26,26,0.10);
  padding: 1px 5px; border-radius: 2px;
}
.header-badge {
  display: inline-flex; align-items: center; gap: 6px;
  font-family: 'Inter', system-ui, sans-serif;
  font-size: 0.63rem; font-weight: 700;
  letter-spacing: 0.10em; text-transform: uppercase;
  color: #1a1a1a; background: rgba(26,26,26,0.10);
  border: 1px solid rgba(26,26,26,0.18); border-radius: 0;
  padding: 5px 10px;
}
.header-badge::before {
  content: ''; width: 6px; height: 6px; border-radius: 50%;
  background: #1a1a1a; animation: siteShellPulse 2.2s ease infinite;
}
@keyframes siteShellPulse { 0%,100%{opacity:1} 50%{opacity:0.25} }

.site-content {
  width: 100%; max-width: 1280px; margin: 0 auto;
  padding: 0 24px 40px; position: relative; z-index: 1; box-sizing: border-box;
}

/* ── FOOTER — matches Maya Chen portfolio footer ─── */
.site-footer {
  margin-top: auto;
  border-top: 1px solid rgba(26,26,26,0.10);
  background: var(--shell-paper);
  font-family: 'Inter', system-ui, sans-serif;
  font-size: 0.78rem; color: rgba(26,26,26,0.45);
}
html[data-theme="dark"] .site-footer {
  border-top-color: rgba(240,240,240,0.09);
  background: var(--shell-paper);
}
.site-footer-inner {
  max-width: 1280px; margin: 0 auto; padding: 20px 24px;
  display: flex; align-items: center;
  justify-content: space-between; gap: 10px; flex-wrap: wrap;
}
.site-footer-left { display: flex; align-items: center; gap: 6px; }
.site-footer-wordmark {
  font-family: 'Inter', system-ui, sans-serif;
  font-size: 0.78rem; font-weight: 800;
  letter-spacing: -0.01em; color: rgba(26,26,26,0.30);
  text-transform: uppercase;
}
html[data-theme="dark"] .site-footer-wordmark { color: rgba(240,240,240,0.25); }
.site-footer-sep { color: rgba(26,26,26,0.20); padding: 0 2px; }
.site-footer-links { display: flex; }
.site-footer-link {
  padding: 4px 9px; color: rgba(26,26,26,0.45);
  text-decoration: none; transition: color 0.13s; white-space: nowrap;
}
.site-footer-link:hover { color: #1a1a1a; }
html[data-theme="dark"] .site-footer-link { color: rgba(240,240,240,0.40); }
html[data-theme="dark"] .site-footer-link:hover { color: #4F7FFF; }
.site-footer-right { display: flex; align-items: center; }
.site-footer-country {
  display: inline-flex; align-items: center; gap: 5px;
  min-height: 44px;
  padding: 8px 12px; border: 1px solid rgba(26,26,26,0.12);
  border-radius: 0; cursor: pointer; background: transparent;
  color: rgba(26,26,26,0.45); font: 500 0.72rem 'Inter', system-ui, sans-serif;
  transition: color 0.13s, border-color 0.13s;
}
.site-footer-country:hover { color: #1a1a1a; border-color: rgba(26,26,26,0.28); }
html[data-theme="dark"] .site-footer-country { color: rgba(240,240,240,0.40); border-color: rgba(240,240,240,0.10); }
html[data-theme="dark"] .site-footer-country:hover { color: #4F7FFF; border-color: rgba(79,127,255,0.30); }

/* ── SETTINGS ──────────────────────────────────── */
.scoutics-footer-settings { position: fixed; right: 20px; bottom: 14px; z-index: 9999; }
.scoutics-footer-settings-trigger {
  border: 0; background: transparent; color: rgba(26,26,26,0.45);
  font: 500 12px/1.2 'Inter', system-ui, sans-serif;
  cursor: pointer; min-height: 44px; padding: 8px 12px; border-radius: 0;
  transition: background 0.13s, color 0.13s;
}
.scoutics-footer-settings-trigger:hover { background: rgba(26,26,26,0.06); color: #1a1a1a; }
.scoutics-settings-panel {
  position: absolute; right: 0; bottom: 40px; width: 282px;
  background: var(--shell-paper); color: var(--shell-ink);
  border: 2px solid #1a1a1a; border-radius: 0;
  box-shadow: 6px 6px 0 #1a1a1a; overflow: hidden;
}
html[data-theme="dark"] .scoutics-settings-panel {
  background: #1a1a1a; border-color: #4F7FFF;
  box-shadow: 6px 6px 0 #4F7FFF;
}
.scoutics-settings-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 10px 14px; border-bottom: 1px solid rgba(26,26,26,0.12);
  background: #4F7FFF;
}
html[data-theme="dark"] .scoutics-settings-header { background: #4F7FFF; }
.scoutics-settings-title {
  font-family: 'Inter', system-ui, sans-serif;
  font-weight: 800; font-size: 0.76rem;
  letter-spacing: 0.08em; text-transform: uppercase; color: #1a1a1a;
}
.scoutics-settings-close {
  background: transparent; border: none; cursor: pointer;
  min-width: 44px; min-height: 44px;
  font-size: 1.2rem; color: rgba(26,26,26,0.55);
  padding: 2px 4px; border-radius: 0; transition: color 0.13s;
}
.scoutics-settings-close:hover { color: #1a1a1a; }
.scoutics-settings-list { list-style: none; margin: 0; padding: 4px 0; }
.scoutics-settings-row {
  display: flex; align-items: center; justify-content: space-between;
  padding: 9px 14px; font-family: 'Inter', system-ui, sans-serif; font-size: 0.82rem;
}
.scoutics-settings-row + .scoutics-settings-row { border-top: 1px solid var(--shell-rule); }
.scoutics-settings-label { color: var(--shell-ink); font-size: 0.80rem; font-weight: 500; }
.scoutics-settings-select {
  max-width: 143px; padding: 4px 7px;
  border: 1px solid var(--shell-rule-strong); border-radius: 0;
  background: transparent; color: var(--shell-ink);
  font: 500 0.78rem/1.2 'Inter', system-ui, sans-serif;
}
.scoutics-settings-hint {
  margin: 0; padding: 9px 14px 11px;
  border-top: 1px solid var(--shell-rule);
  color: var(--shell-ink-soft); font: 500 0.70rem/1.4 'Inter', system-ui, sans-serif;
}
.scoutics-toggle { position: relative; display: inline-block; width: 36px; height: 20px; }
.scoutics-toggle input { opacity: 0; width: 0; height: 0; }
.sr-only {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  padding: 0 !important;
  margin: -1px !important;
  overflow: hidden !important;
  clip: rect(0, 0, 0, 0) !important;
  white-space: nowrap !important;
  border: 0 !important;
}
.scoutics-toggle-track {
  position: absolute; inset: 0; cursor: pointer;
  background: var(--shell-rule-strong); border-radius: 0; transition: background 0.15s;
}
.scoutics-toggle-thumb {
  position: absolute; top: 2px; left: 2px; width: 16px; height: 16px;
  background: #fff; border-radius: 0; transition: transform 0.15s;
}
.scoutics-toggle input:checked + .scoutics-toggle-track { background: #1a1a1a; }
html[data-theme="dark"] .scoutics-toggle input:checked + .scoutics-toggle-track { background: #4F7FFF; }
.scoutics-toggle input:checked + .scoutics-toggle-track .scoutics-toggle-thumb { transform: translateX(16px); }
html[data-theme="dark"] .scoutics-toggle input:checked + .scoutics-toggle-track .scoutics-toggle-thumb { background: #1a1a1a; }

/* ── RESPONSIVE ────────────────────────────────── */

/* Hamburger button — hidden on desktop, shown on mobile */
.site-menu-toggle {
  display: none;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  padding: 0;
  margin: 0 8px 0 auto;
  background: transparent;
  border: none;
  cursor: pointer;
  gap: 4px;
  align-self: center;
  flex-shrink: 0;
}
.site-menu-icon {
  display: block;
  width: 22px;
  height: 2px;
  background: rgba(26,26,26,0.70);
  border-radius: 1px;
  transition: all 0.3s ease;
  transform-origin: center;
}
.site-menu-toggle[aria-expanded="true"] .site-menu-icon:nth-child(1) {
  transform: rotate(45deg) translateY(10px);
}
.site-menu-toggle[aria-expanded="true"] .site-menu-icon:nth-child(2) {
  opacity: 0;
}
.site-menu-toggle[aria-expanded="true"] .site-menu-icon:nth-child(3) {
  transform: rotate(-45deg) translateY(-10px);
}

/* Desktop: show tabs horizontally, hide hamburger */
.site-tab-list {
  display: flex;
  align-items: center;
  flex: 1 1 auto;
  justify-content: flex-end;
  flex-wrap: nowrap;
  gap: 0;
  overflow-x: auto;
  overflow-y: hidden;
  overscroll-behavior-x: contain;
  margin-left: auto;
  scrollbar-width: none;
  position: static;
  background: transparent;
  flex-direction: row;
  max-height: none;
  visibility: visible;
  opacity: 1;
  transition: none;
}
.site-tab-list::-webkit-scrollbar { display: none; }

@media (max-width: 900px) {
  .site-tabs-inner {
    min-height: 56px;
    padding: 0 16px;
    flex-wrap: nowrap;
    align-items: center;
  }
  .site-brand {
    width: auto;
    flex: 1 1 auto;
    min-width: 0;
  }
  .site-brand-lockup {
    min-height: 56px;
    padding: 0 16px 0 0;
    border-right: 1px solid rgba(26,26,26,0.12);
  }

  /* Show hamburger menu at 900px and below */
  .site-menu-toggle {
    display: flex;
  }

  /* Tab list becomes a dropdown drawer */
  .site-tab-list {
    position: absolute;
    top: 56px;
    left: 0;
    right: 0;
    background: #4F7FFF;
    flex-direction: column;
    max-height: 0;
    overflow: hidden;
    visibility: hidden;
    opacity: 0;
    transition: all 0.3s ease;
    gap: 0;
    border-bottom: 1px solid rgba(26,26,26,0.10);
    z-index: 199;
    margin: 0;
    padding: 0;
  }

  .site-tab-list[aria-hidden="false"] {
    max-height: 600px;
    visibility: visible;
    opacity: 1;
  }

  .site-tab {
    min-height: 44px;
    padding: 0 16px;
    justify-content: flex-start;
    border-right: none;
    border-bottom: 1px solid rgba(26,26,26,0.10);
    font-size: 0.75rem;
    width: 100%;
    box-sizing: border-box;
  }

  .site-tab:last-of-type {
    border-bottom: none;
  }

  .site-tab::after {
    display: none;
  }

  /* Auth elements stay on nav bar on tablet */
  .site-auth-pill,
  .site-auth-login {
    margin-left: 0;
    flex-shrink: 1;
  }

  .lab-header { padding: 20px 16px 18px; }
  .site-footer-inner { flex-direction: column; align-items: flex-start; gap: 6px; }
}

@media (max-width: 720px) {
  .site-brand-lockup > svg { width: min(160px, 50vw); }
  .site-brand-lockup {
    padding: 0 12px 0 0;
  }
  .site-menu-toggle {
    margin: 0 4px 0 auto;
    width: 44px;
    height: 44px;
  }
  .site-menu-icon {
    width: 20px;
    height: 2px;
  }
  /* Hide top-bar auth on phone — moved into drawer */
  .site-auth-pill,
  .site-auth-login {
    display: none;
  }
  .site-tab { min-height: 38px; padding: 0 10px; font-size: 0.65rem; }
  .page-title { font-size: clamp(2rem, 11vw, 3.2rem); }
  .scoutics-footer-settings { right: 10px; bottom: 10px; }
  .scoutics-footer-settings-trigger {
    min-height: 36px;
    padding: 8px 12px;
    border: 1px solid rgba(240,240,240,0.16);
    border-radius: 999px;
    background: rgba(20,20,20,0.86);
    color: rgba(255,255,255,0.82);
    box-shadow: 0 8px 24px rgba(0,0,0,0.28);
    backdrop-filter: blur(10px);
  }
  .scoutics-settings-panel { width: min(90vw, 300px); }
}

@media (max-width: 500px) {
  .site-tabs-inner {
    padding: 0 12px;
  }
  .site-brand-lockup {
    padding: 0 8px 0 0;
  }
}

/* ── Mobile-only auth row inside dropdown drawer ── */
.site-tab--auth { display: none; }
@media (max-width: 900px) {
  .site-tab--auth {
    display: flex !important;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    min-height: 48px;
    padding: 0 16px;
    background: rgba(0,0,0,0.04);
    border-top: 1px solid rgba(26,26,26,0.10);
    border-bottom: none !important;
    font-size: 0.78rem;
    font-weight: 600;
  }
  .site-tab-auth-name {
    flex: 1 1 auto;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    color: rgba(26,26,26,0.85);
  }
  .site-tab-auth-action {
    flex: 0 0 auto;
    padding: 6px 14px;
    border: 1px solid rgba(26,26,26,0.30);
    border-radius: 999px;
    background: #fff;
    color: #1a1a1a;
    text-decoration: none;
    font-size: 0.74rem;
    font-weight: 700;
  }
  .site-tab-auth-action--primary {
    width: 100%;
    text-align: center;
    background: #1a1a1a;
    color: #4F7FFF;
    border-color: #1a1a1a;
  }
}

/* ── iPhone polish: ensure canvases & wide blocks fit viewport ── */
@media (max-width: 540px) {
  html, body { overflow-x: hidden; }
  canvas, svg, img, video { max-width: 100%; height: auto; }
  .stadium-preview-shell { max-height: min(40vh, 320px); }
  .panel, .sim-shell, .table-card, .live-card { padding-left: 12px; padding-right: 12px; }
  table { font-size: 12px; }
}
