/* PixelVoxel marketing site — Soft-Voxel design system.
   Mirrors the game's tokens (src/game/ui/theme.ts) so the site and game read as
   one world. Brand: trust, learning, fun. Plain CSS, no framework, renders fully
   with JS off. Depth comes from a heavy BOTTOM border (moulded-brick), not drop
   shadows. Nothing rounded below 12px ("No-Sharp" rule). */

/* ---- Self-hosted Quicksand (no Google Fonts request — privacy + offline) ---- */
@font-face {
  font-family: "Quicksand";
  font-style: normal;
  font-weight: 300 700;
  font-display: swap;
  src: url("fonts/quicksand-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA,
    U+02DC, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Quicksand";
  font-style: normal;
  font-weight: 300 700;
  font-display: swap;
  src: url("fonts/quicksand-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-024F, U+0259, U+1E00-1EFF, U+2020, U+20A0-20AB, U+20AD-20CF,
    U+2113, U+2C60-2C7F, U+A720-A7FF;
}

:root {
  /* Brand palette (from theme.ts) */
  --sky: #7ec4ff;
  --grass: #7ed957;
  --sun: #ffd23f;
  --go: #3c8527;
  --go-dark: #2c6a1c;
  --warm: #ff8a5c;
  --dig: #ffb347;
  --grape: #c9a6ff;
  --ink: #1b2440;
  --snow: #ffffff;
  --muted: #5a6b86;
  --bg: #eaf5ff;
  --surface: #faf8ff;
  --surface-alt: #ebedff;
  --outline: #c0c7d1;
  --lock-grey: #dfe3ea;

  --radius-sm: 12px;
  --radius-md: 16px;
  --radius-lg: 22px;
  --radius-xl: 28px;
  --pill: 999px;

  --maxw: 1080px;
  --font: "Quicksand", system-ui, -apple-system, "Segoe UI", sans-serif;

  /* The Soft-Voxel depth: heavy bottom edge + soft top bevel */
  --voxel-bevel: inset 0 2px 0 rgba(255, 255, 255, 0.7);
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font);
  font-weight: 600;
  color: var(--ink);
  background: linear-gradient(180deg, #eaf5ff 0%, #dbe9ff 100%);
  background-attachment: fixed;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

h1, h2, h3 { font-weight: 700; line-height: 1.12; margin: 0 0 0.4em; letter-spacing: -0.01em; }
h1 { font-size: clamp(2rem, 5.2vw, 3.4rem); }
h2 { font-size: clamp(1.5rem, 3.6vw, 2.3rem); }
h3 { font-size: 1.2rem; }
p { margin: 0 0 1rem; }
a { color: var(--go); text-decoration: none; }
a:hover { text-decoration: underline; }
img { max-width: 100%; display: block; }

.container { width: 100%; max-width: var(--maxw); margin: 0 auto; padding: 0 20px; }
.section { padding: clamp(48px, 8vw, 92px) 0; }
.center { text-align: center; }
.eyebrow {
  display: inline-block;
  font-weight: 700;
  font-size: 0.85rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--go);
  background: rgba(60, 133, 39, 0.1);
  padding: 6px 14px;
  border-radius: var(--pill);
  margin-bottom: 16px;
}
.lead { font-size: clamp(1.05rem, 2.2vw, 1.3rem); color: #2c3550; max-width: 46ch; }
.muted { color: var(--muted); }

/* ---- Buttons: squishy voxel ---- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  font-family: var(--font);
  font-weight: 700;
  font-size: 1.05rem;
  line-height: 1;
  padding: 16px 26px;
  border: none;
  border-radius: var(--pill);
  cursor: pointer;
  text-decoration: none;
  transition: transform 0.06s ease, box-shadow 0.06s ease;
}
.btn:hover { text-decoration: none; }
.btn:active { transform: translateY(3px); }
.btn-primary {
  background: var(--go);
  color: var(--snow);
  box-shadow: 0 5px 0 var(--go-dark), var(--voxel-bevel);
}
.btn-primary:active { box-shadow: 0 2px 0 var(--go-dark), var(--voxel-bevel); }
.btn-secondary {
  background: var(--snow);
  color: var(--ink);
  border: 2px solid var(--outline);
  border-bottom-width: 5px;
}
.btn-lg { font-size: 1.15rem; padding: 18px 32px; }

/* ---- Voxel card: the heavy-bottom moulded-brick surface ---- */
.card {
  background: var(--surface);
  border: 2px solid var(--outline);
  border-bottom-width: 6px;
  border-radius: var(--radius-lg);
  box-shadow: var(--voxel-bevel);
  padding: 26px;
}

/* ---- Trust chips ---- */
.chips { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; }
.chip {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-weight: 700;
  font-size: 0.95rem;
  background: var(--snow);
  color: var(--ink);
  border: 2px solid var(--outline);
  border-bottom-width: 4px;
  border-radius: var(--pill);
  padding: 9px 16px;
}
.chip .x { color: #d64545; font-weight: 800; }
.chip .ok { color: var(--go); font-weight: 800; }

/* ---- Nav ---- */
.nav {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(234, 245, 255, 0.85);
  backdrop-filter: saturate(1.2) blur(8px);
  border-bottom: 2px solid rgba(192, 199, 209, 0.6);
}
.nav .container { display: flex; align-items: center; justify-content: space-between; padding-top: 12px; padding-bottom: 12px; }
.brand { display: inline-flex; align-items: center; gap: 10px; font-weight: 700; font-size: 1.25rem; color: var(--ink); }
.brand:hover { text-decoration: none; }
.brand img { width: 34px; height: 34px; }
.nav-links { display: flex; align-items: center; gap: 22px; }
.nav-links a { color: var(--ink); font-weight: 700; font-size: 0.98rem; }
.nav-toggle { display: none; background: none; border: none; font-size: 1.6rem; cursor: pointer; color: var(--ink); }

/* ---- Hero ---- */
.hero { padding: clamp(40px, 7vw, 80px) 0 clamp(36px, 6vw, 64px); }
.hero-grid { display: grid; grid-template-columns: 1.05fr 1fr; gap: clamp(28px, 5vw, 56px); align-items: center; }
.hero h1 { margin-bottom: 18px; }
.hero .lead { max-width: 40ch; margin-bottom: 26px; }
.hero-cta { display: flex; flex-wrap: wrap; gap: 14px; align-items: center; }
.media-frame {
  border: 3px solid var(--ink);
  border-bottom-width: 9px;
  border-radius: var(--radius-xl);
  overflow: hidden;
  background: var(--sky);
  box-shadow: var(--voxel-bevel);
}
.media-frame img, .media-frame video { display: block; width: 100%; height: auto; }

/* ---- Honest-money block ---- */
.money {
  background: var(--ink);
  color: var(--snow);
  border-radius: var(--radius-xl);
  border-bottom: 8px solid #0f1730;
  padding: clamp(28px, 5vw, 48px);
}
.money h2 { color: var(--snow); }
.money p { color: #cfd8ee; font-size: 1.1rem; }
.money strong { color: var(--snow); }
.money .callout {
  margin-top: 22px;
  padding: 20px 22px;
  background: rgba(126, 196, 255, 0.14);
  border: 2px solid rgba(126, 196, 255, 0.4);
  border-radius: var(--radius-md);
}
.money .callout strong { color: var(--sun); }

/* ---- Pillars ---- */
.pillars { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 22px; }
.pillar { display: flex; flex-direction: column; }
.pillar .badge {
  width: 52px; height: 52px;
  display: grid; place-items: center;
  font-size: 1.7rem;
  background: var(--sky);
  border-radius: var(--radius-md);
  border-bottom: 4px solid #4fa0e6;
  margin-bottom: 14px;
}
.pillar h3 { margin-bottom: 8px; }
.pillar p { color: #39435f; }

/* ---- Comparison table ---- */
.compare { width: 100%; border-collapse: separate; border-spacing: 0; overflow: hidden; border-radius: var(--radius-lg); border: 2px solid var(--outline); border-bottom-width: 6px; background: var(--surface); }
.compare th, .compare td { padding: 14px 16px; text-align: left; border-bottom: 1px solid #e3e7ef; }
.compare thead th { background: var(--surface-alt); font-size: 0.98rem; }
.compare thead th:last-child { color: var(--go); }
.compare tbody tr:last-child td { border-bottom: none; }
.compare td:first-child { color: var(--muted); }
.compare .yes { color: var(--go); font-weight: 700; }
.compare .no { color: #c0563f; font-weight: 700; }

/* ---- Price card ---- */
.price-card { max-width: 460px; margin: 0 auto; text-align: center; }
.price-card .amount { font-size: 3.4rem; font-weight: 700; color: var(--ink); line-height: 1; }
.price-card .amount small { font-size: 1.1rem; color: var(--muted); font-weight: 700; }
.price-list { list-style: none; padding: 0; margin: 20px 0; text-align: left; display: inline-block; }
.price-list li { padding: 7px 0 7px 30px; position: relative; }
.price-list li::before { content: "✓"; position: absolute; left: 0; color: var(--go); font-weight: 800; }
.refund { margin-top: 14px; font-size: 0.95rem; color: var(--muted); }

/* ---- Promise / proof list ---- */
.proof { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 16px; list-style: none; padding: 0; }
.proof li { background: var(--surface); border: 2px solid var(--outline); border-bottom-width: 5px; border-radius: var(--radius-md); padding: 18px 20px; font-size: 0.98rem; }
.proof .n { display: inline-grid; place-items: center; width: 26px; height: 26px; background: var(--go); color: #fff; border-radius: var(--pill); font-weight: 800; font-size: 0.85rem; margin-right: 8px; }

/* ---- FAQ ---- */
.faq details { background: var(--surface); border: 2px solid var(--outline); border-bottom-width: 5px; border-radius: var(--radius-md); padding: 4px 20px; margin-bottom: 12px; }
.faq summary { font-weight: 700; cursor: pointer; padding: 14px 0; list-style: none; font-size: 1.05rem; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; float: right; color: var(--go); font-weight: 800; font-size: 1.3rem; }
.faq details[open] summary::after { content: "–"; }
.faq details p { color: #39435f; padding-bottom: 8px; margin: 0; }

/* ---- Generic two-col + lists ---- */
.split { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(24px, 4vw, 48px); align-items: center; }
.stack > * + * { margin-top: 14px; }
.ticks { list-style: none; padding: 0; }
.ticks li { padding: 6px 0 6px 28px; position: relative; }
.ticks li::before { content: "✓"; position: absolute; left: 0; color: var(--go); font-weight: 800; }
.crosses li::before { content: "✗"; color: #d64545; }

/* ---- Footer ---- */
.footer { background: var(--ink); color: #cfd8ee; padding: 40px 0; margin-top: 40px; }
.footer a { color: var(--sky); font-weight: 700; }
.footer .row { display: flex; flex-wrap: wrap; gap: 18px 26px; align-items: center; }
.footer .small { font-size: 0.88rem; color: #8b99bd; margin-top: 14px; }

/* ---- Section tints ---- */
.tint { background: rgba(255, 255, 255, 0.5); }

/* ---- Responsive ---- */
@media (max-width: 860px) {
  .hero-grid { grid-template-columns: 1fr; }
  .split { grid-template-columns: 1fr; }
  .nav-links {
    display: none;
    position: absolute; top: 100%; left: 0; right: 0;
    flex-direction: column; gap: 0;
    background: var(--surface); border-bottom: 2px solid var(--outline);
    padding: 8px 0;
  }
  .nav-links.open { display: flex; }
  .nav-links a { padding: 12px 20px; width: 100%; }
  .nav-toggle { display: block; }
}

/* ---- Interactive "earn it by learning" demo (learn-to-earn page) ---- */
.earn-demo {
  background: var(--surface);
  border: 2px solid var(--outline);
  border-bottom-width: 6px;
  border-radius: var(--radius-lg);
  box-shadow: var(--voxel-bevel);
  padding: 22px;
  margin: 18px 0;
}
.earn-head { color: var(--muted); font-weight: 700; margin-bottom: 14px; text-align: center; }
.earn-shelf { display: flex; gap: 12px; flex-wrap: wrap; }
.earn-reward {
  flex: 1 1 0; min-width: 96px; text-align: center; padding: 14px 10px;
  border-radius: var(--radius-md); border: 2px solid var(--outline); border-bottom-width: 4px;
  position: relative; transition: transform 0.2s ease, background 0.3s ease, opacity 0.3s ease, filter 0.3s ease;
}
.earn-reward.locked { background: var(--lock-grey); opacity: 0.6; filter: grayscale(0.6); }
.earn-reward.unlocked { background: #eafaf0; border-color: var(--grass); opacity: 1; filter: none; }
.earn-emoji { font-size: 2rem; line-height: 1; }
.earn-rlabel { font-weight: 700; font-size: 0.85rem; margin-top: 6px; }
.earn-lock { position: absolute; top: 6px; right: 8px; font-size: 0.9rem; }
.earn-reward.pop { animation: earnpop 0.5s ease; }
@keyframes earnpop { 0% { transform: scale(1); } 40% { transform: scale(1.14); } 100% { transform: scale(1); } }
.earn-puzzle { margin-top: 18px; }
.earn-q { text-align: center; }
.earn-qtext { font-size: 1.5rem; font-weight: 700; }
.earn-qsub { font-size: 1.3rem; font-weight: 700; color: var(--muted); margin-top: 4px; }
.earn-choices { display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; margin-top: 14px; }
.earn-choice {
  font-family: var(--font); font-weight: 700; font-size: 1.2rem; min-width: 60px; padding: 12px 20px;
  border-radius: var(--pill); border: 2px solid var(--outline); border-bottom-width: 5px;
  background: var(--snow); color: var(--ink); cursor: pointer; transition: transform 0.06s ease, border-color 0.2s ease;
}
.earn-choice:active { transform: translateY(3px); }
.earn-choice.wrong { border-color: #d64545; animation: earnshake 0.3s; }
@keyframes earnshake { 0%, 100% { transform: translateX(0); } 25% { transform: translateX(-5px); } 75% { transform: translateX(5px); } }
.earn-feedback { text-align: center; font-weight: 700; margin-top: 12px; min-height: 1.4em; color: var(--go); }
.earn-done { text-align: center; }
.earn-cta { display: flex; gap: 10px; justify-content: center; margin-top: 14px; flex-wrap: wrap; }
.earn-example { margin: 16px 0 0; color: var(--muted); font-size: 0.95rem; text-align: center; line-height: 1.5; }
