/* games.pearlhx.com: the hub (index.html) and the Android page (src/android.js). Play's typefaces (Instrument Sans and
   Instrument Serif), so the two centers read as one family; the art is docs/ART-PASS.md's, made by tools/art.sh. */
@font-face { font-family: "Instrument Sans"; src: url(/fonts/instrument-sans-v1.woff2) format("woff2"); font-weight: 400 700; font-display: swap; }
@font-face { font-family: "Instrument Serif"; src: url(/fonts/instrument-serif-italic-v1.woff2) format("woff2"); font-style: italic; font-display: swap; }
:root { --bg: #06201d; --bg2: #0b2b27; --card: #0c2c27; --line: #ffffff14; --line2: #ffffff26; --ink: #f6eedc; --muted: #b9c6bf;
  --gold: #f3d58a; --gold2: #c9973f; --lime: #c9e88a; --ease: cubic-bezier(.2, .8, .2, 1); }
* { box-sizing: border-box; }
html, body { margin: 0; background: var(--bg); color: var(--ink); }
body { font: 16px/1.5 "Instrument Sans", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; min-height: 100vh;
  background: radial-gradient(1200px 600px at 50% -10%, #154a43 0%, var(--bg) 60%) no-repeat, var(--bg); -webkit-font-smoothing: antialiased; }
a { color: inherit; }
img { display: block; max-width: 100%; }
.serif { font-family: "Instrument Serif", "Iowan Old Style", Georgia, serif; font-style: italic; font-weight: 400; }

header { position: relative; z-index: 2; width: 100%; display: flex; align-items: center; justify-content: space-between; gap: 12px; max-width: 1120px;
  margin: 0 auto; padding: 18px 20px; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; }
.pearl { width: 26px; height: 26px; border-radius: 50%; background: radial-gradient(circle at 35% 30%, #fff 0 18%, #e9e3ea 40%, #b9b2bd 75%, #8d8794 100%);
  box-shadow: 0 0 18px #ffffff40; }
.brand .serif { font-size: 28px; color: var(--gold); }
/* Play, one step quieter than the games but never faint: its mark in Play's lime, ink words, a clear outline */
.to-play { display: inline-flex; align-items: center; gap: 8px; font-size: 14px; font-weight: 600; color: var(--ink); text-decoration: none;
  border: 1px solid #c9e88a55; background: #06201d99; backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); padding: 8px 14px 8px 10px;
  border-radius: 999px; transition: border-color .2s, background .2s, transform .2s var(--ease); white-space: nowrap; }
.to-play .mark { width: 18px; height: 18px; color: var(--lime); flex: none; }
.to-play:hover { border-color: var(--lime); background: #0b2b27cc; transform: translateY(-1px); }

/* the hub's stage: the key art full width, the words over its calm left side */
.stage { position: relative; isolation: isolate; overflow: hidden; min-height: min(760px, 92vh); display: flex; flex-direction: column; }
.backdrop { position: absolute; inset: 0; z-index: -1; }
.backdrop img { width: 100%; height: 100%; object-fit: cover; object-position: 88% 50%; animation: drift 24s var(--ease) both; }
.backdrop::after { content: ""; position: absolute; inset: 0;
  background: linear-gradient(90deg, #06201df2 0%, #06201dcc 30%, #06201d33 62%, #06201d00 80%),
    linear-gradient(180deg, #06201d99 0%, #06201d00 22%, #06201d00 62%, var(--bg) 100%); }
.stage > .hero { flex: 1; display: flex; flex-direction: column; justify-content: center; max-width: 1120px; width: 100%; margin: 0 auto;
  padding: 24px 20px 72px; }
.stage > .hero > * { max-width: 560px; animation: rise .7s var(--ease) both; }
.stage > .hero > :nth-child(2) { animation-delay: .06s; } .stage > .hero > :nth-child(3) { animation-delay: .12s; }
.stage > .hero > :nth-child(4) { animation-delay: .18s; } .stage > .hero > :nth-child(5) { animation-delay: .24s; }
.kicker { font-size: 12px; letter-spacing: 0.22em; text-transform: uppercase; color: var(--gold); display: flex; align-items: center; gap: 8px; font-weight: 600; }
.kicker::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--lime); box-shadow: 0 0 10px var(--lime); }
h1 { font-size: clamp(40px, 5.6vw, 68px); line-height: 1.02; margin: 14px 0 18px; font-weight: 700; letter-spacing: -0.025em; text-shadow: 0 2px 30px #0008; }
h1 .serif { color: var(--gold); letter-spacing: -0.005em; }
.lead { color: #d4ddd7; font-size: 18px; max-width: 32em; margin: 0; text-shadow: 0 1px 12px #000a; }
.facts { display: flex; flex-wrap: wrap; gap: 6px 18px; margin: 22px 0 0; font-size: 14px; color: var(--muted); }
.facts span { display: inline-flex; align-items: center; gap: 8px; }
.facts span::before { content: ""; width: 5px; height: 5px; border-radius: 50%; background: var(--gold); opacity: .8; }

main { max-width: 1120px; margin: 0 auto; padding: 8px 20px 40px; }
h2 { font-size: 12px; letter-spacing: 0.22em; text-transform: uppercase; color: var(--muted); font-weight: 600; margin: 0 0 16px; }
.games { display: grid; grid-template-columns: 2fr 1fr; gap: 20px; }
.game { background: linear-gradient(180deg, #0f332d, var(--card)); border: 1px solid var(--line); border-radius: 24px; overflow: hidden;
  display: flex; flex-direction: column; box-shadow: 0 18px 50px #0007, 0 1px 0 #ffffff12 inset; transition: transform .35s var(--ease), box-shadow .35s; }
.game:hover { transform: translateY(-3px); box-shadow: 0 26px 60px #0009, 0 1px 0 #ffffff18 inset; }
.game .art { aspect-ratio: 1 / 1; background: #0a2622; position: relative; overflow: hidden; display: block; }
.game .art img { width: 100%; height: 100%; object-fit: cover; transition: transform 1.2s var(--ease); }
.game:hover .art img { transform: scale(1.04); }
.game.feature { flex-direction: row; }
.game.feature .art { flex: 0 0 52%; aspect-ratio: auto; min-height: 420px; }
.game.feature .art::after { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, #0000 60%, #0c2c27 100%); }
.game .body { padding: 22px 24px 24px; display: flex; flex-direction: column; gap: 12px; flex: 1; }
.game.feature .body { justify-content: center; padding: 30px 30px 30px 10px; }
.game .over { font-size: 11px; letter-spacing: 0.3em; text-transform: uppercase; color: var(--muted); font-weight: 600; }
.game h3 { margin: -8px 0 0; font-size: 44px; line-height: 1.05; color: var(--gold); }
.game p { margin: 0; color: var(--muted); font-size: 15px; }
.tags { display: flex; flex-wrap: wrap; gap: 6px; }
.tags span { font-size: 12px; color: var(--ink); background: #ffffff0d; border: 1px solid var(--line); border-radius: 999px; padding: 3px 10px; }
.actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 4px; padding-top: 6px; }
.stage .actions { margin-top: 28px; }
.btn { display: inline-flex; align-items: center; justify-content: center; padding: 12px 18px; border-radius: 14px; text-decoration: none;
  font-weight: 700; font-size: 15px; transition: transform .15s var(--ease), filter .2s, border-color .2s, color .2s, background .2s; }
.btn:active { transform: scale(.97); }
.btn.gold { background: linear-gradient(#f8e7b4, #e6c27a 45%, var(--gold2)); color: #2a1a08; box-shadow: 0 8px 24px #c9973f55, 0 1px 0 #fff8 inset; }
.btn.gold:hover { filter: brightness(1.06); transform: translateY(-1px); }
.btn.line { border: 1px solid var(--line2); color: var(--ink); }
.btn.line:hover { border-color: var(--gold); color: var(--gold); }
.btn.glass { border: 1px solid #ffffff3a; color: var(--ink); background: #ffffff10; backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); }
.btn.glass:hover { background: #ffffff1c; border-color: #ffffff66; }
.btn.big { padding: 15px 24px; font-size: 17px; border-radius: 16px; }
.btn.small { padding: 9px 14px; font-size: 14px; border-radius: 12px; }
.soon { font-size: 13px; color: var(--muted); margin: 2px 0 0; }
.game.next .art { aspect-ratio: 4 / 3; }
.game.next .art img { opacity: .9; }
.game.next .art::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, #0000 50%, #0c2c27 100%); }
.game.next h3 { color: var(--ink); opacity: .9; }

/* Play: a whole band you can tap, art on the right, calm words on the left */
.also { position: relative; display: block; margin: 36px 0 0; border: 1px solid #c9e88a30; border-radius: 22px; overflow: hidden; text-decoration: none;
  min-height: 190px; background: #08231f; transition: border-color .25s, transform .35s var(--ease); }
.also:hover { border-color: #c9e88a77; transform: translateY(-2px); }
.also img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 80% 50%; opacity: .85; transition: transform 1.2s var(--ease); }
.also:hover img { transform: scale(1.03); }
.also::before { content: ""; position: absolute; inset: 0; z-index: 1; background: linear-gradient(90deg, #08231ff7 0%, #08231fd9 38%, #08231f40 70%, #08231f00 100%); }
.also-text { position: relative; z-index: 2; display: flex; flex-direction: column; align-items: flex-start; gap: 6px; padding: 26px 28px; max-width: 460px; color: var(--muted); }
.also-text .over { font-size: 11px; letter-spacing: 0.3em; text-transform: uppercase; color: var(--lime); font-weight: 600; }
.also-text strong { color: var(--ink); font-size: 22px; line-height: 1.2; }
.also-text .btn { margin-top: 10px; }
.also:hover .btn.line { border-color: var(--lime); color: var(--lime); }

footer { max-width: 1120px; margin: 0 auto; padding: 26px 20px 40px; color: var(--muted); font-size: 13px; display: flex; gap: 18px; flex-wrap: wrap;
  border-top: 1px solid var(--line); }
footer a { text-decoration: none; }
footer a:hover { color: var(--ink); }

/* the Android page (/carrom/android): the download, how to install it */
.get .hero { display: grid; grid-template-columns: 1.1fr 0.9fr; gap: 32px; align-items: center; padding: 28px 0 40px; }
.get .actions { margin-top: 22px; }
.phone { justify-self: center; width: min(260px, 70vw); aspect-ratio: 540 / 760; border-radius: 34px; padding: 9px; background: linear-gradient(#2a2a2a, #0d0d0d);
  box-shadow: 0 30px 80px #000a, 0 0 0 1px #ffffff1a inset; transform: rotate(3deg); }
.phone img { width: 100%; height: 100%; object-fit: cover; border-radius: 26px; }
.fine { color: var(--muted); font-size: 14px; margin: 12px 0 0; }
.steps { margin: 0 0 18px; padding-left: 22px; max-width: 40em; }
.steps li { margin: 0 0 10px; color: var(--muted); }
.steps strong, .note strong { color: var(--ink); }
.note { color: var(--muted); font-size: 15px; max-width: 40em; margin: 0 0 12px; }
.note summary { cursor: pointer; color: var(--ink); }
.note code { font-size: 12px; word-break: break-all; color: var(--ink); }

@keyframes rise { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
@keyframes drift { from { transform: scale(1.06); } to { transform: scale(1); } }
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation: none !important; transition: none !important; } }
@media (max-width: 860px) {
  .games { grid-template-columns: 1fr; }
  .game.feature { flex-direction: column; }
  .game.feature .art { flex: none; aspect-ratio: 1 / 1; min-height: 0; }
  .game.feature .art::after { background: linear-gradient(180deg, #0000 60%, #0c2c27 100%); }
  .game.feature .body { padding: 6px 22px 24px; }
}
@media (max-width: 760px) {
  .stage { min-height: 0; }
  .backdrop img { object-position: 72% 50%; }
  .backdrop::after { background: linear-gradient(180deg, #06201d99 0%, #06201d22 22%, #06201d55 46%, #06201df0 72%, var(--bg) 100%); }
  .stage > .hero { justify-content: flex-end; padding-top: 34vh; padding-bottom: 36px; }
  .lead { font-size: 16px; }
  .stage .actions .btn { flex: 1 1 100%; }
  .to-play { font-size: 13px; padding: 7px 12px 7px 9px; }
  .get .hero { grid-template-columns: 1fr; padding-top: 10px; }
  .phone { width: min(220px, 60vw); transform: rotate(2deg); }
  .also img { opacity: .55; }
  .also::before { background: linear-gradient(90deg, #08231ff2 0%, #08231fbb 70%, #08231f88 100%); }
}
.get-stage { min-height: 0; }
.get.top { width: 100%; max-width: 1120px; margin: 0 auto; padding: 0 20px 20px; }
.get-stage .backdrop img { object-position: 60% 50%; }
.get-stage .backdrop::after { background: linear-gradient(90deg, #06201df5 0%, #06201dd0 40%, #06201d88 75%, #06201d66 100%),
  linear-gradient(180deg, #06201d99 0%, #06201d00 25%, #06201d00 70%, var(--bg) 100%); }
main.get { padding-top: 10px; }
main.get h2 { margin-top: 8px; }
