/* sandire.ruykin.com: the stall at sunrise. Every frame on the page is a painting from the
   game (slate, tin sign, blue plank, enamel plate), never a drawn box. */
:root {
  --ink: #f4f1e8;
  --dim: #cfccbe;
  --gold: #f2c66b;
  --navy: #0e1a33;
  --red: #7a1a10;
  --page: #0e1a33;
}
* { box-sizing: border-box; }
html { background: var(--page); }
body {
  margin: 0;
  color: var(--ink);
  font: 18px/1.55 "Mukta", system-ui, sans-serif;
  background: transparent;   /* the painted market shows through (html carries the colour) */
  min-height: 100vh;
}
a { color: var(--gold); }
img { max-width: 100%; display: block; }

/* the market behind everything, dimmed so text on slate stays the focus */
.market {
  position: fixed; inset: 0; z-index: -1;
  background: url(img/sunrise.webp) center / cover no-repeat;
  filter: brightness(.45) saturate(.9);
}

.wrap { width: min(1080px, 100% - 32px); margin: 0 auto; }

/* signboard lettering: cream with a red drop, as on the game's tin signs */
.sign {
  font-family: "Yatra One", serif;
  color: #fff4dc;
  text-shadow: 0 .07em 0 var(--red);
  letter-spacing: .01em;
  font-weight: 400;
}
.chalk { font-family: "Kalam", cursive; }

/* ------------------------------------------------------------------ hero */
.hero {
  display: grid;
  grid-template-columns: 1.1fr .9fr;
  align-items: center;
  gap: 24px;
  padding: 56px 0 24px;
}
.hero .wordmark { width: min(520px, 100%); }
.hero .lede { font-family: "Kalam", cursive; font-size: 26px; line-height: 1.35; margin: 18px 0 26px; max-width: 30ch; }
.plate { position: relative; width: min(440px, 100%); aspect-ratio: 1; margin: 0 auto; }
.plate > img { position: absolute; }
.plate .dish { inset: 0; width: 100%; top: 6%; }
.plate .f { width: 30%; transition: transform .25s ease; }
.plate .f:hover { transform: translateY(-6px) rotate(var(--r, 0deg)); }

/* the tin sign as a button */
.tin {
  display: inline-block;
  border: 22px solid transparent;
  border-image: url(img/tin.webp) 44 fill / 22px stretch;
  padding: 4px 18px 8px;
  font-family: "Yatra One", serif;
  font-size: 24px;
  color: #fff4dc;
  text-shadow: 0 2px 0 var(--red);
  text-decoration: none;
}
.tin small { display: block; font: 15px "Kalam", cursive; color: #ffe6cc; text-shadow: none; margin-top: -4px; }

/* ------------------------------------------------------------------ slates */
.slate {
  border: 44px solid transparent;
  border-image: url(img/slate.webp) 88 fill / 44px stretch;
  padding: 14px 22px 16px;
  margin: 28px 0;
}
.slate h2 { font-size: 34px; margin: 0 0 8px; }
.slate p { margin: 0 0 12px; }
.slate .chalk { font-size: 20px; color: var(--dim); }

.rules {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px 26px;
  margin-top: 18px;
}
.rule { display: grid; grid-template-columns: 64px 1fr; gap: 12px; align-items: start; }
.rule img { width: 64px; height: 64px; object-fit: contain; }
.rule b { display: block; font-family: "Yatra One", serif; font-weight: 400; color: var(--gold); font-size: 19px; }
.rule span { font-size: 16px; color: var(--dim); line-height: 1.4; }

/* ------------------------------------------------------------------ screenshots */
.shots {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 18px;
  margin: 8px 0 0;
}
.shots figure { margin: 0; }
.shots img { border-radius: 18px; box-shadow: 0 10px 28px rgba(0, 0, 0, .55); }
.shots figcaption { font-family: "Kalam", cursive; color: var(--dim); text-align: center; margin-top: 8px; font-size: 17px; }

/* ------------------------------------------------------------------ the counter: customers */
.customers { display: flex; gap: 18px; flex-wrap: wrap; margin-top: 10px; }
.customer { display: flex; gap: 12px; align-items: center; flex: 1 1 280px; }
.customer img { width: 76px; height: 76px; border-radius: 50%; border: 5px solid #c8352a; background: #f3ecdf; object-fit: cover; }
.customer q { font-family: "Kalam", cursive; font-size: 18px; line-height: 1.35; }
.customer b { display: block; color: var(--gold); font-family: "Kalam", cursive; font-weight: 700; }

/* ------------------------------------------------------------------ fair play */
.fair { list-style: none; padding: 0; margin: 8px 0 0; display: grid; gap: 8px; }
.fair li { padding-left: 30px; position: relative; }
.fair li::before {
  content: ""; position: absolute; left: 0; top: .3em; width: 20px; height: 20px;
  background: url(img/star.webp) center / contain no-repeat;
}

/* ------------------------------------------------------------------ the blue plank footer */
.plank {
  display: flex; flex-wrap: wrap; gap: 6px 22px; justify-content: center; align-items: center;
  border: 26px solid transparent;
  border-image: url(img/plank.webp) 52 fill / 26px stretch;
  margin: 40px auto 32px;
  width: fit-content;
  max-width: 100%;
  padding: 2px 10px 6px;
  color: var(--navy);
  font-family: "Kalam", cursive;
  font-size: 18px;
}
.plank a { color: var(--navy); font-weight: 700; }

/* ------------------------------------------------------------------ text pages */
.article .slate { margin-top: 24px; }
.article h1 { font-size: 42px; margin: 0 0 4px; }
.article h2 { font-family: "Yatra One", serif; font-weight: 400; color: var(--gold); font-size: 22px; margin: 26px 0 6px; }
.article p, .article li { color: var(--ink); }
.article ul { padding-left: 22px; }
.article .dateline { font-family: "Kalam", cursive; color: var(--dim); margin: 0 0 8px; }
.topbar { display: flex; align-items: center; gap: 16px; padding: 22px 0 0; }
.topbar img { width: 190px; }
.topbar a { text-decoration: none; }

/* ------------------------------------------------------------------ phones */
@media (max-width: 860px) {
  .hero { grid-template-columns: 1fr; text-align: center; padding-top: 32px; }
  .hero .lede { margin-inline: auto; }
  .hero .wordmark { margin: 0 auto; }
  .rules { grid-template-columns: 1fr; }
  .shots { grid-template-columns: repeat(2, 1fr); }
  .slate { border-width: 30px; border-image-width: 30px; padding: 14px 14px 12px; }
  .plate { width: min(260px, 70%); }
  .slate h2 { font-size: 28px; }
  .article h1 { font-size: 34px; }
}
@media (prefers-reduced-motion: reduce) {
  .plate .f { transition: none; }
}
