:root {
  --pine: #173e32;
  --stone: #f6f2e8;
  --sage: #8e9e7b;
  --ochre: #c89a47;
  --ink: #24352d;
  --muted: #51665a;
  --rule: #cad0bf;
}
* { box-sizing: border-box; }
body { margin: 0; background: var(--stone); color: var(--ink); font: 1rem/1.65 system-ui, sans-serif; }
header, main, footer { width: min(88%, 78rem); margin-inline: auto; }
header, nav { display: flex; align-items: center; flex-wrap: wrap; }
header { justify-content: space-between; gap: 1rem; padding-block: 1.8rem; border-bottom: 1px solid var(--rule); }
nav { gap: clamp(1.1rem, 3vw, 2.5rem); }
a { color: var(--pine); text-underline-offset: .35em; }
a:focus-visible, button:focus-visible { outline: 3px solid var(--pine); outline-offset: 4px; }
.brand, .footer-brand, nav a, .journal-item { text-decoration: none; }
.brand { font-size: 1.75rem; letter-spacing: -.065em; font-weight: 650; line-height: 1.2; }
.brand span { font-weight: 450; }
nav a { display: inline-flex; align-items: center; min-height: 44px; font-size: .95rem; }
nav a:hover, nav a[aria-current], .journal-item:hover h2 { text-decoration: underline; }
.hero { display: grid; grid-template-columns: 1fr 1fr; align-items: center; gap: clamp(2rem, 5vw, 5rem); padding-block: clamp(3rem, 8vw, 8rem); }
h1, h2 { color: var(--pine); font-family: Georgia, serif; font-weight: 400; line-height: 1.04; letter-spacing: -.045em; }
h1 { font-size: clamp(2.9rem, 5.7vw, 5.9rem); margin: 0; text-wrap: balance; }
h2 { font-size: clamp(1.75rem, 3.5vw, 3rem); margin: .35em 0; }
.intro { max-width: 36em; font-size: clamp(1.04rem, 1.6vw, 1.28rem); line-height: 1.65; color: var(--muted); }
.reading { max-width: 48rem; margin-inline: auto; min-height: 62vh; padding-block: clamp(2rem, 5vw, 5rem); }
.reading p { max-width: 42rem; }
.text-link, .journal-item { display: block; margin-top: 2rem; }
.journal-item { border-top: 1px solid var(--rule); padding-block: 1rem; }
.button { background: var(--pine); color: var(--stone); border-radius: 3px; padding: .85rem 1.5rem; font: inherit; }
footer { padding-block: 1.6rem; border-top: 1px solid var(--rule); }
.footer-brand { font-weight: 600; }

.landscape { position: relative; isolation: isolate; overflow: hidden; aspect-ratio: 1.42; background: #ece7d9; border-radius: 45% 45% 2px 2px / 22% 22% 2px 2px; }
.landscape > div { position: absolute; }
.sun { right: 18%; top: 13%; width: 13%; aspect-ratio: 1; background: var(--ochre); border-radius: 50%; }
.ridge { inset: 25% 0 0; }
.far { background: #b7bfa8; clip-path: polygon(0 27%,15% 18%,32% 27%,50% 38%,69% 24%,81% 11%,100% 21%,100% 100%,0 100%); }
.near { inset-block-start: 44%; background: var(--sage); clip-path: polygon(0 30%,24% 25%,60% 33%,83% 12%,100% 0,100% 100%,0 100%); }
.wing { bottom: 24%; left: 17%; width: 27%; height: 16%; background: #d4c3a5; }
.house { bottom: 24%; left: 39%; width: 42%; height: 24%; background: #ebddc4; }
.roof { bottom: 48%; left: 36%; width: 48%; height: 9%; background: #776b57; clip-path: polygon(17% 0,77% 0,100% 100%,0 100%); }
.lowroof { bottom: 40%; left: 15%; width: 25%; height: 6%; background: #8a775d; clip-path: polygon(19% 0,100% 0,100% 100%,0 100%); }
.shutters { bottom: 37%; left: 45%; width: 30%; height: 6%; background: repeating-linear-gradient(90deg,#4c6656 0 14%,transparent 14% 41%); }
.door { bottom: 24%; left: 57%; width: 6%; height: 9%; background: #647563; }
.field-drawing { float: right; width: min(30%, 12rem); margin: 0 0 1rem 1.5rem; }
.field-drawing .landscape { aspect-ratio: 1.85; border-radius: 0; background: transparent; }
.field-drawing .ridge { display: none; }
.field-drawing .house, .field-drawing .wing { background: var(--stone); border: 1px solid var(--pine); }
.field-drawing .roof, .field-drawing .lowroof { background: var(--pine); }
.field-drawing .ground { left: 5%; right: 4%; bottom: 24%; border-bottom: 1px solid var(--pine); }
.field-drawing .sun { width: 9%; top: 12%; }
@media (max-width: 720px) {
  .hero { grid-template-columns: 1fr; }
  .landscape { aspect-ratio: 1.85; }
  header { padding-block: 1rem; }
  .field-drawing { width: 28%; }
}

/* A static signal diagram. The plotted points are examples, not a live feed. */
.measurement-plate {
  min-width: 0;
  margin: 0;
  --plate-inset: clamp(1rem, 2.5vw, 2rem);
  overflow: hidden;
  border-radius: 4px;
  color: var(--stone);
  background: var(--pine);
}
.measurement-plate figcaption {
  display: grid;
  grid-template-columns: minmax(0, 2fr) minmax(0, 3fr);
  align-items: center;
  color: var(--pine);
  background: #ece7d9;
  font: 500 clamp(1.35rem, 2.6vw, 1.95rem)/1.08 system-ui, sans-serif;
  letter-spacing: -.025em;
}
.measurement-plate figcaption span { padding-left: var(--plate-inset); }
.measurement-plate .landscape {
  aspect-ratio: 2.05;
  border-radius: 0;
  mask-image: linear-gradient(to right, transparent, black 18%);
}
.measurement-description {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  clip-path: inset(50%);
  overflow: hidden;
}
.measurement-channels {
  position: relative;
  margin: 1.15rem var(--plate-inset) 0;
}
.energy-heading { color: var(--stone); font-weight: 550; }
.energy-legend { display: flex; flex-wrap: wrap; gap: .25rem 1.25rem; margin: .8rem 0 .55rem; font-size: .84rem; }
.energy-legend span { display: inline-flex; align-items: center; gap: .4rem; }
.energy-legend span::before { content: ""; width: 1rem; border-top: 2px solid var(--trace); }
.energy-legend .ev-trace::before { border-top-style: dashed; }
.solar-trace { --trace: #f2c568; }
.ev-trace { --trace: #cee8bd; }
.water-trace { --trace: #9ed5df; }
.energy-plot { display: grid; grid-template-columns: 3rem minmax(0, 1fr); grid-template-rows: minmax(0, 1fr); height: 6rem; }
.tank-plot { height: 3.8rem; }
.energy-scale, .energy-times, .measurement-link { color: #c3d0bc; font: .72rem/1 ui-monospace, monospace; }
.energy-scale { display: flex; flex-direction: column; justify-content: space-between; }
.energy-plot svg {
  display: block; min-height: 0; width: 100%; height: 100%; overflow: visible;
  background-image: linear-gradient(to right, #aec9ac30 1px, transparent 1px),
                    linear-gradient(to bottom, #aec9ac30 1px, transparent 1px);
  background-size: 25% 100%, 100% 50%;
  border-right: 1px solid #aec9ac30; border-bottom: 1px solid #aec9ac30;
}
.energy-plot path { fill: none; stroke: var(--trace); stroke-width: 2.5; stroke-linejoin: round; vector-effect: non-scaling-stroke; }
.energy-plot .ev-trace { stroke-dasharray: 5 2; }
.energy-times { position: relative; margin: .55rem 0 1rem 3rem; display: grid; grid-template-columns: repeat(4, 1fr) 0; }
.energy-times span { width: max-content; transform: translateX(-50%); }
.energy-times span:first-child { transform: none; }
.energy-times span:last-child { transform: translateX(-100%); }
.measurement-route {
  display: grid;
  grid-template-columns: auto minmax(2rem, 1fr) auto;
  align-items: center;
  gap: .65rem;
  margin: 0 var(--plate-inset);
  padding-block: 1rem;
  border-top: 1px solid #8e9e7b80;
}
.measurement-node {
  border: 1px solid #92a48d;
  border-radius: 3px;
  padding: .4rem .65rem;
  font-size: .88rem;
  line-height: 1.4;
}
.measurement-link { display: grid; gap: .3rem; text-align: center; }
.measurement-link::after {
  content: "";
  height: 7px;
  background: #d5ae65;
  clip-path: polygon(0 43%, 94% 43%, 94% 0, 100% 50%, 94% 100%, 94% 57%, 0 57%);
}
@media (max-width: 900px) {
  .measurement-node { padding-inline: .4rem; }
}
