:root {
  --ink: #162d38;
  --muted: #4d646c;
  --line: #ccd9d8;
  --teal: #00665f;
  font: 16px/1.5 Inter, system-ui, sans-serif;
  color: var(--ink);
  background: #f3f6f5;
}
* { box-sizing: border-box }
body { margin: 0 }
header { background: white; border-bottom: 1px solid var(--line) }
header nav, main { max-width: 75rem; margin: auto; padding: 1rem clamp(1rem,4vw,3rem) }
header nav, .links, .sections, .report-toolbar, .report-toolbar form, .axis {
  display: flex; align-items: center; gap: 1rem; flex-wrap: wrap;
}
.brand { display: inline-flex; align-items: center; gap: .5rem; margin-right: auto; color: var(--ink); font-weight: 800; font-size: 1.15rem; text-decoration: none }
.brand span { padding-left: .6rem; border-left: 1px solid var(--line); font-weight: 500; color: var(--muted) }
header nav > a:not(.brand), .quiet { font-size: .9rem }
main { padding-top: clamp(1.5rem,4vw,3rem); padding-bottom: 4rem }
h1, h2, h3 { line-height: 1.2 }
h1 { margin: 0 0 1rem; font-size: clamp(2rem,4vw,3.25rem); letter-spacing: -.045em }
h2 { margin: 0 0 1rem; font-size: 1.25rem; letter-spacing: -.02em }
h3 { font-size: 1rem }
a { color: var(--teal); text-underline-offset: .22em }
.sections { gap: .4rem 1.3rem; border-bottom: 1px solid var(--line); padding: .15rem 0 .85rem }
.sections a { color: var(--ink); text-decoration: none; font-weight: 600; font-size: .9rem }
.sections a:hover, header a:hover { text-decoration: underline }
section, .panel { min-width: 0; background: white; padding: clamp(1rem,2.3vw,1.7rem); border: 1px solid var(--line); border-radius: 14px; margin: 1rem 0; scroll-margin-top: 1rem }
.narrow { max-width: 34rem; margin: auto }
.overview { background: linear-gradient(112deg,#173944,#0d4644); color: white; border: 0 }
.overview .report-toolbar h2 { font-size: 1.5rem }
.report-toolbar,.axis { justify-content: space-between }
.report-toolbar h2 { margin: 0 }
.report-toolbar label { font-size: .85rem }
.report-toolbar input { width: auto }
.overview button { background: #c1eee0; color: #143d35 }
.metrics { display: grid; grid-template-columns: repeat(4,minmax(0,1fr)); gap: 1rem; margin-top: 1.7rem }
.metrics section { border: 0; border-left: 2px solid #699691; background: transparent; border-radius: 0; margin: 0; padding: 0 0 0 .9rem }
.metrics h3 { color: #d1e4df; font-weight: 500; font-size: .88rem; margin: 0 0 .4rem }
.metrics strong { font-size: clamp(1.6rem,3vw,2.5rem); line-height: 1.1; font-variant-numeric: tabular-nums; overflow-wrap: anywhere }
.billing-metric strong { color: #aeeacf }
.chart { height: 9rem; display: flex; align-items: flex-end; gap: 3px; margin-top: 1rem; border-bottom: 1px solid var(--line); background: repeating-linear-gradient(to top,transparent 0 31px,#edf2f1 31px 32px) }
.chart div { flex: 1; background: #167a72; border-radius: 3px 3px 0 0 }
.axis { color: var(--muted); font-size: .8rem; margin-bottom: .75rem }
.empty { background: #f3f7f6; border-left: 3px solid #83afa4; padding: 1.25rem }
.grid,#address-picker { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 1rem }
.grid section { margin: 0 }
label, dt { display: block; font-weight: 650 }
input,select { font: inherit; min-width: 0; width: 100%; border: 1px solid #879b9c; background: white; color: var(--ink); padding: .55rem .75rem; border-radius: 7px }
select { margin-top: .4rem }
.flat-list { grid-column: 1/-1 }
.chips { display: flex; flex-wrap: wrap; gap: .4rem; margin-top: .4rem }
.chips span { background: #e9f5ef; border: 1px solid #c1dbcf; color: #245944; border-radius: 6px; padding: .22rem .7rem; font-variant-numeric: tabular-nums }
button,.button { display: inline-block; font: inherit; font-weight: 650; padding: .6rem 1rem; color: white; background: var(--teal); border: 0; border-radius: 7px; cursor: pointer; text-decoration: none }
.quiet { background: #eef3f2; color: var(--ink) }
small,.helptext { display: block; color: var(--muted) }
.error,.errorlist { color: #953333 }
pre { overflow: auto; border-radius: 8px; background: #152f39; color: white; padding: 1rem }
code,samp { overflow-wrap: anywhere }
.secret { border-left: 3px solid var(--teal); padding: 1rem; background: #eff8f4 }
dd { margin: .2rem 0 1rem }
:focus-visible { outline: 3px solid #dc921c; outline-offset: 3px }
[hidden] { display: none !important }
@media (max-width: 650px) {
  header nav { gap: .5rem .8rem }
  .brand { font-size: 1rem }
  .metrics { grid-template-columns: 1fr 1fr; gap: 1.4rem .75rem }
  .grid,#address-picker { grid-template-columns: 1fr }
  .report-toolbar form { gap: .5rem }
  .report-toolbar label { width: 100% }
}

#report-message:empty { display: none }
#report-message { font-weight: 600 }
#month-filter { display: grid; grid-template-columns: minmax(0,1fr) auto; column-gap: .55rem; row-gap: .25rem; align-items: stretch }
#month-filter label { grid-column: 1 / -1; color: #d1e4df }
#month-filter input { width: 100%; min-height: 44px }
#month-filter button { min-width: 5.25rem; min-height: 44px }
.sections a { display: inline-flex; align-items: center; min-height: 44px }
.overview [tabindex="-1"]:focus:not(:focus-visible) { outline: none }
@media (max-width: 650px) {
  #usage .report-toolbar { display: grid; gap: .9rem; grid-template-columns: minmax(0,1fr) }
  .sections { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: .3rem; padding-bottom: .6rem }
  .sections a { justify-content: center; background: white; border: 1px solid var(--line); border-radius: 7px }
}
