/* ================= اعلانات و برنامه‌ها — مرکز اطلاع‌رسانی =================
   فهرست هوشمند، تقویم ماهانه، گزارش و پیامک گروهی.
   همهٔ رنگ‌ها از توکن‌های app.css می‌آیند تا حالت شب بدون بازنویسی درست بماند. */

.ev-page { display: flex; flex-direction: column; gap: 14px; }

/* ---------- سربرگ ---------- */
.ev-hero {
  position: relative; overflow: hidden;
  display: flex; align-items: center; justify-content: space-between;
  gap: 16px; flex-wrap: wrap;
  padding: 20px 22px;
  border-radius: var(--radius-xl);
  background:
    radial-gradient(620px 240px at 88% -60%, rgba(251, 191, 36, .34), transparent 70%),
    radial-gradient(500px 260px at 4% 150%, rgba(56, 189, 248, .24), transparent 70%),
    var(--grad-brand);
  color: #fff;
  box-shadow: var(--shadow-md);
}
.ev-hero::after {
  content: ''; position: absolute; inset: 0; pointer-events: none;
  background-image: radial-gradient(rgba(255, 255, 255, .13) 1px, transparent 1px);
  background-size: 22px 22px; opacity: .45;
}
.ev-hero-main { display: flex; align-items: flex-start; gap: 14px; min-width: 0; position: relative; z-index: 1; }
.ev-hero-ic {
  width: 54px; height: 54px; flex: 0 0 auto;
  display: grid; place-items: center; border-radius: 17px;
  background: rgba(255, 255, 255, .14);
  border: 1px solid rgba(255, 255, 255, .24);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .22);
}
.ev-hero-txt { min-width: 0; }
.ev-hero-title { margin: 0 0 5px; font-size: var(--fs-xl); font-weight: 800; letter-spacing: -.2px; }
.ev-hero-sub { margin: 0; font-size: var(--fs-sm); color: rgba(255, 255, 255, .87); max-width: 760px; line-height: 1.9; }
.ev-hero-meta { display: flex; align-items: center; gap: 7px; flex-wrap: wrap; margin-top: 10px; }
.ev-live {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 5px 10px; border-radius: var(--radius-full);
  background: rgba(0, 0, 0, .18);
  border: 1px solid rgba(255, 255, 255, .2);
  font-size: var(--fs-xs); font-weight: 700; color: #eafff7;
}
.ev-live.is-warn { background: rgba(0, 0, 0, .32); border-color: rgba(254, 202, 202, .55); color: #ffe4e6; }
.ev-hero-actions { display: flex; gap: 7px; flex-wrap: wrap; position: relative; z-index: 1; }
.ev-hero-actions .btn { white-space: nowrap; }
.ev-hero-actions .ev-lbl { display: none; }
.ev-hero-actions .btn {
  background: rgba(255, 255, 255, .10);
  border-color: rgba(255, 255, 255, .28);
  color: #fff; backdrop-filter: blur(4px);
}
.ev-hero-actions .btn:hover { background: rgba(255, 255, 255, .2); border-color: rgba(255, 255, 255, .46); }
.ev-hero-actions .btn.accent { background: var(--gold); border-color: var(--gold); color: #17252d; font-weight: 800; }
.ev-hero-actions .btn.accent:hover { background: #fbbf24; }

/* ---------- شاخص‌ها ---------- */
.ev-kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(148px, 1fr)); gap: 10px; }
.ev-kpi {
  position: relative; overflow: hidden; text-align: right;
  display: grid; grid-template-columns: 34px 1fr; grid-template-rows: auto auto;
  gap: 0 9px; align-items: center;
  padding: 11px 13px; cursor: pointer; font-family: inherit;
  background: var(--paper); color: var(--ink);
  border: 1px solid var(--line); border-radius: var(--radius-lg);
  box-shadow: var(--shadow-xs);
  transition: transform var(--dur) var(--ease), box-shadow var(--dur) var(--ease), border-color var(--dur) var(--ease);
}
.ev-kpi::before {
  content: ''; position: absolute; inset-inline-start: 0; top: 0; bottom: 0; width: 4px;
  background: var(--line); border-radius: 0 4px 4px 0;
}
.ev-kpi:hover { transform: translateY(-2px); box-shadow: var(--shadow); border-color: var(--side-2); }
.ev-kpi:focus-visible { outline: 3px solid var(--ring); outline-offset: 2px; }
.ev-kpi.is-active { border-color: var(--accent-2); box-shadow: 0 0 0 2px var(--ring), var(--shadow-xs); }
.ev-kpi-ic { grid-row: 1 / 3; display: grid; place-items: center; color: var(--muted); }
.ev-kpi b { font-size: var(--fs-2xl); line-height: 1.05; font-weight: 800; color: var(--ink); font-variant-numeric: tabular-nums; }
.ev-kpi-l { font-size: var(--fs-xs); color: var(--muted); font-weight: 600; }
.ev-kpi.tone-info::before { background: var(--info); }
.ev-kpi.tone-info b { color: var(--info); }
.ev-kpi.tone-info .ev-kpi-ic { color: var(--info); }
.ev-kpi.tone-good::before { background: var(--good); }
.ev-kpi.tone-good b { color: var(--good); }
.ev-kpi.tone-good .ev-kpi-ic { color: var(--good); }
.ev-kpi.tone-warn::before { background: var(--warn); }
.ev-kpi.tone-warn b { color: var(--warn); }
.ev-kpi.tone-warn .ev-kpi-ic { color: var(--warn); }
.ev-kpi.tone-bad::before { background: var(--bad); }
.ev-kpi.tone-bad b { color: var(--bad); }
.ev-kpi.tone-bad .ev-kpi-ic { color: var(--bad); }

/* ---------- تب‌ها ---------- */
.ev-tabs {
  display: flex; gap: 8px; flex-wrap: wrap; align-items: stretch; padding: 4px;
  background: color-mix(in srgb, var(--paper) 65%, transparent);
  border: 1px solid var(--line); border-radius: var(--radius-lg);
}
.ev-tab {
  flex: 1 1 150px; min-width: 130px;
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  padding: 10px 12px; font-size: var(--fs-sm); font-weight: 700;
  border-radius: var(--radius-md); border: 1px solid transparent;
  background: transparent; color: var(--ink); font-family: inherit; cursor: pointer;
  transition: background var(--dur-fast), color var(--dur-fast), box-shadow var(--dur-fast);
}
.ev-tab:hover { background: var(--paper); border-color: var(--line); }
.ev-tab.active { background: var(--grad-brand); color: #fff; box-shadow: 0 4px 14px rgba(13, 59, 52, .28); }
.ev-tab-n {
  min-width: 21px; padding: 1px 7px; border-radius: var(--radius-full);
  font-size: var(--fs-2xs); font-weight: 800;
  background: color-mix(in srgb, currentColor 14%, transparent);
}
.ev-tab.active .ev-tab-n { background: rgba(255, 255, 255, .22); }

/* ---------- پنل و کارت ---------- */
.ev-panel { animation: evPanelIn var(--dur-base) var(--ease-out) both; }
@keyframes evPanelIn { from { opacity: 0; transform: translateY(5px); } }
.ev-card {
  padding: 18px;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-xs);
}
.ev-card-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-bottom: 12px; }
.ev-card-sub { margin: 3px 0 0; font-size: var(--fs-xs); color: var(--muted); line-height: 1.75; }
.ev-sec-title { display: flex; align-items: center; gap: 6px; margin: 0 0 12px; font-size: var(--fs-lg); font-weight: 800; }
.ev-list-card { padding: 16px; }

/* ---------- نوار ابزار ---------- */
.ev-toolbar { display: flex; flex-wrap: wrap; gap: 9px; align-items: flex-end; }
.ev-toolbar .field { margin: 0; min-width: 0; flex: 1 1 140px; }
.ev-toolbar .ev-search { flex: 2 1 250px; }
.ev-toolbar .field label { font-size: var(--fs-2xs); font-weight: 700; color: var(--muted); }
.ev-search { position: relative; }
.ev-search input { padding-inline-start: 34px; }
.ev-search-ic { position: absolute; inset-inline-start: 10px; bottom: 11px; color: var(--muted); pointer-events: none; display: grid; place-items: center; }
.ev-search-clear {
  position: absolute; inset-inline-end: 6px; bottom: 6px;
  width: 26px; height: 26px; border: 0; border-radius: 50%;
  background: var(--surface-2); color: var(--muted); cursor: pointer;
  display: none; place-items: center; font-family: inherit;
}
.ev-search.has-value .ev-search-clear { display: grid; }
.ev-search-clear:hover { color: var(--bad); }

/* ---------- چیپ‌ها ---------- */
.ev-chips { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; margin-top: 12px; }
.ev-chips-l { font-size: var(--fs-xs); color: var(--muted); font-weight: 600; }
.ev-chip {
  cursor: pointer; font-family: inherit; font-size: var(--fs-xs); font-weight: 700;
  padding: 5px 11px; border-radius: var(--radius-full);
  border: 1px solid var(--line); background: var(--paper); color: var(--ink);
  transition: background var(--dur-fast), border-color var(--dur-fast), color var(--dur-fast);
}
.ev-chip:hover { border-color: var(--accent-2); color: var(--accent-2); }
.ev-chip.active { background: var(--accent-2); border-color: var(--accent-2); color: #fff; }
.ev-chip-n { margin-inline-start: 5px; opacity: .8; font-weight: 600; }
.ev-count {
  margin-inline-start: auto; font-size: var(--fs-xs); font-weight: 700; color: var(--muted);
  background: var(--surface-2); border: 1px solid var(--line);
  padding: 4px 10px; border-radius: var(--radius-full);
}

/* ---------- انتخاب گروهی ---------- */
.ev-bulk {
  display: flex; align-items: center; gap: 6px; flex-wrap: wrap;
  margin-top: 10px; padding: 8px 10px;
  border: 1px solid color-mix(in srgb, var(--accent-2) 30%, var(--line));
  background: color-mix(in srgb, var(--accent-2) 7%, var(--paper));
  border-radius: var(--radius-md);
}
.ev-bulk[hidden] { display: none; }
.ev-bulk-n { font-size: var(--fs-xs); font-weight: 800; color: var(--accent-2); }
.ev-bulk-sep { width: 1px; align-self: stretch; background: var(--line); margin: 0 4px; }
.ev-bulk .btn { min-height: 30px; }

/* ---------- گروه تاریخ و رویدادها ---------- */
.ev-list { margin-top: 14px; display: flex; flex-direction: column; gap: 16px; }
.ev-group { display: flex; flex-direction: column; gap: 8px; }
.ev-group-head { display: flex; align-items: center; gap: 10px; }
.ev-daynum {
  flex: 0 0 auto; width: 48px; min-height: 48px;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  border-radius: var(--radius-md); border: 1px solid var(--line);
  background: var(--surface-2); color: var(--ink); line-height: 1;
}
.ev-daynum b { font-size: var(--fs-xl); font-weight: 800; font-variant-numeric: tabular-nums; }
.ev-daynum span { font-size: var(--fs-3xs); color: var(--muted); margin-top: 3px; }
.ev-daynum.is-today { background: var(--grad-brand); color: #fff; border-color: transparent; }
.ev-daynum.is-today span { color: rgba(255, 255, 255, .8); }
.ev-group-title { display: flex; flex-direction: column; min-width: 0; }
.ev-group-title strong { font-size: var(--fs-md); font-weight: 800; }
.ev-group-title span { font-size: var(--fs-2xs); color: var(--muted); margin-top: 2px; }
.ev-group-bar { flex: 1; height: 1px; background: var(--line); }
.ev-events { display: flex; flex-direction: column; gap: 8px; }
.ev-flat { display: flex; flex-direction: column; gap: 8px; }

.ev-event {
  position: relative; overflow: hidden;
  display: grid; grid-template-columns: 18px 1fr auto; gap: 11px; align-items: flex-start;
  padding: 12px 14px; padding-inline-start: 18px;
  border: 1px solid var(--line); border-radius: var(--radius-md);
  background: var(--paper);
  transition: border-color var(--dur-fast), box-shadow var(--dur-fast), background var(--dur-fast);
}
.ev-event:hover { border-color: color-mix(in srgb, var(--accent-2) 45%, var(--line)); box-shadow: var(--shadow-xs); }
.ev-stripe { position: absolute; inset-inline-start: 0; top: 0; bottom: 0; width: 4px; background: var(--accent-2); }
.ev-event.tone-normal .ev-stripe, .ev-mini.tone-normal .ev-stripe { background: var(--info); }
.ev-event.tone-important .ev-stripe, .ev-mini.tone-important .ev-stripe { background: var(--warn); }
.ev-event.tone-critical .ev-stripe, .ev-mini.tone-critical .ev-stripe { background: var(--bad); }
.ev-event.is-overdue { background: color-mix(in srgb, var(--bad) 5%, var(--paper)); border-color: color-mix(in srgb, var(--bad) 26%, var(--line)); }
.ev-event.is-done { opacity: .82; background: color-mix(in srgb, var(--good) 4%, var(--paper)); }
.ev-event.is-done .ev-title { text-decoration: line-through; text-decoration-thickness: 1px; color: var(--muted); }
.ev-pick { display: grid; place-items: center; padding-top: 2px; cursor: pointer; }
.ev-pick input { width: 16px; height: 16px; }
.ev-event-main { min-width: 0; }
.ev-event-top { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.ev-title { margin: 0; font-size: var(--fs-md); font-weight: 800; line-height: 1.6; overflow-wrap: anywhere; }
.ev-pill {
  display: inline-flex; align-items: center; gap: 4px;
  padding: 2px 8px; border-radius: var(--radius-full);
  font-size: var(--fs-2xs); font-weight: 800; white-space: nowrap;
  background: var(--surface-2); color: var(--muted); border: 1px solid var(--line);
}
.ev-pill.tone-today { background: color-mix(in srgb, var(--accent-2) 14%, var(--paper)); color: var(--accent-2); border-color: transparent; }
.ev-pill.tone-tomorrow, .ev-pill.tone-soon { background: color-mix(in srgb, var(--warn) 12%, var(--paper)); color: var(--warn); border-color: transparent; }
.ev-pill.tone-past { background: color-mix(in srgb, var(--bad) 10%, var(--paper)); color: var(--bad); border-color: transparent; }
.ev-pill.tone-done { background: color-mix(in srgb, var(--good) 10%, var(--paper)); color: var(--good); border-color: transparent; }
.ev-imp {
  display: inline-flex; align-items: center; gap: 3px;
  padding: 2px 7px; border-radius: var(--radius-full);
  font-size: var(--fs-2xs); font-weight: 800; white-space: nowrap;
}
.ev-imp.normal { background: color-mix(in srgb, var(--info) 12%, var(--paper)); color: var(--info); }
.ev-imp.important { background: color-mix(in srgb, var(--warn) 14%, var(--paper)); color: var(--warn); }
.ev-imp.critical { background: color-mix(in srgb, var(--bad) 13%, var(--paper)); color: var(--bad); }
.ev-imp.is-done { background: color-mix(in srgb, var(--good) 10%, var(--paper)); color: var(--good); }
.ev-meta { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-top: 5px; font-size: var(--fs-2xs); color: var(--muted); }
.ev-meta > span { display: inline-flex; align-items: center; gap: 4px; }
.ev-desc {
  margin: 6px 0 0; font-size: var(--fs-sm); line-height: 1.85; color: var(--muted);
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
  cursor: pointer; overflow-wrap: anywhere;
}
.ev-desc:hover { color: var(--ink); }
.ev-desc.is-open { display: block; -webkit-line-clamp: unset; }
.ev-actions { display: flex; align-items: center; gap: 2px; }
.ev-ib {
  width: 30px; height: 30px; flex: 0 0 auto;
  display: grid; place-items: center;
  border: 1px solid transparent; border-radius: var(--radius-sm);
  background: transparent; color: var(--muted); cursor: pointer; font-family: inherit;
  transition: background var(--dur-fast), color var(--dur-fast), border-color var(--dur-fast);
}
.ev-ib:hover { background: var(--surface-2); color: var(--accent-2); border-color: var(--line); }
.ev-ib:focus-visible { outline: 2px solid var(--ring); outline-offset: 1px; }
.ev-ib.danger:hover { color: var(--bad); background: color-mix(in srgb, var(--bad) 8%, var(--paper)); }

/* ---------- تقویم ---------- */
.ev-cal-card { padding: 16px; }
.ev-cal-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-bottom: 12px; }
.ev-cal-title { display: flex; flex-direction: column; }
.ev-cal-title strong { font-size: var(--fs-lg); font-weight: 800; }
.ev-cal-title span { font-size: var(--fs-2xs); color: var(--muted); margin-top: 2px; }
.ev-cal-nav { display: flex; align-items: center; gap: 5px; }
.ev-cal-layout { display: grid; grid-template-columns: 1.55fr 1fr; gap: 14px; align-items: start; }
.ev-cal-grid-wrap { min-width: 0; }
.ev-cal-grid { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 4px; }
.ev-cal-wd { text-align: center; font-size: var(--fs-2xs); font-weight: 800; color: var(--muted); padding: 4px 0 6px; }
.ev-cal-blank { min-height: 58px; }
.ev-cal-day {
  position: relative; min-height: 58px; padding: 5px;
  display: flex; flex-direction: column; align-items: center; justify-content: space-between; gap: 3px;
  border: 1px solid var(--line); border-radius: var(--radius-sm);
  background: var(--paper); color: var(--ink); cursor: pointer; font-family: inherit;
  transition: background var(--dur-fast), border-color var(--dur-fast), transform var(--dur-fast);
}
.ev-cal-day:hover { border-color: var(--accent-2); transform: translateY(-1px); }
.ev-cal-day:focus-visible { outline: 2px solid var(--ring); outline-offset: 1px; }
.ev-cal-n { font-size: var(--fs-sm); font-weight: 800; font-variant-numeric: tabular-nums; }
.ev-cal-day.is-holiday { background: color-mix(in srgb, var(--bad) 7%, var(--paper)); border-color: color-mix(in srgb, var(--bad) 22%, var(--line)); }
.ev-cal-hol { font-size: 8.5px; color: var(--bad); font-weight: 700; line-height: 1; }
.ev-cal-day.is-today { border-color: var(--accent-2); box-shadow: inset 0 0 0 1px var(--accent-2); }
.ev-cal-day.is-sel { background: var(--grad-brand); color: #fff; border-color: transparent; box-shadow: var(--shadow-xs); }
.ev-cal-day.is-sel .ev-cal-hol { color: #ffe4e6; }
.ev-cal-dots { display: flex; align-items: center; gap: 3px; min-height: 8px; flex-wrap: wrap; justify-content: center; }
.ev-cal-dots small { font-size: 8px; color: var(--muted); font-weight: 700; }
.ev-cal-day.is-sel .ev-cal-dots small { color: rgba(255, 255, 255, .85); }
.ev-dot { width: 6px; height: 6px; border-radius: 50%; display: inline-block; background: var(--muted); }
.ev-dot.imp-normal { background: var(--info); }
.ev-dot.imp-important { background: var(--warn); }
.ev-dot.imp-critical { background: var(--bad); }
.ev-dot.is-done { background: var(--good); opacity: .35; }
.ev-cal-day.is-sel .ev-dot { box-shadow: 0 0 0 1px rgba(255, 255, 255, .55); }
.ev-cal-legend { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin-top: 10px; font-size: var(--fs-2xs); color: var(--muted); }
.ev-cal-legend > span { display: inline-flex; align-items: center; gap: 4px; }
.ev-cal-legend-hol { color: var(--bad); font-weight: 700; }
.ev-day-card { border: 1px solid var(--line); border-radius: var(--radius-md); background: var(--surface-2); padding: 14px; min-height: 180px; }
.ev-day-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; flex-wrap: wrap; margin-bottom: 10px; }
.ev-day-title { display: flex; flex-direction: column; }
.ev-day-title strong { font-size: var(--fs-md); font-weight: 800; }
.ev-day-title span { font-size: var(--fs-2xs); color: var(--muted); margin-top: 2px; }
.ev-day-badges { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.ev-holiday {
  display: inline-flex; align-items: center; gap: 4px;
  padding: 3px 8px; border-radius: var(--radius-full);
  background: color-mix(in srgb, var(--bad) 12%, var(--paper)); color: var(--bad);
  font-size: var(--fs-2xs); font-weight: 800;
}
.ev-day-sec { margin-top: 10px; }
.ev-day-sec h4 { margin: 0 0 6px; font-size: var(--fs-xs); font-weight: 800; color: var(--muted); display: flex; align-items: center; gap: 6px; }
.ev-day-c { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius-full); padding: 0 6px; font-size: 9px; }
.ev-day-tags { display: flex; gap: 5px; flex-wrap: wrap; }
.ev-day-tag { padding: 3px 9px; border-radius: var(--radius-full); background: var(--paper); border: 1px solid var(--line); font-size: var(--fs-2xs); color: var(--ink); }
.ev-day-tag.is-custom { border-color: color-mix(in srgb, var(--accent) 35%, var(--line)); color: var(--accent); }
.ev-day-empty { display: flex; align-items: center; gap: 6px; margin: 6px 0 0; font-size: var(--fs-xs); color: var(--muted); }
.ev-mini-list { display: flex; flex-direction: column; gap: 6px; }
.ev-mini {
  position: relative; overflow: hidden;
  display: grid; grid-template-columns: 1fr auto; gap: 8px; align-items: center;
  padding: 8px 10px; padding-inline-start: 14px;
  border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--paper);
}
.ev-mini.is-done { opacity: .75; }
.ev-mini .ev-stripe { width: 3px; }
.ev-mini-main { display: flex; flex-direction: column; min-width: 0; }
.ev-mini-main strong { font-size: var(--fs-sm); font-weight: 700; overflow-wrap: anywhere; }
.ev-mini-main span { font-size: var(--fs-2xs); color: var(--muted); margin-top: 2px; }
.ev-mini-act { display: flex; gap: 1px; }
.ev-mini-act .ev-ib { width: 27px; height: 27px; }
.ev-cal-empty { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 10px; min-height: 220px; padding: 20px; }

/* ---------- گزارش ---------- */
.ev-report { display: flex; flex-direction: column; gap: 12px; }
.ev-report-top { display: grid; grid-template-columns: repeat(auto-fit, minmax(215px, 1fr)); gap: 12px; }
.ev-report-card { display: flex; flex-direction: column; }
.ev-report-card > .ev-pill { align-self: flex-start; }
.ev-report-eyebrow { font-size: var(--fs-2xs); font-weight: 800; color: var(--muted); text-transform: uppercase; letter-spacing: .3px; margin-bottom: 8px; }
.ev-report-big { font-size: var(--fs-lg); font-weight: 800; line-height: 1.7; }
.ev-report-sub { margin: 8px 0 0; font-size: var(--fs-xs); color: var(--muted); }
.ev-report-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.ev-donut { width: 132px; height: 132px; align-self: center; }
.ev-donut-track { stroke: var(--line); }
.ev-donut-val { stroke: var(--accent-2); stroke-linecap: round; }
.ev-donut-t { fill: var(--ink); font-size: 20px; font-weight: 800; }
.ev-donut-s { fill: var(--muted); font-size: 8px; font-weight: 700; }
.ev-att-nums { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.ev-att-nums > div { padding: 10px; border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--surface-2); text-align: center; }
.ev-att-nums b { display: block; font-size: var(--fs-2xl); font-weight: 800; color: var(--ink); font-variant-numeric: tabular-nums; }
.ev-att-nums span { font-size: var(--fs-2xs); color: var(--muted); font-weight: 600; }
.ev-report-links { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 10px; }
.ev-bar-row { display: grid; grid-template-columns: 84px 1fr 34px; align-items: center; gap: 8px; margin-top: 8px; }
.ev-bar-l { font-size: var(--fs-xs); color: var(--muted); font-weight: 600; }
.ev-bar-track { height: 9px; border-radius: var(--radius-full); background: var(--surface-2); border: 1px solid var(--line); overflow: hidden; }
.ev-bar-fill { display: block; height: 100%; border-radius: var(--radius-full); background: var(--accent-2); transition: width var(--dur-big) var(--ease-out); }
.ev-bar-fill.tone-normal { background: var(--info); }
.ev-bar-fill.tone-important { background: var(--warn); }
.ev-bar-fill.tone-critical { background: var(--bad); }
.ev-bar-fill.tone-month { background: var(--accent-2); }
.ev-bar-v { font-size: var(--fs-xs); font-weight: 800; text-align: center; font-variant-numeric: tabular-nums; }

/* ---------- فرم اعلان ---------- */
.ev-form { display: flex; flex-direction: column; gap: 12px; }
.ev-form-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 10px; }
.ev-form-actions { display: flex; align-items: center; justify-content: flex-end; gap: 8px; flex-wrap: wrap; margin-top: 4px; }
.ev-req { color: var(--bad); }
.ev-err { min-height: 15px; font-size: var(--fs-2xs); color: var(--bad); font-weight: 700; margin-top: 3px; }
input.is-invalid, textarea.is-invalid { border-color: var(--bad) !important; box-shadow: 0 0 0 2px color-mix(in srgb, var(--bad) 13%, transparent); }
.ev-hint { font-size: var(--fs-2xs); color: var(--muted); margin-top: 4px; line-height: 1.7; }
.ev-sugs { display: flex; align-items: center; gap: 5px; flex-wrap: wrap; font-size: var(--fs-2xs); color: var(--muted); }
.ev-sug {
  font-family: inherit; font-size: var(--fs-2xs); font-weight: 700; cursor: pointer;
  padding: 3px 9px; border-radius: var(--radius-full);
  border: 1px dashed var(--line); background: transparent; color: var(--ink);
}
.ev-sug:hover { border-color: var(--accent-2); color: var(--accent-2); background: var(--surface-2); }
.ev-seg {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 3px;
  padding: 3px; border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--surface-2);
}
.ev-seg-item { position: relative; cursor: pointer; }
.ev-seg-item input { position: absolute; opacity: 0; pointer-events: none; }
.ev-seg-item span {
  display: block; text-align: center; padding: 7px 4px;
  font-size: var(--fs-xs); font-weight: 700; border-radius: var(--radius-xs); color: var(--muted);
  transition: background var(--dur-fast), color var(--dur-fast), box-shadow var(--dur-fast);
}
.ev-seg-item:hover span { color: var(--ink); }
.ev-seg-item.active.normal span { background: color-mix(in srgb, var(--info) 16%, var(--paper)); color: var(--info); box-shadow: var(--shadow-xs); }
.ev-seg-item.active.important span { background: color-mix(in srgb, var(--warn) 17%, var(--paper)); color: var(--warn); box-shadow: var(--shadow-xs); }
.ev-seg-item.active.critical span { background: color-mix(in srgb, var(--bad) 15%, var(--paper)); color: var(--bad); box-shadow: var(--shadow-xs); }
.ev-ai-row { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.ev-preview { border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--surface-2); padding: 10px 12px; }
.ev-preview summary { cursor: pointer; font-size: var(--fs-xs); font-weight: 800; color: var(--ink); display: flex; align-items: center; gap: 6px; }
.ev-preview summary::-webkit-details-marker { display: none; }
.ev-preview[open] summary { margin-bottom: 9px; }
.ev-preview .field { margin: 0; }
.ev-draft {
  display: flex; align-items: center; gap: 8px; flex-wrap: wrap;
  padding: 8px 11px; border-radius: var(--radius-md);
  border: 1px solid color-mix(in srgb, var(--gold) 45%, var(--line));
  background: color-mix(in srgb, var(--gold) 10%, var(--paper));
  color: var(--ink); font-size: var(--fs-xs); font-weight: 700;
}
.ev-draft[hidden] { display: none; }
.ev-draft span { display: inline-flex; align-items: center; gap: 5px; margin-inline-end: auto; }

/* ---------- پیامک ---------- */
.modal.ev-sms-modal { max-height: 92vh; }
.ev-sms { display: flex; flex-direction: column; gap: 12px; }
.ev-sms-loading { display: flex; align-items: center; gap: 10px; padding: 18px 4px; }
.ev-sms-event {
  display: flex; align-items: center; gap: 8px; flex-wrap: wrap;
  padding: 10px 12px; border-radius: var(--radius-md);
  border: 1px solid var(--line); background: var(--surface-2);
}
.ev-sms-event strong { font-size: var(--fs-md); font-weight: 800; }
.ev-sms-event > span:not(.ev-imp) { display: inline-flex; align-items: center; gap: 4px; font-size: var(--fs-2xs); color: var(--muted); }
.ev-sms-credit { min-height: 38px; display: flex; align-items: center; gap: 5px; padding: 8px 12px; border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--surface-2); font-size: var(--fs-sm); }
.ev-sms-presets { display: flex; align-items: center; gap: 5px; flex-wrap: wrap; font-size: var(--fs-2xs); color: var(--muted); }
.ev-vars { display: flex; align-items: center; gap: 5px; flex-wrap: wrap; margin-top: 6px; font-size: var(--fs-2xs); color: var(--muted); }
.ev-var {
  font-family: inherit; font-size: var(--fs-2xs); font-weight: 700; cursor: pointer;
  padding: 2px 7px; border-radius: var(--radius-xs);
  border: 1px solid var(--line); background: var(--surface-2); color: var(--accent-2);
}
.ev-var:hover { background: var(--paper); border-color: var(--accent-2); }
.ev-sms-stats { padding: 8px 12px; border-radius: var(--radius-sm); background: color-mix(in srgb, var(--accent-2) 7%, var(--paper)); border: 1px solid color-mix(in srgb, var(--accent-2) 22%, var(--line)); font-size: var(--fs-xs); color: var(--ink); }
.ev-sms-stats strong { font-size: var(--fs-sm); }
.ev-over-credit { color: var(--bad); font-weight: 800; }
.ev-sms-preview p { margin: 4px 0 0; padding: 9px 11px; border: 1px dashed var(--line); border-radius: var(--radius-sm); background: var(--paper); font-size: var(--fs-sm); line-height: 1.9; white-space: pre-wrap; }
.ev-sms-modal .ev-sms-preview p { max-height: 150px; overflow-y: auto; }
.ev-sms-modal .ev-form-actions { position: sticky; bottom: 0; margin-top: 0; padding: 8px 0 4px; background: var(--paper); }
.ev-preview-label { font-size: var(--fs-2xs); font-weight: 800; color: var(--muted); }
.ev-rcpt-head { display: flex; align-items: center; gap: 5px; font-size: var(--fs-xs); font-weight: 800; color: var(--muted); margin-bottom: 5px; }
.ev-rcpt-list { display: flex; gap: 5px; flex-wrap: wrap; }
.ev-rcpt {
  display: inline-flex; align-items: center; gap: 5px;
  padding: 3px 8px; border-radius: var(--radius-full);
  border: 1px solid var(--line); background: var(--surface-2); font-size: var(--fs-2xs);
}
.ev-rcpt small { color: var(--muted); font-size: 9px; }
.ev-more { font-size: var(--fs-2xs); color: var(--muted); align-self: center; }

/* ---------- اسکلتون و چرخنده ---------- */
.ev-skel { position: relative; overflow: hidden; border-radius: var(--radius-lg); background: var(--surface-2); border: 1px solid var(--line); }
.ev-skel::after {
  content: ''; position: absolute; inset: 0;
  background: linear-gradient(90deg, transparent, color-mix(in srgb, var(--paper) 65%, transparent), transparent);
  transform: translateX(100%); animation: evShimmer 1.4s infinite;
}
@keyframes evShimmer { to { transform: translateX(-100%); } }
.ev-skel-hero { height: 132px; }
.ev-skel-kpi { height: 72px; }
.ev-skel-tabs { height: 48px; }
.ev-skel-list { height: 320px; }
.ev-spin {
  width: 18px; height: 18px; display: inline-block;
  border: 2px solid color-mix(in srgb, var(--accent-2) 25%, transparent);
  border-top-color: var(--accent-2); border-radius: 50%;
  animation: evSpin .8s linear infinite;
}
@keyframes evSpin { to { transform: rotate(360deg); } }

/* ---------- واکنش‌گرا ---------- */
@media (max-width: 960px) {
  .ev-cal-layout { grid-template-columns: 1fr; }
  .ev-report-grid { grid-template-columns: 1fr; }
}
@media (max-width: 720px) {
  .ev-hero { padding: 16px; }
  .ev-hero-main { gap: 10px; }
  .ev-hero-ic { width: 46px; height: 46px; border-radius: 14px; }
  .ev-hero-actions {
    width: 100%;
    display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 6px;
  }
  .ev-hero-actions .btn { justify-content: center; padding-inline: 6px; font-size: var(--fs-xs); gap: 5px; }
  .ev-hero-actions .btn.accent { grid-column: 1 / -1; font-size: var(--fs-sm); }
  .ev-hero-actions .ev-lbl { display: inline; }
  .ev-kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .ev-tabs { flex-wrap: nowrap; }
  .ev-tab { flex: 1 1 0; min-width: 0; padding: 9px 6px; font-size: var(--fs-xs); }
  .ev-tab .ic { display: none; }
  .ev-event { grid-template-columns: 18px 1fr; }
  .ev-group-title strong { display: none; }
  .ev-actions {
    grid-column: 1 / -1;
    justify-content: space-between;
    gap: 4px;
    border-top: 1px dashed var(--line);
    padding-top: 6px;
  }
  .ev-ib { width: 36px; height: 36px; }
  .modal.ev-sms-modal { max-height: calc(100vh - 12px); }
  .ev-sms { gap: 10px; }
  .modal.ev-sms-modal .modal-body { padding: 12px 14px 14px; }
  .ev-sms-modal .ev-form-actions { bottom: 0; }
  .ev-cal-day { min-height: 48px; padding: 4px; }
  .ev-cal-hol { display: none; }
  .ev-cal-grid { gap: 3px; }
  .ev-count { margin-inline-start: 0; }
}
@media (max-width: 480px) {
  .ev-kpis { grid-template-columns: 1fr 1fr; }
  .ev-kpi b { font-size: var(--fs-xl); }
  .ev-hero-title { font-size: var(--fs-lg); }
}
@media (prefers-reduced-motion: reduce) {
  .ev-panel, .ev-skel::after, .ev-spin, .ev-kpi, .ev-cal-day, .ev-bar-fill { animation: none !important; transition: none !important; }
}
