/* ============================================================
   L'ORÉE DORÉE & MARINA — Navigation Luxury
   ============================================================ */

/* --- Header Base --------------------------------------------- */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 900;
  height: 88px;
  display: flex;
  align-items: center;
  padding: 0 clamp(20px,4vw,56px);
  gap: 24px;
  transition: background .4s ease, box-shadow .4s ease, height .3s ease;
  background: transparent;
}

/* Version solide pour les pages blanches (ex: réservation) */
.site-header.header-light {
  background: rgba(250,248,244,.98);
  box-shadow: 0 1px 0 rgba(26,26,24,.08);
}

/* Scrolled state */
.site-header.is-scrolled {
  background: rgba(250,248,244,.97);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  box-shadow: 0 1px 0 rgba(26,26,24,.08), 0 4px 24px rgba(26,26,24,.06);
  height: 72px;
}

/* Marina theme (blue tint on scroll) */
body.marina-theme .site-header.is-scrolled {
  background: rgba(245,250,254,.97);
}

/* --- Logo / Brand -------------------------------------------- */
.brand {
  font-family: 'Cinzel', serif;
  font-size: clamp(.82rem,1.3vw,.94rem);
  font-weight: 700;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: #fff;
  white-space: nowrap;
  line-height: 1.2;
  transition: color .3s ease;
  flex-shrink: 0;
  text-decoration: none;
  display: flex;
  flex-direction: column;
  gap: 3px;
}
.brand span {
  display: block;
  font-size: .58rem;
  letter-spacing: .24em;
  color: #c9a84c;
  font-weight: 600;
}
.site-header.is-scrolled .brand,
.site-header.header-light .brand { 
  color: #1a1a18; 
}

/* --- Desktop Nav -------------------------------------------- */
.site-nav {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: clamp(4px,1.6vw,26px);
}
.nav-link {
  font-family: 'Manrope', sans-serif;
  font-size: .7rem;
  font-weight: 700;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: rgba(255,255,255,.85);
  padding: 6px 2px;
  position: relative;
  cursor: pointer;
  transition: color .25s ease;
  background: none;
  border: none;
  text-decoration: none;
  white-space: nowrap;
}
.nav-link::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 1.5px;
  background: #c9a84c;
  transition: width .3s ease;
}
.nav-link:hover::after,
.nav-link.active::after { width: 100%; }
.nav-link:hover,
.nav-link.active { color: #fff; }

.site-header.is-scrolled .nav-link,
.site-header.header-light .nav-link { 
  color: rgba(26,26,24,.7); 
}
.site-header.is-scrolled .nav-link:hover,
.site-header.is-scrolled .nav-link.active { color: #1a1a18; }

/* --- Dropdown ------------------------------------------------ */
.nav-item { position: relative; }
.dropdown-menu {
  position: absolute;
  top: calc(100% + 18px);
  left: 50%;
  transform: translateX(-50%) translateY(8px);
  background: #fff;
  border: 1px solid rgba(26,26,24,.08);
  border-radius: 4px;
  box-shadow: 0 20px 60px rgba(26,26,24,.14);
  min-width: 220px;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity .25s ease, transform .25s ease, visibility .25s;
  padding: 8px 0;
  list-style: none;
}
.nav-item.is-open .dropdown-menu {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: translateX(-50%) translateY(0);
}
.dropdown-menu li a {
  display: block;
  padding: 10px 20px;
  font-size: .76rem;
  font-weight: 700;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: #2c2c2a;
  transition: background .2s ease, color .2s ease, padding-left .2s ease;
  text-decoration: none;
}
.dropdown-menu li a:hover {
  background: rgba(201,168,76,.07);
  color: #c9a84c;
  padding-left: 26px;
}
.dropdown-menu li a.active { color: #c9a84c; }
.marina-link { color: #0d6b95 !important; }
.marina-link:hover { color: #c9a84c !important; }

/* --- CTA Button ---------------------------------------------- */
.header-cta {
  flex-shrink: 0;
  padding: 10px 22px;
  border-radius: 999px;
  font-family: 'Manrope', sans-serif;
  font-size: .7rem;
  font-weight: 700;
  letter-spacing: .14em;
  text-transform: uppercase;
  background: #c9a84c;
  color: #1a1a18;
  border: 1.5px solid #c9a84c;
  transition: all .3s ease;
  text-decoration: none;
  white-space: nowrap;
}
.header-cta:hover {
  background: #b8942f;
  border-color: #b8942f;
  transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(201,168,76,.35);
}

/* --- Burger Button ------------------------------------------- */
.burger {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 6px;
  width: 38px;
  height: 38px;
  cursor: pointer;
  background: none;
  border: none;
  padding: 4px;
  margin-left: auto;
  flex-shrink: 0;
  filter: drop-shadow(0 0 2px rgba(0,0,0,.45));
}
.burger span {
  display: block;
  height: 1.5px;
  background: #fff;
  border-radius: 2px;
  transition: all .35s cubic-bezier(.25,.46,.45,.94);
  transform-origin: center;
}
.burger span:nth-child(1) { width: 28px; }
.burger span:nth-child(2) { width: 20px; }
.burger span:nth-child(3) { width: 24px; }
.site-header.is-scrolled .burger span,
.site-header.header-light .burger span {
  background: #1a1a18;
}
.site-header.is-scrolled .burger,
.site-header.header-light .burger {
  filter: none;
}
.burger.active span:nth-child(1) { transform: rotate(45deg) translate(5px,5px); width: 24px; }
.burger.active span:nth-child(2) { opacity: 0; transform: scaleX(0); }
.burger.active span:nth-child(3) { transform: rotate(-45deg) translate(5px,-5px); width: 24px; }

/* --- Header Search ------------------------------------------ */
.header-search {
  position: relative;
  margin: 0 20px;
  flex: 1;
  max-width: 250px;
}
#site-search {
  width: 100%;
  padding: 8px 15px;
  border-radius: 20px;
  border: 1px solid rgba(255,255,255,0.2);
  background: rgba(255,255,255,0.1);
  color: #fff;
  font-size: 0.85rem;
  transition: all 0.3s ease;
}
#site-search:focus {
  outline: none;
  border-color: var(--gold);
  background: rgba(255,255,255,0.15);
}

/* Ajustements pour header clair ou scrollé */
.site-header.is-scrolled #site-search,
.site-header.header-light #site-search {
  border: 1px solid rgba(26,26,24,0.15);
  background: rgba(26,26,24,0.05);
  color: #1a1a18;
}

#search-suggestions {
  position: absolute;
  top: calc(100% + 12px);
  left: 0;
  right: 0;
  background: white;
  border-radius: 10px;
  box-shadow: 0 20px 60px rgba(26,26,24,0.18);
  z-index: 9999;
  display: none;
  max-height: 420px;
  overflow-y: auto;
  border: 1px solid rgba(26,26,24,0.08);
  padding: 8px 0;
}

.search-cat-header {
  padding: 12px 16px 6px;
  font-size: 0.62rem;
  font-weight: 800;
  text-transform: uppercase;
  color: var(--gold);
  letter-spacing: 0.12em;
  background: #fafafa;
}

.suggestion-item {
  padding: 10px 16px;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.84rem;
  color: #1a1a18;
  transition: all 0.2s ease;
}
.suggestion-item:hover {
  background: #fcf9f2;
  color: var(--gold);
  padding-left: 20px;
}
.suggestion-item small {
  font-size: 0.65rem;
  font-weight: 700;
  text-transform: uppercase;
  opacity: 0.3;
}
/* --- Mobile Menu --------------------------------------------- */
.portable {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  height: 100dvh;
  min-height: -webkit-fill-available;
  background: #1a1a18;
  z-index: 800;
  display: flex;
  flex-direction: column;
  padding: 100px 32px max(48px, calc(40px + env(safe-area-inset-bottom)));
  transform: translateX(110%);
  transition: transform .42s cubic-bezier(.25,.46,.45,.94), visibility 0s .42s;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  visibility: hidden;
}
.portable.affiche {
  transform: translateX(0);
  visibility: visible;
  transition: transform .42s cubic-bezier(.25,.46,.45,.94), visibility 0s;
}
.portable.affiche { transform: translateX(0); }
.mobile-nav { display: grid; gap: 0; flex: 1; overflow-y: auto; min-height: 0; }
.mobile-link {
  display: block;
  font-family: 'Cinzel', serif;
  font-size: 1.05rem;
  font-weight: 600;
  letter-spacing: .06em;
  color: rgba(255,255,255,.8);
  padding: 10px 0;
  border-bottom: 1px solid rgba(255,255,255,.07);
  cursor: pointer;
  background: none;
  border-left: none;
  border-right: none;
  border-top: none;
  text-align: left;
  width: 100%;
  transition: color .25s ease;
  text-decoration: none;
}
.mobile-link:hover,
.mobile-link.active { color: #c9a84c; }
.mobile-submenu {
  display: none;
  padding: 6px 0 10px 18px;
}
.mobile-item.is-open > .mobile-link { color: #c9a84c; }
.mobile-item.is-open .mobile-submenu { display: block; }
.mobile-submenu li { border: none; }
.mobile-submenu li a {
  display: block;
  font-family: 'Manrope', sans-serif;
  font-size: .78rem;
  font-weight: 700;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: rgba(255,255,255,.5);
  padding: 8px 0;
  transition: color .25s ease;
  text-decoration: none;
  border-bottom: none;
}
.mobile-submenu li a:hover { color: #c9a84c; }

.btn4 {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  position: sticky;
  bottom: 0;
  margin-top: 20px;
  padding: 16px 40px;
  background: #c9a84c;
  color: #1a1a18;
  border-radius: 999px;
  font-family: 'Manrope', sans-serif;
  font-weight: 700;
  font-size: .82rem;
  letter-spacing: .14em;
  text-transform: uppercase;
  text-decoration: none;
  transition: background .3s ease;
}
.btn4:hover { background: #b8942f; }
body.no-scroll { overflow: hidden; }

/* --- Mobile Search dans le menu ----------------------------- */
.mobile-search-wrap {
  position: relative;
  margin: 0 0 10px;
  flex-shrink: 0;
}
.mobile-search-input {
  width: 100%;
  padding: 12px 18px 12px 42px;
  border-radius: 8px;
  border: 1px solid rgba(255,255,255,.15);
  background: rgba(255,255,255,.08);
  color: #fff;
  font-family: 'Manrope', sans-serif;
  font-size: .9rem;
  outline: none;
  transition: border-color .3s, background .3s;
}
.mobile-search-input::placeholder { color: rgba(255,255,255,.35); }
.mobile-search-input:focus { border-color: #c9a84c; background: rgba(255,255,255,.12); }
.mobile-search-icon {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 1rem;
  pointer-events: none;
}
.mobile-search-results {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  right: 0;
  background: #fff;
  border-radius: 10px;
  box-shadow: 0 16px 48px rgba(0,0,0,.35);
  z-index: 9999;
  display: none;
  max-height: 280px;
  overflow-y: auto;
}
.mobile-suggestion-item {
  padding: 12px 16px;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: .84rem;
  color: #1a1a18;
  border-bottom: 1px solid rgba(26,26,24,.06);
  transition: background .2s;
}
.mobile-suggestion-item:last-child { border-bottom: none; }
.mobile-suggestion-item:hover { background: #fcf9f2; color: #c9a84c; }
.mobile-suggestion-item small { font-size: .62rem; font-weight: 700; text-transform: uppercase; opacity: .35; }
.mobile-no-result { padding: 16px; text-align: center; font-size: .8rem; color: #999; }

/* --- Responsive ---------------------------------------------- */

/* Écrans intermédiaires : réduire avant de cacher */
@media (max-width: 1200px) and (min-width: 1025px) {
  .site-header { gap: 10px; padding: 0 clamp(16px,2.5vw,32px); }
  .site-nav { gap: clamp(2px,1vw,14px); }
  .header-search { max-width: 160px; margin: 0 6px; }
  .header-cta { padding: 8px 14px; font-size: .65rem; }
}

@media (max-width: 1024px) {
  .site-nav { display: none; }
  .header-cta { display: none; }
  .header-search { display: none; }
  .burger { display: flex; }
}

/* Mobile */
@media (max-width: 640px) {
  .site-header { padding: 0 16px; height: 64px; gap: 12px; }
  .site-header.is-scrolled { height: 56px; }
  .brand {
    font-size: .7rem;
    max-width: calc(100vw - 80px);
    overflow: hidden;
    text-overflow: ellipsis;
  }
  .brand span { font-size: .52rem; letter-spacing: .18em; }
  .burger { width: 34px; height: 34px; }
  .portable { padding: 80px 20px max(32px, calc(24px + env(safe-area-inset-bottom))); }
  .mobile-link { font-size: .94rem; padding: 9px 0; }
  .btn4 { width: 100%; margin-top: 24px; padding: 15px 24px; }
  .mobile-search-input { font-size: .85rem; padding: 11px 16px 11px 40px; }
}

@media (max-width: 380px) {
  .site-header { padding: 0 12px; height: 58px; }
  .brand { font-size: .65rem; }
  .portable { padding: 76px 16px max(28px, calc(20px + env(safe-area-inset-bottom))); }
  .mobile-link { font-size: .88rem; }
}
