/* ===== Dashboard ===== */
.welcome {
  display: flex; justify-content: space-between; align-items: center; gap: 20px; flex-wrap: wrap;
  background: linear-gradient(120deg, #1E4233 0%, #244B3A 60%, #2D5A46 100%);
  color: #fff; border-radius: var(--radius-lg); padding: 22px 26px; margin-bottom: 20px;
  position: relative; overflow: hidden;
}
.welcome::after {
  content: ''; position: absolute; right: -60px; top: -60px; width: 260px; height: 260px; border-radius: 50%;
  border: 40px solid rgba(198,161,91,.12);
}
.welcome h2 { font-family: var(--font-display); font-size: 30px; font-weight: 600; letter-spacing: 0; }
.welcome p { margin: 4px 0 0; color: #C9D9CF; }
.welcome .btn { position: relative; z-index: 1; }
.welcome .btn:not(.btn-gold) { background: rgba(255,255,255,.1); border-color: rgba(255,255,255,.2); color: #fff; }
.welcome .btn:not(.btn-gold):hover { background: rgba(255,255,255,.18); }

.kpi-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 14px; margin-bottom: 20px; }
.kpi {
  background: #fff; border: 1px solid var(--border); border-radius: var(--radius); padding: 16px 18px;
  display: flex; flex-direction: column; gap: 8px; box-shadow: var(--shadow-sm); cursor: pointer;
  transition: box-shadow .18s, border-color .18s;
}
.kpi:hover { box-shadow: var(--shadow); border-color: var(--border-strong); }
.kpi-top { display: flex; align-items: center; justify-content: space-between; }
.kpi-label { font-size: 12.5px; color: var(--muted); font-weight: 500; }
.kpi-icon { width: 34px; height: 34px; border-radius: 9px; display: grid; place-items: center; }
.kpi-icon svg { width: 17px; height: 17px; }
.kpi-value { font-size: 24px; font-weight: 700; letter-spacing: -0.02em; font-variant-numeric: tabular-nums; }
.kpi-foot { font-size: 12px; color: var(--muted); }
.ic-green { background: var(--success-50); color: var(--success); }
.ic-gold { background: var(--gold-50); color: var(--gold-600); }
.ic-red { background: var(--danger-50); color: var(--danger); }
.ic-blue { background: var(--info-50); color: var(--info); }
.ic-orange { background: var(--warning-50); color: var(--warning); }
.ic-purple { background: var(--purple-50); color: var(--purple); }
.ic-dark { background: var(--primary-50); color: var(--primary); }

.chart-box { position: relative; height: 270px; }
.chart-box.sm { height: 230px; }

.activity-list { display: flex; flex-direction: column; }
.activity { display: flex; align-items: center; gap: 12px; padding: 11px 18px; border-bottom: 1px solid var(--border); cursor: pointer; }
.activity:last-child { border-bottom: none; }
.activity:hover { background: var(--surface-2); }
.activity .a-icon { width: 34px; height: 34px; border-radius: 9px; display: grid; place-items: center; flex: 0 0 34px; }
.activity .a-icon svg { width: 16px; height: 16px; }
.activity .a-main { flex: 1; min-width: 0; }
.activity .a-title { font-weight: 550; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.activity .a-sub { font-size: 12px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

.popular { display: flex; align-items: center; gap: 12px; padding: 10px 18px; }
.popular .rank { width: 22px; font-weight: 700; color: var(--gold-600); font-family: var(--font-display); font-size: 18px; }
.popular .p-main { flex: 1; min-width: 0; }
.popular .p-name { font-weight: 550; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* ===== Calendar ===== */
.cal-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 14px 16px; border-bottom: 1px solid var(--border); flex-wrap: wrap; }
.cal-title { font-size: 18px; font-weight: 600; min-width: 200px; }
.cal-grid { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); }
.cal-dow { padding: 8px; font-size: 11.5px; font-weight: 600; color: var(--muted); text-transform: uppercase; letter-spacing: .06em; border-bottom: 1px solid var(--border); text-align: center; background: var(--surface-2); }
.cal-cell { min-height: 118px; border-right: 1px solid var(--border); border-bottom: 1px solid var(--border); padding: 6px; display: flex; flex-direction: column; gap: 3px; }
.cal-cell:nth-child(7n) { border-right: none; }
.cal-cell.other { background: #FAFAF8; }
.cal-cell.other .cal-day { color: #B9BEB8; }
.cal-cell.today { background: #FFFCF5; }
.cal-cell.today .cal-day { background: var(--gold); color: #fff; }
.cal-day { font-size: 12px; font-weight: 600; width: 24px; height: 24px; display: grid; place-items: center; border-radius: 50%; }
.cal-ev { font-size: 11.5px; padding: 2px 6px; border-radius: 5px; cursor: pointer; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; border-left: 3px solid; font-weight: 500; }
.cal-ev:hover { filter: brightness(.96); }
.cal-more { font-size: 11px; color: var(--muted); cursor: pointer; padding-left: 4px; }
.cal-legend { display: flex; gap: 14px; flex-wrap: wrap; padding: 12px 16px; border-top: 1px solid var(--border); font-size: 12px; color: var(--muted); }
.cal-legend span { display: inline-flex; align-items: center; gap: 6px; }
.cal-legend i { width: 10px; height: 10px; border-radius: 3px; display: inline-block; }
.cal-week { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); }
.cal-week .cal-cell { min-height: 380px; }
.day-list { padding: 16px; display: flex; flex-direction: column; gap: 10px; }
.day-ev { display: flex; gap: 14px; padding: 14px; border-radius: 10px; border: 1px solid var(--border); border-left: 4px solid; cursor: pointer; align-items: center; }
.day-ev:hover { background: var(--surface-2); }

/* ===== Reports ===== */
.report-layout { display: grid; grid-template-columns: 250px minmax(0, 1fr); gap: 16px; align-items: start; }
.report-nav { padding: 8px; position: sticky; top: calc(var(--topbar-h) + 16px); }
.report-link { display: flex; align-items: center; gap: 10px; padding: 9px 11px; border-radius: 8px; cursor: pointer; color: var(--text); font-weight: 500; font-size: 13px; }
.report-link:hover { background: var(--surface-2); }
.report-link.active { background: var(--primary-50); color: var(--primary); }
.report-link svg { width: 16px; height: 16px; color: var(--muted); }
.report-link.active svg { color: var(--gold-600); }
.report-summary { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 12px; padding: 16px; border-bottom: 1px solid var(--border); }
.rs-item { background: var(--surface-2); border: 1px solid var(--border); border-radius: 10px; padding: 12px 14px; }
.rs-label { font-size: 12px; color: var(--muted); }
.rs-value { font-size: 19px; font-weight: 700; margin-top: 2px; font-variant-numeric: tabular-nums; }
