/*
  Bit Science Games. Dark, after the app it opens with: the bit science slate, the beaker's
  green for links and accents, and the app's backlit LCD for anything read rather than
  pressed. System fonts only: Avenir Next on Apple devices, the platform sans elsewhere.
*/
:root {
  --bg: #1D2123;
  --surface: #262B2E;
  --slate: #33383B;
  --field: #24282B;
  --line: #3A4044;
  --text: #E9EDEF;
  --muted: #A7B0B5;
  --green: #9ACE51;
  --green-deep: #7FB33A;
  --orange: #F97A2B;
  --amber: #F8A621;
  --blue: #04BAF4;
  --lcd-top: #9FCF97;
  --lcd-bottom: #B6E0AB;
  --lcd-ink: #0E150E;
  --lcd-bezel: #161917;
  --sans: "Avenir Next", Avenir, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --mono: Menlo, Consolas, "SF Mono", monospace;
  color-scheme: dark;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 17px/1.6 var(--sans);
  -webkit-font-smoothing: antialiased;
}
img, svg { display: block; max-width: 100%; height: auto; }
a { color: var(--green); text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { color: #B4E07A; }
h1, h2, h3 { font-weight: 600; line-height: 1.2; letter-spacing: -0.01em; margin: 0 0 .5em; }
h1 { font-size: clamp(2.2rem, 5vw, 3.2rem); }
h2 { font-size: clamp(1.6rem, 3.4vw, 2.2rem); }
h3 { font-size: 1.2rem; }
p, ul { margin: 0 0 1em; }
ul { padding-left: 1.2em; }
li { margin-bottom: .5em; }
strong { color: #fff; font-weight: 600; }
code { font-family: var(--mono); font-size: .9em; }
hr { border: 0; border-top: 1px solid var(--line); margin: 2.5em 0; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }

.wrap { width: min(1120px, 100% - 32px); margin-inline: auto; }
.narrow { width: min(760px, 100% - 32px); }

/* Header and footer */
.top { background: rgba(29, 33, 35, .92); border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 10;
  backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); }
.top .wrap { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 64px; }
.brand { display: flex; align-items: center; gap: 12px; text-decoration: none; }
.brand-name { display: flex; align-items: baseline; gap: 9px; }
.games { font: 600 .72rem/1 var(--sans); letter-spacing: .3em; color: var(--muted); }
.games.big { font-size: clamp(1rem, 2.2vw, 1.4rem); margin: 14px 0 0 4px; }
.top nav, .bottom nav { display: flex; flex-wrap: wrap; gap: 4px 22px; }
.top nav a, .bottom nav a { color: var(--text); text-decoration: none; font-weight: 500; }
.top nav a:hover, .bottom nav a:hover { color: var(--green); }
.bottom { border-top: 1px solid var(--line); margin-top: 72px; padding: 40px 0 56px; color: var(--muted); }
.bottom .wrap { display: grid; gap: 18px; }
.bottom .fine { font-size: .85rem; margin: 0; }

/* Heroes */
.hero { background: radial-gradient(ellipse at 25% 30%, #3E4447 0%, var(--slate) 45%, var(--field) 100%);
  border-bottom: 1px solid var(--line); padding: 72px 0 80px; }
.lockup { display: flex; align-items: center; gap: clamp(20px, 4vw, 48px); flex-wrap: wrap; }
.lockup > svg { height: clamp(120px, 20vw, 190px); width: auto; }
.lockup > div svg { height: clamp(36px, 7vw, 64px); width: auto; }
.lead { font-size: clamp(1.1rem, 2.2vw, 1.35rem); color: #D7DDE0; max-width: 40em; margin: 32px 0 0; }

.grid { display: grid; grid-template-columns: 1.05fr .95fr; gap: clamp(28px, 5vw, 72px); align-items: center; }
.app-hero .art img { width: min(100%, 380px); margin-inline: auto; }
.app-lockup { display: flex; align-items: center; gap: 20px; margin-bottom: 26px; }
.app-lockup svg { width: auto; height: 96px; }
.app-lockup h1 { margin: 0; }
.tag { color: var(--muted); font-size: 1.15rem; margin: 2px 0 0; }
.app-hero p { color: #D7DDE0; font-size: 1.15rem; }
.jump { font-size: .95rem; margin-top: 18px; }

.store { display: inline-block; margin-top: 8px; padding: 10px 18px; border-radius: 12px; font-weight: 600;
  background: var(--green); color: #12170E; text-decoration: none; }
.store.soon { background: transparent; color: var(--green); border: 1.5px solid var(--green); }

/* Home: the app list */
.apps { padding-top: 64px; }
.cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 480px), 1fr)); gap: 24px; }
.card { display: flex; gap: 22px; padding: 24px; border-radius: 22px; background: var(--surface);
  border: 1px solid var(--line); color: var(--text); text-decoration: none; transition: border-color .15s, transform .15s; }
.card:hover { border-color: var(--green-deep); transform: translateY(-2px); color: var(--text); }
.card img { width: 96px; height: 96px; border-radius: 22px; flex: none; }
.card h3 { margin: 0; font-size: 1.4rem; }
.card .tag { font-size: 1rem; margin-bottom: 10px; }
.card p { color: #CBD2D5; }

/* App pages: one section per heading */
section.feature, section.plain, section.support { padding: 72px 0 0; }
.feature .text h2 { margin-bottom: .6em; }
.feature .text p { color: #D3D9DC; font-size: 1.08rem; }
.flip .text { order: 2; }
.phones { display: flex; gap: 18px; justify-content: center; }
.phones img { width: min(100%, 330px); }
.phones.n2 img { width: min(48%, 290px); }
.plain ul { list-style: none; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 320px), 1fr)); gap: 14px 28px; }
.plain li { background: var(--surface); border: 1px solid var(--line); border-radius: 16px; padding: 16px 18px; margin: 0; color: #CBD2D5; }

/* The app's backlit display, for the privacy summary */
section.lcd .narrow { background: var(--lcd-bezel); border-radius: 18px; padding: 8px; box-shadow: 0 2px 4px rgba(0,0,0,.4); }
section.lcd .narrow > * { margin: 0; }
section.lcd h2, section.lcd p { background: linear-gradient(var(--lcd-top), var(--lcd-bottom)); color: var(--lcd-ink);
  font-family: var(--mono); padding: 16px 22px 4px; }
section.lcd h2 { border-radius: 11px 11px 0 0; font-size: 1.15rem; letter-spacing: .04em; text-transform: uppercase; }
section.lcd p { border-radius: 0 0 11px 11px; padding-bottom: 20px; font-size: .98rem; }
section.lcd a { color: var(--lcd-ink); font-weight: 700; }

.support h3 { margin-top: 1.6em; color: #fff; }
.support p { color: #CBD2D5; }
.credit { color: var(--muted); font-size: .9rem; margin-top: 48px; }

/* Policies */
.legal main { padding-top: 56px; }
.prose h1 { margin-bottom: .3em; }
.prose h2 { font-size: 1.45rem; margin-top: 2em; padding-top: .4em; border-top: 1px solid var(--line); }
.prose h3 { font-size: 1.2rem; margin-top: 1.6em; color: var(--green); }
.prose p, .prose li { color: #D3D9DC; }

@media (max-width: 820px) {
  .grid { grid-template-columns: 1fr; }
  .flip .text { order: 0; }
  .hero { padding: 48px 0 56px; }
  .top nav { gap: 4px 16px; font-size: .95rem; }
  .app-lockup svg { height: 72px; }
}
@media (max-width: 480px) {
  .brand-name .games { display: none; }
  .top nav { flex-wrap: nowrap; gap: 14px; font-size: .9rem; }
  .card { flex-direction: column; }
}
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } .card { transition: none; } }
