:root {
  color-scheme: light;
  --bg: #f3f5f2;
  --panel: #ffffff;
  --ink: #1f2523;
  --muted: #626d68;
  --line: #d9dfd8;
  --temp: #c84732;
  --rain: #2368a2;
  --ok: #2c7452;
  --warn: #9a5c13;
  --shadow: 0 18px 40px rgba(31, 37, 35, 0.1);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-width: 320px;
  background: var(--bg);
  color: var(--ink);
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

.page {
  width: min(1120px, calc(100% - 32px));
  margin: 0 auto;
  padding: 34px 0 42px;
}

.page-header {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 22px;
}

.eyebrow,
.metric-label,
.metric-meta,
.chart-heading span,
.status {
  margin: 0;
  color: var(--muted);
  font-size: 0.88rem;
}

.eyebrow {
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-weight: 700;
}

h1 {
  margin: 2px 0 0;
  font-size: clamp(2.4rem, 8vw, 5.2rem);
  line-height: 0.95;
  letter-spacing: 0;
}

.status {
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.74);
  border-radius: 8px;
  padding: 9px 12px;
  white-space: nowrap;
}

.status.ok {
  color: var(--ok);
}

.status.warn {
  color: var(--warn);
}

.current-grid,
.chart-grid {
  display: grid;
  gap: 16px;
}

.current-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin-bottom: 16px;
}

.chart-grid {
  grid-template-columns: 1fr;
}

.metric-card,
.chart-panel {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.metric-card {
  min-height: 156px;
  padding: 22px;
}

.metric-value {
  display: flex;
  align-items: baseline;
  gap: 8px;
  margin: 10px 0 6px;
  font-variant-numeric: tabular-nums;
}

.metric-value span:first-child {
  font-size: clamp(2.6rem, 10vw, 5rem);
  line-height: 0.9;
  font-weight: 750;
}

.metric-unit {
  color: var(--muted);
  font-size: 1.05rem;
  font-weight: 700;
}

.chart-panel {
  padding: 18px;
}

.chart-heading {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 10px;
}

h2 {
  margin: 0;
  font-size: 1.18rem;
  letter-spacing: 0;
}

canvas {
  display: block;
  width: 100%;
  height: 320px;
}

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

@media (max-width: 720px) {
  .page {
    width: min(100% - 20px, 1120px);
    padding-top: 22px;
  }

  .page-header {
    align-items: start;
    flex-direction: column;
  }

  .metric-card {
    min-height: 136px;
  }

  canvas {
    height: 250px;
  }
}
