@import url("https://fonts.googleapis.com/css2?family=Space+Grotesk:wght@500;700&family=IBM+Plex+Mono:wght@500;600&family=Baloo+2:wght@600;700&display=swap");

:root {
  --navy: #14213d;
  --ink: #0b0f1a;
  --gold: #f2a93b;
  --cream: #fbf8f2;
  --white: #ffffff;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  background: #e7e2d6;
  font-family: "IBM Plex Mono", monospace;
  color: var(--ink);
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 32px 16px 64px;
  gap: 20px;
}

h1 {
  font-family: "Space Grotesk", sans-serif;
  font-weight: 700;
  font-size: 22px;
  letter-spacing: 0.02em;
  color: var(--navy);
  margin: 8px 0 0;
}

.sub {
  font-size: 13px;
  color: #5a5648;
  margin-top: -12px;
  text-align: center;
}

#stage {
  box-shadow: 0 12px 32px rgba(20, 33, 61, 0.18);
  border-radius: 12px;
  overflow: hidden;
  line-height: 0;
}

canvas {
  display: block;
  width: min(80vw, 420px);
  height: min(80vw, 420px);
}

.controls {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  justify-content: center;
}

button {
  font-family: "IBM Plex Mono", monospace;
  font-weight: 600;
  font-size: 13px;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  border: none;
  border-radius: 8px;
  padding: 12px 20px;
  cursor: pointer;
  transition:
    transform 0.08s ease,
    opacity 0.15s ease;
}

button:active {
  transform: scale(0.97);
}

#downloadBtn {
  background: var(--navy);
  color: var(--white);
}

#shuffleBtn {
  background: var(--gold);
  color: var(--navy);
}

#copyBtn {
  background: transparent;
  color: var(--navy);
  border: 1.5px solid var(--navy);
}

.note {
  font-size: 11px;
  color: #7a7666;
  max-width: 360px;
  text-align: center;
  line-height: 1.5;
}

.toast {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%) translateY(20px);
  background: var(--navy);
  color: var(--white);
  font-family: "IBM Plex Mono", monospace;
  font-size: 13px;
  padding: 10px 18px;
  border-radius: 8px;
  opacity: 0;
  pointer-events: none;
  transition:
    opacity 0.2s ease,
    transform 0.2s ease;
}

.toast.show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}
