/* Baize green and card ink — the app's own palette, so the site and the
   product read as one thing. */
:root {
  --felt: #1d5c43;
  --felt-deep: #12402e;
  --ink: #1b1c1a;
  --muted: #5b6360;
  --paper: #f7f5ef;
  --rule: #ddd8cb;
  --accent: #b3202c;
}

@media (prefers-color-scheme: dark) {
  :root {
    --ink: #ece9e1;
    --muted: #9aa3a0;
    --paper: #14181a;
    --rule: #2a3033;
    --accent: #e2606a;
  }
}

* { box-sizing: border-box; }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font: 17px/1.65 -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
        "Helvetica Neue", Arial, sans-serif;
  -webkit-text-size-adjust: 100%;
}

main {
  max-width: 42rem;
  margin: 0 auto;
  padding: 3rem 1.25rem 5rem;
}

h1 {
  font-size: 2rem;
  line-height: 1.2;
  letter-spacing: -0.02em;
  margin: 0 0 0.4rem;
}

h2 {
  font-size: 1.2rem;
  letter-spacing: -0.01em;
  margin: 2.4rem 0 0.6rem;
  padding-top: 1.4rem;
  border-top: 1px solid var(--rule);
}

h3 {
  font-size: 1.02rem;
  margin: 1.6rem 0 0.3rem;
}

p, ul { margin: 0 0 1rem; }
ul { padding-left: 1.2rem; }
li { margin-bottom: 0.4rem; }

a { color: var(--felt); text-underline-offset: 2px; }
@media (prefers-color-scheme: dark) { a { color: #6fbf9a; } }
a:hover { color: var(--accent); }

.lede {
  font-size: 1.13rem;
  color: var(--ink);
  border-left: 3px solid var(--felt);
  padding-left: 1rem;
  margin: 1.4rem 0 2rem;
}
@media (prefers-color-scheme: dark) { .lede { border-left-color: #6fbf9a; } }

.updated, .back { color: var(--muted); font-size: 0.9rem; }
.back { margin-bottom: 2rem; }
.back a { text-decoration: none; font-weight: 600; }

/* Home page */
.hero {
  background: linear-gradient(160deg, var(--felt) 0%, var(--felt-deep) 100%);
  color: #fff;
  border-radius: 14px;
  padding: 2.4rem 1.8rem;
  margin-bottom: 2.5rem;
}
.hero h1 { color: #fff; margin-bottom: 0.5rem; }
.hero p { color: rgba(255, 255, 255, 0.88); margin-bottom: 0; }
.hero .tagline { font-size: 1.15rem; font-weight: 600; }

.games { list-style: none; padding: 0; }
.games li { padding: 0.55rem 0; border-bottom: 1px solid var(--rule); }
.games strong { display: inline-block; min-width: 7.5rem; }

footer {
  margin-top: 3.5rem;
  padding-top: 1.2rem;
  border-top: 1px solid var(--rule);
  color: var(--muted);
  font-size: 0.9rem;
}
footer a { margin-right: 1.1rem; }

/* Store buttons. Deliberately not the official Apple badges: those are
   licensed artwork with their own sizing and clear-space rules, and a
   home-made copy of one is worse than an honest link. */
.buttons { display: flex; flex-wrap: wrap; gap: 0.7rem; margin: 1.6rem 0 0.6rem; }
.button {
  display: inline-block;
  background: var(--felt);
  color: #fff;
  text-decoration: none;
  font-weight: 600;
  padding: 0.62rem 1.3rem;
  border-radius: 10px;
}
.button:hover { background: var(--felt-deep); color: #fff; }
@media (prefers-color-scheme: dark) {
  .button { background: #2b7d5d; }
  .button:hover { background: #35906b; }
}
.note { color: var(--muted); font-size: 0.9rem; margin-top: 0; }

/* Media. Both grids auto-fit, so the same markup is one column on a phone and
   several on a desktop without a breakpoint per size. */
.videos, .shots {
  display: grid;
  gap: 1.1rem;
  margin-bottom: 1.4rem;
}
/* Three videos, four screenshots — fixed counts, so the columns are stated
   rather than auto-fit. auto-fit could not reach three columns anyway: a grid
   item will not shrink below its content's intrinsic width, and a <video>
   carrying width="443" made that its floor, so the third video wrapped alone
   onto a second row. `min-width: 0` is what lets a grid item be narrower than
   its content wants. */
.videos { grid-template-columns: repeat(3, 1fr); }
.shots { grid-template-columns: repeat(2, 1fr); }
.videos figure, .shots figure { margin: 0; min-width: 0; }
.videos video, .shots img {
  width: 100%;
  height: auto;
  border-radius: 12px;
  background: var(--felt-deep);
  display: block;
}
.shots img { border: 1px solid var(--rule); }
figcaption {
  color: var(--muted);
  font-size: 0.88rem;
  margin-top: 0.4rem;
  text-align: center;
}

/* The app card on the top-level page. */
.card {
  display: flex;
  gap: 1.3rem;
  align-items: flex-start;
  text-decoration: none;
  color: inherit;
  border: 1px solid var(--rule);
  border-radius: 14px;
  padding: 1.2rem;
  margin-bottom: 1.5rem;
}
.card:hover { border-color: var(--felt); color: inherit; }
@media (prefers-color-scheme: dark) { .card:hover { border-color: #6fbf9a; } }
.card img { width: 132px; height: auto; border-radius: 9px; flex: none; }
.card h3 { margin-top: 0; }
.card-text p { margin-bottom: 0.6rem; }
.tagline-small { color: var(--muted); font-weight: 600; }
.more { color: var(--felt); font-weight: 600; margin-bottom: 0; }
@media (prefers-color-scheme: dark) { .more { color: #6fbf9a; } }

@media (max-width: 34rem) {
  /* One per row on a phone: three side by side at that width is three
     thumbnails of nothing. */
  .videos, .shots { grid-template-columns: 1fr; }
  .videos figure, .shots figure { max-width: 320px; margin: 0 auto; }
}

@media (max-width: 30rem) {
  .card { flex-direction: column; align-items: center; text-align: center; }
  .card img { width: 168px; }
}

/* Pre-release stand-in for the store buttons. */
.soon {
  font-weight: 600;
  color: var(--ink);
  border-left: 3px solid var(--felt);
  padding-left: 1rem;
  margin: 1.6rem 0 2rem;
}
@media (prefers-color-scheme: dark) { .soon { border-left-color: #6fbf9a; } }
