:root {
  --color-bg: #05060d;
  --color-bg-soft: #090a14;
  --color-surface: #10111a;
  --color-text: #f2eee8;
  --color-muted: #9f968c;
  --color-border: rgba(255, 255, 255, 0.12);
  --color-accent: #dfe8ff;
  --color-blue: #74a7c9;
  --radius-card: 22px;
  --radius-overlay: 28px;
  --space-xs: 4px;
  --space-sm: 8px;
  --space-md: 16px;
  --space-lg: 32px;
  --space-xl: 64px;
  --shadow-card: 0 24px 80px rgba(0, 0, 0, 0.55);
  --ease-premium: cubic-bezier(0.22, 1, 0.36, 1);
}

@property --active-border-angle {
  syntax: "<angle>";
  inherits: false;
  initial-value: 120deg;
}

@property --about-border-angle {
  syntax: "<angle>";
  inherits: false;
  initial-value: 132deg;
}

* {
  box-sizing: border-box;
}

html {
  color-scheme: dark;
  scroll-behavior: smooth;
  --scrollbar-thumb: rgba(140, 172, 245, 0.05);
  --scrollbar-track: rgba(5, 6, 13, 0.95);
  scrollbar-color: var(--scrollbar-thumb) var(--scrollbar-track);
  scrollbar-width: thin;
}

html.is-scrolling,
html:hover {
  --scrollbar-thumb: rgba(140, 172, 245, 0.32);
}

@supports not (scrollbar-color: auto) {
  ::-webkit-scrollbar {
    width: 8px;
    height: 8px;
  }

  ::-webkit-scrollbar-track {
    background: var(--scrollbar-track);
  }

  ::-webkit-scrollbar-thumb {
    background: var(--scrollbar-thumb);
    border-radius: 99px;
    border: 2px solid transparent;
    background-clip: padding-box;
    transition: background-color 180ms ease;
  }

  ::-webkit-scrollbar-thumb:hover {
    background-color: rgba(140, 172, 245, 0.42);
  }
}

::selection {
  background: rgba(140, 172, 245, 0.28);
  color: #fff;
}

:focus-visible {
  outline: 2px solid rgba(140, 172, 245, 0.6);
  outline-offset: 4px;
}

::view-transition-old(root),
::view-transition-new(root) {
  animation-duration: 0.6s;
  animation-timing-function: var(--ease-premium);
}



body {
  position: relative;
  min-height: 100vh;
  margin: 0;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  background: var(--color-bg);
  color: var(--color-text);
  font-family:
    Inter, Outfit, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI",
    sans-serif;
  letter-spacing: 0;
}

body::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background:
    radial-gradient(ellipse at 22% 0%, rgba(92, 60, 148, 0.17), transparent 35%),
    radial-gradient(ellipse at 74% 18%, rgba(50, 84, 148, 0.14), transparent 44%),
    radial-gradient(ellipse at 52% 72%, rgba(34, 42, 112, 0.08), transparent 48%),
    linear-gradient(118deg, rgba(70, 52, 118, 0.08) 0%, transparent 28%),
    linear-gradient(238deg, transparent 56%, rgba(48, 74, 134, 0.07) 84%, transparent 100%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.02), transparent 38%, rgba(0, 0, 0, 0.3) 100%);
  background-blend-mode: screen, screen, screen, screen, screen, overlay;
  opacity: 1;
  pointer-events: none;
}

body::after {
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  content: "";
  background:
    linear-gradient(90deg, rgba(0, 0, 0, 0.62), transparent 22%, transparent 78%, rgba(0, 0, 0, 0.62)),
    linear-gradient(180deg, transparent 0%, rgba(6, 8, 24, 0.12) 52%, rgba(0, 0, 0, 0.6) 100%),
    radial-gradient(ellipse at 50% 72%, transparent 0%, rgba(0, 0, 0, 0.36) 80%);
  opacity: 0.86;
}

html.has-overlay,
body.has-overlay {
  height: 100%;
  overflow: hidden;
}

html.is-selection-route,
body.is-selection-route {
  height: 100vh !important;
  height: 100dvh !important;
  overflow: hidden !important;
}

button,
a {
  -webkit-tap-highlight-color: transparent;
}

@media (max-width: 768px) {
  button:active,
  a:active {
    transform: scale(0.982);
    transition: transform 60ms ease;
  }
}

button {
  font: inherit;
}

:focus-visible {
  outline: 1px solid rgba(176, 202, 255, 0.34);
  outline-offset: 4px;
}

#app {
  min-height: 100vh;
  padding: clamp(22px, 2.5vh, 30px) 0 clamp(24px, 3vh, 40px);
}

.route-view[hidden] {
  display: none !important;
}

.site-header {
  position: sticky;
  top: 16px;
  z-index: 1000;
  display: flex;
  justify-content: center;
  padding-inline: clamp(18px, 4vw, 56px);
  pointer-events: none;
}

.site-nav {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: clamp(8px, 1.5vw, 16px);
  pointer-events: auto;
  padding: 8px;
  border: 1px solid rgba(190, 222, 235, 0.055);
  border-radius: 999px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.026), rgba(255, 255, 255, 0.006)),
    rgba(4, 9, 11, 0.22);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.035),
    0 12px 36px rgba(0, 0, 0, 0.16);
  backdrop-filter: blur(18px);
}

.site-nav__pill {
  position: absolute;
  top: 8px;
  bottom: 8px;
  left: 0;
  z-index: 1;
  border-radius: 999px;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.12) 0%, rgba(255, 255, 255, 0.03) 100%);
  box-shadow: 
    inset 0 1px 0 rgba(255, 255, 255, 0.20),
    inset 0 0 0 1px rgba(255, 255, 255, 0.08),
    0 4px 12px rgba(0, 0, 0, 0.24);
  pointer-events: none;
  transition: 
    transform 480ms cubic-bezier(0.25, 1, 0.2, 1.15), 
    width 400ms cubic-bezier(0.25, 1, 0.2, 1.1), 
    opacity 260ms ease;
  opacity: 0;
}


.site-nav__link {
  position: relative;
  z-index: 2;
  padding: 6px 14px;
  color: rgba(242, 238, 232, 0.22);
  font-size: clamp(0.76rem, 0.92vw, 0.86rem);
  font-weight: 470;
  line-height: 1;
  white-space: nowrap;
  text-decoration: none;
  user-select: none;
  transition: color 220ms ease;
}


.site-nav__link:hover,
.site-nav__link.is-active {
  color: rgba(242, 238, 232, 0.84);
}

.site-nav__link:focus-visible {
  outline: 0;
  color: rgba(242, 238, 232, 0.84);
}

.site-nav__link.is-active::after {
  position: absolute;
  right: 18%;
  bottom: -10px;
  left: 18%;
  height: 1px;
  border-radius: 999px;
  background: linear-gradient(90deg, transparent, rgba(136, 174, 226, 0.78), transparent);
  box-shadow: 0 0 14px rgba(116, 167, 201, 0.38);
  content: "";
}

/* Bouton "+" et Dropdown dans la Navigation */
.site-nav__more {
  position: relative;
  display: flex;
  align-items: center;
  margin-left: 4px;
}

.site-nav__more-trigger {
  display: grid;
  place-items: center;
  width: 26px;
  height: 26px;
  padding: 0;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.03);
  color: rgba(242, 238, 232, 0.45);
  cursor: pointer;
  transition: 
    border-color 220ms ease, 
    background-color 220ms ease, 
    color 220ms ease,
    transform 220ms cubic-bezier(0.34, 1.56, 0.64, 1);
  z-index: 2;
}

.site-nav__more-trigger:hover {
  border-color: rgba(255, 255, 255, 0.22);
  background-color: rgba(255, 255, 255, 0.08);
  color: rgba(242, 238, 232, 0.9);
}

.site-nav__more.is-open .site-nav__more-trigger {
  border-color: rgba(140, 172, 245, 0.35);
  background-color: rgba(140, 172, 245, 0.12);
  color: rgba(242, 238, 232, 0.95);
  transform: rotate(45deg);
}

.site-nav__dropdown {
  position: absolute;
  top: calc(100% + 14px);
  right: 0;
  z-index: 100;
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 124px;
  padding: 6px;
  border: 1px solid rgba(255, 255, 255, 0.09);
  border-radius: 14px;
  background: rgba(8, 9, 15, 0.88);
  box-shadow: 
    0 12px 36px rgba(0, 0, 0, 0.5),
    inset 0 1px 0 rgba(255, 255, 255, 0.04);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  opacity: 0;
  transform: translateY(6px) scale(0.96);
  pointer-events: none;
  transition: 
    opacity 240ms cubic-bezier(0.25, 1, 0.5, 1), 
    transform 240ms cubic-bezier(0.25, 1, 0.5, 1);
  transform-origin: top right;
}

.site-nav__more.is-open .site-nav__dropdown {
  opacity: 1;
  transform: translateY(0) scale(1);
  pointer-events: auto;
}

.site-nav__dropdown-item {
  display: flex;
  align-items: center;
  padding: 8px 14px;
  border-radius: 9px;
  color: rgba(242, 238, 232, 0.62);
  font-size: 0.76rem;
  font-weight: 500;
  text-decoration: none;
  white-space: nowrap;
  transition: 
    color 180ms ease, 
    background-color 180ms ease;
}

.site-nav__dropdown-item:hover {
  background-color: rgba(255, 255, 255, 0.06);
  color: rgba(242, 238, 232, 0.94);
}

.hero {
  display: grid;
  justify-items: center;
  padding: clamp(8px, 2vh, 22px) 20px 0;
  text-align: center;
}

.hero__logo {
  display: block;
  width: clamp(112px, 9.4vw, 150px);
  height: clamp(112px, 9.4vw, 150px);
  object-fit: contain;
  margin-bottom: -1px;
  opacity: 0.86;
  background: transparent;
  transform: translateZ(0);
}

.hero__title {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: center;
  gap: clamp(7px, 0.9vw, 13px);
  isolation: isolate;
  margin: 0;
  line-height: 0.96;
  text-shadow: none;
}

.hero__title-main,
.hero__title-mark {
  font-family:
    Outfit, sans-serif;
  font-size: clamp(1.42rem, 2.56vw, 2.55rem);
  letter-spacing: 0;
}

.hero__title-main {
  font-style: normal;
  font-weight: 320;
  color: rgba(242, 238, 232, 0.9);
}

.hero__title-mark {
  background:
    linear-gradient(
      105deg,
      rgba(242, 238, 232, 0.96) 0%,
      rgba(128, 174, 232, 0.96) 24%,
      rgba(236, 221, 194, 0.95) 48%,
      rgba(214, 231, 255, 0.98) 68%,
      rgba(242, 238, 232, 0.96) 100%
    );
  background-clip: text;
  background-size: 220% 100%;
  -webkit-text-fill-color: transparent;
  color: rgba(238, 240, 245, 0.93);
  font-style: italic;
  font-weight: 600;
  display: inline-block;
  padding-right: 0.1em;
  animation: motionTitleGradient 7s ease-in-out infinite alternate;
}

.hero__baseline {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
  width: auto;
  max-width: 90vw;
  margin: 22px auto 0;
}

.hero__baseline-item {
  display: inline-flex;
  align-items: center;
  padding: 5px 14px;
  border: 1px solid rgba(140, 172, 245, 0.14);
  border-radius: 999px;
  background: rgba(8, 9, 15, 0.42);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  color: rgba(242, 238, 232, 0.62);
  font-size: 0.74rem;
  font-weight: 500;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  box-shadow: 
    0 4px 12px rgba(0, 0, 0, 0.25),
    0 0 8px rgba(140, 172, 245, 0.02);
  transition: 
    border-color 260ms ease,
    background-color 260ms ease,
    color 260ms ease,
    transform 260ms cubic-bezier(0.25, 1, 0.5, 1);
}

.hero__baseline-item:hover {
  border-color: rgba(140, 172, 245, 0.38);
  background: rgba(140, 172, 245, 0.04);
  color: rgba(242, 238, 232, 0.88);
  transform: translateY(-1px);
}

.hero__baseline-item::before {
  display: none !important;
}

.carousel {
  --gallery-center-y: 60%;
  position: relative;
  display: grid;
  grid-template-columns: 1fr;
  grid-template-rows: minmax(302px, 34vh) auto;
  align-items: center;
  width: 100%;
  margin-top: clamp(10px, 2.2vh, 26px);
}

.carousel__stage {
  --drag: 0px;
  position: relative;
  grid-column: 1 / -1;
  grid-row: 1;
  width: 100%;
  height: 100%;
  min-height: 302px;
  perspective: 1500px;
  transform-style: preserve-3d;
  touch-action: pan-y pinch-zoom;
  user-select: none;
}

.carousel__stage:focus,
.carousel__stage:focus-visible {
  outline: 0;
}

.project-card {
  --active-border-angle: 120deg;
  position: absolute;
  top: var(--gallery-center-y);
  left: 50%;
  width: clamp(168px, 17.4vw, 352px);
  aspect-ratio: 1;
  padding: 0;
  border: none;
  border-radius: var(--radius-card);
  background: var(--color-surface);
  box-shadow:
    inset 0 0 0 1px rgba(255, 255, 255, 0.08),
    0 30px 60px rgba(0, 0, 0, 0.6);
  color: var(--color-text);
  cursor: pointer;
  opacity: var(--card-opacity, 1);
  transform:
    translate(-50%, -50%)
    translateX(calc((var(--shift-x-mult, 0) * clamp(126px, 11vw, 212px)) + var(--drag)))
    translateY(var(--shift-y))
    rotateY(var(--rotate-y))
    translateZ(var(--translate-z))
    scale(var(--scale));
  transition:
    transform 620ms var(--ease-premium),
    filter 420ms ease,
    border-color 240ms ease;
  z-index: var(--z);
  filter: brightness(var(--brightness)) saturate(var(--saturation));
  transform-style: preserve-3d;
  will-change: transform, opacity;
  overflow: visible !important;
}

.project-card__inner {
  position: relative;
  width: 100%;
  height: 100%;
  border-radius: inherit;
  overflow: hidden;
  transform-style: preserve-3d;
  /* Masque matériel pour forcer le rognage des coins arrondis sur Safari durant les transformations 3D */
  -webkit-mask-image: -webkit-radial-gradient(white, black);
  transform: translate3d(0, 0, 0);
}


.project-card__inner::after {
  position: absolute;
  inset: 0;
  z-index: 1;
  border-radius: inherit;
  background:
    linear-gradient(90deg, rgba(0, 0, 0, 0.08), transparent 34%, transparent 66%, rgba(0, 0, 0, 0.08)),
    rgba(0, 0, 0, var(--veil-opacity));
  content: "";
  pointer-events: none;
  transition: opacity 420ms ease;
}

.project-card__inner::before {
  position: absolute;
  inset: 0;
  z-index: 2;
  border-radius: inherit;
  background:
    linear-gradient(
      128deg,
      transparent 0%,
      transparent 32%,
      rgba(255, 255, 255, 0.24) 46%,
      rgba(255, 255, 255, 0.38) 50%,
      rgba(255, 255, 255, 0.24) 54%,
      transparent 68%,
      transparent 100%
    );
  content: "";
  mix-blend-mode: overlay;
  opacity: 0;
  pointer-events: none;
  transform: translateX(-55%) scaleX(1.2) skewX(-15deg);
  transition:
    opacity 350ms ease,
    transform 920ms var(--ease-premium);
}



.carousel__stage.is-dragging .project-card {
  transition-duration: 90ms;
}

.project-card.is-active {
  box-shadow:
    inset 0 0 0 1px rgba(255, 255, 255, 0.25),
    0 0 30px rgba(255, 255, 255, 0.04),
    0 40px 80px rgba(0, 0, 0, 0.8);
}

.project-card.is-active .project-card__inner::before {
  opacity: 0.12;
  transform: translateX(0) scaleX(1.08);
}

.project-card:hover {
  filter: brightness(calc(var(--brightness) + 0.08)) saturate(1);
}

.project-card.is-active:hover .project-card__inner::before {
  opacity: 0.45;
  transform: translateX(55%) scaleX(1.2) skewX(-15deg);
}

/* Reflets 3D DOM Réels (Miroir Satiné) */
.project-card__reflection {
  position: absolute;
  top: calc(100% + 2px);
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  transform: scaleY(-1) translateZ(-1px);
  opacity: var(--card-reflect-opacity, 0.16);
  filter: blur(2px); /* High-end satin mirror reflection */
  transition: opacity 620ms var(--ease-premium);
  transform-style: preserve-3d;
}

.project-card__reflection-img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  clip-path: inset(0 round var(--radius-card));
  opacity: 0.82;
}

.project-card__reflection-shade {
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: linear-gradient(
    to bottom,
    var(--color-bg) 0%,
    var(--color-bg) 48%,
    rgba(5, 6, 13, 0.82) 70%,
    rgba(5, 6, 13, 0.45) 84%,
    rgba(5, 6, 13, 0.15) 94%,
    rgba(5, 6, 13, 0) 100%
  );
}



.project-card__image {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center center;
  transform: scale(1.02);
  transform-origin: center center;
  clip-path: inset(0 round var(--radius-card));
  transition: transform 380ms var(--ease-premium);
}

.project-card.is-active:hover .project-card__image {
  transform: translate(calc(var(--mouse-x, 0) * -12px), calc(var(--mouse-y, 0) * -12px)) scale(1.05);
}

.project-card__shade {
  position: absolute;
  inset: auto 0 0;
  z-index: 2;
  height: 40%;
  background: linear-gradient(180deg, transparent, rgba(0, 0, 0, 0.72) 80%);
}


.project-card__meta {
  position: absolute;
  z-index: 3;
  left: clamp(16px, 1.6vw, 23px);
  right: clamp(16px, 1.6vw, 23px);
  bottom: clamp(16px, 1.6vw, 23px);
  display: grid;
  gap: 7px;
  text-align: left;
}

.project-card__tags {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  max-width: 100%;
}

.project-card__tag,
.portfolio-card__tag {
  display: inline-flex;
  align-items: center;
  min-height: 16px;
  padding: 3px 7px 3px 5px;
  border: none;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.35);
  backdrop-filter: blur(4px);
  color: rgba(242, 238, 232, 0.72);
  font-size: clamp(0.42rem, 0.46vw, 0.5rem);
  font-weight: 540;
  letter-spacing: 0.01em;
  line-height: 1;
  white-space: nowrap;
}

.project-card__tag::before,
.portfolio-card__tag::before {
  width: 5px;
  height: 5px;
  margin-right: 4px;
  border-radius: 999px;
  background: rgb(var(--tag-tone));
  box-shadow: 0 0 10px rgba(var(--tag-tone), 0.45);
  content: "";
}

.project-card__title {
  font-family:
    Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI",
    sans-serif;
  font-size: clamp(0.92rem, 1.12vw, 1.08rem);
  font-weight: 620;
  line-height: 1.08;
}

.carousel__arrow,
.video-overlay__nav,
.video-overlay__close {
  display: grid;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.035);
  color: rgba(242, 238, 232, 0.76);
  cursor: pointer;
  backdrop-filter: blur(18px);
  transition:
    transform 180ms ease,
    background 180ms ease,
    border-color 180ms ease;
}

.carousel__arrow:hover,
.video-overlay__nav:hover,
.video-overlay__close:hover {
  border-color: rgba(255, 255, 255, 0.2);
  background: rgba(255, 255, 255, 0.075);
  transform: scale(1.04);
}

.carousel__arrow:hover {
  transform: scale(1.04);
}

.video-overlay__nav:hover {
  transform: translateY(-50%) scale(1.04);
}

.carousel__arrow svg,
.video-overlay__nav svg,
.video-overlay__close svg {
  width: 28px;
  height: 28px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.5;
}

.carousel__arrow {
  position: absolute;
  top: var(--gallery-center-y);
  z-index: 220;
  width: 64px;
  height: 64px;
  margin-top: -32px;
  border: 1px solid rgba(140, 172, 245, 0.16);
  background: rgba(8, 9, 15, 0.45);
  color: rgba(242, 238, 232, 0.72);
  box-shadow: 
    0 8px 32px rgba(0, 0, 0, 0.4),
    0 0 16px rgba(140, 172, 245, 0.03);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  user-select: none;
  transition: 
    border-color 300ms ease,
    background-color 300ms ease,
    color 300ms ease,
    box-shadow 300ms ease,
    transform 300ms cubic-bezier(0.25, 1, 0.5, 1);
}

.carousel__arrow:hover {
  border-color: rgba(140, 172, 245, 0.52) !important;
  background: rgba(140, 172, 245, 0.06) !important;
  color: rgba(242, 238, 232, 0.98) !important;
  box-shadow: 
    0 10px 36px rgba(0, 0, 0, 0.5),
    0 0 24px rgba(140, 172, 245, 0.22) !important;
}

@media (max-width: 640px) {
  .carousel__arrow {
    display: none;
  }
}

.carousel__arrow--prev {
  left: clamp(24px, 4vw, 64px);
}

.carousel__arrow--next {
  right: clamp(24px, 4vw, 64px);
}

    width 300ms var(--ease-premium),
    background 300ms ease,
    box-shadow 300ms ease,
    opacity 300ms ease;
}

.carousel__dot.is-active {
  width: 28px;
  background: linear-gradient(90deg, rgba(177, 207, 255, 0.95), rgba(228, 210, 170, 0.9));
  box-shadow: 0 0 8px rgba(177, 207, 255, 0.25);
}

.carousel__dot.is-hidden {
  opacity: 0;
  pointer-events: none;
}

.selection-actions {
  display: flex;
  justify-content: center;
  margin-top: clamp(55px, 9vh, 100px);
}

.selection-actions__link {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 12px;
  padding: 15px 28px;
  border: 1px solid rgba(140, 172, 245, 0.16);
  border-radius: 999px;
  background: rgba(8, 9, 15, 0.45);
  color: rgba(242, 238, 232, 0.72);
  font-size: 0.88rem;
  font-weight: 540;
  letter-spacing: 0.04em;
  text-decoration: none;
  box-shadow: 
    0 8px 32px rgba(0, 0, 0, 0.4),
    0 0 16px rgba(140, 172, 245, 0.03);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  overflow: hidden;
  transition: 
    border-color 300ms ease,
    background-color 300ms ease,
    color 300ms ease,
    box-shadow 300ms ease,
    transform 300ms cubic-bezier(0.25, 1, 0.5, 1);
}

.selection-actions__link::after {
  content: "";
  position: absolute;
  top: 0;
  left: -100%;
  width: 50%;
  height: 100%;
  background: linear-gradient(to right, transparent, rgba(140, 172, 245, 0.15), transparent);
  transform: skewX(-20deg);
}

.selection-actions__link:hover {
  border-color: rgba(140, 172, 245, 0.52);
  background: rgba(140, 172, 245, 0.06);
  color: rgba(242, 238, 232, 0.98);
  box-shadow: 
    0 10px 36px rgba(0, 0, 0, 0.5),
    0 0 24px rgba(140, 172, 245, 0.22);
  transform: translateY(-2px);
}

.selection-actions__link:hover::after {
  animation: sweepShine 1.5s ease;
}

.selection-actions__link span:first-child {
  display: grid;
  place-items: center;
  width: 17px;
  height: 17px;
  border-radius: 999px;
  background: rgba(128, 174, 232, 0.13);
  color: rgba(211, 229, 255, 0.88);
  font-size: 0.9rem;
  font-weight: 380;
}

.selection-actions__link em {
  color: rgba(242, 238, 232, 0.94);
  font-family:
    Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI",
    sans-serif;
  font-style: normal;
  font-weight: 700;
}

.portfolio-view {
  width: min(100%, 1240px);
  margin: 0 auto;
  padding: clamp(62px, 8vh, 98px) clamp(18px, 4vw, 54px) 0;
}

.portfolio-view__header {
  display: grid;
  gap: 12px;
  max-width: 680px;
  margin: 0 auto clamp(26px, 4vh, 42px);
  text-align: center;
}

.portfolio-view__eyebrow,
.portfolio-view__header h1 {
  margin: 0;
}

.portfolio-view__eyebrow {
  color: rgba(242, 238, 232, 0.42);
  font-size: 0.68rem;
  font-weight: 560;
  letter-spacing: 0.1em;
  line-height: 1.1;
  text-transform: uppercase;
}

.portfolio-view__header h1 {
  color: rgba(242, 238, 232, 0.88);
  font-size: clamp(1.65rem, 3vw, 3rem);
  font-weight: 380;
  line-height: 1.04;
}


.category-filters {
  position: relative;
  display: flex;
  flex-wrap: nowrap;
  justify-content: center;
  gap: 7px;
  width: min(100%, 960px);
  margin: 0 auto clamp(28px, 4vh, 44px);
  padding: 8px;
  border: 1px solid rgba(190, 222, 235, 0.07);
  border-radius: 999px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.024), rgba(255, 255, 255, 0.006)),
    rgba(255, 255, 255, 0.012);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.035),
    0 18px 54px rgba(0, 0, 0, 0.18);
  backdrop-filter: blur(18px);
}

.category-filters__button {
  min-height: 30px;
  padding: 7px 13px;
  border: 1px solid rgba(255, 255, 255, 0.065);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.018);
  color: rgba(242, 238, 232, 0.46);
  cursor: pointer;
  font-size: 0.72rem;
  font-weight: 500;
  line-height: 1;
  white-space: nowrap;
  transition:
    color 180ms ease,
    border-color 180ms ease,
    background 180ms ease,
    transform 180ms ease;
}

.category-filters__button:hover,
.category-filters__button[aria-pressed="true"] {
  border-color: rgba(150, 190, 230, 0.24);
  background:
    linear-gradient(120deg, rgba(116, 167, 201, 0.12), rgba(255, 255, 255, 0.035)),
    rgba(223, 232, 255, 0.045);
  color: rgba(242, 238, 232, 0.82);
}

.category-filters__button:hover {
  transform: translateY(-1px);
}

.portfolio-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: clamp(12px, 1.4vw, 18px);
}

.portfolio-card {
  position: relative;
  display: grid;
  gap: 12px;
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--color-text);
  cursor: pointer;
  text-align: left;
  opacity: 0;
  animation: fadeInUpStagger 620ms var(--ease-premium) forwards;
  animation-delay: calc(var(--card-index) * 35ms);
}

.portfolio-card__media {
  position: relative;
  display: block;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  border: 1px solid rgba(242, 238, 232, 0.085);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.03);
  box-shadow: 0 20px 70px rgba(0, 0, 0, 0.34);
  transform: translateZ(0);
  transition:
    border-color 220ms ease,
    box-shadow 220ms ease,
    transform 260ms var(--ease-premium);
}

.portfolio-card__media::after {
  position: absolute;
  inset: auto 0 0;
  z-index: 1;
  height: 42%;
  background: linear-gradient(180deg, transparent, rgba(0, 0, 0, 0.56));
  content: "";
}

.portfolio-card__media img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: scale(1.015);
  transition: transform 360ms var(--ease-premium);
}

.portfolio-card__placeholder {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  padding: 24px;
  background:
    radial-gradient(circle at 34% 26%, rgba(132, 156, 235, 0.24), transparent 35%),
    radial-gradient(circle at 75% 76%, rgba(112, 74, 178, 0.22), transparent 42%),
    linear-gradient(135deg, rgba(255, 255, 255, 0.05), rgba(255, 255, 255, 0.012)),
    rgba(8, 9, 20, 0.94);
  color: rgba(242, 238, 232, 0.7);
  font-size: clamp(0.9rem, 1.16vw, 1.24rem);
  font-weight: 540;
  line-height: 1.05;
  text-align: center;
}

.portfolio-card__media-tags {
  position: absolute;
  right: 12px;
  bottom: 12px;
  left: 12px;
  z-index: 2;
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
}

.portfolio-card:hover .portfolio-card__media {
  border-color: rgba(223, 232, 255, 0.22);
  box-shadow: 0 24px 78px rgba(0, 0, 0, 0.45);
  transform: translateY(-2px);
}

.portfolio-card:hover .portfolio-card__media img {
  transform: scale(1.045);
}

.portfolio-card__body {
  display: grid;
  gap: 8px;
  min-width: 0;
  min-height: 1.2em;
}


.portfolio-card__title {
  color: rgba(242, 238, 232, 0.86);
  font-size: clamp(0.92rem, 1.05vw, 1.08rem);
  font-weight: 620;
  line-height: 1.08;
  min-height: 2.16em;
}

.custom-cursor {
  --cursor-x: 50vw;
  --cursor-y: 50vh;
  position: fixed;
  top: 0;
  left: 0;
  z-index: 9999;
  width: 30px;
  height: 30px;
  border: 1px solid rgba(242, 238, 232, 0.42);
  border-radius: 999px;
  opacity: 0;
  pointer-events: none;
  transform: translate3d(calc(var(--cursor-x) - 50%), calc(var(--cursor-y) - 50%), 0);
  will-change: transform, opacity;
  transition:
    width 180ms ease,
    height 180ms ease,
    border-color 180ms ease,
    background 180ms ease,
    opacity 160ms ease;
  mix-blend-mode: exclusion;
}

.custom-cursor__trail {
  position: absolute;
  inset: -8px;
  border-radius: inherit;
  background:
    conic-gradient(from 120deg, rgba(255, 255, 255, 0), rgba(216, 255, 242, 0.46), rgba(201, 221, 255, 0.4), rgba(255, 255, 255, 0));
  opacity: 0;
  filter: blur(6px);
  transform: scale(0.78) rotate(0deg);
  transition:
    opacity 180ms ease,
    transform 260ms var(--ease-premium);
}

.custom-cursor__dot {
  position: absolute;
  inset: 50% auto auto 50%;
  width: 4px;
  height: 4px;
  border-radius: 999px;
  background: #fff;
  transform: translate(-50%, -50%);
}

.custom-cursor.is-visible {
  opacity: 1;
}

.custom-cursor.is-moving .custom-cursor__trail {
  opacity: 0.62;
  transform: scale(1.08) rotate(14deg);
}

.custom-cursor.is-interactive {
  width: 48px;
  height: 48px;
  border-color: rgba(140, 172, 245, 0.62);
  background: rgba(140, 172, 245, 0.04);
  box-shadow: 0 0 16px rgba(140, 172, 245, 0.22);
}

@media (pointer: fine) and (prefers-reduced-motion: no-preference) {
  .has-custom-cursor,
  .has-custom-cursor * {
    cursor: none !important;
  }
}

.video-overlay {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: grid;
  place-items: center;
  padding: clamp(12px, 2.6vw, 34px);
  background: rgba(0, 0, 0, 0.82);
  opacity: 0;
  overflow: hidden;
  pointer-events: none;
  transition: opacity 260ms ease;
  backdrop-filter: blur(14px);
}

.video-overlay[aria-hidden="false"] {
  opacity: 1;
  pointer-events: auto;
}

.video-overlay__panel {
  --overlay-width: 1500px;
  position: relative;
  width: min(100%, var(--overlay-width));
  max-height: 100%;
  display: grid;
  grid-template-rows: auto auto;
  gap: 16px;
  transform: translateY(14px) scale(0.985);
  transition: transform 320ms var(--ease-premium);
  will-change: transform;
}

.video-overlay[aria-hidden="false"] .video-overlay__panel {
  transform: translateY(0) scale(1);
}

.video-overlay__panel:focus,
.video-overlay__panel:focus-visible {
  outline: 0;
}

.video-overlay__topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.video-overlay__meta {
  min-width: 0;
}

.video-overlay__meta p,
.video-overlay__meta h2,
.video-overlay__meta small {
  margin: 0;
}

.video-overlay__meta p {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--color-muted);
  font-size: 0.72rem;
  font-weight: 650;
  line-height: 1.2;
  text-transform: uppercase;
}

.video-overlay__meta p span {
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: currentColor;
}

.video-overlay__meta h2 {
  margin-top: 5px;
  font-family: Outfit, sans-serif;
  font-size: clamp(1.35rem, 3vw, 2.35rem);
  font-weight: 500;
  line-height: 1;
}

.video-overlay__meta small {
  display: block;
  margin-top: 8px;
  color: rgba(242, 238, 232, 0.62);
  font-size: 0.82rem;
}

.video-overlay__close {
  flex: 0 0 auto;
  width: 48px;
  height: 48px;
}

.video-overlay__player-shell {
  position: relative;
  display: grid;
  place-items: center;
  min-height: 0;
  overflow: hidden;
}

.video-overlay__player {
  --video-ratio: 16 / 9;
  --video-width: 100%;
  display: grid;
  place-items: center;
  width: min(100%, var(--video-width));
  max-width: 2400px;
  aspect-ratio: var(--video-ratio);
  transition:
    width 260ms var(--ease-premium),
    aspect-ratio 260ms var(--ease-premium);
}

.video-overlay__player > video {
  width: 100%;
  height: 100%;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: var(--radius-card);
  background: #000;
  box-shadow: 
    0 32px 100px rgba(0, 0, 0, 0.8),
    0 0 32px rgba(140, 172, 245, 0.08);
  object-fit: contain;
}

.video-overlay__player.is-controls-hidden > video {
  cursor: pointer;
}

.video-overlay__multi-container {
  display: flex;
  flex-direction: row;
  gap: 16px;
  width: 100%;
  height: 100%;
  justify-content: center;
  align-items: center;
}

.video-overlay__multi-container video {
  flex: 1 1 0%;
  min-width: 0;
  width: auto;
  height: 100%;
  object-fit: contain;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: var(--radius-card);
  background: #000;
  box-shadow: 
    0 16px 48px rgba(0, 0, 0, 0.6),
    0 0 16px rgba(140, 172, 245, 0.04);
}

@media (max-width: 768px) {
  .video-overlay__player {
    aspect-ratio: auto !important;
    width: 100% !important;
    height: auto !important;
  }

  .video-overlay__multi-container {
    flex-direction: column;
    overflow-y: auto;
    height: auto;
    max-height: 70vh;
    padding: 10px;
    gap: 20px;
  }
  
  .video-overlay__multi-container video {
    width: 100%;
    height: auto;
    aspect-ratio: 4 / 5;
    flex: none;
  }
}

.video-overlay__loading {
  position: absolute;
  z-index: 2;
  padding: 10px 14px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 999px;
  background: rgba(8, 8, 8, 0.76);
  color: rgba(242, 238, 232, 0.78);
  font-size: 0.78rem;
  opacity: 0;
  transform: translateY(6px);
  transition:
    opacity 160ms ease,
    transform 160ms ease;
}

.video-overlay__loading.is-visible {
  opacity: 1;
  transform: translateY(0);
}

.video-overlay__empty {
  display: grid;
  place-items: center;
  width: min(100%, 620px);
  min-height: min(52vh, 420px);
  padding: 30px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: var(--radius-overlay);
  background: rgba(255, 255, 255, 0.035);
  color: rgba(242, 238, 232, 0.62);
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(0.92rem, 1.05vw, 1.05rem);
  font-style: italic;
  text-align: center;
}

.video-overlay__nav {
  position: absolute;
  top: calc(50% + 42px);
  z-index: 3;
  width: 54px;
  height: 54px;
  transform: translateY(-50%);
}

.video-overlay__nav--prev {
  left: clamp(-96px, -6vw, -76px);
}

.video-overlay__nav--next {
  right: clamp(-96px, -6vw, -76px);
}

@keyframes motionTitleGradient {
  from {
    background-position: 0% 50%;
  }

  to {
    background-position: 100% 50%;
  }
}

@keyframes activeCardBorder {
  from {
    --active-border-angle: 92deg;
  }

  to {
    --active-border-angle: 164deg;
  }
}

@keyframes aboutPanelBorder {
  from {
    --about-border-angle: 108deg;
  }

  to {
    --about-border-angle: 178deg;
  }
}

.about-overlay {
  position: fixed;
  inset: 0;
  z-index: 110;
  display: grid;
  place-items: center;
  padding: clamp(16px, 3vw, 42px);
  background: rgba(0, 0, 0, 0.78);
  opacity: 0;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  pointer-events: none;
  transition: opacity 260ms ease;
  backdrop-filter: blur(16px);
}


.about-overlay[aria-hidden="false"] {
  opacity: 1;
  pointer-events: auto;
}

.about-overlay__panel {
  --about-border-angle: 132deg;
  position: relative;
  display: grid;
  grid-template-columns: minmax(160px, 0.7fr) minmax(260px, 1fr);
  gap: clamp(22px, 4vw, 54px);
  width: min(100%, 860px);
  padding: clamp(22px, 3.6vw, 46px);
  border: 1px solid transparent;
  border-radius: 26px;
  background:
    radial-gradient(circle at 24% 20%, rgba(102, 132, 218, 0.16), transparent 35%) padding-box,
    radial-gradient(circle at 86% 74%, rgba(118, 76, 178, 0.15), transparent 38%) padding-box,
    linear-gradient(145deg, rgba(16, 17, 28, 0.92), rgba(7, 8, 16, 0.88)) padding-box,
    linear-gradient(
      var(--about-border-angle),
      rgba(153, 184, 255, 0.46),
      rgba(130, 92, 204, 0.22),
      rgba(236, 212, 170, 0.34),
      rgba(153, 184, 255, 0.46)
    ) border-box;
  box-shadow:
    0 32px 110px rgba(0, 0, 0, 0.72),
    0 0 58px rgba(96, 120, 210, 0.1);
  transform: translateY(12px) scale(0.985);
  overflow: hidden;
  transition: transform 320ms var(--ease-premium);
  will-change: transform;
  animation: aboutPanelBorder 8s ease-in-out infinite alternate;
}

.about-overlay__panel::before {
  position: absolute;
  inset: 1px;
  z-index: -1;
  border-radius: inherit;
  background:
    linear-gradient(120deg, transparent 0 16%, rgba(154, 178, 255, 0.055) 34%, transparent 52%),
    linear-gradient(72deg, transparent 0 45%, rgba(150, 96, 210, 0.04) 64%, transparent 82%);
  content: "";
  pointer-events: none;
}

.about-overlay[aria-hidden="false"] .about-overlay__panel {
  transform: translateY(0) scale(1);
}

.about-overlay__panel:focus,
.about-overlay__panel:focus-visible {
  outline: 0;
}

.about-overlay__close {
  position: absolute;
  top: 18px;
  right: 18px;
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.035);
  color: rgba(242, 238, 232, 0.76);
  cursor: pointer;
  backdrop-filter: blur(18px);
  transition:
    transform 180ms ease,
    background 180ms ease,
    border-color 180ms ease;
}

.about-overlay__close:hover {
  border-color: rgba(255, 255, 255, 0.2);
  background: rgba(255, 255, 255, 0.075);
  transform: scale(1.04);
}

.about-overlay__close svg {
  width: 22px;
  height: 22px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.7;
}

.about-overlay__media {
  display: grid;
  place-items: center;
  min-height: 260px;
  border: 0;
  border-radius: 0;
  background: transparent;
}

.about-overlay__media img {
  width: min(72%, 238px);
  height: auto;
  opacity: 0.9;
}

.about-overlay__content {
  align-self: center;
  padding-right: 38px;
}

.about-overlay__eyebrow,
.about-overlay__content h2,
.about-overlay__content p {
  margin: 0;
}

.about-overlay__eyebrow {
  color: rgba(242, 238, 232, 0.46);
  font-size: 0.68rem;
  font-weight: 540;
  letter-spacing: 0.09em;
  line-height: 1.2;
  text-transform: uppercase;
}

.about-overlay__content h2 {
  display: flex;
  flex-wrap: wrap;
  gap: 0.28em;
  margin-top: 12px;
  color: rgba(242, 238, 232, 0.96);
  font-size: clamp(1.55rem, 3vw, 2.4rem);
  font-weight: 320;
  line-height: 0.98;
}

.about-overlay__content h2 span,
.about-overlay__content h2 em {
  font-family:
    Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI",
    sans-serif;
  letter-spacing: 0;
}

.about-overlay__content h2 span {
  color: rgba(242, 238, 232, 0.92);
  font-style: normal;
  font-weight: 320;
}

.about-overlay__content h2 em {
  background:
    linear-gradient(
      105deg,
      rgba(242, 238, 232, 0.96) 0%,
      rgba(128, 174, 232, 0.96) 28%,
      rgba(236, 221, 194, 0.94) 54%,
      rgba(214, 231, 255, 0.96) 78%,
      rgba(242, 238, 232, 0.94) 100%
    );
  background-clip: text;
  background-size: 220% 100%;
  color: rgba(238, 240, 245, 0.93);
  font-style: italic;
  font-weight: 600;
  -webkit-text-fill-color: transparent;
  animation: motionTitleGradient 7s ease-in-out infinite alternate;
}

.about-overlay__presentation {
  max-width: 50ch;
  margin-top: 24px;
  color: rgba(242, 238, 232, 0.72);
  font-family: Outfit, sans-serif;
  font-size: clamp(0.96rem, 1.08vw, 1.06rem);
  font-weight: 380;
  line-height: 1.7;
  letter-spacing: 0.01em;
}

.about-overlay__presentation p {
  margin: 0 0 16px;
}

.about-overlay__presentation p:last-child {
  margin-bottom: 0;
}

.about-overlay__contact {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 28px;
}

.about-contact-btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 28px;
  border: 1px solid rgba(140, 172, 245, 0.16);
  border-radius: 999px;
  background: rgba(8, 9, 15, 0.45);
  color: rgba(242, 238, 232, 0.72);
  font-size: 0.84rem;
  font-weight: 540;
  letter-spacing: 0.04em;
  white-space: nowrap;
  text-decoration: none;
  box-shadow: 
    0 8px 32px rgba(0, 0, 0, 0.4),
    0 0 16px rgba(140, 172, 245, 0.03);
  backdrop-filter: blur(16px);

  -webkit-backdrop-filter: blur(16px);
  overflow: hidden;
  transition: 
    border-color 300ms ease,
    background-color 300ms ease,
    color 300ms ease,
    box-shadow 300ms ease,
    transform 300ms cubic-bezier(0.25, 1, 0.5, 1);
}

.about-contact-btn::after {
  content: "";
  position: absolute;
  top: 0;
  left: -100%;
  width: 50%;
  height: 100%;
  background: linear-gradient(to right, transparent, rgba(140, 172, 245, 0.15), transparent);
  transform: skewX(-20deg);
}

.about-contact-btn:hover {
  border-color: rgba(140, 172, 245, 0.52);
  background: rgba(140, 172, 245, 0.06);
  color: rgba(242, 238, 232, 0.98);
  box-shadow: 
    0 10px 36px rgba(0, 0, 0, 0.5),
    0 0 24px rgba(140, 172, 245, 0.22);
  transform: translateY(-2px);
}

.about-contact-btn:hover::after {
  animation: sweepShine 1.5s ease;
}

.about-overlay__grid {
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  gap: clamp(16px, 3vw, 32px);
  margin-top: 24px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  padding-top: 22px;
}

.about-overlay__section h3 {
  margin: 0 0 12px;
  font-family: Outfit, sans-serif;
  font-size: 0.82rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: rgba(242, 238, 232, 0.82);
}

.about-overlay__section ul {
  margin: 0;
  padding: 0;
  list-style: none;
}

.about-overlay__section li {
  font-size: 0.86rem;
  color: rgba(242, 238, 232, 0.62);
  margin-bottom: 8px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.about-overlay__section li::before {
  content: "";
  display: block;
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: rgba(140, 172, 245, 0.62);
  box-shadow: 0 0 8px rgba(140, 172, 245, 0.62);
}

.about-overlay__badges {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.about-badge {
  display: inline-flex;
  align-items: center;
  padding: 4px 10px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.02);
  color: rgba(242, 238, 232, 0.72);
  font-size: 0.72rem;
  font-weight: 500;
  white-space: nowrap;
  transition: all 180ms ease;
}


.about-badge:hover {
  border-color: rgba(140, 172, 245, 0.3);
  background: rgba(140, 172, 245, 0.08);
  color: rgba(242, 238, 232, 0.94);
  transform: translateY(-1px);
}

@keyframes fadeInUpStagger {
  from {
    opacity: 0;
    transform: translateY(16px) scale(0.985);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

@media (max-width: 900px) {
  #app {
    padding-top: 26px;
  }

  .portfolio-view {
    padding-top: 54px;
  }

  .portfolio-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 14px;
  }

  .carousel {
    --gallery-center-y: 59%;
    grid-template-columns: 1fr;
    grid-template-rows: minmax(330px, 42vh) auto;
  }

  .carousel__stage {
    min-height: 326px;
  }

  .project-card {
    width: min(68vw, 330px);
    transform:
      translate(-50%, -50%)
      translateX(calc((var(--offset) * min(36vw, 170px)) + var(--drag)))
      translateY(var(--shift-y))
      rotateY(var(--rotate-y))
      translateZ(var(--translate-z))
      scale(var(--scale));
  }

  .carousel__arrow {
    position: absolute;
    top: var(--gallery-center-y);
    width: 46px;
    height: 46px;
    transform: translateY(-50%);
  }

  .carousel__arrow--prev {
    left: 18px;
  }

  .carousel__arrow--next {
    right: 18px;
  }

  .video-overlay__panel {
    width: min(100%, var(--overlay-width));
    max-height: 100%;
  }

  .video-overlay__player {
    width: min(100%, var(--video-width));
    max-width: 100%;
  }

  .video-overlay__player > video {
    border-radius: 18px;
  }

  .about-overlay__panel {
    grid-template-columns: 1fr;
    width: min(100%, 620px);
  }

  .about-overlay__media {
    min-height: 180px;
  }

  .about-overlay__content {
    padding-right: 0;
  }
}

@media (max-width: 620px) {
  .site-nav {
    width: 100%;
    justify-content: center;
    gap: clamp(4px, 1.8vw, 12px);
    padding: 6px;
  }

  .site-nav__link {
    font-size: clamp(0.64rem, 2.2vw, 0.74rem);
    padding: 6px clamp(4px, 1.2vw, 8px);
  }


  .portfolio-view {
    padding: 40px 14px 0;
  }

  .portfolio-view__header {
    margin-bottom: 22px;
  }

  .portfolio-view__header h1 {
    font-size: clamp(1.45rem, 8vw, 2.15rem);
  }

  .category-filters {
    justify-content: flex-start;
    gap: 7px;
    margin-bottom: 24px;
    overflow-x: auto;
    padding-bottom: 3px;
    flex-wrap: nowrap;
    scrollbar-width: none;
  }

  .category-filters::-webkit-scrollbar {
    display: none;
  }

  .category-filters__button {
    flex: 0 0 auto;
    min-height: 29px;
    padding: 7px 10px;
    font-size: 0.68rem;
  }

  .portfolio-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px 8px;
  }

  .portfolio-card__media {
    border-radius: 14px;
  }

  .portfolio-card__body {
    gap: 7px;
  }

  .portfolio-card__media-tags {
    gap: 4px;
  }

  .portfolio-card__tag {
    font-size: 0.46rem;
    padding: 3px 5px;
  }

  .portfolio-card__title {
    font-size: 0.78rem;
    min-height: 2.2em;
  }

  .hero {
    padding-top: 18px;
    padding-bottom: 0;
  }

  .hero__logo {
    display: block;
    margin-inline: auto;
    margin-bottom: var(--space-md);
    opacity: 0.8;
    mix-blend-mode: screen;
  }

  .hero__baseline {
    width: min(82vw, 300px);
    max-width: none;
    column-gap: 10px;
    row-gap: 3px;
    margin: 6px auto 0;
    font-size: 0.66rem;
    letter-spacing: 0.018em;
    justify-content: center;
    text-align: center;
  }

  .hero__baseline-item + .hero__baseline-item::before {
    display: none;
  }

  .carousel {
    --gallery-center-y: 57%;
    grid-template-rows: minmax(306px, 42vh) auto;
    margin-top: 0;
  }

  .project-card {
    width: min(68vw, 286px);
    --radius-card: 18px;
  }


  .carousel__arrow {
    width: 42px;
    height: 42px;
    opacity: 0.82;
  }

  .carousel__arrow--prev {
    left: 10px;
  }

  .carousel__arrow--next {
    right: 10px;
  }

  .carousel__dots {
    gap: 8px;
    margin-top: 72px;
  }

  .carousel__dot {
    width: 4px;
    height: 4px;
  }

  .about-overlay {
    padding: 12px;
  }

  .about-overlay__panel {
    gap: 20px;
    padding: 48px 22px 22px 22px;
    border-radius: 20px;
  }


  .about-overlay__close {
    top: 12px;
    right: 12px;
    width: 38px;
    height: 38px;
  }

  .about-overlay__media {
    min-height: 150px;
  }

  .video-overlay {
    padding: 12px;
  }

  .video-overlay__topbar {
    align-items: flex-start;
  }

  .video-overlay__meta small {
    display: none;
  }

  .video-overlay__close {
    width: 44px;
    height: 44px;
  }

  .video-overlay__panel {
    padding-bottom: 72px;
  }

  .video-overlay__nav {
    top: auto;
    bottom: 12px;
    width: 48px;
    height: 48px;
  }

  .video-overlay__nav--prev {
    left: max(18px, calc(50% - 66px));
  }

  .video-overlay__nav--next {
    right: max(18px, calc(50% - 66px));
  }
}

@media (max-width: 620px) and (orientation: portrait) {
  #app {
    padding-top: 22px;
  }



  .hero {
    padding-top: 14px;
  }

  .hero__title-main,
  .hero__title-mark {
    font-size: clamp(1.74rem, 8vw, 2.42rem);
  }

  .hero__baseline {
    width: min(82vw, 300px);
    column-gap: 8px;
    font-size: clamp(0.64rem, 2.85vw, 0.76rem);
  }

  .carousel {
    --gallery-center-y: 55%;
    grid-template-rows: minmax(282px, 36vh) auto;
    margin-top: clamp(10px, 2vh, 18px);
  }

  .carousel__stage {
    min-height: 282px;
  }

  .project-card {
    width: min(57vw, 244px);
    transform:
      translate(-50%, -50%)
      translateX(calc((var(--offset) * min(29vw, 134px)) + var(--drag)))
      translateY(var(--shift-y))
      rotateY(var(--rotate-y))
      translateZ(var(--translate-z))
      scale(var(--scale));
  }

  .carousel__dots {
    margin-top: 56px;
  }
}

@media (max-width: 430px) and (orientation: portrait) {
  .hero__baseline {
    width: min(80vw, 292px);
    column-gap: 10px;
    font-size: clamp(0.62rem, 2.72vw, 0.7rem);
  }

  .hero__baseline-item + .hero__baseline-item::before {
    display: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
  }
}

@media (max-width: 768px) {
  .project-card {
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5) !important;
  }
  .project-card.is-active {
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.15), 0 20px 40px rgba(0, 0, 0, 0.6) !important;
  }

  .carousel__arrow {
    display: none !important;
  }
}

/* --- AMÉLIORATIONS PREMIUM V13 --- */

/* 1. Halo Lumineux d'Arrière-plan Interactif */
.mouse-glow {
  position: fixed;
  inset: 0;
  z-index: -2;
  pointer-events: none;
  background: radial-gradient(
    600px circle at var(--mouse-glow-x, -999px) var(--mouse-glow-y, -999px),
    rgba(120, 156, 245, 0.045),
    transparent 80%
  );
  opacity: 0;
  transition: opacity 1.2s var(--ease-premium);
}

body.has-glow .mouse-glow {
  opacity: 1;
}

/* 2. Révélation Cinématique au Chargement */
.hero,
.site-header,
.carousel,
.portfolio-view,
.selection-actions {
  --reveal-y: 20px;
  animation: cinematicReveal 1.3s var(--ease-premium) both;
}

.hero { animation-delay: 140ms; }
.site-header { animation-delay: 50ms; }
.carousel { animation-delay: 240ms; }
.portfolio-view { animation-delay: 240ms; }
.selection-actions { animation-delay: 360ms; }

@keyframes cinematicReveal {
  from {
    opacity: 0;
    filter: blur(14px);
    transform: translateY(var(--reveal-y));
  }
  to {
    opacity: 1;
    filter: blur(0);
    transform: translateY(0);
  }
}

/* 3. Lueur et déplacement doux au survol des cartes actives (Premium Hover Glow) */
@media (min-width: 769px) {
  .project-card.is-active:hover {
    box-shadow:
      inset 0 0 0 1px rgba(177, 207, 255, 0.42),
      0 0 28px rgba(140, 172, 245, 0.12),
      0 40px 90px rgba(0, 0, 0, 0.85);
    transform:
      translate(-50%, -50%)
      translateX(calc((var(--shift-x-mult, 0) * clamp(110px, 10vw, 190px)) + var(--drag)))
      translateY(calc(var(--shift-y) - 4px))
      rotateY(var(--rotate-y))
      translateZ(var(--translate-z))
      scale(calc(var(--scale) * 1.015)) !important;
  }
}
