/* Root wrapper */
.sma-wrap {
  max-width: 1200px;
  margin: 3rem auto;
  padding: 0 1.5rem;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "SF Pro Text", sans-serif;
  color: #111827;
}

/* Two-card grid */
.sma-grid {
  display: grid;
  grid-template-columns: minmax(0, 2.2fr) minmax(0, 1fr);
  gap: 2rem;
}

@media (max-width: 960px) {
  .sma-grid {
    grid-template-columns: 1fr;
  }
}

/* Card shell */
.sma-card {
  background: #ffffff;
  border-radius: 26px;
  box-shadow: 0 18px 45px rgba(15, 23, 42, 0.06);
  padding: 1.75rem 2rem 2rem;
}

/* Card header */
.sma-card-header {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin-bottom: 1.5rem;
}

.sma-card-title {
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  color: #111827;
}

.sma-card-subtitle {
  font-size: 0.75rem;
  color: #9ca3af;
}

/* Energy card layout: gauge + charts */
.sma-card-body-energy {
  display: grid;
  grid-template-columns: minmax(0, 2fr) minmax(0, 1.3fr);
  gap: 2rem;
  align-items: center;
}

@media (max-width: 960px) {
  .sma-card-body-energy {
    grid-template-columns: 1fr;
  }
}

/* Gauge block */
.sma-gauge {
  text-align: center;
}

.sma-gauge-svg {
  width: 100%;
  max-width: 420px;
  height: auto;
}

/* arc background and foreground */
.sma-gauge-arc-bg {
  fill: none;
  stroke: #edf1f6;
  stroke-width: 8;
  stroke-linecap: round;
}

.sma-gauge-arc {
  fill: none;
  stroke: #22456f;
  stroke-width: 8;
  stroke-linecap: round;
}

.sma-gauge-needle {
  stroke: #000;
  stroke-width: 0.8;
}

/* Gauge value */
.sma-gauge-value {
  margin-top: 1rem;
  font-size: 2rem;
  font-weight: 700;
  letter-spacing: 0.03em;
  color: #111827;
}

.sma-gauge-unit {
  margin-left: 0.25rem;
  font-size: 1rem;
  font-weight: 500;
  color: #6b7280;
}

.sma-gauge-footnote {
  margin-top: 0.25rem;
  font-size: 1.5rem;
  color: #9ca3af;
}

/* Mini charts column */
.sma-mini-col {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

/* Each row: label + value + chart */
.sma-mini-row {
  padding: 0.75rem 0.5rem;
  border-radius: 10px;
}

.sma-mini-header {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin-bottom: 0.4rem;
}

.sma-mini-title {
  font-size: 1rem;
  font-weight: 800;
  color: #6b7280;
}

.sma-mini-kpi {
  font-size: 0.9rem;
  font-weight: 600;
  color: #111827;
}

.sma-mini-chart {
  height: 20vh;
}

.sma-spark,
.sma-bar {
  width: 100%;
  height: 100%;
}

/* CO2 card */
.sma-card-body-co2 {
  display: flex;
  flex-direction: column;
  justify-content: center;
  height: 100%;
  padding-top: 1rem;
}

/* Today CO2 */
.sma-co2-main {
  margin-bottom: 2.5rem;
}

.sma-co2-today-value {
  font-size: 2.2rem;
  font-weight: 700;
  letter-spacing: 0.03em;
  color: #111827;
}

.sma-co2-unit {
  margin-left: 0.25rem;
  font-size: 1.1rem;
  font-weight: 600;
  color: #4b5563;
}

.sma-co2-today-label {
  margin-top: 0.25rem;
  font-size: 0.85rem;
  color: #9ca3af;
}

/* Total CO2 section */
.sma-co2-total {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 1.25rem;
}

.sma-co2-total-label {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.85rem;
  color: #9ca3af;
}

.sma-co2-total-line {
  display: inline-block;
  width: 24px;
  height: 2px;
  background: #9ca3af;
  border-radius: 999px;
}

.sma-co2-total-value {
  font-size: 1.1rem;
  font-weight: 600;
  color: #111827;
}

.sma-co2-total-unit {
  margin-left: 0.25rem;
  font-size: 0.85rem;
  color: #6b7280;
}

/* Small tweaks for WordPress themes (reduce conflicts) */
.sma-wrap canvas {
  display: block;
}

.sma-wrap small {
  font-size: 0.75em;
}
.mini-sma-widget{
  position: relative;          /* or absolute */
  left: 0.5rem;
  bottom: 0.5rem;

  transition:
    left .3s cubic-bezier(.65,.05,.36,1),
    bottom .3s cubic-bezier(.65,.05,.36,1);
}

.mini-sma-widget:hover{
  left: 1rem;
  bottom: 1rem;
}




