/**
 * EBIT Theme - تم تیره مدرن با استایل نئو-مورفیک
 * بر اساس طراحی داشبورد EBIT
 */

/* ============================================
   Imports (must be at the top)
   ============================================ */
@import url('https://cdn.jsdelivr.net/gh/rastikerdar/vazirmatn@v33.003/Vazirmatn-font-face.css');
/* تم‌ها به صورت داینامیک از طریق theme-manager.js لود می‌شوند */

/* ============================================
   Global RTL & Persian Text Styles
   ============================================ */
html {
  direction: rtl;
}

body {
  direction: rtl;
  text-align: right;
}

/* تمام عناصر متنی راست‌چین */
p, h1, h2, h3, h4, h5, h6, 
label, span, div, 
li, td, th,
input, textarea, select,
button, a {
  text-align: right;
}

/* استثنا برای عناصر خاص */
.text-center {
  text-align: center !important;
}

.text-left {
  text-align: left !important;
}

/* فرم‌ها */
input, textarea, select {
  direction: rtl;
  text-align: right;
}

input::placeholder,
textarea::placeholder {
  text-align: right;
  direction: rtl;
}

/* جداول */
table {
  direction: rtl;
}

th, td {
  text-align: right;
}

/* لیست‌ها */
ul, ol {
  padding-right: 20px;
  padding-left: 0;
}

/* دکمه‌ها با آیکون */
.btn i,
button i {
  margin-left: 0.5rem;
  margin-right: 0;
}

/* Badge ها */
.badge {
  direction: ltr;
}

/* Flexbox RTL fixes - فقط برای عناصر خاص */
.d-flex.flex-column {
  flex-direction: column !important;
}

/* Modal RTL */
.modal {
  direction: rtl;
  text-align: right;
}

.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.modal-header .close {
  margin: 0;
  padding: 0.5rem;
  order: -1;
}

.modal-footer {
  display: flex;
  justify-content: flex-start;
  gap: 0.5rem;
}

.modal-body .form-group {
  text-align: right;
}

.modal-body .form-group label {
  display: block;
  text-align: right;
  margin-bottom: 0.5rem;
}

.modal-body .form-control {
  text-align: right;
  direction: rtl;
}

/* اعداد در input از چپ به راست */
.modal-body input[type="number"],
.modal-body input[type="date"],
.modal-body input[type="time"],
.modal-body input[type="datetime-local"] {
  text-align: left;
  direction: ltr;
}

/* Select box RTL */
.modal-body select.form-control {
  text-align: right;
  direction: rtl;
}

/* Dropdown */
.dropdown-menu {
  text-align: right;
  right: 0;
  left: auto;
}

/* Cards */
.card, .dashboard-card {
  text-align: right;
}

.card-header, .card-body, .card-footer {
  text-align: right;
}

/* Action buttons in tables */
.action-buttons {
  display: flex;
  gap: 0.5rem;
  justify-content: flex-start;
}

/* ============================================
   Common Variables (Shared between themes)
   ============================================ */
:root {
  /* گوشه‌های گرد */
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-xl: 24px;
  --radius-full: 9999px;
  
  /* فاصله‌ها */
  --spacing-xs: 4px;
  --spacing-sm: 8px;
  --spacing-md: 16px;
  --spacing-lg: 24px;
  --spacing-xl: 32px;
  
  /* فونت Vazir */
  --font-family: 'Vazirmatn', 'Tahoma', 'Arial', sans-serif;
  --font-size-xs: 0.75rem;
  --font-size-sm: 0.875rem;
  --font-size-base: 1rem;
  --font-size-lg: 1.125rem;
  --font-size-xl: 1.25rem;
  --font-size-2xl: 1.5rem;
  --font-size-3xl: 1.875rem;
  --font-size-4xl: 2.25rem;
}

/* ============================================
   Base Styles
   ============================================ */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}



body.dashboard-body {
  overflow-x: hidden;
  background-color: var(--bg-primary);
}

body.dashboard-body::before,
body.dashboard-body::after {
  display: block !important;
  visibility: visible !important;
  opacity: 1 !important;
}

/* ============================================
   Typography
   ============================================ */
h1, h2, h3, h4, h5, h6 {
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: var(--spacing-md);
}

h1 { font-size: var(--font-size-4xl); }
h2 { font-size: var(--font-size-3xl); }
h3 { font-size: var(--font-size-2xl); }
h4 { font-size: var(--font-size-xl); }
h5 { font-size: var(--font-size-lg); }
h6 { font-size: var(--font-size-base); }

p {
  color: var(--text-secondary);
  margin-bottom: var(--spacing-md);
}

a {
  color: var(--accent-primary);
  text-decoration: none;
  transition: color 0.3s ease;
}

a:hover {
  color: var(--accent-secondary);
  text-decoration: none;
}

/* ============================================
   Cards with Glassmorphism Effect
   ============================================ */
.card,
.card.h-100,
.dashboard-card,
.service-card,
.project-card,
.stat-card,
.admin-card,
.auth-card,
.pricing-card {
  background: rgba(44, 44, 44, 0.6) !important;
  backdrop-filter: blur(20px) !important;
  -webkit-backdrop-filter: blur(20px) !important;
  border-radius: 16px !important;
  padding: 24px;
  box-shadow: 
    0 8px 32px rgba(0, 0, 0, 0.3),
    0 0 0 1px rgba(255, 255, 255, 0.05),
    inset 0 1px 0 rgba(255, 255, 255, 0.1) !important;
  transition: all 0.3s ease !important;
  border: 1px solid rgba(255, 255, 255, 0.1) !important;
  position: relative;
  overflow: hidden;
}

/* نور داخلی کارت */
.card::before,
.card.h-100::before,
.dashboard-card::before,
.service-card::before,
.project-card::before,
.stat-card::before,
.admin-card::before,
.auth-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(255, 193, 7, 0.5),
    transparent
  );
  opacity: 0;
  transition: opacity 0.3s ease;
  z-index: 10;
}

.card:hover::before,
.card.h-100:hover::before,
.dashboard-card:hover::before,
.service-card:hover::before,
.project-card:hover::before,
.stat-card:hover::before,
.admin-card:hover::before,
.auth-card:hover::before {
  opacity: 1;
}

.card:hover,
.card.h-100:hover,
.dashboard-card:hover,
.service-card:hover,
.project-card:hover,
.stat-card:hover,
.admin-card:hover,
.auth-card:hover {
  background: rgba(54, 54, 54, 0.75) !important;
  box-shadow: 
    0 12px 40px rgba(0, 0, 0, 0.4),
    0 0 0 1px rgba(255, 193, 7, 0.3),
    0 0 30px rgba(255, 193, 7, 0.15),
    inset 0 1px 0 rgba(255, 255, 255, 0.15) !important;
  transform: translateY(-4px);
}

/* Card Body Style */
.card .card-body,
.card.h-100 .card-body {
  background: transparent !important;
  color: var(--text-primary, #fff);
}

.card-header {
  background: transparent !important;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1) !important;
  padding-bottom: var(--spacing-md);
  margin-bottom: var(--spacing-md);
}

.card-title,
.card h5,
.card h4,
.card h3 {
  font-size: var(--font-size-xl);
  font-weight: 600;
  text-align: right;
  color: var(--text-primary, #fff) !important;
  margin-bottom: 0;
}

.card-body {
  padding: 0;
  background: transparent !important;
}

.card p,
.card .text-secondary {
  color: var(--text-secondary, rgba(255, 255, 255, 0.7)) !important;
}

/* ============================================
   Buttons
   ============================================ */
.btn {
  border-radius: var(--radius-md);
  padding: var(--spacing-sm) var(--spacing-lg);
  font-weight: 600;
  font-size: var(--font-size-sm);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  transition: all 0.3s ease;
  border: none;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--spacing-sm);
}

.btn-primary {
  background: var(--accent-gradient);
  color: var(--text-primary);
  box-shadow: 
    0 4px 15px rgba(255, 193, 7, 0.3),
    0 0 20px rgba(255, 193, 7, 0.2);
  position: relative;
  overflow: hidden;
}

.btn-primary::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(255, 255, 255, 0.3),
    transparent
  );
  transition: left 0.5s ease;
  border-radius: inherit;
}

.btn-primary::after {
  content: '';
  position: absolute;
  top: -2px;
  left: -2px;
  right: -2px;
  bottom: -2px;
  background: var(--accent-gradient);
  border-radius: inherit;
  z-index: -1;
  opacity: 0;
  filter: blur(8px);
  transition: opacity 0.3s ease;
}

.btn-primary:hover::before {
  left: 100%;
}

.btn-primary:hover::after {
  opacity: 0.6;
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 
    0 6px 20px rgba(255, 193, 7, 0.4),
    0 0 30px rgba(255, 193, 7, 0.3),
    inset 0 0 0 1px rgba(255, 255, 255, 0.1);
  color: var(--text-primary);
}

.btn-secondary {
  background-color: var(--bg-card);
  color: var(--text-primary);
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.btn-secondary:hover {
  background-color: var(--bg-card-hover);
  color: var(--text-primary);
}

.btn-outline-primary {
  background-color: transparent;
  color: var(--accent-primary);
  border: 1px solid var(--accent-primary);
}

.btn-outline-primary:hover {
  background-color: var(--accent-primary);
  color: var(--bg-primary);
}

.btn-success {
  background-color: var(--color-success);
  color: var(--text-primary);
}

.btn-danger {
  background-color: var(--color-danger);
  color: var(--text-primary);
}

.btn-sm {
  padding: var(--spacing-xs) var(--spacing-md);
  font-size: var(--font-size-xs);
}

.btn-lg {
  padding: var(--spacing-md) var(--spacing-xl);
  font-size: var(--font-size-base);
}

.btn-block {
  width: 100%;
}

.btn:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  transform: none;
}

/* ============================================
   Forms
   ============================================ */
.form-control,
.form-control-soft-ui,
input[type="text"],
input[type="email"],
input[type="password"],
input[type="tel"],
input[type="number"],
textarea,
select {
  width: 100%;
  padding: var(--spacing-md);
  background-color: var(--bg-card);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: var(--radius-md);
  color: var(--text-primary);
  font-size: var(--font-size-base);
  transition: all 0.3s ease;
}

.form-control:focus,
.form-control-soft-ui:focus,
input:focus,
textarea:focus,
select:focus {
  outline: none;
  border-color: var(--accent-primary);
  box-shadow: 0 0 0 3px rgba(255, 193, 7, 0.1);
  background-color: var(--bg-card-hover);
  color: var(--text-primary) !important;
}

.form-control::placeholder,
input::placeholder,
textarea::placeholder {
  color: var(--text-muted);
  text-align: right;
}

.form-control,
input,
textarea,
select {
  text-align: right;
  direction: rtl;
}

.form-group {
  margin-bottom: var(--spacing-lg);
  text-align: right;
}

.form-group label {
  display: block;
  margin-bottom: var(--spacing-sm);
  color: var(--text-secondary);
  text-align: right;
  font-weight: 500;
  font-size: var(--font-size-sm);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* ============================================
   Navigation
   ============================================ */
.navbar {
  background: rgba(30, 30, 30, 0.8);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  padding: var(--spacing-md) 0;
  box-shadow: 
    0 4px 20px rgba(0, 0, 0, 0.3),
    inset 0 -1px 0 rgba(255, 255, 255, 0.05);
}

.navbar-brand {
  font-size: var(--font-size-2xl);
  font-weight: 700;
  color: var(--text-primary);
}

.navbar-brand span {
  background: var(--accent-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.navbar-nav .nav-link {
  color: var(--text-secondary);
  padding: var(--spacing-sm) var(--spacing-md);
  border-radius: var(--radius-md);
  transition: all 0.3s ease;
  margin: 0 var(--spacing-xs);
}

.navbar-nav .nav-link:hover {
  color: var(--text-primary);
  background-color: var(--bg-card);
}

.navbar-nav .nav-link.active {
  color: var(--accent-primary);
  background-color: var(--bg-card);
}

/* Dropdown Menu - Glassmorphism */
.dropdown-menu {
  background: rgba(44, 44, 44, 0.9);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: var(--radius-md);
  box-shadow: 
    0 8px 32px rgba(0, 0, 0, 0.4),
    0 0 0 1px rgba(255, 255, 255, 0.05),
    inset 0 1px 0 rgba(255, 255, 255, 0.1);
  padding: var(--spacing-sm) 0;
}

.dropdown-item {
  color: var(--text-secondary);
  padding: var(--spacing-md) var(--spacing-lg);
  transition: all 0.3s ease;
  display: flex;
  align-items: center;
  line-height: 1.5;
  min-height: 40px;
  text-align: right;
  direction: rtl;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  max-width: 100%;
  box-sizing: border-box;
}

.dropdown-item:hover,
.dropdown-item:focus {
  background: rgba(255, 193, 7, 0.1);
  color: var(--accent-primary);
}

.dropdown-divider {
  border-color: rgba(255, 255, 255, 0.1);
}

/* ============================================
   Dashboard Layout - Background Integration
   ============================================ */
.dashboard-wrapper::before,
.dashboard-wrapper::after {
  display: block !important;
  visibility: visible !important;
}


.dashboard-container {
  display: flex;
  min-height: 100vh;
  padding-top: 0;
  position: relative;
  z-index: 1;
  background-color: transparent;
}

/* ============================================
   Sidebar
   ============================================ */
.dashboard-sidebar {
  width: 280px;
  background-color: transparent;
  min-height: calc(100vh - 70px);
  padding: var(--spacing-lg);
  position: fixed;
  left: 0;
  top: 70px;
  height: calc(100vh - 70px);
  overflow-y: auto;
  z-index: 100;
  display: flex;
  flex-direction: column;
  border-right: 1px solid rgba(255, 255, 255, 0.05);
}

.dashboard-sidebar::-webkit-scrollbar {
  width: 6px;
}

.dashboard-sidebar::-webkit-scrollbar-track {
  background: var(--bg-primary);
}

.dashboard-sidebar::-webkit-scrollbar-thumb {
  background: var(--bg-card);
  border-radius: 3px;
}

.dashboard-sidebar::-webkit-scrollbar-thumb:hover {
  background: var(--bg-card-hover);
}

/* Logo Section */
.sidebar-logo-section {
  padding: var(--spacing-lg) var(--spacing-lg) var(--spacing-lg);
  margin-bottom: var(--spacing-lg);
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.sidebar-logo {
  display: flex;
  align-items: center;
  justify-content: flex-start;
}

.logo-text {
  font-size: var(--font-size-2xl);
  font-weight: 700;
  color: var(--text-primary);
  letter-spacing: 2px;
  position: relative;
  background: linear-gradient(135deg, var(--text-primary) 0%, var(--accent-primary) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.logo-text::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 100%;
  height: 2px;
  background: var(--accent-gradient);
  opacity: 0.5;
}

.nav-menu-section {
  flex: 1;
  padding: 0;
}

.nav-menu-title {
  color: var(--text-secondary);
  font-size: var(--font-size-xs);
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: var(--spacing-lg);
  font-weight: 600;
  padding: 0;
}

.nav-menu-item {
  display: flex;
  align-items: center;
  gap: var(--spacing-md);
  padding: var(--spacing-md) var(--spacing-lg);
  color: var(--text-secondary);
  border-radius: var(--radius-lg);
  margin-bottom: var(--spacing-xs);
  transition: all 0.3s ease;
  text-decoration: none;
  width: 100%;
  position: relative;
  font-size: var(--font-size-sm);
  background: transparent;
}

.nav-menu-item i {
  width: 20px;
  text-align: center;
  font-size: var(--font-size-base);
  flex-shrink: 0;
}

.nav-menu-item span {
  flex: 1;
  text-align: right;
}

.nav-menu-item:hover {
  background-color: rgba(255, 255, 255, 0.03);
  color: var(--text-primary);
}

.nav-menu-item.active {
  background: linear-gradient(90deg, rgba(255, 193, 7, 0.1) 0%, rgba(255, 255, 255, 0.08) 100%);
  color: var(--accent-primary);
  font-weight: 600;
  position: relative;
  border-radius: var(--radius-md);
  box-shadow: inset 0 0 0 1px rgba(255, 193, 7, 0.15);
}

/* نور نارنجی اطراف آیتم فعال */
.nav-menu-item.active::before {
  content: '';
  position: absolute;
  top: 50%;
  right: 0;
  left: auto;
  transform: translateY(-50%);
  width: 4px;
  height: calc(100% - 16px);
  background: var(--accent-gradient);
  border-radius: var(--radius-sm);
  box-shadow: 0 0 10px rgba(255, 193, 7, 0.5);
  animation: activeGlow 2s ease-in-out infinite alternate;
}

@keyframes activeGlow {
  0% {
    opacity: 0.6;
    box-shadow: 0 0 10px rgba(255, 193, 7, 0.5);
  }
  100% {
    opacity: 1;
    box-shadow: 0 0 20px rgba(255, 193, 7, 0.8);
  }
}

.nav-menu-item.active i {
  color: var(--accent-primary);
}

/* Settings at Bottom */
.sidebar-settings {
  margin-top: auto;
  padding: var(--spacing-lg) 0;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
  /* جلوگیری از flicker - استفاده از visibility به جای display */
  min-height: 0;
  /* همیشه block باشد تا از فلش جلوگیری شود */
  display: block;
}

/* استفاده از visibility به جای display برای جلوگیری از فلش */
.sidebar-settings:empty {
  visibility: hidden;
  height: 0;
  padding: 0;
  margin: 0;
  border: none;
}

.sidebar-settings:not(:empty) {
  visibility: visible;
  height: auto;
}

/* Settings Dropdown */
.sidebar-settings .settings-dropdown-wrapper {
  position: relative;
}

.sidebar-settings .settings-dropdown-toggle {
  width: 100%;
}

.sidebar-settings .settings-dropdown-menu {
  background: rgba(44, 44, 44, 0.95);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: var(--radius-md);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
  overflow: hidden;
}

.sidebar-settings .settings-dropdown-item {
  display: flex;
  align-items: center;
  gap: var(--spacing-sm);
  padding: var(--spacing-md);
  color: var(--text-secondary);
  text-decoration: none;
  transition: all 0.2s ease;
}

.sidebar-settings .settings-dropdown-item:hover {
  background-color: rgba(255, 255, 255, 0.1);
  color: var(--text-primary);
}

.sidebar-settings .settings-dropdown-item:first-child {
  border-top: none;
}

/* Main Content - Modules in Center with Background Around */
.dashboard-main {
  flex: 1;
  margin-left: 280px;
  margin-top: 70px;
  padding: var(--spacing-xl);
  min-height: calc(100vh - 70px);
  background-color: transparent;
  position: relative;
  z-index: 1;
}

/* ============================================
   Dashboard Widgets with Glassmorphism
   ============================================ */
.dashboard-widget {
  background: rgba(44, 44, 44, 0.6);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-radius: var(--radius-lg);
  padding: var(--spacing-lg);
  box-shadow: 
    0 8px 32px rgba(0, 0, 0, 0.3),
    0 0 0 1px rgba(255, 255, 255, 0.05),
    inset 0 1px 0 rgba(255, 255, 255, 0.1),
    0 0 30px rgba(255, 193, 7, 0.05);
  margin-bottom: var(--spacing-lg);
  border: 1px solid rgba(255, 255, 255, 0.1);
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
}

/* نور داخلی ویجت */
.dashboard-widget::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(255, 193, 7, 0.4),
    rgba(255, 152, 0, 0.4),
    rgba(255, 193, 7, 0.4),
    transparent
  );
  opacity: 0;
  transition: opacity 0.3s ease;
}

.dashboard-widget:hover::before {
  opacity: 1;
}

.dashboard-widget:hover {
  background: rgba(54, 54, 54, 0.7);
  transform: translateY(-2px);
  box-shadow: 
    0 12px 40px rgba(0, 0, 0, 0.4),
    0 0 0 1px rgba(255, 193, 7, 0.3),
    0 0 40px rgba(255, 193, 7, 0.15),
    inset 0 1px 0 rgba(255, 255, 255, 0.2);
}

.widget-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: var(--spacing-lg);
  padding-bottom: var(--spacing-md);
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.widget-title {
  font-size: var(--font-size-lg);
  font-weight: 600;
  color: var(--text-primary);
  margin: 0;
}

.widget-badge {
  background-color: var(--bg-card-hover);
  color: var(--text-secondary);
  padding: var(--spacing-xs) var(--spacing-md);
  border-radius: var(--radius-full);
  font-size: var(--font-size-xs);
  font-weight: 500;
}

.widget-more-btn {
  margin-top: var(--spacing-md);
  padding: var(--spacing-sm) var(--spacing-lg);
  background: var(--accent-gradient);
  color: var(--text-primary);
  border: none;
  border-radius: var(--radius-md);
  font-size: var(--font-size-sm);
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
}

.widget-more-btn:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

/* Statistics Widget */
.statistics-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: var(--spacing-lg);
  padding-bottom: var(--spacing-md);
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.statistics-item:last-child {
  border-bottom: none;
  margin-bottom: 0;
}

.statistics-label {
  font-size: var(--font-size-sm);
  color: var(--text-secondary);
  font-weight: 500;
}

.statistics-bar-container {
  flex: 1;
  margin: 0 var(--spacing-md);
  position: relative;
  height: 8px;
  background: var(--bg-card-hover);
  border-radius: var(--radius-full);
  overflow: hidden;
}

.statistics-bar {
  height: 100%;
  background: var(--accent-gradient);
  border-radius: var(--radius-full);
  position: relative;
  transition: width 0.5s ease;
}

.statistics-bar-handle {
  position: absolute;
  left: -8px;
  top: 50%;
  transform: translateY(-50%);
  width: 16px;
  height: 16px;
  background: var(--text-primary);
  border: 2px solid var(--accent-primary);
  border-radius: 50%;
  box-shadow: var(--shadow-sm);
}

.statistics-value {
  font-size: var(--font-size-sm);
  font-weight: 600;
  padding: var(--spacing-xs) var(--spacing-md);
  border-radius: var(--radius-full);
  min-width: 80px;
  text-align: center;
}

.statistics-value.positive {
  background: rgba(40, 167, 69, 0.1);
  color: var(--color-success);
}

.statistics-value.negative {
  background: rgba(220, 53, 69, 0.1);
  color: var(--color-danger);
}

/* Card Visual with Glow */
.card-visual {
  width: 100%;
  height: 180px;
  background: var(--accent-gradient);
  border-radius: var(--radius-lg);
  padding: var(--spacing-lg);
  margin-bottom: var(--spacing-lg);
  position: relative;
  overflow: hidden;
  box-shadow: 
    0 8px 30px rgba(255, 193, 7, 0.3),
    0 0 40px rgba(255, 193, 7, 0.2),
    inset 0 1px 0 rgba(255, 255, 255, 0.3);
}

/* نور داخلی برای card visual */
.card-visual::after {
  content: '';
  position: absolute;
  top: -50%;
  right: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(
    circle,
    rgba(255, 255, 255, 0.15) 0%,
    transparent 70%
  );
  animation: cardGlow 4s ease-in-out infinite alternate;
}

@keyframes cardGlow {
  0% {
    opacity: 0.4;
    transform: scale(0.9);
  }
  100% {
    opacity: 0.8;
    transform: scale(1.1);
  }
}

.card-number {
  color: var(--text-primary);
  font-size: var(--font-size-lg);
  font-weight: 600;
  letter-spacing: 2px;
  position: relative;
  z-index: 1;
}

.card-expenses-trend {
  display: flex;
  justify-content: space-between;
  align-items: center;
  color: var(--text-primary);
  font-size: var(--font-size-sm);
  position: relative;
  z-index: 1;
  margin-top: var(--spacing-md);
}

.card-expenses-trend .trend-up {
  color: var(--color-success);
  font-weight: 600;
}

.card-transactions {
  margin-top: var(--spacing-md);
}

.transaction-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: var(--spacing-md) 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.transaction-item:last-child {
  border-bottom: none;
}

.transaction-name {
  display: flex;
  align-items: center;
  gap: var(--spacing-md);
  font-size: var(--font-size-sm);
  color: var(--text-primary);
}

.transaction-icon {
  width: 32px;
  height: 32px;
  border-radius: var(--radius-md);
  background: rgba(255, 255, 255, 0.1);
  color: var(--text-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: var(--font-size-sm);
}

.transaction-amount {
  font-size: var(--font-size-sm);
  font-weight: 600;
}

/* Investments Widget */
.investments-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--spacing-md);
}

.investment-card {
  background: var(--bg-card-hover);
  border-radius: var(--radius-lg);
  padding: var(--spacing-lg);
  border: 1px solid rgba(255, 255, 255, 0.05);
}

.investment-title {
  font-size: var(--font-size-base);
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: var(--spacing-sm);
}

.investment-subtitle {
  font-size: var(--font-size-xs);
  color: var(--text-secondary);
  margin-bottom: var(--spacing-md);
}

.investment-change {
  display: inline-block;
  padding: var(--spacing-xs) var(--spacing-sm);
  border-radius: var(--radius-sm);
  font-size: var(--font-size-xs);
  font-weight: 600;
  margin-bottom: var(--spacing-md);
  background: rgba(40, 167, 69, 0.1);
  color: var(--color-success);
}

.investment-amount {
  font-size: var(--font-size-xl);
  font-weight: 700;
  margin-bottom: var(--spacing-xs);
}

.investment-label {
  font-size: var(--font-size-xs);
  color: var(--text-secondary);
}

/* Income Chart */
.income-chart-container {
  height: 200px;
  position: relative;
  margin-top: var(--spacing-md);
}

.income-chart-line {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 150px;
  display: flex;
  align-items: flex-end;
  justify-content: space-around;
  padding: 0 var(--spacing-md);
}

.chart-point {
  position: relative;
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.chart-bar {
  width: 8px;
  background: var(--accent-gradient);
  border-radius: var(--radius-sm) var(--radius-sm) 0 0;
  margin-bottom: var(--spacing-sm);
  transition: all 0.3s ease;
}

.chart-point:hover .chart-bar {
  background: var(--color-success);
}

.chart-value {
  position: absolute;
  top: -30px;
  background: var(--bg-card);
  color: var(--text-primary);
  padding: var(--spacing-xs) var(--spacing-sm);
  border-radius: var(--radius-sm);
  font-size: var(--font-size-xs);
  font-weight: 600;
  white-space: nowrap;
  opacity: 0;
  transition: opacity 0.3s ease;
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.chart-point:hover .chart-value {
  opacity: 1;
}

.chart-label {
  font-size: var(--font-size-xs);
  color: var(--text-secondary);
  text-transform: uppercase;
}

/* Balance Widget with Glow */
.balance-widget {
  background: var(--accent-gradient);
  color: var(--text-primary);
  border-radius: var(--radius-lg);
  padding: var(--spacing-xl);
  text-align: center;
  box-shadow: 
    0 12px 40px rgba(255, 193, 7, 0.3),
    0 0 60px rgba(255, 193, 7, 0.2),
    inset 0 1px 0 rgba(255, 255, 255, 0.3);
  position: relative;
  overflow: hidden;
}

/* نور درخشان برای balance widget */
.balance-widget::before {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(
    circle,
    rgba(255, 255, 255, 0.2) 0%,
    transparent 70%
  );
  animation: balanceGlow 3s ease-in-out infinite alternate;
}

@keyframes balanceGlow {
  0% {
    opacity: 0.5;
    transform: scale(0.8);
  }
  100% {
    opacity: 1;
    transform: scale(1.2);
  }
}

.balance-label {
  font-size: var(--font-size-xs);
  text-transform: uppercase;
  letter-spacing: 1px;
  opacity: 0.9;
  margin-bottom: var(--spacing-md);
  position: relative;
  z-index: 1;
}

.balance-amount {
  font-size: var(--font-size-4xl);
  font-weight: 700;
  margin-bottom: var(--spacing-md);
  position: relative;
  z-index: 1;
}

.balance-status {
  display: inline-flex;
  align-items: center;
  gap: var(--spacing-sm);
  background: rgba(255, 255, 255, 0.2);
  padding: var(--spacing-sm) var(--spacing-md);
  border-radius: var(--radius-full);
  font-size: var(--font-size-sm);
  font-weight: 600;
  position: relative;
  z-index: 1;
}

/* RTL Support for Dashboard */
[dir="rtl"] .dashboard-sidebar {
  right: 0;
  left: auto;
  border-right: 1px solid rgba(255, 255, 255, 0.05);
  border-left: none;
}

[dir="rtl"] .dashboard-main {
  margin-left: 0;
  margin-right: 280px;
}

[dir="rtl"] .statistics-bar-handle {
  left: auto;
  right: -8px;
}

[dir="rtl"] .widget-more-btn {
  float: right;
}

/* Responsive Dashboard */
@media (max-width: 992px) {
  .dashboard-sidebar {
    width: 250px;
  }
  
  .dashboard-main {
    margin-left: 250px;
    margin-right: 0;
  }
  
  [dir="rtl"] .dashboard-main {
    margin-right: 250px;
    margin-left: 0;
  }
  
  .investments-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 768px) {
  .dashboard-container {
    flex-direction: column;
  }
  
  .dashboard-sidebar {
    width: 100%;
    height: auto;
    position: relative;
    top: 70px;
    padding: var(--spacing-lg);
    border-left: none;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  }
  
  .dashboard-main {
    margin-right: 0;
    margin-left: 0;
    margin-top: 70px;
    padding: var(--spacing-lg);
  }
  
  [dir="rtl"] .dashboard-main {
    margin-left: 0;
  }
  
  .dashboard-grid {
    max-width: 100%;
  }
}

/* ============================================
   Status Badges
   ============================================ */
.badge,
.status-badge {
  display: inline-block;
  padding: var(--spacing-xs) var(--spacing-md);
  border-radius: var(--radius-full);
  font-size: var(--font-size-xs);
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.badge-success,
.status-badge.badge-success {
  background-color: var(--color-success);
  color: var(--text-primary);
}

.badge-danger,
.status-badge.badge-danger {
  background-color: var(--color-danger);
  color: var(--text-primary);
}

.badge-warning,
.status-badge.badge-warning {
  background-color: var(--color-warning);
  color: var(--bg-primary);
}

.badge-info,
.status-badge.badge-info {
  background-color: var(--color-info);
  color: var(--text-primary);
}

.badge-primary,
.status-badge.badge-primary {
  background: var(--accent-gradient);
  color: var(--text-primary);
}

/* ============================================
   Tables
   ============================================ */
.table {
  width: 100%;
  color: var(--text-primary);
  background-color: transparent;
  direction: rtl;
  text-align: right;
}

.table thead th {
  border-bottom: 2px solid rgba(255, 255, 255, 0.1);
  color: var(--text-secondary);
  font-weight: 600;
  text-align: right;
  text-transform: uppercase;
  font-size: var(--font-size-xs);
  letter-spacing: 0.5px;
  padding: var(--spacing-md);
}

.table tbody td {
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  padding: var(--spacing-md);
  color: var(--text-primary);
}

.table tbody tr:hover {
  background-color: var(--bg-card);
}

/* ============================================
   Alerts
   ============================================ */
.alert {
  padding: var(--spacing-md);
  border-radius: var(--radius-md);
  margin-bottom: var(--spacing-md);
  border: 1px solid transparent;
}

.alert-success {
  background-color: rgba(40, 167, 69, 0.1);
  border-color: var(--color-success);
  color: var(--color-success);
}

.alert-danger {
  background-color: rgba(220, 53, 69, 0.1);
  border-color: var(--color-danger);
  color: var(--color-danger);
}

.alert-warning {
  background-color: rgba(255, 193, 7, 0.1);
  border-color: var(--color-warning);
  color: var(--color-warning);
}

.alert-info {
  background-color: rgba(23, 162, 184, 0.1);
  border-color: var(--color-info);
  color: var(--color-info);
}

/* ============================================
   Modals
   ============================================ */
.modal-content {
  background: rgba(44, 44, 44, 0.85);
  backdrop-filter: blur(25px);
  -webkit-backdrop-filter: blur(25px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: var(--radius-lg);
  box-shadow: 
    0 8px 32px rgba(0, 0, 0, 0.4),
    0 0 0 1px rgba(255, 255, 255, 0.05),
    inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.modal-header {
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  padding: var(--spacing-lg);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.modal-title {
  color: var(--text-primary);
  font-weight: 600;
  text-align: right;
  flex-grow: 1;
}

.modal-body {
  padding: var(--spacing-lg);
  color: var(--text-secondary);
  text-align: right;
}

.modal-footer {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding: var(--spacing-lg);
  display: flex;
  justify-content: flex-start;
  gap: 0.5rem;
}

.modal .close {
  color: var(--text-secondary);
  opacity: 1;
}

.modal .close:hover {
  color: var(--text-primary);
}

/* ============================================
   Utilities
   ============================================ */
.text-primary { color: var(--text-primary) !important; }
.text-secondary { color: var(--text-secondary) !important; }
.text-muted { color: var(--text-muted) !important; }
.text-success { color: var(--color-success) !important; }
.text-danger { color: var(--color-danger) !important; }
.text-warning { color: var(--color-warning) !important; }
.text-info { color: var(--color-info) !important; }
.text-accent { color: var(--accent-primary) !important; }

.bg-primary { background-color: var(--bg-primary) !important; }
.bg-secondary { background-color: var(--bg-secondary) !important; }
.bg-card { background-color: var(--bg-card) !important; }

.positive { color: var(--color-success) !important; }
.negative { color: var(--color-danger) !important; }

/* ============================================
   Loading Spinner
   ============================================ */
.spinner-border {
  width: 2rem;
  height: 2rem;
  border: 0.25em solid rgba(255, 193, 7, 0.3);
  border-right-color: var(--accent-primary);
  border-radius: 50%;
  animation: spinner-border 0.75s linear infinite;
}

@keyframes spinner-border {
  to { transform: rotate(360deg); }
}

/* Card Animation - انیمیشن کارت‌ها */
@keyframes cardFadeInUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* استایل پیش‌فرض برای کارت‌های با انیمیشن */
.service-card-item,
.project-card-item {
  background: rgba(44, 44, 44, 0.6) !important;
  backdrop-filter: blur(20px) !important;
  -webkit-backdrop-filter: blur(20px) !important;
  border-radius: 16px !important;
  padding: var(--spacing-lg);
  box-shadow: 
    0 8px 32px rgba(0, 0, 0, 0.3),
    0 0 0 1px rgba(255, 255, 255, 0.05),
    inset 0 1px 0 rgba(255, 255, 255, 0.1) !important;
  transition: all 0.3s ease !important;
  border: 1px solid rgba(255, 255, 255, 0.1) !important;
  position: relative;
  overflow: hidden;
  opacity: 0;
  min-width: 0;
  word-wrap: break-word;
  overflow-wrap: break-word;
  hyphens: auto;
}

/* نور داخلی کارت برای service-card-item و project-card-item */
.service-card-item::before,
.project-card-item::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(255, 193, 7, 0.3),
    transparent
  );
  opacity: 0;
  transition: opacity 0.3s ease;
}

.service-card-item:hover::before,
.project-card-item:hover::before {
  opacity: 1;
}

.service-card-item:hover,
.project-card-item:hover {
  background: rgba(54, 54, 54, 0.75) !important;
  box-shadow: 
    0 12px 40px rgba(0, 0, 0, 0.4),
    0 0 0 1px rgba(255, 193, 7, 0.3),
    0 0 30px rgba(255, 193, 7, 0.15),
    inset 0 1px 0 rgba(255, 255, 255, 0.15) !important;
  transform: translateY(-4px);
  border-color: rgba(255, 193, 7, 0.2) !important;
}

/* انیمیشن برای تمام کارت‌های داشبورد */
.dashboard-card,
.admin-card,
.pricing-card {
  opacity: 0;
}

.dashboard-card.animate-ready,
.admin-card.animate-ready,
.pricing-card.animate-ready {
  animation: cardFadeInUp 0.5s ease-out forwards;
}

/* ============================================
   Toggle Switch
   ============================================ */
.toggle-switch-soft-ui,
.toggle-switch {
  position: relative;
  display: inline-block;
  width: 48px;
  height: 26px;
  cursor: pointer;
}

.toggle-switch-soft-ui input,
.toggle-switch input {
  opacity: 0;
  width: 0;
  height: 0;
  position: absolute;
}

.toggle-switch-soft-ui .slider,
.toggle-switch .slider {
  position: absolute;
  cursor: pointer;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: var(--bg-card);
  transition: 0.3s;
  border-radius: var(--radius-full);
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.3);
}

.toggle-switch-soft-ui .slider:before,
.toggle-switch .slider:before {
  position: absolute;
  content: "";
  height: 20px;
  width: 20px;
  left: 3px;
  bottom: 3px;
  background-color: var(--text-primary);
  transition: 0.3s;
  border-radius: 50%;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

.toggle-switch-soft-ui input:checked + .slider,
.toggle-switch input:checked + .slider {
  background: var(--accent-gradient);
  box-shadow: 
    0 0 10px rgba(255, 193, 7, 0.4),
    inset 0 2px 4px rgba(0, 0, 0, 0.2);
}

.toggle-switch-soft-ui input:checked + .slider:before,
.toggle-switch input:checked + .slider:before {
  transform: translateX(22px);
  background-color: var(--text-primary);
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.4);
}

.toggle-switch-soft-ui input:focus + .slider,
.toggle-switch input:focus + .slider {
  box-shadow: 0 0 0 3px rgba(255, 193, 7, 0.2);
}

.toggle-switch-soft-ui:hover .slider,
.toggle-switch:hover .slider {
  border-color: rgba(255, 193, 7, 0.3);
}

/* ============================================
   Progress Bars
   ============================================ */
.progress {
  height: 8px;
  background-color: var(--bg-card);
  border-radius: var(--radius-full);
  overflow: hidden;
}

.progress-bar {
  background: var(--accent-gradient);
  height: 100%;
  transition: width 0.3s ease;
}

/* ============================================
   Pagination
   ============================================ */
.pagination {
  display: flex;
  list-style: none;
  gap: var(--spacing-sm);
  justify-content: center;
}

.page-item {
  margin: 0;
}

.page-link {
  padding: var(--spacing-sm) var(--spacing-md);
  background-color: var(--bg-card);
  color: var(--text-secondary);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: var(--radius-md);
  transition: all 0.3s ease;
  text-decoration: none;
}

.page-link:hover {
  background-color: var(--bg-card-hover);
  color: var(--text-primary);
  border-color: var(--accent-primary);
}

.page-item.active .page-link {
  background: var(--accent-gradient);
  color: var(--text-primary);
  border-color: var(--accent-primary);
}

.page-item.disabled .page-link {
  opacity: 0.5;
  cursor: not-allowed;
}

/* ============================================
   Responsive Design
   ============================================ */
@media (max-width: 768px) {
  :root {
    --spacing-lg: 16px;
    --spacing-xl: 24px;
  }
  
  .card,
  .dashboard-card {
    padding: var(--spacing-md);
  }
  
  h1 { font-size: var(--font-size-3xl); }
  h2 { font-size: var(--font-size-2xl); }
  h3 { font-size: var(--font-size-xl); }
}

/* ============================================
   Custom Scrollbar Styling - Attractive Design
   ============================================ */
::-webkit-scrollbar {
  width: 10px;
  height: 10px;
}

::-webkit-scrollbar-track {
  background: rgba(26, 26, 26, 0.5);
  border-radius: 10px;
  margin: 4px;
}

::-webkit-scrollbar-thumb {
  background: linear-gradient(180deg, var(--accent-primary) 0%, var(--accent-secondary) 100%);
  border-radius: 10px;
  border: 2px solid transparent;
  background-clip: padding-box;
  box-shadow: 
    0 0 10px rgba(255, 193, 7, 0.3),
    inset 0 0 6px rgba(255, 255, 255, 0.1);
}

::-webkit-scrollbar-thumb:hover {
  background: linear-gradient(180deg, var(--accent-secondary) 0%, var(--accent-primary) 100%);
  box-shadow: 
    0 0 15px rgba(255, 193, 7, 0.5),
    inset 0 0 8px rgba(255, 255, 255, 0.2);
}

::-webkit-scrollbar-thumb:active {
  background: linear-gradient(180deg, #FFD54F 0%, var(--accent-primary) 100%);
}

::-webkit-scrollbar-corner {
  background: transparent;
}

/* Firefox scrollbar */
* {
  scrollbar-width: thin;
  scrollbar-color: var(--accent-primary) rgba(26, 26, 26, 0.5);
}

/* Custom scrollbar for specific containers */
.holdings-projects-list,
.discounts-list,
.message-container,
.holdings-table {
  scrollbar-width: thin;
  scrollbar-color: var(--accent-primary) rgba(44, 44, 44, 0.3);
}

.holdings-projects-list::-webkit-scrollbar,
.discounts-list::-webkit-scrollbar,
.message-container::-webkit-scrollbar,
.holdings-table::-webkit-scrollbar {
  width: 8px;
}

.holdings-projects-list::-webkit-scrollbar-track,
.discounts-list::-webkit-scrollbar-track,
.message-container::-webkit-scrollbar-track,
.holdings-table::-webkit-scrollbar-track {
  background: rgba(44, 44, 44, 0.3);
  border-radius: 8px;
}

.holdings-projects-list::-webkit-scrollbar-thumb,
.discounts-list::-webkit-scrollbar-thumb,
.message-container::-webkit-scrollbar-thumb,
.holdings-table::-webkit-scrollbar-thumb {
  background: linear-gradient(180deg, var(--accent-primary) 0%, var(--accent-secondary) 100%);
  border-radius: 8px;
  border: 2px solid rgba(44, 44, 44, 0.3);
}

/* ============================================
   Animations
   ============================================ */
@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.fade-in {
  animation: fadeIn 0.3s ease;
}

/* ============================================
   Hero Section with Ambient Light
   ============================================ */
.hero-section {
  background: linear-gradient(135deg, var(--bg-primary) 0%, var(--bg-secondary) 100%);
  min-height: 100vh;
  display: flex;
  align-items: center;
  position: relative;
  overflow: hidden;
}

.hero-section::before {
  content: '';
  position: absolute;
  top: -50%;
  right: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(
    circle at 60% 40%,
    rgba(255, 193, 7, 0.2) 0%,
    rgba(255, 152, 0, 0.15) 30%,
    transparent 60%
  );
  pointer-events: none;
  animation: heroGlow 8s ease-in-out infinite alternate;
}

.hero-section::after {
  content: '';
  position: absolute;
  bottom: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(
    circle at 40% 60%,
    rgba(255, 193, 7, 0.15) 0%,
    rgba(255, 152, 0, 0.1) 30%,
    transparent 60%
  );
  pointer-events: none;
  animation: heroGlow 10s ease-in-out infinite alternate-reverse;
}

@keyframes heroGlow {
  0% {
    opacity: 0.6;
    transform: scale(1) rotate(0deg);
  }
  100% {
    opacity: 1;
    transform: scale(1.2) rotate(5deg);
  }
}

/* ============================================
   Empty State
   ============================================ */
.empty-state {
  text-align: center;
  padding: var(--spacing-xl) var(--spacing-lg);
  color: var(--text-muted);
}

.empty-state i {
  font-size: 4rem;
  margin-bottom: var(--spacing-lg);
  color: var(--bg-card);
  opacity: 0.5;
}

.empty-state p {
  font-size: var(--font-size-lg);
  color: var(--text-secondary);
}

/* ============================================
   Dashboard Header (Top Navigation) - Part of Background
   ============================================ */
.dashboard-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: 70px;
  background-color: transparent;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  z-index: 2000;
}

.header-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 100%;
  padding: 0 var(--spacing-xl);
  max-width: 100%;
  position: relative;
  z-index: 1;
}

.header-left {
  display: flex;
  align-items: center;
  gap: var(--spacing-xl);
}

.header-left .logo {
  font-size: var(--font-size-2xl);
  font-weight: 700;
}

.header-left .logo .logo-text {
  background: var(--accent-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.main-nav {
  display: flex;
  align-items: center;
  gap: var(--spacing-lg);
}

.main-nav .nav-link {
  color: var(--text-secondary);
  text-decoration: none;
  font-size: var(--font-size-sm);
  font-weight: 500;
  transition: color 0.3s ease;
  padding: var(--spacing-sm) 0;
}

.main-nav .nav-link:hover {
  color: var(--text-primary);
}

.header-right {
  display: flex;
  align-items: center;
  gap: var(--spacing-md);
  position: relative;
  z-index: 1;
}

.btn-header {
  padding: var(--spacing-sm) var(--spacing-lg);
  border-radius: var(--radius-md);
  font-size: var(--font-size-sm);
  font-weight: 600;
  border: none;
  cursor: pointer;
  transition: all 0.3s ease;
}

.btn-order {
  background: transparent;
  color: var(--text-primary);
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.btn-order:hover {
  background: rgba(255, 255, 255, 0.05);
  border-color: rgba(255, 255, 255, 0.3);
}

.btn-deposit {
  background: var(--accent-gradient);
  color: var(--text-primary);
  box-shadow: 0 4px 15px rgba(255, 193, 7, 0.3);
  position: relative;
  overflow: hidden;
}

.btn-deposit::before {
  content: '';
  position: absolute;
  top: -2px;
  left: -2px;
  right: -2px;
  bottom: -2px;
  background: var(--accent-gradient);
  border-radius: inherit;
  z-index: -1;
  opacity: 0;
  filter: blur(8px);
  transition: opacity 0.3s ease;
}

.btn-deposit:hover::before {
  opacity: 0.6;
}

.btn-deposit:hover {
  transform: translateY(-2px);
  box-shadow: 
    0 6px 20px rgba(255, 193, 7, 0.4),
    0 0 25px rgba(255, 193, 7, 0.3),
    inset 0 0 0 1px rgba(255, 255, 255, 0.1);
}

.header-icon {
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-secondary);
  cursor: pointer;
  border-radius: var(--radius-md);
  transition: all 0.3s ease;
}

.header-icon:hover {
  background: rgba(255, 255, 255, 0.05);
  color: var(--text-primary);
}

/* Theme Toggle Button */
.theme-toggle-btn {
  background: transparent !important;
  border: none !important;
  transition: all 0.3s ease !important;
  cursor: pointer !important;
}

.theme-toggle-btn:hover {
  background: rgba(255, 193, 7, 0.1) !important;
  color: var(--accent-primary) !important;
  transform: rotate(15deg) scale(1.1);
}

.theme-toggle-btn i {
  font-size: 1.2rem;
  transition: transform 0.3s ease;
  display: inline-block;
}

.theme-toggle-btn:hover i {
  transform: rotate(180deg);
}

:root[data-theme="light"] .theme-toggle-btn:hover,
html[data-theme="light"] .theme-toggle-btn:hover {
  background: rgba(30, 58, 138, 0.1) !important;
  color: var(--accent-primary) !important;
}

.user-profile-icon {
  display: flex;
  align-items: center;
  gap: var(--spacing-xs);
  color: var(--text-secondary);
  cursor: pointer;
  position: relative;
  z-index: 1001;
  padding: var(--spacing-sm);
  border-radius: var(--radius-md);
  transition: all 0.3s ease;
}

.user-profile-icon:hover {
  background: rgba(255, 255, 255, 0.05);
  color: var(--text-primary);
}

.user-profile-icon i:first-child {
  font-size: var(--font-size-xl);
}

.user-profile-icon i:last-child {
  font-size: var(--font-size-xs);
}

/* ============================================
   Dashboard Grid Layout - Modules in Center
   ============================================ */
.dashboard-grid {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  grid-auto-rows: min-content;
  gap: var(--spacing-lg);
  max-width: 1400px;
  margin: 0 auto;
  padding: var(--spacing-xl);
  position: relative;
  z-index: 10;
  background-color: transparent;
  width: 100%;
  box-sizing: border-box;
  align-items: start;
}

/* Fix for text wrapping in cards */
.dashboard-card {
  min-width: 0;
  word-wrap: break-word;
  overflow-wrap: break-word;
  hyphens: auto;
}

.dashboard-card * {
  word-wrap: break-word;
  overflow-wrap: break-word;
  max-width: 100%;
}

.dashboard-card p,
.dashboard-card h1,
.dashboard-card h2,
.dashboard-card h3,
.dashboard-card h4,
.dashboard-card h5,
.dashboard-card h6 {
  word-break: break-word;
  overflow-wrap: break-word;
  hyphens: auto;
}

/* User Info Card - Glassmorphism */
.user-info-card,
.deposit-card,
.total-asset-card,
.vip-card,
.holdings-card,
.affiliate-card,
.info-card,
.dashboard-card {
  background: rgba(44, 44, 44, 0.6) !important;
  backdrop-filter: blur(20px) !important;
  -webkit-backdrop-filter: blur(20px) !important;
  border-radius: 16px !important;
  padding: var(--spacing-lg);
  box-shadow: 
    0 8px 32px rgba(0, 0, 0, 0.3),
    0 0 0 1px rgba(255, 255, 255, 0.05),
    inset 0 1px 0 rgba(255, 255, 255, 0.1) !important;
  border: 1px solid rgba(255, 255, 255, 0.1) !important;
  position: relative;
  overflow: hidden;
  z-index: 10;
  min-width: 0;
  word-wrap: break-word;
  overflow-wrap: break-word;
  hyphens: auto;
  transition: all 0.3s ease !important;
}

.user-info-card::before,
.deposit-card::before,
.total-asset-card::before,
.vip-card::before,
.holdings-card::before,
.affiliate-card::before,
.info-card::before,
.dashboard-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(255, 193, 7, 0.3),
    transparent
  );
  opacity: 0;
  transition: opacity 0.3s ease;
}

.user-info-card:hover::before,
.deposit-card:hover::before,
.total-asset-card:hover::before,
.vip-card:hover::before,
.holdings-card:hover::before,
.affiliate-card:hover::before,
.info-card:hover::before,
.dashboard-card:hover::before {
  opacity: 1;
}

.user-info-card:hover,
.deposit-card:hover,
.total-asset-card:hover,
.vip-card:hover,
.holdings-card:hover,
.affiliate-card:hover,
.info-card:hover,
.dashboard-card:hover {
  background: rgba(54, 54, 54, 0.75) !important;
  box-shadow: 
    0 12px 40px rgba(0, 0, 0, 0.4),
    0 0 0 1px rgba(255, 193, 7, 0.3),
    0 0 30px rgba(255, 193, 7, 0.15),
    inset 0 1px 0 rgba(255, 255, 255, 0.15) !important;
  transform: translateY(-2px);
  border-color: rgba(255, 193, 7, 0.2) !important;
}

/* جلوگیری از overflow در hover برای کارت‌های خاص */
.vip-card:hover,
.affiliate-card:hover {
  transform: translateY(-2px) scale(1);
  margin-bottom: 2px;
}

.user-info-card {
  grid-column: 1 / span 12;
  min-height: 180px;
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 0;
  min-width: 0;
  box-sizing: border-box;
}

.card-header-user {
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  align-items: flex-start;
  flex: 0 0 auto;
  min-width: 280px;
  max-width: 320px;
  padding-right: var(--spacing-xl);
  border-right: 1px solid rgba(255, 255, 255, 0.1);
  margin-bottom: 0;
  padding-bottom: 0;
  border-bottom: none;
  width: auto;
  box-sizing: border-box;
  gap: var(--spacing-md);
}

.user-info-header {
  display: flex;
  align-items: center;
  gap: var(--spacing-md);
  width: 100%;
  flex-wrap: wrap;
}

.user-avatar-small {
  width: 60px;
  height: 60px;
  border-radius: 50%;
  overflow: hidden;
  border: 3px solid var(--accent-primary);
  flex-shrink: 0;
}

.user-avatar-small img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.user-info-text {
  display: flex;
  flex-direction: column;
  text-align: right;
}

.user-greeting {
  font-size: var(--font-size-sm);
  color: var(--text-secondary);
  margin-bottom: var(--spacing-xs);
  text-align: right;
}

.user-name-display {
  font-size: var(--font-size-xl);
  font-weight: 700;
  color: var(--text-primary);
  margin-top: var(--spacing-xs);
  text-align: right;
}

.btn-hide-info {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: var(--text-primary);
  cursor: pointer;
  padding: var(--spacing-xs) var(--spacing-md);
  border-radius: var(--radius-md);
  font-size: var(--font-size-xs);
  transition: all 0.3s ease;
  display: flex;
  align-items: center;
  gap: var(--spacing-xs);
}

.btn-hide-info:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.2);
}

.user-details-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--spacing-md);
  margin-top: 0;
  flex: 1;
  padding-left: var(--spacing-xl);
  width: 100%;
  min-width: 0;
  box-sizing: border-box;
}

.user-detail-item {
  display: flex;
  flex-direction: column;
  gap: var(--spacing-xs);
  padding: var(--spacing-md);
  background: rgba(255, 255, 255, 0.02);
  border-radius: var(--radius-sm);
  border: 1px solid rgba(255, 255, 255, 0.05);
  text-align: right;
}

.user-detail-item.full-width {
  grid-column: span 4;
}

.detail-value-row {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: var(--spacing-sm);
  flex-direction: row-reverse;
}

.detail-value-row .detail-value {
  flex: 1;
  text-align: right;
}

.detail-icon.warning-icon {
  color: var(--color-warning);
}

.detail-label {
  font-size: var(--font-size-xs);
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  text-align: right;
}

.detail-value {
  font-size: var(--font-size-sm);
  color: var(--text-primary);
  font-weight: 500;
  text-align: right;
}

.detail-value.warning {
  color: var(--color-warning);
}

.detail-icon {
  color: var(--text-secondary);
  font-size: var(--font-size-sm);
  cursor: pointer;
  transition: all 0.3s ease;
  padding: var(--spacing-xs);
  border-radius: var(--radius-sm);
}

.detail-icon:hover {
  color: var(--accent-primary);
  background: rgba(255, 193, 7, 0.1);
}

/* Deposit Card */
.deposit-card {
  grid-column: 1 / span 4;
  min-height: 200px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-width: 0;
  box-sizing: border-box;
}

.deposit-card .card-title,
.card-title {
  font-size: var(--font-size-base);
  color: var(--text-primary);
  margin-bottom: var(--spacing-lg);
  font-weight: 500;
  line-height: 1.5;
  word-break: break-word;
  overflow-wrap: break-word;
}

.deposit-options {
  display: flex;
  flex-direction: column;
  gap: var(--spacing-md);
}

.deposit-option {
  display: flex;
  align-items: center;
  gap: var(--spacing-md);
  padding: var(--spacing-lg);
  background: rgba(255, 255, 255, 0.03);
  border-radius: var(--radius-md);
  border: 1px solid rgba(255, 255, 255, 0.08);
  transition: all 0.3s ease;
  cursor: pointer;
  position: relative;
}

.deposit-option:hover {
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(255, 193, 7, 0.4);
  transform: translateX(-2px);
}

.deposit-option:hover .deposit-arrow {
  transform: translateX(-3px);
  color: var(--accent-secondary);
}

.deposit-icon {
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 193, 7, 0.1);
  border-radius: var(--radius-md);
  color: var(--accent-primary);
  font-size: var(--font-size-lg);
}

.deposit-text {
  flex: 1;
  color: var(--text-secondary);
  font-size: var(--font-size-sm);
  word-break: break-word;
  overflow-wrap: break-word;
  min-width: 0;
}

.deposit-arrow {
  color: var(--accent-primary);
  font-size: var(--font-size-base);
  transition: all 0.3s ease;
}

/* Total Asset Card */
.total-asset-card {
  grid-column: 5 / span 4;
  position: relative;
  overflow: hidden;
  min-height: 200px;
  display: flex;
  flex-direction: column;
  min-width: 0;
  box-sizing: border-box;
}

.asset-tabs {
  display: flex;
  gap: var(--spacing-sm);
  margin-bottom: var(--spacing-lg);
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.asset-tab {
  padding: var(--spacing-sm) var(--spacing-md);
  background: transparent;
  border: none;
  color: var(--text-secondary);
  font-size: var(--font-size-sm);
  cursor: pointer;
  border-bottom: 2px solid transparent;
  transition: all 0.3s ease;
}

.asset-tab:hover {
  color: var(--text-primary);
}

.asset-tab.active {
  color: var(--accent-primary);
  border-bottom-color: var(--accent-primary);
  font-weight: 600;
}

.asset-content {
  position: relative;
}

.asset-label {
  font-size: var(--font-size-sm);
  color: var(--text-secondary);
  margin-bottom: var(--spacing-sm);
  word-break: break-word;
  overflow-wrap: break-word;
}

.asset-amount-btc {
  font-size: var(--font-size-4xl);
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: var(--spacing-xs);
  line-height: 1.2;
  word-break: break-word;
  overflow-wrap: break-word;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.asset-amount-usd {
  font-size: var(--font-size-lg);
  color: var(--text-secondary);
  margin-bottom: var(--spacing-lg);
  font-weight: 500;
  word-break: break-word;
  overflow-wrap: break-word;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.btc-logo-bg {
  position: absolute;
  bottom: -30px;
  right: -30px;
  font-size: 150px;
  color: var(--text-primary);
  opacity: 0.08;
  z-index: 0;
  font-weight: 700;
  line-height: 1;
  pointer-events: none;
}

/* VIP Card */
.vip-card {
  grid-column: 9 / span 4;
  grid-row: 2;
  min-height: 250px;
  max-height: 400px;
  display: flex;
  flex-direction: column;
  min-width: 0;
  box-sizing: border-box;
  align-self: start;
  overflow: hidden;
  position: relative;
}

.vip-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: var(--spacing-lg);
  padding-bottom: var(--spacing-md);
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.vip-title {
  display: flex;
  align-items: center;
  gap: var(--spacing-sm);
  color: var(--text-primary);
  font-weight: 600;
  font-size: var(--font-size-lg);
}

.vip-title span {
  display: flex;
  align-items: center;
  gap: var(--spacing-xs);
  word-break: break-word;
  overflow-wrap: break-word;
}

.vip-title i {
  color: var(--accent-primary);
}

.view-more-link {
  color: var(--accent-primary);
  text-decoration: none;
  font-size: var(--font-size-sm);
  display: flex;
  align-items: center;
  gap: var(--spacing-xs);
  transition: all 0.3s ease;
}

.view-more-link:hover {
  color: var(--accent-secondary);
}

.vip-content {
  display: flex;
  flex-direction: column;
  gap: var(--spacing-lg);
  flex: 1;
}

.vip-toggle {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: var(--spacing-md);
  background: rgba(255, 255, 255, 0.02);
  border-radius: var(--radius-md);
  border: 1px solid rgba(255, 255, 255, 0.05);
}

.vip-toggle span {
  color: var(--text-primary);
  font-size: var(--font-size-sm);
  font-weight: 500;
  word-break: break-word;
  overflow-wrap: break-word;
  min-width: 0;
}

.vip-fees {
  display: flex;
  flex-direction: column;
  gap: var(--spacing-md);
}

.fee-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: var(--spacing-md) 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  flex-wrap: wrap;
  gap: var(--spacing-xs);
  min-width: 0;
}

.fee-item:last-child {
  border-bottom: none;
}

.fee-label {
  color: var(--text-secondary);
  font-size: var(--font-size-sm);
  font-weight: 500;
  word-break: break-word;
  overflow-wrap: break-word;
  min-width: 0;
}

.fee-value {
  display: flex;
  gap: var(--spacing-md);
  align-items: center;
  flex-shrink: 0;
  white-space: nowrap;
}

.fee-positive {
  color: var(--color-success);
  font-weight: 600;
  font-size: var(--font-size-sm);
}

.fee-negative {
  color: var(--color-danger);
  font-weight: 600;
  font-size: var(--font-size-sm);
}

.vip-holdings {
  padding: var(--spacing-md);
  background: rgba(255, 255, 255, 0.02);
  border-radius: var(--radius-md);
}

.holdings-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: var(--spacing-md);
  color: var(--text-primary);
  font-size: var(--font-size-sm);
  font-weight: 500;
  cursor: pointer;
  padding: var(--spacing-xs);
  border-radius: var(--radius-sm);
  transition: all 0.3s ease;
}

.holdings-header:hover {
  background: rgba(255, 255, 255, 0.03);
}

.holdings-progress {
  display: flex;
  flex-direction: column;
  gap: var(--spacing-sm);
}

.progress-bar-holdings {
  height: 8px;
  background: rgba(255, 255, 255, 0.05);
  border-radius: var(--radius-full);
  overflow: hidden;
  position: relative;
}

.progress-fill {
  height: 100%;
  background: var(--accent-gradient);
  border-radius: var(--radius-full);
  transition: width 0.3s ease;
  box-shadow: 0 0 10px rgba(255, 193, 7, 0.3);
}

.holdings-text {
  display: flex;
  flex-direction: column;
  gap: var(--spacing-xs);
  font-size: var(--font-size-xs);
  color: var(--text-secondary);
  line-height: 1.5;
  word-break: break-word;
  overflow-wrap: break-word;
}

.holdings-text span {
  word-break: break-word;
  overflow-wrap: break-word;
}

.holdings-text span:first-child {
  color: var(--accent-primary);
  font-weight: 700;
  font-size: var(--font-size-base);
  margin-bottom: var(--spacing-xs);
}

/* Holdings Card */
.holdings-card {
  grid-column: 1 / span 8;
  grid-row: 2;
  min-height: 400px;
  display: flex;
  flex-direction: column;
  min-width: 0;
  box-sizing: border-box;
  align-self: stretch;
}

.card-header-flex {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: var(--spacing-lg);
  padding-bottom: var(--spacing-md);
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  flex-wrap: wrap;
  gap: var(--spacing-sm);
}

.holdings-table {
  overflow-x: auto;
  flex: 1;
}

.holdings-table-content {
  width: 100%;
  border-collapse: collapse;
}

.holdings-table-content thead th {
  text-align: right;
  padding: var(--spacing-md) var(--spacing-lg);
  color: var(--text-secondary);
  font-size: var(--font-size-xs);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  font-weight: 600;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.02);
  white-space: nowrap;
}

.holdings-table-content tbody td {
  padding: var(--spacing-md) var(--spacing-lg);
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  color: var(--text-primary);
  font-size: var(--font-size-sm);
  vertical-align: middle;
  word-break: break-word;
  overflow-wrap: break-word;
  max-width: 200px;
}

.holdings-table-content tbody tr:hover {
  background: rgba(255, 255, 255, 0.02);
}

.coin-info {
  display: flex;
  align-items: center;
  gap: var(--spacing-md);
  min-width: 0;
  flex: 1;
}

.coin-icon {
  width: 45px;
  height: 45px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: var(--font-size-lg);
  color: var(--text-primary);
  flex-shrink: 0;
}

.coin-icon.btc {
  background: linear-gradient(135deg, #F7931A 0%, #FFC107 100%);
  box-shadow: 0 4px 15px rgba(247, 147, 26, 0.3);
}

.coin-icon.eth {
  background: linear-gradient(135deg, #627EEA 0%, #8B9FF7 100%);
  box-shadow: 0 4px 15px rgba(98, 126, 234, 0.3);
}

.coin-icon.usdc {
  background: linear-gradient(135deg, #2775CA 0%, #3A8FE8 100%);
  box-shadow: 0 4px 15px rgba(39, 117, 202, 0.3);
}

.coin-icon.usdt {
  background: linear-gradient(135deg, #26A17B 0%, #3BC9A3 100%);
  box-shadow: 0 4px 15px rgba(38, 161, 123, 0.3);
}

.coin-name {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.coin-name {
  display: flex;
  flex-direction: column;
  min-width: 0;
  flex: 1;
}

.coin-symbol {
  font-weight: 600;
  color: var(--text-primary);
  font-size: var(--font-size-base);
  display: block;
  margin-bottom: 2px;
  word-break: break-word;
  overflow-wrap: break-word;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.coin-code {
  color: var(--text-secondary);
  font-size: var(--font-size-xs);
  display: block;
  word-break: break-word;
  overflow-wrap: break-word;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.change-positive {
  color: var(--color-success);
  font-weight: 600;
  font-size: var(--font-size-sm);
}

.change-negative {
  color: var(--color-danger);
  font-weight: 600;
  font-size: var(--font-size-sm);
}

.trend-chart {
  width: 80px;
  height: 40px;
  position: relative;
  display: flex;
  align-items: flex-end;
}

.trend-chart.trend-up {
  background: linear-gradient(
    to top right,
    transparent 0%,
    transparent 30%,
    var(--color-success) 30%,
    var(--color-success) 100%
  );
  clip-path: polygon(
    0% 100%,
    10% 85%,
    20% 70%,
    30% 60%,
    40% 50%,
    50% 45%,
    60% 40%,
    70% 35%,
    80% 30%,
    90% 25%,
    100% 20%,
    100% 100%,
    0% 100%
  );
  border-radius: 2px 2px 0 0;
}

.trend-chart.trend-down {
  background: linear-gradient(
    to top right,
    transparent 0%,
    transparent 30%,
    var(--color-danger) 30%,
    var(--color-danger) 100%
  );
  clip-path: polygon(
    0% 20%,
    10% 25%,
    20% 30%,
    30% 35%,
    40% 40%,
    50% 45%,
    60% 50%,
    70% 60%,
    80% 70%,
    90% 85%,
    100% 100%,
    100% 100%,
    0% 100%
  );
  border-radius: 2px 2px 0 0;
}

.action-buttons {
  display: flex;
  gap: var(--spacing-xs);
  flex-wrap: wrap;
}

.btn-action {
  padding: var(--spacing-xs) var(--spacing-md);
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: var(--radius-sm);
  color: var(--text-secondary);
  font-size: var(--font-size-xs);
  cursor: pointer;
  transition: all 0.3s ease;
  font-weight: 500;
  white-space: nowrap;
}

.btn-action:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 193, 7, 0.4);
  color: var(--text-primary);
  transform: translateY(-1px);
}

/* Affiliate Card */
.affiliate-card {
  grid-column: 9 / span 4;
  grid-row: 3;
  position: relative;
  overflow: hidden;
  min-height: 250px;
  max-height: 350px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-width: 0;
  box-sizing: border-box;
  align-self: start;
}

.affiliate-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
  position: relative;
  z-index: 1;
  min-height: 150px;
}

/* New Affiliate Header Styles */
.affiliate-header {
  margin-bottom: var(--spacing-lg);
  text-align: center;
}

.affiliate-title-section {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--spacing-md);
  flex-direction: row-reverse;
}

.affiliate-title-section .coin-graphic {
  width: 50px;
  height: 50px;
  font-size: var(--font-size-lg);
}

.affiliate-title-text {
  text-align: right;
}

.affiliate-title-text .affiliate-title {
  margin-bottom: var(--spacing-xs);
  font-size: var(--font-size-lg);
}

.affiliate-title-text .affiliate-desc {
  margin: 0;
  font-size: var(--font-size-xs);
}

.affiliate-text {
  flex: 1;
  text-align: right;
}

.affiliate-title {
  font-size: var(--font-size-xl);
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: var(--spacing-md);
  line-height: 1.3;
  word-break: break-word;
  overflow-wrap: break-word;
  text-align: right;
}

.affiliate-desc {
  font-size: var(--font-size-sm);
  word-break: break-word;
  overflow-wrap: break-word;
  color: var(--text-secondary);
  margin-bottom: var(--spacing-md);
  line-height: 1.6;
  text-align: right;
}

.btn-affiliate {
  padding: var(--spacing-md) var(--spacing-xl);
  background: transparent;
  color: var(--accent-primary);
  border: 2px solid var(--accent-primary);
  border-radius: var(--radius-md);
  font-size: var(--font-size-sm);
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.btn-affiliate:hover {
  background: var(--accent-gradient);
  color: var(--text-primary);
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(255, 193, 7, 0.4);
  border-color: transparent;
}

.affiliate-image {
  position: relative;
  flex-shrink: 0;
}

.coin-graphic {
  width: 60px;
  height: 60px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--accent-gradient);
  border-radius: 50%;
  font-size: var(--font-size-xl);
  color: var(--text-primary);
  box-shadow: 
    0 0 20px rgba(255, 193, 7, 0.3),
    0 0 40px rgba(255, 193, 7, 0.15),
    inset 0 0 10px rgba(255, 255, 255, 0.15);
  position: relative;
  animation: coinGlow 3s ease-in-out infinite alternate;
  flex-shrink: 0;
}

.coin-graphic::before {
  content: '';
  position: absolute;
  top: -10px;
  left: -10px;
  right: -10px;
  bottom: -10px;
  background: var(--accent-gradient);
  border-radius: 50%;
  opacity: 0.3;
  filter: blur(15px);
  z-index: -1;
  animation: coinGlowOuter 3s ease-in-out infinite alternate;
}

@keyframes coinGlow {
  0% {
    box-shadow: 
      0 0 40px rgba(255, 193, 7, 0.4),
      0 0 80px rgba(255, 193, 7, 0.2),
      inset 0 0 20px rgba(255, 255, 255, 0.2);
  }
  100% {
    box-shadow: 
      0 0 60px rgba(255, 193, 7, 0.6),
      0 0 120px rgba(255, 193, 7, 0.3),
      inset 0 0 30px rgba(255, 255, 255, 0.3);
  }
}

@keyframes coinGlowOuter {
  0% {
    opacity: 0.2;
    transform: scale(1);
  }
  100% {
    opacity: 0.5;
    transform: scale(1.1);
  }
}

/* Info Card */
.info-card {
  grid-column: 1 / span 8;
  grid-row: 3;
  min-height: 190px;
  display: flex;
  flex-direction: column;
  min-width: 0;
  box-sizing: border-box;
  align-self: start;
}

.info-list {
  display: flex;
  flex-direction: column;
  gap: var(--spacing-md);
  flex: 1;
}

.info-item {
  padding: var(--spacing-md);
  background: rgba(255, 255, 255, 0.02);
  border-radius: var(--radius-md);
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-left: 3px solid var(--accent-primary);
  transition: all 0.3s ease;
  cursor: pointer;
  margin-bottom: var(--spacing-sm);
}

.info-item:last-child {
  margin-bottom: 0;
}

.info-item:hover {
  background: rgba(255, 255, 255, 0.05);
  transform: translateX(-3px);
  border-left-color: var(--accent-secondary);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.info-content {
  display: flex;
  flex-direction: column;
  gap: var(--spacing-xs);
}

.info-title {
  font-size: var(--font-size-base);
  color: var(--text-primary);
  font-weight: 500;
  line-height: 1.6;
  margin-bottom: var(--spacing-xs);
  word-break: break-word;
  overflow-wrap: break-word;
}

.info-time {
  font-size: var(--font-size-xs);
  color: var(--text-secondary);
  margin-top: var(--spacing-xs);
}

/* Responsive Dashboard Grid */
@media (max-width: 1400px) {
  .dashboard-grid {
    grid-template-columns: repeat(12, 1fr);
    max-width: 1200px;
  }
  
  .user-info-card {
    grid-column: 1 / span 12;
  }
  
  .deposit-card {
    grid-column: 1 / span 4;
  }
  
  .total-asset-card {
    grid-column: 5 / span 4;
  }
  
  .vip-card {
    grid-column: 9 / span 4;
    grid-row: 2;
  }
  
  .holdings-card {
    grid-column: 1 / span 8;
    grid-row: 2;
  }
  
  .affiliate-card {
    grid-column: 9 / span 4;
    grid-row: 3;
  }
  
  .info-card {
    grid-column: 1 / span 8;
    grid-row: 3;
  }
}

@media (max-width: 992px) {
  .dashboard-grid {
    grid-template-columns: repeat(4, 1fr);
    max-width: 100%;
    padding: var(--spacing-md);
  }
  
  .user-info-card,
  .deposit-card,
  .total-asset-card,
  .vip-card,
  .holdings-card,
  .affiliate-card,
  .info-card {
    grid-column: span 4;
  }
  
  .user-details-grid {
    grid-template-columns: 1fr;
  }
  
  .user-detail-item.full-width {
    grid-column: span 1;
  }
}

/* VIP Subscription Styles */
.vip-plans {
  display: flex;
  flex-direction: column;
  gap: var(--spacing-md);
  margin-bottom: var(--spacing-lg);
  max-height: 280px;
  overflow-y: auto;
  padding-left: var(--spacing-xs);
  scrollbar-width: thin;
  scrollbar-color: var(--accent-primary) rgba(44, 44, 44, 0.3);
}

.vip-plans::-webkit-scrollbar {
  width: 6px;
}

.vip-plans::-webkit-scrollbar-track {
  background: rgba(44, 44, 44, 0.3);
  border-radius: 6px;
}

.vip-plans::-webkit-scrollbar-thumb {
  background: linear-gradient(180deg, var(--accent-primary) 0%, var(--accent-secondary) 100%);
  border-radius: 6px;
}

.plan-card {
  padding: var(--spacing-md);
  background: rgba(255, 255, 255, 0.02);
  border-radius: var(--radius-md);
  border: 1px solid rgba(255, 255, 255, 0.05);
  transition: all 0.3s ease;
  text-align: right;
}

.plan-card:hover {
  background: rgba(255, 255, 255, 0.05);
  border-color: var(--accent-primary);
  transform: translateY(-2px);
}

.plan-name {
  font-size: var(--font-size-lg);
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: var(--spacing-xs);
  text-align: right;
}

.plan-price {
  font-size: var(--font-size-xl);
  font-weight: 700;
  color: var(--accent-primary);
  margin-bottom: var(--spacing-xs);
  text-align: right;
}

.plan-desc {
  font-size: var(--font-size-sm);
  color: var(--text-secondary);
  margin-bottom: var(--spacing-md);
  line-height: 1.5;
  text-align: right;
}

.btn-plan-select {
  width: 100%;
  padding: var(--spacing-sm) var(--spacing-md);
  background: transparent;
  border: 1px solid var(--accent-primary);
  border-radius: var(--radius-sm);
  color: var(--accent-primary);
  font-size: var(--font-size-sm);
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
}

.btn-plan-select:hover {
  background: var(--accent-gradient);
  color: var(--text-primary);
  border-color: transparent;
}

.vip-current-plan {
  padding: var(--spacing-md);
  background: rgba(255, 193, 7, 0.1);
  border-radius: var(--radius-md);
  border: 1px solid rgba(255, 193, 7, 0.2);
  margin-bottom: var(--spacing-md);
  text-align: right;
}

.current-plan-info {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  gap: var(--spacing-sm);
  margin-bottom: var(--spacing-sm);
  flex-direction: row-reverse;
}

.plan-label {
  color: var(--text-secondary);
  font-size: var(--font-size-sm);
  text-align: right;
}

.plan-name {
  color: var(--accent-primary);
  font-weight: 600;
  font-size: var(--font-size-base);
}

.plan-features {
  display: flex;
  flex-direction: column;
  gap: var(--spacing-xs);
  text-align: right;
}

.feature-item {
  display: flex;
  align-items: center;
  gap: var(--spacing-xs);
  color: var(--text-primary);
  font-size: var(--font-size-sm);
  flex-direction: row-reverse;
  justify-content: flex-start;
}

.feature-item i {
  color: var(--color-success);
}

.btn-vip-upgrade {
  width: 100%;
  padding: var(--spacing-md);
  background: var(--accent-gradient);
  border: none;
  border-radius: var(--radius-md);
  color: var(--text-primary);
  font-size: var(--font-size-base);
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
}

.btn-vip-upgrade:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(255, 193, 7, 0.4);
}

/* Projects Holdings Styles */
.holdings-projects-list {
  display: flex;
  flex-direction: column;
  gap: var(--spacing-md);
}

.project-item {
  padding: var(--spacing-md);
  background: rgba(255, 255, 255, 0.02);
  border-radius: var(--radius-md);
  border: 1px solid rgba(255, 255, 255, 0.05);
  transition: all 0.3s ease;
}

.project-item:hover {
  background: rgba(255, 255, 255, 0.05);
  transform: translateX(-3px);
}

.project-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: var(--spacing-sm);
  flex-wrap: wrap;
  gap: var(--spacing-xs);
}

.project-title {
  font-size: var(--font-size-base);
  font-weight: 600;
  color: var(--text-primary);
  flex: 1;
  min-width: 0;
  word-break: break-word;
  overflow-wrap: break-word;
}

.project-status {
  font-size: var(--font-size-xs);
  font-weight: 600;
  padding: var(--spacing-xs) var(--spacing-sm);
  border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.05);
  white-space: nowrap;
}

.project-progress {
  display: flex;
  align-items: center;
  gap: var(--spacing-md);
}

.progress-bar-container {
  flex: 1;
  height: 8px;
  background: rgba(255, 255, 255, 0.05);
  border-radius: var(--radius-full);
  overflow: hidden;
  position: relative;
}

.progress-bar-fill {
  height: 100%;
  border-radius: var(--radius-full);
  transition: width 0.5s ease;
  box-shadow: 0 0 10px rgba(40, 167, 69, 0.5);
}

.progress-percentage {
  font-size: var(--font-size-sm);
  font-weight: 600;
  color: var(--text-primary);
  min-width: 45px;
  text-align: left;
}

.loading-projects,
.empty-projects,
.error-projects {
  padding: var(--spacing-xl);
  text-align: center;
  color: var(--text-secondary);
  font-size: var(--font-size-base);
}

/* Discounts Styles */
.discounts-list {
  display: flex;
  flex-direction: column;
  gap: var(--spacing-md);
  max-height: 250px;
  overflow-y: auto;
  text-align: right;
  padding-left: var(--spacing-xs);
}

.discount-item {
  padding: var(--spacing-md);
  background: rgba(255, 193, 7, 0.08);
  border-radius: var(--radius-md);
  border: 1px solid rgba(255, 193, 7, 0.15);
  transition: all 0.3s ease;
  display: flex;
  align-items: center;
  gap: var(--spacing-md);
  text-align: right;
  flex-direction: row-reverse;
}

.discount-item:hover {
  background: rgba(255, 193, 7, 0.15);
  transform: translateX(3px);
  border-color: rgba(255, 193, 7, 0.3);
  box-shadow: 0 4px 12px rgba(255, 193, 7, 0.1);
}

.discount-item .discount-icon {
  width: 40px;
  height: 40px;
  background: var(--accent-gradient);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.discount-item .discount-icon i {
  color: var(--text-primary);
  font-size: var(--font-size-base);
}

.discount-item .discount-info {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.discount-code {
  font-size: var(--font-size-base);
  font-weight: 700;
  color: var(--accent-primary);
  font-family: 'Vazirmatn', 'Courier New', monospace;
  word-break: break-all;
  text-align: right;
}

.discount-value {
  font-size: var(--font-size-sm);
  font-weight: 600;
  color: var(--text-primary);
  text-align: right;
}

.discount-title {
  font-size: var(--font-size-xs);
  color: var(--text-secondary);
  line-height: 1.4;
  word-break: break-word;
  text-align: right;
}

.loading-discounts,
.empty-discounts,
.error-discounts {
  padding: var(--spacing-md);
  text-align: center;
  color: var(--text-secondary);
  font-size: var(--font-size-sm);
}

/* Tickets Styles */
.ticket-status {
  font-weight: 600;
  font-size: var(--font-size-xs);
  padding: 2px 6px;
  border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.05);
}

.loading-tickets,
.empty-tickets,
.error-tickets {
  padding: var(--spacing-md);
  text-align: center;
  color: var(--text-secondary);
  font-size: var(--font-size-sm);
}

@media (max-width: 768px) {
  .dashboard-grid {
    grid-template-columns: 1fr;
    padding: var(--spacing-md);
    gap: var(--spacing-md);
  }
  
  .user-info-card,
  .deposit-card,
  .total-asset-card,
  .vip-card,
  .holdings-card,
  .affiliate-card,
  .info-card {
    grid-column: span 1;
  }
  
  .header-container {
    padding: 0 var(--spacing-md);
    flex-wrap: wrap;
  }
  
  .main-nav {
    display: none;
  }
  
  .header-left {
    gap: var(--spacing-md);
  }
  
  .header-right {
    gap: var(--spacing-sm);
  }
  
  .btn-header {
    padding: var(--spacing-xs) var(--spacing-md);
    font-size: var(--font-size-xs);
  }
  
  .asset-amount-btc {
    font-size: var(--font-size-2xl);
  }
  
  .holdings-table-content {
    font-size: var(--font-size-xs);
  }
  
  .holdings-table-content thead th,
  .holdings-table-content tbody td {
    padding: var(--spacing-sm);
  }

  .project-header {
    flex-direction: column;
    align-items: flex-start;
  }

  .project-progress {
    flex-direction: column;
    align-items: stretch;
    gap: var(--spacing-xs);
  }

  .progress-percentage {
    text-align: center;
  }
}

/* ============================================
   GLASSMORPHISM OVERRIDE - اولویت بالا
   ============================================ */
html body .card,
html body .card.h-100,
html body div.card,
html body .dashboard-card,
html body .service-card,
html body .project-card,
html body .stat-card,
html body .admin-card,
html body .auth-card,
html body .auth-card-soft-ui,
html body .pricing-card,
html body .user-info-card,
html body .deposit-card,
html body .total-asset-card,
html body .vip-card,
html body .holdings-card,
html body .affiliate-card,
html body .info-card,
html body .service-card-item,
html body .project-card-item {
  background: rgba(44, 44, 44, 0.6) !important;
  backdrop-filter: blur(20px) !important;
  -webkit-backdrop-filter: blur(20px) !important;
  border-radius: 16px !important;
  border: 1px solid rgba(255, 255, 255, 0.1) !important;
  box-shadow: 
    0 8px 32px rgba(0, 0, 0, 0.3),
    0 0 0 1px rgba(255, 255, 255, 0.05),
    inset 0 1px 0 rgba(255, 255, 255, 0.1) !important;
  transition: all 0.3s ease !important;
  position: relative;
  overflow: hidden;
}

html body .card:hover,
html body .card.h-100:hover,
html body div.card:hover,
html body .dashboard-card:hover,
html body .service-card:hover,
html body .project-card:hover,
html body .stat-card:hover,
html body .admin-card:hover,
html body .auth-card:hover,
html body .auth-card-soft-ui:hover,
html body .user-info-card:hover,
html body .deposit-card:hover,
html body .total-asset-card:hover,
html body .vip-card:hover,
html body .holdings-card:hover,
html body .affiliate-card:hover,
html body .info-card:hover,
html body .service-card-item:hover,
html body .project-card-item:hover {
  background: rgba(54, 54, 54, 0.75) !important;
  box-shadow: 
    0 12px 40px rgba(0, 0, 0, 0.4),
    0 0 0 1px rgba(255, 193, 7, 0.3),
    0 0 30px rgba(255, 193, 7, 0.15),
    inset 0 1px 0 rgba(255, 255, 255, 0.15) !important;
  transform: translateY(-2px);
}

html body .vip-card:hover,
html body .affiliate-card:hover {
  transform: translateY(-2px) scale(1);
  border-color: rgba(255, 193, 7, 0.2) !important;
}

/* متن کارت‌ها */
html body .card .card-body,
html body .card.h-100 .card-body {
  background: transparent !important;
}

html body .card h1,
html body .card h2,
html body .card h3,
html body .card h4,
html body .card h5,
html body .card h6,
html body .card .card-title {
  color: #fff !important;
}

html body .card p,
html body .card .text-secondary,
html body .card span:not(.badge) {
  color: rgba(255, 255, 255, 0.7) !important;
}

/* آیکون‌ها */
html body .card i.text-accent,
html body .card .text-accent {
  color: var(--accent-primary, #FFC107) !important;
}

/* Project Detail View in Modal */
.project-detail-view {
  direction: rtl;
  text-align: right;
}

.project-detail-view .row {
  display: flex;
  flex-wrap: wrap;
  flex-direction: row-reverse;
}

.project-detail-view h6 {
  color: var(--text-muted);
  font-size: 0.875rem;
  margin-bottom: 0.5rem;
}

.project-detail-view p {
  color: var(--text-primary);
  font-weight: 500;
  margin-bottom: 0;
}

.project-detail-view .badge {
  font-size: 0.75rem;
  padding: 0.25rem 0.5rem;
  margin-right: 0.5rem;
}

/* Modal شیشه‌ای */
html body .modal-content {
  background: rgba(44, 44, 44, 0.9) !important;
  backdrop-filter: blur(25px) !important;
  -webkit-backdrop-filter: blur(25px) !important;
  border: 1px solid rgba(255, 255, 255, 0.1) !important;
  border-radius: 16px !important;
}

/* Dropdown شیشه‌ای */
html body .dropdown-menu {
  background: rgba(44, 44, 44, 0.95) !important;
  backdrop-filter: blur(20px) !important;
  -webkit-backdrop-filter: blur(20px) !important;
  border: 1px solid rgba(255, 255, 255, 0.1) !important;
  border-radius: 12px !important;
}

/* Navbar شیشه‌ای */
html body .navbar,
html body nav.navbar {
  background: rgba(30, 30, 30, 0.85) !important;
  backdrop-filter: blur(20px) !important;
  -webkit-backdrop-filter: blur(20px) !important;
}


/* ============================================
   Fallback for browsers without backdrop-filter
   ============================================ */
@supports not (backdrop-filter: blur(20px)) {
  .card,
  .card.h-100,
  .dashboard-card,
  .service-card,
  .project-card,
  .stat-card,
  .admin-card,
  .auth-card,
  .user-info-card,
  .deposit-card,
  .total-asset-card,
  .vip-card,
  .holdings-card,
  .affiliate-card,
  .info-card,
  .service-card-item,
  .project-card-item {
    background: rgba(44, 44, 44, 0.95) !important;
    box-shadow: 
      0 8px 32px rgba(0, 0, 0, 0.5),
      0 0 0 1px rgba(255, 255, 255, 0.1),
      inset 0 1px 0 rgba(255, 255, 255, 0.1) !important;
  }
}
