/* ============================================
   TROF System v2.0 — Dashboard Layout
   ============================================
   تخطيط لوحة التحكم الكامل
   يعتمد على tokens.css, base.css, layout.css, components.css
   ============================================ */

/* ==========================================
   🎯 DASHBOARD WRAPPER — الحاوية الأساسية
   ========================================== */

.dashboard-app {
  display: grid;
  grid-template-columns: var(--w-sidebar) 1fr;
  min-height: 100vh;
  min-height: 100dvh;
  background: var(--c-bg);
  transition: grid-template-columns var(--t-base) var(--ease);
  position: relative;
}

.dashboard-app.sidebar-collapsed {
  grid-template-columns: var(--w-sidebar-collapsed) 1fr;
}

.dashboard-app.sidebar-hidden {
  grid-template-columns: 1fr;
}

/* ==========================================
   🎯 SIDEBAR — الشريط الجانبي
   ========================================== */

.dash-sidebar {
  position: sticky;
  top: 0;
  height: 100vh;
  height: 100dvh;
  display: flex;
  flex-direction: column;
  background: var(--c-surface);
  border-inline-end: 1px solid var(--c-border);
  overflow: hidden;
  z-index: var(--z-sticky);
  transition: all var(--t-base) var(--ease);
}

/* ========== Sidebar Header ========== */

.dash-sidebar-header {
  display: flex;
  align-items: center;
  gap: var(--s-3);
  height: var(--h-topbar);
  padding-inline: var(--s-4);
  border-bottom: 1px solid var(--c-border);
  flex-shrink: 0;
  overflow: hidden;
}

.dash-sidebar-brand {
  display: flex;
  align-items: center;
  gap: var(--s-3);
  text-decoration: none;
  color: var(--c-text);
  flex: 1;
  min-width: 0;
  transition: var(--tr-colors);
}

.dash-sidebar-brand:hover {
  color: var(--c-primary-400);
}

.dash-sidebar-logo {
  width: 36px;
  height: 36px;
  border-radius: var(--r-circle);
  flex-shrink: 0;
  transition: transform var(--t-base) var(--ease);
}

.dash-sidebar-brand:hover .dash-sidebar-logo {
  transform: rotate(-8deg) scale(1.05);
}

.dash-sidebar-title {
  display: flex;
  flex-direction: column;
  gap: 1px;
  min-width: 0;
  overflow: hidden;
  transition: opacity var(--t-fast) var(--ease);
}

.dash-sidebar-name {
  font-size: var(--fs-base);
  font-weight: var(--fw-black);
  color: var(--c-text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  letter-spacing: var(--ls-tight);
}

.dash-sidebar-subtitle {
  font-size: var(--fs-2xs);
  color: var(--c-text-mut);
  text-transform: uppercase;
  letter-spacing: var(--ls-widest);
  white-space: nowrap;
}

/* ========== Sidebar Collapse Button ========== */

.dash-sidebar-collapse {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  background: transparent;
  border: 1px solid var(--c-border);
  border-radius: var(--r-sm);
  color: var(--c-text-mut);
  cursor: pointer;
  transition: var(--tr-fast);
  flex-shrink: 0;
}

.dash-sidebar-collapse:hover {
  color: var(--c-text);
  border-color: var(--c-border-hi);
  background: var(--c-surface-2);
}

.dash-sidebar-collapse svg {
  width: 14px;
  height: 14px;
  transition: transform var(--t-base) var(--ease);
}

.dashboard-app.sidebar-collapsed .dash-sidebar-collapse svg {
  transform: rotate(180deg);
}

/* ========== Sidebar Nav ========== */

.dash-sidebar-nav {
  flex: 1;
  padding: var(--s-4) var(--s-3);
  overflow-y: auto;
  overflow-x: hidden;
  display: flex;
  flex-direction: column;
  gap: var(--s-4);
  scrollbar-width: thin;
}

.dash-sidebar-nav::-webkit-scrollbar {
  width: 4px;
}

.dash-sidebar-nav::-webkit-scrollbar-thumb {
  background: var(--c-surface-3);
  border-radius: var(--r-full);
}

/* ========== Nav Section ========== */

.dash-nav-section {
  display: flex;
  flex-direction: column;
  gap: var(--s-1);
}

.dash-nav-label {
  padding: var(--s-2) var(--s-3);
  font-size: var(--fs-2xs);
  font-weight: var(--fw-bold);
  color: var(--c-text-dim);
  text-transform: uppercase;
  letter-spacing: var(--ls-widest);
  white-space: nowrap;
  overflow: hidden;
  transition: opacity var(--t-fast) var(--ease);
}

/* ========== Nav Item ========== */

.dash-nav-item {
  display: flex;
  align-items: center;
  gap: var(--s-3);
  padding: var(--s-3);
  border-radius: var(--r-md);
  color: var(--c-text-mut);
  font-size: var(--fs-sm);
  font-weight: var(--fw-medium);
  text-decoration: none;
  cursor: pointer;
  transition: var(--tr-base);
  position: relative;
  overflow: hidden;
  white-space: nowrap;
  border: none;
  background: transparent;
  width: 100%;
  text-align: start;
}

.dash-nav-item:hover {
  background: var(--c-surface-2);
  color: var(--c-text);
}

.dash-nav-item:focus-visible {
  outline: var(--focus-ring-width) solid var(--focus-ring-color);
  outline-offset: 2px;
}

.dash-nav-item.active {
  background: var(--c-surface-3);
  color: var(--c-primary-400);
  font-weight: var(--fw-bold);
}

.dash-nav-item.active::before {
  content: '';
  position: absolute;
  inset-inline-start: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 3px;
  height: 60%;
  background: var(--c-primary-500);
  border-radius: 0 var(--r-xs) var(--r-xs) 0;
}

html[dir="rtl"] .dash-nav-item.active::before {
  border-radius: var(--r-xs) 0 0 var(--r-xs);
}

/* Nav item icon */
.dash-nav-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  flex-shrink: 0;
  font-size: var(--fs-lg);
  line-height: 1;
  transition: transform var(--t-base) var(--ease);
}

.dash-nav-item:hover .dash-nav-icon {
  transform: scale(1.1);
}

.dash-nav-icon svg {
  width: 20px;
  height: 20px;
  stroke: currentColor;
  fill: none;
  stroke-width: 1.8;
}

/* Nav item text */
.dash-nav-text {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  transition: opacity var(--t-fast) var(--ease);
}

/* Nav item badge */
.dash-nav-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 20px;
  height: 20px;
  padding: 0 6px;
  background: var(--c-primary-500);
  color: var(--c-text-inv);
  font-size: var(--fs-2xs);
  font-weight: var(--fw-black);
  border-radius: var(--r-full);
  flex-shrink: 0;
  transition: opacity var(--t-fast) var(--ease);
}

.dash-nav-badge.badge-success {
  background: var(--c-success);
  color: #ffffff;
}

.dash-nav-badge.badge-danger {
  background: var(--c-danger);
  color: #ffffff;
}

/* Nav item badge (نقطة) */
.dash-nav-dot {
  width: 8px;
  height: 8px;
  background: var(--c-primary-500);
  border-radius: var(--r-circle);
  flex-shrink: 0;
  position: relative;
}

.dash-nav-dot::after {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: var(--r-circle);
  background: currentColor;
  animation: pulse-ring 2s ease-out infinite;
}

/* ========== Sidebar Footer ========== */

.dash-sidebar-footer {
  padding: var(--s-3);
  border-top: 1px solid var(--c-border);
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  gap: var(--s-2);
}

/* User Card in Sidebar */
.dash-sidebar-user {
  display: flex;
  align-items: center;
  gap: var(--s-3);
  padding: var(--s-3);
  background: var(--c-surface-2);
  border: 1px solid var(--c-border);
  border-radius: var(--r-md);
  cursor: pointer;
  transition: var(--tr-base);
  overflow: hidden;
  position: relative;
}

.dash-sidebar-user:hover {
  border-color: var(--c-border-hi);
  background: var(--c-surface-3);
}

.dash-sidebar-user .avatar {
  flex-shrink: 0;
}

.dash-sidebar-user-info {
  flex: 1;
  min-width: 0;
  transition: opacity var(--t-fast) var(--ease);
}

.dash-sidebar-user-name {
  font-size: var(--fs-sm);
  font-weight: var(--fw-bold);
  color: var(--c-text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.dash-sidebar-user-role {
  font-size: var(--fs-2xs);
  color: var(--c-text-mut);
  text-transform: uppercase;
  letter-spacing: var(--ls-wider);
}

.dash-sidebar-user-arrow {
  color: var(--c-text-mut);
  font-size: var(--fs-xs);
  flex-shrink: 0;
  transition: transform var(--t-base) var(--ease);
}

.dash-sidebar-user:hover .dash-sidebar-user-arrow {
  transform: translateX(4px);
}

html[dir="rtl"] .dash-sidebar-user:hover .dash-sidebar-user-arrow {
  transform: translateX(-4px);
}

/* ========== Collapsed State ========== */

.dashboard-app.sidebar-collapsed .dash-sidebar-title,
.dashboard-app.sidebar-collapsed .dash-sidebar-subtitle,
.dashboard-app.sidebar-collapsed .dash-nav-label,
.dashboard-app.sidebar-collapsed .dash-nav-text,
.dashboard-app.sidebar-collapsed .dash-nav-badge,
.dashboard-app.sidebar-collapsed .dash-sidebar-user-info,
.dashboard-app.sidebar-collapsed .dash-sidebar-user-arrow {
  opacity: 0;
  pointer-events: none;
  width: 0;
}

.dashboard-app.sidebar-collapsed .dash-nav-item {
  justify-content: center;
  padding-inline: 0;
}

.dashboard-app.sidebar-collapsed .dash-nav-item::after {
  content: attr(data-tooltip);
  position: absolute;
  inset-inline-start: calc(100% + 8px);
  top: 50%;
  transform: translateY(-50%);
  padding: 6px 12px;
  background: var(--c-surface-3);
  color: var(--c-text);
  border: 1px solid var(--c-border);
  border-radius: var(--r-sm);
  font-size: var(--fs-xs);
  font-weight: var(--fw-medium);
  white-space: nowrap;
  opacity: 0;
  pointer-events: none;
  transition: opacity var(--t-fast);
  z-index: var(--z-tooltip);
  box-shadow: var(--sh-md);
}

.dashboard-app.sidebar-collapsed .dash-nav-item:hover::after {
  opacity: 1;
}

/* ==========================================
   🎯 TOPBAR — الشريط العلوي
   ========================================== */

.dash-main {
  display: flex;
  flex-direction: column;
  min-width: 0;
  min-height: 100vh;
  min-height: 100dvh;
  background: var(--c-bg);
}

.dash-topbar {
  position: sticky;
  top: 0;
  z-index: var(--z-sticky);
  height: var(--h-topbar);
  display: flex;
  align-items: center;
  gap: var(--s-3);
  padding-inline: var(--s-5);
  background: rgba(10, 9, 8, 0.85);
  backdrop-filter: var(--blur-md);
  -webkit-backdrop-filter: var(--blur-md);
  border-bottom: 1px solid var(--c-border);
  flex-shrink: 0;
}

[data-theme="light"] .dash-topbar {
  background: rgba(250, 250, 247, 0.85);
}

/* Topbar Left */
.dash-topbar-left {
  display: flex;
  align-items: center;
  gap: var(--s-3);
  flex-shrink: 0;
}

.dash-topbar-menu {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  background: transparent;
  border: 1px solid var(--c-border);
  border-radius: var(--r-md);
  color: var(--c-text-mut);
  cursor: pointer;
  transition: var(--tr-fast);
}

.dash-topbar-menu:hover {
  color: var(--c-text);
  background: var(--c-surface-2);
  border-color: var(--c-border-hi);
}

.dash-topbar-menu svg {
  width: 18px;
  height: 18px;
}

/* Breadcrumb in Topbar */
.dash-topbar-breadcrumb {
  display: flex;
  align-items: center;
  gap: var(--s-2);
  font-size: var(--fs-sm);
  color: var(--c-text-mut);
  min-width: 0;
  overflow: hidden;
}

.dash-topbar-breadcrumb-item {
  color: var(--c-text-mut);
  text-decoration: none;
  transition: color var(--t-fast);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.dash-topbar-breadcrumb-item:hover {
  color: var(--c-primary-400);
}

.dash-topbar-breadcrumb-item.active {
  color: var(--c-text);
  font-weight: var(--fw-bold);
  pointer-events: none;
}

.dash-topbar-breadcrumb-sep {
  color: var(--c-text-dim);
  font-size: var(--fs-xs);
  flex-shrink: 0;
}

html[dir="rtl"] .dash-topbar-breadcrumb-sep {
  transform: scaleX(-1);
}

/* Topbar Center */
.dash-topbar-center {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 0;
  padding-inline: var(--s-4);
}

/* Topbar Search */
.dash-topbar-search {
  width: 100%;
  max-width: 400px;
  position: relative;
}

.dash-topbar-search input {
  width: 100%;
  padding: 8px 40px 8px 40px;
  background: var(--c-surface-2);
  border: 1px solid var(--c-border);
  border-radius: var(--r-full);
  font-family: inherit;
  font-size: var(--fs-sm);
  color: var(--c-text);
  outline: none;
  transition: var(--tr-base);
}

.dash-topbar-search input:hover {
  border-color: var(--c-border-hi);
}

.dash-topbar-search input:focus {
  border-color: var(--c-primary-500);
  background: var(--c-surface);
  box-shadow: 0 0 0 3px rgba(242, 194, 60, 0.15);
}

.dash-topbar-search-icon {
  position: absolute;
  top: 50%;
  inset-inline-start: 12px;
  transform: translateY(-50%);
  color: var(--c-text-mut);
  pointer-events: none;
  font-size: var(--fs-base);
  display: flex;
  align-items: center;
}

.dash-topbar-search-kbd {
  position: absolute;
  top: 50%;
  inset-inline-end: 10px;
  transform: translateY(-50%);
  display: inline-flex;
  align-items: center;
  padding: 2px 6px;
  background: var(--c-surface-3);
  border: 1px solid var(--c-border);
  border-radius: var(--r-xs);
  font-family: var(--f-mono);
  font-size: var(--fs-2xs);
  color: var(--c-text-mut);
  pointer-events: none;
}

/* Topbar Right */
.dash-topbar-right {
  display: flex;
  align-items: center;
  gap: var(--s-2);
  flex-shrink: 0;
}

/* Topbar Icon Buttons */
.dash-topbar-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  background: transparent;
  border: 1px solid transparent;
  border-radius: var(--r-md);
  color: var(--c-text-mut);
  cursor: pointer;
  transition: var(--tr-fast);
  position: relative;
  text-decoration: none;
  flex-shrink: 0;
}

.dash-topbar-btn:hover {
  color: var(--c-text);
  background: var(--c-surface-2);
  border-color: var(--c-border);
}

.dash-topbar-btn svg {
  width: 20px;
  height: 20px;
  stroke: currentColor;
  fill: none;
  stroke-width: 1.8;
}

.dash-topbar-btn .notification-badge {
  position: absolute;
  top: 4px;
  inset-inline-end: 4px;
  min-width: 16px;
  height: 16px;
  padding: 0 4px;
  font-size: 0.625rem;
}

/* Server Selector in Topbar */
.dash-topbar-server {
  display: flex;
  align-items: center;
  gap: var(--s-2);
  padding: 6px 10px 6px 6px;
  background: var(--c-surface-2);
  border: 1px solid var(--c-border);
  border-radius: var(--r-md);
  cursor: pointer;
  transition: var(--tr-fast);
  max-width: 220px;
  position: relative;
}

.dash-topbar-server:hover {
  border-color: var(--c-border-hi);
  background: var(--c-surface-3);
}

.dash-topbar-server .avatar {
  width: 28px;
  height: 28px;
  border-radius: var(--r-sm);
  font-size: var(--fs-xs);
}

.dash-topbar-server-name {
  font-size: var(--fs-sm);
  font-weight: var(--fw-medium);
  color: var(--c-text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 140px;
}

.dash-topbar-server-arrow {
  color: var(--c-text-mut);
  font-size: var(--fs-xs);
  flex-shrink: 0;
  transition: transform var(--t-fast);
}

.dash-topbar-server[aria-expanded="true"] .dash-topbar-server-arrow {
  transform: rotate(180deg);
}

/* Topbar User Avatar */
.dash-topbar-user {
  position: relative;
  cursor: pointer;
}

.dash-topbar-user .avatar {
  transition: transform var(--t-fast);
}

.dash-topbar-user:hover .avatar {
  transform: scale(1.05);
}

/* ==========================================
   🎯 DASH CONTENT — المحتوى الرئيسي
   ========================================== */

.dash-content {
  flex: 1;
  padding: var(--s-6);
  max-width: var(--w-wide);
  margin-inline: auto;
  width: 100%;
  min-width: 0;
}

/* Page Header داخل المحتوى */
.dash-page-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: var(--s-4);
  margin-bottom: var(--s-6);
  flex-wrap: wrap;
  padding-bottom: var(--s-5);
  border-bottom: 1px solid var(--c-border);
}

.dash-page-header-left {
  flex: 1;
  min-width: 0;
}

.dash-page-title {
  font-size: clamp(var(--fs-2xl), 3vw, var(--fs-3xl));
  font-weight: var(--fw-black);
  color: var(--c-text);
  margin: 0;
  line-height: var(--lh-tight);
  letter-spacing: var(--ls-tight);
  display: flex;
  align-items: center;
  gap: var(--s-3);
}

.dash-page-title-icon {
  font-size: 1.5em;
  line-height: 1;
}

.dash-page-subtitle {
  font-size: var(--fs-base);
  color: var(--c-text-mut);
  margin-top: var(--s-2);
  line-height: var(--lh-relaxed);
}

.dash-page-actions {
  display: flex;
  align-items: center;
  gap: var(--s-2);
  flex-wrap: wrap;
  flex-shrink: 0;
}

/* Content Area */
.dash-page-content {
  display: flex;
  flex-direction: column;
  gap: var(--s-5);
  animation: fade-in-up var(--t-slow) var(--ease);
}

/* ==========================================
   🎯 STATS GRID — شبكة الإحصائيات
   ========================================== */

.dash-stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: var(--s-4);
  margin-bottom: var(--s-6);
}

.dash-stat {
  display: flex;
  flex-direction: column;
  gap: var(--s-3);
  padding: var(--s-5);
  background: var(--c-surface);
  border: 1px solid var(--c-border);
  border-radius: var(--r-lg);
  transition: var(--tr-base);
  position: relative;
  overflow: hidden;
}

.dash-stat::before {
  content: '';
  position: absolute;
  inset: 0;
  background: var(--g-glass);
  opacity: 0;
  transition: opacity var(--t-base);
  pointer-events: none;
}

.dash-stat:hover {
  transform: translateY(-3px);
  box-shadow: var(--sh-md);
  border-color: var(--c-border-hi);
}

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

.dash-stat-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--s-2);
  position: relative;
  z-index: 1;
}

.dash-stat-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  background: var(--c-surface-2);
  border-radius: var(--r-md);
  font-size: var(--fs-xl);
  flex-shrink: 0;
  transition: transform var(--t-base) var(--ease);
}

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

.dash-stat-icon.primary {
  background: rgba(242, 194, 60, 0.15);
  color: var(--c-primary-400);
}

.dash-stat-icon.success {
  background: var(--c-success-bg);
  color: var(--c-success);
}

.dash-stat-icon.danger {
  background: var(--c-danger-bg);
  color: var(--c-danger);
}

.dash-stat-icon.info {
  background: var(--c-info-bg);
  color: var(--c-info);
}

.dash-stat-icon.premium {
  background: rgba(168, 85, 247, 0.15);
  color: var(--c-premium-hi);
}

.dash-stat-body {
  display: flex;
  flex-direction: column;
  gap: var(--s-1);
  position: relative;
  z-index: 1;
}

.dash-stat-label {
  font-size: var(--fs-xs);
  font-weight: var(--fw-medium);
  color: var(--c-text-mut);
  text-transform: uppercase;
  letter-spacing: var(--ls-wider);
}

.dash-stat-value {
  font-size: clamp(var(--fs-2xl), 3vw, var(--fs-4xl));
  font-weight: var(--fw-black);
  color: var(--c-text);
  line-height: 1;
  letter-spacing: var(--ls-tight);
}

.dash-stat-value.primary { color: var(--c-primary-400); }
.dash-stat-value.success { color: var(--c-success); }
.dash-stat-value.danger { color: var(--c-danger); }

.dash-stat-footer {
  display: flex;
  align-items: center;
  gap: var(--s-2);
  font-size: var(--fs-xs);
  color: var(--c-text-mut);
  position: relative;
  z-index: 1;
}

.dash-stat-trend {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  font-weight: var(--fw-bold);
}

.dash-stat-trend.up { color: var(--c-success); }
.dash-stat-trend.down { color: var(--c-danger); }

/* ==========================================
   🎯 WELCOME BANNER — لافتة الترحيب
   ========================================== */

.dash-welcome {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--s-5);
  padding: var(--s-6);
  background: linear-gradient(135deg, rgba(242, 194, 60, 0.08), rgba(242, 194, 60, 0.02));
  border: 1px solid rgba(242, 194, 60, 0.2);
  border-radius: var(--r-xl);
  margin-bottom: var(--s-6);
  position: relative;
  overflow: hidden;
  flex-wrap: wrap;
}

.dash-welcome::before {
  content: '';
  position: absolute;
  top: -50%;
  inset-inline-end: -10%;
  width: 400px;
  height: 400px;
  background: radial-gradient(circle, rgba(242, 194, 60, 0.15), transparent 70%);
  pointer-events: none;
}

.dash-welcome-content {
  flex: 1;
  min-width: 0;
  position: relative;
  z-index: 1;
}

.dash-welcome-title {
  font-size: clamp(var(--fs-xl), 2.5vw, var(--fs-3xl));
  font-weight: var(--fw-black);
  color: var(--c-text);
  margin: 0 0 var(--s-2);
  line-height: var(--lh-tight);
}

.dash-welcome-title .gold {
  background: var(--g-gold);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.dash-welcome-text {
  font-size: var(--fs-sm);
  color: var(--c-text-mut);
  line-height: var(--lh-relaxed);
  max-width: 500px;
}

.dash-welcome-actions {
  display: flex;
  gap: var(--s-2);
  flex-wrap: wrap;
  position: relative;
  z-index: 1;
}

.dash-welcome-avatar {
  position: relative;
  z-index: 1;
  flex-shrink: 0;
}

/* ==========================================
   🎯 DASH CARDS — بطاقات Dashboard
   ========================================== */

.dash-card {
  display: flex;
  flex-direction: column;
  background: var(--c-surface);
  border: 1px solid var(--c-border);
  border-radius: var(--r-lg);
  overflow: hidden;
  transition: var(--tr-base);
}

.dash-card:hover {
  border-color: var(--c-border-hi);
}

.dash-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--s-3);
  padding: var(--s-5) var(--s-6);
  border-bottom: 1px solid var(--c-border);
  flex-wrap: wrap;
}

.dash-card-title {
  display: flex;
  align-items: center;
  gap: var(--s-3);
  font-size: var(--fs-lg);
  font-weight: var(--fw-bold);
  color: var(--c-text);
  margin: 0;
}

.dash-card-title-icon {
  font-size: 1.25em;
  line-height: 1;
}

.dash-card-subtitle {
  font-size: var(--fs-xs);
  color: var(--c-text-mut);
  margin-top: 2px;
  font-weight: var(--fw-normal);
}

.dash-card-actions {
  display: flex;
  align-items: center;
  gap: var(--s-2);
}

.dash-card-body {
  padding: var(--s-6);
  flex: 1;
  min-width: 0;
}

.dash-card-body.flush {
  padding: 0;
}

.dash-card-footer {
  padding: var(--s-4) var(--s-6);
  border-top: 1px solid var(--c-border);
  background: var(--c-bg-alt);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--s-3);
  flex-wrap: wrap;
}

/* ==========================================
   🎯 QUICK ACTIONS — إجراءات سريعة
   ========================================== */

.dash-quick-actions {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: var(--s-3);
}

.dash-quick-action {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--s-3);
  padding: var(--s-5) var(--s-3);
  background: var(--c-surface-2);
  border: 1px solid var(--c-border);
  border-radius: var(--r-lg);
  text-decoration: none;
  color: var(--c-text);
  text-align: center;
  transition: var(--tr-base);
  cursor: pointer;
}

.dash-quick-action:hover {
  transform: translateY(-3px);
  border-color: var(--c-primary-500);
  background: var(--c-surface);
  box-shadow: var(--sh-md);
}

.dash-quick-action-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 52px;
  height: 52px;
  background: var(--c-surface-3);
  border-radius: var(--r-md);
  font-size: 1.5rem;
  transition: transform var(--t-base) var(--ease-bounce);
}

.dash-quick-action:hover .dash-quick-action-icon {
  transform: scale(1.15) rotate(-8deg);
  background: var(--c-primary-500);
  color: var(--c-text-inv);
}

.dash-quick-action-title {
  font-size: var(--fs-sm);
  font-weight: var(--fw-bold);
  color: var(--c-text);
}

.dash-quick-action-desc {
  font-size: var(--fs-xs);
  color: var(--c-text-mut);
}

/* ==========================================
   🎯 CHART CONTAINER — حاوية الرسم البياني
   ========================================== */

.dash-chart {
  position: relative;
  width: 100%;
  height: 300px;
  padding: var(--s-4);
}

.dash-chart canvas {
  max-width: 100%;
  height: auto;
}

.dash-chart-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--s-3);
  margin-bottom: var(--s-4);
  flex-wrap: wrap;
}

.dash-chart-legend {
  display: flex;
  align-items: center;
  gap: var(--s-3);
  flex-wrap: wrap;
}

.dash-chart-legend-item {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: var(--fs-xs);
  color: var(--c-text-mut);
}

.dash-chart-legend-dot {
  width: 10px;
  height: 10px;
  border-radius: var(--r-circle);
  flex-shrink: 0;
}

/* ==========================================
   🎯 ACTIVITY LIST — قائمة النشاط
   ========================================== */

.dash-activity {
  display: flex;
  flex-direction: column;
}

.dash-activity-item {
  display: flex;
  align-items: flex-start;
  gap: var(--s-3);
  padding: var(--s-4) var(--s-6);
  border-bottom: 1px solid var(--c-border);
  transition: background var(--t-fast);
}

.dash-activity-item:hover {
  background: var(--c-surface-2);
}

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

.dash-activity-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  background: var(--c-surface-2);
  border-radius: var(--r-md);
  font-size: var(--fs-base);
  flex-shrink: 0;
}

.dash-activity-content {
  flex: 1;
  min-width: 0;
}

.dash-activity-text {
  font-size: var(--fs-sm);
  color: var(--c-text);
  line-height: var(--lh-normal);
  margin-bottom: 2px;
}

.dash-activity-text strong {
  color: var(--c-primary-400);
  font-weight: var(--fw-bold);
}

.dash-activity-time {
  font-size: var(--fs-xs);
  color: var(--c-text-mut);
}

/* ==========================================
   🎯 SIDEBAR DRAWER (MOBILE) — الشريط الجانبي للجوال
   ========================================== */

.dash-sidebar-overlay {
  display: none;
  position: fixed;
  inset: 0;
  z-index: calc(var(--z-drawer) - 1);
  background: var(--backdrop);
  backdrop-filter: var(--blur-sm);
  -webkit-backdrop-filter: var(--blur-sm);
  opacity: 0;
  transition: opacity var(--t-base) var(--ease);
}

.dash-sidebar-overlay.show {
  display: block;
  opacity: 1;
}

/* ==========================================
   🎯 SERVER DROPDOWN — قائمة السيرفرات
   ========================================== */

.dash-server-dropdown {
  position: fixed;
  min-width: 320px;
  max-width: 400px;
  max-height: 400px;
  background: var(--c-surface-2);
  border: 1px solid var(--c-border);
  border-radius: var(--r-md);
  box-shadow: var(--sh-xl);
  overflow: hidden;
  z-index: var(--z-dropdown);
  display: flex;
  flex-direction: column;
  animation: fade-in var(--t-fast) var(--ease);
  backdrop-filter: var(--blur-md);
  -webkit-backdrop-filter: var(--blur-md);
}

.dash-server-dropdown-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--s-3);
  padding: var(--s-4) var(--s-5);
  border-bottom: 1px solid var(--c-border);
  font-size: var(--fs-sm);
  font-weight: var(--fw-bold);
  color: var(--c-text);
}

.dash-server-dropdown-search {
  padding: var(--s-3) var(--s-4);
  border-bottom: 1px solid var(--c-border);
}

.dash-server-dropdown-list {
  flex: 1;
  overflow-y: auto;
  padding: var(--s-2);
}

.dash-server-item {
  display: flex;
  align-items: center;
  gap: var(--s-3);
  width: 100%;
  padding: var(--s-3);
  background: transparent;
  border: none;
  border-radius: var(--r-md);
  color: var(--c-text);
  text-align: start;
  cursor: pointer;
  transition: var(--tr-fast);
  font-family: inherit;
  font-size: var(--fs-sm);
}

.dash-server-item:hover {
  background: var(--c-surface-3);
}

.dash-server-item.active {
  background: var(--c-surface-3);
  color: var(--c-primary-400);
  box-shadow: inset 3px 0 0 var(--c-primary-500);
}

html[dir="rtl"] .dash-server-item.active {
  box-shadow: inset -3px 0 0 var(--c-primary-500);
}

.dash-server-item .avatar {
  width: 36px;
  height: 36px;
  border-radius: var(--r-sm);
  font-size: var(--fs-sm);
}

.dash-server-item-info {
  flex: 1;
  min-width: 0;
}

.dash-server-item-name {
  font-weight: var(--fw-medium);
  color: inherit;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.dash-server-item-meta {
  font-size: var(--fs-xs);
  color: var(--c-text-mut);
  margin-top: 2px;
}

.dash-server-item-check {
  color: var(--c-primary-500);
  font-weight: var(--fw-black);
  flex-shrink: 0;
}

/* ==========================================
   🎯 EMPTY & LOADING STATES
   ========================================== */

.dash-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: var(--s-4);
  padding: var(--s-16) var(--s-6);
  text-align: center;
}

.dash-empty-icon {
  font-size: 4rem;
  opacity: 0.4;
  line-height: 1;
}

.dash-empty-title {
  font-size: var(--fs-xl);
  font-weight: var(--fw-bold);
  color: var(--c-text);
  margin: 0;
}

.dash-empty-text {
  font-size: var(--fs-sm);
  color: var(--c-text-mut);
  max-width: 400px;
  line-height: var(--lh-relaxed);
}

/* Loading */
.dash-loading {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: var(--s-4);
  padding: var(--s-16) var(--s-6);
  text-align: center;
}

.dash-loading .spinner {
  width: 40px;
  height: 40px;
  border-width: 3px;
}

.dash-loading-text {
  font-size: var(--fs-sm);
  color: var(--c-text-mut);
}

/* ==========================================
   🎯 FORM LAYOUT — تخطيط النماذج
   ========================================== */

.dash-form {
  display: flex;
  flex-direction: column;
  gap: var(--s-5);
  max-width: 720px;
}

.dash-form-section {
  display: flex;
  flex-direction: column;
  gap: var(--s-4);
  padding: var(--s-5);
  background: var(--c-surface);
  border: 1px solid var(--c-border);
  border-radius: var(--r-lg);
}

.dash-form-section-title {
  display: flex;
  align-items: center;
  gap: var(--s-2);
  font-size: var(--fs-base);
  font-weight: var(--fw-bold);
  color: var(--c-text);
  padding-bottom: var(--s-3);
  border-bottom: 1px solid var(--c-border);
  margin-bottom: var(--s-2);
}

.dash-form-section-title-icon {
  font-size: 1.25em;
  line-height: 1;
}

.dash-form-row {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--s-4);
}

.dash-form-row.two-col {
  grid-template-columns: 1fr 1fr;
}

.dash-form-row.three-col {
  grid-template-columns: repeat(3, 1fr);
}

/* Switch row */
.dash-form-switch-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--s-4);
  padding: var(--s-4) 0;
  border-bottom: 1px solid var(--c-border);
}

.dash-form-switch-row:last-child {
  border-bottom: none;
  padding-bottom: 0;
}

.dash-form-switch-row:first-child {
  padding-top: 0;
}

.dash-form-switch-info {
  display: flex;
  flex-direction: column;
  gap: 4px;
  flex: 1;
  min-width: 0;
}

.dash-form-switch-label {
  font-size: var(--fs-sm);
  font-weight: var(--fw-medium);
  color: var(--c-text);
}

.dash-form-switch-hint {
  font-size: var(--fs-xs);
  color: var(--c-text-mut);
  line-height: var(--lh-relaxed);
}

/* Form Actions */
.dash-form-actions {
  display: flex;
  align-items: center;
  gap: var(--s-3);
  padding-top: var(--s-4);
  border-top: 1px solid var(--c-border);
  flex-wrap: wrap;
}

.dash-form-actions .btn-primary {
  min-width: 140px;
}

/* ==========================================
   🎯 RESPONSIVE — التجاوب
   ========================================== */

/* Tablet */
@media (max-width: 1024px) {
  .dash-content {
    padding: var(--s-5);
  }

  .dash-form-row.three-col {
    grid-template-columns: 1fr 1fr;
  }
}

/* Mobile */
@media (max-width: 768px) {
  .dashboard-app {
    grid-template-columns: 1fr;
  }

  .dash-sidebar {
    position: fixed;
    inset-block: 0;
    inset-inline-start: 0;
    width: var(--w-sidebar-mobile);
    max-width: 85vw;
    z-index: var(--z-drawer);
    transform: translateX(-100%);
    transition: transform var(--t-base) var(--ease);
    box-shadow: none;
  }

  html[dir="rtl"] .dash-sidebar {
    transform: translateX(100%);
  }

  .dash-sidebar.open {
    transform: translateX(0);
    box-shadow: var(--sh-2xl);
  }

  .dash-sidebar-overlay {
    display: block;
  }

  .dash-topbar {
    padding-inline: var(--s-4);
  }

  .dash-topbar-center {
    display: none;
  }

  .dash-topbar-server-name {
    display: none;
  }

  .dash-topbar-server {
    padding: 6px;
    max-width: none;
  }

  .dash-content {
    padding: var(--s-4);
    padding-bottom: calc(var(--h-bottom-nav) + var(--s-4));
  }

  .dash-page-header {
    flex-direction: column;
    align-items: stretch;
    gap: var(--s-3);
  }

  .dash-page-actions {
    width: 100%;
  }

  .dash-page-actions .btn {
    flex: 1;
    justify-content: center;
  }

  .dash-stats {
    grid-template-columns: repeat(2, 1fr);
    gap: var(--s-3);
  }

  .dash-stat {
    padding: var(--s-4);
  }

  .dash-stat-icon {
    width: 36px;
    height: 36px;
    font-size: var(--fs-lg);
  }

  .dash-form-row.two-col,
  .dash-form-row.three-col {
    grid-template-columns: 1fr;
  }

  .dash-welcome {
    flex-direction: column;
    text-align: center;
    padding: var(--s-5);
  }

  .dash-welcome-actions {
    width: 100%;
    justify-content: center;
  }

  .dash-quick-actions {
    grid-template-columns: repeat(2, 1fr);
  }

  .dash-card-header {
    padding: var(--s-4);
  }

  .dash-card-body {
    padding: var(--s-4);
  }

  .dash-card-footer {
    padding: var(--s-3) var(--s-4);
  }

  .dash-server-dropdown {
    min-width: calc(100vw - var(--s-8));
    max-width: calc(100vw - var(--s-8));
  }

  .dash-chart {
    height: 240px;
    padding: var(--s-3);
  }
}

/* Small mobile */
@media (max-width: 480px) {
  .dash-content {
    padding: var(--s-3);
    padding-bottom: calc(var(--h-bottom-nav) + var(--s-3));
  }

  .dash-topbar {
    padding-inline: var(--s-3);
    gap: var(--s-2);
  }

  .dash-topbar-btn {
    width: 36px;
    height: 36px;
  }

  .dash-topbar-btn svg {
    width: 18px;
    height: 18px;
  }

  .dash-stats {
    grid-template-columns: 1fr;
  }

  .dash-stat-value {
    font-size: var(--fs-2xl);
  }

  .dash-quick-actions {
    grid-template-columns: 1fr;
  }

  .dash-form-actions .btn {
    width: 100%;
    justify-content: center;
  }
}

/* ==========================================
   🎯 PRINT — الطباعة
   ========================================== */

@media print {
  .dash-sidebar,
  .dash-topbar,
  .dash-sidebar-overlay,
  .dash-page-actions {
    display: none !important;
  }

  .dashboard-app {
    grid-template-columns: 1fr;
  }

  .dash-content {
    padding: 0;
    max-width: 100%;
  }

  .dash-card {
    break-inside: avoid;
    box-shadow: none;
    border: 1px solid #ccc;
  }
}
/* ==========================================
   🎯 HOME PAGE SPECIFIC
   ========================================== */

/* Welcome Badges */
.dash-welcome-badges {
  display: flex;
  gap: var(--s-2);
  flex-wrap: wrap;
  margin-top: var(--s-3);
}

/* Grid 2 Columns */
.dash-grid-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--s-5);
  margin-bottom: var(--s-6);
}

.dash-column {
  display: flex;
  flex-direction: column;
  gap: var(--s-5);
  min-width: 0;
}

@media (max-width: 1024px) {
  .dash-grid-2 {
    grid-template-columns: 1fr;
  }
}

/* Dash List (Top Users) */
.dash-list {
  display: flex;
  flex-direction: column;
}

.dash-list-item {
  display: flex;
  align-items: center;
  gap: var(--s-3);
  padding: var(--s-3) var(--s-6);
  border-bottom: 1px solid var(--c-border);
  transition: background var(--t-fast);
}

.dash-list-item:hover {
  background: var(--c-surface-2);
}

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

.dash-list-rank {
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 32px;
  height: 32px;
  font-size: var(--fs-base);
  font-weight: var(--fw-black);
  color: var(--c-text-mut);
  flex-shrink: 0;
}

.dash-list-item:nth-child(1) .dash-list-rank { color: #ffd700; font-size: var(--fs-lg); }
.dash-list-item:nth-child(2) .dash-list-rank { color: #c0c0c0; font-size: var(--fs-lg); }
.dash-list-item:nth-child(3) .dash-list-rank { color: #cd7f32; font-size: var(--fs-lg); }

.dash-list-content {
  flex: 1;
  min-width: 0;
}

.dash-list-title {
  font-size: var(--fs-sm);
  font-weight: var(--fw-bold);
  color: var(--c-text);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.dash-list-sub {
  font-size: var(--fs-xs);
  color: var(--c-text-mut);
  margin-top: 2px;
}

.dash-list-value {
  padding: 4px 10px;
  background: rgba(242, 194, 60, 0.15);
  color: var(--c-primary-400);
  border-radius: var(--r-full);
  font-size: var(--fs-xs);
  font-weight: var(--fw-bold);
  white-space: nowrap;
  flex-shrink: 0;
}

/* Help Card */
.dash-help {
  display: flex;
  flex-direction: column;
  gap: var(--s-4);
}

.dash-help-text {
  font-size: var(--fs-sm);
  color: var(--c-text-mut);
  line-height: var(--lh-relaxed);
  margin: 0;
}

.dash-help-actions {
  display: flex;
  gap: var(--s-2);
  flex-wrap: wrap;
}

/* CTA */
.dash-cta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--s-5);
  padding: var(--s-6);
  background: linear-gradient(135deg, rgba(242, 194, 60, 0.08), rgba(242, 194, 60, 0.02));
  border: 1px solid rgba(242, 194, 60, 0.25);
  border-radius: var(--r-xl);
  margin-top: var(--s-6);
  flex-wrap: wrap;
  position: relative;
  overflow: hidden;
}

.dash-cta::before {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: linear-gradient(45deg, transparent 30%, rgba(242, 194, 60, 0.06) 50%, transparent 70%);
  animation: premium-shine 4s linear infinite;
  pointer-events: none;
}

.dash-cta-content {
  flex: 1;
  min-width: 240px;
  position: relative;
  z-index: 1;
}

.dash-cta-title {
  font-size: var(--fs-xl);
  font-weight: var(--fw-black);
  color: var(--c-text);
  margin: 0 0 var(--s-2);
  line-height: var(--lh-tight);
}

.dash-cta-title .gold {
  background: var(--g-gold);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.dash-cta-text {
  font-size: var(--fs-sm);
  color: var(--c-text-mut);
  line-height: var(--lh-relaxed);
  margin: 0;
}

.dash-cta-actions {
  display: flex;
  gap: var(--s-2);
  flex-wrap: wrap;
  position: relative;
  z-index: 1;
}

@media (max-width: 640px) {
  .dash-cta {
    flex-direction: column;
    text-align: center;
  }
  
  .dash-cta-actions {
    width: 100%;
    justify-content: center;
  }
}
/* ==========================================
   🎯 LEVELS PAGE SPECIFIC
   ========================================== */

/* Range slider value */
.range-value {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 60px;
  padding: 6px 12px;
  background: var(--c-surface-2);
  border: 1px solid var(--c-border);
  border-radius: var(--r-md);
  font-family: var(--f-mono);
  font-size: var(--fs-sm);
  font-weight: var(--fw-bold);
  color: var(--c-primary-400);
  text-align: center;
  flex-shrink: 0;
}

/* Role Row */
.role-row {
  display: flex;
  align-items: center;
  gap: var(--s-3);
  padding: var(--s-3) var(--s-4);
  background: var(--c-surface-2);
  border: 1px solid var(--c-border);
  border-radius: var(--r-md);
  transition: var(--tr-fast);
}

.role-row:hover {
  border-color: var(--c-border-hi);
  background: var(--c-surface-3);
}

.role-row-level {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 60px;
  padding: 4px 10px;
  background: rgba(242, 194, 60, 0.15);
  color: var(--c-primary-400);
  border-radius: var(--r-sm);
  font-family: var(--f-mono);
  font-size: var(--fs-xs);
  font-weight: var(--fw-black);
  flex-shrink: 0;
}

.role-row-dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  flex-shrink: 0;
  border: 2px solid var(--c-bg);
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.1);
}

.role-row-name {
  flex: 1;
  min-width: 0;
  font-size: var(--fs-sm);
  font-weight: var(--fw-medium);
  color: var(--c-text);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* Leaderboard Type Tabs */
.lb-type-tabs {
  display: flex;
  gap: var(--s-2);
  padding: var(--s-1);
  background: var(--c-surface-2);
  border: 1px solid var(--c-border);
  border-radius: var(--r-md);
  width: fit-content;
}

.lb-type-tab {
  padding: var(--s-2) var(--s-4);
  background: transparent;
  border: 0;
  border-radius: var(--r-sm);
  font-family: inherit;
  font-size: var(--fs-sm);
  font-weight: var(--fw-medium);
  color: var(--c-text-mut);
  cursor: pointer;
  transition: var(--tr-fast);
  white-space: nowrap;
}

.lb-type-tab:hover {
  color: var(--c-text);
  background: var(--c-surface-3);
}

.lb-type-tab.active {
  background: var(--g-gold);
  color: var(--c-text-inv);
  font-weight: var(--fw-bold);
  box-shadow: 0 2px 8px -2px rgba(242, 194, 60, 0.4);
}

/* Leaderboard List */
.lb-list {
  display: flex;
  flex-direction: column;
  gap: var(--s-2);
}

.lb-item {
  display: flex;
  align-items: center;
  gap: var(--s-3);
  padding: var(--s-3) var(--s-4);
  background: var(--c-surface-2);
  border: 1px solid var(--c-border);
  border-radius: var(--r-md);
  transition: var(--tr-fast);
}

.lb-item:hover {
  border-color: var(--c-border-hi);
  transform: translateX(-4px);
}

html[dir="rtl"] .lb-item:hover {
  transform: translateX(4px);
}

.lb-item.top-1 {
  background: linear-gradient(135deg, rgba(255, 215, 0, 0.08), var(--c-surface-2));
  border-color: rgba(255, 215, 0, 0.4);
}

.lb-item.top-2 {
  background: linear-gradient(135deg, rgba(192, 192, 192, 0.06), var(--c-surface-2));
  border-color: rgba(192, 192, 192, 0.3);
}

.lb-item.top-3 {
  background: linear-gradient(135deg, rgba(205, 127, 50, 0.06), var(--c-surface-2));
  border-color: rgba(205, 127, 50, 0.3);
}

.lb-rank {
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 40px;
  height: 32px;
  font-size: var(--fs-base);
  font-weight: var(--fw-black);
  color: var(--c-text-mut);
  flex-shrink: 0;
}

.lb-item.top-1 .lb-rank { font-size: var(--fs-xl); }
.lb-item.top-2 .lb-rank { font-size: var(--fs-xl); }
.lb-item.top-3 .lb-rank { font-size: var(--fs-xl); }

.lb-user {
  flex: 1;
  min-width: 0;
  font-size: var(--fs-sm);
  font-weight: var(--fw-medium);
  color: var(--c-text);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.lb-value {
  padding: 4px 10px;
  background: rgba(242, 194, 60, 0.15);
  color: var(--c-primary-400);
  border-radius: var(--r-full);
  font-size: var(--fs-xs);
  font-weight: var(--fw-bold);
  white-space: nowrap;
  flex-shrink: 0;
}

/* Stats Grid 2 Columns */
.stats-grid-2 {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: var(--s-4);
}

/* Form Save Button (sticky) */
@media (max-width: 640px) {
  .dash-form-actions[style*="sticky"] {
    position: static !important;
    padding-bottom: 0 !important;
  }
  
  .dash-form-actions[style*="sticky"] .btn {
    width: 100%;
  }
  
  .lb-type-tabs {
    width: 100%;
    justify-content: center;
  }
  
  .lb-type-tab {
    flex: 1;
    justify-content: center;
  }
}
/* ==========================================
   🎯 WELCOME PAGE SPECIFIC
   ========================================== */

/* Upload Area */
.welcome-upload-area {
  position: relative;
  width: 100%;
  border: 2px dashed var(--c-border);
  border-radius: var(--r-xl);
  overflow: hidden;
  cursor: pointer;
  transition: var(--tr-base);
  background: var(--c-bg-alt);
  min-height: 200px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.welcome-upload-area:hover {
  border-color: var(--c-primary-500);
  background: rgba(242, 194, 60, 0.03);
}

.welcome-upload-area.dragging {
  border-color: var(--c-primary-500);
  background: rgba(242, 194, 60, 0.08);
  transform: scale(1.01);
}

.welcome-upload-content {
  width: 100%;
  padding: var(--s-6);
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
}

.welcome-upload-placeholder {
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--s-2);
  padding: var(--s-6);
}

.welcome-upload-icon {
  font-size: 3rem;
  line-height: 1;
  margin-bottom: var(--s-2);
  transition: var(--tr-base);
}

.welcome-upload-area:hover .welcome-upload-icon {
  transform: scale(1.15) rotate(-5deg);
}

.welcome-upload-title {
  font-size: var(--fs-base);
  font-weight: var(--fw-bold);
  color: var(--c-text);
  margin: 0;
}

.welcome-upload-hint {
  font-size: var(--fs-sm);
  color: var(--c-text-mut);
  margin: 0;
}

.welcome-upload-limit {
  font-size: var(--fs-xs);
  color: var(--c-text-dim);
  margin: 0;
  margin-top: var(--s-1);
}

.welcome-upload-preview {
  position: relative;
  width: 100%;
  aspect-ratio: 1024 / 500;
  background: var(--c-surface-2);
  border-radius: var(--r-md);
  overflow: hidden;
}

.welcome-upload-preview img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.welcome-upload-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.8), transparent 60%);
  display: flex;
  align-items: flex-end;
  justify-content: center;
  gap: var(--s-2);
  padding: var(--s-4);
  opacity: 0;
  transition: opacity var(--t-base);
}

.welcome-upload-preview:hover .welcome-upload-overlay {
  opacity: 1;
}

/* Design Grid */
.design-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: var(--s-5);
  margin-top: var(--s-4);
}

.design-item {
  display: flex;
  flex-direction: column;
  gap: var(--s-2);
}

/* Color Picker Row */
.color-picker {
  display: flex;
  gap: var(--s-2);
  align-items: center;
}

.color-picker-input {
  width: 48px;
  height: 44px;
  padding: 2px;
  background: var(--c-bg);
  border: 1px solid var(--c-border);
  border-radius: var(--r-md);
  cursor: pointer;
}

.color-picker-input::-webkit-color-swatch-wrapper { padding: 0; }
.color-picker-input::-webkit-color-swatch {
  border: none;
  border-radius: var(--r-sm);
}

/* Range with value */
.range-with-value {
  display: flex;
  align-items: center;
  gap: var(--s-3);
}

.range-with-value .range {
  flex: 1;
}

/* Preset Grid */
.preset-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
  gap: var(--s-3);
}

.preset-card {
  display: flex;
  flex-direction: column;
  gap: var(--s-2);
  padding: var(--s-3);
  background: var(--c-surface-2);
  border: 2px solid var(--c-border);
  border-radius: var(--r-lg);
  cursor: pointer;
  transition: var(--tr-base);
  font-family: inherit;
}

.preset-card:hover {
  border-color: var(--c-border-hi);
  transform: translateY(-2px);
}

.preset-card.active {
  border-color: var(--c-primary-500);
  box-shadow: 0 0 0 1px var(--c-primary-500), 0 8px 24px -8px rgba(242, 194, 60, 0.4);
}

.preset-preview {
  width: 100%;
  height: 60px;
  border-radius: var(--r-md);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: var(--fs-2xl);
  color: rgba(255, 255, 255, 0.9);
  position: relative;
  overflow: hidden;
}

.preset-preview::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(45deg, transparent 40%, rgba(255, 255, 255, 0.15) 50%, transparent 60%);
}

.preset-name {
  font-size: var(--fs-sm);
  font-weight: var(--fw-bold);
  color: var(--c-text);
  text-align: center;
}

/* Welcome Preview */
.welcome-preview-container {
  display: flex;
  justify-content: center;
  padding: var(--s-5);
  background: var(--c-bg-alt);
  border-radius: var(--r-xl);
  border: 1px solid var(--c-border);
  margin-bottom: var(--s-5);
}

.welcome-preview-card {
  position: relative;
  width: 100%;
  max-width: 600px;
  aspect-ratio: 1024 / 500;
  border-radius: var(--r-xl);
  overflow: hidden;
  background: linear-gradient(135deg, #0a1628, #1a3a4a);
  box-shadow: 0 20px 60px -20px rgba(0, 0, 0, 0.6);
  border: 3px solid var(--c-primary-500);
}

.welcome-preview-bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  filter: brightness(0.7);
}

.welcome-preview-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to bottom, rgba(0, 0, 0, 0.2), rgba(0, 0, 0, 0.5));
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.welcome-preview-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
  text-align: center;
}

.welcome-preview-avatar {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  overflow: hidden;
  border: 3px solid #fff;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4);
  background: var(--c-primary-500);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2rem;
}

.welcome-preview-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.welcome-preview-text {
  font-size: 1.25rem;
  font-weight: 800;
  color: #fff;
  text-shadow: 2px 2px 8px rgba(0, 0, 0, 0.8);
  line-height: 1.4;
  max-width: 90%;
  word-wrap: break-word;
}

.preview-info {
  display: flex;
  gap: var(--s-5);
  justify-content: center;
  flex-wrap: wrap;
  padding: var(--s-4);
  background: var(--c-surface-2);
  border: 1px solid var(--c-border);
  border-radius: var(--r-lg);
}

.preview-info-item {
  display: flex;
  gap: var(--s-2);
  font-size: var(--fs-sm);
}

.preview-info-label {
  color: var(--c-text-mut);
}

.preview-info-value {
  color: var(--c-primary-400);
  font-weight: var(--fw-bold);
}

/* Mobile */
@media (max-width: 640px) {
  .preset-grid {
    grid-template-columns: repeat(3, 1fr);
  }
  
  .design-grid {
    grid-template-columns: 1fr;
  }
  
  .welcome-preview-card {
    aspect-ratio: 1 / 1;
  }
  
  .preview-info {
    flex-direction: column;
    gap: var(--s-2);
    align-items: center;
  }
}
/* ==========================================
   🎯 TICKETS PAGE SPECIFIC
   ========================================== */

/* Types Grid */
.types-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: var(--s-4);
}

.type-card {
  display: flex;
  flex-direction: column;
  gap: var(--s-3);
  padding: var(--s-5);
  background: var(--c-surface-2);
  border: 2px solid var(--c-border);
  border-radius: var(--r-lg);
  transition: var(--tr-base);
  position: relative;
  overflow: hidden;
}

.type-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--sh-md);
  border-color: var(--c-border-hi);
}

.type-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--s-2);
}

.type-card-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 52px;
  height: 52px;
  border-radius: var(--r-md);
  font-size: 1.75rem;
  line-height: 1;
}

.type-card-actions {
  display: flex;
  gap: 4px;
  opacity: 0;
  transition: opacity var(--t-base);
}

.type-card:hover .type-card-actions {
  opacity: 1;
}

.type-card-name {
  font-size: var(--fs-lg);
  font-weight: var(--fw-bold);
  color: var(--c-text);
  margin: 0;
  line-height: var(--lh-tight);
}

.type-card-desc {
  font-size: var(--fs-sm);
  color: var(--c-text-mut);
  margin: 0;
  line-height: var(--lh-relaxed);
  min-height: 2.4em;
}

.type-card-stats {
  display: flex;
  gap: var(--s-3);
  padding-top: var(--s-3);
  border-top: 1px solid var(--c-border);
}

.type-card-stat {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: var(--fs-xs);
  color: var(--c-text-mut);
}

.type-card-stat-icon {
  font-size: var(--fs-sm);
}

.type-card-stat-value {
  font-weight: var(--fw-black);
  color: var(--c-primary-400);
}

.type-card-stat-label {
  display: none;
}

@media (min-width: 500px) {
  .type-card-stat-label {
    display: inline;
  }
}

/* Tab badge */
.tab-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  margin-inline-start: 4px;
  background: var(--c-primary-500);
  color: var(--c-text-inv);
  border-radius: var(--r-full);
  font-size: 0.625rem;
  font-weight: var(--fw-black);
  line-height: 1;
}

.tab.active .tab-badge {
  background: rgba(255, 255, 255, 0.3);
  color: var(--c-text-inv);
}

/* Discord Preview */
.discord-preview-embed {
  padding: var(--s-4);
  background: #2f3136;
  border-radius: var(--r-md);
  display: flex;
  flex-direction: column;
  gap: var(--s-2);
}

.discord-embed {
  padding: var(--s-3) var(--s-4);
  background: #2f3136;
  border-left: 4px solid #5865F2;
  border-radius: var(--r-sm);
  max-width: 100%;
}

.discord-embed-title {
  font-size: var(--fs-base);
  font-weight: var(--fw-bold);
  color: #ffffff;
  margin-bottom: var(--s-1);
}

.discord-embed-desc {
  font-size: var(--fs-sm);
  color: #dcddde;
  line-height: 1.5;
  white-space: pre-wrap;
  word-wrap: break-word;
}

.panel-preview-buttons {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-top: var(--s-2);
}

.panel-preview-btn {
  display: flex;
  align-items: center;
  gap: var(--s-2);
  padding: 8px 12px;
  background: #4f545c;
  border: 1px solid #4f545c;
  border-radius: var(--r-sm);
  color: #ffffff;
  font-size: var(--fs-sm);
  font-weight: var(--fw-medium);
  transition: var(--tr-fast);
  cursor: default;
}

.panel-preview-btn:hover {
  background: #5d6269;
}

/* Multi-select chips */
.multi-select {
  display: flex;
  flex-wrap: wrap;
  gap: var(--s-2);
  min-height: 44px;
  padding: var(--s-2) var(--s-3);
  background: var(--c-bg);
  border: 1px solid var(--c-border);
  border-radius: var(--r-md);
}

.chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 4px 4px 10px;
  background: var(--c-surface-3);
  border: 1px solid var(--c-border);
  border-radius: var(--r-full);
  font-size: var(--fs-xs);
  font-weight: var(--fw-medium);
  color: var(--c-text);
}

.chip-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  flex-shrink: 0;
}

.chip-text {
  max-width: 120px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.chip-remove {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 18px;
  height: 18px;
  padding: 0;
  background: transparent;
  border: 0;
  border-radius: 50%;
  color: var(--c-text-dim);
  cursor: pointer;
  font-size: 0.75rem;
  line-height: 1;
  transition: var(--tr-fast);
  flex-shrink: 0;
}

.chip-remove:hover {
  background: var(--c-danger);
  color: #fff;
}

.chip-empty {
  font-size: var(--fs-xs);
  color: var(--c-text-dim);
  font-style: italic;
  padding: var(--s-2) 0;
}

/* Open Tickets */
.open-tickets-list {
  display: flex;
  flex-direction: column;
  gap: var(--s-2);
}

.open-ticket-item {
  display: flex;
  align-items: center;
  gap: var(--s-3);
  padding: var(--s-3) var(--s-4);
  background: var(--c-surface-2);
  border: 1px solid var(--c-border);
  border-radius: var(--r-md);
  transition: var(--tr-fast);
}

.open-ticket-item:hover {
  border-color: var(--c-border-hi);
  background: var(--c-surface-3);
}

.open-ticket-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  background: rgba(88, 101, 242, 0.15);
  border-radius: var(--r-md);
  font-size: var(--fs-lg);
  flex-shrink: 0;
}

.open-ticket-content {
  flex: 1;
  min-width: 0;
}

.open-ticket-title {
  font-size: var(--fs-sm);
  font-weight: var(--fw-bold);
  color: var(--c-text);
  margin-bottom: 2px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.open-ticket-meta {
  display: flex;
  gap: var(--s-3);
  font-size: var(--fs-xs);
  color: var(--c-text-mut);
  flex-wrap: wrap;
}

.open-ticket-actions {
  flex-shrink: 0;
}

/* ==========================================
   🪟 MODAL (Dash)
   ========================================== */

.dash-modal {
  position: fixed;
  inset: 0;
  z-index: var(--z-max);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--s-4);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.25s var(--ease), visibility 0.25s;
}

.dash-modal[data-open="true"] {
  opacity: 1;
  visibility: visible;
}

.dash-modal[hidden] {
  display: none;
}

.dash-modal-backdrop {
  position: absolute;
  inset: 0;
  background: var(--backdrop);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

.dash-modal-content {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 580px;
  max-height: calc(100vh - var(--s-8));
  background: var(--c-surface);
  border: 1px solid var(--c-border);
  border-radius: var(--r-2xl);
  box-shadow: var(--sh-2xl);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  transform: scale(0.95) translateY(10px);
  transition: transform 0.3s var(--ease-bounce);
}

.dash-modal[data-open="true"] .dash-modal-content {
  transform: scale(1) translateY(0);
}

.dash-modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--s-3);
  padding: var(--s-5) var(--s-6);
  border-bottom: 1px solid var(--c-border);
  flex-shrink: 0;
}

.dash-modal-title {
  font-size: var(--fs-xl);
  font-weight: var(--fw-bold);
  color: var(--c-text);
  margin: 0;
}

.dash-modal-close {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  background: transparent;
  border: 1px solid var(--c-border);
  border-radius: var(--r-md);
  color: var(--c-text-mut);
  cursor: pointer;
  transition: var(--tr-fast);
  font-size: var(--fs-base);
}

.dash-modal-close:hover {
  color: var(--c-text);
  background: var(--c-surface-2);
}

.dash-modal-body {
  padding: var(--s-6);
  overflow-y: auto;
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
  gap: var(--s-4);
}

.dash-modal-footer {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: var(--s-3);
  padding: var(--s-4) var(--s-6);
  border-top: 1px solid var(--c-border);
  background: var(--c-bg-alt);
  flex-shrink: 0;
}

/* Mobile modal */
@media (max-width: 640px) {
  .dash-modal {
    align-items: flex-end;
    padding: 0;
  }
  
  .dash-modal-content {
    max-height: 92vh;
    border-radius: var(--r-2xl) var(--r-2xl) 0 0;
    transform: translateY(100%);
  }
  
  .dash-modal[data-open="true"] .dash-modal-content {
    transform: translateY(0);
  }
  
  .dash-modal-footer .btn {
    flex: 1;
  }
  
  .types-grid {
    grid-template-columns: 1fr;
  }
}
/* ==========================================
   🎯 EMBED BUILDER PAGE
   ========================================== */

.embed-builder {
  display: grid;
  grid-template-columns: 1fr 480px;
  gap: var(--s-5);
  align-items: start;
}

@media (max-width: 1200px) {
  .embed-builder {
    grid-template-columns: 1fr;
  }
}

.embed-editor {
  display: flex;
  flex-direction: column;
  gap: var(--s-4);
  min-width: 0;
}

.embed-preview-panel {
  display: flex;
  flex-direction: column;
  gap: var(--s-4);
  position: sticky;
  top: 90px;
  max-height: calc(100vh - 120px);
  overflow-y: auto;
}

@media (max-width: 1200px) {
  .embed-preview-panel {
    position: static;
    max-height: none;
  }
}

/* Sections */
.embed-section {
  padding: var(--s-5);
  background: var(--c-surface);
  border: 1px solid var(--c-border);
  border-radius: var(--r-xl);
}

.embed-section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--s-3);
  padding-bottom: var(--s-3);
  margin-bottom: var(--s-4);
  border-bottom: 1px solid var(--c-border);
  flex-wrap: wrap;
}

.embed-section-title {
  display: flex;
  align-items: center;
  gap: var(--s-2);
  font-size: var(--fs-base);
  font-weight: var(--fw-bold);
  color: var(--c-text);
  margin: 0;
}

.embed-section-count {
  font-size: var(--fs-xs);
  color: var(--c-text-mut);
  font-weight: var(--fw-medium);
}

/* Fields */
.embed-field {
  display: flex;
  flex-direction: column;
  gap: var(--s-2);
  margin-bottom: var(--s-4);
}

.embed-field:last-child {
  margin-bottom: 0;
}

.embed-label {
  font-size: var(--fs-sm);
  font-weight: var(--fw-bold);
  color: var(--c-text);
  display: flex;
  align-items: center;
  gap: var(--s-2);
}

.embed-hint {
  font-size: var(--fs-xs);
  color: var(--c-text-mut);
  line-height: var(--lh-relaxed);
  margin: 0;
}

.embed-char-count {
  font-size: var(--fs-xs);
  color: var(--c-text-dim);
  align-self: flex-end;
  font-family: var(--f-mono);
}

/* Templates */
.embed-template-save {
  display: flex;
  gap: var(--s-2);
  margin-bottom: var(--s-4);
}

.embed-template-save .input {
  flex: 1;
}

.embed-templates-list {
  display: flex;
  flex-direction: column;
  gap: var(--s-2);
  max-height: 200px;
  overflow-y: auto;
}

.embed-template-item {
  display: flex;
  align-items: center;
  gap: var(--s-2);
  padding: var(--s-3);
  background: var(--c-surface-2);
  border: 1px solid var(--c-border);
  border-radius: var(--r-md);
  transition: var(--tr-fast);
}

.embed-template-item:hover {
  border-color: var(--c-border-hi);
  background: var(--c-surface-3);
}

.embed-template-info {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.embed-template-name {
  font-size: var(--fs-sm);
  font-weight: var(--fw-bold);
  color: var(--c-text);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.embed-template-date {
  font-size: var(--fs-xs);
  color: var(--c-text-mut);
}

.embed-template-actions {
  display: flex;
  gap: 4px;
  flex-shrink: 0;
}

/* Fields list */
.embed-fields-list {
  display: flex;
  flex-direction: column;
  gap: var(--s-3);
}

.embed-field-item {
  padding: var(--s-4);
  background: var(--c-surface-2);
  border: 1px solid var(--c-border);
  border-radius: var(--r-lg);
}

.embed-field-item-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: var(--s-3);
}

.embed-field-item-num {
  display: inline-flex;
  align-items: center;
  padding: 2px 10px;
  background: rgba(242, 194, 60, 0.15);
  color: var(--c-primary-400);
  border-radius: var(--r-full);
  font-family: var(--f-mono);
  font-size: var(--fs-xs);
  font-weight: var(--fw-black);
}

/* Switch row */
.switch-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--s-3);
  padding: var(--s-3) var(--s-4);
  background: var(--c-surface-2);
  border: 1px solid var(--c-border);
  border-radius: var(--r-md);
  cursor: pointer;
  user-select: none;
}

.switch-row-sm {
  padding: var(--s-2) var(--s-3);
}

.switch-info {
  display: flex;
  flex-direction: column;
  gap: 2px;
  flex: 1;
  min-width: 0;
}

/* Preview */
.embed-preview-section {
  position: relative;
}

.embed-preview-wrap {
  background: #36393f;
  border-radius: var(--r-md);
  padding: var(--s-4);
  overflow: hidden;
}

.discord-message {
  display: flex;
  gap: var(--s-3);
  align-items: flex-start;
}

.discord-message-avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  overflow: hidden;
  flex-shrink: 0;
  background: #5865F2;
}

.discord-message-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.discord-message-body {
  flex: 1;
  min-width: 0;
}

.discord-message-header {
  display: flex;
  align-items: baseline;
  gap: 6px;
  margin-bottom: 6px;
  flex-wrap: wrap;
}

.discord-message-author {
  font-size: 15px;
  font-weight: 600;
  color: #ffffff;
}

.discord-message-bot-tag {
  padding: 1px 4px;
  background: #5865F2;
  color: #ffffff;
  border-radius: 3px;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.5px;
}

.discord-message-time {
  font-size: 11px;
  color: #96989d;
}

.discord-embed {
  padding: 10px 14px;
  background: #2f3136;
  border-left: 4px solid #5865F2;
  border-radius: 4px;
  max-width: 100%;
  margin-top: 4px;
}

.discord-embed-empty {
  padding: var(--s-5);
  text-align: center;
  color: #72767d;
  font-size: 13px;
  font-style: italic;
}

.discord-embed-author {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 8px;
  font-size: 12px;
  font-weight: 600;
  color: #ffffff;
}

.discord-embed-author img {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  object-fit: cover;
}

.discord-embed-main {
  display: flex;
  gap: 12px;
  align-items: flex-start;
}

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

.discord-embed-title {
  font-size: 16px;
  font-weight: 600;
  color: #ffffff;
  margin-bottom: 8px;
  display: block;
  text-decoration: none;
  word-break: break-word;
}

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

.discord-embed-description {
  font-size: 14px;
  color: #dcddde;
  line-height: 1.5;
  word-wrap: break-word;
  overflow-wrap: break-word;
}

.discord-embed-description code {
  background: #202225;
  padding: 1px 4px;
  border-radius: 3px;
  font-size: 12px;
  color: #dcddde;
  border: 0;
}

.discord-embed-thumbnail {
  flex-shrink: 0;
  width: 80px;
  height: 80px;
  border-radius: 4px;
  overflow: hidden;
  background: #202225;
}

.discord-embed-thumbnail img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.discord-embed-fields {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  margin-top: 8px;
}

.discord-embed-field {
  grid-column: span 3;
}

.discord-embed-field.inline {
  grid-column: span 1;
}

.discord-embed-field-name {
  font-size: 14px;
  font-weight: 600;
  color: #ffffff;
  margin-bottom: 2px;
}

.discord-embed-field-value {
  font-size: 14px;
  color: #dcddde;
  line-height: 1.4;
  word-wrap: break-word;
}

.discord-embed-image {
  margin-top: 8px;
  border-radius: 4px;
  overflow: hidden;
  background: #202225;
  max-height: 300px;
}

.discord-embed-image img {
  width: 100%;
  height: auto;
  display: block;
}

.discord-embed-footer {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 8px;
  padding-top: 8px;
  border-top: 0;
  font-size: 12px;
  color: #dcddde;
}

.discord-embed-footer img {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  object-fit: cover;
}

.discord-embed-footer-sep {
  opacity: 0.6;
}

/* Send Panel */
.embed-send-section .btn-block {
  width: 100%;
  margin-top: var(--s-3);
}

/* Mobile */
@media (max-width: 640px) {
  .embed-builder {
    gap: var(--s-4);
  }
  
  .discord-embed-fields {
    grid-template-columns: 1fr;
  }
  
  .discord-embed-field.inline {
    grid-column: span 1;
  }
}
/* ==========================================
   🎯 SHORTCUTS PAGE SPECIFIC
   ========================================== */

/* Toolbar */
.shortcuts-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--s-4);
  margin-bottom: var(--s-5);
  flex-wrap: wrap;
}

.shortcuts-search {
  flex: 1;
  max-width: 400px;
  min-width: 200px;
}

.shortcuts-legend {
  display: flex;
  gap: var(--s-4);
  font-size: var(--fs-xs);
  color: var(--c-text-mut);
}

.shortcut-legend-item {
  display: inline-flex;
  align-items: center;
  gap: var(--s-2);
}

.shortcut-legend-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--c-surface-3);
  border: 1px solid var(--c-border);
}

.shortcut-legend-dot.active {
  background: linear-gradient(180deg, #4ade80, #22c55e);
  border-color: #22c55e;
  box-shadow: 0 0 8px rgba(74, 222, 128, 0.6);
}

/* Stats in header */
.shortcuts-stats {
  display: flex;
  align-items: center;
  gap: var(--s-3);
  padding: var(--s-2) var(--s-4);
  background: linear-gradient(135deg, rgba(242, 194, 60, 0.1), rgba(242, 194, 60, 0.03));
  border: 1px solid rgba(242, 194, 60, 0.3);
  border-radius: var(--r-lg);
}

.shortcut-stat {
  display: flex;
  align-items: baseline;
  gap: 6px;
}

.shortcut-stat-value {
  font-size: var(--fs-xl);
  font-weight: var(--fw-black);
  color: var(--c-primary-400);
  font-family: var(--f-mono);
  line-height: 1;
}

.shortcut-stat-label {
  font-size: var(--fs-xs);
  color: var(--c-text-mut);
}

/* Category Sections */
.shortcuts-container {
  display: flex;
  flex-direction: column;
  gap: var(--s-3);
}

.category-section {
  background: var(--c-surface);
  border: 1px solid var(--c-border);
  border-radius: var(--r-xl);
  overflow: hidden;
  transition: var(--tr-base);
}

.category-section.open {
  border-color: var(--c-border-hi);
}

.category-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--s-3);
  padding: var(--s-4) var(--s-5);
  cursor: pointer;
  user-select: none;
  transition: background var(--t-fast);
}

.category-header:hover {
  background: var(--c-surface-2);
}

.category-header-left {
  display: flex;
  align-items: center;
  gap: var(--s-3);
  flex: 1;
  min-width: 0;
}

.category-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: var(--r-md);
  font-size: var(--fs-xl);
  flex-shrink: 0;
}

.category-info {
  flex: 1;
  min-width: 0;
}

.category-name {
  font-size: var(--fs-base);
  font-weight: var(--fw-bold);
  color: var(--c-text);
  margin: 0 0 2px;
  line-height: var(--lh-tight);
}

.category-count {
  font-size: var(--fs-xs);
  color: var(--c-text-mut);
  margin: 0;
}

.category-arrow {
  font-size: var(--fs-xs);
  color: var(--c-text-mut);
  transition: transform var(--t-fast);
  flex-shrink: 0;
  width: 24px;
  text-align: center;
}

.category-commands {
  display: none;
  padding: 0 var(--s-5) var(--s-5);
  flex-direction: column;
  gap: var(--s-2);
}

.category-section.open .category-commands {
  display: flex;
}

/* Command Item */
.command-item {
  display: flex;
  align-items: center;
  gap: var(--s-3);
  padding: var(--s-3) var(--s-4);
  background: var(--c-surface-2);
  border: 1px solid var(--c-border);
  border-radius: var(--r-md);
  transition: var(--tr-base);
}

.command-item:hover {
  border-color: var(--c-border-hi);
  background: var(--c-surface-3);
}

.command-item.has-shortcut {
  border-color: rgba(74, 222, 128, 0.3);
  background: linear-gradient(135deg, rgba(74, 222, 128, 0.05), var(--c-surface-2));
}

.command-info {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.command-name {
  display: inline-flex;
  align-items: center;
  padding: 3px 10px;
  background: var(--c-bg);
  border: 1px solid var(--c-border);
  border-radius: var(--r-sm);
  font-family: var(--f-mono);
  font-size: var(--fs-xs);
  font-weight: var(--fw-bold);
  color: var(--c-primary-400);
  width: fit-content;
  direction: ltr;
}

.command-desc {
  font-size: var(--fs-xs);
  color: var(--c-text-mut);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.command-actions {
  display: flex;
  align-items: center;
  gap: var(--s-2);
  flex-shrink: 0;
}

/* Shortcut Badge */
.shortcut-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  background: linear-gradient(135deg, rgba(74, 222, 128, 0.15), rgba(34, 197, 94, 0.08));
  border: 1px solid rgba(74, 222, 128, 0.3);
  border-radius: var(--r-full);
  color: #4ade80;
  font-size: var(--fs-xs);
  font-weight: var(--fw-bold);
}

.shortcut-badge-icon {
  font-size: var(--fs-sm);
}

.shortcut-badge code {
  font-family: var(--f-mono);
  font-size: var(--fs-xs);
  color: inherit;
  background: transparent;
  border: 0;
  padding: 0;
  direction: ltr;
}

/* Modal Command Info */
.shortcut-modal-command {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: var(--s-3) var(--s-4);
  background: var(--c-surface-2);
  border: 1px solid var(--c-border);
  border-radius: var(--r-md);
}

.shortcut-modal-command code {
  display: inline-flex;
  align-items: center;
  padding: 3px 10px;
  background: var(--c-bg);
  border: 1px solid var(--c-border);
  border-radius: var(--r-sm);
  font-family: var(--f-mono);
  font-size: var(--fs-sm);
  font-weight: var(--fw-bold);
  color: var(--c-primary-400);
  width: fit-content;
  direction: ltr;
}

.shortcut-modal-command-desc {
  font-size: var(--fs-xs);
  color: var(--c-text-mut);
}

/* Shortcut Input Wrapper */
.shortcut-input-wrapper {
  display: flex;
  align-items: stretch;
  background: var(--c-bg);
  border: 2px solid var(--c-border);
  border-radius: var(--r-md);
  overflow: hidden;
  transition: var(--tr-fast);
}

.shortcut-input-wrapper:focus-within {
  border-color: var(--c-primary-500);
  box-shadow: 0 0 0 3px rgba(242, 194, 60, 0.15);
}

.shortcut-prefix {
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 44px;
  padding: 0 var(--s-4);
  background: linear-gradient(180deg, var(--c-primary-500), var(--c-primary-700));
  color: var(--c-text-inv);
  font-family: var(--f-mono);
  font-size: var(--fs-lg);
  font-weight: var(--fw-black);
  border-inline-end: 1px solid var(--c-border);
}

.shortcut-input-wrapper .input {
  flex: 1;
  border: 0;
  border-radius: 0;
  background: transparent;
  font-family: var(--f-mono);
  font-size: var(--fs-base);
  font-weight: var(--fw-bold);
  color: var(--c-text);
  direction: ltr;
  text-align: start;
  padding: var(--s-3) var(--s-4);
}

.shortcut-input-wrapper .input:focus {
  box-shadow: none;
}

/* Rules */
.shortcut-rules {
  padding: var(--s-4);
  background: rgba(59, 130, 246, 0.05);
  border: 1px solid rgba(59, 130, 246, 0.2);
  border-radius: var(--r-md);
  margin-top: var(--s-2);
}

.shortcut-rules-title {
  font-size: var(--fs-sm);
  font-weight: var(--fw-bold);
  color: #93c5fd;
  margin: 0 0 var(--s-2);
}

.shortcut-rules-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.shortcut-rules-list li {
  font-size: var(--fs-xs);
  color: var(--c-text-mut);
  line-height: var(--lh-relaxed);
}

/* Mobile */
@media (max-width: 640px) {
  .shortcuts-toolbar {
    flex-direction: column;
    align-items: stretch;
  }

  .shortcuts-search {
    max-width: 100%;
  }

  .shortcuts-legend {
    justify-content: center;
  }

  .shortcuts-stats {
    display: none;
  }

  .command-item {
    flex-direction: column;
    align-items: stretch;
    gap: var(--s-3);
  }

  .command-actions {
    width: 100%;
    justify-content: flex-end;
  }

  .command-actions .btn {
    flex: 1;
    justify-content: center;
  }

  .shortcut-badge {
    flex: 1;
    justify-content: center;
  }
}
/* ==========================================
   🎯 SERVER MANAGER PAGE
   ========================================== */

/* SM List */
.sm-list {
  display: flex;
  flex-direction: column;
  gap: var(--s-2);
}

.sm-item {
  display: flex;
  align-items: center;
  gap: var(--s-3);
  padding: var(--s-3) var(--s-4);
  background: var(--c-surface-2);
  border: 1px solid var(--c-border);
  border-radius: var(--r-md);
  transition: var(--tr-fast);
}

.sm-item:hover {
  border-color: var(--c-border-hi);
  background: var(--c-surface-3);
}

.sm-item-managed {
  opacity: 0.7;
}

.sm-item-drag {
  font-size: var(--fs-sm);
  color: var(--c-text-dim);
  cursor: grab;
  user-select: none;
  padding: 0 4px;
  line-height: 1;
  letter-spacing: -2px;
}

.sm-item-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  background: var(--c-bg);
  border: 1px solid var(--c-border);
  border-radius: var(--r-md);
  font-size: var(--fs-lg);
  flex-shrink: 0;
}

.sm-role-color {
  width: 16px;
  height: 16px;
  border-radius: 50%;
  flex-shrink: 0;
  border: 2px solid var(--c-bg);
  box-shadow: 0 0 0 1px var(--c-border-hi);
}

.sm-item-content {
  flex: 1;
  min-width: 0;
}

.sm-item-name {
  font-size: var(--fs-sm);
  font-weight: var(--fw-bold);
  color: var(--c-text);
  margin-bottom: 2px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.sm-item-meta {
  font-size: var(--fs-xs);
  color: var(--c-text-mut);
  display: flex;
  align-items: center;
  gap: var(--s-2);
  flex-wrap: wrap;
}

.sm-item-actions {
  display: flex;
  gap: 4px;
  flex-shrink: 0;
}

/* Log */
.sm-log {
  display: flex;
  flex-direction: column;
  gap: var(--s-2);
}

.sm-log-item {
  display: flex;
  align-items: flex-start;
  gap: var(--s-3);
  padding: var(--s-3) var(--s-4);
  background: var(--c-surface-2);
  border: 1px solid var(--c-border);
  border-radius: var(--r-md);
  transition: var(--tr-fast);
}

.sm-log-item:hover {
  border-color: var(--c-border-hi);
}

.sm-log-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  background: var(--c-bg);
  border-radius: var(--r-md);
  font-size: var(--fs-base);
  flex-shrink: 0;
}

.sm-log-content {
  flex: 1;
  min-width: 0;
}

.sm-log-action {
  font-size: var(--fs-sm);
  font-weight: var(--fw-bold);
  color: var(--c-text);
  margin-bottom: 4px;
}

.sm-log-meta {
  display: flex;
  gap: var(--s-3);
  font-size: var(--fs-xs);
  color: var(--c-text-mut);
  flex-wrap: wrap;
}

@media (max-width: 640px) {
  .sm-item {
    flex-wrap: wrap;
  }
  
  .sm-item-content {
    flex-basis: 100%;
  }
}
/* ==========================================
   🎯 SHOP ADMIN PAGE
   ========================================== */

/* Balance in header */
.shop-admin-balance {
  display: flex;
  align-items: center;
  gap: var(--s-3);
  padding: var(--s-2) var(--s-4);
  background: linear-gradient(135deg, rgba(242, 194, 60, 0.12), rgba(242, 194, 60, 0.03));
  border: 1px solid rgba(242, 194, 60, 0.3);
  border-radius: var(--r-lg);
}

.shop-admin-balance-icon {
  font-size: var(--fs-2xl);
  line-height: 1;
}

.shop-admin-balance-info {
  display: flex;
  flex-direction: column;
  gap: 1px;
}

.shop-admin-balance-label {
  font-size: var(--fs-2xs);
  color: var(--c-text-mut);
  text-transform: uppercase;
  letter-spacing: var(--ls-wider);
}

.shop-admin-balance-value {
  font-size: var(--fs-lg);
  font-weight: var(--fw-black);
  color: var(--c-primary-400);
  font-family: var(--f-mono);
  line-height: 1;
}

/* Category tabs (horizontal) */
.shop-category-tabs {
  display: flex;
  gap: var(--s-2);
  padding: var(--s-1);
  background: var(--c-surface-2);
  border: 1px solid var(--c-border);
  border-radius: var(--r-lg);
  overflow-x: auto;
  scrollbar-width: none;
  width: 100%;
}

.shop-category-tabs::-webkit-scrollbar {
  display: none;
}

.shop-category-tab {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: var(--s-2) var(--s-4);
  background: transparent;
  border: 0;
  border-radius: var(--r-md);
  font-family: inherit;
  font-size: var(--fs-sm);
  font-weight: var(--fw-medium);
  color: var(--c-text-mut);
  cursor: pointer;
  transition: var(--tr-fast);
  white-space: nowrap;
  flex-shrink: 0;
}

.shop-category-tab:hover {
  color: var(--c-text);
  background: var(--c-surface-3);
}

.shop-category-tab.active {
  background: var(--g-gold);
  color: var(--c-text-inv);
  font-weight: var(--fw-bold);
  box-shadow: 0 2px 8px -2px rgba(242, 194, 60, 0.4);
}

/* Rarity badge in shop item */
.rarity-badge {
  position: absolute;
  top: var(--s-2);
  inset-inline-start: var(--s-2);
  padding: 3px 8px;
  background: rgba(0, 0, 0, 0.75);
  color: #ffffff;
  border-radius: var(--r-full);
  font-size: 0.625rem;
  font-weight: var(--fw-black);
  text-transform: uppercase;
  letter-spacing: var(--ls-wider);
  z-index: 2;
  backdrop-filter: blur(4px);
}

.shop-item.rarity-common .rarity-badge { color: #9ca3af; }
.shop-item.rarity-rare .rarity-badge { color: #60a5fa; }
.shop-item.rarity-epic .rarity-badge { color: #c084fc; }
.shop-item.rarity-legendary .rarity-badge { color: #fbbf24; }

/* Buy button disabled */
.item-btn.buy-btn.disabled,
.item-btn.buy-btn:disabled {
  background: var(--c-surface-2);
  color: var(--c-text-mut);
  cursor: not-allowed;
  opacity: 0.7;
}

/* Skeleton cards */
.shop-item-skeleton {
  background: var(--c-surface);
  border: 2px solid var(--c-border);
  border-radius: 14px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  min-height: 260px;
}

/* Top items list */
.top-items-list {
  display: flex;
  flex-direction: column;
  gap: var(--s-2);
}

.top-item-row {
  display: flex;
  align-items: center;
  gap: var(--s-3);
  padding: var(--s-3) var(--s-4);
  background: var(--c-surface-2);
  border: 1px solid var(--c-border);
  border-radius: var(--r-md);
  transition: var(--tr-fast);
}

.top-item-row:hover {
  border-color: var(--c-border-hi);
}

.top-item-rank {
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 32px;
  height: 32px;
  font-size: var(--fs-lg);
  font-weight: var(--fw-black);
  color: var(--c-text-mut);
  flex-shrink: 0;
}

.top-item-name {
  flex: 1;
  min-width: 0;
  font-size: var(--fs-sm);
  font-weight: var(--fw-medium);
  color: var(--c-text);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.top-item-count {
  padding: 4px 10px;
  background: rgba(242, 194, 60, 0.15);
  color: var(--c-primary-400);
  border-radius: var(--r-full);
  font-size: var(--fs-xs);
  font-weight: var(--fw-bold);
  white-space: nowrap;
  flex-shrink: 0;
}

@media (max-width: 640px) {
  .shop-admin-balance {
    display: none;
  }
  
  .shop-category-tabs {
    gap: 4px;
  }
  
  .shop-category-tab {
    padding: 6px 12px;
    font-size: var(--fs-xs);
  }
}
/* ==========================================
   🎯 PROFILE PAGE SPECIFIC
   ========================================== */

/* Profile Header */
.profile-header-card {
  padding: var(--s-6);
  background: linear-gradient(135deg, rgba(242, 194, 60, 0.08), rgba(242, 194, 60, 0.02));
  border: 1px solid rgba(242, 194, 60, 0.25);
  border-radius: var(--r-2xl);
  margin-bottom: var(--s-6);
  position: relative;
  overflow: hidden;
}

.profile-header-card::before {
  content: '';
  position: absolute;
  top: -50%;
  inset-inline-end: -10%;
  width: 400px;
  height: 400px;
  background: radial-gradient(circle, rgba(242, 194, 60, 0.15), transparent 60%);
  pointer-events: none;
}

.profile-header-content {
  display: flex;
  align-items: center;
  gap: var(--s-5);
  position: relative;
  z-index: 1;
  flex-wrap: wrap;
}

.profile-header-avatar {
  flex-shrink: 0;
}

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

.profile-header-name-row {
  display: flex;
  align-items: center;
  gap: var(--s-3);
  margin-bottom: var(--s-1);
  flex-wrap: wrap;
}

.profile-header-name {
  font-size: clamp(var(--fs-2xl), 4vw, var(--fs-4xl));
  font-weight: var(--fw-black);
  color: var(--c-text);
  margin: 0;
  line-height: var(--lh-tight);
  letter-spacing: var(--ls-tight);
}

.profile-header-handle {
  font-size: var(--fs-sm);
  color: var(--c-text-mut);
  margin: 0 0 var(--s-3);
}

.profile-header-badges {
  display: flex;
  gap: var(--s-2);
  flex-wrap: wrap;
}

/* Badges for header */
.premium-badge-lg,

.premium-badge-lg {
  background: linear-gradient(135deg, #e0bbe4, #a855f7);
  color: #1a0a28;
  box-shadow: 0 4px 16px -4px rgba(168, 85, 247, 0.6);
}


/* Daily Card */
.daily-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--s-4);
  padding: var(--s-5) var(--s-6);
  background: linear-gradient(135deg, rgba(16, 185, 129, 0.08), rgba(16, 185, 129, 0.02));
  border: 1px solid rgba(16, 185, 129, 0.3);
  border-radius: var(--r-xl);
  margin-bottom: var(--s-5);
  flex-wrap: wrap;
}

.daily-card-header {
  display: flex;
  align-items: center;
  gap: var(--s-4);
  flex: 1;
  min-width: 200px;
}

.daily-card-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 56px;
  height: 56px;
  background: linear-gradient(135deg, #6ee7b7, #10b981);
  border-radius: var(--r-lg);
  font-size: var(--fs-3xl);
  flex-shrink: 0;
  box-shadow: 0 8px 24px -8px rgba(16, 185, 129, 0.6);
  animation: heartbeat 2s ease-in-out infinite;
}

.daily-card-info {
  flex: 1;
  min-width: 0;
}

.daily-card-title {
  font-size: var(--fs-lg);
  font-weight: var(--fw-black);
  color: var(--c-text);
  margin: 0 0 2px;
}

.daily-card-desc {
  font-size: var(--fs-sm);
  color: var(--c-text-mut);
  margin: 0;
}

.daily-card-desc #daily-timer {
  font-family: var(--f-mono);
  color: var(--c-primary-400);
  font-weight: var(--fw-bold);
}

.daily-claim-btn {
  min-height: 48px;
  padding: 12px 28px;
  flex-shrink: 0;
}

/* Level Progress */
.level-progress-header {
  display: flex;
  align-items: center;
  gap: var(--s-4);
  flex-wrap: wrap;
}

.level-badge-lg {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-width: 80px;
  padding: var(--s-3) var(--s-4);
  background: linear-gradient(135deg, var(--c-primary-500), var(--c-primary-700));
  color: var(--c-text-inv);
  border-radius: var(--r-lg);
  flex-shrink: 0;
  box-shadow: 0 8px 24px -8px rgba(242, 194, 60, 0.6);
}

.level-badge-label {
  font-size: var(--fs-2xs);
  text-transform: uppercase;
  letter-spacing: var(--ls-wider);
  opacity: 0.85;
}

.level-badge-value {
  font-size: var(--fs-3xl);
  font-weight: var(--fw-black);
  line-height: 1;
  letter-spacing: var(--ls-tight);
}

.level-progress-info {
  flex: 1;
  min-width: 150px;
}

.level-progress-xp {
  font-size: var(--fs-2xl);
  font-weight: var(--fw-black);
  color: var(--c-text);
  line-height: 1;
  margin-bottom: 4px;
}

.level-progress-xp-value {
  color: var(--c-primary-400);
}

.level-progress-xp-sep,
.level-progress-xp-max {
  font-size: 0.7em;
  color: var(--c-text-mut);
}

.level-progress-needed {
  font-size: var(--fs-sm);
  color: var(--c-text-mut);
}

.level-progress-percent {
  text-align: center;
  font-size: var(--fs-sm);
  font-weight: var(--fw-bold);
  color: var(--c-primary-400);
  margin-top: var(--s-2);
}

.level-info-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: var(--s-3);
  margin-top: var(--s-5);
  padding-top: var(--s-5);
  border-top: 1px solid var(--c-border);
}

.level-info-item {
  display: flex;
  align-items: center;
  gap: var(--s-3);
  padding: var(--s-3);
  background: var(--c-surface-2);
  border: 1px solid var(--c-border);
  border-radius: var(--r-md);
}

.level-info-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  background: var(--c-bg);
  border-radius: var(--r-md);
  font-size: var(--fs-lg);
  flex-shrink: 0;
}

.level-info-content {
  flex: 1;
  min-width: 0;
}

.level-info-value {
  font-size: var(--fs-base);
  font-weight: var(--fw-black);
  color: var(--c-text);
  line-height: 1.2;
}

.level-info-label {
  font-size: var(--fs-xs);
  color: var(--c-text-mut);
}

/* Account Info */
.account-info-list {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.account-info-row {
  display: grid;
  grid-template-columns: 32px 1fr auto;
  gap: var(--s-3);
  align-items: center;
  padding: var(--s-3) var(--s-4);
  border-radius: var(--r-md);
  transition: background var(--t-fast);
}

.account-info-row:hover {
  background: var(--c-surface-2);
}

.account-info-icon {
  font-size: var(--fs-lg);
  text-align: center;
}

.account-info-label {
  font-size: var(--fs-sm);
  color: var(--c-text-mut);
}

.account-info-value {
  font-size: var(--fs-sm);
  font-weight: var(--fw-bold);
  color: var(--c-text);
  text-align: end;
}

.account-info-value.mono {
  font-family: var(--f-mono);
  font-size: var(--fs-xs);
  direction: ltr;
}

/* Presets Grid */
.colors-presets-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
  gap: var(--s-3);
}

.color-preset {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--s-2);
  padding: var(--s-3);
  background: var(--c-surface-2);
  border: 2px solid var(--c-border);
  border-radius: var(--r-lg);
  cursor: pointer;
  transition: var(--tr-base);
  font-family: inherit;
}

.color-preset:hover {
  transform: translateY(-2px);
  border-color: var(--c-border-hi);
}

.color-preset.active {
  border-color: var(--c-primary-500);
  box-shadow: 0 0 0 1px var(--c-primary-500), 0 8px 24px -8px rgba(242, 194, 60, 0.4);
}

.color-preset-swatch {
  width: 100%;
  height: 40px;
  border-radius: var(--r-md);
  position: relative;
  overflow: hidden;
}

.color-preset-swatch::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(45deg, transparent 40%, rgba(255, 255, 255, 0.2) 50%, transparent 60%);
}

.color-preset-name {
  font-size: var(--fs-xs);
  font-weight: var(--fw-bold);
  color: var(--c-text);
  text-align: center;
}

/* Custom colors grid */
.colors-custom-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: var(--s-4);
}

.color-picker-item {
  display: flex;
  flex-direction: column;
  gap: var(--s-2);
}

.color-picker-label {
  font-size: var(--fs-sm);
  font-weight: var(--fw-bold);
  color: var(--c-text);
}

.color-picker-row {
  display: flex;
  gap: var(--s-2);
  align-items: center;
}

.color-picker-row .color-picker-input {
  width: 48px;
  height: 44px;
  padding: 2px;
  background: var(--c-bg);
  border: 1px solid var(--c-border);
  border-radius: var(--r-md);
  cursor: pointer;
  flex-shrink: 0;
}

.color-picker-row .color-picker-input::-webkit-color-swatch-wrapper { padding: 0; }
.color-picker-row .color-picker-input::-webkit-color-swatch {
  border: none;
  border-radius: var(--r-sm);
}

.color-picker-row .input {
  flex: 1;
  font-family: var(--f-mono);
  font-size: var(--fs-sm);
  text-transform: uppercase;
  direction: ltr;
  text-align: start;
}

/* Profile Preview Container */
.profile-preview-container {
  display: flex;
  justify-content: center;
  padding: var(--s-6);
  background: var(--c-bg-alt);
  border: 1px solid var(--c-border);
  border-radius: var(--r-xl);
}

/* Live Preview */
.live-preview {
  --text-color: #FFFFFF;
  --box-bg: rgba(0, 0, 0, 0.55);
  --box-border: rgba(255, 255, 255, 0.15);
  --accent: #FFD700;
  --border-color: #00d4d4;

  position: relative;
  width: 100%;
  max-width: 400px;
  aspect-ratio: 1;
  padding: 20px;
  background: linear-gradient(135deg, #0a1628 0%, #1a3a4a 100%);
  border: 3px solid var(--border-color);
  border-radius: 20px;
  box-shadow: 0 0 0 2px var(--accent), 0 12px 40px -8px var(--border-color);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  color: var(--text-color);
  overflow: hidden;
  box-sizing: border-box;
  transition: all var(--t-base) var(--ease);
}

.preview-avatar-ring {
  position: relative;
  width: 80px;
  height: 80px;
  border-radius: 50%;
  background: conic-gradient(from 0deg, var(--border-color), var(--accent), var(--border-color));
  padding: 3px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.preview-avatar {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  object-fit: cover;
  background: linear-gradient(135deg, var(--accent), var(--border-color));
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.6rem;
  font-weight: 900;
  color: #0d0c0a;
}

.preview-name-row {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  flex-wrap: wrap;
  max-width: 100%;
  padding: 0 6px;
}

.preview-name {
  font-size: 1.1rem;
  font-weight: 900;
  color: var(--text-color);
  text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.9);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 200px;
}

.preview-badge {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 5px;
  font-size: 0.65rem;
  font-weight: 900;
  letter-spacing: 1px;
  text-transform: uppercase;
  white-space: nowrap;
  flex-shrink: 0;
}


.premium-badge {
  background: #1a0a28;
  color: #E0BBE4;
  border: 1.5px solid #E0BBE4;
  box-shadow: 0 0 8px rgba(224, 187, 228, 0.4);
}

.preview-handle {
  font-size: 0.75rem;
  color: rgba(255, 255, 255, 0.6);
  margin-top: -2px;
}

.preview-stats {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
  width: 100%;
  margin-top: 8px;
}

.preview-box {
  padding: 8px 10px;
  background: var(--box-bg);
  border: 1.5px solid var(--box-border);
  border-radius: 10px;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.preview-box-label {
  font-size: 0.6rem;
  font-weight: 700;
  color: rgba(255, 255, 255, 0.65);
  letter-spacing: 1px;
}

.preview-box-value {
  font-size: 0.95rem;
  font-weight: 900;
  color: var(--text-color);
}

.preview-progress-container {
  width: 100%;
  margin-top: 6px;
}

.preview-progress {
  width: 100%;
  height: 16px;
  background: rgba(0, 0, 0, 0.75);
  border: 1.5px solid var(--box-border);
  border-radius: 8px;
  overflow: hidden;
}

.preview-progress-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--accent), var(--border-color));
  border-radius: 6px;
  transition: width var(--t-slow) var(--ease);
}

.preview-progress-info {
  display: flex;
  justify-content: space-between;
  font-size: 0.65rem;
  font-weight: 700;
  margin-top: 3px;
}

.preview-progress-info .left {
  color: var(--accent);
}

.preview-progress-info .right {
  color: rgba(255, 255, 255, 0.8);
}

/* Mobile */
@media (max-width: 640px) {
  .profile-header-card {
    padding: var(--s-4);
  }

  .profile-header-content {
    flex-direction: column;
    text-align: center;
    gap: var(--s-3);
  }

  .profile-header-name-row,
  .profile-header-badges {
    justify-content: center;
  }

  .daily-card {
    flex-direction: column;
    align-items: stretch;
  }

  .daily-claim-btn {
    width: 100%;
  }

  .colors-presets-grid {
    grid-template-columns: repeat(3, 1fr);
  }

  .colors-custom-grid {
    grid-template-columns: 1fr;
  }

  .account-info-row {
    grid-template-columns: 32px 1fr;
    gap: var(--s-2);
  }

  .account-info-value {
    grid-column: 1 / -1;
    text-align: start;
    padding-inline-start: 44px;
  }

  .live-preview {
    max-width: 320px;
    padding: 16px;
  }
}
/* ==========================================
   🎯 SETTINGS PAGE SPECIFIC
   ========================================== */

/* Tab danger */
.tab-danger.active {
  background: var(--c-danger);
  color: #ffffff;
}

.tab-danger:hover:not(.active) {
  color: var(--c-danger);
}

/* Disabled switch row */
.dash-form-switch-row.disabled {
  opacity: 0.5;
}

.dash-form-switch-row.disabled .dash-form-switch-label {
  color: var(--c-text-dim);
}

/* Theme selector */
.theme-selector {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: var(--s-3);
}

.theme-option {
  display: flex;
  align-items: center;
  gap: var(--s-3);
  padding: var(--s-4);
  background: var(--c-surface-2);
  border: 2px solid var(--c-border);
  border-radius: var(--r-lg);
  cursor: pointer;
  transition: var(--tr-base);
  font-family: inherit;
  text-align: start;
  position: relative;
}

.theme-option:hover {
  border-color: var(--c-border-hi);
  transform: translateY(-2px);
}

.theme-option.active {
  border-color: var(--c-primary-500);
  background: linear-gradient(135deg, rgba(242, 194, 60, 0.08), var(--c-surface-2));
  box-shadow: 0 0 0 1px var(--c-primary-500), 0 8px 24px -8px rgba(242, 194, 60, 0.4);
}

.theme-option-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  background: var(--c-bg);
  border-radius: var(--r-md);
  font-size: var(--fs-2xl);
  flex-shrink: 0;
}

.theme-option.active .theme-option-icon {
  background: rgba(242, 194, 60, 0.15);
}

.theme-option-info {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.theme-option-name {
  font-size: var(--fs-base);
  font-weight: var(--fw-bold);
  color: var(--c-text);
}

.theme-option-desc {
  font-size: var(--fs-xs);
  color: var(--c-text-mut);
  line-height: var(--lh-relaxed);
}

.theme-option-check {
  font-size: var(--fs-lg);
  font-weight: var(--fw-black);
  color: var(--c-primary-500);
  flex-shrink: 0;
  width: 24px;
  text-align: center;
}

/* Theme preview */
.theme-preview {
  padding: var(--s-5);
  background: var(--c-bg-alt);
  border: 1px solid var(--c-border);
  border-radius: var(--r-lg);
  display: flex;
  justify-content: center;
}

.theme-preview-card {
  width: 100%;
  max-width: 320px;
  background: var(--c-surface);
  border: 1px solid var(--c-border);
  border-radius: var(--r-md);
  padding: var(--s-4);
  transition: all var(--t-base);
}

.theme-preview-header {
  display: flex;
  align-items: center;
  gap: var(--s-3);
  padding-bottom: var(--s-3);
  border-bottom: 1px solid var(--c-border);
  margin-bottom: var(--s-3);
}

.theme-preview-avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--g-gold);
  flex-shrink: 0;
}

.theme-preview-info {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.theme-preview-name {
  height: 12px;
  width: 60%;
  background: var(--c-text);
  border-radius: var(--r-sm);
  opacity: 0.8;
}

.theme-preview-sub {
  height: 8px;
  width: 40%;
  background: var(--c-text-mut);
  border-radius: var(--r-sm);
  opacity: 0.5;
}

.theme-preview-body {
  display: flex;
  flex-direction: column;
  gap: var(--s-2);
}

.theme-preview-line {
  height: 8px;
  width: 100%;
  background: var(--c-text-mut);
  border-radius: var(--r-sm);
  opacity: 0.3;
}

.theme-preview-line.short {
  width: 70%;
}

/* Setting info grid */
.setting-info-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: var(--s-3);
}

.setting-info-item {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: var(--s-3) var(--s-4);
  background: var(--c-surface-2);
  border: 1px solid var(--c-border);
  border-radius: var(--r-md);
}

.setting-info-label {
  font-size: var(--fs-xs);
  color: var(--c-text-mut);
  text-transform: uppercase;
  letter-spacing: var(--ls-wider);
}

.setting-info-value {
  font-size: var(--fs-base);
  font-weight: var(--fw-bold);
  color: var(--c-text);
  font-family: var(--f-mono);
}

/* Account preview */
.account-preview {
  display: flex;
  align-items: center;
  gap: var(--s-4);
  padding: var(--s-4);
  background: var(--c-surface-2);
  border: 1px solid var(--c-border);
  border-radius: var(--r-lg);
}

.account-preview-info {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.account-preview-info h3 {
  font-size: var(--fs-xl);
  font-weight: var(--fw-bold);
  color: var(--c-text);
  margin: 0;
}

.account-preview-info p {
  font-size: var(--fs-sm);
  color: var(--c-text-mut);
  margin: 0;
}

.account-preview-info p.mono {
  font-family: var(--f-mono);
  font-size: var(--fs-xs);
  color: var(--c-text-dim);
  direction: ltr;
  text-align: start;
}

/* Linked services */
.linked-services {
  display: flex;
  flex-direction: column;
  gap: var(--s-2);
}

.service-item {
  display: flex;
  align-items: center;
  gap: var(--s-3);
  padding: var(--s-3) var(--s-4);
  background: var(--c-surface-2);
  border: 1px solid var(--c-border);
  border-radius: var(--r-md);
  transition: var(--tr-fast);
}

.service-item:hover {
  border-color: var(--c-border-hi);
}

.service-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  background: var(--c-bg);
  border-radius: var(--r-md);
  font-size: var(--fs-xl);
  flex-shrink: 0;
}

.service-info {
  flex: 1;
  min-width: 0;
}

.service-name {
  font-size: var(--fs-sm);
  font-weight: var(--fw-bold);
  color: var(--c-text);
  margin-bottom: 2px;
}

.service-status {
  font-size: var(--fs-xs);
  color: var(--c-text-mut);
}

.service-badge {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  font-size: var(--fs-sm);
  font-weight: var(--fw-black);
  flex-shrink: 0;
}

.service-badge.connected {
  background: var(--c-success-bg);
  color: var(--c-success);
  border: 2px solid var(--c-success);
}

.service-badge.disconnected {
  background: var(--c-surface-3);
  color: var(--c-text-dim);
  border: 2px solid var(--c-border);
}

/* Font size range */
.range-with-value {
  display: flex;
  align-items: center;
  gap: var(--s-3);
}

.range-with-value .range {
  flex: 1;
}

/* Mobile */
@media (max-width: 640px) {
  .theme-selector {
    grid-template-columns: 1fr;
  }

  .account-preview {
    flex-direction: column;
    text-align: center;
  }

  .account-preview-info {
    align-items: center;
  }

  .account-preview-info p.mono {
    text-align: center;
  }
}