/* ===== Design tokens ===== */
:root {
  --brand-dark:   #050a08;
  --brand-accent: #DBFE75;
  --brand-text:   #ebffee;
}
a{ text-decoration:none; }
button{ background:none; border:0; cursor:pointer; }

/* ===== HEADER ===== */
.site-header{ position:fixed; top:20px; left:30px; right:30px; height:71px; display:flex; z-index:1000; }

/* -- Logo block -- */
.logo-block{ position:relative; overflow:hidden; z-index:0; cursor:pointer; }
.logo{ height:71px; width:auto; display:block; margin-right:-15px; }

/* -- Nav strip -- */
.nav-strip{
  position:relative; flex:1; height:71px; margin-left:-15px;
  display:flex; align-items:center; overflow:hidden;
  transform:scaleX(1); transform-origin:left center;
  transition:transform .4s cubic-bezier(.4,0,.2,1);
}

/* Inner shadow */
.nav-strip::after{
  content:""; position:absolute; inset:0; box-shadow:inset 0 15px 20px rgba(0,0,0,.15); opacity:0;
  transition:opacity .3s ease-out; pointer-events:none;
}

/* Gradient flash when header re-apparaît */
.nav-strip::before{
  content:""; position:absolute; inset:0;
  background:linear-gradient(90deg, rgba(219,254,117,.25) 0%, rgba(235,255,238,0) 65%);
  opacity:0; pointer-events:none;
  transition:opacity .45s ease-out;
}

#siteHeader.entering .nav-strip::before{ opacity:1; }

.nav-bg{ position:absolute; top:0; left:0; width:100%; height:100%; z-index:0; }

.brand-name,.nav-menu{ transition:opacity .2s ease-out, transform .2s ease-out; }

.brand-name{
  position:relative; z-index:1; color:var(--brand-text);
  font-weight:bold; text-transform:uppercase; line-height:1; font-size:23px;
  margin-left:40px; margin-right:40px; white-space:nowrap; pointer-events:none;
}

.nav-menu{ list-style:none; display:flex; gap:30px; margin-left:auto; padding-right:70px; z-index:1001; }
.nav-menu a{ color:var(--brand-text); font-weight:bold; font-size:14px; text-transform:uppercase; transition:color .2s; }
.nav-menu a:hover{ color:var(--brand-accent); text-decoration:underline;text-underline-offset:3px;}
/* ===== Effet rétractable ===== */
#siteHeader.collapsed .nav-strip{ transform:scaleX(0); }
#siteHeader.collapsed .nav-strip::after{ opacity:1; }
#siteHeader.collapsed .brand-name,
#siteHeader.collapsed .nav-menu{ opacity:0; transform:translateX(-10px); }

/* ===== Bouton hamburger ===== */
.menu-toggle{ display:none; width:36px; height:26px; position:relative; margin-right:30px; z-index:1002; cursor:pointer; }
.menu-toggle span{ position:absolute; left:0; right:0; height:4px; background:var(--brand-accent); transition:transform .2s, top .2s; }
.menu-toggle span:first-child{ top:6px; }
.menu-toggle span:last-child { top:16px; }

/* ===== WALLET CTRL ===== */
.wallet-ctrl-pill {
  --wallet-accent: var(--brand-accent);
  --wallet-bg: #4E5D2D;
  --wallet-text: var(--brand-dark);

  display: flex;
  align-items: center;
  gap: 12px;
  margin-left: auto; /* pousse la nav-menu à droite */
  margin-right: 32px;
  z-index: 1001;
  font-family: inherit;
  position: relative; /* ← AJOUTER CETTE LIGNE */
}

/* icône portefeuille */
.wallet-icon {
  display: inline-flex;
  width: 32px;
  height: 32px;
  align-items: center;
  justify-content: center;
  border-radius: 4px;
  background: transparent;
  line-height: 0;
}
.wallet-icon svg {
  width: 100%;
  height: 100%;
  fill: var(--wallet-accent);
}

/* pilule avec le montant */
.wallet-amount-pill {
  display: inline-flex;
  align-items: center;
  gap: 2px;
  padding: 4px 16px 4px 20px;
  min-height: 32px;
  background: var(--wallet-bg);
  border-radius: 0 40px 40px 0;
  font-size: 16px;
  font-weight: 600;
  color: white;
  position: relative;
  padding-right: 42px; /* place pour bouton intégré */
  box-sizing: border-box;
}
.wallet-amount-pill:hover {
  color: var(--brand-accent);
}

.wallet-amount-value {
  line-height: 1;
}
.wallet-amount-currency {
  font-size: 0.85em;
  line-height: 1;
  margin-left: 2px;
}

/* bouton + */
.wallet-add {
  position: absolute;
  right: 4px;
  top: 50%;
  transform: translateY(-50%);
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: var(--wallet-accent);
  color: var(--wallet-text);
  font-size: 16px;
  font-weight: 700;
  line-height: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: none;
  box-shadow: 0 0 0 2px var(--wallet-bg);
  transition: filter 0.15s;
  cursor: pointer;
  z-index: 2;
}
.wallet-add:hover,
.wallet-add:focus-visible {
  filter: brightness(1.1);
}

/* focus accessibilité */
.wallet-ctrl-pill :is(.wallet-icon, .wallet-amount-pill, .wallet-add):focus-visible {
  outline: 2px solid var(--wallet-accent);
  outline-offset: 2px;
}

/* ===== Responsive design ===== */
@media (max-width: 576px) {
  .wallet-ctrl-pill {
    gap: 8px;
    margin-right: 16px;
  }

  .wallet-amount-pill {
    padding: 2px 12px 2px 14px;
    font-size: 15px;
  }

  .wallet-add {
    width: 28px;
    height: 28px;
    font-size: 18px;
    transform: translateX(-10px);
  }

  .wallet-icon {
    width: 28px;
    height: 28px;
  }
}

/* Ultra compact : cache texte */
@media (max-width: 380px) {
  .wallet-amount-pill {
    display: none;
  }

  .wallet-add {
    display: none;
  }
}

/* ===== Responsive ≤992px ===== */
@media (max-width:992px){
  .menu-toggle{ display:block; }
  .brand-name { margin-left:24px; margin-right:auto; }

  .nav-menu{
    position:absolute; top:99%; left:0; right:1.5%; background:var(--brand-dark);
    flex-direction:column; gap:24px; padding:28px 40px 40px;
    transform-origin:top; transform:scaleY(0); opacity:0; pointer-events:none;
    transition:transform .3s cubic-bezier(.4,0,.2,1), opacity .25s ease-out;
  }
  .nav-menu li{ width:100%; text-align:left; }
  .nav-menu a{ display:block; padding:6px 0; font-size:15px; }

  #siteHeader.menu-open .nav-strip{ overflow:visible; transform:scaleX(1); }
  #siteHeader.menu-open .brand-name{ opacity:1; transform:none; }
  #siteHeader.menu-open .nav-menu{ transform:scaleY(1); opacity:1; pointer-events:auto; }

  #siteHeader.menu-open .menu-toggle span:first-child{ top:11px; transform:rotate(45deg); }
  #siteHeader.menu-open .menu-toggle span:last-child { top:11px; transform:rotate(-45deg); }
}

/* ===== Micro-ajustements ≤576px ===== */
@media (max-width:576px){
  .brand-name{ font-size:14px; margin-left:16px; }
  .menu-toggle{ margin-right:16px; transform:scale(.9); }
  .nav-menu{ padding:24px 28px 32px; gap:20px; }
  .nav-menu a{ font-size:14px; }
}

/* ===== Bounce animation logo ===== */
.logo-part1{ transform-origin:center bottom; }
.logo-part1.jump{ animation:bounceRot .6s cubic-bezier(.25,.46,.45,.94) both; }
@keyframes bounceRot{
  0%{ transform:translateY(0) rotate(0deg);} 25%{ transform:translateY(-18px) rotate(6deg);} 45%{ transform:translateY(4px) rotate(2deg);} 70%{ transform:translateY(-8px) rotate(1deg);} 100%{ transform:translateY(0) rotate(0deg);} }

/* === NOTIF: AJOUT === */
/* 1) Autoriser le menu à dépasser visuellement le header */
.site-header, .nav-strip { overflow: visible !important; }

/* 2) Cloche tout à droite, centrée verticalement dans la barre */
.notif-wrap{
  position:absolute;
  right:20px;
  top:51%;
  transform:translateY(-50%);
  z-index:1002;
}
@media (max-width:576px){
  .notif-wrap{ right:16px; }
}

/* Bouton cloche + badge */
.notif-btn{
  position:relative;
  background:transparent;
  border:0;
  cursor:pointer;
  padding:6px;
  border-radius:10px;
  line-height:0;
}
.notif-btn:focus-visible{ outline:2px solid var(--brand-accent); outline-offset:2px; }

.notif-badge{
  position:absolute;
  top:-10px; right:-6px;
  min-width:25px; min-height:25px;
  border-radius:100%;
  font-size:11px; font-weight:700;
  display:flex; align-items:center; justify-content:center;
  background:var(--brand-accent); color:var(--brand-dark);
  z-index:1;
}

/* 3) Menu notifications en overlay (pas coupé) */
.notif-menu{
  position:fixed;
  right:30px;
  top:calc(20px + 71px + 8px); /* header top + header height + marge */
  width:360px; max-height:420px; overflow:auto;
  background:#fff; color:var(--brand-dark);
  border:1px solid #ddd; border-radius:12px;
  box-shadow:0 10px 24px rgba(0,0,0,.12);
  display:none; z-index:9999;
}
.notif-menu.open{ display:block; }
@media (max-width:600px){
  .notif-menu{ right:16px; width:300px; }
}

/* Contenu menu */
.notif-head{
  display:flex; align-items:center; justify-content:space-between;
  padding:8px 12px; border-bottom:1px solid #eee;
}
.notif-head .title{ font-weight:700; color:var(--brand-dark); }
#notifMarkAll{
  background:var(--brand-dark); color:var(--brand-accent);
  border-radius:8px; padding:6px 10px; font-weight:600; font-size:13px;
}

.notif-item{
  display:block; padding:10px 12px; text-decoration:none; color:var(--brand-dark);
  border-bottom:1px solid #eee;
}
.notif-item:last-child{ border-bottom:0; }
.notif-item:hover{ background:#f7f7f7; }
.notif-item.unread{ background:#f9ffe5; }

.notif-empty{ padding:16px; color:#666; }

.notif-footer{
  padding:8px 12px; display:flex; gap:8px; justify-content:flex-end;
}
.notif-footer button{
  background:var(--brand-dark); color:var(--brand-accent);
  border:0; padding:8px 10px; border-radius:8px; cursor:pointer; font-weight:600;
}
