/* pixelgrove.app — design tokens + shared components.
   Palette is the app's own (shared/…/ui/Theme.kt, `Grove.*`), not the cream family the
   sibling sites share: the site should look like the app it sells. Dark only.

   Contrast (WCAG relative luminance, measured by tools/contrast.py):
     --moon  on --night  15.6:1   body text
     --moon  on --bark   14.2:1   body text on panels
     --mint  on --night  16.4:1   headline accent, links
     --mint  on --bark   15.0:1
     --mist  on --night   6.3:1   passes 4.5:1, but kept to small labels and footers
     --mist  on --bark    5.8:1   (dimmer than body text on purpose, not as body copy)
     --night on --ember  11.1:1   button label
     --ember on --night  11.1:1   focus ring, "coming soon" chip
   Fonts are self-hosted (fonts/): the site promises no third-party requests, and the
   privacy page says so. Display: Fredoka (the app's board digits use it). Body: Inter. */

@font-face { font-family: "Fredoka"; src: url("/fonts/fredoka-latin.woff2") format("woff2"); font-weight: 300 700; font-display: swap; }
@font-face { font-family: "Inter"; src: url("/fonts/inter-latin.woff2") format("woff2"); font-weight: 100 900; font-display: swap; }

:root {
  --night: #0B0B16;       /* page base */
  --bark: #161624;        /* panels, cards */
  --bark-light: #20203A;  /* raised panels, hairline borders */
  --moon: #E0E4FF;        /* body text */
  --mist: #8A90B8;        /* small labels only, see contrast note */
  --mint: #BFF7E0;        /* headline accent, links */
  --ember: #FFB454;       /* buttons, focus, the glow */
  --glow: rgba(255, 180, 84, .28);      /* --ember, translucent */
  --glow-mint: rgba(191, 247, 224, .14); /* --mint, translucent */
  --focus: var(--ember);
  --display: "Fredoka", "Trebuchet MS", sans-serif;
  --body: "Inter", -apple-system, "Segoe UI", sans-serif;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
img { max-width: 100%; height: auto; display: block; }
/* Pixel art: served at native size, scaled by the browser without smoothing. */
.pixel { image-rendering: pixelated; image-rendering: crisp-edges; }

body {
  font-family: var(--body);
  color: var(--moon);
  background: var(--night);
  font-size: 17px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3 { font-family: var(--display); font-weight: 600; line-height: 1.2; letter-spacing: .01em; }
h1 { font-size: clamp(2.6rem, 7vw, 4.4rem); color: var(--mint); }
h2 { font-size: clamp(1.7rem, 3.6vw, 2.4rem); margin-bottom: 18px; }
h3 { font-size: 1.3rem; margin-bottom: 8px; color: var(--mint); }
p { margin: 0 0 14px; }
p:last-child { margin-bottom: 0; }
a { color: var(--mint); text-underline-offset: 3px; }
a:hover { color: var(--ember); }

.wrap { max-width: 1120px; margin: 0 auto; padding: 0 24px; }

/* ---- a11y ---- */
.skip-link { position: absolute; left: -999px; top: 0; background: var(--focus); color: var(--night); padding: .6rem 1rem; z-index: 100; font-weight: 600; }
.skip-link:focus { left: 0; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 3px; }
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation: none !important; transition: none !important; } html { scroll-behavior: auto; } }

/* ---- header / nav ---- */
.site-header { border-bottom: 1px solid var(--bark-light); }
.site-header .wrap { display: flex; align-items: center; gap: 20px; flex-wrap: wrap; padding-top: 18px; padding-bottom: 18px; }
.brand {
  display: inline-flex; align-items: center; gap: 10px; margin-right: auto;
  font-family: var(--display); font-weight: 600; font-size: 1.35rem; color: var(--moon); text-decoration: none;
}
.brand img { width: 32px; height: 32px; }
.brand-accent { color: var(--mint); }
.site-nav { display: flex; align-items: center; gap: 22px; flex-wrap: wrap; }
.site-nav a { text-decoration: none; font-size: .95rem; color: var(--moon); }
.site-nav a:hover { color: var(--ember); }
.site-nav a[aria-current="page"] { color: var(--mint); font-weight: 600; }

/* ---- buttons ---- */
.btn {
  display: inline-block; text-decoration: none; font-weight: 600; font-size: 1rem;
  padding: 13px 26px; border-radius: 14px; margin: 0 12px 12px 0;
  background: var(--ember); color: var(--night); border: 2px solid var(--ember);
  box-shadow: 0 0 24px var(--glow);
  transition: box-shadow .2s ease, transform .2s ease;
}
.btn:hover { color: var(--night); box-shadow: 0 0 36px var(--glow); transform: translateY(-1px); }
.btn--outline { background: transparent; color: var(--mint); border-color: var(--bark-light); box-shadow: none; }
.btn--outline:hover { color: var(--mint); border-color: var(--mint); box-shadow: none; }

/* ---- hero ---- */
.hero { padding: 64px 0 40px; text-align: center; }
.hero .lede { font-size: clamp(1.15rem, 2.2vw, 1.4rem); max-width: 38ch; margin: 18px auto 10px; }
.coming-soon {
  display: inline-block; margin-top: 10px; padding: 6px 16px; border-radius: 14px;
  background: var(--bark); border: 1px solid var(--bark-light);
  font-family: var(--display); font-weight: 500; color: var(--ember); font-size: 1rem;
}
.hero-art { position: relative; margin: 40px auto 0; max-width: 1040px; }
.hero-art img { border-radius: 20px; border: 1px solid var(--bark-light); }
/* The glow: a soft ember halo under the lit path. It breathes once every 6s, slowly;
   prefers-reduced-motion switches it off (see a11y block above). */
.hero-art::after {
  content: ""; position: absolute; left: 20%; right: 20%; bottom: -6%; height: 40%; z-index: -1;
  background: radial-gradient(closest-side, var(--glow), transparent);
  filter: blur(18px);
  animation: breathe 6s ease-in-out infinite;
}
@keyframes breathe { 0%, 100% { opacity: .55; } 50% { opacity: 1; } }
@media (max-width: 480px) { .coming-soon { font-size: .9rem; } .hero { padding-top: 40px; } }

/* ---- sections ---- */
.section { padding: 72px 0; }
.section--panel { background: var(--bark); border-top: 1px solid var(--bark-light); border-bottom: 1px solid var(--bark-light); }
.section-intro { max-width: 60ch; margin-bottom: 36px; }
.eyebrow { display: block; font-size: .8rem; letter-spacing: .14em; text-transform: uppercase; color: var(--mist); margin-bottom: 10px; font-weight: 600; }

.grid { display: grid; gap: 24px; }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-2 { grid-template-columns: 1fr 1fr; align-items: center; gap: 48px; }
@media (max-width: 860px) { .grid-3, .grid-2 { grid-template-columns: 1fr; } .grid-2 { gap: 32px; } }

.card { background: var(--bark); border: 1px solid var(--bark-light); border-radius: 18px; padding: 28px; }
.section--panel .card { background: var(--night); }
.card .sprite { width: 128px; height: 128px; margin-bottom: 18px; border-radius: 12px; }

.story-art img { border-radius: 16px; border: 1px solid var(--bark-light); }
.caption { font-size: .85rem; color: var(--mist); margin-top: 10px; }
.signoff { font-family: var(--display); font-weight: 500; color: var(--mint); font-size: 1.1rem; }

/* ---- creator callout ---- */
.callout {
  display: grid; grid-template-columns: auto 1fr; gap: 32px; align-items: center;
  background: linear-gradient(135deg, var(--bark), var(--bark-light));
  border: 1px solid var(--bark-light); border-radius: 22px; padding: 40px;
  box-shadow: 0 0 60px var(--glow-mint);
}
.callout .sprite { width: 192px; height: 192px; border-radius: 14px; }
.callout .fine { font-size: .9rem; color: var(--mist); margin-top: 6px; }
@media (max-width: 700px) { .callout { grid-template-columns: 1fr; padding: 28px; } .callout .sprite { width: 128px; height: 128px; } }

/* ---- prose (privacy) ---- */
.page-head { padding: 56px 0 8px; }
.page-head h1 { font-size: clamp(2.2rem, 5vw, 3.2rem); }
.page-head .meta { color: var(--mist); font-size: .95rem; margin-top: 10px; }
.prose { max-width: 70ch; }
.prose h2 { font-size: 1.5rem; margin: 40px 0 12px; color: var(--mint); }
.prose ul { margin: 0 0 14px 1.2em; }
.prose li { margin-bottom: 6px; }
.prose strong { color: #fff; }

/* ---- footer ---- */
.site-footer { border-top: 1px solid var(--bark-light); padding: 32px 0 40px; font-size: .9rem; color: var(--mist); }
.site-footer .wrap { display: flex; gap: 12px 28px; flex-wrap: wrap; align-items: center; }
.site-footer .spacer { margin-right: auto; }
.site-footer a { color: var(--mist); }
.site-footer a:hover { color: var(--ember); }

/* ---- 404 ---- */
.not-found { padding: 96px 0; text-align: center; }
.not-found .sprite { width: 192px; height: 192px; margin: 0 auto 28px; }
.not-found h1 { margin-bottom: 14px; }
