/* app.clod.farm: the clod.farm card, for signing up and your account. Two vendored OFL fonts, no framework. */
@font-face { font-family: "PressStart"; src: url("/fonts/PressStart2P.ttf") format("truetype"); font-display: swap; }
@font-face { font-family: "VT323"; src: url("/fonts/VT323.ttf") format("truetype"); font-display: swap; }

:root {
  --ink: #1f2a44;
  --paper: #f4f1e8;
  --paper-2: #e6e0cf;
  --clay: #b85a38;
  --clay-dark: #6b2f1f;
  --grass: #4f6b25;
  --grass-2: #5d7c2c;
  --ok: #2f6b3a;
  --bad: #a3322a;
  --muted: #5b6377;
  --shadow: rgba(18, 22, 12, .35);
  --font-px: "PressStart", ui-monospace, monospace;
  --font-body: "VT323", ui-monospace, monospace;
  color-scheme: light;
}
* { box-sizing: border-box; }
html, body { margin: 0; background: var(--grass); }
body {
  min-height: 100vh; color: var(--ink); font: 22px/1.25 var(--font-body); -webkit-font-smoothing: none;
}
/* the farm behind the page (farm.js, clodfarm's own renderer): the cards sit over it */
#world { position: fixed; inset: 0; width: 100vw; height: 100vh; display: block; z-index: 0; image-rendering: pixelated; image-rendering: crisp-edges; }
#labels { position: fixed; inset: 0; z-index: 1; pointer-events: none; overflow: hidden; }
.bubble {
  position: absolute; left: 0; top: 0; display: flex; align-items: center; gap: 6px; padding: 4px 6px;
  background: #e9eff3; border: 3px solid var(--ink); border-radius: 6px; box-shadow: 0 3px 0 rgba(0, 0, 0, .18);
  font: 9px/1.2 var(--font-px); white-space: nowrap;
}
.bubble::after {
  content: ""; position: absolute; bottom: -9px; left: calc(50% - 5px); width: 8px; height: 8px;
  background: #e9eff3; border-right: 3px solid var(--ink); border-bottom: 3px solid var(--ink); transform: skewY(40deg);
}
.bubble img { width: 24px; height: 24px; display: block; image-rendering: pixelated; }
.bubble.alert, .bubble.alert::after { background: #fde6df; }
.tag {
  position: absolute; left: 0; top: 0; font: 8px/1 var(--font-px); color: #fff; white-space: nowrap; opacity: .92;
  text-shadow: 1px 1px 0 #1b2410, -1px 1px 0 #1b2410, 1px -1px 0 #1b2410, -1px -1px 0 #1b2410;
}
.stage { position: relative; z-index: 2; min-height: 100vh; display: flex; flex-direction: column; align-items: center; padding: 32px 16px 48px; pointer-events: none; }
.stage > * { pointer-events: auto; }
.hero { width: 100%; max-width: 560px; display: flex; flex-direction: column; gap: 18px; }
.hook { font: 11px/1.6 var(--font-px); color: var(--clay); margin: -4px 0 10px; }
/* the start page: the farm first, then the card (narrow, so the barn and your Claude show beside it) */
body[data-app="start"] .hero { max-width: 470px; }
@media (max-width: 700px) { body[data-app="start"] .stage { padding-top: 38vh; } }
a { color: inherit; }
:focus-visible { outline: 3px solid #d97757; outline-offset: 3px; }

.brand { font: 14px/1 var(--font-px); color: #fff; text-decoration: none; text-shadow: 2px 2px 0 #1b2410; margin-bottom: 20px; }
.panel {
  width: 100%; max-width: 560px; padding: 24px 22px; background: var(--paper); border: 4px solid var(--ink); border-radius: 10px;
  box-shadow: inset 0 0 0 3px var(--paper), inset 0 0 0 5px var(--paper-2), 0 4px 0 var(--shadow);
}
.panel + .panel { margin-top: 0; }
h1 { font: 16px/1.5 var(--font-px); margin: 0 0 14px; }
h2 { font: 11px/1.5 var(--font-px); margin: 18px 0 8px; }
p { margin: 0 0 12px; }
.muted { color: var(--muted); }
.small { font-size: 19px; }
.price { font: 22px/1 var(--font-px); margin: 6px 0 14px; }
.price small { font: 20px var(--font-body); color: var(--muted); }
ul.list { margin: 0 0 14px; padding-left: 22px; }
ul.list li { margin: 2px 0; }

label { display: block; font: 10px/1.6 var(--font-px); margin: 14px 0 6px; }
.field { display: flex; align-items: stretch; border: 3px solid var(--ink); border-radius: 4px; background: #fff; }
.field input { flex: 1; min-width: 0; border: 0; padding: 10px 10px; font: 24px var(--font-body); color: var(--ink); background: transparent; }
.field input:focus { outline: none; }
.field:focus-within { outline: 3px solid #d97757; outline-offset: 2px; }
.field .suffix { padding: 10px 10px 10px 0; color: var(--muted); white-space: nowrap; }
.hint { min-height: 1.3em; font-size: 19px; margin: 6px 0 0; }
.hint.ok { color: var(--ok); }
.hint.bad, .error { color: var(--bad); }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 12px 16px; margin-top: 18px;
  font: 11px/1.2 var(--font-px); color: var(--ink); background: var(--paper); text-decoration: none; cursor: pointer;
  border: 3px solid var(--ink); border-radius: 4px; box-shadow: 0 4px 0 var(--ink);
}
.btn:hover { background: #fff; }
.btn:active { transform: translateY(3px); box-shadow: 0 1px 0 var(--ink); }
.btn.primary { background: var(--clay); color: #fff; border-color: var(--clay-dark); box-shadow: 0 4px 0 var(--clay-dark); }
.btn.primary:hover { background: #a44d2e; }
.btn[disabled] { opacity: .55; cursor: default; transform: none; }
.btn.wide { width: 100%; }
.row { display: flex; gap: 10px; flex-wrap: wrap; }
.row .btn { flex: 1 1 180px; }
.or { text-align: center; color: var(--muted); margin: 14px 0 0; }

.farm { border: 3px solid var(--ink); border-radius: 6px; padding: 12px 14px; margin-top: 12px; background: #fff; }
.farm .name { font: 12px/1.5 var(--font-px); word-break: break-all; }
.chip { display: inline-block; font: 8px/1 var(--font-px); padding: 5px 7px; border: 2px solid var(--ink); border-radius: 3px; margin-left: 6px; vertical-align: middle; }
.chip.active { background: #d9eed2; } .chip.starting, .chip.waiting { background: #fdf0c9; }
.chip.suspended, .chip.past_due { background: #fde0da; }

.steps { list-style: none; padding: 0; margin: 12px 0; }
.steps li { padding: 6px 0 6px 30px; position: relative; }
.steps li::before { content: "·"; position: absolute; left: 8px; }
.steps li.done::before { content: "✓"; color: var(--ok); }
.steps li.now::before { content: "▶"; color: var(--clay); }
.foot { margin-top: 22px; font-size: 18px; color: #fff; text-shadow: 1px 1px 0 #1b2410; text-align: center; max-width: 560px; }
.foot a { color: #fff; }

@media (max-width: 420px) {
  body { padding-top: 20px; font-size: 20px; }
  .panel { padding: 18px 14px; }
  h1 { font-size: 13px; }
  .field .suffix { display: none; }
}
@media (prefers-reduced-motion: reduce) { .btn:active { transform: none; } }

/* the one thing to click, like a game's PRESS START: it pulses, a shine sweeps across */
.why { font-size: 23px; margin-bottom: 14px; }
.center { text-align: center; }
.btn.call { position: relative; overflow: hidden; animation: call-pulse 1.2s ease-in-out infinite; font-size: 12px; padding: 16px 16px; }
.btn.call::after {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(105deg, transparent 35%, rgba(255, 255, 255, .5) 50%, transparent 65%) no-repeat;
  background-size: 250% 100%; animation: call-shine 2.4s ease-in-out infinite;
}
.btn.call:hover { animation-play-state: paused; }
.farm .name { text-decoration: none; }
.farm .name:hover { text-decoration: underline; }
@keyframes call-pulse { 0%, 100% { transform: translateY(0) scale(1); filter: brightness(1); } 50% { transform: translateY(-3px) scale(1.03); filter: brightness(1.12); } }
@keyframes call-shine { 0%, 55% { background-position: 150% 0; } 100% { background-position: -60% 0; } }
@media (prefers-reduced-motion: reduce) { .btn.call, .btn.call::after { animation: none; } }
