/* paraphe.dx2-66.com: a form on a blotter. The page's words are printed on
   the sheet in the PDF's own face; the one hand-drawn thing is the paraphe,
   in the app's ink. No web fonts, no JavaScript. */

:root {
  --desk: #d9dde3;
  --desk-2: #cfd4db;
  --paper: #ffffff;
  --ink: #2340b0;
  --ink-strong: #1a3190;
  --ink-soft: rgb(35 64 176 / 0.09);
  --text: #1f232a;
  --muted: #4c535e;
  --rule: #c3c9d2;
  --field: #eef0fb;
  --sheet-shadow: 0 1px 2px rgb(20 28 45 / 0.12), 0 18px 50px rgb(20 28 45 / 0.16);

  --ui: "Segoe UI Variable Text", "Segoe UI", system-ui, -apple-system, "Helvetica Neue", sans-serif;
  --display: "Segoe UI Variable Display", "Segoe UI", system-ui, -apple-system, "Helvetica Neue", sans-serif;
  --printed: Helvetica, "Helvetica Neue", Arial, sans-serif;

  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root {
    --desk: #15171c;
    --desk-2: #1c1f25;
    --ink: #8ea2ff;
    --ink-strong: #b3c0ff;
    --ink-soft: rgb(142 162 255 / 0.12);
    --text: #e8eaee;
    --muted: #a7aeba;
    --rule: #3a3f49;
    --sheet-shadow: 0 2px 10px rgb(0 0 0 / 0.5), 0 24px 60px rgb(0 0 0 / 0.45);
    color-scheme: dark;
  }
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--desk);
  color: var(--text);
  font: 1.0625rem/1.6 var(--ui);
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--ink); text-underline-offset: 0.18em; text-decoration-thickness: 1px; }
a:hover { color: var(--ink-strong); }
:focus-visible { outline: 2px solid var(--ink); outline-offset: 3px; border-radius: 4px; }
.wrap { width: min(72rem, 100% - 2.5rem); margin-inline: auto; }

/* ---------- header ---------- */

.top { padding-block: 1.1rem; }
.top .wrap { display: flex; align-items: center; gap: 1.5rem; }
.brand { display: inline-flex; align-items: center; gap: 0.5rem; color: var(--text); text-decoration: none; font: 650 1.15rem/1 var(--display); letter-spacing: -0.015em; }
.brand svg { width: 28px; height: 28px; fill: none; stroke: var(--ink); stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; }
.top nav { margin-left: auto; display: flex; gap: 1.4rem; flex-wrap: wrap; justify-content: flex-end; }
.top nav a { color: var(--muted); text-decoration: none; font-size: 0.95rem; }
.top nav a:hover { color: var(--text); }
.top nav .lang { color: var(--text); font-weight: 600; }

/* ---------- hero: the sheet ---------- */

.hero { padding-block: 1.5rem 4.5rem; }
.sheet {
  position: relative;
  background: #fff;
  color: #1f232a;
  border-radius: 3px;
  box-shadow: var(--sheet-shadow);
  padding: clamp(1.75rem, 5vw, 4rem) clamp(1.5rem, 6vw, 5rem) clamp(2rem, 5vw, 3.5rem);
  font-family: var(--printed);
}
.sheet-head { display: flex; justify-content: space-between; gap: 1rem; font-size: 0.8rem; color: #6a717c; border-bottom: 1px solid #d5d9df; padding-bottom: 0.7rem; margin-bottom: clamp(1.5rem, 4vw, 2.75rem); }
.sheet h1 {
  margin: 0;
  font: 700 clamp(2.5rem, 7.2vw, 5.4rem)/0.98 var(--printed);
  letter-spacing: -0.035em;
  max-width: 13ch;
}
.sheet .lede { margin: 1.4rem 0 0; max-width: 40rem; font-size: clamp(1.05rem, 1.6vw, 1.25rem); line-height: 1.5; color: #333944; }

.sheet-fields { margin-top: clamp(1.75rem, 4vw, 2.75rem); display: grid; grid-template-columns: 1fr minmax(15rem, 22rem); gap: 1.25rem 2.5rem; align-items: end; }
.label { display: block; font-size: 0.78rem; color: #4c535e; margin-bottom: 0.4rem; }
.checks { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 0.6rem 1.6rem; }
.checks li { display: inline-flex; align-items: center; gap: 0.55rem; font-size: 1rem; }
.box { width: 1.3rem; height: 1.3rem; border: 1.5px solid #8a919c; border-radius: 2px; display: inline-grid; place-items: center; flex: none; }
.box svg { width: 1.15rem; height: 1.15rem; fill: none; stroke: #2340b0; stroke-width: 2.6; stroke-linecap: round; stroke-linejoin: round; }

.sig { border: 1.5px solid #8a919c; border-radius: 2px; height: 6.2rem; padding: 0.3rem 0.8rem; display: grid; place-items: center; }
.sig svg { width: 100%; height: 100%; fill: none; stroke: #2340b0; stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round; }

/* The one moment of motion: the paraphe draws itself once. */
.sig path { stroke-dasharray: 1; stroke-dashoffset: 0; }
@media (prefers-reduced-motion: no-preference) {
  .sig path { stroke-dashoffset: 1; animation: draw 1.5s cubic-bezier(0.55, 0.1, 0.4, 1) 0.5s forwards; }
  .sig path + path { animation-duration: 0.5s; animation-delay: 1.95s; }
}
@keyframes draw { to { stroke-dashoffset: 0; } }

.get { margin-top: 2rem; display: flex; flex-wrap: wrap; align-items: center; gap: 1rem 1.75rem; }
.btn {
  display: inline-flex; align-items: center; gap: 0.6rem;
  padding: 0.85rem 1.35rem; border-radius: 9px;
  background: var(--ink); color: #fff; text-decoration: none;
  font: 600 1.05rem/1 var(--ui);
}
.btn:hover { background: var(--ink-strong); color: #fff; }
@media (prefers-color-scheme: dark) { .btn, .btn:hover { color: #0f1530; } }
.btn svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.get .meta { color: var(--muted); font-size: 0.92rem; }
.get .alt { font-weight: 600; }

/* ---------- sections ---------- */

section { padding-block: clamp(3rem, 7vw, 5.5rem); }
section + section { border-top: 1px solid var(--rule); }
h2 { margin: 0 0 1.25rem; font: 700 clamp(1.7rem, 3.4vw, 2.5rem)/1.1 var(--display); letter-spacing: -0.025em; max-width: 24ch; }
h3 { margin: 0 0 0.35rem; font: 650 1.1rem/1.3 var(--display); }
p { margin: 0 0 1rem; max-width: 66ch; }
.muted { color: var(--muted); }

/* What it does: the screenshot, then the tools as the dock shows them. */
.shot { margin: 0 0 2.75rem; }
.shot img { border-radius: 10px; border: 1px solid var(--rule); box-shadow: var(--sheet-shadow); }
.shot figcaption { margin-top: 0.8rem; font-size: 0.9rem; color: var(--muted); }
.tools { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(16rem, 1fr)); gap: 1.75rem 2.5rem; }
.tools li { display: grid; grid-template-columns: 2.5rem 1fr; gap: 0 0.9rem; }
.tools .icon { grid-row: span 2; width: 2.5rem; height: 2.5rem; border-radius: 9px; background: var(--ink-soft); display: grid; place-items: center; }
.tools .icon svg { width: 22px; height: 22px; fill: none; stroke: var(--ink); stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.tools p { margin: 0; font-size: 0.98rem; color: var(--muted); }
.also { margin-top: 2.25rem; }

/* Dates by region: a real table, because it is one. */
.formats { border-collapse: collapse; margin: 1.25rem 0 0; font-variant-numeric: tabular-nums; min-width: min(30rem, 100%); }
.formats th, .formats td { text-align: left; padding: 0.55rem 1.5rem 0.55rem 0; border-bottom: 1px solid var(--rule); }
.formats th { font-weight: 600; font-size: 0.85rem; color: var(--muted); }

/* Privacy */
.facts { list-style: none; margin: 1.5rem 0 0; padding: 0; display: grid; gap: 0.75rem; max-width: 46rem; }
.facts li { display: grid; grid-template-columns: 1.4rem 1fr; gap: 0.75rem; align-items: start; }
.facts svg { width: 1.3rem; height: 1.3rem; margin-top: 0.2rem; fill: none; stroke: var(--ink); stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round; }

/* Download */
.downloads { display: grid; grid-template-columns: 1.4fr 1fr; gap: 2.5rem 4rem; align-items: start; }
.steps { margin: 1rem 0 1.25rem; padding-left: 1.4rem; }
.steps li { margin-bottom: 0.45rem; padding-left: 0.25rem; }
.steps li::marker { color: var(--ink); font-weight: 700; }
.note { font-size: 0.95rem; color: var(--muted); }
.side > div + div { margin-top: 2rem; }
kbd { font: 600 0.85em var(--ui); padding: 0.05rem 0.35rem; border: 1px solid var(--rule); border-bottom-width: 2px; border-radius: 4px; }
code { font-size: 0.92em; }

/* Limits */
.limits { margin: 0; padding-left: 1.2rem; max-width: 46rem; }
.limits li { margin-bottom: 0.5rem; }

/* A note from the author, signed like the rest. */
.letter { max-width: 40rem; }
.letter p { font-size: 1.15rem; }
.letter .sign { display: flex; align-items: center; gap: 0.9rem; margin-top: 1.25rem; color: var(--muted); font-size: 0.95rem; }
.letter .sign svg { width: 4.5rem; height: 2.2rem; fill: none; stroke: var(--ink); stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; }

/* ---------- footer ---------- */

footer { border-top: 1px solid var(--rule); background: var(--desk-2); padding-block: 1.75rem 2.5rem; font-size: 0.9rem; color: var(--muted); }
footer .wrap { display: flex; flex-wrap: wrap; gap: 0.5rem 1.75rem; }
footer a { color: var(--muted); }

/* ---------- small screens ---------- */

@media (max-width: 52rem) {
  .sheet-fields { grid-template-columns: 1fr; }
  .downloads { grid-template-columns: 1fr; }
  .top nav .hide-sm { display: none; }
}
@media (max-width: 30rem) {
  .sheet-head span + span { display: none; }
  .formats th, .formats td { padding-right: 0.9rem; }
}
