/* ============================================================
   Piqt website — Direction C · Confident Categorical
   Shared design system. Link this from every page.
   Tokens mirror piqt-design-v2/02-tokens-C.swift.
   ============================================================ */

/* Self-hosted Plus Jakarta Sans — same files bundled in the Piqt app
   (Piqt/Piqt/Fonts/), converted to WOFF2. No third-party font request on
   a page whose pitch is "nothing leaves your device." No italic face is
   bundled; the one italic usage on the site falls back to the browser's
   synthesized oblique, which is standard, expected behavior. */
@font-face {
  font-family: 'Plus Jakarta Sans';
  src: url('assets/fonts/PlusJakartaSans-Regular.woff2') format('woff2');
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: 'Plus Jakarta Sans';
  src: url('assets/fonts/PlusJakartaSans-Medium.woff2') format('woff2');
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: 'Plus Jakarta Sans';
  src: url('assets/fonts/PlusJakartaSans-SemiBold.woff2') format('woff2');
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: 'Plus Jakarta Sans';
  src: url('assets/fonts/PlusJakartaSans-Bold.woff2') format('woff2');
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: 'Plus Jakarta Sans';
  src: url('assets/fonts/PlusJakartaSans-ExtraBold.woff2') format('woff2');
  font-weight: 800;
  font-style: normal;
  font-display: swap;
}

:root {
  /* — Surfaces & ink (warm neutral) — */
  --bg:        #FAF5EC;   /* page */
  --bg-2:      #FEFBF4;   /* slightly lifted page band */
  --surface:   #FFFFFF;   /* cards */
  --ink:       #181612;   /* headings + body */
  --ink-2:     #5A5044;   /* secondary text */
  --ink-3:     #9B8F7C;   /* tertiary / placeholder */
  --border:    #E7DECB;   /* dividers, hairlines */
  --border-2:  #CBC0A8;

  /* — Categorical buckets — */
  --pick:      #1F5C42;   /* Worth a tag · forest */
  --pick-600:  #174A35;
  --pick-tint: #E0EAE2;
  --clear:     #D9523C;   /* Clean up · coral */
  --clear-600: #AD4130;
  --clear-tint:#F5D9D0;
  --rest:      #3D4E96;   /* Everything else · indigo */
  --rest-600:  #303E78;
  --rest-tint: #DCDFEE;

  /* — Radii (tight, structural) — */
  --r-sm: 6px;
  --r-md: 8px;
  --r-lg: 12px;
  --r-xl: 18px;
  --r-2xl: 26px;
  --pill: 999px;

  /* — Layout — */
  --maxw: 1120px;
  --gutter: clamp(20px, 5vw, 48px);

  --shadow-sm: 0 1px 2px rgba(24,22,18,.06), 0 2px 6px rgba(24,22,18,.05);
  --shadow-md: 0 4px 14px rgba(24,22,18,.08), 0 12px 32px rgba(24,22,18,.07);
  --shadow-lg: 0 18px 60px rgba(24,22,18,.16);
}

/* ---------------------------------------------------------- reset */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: 'Plus Jakarta Sans', system-ui, -apple-system, sans-serif;
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font: inherit; cursor: pointer; }

/* ---------------------------------------------------------- type */
h1, h2, h3, h4 { margin: 0; font-weight: 800; letter-spacing: -0.03em; line-height: 1.05; }
p { margin: 0; text-wrap: pretty; }

.display {
  font-size: clamp(40px, 6.4vw, 74px);
  line-height: 0.98;
  letter-spacing: -0.04em;
}
.h2 { font-size: clamp(30px, 4.4vw, 48px); letter-spacing: -0.035em; }
.h3 { font-size: clamp(21px, 2.4vw, 27px); letter-spacing: -0.02em; }

.overline {
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--ink-3);
}
.lead { font-size: clamp(18px, 1.9vw, 21px); color: var(--ink-2); line-height: 1.55; }
.muted { color: var(--ink-2); }
.mono {
  font-family: ui-monospace, 'SF Mono', Menlo, Consolas, monospace;
  font-size: 12px;
  letter-spacing: 0.02em;
}

/* ---------------------------------------------------------- layout */
.wrap { max-width: var(--maxw); margin: 0 auto; padding-inline: var(--gutter); }
.section { padding-block: clamp(64px, 10vw, 128px); }
.section--tight { padding-block: clamp(48px, 7vw, 88px); }
.band-white { background: var(--surface); }
.band-2 { background: var(--bg-2); }
.divider { border: 0; border-top: 1px solid var(--border); margin: 0; }

.eyebrow-row { display: flex; align-items: center; gap: 12px; margin-bottom: 22px; }
.eyebrow-row .rule { flex: 0 0 28px; height: 2px; background: var(--ink); border-radius: 2px; }
.eyebrow-row .overline { white-space: nowrap; }

/* ---------------------------------------------------------- buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  padding: 14px 24px;
  border-radius: var(--pill);
  font-weight: 700;
  font-size: 16px;
  letter-spacing: -0.01em;
  border: 1.5px solid transparent;
  transition: transform .14s ease, background .18s ease, border-color .18s ease, color .18s ease;
  white-space: nowrap;
}
.btn:active { transform: translateY(1px) scale(.99); }
.btn--primary { background: var(--ink); color: #fff; }
.btn--primary:hover { background: #000; }
.btn--ghost { background: transparent; color: var(--ink); border-color: var(--border-2); }
.btn--ghost:hover { border-color: var(--ink); }
.btn--forest { background: var(--pick); color: #fff; }
.btn--forest:hover { background: var(--pick-600); }
.btn--on-dark { background: #fff; color: var(--ink); }
.btn--on-dark:hover { background: #f1ece1; }
.btn .tf-glyph { width: 18px; height: 18px; }

.cta-stack { display: flex; flex-wrap: wrap; align-items: center; gap: 14px 18px; }
.cta-note { font-size: 13.5px; color: var(--ink-2); }
.cta-note b { color: var(--ink); font-weight: 700; }

/* ---------------------------------------------------------- brand lockup */
.lockup { display: inline-flex; align-items: center; gap: 11px; }
.lockup .mark { width: 30px; height: 30px; }
.wordmark {
  font-weight: 800; font-size: 23px; letter-spacing: -0.06em; color: var(--ink);
  display: inline-flex; align-items: flex-end;
}
.wordmark .dot { width: 6px; height: 6px; border-radius: 50%; background: var(--clear); margin-bottom: 6px; margin-left: 1px; }

/* ---------------------------------------------------------- nav */
.nav {
  position: sticky; top: 0; z-index: 50;
  background: color-mix(in srgb, var(--bg) 86%, transparent);
  backdrop-filter: saturate(1.4) blur(14px);
  border-bottom: 1px solid var(--border);
}
.nav__inner { display: flex; align-items: center; justify-content: space-between; height: 68px; }
.nav__links { display: flex; align-items: center; gap: 30px; }
.nav__links a {
  font-size: 15px; font-weight: 600; color: var(--ink-2);
  transition: color .15s ease;
}
.nav__links a:hover { color: var(--ink); }
.nav__cta { display: flex; align-items: center; gap: 14px; }
@media (max-width: 760px) {
  .nav__links { display: none; }
}

/* ---------------------------------------------------------- bucket chips */
.chip {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 7px 13px 7px 11px; border-radius: var(--pill);
  font-size: 13px; font-weight: 700; letter-spacing: -0.01em;
  border: 1px solid var(--border);
  background: var(--surface);
}
.chip .dot { width: 9px; height: 9px; border-radius: 50%; }
.dot--pick  { background: var(--pick); }
.dot--clear { background: var(--clear); }
.dot--rest  { background: var(--rest); }

/* ---------------------------------------------------------- cards */
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-xl);
  padding: 28px;
}
.card__index { font-size: 13px; font-weight: 800; color: var(--ink-3); letter-spacing: 0.04em; }

/* ---------------------------------------------------------- phone frame + screenshot placeholder */
.phone {
  --bezel: #16140f;
  position: relative;
  width: 100%;
  aspect-ratio: 390 / 844;
  background: var(--bezel);
  border-radius: 46px;
  padding: 11px;
  box-shadow: var(--shadow-lg), inset 0 0 0 1.5px rgba(255,255,255,.06);
}
.phone__screen {
  position: relative;
  width: 100%; height: 100%;
  border-radius: 36px;
  overflow: hidden;
  background: var(--bg);
}
.phone__island {
  position: absolute; top: 11px; left: 50%; transform: translateX(-50%);
  width: 34%; height: 26px; background: #000; border-radius: var(--pill); z-index: 3;
}

/* striped "drop a screenshot here" placeholder */
.shot {
  position: absolute; inset: 0;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 14px; padding: 28px; text-align: center;
  background:
    repeating-linear-gradient(135deg,
      rgba(24,22,18,.035) 0 11px, transparent 11px 22px),
    var(--shot-tint, var(--bg-2));
  color: var(--ink-2);
}
.shot__badge {
  font-family: ui-monospace, 'SF Mono', Menlo, Consolas, monospace;
  font-size: 10.5px; letter-spacing: 0.1em; text-transform: uppercase;
  font-weight: 600; color: var(--shot-accent, var(--ink-3));
  border: 1px dashed var(--shot-accent, var(--border-2));
  padding: 5px 10px; border-radius: var(--pill);
}
.shot__title { font-size: 15px; font-weight: 700; color: var(--ink); letter-spacing: -0.01em; line-height: 1.25; max-width: 22ch; }
.shot__desc { font-size: 12.5px; line-height: 1.45; color: var(--ink-2); max-width: 26ch; }
.shot__spec {
  margin-top: 2px;
  font-family: ui-monospace, 'SF Mono', Menlo, Consolas, monospace;
  font-size: 10px; color: var(--ink-3); letter-spacing: 0.04em;
}

/* ---------------------------------------------------------- footer */
.footer { background: var(--ink); color: #cfc7b8; }
.footer a { color: #cfc7b8; transition: color .15s ease; }
.footer a:hover { color: #fff; }
.footer .wordmark { color: #fff; }
.footer__grid {
  display: grid;
  grid-template-columns: 1.4fr repeat(3, 1fr);
  gap: 40px 28px;
  padding-block: 64px 40px;
}
.footer__col h5 {
  margin: 0 0 16px; font-size: 12px; font-weight: 800;
  letter-spacing: 0.14em; text-transform: uppercase; color: #8a8170;
}
.footer__col ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 11px; font-size: 14.5px; }
.footer__bar {
  display: flex; flex-wrap: wrap; gap: 12px 22px; align-items: center; justify-content: space-between;
  padding-block: 24px; border-top: 1px solid rgba(255,255,255,.1);
  font-size: 13px; color: #8a8170;
}
@media (max-width: 760px) {
  .footer__grid { grid-template-columns: 1fr 1fr; }
}

/* ---------------------------------------------------------- legal / doc pages */
.doc { max-width: 760px; }
.doc h1 { font-size: clamp(34px, 5vw, 52px); margin-bottom: 12px; }
.doc h2 { font-size: 22px; margin-top: 44px; margin-bottom: 12px; letter-spacing: -0.02em; }
.doc h3 { font-size: 18px; margin-top: 32px; margin-bottom: 10px; letter-spacing: -0.015em; }
.doc p, .doc li { color: var(--ink-2); font-size: 16.5px; line-height: 1.7; }
.doc p + p { margin-top: 16px; }
.doc ul, .doc ol { margin: 14px 0; padding-left: 22px; display: grid; gap: 9px; }
.doc strong { color: var(--ink); font-weight: 700; }
.doc a { color: var(--rest); text-decoration: underline; text-underline-offset: 2px; }
.doc a:hover { color: var(--rest-600); }
.doc__updated { font-size: 14px; color: var(--ink-3); margin-bottom: 8px; }
.doc__lead { font-size: 18.5px; color: var(--ink); line-height: 1.6; margin-bottom: 8px; }
.blog-cover {
  display: block;
  width: 100%;
  height: auto;
  border-radius: var(--r-xl);
  margin-bottom: 32px;
  box-shadow: var(--shadow-sm);
}
.doc img {
  display: block;
  max-width: 100%;
  height: auto;
  border-radius: var(--r-lg);
  margin: 24px 0;
}
.doc img.doc-shot {
  max-width: 280px;
  margin: 28px auto;
  box-shadow: var(--shadow-md);
}
.doc-shot-caption {
  text-align: center;
  font-size: 13px;
  color: var(--ink-3);
  margin-top: -18px;
  margin-bottom: 28px;
}

/* ---------------------------------------------------------- faq */
.faq { display: grid; gap: 14px; }
.faq details {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--r-lg); overflow: hidden;
}
.faq summary {
  list-style: none; cursor: pointer;
  display: flex; align-items: center; justify-content: space-between; gap: 18px;
  padding: 22px 24px; font-weight: 700; font-size: 17.5px; letter-spacing: -0.015em;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary .pm { flex: 0 0 auto; width: 22px; height: 22px; position: relative; transition: transform .2s ease; }
.faq summary .pm::before, .faq summary .pm::after {
  content: ''; position: absolute; background: var(--ink-3); border-radius: 2px;
}
.faq summary .pm::before { top: 10px; left: 2px; right: 2px; height: 2px; }
.faq summary .pm::after { left: 10px; top: 2px; bottom: 2px; width: 2px; transition: opacity .2s ease; }
.faq details[open] summary .pm::after { opacity: 0; }
.faq details[open] summary { color: var(--ink); }
.faq__body { padding: 0 24px 24px; color: var(--ink-2); font-size: 16px; line-height: 1.65; }
.faq__body p + p { margin-top: 12px; }

/* ---------------------------------------------------------- blog */
.blog-list { display: grid; gap: 16px; list-style: none; margin: 0; padding: 0; }
.blog-card {
  display: block;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-xl);
  overflow: hidden;
  transition: border-color .15s ease, box-shadow .15s ease, transform .15s ease;
}
.blog-card:hover {
  border-color: var(--border-2);
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}
.blog-card__cover {
  display: block;
  width: 100%;
  height: auto;
  background: var(--bg-2);
}
.blog-card__body { padding: 28px 32px 30px; }
.blog-card__title {
  font-size: clamp(19px, 2.2vw, 23px);
  color: var(--ink);
  margin-bottom: 10px;
}
.blog-card__desc { color: var(--ink-2); font-size: 15.5px; line-height: 1.6; max-width: 62ch; }
.blog-card__meta {
  display: flex; align-items: center; gap: 14px; flex-wrap: wrap;
  margin-top: 18px; font-size: 13px; color: var(--ink-3);
}
.blog-card__meta time {
  font-family: ui-monospace, 'SF Mono', Menlo, Consolas, monospace;
  letter-spacing: .02em;
}
.blog-card__arrow {
  display: inline-flex; align-items: center; gap: 6px;
  margin-top: 20px; font-size: 14px; font-weight: 700; color: var(--ink);
}
.blog-card__arrow svg { width: 14px; height: 14px; transition: transform .15s ease; }
.blog-card:hover .blog-card__arrow svg { transform: translateX(3px); }

.blog-tags { display: flex; gap: 8px; flex-wrap: wrap; }
.blog-tag {
  display: inline-flex; align-items: center;
  padding: 4px 11px; border-radius: var(--pill);
  font-size: 12px; font-weight: 700; letter-spacing: .02em;
  border: 1px solid var(--border); color: var(--ink-3);
  background: var(--bg-2);
}

/* ---------------------------------------------------------- utilities */
.center { text-align: center; }
.mx-auto { margin-inline: auto; }
.maxch-50 { max-width: 50ch; }
.maxch-40 { max-width: 40ch; }
.grid { display: grid; }
.stack-sm > * + * { margin-top: 12px; }

@media (prefers-reduced-motion: reduce) {
  * { scroll-behavior: auto !important; }
}
