:root {
  color-scheme: light;
  --bg: #f3f6f5;
  --panel: #ffffff;
  --text: #172126;
  --muted: #647178;
  --line: #d8e0df;
  --teal: #167875;
  --green: #24754a;
  --amber: #a45b16;
  --red: #a43636;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
body {
  margin: 0;
  min-width: 280px;
  background: var(--bg);
  color: var(--text);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

.masthead {
  min-height: 230px;
  display: flex;
  align-items: flex-end;
  background-color: #182124;
  background-image: url("/showroom-racks.webp");
  background-size: cover;
  background-position: center;
  color: #fff;
}
.masthead-inner {
  width: min(1180px, 100%);
  margin: 0 auto;
  padding: 42px 28px 38px;
  text-shadow: 0 1px 3px #000;
}
.eyebrow {
  margin: 0 0 8px;
  color: #b9d8d5;
  font-size: 12px;
  font-weight: 750;
  text-transform: uppercase;
}
h1, h2, p { margin: 0; }
h1 { font-size: 38px; line-height: 1.08; letter-spacing: 0; }
.summary { margin-top: 10px; color: #e3ebea; font-size: 15px; }

main { width: min(1180px, 100%); margin: 0 auto; padding: 0 28px 48px; }
.fleet-bar {
  min-height: 68px;
  display: grid;
  grid-template-columns: minmax(170px, auto) minmax(0, 1fr) auto;
  gap: 22px;
  align-items: center;
  margin-bottom: 26px;
  border-bottom: 1px solid var(--line);
}
.fleet-bar strong { margin-right: 6px; font-size: 22px; }
.fleet-bar span { color: var(--muted); font-size: 13px; }
.fleet-health { display: flex; align-items: center; gap: 8px; }
.fleet-health i {
  width: 9px;
  height: 9px;
  flex: 0 0 9px;
  border-radius: 50%;
  background: var(--amber);
}
.fleet-health i.online { background: var(--green); }
.fleet-health i.offline { background: var(--red); }
button, .open-device {
  min-height: 36px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fff;
  color: var(--text);
  font: inherit;
  font-weight: 700;
}
button { padding: 0 13px; cursor: pointer; }
button:hover { border-color: var(--teal); color: var(--teal); }

.section-head { display: flex; justify-content: space-between; gap: 18px; margin-bottom: 15px; }
h2 { font-size: 18px; letter-spacing: 0; }
.section-head p { margin-top: 5px; color: var(--muted); font-size: 12px; }
.device-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 14px;
}
.device-card {
  min-width: 0;
  display: grid;
  grid-template-rows: auto auto 1fr auto;
  gap: 14px;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: var(--panel);
  padding: 17px;
}
.device-head { display: flex; justify-content: space-between; gap: 14px; align-items: flex-start; }
.device-head h3 { margin: 0; font-size: 16px; overflow-wrap: anywhere; }
.device-head p { margin-top: 4px; color: var(--muted); font-size: 12px; overflow-wrap: anywhere; }
.online-pill {
  min-height: 24px;
  display: inline-flex;
  align-items: center;
  flex: 0 0 auto;
  border: 1px solid #acd0ba;
  border-radius: 5px;
  padding: 2px 7px;
  background: #f0f8f3;
  color: var(--green);
  font-size: 11px;
  font-weight: 750;
}
.device-model { color: var(--text); font-size: 13px; font-weight: 650; overflow-wrap: anywhere; }
.device-facts { display: grid; grid-template-columns: 1fr 1fr; gap: 8px 12px; }
.fact { min-width: 0; }
.fact span { display: block; color: var(--muted); font-size: 10px; text-transform: uppercase; }
.fact strong { display: block; margin-top: 3px; font-size: 12px; overflow-wrap: anywhere; }
.open-device {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 14px;
  background: var(--teal);
  border-color: var(--teal);
  color: #fff;
  text-decoration: none;
}
.open-device:hover { background: #0f6664; border-color: #0f6664; }
.empty-state {
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  padding: 34px 0;
}
.empty-state p { margin-top: 6px; color: var(--muted); font-size: 13px; }

@media (max-width: 680px) {
  .masthead { min-height: 205px; }
  .masthead-inner { padding: 34px 18px 28px; }
  h1 { font-size: 31px; }
  main { padding: 0 18px 36px; }
  .fleet-bar { grid-template-columns: 1fr auto; gap: 10px; padding: 12px 0; }
  .fleet-health { grid-column: 1 / -1; grid-row: 2; }
  .device-grid { grid-template-columns: 1fr; }
}
