* { box-sizing: border-box; }
body {
  margin: 0; font-family: "Segoe UI", system-ui, -apple-system, sans-serif;
  background: linear-gradient(180deg, #0d2b45 0%, #12456b 100%);
  color: #eef6fb; min-height: 100vh;
}
header { padding: 18px 28px 4px; }
header h1 { margin: 0; font-size: 30px; letter-spacing: .5px; }
header .sub { margin: 6px 0 0; color: #bcd9ec; max-width: 900px; }
main {
  display: flex; gap: 22px; align-items: flex-start;
  padding: 16px 28px 8px; flex-wrap: wrap;
}
#stageWrap { position: relative; flex: 0 1 960px; }
#stage {
  width: 100%; height: auto; display: block;
  border-radius: 14px; border: 3px solid #f2c14e;
  box-shadow: 0 12px 40px rgba(0,0,0,.45); background: #8ec9e8;
}
#targetBanner {
  position: absolute; left: 50%; top: 22px; transform: translateX(-50%);
  background: #f2c14e; color: #40260a; font-weight: 700; font-size: 22px;
  padding: 10px 22px; border-radius: 999px; box-shadow: 0 6px 24px rgba(0,0,0,.4);
}
#panel {
  flex: 1 1 340px; max-width: 460px; min-width: 320px;
  background: rgba(255,255,255,.07); border: 1px solid rgba(255,255,255,.16);
  border-radius: 14px; padding: 16px 18px;
}
#intro h2 { margin: 2px 0 8px; font-size: 18px; }
#intro p { margin: 0 0 10px; line-height: 1.45; color: #dceef9; font-size: 14.5px; }
.controls { display: flex; flex-direction: column; gap: 9px; margin: 14px 0 10px; }
button {
  font-size: 16px; font-weight: 600; padding: 11px 14px; border-radius: 10px;
  border: 0; cursor: pointer; background: #f2c14e; color: #33200a;
}
button:hover:not(:disabled) { filter: brightness(1.07); }
button:disabled { opacity: .45; cursor: default; }
#btnDemo { background: #57b7d6; color: #08303f; }
#btnReset { background: #33526e; color: #dceef9; }
.chk { font-size: 14.5px; color: #dceef9; display: flex; gap: 8px; align-items: center; cursor: pointer; }
.status { font-size: 13.5px; color: #bcd9ec; margin: 4px 0; min-height: 18px; }
.status.err { color: #ff9d8a; }
.status.ok { color: #9fe8a9; }
.bigcount { text-align: center; margin: 12px 0 2px; }
.bigcount #repCount {
  font-size: 84px; font-weight: 800; line-height: 1; color: #fff;
  display: inline-block; transition: transform .12s ease;
}
.bigcount #repCount.pulse { transform: scale(1.13); color: #f2c14e; }
.bigcount .of { font-size: 30px; color: #9fc3da; font-weight: 600; margin-left: 8px; }
.progress { height: 12px; background: rgba(255,255,255,.14); border-radius: 999px; overflow: hidden; margin: 8px 0 14px; }
#progBar { height: 100%; width: 0%; background: linear-gradient(90deg, #57b7d6, #f2c14e); transition: width .25s ease; }
.readouts { display: grid; grid-template-columns: auto 1fr; gap: 5px 16px; margin: 0 0 12px; font-size: 15px; }
.readouts dt { color: #9fc3da; }
.readouts dd { margin: 0; font-weight: 600; }
#roFraming.good { color: #9fe8a9; }
#roFraming.bad { color: #ffc46b; }
#roState { color: #f2c14e; }
.fineprint { font-size: 13px; line-height: 1.5; color: #a9c8dd; margin: 0; }
footer { padding: 4px 28px 22px; color: #7fa6bf; font-size: 13px; max-width: 1100px; }
#cam { position: fixed; left: 0; bottom: 0; width: 4px; height: 4px; opacity: 0.01; pointer-events: none; }
