/* ============================================================
   کلاب‌اسپیس — لایهٔ هم‌راستا با پوستهٔ کانون
   بعد از shell.css و clubspace.css بارگذاری می‌شود.
   ============================================================ */

/* صفحات در نسخهٔ سروری همیشه نمایان‌اند (دمو همه را پنهان می‌کرد) */
.cs-app .page{display:block}
.cs-app .cs-main{min-height:62vh}

/* دکمهٔ تم */
[data-k-theme-toggle]{display:inline-grid;place-items:center}
[data-k-theme-toggle] .k-moon{display:none}
html[data-theme="dark"] [data-k-theme-toggle] .k-moon{display:block}
html[data-theme="dark"] [data-k-theme-toggle] .k-sun{display:none}

/* ---------- پیام‌های سیستمی ---------- */
.alert{
  display:flex;align-items:flex-start;gap:9px;
  border-radius:12px;border:1px solid var(--line);
  background:var(--paper-2);color:var(--ink-2);
  padding:12px 14px;font-size:13px;line-height:1.8;margin-bottom:16px;
}
.alert::before{content:"";width:8px;height:8px;border-radius:50%;background:var(--ink-3);margin-top:8px;flex:none}
.alert--success{border-color:#BFDCCD;background:var(--ok-bg);color:var(--ok)}
.alert--success::before{background:var(--ok)}
.alert--error{border-color:#E5C3C3;background:var(--bad-bg);color:var(--bad)}
.alert--error::before{background:var(--bad)}
.alert--warning{border-color:#EBD4B4;background:var(--warn-bg);color:var(--warn)}
.alert--warning::before{background:var(--warn)}

/* ---------- گام‌های فرم ---------- */
.cs-steps{display:flex;gap:8px;flex-wrap:wrap;align-items:center;margin-bottom:18px}
.cs-steps li{
  display:inline-flex;align-items:center;gap:6px;font-size:12px;font-weight:600;color:var(--ink-3);
  border:1px solid var(--line);border-radius:var(--r-pill);padding:4px 10px;background:var(--surface);
}
.cs-steps li span{width:18px;height:18px;border-radius:50%;display:grid;place-items:center;background:#EAE5DB;font-size:10.5px;color:var(--ink-2)}
.cs-steps li.is-current{border-color:var(--accent);color:var(--accent-ink)}
.cs-steps li.is-current span{background:var(--accent);color:#fff}
.cs-steps li.is-done{color:var(--ok);border-color:#BFDCCD}
.cs-steps li.is-done span{background:var(--ok);color:#fff}

/* ---------- فرم‌های صفحه‌ای ---------- */
.form-card{max-width:620px}
.form-card + .form-card{margin-top:16px}
.form-actions{display:flex;align-items:center;gap:10px;flex-wrap:wrap;margin-top:6px}
.auth-wrap{max-width:460px;margin-inline:auto;padding-block:clamp(28px,6vw,64px)}
.auth-wrap .card{padding:clamp(22px,4vw,32px)}
.auth-alt{text-align:center;font-size:12.5px;color:var(--ink-3);margin-top:14px}

/* سوییچ به شکل چک‌باکس (بدون نیاز به JS) */
input.switch{
  appearance:none;-webkit-appearance:none;flex:none;width:46px;height:26px;border-radius:var(--r-pill);
  border:1px solid var(--line);background:#EAE5DB;position:relative;cursor:pointer;margin:0;
  transition:background .18s var(--ease),border-color .18s var(--ease);
}
input.switch::after{
  content:"";position:absolute;top:2px;inset-inline-start:2px;width:20px;height:20px;border-radius:50%;
  background:#fff;box-shadow:0 1px 2px rgba(10,34,71,.25);transition:inset-inline-start .18s var(--ease);
}
input.switch:checked{background:var(--ink);border-color:var(--ink)}
input.switch:checked::after{inset-inline-start:22px}

/* جدول‌های مدیریتی */
.tbl td .btn{min-height:30px;padding:0 10px;font-size:12px}
.tbl .row{gap:6px;flex-wrap:nowrap}
.tbl select{min-width:96px}

/* نوار رزرو */
.reserve-grid{display:grid;grid-template-columns:1fr 1fr;gap:12px}
@media (max-width:680px){.reserve-grid{grid-template-columns:1fr}}

/* کارت‌های داشبورد/مدیریت */
.mini-list{display:grid;gap:0}
.mini-list a{
  display:flex;align-items:center;justify-content:space-between;gap:8px;
  padding:9px 0;border-bottom:1px solid var(--line-2);font-size:13px;
}
.mini-list a:last-child{border-bottom:0}
.mini-list a:hover{color:var(--accent-ink)}
.mini-list .ico{width:15px;height:15px;color:var(--ink-3)}

/* وضعیت اتاق */
.room-live-note{font-size:11.5px;color:#8FA3C0;text-align:center;margin-top:10px}
.room-page .chip{background:#10294A;border-color:#24405F;color:#DCE5F1}
.room-page .empty{background:#0C2140;border-color:#24405F;color:#DCE5F1}
.room-page .empty h3{color:#EAF0F8}
.room-page .empty p{color:#9EB0CC}

/* غلبه بر رنگ‌های ثابت دمو در تم تاریک */
html[data-theme="dark"] body{background:#0b1220;color:#e7edf6}
html[data-theme="dark"]{
  --paper:#0b1220;--paper-2:#111a2c;--surface:#111a2c;
  --ink:#eef2f8;--ink-2:#c3cfdf;--ink-3:#93a3ba;
  --line:#233246;--line-2:#1b2839;
  --accent:#3b82f6;--accent-ink:#8ab4ff;
  --ok-bg:#123125;--warn-bg:#33260f;--bad-bg:#3a1a1e;
}
html[data-theme="dark"] .tag{background:#1b2839}
html[data-theme="dark"] .tag--live{background:#3a1a1e}
html[data-theme="dark"] .chip:hover,
html[data-theme="dark"] .btn--ghost:hover,
html[data-theme="dark"] .icon-btn:hover,
html[data-theme="dark"] .admin-nav button:hover,
html[data-theme="dark"] .stepper button:hover{background:#1b2839;border-color:#2c3d56}
html[data-theme="dark"] .club:hover{border-color:#33445c}
html[data-theme="dark"] .rules .rn,
html[data-theme="dark"] .venue .off{background:#1b2839;color:#dbe4f1}
html[data-theme="dark"] .cs-steps li span{background:#233246}
html[data-theme="dark"] .input.switch,
html[data-theme="dark"] input.switch{background:#233246}
html[data-theme="dark"] .notice--accent{border-color:#274063;background:#12203a}
html[data-theme="dark"] .empty{border-color:#33445c}
html[data-theme="dark"] .field.is-invalid .inp,
html[data-theme="dark"] .field.is-invalid .ta,
html[data-theme="dark"] .field.is-invalid .sel{border-color:#7d3b3b;background:#2a1720}
html[data-theme="dark"] .err-summary{border-color:#5a2b2b;background:#2a1720;color:#f0b4b4}
html[data-theme="dark"] .toast{background:#e8eef7;color:#0b1220}
html[data-theme="dark"] .ring-art circle{stroke:#22314a}
html[data-theme="dark"] .ring-art path{stroke:#8ab4ff;stroke-opacity:.35}
html[data-theme="dark"] .ring-prog circle:first-child{stroke:#243247}
html[data-theme="dark"] .ring-prog circle:last-child{stroke:#8ab4ff}
html[data-theme="dark"] .search input::placeholder{color:#7d8ba1}
html[data-theme="dark"] .stepline i{background:#233246}
html[data-theme="dark"] .skipplink{background:#e8eef7;color:#0b1220}
html[data-theme="dark"] .band{background:#060b15}
html[data-theme="dark"] .card--ink{background:#060b15;border-color:#1d3559}

/* صفحهٔ احراز هویت و پیام‌ها */
html[data-theme="dark"] .auth-wrap .card{background:#111a2c}
