html, body {
  margin: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
  font-family: "Trebuchet MS", "Segoe UI", sans-serif;
  background: #f7f8fb;
}

#paper-bg {
  position: fixed;
  inset: 0;
  background:
    linear-gradient(to right, rgba(226, 74, 74, 0.30) 0, rgba(226, 74, 74, 0.30) 3px, transparent 3px) 72px 0 / 100% 100%,
    repeating-linear-gradient(
      to bottom,
      #fcfdff 0px,
      #fcfdff 29px,
      rgba(113, 169, 255, 0.42) 30px,
      #fcfdff 31px,
      #fcfdff 60px
    );
  z-index: -2;
}

canvas {
  display: block;
  position: fixed;
  inset: 0;
}

#ui {
  position: fixed;
  inset: 0;
  pointer-events: none;
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  padding: 16px;
  box-sizing: border-box;
}

.panel, .hint {
  background: rgba(255,255,255,0.72);
  border: 2px solid rgba(48, 81, 161, 0.23);
  border-radius: 16px;
  backdrop-filter: blur(4px);
  box-shadow: 0 8px 24px rgba(42, 62, 117, 0.12);
  color: #21335e;
}

.panel {
  padding: 14px 18px;
  max-width: 290px;
}

.panel h1 {
  margin: 0 0 8px;
  font-size: 22px;
  letter-spacing: 1px;
}

.panel p {
  margin: 4px 0;
  font-size: 14px;
}

.stats {
  margin-top: 12px;
  display: grid;
  gap: 6px;
}

.hint {
  align-self: flex-end;
  padding: 12px 16px;
  font-size: 14px;
}
