.makerspace-dashboard-wrapper {
  padding: 1.5rem 1rem 2rem;
}

.makerspace-dashboard-tabs {
  display: flex;
  flex-wrap: nowrap;
  gap: 0.25rem;
  margin-bottom: 1.5rem;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid #d0d7de;
  overflow-x: auto;
  overflow-y: hidden;
  scrollbar-width: thin;
}

.makerspace-dashboard-tabs .nav-link {
  color: #374151;
  font-size: 0.9rem;
  font-weight: 500;
  white-space: nowrap;
  padding: 0.45rem 0.65rem;
}

.makerspace-dashboard-tabs .nav-link:hover,
.makerspace-dashboard-tabs .nav-link:focus {
  color: #1f2937;
  background-color: #e5e7eb;
}

.makerspace-dashboard-tabs .nav-link:focus-visible {
  outline: 2px solid #2563eb;
  outline-offset: 2px;
}

.makerspace-dashboard-tabs .nav-link.active {
  color: #ffffff;
  background-color: #0d6efd;
}

@media (max-width: 768px) {
  .makerspace-dashboard-tabs {
    flex-wrap: wrap;
    overflow-x: visible;
  }
}

.makerspace-dashboard-section {
  margin-bottom: 2.5rem;
}

.makerspace-dashboard-section .chart,
.makerspace-dashboard-section .charts-chartjs {
  display: block;
  margin: 0 auto;
  width: 100%;
  max-width: 100%;
}

.makerspace-dashboard-section .chart {
  background-color: #f8fafc;
  border: 1px solid #d0d7de;
  border-radius: 8px;
  padding: 1.25rem;
  margin-bottom: 1rem;
}

.makerspace-dashboard-range-chart {
  margin-bottom: 1.75rem;
  position: relative;
}

.makerspace-dashboard-range-chart.is-loading::after {
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(255, 255, 255, 0.65);
  border-radius: 8px;
  z-index: 2;
}

.makerspace-dashboard-range-controls {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 0.75rem;
  align-items: center;
}

.makerspace-dashboard-range-button {
  background-color: #f1f5f9;
  border: 1px solid #cbd5f5;
  border-radius: 14px;
  color: #1f2937;
  cursor: pointer;
  font-size: 0.875rem;
  line-height: 1.2;
  padding: 0.35rem 0.85rem;
  transition: background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

.makerspace-dashboard-range-button:hover {
  background-color: #e2e8f0;
}

.makerspace-dashboard-range-button.is-active {
  background-color: #1d4ed8;
  border-color: #1d4ed8;
  color: #ffffff;
  cursor: default;
}

.makerspace-dashboard-range-button[aria-busy="true"] {
  position: relative;
}

.makerspace-dashboard-range-button[aria-busy="true"]::after {
  content: '';
  border: 2px solid rgba(255, 255, 255, 0.5);
  border-top-color: #ffffff;
  border-radius: 50%;
  width: 14px;
  height: 14px;
  position: absolute;
  top: 50%;
  right: -22px;
  transform: translateY(-50%);
  animation: makerspace-dashboard-spin 0.6s linear infinite;
}

@keyframes makerspace-dashboard-spin {
  to {
    transform: translateY(-50%) rotate(360deg);
  }
}

.makerspace-dashboard-section canvas {
  display: block;
  width: 100% !important;
  height: auto !important;
}

.makerspace-dashboard-info {
  margin-bottom: 2rem;
  border: 1px solid #d0d7de;
  border-radius: 6px;
  background-color: #ffffff;
}

.makerspace-dashboard-info > summary {
  font-weight: 600;
}

.makerspace-dashboard-info .item-list {
  padding: 0.75rem 1.25rem 1rem;
}

.makerspace-dashboard-info .item-list ul {
  margin: 0;
}

.makerspace-dashboard-info .item-list li {
  margin-bottom: 0.35rem;
}

.makerspace-dashboard-summary {
  margin-bottom: 1.5rem;
}

.makerspace-dashboard-definition {
  margin-bottom: 1.5rem;
  font-size: 0.95rem;
  color: #475569;
}

.makerspace-dashboard-section .makerspace-dashboard-info + .chart,
.makerspace-dashboard-section .chart + .makerspace-dashboard-info {
  margin-top: 1rem;
}

.metric-container {
  background-color: #f8fafc;
  border: 1px solid #d0d7de;
  border-radius: 8px;
  padding: 1.25rem;
  margin-bottom: 2rem;
}

.metric-container h2 {
  margin-top: 0;
  margin-bottom: 1.5rem;
  font-size: 1.5rem;
}

.pie-chart-pair-container {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5rem;
  margin-bottom: 1.5rem;
}

.pie-chart-pair-container .chart {
  background-color: transparent;
  border: none;
  padding: 0;
  margin-bottom: 0;
}

.makerspace-dashboard-react-chart[data-chart-id="chargebee_plans"],
.makerspace-dashboard-react-chart[data-chart-id="payment_mix"] {
  max-width: 560px;
  margin-left: auto;
  margin-right: auto;
}

.metric-container .governance-comparison-table {
  margin-top: 1.5rem;
}

.data-source {
  margin-top: 1.5rem;
  font-size: 0.875rem;
  color: #64748b;
  text-align: right;
}

.kpi-table .kpi-progress {
  font-weight: 600;
}

.kpi-progress--good {
  color: #15803d;
}

.kpi-progress--warning {
  color: #d97706;
}

.makerspace-dashboard-location-map {
  position: relative;
  min-height: 360px;
  height: min(60vh, 520px);
  border: 1px solid #d0d7de;
  border-radius: 8px;
  overflow: hidden;
  margin-bottom: 2rem;
}

.makerspace-dashboard-location-notice {
  margin: 0;
  padding: 2rem;
  text-align: center;
  font-size: 0.95rem;
  color: #475569;
}

.makerspace-dashboard-location-map--empty {
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: #f8fafc;
}

.kpi-progress--poor {
  color: #b91c1c;
}

.kpi-table,
.kpi-annual-table,
.kpi-stoplight-table--sectioned {
  width: 100% !important;
  table-layout: fixed !important;
}

.kpi-table th:nth-child(1), .kpi-table td:nth-child(1),
.kpi-stoplight-table--sectioned th:nth-child(1), .kpi-stoplight-table--sectioned td:nth-child(1) { 
  width: 36% !important; 
}

.kpi-table th:nth-child(2), .kpi-table td:nth-child(2),
.kpi-stoplight-table--sectioned th:nth-child(2), .kpi-stoplight-table--sectioned td:nth-child(2) { 
  width: 12% !important; 
}

.kpi-table th:nth-child(3), .kpi-table td:nth-child(3),
.kpi-stoplight-table--sectioned th:nth-child(3), .kpi-stoplight-table--sectioned td:nth-child(3) { 
  width: 12% !important; 
}

.kpi-table th:nth-child(4), .kpi-table td:nth-child(4),
.kpi-stoplight-table--sectioned th:nth-child(4), .kpi-stoplight-table--sectioned td:nth-child(4) { 
  width: 10% !important; 
}

.kpi-table th:nth-child(5), .kpi-table td:nth-child(5),
.kpi-stoplight-table--sectioned th:nth-child(5), .kpi-stoplight-table--sectioned td:nth-child(5) { 
  width: 10% !important; 
}

.kpi-table th:nth-child(6), .kpi-table td:nth-child(6),
.kpi-stoplight-table--sectioned th:nth-child(6), .kpi-stoplight-table--sectioned td:nth-child(6) { 
  width: 20% !important; 
}

.kpi-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 1.5rem;
  margin-bottom: 1.5rem;
  padding: 0.75rem 1rem;
  background-color: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
}

.kpi-legend-item {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.85rem;
  font-weight: 600;
  color: #475569;
}

.kpi-legend-item .kpi-progress {
  width: 16px;
  height: 16px;
  padding: 0;
}

.kpi-overview-label-cell {
  display: grid;
  gap: 0.15rem;
  padding: 0.25rem 0;
}

.kpi-overview-label-cell .kpi-title {
  font-weight: 700;
  color: #111827;
  font-size: 0.92rem;
}

.kpi-overview-label-cell .kpi-description {
  font-size: 0.78rem;
  line-height: 1.3;
  color: #64748b;
  font-weight: 400;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.kpi-overview-label-cell:hover .kpi-description {
  -webkit-line-clamp: 10;
  overflow: visible;
}

/* KPI Value Prominence */
.kpi-value-big {
  font-size: 1.8rem !important;
  font-weight: 800 !important;
  line-height: 1.1;
}

.kpi-current-cell,
.kpi-goal-cell,
.kpi-details-cell {
  text-align: center !important;
  vertical-align: top !important;
  padding-top: 1rem !important;
}

.kpi-sparkline-cell {
  vertical-align: top !important;
  padding-top: 1rem !important;
}

/* Status Contrast Improvements */
.kpi-progress {
  padding: 0.25rem 0.75rem;
  border-radius: 6px;
  font-weight: 700;
  display: inline-block;
}

.kpi-progress--good {
  background-color: #dcfce7 !important;
  color: #166534 !important;
}

.kpi-progress--warning {
  background-color: #fef3c7 !important;
  color: #92400e !important;
}

.kpi-progress--poor {
  background-color: #b91c1c !important;
  color: #ffffff !important;
}

.kpi-progress--na {
  background-color: #f1f5f9 !important;
  color: #475569 !important;
}

.kpi-sparkline-label {
  font-size: 0.72rem;
  color: #94a3b8;
  margin-top: 0.2rem;
  text-transform: uppercase;
  letter-spacing: 0.02em;
  font-weight: 500;
}

/* Period label under the current value */
.kpi-period-label {
  font-size: 0.68rem;
  color: #94a3b8;
  margin-top: 0.15rem;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  font-weight: 500;
}

/* YTD accumulating badge */
.kpi-period-badge--ytd {
  display: inline-block;
  font-size: 0.62rem;
  font-weight: 700;
  color: #1e40af;
  background-color: #dbeafe;
  padding: 0.05rem 0.35rem;
  border-radius: 4px;
  margin-left: 0.3rem;
  vertical-align: middle;
  cursor: help;
}

/* Wrapper for current value + period label (block so label sits below badge) */
.kpi-value-cell {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.15rem;
}

.kpi-segment-list {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.25rem;
  margin-top: 0.2rem;
}

.kpi-goal-progress {
  margin-top: 0.28rem;
  width: min(140px, 92%);
}

.kpi-goal-progress__track {
  width: 100%;
  height: 6px;
  background: #e2e8f0;
  border-radius: 999px;
  overflow: hidden;
}

.kpi-goal-progress__fill {
  display: block;
  height: 100%;
  border-radius: 999px;
}

.kpi-goal-progress__fill.kpi-progress--good {
  background-color: #16a34a;
}

.kpi-goal-progress__fill.kpi-progress--warning {
  background-color: #d97706;
}

.kpi-goal-progress__fill.kpi-progress--poor {
  background-color: #b91c1c;
}

.kpi-goal-progress__fill.kpi-progress--na {
  background-color: #64748b;
}

.kpi-goal-progress__label {
  margin-top: 0.12rem;
  font-size: 0.63rem;
  line-height: 1.2;
  color: #64748b;
  text-transform: uppercase;
  letter-spacing: 0.02em;
}

.kpi-segment-chip {
  display: inline-flex;
  align-items: baseline;
  gap: 0.2rem;
  font-size: 0.7rem;
  color: #334155;
  background: #f1f5f9;
  border: 1px solid #cbd5e1;
  border-radius: 999px;
  padding: 0.08rem 0.45rem;
  white-space: nowrap;
}

.kpi-segment-chip__label {
  font-weight: 600;
}

.kpi-sparkline-wrapper {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.kpi-shared-tag {
  display: inline-flex;
  align-items: center;
  font-size: 0.7rem;
  color: #6366f1;
  background-color: #eef2ff;
  padding: 0.1rem 0.4rem;
  border-radius: 4px;
  margin-top: 0.3rem;
  font-weight: 600;
  width: fit-content;
}

.kpi-shared-tag::before {
  content: '⇄';
  margin-right: 0.3rem;
  font-size: 0.8rem;
}

/* Ensure annual table first column width matches */
.kpi-annual-table th:first-child,
.kpi-annual-table td:first-child {
  width: 45%;
}

.kpi-stoplight-table {
  margin-top: 1rem;
}

.kpi-stoplight-table td {
  vertical-align: middle;
}

.kpi-stoplight-cell {
  white-space: nowrap;
}

.kpi-stoplight-indicator {
  display: inline-block;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  margin-right: 0.4rem;
  background-color: #94a3b8;
}

.kpi-stoplight-indicator.kpi-progress--good {
  background-color: #15803d;
}

.kpi-stoplight-indicator.kpi-progress--warning {
  background-color: #d97706;
}

.kpi-stoplight-indicator.kpi-progress--poor {
  background-color: #b91c1c;
}

.kpi-stoplight-indicator.kpi-progress--na {
  background-color: #94a3b8;
}

.kpi-stoplight-text {
  font-weight: 600;
}

.kpi-goal-label {
  color: #64748b;
  font-size: 0.85em;
}

.overview-kpi-section-table {
  margin: 1.25rem 0;
}

.overview-kpi-section-table h3 {
  margin-bottom: 0.6rem;
}

.overview-kpi-section-link {
  margin-left: 0.5rem;
  font-size: 0.85rem;
  font-weight: 500;
}

.kpi-overview-label-cell {
  display: grid;
  gap: 0.25rem;
  padding: 0.25rem 0;
}

.kpi-overview-label-cell .kpi-title {
  font-weight: 700;
  color: #111827;
  font-size: 0.95rem;
}

.kpi-overview-label-cell .kpi-description {
  font-size: 0.82rem;
  line-height: 1.35;
  color: #64748b;
  font-weight: 400;
}

.kpi-overview-state {
  display: inline-block;
  width: fit-content;
  padding: 0.1rem 0.45rem;
  border-radius: 999px;
  font-size: 0.72rem;
  line-height: 1.4;
  border: 1px solid transparent;
}

.kpi-overview-state--dev {
  background: #fffbeb;
  color: #92400e;
  border-color: #fde68a;
}

.kpi-overview-more-link {
  font-size: 0.78rem;
}

.kpi-detail-link {
  white-space: nowrap;
}

@media (max-width: 900px) {
  .kpi-table,
  .kpi-annual-table {
    table-layout: auto;
  }
}

.overview-kpi-table-wrap {
  display: block;
  width: 100%;
  overflow-x: auto;
}

.overview-kpi-sections {
  display: grid;
  gap: 1rem;
  margin-top: 0.75rem;
}

.overview-kpi-section {
  border: 1px solid #dbe2ea;
  border-radius: 10px;
  background: #f8fafc;
  padding: 0.85rem;
}

.overview-kpi-section > h4 {
  margin: 0 0 0.75rem;
  font-size: 1rem;
  color: #1f2937;
}

.overview-kpi-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 0.75rem;
}

.overview-kpi-card {
  border: 1px solid #d7dee8;
  border-radius: 8px;
  background: #fff;
  padding: 0.75rem;
  display: grid;
  gap: 0.4rem;
}

.overview-kpi-card.kpi-progress--good {
  border-left: 4px solid #15803d;
}

.overview-kpi-card.kpi-progress--warning {
  border-left: 4px solid #d97706;
}

.overview-kpi-card.kpi-progress--poor {
  border-left: 4px solid #b91c1c;
}

.overview-kpi-card.kpi-progress--na {
  border-left: 4px solid #64748b;
}

.overview-kpi-card__title {
  font-size: 0.92rem;
  font-weight: 700;
  line-height: 1.3;
  color: #111827;
}

.overview-kpi-card__status {
  font-size: 0.85rem;
  font-weight: 600;
  color: #334155;
}

.overview-kpi-card__metrics {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.5rem;
}

.overview-kpi-card__current {
  font-size: 1.05rem;
  font-weight: 700;
  color: #0f172a;
}

.overview-kpi-card__goal,
.overview-kpi-card__trend {
  font-size: 0.8rem;
  color: #475569;
}

.overview-source-notes {
  font-size: 0.9rem;
}

@media (max-width: 640px) {
  .overview-kpi-grid {
    grid-template-columns: 1fr;
  }
}

.makerspace-dashboard-section .overview-stoplight .overview-kpi-table-wrap > table.kpi-stoplight-table.kpi-stoplight-table--sectioned {
  width: 100% !important;
  min-width: 100% !important;
  max-width: 100% !important;
  table-layout: fixed;
}

@media (max-width: 900px) {
  .makerspace-dashboard-section .overview-stoplight .overview-kpi-table-wrap > table.kpi-stoplight-table.kpi-stoplight-table--sectioned {
    min-width: 760px !important;
    max-width: none !important;
  }
}

.chart-tier {
  margin-bottom: 2rem;
}

.chart-tier--key {
  padding: 1rem 1.25rem;
  border: 1px solid #cfd7e6;
  border-radius: 10px;
  background: linear-gradient(180deg, #f5f8ff 0%, #f2f6fc 100%);
}

.chart-tier--key > .heading {
  margin-bottom: 1rem;
}

.chart-tier.chart-tier--supplemental,
.chart-tier.chart-tier--experimental {
  border: 1px solid #e2e8f0;
  border-radius: 6px;
  padding: 0.75rem 1rem 1rem;
  background-color: #ffffff;
  margin-bottom: 1.5rem;
}

.chart-tier.chart-tier--supplemental[open],
.chart-tier.chart-tier--experimental[open] {
  padding-bottom: 1.25rem;
}

.chart-tier summary {
  margin: 0 0 0.75rem;
  color: #475569;
  font-size: 1.15rem;
  font-weight: 600;
}

/* Keep chart-table headers readable regardless of theme table overrides. */
.makerspace-dashboard-section .metric-container table th,
.makerspace-dashboard-section .makerspace-dashboard-react-chart__table th {
  background: #475569 !important;
  color: #ffffff !important;
  text-shadow: none;
}

.makerspace-dashboard-section .metric-container table th a,
.makerspace-dashboard-section .makerspace-dashboard-react-chart__table th a {
  color: #ffffff !important;
}

.makerspace-dashboard-location-map-wrapper {
  position: relative;
}

.makerspace-dashboard-location-map-toggle {
  position: absolute;
  top: 1rem;
  right: 1rem;
  z-index: 401; /* Leaflet is 400 */
  display: flex;
  gap: 0.5rem;
}

.makerspace-dashboard-location-map-toggle .button {
  background-color: #fff;
  border: 1px solid #ccc;
  padding: 0.5rem 1rem;
  cursor: pointer;
  border-radius: 4px;
}

.makerspace-dashboard-location-map-toggle .button.active {
  background-color: #f0f0f0;
  font-weight: bold;
}

.makerspace-dashboard-location-map-info {
  padding: 0.75rem 0.5rem;
  font-size: 0.875rem;
  color: #475569;
  text-align: center;
}

.makerspace-dashboard-location-map-info p {
  margin: 0 0 0.5rem;
}

.makerspace-dashboard-location-map-info p:last-child {
  margin-bottom: 0;
}

.join-location-map__controls {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 0.75rem;
}

.join-location-map__button {
  border: 2px solid #cbd5f5;
  background-color: #fff;
  color: #0f172a;
  padding: 0.35rem 0.9rem;
  cursor: pointer;
  border-radius: 999px;
  font-size: 0.9rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: auto !important;
  min-width: 4.5rem;
  line-height: 1.1;
  text-align: center;
}

.join-location-map__button.active {
  color: #fff;
}

.join-location-map__wrapper {
  position: relative;
}

.join-location-map {
  position: relative;
}

.join-location-map.is-expanded {
  position: fixed;
  inset: 1.5rem;
  z-index: 1000;
  background: #fff;
  padding: 1.5rem;
  border-radius: 12px;
  box-shadow: 0 20px 60px rgba(15, 23, 42, 0.25);
  display: flex;
  flex-direction: column;
}

.join-location-map.is-expanded .join-location-map__controls {
  flex-wrap: wrap;
}

.join-location-map.is-expanded .join-location-map__canvas {
  height: calc(100vh - 12rem);
}

.join-location-map__actions {
  display: flex;
  justify-content: flex-end;
  margin-bottom: 0.75rem;
  gap: 0.5rem;
}

.join-location-map__actions .button {
  background-color: #0f172a;
  color: #fff;
  border: none;
  padding: 0.2rem 0.55rem;
  border-radius: 4px;
  cursor: pointer;
  font-size: 0.75rem;
}

.join-location-map__actions .button:hover {
  background-color: #1d2b50;
}

.join-location-map__canvas {
  position: relative;
  min-height: 360px;
  height: min(60vh, 520px);
  border: 1px solid #d0d7de;
  border-radius: 8px;
  overflow: hidden;
  margin-bottom: 2rem;
}

.join-location-map__control-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  align-items: flex-start;
  margin-bottom: 0.75rem;
}

.join-location-map__control-bar .join-location-map__controls {
  flex: 1 1 320px;
  margin-bottom: 0;
}

.join-location-map__summary {
  flex: 0 1 260px;
  margin: 0;
  color: #475569;
  font-size: 0.85rem;
}

.join-location-map__actions {
  flex: 0 0 auto;
  display: flex;
  align-items: flex-start;
}
.join-location-map__actions .button {
  background-color: #0f172a;
  color: #fff;
  border: none;
  padding: 0.4rem 0.85rem;
  border-radius: 6px;
  cursor: pointer;
  font-size: 0.85rem;
}

/* --- Mobile UI Enhancements --- */

@media (max-width: 600px) {
  .makerspace-dashboard-wrapper {
    padding: 1rem 0.5rem;
  }

  /* Improve KPI Table readability on very small screens */
  .kpi-table th, .kpi-table td,
  .kpi-stoplight-table--sectioned th, .kpi-stoplight-table--sectioned td {
    padding: 0.5rem 0.25rem !important;
    font-size: 0.85rem !important;
  }

  .kpi-value-big {
    font-size: 1.3rem !important;
  }

  .kpi-overview-label-cell .kpi-title {
    font-size: 0.85rem;
  }

  .kpi-overview-label-cell .kpi-description {
    display: none; /* Hide descriptions on mobile list to save space */
  }

  .kpi-table th:nth-child(1), .kpi-table td:nth-child(1),
  .kpi-stoplight-table--sectioned th:nth-child(1), .kpi-stoplight-table--sectioned td:nth-child(1) { 
    width: 50% !important; 
  }

  /* Hide Sparklines on mobile table to keep focus on numbers */
  .kpi-table th:nth-child(6), .kpi-table td:nth-child(6),
  .kpi-stoplight-table--sectioned th:nth-child(6), .kpi-stoplight-table--sectioned td:nth-child(6) { 
    display: none !important;
  }

  /* Expand other columns slightly since sparkline is gone */
  .kpi-table th:nth-child(2), .kpi-table td:nth-child(2),
  .kpi-table th:nth-child(3), .kpi-table td:nth-child(3),
  .kpi-table th:nth-child(4), .kpi-table td:nth-child(4),
  .kpi-table th:nth-child(5), .kpi-table td:nth-child(5) {
    width: 12.5% !important;
  }

  /* Adjust KPI Grid for 2 columns on mobile if space allows, or 1 if very tight */
  .overview-kpi-grid {
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: 0.5rem;
  }

  .overview-kpi-card {
    padding: 0.5rem;
  }

  .overview-kpi-card__title {
    font-size: 0.8rem;
  }

  .overview-kpi-card__current {
    font-size: 1.1rem;
  }

  /* Pie charts stack on mobile */
  .pie-chart-pair-container {
    grid-template-columns: 1fr;
  }
}

/* Ensure horizontal scrolling for tables when they exceed viewport */
.overview-kpi-table-wrap {
  -webkit-overflow-scrolling: touch;
}

/* Tabs scrolling improvements */
.makerspace-dashboard-tabs {
  -webkit-overflow-scrolling: touch;
  padding-left: 0.5rem;
  padding-right: 0.5rem;
  margin-left: -0.5rem;
  margin-right: -0.5rem;
}
