:root {
  --bg: #07000f;
  --purple-900: #1a0033;
  --purple-700: #3b0764;
  --purple-500: #7c3aed;
  --purple-400: #a78bfa;
  --purple-300: #c4b5fd;
  --glow: 0 0 20px rgba(167, 139, 250, 0.35);
  --glow-strong: 0 0 35px rgba(167, 139, 250, 0.55);
  --glass: rgba(20, 5, 40, 0.55);
  --border: rgba(167, 139, 250, 0.25);
  --text: #e9d5ff;
  --text-dim: #c4b5fd;
  --online: #22c55e;
  --idle: #eab308;
  --dnd: #ef4444;
  --offline: #6b7280;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: 'Inter', system-ui, sans-serif;
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
  overflow-x: hidden;
  position: relative;
}

.bg-overlay {
  position: fixed;
  inset: 0;
  background: url('UI/background.gif') center/cover no-repeat;
  z-index: -2;
  filter: brightness(0.85) saturate(1.2);
}

.bg-overlay::after {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at 30% 20%, rgba(124, 58, 237, 0.25), transparent 50%),
              radial-gradient(ellipse at 70% 80%, rgba(59, 7, 100, 0.4), transparent 50%),
              linear-gradient(to bottom, rgba(7, 0, 15, 0.4), rgba(7, 0, 15, 0.85));
}

.container {
  max-width: 1280px;
  margin: 0 auto;
  padding: 2.5rem 1.5rem 6rem;
  display: grid;
  grid-template-columns: 1fr 1fr;
  grid-template-rows: auto auto;
  gap: 1.5rem;
}

.glass {
  background: var(--glass);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  border: 1px solid var(--border);
  border-radius: 18px;
  box-shadow: var(--glow), inset 0 1px 0 rgba(255,255,255,0.05);
}

.card {
  padding: 1.75rem;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.card:hover {
  transform: translateY(-3px);
  box-shadow: var(--glow-strong), inset 0 1px 0 rgba(255,255,255,0.08);
}

/* Profile Card */
.profile-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

.pfp-wrapper {
  position: relative;
  margin-bottom: 1.25rem;
}

.pfp {
  width: 120px;
  height: 120px;
  border-radius: 50%;
  object-fit: cover;
  border: 3px solid var(--purple-500);
  box-shadow: 0 0 25px rgba(124, 58, 237, 0.6);
}

.status-dot {
  position: absolute;
  bottom: 6px;
  right: 6px;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--offline);
  border: 3px solid var(--purple-900);
  box-shadow: 0 0 10px currentColor;
}

.name {
  font-family: 'JetBrains Mono', monospace;
  font-size: 1.75rem;
  font-weight: 700;
  letter-spacing: -0.5px;
  background: linear-gradient(135deg, #e9d5ff, #a78bfa);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  margin-bottom: 0.25rem;
}

.tag {
  font-size: 0.9rem;
  color: var(--purple-400);
  margin-bottom: 1rem;
  font-family: 'JetBrains Mono', monospace;
}

.desc {
  font-size: 0.95rem;
  line-height: 1.55;
  color: var(--text-dim);
  max-width: 320px;
}

/* About Card */
.about-card h2 {
  font-family: 'JetBrains Mono', monospace;
  font-size: 1.15rem;
  margin-bottom: 1rem;
  color: var(--purple-300);
}

.about-card p {
  line-height: 1.6;
  color: var(--text-dim);
  margin-bottom: 1.25rem;
}

.tech-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.tech-tags span {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.75rem;
  padding: 0.3rem 0.7rem;
  background: rgba(124, 58, 237, 0.2);
  border: 1px solid rgba(167, 139, 250, 0.3);
  border-radius: 999px;
  color: var(--purple-300);
}

/* Links */
.links-card h2 {
  font-family: 'JetBrains Mono', monospace;
  font-size: 1.15rem;
  margin-bottom: 1.25rem;
  color: var(--purple-300);
}

.links {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.75rem;
}

.link-btn {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  padding: 0.85rem 1rem;
  background: rgba(124, 58, 237, 0.15);
  border: 1px solid rgba(167, 139, 250, 0.25);
  border-radius: 12px;
  color: var(--text);
  text-decoration: none;
  font-weight: 500;
  font-size: 0.9rem;
  transition: all 0.2s ease;
}

.link-btn img {
  width: 22px;
  height: 22px;
  filter: drop-shadow(0 0 6px rgba(167, 139, 250, 0.5));
}

.link-btn:hover {
  background: rgba(124, 58, 237, 0.35);
  border-color: var(--purple-400);
  box-shadow: 0 0 18px rgba(124, 58, 237, 0.4);
  transform: translateY(-2px);
}

/* Live Card */
.live-card {
  display: flex;
  flex-direction: column;
  padding: 0;
  overflow: hidden;
}

.live-half {
  padding: 1.5rem;
}

.live-half h3 {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.95rem;
  color: var(--purple-300);
  margin-bottom: 1rem;
  letter-spacing: 0.5px;
}

.divider {
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--border), transparent);
}

.discord-user {
  display: flex;
  gap: 1rem;
  align-items: flex-start;
}

.discord-user .avatar {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  border: 2px solid var(--purple-500);
  object-fit: cover;
  flex-shrink: 0;
}

.discord-user .info {
  flex: 1;
  min-width: 0;
}

.discord-user .username {
  font-family: 'JetBrains Mono', monospace;
  font-weight: 600;
  font-size: 1.05rem;
  margin-bottom: 0.25rem;
}

.discord-user .status {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.8rem;
  font-weight: 500;
  margin-bottom: 0.5rem;
}

.discord-user .status::before {
  content: '';
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: currentColor;
  box-shadow: 0 0 8px currentColor;
}

.discord-user .bio {
  font-size: 0.85rem;
  color: var(--text-dim);
  line-height: 1.4;
}

.banner {
  width: 100%;
  height: 70px;
  object-fit: cover;
  border-radius: 10px;
  margin-top: 0.75rem;
  border: 1px solid var(--border);
}

.stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.75rem;
}

.stat {
  text-align: center;
  padding: 0.9rem 0.5rem;
  background: rgba(0, 0, 0, 0.25);
  border-radius: 12px;
  border: 1px solid rgba(167, 139, 250, 0.15);
}

.stat .label {
  display: block;
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  color: var(--text-dim);
  margin-bottom: 0.35rem;
}

.stat .value {
  font-family: 'JetBrains Mono', monospace;
  font-size: 1.35rem;
  font-weight: 700;
}

.stat .value.online { color: var(--online); text-shadow: 0 0 12px rgba(34, 197, 94, 0.5); }
.stat .value.offline { color: var(--offline); }

/* Volume Control */
.volume-control {
  position: fixed;
  bottom: 1.5rem;
  right: 1.5rem;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.7rem 1.1rem;
  z-index: 100;
}

#mute-btn {
  background: none;
  border: none;
  color: var(--purple-300);
  cursor: pointer;
  display: flex;
  padding: 0.25rem;
  transition: color 0.2s;
}

#mute-btn:hover {
  color: var(--purple-400);
}

#volume-icon {
  width: 22px;
  height: 22px;
}

#volume-slider {
  -webkit-appearance: none;
  appearance: none;
  width: 100px;
  height: 5px;
  background: rgba(167, 139, 250, 0.25);
  border-radius: 999px;
  outline: none;
}

#volume-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 14px;
  height: 14px;
  background: var(--purple-400);
  border-radius: 50%;
  cursor: pointer;
  box-shadow: 0 0 10px rgba(167, 139, 250, 0.7);
}

#volume-slider::-moz-range-thumb {
  width: 14px;
  height: 14px;
  background: var(--purple-400);
  border-radius: 50%;
  cursor: pointer;
  border: none;
  box-shadow: 0 0 10px rgba(167, 139, 250, 0.7);
}

/* Loading & Responsive */
.loading {
  color: var(--text-dim);
  font-size: 0.9rem;
}

@media (max-width: 900px) {
  .container {
    grid-template-columns: 1fr;
    padding-bottom: 7rem;
  }
  
  .links {
    grid-template-columns: 1fr;
  }
}
