/* ==========================================================================
   DISCORD PROFILE & BIO WEB THEME - ACRYLIC MATERIAL & COMPACT PROFILE
   ========================================================================== */

:root {
  --discord-primary: #5865F2;
  --discord-primary-hover: #4752c4;
  --discord-green: #23a55a;
  --discord-yellow: #f0b232;
  --discord-red: #f23f43;
  --discord-offline: #80848e;
  --spotify-green: #1ed760;
  --nitro-pink: #f47fff;

  --bg-deep: #090a0f;
  --acrylic-bg: rgba(16, 18, 26, 0.42);
  --card-inner: rgba(255, 255, 255, 0.05);
  --card-inner-hover: rgba(255, 255, 255, 0.09);
  --card-border: rgba(255, 255, 255, 0.14);
  --card-border-glow: rgba(255, 255, 255, 0.25);

  --text-normal: #f2f3f5;
  --text-muted: #949ba4;
  --text-sub: #b5bac1;

  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 18px;
  --radius-xl: 24px;

  --font-main: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-mono: 'JetBrains Mono', monospace;

  /* Custom Wallpaper & Banner (Có thể thay qua script.js hoặc ghi đè tại đây) */
  --wallpaper-url: url('assets/images/wallpaper.gif');
  --banner-url: url('assets/images/banner.jpg');

  /* Kích thước thẻ hồ sơ & Chiều cao Banner (Kéo to theo ý muốn) */
  --card-width: 780px;
  --banner-height: 250px;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  -webkit-font-smoothing: antialiased;
}

body {
  font-family: var(--font-main);
  background-color: var(--bg-deep);
  color: var(--text-normal);
  min-height: 100vh;
  overflow-x: hidden;
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 36px 14px;
}

/* ==========================================================================
   ACRYLIC WALLPAPER TÙY BIẾN ĐẰNG SAU (HÌNH NỀN RÕ NÉT - GIẢM MỜ ACRYLIC)
   ========================================================================== */
.acrylic-backdrop {
  position: fixed;
  inset: -15px;
  z-index: 0;
  background-image: var(--wallpaper-url);
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  filter: blur(4px) brightness(0.9) saturate(115%);
  transform: scale(1.03);
  pointer-events: none;
}

.acrylic-overlay {
  position: fixed;
  inset: 0;
  z-index: 0;
  background: 
    radial-gradient(circle at 15% 20%, rgba(88, 101, 242, 0.14) 0%, transparent 45%),
    radial-gradient(circle at 85% 75%, rgba(244, 127, 255, 0.1) 0%, transparent 45%),
    rgba(9, 10, 15, 0.18);
  pointer-events: none;
}

/* Lớp hạt Canvas */
#bg-canvas {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 1;
  pointer-events: none;
}

/* Scrollbar tùy chỉnh */
::-webkit-scrollbar {
  width: 7px;
}
::-webkit-scrollbar-track {
  background: #0f1015;
}
::-webkit-scrollbar-thumb {
  background: #2b2d38;
  border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
  background: #3c3f4e;
}

/* ==========================================================================
   MÀN HÌNH LOADING & ENTER (SPA OVERLAY - CÓ HÌNH NỀN & AVATAR ĐỘNG)
   ========================================================================== */
#loading-screen {
  position: fixed;
  inset: 0;
  background-image: var(--wallpaper-url, url('assets/images/wallpaper.jpg'));
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  z-index: 99999;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: opacity 0.7s cubic-bezier(0.4, 0, 0.2, 1), 
              visibility 0.7s cubic-bezier(0.4, 0, 0.2, 1),
              transform 0.7s cubic-bezier(0.4, 0, 0.2, 1);
  cursor: pointer;
  overflow: hidden;
}

#loading-screen::before {
  content: '';
  position: absolute;
  inset: -30px;
  background: radial-gradient(circle at center, rgba(16, 18, 26, 0.76) 0%, rgba(9, 10, 15, 0.92) 100%);
  backdrop-filter: blur(28px) saturate(160%);
  -webkit-backdrop-filter: blur(28px) saturate(160%);
  z-index: 0;
}

#loading-screen.fade-out {
  opacity: 0;
  visibility: hidden;
  transform: scale(1.04);
  pointer-events: none;
}

.loader-content {
  position: relative;
  z-index: 2;
  text-align: center;
  max-width: 420px;
  width: 90%;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 18px;
}

/* AVATAR + DECORATION TRONG LOADING (THAY THẾ LOGO DISCORD) */
.loading-avatar-wrapper {
  position: relative;
  width: 106px;
  height: 106px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 4px;
}

.loading-avatar-box {
  position: relative;
  width: 92px;
  height: 92px;
}

.loading-avatar-img {
  width: 92px;
  height: 92px;
  border-radius: 50%;
  object-fit: cover;
  border: 4px solid rgba(88, 101, 242, 0.7);
  box-shadow: 0 0 25px rgba(88, 101, 242, 0.5), inset 0 0 10px rgba(0, 0, 0, 0.6);
  display: block;
  animation: avatarPulse 2.5s ease-in-out infinite alternate;
}

.loading-decor-img {
  position: absolute;
  top: -15%;
  left: -15%;
  width: 130%;
  height: 130%;
  pointer-events: none;
  z-index: 2;
  filter: drop-shadow(0 0 12px rgba(244, 127, 255, 0.6));
}

.loading-avatar-glow {
  position: absolute;
  inset: -12px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(88, 101, 242, 0.45) 0%, transparent 70%);
  z-index: -1;
  animation: glowPulse 2s ease-in-out infinite alternate;
}

@keyframes avatarPulse {
  0% { transform: scale(1); filter: brightness(1); }
  100% { transform: scale(1.04); filter: brightness(1.15); }
}

@keyframes glowPulse {
  0% { opacity: 0.35; transform: scale(0.9); }
  100% { opacity: 0.95; transform: scale(1.25); }
}

.loading-info {
  width: 100%;
}

/* TÊN HIỂN THỊ CÓ ANIMATION TÁCH TỪNG KÝ TỰ */
.animated-name {
  display: inline-flex;
  justify-content: center;
  align-items: center;
  gap: 3px;
  font-size: 1.6rem;
  font-weight: 800;
  letter-spacing: 2px;
  margin-bottom: 14px;
}

.animated-name span {
  display: inline-block;
  color: #fff;
  text-shadow: 0 0 12px rgba(88, 101, 242, 0.8), 0 0 24px rgba(244, 127, 255, 0.4);
  animation: letterWave 1.8s ease-in-out infinite;
  animation-delay: calc(var(--i) * 0.12s);
}

@keyframes letterWave {
  0%, 100% {
    transform: translateY(0px) scale(1);
    color: #f2f3f5;
    text-shadow: 0 0 12px rgba(88, 101, 242, 0.6);
  }
  50% {
    transform: translateY(-8px) scale(1.12);
    color: #c7d2fe;
    text-shadow: 0 0 20px rgba(88, 101, 242, 1), 0 0 35px rgba(244, 127, 255, 0.85);
  }
}

.progress-bar-container {
  width: 100%;
  height: 7px;
  background: #1a1c24;
  border-radius: 99px;
  overflow: hidden;
  position: relative;
  border: 1px solid rgba(255, 255, 255, 0.06);
}

.progress-bar-fill {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, #5865F2, #858ff8, #5865F2);
  background-size: 200% 100%;
  border-radius: 99px;
  transition: width 0.3s ease;
  animation: shimmer 2s infinite linear;
}

@keyframes shimmer {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

.progress-meta {
  display: flex;
  justify-content: space-between;
  margin-top: 10px;
  font-size: 0.8rem;
  color: var(--text-muted);
}

#loading-percentage {
  font-family: var(--font-mono);
  color: var(--discord-primary);
  font-weight: 600;
}

.enter-prompt {
  display: none;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  animation: fadeInUp 0.5s ease forwards;
}

.enter-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(35, 165, 90, 0.15);
  border: 1px solid rgba(35, 165, 90, 0.3);
  color: #57f287;
  padding: 6px 14px;
  border-radius: 20px;
  font-size: 0.8rem;
  font-weight: 600;
}

.enter-btn {
  background: linear-gradient(135deg, #5865F2, #4752c4);
  color: #fff;
  border: none;
  padding: 13px 30px;
  border-radius: 99px;
  font-size: 0.92rem;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  cursor: pointer;
  box-shadow: 0 4px 20px rgba(88, 101, 242, 0.45);
  transition: all 0.25s ease;
  animation: pulseButton 1.8s infinite;
}

.enter-btn:hover {
  transform: translateY(-2px) scale(1.03);
  box-shadow: 0 6px 28px rgba(88, 101, 242, 0.65);
}

@keyframes pulseButton {
  0%, 100% { box-shadow: 0 0 0 0 rgba(88, 101, 242, 0.6); }
  50% { box-shadow: 0 0 0 12px rgba(88, 101, 242, 0); }
}

.enter-subtext {
  font-size: 0.76rem;
  color: var(--text-muted);
}

@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: translateY(0); }
}


/* ==========================================================================
   PAGE CONTAINER & DISCORD ACRYLIC CARD (CO GỌN GÀNG - CHUẨN DISCORD)
   ========================================================================== */
.page-container {
  width: 100%;
  max-width: var(--card-width, 780px);
  position: relative;
  z-index: 2;
  animation: cardEnter 0.8s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes cardEnter {
  from {
    opacity: 0;
    transform: translateY(22px) scale(0.97);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.acrylic-card {
  background: var(--acrylic-bg);
  backdrop-filter: blur(12px) saturate(135%) brightness(1.04);
  -webkit-backdrop-filter: blur(12px) saturate(135%) brightness(1.04);
  border: 1px solid var(--card-border);
  border-radius: var(--radius-xl);
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.65), 
              inset 0 1px 1px 0 rgba(255, 255, 255, 0.22);
  overflow: hidden;
  position: relative;
}

/* BANNER TÙY BIẾN (KÉO TO THEO KHUNG WINDOWS) */
.discord-banner {
  height: var(--banner-height, 250px);
  background-color: #1c1e28;
  background-image: var(--banner-url);
  background-position: center;
  background-size: cover;
  background-repeat: no-repeat;
  position: relative;
  overflow: hidden;
}

.banner-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to bottom, rgba(14, 15, 20, 0.0) 0%, rgba(18, 20, 26, 0.55) 100%);
}

/* DISCORD BADGES GÓC PHẢI */
.discord-badges {
  position: absolute;
  top: 12px;
  right: 14px;
  display: flex;
  align-items: center;
  gap: 7px;
  background: rgba(12, 13, 18, 0.72);
  backdrop-filter: blur(10px);
  padding: 5px 10px;
  border-radius: 18px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  z-index: 3;
  min-height: 30px;
}

.badge-item {
  width: 22px;
  height: 22px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  position: relative;
  transition: transform 0.2s;
}

.badge-item:hover {
  transform: scale(1.25);
}

.badge-icon-img,
.badge-icon {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
}

.badge-item::after {
  content: attr(data-tooltip);
  position: absolute;
  bottom: -30px;
  left: 50%;
  transform: translateX(-50%) translateY(4px);
  background: #0f1015;
  color: #fff;
  font-size: 0.72rem;
  font-weight: 600;
  padding: 4px 8px;
  border-radius: 4px;
  white-space: nowrap;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: all 0.2s ease;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.6);
  border: 1px solid rgba(255, 255, 255, 0.1);
  z-index: 100;
}

.badge-item:hover::after {
  opacity: 1;
  visibility: visible;
  transform: translateX(-50%) translateY(0);
}

/* ==========================================================================
   AVATAR & AVATAR DECORATION (CHUẨN TỶ LỆ DISCORD)
   ========================================================================== */
.avatar-wrapper {
  padding: 0 26px;
  margin-top: -55px;
  position: relative;
  z-index: 10;
  display: flex;
  align-items: flex-end;
}

.avatar-container {
  position: relative;
  width: 100px;
  height: 100px;
}

.avatar-img {
  width: 100px;
  height: 100px;
  border-radius: 50%;
  object-fit: cover;
  border: 5px solid rgba(22, 23, 31, 0.75);
  background-color: #2b2d38;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.45);
  display: block;
}

.avatar-decoration {
  position: absolute;
  top: -15%;
  left: -15%;
  width: 130%;
  height: 130%;
  pointer-events: none;
  z-index: 5;
  filter: drop-shadow(0 2px 8px rgba(0, 0, 0, 0.4));
  transition: opacity 0.3s ease;
}

/* TRẠNG THÁI STATUS DISCORD (ONLINE, IDLE, DND, OFFLINE) */
.status-indicator {
  position: absolute;
  bottom: 0px;
  right: 0px;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: #16171f;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 6;
}

.status-dot {
  width: 15px;
  height: 15px;
  border-radius: 50%;
  background-color: var(--discord-red);
  box-shadow: 0 0 8px rgba(242, 63, 67, 0.6);
  transition: background-color 0.3s ease;
}

.status-indicator.online .status-dot {
  background-color: var(--discord-green);
  box-shadow: 0 0 8px rgba(35, 165, 90, 0.7);
}
.status-indicator.idle .status-dot {
  background-color: var(--discord-yellow);
  box-shadow: 0 0 8px rgba(240, 178, 50, 0.7);
}
.status-indicator.dnd .status-dot {
  background-color: var(--discord-red);
  box-shadow: 0 0 8px rgba(242, 63, 67, 0.7);
}
.status-indicator.offline .status-dot {
  background-color: var(--discord-offline);
  box-shadow: none;
}

/* ==========================================================================
   TÊN & USERNAME (ヴァン・フイ & vanhuy0000)
   ========================================================================== */
.profile-header-info {
  padding: 14px 26px 6px;
}

.name-row {
  display: flex;
  align-items: center;
  gap: 8px;
}

.display-name {
  font-size: 1.55rem;
  font-weight: 800;
  letter-spacing: -0.2px;
  color: var(--text-normal);
}

.pronouns-badge {
  font-size: 0.72rem;
  background: rgba(255, 255, 255, 0.08);
  color: var(--text-muted);
  padding: 2px 7px;
  border-radius: 10px;
  font-weight: 600;
}

.username-row {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  margin-top: 3px;
  cursor: pointer;
  position: relative;
  user-select: none;
}

.username {
  font-size: 0.92rem;
  color: var(--text-sub);
  font-weight: 500;
}

.copy-tag-pill {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: rgba(255, 255, 255, 0.06);
  padding: 2px 7px;
  border-radius: 5px;
  font-size: 0.72rem;
  color: var(--text-muted);
  transition: all 0.2s;
}

.username-row:hover .copy-tag-pill {
  background: rgba(88, 101, 242, 0.25);
  color: #fff;
}

.toast-copied {
  position: absolute;
  top: -28px;
  left: 0;
  background: var(--discord-primary);
  color: #fff;
  font-size: 0.72rem;
  font-weight: 700;
  padding: 3px 9px;
  border-radius: 5px;
  opacity: 0;
  pointer-events: none;
  transform: translateY(6px);
  transition: all 0.25s ease;
  white-space: nowrap;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
}

.toast-copied.show {
  opacity: 1;
  transform: translateY(0);
}

/* CUSTOM STATUS */
.custom-status-card {
  margin: 10px 26px 14px;
  padding: 10px 14px;
  background: var(--card-inner);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  gap: 9px;
  font-size: 0.88rem;
}

.status-emoji {
  font-size: 1.1rem;
}

.status-text {
  color: var(--text-sub);
  line-height: 1.4;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* DIVIDER */
.card-divider {
  height: 1px;
  background: rgba(255, 255, 255, 0.06);
  margin: 12px 26px;
}

/* ==========================================================================
   SECTIONS CHUNG
   ========================================================================== */
.section-container {
  padding: 8px 26px;
}

.section-title {
  display: flex;
  align-items: center;
  gap: 7px;
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.7px;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 9px;
}

.section-title i {
  font-size: 0.82rem;
}

/* ==========================================================================
   MEMBER SINCE: GỌN GÀNG (ĐÃ BỎ SERVER KHÔNG CẦN THIẾT)
   ========================================================================== */
.member-since-box.single-box {
  display: block;
}

.member-since-item {
  background: var(--card-inner);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: var(--radius-md);
  padding: 10px 14px;
  display: flex;
  align-items: center;
  gap: 12px;
  transition: all 0.25s ease;
}

.member-since-item:hover {
  background: var(--card-inner-hover);
  border-color: rgba(255, 255, 255, 0.12);
}

.ms-icon-wrap {
  width: 36px;
  height: 36px;
  border-radius: 9px;
  background: rgba(88, 101, 242, 0.15);
  color: var(--discord-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.05rem;
}

.ms-details {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.ms-label {
  font-size: 0.7rem;
  text-transform: uppercase;
  color: var(--text-muted);
  font-weight: 700;
  letter-spacing: 0.4px;
}

.ms-value {
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--text-normal);
}

.highlight-join {
  color: #57f287 !important;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.highlight-join::before {
  content: '';
  width: 6px;
  height: 6px;
  background: #57f287;
  border-radius: 50%;
  box-shadow: 0 0 8px #57f287;
  animation: pulseDot 1.5s infinite;
}

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

/* ==========================================================================
   ABOUT ME
   ========================================================================== */
.about-content {
  background: var(--card-inner);
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: var(--radius-md);
  padding: 12px 14px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.bio-line {
  font-size: 0.88rem;
  color: var(--text-sub);
  line-height: 1.5;
}

.bio-quote {
  font-size: 0.84rem;
  color: #9db2ec;
  margin-top: 3px;
  padding-left: 8px;
  border-left: 2px solid var(--discord-primary);
}

/* ==========================================================================
   ACTIVITY & PLAYING A GAME (TỰ ĐỘNG HIỆN KHI ĐANG VÀO GAME DISCORD)
   ========================================================================== */
.activity-card {
  background: rgba(88, 101, 242, 0.08);
  border: 1px solid rgba(88, 101, 242, 0.25);
  border-radius: var(--radius-md);
  padding: 14px 16px;
  position: relative;
  overflow: hidden;
  transition: all 0.25s ease;
}

.activity-card:hover {
  background: rgba(88, 101, 242, 0.12);
  border-color: rgba(88, 101, 242, 0.45);
  box-shadow: 0 4px 20px rgba(88, 101, 242, 0.15);
}

.activity-body {
  display: flex;
  gap: 14px;
  align-items: center;
}

.activity-asset-wrap {
  position: relative;
  width: 66px;
  height: 66px;
  flex-shrink: 0;
}

.activity-large-img {
  width: 66px;
  height: 66px;
  border-radius: 14px;
  object-fit: cover;
  background: #14161f;
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.4);
  display: block;
}

.activity-small-img {
  position: absolute;
  bottom: -4px;
  right: -4px;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  border: 2px solid #16171f;
  background: #232428;
  object-fit: cover;
}

.activity-details {
  flex: 1;
  min-width: 0;
}

.activity-top-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 3px;
}

.activity-type-badge {
  font-size: 0.68rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.6px;
  color: var(--discord-primary);
}

.activity-live-indicator {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 0.65rem;
  font-weight: 800;
  background: rgba(87, 242, 135, 0.14);
  color: #57f287;
  padding: 2px 7px;
  border-radius: 10px;
  border: 1px solid rgba(87, 242, 135, 0.3);
}

.live-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #57f287;
  display: inline-block;
}

.live-dot.pulse {
  box-shadow: 0 0 6px #57f287;
  animation: pulseDot 1.5s infinite;
}

.activity-name {
  font-size: 1rem;
  font-weight: 700;
  color: var(--text-normal);
  line-height: 1.25;
  margin-bottom: 3px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.activity-detail-text,
.activity-state-text {
  font-size: 0.82rem;
  color: var(--text-sub);
  line-height: 1.35;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.activity-time-wrap {
  margin-top: 4px;
  font-size: 0.74rem;
  color: #949ba4;
  display: flex;
  align-items: center;
  gap: 5px;
}

/* ==========================================================================
   AUDIO MUSIC PLAYER (ĐĨA QUAY TẠI CHỖ, TÔNG MÀU TRẮNG ACRYLIC TINH TẾ)
   ========================================================================== */
.spotify-card {
  background: rgba(18, 19, 26, 0.75);
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: var(--radius-md);
  padding: 18px 22px;
  display: flex;
  gap: 18px;
  align-items: center;
  position: relative;
  overflow: hidden;
  transition: all 0.3s ease;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.4);
}

.spotify-card:hover {
  border-color: rgba(255, 255, 255, 0.45);
  box-shadow: 0 6px 25px rgba(255, 255, 255, 0.12);
}

/* KHUNG ĐĨA THAN QUAY VÒNG TẠI CHỖ (ĐÃ BỎ ẢNH BÌA VUÔNG) */
.spotify-art-wrap {
  position: relative;
  width: 84px;
  height: 84px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* ĐĨA THAN (VINYL RECORD) */
.vinyl-record {
  position: relative;
  width: 84px;
  height: 84px;
  background: radial-gradient(circle, #2d2d38 0%, #181922 45%, #0a0b10 100%);
  border-radius: 50%;
  box-shadow: 0 4px 18px rgba(0, 0, 0, 0.75), inset 0 0 8px rgba(255, 255, 255, 0.22);
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(255, 255, 255, 0.18);
  animation: spinVinyl 4.5s linear infinite;
  animation-play-state: paused; /* Dừng thì để im */
  will-change: transform;
}

/* KHI ĐANG PHÁT NHẠC: ĐĨA QUAY LIÊN TỤC TẠI CHỖ */
.spotify-card.playing .vinyl-record {
  animation-play-state: running;
}

/* DỪNG THÌ ĐỂ IM: ĐỨNG YÊN HOÀN TOÀN TẠI VỊ TRÍ HIỆN TẠI */
.spotify-card:not(.playing) .vinyl-record {
  animation-play-state: paused;
}

@keyframes spinVinyl {
  0% {
    transform: rotate(0deg);
  }
  100% {
    transform: rotate(360deg);
  }
}

.vinyl-grooves {
  width: 82%;
  height: 82%;
  border-radius: 50%;
  border: 1px dashed rgba(255, 255, 255, 0.25);
  box-shadow: inset 0 0 0 4px rgba(0, 0, 0, 0.65), inset 0 0 0 8px rgba(255, 255, 255, 0.08);
  pointer-events: none;
}

.vinyl-center {
  position: absolute;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  overflow: hidden;
  border: 2px solid #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #000;
  box-shadow: 0 0 10px rgba(255, 255, 255, 0.55);
  pointer-events: none;
}

.vinyl-center::after {
  content: '';
  position: absolute;
  width: 8px;
  height: 8px;
  background: #101118;
  border: 1px solid rgba(255, 255, 255, 0.6);
  border-radius: 50%;
  z-index: 3;
}

.vinyl-label-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 50%;
}

.spotify-info {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.track-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.track-title {
  font-size: 1.02rem;
  font-weight: 700;
  color: #fff;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.spotify-live-badge {
  font-size: 0.68rem;
  font-weight: 800;
  color: #ffffff;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.28);
  padding: 3px 8px;
  border-radius: 5px;
  display: flex;
  align-items: center;
  gap: 5px;
  letter-spacing: 0.5px;
}

.live-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #ffffff;
  display: inline-block;
  box-shadow: 0 0 6px #ffffff;
}

.live-dot.pulse {
  animation: liveDotPulse 1.8s infinite ease-in-out;
}

@keyframes liveDotPulse {
  0%, 100% {
    opacity: 1;
    transform: scale(1);
  }
  50% {
    opacity: 0.35;
    transform: scale(0.85);
  }
}

.track-artist {
  font-size: 0.82rem;
  color: var(--text-muted);
}

/* ==========================================================================
   THANH TIẾN TRÌNH NHẠC (KÉO TO & TÔNG TRẮNG HIỆN ĐẠI)
   ========================================================================== */
.playback-bar-wrap {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 6px;
  margin-bottom: 6px;
  width: 100%;
}

.playback-time {
  font-size: 0.78rem;
  font-family: var(--font-mono);
  color: var(--text-sub);
  width: 38px;
  font-weight: 600;
}

.playback-bar {
  flex: 1;
  height: 10px; /* TO HƠN RÕ RÀNG */
  background: rgba(255, 255, 255, 0.16);
  border-radius: 12px;
  cursor: pointer;
  position: relative;
  transition: all 0.2s ease;
  box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.5);
}

.playback-bar:hover {
  height: 12px;
  background: rgba(255, 255, 255, 0.24);
}

.playback-progress {
  width: 0%;
  height: 100%;
  background: #ffffff;
  border-radius: 12px;
  position: relative;
  transition: width 0.1s linear;
  box-shadow: 0 0 12px rgba(255, 255, 255, 0.7);
}

/* Nút chấm tiến trình to rõ ràng để kéo thả */
.playback-progress::after {
  content: '';
  position: absolute;
  right: -7px;
  top: 50%;
  transform: translateY(-50%);
  width: 16px;
  height: 16px;
  background: #ffffff;
  border: 3px solid #16171f;
  border-radius: 50%;
  box-shadow: 0 0 12px #ffffff, 0 2px 6px rgba(0, 0, 0, 0.6);
  transition: transform 0.15s ease;
}

.playback-bar:hover .playback-progress::after {
  transform: translateY(-50%) scale(1.25);
}

.spotify-controls {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-top: 6px;
}

.ctrl-btn {
  background: none;
  border: none;
  color: var(--text-muted);
  font-size: 1rem;
  cursor: pointer;
  transition: all 0.2s;
  display: flex;
  align-items: center;
  justify-content: center;
}

.ctrl-btn:hover {
  color: #fff;
  transform: scale(1.18);
}

.play-btn {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: #ffffff;
  color: #12131a;
  font-size: 1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 0 14px rgba(255, 255, 255, 0.5);
  transition: all 0.2s ease;
}

.play-btn:hover {
  background: #ffffff;
  color: #000000;
  transform: scale(1.12);
  box-shadow: 0 0 20px rgba(255, 255, 255, 0.85);
}

.play-btn i {
  color: inherit !important;
}

.volume-slider-wrap {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-left: auto;
}

.volume-slider-wrap i {
  font-size: 0.9rem;
  color: var(--text-muted);
}

.volume-slider {
  width: 95px;
  height: 6px;
  accent-color: #ffffff;
  cursor: pointer;
}

/* ==========================================================================
   KẾT NỐI MẠNG XÃ HỘI (ĐÃ BỎ DISCORD - CO GỌN GÀNG)
   ========================================================================== */
.social-links-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
}

.social-card {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 12px;
  background: var(--card-inner);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: var(--radius-md);
  text-decoration: none;
  color: var(--text-normal);
  transition: all 0.25s ease;
  position: relative;
}

.social-card i:first-child {
  font-size: 1.15rem;
  width: 20px;
  text-align: center;
}

.social-text {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.social-type {
  font-size: 0.68rem;
  color: var(--text-muted);
  text-transform: uppercase;
  font-weight: 700;
}

.social-handle {
  font-size: 0.8rem;
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.open-link {
  font-size: 0.7rem;
  color: var(--text-muted);
  margin-left: auto;
  opacity: 0;
  transition: opacity 0.2s, transform 0.2s;
}

.social-card:hover .open-link {
  opacity: 1;
  transform: translate(2px, -2px);
}

.social-card:hover {
  transform: translateY(-2px);
  border-color: rgba(255, 255, 255, 0.15);
  background: var(--card-inner-hover);
}

.github-btn:hover { border-color: rgba(255, 255, 255, 0.5); }
.facebook-btn:hover { border-color: rgba(24, 119, 242, 0.5); }
.steam-btn:hover { border-color: rgba(23, 26, 33, 0.8); }
.youtube-btn:hover { border-color: rgba(255, 0, 0, 0.5); }
.tiktok-btn:hover { border-color: rgba(254, 44, 85, 0.5); }

/* FOOTER */
.discord-footer {
  padding: 14px 20px 18px;
  text-align: center;
  font-size: 0.72rem;
  color: var(--text-muted);
}

/* ==========================================================================
   RESPONSIVE DESIGN
   ========================================================================== */
@media (max-width: 480px) {
  body {
    padding: 10px 6px;
  }
  
  .social-links-grid {
    grid-template-columns: 1fr;
  }
  
  .spotify-card {
    flex-direction: column;
    align-items: flex-start;
  }
  
  .spotify-art-wrap {
    margin: 0 auto 4px;
  }
  
  .spotify-info {
    width: 100%;
  }
}
