/* GUTTEROT website — page shell styles */
html, body { margin: 0; height: 100%; background: var(--gr-void); overflow: hidden; }
html, body { overscroll-behavior: none; -webkit-text-size-adjust: 100%; }
body { -webkit-tap-highlight-color: transparent; }
/* iOS Safari: 100vh includes the address bar and overflows. Use dynamic viewport
   units where supported, falling back to vh, so the stage always fills the screen. */
#stage { position: relative; width: 100vw; height: 100vh; height: 100svh; height: 100dvh; }

/* Loading splash — shown until React mounts (Babel transpile takes a beat) */
#splash {
  position: absolute; inset: 0; z-index: 50;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 18px;
  background: radial-gradient(120% 90% at 50% 40%, #14181a, #050607 70%);
  transition: opacity .5s ease;
}
#splash.gone { opacity: 0; pointer-events: none; }
#splash .wm {
  font-family: var(--gr-font-display, 'Chakra Petch', sans-serif);
  font-weight: 700; text-transform: uppercase; letter-spacing: .05em;
  font-size: clamp(40px, 7vw, 76px); line-height: 1; padding-right: .18em;
  background: linear-gradient(180deg, #fbfdfe, #c4ced4 32%, #59636a 52%, #c4ced4 70%, #fbfdfe);
  -webkit-background-clip: text; background-clip: text;
  color: transparent; -webkit-text-fill-color: transparent;
  filter: drop-shadow(0 3px 8px rgba(0,0,0,.7));
}
#splash .dots { display: flex; gap: 6px; }
#splash .dots i { width: 7px; height: 7px; border-radius: 50%; background: var(--gr-ember, #e0892f); opacity: .3; animation: sp 1s infinite; }
#splash .dots i:nth-child(2) { animation-delay: .15s; }
#splash .dots i:nth-child(3) { animation-delay: .3s; }
@keyframes sp { 0%,100% { opacity: .25; transform: translateY(0); } 50% { opacity: 1; transform: translateY(-4px); } }
#splash .bar { width: min(260px, 56vw); height: 3px; background: rgba(255,255,255,.08); overflow: hidden; clip-path: polygon(3px 0,100% 0,100% calc(100% - 3px),calc(100% - 3px) 100%,0 100%,0 3px); }
#splash .bar i { display: block; height: 100%; width: 0%; background: linear-gradient(90deg, var(--gr-blood, #b3221c), var(--gr-ember, #e0892f)); box-shadow: 0 0 12px rgba(224,137,47,.6); transition: width .28s cubic-bezier(.2,.7,.2,1); }
#splash .pct { font-family: var(--gr-font-mono, 'Share Tech Mono', monospace); font-size: 11px; letter-spacing: .18em; text-transform: uppercase; color: var(--gr-fog, #7f8c93); }

.footlink { color: var(--gr-fog); text-decoration: none; transition: color .15s ease; }
.footlink:hover { color: var(--gr-ember); }

@keyframes gr-die-in { 0% { opacity: 0; backdrop-filter: blur(0); } 100% { opacity: 1; } }

/* Responsive polish */
@media (max-width: 820px) {
  .gr-hide-mobile { display: none !important; }
}
@media (max-width: 600px) {
  .footlink { font-size: 10px; }
  .gr-topbar { justify-content: flex-end; }
  .gr-menu-footer { justify-content: center; gap: 6px; }
  /* On phones the character art sits behind the text — deepen the scrim for legibility */
  .gr-menu-panel { text-shadow: 0 2px 12px rgba(0,0,0,0.85); }
  /* Drop the wide "now playing" text so the sound + fullscreen buttons never get
     pushed off-screen (the page clips overflow), leaving the controls always reachable. */
  .gr-sound-credit { display: none !important; }
  /* Compact menu buttons so they don't dominate the small screen */
  .gr-nav-btn { padding: 7px 12px !important; }
  .gr-nav-btn span { font-size: 18px !important; }
  .gr-support { margin-top: 12px !important; padding: 9px 14px !important; }
  .gr-support span span:first-child { font-size: 14px !important; }
  .gr-support svg { width: 20px !important; height: 20px !important; }
}
/* Short / landscape phones: pull the menu block tighter so nav + CTA never clip */
@media (max-height: 520px) {
  .gr-menu-panel { padding-top: 52px !important; padding-bottom: 44px !important; }
}
/* Touch targets: comfortable minimum on coarse pointers */
@media (pointer: coarse) {
  .gr-fs-btn, .gr-topbar button { min-height: 44px; }
}

/* iOS safe-area (notch / Dynamic Island / home indicator): keep chrome clear of insets.
   These are progressive — they add to existing padding only where the OS reports an inset. */
.gr-topbar { padding-top: max(clamp(14px,2.5vw,22px), env(safe-area-inset-top)) !important;
  padding-left: max(clamp(16px,3vw,32px), env(safe-area-inset-left));
  padding-right: max(clamp(16px,3vw,32px), env(safe-area-inset-right)); }
.gr-menu-footer { padding-bottom: max(clamp(12px,2vw,18px), env(safe-area-inset-bottom)) !important;
  padding-left: max(clamp(16px,3vw,32px), env(safe-area-inset-left));
  padding-right: max(clamp(16px,3vw,32px), env(safe-area-inset-right)); }
/* In-game top-right cluster + bottom action button respect the insets too */
.gr-chrome-tr { top: max(clamp(12px,2.5vw,20px), env(safe-area-inset-top)) !important;
  right: max(clamp(12px,2.5vw,20px), env(safe-area-inset-right)) !important; }
.gr-action-btn { bottom: max(clamp(16px,3vh,28px), env(safe-area-inset-bottom)) !important;
  right: max(clamp(16px,3vw,28px), env(safe-area-inset-right)) !important; }
