/* ==========================================================================
   Five Days Done — gedeelde stijl (alle pagina's)
   Basis: homepage-prototype uit "Claude Dev Folder" + Figma "Five Days Done 2026"
   ========================================================================== */

@font-face {
  font-family: "Apercu Pro"; font-weight: 300; font-style: normal; font-display: swap;
  src: local("Apercu Pro Light"), local("ApercuPro-Light"), url("../fonts/ApercuPro-Light.otf") format("opentype");
}
@font-face {
  font-family: "Apercu Pro"; font-weight: 400; font-style: normal; font-display: swap;
  src: local("Apercu Pro Regular"), local("ApercuPro-Regular"), url("../fonts/ApercuPro-Regular.otf") format("opentype");
}

/* Playfair Display (SIL OFL), self-hosted so no visitor data goes to Google */
@font-face {
  font-family: "Playfair Display"; font-weight: 400; font-style: normal; font-display: swap;
  src: url("../fonts/PlayfairDisplay-Regular.woff2?v=1") format("woff2");
}

/* Font Awesome 6 Pro (licensed) — subsets with only the icons the site uses */
@font-face { font-family: "Font Awesome 6 Pro"; font-weight: 300; font-style: normal; font-display: block;
  src: url("../fonts/fa-pro-light-300.woff2") format("woff2"); }
@font-face { font-family: "Font Awesome 6 Pro"; font-weight: 400; font-style: normal; font-display: block;
  src: url("../fonts/fa-pro-regular-400.woff2?v=2") format("woff2"); }
@font-face { font-family: "Font Awesome 6 Pro"; font-weight: 900; font-style: normal; font-display: block;
  src: url("../fonts/fa-pro-solid-900.woff2") format("woff2"); }

:root {
  --bg: #0b0b0b;
  --fg: #F7F4EF;            /* brand off-white — used for every "white" */
  --fg-rgb: 247, 244, 239;
  --muted: #949089;         /* secondary text; Figma's #404040 is unreadable on the dark cards */
  --hover: #C5C2BC;         /* hover on muted text: halfway --muted → --fg, so it never matches the white text next to it */
  --serif: "Playfair Display", "Times New Roman", serif;
  --sans: "Apercu Pro", system-ui, sans-serif;
  /* One Figma pixel. The Figma frame is 1440 wide, so at a 1440px window
     every size equals the Figma value and all of them scale together. */
  /* floor .8: between the phone layout (≤900) and 1440 the design scales down at most to 80% */
  --k: clamp(.8px, calc(100vw / 1440), 1.35px);
}

* { box-sizing: border-box; margin: 0; padding: 0; }
/* Headings default to bold; Apercu has no bold file, so the browser would fake one.
   Every heading on the site is Regular unless a rule says otherwise. */
h1, h2, h3, h4, h5, h6 { font-weight: 400; }
/* `hidden` must win over component display rules (flex, grid…) */
[hidden] { display: none !important; }
.fa { display: inline-block; font-family: "Font Awesome 6 Pro"; font-style: normal; line-height: 1;
      font-feature-settings: normal; -webkit-font-smoothing: antialiased; text-rendering: auto; }
.fa-light { font-weight: 300; }
.fa-regular { font-weight: 400; }
.fa-solid { font-weight: 900; }
html, body { background: var(--bg); color: var(--fg); }
body { font-family: var(--sans); -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; }
img, svg { display: block; }
a { color: inherit; }

/* ── Button — Figma "Secundary": 12% fill, 15px backdrop blur, radius 5,
      padding 9/21, Apercu Pro Regular 15 / 110%. No border. ── */
.btn {
  display: inline-block;
  font: 400 calc(15 * var(--k))/1.1 var(--sans); color: var(--fg); text-decoration: none;
  padding: calc(9 * var(--k)) calc(21 * var(--k)); border: 0; border-radius: calc(5 * var(--k));
  background: rgba(var(--fg-rgb), .12);
  -webkit-backdrop-filter: blur(15px); backdrop-filter: blur(15px);
  white-space: nowrap; cursor: pointer;
  transition: background .3s, border-radius .5s cubic-bezier(.4,0,.2,1);
}
.btn:hover { background: rgba(var(--fg-rgb), .2); }

/* ── Header — Figma "Menu FC": logo 27×34 at 20px from the top,
      burger 21 wide with 2.5 strokes 7 apart, 20px gap between them ── */
.site-header {
  position: fixed; inset: 0 0 auto 0; z-index: 30; padding-top: calc(20 * var(--k));
  display: flex; align-items: center; justify-content: center; gap: calc(20 * var(--k));
  pointer-events: none;
}
.site-header > * { pointer-events: auto; }

/* Figma "Rectangle 17" behind logo + burger: 107 × 74, flush to the top,
   bottom corners 20, #0b0b0b at 10%, Glass effect (frost 15, refraction .8,
   depth 20, dispersion .5). Chromium gets the full lens via the SVG filter
   built in main.js (.glass-lens); other browsers get the frost only. */
.site-header > .site-header__glass {
  position: absolute; left: 50%; top: 0; translate: -50% 0;
  width: calc(107 * var(--k)); height: calc(74 * var(--k));
  border-radius: 0 0 calc(20 * var(--k)) calc(20 * var(--k));
  background: rgba(11, 11, 11, .1);
  -webkit-backdrop-filter: blur(15px); backdrop-filter: blur(15px);
  pointer-events: none; z-index: -1;
  transition: opacity .3s ease-out;
}
.glass-lens .site-header > .site-header__glass { backdrop-filter: url(#fdd-glass) blur(15px); }
/* Figma "Variant2" (menu open) has no glass */
.menu-open .site-header > .site-header__glass { opacity: 0; }
.site-header .mark { height: calc(34 * var(--k)); width: auto; aspect-ratio: 27 / 34; display: block; }
.site-header button {
  background: none; border: 0; color: inherit; cursor: pointer;
  width: calc(24 * var(--k)); height: calc(24 * var(--k));
}

/* Hamburger ↔ close: the middle line fades, the outer two cross */
.burger { position: relative; }
.burger i {
  position: absolute; left: 50%; top: 50%;
  width: calc(21 * var(--k)); height: calc(2.5 * var(--k)); margin: calc(-1.25 * var(--k)) 0 0 calc(-10.5 * var(--k));
  background: currentColor;
  transition: transform .3s ease-out, opacity .3s ease-out;
}
.burger i:nth-child(1) { transform: translateY(calc(-7 * var(--k))); }
.burger i:nth-child(3) { transform: translateY(calc(7 * var(--k))); }
.menu-open .burger i:nth-child(1) { transform: rotate(45deg) scaleX(1.14); }
.menu-open .burger i:nth-child(2) { opacity: 0; }
.menu-open .burger i:nth-child(3) { transform: rotate(-45deg) scaleX(1.14); }

/* ── Menu — Figma "Variant2": 70% #0b0b0b scrim, #1b1b1b panel over the
      right half. Slides in over 700ms ease in/out, then the text arrives
      one by one. ── */
.scrim {
  position: fixed; inset: 0; z-index: 28; background: rgba(11,11,11,.7);
  opacity: 0; pointer-events: none; transition: opacity .7s cubic-bezier(.65,0,.35,1);
}
.panel {
  position: fixed; top: 0; right: 0; bottom: 0; z-index: 29; width: 50%;
  background: #1b1b1b;
  display: flex; flex-direction: column; justify-content: space-between;
  padding: calc(210 * var(--k)) calc(60 * var(--k)) calc(60 * var(--k)) calc(59 * var(--k));
  transform: translate3d(100%, 0, 0);
  transition: transform .7s cubic-bezier(.65,0,.35,1), visibility 0s .7s;
  visibility: hidden;
}
/* Figma: Playfair Display 42 / 110%, 60px between items */
.panel nav { display: flex; flex-direction: column; gap: calc(60 * var(--k)); }
.panel nav a {
  font-family: var(--serif); font-size: calc(42 * var(--k)); line-height: 1.1;
  color: var(--fg); text-decoration: none; width: max-content; transition: color .3s;
}
.panel nav a:hover { color: rgba(var(--fg-rgb), .6); }
/* Figma: 1px #414141 rule, 30px above Apercu Pro Regular 15 / 110% links */
.panel .sub {
  display: flex; justify-content: space-between;
  border-top: 1px solid #414141; padding-top: calc(30 * var(--k));
}
.panel .sub a { font-size: calc(15 * var(--k)); line-height: 1.1; color: var(--fg); text-decoration: none; }
.panel .sub a:hover { opacity: .6; }

/* The page behind an open menu can't scroll; --sbw keeps the layout in place
   where the browser has a classic scrollbar */
html.menu-lock { overflow: hidden; padding-right: var(--sbw, 0px); }
html.menu-lock .site-header { right: var(--sbw, 0px); }

.menu-open .scrim { opacity: 1; pointer-events: auto; }
.menu-open .panel { transform: none; visibility: visible; transition: transform .7s cubic-bezier(.65,0,.35,1); }
/* Text arrives one by one once the panel is halfway; on close it just
   leaves with the panel */
.menu-open .panel nav a, .menu-open .panel .sub a {
  animation: menu-item .6s cubic-bezier(.22,1,.36,1) .35s backwards;
}
.menu-open .panel nav a:nth-child(2) { animation-delay: .42s; }
.menu-open .panel nav a:nth-child(3) { animation-delay: .49s; }
.menu-open .panel .sub { animation: menu-rule .6s ease .56s backwards; }
.menu-open .panel .sub a:nth-child(1) { animation-delay: .56s; }
.menu-open .panel .sub a:nth-child(2) { animation-delay: .63s; }
.menu-open .panel .sub a:nth-child(3) { animation-delay: .7s; }
@keyframes menu-item { from { opacity: 0; transform: translate3d(0, 14px, 0); } }
@keyframes menu-rule { from { border-top-color: transparent; } }
@media (prefers-reduced-motion: reduce) {
  .menu-open .panel nav a, .menu-open .panel .sub, .menu-open .panel .sub a { animation: none; }
}

/* ── "Our philosophy" closer — Figma: Playfair 42 / 682 wide, 45 to the button ── */
.philosophy {
  display: flex; flex-direction: column; align-items: center; gap: calc(45 * var(--k));
  width: calc(682 * var(--k)); max-width: calc(100% - 32px); margin: auto;
  text-align: center; text-decoration: none;
}
.philosophy p { font-family: var(--serif); font-size: calc(42 * var(--k)); line-height: 1.1; }

/* ── Client logos — Figma "Component 1": 20% opacity, 120 apart,
      1px 20% rule underneath. Loops slowly. ── */
.clients {
  position: relative; overflow: hidden;
  overflow-x: clip; overflow-y: visible;   /* clip the loop sideways only, so a taller logo isn't cut off */
  height: calc(90 * var(--k));
  border-bottom: 1px solid rgba(255,255,255,.2);
}
/* main.js fills the track with enough copies of the set to cover the
   screen plus one, then shifts by exactly one set width (in px) per loop,
   so there is never a gap or a jump. Speed is constant (see main.js). */
.clients__track {
  display: flex; align-items: center; width: max-content;
  height: calc(60 * var(--k)); opacity: .2;
}
.marquee__track { display: flex; width: max-content; }
.clients__track.is-running, .marquee__track.is-running {
  animation: clients-marquee var(--marquee-duration, 40s) linear infinite;
}
.clients__set { display: flex; align-items: center; gap: calc(120 * var(--k)); padding-right: calc(120 * var(--k)); }
.clients__set img { flex: none; width: auto; }
.clients__set .l-fifa    { height: calc(36 * var(--k)); }
.clients__set .l-sanctum { height: calc(36 * var(--k)); }
.clients__set .l-asics   { height: calc(53 * var(--k)); }
.clients__set .l-hera    { height: calc(48 * var(--k)); }
/* added 2026-12-02: sized by eye to the same visual weight (roughly equal area) */
.clients__set .l-bradbull   { height: calc(52 * var(--k)); }
.clients__set .l-stagelight { height: calc(22 * var(--k)); }
.clients__set .l-bounce     { height: calc(81 * var(--k)); }   /* 50% larger (client); pokes out of the 60 track, hence overflow-y visible on .clients */
.clients__set .l-klstr      { height: calc(28 * var(--k)); }
.clients__set .l-scc        { height: calc(40 * var(--k)); }
@keyframes clients-marquee {
  from { transform: translate3d(0, 0, 0); }
  to   { transform: translate3d(var(--marquee-shift, -50%), 0, 0); }
}
@media (prefers-reduced-motion: reduce) { .clients__track, .marquee__track { animation: none; } }

:focus-visible { outline: 1px solid var(--fg); outline-offset: 3px; }

/* Phones and portrait tablets (≤900): pin readable sizes */
/* ── More cases strip (case pages + expertise pages): 218 squares, 120 apart,
      drifting slowly (main.js loops it).
      Hover pauses and shows the case name (Playfair 36). ── */
.cs-more {
  --more-gap: calc(120 * var(--k));   /* between the tiles */
  position: relative; margin-top: var(--more-gap);   /* same as the space between the tiles */   /* closer to the quote than the tiles are to each other */
  overflow: hidden;
}
.cs-more .marquee__set { display: flex; gap: var(--more-gap); padding-right: var(--more-gap); }
.cs-more:hover .marquee__track { animation-play-state: paused; }
.more-tile {
  position: relative; flex: none; display: block;
  width: calc(218 * var(--k)); height: calc(218 * var(--k));
  text-decoration: none;
}
.more-tile img { display: block; width: 100%; height: 100%; object-fit: cover; }

/* Cursor label: over a tile the arrow disappears and the case name rides
   on the cursor (Playfair 36). Pointer devices only; built by main.js. */
@media (hover: hover) and (pointer: fine) {
  .cs-more.has-cursor-label, .cs-more.has-cursor-label .more-tile { cursor: none; }
}
.cursor-label {
  position: fixed; left: 0; top: 0; z-index: 25; pointer-events: none;
  font-family: var(--serif); font-size: calc(36 * var(--k)); line-height: 1.1;
  color: var(--fg); white-space: nowrap;
  opacity: 0; transition: opacity .25s ease;
  will-change: transform;
}
.cursor-label.is-on { opacity: 1; }

@media (max-width: 900px) {
  .btn { font-size: 14px; padding: 8px 18px; }
  .site-header { padding-top: 12px; gap: 6px; }
  .site-header .mark { height: 28px; }
  /* 44×44 tap area around the 22×28 logo, without moving it */
  .site-header > a { position: relative; }
  .site-header > a::after { content: ""; position: absolute; inset: -8px -6px -8px -16px; }
  .site-header button { width: 44px; height: 44px; }
  .burger i { width: 22px; height: 2px; margin: -1px 0 0 -11px; }
  .burger i:nth-child(1) { transform: translateY(-7px); }
  .burger i:nth-child(3) { transform: translateY(7px); }
  .menu-open .burger i:nth-child(1) { transform: rotate(45deg); }
  .menu-open .burger i:nth-child(3) { transform: rotate(-45deg); }
  .site-header > .site-header__glass { width: 104px; height: 64px; border-radius: 0 0 16px 16px; }
  .clients { height: 64px; }
  .clients__track { height: 44px; }
  .panel {
    width: 100%; padding: 120px 24px 32px; transform: translate3d(0, -100%, 0);   /* unfolds from the top */
    overflow-y: auto; overscroll-behavior: contain;   /* short landscape screens */
  }
  .panel nav { gap: 32px; align-items: center; text-align: center; }   /* centred on phones */
  .panel nav a { font-size: 34px; }
  .panel .sub a { font-size: 14px; }
  .philosophy p { font-size: 28px; }
  .more-tile { width: 160px; height: 160px; }
}
