/* EggHunt overlay — no fullscreen layer (breaks WebGL compositor) */
#egghunt-ui {
  position: static;
  pointer-events: none;
  font-family: Nunito, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  font-size: 14px;
  line-height: 1.2;
}

#egghunt-ui a,
#egghunt-ui button {
  pointer-events: auto;
}

#eh-ticker {
  position: fixed;
  top: max(12px, env(safe-area-inset-top));
  left: 50%;
  transform: translateX(-50%);
  z-index: 6;
  padding: 7px 14px;
  border-radius: 999px;
  background: linear-gradient(298deg, #9a57c5 25%, #cba4e2 99.4%);
  color: #fff;
  font-family: Nunito, sans-serif;
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  box-shadow: 0 4px 16px rgba(154, 87, 197, 0.35);
  white-space: nowrap;
  line-height: 1;
}

#eh-actions {
  position: fixed;
  right: max(16px, env(safe-area-inset-right));
  bottom: max(20px, env(safe-area-inset-bottom));
  z-index: 7;
  display: flex;
  align-items: center;
  gap: 8px;
}

/* Join / push panel — lift above overlay buttons */
.home-popin {
  bottom: max(68px, calc(env(safe-area-inset-bottom) + 52px)) !important;
  z-index: 5 !important;
}

@media (min-width: 768px) {
  .home-popin {
    bottom: max(76px, calc(env(safe-area-inset-bottom) + 60px)) !important;
  }
}

.eh-btn {
  box-sizing: border-box;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  height: 40px;
  min-width: 40px;
  padding: 0 12px;
  border: 2px solid rgba(255, 255, 255, 0.85);
  border-radius: 999px;
  background: rgba(14, 58, 68, 0.88);
  color: #fff;
  font-family: Nunito, sans-serif;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  line-height: 1;
  cursor: pointer;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.18);
  text-decoration: none;
  margin: 0;
  appearance: none;
  -webkit-appearance: none;
  transition: transform 0.2s ease, background 0.2s ease;
}

.eh-btn:hover {
  transform: translateY(-1px);
  background: rgba(20, 78, 92, 0.95);
}

.eh-btn svg {
  width: 14px;
  height: 14px;
  fill: currentColor;
  display: block;
  flex-shrink: 0;
}

#eh-info-backdrop {
  position: fixed;
  inset: 0;
  z-index: 10001;
  background: rgba(8, 20, 28, 0.55);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s ease;
}

#eh-info-backdrop.open {
  opacity: 1;
  pointer-events: auto;
}

#eh-info-panel {
  position: fixed;
  top: 50%;
  left: 50%;
  z-index: 10002;
  width: min(92vw, 420px);
  max-height: min(80vh, 640px);
  overflow: auto;
  padding: 28px 24px 24px;
  border-radius: 20px;
  background: linear-gradient(160deg, #1a3844 0%, #0e3a44 100%);
  color: #fff;
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.35);
  opacity: 0;
  pointer-events: none;
  transform: translate(-50%, -46%) scale(0.96);
  transition: opacity 0.25s ease, transform 0.25s ease;
  font-family: Nunito, sans-serif;
  font-size: 14px;
}

#eh-info-panel.open {
  opacity: 1;
  pointer-events: auto;
  transform: translate(-50%, -50%) scale(1);
}

#eh-info-panel h2 {
  font-family: Grauna, Nunito, sans-serif;
  font-size: 28px;
  line-height: 1;
  text-transform: uppercase;
  margin: 0 0 8px;
}

#eh-info-panel .tag {
  display: inline-block;
  margin-bottom: 16px;
  padding: 4px 10px;
  border-radius: 999px;
  background: rgba(154, 87, 197, 0.25);
  color: #e8d4ff;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

#eh-info-panel p,
#eh-info-panel li {
  font-size: 14px;
  line-height: 1.55;
  color: rgba(255, 255, 255, 0.88);
}

#eh-info-panel ul {
  margin: 0 0 16px;
  padding-left: 18px;
}

#eh-info-panel .section-title {
  margin: 18px 0 8px;
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: #cba4e2;
}

#eh-info-close {
  position: absolute;
  top: 12px;
  right: 14px;
  width: 36px;
  height: 36px;
  border: none;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
  font-size: 24px;
  line-height: 36px;
  text-align: center;
  cursor: pointer;
  padding: 0;
  margin: 0;
}

#eh-contract-block {
  margin-top: 16px;
  padding: 12px;
  border-radius: 12px;
  background: rgba(0, 0, 0, 0.2);
}

#eh-contract-block .label {
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.55);
  margin-bottom: 6px;
}

#eh-contract-addr {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 11px;
  word-break: break-all;
  color: #f2e8ff;
}

#eh-contract-copy {
  display: block;
  margin-top: 10px;
  width: 100%;
  min-height: 38px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
  font-weight: 800;
  text-align: center;
  line-height: 38px;
  cursor: pointer;
  padding: 0;
  font-family: Nunito, sans-serif;
  font-size: 12px;
}

@media (max-width: 640px) {
  #eh-actions {
    right: max(12px, env(safe-area-inset-right));
    bottom: max(16px, env(safe-area-inset-bottom));
    flex-wrap: wrap;
    justify-content: flex-end;
    max-width: calc(100vw - 24px);
  }

  .home-popin {
    bottom: max(76px, calc(env(safe-area-inset-bottom) + 60px)) !important;
    width: min(85%, 320px) !important;
  }

  #eh-ticker {
    font-size: 10px;
    padding: 6px 12px;
  }
}

/* Home menu — teal/purple hunt gradient instead of flat white */
html,
body {
  background: linear-gradient(145deg, #0b2e38 0%, #145a6b 38%, #2a7f92 62%, #6b4f8a 100%);
  background-attachment: fixed;
}

.view-home {
  background: radial-gradient(ellipse 120% 80% at 50% 20%, rgba(203, 164, 226, 0.22), transparent 55%),
    radial-gradient(ellipse 90% 60% at 80% 90%, rgba(31, 105, 126, 0.35), transparent 50%);
}

.menu:not(.menu-open) .menu-background {
  opacity: 0.35;
}

.menu-background {
  background: linear-gradient(160deg, rgba(14, 58, 68, 0.92) 0%, rgba(26, 56, 68, 0.88) 100%) !important;
}
