/* ============================================================
   VidReward DZ — Admin Dashboard Design System v2
   مستوحى من تصميم مفضّل: بنفسجي-نيلي + Neumorphism + Dark/Light
   ============================================================ */

@import url("https://fonts.googleapis.com/css2?family=Cairo:wght@400;600;700;900&family=Inter:wght@400;600;700;900&display=swap");

:root {
  --bg: #e8eaf0;
  --bg-elevated: #eef0f6;
  --shadow-light: #ffffff;
  --shadow-dark: #c5c8d4;

  --text-primary: #3d4066;
  --text-secondary: #8b8fad;

  --accent: #6366f1;
  --accent2: #818cf8;
  --accent-soft: rgba(99, 102, 241, 0.12);
  --green: #10b981;
  --green-soft: rgba(16, 185, 129, 0.12);
  --gold: #f59e0b;
  --gold-soft: rgba(245, 158, 11, 0.12);
  --red: #ef4444;
  --red-soft: rgba(239, 68, 68, 0.12);

  --border: rgba(99, 102, 241, 0.08);

  --radius-lg: 20px;
  --radius-md: 14px;
  --radius-sm: 10px;

  --font-display: "Cairo", sans-serif;
  --font-body: "Cairo", sans-serif;
  --font-num: "Inter", sans-serif;
}

html[data-theme="dark"] {
  --bg: #1a1c2e;
  --bg-elevated: #212339;
  --shadow-light: #2a2d47;
  --shadow-dark: #101223;

  --text-primary: #e8eaf0;
  --text-secondary: #8b8fad;

  --accent: #818cf8;
  --accent2: #a5b4fc;
  --accent-soft: rgba(129, 140, 248, 0.15);
  --green: #34d399;
  --green-soft: rgba(52, 211, 153, 0.15);
  --gold: #fbbf24;
  --gold-soft: rgba(251, 191, 36, 0.15);
  --red: #f87171;
  --red-soft: rgba(248, 113, 113, 0.15);

  --border: rgba(129, 140, 248, 0.1);
}

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

body {
  font-family: var(--font-body);
  background: var(--bg);
  color: var(--text-primary);
  min-height: 100vh;
  direction: rtl;
  transition: background 0.35s ease, color 0.35s ease;
}

.num {
  font-family: var(--font-num);
}

h1, h2, h3, .display {
  font-family: var(--font-display);
  font-weight: 900;
  margin: 0;
}

.neu {
  background: var(--bg-elevated);
  box-shadow: 6px 6px 14px var(--shadow-dark), -6px -6px 14px var(--shadow-light);
}

.neu-in {
  background: var(--bg);
  box-shadow: inset 4px 4px 10px var(--shadow-dark),
    inset -4px -4px 10px var(--shadow-light);
}

.neu-sm {
  background: var(--bg-elevated);
  box-shadow: 4px 4px 8px var(--shadow-dark), -4px -4px 8px var(--shadow-light);
}

.neu-btn {
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 14px;
  color: var(--text-primary);
  background: var(--bg-elevated);
  border: none;
  border-radius: var(--radius-md);
  padding: 13px 18px;
  cursor: pointer;
  box-shadow: 5px 5px 10px var(--shadow-dark), -5px -5px 10px var(--shadow-light);
  transition: all 0.2s ease;
}

.neu-btn:active {
  box-shadow: inset 3px 3px 6px var(--shadow-dark),
    inset -3px -3px 6px var(--shadow-light);
}

.neu-btn-accent {
  background: linear-gradient(135deg, var(--accent), var(--accent2));
  color: white;
  box-shadow: 4px 4px 12px var(--accent-soft);
}

.neu-input {
  width: 100%;
  font-family: var(--font-body);
  font-size: 14px;
  color: var(--text-primary);
  background: var(--bg);
  border: none;
  border-radius: var(--radius-md);
  padding: 13px 16px;
  box-shadow: inset 4px 4px 8px var(--shadow-dark),
    inset -4px -4px 8px var(--shadow-light);
  outline: none;
}

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

.card {
  border-radius: var(--radius-lg);
  overflow: hidden;
}

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

.card-title {
  font-size: 14px;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 8px;
}

.card-title svg {
  width: 18px;
  height: 18px;
  color: var(--accent);
}

.card-body {
  padding: 20px;
}

.theme-toggle {
  display: inline-flex;
  align-items: center;
  width: 60px;
  height: 32px;
  border-radius: 999px;
  background: var(--bg);
  box-shadow: inset 3px 3px 6px var(--shadow-dark),
    inset -3px -3px 6px var(--shadow-light);
  padding: 3px;
  cursor: pointer;
  border: none;
  position: relative;
}

.theme-toggle .knob {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: var(--bg-elevated);
  box-shadow: 3px 3px 6px var(--shadow-dark), -3px -3px 6px var(--shadow-light);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  transition: transform 0.25s ease;
  position: absolute;
  right: 3px;
}

html[data-theme="dark"] .theme-toggle .knob {
  transform: translateX(-28px);
}

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}
