/* ═══════════════════════════════════════════════════════════
   TNT Studio — Profile V3 Advanced Redesign
   Complete visual overhaul with glassmorphism, animations,
   neon accents, and modern gaming UI patterns.
   ═══════════════════════════════════════════════════════════ */

/* ─── Root Variables ───────────────────────────────────────── */
#view-profile {
  --pv3-accent: #ff6b1a;
  --pv3-accent2: #ffb84d;
  --pv3-purple: #8a63f0;
  --pv3-green: #32cd32;
  --pv3-bg: #04040b;
  --pv3-card: rgba(12, 12, 28, 0.85);
  --pv3-border: rgba(138, 99, 240, 0.12);
  --pv3-glass: rgba(255, 255, 255, 0.03);
  --pv3-text: #e6e6f2;
  --pv3-muted: #8a8ab0;
  --pv3-glow: 0 0 20px rgba(255, 107, 26, 0.15);
  --pv3-radius: 16px;
}

/* ─── Main Container ──────────────────────────────────────── */
#view-profile .pv2 {
  max-width: 960px;
  margin: 0 auto;
  padding: 0 16px 100px;
  position: relative;
}

/* ─── Animated Cover / Banner ─────────────────────────────── */
#view-profile .pv2-cover {
  position: relative;
  height: 180px;
  margin: -16px -16px 0;
  background: linear-gradient(135deg, #0a0a1a 0%, #1a0a2e 25%, #0d1b3e 50%, #1a0520 75%, #0a0a1a 100%);
  background-size: 400% 400%;
  animation: pv3-coverShift 12s ease infinite;
  overflow: hidden;
  border-radius: 0 0 24px 24px;
}

@keyframes pv3-coverShift {
  0% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}

#view-profile .pv2-cover::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 80% 50% at 20% 80%, rgba(255, 107, 26, 0.08) 0%, transparent 50%),
    radial-gradient(ellipse 60% 40% at 80% 20%, rgba(138, 99, 240, 0.06) 0%, transparent 50%);
  pointer-events: none;
}

#view-profile .pv2-cover::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(to bottom, transparent 40%, var(--pv3-bg) 100%);
  pointer-events: none;
}

#view-profile .pv2-cover-glow {
  position: absolute;
  width: 200px;
  height: 200px;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  background: radial-gradient(circle, rgba(255, 107, 26, 0.12) 0%, transparent 60%);
  animation: pv3-pulse 3s ease-in-out infinite;
}

@keyframes pv3-pulse {
  0%, 100% { transform: translate(-50%, -50%) scale(1); opacity: 0.6; }
  50% { transform: translate(-50%, -50%) scale(1.3); opacity: 1; }
}

/* ─── Identity Section ────────────────────────────────────── */
#view-profile .pv2-identity {
  text-align: center;
  margin-top: -52px;
  position: relative;
  z-index: 2;
  padding-bottom: 20px;
}

#view-profile .pv2-avatar-wrap {
  position: relative;
  display: inline-block;
  margin-bottom: 14px;
}

#view-profile .pv2-avatar-btn {
  position: relative;
  display: block;
  width: 108px;
  height: 108px;
  border-radius: 50%;
  border: 3px solid var(--pv3-accent);
  box-shadow: 0 0 24px rgba(255, 107, 26, 0.25), inset 0 0 12px rgba(255, 107, 26, 0.1);
  background: var(--pv3-bg);
  cursor: pointer;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  overflow: hidden;
  padding: 0;
}

#view-profile .pv2-avatar-btn:hover {
  transform: scale(1.05);
  box-shadow: 0 0 32px rgba(255, 107, 26, 0.4), inset 0 0 16px rgba(255, 107, 26, 0.15);
}

#view-profile .pv2-avatar-btn .avatar,
#view-profile .pv2-avatar-btn img {
  width: 100% !important;
  height: 100% !important;
  border-radius: 50%;
  object-fit: cover;
}

#view-profile .pv2-edit-badge {
  position: absolute;
  bottom: 4px;
  right: 4px;
  width: 26px;
  height: 26px;
  background: var(--pv3-accent);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  color: #fff;
  box-shadow: 0 2px 8px rgba(255, 107, 26, 0.4);
  transition: transform 0.2s;
}

#view-profile .pv2-avatar-btn:hover .pv2-edit-badge {
  transform: scale(1.15);
}

#view-profile .pv2-level-badge {
  position: absolute;
  top: -4px;
  right: -8px;
  padding: 3px 10px;
  background: linear-gradient(135deg, var(--pv3-accent), var(--pv3-accent2));
  border-radius: 12px;
  font-family: 'Orbitron', sans-serif;
  font-size: 0.65rem;
  font-weight: 800;
  color: #fff;
  box-shadow: 0 2px 12px rgba(255, 107, 26, 0.4);
  letter-spacing: 0.5px;
}

#view-profile .pv2-status-dot {
  position: absolute;
  bottom: 8px;
  left: 4px;
  width: 14px;
  height: 14px;
  background: var(--pv3-green);
  border: 3px solid var(--pv3-bg);
  border-radius: 50%;
  box-shadow: 0 0 8px rgba(50, 205, 50, 0.5);
}

#view-profile .pv2-name {
  font-family: 'Orbitron', sans-serif;
  font-size: 1.5rem;
  font-weight: 800;
  color: #fff;
  margin: 0 0 4px;
  letter-spacing: 0.5px;
}

#view-profile .pv2-verified {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 22px;
  height: 22px;
  background: linear-gradient(135deg, #3b82f6, #1d4ed8);
  border-radius: 50%;
  font-size: 11px;
  color: #fff;
  margin-left: 6px;
  vertical-align: middle;
  box-shadow: 0 2px 8px rgba(59, 130, 246, 0.3);
}

#view-profile .pv2-vip {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 22px;
  height: 22px;
  background: linear-gradient(135deg, #ffd700, #ff8c00);
  border-radius: 50%;
  font-size: 11px;
  color: #1a1a2e;
  margin-left: 4px;
  vertical-align: middle;
  box-shadow: 0 2px 8px rgba(255, 215, 0, 0.3);
}

#view-profile .pv2-handle {
  font-size: 0.9rem;
  color: var(--pv3-muted);
  margin-bottom: 10px;
}

#view-profile .pv2-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: center;
  margin-bottom: 12px;
}

#view-profile .pv2-pill {
  padding: 4px 12px;
  border-radius: 20px;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.3px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: var(--pv3-glass);
  color: var(--pv3-muted);
  backdrop-filter: blur(8px);
}

#view-profile .pv2-pill-rank {
  background: linear-gradient(135deg, rgba(255, 107, 26, 0.12), rgba(138, 99, 240, 0.08));
  border-color: rgba(255, 107, 26, 0.25);
  color: var(--pv3-accent2);
}

#view-profile .pv2-pill-online {
  border-color: rgba(50, 205, 50, 0.25);
}

#view-profile .pv2-pill-streak {
  background: rgba(255, 107, 26, 0.08);
  border-color: rgba(255, 107, 26, 0.2);
  color: var(--pv3-accent);
}

#view-profile .pv2-onlinedot {
  display: inline-block;
  width: 6px;
  height: 6px;
  background: var(--pv3-green);
  border-radius: 50%;
  margin-right: 4px;
  box-shadow: 0 0 6px rgba(50, 205, 50, 0.5);
  animation: pv3-onlinePulse 2s ease-in-out infinite;
}

@keyframes pv3-onlinePulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.5; }
}

#view-profile .pv2-bio {
  color: var(--pv3-muted);
  font-size: 0.85rem;
  max-width: 500px;
  margin: 8px auto 0;
  line-height: 1.5;
}

/* ─── Mini Meta Ring Section ──────────────────────────────── */
#view-profile .pv2-mini-meta {
  display: flex;
  justify-content: center;
  gap: 32px;
  padding: 20px 0;
  margin-bottom: 4px;
}

#view-profile .pv2-meta-item {
  text-align: center;
}

#view-profile .pv2-meta-ring {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 8px;
  position: relative;
  background: conic-gradient(var(--pv3-accent) calc(var(--pct) * 1%), rgba(255,255,255,0.06) 0);
  font-family: 'Orbitron', sans-serif;
  font-size: 0.7rem;
  font-weight: 700;
  color: var(--pv3-accent2);
}

#view-profile .pv2-meta-ring::before {
  content: '';
  position: absolute;
  inset: 4px;
  background: var(--pv3-bg);
  border-radius: 50%;
}

#view-profile .pv2-meta-ring > span {
  position: relative;
  z-index: 1;
}

#view-profile .pv2-meta-val {
  font-family: 'Orbitron', sans-serif;
  font-size: 1.1rem;
  font-weight: 800;
  color: #fff;
  margin-bottom: 4px;
}

#view-profile .pv2-meta-lbl {
  font-size: 0.7rem;
  color: var(--pv3-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* ─── XP Progress Bar ─────────────────────────────────────── */
#view-profile .pv2-xp {
  background: linear-gradient(145deg, rgba(10,10,20,.97), rgba(15,15,28,.92));
  border: 1px solid rgba(255,107,26,.12);
  border-radius: 16px;
  padding: 20px 24px;
  margin-bottom: 20px;
  backdrop-filter: blur(12px);
  position: relative;
  overflow: hidden;
  box-shadow: 0 4px 24px rgba(0,0,0,.35), inset 0 1px 0 rgba(255,255,255,.03);
}
#view-profile .pv2-xp::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(255,107,26,.35), transparent);
}
#view-profile .pv2-xp::after {
  content: '';
  position: absolute;
  top: 12px; right: 24px;
  font-family: Orbitron, monospace;
  font-size: 8px;
  letter-spacing: .15em;
  color: rgba(255,107,26,.2);
}

#view-profile .pv2-xp-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.8rem;
  margin-bottom: 14px;
}

#view-profile .pv2-xp-row > span:first-child {
  font-family: 'Orbitron', sans-serif;
  font-weight: 800;
  font-size: 12px;
  letter-spacing: .1em;
  color: #c084fc;
  text-shadow: 0 0 14px rgba(192,132,252,.4);
  text-transform: uppercase;
}

#view-profile .pv2-xp-row > span:last-child {
  color: rgba(255,255,255,.6);
  font-family: 'JetBrains Mono', monospace;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .02em;
}

#view-profile .pv2-xp-track {
  height: 10px;
  background: rgba(255, 255, 255, 0.04);
  border-radius: 5px;
  overflow: hidden;
  position: relative;
  border: 1px solid rgba(255,255,255,.06);
  box-shadow: inset 0 2px 4px rgba(0,0,0,.4);
}

#view-profile .pv2-xp-fill {
  height: 100%;
  background: linear-gradient(90deg, #ff6b1a 0%, #ff8c42 40%, #ffaa00 100%);
  border-radius: 5px;
  position: relative;
  box-shadow: 0 0 16px rgba(255,107,26,.45), 0 0 4px rgba(255,140,66,.6);
  transition: width 1.2s cubic-bezier(.4,0,.2,1);
}

#view-profile .pv2-xp-fill::after {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  background: linear-gradient(90deg, transparent 0%, rgba(255,255,255,.35) 50%, transparent 100%);
  animation: pv3-shimmer 2.2s ease-in-out infinite;
}
#view-profile .pv2-xp-fill::before {
  content: '';
  position: absolute;
  right: 0; top: 50%; transform: translateY(-50%);
  width: 4px; height: 4px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 0 8px #ffaa00, 0 0 16px rgba(255,170,0,.6);
  animation: pv3-xp-pulse 1.5s ease-in-out infinite alternate;
}

@keyframes pv3-shimmer {
  0% { transform: translateX(-100%); }
  100% { transform: translateX(100%); }
}
@keyframes pv3-xp-pulse {
  0% { opacity: .6; box-shadow: 0 0 6px #ffaa00; }
  100% { opacity: 1; box-shadow: 0 0 12px #ffaa00, 0 0 24px rgba(255,170,0,.5); }
}

/* ─── Stats Grid ──────────────────────────────────────────── */
#view-profile .pv2-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  margin-bottom: 20px;
}

@media (min-width: 600px) {
  #view-profile .pv2-stats {
    grid-template-columns: repeat(6, 1fr);
  }
}

#view-profile .pv2-stat {
  background: var(--pv3-card);
  border: 1px solid var(--pv3-border);
  border-radius: 14px;
  padding: 16px 12px;
  text-align: center;
  transition: all 0.25s ease;
  position: relative;
  overflow: hidden;
}

#view-profile .pv2-stat::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--pv3-accent), transparent);
  opacity: 0;
  transition: opacity 0.3s;
}

#view-profile .pv2-stat:hover {
  transform: translateY(-3px);
  border-color: rgba(255, 107, 26, 0.3);
  box-shadow: var(--pv3-glow);
}

#view-profile .pv2-stat:hover::before {
  opacity: 1;
}

#view-profile .pv2-si {
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 8px;
  width: 36px;
  height: 36px;
}

#view-profile .pv2-si-svg {
  width: 28px;
  height: 28px;
}

#view-profile .pv2-sv {
  display: block;
  font-family: 'Orbitron', sans-serif;
  font-size: 1rem;
  font-weight: 800;
  color: #fff;
  margin-bottom: 4px;
}

#view-profile .pv2-sl {
  display: block;
  font-size: 0.65rem;
  color: var(--pv3-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* ─── Action Buttons ──────────────────────────────────────── */
#view-profile .pv2-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: center;
  margin-bottom: 24px;
}

#view-profile .pv2-btn {
  padding: 9px 18px;
  border-radius: 10px;
  font-size: 0.8rem;
  font-weight: 700;
  cursor: pointer;
  border: none;
  transition: all 0.2s ease;
  letter-spacing: 0.3px;
}

#view-profile .pv2-btn-primary {
  background: linear-gradient(135deg, var(--pv3-accent), #ff8c42);
  color: #fff;
  box-shadow: 0 4px 16px rgba(255, 107, 26, 0.3);
}

#view-profile .pv2-btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 24px rgba(255, 107, 26, 0.4);
}

#view-profile .pv2-btn-ghost {
  background: var(--pv3-glass);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: var(--pv3-text);
  backdrop-filter: blur(8px);
}

#view-profile .pv2-btn-ghost:hover {
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(255, 255, 255, 0.2);
}

#view-profile .pv2-btn-danger {
  background: rgba(239, 68, 68, 0.1);
  border: 1px solid rgba(239, 68, 68, 0.2);
  color: #ef4444;
}

#view-profile .pv2-btn-danger:hover {
  background: rgba(239, 68, 68, 0.15);
}

/* ─── Sections ────────────────────────────────────────────── */
#view-profile .pv2-section {
  margin-bottom: 24px;
  background: var(--pv3-card);
  border: 1px solid var(--pv3-border);
  border-radius: var(--pv3-radius);
  padding: 20px;
  backdrop-filter: blur(12px);
}

#view-profile .pv2-section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
}

#view-profile .pv2-section-title {
  font-family: 'Rajdhani', sans-serif;
  font-size: 1.05rem;
  font-weight: 700;
  color: #fff;
  margin: 0;
  display: flex;
  align-items: center;
  gap: 8px;
}

#view-profile .pv2-section-sub {
  font-size: 0.75rem;
  color: var(--pv3-muted);
}

#view-profile .pv2-section-cta {
  font-size: 0.75rem;
  color: var(--pv3-accent);
  cursor: pointer;
  font-weight: 600;
  transition: color 0.2s;
}

#view-profile .pv2-section-cta:hover {
  color: var(--pv3-accent2);
}

/* ─── Daily Challenges (in profile) ──────────────────────── */
#view-profile .pv2-challenges {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

#view-profile .pv2-challenge {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 10px;
  transition: all 0.2s;
}

#view-profile .pv2-challenge:hover {
  background: rgba(255, 255, 255, 0.04);
  border-color: rgba(255, 107, 26, 0.15);
}

#view-profile .pv2-challenge--done {
  border-color: rgba(50, 205, 50, 0.2);
  background: rgba(50, 205, 50, 0.03);
}

#view-profile .pv2-ch-icon {
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  background: rgba(255, 107, 26, 0.08);
  font-size: 0.9rem;
  flex-shrink: 0;
}

#view-profile .pv2-challenge--done .pv2-ch-icon {
  background: rgba(50, 205, 50, 0.1);
}

#view-profile .pv2-ch-meta {
  flex: 1;
  min-width: 0;
}

#view-profile .pv2-ch-title {
  font-size: 0.82rem;
  font-weight: 600;
  color: #fff;
  margin-bottom: 5px;
}

#view-profile .pv2-ch-title small {
  color: var(--pv3-muted);
  font-weight: 400;
  margin-left: 6px;
}

#view-profile .pv2-ch-bar {
  height: 4px;
  background: rgba(255, 255, 255, 0.06);
  border-radius: 2px;
  overflow: hidden;
}

#view-profile .pv2-ch-bar > div {
  height: 100%;
  background: linear-gradient(90deg, var(--pv3-accent), var(--pv3-accent2));
  border-radius: 2px;
  transition: width 0.6s ease;
}

#view-profile .pv2-challenge--done .pv2-ch-bar > div {
  background: linear-gradient(90deg, var(--pv3-green), #7fff7f);
}

#view-profile .pv2-ch-reward {
  font-size: 0.72rem;
  color: var(--pv3-accent2);
  font-weight: 700;
  flex-shrink: 0;
  white-space: nowrap;
}

/* ─── Achievements Strip ──────────────────────────────────── */
#view-profile .pv2-ach-strip {
  display: flex;
  gap: 10px;
  overflow-x: auto;
  padding: 4px 0 8px;
  scrollbar-width: thin;
  scrollbar-color: rgba(255,107,26,0.3) transparent;
  -webkit-overflow-scrolling: touch;
}

#view-profile .pv2-ach-strip::-webkit-scrollbar {
  height: 4px;
}

#view-profile .pv2-ach-strip::-webkit-scrollbar-thumb {
  background: rgba(255, 107, 26, 0.3);
  border-radius: 2px;
}

#view-profile .pv2-ach {
  flex-shrink: 0;
  width: 72px;
  text-align: center;
  padding: 10px 6px;
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.05);
  background: rgba(255, 255, 255, 0.02);
  transition: all 0.25s;
  cursor: pointer;
}

#view-profile .pv2-ach:hover {
  transform: translateY(-2px);
  border-color: rgba(255, 107, 26, 0.3);
}

#view-profile .pv2-ach--earned {
  border-color: rgba(255, 215, 0, 0.3);
  background: rgba(255, 215, 0, 0.04);
}

#view-profile .pv2-ach--locked {
  opacity: 0.5;
  filter: grayscale(0.6);
}

#view-profile .pv2-ach--tier-legendary {
  border-color: rgba(255, 215, 0, 0.35);
}

#view-profile .pv2-ach--tier-epic {
  border-color: rgba(168, 85, 247, 0.35);
}

#view-profile .pv2-ach--tier-rare {
  border-color: rgba(59, 130, 246, 0.35);
}

#view-profile .pv2-ach-svgwrap {
  width: 36px;
  height: 36px;
  margin: 0 auto 6px;
}

#view-profile .pv2-ach-title {
  font-size: 0.6rem;
  color: var(--pv3-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* ─── Characters Strip ────────────────────────────────────── */
#view-profile .pv2-chars-strip {
  display: flex;
  gap: 12px;
  overflow-x: auto;
  padding: 4px 0 8px;
  scrollbar-width: thin;
  scrollbar-color: rgba(255,107,26,0.3) transparent;
}

#view-profile .ccd {
  flex-shrink: 0;
  width: 120px;
  border-radius: 12px;
  border: 1px solid var(--pv3-border);
  background: var(--pv3-glass);
  overflow: hidden;
  cursor: pointer;
  transition: all 0.25s;
}

#view-profile .ccd:hover {
  transform: translateY(-3px);
  border-color: var(--pv3-accent);
  box-shadow: var(--pv3-glow);
}

#view-profile .ccd--active {
  border-color: var(--pv3-accent) !important;
  box-shadow: 0 0 16px rgba(255, 107, 26, 0.2);
}

#view-profile .ccd-frame {
  position: relative;
  height: 100px;
  overflow: hidden;
  background: linear-gradient(135deg, rgba(10,10,30,0.8), rgba(20,10,40,0.6));
}

#view-profile .ccd-tier {
  position: absolute;
  top: 6px;
  left: 6px;
  font-size: 0.55rem;
  font-weight: 800;
  letter-spacing: 0.5px;
  padding: 2px 6px;
  border-radius: 4px;
  background: rgba(0,0,0,0.5);
  color: var(--pv3-muted);
}

#view-profile .ccd-active-pip {
  position: absolute;
  top: 6px;
  right: 6px;
  font-size: 0.5rem;
  font-weight: 800;
  color: var(--pv3-green);
}

#view-profile .ccd-art {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
}

#view-profile .ccd-art img {
  width: 80%;
  height: 80%;
  object-fit: contain;
}

#view-profile .ccd-meta {
  padding: 8px 10px;
}

#view-profile .ccd-class {
  font-size: 0.55rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

#view-profile .ccd-name {
  font-size: 0.75rem;
  font-weight: 700;
  color: #fff;
  margin: 2px 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

#view-profile .ccd-sub {
  font-size: 0.6rem;
  color: var(--pv3-muted);
}

/* ─── Detailed Stats ──────────────────────────────────────── */
#view-profile .pv2-detailed-stats {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
}

@media (min-width: 600px) {
  #view-profile .pv2-detailed-stats {
    grid-template-columns: repeat(3, 1fr);
  }
}

#view-profile .pv2-dstat {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid rgba(255, 255, 255, 0.04);
  border-radius: 10px;
  transition: all 0.2s;
}

#view-profile .pv2-dstat:hover {
  background: rgba(255, 255, 255, 0.04);
  border-color: rgba(255, 107, 26, 0.15);
}

#view-profile .pv2-dstat-icon {
  font-size: 1.2rem;
  flex-shrink: 0;
}

#view-profile .pv2-dstat-val {
  font-family: 'Orbitron', sans-serif;
  font-size: 0.95rem;
  font-weight: 800;
  color: #fff;
}

#view-profile .pv2-dstat-lbl {
  font-size: 0.65rem;
  color: var(--pv3-muted);
  text-transform: uppercase;
  letter-spacing: 0.3px;
  margin-top: 2px;
}

/* ─── Activity Timeline ───────────────────────────────────── */
#view-profile .pv2-activity {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

#view-profile .pv2-activity-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 12px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid rgba(255, 255, 255, 0.03);
  transition: background 0.2s;
}

#view-profile .pv2-activity-row:hover {
  background: rgba(255, 255, 255, 0.04);
}

#view-profile .pv2-activity-icon {
  font-size: 1rem;
  width: 28px;
  text-align: center;
  flex-shrink: 0;
}

#view-profile .pv2-activity-title {
  font-size: 0.82rem;
  font-weight: 600;
  color: #fff;
}

#view-profile .pv2-activity-sub {
  font-size: 0.7rem;
  color: var(--pv3-muted);
  margin-top: 2px;
}

#view-profile .pv2-empty-row {
  text-align: center;
  padding: 20px;
  color: var(--pv3-muted);
  font-size: 0.85rem;
}

#view-profile .pv2-empty-icon {
  font-size: 2rem;
  margin-bottom: 8px;
}

#view-profile .pv2-empty-text {
  font-size: 0.82rem;
  color: var(--pv3-muted);
  margin-left: 8px;
}

/* ─── Bottom Cards ────────────────────────────────────────── */
#view-profile .pv2-bottom {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
  margin-bottom: 24px;
}

#view-profile .pv2-card {
  background: var(--pv3-card);
  border: 1px solid var(--pv3-border);
  border-radius: 14px;
  padding: 18px 14px;
  text-align: center;
  cursor: pointer;
  transition: all 0.25s;
}

#view-profile .pv2-card:hover {
  transform: translateY(-2px);
  border-color: rgba(255, 107, 26, 0.3);
  box-shadow: var(--pv3-glow);
}

#view-profile .pv2-ci {
  display: block;
  font-size: 1.4rem;
  margin-bottom: 6px;
}

#view-profile .pv2-cv {
  display: block;
  font-family: 'Orbitron', sans-serif;
  font-size: 1.1rem;
  font-weight: 800;
  color: #fff;
  margin-bottom: 4px;
}

#view-profile .pv2-cl {
  display: block;
  font-size: 0.65rem;
  color: var(--pv3-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* ─── Content Tabs (Posts/Reels/Saved) ────────────────────── */
#view-profile .pv2-content {
  margin-top: 4px;
}

#view-profile .pv2-tabs {
  display: flex;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  margin-bottom: 16px;
}

#view-profile .pv2-tab {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  padding: 12px 8px;
  background: transparent;
  border: none;
  color: var(--pv3-muted);
  cursor: pointer;
  position: relative;
  transition: color 0.2s;
}

#view-profile .pv2-tab::after {
  content: '';
  position: absolute;
  bottom: -1px;
  left: 20%;
  right: 20%;
  height: 2px;
  background: var(--pv3-accent);
  border-radius: 1px;
  opacity: 0;
  transition: opacity 0.2s;
}

#view-profile .pv2-tab--active {
  color: #fff;
}

#view-profile .pv2-tab--active::after {
  opacity: 1;
}

#view-profile .pv2-tab svg {
  width: 20px;
  height: 20px;
}

#view-profile .pv2-tab-label {
  font-size: 0.7rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.3px;
}

#view-profile .pv2-tab-count {
  font-size: 0.6rem;
  font-weight: 700;
  color: var(--pv3-accent);
}

/* ─── Content Grid (Tiles) ────────────────────────────────── */
#view-profile .pv2-content-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 3px;
}

#view-profile .pv2-tile {
  position: relative;
  aspect-ratio: 1;
  background-color: rgba(20, 20, 40, 0.6);
  background-size: cover;
  background-position: center;
  border-radius: 4px;
  overflow: hidden;
  cursor: pointer;
  border: none;
  padding: 0;
  transition: opacity 0.2s;
}

#view-profile .pv2-tile:hover {
  opacity: 0.85;
}

#view-profile .pv2-tile-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  background: rgba(0, 0, 0, 0.6);
  opacity: 0;
  transition: opacity 0.2s;
}

#view-profile .pv2-tile:hover .pv2-tile-overlay {
  opacity: 1;
}

#view-profile .pv2-tile-stat {
  font-size: 0.75rem;
  font-weight: 700;
  color: #fff;
}

#view-profile .pv2-tile-badge {
  position: absolute;
  top: 6px;
  right: 6px;
  font-size: 0.6rem;
  padding: 2px 6px;
  border-radius: 4px;
  background: rgba(0, 0, 0, 0.6);
  color: #fff;
  font-weight: 600;
}

#view-profile .pv2-tile--skel {
  background: linear-gradient(90deg, rgba(30,30,60,0.5) 25%, rgba(50,50,80,0.5) 50%, rgba(30,30,60,0.5) 75%);
  background-size: 200% 100%;
  animation: pv3-skelShimmer 1.5s ease-in-out infinite;
}

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

#view-profile .pv2-tile--text {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 10px;
  background: rgba(20, 20, 50, 0.8) !important;
}

#view-profile .pv2-tile-text {
  font-size: 0.7rem;
  color: var(--pv3-muted);
  line-height: 1.4;
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 4;
  -webkit-box-orient: vertical;
}

#view-profile .pv2-tile-video {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

#view-profile .pv2-load-more {
  grid-column: 1 / -1;
  padding: 14px;
  background: var(--pv3-glass);
  border: 1px solid var(--pv3-border);
  border-radius: 10px;
  color: var(--pv3-accent);
  font-weight: 700;
  font-size: 0.8rem;
  cursor: pointer;
  transition: all 0.2s;
  margin-top: 8px;
}

#view-profile .pv2-load-more:hover {
  background: rgba(255, 107, 26, 0.08);
  border-color: var(--pv3-accent);
}

/* ─── Empty States ────────────────────────────────────────── */
#view-profile .pv2-empty {
  text-align: center;
  padding: 40px 20px;
}

#view-profile .pv2-empty-icon {
  font-size: 2.5rem;
  margin-bottom: 12px;
}

#view-profile .pv2-empty-title {
  font-size: 1rem;
  font-weight: 700;
  color: #fff;
  margin-bottom: 6px;
}

#view-profile .pv2-empty-sub {
  font-size: 0.82rem;
  color: var(--pv3-muted);
  margin-bottom: 16px;
}

#view-profile .pv2-empty-cta {
  padding: 10px 20px;
  background: linear-gradient(135deg, var(--pv3-accent), #ff8c42);
  color: #fff;
  border: none;
  border-radius: 8px;
  font-weight: 700;
  font-size: 0.82rem;
  cursor: pointer;
}

/* ─── Character Section ───────────────────────────────────── */
#view-profile .pv2-charSection {
  position: relative;
  overflow: hidden;
}

#view-profile .pv2-char3d-host {
  min-height: 200px;
  border-radius: 12px;
  background: linear-gradient(180deg, rgba(10,10,30,0.3), rgba(5,5,15,0.6));
  margin-bottom: 12px;
}

#view-profile .pv2-charactions {
  display: flex;
  gap: 10px;
  justify-content: center;
}

/* ─── XP Burst Animation ──────────────────────────────────── */
#view-profile .xp-burst .pv2-xp-fill {
  animation: pv3-xpBurst 1s ease;
}

@keyframes pv3-xpBurst {
  0% { filter: brightness(1); }
  25% { filter: brightness(2); }
  50% { filter: brightness(1.5); box-shadow: 0 0 30px rgba(255, 107, 26, 0.6); }
  100% { filter: brightness(1); }
}

/* ─── Skeleton Loading ────────────────────────────────────── */
#view-profile .skeleton-line {
  height: 16px;
  background: linear-gradient(90deg, rgba(30,30,60,0.5) 25%, rgba(50,50,80,0.5) 50%, rgba(30,30,60,0.5) 75%);
  background-size: 200% 100%;
  animation: pv3-skelShimmer 1.5s ease-in-out infinite;
  border-radius: 4px;
  margin-bottom: 10px;
}

/* ─── Responsive ──────────────────────────────────────────── */
@media (max-width: 480px) {
  #view-profile .pv2-cover {
    height: 140px;
  }
  #view-profile .pv2-name {
    font-size: 1.2rem;
  }
  #view-profile .pv2-mini-meta {
    gap: 20px;
  }
  #view-profile .pv2-stats {
    grid-template-columns: repeat(3, 1fr);
    gap: 6px;
  }
  #view-profile .pv2-stat {
    padding: 12px 8px;
  }
  #view-profile .pv2-sv {
    font-size: 0.85rem;
  }
  #view-profile .pv2-actions {
    gap: 6px;
  }
  #view-profile .pv2-btn {
    padding: 8px 14px;
    font-size: 0.72rem;
  }
}

/* ─── Scrollbar for main view ─────────────────────────────── */
#view-profile {
  scrollbar-width: thin;
  scrollbar-color: rgba(255,107,26,0.2) transparent;
}

#view-profile::-webkit-scrollbar {
  width: 6px;
}

#view-profile::-webkit-scrollbar-thumb {
  background: rgba(255, 107, 26, 0.2);
  border-radius: 3px;
}

#view-profile::-webkit-scrollbar-thumb:hover {
  background: rgba(255, 107, 26, 0.4);
}
