/* Fonts are served from the site itself: remote fonts would need a consent banner (see CLAUDE.md). */
@font-face {
  font-family: "Barlow";
  src: url("fonts/barlow-latin-400-normal.woff2") format("woff2");
  font-weight: 400;
  font-display: swap;
}
@font-face {
  font-family: "Barlow";
  src: url("fonts/barlow-latin-500-normal.woff2") format("woff2");
  font-weight: 500;
  font-display: swap;
}
@font-face {
  font-family: "Barlow";
  src: url("fonts/barlow-latin-600-normal.woff2") format("woff2");
  font-weight: 600;
  font-display: swap;
}
@font-face {
  font-family: "Barlow Condensed";
  src: url("fonts/barlow-condensed-latin-700-normal.woff2") format("woff2");
  font-weight: 700;
  font-display: swap;
}

:root {
  --ink: #111315;
  --muted: #6a6e75;
  --line: #e4e6ea;
  --soft: #f5f6f7;
  --paper: #ffffff;
  --green: #22a55b;
  /* Set on <body> and changed by the preview: the page wears the colour of the chosen style. */
  --accent: #2f5bff;

  --text: "Barlow", system-ui, sans-serif;
  /* One easing for everything that moves: quick start, soft landing. */
  --ease: cubic-bezier(0.16, 1, 0.3, 1);

  --gutter: clamp(1.25rem, 5vw, 3rem);
  --width: 76rem;
  --section: clamp(5.5rem, 13vw, 10.5rem);
}

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

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--text);
  font-size: 1.125rem;
  line-height: 1.55;
  -webkit-text-size-adjust: 100%;
  -webkit-font-smoothing: antialiased;
}

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

ul,
ol {
  list-style: none;
}

h1,
h2,
h3 {
  font-weight: 600;
  line-height: 1.05;
  letter-spacing: -0.02em;
}

h2 {
  font-size: clamp(2.2rem, 5.4vw, 3.9rem);
  letter-spacing: -0.03em;
}

a {
  color: inherit;
  text-decoration-color: var(--accent);
  text-decoration-thickness: 2px;
  text-underline-offset: 0.22em;
}

button {
  font: inherit;
  color: inherit;
}

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

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

.top,
.foot,
main > section,
.legal {
  max-width: var(--width);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

main > section {
  margin-top: var(--section);
  scroll-margin-top: 2rem;
}

/* The small coloured dot: Patrick's mark. It takes the colour of the chosen style. */
.dot {
  display: inline-block;
  width: 0.5em;
  height: 0.5em;
  border-radius: 50%;
  background: var(--accent);
  transition: background-color 0.3s ease;
}

/* Section opening: heading and one line of text */
.intro {
  margin-bottom: clamp(2rem, 5vw, 3.25rem);
}

.intro p {
  margin-top: 1rem;
  max-width: 40ch;
  color: var(--muted);
  font-size: clamp(1.15rem, 2vw, 1.3rem);
}

/* Things come in once when scrolled into view. Without the script they are simply visible. */
.js [data-reveal] {
  opacity: 0;
  transform: translateY(1.5rem);
  transition: opacity 0.8s ease, transform 0.8s var(--ease);
}

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

.js .detail:nth-child(2)[data-reveal] {
  transition-delay: 0.1s;
}

.js .detail:nth-child(3)[data-reveal] {
  transition-delay: 0.2s;
}

/* Buttons */

.button {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.8rem 1.4rem;
  border: 1px solid var(--ink);
  border-radius: 999px;
  background: var(--ink);
  color: var(--paper);
  font-size: 1rem;
  font-weight: 500;
  line-height: 1.3;
  text-decoration: none;
  cursor: pointer;
  transition: background-color 0.2s ease, border-color 0.2s ease, transform 0.2s var(--ease);
}

.button:hover {
  border-color: var(--accent);
  background: var(--accent);
}

.button:active {
  transform: scale(0.97);
}

.button--plain {
  border-color: var(--line);
  background: var(--paper);
  color: var(--ink);
}

.button--plain:hover {
  border-color: var(--ink);
  background: var(--paper);
}

.button--small {
  padding: 0.45rem 0.9rem;
  font-size: 0.9rem;
}

/* Header */

.top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  padding-block: 1.5rem;
}

.top__name {
  font-size: 1.15rem;
  font-weight: 600;
  text-decoration: none;
}

.top__name .dot {
  margin-left: 0.3em;
}

.top__nav {
  display: flex;
  gap: 1.75rem;
  font-size: 1rem;
  font-weight: 500;
}

.top__nav a {
  text-decoration: none;
}

.top__nav a:hover {
  text-decoration: underline;
}

/* Hero: headline and the sentence on one side, the browser window on the other */

main > .hero {
  display: grid;
  gap: 3rem;
  margin-top: clamp(2rem, 6vw, 4.5rem);
}

.hero h1 {
  max-width: 15ch;
  font-size: clamp(2.4rem, 4.6vw, 3.9rem);
  line-height: 1.04;
  letter-spacing: -0.03em;
}

.line {
  display: block;
}

/* The second sentence of the headline is set back. */
.line--soft {
  color: var(--muted);
}

.hero__lead {
  margin-top: 1.25rem;
  color: var(--muted);
  font-size: clamp(1.15rem, 2vw, 1.3rem);
}

.hero__lead b {
  color: var(--ink);
  font-weight: 600;
}

/* On load the headline rises line by line, then the rest follows and the window comes in. */
.js .line,
.js .hero__lead,
.js .try {
  animation: rise 0.9s var(--ease) backwards;
}

.js .line--soft {
  animation-delay: 0.1s;
}

.js .hero__lead {
  animation-delay: 0.2s;
}

.js .try {
  animation-delay: 0.3s;
}

.js .window {
  animation: enter 1.1s 0.25s var(--ease) backwards;
}

@keyframes rise {
  from {
    opacity: 0;
    transform: translateY(1.2rem);
  }
}

@keyframes enter {
  from {
    opacity: 0;
    transform: translateY(2.5rem) scale(0.96);
  }
}

.try {
  margin-top: clamp(2.25rem, 5vw, 3.5rem);
}

.try__label {
  color: var(--muted);
  font-size: 1rem;
}

.try__sentence {
  margin-top: 0.75rem;
  font-size: clamp(1.5rem, 2.9vw, 2.1rem);
  font-weight: 500;
  line-height: 1.5;
  letter-spacing: -0.015em;
}

/* The two blanks: editable text, underlined in the accent colour, wrapping like any other words. */
.field {
  font-weight: 600;
  text-decoration: underline;
  text-decoration-color: var(--accent);
  text-decoration-thickness: 3px;
  text-underline-offset: 0.2em;
  cursor: text;
  transition: text-decoration-color 0.3s ease;
}

.field:focus {
  outline: none;
  background: var(--soft);
  box-decoration-break: clone;
  -webkit-box-decoration-break: clone;
}

/* An emptied blank shows the example again, greyed, so there is always something to click on. */
.field:empty::before {
  content: attr(data-placeholder);
  color: var(--muted);
  font-weight: 500;
}

.try__actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.75rem 1.25rem;
  margin-top: 2rem;
}

.try__style {
  color: var(--muted);
  font-size: 1rem;
}

.try > .button {
  margin-top: 1rem;
}

.try__call {
  margin-top: 1rem;
  color: var(--muted);
  font-size: 1rem;
}

.try__call a {
  color: var(--ink);
  font-weight: 500;
  white-space: nowrap;
}

/* The five styles as colour swatches; the chosen one gets a ring. */
.swatches {
  display: flex;
  gap: 0.15rem;
}

/* The button is 30px across so it is easy to hit; the dot inside it stays small. */
.swatch {
  width: 1.9rem;
  height: 1.9rem;
  padding: 0.38rem;
  border: 0;
  border-radius: 50%;
  background: var(--c) content-box;
  cursor: pointer;
  transition: box-shadow 0.2s ease, transform 0.2s var(--ease);
}

.swatch:hover {
  transform: scale(1.12);
}

.swatch[aria-pressed="true"] {
  box-shadow: inset 0 0 0 2px var(--ink);
}

/* Browser window. It leans slightly towards the pointer. */

.window {
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--paper);
  box-shadow: 0 2px 6px rgba(17, 19, 21, 0.04), 0 40px 80px -50px rgba(17, 19, 21, 0.4);
  transform: perspective(1400px) rotateX(calc(var(--ty, 0) * -1deg)) rotateY(calc(var(--tx, 0) * 1deg));
  transition: transform 0.35s ease-out;
}

.window__bar {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.65rem 0.9rem;
  border-bottom: 1px solid var(--line);
  background: #fafbfb;
}

.window__bar i {
  width: 0.6rem;
  height: 0.6rem;
  border-radius: 50%;
  background: #dcdfe3;
}

.window__bar span {
  margin-inline: auto;
  padding: 0.15rem 1rem;
  border-radius: 999px;
  background: #eff1f3;
  color: var(--muted);
  font-size: 0.8rem;
  transform: translateX(-1.1rem);
}

.window__view {
  aspect-ratio: 4 / 4.6;
  container-type: inline-size;
}

/* The generated site. All sizes are relative to its container (cqw), so it scales with it. */

.site {
  /* --title is the headline size of the layout, --fit shrinks it for long text (set by the script). */
  --title: 11cqw;
  position: relative;
  display: grid;
  grid-template-rows: auto 1fr;
  height: 100%;
  overflow: hidden;
  transition: background-color 0.4s ease, color 0.4s ease;
}

.site__nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 5cqw 6cqw 0;
}

.site__brand {
  font-size: 4.4cqw;
  font-weight: 600;
}

.site__links {
  display: none;
  gap: 2.6cqw;
  font-size: 1.9cqw;
}

.site__links i {
  font-style: normal;
  opacity: 0.7;
}

.site__main {
  display: grid;
  align-content: center;
  gap: 6cqw;
  padding: 4cqw 6cqw 7cqw;
}

.site__title {
  font-size: calc(var(--title) * var(--fit, 1));
  font-weight: 600;
  line-height: 1;
  letter-spacing: -0.02em;
  hyphens: auto;
  overflow-wrap: break-word;
  text-wrap: balance;
}

.site__sub {
  margin-top: 3cqw;
  font-size: 4cqw;
  opacity: 0.75;
}

.site__btn {
  display: inline-block;
  margin-top: 4.5cqw;
  padding: 2.4cqw 4.4cqw;
  font-size: 3.6cqw;
  font-weight: 600;
  line-height: 1.2;
}

.site__art {
  position: relative;
  justify-self: end;
  width: 46cqw;
  aspect-ratio: 1;
}

.site__art span {
  position: absolute;
}

/* Wide layout: the script sets this when the container is wide enough. */
.site--wide {
  --title: 7cqw;
}

.site--wide .site__nav {
  padding: 3.2cqw 4.5cqw 0;
}

.site--wide .site__brand {
  font-size: 2.4cqw;
}

.site--wide .site__links {
  display: flex;
}

.site--wide .site__main {
  grid-template-columns: 1.2fr 0.8fr;
  align-items: center;
  gap: 4cqw;
  padding: 2cqw 4.5cqw 5cqw;
}

.site--wide .site__sub {
  margin-top: 2cqw;
  font-size: 2.2cqw;
}

.site--wide .site__btn {
  margin-top: 3cqw;
  padding: 1.4cqw 2.6cqw;
  font-size: 2cqw;
}

.site--wide .site__art {
  justify-self: stretch;
  width: auto;
}

/* When the style changes, the parts of the site come in one after the other. */
.is-assembling .site__brand,
.is-assembling .site__links,
.is-assembling .site__title,
.is-assembling .site__sub,
.is-assembling .site__btn {
  animation: part 0.7s var(--ease) backwards;
}

.is-assembling .site__links {
  animation-delay: 0.05s;
}

.is-assembling .site__title {
  animation-delay: 0.1s;
}

.is-assembling .site__sub {
  animation-delay: 0.18s;
}

.is-assembling .site__btn {
  animation-delay: 0.26s;
}

.is-assembling .site__art span {
  animation: shape 0.8s var(--ease) backwards;
}

.is-assembling .site__art span:nth-child(1) {
  animation-delay: 0.14s;
}

.is-assembling .site__art span:nth-child(2) {
  animation-delay: 0.24s;
}

.is-assembling .site__art span:nth-child(3) {
  animation-delay: 0.34s;
}

@keyframes part {
  from {
    opacity: 0;
    translate: 0 2.5cqw;
  }
}

@keyframes shape {
  from {
    opacity: 0;
    scale: 0.75;
  }
}

/* Style 1, Klar: white, one blue, plain shapes. */
.s1 {
  background: #ffffff;
  color: #111315;
}

.s1 .site__btn {
  border-radius: 99cqw;
  background: #2f5bff;
  color: #ffffff;
}

.s1 .site__art span:nth-child(1) {
  inset: 0;
  border-radius: 14%;
  background: #2f5bff;
}

.s1 .site__art span:nth-child(2) {
  right: -7%;
  bottom: -7%;
  width: 46%;
  aspect-ratio: 1;
  border-radius: 50%;
  background: #111315;
}

.s1 .site__art span:nth-child(3) {
  top: 16%;
  left: 14%;
  width: 36%;
  height: 7%;
  border-radius: 99cqw;
  background: #ffffff;
}

/* Style 2, Warm: sand, serif, an arch with a sun. */
.s2 {
  background: #f4eee3;
  color: #2c2a26;
  font-family: Georgia, "Times New Roman", serif;
}

.s2 .site__brand,
.s2 .site__title {
  font-weight: 400;
}

.s2 .site__title {
  letter-spacing: -0.01em;
}

.s2 .site__btn {
  border: 0.3cqw solid #2f6b4f;
  color: #2f6b4f;
}

/* Centred: the arch sits above the name like a sign over a door. */
.s2 .site__nav {
  justify-content: center;
}

.s2 .site__links {
  display: none;
}

.s2 .site__main {
  grid-template-columns: 1fr;
  justify-items: center;
  gap: 4cqw;
  text-align: center;
}

.s2 .site__art {
  order: -1;
  justify-self: center;
  width: 30cqw;
}

.s2.site--wide .site__main {
  gap: 2.4cqw;
}

.s2.site--wide .site__art {
  width: 16cqw;
}

.s2 .site__art span:nth-child(1) {
  inset: 0 12%;
  border-radius: 50cqw 50cqw 0 0;
  background: #2f6b4f;
}

.s2 .site__art span:nth-child(2) {
  top: 20%;
  left: 36%;
  width: 28%;
  aspect-ratio: 1;
  border-radius: 50%;
  background: #e3b46f;
}

/* Style 3, Kräftig: red, condensed capitals, stripes. */
.s3 {
  background: #e2372b;
  color: #ffffff;
  font-family: "Barlow Condensed", "Arial Narrow", sans-serif;
}

.s3 .site__brand,
.s3 .site__title {
  font-weight: 700;
  text-transform: uppercase;
}

.s3 {
  --title: 16cqw;
}

.s3.site--wide {
  --title: 11.5cqw;
}

.s3 .site__title {
  line-height: 0.88;
  letter-spacing: 0;
}

/* A poster: the headline runs across the full width, the stripes close the page at the bottom. */
.s3 .site__main {
  grid-template-columns: 1fr;
  align-content: start;
  padding-bottom: 24cqw;
}

.s3.site--wide .site__main {
  padding-bottom: 13cqw;
}

.s3 .site__art {
  position: absolute;
  inset: auto 0 0 0;
  width: auto;
  height: 17cqw;
  aspect-ratio: auto;
}

.s3.site--wide .site__art {
  height: 9cqw;
}

.s3 .site__sub {
  font-family: "Barlow", system-ui, sans-serif;
}

.s3 .site__btn {
  background: #ffffff;
  color: #e2372b;
  font-weight: 700;
  text-transform: uppercase;
}

.s3 .site__art span:nth-child(1) {
  inset: 0;
  background: repeating-linear-gradient(-45deg, #111315 0 3cqw, transparent 3cqw 6cqw);
}

.s3 .site__art span:nth-child(2) {
  top: 0;
  bottom: 0;
  left: 0;
  width: 22%;
  background: #111315;
}

/* Style 4, Ruhig: dark, italic serif, thin gold lines. */
.s4 {
  background: #131313;
  color: #f3efe6;
  font-family: Georgia, "Times New Roman", serif;
}

.s4 .site__brand {
  font-weight: 400;
  letter-spacing: 0.04em;
}

.s4 .site__title {
  font-style: italic;
  font-weight: 400;
  letter-spacing: -0.01em;
}

.s4 .site__btn {
  border: 0.25cqw solid #c9a45c;
  color: #c9a45c;
  font-weight: 400;
  letter-spacing: 0.06em;
}

/* The ring sits before the text, like a seal. */
.s4 .site__art {
  order: -1;
  justify-self: start;
  width: 32cqw;
}

.s4.site--wide .site__main {
  grid-template-columns: 0.7fr 1.3fr;
}

.s4.site--wide .site__art {
  justify-self: stretch;
  width: auto;
}

.s4 .site__art span:nth-child(1) {
  inset: 6%;
  border: 0.3cqw solid #c9a45c;
  border-radius: 50%;
}

.s4 .site__art span:nth-child(2) {
  top: 41%;
  left: 41%;
  width: 18%;
  aspect-ratio: 1;
  border-radius: 50%;
  background: #c9a45c;
}

.s4 .site__art span:nth-child(3) {
  top: 0;
  bottom: 0;
  left: 50%;
  width: 0.3cqw;
  background: rgba(201, 164, 92, 0.45);
}

/* Style 5, Verspielt: rounded letters, three loose shapes. */
.s5 {
  background: #fff6ee;
  color: #2a1b5e;
  font-family: ui-rounded, "SF Pro Rounded", "Arial Rounded MT Bold", "Barlow", system-ui, sans-serif;
}

.s5 .site__brand,
.s5 .site__title {
  font-weight: 700;
}

.s5 .site__btn {
  border-radius: 2.4cqw;
  background: #6b46ff;
  box-shadow: 0.7cqw 0.7cqw 0 #2a1b5e;
  color: #ffffff;
}

/* The shapes lie loose across the whole page, behind the text. */
.s5 .site__main {
  grid-template-columns: 1fr;
}

.s5 .site__nav,
.s5 .site__copy {
  position: relative;
  z-index: 1;
}

.s5 .site__copy {
  max-width: 80%;
}

.s5.site--wide .site__copy {
  max-width: 62%;
}

.s5 .site__art {
  position: absolute;
  inset: 0;
  width: auto;
  aspect-ratio: auto;
}

.s5 .site__art span:nth-child(1) {
  top: -9%;
  right: -7%;
  width: 34%;
  aspect-ratio: 1;
  border-radius: 50%;
  background: #ff7ab6;
}

.s5 .site__art span:nth-child(2) {
  right: 17%;
  bottom: -7%;
  width: 22%;
  aspect-ratio: 1;
  border-radius: 14%;
  background: #ffd23f;
  rotate: 12deg;
}

.s5 .site__art span:nth-child(3) {
  right: 5%;
  bottom: 20%;
  width: 12%;
  aspect-ratio: 1;
  background: #6b46ff;
  clip-path: polygon(50% 0, 100% 100%, 0 100%);
}

/* Before and after: two layers, the new one clipped at the handle */

.compare__stage {
  position: relative;
  aspect-ratio: 4 / 4.4;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 20px;
  container-type: inline-size;
  box-shadow: 0 40px 80px -55px rgba(17, 19, 21, 0.4);
}

.compare__layer {
  position: absolute;
  inset: 0;
}

.compare__layer--new {
  clip-path: inset(0 0 0 var(--pos));
}

.compare__tag {
  position: absolute;
  top: 0.9rem;
  left: 0.9rem;
  padding: 0.15rem 0.65rem;
  border-radius: 999px;
  background: rgba(17, 19, 21, 0.78);
  color: #ffffff;
  font-size: 0.8rem;
  font-weight: 500;
  pointer-events: none;
}

.compare__tag--new {
  right: 0.9rem;
  left: auto;
}

/* The range input covers the stage, so dragging anywhere moves the handle; it also takes the keyboard. */
.compare__range {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  margin: 0;
  opacity: 0;
  cursor: ew-resize;
}

.compare__handle {
  position: absolute;
  top: 0;
  bottom: 0;
  left: var(--pos);
  width: 2px;
  margin-left: -1px;
  background: #ffffff;
  box-shadow: 0 0 0 1px rgba(17, 19, 21, 0.2);
  pointer-events: none;
}

.compare__handle i {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 3rem;
  height: 3rem;
  border-radius: 50%;
  background: #ffffff;
  box-shadow: 0 0 0 1px rgba(17, 19, 21, 0.12), 0 8px 24px -8px rgba(17, 19, 21, 0.45);
  transform: translate(-50%, -50%);
}

.compare__handle i::before,
.compare__handle i::after {
  content: "";
  position: absolute;
  top: 50%;
  width: 0.55rem;
  height: 0.55rem;
  border: solid var(--ink);
  border-width: 2px 2px 0 0;
}

.compare__handle i::before {
  left: 0.75rem;
  transform: translateY(-50%) rotate(-135deg);
}

.compare__handle i::after {
  right: 0.75rem;
  transform: translateY(-50%) rotate(45deg);
}

.compare__range:focus-visible ~ .compare__handle i {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}

/* The old site: how they were built around 2006. */
.old {
  height: 100%;
  overflow: hidden;
  background: #ffffff;
  color: #000000;
  font-family: "Times New Roman", Times, serif;
  font-size: clamp(11px, 2.1cqw, 20px);
  line-height: 1.35;
  text-align: center;
}

.old__bar {
  padding: 0.5em;
  background: #000080;
  color: #ffff00;
  font-size: 1.5em;
  font-weight: bold;
  letter-spacing: 0.08em;
}

.old__welcome {
  margin-top: 1.4em;
  color: #c00000;
  font-size: 1.6em;
  font-style: italic;
  font-weight: bold;
}

.old__links {
  margin-top: 1.2em;
  color: #0000ee;
}

.old__body {
  max-width: 28em;
  margin: 1.4em auto 0;
  padding-inline: 1em;
}

.old__counter {
  display: inline-block;
  margin-top: 1.4em;
  padding: 0.25em 0.8em;
  background: #000000;
  color: #00ff00;
  font-family: "Courier New", Courier, monospace;
}

.old__small {
  margin-top: 1.2em;
  color: #555555;
  font-size: 0.8em;
}

/* Devices: one site, three screens */

.segmented {
  display: inline-flex;
  padding: 0.25rem;
  border: 1px solid var(--line);
  border-radius: 999px;
}

.segmented button {
  padding: 0.5rem 1.15rem;
  border: 0;
  border-radius: 999px;
  background: none;
  font-size: 1rem;
  font-weight: 500;
  cursor: pointer;
  transition: background-color 0.25s ease, color 0.25s ease;
}

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

.devices__stage {
  display: grid;
  place-items: center;
  margin-top: 2rem;
}

.device {
  overflow: hidden;
  border: 0.45rem solid var(--ink);
  border-radius: 0.9rem;
  background: var(--paper);
  box-shadow: 0 40px 80px -50px rgba(17, 19, 21, 0.5);
  container-type: inline-size;
  transition: width 0.8s var(--ease), height 0.8s var(--ease), border-radius 0.8s var(--ease);
}

.device[data-kind="tablet"] {
  border-radius: 1.4rem;
}

.device[data-kind="phone"] {
  border-radius: 2rem;
}

/* Speed: the load time of this very page */

.speed .intro {
  margin-bottom: 0;
}

.speed__figure {
  margin-top: 2rem;
  font-size: clamp(5.5rem, 19vw, 13rem);
  font-variant-numeric: tabular-nums;
  font-weight: 600;
  line-height: 0.85;
  letter-spacing: -0.05em;
}

.speed__figure small {
  display: block;
  margin-top: 1rem;
  color: var(--muted);
  font-size: 1.2rem;
  font-weight: 400;
  letter-spacing: 0;
}

/* The small things: three demos to try */

.details__grid {
  display: grid;
  gap: 2.5rem;
}

.detail h3 {
  margin-top: 1.25rem;
  font-size: 1.45rem;
}

.detail > p {
  margin-top: 0.4rem;
  max-width: 32ch;
  color: var(--muted);
}

.demo {
  position: relative;
  display: grid;
  place-items: center;
  height: 14rem;
  overflow: hidden;
  border-radius: 20px;
  background: var(--soft);
}

/* Open or closed */

.demo--open {
  align-content: center;
  gap: 1rem;
  padding: 1rem;
}

.open__status {
  font-size: 1.1rem;
  font-weight: 600;
}

.open__dot {
  position: relative;
  display: inline-block;
  width: 0.7rem;
  height: 0.7rem;
  margin-right: 0.55rem;
  border-radius: 50%;
  background: #a9aeb5;
}

.open__dot.is-open {
  background: var(--green);
}

/* While open, a ring goes out from the dot. */
.open__dot.is-open::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 50%;
  background: var(--green);
  animation: ping 2s ease-out infinite;
}

@keyframes ping {
  from {
    opacity: 0.6;
    transform: scale(1);
  }
  to {
    opacity: 0;
    transform: scale(3.2);
  }
}

.open__week {
  display: flex;
  gap: 0.3rem;
}

.open__week li {
  min-width: 2.15rem;
  padding: 0.4rem 0;
  border-radius: 9px;
  background: var(--paper);
  color: var(--muted);
  font-size: 0.8rem;
  text-align: center;
}

.open__week .is-closed {
  background: none;
}

.open__week .is-today {
  background: var(--ink);
  color: var(--paper);
  font-weight: 600;
}

.open__example {
  color: var(--muted);
  font-size: 0.85rem;
}

/* Call with one tap */

.callbtn {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 0.65rem;
  padding: 0.95rem 1.5rem;
  border: 0;
  border-radius: 999px;
  background: var(--ink);
  color: var(--paper);
  font-size: 1.2rem;
  font-weight: 600;
  cursor: pointer;
  transition: background-color 0.3s ease, transform 0.2s var(--ease);
}

.callbtn:active {
  transform: scale(0.96);
}

.callbtn svg {
  width: 1.2rem;
  height: 1.2rem;
  fill: currentColor;
}

.callbtn.is-dialing {
  background: var(--accent);
}

/* While dialling, rings go out from the button and the handset shakes. */
.callbtn.is-dialing::before,
.callbtn.is-dialing::after {
  content: "";
  position: absolute;
  inset: 0;
  border: 2px solid var(--accent);
  border-radius: 999px;
  animation: ring 1.2s ease-out infinite;
}

.callbtn.is-dialing::after {
  animation-delay: 0.6s;
}

.callbtn.is-dialing svg {
  animation: shake 0.4s ease-in-out infinite;
}

@keyframes ring {
  from {
    opacity: 0.7;
    transform: scale(1);
  }
  to {
    opacity: 0;
    transform: scale(1.35, 1.9);
  }
}

@keyframes shake {
  25% {
    rotate: -14deg;
  }
  75% {
    rotate: 14deg;
  }
}

/* Directions with one tap */

.demo--route svg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.map__streets {
  fill: none;
  stroke: var(--paper);
  stroke-linecap: round;
  stroke-width: 11;
}

.map__route {
  fill: none;
  stroke: var(--accent);
  stroke-dasharray: 1;
  stroke-dashoffset: 1;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 5;
}

.map__start {
  fill: var(--ink);
}

.map__pin {
  opacity: 0;
}

.map__pin path {
  fill: var(--accent);
}

.map__pin circle {
  fill: var(--paper);
}

.demo--route .button {
  position: absolute;
  right: 0.9rem;
  bottom: 0.9rem;
}

/* The route is drawn from the start, then the pin lands at the end. */
.demo--route.is-on .map__route {
  animation: draw 1.3s ease-in-out forwards;
}

.demo--route.is-on .map__pin {
  animation: drop 0.6s 1.15s var(--ease) forwards;
}

@keyframes draw {
  to {
    stroke-dashoffset: 0;
  }
}

@keyframes drop {
  from {
    opacity: 0;
    translate: 0 -18px;
  }
  to {
    opacity: 1;
    translate: 0 0;
  }
}

/* What it is worth: three measured figures, each with its source and something to try */

.exhibit {
  display: grid;
  gap: 2rem;
  padding-block: clamp(2.5rem, 6vw, 4rem);
  border-top: 1px solid var(--line);
}

.exhibit:last-child {
  padding-bottom: 0;
}

/* Neither column may be widened by what is inside it. */
.exhibit > * {
  min-width: 0;
}

.exhibit h3 {
  font-size: clamp(1.6rem, 3.2vw, 2.25rem);
}

.exhibit__text p {
  margin-top: 1rem;
  max-width: 42ch;
  color: var(--muted);
}

.exhibit__text b {
  color: var(--ink);
  font-weight: 600;
}

/* What the visitor's own choices lead to: in ink, the figures underlined in the accent. */
.profile__result {
  max-width: 36ch;
  color: var(--muted);
  text-align: center;
}

.exhibit__result {
  color: var(--ink);
  font-size: 1.15rem;
  font-weight: 500;
  line-height: 1.4;
}

.exhibit__result b {
  font-weight: 600;
}

.exhibit__result b {
  text-decoration: underline;
  text-decoration-color: var(--accent);
  text-decoration-thickness: 2px;
  text-underline-offset: 0.2em;
}

#profile-done {
  animation: rise 0.7s var(--ease) both;
}

.exhibit__text .exhibit__source {
  margin-top: 1.5rem;
  font-size: 0.9rem;
}

.exhibit__stage {
  display: grid;
  align-content: center;
  justify-items: center;
  gap: 1.75rem;
  min-height: 21rem;
  padding: clamp(1.5rem, 4vw, 2.5rem);
  border-radius: 20px;
  background: var(--soft);
}

.exhibit__stage .segmented {
  background: var(--paper);
}

.exhibit__stage .segmented button {
  padding-inline: 0.95rem;
  font-size: 0.95rem;
  white-space: nowrap;
}

/* Waiting */

.wait__clock {
  font-size: clamp(3.75rem, 12vw, 6.5rem);
  font-variant-numeric: tabular-nums;
  font-weight: 600;
  line-height: 0.9;
  letter-spacing: -0.04em;
  transition: color 0.3s ease;
}

.wait.is-done .wait__clock {
  color: var(--accent);
  animation: rise 0.6s var(--ease) both;
}

.wait__bar {
  width: min(100%, 22rem);
  height: 6px;
  overflow: hidden;
  border-radius: 3px;
  background: var(--line);
}

.wait__bar i {
  display: block;
  height: 100%;
  background: var(--accent);
  transform: scaleX(0);
  transform-origin: left;
}

.wait__label {
  min-height: 3.1em;
  max-width: 30ch;
  color: var(--muted);
  text-align: center;
}

.wait.is-done .wait__label {
  color: var(--ink);
  font-weight: 500;
}

/* Google profile */

.profile__card {
  width: min(100%, 21rem);
  padding: 1.25rem;
  border-radius: 16px;
  background: var(--paper);
  box-shadow: 0 24px 50px -36px rgba(17, 19, 21, 0.45);
}

.profile__name {
  overflow-wrap: anywhere;
  font-size: 1.3rem;
  font-weight: 600;
  line-height: 1.2;
}

.profile__kind {
  overflow-wrap: anywhere;
  color: var(--muted);
  font-size: 0.95rem;
}

.profile__card ul {
  display: grid;
  gap: 0.5rem;
  margin-top: 1rem;
}

.profile__card li {
  display: grid;
  align-items: center;
  min-height: 2.5rem;
  font-size: 0.95rem;
}

/* A part that is not filled in is an empty, dashed slot. */
.profile__card em {
  padding: 0.5rem 0.75rem;
  border: 1px dashed #c6cad0;
  border-radius: 10px;
  color: var(--muted);
  font-size: 0.85rem;
  font-style: normal;
}

.profile__card li > span,
.profile__card li.is-on em {
  display: none;
}

.profile__card li.is-on > span {
  display: block;
  padding-left: 0.75rem;
  border-left: 2px solid var(--accent);
  font-weight: 500;
  animation: rise 0.5s var(--ease) both;
}

.profile__card li.is-on > .profile__photos {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.4rem;
  padding-left: 0;
  border-left: 0;
}

.profile__photos i {
  aspect-ratio: 4 / 3;
  border-radius: 8px;
  background: color-mix(in srgb, var(--accent) 28%, var(--paper));
}

.profile__photos i:nth-child(2) {
  background: color-mix(in srgb, var(--accent) 55%, var(--paper));
}

.profile__photos i:nth-child(3) {
  background: color-mix(in srgb, var(--accent) 14%, var(--paper));
}

.chips {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.5rem;
}

.chip {
  padding: 0.5rem 1rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--paper);
  font-size: 0.95rem;
  font-weight: 500;
  cursor: pointer;
  transition: background-color 0.2s ease, border-color 0.2s ease, color 0.2s ease;
}

.chip:hover {
  border-color: var(--ink);
}

.chip[aria-pressed="true"] {
  border-color: var(--ink);
  background: var(--ink);
  color: var(--paper);
}

/* Position in the search: a hundred dots, lit one after the other */

.rank__dots {
  display: grid;
  grid-template-columns: repeat(10, 1fr);
  gap: 0.5rem;
  width: min(100%, 15rem);
}

.rank__dots i {
  aspect-ratio: 1;
  border-radius: 50%;
  background: #d6dade;
  transition: background-color 0.35s ease calc(var(--i) * 12ms), scale 0.35s var(--ease) calc(var(--i) * 12ms);
}

.rank__dots i.is-on {
  background: var(--accent);
  scale: 1.12;
}

.rank__result {
  min-height: 2.9em;
  max-width: 26ch;
  font-size: 1.2rem;
  font-weight: 500;
  line-height: 1.35;
  text-align: center;
}

/* Offer: the price and what it contains */

main > .offer {
  display: grid;
  gap: 3rem;
  /* A soft band, inset from the page edge by the gutter. */
  width: min(100% - 2 * var(--gutter), var(--width) - 2 * var(--gutter));
  max-width: none;
  padding: clamp(2rem, 6vw, 5rem);
  border-radius: 24px;
  background: var(--soft);
}

.offer__figure {
  font-size: clamp(5.5rem, 19vw, 12.5rem);
  font-weight: 600;
  line-height: 0.85;
  letter-spacing: -0.05em;
  white-space: nowrap;
}

.offer__once {
  margin-top: 1rem;
  color: var(--muted);
  font-size: 1.2rem;
}

.offer__promise {
  margin-block: 2rem 1.5rem;
  max-width: 20ch;
  font-size: clamp(1.3rem, 2.6vw, 1.7rem);
  font-weight: 500;
  line-height: 1.25;
  letter-spacing: -0.01em;
}

.offer__details h2 {
  color: var(--muted);
  font-size: 1rem;
  font-weight: 500;
  letter-spacing: 0;
}

.offer__details h2:not(:first-child) {
  margin-top: 2.5rem;
}

.offer__list,
.offer__extras {
  margin-top: 0.75rem;
  border-bottom: 1px solid var(--line);
}

.offer__list li,
.offer__extras > div {
  padding-block: 0.8rem;
  border-top: 1px solid var(--line);
}

.offer__list li {
  font-size: 1.2rem;
  font-weight: 500;
}

.offer__extras dt {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 0.2rem 1.5rem;
  font-size: 1.2rem;
  font-weight: 500;
}

.offer__extras b {
  font-weight: 600;
  white-space: nowrap;
}

.offer__extras dd {
  margin-top: 0.3rem;
  max-width: 46ch;
  color: var(--muted);
  font-size: 1rem;
}

.offer__extras .offer__notice {
  font-size: 0.9rem;
}

/* Steps: a line that fills as the section is scrolled through */

.steps ol {
  --p: 0;
  position: relative;
  display: grid;
  gap: 2.5rem;
  padding-left: 3rem;
  counter-reset: step;
}

.steps ol::before,
.steps ol::after {
  content: "";
  position: absolute;
  top: 0.3rem;
  bottom: 0.3rem;
  left: 0.85rem;
  width: 2px;
  background: var(--line);
}

.steps ol::after {
  background: var(--accent);
  transform: scaleY(var(--p));
  transform-origin: top;
  transition: background-color 0.3s ease;
}

.steps li {
  position: relative;
  counter-increment: step;
}

.steps li::before {
  content: counter(step);
  position: absolute;
  top: 0;
  left: -3rem;
  z-index: 1;
  display: grid;
  place-items: center;
  width: 1.8rem;
  height: 1.8rem;
  border: 2px solid var(--line);
  border-radius: 50%;
  background: var(--paper);
  color: var(--muted);
  font-size: 0.85rem;
  font-weight: 600;
  transition: background-color 0.4s ease, border-color 0.4s ease, color 0.4s ease, transform 0.5s var(--ease);
}

.steps li.is-on::before {
  border-color: var(--accent);
  background: var(--accent);
  color: var(--paper);
  transform: scale(1.12);
}

.steps h3,
.steps p {
  opacity: 0.4;
  transition: opacity 0.5s ease;
}

.steps .is-on h3,
.steps .is-on p {
  opacity: 1;
}

.steps h3 {
  font-size: clamp(1.5rem, 2.6vw, 1.9rem);
}

.steps p {
  margin-top: 0.5rem;
  max-width: 30ch;
  color: var(--muted);
}

/* About */

.about {
  display: grid;
  gap: 1.75rem 4rem;
}

.about__text p {
  max-width: 40ch;
  font-size: clamp(1.15rem, 2.2vw, 1.35rem);
}

.about__text p + p {
  margin-top: 1em;
}

.about img {
  width: min(100%, 20rem);
  height: auto;
  border-radius: 16px;
}

/* Contact */

.contact h2 {
  font-size: clamp(3rem, 11vw, 7.5rem);
  line-height: 0.95;
  letter-spacing: -0.04em;
}

.contact__mail,
.contact__phone {
  margin-top: 1.5rem;
  font-size: clamp(1.5rem, 4.5vw, 2.75rem);
  font-weight: 500;
  letter-spacing: -0.02em;
  overflow-wrap: anywhere;
}

.contact__phone {
  margin-top: 0.5rem;
}

.contact__actions {
  margin-top: 1.5rem;
}

.contact__text {
  margin-top: 1.25rem;
  color: var(--muted);
}

/* Footer */

.foot {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 0.75rem 2rem;
  margin-top: var(--section);
  padding-block: 1.5rem 6rem;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 0.95rem;
}

.foot nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.5rem;
}

.foot a {
  text-decoration: none;
}

.foot a:hover {
  text-decoration: underline;
}

/* The bar at the bottom: slides in once the hero is out of view */

.sticky {
  position: fixed;
  right: 1rem;
  bottom: 1rem;
  left: 1rem;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  max-width: 34rem;
  margin-inline: auto;
  padding: 0.5rem 0.5rem 0.5rem 1.25rem;
  border-radius: 1.6rem;
  background: var(--ink);
  box-shadow: 0 20px 40px -20px rgba(17, 19, 21, 0.6);
  color: var(--paper);
  font-size: 0.95rem;
  line-height: 1.3;
  opacity: 0;
  pointer-events: none;
  transform: translateY(150%);
  transition: transform 0.6s var(--ease), opacity 0.4s ease;
}

.sticky.is-on {
  opacity: 1;
  pointer-events: auto;
  transform: none;
}

.sticky .button {
  flex: none;
  border-color: var(--paper);
  background: var(--paper);
  color: var(--ink);
}

.sticky .button:hover {
  border-color: var(--accent);
  background: var(--accent);
  color: var(--paper);
}

/* Legal pages */

.legal {
  margin-top: clamp(2.5rem, 8vw, 5rem);
}

.legal h1 {
  font-size: clamp(2.6rem, 7vw, 4.5rem);
  letter-spacing: -0.03em;
}

.legal h2 {
  margin-top: 2.25rem;
  font-size: 1.5rem;
  letter-spacing: -0.02em;
}

.legal p {
  margin-top: 0.5rem;
  max-width: 62ch;
}

.legal dl {
  margin-top: 2rem;
}

.legal dt {
  margin-top: 1.1rem;
  color: var(--muted);
  font-size: 0.9rem;
}

.legal dd {
  font-weight: 500;
}

@media (min-width: 44rem) {
  .window__view {
    aspect-ratio: 16 / 10.5;
  }

  .compare__stage {
    aspect-ratio: 16 / 8.6;
  }

  .details__grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
  }

  /* On a wide screen the steps run left to right and the line fills sideways. */
  .steps ol {
    grid-template-columns: repeat(3, 1fr);
    gap: 3rem;
    padding: 3rem 0 0;
  }

  .steps ol::before,
  .steps ol::after {
    top: 0.85rem;
    right: 0;
    bottom: auto;
    left: 0;
    width: auto;
    height: 2px;
  }

  .steps ol::after {
    transform: scaleX(var(--p));
    transform-origin: left;
  }

  .steps li::before {
    top: -3rem;
    left: 0;
  }
}

@media (min-width: 60rem) {
  main > .hero {
    grid-template-columns: 5fr 7fr;
    gap: 4rem;
    align-items: center;
  }

  main > .offer {
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: start;
  }

  .speed {
    display: grid;
    grid-template-columns: 5fr 7fr;
    gap: 4rem;
    align-items: end;
  }

  .exhibit {
    grid-template-columns: 5fr 7fr;
    gap: 4rem;
    align-items: center;
  }

  .speed__figure {
    margin-top: 0;
    text-align: right;
  }

  .about {
    grid-template-columns: 5fr 7fr;
    align-items: start;
  }
}

/* No movement for people who have asked for none: everything is simply in its final state. */
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
  }

  .js [data-reveal] {
    opacity: 1;
    transform: none;
  }

  .demo--route.is-on .map__route {
    stroke-dashoffset: 0;
  }

  .demo--route.is-on .map__pin {
    opacity: 1;
  }
}
