/* Undercity Studio. Layout: a quiet frame (one face for headings, one for reading, plain grey ground)
   so the game characters supply all the colour. Each game gets a tile in its own icon colour. */
:root {
  --ground: #f1f2f4;
  --paper: #ffffff;
  --ink: #15171c;
  --ink-soft: #5b616b;
  --line: #d9dce1;
  --link: #1f5fa8;
  --ph-bg: #fff0b8;
  --ph-fg: #5e4500;
  --font-head: "Gabarito", "Avenir Next", "Helvetica Neue", Arial, sans-serif;
  --font-body: "Atkinson Hyperlegible", "Helvetica Neue", Arial, sans-serif;
  --font-label: var(--font-body);
  --w: 1120px;
  --read: 68ch;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --ground: #111317; --paper: #1a1d22; --ink: #eef0f3; --ink-soft: #a2a8b2; --line: #2c3037;
    --link: #8ab8ee; --ph-bg: #3d3110; --ph-fg: #ffd877; color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --ground: #111317; --paper: #1a1d22; --ink: #eef0f3; --ink-soft: #a2a8b2; --line: #2c3037;
  --link: #8ab8ee; --ph-bg: #3d3110; --ph-fg: #ffd877; color-scheme: dark;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--ground); color: var(--ink); font: 17px/1.6 var(--font-body); }
img { max-width: 100%; display: block; }
a { color: var(--link); text-underline-offset: 3px; }
:focus-visible { outline: 3px solid var(--link); outline-offset: 3px; border-radius: 3px; }
h1, h2, h3 { font-family: var(--font-head); font-weight: 700; letter-spacing: -0.015em; text-wrap: balance; }

.skip { position: absolute; left: 16px; top: -60px; background: var(--ink); color: var(--ground); padding: 10px 14px; border-radius: 8px; z-index: 10; }
.skip:focus { top: 12px; }
.wrap { max-width: var(--w); margin: 0 auto; padding-inline: 20px; }

/* Header */
.site-head .wrap { display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; padding-block: 22px; }
.brand { color: var(--ink); text-decoration: none; font: 800 28px/1 var(--font-head); letter-spacing: -0.03em; }
.nav { display: flex; gap: 24px; flex-wrap: wrap; }
.nav a { color: var(--ink-soft); text-decoration: none; font-size: 16px; padding-block: 4px; border-bottom: 2px solid transparent; }
.nav a:hover { color: var(--ink); }
.nav a[aria-current="page"] { color: var(--ink); border-bottom-color: var(--ink); }

/* Hero */
.hero { padding-block: 64px 56px; }
.hero h1 { font-size: clamp(38px, 6vw, 68px); line-height: 1.04; margin: 0 0 20px; max-width: 16ch; }
.hero .lede { font-size: 20px; color: var(--ink-soft); max-width: 52ch; margin: 0; }

/* Games */
.section { padding-block: 24px 80px; }
.section > .wrap > h2 { font-size: clamp(30px, 4vw, 40px); margin: 0 0 24px; }
.games { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.game {
  display: grid; grid-template-columns: 132px minmax(0, 1fr); gap: 24px; align-items: center;
  padding: 28px; border-radius: 20px; background: var(--tile); color: var(--tile-ink);
}
.game img { width: 132px; height: 132px; border-radius: 22%; box-shadow: 0 8px 20px -10px rgba(0,0,0,.45); }
.game h3 { font-size: 30px; line-height: 1.05; margin: 0 0 4px; }
.game .genre { margin: 0 0 10px; font-size: 15px; opacity: .8; }
.game p { margin: 0; font-size: 16px; line-height: 1.5; }
a.game { text-decoration: none; transition: transform .15s ease; }
a.game:hover { transform: translateY(-3px); }
.more { margin: 24px 0 0; }
.more-link { display: inline-block; padding: 13px 22px; border-radius: 12px; border: 1px solid var(--ink); color: var(--ink); font-weight: 700; text-decoration: none; transition: background .15s ease, color .15s ease; }
.more-link::after { content: "\00a0\2192"; }
.more-link:hover { background: var(--ink); color: var(--ground); }
.hero-small h1 { font-size: clamp(40px, 6vw, 64px); }
.soon-section { padding-top: 0; }
.apps { padding-top: 0; }
.apps-note { margin: 0; max-width: 56ch; font-size: 18px; color: var(--ink-soft); }
.soon { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.soon-card { border: 1px dashed var(--line); border-radius: 18px; padding: 24px 28px; }
.soon-card h3 { font-size: 24px; margin: 0 0 4px; }
.soon-card .genre { margin: 0 0 10px; font-size: 15px; color: var(--ink-soft); }
.soon-card p { margin: 0; }

/* About */
.about { border-top: 1px solid var(--line); padding-block: 56px 80px; }
.about .wrap { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 2fr); gap: 40px; }
.about h2 { font-size: clamp(30px, 4vw, 40px); margin: 0; }
.about p { margin: 0 0 16px; max-width: 60ch; font-size: 18px; }
.about p:last-child { margin-bottom: 0; }

/* Game pages */
.gp-band { background: var(--tile); color: var(--tile-ink); overflow: hidden; }
.gp-band .wrap { display: grid; grid-template-columns: minmax(0, 1fr) 470px; gap: 48px; align-items: end; padding-block: 40px 0; }
.gp-intro { padding-bottom: 56px; }
.gp-back { color: inherit; opacity: .85; font-size: 15px; display: inline-block; margin-bottom: 28px; }
.gp-back::before { content: "\2190\00a0"; }
.gp-icon { width: 128px; height: 128px; border-radius: 22%; box-shadow: 0 10px 24px -12px rgba(0,0,0,.5); margin-bottom: 24px; }
.gp-band h1 { font-size: clamp(40px, 6vw, 64px); line-height: 1.02; margin: 0 0 12px; }
.gp-tag { font-size: 21px; margin: 0 0 8px; max-width: 32ch; }
.gp-genre { font-size: 15px; opacity: .85; margin: 0 0 28px; }
.gp-store { display: inline-block; padding: 14px 22px; border-radius: 12px; background: var(--tile-ink); color: var(--tile); font-weight: 700; font-size: 16px; text-decoration: none; transition: transform .15s ease; }
.gp-stores { display: flex; flex-wrap: wrap; gap: 10px; }
.gp-store:hover { transform: translateY(-2px); }
.gp-phones { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; align-items: end; align-self: end; }
.gp-phone:nth-child(2) img { max-height: 460px; }
.gp-phone { margin: 0; background: #0d0f12; padding: 10px 10px 0; border-radius: 40px 40px 0 0; box-shadow: 0 -10px 40px -20px rgba(0,0,0,.6); }
.gp-phone img { width: 100%; height: auto; border-radius: 30px 30px 0 0; aspect-ratio: 600 / 1299; object-fit: cover; object-position: top; max-height: 520px; }
.gp-body { padding-block: 56px; }
.gp-body .wrap { display: grid; grid-template-columns: minmax(0, 3fr) minmax(0, 2fr); gap: 56px; }
.gp-body h2 { font-size: 26px; margin: 0 0 12px; }
.gp-about p { font-size: 18px; max-width: 58ch; margin: 0 0 16px; }
.gp-side ul { margin: 0 0 32px; padding-left: 1.2em; }
.gp-side li + li { margin-top: 6px; }
.gp-helpbox { grid-column: 1; }
.gp-help { display: flex; flex-wrap: wrap; gap: 10px; margin: 0; }
.gp-help a { padding: 9px 16px; border: 1px solid var(--line); border-radius: 999px; text-decoration: none; color: var(--ink); font-size: 16px; }
.gp-help a:hover { border-color: var(--ink); }
.gp-zoom { display: block; width: 100%; padding: 0; border: 0; background: none; cursor: zoom-in; border-radius: 30px 30px 0 0; }
.gp-zoom:focus-visible { outline: 3px solid var(--tile-ink); outline-offset: 4px; }
.shot-view { border: 0; padding: 0; background: transparent; max-width: none; max-height: none; width: 100%; height: 100%; }
.shot-view::backdrop { background: rgba(8,10,12,.88); }
.shot-view[open] { display: grid; place-items: center; padding: 16px 16px 88px; box-sizing: border-box; }
.shot-view img { max-height: calc(100vh - 112px); max-height: calc(100dvh - 112px); max-width: 100%; width: auto; height: auto; border-radius: 28px; border: 8px solid #0d0f12; box-shadow: 0 20px 60px rgba(0,0,0,.5); }
.shot-view .sv-bar { position: fixed; left: 0; right: 0; bottom: 20px; display: flex; justify-content: center; gap: 10px; }
.shot-view button { font: 700 16px/1 var(--font-body); padding: 12px 20px; border-radius: 999px; border: 0; background: #fff; color: #111; cursor: pointer; }
.moves .shot-view[open] img { animation: uc-pop .35s cubic-bezier(.3,1.3,.5,1) both; }
.gp-next { padding-block: 0 72px; }
.gp-next a { display: flex; align-items: center; gap: 16px; padding: 16px 20px; border-radius: 16px; background: var(--tile); color: var(--tile-ink); text-decoration: none; max-width: 420px; }
.gp-next img { width: 64px; height: 64px; border-radius: 22%; }
.gp-next span { font: 700 24px/1.1 var(--font-head); }
.gp-next small { display: block; font: 400 14px/1.4 var(--font-body); opacity: .85; }
.notfound { padding-block: 80px 120px; }
.notfound h1 { font-size: clamp(36px, 6vw, 56px); margin: 0 0 12px; }
.notfound p { font-size: 19px; max-width: 50ch; }

/* Press kit */
.mailer { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; margin: 18px 0 8px; padding: 20px; border: 1px solid var(--line); border-radius: 16px; }
.mailer[hidden] { display: none; }
.mailer-lede { grid-column: 1 / -1; margin: 0 !important; font-weight: 700; }
.mailer label { display: grid; gap: 6px; font-size: 15px; font-weight: 700; }
.mailer .wide { grid-column: 1 / -1; }
.mailer select, .mailer textarea { font: 400 17px/1.4 var(--font-body); color: var(--ink); background: var(--paper); border: 1px solid var(--line); border-radius: 10px; padding: 11px 12px; width: 100%; box-sizing: border-box; }
.mailer textarea { resize: vertical; min-height: 120px; }
.mailer select:focus, .mailer textarea:focus { outline: 2px solid var(--ink); outline-offset: 1px; }
.mailer-go { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 16px; }
.mailer-go button { font: 700 17px/1 var(--font-body); padding: 14px 22px; border: 0; border-radius: 12px; background: var(--ink); color: var(--ground); cursor: pointer; }
.mailer-go span { color: var(--ink-soft); font-size: 15px; flex: 1 1 240px; }
@media (max-width: 600px) { .mailer { grid-template-columns: minmax(0, 1fr); padding: 16px; } }
.dl { display: inline-block; padding: 13px 20px; border-radius: 12px; background: var(--ink); color: var(--ground); font-weight: 700; text-decoration: none; }
.dl:hover { opacity: .9; }
.facts { display: grid; grid-template-columns: minmax(0, 150px) minmax(0, 1fr); gap: 10px 20px; margin: 0; background: var(--paper); border-radius: 14px; padding: 20px 22px; }
.facts dt { color: var(--ink-soft); }
.facts dd { margin: 0; }
.boiler { background: var(--paper); border-radius: 14px; padding: 20px 22px; }
.logos { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.logos figure { margin: 0; border-radius: 14px; padding: 40px 16px 14px; text-align: center; }
.logos span { font: 800 44px/1 var(--font-head); letter-spacing: -0.03em; display: block; margin-bottom: 30px; }
.logos figcaption { font-size: 14px; opacity: .75; }
.logo-light { background: #ffffff; color: #15171c; border: 1px solid var(--line); }
.logo-dark { background: #15171c; color: #ffffff; }
.press-game { display: grid; grid-template-columns: 72px minmax(0, 1fr) auto; gap: 18px; align-items: center; padding: 16px 0; border-bottom: 1px solid var(--line); }
.press-game h3 { margin: 0 0 2px; font-size: 21px; }
.press-game h3 a { color: var(--ink); text-decoration: none; }
.press-game p { margin: 0; color: var(--ink-soft); font-size: 15px; }
.press-game .pg-genre { font-size: 13px; font-weight: 700; text-transform: none; color: var(--ink); opacity: .7; margin-bottom: 2px; }
.pg-icon { width: 72px; height: 72px; border-radius: 22%; }
.pg-shots { display: flex; gap: 8px; }
.pg-shots img { width: 54px; height: auto; border-radius: 8px; }

/* Long-form pages (privacy, support) */
.doc { padding-block: 32px 80px; }
.doc .wrap { display: grid; grid-template-columns: 210px minmax(0, 1fr); gap: 56px; align-items: start; }
.doc h1 { font-size: clamp(40px, 6vw, 60px); line-height: 1.05; margin: 0 0 10px; }
.doc .meta { color: var(--ink-soft); margin: 0 0 32px; font-size: 16px; }
.doc article { max-width: var(--read); min-width: 0; }
.doc .meta + p { font-size: 19px; }
.doc h2 { font-size: 27px; line-height: 1.15; margin: 48px 0 10px; scroll-margin-top: 20px; }
.doc h3 { font-size: 19px; margin: 24px 0 6px; }
.doc ul { padding-left: 1.2em; }
.doc li + li { margin-top: 6px; }
.toc { position: sticky; top: calc(env(safe-area-inset-top, 0px) + 24px); font-size: 15px; padding-top: 12px; }
.toc p { font-weight: 700; margin: 0 0 8px; }
.toc ol { list-style: none; margin: 0; padding: 0; }
.toc a { display: block; padding: 4px 0; color: var(--ink-soft); text-decoration: none; }
.toc a:hover { color: var(--ink); text-decoration: underline; }

.table-wrap { overflow-x: auto; margin: 16px 0; }
table { border-collapse: collapse; width: 100%; min-width: 520px; font-size: 15px; background: var(--paper); border-radius: 12px; overflow: hidden; }
th, td { text-align: left; vertical-align: top; padding: 11px 14px; border-bottom: 1px solid var(--line); }
tr:last-child td { border-bottom: 0; }
th { font-size: 14px; color: var(--ink-soft); }

.callout { background: var(--paper); border-radius: 14px; padding: 20px 22px; margin: 20px 0; }
.callout strong { display: block; margin-bottom: 4px; }
.email { font-weight: 700; font-size: 19px; word-break: break-all; }

.ph { background: var(--ph-bg); color: var(--ph-fg); border-radius: 4px; padding: 0 4px; font-weight: 700; }

.faq details { border-bottom: 1px solid var(--line); padding: 14px 0; }
.faq summary { cursor: pointer; font-weight: 700; font-size: 18px; }
.faq details p { margin: 10px 0 0; }

/* Footer */
.site-foot { border-top: 1px solid var(--line); padding-block: 32px 40px; font-size: 15px; color: var(--ink-soft); }
.site-foot .wrap { display: flex; justify-content: space-between; gap: 24px; flex-wrap: wrap; }
.site-foot strong { color: var(--ink); font-family: var(--font-head); font-size: 18px; }
.site-foot p { margin: 6px 0 0; }
.site-foot a { color: var(--ink-soft); }
.site-foot a:hover { color: var(--ink); }
.foot-links { display: flex; gap: 20px; flex-wrap: wrap; align-items: flex-start; }


/* Motion. Only runs when site.js adds .moves (it skips people who ask for reduced motion). */
@keyframes uc-rise { from { opacity: 0; transform: translateY(18px); } to { opacity: 1; transform: none; } }
@keyframes uc-pop { 0% { opacity: 0; transform: translateY(28px) scale(.7) rotate(-6deg); } 60% { opacity: 1; transform: translateY(-6px) scale(1.04) rotate(2deg); } 100% { opacity: 1; transform: none; } }
@keyframes uc-wave { 0%, 100% { transform: none; } 40% { transform: translateY(-6px); } }
@keyframes uc-phone { from { transform: translateY(70px); opacity: 0; } to { transform: none; opacity: 1; } }
@keyframes uc-fade { from { opacity: 0; } to { opacity: 1; } }

.moves .brand span { display: inline-block; }
.moves .brand:hover span { animation: uc-wave .45s ease calc(var(--i) * 35ms); }

.moves .hero h1 { animation: uc-rise .7s cubic-bezier(.2,.7,.2,1) both; }
.moves .hero .lede { animation: uc-rise .7s cubic-bezier(.2,.7,.2,1) .1s both; }
.moves .moves .moves .moves .moves .moves 
.moves a.game img { transition: transform .35s cubic-bezier(.3,1.6,.5,1); }
.moves a.game:hover img { transform: rotate(-5deg) scale(1.06); }

.moves .reveal { opacity: 0; transform: translateY(26px); transition: opacity .6s ease, transform .7s cubic-bezier(.2,.7,.2,1); }
.moves .reveal.in { opacity: 1; transform: none; }

.moves .gp-intro > * { animation: uc-rise .6s cubic-bezier(.2,.7,.2,1) both; }
.moves .gp-intro > :nth-child(2) { animation: uc-pop .7s cubic-bezier(.3,.9,.3,1) .05s both; }
.moves .gp-intro > :nth-child(3) { animation-delay: .12s; } .moves .gp-intro > :nth-child(4) { animation-delay: .18s; }
.moves .gp-intro > :nth-child(5) { animation-delay: .24s; } .moves .gp-intro > :nth-child(6) { animation-delay: .3s; }
.moves .gp-phone { animation: uc-phone .8s cubic-bezier(.2,.8,.2,1) .2s both; }
.moves .gp-phone:nth-child(2) { animation-delay: .35s; }
.moves .gp-next img { transition: transform .35s cubic-bezier(.3,1.6,.5,1); }
.moves .gp-next a:hover img { transform: rotate(-6deg) scale(1.08); }

.moves .doc h1, .moves .notfound h1 { animation: uc-rise .6s cubic-bezier(.2,.7,.2,1) both; }
.moves .page:not([hidden]) > main { animation: uc-fade .35s ease both; }

@media (prefers-reduced-motion: reduce) { a.game { transition: none; } a.game:hover { transform: none; } }
@media (max-width: 900px) {
  .games, .soon { grid-template-columns: minmax(0, 1fr); }
  .about .wrap { grid-template-columns: minmax(0, 1fr); gap: 16px; }
  .doc .wrap { grid-template-columns: minmax(0, 1fr); gap: 16px; }
  .toc { position: static; }
  .gp-band .wrap { grid-template-columns: minmax(0, 1fr); gap: 0; }
  .gp-intro { padding-bottom: 32px; }
  .gp-phones { max-width: 460px; gap: 12px; }
  .gp-phone { padding: 6px 6px 0; border-radius: 26px 26px 0 0; }
  .gp-phone img { max-height: 340px; border-radius: 20px 20px 0 0; }
  .gp-phone:nth-child(2) img { max-height: 300px; }
  .gp-body .wrap { grid-template-columns: minmax(0, 1fr); gap: 32px; }
}
@media (max-width: 600px) {
  .hero { padding-block: 32px 48px; }
    .game { grid-template-columns: 84px minmax(0, 1fr); gap: 16px; padding: 20px; align-items: start; }
  .game img { width: 84px; height: 84px; }
  .game h3 { font-size: 24px; }
  .gp-icon { width: 96px; height: 96px; }
  .gp-stores { flex-direction: column; align-items: stretch; max-width: 320px; }
  .gp-store { text-align: center; }
  .press-game { grid-template-columns: 56px minmax(0, 1fr); }
  .pg-icon { width: 56px; height: 56px; }
  .pg-shots { grid-column: 1 / -1; }
  .logos { grid-template-columns: minmax(0, 1fr); }
  .facts { grid-template-columns: minmax(0, 1fr); gap: 2px; }
  .facts dd { margin-bottom: 10px; }
}
@media print {
  .skip, header nav, .toc, .draft-note, .mailer, .gp-stores, .gp-next, footer nav { display: none !important; }
  body { background: #fff; color: #000; }
  .doc .wrap { display: block; }
  .reveal, .moves * { opacity: 1 !important; transform: none !important; transition: none !important; animation: none !important; }
  .faq details { break-inside: avoid; }
  .faq details > *:not(summary) { display: block; }
  a { color: inherit; }
}
