/**
 * FitRonix — داشبورد کاربری · بازطراحی مدرن مینیمال v2
 * پالت: Primary #2563EB · Accent #F97316 · Dark #0F172A · Gray 100/200/300 · White
 * ─────────────────────────────────────────────────────────────────────────────
 * این فایل آخرین CSS لود می‌شود و بالاترین اولویت را دارد
 */

/* ══════════════════════════════════════════════════
   DESIGN TOKENS
══════════════════════════════════════════════════ */
:root,
html[data-user-panel-theme="fitronix"],
html[data-user-panel-theme="firouzi"] {
  --dp: #2563EB;          /* primary blue */
  --dp-dark: #1d4ed8;
  --dp-soft: #eff6ff;
  --dp-muted: rgba(37,99,235,.10);

  --da: #F97316;          /* accent orange */
  --da-dark: #ea6c10;
  --da-muted: rgba(249,115,22,.10);

  --dn: #0F172A;          /* dark navy — text */
  --ds2: #475569;         /* secondary text */
  --ds3: #94a3b8;         /* tertiary / hints */

  --g100: #F1F5F9;        /* page bg */
  --g200: #E2E8F0;        /* icon bg / divider */
  --g300: #CBD5E1;        /* border */
  --dw:   #FFFFFF;        /* card surface */

  --ok:  #10b981;
  --ok-m: rgba(16,185,129,.10);
  --err: #ef4444;
  --err-m: rgba(239,68,68,.10);

  --card-r: 16px;
  --card-r-sm: 12px;
  --card-r-pill: 999px;
  --card-r-ico: 10px;
  --card-pad: 20px;
  --card-pad-sm: 16px;
  --card-sh: 0 1px 2px rgba(15,23,42,.04), 0 4px 16px rgba(15,23,42,.04);
  --card-sh-hover: 0 2px 8px rgba(15,23,42,.06), 0 8px 24px rgba(15,23,42,.07);
  --dash-gap: 16px;
}

/* dark mode overrides */
html[data-user-panel-theme="fitronix"][data-theme="dark"],
html[data-user-panel-theme="firouzi"][data-theme="dark"] {
  --g100: #0F172A;
  --g200: #E2E8F0;
  --g300: #CBD5E1;
  --dw:   color-mix(in srgb, #F1F5F9 7%, #0F172A);
  --dn:   #F1F5F9;
  --ds2:  #E2E8F0;
  --ds3:  #CBD5E1;
  --dp-soft: color-mix(in srgb, #2563EB 14%, transparent);
  --dp-muted: color-mix(in srgb, #2563EB 16%, transparent);
  --da-muted: color-mix(in srgb, #F97316 14%, transparent);
  --card-sh: 0 2px 8px rgba(15,23,42,.35), inset 0 1px 0 color-mix(in srgb, #F1F5F9 6%, transparent);
  --card-sh-hover: 0 4px 16px rgba(15,23,42,.45);
}

/* ══════════════════════════════════════════════════
   PAGE BACKGROUND
══════════════════════════════════════════════════ */
html[data-user-panel-theme="fitronix"]:not([data-theme="dark"])
  .shell-user .main:has(#view-dashboard.active),
html[data-user-panel-theme="firouzi"]:not([data-theme="dark"])
  .shell-user .main:has(#view-dashboard.active) {
  background: var(--g100) !important;
}

html[data-user-panel-theme="fitronix"]:not([data-theme="dark"]) #view-dashboard,
html[data-user-panel-theme="firouzi"]:not([data-theme="dark"]) #view-dashboard {
  color: var(--dn);
}

/* ══════════════════════════════════════════════════
   DASHBOARD LAYOUT — DESKTOP
══════════════════════════════════════════════════ */
@media (min-width: 881px) {
  html[data-user-panel-theme="fitronix"]
    .shell-user .main:has(#view-dashboard.active),
  html[data-user-panel-theme="firouzi"]
    .shell-user .main:has(#view-dashboard.active) {
    padding: 24px 24px 0 !important;
    box-sizing: border-box;
    overflow-x: clip;
  }
}

html[data-user-panel-theme="fitronix"]
  .shell-user .main:has(#view-dashboard.active) > .header,
html[data-user-panel-theme="fitronix"]
  .shell-user .main:has(#view-dashboard.active) > .content,
html[data-user-panel-theme="firouzi"]
  .shell-user .main:has(#view-dashboard.active) > .header,
html[data-user-panel-theme="firouzi"]
  .shell-user .main:has(#view-dashboard.active) > .content {
  width: 100% !important;
  max-width: none !important;
  margin-inline: 0 !important;
  padding-inline: 0 !important;
  box-sizing: border-box;
}

html[data-user-panel-theme="fitronix"]
  .shell-user .main:has(#view-dashboard.active) .content,
html[data-user-panel-theme="firouzi"]
  .shell-user .main:has(#view-dashboard.active) .content {
  width: 100% !important;
  max-width: none !important;
  padding: 0 !important;
}

html[data-user-panel-theme="fitronix"] #view-dashboard,
html[data-user-panel-theme="firouzi"] #view-dashboard {
  width: 100% !important;
  max-width: none !important;
  margin-inline: 0 !important;
  padding: 0 !important;
  box-sizing: border-box;
}

/* GRID — ۱۲ ستون + اندازه ویجت */
html[data-user-panel-theme="fitronix"]
  #view-dashboard .fx-dash[data-dash-sortable="fx-main"],
html[data-user-panel-theme="firouzi"]
  #view-dashboard .fx-dash[data-dash-sortable="fx-main"] {
  display: grid !important;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: var(--dash-gap);
  width: 100% !important;
  max-width: none !important;
  min-width: 0;
  box-sizing: border-box;
  align-items: start;
  padding-bottom: 24px;
}

/* پایه فرزندان مستقیم */
html[data-user-panel-theme="fitronix"]
  #view-dashboard .fx-dash[data-dash-sortable="fx-main"] > [data-dash-sort-key],
html[data-user-panel-theme="firouzi"]
  #view-dashboard .fx-dash[data-dash-sortable="fx-main"] > [data-dash-sort-key],
html[data-user-panel-theme="fitronix"]
  #view-dashboard .fx-dash[data-dash-sortable="fx-main"] > .fx-hw-standalone,
html[data-user-panel-theme="firouzi"]
  #view-dashboard .fx-dash[data-dash-sortable="fx-main"] > .fx-hw-standalone,
html[data-user-panel-theme="fitronix"]
  #view-dashboard .fx-dash[data-dash-sortable="fx-main"] > .fx-customize,
html[data-user-panel-theme="firouzi"]
  #view-dashboard .fx-dash[data-dash-sortable="fx-main"] > .fx-customize {
  position: relative;
  min-width: 0;
  max-width: 100%;
  box-sizing: border-box;
}

/* پیش‌فرض: تمام‌عرض */
html[data-user-panel-theme="fitronix"]
  #view-dashboard .fx-dash[data-dash-sortable="fx-main"] > [data-dash-sort-key]:not([class*="dash-widget-size-"]),
html[data-user-panel-theme="firouzi"]
  #view-dashboard .fx-dash[data-dash-sortable="fx-main"] > [data-dash-sort-key]:not([class*="dash-widget-size-"]),
html[data-user-panel-theme="fitronix"]
  #view-dashboard .fx-dash[data-dash-sortable="fx-main"] > .fx-hw-standalone:not([class*="dash-widget-size-"]),
html[data-user-panel-theme="firouzi"]
  #view-dashboard .fx-dash[data-dash-sortable="fx-main"] > .fx-hw-standalone:not([class*="dash-widget-size-"]) {
  grid-column: 1 / -1;
}

html[data-user-panel-theme="fitronix"]
  #view-dashboard .fx-dash[data-dash-sortable="fx-main"] > .fx-customize,
html[data-user-panel-theme="firouzi"]
  #view-dashboard .fx-dash[data-dash-sortable="fx-main"] > .fx-customize {
  grid-column: 1 / -1;
}

/* اندازه‌ها — کلیک دکمه اندازه در ویجت */
html[data-user-panel-theme="fitronix"]
  #view-dashboard .fx-dash[data-dash-sortable="fx-main"] > .dash-widget-size-full,
html[data-user-panel-theme="firouzi"]
  #view-dashboard .fx-dash[data-dash-sortable="fx-main"] > .dash-widget-size-full,
html[data-user-panel-theme="fitronix"]
  #view-dashboard .fx-dash [data-dash-sortable] > .dash-widget-size-full,
html[data-user-panel-theme="firouzi"]
  #view-dashboard .fx-dash [data-dash-sortable] > .dash-widget-size-full {
  grid-column: 1 / -1 !important;
}

html[data-user-panel-theme="fitronix"]
  #view-dashboard .fx-dash[data-dash-sortable="fx-main"] > .dash-widget-size-half,
html[data-user-panel-theme="firouzi"]
  #view-dashboard .fx-dash[data-dash-sortable="fx-main"] > .dash-widget-size-half,
html[data-user-panel-theme="fitronix"]
  #view-dashboard .fx-dash [data-dash-sortable] > .dash-widget-size-half,
html[data-user-panel-theme="firouzi"]
  #view-dashboard .fx-dash [data-dash-sortable] > .dash-widget-size-half {
  grid-column: span 6 !important;
}

html[data-user-panel-theme="fitronix"]
  #view-dashboard .fx-dash[data-dash-sortable="fx-main"] > .dash-widget-size-two-thirds,
html[data-user-panel-theme="firouzi"]
  #view-dashboard .fx-dash[data-dash-sortable="fx-main"] > .dash-widget-size-two-thirds,
html[data-user-panel-theme="fitronix"]
  #view-dashboard .fx-dash [data-dash-sortable] > .dash-widget-size-two-thirds,
html[data-user-panel-theme="firouzi"]
  #view-dashboard .fx-dash [data-dash-sortable] > .dash-widget-size-two-thirds {
  grid-column: span 8 !important;
}

html[data-user-panel-theme="fitronix"]
  #view-dashboard .fx-dash[data-dash-sortable="fx-main"] > .dash-widget-size-third,
html[data-user-panel-theme="firouzi"]
  #view-dashboard .fx-dash[data-dash-sortable="fx-main"] > .dash-widget-size-third,
html[data-user-panel-theme="fitronix"]
  #view-dashboard .fx-dash [data-dash-sortable] > .dash-widget-size-third,
html[data-user-panel-theme="firouzi"]
  #view-dashboard .fx-dash [data-dash-sortable] > .dash-widget-size-third {
  grid-column: span 4 !important;
}

html[data-user-panel-theme="fitronix"]
  #view-dashboard .fx-dash[data-dash-sortable="fx-main"] > .dash-widget-size-quarter,
html[data-user-panel-theme="firouzi"]
  #view-dashboard .fx-dash[data-dash-sortable="fx-main"] > .dash-widget-size-quarter,
html[data-user-panel-theme="fitronix"]
  #view-dashboard .fx-dash [data-dash-sortable] > .dash-widget-size-quarter,
html[data-user-panel-theme="firouzi"]
  #view-dashboard .fx-dash [data-dash-sortable] > .dash-widget-size-quarter {
  grid-column: span 3 !important;
}

/* ردیف‌های تو در تو — گرید ۱۲ ستونی داخلی */
html[data-user-panel-theme="fitronix"]
  #view-dashboard .fx-dash [data-dash-sortable="fx-quick"],
html[data-user-panel-theme="firouzi"]
  #view-dashboard .fx-dash [data-dash-sortable="fx-quick"],
html[data-user-panel-theme="fitronix"]
  #view-dashboard .fx-dash [data-dash-sortable="fx-ops"],
html[data-user-panel-theme="firouzi"]
  #view-dashboard .fx-dash [data-dash-sortable="fx-ops"],
html[data-user-panel-theme="fitronix"]
  #view-dashboard .fx-dash [data-dash-sortable="fx-bottom"],
html[data-user-panel-theme="firouzi"]
  #view-dashboard .fx-dash [data-dash-sortable="fx-bottom"] {
  display: grid !important;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: var(--dash-gap);
  align-items: stretch;
}

@media (max-width: 1100px) {
  html[data-user-panel-theme="fitronix"]
    #view-dashboard .fx-dash[data-dash-sortable="fx-main"] > .dash-widget-size-third,
  html[data-user-panel-theme="firouzi"]
    #view-dashboard .fx-dash[data-dash-sortable="fx-main"] > .dash-widget-size-third,
  html[data-user-panel-theme="fitronix"]
    #view-dashboard .fx-dash[data-dash-sortable="fx-main"] > .dash-widget-size-two-thirds,
  html[data-user-panel-theme="firouzi"]
    #view-dashboard .fx-dash[data-dash-sortable="fx-main"] > .dash-widget-size-two-thirds,
  html[data-user-panel-theme="fitronix"]
    #view-dashboard .fx-dash[data-dash-sortable="fx-main"] > .dash-widget-size-quarter,
  html[data-user-panel-theme="firouzi"]
    #view-dashboard .fx-dash[data-dash-sortable="fx-main"] > .dash-widget-size-quarter,
  html[data-user-panel-theme="fitronix"]
    #view-dashboard .fx-dash [data-dash-sortable] > .dash-widget-size-third,
  html[data-user-panel-theme="firouzi"]
    #view-dashboard .fx-dash [data-dash-sortable] > .dash-widget-size-third,
  html[data-user-panel-theme="fitronix"]
    #view-dashboard .fx-dash [data-dash-sortable] > .dash-widget-size-two-thirds,
  html[data-user-panel-theme="firouzi"]
    #view-dashboard .fx-dash [data-dash-sortable] > .dash-widget-size-two-thirds,
  html[data-user-panel-theme="fitronix"]
    #view-dashboard .fx-dash [data-dash-sortable] > .dash-widget-size-quarter,
  html[data-user-panel-theme="firouzi"]
    #view-dashboard .fx-dash [data-dash-sortable] > .dash-widget-size-quarter {
    grid-column: span 6 !important;
  }
}

@media (max-width: 880px) {
  html[data-user-panel-theme="fitronix"]
    #view-dashboard .fx-dash[data-dash-sortable="fx-main"] > .dash-widget-size-half,
  html[data-user-panel-theme="firouzi"]
    #view-dashboard .fx-dash[data-dash-sortable="fx-main"] > .dash-widget-size-half,
  html[data-user-panel-theme="fitronix"]
    #view-dashboard .fx-dash[data-dash-sortable="fx-main"] > .dash-widget-size-two-thirds,
  html[data-user-panel-theme="firouzi"]
    #view-dashboard .fx-dash[data-dash-sortable="fx-main"] > .dash-widget-size-two-thirds,
  html[data-user-panel-theme="fitronix"]
    #view-dashboard .fx-dash[data-dash-sortable="fx-main"] > .dash-widget-size-third,
  html[data-user-panel-theme="firouzi"]
    #view-dashboard .fx-dash[data-dash-sortable="fx-main"] > .dash-widget-size-third,
  html[data-user-panel-theme="fitronix"]
    #view-dashboard .fx-dash[data-dash-sortable="fx-main"] > .dash-widget-size-quarter,
  html[data-user-panel-theme="firouzi"]
    #view-dashboard .fx-dash[data-dash-sortable="fx-main"] > .dash-widget-size-quarter,
  html[data-user-panel-theme="fitronix"]
    #view-dashboard .fx-dash [data-dash-sortable] > .dash-widget-size-half,
  html[data-user-panel-theme="firouzi"]
    #view-dashboard .fx-dash [data-dash-sortable] > .dash-widget-size-half,
  html[data-user-panel-theme="fitronix"]
    #view-dashboard .fx-dash [data-dash-sortable] > .dash-widget-size-two-thirds,
  html[data-user-panel-theme="firouzi"]
    #view-dashboard .fx-dash [data-dash-sortable] > .dash-widget-size-two-thirds,
  html[data-user-panel-theme="fitronix"]
    #view-dashboard .fx-dash [data-dash-sortable] > .dash-widget-size-third,
  html[data-user-panel-theme="firouzi"]
    #view-dashboard .fx-dash [data-dash-sortable] > .dash-widget-size-third,
  html[data-user-panel-theme="fitronix"]
    #view-dashboard .fx-dash [data-dash-sortable] > .dash-widget-size-quarter,
  html[data-user-panel-theme="firouzi"]
    #view-dashboard .fx-dash [data-dash-sortable] > .dash-widget-size-quarter {
    grid-column: 1 / -1 !important;
  }
}

/* فوتر ویجت‌های سلامت */
#view-dashboard .fx-hw-foot {
  display: grid;
  padding: 12px var(--card-pad) !important;
}

#view-dashboard .fx-hw-foot--4 { grid-template-columns: repeat(4, 1fr) !important; }
#view-dashboard .fx-hw-foot--macros { grid-template-columns: repeat(3, 1fr) !important; }

#view-dashboard .fx-hw-foot-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
  padding: 8px 4px;
  text-align: center;
  border-inline-end: 1px solid var(--g200);
}

#view-dashboard .fx-hw-foot-item:last-child { border-inline-end: none !important; }

/* ══════════════════════════════════════════════════
   BASE CARD — همه ویجت‌ها
══════════════════════════════════════════════════ */
#view-dashboard .fx-card:not(.fx-greet-tasks),
#view-dashboard .fx-hw-standalone,
#view-dashboard .fx-hw,
#view-dashboard .fx-score-card,
#view-dashboard .fx-panel-card,
#view-dashboard .fx-weekly-card,
#view-dashboard .fx-body-card,
#view-dashboard .fx-body-comp,
#view-dashboard .fx-programs-section {
  background: var(--dw) !important;
  border: 1px solid var(--g300) !important;
  border-radius: var(--card-r) !important;
  box-shadow: var(--card-sh) !important;
  box-sizing: border-box;
  overflow: hidden;
  transition: border-color .18s, box-shadow .18s;
}

#view-dashboard .fx-card:not(.fx-greet-tasks):hover,
#view-dashboard .fx-hw-standalone:hover,
#view-dashboard .fx-score-card:hover,
#view-dashboard .fx-panel-card:hover,
#view-dashboard .fx-weekly-card:hover {
  border-color: color-mix(in srgb, var(--dp) 28%, var(--g300)) !important;
  box-shadow: var(--card-sh-hover) !important;
  transform: none !important;
}

/* روکردهای کارت برای layout */
#view-dashboard .fx-card:not(.fx-greet-tasks),
#view-dashboard .fx-hw-standalone,
#view-dashboard .fx-panel-card,
#view-dashboard .fx-weekly-card,
#view-dashboard .fx-body-card,
#view-dashboard .fx-body-comp,
#view-dashboard .fx-programs-section {
  display: flex;
  flex-direction: column;
}

/* غیر-کارت ردیف‌ها */
#view-dashboard .fx-score-row,
#view-dashboard .fx-quick-row,
#view-dashboard .fx-ops-row,
#view-dashboard .fx-bottom-row {
  background: transparent !important;
  border: none !important;
  box-shadow: none !important;
  border-radius: 0 !important;
  gap: var(--dash-gap) !important;
}

/* حذف pseudo-element های قدیمی */
#view-dashboard .fx-hw::after,
#view-dashboard .fx-hw-standalone::after { display: none !important; }

/* ══════════════════════════════════════════════════
   CARD HEADER — هدر مشترک همه ویجت‌ها
══════════════════════════════════════════════════ */
#view-dashboard .fx-card-head,
#view-dashboard .fx-panel-head,
#view-dashboard .fx-weekly-head,
#view-dashboard .fx-ops-head,
#view-dashboard .fx-body-card-head,
#view-dashboard .fx-programs-head {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: var(--card-pad) var(--card-pad) 14px !important;
  border-bottom: 1px solid var(--g200) !important;
  background: transparent !important;
}

#view-dashboard .fx-hw-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: var(--card-pad) var(--card-pad) 14px !important;
  border-bottom: 1px solid var(--g200) !important;
  background: transparent !important;
}

#view-dashboard .fx-card-head h3,
#view-dashboard .fx-panel-head h3,
#view-dashboard .fx-weekly-head h3,
#view-dashboard .fx-hw-head h3,
#view-dashboard .fx-ops-head h3,
#view-dashboard .fx-programs-section h3,
#view-dashboard .fx-body-card-head-copy h3 {
  font-size: 13px !important;
  font-weight: 600 !important;
  color: var(--dn) !important;
  letter-spacing: -0.01em;
  margin: 0;
  line-height: 1.3;
}

/* آیکون هدر */
#view-dashboard .fx-widget-head-ico,
#view-dashboard .fx-hw-ico,
#view-dashboard .fx-ops-ico,
#view-dashboard .fx-streak-flame,
#view-dashboard .fx-body-seg-ico,
#view-dashboard .fx-activity-ico,
#view-dashboard .fx-programs-head-ico {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  flex-shrink: 0;
  width: 32px !important;
  height: 32px !important;
  border-radius: var(--card-r-ico) !important;
  background: var(--g200) !important;
  color: var(--dp) !important;
  border: none !important;
}

#view-dashboard .fx-widget-head-ico svg,
#view-dashboard .fx-hw-ico svg,
#view-dashboard .fx-ops-ico svg,
#view-dashboard .fx-activity-ico svg,
#view-dashboard .fx-body-seg-ico svg {
  width: 16px;
  height: 16px;
}

/* streak flame → accent */
#view-dashboard .fx-streak-flame,
#view-dashboard .fx-widget-head-ico--sub {
  background: var(--da-muted) !important;
  color: var(--da) !important;
}

/* لینک هدر */
#view-dashboard .fx-panel-head-link,
#view-dashboard .fx-panel-head a,
#view-dashboard .fx-body-card-head-link {
  font-size: 11px;
  font-weight: 500;
  color: var(--dp);
  text-decoration: none;
  margin-inline-start: auto;
  white-space: nowrap;
}

/* ══════════════════════════════════════════════════
   PROGRESS RING
══════════════════════════════════════════════════ */
#view-dashboard .fx-hw-ring svg,
#view-dashboard .fx-score-ring svg {
  transform: rotate(-90deg);
  display: block;
}

#view-dashboard .fx-hw-ring .fx-ring-bg,
#view-dashboard .fx-score-ring .fx-ring-bg {
  fill: none;
  stroke: var(--g200) !important;
  stroke-width: 6 !important;
}

#view-dashboard .fx-hw-ring .fx-ring-fg,
#view-dashboard .fx-score-ring .fx-ring-fg {
  fill: none;
  stroke: var(--dp) !important;
  stroke-width: 6 !important;
  stroke-linecap: round;
  transition: stroke-dashoffset .6s cubic-bezier(.4,0,.2,1);
}

#view-dashboard .fx-hw--workout .fx-ring-fg { stroke: var(--da) !important; }

#view-dashboard .fx-hw-ring-center,
#view-dashboard .fx-score-ring-center {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  pointer-events: none;
}

#view-dashboard .fx-hw-ring-center strong {
  font-size: 17px !important;
  font-weight: 700 !important;
  color: var(--dn) !important;
  line-height: 1.1;
}

#view-dashboard .fx-hw--workout .fx-hw-ring-center strong { color: var(--da) !important; }
#view-dashboard .fx-hw--nutrition .fx-hw-ring-center strong { color: var(--dp) !important; }

#view-dashboard .fx-hw-ring-center small {
  font-size: 10px !important;
  color: var(--ds3) !important;
  margin-top: 2px;
}

/* ══════════════════════════════════════════════════
   NESTED BOXES — باکس‌های داخلی
══════════════════════════════════════════════════ */
#view-dashboard .fx-hw-workout-kpi,
#view-dashboard .fx-hw-nutrition-pills li,
#view-dashboard .fx-hw-stats--pair li,
#view-dashboard .fx-hw-recovery-tile,
#view-dashboard .fx-sleep-metric,
#view-dashboard .fx-hw-macro,
#view-dashboard .fx-ops-tile,
#view-dashboard .fx-body-seg,
#view-dashboard .fx-hw-workout-chart,
#view-dashboard .fx-hw-chart-host,
#view-dashboard .fx-weekly-summary,
#view-dashboard .fx-weekly-chart {
  background: var(--g100) !important;
  border: 1px solid var(--g200) !important;
  border-radius: var(--card-r-sm) !important;
}

/* progress bars */
#view-dashboard .fx-hw-macro-bar,
#view-dashboard .fx-level-bar,
#view-dashboard .fx-sub-bar,
#view-dashboard .fx-hw-ready-track {
  height: 5px;
  border-radius: var(--card-r-pill);
  background: var(--g200) !important;
  overflow: hidden;
}

#view-dashboard .fx-hw-macro-bar i,
#view-dashboard .fx-hw-macro-bar span,
#view-dashboard .fx-level-bar span {
  display: block;
  height: 100%;
  border-radius: var(--card-r-pill);
  background: var(--dp) !important;
}

#view-dashboard .fx-sub-bar span {
  display: block;
  height: 100%;
  border-radius: var(--card-r-pill);
  background: var(--dp) !important;
}

#view-dashboard .fx-hw-ready-track span {
  display: block;
  height: 100%;
  border-radius: var(--card-r-pill);
  background: var(--ok) !important;
}

/* ══════════════════════════════════════════════════
   TYPOGRAPHY GLOBALS
══════════════════════════════════════════════════ */
#view-dashboard .fx-hw-foot-item strong,
#view-dashboard .fx-score-val,
#view-dashboard .fx-streak-days strong,
#view-dashboard .fx-streak-days,
#view-dashboard .fx-body-seg .val,
#view-dashboard .fx-hw-stat-val,
#view-dashboard .fx-ops-badge,
#view-dashboard .fx-ops-status {
  font-size: 18px !important;
  font-weight: 700 !important;
  color: var(--dn) !important;
  line-height: 1.2;
}

#view-dashboard .fx-hw-foot-item > span:last-child,
#view-dashboard .fx-score-lbl,
#view-dashboard .fx-streak-label,
#view-dashboard .fx-body-seg .lbl,
#view-dashboard .fx-ops-text,
#view-dashboard .fx-water-count,
#view-dashboard .fx-hw-workout-chart-head,
#view-dashboard .fx-hw-workout-chart-head small,
#view-dashboard .fx-hw-workout-chart-head span,
#view-dashboard .fx-hw-monitor-meta .lbl,
#view-dashboard .fx-hw-recovery-tile .lbl,
#view-dashboard .fx-sleep-metric .lbl {
  font-size: 11px !important;
  color: var(--ds3) !important;
}

#view-dashboard .fx-activity-body strong {
  font-size: 13px !important;
  font-weight: 600 !important;
  color: var(--dn) !important;
}

#view-dashboard .fx-activity-body span {
  font-size: 11px !important;
  color: var(--ds3) !important;
}

/* ══════════════════════════════════════════════════
   BUTTONS
══════════════════════════════════════════════════ */
#view-dashboard .fx-water-btn,
#view-dashboard .fx-sub-btn:not(.fx-sub-btn--ghost),
#view-dashboard .fx-sleep-cta:not(.fx-hw-chart-empty-btn),
#view-dashboard .fx-promo-cta,
#view-dashboard .fx-hw-chart-empty-btn {
  border-radius: var(--card-r-pill) !important;
  padding: 9px 18px !important;
  font-size: 12px !important;
  font-weight: 600 !important;
  background: var(--dp) !important;
  color: var(--dw) !important;
  border: none !important;
  cursor: pointer;
  transition: filter .15s;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
}

#view-dashboard .fx-water-btn:hover,
#view-dashboard .fx-sub-btn:not(.fx-sub-btn--ghost):hover,
#view-dashboard .fx-sleep-cta:hover,
#view-dashboard .fx-promo-cta:hover,
#view-dashboard .fx-hw-chart-empty-btn:hover {
  filter: brightness(1.06);
  transform: none !important;
}

#view-dashboard .fx-water-btn--ghost,
#view-dashboard .fx-sub-btn--ghost,
#view-dashboard .fx-btn-outline {
  border-radius: var(--card-r-sm) !important;
  padding: 9px 16px !important;
  font-size: 12px !important;
  font-weight: 500 !important;
  background: transparent !important;
  color: var(--ds2) !important;
  border: 1px solid var(--g300) !important;
  cursor: pointer;
  transition: border-color .15s, color .15s;
}

#view-dashboard .fx-water-btn--ghost:hover,
#view-dashboard .fx-sub-btn--ghost:hover,
#view-dashboard .fx-btn-outline:hover {
  border-color: var(--dp) !important;
  color: var(--dp) !important;
  transform: none !important;
}

/* ══════════════════════════════════════════════════
   RING WRAP
══════════════════════════════════════════════════ */
#view-dashboard .fx-hw-ring-wrap {
  position: relative;
  display: inline-flex;
  flex-shrink: 0;
}

#view-dashboard .fx-hw-ring-wrap--lg {
  width: 110px;
  height: 110px;
}

#view-dashboard .fx-hw-ring-wrap--lg .fx-hw-ring,
#view-dashboard .fx-hw-ring-wrap--lg .fx-score-ring {
  width: 110px;
  height: 110px;
}

#view-dashboard .fx-hw-ring-wrap--lg .fx-hw-ring svg,
#view-dashboard .fx-hw-ring-wrap--lg .fx-score-ring svg {
  width: 110px;
  height: 110px;
}

/* ══════════════════════════════════════════════════
   HEALTH WIDGET INNER LAYOUTS
══════════════════════════════════════════════════ */
/* تمرین */
#view-dashboard .fx-hw-body--workout {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

#view-dashboard .fx-hw-workout-main {
  display: flex;
  align-items: center;
  gap: 16px;
}

#view-dashboard .fx-hw-workout-side {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

#view-dashboard .fx-hw-workout-kpi {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

#view-dashboard .fx-hw-workout-chart-wrap { width: 100%; }

/* تغذیه */
#view-dashboard .fx-hw-body--nutrition {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

#view-dashboard .fx-hw-nutrition-main {
  display: flex;
  align-items: center;
  gap: 16px;
}

#view-dashboard .fx-hw-nutrition-pills { flex: 1; }

/* خواب */
#view-dashboard .fx-hw-body--sleep,
#view-dashboard .fx-sleep-shell {
  padding: 0 !important;
}

/* ریکاوری */
#view-dashboard .fx-hw-body--recovery {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

#view-dashboard .fx-hw-recovery-top {
  display: flex;
  align-items: center;
  gap: 16px;
}

/* ══════════════════════════════════════════════════
   ویجت خوش‌آمدگویی (GREET v3)
══════════════════════════════════════════════════ */
#view-dashboard .fx-greet-v3.fx-dash-greet,
#view-dashboard .fx-greet-v3.up-dash-greet {
  padding: var(--card-pad) !important;
  background: var(--dw) !important;
  border: 1px solid var(--g300) !important;
  border-radius: var(--card-r) !important;
  box-shadow: var(--card-sh) !important;
  overflow: hidden;
  grid-column: 1 / -1 !important;
}

#view-dashboard .fx-greet-v3 .up-dash-greet-stripe { display: none !important; }

#view-dashboard .fx-greet-v3 .fx-greet-layout {
  display: grid;
  grid-template-columns: 180px 1fr 300px;
  gap: 24px;
  align-items: start;
  width: 100%;
}

/* آواتار */
#view-dashboard .fx-greet-v3 .up-dash-greet-portrait {
  width: 180px;
  position: relative;
}

#view-dashboard .fx-greet-v3 .up-dash-greet-portrait::before {
  content: '';
  position: absolute;
  inset: -4px;
  border-radius: 50%;
  background: conic-gradient(from 200deg, var(--dp), #60a5fa, var(--g300), var(--dp));
  opacity: 0.2;
  z-index: 0;
}

#view-dashboard .fx-greet-v3 .up-dash-greet-avatar {
  position: relative;
  z-index: 1;
  width: 148px !important;
  height: 148px !important;
  border-radius: 50%;
  overflow: hidden;
  border: 3px solid var(--dw) !important;
  box-shadow: 0 8px 24px rgba(37,99,235,.12) !important;
  background: var(--g100) !important;
  margin: 0 auto;
  display: block;
}

#view-dashboard .fx-greet-v3 .up-dash-greet-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* بالای اطلاعات */
#view-dashboard .fx-greet-v3 .fx-greet-topline {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 8px;
}

#view-dashboard .fx-greet-v3 .up-dash-greet-eyebrow {
  font-size: 11px !important;
  font-weight: 600 !important;
  color: var(--ds3) !important;
  letter-spacing: .04em;
  text-transform: uppercase;
  margin: 0;
}

#view-dashboard .fx-greet-v3 .up-dual-red { color: var(--da) !important; }
#view-dashboard .fx-greet-v3 .up-dual-navy { color: var(--dn) !important; }

/* تاریخ pill */
#view-dashboard .fx-greet-v3 .fx-greet-date,
#view-dashboard .fx-greet-v3 .up-dash-pill--date {
  font-size: 11px !important;
  font-weight: 500 !important;
  padding: 4px 10px !important;
  border-radius: var(--card-r-pill) !important;
  background: var(--g100) !important;
  border: 1px solid var(--g200) !important;
  color: var(--ds2) !important;
  margin-inline-start: auto;
}

/* نام کاربر */
#view-dashboard .fx-greet-v3 .up-dash-greet-name-row {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 4px;
}

#view-dashboard .fx-greet-v3 .up-dash-greet-name-row h2 {
  font-size: clamp(1.25rem, 2vw, 1.5rem) !important;
  font-weight: 700 !important;
  color: var(--dn) !important;
  margin: 0;
  letter-spacing: -0.02em;
}

#view-dashboard .fx-greet-v3 .fx-verified {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: var(--dp) !important;
  flex-shrink: 0;
}

#view-dashboard .fx-greet-v3 .fx-badge-member {
  font-size: 11px;
  font-weight: 600;
  padding: 3px 9px;
  border-radius: var(--card-r-pill);
  background: var(--da-muted) !important;
  color: var(--da) !important;
  border: 1px solid color-mix(in srgb, var(--da) 20%, transparent);
}

#view-dashboard .fx-greet-v3 .fx-greet-expiry,
#view-dashboard .fx-greet-v3 .up-dash-greet-expiry {
  font-size: 11px;
  color: var(--ds3);
  margin: 4px 0 0;
}

#view-dashboard .fx-greet-v3 .up-dash-greet-sub {
  font-size: 13px;
  color: var(--ds2);
  margin: 6px 0 0;
}

/* آمار بدنی */
#view-dashboard .fx-greet-v3 .fx-greet-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  margin-top: 16px;
}

#view-dashboard .fx-greet-v3 .fx-greet-stat {
  padding: 10px 8px !important;
  border-radius: var(--card-r-sm) !important;
  border: 1px solid var(--g200) !important;
  background: var(--g100) !important;
  text-align: center;
}

#view-dashboard .fx-greet-v3 .fx-greet-stat .lbl {
  display: block;
  font-size: 10px;
  font-weight: 500;
  color: var(--ds3);
  margin-bottom: 3px;
}

#view-dashboard .fx-greet-v3 .fx-greet-stat .val {
  font-size: 13px !important;
  font-weight: 700 !important;
  color: var(--dn) !important;
}

/* toolbar دکمه‌ها */
#view-dashboard .fx-greet-v3 .fx-greet-toolbar {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 14px;
}

#view-dashboard .fx-greet-v3 .fx-profile-icon-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  border-radius: var(--card-r-ico) !important;
  border: 1px solid var(--g300) !important;
  background: var(--dw) !important;
  color: var(--ds2) !important;
  cursor: pointer;
  transition: border-color .15s, background .15s, color .15s;
}

#view-dashboard .fx-greet-v3 .fx-profile-icon-btn:hover {
  border-color: var(--dp) !important;
  background: var(--dp-soft) !important;
  color: var(--dp) !important;
}

#view-dashboard .fx-greet-v3 .fx-greet-edit-btn {
  padding: 9px 16px !important;
  border-radius: var(--card-r-pill) !important;
  background: var(--dp) !important;
  color: var(--dw) !important;
  border: none !important;
  font-size: 12px !important;
  font-weight: 600 !important;
  cursor: pointer;
  transition: filter .15s;
}

#view-dashboard .fx-greet-v3 .fx-greet-edit-btn:hover { filter: brightness(1.07); }

/* پنل کارهای امروز */
#view-dashboard .fx-greet-v3 .fx-greet-tasks {
  padding: 16px !important;
  border-radius: var(--card-r-sm) !important;
  border: 1px solid var(--g200) !important;
  background: var(--g100) !important;
  box-shadow: none !important;
  min-height: 100%;
}

#view-dashboard .fx-greet-v3 .fx-greet-tasks-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 10px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--g200) !important;
}

#view-dashboard .fx-greet-v3 .fx-greet-tasks-head h3 {
  font-size: 13px !important;
  font-weight: 600 !important;
  color: var(--dn) !important;
  margin: 0;
}

#view-dashboard .fx-greet-v3 .fx-tasks-prog {
  font-size: 11px;
  font-weight: 600;
  padding: 2px 8px;
  border-radius: var(--card-r-pill);
  background: var(--dp-muted);
  color: var(--dp);
}

#view-dashboard .fx-greet-v3 .fx-tasks-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
  max-height: 220px;
  overflow-y: auto;
}

#view-dashboard .fx-greet-v3 .fx-task {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 7px 8px;
  border-radius: var(--card-r-ico);
  transition: background .15s;
}

#view-dashboard .fx-greet-v3 .fx-task:hover { background: var(--dw) !important; }

#view-dashboard .fx-greet-v3 .fx-task-check {
  width: 17px;
  height: 17px;
  border-radius: 5px;
  border: 1.5px solid var(--g300);
  background: var(--dw);
  display: grid;
  place-items: center;
  cursor: pointer;
  flex-shrink: 0;
  transition: background .15s, border-color .15s;
}

#view-dashboard .fx-greet-v3 .fx-task.is-done .fx-task-check {
  background: var(--dp) !important;
  border-color: var(--dp) !important;
  color: var(--dw);
}

#view-dashboard .fx-greet-v3 .fx-task-text {
  font-size: 12px;
  color: var(--dn);
}

#view-dashboard .fx-greet-v3 .fx-task.is-done .fx-task-text {
  text-decoration: line-through;
  color: var(--ds3);
}

/* ══════════════════════════════════════════════════
   برنامه‌های من
══════════════════════════════════════════════════ */
#view-dashboard .fx-programs-section {
  padding: var(--card-pad) !important;
  grid-column: 1 / -1 !important;
}

#view-dashboard .fx-programs-head {
  padding: 0 0 14px !important;
  margin-bottom: 14px !important;
  border-bottom: 1px solid var(--g200) !important;
  border-top: none !important;
  background: transparent !important;
}

#view-dashboard .fx-programs-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 320px), 1fr));
  gap: 12px;
  width: 100%;
}

#view-dashboard .fx-program-card {
  background: var(--g100) !important;
  border: 1px solid var(--g200) !important;
  border-radius: var(--card-r-sm) !important;
  box-shadow: none !important;
  overflow: hidden;
  transition: border-color .18s, box-shadow .18s;
}

#view-dashboard .fx-program-card:hover {
  border-color: color-mix(in srgb, var(--dp) 30%, var(--g200)) !important;
  box-shadow: var(--card-sh) !important;
  transform: none !important;
}

#view-dashboard .fx-program-card--wp .fx-program-thumb { background: color-mix(in srgb, var(--da) 10%, var(--g100)) !important; }
#view-dashboard .fx-program-card--np .fx-program-thumb { background: color-mix(in srgb, var(--dp) 10%, var(--g100)) !important; }

#view-dashboard .fx-program-type { font-size: 11px; font-weight: 600; }
#view-dashboard .fx-program-card--wp .fx-program-type { color: var(--da) !important; }
#view-dashboard .fx-program-card--np .fx-program-type { color: var(--dp) !important; }

#view-dashboard .fx-program-content strong {
  font-size: 14px;
  font-weight: 700;
  color: var(--dn);
}

#view-dashboard .fx-program-meta { font-size: 11px; color: var(--ds3); }

#view-dashboard .fx-program-progress {
  height: 4px;
  border-radius: var(--card-r-pill);
  background: var(--g200) !important;
}

#view-dashboard .fx-program-card--wp .fx-program-progress i {
  background: var(--da) !important;
  border-radius: var(--card-r-pill);
}

#view-dashboard .fx-program-card--np .fx-program-progress i {
  background: var(--dp) !important;
  border-radius: var(--card-r-pill);
}

#view-dashboard .fx-program-card--wp .fx-program-progress-row span { color: var(--da) !important; font-size: 11px; font-weight: 600; }
#view-dashboard .fx-program-card--np .fx-program-progress-row span { color: var(--dp) !important; font-size: 11px; font-weight: 600; }

#view-dashboard .fx-program-btn {
  border-radius: var(--card-r-pill) !important;
  padding: 8px 16px !important;
  font-size: 12px !important;
  font-weight: 600 !important;
  border: none !important;
  color: var(--dw) !important;
  cursor: pointer;
}

#view-dashboard .fx-program-card--wp .fx-program-btn { background: var(--da) !important; }
#view-dashboard .fx-program-card--np .fx-program-btn { background: var(--dp) !important; }

#view-dashboard .fx-program-btn:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

#view-dashboard .fx-program-ghost {
  background: var(--dw, #fff) !important;
  border: 1px solid var(--g200) !important;
  border-radius: var(--card-r-sm) !important;
  box-shadow: none !important;
}

#view-dashboard .fx-program-ghost:hover {
  box-shadow: var(--card-sh) !important;
}

#view-dashboard .fx-program-ghost--wp:hover {
  border-color: color-mix(in srgb, var(--da) 35%, var(--g200)) !important;
  background: color-mix(in srgb, var(--da) 3%, var(--dw)) !important;
}

#view-dashboard .fx-program-ghost--np:hover {
  border-color: color-mix(in srgb, var(--dp) 35%, var(--g200)) !important;
  background: color-mix(in srgb, var(--dp) 3%, var(--dw)) !important;
}

#view-dashboard .fx-program-ghost--wp .fx-program-ghost-type { color: var(--da) !important; }
#view-dashboard .fx-program-ghost--np .fx-program-ghost-type { color: var(--dp) !important; }
#view-dashboard .fx-program-ghost-title { color: var(--dn); }
#view-dashboard .fx-program-ghost-hint { color: var(--ds3); }
#view-dashboard .fx-program-ghost--wp .fx-program-ghost-ico { background: color-mix(in srgb, var(--da) 12%, var(--g100)) !important; }
#view-dashboard .fx-program-ghost--np .fx-program-ghost-ico { background: color-mix(in srgb, var(--dp) 12%, var(--g100)) !important; }
#view-dashboard .fx-program-ghost--wp:hover .fx-program-ghost-cta { color: var(--da) !important; }
#view-dashboard .fx-program-ghost--wp:hover .fx-program-ghost-arrow { color: var(--da) !important; }
#view-dashboard .fx-program-ghost--np:hover .fx-program-ghost-cta { color: var(--dp) !important; }
#view-dashboard .fx-program-ghost--np:hover .fx-program-ghost-arrow { color: var(--dp) !important; }

#view-dashboard .fx-program-expired {
  background: var(--dw, #fff) !important;
  border: 1px solid var(--g200) !important;
  border-radius: var(--card-r-sm) !important;
  box-shadow: none !important;
}
#view-dashboard .fx-program-expired--wp .fx-program-expired-type { color: var(--da) !important; }
#view-dashboard .fx-program-expired--np .fx-program-expired-type { color: var(--dp) !important; }
#view-dashboard .fx-program-expired--wp .fx-program-expired-ico { background: color-mix(in srgb, var(--da) 12%, var(--g100)) !important; }
#view-dashboard .fx-program-expired--np .fx-program-expired-ico { background: color-mix(in srgb, var(--dp) 12%, var(--g100)) !important; }
#view-dashboard .fx-program-expired-title { color: var(--dn); }
#view-dashboard .fx-program-expired-hint { color: var(--ds3); }
#view-dashboard .fx-program-expired-badge { background: var(--g100) !important; border-color: var(--g200) !important; color: var(--ds3); }
#view-dashboard .fx-program-expired-btn--wp { background: var(--da) !important; color: var(--dw) !important; }
#view-dashboard .fx-program-expired-btn--np { background: var(--dp) !important; color: var(--dw) !important; }
#view-dashboard .fx-program-expired-btn--ghost { border-color: var(--g200) !important; color: var(--ds3); }

/* ══════════════════════════════════════════════════
   دسترسی سریع + آب
══════════════════════════════════════════════════ */
#view-dashboard .fx-quick-row[data-dash-sortable="fx-quick"] {
  display: grid !important;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: var(--dash-gap);
  align-items: stretch;
}

#view-dashboard .fx-quick-row:not([data-dash-sortable]) {
  display: grid;
  grid-template-columns: 1fr 220px;
  gap: var(--dash-gap);
  align-items: stretch;
}

#view-dashboard .fx-quick-card {
  padding: var(--card-pad) !important;
}

#view-dashboard .fx-quick-grid {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 8px !important;
  margin-top: 14px;
}

#view-dashboard .fx-quick-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  padding: 14px 8px !important;
  border-radius: var(--card-r-sm) !important;
  background: var(--g100) !important;
  border: 1px solid transparent !important;
  font-size: 11.5px !important;
  font-weight: 500 !important;
  color: var(--ds2);
  cursor: pointer;
  transition: background .15s, border-color .15s, color .15s;
  -webkit-tap-highlight-color: transparent;
}

#view-dashboard .fx-quick-btn:hover {
  background: var(--dp-muted) !important;
  border-color: color-mix(in srgb, var(--dp) 18%, transparent) !important;
  color: var(--dn);
  transform: none !important;
  box-shadow: none !important;
}

#view-dashboard .fx-quick-ico {
  width: 36px !important;
  height: 36px !important;
  border-radius: var(--card-r-ico) !important;
  display: grid;
  place-items: center;
}

#view-dashboard .fx-quick-ico--blue  { background: var(--da-muted) !important; color: var(--da) !important; }
#view-dashboard .fx-quick-ico--green,
#view-dashboard .fx-quick-ico--orange,
#view-dashboard .fx-quick-ico--purple,
#view-dashboard .fx-quick-ico--pink,
#view-dashboard .fx-quick-ico--teal  { background: var(--dp-muted) !important; color: var(--dp) !important; }

#view-dashboard .fx-quick-ico svg { width: 17px; height: 17px; }

/* آب امروز */
#view-dashboard .fx-water-card {
  padding: var(--card-pad) !important;
}

#view-dashboard .fx-card-head:has(+ .fx-water-cups),
#view-dashboard .fx-water-card .fx-card-head {
  padding-bottom: 12px !important;
  margin-bottom: 12px !important;
}

#view-dashboard .fx-water-count {
  font-size: 11px;
  color: var(--ds3);
  margin-inline-start: auto;
}

#view-dashboard .fx-water-count strong {
  font-size: 15px;
  font-weight: 700;
  color: var(--dp);
}

#view-dashboard .fx-water-cups {
  display: flex;
  flex-wrap: wrap;
  gap: 5px !important;
  margin: 0 0 12px !important;
}

#view-dashboard .fx-water-cup {
  flex: 1;
  min-width: 20px;
  height: 26px !important;
  border-radius: 6px !important;
  border: 1.5px solid var(--g300) !important;
  background: transparent !important;
  cursor: pointer;
  transition: background .15s, border-color .15s;
}

#view-dashboard .fx-water-cup.is-full {
  background: var(--dp) !important;
  border-color: var(--dp) !important;
}

#view-dashboard .fx-water-actions {
  display: flex;
  gap: 8px;
  margin-top: auto;
}

#view-dashboard .fx-water-btn {
  flex: 1;
  padding: 9px 12px !important;
  font-size: 12px !important;
}

/* ══════════════════════════════════════════════════
   ویجت‌های سلامت (fx-hw)
══════════════════════════════════════════════════ */
#view-dashboard .fx-hw {
  overflow: hidden;
}

#view-dashboard .fx-hw-head-main {
  display: flex;
  align-items: center;
  gap: 10px;
  flex: 1;
}

/* رنگ آیکون هر ویجت */
#view-dashboard .fx-hw--workout  .fx-hw-ico { background: var(--da-muted) !important; color: var(--da) !important; }
#view-dashboard .fx-hw--nutrition .fx-hw-ico { background: var(--dp-muted) !important; color: var(--dp) !important; }
#view-dashboard .fx-hw--sleep    .fx-hw-ico { background: rgba(99,102,241,.10) !important; color: #6366f1 !important; }
#view-dashboard .fx-hw--recovery .fx-hw-ico { background: rgba(139,92,246,.10) !important; color: #8b5cf6 !important; }
#view-dashboard .fx-hw--monitor  .fx-hw-ico { background: rgba(14,165,233,.10) !important; color: #0ea5e9 !important; }

/* عنوان رنگی */
#view-dashboard .fx-hw--workout  .fx-hw-head h3 { color: var(--da) !important; }
#view-dashboard .fx-hw--nutrition .fx-hw-head h3 { color: var(--dp) !important; }

/* منوی سه‌نقطه */
#view-dashboard .fx-hw-menu {
  width: 28px;
  height: 28px;
  border-radius: 8px;
  opacity: .45;
  transition: opacity .15s, background .15s;
  background: transparent;
  border: none;
  cursor: pointer;
  display: grid;
  place-items: center;
  color: var(--ds2);
}

#view-dashboard .fx-hw-head:hover .fx-hw-menu { opacity: 1; }
#view-dashboard .fx-hw-menu:hover { background: var(--g200) !important; opacity: 1; }

#view-dashboard .fx-hw-menu-pop {
  border: 1px solid var(--g300);
  border-radius: var(--card-r-sm);
  background: var(--dw);
  box-shadow: var(--card-sh-hover);
  overflow: hidden;
}

#view-dashboard .fx-hw-menu-pop button {
  display: block;
  width: 100%;
  padding: 9px 14px;
  font-size: 12px;
  text-align: start;
  background: transparent;
  border: none;
  cursor: pointer;
  color: var(--ds2);
  transition: background .12s, color .12s;
}

#view-dashboard .fx-hw-menu-pop button:hover {
  background: var(--g100);
  color: var(--dn);
}

/* بدنه */
#view-dashboard .fx-hw-body {
  padding: 16px var(--card-pad) !important;
  flex: 1;
}

/* فوتر */
#view-dashboard .fx-hw-foot {
  background: var(--g100) !important;
  border-top: 1px solid var(--g200) !important;
  margin-top: auto;
}

#view-dashboard .fx-hw-foot-item strong {
  font-size: 15px !important;
  font-weight: 700 !important;
}

#view-dashboard .fx-hw-foot-item > span:last-child {
  font-size: 10px !important;
}

/* KPI تمرین */
#view-dashboard .fx-hw-workout-kpi {
  padding: 10px !important;
  gap: 4px !important;
}

#view-dashboard .fx-hw-workout-kpi strong {
  font-size: 15px !important;
  font-weight: 700 !important;
  color: var(--da) !important;
}

/* نمودار */
#view-dashboard .fx-hw-workout-chart,
#view-dashboard .fx-hw-chart-host {
  padding: 8px !important;
  min-height: 100px;
}

#view-dashboard .fx-hw-workout-chart-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 8px;
}

/* حالت خالی نمودار */
#view-dashboard .fx-hw-chart-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  padding: 20px 16px;
  text-align: center;
}

#view-dashboard .fx-hw-chart-empty p { font-size: 12px; color: var(--ds3); margin: 0; }

#view-dashboard .fx-hw-chart-empty-ico svg { width: 28px; height: 28px; color: var(--ds3); }

/* ماکرو */
#view-dashboard .fx-hw-macro {
  padding: 10px 12px !important;
  border-radius: var(--card-r-ico) !important;
}

#view-dashboard .fx-hw-macro .lbl {
  font-size: 10px;
  color: var(--ds3);
}

#view-dashboard .fx-hw-macro strong {
  font-size: 13px !important;
  font-weight: 700 !important;
  color: var(--dn) !important;
}

#view-dashboard .fx-hw-macro-bar {
  height: 3px !important;
  margin-top: 6px;
}

/* آمادگی */
#view-dashboard .fx-hw-ready-bar {
  padding: 8px var(--card-pad);
  background: var(--ok-m) !important;
  border-top: 1px solid var(--g200) !important;
  font-size: 11px;
  color: var(--ds2);
}

/* pills تغذیه */
#view-dashboard .fx-hw-nutrition-pills {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

#view-dashboard .fx-hw-nutrition-pills li {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 10px !important;
}

#view-dashboard .fx-hw-nutrition-pills li .lbl { font-size: 11px; color: var(--ds3); }
#view-dashboard .fx-hw-nutrition-pills li strong { font-size: 13px; font-weight: 700; color: var(--dp); }

/* stats pair */
#view-dashboard .fx-hw-stats--pair {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  gap: 8px;
}

#view-dashboard .fx-hw-stats--pair li {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  padding: 10px 8px !important;
  text-align: center;
}

#view-dashboard .fx-hw-stat-val {
  font-size: 18px !important;
  font-weight: 700 !important;
  color: var(--dn) !important;
}

#view-dashboard .fx-hw-stat-lbl { font-size: 10px !important; color: var(--ds3) !important; }

/* خواب */
#view-dashboard .fx-sleep-shell { flex: 1; display: flex; flex-direction: column; }

#view-dashboard .fx-sleep-pane { flex: 1; display: flex; flex-direction: column; }

#view-dashboard .fx-sleep-empty-art {
  margin-bottom: 12px;
}

#view-dashboard .fx-sleep-empty-art svg {
  width: 56px;
  height: 56px;
  color: var(--ds3);
}

#view-dashboard .fx-sleep-cta {
  margin-top: 8px;
}

#view-dashboard .fx-sleep-pane--empty {
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 24px var(--card-pad);
  text-align: center;
}

#view-dashboard .fx-sleep-pane--empty p { font-size: 12px; color: var(--ds3); margin: 0; }

#view-dashboard .fx-sleep-hero {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 16px var(--card-pad);
}

#view-dashboard .fx-sleep-score {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

#view-dashboard .fx-sleep-score .lbl { font-size: 11px; color: var(--ds3); }
#view-dashboard .fx-sleep-score strong { font-size: 28px; font-weight: 800; color: var(--dn); }

#view-dashboard .fx-sleep-metrics {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
  padding: 0 var(--card-pad) 16px;
}

#view-dashboard .fx-sleep-metric {
  display: flex;
  flex-direction: column;
  gap: 3px;
  padding: 10px !important;
  text-align: center;
}

#view-dashboard .fx-sleep-metric .lbl { font-size: 10px; color: var(--ds3); }
#view-dashboard .fx-sleep-metric strong { font-size: 14px; font-weight: 700; color: var(--dn); }

#view-dashboard .fx-hw-sleep-log-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  padding: 16px var(--card-pad);
}

#view-dashboard .fx-hw-sleep-log-grid label {
  display: flex;
  flex-direction: column;
  gap: 4px;
  font-size: 11px;
  color: var(--ds2);
}

/* ریکاوری */
#view-dashboard .fx-hw-recovery-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
  margin-top: 12px;
}

#view-dashboard .fx-hw-recovery-tile {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 10px !important;
  text-align: center;
}

#view-dashboard .fx-hw-recovery-tile .lbl { font-size: 10px; color: var(--ds3); }
#view-dashboard .fx-hw-recovery-tile strong { font-size: 15px; font-weight: 700; color: var(--dn); }

#view-dashboard .fx-hw-recovery-msg {
  font-size: 12px;
  color: var(--ds2);
  text-align: center;
  margin-top: 10px;
}

#view-dashboard .fx-hw-recovery-trend {
  padding: 12px var(--card-pad);
  background: var(--g100) !important;
  border-top: 1px solid var(--g200) !important;
}

#view-dashboard .fx-hw-recovery-trend-lbl { font-size: 10px; color: var(--ds3); display: block; margin-bottom: 6px; }

/* badge‌های hw */
#view-dashboard .fx-hw-badge {
  font-size: 10px;
  font-weight: 600;
  padding: 2px 7px;
  border-radius: var(--card-r-pill);
}

#view-dashboard .fx-hw-badge--green { background: var(--ok-m); color: var(--ok); }
#view-dashboard .fx-hw-badge--yellow { background: rgba(234,179,8,.12); color: #ca8a04; }
#view-dashboard .fx-hw-badge--red { background: var(--err-m); color: var(--err); }

/* پایش */
#view-dashboard .fx-hw-monitor-body {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  padding: 16px var(--card-pad);
  flex: 1;
}

#view-dashboard .fx-hw-monitor-stats {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

#view-dashboard .fx-hw-monitor-row {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px;
  border-radius: var(--card-r-sm);
  background: var(--g100);
  border: 1px solid var(--g200);
}

#view-dashboard .fx-hw-monitor-ico {
  width: 28px;
  height: 28px;
  border-radius: 8px;
  background: var(--g200);
  display: grid;
  place-items: center;
  color: var(--dp);
  flex-shrink: 0;
}

#view-dashboard .fx-hw-monitor-ico svg { width: 14px; height: 14px; }

#view-dashboard .fx-hw-monitor-meta { flex: 1; }
#view-dashboard .fx-hw-monitor-meta .lbl { font-size: 10px; display: block; }
#view-dashboard .fx-hw-monitor-meta strong { font-size: 14px; font-weight: 700; color: var(--dn); }

#view-dashboard .fx-hw-monitor-delta { font-size: 11px; font-weight: 600; }
#view-dashboard .fx-hw-monitor-delta--down { color: var(--ok); }
#view-dashboard .fx-hw-monitor-delta--up { color: var(--err); }

#view-dashboard .fx-hw-monitor-more {
  display: flex;
  align-items: center;
  gap: 4px;
  justify-content: center;
  margin-top: 4px;
  padding: 8px;
  border-radius: var(--card-r-sm);
  font-size: 12px;
  font-weight: 500;
  color: var(--dp);
  background: transparent;
  border: 1px solid var(--g200);
  cursor: pointer;
  transition: background .15s, border-color .15s;
}

#view-dashboard .fx-hw-monitor-more:hover { background: var(--dp-muted); border-color: color-mix(in srgb, var(--dp) 25%, var(--g200)); }
#view-dashboard .fx-hw-monitor-chart { min-height: 120px; }

/* ══════════════════════════════════════════════════
   امتیازها
══════════════════════════════════════════════════ */
#view-dashboard .fx-score-row {
  display: grid;
  grid-template-columns: 180px repeat(3, 1fr);
  gap: var(--dash-gap);
  align-items: stretch;
}

#view-dashboard .fx-score-card {
  padding: var(--card-pad) !important;
  min-height: 140px;
}

#view-dashboard .fx-score-card--total {
  background: linear-gradient(160deg, var(--dp-soft) 0%, var(--dw) 65%) !important;
  border-color: color-mix(in srgb, var(--dp) 18%, var(--g300)) !important;
}

#view-dashboard .fx-score-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
}

#view-dashboard .fx-score-lbl {
  font-size: 11px !important;
  font-weight: 500;
  color: var(--ds3) !important;
}

#view-dashboard .fx-score-delta {
  font-size: 10px;
  font-weight: 600;
  padding: 2px 7px;
  border-radius: var(--card-r-pill);
  background: var(--ok-m);
  color: var(--ok);
}

#view-dashboard .fx-score-val {
  font-size: 28px !important;
  font-weight: 800 !important;
  color: var(--dn) !important;
  line-height: 1;
  display: flex;
  align-items: baseline;
  gap: 3px;
}

#view-dashboard .fx-score-val small {
  font-size: 11px !important;
  font-weight: 400;
  color: var(--ds3);
}

#view-dashboard .fx-score-ring-wrap { position: relative; display: inline-block; }

#view-dashboard .fx-score-ring-center strong {
  font-size: 22px !important;
  font-weight: 800 !important;
  color: var(--dp) !important;
}

#view-dashboard .fx-score-ring-center small {
  font-size: 10px !important;
  color: var(--ds3) !important;
}

#view-dashboard .fx-sparkline { margin-top: 8px; opacity: .7; }

/* ══════════════════════════════════════════════════
   زنجیره + اشتراک
══════════════════════════════════════════════════ */
#view-dashboard .fx-ops-row[data-dash-sortable="fx-ops"] {
  display: grid !important;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: var(--dash-gap);
  align-items: stretch;
}

#view-dashboard .fx-ops-row:not([data-dash-sortable]) {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--dash-gap);
}

#view-dashboard .fx-streak-card,
#view-dashboard .fx-sub-card {
  padding: var(--card-pad) !important;
}

#view-dashboard .fx-streak-top {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 16px;
}

#view-dashboard .fx-streak-flame {
  width: 40px !important;
  height: 40px !important;
  border-radius: var(--card-r-ico) !important;
  flex-shrink: 0;
}

#view-dashboard .fx-streak-flame svg { width: 20px; height: 20px; }

#view-dashboard .fx-streak-meta { flex: 1; }
#view-dashboard .fx-streak-label { font-size: 11px; color: var(--ds3); display: block; }
#view-dashboard .fx-streak-days { font-size: 16px !important; font-weight: 700 !important; color: var(--dn) !important; }

#view-dashboard .fx-streak-points { text-align: end; margin-inline-start: auto; }
#view-dashboard .fx-streak-points span { font-size: 18px; font-weight: 700; color: var(--dn); display: block; }
#view-dashboard .fx-streak-points small { font-size: 10px; color: var(--ds3); }

#view-dashboard .fx-streak-week {
  display: flex;
  gap: 6px;
  justify-content: space-between;
  margin: 0 0 14px;
}

#view-dashboard .fx-streak-dot {
  flex: 1;
  aspect-ratio: 1;
  max-width: 36px;
  border-radius: var(--card-r-ico) !important;
  display: grid;
  place-items: center;
  font-size: 10px;
  font-weight: 600;
  border: 1px solid var(--g200) !important;
  background: var(--g100) !important;
  color: var(--ds3);
}

#view-dashboard .fx-streak-dot.on {
  background: var(--da-muted) !important;
  border-color: color-mix(in srgb, var(--da) 30%, var(--g200)) !important;
  color: var(--da) !important;
}

#view-dashboard .fx-streak-dot.today {
  box-shadow: 0 0 0 2px color-mix(in srgb, var(--da) 25%, transparent);
}

#view-dashboard .fx-level-head {
  font-size: 11px;
  color: var(--ds3);
  display: flex;
  justify-content: space-between;
  margin-bottom: 6px;
}

#view-dashboard .fx-level-bar {
  height: 5px;
}

#view-dashboard .fx-level-bar span {
  background: linear-gradient(90deg, var(--da), #fb923c) !important;
}

/* اشتراک */
#view-dashboard .fx-sub-plan {
  font-size: 11px;
  font-weight: 600;
  padding: 3px 10px;
  border-radius: var(--card-r-pill);
  background: var(--da-muted);
  color: var(--da);
  margin-inline-start: auto;
}

#view-dashboard .fx-sub-info { margin: 14px 0; }

#view-dashboard .fx-sub-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 12px;
  color: var(--ds2);
  margin-bottom: 8px;
}

#view-dashboard .fx-sub-row b { font-weight: 700; color: var(--dn); }

#view-dashboard .fx-sub-bar { height: 5px; margin-bottom: 4px; }

#view-dashboard .fx-sub-actions { display: flex; gap: 8px; }
#view-dashboard .fx-sub-btn { flex: 1; }

/* ══════════════════════════════════════════════════
   فعالیت‌های اخیر
══════════════════════════════════════════════════ */
#view-dashboard .fx-panel-card {
  padding: var(--card-pad) !important;
}

#view-dashboard .fx-panel-head {
  padding-bottom: 14px !important;
  margin-bottom: 0;
}

#view-dashboard .fx-panel-head-title {
  display: flex;
  align-items: center;
  gap: 10px;
  flex: 1;
}

#view-dashboard .fx-activities-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  flex: 1;
}

#view-dashboard .fx-activity-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 11px 0 !important;
  border-bottom: 1px solid var(--g200) !important;
  transition: background .12s;
  border-radius: 0;
}

#view-dashboard .fx-activity-item:last-child { border-bottom: none !important; }

#view-dashboard .fx-activity-item:hover {
  background: var(--g100) !important;
  border-radius: var(--card-r-sm);
  padding-inline: 8px !important;
}

#view-dashboard .fx-activity-ico {
  width: 32px !important;
  height: 32px !important;
  border-radius: var(--card-r-ico) !important;
  flex-shrink: 0;
}

#view-dashboard .fx-activity-body { flex: 1; min-width: 0; }

/* ══════════════════════════════════════════════════
   وضعیت حساب
══════════════════════════════════════════════════ */
#view-dashboard .fx-ops-card {
  padding: var(--card-pad) !important;
}

#view-dashboard .fx-ops-head { padding-bottom: 14px !important; }
#view-dashboard .fx-ops-head-main { display: flex; align-items: center; gap: 10px; flex: 1; }

#view-dashboard .fx-status-badge {
  font-size: 10px;
  font-weight: 600;
  padding: 3px 9px;
  border-radius: var(--card-r-pill);
  background: var(--ok-m);
  color: var(--ok);
  margin-inline-start: auto;
}

#view-dashboard .fx-ops-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
  margin-top: 14px;
}

#view-dashboard .fx-ops-tile {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 8px;
  padding: 14px !important;
  border-radius: var(--card-r-sm) !important;
  border: 1px solid var(--g200) !important;
  background: var(--g100) !important;
  cursor: pointer;
  text-align: start;
  transition: border-color .15s, background .15s;
}

#view-dashboard .fx-ops-tile:hover {
  border-color: color-mix(in srgb, var(--dp) 28%, var(--g200)) !important;
  background: var(--dp-muted) !important;
  transform: none !important;
}

#view-dashboard .fx-ops-ico {
  width: 30px !important;
  height: 30px !important;
  border-radius: 9px !important;
}

#view-dashboard .fx-ops-ico svg { width: 15px; height: 15px; }

#view-dashboard .fx-ops-text {
  font-size: 11px !important;
  color: var(--ds2) !important;
}

#view-dashboard .fx-ops-badge,
#view-dashboard .fx-ops-status {
  font-size: 14px !important;
  font-weight: 700 !important;
  color: var(--dn) !important;
  margin-top: auto;
}

#view-dashboard .fx-ops-badge--new { color: var(--dp) !important; }

/* ══════════════════════════════════════════════════
   پیشرفت هفتگی
══════════════════════════════════════════════════ */
#view-dashboard .fx-weekly-card {
  padding: var(--card-pad) !important;
}

#view-dashboard .fx-weekly-head-title {
  display: flex;
  align-items: center;
  gap: 10px;
  flex: 1;
}

#view-dashboard .fx-weekly-legend {
  display: flex;
  gap: 10px;
  margin-inline-start: auto;
}

#view-dashboard .fx-weekly-legend span {
  font-size: 11px;
  font-weight: 500;
  padding: 3px 8px;
  border-radius: var(--card-r-pill);
  background: var(--g100);
}

#view-dashboard .fx-weekly-legend .leg-weight { color: var(--dp); }
#view-dashboard .fx-weekly-legend .leg-fat { color: var(--da); }

#view-dashboard .fx-weekly-body {
  display: grid;
  grid-template-columns: 1fr 280px;
  gap: var(--dash-gap);
  flex: 1;
  margin-top: 14px;
}

#view-dashboard .fx-weekly-chart {
  min-height: 220px;
  padding: 10px !important;
  border-radius: var(--card-r-sm) !important;
}

#view-dashboard .fx-weekly-summary {
  padding: 16px !important;
  border-radius: var(--card-r-sm) !important;
  display: flex;
  flex-direction: column;
}

#view-dashboard .fx-weekly-summary h4 {
  font-size: 12px;
  font-weight: 600;
  color: var(--ds2);
  margin: 0 0 12px;
}

#view-dashboard .fx-weekly-summary ul {
  list-style: none;
  margin: 0;
  padding: 0;
  flex: 1;
}

#view-dashboard .fx-weekly-summary li {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 0;
  font-size: 12px;
  border-bottom: 1px solid var(--g200);
}

#view-dashboard .fx-weekly-summary li:last-child { border-bottom: none; }
#view-dashboard .fx-weekly-summary li span { color: var(--ds2); }
#view-dashboard .fx-weekly-summary li strong { font-size: 13px !important; font-weight: 700 !important; }
#view-dashboard .fx-weekly-summary li.fx-trend--positive strong { color: var(--ok) !important; }
#view-dashboard .fx-weekly-summary li.fx-trend--negative strong { color: var(--err) !important; }

#view-dashboard .fx-btn-outline {
  margin-top: 12px;
  width: 100%;
  padding: 9px !important;
  text-align: center;
  border-radius: var(--card-r-sm) !important;
  border: 1px solid var(--g300) !important;
  background: transparent !important;
  font-size: 12px !important;
  font-weight: 500 !important;
  color: var(--ds2) !important;
  cursor: pointer;
  transition: border-color .15s, color .15s;
}

#view-dashboard .fx-btn-outline:hover {
  border-color: var(--dp) !important;
  color: var(--dp) !important;
}

/* ══════════════════════════════════════════════════
   ترکیب بدنی
══════════════════════════════════════════════════ */
#view-dashboard .fx-body-card,
#view-dashboard .fx-body-comp {
  padding: var(--card-pad) !important;
}

#view-dashboard .fx-body-card-head {
  padding: 0 0 14px !important;
  margin-bottom: 14px !important;
  border-top: none !important;
  border-bottom: 1px solid var(--g200) !important;
  background: transparent !important;
}

#view-dashboard .fx-body-card-head-main {
  display: flex;
  align-items: center;
  gap: 12px;
}

#view-dashboard .fx-body-card-head-copy p {
  font-size: 11px;
  color: var(--ds3);
  margin: 2px 0 0;
}

#view-dashboard .fx-body-card-title-row {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

#view-dashboard .fx-body-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 8px !important;
}

#view-dashboard .fx-body-seg {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  padding: 14px 8px !important;
  border-radius: var(--card-r-sm) !important;
  text-align: center;
  cursor: default;
  transition: border-color .15s, background .15s;
}

#view-dashboard .fx-body-seg:hover {
  border-color: color-mix(in srgb, var(--dp) 25%, var(--g200)) !important;
  background: color-mix(in srgb, var(--dp) 4%, var(--g100)) !important;
}

#view-dashboard .fx-body-seg .lbl { font-size: 10px !important; color: var(--ds3) !important; }
#view-dashboard .fx-body-seg .val { font-size: 15px !important; font-weight: 700 !important; color: var(--dn) !important; }

#view-dashboard .fx-body-seg--fat .fx-body-seg-ico { background: rgba(239,68,68,.10) !important; color: var(--err) !important; }
#view-dashboard .fx-body-seg--muscle .fx-body-seg-ico { background: rgba(139,92,246,.10) !important; color: #8b5cf6 !important; }
#view-dashboard .fx-body-seg--water .fx-body-seg-ico { background: rgba(14,165,233,.10) !important; color: #0ea5e9 !important; }
#view-dashboard .fx-body-seg--bmr .fx-body-seg-ico { background: rgba(245,158,11,.10) !important; color: #f59e0b !important; }

/* ══════════════════════════════════════════════════
   دستاوردها
══════════════════════════════════════════════════ */
#view-dashboard .fx-achievements-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  padding-top: 4px;
  justify-content: flex-start;
}

#view-dashboard .fx-achievement {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
}

#view-dashboard .fx-achievement-badge {
  width: 54px !important;
  height: 54px !important;
  border-radius: 14px !important;
  box-shadow: none !important;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
}

#view-dashboard .fx-achievement-badge.gold {
  background: rgba(245,158,11,.14) !important;
  color: #d97706 !important;
  border: 1px solid rgba(245,158,11,.25) !important;
}

#view-dashboard .fx-achievement-badge.blue {
  background: var(--dp-muted) !important;
  color: var(--dp) !important;
  border: 1px solid color-mix(in srgb, var(--dp) 22%, transparent) !important;
}

#view-dashboard .fx-achievement-badge.purple {
  background: rgba(139,92,246,.12) !important;
  color: #7c3aed !important;
  border: 1px solid rgba(139,92,246,.22) !important;
}

#view-dashboard .fx-achievement-badge span { font-size: 16px !important; }
#view-dashboard .fx-achievement-badge small { font-size: 8px !important; }

#view-dashboard .fx-achievement > span:last-child {
  font-size: 10px;
  color: var(--ds3);
  max-width: 80px;
  text-align: center;
}

/* ══════════════════════════════════════════════════
   بنر پیشنهاد ویژه — بازطراحی کامل v2
   (اسپسیفیسیتی بالا — بر قانون کارت سفید widgets-system غلبه می‌کند)
══════════════════════════════════════════════════ */
html[data-user-panel-theme="fitronix"]:not([data-theme="dark"]) #view-dashboard .fx-dash[data-dash-sortable="fx-main"] > .fx-promo-banner,
html[data-user-panel-theme="fitronix"]:not([data-theme="dark"]) #view-dashboard .fx-dash[data-dash-sortable="fx-main"] > [data-dash-sort-key="promo"],
html[data-user-panel-theme="firouzi"]:not([data-theme="dark"]) #view-dashboard .fx-dash[data-dash-sortable="fx-main"] > .fx-promo-banner,
html[data-user-panel-theme="firouzi"]:not([data-theme="dark"]) #view-dashboard .fx-dash[data-dash-sortable="fx-main"] > [data-dash-sort-key="promo"],
html[data-user-panel-theme="fitronix"]:not([data-theme="dark"]) #view-dashboard .fx-promo-banner,
html[data-user-panel-theme="firouzi"]:not([data-theme="dark"]) #view-dashboard .fx-promo-banner {
  background:
    linear-gradient(135deg, #1d4ed8 0%, #2563eb 45%, #3b82f6 100%) !important;
  border: none !important;
  box-shadow: 0 8px 32px rgba(37,99,235,.28), 0 2px 8px rgba(37,99,235,.18) !important;
  color: #fff !important;
  position: relative;
  overflow: hidden;
  display: block !important;
  height: auto !important;
}

/* دکوراسیون پس‌زمینه */
html[data-user-panel-theme="fitronix"]:not([data-theme="dark"]) #view-dashboard .fx-promo-banner::after,
html[data-user-panel-theme="firouzi"]:not([data-theme="dark"]) #view-dashboard .fx-promo-banner::after {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 60% 80% at 85% 50%, rgba(255,255,255,.08), transparent 65%),
    radial-gradient(ellipse 40% 60% at 15% 20%, rgba(249,115,22,.10), transparent 55%);
  pointer-events: none;
}

html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-promo-banner,
html[data-user-panel-theme="firouzi"][data-theme="dark"] #view-dashboard .fx-promo-banner {
  background: linear-gradient(135deg, #0c1a36 0%, #0f2744 55%, #1a3a6e 100%) !important;
  border: 1px solid rgba(37,99,235,.25) !important;
  box-shadow: 0 4px 24px rgba(0,0,0,.4), inset 0 1px 0 rgba(255,255,255,.06) !important;
  color: #fff;
  position: relative;
  overflow: hidden;
}

html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-promo-banner::after,
html[data-user-panel-theme="firouzi"][data-theme="dark"] #view-dashboard .fx-promo-banner::after {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 55% 70% at 80% 50%, rgba(37,99,235,.18), transparent 60%),
    radial-gradient(ellipse 35% 50% at 20% 15%, rgba(249,115,22,.08), transparent 50%);
  pointer-events: none;
}

#view-dashboard .fx-promo-banner-inner {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 20px;
  padding: 24px 28px !important;
  position: relative;
  z-index: 1;
}

#view-dashboard .fx-promo-banner-ico {
  width: 52px !important;
  height: 52px !important;
  border-radius: 14px !important;
  background: rgba(255,255,255,.14) !important;
  border: 1px solid rgba(255,255,255,.18) !important;
  display: grid !important;
  place-items: center !important;
  flex-shrink: 0;
  backdrop-filter: blur(4px);
}

#view-dashboard .fx-promo-banner-ico svg {
  width: 24px !important;
  height: 24px !important;
  stroke: #fff !important;
  opacity: .95;
}

#view-dashboard .fx-promo-kicker {
  display: inline-block;
  font-size: 10px !important;
  font-weight: 600 !important;
  letter-spacing: .06em;
  text-transform: uppercase;
  padding: 3px 10px !important;
  background: rgba(255,255,255,.15) !important;
  border: 1px solid rgba(255,255,255,.20) !important;
  border-radius: var(--card-r-pill) !important;
  color: rgba(255,255,255,.95) !important;
  margin-bottom: 6px;
}

#view-dashboard .fx-promo-copy {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
}

#view-dashboard .fx-promo-copy h3 {
  font-size: 17px !important;
  font-weight: 800 !important;
  color: #fff !important;
  margin: 0 0 4px !important;
  line-height: 1.3;
}

#view-dashboard .fx-promo-copy p {
  font-size: 13px !important;
  color: rgba(255,255,255,.88) !important;
  margin: 0 !important;
  line-height: 1.6;
}

html[data-user-panel-theme="fitronix"]:not([data-theme="dark"]) #view-dashboard .fx-promo-banner .fx-promo-kicker,
html[data-user-panel-theme="firouzi"]:not([data-theme="dark"]) #view-dashboard .fx-promo-banner .fx-promo-kicker {
  color: rgba(255,255,255,.95) !important;
}

#view-dashboard .fx-promo-cta {
  display: inline-flex !important;
  align-items: center !important;
  gap: 7px !important;
  background: rgba(255,255,255,.95) !important;
  color: #1d4ed8 !important;
  font-size: 13px !important;
  font-weight: 700 !important;
  padding: 11px 20px !important;
  border-radius: var(--card-r-pill) !important;
  white-space: nowrap;
  border: none !important;
  box-shadow: 0 2px 12px rgba(0,0,0,.15) !important;
  flex-shrink: 0;
  transition: transform .18s ease, box-shadow .18s ease, background .18s ease !important;
}

#view-dashboard .fx-promo-cta svg {
  width: 15px !important;
  height: 15px !important;
  stroke: #1d4ed8 !important;
}

#view-dashboard .fx-promo-cta:hover {
  background: #fff !important;
  transform: translateY(-2px) !important;
  box-shadow: 0 6px 20px rgba(0,0,0,.20) !important;
  filter: none !important;
}

/* ══════════════════════════════════════════════════
   سفارشی‌سازی ویجت
══════════════════════════════════════════════════ */
#view-dashboard .fx-customize {
  grid-column: 1 / -1;
  border: 1px solid var(--g300);
  border-radius: var(--card-r-sm);
  background: var(--dw);
  overflow: hidden;
}

#view-dashboard .fx-customize summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 16px;
  font-size: 13px;
  font-weight: 500;
  color: var(--ds2);
  cursor: pointer;
  user-select: none;
}

#view-dashboard .fx-customize-title {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--dn);
  font-weight: 600;
}

#view-dashboard .fx-customize-hint {
  font-size: 11px;
  color: var(--ds3);
}

#view-dashboard .fx-customize-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  padding: 0 16px 14px;
}

#view-dashboard .fx-customize-chip {
  border-radius: var(--card-r-pill);
  font-size: 12px;
  padding: 5px 12px;
  border: 1px solid var(--g300);
  background: transparent;
  cursor: pointer;
  transition: background .12s, border-color .12s, color .12s;
  color: var(--ds2);
}

#view-dashboard .fx-customize-chip.is-on {
  background: var(--dp-muted);
  border-color: color-mix(in srgb, var(--dp) 25%, var(--g300));
  color: var(--dp);
}

#view-dashboard .fx-customize-actions {
  padding: 10px 16px 14px;
  border-top: 1px solid var(--g200);
}

#view-dashboard .fx-customize-reset {
  font-size: 12px;
  color: var(--ds3);
  background: transparent;
  border: 1px solid var(--g200);
  border-radius: var(--card-r-sm);
  padding: 7px 14px;
  cursor: pointer;
  transition: border-color .15s, color .15s;
}

#view-dashboard .fx-customize-reset:hover { border-color: var(--dp); color: var(--dp); }

/* ══════════════════════════════════════════════════
   DARK MODE — هماهنگ‌سازی کامل ویجت‌ها
══════════════════════════════════════════════════ */

/* ─── پس‌زمینه داشبورد ─── */
html[data-user-panel-theme="fitronix"][data-theme="dark"] .shell-user .main:has(#view-dashboard.active),
html[data-user-panel-theme="firouzi"][data-theme="dark"]  .shell-user .main:has(#view-dashboard.active) {
  background: #0f1420 !important;
}

html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard {
  color: var(--dn);
}

/* ─── سطح کارت‌ها (همه انواع) ─── */
html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-card,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-card,
html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-hw,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-hw,
html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-hw-standalone,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-hw-standalone,
html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-score-card,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-score-card,
html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-panel-card,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-panel-card,
html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-weekly-card,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-weekly-card,
html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-body-card,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-body-card,
html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-body-comp,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-body-comp,
html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-ops-card,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-ops-card,
html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-programs-section,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-programs-section,
html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-customize,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-customize,
html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-greet-v3.fx-dash-greet,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-greet-v3.fx-dash-greet,
html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-greet-v3.up-dash-greet,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-greet-v3.up-dash-greet,
html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-dash[data-dash-sortable="fx-main"] > [data-dash-sort-key]:not([data-dash-sort-key="promo"]),
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-dash[data-dash-sortable="fx-main"] > [data-dash-sort-key]:not([data-dash-sort-key="promo"]) {
  background: #1e2433 !important;
  border-color: rgba(255,255,255,.10) !important;
  box-shadow: var(--card-sh) !important;
}

/* ─── بنر پیشنهاد تم تاریک ─── */
html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-dash[data-dash-sortable="fx-main"] > .fx-promo-banner,
html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-dash[data-dash-sortable="fx-main"] > [data-dash-sort-key="promo"],
html[data-user-panel-theme="firouzi"][data-theme="dark"] #view-dashboard .fx-dash[data-dash-sortable="fx-main"] > .fx-promo-banner,
html[data-user-panel-theme="firouzi"][data-theme="dark"] #view-dashboard .fx-dash[data-dash-sortable="fx-main"] > [data-dash-sort-key="promo"],
html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-promo-banner,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-promo-banner {
  background: linear-gradient(135deg, #0c1a36 0%, #0f2744 50%, #1a3a6e 100%) !important;
  border: 1px solid rgba(37,99,235,.28) !important;
  box-shadow: 0 4px 24px rgba(0,0,0,.45), inset 0 1px 0 rgba(255,255,255,.06) !important;
  color: #fff !important;
}

html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-promo-copy h3,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-promo-copy h3 {
  color: #fff !important;
}

html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-promo-copy p,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-promo-copy p {
  color: rgba(255,255,255,.82) !important;
}

/* ─── عناوین ویجت ─── */
html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-card-head h3,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-card-head h3,
html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-widget-head h3,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-widget-head h3,
html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-panel-head h3,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-panel-head h3,
html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-hw-head h3,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-hw-head h3,
html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-ops-head-main span,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-ops-head-main span,
html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-programs-section h3,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-programs-section h3,
html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-weekly-head h3,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-weekly-head h3,
html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-body-card-head-copy h3,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-body-card-head-copy h3 {
  color: #e8edf5 !important;
}

/* ─── مقادیر عددی ─── */
html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-hw-foot-item strong,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-hw-foot-item strong,
html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-score-val,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-score-val,
html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-streak-days,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-streak-days,
html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-body-seg .val,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-body-seg .val,
html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-hw-stat-val,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-hw-stat-val,
html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-hw-ring-center strong,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-hw-ring-center strong,
html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-greet-stat .val,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-greet-stat .val,
html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-program-card h4,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-program-card h4 {
  color: #e8edf5 !important;
}

/* ─── برچسب‌ها و متن ثانویه ─── */
html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-score-lbl,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-score-lbl,
html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-hw-foot-item > span:last-child,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-hw-foot-item > span:last-child,
html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-streak-label,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-streak-label,
html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-body-seg .lbl,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-body-seg .lbl,
html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-ops-text,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-ops-text,
html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-greet-stat .lbl,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-greet-stat .lbl,
html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-program-card p,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-program-card p {
  color: #64748b !important;
}

/* ─── خوش‌آمدگویی ─── */
html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-greet-v3 .up-dash-greet-name-row h2,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-greet-v3 .up-dash-greet-name-row h2 {
  color: #e8edf5 !important;
}

html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-greet-v3 .up-dash-greet-sub,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-greet-v3 .up-dash-greet-sub,
html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-greet-v3 .fx-greet-expiry,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-greet-v3 .fx-greet-expiry {
  color: #94a3b8 !important;
}

html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-greet-v3 .fx-greet-date,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-greet-v3 .fx-greet-date,
html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-greet-v3 .up-dash-pill--date {
  background: rgba(255,255,255,.06) !important;
  border-color: rgba(255,255,255,.09) !important;
  color: #94a3b8 !important;
}

html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-greet-v3 .up-dash-greet-avatar {
  border-color: #1e2433 !important;
  background: rgba(255,255,255,.05) !important;
}

/* ─── سطح نمره کل ─── */
html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-score-card--total,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-score-card--total {
  background: linear-gradient(145deg, rgba(37,99,235,.16) 0%, #1e2433 65%) !important;
  border-color: rgba(37,99,235,.22) !important;
}

/* ─── عناصر تو در تو ─── */
html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-program-card,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-program-card {
  background: rgba(255,255,255,.06) !important;
  border-color: rgba(255,255,255,.09) !important;
}

html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-quick-btn,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-quick-btn {
  background: rgba(255,255,255,.06) !important;
  border-color: rgba(255,255,255,.09) !important;
  color: #94a3b8 !important;
}

html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-quick-btn:hover,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-quick-btn:hover {
  background: rgba(37,99,235,.16) !important;
  border-color: rgba(37,99,235,.28) !important;
  color: #93c5fd !important;
}

html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-ops-tile,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-ops-tile,
html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-body-seg,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-body-seg,
html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-hw-monitor-row,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-hw-monitor-row,
html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-greet-stat,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-greet-stat,
html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-hw-workout-kpi,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-hw-workout-kpi,
html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-hw-nutrition-pills li,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-hw-nutrition-pills li,
html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-hw-stats--pair li,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-hw-stats--pair li,
html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-hw-macro,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-hw-macro,
html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-hw-recovery-tile,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-hw-recovery-tile,
html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-sleep-metric,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-sleep-metric {
  background: rgba(255,255,255,.06) !important;
  border-color: rgba(255,255,255,.09) !important;
}

html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-greet-tasks,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-greet-tasks {
  background: rgba(255,255,255,.06) !important;
  border-color: rgba(255,255,255,.09) !important;
}

html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-greet-tasks .fx-task-item,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-greet-tasks .fx-task-item {
  color: #94a3b8 !important;
}

html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-hw-foot,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-hw-foot {
  background: rgba(255,255,255,.04) !important;
  border-color: rgba(255,255,255,.08) !important;
}

html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-hw-ring .fx-ring-bg,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-hw-ring .fx-ring-bg {
  stroke: rgba(255,255,255,.10) !important;
}

/* ─── آیکون‌ها ─── */
html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-score-ico,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-score-ico,
html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-widget-head-ico,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-widget-head-ico,
html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-hw-ico,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-hw-ico,
html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-ops-ico,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-ops-ico,
html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-programs-head-ico,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-programs-head-ico {
  background: rgba(255,255,255,.08) !important;
  color: #60a5fa !important;
}

/* ─── streak ─── */
html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-streak-dot,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-streak-dot {
  background: rgba(255,255,255,.07) !important;
  border-color: rgba(255,255,255,.10) !important;
}

html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-streak-dot.done,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-streak-dot.done {
  background: var(--dp) !important;
  border-color: transparent !important;
}

/* ─── آب ─── */
html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-water-cup.is-full,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-water-cup.is-full {
  background: color-mix(in srgb, var(--dp) 65%, transparent) !important;
}

/* ─── دکمه‌ها ─── */
html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-sub-btn,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-sub-btn,
html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-hw-chart-empty-btn,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-hw-chart-empty-btn {
  background: rgba(37,99,235,.20) !important;
  color: #93c5fd !important;
  border-color: rgba(37,99,235,.28) !important;
}

html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-sub-btn--ghost,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-sub-btn--ghost {
  background: rgba(255,255,255,.06) !important;
  color: #94a3b8 !important;
  border-color: rgba(255,255,255,.11) !important;
}

/* ─── جداکننده هدر ─── */
html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-widget-head,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-widget-head,
html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-panel-head,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-panel-head,
html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-hw-head,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-hw-head,
html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-card-head,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-card-head,
html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-programs-head,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-programs-head {
  border-bottom-color: rgba(255,255,255,.08) !important;
}

/* ─── بج و وضعیت ─── */
html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-ops-badge,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-ops-badge {
  background: rgba(37,99,235,.24) !important;
  color: #93c5fd !important;
}

html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-ops-status,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-ops-status {
  color: #34d399 !important;
}

/* ─── دستاوردها ─── */
html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-achievement > span:last-child,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-achievement > span:last-child {
  color: #94a3b8 !important;
}

html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-panel-head a,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-panel-head a {
  color: #60a5fa !important;
}

/* ─── سفارشی‌سازی ویجت ─── */
html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-customize summary,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-customize summary {
  color: #e8edf5 !important;
  border-color: rgba(255,255,255,.08) !important;
}

html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-customize-chip,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-customize-chip {
  background: rgba(255,255,255,.06) !important;
  border-color: rgba(255,255,255,.09) !important;
  color: #94a3b8 !important;
}

/* ─── بنر CTA ─── */
html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-promo-cta,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-promo-cta {
  background: rgba(255,255,255,.14) !important;
  color: #fff !important;
  border: 1px solid rgba(255,255,255,.20) !important;
  box-shadow: none !important;
}

html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-promo-cta svg,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-promo-cta svg {
  stroke: #fff !important;
}

html[data-user-panel-theme="fitronix"][data-theme="dark"] #view-dashboard .fx-promo-cta:hover,
html[data-user-panel-theme="firouzi"][data-theme="dark"]  #view-dashboard .fx-promo-cta:hover {
  background: rgba(255,255,255,.22) !important;
  transform: translateY(-2px) !important;
}

/* ══════════════════════════════════════════════════
   RESPONSIVE — TABLET (1100px)
══════════════════════════════════════════════════ */
@media (max-width: 1100px) {
  #view-dashboard .fx-score-row {
    grid-template-columns: repeat(2, 1fr);
  }

  #view-dashboard .fx-greet-v3 .fx-greet-layout {
    grid-template-columns: 160px 1fr 260px;
    gap: 16px;
  }

  #view-dashboard .fx-quick-row {
    grid-template-columns: 1fr 200px;
  }

  #view-dashboard .fx-body-grid {
    grid-template-columns: repeat(3, 1fr) !important;
  }
}

@media (max-width: 900px) {
  #view-dashboard .fx-greet-v3 .fx-greet-layout {
    grid-template-columns: 1fr;
    gap: 16px;
  }

  #view-dashboard .fx-greet-v3 .up-dash-greet-portrait {
    justify-self: center;
  }

  #view-dashboard .fx-quick-row {
    grid-template-columns: 1fr;
  }

  #view-dashboard .fx-quick-grid {
    grid-template-columns: repeat(3, 1fr);
  }

  #view-dashboard .fx-weekly-body {
    grid-template-columns: 1fr;
  }

  #view-dashboard .fx-hw-monitor-body {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 768px) {
  #view-dashboard .fx-score-row {
    grid-template-columns: repeat(2, 1fr);
  }

  #view-dashboard .fx-ops-row {
    grid-template-columns: 1fr;
  }

  #view-dashboard .fx-body-grid {
    grid-template-columns: repeat(2, 1fr) !important;
  }

  #view-dashboard .fx-promo-banner-inner {
    grid-template-columns: 1fr !important;
    text-align: center;
    justify-items: center;
    padding: 20px 16px !important;
  }

  #view-dashboard .fx-promo-cta { width: 100%; justify-content: center; }
}
