/* Mindio — marketing site
   Tokens mirror ios/Mindio/DesignSystem/Tokens/MindioColor.swift exactly,
   so the site and the app feel like one thing. Type uses Fredoka (display)
   + Nunito (body) — the original family the app shipped with before the
   iOS build switched to SF Pro Rounded for zero-weight delivery. */

:root {
  --paper:        #FBF4E6;
  --surface:      #FFFDF8;
  --ink:          #3A3142;
  --ink-muted:    #9A91A0;

  --intellect:    #5B6EE1;
  --aesthetic:    #FF7A8A;
  --body:         #23B99A;
  --character:    #F5A623;
  --streak:       #F97316;

  --halo-bronze:  #C08A5A;
  --halo-silver:  #AEB4BE;
  --halo-gold:    #F5C542;

  --border:       rgba(58, 49, 66, 0.10);
  --border-soft:  rgba(58, 49, 66, 0.05);
  --shadow:       0 1px 2px rgba(58, 49, 66, 0.06),
                  0 12px 32px rgba(58, 49, 66, 0.08);

  --radius:       18px;
  --radius-lg:    22px;
  --radius-sm:    12px;
  --max:         1040px;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }

body {
  font-family: "Nunito", -apple-system, BlinkMacSystemFont,
               "SF Pro Text", "Helvetica Neue", system-ui, sans-serif;
  background: var(--paper);
  color: var(--ink);
  line-height: 1.55;
  font-size: 17px;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

.container {
  max-width: var(--max);
  margin: 0 auto;
  padding: 24px 24px 80px;
}

/* ---------- Nav ---------- */

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 0 36px;
}
.nav a.logo {
  font-family: "Fredoka", "Nunito", system-ui, sans-serif;
  font-weight: 600;
  font-size: 22px;
  letter-spacing: -0.01em;
  color: var(--ink);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 10px;
}
.nav a.logo img {
  width: 32px;
  height: 32px;
  border-radius: 8px;
}
.nav .links a {
  font-weight: 600;
  font-size: 15px;
  color: var(--ink-muted);
  text-decoration: none;
  margin-left: 22px;
}
.nav .links a:hover { color: var(--ink); }

/* ---------- Hero ---------- */

.hero {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 44px;
  align-items: center;
  margin: 24px 0 64px;
}
@media (max-width: 820px) {
  .hero { grid-template-columns: 1fr; gap: 24px; text-align: left; }
}

.hero .copy { max-width: 540px; }

.kicker {
  font-family: "Fredoka", system-ui, sans-serif;
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  color: var(--ink-muted);
  font-weight: 600;
  margin-bottom: 14px;
}

h1 {
  font-family: "Fredoka", system-ui, sans-serif;
  font-size: clamp(36px, 5.4vw, 56px);
  font-weight: 600;
  line-height: 1.08;
  letter-spacing: -0.02em;
  margin: 0 0 18px;
}

.hero p.lead {
  font-size: 19px;
  color: var(--ink-muted);
  margin: 0;
}

.cta-row {
  margin-top: 32px;
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}
.btn {
  display: inline-block;
  padding: 14px 26px;
  border-radius: 999px;
  font-family: "Fredoka", system-ui, sans-serif;
  font-size: 16px;
  font-weight: 600;
  text-decoration: none;
  border: 1px solid transparent;
  transition: transform 0.06s ease, box-shadow 0.15s ease;
}
.btn:active { transform: translateY(1px); }
.btn.primary {
  background: var(--ink);
  color: var(--paper);
  box-shadow: 0 4px 14px rgba(58, 49, 66, 0.18);
}
.btn.primary:hover { box-shadow: 0 6px 18px rgba(58, 49, 66, 0.24); }
.btn.secondary {
  background: var(--surface);
  color: var(--ink);
  border-color: var(--border);
}
.btn.secondary:hover { border-color: rgba(58, 49, 66, 0.25); }

/* Hero illustration tile — Milo + supporting cast peek */

.hero-art {
  position: relative;
  background: var(--surface);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
  border: 1px solid var(--border-soft);
  padding: 36px 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 320px;
}
.hero-art img.milo {
  width: 160px;
  height: 160px;
  border-radius: 32px;
  box-shadow: 0 12px 28px rgba(91, 110, 225, 0.18);
}
.hero-art .satellites {
  position: absolute;
  inset: 0;
  pointer-events: none;
}
.hero-art .satellites img {
  position: absolute;
  width: 60px;
  height: 60px;
  filter: drop-shadow(0 4px 8px rgba(58, 49, 66, 0.10));
}
.hero-art .satellites .top-left  { top: 26px;    left: 26px;   transform: rotate(-6deg); }
.hero-art .satellites .top-right { top: 26px;    right: 26px;  transform: rotate(6deg); }
.hero-art .satellites .bot-left  { bottom: 26px; left: 26px;   transform: rotate(8deg); }
.hero-art .satellites .bot-right { bottom: 26px; right: 26px;  transform: rotate(-4deg); }

/* ---------- Sections ---------- */

section {
  margin: 64px 0;
}

h2 {
  font-family: "Fredoka", system-ui, sans-serif;
  font-size: clamp(24px, 3vw, 32px);
  font-weight: 600;
  letter-spacing: -0.01em;
  margin: 0 0 14px;
  line-height: 1.15;
}

p { margin: 0 0 14px; color: var(--ink); }
p.muted { color: var(--ink-muted); }
p.large  { font-size: 19px; }

.section-intro { max-width: 640px; }

/* Four pieces grid */

.pieces {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
  margin-top: 28px;
}
@media (max-width: 700px) { .pieces { grid-template-columns: 1fr; } }

.piece {
  background: var(--surface);
  border: 1px solid var(--border-soft);
  border-radius: var(--radius);
  padding: 24px;
  display: flex;
  gap: 18px;
  align-items: flex-start;
  box-shadow: var(--shadow);
}
.piece .avatar {
  flex-shrink: 0;
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: var(--paper);
  display: flex;
  align-items: center;
  justify-content: center;
  border: 2px solid var(--border-soft);
}
.piece .avatar img { width: 56px; height: 56px; }
.piece .body { flex: 1; min-width: 0; }
.piece .label {
  font-family: "Fredoka", system-ui, sans-serif;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.18em;
  font-weight: 600;
  margin-bottom: 4px;
}
.piece h3 {
  font-family: "Fredoka", system-ui, sans-serif;
  font-size: 19px;
  margin: 0 0 6px;
  font-weight: 600;
}
.piece p {
  font-size: 15px;
  color: var(--ink-muted);
  margin: 0;
}
.piece.intellect .label { color: var(--intellect); }
.piece.intellect .avatar { border-color: rgba(91, 110, 225, 0.30); background: rgba(91, 110, 225, 0.08); }
.piece.aesthetic .label { color: var(--aesthetic); }
.piece.aesthetic .avatar { border-color: rgba(255, 122, 138, 0.30); background: rgba(255, 122, 138, 0.08); }
.piece.body      .label { color: var(--body); }
.piece.body      .avatar { border-color: rgba(35, 185, 154, 0.30); background: rgba(35, 185, 154, 0.08); }
.piece.character .label { color: var(--character); }
.piece.character .avatar { border-color: rgba(245, 166, 35, 0.30); background: rgba(245, 166, 35, 0.08); }

/* Steps */

.steps {
  list-style: none;
  padding: 0;
  margin: 24px 0 0;
  display: grid;
  gap: 16px;
}
.step {
  display: flex;
  gap: 16px;
  align-items: flex-start;
  background: var(--surface);
  border: 1px solid var(--border-soft);
  border-radius: var(--radius);
  padding: 18px 22px;
}
.step .n {
  flex-shrink: 0;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--ink);
  color: var(--paper);
  font-family: "Fredoka", system-ui, sans-serif;
  font-size: 15px;
  font-weight: 600;
  display: flex;
  align-items: center;
  justify-content: center;
}
.step p { margin: 4px 0 0; font-size: 16px; }

/* Illustration block — used in "books" callout */

.illust-block {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 36px;
  align-items: center;
  padding: 32px;
  background: var(--surface);
  border: 1px solid var(--border-soft);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
}
@media (max-width: 700px) {
  .illust-block { grid-template-columns: 1fr; padding: 24px; }
  .illust-block img { max-height: 220px; margin: 0 auto; }
}
.illust-block img { width: 100%; max-width: 320px; }
.illust-block.reverse { direction: rtl; }
.illust-block.reverse > * { direction: ltr; }

/* ---------- Doc pages (privacy / support) ---------- */

.doc h1 {
  font-size: clamp(30px, 4.5vw, 40px);
  margin-bottom: 6px;
}
.doc .updated {
  color: var(--ink-muted);
  font-size: 14px;
  margin-bottom: 36px;
}
.doc h2 {
  font-size: 21px;
  margin-top: 38px;
  margin-bottom: 10px;
}
.doc p, .doc li {
  font-size: 16px;
  color: var(--ink);
}
.doc ul { padding-left: 22px; }
.doc ul li { margin-bottom: 8px; }
.doc a { color: var(--intellect); }
.doc a:hover { text-decoration: underline; }

/* ---------- Footer ---------- */

footer {
  margin-top: 72px;
  padding-top: 28px;
  border-top: 1px solid var(--border);
  color: var(--ink-muted);
  font-size: 14px;
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
}
footer a {
  color: var(--ink-muted);
  text-decoration: none;
  margin-right: 18px;
}
footer a:hover { color: var(--ink); }
