/* Modern CSS Reset & Variable Definitions */
:root {
  --bg-dark: #05060f;
  --bg-card: rgba(13, 17, 34, 0.7);
  --bg-card-hover: rgba(20, 26, 51, 0.85);
  
  --border-glow: rgba(0, 255, 210, 0.2);
  --border-dim: rgba(255, 255, 255, 0.07);
  
  /* Accent Colors */
  --uridium-teal: #00ffca;
  --credits-blue: #00ccff;
  --laser-red: #ff3c60;
  --gold-yellow: #ffd000;
  --rare-purple: #bd5eff;
  --common-gray: #a0aec0;
  
  /* Fonts */
  --font-title: 'Orbitron', 'Inter', sans-serif;
  --font-body: 'Inter', sans-serif;
  --font-mono: 'JetBrains Mono', monospace;
  
  /* Shadow & Glows */
  --glow-teal: 0 0 15px rgba(0, 255, 202, 0.3);
  --glow-blue: 0 0 15px rgba(0, 204, 255, 0.3);
  --glow-red: 0 0 15px rgba(255, 60, 96, 0.3);
  --glow-gold: 0 0 15px rgba(255, 208, 0, 0.35);
  
  --transition-fast: 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-normal: 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}

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

body {
  font-family: var(--font-body);
  background-color: var(--bg-dark);
  color: #e2e8f0;
  min-height: 100vh;
  overflow-x: hidden;
  position: relative;
}

/* Background Atmosphere */
.space-bg {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: -10;
  overflow: hidden;
  pointer-events: none;
}

.stars {
  position: absolute;
  width: 100%;
  height: 100%;
  background-image: 
    radial-gradient(white, rgba(255,255,255,.2) 2px, transparent 40px),
    radial-gradient(white, rgba(255,255,255,.15) 1px, transparent 30px),
    radial-gradient(white, rgba(255,255,255,.1) 2px, transparent 40px);
  background-size: 550px 550px, 350px 350px, 250px 250px;
  background-position: 0 0, 40px 60px, 130px 270px;
  opacity: 0.35;
}

.nebula {
  position: absolute;
  top: -10%;
  left: -20%;
  width: 150%;
  height: 120%;
  background: 
    radial-gradient(circle at 20% 30%, rgba(0, 102, 255, 0.1) 0%, transparent 50%),
    radial-gradient(circle at 80% 70%, rgba(0, 255, 202, 0.08) 0%, transparent 50%),
    radial-gradient(circle at 50% 50%, rgba(189, 94, 255, 0.05) 0%, transparent 60%);
  filter: blur(80px);
  animation: floatNebula 30s infinite alternate linear;
}

.cyber-grid {
  position: absolute;
  width: 100%;
  height: 100%;
  background-image: 
    linear-gradient(to right, rgba(0, 255, 202, 0.015) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(0, 255, 202, 0.015) 1px, transparent 1px);
  background-size: 40px 40px;
}

@keyframes floatNebula {
  0% { transform: scale(1) translate(0, 0); }
  100% { transform: scale(1.1) translate(2%, 3%); }
}

/* App Container and Header */
.app-container {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  max-width: 1800px;
  margin: 0 auto;
  padding: 0 15px;
}

.app-header {
  height: 70px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid var(--border-glow);
  padding: 10px 10px;
  margin-bottom: 20px;
  background: rgba(5, 6, 15, 0.8);
  backdrop-filter: blur(10px);
  position: sticky;
  top: 0;
  z-index: 100;
}

.logo-container {
  display: flex;
  align-items: center;
  gap: 12px;
}

.logo-icon {
  width: 30px;
  height: 30px;
  background: linear-gradient(135deg, var(--uridium-teal), var(--credits-blue));
  border-radius: 6px;
  transform: rotate(45deg);
  box-shadow: var(--glow-teal);
  position: relative;
}

.logo-icon::after {
  content: '';
  position: absolute;
  width: 14px;
  height: 14px;
  background: var(--bg-dark);
  top: 8px;
  left: 8px;
  border-radius: 3px;
}

.logo-container h1 {
  font-family: var(--font-title);
  font-size: 20px;
  font-weight: 900;
  letter-spacing: 2px;
}

.accent-text {
  color: var(--uridium-teal);
  text-shadow: var(--glow-teal);
}

.connection-status {
  display: flex;
  align-items: center;
  gap: 8px;
  background: rgba(255, 255, 255, 0.03);
  padding: 6px 14px;
  border-radius: 20px;
  border: 1px solid var(--border-dim);
}

.status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
}

.status-dot.disconnected {
  background: var(--laser-red);
  box-shadow: var(--glow-red);
}

.status-dot.connected {
  background: var(--uridium-teal);
  box-shadow: var(--glow-teal);
  animation: pulseGreen 1.5s infinite;
}

.status-text {
  font-family: var(--font-title);
  font-size: 11px;
  font-weight: bold;
  letter-spacing: 1px;
}

@keyframes pulseGreen {
  0% { transform: scale(1); opacity: 1; }
  50% { transform: scale(1.2); opacity: 0.6; }
  100% { transform: scale(1); opacity: 1; }
}

/* Layout */
.main-layout {
  display: grid;
  grid-template-columns: 330px 1fr;
  gap: 20px;
  flex: 1;
  align-items: start;
}

/* Cards Design System (Glassmorphism) */
.card {
  background: var(--bg-card);
  backdrop-filter: blur(15px);
  -webkit-backdrop-filter: blur(15px);
  border: 1px solid var(--border-dim);
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
  margin-bottom: 20px;
  transition: border-color var(--transition-normal);
}

.card:hover {
  border-color: rgba(255, 255, 255, 0.15);
}

.card-header {
  padding: 15px 20px;
  background: rgba(255, 255, 255, 0.02);
  border-bottom: 1px solid var(--border-dim);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.card-header h3 {
  font-family: var(--font-title);
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 1px;
  color: #fff;
}

/* Inputs & Form Styling */
.auth-form {
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 15px;
}

.input-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.input-group label {
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: #a0aec0;
}

.input-wrapper {
  position: relative;
  display: flex;
  align-items: center;
}

.input-wrapper input {
  width: 100%;
  background: rgba(0, 0, 0, 0.4);
  border: 1px solid var(--border-dim);
  border-radius: 6px;
  height: 40px;
  padding: 0 12px 0 36px;
  color: #fff;
  font-family: var(--font-mono);
  font-size: 13px;
  transition: all var(--transition-fast);
}

.input-wrapper input:focus {
  outline: none;
  border-color: var(--uridium-teal);
  box-shadow: 0 0 8px rgba(0, 255, 202, 0.2);
}

.input-icon {
  position: absolute;
  left: 10px;
  font-size: 14px;
  pointer-events: none;
}

.toggle-password {
  position: absolute;
  right: 10px;
  background: none;
  border: none;
  color: var(--common-gray);
  cursor: pointer;
  padding: 4px;
}

.toggle-password:hover {
  color: #fff;
}

.helper-text {
  font-size: 10px;
  color: #718096;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 42px;
  padding: 0 20px;
  border-radius: 6px;
  font-family: var(--font-title);
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  transition: all var(--transition-fast);
  border: none;
  width: 100%;
}

.btn-primary {
  background: linear-gradient(135deg, #00e5ba, #0099ff);
  color: #000;
  box-shadow: var(--glow-teal);
  position: relative;
  overflow: hidden;
}

.btn-primary:hover {
  filter: brightness(1.1);
  box-shadow: 0 0 20px rgba(0, 255, 202, 0.5);
  transform: translateY(-1px);
}

.btn-secondary {
  background: rgba(255, 255, 255, 0.05);
  color: #fff;
  border: 1px solid var(--border-dim);
}

.btn-secondary:hover {
  background: rgba(255, 255, 255, 0.12);
  border-color: rgba(255, 255, 255, 0.2);
  transform: translateY(-1px);
}

.button-group {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 5px;
}

.pulse-ring {
  width: 8px;
  height: 8px;
  background: var(--uridium-teal);
  border-radius: 50%;
  box-shadow: var(--glow-teal);
}

/* Security Info Card & Guide Card */
.security-card {
  border-left: 3px solid var(--gold-yellow);
}

.security-title {
  color: var(--gold-yellow) !important;
}

.security-body {
  padding: 15px 20px;
  font-size: 12px;
  line-height: 1.5;
  color: #cbd5e0;
}

.shield-badge {
  display: flex;
  gap: 10px;
  margin-top: 10px;
  background: rgba(255, 208, 0, 0.05);
  border: 1px solid rgba(255, 208, 0, 0.15);
  padding: 10px;
  border-radius: 6px;
}

.shield-icon {
  font-size: 20px;
}

.guide-card {
  padding: 20px;
  font-size: 12px;
}

.guide-card h4 {
  font-family: var(--font-title);
  font-size: 13px;
  margin-bottom: 12px;
  letter-spacing: 0.5px;
}

.steps-list {
  padding-left: 18px;
  color: #a0aec0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.steps-list a {
  color: var(--credits-blue);
  text-decoration: none;
}

.steps-list a:hover {
  text-decoration: underline;
}

kbd {
  background: rgba(255, 255, 255, 0.1);
  padding: 1px 4px;
  border-radius: 3px;
  font-family: var(--font-mono);
  font-size: 11px;
  border: 1px solid rgba(255,255,255,0.15);
}

/* RIGHT SECTION: DASHBOARD */
.dashboard {
  min-height: 500px;
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

/* Dashboard Overlay / Welcomer */
.dashboard-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: radial-gradient(circle at center, rgba(8, 12, 33, 0.9) 0%, rgba(3, 4, 11, 0.98) 100%);
  border: 1px solid var(--border-glow);
  border-radius: 12px;
  z-index: 50;
  display: flex;
  justify-content: center;
  align-items: center;
  text-align: center;
  padding: 40px;
  backdrop-filter: blur(10px);
}

.overlay-content {
  max-width: 450px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
}

.overlay-content h2 {
  font-family: var(--font-title);
  font-size: 18px;
  letter-spacing: 2px;
}

.overlay-content p {
  font-size: 13px;
  color: #a0aec0;
  line-height: 1.6;
}

.btn-pulse {
  width: auto !important;
  animation: pulseButton 2s infinite;
}

@keyframes pulseButton {
  0% { box-shadow: 0 0 0 0 rgba(0, 255, 202, 0.4); }
  70% { box-shadow: 0 0 0 12px rgba(0, 255, 202, 0); }
  100% { box-shadow: 0 0 0 0 rgba(0, 255, 202, 0); }
}

/* Radar Scan Animation Overlay */
.radar-scanner {
  position: relative;
  width: 100px;
  height: 100px;
  border-radius: 50%;
  border: 2px solid rgba(0, 255, 202, 0.2);
  margin-bottom: 10px;
  overflow: hidden;
  background: rgba(0, 255, 202, 0.02);
}

.radar-scanner::before {
  content: '';
  position: absolute;
  width: 100%;
  height: 100%;
  border-radius: 50%;
  background-image: 
    linear-gradient(rgba(0, 255, 202, 0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(0, 255, 202, 0.05) 1px, transparent 1px);
  background-size: 10px 10px;
  background-position: center;
}

.radar-line {
  position: absolute;
  width: 50%;
  height: 50%;
  background: linear-gradient(45deg, rgba(0, 255, 202, 0.4) 0%, transparent 100%);
  top: 0;
  left: 0;
  transform-origin: bottom right;
  border-right: 1px solid rgba(0, 255, 202, 0.8);
  animation: radarScan 4s infinite linear;
}

.radar-crosshair {
  position: absolute;
  width: 100%;
  height: 100%;
  top: 0;
  left: 0;
}

.radar-crosshair::before,
.radar-crosshair::after {
  content: '';
  position: absolute;
  background: rgba(0, 255, 202, 0.3);
}

.radar-crosshair::before {
  width: 100%;
  height: 1px;
  top: 50%;
}

.radar-crosshair::after {
  height: 100%;
  width: 1px;
  left: 50%;
}

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

/* Player Profile Panel */
.player-profile {
  padding: 20px;
}

.profile-header {
  display: flex;
  gap: 20px;
  align-items: center;
  position: relative;
  flex-wrap: wrap;
}

.avatar-container {
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  width: 120px;
  height: 85px;
  background: rgba(0, 0, 0, 0.3);
  border: 1px solid var(--border-glow);
  border-radius: 8px;
}

.company-logo {
  position: absolute;
  top: -8px;
  left: -8px;
  font-family: var(--font-title);
  font-size: 10px;
  font-weight: 900;
  padding: 3px 8px;
  border-radius: 4px;
  color: #000;
}

/* Company Theme Colors */
.company-logo.mmo { background: #ff7700; box-shadow: 0 0 10px rgba(255,119,0,0.5); }
.company-logo.eic { background: #0077ff; box-shadow: 0 0 10px rgba(0,119,255,0.5); }
.company-logo.vru { background: #00ff44; box-shadow: 0 0 10px rgba(0,255,68,0.5); }

.ship-image-container {
  width: 70px;
  height: 70px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.hologram-ship {
  width: 100%;
  height: 100%;
  stroke: var(--uridium-teal);
  stroke-width: 1.5;
  fill: rgba(0, 255, 202, 0.05);
  filter: drop-shadow(0 0 8px rgba(0, 255, 202, 0.6));
  animation: hoverShip 4s infinite ease-in-out;
}

@keyframes hoverShip {
  0% { transform: translateY(0px) rotate(0deg); }
  50% { transform: translateY(-4px) rotate(-1deg); }
  100% { transform: translateY(0px) rotate(0deg); }
}

.profile-details {
  flex: 1;
  min-width: 200px;
}

.profile-name-row {
  display: flex;
  align-items: baseline;
  gap: 10px;
  margin-bottom: 8px;
}

.profile-name-row h2 {
  font-family: var(--font-title);
  font-size: 20px;
  font-weight: 700;
  color: #fff;
}

.user-id {
  font-family: var(--font-mono);
  font-size: 11px;
  color: #718096;
}

.profile-meta {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.meta-tag {
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  padding: 3px 8px;
  border-radius: 4px;
  background: rgba(255,255,255,0.05);
  border: 1px solid var(--border-dim);
}

.ship-name-tag { color: var(--uridium-teal); border-color: rgba(0, 255, 202, 0.2); }
.level-tag { color: var(--gold-yellow); border-color: rgba(255, 208, 0, 0.2); }

/* Currencies */
.currencies {
  display: flex;
  gap: 15px;
  justify-content: flex-end;
}

.currency-item {
  background: rgba(0, 0, 0, 0.4);
  border: 1px solid var(--border-dim);
  padding: 10px 16px;
  border-radius: 6px;
  min-width: 140px;
}

.currency-label {
  display: block;
  font-size: 9px;
  font-weight: 700;
  color: #718096;
  margin-bottom: 4px;
}

.currency-value {
  font-family: var(--font-mono);
  font-size: 16px;
  font-weight: 700;
}

.credits .currency-value { color: var(--credits-blue); text-shadow: 0 0 5px rgba(0, 204, 255, 0.2); }
.uridium .currency-value { color: var(--uridium-teal); text-shadow: 0 0 5px rgba(0, 255, 202, 0.2); }

/* Progress Bars */
.profile-progress-grids {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  margin-top: 15px;
  border-top: 1px solid var(--border-dim);
  padding-top: 15px;
}

.progress-container {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.progress-label-row {
  display: flex;
  justify-content: space-between;
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  color: #a0aec0;
}

.progress-bar {
  height: 6px;
  background: rgba(0, 0, 0, 0.5);
  border-radius: 3px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.03);
}

.progress-fill {
  height: 100%;
  border-radius: 3px;
}

.exp-fill { background: linear-gradient(90deg, #0099ff, #00ccff); box-shadow: 0 0 5px rgba(0, 204, 255, 0.5); }
.hon-fill { background: linear-gradient(90deg, #bd5eff, #da9eff); box-shadow: 0 0 5px rgba(189, 94, 255, 0.5); }

/* WORKSPACE: TABS, FILTERS & GRID */
.workspace {
  background: var(--bg-card);
  border: 1px solid var(--border-dim);
  border-radius: 12px;
  padding: 20px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.tabs-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid var(--border-dim);
  padding-bottom: 12px;
  gap: 20px;
  flex-wrap: wrap;
}

.inventory-tabs {
  display: flex;
  gap: 6px;
  overflow-x: auto;
  padding-bottom: 4px;
}

.tab-btn {
  background: none;
  border: none;
  color: #a0aec0;
  font-family: var(--font-title);
  font-size: 11px;
  font-weight: 700;
  padding: 8px 16px;
  cursor: pointer;
  border-radius: 4px;
  border: 1px solid transparent;
  transition: all var(--transition-fast);
  white-space: nowrap;
}

.tab-btn:hover {
  color: #fff;
  background: rgba(255, 255, 255, 0.02);
}

.tab-btn.active {
  color: var(--uridium-teal);
  background: rgba(0, 255, 202, 0.05);
  border-color: rgba(0, 255, 202, 0.15);
  text-shadow: var(--glow-teal);
}

.filter-controls {
  display: flex;
  gap: 10px;
}

.filter-controls input {
  background: rgba(0,0,0,0.3);
  border: 1px solid var(--border-dim);
  border-radius: 6px;
  padding: 0 12px;
  height: 34px;
  color: #fff;
  font-size: 12px;
  width: 220px;
  outline: none;
  transition: all var(--transition-fast);
}

.filter-controls input:focus {
  border-color: var(--uridium-teal);
}

.filter-controls select {
  background: rgba(0,0,0,0.3);
  border: 1px solid var(--border-dim);
  border-radius: 6px;
  padding: 0 10px;
  height: 34px;
  color: #fff;
  font-size: 12px;
  outline: none;
  cursor: pointer;
  transition: all var(--transition-fast);
}

.filter-controls select:focus {
  border-color: var(--uridium-teal);
}

/* Stats Banner */
.inventory-stats {
  display: flex;
  justify-content: space-between;
  font-size: 11px;
  color: #718096;
  background: rgba(0,0,0,0.15);
  padding: 8px 15px;
  border-radius: 6px;
  border: 1px solid rgba(255,255,255,0.02);
}

.inventory-stats strong {
  color: #fff;
}

/* Item Grid */
.inventory-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
  gap: 12px;
  max-height: 600px;
  overflow-y: auto;
  padding-right: 5px;
}

/* Scrollbar styling for grid */
.inventory-grid::-webkit-scrollbar,
.steps-list::-webkit-scrollbar {
  width: 6px;
}

.inventory-grid::-webkit-scrollbar-track {
  background: rgba(0, 0, 0, 0.2);
  border-radius: 3px;
}

.inventory-grid::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.1);
  border-radius: 3px;
}

.inventory-grid::-webkit-scrollbar-thumb:hover {
  background: rgba(255, 255, 255, 0.2);
}

/* Item Card */
.item-card {
  background: rgba(10, 12, 28, 0.5);
  border: 1px solid var(--border-dim);
  border-radius: 8px;
  padding: 10px;
  display: flex;
  flex-direction: column;
  align-items: center;
  position: relative;
  cursor: pointer;
  transition: all var(--transition-fast);
  height: 145px;
}

.item-card:hover {
  background: rgba(20, 25, 51, 0.7);
  transform: translateY(-2px);
  box-shadow: 0 4px 15px rgba(0,0,0,0.4);
}

/* Rarity classes for Item borders and glows */
.item-card.common { border-bottom: 2px solid var(--common-gray); }
.item-card.rare { border-bottom: 2px solid var(--credits-blue); }
.item-card.elite { border-bottom: 2px solid var(--rare-purple); }
.item-card.legendary { border-bottom: 2px solid var(--gold-yellow); }

.item-card.common:hover { border-color: var(--common-gray); }
.item-card.rare:hover { border-color: var(--credits-blue); box-shadow: 0 0 10px rgba(0, 204, 255, 0.15); }
.item-card.elite:hover { border-color: var(--rare-purple); box-shadow: 0 0 10px rgba(189, 94, 255, 0.15); }
.item-card.legendary:hover { border-color: var(--gold-yellow); box-shadow: 0 0 10px rgba(255, 208, 0, 0.25); }

/* Item Card Contents */
.item-icon-container {
  width: 50px;
  height: 50px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 8px;
  position: relative;
}

.item-icon-svg {
  width: 100%;
  height: 100%;
}

.item-quantity {
  position: absolute;
  top: 4px;
  right: 4px;
  background: rgba(0, 0, 0, 0.75);
  border: 1px solid var(--border-dim);
  border-radius: 4px;
  padding: 2px 5px;
  font-family: var(--font-mono);
  font-size: 9px;
  font-weight: 700;
  color: #fff;
}

.item-name {
  font-family: var(--font-title);
  font-size: 10px;
  font-weight: 700;
  text-align: center;
  margin-bottom: 4px;
  color: #e2e8f0;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  height: 28px;
  line-height: 1.4;
}

.item-level {
  font-family: var(--font-mono);
  font-size: 9px;
  font-weight: 500;
  color: var(--gold-yellow);
  margin-top: auto;
}

.item-equipped-badge {
  position: absolute;
  bottom: 4px;
  left: 4px;
  background: rgba(0, 255, 202, 0.15);
  border: 1px solid var(--uridium-teal);
  color: var(--uridium-teal);
  font-size: 7px;
  font-weight: 900;
  padding: 1px 4px;
  border-radius: 3px;
  text-transform: uppercase;
}

/* Modal / Backdrop styling */
.modal-backdrop {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(3, 4, 11, 0.85);
  backdrop-filter: blur(8px);
  z-index: 1000;
  display: flex;
  justify-content: center;
  align-items: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity var(--transition-fast) ease;
}

.modal-backdrop.show {
  opacity: 1;
  pointer-events: auto;
}

.modal-card {
  background: rgba(13, 17, 34, 0.95);
  border: 1px solid var(--border-glow);
  box-shadow: 0 0 30px rgba(0, 255, 202, 0.2);
  border-radius: 12px;
  width: 480px;
  max-width: 90%;
  position: relative;
  transform: translateY(-20px);
  transition: transform var(--transition-normal);
  overflow: hidden;
}

.modal-backdrop.show .modal-card {
  transform: translateY(0);
}

.close-modal {
  position: absolute;
  top: 15px;
  right: 15px;
  background: none;
  border: none;
  font-size: 28px;
  color: var(--common-gray);
  cursor: pointer;
  line-height: 1;
}

.close-modal:hover {
  color: #fff;
}

.modal-header {
  padding: 25px 25px 15px;
  display: flex;
  align-items: center;
  gap: 15px;
  border-bottom: 1px solid var(--border-dim);
}

.item-visual-large {
  width: 64px;
  height: 64px;
  background: rgba(0,0,0,0.3);
  border-radius: 8px;
  border: 1px solid var(--border-dim);
  display: flex;
  align-items: center;
  justify-content: center;
}

#modalItemName {
  font-family: var(--font-title);
  font-size: 16px;
  color: #fff;
  margin-bottom: 4px;
}

.rarity-badge {
  display: inline-block;
  font-size: 8px;
  font-weight: 900;
  padding: 2px 6px;
  border-radius: 3px;
  text-transform: uppercase;
}

.rarity-badge.common { background: rgba(160, 174, 192, 0.15); color: var(--common-gray); border: 1px solid var(--common-gray); }
.rarity-badge.rare { background: rgba(0, 204, 255, 0.15); color: var(--credits-blue); border: 1px solid var(--credits-blue); }
.rarity-badge.elite { background: rgba(189, 94, 255, 0.15); color: var(--rare-purple); border: 1px solid var(--rare-purple); }
.rarity-badge.legendary { background: rgba(255, 208, 0, 0.15); color: var(--gold-yellow); border: 1px solid var(--gold-yellow); }

.modal-body {
  padding: 20px 25px 25px;
}

.stats-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 15px;
}

.stat-row {
  display: flex;
  justify-content: space-between;
  font-family: var(--font-mono);
  font-size: 12px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.03);
  padding-bottom: 4px;
}

.stat-name {
  color: #a0aec0;
}

.stat-value {
  color: #fff;
  font-weight: bold;
}

.item-description {
  font-size: 12px;
  line-height: 1.6;
  color: #cbd5e0;
}

/* Footer styling */
.app-footer {
  text-align: center;
  padding: 20px 0;
  border-top: 1px solid var(--border-dim);
  margin-top: 40px;
}

.app-footer p {
  font-size: 11px;
  color: #4a5568;
}

/* Animations */
.btn-loader {
  display: none;
  width: 16px;
  height: 16px;
  border: 2px solid rgba(0,0,0,0.3);
  border-radius: 50%;
  border-top-color: #000;
  animation: spinLoader 0.8s infinite linear;
  position: absolute;
}

@keyframes spinLoader {
  to { transform: rotate(360deg); }
}

.loading-active .btn-loader {
  display: inline-block;
}

.loading-active .btn-text {
  visibility: hidden;
}

/* Responsive adjustments */
@media(max-width: 900px) {
  .main-layout {
    grid-template-columns: 1fr;
  }
  
  .currencies {
    width: 100%;
    justify-content: flex-start;
    margin-top: 15px;
  }
}

/* Share Button Styles */
.btn-share {
  font-family: var(--font-title);
  font-size: 10px;
  font-weight: 700;
  color: var(--uridium-teal);
  background: rgba(0, 255, 202, 0.05);
  border: 1px solid rgba(0, 255, 202, 0.25);
  padding: 4px 10px;
  border-radius: 4px;
  cursor: pointer;
  transition: all var(--transition-fast);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-left: auto;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  box-shadow: 0 0 5px rgba(0, 255, 202, 0.05);
}

.btn-share:hover {
  background: rgba(0, 255, 202, 0.15);
  border-color: var(--uridium-teal);
  box-shadow: var(--glow-teal);
  transform: translateY(-1px);
}

#shareUrlInput {
  color: var(--uridium-teal);
  font-weight: 500;
  text-overflow: ellipsis;
}

/* Empty grid message */
.empty-grid-msg {
  grid-column: 1 / -1;
  text-align: center;
  padding: 40px;
  color: #718096;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 15px;
}

.empty-icon {
  font-size: 36px;
  opacity: 0.5;
}
