:root {
  --bg-primary: #0a0a0f;
  --bg-secondary: #0f0f15;
  --bg-tertiary: #14141e;
  --glass-ultra: rgba(255, 255, 255, 0.02);
  --glass-thin: rgba(255, 255, 255, 0.04);
  --glass-medium: rgba(255, 255, 255, 0.06);
  --glass-thick: rgba(255, 255, 255, 0.08);
  --glass-heavy: rgba(255, 255, 255, 0.12);
  --border-ultra: rgba(255, 255, 255, 0.05);
  --border-thin: rgba(255, 255, 255, 0.08);
  --border-medium: rgba(255, 255, 255, 0.12);
  --border-strong: rgba(255, 255, 255, 0.18);
  --border-color: rgba(255, 255, 255, 0.12);
  --text-primary: #f0f0f5;
  --text-secondary: #a0a0b0;
  --text-muted: #606070;
  --text-muted-dim: rgba(96, 96, 112, 0.08);
  --accent: #10b981;
  --accent-light: #34d399;
  --accent-dark: #059669;
  --accent-gradient: linear-gradient(135deg, #10b981 0%, #34d399 100%);
  --accent-dim: rgba(16, 185, 129, 0.08);
  --accent-glow: rgba(16, 185, 129, 0.3);
  --accent-border: rgba(16, 185, 129, 0.25);
  --danger: #ef4444;
  --danger-light: #f87171;
  --danger-dim: rgba(239, 68, 68, 0.08);
  --danger-border: rgba(239, 68, 68, 0.25);
  --warning: #f59e0b;
  --warning-light: #fbbf24;
  --warning-dim: rgba(245, 158, 11, 0.08);
  --warning-border: rgba(245, 158, 11, 0.25);
  --info: #3b82f6;
  --info-light: #60a5fa;
  --info-dim: rgba(59, 130, 246, 0.08);
  --info-border: rgba(59, 130, 246, 0.25);
  --java: #f97316;
  --java-dim: rgba(249, 115, 22, 0.1);
  --bedrock: #3b82f6;
  --bedrock-dim: rgba(59, 130, 246, 0.1);
  --radius: 16px;
  --radius-sm: 12px;
  --radius-xs: 8px;
  --blur-soft: blur(20px) saturate(1.2);
  --blur-medium: blur(40px) saturate(1.5);
  --blur-strong: blur(60px) saturate(1.8);
  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.2);
  --shadow-md: 0 8px 24px rgba(0, 0, 0, 0.3);
  --shadow-lg: 0 16px 48px rgba(0, 0, 0, 0.4);
  --shadow-glow: 0 0 30px rgba(16, 185, 129, 0.15);
  --header-bg: rgba(10, 10, 15, 0.8);
  --login-bg: #08080c;
  --console-bg: rgba(5, 5, 10, 0.8);
  --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

[data-theme="light"] {
  --bg-primary: #f0f2f5;
  --bg-secondary: #ffffff;
  --bg-tertiary: #e8eaed;
  --glass-ultra: rgba(255, 255, 255, 0.5);
  --glass-thin: rgba(255, 255, 255, 0.6);
  --glass-medium: rgba(255, 255, 255, 0.7);
  --glass-thick: rgba(255, 255, 255, 0.8);
  --glass-heavy: rgba(255, 255, 255, 0.9);
  --border-ultra: rgba(0, 0, 0, 0.05);
  --border-thin: rgba(0, 0, 0, 0.08);
  --border-medium: rgba(0, 0, 0, 0.12);
  --border-strong: rgba(0, 0, 0, 0.18);
  --border-color: rgba(0, 0, 0, 0.12);
  --text-primary: #1a1a2e;
  --text-secondary: #4a4a5a;
  --text-muted: #8a8a9a;
  --text-muted-dim: rgba(138, 138, 154, 0.08);
  --accent: #059669;
  --accent-light: #10b981;
  --accent-dark: #047857;
  --accent-gradient: linear-gradient(135deg, #059669 0%, #10b981 100%);
  --accent-dim: rgba(5, 150, 105, 0.08);
  --accent-glow: rgba(5, 150, 105, 0.2);
  --accent-border: rgba(5, 150, 105, 0.25);
  --danger: #dc2626;
  --danger-light: #ef4444;
  --danger-dim: rgba(220, 38, 38, 0.08);
  --danger-border: rgba(220, 38, 38, 0.2);
  --warning: #d97706;
  --warning-light: #f59e0b;
  --warning-dim: rgba(217, 119, 6, 0.08);
  --warning-border: rgba(217, 119, 6, 0.2);
  --info: #2563eb;
  --info-light: #3b82f6;
  --info-dim: rgba(37, 99, 235, 0.08);
  --info-border: rgba(37, 99, 235, 0.2);
  --java-dim: rgba(249, 115, 22, 0.08);
  --bedrock-dim: rgba(59, 130, 246, 0.08);
  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.06);
  --shadow-md: 0 8px 24px rgba(0, 0, 0, 0.08);
  --shadow-lg: 0 16px 48px rgba(0, 0, 0, 0.12);
  --shadow-glow: 0 0 30px rgba(5, 150, 105, 0.1);
  --header-bg: rgba(255, 255, 255, 0.7);
  --login-bg: #f0f2f5;
  --console-bg: rgba(26, 26, 46, 0.8);
  --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

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

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', sans-serif;
  background: var(--bg-primary);
  color: var(--text-primary);
  min-height: 100vh;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

/* Scrollbar */
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--border-medium); border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: var(--text-muted); }

/* Login Screen */
#login-screen {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--login-bg);
  background-image: 
    radial-gradient(ellipse at 20% 50%, rgba(16, 185, 129, 0.08) 0%, transparent 50%),
    radial-gradient(ellipse at 80% 50%, rgba(59, 130, 246, 0.06) 0%, transparent 50%);
}

.login-box {
  width: 100%;
  max-width: 420px;
  background: var(--glass-medium);
  backdrop-filter: var(--blur-medium);
  border: 1px solid var(--border-thin);
  border-radius: var(--radius);
  padding: 40px 32px;
  box-shadow: var(--shadow-lg), var(--shadow-glow);
}

.logo {
  text-align: center;
  margin-bottom: 32px;
  position: relative;
}

.logo-icon-wrap {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 80px;
  height: 80px;
  border-radius: 50%;
  background: radial-gradient(circle at 30% 30%, rgba(16,185,129,0.2), rgba(16,185,129,0.05));
  border: 1px solid rgba(16,185,129,0.2);
  margin-bottom: 16px;
  box-shadow: 0 0 40px rgba(16,185,129,0.15), inset 0 0 30px rgba(16,185,129,0.05);
}

.logo-icon {
  width: 56px;
  height: 56px;
  filter: drop-shadow(0 0 12px rgba(110, 231, 183, 0.5));
}

.logo h1 {
  font-size: 32px;
  font-weight: 700;
  letter-spacing: -1px;
  color: var(--text-primary);
}

.logo h1 span {
  background: var(--accent-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.logo p {
  color: var(--text-muted);
  font-size: 14px;
  margin-top: 4px;
  letter-spacing: 0.5px;
}

/* Tab Switch */
.tab-switch {
  display: flex;
  gap: 8px;
  margin-bottom: 24px;
  background: var(--glass-thin);
  border-radius: var(--radius-sm);
  padding: 4px;
}

.tab-switch .btn {
  flex: 1;
  padding: 10px;
  border: none;
  background: transparent;
  color: var(--text-muted);
  font-size: 14px;
  font-weight: 500;
  border-radius: var(--radius-xs);
  transition: var(--transition);
}

.tab-switch .btn.active {
  background: var(--accent);
  color: white;
  box-shadow: 0 2px 8px rgba(16, 185, 129, 0.3);
}

/* Form */
.form-group {
  margin-bottom: 16px;
}

.form-group label {
  display: block;
  font-size: 12px;
  font-weight: 600;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 6px;
}

.input {
  width: 100%;
  padding: 12px 16px;
  background: var(--glass-thin);
  border: 1px solid var(--border-thin);
  border-radius: var(--radius-xs);
  color: var(--text-primary);
  font-size: 14px;
  transition: var(--transition);
  outline: none;
}

.input:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-dim);
  background: var(--glass-medium);
}

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

select.input, select {
  appearance: none;
  -webkit-appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath fill='%23888' d='M6 8L0 0h12z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  padding-right: 36px;
  cursor: pointer;
}

select option {
  background: #1a1a2e;
  color: #e0e0e0;
  padding: 8px 12px;
}

.login-error {
  color: var(--danger);
  font-size: 13px;
  margin-top: 12px;
  text-align: center;
  min-height: 20px;
}

/* Buttons */
.btn {
  padding: 10px 20px;
  border: 1px solid var(--border-medium);
  border-radius: var(--radius-xs);
  background: var(--glass-medium);
  color: var(--text-primary);
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: var(--transition);
  backdrop-filter: var(--blur-soft);
}

.btn:hover {
  background: var(--glass-heavy);
  border-color: var(--border-strong);
}

.btn.accent {
  background: var(--accent-gradient);
  color: white;
  border: none;
  font-weight: 600;
  box-shadow: 0 4px 12px rgba(16, 185, 129, 0.3);
}

.btn.accent:hover {
  box-shadow: 0 6px 20px rgba(16, 185, 129, 0.4);
  transform: translateY(-1px);
}

.btn.ghost {
  background: transparent;
  border: 1px solid var(--border-thin);
  color: var(--text-secondary);
}

.btn.ghost:hover {
  background: var(--glass-thin);
  color: var(--text-primary);
}

.btn.sm {
  padding: 6px 12px;
  font-size: 12px;
}

.btn.danger {
  background: var(--danger);
  color: white;
  border: none;
}

/* Dashboard */
#dashboard {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  overflow-y: auto;
}

/* Header */
.header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 24px;
  background: var(--header-bg);
  backdrop-filter: var(--blur-medium);
  border-bottom: 1px solid var(--border-ultra);
  position: sticky;
  top: 0;
  z-index: 100;
  flex-wrap: wrap;
  gap: 8px;
}

.header-brand {
  display: flex;
  align-items: center;
  gap: 10px;
}

.header-logo-icon {
  width: 32px;
  height: 32px;
  filter: drop-shadow(0 0 10px rgba(16, 185, 129, 0.4));
}

.header-brand h1 {
  font-size: 20px;
  font-weight: 700;
  letter-spacing: -0.5px;
  text-shadow: 0 0 16px rgba(110,231,183,0.2);
}

.header-brand h1 span {
  background: var(--accent-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.header-user {
  display: flex;
  align-items: center;
  gap: 12px;
}

.username {
  font-size: 14px;
  font-weight: 500;
  color: var(--text-primary);
}

.role-badge {
  font-size: 10px;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: 100px;
  letter-spacing: 0.5px;
  text-transform: uppercase;
}

.role-badge.admin {
  background: var(--danger-dim);
  color: var(--danger);
  border: 1px solid var(--danger-border);
}

.role-badge.user {
  background: var(--info-dim);
  color: var(--info);
  border: 1px solid var(--info-border);
}

.role-badge.owner {
  background: rgba(234,179,8,0.15);
  color: #eab308;
  border: 1px solid rgba(234,179,8,0.3);
}

.theme-toggle {
  width: 36px;
  height: 36px;
  border: 1px solid var(--border-thin);
  border-radius: 50%;
  background: var(--glass-thin);
  cursor: pointer;
  font-size: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
}

.theme-toggle:hover {
  background: var(--glass-medium);
  border-color: var(--border-medium);
}

.cart-btn {
  position: relative;
  width: 36px;
  height: 36px;
  border: 1px solid var(--border-thin);
  border-radius: 50%;
  background: var(--glass-thin);
  cursor: pointer;
  font-size: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
}

.cart-btn:hover {
  background: var(--glass-medium);
  border-color: var(--border-medium);
}

.cart-badge {
  position: absolute;
  top: -4px;
  right: -4px;
  background: var(--accent);
  color: white;
  font-size: 10px;
  font-weight: 700;
  min-width: 18px;
  height: 18px;
  border-radius: 9px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 4px;
}

/* Navigation */
.nav-tabs {
  display: flex;
  gap: 4px;
  padding: 8px 24px;
  background: var(--bg-secondary);
  border-bottom: 1px solid var(--border-ultra);
}

.nav-tab {
  padding: 10px 20px;
  border: none;
  background: transparent;
  color: var(--text-muted);
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  border-radius: var(--radius-xs);
  transition: var(--transition);
  position: relative;
}

.nav-tab:hover {
  color: var(--text-primary);
  background: var(--glass-thin);
}

.nav-tab.active {
  color: var(--accent);
  background: var(--accent-dim);
}

.nav-tab.active::after {
  content: '';
  position: absolute;
  bottom: -9px;
  left: 50%;
  transform: translateX(-50%);
  width: 24px;
  height: 2px;
  background: var(--accent);
  border-radius: 1px;
}

/* Main Content */
.main-content {
  flex: 1;
  padding: 24px;
  max-width: 1400px;
  width: 100%;
  margin: 0 auto;
}

.tab-content {
  display: block;
  visibility: hidden;
  position: absolute;
  left: 0;
  top: 0;
  width: 100%;
  height: 0;
  overflow: hidden;
  pointer-events: none;
}

.tab-content.active {
  display: block;
  visibility: visible;
  position: static;
  width: auto;
  height: auto;
  overflow: visible;
  pointer-events: auto;
}

/* Section Header */
.section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 24px;
  flex-wrap: wrap;
  gap: 16px;
}

.section-header h2 {
  font-size: 24px;
  font-weight: 700;
  letter-spacing: -0.5px;
}

/* Hero Section */
.hero-section {
  background: var(--glass-medium);
  backdrop-filter: var(--blur-soft);
  border: 1px solid var(--border-thin);
  border-radius: var(--radius);
  padding: 32px;
  margin-bottom: 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 24px;
  background-image: 
    radial-gradient(ellipse at 0% 100%, rgba(16, 185, 129, 0.1) 0%, transparent 50%),
    radial-gradient(ellipse at 100% 0%, rgba(59, 130, 246, 0.08) 0%, transparent 50%);
}

.hero-text h2 {
  font-size: 28px;
  font-weight: 700;
  margin-bottom: 8px;
  letter-spacing: -0.5px;
}

.hero-text p {
  color: var(--text-secondary);
  font-size: 14px;
}

.hero-stats {
  display: flex;
  gap: 24px;
}

.hero-stat {
  text-align: center;
}

.hero-stat-value {
  font-size: 24px;
  font-weight: 700;
  color: var(--accent);
}

.hero-stat-label {
  font-size: 11px;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

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

.stat-card {
  background: var(--glass-medium);
  backdrop-filter: var(--blur-soft);
  border: 1px solid var(--border-thin);
  border-radius: var(--radius-sm);
  padding: 20px;
  transition: var(--transition);
}

.stat-card:hover {
  border-color: var(--border-medium);
  transform: translateY(-2px);
}

.stat-label {
  font-size: 12px;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 8px;
}

.stat-value {
  font-size: 28px;
  font-weight: 700;
  color: var(--text-primary);
}

.stat-value.accent {
  color: var(--accent);
}

.stat-value.danger {
  color: var(--danger);
}

/* Server Grid */
.server-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 20px;
}

.server-card {
  background: var(--glass-medium);
  backdrop-filter: var(--blur-soft);
  border: 1px solid var(--border-thin);
  border-radius: var(--radius);
  padding: 24px;
  transition: var(--transition);
  cursor: default;
  position: relative;
  overflow: hidden;
}

.server-card:hover {
  border-color: var(--accent-border);
  transform: translateY(-4px);
  box-shadow: var(--shadow-md), 0 0 20px rgba(16, 185, 129, 0.1);
}

.server-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: var(--accent-gradient);
  opacity: 0;
  transition: var(--transition);
}

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

.server-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
}

.server-name {
  font-size: 18px;
  font-weight: 600;
}

.server-edition {
  font-size: 11px;
  font-weight: 600;
  padding: 4px 10px;
  border-radius: 100px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.server-edition.java {
  background: var(--java-dim);
  color: var(--java);
  border: 1px solid rgba(249, 115, 22, 0.2);
}

.server-edition.bedrock {
  background: var(--bedrock-dim);
  color: var(--bedrock);
  border: 1px solid rgba(59, 130, 246, 0.2);
}

.status-indicator {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  font-weight: 500;
  padding: 4px 10px;
  border-radius: 100px;
}

.status-indicator.running {
  background: var(--accent-dim);
  color: var(--accent);
}

.status-indicator.stopped {
  background: var(--text-muted-dim);
  color: var(--text-muted);
}

.status-indicator.starting {
  background: rgba(251, 191, 36, 0.15);
  color: #fbbf24;
}

.status-indicator.starting .status-dot {
  background: #fbbf24;
  animation: pulse 1s ease-in-out infinite;
}

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

.status-indicator.error {
  background: var(--danger-dim);
  color: var(--danger);
}

.status-indicator.expired {
  background: var(--warning-dim);
  color: var(--warning);
}

.status-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  animation: pulse 2s infinite;
}

.status-indicator.running .status-dot { background: var(--accent); }
.status-indicator.stopped .status-dot { background: var(--text-muted); }
.status-indicator.error .status-dot { background: var(--danger); }
.status-indicator.expired .status-dot { background: var(--warning); }

@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.5; }
}

.server-info {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-bottom: 16px;
}

.server-info-item {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.server-info-label {
  font-size: 11px;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.server-info-value {
  font-size: 14px;
  font-weight: 500;
  color: var(--text-primary);
}

.server-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 16px;
  padding-top: 16px;
  border-top: 1px solid var(--border-ultra);
}

/* Games Grid */
.search-box {
  position: relative;
  min-width: 300px;
}

.search-box .input {
  padding-left: 40px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='18' height='18' fill='%239ca3af' viewBox='0 0 16 16'%3E%3Cpath d='M11.742 10.344a6.5 6.5 0 1 0-1.397 1.398h-.001l3.85 3.85a1 1 0 0 0 1.415-1.414l-3.85-3.85zm-5.44.156a5 5 0 1 1 0-10 5 5 0 0 1 0 10z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: 14px center;
  background-size: 18px;
}

.games-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 20px;
  margin-top: 24px;
}

.game-card {
  background: var(--glass-medium);
  backdrop-filter: var(--blur-soft);
  border: 1px solid var(--border-thin);
  border-radius: var(--radius);
  padding: 24px;
  cursor: pointer;
  transition: var(--transition);
  text-align: center;
  position: relative;
  overflow: hidden;
}

.game-card:hover {
  transform: translateY(-6px);
  border-color: var(--accent-border);
  box-shadow: var(--shadow-lg), 0 0 30px rgba(16, 185, 129, 0.15);
}

.game-card::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: var(--accent-gradient);
  transform: scaleX(0);
  transition: transform 0.3s ease;
}

.game-card:hover::after {
  transform: scaleX(1);
}

.game-card-icon {
  font-size: 48px;
  margin-bottom: 16px;
  display: block;
  filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.3));
}

.game-card-name {
  font-size: 16px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 6px;
}

.game-card-desc {
  font-size: 12px;
  color: var(--text-muted);
  line-height: 1.4;
}

/* Shop Grid */
.shop-intro {
  color: var(--text-secondary);
  font-size: 14px;
  margin-bottom: 24px;
  padding: 16px;
  background: var(--glass-thin);
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-ultra);
}

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

.shop-card {
  background: var(--glass-medium);
  backdrop-filter: var(--blur-soft);
  border: 1px solid var(--border-thin);
  border-radius: var(--radius);
  padding: 24px;
  transition: var(--transition);
  position: relative;
  overflow: hidden;
}

.shop-card.featured {
  border-color: var(--accent-border);
  box-shadow: 0 0 20px rgba(16, 185, 129, 0.1);
}

.shop-card.featured::before {
  content: 'EMPFOHLEN';
  position: absolute;
  top: 12px;
  right: -32px;
  background: var(--accent-gradient);
  color: white;
  font-size: 10px;
  font-weight: 700;
  padding: 4px 40px;
  transform: rotate(45deg);
  letter-spacing: 0.5px;
}

.shop-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
  border-color: var(--border-medium);
}

.shop-card h3 {
  font-size: 20px;
  font-weight: 700;
  margin-bottom: 8px;
}

.shop-card .price {
  font-size: 32px;
  font-weight: 700;
  color: var(--accent);
  margin-bottom: 16px;
}

.shop-card .price-period {
  font-size: 14px;
  color: var(--text-muted);
  font-weight: 400;
}

.shop-specs {
  list-style: none;
  margin-bottom: 20px;
}

.shop-specs li {
  padding: 8px 0;
  font-size: 13px;
  color: var(--text-secondary);
  border-bottom: 1px solid var(--border-ultra);
  display: flex;
  align-items: center;
  gap: 8px;
}

.shop-specs li::before {
  content: '✓';
  color: var(--accent);
  font-weight: 700;
}

/* Settings */
.settings-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 24px;
  flex-wrap: wrap;
  gap: 16px;
}

.settings-header h2 {
  font-size: 20px;
  font-weight: 600;
}

.settings-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.settings-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  margin-bottom: 24px;
  background: var(--glass-thin);
  border-radius: var(--radius-sm);
  padding: 4px;
}

@media (max-width: 768px) {
  .settings-nav {
    flex-wrap: nowrap;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }
}

.settings-tab {
  padding: 10px 16px;
  border: none;
  background: transparent;
  color: var(--text-muted);
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  border-radius: var(--radius-xs);
  transition: var(--transition);
  white-space: nowrap;
}

.settings-tab:hover {
  color: var(--text-primary);
  background: var(--glass-medium);
}

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

.settings-content {
  background: var(--glass-medium);
  backdrop-filter: var(--blur-soft);
  border: 1px solid var(--border-thin);
  border-radius: var(--radius);
  padding: 24px;
}

.settings-panel {
  display: none;
}

.settings-panel.active {
  display: block;
  animation: fadeIn 0.3s ease;
}

.config-section {
  margin-bottom: 24px;
  padding-bottom: 24px;
  border-bottom: 1px solid var(--border-ultra);
}

.config-section:last-child {
  border-bottom: none;
  margin-bottom: 0;
  padding-bottom: 0;
}

.config-section h3 {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 16px;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

/* Stats Overview */
.stats-overview {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 16px;
  margin-bottom: 24px;
}

.stat-item {
  background: var(--glass-thin);
  border: 1px solid var(--border-ultra);
  border-radius: var(--radius-sm);
  padding: 16px;
}

.stat-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 8px;
}

.stat-label-text {
  font-size: 12px;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.stat-value-text {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
}

.stat-bar {
  height: 6px;
  background: var(--glass-thin);
  border: 1px solid var(--border-ultra);
  border-radius: 3px;
  overflow: hidden;
}

.stat-fill {
  height: 100%;
  border-radius: 3px;
  transition: width 0.6s cubic-bezier(0.4, 0, 0.2, 1);
  background: var(--accent-gradient);
  box-shadow: 0 0 12px rgba(16, 185, 129, 0.4);
}

.stat-fill.warning {
  background: linear-gradient(90deg, var(--warning), var(--warning-light));
  box-shadow: 0 0 12px rgba(245, 158, 11, 0.4);
}

.stat-fill.danger {
  background: linear-gradient(90deg, var(--danger), var(--danger-light));
  box-shadow: 0 0 12px rgba(239, 68, 68, 0.4);
}

/* Console */
.console-box {
  background: var(--console-bg);
  border: 1px solid var(--border-thin);
  border-radius: var(--radius-sm);
  padding: 16px;
  height: 400px;
  overflow-y: auto;
  font-family: 'SF Mono', 'Fira Code', monospace;
  font-size: 12px;
  line-height: 1.6;
  color: var(--text-primary);
}

/* Cards */
.card {
  background: var(--glass-medium);
  backdrop-filter: var(--blur-soft);
  border: 1px solid var(--border-thin);
  border-radius: var(--radius);
  padding: 24px;
  margin-bottom: 20px;
}

.card:last-child {
  margin-bottom: 0;
}

.accent-border {
  border-color: var(--accent-border);
}

/* Empty State */
.empty-list {
  text-align: center;
  padding: 48px 24px;
  color: var(--text-muted);
  font-size: 14px;
}

/* Admin */
#users-list table, #pending-orders table {
  width: 100%;
  border-collapse: collapse;
}

#users-list th, #pending-orders th {
  text-align: left;
  padding: 10px 12px;
  font-size: 11px;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  border-bottom: 1px solid var(--border-thin);
}

#users-list td, #pending-orders td {
  padding: 12px;
  font-size: 13px;
  border-bottom: 1px solid var(--border-ultra);
}

/* Admin table: mobile card layout */
@media (max-width: 768px) {
  #users-list table, #pending-orders table {
    display: block;
    overflow-x: visible;
  }
  #users-list thead, #pending-orders thead {
    display: none;
  }
  #users-list tbody, #pending-orders tbody {
    display: flex;
    flex-direction: column;
    gap: 8px;
  }
  #users-list tr, #pending-orders tr {
    display: flex;
    flex-direction: column;
    background: var(--bg-main);
    border-radius: var(--radius-xs);
    padding: 12px;
    gap: 6px;
  }
  #users-list td, #pending-orders td {
    padding: 4px 0;
    border-bottom: none;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
  }
  #users-list td:last-child, #pending-orders td:last-child {
    flex-wrap: wrap;
  }
  #users-list td::before, #pending-orders td::before {
    content: attr(data-label);
    font-size: 11px;
    font-weight: 600;
    color: var(--text-muted);
    text-transform: uppercase;
    min-width: 80px;
  }
}

/* Responsive */
@media (max-width: 768px) {
  .header { padding: 12px 16px; flex-wrap: wrap; gap: 8px; }
  .header-brand h1 { font-size: 16px; }
  .header-user .username { display: none; }
  .nav-tabs { padding: 8px 16px; overflow-x: auto; -webkit-overflow-scrolling: touch; gap: 0; }
  .nav-tab { white-space: nowrap; flex-shrink: 0; font-size: 12px; padding: 8px 14px; }
  .main-content { padding: 12px; }
  .server-grid { grid-template-columns: 1fr; }
  .shop-grid { grid-template-columns: 1fr; }
  .stats-grid { grid-template-columns: 1fr 1fr; }
  .stats-overview { grid-template-columns: 1fr; }
  .form-row { grid-template-columns: 1fr; }
  .hero-section { flex-direction: column; text-align: center; gap: 12px; }
  .hero-stats { justify-content: center; gap: 16px; flex-wrap: wrap; }
  .hero-stat-value { font-size: 28px; }
  .hero-stat-label { font-size: 12px; }
  .search-box { min-width: 100%; }
  .games-grid { grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); }
  .settings-nav { overflow-x: auto; -webkit-overflow-scrolling: touch; flex-wrap: nowrap; }
  .settings-nav button { white-space: nowrap; flex-shrink: 0; font-size: 12px; padding: 8px 14px; }
  .settings-header { flex-direction: column; align-items: flex-start; gap: 8px; }
  .settings-actions { width: 100%; justify-content: flex-start; }
  .card { padding: 14px; }
  .config-section h3 { font-size: 14px; }
  .players-table { font-size: 11px; }
  .players-table th, .players-table td { padding: 4px 6px; }
  .notification-bell { margin: 0; width: 32px; height: 32px; font-size: 14px; }
  #notif-dropdown { width: calc(100vw - 16px) !important; max-height: 50vh; }
  .header-user { gap: 6px; }
  .cart-btn .cart-badge { right: -4px; top: -4px; }
}

@media (max-width: 480px) {
  .header { padding: 8px 12px; flex-wrap: wrap; }
  .header-brand svg { width: 24px; height: 24px; }
  .header-brand h1 { font-size: 14px; }
  .main-content { padding: 8px; overflow-x: hidden; }
  .card { padding: 10px; overflow: visible; }
  .hero-stat-value { font-size: 24px; }
  .server-card { padding: 14px; }
  .server-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 6px;
  }
  .server-actions .btn { width: 100%; justify-content: center; font-size: 11px; padding: 8px 10px; }
  .server-actions .btn[title="Einstellungen"],
  .server-actions .btn[title="Server teilen"] { grid-column: 1 / -1; }
  .server-actions .btn.danger:last-child { grid-column: 1 / -1; }
  .settings-actions { gap: 6px; flex-wrap: wrap; }
  .settings-actions .btn { font-size: 11px; padding: 6px 10px; }
  .status-indicator { font-size: 11px; }
  .login-box { padding: 24px 16px; }
  .tab-switch button { font-size: 13px; padding: 8px 20px; }
  .config-section { padding: 12px 0; }
  .input { font-size: 13px; padding: 8px 10px; }
  .btn { font-size: 12px; padding: 8px 14px; }
  .console-box { font-size: 11px; padding: 8px; max-height: 250px; }
  .stats-overview .stat-item { padding: 8px; }
  #file-editor-content { min-height: 200px; font-size: 11px; }
  .file-item { padding: 6px 8px; font-size: 12px; }
  .settings-nav button { font-size: 11px; padding: 6px 10px; }
  .nav-tab { font-size: 11px; padding: 6px 10px; }
  #notif-dropdown { width: calc(100vw - 16px) !important; right: 8px !important; }
  .games-grid { grid-template-columns: repeat(auto-fill, minmax(120px, 1fr)); gap: 8px; }
  .shop-grid { gap: 8px; }
}

/* Notifications */
.notification {
  position: fixed;
  top: 20px;
  left: 50%;
  transform: translateX(-50%);
  padding: 12px 20px;
  border-radius: var(--radius-xs);
  font-size: 14px;
  font-weight: 500;
  z-index: 1000;
  animation: slideDown 0.3s ease;
  backdrop-filter: var(--blur-soft);
  white-space: nowrap;
}

.notification.success {
  background: var(--accent-dim);
  color: var(--accent);
  border: 1px solid var(--accent-border);
}

.notification.error {
  background: var(--danger-dim);
  color: var(--danger);
  border: 1px solid var(--danger-border);
}

@keyframes slideDown {
  from { transform: translate(-50%, -20px); opacity: 0; }
  to { transform: translate(-50%, 0); opacity: 1; }
}

/* Avatar */
.avatar-small {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--accent);
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 600;
  font-size: 14px;
}

.avatar-large {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--accent), var(--accent-hover));
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 600;
  font-size: 32px;
  border: 3px solid var(--border);
}

.user-menu:hover {
  opacity: 0.8;
  transition: opacity 0.2s;
}

/* Hero Avatar */
.hero-avatar {
  display: flex;
  align-items: center;
  justify-content: center;
  align-self: center;
}

.settings-btn:hover .gear-icon {
  transform: rotate(90deg);
}

.settings-btn:hover {
  background: var(--accent);
  color: #fff !important;
  border-color: var(--accent) !important;
}

@keyframes bell-shake {
  0% { transform: rotate(0); }
  15% { transform: rotate(15deg); }
  30% { transform: rotate(-15deg); }
  45% { transform: rotate(10deg); }
  60% { transform: rotate(-10deg); }
  75% { transform: rotate(5deg); }
  85% { transform: rotate(-5deg); }
  100% { transform: rotate(0); }
}

.notification-bell {
  position: relative;
  width: 36px;
  height: 36px;
  border: 1px solid var(--border-thin);
  border-radius: 50%;
  background: var(--glass-thin);
  cursor: pointer;
  font-size: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
}

.notification-bell:hover {
  animation: bell-shake 0.4s !important;
}

.players-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 12px;
}
.players-table th {
  text-align: left;
  padding: 6px 8px;
  color: var(--text-muted);
  border-bottom: 1px solid var(--border-thin);
  font-weight: 500;
}
.players-table td {
  padding: 6px 8px;
  border-bottom: 1px solid var(--border-ultra);
  color: var(--text-primary);
}
.players-table tr:hover td {
  background: var(--glass-thin);
}

/* ============================================
   MOBILE / APP OPTIMIZATIONS
   ============================================ */

/* Detect if running in WebView (app) */
body.app-mode.nav-visible {
  padding-bottom: 70px;
}

body.app-mode #download-app-link {
  display: none !important;
}

/* Safe area for notched phones */
@supports (padding: env(safe-area-inset-bottom)) {
  body.app-mode.nav-visible .mobile-bottom-nav {
    padding-bottom: env(safe-area-inset-bottom);
  }
  body.app-mode.nav-visible {
    padding-bottom: calc(70px + env(safe-area-inset-bottom));
  }
  #login-screen .login-box {
    padding-top: calc(24px + env(safe-area-inset-top));
  }
}

/* Bottom Navigation Bar (nur App/ Mobile) */
.mobile-bottom-nav {
  display: none;
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  height: 64px;
  background: rgba(10, 10, 15, 0.95);
  backdrop-filter: blur(20px) saturate(1.5);
  -webkit-backdrop-filter: blur(20px) saturate(1.5);
  border-top: 1px solid var(--border-ultra);
  z-index: 200;
  padding: 0 8px;
  align-items: center;
  justify-content: space-around;
  padding-bottom: 0;
}

[data-theme="light"] .mobile-bottom-nav {
  background: rgba(255, 255, 255, 0.95);
  border-top-color: rgba(0, 0, 0, 0.08);
}

.mobile-nav-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  padding: 6px 12px;
  border: none;
  background: transparent;
  color: var(--text-muted);
  font-size: 10px;
  font-weight: 500;
  cursor: pointer;
  border-radius: 12px;
  transition: all 0.2s ease;
  min-width: 56px;
  -webkit-tap-highlight-color: transparent;
  position: relative;
}

.mobile-nav-item .nav-icon {
  font-size: 22px;
  line-height: 1;
  transition: all 0.2s ease;
}

.mobile-nav-item.active {
  color: var(--accent);
}

.mobile-nav-item.active .nav-icon {
  transform: scale(1.1);
  filter: drop-shadow(0 0 6px rgba(16, 185, 129, 0.4));
}

.mobile-nav-item.active::before {
  content: '';
  position: absolute;
  top: -1px;
  left: 50%;
  transform: translateX(-50%);
  width: 24px;
  height: 3px;
  background: var(--accent);
  border-radius: 0 0 3px 3px;
}

.mobile-nav-item:active {
  transform: scale(0.92);
}

/* Mobile Header - compact */
@media (max-width: 768px) {
  body.app-mode.nav-visible .mobile-bottom-nav {
    display: flex;
  }

  /* Hide desktop nav-tabs in app mode after login */
  body.app-mode.nav-visible .nav-tabs {
    display: none;
  }

  /* Hide header user details in app mode, keep compact */
  body.app-mode.nav-visible .header-user .username,
  body.app-mode.nav-visible .header-user .role-badge,
  body.app-mode.nav-visible .header-user .theme-toggle,
  body.app-mode.nav-visible .header-user .btn.ghost {
    display: none !important;
  }

  body.app-mode.nav-visible .user-menu {
    display: none !important;
  }

  /* Add safe area top padding */
  body.app-mode .header {
    padding-top: calc(10px + env(safe-area-inset-top));
  }

  /* Main content bottom padding for nav bar */
  body.app-mode.nav-visible .main-content {
    padding-bottom: 24px;
  }

  /* Server cards - full width, better touch */
  body.app-mode .server-card {
    padding: 16px;
    border-radius: 14px;
  }

  body.app-mode .server-actions {
    flex-wrap: wrap;
    gap: 8px;
  }

  body.app-mode .server-actions .btn {
    min-height: 44px;
    font-size: 13px;
    font-weight: 600;
    border-radius: 10px;
    flex: 1 1 auto;
    min-width: 0;
  }

  /* In app: hide the tiny share icon button, replace with full-width row */
  body.app-mode .server-actions .btn[style*="border-radius:50%"] {
    display: none;
  }

  /* Stats - bigger touch targets */
  body.app-mode .stat-item {
    padding: 14px;
    min-height: 60px;
  }

  /* Inputs - bigger for touch */
  body.app-mode .input {
    min-height: 48px;
    font-size: 16px; /* prevents iOS zoom on focus */
    padding: 12px 14px;
  }

  body.app-mode .btn {
    min-height: 48px;
    font-size: 15px;
    font-weight: 600;
    border-radius: 12px;
  }

  /* Login screen - full height mobile */
  body.app-mode #login-screen {
    padding: 0 16px;
    padding-top: env(safe-area-inset-top);
  }

  body.app-mode .login-box {
    padding: 28px 20px;
    border-radius: 20px;
    max-width: 100%;
  }

  body.app-mode .logo-icon-wrap {
    width: 72px;
    height: 72px;
  }

  body.app-mode .logo-icon {
    width: 48px;
    height: 48px;
  }

  body.app-mode .logo h1 {
    font-size: 28px;
  }

  /* Tab switch - bigger buttons */
  body.app-mode .tab-switch .btn {
    padding: 12px;
    font-size: 15px;
    font-weight: 600;
    min-height: 44px;
  }

  /* Section headers - compact */
  body.app-mode .section-header {
    margin-bottom: 12px;
    gap: 8px;
  }
  body.app-mode .section-header h2 {
    font-size: 16px;
    font-weight: 700;
  }

  /* Hide redundant server-stats bar (hero already shows stats) */
  body.app-mode #server-stats {
    display: none !important;
  }

  /* Reduce animations for better mobile perf */
  body.app-mode * {
    animation-duration: 0.2s !important;
    transition-duration: 0.15s !important;
  }

  /* Console - full screen option */
  body.app-mode .console-box {
    max-height: 300px;
    font-size: 12px;
    border-radius: 12px;
  }

  /* Config sections - cleaner mobile layout */
  body.app-mode .config-section {
    padding: 14px 0;
  }

  body.app-mode .config-section h3 {
    font-size: 15px;
    margin-bottom: 12px;
  }

  /* Modal overlays - full screen on mobile */
  body.app-mode .modal-overlay {
    padding: 0;
    align-items: flex-end;
  }

  body.app-mode .modal-content {
    border-radius: 20px 20px 0 0;
    max-height: 90vh;
    overflow-y: auto;
    padding-bottom: env(safe-area-inset-bottom);
  }

  /* File list items - better touch */
  body.app-mode .file-item {
    padding: 12px 14px;
    min-height: 48px;
    display: flex;
    align-items: center;
  }

  /* Pull to refresh indicator */
  .pull-refresh-indicator {
    display: none;
    text-align: center;
    padding: 12px;
    color: var(--text-muted);
    font-size: 13px;
  }

  body.app-mode .pull-refresh-indicator.active {
    display: block;
  }

  /* Smooth scroll */
  body.app-mode .main-content {
    -webkit-overflow-scrolling: touch;
    scroll-behavior: smooth;
  }

  /* Better focus styles for accessibility */
  body.app-mode .btn:focus-visible,
  body.app-mode .input:focus-visible,
  body.app-mode .nav-tab:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 2px;
  }

  /* Haptic feedback simulation on tap */
  body.app-mode .btn:active,
  body.app-mode .server-card:active {
    transform: scale(0.98);
  }
}

/* Small phones */
@media (max-width: 380px) {
  body.app-mode .mobile-nav-item {
    min-width: 48px;
    padding: 4px 8px;
    font-size: 9px;
  }
  body.app-mode .mobile-nav-item .nav-icon {
    font-size: 20px;
  }
  body.app-mode .login-box {
    padding: 20px 14px;
  }
  body.app-mode .logo h1 {
    font-size: 24px;
  }
}

/* Landscape mode */
@media (max-height: 500px) and (orientation: landscape) {
  body.app-mode .mobile-bottom-nav {
    height: 48px;
  }
  body.app-mode .mobile-nav-item .nav-icon {
    font-size: 18px;
  }
  body.app-mode .mobile-nav-item {
    font-size: 9px;
    padding: 4px 10px;
  }
}

/* ============================================
   APP MODE ENHANCEMENTS (detected via JS)
   ============================================ */

/* --- App Mode: Settings tabs scrollable with bigger touch targets --- */
body.app-mode .settings-nav {
  gap: 6px;
  padding: 4px 0;
  -webkit-overflow-scrolling: touch;
  overflow-x: auto;
  -ms-overflow-style: none;
  scrollbar-width: none;
}
body.app-mode .settings-nav::-webkit-scrollbar { display: none; }
body.app-mode .settings-tab {
  padding: 10px 16px;
  font-size: 13px;
  white-space: nowrap;
  min-height: 40px;
  border-radius: 10px;
  flex-shrink: 0;
}

/* --- App Mode: Prevent ALL horizontal overflow --- */
body.app-mode,
body.app-mode #dashboard,
body.app-mode .main-content,
body.app-mode .header,
body.app-mode .header-user {
  overflow-x: hidden;
  max-width: 100%;
}

/* --- App Mode: Config form inputs bigger --- */
body.app-mode .config-section .input,
body.app-mode .config-section select {
  min-height: 48px;
  font-size: 16px;
  padding: 12px 14px;
  width: 100%;
  box-sizing: border-box;
}
body.app-mode .config-section label {
  font-size: 13px;
  margin-bottom: 6px;
}

/* --- App Mode: Server card badges row wrap --- */
body.app-mode .edition-badge,
body.app-mode .badge-danger,
body.app-mode .badge-warning,
body.app-mode .badge {
  font-size: 9px;
  padding: 2px 6px;
}
body.app-mode .server-card > .edition-badge,
body.app-mode .server-card > .badge-danger,
body.app-mode .server-card > .badge-warning,
body.app-mode .server-card > .badge {
  margin-bottom: 6px;
}

/* --- App Mode: Server info items --- */
body.app-mode .info-item {
  font-size: 13px;
  padding: 8px 0;
  word-break: break-word;
}
body.app-mode .copy-ip {
  font-size: 12px;
}

/* --- App Mode: Server actions — 2-column grid --- */
body.app-mode .server-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}
body.app-mode .server-actions .btn {
  width: 100%;
  justify-content: center;
  min-height: 44px;
  font-size: 13px;
}
/* Settings and share buttons span full width */
body.app-mode .server-actions .btn[title="Einstellungen"],
body.app-mode .server-actions .btn[title="Server teilen"] {
  grid-column: 1 / -1;
}
/* Delete button: full width, danger style, at the bottom */
body.app-mode .server-actions .btn.danger:last-child {
  grid-column: 1 / -1;
  background: rgba(239, 68, 68, 0.12);
  border: 1px solid rgba(239, 68, 68, 0.3);
  color: #f87171;
}
/* Hide the tiny circular share button in app */
body.app-mode .server-actions .btn[style*="border-radius:50%"] {
  display: none !important;
}

/* --- App Mode: Header compact --- */
body.app-mode .header {
  padding: 8px 12px;
  gap: 6px;
}
body.app-mode .header-brand svg {
  width: 24px;
  height: 24px;
}
body.app-mode .header-brand h1 {
  font-size: 15px;
}
body.app-mode .header-user {
  gap: 6px;
}
body.app-mode .cart-btn,
body.app-mode .notification-bell {
  font-size: 18px;
  padding: 4px;
}
body.app-mode .header-user [download] {
  padding: 5px 10px;
  font-size: 11px;
  gap: 3px;
}
body.app-mode .header-user [download] svg {
  width: 12px;
  height: 12px;
}

/* --- App Mode: Settings actions (save button) full width --- */
body.app-mode .settings-actions {
  flex-direction: column;
}
body.app-mode .settings-actions .btn {
  width: 100%;
  justify-content: center;
}

/* --- App Mode: Backup/Plugin cards --- */
body.app-mode .backup-card,
body.app-mode .plugin-card,
body.app-mode .mod-card {
  padding: 14px;
  gap: 14px;
}
body.app-mode .backup-actions,
body.app-mode .plugin-actions,
body.app-mode .mod-actions {
  flex-direction: row;
  gap: 8px;
}

/* --- App Mode: Pending orders --- */
body.app-mode .pending-order {
  flex-direction: column;
  align-items: flex-start;
  gap: 10px;
}
body.app-mode .order-actions {
  width: 100%;
  justify-content: flex-end;
}

/* --- App Mode: Hero kompakt --- */
body.app-mode .hero-section {
  flex-direction: column;
  align-items: flex-start;
  padding: 12px 16px;
  gap: 8px;
  margin-bottom: 16px;
}
body.app-mode .hero-text h2 {
  font-size: 15px;
  font-weight: 700;
  margin: 0;
}
body.app-mode .hero-text p {
  font-size: 11px;
  margin: 2px 0 0 0;
  color: var(--text-secondary);
}
body.app-mode .hero-stats {
  display: flex;
  gap: 6px;
  width: 100%;
}
body.app-mode .hero-stat {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  padding: 6px 0;
  background: var(--accent-dim);
  border: 1px solid var(--accent-border);
  border-radius: 8px;
}
body.app-mode .hero-stat-value {
  font-size: 14px;
  font-weight: 700;
  color: var(--accent);
  line-height: 1;
}
body.app-mode .hero-stat-label {
  font-size: 10px;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.3px;
}
body.app-mode .hero-avatar {
  display: none !important;
}

/* --- App Mode: Notification dropdown full width --- */
body.app-mode #notif-dropdown {
  width: calc(100vw - 24px);
  right: 12px;
  left: 12px;
  max-height: 60vh;
}

/* Vibrate on button press (if supported) */
@keyframes tapFeedback {
  0% { transform: scale(1); }
  50% { transform: scale(0.96); }
  100% { transform: scale(1); }
}

/* Status bar color for Android WebView */
@media (display-mode: standalone) {
  :root {
    color-scheme: dark;
  }
  [data-theme="light"] {
    color-scheme: light;
  }
}

/* ============================================
   MISSING CSS CLASSES — UI FIXES
   ============================================ */

/* --- Button variants --- */
.btn.success {
  background: var(--success, #22c55e);
  color: #fff;
  border: none;
}
.btn.success:hover {
  background: #16a34a;
}
.btn.info {
  background: var(--accent, #3b82f6);
  color: #fff;
  border: none;
}
.btn.info:hover {
  background: #2563eb;
}

/* --- Edition badges on server cards --- */
.edition-badge {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 4px;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  vertical-align: middle;
  line-height: 1.4;
}
.edition-badge.bedrock, .edition-badge.java, .edition-badge.vanilla {
  background: rgba(59, 130, 246, 0.15);
  color: #60a5fa;
  border: 1px solid rgba(59, 130, 246, 0.25);
}
.edition-badge.seven-days, .edition-badge.rust, .edition-badge.ark, .edition-badge.gmod {
  background: rgba(249, 115, 22, 0.15);
  color: #fb923c;
  border: 1px solid rgba(249, 115, 22, 0.25);
}

/* --- Status badges (expired, warning, etc.) --- */
.badge, .badge-danger, .badge-warning {
  display: inline-block;
  padding: 3px 8px;
  border-radius: 4px;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.3px;
  text-transform: uppercase;
  line-height: 1.4;
}
.badge {
  background: var(--glass-thin, rgba(255,255,255,0.06));
  color: var(--text-secondary, #94a3b8);
  border: 1px solid var(--border-thin, rgba(255,255,255,0.08));
}
.badge-danger {
  background: rgba(239, 68, 68, 0.15);
  color: #f87171;
  border: 1px solid rgba(239, 68, 68, 0.25);
}
.badge-warning {
  background: rgba(245, 158, 11, 0.15);
  color: #fbbf24;
  border: 1px solid rgba(245, 158, 11, 0.25);
}

/* --- Server info items --- */
.info-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 6px 0;
  font-size: 12px;
  color: var(--text-secondary, #94a3b8);
  border-bottom: 1px solid var(--border-ultra, rgba(255,255,255,0.03));
}
.info-item:last-child {
  border-bottom: none;
}
.info-item span {
  color: var(--text-primary, #f1f5f9);
  font-weight: 500;
}

/* --- Copy-able IP --- */
.copy-ip {
  cursor: pointer;
  color: var(--accent, #3b82f6);
  font-family: 'SF Mono', 'Cascadia Code', monospace;
  font-size: 12px;
  transition: color 0.2s;
}
.copy-ip:hover {
  color: #60a5fa;
  text-decoration: underline;
}

/* --- Game category headers --- */
.game-category-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 0 12px 0;
  border-bottom: 1px solid var(--border-ultra, rgba(255,255,255,0.03));
  margin-bottom: 16px;
}
.game-category-header h3 {
  margin: 0;
  font-size: 15px;
  font-weight: 600;
  color: var(--text-primary, #f1f5f9);
}
.game-category-header .badge {
  margin-left: 8px;
}

/* --- Plugin & Mod cards --- */
.plugin-card, .mod-card {
  background: var(--glass-thin, rgba(255,255,255,0.04));
  border: 1px solid var(--border-thin, rgba(255,255,255,0.08));
  border-radius: var(--radius-sm, 8px);
  padding: 12px;
  display: flex;
  gap: 12px;
  align-items: flex-start;
  transition: border-color 0.2s, background 0.2s;
}
.plugin-card:hover, .mod-card:hover {
  border-color: var(--accent, rgba(59,130,246,0.3));
  background: var(--glass-medium, rgba(255,255,255,0.06));
}
.plugin-icon, .mod-icon {
  width: 40px;
  height: 40px;
  min-width: 40px;
  border-radius: var(--radius-xs, 6px);
  background: var(--bg-main, #0a0a1a);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  overflow: hidden;
}
.plugin-info, .mod-info {
  flex: 1;
  min-width: 0;
}
.plugin-title, .mod-title {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-primary, #f1f5f9);
  margin-bottom: 2px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.plugin-desc, .mod-desc {
  font-size: 11px;
  color: var(--text-muted, #64748b);
  line-height: 1.4;
  margin-bottom: 4px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.plugin-meta, .mod-meta {
  font-size: 10px;
  color: var(--text-muted, #64748b);
}
.plugin-actions, .mod-actions {
  display: flex;
  flex-direction: column;
  gap: 4px;
  align-items: flex-end;
  min-width: 80px;
}

/* --- Backup cards --- */
.backup-card {
  background: var(--glass-thin, rgba(255,255,255,0.04));
  border: 1px solid var(--border-thin, rgba(255,255,255,0.08));
  border-radius: var(--radius-sm, 8px);
  padding: 12px;
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 8px;
}
.backup-icon {
  width: 36px;
  height: 36px;
  min-width: 36px;
  border-radius: var(--radius-xs, 6px);
  background: rgba(99, 102, 241, 0.1);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
}
.backup-info {
  flex: 1;
  min-width: 0;
}
.backup-name {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-primary, #f1f5f9);
}
.backup-meta {
  font-size: 11px;
  color: var(--text-muted, #64748b);
}
.backup-actions {
  display: flex;
  gap: 6px;
  align-items: center;
}

/* --- Pending orders (admin) --- */
.pending-order {
  background: var(--glass-thin, rgba(255,255,255,0.04));
  border: 1px solid var(--border-thin, rgba(255,255,255,0.08));
  border-radius: var(--radius-sm, 8px);
  padding: 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 8px;
  gap: 12px;
}
.order-info {
  flex: 1;
  min-width: 0;
  font-size: 12px;
  color: var(--text-secondary, #94a3b8);
}
.order-amount {
  font-weight: 700;
  color: var(--text-primary, #f1f5f9);
}
.order-actions {
  display: flex;
  gap: 6px;
  align-items: center;
}

/* --- Payment dialog --- */
.payment-info-box {
  background: var(--bg-main, #0a0a1a);
  border: 1px solid var(--border-thin, rgba(255,255,255,0.08));
  border-radius: var(--radius-sm, 8px);
  padding: 16px;
  margin: 12px 0;
}
.payment-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 6px 0;
  font-size: 13px;
}
.payment-row .label {
  color: var(--text-secondary, #94a3b8);
}
.payment-row .value {
  font-weight: 600;
  color: var(--text-primary, #f1f5f9);
}

/* --- User/Coupon tables --- */
.user-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 12px;
}
.user-table th {
  text-align: left;
  padding: 8px 12px;
  font-weight: 600;
  color: var(--text-secondary, #94a3b8);
  border-bottom: 1px solid var(--border-ultra, rgba(255,255,255,0.05));
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}
.user-table td {
  padding: 8px 12px;
  color: var(--text-primary, #f1f5f9);
  border-bottom: 1px solid var(--border-ultra, rgba(255,255,255,0.03));
}
.user-table tr:hover td {
  background: var(--glass-thin, rgba(255,255,255,0.03));
}

/* --- Status dot --- */
.dot {
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--success, #22c55e);
  margin-right: 6px;
  vertical-align: middle;
  animation: dotPulse 2s ease-in-out infinite;
}
@keyframes dotPulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.5; }
}

/* --- Fix: pointer-events on decorative pseudo-elements --- */
.server-card::before {
  pointer-events: none;
}
.game-card::after {
  pointer-events: none;
}

/* --- Fix: notification overflow on small screens --- */
@media (max-width: 480px) {
  .notification {
    white-space: normal;
    max-width: 90vw;
    word-wrap: break-word;
  }
}

/* --- Fix: settings nav scroll indicator on mobile --- */
@media (max-width: 768px) {
  .settings-nav {
    position: relative;
  }
  .settings-nav::after {
    content: '';
    position: absolute;
    right: 0;
    top: 0;
    bottom: 0;
    width: 32px;
    background: linear-gradient(to right, transparent, var(--bg-main, #0a0a1a));
    pointer-events: none;
    border-radius: 0 var(--radius-sm, 8px) var(--radius-sm, 8px) 0;
  }
}

/* --- Fix: small button touch targets on mobile --- */
@media (max-width: 768px) and (hover: none) {
  .btn.sm {
    min-height: 36px;
    padding: 8px 14px;
  }
}

/* ============================================
   SYSTEM RAM BAR (Admin)
   ============================================ */
#stat-sys-ram-bar.warning {
  background: linear-gradient(90deg, var(--warning), var(--warning-light));
  box-shadow: 0 0 12px rgba(245, 158, 11, 0.4);
}
#stat-sys-ram-bar.danger {
  background: linear-gradient(90deg, var(--danger), var(--danger-light));
  box-shadow: 0 0 12px rgba(239, 68, 68, 0.4);
}

/* ============================================
   GLOBAL HORIZONTAL OVERFLOW PREVENTION (Web + App)
   ============================================ */
html {
  overflow-x: hidden;
}
body {
  overflow-x: hidden;
  max-width: 100%;
}
#dashboard {
  overflow-x: hidden;
  max-width: 100%;
}
.main-content {
  overflow-x: hidden;
}
.header {
  overflow-x: hidden;
}
.header-user {
  flex-wrap: wrap;
  max-width: 100%;
}

/* --- Fix: search box overflow --- */
.search-box {
  min-width: 0;
  width: 100%;
}

/* --- Fix: shop card featured ribbon overflow --- */
.shop-card.featured::before {
  right: -28px;
}
.shop-card {
  overflow: hidden;
}

/* --- Fix: hero section wrap properly --- */
.hero-section {
  min-width: 0;
}

/* --- Fix: server grid min-width --- */
.server-grid {
  min-width: 0;
  width: 100%;
}

/* --- Fix: games grid min-width --- */
.games-grid {
  min-width: 0;
  width: 100%;
}

/* --- Fix: shop grid min-width --- */
.shop-grid {
  min-width: 0;
  width: 100%;
}

/* --- Fix: settings content overflow --- */
.settings-content {
  overflow-x: hidden;
  min-width: 0;
}

/* --- Fix: console-box overflow --- */
.console-box {
  overflow-x: auto;
  word-break: break-all;
  white-space: pre-wrap;
}

/* --- Fix: tables on small screens --- */
.players-table {
  width: 100%;
  table-layout: fixed;
}

/* --- Fix: admin stats grid responsive --- */
@media (max-width: 480px) {
  #tab-admin .card > div[style*="grid-template-columns"] {
    grid-template-columns: 1fr 1fr !important;
  }
}

/* --- Fix: admin forms overflow on small screens --- */
@media (max-width: 768px) {
  #tab-admin .card form[style*="flex-wrap"] {
    flex-direction: column;
  }
  #tab-admin .card form[style*="flex-wrap"] .form-group {
    min-width: 0 !important;
    width: 100%;
  }
  #tab-admin .card form[style*="flex-wrap"] button[type="submit"] {
    width: 100%;
  }
}

/* --- Fix: notification dropdown fixed width on mobile --- */
@media (max-width: 480px) {
  #notif-dropdown {
    width: calc(100vw - 16px) !important;
    left: 8px !important;
    right: 8px !important;
  }
}

/* ======================================================
   MAINTENANCE SCREEN
   ====================================================== */
#maintenance-screen {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 9999;
  background: var(--bg-primary);
  align-items: center;
  justify-content: center;
  padding: 24px;
}
.maint-card {
  max-width: 420px;
  width: 100%;
  text-align: center;
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius);
  padding: 48px 32px;
  box-shadow: var(--shadow-lg);
}
.maint-icon { font-size: 52px; margin-bottom: 16px; }
.maint-card h1 {
  font-size: 24px;
  font-weight: 700;
  margin-bottom: 12px;
  color: var(--text-primary);
}
.maint-card p {
  font-size: 14px;
  line-height: 1.7;
  color: var(--text-secondary);
  margin-bottom: 16px;
}
.maint-note {
  font-size: 12px;
  color: var(--text-muted);
  line-height: 1.6;
}
@media (max-width: 480px) {
  .maint-card { padding: 32px 20px; }
  .maint-icon { font-size: 40px; }
  .maint-card h1 { font-size: 20px; }
  .maint-card p { font-size: 13px; }
}

/* ======================================================
   NEWS TICKER: responsive + light theme
   ====================================================== */
#news-ticker {
  font-size: clamp(13px, 1.1vw, 14px);
  line-height: 38px;
  min-height: 36px;
}
[data-theme="light"] #news-ticker {
  background: rgba(16, 185, 129, 0.06);
}
@media (max-width: 640px) {
  #news-ticker {
    font-size: 13px;
    line-height: 40px;
    padding: 0 12px;
  }
  #news-ticker-track { padding-right: 40px; }
}

/* ======================================================
   LOADING SPINNER
   ====================================================== */
.loading-wrap {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 20px;
  color: var(--text-muted);
  font-size: 13px;
}
.spinner {
  width: 20px;
  height: 20px;
  border: 2px solid var(--border-color);
  border-top-color: var(--accent);
  border-radius: 50%;
  animation: spin .6s linear infinite;
  flex-shrink: 0;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ======================================================
   COPY CHIPS (Settings IP / Port)
   ====================================================== */
.copy-chip {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: var(--glass-thick);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-xs);
  padding: 4px 10px;
  font-size: 12px;
  color: var(--text-secondary);
  cursor: pointer;
  transition: background .15s, border-color .15s;
  user-select: all;
}
.copy-chip:hover { background: var(--glass-heavy); border-color: var(--accent-border); }
@media (max-width: 480px) {
  .copy-chip { font-size: 11px; padding: 4px 8px; }
}

/* ======================================================
   PLAYER COUNT BADGE (Server Card & Settings)
   ====================================================== */
.player-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 12px;
  color: var(--text-muted);
}
.player-badge .dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent);
  flex-shrink: 0;
}

/* ======================================================
   DESKTOP: Alle zu kleinen Elemente vergrößern
   ====================================================== */

/* ======================================================
   ADMIN-TAB: 2-spaltiges Desktop-Layout (nur >=1200px)
   Statistiken + Bestellungen direkt über dem Fold
   ====================================================== */

/* ======================================================
   MOBILE: Touch-optimierte Größen (min-height 44px)
   ====================================================== */
@media (max-width: 768px) {
  /* Buttons: nie kleiner als 14px + 44px touch target */
  .btn { font-size: 14px !important; min-height: 44px; }
  .btn.sm { font-size: 13px !important; padding: 8px 14px !important; min-height: 36px; }

  /* Server-Actions Buttons */
  .server-actions .btn { min-height: 42px; font-size: 13px !important; padding: 10px 14px !important; }

  /* App-Mode (WebView): größere Touch-Ziele beibehalten (überschreibt alte Regeln) */
  body.app-mode .btn { font-size: 15px !important; min-height: 48px; }
  body.app-mode .btn.sm { font-size: 14px !important; min-height: 42px; padding: 10px 16px; }
  body.app-mode .input { font-size: 16px !important; min-height: 50px; }
  body.app-mode .server-actions .btn { font-size: 14px !important; min-height: 48px; }
  body.app-mode .settings-actions .btn { font-size: 14px !important; min-height: 44px; }
  body.app-mode .server-name { font-size: 18px !important; }
  body.app-mode .status-indicator { font-size: 13px !important; }
  body.app-mode .info-item { font-size: 13px !important; }
}

@media (max-width: 480px) {
  /* Buttons: nie kleiner als 13px */
  .btn { font-size: 14px !important; min-height: 44px; padding: 10px 18px !important; }
  .btn.sm { font-size: 13px !important; padding: 8px 14px !important; min-height: 38px; }

  /* Server-Actions: komplette Breite, gut lesbar */
  .server-actions .btn { font-size: 13px !important; padding: 10px 14px !important; min-height: 42px; }

  /* Settings Buttons */
  .settings-actions .btn { font-size: 13px !important; padding: 8px 14px !important; min-height: 38px; }

  /* Status Indicator */
  .status-indicator { font-size: 12px !important; }

  /* Inputs */
  .input { font-size: 16px !important; min-height: 48px; }

  /* Server Name in Card */
  .server-name { font-size: 17px !important; }

  /* Settings Header */
  #settings-server-name { font-size: 20px !important; }
  .section-header h2 { font-size: 18px !important; }

  /* Admin Panel */
  #tab-admin .btn.sm { font-size: 13px !important; min-height: 38px; padding: 8px 14px !important; }
  #tab-admin .card form[style*="flex-wrap"] .form-group { min-width: 120px; }
}

/* ======================================================
   LIGHT THEME NEWS TICKER TEXT COLOR FIX
   ====================================================== */
[data-theme="light"] .news-ticker-text { color: var(--text-primary); }

/* ==================================================================
   DESKTOP LAYER (min-width: 769px) — automatisch aus Basis generiert
   Mobile/App unverändert; hier wird jede Basis-Regel skaliert
   ================================================================== */
@media (min-width: 769px) {
.login-box {

  width: 100%;
  max-width: 420px;
  background: var(--glass-medium);
  backdrop-filter: var(--blur-medium);
  border: 1px solid var(--border-thin);
  border-radius: var(--radius);
  padding: 50px 40px;
  box-shadow: var(--shadow-lg), var(--shadow-glow);

}
.logo {

  text-align: center;
  margin-bottom: 40px;
  position: relative;

}
.logo-icon-wrap {

  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 80px;
  height: 80px;
  border-radius: 50%;
  background: radial-gradient(circle at 30% 30%, rgba(16,185,129,0.2), rgba(16,185,129,0.05));
  border: 1px solid rgba(16,185,129,0.2);
  margin-bottom: 20px;
  box-shadow: 0 0 40px rgba(16,185,129,0.15), inset 0 0 30px rgba(16,185,129,0.05);

}
.logo h1 {

  font-size: 40px;
  font-weight: 700;
  letter-spacing: -1px;
  color: var(--text-primary);

}
.logo p {

  color: var(--text-muted);
  font-size: 18px;
  margin-top: 5px;
  letter-spacing: 0.5px;

}
/* Tab Switch */
.tab-switch {

  display: flex;
  gap: 10px;
  margin-bottom: 30px;
  background: var(--glass-thin);
  border-radius: var(--radius-sm);
  padding: 5px;

}
.tab-switch .btn {

  flex: 1;
  padding: 13px;
  border: none;
  background: transparent;
  color: var(--text-muted);
  font-size: 18px;
  font-weight: 500;
  border-radius: var(--radius-xs);
  transition: var(--transition);

}
/* Form */
.form-group {

  margin-bottom: 20px;

}
.form-group label {

  display: block;
  font-size: 16px;
  font-weight: 600;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 8px;

}
.input {

  width: 100%;
  padding: 15px 20px;
  background: var(--glass-thin);
  border: 1px solid var(--border-thin);
  border-radius: var(--radius-xs);
  color: var(--text-primary);
  font-size: 18px;
  transition: var(--transition);
  outline: none;

}
select.input, select {

  appearance: none;
  -webkit-appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath fill='%23888' d='M6 8L0 0h12z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  padding-right: 44px;
  cursor: pointer;

}
select option {

  background: #1a1a2e;
  color: #e0e0e0;
  padding: 10px 15px;

}
.login-error {

  color: var(--danger);
  font-size: 17px;
  margin-top: 15px;
  text-align: center;
  min-height: 20px;

}
/* Buttons */
.btn {

  padding: 13px 26px;
  border: 1px solid var(--border-medium);
  border-radius: var(--radius-xs);
  background: var(--glass-medium);
  color: var(--text-primary);
  font-size: 18px;
  font-weight: 500;
  cursor: pointer;
  transition: var(--transition);
  backdrop-filter: var(--blur-soft);

}
.btn.sm {

  padding: 8px 15px;
  font-size: 16px;

}
/* Header */
.header {

  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 15px 30px;
  background: var(--header-bg);
  backdrop-filter: var(--blur-medium);
  border-bottom: 1px solid var(--border-ultra);
  position: sticky;
  top: 0;
  z-index: 100;
  flex-wrap: wrap;
  gap: 10px;

}
.header-brand {

  display: flex;
  align-items: center;
  gap: 13px;

}
.header-brand h1 {

  font-size: 25px;
  font-weight: 700;
  letter-spacing: -0.5px;
  text-shadow: 0 0 16px rgba(110,231,183,0.2);

}
.header-user {

  display: flex;
  align-items: center;
  gap: 15px;

}
.username {

  font-size: 18px;
  font-weight: 500;
  color: var(--text-primary);

}
.role-badge {

  font-size: 14px;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: 100px;
  letter-spacing: 0.5px;
  text-transform: uppercase;

}
.theme-toggle {

  width: 36px;
  height: 36px;
  border: 1px solid var(--border-thin);
  border-radius: 50%;
  background: var(--glass-thin);
  cursor: pointer;
  font-size: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);

}
.cart-btn {

  position: relative;
  width: 36px;
  height: 36px;
  border: 1px solid var(--border-thin);
  border-radius: 50%;
  background: var(--glass-thin);
  cursor: pointer;
  font-size: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);

}
.cart-badge {

  position: absolute;
  top: -4px;
  right: -4px;
  background: var(--accent);
  color: white;
  font-size: 14px;
  font-weight: 700;
  min-width: 18px;
  height: 18px;
  border-radius: 9px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 5px;

}
/* Navigation */
.nav-tabs {

  display: flex;
  gap: 5px;
  padding: 10px 30px;
  background: var(--bg-secondary);
  border-bottom: 1px solid var(--border-ultra);

}
.nav-tab {

  padding: 13px 26px;
  border: none;
  background: transparent;
  color: var(--text-muted);
  font-size: 18px;
  font-weight: 500;
  cursor: pointer;
  border-radius: var(--radius-xs);
  transition: var(--transition);
  position: relative;

}
/* Main Content */
.main-content {

  flex: 1;
  padding: 30px;
  max-width: 1400px;
  width: 100%;
  margin: 0 auto;

}
/* Section Header */
.section-header {

  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 30px;
  flex-wrap: wrap;
  gap: 20px;

}
.section-header h2 {

  font-size: 30px;
  font-weight: 700;
  letter-spacing: -0.5px;

}
/* Hero Section */
.hero-section {

  background: var(--glass-medium);
  backdrop-filter: var(--blur-soft);
  border: 1px solid var(--border-thin);
  border-radius: var(--radius);
  padding: 40px;
  margin-bottom: 30px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 30px;
  background-image: 
    radial-gradient(ellipse at 0% 100%, rgba(16, 185, 129, 0.1) 0%, transparent 50%),
    radial-gradient(ellipse at 100% 0%, rgba(59, 130, 246, 0.08) 0%, transparent 50%);

}
.hero-text h2 {

  font-size: 34px;
  font-weight: 700;
  margin-bottom: 10px;
  letter-spacing: -0.5px;

}
.hero-text p {

  color: var(--text-secondary);
  font-size: 18px;

}
.hero-stats {

  display: flex;
  gap: 30px;

}
.hero-stat-value {

  font-size: 30px;
  font-weight: 700;
  color: var(--accent);

}
.hero-stat-label {

  font-size: 15px;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;

}
/* Stats Grid */
.stats-grid {

  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 20px;
  margin-bottom: 30px;

}
.stat-card {

  background: var(--glass-medium);
  backdrop-filter: var(--blur-soft);
  border: 1px solid var(--border-thin);
  border-radius: var(--radius-sm);
  padding: 26px;
  transition: var(--transition);

}
.stat-label {

  font-size: 16px;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 10px;

}
.stat-value {

  font-size: 34px;
  font-weight: 700;
  color: var(--text-primary);

}
/* Server Grid */
.server-grid {

  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 26px;

}
.server-card {

  background: var(--glass-medium);
  backdrop-filter: var(--blur-soft);
  border: 1px solid var(--border-thin);
  border-radius: var(--radius);
  padding: 30px;
  transition: var(--transition);
  cursor: default;
  position: relative;
  overflow: hidden;

}
.server-card-header {

  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;

}
.server-name {

  font-size: 22px;
  font-weight: 600;

}
.server-edition {

  font-size: 15px;
  font-weight: 600;
  padding: 5px 13px;
  border-radius: 100px;
  text-transform: uppercase;
  letter-spacing: 0.5px;

}
.status-indicator {

  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 16px;
  font-weight: 500;
  padding: 5px 13px;
  border-radius: 100px;

}
.server-info {

  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 15px;
  margin-bottom: 20px;

}
.server-info-item {

  display: flex;
  flex-direction: column;
  gap: 3px;

}
.server-info-label {

  font-size: 15px;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;

}
.server-info-value {

  font-size: 18px;
  font-weight: 500;
  color: var(--text-primary);

}
.server-actions {

  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 20px;
  padding-top: 20px;
  border-top: 1px solid var(--border-ultra);

}
.search-box .input {

  padding-left: 50px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='18' height='18' fill='%239ca3af' viewBox='0 0 16 16'%3E%3Cpath d='M11.742 10.344a6.5 6.5 0 1 0-1.397 1.398h-.001l3.85 3.85a1 1 0 0 0 1.415-1.414l-3.85-3.85zm-5.44.156a5 5 0 1 1 0-10 5 5 0 0 1 0 10z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: 14px center;
  background-size: 18px;

}
.games-grid {

  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 26px;
  margin-top: 30px;

}
.game-card {

  background: var(--glass-medium);
  backdrop-filter: var(--blur-soft);
  border: 1px solid var(--border-thin);
  border-radius: var(--radius);
  padding: 30px;
  cursor: pointer;
  transition: var(--transition);
  text-align: center;
  position: relative;
  overflow: hidden;

}
.game-card-icon {

  font-size: 56px;
  margin-bottom: 20px;
  display: block;
  filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.3));

}
.game-card-name {

  font-size: 20px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 8px;

}
.game-card-desc {

  font-size: 16px;
  color: var(--text-muted);
  line-height: 1.4;

}
/* Shop Grid */
.shop-intro {

  color: var(--text-secondary);
  font-size: 18px;
  margin-bottom: 30px;
  padding: 20px;
  background: var(--glass-thin);
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-ultra);

}
.shop-grid {

  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 26px;

}
.shop-card {

  background: var(--glass-medium);
  backdrop-filter: var(--blur-soft);
  border: 1px solid var(--border-thin);
  border-radius: var(--radius);
  padding: 30px;
  transition: var(--transition);
  position: relative;
  overflow: hidden;

}
.shop-card.featured::before {

  content: 'EMPFOHLEN';
  position: absolute;
  top: 12px;
  right: -32px;
  background: var(--accent-gradient);
  color: white;
  font-size: 14px;
  font-weight: 700;
  padding: 5px 50px;
  transform: rotate(45deg);
  letter-spacing: 0.5px;

}
.shop-card h3 {

  font-size: 25px;
  font-weight: 700;
  margin-bottom: 10px;

}
.shop-card .price {

  font-size: 40px;
  font-weight: 700;
  color: var(--accent);
  margin-bottom: 20px;

}
.shop-card .price-period {

  font-size: 18px;
  color: var(--text-muted);
  font-weight: 400;

}
.shop-specs {

  list-style: none;
  margin-bottom: 26px;

}
.shop-specs li {

  padding: 10px 0;
  font-size: 17px;
  color: var(--text-secondary);
  border-bottom: 1px solid var(--border-ultra);
  display: flex;
  align-items: center;
  gap: 10px;

}
/* Settings */
.settings-header {

  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 30px;
  flex-wrap: wrap;
  gap: 20px;

}
.settings-header h2 {

  font-size: 25px;
  font-weight: 600;

}
.settings-actions {

  display: flex;
  align-items: center;
  gap: 15px;

}
.settings-nav {

  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  margin-bottom: 30px;
  background: var(--glass-thin);
  border-radius: var(--radius-sm);
  padding: 5px;

}
.settings-tab {

  padding: 13px 20px;
  border: none;
  background: transparent;
  color: var(--text-muted);
  font-size: 17px;
  font-weight: 500;
  cursor: pointer;
  border-radius: var(--radius-xs);
  transition: var(--transition);
  white-space: nowrap;

}
.settings-content {

  background: var(--glass-medium);
  backdrop-filter: var(--blur-soft);
  border: 1px solid var(--border-thin);
  border-radius: var(--radius);
  padding: 30px;

}
.config-section {

  margin-bottom: 30px;
  padding-bottom: 30px;
  border-bottom: 1px solid var(--border-ultra);

}
.config-section h3 {

  font-size: 18px;
  font-weight: 600;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 20px;

}
.form-row {

  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;

}
/* Stats Overview */
.stats-overview {

  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 20px;
  margin-bottom: 30px;

}
.stat-item {

  background: var(--glass-thin);
  border: 1px solid var(--border-ultra);
  border-radius: var(--radius-sm);
  padding: 20px;

}
.stat-header {

  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 10px;

}
.stat-label-text {

  font-size: 16px;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;

}
.stat-value-text {

  font-size: 18px;
  font-weight: 600;
  color: var(--text-primary);

}
/* Console */
.console-box {

  background: var(--console-bg);
  border: 1px solid var(--border-thin);
  border-radius: var(--radius-sm);
  padding: 20px;
  height: 400px;
  overflow-y: auto;
  font-family: 'SF Mono', 'Fira Code', monospace;
  font-size: 16px;
  line-height: 1.6;
  color: var(--text-primary);

}
/* Cards */
.card {

  background: var(--glass-medium);
  backdrop-filter: var(--blur-soft);
  border: 1px solid var(--border-thin);
  border-radius: var(--radius);
  padding: 30px;
  margin-bottom: 26px;

}
/* Empty State */
.empty-list {

  text-align: center;
  padding: 60px 30px;
  color: var(--text-muted);
  font-size: 18px;

}
#users-list th, #pending-orders th {

  text-align: left;
  padding: 13px 15px;
  font-size: 15px;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  border-bottom: 1px solid var(--border-thin);

}
#users-list td, #pending-orders td {

  padding: 15px;
  font-size: 17px;
  border-bottom: 1px solid var(--border-ultra);

}
/* Notifications */
.notification {

  position: fixed;
  top: 20px;
  left: 50%;
  transform: translateX(-50%);
  padding: 15px 26px;
  border-radius: var(--radius-xs);
  font-size: 18px;
  font-weight: 500;
  z-index: 1000;
  animation: slideDown 0.3s ease;
  backdrop-filter: var(--blur-soft);
  white-space: nowrap;

}
/* Avatar */
.avatar-small {

  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--accent);
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 600;
  font-size: 18px;

}
.avatar-large {

  width: 80px;
  height: 80px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--accent), var(--accent-hover));
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 600;
  font-size: 40px;
  border: 3px solid var(--border);

}
.notification-bell {

  position: relative;
  width: 36px;
  height: 36px;
  border: 1px solid var(--border-thin);
  border-radius: 50%;
  background: var(--glass-thin);
  cursor: pointer;
  font-size: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);

}
.players-table {

  width: 100%;
  border-collapse: collapse;
  font-size: 16px;

}
.players-table th {

  text-align: left;
  padding: 8px 10px;
  color: var(--text-muted);
  border-bottom: 1px solid var(--border-thin);
  font-weight: 500;

}
.players-table td {

  padding: 8px 10px;
  border-bottom: 1px solid var(--border-ultra);
  color: var(--text-primary);

}
/* Bottom Navigation Bar (nur App/ Mobile) */
.mobile-bottom-nav {

  display: none;
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  height: 64px;
  background: rgba(10, 10, 15, 0.95);
  backdrop-filter: blur(20px) saturate(1.5);
  -webkit-backdrop-filter: blur(20px) saturate(1.5);
  border-top: 1px solid var(--border-ultra);
  z-index: 200;
  padding: 0 10px;
  align-items: center;
  justify-content: space-around;
  padding-bottom: 0;

}
.mobile-nav-item {

  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  padding: 8px 15px;
  border: none;
  background: transparent;
  color: var(--text-muted);
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  border-radius: 12px;
  transition: all 0.2s ease;
  min-width: 56px;
  -webkit-tap-highlight-color: transparent;
  position: relative;

}
.mobile-nav-item .nav-icon {

  font-size: 26px;
  line-height: 1;
  transition: all 0.2s ease;

}
/* ============================================
   APP MODE ENHANCEMENTS (detected via JS)
   ============================================ */

/* --- App Mode: Settings tabs scrollable with bigger touch targets --- */
body.app-mode .settings-nav {

  gap: 8px;
  padding: 5px 0;
  -webkit-overflow-scrolling: touch;
  overflow-x: auto;
  -ms-overflow-style: none;
  scrollbar-width: none;

}
body.app-mode .settings-tab {

  padding: 13px 20px;
  font-size: 17px;
  white-space: nowrap;
  min-height: 40px;
  border-radius: 10px;
  flex-shrink: 0;

}
/* --- App Mode: Config form inputs bigger --- */
body.app-mode .config-section .input,
body.app-mode .config-section select {

  min-height: 48px;
  font-size: 20px;
  padding: 15px 18px;
  width: 100%;
  box-sizing: border-box;

}
body.app-mode .config-section label {

  font-size: 17px;
  margin-bottom: 8px;

}
/* --- App Mode: Server card badges row wrap --- */
body.app-mode .edition-badge,
body.app-mode .badge-danger,
body.app-mode .badge-warning,
body.app-mode .badge {

  font-size: 9px;
  padding: 3px 8px;

}
body.app-mode .server-card > .edition-badge,
body.app-mode .server-card > .badge-danger,
body.app-mode .server-card > .badge-warning,
body.app-mode .server-card > .badge {

  margin-bottom: 8px;

}
/* --- App Mode: Server info items --- */
body.app-mode .info-item {

  font-size: 17px;
  padding: 10px 0;
  word-break: break-word;

}
body.app-mode .copy-ip {

  font-size: 16px;

}
/* --- App Mode: Server actions — 2-column grid --- */
body.app-mode .server-actions {

  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;

}
body.app-mode .server-actions .btn {

  width: 100%;
  justify-content: center;
  min-height: 44px;
  font-size: 17px;

}
/* --- App Mode: Header compact --- */
body.app-mode .header {

  padding: 10px 15px;
  gap: 8px;

}
body.app-mode .header-user {

  gap: 8px;

}
body.app-mode .cart-btn,
body.app-mode .notification-bell {

  font-size: 22px;
  padding: 5px;

}
body.app-mode .header-user [download] {

  padding: 6px 13px;
  font-size: 15px;
  gap: 4px;

}
/* --- App Mode: Backup/Plugin cards --- */
body.app-mode .backup-card,
body.app-mode .plugin-card,
body.app-mode .mod-card {

  padding: 18px;
  gap: 18px;

}
body.app-mode .backup-actions,
body.app-mode .plugin-actions,
body.app-mode .mod-actions {

  flex-direction: row;
  gap: 10px;

}
/* --- App Mode: Pending orders --- */
body.app-mode .pending-order {

  flex-direction: column;
  align-items: flex-start;
  gap: 13px;

}
/* --- App Mode: Hero kompakt --- */
body.app-mode .hero-section {

  flex-direction: column;
  align-items: flex-start;
  padding: 15px 20px;
  gap: 10px;
  margin-bottom: 20px;

}
body.app-mode .hero-text p {

  font-size: 15px;
  margin: 3px 0 0 0;
  color: var(--text-secondary);

}
body.app-mode .hero-stats {

  display: flex;
  gap: 8px;
  width: 100%;

}
body.app-mode .hero-stat {

  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  padding: 8px 0;
  background: var(--accent-dim);
  border: 1px solid var(--accent-border);
  border-radius: 8px;

}
body.app-mode .hero-stat-value {

  font-size: 18px;
  font-weight: 700;
  color: var(--accent);
  line-height: 1;

}
body.app-mode .hero-stat-label {

  font-size: 14px;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.3px;

}
/* --- Edition badges on server cards --- */
.edition-badge {

  display: inline-block;
  padding: 3px 10px;
  border-radius: 4px;
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  vertical-align: middle;
  line-height: 1.4;

}
/* --- Status badges (expired, warning, etc.) --- */
.badge, .badge-danger, .badge-warning {

  display: inline-block;
  padding: 4px 10px;
  border-radius: 4px;
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.3px;
  text-transform: uppercase;
  line-height: 1.4;

}
/* --- Server info items --- */
.info-item {

  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 0;
  font-size: 16px;
  color: var(--text-secondary, #94a3b8);
  border-bottom: 1px solid var(--border-ultra, rgba(255,255,255,0.03));

}
/* --- Copy-able IP --- */
.copy-ip {

  cursor: pointer;
  color: var(--accent, #3b82f6);
  font-family: 'SF Mono', 'Cascadia Code', monospace;
  font-size: 16px;
  transition: color 0.2s;

}
/* --- Game category headers --- */
.game-category-header {

  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 0 15px 0;
  border-bottom: 1px solid var(--border-ultra, rgba(255,255,255,0.03));
  margin-bottom: 20px;

}
.game-category-header .badge {

  margin-left: 10px;

}
/* --- Plugin & Mod cards --- */
.plugin-card, .mod-card {

  background: var(--glass-thin, rgba(255,255,255,0.04));
  border: 1px solid var(--border-thin, rgba(255,255,255,0.08));
  border-radius: var(--radius-sm, 8px);
  padding: 15px;
  display: flex;
  gap: 15px;
  align-items: flex-start;
  transition: border-color 0.2s, background 0.2s;

}
.plugin-icon, .mod-icon {

  width: 40px;
  height: 40px;
  min-width: 40px;
  border-radius: var(--radius-xs, 6px);
  background: var(--bg-main, #0a0a1a);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 25px;
  overflow: hidden;

}
.plugin-title, .mod-title {

  font-size: 17px;
  font-weight: 600;
  color: var(--text-primary, #f1f5f9);
  margin-bottom: 3px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;

}
.plugin-desc, .mod-desc {

  font-size: 15px;
  color: var(--text-muted, #64748b);
  line-height: 1.4;
  margin-bottom: 5px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;

}
.plugin-meta, .mod-meta {

  font-size: 14px;
  color: var(--text-muted, #64748b);

}
.plugin-actions, .mod-actions {

  display: flex;
  flex-direction: column;
  gap: 5px;
  align-items: flex-end;
  min-width: 80px;

}
/* --- Backup cards --- */
.backup-card {

  background: var(--glass-thin, rgba(255,255,255,0.04));
  border: 1px solid var(--border-thin, rgba(255,255,255,0.08));
  border-radius: var(--radius-sm, 8px);
  padding: 15px;
  display: flex;
  align-items: center;
  gap: 15px;
  margin-bottom: 10px;

}
.backup-icon {

  width: 36px;
  height: 36px;
  min-width: 36px;
  border-radius: var(--radius-xs, 6px);
  background: rgba(99, 102, 241, 0.1);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;

}
.backup-name {

  font-size: 17px;
  font-weight: 600;
  color: var(--text-primary, #f1f5f9);

}
.backup-meta {

  font-size: 15px;
  color: var(--text-muted, #64748b);

}
.backup-actions {

  display: flex;
  gap: 8px;
  align-items: center;

}
/* --- Pending orders (admin) --- */
.pending-order {

  background: var(--glass-thin, rgba(255,255,255,0.04));
  border: 1px solid var(--border-thin, rgba(255,255,255,0.08));
  border-radius: var(--radius-sm, 8px);
  padding: 15px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
  gap: 15px;

}
.order-info {

  flex: 1;
  min-width: 0;
  font-size: 16px;
  color: var(--text-secondary, #94a3b8);

}
.order-actions {

  display: flex;
  gap: 8px;
  align-items: center;

}
/* --- Payment dialog --- */
.payment-info-box {

  background: var(--bg-main, #0a0a1a);
  border: 1px solid var(--border-thin, rgba(255,255,255,0.08));
  border-radius: var(--radius-sm, 8px);
  padding: 20px;
  margin: 15px 0;

}
.payment-row {

  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 0;
  font-size: 17px;

}
/* --- User/Coupon tables --- */
.user-table {

  width: 100%;
  border-collapse: collapse;
  font-size: 16px;

}
.user-table th {

  text-align: left;
  padding: 10px 15px;
  font-weight: 600;
  color: var(--text-secondary, #94a3b8);
  border-bottom: 1px solid var(--border-ultra, rgba(255,255,255,0.05));
  font-size: 15px;
  text-transform: uppercase;
  letter-spacing: 0.5px;

}
.user-table td {

  padding: 10px 15px;
  color: var(--text-primary, #f1f5f9);
  border-bottom: 1px solid var(--border-ultra, rgba(255,255,255,0.03));

}
/* --- Status dot --- */
.dot {

  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--success, #22c55e);
  margin-right: 8px;
  vertical-align: middle;
  animation: dotPulse 2s ease-in-out infinite;

}
/* ======================================================
   MAINTENANCE SCREEN
   ====================================================== */
#maintenance-screen {

  display: none;
  position: fixed;
  inset: 0;
  z-index: 9999;
  background: var(--bg-primary);
  align-items: center;
  justify-content: center;
  padding: 30px;

}
.maint-card {

  max-width: 420px;
  width: 100%;
  text-align: center;
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius);
  padding: 60px 40px;
  box-shadow: var(--shadow-lg);

}
.maint-icon {
 font-size: 60px; margin-bottom: 20px; 
}
.maint-card h1 {

  font-size: 30px;
  font-weight: 700;
  margin-bottom: 15px;
  color: var(--text-primary);

}
.maint-card p {

  font-size: 18px;
  line-height: 1.7;
  color: var(--text-secondary);
  margin-bottom: 20px;

}
.maint-note {

  font-size: 16px;
  color: var(--text-muted);
  line-height: 1.6;

}
/* ======================================================
   LOADING SPINNER
   ====================================================== */
.loading-wrap {

  display: flex;
  align-items: center;
  gap: 13px;
  padding: 26px;
  color: var(--text-muted);
  font-size: 17px;

}
/* ======================================================
   COPY CHIPS (Settings IP / Port)
   ====================================================== */
.copy-chip {

  display: inline-flex;
  align-items: center;
  gap: 5px;
  background: var(--glass-thick);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-xs);
  padding: 5px 13px;
  font-size: 16px;
  color: var(--text-secondary);
  cursor: pointer;
  transition: background .15s, border-color .15s;
  user-select: all;

}
/* ======================================================
   PLAYER COUNT BADGE (Server Card & Settings)
   ====================================================== */
.player-badge {

  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 16px;
  color: var(--text-muted);

}
}
/* ==================================================================
   DESKTOP TAIL: JS-Inline-Styles + Admin-Spezial (nur >=769px)
   ================================================================== */
@media (min-width: 769px) {
  /* Inline font-size aus app.js/index.html auf Desktop vergrößern */
  [style*="font-size: 10px"], [style*="font-size:10px"] { font-size: 14px !important; }
  [style*="font-size: 11px"], [style*="font-size:11px"] { font-size: 15px !important; }
  [style*="font-size: 12px"], [style*="font-size:12px"] { font-size: 16px !important; }
  [style*="font-size: 13px"], [style*="font-size:13px"] { font-size: 17px !important; }
  [style*="font-size: 14px"], [style*="font-size:14px"] { font-size: 18px !important; }
  [style*="font-size: 15px"], [style*="font-size:15px"] { font-size: 19px !important; }
  [style*="font-size: 16px"], [style*="font-size:16px"] { font-size: 20px !important; }

  /* Suche */
  .search-box { min-width: 220px; max-width: 340px; }
}

/* --bg-main: wurde in etlichen Inline-Styles verwendet, aber nie definiert
   -> alle var(--bg-main) Boxen waren transparent (sichtbar als Schwarz).
   Korrekte Definition nachtragen (dark default + light override). */
:root {
  --bg-main: #0f0f15;
}
[data-theme="light"] {
  --bg-main: #ffffff;
}

/* ======================================================
   ADMIN PANEL — komplett neu aufgebaut
   Solide Flächen, kompaktes Raster, direkter Zugriff.
   ====================================================== */
#tab-admin {
  background: var(--bg-primary) !important;
}
.adm-shell {
  display: grid;
  gap: 14px;
}

.adm-head {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}
.adm-head-title {
  font-size: 18px;
  font-weight: 800;
  letter-spacing: 0.2px;
  flex: 1;
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 200px;
}
.adm-sub {
  font-size: 12px;
  font-weight: 500;
  color: var(--text-muted);
}

/* Kennzahlen-Streifen */
.adm-kpis {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
}
.adm-kpi {
  background: var(--bg-tertiary);
  border: 1px solid var(--border-medium);
  border-radius: 12px;
  padding: 10px 12px;
  text-align: center;
}
.adm-kpi b {
  display: block;
  font-size: 20px;
  font-weight: 800;
  color: var(--accent);
  line-height: 1.2;
}
.adm-kpi span {
  display: block;
  font-size: 11px;
  color: var(--text-muted);
  margin-top: 2px;
}

/* Funktions-Raster */
.adm-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
}

.adm-card {
  background: var(--bg-tertiary);
  border: 1px solid var(--border-medium);
  border-radius: 14px;
  padding: 16px 18px;
  box-shadow: var(--shadow-sm);
  align-self: stretch;
}
.adm-h {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 14px;
}
.adm-ic {
  width: 32px;
  height: 32px;
  border-radius: 9px;
  background: var(--bg-secondary);
  border: 1px solid var(--border-medium);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  flex-shrink: 0;
}
.adm-h h3 {
  font-size: 14px;
  font-weight: 700;
  margin: 0;
  flex: 1;
}

/* Buttons: neue Administration-Buttons */
.adm-btn {
  appearance: none;
  border: 1px solid var(--border-strong);
  background: var(--bg-secondary);
  color: var(--text-primary);
  border-radius: 9px;
  padding: 8px 14px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: filter 0.15s, transform 0.1s;
  white-space: nowrap;
}
.adm-btn:hover { filter: brightness(1.15); }
.adm-btn:active { transform: translateY(1px); }
.adm-btn.primary {
  background: var(--accent-gradient);
  border: none;
  color: #fff;
}
.adm-btn.danger {
  background: #e05252;
  border: none;
  color: #fff;
}
.adm-btn.sm { padding: 5px 10px; font-size: 12px; border-radius: 7px; }

.adm-btnrow {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin: 10px 0;
}

/* Formulare: kompaktes Auto-Raster */
.adm-form {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(130px, 1fr));
  gap: 10px;
  align-items: end;
}
.adm-form .form-group { margin: 0; }
.adm-form label { font-size: 11px; }
.adm-form .adm-btn { margin-top: 0; }

/* System-RAM */
.adm-ramline {
  display: flex;
  align-items: baseline;
  gap: 8px;
  margin-bottom: 10px;
}
.adm-ramline b {
  font-size: 26px;
  font-weight: 800;
  color: var(--accent);
}
.adm-ramline span { font-size: 14px; color: var(--text-muted); }
.adm-gauge {
  height: 8px;
  background: var(--glass-thin);
  border-radius: 4px;
  overflow: hidden;
  margin-bottom: 10px;
}
.adm-gauge > div {
  height: 100%;
  width: 0%;
  background: var(--accent-gradient);
  border-radius: 4px;
  transition: width 0.6s ease;
}
.adm-gauge > div.danger { background: #e05252; }
.adm-gauge > div.warning { background: #f59e0b; }
.adm-ramfoot {
  display: flex;
  justify-content: space-between;
  font-size: 12px;
  color: var(--text-muted);
}
.adm-ramfoot b { color: var(--text-primary); }

@media (min-width: 769px) {
  .adm-kpis { grid-template-columns: repeat(6, 1fr); }
  .adm-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .adm-span2 { grid-column: 1 / -1; }
  .adm-card { padding: 18px 20px; }
}

/* ============================================================
   APP-MODE KLARHEIT / ÜBERSICHT (nur WebView/App, Web unverändert)
   ============================================================ */

/* Einheitlicher Seitenrand & Kartenrhythmus */
body.app-mode .main-content {
  padding: 12px 12px 24px;
}
body.app-mode .card {
  padding: 14px;
  border-radius: 14px;
}
body.app-mode .section-header {
  margin: 18px 2px 10px;
}
body.app-mode .section-header h2 {
  font-size: 18px;
}

/* Hero kompakt */
body.app-mode .hero-section {
  padding: 14px;
  gap: 10px;
  border-radius: 14px;
}
body.app-mode .hero-text h2 {
  font-size: 17px;
}
body.app-mode .hero-text p {
  font-size: 12px;
}
body.app-mode .hero-stat {
  padding: 10px 6px;
}
body.app-mode .hero-stat-value {
  font-size: 20px;
}
body.app-mode .hero-stat-label {
  font-size: 10px;
}

/* Server-Info: ruhiges Bild, Werte betont, IP als eigene Zeile */
body.app-mode .server-info {
  grid-template-columns: 1fr 1fr;
  gap: 10px 12px;
  font-size: 12px;
  line-height: 1.45;
}
body.app-mode .server-info .info-item {
  color: var(--text-muted);
  min-width: 0;
}
body.app-mode .server-info .info-item > span {
  color: var(--text-primary);
  font-weight: 600;
}
body.app-mode .server-info .info-item:has(.copy-ip) {
  grid-column: 1 / -1;
  background: var(--bg-main);
  border: 1px solid var(--border-ultra);
  border-radius: 10px;
  padding: 8px 10px;
}
body.app-mode .server-info .copy-ip {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 12px;
  word-break: break-all;
}

/* Server-Buttons: strenges Raster statt flotierender Zeilen */
body.app-mode .server-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}
body.app-mode .server-actions .btn {
  width: 100%;
  min-width: 0;
  flex: none;
  justify-content: center;
}
body.app-mode .server-actions .btn[title="Einstellungen"],
body.app-mode .server-actions .btn[title="Server teilen"],
body.app-mode .server-actions .btn.accent[onclick*="extendServer"],
body.app-mode .server-actions .btn.danger:last-child {
  grid-column: 1 / -1;
}

/* Admin-Kopf: kein Umbruch, klare Hierarchie */
body.app-mode .adm-head {
  flex-wrap: wrap;
  gap: 8px;
}
body.app-mode .adm-head-title {
  font-size: 20px;
}
body.app-mode .adm-sub {
  font-size: 11px;
}
body.app-mode .adm-kpis {
  gap: 8px;
}
body.app-mode .adm-kpi {
  padding: 10px 6px;
  border-radius: 12px;
}

/* Shop-Karten: Preis & CTA klarer */
body.app-mode .shop-card {
  padding: 16px;
  border-radius: 14px;
}
body.app-mode .shop-card .price {
  font-size: 26px;
}

/* Settings-Navigation als horizontale Chips */
body.app-mode .settings-nav {
  display: flex;
  overflow-x: auto;
  gap: 8px;
  padding-bottom: 6px;
  -webkit-overflow-scrolling: touch;
}
body.app-mode .settings-nav button,
body.app-mode .settings-nav .settings-nav-item {
  flex: 0 0 auto;
  min-height: 40px;
  border-radius: 999px;
  padding: 8px 14px;
  font-size: 12px;
}
