/*
  Look: a calm pastel page where the ads carry the colour. One typeface, one
  highlighter. The only thing that gets marked is a result.

  Shape rule: ads and photos 20px, buttons and filters full pill.
*/

@font-face {
  font-family: "Instrument Sans";
  src: url("../fonts/instrument-sans-var.woff2") format("woff2");
  font-weight: 400 700;
  font-stretch: 75% 100%;
  font-display: swap;
}

:root {
  --page: #eef4ef;
  --ink: #0f1a14;
  --soft: #55665c;
  --rule: rgba(15, 26, 20, 0.12);
  --mark: #ffe27a;
  --paper: #f8fbf8;
  --tint: #dfeae2;
  --butter: #fff1b8;

  --font: "Instrument Sans", "Helvetica Neue", Arial, sans-serif;
  --r-ad: 20px;
  --ease-out: cubic-bezier(0.23, 1, 0.32, 1);

  --wrap: 1080px;
  --gutter: clamp(20px, 4.5vw, 56px);
  --gap: clamp(72px, 10vw, 136px);
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 104px; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--page);
  color: var(--ink);
  font-family: var(--font);
  font-size: 1.0625rem;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img, video, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
ul, ol { list-style: none; margin: 0; padding: 0; }
h1, h2, h3, p, figure { margin: 0; }
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; }

::selection { background: var(--mark); color: var(--ink); }
:focus-visible { outline: 2px solid var(--ink); outline-offset: 3px; border-radius: 6px; }
html { scrollbar-color: rgba(15, 26, 20, 0.3) var(--page); }

.wrap { width: min(100% - 2 * var(--gutter), var(--wrap)); margin-inline: auto; }
.skip { position: absolute; left: 12px; top: -60px; z-index: 30; background: var(--ink); color: var(--page); padding: 10px 16px; border-radius: 999px; font-weight: 600; }
.skip:focus { top: 12px; }

h1, h2 { font-weight: 600; letter-spacing: -0.035em; line-height: 1.02; text-wrap: balance; }
h1 { font-size: clamp(2.5rem, 5.4vw, 4.25rem); }
h2 { font-size: clamp(1.9rem, 3.4vw, 2.75rem); }
h3 { font-size: 1.25rem; font-weight: 600; letter-spacing: -0.02em; line-height: 1.2; text-wrap: balance; }

/* The highlighter. It draws across the number once, when the line scrolls into view. */
mark {
  color: inherit;
  padding: 0 0.16em;
  margin: 0 -0.06em;
  border-radius: 0.14em;
  background: linear-gradient(var(--mark), var(--mark)) no-repeat 0 62% / 100% 82%;
  -webkit-box-decoration-break: clone;
  box-decoration-break: clone;
}
.js [data-mark] mark { background-size: 0% 82%; transition: background-size 620ms var(--ease-out) 120ms; }
.js [data-mark].is-in mark { background-size: 100% 82%; }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 52px; padding: 0 26px; border-radius: 999px;
  background: var(--ink); color: var(--page);
  font-weight: 600; font-size: 1rem; white-space: nowrap;
  transition: transform 160ms var(--ease-out), background-color 160ms ease;
}
.btn:active { transform: scale(0.97); }
.btn--sm { min-height: 42px; padding: 0 18px; font-size: 0.9375rem; }
.link { font-weight: 600; text-decoration: underline; text-decoration-thickness: 1.5px; text-underline-offset: 5px; }
@media (hover: hover) and (pointer: fine) {
  .btn:hover { background: #1f3328; }
  .link:hover { text-decoration-color: transparent; }
}

/* Top bar: a floating glass pill, so it reads as a bar over the ads instead of fading into them */
.top { position: sticky; top: 0; z-index: 20; padding-top: 12px; pointer-events: none; }
.top__in {
  pointer-events: auto;
  display: flex; align-items: center; gap: 28px;
  height: 62px; padding: 0 10px 0 24px;
  border-radius: 999px;
  background: rgba(248, 251, 248, 0.72);
  -webkit-backdrop-filter: blur(18px) saturate(1.6);
  backdrop-filter: blur(18px) saturate(1.6);
  border: 1px solid rgba(255, 255, 255, 0.7);
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.6) inset, 0 10px 30px -12px rgba(15, 26, 20, 0.28), 0 0 0 1px rgba(15, 26, 20, 0.06);
}
@supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) { .top__in { background: var(--paper); } }
.top__name { font-weight: 600; font-size: 1.0625rem; letter-spacing: -0.01em; margin-right: auto; white-space: nowrap; }
.top__nav { display: flex; gap: 28px; margin-right: auto; font-size: 0.9688rem; font-weight: 500; color: var(--ink); }
.top__nav a { padding: 8px 0; opacity: 0.72; transition: opacity 160ms ease; }
@media (hover: hover) and (pointer: fine) { .top__nav a:hover { opacity: 1; } }

/* Hero: the statement, then a row of ads playing */
.hero { padding: clamp(28px, 4.5vw, 60px) 0 0; }
.hero__copy { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 0.75fr); gap: clamp(24px, 5vw, 72px); align-items: end; }
.hero__side p { font-size: clamp(1.0625rem, 1.4vw, 1.1875rem); color: var(--soft); max-width: 34ch; }
.hero__cta { display: flex; flex-wrap: wrap; align-items: center; gap: 14px 26px; margin-top: 24px; }
.reel { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: clamp(10px, 1.6vw, 18px); margin-top: clamp(36px, 5vw, 60px); align-items: start; }
.reel .ad:nth-child(even) { margin-top: clamp(16px, 3vw, 40px); }

/* An ad on the page: always its native 9:16, never boxed in a card */
.ad {
  position: relative; display: block; width: 100%;
  aspect-ratio: 9 / 16; overflow: hidden;
  border-radius: var(--r-ad);
  background: var(--tint);
}
.ad video, .ad img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.ad video { opacity: 0; transition: opacity 200ms ease; }
.ad video.is-on, .ad video[autoplay] { opacity: 1; }
.ad__play {
  position: absolute; left: 12px; bottom: 12px;
  width: 38px; height: 38px; border-radius: 50%;
  display: grid; place-items: center;
  background: rgba(255, 255, 255, 0.92); color: var(--ink);
  transition: transform 160ms var(--ease-out);
}
.ad__play svg { width: 14px; height: 14px; fill: currentColor; margin-left: 2px; }
.ad--pending { background: var(--butter); display: grid; place-items: center; padding: 18px; text-align: center; }
.ad--pending span { font-size: 0.9375rem; font-weight: 500; color: #6b5a12; max-width: 14ch; }
.ad--wide { aspect-ratio: 16 / 9; }
.ad--wide.ad--pending span { max-width: none; }
button.ad { transition: transform 200ms var(--ease-out); }
button.ad:active { transform: scale(0.985); }
@media (hover: hover) and (pointer: fine) {
  button.ad:hover .ad__play { transform: scale(1.08); }
}

/* The lines under an ad */
.who { font-size: 0.9375rem; font-weight: 500; color: var(--soft); }
.result { font-size: 1.25rem; font-weight: 600; letter-spacing: -0.022em; line-height: 1.2; margin-top: 6px; text-wrap: balance; }
.sub { font-size: 0.9375rem; color: var(--soft); margin-top: 8px; max-width: 34ch; }

/* Sections */
.block { padding: var(--gap) 0 0; }
.block__head { margin-bottom: clamp(28px, 4vw, 48px); }
.block__head p { margin-top: 12px; color: var(--soft); max-width: 46ch; }
.block__head--row { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 20px 32px; }

/* Featured clients: a photo and one line each */
.featured { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: clamp(12px, 1.6vw, 20px); }
.client__pic { position: relative; aspect-ratio: 4 / 5; border-radius: var(--r-ad); overflow: hidden; background: var(--butter); display: grid; place-items: center; }
.client__pic img.fill { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.client__pic img.logo { width: 68%; height: auto; }
.client__pic--round { background: #d9e6f5; }
.client__pic b { padding: 0 14px; text-align: center; font-size: clamp(1.6rem, 2.8vw, 2.25rem); font-weight: 700; letter-spacing: -0.04em; line-height: 1.02; color: var(--ink); }
.client:nth-child(3) .client__pic:not(:has(img)) { background: #d9e6f5; }
.client:nth-child(4) .client__pic:not(:has(img)) { background: #f6d9d3; }
.client h3 { margin-top: 14px; font-size: 1.125rem; }
.client h3 span { display: block; margin-top: 3px; font-weight: 500; color: var(--soft); font-size: 0.9375rem; letter-spacing: 0; }
.client p { margin-top: 8px; max-width: 36ch; font-size: 0.9688rem; }
.client .link { display: inline-block; margin-top: 12px; font-size: 0.9688rem; }

.also { display: flex; align-items: baseline; gap: 12px 28px; margin-top: clamp(32px, 4vw, 48px); padding-top: 22px; border-top: 1px solid var(--rule); }
.also > p { color: var(--soft); font-size: 0.9375rem; }
.also ul { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 30px; }
.also li { display: inline-flex; align-items: center; gap: 8px; font-weight: 600; font-size: 1.0625rem; letter-spacing: -0.01em; white-space: nowrap; }
.also li img { width: 19px; height: 19px; object-fit: contain; }

/* Winners and the work wall */
.winners { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: clamp(40px, 4.6vw, 60px) clamp(14px, 2vw, 24px); }
.winners .who { margin-top: 16px; }

/* Ad account results: one main line per account, the rest small underneath */
.accounts { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(36px, 4.4vw, 56px) clamp(24px, 3.4vw, 48px); }
.accounts > li { border-top: 1px solid var(--rule); padding-top: 20px; }
.accounts h3 { font-size: 1.0625rem; letter-spacing: -0.01em; }
.accounts h3 span { display: block; margin-top: 2px; font-size: 0.875rem; font-weight: 500; letter-spacing: 0; color: var(--soft); }
.accounts .result { font-size: 1.375rem; margin-top: 16px; }
.accounts ul { margin-top: 14px; display: grid; gap: 8px; }
.accounts ul li { font-size: 0.9375rem; color: var(--soft); }

.filters { display: flex; flex-wrap: wrap; gap: 8px; }
.filters button {
  min-height: 38px; padding: 0 16px; border-radius: 999px;
  border: 1px solid var(--rule); font-size: 0.9375rem; font-weight: 500; color: var(--soft);
  transition: transform 160ms var(--ease-out), background-color 160ms ease, color 160ms ease, border-color 160ms ease;
}
.filters button:active { transform: scale(0.97); }
.filters button[aria-pressed="true"] { background: var(--ink); border-color: var(--ink); color: var(--page); }
@media (hover: hover) and (pointer: fine) { .filters button:not([aria-pressed="true"]):hover { color: var(--ink); border-color: rgba(15, 26, 20, 0.4); } }

.wall { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 28px 14px; }
.wall li[hidden] { display: none; }
.wall .who { margin-top: 10px; font-size: 0.875rem; }

/* VSLs and long form: 16:9, two per row */
.long { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 36px 20px; }
.long h3 { margin-top: 14px; }
.long .who { margin-top: 4px; font-size: 0.875rem; }

/* How I work: three plain statements beside the 4:5 frame */
.how { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 280px); gap: clamp(28px, 6vw, 96px); align-items: center; }
.points article { padding: 22px 0; border-top: 1px solid var(--rule); }
.points article:last-child { border-bottom: 1px solid var(--rule); }
.points h3 { font-size: 1.375rem; }
.points p { margin-top: 6px; color: var(--soft); max-width: 52ch; }
.safe__tag {
  position: absolute; left: 10px; top: 10px;
  padding: 4px 10px; border-radius: 999px;
  background: var(--mark); color: var(--ink);
  font-size: 0.8125rem; font-weight: 600; line-height: 1.3;
}
.safe { position: relative; aspect-ratio: 9 / 16; border-radius: var(--r-ad); overflow: hidden; background: var(--tint); }
.safe img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
/* A 4:5 crop of a 9:16 frame keeps the middle 70.3% of the height. */
.safe__zone { position: absolute; left: 0; right: 0; top: 14.85%; bottom: 14.85%; border: 2px dashed #fff; box-shadow: 0 0 0 100vmax rgba(15, 26, 20, 0.5); }
.safe__tag--full { z-index: 1; background: rgba(255, 255, 255, 0.92); }

.ladder { margin-top: clamp(48px, 7vw, 88px); }
.ladder ol { position: relative; display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 18px; margin-top: 30px; }
.ladder ol::before { content: ""; position: absolute; left: 26px; right: calc(20% - 34px); top: 26px; height: 2px; background: var(--ink); opacity: 0.18; }
.ladder li { position: relative; }
.ladder b { display: block; margin-top: 16px; font-weight: 600; letter-spacing: -0.015em; }
.ladder p { margin-top: 4px; font-size: 0.9375rem; color: var(--soft); max-width: 22ch; }
/* Awareness as a filling circle: empty when they know nothing, full when they are ready to buy. */
.moon {
  display: block; width: 52px; height: 52px; border-radius: 50%;
  border: 2px solid var(--ink);
  background: linear-gradient(to top, var(--mark) var(--fill), var(--page) var(--fill));
}

/* About and contact */
.about { padding-bottom: var(--gap); }
.about__in { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(28px, 6vw, 96px); align-items: start; border-top: 1px solid var(--rule); padding-top: clamp(40px, 6vw, 72px); }
.about__body p { max-width: 46ch; font-size: 1.125rem; }
.about__body p + p { margin-top: 16px; color: var(--soft); }
.about__body p.note { margin-top: 24px; padding-top: 20px; border-top: 1px solid var(--rule); font-size: 1rem; }
.about__body .btn { margin-top: 32px; }

.foot { border-top: 1px solid var(--rule); padding: 24px 0 36px; color: var(--soft); font-size: 0.875rem; }
.foot__in { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 6px 32px; }

/* Player */
.viewer {
  width: min(100% - 32px, 860px); max-height: calc(100dvh - 32px);
  padding: 0; border: 0; border-radius: 24px;
  background: var(--paper); color: var(--ink);
  overflow: hidden;
  box-shadow: 0 30px 80px -20px rgba(15, 26, 20, 0.45);
  opacity: 0; transform: scale(0.97);
  transition: opacity 200ms var(--ease-out), transform 200ms var(--ease-out), overlay 200ms allow-discrete, display 200ms allow-discrete;
}
.viewer[open] { opacity: 1; transform: scale(1); }
@starting-style { .viewer[open] { opacity: 0; transform: scale(0.97); } }
.viewer::backdrop { background: rgba(15, 26, 20, 0); transition: background-color 200ms ease, overlay 200ms allow-discrete, display 200ms allow-discrete; }
.viewer[open]::backdrop { background: rgba(15, 26, 20, 0.6); }
@starting-style { .viewer[open]::backdrop { background: rgba(15, 26, 20, 0); } }
.viewer__in { display: grid; grid-template-columns: auto minmax(0, 1fr); }
.viewer__stage { background: #0b100d; height: min(calc(100dvh - 32px), 760px); aspect-ratio: 9 / 16; display: grid; place-items: center; color: #cfd8d2; text-align: center; padding: 0; }
.viewer__stage video, .viewer__stage img { width: 100%; height: 100%; object-fit: contain; }
.viewer__stage iframe { width: 100%; height: 100%; border: 0; display: block; }
.viewer__side { padding: 72px 36px 36px; display: flex; flex-direction: column; }
.viewer__side .result { font-size: 1.75rem; margin-top: 10px; }
.viewer__side .title { margin-top: 20px; padding-top: 20px; border-top: 1px solid var(--rule); font-size: 0.9375rem; color: var(--soft); }
.cuts { display: flex; flex-wrap: wrap; gap: 8px; margin-top: auto; padding-top: 28px; }
.cuts button {
  min-height: 40px; padding: 0 16px; border-radius: 999px;
  border: 1px solid var(--rule); font-size: 0.9375rem; font-weight: 500;
  transition: transform 160ms var(--ease-out), background-color 160ms ease, color 160ms ease, border-color 160ms ease;
}
.cuts button:active { transform: scale(0.97); }
.cuts button[aria-pressed="true"] { background: var(--ink); border-color: var(--ink); color: var(--paper); }
.viewer__close {
  position: absolute; top: 16px; right: 16px; z-index: 2;
  width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center;
  background: rgba(15, 26, 20, 0.07);
  transition: transform 160ms var(--ease-out), background-color 160ms ease;
}
.viewer__close svg { width: 16px; height: 16px; fill: currentColor; }
.viewer__close:active { transform: scale(0.94); }
@media (hover: hover) and (pointer: fine) { .viewer__close:hover { background: rgba(15, 26, 20, 0.14); } }

/* A 16:9 piece gets a wide player with the text underneath */
.viewer--wide { width: min(100% - 32px, 1000px); }
.viewer--wide .viewer__in { grid-template-columns: minmax(0, 1fr); }
.viewer--wide .viewer__stage { height: auto; width: 100%; aspect-ratio: 16 / 9; }
.viewer--wide .viewer__side { padding: 22px 30px 26px; }

/* Smaller screens */
@media (max-width: 980px) {
  .winners { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .accounts { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .featured { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 28px 16px; }
  .wall { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}
@media (max-width: 760px) {
  .top__nav { gap: 18px; font-size: 0.9063rem; }
  .top__nav a[href="#how"] { display: none; }
  .hero__copy, .about__in, .how { grid-template-columns: minmax(0, 1fr); }
  .how { gap: 32px; }
  .how .safe { max-width: 62%; }
  .hero__copy { align-items: start; }
  .reel { grid-template-columns: repeat(4, 44vw); overflow-x: auto; scroll-snap-type: x mandatory; margin-inline: calc(-1 * var(--gutter)); padding-inline: var(--gutter); scrollbar-width: none; }
  .reel::-webkit-scrollbar { display: none; }
  .reel .ad { scroll-snap-align: center; }
  .reel .ad:nth-child(even) { margin-top: 0; }
  .featured { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 28px 14px; }
  .long { grid-template-columns: minmax(0, 1fr); }
  .also { flex-direction: column; }
  .accounts { grid-template-columns: minmax(0, 1fr); gap: 32px; }
  .accounts .result { font-size: 1.25rem; }
  .winners { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .wall { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 22px 10px; }
  .result { font-size: 1.125rem; }
  .ladder ol { grid-template-columns: minmax(0, 1fr); gap: 20px; }
  .ladder ol::before { left: 25px; right: auto; top: 26px; bottom: 26px; width: 2px; height: auto; }
  .ladder li { display: grid; grid-template-columns: 52px minmax(0, 1fr); column-gap: 16px; align-items: center; }
  .ladder .moon { grid-row: 1 / span 2; }
  .ladder b { margin-top: 0; align-self: end; }
  .ladder p { max-width: none; align-self: start; }
  .viewer__in { grid-template-columns: minmax(0, 1fr); max-height: calc(100dvh - 32px); overflow-y: auto; }
  .viewer__stage { height: auto; width: 100%; max-height: 64dvh; aspect-ratio: auto; min-height: 200px; }
  .viewer__stage video, .viewer__stage img { max-height: 64dvh; width: auto; }
  .viewer__side { padding: 24px 22px 26px; }
  .cuts { padding-top: 20px; }
}
@media (max-width: 460px) {
  .top__in { height: 56px; padding-left: 18px; }
  .wall { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .winners { gap: 36px 12px; }
  .hero__cta .btn { width: 100%; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .js [data-mark] mark { background-size: 100% 82%; transition: none; }
  .viewer { transform: none; }
  .viewer, .btn, .ad__play, button.ad, .cuts button, .filters button { transition-duration: 1ms; }
}
