/* ════════════════════════════════════════
   TOP BANNER
════════════════════════════════════════ */
.top-banner {
  background: var(--banner-bg);
  color: var(--white);
  height: var(--banner-h);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 13.5px;
  font-weight: var(--fw-regular);
  letter-spacing: 0.01em;
  position: sticky;
  top: 0;
  z-index: 200;
}
.top-banner a {
  color: var(--white);
  text-decoration: underline;
  text-underline-offset: 2px;
  margin-left: 6px;
  font-weight: var(--fw-medium);
}
.top-banner a:hover { opacity: 0.85; }

/* ════════════════════════════════════════
   MAIN HEADER
════════════════════════════════════════ */
.site-header {
  background: var(--bg-white);
  height: var(--header-h);
  display: flex;
  align-items: center;
  padding: 0 var(--space-xl);
  position: sticky;
  top: var(--banner-h);
  z-index: 100;
  border-bottom: 1px solid var(--gray-200);
}

.header-inner {
  display: flex;
  align-items: center;
  width: 100%;
  max-width: var(--max-w);
  margin: 0 auto;
  gap: var(--space-xl);
}

/* ── Logo ── */
.logo {
  display: flex;
  align-items: center;
  flex-shrink: 0;
  margin-right: var(--space-lg);
}
.logo img {
  height: 28px;
  width: auto;
}
.logo svg {
  height: 28px;
  width: auto;
}

/* ── Main Nav ── */
.main-nav {
  display: flex;
  align-items: center;
  gap: 0;
  flex: 1;
}
.main-nav a {
  font-size: 14.5px;
  font-weight: var(--fw-medium);
  color: var(--black);
  padding: 0 var(--space-md);
  height: var(--header-h);
  display: flex;
  align-items: center;
  position: relative;
  white-space: nowrap;
  transition: color var(--transition);
}
.main-nav a:hover { color: var(--red); }
.main-nav a.active {
  color: var(--black);
  font-weight: var(--fw-semibold);
}
.main-nav a.active::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: var(--space-md);
  right: var(--space-md);
  height: 2px;
  background: var(--red);
  border-radius: 1px 1px 0 0;
}

/* Dropdown trigger */
.nav-dropdown {
  position: relative;
}
.nav-dropdown > a {
  gap: 4px;
}
.nav-dropdown > a svg {
  width: 14px;
  height: 14px;
  transition: transform var(--transition);
}
.nav-dropdown:hover > a svg { transform: rotate(180deg); }

/* ── Header Actions (right side) ── */
.header-actions {
  display: flex;
  align-items: center;
  gap: var(--space-xs);
  margin-left: auto;
  flex-shrink: 0;
}

.btn-icon {
  width: 40px;
  height: 40px;
  border-radius: var(--radius-pill);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--black);
  transition: background var(--transition);
}
.btn-icon:hover { background: var(--gray-100); }
.btn-icon svg { width: 22px; height: 22px; }

.btn-sign-in {
  font-size: 14px;
  font-weight: var(--fw-medium);
  color: var(--black);
  padding: 0 var(--space-md);
  height: 38px;
  display: flex;
  align-items: center;
  border-radius: var(--radius-pill);
  transition: background var(--transition);
  white-space: nowrap;
}
.btn-sign-in:hover { background: var(--gray-100); }

/* ════════════════════════════════════════
   POPUP / MODAL
════════════════════════════════════════ */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.55);
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--space-md);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.25s ease, visibility 0.25s ease;
}
.modal-overlay.active {
  opacity: 1;
  visibility: visible;
}
.modal {
  background: var(--red);
  border-radius: var(--radius-xl);
  width: 100%;
  max-width: 580px;
  padding: 32px 36px 36px;
  position: relative;
  transform: translateY(16px);
  transition: transform 0.25s ease;
}
.modal-overlay.active .modal { transform: translateY(0); }

.modal-close {
  position: absolute;
  top: 16px;
  right: 16px;
  width: 36px;
  height: 36px;
  border-radius: var(--radius-pill);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--white);
  background: rgba(255,255,255,0.15);
  transition: background var(--transition);
}
.modal-close:hover { background: rgba(255,255,255,0.25); }
.modal-close svg { width: 20px; height: 20px; }

.modal-icon {
  width: 72px;
  height: 72px;
  margin-bottom: var(--space-lg);
}
.modal-icon img { width: 100%; height: 100%; object-fit: contain; }

.modal h2 {
  font-size: 32px;
  font-weight: var(--fw-bold);
  color: var(--white);
  line-height: 1.15;
  margin-bottom: var(--space-lg);
}
.modal-features {
  display: flex;
  flex-direction: column;
  gap: var(--space-sm);
  margin-bottom: var(--space-xl);
}
.modal-feature {
  font-size: 15px;
  color: var(--white);
  line-height: 1.5;
}
.modal-feature strong {
  font-weight: var(--fw-bold);
}
.modal-cta {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 56px;
  background: var(--white);
  color: var(--red);
  font-size: 16px;
  font-weight: var(--fw-semibold);
  border-radius: var(--radius-pill);
  transition: opacity var(--transition);
}
.modal-cta:hover { opacity: 0.92; }

/* ════════════════════════════════════════
   MENU BURGER
════════════════════════════════════════ */

.btn-menu{
  width:40px;
  height:40px;
  border-radius:999px;
  display:flex;
  align-items:center;
  justify-content:center;
  cursor:pointer;
  transition:.2s;
  /* Caché par défaut en desktop — visible uniquement en mobile (voir media query) */
  display: none;
}

.btn-menu:hover{
  background:#f5f5f5;
}

.btn-menu svg{
  width:22px;
  height:22px;
}

/* ════════════════════════════════════════
   DRAWER OVERLAY
════════════════════════════════════════ */

.drawer-overlay{
  position:fixed;
  inset:0;
  background:rgba(0,0,0,.35);
  opacity:0;
  visibility:hidden;
  transition:.3s;
  z-index:300;
}

.drawer-overlay.show{
  opacity:1;
  visibility:visible;
}

/* ════════════════════════════════════════
   DRAWER PANEL
════════════════════════════════════════ */

.drawer-menu{
  position:fixed;
  top:0;
  right:0;
  width:340px;
  max-width:88vw;
  height:100vh;
  background:#fff;
  z-index:301;
  transform:translateX(100%);
  transition:.3s ease;
  display:flex;
  flex-direction:column;
  overflow-y:auto;
}

.drawer-menu.open{
  transform:translateX(0);
}

/* HEADER — avatar + nom + "My account" + close */
.drawer-top{
  display:flex;
  align-items:center;
  gap:12px;
  padding:22px 20px;
  border-bottom:1px solid #ececec;
}

.drawer-avatar{
  width:38px;
  height:38px;
  border-radius:50%;
  background:#1A1A1A;
  color:#fff;
  display:flex;
  align-items:center;
  justify-content:center;
  font-size:15px;
  font-weight:700;
  flex-shrink:0;
}

.drawer-logo{
  width:36px;
  height:36px;
  border-radius:50%;
  background:#fff;
  border:1px solid #ececec;
  display:flex;
  align-items:center;
  justify-content:center;
}

.drawer-logo img{
  width:18px;
}

.drawer-user-info{
  display:flex;
  flex-direction:column;
  gap:2px;
  flex:1;
  min-width:0;
}
.drawer-user-name{
  font-size:15px;
  font-weight:700;
  color:#1A1A1A;
}
.drawer-user-link{
  font-size:13px;
  color:#666;
  text-decoration:underline;
  text-underline-offset:2px;
}

.drawer-signin{
  background:#222;
  color:#fff;
  border:none;
  border-radius:999px;
  padding:10px 18px;
  font-size:14px;
  font-weight:600;
}

.drawer-close{
  margin-left:auto;
  width:32px;
  height:32px;
  border-radius:50%;
  display:flex;
  align-items:center;
  justify-content:center;
  font-size:20px;
  line-height:1;
  cursor:pointer;
  color:#1A1A1A;
  background:transparent;
  border:none;
  flex-shrink:0;
  transition:background .15s;
}
.drawer-close:hover{ background:#f5f5f5; }

/* LINKS */

.drawer-links{
  display:flex;
  flex-direction:column;
  flex:1;
}

.drawer-link{
  display:flex;
  justify-content:space-between;
  align-items:center;
  padding:18px 20px;
  border-bottom:1px solid #ececec;
  color:#1a1a1a;
  cursor:pointer;
  gap:12px;
}

.drawer-link-text{
  display:flex;
  flex-direction:column;
  gap:3px;
  min-width:0;
}

.drawer-link strong{
  display:block;
  font-size:15.5px;
  font-weight:700;
  color:#1A1A1A;
}

.drawer-link span{
  font-size:13px;
  color:#777;
  line-height:1.3;
}

.drawer-link-chevron{
  width:18px;
  height:18px;
  color:#999;
  flex-shrink:0;
}

.drawer-link:hover{
  background:#fafafa;
}

/* Sign out — collé en bas */
.drawer-signout{
  padding:18px 20px;
  text-align:center;
  font-size:14.5px;
  font-weight:600;
  color:#1A1A1A;
  text-decoration:underline;
  text-underline-offset:2px;
  cursor:pointer;
  border-top:1px solid #ececec;
  margin-top:auto;
}
.drawer-signout:hover{ background:#fafafa; }

/* ════════════════════════════════════════
   MOBILE / TABLET RESPONSIVE
   (Tout ce qui suit est additif — ne modifie
   aucune règle desktop ci-dessus)
════════════════════════════════════════ */
@media (max-width: 1100px) {
  /* Cache la nav desktop, le menu burger devient visible */
  .main-nav { display: none; }
  .btn-menu { display: flex; }

  /* Sign in caché en mobile — remplacé par le burger menu */
  .btn-sign-in { display: none; }

  .site-header { padding: 0 var(--space-md); }
  .header-inner { gap: var(--space-md); }
}

@media (max-width: 768px) {
  .site-header { padding: 0 16px; }
  .header-inner { gap: 12px; min-width: 0; }
  .logo { margin-right: 0; }
  .logo img, .logo svg { height: 24px; }

  .header-actions { gap: 2px; }
  .btn-icon { width: 36px; height: 36px; }
  .btn-icon svg { width: 20px; height: 20px; }
  .btn-menu { width: 36px; height: 36px; }
  .btn-menu svg { width: 20px; height: 20px; }

  .top-banner {
    font-size: 12px;
    padding: 0 12px;
    text-align: center;
    line-height: 1.3;
  }

  .drawer-menu { width: 320px; }
}

@media (max-width: 380px) {
  .top-banner { font-size: 11px; }
  .logo img, .logo svg { height: 22px; }
}