/* =========================================================
   FONTS (self-hosted, geen extra verbinding naar Google)
========================================================= */

@font-face {
  font-family: 'Space Grotesk';
  src: url('../fonts/space-grotesk-latin.woff2') format('woff2');
  font-weight: 300 700;
  font-display: swap;
  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;
}

@font-face {
  font-family: 'Space Grotesk';
  src: url('../fonts/space-grotesk-latin-ext.woff2') format('woff2');
  font-weight: 300 700;
  font-display: swap;
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+1E00-1E9F, U+1EF2-1EFF, U+2C60-2C7F, U+A720-A7FF;
}

@font-face {
  font-family: 'Roboto Mono';
  src: url('../fonts/roboto-mono-latin.woff2') format('woff2');
  font-weight: 100 700;
  font-display: swap;
  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;
}

@font-face {
  font-family: 'Roboto Mono';
  src: url('../fonts/roboto-mono-latin-ext.woff2') format('woff2');
  font-weight: 100 700;
  font-display: swap;
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+1E00-1E9F, U+1EF2-1EFF, U+2C60-2C7F, U+A720-A7FF;
}

:root {
  --sugar-milk: #fcf6f6;
  --ruby: #9a230f;
  --ruby-light: #e3c0bc;
  --font: 'Space Grotesk', system-ui, sans-serif;
  --mono: 'Roboto Mono', ui-monospace, monospace;

  --page-max: 1264px;
  --page-gutter: 2rem;
  --page-gutter-mobile: 1rem;

  --header-clearance: 6.75rem;
  --project-gap: 2rem;

  /* Eén gedeelde easing voor alle bewegingen */
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
}

/* =========================================================
   BASE
========================================================= */

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

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  overflow-x: hidden;
  font-family: var(--font);
  background-color: var(--sugar-milk);
  color: var(--ruby);
  line-height: 1.6;
  font-weight: 400;
  letter-spacing: -0.02em;
}

img,
video {
  display: block;
  max-width: 100%;
}

a {
  cursor: pointer;
}

:focus-visible {
  outline: 2px solid var(--ruby);
  outline-offset: 4px;
}

/* Tekstselectie in de huisstijl: ruby vlak, sugar-milk tekst */
::selection {
  background: var(--ruby);
  color: var(--sugar-milk);
}

/* Op elementen die zelf al ruby zijn: omgekeerd */
.form-submit::selection,
.form-submit *::selection,
.cookie-btn-accept::selection,
.projects-top-button:hover::selection {
  background: var(--sugar-milk);
  color: var(--ruby);
}

.skip-link {
  position: absolute;
  left: 1rem;
  top: -4rem;
  z-index: 2000;
  padding: 0.5rem 1rem;
  background: var(--ruby);
  color: var(--sugar-milk);
  text-decoration: none;
}

.skip-link:focus {
  top: 1rem;
}

.container {
  width: 100%;
  max-width: var(--page-max);
  margin: 0 auto;
  padding-inline: var(--page-gutter);
}

.projects-body {
  cursor: url('../img/cursor-scroll.png'), auto;
}

/* =========================================================
   TYPOGRAPHY / LINKS
========================================================= */

.italic {
  font-style: italic;
  font-weight: 500;
}

.ruby-link {
  color: var(--ruby);
  text-decoration: none;
}

.link {
  color: inherit;
  text-decoration: none;
  font-weight: 400;
  transition: opacity 0.2s ease;
}

.link:hover {
  opacity: 0.7;
}

.underline {
  border-bottom: 1px solid var(--ruby);
}

/* "Read more →": pijl schuift mee bij hover */
.read-more {
  display: inline-flex;
  gap: 0.35em;
}

.read-more .arrow {
  display: inline-block;
  transition: transform 0.35s var(--ease-out);
}

.read-more:hover .arrow {
  transform: translateX(6px);
}

/* =========================================================
   HEADER
========================================================= */

.header {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 1000;
  background-color: var(--sugar-milk);
  border-bottom: 1px solid var(--ruby-light);
}

.nav {
  width: 100%;
  max-width: var(--page-max);
  margin: 0 auto;
  padding: 1.8rem var(--page-gutter);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

/* Logo: elke letter rolt bij hover omhoog en wordt vervangen door
   dezelfde letter in italic (zelfde taal als de nav-links).
   .is-rolling speelt dezelfde golf één keer heen en terug (site.js
   zet die class om de ±20 seconden). */

.nav-logo {
  display: inline-block;
  color: var(--ruby);
  font-size: 1.8rem;
  font-weight: 600;
  line-height: 1.1;
  text-decoration: none;
}

.logo-letters {
  display: inline-flex;
  gap: 0.28em;
}

.logo-word {
  display: inline-flex;
}

.logo-char {
  display: inline-block;
  /* Verticaal afknippen, horizontaal ruimte laten voor de italic */
  clip-path: inset(0 -0.3em);
}

.logo-char > span {
  position: relative;
  display: inline-block;
  transition: transform 0.55s var(--ease-out);
  transition-delay: calc(var(--i) * 22ms);
}

.logo-char > span::after {
  content: attr(data-char);
  position: absolute;
  left: 0;
  top: 100%;
  font-style: italic;
  font-weight: 400;
}

.nav-logo:hover .logo-char > span,
.nav-logo:focus-visible .logo-char > span {
  transform: translateY(-100%);
}

.nav-logo.is-rolling .logo-char > span {
  animation: logo-roll 1.6s var(--ease-out) both;
  animation-delay: calc(var(--i) * 45ms);
}

@keyframes logo-roll {
  0%, 100% { transform: translateY(0); }
  35%, 60% { transform: translateY(-100%); }
}

.nav-links {
  display: flex;
  gap: 2rem;
}

.nav-link {
  color: var(--ruby);
  text-decoration: none;
  font-weight: 700;
  font-size: 1.6rem;
  text-transform: uppercase;
  transition: opacity 0.2s ease;
}

.nav-link:hover {
  opacity: 0.7;
  font-style: italic;
  font-weight: 400;
}

.nav-link.active {
  font-style: italic;
  font-weight: 400;
}

/* Geen verspringen bij hover/active: een onzichtbare kopie van de tekst
   in de breedste stijl (data-text) houdt de breedte van de link vast. */
.nav-link,
.about-nav-link {
  display: inline-grid;
}

.nav-link::after,
.about-nav-link::after {
  content: attr(data-text);
  height: 0;
  overflow: hidden;
  visibility: hidden;
  font-style: normal;
  pointer-events: none;
  user-select: none;
}

.nav-link::after {
  font-weight: 700;
}

.about-nav-link::after {
  font-weight: 600;
}

/* =========================================================
   HERO / ROTATING OBJECT
========================================================= */

.hero-stage {
  min-height: 100svh;
  padding-top: var(--header-clearance);
  display: grid;
  grid-template-rows: minmax(0, 1fr) auto;
}

.slideshow-container {
  position: relative;
  width: 100%;
  min-height: 0;
  overflow: hidden;
  cursor: pointer;
}

.slide {
  position: absolute;
  inset: 0;
  display: none;
  place-items: center;
  margin: 0;
}

.slide.active {
  display: grid;
}

.slide img {
  width: auto;
  height: min(66vh, 720px);
  max-width: min(78vw, 1100px);
  object-fit: contain;
  user-select: none;
  -webkit-user-drag: none;
  transition: transform 0.45s var(--ease-out);
}

.slideshow-container.expanded .slide.active img {
  transform: scale(1.16);
}

/* Eerste keer laden: object "landt" zacht */
.has-motion .slideshow-container .slide.active img {
  animation: slide-in 0.6s var(--ease-out) both;
}

.has-motion .slideshow-container.is-running .slide.active img {
  animation: none;
}

@keyframes slide-in {
  from {
    opacity: 0;
    transform: translateY(16px) scale(0.98);
  }
}

#pause-instruction {
  margin: 0;
  padding: 0 1rem 1.25rem;
  text-align: center;
  font-family: var(--mono);
  font-size: 0.75rem;
  text-transform: uppercase;
}

/* =========================================================
   INTRO
========================================================= */

.current-projects-container {
  width: 100%;
  max-width: var(--page-max);
  margin: 0 auto;
  padding: 4rem var(--page-gutter) 2rem;
}

.main-heading {
  max-width: 1000px;
  margin: 0 0 4rem;
  font-size: clamp(2rem, 6vw, 4rem);
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: -0.03em;
}

.current-projects {
  max-width: 100%;
  margin: 0 0 4rem;
  font-size: clamp(1.5rem, 4vw, 3rem);
  font-weight: 600;
  line-height: 1.2;
  letter-spacing: -0.03em;
}

.last-updated {
  margin: 0;
  font-size: 1.125rem;
}

/* =========================================================
   TIMELINE
========================================================= */

.timeline {
  padding: 4rem 0;
}

.timeline-item {
  position: relative;
  padding-left: 1.5rem;
  margin-bottom: 3rem;
}

/* Lijn als apart element, zodat ze kan "intekenen" */
.timeline-item::before {
  content: '';
  position: absolute;
  inset: 0 auto 0 0;
  width: 2px;
  background: var(--ruby);
  transform-origin: top;
}

.timeline-badge {
  display: inline-block;
  margin-bottom: 0.5rem;
  padding: 0.5rem 0.75rem;
  background-color: var(--ruby-light);
  color: var(--ruby);
  font-family: var(--mono);
  font-size: 0.875rem;
  text-transform: uppercase;
}

.timeline-title {
  max-width: 800px;
  margin: 0 0 0.5rem;
  font-size: 1.25rem;
  font-weight: 600;
}

/* =========================================================
   SCROLL REVEALS
   Alleen actief als JS draait én er geen reduced motion is
   (.has-motion op <html>). Zonder JS is alles gewoon zichtbaar.
========================================================= */

.has-motion [data-reveal] {
  opacity: 0;
  transform: translate3d(0, 28px, 0);
  transition:
    opacity 0.8s var(--ease-out),
    transform 0.8s var(--ease-out);
  transition-delay: calc(var(--reveal-i, 0) * 90ms);
}

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

.has-motion .timeline-item[data-reveal]::before {
  transform: scaleY(0);
  transition: transform 0.9s var(--ease-out);
  transition-delay: calc(var(--reveal-i, 0) * 90ms + 150ms);
}

.has-motion .timeline-item[data-reveal].is-in::before {
  transform: scaleY(1);
}

/* =========================================================
   PROJECTS — HORIZONTAL SCROLL SCENES

   Desktop:
   - elk project is een lange scroll-scene
   - de tekst blijft vast in beeld
   - de beelden schuiven horizontaal OVER de tekst

   Moderne browsers: CSS scroll-driven animation (draait buiten
   de main thread, dus vloeiend). Andere browsers: flow.js zet
   --track-x per frame.
========================================================= */

.projects {
  position: relative;
}

.project-scene {
  --scene-height: 260vh;
  --start-x: 88vw;
  --end-x: -100vw;
  position: relative;
  height: var(--scene-height);
  width: 100%;
  view-timeline-name: --scene;
  view-timeline-axis: block;
}

.project-stage {
  position: sticky;
  top: 0;
  width: 100%;
  height: 100svh;
  overflow: clip;
  isolation: isolate;
}

.project-copy-layer {
  position: absolute;
  inset: 0;
  z-index: 1;
  display: flex;
  align-items: center;
  pointer-events: none;
}

.project-container {
  width: 100%;
  max-width: var(--page-max);
  margin: 0 auto;
  padding: calc(var(--header-clearance) + 1rem) var(--page-gutter) 4rem;
  pointer-events: auto;
}

.project-title {
  max-width: 1000px;
  margin: 0 0 1rem;
  font-size: clamp(2.4rem, 5.1vw, 5.5rem);
  font-weight: 700;
  line-height: 0.98;
  letter-spacing: -0.045em;
}

.project-meta {
  margin-bottom: 1rem;
  font-family: var(--mono);
  font-size: 0.875rem;
}

.project-description {
  max-width: 800px;
  margin: 0 0 1.5rem;
  font-size: 1.125rem;
}

.featured-project-undertext {
  max-width: 950px;
  margin: 0 0 2rem;
  font-size: 1.5rem;
}

.project-media-layer {
  position: absolute;
  inset: 0;
  z-index: 2;
  overflow: hidden;
  pointer-events: none;
}

.horizontal-scroll-wrapper {
  position: absolute;
  inset: 0;
  overflow: hidden;
}

.horizontal-scroll {
  --track-x: var(--start-x);
  position: absolute;
  top: 50%;
  left: 0;
  width: max-content;
  display: flex;
  align-items: center;
  gap: var(--project-gap);
  transform: translate3d(var(--track-x), -50%, 0);
  will-change: transform;
}

.project-media-item {
  flex: 0 0 auto;
  margin: 0;
  position: relative;
}

/* Losse, zwevende ritmiek */
.project-media-item:nth-child(5n + 1) { top: -6vh; --drift: 3vh; }
.project-media-item:nth-child(5n + 2) { top:  5vh; --drift: -4vh; }
.project-media-item:nth-child(5n + 3) { top: -2vh; --drift: 2vh; }
.project-media-item:nth-child(5n + 4) { top:  8vh; --drift: -3vh; }
.project-media-item:nth-child(5n + 5) { top: -4vh; --drift: 4vh; }

/* --r = breedte/hoogte (staat inline in de HTML). Zo ligt de maat
   vast vóór het beeld geladen is: geen verspringende strook. */
.project-media-item img,
.project-media-item video {
  height: min(60svh, 680px, calc(72vw / var(--r, 1)));
  width: auto;
  aspect-ratio: var(--r, auto);
  object-fit: contain;
  border: 1px solid var(--ruby);
  border-radius: 8px;
  background: var(--sugar-milk);
  user-select: none;
  -webkit-user-drag: none;
}

.project-index {
  position: absolute;
  right: max(var(--page-gutter), calc((100vw - var(--page-max)) / 2 + var(--page-gutter)));
  bottom: 1.25rem;
  z-index: 1;
  font-family: var(--mono);
  font-size: 0.75rem;
  letter-spacing: 0;
}

/* Voortgangsbalkje per project (alleen desktop + motion) */
.project-progress {
  display: none;
}

.mobile-gallery-hint {
  display: none;
}

/* ---------- Desktop motion ---------- */

@media (min-width: 768px) and (prefers-reduced-motion: no-preference) {

  .project-progress {
    display: block;
    position: absolute;
    left: max(var(--page-gutter), calc((100vw - var(--page-max)) / 2 + var(--page-gutter)));
    bottom: 1.6rem;
    z-index: 1;
    width: 120px;
    height: 2px;
    background: var(--ruby-light);
    overflow: hidden;
  }

  .project-progress span {
    display: block;
    height: 100%;
    background: var(--ruby);
    transform-origin: left;
    transform: scaleX(var(--progress, 0));
  }

  @supports (animation-timeline: view()) {

    .horizontal-scroll {
      animation: track-move linear both;
      animation-timeline: --scene;
      animation-range: contain 0% contain 100%;
    }

    .project-media-item img,
    .project-media-item video {
      animation: item-drift linear both;
      animation-timeline: --scene;
      animation-range: contain 0% contain 100%;
    }

    .project-progress span {
      animation: progress-fill linear both;
      animation-timeline: --scene;
      animation-range: contain 0% contain 100%;
    }

    /* Tekst komt binnen bij het begin van de scene */
    .project-container {
      animation: copy-enter linear both;
      animation-timeline: --scene;
      animation-range: entry 20% entry 100%;
    }
  }
}

@keyframes track-move {
  from { transform: translate3d(var(--start-x), -50%, 0); }
  to   { transform: translate3d(var(--end-x), -50%, 0); }
}

@keyframes item-drift {
  from { transform: translate3d(0, var(--drift, 0), 0); }
  to   { transform: translate3d(0, calc(var(--drift, 0) * -1), 0); }
}

@keyframes progress-fill {
  from { transform: scaleX(0); }
  to   { transform: scaleX(1); }
}

@keyframes copy-enter {
  from {
    opacity: 0;
    transform: translate3d(0, 6vh, 0);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

/* =========================================================
   PROJECTS — BACK TO TOP BUTTON
========================================================= */

/* TOP + NEXT als één groepje: positie en in/uitfaden op de groep */
.projects-jump {
  position: fixed;
  left: max(1rem, calc((100vw - var(--page-max)) / 2 - 5.5rem));
  top: 50%;
  z-index: 900;

  display: flex;
  flex-direction: column;
  gap: 0.5rem;

  opacity: 0;
  visibility: hidden;
  pointer-events: none;

  transform: translateY(-50%) translateX(-10px);

  transition:
    opacity 0.25s var(--ease-out),
    transform 0.25s var(--ease-out),
    visibility 0.25s;
}

.projects-jump.is-visible {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: translateY(-50%) translateX(0);
}

.projects-top-button,
.projects-next-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.3em;

  min-width: 66px;
  height: 40px;
  padding: 0 0.95rem;

  border: 2px solid var(--ruby);
  border-radius: 999px;

  background: var(--sugar-milk);
  color: var(--ruby);

  font-family: var(--font);
  font-size: 0.8rem;
  font-weight: 700;
  font-style: italic;
  line-height: 1;
  letter-spacing: 0.04em;

  text-decoration: none;
  text-transform: uppercase;

  transition: background-color 0.2s ease, color 0.2s ease;
}

.projects-top-button:hover,
.projects-top-button:focus-visible,
.projects-next-button:hover,
.projects-next-button:focus-visible {
  background: var(--ruby);
  color: var(--sugar-milk);
}

/* Pijltje van NEXT tikt even naar beneden bij hover */
.projects-next-button .arrow {
  display: inline-block;
  font-style: normal;
  transition: transform 0.35s var(--ease-out);
}

.projects-next-button:hover .arrow {
  transform: translateY(3px);
}

@media (min-width: 768px) and (max-width: 1450px) {
  .projects-jump {
    left: 1rem;
  }

  .projects-top-button,
  .projects-next-button {
    min-width: 62px;
    height: 38px;
    padding: 0 0.85rem;
    font-size: 0.76rem;
  }
}

/* =========================================================
   ABOUT
========================================================= */

.about {
  padding: 4rem 0;
  margin-top: 8rem;
}

.about-layout {
  display: flex;
  gap: 4rem;
  align-items: flex-start;
  width: 50%;
}

.about-nav {
  position: sticky;
  top: 160px;
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  gap: 1rem;
  font-weight: 600;
  font-size: 1.25rem;
}

.about-nav-link {
  color: var(--ruby);
  text-decoration: none;
  transition: opacity 0.2s ease;
}

.about-nav-link:hover {
  opacity: 0.8;
}

.about-nav-link.active {
  opacity: 1;
  font-style: italic;
  text-decoration: underline;
  font-weight: 400;
}

.about-grid {
  flex-grow: 1;
  display: flex;
  flex-direction: column;
  gap: 4rem;
}

.about-title {
  margin-bottom: 1.5rem;
  font-size: 1.5rem;
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: -0.03em;
}

.about-text {
  margin-bottom: 1.5rem;
  font-size: 1.125rem;
}

.about-row {
  display: flex;
  gap: 2rem;
  align-items: flex-start;
  flex-wrap: wrap;
}

.about-photo {
  max-width: 280px;
  height: auto;
  flex-shrink: 0;
  border: 1px solid var(--ruby);
  border-radius: 1rem;
}

.about-text-wrapper {
  position: relative;
  bottom: 1rem;
  flex: 1;
  min-width: 280px;
}

.capabilities-list {
  list-style: none;
  font-size: 1.125rem;
}

.capabilities-list li {
  margin-bottom: 0.5rem;
}

.social-links {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

#about-contact {
  position: relative;
  top: 7rem;
  margin-bottom: 16rem;
}

#big_title {
  position: relative;
  bottom: 2.5rem;
  margin-bottom: 0;
  font-size: 2.5rem;
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: -0.03em;
}

.big-title-contact {
  font-size: 4.5rem;
  line-height: 1;
  font-weight: 700;
  text-transform: uppercase;
}

/* =========================================================
   FOOTER
========================================================= */

.footer {
  border-top: 1px solid var(--ruby-light);
}

.footer-copyright {
  position: relative;
  overflow: hidden;
  white-space: nowrap;
}

.footer-repeat {
  display: inline-block;
  white-space: nowrap;
  font-size: 6rem;
  font-weight: 700;
  text-transform: uppercase;
  animation: scroll-left 30s linear infinite;
}

/* Marquee staat stil zolang de footer niet in beeld is */
.footer:not(.is-visible) .footer-repeat {
  animation-play-state: paused;
}

.footer-repeat .link:hover {
  text-decoration: underline;
}

@keyframes scroll-left {
  from { transform: translateX(0%); }
  to   { transform: translateX(-50%); }
}

/* =========================================================
   NAME HOVER PHOTO
   Eén foto die de muis volgt boven "Wolf Ver Elst".
   Positie, kanteling en schaal zet site.js via transform.
========================================================= */

.name-hover {
  position: fixed;
  left: 0;
  top: 0;
  z-index: 9999;
  width: 220px;
  height: 300px;
  margin: -150px 0 0 -110px;
  border: 1px solid var(--ruby);
  border-radius: 8px;
  overflow: hidden;
  pointer-events: none;
  opacity: 0;
  transform: translate3d(-400px, -400px, 0) scale(0.6);
  transition: opacity 0.25s var(--ease-out);
  will-change: transform, opacity;
}

.name-hover.is-active {
  opacity: 1;
}

.name-hover img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  /* Iets groter dan het kader, zodat de foto erin kan meeschuiven */
  transform: translate3d(var(--img-x, 0), var(--img-y, 0), 0) scale(1.15);
}

@media (hover: hover) and (pointer: fine) and (prefers-reduced-motion: no-preference) {
  #wolfverelst {
    cursor: none;
  }
}

@media (hover: none), (pointer: coarse), (prefers-reduced-motion: reduce) {
  .name-hover {
    display: none;
  }
}

/* =========================================================
   MOBILE
   Geen scroll-gekoppelde animatie.
   Projecten worden swipe-galerijen.
========================================================= */

@media (max-width: 767px) {
  :root {
    --header-clearance: 7.1rem;
  }

  .container,
  .current-projects-container {
    padding-left: var(--page-gutter-mobile);
    padding-right: var(--page-gutter-mobile);
  }

  .projects-body {
    cursor: auto;
  }

  .nav {
    padding: 1rem;
    flex-direction: column;
    gap: 1rem;
  }

  .nav-links {
    gap: 1rem;
  }

  .nav-logo {
    font-size: 1.45rem;
  }

  .nav-link {
    font-size: 1.15rem;
  }

  .slide img {
    height: min(55vh, 500px);
    max-width: 84vw;
  }

  #pause-instruction {
    padding-bottom: 1rem;
    font-size: 0.68rem;
  }

  .current-projects-container {
    padding-top: 3rem;
    text-align: center;
    align-items: center;
    display: flex;
    flex-direction: column;
  }

  .main-heading {
    margin: 0 0 2rem;
    font-size: 1.5rem;
    text-align: center;
  }

  .current-projects {
    margin: 0 0 2rem;
    font-size: 1.4rem;
  }

  .last-updated {
    font-size: 1rem;
  }

  .project-scene {
    height: auto !important;
    min-height: 0;
    padding: 4.5rem 0 2rem;
  }

  .project-stage {
    position: relative;
    top: auto;
    height: auto;
    overflow: visible;
    display: flex;
    flex-direction: column;
  }

  .project-copy-layer {
    position: relative;
    inset: auto;
    order: 1;
    display: block;
  }

  .project-container {
    padding: 0 var(--page-gutter-mobile) 1.5rem;
  }

  .project-title {
    font-size: clamp(2rem, 11vw, 3.2rem);
    line-height: 1;
  }

  .project-description {
    font-size: 1rem;
  }

  .featured-project-undertext {
    font-size: 1.05rem;
  }

  .project-media-layer {
    position: relative;
    inset: auto;
    order: 2;
    overflow: visible;
    pointer-events: auto;
  }

  .horizontal-scroll-wrapper {
    position: relative;
    inset: auto;
    width: 100%;
    height: var(--gallery-height, auto);
    padding: 0 0 8px;
    overflow-x: auto;
    overflow-y: hidden;
    scroll-snap-type: x mandatory;
    transition: height 0.25s var(--ease-out);
    scroll-padding-inline: var(--page-gutter-mobile);
    scrollbar-width: none;
    overscroll-behavior-inline: contain;
    -webkit-overflow-scrolling: touch;
  }

  .horizontal-scroll-wrapper::-webkit-scrollbar {
    display: none;
  }

  .horizontal-scroll {
    position: relative;
    inset: auto;
    top: auto;
    left: auto;
    width: max-content;
    display: flex;
    align-items: flex-start;
    gap: 12px;
    height: auto;
    padding: 0 12px;
    transform: none !important;
    will-change: auto;
  }

  .project-media-item,
  .project-media-item:nth-child(n) {
    position: relative;
    top: auto;
    flex: 0 0 auto;
    width: fit-content;
    height: auto;
    margin: 0;
    border: 0;
    border-radius: 0;
    overflow: visible;
    scroll-snap-align: center;
    scroll-snap-stop: always;
  }

  .project-media-item img,
  .project-media-item video {
    display: block;
    height: min(70svh, calc(84vw / var(--r, 1)));
    width: auto;
    object-fit: contain;
    background: transparent;
  }

  /* Swipe-galerij: niet-actieve beelden iets terug */
  .has-motion .project-media-item {
    transition: opacity 0.35s var(--ease-out), transform 0.35s var(--ease-out);
  }

  .has-motion .project-media-item:not(.is-current) {
    opacity: 0.55;
    transform: scale(0.96);
  }

  .mobile-gallery-hint {
    display: block;
    margin: 8px 12px 0;
    font-family: var(--mono);
    font-size: 0.72rem;
    text-transform: uppercase;
  }

  .project-index {
    display: none;
  }

  /* Mobiel: naast elkaar, linksonder */
  .projects-jump {
    top: auto;
    bottom: calc(1rem + env(safe-area-inset-bottom));
    left: calc(1rem + env(safe-area-inset-left));
    flex-direction: row;
    transform: translateY(10px);
  }

  .projects-jump.is-visible {
    transform: translateY(0);
  }

  .projects-top-button,
  .projects-next-button {
    min-width: 58px;
    height: 38px;
    padding: 0 0.8rem;
    font-size: 0.72rem;
    letter-spacing: 0.03em;
  }

  .about {
    margin-top: 4rem;
  }

  .about-nav {
    display: none;
  }

  .about-layout {
    width: 100%;
    flex-direction: column;
    align-items: center;
    text-align: center;
  }

  .about-row {
    flex-direction: column;
    align-items: center;
    text-align: center;
  }

  .about-text-wrapper,
  .about-grid,
  .about-text,
  .about-title,
  .capabilities-list {
    text-align: center;
  }

  .about-grid {
    gap: 2rem;
    align-items: center;
  }

  .capabilities-list {
    padding-left: 0;
  }

  #big_title {
    font-size: 2rem;
  }

  .big-title-contact {
    font-size: clamp(2.7rem, 14vw, 4.5rem);
  }

  .footer-repeat {
    font-size: 3rem;
  }
}

/* =========================================================
   REDUCED MOTION
   Geen scroll-jacking, geen autoplay, geen marquee.
   Galerijen worden gewoon horizontaal scrollbaar.
========================================================= */

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }

  .footer-repeat {
    animation: none;
  }

  .project-scene {
    height: auto !important;
    padding-block: 5rem;
  }

  .project-stage {
    position: relative;
    height: auto;
    overflow: visible;
  }

  .project-copy-layer,
  .project-media-layer {
    position: relative;
    inset: auto;
  }

  .project-media-layer {
    pointer-events: auto;
  }

  .horizontal-scroll-wrapper {
    position: relative;
    inset: auto;
    overflow-x: auto;
    scroll-snap-type: x proximity;
  }

  .horizontal-scroll {
    position: relative;
    top: auto;
    padding: 2rem var(--page-gutter);
    transform: none !important;
    will-change: auto;
  }

  .project-media-item,
  .project-media-item:nth-child(n) {
    top: auto;
    scroll-snap-align: start;
  }
}

/* =========================================================
   SUBPAGES (contact, privacy, bedankt)
========================================================= */

.subpage-main {
  min-height: 100svh;
  padding: calc(var(--header-clearance) + 4rem) 0 6rem;
}

.subpage-container {
  width: 100%;
  max-width: 880px;
  margin: 0 auto;
  padding-inline: var(--page-gutter);
}

.subpage-title {
  margin: 0.75rem 0 1.25rem;
  font-size: clamp(2.6rem, 7vw, 5.5rem);
  font-weight: 700;
  line-height: 0.98;
  letter-spacing: -0.045em;
}

.subpage-lead {
  max-width: 640px;
  margin: 0 0 3rem;
  font-size: clamp(1.15rem, 2.2vw, 1.5rem);
  font-weight: 500;
  line-height: 1.35;
}

/* Lopende tekst (privacy) */
.prose h2 {
  margin: 2.75rem 0 0.75rem;
  font-size: 1.5rem;
  line-height: 1.2;
  letter-spacing: -0.03em;
}

.prose p {
  max-width: 680px;
  margin: 0 0 1rem;
  font-size: 1.125rem;
}

.prose .last-updated {
  margin-top: 3rem;
  font-family: var(--mono);
  font-size: 0.85rem;
}

/* =========================================================
   CONTACT FORM
========================================================= */

.contact-form {
  display: grid;
  gap: 1.5rem;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5rem;
}

.form-field {
  display: grid;
  gap: 0.45rem;
}

.form-field label {
  font-family: var(--mono);
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.02em;
}

.form-field input,
.form-field select,
.form-field textarea {
  width: 100%;
  padding: 0.85rem 1rem;
  border: 1px solid var(--ruby);
  border-radius: 8px;
  background: var(--sugar-milk);
  color: var(--ruby);
  font: inherit;
  font-size: 1.05rem;
  letter-spacing: -0.01em;
  transition: box-shadow 0.25s var(--ease-out), background-color 0.25s ease;
}

.form-field textarea {
  min-height: 11rem;
  resize: vertical;
  line-height: 1.5;
}

.form-field select {
  appearance: none;
  background-image: linear-gradient(45deg, transparent 50%, var(--ruby) 50%),
    linear-gradient(135deg, var(--ruby) 50%, transparent 50%);
  background-position: calc(100% - 1.25rem) 50%, calc(100% - 0.9rem) 50%;
  background-size: 6px 6px;
  background-repeat: no-repeat;
  padding-right: 2.5rem;
}

.form-field input:focus,
.form-field select:focus,
.form-field textarea:focus {
  outline: none;
  background: #fff;
  box-shadow: 0 0 0 3px var(--ruby-light);
}

.form-field input:user-invalid,
.form-field textarea:user-invalid {
  box-shadow: 0 0 0 3px var(--ruby-light);
  border-style: dashed;
}

.form-honeypot {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.form-note {
  margin: 0;
  font-size: 0.95rem;
}

.form-submit {
  justify-self: start;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.95rem 1.6rem;
  border: 2px solid var(--ruby);
  border-radius: 999px;
  background: var(--ruby);
  color: var(--sugar-milk);
  font: inherit;
  font-size: 1rem;
  font-weight: 700;
  font-style: italic;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  text-decoration: none;
  cursor: pointer;
  transition: background-color 0.2s ease, color 0.2s ease;
}

.form-submit .arrow {
  display: inline-block;
  transition: transform 0.35s var(--ease-out);
}

.form-submit:hover,
.form-submit:focus-visible {
  background: var(--sugar-milk);
  color: var(--ruby);
}

.form-submit:hover .arrow {
  transform: translateX(6px);
}

.form-submit:disabled {
  opacity: 0.6;
  cursor: progress;
}

.form-status {
  margin: 0;
  min-height: 1.5em;
  font-family: var(--mono);
  font-size: 0.85rem;
}

/* =========================================================
   FOOTERS
========================================================= */

.footer-meta,
.footer-simple-inner {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.5rem 1.5rem;
  padding-block: 1.25rem;
  font-family: var(--mono);
  font-size: 0.8rem;
}

.footer-simple {
  padding-block: 0.5rem;
}

/* Knop die eruitziet als een link */
.cookie-settings-link {
  padding: 0;
  border: 0;
  background: none;
  color: inherit;
  font: inherit;
  cursor: pointer;
}

/* =========================================================
   COOKIE BANNER
========================================================= */

.cookie-banner {
  position: fixed;
  right: max(1rem, env(safe-area-inset-right));
  bottom: max(1rem, env(safe-area-inset-bottom));
  z-index: 1100;
  width: min(360px, calc(100vw - 2rem));
  padding: 1.25rem 1.25rem 1.1rem;
  border: 1px solid var(--ruby);
  border-radius: 12px;
  background: var(--sugar-milk);
  color: var(--ruby);
  box-shadow: 0 18px 40px -24px rgba(154, 35, 15, 0.45);
  opacity: 0;
  transform: translate3d(0, 16px, 0);
  transition: opacity 0.35s var(--ease-out), transform 0.35s var(--ease-out);
}

.cookie-banner.is-visible {
  opacity: 1;
  transform: none;
}

.cookie-banner-title {
  margin: 0 0 0.35rem;
  font-size: 1.35rem;
  font-weight: 700;
  font-style: italic;
  letter-spacing: -0.03em;
}

.cookie-banner-text {
  margin: 0 0 1rem;
  font-size: 0.95rem;
  line-height: 1.45;
}

.cookie-banner-actions {
  display: flex;
  gap: 0.6rem;
}

.cookie-btn {
  flex: 1;
  padding: 0.6rem 1rem;
  border: 2px solid var(--ruby);
  border-radius: 999px;
  background: var(--sugar-milk);
  color: var(--ruby);
  font: inherit;
  font-size: 0.85rem;
  font-weight: 700;
  font-style: italic;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  cursor: pointer;
  transition: background-color 0.2s ease, color 0.2s ease;
}

.cookie-btn:hover,
.cookie-btn:focus-visible,
.cookie-btn-accept {
  background: var(--ruby);
  color: var(--sugar-milk);
}

.cookie-btn-accept:hover,
.cookie-btn-accept:focus-visible {
  background: var(--sugar-milk);
  color: var(--ruby);
}

@media (max-width: 767px) {
  .subpage-main {
    padding-top: calc(var(--header-clearance) + 2.5rem);
  }

  .subpage-container {
    padding-inline: var(--page-gutter-mobile);
  }

  .form-row {
    grid-template-columns: 1fr;
  }

  .form-submit {
    justify-self: stretch;
    justify-content: center;
  }

  .footer-meta {
    justify-content: center;
    padding-inline: var(--page-gutter-mobile);
  }

  /* Banner boven de TOP-knop houden */
  .cookie-banner {
    left: 1rem;
    right: 1rem;
    width: auto;
  }
}
