/* First Contact — shared styles. Waylo-inspired: soft grey page, white rounded cards, one soft-blue accent, Inter. */
:root {
  --bg: #f4f5f7;
  --surface: #ffffff;
  --surface-2: #f8f9fb;
  --text: #14161a;
  --muted: #646b76;
  --line: #e6e8ec;
  --accent: #3e69dc;
  --accent-soft: #e9effc;
  --tick: #2f9e6b;
  --shadow: 0 1px 2px rgba(16, 24, 40, .04), 0 8px 24px rgba(16, 24, 40, .06);
  --radius: 20px;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0f1115; --surface: #171a20; --surface-2: #1d2128; --text: #eceef2; --muted: #9aa1ad;
    --line: #2a2f38; --accent: #7c9cf0; --accent-soft: #1e2840; --tick: #4cc28c;
    --shadow: 0 1px 2px rgba(0,0,0,.3), 0 8px 24px rgba(0,0,0,.25);
  }
}
:root[data-theme="dark"] {
  --bg: #0f1115; --surface: #171a20; --surface-2: #1d2128; --text: #eceef2; --muted: #9aa1ad;
  --line: #2a2f38; --accent: #7c9cf0; --accent-soft: #1e2840; --tick: #4cc28c;
  --shadow: 0 1px 2px rgba(0,0,0,.3), 0 8px 24px rgba(0,0,0,.25);
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--bg); color: var(--text);
  font: 16px/1.6 Inter, system-ui, -apple-system, "Segoe UI", sans-serif;
  overflow-wrap: break-word;
}
a { color: var(--accent); text-decoration: none; font-weight: 500; }
a:hover { text-decoration: underline; }
h1, h2, h3 { line-height: 1.2; letter-spacing: -0.02em; margin: 0 0 .4em; }
h1 { font-size: clamp(2rem, 5vw, 3.1rem); font-weight: 800; }
h2 { font-size: 1.5rem; font-weight: 700; }
h3 { font-size: 1.05rem; font-weight: 600; }
p { margin: 0 0 .8em; }
.muted { color: var(--muted); }
.small { font-size: .9rem; }

.wrap { max-width: 1040px; margin: 0 auto; padding: 0 16px; }

/* nav */
.nav { position: sticky; top: 0; z-index: 10; background: color-mix(in srgb, var(--bg) 85%, transparent); backdrop-filter: blur(8px); }
.nav-inner { display: flex; align-items: center; justify-content: space-between; height: 64px; }
.brand { color: var(--text); font-weight: 800; letter-spacing: -0.02em; }
.nav nav { display: flex; align-items: center; gap: 20px; }
.nav nav a { color: var(--muted); font-size: .95rem; }
.theme-toggle { border: 1px solid var(--line); background: var(--surface); color: var(--text); border-radius: 999px; width: 34px; height: 34px; cursor: pointer; }

/* hero */
.hero { padding: 56px 0 40px; display: grid; grid-template-columns: 1.15fr 1fr; gap: 40px; align-items: center; }
.hero-img { margin: 0; }
.hero-img img { display: block; width: 100%; height: auto; aspect-ratio: 4 / 3; object-fit: cover; border-radius: var(--radius); box-shadow: var(--shadow); }
.hero-img figcaption { font-size: .75rem; color: var(--muted); margin-top: 8px; text-align: right; }
.hero-img figcaption a { color: var(--muted); }
.eyebrow { display: inline-block; background: var(--accent-soft); color: var(--accent); font-weight: 600; font-size: .8rem; padding: 4px 12px; border-radius: 999px; margin-bottom: 18px; }
.lede { font-size: 1.15rem; color: var(--muted); }
.hero-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 16px; margin-top: 24px; }
.btn { display: inline-block; background: var(--accent); color: #fff; padding: 12px 22px; border-radius: 999px; font-weight: 600; }
.btn:hover { text-decoration: none; filter: brightness(1.05); }

/* cards & sections */
.card { background: var(--surface); border-radius: var(--radius); box-shadow: var(--shadow); padding: 32px; margin: 0 0 32px; }
.section { margin: 56px 0 32px; }

.quotes { list-style: none; padding: 0; margin: 20px 0 0; }
.quotes li { padding: 18px 0; border-top: 1px solid var(--line); }
.quotes li:first-child { border-top: 0; padding-top: 4px; }
.q { font-weight: 600; font-size: 1.05rem; margin-bottom: 6px; }
.meta { font-size: .85rem; color: var(--muted); margin: 0; }
.tip { margin-top: 16px; background: var(--accent-soft); border-radius: 14px; padding: 16px 20px; }

/* tool grid */
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 20px; margin-top: 24px; }
.tool { background: var(--surface); border-radius: var(--radius); box-shadow: var(--shadow); padding: 24px; display: flex; flex-direction: column; }
.tool-head { display: flex; gap: 14px; align-items: flex-start; margin-bottom: 12px; }
.tool-head h3 { margin: 0; }
.flag { display: inline-block; vertical-align: -2px; margin-right: 4px; border-radius: 2px; box-shadow: 0 0 0 1px var(--line); }
.logo { flex: none; width: 40px; height: 40px; border-radius: 12px; background: var(--surface-2); border: 1px solid var(--line); color: var(--accent); display: grid; place-items: center; font-weight: 800; }
.for { font-size: .85rem; color: var(--muted); margin: 2px 0 0; }
.tag { font-size: .92rem; font-style: italic; color: var(--muted); }
.ticks { list-style: none; padding: 0; margin: 0 0 16px; font-size: .93rem; }
.ticks li { position: relative; padding-left: 26px; margin-bottom: 8px; }
.ticks li::before { content: "✓"; position: absolute; left: 0; top: 0; color: var(--tick); font-weight: 700; }
.tool-foot { margin-top: auto; padding-top: 14px; border-top: 1px solid var(--line); display: flex; flex-wrap: wrap; gap: 8px; justify-content: space-between; align-items: center; font-size: .9rem; }
.price { font-weight: 600; }
.tool-empty { background: transparent; box-shadow: none; border: 2px dashed var(--line); justify-content: center; }
.checked { margin-top: 16px; }

.steps { padding-left: 22px; margin: 12px 0 0; }
.steps li { margin-bottom: 12px; }

.fineprint { background: var(--surface-2); border-radius: var(--radius); padding: 24px 28px; margin: 0 0 32px; font-size: .92rem; color: var(--muted); }
.fineprint h3 { color: var(--text); }
.footer { padding: 24px 16px 48px; text-align: center; }

@media (max-width: 820px) {
  .hero { grid-template-columns: 1fr; gap: 24px; }
}
@media (max-width: 600px) {
  .hero { padding: 36px 0 28px; }
  .card { padding: 22px; }
  .nav nav { gap: 12px; }
}

/* Comparison table (cash-flow page): wrapper scrolls sideways on phones so the page never overflows */
.table-scroll { overflow-x: auto; margin: 20px 0 0; -webkit-overflow-scrolling: touch; }
.compare { width: 100%; min-width: 880px; border-collapse: collapse; font-size: .88rem; }
.compare th, .compare td { text-align: left; vertical-align: top; padding: 12px 12px; border-top: 1px solid var(--line); }
.compare thead th { border-top: 0; color: var(--muted); font-weight: 600; font-size: .8rem; white-space: nowrap; }
.compare tbody th { font-weight: 700; white-space: nowrap; }
.compare .flag { margin-right: 6px; }
/* Hero with no photo: single column */
.hero-plain { grid-template-columns: 1fr; }
.hero-plain .hero-text { max-width: 720px; }

/* Where a tool is from / who it is built for (finance category cards) */
.origin { font-size: .85rem; font-weight: 600; margin: 0; }

/* Contact block (email button + the address as plain selectable text, for people whose mail links don't open) */
.contact-addr { margin: 14px 0 0; user-select: all; overflow-wrap: anywhere; }
.contact .btn { margin-top: 4px; }

/* Market tag on home category cards (who the category serves: Owners, Bookkeepers) */
.market { align-self: flex-start; font-size: .78rem; font-weight: 600; color: var(--accent); background: var(--accent-soft); padding: 2px 10px; border-radius: 999px; margin: 0 0 10px; }

/* Home page: categories grouped by market (owners, bookkeepers, builders). scroll-margin keeps the heading clear of the sticky nav. */
.group { margin-top: 40px; scroll-margin-top: 72px; }
.group-title { font-size: 1.2rem; font-weight: 700; margin: 0; }
.group .grid { margin-top: 16px; }
.group-note { margin: 16px 0 0; }
#doors, #categories, #checklist, #questions, #contact { scroll-margin-top: 72px; }
/* "New, no reviews yet" label on a tool card (bookkeeper pages, Michael 2026-10-14): neutral pill, so it informs without alarming */
.badge-new { align-self: flex-start; font-size: .78rem; font-weight: 600; color: var(--muted); background: var(--surface-2); border: 1px solid var(--line); padding: 2px 10px; border-radius: 999px; margin: 8px 0 10px; }
/* Home door cards: label above link in all three so the footers match whatever the link length (the link text differs per card) */
.doors .tool-foot { flex-direction: column; align-items: flex-start; gap: 4px; }

/* Checklist pages (leaving-quickbooks-desktop): bullet list nested inside a numbered step, and a one-line link under a hero button */
.steps ul { margin: 8px 0 0; padding-left: 20px; }
.steps ul li { margin-bottom: 4px; }
.hero-note { margin: 16px 0 0; }

/* Q&A sections (Questions owners/builders asked): spacing between questions, no extra gap after the last line */
.qa + .qa { margin-top: 24px; }
.qa p:last-child { margin-bottom: 0; }

/* Phone header (2026-10-17): with About added, brand + 4 links + toggle no longer fit on one line at 375px.
   Below 480px the links drop to a second row under the brand. Anchor offsets grow to clear the taller header. */
@media (max-width: 480px) {
  .nav-inner { flex-wrap: wrap; height: auto; padding-top: 10px; padding-bottom: 8px; row-gap: 6px; }
  .nav nav { width: 100%; justify-content: space-between; gap: 4px; }
  /* 2026-10-17: "Free tools" added, so five links + toggle need a smaller size and no wrapping inside a link */
  .nav nav a { font-size: .82rem; white-space: nowrap; }
  .theme-toggle { width: 30px; height: 30px; }
  #doors, #categories, #checklist, #questions, #contact, .group { scroll-margin-top: 104px; }
}

/* Small-yes button above "Email us" in the contact block (2026-10-17): same .btn, stacked on its own line */
.contact .btn-above { display: table; margin: 4px 0 12px; }

/* Free tools page (2026-10-17): jump-to links, small tag labels on cards, what's-free / works-in / before-you-start lines */
.jump { margin: 16px 0 0; }
.jump a { white-space: nowrap; }
.label { display: inline-block; font-size: .78rem; font-weight: 600; color: var(--accent); background: var(--accent-soft); padding: 2px 10px; border-radius: 999px; }
.tagline { font-size: .9rem; color: var(--muted); margin: 0 0 14px; }
.label-list { list-style: none; padding: 0; margin: 12px 0 0; font-size: .93rem; }
.label-list li { margin-bottom: 6px; }
.facts { font-size: .93rem; margin: 0 0 16px; }
.facts p { margin: 0 0 8px; }
.facts strong { font-weight: 600; }
.tool-links { display: flex; flex-direction: column; gap: 6px; margin-top: auto; padding-top: 14px; border-top: 1px solid var(--line); font-size: .9rem; }
.free-section { scroll-margin-top: 72px; }
@media (max-width: 480px) { .free-section { scroll-margin-top: 104px; } }
