/* Plugsquire site. Direction: "the squire's ledger" — the app's own Signature dark look
   (near-black, brass hairlines, the heraldic shield) set in a Mac-native serif.
   No web fonts on purpose: the site makes no third-party requests, and its visitors are on
   macOS, where ui-serif resolves to New York and the sans stack to SF Pro. */

:root {
  --bg: #0B0B0C;          /* app icon ground */
  --surface: #131315;
  --surface-2: #19191C;
  --line: #2A2A2E;
  --line-strong: #3A3833;
  --ink: #F3EFE7;          /* brand paper, used as text */
  --muted: #B3ADA4;        /* 8.9:1 on --bg */
  --gold: #C9A96A;         /* brand brass, 8.6:1 on --bg */
  --gold-soft: #EAD7A8;
  --gold-deep: #9A7A43;
  --on-gold: #0B0B0C;
  --gap-ink: #F2C46D;

  --serif: ui-serif, "New York", "Iowan Old Style", "Palatino Linotype", Palatino, Georgia, serif;
  --sans: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Helvetica Neue", "Segoe UI", sans-serif;
  --mono: ui-monospace, "SF Mono", Menlo, Consolas, monospace;

  --wrap: 1120px;
  --gutter: 24px;
  --radius: 6px;
  --space-1: 8px;
  --space-2: 16px;
  --space-3: 24px;
  --space-4: 40px;
  --space-5: 64px;
  --space-6: 112px;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

/* A faint brass glow and a hairline grid give the dark ground depth without a fifth colour. */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: -1;
  background:
    radial-gradient(900px 520px at 78% -8%, rgba(201, 169, 106, 0.10), transparent 70%),
    radial-gradient(700px 420px at -10% 40%, rgba(201, 169, 106, 0.05), transparent 70%),
    linear-gradient(rgba(243, 239, 231, 0.025) 1px, transparent 1px) 0 0 / 100% 48px;
}

img, svg { display: block; max-width: 100%; }
a { color: var(--gold); text-underline-offset: 3px; text-decoration-thickness: 1px; }
a:hover { color: var(--gold-soft); }
:focus-visible { outline: 2px solid var(--gold-soft); outline-offset: 3px; border-radius: 2px; }

.wrap { width: 100%; max-width: var(--wrap); margin: 0 auto; padding: 0 var(--gutter); }

.skip {
  position: absolute; left: var(--gutter); top: -60px;
  background: var(--gold); color: var(--on-gold); padding: 8px 14px; border-radius: var(--radius);
  font-weight: 600; text-decoration: none; z-index: 10;
}
.skip:focus { top: 12px; color: var(--on-gold); }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 5;
  background: rgba(11, 11, 12, 0.82);
  -webkit-backdrop-filter: saturate(140%) blur(14px);
  backdrop-filter: saturate(140%) blur(14px);
  border-bottom: 1px solid var(--line);
}
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; gap: var(--space-3); min-height: 68px; }
.brand { display: inline-flex; align-items: center; flex-shrink: 0; }
.brand img { height: 40px; width: auto; }
.nav { display: flex; align-items: center; gap: var(--space-3); }
.nav a { color: var(--muted); text-decoration: none; font-size: 15px; }
.nav a:hover { color: var(--ink); }
.nav .btn { color: var(--on-gold); }
@media (max-width: 860px) { .nav .nav-link { display: none; } }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 44px; padding: 10px 20px;
  border-radius: var(--radius);
  font: 600 15px/1.2 var(--sans); letter-spacing: 0.01em;
  text-decoration: none; cursor: pointer;
  transition: background-color .18s ease, border-color .18s ease, color .18s ease, transform .18s ease, box-shadow .18s ease;
}
.btn-primary {
  background: var(--gold); color: var(--on-gold); border: 1px solid var(--gold);
  box-shadow: 0 1px 0 rgba(255,255,255,.25) inset, 0 10px 30px -12px rgba(201,169,106,.55);
}
.btn-primary:hover { background: var(--gold-soft); border-color: var(--gold-soft); color: var(--on-gold); transform: translateY(-1px); }
.btn-primary:active { transform: translateY(0); background: var(--gold-deep); border-color: var(--gold-deep); }
.btn-ghost { background: transparent; color: var(--ink); border: 1px solid var(--line-strong); }
.btn-ghost:hover { border-color: var(--gold); color: var(--gold-soft); }
.btn-ghost:active { background: var(--surface); }
.btn-sm { min-height: 38px; padding: 8px 14px; font-size: 14px; }
.btn svg { width: 16px; height: 16px; flex-shrink: 0; }

/* ---------- Type ---------- */
h1, h2, h3 { font-family: var(--serif); font-weight: 600; letter-spacing: -0.01em; color: var(--ink); margin: 0; }
h1 { font-size: clamp(40px, 6.4vw, 72px); line-height: 1.04; letter-spacing: -0.02em; }
h2 { font-size: clamp(30px, 4vw, 46px); line-height: 1.1; }
h3 { font-size: 22px; line-height: 1.25; }
p { margin: 0; }
.lead { font-size: clamp(18px, 2vw, 21px); line-height: 1.55; color: var(--muted); }
.motto {
  font-family: var(--serif); font-size: 17px; letter-spacing: 0.04em; color: var(--gold);
  display: inline-flex; align-items: center; gap: 12px;
}
.motto::before { content: ""; width: 28px; height: 1px; background: var(--gold); }

/* Gap markers stay visible on purpose: each one is a fact still missing. */
.gap {
  display: inline-block; font-family: var(--mono); font-size: 0.82em; line-height: 1.5;
  color: var(--gap-ink); background: rgba(242, 196, 109, 0.08);
  border: 1px dashed rgba(242, 196, 109, 0.6); border-radius: 4px; padding: 2px 8px;
}

/* ---------- Sections ---------- */
section { padding: var(--space-6) 0; position: relative; }
.section-head { max-width: 760px; margin-bottom: var(--space-5); }
.section-head p { margin-top: var(--space-3); }
.rule { border: 0; height: 1px; margin: 0; background: linear-gradient(90deg, transparent, var(--line-strong) 20%, var(--line-strong) 80%, transparent); }

/* ---------- Hero ---------- */
.hero { padding: var(--space-5) 0 var(--space-6); }
.hero-grid { display: grid; grid-template-columns: 1.12fr 0.88fr; gap: var(--space-5); align-items: center; }
.hero h1 { margin-top: var(--space-3); max-width: 13ch; }
.hero .lead { margin-top: var(--space-3); max-width: 34em; }
.hero-ctas { display: flex; flex-wrap: wrap; gap: 12px; margin-top: var(--space-4); }
.trust {
  display: flex; flex-wrap: wrap; gap: 10px 22px; margin: var(--space-4) 0 0; padding: 0; list-style: none;
  color: var(--muted); font-size: 14px;
}
.trust li { display: inline-flex; align-items: center; gap: 8px; }
.trust li::before {
  content: ""; width: 7px; height: 7px; transform: rotate(45deg);
  border: 1px solid var(--gold); background: rgba(201,169,106,.25);
}

/* The roll: a drawn muster of the buses Plugsquire reads. Decorative, not a screenshot. */
.roll {
  position: relative;
  background: linear-gradient(180deg, var(--surface-2), var(--surface));
  border: 1px solid var(--line-strong);
  border-radius: 10px;
  padding: 28px 28px 22px;
  box-shadow: 0 40px 80px -40px rgba(0,0,0,.9), 0 0 0 6px rgba(201,169,106,.04);
}
.roll::before {
  content: ""; position: absolute; inset: 7px; border: 1px solid rgba(201,169,106,.16); border-radius: 6px; pointer-events: none;
}
.roll-head { display: flex; align-items: center; gap: 14px; padding-bottom: 18px; border-bottom: 1px solid var(--line); }
.roll-head img { width: 44px; height: 44px; }
.roll-head span { font-family: var(--serif); font-size: 20px; color: var(--ink); }
.roll ol { list-style: none; margin: 8px 0 0; padding: 0; }
.roll li {
  display: flex; align-items: baseline; gap: 10px; padding: 11px 0; border-bottom: 1px dashed var(--line);
  font-size: 15px; color: var(--ink);
  opacity: 0; animation: muster .5s ease forwards;
}
.roll li:last-child { border-bottom: 0; }
.roll li::after {
  content: ""; order: 2; flex: 1; border-bottom: 1px dotted rgba(179,173,164,.35); transform: translateY(-4px);
}
.roll li .dot { order: 3; width: 9px; height: 9px; border-radius: 50%; background: var(--gold); box-shadow: 0 0 0 4px rgba(201,169,106,.14); flex-shrink: 0; }
.roll li:nth-child(1) { animation-delay: .10s; }
.roll li:nth-child(2) { animation-delay: .18s; }
.roll li:nth-child(3) { animation-delay: .26s; }
.roll li:nth-child(4) { animation-delay: .34s; }
.roll li:nth-child(5) { animation-delay: .42s; }
.roll li:nth-child(6) { animation-delay: .50s; }
.roll li:nth-child(7) { animation-delay: .58s; }
.roll li:nth-child(8) { animation-delay: .66s; }
.roll li:nth-child(9) { animation-delay: .74s; }
@keyframes muster { from { opacity: 0; transform: translateX(-6px); } to { opacity: 1; transform: none; } }

/* Staggered page-load reveal for the hero copy. */
.reveal { opacity: 0; animation: rise .7s cubic-bezier(.2,.7,.2,1) forwards; }
.reveal-1 { animation-delay: .05s; } .reveal-2 { animation-delay: .15s; } .reveal-3 { animation-delay: .25s; }
.reveal-4 { animation-delay: .35s; } .reveal-5 { animation-delay: .45s; }
@keyframes rise { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }

/* ---------- Problem / Agitate ---------- */
.split { display: grid; grid-template-columns: 0.9fr 1.1fr; gap: var(--space-5); align-items: start; }
.split .section-head { margin-bottom: 0; }
.scenes { display: grid; gap: 14px; margin: 0; padding: 0; list-style: none; }
.scenes li {
  display: grid; grid-template-columns: 40px 1fr; gap: 16px; align-items: start;
  padding: 20px 22px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
}
.scenes .ico { width: 40px; height: 40px; border-radius: 8px; display: grid; place-items: center; border: 1px solid var(--line-strong); color: var(--gold); }
.scenes .ico svg { width: 20px; height: 20px; }

.agitate { background: linear-gradient(180deg, transparent, rgba(201,169,106,.035) 50%, transparent); }
.costs { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0; border-top: 1px solid var(--line-strong); border-bottom: 1px solid var(--line-strong); }
.costs p { padding: 28px 28px 30px 0; font-family: var(--serif); font-size: 21px; line-height: 1.4; color: var(--ink); }
.costs p + p { padding-left: 28px; border-left: 1px solid var(--line); }

/* ---------- Solution / features ---------- */
.features { display: grid; grid-template-columns: repeat(6, 1fr); gap: 16px; }
.feature {
  grid-column: span 2; padding: 28px; background: var(--surface); border: 1px solid var(--line); border-radius: 10px;
  transition: border-color .2s ease, transform .2s ease;
}
.feature:nth-child(4), .feature:nth-child(5) { grid-column: span 3; }
.feature:hover { border-color: var(--line-strong); transform: translateY(-2px); }
.feature .ico { width: 44px; height: 44px; color: var(--gold); margin-bottom: 20px; }
.feature .ico svg { width: 44px; height: 44px; }
.feature p { margin-top: 10px; color: var(--muted); font-size: 16px; }
.versus {
  margin-top: var(--space-4); padding: 26px 28px; border-left: 2px solid var(--gold);
  background: linear-gradient(90deg, rgba(201,169,106,.07), transparent 70%);
  font-family: var(--serif); font-size: 20px; line-height: 1.5; color: var(--ink); max-width: 900px;
}

/* ---------- How it works ---------- */
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; counter-reset: step; margin: 0; padding: 0; list-style: none; }
.steps li { position: relative; padding: 30px 28px; border: 1px solid var(--line); border-radius: 10px; background: var(--surface); }
.steps .ico { width: 52px; height: 52px; border-radius: 50%; border: 1px solid var(--gold); display: grid; place-items: center; color: var(--gold); margin-bottom: 22px; background: rgba(201,169,106,.06); }
.steps .ico svg { width: 24px; height: 24px; }
.steps h3 { font-size: 21px; }
.steps p { margin-top: 10px; color: var(--muted); font-size: 16px; }
.steps-cta { margin-top: var(--space-4); }

/* ---------- Proof ---------- */
.proof-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.quote { padding: 34px; border: 1px solid var(--line-strong); border-radius: 10px; background: var(--surface); }
.quote .mark { font-family: var(--serif); font-size: 64px; line-height: .6; color: var(--gold); display: block; margin-bottom: 14px; }
.note { padding: 34px; border: 1px solid var(--line); border-radius: 10px; color: var(--muted); }
.note p + p { margin-top: 14px; }

/* ---------- Pricing ---------- */
.plans { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; max-width: 920px; }
.plan { padding: 34px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface); display: flex; flex-direction: column; }
.plan.pro { border-color: var(--gold); box-shadow: 0 0 0 1px rgba(201,169,106,.25), 0 30px 70px -40px rgba(201,169,106,.45); position: relative; }
.plan .tag {
  position: absolute; top: -12px; left: 34px; background: var(--bg); border: 1px solid var(--gold); color: var(--gold);
  font-size: 12px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; padding: 3px 10px; border-radius: 4px;
}
.plan h3 { font-size: 24px; }
.price { margin-top: 14px; font-family: var(--serif); font-size: 46px; line-height: 1; color: var(--ink); }
.price small { font-family: var(--sans); font-size: 15px; color: var(--muted); margin-left: 6px; }
.plan ul { list-style: none; margin: 24px 0 0; padding: 0; display: grid; gap: 10px; }
.plan li { display: grid; grid-template-columns: 18px 1fr; gap: 10px; font-size: 16px; }
.plan li svg { width: 16px; height: 16px; margin-top: 5px; color: var(--gold); }
.plan .fine { margin-top: 22px; font-size: 14px; color: var(--muted); }
.pricing-notes { margin-top: var(--space-3); max-width: 920px; color: var(--muted); font-size: 15px; display: grid; gap: 8px; }

/* ---------- FAQ ---------- */
.faq { max-width: 860px; border-top: 1px solid var(--line-strong); }
.faq details { border-bottom: 1px solid var(--line); }
.faq summary {
  list-style: none; cursor: pointer; padding: 22px 44px 22px 0; position: relative;
  font-family: var(--serif); font-size: 21px; color: var(--ink);
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: ""; position: absolute; right: 8px; top: 50%; width: 10px; height: 10px; margin-top: -7px;
  border-right: 1.5px solid var(--gold); border-bottom: 1.5px solid var(--gold); transform: rotate(45deg); transition: transform .2s ease;
}
.faq details[open] summary::after { transform: rotate(-135deg); margin-top: -2px; }
.faq summary:hover { color: var(--gold-soft); }
.faq details p { padding: 0 0 24px; color: var(--muted); max-width: 70ch; }

/* ---------- Final CTA ---------- */
.final { text-align: center; }
.final .crest { width: 72px; height: 72px; margin: 0 auto var(--space-3); }
.final h2 { max-width: 18ch; margin: 0 auto; }
.final p { margin: var(--space-3) auto 0; color: var(--muted); max-width: 40em; }
.final .btn { margin-top: var(--space-4); }

/* ---------- Footer ---------- */
.site-footer { border-top: 1px solid var(--line); padding: var(--space-4) 0 var(--space-5); color: var(--muted); font-size: 14px; }
.site-footer .wrap { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: var(--space-3); }
.site-footer nav { display: flex; flex-wrap: wrap; gap: 8px 22px; }
.site-footer a { color: var(--muted); text-decoration: none; }
.site-footer a:hover, .site-footer a[aria-current="page"] { color: var(--gold); }
.foot-brand { display: inline-flex; align-items: center; gap: 10px; }
.foot-brand img { width: 22px; height: 22px; }

/* ---------- Document pages (privacy, terms, changelog, docs) ---------- */
.doc { padding: var(--space-5) 0 var(--space-6); }
.doc .wrap { max-width: 820px; }
.doc header.doc-head { padding-bottom: var(--space-4); margin-bottom: var(--space-4); border-bottom: 1px solid var(--line-strong); }
.doc h1 { font-size: clamp(36px, 5vw, 52px); margin-top: var(--space-2); }
.doc .meta { margin-top: var(--space-2); color: var(--muted); font-size: 15px; }
.doc .summary { margin-top: var(--space-3); font-size: 19px; line-height: 1.6; color: var(--ink); }
.doc h2 { font-size: 26px; margin: var(--space-5) 0 var(--space-2); padding-top: var(--space-1); }
.doc h3 { font-size: 19px; margin: var(--space-4) 0 var(--space-1); color: var(--gold-soft); }
.doc p, .doc li { color: #D9D3C9; }
.doc p + p { margin-top: 14px; }
.doc ul, .doc ol { padding-left: 22px; margin: 12px 0 0; }
.doc li { margin: 8px 0; }
.doc li::marker { color: var(--gold); }
.doc code {
  font-family: var(--mono); font-size: 0.88em; background: var(--surface-2); border: 1px solid var(--line);
  border-radius: 4px; padding: 1px 6px; color: var(--gold-soft); overflow-wrap: anywhere;
}
.doc pre {
  margin: 14px 0 0; padding: 16px 18px; background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--radius); overflow-x: auto; font-size: 14px; line-height: 1.6;
}
.doc pre code { background: none; border: 0; padding: 0; color: var(--ink); overflow-wrap: normal; }
.doc .toc { display: flex; flex-wrap: wrap; gap: 8px 18px; margin-top: var(--space-3); font-size: 15px; }
.doc .toc a { color: var(--muted); }
.doc .toc a:hover { color: var(--gold); }
.flags { width: 100%; border-collapse: collapse; margin-top: 14px; font-size: 15px; }
.flags th, .flags td { text-align: left; vertical-align: top; padding: 12px 14px 12px 0; border-bottom: 1px solid var(--line); }
.flags th { color: var(--muted); font-weight: 600; font-size: 13px; letter-spacing: .04em; text-transform: uppercase; }
.flags td:first-child { white-space: nowrap; padding-right: 22px; }
.release { margin-top: var(--space-4); padding: 30px; border: 1px solid var(--line-strong); border-radius: 10px; background: var(--surface); }
.release h2 { margin: 0; font-size: 28px; }
.release .when { color: var(--muted); margin-top: 6px; font-size: 15px; }
.release h3 { margin-top: var(--space-3); font-family: var(--sans); font-size: 13px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--gold); }
.callout { margin-top: var(--space-3); padding: 18px 20px; border-left: 2px solid var(--gold); background: rgba(201,169,106,.06); border-radius: 0 var(--radius) var(--radius) 0; }

/* ---------- Responsive ---------- */
@media (max-width: 960px) {
  .hero-grid, .split, .proof-grid { grid-template-columns: 1fr; }
  .hero h1 { max-width: 16ch; }
  .features { grid-template-columns: 1fr 1fr; }
  .feature, .feature:nth-child(4), .feature:nth-child(5) { grid-column: span 1; }
  .feature:nth-child(5) { grid-column: span 2; }
  .steps { grid-template-columns: 1fr; }
  .costs { grid-template-columns: 1fr; }
  .costs p, .costs p + p { padding: 22px 0; border-left: 0; }
  .costs p + p { border-top: 1px solid var(--line); }
  section { padding: 80px 0; }
}
@media (max-width: 640px) {
  :root { --gutter: 18px; }
  body { font-size: 16px; }
  .features, .plans { grid-template-columns: 1fr; }
  .feature:nth-child(5) { grid-column: span 1; }
  .brand img { height: 34px; }
  .nav { gap: 12px; }
  .hero-ctas .btn { width: 100%; }
  .roll { padding: 22px 20px 16px; }
  .plan, .quote, .note { padding: 26px 22px; }
  .flags td:first-child { white-space: normal; }
  .site-footer .wrap { flex-direction: column; align-items: flex-start; }
}
@media (max-width: 440px) { .nav .btn { display: none; } }
