/* ==========================================================================
   PrivyPIN — shared stylesheet
   Design tokens, base type, nav, footer, buttons, containers, cards, pills.
   Responsive with NO media queries: clamp() + flex-wrap + grid auto-fit.
   ========================================================================== */

/* ---- Reset -------------------------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; }
html, body, h1, h2, h3, h4, p, figure, blockquote, dl, dd, ul, ol { margin: 0; }
ul, ol { padding: 0; }
img, svg { display: block; max-width: 100%; }
[hidden] { display: none !important; }
button { font: inherit; }
input, textarea, select { font: inherit; }
input:focus { outline: none; }

/* ---- Design tokens ------------------------------------------------------ */
:root {
  /* Surfaces */
  --paper: #F4F0E6;
  --alt-paper: #EDE8DA;
  --card: #FFFFFF;

  /* Warm borders / dividers */
  --border-card: #E7E1D2;
  --border-divider: #E2DBC9;
  --border-divider-2: #E0D9C8;
  --border-input: #D9D2C2;
  --border-chip: #DDD6C6;
  --border-float: #EFE9DB;

  /* Text */
  --ink: #16152A;
  --body: #4A4860;
  --muted: #77748A;
  --muted-2: #8A8698;
  --body-alt: #3a3850;

  /* Brand indigo */
  --brand: #332B96;
  --brand-hover: #29237A;
  --brand-bg-08: rgba(51, 43, 150, 0.08);
  --brand-bg-09: rgba(51, 43, 150, 0.09);
  --brand-bg-12: rgba(51, 43, 150, 0.12);
  --brand-border: rgba(51, 43, 150, 0.16);

  /* Light indigo (on dark) */
  --indigo-light: #B9B3E8;
  --indigo-light-2: #C6C2DA;
  --indigo-light-3: #C7C2F0;
  --indigo-light-4: #CFCBF0;

  /* Green (success / rings through) */
  --green: #1E8A5A;
  --green-bg: #E4F2EA;
  --green-border: #B8E0C9;
  --green-on-dark: #5FD39B;
  --green-title: #14532d;
  --green-body: #3f6b52;

  /* Amber (trusted / voicemail) */
  --amber: #B4791A;
  --amber-bg: #F7EDD6;

  /* Red (blocked / fail) */
  --red: #C6413B;
  --red-bg: #F7E3E1;

  /* Footer / dark muted */
  --footer-muted: #A6A2C4;
  --footer-muted-2: #726E90;

  /* Dark section text */
  --on-dark: #E9E7F5;
  --on-dark-body: #B7B3CE;
  --on-dark-body-2: #DAD7EC;

  /* Shape */
  --r-chip: 10px;
  --r-btn: 12px;
  --r-input: 12px;
  --r-card: 18px;
  --r-card-lg: 24px;
  --r-pill: 999px;

  /* Shadows */
  --sh-btn: 0 6px 16px -5px rgba(51, 43, 150, 0.5);
  --sh-btn-lg: 0 8px 20px -6px rgba(51, 43, 150, 0.55);
  --sh-btn-xl: 0 10px 24px -8px rgba(51, 43, 150, 0.5);
  --sh-card: 0 24px 56px -28px rgba(20, 19, 42, 0.28);
  --sh-phone: 0 34px 64px -22px rgba(20, 19, 42, 0.55), 0 0 0 1px rgba(255, 255, 255, 0.06);

  /* Layout */
  --container: 1120px;
  --prose: 760px;

  /* Fonts */
  --font-body: 'Hanken Grotesk', system-ui, -apple-system, sans-serif;
  --font-display: 'Bricolage Grotesque', system-ui, -apple-system, sans-serif;
  --font-mono: 'JetBrains Mono', ui-monospace, monospace;
}

/* ---- Base ---------------------------------------------------------------- */
html {
  scroll-behavior: smooth;
  scroll-padding-top: 84px;
}
body {
  font-family: var(--font-body);
  background: var(--paper);
  color: var(--ink);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
a { color: var(--brand); text-decoration: none; }
a:hover { color: var(--brand-hover); }
::selection { background: var(--brand); color: #fff; }

/* Wrap that clips the offset gradients/chips from causing horizontal scroll */
.page { overflow-x: hidden; }

@keyframes floaty {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-10px); }
}

/* ---- Containers --------------------------------------------------------- */
.container {
  max-width: var(--container);
  margin: 0 auto;
}
.prose-container {
  max-width: var(--prose);
  margin: 0 auto;
}

/* Section vertical/horizontal padding (media-query-free) */
.section {
  padding: clamp(64px, 8vw, 112px) clamp(20px, 5vw, 40px);
}
.section-paper { background: var(--paper); }
.section-alt { background: var(--alt-paper); }

/* ---- Typography helpers ------------------------------------------------- */
.eyebrow {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--brand);
}
.h2 {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(2rem, 4.2vw, 3.1rem);
  line-height: 1.04;
  letter-spacing: -0.02em;
  color: var(--ink);
  text-wrap: balance;
}
.lead {
  font-size: clamp(1.02rem, 1.5vw, 1.18rem);
  line-height: 1.55;
  color: var(--body);
}

/* ---- Sticky nav --------------------------------------------------------- */
.nav-header {
  position: sticky;
  top: 0;
  z-index: 50;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  background: rgba(244, 240, 230, 0.82);
  border-bottom: 1px solid var(--border-card);
}
.nav {
  max-width: var(--container);
  margin: 0 auto;
  padding: 13px clamp(20px, 5vw, 40px);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}
.nav-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--ink);
}
.nav-brand:hover { color: var(--ink); }
.logo-chip {
  width: 34px;
  height: 34px;
  border-radius: var(--r-chip);
  background: var(--brand);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 3px;
  box-shadow: 0 3px 8px rgba(51, 43, 150, 0.4);
}
.logo-chip span {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: #fff;
}
.wordmark {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.28rem;
  letter-spacing: -0.02em;
}
.wordmark .pin { color: var(--brand); }
.nav-links {
  display: flex;
  align-items: center;
  gap: clamp(14px, 2.5vw, 28px);
  flex-wrap: wrap;
}
.nav-link {
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--body);
}
.nav-link:hover { color: var(--brand); }

/* ---- Buttons ------------------------------------------------------------ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-weight: 700;
  border-radius: var(--r-btn);
  border: none;
  cursor: pointer;
  transition: all .15s ease;
  text-align: center;
}
.btn-primary {
  background: var(--brand);
  color: #fff;
  box-shadow: var(--sh-btn);
}
.btn-primary:hover {
  background: var(--brand-hover);
  color: #fff;
  transform: translateY(-1px);
}
/* Nav-sized primary */
.btn-nav {
  font-size: 0.95rem;
  padding: 0.62rem 1.1rem;
  border-radius: 11px;
}
/* Form submit */
.btn-submit {
  flex: 0 0 auto;
  font-size: 1rem;
  padding: 0.95rem 1.5rem;
  box-shadow: var(--sh-btn-lg);
}
/* Pricing / block button */
.btn-block {
  display: flex;
  width: 100%;
  font-size: 1.02rem;
  padding: 1rem 1.4rem;
  box-shadow: var(--sh-btn-xl);
}
/* White button on indigo band */
.btn-on-brand {
  background: #fff;
  color: var(--brand);
  font-size: 1.05rem;
  padding: 1rem 1.8rem;
  box-shadow: 0 12px 32px -10px rgba(0, 0, 0, 0.4);
}
.btn-on-brand:hover {
  background: #fff;
  color: var(--brand);
  transform: translateY(-2px);
}

/* ---- Cards -------------------------------------------------------------- */
.card {
  background: var(--card);
  border: 1px solid var(--border-card);
  border-radius: var(--r-card);
  padding: 26px;
}
.card-title {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.24rem;
  margin: 18px 0 0;
  color: var(--ink);
  letter-spacing: -0.01em;
}
.card-body {
  margin: 10px 0 0;
  color: var(--body);
  line-height: 1.55;
  font-size: 0.98rem;
}

/* Card grids (auto-fit, media-query-free) */
.grid-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(238px, 1fr));
  gap: 18px;
}
.grid-steps {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(258px, 1fr));
  gap: clamp(24px, 3vw, 40px);
}

/* Chip glyph for benefit cards */
.glyph-chip {
  width: 46px;
  height: 46px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: 1.25rem;
}
.glyph-red { background: var(--red-bg); color: var(--red); }
.glyph-indigo { background: var(--brand-bg-09); color: var(--brand); }
.glyph-green { background: var(--green-bg); color: var(--green); }
.glyph-ink {
  background: #ECE9DE;
  color: var(--ink);
  font-size: 1rem;
  letter-spacing: 0.12em;
}

/* ---- Pills / badges ----------------------------------------------------- */
.pill {
  font-family: var(--font-mono);
  font-size: 0.71rem;
  font-weight: 600;
  padding: 5px 11px;
  border-radius: var(--r-pill);
}
.pill-green { background: var(--green-bg); color: var(--green); }
.pill-amber { background: var(--amber-bg); color: var(--amber); }
.pill-red { background: var(--red-bg); color: var(--red); }

/* ---- Check bullets ------------------------------------------------------ */
.check-bullet {
  display: flex;
  gap: 15px;
  align-items: flex-start;
}
.check-circle {
  flex: 0 0 auto;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 0.85rem;
}
/* on dark privacy band */
.check-circle-dark {
  background: rgba(30, 138, 90, 0.22);
  color: var(--green-on-dark);
}
/* small check for feature lists (light) */
.check-sm {
  flex: 0 0 auto;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--green-bg);
  color: var(--green);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 0.72rem;
}

/* ---- Dark section band -------------------------------------------------- */
.section-band {
  padding: clamp(72px, 9vw, 120px) clamp(20px, 5vw, 40px);
  background: var(--ink);
  color: var(--on-dark);
}

/* ---- Footer (dark) ------------------------------------------------------ */
.footer {
  background: var(--ink);
  color: var(--footer-muted);
  padding: clamp(48px, 6vw, 72px) clamp(20px, 5vw, 40px) 34px;
}
.footer-inner {
  max-width: var(--container);
  margin: 0 auto;
}
.footer-top {
  display: flex;
  flex-wrap: wrap;
  gap: clamp(32px, 5vw, 64px);
  justify-content: space-between;
}
.footer-brand-block {
  flex: 1 1 280px;
  max-width: 340px;
}
.footer-brand {
  display: flex;
  align-items: center;
  gap: 10px;
}
.footer-logo-chip {
  width: 32px;
  height: 32px;
  border-radius: 9px;
  background: var(--brand);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 3px;
}
.footer-logo-chip span {
  width: 4.5px;
  height: 4.5px;
  border-radius: 50%;
  background: #fff;
}
.footer-wordmark {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.2rem;
  letter-spacing: -0.02em;
  color: #fff;
}
.footer-wordmark .pin { color: var(--indigo-light); }
.footer-tagline {
  margin: 16px 0 0;
  line-height: 1.55;
  color: var(--footer-muted);
  font-size: 0.95rem;
  max-width: 32ch;
}
.footer-cols {
  display: flex;
  flex-wrap: wrap;
  gap: clamp(32px, 5vw, 64px);
}
.footer-col-title {
  font-family: var(--font-mono);
  font-size: 0.66rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--footer-muted-2);
  margin-bottom: 14px;
}
.footer-col-links {
  display: flex;
  flex-direction: column;
  gap: 11px;
}
.footer-col-links a {
  color: var(--indigo-light-2);
  font-size: 0.95rem;
}
.footer-col-links a:hover { color: #fff; }
.footer-divider {
  height: 1px;
  background: rgba(255, 255, 255, 0.1);
  margin: 36px 0 22px;
}
.footer-bottom {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  justify-content: space-between;
  align-items: center;
}
.footer-copy {
  margin: 0;
  color: var(--muted-2);
  font-size: 0.84rem;
}
.footer-trademark {
  margin: 0;
  color: var(--footer-muted-2);
  font-size: 0.8rem;
  max-width: 56ch;
}

/* ---- Prose (legal / support content) ------------------------------------ */
.prose {
  color: var(--body);
  line-height: 1.7;
  font-size: 1.02rem;
}
.prose h2 {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(1.4rem, 2.6vw, 1.8rem);
  letter-spacing: -0.01em;
  color: var(--ink);
  margin: 40px 0 0;
}
.prose h3 {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.16rem;
  letter-spacing: -0.01em;
  color: var(--ink);
  margin: 26px 0 0;
}
.prose p { margin: 14px 0 0; }
.prose ul { margin: 14px 0 0; padding-left: 1.2em; }
.prose li { margin: 8px 0 0; }
.prose a { font-weight: 600; }
.prose strong { color: var(--ink); font-weight: 700; }

/* Page hero band (privacy / terms / support) */
.page-hero {
  padding: clamp(56px, 7vw, 96px) clamp(20px, 5vw, 40px) clamp(40px, 5vw, 64px);
  background: var(--alt-paper);
  border-bottom: 1px solid var(--border-divider);
}
.back-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--brand);
  font-weight: 600;
}
.page-h1 {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(2.2rem, 5vw, 3.4rem);
  line-height: 1.02;
  letter-spacing: -0.02em;
  color: var(--ink);
  margin: 18px 0 0;
  text-wrap: balance;
}
.page-updated {
  margin: 14px 0 0;
  color: var(--muted);
  font-size: 0.95rem;
}

/* ---- FAQ accordion (native <details>) ----------------------------------- */
.faq-item {
  border-bottom: 1px solid var(--border-divider-2);
}
.faq-summary {
  list-style: none;
  cursor: pointer;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 22px 2px;
  color: var(--ink);
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(1.05rem, 1.8vw, 1.22rem);
  letter-spacing: -0.01em;
}
.faq-summary::-webkit-details-marker { display: none; }
.faq-toggle {
  flex: 0 0 auto;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: #ECE9DE;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  color: var(--brand);
  font-size: 1.1rem;
  line-height: 1;
}
.faq-toggle::before { content: "+"; }
.faq-item[open] .faq-toggle::before { content: "−"; }
.faq-answer {
  margin: 0;
  padding: 0 2px 24px;
  color: var(--body);
  line-height: 1.62;
  font-size: 1.02rem;
  max-width: 66ch;
}

/* Callout boxes (privacy short-version / terms 911) */
.callout {
  border-radius: var(--r-card);
  padding: 20px 22px;
  margin: 28px 0 0;
}
.callout-green {
  background: var(--green-bg);
  border: 1.5px solid var(--green-border);
}
.callout-red {
  background: var(--red-bg);
  border: 1.5px solid #E9B7B4;
}
