/* ════════════════════════════════════════════
   DASHBOARD — Início
   ════════════════════════════════════════════ */

.chart-header-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 0;
  padding: 0 0 18px;
  border-bottom: 1px solid var(--line-soft);
  margin-bottom: 4px;
}
.chart-stat { padding-right: 24px; }
.chart-stat + .chart-stat { padding-left: 16px; border-left: 1px solid var(--ink-200); }

/* Next meeting card */
.meeting-card {
  background: var(--card);
  border-radius: var(--r-card);
  padding: 20px;
  margin-top: 14px;
  box-shadow: var(--shadow-sm);
  border-left: 4px solid var(--green-700);
}
.meeting-card-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
}
.meeting-badge {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .04em;
  background: #f0fdf4;
  color: var(--green-700);
  padding: 4px 10px;
  border-radius: 999px;
}
.meeting-card-btn {
  width: 28px; height: 28px;
  border-radius: 50%;
  background: var(--surface-2);
  border: none;
  display: grid; place-items: center;
  color: var(--ink-500);
  cursor: pointer;
  transition: background 120ms, color 120ms;
  font-family: inherit;
}
.meeting-card-btn:hover { background: var(--surface-3, #e5e7eb); color: var(--ink-900); }
.meeting-title {
  font-size: 15px;
  font-weight: 800;
  color: var(--ink-900);
  line-height: 1.25;
  margin-bottom: 8px;
  letter-spacing: -.2px;
}
.meeting-meta {
  display: flex;
  gap: 14px;
  font-size: 12px;
  font-weight: 600;
  color: var(--ink-500);
  align-items: center;
  margin-bottom: 12px;
}
.meeting-meta svg { vertical-align: middle; margin-right: 4px; }
.meeting-quorum {
  margin-bottom: 12px;
}
.meeting-quorum-bar {
  height: 5px;
  background: var(--surface-2);
  border-radius: 999px;
  overflow: hidden;
  margin-bottom: 5px;
}
.meeting-quorum-fill {
  height: 100%;
  border-radius: 999px;
  transition: width 600ms ease;
}
.meeting-quorum-label {
  display: flex;
  justify-content: space-between;
  font-size: 11px;
  color: var(--ink-500);
  font-weight: 500;
}
.meeting-agenda {
  border-top: 1px solid var(--line-soft);
  padding-top: 11px;
  display: flex;
  flex-direction: column;
  gap: 7px;
}
.meeting-agenda-item {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  font-size: 12px;
  color: var(--ink-700);
  line-height: 1.4;
}
.agenda-dot {
  display: block;
  width: 5px; height: 5px;
  border-radius: 50%;
  background: var(--green-700);
  flex-shrink: 0;
  margin-top: 5px;
}

/* Overall layout: sidebar + body */
.dash-layout {
  display: flex;
  gap: 32px;
  align-items: flex-start;
  margin-left: 15px;
}

/* Floating left sidebar */
.dash-sidebar {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 4px;
  background: var(--surface-2);
  border-radius: 26px;
  padding: 10px 8px;
  flex-shrink: 0;
  width: 52px;
  position: sticky;
  top: 8px;
  margin-top: 72px;
  overflow: hidden;
  transition: width 240ms cubic-bezier(.4,0,.2,1);
}
.dash-sidebar:hover {
  width: 210px;
}
.dsb-icon {
  width: 36px;
  height: 36px;
  min-width: 36px;
  border-radius: 18px;
  background: var(--card);
  border: none;
  display: flex;
  align-items: center;
  gap: 0;
  padding: 0;
  color: var(--ink-400);
  cursor: pointer;
  font-family: inherit;
  font-size: 13px;
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  box-shadow: 0 1px 3px rgba(0,0,0,.08);
  transition: width 240ms cubic-bezier(.4,0,.2,1),
              border-radius 240ms cubic-bezier(.4,0,.2,1),
              padding 240ms cubic-bezier(.4,0,.2,1),
              background 120ms, color 120ms, box-shadow 120ms;
}
.dash-sidebar:hover .dsb-icon {
  width: 194px;
  border-radius: 12px;
  padding: 0 12px 0 10px;
  gap: 10px;
}
.dsb-ico {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  width: 36px;
  height: 36px;
}
.dsb-label {
  opacity: 0;
  transition: opacity 80ms;
  pointer-events: none;
}
.dash-sidebar:hover .dsb-label {
  opacity: 1;
  transition: opacity 160ms 140ms;
}
.dsb-icon:hover { background: #fff; color: var(--ink-900); box-shadow: 0 2px 6px rgba(0,0,0,.12); }
.dsb-icon.active { background: #fff; color: var(--ink-900); box-shadow: 0 2px 6px rgba(0,0,0,.12); }
.dsb-logout:hover { color: var(--danger); }
.dsb-spacer { flex: 1; min-height: 8px; }
.dsb-sep {
  width: 36px;
  height: 1px;
  background: var(--line);
  flex-shrink: 0;
  margin: 2px 0;
  transition: width 240ms cubic-bezier(.4,0,.2,1);
}
.dash-sidebar:hover .dsb-sep { width: 194px; }

/* Chevron affordance: visible when collapsed, fades on hover */
.dash-sidebar::after {
  content: '›';
  position: absolute;
  bottom: 12px;
  left: 0; right: 0;
  text-align: center;
  font-size: 14px;
  font-weight: 700;
  color: var(--ink-300);
  transition: opacity 160ms;
  pointer-events: none;
}
.dash-sidebar:hover::after { opacity: 0; }

/* Hide sidebar on mobile/touch */
@media (max-width: 900px) {
  .dash-sidebar { display: none; }
}

/* Main content area */
.dash-body {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 18px;
}

/* Greeting row */
.dash-greeting {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}
.dash-greeting-left h1 {
  font-size: 26px;
  font-weight: 800;
  color: var(--ink-900);
  margin: 0 0 4px;
  letter-spacing: -.4px;
  line-height: 1.15;
}
.dash-greeting-left p {
  font-size: 13px;
  color: var(--ink-500);
  margin: 0;
}
.dash-greeting-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
  flex-wrap: wrap;
}
.dash-action-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 9px 16px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--card);
  font-size: 13px;
  font-weight: 600;
  color: var(--ink-900);
  cursor: pointer;
  transition: all 120ms;
  font-family: inherit;
  white-space: nowrap;
  box-shadow: var(--shadow-sm);
}
.dash-action-btn:hover { background: var(--surface-2); }
.dash-action-btn.primary {
  background: var(--ok);
  border-color: var(--ok);
  color: #fff;
  box-shadow: 0 2px 8px rgba(22,163,74,.35);
}
.dash-action-btn.primary:hover { background: var(--green-600); border-color: var(--green-600); }

/* 2-column grid */
.dash-cols {
  display: grid;
  grid-template-columns: 42% 1fr;
  gap: 14px;
  align-items: start;
}
@media (max-width: 1150px) { .dash-cols { grid-template-columns: 1fr; } }

/* Summary card */
.summary-card {
  background: var(--card);
  border-radius: var(--r-card);
  padding: 20px;
  box-shadow: var(--shadow-sm);
}
.summary-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: 14px;
}
.summary-header h3 {
  font-size: 16px;
  font-weight: 700;
  color: var(--ink-900);
  margin: 0 0 3px;
}
.summary-header p { font-size: 12px; color: var(--ink-500); margin: 0; }
.period-wrap {
  position: relative;
  flex-shrink: 0;
}
.summary-dropdown {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 5px 11px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--card);
  font-size: 12px;
  font-weight: 600;
  color: var(--ink-900);
  cursor: pointer;
  font-family: inherit;
  transition: background 120ms, border-color 120ms;
}
.summary-dropdown:hover, .summary-dropdown.open {
  background: var(--surface-2);
  border-color: var(--ink-200);
}
.summary-dropdown.open svg { transform: rotate(180deg); }
.summary-dropdown svg { transition: transform 200ms; }
.period-panel {
  position: absolute;
  right: 0;
  top: calc(100% + 6px);
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 16px;
  box-shadow: var(--shadow-md);
  overflow: hidden;
  z-index: 120;
  min-width: 160px;
  padding: 4px;
}
.period-opt {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  padding: 8px 12px;
  border: none;
  background: transparent;
  font-family: inherit;
  font-size: 12px;
  font-weight: 600;
  color: var(--ink-500);
  cursor: pointer;
  border-radius: 10px;
  transition: background 100ms, color 100ms;
  text-align: left;
  gap: 10px;
}
.period-opt:hover { background: var(--surface-2); color: var(--ink-900); }
.period-opt.active { color: var(--ink-900); }
.period-opt.active svg { color: var(--ok); }
.summary-kpis {
  display: flex;
  align-items: stretch;
  margin-bottom: 14px;
  padding: 12px 0;
  border-top: 1px solid var(--line-soft);
  border-bottom: 1px solid var(--line-soft);
}
.summary-kpi { flex: 1; padding: 0 14px; }
.summary-kpi:first-child { padding-left: 0; }
.summary-kpi:last-child  { padding-right: 0; }
.summary-kpi + .summary-kpi { border-left: 1px solid var(--line-soft); }
.summary-kpi-label {
  font-size: 11px;
  color: var(--ink-500);
  margin-bottom: 6px;
  display: flex;
  align-items: center;
  gap: 6px;
}
.summary-kpi-icon {
  width: 22px; height: 22px;
  border-radius: 50%;
  display: grid; place-items: center;
  flex-shrink: 0;
}
.summary-kpi-value {
  font-size: 22px;
  font-weight: 800;
  color: var(--ink-900);
  letter-spacing: -.4px;
  line-height: 1;
}
.chart-legend-row {
  display: flex;
  gap: 16px;
  margin-top: 8px;
  font-size: 11px;
  color: var(--ink-500);
  align-items: center;
}
.chart-legend-dot {
  width: 10px; height: 10px;
  border-radius: 3px;
  display: inline-block;
  flex-shrink: 0;
  margin-right: 4px;
  vertical-align: middle;
}

/* Metric cards (kept for compatibility) */
.metric-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-top: 10px;
}
.metric-card {
  background: var(--surface-2);
  border-radius: var(--r-md);
  padding: 16px;
}
.metric-icon {
  width: 32px; height: 32px;
  border-radius: 50%;
  background: var(--card);
  display: grid; place-items: center;
  color: var(--ink-500);
  margin-bottom: 10px;
  box-shadow: var(--shadow-sm);
}
.metric-label {
  font-size: 11px;
  color: var(--ink-500);
  font-weight: 500;
  margin-bottom: 4px;
  display: block;
}
.metric-value {
  font-size: 24px;
  font-weight: 800;
  color: var(--ink-900);
  letter-spacing: -.4px;
  line-height: 1;
  margin-bottom: 6px;
}
.metric-variation {
  display: flex;
  align-items: center;
  gap: 3px;
  font-size: 11px;
  font-weight: 700;
}
.metric-variation.up   { color: var(--ok); }
.metric-variation.down { color: var(--danger); }

/* CTA card */
.cta-dash-card {
  background: var(--card);
  border-radius: 16px;
  padding: 13px 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: 10px;
  border: 1px solid var(--line-soft);
}
.cta-dash-card p { font-size: 13px; font-weight: 600; color: var(--ink-900); margin: 0 0 2px; }
.cta-dash-link { font-size: 11.5px; color: var(--ok); font-weight: 600; cursor: pointer; }
.cta-dash-link:hover { text-decoration: underline; }
.cta-close-btn {
  width: 26px; height: 26px;
  border-radius: 50%;
  border: 1px solid var(--line);
  background: var(--surface);
  display: grid; place-items: center;
  cursor: pointer;
  flex-shrink: 0;
  color: var(--ink-500);
  font-family: inherit;
}

/* Activity card */
.activity-card {
  background: var(--card);
  border-radius: var(--r-card);
  padding: 20px;
  box-shadow: var(--shadow-sm);
}
.activity-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: 14px;
}
.activity-header h3 { font-size: 16px; font-weight: 700; color: var(--ink-900); margin: 0 0 3px; }
.activity-header p  { font-size: 12px; color: var(--ink-500); margin: 0; }
.activity-header-actions { display: flex; gap: 6px; }
.activity-icon-btn {
  width: 32px; height: 32px;
  border-radius: 50%;
  border: 1px solid var(--line);
  background: var(--card);
  display: grid; place-items: center;
  cursor: pointer;
  color: var(--ink-500);
  transition: all 120ms;
  font-family: inherit;
}
.activity-icon-btn:hover { background: var(--surface-2); color: var(--ink-900); }

/* 3-column sub-cards */
.activity-sub-cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}
.sub-card {
  background: var(--surface-2);
  border-radius: 16px;
  padding: 14px;
  overflow: hidden;
}
.sub-card.highlight { background: var(--ink-700); color: #fff; }
.sub-card-header { display: flex; align-items: center; gap: 8px; margin-bottom: 8px; }
.sub-card-icon {
  width: 30px; height: 30px;
  border-radius: 50%;
  background: var(--card);
  display: grid; place-items: center;
  color: var(--ink-700);
  flex-shrink: 0;
}
.sub-card.highlight .sub-card-icon { background: rgba(255,255,255,.1); color: var(--danger); }
.sub-card-label { font-size: 12px; font-weight: 600; color: var(--ink-700); line-height: 1.2; }
.sub-card.highlight .sub-card-label { color: rgba(255,255,255,.75); }
.sub-card-variation {
  font-size: 11px;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 3px;
  margin-bottom: 3px;
}
.sub-card-value {
  font-size: 18px;
  font-weight: 800;
  color: var(--ink-900);
  letter-spacing: -.3px;
  margin-bottom: 8px;
  line-height: 1;
}
.sub-card.highlight .sub-card-value { color: #fff; }
.sparkline-wrap { line-height: 0; overflow: hidden; }

/* Summary mini-KPIs */
.summary-mini-kpis {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  margin-top: 12px;
}
.smk-card {
  background: var(--ink-700);
  border-radius: 14px;
  padding: 12px 14px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.smk-card.smk-light {
  background: var(--surface-2);
}
.smk-header {
  display: flex;
  align-items: center;
  gap: 7px;
  margin-bottom: 2px;
}
.smk-icon {
  width: 26px; height: 26px;
  border-radius: 50%;
  display: grid; place-items: center;
  flex-shrink: 0;
  background: rgba(255,255,255,.18);
  color: #fff;
}
.smk-icon.smk-icon-light {
  background: var(--card);
  color: var(--ink-500);
  box-shadow: 0 1px 3px rgba(0,0,0,.07);
}
.smk-label {
  font-size: 11px;
  font-weight: 600;
  color: rgba(255,255,255,.75);
  line-height: 1.2;
}
.smk-label.smk-label-light { color: var(--ink-500); }
.smk-value {
  font-size: 17px;
  font-weight: 800;
  color: #fff;
  letter-spacing: -.4px;
  line-height: 1;
  margin-top: 2px;
}
.smk-value.smk-value-light { color: var(--ink-900); }

/* Activity sub-card extras */
.sub-card-vs {
  font-size: 11px;
  font-weight: 500;
  color: var(--ink-400);
  margin-left: 4px;
  letter-spacing: 0;
}
.sub-card.highlight .sub-card-vs { color: rgba(255,255,255,.45); }
.sub-card-link {
  display: inline-block;
  margin-left: auto;
  font-size: 10px;
  font-weight: 700;
  color: rgba(255,255,255,.8);
  background: rgba(255,255,255,.12);
  border: none;
  border-radius: 999px;
  padding: 2px 8px;
  cursor: pointer;
  font-family: inherit;
  transition: background 120ms;
  white-space: nowrap;
  flex-shrink: 0;
}
.sub-card-link:hover { background: rgba(255,255,255,.22); }

/* Clickable member name in history table */
.hist-member-link:hover {
  color: var(--green-700) !important;
  text-decoration: underline;
}

/* History card */
.history-card {
  background: var(--card);
  border-radius: var(--r-card);
  padding: 20px;
  box-shadow: var(--shadow-sm);
  margin-top: 10px;
}
.history-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: 14px;
}
.history-header h3 { font-size: 16px; font-weight: 700; color: var(--ink-900); margin: 0 0 3px; }
.history-header p  { font-size: 12px; color: var(--ink-500); margin: 0; }
.hist-table { width: 100%; border-collapse: separate; border-spacing: 0; font-size: 13px; }
.hist-table th {
  text-align: left;
  font-size: 11px;
  font-weight: 500;
  color: var(--ink-500);
  padding: 6px 10px;
  border-bottom: 0.5px solid var(--line);
}
.hist-table td { padding: 10px 10px; border-bottom: 0.5px solid var(--line-soft); vertical-align: middle; }
.hist-table tr:last-child td { border-bottom: none; }
.hist-avatar {
  width: 28px; height: 28px;
  border-radius: 50%;
  background: var(--surface-3);
  display: flex; align-items: center; justify-content: center;
  font-size: 10px; font-weight: 700;
  color: var(--ink-700);
  flex-shrink: 0;
}

/* Aniversariantes do mês */
.bday-card {
  background: var(--card);
  border-radius: var(--r-card);
  padding: 20px;
  box-shadow: var(--shadow-sm);
}
.bday-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
}
.bday-title-wrap {
  display: flex;
  align-items: center;
  gap: 12px;
}
.bday-icon-wrap {
  width: 36px; height: 36px;
  border-radius: 12px;
  background: var(--ok-bg);
  color: var(--green-700);
  display: grid; place-items: center;
  flex-shrink: 0;
}
.bday-header h3 { font-size: 15px; font-weight: 700; color: var(--ink-900); margin: 0 0 2px; }
.bday-header p  { font-size: 12px; color: var(--ink-500); margin: 0; }
.bday-list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 8px;
}
.bday-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border-radius: 14px;
  background: var(--surface-2);
  transition: background 120ms;
}
.bday-item:hover { background: var(--surface-3, #e5e7eb); }
.bday-item.bday-today {
  background: var(--ok-bg);
  outline: 1.5px solid var(--green-700);
}
.bday-av {
  width: 34px; height: 34px;
  border-radius: 50%;
  background: var(--card);
  display: flex; align-items: center; justify-content: center;
  font-size: 11px; font-weight: 800;
  color: var(--ink-700);
  flex-shrink: 0;
  box-shadow: 0 1px 3px rgba(0,0,0,.08);
}
.bday-item.bday-today .bday-av { background: var(--green-700); color: #fff; }
.bday-info { flex: 1; min-width: 0; }
.bday-name {
  font-size: 13px;
  font-weight: 600;
  color: var(--ink-900);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  display: flex;
  align-items: center;
  gap: 6px;
}
.bday-today-badge {
  font-size: 10px;
  font-weight: 700;
  background: var(--green-700);
  color: #fff;
  border-radius: 999px;
  padding: 1px 7px;
  white-space: nowrap;
}
.bday-sub {
  font-size: 11px;
  color: var(--ink-500);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.bday-day {
  font-size: 11px;
  font-weight: 700;
  color: var(--ink-400);
  flex-shrink: 0;
}
