:root {
  color-scheme: light;
  --paper: #f3efe4;
  --card: #fffdf7;
  --ink: #171717;
  --muted: #68645b;
  --line: #c9c2b2;
  --soft: #e8e1d2;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-width: 280px;
  background: var(--paper);
  color: var(--ink);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

.page {
  width: min(100%, 620px);
  margin: 0 auto;
  padding: 28px 16px 44px;
}

.hero {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 20px;
}

.mark {
  display: grid;
  width: 58px;
  height: 66px;
  flex: 0 0 auto;
  place-items: center;
  border: 3px solid var(--ink);
  border-radius: 4px 4px 10px 4px;
  background: var(--card);
  font: 700 2.2rem/1 Georgia, serif;
  box-shadow: 5px 5px 0 var(--ink);
}

.eyebrow {
  margin: 0 0 2px;
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.15em;
  text-transform: uppercase;
}

h1 {
  margin: 0;
  font: 700 clamp(2rem, 10vw, 3rem)/1 Georgia, serif;
}

.lede {
  max-width: 32rem;
  margin: 8px 0 0;
  color: var(--muted);
  line-height: 1.45;
}

.card {
  padding: 20px;
  border: 2px solid var(--ink);
  border-radius: 10px;
  background: var(--card);
  box-shadow: 7px 7px 0 var(--ink);
}

fieldset {
  min-width: 0;
  margin: 0;
  padding: 0;
  border: 0;
}

.setting-group + .setting-group {
  margin-top: 24px;
  padding-top: 20px;
  border-top: 1px solid var(--line);
}

legend,
.preview-section h2 {
  margin: 0 0 12px;
  padding: 0;
  font-size: 1rem;
  font-weight: 800;
}

.choice {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 10px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
  cursor: pointer;
}

.choice:has(input:checked) {
  border-color: var(--ink);
  box-shadow: inset 0 0 0 1px var(--ink);
}

.choice input {
  width: 20px;
  height: 20px;
  flex: 0 0 auto;
  accent-color: var(--ink);
}

.choice span,
.choice strong,
.choice small {
  display: block;
}

.choice small {
  margin-top: 3px;
  color: var(--muted);
  line-height: 1.35;
}

.preview-section {
  margin-top: 24px;
}

#preview-watch {
  display: block;
  width: 100%;
  margin: 8px 0 20px;
  padding: 10px;
  font: inherit;
}

.preview-frame {
  text-align: center;
}

#watch-preview {
  box-sizing: content-box;
  display: inline-block;
  max-width: calc(100% - 16px);
  height: auto;
  border: 8px solid var(--ink);
  border-radius: 3px;
  background: white;
  image-rendering: pixelated;
}

#watch-preview[data-watch="gabbro"] {
  border-radius: 50%;
}

button {
  width: 100%;
  margin-top: 24px;
  padding: 13px 16px;
  border: 2px solid var(--ink);
  border-radius: 8px;
  background: var(--soft);
  color: var(--ink);
  font: inherit;
  font-weight: 800;
  cursor: pointer;
}

button.primary {
  background: var(--ink);
  color: #ffffff;
}

button:focus-visible,
.choice:focus-within {
  outline: 3px solid #5a84d6;
  outline-offset: 2px;
}

.status {
  min-height: 1.4em;
  margin: 12px 0 0;
  color: var(--muted);
  text-align: center;
  font-size: 0.9rem;
}

@media (max-width: 420px) {
  .page {
    padding: 20px 12px 36px;
  }

  .card {
    padding: 16px;
    box-shadow: 5px 5px 0 var(--ink);
  }
}

@supports not selector(:has(*)) {
  .choice {
    border-width: 2px;
  }
}

.preview-navigation { display: flex; align-items: center; gap: 12px; margin-top: 12px; }
.preview-navigation button { width: auto; margin: 0; padding: 8px; }
.preview-navigation span { flex: 1; text-align: center; }
.preview-navigation button:disabled { opacity: 0.4; cursor: default; }
