/* ==========================================================================
   Abby Creative Studio — Styles
   Fonts: Satoshi (body) + zahrah (headings)
   ========================================================================== */

/* --------------------------------------------------------------------------
   Variables
   -------------------------------------------------------------------------- */
:root {
  /* Palette */
  --color-bg: #ede9de;
  --color-bg-alt: #e8dfd2;
  --color-surface: #faf6f0;
  --color-card-media: #f8f4ec;
  --color-card-footer: #d9d2c8;
  --color-text: #1c1410;
  --color-text-muted: #5c4f45;
  --color-accent: #600010;
  --color-accent-hover: #4a000c;
  --color-lilac: #d89cf6;
  --color-black: #1a1a1a;
  --color-border: #c9bfb0;
  --color-form-bg: #f0ebe3;
  --color-btn-dark: #2a2a2a;
  --color-btn-dark-text: #ffffff;
  --color-overlay: rgba(28, 20, 16, 0.55);

  /* Fonts */
  --font-body: "Satoshi", system-ui, sans-serif;
  --font-heading: "zahrah", "Cormorant Garamond", serif;

  /* Type scale (fluide) */
  --text-xs: clamp(0.65rem, 1.5vw, 0.75rem);
  --text-sm: clamp(0.75rem, 1.8vw, 0.875rem);
  --text-base: clamp(0.875rem, 2vw, 1rem);
  --text-lg: clamp(1.125rem, 2.5vw, 1.375rem);
  --text-xl: clamp(1.5rem, 3vw, 2rem);
  --text-2xl: clamp(1.75rem, 4vw, 2.5rem);
  --text-3xl: clamp(2rem, 6vw, 3.5rem);

  /* Layout */
  --content-narrow: 42rem;
  --content-default: 78rem;
  --content-wide: 96rem;
  --gutter: clamp(1rem, 3vw, 2rem);
  --section-gap: clamp(2.5rem, 6vw, 5rem);
  --radius-pill: 999px;
  --radius-card: 1.25rem;

  --transition: 0.2s ease;

  color-scheme: light;
}

[data-theme="dark"] {
  --color-bg: #262626;
  --color-bg-alt: #262626;
  --color-surface: #211710;
  --color-card-media: #2a1e16;
  --color-card-footer: #3a291d;
  --color-text: #f5ede2;
  --color-text-muted: #c9b8a8;
  --color-accent: #620012;
  --color-accent-hover: #ffa3b1;
  --color-lilac: #caa1ec;
  --color-border: #4a382c;
  --color-form-bg: #2a1e16;
  --color-btn-dark: #f5ede2;
  --color-btn-dark-text: #17110d;
  --color-overlay: rgba(0, 0, 0, 0.7);
  color-scheme: dark;
}

/* --------------------------------------------------------------------------
   Reset & base
   -------------------------------------------------------------------------- */
*,
*::before,
*::after {
  box-sizing: border-box;
}
html {
  scroll-behavior: smooth;
}
body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  font-family: var(--font-body);
  font-size: var(--text-base);
  line-height: 1.6;
  color: var(--color-text);
  background-color: var(--color-bg);
  -webkit-font-smoothing: antialiased;
  transition:
    background-color var(--transition),
    color var(--transition);
}
body.has-modal-open {
  overflow: hidden;
  /* Sur iOS Safari, "overflow: hidden" seul ne bloque pas le rebond de la
     page derrière la modale : on fige aussi sa position (voir script.js,
     lockBodyScroll/unlockBodyScroll, qui gère le "top" et restaure le
     scroll à la fermeture). */
  position: fixed;
  left: 0;
  right: 0;
  width: 100%;
}
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }
}
img {
  display: block;
  max-width: 100%;
  height: auto;
}
a {
  color: inherit;
  text-decoration: none;
  transition: color var(--transition);
}
a:hover,
a:focus-visible {
  color: var(--color-accent);
}
ul,
ol {
  margin: 0;
  padding: 0;
  list-style: none;
}
h1,
h2,
h3,
h4 {
  font-family: var(--font-heading);
  font-weight: 800;
  font-style: italic;
  line-height: 1.15;
  margin: 0 0 0.5em;
  color: var(--color-text);
}
h1 {
  font-size: var(--text-3xl);
  letter-spacing: -0.04em;
}
h2 {
  font-size: var(--text-2xl);
}
h3 {
  font-size: var(--text-lg);
}
p {
  margin: 0 0 1em;
  color: var(--color-text-muted);
  font-size: var(--text-base);
}
p:last-child {
  margin-bottom: 0;
}
:focus-visible {
  outline: 2px solid var(--color-accent);
  outline-offset: 3px;
}
.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* --------------------------------------------------------------------------
   Transition entre les pages
   -------------------------------------------------------------------------- */

@view-transition {
  navigation: auto;
}
::view-transition-old(root) {
  animation: page-out 180ms ease-in both;
}
::view-transition-new(root) {
  animation: page-in 260ms ease-out both;
}
@keyframes page-out {
  to {
    opacity: 0;
    transform: translateY(-0.5rem);
  }
}
@keyframes page-in {
  from {
    opacity: 0;
    transform: translateY(0.75rem);
  }
}

/* --------------------------------------------------------------------------
   Layout
   -------------------------------------------------------------------------- */
.container {
  width: 100%;
  max-width: var(--content-default);
  margin-inline: auto;
  padding-inline: var(--gutter);
}
.section {
  padding-block: var(--section-gap);
}
.section__label {
  display: block;
  font-family: var(--font-body);
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--color-text);
  margin-bottom: 0.5rem;
}

/* --------------------------------------------------------------------------
   Boutons
   -------------------------------------------------------------------------- */
.btn-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.5rem 1.25rem;
  font-family: var(--font-body);
  font-size: var(--text-xs);
  font-weight: 600;
  letter-spacing: 0.06em;
  color: var(--color-accent);
  background-color: transparent;
  border: 1px solid var(--color-accent);
  border-radius: var(--radius-pill);
  cursor: pointer;
  transition:
    background-color var(--transition),
    color var(--transition),
    border-color var(--transition);
}
.btn-pill:hover,
.btn-pill:focus-visible {
  color: var(--color-bg);
  background-color: var(--color-accent);
}
.btn-pill--white {
  color: #fff;
  border-color: #fff;
}
.btn-pill--white:hover,
.btn-pill--white:focus-visible {
  color: var(--color-lilac);
  background-color: #fff;
}
.btn-pill--dark {
  color: #fff;
  background-color: var(--color-btn-dark);
  border-color: var(--color-btn-dark);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 0.7rem;
  padding: 0.6rem 1.75rem;
}
.btn-pill--dark:hover,
.btn-pill--dark:focus-visible {
  color: #fff;
  background-color: var(--color-black);
  border-color: var(--color-black);
}

/* --------------------------------------------------------------------------
   Micro-interactions
   -------------------------------------------------------------------------- */

.btn-pill {
  transition:
    transform var(--transition),
    background-color var(--transition),
    color var(--transition),
    border-color var(--transition),
    box-shadow var(--transition);
}

.btn-pill:hover,
.btn-pill:focus-visible {
  transform: translateY(-2px);
  box-shadow: 0 0.5rem 1.25rem rgba(96, 0, 16, 0.16);
}

.btn-pill:active {
  transform: translateY(0);
  box-shadow: none;
}

.project-card {
  transition:
    transform var(--transition),
    border-color var(--transition),
    box-shadow var(--transition);
}

.project-card:hover,
.project-card:focus-within {
  transform: translateY(-0.35rem);
  border-color: var(--color-accent);
  box-shadow: 0 1rem 2rem rgba(28, 20, 16, 0.1);
}

.project-card__media img {
  transition: transform 420ms cubic-bezier(0.16, 1, 0.3, 1);
}

.project-card:hover .project-card__media img,
.project-card:focus-within .project-card__media img {
  transform: scale(1.035);
}

.filter-btn {
  transition:
    transform var(--transition),
    color var(--transition),
    border-color var(--transition),
    background-color var(--transition);
}

.filter-btn:hover,
.filter-btn:focus-visible {
  transform: translateY(-1px);
}

.filter-btn:active {
  transform: translateY(0);
}

/* --------------------------------------------------------------------------
   Header (toutes pages)
   -------------------------------------------------------------------------- */
.home-header {
  padding-block: clamp(1rem, 3vw, 2rem) 0;
  position: relative;
  z-index: 100;
}
.home-header__wrap {
  display: flex;
  justify-content: center;
}
.home-header__nav {
  position: fixed;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: clamp(0.5rem, 2vw, 1.25rem);
  width: min(95%, 68rem);
  min-height: clamp(2.2rem, 6vw, 3rem);
  padding: 0.5rem clamp(0.8rem, 2.5vw, 1.5rem);
  background-color: var(--color-black);
  border-radius: var(--radius-pill);
}
.home-header__logo {
  flex-shrink: 0;
  font-family: var(--font-heading);
  font-size: clamp(0.8rem, 2vw, 1.0625rem);
  font-weight: 400;
  letter-spacing: 0.04em;
  color: #fff;
  text-transform: lowercase;
  transition: opacity var(--transition);
}
.home-header__logo:hover,
.home-header__logo:focus-visible {
  color: #fff;
  opacity: 0.75;
}

.home-header__toggle {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 4px;
  width: 2rem;
  height: 2rem;
  padding: 0;
  background: none;
  border: 0;
  cursor: pointer;
  flex-shrink: 0;
}

.home-header__toggle-bar {
  display: block;
  width: 1.1rem;
  height: 1.5px;
  background-color: #fff;
  border-radius: 1px;
  transition:
    transform var(--transition),
    opacity var(--transition);
}
.home-header__toggle[aria-expanded="true"]
  .home-header__toggle-bar:nth-child(1) {
  transform: translateY(5px) rotate(45deg);
}
.home-header__toggle[aria-expanded="true"]
  .home-header__toggle-bar:nth-child(2) {
  opacity: 0;
}
.home-header__toggle[aria-expanded="true"]
  .home-header__toggle-bar:nth-child(3) {
  transform: translateY(-6px) rotate(-45deg);
}
.home-header__menu {
  display: none;
  position: absolute;
  top: calc(100% + 0.6rem);
  left: 0;
  right: 0;
  flex-direction: column;
  gap: 1.25rem;
  padding: 1.25rem;
  background-color: var(--color-black);
  border-radius: 1.25rem;
}
.home-header__menu.is-open {
  display: flex;
}
.home-header__list {
  display: flex;
  flex-direction: column;
  gap: 0.875rem;
}
.home-header__link {
  font-size: var(--text-xs);
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.75);
  white-space: nowrap;
  transition: color var(--transition);
}
.home-header__link:hover,
.home-header__link:focus-visible {
  color: #fff;
}
.home-header__link--active {
  color: #fff;
}
.home-header__utility {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1rem;
  padding-top: 1rem;
  border-top: 1px solid rgba(255, 255, 255, 0.15);
}
.home-header__socials {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}
.home-header__social-link {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 1.6rem;
  height: 1.6rem;
  color: rgba(255, 255, 255, 0.75);
  transition:
    color var(--transition),
    opacity var(--transition);
}
.home-header__social-link svg {
  width: 0.9rem;
  height: 0.9rem;
}
.home-header__social-link:hover,
.home-header__social-link:focus-visible {
  color: #fff;
}
.lang-toggle,
.theme-toggle {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.35rem 0.6rem;
  font-family: var(--font-body);
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  color: rgba(255, 255, 255, 0.85);
  background-color: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: var(--radius-pill);
  cursor: pointer;
  transition:
    background-color var(--transition),
    color var(--transition),
    border-color var(--transition);
}
.lang-toggle:hover,
.lang-toggle:focus-visible,
.theme-toggle:hover,
.theme-toggle:focus-visible {
  color: #fff;
  background-color: rgba(255, 255, 255, 0.16);
  border-color: rgba(255, 255, 255, 0.32);
}
.lang-toggle svg,
.theme-toggle svg {
  width: 0.8rem;
  height: 0.8rem;
  flex-shrink: 0;
}
.theme-toggle__icon--sun {
  display: none;
}
[data-theme="dark"] .theme-toggle__icon--sun {
  display: inline-flex;
}
[data-theme="dark"] .theme-toggle__icon--moon {
  display: none;
}

@media (min-width: 880px) {
  .home-header__toggle {
    display: none;
  }

  .home-header__menu {
    display: flex;
    position: static;
    flex-direction: row;
    align-items: center;
    gap: clamp(0.75rem, 2vw, 1.5rem);
    padding: 0;
    background: none;
    border-radius: 0;
    margin-left: auto;
  }

  .home-header__list {
    flex-direction: row;
    flex-wrap: wrap;
    gap: clamp(0.6rem, 1.5vw, 1.25rem);
  }

  .home-header__utility {
    padding-top: 0;
    border-top: 0;
    gap: 0.75rem;
  }
}

/* --------------------------------------------------------------------------
   Hero
   -------------------------------------------------------------------------- */
.hero-home {
  min-height: 100svh;
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding-block: clamp(6rem, 14vw, 8rem) clamp(3rem, 8vw, 5rem);
}
.hero-home__inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: clamp(1rem, 3vw, 1.5rem);
  text-align: center;
  position: relative;
  width: 100%;
}
.hero-home__brand {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  padding: clamp(1.25rem, 4vw, 2rem) clamp(1.5rem, 5vw, 3rem)
    clamp(0rem, 4vw, 0rem) clamp(1.5rem, 5vw, 3rem);
  border-radius: var(--radius-card);
}
.icone_menu {
  width: 2em;
}
.hero-home__logo {
  width: min(90%);
  height: auto;
  display: block;
}
.hero-home--bg {
  position: relative;
  margin-top: -4vh;
  background-image:
    linear-gradient(rgba(237, 233, 222, 0.55), rgba(237, 233, 222, 0.35)),
    url("assets/fondrose.webp");
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}
.hero-home__role {
  margin: 0;
  font-family: var(--font-heading);
  font-size: clamp(1.5rem, 6vw, 3rem);
  color: var(--color-text);
  line-height: 1.1;
}
.hero-home__tagline {
  margin: -0.8em 0em 0em 0em;
  font-size: clamp(0.85rem, 1.5vw, 3rem);
  font-weight: 500;
  font-style: italic;
  color: var(--color-accent);
  max-width: 36ch;
}
.hero-home__actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.75rem;
  margin-top: clamp(0.5rem, 2vw, 1rem);
}
.hero-home__scroll {
  position: absolute;
  bottom: clamp(-4.5rem, -8vw, -3rem);
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  align-items: center;
  justify-content: center;
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 50%;
  border: 0.6px solid var(--color-accent);
  color: var(--color-accent);
  animation: hero-scroll-bounce 2s ease-in-out infinite;
}
.hero-home__scroll svg {
  width: 1.1rem;
  height: 1.1rem;
}
@keyframes hero-scroll-bounce {
  0%,
  100% {
    transform: translateX(-50%) translateY(0);
  }
  50% {
    transform: translateX(-50%) translateY(6px);
  }
}
@media (prefers-reduced-motion: reduce) {
  .hero-home__scroll {
    animation: none;
  }
  .reveal,
  .reveal.is-visible,
  .project-card,
  .btn-pill,
  .filter-btn,
  .project-card__media img,
  .modal-content,
  .modal-backdrop {
    animation: none !important;
    transform: none !important;
    transition: none !important;
  }

  .reveal {
    opacity: 1;
  }
}

/* --------------------------------------------------------------------------
   Featured projects
   -------------------------------------------------------------------------- */
.featured-projects {
  background-color: var(--color-lilac);
  padding-block: clamp(2.5rem, 6vw, 4.5rem);
}
.featured-projects__inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: clamp(1.5rem, 4vw, 2.5rem);
}
.featured-projects__title {
  margin: 0;
  font-family: var(--font-heading);
  font-size: clamp(1.5rem, 4vw, 2.5rem);
  font-weight: 400;
  color: #fff;
  text-align: center;
}
.featured-projects__grid {
  display: grid;
  gap: clamp(0.75rem, 2vw, 1.25rem);
  width: 100%;
}
/* --------------------------------------------------------------------------
   AMÉLIORATIONS UX — carrousel tactile sur mobile ("Quelques projets")
   -------------------------------------------------------------------------- */
@media (max-width: 767.98px) {
  .featured-projects__grid {
    display: flex;
    gap: 0.85rem;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scroll-padding-inline: var(--gutter);
    margin-inline: calc(var(--gutter) * -1);
    padding-inline: var(--gutter);
    padding-bottom: 0.35rem;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
  }
  .featured-projects__grid::-webkit-scrollbar {
    display: none;
  }
  .featured-projects__item,
  .featured-projects__item--large {
    flex: 0 0 82%;
    scroll-snap-align: center;
  }
  .featured-projects__item--large .featured-card__media {
    min-height: 52vw;
  }
  .featured-projects__item:not(.featured-projects__item--large)
    .featured-card__media {
    min-height: 44vw;
  }
}
.featured-projects__dots {
  display: none;
  justify-content: center;
  gap: 0.5rem;
}
.featured-projects__dot {
  width: 0.5rem;
  height: 0.5rem;
  padding: 0;
  background-color: transparent;
  border: 1px solid rgba(255, 255, 255, 0.8);
  border-radius: 50%;
  cursor: pointer;
  transition:
    background-color var(--transition),
    transform var(--transition);
}
.featured-projects__dot.is-active {
  background-color: #fff;
  transform: scale(1.25);
}
@media (max-width: 767.98px) {
  .featured-projects__dots {
    display: flex;
  }
}
@media (min-width: 768px) {
  .featured-projects__grid {
    grid-template-columns: 1.15fr 1fr;
    grid-template-rows: repeat(3, minmax(140px, 1fr));
    min-height: 520px;
  }

  .featured-projects__item--large {
    grid-row: 1 / -1;
    grid-column: 1;
  }

  .featured-projects__item:not(.featured-projects__item--large) {
    grid-column: 2;
  }
}
.featured-card {
  height: 100%;
  border-radius: var(--radius-card);
  overflow: hidden;
  background-color: var(--color-card-media);
}
.featured-card__link {
  display: flex;
  flex-direction: column;
  height: 100%;
  color: inherit;
}
.featured-card__link:hover,
.featured-card__link:focus-visible {
  color: inherit;
}
.featured-card__media {
  flex: 1;
  min-height: clamp(120px, 20vw, 200px);
  background-color: var(--color-card-media);
}
.featured-projects__item--large .featured-card__media {
  min-height: clamp(200px, 40vw, 420px);
}
.featured-card__media-placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
  min-height: inherit;
  font-size: 0.65rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--color-text-muted);
}
.featured-card__footer {
  padding: 0.75rem 1rem;
  background-color: var(--color-card-footer);
  display: grid;
  grid-template-columns: 1fr auto;
  grid-template-rows: auto auto;
  gap: 0.15rem 0.75rem;
  align-items: center;
}
.featured-card__title {
  margin: 0;
  grid-column: 1;
  grid-row: 1;
  font-family: var(--font-heading);
  font-size: 1rem;
  color: var(--color-text);
}
.featured-card__desc {
  margin: 0;
  grid-column: 1;
  grid-row: 2;
  font-size: 0.75rem;
  color: var(--color-text-muted);
}
.featured-card__cta {
  grid-column: 2;
  grid-row: 1 / -1;
  align-self: center;
  font-size: 0.7rem;
  font-weight: 600;
  color: var(--color-text);
  white-space: nowrap;
}
.featured-projects__action {
  text-align: center;
}

/* --------------------------------------------------------------------------
   Domaines d’intervention
   -------------------------------------------------------------------------- */
.domains {
  padding-block: clamp(2.5rem, 10vw, 15rem);
  background-color: var(--color-bg);
}
.domains__inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: clamp(1.5rem, 4vw, 2.5rem);
}
.domains__title {
  margin: 0;
  font-family: var(--font-heading);
  font-size: clamp(1.5rem, 4vw, 2.25rem);
  font-weight: 600;
  color: var(--color-accent);
  text-align: center;
  max-width: 22ch;
}
.domains__grid {
  display: grid;
  gap: clamp(0.75rem, 2vw, 1.25rem);
  width: 100%;
}
@media (min-width: 640px) {
  .domains__grid {
    grid-template-columns: repeat(3, 1fr);
  }
}
.domain-card {
  aspect-ratio: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.25rem;
  background-color: var(--color-accent);
  border-radius: var(--radius-card);
}
.domain-card__label {
  margin: 0;
  font-family: var(--font-heading);
  font-size: clamp(1rem, 2.5vw, 1.5rem);
  font-style: italic;
  font-weight: 400;
  color: #fff;
  text-align: center;
}

/* --------------------------------------------------------------------------
   Contact
   -------------------------------------------------------------------------- */
.contact-home {
  position: relative;
  padding-block: clamp(2.5rem, 6vw, 5rem);
  background-color: var(--color-bg);
  overflow: hidden;
}
.contact-home::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(
    ellipse 70% 60% at 50% 45%,
    color-mix(in srgb, var(--color-lilac) 28%, transparent) 0%,
    transparent 70%
  );
  pointer-events: none;
}
.contact-home__inner {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: clamp(0.75rem, 2vw, 1.25rem);
  max-width: 640px;
}
.contact-home__title {
  margin: 0;
  font-family: var(--font-heading);
  font-size: clamp(1.5rem, 4vw, 2.25rem);
  font-weight: 400;
  color: var(--color-accent);
  text-align: center;
}
.contact-home__intro {
  text-align: center;
  font-size: var(--text-sm);
  max-width: 42ch;
}
.contact-home__email {
  margin: 0 0 0.75rem;
  text-align: center;
}
.contact-home__email a {
  font-size: var(--text-sm);
  color: var(--color-text-muted);
}
.contact-home__email a:hover,
.contact-home__email a:focus-visible {
  color: var(--color-accent);
}
.contact-form {
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}
.contact-form__row {
  display: grid;
  gap: 0.75rem;
}
@media (min-width: 480px) {
  .contact-form__row {
    grid-template-columns: 1fr 1fr;
  }
}
.contact-form__field {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}
.contact-form__label {
  font-size: 0.6rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  text-align: center;
  color: var(--color-text-muted);
}
.contact-form__input {
  width: 100%;
  padding: 0.5rem 1.25rem;
  font-family: var(--font-body);
  font-size: var(--text-sm);
  color: var(--color-text);
  background-color: var(--color-form-bg);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-pill);
  transition: border-color var(--transition);
}
.contact-form__input:focus {
  outline: none;
  border-color: var(--color-accent);
}
.contact-form__textarea {
  border-radius: 1.25rem;
  resize: vertical;
  min-height: 7rem;
}
.contact-form__submit {
  display: flex;
  justify-content: center;
  margin-top: 0.5rem;
}

/* --------------------------------------------------------------------------
   Footer
   -------------------------------------------------------------------------- */
.home-footer,
.site-footer {
  margin-top: auto;
  padding-block: 1.75rem 2rem;
  border-top: 1px solid var(--color-border);
  background-color: var(--color-bg-alt);
}
.home-footer__inner,
.site-footer__inner {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}
@media (min-width: 640px) {
  .home-footer__inner,
  .site-footer__inner {
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
  }
}
.home-footer__links,
.site-footer__social {
  display: flex;
  flex-wrap: wrap;
  gap: clamp(0.75rem, 2vw, 1.5rem);
}
.home-footer__links a,
.site-footer__social-link {
  font-size: 0.6rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--color-text-muted);
}
.home-footer__links a:hover,
.home-footer__links a:focus-visible,
.site-footer__social-link:hover,
.site-footer__social-link:focus-visible {
  color: var(--color-accent);
}
.home-footer__copy,
.site-footer__copy {
  margin: 0;
  font-size: 0.6rem;
  color: var(--color-text-muted);
}

/* --------------------------------------------------------------------------
   Page header (inner pages)
   -------------------------------------------------------------------------- */
.page-header {
  padding-block: clamp(3rem, 18vw, 8rem) clamp(1.5rem, 8vw, 3rem);
}
.page-header__title {
  font-size: clamp(2.5rem, 10vw, 4rem);
  margin: 0;
  letter-spacing: -0.06em;
}
.page-header__desc {
  max-width: 60ch;
  line-height: 110%;
  font-size: var(--text-sm);
}

/* --------------------------------------------------------------------------
   Projects page
   -------------------------------------------------------------------------- */
.projects-grid {
  display: grid;
  gap: clamp(1.25rem, 4vw, 2.25rem);
}
@media (min-width: 640px) {
  .projects-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}
@media (min-width: 960px) {
  .projects-grid--featured {
    grid-template-columns: repeat(3, 1fr);
  }
}
.project-card {
  display: flex;
  flex-direction: column;
  background-color: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-card);
  overflow: hidden;
  transition: border-color var(--transition);
}
.project-card:hover,
.project-card:focus-within {
  border-color: var(--color-accent);
}
.project-card__link {
  display: flex;
  flex-direction: column;
  height: 100%;
  color: inherit;
}
.project-card__link:hover,
.project-card__link:focus-visible {
  color: inherit;
}
.project-card__media {
  aspect-ratio: 4 / 3;
  background-color: var(--color-bg-alt);
  overflow: hidden;
}
.project-card__media img,
.project-card__media-placeholder {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.project-card__media-placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.65rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--color-text-muted);
}
.project-card__body {
  padding: 1rem 1.25rem 1.25rem;
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}
.project-card__category {
  font-size: 0.6rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--color-accent);
}
.project-card__title {
  font-family: var(--font-heading);
  font-size: 1.8rem;
  margin: 0;
}
.project-card__desc {
  font-size: var(--text-sm);
  flex: 1;
}

/* --------------------------------------------------------------------------
   Filtres
   -------------------------------------------------------------------------- */
.filters {
  margin-bottom: clamp(1.5rem, 4vw, 2.5rem);
}
.filters__group {
  margin-bottom: 1.1rem;
}
.filters__group-label {
  margin: 0 0 0.5rem;
  font-family: var(--font-body);
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--color-text-muted);
}
.filters__list {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem;
}
.filter-btn {
  padding: 0.35rem 0.75rem;
  font-family: var(--font-body);
  font-size: 0.6rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--color-text-muted);
  background-color: transparent;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-pill);
  cursor: pointer;
  transition:
    color var(--transition),
    border-color var(--transition),
    background-color var(--transition);
}
.filter-btn:hover,
.filter-btn:focus-visible {
  color: var(--color-accent);
  border-color: var(--color-accent);
}
.filter-btn--active,
.filter-btn[aria-pressed="true"] {
  color: var(--color-surface);
  background-color: var(--color-accent);
  border-color: var(--color-accent);
}

/* Bouton reset (par groupe) */
.filter-reset {
  margin-left: 0.25rem;
  font-size: 0.6rem;
  padding: 0.35rem 0.75rem;
  font-family: var(--font-body);
  font-weight: 600;
  letter-spacing: 0.04em;
  color: var(--color-text-muted);
  background-color: transparent;
  border: 1px dashed var(--color-border);
  border-radius: var(--radius-pill);
  cursor: pointer;
  transition:
    color var(--transition),
    border-color var(--transition);
}
.filter-reset:hover,
.filter-reset:focus-visible {
  color: var(--color-accent);
  border-color: var(--color-accent);
}

/* Bouton reset global */
.filter-reset--all {
  display: inline-block;
  margin-top: 0.5rem;
  font-size: 0.65rem;
  padding: 0.45rem 1rem;
  text-decoration: underline;
  text-underline-offset: 3px;
  border: none;
  background: none;
}

/* --------------------------------------------------------------------------
   About
   -------------------------------------------------------------------------- */
.about-layout {
  display: grid;
  gap: clamp(2rem, 5vw, 3.5rem);
}
@media (min-width: 768px) {
  .about-layout {
    grid-template-columns: 1fr 1.4fr;
    align-items: start;
  }
}
.about-portrait {
  aspect-ratio: 3 / 4;
  background-color: var(--color-bg-alt);
  border: 1px solid var(--color-border);
  display: flex;
  align-items: center;
  justify-content: center;
}
.about-portrait__placeholder {
  font-size: 0.7rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--color-text-muted);
}
.about-content__intro {
  font-size: clamp(1rem, 2.5vw, 1.25rem);
  color: var(--color-text);
  margin-bottom: 1.25rem;
}
.skills-list {
  display: grid;
  gap: 0.6rem;
  margin-top: 1.5rem;
}
@media (min-width: 480px) {
  .skills-list {
    grid-template-columns: repeat(2, 1fr);
  }
}
.skills-list__item {
  padding: 0.4rem 0.75rem;
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  background-color: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-card);
}
.contact-block {
  margin-top: clamp(2rem, 5vw, 3.5rem);
  padding: clamp(1.25rem, 4vw, 2rem);
  background-color: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-card);
}
.contact-block__email {
  font-family: var(--font-heading);
  font-size: clamp(1.125rem, 3vw, 1.5rem);
  color: var(--color-accent);
  word-break: break-all;
}
.contact-block__email:hover,
.contact-block__email:focus-visible {
  color: var(--color-accent-hover);
}

/* --------------------------------------------------------------------------
   Voir plus / charge progressive
   -------------------------------------------------------------------------- */
.projects-grid > li[hidden],
.projects-grid > li.hidden-by-load {
  display: none;
}
.projects-load-more {
  margin-top: clamp(1.5rem, 4vw, 2.5rem);
  margin-bottom: 1rem;
  text-align: center;
}
.projects-empty-state {
  max-width: 46ch;
  margin: 2rem auto 0;
  padding: 1.25rem;
  text-align: center;
  color: var(--color-text-muted);
  background-color: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-card);
}
.projects-empty-state .text-link {
  margin-top: 0.75rem;
  border: 0;
  background: none;
  cursor: pointer;
}
/* --------------------------------------------------------------------------
   Flèche "aller en bas"
   -------------------------------------------------------------------------- */
.scroll-to-bottom {
  position: fixed;
  right: 1rem;
  bottom: 6rem;
  display: none;
  align-items: center;
  justify-content: center;
  width: 2.8rem;
  height: 2.8rem;
  border-radius: 50%;
  background-color: var(--color-accent);
  color: #fff;
  border: none;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
  z-index: 90;
  cursor: pointer;
  transition:
    transform 0.2s ease,
    opacity 0.2s ease;
}
.scroll-to-bottom svg {
  width: 1.2rem;
  height: 1.2rem;
}
@media (max-width: 640px) {
  .scroll-to-bottom {
    display: flex;
  }
}

/* --------------------------------------------------------------------------
   Modales
   -------------------------------------------------------------------------- */
/* --------------------------------------------------------------------------
   Modales
   -------------------------------------------------------------------------- */
.modal {
  position: fixed;
  inset: 0;
  display: grid;
  place-items: center;
  z-index: 1000;
}
.modal[hidden] {
  display: none;
}
.modal-backdrop {
  position: absolute;
  inset: 0;
  background-color: var(--color-overlay);
}
.modal-content {
  position: relative;
  top: 2vh;
  border-radius: 1.5rem 1.5rem 0em 0em;
  background-color: var(--color-bg);
  max-width: min(1000px, 96vw);
  width: 100%;
  /* max-height: 96vh; */
  height: 96vh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.2);
}
.modal-content--hiska {
  background-color: var(--color-bg);
}

/* Bandeau visuel */
.modal-hero {
  position: relative;
  flex: 0 0 30vh;
  max-height: 26vh;
  overflow: hidden;
}
.modal-hero img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* En-tête texte sticky */
.modal_entete {
  position: sticky;
  top: 0;
  z-index: 3;
  background: linear-gradient(
    180deg,
    rgba(96, 0, 16, 0.95) 0%,
    rgba(96, 0, 16, 0.92) 50%,
    rgba(96, 0, 16, 0.88) 100%
  );
  padding: 1rem 1.75rem 0.75rem;
}
.modal-kicker {
  margin: 0 0 0.4rem;
  font-family: var(--font-body);
  font-size: 0.65rem;
  font-weight: 400;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.7);
}
.modal-title {
  margin: 0;
  color: #fff;
  font-size: clamp(1.4rem, 3.4vw, 2.2rem);
  line-height: 1.1;
}
.modal-subtitle {
  font-family: var(--font-heading);
  font-weight: 300;
  font-style: italic;
  font-size: clamp(0.85rem, 1.6vw, 0.95rem);
  color: rgba(255, 255, 255, 0.85);
}
.modal-close {
  position: absolute;
  top: 1rem;
  right: 1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 3rem;
  height: 3rem;
  border-radius: 50%;
  border: none;
  background: rgba(0, 0, 0, 0.25);
  color: #fff;
  cursor: pointer;
  z-index: 4;
}
.modal-close svg {
  width: 1.5rem;
  height: 1.5rem;
}

/* Barre meta sticky */
.modal-meta-bar {
  position: sticky;
  top: 0;
  z-index: 2;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
  padding: 0.9rem 1.75rem;
  background-color: #f3ede2;
  border-bottom: 1px solid var(--color-border);
}
[data-theme="dark"] .modal-meta-bar {
  background-color: #2a1e16;
}
.modal-meta-item {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
}
.modal-meta-label {
  font-size: 0.6rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--color-text-muted);
}
.modal-meta-value {
  font-size: 0.9rem;
  color: var(--color-text);
  font-weight: 400;
}

/* Corps scrollable */
.modal-body {
  flex: 1;
  padding: 1.5rem 1.75rem 1.75rem;
  overflow-y: auto;

  /* Empêche le scroll de continuer sur la page derrière la modale */
  overscroll-behavior-y: contain;
}
.modal-body p {
  margin-bottom: 1.1rem;
}

/* Citation */
.modal-quote {
  margin: 1.5rem 0;
  padding: 0.9rem 1rem;
  border-left: 2px solid var(--color-accent);
  background: color-mix(in srgb, var(--color-accent) 8%, transparent);
  border-radius: 0.75rem;
}
.modal-quote p {
  margin: 0;
  font-family: var(--font-heading);
  font-style: italic;
  color: var(--color-accent);
  font-size: clamp(1rem, 2vw, 1.15rem);
}

/* Ce que ce projet m'a appris */
.modal-learnings {
  margin-top: 1.5rem;
  padding: 1rem 1rem 0.5rem;
  border-radius: 1rem;
  background-color: color-mix(
    in srgb,
    var(--color-surface) 85%,
    var(--color-bg)
  );
  border: 1px solid var(--color-border);
}
.modal-learnings h3 {
  margin-bottom: 0.75rem;
  font-size: 1rem;
}
.modal-learnings ul {
  margin: 0;
  padding-left: 1.2rem;
  list-style: disc;
}
.modal-learnings li {
  margin-bottom: 0.65rem;
  color: var(--color-text-muted);
}

/* Mots en couleur */
.text-accent {
  color: var(--purple);
  font-weight: 600;
}

/* Mobile : modale plus compacte */
@media (max-width: 640px) {
  .modal-content {
    max-width: 100vw;
    width: 100vw;
    height: 100vh;
    height: 100dvh;
    max-height: 100vh;
    max-height: 100dvh;
    border-radius: 0;
  }

  .modal-hero {
    flex: 0 0 22vh;
  }

  .modal_entete {
    padding: 0.75rem 1.25rem 0.6rem;
  }

  /* La catégorie et le sous-titre restent sur une seule ligne : s'ils sont
     trop longs pour l'écran, on glisse au doigt plutôt que de passer à la
     ligne (ce qui mangeait beaucoup de hauteur au profit du vrai contenu). */
  .modal-kicker,
  .modal-subtitle {
    white-space: nowrap;
    overflow-x: auto;
    overflow-y: hidden;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    -webkit-mask-image: linear-gradient(
      90deg,
      #000 calc(100% - 1.5rem),
      transparent 100%
    );
    mask-image: linear-gradient(
      90deg,
      #000 calc(100% - 1.5rem),
      transparent 100%
    );
  }
  .modal-kicker::-webkit-scrollbar,
  .modal-subtitle::-webkit-scrollbar {
    display: none;
  }

  .modal-kicker {
    font-size: 0.6rem;
    padding-bottom: 0.15rem;
  }

  .modal-title {
    font-size: 1.35rem;
    line-height: 1.15;
  }

  .modal-subtitle {
    font-size: 0.8rem;
    margin-top: 0.3rem;
    padding-bottom: 0.15rem;
  }

  .modal-meta-bar {
    padding: 0.7rem 1.25rem;
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .modal-body {
    padding: 1.25rem;
    padding-bottom: calc(1.25rem + env(safe-area-inset-bottom, 0px));
  }
}

/* --------------------------------------------------------------------------
   Mobile : on agrandit au contraire les textes clés pour rester lisible
   -------------------------------------------------------------------------- */
@media (max-width: 640px) {
  .filter-btn {
    font-size: 0.5rem;
    padding: 0.3rem 0.5rem;
  }

  .filter-reset {
    font-size: 0.5rem;
    padding: 0.3rem 0.5rem;
  }

  .filter-reset--all {
    font-size: 0.72rem;
  }

  .filters__group-label {
    font-size: 0.72rem;
  }

  .project-card__category {
    font-size: 0.65rem;
  }

  .project-card__title {
    font-size: 1.1rem;
  }

  .project-card__desc {
    font-size: 0.85rem;
  }

  .filters {
    margin-bottom: 1.5rem;
  }

  .filters__group {
    margin-bottom: 1rem;
  }

  .filters__list {
    gap: 0.6rem;
  }

  .contact-form__label {
    font-size: 0.68rem;
  }

  .contact-form__input {
    font-size: 0.8rem;
    padding: 0.5rem 1.1rem;
    width: 80%;
    align-self: center;
  }

  .home-footer__links a,
  .site-footer__social-link {
    font-size: 0.7rem;
  }

  .home-footer__copy,
  .site-footer__copy {
    font-size: 0.7rem;
  }

  .home-header__link {
    font-size: 0.8rem;
  }
}
.project-media-pair {
  display: flex;
  gap: 3rem;
  align-items: stretch;
  margin: 1.5rem 0;
}
.project-media-pair__video {
  flex: 1.35;
  min-width: 0;
}
.project-media-pair__storyboard {
  width: 16vw;
}
.project-video,
.project-storyboard {
  width: 100%;
  height: 100%;
  display: block;
  border-radius: 1rem;
  object-fit: cover;
}
.project-video {
  aspect-ratio: 16 / 9;
  background: var(--color-black);
}
.project-storyboard {
  aspect-ratio: 3 / 4;
  background: var(--color-surface);
  border: 1px solid var(--color-border);
}
@media (max-width: 768px) {
  .project-media-pair {
    flex-direction: column;
  }

  .project-media-pair__video,
  .project-media-pair__storyboard {
    flex: none;
  }

  .project-video {
    aspect-ratio: 16 / 9;
  }

  .project-storyboard {
    aspect-ratio: 3 / 4;
  }
}
.project-image--zoomable {
  cursor: zoom-in;
}
.image-lightbox {
  position: fixed;
  inset: 0;
  z-index: 1300;
  display: grid;
  place-items: center;
  padding: 1rem;
}
.image-lightbox[hidden] {
  display: none;
}
.image-lightbox__backdrop {
  position: absolute;
  inset: 0;
  background-color: rgba(16, 10, 8, 0.86);
  backdrop-filter: blur(5px);
}
.image-lightbox__content {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  width: min(96vw, 1200px);
  max-height: 94vh;
}
.image-lightbox__content img {
  display: block;
  width: auto;
  max-width: 100%;
  max-height: calc(94vh - 4rem);
  margin-inline: auto;
  object-fit: contain;
  border-radius: var(--radius-card);
  background-color: var(--color-surface);
}
.image-lightbox__caption {
  margin: 0;
  text-align: center;
  color: #fff;
  font-size: var(--text-sm);
}
.image-lightbox__close {
  position: absolute;
  top: 0.5rem;
  right: 0.5rem;
  z-index: 2;
  display: grid;
  place-items: center;
  width: 2.75rem;
  height: 2.75rem;
  border: 1px solid rgba(255, 255, 255, 0.35);
  border-radius: 50%;
  color: #fff;
  background-color: rgba(0, 0, 0, 0.35);
  font-size: 1.75rem;
  line-height: 1;
  cursor: pointer;
}

/* --------------------------------------------------------------------------
   About page — nouvelle structure
   -------------------------------------------------------------------------- */

.about-intro {
  min-height: 100svh;
  display: flex;
  align-items: center;
  padding-top: clamp(8rem, 14vh, 12rem);
  padding-bottom: clamp(4rem, 8vh, 7rem);
}
.about-intro__inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}
.about-intro__title {
  max-width: 12ch;
  margin: 0;
  font-size: clamp(3.5rem, 11vw, 8rem);
  line-height: 0.95;
  letter-spacing: -0.07em;
}
.about-intro__actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.75rem;
  margin-top: 1.5rem;
}
.about-intro__copy {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(2rem, 8vw, 8rem);
  width: min(100%, 64rem);
  margin-top: clamp(5rem, 12vw, 9rem);
  text-align: left;
}
.about-intro__copy p {
  max-width: 38ch;
}
.about-intro__copy p {
  max-width: 38ch;
  font-family: var(--font-body);
  font-size: var(--text-base);
  line-height: 1.6;
  color: var(--color-text-muted);
}
.about-intro__copy .about-intro__lead {
  color: var(--color-text-muted);
  font-size: var(--text-base);
  line-height: 1.6;
}
.section-heading {
  margin-bottom: clamp(2rem, 5vw, 4rem);
}
.section-heading--center {
  text-align: center;
}
.section-heading h2 {
  margin: 0;
  font-size: clamp(2.5rem, 7vw, 5rem);
  letter-spacing: -0.06em;
}
.timeline {
  position: relative;
  display: grid;
  gap: 0;
  max-width: 70rem;
  margin-inline: auto;
}
.timeline::before {
  content: "";
  position: absolute;
  top: 0.75rem;
  bottom: 0.75rem;
  left: 7.5rem;
  width: 1px;
  background-color: var(--color-border);
}
.timeline__item {
  position: relative;
  display: grid;
  grid-template-columns: 7.5rem 1fr;
  gap: 2rem;
  padding-block: 1.5rem;
}
.timeline__item::before {
  content: "";
  position: absolute;
  top: 1.95rem;
  left: 7.1rem;
  width: 0.85rem;
  height: 0.85rem;
  border: 2px solid var(--color-bg);
  border-radius: 50%;
  background-color: var(--color-accent);
  box-shadow: 0 0 0 1px var(--color-accent);
}
.timeline__year {
  color: var(--color-accent);
  font-size: var(--text-sm);
  font-weight: 700;
}
.timeline__content {
  padding-left: 1.5rem;
}
.timeline__content h3 {
  margin: 0 0 0.5rem;
  font-size: clamp(1.2rem, 2.5vw, 1.7rem);
}
.timeline__content p {
  max-width: 55ch;
  margin: 0;
}
.about-skills {
  background-color: var(--color-lilac);
}
.about-skills__grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1rem;
  justify-items: center;
}
.about-skill-card {
  align-content: center;
  min-height: 17rem;
  padding: clamp(1rem, 3vw, 1.75rem);
  background-color: #171717;
  border-radius: var(--radius-card);
  color: var(--color-lilac);
}
.about-skill-card h3 {
  margin-bottom: 1.25rem;
  color: var(--color-lilac);
  text-align: center;
  font-size: clamp(1.25rem, 2.5vw, 1.8rem);
}
.about-skill-card p {
  color: rgba(255, 255, 255, 0.82);
  font-size: var(--text-sm);
}
.about-contact {
  position: relative;
  overflow: hidden;
  text-align: center;
}
.about-contact::before {
  content: "";
  position: absolute;
  inset: 20% 15%;
  z-index: 0;
  background: radial-gradient(
    ellipse,
    color-mix(in srgb, var(--color-lilac) 32%, transparent),
    transparent 68%
  );
  pointer-events: none;
}
.about-contact__inner {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
}
.about-contact__inner h2 {
  margin: 0;
  font-size: clamp(2.5rem, 7vw, 5rem);
  letter-spacing: -0.06em;
}
.about-contact__inner p {
  max-width: 36ch;
  margin-block: 1rem 1.5rem;
}
.about-visual {
  margin: 0;
  overflow: hidden;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-card);
  background-color: var(--color-bg-alt);
}
.about-visual img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
}
.about-visual figcaption {
  padding: 0.75rem 1rem;
  color: var(--color-text-muted);
  font-size: var(--text-xs);
}
.about-visual--placeholder {
  display: grid;
  min-height: 20rem;
  place-items: center;
  color: var(--color-text-muted);
}

/* Responsive */
@media (max-width: 768px) {
  .about-intro__copy {
    grid-template-columns: 1fr;
    gap: 1rem;
    margin-top: 4rem;
  }

  .about-intro__copy p {
    max-width: none;
  }

  .about-skills__grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
@media (max-width: 520px) {
  .about-intro__title {
    font-size: clamp(3rem, 16vw, 5rem);
  }

  .timeline::before {
    left: 0.45rem;
  }

  .timeline__item {
    grid-template-columns: 1fr;
    gap: 0.4rem;
    padding-left: 2rem;
  }

  .timeline__item::before {
    top: 1.55rem;
    left: 0.05rem;
  }

  .timeline__content {
    padding-left: 0;
  }

  .about-skills__grid {
    grid-template-columns: 1fr;
  }
}
.about-intro,
.about-timeline,
.about-skills,
.about-contact {
  min-height: 100svh;
  display: flex;
  align-items: center;
}
@media (max-width: 768px) {
  .about-intro,
  .about-timeline,
  .about-skills,
  .about-contact {
    min-height: auto;
  }
}
.about-timeline,
.about-skills,
.about-contact {
  padding-block: clamp(5rem, 10vh, 9rem);
}
.about-skills {
  min-height: 100svh;
  display: flex;
  align-items: center;
  background-color: var(--color-lilac);
}
.about-skill-card__list {
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
  margin: 0;
  padding: 0;
  list-style: none;
  text-align: center;
}
.about-skill-card__list li {
  margin: 0;
  color: rgba(255, 255, 255, 0.84);
  font-family: var(--font-body);
  font-size: var(--text-sm);
  line-height: 1.35;
}
@media (max-width: 768px) {
  .about-skills__grid {
    grid-template-columns: 1fr 1fr;
  }

  .about-skill-card {
    min-height: 13rem;
  }

  .about-skill-card__list {
    gap: 0.3rem;
  }

  .about-skill-card__list li {
    font-size: 0.78rem;
  }
}
@media (max-width: 520px) {
  .about-skills__grid {
    grid-template-columns: 1fr;
  }

  .about-skill-card {
    min-height: auto;
    width: 90%;
  }
}
/* --------------------------------------------------------------------------
   About — ajustement des espaces entre sections
   -------------------------------------------------------------------------- */

/* On garde la première section pleine hauteur */
.about-intro {
  min-height: 100svh;
}

/* La timeline commence plus tôt */
.about-timeline {
  min-height: auto;
  padding-top: clamp(3rem, 6vh, 5rem);
  padding-bottom: clamp(5rem, 10vh, 9rem);
}

/* Évite un espace trop important avant le titre */
.about-timeline .section-heading {
  margin-top: -4rem;
}

/* Section compétences : toujours pleine page */
.about-skills {
  min-height: 100svh;
  padding-block: clamp(5rem, 10vh, 9rem);
}

/* Contact plus compact, sans formulaire sur cette page */
.about-contact {
  min-height: 70svh;
  padding-block: clamp(4rem, 8vh, 6rem);
}

/* Mobile : on évite les grands décalages négatifs */
@media (max-width: 768px) {
  .about-timeline {
    min-height: auto;
    padding-top: 3rem;
    padding-bottom: 5rem;
  }

  .about-timeline .section-heading {
    margin-top: 0;
  }

  .about-skills {
    min-height: auto;
    padding-block: 5rem;
  }

  .about-contact {
    min-height: auto;
    padding-block: 5rem;
  }
}

/* --------------------------------------------------------------------------
   Apparition des sections au scroll
   -------------------------------------------------------------------------- */

.reveal {
  opacity: 0;
  transform: translateY(1.5rem);
  transition:
    opacity 600ms ease,
    transform 600ms cubic-bezier(0.16, 1, 0.3, 1);
}

.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

.reveal--delay-1 {
  transition-delay: 80ms;
}

.reveal--delay-2 {
  transition-delay: 160ms;
}

.reveal--delay-3 {
  transition-delay: 240ms;
}

.reveal--delay-4 {
  transition-delay: 320ms;
}

/* --------------------------------------------------------------------------
   Animation des modales
   -------------------------------------------------------------------------- */

.modal-content {
  animation: modal-enter 280ms cubic-bezier(0.16, 1, 0.3, 1) both;
}

.modal-backdrop {
  animation: backdrop-enter 220ms ease both;
}

@keyframes modal-enter {
  from {
    opacity: 0;
    transform: translateY(1.25rem) scale(0.985);
  }

  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

@keyframes backdrop-enter {
  from {
    opacity: 0;
  }

  to {
    opacity: 1;
  }
}

.form-honeypot {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.contact-form__consent {
  display: flex;
  align-items: flex-start;
  gap: 0.6rem;
  color: var(--color-text-muted);
  font-size: var(--text-xs);
  line-height: 1.45;
}

.contact-form__consent input {
  flex: 0 0 auto;
  width: 1rem;
  height: 1rem;
  margin-top: 0.15rem;
  accent-color: var(--color-accent);
}

.contact-form__feedback {
  margin-top: 1rem;
  min-height: 1.5em;
  font-size: 0.95rem;
}

.contact-form__feedback[data-state="success"] {
  color: #2f7d4a;
}

.contact-form__feedback[data-state="error"] {
  color: #a33a3a;
}

.contact-form button[type="submit"]:disabled {
  opacity: 0.65;
  cursor: wait;
}

.project-section {
  margin-bottom: 2rem;
}

.project-section h3 {
  margin-bottom: 0.55rem;
}

.project-gallery {
  margin-block: 2rem;
}

.project-gallery__viewport {
  overflow: hidden;
  background: var(--color-bg-alt);
  border: 1px solid var(--color-border);
  border-radius: 1rem;
}

.project-gallery__image {
  display: block;
  width: 100%;
  min-height: 14rem;
  max-height: 20rem;
  object-fit: contain;
  object-position: center;
  cursor: zoom-in;
}

.project-gallery__controls {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  margin-top: 0.85rem;
}

.project-gallery__button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.3rem;
  height: 2.3rem;
  padding: 0;
  font-size: 1.15rem;
  line-height: 1;
  color: var(--color-accent);
  background: transparent;
  border: 1px solid var(--color-accent);
  border-radius: 50%;
  cursor: pointer;
  transition:
    background-color var(--transition),
    color var(--transition),
    transform var(--transition);
}

.project-gallery__button:hover,
.project-gallery__button:focus-visible {
  color: var(--color-bg);
  background-color: var(--color-accent);
  transform: translateY(-1px);
}

.project-gallery__dots {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
}

.project-gallery__dot {
  width: 0.55rem;
  height: 0.55rem;
  padding: 0;
  background: transparent;
  border: 1px solid var(--color-accent);
  border-radius: 50%;
  cursor: pointer;
  transition:
    background-color var(--transition),
    transform var(--transition);
}

.project-gallery__dot:hover,
.project-gallery__dot:focus-visible,
.project-gallery__dot.is-active {
  background-color: var(--color-accent);
  transform: scale(1.18);
}

.project-document-link {
  margin-block: 1.5rem;
  text-align: center;
}

@media (max-width: 640px) {
  .project-gallery__image {
    min-height: 11rem;
  }
}

.domains__grid {
  width: 80%;
  margin-inline: auto;
}

.domain-card {
  min-height: 17rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1.25rem;
  padding: 1.75rem;
  text-align: center;
}

.domain-card__label {
  margin: 0;
  font-size: clamp(1.25rem, 3vw, 1.8rem);
}

.domain-card__tools {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.5rem;
  width: 100%;
}

.domain-card__tools li {
  padding: 0.35rem 0.65rem;
  font-size: var(--text-xs);
  line-height: 1.2;
  color: #f5ede2;
  border: 1px solid currentColor;
  border-radius: var(--radius-pill);
}

@media (max-width: 640px) {
  .domains__grid {
    width: 88%;
  }

  .domain-card {
    min-height: 15rem;
    padding: 1.25rem;
  }
}

/* Logo : on masque la version mobile par défaut */
.hero-home__logo--mobile {
  display: none;
}

@media (max-width: 640px) {
  .hero-home__logo--desktop {
    display: none;
  }

  .hero-home__logo--mobile {
    display: block;
    width: min(82vw, 22rem);
  }
}

@media (max-width: 640px) {
  .about-intro__copy {
    width: 91%;
  }
}
.contact-form__link {
  color: #0f2d4e;
  text-decoration: underline;
}

@media (max-width: 640px) {
  .secml {
    width: 91%;
    justify-self: center;
  }
}

/* --------------------------------------------------------------------------
   AMÉLIORATIONS UX — barre de progression de scroll
   -------------------------------------------------------------------------- */
.scroll-progress {
  position: fixed;
  top: 0;
  left: 0;
  height: 3px;
  width: 0%;
  background-color: var(--color-accent);
  z-index: 1200;
  pointer-events: none;
  transform-origin: left;
}

/* --------------------------------------------------------------------------
   AMÉLIORATIONS UX — le bandeau de navigation se soulève légèrement au scroll
   -------------------------------------------------------------------------- */
.home-header__nav {
  transition:
    box-shadow var(--transition),
    transform var(--transition);
}
.home-header__nav.is-scrolled {
  box-shadow: 0 0.6rem 1.6rem rgba(0, 0, 0, 0.22);
}

/* --------------------------------------------------------------------------
   AMÉLIORATIONS UX — menu mobile animé (ouverture / fermeture en douceur)
   -------------------------------------------------------------------------- */
@media (max-width: 879.98px) {
  .home-header__menu {
    display: flex;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transform: translateY(-0.6rem) scale(0.98);
    transition:
      opacity 220ms ease,
      transform 260ms cubic-bezier(0.16, 1, 0.3, 1),
      visibility 0s linear 220ms;
  }
  .home-header__menu.is-open {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    transform: translateY(0) scale(1);
    transition:
      opacity 220ms ease,
      transform 260ms cubic-bezier(0.16, 1, 0.3, 1),
      visibility 0s linear 0s;
  }

  /* Petit effet d'apparition en cascade sur les liens du menu */
  .home-header__menu .home-header__list li {
    opacity: 0;
    transform: translateY(0.4rem);
    transition:
      opacity 260ms ease,
      transform 260ms ease;
  }
  .home-header__menu.is-open .home-header__list li {
    opacity: 1;
    transform: translateY(0);
  }
  .home-header__menu.is-open .home-header__list li:nth-child(1) {
    transition-delay: 60ms;
  }
  .home-header__menu.is-open .home-header__list li:nth-child(2) {
    transition-delay: 110ms;
  }
  .home-header__menu.is-open .home-header__list li:nth-child(3) {
    transition-delay: 160ms;
  }
  .home-header__menu.is-open .home-header__list li:nth-child(4) {
    transition-delay: 210ms;
  }

  .home-header__link {
    display: inline-block;
    padding-block: 0.35rem;
  }
}

/* --------------------------------------------------------------------------
   AMÉLIORATIONS UX — apparition/disparition animée des cartes filtrées
   -------------------------------------------------------------------------- */
.projects-grid > li {
  transition:
    opacity 320ms ease,
    transform 320ms cubic-bezier(0.16, 1, 0.3, 1);
}
.projects-grid > li.is-filter-hidden {
  opacity: 0;
  transform: translateY(0.6rem) scale(0.97);
}

/* --------------------------------------------------------------------------
   AMÉLIORATIONS UX — les images apparaissent en fondu une fois chargées
   -------------------------------------------------------------------------- */
img[loading="lazy"],
#image-lightbox-image {
  opacity: 0;
  transition: opacity 450ms ease;
}
img[loading="lazy"].is-loaded,
#image-lightbox-image.is-loaded {
  opacity: 1;
}

/* --------------------------------------------------------------------------
   AMÉLIORATIONS UX — petit "pulse" tactile au clic sur les boutons
   -------------------------------------------------------------------------- */
.btn-pill,
.filter-btn,
.project-gallery__button {
  position: relative;
  isolation: isolate;
}
.btn-pill::after,
.filter-btn::after,
.project-gallery__button::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background-color: currentColor;
  opacity: 0;
  transform: scale(0.85);
  pointer-events: none;
  z-index: -1;
}
.btn-pill.is-pressed::after,
.filter-btn.is-pressed::after,
.project-gallery__button.is-pressed::after {
  animation: btn-pulse 420ms ease-out;
}
@keyframes btn-pulse {
  from {
    opacity: 0.22;
    transform: scale(0.85);
  }
  to {
    opacity: 0;
    transform: scale(1.18);
  }
}

/* --------------------------------------------------------------------------
   AMÉLIORATIONS UX — la modale s'ouvre depuis le bouton cliqué
   -------------------------------------------------------------------------- */
.modal-content {
  transform-origin: var(--modal-origin-x, 50%) var(--modal-origin-y, 50%);
}

/* --------------------------------------------------------------------------
   AMÉLIORATIONS UX — galerie et lightbox utilisables au doigt (mobile)
   -------------------------------------------------------------------------- */
.project-gallery__image {
  touch-action: pan-y;
}
.image-lightbox__content img {
  touch-action: pan-y;
}

@media (prefers-reduced-motion: reduce) {
  .home-header__menu,
  .home-header__menu .home-header__list li,
  .projects-grid > li,
  img[loading="lazy"],
  #image-lightbox-image {
    transition: none !important;
  }
  .btn-pill.is-pressed::after,
  .filter-btn.is-pressed::after,
  .project-gallery__button.is-pressed::after {
    animation: none !important;
  }
}
