/* ==========================================================================
   figma-print — marketing site
   Reference: a press colour-bar on bright white stock. Precise, calibrated,
   honest. Bright paper canvas, near-black ink, the CMYK quartet as the real
   functional palette, ink-black actions. Display: Bricolage Grotesque.
   Specs/labels: Spline Sans Mono. Loaded from Google Fonts in the HTML head.
   ========================================================================== */

:root {
  /* CMYK — the brand palette, each channel a real role (not decoration) */
  --c: #14b4e6;
  --m: #ec0f8c;
  --y: #f3b50a;
  --k: #111114;

  /* Surface */
  --paper: #ffffff;
  --paper-2: #f5f6f8;       /* cool, not cream — a faint press-room grey */
  --paper-3: #eceef2;
  --ink: #111114;
  --ink-2: #3a3b42;         /* body — 8.9:1 on white */
  --ink-3: #62646e;         /* muted — 5.4:1 on white */
  --line: #e4e6eb;
  --line-2: #d3d6dd;

  --radius: 16px;
  --radius-sm: 10px;
  --maxw: 1140px;
  --ease: cubic-bezier(0.2, 0.7, 0.2, 1);

  --display: "Bricolage Grotesque", "Archivo", -apple-system, system-ui, sans-serif;
  --sans: "Bricolage Grotesque", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --mono: "Spline Sans Mono", ui-monospace, SFMono-Regular, Menlo, monospace;
}

* { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  font-family: var(--sans);
  background: var(--paper);
  color: var(--ink-2);
  font-size: 17px;
  line-height: 1.6;
  font-feature-settings: "ss01" 1;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

a { color: inherit; text-decoration: none; }

.wrap { width: 100%; max-width: var(--maxw); margin: 0 auto; padding: 0 24px; }
.mono { font-family: var(--mono); font-feature-settings: "tnum" 1; }

/* The CMYK rule — a colour-bar used as a deliberate brand divider. */
.cmyk-rule { display: inline-flex; gap: 3px; height: 6px; }
.cmyk-rule span { width: 30px; border-radius: 1px; }
.cmyk-rule span:nth-child(1) { background: var(--c); }
.cmyk-rule span:nth-child(2) { background: var(--m); }
.cmyk-rule span:nth-child(3) { background: var(--y); }
.cmyk-rule span:nth-child(4) { background: var(--k); }

/* Small mono spec label — used sparingly, NOT above every section. */
.spec {
  font-family: var(--mono);
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-3);
}

/* ==========================================================================
   Header
   ========================================================================== */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: color-mix(in srgb, var(--paper) 86%, transparent);
  backdrop-filter: saturate(150%) blur(14px);
  -webkit-backdrop-filter: saturate(150%) blur(14px);
  border-bottom: 1px solid var(--line);
}
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; height: 64px; }
.brand { display: flex; align-items: center; gap: 11px; }
.brand .logo { width: 28px; height: 28px; border-radius: 7px; display: block; flex: none; }
.brand-mono { font-family: var(--mono); font-size: 0.95rem; font-weight: 600; letter-spacing: -0.01em; color: var(--ink); }
.nav { display: flex; align-items: center; gap: 4px; }
.nav a {
  padding: 8px 13px; border-radius: 9px;
  color: var(--ink-3); font-size: 0.92rem; font-weight: 500;
  transition: color 0.18s var(--ease), background 0.18s var(--ease);
}
.nav a:hover { color: var(--ink); background: var(--paper-2); }
.nav .nav-cta { color: var(--paper); background: var(--ink); }
.nav .nav-cta:hover { background: #2a2b31; color: var(--paper); }
@media (max-width: 680px) { .nav a.nav-hide { display: none; } }

/* ==========================================================================
   Buttons
   ========================================================================== */
.btn {
  display: inline-flex; align-items: center; gap: 9px;
  padding: 13px 20px; border-radius: 11px;
  font-family: var(--sans); font-weight: 600; font-size: 0.96rem; letter-spacing: -0.01em;
  border: 0; cursor: pointer; white-space: nowrap;
  transition: transform 0.14s var(--ease), box-shadow 0.2s var(--ease), background 0.2s var(--ease);
}
.btn:active { transform: translateY(1px); }
.btn svg { width: 17px; height: 17px; flex: none; }
.btn-primary {
  background: var(--ink); color: var(--paper);
  box-shadow: 0 1px 2px rgba(17,17,20,0.2), 0 10px 24px -12px rgba(17,17,20,0.5);
}
.btn-primary:hover { background: #25262c; box-shadow: 0 1px 2px rgba(17,17,20,0.24), 0 14px 30px -12px rgba(17,17,20,0.6); }
.btn-ghost { background: var(--paper); color: var(--ink); box-shadow: inset 0 0 0 1.5px var(--line-2); }
.btn-ghost:hover { box-shadow: inset 0 0 0 1.5px var(--ink-3); }

/* ==========================================================================
   Hero — copy left, real product shot right
   ========================================================================== */
.hero { position: relative; overflow: hidden; border-bottom: 1px solid var(--line); }
.hero .wrap {
  display: grid; grid-template-columns: 1.05fr 0.95fr; gap: 60px;
  align-items: center; padding-top: 76px; padding-bottom: 80px;
}
@media (max-width: 940px) {
  .hero .wrap { grid-template-columns: 1fr; gap: 48px; padding-top: 48px; padding-bottom: 56px; }
}
.eyebrow {
  display: inline-flex; align-items: center; gap: 9px;
  font-family: var(--mono); font-size: 0.72rem; font-weight: 500;
  letter-spacing: 0.06em; text-transform: uppercase; color: var(--ink-3);
  padding: 6px 12px 6px 10px; border-radius: 999px;
  box-shadow: inset 0 0 0 1px var(--line-2);
}
.eyebrow .dot { width: 7px; height: 7px; border-radius: 50%; background: var(--m); }
.hero h1 {
  font-family: var(--display);
  font-size: clamp(2.6rem, 6vw, 4.2rem);
  line-height: 1.02; letter-spacing: -0.035em; margin: 22px 0 0; font-weight: 800;
  color: var(--ink); text-wrap: balance;
}
.hero h1 em { font-style: normal; position: relative; white-space: nowrap; }
.hero h1 em::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: 0.04em; height: 0.13em;
  background: linear-gradient(90deg, var(--c) 0 25%, var(--m) 25% 50%, var(--y) 50% 75%, var(--k) 75% 100%);
  border-radius: 2px;
}
.hero .tagline { font-size: 1.16rem; color: var(--ink-2); margin: 22px 0 0; max-width: 34ch; line-height: 1.55; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 30px; }
.hero-meta {
  margin-top: 26px; font-family: var(--mono); font-size: 0.76rem; letter-spacing: 0.01em;
  color: var(--ink-3); display: flex; flex-wrap: wrap; gap: 9px 20px;
}
.hero-meta span { display: inline-flex; align-items: center; gap: 7px; }
.hero-meta svg { width: 14px; height: 14px; flex: none; }
.hero-meta .mc { color: var(--c); }
.hero-meta .mm { color: var(--m); }
.hero-meta .mk { color: var(--ink); }

/* The product shot, sat in a press-registration frame with crop-mark corners. */
.shot { position: relative; padding: 26px; }
.shot::before, .shot::after,
.shot .corner { position: absolute; width: 16px; height: 16px; pointer-events: none; }
.shot .reg {
  position: absolute; inset: 0;
  background-image:
    linear-gradient(var(--line-2) 1px, transparent 1px),
    linear-gradient(90deg, var(--line-2) 1px, transparent 1px);
  background-size: 22px 22px;
  -webkit-mask-image: radial-gradient(ellipse at center, #000 40%, transparent 78%);
  mask-image: radial-gradient(ellipse at center, #000 40%, transparent 78%);
  opacity: 0.5;
}
.shot img {
  position: relative; display: block; width: 100%; height: auto;
  border-radius: 14px;
  box-shadow: 0 2px 6px rgba(17,17,20,0.06), 0 40px 80px -36px rgba(17,17,20,0.4);
  outline: 1px solid var(--line);
}
.shot .crop { position: absolute; width: 18px; height: 18px; z-index: 2; }
.shot .crop::before, .shot .crop::after { content: ""; position: absolute; background: var(--ink); }
.shot .crop::before { width: 100%; height: 1.5px; top: 0; }
.shot .crop::after { width: 1.5px; height: 100%; left: 0; }
.shot .tl { top: 4px; left: 4px; }
.shot .tr { top: 4px; right: 4px; transform: scaleX(-1); }
.shot .bl { bottom: 4px; left: 4px; transform: scaleY(-1); }
.shot .br { bottom: 4px; right: 4px; transform: scale(-1); }
@media (max-width: 940px) { .shot { max-width: 420px; margin: 0 auto; } }

/* ==========================================================================
   Section scaffolding
   ========================================================================== */
section.block { padding: 84px 0; }
@media (max-width: 720px) { section.block { padding: 56px 0; } }
.section-head { max-width: 640px; margin-bottom: 48px; }
.section-head.center { margin-inline: auto; text-align: center; }
.section-head h2 {
  font-family: var(--display); font-weight: 800;
  font-size: clamp(1.9rem, 4vw, 2.7rem); letter-spacing: -0.03em; line-height: 1.08;
  margin: 16px 0 0; color: var(--ink); text-wrap: balance;
}
.section-head p { color: var(--ink-2); font-size: 1.08rem; margin: 16px 0 0; max-width: 60ch; }
.section-head .cmyk-rule { vertical-align: middle; }

/* ==========================================================================
   Features — a lead block + a supporting grid (not an identical card wall)
   ========================================================================== */
.features-lead {
  display: grid; grid-template-columns: 1.1fr 1fr; gap: 28px; align-items: center;
  background: var(--paper-2); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 36px; margin-bottom: 16px;
}
@media (max-width: 820px) { .features-lead { grid-template-columns: 1fr; padding: 26px; } }
.features-lead h3 { font-family: var(--display); font-weight: 700; font-size: 1.5rem; letter-spacing: -0.02em; margin: 0 0 10px; color: var(--ink); }
.features-lead p { margin: 0; color: var(--ink-2); font-size: 1rem; }
.features-lead .shot { padding: 0; }
.features-lead .shot img { box-shadow: 0 2px 6px rgba(17,17,20,0.05), 0 24px 50px -28px rgba(17,17,20,0.35); }

.features { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
@media (max-width: 860px) { .features { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 540px) { .features { grid-template-columns: 1fr; } }
.feature {
  background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius-sm);
  padding: 24px 22px; transition: border-color 0.2s var(--ease), transform 0.2s var(--ease), box-shadow 0.2s var(--ease);
}
.feature:hover { transform: translateY(-2px); border-color: var(--line-2); box-shadow: 0 18px 40px -26px rgba(17,17,20,0.3); }
.feature .ficon { width: 36px; height: 36px; border-radius: 9px; display: grid; place-items: center; margin-bottom: 15px; background: var(--paper-2); }
.feature .ficon svg { width: 19px; height: 19px; }
.feature h3 { font-family: var(--display); font-weight: 700; font-size: 1.06rem; letter-spacing: -0.01em; margin: 0 0 6px; color: var(--ink); }
.feature p { margin: 0; color: var(--ink-2); font-size: 0.92rem; line-height: 1.55; }
.ic-c { color: var(--c); } .ic-m { color: var(--m); } .ic-y { color: #c79400; } .ic-k { color: var(--ink); }

/* ==========================================================================
   How it works — a genuine 3-step sequence (numbers earn their place)
   ========================================================================== */
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
@media (max-width: 780px) { .steps { grid-template-columns: 1fr; } }
.step { position: relative; }
.step .num {
  font-family: var(--mono); font-weight: 600; font-size: 0.8rem;
  color: var(--ink-3); display: inline-flex; align-items: center; gap: 9px; margin-bottom: 14px;
}
.step .num b { width: 26px; height: 26px; border-radius: 7px; display: grid; place-items: center; background: var(--ink); color: var(--paper); font-weight: 700; }
.step h3 { font-family: var(--display); font-weight: 700; font-size: 1.18rem; letter-spacing: -0.015em; margin: 0 0 6px; color: var(--ink); }
.step p { margin: 0; color: var(--ink-2); font-size: 0.96rem; }

/* ==========================================================================
   Colour / honesty
   ========================================================================== */
.honesty { background: var(--paper-2); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.honesty-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
@media (max-width: 780px) { .honesty-grid { grid-template-columns: 1fr; } }
.note-card { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); padding: 28px 26px; }
.note-card .tag {
  display: inline-flex; align-items: center; gap: 8px;
  font-family: var(--mono); font-size: 0.7rem; font-weight: 500; letter-spacing: 0.04em; text-transform: uppercase;
  padding: 5px 11px; border-radius: 999px; margin-bottom: 16px; color: var(--ink);
  box-shadow: inset 0 0 0 1px var(--line-2);
}
.note-card .tag .sw { width: 8px; height: 8px; border-radius: 2px; }
.tag.default .sw { background: var(--k); }
.tag.optional .sw { background: var(--m); }
.note-card h3 { font-family: var(--display); font-weight: 700; font-size: 1.25rem; letter-spacing: -0.02em; margin: 0 0 10px; color: var(--ink); }
.note-card p { margin: 0 0 9px; color: var(--ink-2); font-size: 0.97rem; }
.note-card p strong { color: var(--ink); font-weight: 600; }

/* ==========================================================================
   Open-source / free band
   ========================================================================== */
.oss { text-align: center; }
.oss .panel {
  position: relative; overflow: hidden;
  background: var(--k); color: var(--paper);
  border-radius: 22px; padding: 56px 40px;
}
.oss .bar { position: absolute; top: 0; left: 0; right: 0; height: 5px; display: flex; }
.oss .bar i { flex: 1; }
.oss .bar i:nth-child(1) { background: var(--c); }
.oss .bar i:nth-child(2) { background: var(--m); }
.oss .bar i:nth-child(3) { background: var(--y); }
.oss .bar i:nth-child(4) { background: var(--paper); }
.oss h2 { font-family: var(--display); font-weight: 800; font-size: clamp(1.8rem, 4vw, 2.6rem); letter-spacing: -0.03em; margin: 0; color: var(--paper); text-wrap: balance; }
.oss p { color: #c9cad2; font-size: 1.08rem; max-width: 60ch; margin: 16px auto 0; }
.oss .hero-actions { justify-content: center; margin-top: 28px; }
.oss .btn-ghost { background: transparent; color: var(--paper); box-shadow: inset 0 0 0 1.5px rgba(255,255,255,0.28); }
.oss .btn-ghost:hover { box-shadow: inset 0 0 0 1.5px rgba(255,255,255,0.6); }
.oss .stats { display: flex; flex-wrap: wrap; justify-content: center; gap: 14px 30px; margin-top: 30px; font-family: var(--mono); font-size: 0.78rem; color: #9a9ba6; }
.oss .stats b { color: var(--paper); font-weight: 600; }

/* ==========================================================================
   Install / CTA band
   ========================================================================== */
.install-band {
  border: 1px solid var(--line); border-radius: 22px; padding: 46px 42px;
  display: grid; grid-template-columns: 1.2fr 1fr; gap: 38px; align-items: center; background: var(--paper);
}
@media (max-width: 820px) { .install-band { grid-template-columns: 1fr; padding: 32px 24px; } }
.install-band h2 { font-family: var(--display); font-weight: 800; font-size: clamp(1.6rem, 4vw, 2.1rem); letter-spacing: -0.03em; margin: 14px 0 0; color: var(--ink); }
.install-band p { color: var(--ink-2); margin: 14px 0 0; font-size: 1rem; }
.install-band .hero-actions { margin-top: 26px; }
.install-steps { margin: 18px 0 0; padding: 0 0 0 1.2em; color: var(--ink-2); font-size: 0.97rem; line-height: 1.7; }
.install-steps li { margin: 7px 0; }
.install-steps strong { color: var(--ink); font-weight: 600; }
.install-steps code, .codeblock { font-family: var(--mono); }
.install-steps code { font-size: 0.85em; background: var(--paper-2); padding: 1px 6px; border-radius: 5px; border: 1px solid var(--line); }
.codeblock {
  font-size: 0.82rem; background: var(--k); color: #d7d8de; border-radius: var(--radius-sm);
  padding: 20px; overflow-x: auto; line-height: 1.85;
}
.codeblock .c { color: #7e8089; } .codeblock .p { color: var(--y); }

/* ==========================================================================
   Footer
   ========================================================================== */
.site-footer { border-top: 1px solid var(--line); padding: 40px 0 52px; }
.site-footer .wrap { display: flex; flex-wrap: wrap; gap: 18px; align-items: center; justify-content: space-between; }
.foot-links { display: flex; flex-wrap: wrap; gap: 18px; font-size: 0.9rem; color: var(--ink-3); }
.foot-links a:hover { color: var(--ink); }
.foot-note { width: 100%; margin-top: 8px; font-size: 0.82rem; color: var(--ink-3); }

/* ==========================================================================
   Guide (install.html)
   ========================================================================== */
.doc { display: grid; grid-template-columns: 230px 1fr; gap: 52px; align-items: start; padding: 52px 0 88px; }
@media (max-width: 900px) { .doc { grid-template-columns: 1fr; gap: 0; } }
.toc { position: sticky; top: 88px; font-size: 0.9rem; }
@media (max-width: 900px) { .toc { position: static; margin-bottom: 32px; padding-bottom: 24px; border-bottom: 1px solid var(--line); } }
.toc .toc-title { font-family: var(--mono); font-size: 0.68rem; font-weight: 500; letter-spacing: 0.1em; text-transform: uppercase; color: var(--ink-3); margin-bottom: 12px; }
.toc a { display: block; padding: 6px 11px; margin: 1px 0; border-radius: 8px; color: var(--ink-3); transition: color 0.18s var(--ease), background 0.18s var(--ease); }
.toc a:hover { color: var(--ink); background: var(--paper-2); }
.toc a.is-active, .toc a[aria-current="true"] { color: var(--ink); font-weight: 600; background: var(--paper-2); }

.prose { max-width: 720px; min-width: 0; }
.prose h1 { font-family: var(--display); font-weight: 800; font-size: clamp(2rem, 5vw, 2.7rem); letter-spacing: -0.035em; line-height: 1.06; margin: 0 0 10px; color: var(--ink); }
.prose .lede { font-size: 1.15rem; color: var(--ink-2); margin: 0 0 8px; }
.prose h2 { font-family: var(--display); font-weight: 700; font-size: 1.5rem; letter-spacing: -0.02em; margin: 54px 0 6px; padding-top: 14px; color: var(--ink); scroll-margin-top: 84px; }
.prose h3 { font-family: var(--display); font-weight: 700; font-size: 1.14rem; letter-spacing: -0.01em; margin: 30px 0 6px; color: var(--ink); scroll-margin-top: 84px; }
.prose p { color: var(--ink-2); margin: 13px 0; }
.prose strong { color: var(--ink); font-weight: 600; }
.prose ul, .prose ol { color: var(--ink-2); padding-left: 22px; margin: 13px 0; }
.prose li { margin: 8px 0; }
.prose a:not(.btn) { color: var(--ink); text-decoration: underline; text-decoration-color: var(--m); text-underline-offset: 3px; text-decoration-thickness: 2px; }
.prose code { font-family: var(--mono); font-size: 0.85em; background: var(--paper-2); color: var(--ink); padding: 2px 6px; border-radius: 6px; border: 1px solid var(--line); }
.prose pre { font-family: var(--mono); font-size: 0.82rem; background: var(--k); color: #d7d8de; border-radius: var(--radius-sm); padding: 18px 20px; overflow-x: auto; line-height: 1.75; margin: 18px 0; }
.prose pre code { background: none; border: 0; padding: 0; color: inherit; }
.prose .menu-path { font-family: var(--mono); font-size: 0.85em; background: var(--paper-2); border: 1px solid var(--line); padding: 2px 8px; border-radius: 6px; white-space: nowrap; color: var(--ink); }
.callout { border: 1px solid var(--line); background: var(--paper-2); border-radius: var(--radius-sm); padding: 16px 18px; margin: 22px 0; }
.callout p { margin: 0; color: var(--ink-2); font-size: 0.94rem; }
.callout strong { color: var(--ink); }
.tabs-legend { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin: 24px 0; }
@media (max-width: 600px) { .tabs-legend { grid-template-columns: 1fr; } }
.tabs-legend .pill { border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 14px 16px; background: var(--paper); }
.tabs-legend .pill b { font-family: var(--mono); display: block; font-size: 0.9rem; margin-bottom: 3px; color: var(--ink); }
.tabs-legend .pill span { font-size: 0.85rem; color: var(--ink-3); }
.back-link { display: inline-flex; align-items: center; gap: 8px; color: var(--ink-3); font-size: 0.9rem; font-weight: 500; margin-bottom: 28px; font-family: var(--mono); }
.back-link:hover { color: var(--ink); }
.back-link svg { width: 15px; height: 15px; }

/* ==========================================================================
   Craft
   ========================================================================== */
.tagline, .section-head p, .feature p, .install-band p, .note-card p { text-wrap: pretty; }
:focus-visible { outline: 2.5px solid var(--m); outline-offset: 2px; border-radius: 4px; }
::selection { background: color-mix(in srgb, var(--m) 22%, transparent); }

@keyframes rise { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
@keyframes shot-in { from { opacity: 0; transform: translateY(18px) scale(0.98); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: no-preference) {
  .hero-copy > * { animation: rise 0.7s var(--ease) both; }
  .hero-copy > :nth-child(1) { animation-delay: 0.04s; }
  .hero-copy > :nth-child(2) { animation-delay: 0.10s; }
  .hero-copy > :nth-child(3) { animation-delay: 0.16s; }
  .hero-copy > :nth-child(4) { animation-delay: 0.22s; }
  .hero-copy > :nth-child(5) { animation-delay: 0.28s; }
  .hero .shot { animation: shot-in 0.85s var(--ease) 0.16s both; }
}
@media (hover: none) { .btn:hover, .feature:hover { transform: none; } }
:where(h1, h2, h3, section)[id] { scroll-margin-top: 84px; }
