@font-face {
  font-family: "IBM Plex Sans";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("/fonts/ibm-plex-sans-latin-400-normal.woff2") format("woff2");
}
@font-face {
  font-family: "IBM Plex Sans";
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url("/fonts/ibm-plex-sans-latin-600-normal.woff2") format("woff2");
}

/* Dark ground and blue from the app icon and its dark interface. The pictures bring the colour. */
:root, .dark {
  --g0: #111113;
  --g1: #19191c;
  --g2: #232327;
  --ink: #f2f2f4;
  --muted: #a9a9b1;
  --accent: #6ba7ff;
  --accent-hover: #9cc2ff;
  --btn: #2f6df0;
  --btn-hover: #2a5fd6;
  --on-btn: #ffffff;
}

@media (prefers-color-scheme: light) {
  :root {
    --g0: #f7f7f8;
    --g1: #ececef;
    --g2: #e0e0e5;
    --ink: #151517;
    --muted: #55555d;
    --accent: #1a55c9;
    --accent-hover: #123f9a;
    --btn: #1f5fe0;
    --btn-hover: #174dba;
  }
}

:root {
  color-scheme: dark light;
  --s1: 8px;
  --s2: 16px;
  --s3: 24px;
  --s4: 32px;
  --s5: 48px;
  --s6: 64px;
  --s7: 96px;
  --label: 220px;
  --sans: "IBM Plex Sans", sans-serif;
}

* { box-sizing: border-box; }
html { scroll-padding-top: 72px; }

body {
  margin: 0;
  background: var(--g0);
  color: var(--ink);
  font: 400 17px/1.6 var(--sans);
  -webkit-text-size-adjust: 100%;
}

img { display: block; max-width: 100%; height: auto; }
a { color: var(--accent); text-underline-offset: 3px; }
a:hover { color: var(--accent-hover); }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

h1, h2 { margin: 0; font-family: var(--sans); font-weight: 600; }
h1 { font-size: 64px; line-height: 1.05; letter-spacing: -0.02em; }
h2 { font-size: 36px; line-height: 1.15; letter-spacing: -0.01em; }
p { margin: 0 0 var(--s2); }

/* One container for the bar, hero, rows, download and footer */
.wrap { max-width: 1344px; margin: 0 auto; padding: 0 var(--s5); }

/* Top bar: the hero's own dark ground */
.bar { position: sticky; top: 0; z-index: 2; background: var(--g0); color: var(--ink); }
.bar-in { display: flex; align-items: center; justify-content: space-between; gap: var(--s3); min-height: 56px; }
.brand { display: block; line-height: 0; }
.bar nav { display: flex; gap: 0 var(--s4); font-size: 15px; }
.bar nav a { display: block; padding: 12px 0; color: var(--ink); text-decoration: none; }
.bar nav a:hover { color: var(--accent); text-decoration: underline; }

/* First screen: name, line, buttons, then the result and the app */
.hero { background: var(--g0); color: var(--ink); padding: var(--s4) 0 var(--s7); }
.hero h1 { margin-bottom: var(--s2); }
.lead { max-width: 640px; margin: 0 0 var(--s3); font-size: 22px; line-height: 1.45; }
.actions { display: flex; flex-wrap: wrap; gap: var(--s2); margin: 0 0 var(--s5); }

.button {
  display: inline-block;
  min-height: 48px;
  padding: 11px var(--s3);
  background: var(--btn);
  color: var(--on-btn);
  font-weight: 600;
  text-decoration: none;
}
.button:hover { background: var(--btn-hover); color: var(--on-btn); }

.compare, .appwin, .demo { margin: 0 0 var(--s6); }
.compare figcaption { margin-top: var(--s2); font-size: 15px; color: var(--muted); }
.appwin { margin-bottom: 0; }
.appwin img { width: 100%; height: auto; }

/* Before and after split */
.cmp {
  --pos: 50%;
  position: relative;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background: #000;
  cursor: ew-resize;
  touch-action: pan-y;
  user-select: none;
  -webkit-user-select: none;
}
.cmp img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; pointer-events: none; -webkit-user-drag: none; }
.img-before { clip-path: inset(0 calc(100% - var(--pos)) 0 0); }
.line { position: absolute; top: 0; bottom: 0; left: var(--pos); width: 2px; margin-left: -1px; background: #fff; pointer-events: none; }
.line::after { content: ""; position: absolute; top: 50%; left: -5px; width: 12px; height: 64px; margin-top: -32px; background: #fff; }
.tag { position: absolute; top: var(--s2); padding: 4px 12px; background: #000; color: #fff; font-size: 15px; font-weight: 600; pointer-events: none; }
.tag-before { left: var(--s2); }
.tag-after { right: var(--s2); }
.cmp:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; }

.demo video { display: block; width: 100%; height: auto; aspect-ratio: 16 / 9; background: #000; }

/* Rows: label column and text column share one baseline */
.band { padding: var(--s7) 0; }
.band.a { background: var(--g1); }
.band.b { background: var(--g0); }
.rows { margin: 0; }
.rows > div { display: grid; grid-template-columns: var(--label) minmax(0, 1fr); gap: var(--s4); align-items: baseline; margin-bottom: var(--s5); }
.rows > div:last-child { margin-bottom: 0; }
.rows dt { font-weight: 600; }
.rows dd { margin: 0; }
.rows.big dt { font-size: 36px; line-height: 1.15; letter-spacing: -0.01em; }
.rows.big dd { font-size: 22px; line-height: 1.45; max-width: 640px; }

.cols { display: grid; grid-template-columns: var(--label) minmax(0, 1fr); gap: var(--s4); align-items: start; }
.get > div { margin-bottom: var(--s3); align-items: center; }
.get dd { display: flex; flex-wrap: wrap; align-items: center; gap: var(--s1) var(--s3); }
.req { color: var(--muted); font-size: 15px; }
.cols p { margin: var(--s4) 0 0; }

/* Footer */
.foot { background: var(--g2); padding: var(--s3) 0; font-size: 15px; }
.foot nav { display: flex; flex-wrap: wrap; gap: 0 var(--s4); }
.foot nav a { display: block; padding: 8px 0; }
.foot p { margin: var(--s1) 0 0; color: var(--muted); }

/* Narrow windows */
@media (max-width: 900px) {
  .wrap { padding: 0 var(--s2); }
  h1 { font-size: 40px; }
  h2 { font-size: 28px; }
  .lead { font-size: 17px; }
  .hero { padding: var(--s3) 0 var(--s6); }
  .actions { margin-bottom: var(--s4); }
  .compare, .demo { margin-bottom: var(--s5); }
  .tag { top: var(--s1); padding: 2px 8px; }
  .tag-before { left: var(--s1); }
  .tag-after { right: var(--s1); }
  .band { padding: var(--s6) 0; }
  .rows > div { grid-template-columns: minmax(0, 1fr); gap: var(--s1); margin-bottom: var(--s4); }
  .rows.big dt { font-size: 28px; }
  .rows.big dd { font-size: 17px; }
  .cols { grid-template-columns: minmax(0, 1fr); gap: var(--s3); }
  .cols p { margin-top: var(--s2); }
}
