/* ════════════════════════════════════════════════════════
   ROMAIN MAULAVÉ — Master Homepage
   Digital equivalent of a black matte envelope in gold foil.
   ════════════════════════════════════════════════════════ */

/* ── Design tokens ──────────────────────────────────────── */
:root {
  --black:     #050505;
  --white:     #F5F1EA;
  --gold:      #C8A86B;
  --gold-dim:  rgba(200, 168, 107, 0.12);
  --muted:     rgba(245, 241, 234, 0.38);
  --med-blue:  #264B6A;
  --sand:      #D6C1A2;

  --display:   'Bebas Neue', Impact, 'Arial Narrow', sans-serif;
  --sans:      'Montserrat', Helvetica, Arial, sans-serif;

  --expo:      cubic-bezier(0.76, 0, 0.24, 1);
  --out:       cubic-bezier(0.25, 0.46, 0.45, 0.94);

  --gutter:    clamp(24px, 5vw, 72px);
}

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

html {
  font-size: 16px;
  scroll-behavior: smooth;
}

body {
  background: var(--black);
  color: var(--white);
  font-family: var(--sans);
  font-weight: 300;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

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


/* ── Scroll reveal ──────────────────────────────────────── */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 1s var(--out), transform 1s var(--out);
}

.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

.d1 { transition-delay: 0.14s; }
.d2 { transition-delay: 0.3s;  }
.d3 { transition-delay: 0.48s; }


/* ════════════════════════════════════════════════════════
   01. FILM GRAIN — optimisé (réduit sur mobile)
   ════════════════════════════════════════════════════════ */
.grain {
  position: fixed;
  inset: -50%;
  width: 200%; height: 200%;
  z-index: 9997;
  pointer-events: none;
  opacity: 0.04;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='300' height='300'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.78' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='300' height='300' filter='url(%23n)'/%3E%3C/svg%3E");
  /* OPTIMISATION: animation réduite à 1s sur mobile via media query */
  animation: grain-shift 0.5s steps(1) infinite;
}

/* Désactiver le grain animé sur mobile — gain GPU significatif */
@media (hover: none) {
  .grain {
    animation: none;
    opacity: 0.03;
  }
}

@keyframes grain-shift {
  0%   { transform: translate( 0%,  0%) }
  25%  { transform: translate(-4%, -3%) }
  50%  { transform: translate( 3%,  4%) }
  75%  { transform: translate(-2%,  3%) }
  100% { transform: translate( 4%, -3%) }
}


/* ════════════════════════════════════════════════════════
   02. LOADER — durée réduite sur mobile
   ════════════════════════════════════════════════════════ */
.loader {
  position: fixed;
  inset: 0;
  background: var(--black);
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: opacity 0.65s var(--out), visibility 0.65s;
}

.loader.is-hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.loader__monogram {
  font-family: var(--display);
  font-size: clamp(48px, 8vw, 76px);
  letter-spacing: 0.26em;
  color: var(--gold);
  animation: monogram-in 1.65s var(--out) forwards;
}

/* OPTIMISATION: loader plus court sur mobile */
@media (hover: none) {
  .loader__monogram {
    animation-duration: 0.9s;
  }
}

@keyframes monogram-in {
  0%   { opacity: 0; letter-spacing: 0.52em; }
  28%  { opacity: 1; letter-spacing: 0.26em; }
  72%  { opacity: 1; letter-spacing: 0.26em; }
  100% { opacity: 0; letter-spacing: 0.08em; }
}


/* ════════════════════════════════════════════════════════
   03. CUSTOM CURSOR — desktop uniquement
   ════════════════════════════════════════════════════════ */
@media (hover: none) {
  .cursor-dot, .cursor-ring { display: none; }
}


/* ════════════════════════════════════════════════════════
   SECTION 1 — HERO
   ════════════════════════════════════════════════════════ */
.hero {
  position: relative;
  height: 100vh;
  min-height: 640px;
  display: flex;
  flex-direction: column;
  align-items: center;
  background: var(--black);
  overflow: hidden;
}

/* ── Identity ───────────────────────────────────────────── */
.hero__identity {
  position: relative;
  z-index: 10;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: clamp(44px, 7vh, 84px) var(--gutter) clamp(20px, 3vh, 36px);
  flex-shrink: 0;
  animation: identity-reveal 1s var(--expo) 1.4s both;
}

@keyframes identity-reveal {
  from { opacity: 0; transform: translateY(18px); }
  to   { opacity: 1; transform: translateY(0); }
}

.hero__name {
  font-family: var(--display);
  font-size: clamp(52px, 8vw, 124px);
  line-height: 0.88;
  text-align: center;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--white);
}

.hero__name span { display: block; }
.hero__name em   { display: block; font-style: normal; color: var(--gold); }

.hero__tag {
  margin-top: clamp(12px, 2vh, 22px);
  font-size: clamp(7.5px, 0.85vw, 10px);
  letter-spacing: 0.42em;
  text-transform: uppercase;
  color: var(--gold);
  font-weight: 300;
  display: flex;
  align-items: center;
  gap: 16px;
}

.hero__tag::before,
.hero__tag::after {
  content: '';
  display: block;
  width: 24px;
  height: 1px;
  background: var(--gold);
  flex-shrink: 0;
}

/* ── Two worlds ─────────────────────────────────────────── */
.worlds {
  position: relative;
  width: 100%;
  flex: 1;
  display: flex;
  overflow: hidden;
  min-height: 0;
}

.world {
  position: relative;
  flex: 1;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 0 var(--gutter) clamp(28px, 5.5vh, 56px);
  text-decoration: none;
  color: var(--white);
  transition: flex 0.9s var(--expo);
  animation: world-reveal 0.85s var(--out) 1.55s both;
}

.world--riviera { animation-delay: 1.72s; }

@keyframes world-reveal {
  from { opacity: 0; }
  to   { opacity: 1; }
}

.worlds:has(.world--fashion:hover) .world--fashion { flex: 1.5; }
.worlds:has(.world--fashion:hover) .world--riviera { flex: 0.5; }
.worlds:has(.world--riviera:hover) .world--riviera { flex: 1.5; }
.worlds:has(.world--riviera:hover) .world--fashion { flex: 0.5; }

.world__bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  transition: transform 0.65s var(--out), filter 0.65s ease;
  transform: scale(1);
}

.world--fashion .world__bg {
  background-image: url('../fashion/images/USA00093.jpg');
  filter: brightness(0.62) saturate(0.84);
}

.world--riviera .world__bg {
  background-image: url('../riviera/images/USA02706.jpeg');
  filter: brightness(0.68) saturate(1.0);
}

.world--fashion:hover .world__bg {
  transform: scale(1.05);
  filter: brightness(0.78) saturate(0.90);
}

.world--riviera:hover .world__bg {
  transform: scale(1.05);
  filter: brightness(0.82) saturate(1.08);
}

.world__vignette {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to top,
    rgba(0, 0, 0, 0.78) 0%,
    rgba(0, 0, 0, 0.16) 45%,
    rgba(0, 0, 0, 0.0)  100%
  );
  z-index: 1;
}

.world__content {
  position: relative;
  z-index: 2;
  transition: transform 0.7s var(--expo);
}

.world:hover .world__content { transform: translateY(-10px); }

.world__index {
  display: block;
  font-family: var(--sans);
  font-size: 8.5px;
  font-weight: 400;
  letter-spacing: 0.46em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 8px;
}

.world__title {
  font-family: var(--display);
  font-size: clamp(36px, 4.5vw, 68px);
  line-height: 0.88;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--white);
  margin-bottom: 10px;
}

.world__location {
  font-family: var(--sans);
  font-size: clamp(8px, 0.82vw, 10px);
  font-weight: 300;
  letter-spacing: 0.36em;
  text-transform: uppercase;
  color: rgba(245, 241, 234, 0.55);
}

.world__cta {
  position: absolute;
  bottom: clamp(28px, 5.5vh, 56px);
  right: var(--gutter);
  font-family: var(--sans);
  font-size: 9px;
  letter-spacing: 0.36em;
  text-transform: uppercase;
  color: var(--gold);
  opacity: 0;
  transition: opacity 0.4s ease, transform 0.4s var(--out);
  transform: translateX(-6px);
}

.world:hover .world__cta {
  opacity: 1;
  transform: translateX(0);
}

.worlds__sep {
  width: 1px;
  height: 100%;
  background: linear-gradient(
    to bottom,
    transparent 0%,
    rgba(200, 168, 107, 0.28) 18%,
    rgba(200, 168, 107, 0.6) 50%,
    rgba(200, 168, 107, 0.28) 82%,
    transparent 100%
  );
  flex-shrink: 0;
  z-index: 10;
  animation: sep-reveal 1s var(--out) 1.9s both;
}

@keyframes sep-reveal {
  from { opacity: 0; }
  to   { opacity: 1; }
}

.hero__scroll {
  position: absolute;
  bottom: 18px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 20;
  font-size: 7px;
  letter-spacing: 0.44em;
  text-transform: uppercase;
  color: rgba(245, 241, 234, 0.2);
  font-weight: 400;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  animation: identity-reveal 1s var(--expo) 2.1s both;
}

.hero__scroll::before {
  content: '';
  display: block;
  width: 1px;
  height: 34px;
  background: linear-gradient(to bottom, rgba(200, 168, 107, 0.4), transparent);
  animation: scroll-pulse 2.4s ease 2.4s infinite;
}

@keyframes scroll-pulse {
  0%, 100% { opacity: 0.35; transform: scaleY(0.7); transform-origin: top; }
  55%      { opacity: 1;    transform: scaleY(1);   transform-origin: top; }
}


/* ════════════════════════════════════════════════════════
   SECTION 2 — MANIFESTO
   ════════════════════════════════════════════════════════ */
.manifesto {
  padding: clamp(128px, 20vh, 220px) var(--gutter);
  background: var(--black);
  display: flex;
  justify-content: center;
  align-items: center;
}

.manifesto__inner {
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: clamp(20px, 3.5vh, 44px);
}

.manifesto__line {
  font-family: var(--display);
  font-size: clamp(38px, 7.5vw, 112px);
  line-height: 0.88;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--white);
}

.manifesto__line--accent {
  color: var(--gold);
  font-size: clamp(24px, 4.6vw, 70px);
}

.manifesto__rule {
  width: 52px;
  height: 1px;
  background: var(--gold);
  opacity: 0.4;
}


/* ════════════════════════════════════════════════════════
   SECTION 3 & 4 — CAMPAIGN
   OPTIMISATION: images campaign chargées en lazy via JS
   ════════════════════════════════════════════════════════ */
.campaign {
  position: relative;
  height: 92vh;
  min-height: 520px;
  overflow: hidden;
}

.campaign__bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center 40%;
  background-image: url('../riviera/images/USA02707.jpeg');
  transform: scale(1.06);
  transition: transform 1.4s var(--out);
  filter: brightness(0.92) contrast(1.02) saturate(0.95) sepia(0.03);
}

.campaign.is-visible .campaign__bg {
  transform: scale(1.01);
}

.campaign__grade {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to bottom,
    rgba(5, 5, 5, 0.04)  0%,
    rgba(5, 5, 5, 0.01)  38%,
    rgba(5, 5, 5, 0.48)  100%
  );
  z-index: 1;
}

.campaign__text {
  position: absolute;
  bottom: clamp(44px, 8vh, 100px);
  left: var(--gutter);
  z-index: 2;
}

.campaign__eyebrow {
  display: block;
  font-family: var(--sans);
  font-size: 12px;
  font-weight: 400;
  letter-spacing: 0.5em;
  text-transform: uppercase;
  color: var(--gold);
  opacity: 0.75;
  margin-bottom: 20px;
}

.campaign__headline {
  display: block;
  font-family: var(--display);
  font-size: clamp(36px, 5.5vw, 80px);
  line-height: 0.9;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--white);
}

.campaign__subline {
  display: block;
  font-family: var(--sans);
  font-style: italic;
  font-weight: 300;
  font-size: clamp(18px, 2.6vw, 38px);
  line-height: 1;
  color: rgba(245, 241, 234, 0.52);
  letter-spacing: 0.14em;
  margin-top: 10px;
}

.campaign__bg--newyork {
  background-position: center 30%;
  background-image: url('../riviera/images/USA05801.jpg');
}


/* ════════════════════════════════════════════════════════
   SECTION 5 — FOOTER
   ════════════════════════════════════════════════════════ */
.footer {
  position: relative;
  background: #050505;
  padding: clamp(72px, 12vh, 120px) var(--gutter) clamp(52px, 8vh, 88px);
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: clamp(36px, 5.5vh, 56px);
  border-top: 1px solid rgba(200, 168, 107, 0.1);
  overflow: hidden;
}

.footer::before {
  content: '';
  position: absolute;
  inset: -50%;
  width: 200%; height: 200%;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='300' height='300'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.78' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='300' height='300' filter='url(%23n)'/%3E%3C/svg%3E");
  opacity: 0.022;
  pointer-events: none;
}

.footer__upper {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: clamp(8px, 1vh, 12px);
}

.footer__name {
  font-family: var(--display);
  font-size: clamp(28px, 3.2vw, 46px);
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--white);
}

.footer__tagline {
  font-family: var(--sans);
  font-size: 11px;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--gold);
  opacity: 0.85;
  line-height: 2.1;
  font-weight: 300;
}

.footer__cta {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  margin-top: clamp(10px, 1.5vh, 16px);
  margin-bottom: clamp(10px, 1.5vh, 16px);
}

.footer__contact-link {
  font-family: var(--sans);
  font-size: 11px;
  letter-spacing: 0.18em;
  color: rgba(245, 241, 234, 0.55);
  font-weight: 300;
}

.footer__contact-link:hover {
  text-decoration: underline;
  text-decoration-color: rgba(245, 241, 234, 0.35);
  text-underline-offset: 4px;
  text-decoration-thickness: 1px;
}

.footer__whatsapp {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: var(--sans);
  font-size: 11px;
  font-weight: 300;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: rgba(245, 241, 234, 0.55);
  text-decoration: none;
}

.footer__whatsapp:hover {
  text-decoration: underline;
  text-decoration-color: rgba(245, 241, 234, 0.35);
  text-underline-offset: 4px;
  text-decoration-thickness: 1px;
}

.footer__territory {
  font-family: var(--sans);
  font-size: 11px;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: rgba(245, 241, 234, 0.55);
  font-weight: 300;
}

.footer__copy {
  font-family: var(--sans);
  font-size: 10px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: rgba(245, 241, 234, 0.28);
  font-weight: 300;
}


/* ════════════════════════════════════════════════════════
   MOBILE — max-width: 768px uniquement. Desktop intact.
   ════════════════════════════════════════════════════════ */
@media (max-width: 768px) {

  /* ── Hero mobile dédié — caché sur desktop ──────────── */
  .hero__mobile { display: flex; }

  /* ── Masquer les éléments desktop dans le hero ───────── */
  .hero__identity { display: none; }
  .worlds         { display: none; }
  .worlds__sep    { display: none; }

  /* ── Hero — fond noir pleine hauteur ────────────────── */
  .hero {
    height: 100svh;
    min-height: 600px;
    flex-direction: column;
    justify-content: space-between;
    align-items: stretch;
    background: var(--black);
    padding: 0;
  }

  /* ── Hero mobile layout ─────────────────────────────── */
  .hero__mobile {
    flex-direction: column;
    justify-content: space-between;
    height: 100%;
    padding: 0;
  }

  /* NAV — RM + Book */
  .hero__mobile-nav-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 18px 24px;
    border-bottom: 1px solid rgba(200, 168, 107, 0.1);
  }

  /* Nom principal — plein écran */
  .hero__mobile-name {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    padding: 0 24px;
  }

  .hero__mobile-name span {
    display: block;
    font-family: var(--display);
    font-size: clamp(58px, 16vw, 82px);
    line-height: 0.87;
    letter-spacing: 0.03em;
    text-transform: uppercase;
    color: var(--white);
  }

  .hero__mobile-name em {
    display: block;
    font-family: var(--display);
    font-style: normal;
    font-size: clamp(58px, 16vw, 82px);
    line-height: 0.87;
    letter-spacing: 0.03em;
    text-transform: uppercase;
    color: var(--gold);
    margin-top: 6px;
  }

  .hero__mobile-tag {
    padding: 0 24px;
    font-size: 10px;
    letter-spacing: 0.36em;
    text-transform: uppercase;
    color: rgba(245, 241, 234, 0.38);
    font-weight: 300;
    margin-top: 18px;
    text-align: center;
  }

  /* CTAs — Book + Fashion/Riviera */
  .hero__mobile-ctas {
    padding: 24px;
    display: flex;
    flex-direction: column;
    gap: 10px;
  }

  .hero__mobile-book {
    display: block;
    background: var(--gold);
    color: #050505;
    text-align: center;
    padding: 17px;
    font-family: var(--sans);
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.35em;
    text-transform: uppercase;
    border-radius: 2px;
    text-decoration: none;
  }

  .hero__mobile-nav {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
  }

  .hero__mobile-card {
    position: relative;
    height: 224px;
    border-radius: 3px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    padding: 14px 12px;
    text-decoration: none;
    color: #F5F1EA;
  }

  .hero__mobile-card-bg {
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center;
  }

  .hero__mobile-card-bg--fashion {
    background-image: url('../fashion/images/USA00093.jpg');
    filter: brightness(0.55) saturate(0.85);
  }

  .hero__mobile-card-bg--riviera {
    background-image: url('../riviera/images/USA02706.jpeg');
    filter: brightness(0.55) saturate(1.0);
  }

  .hero__mobile-card-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(0,0,0,0.75) 0%, transparent 60%);
  }

  .hero__mobile-card-content {
    position: relative;
    z-index: 2;
    display: flex;
    flex-direction: column;
    gap: 2px;
  }

  .hero__mobile-card-num {
    font-size: 8px;
    letter-spacing: 0.4em;
    color: #C8A86B;
    font-weight: 400;
  }

  .hero__mobile-card-title {
    font-family: 'Bebas Neue', Impact, sans-serif;
    font-size: 30px;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    line-height: 1;
  }

  .hero__mobile-card-sub {
    font-size: 9px;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: rgba(245,241,234,0.5);
  }

  .hero__mobile-card-arrow {
    position: absolute;
    top: 12px;
    right: 12px;
    font-size: 14px;
    color: #C8A86B;
    z-index: 2;
  }

  /* ── Manifesto — compact ────────────────────────────── */
  .manifesto {
    display: flex;
    padding: 40px 24px;
  }

  .manifesto__line      { font-size: clamp(34px, 9vw, 54px); }
  .manifesto__line--accent { font-size: clamp(22px, 6vw, 34px); }

  /* ── Campaign — hauteur réduite ─────────────────────── */
  .campaign { height: 56vh; min-height: 300px; }
  .campaign__bg { background-attachment: scroll; }
  .campaign__headline { font-size: clamp(28px, 8vw, 48px); }

  /* ── Footer ─────────────────────────────────────────── */
  .footer { padding: 56px 24px 44px; gap: 28px; }
  .footer__name { font-size: clamp(24px, 6vw, 34px); }
  .footer__tagline { font-size: 10px; line-height: 2; }
  .footer__cta { margin-top: 10px; margin-bottom: 10px; gap: 8px; }
}

/* Desktop — hero mobile caché */
@media (min-width: 769px) {
  .hero__mobile { display: none; }
}

/* Très petits écrans */
@media (max-width: 380px) {
  .hero__mobile-name span,
  .hero__mobile-name em { font-size: 48px; }
}
