/* Eva Immerzeel — portfolio site
   Fonts: Alumni Sans (nav/body) + Akira Expanded Super Bold (display headlines) */

@import url('https://fonts.googleapis.com/css2?family=Alumni+Sans:ital,wght@0,400;0,600;0,700;0,800;1,600&family=Unbounded:wght@700;800;900&family=Permanent+Marker&display=swap');

@font-face {
  font-family: 'Akira Expanded';
  src: url('../assets/fonts/AkiraExpanded-SuperBold.otf') format('opentype');
  font-weight: 700 900;
  font-style: normal;
  font-display: swap;
}

:root {
  --color-bg: #ffffff;
  --color-bg-soft: #f4f4f4;
  --color-black: #0a0a0a;
  --color-white: #ffffff;
  --color-footer-text: #ffe8e8;
  --font-body: 'Alumni Sans', 'Arial Narrow', sans-serif;
  --font-display: 'Akira Expanded', 'Unbounded', 'Alumni Sans', sans-serif;
  --ease-smooth: cubic-bezier(0.65, 0, 0.35, 1);
  --container: 1352px;
  --header-h: 96px;
  --page-pad: clamp(16px, 4vw, 40px);
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background: var(--color-bg);
  color: var(--color-black);
  font-family: var(--font-body);
  font-weight: 600;
  -webkit-font-smoothing: antialiased;
}

body > main { flex: 1 0 auto; }
body > .site-footer { flex: 0 0 auto; }

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

a { color: inherit; }

.container {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 40px;
}

/* ---------- Header ---------- */
.site-header {
  position: relative;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 34px 43px 24px;
}

.site-header.on-dark { color: var(--color-white); }

.site-header--overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  z-index: 20;
  background: transparent;
}

.site-header__logo {
  font-size: clamp(16px, 1.6vw, 24px);
  font-weight: 600;
  letter-spacing: 0.02em;
  text-decoration: none;
  white-space: nowrap;
  transition: opacity 0.25s var(--ease-smooth);
}

.site-header__logo:hover { opacity: 0.6; }

.site-nav {
  display: flex;
  align-items: center;
  gap: clamp(24px, 3vw, 48px);
}

.site-nav a {
  position: relative;
  font-size: clamp(15px, 1.6vw, 24px);
  font-weight: 600;
  text-decoration: none;
  white-space: nowrap;
  padding-bottom: 6px;
}

.site-nav a::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 2px;
  background: currentColor;
  transform: scaleX(0);
  transform-origin: right;
  transition: transform 0.4s var(--ease-smooth);
}

.site-nav a:hover::after,
.site-nav a:focus-visible::after {
  transform: scaleX(1);
  transform-origin: left;
}

.site-nav a[aria-current="page"]::after {
  transform: scaleX(1);
}

.nav-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
  color: inherit;
}

html.nav-locked { overflow: hidden; }

.site-nav__social { display: none; }

.nav-toggle svg { width: 28px; height: 28px; display: block; }
.nav-toggle .icon-close { display: none; }
.nav-toggle[aria-expanded="true"] .icon-open { display: none; }
.nav-toggle[aria-expanded="true"] .icon-close { display: block; }

/* ---------- Display / headline type ---------- */
.display {
  font-family: var(--font-display);
  font-weight: 900;
  font-style: normal;
  text-transform: uppercase;
  letter-spacing: 0.02em;
  line-height: 0.95;
  margin: 0;
}

.display--xl { font-size: clamp(48px, 8.5vw, 128px); }
.display--lg { font-size: clamp(40px, 6.8vw, 96px); }

.subtitle {
  font-family: var(--font-body);
  font-weight: 600;
  text-align: left;
  font-size: clamp(28px, 5vw, 60px);
  margin: 0;
  letter-spacing: 0.01em;
}

/* ---------- Footer ---------- */
.site-footer {
  background: var(--color-white);
  color: var(--color-black);
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 20px;
  flex-wrap: wrap;
  padding: 34px 43px;
  margin-top: 96px;
}

.social-row {
  display: flex;
  align-items: center;
  gap: 16px;
}

.social-row a { display: flex; }

.social-row img,
.social-row svg { width: 26px; height: 26px; }

.social-row--dark img { filter: none; }
.social-row--light img { filter: invert(1) brightness(2); }

/* ---------- Home ---------- */
.home-hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  overflow: hidden;
  padding: 80px 24px 120px;
  margin: 0;
}

.home-hero__bg-video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
  z-index: 0;
  pointer-events: none;
}

.home-hero__bg-video iframe {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 100vw;
  height: 56.25vw; /* 16:9 */
  min-height: 100vh;
  min-width: 177.78vh; /* 16:9 */
  transform: translate(-50%, -50%);
  border: 0;
}

.home-hero__overlay {
  position: absolute;
  inset: 0;
  background: rgba(255, 255, 255, 0.35);
  z-index: 0;
  pointer-events: none;
}

.home-hero__title {
  position: relative;
  z-index: 1;
  width: min(720px, 70vw);
  height: auto;
}

.home-hero__link {
  position: relative;
  z-index: 1;
  margin-top: 28px;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: clamp(20px, 3vw, 36px);
  letter-spacing: 0.15em;
  text-decoration: none;
  padding-bottom: 6px;
  background-image: linear-gradient(currentColor, currentColor);
  background-position: 0 100%;
  background-repeat: no-repeat;
  background-size: 100% 1px;
  transition: background-size 0.35s var(--ease-smooth), letter-spacing 0.35s var(--ease-smooth), opacity 0.35s var(--ease-smooth);
}

.home-hero__link:hover {
  letter-spacing: 0.2em;
  opacity: 0.7;
  background-size: 100% 2px;
}

.home-hero .social-row {
  position: absolute;
  z-index: 1;
  right: 40px;
  bottom: 40px;
}

.home-hero .social-row a {
  transition: transform 0.3s var(--ease-smooth), opacity 0.3s var(--ease-smooth);
}

.home-hero .social-row a:hover {
  transform: translateY(-3px);
  opacity: 0.7;
}

/* ---------- About ---------- */
.about-intro {
  min-height: 100vh;
  box-sizing: border-box;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 120px clamp(32px, 8vw, 80px) 60px;
}

.about-intro__signature {
  display: block;
  position: relative;
  z-index: 3;
  width: clamp(320px, 60vw, 820px);
  height: auto;
}

.about-intro__row {
  display: grid;
  grid-template-columns: 1.08fr 1fr;
  align-items: start;
  gap: clamp(20px, 3vw, 40px);
  width: 100%;
  max-width: 800px;
  margin-top: clamp(-90px, -8vw, -40px);
  position: relative;
  z-index: 2;
}

.about-intro__text {
  margin: 0;
  margin-top: 28%;
  text-align: left;
  font-size: clamp(19px, 1.75vw, 25px);
  line-height: 1.5;
}

.about-intro__photo {
  width: 90%;
  aspect-ratio: 2 / 3;
  overflow: hidden;
}

.about-intro__photo img { width: 100%; height: 100%; object-fit: cover; }

.about-details {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: clamp(32px, 5vw, 64px);
  padding: 90px clamp(32px, 8vw, 80px) 0;
  align-items: start;
}

.about-col {
  display: flex;
  flex-direction: column;
  gap: 48px;
}

.about-block h2 {
  font-family: var(--font-display);
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: 0.02em;
  font-size: clamp(19px, 1.75vw, 25px);
  margin: 0 0 14px;
}

.about-block p {
  margin: 0 0 6px;
  font-size: clamp(18px, 1.4vw, 23px);
  line-height: 1.4;
}

.about-block a { text-decoration: underline; }

.about-block__title { display: block; }

.about-block__date {
  display: block;
  opacity: 0.6;
  font-size: 0.92em;
  margin-bottom: 14px;
}

.about-instagram {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: clamp(24px, 4vw, 64px);
  margin: 96px clamp(32px, 8vw, 80px) 0;
  padding: clamp(28px, 4vw, 48px);
  background: var(--color-bg-soft);
  border-radius: 24px;
}

.about-instagram__handle {
  font-weight: 700;
  font-size: clamp(20px, 2vw, 28px);
  margin: 0 0 12px;
}

.about-instagram__text p:last-child {
  margin: 0;
  max-width: 320px;
  font-size: clamp(19px, 1.8vw, 25px);
  line-height: 1.4;
}

.about-instagram__grid { display: flex; gap: 10px; }

.about-instagram__item {
  display: block;
  width: clamp(90px, 12vw, 170px);
  aspect-ratio: 3 / 4;
  overflow: hidden;
  border-radius: 10px;
  transition: opacity 0.3s var(--ease-smooth);
}

.about-instagram__item:hover { opacity: 0.85; }

.about-instagram__placeholder {
  display: block;
  width: 100%;
  height: 100%;
  background: linear-gradient(135deg, #dcdcdc, #c4c4c4);
}

/* ---------- Portfolio ---------- */
.portfolio-hero {
  text-align: left;
  padding: 60px 43px 40px;
  position: relative;
}

.portfolio-hero .social-row {
  position: absolute;
  right: 40px;
  top: 68px;
}

.portfolio-grid {
  padding: 0 var(--page-pad);
  display: flex;
  flex-direction: column;
  gap: 0;
}

.portfolio-grid__row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0;
}

.portfolio-grid__item {
  position: relative;
  overflow: hidden;
  aspect-ratio: 480 / 700;
  display: block;
}

.portfolio-grid__item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s var(--ease-smooth);
}

.portfolio-grid__item:hover img { transform: scale(1.05); }

.portfolio-grid__item::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, rgba(0, 0, 0, 0.7) 0%, rgba(0, 0, 0, 0) 60%);
  opacity: 0;
  transition: opacity 0.4s var(--ease-smooth);
}

.portfolio-grid__item:hover::after { opacity: 1; }

.portfolio-grid__item .label {
  position: absolute;
  left: 24px;
  bottom: 22px;
  color: var(--color-white);
  font-family: var(--font-body);
  font-weight: 700;
  font-size: clamp(18px, 2vw, 26px);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  z-index: 1;
  opacity: 0;
  transform: translateY(12px);
  transition: opacity 0.4s var(--ease-smooth), transform 0.4s var(--ease-smooth);
}

.portfolio-grid__item:hover .label {
  opacity: 1;
  transform: translateY(0);
}

.portfolio-grid__item .year {
  position: absolute;
  right: 24px;
  bottom: 22px;
  color: var(--color-white);
  font-family: var(--font-body);
  font-weight: 700;
  font-size: clamp(18px, 2vw, 26px);
  letter-spacing: 0.04em;
  z-index: 1;
  opacity: 0;
  transform: translateY(12px);
  transition: opacity 0.4s var(--ease-smooth), transform 0.4s var(--ease-smooth);
}

.portfolio-grid__item:hover .year {
  opacity: 1;
  transform: translateY(0);
}

/* ---------- Contact ---------- */
.contact-main {
  background: var(--color-white);
  padding: 90px 24px 140px;
}

.contact-main .display { margin-bottom: 48px; }

.contact-info p {
  margin: 0;
  font-size: clamp(18px, 2.2vw, 36px);
  line-height: 1.5;
}

.contact-info .label {
  font-weight: 700;
  margin-top: 28px;
}

.contact-info a {
  text-decoration: underline;
}

.contact-main .social-row { margin-top: 40px; }
.contact-main .social-row img { width: 26px; height: 26px; }

.contact-lead {
  max-width: 900px;
  margin-bottom: 12px;
}

.word-rotator {
  display: inline-grid;
  overflow: hidden;
  vertical-align: baseline;
  transition: width 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.word-rotator__word {
  grid-row: 1;
  grid-column: 1;
  font-family: var(--font-display);
  font-weight: 800;
  white-space: nowrap;
  transform-origin: 50% 100%;
  opacity: 0;
  transform: rotateX(90deg) translateY(20%);
  transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1), opacity 0.4s ease;
  backface-visibility: hidden;
}

.word-rotator__word.is-active {
  opacity: 1;
  transform: rotateX(0deg) translateY(0);
}

.word-rotator__word.is-exiting {
  opacity: 0;
  transform: rotateX(-90deg) translateY(-20%);
}

/* ---------- Project pages ---------- */
.project-hero {
  text-align: left;
  max-width: var(--container);
  margin: 0 auto;
  padding: 50px var(--page-pad) 30px;
}

.project-hero .display { margin-bottom: 0; }

.project-hero .subtitle {
  margin-left: clamp(24px, 9vw, 130px);
  margin-top: clamp(-26px, -2.8vw, -8px);
}

.project-media {
  max-width: var(--container);
  margin: 0 auto;
  padding: 40px var(--page-pad) 0;
}

.project-media .container,
.project-media--full {
  display: block;
}

.pair {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
  max-width: 100%;
  aspect-ratio: 1437 / 1098;
  margin: 0 auto;
}

.pair img { width: 100%; height: 100%; object-fit: cover; object-position: center; display: block; }

.full-bleed img { width: 100%; height: auto; object-fit: cover; object-position: center; display: block; }

.full-bleed { max-width: var(--container); margin: 0 auto; padding: 0 var(--page-pad); }

.project-copy {
  padding: 56px 40px;
  max-width: var(--container);
  margin: 0 auto;
}

.project-copy p {
  font-size: clamp(17px, 1.7vw, 32px);
  line-height: 1.5;
  margin: 0 0 24px;
  max-width: 1320px;
}

.project-copy p:last-child { margin-bottom: 0; }

.caption {
  font-size: clamp(17px, 1.7vw, 32px);
  font-weight: 600;
  padding: 40px 40px 20px;
  max-width: var(--container);
  margin: 0 auto;
}

.gallery-pair {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  padding: 0 40px;
  max-width: var(--container);
  margin: 0 auto;
}

.gallery-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  padding: 0 40px;
  max-width: var(--container);
  margin: 0 auto;
}

.gallery-3 img,
.gallery-pair img {
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  border-radius: 2px;
}

.gallery-faded img { opacity: 0.55; }

/* ---------- Marquee (auto-scrolling image row) ---------- */
.marquee {
  overflow: hidden;
  width: 100%;
  margin-bottom: 20px;
  -webkit-mask-image: linear-gradient(to right, transparent 0, #000 var(--page-pad), #000 calc(100% - var(--page-pad)), transparent 100%);
  mask-image: linear-gradient(to right, transparent 0, #000 var(--page-pad), #000 calc(100% - var(--page-pad)), transparent 100%);
}

.marquee__track {
  display: flex;
  width: max-content;
  gap: 20px;
  padding: 0 20px;
  animation: marquee-scroll 34s linear infinite;
}

.marquee:hover .marquee__track { animation-play-state: paused; }

.marquee__track img {
  flex: 0 0 auto;
  width: clamp(220px, 26vw, 340px);
  aspect-ratio: 3 / 4;
  object-fit: cover;
  border-radius: 2px;
  display: block;
}

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

@media (prefers-reduced-motion: reduce) {
  .marquee__track { animation: none; }
}

.project-nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 60px 40px;
  max-width: var(--container);
  margin: 0 auto;
  gap: 20px;
  font-size: clamp(16px, 1.6vw, 22px);
}

.project-nav a {
  text-decoration: none;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  border-bottom: 2px solid transparent;
}

.project-nav a:hover { border-bottom-color: currentColor; }

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .site-header { padding: 22px 24px; }

  .nav-toggle { display: block; position: relative; z-index: 110; }
  .nav-toggle[aria-expanded="true"] { color: var(--color-black); }

  .site-nav {
    position: fixed;
    inset: 0;
    height: 100dvh;
    width: 100vw;
    background: var(--color-white);
    color: var(--color-black);
    counter-reset: nav-item;
    flex-direction: column;
    align-items: stretch;
    justify-content: center;
    gap: 0;
    padding: 100px 24px 40px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-12px);
    transition: opacity 0.35s ease, transform 0.35s ease, visibility 0s linear 0.35s;
    z-index: 100;
  }

  .site-nav.is-open {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
    transition: opacity 0.35s ease, transform 0.35s ease;
  }

  .site-nav a {
    counter-increment: nav-item;
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    font-size: 34px;
    padding: 20px 0;
    border-bottom: 1px solid rgba(10, 10, 10, 0.15);
  }

  .site-nav a::after {
    content: counter(nav-item, decimal-leading-zero);
    position: static;
    height: auto;
    background: none;
    transform: none;
    font-size: 16px;
    font-weight: 600;
    opacity: 0.5;
  }

  .site-nav__social {
    display: flex;
    counter-increment: none !important;
    margin-top: 32px;
    padding: 0 !important;
    border-bottom: none !important;
    font-size: 17px !important;
    font-weight: 500;
    opacity: 0.7;
  }

  .site-nav a.site-nav__social::after { content: none; }

  .nav-scrim { display: none; }

  .about-intro { padding: 100px 24px 50px; }
  .about-intro__signature { width: min(420px, 82vw); }
  .about-intro__row { grid-template-columns: 1fr; margin-top: 28px; }
  .about-intro__text { margin-top: 0; }
  .about-intro__photo { width: min(280px, 70vw); margin: 0 auto; }
  .about-details { grid-template-columns: 1fr; padding: 60px 24px 0; gap: 48px; }
  .about-instagram { margin: 60px 24px 0; flex-direction: column; align-items: flex-start; }
  .about-instagram__grid { width: 100%; }
  .about-instagram__item { flex: 1 1 0; width: auto; }

  .portfolio-grid__row { grid-template-columns: 1fr; }

  .pair,
  .gallery-pair,
  .gallery-3 {
    grid-template-columns: 1fr 1fr;
  }

  .project-copy, .caption { padding-left: 24px; padding-right: 24px; }
  .gallery-pair, .gallery-3 { padding-left: 24px; padding-right: 24px; }
  .project-hero, .project-media, .full-bleed { padding-left: 24px; padding-right: 24px; }
  .marquee__track img { width: clamp(180px, 40vw, 260px); }
  .project-nav { padding: 40px 24px; flex-direction: column; align-items: flex-start; }
  .site-footer { padding: 24px; }
}

@media (max-width: 560px) {
  .pair, .gallery-pair, .gallery-3 {
    grid-template-columns: 1fr;
  }

  .pair {
    aspect-ratio: auto;
    max-height: none;
  }

  .pair img {
    height: auto;
    aspect-ratio: 3 / 4;
    max-height: 100vh;
  }
}

/* ============================================================
   Motion & interaction layer — grain texture, custom cursor,
   scroll reveals, split-text headlines, magnetic nav, page fades.
   ============================================================ */

/* ---------- Grain texture ---------- */
.grain-overlay {
  position: fixed;
  inset: 0;
  z-index: 9990;
  pointer-events: none;
  opacity: 0.05;
  mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='180' height='180'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='2' stitchTiles='stitch'/></filter><rect width='100%25' height='100%25' filter='url(%23n)'/></svg>");
  background-size: 180px 180px;
}

/* ---------- Custom cursor ---------- */
@media (hover: hover) and (pointer: fine) {
  html.has-custom-cursor,
  html.has-custom-cursor a,
  html.has-custom-cursor button {
    cursor: none !important;
  }
}

.cursor-dot,
.cursor-ring {
  position: fixed;
  top: 0;
  left: 0;
  border-radius: 50%;
  pointer-events: none;
  z-index: 10000;
  opacity: 0;
  will-change: transform;
}

.cursor-dot {
  width: 6px;
  height: 6px;
  background: var(--color-black);
  transition: opacity 0.25s ease, background-color 0.3s ease;
}

.cursor-ring {
  width: 40px;
  height: 40px;
  margin: -20px 0 0 -20px;
  border: 1px solid rgba(10, 10, 10, 0.45);
  transition: opacity 0.25s ease, width 0.35s var(--ease-smooth),
    height 0.35s var(--ease-smooth), margin 0.35s var(--ease-smooth),
    border-color 0.3s ease, background-color 0.3s ease;
}

.cursor-dot { margin: -3px 0 0 -3px; }

.cursor-dot.is-visible,
.cursor-ring.is-visible { opacity: 1; }

.cursor-ring.is-hovering {
  width: 68px;
  height: 68px;
  margin: -34px 0 0 -34px;
  background: rgba(10, 10, 10, 0.06);
  border-color: transparent;
}

.cursor-ring.is-hovering-light {
  background: rgba(255, 255, 255, 0.12);
  border-color: rgba(255, 255, 255, 0.55);
}

.cursor-label {
  position: fixed;
  top: 0;
  left: 0;
  z-index: 10000;
  pointer-events: none;
  background: var(--color-white);
  color: var(--color-black);
  font-family: var(--font-body);
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  font-size: 13px;
  padding: 11px 20px;
  border-radius: 999px;
  opacity: 0;
  transition: opacity 0.3s ease;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.18);
}

.cursor-label.is-active { opacity: 1; }

@media (hover: none), (pointer: coarse) {
  .cursor-dot, .cursor-ring, .cursor-label { display: none !important; }
}

/* ---------- Scroll reveal ---------- */
[data-reveal] {
  opacity: 0;
  transform: translateY(32px);
  transition: opacity 0.9s var(--ease-smooth), transform 0.9s var(--ease-smooth);
  transition-delay: var(--reveal-delay, 0s);
}

[data-reveal].is-visible {
  opacity: 1;
  transform: translateY(0);
}

/* ---------- Split-text headline reveal ---------- */
.split-line {
  display: inline-block;
  overflow: hidden;
  vertical-align: top;
  margin-right: 0.28em;
}

.split-word {
  display: inline-block;
  transform: translateY(105%);
  opacity: 0;
  transition: transform 0.8s var(--ease-smooth), opacity 0.6s ease;
  transition-delay: calc(var(--i, 0) * 40ms);
}

.split-ready .split-word {
  transform: translateY(0);
  opacity: 1;
}

/* ---------- Magnetic elements ---------- */
[data-magnetic] {
  transition: transform 0.3s var(--ease-smooth);
}

/* ---------- Page transitions ---------- */
body {
  animation: page-in 0.7s var(--ease-smooth) forwards;
}

@keyframes page-in {
  from { opacity: 0; }
  to { opacity: 1; }
}

body.is-leaving {
  opacity: 0;
  transition: opacity 0.38s ease;
}

body.is-leaving-up {
  animation: swipe-up-exit 0.52s var(--ease-smooth) forwards;
}

@keyframes swipe-up-exit {
  to { transform: translateY(-100%); opacity: 0.9; }
}

/* ---------- Portfolio tile polish ---------- */

@media (prefers-reduced-motion: reduce) {
  [data-reveal],
  .split-word,
  body,
  .portfolio-grid__item img {
    transition: none !important;
    animation: none !important;
    opacity: 1 !important;
    transform: none !important;
    filter: none !important;
  }
}

@media (max-width: 900px) {
  [data-reveal] { transition-duration: 0.6s; transform: translateY(18px); }
}
