/* Modern Dark Theme with Blue Gradients */
:root {
  /* Neutral Zinc Palette */
  --bg-primary: #09090b;
  --bg-secondary: #18181b;
  --bg-tertiary: #0a0a0a;
  --bg-modal: #000000;
  --bg-card: rgba(24, 24, 27, 0.6);

  /* Brand Colors (keep blue for primary actions/links) */
  --accent-primary: #3b82f6;
  --accent-secondary: #2563eb;
  --accent-hover: #60a5fa;
  --accent-active: #1d4ed8;

  /* Neutral Text Colors */
  --text-primary: #f4f4f5;
  --text-secondary: #a1a1aa;
  --text-muted: #71717a;

  /* Neutral Borders */
  --border-color: #27272a;
  --border-accent: #3f3f46;

  /* Status Colors */
  --success: #22c55e;
  --warning: #eab308;
  --danger: #ef4444;

  /* Gradients */
  --gradient-primary: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%);
  --gradient-secondary: linear-gradient(135deg, #1e3a8a 0%, #1e40af 100%);

  /* Neutral Card Gradient */
  --gradient-card: linear-gradient(135deg, rgba(255, 255, 255, 0.03) 0%, rgba(255, 255, 255, 0.01) 100%);

  /* Viewport scrollbar (Firefox + Chrome) */
  scrollbar-width: thin;
  scrollbar-color: var(--accent-primary) var(--bg-secondary);
}

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

/* Global Scrollbar */
::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}

::-webkit-scrollbar-track {
  background: var(--bg-secondary);
}

::-webkit-scrollbar-thumb {
  background: var(--accent-primary);
  border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
  background: var(--accent-hover);
}

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Noto Sans', Helvetica, Arial, sans-serif;
  background: linear-gradient(135deg, var(--bg-tertiary) 0%, var(--bg-modal) 100%);
  color: var(--text-primary);
  line-height: 1.6;
  min-height: 100vh;
}

.container {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* Navbar */
.navbar {
  background: rgba(9, 9, 11, 0.8);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  padding: 1rem 2rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  /* This aligns the brand and links vertically  */
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2);
  position: sticky;
  top: 0;
  z-index: 100;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

/* NEW: Add this to align the icon and text together */
.nav-brand {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

/* NEW: Add this to control the icon size relative to the text */
.bot-icon {
  height: 4rem;
  /* Matches the font-size of your h1  */
  width: auto;
  display: block;
  border-radius: 50%;
}

.nav-brand h1 {
  font-size: 1.5rem;
  /* Your existing size  */
  font-weight: 600;
  color: var(--text-primary);
  margin: 0;
  /* Remove default margins to prevent vertical offset */
  line-height: 1;
  /* Keeps the text box tight to the letters for better centering */
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.user-info {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.4rem 1rem;
  background: var(--bg-card);
  border-radius: 8px;
  border: 1px solid var(--border-accent);
}

.user-avatar {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: 2px solid var(--accent-primary);
  box-shadow: 0 0 12px rgba(59, 130, 246, 0.3);
}

/* Buttons */
.btn {
  padding: 0.5rem 1.5rem;
  border-radius: 6px;
  border: none;
  font-size: 0.9rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
}

.btn-primary {
  background: var(--gradient-primary);
  color: white;
  box-shadow: 0 2px 8px rgba(59, 130, 246, 0.3);
}

.btn-primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(59, 130, 246, 0.4);
}

.btn-secondary {
  background-color: var(--bg-card);
  color: var(--text-primary);
  border: 1px solid var(--border-accent);
}

.btn-secondary:hover {
  background-color: var(--bg-tertiary);
  border-color: var(--accent-primary);
}

.btn-discord {
  background: var(--gradient-primary);
  color: white;
  box-shadow: 0 4px 12px rgba(59, 130, 246, 0.3);
}

.btn-discord:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(59, 130, 246, 0.5);
}

.btn-large {
  padding: 0.75rem 2rem;
  font-size: 1.1rem;
}

/* Hero Section */
.hero {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 4rem 2rem;
  background: radial-gradient(ellipse at top, rgba(59, 130, 246, 0.15) 0%, rgba(59, 130, 246, 0.08) 12%, rgba(59, 130, 246, 0.04) 25%, rgba(59, 130, 246, 0.01) 37%, rgba(59, 130, 246, 0) 50%),
    linear-gradient(135deg, var(--bg-tertiary) 0%, var(--bg-modal) 100%);
}

.hero-content {
  text-align: center;
  max-width: 600px;
}

.hero-title {
  font-size: 3rem;
  margin-bottom: 1rem;
  background: linear-gradient(135deg, var(--text-primary) 0%, var(--accent-hover) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  font-weight: 700;
}

.hero-subtitle {
  font-size: 1.25rem;
  color: var(--text-secondary);
  margin-bottom: 2rem;
}

/* Dashboard */
.dashboard-content {
  flex: 1;
  padding: 2rem;
  max-width: 1400px;
  margin: 0 auto;
  width: 100%;
  position: relative;
}

.dashboard-content::before {
  content: '';
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: var(--bg-modal);
  z-index: -1;
  pointer-events: none;
}

/* Glow blob — uses filter:blur so it's perfectly smooth in every browser.
   The ellipse is centered at the viewport top edge (top:-50%, height:100%)
   so only the bottom half of the blurred ellipse is visible — this creates
   the same natural "radial ellipse at top" shape as the old gradient, but
   without any banding. */
.dashboard-content::after {
  content: '';
  position: fixed;
  top: -65%;
  left: 50%;
  transform: translateX(-50%);
  width: 100%;
  height: 100%;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.08);
  filter: blur(80px);
  z-index: -1;
  pointer-events: none;
}

.dashboard-header {
  margin-bottom: 2rem;
}

.dashboard-header h1 {
  font-size: 2rem;
  margin-bottom: 0.5rem;
}

.subtitle {
  color: var(--text-secondary);
  font-size: 1.1rem;
}

/* Stats Grid */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 1rem;
  margin-bottom: 2.5rem;
}

.stat-card {
  background: var(--bg-card);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  padding: 1rem 1.5rem;
  border-radius: 12px;
  text-align: center;
  border: 1px solid rgba(255, 255, 255, 0.1);
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
}

.stat-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: var(--gradient-primary);
  opacity: 0;
  transition: opacity 0.3s ease;
}

.stat-card:hover {
  border-color: var(--border-accent);
  transform: translateY(-2px);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.2);
  background: rgba(255, 255, 255, 0.05);
}

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

.stat-value {
  font-size: 2rem;
  font-weight: 700;
  background: var(--gradient-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: 0.25rem;
}

.stat-label {
  color: var(--text-primary);
  font-size: 0.875rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 0.25rem;
}

.stat-hint {
  font-size: 0.75rem;
  color: var(--text-muted);
  margin-top: 0.25rem;
  text-transform: none;
  letter-spacing: normal;
}

/* Servers Section */
.servers-section {
  margin-bottom: 3rem;
}

.servers-section h2 {
  font-size: 1.5rem;
  margin-bottom: 1.5rem;
  color: var(--text-primary);
}

.count {
  color: var(--text-muted);
  font-size: 1rem;
  font-weight: 400;
}

.servers-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
  gap: 1.5rem;
}

.server-card {
  background: var(--bg-card);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 12px;
  padding: 1.25rem;
  display: flex;
  align-items: center;
  gap: 1rem;
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
}

.server-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 4px;
  height: 100%;
  background: var(--gradient-primary);
  opacity: 0;
  transition: opacity 0.3s ease;
}

.server-card:hover {
  border-color: var(--border-accent);
  transform: translateY(-2px);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.2);
  background: rgba(255, 255, 255, 0.05);
}

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

.server-icon {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  overflow: hidden;
  flex-shrink: 0;
}

.server-icon img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.server-icon-placeholder {
  width: 100%;
  height: 100%;
  background: var(--gradient-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 1.5rem;
  color: white;
  box-shadow: 0 4px 12px rgba(192, 213, 246, 0.3);
}

.server-info {
  flex: 1;
}

.server-info h3 {
  font-size: 1.1rem;
  margin-bottom: 0.5rem;
}

.server-badges {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.badge {
  padding: 0.25rem 0.75rem;
  border-radius: 6px;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.badge-owner {
  background: linear-gradient(135deg, #d29922 0%, #f59e0b 100%);
  color: white;
  box-shadow: 0 2px 8px rgba(245, 158, 11, 0.3);
}

.badge-admin {
  background: linear-gradient(135deg, #f85149 0%, #ef4444 100%);
  color: white;
  box-shadow: 0 2px 8px rgba(248, 81, 73, 0.3);
}

.badge-manage {
  background: linear-gradient(135deg, #3fb950 0%, #22c55e 100%);
  color: white;
  box-shadow: 0 2px 8px rgba(63, 185, 80, 0.3);
}

.badge-staff {
  background: linear-gradient(135deg, #8b5cf6 0%, #a78bfa 100%);
  color: white;
  box-shadow: 0 2px 8px rgba(139, 92, 246, 0.3);
}

.badge-bot {
  background: var(--gradient-primary);
  color: white;
  box-shadow: 0 2px 8px rgba(59, 130, 246, 0.3);
}

.info-text {
  color: var(--text-secondary);
  margin-bottom: 1.5rem;
  font-size: 0.95rem;
}

/* No Servers */
.no-servers {
  text-align: center;
  padding: 3rem 2rem;
  color: var(--text-secondary);
  background: var(--bg-card);
  border-radius: 12px;
  border: 1px solid var(--border-accent);
}

.no-servers p {
  margin-bottom: 0.5rem;
}

.hint {
  font-size: 0.9rem;
  color: var(--text-muted);
}

.server-actions {
  flex-shrink: 0;
}

/* Server List */
.servers-list {
  background-color: var(--bg-secondary);
  border-radius: 8px;
  border: 2px solid var(--border-color);
  overflow: hidden;
}

.server-list-item {
  display: flex;
  align-items: center;
  padding: 1rem 1.5rem;
  gap: 1rem;
  border-bottom: 1px solid var(--border-color);
  transition: background-color 0.2s ease;
}

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

.server-list-item:hover {
  background-color: var(--bg-tertiary);
}

.server-icon-small {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  overflow: hidden;
  flex-shrink: 0;
}

.server-icon-small img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.server-icon-placeholder-small {
  width: 100%;
  height: 100%;
  background: var(--gradient-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 600;
  font-size: 1rem;
  color: white;
  box-shadow: 0 2px 8px rgba(225, 232, 243, 0.3);
}

.server-list-info {
  flex: 1;
}

.server-list-name {
  font-weight: 600;
  margin-bottom: 0.25rem;
}

.server-list-id {
  font-size: 0.85rem;
  color: var(--text-muted);
  font-family: 'Courier New', monospace;
}

.server-list-badges {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.badge-small {
  padding: 0.2rem 0.6rem;
  border-radius: 10px;
  font-size: 0.7rem;
  font-weight: 600;
  text-transform: uppercase;
}

.badge-manage {
  background-color: var(--accent-primary);
  color: white;
}

/* No Servers */
.no-servers {
  text-align: center;
  padding: 3rem 2rem;
  color: var(--text-secondary);
  background: var(--bg-card);
  border-radius: 12px;
  border: 1px solid var(--border-accent);
}

.no-servers p {
  margin-bottom: 0.5rem;
}

.hint {
  font-size: 0.9rem;
  color: var(--text-muted);
}

/* Footer */
.footer {
  background: rgba(9, 9, 11, 0.8);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  padding: 2rem;
  text-align: center;
  color: var(--text-muted);
  margin-top: auto;
  border-top: 1px solid var(--border-accent);
}

/* Server Stats Page */
.server-header {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  margin-bottom: 2.5rem;
  padding: 1.5rem;
  background: var(--bg-card);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
}

.server-header-icon {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  overflow: hidden;
  flex-shrink: 0;
  box-shadow: 0 4px 12px rgba(199, 215, 240, 0.3);
}

.server-header-icon img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.server-icon-placeholder-large {
  width: 100%;
  height: 100%;
  background: var(--gradient-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 2rem;
  color: white;
}

.server-header-info h1 {
  font-size: 2rem;
  margin-bottom: 0.25rem;
}

.server-nav-buttons {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
  margin-top: 0.75rem;
}

.no-stats-card {
  background: var(--bg-card);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 12px;
  padding: 3rem 2rem;
  text-align: center;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
}

.no-stats-card h2 {
  margin-bottom: 1rem;
  color: var(--text-primary);
}

.no-stats-card p {
  color: var(--text-secondary);
}

/* Progress Card */
.progress-card {
  background: var(--bg-card);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 12px;
  padding: 1.5rem;
  margin-bottom: 2.5rem;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
}

.progress-card-header {
  margin-bottom: 1rem;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.progress-card-header h3 {
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--text-primary);
  margin: 0;
}

.progress-bar-container {
  width: 100%;
  height: 40px;
  background: rgba(15, 20, 25, 0.8);
  border-radius: 20px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.1);
  position: relative;
  box-shadow: inset 0 4px 16px rgba(0, 0, 0, 0.3);
  margin-bottom: 0.75rem;
}

.progress-bar {
  height: 100%;
  background: var(--gradient-primary);
  transition: width 0.5s ease;
  box-shadow: 0 0 20px rgba(59, 130, 246, 0.5);
}

.progress-info {
  display: flex;
  justify-content: space-between;
  color: var(--text-secondary);
  font-size: 0.9rem;
}

/* Currency Section Card */
.currency-section-card {
  background: var(--bg-card);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 12px;
  padding: 1.5rem;
  margin-bottom: 2.5rem;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
}

.currency-card-header {
  margin-bottom: 1.5rem;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.currency-card-header h3 {
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--text-primary);
  margin: 0;
}

.transfer-section {
  padding-top: 1rem;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
}

/* Level Section Card */
.level-section-card {
  background: var(--bg-card);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 12px;
  padding: 1.5rem;
  margin-bottom: 2.5rem;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
}

.level-card-header {
  margin-bottom: 1.5rem;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.level-card-header h3 {
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--text-primary);
  margin: 0;
}

.progress-section-inner {
  padding-top: 1rem;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
}

/* Bio Card */
.bio-card {
  background: var(--bg-card);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 12px;
  padding: 1.5rem;
  margin-bottom: 2.5rem;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
}

.bio-card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1rem;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.bio-card-header h3 {
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--text-primary);
  margin: 0;
}

.bio-card-content {
  color: var(--text-secondary);
  line-height: 1.6;
}

/* Profile Section Card */
.profile-section-card {
  background: var(--bg-card);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 12px;
  padding: 1.5rem;
  margin-bottom: 2.5rem;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
}

.profile-card-header {
  margin-bottom: 1.5rem;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.profile-card-header h3 {
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--text-primary);
  margin: 0;
}

.profile-bio-section {
  margin-bottom: 1.5rem;
  padding-bottom: 1.5rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.profile-subsection-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1rem;
}

.profile-subsection-header h4 {
  font-size: 1rem;
  font-weight: 600;
  color: var(--text-primary);
  margin: 0;
}

.profile-stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 1rem;
}

.profile-section-card .compact-card-header h4 {
  font-size: 1rem;
  font-weight: 600;
  color: var(--text-primary);
  margin: 0;
}

/* Items Grid */
.items-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 1.5rem;
  margin-bottom: 2.5rem;
}

.items-section h2 {
  margin-bottom: 1rem;
  font-size: 1.5rem;
}

.items-card {
  background: rgba(26, 31, 46, 0.6);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 12px;
  padding: 1.5rem;
  min-height: 200px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
}

.no-items {
  color: var(--text-muted);
  text-align: center;
  padding: 2rem;
}

.item-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.75rem;
  border-bottom: 1px solid var(--border-color);
}

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

.item-name {
  color: var(--text-primary);
  font-size: 0.95rem;
}

.item-count {
  color: var(--text-muted);
  font-weight: 600;
}

.augment-row {
  flex-direction: column;
  align-items: flex-start;
  gap: 0.5rem;
}

.augment-bonus {
  font-size: 0.85rem;
  font-weight: 600;
  padding: 0.25rem 0.75rem;
  border-radius: 6px;
}

.augment-bonus.atk {
  background: linear-gradient(135deg, #f85149 0%, #ef4444 100%);
  color: white;
}

.augment-bonus.def {
  background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%);
  color: white;
}

/* Saves Section */
.saves-section {
  margin-bottom: 2.5rem;
}

.saves-section h2 {
  margin-bottom: 1rem;
  font-size: 1.5rem;
}

.saves-card {
  background: rgba(26, 31, 46, 0.6);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 12px;
  padding: 2rem;
  text-align: center;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
}

.saves-value {
  font-size: 3rem;
  font-weight: 700;
  background: var(--gradient-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: 0.5rem;
}

.saves-text {
  color: var(--text-secondary);
  font-size: 1rem;
}

/* Coming Soon Card */
.coming-soon-card {
  background: rgba(26, 31, 46, 0.6);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 12px;
  padding: 3rem 2rem;
  text-align: center;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
}

.coming-soon-card h2 {
  margin-bottom: 1.5rem;
  font-size: 2rem;
}

.coming-soon-card p {
  color: var(--text-secondary);
  margin-bottom: 1rem;
}

.coming-soon-card ul {
  list-style: none;
  padding: 0;
  margin: 1.5rem 0;
  color: var(--text-primary);
}

.coming-soon-card li {
  padding: 0.5rem 0;
}

.coming-soon-card li:before {
  content: "✓ ";
  color: var(--accent-primary);
  font-weight: bold;
  margin-right: 0.5rem;
}

/* Discord Custom Emojis */
.discord-emoji {
  width: 1.375em;
  height: 1.375em;
  vertical-align: -0.4em;
  display: inline-block;
  margin: 0 0.05em 0 0.1em;
  object-fit: contain;
}

/* Larger emojis for specific contexts */
.item-name .discord-emoji,
.stat-label .discord-emoji {
  width: 1.5em;
  height: 1.5em;
}

.stat-value .discord-emoji {
  width: 1.25em;
  height: 1.25em;
  vertical-align: -0.35em;
  margin-right: 0.15em;
}

.saves-value .discord-emoji {
  width: 2em;
  height: 2em;
}

/* Compact Cards for Items/Augments/Saves */
.compact-card {
  text-align: left;
  min-height: 220px;
  display: flex;
  flex-direction: column;
}

.compact-card-header {
  margin-bottom: 1rem;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.compact-card-header h3 {
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--text-primary);
  margin: 0;
}

.compact-card-content {
  flex: 1;
  overflow-y: auto;
  max-height: 180px;
  padding-right: 12px;
  padding-left: 12px;
  scrollbar-width: thin;
  scrollbar-color: var(--accent-primary) rgba(0, 0, 0, 0.3);
}

.compact-card-content::-webkit-scrollbar {
  width: 6px;
}

.compact-card-content::-webkit-scrollbar-track {
  background: rgba(0, 0, 0, 0.3);
  border-radius: 3px;
}

.compact-card-content::-webkit-scrollbar-thumb {
  background: var(--accent-primary);
  border-radius: 3px;
}

.compact-item-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.5rem 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  font-size: 0.9rem;
}

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

.compact-item-name {
  color: var(--text-primary);
  font-size: 0.85rem;
  display: flex;
  align-items: center;
  gap: 0.25rem;
}

.compact-item-count {
  color: var(--text-muted);
  font-weight: 600;
  font-size: 0.8rem;
}

.compact-item-more {
  text-align: center;
  padding: 0.5rem;
  color: var(--text-muted);
  font-size: 0.85rem;
  font-style: italic;
}

.no-items-compact {
  text-align: center;
  color: var(--text-muted);
  padding: 2rem 1rem;
  font-size: 0.9rem;
}

.augment-bonus-compact {
  font-size: 0.75rem;
  font-weight: 600;
  padding: 0.2rem 0.5rem;
  border-radius: 4px;
}

.augment-bonus-compact.atk {
  background: linear-gradient(135deg, #f85149 0%, #ef4444 100%);
  color: white;
}

.augment-bonus-compact.def {
  background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%);
  color: white;
}

.saves-compact {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 2rem 1rem;
}

.compact-saves-value {
  font-size: 2.5rem;
  font-weight: 700;
  background: var(--gradient-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: 0.5rem;
}

.compact-saves-text {
  color: var(--text-secondary);
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* ========================================
   EMBED BUILDER STYLES
   ======================================== */

/* Loader Card */
.embed-loader-card {
  background: var(--bg-card);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 12px;
  padding: 1.5rem;
  margin-bottom: 1.5rem;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
}

.loader-header h3 {
  font-size: 1.1rem;
  margin-bottom: 1rem;
  color: var(--text-primary);
}

.loader-content {
  display: flex;
  gap: 1rem;
  align-items: center;
}

.loader-content .embed-input {
  flex: 1;
}

.loader-hint {
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-top: 0.75rem;
}

/* Error & Status Messages */
.error-message {
  background: rgba(248, 81, 73, 0.1);
  border: 1px solid rgba(248, 81, 73, 0.3);
  color: var(--danger);
  padding: 0.75rem 1rem;
  border-radius: 8px;
  margin-top: 1rem;
  font-size: 0.9rem;
}

.status-message {
  padding: 1rem 1.5rem;
  border-radius: 8px;
  margin-top: 1.5rem;
  text-align: center;
  font-weight: 500;
}

.status-message.success {
  background: rgba(63, 185, 80, 0.1);
  border: 1px solid rgba(63, 185, 80, 0.3);
  color: var(--success);
}

.status-message.error {
  background: rgba(248, 81, 73, 0.1);
  border: 1px solid rgba(248, 81, 73, 0.3);
  color: var(--danger);
}

/* Builder Container Layout */
.embed-builder-container {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5rem;
  margin-bottom: 1.5rem;
}

/* Editor Panel */
.embed-editor-panel {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.editor-section {
  background: var(--bg-card);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 12px;
  padding: 1.5rem;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
}

.editor-section h3 {
  font-size: 1.1rem;
  margin-bottom: 1.25rem;
  color: var(--text-primary);
  padding-bottom: 0.75rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.section-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1.25rem;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.section-header h3 {
  margin: 0;
  padding: 0;
  border: none;
}

/* Form Elements */
.form-group {
  margin-bottom: 1rem;
}

.form-group label {
  display: block;
  font-size: 0.85rem;
  color: var(--text-secondary);
  margin-bottom: 0.5rem;
  font-weight: 500;
}

.form-row {
  display: flex;
  gap: 1rem;
}

.form-row .form-group {
  flex: 1;
}

.embed-input,
.embed-textarea,
.embed-select {
  width: 100%;
  background: rgba(0, 0, 0, 0.5);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  padding: 0.75rem 1rem;
  color: var(--text-primary);
  font-size: 0.95rem;
  font-family: inherit;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.embed-input:focus,
.embed-textarea:focus,
.embed-select:focus {
  outline: none;
  border-color: var(--accent-primary);
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.2);
}

.embed-input::placeholder,
.embed-textarea::placeholder {
  color: var(--text-muted);
}

.embed-textarea {
  resize: vertical;
  min-height: 80px;
}

.embed-select {
  cursor: pointer;
}

.embed-select option {
  background: var(--bg-secondary);
  color: var(--text-primary);
}

/* Custom Dropdown */
.custom-select-wrapper {
  position: relative;
  user-select: none;
  width: 100%;
  max-width: 400px;
  /* Limit width to match reasonable input sizes */
}

.custom-select {
  position: relative;
  display: flex;
  flex-direction: column;
}

.custom-select-trigger {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.75rem 1rem;
  font-size: 0.95rem;
  font-weight: 400;
  color: var(--text-primary);
  background: rgba(0, 0, 0, 0.5);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.2s;
}

.custom-select-trigger:hover {
  border-color: rgba(255, 255, 255, 0.2);
}

.custom-options {
  position: absolute;
  display: block;
  bottom: 100%;
  /* Drop UP instead of down */
  left: 0;
  right: 0;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-bottom: 0;
  /* Remove bottom border since it's on top now */
  background: var(--bg-secondary);
  transition: all 0.2s;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  z-index: 100;
  margin-bottom: 8px;
  /* Margin from bottom instead of top */
  border-radius: 8px;
  max-height: 200px;
  overflow-y: auto;
  box-shadow: 0 -4px 12px rgba(0, 0, 0, 0.5);
  /* Shadow upwards */
  scrollbar-width: thin;
  scrollbar-color: var(--accent-primary) rgba(0, 0, 0, 0.3);
}

/* Drop-down variant (opens below the trigger, for inline form contexts) */
.custom-select-wrapper.drop-down .custom-options {
  bottom: auto;
  top: 100%;
  border-top: 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  margin-bottom: 0;
  margin-top: 8px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.5);
}

.custom-select.open .custom-options {
  opacity: 1;
  visibility: visible;
  pointer-events: all;
}

.custom-option {
  position: relative;
  display: block;
  padding: 0.75rem 1rem;
  font-size: 0.95rem;
  font-weight: 400;
  color: var(--text-secondary);
  cursor: pointer;
  transition: all 0.2s;
}

.custom-option:hover {
  background: rgba(255, 255, 255, 0.05);
  color: var(--text-primary);
}

.custom-option.selected {
  color: var(--text-primary);
  background: rgba(255, 255, 255, 0.05);
}

.arrow {
  position: relative;
  height: 8px;
  width: 8px;
}

.arrow::before,
.arrow::after {
  content: "";
  position: absolute;
  bottom: 0px;
  width: 0.1rem;
  height: 100%;
  transition: all 0.2s;
}

.arrow::before {
  left: -3px;
  transform: rotate(-45deg);
  background-color: var(--text-secondary);
}

.arrow::after {
  left: 3px;
  transform: rotate(45deg);
  background-color: var(--text-secondary);
}

.custom-select.open .arrow::before {
  left: -3px;
  transform: rotate(45deg);
}

.custom-select.open .arrow::after {
  left: 3px;
  transform: rotate(-45deg);
}

/* Custom Scrollbar for Dropdown */
.custom-options::-webkit-scrollbar {
  width: 6px;
}

.custom-options::-webkit-scrollbar-track {
  background: rgba(0, 0, 0, 0.3);
  border-radius: 3px;
}

.custom-options::-webkit-scrollbar-thumb {
  background: var(--accent-primary);
  border-radius: 3px;
}

.embed-select option {
  background: var(--bg-secondary);
  color: var(--text-primary);
}

/* Color Picker */
.color-picker-wrapper {
  display: flex;
  gap: 0.75rem;
  align-items: center;
}

.color-picker-wrapper input[type="color"] {
  width: 50px;
  height: 42px;
  padding: 0;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  background: none;
}

.color-picker-wrapper input[type="color"]::-webkit-color-swatch-wrapper {
  padding: 2px;
}

.color-picker-wrapper input[type="color"]::-webkit-color-swatch {
  border-radius: 6px;
  border: 2px solid rgba(255, 255, 255, 0.2);
}

.color-text {
  width: 120px !important;
  flex: none;
  font-family: 'Courier New', monospace;
}

/* Checkbox */
.checkbox-group {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.checkbox-group input[type="checkbox"] {
  width: 18px;
  height: 18px;
  accent-color: var(--accent-primary);
  cursor: pointer;
}

.checkbox-group label {
  margin: 0;
  cursor: pointer;
  color: var(--text-primary);
}

/* Fields */
.field-entry {
  background: rgba(0, 0, 0, 0.4);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 8px;
  padding: 1rem;
  margin-bottom: 1rem;
}

.field-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1rem;
  padding-bottom: 0.5rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  font-weight: 500;
  color: var(--text-secondary);
}

/* Preview Panel */
.embed-preview-panel {
  background: var(--bg-card);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 12px;
  padding: 1.5rem;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
  position: sticky;
  top: 100px;
  max-height: calc(100vh - 140px);
  overflow-y: auto;
}

.embed-preview-panel h3 {
  font-size: 1.1rem;
  margin-bottom: 1.25rem;
  color: var(--text-primary);
  padding-bottom: 0.75rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

/* Discord Embed Preview */
.discord-embed-preview {
  background: #2f3136;
  border-left: 4px solid var(--accent-primary);
  border-radius: 4px;
  padding: 1rem;
  display: flex;
  gap: 1rem;
  max-width: 520px;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

.embed-preview-content {
  flex: 1;
  min-width: 0;
}

/* Author */
.embed-author {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.5rem;
}

.embed-author .author-icon {
  width: 24px;
  height: 24px;
  border-radius: 50%;
}

.embed-author span {
  font-size: 0.85rem;
  font-weight: 600;
  color: #ffffff;
}

/* Title */
.embed-title {
  font-weight: 600;
  font-size: 1rem;
  color: #ffffff;
  margin-bottom: 0.5rem;
}

.embed-title.has-link {
  color: #00b0f4;
}

.embed-title a {
  color: #00b0f4;
  text-decoration: none;
}

.embed-title a:hover {
  text-decoration: underline;
}

/* Description */
.embed-description {
  font-size: 0.875rem;
  color: #dcddde;
  line-height: 1.5;
  margin-bottom: 0.75rem;
  word-wrap: break-word;
}

.embed-description code {
  background: #202225;
  padding: 0.2em 0.4em;
  border-radius: 3px;
  font-size: 0.85em;
}

/* Fields */
.embed-fields {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 0.75rem;
}

.preview-field {
  flex: 0 0 100%;
}

.preview-field.inline {
  flex: 0 0 calc(33.33% - 0.5rem);
}

.preview-field .field-name {
  font-size: 0.85rem;
  font-weight: 600;
  color: #ffffff;
  margin-bottom: 0.25rem;
}

.preview-field .field-value {
  font-size: 0.875rem;
  color: #dcddde;
  line-height: 1.4;
}

/* Images */
.embed-thumbnail {
  width: 80px;
  height: 80px;
  border-radius: 4px;
  object-fit: cover;
  flex-shrink: 0;
}

.embed-image {
  max-width: 100%;
  max-height: 300px;
  border-radius: 4px;
  margin-top: 0.75rem;
}

/* Footer */
.embed-footer {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.75rem;
  color: #72767d;
  margin-top: 0.75rem;
}

.embed-footer .footer-icon {
  width: 20px;
  height: 20px;
  border-radius: 50%;
}

/* Action Bar */
.embed-action-bar {
  background: var(--bg-card);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 12px;
  padding: 1.5rem;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1.5rem;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
}

.action-section {
  display: flex;
  align-items: center;
  gap: 1rem;
  flex: 1;
  min-width: 250px;
}

.action-section-header {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex: 1;
}

.action-icon {
  font-size: 1.5rem;
}

.action-info {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
}

.action-info strong {
  color: var(--text-primary);
  font-size: 0.95rem;
}

.action-hint {
  font-size: 0.8rem;
  color: var(--text-muted);
}

.action-divider {
  display: flex;
  align-items: center;
  padding: 0 0.5rem;
}

.action-divider span {
  background: rgba(255, 255, 255, 0.1);
  padding: 0.25rem 0.75rem;
  border-radius: 4px;
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.action-clear {
  margin-left: auto;
}

.channel-selector {
  display: flex;
  align-items: center;
  gap: 1rem;
  flex: 1;
}

.channel-selector label {
  font-weight: 500;
  color: var(--text-primary);
  white-space: nowrap;
}

.channel-selector .embed-select {
  max-width: 250px;
  flex: 1;
}

/* Button Variants */
.btn-small {
  padding: 0.4rem 1rem;
  font-size: 0.85rem;
}

.btn-danger {
  background: linear-gradient(135deg, #f85149 0%, #da3633 100%);
  color: white;
  border: none;
}

.btn-danger:hover {
  background: linear-gradient(135deg, #ff6b63 0%, #f85149 100%);
}

/* Config Cards Grid */
.config-cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 1.5rem;
}

.config-card {
  background: var(--bg-card);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 12px;
  padding: 1.5rem;
  display: flex;
  gap: 1.25rem;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
  transition: all 0.3s ease;
}

.config-card:hover {
  border-color: rgba(var(--accent-primary-rgb, 88, 101, 242), 0.5);
  transform: translateY(-2px);
  box-shadow: 0 12px 40px rgba(var(--accent-primary-rgb, 88, 101, 242), 0.2);
  background: rgba(var(--accent-primary-rgb, 88, 101, 242), 0.1);
}

.config-card-icon {
  font-size: 2.5rem;
  flex-shrink: 0;
}

.config-card-content {
  display: flex;
  flex-direction: column;
  flex: 1;
}

.config-card-content .btn {
  margin-top: auto;
  align-self: flex-start;
}

.config-card-content h3 {
  font-size: 1.2rem;
  margin-bottom: 0.5rem;
  color: var(--text-primary);
}

.config-card-content p {
  color: var(--text-secondary);
  font-size: 0.9rem;
  margin-bottom: 1rem;
  line-height: 1.5;
}

.config-card-coming-soon {
  opacity: 0.6;
}

.config-card-coming-soon .config-card-content p {
  margin-bottom: 0;
}

.coming-soon-badge {
  display: inline-block;
  margin-top: 0.75rem;
  padding: 0.35rem 0.75rem;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 6px;
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* ==================== */
/* Shop Modal Styles    */
/* ==================== */

.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.8);
  backdrop-filter: blur(4px);
  display: none;
  justify-content: center;
  align-items: center;
  z-index: 1000;
}

.modal-overlay.active {
  display: flex;
}

.shop-modal {
  background: var(--bg-secondary);
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  width: 90%;
  max-width: 800px;
  max-height: 80vh;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.shop-modal-header {
  padding: 1.5rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.shop-modal-header h2 {
  margin: 0;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.shop-modal-close {
  background: none;
  border: none;
  color: var(--text-secondary);
  font-size: 1.5rem;
  cursor: pointer;
  padding: 0.5rem;
  transition: color 0.2s;
}

.shop-modal-close:hover {
  color: var(--text-primary);
}

.shop-tabs {
  display: flex;
  gap: 0.5rem;
  padding: 1rem 1.5rem 0;
}

.shop-tab {
  padding: 0.6rem 1.2rem;
  border: none;
  background: rgba(255, 255, 255, 0.05);
  color: var(--text-secondary);
  border-radius: 8px 8px 0 0;
  cursor: pointer;
  transition: all 0.2s;
}

.shop-tab:hover {
  background: rgba(255, 255, 255, 0.1);
}

.shop-tab.active {
  background: var(--accent-primary);
  color: white;
}

.shop-modal-body {
  padding: 1.5rem;
  overflow-y: auto;
  flex: 1;
  scrollbar-width: thin;
  scrollbar-color: var(--accent-primary) rgba(0, 0, 0, 0.3);
}

.shop-modal-body::-webkit-scrollbar {
  width: 6px;
}

.shop-modal-body::-webkit-scrollbar-track {
  background: rgba(0, 0, 0, 0.3);
  border-radius: 3px;
}

.shop-modal-body::-webkit-scrollbar-thumb {
  background: var(--accent-primary);
  border-radius: 3px;
}

body.modal-open {
  overflow: hidden;
}

.shop-items-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1rem;
}

.shop-item-card {
  background: var(--bg-card);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 12px;
  padding: 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  transition: all 0.2s;
  position: relative;
  overflow: hidden;
}

.shop-item-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: var(--gradient-primary);
  opacity: 0;
  transition: opacity 0.3s ease;
}

.shop-item-card:hover {
  border-color: var(--border-accent);
  transform: translateY(-2px);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.2);
  background: rgba(255, 255, 255, 0.05);
}

.shop-item-card:hover::before {
  opacity: 1;
}

.shop-item-header {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.shop-item-icon {
  font-size: 1.5rem;
}

.shop-item-icon .discord-emoji {
  width: 28px;
  height: 28px;
}

.shop-item-name {
  font-weight: 600;
  color: var(--text-primary);
}

.shop-item-details {
  font-size: 0.85rem;
  color: var(--text-secondary);
}

.shop-item-type {
  text-transform: capitalize;
  opacity: 0.7;
}

.shop-item-bonus {
  color: var(--accent-primary);
  font-weight: 500;
}

.shop-item-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: auto;
  padding-top: 0.5rem;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
}

.shop-item-price {
  display: flex;
  align-items: center;
  gap: 0.3rem;
  font-weight: 600;
  color: var(--text-primary);
}

.shop-item-price .discord-emoji {
  width: 18px;
  height: 18px;
}

.shop-buy-btn {
  padding: 0.5rem 1rem;
  border: none;
  border-radius: 6px;
  background: var(--gradient-primary);
  color: white;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s;
}

.shop-buy-btn:hover:not(:disabled) {
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(var(--accent-primary-rgb, 88, 101, 242), 0.4);
}

.shop-buy-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.shop-buy-btn.discord-only {
  background: var(--bg-tertiary);
  font-size: 0.75rem;
}

.shop-empty,
.shop-loading {
  text-align: center;
  padding: 3rem;
  color: var(--text-secondary);
}

.shop-currency-display {
  padding: 0.5rem 1rem;
  background: rgba(255, 255, 255, 0.05);
  border-radius: 8px;
  font-size: 0.9rem;
}

.toast {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  padding: 1rem 1.5rem;
  border-radius: 8px;
  color: white;
  font-weight: 500;
  z-index: 2000;
  animation: slideIn 0.3s ease;
}

.toast.success {
  background: #22c55e;
}

.toast.error {
  background: #ef4444;
}

@keyframes slideIn {
  from {
    transform: translateX(100%);
    opacity: 0;
  }

  to {
    transform: translateX(0);
    opacity: 1;
  }
}

/* ── Shared Data Tables ─────────────────────────────── */
.lr-table,
.role-table,
.cd-table,
.shop-table,
.tk-table {
  width: 100%;
  border-collapse: collapse;
  margin-bottom: 1rem;
}

.lr-table th,
.role-table th,
.cd-table th,
.shop-table th,
.tk-table th {
  text-align: left;
  padding: 0 0.75rem 0.5rem;
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.lr-table td,
.role-table td,
.cd-table td,
.shop-table td,
.tk-table td {
  padding: 0.55rem 0.75rem;
  font-size: 0.875rem;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
  vertical-align: middle;
}

.lr-table tr:first-child td,
.role-table tr:first-child td,
.cd-table tr:first-child td,
.shop-table tr:first-child td,
.tk-table tr:first-child td {
  border-top: none;
}

/* Compact variant for dense config tables */
.cd-table td {
  padding: 0.45rem 0.75rem;
}

/* Table scroll wrapper */
.table-scroll {
  overflow-x: auto;
  scrollbar-width: thin;
  scrollbar-color: var(--accent-primary) transparent;
}

/* ── Loading Spinner ───────────────────────────────── */
.spinner {
  display: inline-block;
  width: 20px;
  height: 20px;
  border: 2px solid rgba(255, 255, 255, 0.15);
  border-top-color: var(--accent-primary);
  border-radius: 50%;
  animation: spin 0.6s linear infinite;
}

.spinner-lg {
  width: 32px;
  height: 32px;
  border-width: 3px;
}

.loading-state {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 2rem;
  color: var(--text-secondary);
  font-size: 0.875rem;
}

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

/* Responsive */

@media (max-width: 768px) {
  .navbar {
    flex-direction: row;
    flex-wrap: wrap;
    padding: 0.5rem 1rem;
    gap: 0.5rem;
    transition: transform 0.3s ease;
  }

  .navbar.header-hidden {
    transform: translateY(-100%);
  }

  .nav-brand h1 {
    display: none;
  }

  .nav-links {
    flex-direction: row;
    flex-wrap: wrap;
    gap: 0.4rem;
    width: auto;
    margin-left: auto;
  }

  .nav-links .btn {
    font-size: 0.78rem;
    padding: 0.35rem 0.7rem;
  }

  .user-info span {
    display: none;
  }

  .hero-title {
    font-size: 2rem;
  }

  .servers-grid {
    grid-template-columns: 1fr;
  }

  .server-card {
    flex-direction: column;
    text-align: center;
  }

  .dashboard-content {
    padding: 1rem;
  }

  /* Make body content not jump when header hides */
  .dashboard-wrapper {
    padding-top: 0;
  }

  /* Embed Builder Responsive */
  .embed-builder-container {
    grid-template-columns: 1fr;
  }

  .embed-preview-panel {
    position: static;
    max-height: none;
  }

  .loader-content {
    flex-direction: column;
  }

  .embed-action-bar {
    flex-direction: column;
    align-items: stretch;
  }

  .channel-selector {
    flex-direction: column;
    align-items: stretch;
  }

  .channel-selector .embed-select {
    max-width: none;
  }

  .action-buttons {
    justify-content: stretch;
  }

  .action-buttons .btn {
    flex: 1;
    justify-content: center;
  }

  /* Config Cards Responsive */
  .config-cards-grid {
    grid-template-columns: 1fr;
  }

  .config-card {
    flex-direction: column;
    text-align: center;
  }

  .config-card-content .btn {
    align-self: center;
  }

  /* ── Module pages: mobile improvements ────────────── */

  /* Make all data tables horizontally scrollable */
  .lr-table,
  .role-table,
  .cd-table,
  .shop-table,
  .tk-table {
    display: block;
    overflow-x: auto;
    scrollbar-width: thin;
  }

  /* Stack form grids to single column */
  .msg-form-grid,
  .msg-form-grid-2col {
    grid-template-columns: 1fr !important;
  }

  /* Stack action bars vertically */
  .msg-action-bar {
    flex-direction: column;
    align-items: stretch;
  }

  .msg-action-bar .btn-primary,
  .msg-action-bar .btn-secondary {
    width: 100%;
    justify-content: center;
  }

  /* Reduce card padding on mobile */
  .msg-card {
    padding: 1rem;
  }

  /* Tab bar: horizontal scroll instead of wrap */
  .msg-tab-bar {
    flex-wrap: nowrap;
    overflow-x: auto;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
  }

  .msg-tab-bar::-webkit-scrollbar {
    display: none;
  }

  .msg-tab {
    white-space: nowrap;
    flex-shrink: 0;
  }

  /* Server header buttons stack */
  .server-nav-buttons {
    flex-wrap: wrap;
    gap: 0.5rem;
  }
}

/* ── Leaderboard Modal ── */
.leaderboard-modal {
  background: var(--bg-secondary);
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  width: 90%;
  max-width: 540px;
  max-height: 80vh;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.leaderboard-modal-header {
  padding: 1.25rem 1.5rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.leaderboard-modal-header h2 {
  margin: 0;
  font-size: 1.15rem;
}

.leaderboard-tabs {
  display: flex;
  gap: 0.5rem;
  padding: 0.75rem 1.5rem 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.07);
}

.leaderboard-tab {
  padding: 0.5rem 1.1rem;
  border: none;
  background: rgba(255, 255, 255, 0.05);
  color: var(--text-secondary);
  border-radius: 8px 8px 0 0;
  cursor: pointer;
  font-size: 0.9rem;
  font-weight: 500;
  transition: all 0.2s;
}

.leaderboard-tab:hover {
  background: rgba(255, 255, 255, 0.1);
  color: var(--text-primary);
}

.leaderboard-tab.active {
  background: var(--accent-primary);
  color: white;
}

.leaderboard-modal-body {
  padding: 1rem 1.25rem;
  overflow-y: auto;
  flex: 1;
  scrollbar-width: thin;
  scrollbar-color: var(--accent-primary) rgba(0, 0, 0, 0.3);
}

.leaderboard-modal-body::-webkit-scrollbar {
  width: 6px;
}

.leaderboard-modal-body::-webkit-scrollbar-track {
  background: rgba(0, 0, 0, 0.3);
  border-radius: 3px;
}

.leaderboard-modal-body::-webkit-scrollbar-thumb {
  background: var(--accent-primary);
  border-radius: 3px;
}

.lb-row {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  padding: 0.65rem 0.75rem;
  border-radius: 8px;
  transition: background 0.15s;
}

.lb-row:hover {
  background: rgba(255, 255, 255, 0.05);
}

.lb-row.lb-top {
  background: rgba(255, 255, 255, 0.03);
}

.lb-rank {
  width: 2.2rem;
  text-align: center;
  font-weight: 700;
  font-size: 1.05rem;
  flex-shrink: 0;
  color: var(--text-secondary);
}

.lb-row.lb-top .lb-rank {
  font-size: 1.3rem;
}

.lb-avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  flex-shrink: 0;
  object-fit: cover;
}

.lb-name {
  flex: 1;
  font-weight: 500;
  color: var(--text-primary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  font-size: 0.95rem;
}

.lb-value {
  font-weight: 600;
  color: var(--accent-primary);
  flex-shrink: 0;
  font-size: 0.9rem;
}

.lb-loading,
.lb-error,
.lb-empty {
  text-align: center;
  padding: 2.5rem 1rem;
  color: var(--text-secondary);
  font-size: 0.9rem;
}