/* =============================================
   GAWDA.AI - Main Stylesheet
   ذكاء ينجز عنك
   ============================================= */

@import url('https://fonts.googleapis.com/css2?family=Cairo:wght@300;400;500;600;700;800;900&family=Tajawal:wght@300;400;500;700;800&display=swap');

/* =============================================
   CSS Variables - Brand Colors from Logo
   ============================================= */
:root {
  /* Primary Brand Colors - from logo */
  --primary:        #E91E8C;   /* Pink/Magenta */
  --primary-dark:   #C2177A;
  --primary-light:  #FF4DAE;

  --secondary:      #00C8FF;   /* Cyan/Blue */
  --secondary-dark: #0099CC;
  --secondary-light:#4DD9FF;

  --accent-purple:  #7C3AED;   /* Purple */
  --accent-orange:  #FF6B35;   /* Orange */
  --accent-yellow:  #FFD700;   /* Yellow/Gold */
  --accent-green:   #00E676;   /* Green */

  /* Gradient - matches logo gradient */
  --gradient-main:  linear-gradient(135deg, #E91E8C 0%, #FF6B35 25%, #FFD700 50%, #00C8FF 75%, #7C3AED 100%);
  --gradient-pink:  linear-gradient(135deg, #E91E8C, #FF4DAE);
  --gradient-blue:  linear-gradient(135deg, #00C8FF, #7C3AED);
  --gradient-warm:  linear-gradient(135deg, #FF6B35, #FFD700);

  /* Dark Theme (Admin & Client Dashboard) */
  --dark-bg:        #0A0A0F;
  --dark-surface:   #12121A;
  --dark-card:      #1A1A26;
  --dark-border:    #2A2A3E;
  --dark-hover:     #222235;
  --dark-text:      #F0F0FF;
  --dark-text-muted:#8888AA;
  --dark-text-dim:  #555570;

  /* Sidebar */
  --sidebar-width:       260px;
  --sidebar-bg:          #0E0E1A;
  --sidebar-border:      #1E1E32;
  --sidebar-item-hover:  #1A1A2E;
  --sidebar-item-active: rgba(233, 30, 140, 0.15);

  /* Navbar */
  --navbar-height:  65px;
  --navbar-bg:      rgba(10, 10, 15, 0.95);

  /* Shadows */
  --shadow-sm:   0 2px 8px rgba(0,0,0,0.3);
  --shadow-md:   0 4px 20px rgba(0,0,0,0.4);
  --shadow-lg:   0 8px 40px rgba(0,0,0,0.5);
  --shadow-pink: 0 4px 20px rgba(233, 30, 140, 0.3);
  --shadow-blue: 0 4px 20px rgba(0, 200, 255, 0.3);
  --shadow-glow: 0 0 30px rgba(233, 30, 140, 0.2);

  /* Border Radius */
  --radius-sm:  6px;
  --radius-md:  12px;
  --radius-lg:  20px;
  --radius-xl:  30px;
  --radius-full: 9999px;

  /* Transitions */
  --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-fast: all 0.15s ease;

  /* Fonts */
  --font-primary: 'Cairo', sans-serif;
  --font-secondary: 'Tajawal', sans-serif;
}

/* =============================================
   Reset & Base
   ============================================= */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  direction: rtl;
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-primary);
  background-color: var(--dark-bg);
  color: var(--dark-text);
  line-height: 1.7;
  min-height: 100vh;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

a {
  text-decoration: none;
  color: inherit;
  transition: var(--transition-fast);
}

img {
  max-width: 100%;
  height: auto;
}

/* =============================================
   Scrollbar
   ============================================= */
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: var(--dark-surface); }
::-webkit-scrollbar-thumb { background: var(--dark-border); border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: var(--primary); }

/* =============================================
   Typography
   ============================================= */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-primary);
  font-weight: 700;
  line-height: 1.3;
  color: var(--dark-text);
}

.text-gradient {
  background: var(--gradient-main);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.text-muted { color: var(--dark-text-muted); }
.text-dim   { color: var(--dark-text-dim); }
.text-primary { color: var(--primary); }
.text-secondary { color: var(--secondary); }

/* =============================================
   Layout - Dashboard Wrapper
   ============================================= */
.dashboard-wrapper {
  display: flex;
  min-height: 100vh;
}

.main-content {
  flex: 1;
  margin-right: var(--sidebar-width);
  min-height: 100vh;
  transition: var(--transition);
}

.page-content {
  padding: calc(var(--navbar-height) + 24px) 24px 24px;
}

/* =============================================
   Navbar
   ============================================= */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: var(--sidebar-width);
  height: var(--navbar-height);
  background: var(--navbar-bg);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--dark-border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 24px;
  z-index: 100;
  transition: var(--transition);
}

.navbar-left {
  display: flex;
  align-items: center;
  gap: 16px;
}

.navbar-right {
  display: flex;
  align-items: center;
  gap: 8px;
}

/* Hamburger (mobile only) */
.btn-hamburger {
  display: none;
  width: 42px;
  height: 42px;
  border: none;
  background: var(--dark-card);
  border-radius: var(--radius-sm);
  cursor: pointer;
  align-items: center;
  justify-content: center;
  color: var(--dark-text);
  font-size: 1.2rem;
  transition: var(--transition-fast);
  border: 1px solid var(--dark-border);
}

.btn-hamburger:hover {
  background: var(--dark-hover);
  border-color: var(--primary);
  color: var(--primary);
}

/* Page Title in Navbar */
.navbar-title {
  font-size: 1rem;
  font-weight: 600;
  color: var(--dark-text-muted);
}

/* =============================================
   Notification Bell
   ============================================= */
.btn-notif {
  position: relative;
  width: 42px;
  height: 42px;
  border: none;
  background: var(--dark-card);
  border-radius: var(--radius-sm);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--dark-text-muted);
  font-size: 1.1rem;
  transition: var(--transition-fast);
  border: 1px solid var(--dark-border);
}

.btn-notif:hover {
  background: var(--dark-hover);
  color: var(--accent-yellow);
  border-color: var(--accent-yellow);
}

.btn-notif.has-notif {
  color: var(--accent-yellow);
  animation: bell-ring 1s ease-in-out;
}

.notif-badge {
  position: absolute;
  top: -5px;
  left: -5px;
  min-width: 18px;
  height: 18px;
  background: var(--primary);
  border-radius: var(--radius-full);
  font-size: 0.65rem;
  font-weight: 700;
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 4px;
  border: 2px solid var(--dark-bg);
  animation: badge-pop 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

@keyframes bell-ring {
  0%,100% { transform: rotate(0); }
  20%     { transform: rotate(-15deg); }
  40%     { transform: rotate(15deg); }
  60%     { transform: rotate(-10deg); }
  80%     { transform: rotate(10deg); }
}

@keyframes badge-pop {
  from { transform: scale(0); }
  to   { transform: scale(1); }
}

/* Notification Dropdown */
.notif-dropdown {
  position: absolute;
  top: calc(var(--navbar-height) - 10px);
  left: 16px;
  width: 360px;
  background: var(--dark-card);
  border: 1px solid var(--dark-border);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-lg);
  z-index: 200;
  display: none;
  overflow: hidden;
}

.notif-dropdown.open { display: block; animation: dropdown-in 0.2s ease; }

@keyframes dropdown-in {
  from { opacity: 0; transform: translateY(-10px); }
  to   { opacity: 1; transform: translateY(0); }
}

.notif-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 20px;
  border-bottom: 1px solid var(--dark-border);
}

.notif-header h4 { font-size: 0.95rem; font-weight: 600; }

.notif-mark-all {
  font-size: 0.75rem;
  color: var(--primary);
  cursor: pointer;
  border: none;
  background: none;
  font-family: var(--font-primary);
}

.notif-list { max-height: 360px; overflow-y: auto; }

.notif-item {
  display: flex;
  gap: 12px;
  padding: 14px 20px;
  border-bottom: 1px solid var(--dark-border);
  cursor: pointer;
  transition: var(--transition-fast);
  position: relative;
}

.notif-item:hover { background: var(--dark-hover); }
.notif-item.unread { background: rgba(233, 30, 140, 0.05); }
.notif-item.unread::before {
  content: '';
  position: absolute;
  right: 0;
  top: 0;
  bottom: 0;
  width: 3px;
  background: var(--primary);
}

.notif-icon {
  width: 38px;
  height: 38px;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
  flex-shrink: 0;
}

.notif-icon.info    { background: rgba(0,200,255,0.15); color: var(--secondary); }
.notif-icon.success { background: rgba(0,230,118,0.15); color: var(--accent-green); }
.notif-icon.warning { background: rgba(255,215,0,0.15);  color: var(--accent-yellow); }
.notif-icon.error   { background: rgba(233,30,140,0.15); color: var(--primary); }

.notif-body { flex: 1; min-width: 0; }
.notif-body .notif-title { font-size: 0.85rem; font-weight: 600; margin-bottom: 2px; }
.notif-body .notif-text  { font-size: 0.78rem; color: var(--dark-text-muted); }
.notif-body .notif-time  { font-size: 0.72rem; color: var(--dark-text-dim); margin-top: 4px; }

.notif-empty {
  padding: 40px 20px;
  text-align: center;
  color: var(--dark-text-muted);
  font-size: 0.85rem;
}

.notif-footer {
  padding: 12px 20px;
  border-top: 1px solid var(--dark-border);
  text-align: center;
}

.notif-footer a {
  font-size: 0.82rem;
  color: var(--primary);
}

/* =============================================
   Profile Dropdown
   ============================================= */
.profile-btn {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 6px 12px 6px 6px;
  background: var(--dark-card);
  border: 1px solid var(--dark-border);
  border-radius: var(--radius-full);
  cursor: pointer;
  transition: var(--transition-fast);
  position: relative;
}

.profile-btn:hover {
  border-color: var(--primary);
  background: var(--dark-hover);
}

.profile-avatar {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid var(--primary);
}

.profile-avatar-placeholder {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: var(--gradient-pink);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.85rem;
  font-weight: 700;
  color: #fff;
  flex-shrink: 0;
}

.profile-name {
  font-size: 0.85rem;
  font-weight: 600;
  max-width: 100px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.profile-arrow {
  font-size: 0.7rem;
  color: var(--dark-text-muted);
  transition: var(--transition-fast);
}

.profile-btn.open .profile-arrow { transform: rotate(180deg); }

/* Profile Dropdown Menu */
.profile-dropdown {
  position: absolute;
  top: calc(var(--navbar-height) - 10px);
  left: 16px;
  width: 220px;
  background: var(--dark-card);
  border: 1px solid var(--dark-border);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-lg);
  z-index: 200;
  display: none;
  overflow: hidden;
}

.profile-dropdown.open { display: block; animation: dropdown-in 0.2s ease; }

.profile-dropdown-header {
  padding: 16px;
  border-bottom: 1px solid var(--dark-border);
  text-align: center;
}

.profile-dropdown-header .name { font-size: 0.9rem; font-weight: 700; }
.profile-dropdown-header .email { font-size: 0.75rem; color: var(--dark-text-muted); }

.profile-dropdown-menu { padding: 8px 0; }

.profile-dropdown-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 16px;
  font-size: 0.85rem;
  cursor: pointer;
  transition: var(--transition-fast);
  color: var(--dark-text);
}

.profile-dropdown-item:hover { background: var(--dark-hover); color: var(--primary); }
.profile-dropdown-item i { width: 18px; text-align: center; }

.profile-dropdown-item.danger { color: #ff4444; }
.profile-dropdown-item.danger:hover { background: rgba(255,68,68,0.1); }

.profile-dropdown-divider {
  height: 1px;
  background: var(--dark-border);
  margin: 6px 0;
}

/* =============================================
   Sidebar
   ============================================= */
.sidebar {
  position: fixed;
  top: 0;
  right: 0;
  width: var(--sidebar-width);
  height: 100vh;
  background: var(--sidebar-bg);
  border-left: 1px solid var(--sidebar-border);
  display: flex;
  flex-direction: column;
  z-index: 150;
  transition: var(--transition);
  overflow: hidden;
}

/* Logo Area */
.sidebar-logo {
  height: var(--navbar-height);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 20px;
  border-bottom: 1px solid var(--sidebar-border);
  flex-shrink: 0;
}

.sidebar-logo img {
  height: 58px;
    width: auto;
    margin-top: 20px;
}

/* Nav */
.sidebar-nav {
  flex: 1;
  overflow-y: auto;
  padding: 16px 12px;
}

.sidebar-nav::-webkit-scrollbar { width: 3px; }
.sidebar-nav::-webkit-scrollbar-thumb { background: var(--dark-border); }

.nav-section-title {
  font-size: 0.68rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--dark-text-dim);
  padding: 12px 10px 6px;
}

.nav-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 11px 14px;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: var(--transition-fast);
  color: var(--dark-text-muted);
  font-size: 0.875rem;
  font-weight: 500;
  position: relative;
  margin-bottom: 2px;
}

.nav-item:hover {
  background: var(--sidebar-item-hover);
  color: var(--dark-text);
}

.nav-item.active {
  background: var(--sidebar-item-active);
  color: var(--primary);
  font-weight: 600;
}

.nav-item.active::before {
  content: '';
  position: absolute;
  right: 0;
  top: 20%;
  bottom: 20%;
  width: 3px;
  background: var(--primary);
  border-radius: 2px 0 0 2px;
}

.nav-item i {
  width: 20px;
  text-align: center;
  font-size: 1rem;
  flex-shrink: 0;
}

.nav-item .nav-badge {
  margin-right: auto;
  margin-left: 0;
  background: var(--primary);
  color: #fff;
  font-size: 0.65rem;
  font-weight: 700;
  padding: 2px 6px;
  border-radius: var(--radius-full);
}

/* Sidebar Footer */
.sidebar-footer {
  padding: 16px 12px;
  border-top: 1px solid var(--sidebar-border);
  flex-shrink: 0;
}

.sidebar-user {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px;
  border-radius: var(--radius-sm);
  background: var(--dark-card);
}

.sidebar-user .user-info { flex: 1; min-width: 0; }
.sidebar-user .user-name { font-size: 0.82rem; font-weight: 600; }
.sidebar-user .user-role {
  font-size: 0.7rem;
  color: var(--primary);
  font-weight: 500;
}

/* Overlay (Mobile) */
.sidebar-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.7);
  z-index: 140;
  backdrop-filter: blur(4px);
}

.sidebar-overlay.open { display: block; animation: fade-in 0.3s ease; }

@keyframes fade-in {
  from { opacity: 0; }
  to   { opacity: 1; }
}

/* =============================================
   Cards
   ============================================= */
.card {
  background: var(--dark-card);
  border: 1px solid var(--dark-border);
  border-radius: var(--radius-md);
  padding: 24px;
  transition: var(--transition-fast);
}

.card:hover { border-color: rgba(233, 30, 140, 0.3); }

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

.card-title {
  font-size: 1rem;
  font-weight: 700;
}

/* Stat Cards */
.stat-card {
  background: var(--dark-card);
  border: 1px solid var(--dark-border);
  border-radius: var(--radius-md);
  padding: 20px;
  position: relative;
  overflow: hidden;
  transition: var(--transition-fast);
}

.stat-card::after {
  content: '';
  position: absolute;
  top: 0;
  right: 0;
  width: 4px;
  height: 100%;
  background: var(--gradient-pink);
}

.stat-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-pink);
  border-color: rgba(233, 30, 140, 0.3);
}

.stat-card.blue::after { background: var(--gradient-blue); }
.stat-card.blue:hover { box-shadow: var(--shadow-blue); border-color: rgba(0,200,255,0.3); }
.stat-card.green::after { background: linear-gradient(to bottom, var(--accent-green), #00a854); }
.stat-card.yellow::after { background: linear-gradient(to bottom, var(--accent-yellow), #e6a800); }

.stat-icon {
  width: 48px;
  height: 48px;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.3rem;
  margin-bottom: 14px;
}

.stat-icon.pink   { background: rgba(233,30,140,0.15); color: var(--primary); }
.stat-icon.blue   { background: rgba(0,200,255,0.15); color: var(--secondary); }
.stat-icon.green  { background: rgba(0,230,118,0.15); color: var(--accent-green); }
.stat-icon.yellow { background: rgba(255,215,0,0.15); color: var(--accent-yellow); }
.stat-icon.purple { background: rgba(124,58,237,0.15); color: var(--accent-purple); }

.stat-value {
  font-size: 1.8rem;
  font-weight: 800;
  line-height: 1;
  margin-bottom: 6px;
}

.stat-label {
  font-size: 0.8rem;
  color: var(--dark-text-muted);
  font-weight: 500;
}

.stat-change {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 0.75rem;
  font-weight: 600;
  margin-top: 8px;
}

.stat-change.up   { color: var(--accent-green); }
.stat-change.down { color: #ff4444; }

/* =============================================
   Buttons
   ============================================= */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 20px;
  border-radius: var(--radius-sm);
  border: none;
  cursor: pointer;
  font-family: var(--font-primary);
  font-size: 0.875rem;
  font-weight: 600;
  transition: var(--transition-fast);
  white-space: nowrap;
}

.btn-primary {
  background: var(--gradient-pink);
  color: #fff;
  box-shadow: var(--shadow-pink);
}

.btn-primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 24px rgba(233, 30, 140, 0.4);
}

.btn-secondary {
  background: var(--gradient-blue);
  color: #fff;
  box-shadow: var(--shadow-blue);
}

.btn-outline {
  background: transparent;
  border: 1px solid var(--dark-border);
  color: var(--dark-text-muted);
}

.btn-outline:hover {
  border-color: var(--primary);
  color: var(--primary);
  background: rgba(233, 30, 140, 0.05);
}

.btn-danger {
  background: linear-gradient(135deg, #ff4444, #cc0000);
  color: #fff;
}

.btn-sm { padding: 7px 14px; font-size: 0.8rem; }
.btn-lg { padding: 14px 28px; font-size: 1rem; }

.btn-icon {
  width: 38px;
  height: 38px;
  padding: 0;
  border-radius: var(--radius-sm);
  background: var(--dark-card);
  border: 1px solid var(--dark-border);
  color: var(--dark-text-muted);
}

.btn-icon:hover {
  border-color: var(--primary);
  color: var(--primary);
  background: var(--dark-hover);
}

/* =============================================
   Forms
   ============================================= */
.form-group { margin-bottom: 20px; }

.form-label {
  display: block;
  font-size: 0.85rem;
  font-weight: 600;
  margin-bottom: 8px;
  color: var(--dark-text-muted);
}

.form-control {
  width: 100%;
  padding: 11px 14px;
  background: var(--dark-surface);
  border: 1px solid var(--dark-border);
  border-radius: var(--radius-sm);
  color: var(--dark-text);
  font-family: var(--font-primary);
  font-size: 0.875rem;
  transition: var(--transition-fast);
  outline: none;
}

.form-control:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(233, 30, 140, 0.1);
}

.form-control::placeholder { color: var(--dark-text-dim); }

select.form-control {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8'%3E%3Cpath d='M6 8L0 0h12z' fill='%23666'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: 12px center;
  padding-left: 32px;
}

/* =============================================
   Tables
   ============================================= */
.table-wrapper {
  overflow-x: auto;
  border-radius: var(--radius-md);
  border: 1px solid var(--dark-border);
}

table {
  width: 100%;
  border-collapse: collapse;
}

thead th {
  background: var(--dark-surface);
  padding: 14px 16px;
  text-align: right;
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--dark-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  border-bottom: 1px solid var(--dark-border);
  white-space: nowrap;
}

tbody td {
  padding: 14px 16px;
  font-size: 0.875rem;
  border-bottom: 1px solid var(--dark-border);
  vertical-align: middle;
}

tbody tr:last-child td { border-bottom: none; }
tbody tr:hover td { background: var(--dark-hover); }

/* =============================================
   Badges & Tags
   ============================================= */
.badge {
  display: inline-flex;
  align-items: center;
  padding: 3px 10px;
  border-radius: var(--radius-full);
  font-size: 0.72rem;
  font-weight: 700;
}

.badge-success { background: rgba(0,230,118,0.15); color: var(--accent-green); }
.badge-danger  { background: rgba(255,68,68,0.15);  color: #ff4444; }
.badge-warning { background: rgba(255,215,0,0.15);  color: var(--accent-yellow); }
.badge-info    { background: rgba(0,200,255,0.15);  color: var(--secondary); }
.badge-primary { background: rgba(233,30,140,0.15); color: var(--primary); }
.badge-purple  { background: rgba(124,58,237,0.15); color: var(--accent-purple); }

/* =============================================
   Points & Wallet Display
   ============================================= */
.points-display {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 14px;
  background: var(--dark-card);
  border: 1px solid var(--dark-border);
  border-radius: var(--radius-full);
  font-size: 0.85rem;
  font-weight: 700;
}

.points-display .points-icon {
  width: 24px;
  height: 24px;
  background: var(--gradient-warm);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.7rem;
  color: #fff;
}

/* =============================================
   Gradient Borders
   ============================================= */
.gradient-border {
  position: relative;
  border-radius: var(--radius-md);
}

.gradient-border::before {
  content: '';
  position: absolute;
  inset: -1px;
  border-radius: calc(var(--radius-md) + 1px);
  background: var(--gradient-main);
  z-index: -1;
}

/* =============================================
   Loading & Skeleton
   ============================================= */
.skeleton {
  background: linear-gradient(90deg, var(--dark-card) 25%, var(--dark-hover) 50%, var(--dark-card) 75%);
  background-size: 200% 100%;
  animation: skeleton-loading 1.5s infinite;
  border-radius: var(--radius-sm);
}

@keyframes skeleton-loading {
  from { background-position: 200% 0; }
  to   { background-position: -200% 0; }
}

/* =============================================
   Alerts
   ============================================= */
.alert {
  padding: 14px 18px;
  border-radius: var(--radius-sm);
  font-size: 0.875rem;
  display: flex;
  align-items: flex-start;
  gap: 12px;
  margin-bottom: 16px;
}

.alert-success { background: rgba(0,230,118,0.1);  border: 1px solid rgba(0,230,118,0.3); color: var(--accent-green); }
.alert-danger  { background: rgba(255,68,68,0.1);  border: 1px solid rgba(255,68,68,0.3); color: #ff4444; }
.alert-warning { background: rgba(255,215,0,0.1);  border: 1px solid rgba(255,215,0,0.3);  color: var(--accent-yellow); }
.alert-info    { background: rgba(0,200,255,0.1);  border: 1px solid rgba(0,200,255,0.3);  color: var(--secondary); }

/* =============================================
   Pagination
   ============================================= */
.pagination {
  display: flex;
  align-items: center;
  gap: 6px;
  justify-content: center;
  margin-top: 24px;
}

.page-btn {
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-sm);
  border: 1px solid var(--dark-border);
  background: var(--dark-card);
  color: var(--dark-text-muted);
  font-size: 0.85rem;
  cursor: pointer;
  transition: var(--transition-fast);
}

.page-btn:hover { border-color: var(--primary); color: var(--primary); }
.page-btn.active { background: var(--gradient-pink); border-color: transparent; color: #fff; }

/* =============================================
   Modal
   ============================================= */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.75);
  backdrop-filter: blur(8px);
  z-index: 300;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

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

.modal {
  background: var(--dark-card);
  border: 1px solid var(--dark-border);
  border-radius: var(--radius-lg);
  width: 100%;
  max-width: 520px;
  max-height: 90vh;
  overflow-y: auto;
  animation: modal-in 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

@keyframes modal-in {
  from { opacity: 0; transform: scale(0.9) translateY(20px); }
  to   { opacity: 1; transform: scale(1) translateY(0); }
}

.modal-header {
  padding: 20px 24px;
  border-bottom: 1px solid var(--dark-border);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.modal-title { font-size: 1.1rem; font-weight: 700; }
.modal-body  { padding: 24px; }
.modal-footer {
  padding: 16px 24px;
  border-top: 1px solid var(--dark-border);
  display: flex;
  justify-content: flex-end;
  gap: 10px;
}

.btn-close {
  width: 32px;
  height: 32px;
  border: none;
  background: var(--dark-hover);
  border-radius: var(--radius-sm);
  cursor: pointer;
  color: var(--dark-text-muted);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
  transition: var(--transition-fast);
}

.btn-close:hover { background: rgba(255,68,68,0.2); color: #ff4444; }

/* =============================================
   Toast Notifications
   ============================================= */
.toast-container {
  position: fixed;
  bottom: 24px;
  left: 24px;
  z-index: 500;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.toast {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 18px;
  background: var(--dark-card);
  border: 1px solid var(--dark-border);
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-lg);
  min-width: 280px;
  max-width: 360px;
  animation: toast-in 0.3s ease;
}

@keyframes toast-in {
  from { opacity: 0; transform: translateX(-20px); }
  to   { opacity: 1; transform: translateX(0); }
}

.toast.success { border-right: 3px solid var(--accent-green); }
.toast.error   { border-right: 3px solid #ff4444; }
.toast.warning { border-right: 3px solid var(--accent-yellow); }
.toast.info    { border-right: 3px solid var(--secondary); }

/* =============================================
   Grid Utilities
   ============================================= */
.grid { display: grid; gap: 20px; }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }

.flex { display: flex; }
.flex-center { display: flex; align-items: center; justify-content: center; }
.flex-between { display: flex; align-items: center; justify-content: space-between; }
.gap-8  { gap: 8px; }
.gap-12 { gap: 12px; }
.gap-16 { gap: 16px; }
.gap-20 { gap: 20px; }
.gap-24 { gap: 24px; }

/* =============================================
   Responsive - Mobile
   ============================================= */
@media (max-width: 991px) {
  :root {
    --sidebar-width: 0px;
  }

  .sidebar {
    transform: translateX(100%);
    width: 260px;
    z-index: 160;
  }

  .sidebar.open {
    transform: translateX(0);
  }

  .main-content {
    margin-right: 0;
  }

  .navbar {
    right: 0;
  }

  .btn-hamburger {
    display: flex;
  }

  .profile-name {
    display: none;
  }

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

  .notif-dropdown,
  .profile-dropdown {
    width: calc(100vw - 32px);
    left: 16px;
    right: 16px;
  }
}

@media (max-width: 576px) {
  .page-content { padding: calc(var(--navbar-height) + 16px) 16px 16px; }
  .grid-4, .grid-3, .grid-2 { grid-template-columns: 1fr; }
  .stat-value { font-size: 1.5rem; }
}

/* =============================================
   Animations
   ============================================= */
.fade-in {
  animation: fade-up 0.4s ease forwards;
}

@keyframes fade-up {
  from { opacity: 0; transform: translateY(16px); }
  to   { opacity: 1; transform: translateY(0); }
}

.stagger > * {
  opacity: 0;
  animation: fade-up 0.4s ease forwards;
}

.stagger > *:nth-child(1) { animation-delay: 0.05s; }
.stagger > *:nth-child(2) { animation-delay: 0.10s; }
.stagger > *:nth-child(3) { animation-delay: 0.15s; }
.stagger > *:nth-child(4) { animation-delay: 0.20s; }
.stagger > *:nth-child(5) { animation-delay: 0.25s; }
.stagger > *:nth-child(6) { animation-delay: 0.30s; }
