/* Quiet games: the look of the Pebble app. Oatmeal linen, words cut into it. */
:root {
  --linen: #e2dcd0;
  --linen-light: #ece7dd;
  --ink: #403730;
  --ink-soft: rgba(64, 55, 48, 0.72);
  --ink-faint: rgba(64, 55, 48, 0.5);
  --lit: rgba(255, 253, 245, 0.75);
  --felt: #556b5c;
  --timber: #e6d3b3;
  --terracotta: #c4683f;
  --rule: rgba(64, 55, 48, 0.14);
  color-scheme: light;
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; background-color: var(--linen); }

body {
  margin: 0;
  min-height: 100vh;
  color: var(--ink);
  background-color: var(--linen);
  /* A fine plain weave, and soft daylight from the upper left. */
  background-image:
    radial-gradient(120% 80% at 8% 0%, rgba(255, 252, 244, 0.55), rgba(255, 252, 244, 0) 60%),
    repeating-linear-gradient(0deg, rgba(255, 255, 255, 0.08) 0 1px, rgba(255, 255, 255, 0) 1px 3px),
    repeating-linear-gradient(90deg, rgba(90, 70, 50, 0.045) 0 1px, rgba(90, 70, 50, 0) 1px 3px);
  font: 17px/1.6 -apple-system, BlinkMacSystemFont, "Helvetica Neue", Helvetica, Arial, sans-serif;
  text-shadow: 0.5px 0.8px 0 var(--lit);
}

a { color: var(--ink); text-decoration-color: rgba(64, 55, 48, 0.35); text-underline-offset: 3px; }
a:hover { text-decoration-color: var(--ink); }

.page { max-width: 760px; margin: 0 auto; padding: 0 24px; }

/* Engraved capitals, as in the app's menus. */
.caps {
  text-transform: uppercase;
  letter-spacing: 0.32em;
  font-weight: 500;
}

.site-head { padding: 28px 0 0; text-align: center; }
.site-head a { text-decoration: none; color: var(--ink-faint); font-size: 12px; }

h1 {
  margin: 0;
  font-weight: 400;
  font-size: clamp(30px, 6vw, 44px);
  letter-spacing: 0.42em;
  text-transform: uppercase;
  /* Letter-spacing adds space after the last letter; balance it. */
  padding-left: 0.42em;
}

h2 {
  margin: 56px 0 14px;
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: var(--ink-soft);
}

h3 { margin: 26px 0 4px; font-size: 13px; font-weight: 600; letter-spacing: 0.24em; text-transform: uppercase; }

p, li { color: var(--ink-soft); }
p { margin: 0 0 14px; }
ul { padding-left: 20px; }
li { margin-bottom: 8px; }

.lede { font-size: 19px; color: var(--ink); text-align: center; max-width: 34em; margin: 18px auto 0; }

.hero { text-align: center; padding: 36px 0 8px; }
.hero .icon {
  width: 120px; height: 120px; border-radius: 27px;
  box-shadow: 0 10px 24px rgba(60, 45, 30, 0.22), 0 1px 3px rgba(60, 45, 30, 0.2);
  margin-bottom: 26px;
}
.hero .sub { margin-top: 10px; font-size: 12px; color: var(--ink-faint); }

/* The box of games, fading into the page's linen at every edge. On narrow screens it crops in to the box. */
.banner {
  display: block; width: 100%; max-width: 1200px; margin: 30px auto 0;
  height: clamp(300px, 43vw, 515px); object-fit: cover; object-position: center;
  -webkit-mask-image: linear-gradient(to right, transparent, #000 12%, #000 88%, transparent),
                      linear-gradient(to bottom, transparent, #000 5%, #000 95%, transparent);
  -webkit-mask-composite: source-in;
  mask-image: linear-gradient(to right, transparent, #000 12%, #000 88%, transparent),
              linear-gradient(to bottom, transparent, #000 5%, #000 95%, transparent);
  mask-composite: intersect;
}

.store-note {
  display: inline-block; margin-top: 22px; padding: 12px 22px; border-radius: 999px; white-space: nowrap;
  border: 1px solid var(--rule); font-size: 12px; color: var(--ink-soft); text-decoration: none;
}

a.store-link { background: var(--ink); color: var(--linen-light); border-color: var(--ink); text-shadow: none; }
a.store-link:hover { background: #2c251f; }

.games { list-style: none; padding: 0; margin: 0; }
.games li { padding: 14px 0; border-top: 1px solid var(--rule); margin: 0; display: grid; grid-template-columns: 11.5em 1fr; align-items: baseline; }
.games li:last-child { border-bottom: 1px solid var(--rule); }
.games b { display: block; color: var(--ink); font-weight: 600; font-size: 13px; letter-spacing: 0.22em; }

.shots {
  display: flex; gap: 18px; overflow-x: auto; padding: 8px 24px 22px;
  scroll-snap-type: x mandatory; -webkit-overflow-scrolling: touch;
  max-width: 1200px; margin: 0 auto;
}
.shots img {
  flex: 0 0 auto; width: 220px; height: auto; border-radius: 26px; scroll-snap-align: center;
  box-shadow: 0 8px 22px rgba(60, 45, 30, 0.2), 0 1px 2px rgba(60, 45, 30, 0.18);
}

/* The short film: phone-shaped, centred, playing quietly. */
.film { text-align: center; margin: 8px 0 0; }
.film video {
  display: block; margin: 0 auto;
  width: 300px; max-width: 72vw; height: auto; border-radius: 34px; background: var(--linen-light);
  box-shadow: 0 12px 30px rgba(60, 45, 30, 0.24), 0 1px 3px rgba(60, 45, 30, 0.2);
}
.film-note { margin-top: 12px; font-size: 11px; letter-spacing: 0.3em; text-transform: uppercase; color: var(--ink-faint); }

.note { font-size: 15px; }
.updated { font-size: 13px; color: var(--ink-faint); }

.site-foot {
  margin: 72px auto 0; padding: 26px 0 44px; border-top: 1px solid var(--rule);
  text-align: center; font-size: 12px; color: var(--ink-faint);
}
.site-foot a { margin: 0 12px; color: var(--ink-soft); text-decoration: none; }
.site-foot a:hover { color: var(--ink); }
.site-foot p { margin-top: 14px; color: var(--ink-faint); }

@media (max-width: 520px) {
  body { font-size: 16px; }
  .store-note { letter-spacing: 0.16em; font-size: 11px; padding: 11px 16px; }
  .lede { font-size: 17px; }
  .games li { grid-template-columns: 1fr; }
  .games b { margin-bottom: 2px; }
  .shots img { width: 180px; border-radius: 22px; }
}
