/* The web Daily Page: the app's paper and ink (art bible §4), two OFL
   fonts, nothing remote. */
@font-face {
  font-family: "IM Fell SC";
  src: url("/fonts/IMFeENsc28P.ttf") format("truetype");
  font-display: swap;
}
@font-face {
  font-family: "Atkinson Next";
  src: url("/fonts/AtkinsonHyperlegibleNext.ttf") format("truetype");
  font-weight: 200 800;
  font-display: swap;
}

:root {
  --ink: #1F2A44;
  --ink-deep: #141B2D;
  --paper: #F3EAD7;
  --ivory: #FBF7EE;
  --brass: #6E5326;
  --amber: #E8B04A;
  --lilac: #5A5278;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: "Atkinson Next", system-ui, sans-serif;
  font-size: 18px;
  line-height: 1.45;
}

main, footer {
  max-width: 34rem;
  margin: 0 auto;
  padding: 1rem;
}

h1 {
  font-family: "IM Fell SC", Georgia, serif;
  font-weight: normal;
  font-size: 2.4rem;
  color: var(--brass);
  margin: 0.5rem 0 0;
}

h2 { font-size: 1.25rem; margin: 1.2rem 0 0.4rem; }

.sub { margin: 0 0 1rem; font-weight: 600; }
.note, .quiet { color: var(--lilac); }
.quiet { font-size: 0.95rem; }

button, a.primary {
  font: inherit;
  min-height: 48px;
  min-width: 48px;
  padding: 0.6rem 1.1rem;
  margin: 0.4rem 0.4rem 0.4rem 0;
  border: 2px solid var(--ink);
  border-radius: 8px;
  background: var(--ivory);
  color: var(--ink);
  cursor: pointer;
}

button.primary, a.primary {
  background: var(--ink);
  color: var(--ivory);
  display: inline-block;
  text-decoration: none;
}

button:focus-visible, a:focus-visible, canvas:focus-visible {
  outline: 3px solid var(--amber);
  outline-offset: 2px;
}

.board { margin-top: 0.8rem; }

canvas.pendulum {
  width: 100%;
  max-width: 340px;
  aspect-ratio: 340 / 230;
  display: block;
  background: var(--ivory);
  border: 1px solid var(--ink);
  border-radius: 8px;
  touch-action: manipulation;
}

.status { font-weight: 600; text-align: center; min-height: 1.5em; }

.plates {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(96px, 1fr));
  gap: 0.75rem;
}

button.plate {
  white-space: pre-line;
  min-height: 88px;
  margin: 0;
  font-size: 1rem;
}

button.plate.lit {
  background: var(--amber);
  border-color: var(--brass);
  border-width: 3px;
  color: var(--ink-deep);
  font-weight: 700;
}

button:disabled { cursor: default; }

.stamp {
  font-family: "IM Fell SC", Georgia, serif;
  font-size: 2.6rem;
  text-align: center;
  border: 3px solid var(--brass);
  border-radius: 8px;
  background: var(--ivory);
  padding: 1.5rem 0;
}

.tiers { padding-left: 1.2rem; }

pre.card {
  font-family: inherit;
  white-space: pre-wrap;
  background: var(--ivory);
  border: 1px solid var(--ink);
  border-radius: 8px;
  padding: 0.9rem;
}

.app {
  margin-top: 1.5rem;
  border-top: 2px dashed var(--brass);
  padding-top: 0.5rem;
}

footer { color: var(--lilac); font-size: 0.9rem; }

.sr-live {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
}
