/**
 * ASDF Valhalla Theme
 * Nordic-inspired deluxe styling
 *
 * @version 1.0.0
 */

@import url('./design-tokens.css');

/* ============================================
   VALHALLA CSS VARIABLES
   ============================================ */

:root {
  /* Nordic Palette */
  --valhalla-gold: #fbbf24;
  --valhalla-gold-light: #fde68a;
  --valhalla-gold-dark: #d97706;
  --valhalla-cyan: #22d3ee;
  --valhalla-cyan-light: #a5f3fc;
  --valhalla-cyan-dark: #0891b2;
  --valhalla-violet: #a855f7;
  --valhalla-violet-light: #d8b4fe;
  --valhalla-violet-dark: #7c3aed;
  --valhalla-fire: #f97316;
  --valhalla-fire-light: #fed7aa;
  --valhalla-ember: #ef4444;

  /* Metal & Stone - WCAG 2.1 AA compliant */
  --valhalla-steel: #8994a5; /* Lightened for 4.5:1 contrast - was #64748b */
  --valhalla-iron: #475569;
  --valhalla-stone: #374151;
  --valhalla-obsidian: #1e293b;
  --valhalla-void: #0f172a;
  --valhalla-abyss: #020617;

  /* Gradients */
  --valhalla-aurora: linear-gradient(
    135deg,
    var(--valhalla-cyan),
    var(--valhalla-violet),
    var(--valhalla-fire)
  );
  --valhalla-sunset: linear-gradient(135deg, var(--valhalla-gold), var(--valhalla-fire));
  --valhalla-frost: linear-gradient(135deg, var(--valhalla-cyan-light), var(--valhalla-cyan));
  --valhalla-metal: linear-gradient(180deg, var(--valhalla-steel), var(--valhalla-iron));

  /* Shadows */
  --valhalla-glow-gold: 0 0 30px rgba(251, 191, 36, 0.4);
  --valhalla-glow-cyan: 0 0 30px rgba(34, 211, 238, 0.4);
  --valhalla-glow-violet: 0 0 30px rgba(168, 85, 247, 0.4);
  --valhalla-glow-fire: 0 0 30px rgba(249, 115, 22, 0.4);

  /* Rune Border */
  --rune-border-width: 3px;
  --rune-corner-size: 20px;

  /* Timing - using design tokens */
  --valhalla-transition: var(--duration-normal) cubic-bezier(0.4, 0, 0.2, 1);
  --valhalla-bounce: var(--duration-slow) cubic-bezier(0.68, -0.55, 0.265, 1.55);
}

/* ============================================
   NAVIGATION BAR
   ============================================ */

.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: var(--z-sticky);
  padding: var(--space-md) var(--space-lg);
  background: rgba(10, 10, 15, 0.95);
  backdrop-filter: blur(12px);
  border-bottom: 2px solid var(--valhalla-iron);
}

.nav-content {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: var(--space-md);
}

.nav-logo {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  text-decoration: none;
  color: var(--color-text-primary);
}

.nav-logo-text {
  font-size: var(--text-lg);
  font-weight: var(--font-bold);
  background: var(--valhalla-sunset);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.nav-right {
  display: flex;
  align-items: center;
  gap: var(--space-md);
}

/* DEV Mode Button */
.dev-mode-btn {
  padding: var(--space-xs) var(--space-sm);
  font-size: var(--text-xs);
  font-weight: var(--font-bold);
  background: transparent;
  border: 1px solid var(--valhalla-violet);
  color: var(--valhalla-violet);
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: var(--valhalla-transition);
}

.dev-mode-btn:hover {
  background: var(--valhalla-violet);
  color: var(--color-text-inverse);
}

.dev-mode-btn.active {
  background: var(--valhalla-violet);
  color: var(--color-text-inverse);
  box-shadow: var(--valhalla-glow-violet);
}

/* Visitor Badge */
.visitor-badge {
  padding: var(--space-xs) var(--space-sm);
  font-size: var(--text-xs);
  font-weight: var(--font-bold);
  background: var(--valhalla-stone);
  color: var(--valhalla-steel);
  border-radius: var(--radius-sm);
  text-transform: uppercase;
  letter-spacing: var(--tracking-wide);
}

/* Wallet Button */
.wallet-btn {
  padding: var(--space-sm) var(--space-lg);
  font-size: var(--text-sm);
  font-weight: var(--font-semibold);
  background: var(--valhalla-sunset);
  border: none;
  color: var(--color-text-inverse);
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: var(--valhalla-transition);
}

.wallet-btn:hover {
  transform: translateY(-2px);
  box-shadow: var(--valhalla-glow-gold);
}

/* ============================================
   NAVIGATION TABS
   ============================================ */

.nav-tabs {
  display: flex;
  gap: var(--space-xs);
  background: var(--valhalla-obsidian);
  padding: var(--space-xs);
  border-radius: var(--radius-md);
  border: 1px solid var(--valhalla-iron);
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
}

.nav-tab {
  padding: var(--space-sm) var(--space-md);
  font-size: var(--text-xs);
  font-weight: var(--font-semibold);
  color: var(--valhalla-steel);
  background: transparent;
  border: none;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: var(--valhalla-transition);
  white-space: nowrap;
  text-decoration: none;
}

.nav-tab:hover {
  color: var(--valhalla-gold-light);
  background: rgba(251, 191, 36, 0.1);
}

.nav-tab.active {
  background: var(--valhalla-sunset);
  color: var(--color-text-inverse);
  box-shadow: var(--valhalla-glow-gold);
}

/* ============================================
   MAIN CONTENT
   ============================================ */

.main {
  padding-top: 80px; /* Account for fixed nav */
  min-height: 100vh;
  position: relative;
  z-index: 2; /* Above fixed backgrounds */
}

/* ============================================
   NAVIGATION RESPONSIVE
   ============================================ */

@media (max-width: 768px) {
  .nav {
    padding: var(--space-sm) var(--space-md);
  }

  .nav-content {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: var(--space-sm);
  }

  .nav-logo {
    order: 1;
  }

  .nav-tabs {
    order: 3;
    width: 100%;
    justify-content: center;
    flex-wrap: wrap;
    margin-top: var(--space-sm);
  }

  .nav-right {
    order: 2;
  }

  .nav-tab {
    padding: var(--space-xs) var(--space-sm);
    font-size: var(--text-xs);
  }

  .wallet-btn {
    padding: var(--space-sm) var(--space-md);
    font-size: var(--text-xs);
  }

  .main {
    padding-top: 120px; /* More space for wrapped nav */
  }
}

/* ============================================
   RUNE DECORATIONS (SVG Borders)
   ============================================ */

.rune-border {
  position: relative;
}

.rune-border::before,
.rune-border::after {
  content: '';
  position: absolute;
  width: var(--rune-corner-size);
  height: var(--rune-corner-size);
  border: var(--rune-border-width) solid var(--valhalla-gold);
  pointer-events: none;
}

.rune-border::before {
  top: -4px;
  left: -4px;
  border-right: none;
  border-bottom: none;
}

.rune-border::after {
  bottom: -4px;
  right: -4px;
  border-left: none;
  border-top: none;
}

.rune-border-full::before {
  top: -4px;
  right: -4px;
  left: auto;
  border-left: none;
  border-bottom: none;
}

/* Rune corner ornaments */
.rune-ornament {
  position: absolute;
  width: 24px;
  height: 24px;
  opacity: 0.6;
}

.rune-ornament svg {
  width: 100%;
  height: 100%;
  fill: var(--valhalla-gold);
}

.rune-ornament.top-left {
  top: -12px;
  left: -12px;
}
.rune-ornament.top-right {
  top: -12px;
  right: -12px;
  transform: rotate(90deg);
}
.rune-ornament.bottom-left {
  bottom: -12px;
  left: -12px;
  transform: rotate(-90deg);
}
.rune-ornament.bottom-right {
  bottom: -12px;
  right: -12px;
  transform: rotate(180deg);
}

/* ============================================
   HUB CARDS
   ============================================ */

.hub-container {
  display: flex;
  flex-direction: column;
  gap: var(--space-2xl);
  padding: var(--space-2xl) var(--space-lg);
  max-width: 1200px;
  margin: 0 auto;
}

.hub-hero {
  text-align: center;
  padding: var(--space-3xl) var(--space-lg);
}

.hub-title {
  font-size: clamp(2.5rem, 6vw, 4rem);
  font-weight: var(--font-extrabold);
  margin: 0 0 var(--space-md);
  background: var(--valhalla-aurora);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  text-shadow: none;
  animation: aurora-shift 8s ease-in-out infinite;
}

@keyframes aurora-shift {
  0%,
  100% {
    filter: hue-rotate(0deg);
  }
  50% {
    filter: hue-rotate(30deg);
  }
}

.hub-subtitle {
  font-size: var(--text-xl);
  color: var(--valhalla-steel);
  max-width: 600px;
  margin: 0 auto;
}

/* Hub Navigation Cards Grid */
.hub-nav-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: var(--space-lg);
  padding: var(--space-lg);
}

/* Hub Card */
.hub-card {
  position: relative;
  background: var(--valhalla-obsidian);
  border: 2px solid var(--valhalla-iron);
  border-radius: var(--radius-xl);
  padding: var(--space-xl);
  cursor: pointer;
  overflow: hidden;
  transition: var(--valhalla-transition);
  transition-property: transform, box-shadow, border-color;
}

.hub-card::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, transparent 40%, rgba(251, 191, 36, 0.05) 100%);
  opacity: 0;
  transition: opacity var(--valhalla-transition);
}

.hub-card:hover {
  transform: translateY(-8px) scale(1.02);
  border-color: var(--valhalla-gold);
}

.hub-card:hover::before {
  opacity: 1;
}

/* Card variants */
.hub-card.games-card:hover {
  box-shadow: var(--valhalla-glow-fire);
  border-color: var(--valhalla-fire);
}

.hub-card.shop-card:hover {
  box-shadow: var(--valhalla-glow-gold);
  border-color: var(--valhalla-gold);
}

.hub-card.profile-card:hover {
  box-shadow: var(--valhalla-glow-cyan);
  border-color: var(--valhalla-cyan);
}

.hub-card.settings-card:hover {
  box-shadow: var(--valhalla-glow-violet);
  border-color: var(--valhalla-violet);
}

/* Card Icon */
.hub-card-icon {
  width: 80px;
  height: 80px;
  margin-bottom: var(--space-lg);
  font-size: var(--text-4xl);
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--valhalla-stone);
  border-radius: var(--radius-xl);
  transition: var(--valhalla-transition);
}

.hub-card:hover .hub-card-icon {
  transform: scale(1.1) rotate(-5deg);
}

.hub-card.games-card .hub-card-icon {
  background: linear-gradient(135deg, var(--valhalla-fire), var(--valhalla-ember));
}
.hub-card.shop-card .hub-card-icon {
  background: linear-gradient(135deg, var(--valhalla-gold), var(--valhalla-gold-dark));
}
.hub-card.profile-card .hub-card-icon {
  background: linear-gradient(135deg, var(--valhalla-cyan), var(--valhalla-cyan-dark));
}
.hub-card.settings-card .hub-card-icon {
  background: linear-gradient(135deg, var(--valhalla-violet), var(--valhalla-violet-dark));
}

/* Card Content */
.hub-card-title {
  font-size: var(--text-xl);
  font-weight: var(--font-bold);
  margin: 0 0 var(--space-sm);
  color: var(--color-text-inverse);
}

.hub-card-desc {
  font-size: var(--text-sm);
  color: var(--valhalla-steel);
  margin: 0 0 var(--space-md);
  line-height: var(--leading-normal);
}

.hub-card-stats {
  display: flex;
  gap: var(--space-md);
  flex-wrap: wrap;
}

.hub-card-stat {
  display: flex;
  align-items: center;
  gap: var(--space-xs);
  font-size: var(--text-sm);
  color: var(--valhalla-gold);
}

.hub-card-stat-icon {
  font-size: var(--text-base);
}

/* Card Arrow */
.hub-card-arrow {
  position: absolute;
  bottom: var(--space-lg);
  right: var(--space-lg);
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--valhalla-stone);
  border-radius: 50%;
  font-size: var(--text-lg);
  opacity: 0;
  transform: translateX(-10px);
  transition: var(--valhalla-transition);
}

.hub-card:hover .hub-card-arrow {
  opacity: 1;
  transform: translateX(0);
}

/* ============================================
   VALHALLA BUTTONS
   ============================================ */

.btn-valhalla {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-sm);
  padding: var(--space-md) var(--space-xl);
  background: var(--valhalla-sunset);
  border: 2px solid var(--valhalla-gold);
  border-radius: var(--radius-md);
  color: #000;
  font-weight: var(--font-bold);
  font-size: var(--text-base);
  cursor: pointer;
  overflow: hidden;
  transition: var(--valhalla-transition);
}

.btn-valhalla::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
  transform: translateX(-100%);
  transition: transform var(--duration-slow);
}

.btn-valhalla:hover::before {
  transform: translateX(100%);
}

.btn-valhalla:hover {
  transform: translateY(-2px);
  box-shadow: var(--valhalla-glow-gold);
}

.btn-valhalla-secondary {
  background: transparent;
  border: 2px solid var(--valhalla-steel);
  color: var(--color-text-inverse);
}

.btn-valhalla-secondary:hover {
  border-color: var(--valhalla-gold);
  box-shadow: none;
}

.btn-valhalla-icon {
  background: var(--valhalla-stone);
  border: none;
  width: 48px;
  height: 48px;
  border-radius: var(--radius-md);
  color: var(--valhalla-gold);
  font-size: var(--text-lg);
}

.btn-valhalla-icon:hover {
  background: var(--valhalla-iron);
  box-shadow: var(--valhalla-glow-gold);
}

/* ============================================
   VALHALLA SECTIONS
   ============================================ */

.valhalla-section {
  position: relative;
  padding: var(--space-3xl) var(--space-lg);
  background: var(--valhalla-void);
  border-top: 1px solid var(--valhalla-iron);
}

.valhalla-section-header {
  text-align: center;
  margin-bottom: var(--space-2xl);
}

.valhalla-section-title {
  display: inline-flex;
  align-items: center;
  gap: var(--space-md);
  font-size: var(--text-3xl);
  font-weight: var(--font-bold);
  color: var(--color-text-inverse);
  margin: 0 0 var(--space-md);
}

.valhalla-section-title .icon {
  font-size: var(--text-4xl);
}

.valhalla-section-subtitle {
  font-size: var(--text-lg);
  color: var(--valhalla-steel);
  max-width: 600px;
  margin: 0 auto;
}

.valhalla-badge {
  display: inline-flex;
  align-items: center;
  padding: var(--space-xs) var(--space-md);
  background: var(--valhalla-sunset);
  border-radius: var(--radius-full);
  font-size: var(--text-xs);
  font-weight: var(--font-bold);
  text-transform: uppercase;
  letter-spacing: var(--tracking-wide);
  color: #000;
}

/* ============================================
   PROFILE SECTION
   ============================================ */

.profile-container {
  display: grid;
  grid-template-columns: 320px 1fr;
  gap: var(--space-lg);
  max-width: 1200px;
  margin: 0 auto;
}

@media (max-width: 900px) {
  .profile-container {
    grid-template-columns: 1fr;
  }
}

/* Profile Sidebar */
.profile-sidebar {
  display: flex;
  flex-direction: column;
  gap: var(--space-lg);
}

.profile-avatar-card {
  background: var(--valhalla-obsidian);
  border: 2px solid var(--valhalla-iron);
  border-radius: var(--radius-xl);
  padding: var(--space-lg);
  text-align: center;
}

.profile-avatar-preview {
  width: 200px;
  height: 200px;
  margin: 0 auto var(--space-lg);
  background: var(--valhalla-stone);
  border-radius: var(--radius-xl);
  overflow: hidden;
}

.profile-avatar-preview canvas {
  width: 100%;
  height: 100%;
}

.profile-name {
  font-size: var(--text-xl);
  font-weight: var(--font-bold);
  margin: 0 0 var(--space-sm);
  color: var(--color-text-inverse);
}

.profile-wallet {
  font-family: var(--font-mono);
  font-size: var(--text-sm);
  color: var(--valhalla-steel);
  background: var(--valhalla-stone);
  padding: var(--space-sm) var(--space-md);
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: background var(--valhalla-transition);
}

.profile-wallet:hover {
  background: var(--valhalla-iron);
}

.profile-tier-badge {
  display: inline-flex;
  align-items: center;
  gap: var(--space-sm);
  margin-top: var(--space-md);
  padding: var(--space-sm) var(--space-lg);
  background: var(--valhalla-sunset);
  border-radius: var(--radius-md);
  font-weight: var(--font-bold);
  color: #000;
}

/* Profile Stats Card */
.profile-stats-card {
  background: var(--valhalla-obsidian);
  border: 2px solid var(--valhalla-iron);
  border-radius: var(--radius-xl);
  padding: var(--space-lg);
}

.profile-stats-title {
  font-size: var(--text-sm);
  font-weight: var(--font-semibold);
  text-transform: uppercase;
  letter-spacing: var(--tracking-wider);
  color: var(--valhalla-steel);
  margin: 0 0 var(--space-md);
}

.profile-stats-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--space-md);
}

.profile-stat-item {
  text-align: center;
  padding: var(--space-md);
  background: var(--valhalla-stone);
  border-radius: var(--radius-md);
}

.profile-stat-value {
  font-size: var(--text-xl);
  font-weight: var(--font-bold);
  color: var(--valhalla-gold);
  font-variant-numeric: tabular-nums;
}

.profile-stat-label {
  font-size: var(--text-xs);
  color: var(--valhalla-steel);
  margin-top: var(--space-xs);
}

/* Profile Main Content */
.profile-main {
  display: flex;
  flex-direction: column;
  gap: var(--space-lg);
}

.profile-panel {
  background: var(--valhalla-obsidian);
  border: 2px solid var(--valhalla-iron);
  border-radius: var(--radius-xl);
  overflow: hidden;
}

.profile-panel-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: var(--space-lg) var(--space-lg);
  background: var(--valhalla-stone);
  border-bottom: 1px solid var(--valhalla-iron);
}

.profile-panel-title {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  font-size: var(--text-lg);
  font-weight: var(--font-semibold);
  color: var(--color-text-inverse);
  margin: 0;
}

.profile-panel-body {
  padding: var(--space-lg);
}

/* Achievements Grid */
.achievements-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
  gap: var(--space-md);
}

.achievement-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: var(--space-md);
  background: var(--valhalla-stone);
  border-radius: var(--radius-md);
  transition: var(--valhalla-transition);
}

.achievement-item.locked {
  opacity: 0.4;
  filter: grayscale(1);
}

.achievement-item:not(.locked):hover {
  transform: translateY(-4px);
  box-shadow: var(--valhalla-glow-gold);
}

.achievement-icon {
  font-size: var(--text-3xl);
  margin-bottom: var(--space-sm);
}

.achievement-name {
  font-size: var(--text-xs);
  font-weight: var(--font-semibold);
  color: var(--color-text-inverse);
}

/* History Table */
.history-table {
  width: 100%;
  border-collapse: collapse;
}

.history-table th,
.history-table td {
  padding: var(--space-md) var(--space-md);
  text-align: left;
  border-bottom: 1px solid var(--valhalla-iron);
}

.history-table th {
  font-size: var(--text-xs);
  font-weight: var(--font-semibold);
  text-transform: uppercase;
  letter-spacing: var(--tracking-wide);
  color: var(--valhalla-steel);
}

.history-table td {
  font-size: var(--text-sm);
  color: var(--color-text-inverse);
}

.history-table tr:last-child td {
  border-bottom: none;
}

.history-type {
  display: inline-flex;
  align-items: center;
  gap: var(--space-xs);
  padding: var(--space-xs) var(--space-sm);
  border-radius: var(--radius-sm);
  font-size: var(--text-sm);
  font-weight: var(--font-semibold);
}

.history-type.purchase {
  background: var(--valhalla-gold);
  color: #000;
}
.history-type.burn {
  background: var(--valhalla-fire);
  color: #fff;
}
.history-type.earn {
  background: var(--valhalla-cyan);
  color: #000;
}

.history-amount {
  font-family: var(--font-mono);
  font-weight: var(--font-semibold);
}

.history-amount.positive {
  color: var(--valhalla-cyan);
}
.history-amount.negative {
  color: var(--valhalla-fire);
}

/* Profile Currency Card */
.profile-currency-card {
  background: var(--valhalla-obsidian);
  border: 2px solid var(--valhalla-iron);
  border-radius: var(--radius-xl);
  padding: var(--space-lg);
}

.profile-currency-grid {
  display: flex;
  flex-direction: column;
  gap: var(--space-md);
}

.profile-currency-item {
  display: flex;
  align-items: center;
  gap: var(--space-md);
  padding: var(--space-md) var(--space-md);
  background: var(--valhalla-stone);
  border-radius: var(--radius-md);
  transition: var(--valhalla-transition);
}

.profile-currency-item:hover {
  transform: translateX(4px);
  background: var(--valhalla-iron);
}

.profile-currency-item .currency-icon {
  font-size: var(--text-xl);
}

.profile-currency-item .currency-info {
  display: flex;
  flex-direction: column;
}

.profile-currency-item .currency-value {
  font-family: var(--font-mono);
  font-size: var(--text-lg);
  font-weight: var(--font-bold);
  color: var(--valhalla-gold);
}

.profile-currency-item .currency-label {
  font-size: var(--text-xs);
  color: var(--valhalla-steel);
}

/* Profile Inventory */
.profile-inventory-filters {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-sm);
  margin-bottom: var(--space-lg);
}

.inv-filter-btn {
  padding: var(--space-sm) var(--space-md);
  background: var(--valhalla-stone);
  border: 1px solid var(--valhalla-iron);
  border-radius: var(--radius-full);
  color: var(--valhalla-steel);
  font-size: var(--text-sm);
  cursor: pointer;
  transition: var(--valhalla-transition);
}

.inv-filter-btn:hover {
  background: var(--valhalla-iron);
  color: var(--color-text-inverse);
}

.inv-filter-btn.active {
  background: var(--valhalla-gold);
  border-color: var(--valhalla-gold);
  color: #000;
  font-weight: var(--font-semibold);
}

.profile-inventory-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
  gap: var(--space-md);
}

.profile-inventory-item {
  position: relative;
  aspect-ratio: 1;
  background: var(--valhalla-stone);
  border: 2px solid var(--valhalla-iron);
  border-radius: var(--radius-md);
  overflow: hidden;
  cursor: pointer;
  transition: var(--valhalla-transition);
}

.profile-inventory-item:hover {
  transform: translateY(-4px);
  border-color: var(--valhalla-gold);
  box-shadow: var(--valhalla-glow-gold);
}

.profile-inventory-item.equipped {
  border-color: var(--valhalla-cyan);
  box-shadow: 0 0 15px var(--valhalla-cyan-glow);
}

.profile-inventory-item.equipped::after {
  content: '✓';
  position: absolute;
  top: var(--space-xs);
  right: var(--space-xs);
  width: 20px;
  height: 20px;
  background: var(--valhalla-cyan);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: var(--text-xs);
  color: #000;
}

.profile-inventory-item img,
.profile-inventory-item canvas {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.profile-inventory-item .item-placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: var(--text-3xl);
  background: linear-gradient(135deg, var(--valhalla-stone), var(--valhalla-iron));
}

.profile-inventory-item .item-tier-badge {
  position: absolute;
  bottom: var(--space-xs);
  left: var(--space-xs);
  padding: var(--space-2xs) var(--space-xs);
  background: rgba(0, 0, 0, 0.7);
  border-radius: var(--radius-sm);
  font-size: var(--text-xs);
  font-weight: var(--font-semibold);
}

.profile-inventory-empty {
  grid-column: 1 / -1;
  text-align: center;
  padding: var(--space-2xl) var(--space-lg);
  color: var(--valhalla-steel);
}

.profile-inventory-empty .empty-icon {
  font-size: var(--text-4xl);
  margin-bottom: var(--space-md);
}

.profile-inventory-empty .empty-text {
  font-size: var(--text-base);
  margin-bottom: var(--space-md);
}

.btn-sm {
  padding: var(--space-xs) var(--space-md) !important;
  font-size: var(--text-sm) !important;
}

/* ============================================
   SETTINGS SECTION
   ============================================ */

.settings-container {
  max-width: 800px;
  margin: 0 auto;
}

.settings-group {
  background: var(--valhalla-obsidian);
  border: 2px solid var(--valhalla-iron);
  border-radius: var(--radius-xl);
  margin-bottom: var(--space-lg);
  overflow: hidden;
}

.settings-group-header {
  display: flex;
  align-items: center;
  gap: var(--space-md);
  padding: var(--space-lg) var(--space-lg);
  background: var(--valhalla-stone);
  border-bottom: 1px solid var(--valhalla-iron);
}

.settings-group-icon {
  font-size: var(--text-xl);
}

.settings-group-title {
  font-size: var(--text-lg);
  font-weight: var(--font-semibold);
  color: var(--color-text-inverse);
  margin: 0;
}

.settings-group-body {
  padding: var(--space-sm) 0;
}

.settings-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: var(--space-md) var(--space-lg);
  border-bottom: 1px solid var(--valhalla-iron);
}

.settings-item:last-child {
  border-bottom: none;
}

.settings-item-info {
  flex: 1;
}

.settings-item-label {
  font-weight: var(--font-semibold);
  color: var(--color-text-inverse);
  margin-bottom: var(--space-xs);
}

.settings-item-desc {
  font-size: var(--text-sm);
  color: var(--valhalla-steel);
}

/* Toggle Switch */
.toggle-switch {
  position: relative;
  width: 52px;
  height: 28px;
  background: var(--valhalla-stone);
  border-radius: var(--radius-full);
  cursor: pointer;
  transition: background var(--valhalla-transition);
}

.toggle-switch.active {
  background: var(--valhalla-gold);
}

.toggle-switch::after {
  content: '';
  position: absolute;
  top: var(--space-xs);
  left: var(--space-xs);
  width: 20px;
  height: 20px;
  background: var(--color-text-inverse);
  border-radius: 50%;
  transition: transform var(--valhalla-transition);
}

.toggle-switch.active::after {
  transform: translateX(24px);
}

/* Select Dropdown */
.settings-select {
  padding: var(--space-sm) var(--space-md);
  padding-right: var(--space-2xl);
  background: var(--valhalla-stone)
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' fill='%239ca3af' viewBox='0 0 16 16'%3E%3Cpath d='M8 11L3 6h10l-5 5z'/%3E%3C/svg%3E")
    no-repeat right var(--space-md) center;
  border: 1px solid var(--valhalla-iron);
  border-radius: var(--radius-md);
  color: var(--color-text-inverse);
  font-size: var(--text-sm);
  cursor: pointer;
  appearance: none;
}

.settings-select:focus {
  outline: none;
  border-color: var(--valhalla-gold);
}

/* Slider */
.settings-slider {
  width: 120px;
  height: 6px;
  background: var(--valhalla-stone);
  border-radius: var(--radius-xs);
  appearance: none;
  cursor: pointer;
}

.settings-slider::-webkit-slider-thumb {
  appearance: none;
  width: 18px;
  height: 18px;
  background: var(--valhalla-gold);
  border-radius: 50%;
  cursor: pointer;
}

/* ============================================
   VALHALLA PARTICLES (Background)
   ============================================ */

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

.particle-ember {
  position: absolute;
  width: 4px;
  height: 4px;
  background: var(--valhalla-gold);
  border-radius: 50%;
  opacity: 0;
  animation: float-up 8s ease-in-out infinite;
}

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

.particle-mist {
  position: absolute;
  width: 300px;
  height: 300px;
  background: radial-gradient(circle, var(--valhalla-cyan) 0%, transparent 70%);
  opacity: 0.03;
  animation: drift 20s ease-in-out infinite;
}

@keyframes drift {
  0%,
  100% {
    transform: translate(0, 0) scale(1);
  }
  25% {
    transform: translate(50px, -30px) scale(1.1);
  }
  50% {
    transform: translate(-30px, 20px) scale(0.9);
  }
  75% {
    transform: translate(20px, 40px) scale(1.05);
  }
}

/* ============================================
   VALHALLA ANIMATIONS
   ============================================ */

.valhalla-fade-in {
  animation: valhalla-fade-in var(--duration-slow) ease forwards;
}

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

.valhalla-slide-in-left {
  animation: valhalla-slide-in-left var(--duration-slow) ease forwards;
}

@keyframes valhalla-slide-in-left {
  from {
    opacity: 0;
    transform: translateX(-40px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

.valhalla-scale-in {
  animation: valhalla-scale-in var(--duration-normal) var(--valhalla-bounce) forwards;
}

@keyframes valhalla-scale-in {
  from {
    opacity: 0;
    transform: scale(0.8);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

.valhalla-glow-pulse {
  animation: valhalla-glow-pulse 2s ease-in-out infinite;
}

@keyframes valhalla-glow-pulse {
  0%,
  100% {
    box-shadow: 0 0 10px var(--valhalla-gold);
  }
  50% {
    box-shadow:
      0 0 30px var(--valhalla-gold),
      0 0 60px rgba(251, 191, 36, 0.3);
  }
}

/* ============================================
   RESPONSIVE
   ============================================ */

@media (max-width: 768px) {
  .hub-nav-grid {
    grid-template-columns: 1fr;
  }

  .hub-card {
    padding: var(--space-lg);
  }

  .hub-card-icon {
    width: 60px;
    height: 60px;
    font-size: var(--text-3xl);
  }

  .profile-container {
    grid-template-columns: 1fr;
  }

  .profile-stats-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .settings-item {
    flex-direction: column;
    align-items: flex-start;
    gap: var(--space-md);
  }
}
