/* ============ RESET & BASE ============ */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --black: #0a0a0a;
  --white: #ffffff;
  --font-serif: 'DM Serif Display', Georgia, serif;
  --font-sans: 'IBM Plex Sans', system-ui, sans-serif;
}

html { overflow-x: hidden; scrollbar-width: none; }
html::-webkit-scrollbar { display: none; }

/* ============ SCROLLBAR CUSTOM ============ */
.c-scrollbar {
  position: fixed;
  right: 18px;
  top: 12vh;
  height: 76vh;
  width: 1px;
  background: rgba(10,10,10,0.1);
  z-index: 50;
  cursor: pointer;
}
.c-scrollbar__thumb {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  width: 5px;
  background: var(--black);
  cursor: grab;
}
.c-scrollbar__thumb:hover,
.c-scrollbar__thumb.dragging { cursor: grabbing; }
.c-scrollbar:hover .c-scrollbar__thumb { background: #333; }

body {
  font-family: var(--font-sans);
  color: var(--black);
  background: var(--white);
  padding-bottom: 40vh;
}

.page-content {
  position: relative;
  z-index: 1;
  background: var(--white);
  height: 100vh;
  overflow: hidden;
}

img { display: block; width: 100%; height: 100%; object-fit: cover; }

/* Texte visible uniquement par les lecteurs d'écran */
.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;
}

/* ============ NAVIGATION ============ */
.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 48px;
  background: transparent;
  transition: background 0.3s;
}

.nav__logo { text-decoration: none; display: flex; align-items: center; }

.nav__logo-img { height: 44px; width: auto; display: block; object-fit: contain; }

.nav__links { display: flex; gap: 40px; list-style: none; }

.nav__link {
  font-family: var(--font-sans);
  font-size: 13px;
  font-weight: 400;
  letter-spacing: 0.08em;
  text-decoration: none;
  color: var(--black);
  text-transform: capitalize;
  position: relative;
  padding-bottom: 2px;
}

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

.nav__link:hover::after { width: 100%; }

/* ============ NAV BLANCHE, SANS OMBRE ============ */
.nav,
.nav.scrolled {
  background: #ffffff;
  -webkit-backdrop-filter: none;
  backdrop-filter: none;
  box-shadow: none;
  border-color: transparent;
}

/* ============ CATEGORIES ============ */
.categories {
  display: flex;
  width: 100%;
  height: 100vh;
  align-items: center;
  justify-content: center;              /* les 2 blocs centrés */
  gap: clamp(36px, 8vw, 150px);         /* écart entre les 2 catégories */
  padding-top: 52px; /* léger dégagement sous la nav (sans fond) */
}

.cat {
  position: relative;
  flex: 0 1 auto;                       /* largeur = celle de la photo */
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0;
  text-decoration: none;
  background: var(--white);
  /* Largeur commune photo + libellé : bornée par la demi-fenêtre (moins
     l'écart) ET par ce qui tient en hauteur */
  --cat-w: min(calc(50vw - 88px), calc((100vh - 178px) * 2 / 3));
}

/* Grande photo, proportions 2/3 conservées */
.cat__img {
  position: relative;
  width: var(--cat-w);
  aspect-ratio: 2 / 3;
  transition: transform 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.cat:hover .cat__img { transform: scale(1.03); }

/* Placeholder quand l'image est absente */
.cat__img::after {
  content: '';
  position: absolute;
  inset: 0;
  background: #c8c8c8;
}

.cat__img img { position: relative; z-index: 1; color: transparent; font-size: 0; }

/* Léger voile au survol seulement (plus d'overlay permanent) */
.cat__overlay {
  position: absolute;
  inset: 0;
  z-index: 2;
  background: transparent;
  transition: background 0.4s ease;
}

.cat:hover .cat__overlay { background: rgba(0,0,0,0.10); }

/* Libellé sous l'image : nom à gauche, appel à l'action à droite,
   collé à la photo (sans filet) */
.cat__title {
  width: var(--cat-w);
  margin: 0;
  margin-top: clamp(10px, 1.4vh, 16px);
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 20px;
}

.cat__name {
  font-family: var(--font-serif);
  font-size: clamp(24px, 2.6vw, 36px);
  font-weight: 400;
  letter-spacing: 0.01em;
  color: var(--black);
  line-height: 1;
}

.cat__cta {
  font-family: var(--font-sans);
  font-size: 12px;
  font-weight: 400;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: rgba(10, 10, 10, 0.4);
  white-space: nowrap;
  display: inline-flex;
  align-items: center;
  gap: 9px;
  transition: color 0.45s ease;
}

.cat:hover .cat__cta { color: var(--black); }

.cat__arrow {
  display: inline-block;
  transition: transform 0.45s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.cat:hover .cat__arrow { transform: translateX(6px); }

/* ============ FOOTER ============ */
.footer {
  position: fixed;
  bottom: 0; left: 0;
  width: 100%; z-index: 0;
  background: #0f0f0f;
  overflow: hidden;
  color: var(--black);
  padding: 0 0 60px;
  display: flex;
  flex-direction: column;
  height: 40vh;
}

.footer__main {
  display: inline-block;
  align-self: flex-start;
  margin-right: -3.5vw;
}

.footer__logo {
  font-family: var(--font-serif);
  font-size: 11.5vw;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  line-height: 0.82;
  margin: 0; padding: 0;
  color: var(--black);
  display: block;
  -webkit-font-smoothing: antialiased;
}

.footer__phone {
  font-family: var(--font-sans);
  font-size: 20px;
  font-weight: 300;
  letter-spacing: 0.28em;
  color: var(--black);
  text-align: right;
  margin-top: 4px;
  display: block;
  text-decoration: none;
}

.footer__bottom {
  margin-top: auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0 48px 0;
}

.footer__socials { display: flex; gap: 36px; align-items: center; }

.footer__social-link {
  font-family: var(--font-sans);
  font-size: 13px;
  letter-spacing: 0.1em;
  text-decoration: none;
  color: #888;
  text-transform: capitalize;
}

.footer__nav { display: flex; flex-wrap: wrap; gap: 22px; align-items: center; }

.footer__nav-link {
  font-family: var(--font-sans);
  font-size: 13px;
  font-weight: 300;
  letter-spacing: 0.1em;
  color: var(--black);
  text-decoration: none;
  text-transform: uppercase;
  transition: opacity 0.2s;
}

/* --- Footer : fond photo noir & blanc --- */
.footer::before {
  content: "";
  position: absolute;
  inset: 0;
  background: url(../assets/cat-mariages.jpg) center 30% / cover no-repeat;
  filter: grayscale(1) contrast(1.06) brightness(0.82);
  z-index: 0;
}
.footer::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(10,10,10,0.34) 0%, rgba(10,10,10,0.66) 55%, rgba(10,10,10,0.8) 100%);
  z-index: 0;
}
.footer__main,
.footer__bottom { position: relative; z-index: 1; }
.footer__logo { color: #fff; }
.footer__phone { color: rgba(255,255,255,0.9); }
.footer__nav-link { color: #fff; font-weight: 400; text-transform: capitalize; }
.footer__social-link { color: rgba(255,255,255,0.6); }

/* ============ RESPONSIVE ============ */
@media (max-width: 768px) {
  .nav { padding: 16px 24px; }
  .nav__links { gap: 20px; }
  .nav__link { font-size: 12px; }

  /* Mobile : les 2 catégories empilées, en grand (une par écran ou presque) */
  /* Le fond blanc remplit tout l'écran : le footer fixe reste caché
     derrière et ne se découvre qu'en défilant vers le bas. */
  .page-content {
    height: auto;
    min-height: 100vh;
    min-height: 100dvh;
    overflow: visible;
  }
  .categories {
    flex-direction: column;
    height: auto;
    min-height: 0;
    align-items: stretch;
    justify-content: flex-start;
    padding: 96px 20px 72px;      /* dégage la nav fixe */
    gap: 56px;
  }
  .cat {
    flex: none;
    width: 100%;
    padding: 0;
    --cat-w: 100%;
  }
  .cat:not(:last-child) { padding-bottom: 0; }
  .cat__img { width: 100%; height: auto; aspect-ratio: 4 / 5; overflow: hidden; }
  .cat:first-child .cat__img img { object-position: 50% 30%; }
  .cat:hover .cat__img { transform: none; }     /* pas de zoom au toucher */
  .cat__title { margin-top: 14px; align-items: center; }
  .cat__name { font-size: clamp(32px, 9vw, 40px); }
  /* « Voir la galerie → » affiché en entier, même style que sur desktop */

  .footer__main { padding-top: 24px; }
  .footer__bottom { flex-direction: column; align-items: center; text-align: center; gap: 20px; padding: 24px 24px 0; }
  .footer__phone { text-align: left; }
}


/* Nav compacte sur petit écran : logo au-dessus, liens en dessous */
@media (max-width: 480px) {
  .nav { flex-direction: column; gap: 10px; padding: 12px 16px; }
  .nav__logo-img { height: 36px; }
  .nav__links { gap: 14px; }
  .nav__link { font-size: 11px; letter-spacing: 0.04em; }
}

/* ============ HEADER ESCAMOTABLE — caché pendant le scroll, revient à l'arrêt ============ */
.nav {
  transition: transform 0.35s ease, opacity 0.35s ease, background 0.3s;
}
.nav--hidden {
  transform: translateY(-100%);
  opacity: 0;
  pointer-events: none;
}
