/* Ported from site/index.html. One dark universe, taken from the app: graphite, white, photos. */
@font-face {
  font-family: 'Unbounded';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url('/fonts/unbounded-latin-500.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
:root {
  color-scheme: dark;
  --bg: #111214;
  --surface: #1B1C20;
  --raised: #25272C;
  --text: #FFFFFF;
  --muted: rgba(255, 255, 255, 0.66);
  --line: rgba(255, 255, 255, 0.1);
  --ok: #30D158;
  --display: 'Unbounded', ui-sans-serif, system-ui, sans-serif;
  --body: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
}
* { box-sizing: border-box; }
html { background: var(--bg); interpolate-size: allow-keywords; }
::selection { background: rgba(255, 255, 255, 0.88); color: var(--bg); }
body { margin: 0; background: var(--bg); color: var(--text); font: 400 17px/1.55 var(--body); -webkit-font-smoothing: antialiased; }
a { color: var(--text); text-underline-offset: 3px; }
a:focus-visible, button:focus-visible, summary:focus-visible { outline: 2px solid var(--text); outline-offset: 3px; border-radius: 6px; }
.wrap { max-width: 1080px; margin: 0 auto; padding: 0 24px; }
header .wrap { display: flex; align-items: center; justify-content: space-between; gap: 16px 24px; flex-wrap: wrap; padding-top: 24px; padding-bottom: 24px; }
.brand { font: 500 22px/1.3 var(--display); letter-spacing: -0.01em; text-decoration: none; }
.brand span { display: inline-block; }
/* Per-letter blur of the wordmark (was inline styles; moved here for the CSP). */
.brand .b1 { filter: blur(0.023em); }
.brand .b2 { filter: blur(0.05em); }
.brand .b3 { filter: blur(0.086em); }
.brand .b4 { filter: blur(0.132em); }
.brand .b5 { filter: blur(0.19em); }
nav { display: flex; gap: 4px 24px; flex-wrap: wrap; }
nav a { font-size: 15px; color: var(--muted); text-decoration: none; padding: 10px 0; }
nav a:hover, nav a[aria-current="page"] { color: var(--text); }
.lang { display: flex; gap: 2px; padding: 3px; border-radius: 10px; background: var(--surface); }
.lang a { display: inline-flex; align-items: center; justify-content: center; min-width: 44px; min-height: 36px; border-radius: 8px; color: var(--muted); font: 600 13px var(--body); text-decoration: none; }
.lang a[aria-current="true"] { background: var(--raised); color: var(--text); }
.head-right { display: flex; align-items: center; gap: 8px 24px; flex-wrap: wrap; }
h1, h2, h3 { text-wrap: balance; margin: 0; font-weight: 600; letter-spacing: -0.02em; }
h1 { font-size: clamp(34px, 5.2vw, 56px); line-height: 1.06; }
h2 { font-size: clamp(24px, 3vw, 32px); line-height: 1.15; }
h3 { font-size: 17px; line-height: 1.35; letter-spacing: 0; }
p { margin: 0; }
.muted { color: var(--muted); }
.hero { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr); gap: 48px; align-items: center; padding: 40px 0 72px; }
.hero-text { display: flex; flex-direction: column; gap: 20px; align-items: flex-start; }
.hero-text p { max-width: 34em; }
.cta { display: inline-flex; align-items: center; min-height: 52px; padding: 0 22px; border-radius: 14px; background: var(--text); color: var(--bg); font-weight: 600; text-decoration: none; }
.small { font-size: 14px; line-height: 1.45; }
.split { position: relative; aspect-ratio: 1; border-radius: 20px; overflow: hidden; background: var(--surface); }
.split img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; display: block; }
.split .half { position: absolute; inset: 0; overflow: hidden; clip-path: inset(0 0 0 50%); }
.split .half img { filter: blur(22px); transform: scale(1.1); }
.split .half::after { content: ""; position: absolute; inset: 0; background: rgba(17, 18, 20, 0.4); }
.split .seam { position: absolute; inset: 0; pointer-events: none; }
.split .bar { position: absolute; top: 0; left: calc(50% - 1px); width: 2px; height: 100%; background: var(--text); box-shadow: 0 0 18px rgba(255, 255, 255, 0.35); }
.split .knob { position: absolute; top: calc(50% - 28px); left: calc(50% - 28px); width: 56px; height: 56px; border-radius: 50%; background: var(--text); color: var(--bg); display: flex; align-items: center; justify-content: center; box-shadow: 0 6px 24px rgba(0, 0, 0, 0.35); }
.split .shackle { transform-box: fill-box; }
.split .tag { position: absolute; bottom: 14px; padding: 5px 10px; border-radius: 9px; background: rgba(0, 0, 0, 0.66); font-size: 14px; font-weight: 600; }
.split .tag.l { left: 14px; }
.split .tag.r { right: 14px; }
section { padding: 56px 0; border-top: 1px solid var(--line); }
.section-head { display: flex; flex-direction: column; gap: 10px; margin-bottom: 32px; max-width: 40em; }
.steps { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(260px, 100%), 1fr)); gap: 32px; }
.step { display: flex; flex-direction: column; gap: 10px; }
.step svg { margin-bottom: 6px; }
.table { overflow-x: auto; }
table { width: 100%; min-width: 560px; border-collapse: collapse; }
th, td { text-align: left; vertical-align: top; padding: 16px 16px 16px 0; border-bottom: 1px solid var(--line); }
th { font-size: 14px; font-weight: 400; color: var(--muted); }
td:first-child { font-weight: 600; width: 26%; }
td.dim { color: var(--muted); }
.dot { display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: var(--ok); margin-right: 8px; }
.features { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(230px, 100%), 1fr)); gap: 16px; }
.feature { padding: 22px; border-radius: 16px; background: var(--surface); display: flex; flex-direction: column; gap: 8px; }
.feature svg { margin-bottom: 8px; }
details { border-bottom: 1px solid var(--line); }
summary { cursor: pointer; list-style: none; padding: 18px 0; font-weight: 600; display: flex; justify-content: space-between; gap: 16px; }
summary::-webkit-details-marker { display: none; }
summary::after { content: "+"; color: var(--muted); font-weight: 400; }
details[open] summary::after { content: "−"; }
details p { padding: 0 0 20px; max-width: 42em; color: var(--muted); }
.doc { max-width: 720px; padding: 32px 0 80px; }
.doc h1 { font-size: clamp(30px, 4.4vw, 44px); }
.doc .meta { margin-top: 12px; font-size: 14px; color: var(--muted); }
.doc h2 { font-size: 22px; line-height: 1.25; margin: 40px 0 12px; letter-spacing: -0.01em; }
.doc p, .doc li { color: rgba(255, 255, 255, 0.84); }
.doc p + p, .doc ul + p, .doc p + ul { margin-top: 12px; }
.doc ul { margin: 0; padding-left: 22px; display: flex; flex-direction: column; gap: 8px; }
.note { margin-top: 24px; padding: 16px 18px; border-radius: 14px; background: var(--surface); font-size: 15px; line-height: 1.5; color: var(--muted); }
.note strong, .todo { color: var(--text); }
.todo { background: var(--raised); border-radius: 6px; padding: 1px 6px; font-size: 0.92em; white-space: nowrap; }
footer { border-top: 1px solid var(--line); }
footer .wrap { display: flex; justify-content: space-between; gap: 16px 32px; flex-wrap: wrap; padding-top: 28px; padding-bottom: 40px; font-size: 14px; color: var(--muted); }
footer nav a { padding: 0; font-size: 14px; }
@media (max-width: 760px) {
  .hero { grid-template-columns: minmax(0, 1fr); gap: 32px; padding: 16px 0 48px; }
  section { padding: 44px 0; }
}

/* ---------------------------------------------------------------------------
   Motion. CSS only (the CSP forbids scripts). Every element is visible in its
   final state by default: animations only run "from" a hidden state, so a
   browser without support simply shows the page.
   --------------------------------------------------------------------------- */
:root {
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --ease-sweep: cubic-bezier(0.72, 0, 0.18, 1);
}

/* Feedback: always on (colour and opacity only, fine under reduced motion). */
nav a, .lang a, footer nav a { transition: color 0.2s ease, background-color 0.25s ease; }
.cta { transition: background-color 0.2s ease, transform 0.15s ease, box-shadow 0.3s ease; }
a.cta:hover { box-shadow: 0 8px 30px rgba(255, 255, 255, 0.16); }
a.cta:active { transform: scale(0.97); }
.feature { transition: background-color 0.3s ease; }
.feature:hover { background: var(--raised); }
summary::after { transition: transform 0.3s var(--ease-out), color 0.2s ease; }
summary:hover::after { color: var(--text); }
details[open] summary::after { content: "+"; transform: rotate(45deg); }

/* FAQ: the answer unfolds instead of jumping (Chromium; elsewhere it opens at once). */
details::details-content { block-size: 0; overflow: clip; opacity: 0; transition: block-size 0.35s var(--ease-out), opacity 0.3s ease, content-visibility 0.35s allow-discrete; }
details[open]::details-content { block-size: auto; opacity: 1; }

/* Page to page (and EN ⇄ FR): the header stays put, the content cross-fades. */
@view-transition { navigation: auto; }
header { view-transition-name: site-header; }
::view-transition-old(root) { animation: 0.18s ease both vt-out; }
::view-transition-new(root) { animation: 0.32s var(--ease-out) both vt-in; }
@keyframes vt-out { to { opacity: 0; } }
@keyframes vt-in { from { opacity: 0; } }

@media (prefers-reduced-motion: no-preference) {
  ::view-transition-old(root) { animation-name: vt-out-move; }
  ::view-transition-new(root) { animation-name: vt-in-move; }
  @keyframes vt-out-move { to { opacity: 0; transform: translateY(-6px); } }
  @keyframes vt-in-move { from { opacity: 0; transform: translateY(10px); } }

  /* Wordmark: the letters slip one by one into the enclave. Hover brings them back into focus. */
  .brand .b1, .brand .b2, .brand .b3, .brand .b4, .brand .b5 { animation: 0.9s var(--ease-out) both letter-blur; transition: filter 0.45s var(--ease-out); }
  .brand .b1 { animation-delay: 0.15s; }
  .brand .b2 { animation-delay: 0.25s; }
  .brand .b3 { animation-delay: 0.35s; }
  .brand .b4 { animation-delay: 0.45s; }
  .brand .b5 { animation-delay: 0.55s; }
  .brand:hover span, .brand:focus-visible span { filter: none; }
  @keyframes letter-blur { from { filter: blur(0); } }

  /* Hero text comes into focus. */
  .hero-text > *, .doc > h1, .doc > .meta { animation: 0.8s var(--ease-out) both focus-in; }
  .hero-text > :nth-child(2) { animation-delay: 0.08s; }
  .hero-text > :nth-child(3) { animation-delay: 0.16s; }
  .hero-text > :nth-child(4) { animation-delay: 0.24s; }
  .doc > .meta { animation-delay: 0.08s; }
  @keyframes focus-in { from { opacity: 0; transform: translateY(14px); filter: blur(6px); } }

  /* The focal moment: the seam sweeps in from the right, the blurred half
     (what the server sees) follows it, and the padlock clicks shut. */
  .split .half { animation: 1.15s var(--ease-sweep) 0.35s both seal; }
  .split .seam { animation: 1.15s var(--ease-sweep) 0.35s both seam-in; }
  .split .shackle { animation: 0.22s cubic-bezier(0.55, 0, 1, 0.45) 1.42s both shackle-close; }
  .split .knob { animation: 0.45s var(--ease-out) 1.45s both knob-press; }
  .split .tag { animation: 0.6s var(--ease-out) both tag-in; }
  .split .tag.l { animation-delay: 1.5s; }
  .split .tag.r { animation-delay: 1.62s; }
  @keyframes seal { from { clip-path: inset(0 0 0 100%); } }
  @keyframes seam-in { from { transform: translateX(50%); } }
  @keyframes shackle-close { from { transform: translateY(-3px); } }
  @keyframes knob-press { 40% { transform: scale(0.9); } }
  @keyframes tag-in { from { opacity: 0; transform: translateY(8px); } }
  .split img:first-child { animation: 1.6s var(--ease-out) both settle; }
  @keyframes settle { from { transform: scale(1.06); } }
}

/* Scroll-driven, where supported (Chromium, Safari 26). Elsewhere the page is simply static. */
@supports (animation-timeline: view()) {
  @media (prefers-reduced-motion: no-preference) {
    /* How it works: each icon draws itself as it enters. */
    .step svg :is(path, rect:not([fill])) { stroke-dasharray: 100; animation: draw linear both; animation-timeline: view(); animation-range: entry 10% cover 40%; }
    .step svg rect[fill] { animation: pop linear both; animation-timeline: view(); animation-range: entry 60% cover 45%; transform-box: fill-box; transform-origin: center; }
    .step h3, .step p { animation: rise linear both; animation-timeline: view(); animation-range: entry 0% cover 30%; }
    @keyframes draw { from { stroke-dashoffset: 100; } to { stroke-dashoffset: 0; } }
    @keyframes pop { from { opacity: 0; transform: scale(0.2); } }
    @keyframes rise { from { opacity: 0; transform: translateY(18px); } }

    /* What we see: rows resolve out of the blur, one after the other. */
    tbody tr { animation: unblur linear both; animation-timeline: view(); animation-range: entry 0% cover 25%; }
    @keyframes unblur { from { opacity: 0; filter: blur(8px); } }

    /* Features: cards lift in, staggered by column via the range. */
    .feature { animation: lift linear both; animation-timeline: view(); animation-range: entry 0% cover 28%; }
    .feature:nth-child(2) { animation-range: entry 8% cover 34%; }
    .feature:nth-child(3) { animation-range: entry 16% cover 40%; }
    .feature:nth-child(4) { animation-range: entry 24% cover 46%; }
    @keyframes lift { from { opacity: 0; transform: translateY(28px) scale(0.97); } }

    .section-head h2 { animation: rise linear both; animation-timeline: view(); animation-range: entry 0% cover 25%; }
  }
}
