*,*::before,*::after { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  font-family: "Helvetica Neue", -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, Arial, sans-serif;
  background: #f7f6f2;
  color: #1f1f1d;
  line-height: 1.5;
  padding: 24px 16px 60px;
}
.container { max-width: 1100px; margin: 0 auto; }

header { margin-bottom: 18px; }
h1 { font-size: clamp(22px, 3vw, 30px); margin: 0 0 6px; font-weight: 600; }
.subtitle { color: #5f5e5a; font-size: 14px; margin: 0; max-width: 720px; }

.info-banner {
  background: #fff;
  border: 1px solid #e5e3da;
  border-left: 3px solid #1d9e75;
  border-radius: 6px;
  padding: 10px 14px;
  margin-bottom: 22px;
  font-size: 13px;
  color: #444441;
}
.info-banner strong { color: #1f1f1d; font-weight: 600; }

.main-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
  margin-bottom: 18px;
}
@media (min-width: 800px) {
  .main-grid { grid-template-columns: 1fr 320px; }
}

.diagram-area {
  background: #e6f2ed;
  border: 1px solid #c0dccf;
  border-radius: 10px;
  padding: 16px;
}
#plant-svg {
  width: 100%;
  height: auto;
  display: block;
}

.readout-panel {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.readout-big {
  background: #fff;
  border: 1px solid #e5e3da;
  border-radius: 10px;
  padding: 18px 20px;
  text-align: center;
}
.readout-big .readout-label {
  font-size: 11px;
  color: #5f5e5a;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  font-weight: 600;
  margin-bottom: 8px;
}
.readout-big .readout-value {
  font-size: 28px;
  font-weight: 600;
  color: #1d9e75;
  font-variant-numeric: tabular-nums;
  line-height: 1.1;
}
.readout-big .readout-value .unit {
  font-size: 12px;
  color: #5f5e5a;
  font-weight: 500;
  display: block;
  margin-top: 4px;
}
.readout-big .readout-value.negative { color: #d50000; }
.readout-status {
  margin-top: 8px;
  font-size: 13px;
  font-weight: 500;
  color: #5f5e5a;
}

.bar-section {
  background: #fff;
  border: 1px solid #e5e3da;
  border-radius: 10px;
  padding: 14px 18px;
}
.bar-row {
  display: grid;
  grid-template-columns: 90px 1fr 50px;
  gap: 10px;
  align-items: center;
  margin-bottom: 10px;
}
.bar-row:last-child { margin-bottom: 0; }
.bar-name {
  font-size: 12px;
  font-weight: 500;
  color: #1f1f1d;
}
.bar-track {
  background: #f0eee5;
  border-radius: 4px;
  height: 10px;
  overflow: hidden;
}
.bar-fill {
  height: 100%;
  border-radius: 4px;
  transition: width 0.3s;
}
.bar-fill.green { background: #1d9e75; }
.bar-fill.red { background: #d50000; }
.bar-value {
  font-size: 12px;
  font-weight: 600;
  text-align: right;
  font-variant-numeric: tabular-nums;
  color: #1f1f1d;
}

.controls-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 12px;
  margin-bottom: 18px;
}
.control {
  background: #fff;
  border: 1px solid #e5e3da;
  border-radius: 10px;
  padding: 14px 18px;
}
.control label {
  font-size: 13px;
  font-weight: 500;
  margin-bottom: 8px;
  display: block;
}
.control input[type=range] {
  width: 100%;
  accent-color: #1d9e75;
}
.value-row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin-top: 4px;
}
.value-display {
  font-size: 16px;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
}
.hint {
  font-size: 11px;
  color: #888780;
}

.explanations {
  background: #fff;
  border: 1px solid #e5e3da;
  border-radius: 10px;
  padding: 18px 22px;
}
.explanations h2 { font-size: 16px; margin: 0 0 14px; font-weight: 600; }
.exp-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
}
@media (min-width: 600px) {
  .exp-grid { grid-template-columns: 1fr 1fr; }
}
.exp-box {
  padding: 12px 14px;
  background: #f4faf7;
  border-left: 3px solid #1d9e75;
  border-radius: 4px;
}
.exp-box h3 {
  font-size: 13px;
  margin: 0 0 6px;
  font-weight: 600;
  color: #04342c;
}
.exp-box p {
  margin: 0;
  font-size: 13px;
  line-height: 1.6;
  color: #1f1f1d;
}

footer {
  margin-top: 36px;
  padding-top: 18px;
  border-top: 1px solid #e5e3da;
  font-size: 12.5px;
  color: #5f5e5a;
  line-height: 1.6;
}
footer .brand { font-weight: 600; color: #1f1f1d; }
