/* ============================================================
   PARLEY MARKETING SITE — STYLES
   ------------------------------------------------------------
   Sections (search for the labels to jump around):
     1. TOKENS         — colours, fonts, spacing variables
     2. RESET + BASE   — element defaults
     3. LAYOUT         — container, sections, reveal animation
     4. BUTTONS        — .btn variants
     5. NAVIGATION
     6. HERO
     7. FEATURES
     8. PROOF / TESTIMONIALS
     9. PRICING
    10. DOWNLOAD
    11. CONTACT
    12. FOOTER
    13. RESPONSIVE     — mobile breakpoints
   ============================================================ */

/* 1. TOKENS ================================================== */
:root {
  /* Brand palette */
  --navy:        #1a2942;
  --cream:       #F5EFE0;
  --terracotta:  #D85A30;
  --terracotta-dark: #BE4A24;
  --page-bg:     #F8F7F5;
  --border:      #E2DDD8;
  --muted:       #6B6560;

  /* Type */
  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Helvetica, Arial, sans-serif;
  --font-display: 'Plus Jakarta Sans', 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-mono: 'JetBrains Mono', 'Fira Code', ui-monospace, SFMono-Regular, Menlo, monospace;

  /* Sizing */
  --container: 1180px;
  --radius:    14px;
  --radius-lg: 22px;

  /* Motion */
  --ease: cubic-bezier(.2, .7, .2, 1);
}

/* 2. RESET + BASE ============================================ */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--font-sans);
  font-size: 17px;
  line-height: 1.7;
  color: var(--navy);
  background: var(--page-bg);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.15;
  color: var(--navy);
  margin: 0 0 0.5em;
}
h1 { font-size: clamp(40px, 6vw, 68px); letter-spacing: -0.03em; }
h2 { font-size: clamp(30px, 4vw, 44px); }
h3 { font-size: 20px; }
h4 { font-size: 15px; text-transform: uppercase; letter-spacing: 0.08em; }

p { margin: 0 0 1em; }
a { color: var(--terracotta); text-decoration: none; transition: color .15s var(--ease); }
a:hover { color: var(--terracotta-dark); }

img, svg { display: block; max-width: 100%; }
img { height: auto; }

ul { padding: 0; margin: 0; list-style: none; }

button { font: inherit; cursor: pointer; }

::selection { background: var(--terracotta); color: var(--cream); }

/* 3. LAYOUT ================================================== */
.container {
  width: 100%;
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 24px;
}

section { padding: 96px 0; }

.eyebrow {
  display: inline-block;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--terracotta);
  margin: 0 0 14px;
}

.section-head {
  text-align: center;
  max-width: 720px;
  margin: 0 auto 56px;
}
.section-head__sub {
  color: var(--muted);
  font-size: 18px;
  margin-top: 8px;
}

.muted { color: var(--muted); }

/* Reveal animation */
.reveal {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity .7s var(--ease), transform .7s var(--ease);
}
.reveal.is-visible { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
  html { scroll-behavior: auto; }
}

/* 4. BUTTONS ================================================= */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 24px;
  font-weight: 600;
  font-size: 16px;
  border-radius: 12px;
  border: 1.5px solid transparent;
  text-decoration: none;
  transition: transform .15s var(--ease), background-color .15s var(--ease), box-shadow .2s var(--ease), color .15s var(--ease), border-color .15s var(--ease);
  white-space: nowrap;
  line-height: 1;
  min-height: 44px;
}
.btn:hover { transform: scale(1.02); }
.btn:active { transform: scale(0.99); }

.btn--primary {
  background: var(--terracotta);
  color: var(--cream);
}
.btn--primary:hover {
  background: var(--terracotta-dark);
  color: var(--cream);
}

.btn--secondary {
  background: transparent;
  color: var(--navy);
  border-color: var(--navy);
}
.btn--secondary:hover {
  background: var(--navy);
  color: var(--cream);
}

.btn--outline {
  background: transparent;
  color: var(--navy);
  border-color: var(--border);
}
.btn--outline:hover {
  background: var(--navy);
  color: var(--cream);
  border-color: var(--navy);
}

.btn--small  { padding: 10px 18px; font-size: 14px; min-height: 40px; }
.btn--large  { padding: 18px 28px; font-size: 17px; min-height: 52px; }
.btn--full   { width: 100%; }

.btn--disabled,
.btn[disabled] {
  background: var(--border);
  color: var(--muted);
  cursor: not-allowed;
  pointer-events: none;
  border-color: transparent;
}

/* 5. NAVIGATION ============================================== */
.nav {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(248, 247, 245, 0.85);
  backdrop-filter: saturate(180%) blur(14px);
  -webkit-backdrop-filter: saturate(180%) blur(14px);
  transition: box-shadow .2s var(--ease), background-color .2s var(--ease);
}
.nav.is-scrolled {
  box-shadow: 0 1px 0 rgba(26, 41, 66, 0.06), 0 6px 24px rgba(26, 41, 66, 0.06);
}
.nav__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
  gap: 24px;
}
.nav__brand { display: inline-flex; align-items: center; }
.nav__logo  { height: 32px; width: auto; }
.nav__brand-fallback {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 22px;
  color: var(--navy);
  letter-spacing: -0.02em;
}

.nav__links {
  display: flex;
  align-items: center;
  gap: 28px;
}
.nav__links a {
  color: var(--navy);
  font-weight: 500;
  font-size: 15px;
}
.nav__links a:not(.btn):hover { color: var(--terracotta); }

.nav__toggle {
  display: none;
  background: transparent;
  border: 0;
  width: 44px;
  height: 44px;
  padding: 0;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 5px;
}
.nav__toggle span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--navy);
  border-radius: 2px;
  transition: transform .25s var(--ease), opacity .25s var(--ease);
}
.nav__toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav__toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav__toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* 6. HERO ==================================================== */
.hero {
  background: linear-gradient(180deg, var(--cream) 0%, var(--page-bg) 100%);
  padding: 80px 0 96px;
  overflow: hidden;
}
.hero__inner {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
  align-items: center;
}
.hero__headline {
  margin: 0 0 20px;
}
.hero__sub {
  font-size: 19px;
  color: var(--muted);
  line-height: 1.65;
  margin: 0 0 32px;
  max-width: 560px;
}
.hero__ctas {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 20px;
}
.hero__trust {
  font-size: 14px;
  color: var(--muted);
  margin: 0;
}

/* Mockup device */
.device {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow:
    0 1px 2px rgba(26, 41, 66, 0.04),
    0 30px 60px -20px rgba(26, 41, 66, 0.25),
    0 18px 36px -12px rgba(26, 41, 66, 0.15);
  transform: rotate(-0.5deg);
}
.device__chrome {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 12px 16px;
  background: var(--cream);
  border-bottom: 1px solid var(--border);
  position: relative;
}
.device__dot { width: 11px; height: 11px; border-radius: 50%; display: inline-block; }
.device__dot--red    { background: #ED6A5E; }
.device__dot--amber  { background: #F4BF4F; }
.device__dot--green  { background: #61C554; }
.device__title {
  position: absolute;
  left: 50%; transform: translateX(-50%);
  font-size: 12px; color: var(--muted); font-weight: 500;
}
.device__image { width: 100%; height: auto; display: block; }
.device__placeholder {
  display: flex;
  padding: 28px;
  min-height: 360px;
  background: #fff;
}
.device__placeholder-inner {
  width: 100%;
  display: grid;
  grid-template-rows: auto 1fr auto;
  gap: 20px;
}
.device__wave {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  height: 56px;
  background: var(--cream);
  border-radius: 10px;
  padding: 0 18px;
}
.device__wave span {
  width: 3px;
  background: var(--terracotta);
  border-radius: 2px;
  animation: wave 1.4s ease-in-out infinite;
}
.device__wave span:nth-child(1)  { height: 30%; animation-delay: 0.0s; }
.device__wave span:nth-child(2)  { height: 60%; animation-delay: 0.1s; }
.device__wave span:nth-child(3)  { height: 90%; animation-delay: 0.2s; }
.device__wave span:nth-child(4)  { height: 70%; animation-delay: 0.3s; }
.device__wave span:nth-child(5)  { height: 45%; animation-delay: 0.4s; }
.device__wave span:nth-child(6)  { height: 80%; animation-delay: 0.5s; }
.device__wave span:nth-child(7)  { height: 55%; animation-delay: 0.4s; }
.device__wave span:nth-child(8)  { height: 35%; animation-delay: 0.3s; }
.device__wave span:nth-child(9)  { height: 70%; animation-delay: 0.2s; }
.device__wave span:nth-child(10) { height: 95%; animation-delay: 0.1s; }
.device__wave span:nth-child(11) { height: 65%; animation-delay: 0.0s; }
.device__wave span:nth-child(12) { height: 40%; animation-delay: 0.1s; }
.device__wave span:nth-child(13) { height: 75%; animation-delay: 0.2s; }
.device__wave span:nth-child(14) { height: 50%; animation-delay: 0.3s; }
.device__wave span:nth-child(15) { height: 25%; animation-delay: 0.4s; }
@keyframes wave {
  0%, 100% { transform: scaleY(0.6); }
  50%      { transform: scaleY(1.2); }
}

.device__transcript {
  background: var(--page-bg);
  border-radius: 10px;
  padding: 14px 16px;
  font-size: 13px;
  line-height: 1.55;
}
.device__transcript p { margin: 0 0 4px; color: var(--navy); }
.device__transcript p strong { color: var(--terracotta); font-weight: 600; font-size: 11px; letter-spacing: 0.05em; }
.device__transcript p:nth-child(odd) { color: var(--muted); font-size: 11px; }

.device__summary {
  background: var(--navy);
  border-radius: 10px;
  padding: 14px 16px;
  color: var(--cream);
}
.device__summary-label {
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--terracotta);
  margin: 0 0 6px;
}
.device__summary ul { font-size: 12px; }
.device__summary li { padding-left: 12px; position: relative; margin-bottom: 4px; color: var(--cream); }
.device__summary li::before {
  content: '';
  position: absolute;
  left: 0; top: 8px;
  width: 4px; height: 4px;
  background: var(--terracotta);
  border-radius: 50%;
}

/* 7. FEATURES ================================================ */
.features {
  background: var(--page-bg);
}
.features__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}
.feature-card {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 32px 28px;
  transition: transform .2s var(--ease), box-shadow .2s var(--ease), border-color .2s var(--ease);
}
.feature-card:hover {
  transform: translateY(-3px);
  border-color: rgba(26, 41, 66, 0.15);
  box-shadow: 0 12px 30px -12px rgba(26, 41, 66, 0.12);
}
.feature-card__icon {
  width: 48px; height: 48px;
  border-radius: 12px;
  background: var(--cream);
  color: var(--terracotta);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 20px;
}
.feature-card__icon svg { width: 26px; height: 26px; }
.feature-card h3 { margin: 0 0 8px; }
.feature-card p { color: var(--muted); margin: 0; font-size: 15px; line-height: 1.65; }

/* 8. PROOF =================================================== */
.proof {
  background: var(--navy);
  color: var(--cream);
  padding: 80px 0;
}
.proof__lead {
  text-align: center;
  font-size: 18px;
  color: var(--cream);
  opacity: 0.85;
  margin: 0 0 48px;
}
.proof__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}
.testimonial {
  background: rgba(245, 239, 224, 0.06);
  border: 1px solid rgba(245, 239, 224, 0.12);
  border-radius: var(--radius);
  padding: 28px;
  margin: 0;
}
.testimonial p {
  color: var(--cream);
  font-size: 16px;
  line-height: 1.6;
  margin: 0 0 16px;
}
.testimonial cite {
  display: block;
  font-style: normal;
  font-size: 13px;
  color: var(--terracotta);
  font-weight: 500;
  letter-spacing: 0.02em;
}

/* 9. PRICING ================================================= */
.pricing {
  background: var(--page-bg);
}
.pricing__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
  max-width: 880px;
  margin: 0 auto;
}
.plan {
  position: relative;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 40px 32px;
  display: flex;
  flex-direction: column;
}
.plan--popular {
  border-color: var(--terracotta);
  box-shadow: 0 18px 50px -20px rgba(216, 90, 48, 0.25);
}
.plan__badge {
  position: absolute;
  top: -14px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--terracotta);
  color: var(--cream);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 6px 14px;
  border-radius: 999px;
}
.plan__name {
  font-size: 22px;
  margin: 0 0 12px;
}
.plan__price {
  display: flex;
  align-items: baseline;
  gap: 4px;
  margin-bottom: 28px;
  flex-wrap: wrap;
}
.plan__from {
  font-size: 14px;
  color: var(--muted);
  margin-right: 2px;
}
.plan__amount {
  font-family: var(--font-display);
  font-size: 48px;
  font-weight: 800;
  letter-spacing: -0.02em;
}
.plan__period {
  font-size: 16px;
  color: var(--muted);
}
.plan__features {
  margin: 0 0 28px;
  flex: 1;
}
.plan__features li {
  padding: 10px 0 10px 28px;
  border-bottom: 1px solid var(--border);
  position: relative;
  font-size: 15px;
}
.plan__features li:last-child { border-bottom: 0; }
.plan__features li::before {
  content: '';
  position: absolute;
  left: 0; top: 14px;
  width: 16px; height: 16px;
  background: var(--cream);
  border-radius: 50%;
}
.plan__features li::after {
  content: '';
  position: absolute;
  left: 4px; top: 17px;
  width: 8px; height: 4px;
  border-left: 2px solid var(--terracotta);
  border-bottom: 2px solid var(--terracotta);
  transform: rotate(-45deg);
}
.pricing__note {
  text-align: center;
  color: var(--muted);
  font-size: 14px;
  max-width: 600px;
  margin: 36px auto 0;
}

/* 10. DOWNLOAD =============================================== */
.download {
  background: var(--cream);
}
.download__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
  max-width: 880px;
  margin: 0 auto;
}
.dl-card {
  position: relative;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 36px 32px;
  text-align: center;
  transition: transform .2s var(--ease), box-shadow .2s var(--ease);
}
.dl-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 16px 40px -16px rgba(26, 41, 66, 0.18);
}
.dl-card.is-detected {
  border-color: var(--terracotta);
  box-shadow: 0 18px 50px -20px rgba(216, 90, 48, 0.22);
}
.dl-card__highlight {
  display: none;
  position: absolute;
  top: -12px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--navy);
  color: var(--cream);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 5px 12px;
  border-radius: 999px;
}
.dl-card.is-detected .dl-card__highlight { display: inline-block; }

.dl-card__icon {
  width: 64px;
  height: 64px;
  margin: 0 auto 18px;
  color: var(--navy);
  display: flex;
  align-items: center;
  justify-content: center;
}
.dl-card__icon svg { width: 100%; height: 100%; }
.dl-card h3 { margin-bottom: 18px; font-size: 22px; }
.dl-card__meta {
  font-family: var(--font-mono);
  font-size: 13px;
  color: var(--muted);
  margin: 14px 0 4px;
}
.dl-card__req {
  font-size: 13px;
  color: var(--muted);
  margin: 0;
}
.dl-card__waitlist {
  display: block;
  margin-top: 10px;
  font-size: 13px;
  color: var(--terracotta);
}

/* 11. CONTACT ================================================ */
.contact {
  background: var(--page-bg);
}
.contact__grid {
  display: grid;
  grid-template-columns: 1fr 1.4fr;
  gap: 48px;
  max-width: 980px;
  margin: 0 auto;
  align-items: start;
}
.contact__info h3 { font-size: 22px; }
.contact__info p { font-size: 16px; }
.contact__info a {
  font-family: var(--font-mono);
  font-size: 15px;
}

.contact__form-wrap {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 32px;
}
.field { margin-bottom: 18px; }
.field label {
  display: block;
  font-size: 14px;
  font-weight: 600;
  color: var(--navy);
  margin-bottom: 6px;
}
.field input,
.field select,
.field textarea {
  width: 100%;
  padding: 12px 14px;
  border: 1.5px solid var(--border);
  border-radius: 10px;
  font: inherit;
  font-size: 15px;
  color: var(--navy);
  background: var(--page-bg);
  transition: border-color .15s var(--ease), background-color .15s var(--ease);
  font-family: var(--font-sans);
}
.field input:focus,
.field select:focus,
.field textarea:focus {
  outline: none;
  border-color: var(--terracotta);
  background: #fff;
}
.field textarea { resize: vertical; min-height: 120px; }
.field--error input,
.field--error select,
.field--error textarea {
  border-color: #c9442b;
  background: #fff7f4;
}
.field__hint {
  font-size: 12px;
  color: var(--muted);
  margin: 6px 0 0;
}

.contact__thanks {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 48px 32px;
  text-align: center;
}
.contact__thanks h3 { margin-bottom: 8px; }
.contact__thanks p { color: var(--muted); margin: 0; }

/* 12. FOOTER ================================================= */
.footer {
  background: var(--navy);
  color: var(--cream);
  padding: 64px 0 0;
}
.footer a { color: var(--cream); opacity: 0.75; }
.footer a:hover { opacity: 1; color: var(--cream); }

.footer__inner {
  display: grid;
  grid-template-columns: 1.2fr 2fr;
  gap: 48px;
}
.footer__logo {
  height: 32px;
  /* Invert navy logo so cream shows on navy bg */
  filter: brightness(0) invert(0.95);
  margin-bottom: 12px;
}
.footer__logo-fallback {
  display: inline-block;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 22px;
  color: var(--cream);
  margin-bottom: 12px;
}
.footer__tag {
  color: var(--cream);
  opacity: 0.7;
  font-size: 15px;
  margin: 0;
}

.footer__cols {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}
.footer__col h4 {
  color: var(--cream);
  opacity: 0.9;
  margin-bottom: 16px;
  font-size: 12px;
}
.footer__col ul li {
  margin-bottom: 10px;
  font-size: 15px;
}

.footer__bottom {
  margin-top: 56px;
  border-top: 1px solid rgba(245, 239, 224, 0.12);
  padding: 24px 0;
}
.footer__bottom-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 13px;
  color: var(--cream);
  opacity: 0.7;
}

/* 12b. DOWNLOAD GATE MODAL =================================== */
.modal {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}
.modal[hidden] { display: none; }
.modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(26, 41, 66, 0.55);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  animation: modal-fade .2s var(--ease);
}
.modal__panel {
  position: relative;
  background: #fff;
  border-radius: var(--radius-lg);
  width: 100%;
  max-width: 460px;
  padding: 36px 32px 28px;
  box-shadow: 0 30px 80px -20px rgba(26, 41, 66, 0.35);
  animation: modal-pop .25s var(--ease);
  max-height: calc(100vh - 40px);
  overflow-y: auto;
}
.modal__close {
  position: absolute;
  top: 10px;
  right: 12px;
  width: 36px;
  height: 36px;
  border: 0;
  background: transparent;
  color: var(--muted);
  font-size: 28px;
  line-height: 1;
  border-radius: 8px;
  cursor: pointer;
  transition: background-color .15s var(--ease), color .15s var(--ease);
}
.modal__close:hover {
  background: var(--cream);
  color: var(--navy);
}
.modal__panel h3 {
  font-size: 22px;
  margin: 0 0 8px;
  line-height: 1.25;
}
.modal__sub {
  color: var(--muted);
  font-size: 14px;
  margin: 0 0 20px;
  line-height: 1.55;
}
.modal__form .field { margin-bottom: 14px; }
.modal__form .btn { margin-top: 6px; }
.modal__fine {
  font-size: 11.5px;
  color: var(--muted);
  margin: 12px 0 0;
  text-align: center;
  line-height: 1.5;
}

.modal__body--success { text-align: center; }
.modal__success-icon {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: var(--cream);
  color: var(--terracotta);
  margin: 4px auto 16px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.modal__success-icon svg { width: 30px; height: 30px; }
.modal__body--success .btn { margin-top: 22px; }

body.is-modal-open { overflow: hidden; }

@keyframes modal-fade {
  from { opacity: 0; }
  to   { opacity: 1; }
}
@keyframes modal-pop {
  from { opacity: 0; transform: translateY(8px) scale(0.98); }
  to   { opacity: 1; transform: none; }
}
@media (prefers-reduced-motion: reduce) {
  .modal__backdrop, .modal__panel { animation: none; }
}

/* 12c. DOCS PAGE ============================================= */
/* Only loaded when body.docs-page is present, but rules are
   scoped so they don't leak onto index.html either way.       */

.docs-hero {
  background: linear-gradient(180deg, var(--cream) 0%, var(--page-bg) 100%);
  padding: 72px 0 56px;
  border-bottom: 1px solid var(--border);
}
.docs-hero h1 {
  margin: 6px 0 14px;
  font-size: clamp(34px, 5vw, 54px);
}
.docs-hero__sub {
  color: var(--muted);
  font-size: 18px;
  max-width: 680px;
  margin: 0;
}

.docs { padding: 56px 0 96px; }
.docs__layout {
  display: grid;
  grid-template-columns: 240px minmax(0, 1fr);
  gap: 64px;
  align-items: start;
}

/* Sidebar (desktop) */
.docs__sidebar {
  position: sticky;
  top: 96px;
  max-height: calc(100vh - 120px);
  overflow-y: auto;
  padding-right: 8px;
}
.docs__toc-eyebrow {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
  margin: 0 0 14px;
}
.docs__toc ol {
  list-style: none;
  padding: 0;
  margin: 0;
  counter-reset: docs-toc;
}
.docs__toc li { counter-increment: docs-toc; }
.docs__toc li a {
  display: block;
  position: relative;
  padding: 7px 12px 7px 18px;
  margin-left: -12px;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.45;
  border-left: 2px solid transparent;
  border-radius: 0 6px 6px 0;
  transition: color .15s var(--ease), background-color .15s var(--ease), border-color .15s var(--ease);
}
.docs__toc li a:hover {
  color: var(--navy);
  background: rgba(245, 239, 224, 0.6);
}
.docs__toc li a.is-active {
  color: var(--terracotta);
  border-left-color: var(--terracotta);
  font-weight: 600;
  background: rgba(245, 239, 224, 0.8);
}
.docs__toc-cta {
  margin-top: 28px;
  padding: 18px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: #fff;
  text-align: center;
}
.docs__toc-cta p {
  margin: 0 0 10px;
  font-size: 14px;
  color: var(--muted);
}

/* Mobile TOC dropdown */
.docs__mobile-toc {
  display: none;
  margin-bottom: 28px;
  grid-column: 1 / -1;
  position: sticky;
  top: 72px;
  z-index: 5;
  background: var(--page-bg);
  padding: 14px 0;
  margin-top: -14px;
  border-bottom: 1px solid var(--border);
}
.docs__mobile-toc-label {
  display: block;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 6px;
}
.docs__mobile-toc-select {
  width: 100%;
  padding: 12px 14px;
  font: inherit;
  font-size: 15px;
  background: #fff;
  border: 1.5px solid var(--border);
  border-radius: 10px;
  color: var(--navy);
}
.docs__mobile-toc-select:focus {
  outline: none;
  border-color: var(--terracotta);
}

/* Content prose */
.docs__content { max-width: 760px; }
.docs__section {
  padding-top: 32px;
  scroll-margin-top: 96px; /* anchor offset under sticky nav */
}
.docs__section + .docs__section {
  border-top: 1px solid var(--border);
  margin-top: 48px;
}
.docs__section h2 {
  position: relative;
  font-size: clamp(26px, 3vw, 34px);
  margin: 0 0 16px;
  padding-left: 18px;
}
.docs__section h2::before {
  content: '';
  position: absolute;
  left: 0;
  top: 4px;
  bottom: 10px;
  width: 4px;
  border-radius: 2px;
  background: var(--terracotta);
}
.docs__section h3 {
  font-size: 17px;
  text-transform: none;
  letter-spacing: -0.005em;
  margin: 28px 0 10px;
  color: var(--navy);
}
.docs__content p {
  font-size: 16px;
  line-height: 1.7;
  color: var(--navy);
  margin: 0 0 14px;
}
.docs__content ul,
.docs__content ol {
  margin: 0 0 16px;
  padding-left: 22px;
}
.docs__content ul { list-style: disc; }
.docs__content ol { list-style: decimal; }
.docs__content li {
  margin-bottom: 8px;
  line-height: 1.65;
  color: var(--navy);
}
.docs__content li::marker { color: var(--terracotta); }
.docs__content a:not(.btn) {
  color: var(--terracotta);
  text-decoration: underline;
  text-decoration-color: rgba(216, 90, 48, 0.35);
  text-underline-offset: 3px;
}
.docs__content a:not(.btn):hover {
  text-decoration-color: var(--terracotta);
}
/* Make sure .btn links keep their button colours inside docs prose */
.docs__content a.btn { text-decoration: none; }
.docs__content a.btn--primary { color: var(--cream); }
.docs__content a.btn--primary:hover { color: var(--cream); }
.docs__content code {
  font-family: var(--font-mono);
  font-size: 0.88em;
  background: var(--cream);
  color: var(--navy);
  padding: 2px 6px;
  border-radius: 5px;
}
.docs__content strong { color: var(--navy); }

/* Callouts (tips inline within sections) */
.docs__callout {
  margin: 20px 0;
  padding: 16px 18px;
  background: var(--cream);
  border-left: 3px solid var(--terracotta);
  border-radius: 0 10px 10px 0;
  font-size: 15px;
  line-height: 1.6;
  color: var(--navy);
}
.docs__callout strong { color: var(--navy); }

/* Note */
.docs__note {
  font-size: 14px;
  color: var(--muted);
  font-style: italic;
}

/* Troubleshooting cards */
.trouble-card {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 18px 22px;
  margin-bottom: 14px;
  transition: border-color .15s var(--ease), box-shadow .15s var(--ease);
}
.trouble-card:hover {
  border-color: rgba(216, 90, 48, 0.35);
  box-shadow: 0 6px 18px -10px rgba(26, 41, 66, 0.12);
}
.trouble-card__problem {
  margin: 0 0 8px;
  font-weight: 600;
  color: var(--terracotta);
  font-size: 15px;
}
.trouble-card p:last-child { margin-bottom: 0; }

/* Tips list — bigger, more spacious */
.tips-list {
  list-style: none !important;
  padding: 0 !important;
  margin: 8px 0 0 !important;
}
.tips-list li {
  position: relative;
  padding: 14px 16px 14px 44px;
  background: var(--cream);
  border-radius: var(--radius);
  margin-bottom: 10px;
  line-height: 1.6;
}
.tips-list li::before {
  content: '';
  position: absolute;
  left: 16px;
  top: 22px;
  width: 14px;
  height: 14px;
  border-radius: 4px;
  background: var(--terracotta);
  background-image: linear-gradient(135deg, var(--terracotta), var(--terracotta-dark));
}
.tips-list li::after {
  content: '';
  position: absolute;
  left: 19px;
  top: 26px;
  width: 8px;
  height: 4px;
  border-left: 2px solid #fff;
  border-bottom: 2px solid #fff;
  transform: rotate(-45deg);
}

/* Pseudo-table for export formats */
.docs__table {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  margin: 0 0 16px;
  background: #fff;
}
.docs__row {
  display: grid;
  grid-template-columns: 180px 1fr;
  gap: 16px;
  padding: 14px 18px;
  border-bottom: 1px solid var(--border);
  font-size: 15px;
  line-height: 1.55;
}
.docs__row:last-child { border-bottom: 0; }
.docs__row--head {
  background: var(--cream);
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--muted);
}

.docs__numbered { padding-left: 22px; }

/* End-of-docs CTA */
.docs__end {
  margin-top: 64px;
  padding: 32px;
  background: var(--cream);
  border-radius: var(--radius-lg);
  text-align: center;
}
.docs__end h3 {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 22px;
  margin: 0 0 6px;
  text-transform: none;
  letter-spacing: -0.01em;
}
.docs__end p {
  color: var(--muted);
  margin: 0 0 20px;
}

/* Back-to-top button */
.back-to-top {
  position: fixed;
  bottom: 24px;
  right: 24px;
  width: 44px;
  height: 44px;
  border: 0;
  border-radius: 50%;
  background: var(--navy);
  color: var(--cream);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 40;
  box-shadow: 0 10px 24px -8px rgba(26, 41, 66, 0.35);
  opacity: 0;
  transform: translateY(8px);
  transition: opacity .25s var(--ease), transform .25s var(--ease), background-color .15s var(--ease);
}
.back-to-top[hidden] { display: none; }
.back-to-top.is-visible {
  opacity: 1;
  transform: none;
}
.back-to-top:hover {
  background: var(--terracotta);
}
.back-to-top svg { width: 18px; height: 18px; }

/* 13. RESPONSIVE ============================================= */
@media (max-width: 960px) {
  section { padding: 72px 0; }
  .hero__inner {
    grid-template-columns: 1fr;
    gap: 48px;
  }
  .hero__visual { order: -1; }
  .features__grid,
  .proof__grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .footer__inner {
    grid-template-columns: 1fr;
    gap: 32px;
  }
}

@media (max-width: 768px) {
  body { font-size: 16px; }
  section { padding: 56px 0; }
  .container { padding: 0 20px; }

  .nav__links {
    position: fixed;
    top: 72px;
    left: 0;
    right: 0;
    background: var(--page-bg);
    border-top: 1px solid var(--border);
    flex-direction: column;
    align-items: stretch;
    padding: 24px;
    gap: 8px;
    transform: translateY(-120%);
    transition: transform .25s var(--ease);
    box-shadow: 0 14px 30px -10px rgba(26, 41, 66, 0.1);
  }
  .nav__links.is-open { transform: translateY(0); }
  .nav__links a { padding: 12px 4px; font-size: 16px; }
  .nav__links a.btn { margin-top: 12px; justify-content: center; }
  .nav__toggle { display: inline-flex; }

  .hero { padding: 56px 0 64px; }
  .hero__sub { font-size: 17px; }
  .hero__ctas .btn { flex: 1; }

  .features__grid,
  .proof__grid,
  .pricing__grid,
  .download__grid {
    grid-template-columns: 1fr;
  }
  .feature-card { padding: 28px 24px; }

  .contact__grid {
    grid-template-columns: 1fr;
    gap: 32px;
  }
  .contact__form-wrap { padding: 24px; }

  .footer__cols {
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
  }
  .footer__bottom-inner {
    flex-direction: column;
    gap: 8px;
    text-align: center;
  }

  .section-head { margin-bottom: 40px; }
}

@media (max-width: 480px) {
  h1 { font-size: 38px; }
  h2 { font-size: 28px; }
  .hero__ctas { flex-direction: column; }
  .hero__ctas .btn { width: 100%; }
  .footer__cols {
    grid-template-columns: 1fr 1fr;
  }
}

/* Docs page — responsive ===================================== */
@media (max-width: 960px) {
  .docs__layout {
    grid-template-columns: 1fr;
    gap: 0;
  }
  .docs__sidebar { display: none; }
  .docs__mobile-toc { display: block; }
  .docs-hero { padding: 56px 0 40px; }
  .docs { padding: 24px 0 80px; }
}
@media (max-width: 768px) {
  .docs__row {
    grid-template-columns: 1fr;
    gap: 4px;
  }
  .docs__row--head { display: none; }
  .docs__section h2 { font-size: 24px; padding-left: 14px; }
  .docs__section h2::before { width: 3px; }
  .back-to-top { bottom: 16px; right: 16px; }
}
