/* ChibChob public site — same palette as the HQ dashboard (apps/web/src/styles.css). Fonts are self-hosted:
   no request goes to Google or any other third party. */
@font-face {
  font-family: "Baloo 2";
  src: url("/fonts/baloo2-latin.woff2") format("woff2");
  font-weight: 400 800;
  font-display: swap;
}
@font-face {
  font-family: "Nunito";
  src: url("/fonts/nunito-latin.woff2") format("woff2");
  font-weight: 200 1000;
  font-display: swap;
}

:root {
  --bg: #fff6ea;
  --bg-dots: #f6e3c8;
  --card: #fffdf9;
  --ink: #3b2418;
  --ink-soft: #7a5a45;
  --line: rgba(92, 52, 28, 0.12);
  --caramel: #f0b36a;
  --choco: #b26544;
  --mint: #5fbba8;
  --orange: #f98b5b;
  --yellow: #f7c948;
  --shadow: 0 2px 0 rgba(120, 70, 30, 0.06), 0 10px 28px -12px rgba(120, 70, 30, 0.28);
  --radius: 22px;
  --font: "Nunito", ui-rounded, system-ui, -apple-system, "Segoe UI", sans-serif;
  --display: "Baloo 2", "Nunito", ui-rounded, system-ui, sans-serif;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  font-family: var(--font);
  font-size: 17px;
  line-height: 1.6;
  color: var(--ink);
  background: var(--bg) radial-gradient(var(--bg-dots) 1.5px, transparent 1.6px) 0 0 / 22px 22px;
  -webkit-font-smoothing: antialiased;
}
h1, h2, h3 { font-family: var(--display); line-height: 1.15; margin: 0 0 0.4em; font-weight: 800; }
h1 { font-size: clamp(32px, 6vw, 52px); letter-spacing: -0.5px; }
h2 { font-size: clamp(24px, 3.4vw, 30px); }
h3 { font-size: 21px; }
p { margin: 0 0 1em; }
a { color: var(--choco); font-weight: 700; text-underline-offset: 3px; overflow-wrap: anywhere; }
a:hover { color: var(--orange); }
:focus-visible { outline: 3px solid var(--mint); outline-offset: 2px; border-radius: 6px; }

.wrap { width: 100%; max-width: 1040px; margin: 0 auto; padding: 0 20px; }

/* Header */
.top { padding: 18px 0; }
.top .wrap { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; color: var(--ink); }
.brand img { width: 48px; height: 48px; }
.brand b { font-family: var(--display); font-size: 28px; font-weight: 800; letter-spacing: -0.5px; line-height: 1; }
.brand small { display: block; font-size: 11px; color: var(--ink-soft); font-weight: 800; letter-spacing: 1.5px; text-transform: uppercase; }
.nav { display: flex; gap: 6px; flex-wrap: wrap; }
.nav a {
  text-decoration: none; color: var(--ink-soft); font-weight: 800; font-size: 15px;
  padding: 7px 14px; border-radius: 999px;
}
.nav a:hover { background: var(--card); color: var(--ink); }
.nav a[aria-current="page"] { background: var(--card); color: var(--choco); box-shadow: var(--shadow); }

main.main { flex: 1; padding: 8px 0 48px; }

/* Home */
.hero {
  display: grid; grid-template-columns: 1.25fr 1fr; gap: 32px; align-items: center;
  padding: 28px 0 40px;
}
.hero .eyebrow { font-weight: 800; color: var(--mint); letter-spacing: 1.5px; text-transform: uppercase; font-size: 13px; margin-bottom: 8px; }
.hero p.lead { font-size: 19px; color: var(--ink-soft); font-weight: 600; max-width: 34em; }
.hero-art { display: flex; justify-content: center; }
.hero-art img { width: 100%; max-width: 360px; height: auto; filter: drop-shadow(0 18px 24px rgba(120, 70, 30, 0.22)); }
.btn {
  display: inline-block; text-decoration: none; color: #fff; background: var(--choco);
  font-weight: 800; font-size: 17px; padding: 12px 22px; border-radius: 999px;
  box-shadow: 0 4px 0 #8a4a2f;
}
.btn:hover { color: #fff; background: #c2724f; }

.section { margin: 0 0 36px; }
.cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.card {
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
  box-shadow: var(--shadow); padding: 22px 24px;
}
.card .ico {
  width: 46px; height: 46px; border-radius: 14px; display: grid; place-items: center;
  font-size: 24px; margin-bottom: 12px;
}
.ico.mint { background: #d8f1eb; }
.ico.caramel { background: #fde7c9; }
.ico.yellow { background: #fdf0c2; }
.card p:last-child { margin-bottom: 0; }

.panel { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); padding: 26px 28px; }
.panel p:last-child { margin-bottom: 0; }

/* Legal pages */
.doc { max-width: 760px; }
.doc .meta { color: var(--ink-soft); font-weight: 600; font-size: 15px; margin-bottom: 1.6em; }
.doc h2 { font-size: 22px; margin-top: 1.6em; }
.doc ul, .doc ol { padding-left: 1.3em; margin: 0 0 1em; }
.doc li { margin-bottom: 0.35em; }

/* Footer: Privacy and Terms links on every page */
.foot { border-top: 1px solid var(--line); background: rgba(255, 253, 249, 0.75); padding: 22px 0 26px; font-size: 14.5px; color: var(--ink-soft); }
.foot .links { display: flex; gap: 8px 18px; flex-wrap: wrap; align-items: center; margin-bottom: 6px; }
.foot .links a { font-size: 15.5px; }
.foot p { margin: 0; }

@media (max-width: 760px) {
  body { font-size: 16px; }
  .top { padding: 14px 0 6px; }
  .brand img { width: 40px; height: 40px; }
  .brand b { font-size: 24px; }
  .nav a { padding: 6px 11px; font-size: 14.5px; }
  .hero { grid-template-columns: 1fr; gap: 8px; padding: 12px 0 28px; }
  .hero-art { order: -1; }
  .hero-art img { max-width: 200px; }
  .cards { grid-template-columns: 1fr; }
  .panel { padding: 20px; }
}
