/* Lite Notes — base stylesheet
   System fonts only, no external assets. Mobile-first. */

:root {
  --accent: #4a6274;          /* calm blue-grey */
  --accent-strong: #35505f;
  --accent-soft: #eef2f5;
  --bg: #ffffff;
  --bg-alt: #f6f8fa;
  --surface: #ffffff;
  --border: #e2e8ec;
  --text: #1f2a30;
  --text-muted: #5b6b74;
  --shadow: 0 1px 2px rgba(31, 42, 48, .06), 0 8px 24px rgba(31, 42, 48, .05);
  --radius: 12px;
  --maxw: 1080px;
  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial,
    sans-serif, "Apple Color Emoji", "Segoe UI Emoji";
  --mono: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, monospace;
}

@media (prefers-color-scheme: dark) {
  :root {
    --accent: #7fa6bd;
    --accent-strong: #a9c6d8;
    --accent-soft: #1d2830;
    --bg: #12181c;
    --bg-alt: #161e23;
    --surface: #1a232a;
    --border: #26333c;
    --text: #e6edf1;
    --text-muted: #9fb0ba;
    --shadow: 0 1px 2px rgba(0, 0, 0, .3), 0 8px 24px rgba(0, 0, 0, .25);
  }
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.6;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4 { line-height: 1.25; font-weight: 650; letter-spacing: -.01em; }
h1 { font-size: clamp(1.9rem, 4vw, 2.9rem); margin: 0 0 .5em; }
h2 { font-size: clamp(1.4rem, 3vw, 2rem); margin: 0 0 .6em; }
h3 { font-size: 1.15rem; margin: 0 0 .4em; }
p { margin: 0 0 1em; }

a { color: var(--accent-strong); text-decoration: none; }
a:hover { text-decoration: underline; }

.container {
  width: 100%;
  max-width: var(--maxw);
  margin-inline: auto;
  padding-inline: 20px;
}

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  background: color-mix(in srgb, var(--bg) 88%, transparent);
  backdrop-filter: saturate(1.4) blur(8px);
  border-bottom: 1px solid var(--border);
}
.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 62px;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  font-size: 1.05rem;
  color: var(--text);
}
.brand:hover { text-decoration: none; }
.brand .logo { width: 26px; height: 26px; display: block; }
.nav-links {
  display: flex;
  align-items: center;
  gap: 4px;
  list-style: none;
  margin: 0;
  padding: 0;
}
.nav-links a {
  display: inline-block;
  padding: 8px 12px;
  border-radius: 8px;
  color: var(--text-muted);
  font-size: .95rem;
  font-weight: 500;
}
.nav-links a:hover { color: var(--text); background: var(--bg-alt); text-decoration: none; }
.nav-links a.active { color: var(--accent-strong); }
.nav-cta {
  margin-left: 6px;
}
.nav-toggle {
  display: none;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text);
  width: 42px; height: 40px;
  border-radius: 8px;
  cursor: pointer;
  font-size: 1.2rem;
  line-height: 1;
}

@media (max-width: 820px) {
  .nav-toggle { display: inline-flex; align-items: center; justify-content: center; }
  .nav-links {
    display: none;
    position: absolute;
    left: 0; right: 0; top: 62px;
    flex-direction: column;
    align-items: stretch;
    gap: 2px;
    padding: 12px 16px 18px;
    background: var(--bg);
    border-bottom: 1px solid var(--border);
    box-shadow: var(--shadow);
  }
  .nav-links.open { display: flex; }
  .nav-links a { padding: 11px 12px; font-size: 1rem; }
  .nav-cta { margin: 6px 0 0; }
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 11px 20px;
  border-radius: 10px;
  font-weight: 600;
  font-size: .95rem;
  cursor: pointer;
  border: 1px solid transparent;
  transition: transform .04s ease, background .15s ease;
}
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--accent); color: #fff; }
.btn-primary:hover { background: var(--accent-strong); text-decoration: none; color: #fff; }
.btn-ghost { background: var(--surface); color: var(--text); border-color: var(--border); }
.btn-ghost:hover { background: var(--bg-alt); text-decoration: none; }

/* ---------- Sections ---------- */
section { padding: 64px 0; }
.section-tight { padding: 40px 0; }
.eyebrow {
  display: inline-block;
  font-size: .78rem;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--accent-strong);
  background: var(--accent-soft);
  padding: 5px 11px;
  border-radius: 999px;
  margin-bottom: 16px;
}
.lead { font-size: 1.15rem; color: var(--text-muted); max-width: 42ch; }
.center { text-align: center; }
.center .lead { margin-inline: auto; }

/* Hero */
.hero { padding: 84px 0 56px; }
.hero .lead { margin-bottom: 28px; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; }
.hero-note { margin-top: 16px; font-size: .88rem; color: var(--text-muted); }

/* Cards / grids */
.grid { display: grid; gap: 20px; }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
@media (max-width: 820px) { .grid-3 { grid-template-columns: 1fr; } .grid-2 { grid-template-columns: 1fr; } }

.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
  box-shadow: var(--shadow);
}
.card .icon {
  width: 40px; height: 40px;
  border-radius: 10px;
  background: var(--accent-soft);
  color: var(--accent-strong);
  display: inline-flex; align-items: center; justify-content: center;
  margin-bottom: 14px;
  font-size: 1.2rem;
}
.card h3 { margin-bottom: .3em; }
.card p { color: var(--text-muted); margin: 0; font-size: .96rem; }

.bg-alt { background: var(--bg-alt); }

/* Logo strip / stats */
.stats { display: flex; flex-wrap: wrap; gap: 40px; justify-content: center; }
.stat { text-align: center; }
.stat .num { font-size: 2rem; font-weight: 700; color: var(--text); }
.stat .label { color: var(--text-muted); font-size: .9rem; }

/* Testimonials */
.quote { font-size: 1.05rem; }
.quote footer { margin-top: 14px; color: var(--text-muted); font-size: .9rem; font-style: normal; }

/* ---------- Pricing ---------- */
.price-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
@media (max-width: 820px) { .price-grid { grid-template-columns: 1fr; } }
.plan { display: flex; flex-direction: column; }
.plan.featured { border-color: var(--accent); box-shadow: 0 0 0 1px var(--accent), var(--shadow); }
.plan .tier { font-weight: 700; font-size: 1.1rem; }
.plan .price { font-size: 2.2rem; font-weight: 700; margin: 6px 0 2px; }
.plan .price span { font-size: .95rem; font-weight: 500; color: var(--text-muted); }
.plan ul { list-style: none; padding: 0; margin: 18px 0 24px; }
.plan li { padding: 7px 0 7px 26px; position: relative; color: var(--text-muted); font-size: .95rem; }
.plan li::before {
  content: "✓"; position: absolute; left: 0; color: var(--accent);
  font-weight: 700;
}
.plan .btn { margin-top: auto; }
.badge {
  display: inline-block; font-size: .72rem; font-weight: 700; letter-spacing: .05em;
  text-transform: uppercase; color: #fff; background: var(--accent);
  padding: 3px 9px; border-radius: 999px; margin-left: 8px; vertical-align: middle;
}

/* ---------- Prose (blog, legal, about) ---------- */
.prose { max-width: 72ch; }
.prose h2 { margin-top: 1.6em; }
.prose h3 { margin-top: 1.3em; }
.prose ul, .prose ol { padding-left: 1.3em; margin: 0 0 1em; }
.prose li { margin-bottom: .4em; }
.prose code {
  font-family: var(--mono); font-size: .88em;
  background: var(--bg-alt); border: 1px solid var(--border);
  padding: .1em .4em; border-radius: 5px;
}
.prose blockquote {
  margin: 1.2em 0; padding: .4em 1.1em; border-left: 3px solid var(--accent);
  color: var(--text-muted);
}
.meta { color: var(--text-muted); font-size: .9rem; }

/* Blog list */
.post-list { display: grid; gap: 18px; }
.post-item {
  display: block;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 22px 24px;
  box-shadow: var(--shadow);
}
.post-item:hover { text-decoration: none; border-color: var(--accent); }
.post-item h3 { margin-bottom: .2em; color: var(--text); }
.post-item p { color: var(--text-muted); margin: .4em 0 0; }
.post-item .meta { margin-bottom: .3em; }

/* Changelog entries */
.log-entry { padding: 22px 0; border-bottom: 1px solid var(--border); }
.log-entry:last-child { border-bottom: 0; }
.log-entry .ver {
  font-family: var(--mono); font-weight: 700; color: var(--accent-strong);
}
.tag {
  display: inline-block; font-size: .72rem; font-weight: 700;
  padding: 2px 8px; border-radius: 999px; margin-right: 6px;
  background: var(--accent-soft); color: var(--accent-strong);
}

/* ---------- FAQ accordion ---------- */
.faq { max-width: 760px; margin-inline: auto; }
.faq-item { border-bottom: 1px solid var(--border); }
.faq-q {
  width: 100%; text-align: left; background: none; border: 0; cursor: pointer;
  padding: 18px 34px 18px 0; font-size: 1.02rem; font-weight: 600; color: var(--text);
  position: relative;
}
.faq-q::after {
  content: "+"; position: absolute; right: 4px; top: 50%; transform: translateY(-50%);
  font-size: 1.4rem; font-weight: 400; color: var(--text-muted); transition: transform .2s;
}
.faq-q[aria-expanded="true"]::after { transform: translateY(-50%) rotate(45deg); }
.faq-a { display: none; padding: 0 0 18px; color: var(--text-muted); }
.faq-a.open { display: block; }

/* ---------- Contact form ---------- */
.form { max-width: 560px; }
.field { margin-bottom: 16px; }
.field label { display: block; font-weight: 600; font-size: .92rem; margin-bottom: 6px; }
.field input, .field textarea, .field select {
  width: 100%; padding: 11px 13px; border-radius: 9px;
  border: 1px solid var(--border); background: var(--surface); color: var(--text);
  font: inherit;
}
.field textarea { min-height: 130px; resize: vertical; }
.field input:focus, .field textarea:focus, .field select:focus {
  outline: 2px solid var(--accent); outline-offset: 1px; border-color: var(--accent);
}
.form-note { font-size: .85rem; color: var(--text-muted); }
.contact-cols { display: grid; grid-template-columns: 1.2fr 1fr; gap: 40px; }
@media (max-width: 820px) { .contact-cols { grid-template-columns: 1fr; } }

/* ---------- Footer ---------- */
.site-footer {
  border-top: 1px solid var(--border);
  background: var(--bg-alt);
  padding: 48px 0 32px;
  margin-top: 40px;
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.5fr repeat(3, 1fr);
  gap: 32px;
}
@media (max-width: 820px) { .footer-grid { grid-template-columns: 1fr 1fr; } }
.footer-grid h4 { font-size: .8rem; text-transform: uppercase; letter-spacing: .06em;
  color: var(--text-muted); margin-bottom: 12px; }
.footer-grid ul { list-style: none; margin: 0; padding: 0; }
.footer-grid li { margin-bottom: 8px; }
.footer-grid a { color: var(--text-muted); font-size: .93rem; }
.footer-grid a:hover { color: var(--text); }
.footer-brand p { color: var(--text-muted); font-size: .93rem; max-width: 34ch; }
.footer-bottom {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between;
  gap: 12px; margin-top: 36px; padding-top: 22px; border-top: 1px solid var(--border);
  color: var(--text-muted); font-size: .88rem;
}
.status {
  display: inline-flex; align-items: center; gap: 7px;
}
.status .dot {
  width: 9px; height: 9px; border-radius: 50%; background: #3fb27f;
  box-shadow: 0 0 0 3px rgba(63, 178, 127, .18);
}

/* ---------- 404 ---------- */
.notfound { text-align: center; padding: 100px 0; }
.notfound .code { font-size: clamp(4rem, 14vw, 8rem); font-weight: 800; color: var(--accent);
  line-height: 1; letter-spacing: -.03em; }

/* Utilities */
.mt-0 { margin-top: 0; }
.mb-0 { margin-bottom: 0; }
.narrow { max-width: 720px; }
hr.rule { border: 0; border-top: 1px solid var(--border); margin: 40px 0; }
.pill-row { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 8px; }
.pill { border: 1px solid var(--border); background: var(--surface); border-radius: 999px;
  padding: 6px 14px; font-size: .88rem; color: var(--text-muted); }

.skip-link {
  position: absolute; left: -9999px; top: 0;
  background: var(--accent); color: #fff; padding: 10px 16px; border-radius: 0 0 8px 0;
  z-index: 100;
}
.skip-link:focus { left: 0; }
