@import url('https://fonts.googleapis.com/css2?family=Oswald:wght@400;500;600;700&family=Syne:wght@400;500;600;700;800&family=Syne+Mono&display=swap');

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

:root {
  --fm: 'Syne', sans-serif;
  --fmo: 'Syne Mono', monospace;
}

html, body {
  width: 100%;
  height: 100%;
  background: #000;
  color: #fff;
  font-family: var(--fm);
  overflow: hidden;
}

/* ── HEADER ── */
#site-header {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 200;
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  padding: 28px 32px;
  pointer-events: none;
}

#site-title {
  font-family: 'Oswald', sans-serif;
  font-weight: 700;
  font-size: 18px;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: #fff;
  text-decoration: none;
  pointer-events: all;
  cursor: pointer;
  line-height: 1.2;
  position: fixed;
  top: 28px;
  left: 32px;
  z-index: 201;
}

/* Supprime l'état centré — titre toujours en haut à gauche */
#site-title.centered {
  top: 28px;
  left: 32px;
  transform: none;
  font-size: 18px;
  letter-spacing: .08em;
}

#site-title span {
  display: block;
  font-family: 'Syne', sans-serif;
  font-weight: 400;
  font-size: 10px;
  letter-spacing: .2em;
  opacity: .6;
  margin-top: 3px;
}

#menu-btn {
  background: none;
  border: none;
  cursor: pointer;
  pointer-events: all;
  padding: 0;
  position: fixed;
  top: 24px;
  right: 28px;
  z-index: 201;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  overflow: visible;
}

#menu-btn svg {
  width: 36px;
  height: 36px;
  transition: opacity 0.3s ease;
}

#menu-btn:hover svg { opacity: 0.6; }

/* ── MENU OVERLAY ── */
#menu-overlay {
  position: fixed;
  inset: 0;
  background: #000;
  z-index: 150;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity .5s ease;
  overflow: hidden;
}

#menu-overlay.active {
  opacity: 1;
  pointer-events: all;
}

/* Lignes verticales pleine hauteur */
.menu-grid-lines {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 0;
}

.menu-grid-lines::before {
  content: '';
  position: absolute;
  top: 0;
  bottom: 0;
  left: 25%;
  width: 1px;
  background: rgba(255,255,255,0.12);
}

.menu-grid-lines::after {
  content: '';
  position: absolute;
  top: 0;
  bottom: 0;
  right: 25%;
  width: 1px;
  background: rgba(255,255,255,0.12);
}

.menu-categories {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  position: relative;
  z-index: 2;
}

.menu-categories a {
  font-family: var(--fm);
  font-weight: 400;
  font-size: 11px;
  letter-spacing: .2em;
  text-transform: uppercase;
  color: #fff;
  text-decoration: none;
  transition: opacity .3s ease, transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  display: inline-block;
}

.menu-categories a:hover { opacity: .4; transform: scale(1.08); }

.menu-divider {
  width: 40px;
  height: 1px;
  background: rgba(255,255,255,0.25);
  margin: 8px 0;
}

.menu-bottom { display: none; }
.menu-contact { display: none; }

/* ── PROJECTS GRID ── */
#page-projects {
  position: fixed;
  inset: 0;
  background: #000;
  overflow-y: auto;
  overflow-x: hidden;
}

.projects-header {
  position: sticky;
  top: 0;
  z-index: 10;
  padding: 28px 32px;
  display: flex;
  align-items: center;
  background: rgba(0,0,0,.85);
  backdrop-filter: blur(10px);
}

.category-filters {
  display: flex;
  gap: 24px;
  margin-left: auto;
}

.filter-btn {
  font-family: var(--fmo);
  font-size: 10px;
  letter-spacing: .2em;
  text-transform: uppercase;
  color: rgba(255,255,255,.4);
  background: none;
  border: none;
  cursor: pointer;
  padding: 0;
  transition: color .3s ease;
  text-decoration: none;
}

.filter-btn.active,
.filter-btn:hover { color: #fff; }

.project-row { display: grid; width: 100%; }
.project-row.full { grid-template-columns: 1fr; }
.project-row.split { grid-template-columns: 1fr 1fr; }

.project-item {
  position: relative;
  overflow: hidden;
  cursor: pointer;
  height: 100vh;
  background: #0d0d0d;
}

.project-row.split .project-item { height: 56.25vw; }

.project-thumb-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .8s cubic-bezier(.16,1,.3,1);
}

.project-item:hover .project-thumb-img { transform: scale(1.04); }

.project-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0,0,0,.75) 0%, transparent 50%);
  opacity: 0;
  transition: opacity .4s ease;
  display: flex;
  align-items: flex-end;
  padding: 32px;
}

.project-item:hover .project-overlay { opacity: 1; }

.project-info { display: flex; flex-direction: column; gap: 4px; }

.project-client {
  font-family: var(--fm);
  font-weight: 700;
  font-size: clamp(18px, 2.5vw, 32px);
  letter-spacing: -.01em;
  line-height: 1;
}

.project-title {
  font-family: var(--fmo);
  font-size: 11px;
  letter-spacing: .15em;
  text-transform: uppercase;
  opacity: .6;
}

.empty-state {
  height: 60vh;
  display: flex;
  align-items: center;
  justify-content: center;
}

.empty-state p {
  font-family: var(--fmo);
  font-size: 11px;
  letter-spacing: .2em;
  text-transform: uppercase;
  opacity: .2;
}

#page-projects::-webkit-scrollbar { width: 2px; }
#page-projects::-webkit-scrollbar-thumb { background: rgba(255,255,255,.2); }

/* ── PROJECT DETAIL ── */
#page-detail {
  position: fixed;
  inset: 0;
  background: #000;
  overflow-y: auto;
  overflow-x: hidden;
  opacity: 0;
  pointer-events: none;
  transition: opacity .5s ease;
}

#page-detail.active {
  opacity: 1;
  pointer-events: all;
}

.detail-video-wrap {
  position: relative;
  width: 100%;
  height: 100vh;
  background: #000;
  overflow: hidden;
  margin-top: 0;
}

.detail-video-wrap iframe {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 100vw;
  height: 56.25vw;
  min-height: 100vh;
  min-width: 177.78vh;
  border: none;
}

.detail-meta {
  padding: 48px 32px 40px;
  display: flex;
  align-items: baseline;
  gap: 20px;
  border-bottom: 1px solid rgba(255,255,255,.08);
}

.detail-meta-client {
  font-family: var(--fm);
  font-weight: 700;
  font-size: clamp(22px, 3vw, 40px);
  letter-spacing: -.01em;
  line-height: 1;
}

.detail-meta-title {
  font-family: var(--fmo);
  font-size: 11px;
  letter-spacing: .2em;
  text-transform: uppercase;
  opacity: .45;
}

.detail-meta-category {
  margin-left: auto;
  font-family: var(--fmo);
  font-size: 10px;
  letter-spacing: .2em;
  text-transform: uppercase;
  opacity: .3;
}

.detail-stills {
  display: grid;
  grid-template-columns: 1fr 1fr;
  width: 100%;
}

.detail-still {
  position: relative;
  overflow: hidden;
  aspect-ratio: 16/9;
  background: #0d0d0d;
}

.detail-still img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform .8s cubic-bezier(.16,1,.3,1);
}

.detail-still:hover img { transform: scale(1.04); }

#page-detail::-webkit-scrollbar { width: 2px; }
#page-detail::-webkit-scrollbar-thumb { background: rgba(255,255,255,.2); }

/* ── BACK BUTTON ── */
#back-btn {
  position: fixed;
  bottom: 32px;
  left: 32px;
  z-index: 200;
  font-family: var(--fm);
  font-weight: 400;
  font-size: 10px;
  letter-spacing: .2em;
  text-transform: uppercase;
  color: rgba(255,255,255,.5);
  background: none;
  border: none;
  cursor: pointer;
  padding: 0;
  opacity: 0;
  pointer-events: none;
  transition: opacity .3s ease, color .3s ease;
  display: flex;
  align-items: center;
  gap: 8px;
  text-decoration: none;
}

#back-btn::before { content: '←'; font-size: 14px; }
#back-btn:hover { color: #fff; }
#back-btn.visible { opacity: 1; pointer-events: all; }

/* ── CONTACT ── */
.contact-body {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
  text-align: center;
}

.contact-location {
  font-family: var(--fm);
  font-size: 11px;
  letter-spacing: .25em;
  text-transform: uppercase;
  opacity: .4;
  margin-bottom: 12px;
}

.contact-email {
  font-family: var(--fm);
  font-weight: 400;
  font-size: clamp(18px, 2.5vw, 28px);
  letter-spacing: .02em;
  color: #fff;
  text-decoration: none;
  border-bottom: 1px solid rgba(255,255,255,.3);
  padding-bottom: 4px;
  transition: border-color .3s ease, opacity .3s ease;
}

.contact-email:hover { border-color: #fff; opacity: .7; }

.contact-phone {
  font-family: var(--fm);
  font-weight: 400;
  font-size: clamp(14px, 1.8vw, 20px);
  letter-spacing: .1em;
  opacity: .5;
}

.contact-socials {
  display: flex;
  gap: 20px;
  margin-top: 40px;
}

.contact-socials a {
  color: #fff;
  opacity: .35;
  transition: opacity .3s ease;
  display: flex;
  align-items: center;
  justify-content: center;
}

.contact-socials a:hover { opacity: 1; }
.contact-socials svg { width: 20px; height: 20px; fill: currentColor; }

/* ── SHOWREEL ── */
#showreel-container {
  position: fixed;
  inset: 0;
}

#showreel-container iframe {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 100vw;
  height: 56.25vw;
  min-height: 100vh;
  min-width: 177.78vh;
  border: none;
}

.showreel-placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 16px;
  background: #0a0a0a;
}

.showreel-placeholder p {
  font-family: var(--fmo);
  font-size: 11px;
  letter-spacing: .2em;
  text-transform: uppercase;
  opacity: .3;
}

.play-icon {
  width: 64px;
  height: 64px;
  border: 1px solid rgba(255,255,255,.15);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: .3;
}

.play-icon::after {
  content: '';
  border-left: 18px solid white;
  border-top: 11px solid transparent;
  border-bottom: 11px solid transparent;
  margin-left: 5px;
}

/* ── LIGHTBOX ── */
#lightbox {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.4s ease;
  background: #000;
}

#lightbox.active {
  opacity: 1;
  pointer-events: all;
}

#lb-backdrop { display: none; }

#lb-content {
  position: relative;
  z-index: 2;
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 60px 100px;
}

#lb-img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  display: block;
  transition: transform 0.5s cubic-bezier(0.16, 1, 0.3, 1);
  transform: scale(0.95);
  opacity: 0;
}

#lightbox.active #lb-img {
  transform: scale(1);
  opacity: 1;
}

#lb-prev, #lb-next {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 3;
  background: none;
  border: none;
  color: rgba(255,255,255,0.4);
  font-size: 20px;
  cursor: pointer;
  padding: 16px 24px;
  transition: color 0.2s ease;
  font-family: 'Syne Mono', monospace;
  letter-spacing: 0.1em;
}

#lb-prev { left: 16px; }
#lb-next { right: 16px; }
#lb-prev:hover, #lb-next:hover { color: #fff; }

#lb-close {
  position: absolute;
  top: 24px;
  right: 32px;
  z-index: 3;
  background: none;
  border: none;
  color: rgba(255,255,255,0.4);
  font-size: 10px;
  cursor: pointer;
  padding: 8px;
  transition: color 0.2s ease;
  font-family: var(--fm);
  font-weight: 400;
  letter-spacing: 0.2em;
  text-transform: uppercase;
}

#lb-close:hover { color: #fff; }

#lb-counter {
  position: absolute;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%);
  font-family: var(--fm);
  font-weight: 400;
  font-size: 10px;
  letter-spacing: 0.2em;
  color: rgba(255,255,255,0.3);
  text-transform: uppercase;
}

.detail-still { cursor: pointer; }
.detail-still:hover img { transform: scale(1.02); }

#page-detail.lb-blur, #page-projects.lb-blur { filter: none; }