/* Hallmark · macrostructure: egg-stand counter · tone: playful · anchor hue: yolk
   pre-emit critique: P4 H4 E4 S5 R4 V4
   Going with: neighbours buying eggs · pay a dozen in pDAI · playful */
@import url("tokens.css");

*,
*::before,
*::after { box-sizing: border-box; }

html,
body {
  margin: 0;
  overflow-x: clip;
  background: var(--color-paper);
  color: var(--color-ink);
  font-family: var(--font-body);
  font-size: var(--text-body);
  line-height: 1.45;
}

body {
  min-height: 100vh;
  background:
    linear-gradient(180deg, var(--color-paper) 0 58%, var(--color-paper-2) 58% 100%);
}

img { max-width: 100%; display: block; }

a { color: var(--color-grass-deep); }

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

.sign {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-3) var(--space-5);
  margin: var(--space-4);
  padding: var(--space-4) var(--space-5);
  background: var(--color-sign);
  color: var(--color-egg);
  border-radius: 1.25rem 1.25rem 0.4rem 0.4rem;
  box-shadow: var(--shadow);
}

.sign h1 {
  margin: 0;
  font-family: var(--font-display);
  font-style: normal;
  font-weight: 400;
  font-size: var(--text-sign);
  line-height: 1.05;
  letter-spacing: 0.01em;
  overflow-wrap: anywhere;
  min-width: 0;
}

.sign nav {
  display: flex;
  gap: var(--space-4);
}

.sign a {
  color: var(--color-egg);
  font-weight: 800;
  text-decoration: none;
}

.sign a:hover { text-decoration: underline; }

.stand {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr);
  gap: var(--space-5);
  width: min(1120px, calc(100% - 2rem));
  margin: var(--space-5) auto var(--space-6);
  align-items: start;
}

.hero-shot {
  margin: 0;
  background: var(--color-egg);
  border-radius: var(--radius-egg);
  overflow: hidden;
  box-shadow: var(--shadow);
}

.hero-shot img {
  width: 100%;
  height: auto;
  aspect-ratio: 1;
  object-fit: cover;
}

.till {
  background: var(--color-egg);
  border-radius: var(--radius-card);
  padding: var(--space-5);
  box-shadow: var(--shadow);
}

.till h2 {
  margin: 0 0 var(--space-2);
  font-family: var(--font-display);
  font-style: normal;
  font-weight: 400;
  font-size: clamp(1.8rem, 4vw, 2.6rem);
  line-height: 1.1;
  overflow-wrap: anywhere;
}

.till .lede {
  margin: 0 0 var(--space-4);
  color: var(--color-ink-soft);
}

.price-aud {
  margin: 0;
  font-weight: 800;
}

.price-pdai {
  margin: var(--space-2) 0 var(--space-4);
  font-family: var(--font-display);
  font-style: normal;
  font-size: var(--text-display);
  line-height: 0.95;
  overflow-wrap: anywhere;
  color: var(--color-comb);
}

.price-pdai small {
  display: block;
  margin-top: var(--space-2);
  font-family: var(--font-body);
  font-size: var(--text-sm);
  font-weight: 700;
  color: var(--color-ink-soft);
}

.stepper {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  margin-bottom: var(--space-4);
}

.stepper button,
.pay {
  font-family: var(--font-body);
  font-weight: 800;
  border: 2px solid var(--color-ink);
  cursor: pointer;
}

.stepper button {
  width: 3rem;
  height: 3rem;
  border-radius: 999px;
  background: var(--color-paper);
  font-size: 1.4rem;
  line-height: 1;
}

.stepper button:hover,
.pay:hover { background: var(--color-yolk-deep); }

.stepper button:active,
.pay:active { transform: translateY(1px); }

.stepper button:disabled,
.pay:disabled {
  cursor: not-allowed;
  opacity: 0.55;
  transform: none;
}

.qty {
  min-width: 7.5rem;
  font-weight: 800;
}

.eggs {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  margin: 0 0 var(--space-4);
  padding: 0;
  list-style: none;
}

.eggs li {
  width: 1.35rem;
  height: 1.7rem;
  border-radius: 50% 50% 50% 50% / 40% 40% 60% 60%;
  background: var(--color-yolk);
  border: 2px solid var(--color-ink);
}

.pay {
  display: block;
  width: 100%;
  min-height: 3.25rem;
  padding: 0.75rem 1rem;
  border-radius: 999px;
  background: var(--color-yolk);
  color: var(--color-ink);
  font-size: 1.15rem;
  white-space: nowrap;
}

.pay[data-state="error"] { background: oklch(92% 0.04 25); }

.note,
.lock,
.alert {
  margin: var(--space-3) 0 0;
  font-size: var(--text-sm);
}

.alert { color: var(--color-comb); font-weight: 800; }

.lock { font-weight: 800; }

.fine {
  margin: var(--space-4) 0 0;
  color: var(--color-ink-soft);
  font-size: var(--text-sm);
}

.yard,
.flock,
.pickup {
  width: min(1120px, calc(100% - 2rem));
  margin: 0 auto var(--space-6);
}

.yard {
  margin: 0 0 var(--space-6);
  width: 100%;
}

.yard img {
  width: 100%;
  height: min(70vh, 640px);
  object-fit: cover;
  aspect-ratio: 16 / 9;
}

.flock h2,
.pickup h2 {
  margin: 0 0 var(--space-4);
  font-family: var(--font-display);
  font-style: normal;
  font-weight: 400;
  font-size: clamp(1.8rem, 4vw, 2.6rem);
  overflow-wrap: anywhere;
}

.cards {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: var(--space-4);
}

.cards figure {
  margin: 0;
  background: var(--color-egg);
  border-radius: var(--radius-card);
  overflow: hidden;
  box-shadow: var(--shadow);
}

.cards img {
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
  height: auto;
}

.cards figcaption {
  padding: var(--space-3) var(--space-4) var(--space-4);
  font-weight: 800;
}

.pickup p { max-width: 38rem; margin-top: 0; }

.foot {
  width: min(1120px, calc(100% - 2rem));
  margin: 0 auto;
  padding: 0 0 var(--space-7);
  color: var(--color-grass-deep);
  font-size: var(--text-sm);
  font-weight: 700;
}

.foot code {
  font-family: ui-monospace, Consolas, monospace;
  font-size: 0.85em;
  overflow-wrap: anywhere;
}

.thanks {
  width: min(720px, calc(100% - 2rem));
  margin: var(--space-6) auto var(--space-8);
  background: var(--color-egg);
  border-radius: var(--radius-card);
  padding: var(--space-6);
  box-shadow: var(--shadow);
}

.thanks h2 {
  margin: 0 0 var(--space-3);
  font-family: var(--font-display);
  font-style: normal;
  font-weight: 400;
  font-size: var(--text-sign);
  overflow-wrap: anywhere;
}

.thanks a.pay {
  display: inline-block;
  width: auto;
  margin-top: var(--space-4);
  text-decoration: none;
  text-align: center;
}

@media (max-width: 800px) {
  .stand { grid-template-columns: minmax(0, 1fr); }
  .till { order: -1; }
  .cards { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .yard img { height: auto; }
}

@media (prefers-reduced-motion: reduce) {
  .stepper button:active,
  .pay:active { transform: none; }
}
