/* inthistown.app: what both game pages share. Each page sets its own tokens (--ink, --paper, --head, --body ...) */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body { margin: 0; overflow-x: clip; background: var(--paper); color: var(--ink); font-family: var(--body); font-size: 17px; line-height: 1.55; }
img { display: block; max-width: 100%; height: auto; }
picture { display: contents; }
a { color: inherit; }
h1, h2, h3 { font-family: var(--head); font-weight: 400; line-height: 1.04; margin: 0; letter-spacing: .005em; text-wrap: balance; }
.tag, .lead, .lede { text-wrap: balance; }
p { margin: 0; }
button { font: inherit; color: inherit; }
.sr { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.wrap { width: min(1180px, 100% - 32px); margin-inline: auto; }
:focus-visible { outline: 3px solid var(--focus, #3a8dff); outline-offset: 3px; border-radius: 6px; }

/* the top bar: one pill per game */
.top { position: absolute; z-index: 20; inset: 0 0 auto; padding: 14px 0; }
.top .wrap { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.games { display: flex; gap: 8px; margin: 0; padding: 0; list-style: none; }
.games a { display: flex; align-items: center; gap: 8px; min-height: 44px; padding: 5px 14px 5px 5px; border-radius: 999px; text-decoration: none;
  font-family: var(--head); font-size: 16px; line-height: 1; white-space: nowrap; background: var(--pill-bg); color: var(--pill-ink);
  border: var(--pill-line); }
.games a[aria-current] { background: var(--pill-on-bg); color: var(--pill-on-ink); box-shadow: var(--pill-on-shadow); }
.games img { width: 30px; height: 30px; border-radius: 9px; }
@media (max-width: 380px) { .games a { font-size: 14px; padding-right: 11px; } .games img { width: 26px; height: 26px; } }

/* a phone with a real frame of the game in it: our own drawing of a modern phone (Apple's device artwork is not licensed for
   websites). A dark body with a lit metal edge, a thin bezel, the screen's own corner radius, a Dynamic Island, a long soft shadow. */
.phone { position: relative; border-radius: 16.5% / 7.6%; padding: 3%; isolation: isolate;
  background: linear-gradient(155deg, #5b5a66 0, #1b1a22 9%, #0b0b10 40%, #16151c 78%, #4b4a56 100%);
  box-shadow: inset 0 0 0 1.5px rgba(255, 255, 255, .16), inset 0 0 0 4px #050508, var(--phone-shadow, 0 44px 60px -30px rgba(12, 8, 40, .62), 0 14px 26px -14px rgba(12, 8, 40, .45)); }
/* only the phone's own screen picture, never a picture inside a live screen (the throw's catch card) */
.phone > img, .phone > picture img { border-radius: 13.6% / 6.3%; width: 100%; background: #000; }
.phone::after { content: ""; position: absolute; z-index: 1; left: 50%; top: 5.2%; width: 27%; height: 3.3%; translate: -50% 0; border-radius: 999px; background: #050508;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .06); }
.phone.wide { border-radius: 7.6% / 16.5%; padding: 1.5%; }
.phone.wide > img, .phone.wide > picture img { border-radius: 6.3% / 13.6%; }
.phone.wide::after { left: 4.6%; top: 50%; width: 1.6%; height: 27%; translate: 0 -50%; }

/* App Store: Apple's own badge, unaltered, as knockround.co.uk shows its stores (his pick, 7 Nov). Until the app is on sale it
   is not a link and wears a small "Coming soon" pill on its top edge, clear of Apple's words. */
.store { position: relative; flex: none; display: inline-block; margin: 0; line-height: 0; border-radius: 9px; -webkit-tap-highlight-color: transparent;
  transition: translate .3s cubic-bezier(.2, 1, .3, 1); }
.store img { display: block; height: 46px; width: auto; }
.store.soon { cursor: default; }
.store.soon::after { content: "Coming soon"; position: absolute; top: -11px; right: -9px; padding: 4px 8px 3px; border-radius: 999px;
  background: var(--soon-bg, #ffd23a); color: var(--soon-ink, #121226); font: 800 11px/1 var(--soon-font, var(--body)); letter-spacing: .01em;
  white-space: nowrap; box-shadow: 0 4px 10px -4px rgba(10, 6, 40, .55); }
@media (hover: hover) { a.store:hover { translate: 0 -2px; } }
a.store:active { scale: .97; }

/* swipe rows on phones */
.row { display: flex; gap: 16px; overflow-x: auto; overflow-y: hidden; scroll-snap-type: x mandatory; overscroll-behavior-x: contain;
  scrollbar-width: none; padding: 8px 16px 22px; margin-inline: -16px; }
.row::-webkit-scrollbar { display: none; }
.row > * { scroll-snap-align: center; flex: none; }

/* things that arrive as you reach them (only with JS, never under reduced motion) */
.js .rise { opacity: 0; translate: 0 28px; transition: opacity .7s ease, translate .9s cubic-bezier(.2, 1.2, .35, 1); }
.js .rise.in { opacity: 1; translate: 0 0; }

/* footer */
.foot { background: #121226; color: #f4f2ff; padding: 56px 0 40px; font-size: 15px; }
.foot .wrap { display: grid; gap: 32px; }
@media (min-width: 760px) { .foot .wrap { grid-template-columns: 1fr 1fr; } }
.foot .game { display: grid; grid-template-columns: 56px 1fr; gap: 6px 16px; align-items: start; }
.foot .game img { width: 56px; height: 56px; border-radius: 14px; grid-row: span 2; }
.foot h2 { font-family: var(--foot-head, var(--head)); font-size: 22px; }
.foot ul { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 0 20px; }
.foot a { color: #f4f2ff; text-underline-offset: 3px; display: inline-block; padding: 11px 0; }
.foot .made a { padding: 11px 0; }
.foot .made { grid-column: 1 / -1; border-top: 1px solid rgba(255, 255, 255, .18); padding-top: 22px; color: #c9c5e0; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .js .rise { opacity: 1; translate: none; }
}
