/* PDFCraft site — pdfcraft.datika.io
   One face (Erode, self-hosted), one ground per field, one accent (the PDF red of the icon).
   No inline styles anywhere: the CSP is style-src 'self'. */

@font-face {
  font-family: 'Erode';
  src: url('/assets/fonts/erode-400.woff2') format('woff2');
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: 'Erode';
  src: url('/assets/fonts/erode-500.woff2') format('woff2');
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: 'Erode';
  src: url('/assets/fonts/erode-600.woff2') format('woff2');
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}

:root {
  --paper: #f3f3f0;
  --paper-2: #e6e5e0;
  --ink: #151413;
  --muted: #55524d;
  --stage: #151413;
  --stage-ink: #ecebe6;
  --stage-muted: #b7b4ac;
  --accent: #c41e2c;
  --accent-press: #a31623;
  --accent-ink: #ffffff;

  --step-small: clamp(0.875rem, 0.85rem + 0.1vw, 0.9375rem);
  --step-body: clamp(1.0625rem, 1rem + 0.25vw, 1.1875rem);
  --step-lead: clamp(1.25rem, 1.1rem + 0.7vw, 1.625rem);
  --step-head: clamp(2rem, 1.3rem + 2.6vw, 3.5rem);
  --step-display: clamp(5.5rem, 12vw, 12.5rem);

  --margin: clamp(20px, 3vw, 32px);
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
  --ui-font: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
  color-scheme: light;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: 'Erode', Georgia, 'Times New Roman', serif;
  font-size: var(--step-body);
  line-height: 1.5;
  color: var(--ink);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

h1,
h2,
h3,
p,
ul,
ol,
dl,
dd,
figure,
blockquote {
  margin: 0;
}

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

a {
  color: inherit;
  text-decoration-thickness: 0.06em;
  text-underline-offset: 0.18em;
}

a:hover {
  text-decoration-thickness: 0.12em;
}

:focus-visible {
  outline: 3px solid var(--accent);
  outline-offset: 3px;
}

::selection {
  background: var(--ink);
  color: var(--paper);
}

.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;
}

.skip {
  position: absolute;
  left: var(--margin);
  top: -60px;
  z-index: 50;
  background: var(--ink);
  color: var(--paper);
  padding: 10px 16px;
  text-decoration: none;
}

.skip:focus {
  top: 12px;
}

/* ---------- Buttons: one shape (square), one height ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 52px;
  padding: 0 24px;
  font: 500 var(--step-body) / 1.2 'Erode', Georgia, serif;
  text-decoration: none;
  border: 0;
  border-radius: 0;
  cursor: pointer;
  transition:
    transform 160ms var(--ease-out),
    background-color 160ms var(--ease-out);
}

.btn:active {
  transform: translateY(1px) scale(0.985);
}

.btn-accent {
  background: var(--accent);
  color: var(--accent-ink);
}

.btn-accent:hover {
  background: var(--accent-press);
}

.btn-ink {
  background: var(--ink);
  color: var(--paper);
}

.btn-ink:hover {
  background: #2c2a27;
}

.btn-paper {
  background: var(--paper);
  color: var(--ink);
}

.btn-paper:hover {
  background: #ffffff;
}

.btn[aria-disabled='true'] {
  cursor: default;
}

/* ---------- Top bar (inner pages) ---------- */

.bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 20px var(--margin);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 600;
  font-size: var(--step-lead);
  letter-spacing: -0.02em;
  text-decoration: none;
}

.brand img {
  width: 32px;
  height: 32px;
}

.links {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 24px;
  font-size: var(--step-small);
}

.links a {
  text-decoration: none;
  padding: 6px 0;
  transition: color 160ms var(--ease-out);
}

.links a:hover,
.links a[aria-current='page'] {
  text-decoration: underline;
}

/* ---------- Home: the split stage ---------- */

.split {
  display: grid;
  grid-template-columns: 47% 53%;
  background: var(--paper);
}

.stage {
  position: sticky;
  top: 0;
  height: 100vh;
  height: 100svh;
  padding: 20px 0 20px 20px;
  background: var(--paper);
  z-index: 0;
}

.stage-frame {
  position: relative;
  height: 100%;
  overflow: hidden;
  background: var(--stage);
}

.stage-frame img {
  position: absolute;
  top: 7%;
  left: 7%;
  width: 86%;
  height: 78%;
  object-fit: contain;
  object-position: 50% 50%;
  opacity: 0;
  transform: translateY(14px) scale(0.985);
  transition:
    opacity 600ms var(--ease-out),
    transform 1200ms var(--ease-out);
}

.stage-frame img.is-active {
  opacity: 1;
  transform: none;
}

/* Without the script the first plate shows. */
.stage-frame img:first-child {
  opacity: 1;
  transform: none;
}

.js .stage-frame img:first-child:not(.is-active) {
  opacity: 0;
}

.stage-caption {
  position: absolute;
  left: 7%;
  top: calc(85% + 14px);
  margin: 0;
  max-width: 24ch;
  font-size: var(--step-small);
  line-height: 1.35;
  color: var(--stage-muted);
}

.read {
  position: relative;
  min-width: 0;
  padding: 0 clamp(28px, 5vw, 72px);
}

.hero {
  position: relative;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  min-height: 100svh;
  padding-bottom: 40px;
}

.hero .links {
  justify-content: flex-end;
  padding-top: 26px;
}

.hero-body {
  margin-top: auto;
  padding-top: 64px;
  max-width: 34ch;
}

.statement {
  font-size: var(--step-lead);
  line-height: 1.35;
  letter-spacing: -0.01em;
  font-weight: 500;
}

.hero-price {
  margin-top: 20px;
  color: var(--muted);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 20px;
  align-items: center;
  margin-top: 28px;
}

.hero-actions .quiet {
  font-size: var(--step-body);
}

.wordmark {
  position: relative;
  z-index: 2;
  margin: 48px 0 0;
  color: var(--ink);
  font-size: var(--step-display);
  font-weight: 400;
  line-height: 0.82;
  letter-spacing: -0.045em;
  white-space: nowrap;
  transform-origin: 0 100%;
}

@supports (animation-timeline: scroll()) {
  @media (prefers-reduced-motion: no-preference) {
    .wordmark {
      animation: wordmark-settle linear both;
      animation-timeline: scroll(root);
      animation-range: 0 100vh;
    }
  }
}

@keyframes wordmark-settle {
  to {
    transform: scale(0.93);
  }
}

/* Reading sections inside the split */

.chapter {
  padding: clamp(96px, 14vh, 160px) 0 0;
  max-width: 46ch;
}

.chapter h2 {
  font-size: var(--step-head);
  font-weight: 500;
  line-height: 1;
  letter-spacing: -0.03em;
}

.chapter > p,
.tool p {
  margin-top: 20px;
}

.tool {
  margin-top: clamp(56px, 9vh, 96px);
}

.tool h3 {
  font-size: var(--step-lead);
  font-weight: 600;
  line-height: 1.2;
  letter-spacing: -0.015em;
}

.tool ul {
  margin-top: 16px;
  padding-left: 1.1em;
}

.tool li + li {
  margin-top: 6px;
}

.inline-shot {
  display: none;
  margin-top: 24px;
}

/* Data table: what stays, what is sent */

.ledger {
  width: 100%;
  margin-top: 32px;
  border-collapse: collapse;
  font-size: var(--step-body);
}

.ledger caption {
  text-align: left;
  font-size: var(--step-small);
  color: var(--muted);
  padding-bottom: 10px;
}

.ledger th,
.ledger td {
  text-align: left;
  vertical-align: top;
  padding: 14px 16px 14px 0;
  border-top: 2px solid var(--paper-2);
}

.ledger thead th {
  border-top: 0;
  font-weight: 600;
}

.ledger tbody th {
  font-weight: 500;
  width: 38%;
}

.note {
  margin-top: 20px;
  font-size: var(--step-small);
  color: var(--muted);
}

/* ---------- The live thing: white-out is not redaction ---------- */

.demo {
  margin-top: 40px;
  max-width: 560px;
}

.demo-sheet {
  position: relative;
  background: #ffffff;
  color: #1d1d1f;
  font-family: var(--ui-font);
  font-size: 13px;
  line-height: 1.55;
  padding: 28px 30px 30px;
  border: 1px solid #dddcd7;
}

.demo-sheet .demo-title {
  margin: 0 0 4px;
  font-size: 15px;
  font-weight: 700;
  color: #1c2f5e;
}

.demo-sheet .rule {
  height: 2px;
  background: #b9473f;
  margin-bottom: 14px;
}

.demo-sheet p {
  margin: 0;
}

.demo-line {
  position: relative;
  padding: 2px 0;
}

.demo-cover {
  position: absolute;
  left: -4px;
  top: 0;
  bottom: 0;
  width: 230px;
  background: #ffffff;
  outline: 1px dashed #c9c7c0;
  transition: opacity 260ms var(--ease-out);
}

.demo-typed {
  position: absolute;
  left: 0;
  top: 2px;
  color: #1f48c9;
  white-space: nowrap;
  transition: opacity 260ms var(--ease-out);
}

.demo-hidden {
  transition: background-color 260ms var(--ease-out);
}

.demo-sign {
  margin-top: 18px;
  color: #1f48c9;
  min-height: 1.55em;
}

/* "Text inside the file" view */
.demo[data-view='text'] .demo-cover,
.demo[data-view='text'] .demo-typed {
  opacity: 0;
}

.demo[data-view='text'] .demo-hidden {
  background: #ffe08a;
}

.demo-controls {
  margin-top: 20px;
  display: grid;
  gap: 18px;
}

.demo-controls label,
.demo-controls legend {
  display: block;
  font-size: var(--step-small);
  font-weight: 600;
  margin-bottom: 8px;
  padding: 0;
}

.demo-controls fieldset {
  border: 0;
  margin: 0;
  padding: 0;
}

.demo-controls input[type='text'] {
  width: 100%;
  min-height: 48px;
  padding: 0 14px;
  font: 400 16px/1.2 var(--ui-font);
  color: var(--ink);
  background: #ffffff;
  border: 1px solid #bdbab3;
  border-radius: 0;
}

.segmented {
  display: inline-flex;
  flex-wrap: wrap;
  background: var(--paper-2);
  padding: 4px;
  gap: 4px;
}

.segmented button {
  min-height: 44px;
  padding: 0 16px;
  font: 500 var(--step-small) / 1.2 'Erode', Georgia, serif;
  color: var(--ink);
  background: transparent;
  border: 0;
  border-radius: 0;
  cursor: pointer;
  transition: background-color 160ms var(--ease-out);
}

.segmented button:hover {
  background: #d8d6d0;
}

.segmented button[aria-pressed='true'] {
  background: var(--ink);
  color: var(--paper);
}

.demo-verdict {
  margin-top: 20px;
  min-height: 3em;
}

/* ---------- Pricing: two fields ---------- */

.pricing {
  padding-top: clamp(120px, 16vh, 200px);
}

.pricing-head {
  padding: 0 var(--margin) 48px;
  max-width: 60ch;
}

.pricing-head h2,
.faq h2,
.terms-of-sale h2,
.page-head h1 {
  font-size: var(--step-head);
  font-weight: 500;
  line-height: 1;
  letter-spacing: -0.03em;
}

.pricing-head p {
  margin-top: 16px;
}

.plans {
  display: grid;
  grid-template-columns: 5fr 7fr;
}

.plan {
  display: flex;
  flex-direction: column;
  min-height: 82vh;
  min-height: 82svh;
  padding: 40px var(--margin);
}

.plan-free {
  background: var(--paper-2);
  color: var(--ink);
}

.plan-pro {
  background: var(--accent);
  color: var(--accent-ink);
}

.plan-pro a {
  color: inherit;
}

.plan h3 {
  font-size: clamp(2.5rem, 5vw, 4.5rem);
  font-weight: 500;
  line-height: 0.95;
  letter-spacing: -0.035em;
}

.plan .who {
  margin-top: 16px;
  font-size: var(--step-lead);
  line-height: 1.3;
  max-width: 26ch;
}

.plan .includes {
  margin-top: 24px;
  max-width: 44ch;
}

.plan-foot {
  margin-top: auto;
  padding-top: 40px;
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 20px 32px;
}

.price {
  font-size: clamp(4rem, 9vw, 9rem);
  font-weight: 500;
  line-height: 0.85;
  letter-spacing: -0.05em;
  font-variant-numeric: lining-nums tabular-nums;
}

.price small {
  font-size: var(--step-body);
  letter-spacing: 0;
  font-weight: 400;
  margin-left: 6px;
}

.price-alt {
  margin-top: 14px;
  font-size: var(--step-lead);
}

.terms-of-sale {
  display: grid;
  grid-template-columns: minmax(0, 3fr) minmax(0, 9fr);
  gap: 32px clamp(32px, 5vw, 72px);
  padding: clamp(72px, 10vh, 120px) var(--margin) 0;
}

.terms-of-sale h2 {
  font-size: var(--step-lead);
  font-weight: 600;
  letter-spacing: -0.015em;
  line-height: 1.2;
}

.terms-cols {
  columns: 2;
  column-gap: 56px;
}

.terms-cols p {
  break-inside: avoid;
  margin-bottom: 18px;
}

/* ---------- FAQ as reading text ---------- */

.faq {
  display: grid;
  grid-template-columns: minmax(0, 3fr) minmax(0, 9fr);
  gap: 32px clamp(32px, 5vw, 72px);
  padding: clamp(120px, 16vh, 200px) var(--margin) clamp(120px, 16vh, 200px);
}

.faq-text {
  columns: 2;
  column-gap: 56px;
}

.faq-text p {
  break-inside: avoid;
  margin-bottom: 20px;
}

.faq-text strong,
.qa strong {
  font-weight: 600;
}

/* ---------- Footer: plate half, menu half ---------- */

.footer {
  display: grid;
  grid-template-columns: 1fr 1fr;
  background: var(--stage);
  color: var(--stage-ink);
  min-height: 92vh;
  min-height: 92svh;
}

.footer-plate {
  position: relative;
  overflow: hidden;
  min-height: 320px;
}

.footer-plate img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 50% 20%;
}

.footer-menu {
  display: flex;
  flex-direction: column;
  padding: 64px var(--margin) 32px clamp(32px, 6vw, 96px);
}

.footer-menu .brand {
  color: var(--stage-ink);
}

.footer-menu nav ul {
  list-style: none;
  padding: 0;
  margin-top: 48px;
  display: grid;
  gap: 14px;
}

.footer-menu nav a {
  display: inline-block;
  font-size: clamp(1.75rem, 2.6vw, 2.5rem);
  font-weight: 500;
  letter-spacing: -0.02em;
  line-height: 1.1;
  text-decoration: none;
  transition:
    transform 220ms var(--ease-out),
    color 220ms var(--ease-out);
}

.footer-menu nav ul:hover a {
  color: var(--stage-muted);
}

.footer-menu nav ul a:hover,
.footer-menu nav ul a:focus-visible {
  color: var(--stage-ink);
  transform: translateX(12px);
}

.footer-contact {
  margin-top: 56px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
  font-size: var(--step-small);
}

.footer-contact strong {
  display: block;
  font-weight: 600;
  margin-bottom: 4px;
}

.legal {
  margin-top: auto;
  padding-top: 48px;
  display: flex;
  flex-wrap: wrap;
  gap: 6px 20px;
  font-size: var(--step-small);
  color: var(--stage-muted);
}

.legal a {
  color: var(--stage-ink);
}

/* ---------- Inner pages ---------- */

.page {
  display: grid;
  grid-template-columns: minmax(0, 4fr) minmax(0, 8fr);
  gap: 40px clamp(32px, 6vw, 96px);
  padding: clamp(56px, 10vh, 120px) var(--margin) clamp(120px, 16vh, 200px);
}

.page-head p {
  margin-top: 20px;
  font-size: var(--step-lead);
  line-height: 1.35;
  max-width: 30ch;
}

.page-body {
  max-width: 68ch;
}

.page-body h2 {
  font-size: var(--step-lead);
  font-weight: 600;
  letter-spacing: -0.015em;
  line-height: 1.2;
}

.page-body section + section {
  margin-top: 64px;
}

.page-body p,
.page-body ol,
.page-body ul {
  margin-top: 14px;
}

.page-body li + li {
  margin-top: 8px;
}

.contact-block {
  background: var(--paper-2);
  padding: 28px;
  margin-top: 20px;
}

.contact-block .big {
  display: inline-block;
  margin-top: 6px;
  font-size: clamp(1.5rem, 1.1rem + 1.2vw, 2rem);
  font-weight: 500;
  letter-spacing: -0.02em;
  line-height: 1.1;
  overflow-wrap: anywhere;
}

/* Checkout */

.checkout {
  display: grid;
  grid-template-columns: minmax(0, 6fr) minmax(0, 6fr);
  min-height: 70vh;
}

.checkout-main {
  padding: clamp(48px, 9vh, 112px) var(--margin) 96px;
}

.checkout-main h1 {
  font-size: var(--step-head);
  font-weight: 500;
  line-height: 1;
  letter-spacing: -0.03em;
}

.checkout-main .lead {
  margin-top: 20px;
  font-size: var(--step-lead);
  line-height: 1.35;
  max-width: 32ch;
}

.checkout-plan {
  margin-top: 40px;
}

.checkout-plan .price {
  font-size: clamp(3.5rem, 7vw, 6.5rem);
}

.checkout-actions {
  margin-top: 32px;
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  align-items: center;
}

.checkout-status {
  margin-top: 20px;
  min-height: 1.5em;
}

.checkout-terms {
  background: var(--paper-2);
  padding: clamp(48px, 9vh, 112px) var(--margin) 96px clamp(32px, 5vw, 72px);
}

.checkout-terms h2 {
  font-size: var(--step-lead);
  font-weight: 600;
  letter-spacing: -0.015em;
}

.checkout-steps {
  margin-top: 28px;
  padding-left: 1.2em;
  max-width: 44ch;
}

.checkout-steps li + li {
  margin-top: 10px;
}

.checkout-terms ul {
  margin-top: 20px;
  padding-left: 1.1em;
  max-width: 52ch;
}

.checkout-terms li + li {
  margin-top: 12px;
}

.checkout-terms p {
  margin-top: 24px;
  max-width: 52ch;
}

.plan-switch {
  margin-top: 24px;
}

[hidden] {
  display: none !important;
}

/* 404 */

.lost {
  padding: clamp(48px, 10vh, 120px) var(--margin) clamp(120px, 16vh, 200px);
}

.lost .big-num {
  font-size: clamp(8rem, 26vw, 22rem);
  font-weight: 400;
  line-height: 0.8;
  letter-spacing: -0.06em;
}

.lost h1 {
  margin-top: 32px;
  font-size: var(--step-head);
  font-weight: 500;
  letter-spacing: -0.03em;
  line-height: 1;
}

.lost p {
  margin-top: 20px;
  max-width: 46ch;
}

/* ---------- Entrances (only when the script runs) ---------- */

.js [data-reveal] > * {
  opacity: 0;
  transform: translateY(24px);
  transition:
    opacity 700ms var(--ease-out),
    transform 700ms var(--ease-out);
}

.js [data-reveal].is-in > * {
  opacity: 1;
  transform: none;
}

.js [data-reveal].is-in > *:nth-child(2) {
  transition-delay: 70ms;
}
.js [data-reveal].is-in > *:nth-child(3) {
  transition-delay: 140ms;
}
.js [data-reveal].is-in > *:nth-child(4) {
  transition-delay: 210ms;
}
.js [data-reveal].is-in > *:nth-child(n + 5) {
  transition-delay: 280ms;
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  .js [data-reveal] > *,
  .stage-frame img {
    transform: none !important;
    transition: opacity 200ms linear !important;
  }
  .btn,
  .footer-menu nav a {
    transition: none;
  }
}

/* ---------- Phone and narrow tablet ---------- */

@media (max-width: 900px) {
  .split {
    grid-template-columns: 1fr;
  }

  .stage {
    position: relative;
    height: 56vh;
    height: 56svh;
    padding: 12px 12px 0;
  }

  .stage-frame img {
    top: 64px;
    left: 6%;
    width: 88%;
    height: calc(100% - 64px - 12vw);
  }

  .stage-frame img:not(:first-child) {
    display: none;
  }

  .stage-caption {
    display: none;
  }

  .read {
    padding: 0 20px;
  }

  .hero {
    min-height: 0;
    padding-bottom: 0;
  }

  .split,
  .stage {
    position: relative;
  }

  .read,
  .hero {
    position: static;
  }

  .hero .links {
    position: absolute;
    z-index: 3;
    top: 12px;
    left: 12px;
    right: 12px;
    justify-content: flex-start;
    gap: 0;
    padding: 0;
  }

  .hero .links a {
    background: var(--stage);
    color: var(--stage-ink);
    padding: 12px 9px;
  }

  .wordmark {
    order: -1;
    position: relative;
    z-index: 2;
    margin: 20px 0 0;
    font-size: 21vw;
  }

  .hero-body {
    margin-top: 0;
    padding-top: 24px;
    max-width: none;
  }

  .statement {
    font-size: 1.1875rem;
  }

  .chapter {
    padding-top: 96px;
    max-width: none;
  }

  .inline-shot {
    display: block;
  }

  .plans {
    grid-template-columns: 1fr;
  }

  .plan-pro {
    order: -1;
  }

  .plan {
    min-height: 70vh;
    min-height: 70svh;
    padding: 28px 20px;
  }

  .plan h3 {
    font-size: 12vw;
  }

  .price {
    font-size: 22vw;
  }

  .plan-foot .btn {
    width: 100%;
  }

  .terms-of-sale,
  .faq,
  .page,
  .checkout {
    grid-template-columns: 1fr;
  }

  .terms-cols,
  .faq-text {
    columns: 1;
  }

  .footer {
    grid-template-columns: 1fr;
  }

  .footer-plate {
    height: 50vh;
    height: 50svh;
  }

  .footer-menu {
    padding: 40px 20px 28px;
  }

  .footer-menu nav a {
    font-size: 8vw;
  }

  .footer-contact {
    grid-template-columns: 1fr;
  }

  .bar {
    flex-wrap: wrap;
    padding: 16px 20px;
  }

  .checkout-terms {
    padding: 48px 20px 72px;
  }
}

.chapter h2 + p {
  margin-top: 20px;
}

@media (max-width: 360px) {
  .hero .links .hide-xs {
    display: none;
  }
}
