/* Heretic Hunter Server Connect Bar */
:root {
  --hh-bg: rgba(15, 23, 42, 0.85);
  --hh-border: rgba(255, 255, 255, 0.12);
  --hh-accent: #38bdf8;
  --hh-accent-hover: #0284c7;
  --hh-discord: #5865F2;
  --hh-discord-hover: #4752c4;
  --hh-success: #22c55e;
  --hh-text: #f8fafc;
  --hh-text-muted: #94a3b8;
  --hh-pill-bg: rgba(255, 255, 255, 0.07);
  --hh-pill-hover: rgba(255, 255, 255, 0.14);
}

#server-connect-bar {
  position: fixed;
  top: 14px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 10000;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 6px 14px;
  background: var(--hh-bg);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid var(--hh-border);
  border-radius: 9999px;
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.45), 0 1px 1px rgba(255, 255, 255, 0.1) inset;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  color: var(--hh-text);
  font-size: 13px;
  user-select: none;
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

#server-connect-bar.collapsed {
  padding: 6px 12px;
}

#server-connect-bar.collapsed .hh-expandable {
  display: none !important;
}

/* Brand badge */
.hh-brand {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 700;
  letter-spacing: 0.3px;
  color: #fff;
  padding-right: 6px;
  border-right: 1px solid rgba(255, 255, 255, 0.12);
  white-space: nowrap;
}

.hh-status-dot {
  width: 8px;
  height: 8px;
  background-color: var(--hh-success);
  border-radius: 50%;
  box-shadow: 0 0 8px var(--hh-success);
  animation: hh-pulse 2s infinite;
}

@keyframes hh-pulse {
  0% {
    box-shadow: 0 0 0 0 rgba(34, 197, 94, 0.7);
  }
  70% {
    box-shadow: 0 0 0 6px rgba(34, 197, 94, 0);
  }
  100% {
    box-shadow: 0 0 0 0 rgba(34, 197, 94, 0);
  }
}

/* Connect button pills */
.hh-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  background: var(--hh-pill-bg);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 9999px;
  color: var(--hh-text);
  text-decoration: none;
  font-weight: 500;
  font-size: 12px;
  cursor: pointer;
  transition: all 0.15s ease;
  white-space: nowrap;
}

.hh-btn:hover {
  background: var(--hh-pill-hover);
  border-color: rgba(255, 255, 255, 0.2);
  transform: translateY(-1px);
}

.hh-btn:active {
  transform: translateY(0);
}

.hh-btn-tag {
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  padding: 2px 5px;
  border-radius: 4px;
  background: rgba(255, 255, 255, 0.12);
  color: var(--hh-accent);
}

.hh-btn.copied {
  background: rgba(34, 197, 94, 0.25) !important;
  border-color: var(--hh-success) !important;
  color: #86efac !important;
}

/* Discord special button */
.hh-btn-discord {
  background: var(--hh-discord);
  border-color: var(--hh-discord);
  color: #fff;
  font-weight: 600;
}

.hh-btn-discord:hover {
  background: var(--hh-discord-hover);
  border-color: var(--hh-discord-hover);
  color: #fff;
}

/* Collapse toggle button */
.hh-toggle-btn {
  background: transparent;
  border: none;
  color: var(--hh-text-muted);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 4px;
  border-radius: 50%;
  transition: all 0.15s ease;
}

.hh-toggle-btn:hover {
  color: #fff;
  background: rgba(255, 255, 255, 0.1);
}

/* Toast popup notification */
#hh-toast {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%) translateY(20px);
  background: rgba(15, 23, 42, 0.95);
  backdrop-filter: blur(12px);
  border: 1px solid var(--hh-success);
  color: #86efac;
  padding: 10px 20px;
  border-radius: 9999px;
  font-size: 13px;
  font-weight: 600;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.4);
  opacity: 0;
  pointer-events: none;
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  z-index: 10001;
  display: flex;
  align-items: center;
  gap: 8px;
}

#hh-toast.show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

/* Responsive adjustments */
@media (max-width: 900px) {
  #server-connect-bar {
    top: 10px;
    gap: 6px;
    padding: 5px 10px;
    font-size: 11px;
  }
  .hh-btn {
    padding: 5px 9px;
    font-size: 11px;
  }
  .hh-btn-address {
    display: none;
  }
}

@media (max-width: 600px) {
  #server-connect-bar {
    max-width: 95vw;
    overflow-x: auto;
  }
  .hh-brand-text {
    display: none;
  }
}
