/* Gemfall — site layout. Loads on top of palette.css, which owns the colours,
   the backdrop, .panel and .button. Nothing here redefines a token. */

/* The app is set in SF Pro Rounded. Apple platforms expose exactly that through
   the `ui-rounded` generic, so visitors on iPhone and Mac — most of the audience
   for an iPhone game — see the real thing with no webfont request at all.
   Everyone else lands on their system sans. No Google Fonts, nothing to disclose
   in the privacy policy, no render-blocking stylesheet. */
:root {
  --font: ui-rounded, "SF Pro Rounded", "Hiragino Maru Gothic ProN",
          -apple-system, "Segoe UI Variable Display", "Segoe UI", system-ui, sans-serif;
  --measure: 1080px;
}

* { box-sizing: border-box; }

body {
  font-family: var(--font);
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  overflow-x: hidden;
}

img { max-width: 100%; height: auto; display: block; }

.wrap {
  width: 100%;
  max-width: var(--measure);
  margin-inline: auto;
  padding-inline: 24px;
}

/* Skip link — the page is short, but the nav still sits in front of the content. */
.skip {
  position: absolute;
  left: -9999px;
  top: 8px;
  padding: 0.6rem 1rem;
  border-radius: 12px;
  background: var(--gold);
  color: var(--ink);
  font-weight: 800;
  z-index: 10;
}
.skip:focus { left: 24px; }

:where(a, button):focus-visible {
  outline: 2px solid var(--gold);
  outline-offset: 3px;
  border-radius: 6px;
}

/* ── Header ─────────────────────────────────────────────────────────────── */

.site-head {
  padding-block: 20px;
}
.site-head .wrap {
  display: flex;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.7rem;
  color: var(--text);
  text-decoration: none;
  font-weight: 900;
  font-size: 1.15rem;
  letter-spacing: -0.01em;
  margin-right: auto;
}
.brand img {
  width: 34px;
  height: 34px;
  border-radius: 9px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.45);
}
.site-nav {
  display: flex;
  gap: 1.4rem;
  font-weight: 700;
  font-size: 0.95rem;
}
.site-nav a {
  color: var(--text-body);
  text-decoration: none;
}
.site-nav a:hover,
.site-nav a[aria-current="page"] { color: var(--gold); }

/* ── Hero ───────────────────────────────────────────────────────────────── */

main { flex: 1; }

.hero {
  padding-block: clamp(3rem, 9vw, 6.5rem) clamp(2.5rem, 6vw, 4rem);
  text-align: center;
}
.hero-icon {
  width: clamp(104px, 18vw, 136px);
  height: auto;
  margin: 0 auto 1.75rem;
  border-radius: 26%;
  box-shadow: 0 18px 44px rgba(11, 10, 29, 0.7),
              0 0 0 1px rgba(255, 255, 255, 0.09);
}
.hero h1 {
  font-size: clamp(2.6rem, 8vw, 4.4rem);
  margin: 0 0 0.6rem;
}
.hero .tagline {
  font-size: clamp(1.1rem, 3.2vw, 1.45rem);
  color: var(--text);
  font-weight: 700;
  margin: 0 auto 1.1rem;
  max-width: 22ch;
}
.hero .blurb {
  max-width: 46ch;
  margin: 0 auto 2.25rem;
  font-size: 1.02rem;
}

.cta-row {
  display: flex;
  gap: 0.9rem;
  justify-content: center;
  flex-wrap: wrap;
  align-items: center;
}
/* Swap this whole block for Apple's official black App Store badge once the app
   is live — see README.md. Until there is a real product URL, a dead badge is
   worse than an honest one. */
.badge-soon {
  display: inline-flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 2px;
  padding: 0.7rem 1.5rem;
  border-radius: 18px;
  border: 1.5px solid rgba(255, 214, 92, 0.45);
  background: rgba(255, 214, 92, 0.08);
  color: var(--gold);
  text-decoration: none;
  line-height: 1.25;
}
.badge-soon .small {
  font-size: 0.62rem;
  letter-spacing: 1.4px;
  text-transform: uppercase;
  font-weight: 800;
  opacity: 0.75;
}
.badge-soon .big { font-size: 1.12rem; font-weight: 900; }

.gem-row {
  display: flex;
  justify-content: center;
  gap: clamp(0.4rem, 2.5vw, 1.4rem);
  margin-top: 3rem;
  flex-wrap: wrap;
}
.gem-row img {
  width: clamp(38px, 8vw, 60px);
  filter: drop-shadow(0 6px 14px rgba(0, 0, 0, 0.5));
  animation: float 5s ease-in-out infinite;
}
.gem-row img:nth-child(2) { animation-delay: -0.7s; }
.gem-row img:nth-child(3) { animation-delay: -1.4s; }
.gem-row img:nth-child(4) { animation-delay: -2.1s; }
.gem-row img:nth-child(5) { animation-delay: -2.8s; }
.gem-row img:nth-child(6) { animation-delay: -3.5s; }
.gem-row img:nth-child(7) { animation-delay: -4.2s; }
@keyframes float {
  0%, 100% { transform: translateY(0); }
  50%      { transform: translateY(-9px); }
}

/* ── Sections ───────────────────────────────────────────────────────────── */

section { padding-block: clamp(2.5rem, 7vw, 4.5rem); }

.section-head { text-align: center; margin-bottom: 2.5rem; }
.section-head h2 {
  font-size: clamp(1.7rem, 4.5vw, 2.4rem);
  margin: 0.4rem 0 0.6rem;
}
.section-head p {
  max-width: 52ch;
  margin: 0 auto;
}

.cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 1.25rem;
}
.card h3 {
  font-size: 1.15rem;
  margin: 0.9rem 0 0.5rem;
}
.card p { margin: 0; font-size: 0.98rem; }
.card img.gem-mark {
  width: 44px;
  filter: drop-shadow(0 5px 12px rgba(0, 0, 0, 0.45));
}

/* ── Screenshots ────────────────────────────────────────────────────────── */

.shots {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
  gap: clamp(1.25rem, 4vw, 2.5rem);
  max-width: 900px;
  margin-inline: auto;
}
.shot { text-align: center; }
.shot img {
  border-radius: 26px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  box-shadow: 0 22px 50px rgba(11, 10, 29, 0.75);
  margin-bottom: 0.9rem;
}
.shot .label { display: block; }

/* ── Prose (privacy / support) ──────────────────────────────────────────── */

.page-head {
  padding-block: clamp(2.5rem, 7vw, 4rem) 1.5rem;
  text-align: center;
}
.page-head h1 { font-size: clamp(2.1rem, 6vw, 3.1rem); margin: 0 0 0.75rem; }

.prose {
  max-width: 68ch;
  margin-inline: auto;
  padding: clamp(1.5rem, 4vw, 2.75rem);
  margin-bottom: 4rem;
}
.prose > :first-child { margin-top: 0; }
.prose > :last-child { margin-bottom: 0; }
.prose h2 {
  font-size: 1.4rem;
  margin: 2.4rem 0 0.8rem;
  color: var(--gold);
}
.prose h3 {
  font-size: 1.08rem;
  margin: 1.8rem 0 0.5rem;
}
.prose p, .prose li { font-size: 1rem; }
.prose ul { padding-left: 1.2rem; }
.prose li { margin-bottom: 0.55rem; }
.prose li::marker { color: var(--mint); }
.prose code {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 0.86em;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.1);
  padding: 0.12em 0.42em;
  border-radius: 6px;
  color: var(--ice);
  overflow-wrap: anywhere;
}
.prose a { overflow-wrap: anywhere; }

.updated {
  color: var(--text-mute);
  font-size: 0.85rem;
  font-weight: 700;
}

/* A pulled-out contact block for the support page. */
.contact {
  text-align: center;
  padding: clamp(1.5rem, 4vw, 2.25rem);
  margin: 1.75rem 0 2rem;
}
.contact .mail {
  display: inline-block;
  font-size: clamp(1.1rem, 3.5vw, 1.5rem);
  font-weight: 900;
  color: var(--gold);
  text-decoration: none;
  margin: 0.35rem 0 0.6rem;
  overflow-wrap: anywhere;
}
.contact .mail:hover { text-decoration: underline; }
.contact p { margin: 0; font-size: 0.92rem; color: var(--text-mute); }

/* Definition-list FAQ: question in white, answer indented under it. */
.faq { margin: 0; }
.faq dt {
  font-weight: 800;
  color: var(--text);
  margin-top: 1.6rem;
  font-size: 1.02rem;
}
.faq dd { margin: 0.4rem 0 0; }

/* ── Footer ─────────────────────────────────────────────────────────────── */

.site-foot {
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  padding-block: 2rem 2.5rem;
  margin-top: auto;
}
.site-foot .wrap {
  display: flex;
  gap: 1rem 2rem;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  font-size: 0.88rem;
  color: var(--text-mute);
}
.foot-links { display: flex; gap: 1.4rem; flex-wrap: wrap; }
.foot-links a { text-decoration: none; font-weight: 700; }
.foot-links a:hover { text-decoration: underline; }

@media (max-width: 560px) {
  .site-head .wrap { justify-content: center; }
  .brand { margin-right: 0; }
  .site-foot .wrap { justify-content: center; text-align: center; }
}
