/* Self-hosted fonts (no third-party requests) */
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('/fonts/inter-400.woff2') format('woff2');
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url('/fonts/inter-500.woff2') format('woff2');
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url('/fonts/inter-600.woff2') format('woff2');
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url('/fonts/inter-700.woff2') format('woff2');
}
@font-face {
  font-family: 'Fraunces';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('/fonts/fraunces-400.woff2') format('woff2');
}
@font-face {
  font-family: 'Fraunces';
  font-style: italic;
  font-weight: 500;
  font-display: swap;
  src: url('/fonts/fraunces-500-italic.woff2') format('woff2');
}
@font-face {
  font-family: 'Fraunces';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url('/fonts/fraunces-600.woff2') format('woff2');
}
@font-face {
  font-family: 'IBM Plex Mono';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('/fonts/ibm-plex-mono-400.woff2') format('woff2');
}
@font-face {
  font-family: 'IBM Plex Mono';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url('/fonts/ibm-plex-mono-500.woff2') format('woff2');
}
@font-face {
  font-family: 'IBM Plex Mono';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url('/fonts/ibm-plex-mono-600.woff2') format('woff2');
}

/* Shared chrome — palette + header/footer (mirrored from docracy.io structure) */

:root {
  /* Docstoc palette: Docstoc-style — dark charcoal primary + orange accent + white/light-gray background */
  --ink: #262626;
  --accent: #F58025;
  --paper: #F7F7F7;
  --white: #FFFFFF;

  /* Marketing chrome — dark charcoal header/footer/hero, orange pops as the accent on top */
  --header-bg: #262626;
  --hero-from: #333333;
  --hero-to: #1A1A1A;
  --on-orange: #FFFFFF;

  /* Signal CTA — orange is the button color per the Docstoc-style guide (was mint on the old orange chrome) */
  --signal: #F58025;
  --signal-hover: #FF9A47;
  --on-signal: #FFFFFF;

  --ink-soft: color-mix(in srgb, var(--ink) 58%, var(--white));
  --line: color-mix(in srgb, var(--ink) 12%, var(--white));
  --paper-deep: color-mix(in srgb, var(--accent) 4%, var(--paper));
  --accent-soft: color-mix(in srgb, var(--accent) 16%, var(--white));

  --sage: color-mix(in srgb, var(--ink) 70%, var(--white));
  --sage-bg: color-mix(in srgb, var(--accent) 6%, var(--white));
  --amber: color-mix(in srgb, var(--accent) 78%, var(--ink));
  --amber-bg: color-mix(in srgb, var(--accent) 14%, var(--white));
  --rust: var(--accent);
  --rust-bg: var(--accent-soft);
}

* { box-sizing: border-box; margin: 0; padding: 0; }

body {
  background: var(--paper);
  color: var(--ink);
  font-family: 'Inter', sans-serif;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; }

.wrap {
  max-width: 1080px;
  margin: 0 auto;
  padding: 0 28px;
}

/* ---------- HEADER (deep Docstoc orange — Docracy layout, orange palette) ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--header-bg);
  border-bottom: 1px solid rgba(255, 255, 255, 0.12);
}

.site-header-inner {
  display: flex;
  align-items: center;
  gap: 16px;
  max-width: none;
  margin: 0;
  padding: 16px 32px;
  position: relative;
}

.logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  flex-shrink: 0;
  line-height: 0;
  color: #fff;
}
.logo-mark {
  width: 28px;
  height: 28px;
  display: block;
  flex-shrink: 0;
}
.logo-word {
  font-family: 'Inter', system-ui, sans-serif;
  font-weight: 700;
  font-size: 22px;
  letter-spacing: -0.03em;
  line-height: 1;
  color: #fff;
}
.logo-group {
  display: inline-flex;
  flex-direction: column;
  gap: 3px;
  flex-shrink: 0;
}
.logo-tagline {
  font-family: 'Inter', system-ui, sans-serif;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.5);
  white-space: nowrap;
}
.site-footer-brand .logo-tagline { color: var(--ink-soft); }
.site-footer-brand .logo-word {
  color: #fff;
  font-size: 20px;
}
.site-footer-brand .logo-mark {
  width: 24px;
  height: 24px;
}
/* legacy img logos (if any remain) */
.logo img:not(.logo-mark) {
  height: 36px;
  width: auto;
  display: block;
}

.header-nav-right {
  margin-left: 48px;
  display: flex;
  align-items: center;
  flex: 1;
  flex-wrap: nowrap;
  min-width: 0;
}

/* LimeWire pattern: a small, loosely-spaced nav cluster sits right after the logo; the
   badge/CTA/account cluster is pushed to the far right by margin-left: auto on its own wrapper,
   rather than every item being crammed together with justify-content: flex-end. */
.header-nav-links {
  display: flex;
  align-items: center;
  gap: 30px;
  min-width: 0;
}
.header-nav-actions {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: nowrap;
  flex-shrink: 0;
  justify-content: flex-end;
}

.header-nav-link {
  font-size: 14px;
  font-weight: 500;
  color: #fff;
  text-decoration: none;
  opacity: 0.88;
  padding: 6px 2px;
  border-bottom: 2px solid transparent;
  transition: opacity 0.15s ease, border-color 0.15s ease;
}
.header-nav-link:hover {
  opacity: 1;
  border-bottom-color: rgba(255, 255, 255, 0.55);
}

.locale-switch {
  position: relative;
  display: inline-flex;
  align-items: center;
}
.locale-switch-trigger {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  border: none;
  background: transparent;
  color: #fff;
  font: inherit;
  font-family: 'Inter', sans-serif;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.02em;
  padding: 4px 2px;
  cursor: pointer;
  opacity: 0.82;
}
.locale-switch-trigger:hover,
.locale-switch.is-open .locale-switch-trigger { opacity: 1; }
.locale-switch-globe { display: block; flex-shrink: 0; }
.locale-switch-code { line-height: 1; }
.locale-switch-chevron { display: block; flex-shrink: 0; opacity: 0.7; transition: transform 0.15s ease; }
.locale-switch-chevron.is-open { transform: rotate(180deg); }
.locale-switch-menu {
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  z-index: 200;
  min-width: 150px;
  margin: 0;
  padding: 6px;
  list-style: none;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fff;
  box-shadow: 0 8px 24px rgba(42, 20, 16, 0.18);
}
.locale-switch-menu[hidden] { display: none; }
.locale-switch-option {
  display: flex;
  align-items: baseline;
  gap: 10px;
  width: 100%;
  border: none;
  background: transparent;
  color: var(--ink);
  font: inherit;
  font-family: 'Inter', sans-serif;
  font-size: 13px;
  text-align: left;
  padding: 8px 10px;
  border-radius: 7px;
  cursor: pointer;
}
.locale-switch-option:hover,
.locale-switch-option.is-active {
  background: var(--accent-soft);
  color: var(--ink);
}
.locale-switch-option-code { font-weight: 700; letter-spacing: 0.04em; min-width: 1.6em; color: inherit; }
.locale-switch-option-name { opacity: 0.78; font-weight: 500; color: inherit; }

/* ---------- Header mega-menus (Docracy pattern: icon + title + desc grid) ---------- */
.nav-megamenu { position: relative; display: inline-flex; }
.nav-megamenu-trigger {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  background: none;
  border: none;
  /* `.header-nav-link` (also on this element) sets font-size/weight/color — `font: inherit`
     here would reset those to the button's own inherited default and silently override it. */
  font-family: 'Inter', sans-serif;
  font-size: 14px;
  font-weight: 500;
  color: #fff;
  opacity: 0.88;
  cursor: pointer;
}
.nav-megamenu-trigger:hover { opacity: 1; }
.nav-megamenu-chevron { transition: transform 0.15s ease; opacity: 0.75; }
.nav-megamenu-chevron.is-open { transform: rotate(180deg); }
.nav-megamenu-panel {
  position: absolute;
  top: calc(100% + 16px);
  left: 50%;
  transform: translateX(-50%);
  z-index: 150;
  background: #fff;
  color: var(--ink);
  border-radius: 16px;
  box-shadow: 0 20px 48px rgba(42, 20, 16, 0.22);
  padding: 20px;
  display: flex;
  gap: 24px;
  width: max-content;
  max-width: 92vw;
}
.nav-megamenu-panel[hidden] { display: none; }

/* LimeWire-style simple list: bold title + chevron, no icon/description, generous spacing */
.nav-megamenu-panel-simple {
  padding: 28px 32px;
  border-radius: 24px;
}
.nav-simplemenu-list {
  display: flex;
  flex-direction: column;
  width: 260px;
}
.nav-simplemenu-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 16px 4px;
  text-decoration: none;
  border-bottom: 1px solid var(--line);
}
.nav-simplemenu-item:last-child { border-bottom: none; }
.nav-simplemenu-item-title {
  font-weight: 700;
  font-size: 18px;
  color: var(--ink);
}
.nav-simplemenu-item-chevron {
  flex-shrink: 0;
  color: var(--ink-soft);
  transition: transform 0.15s ease;
}
.nav-simplemenu-item:hover .nav-simplemenu-item-title { color: var(--accent); }
.nav-simplemenu-item:hover .nav-simplemenu-item-chevron { transform: translateX(3px); color: var(--accent); }

.nav-megamenu-grid { display: grid; gap: 2px 24px; }
.nav-megamenu-item {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 10px;
  border-radius: 10px;
  text-decoration: none;
  color: var(--ink);
  width: 216px;
}
.nav-megamenu-item:hover { background: var(--paper-deep); }
.nav-megamenu-icon {
  flex-shrink: 0;
  width: 34px;
  height: 34px;
  border-radius: 9px;
  background: var(--accent-soft);
  color: var(--accent);
  display: flex;
  align-items: center;
  justify-content: center;
}
.nav-megamenu-icon-sm { width: 28px; height: 28px; border-radius: 8px; }
.nav-megamenu-icon-lg {
  width: 46px;
  height: 46px;
  border-radius: 12px;
  background: var(--accent);
  color: #fff;
  box-shadow: 0 6px 16px rgba(245, 128, 37, 0.3);
}
.nav-megamenu-item-lg { width: 250px; padding: 12px; gap: 14px; }
.nav-megamenu-item-lg .nav-megamenu-item-title { font-size: 14.5px; }
.nav-megamenu-item-lg .nav-megamenu-item-desc { font-size: 12.5px; }
.nav-megamenu-item-title { display: block; font-weight: 700; font-size: 13.5px; color: var(--ink); }
.nav-megamenu-item-desc { display: block; font-size: 12px; color: var(--ink-soft); margin-top: 2px; line-height: 1.4; }
.nav-megamenu-side {
  border-left: 1px solid var(--line);
  padding-left: 24px;
  width: 190px;
  flex-shrink: 0;
}
.nav-megamenu-side h4 {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--ink-soft);
  margin-bottom: 8px;
  padding: 0 6px;
}
.nav-megamenu-side-item { padding: 8px 6px; width: auto; }
.nav-megamenu-side-footer {
  display: block;
  margin-top: 4px;
  padding: 8px 6px;
  font-size: 12.5px;
  font-weight: 700;
  color: var(--accent);
  text-decoration: none;
}
.nav-megamenu-side-footer:hover { text-decoration: underline; }

@media (max-width: 900px) {
  .nav-megamenu-panel { left: auto; right: 0; transform: none; }
}

.header-nav-strong {
  font-weight: 700;
  opacity: 1;
}

.header-nav-sales {
  display: inline-flex;
  align-items: center;
  padding: 10px 16px;
  border-radius: 999px;
  background: #fff;
  color: var(--accent);
  font-size: 13.5px;
  font-weight: 700;
  text-decoration: none;
  white-space: nowrap;
  flex-shrink: 0;
}
.header-nav-sales:hover { background: #fff5f0; }

.header-revival-badge {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  z-index: 2;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 5px 10px 5px 5px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.18);
  color: #fff;
  font: inherit;
  text-decoration: none;
  white-space: nowrap;
  flex-shrink: 0;
  cursor: pointer;
  transition: background 0.15s ease, border-color 0.15s ease, transform 0.15s ease;
}
.header-revival-badge:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.28);
  transform: translate(-50%, calc(-50% - 1px));
}
.header-revival-badge-thumb {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: #f4f1ec url("/brand/docstoc-old-logo-small.jpg") center / 160% no-repeat;
  flex-shrink: 0;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.25);
}
.header-revival-badge-text {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0;
  line-height: 1.15;
}
.header-revival-badge-title {
  font-size: 12.5px;
  font-weight: 800;
  color: #fff;
}
.header-revival-badge-sub {
  font-size: 10px;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.55);
}
.header-revival-badge-play {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: var(--accent);
  flex-shrink: 0;
  margin-left: 2px;
}
.header-revival-badge-play svg {
  width: 8px;
  height: 8px;
}
@media (max-width: 1100px) {
  .header-revival-badge-sub { display: none; }
}

/* Shared video modal (how-it-works / docstoc-is-back) */
.how-modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 1200;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background: rgba(6, 16, 32, 0.78);
}
.how-modal-backdrop.is-open { display: flex; }
.how-modal-backdrop[hidden] { display: none !important; }
.how-modal {
  position: relative;
  width: min(940px, 100%);
  background: #0b0b0b;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.45);
}
.how-modal-close {
  position: absolute;
  top: 10px;
  right: 12px;
  z-index: 2;
  width: 36px;
  height: 36px;
  border: 0;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.55);
  color: #fff;
  font-size: 22px;
  line-height: 1;
  cursor: pointer;
}
.how-modal-close:hover { background: rgba(0, 0, 0, 0.75); }
.how-modal-video {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  background: #000;
}
.header-login-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 9px 16px;
  border-radius: 999px;
  border: 1.5px solid rgba(255, 255, 255, 0.7);
  color: #fff;
  font-size: 13.5px;
  font-weight: 650;
  text-decoration: none;
  background: transparent;
  white-space: nowrap;
  flex-shrink: 0;
}
.header-login-btn:hover {
  background: rgba(255, 255, 255, 0.12);
  border-color: #fff;
}

.nav-cta {
  font-family: 'Inter', sans-serif;
  font-size: 13.5px;
  font-weight: 700;
  color: var(--on-signal);
  background: var(--signal);
  border: 1.5px solid var(--signal);
  padding: 10px 18px;
  border-radius: 999px;
  text-decoration: none;
  transition: background 0.15s ease, border-color 0.15s ease;
  white-space: nowrap;
  flex-shrink: 0;
}
.nav-cta:hover {
  background: var(--signal-hover);
  border-color: var(--signal-hover);
}

.site-header .nav-cta {
  color: var(--on-signal);
  background: var(--signal);
  border-color: var(--signal);
}
.site-header .nav-cta:hover {
  background: var(--signal-hover);
  border-color: var(--signal-hover);
}

/* Legacy inline mobile nav — replaced by .mobile-panel; hide if any pages still emit it */
.header-mobile-menu {
  display: none !important;
}

.header-menu-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 4px;
  width: 36px;
  height: 36px;
  padding: 0;
  background: none;
  border: none;
  border-radius: 4px;
  cursor: pointer;
}
.header-menu-toggle span {
  display: block;
  width: 18px;
  height: 2px;
  background: #fff;
  border-radius: 1px;
}

/* Slide-in mobile panel — Swipesign style */
.mobile-panel-backdrop {
  display: none;
  position: fixed;
  inset: 0;
  /* Above cookie banner (9999) and assistant FAB (99999) so Sign in stays tappable */
  z-index: 100050;
  background: rgba(0, 0, 0, 0.4);
}
.mobile-panel {
  display: none;
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  width: min(320px, 88vw);
  z-index: 100060;
  background: var(--white);
  box-shadow: -8px 0 40px rgba(0, 0, 0, 0.16);
  flex-direction: column;
  padding: 24px 28px 40px;
  transform: translateX(100%);
  transition: transform 0.28s cubic-bezier(0.4, 0, 0.2, 1);
}
/* Hide chat FAB while the drawer is open — it sat on top of Sign in / Try free */
body.mobile-nav-open .docstoc-asst {
  visibility: hidden;
  pointer-events: none;
}
.mobile-panel.is-open {
  transform: translateX(0);
}
.mobile-panel-close {
  align-self: flex-end;
  background: none;
  border: none;
  font-size: 20px;
  color: var(--ink);
  cursor: pointer;
  padding: 4px 6px;
  line-height: 1;
  margin-bottom: 32px;
}
.mobile-panel-nav {
  display: flex;
  flex-direction: column;
  gap: 0;
  flex: 1;
}
.mobile-panel-nav-link {
  display: block;
  padding: 16px 0;
  font-size: 15px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--ink);
  text-decoration: none;
  border-bottom: 1px solid var(--line);
}
.mobile-panel-nav-link:last-child {
  border-bottom: none;
}
.mobile-panel-ctas {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 36px;
}
.mobile-panel-cta-primary {
  display: block;
  text-align: center;
  padding: 14px 20px;
  border-radius: 999px;
  background: var(--signal);
  color: var(--on-signal);
  font-size: 16px;
  font-weight: 700;
  text-decoration: none;
}
.mobile-panel-cta-secondary {
  display: block;
  text-align: center;
  padding: 13px 20px;
  border-radius: 999px;
  border: 1.5px solid var(--accent);
  color: var(--accent);
  font-size: 16px;
  font-weight: 600;
  text-decoration: none;
  background: transparent;
}

/* The full desktop nav stops fitting on one row below ~1200px — collapse to the mobile
   panel earlier instead of wrapping into a broken multi-row header. */
@media (max-width: 1200px) {
  .header-nav-collapse { display: none; }
  .header-menu-toggle { display: inline-flex; }
  .mobile-panel-backdrop.is-open { display: block; }
  .mobile-panel { display: flex; }
  .site-header-inner {
    padding: 12px 16px;
    gap: 10px;
  }
  .header-nav-right {
    margin-left: auto;
    flex: 0 0 auto;
  }
  /* All primary nav links use header-nav-collapse — hide the empty cluster on mobile. */
  .header-nav-links {
    display: none;
  }
  /* After collapse, only locale + Try free + hamburger remain — keep one tight row. */
  .header-nav-actions {
    gap: 8px;
  }
  .logo-word {
    font-size: 18px;
  }
  .site-header .nav-cta {
    padding: 8px 12px;
    font-size: 13px;
  }
  .locale-switch-trigger {
    padding: 6px 8px;
    font-size: 12px;
  }
}

/* ---------- FOOTER ---------- */
.site-footer {
  margin-top: 64px;
  background: var(--header-bg);
  color: color-mix(in srgb, var(--white) 78%, transparent);
  padding: 48px 0 24px;
}

.site-footer-inner {
  display: grid;
  grid-template-columns: 1.2fr repeat(5, 1fr);
  gap: 24px;
}

.site-footer-brand .logo {
  color: var(--white);
  font-size: 20px;
}
.site-footer-brand p {
  font-size: 13px;
  margin: 12px 0 0;
  max-width: 240px;
  opacity: 0.85;
  line-height: 1.5;
}

.site-footer-col {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.site-footer-col h4 {
  color: var(--white);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  margin: 0 0 4px;
  opacity: 0.7;
}
.site-footer-col a {
  color: inherit;
  font-size: 14px;
  text-decoration: none;
  transition: color 0.15s ease;
}
.site-footer-col a:hover { color: var(--white); }

.site-footer-bottom {
  max-width: 1080px;
  margin: 40px auto 0;
  padding: 20px 28px 0;
  border-top: 1px solid color-mix(in srgb, var(--white) 12%, transparent);
  font-size: 12px;
  opacity: 0.7;
}

@media (max-width: 900px) {
  .site-footer-inner { grid-template-columns: repeat(3, 1fr); }
  .site-footer-brand { grid-column: 1 / -1; }
}

@media (max-width: 600px) {
  .site-footer-inner { grid-template-columns: repeat(2, 1fr); }
}

/* ---------- NEXT STEPS SECTION ---------- */
.next-steps-band {
  margin: 64px 0 32px;
  padding: 44px 24px;
  background: color-mix(in srgb, var(--accent) 3%, #ffffff);
  border-top: 1px solid color-mix(in srgb, var(--accent) 15%, transparent);
  border-bottom: 1px solid color-mix(in srgb, var(--accent) 15%, transparent);
}
.next-steps-inner {
  max-width: 1080px;
  margin: 0 auto;
}
.next-steps-title {
  font-family: 'Fraunces', serif;
  font-size: 24px;
  font-weight: 700;
  margin: 0 0 24px;
  color: var(--text-heading, #111827);
}
.next-steps-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 20px;
}
.next-step-card {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 20px;
  background: #ffffff;
  border: 1px solid var(--border, #e5e7eb);
  border-radius: 8px;
  text-decoration: none;
  color: inherit;
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}
.next-step-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(0,0,0,0.06);
  border-color: var(--accent, #f97316);
}
.next-step-card h4 {
  font-size: 16px;
  font-weight: 700;
  color: var(--text-heading, #111827);
  margin: 0 0 8px;
}
.next-step-card p {
  font-size: 13px;
  color: var(--text-muted, #6b7280);
  margin: 0;
  line-height: 1.4;
}
.next-step-primary {
  border-color: var(--accent, #f97316);
  background: linear-gradient(135deg, color-mix(in srgb, var(--accent) 8%, #ffffff) 0%, color-mix(in srgb, var(--accent) 14%, #ffffff) 100%);
}

/* ---------- LEGAL / INNER PAGES ---------- */
.legal-page {
  padding: 48px 0 40px;
  max-width: 720px;
}
.legal-page h1 {
  font-family: 'Fraunces', serif;
  font-weight: 600;
  font-size: clamp(28px, 4vw, 36px);
  margin-bottom: 12px;
  line-height: 1.15;
}
.legal-page .lede {
  font-size: 13px;
  color: var(--ink-soft);
  margin-bottom: 28px;
}
.legal-page h3 {
  font-size: 16px;
  font-weight: 700;
  margin: 28px 0 8px;
}
.legal-page p {
  font-size: 15px;
  color: var(--ink-soft);
  margin-bottom: 12px;
  line-height: 1.6;
}
.legal-page a {
  color: var(--accent);
  font-weight: 600;
  text-decoration: none;
}
.legal-page a:hover { text-decoration: underline; }

/* ---------- DOCS ---------- */
.docs-page { padding-bottom: 60px; }
.docs-page h1 {
  font-family: 'Fraunces', serif;
  font-weight: 600;
  font-size: clamp(28px, 4vw, 36px);
  margin-bottom: 12px;
  line-height: 1.15;
}
.docs-page .lede {
  font-size: 15px;
  color: var(--ink-soft);
  max-width: 640px;
  margin-bottom: 32px;
  line-height: 1.6;
}
.docs-layout {
  display: grid;
  grid-template-columns: 220px 1fr;
  gap: 40px;
  align-items: start;
}
.docs-sidebar {
  position: sticky;
  top: 96px;
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.docs-sidebar a {
  display: block;
  padding: 7px 10px;
  border-radius: 8px;
  font-size: 13.5px;
  font-weight: 600;
  color: var(--ink-soft);
  text-decoration: none;
}
.docs-sidebar a:hover {
  background: var(--paper);
  color: var(--accent);
}
.docs-content { min-width: 0; max-width: 680px; }
.docs-section {
  padding-top: 8px;
  margin-bottom: 40px;
  scroll-margin-top: 90px;
}
.docs-section h2 {
  font-family: 'Fraunces', serif;
  font-weight: 600;
  font-size: 22px;
  margin: 0 0 14px;
  padding-top: 24px;
  border-top: 1px solid var(--line);
}
.docs-section:first-of-type h2 { border-top: 0; padding-top: 0; }
.docs-section h3 {
  font-size: 15px;
  font-weight: 700;
  margin: 20px 0 8px;
}
.docs-section p, .docs-section li {
  font-size: 14.5px;
  color: var(--ink-soft);
  line-height: 1.6;
}
.docs-section ul, .docs-section ol {
  margin: 0 0 14px;
  padding-left: 1.3em;
}
.docs-section code {
  background: var(--paper);
  padding: 2px 6px;
  border-radius: 4px;
  font-family: 'IBM Plex Mono', monospace;
  font-size: 13px;
  color: var(--ink);
}
.docs-section a { color: var(--accent); font-weight: 600; text-decoration: none; }
.docs-section a:hover { text-decoration: underline; }
.docs-section a.nav-cta {
  color: var(--on-signal);
  background: var(--signal);
  border: 1.5px solid var(--signal);
  padding: 10px 18px;
  border-radius: 999px;
  display: inline-block;
  text-decoration: none;
}
.docs-section a.nav-cta:hover {
  background: var(--signal-hover);
  border-color: var(--signal-hover);
  text-decoration: none;
}
@media (max-width: 760px) {
  .docs-layout { grid-template-columns: 1fr; }
  .docs-sidebar {
    position: static;
    flex-direction: row;
    flex-wrap: wrap;
    gap: 6px;
    margin-bottom: 24px;
    padding-bottom: 16px;
    border-bottom: 1px solid var(--line);
  }
  .docs-sidebar a { padding: 6px 10px; background: var(--paper); border-radius: 999px; }
}

/* ---------- BLOG INDEX ---------- */
.blog-hero {
  max-width: 760px;
  margin: 44px auto 48px;
  text-align: center;
}
.blog-hero h1 {
  font-family: 'Fraunces', serif;
  font-weight: 600;
  font-size: clamp(32px, 5vw, 48px);
  line-height: 1.15;
  margin: 0 0 16px;
  background: linear-gradient(135deg, color-mix(in srgb, var(--accent) 45%, var(--white)), var(--accent));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  -webkit-text-fill-color: transparent;
}
.blog-hero .lede {
  font-size: 16px;
  color: var(--ink-soft);
  line-height: 1.6;
  margin: 0 auto;
}

.blog-layout {
  display: grid;
  grid-template-columns: 1fr 300px;
  gap: 28px;
  align-items: start;
}
@media (max-width: 860px) {
  .blog-layout { grid-template-columns: 1fr; }
}

.blog-posts { display: flex; flex-direction: column; gap: 20px; }

.blog-article-main {
  max-width: none;
  width: 100%;
  margin: 0;
  padding: 0;
}

.blog-article-hero {
  background:
    radial-gradient(ellipse 80% 60% at 70% 0%, rgba(255, 255, 255, 0.08), transparent 55%),
    linear-gradient(165deg, #1a1816 0%, #0e0d0c 55%, #161412 100%);
  color: #f4f1ec;
  padding: 48px 0 56px;
}
.blog-article-hero-inner {
  max-width: 720px;
  margin: 0 auto;
  padding: 0 24px;
}
.blog-article-back {
  display: inline-block;
  color: rgba(244, 241, 236, 0.72);
  text-decoration: none;
  font-size: 14px;
  margin-bottom: 22px;
}
.blog-article-back:hover { color: #fff; }
.blog-article-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 10px;
  font-size: 13px;
  letter-spacing: 0.02em;
  color: rgba(244, 241, 236, 0.65);
  margin-bottom: 18px;
}
.blog-article-tag {
  color: #f4f1ec;
  font-weight: 650;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  font-size: 12px;
}
.blog-article-date,
.blog-article-read {
  color: rgba(244, 241, 236, 0.6);
}
.blog-article-read::before {
  content: "·";
  margin-right: 10px;
  color: rgba(244, 241, 236, 0.35);
}
.blog-article-hero h1 {
  margin: 0 0 16px;
  font-size: clamp(28px, 4.2vw, 42px);
  line-height: 1.15;
  letter-spacing: -0.02em;
  color: #fff;
  max-width: 18ch;
}
.blog-article-lede {
  margin: 0;
  font-size: 18px;
  line-height: 1.55;
  color: rgba(244, 241, 236, 0.78);
  max-width: 42em;
}

.blog-article-layout {
  display: grid;
  grid-template-columns: minmax(0, 220px) minmax(0, 720px);
  gap: 40px;
  justify-content: center;
  max-width: 1080px;
  margin: 0 auto;
  padding: 40px 24px 72px;
  align-items: start;
}
.blog-article-aside {
  position: sticky;
  top: 88px;
}
.blog-toc {
  margin: 0;
  padding: 0;
  border: none;
  border-radius: 0;
  background: transparent;
}
.blog-toc-side .blog-toc-title,
.blog-toc-title {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-soft);
  margin-bottom: 12px;
}
.blog-toc ol {
  margin: 0;
  padding-left: 0;
  list-style: none;
  border-left: 1px solid var(--line);
}
.blog-toc li {
  margin: 0;
  font-size: 13px;
  line-height: 1.4;
}
.blog-toc a {
  display: block;
  color: var(--ink-soft);
  text-decoration: none;
  padding: 7px 0 7px 14px;
  border-left: 2px solid transparent;
  margin-left: -1px;
}
.blog-toc a:hover {
  color: var(--ink);
  border-left-color: var(--accent);
}

.blog-article-content {
  min-width: 0;
  font-size: 17px;
  line-height: 1.7;
  color: var(--ink);
}
.blog-article-footer {
  margin-top: 48px;
  padding-top: 28px;
  border-top: 1px solid var(--line);
}
.blog-body h2 {
  font-size: 24px;
  margin-top: 40px;
  margin-bottom: 12px;
  line-height: 1.25;
  letter-spacing: -0.015em;
}
.blog-body h3 {
  font-size: 18px;
  margin-top: 28px;
  margin-bottom: 8px;
}
.blog-body ul { margin: 0 0 1.15em; padding-left: 22px; }
.blog-body ol { margin: 0 0 1.15em; padding-left: 22px; }
.blog-body li { margin-bottom: 6px; }
.blog-body p { margin: 0 0 1.15em; }
.blog-body table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
  line-height: 1.45;
  margin: 0 0 1.25em;
}
.blog-body th,
.blog-body td {
  border: 1px solid var(--line);
  padding: 10px 12px;
  text-align: left;
  vertical-align: top;
}
.blog-body th {
  background: color-mix(in srgb, var(--paper) 70%, var(--white));
  font-weight: 700;
  color: var(--ink);
}
.blog-body tr:nth-child(even) td {
  background: color-mix(in srgb, var(--paper) 35%, var(--white));
}
.blog-body .faq-item {
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 12px 14px;
  margin: 0 0 10px;
  background: var(--white);
}
.blog-body .faq-item summary {
  cursor: pointer;
  font-weight: 650;
  color: var(--ink);
}
.blog-body .faq-item p { margin: 10px 0 0; }

@media (max-width: 900px) {
  .blog-article-layout {
    grid-template-columns: 1fr;
    gap: 28px;
    padding-top: 28px;
  }
  .blog-article-aside {
    position: static;
    order: -1;
  }
  .blog-toc ol {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0 16px;
    border-left: none;
  }
  .blog-toc a {
    border-left: none;
    margin-left: 0;
    padding-left: 0;
  }
  .blog-article-hero h1 { max-width: none; }
}
@media (max-width: 560px) {
  .blog-toc ol { grid-template-columns: 1fr; }
}

.blog-card {
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 26px 28px;
  background: color-mix(in srgb, var(--paper) 45%, var(--white));
  transition: border-color 0.15s ease, transform 0.15s ease;
}
.blog-card:hover {
  border-color: color-mix(in srgb, var(--accent) 40%, var(--line));
  transform: translateY(-1px);
}
.blog-card-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 10px;
}
.blog-card-tag {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--accent);
}
.blog-card-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  font-weight: 600;
  color: var(--ink);
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 4px 12px 4px 8px;
}
.blog-card-badge i {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent);
  display: inline-block;
}
.blog-card h2 {
  font-family: 'Fraunces', serif;
  font-weight: 600;
  font-size: 24px;
  line-height: 1.25;
  margin: 0 0 10px;
}
.blog-card h2 a { text-decoration: none; color: var(--ink); }
.blog-card h2 a:hover { color: var(--accent); }
.blog-card p {
  color: var(--ink-soft);
  font-size: 15px;
  line-height: 1.55;
  margin: 0 0 18px;
}
.blog-read-btn {
  display: inline-block;
  font-family: 'Inter', sans-serif;
  font-size: 14px;
  font-weight: 700;
  color: var(--white);
  background: var(--accent);
  border-radius: 999px;
  padding: 10px 22px;
  text-decoration: none;
  transition: filter 0.15s ease;
}
.blog-read-btn:hover { filter: brightness(0.95); }

.blog-sidebar-cta {
  background: linear-gradient(160deg, var(--ink), color-mix(in srgb, var(--ink) 78%, black));
  color: var(--white);
  border-radius: 16px;
  padding: 28px 24px;
  position: sticky;
  top: 96px;
}
.blog-sidebar-eyebrow {
  display: block;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: color-mix(in srgb, var(--accent) 70%, var(--white));
  margin-bottom: 10px;
}
.blog-sidebar-cta h3 {
  font-family: 'Fraunces', serif;
  font-size: 20px;
  line-height: 1.3;
  margin: 0 0 12px;
}
.blog-sidebar-cta p {
  font-size: 14px;
  line-height: 1.55;
  color: color-mix(in srgb, var(--white) 82%, transparent);
  margin: 0 0 18px;
}
.blog-sidebar-btn {
  display: block;
  text-align: center;
  font-family: 'Inter', sans-serif;
  font-size: 14px;
  font-weight: 700;
  text-decoration: none;
  border-radius: 999px;
  padding: 11px 18px;
  margin-bottom: 10px;
  transition: filter 0.15s ease, opacity 0.15s ease;
}
.blog-sidebar-btn-primary {
  background: var(--accent);
  color: var(--white);
}
.blog-sidebar-btn-primary:hover { filter: brightness(0.95); }
.blog-sidebar-btn-secondary {
  background: transparent;
  color: var(--white);
  border: 1.5px solid color-mix(in srgb, var(--white) 35%, transparent);
}
.blog-sidebar-btn-secondary:hover { border-color: color-mix(in srgb, var(--white) 60%, transparent); }
.blog-sidebar-tip {
  font-size: 12px;
  line-height: 1.55;
  color: color-mix(in srgb, var(--white) 65%, transparent);
  margin: 18px 0 0;
}

/* ---------- FREE TEMPLATES ---------- */
.templates-index, .template-detail {
  padding: 40px 0 60px;
}
.crumb {
  font-size: 13px;
  color: var(--ink-soft);
  margin-bottom: 18px;
}
.crumb a {
  color: var(--ink-soft);
  text-decoration: none;
}
.crumb a:hover { color: var(--accent); }

.templates-index h1, .template-detail h1 {
  font-family: 'Fraunces', serif;
  font-weight: 600;
  font-size: clamp(28px, 4vw, 40px);
  line-height: 1.15;
  margin-bottom: 14px;
}
.templates-index .lede, .template-detail .lede {
  font-size: 16px;
  color: var(--ink-soft);
  max-width: 640px;
  margin-bottom: 32px;
  line-height: 1.6;
}
.templates-index .lede a, .template-detail .lede a {
  color: var(--accent);
  font-weight: 600;
  text-decoration: none;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* ---------- TEMPLATES HERO + CATEGORIES ---------- */
.tpl-hero {
  background: radial-gradient(120% 140% at 20% 0%, color-mix(in srgb, var(--accent) 55%, var(--ink) 10%), var(--ink) 65%);
  padding: 56px 0 44px;
  margin-bottom: 32px;
  /* Full-bleed: this section sits inside <main class="wrap page-main"> (max-width: 1080px), so
     without this it gets capped and padded like the rest of the page content. The banner should
     stretch edge-to-edge on wide screens while .tpl-hero-inner (its own "wrap" class) still
     centers the actual text/search box at a readable width. */
  width: 100vw;
  position: relative;
  left: 50%;
  margin-left: -50vw;
}
.tpl-hero-inner {
  max-width: 760px;
  text-align: center;
}
.tpl-hero h1 {
  font-family: 'Fraunces', serif;
  font-weight: 600;
  font-size: clamp(28px, 4.4vw, 42px);
  line-height: 1.18;
  color: var(--white);
  margin: 0 0 14px;
}
.tpl-hero-lede {
  font-size: 16px;
  line-height: 1.55;
  color: color-mix(in srgb, var(--white) 82%, transparent);
  margin: 0 0 28px;
}
.tpl-hero-search {
  display: flex;
  align-items: center;
  gap: 10px;
  background: var(--white);
  border: 2px solid color-mix(in srgb, var(--accent) 70%, var(--white));
  border-radius: 999px;
  padding: 14px 22px;
  max-width: 560px;
  margin: 0 auto;
  box-shadow: 0 12px 30px color-mix(in srgb, black 20%, transparent);
}
.tpl-hero-search svg {
  width: 18px;
  height: 18px;
  color: var(--ink-soft);
  flex-shrink: 0;
}
.tpl-hero-search input {
  flex: 1;
  border: 0;
  outline: 0;
  font-family: 'Inter', sans-serif;
  font-size: 15px;
  color: var(--ink);
  background: transparent;
}
.tpl-hero-search input::placeholder { color: var(--ink-soft); }

.tpl-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 20px;
}
.tpl-toolbar-count {
  font-size: 13px;
  font-weight: 600;
  color: var(--ink-soft);
}
.tpl-cat-dropdown { position: relative; }
.tpl-cat-dropdown-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: 'Inter', sans-serif;
  font-size: 14px;
  font-weight: 600;
  color: var(--ink);
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 9px 18px;
  cursor: pointer;
  transition: border-color 0.15s ease;
}
.tpl-cat-dropdown-btn:hover { border-color: var(--accent); }
.tpl-cat-dropdown.is-open .tpl-cat-dropdown-btn {
  border-color: var(--accent);
  color: var(--accent);
}
.tpl-cat-dropdown-chevron {
  width: 10px;
  height: 7px;
  transition: transform 0.18s ease;
}
.tpl-cat-dropdown.is-open .tpl-cat-dropdown-chevron { transform: rotate(180deg); }

.tpl-cat-dropdown-menu {
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  min-width: 220px;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 12px;
  box-shadow: 0 16px 36px color-mix(in srgb, var(--ink) 18%, transparent);
  padding: 8px;
  z-index: 20;
  opacity: 0;
  transform: translateY(-6px) scale(0.98);
  transform-origin: top right;
  transition: opacity 0.15s ease, transform 0.15s ease;
  pointer-events: none;
}
.tpl-cat-dropdown.is-open .tpl-cat-dropdown-menu {
  opacity: 1;
  transform: translateY(0) scale(1);
  pointer-events: auto;
}
.tpl-cat-dropdown-item {
  display: block;
  font-family: 'Inter', sans-serif;
  font-size: 14px;
  font-weight: 600;
  color: var(--ink);
  text-decoration: none;
  padding: 10px 14px;
  border-radius: 8px;
  transition: background 0.12s ease, color 0.12s ease;
}
.tpl-cat-dropdown-item:hover {
  background: color-mix(in srgb, var(--accent) 12%, transparent);
  color: var(--accent);
}

.tpl-index-note {
  font-size: 14px;
  color: var(--ink-soft);
  line-height: 1.6;
  max-width: 720px;
  margin: 20px 0 32px;
}
.tpl-index-note a { color: var(--accent); font-weight: 600; text-decoration: none; }

.tpl-cat-section { margin-bottom: 36px; scroll-margin-top: 90px; }
.tpl-cat-title {
  font-family: 'Fraunces', serif;
  font-weight: 600;
  font-size: 20px;
  margin: 0 0 14px;
  border-top: 1px solid var(--line);
  padding-top: 20px;
}
.tpl-cat-section:first-of-type .tpl-cat-title { border-top: 0; padding-top: 0; }

.tpl-no-results {
  font-size: 15px;
  color: var(--ink-soft);
  text-align: center;
  padding: 40px 0;
}
.tpl-no-results a { color: var(--accent); font-weight: 600; text-decoration: none; }

.tpl-how {
  max-width: 640px;
  margin: 0 0 40px;
  padding: 22px 0 4px;
  border-top: 1px solid var(--line);
}
.tpl-how-title,
.tpl-section-title {
  font-family: 'Fraunces', serif;
  font-weight: 600;
  font-size: 22px;
  margin: 0 0 14px;
}
.tpl-section-title { margin-top: 8px; }
.tpl-how-steps {
  margin: 0 0 14px;
  padding-left: 1.2em;
  color: var(--ink-soft);
  font-size: 15px;
  line-height: 1.7;
}
.tpl-how-steps strong { color: var(--ink); font-weight: 600; }
.tpl-tip {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 13px;
  color: var(--ink-soft);
  margin: 0;
}
.tpl-popular {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px 28px;
  max-width: 720px;
  margin: 0 0 36px;
  padding: 0;
}
.tpl-popular a {
  display: block;
  text-decoration: none;
  font-weight: 600;
  font-size: 14.5px;
  padding: 8px 0;
  border-bottom: 1px solid var(--line);
  color: var(--ink);
}
.tpl-popular a:hover { color: var(--accent); }
@media (max-width: 640px) {
  .tpl-popular { grid-template-columns: 1fr; }
}

.tpl-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 16px;
}
.tpl-card {
  display: block;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 20px;
  text-decoration: none;
  color: inherit;
  transition: border-color 0.15s ease, transform 0.12s ease;
}
.tpl-card:hover {
  border-color: var(--accent);
  transform: translateY(-1px);
}
.tpl-card h3 {
  font-family: 'Inter', sans-serif;
  font-size: 16px;
  font-weight: 700;
  margin: 8px 0;
  line-height: 1.3;
}
.tpl-card p {
  font-size: 13.5px;
  color: var(--ink-soft);
  line-height: 1.5;
  margin: 0;
}
.tpl-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 4px;
}
.tpl-meta span {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 11.5px;
  font-weight: 600;
  letter-spacing: 0.02em;
  padding: 3px 8px;
  border-radius: 3px;
  background: var(--accent-soft);
  color: var(--accent);
}
.tpl-meta span:first-child {
  background: var(--sage-bg);
  color: var(--sage);
}
.tpl-featured-badge {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 11.5px;
  font-weight: 700;
  letter-spacing: 0.02em;
  padding: 3px 8px;
  border-radius: 3px;
  background: var(--accent);
  color: var(--white);
}
.tpl-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 8px 0 0;
}
.tpl-tag {
  font-size: 11px;
  padding: 2px 8px;
  border-radius: 999px;
  background: var(--paper, #f4f2ee);
  color: var(--ink-soft);
  border: 1px solid var(--line);
}
.tpl-author {
  font-size: 12px;
  color: var(--ink-soft);
  margin: 8px 0 0;
}
.tpl-author a {
  color: inherit;
  text-decoration: underline;
  text-underline-offset: 2px;
}

.tpl-box {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 22px;
  margin: 24px 0;
}
.tpl-label {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--ink-soft);
  margin-bottom: 6px;
}
.tpl-subject, .tpl-body {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 13.5px;
  line-height: 1.55;
  white-space: pre-wrap;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 4px;
  padding: 14px 16px;
  margin: 0 0 16px;
  color: var(--ink);
}
.btn-copy {
  font-family: 'Inter', sans-serif;
  font-weight: 700;
  font-size: 14px;
  padding: 10px 18px;
  border-radius: 4px;
  border: 1.5px solid var(--accent);
  background: var(--accent);
  color: var(--white);
  cursor: pointer;
}
.btn-copy:hover { filter: brightness(0.95); }

/* —— Document template online editor + PDF —— */
.tpl-editor-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 0 0 14px;
}
.btn-download-pdf {
  font-family: 'Inter', sans-serif;
  font-weight: 700;
  font-size: 14px;
  padding: 10px 18px;
  border-radius: 4px;
  border: 1.5px solid var(--accent);
  background: var(--accent);
  color: var(--white);
  cursor: pointer;
}
.btn-download-pdf:hover { filter: brightness(0.95); }
.btn-copy-secondary {
  background: var(--white);
  color: var(--ink);
  border-color: var(--line);
}
.btn-copy-secondary:hover { background: var(--paper); }
.tpl-doc-sheet {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 24px 26px 0;
  min-height: 200px;
}
.tpl-doc-editor {
  font-family: 'Inter', sans-serif;
  font-size: 15px;
  line-height: 1.65;
  color: var(--ink);
  outline: none;
  min-height: 180px;
  padding-bottom: 20px;
}
.tpl-doc-editor:focus {
  box-shadow: inset 0 0 0 2px color-mix(in srgb, var(--accent) 35%, transparent);
  border-radius: 4px;
}
.tpl-doc-editor h1 { font-size: 22px; margin: 0 0 12px; }
.tpl-doc-editor h2 { font-size: 16px; margin: 18px 0 8px; color: var(--ink); }
.tpl-doc-editor h3 { font-size: 14px; margin: 14px 0 6px; }
.tpl-doc-editor p { margin: 0 0 10px; }
.tpl-doc-editor ul { margin: 0 0 12px; padding-left: 22px; }
.tpl-doc-editor table { width: 100%; border-collapse: collapse; margin: 12px 0; font-size: 14px; }
.tpl-doc-editor th, .tpl-doc-editor td { border: 1px solid var(--line); padding: 6px 8px; text-align: left; }
.tpl-doc-editor hr { border: none; border-top: 1px solid var(--line); margin: 16px 0; }
.tpl-doc-footer {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin: 0 -26px;
  padding: 12px 16px;
  border-top: 1px solid var(--line);
  background: var(--white);
  font-size: 12px;
  font-weight: 600;
  color: var(--ink-soft);
  user-select: none;
  -webkit-user-modify: read-only;
}
.tpl-doc-footer img { border-radius: 4px; }
.tpl-editor-hint {
  margin: 12px 0 0;
  font-size: 13px;
  color: var(--ink-soft);
  line-height: 1.45;
}
@media print {
  body.tpl-printing .site-header,
  body.tpl-printing .site-footer,
  body.tpl-printing .mobile-panel {
    display: none !important;
  }
  body.tpl-printing .template-detail > *:not(.tpl-editor),
  body.tpl-printing .tpl-editor .tpl-label,
  body.tpl-printing .tpl-editor .tpl-editor-toolbar,
  body.tpl-printing .tpl-editor .tpl-editor-hint {
    display: none !important;
  }
  body.tpl-printing .page-main,
  body.tpl-printing .template-detail {
    padding: 0 !important;
    margin: 0 !important;
    max-width: none !important;
  }
  body.tpl-printing .tpl-box {
    border: none;
    padding: 0;
    margin: 0;
  }
  body.tpl-printing .tpl-doc-sheet {
    border: none;
    padding: 0;
    background: #fff;
  }
  body.tpl-printing .tpl-doc-editor {
    box-shadow: none;
  }
  body.tpl-printing .tpl-doc-footer {
    margin: 24px 0 0;
    border-top: 1px solid #ccc;
    print-color-adjust: exact;
    -webkit-print-color-adjust: exact;
  }
}

.tpl-cta {
  background: var(--paper-deep);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 22px 24px;
  margin: 28px 0;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}
.tpl-cta p {
  margin: 0;
  font-size: 15px;
  color: var(--ink);
  font-weight: 600;
}

/* —— PDF pack strip (index / blog) —— */
.tpl-pack-strip {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 16px 24px;
  margin: 8px 0 36px;
  padding: 18px 22px;
  border-top: 4px solid var(--ink);
  border-bottom: 4px solid var(--accent);
  background: color-mix(in srgb, var(--paper) 70%, var(--white));
}
.tpl-pack-strip-copy {
  margin: 0;
  flex: 1 1 240px;
  font-size: 16px;
  font-weight: 600;
  color: var(--ink);
  line-height: 1.35;
  letter-spacing: -0.01em;
}
.tpl-pack-strip-btn {
  display: inline-block;
  flex: 0 0 auto;
  padding: 11px 22px;
  border-radius: 4px;
  background: var(--accent);
  color: var(--white);
  font-weight: 700;
  font-size: 14px;
  text-decoration: none;
}
.tpl-pack-strip-btn:hover { filter: brightness(0.96); }

/* —— Dedicated lead-pack landing —— */
.lead-pack-page {
  background: color-mix(in srgb, var(--paper) 55%, #f7f1e8);
  min-height: 100vh;
}
.lead-pack-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 14px 28px;
  background: var(--accent);
}
.lead-pack-brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--white);
  font-weight: 700;
  font-size: 20px;
  letter-spacing: -0.03em;
}
.lead-pack-brand img {
  width: 28px;
  height: 28px;
  border-radius: 7px;
  background: var(--white);
}
.lead-pack-top-link {
  color: var(--white);
  text-decoration: none;
  font-size: 14px;
  font-weight: 600;
  opacity: 0.92;
}
.lead-pack-top-link:hover { text-decoration: underline; opacity: 1; }

.lead-pack-shell {
  max-width: 1080px;
  margin: 0 auto;
  padding: 48px 24px 32px;
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 40px;
  align-items: start;
}
.lead-pack-copy h1 {
  font-family: Fraunces, serif;
  font-size: clamp(28px, 4vw, 40px);
  line-height: 1.15;
  letter-spacing: -0.03em;
  color: var(--ink);
  margin: 0 0 18px;
}
.lead-pack-copy p {
  margin: 0 0 14px;
  font-size: 16px;
  line-height: 1.6;
  color: var(--ink);
  max-width: 38em;
}
.lead-pack-mock {
  position: relative;
  margin: 36px 0 0;
  height: 280px;
  max-width: 340px;
}
.lead-pack-book {
  position: absolute;
  width: 210px;
  height: 260px;
  border-radius: 6px 10px 10px 6px;
  box-shadow: 0 14px 36px color-mix(in srgb, var(--ink) 18%, transparent);
}
.lead-pack-book-back {
  left: 36px;
  top: 18px;
  background: color-mix(in srgb, var(--accent) 72%, var(--ink));
  transform: rotate(6deg);
}
.lead-pack-book-mid {
  left: 18px;
  top: 10px;
  background: color-mix(in srgb, var(--accent) 88%, var(--white));
  transform: rotate(3deg);
}
.lead-pack-book-front {
  left: 0;
  top: 0;
  background: linear-gradient(160deg, var(--accent), color-mix(in srgb, var(--accent) 75%, var(--ink)));
  color: var(--white);
  padding: 22px 20px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.lead-pack-book-mark {
  font-weight: 700;
  font-size: 15px;
  letter-spacing: -0.03em;
  opacity: 0.95;
}
.lead-pack-book-title {
  font-family: Fraunces, serif;
  font-size: 22px;
  line-height: 1.2;
  letter-spacing: -0.02em;
  margin-top: 8px;
}
.lead-pack-book-sub {
  font-size: 13px;
  opacity: 0.9;
}
.lead-pack-book-bullets {
  margin: auto 0 0;
  padding: 0;
  list-style: none;
  font-size: 12.5px;
  line-height: 1.45;
}
.lead-pack-book-bullets li {
  margin: 0 0 4px;
  padding-left: 12px;
  position: relative;
}
.lead-pack-book-bullets li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.55em;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--white);
}

.lead-pack-card {
  background: var(--white);
  border-radius: 12px;
  padding: 28px 28px 24px;
  box-shadow:
    0 1px 0 color-mix(in srgb, var(--ink) 6%, transparent),
    0 18px 40px color-mix(in srgb, var(--ink) 10%, transparent);
  border: 1px solid color-mix(in srgb, var(--ink) 8%, var(--white));
}
.lead-pack-card h2 {
  margin: 0 0 18px;
  text-align: center;
  font-family: Fraunces, serif;
  font-size: 24px;
  letter-spacing: -0.02em;
  color: var(--ink);
}
.lead-pack-label {
  display: block;
  margin: 0 0 6px;
  font-size: 13px;
  font-weight: 600;
  color: var(--ink);
}
.lead-pack-form input,
.lead-pack-form select {
  display: block;
  width: 100%;
  margin: 0 0 14px;
  border: 1.5px solid var(--line);
  border-radius: 6px;
  padding: 11px 12px;
  font: inherit;
  font-size: 14.5px;
  color: var(--ink);
  background: var(--white);
}
.lead-pack-form input:focus,
.lead-pack-form select:focus {
  outline: 2px solid color-mix(in srgb, var(--accent) 45%, transparent);
  border-color: var(--accent);
}
.lead-pack-fine {
  margin: 4px 0 14px;
  font-size: 12px;
  line-height: 1.45;
  color: var(--ink-soft);
}
.lead-pack-submit {
  display: block;
  width: 100%;
  border: 0;
  border-radius: 6px;
  padding: 13px 18px;
  background: var(--accent);
  color: var(--white);
  font: inherit;
  font-weight: 700;
  font-size: 15px;
  cursor: pointer;
}
.lead-pack-submit:hover { filter: brightness(0.96); }
.lead-pack-submit:disabled { opacity: 0.7; cursor: wait; }
.lead-pack-foot {
  text-align: center;
  padding: 8px 24px 40px;
  font-size: 14px;
  color: var(--ink-soft);
}
.lead-pack-foot a { color: var(--accent); font-weight: 600; }

.tpl-pack-turnstile { margin: 4px 0 8px; }
.tpl-pack-status {
  margin: 0 0 10px;
  font-size: 13.5px;
  min-height: 1.2em;
  color: var(--ink-soft);
}
.tpl-pack-status.is-ok { color: var(--sage); }
.tpl-pack-status.is-error { color: var(--rust); }

@media (max-width: 860px) {
  .lead-pack-shell {
    grid-template-columns: 1fr;
    padding-top: 32px;
    gap: 28px;
  }
  .lead-pack-mock {
    margin-left: auto;
    margin-right: auto;
  }
  .lead-pack-topbar { padding: 12px 18px; }
}

.template-detail h2 {
  font-family: 'Fraunces', serif;
  font-size: 22px;
  margin: 36px 0 12px;
}
.tpl-more {
  list-style: none;
  padding: 0;
}
.tpl-more li {
  border-bottom: 1px solid var(--line);
}
.tpl-more a {
  display: block;
  padding: 12px 0;
  text-decoration: none;
  color: var(--ink);
  font-weight: 600;
  font-size: 14.5px;
}
.tpl-more a:hover { color: var(--accent); }

/* ---------- Template detail: 7-section landing structure ---------- */
.tpl-hero-cta { margin: 18px 0 8px; }

/* ---------- Alternative / import-from landings (docstoc orange hero) ---------- */
.alt-hero .tpl-hero-inner,
.alt-hero-inner {
  max-width: 720px;
  text-align: left;
  margin: 0 auto;
}
.alt-hero-ctas {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 8px;
}
.alt-hero-primary {
  display: inline-block;
  background: var(--accent);
  color: var(--white);
  font-weight: 700;
  font-size: 15px;
  text-decoration: none;
  padding: 12px 20px;
  border-radius: 8px;
}
.alt-hero-primary:hover { filter: brightness(1.05); }
.alt-hero-secondary {
  display: inline-block;
  background: var(--white);
  color: var(--ink);
  font-weight: 700;
  font-size: 15px;
  text-decoration: none;
  padding: 12px 20px;
  border-radius: 8px;
}
.alt-body {
  max-width: 720px;
  margin: 0 auto 56px;
  padding-top: 8px;
}
.alt-body h2 {
  font-family: 'Fraunces', serif;
  font-weight: 600;
  font-size: 1.45rem;
  margin: 36px 0 12px;
  color: var(--ink);
}
.alt-body h3 {
  font-size: 1.05rem;
  margin: 22px 0 8px;
  color: var(--ink);
}
.alt-body p,
.alt-body li {
  font-size: 15.5px;
  line-height: 1.65;
  color: var(--ink-soft);
}
.alt-body ul { padding-left: 1.2em; margin: 0 0 18px; }
.alt-body a { color: var(--accent); font-weight: 600; text-decoration: none; }
.alt-body a:hover { text-decoration: underline; }
.alt-steps {
  list-style: none;
  padding: 0;
  margin: 0 0 18px;
}
.alt-steps li {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  margin-bottom: 14px;
}
.alt-step-n {
  flex-shrink: 0;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--accent);
  color: var(--white);
  font-size: 13px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: 2px;
}
.alt-note { font-size: 14.5px; }
.alt-also { padding-left: 1.2em; }
.alt-import-more { font-size: 14.5px; margin-top: 24px; }
.alt-footer-cta {
  margin: 40px 0 8px;
  padding: 28px 0 8px;
  border-top: 1px solid var(--line);
}
.alt-footer-cta p { margin: 0 0 16px; }
.cmp-hub { max-width: 760px; }
.cmp-sector { margin: 8px 0 40px; }
.cmp-sector-lede { margin: 0 0 16px; }
.cmp-grid {
  display: flex;
  flex-direction: column;
}
.cmp-row {
  display: block;
  padding: 16px 0;
  border-bottom: 1px solid var(--line);
  text-decoration: none !important;
}
.cmp-row strong {
  display: block;
  font-size: 16px;
  color: var(--ink);
  margin-bottom: 4px;
}
.cmp-row span {
  font-size: 14px;
  font-weight: 400;
  color: var(--ink-soft);
  line-height: 1.45;
}
.cmp-row:hover strong { color: var(--accent); }
.cmp-imports {
  margin: 14px 0 0;
  font-size: 13.5px;
  line-height: 1.7;
}

.tpl-seo-intro {
  font-size: 15.5px;
  line-height: 1.65;
  color: var(--ink-soft);
  margin: 8px 0 28px;
}

.tpl-included {
  list-style: none;
  padding: 0;
  margin: 0 0 28px;
  display: grid;
  gap: 10px;
}
.tpl-included li {
  position: relative;
  padding-left: 26px;
  font-size: 15px;
  line-height: 1.5;
  color: var(--ink);
}
.tpl-included li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 7px;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--accent);
}

.tpl-usecases {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
  margin: 0 0 28px;
}
@media (max-width: 640px) {
  .tpl-usecases { grid-template-columns: 1fr; }
}
.tpl-usecase {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 16px 18px;
}
.tpl-usecase h3 {
  margin: 0 0 6px;
  font-size: 15px;
  font-weight: 700;
  color: var(--ink);
}
.tpl-usecase p {
  margin: 0;
  font-size: 14px;
  line-height: 1.5;
  color: var(--ink-soft);
}

.tpl-cta-footer {
  background: var(--paper-deep);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 32px 28px;
  margin: 40px 0 16px;
  text-align: center;
}
.tpl-cta-footer h2 {
  margin: 0 0 8px;
  font-size: 20px;
}
.tpl-cta-footer p {
  margin: 0 0 18px;
  color: var(--ink-soft);
  font-size: 15px;
}

/* ---------- Trust layer + "why us" conversion section (template/document detail pages) ---------- */
.trust-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 22px;
  list-style: none;
  padding: 0;
  margin: 14px 0 24px;
}
.trust-badges li {
  display: flex;
  align-items: center;
  gap: 7px;
  font-size: 13.5px;
  font-weight: 600;
  color: var(--ink-soft);
}
.trust-badges svg {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
  color: var(--accent);
}

.why-docstoc {
  margin: 40px 0;
  padding: 32px 0;
  border-top: 1px solid var(--line);
}
.why-docstoc h2 {
  margin: 0 0 20px;
  font-size: 22px;
}
.why-docstoc-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}
@media (max-width: 720px) {
  .why-docstoc-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 480px) {
  .why-docstoc-grid { grid-template-columns: 1fr; }
}
.why-docstoc-item h3 {
  margin: 0 0 6px;
  font-size: 15px;
  font-weight: 700;
  color: var(--ink);
}
.why-docstoc-item p {
  margin: 0;
  font-size: 13.5px;
  line-height: 1.5;
  color: var(--ink-soft);
}
.why-docstoc-item a {
  color: var(--accent);
  font-weight: 600;
  text-decoration: none;
}

/* ---------- AI PAGE / AI TOOL CARDS ---------- */
.ai-page { padding: 40px 0 60px; max-width: 720px; }
.ai-eyebrow {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 12px;
}
.ai-page h1 {
  font-family: 'Fraunces', serif;
  font-weight: 600;
  font-size: clamp(28px, 4vw, 40px);
  line-height: 1.15;
  margin-bottom: 14px;
}
.ai-page .lede {
  font-size: 16px;
  color: var(--ink-soft);
  margin-bottom: 32px;
  line-height: 1.6;
}
.ai-page .lede em { color: var(--ink); font-style: normal; font-weight: 600; }

.ai-tools-panel, .ai-also {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 18px;
  margin-bottom: 20px;
}
.ai-tools-label {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-soft);
  margin: 2px 6px 12px;
}
.ai-tool-card {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  padding: 14px 16px;
  margin-bottom: 10px;
  border-radius: 10px;
  border: 1.5px solid color-mix(in srgb, var(--accent) 35%, var(--line));
  background: color-mix(in srgb, var(--accent) 6%, var(--white));
  text-decoration: none;
  color: inherit;
  transition: border-color 0.15s ease, transform 0.12s ease;
}
.ai-tool-card:last-child { margin-bottom: 0; }
.ai-tool-card:hover {
  border-color: var(--accent);
  transform: translateY(-1px);
}
.ai-tool-icon {
  flex-shrink: 0;
  width: 36px;
  height: 36px;
  border-radius: 8px;
  background: var(--accent);
  color: var(--white);
  display: grid;
  place-items: center;
  font-size: 15px;
  font-weight: 700;
}
.ai-tool-copy {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}
.ai-tool-copy strong {
  font-size: 15px;
  color: var(--ink);
}
.ai-tool-copy span {
  font-size: 13px;
  color: var(--ink-soft);
  line-height: 1.4;
}

.ai-also-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}
.ai-also-card {
  background: var(--paper);
  border-radius: 8px;
  padding: 14px 16px;
}
.ai-also-card strong {
  display: block;
  font-size: 14px;
  margin-bottom: 4px;
}
.ai-also-card strong a { color: var(--accent); text-decoration: none; }
.ai-also-card p {
  margin: 0;
  font-size: 13px;
  color: var(--ink-soft);
  line-height: 1.45;
}
@media (max-width: 560px) {
  .ai-also-grid { grid-template-columns: 1fr; }
}

.ai-tool-card.ai-tool-teaser {
  opacity: 0.75;
  pointer-events: none;
  cursor: default;
}
.ai-page .lede a {
  color: var(--accent);
  font-weight: 600;
  text-decoration: none;
}
.ai-page .lede strong { color: var(--ink); }

.mcp-panel {
  margin-top: 48px;
  padding: 28px 24px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: color-mix(in srgb, var(--paper) 70%, var(--white));
}
.mcp-panel h2 {
  font-family: 'Fraunces', serif;
  font-size: 24px;
  font-weight: 600;
  margin: 0 0 12px;
}
.mcp-panel > p {
  color: var(--ink-soft);
  font-size: 15px;
  line-height: 1.6;
  margin: 0 0 16px;
}
.mcp-url-row {
  display: flex;
  gap: 8px;
  align-items: center;
  flex-wrap: wrap;
  margin-bottom: 10px;
}
.mcp-url-row code {
  flex: 1;
  min-width: 200px;
  font-family: 'IBM Plex Mono', monospace;
  font-size: 13.5px;
  padding: 12px 14px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--white);
  color: var(--ink);
}
.btn-copy-mcp {
  font: inherit;
  font-weight: 700;
  font-size: 14px;
  padding: 12px 18px;
  border-radius: 999px;
  border: 1.5px solid var(--ink);
  background: var(--ink);
  color: var(--white);
  cursor: pointer;
}
.btn-copy-mcp:hover { opacity: 0.9; }
.mcp-note {
  font-size: 13px !important;
  color: var(--ink-soft);
  margin-bottom: 28px !important;
}
.mcp-note-tight {
  margin-top: 4px !important;
  margin-bottom: 0 !important;
}
.mcp-clients { display: flex; flex-direction: column; gap: 22px; }
.mcp-client {
  padding-left: 14px;
  border-left: 3px solid var(--accent);
}
.mcp-client h3 {
  font-size: 16px;
  font-weight: 700;
  margin: 0 0 8px;
}
.mcp-client h3 span {
  font-weight: 500;
  color: var(--ink-soft);
  font-size: 14px;
}
.mcp-client p {
  font-size: 14.5px;
  color: var(--ink-soft);
  line-height: 1.55;
  margin: 0 0 6px;
}
.mcp-client p strong { color: var(--ink); }
.mcp-client .mcp-code {
  margin-top: 10px;
}
.mcp-client a {
  color: var(--ink);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.mcp-panel-soft { margin-top: 20px; }
.mcp-panel + .mcp-panel { margin-top: 20px; }
.mcp-code {
  display: block;
  margin: 0 0 12px;
  padding: 16px 18px;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: var(--white);
  font-family: 'IBM Plex Mono', monospace;
  font-size: 13px;
  line-height: 1.55;
  overflow-x: auto;
  white-space: pre;
  color: var(--ink);
}
.btn-copy-mcp-ghost {
  background: var(--white);
  color: var(--ink);
  border-color: var(--line);
  margin-bottom: 12px;
}
.btn-copy-mcp-ghost:hover {
  border-color: var(--ink-soft);
  opacity: 1;
}
.mcp-upgrade-list {
  margin: 0 0 20px;
  padding-left: 1.2em;
  color: var(--ink-soft);
  font-size: 15px;
  line-height: 1.65;
}
.mcp-upgrade-list strong { color: var(--ink); }
.mcp-panel .nav-cta {
  display: inline-block;
  margin-top: 4px;
}

.tpl-ai-intro {
  font-size: 13.5px;
  color: var(--ink-soft);
  margin: 0 6px 14px;
  line-height: 1.45;
}
.paid-pill {
  display: inline-block;
  margin-left: 8px;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 2px 7px;
  border-radius: 3px;
  background: var(--accent-soft);
  color: var(--accent);
  vertical-align: middle;
}
.tpl-cta-compact {
  margin: 14px 6px 4px;
  padding: 14px 0 0;
  border-top: 1px solid var(--line);
  background: none;
  border-left: none;
  border-right: none;
  border-bottom: none;
  border-radius: 0;
}

/* Docstoc Assistant (styles also injected by assistant.js for /app) */
.docstoc-asst { position: fixed; right: 20px; bottom: 20px; z-index: 99999; font-family: Inter, system-ui, sans-serif; }
.docstoc-asst-fab {
  width: 56px; height: 56px; border-radius: 999px; border: 0;
  background: var(--ink, #2A1410); color: #fff; cursor: pointer;
  display: grid; place-items: center; box-shadow: 0 8px 24px rgba(27,49,85,.28);
  padding: 0; line-height: 1;
}
.docstoc-asst-fab img { display: block; width: 22px; height: 22px; }
.docstoc-asst-fab.is-open { background: var(--accent, #EC683C); font-size: 28px; font-weight: 300; }
.docstoc-asst-panel {
  position: absolute; right: 0; bottom: 70px; width: min(340px, calc(100vw - 32px));
  background: #fff; border-radius: 16px; box-shadow: 0 16px 48px rgba(27,49,85,.22);
  overflow: hidden; border: 1px solid rgba(27,49,85,.08);
}
.docstoc-asst-panel[hidden] { display: none !important; }
.docstoc-asst-head {
  display: flex; align-items: center; justify-content: space-between;
  padding: 12px 14px; background: var(--ink, #2A1410); color: #fff;
}
.docstoc-asst-title { display: flex; align-items: center; gap: 8px; font-weight: 700; font-size: 14px; }
.docstoc-asst-title img {
  width: 18px; height: 18px; border-radius: 999px; background: #fff; padding: 2px; box-sizing: border-box;
}
.docstoc-asst-x { background: none; border: 0; color: #fff; font-size: 22px; cursor: pointer; line-height: 1; opacity: .85; }
.docstoc-asst-x:hover { opacity: 1; }
.docstoc-asst-body { padding: 14px; max-height: min(420px, 60vh); overflow: auto; display: flex; flex-direction: column; gap: 10px; }
.docstoc-asst-msg { padding: 10px 12px; border-radius: 12px; font-size: 13.5px; line-height: 1.45; max-width: 95%; }
.docstoc-asst-msg.bot { background: #f7f3f0; color: #2A1410; align-self: flex-start; }
.docstoc-asst-msg.user { background: #fde8e0; color: #2A1410; align-self: flex-end; }
.docstoc-asst-chips { display: flex; flex-direction: column; gap: 8px; }
.docstoc-asst-chips button, .docstoc-asst-link {
  display: block; width: 100%; text-align: left; padding: 10px 12px;
  border: 1px solid #d5dbe7; border-radius: 10px; background: #fff;
  font: inherit; font-size: 13.5px; cursor: pointer; color: #2A1410; text-decoration: none;
  box-sizing: border-box;
}
.docstoc-asst-chips button:hover, .docstoc-asst-link:hover { border-color: var(--accent, #EC683C); }

/* ---------- COMPARE (blog) ---------- */
.compare-price {
  padding: 28px 0 40px;
}
.compare-price h2,
.compare-features h2 {
  font-family: 'Fraunces', serif;
  font-weight: 600;
  font-size: clamp(24px, 3.2vw, 32px);
  margin: 0 0 12px;
}
.compare-price-sub,
.compare-features-sub {
  color: var(--ink-soft);
  font-size: 15.5px;
  max-width: 640px;
  margin: 0 0 28px;
  line-height: 1.6;
}
.pc-panel {
  max-width: 820px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.pc-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0 0 4px;
}
.pc-tab {
  appearance: none;
  border: 1px solid var(--line);
  background: var(--white);
  color: var(--ink-soft);
  font: inherit;
  font-size: 13.5px;
  font-weight: 600;
  padding: 8px 14px;
  border-radius: 999px;
  cursor: pointer;
  line-height: 1.2;
}
.pc-tab:hover {
  border-color: color-mix(in srgb, var(--ink) 28%, var(--line));
  color: var(--ink);
}
.pc-tab[aria-selected="true"] {
  background: var(--ink);
  border-color: var(--ink);
  color: var(--white);
}
.pc-product-lede {
  margin: 0 0 4px;
  font-size: 15px;
  line-height: 1.55;
  color: var(--ink-soft);
  max-width: 720px;
}
.pc-slider-card {
  background: color-mix(in srgb, var(--ink) 4%, var(--white));
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 22px 24px 20px;
}
.pc-slider-label {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-soft);
  margin-bottom: 8px;
}
.pc-slider-value {
  display: flex;
  align-items: baseline;
  gap: 8px;
  margin-bottom: 18px;
}
.pc-slider-value strong {
  font-family: 'Fraunces', serif;
  font-size: 36px;
  font-weight: 600;
  line-height: 1;
}
.pc-slider-value span {
  font-size: 15px;
  color: var(--ink-soft);
}
.pc-range {
  -webkit-appearance: none;
  appearance: none;
  width: 100%;
  height: 6px;
  border-radius: 999px;
  background: linear-gradient(
    to right,
    var(--accent) 0%,
    var(--accent) var(--pct, 21%),
    color-mix(in srgb, var(--ink) 14%, var(--white)) var(--pct, 21%),
    color-mix(in srgb, var(--ink) 14%, var(--white)) 100%
  );
  outline: none;
  cursor: pointer;
}
.pc-range::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: var(--accent);
  border: 3px solid var(--white);
  box-shadow: 0 1px 4px color-mix(in srgb, var(--ink) 28%, transparent);
  cursor: pointer;
}
.pc-range::-moz-range-thumb {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: var(--accent);
  border: 3px solid var(--white);
  box-shadow: 0 1px 4px color-mix(in srgb, var(--ink) 28%, transparent);
  cursor: pointer;
}
.pc-range-ends {
  display: flex;
  justify-content: space-between;
  margin-top: 10px;
  font-size: 12px;
  color: var(--ink-soft);
}
.pc-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 18px 22px;
  scroll-margin-top: 90px;
}
.pc-row-docstoc {
  border: 2px solid var(--accent);
  background: color-mix(in srgb, var(--accent) 6%, var(--white));
}
.pc-row-main { min-width: 0; flex: 1; }
.pc-row-name {
  font-size: 15px;
  font-weight: 700;
  color: var(--ink);
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 6px 10px;
}
.pc-row-docstoc .pc-row-name {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--accent);
}
.pc-row-link {
  font-size: 13px;
  font-weight: 600;
  color: color-mix(in srgb, var(--ink) 55%, #3b6fd8);
  text-decoration: none;
  white-space: nowrap;
}
.pc-row-link:hover { text-decoration: underline; }
.pc-row-formula {
  margin-top: 4px;
  font-size: 13px;
  color: var(--ink-soft);
  line-height: 1.4;
}
.pc-row-nums {
  display: flex;
  align-items: baseline;
  gap: 10px;
  flex-shrink: 0;
  text-align: right;
}
.pc-delta {
  font-size: 13px;
  font-weight: 600;
  color: #c0392b;
  white-space: nowrap;
}
.pc-delta.is-zero { color: var(--ink-soft); }
.pc-delta.is-cheaper { color: #1f7a4d; }
.pc-delta.is-costlier { color: #c0392b; }
[data-pc-rows] {
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.pc-total {
  font-family: 'Fraunces', serif;
  font-size: 26px;
  font-weight: 600;
  line-height: 1;
  white-space: nowrap;
}
.pc-total small {
  font-family: 'Inter', sans-serif;
  font-size: 13px;
  font-weight: 500;
  color: var(--ink-soft);
  margin-left: 2px;
}
.pc-note {
  max-width: 820px;
  margin: 16px 0 0;
  font-size: 12.5px;
  color: var(--ink-soft);
  line-height: 1.5;
}
.compare-features {
  padding: 8px 0 32px;
}
.switch-steps {
  max-width: 680px;
  margin: 16px 0 32px;
  padding-left: 1.4em;
  counter-reset: switch-step;
}
.switch-steps li {
  margin-bottom: 20px;
  padding-left: 4px;
}
.switch-steps strong {
  display: block;
  font-size: 16px;
  color: var(--ink);
  margin-bottom: 4px;
}
.switch-steps p {
  margin: 0;
  color: var(--ink-soft);
  font-size: 14.5px;
  line-height: 1.6;
}
.switch-steps a {
  color: var(--accent);
  font-weight: 600;
  text-decoration: none;
}

.compare-table-wrap {
  overflow-x: auto;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--white);
  margin: 16px 0 28px;
}
.compare-table {
  width: 100%;
  min-width: 900px;
  border-collapse: collapse;
  font-size: 13.5px;
}
.compare-table th,
.compare-table td {
  padding: 12px 14px;
  text-align: center;
  border-bottom: 1px solid var(--line);
  vertical-align: middle;
}
.compare-table th:first-child,
.compare-table td:first-child {
  text-align: left;
  font-weight: 500;
  color: var(--ink-soft);
  width: 22%;
}
.compare-table thead th {
  background: var(--ink);
  color: var(--white);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  padding-top: 16px;
  padding-bottom: 16px;
  border-bottom: none;
}
.compare-table thead th.col-docstoc {
  background: color-mix(in srgb, var(--accent) 88%, var(--ink));
}
.compare-table tbody tr:nth-child(even) td { background: var(--paper); }
.compare-table tbody tr:last-child td { border-bottom: none; }
.compare-table .col-docstoc {
  background: color-mix(in srgb, var(--accent) 10%, var(--white));
  font-weight: 600;
  color: var(--ink);
}
.compare-table tbody tr:nth-child(even) .col-docstoc {
  background: color-mix(in srgb, var(--accent) 14%, var(--paper));
}
.compare-table .check { color: var(--accent); font-weight: 700; }
.compare-table .cross { color: var(--line); font-weight: 700; }
.compare-table .muted { color: var(--ink-soft); font-size: 12.5px; font-weight: 500; }
@media (max-width: 720px) {
  .pc-row { flex-direction: column; align-items: flex-start; }
  .pc-row-nums { align-self: flex-end; }
}

/* ---------- Blog FAQ (details) ---------- */
.page-main .faq-item,
.template-detail .faq-item,
.templates-index .faq-item {
  border-bottom: 1px solid var(--line);
  padding: 4px 0;
}
.page-main .faq-item summary,
.template-detail .faq-item summary,
.templates-index .faq-item summary {
  list-style: none;
  cursor: pointer;
  font-weight: 600;
  font-size: 15.5px;
  padding: 14px 0;
  color: var(--ink);
}
.page-main .faq-item summary::-webkit-details-marker,
.template-detail .faq-item summary::-webkit-details-marker,
.templates-index .faq-item summary::-webkit-details-marker { display: none; }
.page-main .faq-item[open] summary,
.template-detail .faq-item[open] summary,
.templates-index .faq-item[open] summary { color: var(--accent); }
.page-main .faq-item p,
.template-detail .faq-item p,
.templates-index .faq-item p {
  margin: 0 0 16px;
  color: var(--ink-soft);
  line-height: 1.6;
  font-size: 15px;
}

/* ---------- Integrations band (official brand SVGs — real connectors only) ---------- */

.integrations-band {
  background: var(--paper-deep);
  border-bottom: 1px solid var(--line);
  padding: 48px 0 52px;
}

.integrations-band-compact {
  padding: 36px 0 40px;
}

.integrations-inner {
  max-width: 880px;
  margin: 0 auto;
}

.integrations-band h2 {
  font-size: 26px;
  margin-bottom: 8px;
  text-align: center;
  color: var(--ink);
}

.integrations-band-compact h2 {
  font-size: 22px;
}

.integrations-lede {
  text-align: center;
  max-width: 560px;
  margin: 0 auto 28px;
  color: var(--ink-soft);
  font-size: 15.5px;
  line-height: 1.55;
}

.integrations-band-compact .integrations-lede {
  font-size: 14px;
}

.integrations-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
  max-width: 640px;
  margin: 0 auto;
  list-style: none;
}

@media (max-width: 640px) {
  .integrations-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

.integrations-tile {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 18px 12px 14px;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 6px;
  box-shadow: 0 1px 3px color-mix(in srgb, var(--ink) 8%, transparent);
  min-height: 96px;
}

.integrations-tile-logo {
  width: 32px;
  height: 32px;
  object-fit: contain;
  display: block;
}

/* NOWPayments ships a wide wordmark (163x21), not a square icon like its siblings here —
   forcing it into the 32x32 box scales it down to a near-invisible sliver. Cap by width
   instead so it renders at a legible size, even though it won't match the others' footprint. */
.integrations-tile-logo-wordmark {
  width: 84px;
  height: auto;
  max-width: 100%;
}

.integrations-tile-name {
  font-size: 12.5px;
  font-weight: 600;
  color: var(--ink);
  text-align: center;
  line-height: 1.2;
}

.integrations-footnote {
  text-align: center;
  font-size: 12.5px;
  color: var(--ink-soft);
  margin: 20px auto 0;
  max-width: 520px;
  line-height: 1.5;
}

.integrations-cta-wrap {
  text-align: center;
  margin-top: 24px;
}

.integrations-cta {
  font-family: 'Inter', sans-serif;
  font-weight: 700;
  font-size: 16px;
  background: var(--accent);
  color: var(--white);
  padding: 14px 28px;
  border-radius: 4px;
  text-decoration: none;
  border: 1.5px solid var(--accent);
  transition: transform 0.12s ease;
  display: inline-block;
}

.integrations-cta:hover {
  transform: translateY(-1px);
}

