/* ==========================================================================
   پدل تو — پنل مدیریت و پنل باشگاه
   قاب سرمه‌ای + پنل سفید، تخته‌های کانبان، جدول، دراور جزئیات
   ========================================================================== */

:root {
  --navy: #0C1230;
  --navy-2: #161D44;
  --navy-3: #222A57;
  --lime: #D6F43D;
  --mist: #F3F5F9;
  --white: #FFFFFF;

  --ink: var(--navy);
  --ink-2: rgba(12, 18, 48, .66);
  --ink-3: rgba(12, 18, 48, .46);
  --ink-4: rgba(12, 18, 48, .26);
  --fill: rgba(12, 18, 48, .045);
  --fill-2: rgba(12, 18, 48, .08);
  --line: rgba(12, 18, 48, .08);
  --line-2: rgba(12, 18, 48, .14);
  --on-dark: #FFFFFF;
  --on-dark-2: rgba(255, 255, 255, .64);
  --on-dark-3: rgba(255, 255, 255, .40);
  --dark-line: rgba(255, 255, 255, .08);

  --danger: #E5484D;
  --danger-fill: rgba(229, 72, 77, .10);
  --hl: rgba(214, 244, 61, .65);          /* ماژیک لیمویی زیر مبلغ‌ها */

  /* رنگ وضعیت‌ها (نقطه‌های سر ستون) */
  --st-new: #8D93A8;
  --st-progress: var(--navy);
  --st-done: var(--lime);
  --st-lost: var(--danger);

  --r-sm: 10px;
  --r-md: 14px;
  --r-lg: 18px;
  --r-xl: 28px;

  --side-w: 268px;
  --font: "Yekan Bakh", Tahoma, system-ui, sans-serif;
  --ease: cubic-bezier(.2, .8, .2, 1);
  --shadow: 0 1px 2px rgba(12, 18, 48, .05), 0 12px 32px -16px rgba(12, 18, 48, .18);
  --shadow-lg: 0 30px 80px -24px rgba(12, 18, 48, .55);
}

*, *::before, *::after { box-sizing: border-box; }
html, body { margin: 0; height: 100%; }
body {
  font-family: var(--font); font-size: 14.5px; line-height: 1.6;
  color: var(--ink); background: var(--navy);
  -webkit-font-smoothing: antialiased;
}
h1, h2, h3, h4, p { margin: 0; }
button, input, textarea, select { font: inherit; color: inherit; }
button { cursor: pointer; border: 0; background: none; padding: 0; }
a { color: inherit; text-decoration: none; }
ul { margin: 0; padding: 0; list-style: none; }
svg { display: block; }
.ltr { direction: ltr; unicode-bidi: isolate; display: inline-block; }
:focus-visible { outline: 2.5px solid var(--navy); outline-offset: 2px; border-radius: 8px; }
.side :focus-visible { outline-color: var(--lime); }

.ico { width: 20px; height: 20px; flex: none; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.ico--sm { width: 17px; height: 17px; }
.ico--xs { width: 14px; height: 14px; stroke-width: 2.1; }
.ico--lg { width: 24px; height: 24px; }

/* ---------- پوسته ---------- */
.shell { display: grid; grid-template-columns: var(--side-w) 1fr; height: 100vh; }

/* ---------- سایدبار ---------- */
.side {
  display: flex; flex-direction: column;
  padding: 26px 18px 18px; color: var(--on-dark); overflow-y: auto;
  scrollbar-width: none;
}
.side::-webkit-scrollbar { display: none; }
.side__brand { display: flex; align-items: center; gap: 10px; padding: 0 8px; }
.side__brand img { height: 24px; }

.ws { position: relative; margin-top: 26px; }
.ws__btn {
  width: 100%; display: flex; align-items: center; gap: 12px;
  padding: 10px 12px; border-radius: 16px;
  background: var(--navy-2); box-shadow: inset 0 0 0 1px var(--dark-line);
  text-align: start;
}
.ws__icon { width: 38px; height: 38px; border-radius: 12px; display: grid; place-items: center; background: var(--lime); color: var(--navy); flex: none; font-weight: 900; }
.ws__btn small { display: block; font-size: 11.5px; color: var(--on-dark-3); line-height: 1.3; }
.ws__btn b { font-size: 14px; font-weight: 700; }
.ws__btn .ico { margin-inline-start: auto; color: var(--on-dark-3); }
.ws__menu {
  position: absolute; inset-inline: 0; top: calc(100% + 8px); z-index: 30;
  padding: 6px; border-radius: 16px; background: var(--navy-3);
  box-shadow: var(--shadow-lg); display: none;
}
.ws.is-open .ws__menu { display: block; }
.ws__menu button { width: 100%; display: flex; align-items: center; gap: 10px; padding: 10px; border-radius: 12px; text-align: start; font-size: 13.5px; }
.ws__menu button:hover { background: rgba(255,255,255,.06); }
.ws__menu button small { display: block; color: var(--on-dark-3); font-size: 11.5px; }
.ws__menu .ws__icon { width: 32px; height: 32px; border-radius: 10px; font-size: 12px; }
.ws__menu .ws__icon--dark { background: rgba(255,255,255,.1); color: var(--white); }

.nav { margin-top: 30px; }
.nav[hidden] { display: none; }
.nav a {
  display: flex; align-items: center; gap: 12px;
  height: 42px; padding: 0 12px; border-radius: 12px;
  font-size: 14px; color: var(--on-dark-2);
  transition: background .15s, color .15s;
}
.nav a + a { margin-top: 2px; }
.nav a .ico { color: var(--on-dark-3); }
.nav a:hover { color: var(--white); background: rgba(255,255,255,.04); }
.nav a.is-on { background: rgba(255,255,255,.08); color: var(--white); font-weight: 700; }
.nav a.is-on .ico { color: var(--lime); }
.nav .count { margin-inline-start: auto; min-width: 22px; height: 20px; padding: 0 7px; border-radius: 99px; background: var(--lime); color: var(--navy); font-size: 11.5px; font-weight: 800; display: grid; place-items: center; }
.nav .count--muted { background: rgba(255,255,255,.1); color: var(--on-dark-2); }

.side__sec { margin-top: 22px; padding-top: 18px; border-top: 1px solid var(--dark-line); }
.side__sec-title { display: flex; align-items: center; gap: 8px; padding: 0 10px; margin-bottom: 8px; font-size: 13px; font-weight: 700; color: var(--on-dark-3); }
.club-link { display: flex; align-items: center; gap: 12px; height: 40px; padding: 0 10px; border-radius: 12px; font-size: 14px; color: var(--on-dark-2); width: 100%; text-align: start; }
.club-link:hover { background: rgba(255,255,255,.04); color: var(--white); }
.club-link .sq { width: 26px; height: 26px; border-radius: 8px; display: grid; place-items: center; font-size: 11px; font-weight: 800; background: rgba(255,255,255,.1); color: var(--white); flex: none; }
.club-link .sq--lime { background: var(--lime); color: var(--navy); }
.club-link .state { margin-inline-start: auto; width: 7px; height: 7px; border-radius: 50%; background: var(--lime); }
.club-link .state--off { background: var(--on-dark-3); }

.side__me { margin-top: auto; padding-top: 18px; display: flex; align-items: center; gap: 10px; }
.side__me small { display: block; font-size: 11.5px; color: var(--on-dark-3); line-height: 1.3; }
.side__me b { font-size: 13.5px; }
.side__me .icon-btn { margin-inline-start: auto; background: rgba(255,255,255,.08); color: var(--on-dark-2); box-shadow: none; }

/* ---------- پنل سفید ---------- */
.main { padding: 16px; padding-inline-start: 0; min-width: 0; }
.panel {
  position: relative; height: 100%; overflow: hidden;
  display: flex; flex-direction: column;
  background: var(--white); border-radius: var(--r-xl);
}
.view { display: none; flex-direction: column; min-height: 0; flex: 1; }
.view.is-on { display: flex; }

.ph { display: flex; align-items: center; gap: 16px; padding: 24px 30px 0; }
.ph h1 { font-size: 26px; font-weight: 800; line-height: 1.3; }
.ph h1 small { display: block; font-size: 13px; font-weight: 400; color: var(--ink-3); }
.ph__actions { margin-inline-start: auto; display: flex; align-items: center; gap: 10px; }
.search {
  display: flex; align-items: center; gap: 10px;
  width: 260px; height: 46px; padding: 0 16px; border-radius: 14px;
  background: var(--mist); color: var(--ink-3);
}
.search input { flex: 1; border: 0; outline: 0; background: none; font-size: 14px; color: var(--ink); min-width: 0; }

.toolbar { display: flex; align-items: center; gap: 10px; padding: 18px 30px 18px; border-bottom: 1px solid var(--line); flex-wrap: wrap; }
.toolbar__end { margin-inline-start: auto; display: flex; gap: 10px; align-items: center; }
.vbody { flex: 1; overflow: auto; padding: 24px 30px 40px; min-height: 0; }
.vbody--board { padding: 0; background: var(--mist); }
.vbody--flush { padding: 0; }

/* ---------- دکمه‌ها ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  height: 46px; padding: 0 20px; border-radius: 14px;
  font-size: 14.5px; font-weight: 700; white-space: nowrap;
  transition: transform .12s var(--ease), background .15s, box-shadow .15s;
}
.btn:active { transform: scale(.98); }
.btn--primary { background: var(--navy); color: var(--white); }
.btn--lime { background: var(--lime); color: var(--navy); }
.btn--outline { background: var(--white); color: var(--navy); box-shadow: inset 0 0 0 1.5px var(--navy); }
.btn--soft { background: var(--mist); color: var(--navy); font-weight: 500; }
.btn--soft:hover { background: var(--fill-2); }
.btn--danger { background: var(--danger-fill); color: var(--danger); }
.btn--sm { height: 36px; padding: 0 14px; font-size: 13px; border-radius: 11px; }
.btn--block { width: 100%; }
.btn .caret { color: var(--ink-3); }
.btn b { font-weight: 700; color: var(--ink); }

.icon-btn { width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; background: var(--mist); color: var(--ink); flex: none; }
.icon-btn:hover { background: var(--fill-2); }
.icon-btn--ghost { background: none; }
.icon-btn--sm { width: 32px; height: 32px; }

/* ---------- برچسب، چیپ، آواتار ---------- */
.tag { display: inline-flex; align-items: center; gap: 5px; height: 24px; padding: 0 10px; border-radius: 99px; font-size: 11.5px; font-weight: 700; white-space: nowrap; line-height: 1; }
.tag--lime { background: var(--lime); color: var(--navy); }
.tag--navy { background: var(--navy); color: var(--white); }
.tag--soft { background: var(--fill-2); color: var(--ink-2); }
.tag--line { box-shadow: inset 0 0 0 1.5px var(--line-2); color: var(--ink-2); }
.tag--danger { background: var(--danger-fill); color: var(--danger); }
.tag--guest { box-shadow: inset 0 0 0 1.5px var(--ink-4); color: var(--ink-2); border-radius: 99px; }
.dot { width: 9px; height: 9px; border-radius: 50%; display: inline-block; flex: none; }
.dot--new { background: var(--st-new); }
.dot--progress { background: var(--st-progress); }
.dot--done { background: var(--st-done); box-shadow: 0 0 0 1.5px var(--navy); }
.dot--lost { background: var(--st-lost); }
.status { display: inline-flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 500; white-space: nowrap; }

.av { --s: 30px; width: var(--s); height: var(--s); border-radius: 50%; flex: none; display: grid; place-items: center; font-size: calc(var(--s) * .4); font-weight: 800; background: var(--navy); color: var(--lime); line-height: 1; }
.av--2 { background: var(--lime); color: var(--navy); }
.av--3 { background: #DDE2EC; color: var(--navy); }
.av--4 { background: var(--navy-3); color: var(--white); }
.av--guest { background: var(--mist); color: var(--ink-2); box-shadow: inset 0 0 0 1.5px dashed var(--ink-4); outline: 1.5px dashed var(--ink-3); outline-offset: -1.5px; }
.av--sq { border-radius: 9px; }
.av--lg { --s: 48px; } .av--xl { --s: 64px; } .av--sm { --s: 24px; }

.chips { display: flex; gap: 8px; flex-wrap: wrap; }
.chip { height: 34px; padding: 0 14px; border-radius: 99px; display: inline-flex; align-items: center; gap: 6px; font-size: 13px; font-weight: 500; background: var(--mist); color: var(--ink-2); }
.chip.is-on { background: var(--navy); color: var(--white); font-weight: 700; }
.chip .x { color: var(--ink-3); }

.seg { display: inline-flex; padding: 4px; border-radius: 13px; background: var(--mist); }
.seg button { height: 34px; padding: 0 16px; border-radius: 10px; font-size: 13.5px; font-weight: 500; color: var(--ink-2); white-space: nowrap; }
.seg button.is-on { background: var(--white); color: var(--navy); font-weight: 700; box-shadow: 0 1px 3px rgba(12,18,48,.1); }

.amount { font-weight: 800; font-size: 15.5px; background: linear-gradient(transparent 58%, var(--hl) 58%, var(--hl) 92%, transparent 92%); padding: 0 2px; }
.amount small { font-weight: 500; font-size: 12.5px; }

/* ---------- کانبان ---------- */
.board { display: flex; gap: 22px; padding: 24px 30px 40px; min-height: 100%; align-items: flex-start; width: max-content; }
.col { width: 296px; flex: none; }
.col__head { display: flex; align-items: center; gap: 10px; margin-bottom: 16px; padding: 0 2px; }
.col__head h3 { font-size: 18px; font-weight: 500; }
.col__sum { margin-inline-start: auto; height: 30px; padding: 0 12px; border-radius: 99px; background: var(--navy); color: var(--white); font-size: 12.5px; font-weight: 700; display: grid; place-items: center; }
.col__list { display: flex; flex-direction: column; gap: 14px; min-height: 120px; border-radius: 18px; transition: background .15s; }
.col.is-over .col__list { background: rgba(214, 244, 61, .18); outline: 2px dashed var(--ink-4); outline-offset: 6px; }
.dropzone {
  height: 150px; border-radius: 18px; border: 2px dashed var(--ink-4);
  display: grid; place-items: center; font-size: 26px; font-weight: 800; color: var(--ink-4);
}
.col.is-over .dropzone { border-color: var(--navy); color: var(--navy); }

.kcard {
  background: var(--white); border-radius: 18px; padding: 16px;
  box-shadow: 0 0 0 1px var(--line), 0 1px 2px rgba(12,18,48,.04);
  cursor: grab; text-align: start; width: 100%; display: block;
  transition: transform .18s var(--ease), box-shadow .18s, opacity .15s;
}
.kcard:hover { box-shadow: 0 0 0 1px var(--line-2), var(--shadow); }
.kcard.is-dragging { opacity: .35; }
.kcard.is-picked { background: rgba(214, 244, 61, .55); transform: rotate(-2deg); box-shadow: var(--shadow); }
.kcard__head { display: flex; align-items: center; gap: 10px; }
.kcard__name { font-weight: 700; font-size: 15px; flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.kcard__more { color: var(--ink-3); }
.kcard__value { margin-top: 12px; }
.kcard__note { padding-top: 12px; margin-top: 12px; border-top: 1px solid var(--line); font-size: 14px; color: var(--ink); line-height: 1.7; }
.kcard__foot { display: flex; align-items: center; gap: 8px; margin-top: 14px; font-size: 12.5px; }
.kcard__time { margin-inline-start: auto; display: inline-flex; align-items: center; gap: 4px; color: var(--ink-3); }
.type-ico { width: 30px; height: 30px; border-radius: 9px; display: grid; place-items: center; background: var(--mist); color: var(--navy); flex: none; }
.type-ico--lime { background: var(--lime); }
.type-ico--navy { background: var(--navy); color: var(--lime); }
.type-ico--danger { background: var(--danger-fill); color: var(--danger); }

/* ---------- جدول ---------- */
.tbl-wrap { border-radius: 18px; box-shadow: 0 0 0 1px var(--line); overflow: auto; }
.tbl { width: 100%; border-collapse: collapse; font-size: 13.5px; }
.tbl th { position: sticky; top: 0; z-index: 1; background: var(--mist); text-align: start; font-size: 12px; font-weight: 700; color: var(--ink-3); padding: 12px 16px; white-space: nowrap; }
.tbl td { padding: 12px 16px; border-top: 1px solid var(--line); white-space: nowrap; vertical-align: middle; }
.tbl tbody tr { cursor: pointer; transition: background .12s; }
.tbl tbody tr:hover { background: rgba(243, 245, 249, .7); }
.tbl .who { display: flex; align-items: center; gap: 10px; font-weight: 700; }
.tbl .who small { display: block; font-weight: 400; color: var(--ink-3); font-size: 12px; line-height: 1.3; }
.tbl .num { font-weight: 700; }
.tbl .muted { color: var(--ink-2); }
.tbl .end { text-align: end; }
.cb { width: 18px; height: 18px; accent-color: var(--navy); }

/* ---------- کارت‌ها و آمار ---------- */
.grid { display: grid; gap: 16px; }
.g-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.g-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.g-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.g-5 { grid-template-columns: repeat(5, minmax(0, 1fr)); }
.g-main { grid-template-columns: minmax(0, 1.65fr) minmax(0, 1fr); align-items: start; }
.card { background: var(--white); border-radius: 20px; padding: 20px; box-shadow: 0 0 0 1px var(--line); }
.card--mist { background: var(--mist); box-shadow: none; }
.card--dark { position: relative; overflow: hidden; isolation: isolate; background: var(--navy); color: var(--white); box-shadow: none; }
.card--dark::before, .card--dark::after { content: ""; position: absolute; pointer-events: none; z-index: -1; }
.card--dark::before { top: -2px; bottom: -2px; inset-inline-start: 66%; width: 24%; border-inline: 1.5px solid var(--dark-line); }
.card--dark::after { top: 50%; inset-inline-start: 66%; width: 24%; height: 50%; border-top: 1.5px solid var(--dark-line); background: linear-gradient(var(--dark-line), var(--dark-line)) 50% 0 / 1.5px 100% no-repeat; }
.card__head { display: flex; align-items: center; gap: 10px; margin-bottom: 16px; }
.card__head h3 { font-size: 16px; font-weight: 800; }
.card__head .link { margin-inline-start: auto; }
.link { font-size: 13px; font-weight: 700; border-bottom: 2px solid var(--lime); }

.stat__label { font-size: 13px; color: var(--ink-2); display: flex; align-items: center; gap: 8px; }
.stat__num { font-size: 30px; font-weight: 900; line-height: 1.3; margin-top: 6px; }
.stat__sub { font-size: 12.5px; color: var(--ink-3); margin-top: 2px; }
.card--dark .stat__label, .card--dark .stat__sub { color: var(--on-dark-2); }
.delta { font-size: 12px; font-weight: 800; padding: 2px 8px; border-radius: 99px; background: var(--lime); color: var(--navy); direction: ltr; display: inline-block; }
.delta--down { background: var(--danger-fill); color: var(--danger); }

.bars { display: flex; align-items: flex-end; gap: 10px; height: 180px; padding-top: 10px; }
.bars__col { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 8px; height: 100%; justify-content: flex-end; }
.bars__bar { width: 100%; max-width: 38px; border-radius: 10px 10px 4px 4px; background: var(--fill-2); position: relative; }
.bars__bar.is-now { background: var(--navy); }
.bars__bar.is-now::after { content: attr(data-v); position: absolute; top: -26px; inset-inline-start: 50%; translate: 50% 0; font-size: 11px; font-weight: 800; background: var(--lime); padding: 1px 7px; border-radius: 99px; }
.bars__lab { font-size: 11.5px; color: var(--ink-3); }

.queue a { display: flex; align-items: center; gap: 12px; padding: 12px 0; }
.queue a + a { border-top: 1px solid var(--line); }
.queue b { font-size: 14px; }
.queue small { display: block; font-size: 12px; color: var(--ink-3); }
.queue .count { margin-inline-start: auto; min-width: 30px; height: 26px; border-radius: 99px; display: grid; place-items: center; font-weight: 800; font-size: 13px; background: var(--mist); padding: 0 8px; }
.queue .count--hot { background: var(--navy); color: var(--lime); }

.feed li { display: flex; gap: 12px; padding: 10px 0; font-size: 13.5px; align-items: flex-start; }
.feed li + li { border-top: 1px solid var(--line); }
.feed small { display: block; color: var(--ink-3); font-size: 12px; }

.bar { height: 6px; border-radius: 99px; background: var(--fill-2); overflow: hidden; }
.bar > i { display: block; height: 100%; width: var(--v, 50%); background: var(--navy); border-radius: inherit; }
.bar--lime > i { background: var(--lime); }

/* ---------- فرم ---------- */
.field + .field { margin-top: 16px; }
.label { display: flex; justify-content: space-between; font-size: 13px; font-weight: 700; margin-bottom: 8px; }
.label span { font-weight: 400; color: var(--ink-3); }
.input, .textarea, .select {
  width: 100%; height: 46px; padding: 0 14px; border-radius: 12px;
  background: var(--mist); border: 1.5px solid transparent; font-size: 14px; outline: 0;
}
.textarea { height: auto; min-height: 110px; padding: 12px 14px; line-height: 1.8; resize: vertical; }
.input:focus, .textarea:focus, .select:focus { border-color: var(--navy); background: var(--white); }
.input--ltr { direction: ltr; text-align: left; }
.hint { font-size: 12px; color: var(--ink-3); margin-top: 6px; }
.input-unit { display: flex; align-items: center; background: var(--mist); border-radius: 12px; border: 1.5px solid transparent; }
.input-unit:focus-within { border-color: var(--navy); background: var(--white); }
.input-unit .input { background: transparent; border: 0; }
.input-unit span { padding: 0 14px; color: var(--ink-3); font-size: 13px; white-space: nowrap; }

.switch { position: relative; width: 44px; height: 26px; flex: none; display: inline-block; }
.switch input { position: absolute; inset: 0; opacity: 0; margin: 0; cursor: pointer; z-index: 1; }
.switch span { position: absolute; inset: 0; border-radius: 99px; background: var(--fill-2); transition: background .15s; }
.switch span::after { content: ""; position: absolute; top: 3px; inset-inline-start: 3px; width: 20px; height: 20px; border-radius: 50%; background: var(--white); box-shadow: 0 1px 4px rgba(12,18,48,.25); transition: inset-inline-start .2s var(--ease), background .2s; }
.switch input:checked + span { background: var(--navy); }
.switch input:checked + span::after { inset-inline-start: 21px; background: var(--lime); }
.switch input:focus-visible + span { outline: 2.5px solid var(--navy); outline-offset: 2px; }

.setting { display: flex; align-items: center; gap: 14px; padding: 14px 0; }
.setting + .setting { border-top: 1px solid var(--line); }
.setting__body { flex: 1; min-width: 0; }
.setting__body b { font-size: 14px; display: block; }
.setting__body small { font-size: 12.5px; color: var(--ink-3); }
.setting .input, .setting .input-unit { width: 150px; flex: none; }

.kv { display: grid; grid-template-columns: 130px 1fr; row-gap: 14px; font-size: 14px; }
.kv dt { color: var(--ink-3); }
.kv dd { margin: 0; font-weight: 500; display: flex; align-items: center; gap: 8px; }

.priority li { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border-radius: 14px; background: var(--mist); }
.priority li + li { margin-top: 8px; }
.priority .grip { color: var(--ink-4); cursor: grab; }
.priority .n { width: 26px; height: 26px; border-radius: 8px; background: var(--navy); color: var(--lime); display: grid; place-items: center; font-weight: 800; font-size: 12px; }

/* ---------- دراور جزئیات ---------- */
.scrim { position: absolute; inset: 0; z-index: 40; background: rgba(12, 18, 48, .28); opacity: 0; pointer-events: none; transition: opacity .2s; }
.scrim.is-on { opacity: 1; pointer-events: auto; }
.drawer {
  position: absolute; top: 12px; bottom: 12px; inset-inline-end: 12px; z-index: 50;
  width: 430px; max-width: calc(100% - 24px);
  background: var(--white); border-radius: 26px;
  box-shadow: var(--shadow-lg);
  display: flex; flex-direction: column;
  transform: translateX(calc(-100% - 24px)); transition: transform .3s var(--ease);
}
[dir="ltr"] .drawer { transform: translateX(calc(100% + 24px)); }
.drawer.is-on { transform: none; }
.drawer__head { display: flex; align-items: center; gap: 14px; padding: 26px 26px 0; }
.drawer__head h2 { font-size: 26px; font-weight: 800; line-height: 1.3; flex: 1; min-width: 0; }
.drawer__body { flex: 1; overflow-y: auto; padding: 20px 26px 26px; }
.drawer__foot { display: flex; gap: 10px; padding: 16px 26px 22px; border-top: 1px solid var(--line); }
.drawer__foot .btn { flex: 1; }
.doc-preview {
  position: relative; height: 200px; border-radius: 18px; overflow: hidden;
  background: var(--mist); display: grid; place-items: center; margin: 20px 0;
}
.doc-preview .paper { position: absolute; inset: 18px 36px; background: var(--white); border-radius: 10px; box-shadow: var(--shadow); padding: 18px; }
.doc-preview .paper i { display: block; height: 7px; border-radius: 4px; background: var(--fill-2); margin-bottom: 10px; }
.doc-preview .paper i.hl { background: rgba(214,244,61,.6); width: 60%; }
.doc-preview .eye { position: relative; width: 60px; height: 60px; border-radius: 50%; background: rgba(12,18,48,.82); color: var(--white); display: grid; place-items: center; }
.d-sec { margin-top: 22px; }
.d-sec > h4 { font-size: 13px; font-weight: 700; color: var(--ink-3); margin-bottom: 10px; }
.timeline li { position: relative; padding-inline-start: 22px; padding-bottom: 14px; font-size: 13.5px; }
.timeline li::before { content: ""; position: absolute; inset-inline-start: 2px; top: 8px; width: 9px; height: 9px; border-radius: 50%; background: var(--navy); }
.timeline li::after { content: ""; position: absolute; inset-inline-start: 6px; top: 20px; bottom: -2px; width: 1.5px; background: var(--line-2); }
.timeline li:last-child::after { display: none; }
.timeline li.is-now::before { background: var(--lime); box-shadow: 0 0 0 2px var(--navy); }
.timeline small { display: block; color: var(--ink-3); font-size: 12px; }

/* ---------- تقویم سانس باشگاه ---------- */
.cal-wrap { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 20px; align-items: start; }
.cal { border-radius: 18px; box-shadow: 0 0 0 1px var(--line); overflow: hidden; user-select: none; }
.cal table { width: 100%; border-collapse: separate; border-spacing: 0; table-layout: fixed; }
.cal th { background: var(--mist); padding: 10px 6px; font-size: 12px; font-weight: 700; color: var(--ink-3); cursor: pointer; }
.cal th b { display: block; font-size: 18px; font-weight: 900; color: var(--ink); line-height: 1.2; }
.cal th.is-today b { display: inline-grid; place-items: center; min-width: 32px; height: 32px; border-radius: 10px; background: var(--navy); color: var(--lime); }
.cal th:first-child { width: 74px; cursor: default; }
.cal td { padding: 3px; border-top: 1px solid var(--line); }
.cal td.time { font-size: 12px; font-weight: 700; color: var(--ink-3); text-align: center; }
.cal td.time small { display: block; font-weight: 400; font-size: 10.5px; }
.slot {
  width: 100%; height: 46px; border-radius: 10px; display: flex; flex-direction: column; justify-content: center; align-items: flex-start;
  padding: 0 10px; font-size: 11.5px; line-height: 1.35; text-align: start; overflow: hidden;
  background: var(--white); box-shadow: inset 0 0 0 1.5px var(--line); color: var(--ink-3);
  transition: background .1s, box-shadow .1s;
}
.slot b { font-weight: 700; color: var(--ink); font-size: 12px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 100%; }
.slot:hover { box-shadow: inset 0 0 0 1.5px var(--navy); }
.slot--peak { background: linear-gradient(var(--white), var(--white)) padding-box; box-shadow: inset 0 0 0 1.5px var(--line), inset 0 -3px 0 var(--lime); }
.slot--closed { background: repeating-linear-gradient(-45deg, #E3E7EF 0 5px, #EEF1F6 5px 10px); box-shadow: none; color: var(--ink-3); }
.slot--booked { background: var(--navy); color: var(--on-dark-2); box-shadow: none; }
.slot--booked b { color: var(--white); }
.slot--pending { background: rgba(214, 244, 61, .5); box-shadow: inset 0 0 0 1.5px var(--navy); color: var(--ink-2); }
.slot--past { opacity: .45; pointer-events: none; }
.legend { display: flex; gap: 18px; font-size: 12.5px; color: var(--ink-2); flex-wrap: wrap; }
.legend i { display: inline-block; width: 14px; height: 14px; border-radius: 4px; vertical-align: -2px; margin-inline-end: 6px; }

/* ---------- پیش‌نمایش موبایل (دستیار، صفحهٔ باشگاه) ---------- */
.phone-prev { width: 300px; margin: 0 auto; border-radius: 40px; padding: 9px; background: #05070F; box-shadow: var(--shadow); }
.phone-prev > div { border-radius: 32px; overflow: hidden; background: var(--mist); height: 560px; display: flex; flex-direction: column; }
.pp-head { display: flex; align-items: center; justify-content: center; height: 54px; font-size: 13.5px; font-weight: 700; border-bottom: 1px solid var(--line); background: var(--white); }
.pp-body { flex: 1; overflow: hidden; padding: 14px; display: flex; flex-direction: column; gap: 10px; font-size: 12.5px; line-height: 1.75; }
.bub { max-width: 86%; padding: 9px 12px; border-radius: 16px 16px 16px 5px; background: var(--white); box-shadow: 0 1px 2px rgba(12,18,48,.06); }
.bub--me { margin-inline-start: auto; background: var(--navy); color: var(--white); border-radius: 16px 16px 5px 16px; }
.pp-card { display: flex; gap: 10px; align-items: center; background: var(--white); border-radius: 14px; padding: 8px; }
.pp-card i { width: 40px; height: 40px; border-radius: 10px; background: #E6EAF2; display: grid; place-items: center; flex: none; }
.pp-input { display: flex; gap: 8px; padding: 10px; background: var(--white); border-top: 1px solid var(--line); }
.pp-input span { flex: 1; height: 36px; border-radius: 99px; background: var(--mist); display: flex; align-items: center; padding: 0 12px; color: var(--ink-3); font-size: 12px; }
.pp-input b { width: 36px; height: 36px; border-radius: 50%; background: var(--navy); color: var(--lime); display: grid; place-items: center; }

.product { display: flex; flex-direction: column; border-radius: 20px; box-shadow: 0 0 0 1px var(--line); overflow: hidden; }
.product__img { height: 150px; background: #E6EAF2; display: grid; place-items: center; position: relative; }
.product__img svg { width: 46%; height: 70%; }
.product__img .tag { position: absolute; top: 12px; inset-inline-start: 12px; }
.product__body { padding: 14px 16px 16px; }
.product__body b { display: block; font-size: 14.5px; }
.product__meta { display: flex; justify-content: space-between; align-items: center; margin-top: 10px; font-size: 12.5px; color: var(--ink-3); }

/* ---------- توست ---------- */
.toast {
  position: fixed; bottom: 28px; inset-inline-start: 50%; translate: 50% 0; z-index: 99;
  display: flex; align-items: center; gap: 10px; padding: 12px 18px 12px 14px; border-radius: 16px;
  background: var(--navy); color: var(--white); font-weight: 700; font-size: 14px; box-shadow: var(--shadow-lg);
  opacity: 0; transform: translateY(16px); transition: opacity .2s, transform .3s var(--ease); pointer-events: none;
}
.toast.is-on { opacity: 1; transform: none; }
.toast i { width: 26px; height: 26px; border-radius: 50%; background: var(--lime); color: var(--navy); display: grid; place-items: center; }

/* ---------- واکنش‌گرا ---------- */
.menu-btn { display: none; }
@media (max-width: 1280px) {
  .g-5 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .cal-wrap { grid-template-columns: 1fr; }
}
@media (max-width: 1020px) {
  .shell { grid-template-columns: 1fr; }
  .side { position: fixed; inset-block: 0; inset-inline-start: 0; width: var(--side-w); z-index: 80; background: var(--navy); transform: translateX(110%); transition: transform .25s var(--ease); }
  .shell.side-open .side { transform: none; }
  .main { padding: 8px; }
  .menu-btn { display: grid; }
  .g-main, .g-4, .g-3 { grid-template-columns: 1fr 1fr; }
  .search { width: 180px; }
}
@media (max-width: 680px) {
  .ph { flex-wrap: wrap; padding: 18px 18px 0; }
  .ph__actions { width: 100%; }
  .search { flex: 1; width: auto; }
  .toolbar, .vbody { padding-inline: 18px; }
  .board { padding-inline: 18px; }
  .g-main, .g-4, .g-3, .g-2, .g-5 { grid-template-columns: 1fr; }
  .drawer { width: auto; inset-inline-start: 12px; }
  .panel { border-radius: 20px; }
}
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { transition: none !important; animation: none !important; } }

/* ---------- کمکی‌ها ---------- */
.mt { margin-top: 16px !important; }
.hint { display: block; }
.between { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.row-gap { display: flex; align-items: center; gap: 10px; }
[data-panels] > [data-panel] { display: none; }
[data-panels] > [data-panel].is-on { display: block; }
.board .dropzone { display: none; }
.board.is-dragging .dropzone { display: grid; }
.kcard[hidden] { display: none; }
.svc { display: flex; flex-direction: column; gap: 12px; text-align: start; cursor: pointer; transition: box-shadow .15s; }
.svc:hover { box-shadow: 0 0 0 1px var(--line-2), var(--shadow); }
.svc__head { display: flex; align-items: center; gap: 12px; }
.svc__head .type-ico { width: 44px; height: 44px; border-radius: 14px; }
.svc__head b { font-size: 15.5px; display: block; }
.svc__head small { font-size: 12.5px; color: var(--ink-3); }
.svc p { font-size: 13.5px; color: var(--ink-2); min-height: 44px; }
.svc__foot { display: flex; align-items: center; gap: 10px; padding-top: 12px; border-top: 1px solid var(--line); font-size: 12.5px; color: var(--ink-3); }
.svc__foot .btn { margin-inline-start: auto; }
.secret { display: flex; gap: 8px; }
.secret .input { flex: 1; }
.log { font-family: ui-monospace, Menlo, monospace; direction: ltr; text-align: left; font-size: 12px; line-height: 1.9; background: var(--navy); color: #C9CEDF; border-radius: 14px; padding: 12px 14px; }
.log b { color: var(--lime); font-weight: 400; }
.score { display: grid; grid-template-columns: 1fr repeat(3, 40px); gap: 6px; align-items: center; padding: 8px 0; font-weight: 700; }
.score + .score { border-top: 1px solid var(--dark-line); }
.score span:not(:first-child) { text-align: center; font-size: 20px; font-weight: 900; color: var(--on-dark-2); }
.score span.w { color: var(--lime); }
.vars { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 8px; }
.vars button { font-size: 12px; padding: 3px 9px; border-radius: 8px; background: var(--mist); color: var(--ink-2); }
.input-unit .input { flex: 1; min-width: 0; width: auto !important; }
/* کلیدها، آدرس‌ها و کدها با رقم لاتین */
.input--ltr, .log { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 13px; letter-spacing: 0; }

/* ---------- دادهٔ زنده ---------- */
[hidden] { display: none !important; }
.live-dash { margin-bottom: 16px; box-shadow: inset 0 0 0 2px var(--lime, #D6F43D); }
.live-dash .feed a small { display: block; }
tr.is-live td:first-child, tr.is-live td:nth-child(2) { position: relative; }
tr.is-live > td:first-child { box-shadow: inset -3px 0 0 var(--lime, #D6F43D); }
.kcard.is-live { box-shadow: inset 0 0 0 2px var(--lime, #D6F43D); }
.live-dash .card__head { flex-wrap: wrap; gap: 8px; }
.live-dash .card__head .status { white-space: normal; line-height: 1.6; }
.live-dash .between { flex-wrap: wrap; gap: 8px; }
@media (max-width: 760px) { .live-dash .grid.g-5 { grid-template-columns: 1fr 1fr; } .live-dash .stat__num { font-size: 22px !important; } }

/* ---------- ورود به پنل ---------- */
.auth { display: none; position: fixed; inset: 0; z-index: 100; place-items: center; padding: 24px 16px; overflow-y: auto;
  background: radial-gradient(120% 80% at 50% 0%, var(--navy-3) 0%, var(--navy) 60%); }
html:not(.is-authed) .auth { display: grid; }
html:not(.is-authed) .shell { visibility: hidden; }
.auth__card { width: 100%; max-width: 380px; background: var(--white); border-radius: var(--r-xl); padding: 32px 28px 28px; box-shadow: 0 30px 80px rgba(0, 0, 0, .35); }
.auth__logo { height: 34px; width: auto; display: block; margin-bottom: 26px; }
.auth h1 { font-size: 21px; font-weight: 800; margin: 0; }
.auth__sub { font-size: 13px; color: var(--ink-3); margin: 6px 0 24px; }
.auth__pass { padding-inline-end: 4px; }
.auth__pass .input { flex: 1; min-width: 0; }
.auth__eye { width: 38px; height: 38px; border-radius: 10px; display: grid; place-items: center; color: var(--ink-3); flex: none; }
.auth__eye:hover, .auth__eye[aria-pressed="true"] { color: var(--ink); background: var(--fill-2); }
.auth__err { margin: 14px 0 0; padding: 10px 12px; border-radius: 10px; background: var(--danger-fill); color: var(--danger); font-size: 13px; font-weight: 700; }
.auth__go { margin-top: 22px; }
.auth__go:disabled { opacity: .6; }
.auth__warn { margin: 12px 0 0; padding: 9px 12px; border-radius: 10px; background: rgba(214, 244, 61, .35); color: var(--navy); font-size: 12.5px; font-weight: 700; }
