/* The site's own pages (how-to-play, cards, support) in the game's Toy Box
   look: the link preview's sky, hills and purple button, Fredoka headings
   and Nunito text. The fonts are the game's own, already on the site. */

@font-face {
  font-family: "Fredoka";
  src: url("/assets/assets/fonts/Fredoka.ttf") format("truetype");
  font-weight: 300 700;
  font-display: swap;
}
@font-face {
  font-family: "Nunito";
  src: url("/assets/assets/fonts/Nunito.ttf") format("truetype");
  font-weight: 200 1000;
  font-display: swap;
}

:root {
  color-scheme: light;
  --sky-top: #8fd0ff;
  --sky-bottom: #e6f4ff;
  --hill: #7ccb6b;
  --hill-dark: #69b95a;
  --ink: #1d2b4a;
  --ink-soft: #3b4c6e;
  --muted: #5d6b86;
  --panel: #ffffff;
  --panel-soft: #f3f8ff;
  --line: #dbe7f5;
  --purple: #6a47ec;
  --purple-deep: #4a2fb8;
  --purple-wash: #efeaff;
  --green: #12865d;
  --green-wash: #e3f6ec;
  --shadow: 0 10px 30px rgba(29, 43, 74, 0.10);
  --radius: 22px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  min-height: 100vh;
  color: var(--ink);
  font-family: "Nunito", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
  font-size: 17px;
  line-height: 1.6;
  background: linear-gradient(var(--sky-top) 0, #bfe4ff 420px, var(--sky-bottom) 900px) no-repeat, var(--sky-bottom);
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; }
a { color: var(--purple); font-weight: 700; text-decoration-thickness: 2px; text-underline-offset: 3px; }
a:hover { color: var(--purple-deep); }

h1, h2, h3, .brand { font-family: "Fredoka", "Nunito", sans-serif; letter-spacing: -0.01em; }
h1 { font-size: clamp(34px, 6vw, 54px); line-height: 1.05; margin: 0 0 14px; font-weight: 700; }
h2 { font-size: clamp(24px, 3.4vw, 32px); line-height: 1.15; margin: 0 0 14px; font-weight: 700; }
h3 { font-size: 21px; line-height: 1.2; margin: 0 0 6px; font-weight: 600; }
p { margin: 0 0 14px; }
ul { margin: 0 0 6px; padding-left: 20px; }
li { margin: 4px 0; }
li::marker { color: var(--purple); }
strong { font-weight: 800; }

.wrap { max-width: 1040px; margin: 0 auto; padding: 0 16px; }
.narrow { max-width: 760px; }

/* Top bar */
.top {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  flex-wrap: wrap; padding: 18px 0 8px;
}
.brand {
  display: inline-flex; align-items: center; gap: 10px;
  color: var(--ink); text-decoration: none; font-size: 22px; font-weight: 700;
}
.brand img { width: 40px; height: 40px; border-radius: 11px; box-shadow: 0 4px 0 rgba(29, 43, 74, 0.15); }
.top nav { display: flex; flex-wrap: wrap; gap: 6px; }
.top nav a {
  color: var(--ink); text-decoration: none; font-weight: 800; font-size: 15px;
  padding: 7px 14px; border-radius: 999px; background: rgba(255, 255, 255, 0.55);
}
.top nav a:hover { background: #fff; }
.top nav a[aria-current="page"] { background: var(--ink); color: #fff; }

/* Hero */
.hero { padding: 34px 0 30px; }
.hero p.lead { font-size: 19px; color: var(--ink-soft); max-width: 640px; }
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  background: var(--purple); color: #fff; text-decoration: none;
  font-family: "Fredoka", "Nunito", sans-serif; font-weight: 600; font-size: 19px;
  padding: 13px 26px; border-radius: 999px; box-shadow: 0 5px 0 var(--purple-deep);
  transition: transform 0.08s ease, box-shadow 0.08s ease;
}
.btn:hover { color: #fff; transform: translateY(1px); box-shadow: 0 4px 0 var(--purple-deep); }
.btn:active { transform: translateY(4px); box-shadow: 0 1px 0 var(--purple-deep); }
.btn.ghost { background: #fff; color: var(--purple); box-shadow: 0 5px 0 #cfc3ff; }
.actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 8px; }

/* Panels */
.panel {
  background: var(--panel); border-radius: var(--radius); box-shadow: var(--shadow);
  padding: 26px; margin: 0 0 18px;
}
.panel > :last-child { margin-bottom: 0; }
section { margin: 0 0 30px; scroll-margin-top: 16px; }
.eyebrow {
  display: inline-block; font-size: 13px; font-weight: 900; letter-spacing: 0.12em;
  text-transform: uppercase; color: var(--green); margin-bottom: 6px;
}
.muted { color: var(--muted); }

/* Chips */
.chips { display: flex; flex-wrap: wrap; gap: 6px; margin: 2px 0 10px; }
.chip {
  font-size: 13px; font-weight: 800; color: var(--ink-soft);
  background: var(--panel-soft); border: 1px solid var(--line);
  padding: 2px 10px; border-radius: 999px;
}
.chip.green { color: var(--green); background: var(--green-wash); border-color: transparent; }

/* Card strip: every card, small, linking to its entry */
.strip {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(76px, 1fr)); gap: 10px;
  margin: 22px 0 0;
}
.strip a { display: block; text-decoration: none; text-align: center; color: var(--ink-soft); font-size: 12px; font-weight: 800; line-height: 1.2; }
.strip img {
  display: block; width: 100%; height: auto; aspect-ratio: 336 / 520; margin-bottom: 5px;
  filter: drop-shadow(0 4px 6px rgba(29, 43, 74, 0.18)); transition: transform 0.12s ease;
}
.strip a:hover img { transform: translateY(-4px) rotate(-2deg); }
/* On a phone: one row that scrolls sideways, running to the screen edges. */
@media (max-width: 640px) {
  .strip {
    grid-auto-flow: column; grid-template-columns: none; grid-auto-columns: 72px;
    overflow-x: auto; scroll-snap-type: x proximity; padding: 4px 16px 10px;
    margin: 22px -16px 0; scrollbar-width: none;
  }
  .strip::-webkit-scrollbar { display: none; }
  .strip a { scroll-snap-align: start; }
}

/* Card entries: the card as it looks in a game, beside what it does */
.cards-grid { display: grid; grid-template-columns: 1fr; gap: 16px; }
@media (min-width: 860px) { .cards-grid { grid-template-columns: 1fr 1fr; } }
.entry {
  display: flex; gap: 18px; align-items: flex-start;
  background: var(--panel); border-radius: var(--radius); box-shadow: var(--shadow);
  padding: 18px; scroll-margin-top: 16px;
}
.entry img {
  flex: none; width: 112px; height: auto; aspect-ratio: 336 / 520;
  filter: drop-shadow(0 6px 8px rgba(29, 43, 74, 0.20));
}
.entry ul { padding-left: 18px; font-size: 16px; color: var(--ink-soft); }
@media (max-width: 420px) { .entry img { width: 92px; } .entry { gap: 14px; padding: 16px; } }

/* Numbered steps */
.steps { display: grid; grid-template-columns: 1fr; gap: 14px; counter-reset: step; margin: 0; padding: 0; list-style: none; }
@media (min-width: 760px) { .steps { grid-template-columns: repeat(3, 1fr); } }
.steps li {
  background: var(--panel-soft); border-radius: 18px; padding: 18px 18px 16px; margin: 0;
  counter-increment: step; position: relative;
}
.steps li::before {
  content: counter(step);
  display: grid; place-items: center; width: 34px; height: 34px; border-radius: 50%;
  background: var(--purple); color: #fff; font-family: "Fredoka", sans-serif; font-weight: 700;
  margin-bottom: 8px;
}
.steps strong { display: block; font-family: "Fredoka", sans-serif; font-weight: 600; font-size: 19px; }

/* Small card beside a line of text */
.mini { list-style: none; padding: 0; display: grid; grid-template-columns: 1fr; gap: 10px; }
@media (min-width: 760px) { .mini { grid-template-columns: 1fr 1fr; } }
.mini li { display: flex; gap: 12px; align-items: center; margin: 0; padding: 8px 10px; border-radius: 14px; background: var(--panel-soft); }
.mini img { flex: none; width: 46px; height: auto; aspect-ratio: 336 / 520; filter: drop-shadow(0 3px 4px rgba(29, 43, 74, 0.18)); }
.mini a { color: inherit; text-decoration: none; font-weight: inherit; }

.two { display: grid; grid-template-columns: 1fr; gap: 18px; }
@media (min-width: 760px) { .two { grid-template-columns: 1fr 1fr; } }

/* Contact box */
.contact {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px;
  background: var(--ink); color: #fff; border-radius: var(--radius); padding: 26px;
  box-shadow: var(--shadow); margin: 0 0 18px;
}
.contact h2 { color: #fff; margin-bottom: 6px; }
.contact p { color: #c9d6f2; margin: 0; max-width: 520px; }
.contact .btn { background: #fff; color: var(--purple); box-shadow: 0 5px 0 #b9c7e8; }

/* Questions that fold open */
details {
  background: var(--panel); border-radius: 18px; box-shadow: var(--shadow);
  margin: 0 0 12px; padding: 0 22px;
}
summary {
  cursor: pointer; list-style: none; padding: 18px 30px 18px 0; position: relative;
  font-family: "Fredoka", "Nunito", sans-serif; font-weight: 600; font-size: 19px;
}
summary::-webkit-details-marker { display: none; }
/* The plus and minus are drawn, not typed: a font's own + sits low. */
summary::after {
  content: ""; position: absolute; right: 0; top: 50%; transform: translateY(-50%);
  width: 28px; height: 28px; border-radius: 50%;
  background:
    linear-gradient(var(--purple), var(--purple)) center / 12px 2.5px no-repeat,
    linear-gradient(var(--purple), var(--purple)) center / 2.5px 12px no-repeat,
    var(--purple-wash);
}
details[open] summary::after {
  background:
    linear-gradient(var(--purple), var(--purple)) center / 12px 2.5px no-repeat,
    var(--purple-wash);
}
details > p { padding-bottom: 18px; margin: 0; color: var(--ink-soft); }

/* Closing call to play, on the hills */
.outro { position: relative; margin-top: 40px; padding: 56px 0 120px; text-align: center; overflow: hidden; }
.outro h2 { margin-bottom: 16px; }
.hills { position: absolute; left: 0; right: 0; bottom: 0; height: 130px; pointer-events: none; }
.hills::before, .hills::after { content: ""; position: absolute; border-radius: 50%; }
.hills::before { background: var(--hill); left: -20%; width: 85%; top: 30px; height: 260px; }
.hills::after { background: var(--hill-dark); right: -25%; width: 90%; top: 50px; height: 260px; }
footer.site {
  position: relative; background: var(--hill-dark); color: #eaffea; text-align: center;
  padding: 0 16px 28px; font-size: 15px;
}
footer.site a { color: #fff; margin: 4px 8px; display: inline-block; white-space: nowrap; }

/* Long reading pages (privacy): headings, tables and boxes inside a panel */
.prose h2 { margin-top: 0; }
.prose h3 { margin: 18px 0 8px; }
.prose ol { margin: 0 0 10px; padding-left: 22px; }
.prose table { width: 100%; border-collapse: collapse; font-size: 15px; margin: 6px 0 4px; }
.prose th, .prose td { text-align: left; vertical-align: top; padding: 10px 12px; border-bottom: 1px solid var(--line); }
.prose th { background: var(--panel-soft); font-weight: 900; font-size: 13px; text-transform: uppercase; letter-spacing: 0.06em; color: var(--ink-soft); }
.prose td:first-child { font-weight: 800; white-space: nowrap; color: var(--ink); }
.prose td { color: var(--ink-soft); }
@media (max-width: 600px) {
  .prose table, .prose tbody, .prose tr, .prose td { display: block; width: 100%; }
  .prose tr:first-child { display: none; }
  .prose tr { padding: 10px 0; border-bottom: 1px solid var(--line); }
  .prose td { border: 0; padding: 2px 0; white-space: normal; }
}
.delete-card { border-radius: 18px; padding: 18px 20px; margin: 14px 0; background: var(--panel-soft); }
.delete-card--primary { background: var(--green-wash); }
.delete-card h3 { margin-top: 0; }
.kicker { font-size: 12px; font-weight: 900; letter-spacing: 0.12em; text-transform: uppercase; color: var(--green); margin: 0 0 4px; }
.btn-primary {
  display: inline-block; background: var(--purple); color: #fff; text-decoration: none;
  font-family: "Fredoka", "Nunito", sans-serif; font-weight: 600; font-size: 17px;
  padding: 11px 22px; border-radius: 999px; box-shadow: 0 4px 0 var(--purple-deep); margin: 6px 0 8px;
}
.btn-primary:hover { color: #fff; }
.fine { font-size: 14px; color: var(--muted); margin: 0; }
.prose .card { background: var(--panel-soft); border-radius: 14px; padding: 12px 16px; color: var(--ink-soft); font-size: 15px; margin-top: 14px; }
