/* ── Variables ── */
:root {
  --green:        #006633;
  --green-light:  #008844;
  --green-pale:   #e8f5ee;
  --green-faint:  #f4faf7;
  --gold:         #C8960C;
  --gold-light:   #f0b429;
  --dark:         #1A1A2E;
  --gray-dark:    #374151;
  --gray:         #6B7280;
  --gray-light:   #9CA3AF;
  --light:        #F8F9FA;
  --white:        #ffffff;
  --border:       #E5E7EB;
  --border-dark:  #D1D5DB;
  --shadow-sm:    0 1px 3px rgba(0,0,0,.06);
  --shadow:       0 4px 16px rgba(0,0,0,.08);
  --shadow-lg:    0 12px 40px rgba(0,0,0,.12);
  --radius:       8px;
  --radius-lg:    14px;
  --hero-bg:      #0D1B2A;
}

/* ── Reset ── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: 'Inter', 'Source Sans 3', sans-serif;
  color: var(--dark);
  background: var(--light);
  font-size: 15px;
  line-height: 1.65;
}
a { text-decoration: none; color: inherit; }
ul { list-style: none; }
img { max-width: 100%; display: block; }

/* ── Navbar ── */
.navbar {
  background: var(--white);
  border-bottom: 1px solid var(--border);
  padding: 0 5%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: var(--shadow-sm);
  gap: 16px;
}
.navbar-logo {
  display: flex;
  align-items: center;
  gap: 10px;
}
.logo-img {
  height: 40px;
  width: auto;
  object-fit: contain;
}
.navbar-logo .logo-text {
  font-family: 'Playfair Display', serif;
  font-size: 1.1rem;
  color: var(--green);
  font-weight: 700;
}
.navbar-nav, .navbar nav {
  display: flex;
  align-items: center;
  gap: 4px;
}
.navbar nav a {
  font-weight: 500;
  font-size: .82rem;
  letter-spacing: .04em;
  text-transform: uppercase;
  color: var(--gray-dark);
  transition: color .2s, background .2s;
  position: relative;
  padding: 6px 12px;
  border-radius: 6px;
}
.navbar nav a:hover,
.navbar nav a.active {
  color: var(--green);
  background: var(--green-pale);
}
.navbar nav a::after { display: none; }

/* Bouton connexion */
.btn-connect {
  background: var(--green);
  color: var(--white) !important;
  padding: 8px 18px;
  border-radius: 6px;
  font-weight: 600 !important;
  font-size: .8rem !important;
  letter-spacing: .04em;
  transition: background .2s, transform .15s !important;
  opacity: 0;
}
.btn-connect:hover {
  background: var(--green-light) !important;
  transform: translateY(-1px);
}
.btn-connect::after { display: none !important; }

/* ── Hero ── */
.hero {
  background: var(--hero-bg);
  color: var(--white);
  text-align: center;
  padding: 72px 20px 68px;
  position: relative;
  overflow: hidden;
}

/* Grille de points — signature visuelle */
.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image: radial-gradient(circle, rgba(0,102,51,.3) 1px, transparent 1px);
  background-size: 32px 32px;
  pointer-events: none;
}

/* Lueur verte subtile */
.hero::after {
  content: '';
  position: absolute;
  top: -80px;
  left: 50%;
  transform: translateX(-50%);
  width: 600px;
  height: 400px;
  background: radial-gradient(ellipse, rgba(0,136,68,.15) 0%, transparent 70%);
  pointer-events: none;
}

.hero-content { position: relative; z-index: 1; max-width: 780px; margin: 0 auto; }

.hero h1 {
  font-family: 'Playfair Display', serif;
  font-size: clamp(1.8rem, 4vw, 2.8rem);
  font-weight: 700;
  margin-bottom: 14px;
  letter-spacing: -.02em;
  line-height: 1.2;
  color: var(--white);
}
.hero h1 span { color: #5EE89A; }
.hero p {
  font-size: .95rem;
  opacity: .7;
  margin-bottom: 32px;
  font-weight: 300;
  line-height: 1.7;
  max-width: 520px;
  margin-left: auto;
  margin-right: auto;
}

/* Barre de recherche */
.search-bar {
  display: flex;
  max-width: 540px;
  margin: 0 auto;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 8px 32px rgba(0,0,0,.25);
  border: 1px solid rgba(255,255,255,.1);
}
.search-bar input {
  flex: 1;
  padding: 14px 20px;
  border: none;
  outline: none;
  font-family: 'Inter', 'Source Sans 3', sans-serif;
  font-size: .93rem;
  color: var(--dark);
  background: var(--white);
}
.search-bar input::placeholder { color: var(--gray-light); }
.search-bar button {
  background: var(--gold);
  border: none;
  padding: 0 22px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background .2s;
}
.search-bar button:hover { background: var(--gold-light); }
.search-bar button svg { width: 18px; height: 18px; fill: white; }

/* ── Stats ── */
.stats {
  display: flex;
  background: var(--white);
  border-bottom: 1px solid var(--border);
}
.stat-item {
  flex: 1;
  text-align: center;
  padding: 28px 16px;
  border-right: 1px solid var(--border);
  transition: background .2s;
  position: relative;
}
.stat-item:last-child { border-right: none; }
.stat-item:hover { background: var(--green-faint); }
.stat-num {
  font-family: 'Playfair Display', serif;
  font-size: 2.6rem;
  font-weight: 700;
  line-height: 1;
  display: block;
  color: var(--green);
  margin-bottom: 8px;
}
.stat-label {
  font-size: .72rem;
  font-weight: 600;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--gray);
  margin-top: 4px;
}

/* ── Section titles ── */
.section-title {
  font-family: 'Playfair Display', serif;
  font-size: 1.6rem;
  color: var(--dark);
  text-align: center;
  margin-bottom: 10px;
  position: relative;
  font-weight: 700;
}
.section-title::after {
  content: '';
  display: block;
  width: 40px;
  height: 3px;
  background: var(--gold);
  margin: 10px auto 0;
  border-radius: 2px;
}

/* ── Explore Resources ── */
.explore {
  padding: 56px 5%;
  background: var(--light);
}

/* ── Custom Dropdown ── */
.custom-select-wrapper {
  max-width: 400px;
  margin: 0 auto;
  position: relative;
}
.custom-select {
  position: relative;
  user-select: none;
}
.select-selected {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 13px 18px;
  border: 1.5px solid var(--border-dark);
  border-radius: var(--radius);
  background: var(--white);
  cursor: pointer;
  font-size: .93rem;
  font-weight: 500;
  color: var(--gray);
  transition: border-color .2s, box-shadow .2s;
}
.select-selected:hover {
  border-color: var(--green);
  box-shadow: 0 0 0 3px rgba(0,102,51,.08);
}
.select-selected.open {
  border-color: var(--green);
  border-bottom-left-radius: 0;
  border-bottom-right-radius: 0;
  box-shadow: 0 0 0 3px rgba(0,102,51,.08);
}
.select-arrow {
  width: 18px; height: 18px;
  color: var(--green);
  transition: transform .25s;
  flex-shrink: 0;
}
.select-arrow.rotated { transform: rotate(180deg); }
.select-options {
  display: none;
  position: absolute;
  top: 100%;
  left: 0; right: 0;
  background: var(--white);
  border: 1.5px solid var(--green);
  border-top: none;
  border-bottom-left-radius: var(--radius);
  border-bottom-right-radius: var(--radius);
  z-index: 50;
  box-shadow: var(--shadow-lg);
  overflow: hidden;
  animation: slideDown .2s ease;
}
.select-options.open { display: block; }
@keyframes slideDown {
  from { opacity: 0; transform: translateY(-6px); }
  to   { opacity: 1; transform: none; }
}
.select-options li {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 18px;
  cursor: pointer;
  font-size: .9rem;
  font-weight: 500;
  color: var(--dark);
  border-bottom: 1px solid var(--border);
  transition: background .15s, color .15s;
}
.select-options li:last-child { border-bottom: none; }
.select-options li:hover {
  background: var(--green-pale);
  color: var(--green);
}
.select-options li.selected {
  background: var(--green-pale);
  color: var(--green);
}
.opt-icon {
  font-size: 1rem;
  color: var(--green);
  width: 22px;
  text-align: center;
}

/* ── Publications ── */
.publications {
  padding: 56px 5%;
  background: var(--white);
}
.pub-list {
  max-width: 860px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 0;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow);
}
.pub-item {
  background: var(--white);
  border-bottom: 1px solid var(--border);
  transition: background .15s;
}
.pub-item:last-child { border-bottom: none; }
.pub-header {
  display: flex;
  align-items: center;
  padding: 18px 22px;
  cursor: pointer;
  gap: 14px;
}
.pub-header:hover { background: var(--green-faint); }
.pub-dot {
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--green);
  flex-shrink: 0;
}
.pub-title {
  flex: 1;
  font-weight: 600;
  font-size: .92rem;
  color: var(--dark);
  line-height: 1.4;
}
.pub-meta {
  font-size: .78rem;
  color: var(--gray);
}
.pub-toggle {
  background: none;
  border: 1px solid var(--border);
  color: var(--gray);
  border-radius: 6px;
  width: 28px; height: 28px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: .75rem;
  flex-shrink: 0;
  transition: all .2s;
}
.pub-toggle:hover { border-color: var(--green); color: var(--green); }
.pub-body {
  display: none;
  padding: 0 22px 20px 44px;
  border-top: 1px solid var(--border);
}
.pub-body.open { display: block; animation: fadeDown .2s ease; }
@keyframes fadeDown {
  from { opacity: 0; transform: translateY(-6px); }
  to   { opacity: 1; transform: none; }
}
.pub-abstract-label {
  display: inline-block;
  font-size: .68rem;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--gold);
  border-left: 3px solid var(--gold);
  padding-left: 8px;
  margin: 14px 0 8px;
}
.pub-abstract-text {
  font-size: .87rem;
  color: var(--gray-dark);
  line-height: 1.7;
  margin-bottom: 12px;
}
.btn-pdf {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--light);
  color: var(--gray-dark);
  font-weight: 600;
  font-size: .78rem;
  padding: 6px 14px;
  border-radius: 6px;
  border: 1px solid var(--border);
  transition: all .2s;
  cursor: pointer;
}
.btn-pdf:hover {
  background: var(--green-pale);
  color: var(--green);
  border-color: var(--green);
}
.btn-voir-plus {
  display: flex;
  justify-content: center;
  margin-top: 28px;
}
.btn-voir-plus a {
  background: var(--green);
  color: white;
  font-weight: 600;
  font-size: .85rem;
  padding: 11px 28px;
  border-radius: 8px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  letter-spacing: .03em;
  transition: background .2s, transform .2s;
}
.btn-voir-plus a:hover { background: var(--green-light); transform: translateY(-2px); }

/* ── Chercheurs & Axes ── */
.bottom-section {
  background: var(--light);
  padding: 56px 5%;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  max-width: 1100px;
  margin: 0 auto;
}
.sub-title {
  font-family: 'Playfair Display', serif;
  font-size: 1.15rem;
  color: var(--dark);
  margin-bottom: 20px;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 10px;
}
.sub-title::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--border);
}
.chercheurs-grid {
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: nowrap;
  margin-bottom: 20px;
}
.chercheur-card {
  position: relative;
  cursor: pointer;
  width: 115px;
  flex-shrink: 0;
  overflow: hidden;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
  transition: transform .2s, box-shadow .2s;
}
.chercheur-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow);
  border-color: var(--green);
}
.chercheur-avatar {
  width: 100%;
  height: 135px;
  object-fit: cover;
  display: block;
  background: var(--green-pale);
  overflow: hidden;
}
.chercheur-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.chercheur-name {
  display: block;
  background: var(--green);
  color: var(--white);
  font-size: .78rem;
  font-weight: 600;
  padding: 8px 6px;
  text-align: center;
  letter-spacing: .02em;
}
.btn-all-chercheurs {
  display: block;
  margin: 0 auto;
  width: fit-content;
  background: var(--white);
  color: var(--green);
  border: 1px solid var(--green);
  font-weight: 600;
  font-size: .78rem;
  padding: 8px 18px;
  border-radius: 6px;
  letter-spacing: .03em;
  transition: all .2s;
}
.btn-all-chercheurs:hover {
  background: var(--green);
  color: white;
}
.axes-list { padding: 0; }
.axe-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 0;
  border-bottom: 1px solid var(--border);
  font-size: .85rem;
  font-weight: 500;
  color: var(--gray-dark);
  cursor: pointer;
  transition: color .2s;
}
.axe-item:last-child { border-bottom: none; }
.axe-item:hover { color: var(--green); }
.axe-item.priority {
  background: linear-gradient(90deg, var(--green-pale), transparent);
  border-left: 3px solid var(--green);
  padding-left: 10px;
  font-weight: 700;
  color: var(--green);
  font-size: .88rem;
  margin: 2px 0;
  border-radius: 0 4px 4px 0;
}
.axe-item.priority:hover {
  background: linear-gradient(90deg, rgba(0,102,51,.12), transparent);
  transform: translateX(3px);
}
.axe-dot {
  width: 8px; height: 8px;
  border-radius: 50%;
  flex-shrink: 0;
}

/* ── Footer ── */
footer {
  background: var(--dark);
  color: rgba(255,255,255,.6);
}
.footer-social {
  background: rgba(0,0,0,.2);
  display: flex;
  justify-content: center;
  gap: 12px;
  padding: 20px;
}
.social-link {
  width: 36px; height: 36px;
  border-radius: 8px;
  border: 1px solid rgba(255,255,255,.15);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: .85rem;
  color: rgba(255,255,255,.5);
  transition: all .2s;
  cursor: pointer;
}
.social-link:hover {
  border-color: #5EE89A;
  color: #5EE89A;
}
.footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 5%;
  font-size: .75rem;
  border-top: 1px solid rgba(255,255,255,.08);
  flex-wrap: wrap;
  gap: 8px;
  color: rgba(255,255,255,.35);
}
.footer-bottom a {
  color: rgba(255,255,255,.35);
  transition: color .2s;
}
.footer-bottom a:hover { color: #5EE89A; }

/* ── Dropdown Navbar ── */
.nav-dropdown { position: relative; }
.nav-dropdown > a { cursor: pointer; }
.nav-dropdown-menu {
  display: none;
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
  min-width: 220px;
  z-index: 200;
  overflow: hidden;
}
.nav-dropdown:hover .nav-dropdown-menu {
  display: block;
  animation: slideDown .2s ease;
}
.nav-dropdown-menu a {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 11px 16px !important;
  font-size: .83rem !important;
  color: var(--gray-dark) !important;
  border-bottom: 1px solid var(--border);
  text-transform: none !important;
  letter-spacing: 0 !important;
  border-radius: 0 !important;
  background: none !important;
  transition: background .15s, color .15s;
}
.nav-dropdown-menu a:last-child { border-bottom: none; }
.nav-dropdown-menu a:hover {
  background: var(--green-pale) !important;
  color: var(--green) !important;
}
.nav-dropdown-menu a::after { display: none !important; }
.nav-dropdown-menu i {
  color: var(--green);
  width: 16px;
  text-align: center;
}

/* ── Google Translate ── */
#google_translate_element { display: none !important; }
.goog-te-banner-frame { display: none !important; }
body { top: 0 !important; }
font[style] { background: none !important; box-shadow: none !important; }
.skiptranslate { display: none !important; }

/* ── Bouton hamburger ── */
.menu-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  width: 40px;
  height: 40px;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 5px;
  padding: 0;
  z-index: 101;
  margin-left: auto;
}
.menu-toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--dark);
  border-radius: 2px;
  transition: transform .3s, opacity .3s;
}
.menu-toggle.active span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.menu-toggle.active span:nth-child(2) { opacity: 0; }
.menu-toggle.active span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/*Anti-débordement*/
html, body { overflow-x: hidden; max-width: 100%; }

/*Tablette*/
@media (max-width: 900px) {
  .bottom-section { grid-template-columns: 1fr; gap: 36px; }
}

/*Mobile */
@media (max-width: 768px) {
  .navbar {
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
    height: 58px;
    padding: 0 16px;
  }
  .logo-img { height: 36px; }

  .navbar-nav, .navbar-actions { display: none; }
  .navbar-nav.open, .navbar-actions.open {
    display: flex;
    position: fixed;
    top: 58px;
    left: 0; right: 0;
    bottom: 0;
    background: var(--white);
    z-index: 199;
    overflow-y: auto;
  }
  .navbar-nav.open {
    flex-direction: column;
    padding: 8px 16px 0;
    gap: 0;
    height: auto;
  }
  .navbar-nav.open li {
    border-bottom: 1px solid var(--border);
  }
  .navbar-nav.open li a {
    display: block;
    padding: 16px 0;
    font-size: .92rem;
  }
  .navbar-actions.open {
    flex-direction: row;
    align-items: center;
    justify-content: flex-end;
    padding: 12px 16px;
    gap: 10px;
    top: auto;
    bottom: auto;
    position: relative;
    background: var(--white);
  }
  .menu-toggle { display: flex; margin-left: auto; }

  .nav-dropdown-menu {
    display: block;
    position: static;
    border: none;
    box-shadow: none;
    background: var(--light);
    margin-top: 4px;
    border-radius: 4px;
  }
  .nav-dropdown-menu a {
    padding: 10px 14px !important;
    font-size: .85rem !important;
  }

  .hero { padding: 48px 16px 44px; }
  .hero h1 { font-size: 1.6rem; }
  .hero p { font-size: .9rem; }
  .search-bar { max-width: 100%; border-radius: 8px; }
  .search-bar input { padding: 12px 14px; font-size: .88rem; }
  .search-bar button { padding: 0 16px; }
  .search-bar button svg { width: 17px; height: 17px; }

  .stats { flex-direction: row; }
  .stat-item { padding: 16px 6px; border-bottom: none; }
  .stat-num { font-size: 1.6rem; }
  .stat-label { font-size: .62rem; letter-spacing: .06em; }

  .publications { padding: 32px 4%; }
  .pub-list { max-width: 100%; }
  .pub-header {
    display: grid;
    grid-template-columns: auto 1fr auto;
    grid-template-areas:
      "dot title toggle"
      ".   meta  meta";
    gap: 6px 10px;
    padding: 14px;
    align-items: center;
  }
  .pub-dot { grid-area: dot; }
  .pub-title { grid-area: title; font-size: .9rem; line-height: 1.35; }
  .pub-toggle { grid-area: toggle; }
  .pub-meta {
    grid-area: meta;
    font-size: .76rem;
    white-space: normal !important;
    word-break: break-word;
    line-height: 1.4;
  }
  .pub-body { padding: 0 14px 14px 14px; }

  .chercheurs-grid { gap: 8px; }
  .chercheur-card { width: calc(33% - 8px); max-width: 110px; }
  .chercheur-avatar { height: 110px; }
  .chercheur-name { font-size: .7rem; padding: 6px 4px; }

  .btn-all-chercheurs { font-size: .76rem; padding: 8px 14px; }

  .axe-item { font-size: .83rem; padding: 10px 0; }
  .axe-item.priority { font-size: .85rem; }

  .footer-bottom { flex-direction: column; text-align: center; padding: 14px 16px; }
  .footer-social { gap: 10px; padding: 16px; }

  .section-title { font-size: 1.3rem; }
  .sub-title { font-size: 1.05rem; }
}

/* ── Très petit mobile ── */
@media (max-width: 380px) {
  .stat-num { font-size: 1.4rem; }
  .stat-label { font-size: .58rem; }
  .hero h1 { font-size: 1.35rem; }
  .chercheur-card { width: calc(33% - 6px); }
  .chercheur-avatar { height: 95px; }
}
.navbar-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}
.btn-lang {
  background: none;
  border: 1px solid var(--border);
  color: var(--gray-dark);
  padding: 5px 12px;
  border-radius: 6px;
  font-size: .78rem;
  font-weight: 600;
  cursor: pointer;
  letter-spacing: .06em;
  transition: all .2s;
}
.btn-lang:hover { border-color: var(--green); color: var(--green); }
/* Fix Font Awesome */
i.fa-solid,
i.fa-regular,
i.fa-brands {
  width: auto !important;
  height: auto !important;
  display: inline-block !important;
}