/* Shared institutional UI. Color belongs only to the thermal canvas and games. */
[hidden] { display:none !important; }
:focus-visible { outline:3px solid #111111; outline-offset:4px; }
.demo-section :focus-visible { outline-color:#ffffff; }
.button-dark { color:#ffffff; background:#111111; }
.button-dark:hover { background:#333333; }
.button-light { color:#111111; background:#ffffff; }
.button-outline { color:inherit; border:1px solid currentColor; background:transparent; }
.button:disabled { opacity:.45; transform:none; }
.thermal-text { color:#777777; }
.thermal-subhint { color:#666666; }
.back-top { background:transparent; }

/* The panel extends the existing header, without a backdrop. */
.site-header { background:#ffffff; }
.site-header.scrolled .nav-shell { min-height:var(--header); }
.nav-menu-toggle { display:flex; align-items:center; gap:22px; padding:14px 0 14px 14px; min-height:48px; background:none; font:600 12px Arial,sans-serif; letter-spacing:.075em; }
.menu-glyph { font:300 27px/1 LOB Sans,Arial,sans-serif; width:22px; text-align:center; }
.menu-panel { position:absolute; inset:100% 0 auto; height:55vh; height:55svh; min-height:min(365px,calc(100svh - var(--header))); max-height:min(650px,calc(100svh - var(--header))); background:#ffffff; border-bottom:1px solid #dddddd; overflow:auto; overscroll-behavior:contain; opacity:0; clip-path:inset(0 0 100%); transform:translateY(-15px); transition:clip-path 500ms var(--ease),transform 500ms var(--ease),opacity 500ms var(--ease); }
.is-menu-open .menu-panel { opacity:1; clip-path:inset(0); transform:translateY(0); }
.menu-panel-inner { min-height:100%; display:grid; grid-template-columns:minmax(0,1.6fr) minmax(240px,.65fr); gap:8%; padding-block:30px 35px; }
.menu-primary { display:flex; flex-direction:column; justify-content:center; gap:6px; }
.menu-primary a { display:flex; align-items:center; gap:25px; padding:8px 0; opacity:0; transform:translateY(15px); transition:opacity 300ms ease,transform 350ms var(--ease); }
.is-menu-open .menu-primary a { opacity:1; transform:translateY(0); transition-delay:calc(var(--item) * 55ms + 80ms); }
.menu-primary a>span { color:#666666; font:12px Arial,sans-serif; min-width:22px; }
.menu-primary strong { font-size:clamp(28px,3.7vw,60px); font-weight:600; letter-spacing:-.05em; line-height:1.06; transition:transform 200ms var(--ease); }
.menu-primary a:hover strong { transform:translateX(8px); }
.menu-secondary { display:flex; flex-direction:column; justify-content:center; align-items:flex-start; gap:25px; }
.menu-secondary p { font-size:clamp(26px,2.5vw,40px); line-height:1.05; letter-spacing:-.04em; }
.menu-secondary .button { width:100%; max-width:300px; }
.menu-secondary>.tiny { color:#666666; font-size:8px; }
body.menu-locked { overscroll-behavior:none; }

/* Native cursor remains visible; the follower sleeps once it catches up. */
.cursor-follower { --cursor-lens-size:52px; position:fixed; top:0; left:0; z-index:90; pointer-events:none; visibility:hidden; transition:visibility 0s 160ms; will-change:transform; }
.cursor-follower.is-visible { visibility:visible; transition-delay:0s; }
.cursor-optics { position:absolute; width:0; height:0; pointer-events:none; overflow:hidden; }
.cursor-mark { display:block; width:10px; height:10px; margin:-5px; border-radius:50%; background:#111111; transform:scale(1); filter:blur(0px); transition:width 220ms var(--ease),height 220ms var(--ease),margin 220ms var(--ease),background 220ms ease,opacity 160ms ease; }
.cursor-follower.is-lens .cursor-mark,.cursor-follower.is-smoke .cursor-mark { opacity:0; }
.cursor-follower.is-lens .cursor-mark { transform:scale(1.15); filter:blur(.6px); transition:width 220ms var(--ease),height 220ms var(--ease),margin 220ms var(--ease),background 220ms ease,opacity 70ms cubic-bezier(.22,1,.36,1) 30ms,transform 180ms cubic-bezier(.22,1,.36,1),filter 110ms cubic-bezier(.22,1,.36,1); }
.cursor-follower.is-glass-exit:not(.is-thermal):not(.is-smoke) .cursor-mark { transform:scale(1); filter:blur(0px); transition:width 220ms var(--ease),height 220ms var(--ease),margin 220ms var(--ease),background 220ms ease,opacity 70ms cubic-bezier(.22,1,.36,1) 35ms,transform 160ms cubic-bezier(.22,1,.36,1),filter 130ms cubic-bezier(.22,1,.36,1); }
.cursor-follower.on-dark .cursor-mark { background:#ffffff; color:#111111; }
.cursor-follower.is-thermal .cursor-mark { width:30px; height:30px; margin:-15px; background:#666666; filter:blur(8px); opacity:.2; }
.cursor-lens { position:absolute; top:calc(var(--cursor-lens-size) * -.5); left:calc(var(--cursor-lens-size) * -.5); width:var(--cursor-lens-size); height:var(--cursor-lens-size); border-radius:50%; overflow:hidden; background:rgba(255,255,255,.015); box-shadow:inset 0 0 0 1px rgba(119,119,119,0),0 1px 4px rgba(0,0,0,0); opacity:0; transform:scale(.78); transition:opacity 160ms cubic-bezier(.22,1,.36,1),transform 160ms cubic-bezier(.22,1,.36,1),box-shadow 160ms cubic-bezier(.22,1,.36,1),width 180ms cubic-bezier(.22,1,.36,1),height 180ms cubic-bezier(.22,1,.36,1),top 180ms cubic-bezier(.22,1,.36,1),left 180ms cubic-bezier(.22,1,.36,1); }
.cursor-lens:after { content:""; position:absolute; inset:0; border-radius:inherit; box-shadow:inset 0 1px 1px rgba(255,255,255,.2); background:linear-gradient(145deg,rgba(255,255,255,.07),rgba(255,255,255,0) 55%); }
.cursor-follower:is(.is-lens,.is-glass-exit) .cursor-lens { -webkit-backdrop-filter:url(#lob-cursor-optics); backdrop-filter:url(#lob-cursor-optics); }
.cursor-follower.is-lens .cursor-lens { opacity:1; transform:scale(1); box-shadow:inset 0 0 0 1px rgba(119,119,119,.22),0 1px 4px rgba(0,0,0,.06); transition-duration:180ms; }
.cursor-smoke { position:absolute; top:-17px; left:-17px; width:34px; height:34px; border-radius:50%; background:radial-gradient(circle,rgba(var(--cursor-smoke-rgb,110,110,110),.14) 0%,rgba(var(--cursor-smoke-rgb,110,110,110),.07) 30%,rgba(var(--cursor-smoke-rgb,110,110,110),0) 72%); opacity:0; transform:scale(.8); transition:opacity 180ms ease,transform 220ms var(--ease); }
.cursor-follower.is-smoke .cursor-smoke { opacity:1; transform:scale(1); }
.cursor-label { display:block; position:absolute; top:36px; left:0; width:max-content; min-width:40px; max-width:min(190px,calc(100vw - 32px)); padding:8px 11px; border-radius:12px; background:var(--cursor-ink,#111111); color:var(--cursor-surface,#ffffff); font:600 10px/1.35 Arial,sans-serif; text-align:center; white-space:normal; overflow-wrap:anywhere; transform:translateX(-50%); opacity:0; transition:opacity 140ms ease; }
.cursor-follower.has-label .cursor-label { opacity:1; }
/* Fade the layers, never their ancestor: the optical layer needs the page's
   backdrop throughout its entry, without an empty opacity-group boundary. */
.cursor-follower:not(.is-visible) :is(.cursor-mark,.cursor-lens,.cursor-smoke,.cursor-label) { opacity:0; }

/* Frames keep native proportions. The new topbar never overlays the game. */
.real-game-stage { border:1px solid #e6e6e6; border-radius:20px; overflow:hidden; box-shadow:none; padding:56px 20px 20px; transition:border-color 200ms ease; }
.real-game-stage:hover { border-color:#111111; }
.real-game-stage .showcase-head { top:0; left:0; right:0; min-height:40px; height:40px; padding:0 15px; border-bottom:1px solid #e6e6e6; background:#ffffff; }
.real-game-stage .game-viewport { border-radius:12px; }
.demo-real-stage { border-color:#444444; }
.demo-real-stage:hover { border-color:#ffffff; }
.demo-real-stage .showcase-head { border-color:#444444; background:#181818; }
.demo-real-stage .showcase-head .eyebrow { color:#ffffff; }
.demo-real-stage .showcase-head .tiny { color:#cccccc; }
.demo-section .accent { color:#ffffff; }
.demo-section #like-progress { background:#ffffff; }
.dashboard { border-radius:16px; overflow:hidden; border-color:#e6e6e6; box-shadow:none; }
.central-game-stage { border-radius:12px; border:1px solid #e6e6e6; overflow:hidden; }
.central-game-stage .game-viewport { border-radius:12px; }
.central-live-controls button,.central-live-controls .button { border-radius:10px; }
.game-tab.active { color:#111111; background:#ececec; }
.test-actions button:hover { color:#111111; border-color:#111111; background:#f5f5f5; }
.test-actions button:disabled:hover { border-color:#dddddd; background:transparent; }

@media(max-width:960px) {
  .menu-panel-inner { grid-template-columns:minmax(0,1fr) 240px; gap:5%; }
  .menu-primary a { gap:16px; }
  .menu-primary strong { font-size:clamp(26px,4.3vw,45px); }
}
@media(max-width:680px) {
  .nav-menu-toggle { gap:13px; font-size:11px; }
  .menu-panel { height:calc(100vh - var(--header)); height:calc(100svh - var(--header)); min-height:0; max-height:none; }
  .menu-panel-inner { display:flex; flex-direction:column; justify-content:space-between; gap:30px; padding-block:20px 30px; }
  .menu-primary { gap:10px; }
  .menu-primary a { min-height:52px; padding:8px 0; }
  .menu-primary strong { font-size:clamp(25px,6.6vw,43px); }
  .menu-secondary { gap:19px; }
  .menu-secondary p { font-size:28px; }
  .menu-secondary .button { max-width:none; }
  .real-game-stage { padding:40px 0 0; overflow:hidden; }
  .real-game-stage .game-viewport { border-radius:0; }
  .real-game-stage .showcase-head { left:0; right:0; }
  .central-game-stage,.central-game-stage .game-viewport { border-radius:12px; }
  .cursor-follower { display:none; }
}
@media(hover:none),(pointer:coarse) { .cursor-follower { display:none; } }
@media(prefers-reduced-motion:reduce) {
  html { scroll-behavior:auto; }
  .cursor-follower { display:none; }
  .menu-panel,.menu-primary a,.menu-primary strong { transition:none; }
  .live-dot:after { animation:none; }
}
