/* Honest Count marketing site. Mobile-first, system fonts, no JS. */
:root {
  --ink: #14161a;
  --ink-2: #3a3f46;
  --muted: #565c64;
  --paper: #faf8f4;
  --card: #ffffff;
  --line: #e4dfd6;
  --brand: #0f6b4f;
  --brand-ink: #0a4a37;
  --brand-tint: #e3f1ea;
  --amber: #f2b134;
  --amber-tint: #fdf2d8;
  --red: #b4372b;
  --radius: 14px;
  --shadow: 0 1px 2px rgba(20,22,26,.06), 0 8px 24px rgba(20,22,26,.06);
  --font: ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --mono: ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace;
}
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 5rem; }
body { margin: 0; font-family: var(--font); font-size: 1.0625rem; line-height: 1.6; color: var(--ink); background: var(--paper); }
img, svg { max-width: 100%; }
a { color: var(--brand-ink); text-underline-offset: .18em; }
a:hover { color: var(--brand); }
:focus-visible { outline: 3px solid var(--amber); outline-offset: 2px; border-radius: 4px; }
h1, h2, h3 { line-height: 1.15; letter-spacing: -0.02em; margin: 0 0 .6em; }
h1 { font-size: clamp(2.2rem, 7vw, 4rem); letter-spacing: -0.035em; }
h2 { font-size: clamp(1.6rem, 4.2vw, 2.4rem); }
h3 { font-size: 1.2rem; }
p { margin: 0 0 1em; }
code, pre { font-family: var(--mono); font-size: .9em; }
:not(pre) > code { overflow-wrap: anywhere; background: #efeae1; padding: .1em .35em; border-radius: 5px; }
pre { background: #15191d; color: #e8efe9; padding: 1rem 1.1rem; border-radius: 10px; overflow-x: auto; line-height: 1.5; font-size: .85rem; }
pre code { background: none; padding: 0; }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip-link { position: absolute; left: .5rem; top: -3rem; background: var(--ink); color: #fff; padding: .6rem 1rem; border-radius: 8px; z-index: 100; }
.skip-link:focus { top: .5rem; color: #fff; }
main:focus { outline: none; }
.wrap { width: min(1120px, 100% - 2.5rem); margin-inline: auto; }
.narrow { width: min(760px, 100% - 2.5rem); }
.muted { color: var(--muted); }
.small { font-size: .9rem; }
.center { text-align: center; }
.eyebrow { text-transform: uppercase; letter-spacing: .12em; font-size: .78rem; font-weight: 700; color: var(--brand-ink); margin-bottom: .8rem; }
.lead { font-size: clamp(1.1rem, 2.4vw, 1.3rem); color: var(--ink-2); max-width: 42rem; }

/* Buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: .4rem; min-height: 48px; padding: .75rem 1.25rem; border-radius: 999px; font-weight: 700; text-decoration: none; border: 2px solid transparent; transition: transform .08s ease, background .15s ease; }
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--brand); color: #fff; }
.btn-primary:hover { background: var(--brand-ink); color: #fff; }
.btn-secondary { background: transparent; color: var(--ink); border-color: var(--ink); }
.btn-secondary:hover { background: var(--ink); color: #fff; }
.btn-sm { min-height: 40px; padding: .45rem 1rem; font-size: .95rem; }
.btn-row { display: flex; flex-wrap: wrap; gap: .75rem; align-items: center; margin-top: 1.5rem; }

/* Header */
.site-header { position: sticky; top: 0; z-index: 50; background: rgba(250,248,244,.92); backdrop-filter: saturate(1.4) blur(8px); border-bottom: 1px solid var(--line); }
.header-inner { display: flex; align-items: center; gap: 1rem; min-height: 64px; }
.brand { display: inline-flex; align-items: center; gap: .55rem; font-weight: 800; color: var(--ink); text-decoration: none; letter-spacing: -0.01em; font-size: 1.1rem; }
.brand .logo-mark { color: var(--brand); }
.nav-desktop, .header-cta { display: none; }
.nav-desktop ul, .nav-mobile ul, .site-footer ul, .docs-nav ul { list-style: none; margin: 0; padding: 0; }
.nav-mobile { margin-left: auto; }
.nav-mobile summary { list-style: none; cursor: pointer; width: 48px; height: 48px; display: grid; place-items: center; border-radius: 10px; }
.nav-mobile summary::-webkit-details-marker { display: none; }
.burger, .burger::before, .burger::after { display: block; width: 22px; height: 2px; background: var(--ink); border-radius: 2px; position: relative; content: ""; }
.burger::before { position: absolute; top: -7px; } .burger::after { position: absolute; top: 7px; }
.nav-mobile[open] nav { position: absolute; left: 0; right: 0; top: 64px; background: var(--paper); border-bottom: 1px solid var(--line); padding: .5rem 1.25rem 1.25rem; box-shadow: var(--shadow); }
.nav-mobile li a:not(.btn) { display: block; padding: .8rem 0; color: var(--ink); text-decoration: none; font-weight: 600; border-bottom: 1px solid var(--line); }
.nav-mobile li .btn { margin-top: 1rem; width: 100%; }
.link-quiet { color: var(--ink); font-weight: 600; text-decoration: none; }
[aria-current="page"] { color: var(--brand-ink) !important; text-decoration: underline; text-decoration-thickness: 2px; }
@media (min-width: 860px) {
  .nav-mobile { display: none; }
  .nav-desktop { display: block; margin-left: 1.5rem; }
  .nav-desktop ul { display: flex; gap: 1.5rem; }
  .nav-desktop a { color: var(--ink); text-decoration: none; font-weight: 600; }
  .header-cta { display: flex; align-items: center; gap: 1.1rem; margin-left: auto; }
}

/* Sections */
section { padding: clamp(3.5rem, 9vw, 6.5rem) 0; }
section + section { border-top: 1px solid var(--line); }
.section-head { max-width: 44rem; margin-bottom: 2.5rem; }
.band { background: var(--ink); color: #f3f1ec; }
.band a:not(.btn) { color: #9fe0c4; }
.band .muted, .band .lead { color: #c9c6bf; }
.band .eyebrow { color: var(--amber); }
.tint { background: var(--brand-tint); }

/* Hero */
.hero { padding-top: clamp(3rem, 8vw, 6rem); }
.hero-grid { display: grid; gap: 2.5rem; align-items: center; }
.hero h1 { max-width: 14ch; }
.hero .reassure { margin-top: 1rem; font-size: .95rem; color: var(--muted); }
.hero .reassure span { white-space: nowrap; }
@media (min-width: 960px) { .hero-grid { grid-template-columns: 1.15fr 1fr; } }
.code-card { background: #15191d; color: #e8efe9; border-radius: var(--radius); padding: 1.25rem; box-shadow: var(--shadow); }
.code-card .label { font-size: .78rem; text-transform: uppercase; letter-spacing: .1em; color: #a9c9b9; margin: 0 0 .6rem; }
.code-card pre { padding: 0; margin: 0 0 1rem; white-space: pre-wrap; word-break: break-all; font-size: .85rem; }
.meter { margin-top: .5rem; }
.meter-bar { position: relative; height: 14px; border-radius: 999px; background: #2a3036; overflow: visible; }
.meter-fill { position: absolute; inset: 0 auto 0 0; width: 82%; border-radius: 999px; background: linear-gradient(90deg, #3ba57e, var(--amber)); }
.meter-ticks { display: flex; justify-content: space-between; font-size: .75rem; color: #a9b3ad; margin-top: .45rem; }
.meter-note { font-size: .82rem; color: #cfd8d2; margin: .75rem 0 0; }

/* Cards & grids */
.grid { display: grid; gap: 1.25rem; }
@media (min-width: 720px) { .grid-2 { grid-template-columns: repeat(2, 1fr); } .grid-3 { grid-template-columns: repeat(3, 1fr); } }
@media (min-width: 1000px) { .grid-4 { grid-template-columns: repeat(4, 1fr); } }
@media (min-width: 720px) and (max-width: 999px) { .grid-4 { grid-template-columns: repeat(2, 1fr); } }
.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 1.5rem; box-shadow: var(--shadow); }
.band .card { background: #1d2227; border-color: #2c3238; box-shadow: none; }
.card h3 { margin-bottom: .4rem; }
.card p:last-child { margin-bottom: 0; }
.kicker { font-size: .8rem; font-weight: 700; text-transform: uppercase; letter-spacing: .1em; color: var(--brand-ink); margin-bottom: .5rem; }
.band .kicker { color: var(--amber); }
.steps { counter-reset: step; list-style: none; padding: 0; margin: 0; }
.steps > li { counter-increment: step; position: relative; padding-left: 3.75rem; }
.steps > li::before { content: counter(step); position: absolute; left: 0; top: 0; width: 2.6rem; height: 2.6rem; border-radius: 50%; background: var(--brand); color: #fff; font-weight: 800; display: grid; place-items: center; }
.ticks { list-style: none; padding: 0; margin: 0; }
.ticks li { position: relative; padding-left: 1.8rem; margin-bottom: .6rem; }
.ticks li::before { content: ""; position: absolute; left: .1rem; top: .45em; width: .9rem; height: .5rem; border-left: 3px solid var(--brand); border-bottom: 3px solid var(--brand); transform: rotate(-45deg); }
.band .ticks li::before { border-color: #6fd1a6; }
.crosses li::before { border: 0; content: "✕"; transform: none; top: 0; color: var(--red); font-weight: 800; }
.band .crosses li::before { color: #ff8f84; }
.promise { border-left: 4px solid var(--amber); padding: 1rem 1.25rem; background: var(--amber-tint); border-radius: 0 10px 10px 0; }

/* Plans */
.plans { list-style: none; padding: 0; margin: 0; display: grid; gap: 1.25rem; }
@media (min-width: 640px) { .plans { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1040px) { .plans { grid-template-columns: repeat(4, 1fr); } }
.plan { display: flex; flex-direction: column; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 1.5rem; box-shadow: var(--shadow); }
.plan-featured { border: 2px solid var(--brand); }
.plan-name { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem; font-size: 1.25rem; margin-bottom: .5rem; }
.pill { font-size: .72rem; font-weight: 700; letter-spacing: .02em; background: var(--brand-tint); color: var(--brand-ink); padding: .2rem .55rem; border-radius: 999px; }
.plan-price { margin: 0 0 .5rem; }
.plan-price .amount { font-size: 2.4rem; font-weight: 800; letter-spacing: -0.03em; }
.plan-price .per { color: var(--muted); margin-left: .2rem; }
.plan-blurb { color: var(--ink-2); min-height: 3.2em; }
.plan-facts { list-style: none; padding: 0; margin: 0 0 1.5rem; border-top: 1px solid var(--line); }
.plan-facts li { padding: .55rem 0; border-bottom: 1px solid var(--line); font-size: .97rem; }
.plan .btn { margin-top: auto; }

/* Tables */
.table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: 12px; background: var(--card); margin: 1.25rem 0 1.75rem; }
table { border-collapse: collapse; width: 100%; font-size: .95rem; }
th, td { text-align: left; padding: .7rem .9rem; border-bottom: 1px solid var(--line); vertical-align: top; }
thead th { background: #f3efe7; font-weight: 700; }
tbody tr:last-child td, tbody tr:last-child th { border-bottom: 0; }
td.num, th.num { text-align: right; white-space: nowrap; }

/* Prose (docs, legal) */
.page-head { padding: clamp(2.5rem, 7vw, 4.5rem) 0 1.5rem; }
.page-head h1 { font-size: clamp(2rem, 5.5vw, 3.2rem); }
.prose { padding-bottom: 4rem; }
.prose h2 { font-size: 1.55rem; margin-top: 2.4rem; }
.prose h3 { margin-top: 1.8rem; }
.prose ul, .prose ol { padding-left: 1.3rem; }
.prose li { margin-bottom: .4rem; }
.callout { background: var(--brand-tint); border-radius: 12px; padding: 1rem 1.2rem; margin: 1.25rem 0; }
.callout.warn { background: var(--amber-tint); }
.callout > :last-child { margin-bottom: 0; }
.draft-banner { margin: 2rem 0 1.5rem; background: var(--amber-tint); border: 1px solid #e9c975; border-radius: 12px; padding: .9rem 1.1rem; font-size: .95rem; }
.legal h1 { font-size: clamp(2rem, 5vw, 2.8rem); }
.legal .meta { color: var(--muted); font-size: .95rem; }
.toc { background: var(--card); border: 1px solid var(--line); border-radius: 12px; padding: 1rem 1.25rem; margin: 1.5rem 0; }
.toc h2 { font-size: 1rem; margin: 0 0 .5rem; }
.toc ol { margin: 0; }

/* Docs */
.docs-grid { display: grid; gap: 1.5rem; padding-top: 2rem; }
.docs-nav { border-bottom: 1px solid var(--line); padding-bottom: 1rem; }
.docs-nav ul { display: flex; flex-wrap: wrap; gap: .25rem .5rem; }
.docs-nav a { display: inline-block; padding: .45rem .7rem; border-radius: 8px; color: var(--ink); text-decoration: none; font-weight: 600; font-size: .95rem; background: #efeae1; }
.docs-nav a[aria-current="page"] { background: var(--brand); color: #fff !important; text-decoration: none; }
.docs-body { min-width: 0; }
.docs-body h1 { font-size: clamp(2rem, 5vw, 2.8rem); }
@media (min-width: 900px) {
  .docs-grid { grid-template-columns: 220px 1fr; gap: 3rem; padding-top: 3rem; }
  .docs-nav { border: 0; position: sticky; top: 5.5rem; align-self: start; }
  .docs-nav ul { display: block; }
  .docs-nav li { margin-bottom: .2rem; }
  .docs-nav a { display: block; background: none; }
}
details.faq { border-bottom: 1px solid var(--line); padding: .9rem 0; }
details.faq summary { cursor: pointer; font-weight: 700; font-size: 1.05rem; }
details.faq[open] summary { margin-bottom: .6rem; }

/* Footer */
.site-footer { background: #101215; color: #d9d6cf; padding: 3rem 0 1.5rem; }
.site-footer a { color: #e9e6df; }
.site-footer .brand { color: #fff; margin-bottom: .75rem; }
.site-footer .brand .logo-mark { color: #3ba57e; }
.site-footer .muted { color: #aaa69e; }
.footer-grid { display: grid; gap: 2rem; }
@media (min-width: 760px) { .footer-grid { grid-template-columns: 2fr 1fr 1fr 1.3fr; } }
.footer-h { font-size: .8rem; text-transform: uppercase; letter-spacing: .12em; color: #aaa69e; margin: 0 0 .75rem; }
.site-footer li { margin-bottom: .45rem; }
.docs-nav .footer-h { color: var(--muted); }
.footer-base { border-top: 1px solid #2a2d31; margin-top: 2.5rem; padding-top: 1.25rem; }
.footer-base p { margin: 0; }

@media (prefers-reduced-motion: reduce) { * { transition: none !important; scroll-behavior: auto !important; } }
.mt-1 { margin-top: 1rem; } .mt-2 { margin-top: 2rem; } .mx-auto { margin-inline: auto; } .justify-center { justify-content: center; }
