/* ─── Reset ─────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --bg:        #2e3440;
  --surface:   rgba(59,66,82,0.55);
  --border:    rgba(76,86,106,0.4);
  --text:      #d8dee9;
  --muted:     rgba(216,222,233,0.45);
  --accent:    #88c0d0;
  --accent2:   #81a1c1;
  --link-bg:   rgba(59,66,82,0.35);
  --link-hover:rgba(67,76,94,0.5);
  --radius-card: 20px;
  --radius-btn:  12px;
  --font: 'JetBrains Mono', 'Inter', system-ui, monospace;
}

html, body {
  height: 100%;
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  overflow: hidden;
}

/* ─── Splash ─────────────────────────────────────────────────── */
.splash {
  position: fixed; inset: 0;
  display: flex; align-items: center; justify-content: center;
  background: var(--bg);
  cursor: pointer;
  z-index: 100;
  transition: opacity 0.6s ease, visibility 0.6s ease;
}
.splash.fade-out { opacity: 0; visibility: hidden; }

.splash-text {
  font-size: 1.1rem;
  color: var(--muted);
  letter-spacing: 0.08em;
  animation: pulse 2s ease-in-out infinite;
  user-select: none;
}

@keyframes pulse {
  0%, 100% { opacity: 0.4; }
  50%       { opacity: 1; }
}

/* ─── Main wrapper ───────────────────────────────────────────── */
.main {
  position: fixed; inset: 0;
  display: flex; flex-direction: column;
  align-items: center; justify-content: center;
  overflow-y: auto;
  padding: 40px 16px;
  opacity: 1;
  transition: opacity 0.5s ease;
}
.main.hidden { opacity: 0; pointer-events: none; }
.main.visible { opacity: 1; pointer-events: all; }

/* ─── Background ─────────────────────────────────────────────── */
.bg-blur {
  position: fixed; inset: 0; z-index: -2;
  background: var(--bg);
  overflow: hidden;
}

.bg-blur::before {
  content: '';
  position: absolute; inset: -60px;
  background: url('assets/background.png') center/cover no-repeat;
  filter: blur(15px) brightness(0.3) saturate(0.8);
}

.particles {
  position: fixed; inset: 0; z-index: -1;
  pointer-events: none;
}

.particle {
  position: absolute;
  width: 2px; height: 2px;
  border-radius: 50%;
  background: var(--accent);
  opacity: 0;
  animation: float-up var(--dur, 8s) var(--delay, 0s) ease-in infinite;
}

@keyframes float-up {
  0%   { transform: translateY(100vh) scale(0); opacity: 0; }
  10%  { opacity: 0.6; }
  90%  { opacity: 0.3; }
  100% { transform: translateY(-10vh) scale(1); opacity: 0; }
}

/* ─── Card ───────────────────────────────────────────────────── */
.card {
  position: relative;
  width: 100%; max-width: 440px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-card);
  backdrop-filter: blur(24px) saturate(160%);
  -webkit-backdrop-filter: blur(24px) saturate(160%);
  padding: 40px 32px 32px;
  display: flex; flex-direction: column; align-items: center;
  gap: 0;
  box-shadow: 0 8px 60px rgba(0,0,0,0.55), 0 1px 0 rgba(255,255,255,0.06) inset;
  animation: card-in 0.5s ease both;
}

@keyframes card-in {
  from { transform: translateY(20px); opacity: 0; }
  to   { transform: translateY(0);    opacity: 1; }
}

/* ─── Avatar ─────────────────────────────────────────────────── */
.avatar-wrap {
  position: relative;
  width: 96px; height: 96px;
  margin-bottom: 16px;
}

.avatar {
  width: 96px; height: 96px;
  border-radius: 50%;
  object-fit: cover;
  position: relative; z-index: 1;
}

.avatar-ring {
  position: absolute; inset: -3px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--accent), var(--accent2));
  z-index: 0;
  animation: spin-ring 4s linear infinite;
}

@keyframes spin-ring {
  from { filter: hue-rotate(0deg); }
  to   { filter: hue-rotate(360deg); }
}

/* ─── Text ───────────────────────────────────────────────────── */
.username {
  font-size: 1.5rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: 2px;
}

.uid {
  font-size: 0.72rem;
  color: var(--muted);
  margin-bottom: 12px;
  letter-spacing: 0.04em;
}

.bio {
  font-size: 0.9rem;
  color: rgba(216,222,233,0.72);
  text-align: center;
  margin-bottom: 16px;
  max-width: 280px;
  line-height: 1.5;
}

/* ─── Badges ─────────────────────────────────────────────────── */
.badges {
  display: flex; flex-wrap: wrap; gap: 6px;
  justify-content: center;
  margin-bottom: 24px;
}

.badge {
  font-size: 0.72rem;
  padding: 4px 10px;
  border-radius: 20px;
  background: rgba(136,192,208,0.15);
  border: 1px solid rgba(136,192,208,0.3);
  color: var(--accent);
  letter-spacing: 0.02em;
}

/* ─── Social links ───────────────────────────────────────────── */
.socials {
  width: 100%;
  display: flex; flex-direction: column; gap: 8px;
  margin-bottom: 24px;
}

.social-link {
  display: flex; align-items: center; gap: 12px;
  padding: 11px 16px;
  border-radius: var(--radius-btn);
  background: var(--link-bg);
  border: 1px solid var(--border);
  color: var(--text);
  text-decoration: none;
  font-size: 0.87rem;
  font-weight: 500;
  transition: background 0.18s, transform 0.15s, border-color 0.18s;
}

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

.social-link i {
  width: 18px; text-align: center;
  font-size: 1rem;
  color: var(--accent);
}

.social-link span {
  flex: 1;
}

.social-arrow {
  font-size: 0.65rem !important;
  color: var(--muted) !important;
  transition: color 0.18s;
}

.social-link:hover .social-arrow {
  color: var(--accent) !important;
}

/* ─── Views ──────────────────────────────────────────────────── */
.views {
  display: flex; align-items: center; gap: 6px;
  font-size: 0.78rem;
  color: var(--muted);
}

.views i { font-size: 0.85rem; }

/* ─── Footer ─────────────────────────────────────────────────── */
.footer {
  margin-top: 20px;
  font-size: 0.72rem;
  color: rgba(255,255,255,0.25);
}

.footer a {
  color: rgba(136,192,208,0.6);
  text-decoration: none;
}
.footer a:hover { color: var(--accent); }

/* ─── Scrollbar ──────────────────────────────────────────────── */
::-webkit-scrollbar { width: 4px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--border); border-radius: 4px; }

/* ─── Volume slider ──────────────────────────────────────────── */
.volume-wrap {
  position: fixed; left: 16px; bottom: 16px;
  display: flex; align-items: center; gap: 8px;
  z-index: 10;
  padding: 6px 10px;
  border-radius: var(--radius-btn);
  background: var(--surface);
  border: 1px solid var(--border);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

.volume-wrap i {
  font-size: 0.85rem;
  color: var(--accent);
  width: 16px;
  text-align: center;
}

.volume-slider {
  -webkit-appearance: none; appearance: none;
  width: 64px; height: 4px;
  border-radius: 2px;
  background: var(--border);
  outline: none;
  cursor: pointer;
}

.volume-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 12px; height: 12px;
  border-radius: 50%;
  background: var(--accent);
  border: 2px solid var(--bg);
  cursor: pointer;
}

.volume-slider::-moz-range-thumb {
  width: 12px; height: 12px;
  border-radius: 50%;
  background: var(--accent);
  border: 2px solid var(--bg);
  cursor: pointer;
}

/* ─── Music widget ────────────────────────────────────────────── */
.music {
  display: none;
  position: fixed; right: 16px; bottom: 16px;
  z-index: 10;
  gap: 10px;
  padding: 10px 12px;
  border-radius: var(--radius-btn);
  background: var(--surface);
  border: 1px solid var(--border);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  max-width: 280px;
}

.music-art {
  flex-shrink: 0;
  width: 56px; height: 56px;
  border-radius: 8px;
  overflow: hidden;
  background: linear-gradient(135deg, rgba(136,192,208,0.3), rgba(129,161,193,0.3));
  display: flex; align-items: center; justify-content: center;
}

.music-art img {
  width: 100%; height: 100%;
  object-fit: cover;
  display: block;
}

.music-body {
  flex: 1;
  min-width: 0;
  display: flex; flex-direction: column;
  gap: 4px;
}

.music-title {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text);
  white-space: nowrap; overflow: hidden;
  text-overflow: ellipsis;
}

.music-artist {
  font-size: 0.7rem;
  color: var(--muted);
  white-space: nowrap; overflow: hidden;
  text-overflow: ellipsis;
}

.music-progress-wrap {
  display: flex; flex-direction: column;
  gap: 2px;
}

.music-progress {
  -webkit-appearance: none; appearance: none;
  width: 100%; height: 4px;
  border-radius: 2px;
  background: var(--border);
  outline: none;
  cursor: pointer;
}

.music-progress::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 10px; height: 10px;
  border-radius: 50%;
  background: var(--accent);
  border: 2px solid var(--bg);
  cursor: pointer;
}

.music-progress::-moz-range-thumb {
  width: 10px; height: 10px;
  border-radius: 50%;
  background: var(--accent);
  border: 2px solid var(--bg);
  cursor: pointer;
}

.music-time {
  display: flex; justify-content: space-between;
  font-size: 0.6rem;
  color: var(--muted);
}

.music-controls {
  display: flex; align-items: center; justify-content: center;
  gap: 12px;
  margin-top: 2px;
}

.music-btn {
  background: none; border: none;
  color: var(--muted);
  font-size: 0.85rem;
  cursor: pointer;
  padding: 4px;
  transition: color 0.15s;
  display: flex;
}

.music-btn:hover { color: var(--accent); }

.music-play-btn {
  font-size: 1.1rem;
  color: var(--accent);
}

.music-play-btn:hover { color: #b0e0e6; }

/* ─── Responsive ─────────────────────────────────────────────── */
@media (max-width: 480px) {
  .card { padding: 32px 20px 24px; }
  .username { font-size: 1.3rem; }
}
