/* ============================================================
   NEKTAR — Hero (site, hi-fi)
   Layered on top of colors_and_type.css
   ============================================================ */

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  background: var(--bg);
  color: var(--fg);
  overflow-x: hidden;
}

/* Skip link (a11y) */
.skip {
  position: absolute; left: -9999px; top: 0;
  background: var(--fg); color: var(--on-photo);
  padding: 8px 14px; font-size: 12px; letter-spacing: 0.18em; text-transform: uppercase;
  z-index: 100;
}
.skip:focus { left: 16px; top: 16px; }

/* ============================================================
   NAV
   ============================================================ */
.nav {
  position: fixed; top: 0; left: 0; right: 0;
  display: flex; align-items: center; justify-content: space-between;
  padding: 18px var(--gutter);
  z-index: 50;
  color: var(--on-photo);
  transition: background-color var(--dur) var(--ease),
              border-color var(--dur) var(--ease),
              padding var(--dur) var(--ease);
  border-bottom: 1px solid transparent;
}
.nav.is-scrolled {
  background: var(--nektar-nuit);
  color: var(--on-photo);
  border-bottom-color: var(--nektar-or);
  padding-top: 14px; padding-bottom: 14px;
}

/* Logo in nav — horizontal SVG-ish image */
.nav__brand {
  display: inline-flex; align-items: center;
  height: 44px;
}
.nav__brand img {
  height: 100%; width: auto; display: block;
  /* The horizontal logo PNG is gold lineart on transparent — keep as-is on photo.
     On the scrolled cream nav, we keep it gold too — that's the accent rule. */
  filter: none;
}
.nav.is-scrolled .nav__brand { height: 36px; }
.nav__brand--medallion {
  height: 72px;
}
.nav__brand--medallion img {
  border-radius: var(--radius-pill);
}
.nav.is-scrolled .nav__brand--medallion { height: 64px; }

.nav__right {
  display: flex; align-items: center; gap: clamp(20px, 3vw, 36px);
}

.nav__links {
  display: flex; align-items: center; gap: clamp(20px, 3vw, 36px);
}
.nav__links a {
  color: inherit; text-decoration: none;
  font-family: var(--font-body); font-weight: 400;
  font-size: 11px; letter-spacing: var(--track-eyebrow);
  text-transform: uppercase;
  position: relative;
  padding-bottom: 4px;
}
.nav__links a::after {
  content: "";
  position: absolute; left: 0; right: 0; bottom: 0;
  height: 1px; background: var(--accent);
  transform-origin: left; transform: scaleX(0);
  transition: transform var(--dur) var(--ease);
}
.nav__links a:hover::after { transform: scaleX(1); }
.nav__links a.is-cta {
  padding-bottom: 5px;
  border-bottom: 1px solid var(--accent);
}
.nav__links a.is-cta::after { display: none; }
.nav__links a.is-cta:hover { color: var(--accent); }

/* Mobile burger */
.nav__burger {
  display: none;
  width: 22px; height: 16px;
  flex-direction: column; justify-content: space-between;
  background: transparent; border: 0; padding: 0; cursor: pointer;
  color: inherit;
}
.nav__burger span {
  display: block; height: 1px; background: currentColor;
  transition: transform var(--dur) var(--ease), opacity var(--dur) var(--ease);
}

/* Lang toggle — fonctional, two locales */
.lang {
  display: inline-flex; align-items: center;
  font-family: var(--font-body); font-weight: 400;
  font-size: 10px; letter-spacing: 0.22em; text-transform: uppercase;
  color: inherit; gap: 0;
}
.lang button {
  background: transparent; border: 0; color: inherit; cursor: pointer;
  padding: 4px 2px;
  font: inherit; letter-spacing: inherit;
  opacity: 0.5;
  transition: opacity var(--dur) var(--ease), color var(--dur) var(--ease);
}
.lang button.is-on { opacity: 1; color: var(--accent); }
.lang .sep { opacity: 0.4; margin: 0 4px; }

/* Desktop / mobile logo switch */
.nav__brand--show-mobile { display: none; }
.nav__brand--show-desktop { display: inline-flex; }

@media (max-width: 760px) {
  /* Masquer TOUS les liens nav sur mobile — le drawer les contient */
  .nav__links { display: none; }
  .nav__burger { display: flex; }

  /* Logo : médaillon sur mobile, horizontal masqué */
  .nav__brand--show-desktop { display: none; }
  .nav__brand--show-mobile  { display: inline-flex; }

  /* Nav mobile sizing */
  .nav { padding: 12px 20px; }
  .nav.is-scrolled { padding: 10px 20px; }
  .nav__brand--medallion { height: 44px; }
  .nav.is-scrolled .nav__brand--medallion { height: 40px; }
  .nav__right { gap: 14px; }

  /* Teaser */
  .teaser { padding: 48px 24px; }
}

/* ============================================================
   HERO
   ============================================================ */
.hero {
  position: relative;
  min-height: 100svh;
  width: 100%;
  overflow: hidden;
  isolation: isolate;
}

.hero__photo {
  position: absolute; inset: 0;
  z-index: 0;
  background:
    /* tungsten warm wash, very subtle — only when no image is loaded */
    radial-gradient(ellipse at 30% 75%, rgba(201, 168, 76, 0.18) 0%, transparent 55%),
    radial-gradient(ellipse at 80% 20%, rgba(201, 168, 76, 0.10) 0%, transparent 50%),
    linear-gradient(170deg, #1a1812 0%, #2a2418 40%, #3d2f1f 75%, #5b4422 100%);
  /* the real photograph (Unsplash placeholder) */
  background-size: cover;
  background-position: center;
}
.hero__photo img {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: cover;
  object-position: left center;
  display: block;
  opacity: 0;
  transition: opacity var(--dur-slow) var(--ease);
}
.hero__photo img.is-loaded { opacity: 1; }

/* Film grain overlay — subtle, on photo only */
.hero__grain {
  position: absolute; inset: 0;
  pointer-events: none;
  opacity: 0.18;
  mix-blend-mode: overlay;
  background-image:
    url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='180' height='180'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/><feColorMatrix type='matrix' values='0 0 0 0 0.95  0 0 0 0 0.9  0 0 0 0 0.82  0 0 0 0.6 0'/></filter><rect width='100%25' height='100%25' filter='url(%23n)'/></svg>");
  z-index: 1;
}

/* Overlay for type legibility — variants set --hero-overlay */
.hero__overlay {
  position: absolute; inset: 0;
  z-index: 2;
  pointer-events: none;
  background: var(--hero-overlay, linear-gradient(180deg,
    rgba(13,27,62,0.30) 0%,
    rgba(13,27,62,0.10) 30%,
    rgba(13,27,62,0.55) 100%));
}

.hero__inner {
  position: relative;
  z-index: 3;
  width: 100%;
  min-height: 100svh;
  padding: clamp(96px, 14vh, 140px) var(--gutter) clamp(110px, 16vh, 160px) var(--gutter);
  display: flex; flex-direction: column;
  color: var(--on-photo);
}

/* Lock-ups */
.hero[data-layout="left"]     .hero__inner { justify-content: center; align-items: flex-start; }
.hero[data-layout="right"]    .hero__inner { justify-content: center; align-items: flex-end;   text-align: right; }
.hero[data-layout="centered"] .hero__inner { justify-content: center; align-items: center;     text-align: center; }

/* Alignement selon le lock-up */
.hero[data-layout="centered"] .hero__copy { align-items: center; }
.hero[data-layout="centered"] .hero__cta-row { justify-content: center; }

.hero[data-layout="right"] .hero__copy { align-items: flex-end; }
.hero[data-layout="right"] .hero__cta-row { justify-content: flex-end; }

.hero__copy { max-width: min(900px, 92%); display: flex; flex-direction: column; gap: clamp(14px, 2vh, 22px); }

.hero__eyebrow {
  font-family: var(--font-body); font-weight: 400;
  font-size: var(--t-eyebrow);
  letter-spacing: var(--track-eyebrow); text-transform: uppercase;
  color: var(--accent);
}

.hero__title {
  font-family: var(--font-display);
  font-weight: 500; font-style: italic;
  font-size: clamp(54px, 11.5vw, 184px);
  line-height: 0.92; letter-spacing: -0.025em;
  color: var(--on-photo);
  margin: 0;
}

.hero__cta-row {
  display: flex; align-items: center; gap: 24px;
  margin-top: clamp(6px, 1.5vh, 14px);
}
.hero__cta {
  color: var(--on-photo); text-decoration: none;
  font-family: var(--font-body); font-weight: 400;
  font-size: 12px; letter-spacing: 0.26em; text-transform: uppercase;
  padding-bottom: 6px;
  border-bottom: 1px solid var(--accent);
  transition: color var(--dur) var(--ease), letter-spacing var(--dur) var(--ease);
}
.hero__cta:hover { color: var(--accent); letter-spacing: 0.30em; }

.hero__foot {
  position: absolute;
  left: var(--gutter); right: var(--gutter); bottom: clamp(20px, 4vh, 36px);
  z-index: 3;
  display: flex; align-items: flex-end; justify-content: space-between;
  gap: 24px;
  color: var(--on-photo-muted);
  font-size: 11px; letter-spacing: 0.18em; text-transform: uppercase;
  line-height: 1.85;
  pointer-events: none;
}
.hero__foot a {
  color: inherit;
  text-decoration: none;
}
.hero__foot .addr { pointer-events: auto; }
.hero__foot .scroll {
  display: inline-flex; align-items: center; gap: 10px;
  pointer-events: auto;
  transition: color var(--dur) var(--ease);
}
.hero__foot .scroll:hover { color: var(--on-photo); }
.hero__foot .scroll .rule {
  display: inline-block; width: 28px; height: 1px; background: var(--accent);
  transition: width var(--dur) var(--ease);
}
.hero__foot .scroll:hover .rule { width: 44px; }

/* Hero mobile overrides — must come AFTER base hero styles to win cascade */
@media (max-width: 760px) {
  /* Hero inner */
  .hero__inner {
    padding-top: 80px;
    padding-bottom: 120px;
    padding-left: 24px;
    padding-right: 24px;
  }

  /* Eyebrow : tracking réduit pour tenir sur une ligne */
  .hero__eyebrow {
    font-size: 9px;
    letter-spacing: 0.16em;
  }

  /* Titre : proportionné à 390 px */
  .hero__title {
    font-size: clamp(38px, 10.5vw, 52px);
    line-height: 1.0;
  }

  /* CTA : zone de tap min 44px */
  .hero__cta {
    display: inline-flex;
    align-items: center;
    min-height: 44px;
    padding: 0 2px;
    font-size: 11px;
    letter-spacing: 0.22em;
  }

  /* Pied du hero */
  .hero__foot {
    flex-direction: column;
    align-items: center;
    text-align: center;
    bottom: 20px;
    gap: 8px;
    font-size: 10px;
    letter-spacing: 0.14em;
  }
  .hero__foot .scroll { display: none; }

  /* Copy block */
  .hero__copy { max-width: 100%; gap: 14px; }

  .hero[data-layout="left"]  .hero__inner { padding-bottom: 140px; }
  .hero[data-layout="right"] .hero__inner { padding-bottom: 140px; }
}

/* ============================================================
   NEXT SECTION TEASER (so we see what's below the fold)
   ============================================================ */
.teaser {
  background: var(--bg);
  padding: clamp(64px, 12vh, 128px) var(--gutter) clamp(48px, 10vh, 96px) var(--gutter);
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: var(--space-5);
}
.teaser__eyebrow {
  font-family: var(--font-body); font-weight: 400;
  font-size: var(--t-eyebrow);
  letter-spacing: var(--track-eyebrow); text-transform: uppercase;
  color: var(--accent);
}
.teaser__title {
  font-family: var(--font-display); font-weight: 300; font-style: italic;
  font-size: clamp(32px, 5vw, 64px);
  line-height: 1.05; letter-spacing: -0.018em;
  color: var(--fg);
  max-width: 14ch;
  margin: 0;
}

/* ============================================================
   "Photo à venir" tag — discreet, only when no image loaded.
   ============================================================ */
.placeholder-tag {
  position: absolute; right: var(--gutter); top: calc(72px + 16px);
  z-index: 4;
  font-family: var(--font-body); font-weight: 400;
  font-size: 9px; letter-spacing: 0.24em; text-transform: uppercase;
  color: var(--on-photo-muted);
  background: rgba(13, 27, 62, 0.35);
  padding: 6px 10px; border: 1px solid rgba(248, 244, 236, 0.18);
}
.hero__photo img.is-loaded ~ .placeholder-tag { display: none; }

/* ============================================================
   TITLE VARIANTS — « Nektar » or vs logo
   ============================================================ */

/* A: mot Nektar en or champagne */
.hero__title-or {
  color: var(--nektar-or);
}

/* B: wordmark PNG inline — taille calée sur la hauteur du texte voisin */
.title-wordmark {
  display: inline-block;
  height: 0.88em;       /* proportionnel à la font-size du h1 */
  width: auto;
  vertical-align: middle;
  margin: 0.06em 0;     /* petit respir haut/bas */
  /* Le PNG est doré sur transparent — rendu identique sur photo */
}

/* Sur 3 lignes, on redresse la line-height pour que la ligne
   du wordmark (plus courte visuellement) ne creuse pas l'espacement */
.hero__title--three-line {
  line-height: 1.0;
}

/* Adaptation mobile : le wordmark est grand, s'assurer qu'il ne déborde pas */
@media (max-width: 760px) {
  .title-wordmark {
    max-width: min(100%, 340px);
    height: auto;
    display: block;
    margin: 0.1em 0;
  }
  .hero__title--three-line { line-height: 1.05; }
}

/* ============================================================
   FLOATING RÉSERVER — apparaît quand le CTA hero quitte le viewport
   ============================================================ */
.resa-float {
  position: fixed;
  bottom: max(24px, env(safe-area-inset-bottom, 0px) + 16px);
  right: 20px;
  z-index: 100;

  background: var(--nektar-nuit);
  color: var(--nektar-or);
  border: 1px solid var(--nektar-or);

  font-family: var(--font-body);
  font-weight: 400;
  font-size: 10px;
  letter-spacing: 0.26em;
  text-transform: uppercase;

  padding: 14px 22px;
  cursor: pointer;

  opacity: 0;
  transform: translateY(10px);
  pointer-events: none;
  transition:
    opacity var(--dur) var(--ease),
    transform var(--dur) var(--ease),
    color var(--dur) var(--ease);
}
.resa-float.is-visible {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}
.resa-float:hover { color: var(--on-photo); }
