:root {
  --accent: #f1d22b;
  --background: #f1f0ea;
  --surface: #deddd6;
  --text: #262622;
  --text-muted: #686861;
  --border: rgba(38, 38, 34, 0.2);
  --header-height: 82px;
}

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

html {
  scroll-behavior: auto;
  scrollbar-width: thin;
  scrollbar-color: var(--accent) transparent;
}

body {
  margin: 0;
  overflow-x: hidden;

  font-family:
    Inter,
    Arial,
    Helvetica,
    sans-serif;

  color: var(--text);
  background: var(--background);

  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 100;
  pointer-events: none;

  opacity: 0.035;

  background-image:
    repeating-radial-gradient(
      circle at 0 0,
      transparent 0,
      rgba(0, 0, 0, 0.35) 1px,
      transparent 2px
    );

  background-size: 5px 5px;
}

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

a {
  color: inherit;
}

/* Header */

.header {
  position: fixed;
  top: 0;
  left: 0;
  z-index: 50;

  display: grid;
  grid-template-columns: auto minmax(100px, 1fr) auto auto;
  align-items: center;
  gap: 32px;

  width: 100%;
  min-height: var(--header-height);
  padding: 18px 32px;

  background: rgba(241, 240, 234, 0.84);
  border-bottom: 1px solid var(--border);

  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
}

.logo {
  display: inline-flex;
  align-items: center;
  gap: 8px;

  font-size: 14px;
  font-weight: 800;
  letter-spacing: -0.02em;
  text-decoration: none;
}

.logo__img {
  width: 28px;
  height: 28px;

  flex-shrink: 0;
}

.scroll-progress {
  width: 100%;
  height: 2px;
  overflow: hidden;
  background: var(--border);
}

.scroll-progress__bar {
  width: 0;
  height: 100%;
  background: var(--accent);
}

.navigation {
  display: flex;
  gap: 24px;
}

.navigation a {
  position: relative;

  font-size: 13px;
  font-weight: 600;
  text-decoration: none;
}

.navigation a::after {
  content: "";
  position: absolute;
  right: 0;
  bottom: -5px;
  left: 0;

  height: 1px;

  background: currentColor;

  transform: scaleX(0);
  transform-origin: right;
  transition: transform 250ms ease;
}

.navigation a:hover::after {
  transform: scaleX(1);
  transform-origin: left;
}

/* Toggle menu mobile */

.nav-toggle {
  display: none;

  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 5px;

  width: 36px;
  height: 36px;
  padding: 0;

  background: none;
  border: none;
  cursor: pointer;
}

.nav-toggle__bar {
  display: block;

  width: 22px;
  height: 2px;

  background: var(--text);
  border-radius: 2px;

  transition: transform 300ms ease, opacity 300ms ease;
}

.nav-toggle--open .nav-toggle__bar:first-child {
  transform: translateY(7px) rotate(45deg);
}

.nav-toggle--open .nav-toggle__bar:last-child {
  transform: translateY(-7px) rotate(-45deg);
}

.header-contact {
  padding: 11px 15px;
  line-height: 1;

  color: var(--background);
  background: var(--text);

  font-size: 12px;
  font-weight: 700;
  text-decoration: none;
  text-transform: uppercase;
}

.header-socials {
  display: none;

  padding: 11px 15px;
  line-height: 1;

  color: var(--text);
  background: var(--accent);

  font-size: 12px;
  font-weight: 700;
  text-decoration: none;
  text-transform: uppercase;

  transition: transform 250ms ease, box-shadow 250ms ease;
}

.header-socials:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(241, 210, 43, 0.4);
}

/* Hero */

.hero {
  position: relative;

  display: flex;
  flex-direction: column;
  justify-content: space-between;

  min-height: 100svh;

  padding:
    calc(var(--header-height) + 56px)
    32px
    32px;
}

.hero__title-wrapper {
  position: relative;
  z-index: 2;
}

.hero__eyebrow,
.hero__introduction {
  visibility: hidden;
}

.hero__eyebrow {
  margin: 0 0 18px;

  color: var(--text-muted);

  font-size: clamp(12px, 1.1vw, 15px);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.hero__title {
  width: 100%;
  margin: 0;
  overflow: hidden;

  font-size: clamp(60px, 13vw, 220px);
  font-weight: 900;
  line-height: 0.8;
  letter-spacing: -0.08em;
  text-transform: uppercase;
  white-space: nowrap;
}

/* Titre animé avec effet glitch */

.hero__title-word,
.glitch-text {
  position: relative;
  display: inline-block;
  max-width: 100%;
}

.hero__title-word {
  transform-origin: left center;
  will-change: transform, filter;
}

.hero__title-word::before,
.hero__title-word::after,
.glitch-text::before,
.glitch-text::after {
  content: attr(data-text);

  position: absolute;
  inset: 0;

  pointer-events: none;
  opacity: 0;
}

.hero__title-word::before,
.glitch-text::before {
  color: #00ffff;
}

.hero__title-word::after,
.glitch-text::after {
  color: #ff0055;
}

.hero__title-word.is-glitching::before,
.glitch-text.is-glitching::before {
  opacity: 0.85;
  animation: glitch-cyan 0.3s steps(2, end);
}

.hero__title-word.is-glitching::after,
.glitch-text.is-glitching::after {
  opacity: 0.85;
  animation: glitch-red 0.3s steps(2, end);
}

@keyframes glitch-cyan {
  0% {
    transform: translate(-8px, -2px);
    clip-path: inset(0 0 68% 0);
  }

  20% {
    transform: translate(6px, 2px);
    clip-path: inset(38% 0 18% 0);
  }

  40% {
    transform: translate(-5px, 1px);
    clip-path: inset(70% 0 4% 0);
  }

  60% {
    transform: translate(7px, -2px);
    clip-path: inset(12% 0 58% 0);
  }

  80% {
    transform: translate(-3px, 2px);
    clip-path: inset(48% 0 30% 0);
  }

  100% {
    transform: translate(0, 0);
    clip-path: inset(0);
  }
}

@keyframes glitch-red {
  0% {
    transform: translate(8px, 2px);
    clip-path: inset(68% 0 0 0);
  }

  20% {
    transform: translate(-6px, -2px);
    clip-path: inset(14% 0 58% 0);
  }

  40% {
    transform: translate(5px, -1px);
    clip-path: inset(46% 0 28% 0);
  }

  60% {
    transform: translate(-7px, 2px);
    clip-path: inset(76% 0 3% 0);
  }

  80% {
    transform: translate(4px, -2px);
    clip-path: inset(25% 0 45% 0);
  }

  100% {
    transform: translate(0, 0);
    clip-path: inset(0);
  }
}

.hero__content {
  display: block;
  margin-top: 64px;
}

@media (min-width: 1367px) {
  .hero__content {
    display: grid;
    grid-template-columns:
      minmax(280px, 0.8fr)
      0.2fr
      minmax(260px, 1fr);
    align-items: end;
    gap: 32px;
  }

  .hero__image-wrapper {
    grid-column: 1;
  }

  .hero__introduction {
    grid-column: 3;
  }
}

.hero__image-wrapper {
  margin: 0;
  overflow: hidden;
  cursor: pointer;

  aspect-ratio: 4 / 5;

  background: var(--surface);
}

.hero__image {
  width: 100%;
  height: 100%;

  object-fit: cover;
  filter: grayscale(1);
}

.hero__introduction {
  padding-bottom: 20px;
}

.hero__introduction p {
  margin: 0 0 28px;

  font-size: clamp(17px, 1.55vw, 24px);
  line-height: 1.42;
  letter-spacing: -0.035em;
}

.text-link {
  display: inline-flex;
  align-items: center;
  gap: 10px;

  padding-bottom: 5px;

  border-bottom: 1px solid currentColor;

  font-size: 14px;
  font-weight: 700;
  text-decoration: none;
  text-transform: uppercase;
}

.hero__scroll {
  position: absolute;
  right: 32px;
  bottom: 34px;

  display: flex;
  gap: 12px;

  font-size: 12px;
  font-weight: 700;
  text-decoration: none;
  text-transform: uppercase;
}

/* Sections générales */

.section {
  padding: 150px 32px;
  border-top: 1px solid var(--border);
}

.section-heading {
  display: grid;
  grid-template-columns: minmax(80px, 1fr) 3fr;
  gap: 32px;

  margin-bottom: 90px;
}

.section-number {
  margin: 8px 0 0;

  color: var(--text-muted);

  font-size: 13px;
  font-weight: 700;
}

.section-heading h2 {
  margin: 0;

  font-size: clamp(54px, 8vw, 126px);
  font-weight: 800;
  line-height: 0.9;
  letter-spacing: -0.075em;
  text-transform: uppercase;
}

.section-description {
  max-width: 400px;
  margin: 24px 0 0;

  color: var(--text-muted);

  font-size: 16px;
  line-height: 1.5;
}

/* Présentation */

.about__content {
  display: grid;
  grid-template-columns: 1.35fr 0.65fr;
  gap: 100px;
}

.about__lead {
  max-width: 950px;
  margin: 0;

  font-size: clamp(38px, 5.3vw, 82px);
  font-weight: 700;
  line-height: 0.98;
  letter-spacing: -0.065em;
}

.about__details {
  align-self: end;
}

.about__details p {
  margin: 0 0 24px;

  color: var(--text-muted);

  font-size: 17px;
  line-height: 1.55;
}

/* Portfolio */

.portfolio-grid {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 44px 16px;
}

.project {
  grid-column: span 5;
}

.project:nth-child(2) {
  grid-column: 8 / span 5;
  margin-top: 80px;
}

.project:nth-child(3) {
  grid-column: 1 / span 5;
}

.project:nth-child(4) {
  grid-column: 7 / span 5;
  margin-top: 50px;
}

.project--large {
  grid-column: span 7;
}

.project--wide {
  grid-column: 3 / span 8;
}

.project__image-wrapper {
  overflow: hidden;
  background: var(--surface);
}

.project__image {
  width: 100%;
  aspect-ratio: 4 / 5;

  object-fit: cover;
  cursor: pointer;

  transition:
    transform 700ms cubic-bezier(0.2, 0.8, 0.2, 1);
}

.project__image-wrapper {
  cursor: pointer;
}

.project--large .project__image,
.project--wide .project__image {
  aspect-ratio: 16 / 13;
}

.project:hover .project__image {
  transform: scale(1.025);
}

.project__information {
  display: flex;
  justify-content: space-between;
  gap: 20px;

  padding-top: 14px;
}

.project__information h3,
.project__information p {
  margin: 0;
}

.project__information h3 {
  font-size: 17px;
}

.project__information p {
  color: var(--text-muted);
  font-size: 13px;
}

.portfolio-button {
  display: flex;
  justify-content: space-between;
  align-items: center;

  max-width: 720px;
  margin: 130px auto 0;
  padding: 24px 0;

  border-top: 1px solid var(--text);
  border-bottom: 1px solid var(--text);

  font-size: clamp(24px, 3vw, 45px);
  font-weight: 700;
  text-decoration: none;
  letter-spacing: -0.04em;
}

/* Indicateurs carrousel mobile */

.carousel-dots {
  display: none;
  justify-content: center;
  gap: 10px;

  margin-top: 24px;
}

.carousel-dots__dot {
  width: 8px;
  height: 8px;

  background: var(--border);
  border-radius: 50%;

  transition: background 250ms ease;
}

.carousel-dots__dot--active {
  background: var(--text);
}

/* Liens sociaux */

.links-section {
  color: var(--background);
  background: var(--text);
}

.links-section .section-number,
.links-section .section-description {
  color: rgba(241, 240, 234, 0.6);
}

.social-links {
  border-top: 1px solid rgba(241, 240, 234, 0.25);
}

.social-link {
  display: grid;
  grid-template-columns: 64px 1fr auto;
  align-items: center;
  gap: 24px;

  padding: 34px 0;

  border-bottom: 1px solid rgba(241, 240, 234, 0.25);

  color: var(--background);
  text-decoration: none;

  transition:
    padding 350ms ease,
    color 350ms ease,
    background 350ms ease,
    box-shadow 350ms ease;
}

.social-link:hover {
  padding-right: 20px;
  padding-left: 20px;
}

/* Logo placé à gauche */

.social-link__icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;

  width: 80px;
  height: 80px;

  color: currentColor;

  border: 1px solid rgba(241, 240, 234, 0.25);
  border-radius: 50%;

  transition:
    color 350ms ease,
    background-color 350ms ease,
    border-color 350ms ease,
    transform 350ms cubic-bezier(0.2, 0.8, 0.2, 1),
    box-shadow 350ms ease;
}

.social-link__icon svg,
.social-link__icon img {
  width: 60px;
  height: 60px;

  object-fit: contain;
}

/*
 * Permet aux SVG utilisant currentColor
 * de prendre automatiquement la couleur du lien.
 */

.social-link__icon svg {
  fill: currentColor;
}

.social-link__name {
  font-size: clamp(34px, 5vw, 76px);
  font-weight: 700;
  letter-spacing: -0.055em;
}

.social-link__arrow {
  font-size: 50px;

  transition:
    transform 350ms cubic-bezier(0.2, 0.8, 0.2, 1),
    filter 350ms ease;
}

.social-link:hover .social-link__icon {
  transform: scale(1.14) rotate(-8deg);
}

.social-link:hover .social-link__arrow {
  transform: translate(7px, -7px);
}

/* Instagram */

.social-link--instagram:hover {
  color: #ffffff;

  background:
    linear-gradient(
      135deg,
      #f58529 0%,
      #dd2a7b 36%,
      #8134af 68%,
      #515bd4 100%
    );
}

.social-link--instagram:hover .social-link__icon {
  color: #ffffff;

  background: rgba(255, 255, 255, 0.14);
  border-color: rgba(255, 255, 255, 0.6);

  box-shadow:
    0 0 12px rgba(255, 255, 255, 0.22),
    0 0 26px rgba(221, 42, 123, 0.42);
}

/* Snapchat */

.social-link--snapchat:hover {
  color: #111111;
  background: #fffc00;
}

.social-link--snapchat:hover .social-link__icon {
  color: #111111;

  background: rgba(255, 255, 255, 0.35);
  border-color: rgba(17, 17, 17, 0.5);

  box-shadow:
    0 0 12px rgba(255, 252, 0, 0.65),
    0 0 28px rgba(255, 252, 0, 0.4);
}

.social-link--linkedin:hover {
  color: #ffffff;
  background: #0a66c2;
}

.social-link--linkedin:hover .social-link__icon {
  color: #ffffff;

  background: rgba(255, 255, 255, 0.14);
  border-color: rgba(255, 255, 255, 0.6);

  box-shadow:
    0 0 12px rgba(10, 102, 194, 0.65),
    0 0 28px rgba(10, 102, 194, 0.45);
}
/* Portfolio */

.social-link--portfolio:hover {
     color: #ffffff;
  background: #00a86b;
}

.social-link--portfolio:hover .social-link__icon {
color: #ffffff;

  background: rgba(255,255,255,.16);
  border-color: rgba(255,255,255,.55);

  box-shadow:
    0 0 12px rgba(0,168,107,.6),
    0 0 28px rgba(0,168,107,.45);
}

/* Footer */

.footer {
  padding: 110px 32px 32px;

  color: var(--text);
  background: var(--accent);
}

.footer__label {
  margin: 0 0 30px;

  font-size: 15px;
  font-weight: 700;
  text-transform: uppercase;
}
.footer__contacts {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.footer__contact {
  display: inline-flex;
  align-items: center;
  gap: 18px;

  width: fit-content;

  color: inherit;
  text-decoration: none;
}

.footer__contact svg {
  flex-shrink: 0;

  width: 30px;
  height: 30px;
}

.footer__email {
  font-size: clamp(20px, 5.5vw, 70px);
  font-weight: 800;
  line-height: .9;
  letter-spacing: -.075em;
}

.footer__email svg {
  width: .8em;
  height: .8em;
}

.footer__phone {
  font-size: clamp(24px, 3vw, 34px);
  font-weight: 700;
  letter-spacing: -.03em;
}

.footer__phone svg {
  width: .9em;
  height: .9em;
}

.footer__whatsapp {
  display: none;
  gap: 24px;
}

.footer__whatsapp-link {
  display: inline-flex;
  align-items: center;
  gap: 12px;

  color: inherit;
  text-decoration: none;

  font-size: clamp(22px, 3vw, 32px);
  font-weight: 700;
  letter-spacing: -.03em;
}

.footer__whatsapp-link svg {
  flex-shrink: 0;

  width: .9em;
  height: .9em;
}

.footer__bottom {
  display: flex;
  justify-content: center;
  align-items: center;

  min-height: 20vh;

  font-size: 22px;
  font-weight: 500;
  text-transform: uppercase;
}

.footer__bottom p {
  margin: 0;
}

.footer__bottom a {
  color: inherit;
  text-decoration: underline;
  text-underline-offset: 4px;

  transition: opacity 250ms ease;
}

.footer__bottom a:hover {
  opacity: 0.6;
}

/* Tablette */

@media (max-width: 1366px) {
  .header {
    grid-template-columns: auto 1fr auto auto;
    gap: 18px;

    padding: 16px 20px;
  }

  .nav-toggle {
    display: flex;
  }

  .navigation {
    display: none;

    position: absolute;
    top: 100%;
    left: 0;

    flex-direction: column;
    gap: 0;

    width: 100%;

    background: rgba(241, 240, 234, 0.96);
    border-bottom: 1px solid var(--border);

    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
  }

  .navigation--open {
    display: flex;
  }

  .navigation a {
    padding: 18px 24px;

    font-size: 15px;

    border-top: 1px solid var(--border);
  }

  .hero {
    padding:
      calc(var(--header-height) + 45px)
      20px
      30px;
  }

  .hero__content {
    margin-top: 24px;
  }

  .hero__image-wrapper {
    width: min(90%, 700px);
  }

  .hero__introduction {
    max-width: 100%;
    margin-left: 0;
    margin-top: 32px;
  }

  .hero__introduction p {
    font-size: clamp(18px, 2.2vw, 24px);
    line-height: 1.55;
    letter-spacing: -0.02em;
    margin: 0 0 36px;
  }

  .hero__scroll {
    display: none;
  }

  .section {
    padding: 80px 24px;
    overflow: hidden;
  }

  .section-heading {
    grid-template-columns: 50px 1fr;
    gap: 10px;

    margin-bottom: 56px;
  }

  .about__content {
    grid-template-columns: 1fr;
    gap: 50px;
  }

  .about__details {
    max-width: 100%;
    margin-left: 0;
  }

  .portfolio-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 36px 12px;
  }

  .project,
  .project--large,
  .project--wide,
  .project:nth-child(2),
  .project:nth-child(3),
  .project:nth-child(4) {
    grid-column: auto;
    margin-top: 0;
  }

  .project--large,
  .project--wide {
    grid-column: 1 / -1;
  }

  .footer {
    padding: 90px 20px 25px;
  }

  .social-link:hover {
    padding-right: 12px;
    padding-left: 12px;
  }
}

/* Mobile */

@media (max-width: 600px) {
  .section {
    padding: 65px 20px;
  }

  .footer {
    padding-bottom: 80px;
  }

  .header-contact {
    padding: 9px 11px;
  }

  .hero__title {
    font-size: clamp(65px, 22vw, 105px);
    line-height: 0.79;
  }

  .hero__eyebrow {
    margin-top: 24px;
  }

  .hero__image-wrapper {
    width: 100%;
  }

  .section-heading {
    grid-template-columns: 1fr;
  }

  .section-number {
    margin-bottom: 18px;
  }

  .portfolio-grid {
    display: flex;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    gap: 0;
  }

  .portfolio-grid::-webkit-scrollbar {
    display: none;
  }

  .project,
  .project--large,
  .project--wide {
    flex: 0 0 100%;
    scroll-snap-align: start;
    scroll-snap-stop: always;
    grid-column: auto;
  }

  .project__image,
  .project--large .project__image,
  .project--wide .project__image {
    aspect-ratio: 4 / 5;
  }

  .project__information {
    flex-direction: column;
    gap: 5px;
  }

  .header-socials {
    display: inline-block;
  }

  .social-link {
    grid-template-columns: 48px 1fr auto;
    gap: 14px;

    padding: 25px 0;
  }

  .carousel-dots {
    display: flex;
  }

  .social-link:hover {
    padding-right: 10px;
    padding-left: 10px;
  }

  .social-link__icon {
    width: 50px;
    height: 50px;
  }

  .social-link__icon svg,
  .social-link__icon img {
    width: 33px;
    height: 33px;
  }

  .social-link__arrow {
    font-size: 22px;
  }

  .footer__whatsapp {
    display: flex;
  }

  .footer__phone {
    display: none;
  }

  .footer__bottom p {
    font-weight: 600;
    font-size: 14px;
  }

  .footer__bottom {
    min-height: 8vh;
    flex-direction: column;
    align-items: flex-start;
    justify-content: flex-end;
    gap: 18px;
  }
}

/* Réduction des animations */

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

/* Lightbox */

.lightbox {
  position: fixed;
  inset: 0;
  z-index: 9999;

  display: flex;
  justify-content: center;
  align-items: center;

  background: rgba(0, 0, 0, 0.92);

  opacity: 0;
  visibility: hidden;

  transition: opacity 350ms ease, visibility 350ms ease;
}

.lightbox--open {
  opacity: 1;
  visibility: visible;
}

.lightbox__image {
  max-width: 92vw;
  max-height: 92vh;

  object-fit: contain;
}

.lightbox__close {
  position: absolute;
  top: 20px;
  right: 24px;

  background: none;
  border: none;

  color: #fff;
  font-size: 32px;
  cursor: pointer;
}