:root {
  --bg: #0d1017;
  --fg: #fff;
  --muted: rgba(255, 255, 255, 0.4);
  --line: rgba(255, 255, 255, 0.1);
  --green: #53d35f;
  --green-soft: rgba(83, 211, 95, 0.2);
  --surface: rgba(217, 217, 217, 0.2);

  --col: 424px;
  --col-wide: 848px;
  --gutter: clamp(20px, 6.6vw, 100px);
  --px: 14px;
  --px-step: 18px;
}

* {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

html {
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font:
    400 14px/1.45 Inter,
    -apple-system,
    BlinkMacSystemFont,
    "Segoe UI",
    Roboto,
    sans-serif;
  -webkit-font-smoothing: antialiased;
}

img {
  display: block;
}

a {
  color: inherit;
}

.pixels {
  display: grid;
  grid-template-rows: repeat(7, var(--px-step));
  grid-auto-flow: column;
  grid-auto-columns: var(--px-step);
  justify-content: end;
  height: calc(var(--px-step) * 7 - (var(--px-step) - var(--px)));
  overflow: hidden;
}

.pixels i {
  width: var(--px);
  height: var(--px);
  border-radius: 3px;
  background: var(--green);
}

main {
  padding-bottom: 100px;
}

main > * {
  width: min(var(--col), 100% - var(--gutter) * 2);
  margin-inline: auto;
}

h1,
h2 {
  font-size: 24px;
  font-weight: 400;
  line-height: 1.25;
  margin-block: 0;
}

.hero {
  margin-top: 156px;
  text-align: center;
}

.hero__line {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
}

.hero__line em {
  font-style: italic;
}

.hero__avatar {
  width: 37px;
  height: 37px;
  border-radius: 50%;
  object-fit: cover;
}

.about {
  margin-top: 101px;
}

.about h2 {
  margin-bottom: 28px;
}

.wave {
  display: inline-block;
  margin-right: 4px;
  filter: grayscale(1) brightness(1.75);
  transform-origin: 70% 75%;
}

.about p {
  margin: 0 0 1.45em;
}

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

.about__agents {
  display: flex;
  align-items: flex-start;
  gap: 20px;
}

.about__agents span {
  flex: 1;
}

.agents-link {
  color: var(--green);
  text-decoration: underline;
  text-decoration-color: var(--green-soft);
  text-underline-offset: 4px;
}

.agents-link::after {
  content: "\00a0\2192";
  display: inline-block;
}

.agents-link:hover {
  text-decoration-color: var(--green);
}

.agents-link:hover::after {
  translate: 3px 0;
}

.badge {
  flex: none;
  rotate: 10deg;
}

.badge:hover {
  scale: 1.05;
}

.stack {
  position: relative;
  margin-top: 80px;
  height: 104px;
}

.stack canvas {
  position: absolute;
  bottom: 0;
  left: 0;
  width: calc(100% + var(--gutter));
  height: 152px;
  pointer-events: none;
}

.work {
  margin-top: 100px;
}

.filters {
  display: flex;
  flex-wrap: wrap;
  gap: 18px;
  margin: 20px 0 42px;
}

.filter {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 3px 12px;
  border: 0;
  border-radius: 16px;
  background: transparent;
  color: var(--muted);
  font: inherit;
  line-height: 17px;
  cursor: pointer;
}

.filter:hover {
  color: var(--green);
}

.filter[aria-pressed="true"] {
  background: var(--green-soft);
  color: var(--green);
}

.filter__x {
  width: 9px;
  height: 9px;
  display: none;
}

.filter[aria-pressed="true"] .filter__x {
  display: block;
}

.projects {
  margin: 0;
  padding: 0;
  list-style: none;
}

.projects li + li {
  margin-top: 18px;
}

.projects a {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  text-decoration: none;
}

.projects a:hover {
  color: var(--green);
}

.projects time {
  font-weight: 300;
  font-style: italic;
  white-space: nowrap;
}

.mail {
  position: fixed;
  bottom: calc(24px + env(safe-area-inset-bottom, 0px));
  left: 50%;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: center;
  width: auto;
  min-width: 31px;
  height: 31px;
  padding: 0 6px;
  transform: translateX(-50%);
  text-decoration: none;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 4px;
  background: var(--surface);
  backdrop-filter: blur(12px) saturate(180%);
  -webkit-backdrop-filter: blur(12px) saturate(180%);
  box-shadow:
    0 4px 16px rgba(0, 0, 0, 0.35),
    inset 0 1px 0 rgba(255, 255, 255, 0.22);
}

.mail:hover {
  background: var(--green-soft);
}

.mail img {
  flex: none;
}

.mail__label {
  max-width: 0;
  margin-left: 0;
  overflow: hidden;
  opacity: 0;
  white-space: nowrap;
}

.mail:hover .mail__label,
.mail:focus-visible .mail__label {
  max-width: 7rem;
  margin-left: 8px;
  opacity: 1;
}

.peek {
  position: fixed;
  top: 0;
  left: 0;
  z-index: 20;
  width: 220px;
  pointer-events: none;
}

.peek__card {
  aspect-ratio: 16 / 10;
  border-radius: 6px;
  background: var(--surface) center / cover no-repeat;
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.45);
  rotate: 10deg;
  scale: 0.9;
  opacity: 0;
}

.peek.is-on .peek__card {
  scale: 1;
  opacity: 1;
}

.mail::after {
  content: "";
  position: absolute;
  top: -2px;
  right: -3px;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--green);
}

.faq {
  margin-top: 100px;
}

.faq h2 {
  margin-bottom: 8px;
}

.faq details {
  border-top: 1px solid var(--line);
}

.faq details:last-child {
  border-bottom: 1px solid var(--line);
}

.faq summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 18px 0;
  list-style: none;
  cursor: pointer;
}

.faq summary::-webkit-details-marker {
  display: none;
}

.faq summary:hover {
  color: var(--green);
}

.faq summary::after {
  content: "+";
  flex: none;
  color: var(--muted);
  font-size: 17px;
  line-height: 1;
}

.faq details[open] summary::after {
  rotate: 45deg;
}

.faq p {
  margin: 0 0 22px;
  color: var(--muted);
}

.faq a {
  color: var(--green);
}

footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  width: min(1318px, 100% - var(--gutter) * 2);
  margin: 0 auto;
  padding: 27px 0 34px;
  border-top: 1px solid var(--line);
}

footer small {
  font-size: 14px;
  color: var(--muted);
}

footer nav {
  display: flex;
  align-items: center;
  gap: 20px;
}

footer nav a {
  opacity: 0.4;
}

footer nav a:hover {
  opacity: 1;
}

@media (max-width: 600px) {
  .hero {
    margin-top: 80px;
  }
  .about,
  .stack,
  .work,
  .faq {
    margin-top: 64px;
  }
  .back {
    margin-top: 48px;
  }
  .project__cover,
  .project__shots,
  .project__body {
    margin-top: 40px;
  }
  .lp__head {
    margin-top: 40px;
  }
  .lp section {
    margin-top: 56px;
  }
}

@keyframes flottaison {
  0%,
  100% {
    translate: 0 0;
  }
  50% {
    translate: 0 -6px;
  }
}

@keyframes coucou {
  0%,
  100% {
    rotate: 0deg;
  }
  25% {
    rotate: -16deg;
  }
  50% {
    rotate: 12deg;
  }
  75% {
    rotate: -7deg;
  }
}

@media (prefers-reduced-motion: no-preference) {
  .badge {
    animation: flottaison 3.6s ease-in-out infinite;
  }

  .about h2:hover .wave {
    animation: coucou 0.9s ease-in-out;
  }

  .mail__label {
    transition:
      max-width 0.35s ease-out,
      margin-left 0.35s ease-out,
      opacity 0.25s ease-out 0.05s;
  }

  .peek {
    transition: translate 0.28s ease-out;
  }

  .peek__card {
    transition:
      scale 0.3s ease-out,
      opacity 0.22s ease-out;
  }

  .filter,
  .projects a,
  .mail,
  footer nav a,
  .back,
  .project__step-title,
  .project__link,
  .agents-link,
  .agents-link::after,
  .badge,
  .faq summary,
  .faq summary::after {
    transition: 0.18s ease;
  }
}

.back {
  display: block;
  margin-top: 80px;
  color: var(--muted);
  text-decoration: none;
}

.back::before {
  content: "\2190\00a0";
}

.back:hover {
  color: var(--green);
}

.project__head {
  margin-top: 40px;
}

.project__line {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 14px 0 0;
}

.tag {
  padding: 3px 12px;
  border-radius: 16px;
  background: var(--green-soft);
  color: var(--green);
  line-height: 17px;
}

.project__line time {
  font-weight: 300;
  font-style: italic;
  color: var(--muted);
}

.project__cover,
.project__shots {
  width: min(var(--col-wide), 100% - var(--gutter) * 2);
  margin: 56px auto 0;
}

.project__shots {
  display: grid;
  gap: 18px;
}

.project__cover:empty,
.project__shots:empty {
  display: none;
}

.project__cover img,
.project__shots img {
  width: 100%;
  border-radius: 6px;
}

.project__shots iframe,
.project__shots video {
  display: block;
  width: 100%;
  max-width: calc(70vh * (var(--ratio)));
  aspect-ratio: var(--ratio);
  margin-inline: auto;
  border: 0;
  border-radius: 6px;
  background: var(--surface);
}

.project__shots figure {
  margin: 0;
}

.project__shots figcaption {
  margin-top: 10px;
  color: var(--muted);
}

.project__body {
  margin-top: 56px;
}

.project__intro {
  margin: 0 0 1.45em;
  font-size: 18px;
  line-height: 1.4;
}

.project__body p {
  margin: 0 0 1.45em;
}

.project__meta {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 8px 24px;
  margin: 42px 0 0;
  padding-top: 20px;
  border-top: 1px solid var(--line);
}

.project__meta dt {
  color: var(--muted);
}

.project__meta dd {
  margin: 0;
}

.project__link {
  display: inline-block;
  margin-top: 28px;
  color: var(--green);
  text-decoration: none;
}

.project__link::after {
  content: "\00a0\2192";
}

.project__link:hover {
  text-decoration: underline;
}

.project__nav {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  margin-top: 80px;
  padding-top: 27px;
  border-top: 1px solid var(--line);
}

.project__step {
  display: flex;
  flex-direction: column;
  gap: 4px;
  text-decoration: none;
}

.project__step--next {
  text-align: right;
}

.project__dir {
  color: var(--muted);
}

.project__step:hover .project__step-title {
  color: var(--green);
}

.lp__head {
  margin-top: 56px;
}

.lp h1 em {
  font-style: italic;
}

.lp__intro {
  margin: 28px 0 0;
  font-size: 18px;
  line-height: 1.4;
}

.lp section {
  margin-top: 80px;
}

.lp h2 {
  padding-bottom: 20px;
  border-bottom: 1px solid var(--line);
}

.lp__list {
  margin: 0;
}

.lp__list dt {
  margin-top: 28px;
}

.lp__list dd {
  margin: 6px 0 0;
  color: var(--muted);
}

.lp__cta p {
  margin: 20px 0 0;
  color: var(--muted);
}
