/* =========================================
   CRAIE STUDIO — styles.css
   ========================================= */

/* --- Reset & base --- */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

/* --- Accessible hidden (SEO + screen readers) --- */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

:root {
  --font: 'Outfit', sans-serif;
  --white: #ffffff;
  --black: #111111;
  --grey-light: #f5f5f3;
  --grey-text: #888884;
  --header-h: 64px;
  --transition-speed: 0.6s;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font);
  font-weight: 300;
  background: var(--white);
  color: var(--black);
  overflow-x: hidden;
}

a {
  text-decoration: none;
  color: inherit;
}

/* =========================================
   HEADER
   ========================================= */
.header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  height: var(--header-h);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 40px;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

.logo {
  font-family: var(--font);
  font-weight: 400;
  font-size: 15px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--black);
  transition: opacity 0.3s ease;
}

.logo:hover {
  opacity: 0.5;
}

.nav {
  display: flex;
  gap: 36px;
}

.nav-link {
  font-family: var(--font);
  font-weight: 300;
  font-size: 13px;
  letter-spacing: 0.10em;
  text-transform: uppercase;
  color: var(--black);
  position: relative;
  transition: opacity 0.3s ease;
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 0;
  height: 1px;
  background: var(--black);
  transition: width 0.3s ease;
}

.nav-link:hover {
  opacity: 1;
}

.nav-link:hover::after {
  width: 100%;
}

/* =========================================
   PROJETS — liste principale
   ========================================= */
.projets {
  padding-top: var(--header-h);
}

/* =========================================
   PROJET — bloc individuel
   ========================================= */
.projet {
  position: relative;
  width: 70%;
  margin: 0 auto 40px;
  height: 78vh;
  overflow: hidden;
  cursor: pointer;
}

/* Lien invisible qui couvre tout le bloc */
.projet-link {
  position: absolute;
  inset: 0;
  z-index: 10;
}

/* =========================================
   SLIDESHOW — photos en fond
   ========================================= */
.slideshow {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.slide {
  position: absolute;
  inset: 0;
  /* Noir & blanc par défaut */
  filter: grayscale(100%);
  opacity: 0;
  transform: scale(1);
  transition:
    opacity var(--transition-speed) ease,
    filter 0.5s ease,
    transform 0.6s ease;
}

.slide img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}

.slide.active {
  opacity: 1;
}

/* Couleur + zoom au hover */
.projet:hover .slide.active {
  filter: grayscale(0%);
  transform: scale(1.03);
}

/* Pause du slideshow gérée en JS via classe .paused sur .projet */

/* =========================================
   PROJET INFO — nom + lieu sous la photo
   ========================================= */
.projet-info {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 5;
  display: flex;
  align-items: baseline;
  gap: 20px;
  padding: 18px 40px;
  background: var(--white);
  border-top: 1px solid rgba(0,0,0,0.06);
}

.projet-nom {
  font-family: var(--font);
  font-weight: 400;
  font-size: 14px;
  letter-spacing: 0.06em;
  color: var(--black);
}

.projet-lieu {
  font-family: var(--font);
  font-weight: 300;
  font-size: 12px;
  letter-spacing: 0.10em;
  text-transform: uppercase;
  color: var(--grey-text);
}

/* =========================================
   FOOTER
   ========================================= */
.footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 28px 40px;
  border-top: 1px solid rgba(0,0,0,0.08);
}

.footer-copy {
  font-family: var(--font);
  font-weight: 300;
  font-size: 11px;
  letter-spacing: 0.08em;
  color: var(--grey-text);
  text-transform: uppercase;
}

.footer-ig {
  font-family: var(--font);
  font-weight: 300;
  font-size: 11px;
  letter-spacing: 0.10em;
  text-transform: uppercase;
  color: var(--black);
  position: relative;
  transition: opacity 0.3s ease;
}

.footer-ig::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 0;
  height: 1px;
  background: var(--black);
  transition: width 0.3s ease;
}

.footer-ig:hover::after {
  width: 100%;
}

/* =========================================
   PAGE STUDIO — hero + texte
   ========================================= */
.studio-hero {
  width: 100%;
  padding-top: var(--header-h);
}

.studio-hero-img {
  display: block;
  width: 70%;
  margin: 0 auto;
  height: 70vh;
  object-fit: cover;
  filter: grayscale(100%);
}

.studio-texte {
  max-width: 680px;
  margin: 0 auto;
  padding: 80px 40px;
}

.studio-texte p {
  font-family: var(--font);
  font-weight: 300;
  font-size: 15px;
  line-height: 1.9;
  color: #111;
  margin-bottom: 28px;
}

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

/* =========================================
   PAGES — studio, contact, projets détail
   ========================================= */
.page-content {
  padding-top: calc(var(--header-h) + 60px);
  padding-bottom: 80px;
  padding-left: 40px;
  padding-right: 40px;
  max-width: 900px;
  margin: 0 auto;
}

.page-title {
  font-family: var(--font);
  font-weight: 400;
  font-size: 28px;
  letter-spacing: 0.04em;
  color: var(--black);
  margin-bottom: 12px;
}

.page-text {
  font-family: var(--font);
  font-weight: 300;
  font-size: 15px;
  line-height: 1.8;
  color: var(--black);
}

.page-text p {
  margin-bottom: 18px;
}

.page-text a {
  border-bottom: 1px solid var(--black);
  transition: opacity 0.3s ease;
}

.page-text a:hover {
  opacity: 0.5;
}

.contact-details {
  margin-top: 32px;
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.contact-details strong {
  font-weight: 400;
  font-size: 12px;
  letter-spacing: 0.10em;
  text-transform: uppercase;
  color: var(--grey-text);
}

/* --- Projet détail --- */
.projet-header {
  display: flex;
  align-items: baseline;
  gap: 20px;
  margin-bottom: 24px;
}

.projet-meta {
  font-family: var(--font);
  font-weight: 300;
  font-size: 12px;
  letter-spacing: 0.10em;
  text-transform: uppercase;
  color: var(--grey-text);
}

.projet-galerie {
  margin-top: 48px;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.galerie-img {
  display: block;
  width: 100%;
  aspect-ratio: 3 / 2;
  object-fit: cover;
  object-position: center;
  background-color: var(--grey-light);
}

.back-link {
  display: inline-block;
  margin-top: 48px;
  font-family: var(--font);
  font-weight: 300;
  font-size: 13px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--grey-text);
  transition: color 0.3s ease;
}

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

/* =========================================
   RESPONSIVE — mobile
   ========================================= */
@media (max-width: 768px) {
  .header {
    padding: 0 20px;
  }

  .nav {
    gap: 20px;
  }

  .nav-link,
  .logo {
    font-size: 12px;
  }

  .projet {
    width: 90%;
    height: auto;
    aspect-ratio: 4 / 3;
    margin-bottom: 24px;
  }

  .projet-info {
    padding: 14px 20px;
    gap: 12px;
  }

  .footer {
    padding: 20px;
    flex-direction: column;
    gap: 10px;
    align-items: flex-start;
  }

  .page-content {
    padding-left: 20px;
    padding-right: 20px;
    padding-top: calc(var(--header-h) + 40px);
  }

  .page-title {
    font-size: 22px;
  }

  .projet-header {
    flex-direction: column;
    gap: 6px;
  }

  .studio-hero-img {
    width: 90%;
    height: 50vh;
  }

  .studio-texte {
    padding: 60px 20px;
  }
}
