/* ==========================================================================
   style.css
   استایل مشترک تمام صفحات سامانه مدیریت اعضا
   هویت بصری: کارت عضویت طلایی روی زمینه سبز تیره (حس باشگاه/کلوب خصوصی)
   ========================================================================== */

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

/* ---------- توکن‌های طراحی ---------- */
:root {
  --ink: #0F2A22;
  --ink-2: #0B211A;
  --surface: #163A2F;
  --surface-2: #1E4A3B;
  --surface-3: #245A48;
  --gold: #D8A94C;
  --gold-light: #F0C877;
  --gold-dim: rgba(216, 169, 76, 0.14);
  --sage: #7FA88F;
  --cream: #F5F1E6;
  --muted: #9DB3A8;
  --danger: #E2685A;
  --danger-dim: rgba(226, 104, 90, 0.14);
  --ok: #6FBE8C;
  --ok-dim: rgba(111, 190, 140, 0.14);
  --radius-sm: 10px;
  --radius: 16px;
  --radius-lg: 24px;
  --shadow: 0 20px 50px rgba(5, 15, 12, 0.45);
  --font-display: 'Vazirmatn', sans-serif;
  --font-mono: 'JetBrains Mono', monospace;
}

/* ---------- ریست پایه ---------- */
* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  min-height: 100vh;
  font-family: var(--font-display);
  background: var(--ink);
  background-image:
    radial-gradient(circle at 12% 8%, rgba(216, 169, 76, 0.08), transparent 40%),
    radial-gradient(circle at 90% 85%, rgba(127, 168, 143, 0.10), transparent 45%);
  color: var(--cream);
  direction: rtl;
  line-height: 1.75;
}

a { color: inherit; text-decoration: none; }
ul { list-style: none; margin: 0; padding: 0; }
img { max-width: 100%; display: block; }
button { font-family: inherit; cursor: pointer; }

::selection { background: var(--gold); color: var(--ink); }

:focus-visible {
  outline: 2px solid var(--gold-light);
  outline-offset: 3px;
  border-radius: 6px;
}

.mono { font-family: var(--font-mono); letter-spacing: 0.03em; }

/* ---------- کانتینر عمومی ---------- */
.container {
  width: 100%;
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ==========================================================================
   هدر / ناوبری
   ========================================================================== */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(15, 42, 34, 0.85);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid rgba(216, 169, 76, 0.14);
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 24px;
  max-width: 1180px;
  margin: 0 auto;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  font-size: 18px;
}

.brand .brand-mark {
  width: 38px;
  height: 38px;
  border-radius: 10px;
  background: linear-gradient(135deg, var(--gold-light), var(--gold));
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--ink);
  font-weight: 900;
  font-size: 16px;
  flex-shrink: 0;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 8px;
}

.nav-links a {
  padding: 9px 16px;
  border-radius: 999px;
  font-size: 14px;
  font-weight: 600;
  color: var(--muted);
  transition: background 0.2s, color 0.2s;
}

.nav-links a:hover,
.nav-links a.active {
  background: var(--gold-dim);
  color: var(--gold-light);
}

.nav-links a.cta {
  background: var(--gold);
  color: var(--ink);
}

.nav-links a.cta:hover {
  background: var(--gold-light);
}

.nav-toggle {
  display: none;
  width: 42px;
  height: 42px;
  border-radius: 10px;
  border: 1px solid rgba(216, 169, 76, 0.25);
  background: transparent;
  color: var(--cream);
  align-items: center;
  justify-content: center;
  font-size: 20px;
}

/* ==========================================================================
   دکمه‌ها
   ========================================================================== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 13px 24px;
  border-radius: 12px;
  border: none;
  font-size: 14.5px;
  font-weight: 700;
  font-family: inherit;
  transition: transform 0.15s, box-shadow 0.15s, background 0.15s;
}

.btn-gold {
  background: linear-gradient(135deg, var(--gold-light), var(--gold));
  color: var(--ink);
}

.btn-gold:hover { transform: translateY(-2px); box-shadow: 0 12px 28px rgba(216, 169, 76, 0.3); }

.btn-outline {
  background: transparent;
  border: 1px solid rgba(216, 169, 76, 0.4);
  color: var(--gold-light);
}

.btn-outline:hover { background: var(--gold-dim); }

.btn-ghost {
  background: rgba(255,255,255,0.05);
  color: var(--cream);
  border: 1px solid rgba(255,255,255,0.08);
}

.btn-ghost:hover { background: rgba(255,255,255,0.09); }

.btn-danger {
  background: var(--danger-dim);
  color: #FFC2BA;
  border: 1px solid rgba(226, 104, 90, 0.35);
}

.btn-danger:hover { background: rgba(226, 104, 90, 0.22); }

.btn-ok {
  background: var(--ok-dim);
  color: #B7EAC9;
  border: 1px solid rgba(111, 190, 140, 0.35);
}

.btn-ok:hover { background: rgba(111, 190, 140, 0.22); }

.btn-sm { padding: 8px 14px; font-size: 13px; border-radius: 9px; }
.btn-block { width: 100%; }
.btn:disabled { opacity: 0.5; cursor: not-allowed; transform: none !important; }

/* ==========================================================================
   هیرو (صفحه اصلی)
   ========================================================================== */
.hero {
  padding: 72px 24px 40px;
}

.hero-grid {
  max-width: 1180px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 56px;
  align-items: center;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 12.5px;
  font-weight: 700;
  color: var(--gold-light);
  background: var(--gold-dim);
  padding: 6px 14px;
  border-radius: 999px;
  margin-bottom: 20px;
  border: 1px solid rgba(216, 169, 76, 0.25);
}

.hero h1 {
  font-size: 44px;
  font-weight: 900;
  line-height: 1.35;
  margin: 0 0 18px;
}

.hero h1 .accent { color: var(--gold-light); }

.hero p.lead {
  font-size: 16.5px;
  color: var(--muted);
  max-width: 480px;
  margin: 0 0 30px;
}

.hero-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 36px;
}

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

.hero-stat .num {
  font-family: var(--font-mono);
  font-size: 24px;
  font-weight: 700;
  color: var(--gold-light);
}

.hero-stat .label {
  font-size: 12.5px;
  color: var(--muted);
  margin-top: 2px;
}

/* ---------- کارت عضویت (عنصر امضادار طراحی) ---------- */
.membership-card {
  position: relative;
  width: 100%;
  max-width: 400px;
  margin: 0 auto;
  aspect-ratio: 1.58 / 1;
  border-radius: 20px;
  padding: 26px 26px 22px;
  background:
    radial-gradient(circle at 85% 0%, rgba(240, 200, 119, 0.18), transparent 55%),
    linear-gradient(155deg, var(--surface-3), var(--surface) 60%, var(--ink-2));
  border: 1px solid rgba(216, 169, 76, 0.35);
  box-shadow: var(--shadow);
  color: var(--cream);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  transform: rotate(-4deg);
  transition: transform 0.4s ease;
}

.membership-card:hover { transform: rotate(0deg) scale(1.02); }

.card-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
}

.card-brand {
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.14em;
  color: var(--gold-light);
  text-transform: uppercase;
}

.card-status {
  font-size: 10.5px;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: 999px;
  background: var(--ok-dim);
  color: #B7EAC9;
  border: 1px solid rgba(111, 190, 140, 0.35);
}
.card-status.pending { background: var(--gold-dim); color: var(--gold-light); border-color: rgba(216,169,76,0.35); }
.card-status.rejected { background: var(--danger-dim); color: #FFC2BA; border-color: rgba(226,104,90,0.35); }

.card-mid {
  display: flex;
  align-items: center;
  gap: 14px;
}

.card-avatar {
  width: 54px;
  height: 54px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--gold-light), var(--gold));
  color: var(--ink);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 900;
  font-size: 19px;
  flex-shrink: 0;
}

.card-name { font-size: 17px; font-weight: 800; }
.card-role { font-size: 12px; color: var(--muted); margin-top: 2px; }

.card-bottom {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
}

.card-code-label { font-size: 10px; color: var(--muted); letter-spacing: 0.08em; margin-bottom: 4px; }
.card-code { font-family: var(--font-mono); font-size: 19px; font-weight: 700; letter-spacing: 0.06em; color: var(--gold-light); }

.card-qr {
  width: 46px;
  height: 46px;
  border-radius: 8px;
  background:
    repeating-linear-gradient(90deg, var(--ink) 0 3px, transparent 3px 6px),
    repeating-linear-gradient(0deg, var(--ink) 0 3px, transparent 3px 6px);
  background-color: var(--cream);
  opacity: 0.9;
}

.card-date { font-size: 10.5px; color: var(--muted); margin-top: 8px; }

/* ==========================================================================
   بخش‌های عمومی صفحه
   ========================================================================== */
.section { padding: 64px 24px; }
.section-tight { padding: 40px 24px; }

.section-head { max-width: 620px; margin: 0 auto 42px; text-align: center; }
.section-head h2 { font-size: 30px; font-weight: 800; margin: 10px 0 12px; }
.section-head p { color: var(--muted); font-size: 15px; }

.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 20px; }

.card {
  background: var(--surface);
  border: 1px solid rgba(216, 169, 76, 0.12);
  border-radius: var(--radius);
  padding: 26px;
}

.card:hover { border-color: rgba(216, 169, 76, 0.28); }

/* ---------- کارت‌های پاداش (امتیاز) ---------- */
.reward-card {
  text-align: center;
  transition: transform 0.2s, border-color 0.2s;
}
.reward-card:hover { transform: translateY(-4px); }

.reward-points {
  font-family: var(--font-mono);
  font-size: 30px;
  font-weight: 700;
  color: var(--gold-light);
  margin-bottom: 6px;
}

.reward-points span { font-size: 13px; color: var(--muted); font-weight: 500; }
.reward-title { font-size: 15px; font-weight: 700; margin-bottom: 6px; }
.reward-desc { font-size: 13px; color: var(--muted); }

/* ==========================================================================
   فرم‌ها
   ========================================================================== */
.auth-wrap {
  min-height: calc(100vh - 78px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px 20px;
}

.auth-card {
  width: 100%;
  max-width: 420px;
  background: var(--surface);
  border: 1px solid rgba(216, 169, 76, 0.16);
  border-radius: var(--radius-lg);
  padding: 38px 32px;
  box-shadow: var(--shadow);
  animation: rise 0.5s ease;
}

@keyframes rise {
  from { opacity: 0; transform: translateY(14px); }
  to { opacity: 1; transform: translateY(0); }
}

.auth-icon {
  width: 50px; height: 50px;
  border-radius: 13px;
  background: linear-gradient(135deg, var(--gold-light), var(--gold));
  display: flex; align-items: center; justify-content: center;
  color: var(--ink); font-weight: 900; font-size: 19px;
  margin-bottom: 18px;
}

.auth-card h1 { font-size: 22px; font-weight: 800; margin: 0 0 6px; }
.auth-card p.subtitle { color: var(--muted); font-size: 13.5px; margin: 0 0 26px; }

.field { margin-bottom: 16px; }
.field label {
  display: block;
  font-size: 12.5px;
  font-weight: 600;
  color: var(--muted);
  margin-bottom: 6px;
}

.field input,
.field select,
.field textarea {
  width: 100%;
  padding: 12px 14px;
  border-radius: 10px;
  border: 1px solid rgba(255,255,255,0.1);
  background: rgba(255,255,255,0.04);
  color: var(--cream);
  font-family: inherit;
  font-size: 14px;
  outline: none;
  transition: border-color 0.2s, background 0.2s;
}

.field textarea { resize: vertical; min-height: 90px; }

.field input:focus,
.field select:focus,
.field textarea:focus {
  border-color: var(--gold);
  background: rgba(255,255,255,0.06);
}

.field small.error {
  display: none;
  color: #FFC2BA;
  font-size: 12px;
  margin-top: 6px;
}

.field.invalid input,
.field.invalid select { border-color: var(--danger); }
.field.invalid small.error { display: block; }

.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }

.form-msg {
  padding: 11px 14px;
  border-radius: 10px;
  font-size: 13px;
  margin-bottom: 16px;
  display: none;
}
.form-msg.show { display: block; }
.form-msg.error { background: var(--danger-dim); color: #FFC2BA; border: 1px solid rgba(226,104,90,0.3); }
.form-msg.success { background: var(--ok-dim); color: #B7EAC9; border: 1px solid rgba(111,190,140,0.3); }

.hint { margin-top: 18px; font-size: 12.5px; color: var(--muted); text-align: center; }
.hint a { color: var(--gold-light); font-weight: 700; }

/* ==========================================================================
   لایوت داشبورد (کاربر/ادمین)
   ========================================================================== */
.dash-shell { display: flex; min-height: 100vh; }

.dash-sidebar {
  width: 250px;
  flex-shrink: 0;
  background: var(--surface);
  border-left: 1px solid rgba(216, 169, 76, 0.12);
  padding: 22px 16px;
  display: flex;
  flex-direction: column;
  position: sticky;
  top: 0;
  height: 100vh;
}

.dash-sidebar .brand { padding: 0 8px; margin-bottom: 28px; }

.side-nav { display: flex; flex-direction: column; gap: 3px; flex: 1; overflow-y: auto; }

.side-link {
  display: flex; align-items: center; gap: 10px;
  padding: 11px 13px;
  border-radius: 11px;
  font-size: 13.5px;
  font-weight: 600;
  color: var(--muted);
  border: 1px solid transparent;
  background: none;
  width: 100%;
  text-align: right;
}

.side-link .ic { width: 18px; text-align: center; }

.side-link:hover { background: rgba(255,255,255,0.04); color: var(--cream); }

.side-link.active {
  background: var(--gold-dim);
  color: var(--gold-light);
  border-color: rgba(216, 169, 76, 0.25);
}

.side-foot { border-top: 1px solid rgba(255,255,255,0.06); padding-top: 14px; margin-top: 10px; }

.who-chip { display: flex; align-items: center; gap: 10px; padding: 0 4px 12px; }
.who-chip .avatar {
  width: 34px; height: 34px; border-radius: 50%;
  background: linear-gradient(135deg, var(--gold-light), var(--gold));
  color: var(--ink); display: flex; align-items: center; justify-content: center;
  font-weight: 800; font-size: 13px; flex-shrink: 0;
}
.who-chip .name { font-size: 13px; font-weight: 700; }
.who-chip .role { font-size: 11px; color: var(--muted); }

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

.dash-topbar {
  display: flex; align-items: center; justify-content: space-between;
  padding: 18px 28px;
  border-bottom: 1px solid rgba(255,255,255,0.06);
  position: sticky; top: 0;
  background: rgba(15, 42, 34, 0.9);
  backdrop-filter: blur(10px);
  z-index: 20;
}

.dash-topbar h1 { font-size: 18px; font-weight: 800; margin: 0; }
.dash-body { padding: 26px 28px 60px; }

.panel-toggle {
  display: none;
  width: 38px; height: 38px;
  border-radius: 9px;
  border: 1px solid rgba(216,169,76,0.25);
  background: transparent; color: var(--cream);
  align-items: center; justify-content: center;
}

/* ---------- تب‌های داشبورد ادمین ---------- */
.tab-panel { display: none; }
.tab-panel.active { display: block; animation: fadeIn 0.3s ease; }
@keyframes fadeIn { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: translateY(0); } }

/* ---------- کارت‌های آماری ---------- */
.stat-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
  gap: 14px;
  margin-bottom: 28px;
}

.stat-box {
  background: var(--surface);
  border: 1px solid rgba(216, 169, 76, 0.12);
  border-radius: var(--radius);
  padding: 18px 20px;
}

.stat-box .stat-num { font-family: var(--font-mono); font-size: 26px; font-weight: 700; color: var(--gold-light); }
.stat-box .stat-label { font-size: 12.5px; color: var(--muted); margin-top: 4px; }

/* ---------- جدول‌ها ---------- */
.table-wrap {
  background: var(--surface);
  border: 1px solid rgba(216, 169, 76, 0.12);
  border-radius: var(--radius);
  overflow: hidden;
}

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

th {
  text-align: right;
  font-size: 12px;
  font-weight: 700;
  color: var(--muted);
  padding: 13px 16px;
  background: rgba(255,255,255,0.03);
  border-bottom: 1px solid rgba(255,255,255,0.06);
  white-space: nowrap;
}

td {
  padding: 13px 16px;
  font-size: 13.5px;
  border-bottom: 1px solid rgba(255,255,255,0.04);
  vertical-align: middle;
}

tbody tr:last-child td { border-bottom: none; }
tbody tr:hover { background: rgba(255,255,255,0.025); }

.table-toolbar {
  display: flex; align-items: center; justify-content: space-between;
  gap: 12px; flex-wrap: wrap;
  margin-bottom: 16px;
}

.search-box {
  position: relative;
  max-width: 280px;
  flex: 1;
}

.search-box input {
  width: 100%;
  padding: 10px 14px;
  border-radius: 10px;
  border: 1px solid rgba(255,255,255,0.1);
  background: rgba(255,255,255,0.04);
  color: var(--cream);
  font-family: inherit;
  font-size: 13.5px;
  outline: none;
}
.search-box input:focus { border-color: var(--gold); }

/* ---------- برچسب‌های وضعیت ---------- */
.badge {
  display: inline-flex; align-items: center; gap: 5px;
  font-size: 11.5px; font-weight: 700;
  padding: 4px 11px; border-radius: 999px;
}
.badge-ok { background: var(--ok-dim); color: #B7EAC9; border: 1px solid rgba(111,190,140,0.3); }
.badge-pending { background: var(--gold-dim); color: var(--gold-light); border: 1px solid rgba(216,169,76,0.3); }
.badge-danger { background: var(--danger-dim); color: #FFC2BA; border: 1px solid rgba(226,104,90,0.3); }
.badge-muted { background: rgba(255,255,255,0.06); color: var(--muted); border: 1px solid rgba(255,255,255,0.08); }

/* ---------- چک‌باکس حضور ---------- */
.attend-check {
  width: 22px; height: 22px;
  border-radius: 7px;
  border: 1.5px solid rgba(216,169,76,0.4);
  background: transparent;
  cursor: pointer;
  display: inline-flex; align-items: center; justify-content: center;
  color: var(--ink); font-size: 13px; font-weight: 900;
  transition: background 0.15s, border-color 0.15s;
}
.attend-check.on { background: var(--gold); border-color: var(--gold); }

/* ---------- کارت اطلاعیه ---------- */
.notice-item {
  display: flex; gap: 14px;
  padding: 16px 0;
  border-bottom: 1px solid rgba(255,255,255,0.06);
}
.notice-item:last-child { border-bottom: none; }
.notice-dot {
  width: 9px; height: 9px; border-radius: 50%;
  background: var(--gold); margin-top: 7px; flex-shrink: 0;
}
.notice-title { font-weight: 700; font-size: 14px; margin-bottom: 3px; }
.notice-body { font-size: 13px; color: var(--muted); line-height: 1.8; }
.notice-date { font-size: 11px; color: var(--muted); margin-top: 6px; }

/* ---------- مودال ساده ---------- */
.modal-overlay {
  position: fixed; inset: 0;
  background: rgba(6, 14, 11, 0.72);
  backdrop-filter: blur(3px);
  display: none;
  align-items: center; justify-content: center;
  padding: 20px;
  z-index: 100;
}
.modal-overlay.show { display: flex; }

.modal-box {
  width: 100%; max-width: 440px;
  background: var(--surface-2);
  border: 1px solid rgba(216,169,76,0.2);
  border-radius: var(--radius-lg);
  padding: 28px;
  box-shadow: var(--shadow);
  animation: rise 0.3s ease;
}

.modal-box h3 { margin: 0 0 6px; font-size: 18px; font-weight: 800; }
.modal-box p { color: var(--muted); font-size: 13.5px; margin: 0 0 20px; }
.modal-actions { display: flex; gap: 10px; justify-content: flex-end; margin-top: 22px; }

/* ---------- toast ---------- */
.toast-wrap {
  position: fixed; bottom: 22px; left: 50%;
  transform: translateX(-50%);
  z-index: 200;
  display: flex; flex-direction: column; gap: 8px;
  align-items: center;
}
.toast {
  background: var(--surface-2);
  border: 1px solid rgba(216,169,76,0.3);
  color: var(--cream);
  padding: 12px 20px;
  border-radius: 12px;
  font-size: 13.5px;
  font-weight: 600;
  box-shadow: var(--shadow);
  animation: toastIn 0.25s ease;
}
.toast.success { border-color: rgba(111,190,140,0.4); }
.toast.error { border-color: rgba(226,104,90,0.4); }
@keyframes toastIn { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: translateY(0); } }

/* ---------- فوتر ---------- */
.site-footer {
  border-top: 1px solid rgba(216, 169, 76, 0.1);
  padding: 30px 24px;
  text-align: center;
  color: var(--muted);
  font-size: 12.5px;
}

/* ==========================================================================
   ابزارهای عمومی
   ========================================================================== */
.flex { display: flex; }
.flex-between { display: flex; align-items: center; justify-content: space-between; }
.flex-center { display: flex; align-items: center; justify-content: center; }
.gap-8 { gap: 8px; } .gap-12 { gap: 12px; } .gap-16 { gap: 16px; }
.mt-8 { margin-top: 8px; } .mt-16 { margin-top: 16px; } .mt-24 { margin-top: 24px; }
.mb-0 { margin-bottom: 0 !important; }
.text-muted { color: var(--muted); }
.text-center { text-align: center; }
.w-full { width: 100%; }
.empty-state { text-align: center; padding: 50px 20px; color: var(--muted); font-size: 13.5px; }
.empty-state .empty-ic { font-size: 30px; margin-bottom: 10px; }
.hidden { display: none !important; }

/* ---------- انیمیشن ورود عناصر هنگام اسکرول ---------- */
.reveal { opacity: 0; transform: translateY(18px); transition: opacity 0.6s ease, transform 0.6s ease; }
.reveal.in { opacity: 1; transform: translateY(0); }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.001ms !important; transition-duration: 0.001ms !important; }
  html { scroll-behavior: auto; }
}

/* ==========================================================================
   ریسپانسیو
   ========================================================================== */
@media (max-width: 980px) {
  .hero-grid { grid-template-columns: 1fr; gap: 40px; }
  .membership-card { max-width: 360px; }
  .grid-3 { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 860px) {
  .dash-sidebar {
    position: fixed; right: 0; top: 0; z-index: 60;
    transform: translateX(100%);
    transition: transform 0.25s ease;
    box-shadow: var(--shadow);
  }
  .dash-sidebar.open { transform: translateX(0); }
  .panel-toggle { display: flex; }
  .dash-body { padding: 20px 16px 50px; }
  .dash-topbar { padding: 14px 16px; }
}

@media (max-width: 720px) {
  .nav-links { display: none; }
  .nav-links.open {
    display: flex; flex-direction: column;
    position: absolute; top: 100%; right: 0; left: 0;
    background: var(--surface); padding: 14px; gap: 6px;
    border-bottom: 1px solid rgba(216,169,76,0.15);
  }
  .nav-toggle { display: flex; }
  .hero h1 { font-size: 32px; }
  .grid-3, .grid-2 { grid-template-columns: 1fr; }
  .field-row { grid-template-columns: 1fr; }
  .table-wrap { overflow-x: auto; }
  table { min-width: 640px; }
}

/* ==========================================================================
   گالری جلسات
   ========================================================================== */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 16px;
}

.gallery-thumb {
  position: relative;
  border-radius: var(--radius);
  overflow: hidden;
  aspect-ratio: 4 / 3;
  cursor: pointer;
  border: 1px solid rgba(216, 169, 76, 0.15);
  background: var(--surface);
}

.gallery-thumb img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.3s; }
.gallery-thumb:hover img { transform: scale(1.06); }

.gallery-thumb .cap {
  position: absolute; inset-inline: 0; bottom: 0;
  padding: 10px 12px;
  background: linear-gradient(to top, rgba(6,14,11,0.85), transparent);
  font-size: 12.5px; font-weight: 700;
}

.lightbox-overlay {
  position: fixed; inset: 0;
  background: rgba(6, 14, 11, 0.9);
  backdrop-filter: blur(4px);
  display: none;
  align-items: center; justify-content: center;
  padding: 24px;
  z-index: 120;
}
.lightbox-overlay.show { display: flex; }

.lightbox-box {
  width: 100%; max-width: 720px;
  background: var(--surface-2);
  border: 1px solid rgba(216,169,76,0.2);
  border-radius: var(--radius-lg);
  padding: 20px;
  animation: rise 0.3s ease;
}

.lightbox-main {
  width: 100%; aspect-ratio: 16/10;
  border-radius: 14px;
  overflow: hidden;
  margin-bottom: 12px;
  background: var(--ink);
}
.lightbox-main img { width: 100%; height: 100%; object-fit: cover; }

.lightbox-thumbs { display: flex; gap: 8px; flex-wrap: wrap; }
.lightbox-thumbs img {
  width: 62px; height: 62px; object-fit: cover;
  border-radius: 8px; cursor: pointer;
  border: 2px solid transparent;
  opacity: 0.7;
}
.lightbox-thumbs img.active { border-color: var(--gold); opacity: 1; }

.lightbox-close {
  display: flex; align-items: center; justify-content: center;
  margin-top: 14px;
}

/* ==========================================================================
   جدول رتبه‌بندی + پاداش‌های صفحه اصلی
   ========================================================================== */
.rank-row {
  display: flex; align-items: center; justify-content: space-between;
  padding: 9px 4px;
  border-bottom: 1px solid rgba(255,255,255,0.05);
  font-size: 13px;
}
.rank-row:last-child { border-bottom: none; }
.rank-row .rank-num {
  display: inline-flex; align-items: center; justify-content: center;
  width: 24px; height: 24px; border-radius: 50%;
  background: var(--gold-dim); color: var(--gold-light);
  font-family: var(--font-mono); font-size: 11.5px; font-weight: 700;
  margin-left: 8px;
}
.rank-row.top1 .rank-num { background: linear-gradient(135deg, var(--gold-light), var(--gold)); color: var(--ink); }

/* ==========================================================================
   پاداش‌های من (کاربر) - قفل/باز
   ========================================================================== */
.reward-user-card { position: relative; text-align: center; }
.reward-user-card.locked { opacity: 0.55; }
.reward-user-card .lock-badge {
  position: absolute; top: 14px; left: 14px;
  font-size: 16px;
}
.reward-user-card .btn { margin-top: 14px; }

/* ==========================================================================
   مودال پروفایل عضو (ادمین)
   ========================================================================== */
.profile-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px 16px;
  font-size: 13px;
}
.profile-grid .pg-label { color: var(--muted); font-size: 11.5px; margin-bottom: 2px; }
.profile-grid .pg-value { font-weight: 600; }
.profile-photo {
  width: 72px; height: 72px; border-radius: 14px;
  object-fit: cover; border: 1px solid rgba(216,169,76,0.25);
  margin-bottom: 14px;
}

/* ==========================================================================
   آپلود فایل سفارشی
   ========================================================================== */
.file-drop {
  border: 1.5px dashed rgba(216, 169, 76, 0.3);
  border-radius: 12px;
  padding: 20px;
  text-align: center;
  font-size: 12.5px;
  color: var(--muted);
  cursor: pointer;
  transition: border-color 0.2s, background 0.2s;
}
.file-drop:hover { border-color: var(--gold); background: rgba(216,169,76,0.04); }
.file-drop input[type="file"] { display: none; }
.file-drop .file-name { color: var(--gold-light); font-weight: 700; margin-top: 6px; }

.receipt-thumb {
  width: 100%; max-width: 180px; border-radius: 10px;
  border: 1px solid rgba(216,169,76,0.2);
}

/* ==========================================================================
   بخش آدرس و شبکه اجتماعی
   ========================================================================== */
.contact-strip {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 16px;
}
.contact-item {
  display: flex; align-items: flex-start; gap: 12px;
}
.contact-item .ic {
  width: 40px; height: 40px; border-radius: 11px;
  background: var(--gold-dim); color: var(--gold-light);
  display: flex; align-items: center; justify-content: center;
  font-size: 17px; flex-shrink: 0;
}
.contact-item .title { font-weight: 700; font-size: 13.5px; margin-bottom: 3px; }
.contact-item .val { font-size: 12.5px; color: var(--muted); word-break: break-all; }

/* ==========================================================================
   کارت نظرات اعضا
   ========================================================================== */
.testimonial-card { position: relative; padding-top: 34px; }
.testimonial-card::before {
  content: '”';
  position: absolute; top: 6px; right: 20px;
  font-size: 40px; font-weight: 900; color: var(--gold); opacity: 0.4; line-height: 1;
}
.testimonial-text { font-size: 13.5px; line-height: 1.9; color: var(--cream); margin-bottom: 14px; }
.testimonial-author { font-size: 12.5px; font-weight: 700; color: var(--gold-light); }

/* ==========================================================================
   گفتگوی مدیر و اعضا
   ========================================================================== */
.chat-box {
  display: flex; flex-direction: column; gap: 10px;
  max-height: 420px; overflow-y: auto;
  padding: 6px 4px 12px;
}
.chat-bubble {
  max-width: 75%;
  padding: 10px 14px;
  border-radius: 14px;
  font-size: 13px;
  line-height: 1.8;
  position: relative;
}
.chat-bubble .chat-time { display: block; font-size: 10.5px; color: var(--muted); margin-top: 4px; }
.chat-bubble.mine {
  align-self: flex-start;
  background: linear-gradient(135deg, var(--gold-light), var(--gold));
  color: var(--ink);
  border-bottom-left-radius: 4px;
}
.chat-bubble.mine .chat-time { color: rgba(15,42,34,0.6); }
.chat-bubble.theirs {
  align-self: flex-end;
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.08);
  border-bottom-right-radius: 4px;
}
.chat-input-row { display: flex; gap: 10px; margin-top: 14px; }
.chat-input-row textarea { flex: 1; min-height: 46px; resize: none; }
.chat-empty { text-align: center; padding: 30px 10px; color: var(--muted); font-size: 13px; }

.member-pick-list { display: flex; flex-direction: column; gap: 6px; max-height: 420px; overflow-y: auto; }
.member-pick-item {
  display: flex; align-items: center; justify-content: space-between;
  padding: 10px 12px; border-radius: 10px;
  font-size: 13px; cursor: pointer;
  border: 1px solid transparent;
}
.member-pick-item:hover { background: rgba(255,255,255,0.04); }
.member-pick-item.active { background: var(--gold-dim); border-color: rgba(216,169,76,0.3); color: var(--gold-light); }
.member-pick-item .count-badge {
  font-size: 10.5px; background: rgba(255,255,255,0.08); padding: 2px 8px; border-radius: 999px;
}

@media (max-width: 720px) {
  .profile-grid { grid-template-columns: 1fr; }
}

@media (max-width: 480px) {
  .hero { padding: 48px 18px 30px; }
  .auth-card { padding: 28px 22px; }
}

/* ---------- شماره کارت برای واریز ---------- */
.pay-card {
  background: var(--surface-2);
  border: 1px solid rgba(216, 169, 76, 0.35);
  border-radius: var(--radius);
  padding: 20px;
  max-width: 420px;
  text-align: center;
}
.pay-card-label { font-size: 12px; color: var(--muted); margin-bottom: 8px; }
.pay-card-number {
  font-size: 22px; font-weight: 700; color: var(--gold-light);
  letter-spacing: 0.08em; margin-bottom: 8px; user-select: all;
}
.pay-card-holder { font-size: 13px; color: var(--cream); margin-bottom: 14px; }
@media (max-width: 480px) { .pay-card-number { font-size: 18px; } }

/* ==========================================================================
   امضای سازنده (void null;) — فوتر
   ========================================================================== */
.footer-credit {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin-top: 16px;
  opacity: 0.85;
  transition: opacity 0.2s;
}
.footer-credit:hover { opacity: 1; }
.footer-credit img {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  display: block;
}
.footer-credit .credit-name {
  font-family: "Courier New", Consolas, monospace;
  color: var(--cream);
  font-weight: 700;
}
