:root {
  color-scheme: light;
  --ink: #1e1f22;
  --paper: #f6f3ef;
  --accent: #ce4d32;
  --accent-2: #0c6a67;
  --border: #d7cfc6;
  --shadow: rgba(20, 18, 15, 0.12);
  --radius: 18px;
  --font-title: "Fraunces", "Iowan Old Style", "Palatino Linotype", serif;
  --font-body: "Work Sans", "Gill Sans", "Trebuchet MS", sans-serif;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--ink);
  background: radial-gradient(circle at top, #fffaf4 0%, #efe9e1 45%, #e5ddd3 100%);
}

.page {
  max-width: 1100px;
  margin: 0 auto;
  padding: 48px 24px 64px;
  display: flex;
  flex-direction: column;
  gap: 32px;
}

.hero {
  display: grid;
  gap: 12px;
}

.eyebrow {
  text-transform: uppercase;
  letter-spacing: 0.2em;
  font-size: 12px;
  color: var(--accent-2);
  margin: 0;
}

h1 {
  font-family: var(--font-title);
  font-size: clamp(32px, 5vw, 48px);
  margin: 0;
}

.lede {
  font-size: 16px;
  margin: 0;
  max-width: 720px;
}

.panel {
  background: #fffdf9;
  border-radius: var(--radius);
  padding: 24px;
  box-shadow: 0 18px 40px var(--shadow);
  border: 1px solid var(--border);
}

.panel.notes ul {
  padding-left: 20px;
}

.panel.notes li {
  margin-bottom: 8px;
}

.disclaimer {
  font-size: 13px;
  color: #6d6257;
}

.panel {
  display: grid;
  grid-template-columns: minmax(220px, 260px) 1fr;
  gap: 24px;
}

.controls {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.control,
.file {
  display: grid;
  gap: 6px;
  font-size: 14px;
}

.file input {
  margin-top: 6px;
}

input[type="range"] {
  width: 100%;
}

button {
  background: var(--accent);
  color: white;
  border: none;
  padding: 10px 14px;
  border-radius: 999px;
  font-weight: 600;
  cursor: pointer;
  box-shadow: 0 10px 20px rgba(206, 77, 50, 0.2);
}

button#centerBtn {
  background: var(--accent-2);
  box-shadow: 0 10px 20px rgba(12, 106, 103, 0.2);
}

.stats {
  font-size: 12px;
  color: #6c635b;
  margin: 0;
}

.canvas-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
}

.canvas-frame {
  width: min(90vw, 600px);
  aspect-ratio: 1 / 1;
  border-radius: 20px;
  border: 2px solid var(--border);
  background: #f2f0ec;
  position: relative;
  overflow: hidden;
  display: grid;
  place-items: center;
}

canvas {
  width: 100%;
  height: 100%;
  display: block;
}

#overlay {
  position: absolute;
  inset: 0;
  pointer-events: none;
}

.hint {
  margin: 0;
  font-size: 13px;
  color: #5b524a;
}

@media (max-width: 860px) {
  .panel {
    grid-template-columns: 1fr;
  }

  .controls {
    order: 2;
  }
}
