/*
 * header.css — PsyRisso Desktop
 * Styles du header : bandeau logo+identité, menu horizontal, recherche,
 * sélecteur de palette. Chargé sur toutes les pages (includes/header.php).
 * Issu de la maquette validée (Recap_Nouveau_Design_Desktop.md §1).
 *
 * Dépend de assets/css/palettes.css (variables --bleu, --dore, --ocre,
 * --creme, --blanc, --gris-sep, --gris-fond) — palettes.css doit être
 * chargé AVANT ce fichier.
 */

/* ============ 1. BANDEAU LOGO + DESCRIPTION ============ */
.hdrv-top {
  position: relative;
  overflow: hidden;
  background: var(--blanc);
  padding: 1.1rem 3rem;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1.5rem;
  max-width: 1200px;
  margin: 0 auto;
}

.hdrv-logo {
  width: 95px;
  height: 95px;
  object-fit: contain;
  flex-shrink: 0;
}

.hdrv-identite {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
}

.hdrv-nom {
  font-family: Georgia, serif;
  font-size: 1.65rem;
  font-weight: normal;
  color: var(--bleu);
  margin: 0;
  letter-spacing: 0.01em;
  line-height: 1.1;
}

.hdrv-titre {
  font-family: Georgia, serif;
  font-size: 0.95rem;
  font-weight: normal;
  color: #1a1a1a;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  line-height: 1.35;
  margin: 0.15rem 0 0;
}

.hdrv-membre {
  font-family: Georgia, serif;
  font-size: 0.75rem;
  font-style: italic;
  font-weight: normal;
  color: #5c6b66;
  letter-spacing: 0.02em;
  line-height: 1.35;
  margin: 0.1rem 0 0;
}

/* ---- Badge "Ouverture octobre 2026" (2 août 2026) ----
   Remplace l'ancien filigrane clignotant (-webkit-text-stroke + animation).
   Carte penchée, couleurs pilotées par la palette active (--creme/--bleu/--dore)
   donc s'adapte automatiquement aux 4 palettes du site.
   position: absolute — sort du flux normal, ne pousse jamais la hauteur
   du header quelle que soit l'inclinaison. */
.hdrv-badge-ouverture {
  position: absolute;
  top: 50%;
  left: 1.5rem;
  transform: translateY(-50%) rotate(-6deg);
  background: var(--creme);
  border: 1.5px solid var(--dore);
  border-radius: 6px;
  padding: 0.5rem 1.1rem;
  text-align: center;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.1);
  pointer-events: none;
}

.hdrv-badge-kicker {
  font-family: Georgia, serif;
  font-size: 0.62rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--bleu);
  margin: 0 0 0.15rem;
  line-height: 1.2;
}

.hdrv-badge-date {
  font-family: Georgia, serif;
  font-size: 1.1rem;
  font-weight: normal;
  color: var(--dore);
  margin: 0;
  line-height: 1.1;
}

@media (max-width: 1000px) {
  .hdrv-badge-ouverture { display: none; }
}

@media (max-width: 900px) {
  .hdrv-badge-ouverture { display: none; }
  .hdrv-top { grid-template-columns: 1fr; }
}

.hdrv-sep-1 {
  border: none;
  border-top: 1px solid var(--gris-sep);
  margin: 0;
}

/* ============ 2. MENU HORIZONTAL ============ */
.hdrv-menu-wrap { background: var(--blanc); }

.hdrv-menu-links {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  row-gap: 0.6rem;
  column-gap: 1.1rem;
  padding: 1.1rem 1.5rem;
  margin: 0;
}

.hdrv-menu-utils {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  row-gap: 0.6rem;
  column-gap: 0.8rem;
  margin-left: 0.5rem;
  padding-left: 0.9rem;
  border-left: 1px solid var(--gris-sep);
}

.hdrv-menu-links li a {
  font-family: Georgia, serif;
 /* font-size: 0.9rem; -- jugé un peu petit (6 août 2026) */
  font-size: 1rem;
  color: var(--bleu);
  text-decoration: none;
  letter-spacing: 0.02em;
  padding-bottom: 0.35rem;
  border-bottom: 2px solid transparent;
  transition: color 0.2s ease, border-color 0.2s ease;
}

.hdrv-menu-links li a:hover { color: var(--dore); border-bottom-color: var(--dore); }
.hdrv-menu-links li a.actif { color: var(--ocre); border-bottom-color: var(--ocre); }

.hdrv-menu-links li span.hdrv-menu-todo {
  font-family: Georgia, serif;
  font-size: 0.9rem;
  color: #b8b3a8;
  letter-spacing: 0.02em;
  padding-bottom: 0.35rem;
  border-bottom: 2px solid transparent;
  cursor: default;
}

/* ---- Recherche ---- */
.hdrv-search {
  border: 1px solid var(--gris-sep);
  border-radius: 20px;
  /* padding: 0.25rem 0.8rem; -- jugé un peu petit (6 août 2026) */
  padding: 0.4rem 1rem;
  margin-left: 0.5rem;
}

.hdrv-search form {
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.hdrv-search input {
  border: none;
  outline: none;
  background: transparent;
  font-family: Arial, sans-serif;
  /* font-size: 0.8rem; -- jugé un peu petit (6 août 2026) */
  font-size: 0.9rem;
  color: var(--bleu);
  /* width: 140px; -- élargi en cohérence avec la police plus grande (6 août 2026) */
  width: 160px;
}

.hdrv-search input::placeholder { color: #b8b3a8; }
.hdrv-search button {
  background: none;
  border: none;
  padding: 0;
  display: flex;
  cursor: pointer;
  color: var(--bleu);
}

.hdrv-search svg {
  /* width: 15px; height: 15px; -- jugé un peu petite (6 août 2026) */
  width: 18px;
  height: 18px;
  stroke: var(--bleu);
  fill: none;
  stroke-width: 2;
}
.hdrv-search button:hover svg { stroke: var(--dore); }

/* ---- Sélecteur de palette ---- */
.hdrv-palette {
  display: flex;
  align-items: center;
  gap: 0.3rem;
  margin-left: 0.4rem;
  padding-left: 0.7rem;
  border-left: 1px solid var(--gris-sep);
}
.hdrv-pal-btn {
  position: relative;
  display: flex;
  align-items: center;
  gap: 0.3rem;
  background: none;
  border: 1px solid transparent;
  border-radius: 14px;
  padding: 0.2rem 0.4rem;
  font-family: Arial, sans-serif;
  font-size: 0.68rem;
  color: var(--bleu);
  cursor: pointer;
  white-space: nowrap;
}
.hdrv-pal-btn:hover { border-color: var(--gris-sep); }
.hdrv-pal-btn.active { border-color: var(--ocre); font-weight: bold; padding: 0.2rem 0.55rem; }

.hdrv-pal-btn::after {
  content: attr(data-tip);
  position: absolute;
  bottom: calc(100% + 9px);
  left: 50%;
  transform: translateX(-50%);
  background: var(--bleu);
  color: var(--dore);
  font-family: Arial, sans-serif;
  font-size: 0.7rem;
  font-weight: bold;
  letter-spacing: 0.02em;
  white-space: nowrap;
  padding: 0.35rem 0.7rem;
  border-radius: 5px;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.15s ease;
  z-index: 40;
}
.hdrv-pal-btn::before {
  content: '';
  position: absolute;
  bottom: calc(100% + 4px);
  left: 50%;
  transform: translateX(-50%);
  border: 5px solid transparent;
  border-top-color: var(--bleu);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.15s ease;
  z-index: 40;
}
.hdrv-pal-btn:hover::after, .hdrv-pal-btn:hover::before,
.hdrv-pal-btn:focus::after, .hdrv-pal-btn:focus::before {
  opacity: 1;
  visibility: visible;
}
.hdrv-pal-label { display: none; }

.hdrv-pal-dot {
  width: 10px; height: 10px; border-radius: 50%; flex-shrink: 0;
  border: 1px solid rgba(0,0,0,0.15);
}

.hdrv-sep-2 {
  border: none;
  border-top: 1px solid var(--gris-sep);
  margin: 0;
}

/* ============ TRANSITION : bandeau blanc fin ============ */
.hdrv-transition {
  background: var(--blanc);
  height: 1rem;
}