/* Typy marketing site. Plain CSS, no build step. Palette comes from the app icon (indigo + yellow). */
:root {
  --bg: #fbf8ee;
  --surface: #ffffff;
  --ink: #1b1250;
  --muted: #5b5687;
  --line: #e4dfcd;
  --brand: #2f2179;
  --brand-deep: #1f125c;
  --accent: #fbd500;
  --accent-ink: #1b1250;
  --key-bg: #ffffff;
  --shadow: 0 1px 0 rgba(31, 18, 92, 0.06), 0 12px 32px -18px rgba(31, 18, 92, 0.35);
  --font: "Nunito", ui-rounded, "Segoe UI", system-ui, sans-serif;
  --mono: ui-monospace, "Cascadia Mono", Consolas, monospace;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #150c3d;
    --surface: #1f125c;
    --ink: #f4f1ff;
    --muted: #b3aedf;
    --line: #35288a;
    --brand: #6f5fd6;
    --brand-deep: #0f0830;
    --accent-ink: #1b1250;
    --key-bg: #2f2179;
    --shadow: 0 1px 0 rgba(0, 0, 0, 0.3), 0 18px 40px -22px rgba(0, 0, 0, 0.8);
    color-scheme: dark;
  }
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font);
  font-size: 18px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: inherit; }
h1, h2, h3 { line-height: 1.12; margin: 0; letter-spacing: -0.01em; text-wrap: balance; }
h1 { font-size: clamp(2.3rem, 6vw, 4rem); font-weight: 900; }
h2 { font-size: clamp(1.7rem, 3.6vw, 2.5rem); font-weight: 800; }
h3 { font-size: 1.2rem; font-weight: 800; }
p { margin: 0; }
.wrap { width: 100%; max-width: 1080px; margin: 0 auto; padding-inline: 20px; }

/* header */
header.top { position: sticky; top: 0; z-index: 10; background: color-mix(in srgb, var(--bg) 88%, transparent); backdrop-filter: blur(10px); border-bottom: 1px solid var(--line); }
header.top .wrap { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding-block: 12px; }
.brand { display: inline-flex; align-items: center; gap: 10px; font-weight: 900; font-size: 1.25rem; text-decoration: none; }
.brand img { width: 34px; height: 34px; border-radius: 9px; }
nav.links { display: flex; align-items: center; gap: 20px; font-size: 0.95rem; font-weight: 700; }
nav.links a { text-decoration: none; color: var(--muted); }
nav.links a:hover { color: var(--ink); }
@media (max-width: 720px) { nav.links a:not(.btn) { display: none; } }

/* buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 12px 22px; border-radius: 999px; font: inherit; font-weight: 800; font-size: 1rem;
  text-decoration: none; border: 2px solid transparent; cursor: pointer;
}
.btn.primary { background: var(--accent); color: var(--accent-ink); }
.btn.primary:hover { filter: brightness(1.05); }
.btn.ghost { border-color: var(--ink); color: var(--ink); background: transparent; }
.btn.ghost:hover { background: color-mix(in srgb, var(--ink) 8%, transparent); }
.btn.small { padding: 8px 16px; font-size: 0.9rem; }
.btn[aria-disabled="true"] { opacity: 0.55; pointer-events: none; }

/* hero */
.hero { padding-block: clamp(48px, 9vw, 104px) 56px; }
.hero .wrap { display: grid; grid-template-columns: 1.15fr 0.85fr; gap: 48px; align-items: center; }
.hero p.lede { margin-top: 20px; font-size: 1.25rem; color: var(--muted); max-width: 34em; }
.hero .cta { margin-top: 28px; display: flex; flex-wrap: wrap; gap: 12px; }
.hero .fine { margin-top: 18px; font-size: 0.95rem; color: var(--muted); }
.mock {
  background: var(--brand-deep); color: #f4f1ff; border-radius: 22px; padding: 18px; box-shadow: var(--shadow);
  border: 1px solid rgba(255, 255, 255, 0.08);
}
.mock .bar { display: flex; align-items: center; gap: 8px; font-size: 0.85rem; opacity: 0.85; margin-bottom: 14px; }
.mock .bar b { color: var(--accent); }
.bubble { border-radius: 14px; padding: 10px 14px; font-size: 0.95rem; line-height: 1.5; margin-top: 10px; max-width: 92%; }
.bubble.me { margin-left: auto; background: var(--accent); color: #1b1250; border-bottom-right-radius: 4px; font-weight: 700; }
.bubble.typy { background: #2f2179; border: 1px solid #35288a; border-bottom-left-radius: 4px; }
.bubble.typy ol { margin: 6px 0 0; padding-left: 20px; }
@media (max-width: 860px) { .hero .wrap { grid-template-columns: 1fr; } }

/* sections */
section { padding-block: clamp(48px, 8vw, 88px); }
section.alt { background: color-mix(in srgb, var(--brand) 7%, var(--bg)); }
.eyebrow { font-family: var(--mono); font-size: 0.8rem; letter-spacing: 0.14em; text-transform: uppercase; color: var(--muted); margin-bottom: 10px; }
.section-head { max-width: 40em; margin-bottom: 36px; }
.section-head p { margin-top: 12px; color: var(--muted); }
.grid { display: grid; gap: 18px; }
.grid.three { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid.two { grid-template-columns: repeat(2, minmax(0, 1fr)); max-width: 820px; }
@media (max-width: 860px) { .grid.three, .grid.two { grid-template-columns: 1fr; } }
.card { background: var(--surface); border: 1px solid var(--line); border-radius: 20px; padding: 24px; box-shadow: var(--shadow); min-width: 0; }
.card h3 { margin-bottom: 8px; }
.card p, .card li { color: var(--muted); font-size: 1rem; }
.card ul { margin: 12px 0 0; padding-left: 20px; }
.card .btn { margin-top: 18px; }
.tag { display: inline-block; font-size: 0.75rem; font-weight: 800; padding: 3px 10px; border-radius: 999px; background: color-mix(in srgb, var(--accent) 30%, transparent); color: var(--ink); margin-bottom: 12px; }

/* steps */
.steps { counter-reset: step; display: grid; gap: 18px; grid-template-columns: repeat(3, minmax(0, 1fr)); }
@media (max-width: 860px) { .steps { grid-template-columns: 1fr; } }
.step { position: relative; padding-top: 8px; }
.step::before {
  counter-increment: step; content: counter(step);
  display: grid; place-items: center; width: 40px; height: 40px; border-radius: 12px;
  background: var(--accent); color: var(--accent-ink); font-weight: 900; margin-bottom: 14px;
}
.step p { color: var(--muted); margin-top: 6px; }
kbd {
  font-family: var(--mono); font-size: 0.85em; background: var(--key-bg); color: var(--ink);
  border: 1px solid var(--line); border-bottom-width: 3px; border-radius: 8px; padding: 1px 8px; white-space: nowrap;
}
.promise {
  margin-top: 28px; padding: 20px 24px; border-radius: 18px; border: 2px dashed var(--brand);
  font-weight: 800; font-size: 1.1rem;
}

/* faq */
details { border-top: 1px solid var(--line); padding-block: 16px; }
details:last-of-type { border-bottom: 1px solid var(--line); }
summary { cursor: pointer; font-weight: 800; font-size: 1.1rem; }
details p { margin-top: 10px; color: var(--muted); max-width: 46em; }

/* install steps inside a download card */
.card details.howto { margin-top: 16px; padding-block: 10px; border-bottom: 1px solid var(--line); }
.card details.howto summary { font-size: 0.98rem; }
.card details.howto ol { margin: 10px 0 0; padding-left: 20px; }
.card details.howto li { margin-bottom: 6px; font-size: 0.95rem; }
.card details.howto p { font-size: 0.95rem; }

/* footer */
footer { border-top: 1px solid var(--line); padding-block: 36px; color: var(--muted); font-size: 0.95rem; }
footer .wrap { display: flex; flex-wrap: wrap; gap: 12px 28px; justify-content: space-between; }
footer nav { display: flex; flex-wrap: wrap; gap: 8px 22px; }

/* legal pages */
.legal { padding-block: 56px 80px; }
.legal .wrap { max-width: 760px; }
.legal h1 { font-size: clamp(2rem, 5vw, 2.8rem); margin-bottom: 8px; }
.legal h2 { font-size: 1.4rem; margin: 36px 0 8px; }
.legal p, .legal li { color: var(--muted); }
.legal p + p { margin-top: 12px; }
.legal ul { padding-left: 22px; margin: 10px 0; }
.legal .updated { font-family: var(--mono); font-size: 0.85rem; color: var(--muted); margin-bottom: 28px; }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; }
