/* =========================
   0) TOKENS / BASE
========================= */
:root {
  --bg: #F7F8FA;
  --panel: #fff;
  --ink: #113652;
  --muted: #ADBACC;
  --line: #E5E7EB;
  --darkline: hwb(223 83% 12%);
  /* --brand:#275C83; --brand-10:hsla(218, 100%, 52%, 0.102);*/
  --brand: #2a3b5c;
  --brand-10: hsla(218, 100%, 52%, 0.102);
  --shadow: 0 6px 24px rgba(16, 24, 40, .08);
  --shadow-soft: 0 2px 8px rgba(16, 24, 40, .06);
  --radius: 14px;
  --radius-lg: 18px;
  --maxw: 1200px;
  --gutter: 24px;
  --logos-h: clamp(180px, 30vh, 320px);
  --hero-h: calc(100vh - var(--logos-h));
}

html,
body {
  margin: 0;
  padding: 0;
  height: 100%;
  box-sizing: border-box;
  font-size: 15px;
  background: var(--bg);
  color: var(--ink);
  font-family: "Inter", Helvetica, Arial, sans-serif;
  font-weight: 300;
  font-optical-sizing: auto;
}

a {
  text-decoration: underline;
  color: inherit;
}

/* =========================
   1) LAYOUT CONTAINER
========================= */
#layout-container {
  display: block;
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 24px var(--gutter) 32px;
  min-height: 100vh;
  padding-top: 0;
}

#feedback-btn {
  position: fixed;
  bottom: 24px;
  right: 24px;
  background: var(--brand);
  color: #fff;
  border: none;
  border-radius: 9999px;
  padding: 10px 20px;
  font-size: 0.8rem;
  font-weight: 600;
  box-shadow: var(--shadow-soft);
  cursor: pointer;
  z-index: 1000;
  transition: background 0.2s ease, transform 0.2s ease;
  opacity: 0.9;
  padding: 6px 16px;
}

a#feedback-btn {
  text-decoration: none;
}

#feedback-btn:hover {
  background: color-mix(in srgb, var(--brand) 85%, white);
  transform: translateY(-2px);
  opacity: 1;
}

#feedback-btn:active {
  transform: translateY(0);
  filter: brightness(0.95);
}

/* =========================
   2) BANDS (full width backgrounds)
   - White top band: search + filters
   - Grey bottom band: logos, instructions, about, credits, results
========================= */
.section-recherche {
  background: #fff;
  box-shadow: inset 0 -1px 0 var(--line);
  padding: 100px 0 60px;
  width: 100vw;
  position: relative;
  left: 50%;
  right: 50%;
  margin-left: -50vw;
  margin-right: -50vw;
}

.section-results {
  background: var(--bg);
  padding: 0 0 80px;
  width: 100vw;
  position: relative;
  left: 50%;
  right: 50%;
  margin-left: -50vw;
  margin-right: -50vw;
}

/* Centers for inner content */
.section-recherche #filters-column,
.section-results #results-column {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 var(--gutter);
}

#info-button {
  display: none;
}

.splash #info-button {
  display: block;
}

/* =========================
   3) SEARCH AREA (inside .section-recherche)
========================= */
#filters-column {
  width: 100%;
  background: transparent;
  padding: 10px 0 0;
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
}

#filters-column h2 {
  text-align: center;
  font-weight: 300;
  font-size: 1.5em;
  line-height: 1.15;
  letter-spacing: -0.01em;
  margin: 30px;
}

.splash #filters-column h2 {
  font-size: clamp(26px, 2vw, 34px);
  margin: 50px 30px clamp(20px, 4vh, 50px);
}

/* Ensure search area centers even without a .search-wrap wrapper */
#request-selector {
  position: relative;
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
}

/* Search pill (contenteditable) */

.search-wrap {
  position: relative;
  width: min(780px, 92%);
  margin: 50px auto 8px;
}

/* Pilule (on garde tes styles existants) */
#request-text {
  background: var(--panel);
  border: 1px solid var(--darkline);
  border-radius: 999px;
  box-shadow: 0 6px 18px rgba(16, 24, 40, .06);
  padding: 16px 110px 16px 30px;
  /* place pour le bouton à droite */
  min-height: 22px;
  font-size: 1.2em;
}

/* Show placeholder only when truly empty */
#request-text:empty::before {
  content: attr(placeholder);
  color: var(--muted);
  font-style: italic;
  /* optional */
  pointer-events: none;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  display: block;
}

/* Hide on focus to avoid flicker while typing */
#request-text:focus::before {
  content: "";
}

#request-text[contenteditable][placeholder]:empty::before {
  content: attr(placeholder);
  color: #999;
  pointer-events: none;

  /* clé du problème */
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  display: block;
}



/* Bouton SEARCH dans la pilule */
.search-btn {
  position: absolute;
  top: 50%;
  right: 16px;
  /* espace avant le bouton "i" externe */
  transform: translateY(-50%);
  height: 34px;
  padding: 0 14px;
  border: 0;
  border-radius: 999px;
  background: var(--brand);
  color: #fff;
  font-weight: 700;
  font-size: 13px;
  box-shadow: 0 2px 6px rgba(16, 24, 40, .12);
  cursor: pointer;
}

.search-btn:hover {
  filter: brightness(.96);
}

.search-btn:focus-visible {
  outline: 2px solid var(--brand);
  outline-offset: 2px;
}

#search-button:disabled {
  background-color: var(--muted);
}

/* Bouton info (pilule ronde) à l'extérieur */
.info-btn {
  position: absolute;
  top: 50%;
  right: 0;
  transform: translate(calc(100% + 12px), -50%);
  /* déporté à droite */
  width: 36px;
  height: 36px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: #fff;
  color: var(--brand);
  font-weight: 700;
  box-shadow: 0 2px 8px rgba(16, 24, 40, .08);
  cursor: pointer;

}

.info-btn:hover {
  background: #F8FAFC;
}


/* Responsive */
@media (max-width: 900px) {
  .search-wrap {
    width: 92%;
  }

  .search-btn {
    right: 20px;
  }

  .info-btn {
    transform: translate(calc(100% + 8px), -50%);
  }
}



/* Disclaimer */
#filters-column #disclaimer {
  width: min(860px, 90%);
  margin: 4px auto 0;
  text-align: center;
}

#filters-column #disclaimer p {
  margin: 0;
  font-size: 11px;
  line-height: 1.35;
  color: var(--brand);
}

/* ================================
   FILTERS (CHIPS)
   ================================ */

.chips {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 20px;
  width: min(860px, 90%);
  margin: 20px auto 0;
}

@media (min-width: 1300px) {
  .chips {
    margin: 60px auto 0;
  }
}



/* --- WRAPPER --- */
.chip-wrapper {
  position: relative;
  width: 250px;
  /* largeur fixe cohérente */
}

/* --- CHIP BUTTON --- */
.chip {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  gap: 8px;

  background: #F7F8FA;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 10px 18px 10px 18px;
  /* espace pour la croix */
  font-weight: 600;
  font-size: 0.95em;
  color: var(--ink);
  cursor: pointer;
  transition: all 0.2s ease;
}

.chip:hover {
  background: #E6EBF2;
}

.chip-arrow {
  font-size: 1.5em;
  line-height: 0.8em;
  color: var(--muted);
}

/* --- CHIP ACTIVE --- */
.chip.active {
  background: var(--ink);
  color: #fff;
  border-color: var(--ink);
}

.chip.active .chip-arrow {
  display: none;
}

/* --- CLEAR BUTTON (dans le chip visuellement) --- */
.chip-clear {
  position: absolute;
  top: 0;
  right: 0;
  height: 100%;
  width: 42px;
  display: none;
  align-items: center;
  justify-content: center;

  background: transparent;
  border: none;
  color: #fff;
  font-size: 1.1em;
  cursor: pointer;
  border-radius: 0 999px 999px 0;
  transition: background 0.2s ease;
}

.chip.active+.chip-clear {
  display: flex;
}

.chip-clear:hover {
  background: rgba(255, 255, 255, 0.15);
}










/* --- MENU DÉROULANT --- */
.chip-menu {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  width: 100%;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 12px;
  box-shadow: 0 12px 30px rgba(16, 24, 40, 0.12);
  padding: 12px;
  z-index: 50;
  display: none;
}

.chip-menu.open {
  display: block;
  animation: fadeIn 0.15s ease;
}

/* --- HEADER DU MENU DÉROULANT --- */
.menu-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 8px;
  padding: 2px 4px 6px;
  border-bottom: 1px solid var(--line);
}

.menu-title {
  font-weight: 600;
  font-size: 0.95em;
  color: var(--ink);
}

/* --- BOUTON "CLEAR" --- */
.menu-reset {
  background: none;
  border: none;
  color: var(--brand);
  font-size: 0.85em;
  font-weight: 600;
  cursor: pointer;
  padding: 2px 6px;
  transition: color 0.2s ease, text-decoration 0.2s ease;
}

.menu-reset:hover {
  color: var(--brand);
  text-decoration: underline;
}

.menu-reset:active {
  color: var(--brand);
}

/* Liste en colonne */
.chip-menu label {
  display: flex;
  flex-direction: row;
  /* garantit une ligne par élément */
  align-items: center;
  gap: 8px;
  padding: 6px 8px;
  margin: 2px 0;
  border-radius: 8px;
  cursor: pointer;
  width: 100%;
}

.chip-menu label:hover {
  background: #F7F8FA;
}

/* Cases à cocher */
.chip-menu input[type="checkbox"] {
  accent-color: var(--brand);
  cursor: pointer;
}

/* Animation légère à l’ouverture */
@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(-4px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* --- Responsive --- */
@media (max-width: 700px) {
  .chip-wrapper {
    width: 100%;
  }
}

/* Optional: SAMW logo in white band (aligned to content right edge) */
#logo-sponsor {
  position: absolute;
  top: 15px;
  right: 20px;
  opacity: .9;
  z-index: 1000;
}

#logo-sponsor img {
  width: 120px;
  height: auto;
}

/* Laptop & desktop standard */
@media (min-width: 1000px) {
  #logo-sponsor img {
    width: 130px;
  }
}

/* Très grands écrans */
@media (min-width: 1440px) {
  #logo-sponsor img {
    width: 160px;
  }
}

.assmlogotitle {
  text-transform: uppercase;
  font-size: 0.7em;
  margin-top: 0;
  padding-left: 20px;
  margin-bottom: 7px;
  font-weight: 400;
}

/* Très grands écrans */
@media (max-width: 900px) {
  .assmlogotitle {
    font-size: 0.6em;
  }
}


#logo-cpcr {
  position: absolute;
  top: 20px;
  left: 20px;
  opacity: .9;
  z-index: 1000;
}

#logo-cpcr img {
  width: 200px;
  height: auto;
}

/* Laptop & desktop standard */
@media (min-width: 1000px) {
  #logo-cpcr img {
    width: 200px;
  }
}

/* Très grands écrans */
@media (min-width: 1440px) {
  #logo-cpcr img {
    width: 250px;
  }
}

/* =========================
   4) INFO / RESULTS AREA (inside .section-results)
========================= */
#results-column {
  background: transparent;
  height: auto;
  overflow: visible;
  position: relative;
}

#results-content {
  display: flex;
  flex-direction: column;
  gap: 24px;
  padding: 0;
}



/* Providers logos band */

/* “How it works” */
#search-instruction ul {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  list-style: none;
  padding: 0;
  margin: 0;
}


/* Intro / About cards */
#result-description,
#credits,
#search-instruction,
#target-audience {
  max-width: 860px;
  margin: 0 auto;
  padding: 24px 0;
  border-top: 4px solid white;
  color: var(--brand);
}

#search-instruction h2,
#target-audience h2,
#result-description h2,
#credits h2 {
  font-size: 20px;
  font-weight: 700;
  margin: 20px 0 10px 0;
}

#search-instruction p,
#target-audience p,
#result-description p,
#credits p,
#search-instruction ul,
#target-audience ul p {
  font-size: 15px;
  line-height: 1.5;
  margin: 0 0 8px;
  color: var(--brand);
}

/* Dynamic containers */
#result-count {
  display: none;
  font-size: .9em;
  color: #aaa;
  margin-bottom: 10px;
  text-align: right;
}

#ranking {
  flex-grow: 1;
}

#result-footer {
  margin-top: auto;
  padding: 20px 0;
  font-size: .9em;
  color: #333;
  line-height: 1.5;
  background: transparent;
}

#credits img {
  float: left;
  margin-right: 20px;
}

.textSBP {
  margin-top: 20px;
}

/* =========================
   5) RESULT CARDS (services)
========================= */
.service-result {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  background: #fff;
  padding: 24px;
  padding-top: 15px;
  position: relative;
  border: 1px solid var(--line);
  box-shadow: var(--shadow-soft);
}

.service-main {
  display: flex;
  justify-content: space-between;
  gap: 30px;
  flex-wrap: wrap;
}

.service-body {
  display: flex;
  flex-direction: row;
  gap: 2em;
  align-items: flex-start;
}

.service-header {
  display: flex;
  flex-direction: column;
  gap: 5px;
  margin-bottom: 5px;
}

.service-reginfra {
  font-size: .8em;
  font-weight: 300;
  text-transform: uppercase;
  color: var(--ink);
  max-width: calc(100% - 130px);
}


.service-reginfra {
  position: relative;
  min-height: 30px;
  display: flex;
  align-items: center;
}

.service-reginfra img.logo_infra {
  height: 50px;
  /*max-width: 80px;*/
  margin-right: 15px;

}

/*Boutons documents*/

/* Bloc complet Documents */
.info-block.documents {
  margin-top: 8px;
}

.info-block.documents .info-value {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: center;
}

/* Style des liens individuels */
.info-block.documents .itemLink {
  display: inline-block;
  padding: 0 12px 0 20px;
  background: white;
  color: var(--brand);
  /*font-size: 0.85rem;*/
  font-weight: 600;
  text-decoration: none;
  line-height: 1.4;
  transition: all 0.2s ease;
  white-space: nowrap;
  opacity: 1;
  overflow-wrap: anywhere;
  word-break: break-word;
  min-width: 0;
  max-width: 100%;
}

.info-block.documents a.itemLink {
  overflow-wrap: anywhere;
  word-break: break-word;
  white-space: normal;
  min-width: 0;
  max-width: 100%;
  display: inline-block;
  /* nécessaire pour appliquer max-width */
}


.info-block.documents .itemLink::before {
  content: "";
  display: inline-block;
  width: 15px;
  height: 15px;
  background: url(../images/file-download_blue.png) no-repeat center center;
  background-size: contain;
  flex-shrink: 0;
}



/* Hover */
.info-block.documents .itemLink:hover {
  text-decoration: underline;
}

/* Active (click) */
.info-block.documents .itemLink:active {
  transform: translateY(0);

}

.info-block.documents {
  margin-top: 0;
}

/*fin documents*/


.service-name {
  font-weight: 700;
  font-size: 1.25em;
  margin-bottom: 5px;
  margin-top: 10px;
}

.service-description {
  font-size: .95em;
  color: var(--ink);
  line-height: 1.45;
  margin-bottom: 10px;
  flex: 2;
  white-space: pre-wrap;
}

/* Tags */
.service-type {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 10px;
}

.service-type span {
  background: #EFF6FF;
  color: #0B66FF;
  border: 1px solid #D6E4FF;
  border-radius: 999px;
  padding: 6px 10px;
  font-size: 12px;
  font-weight: 700;
  white-space: nowrap;
}

/* Right column info */
.service-info {
  font-size: .8em;
  color: var(--ink);
  margin-top: 5px;
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 15px;
  min-width: 200px;
}

.info-block {
  display: flex;
  flex-direction: column;
}

.info-block .info-label {
  font-weight: 400;
  font-size: .6rem;
  text-transform: uppercase;
  color: #909090;
  margin-bottom: 4px;
  letter-spacing: .1em;
  padding-bottom: 3px;
  border-bottom: 1px solid #bcbcbc;
}

.info-block .info-value {
  word-break: break-word;
  overflow-wrap: anywhere;
}

.info-block .info-value a {
  color: var(--brand);
  font-weight: 600;
  text-decoration: none;
  display: block;
  position: relative;
  padding-left: 1.4em;
  overflow-wrap: anywhere;
}

.info-block .info-value a::before {
  content: "→";
  position: absolute;
  left: 0;
  color: var(--brand);
  line-height: 1;
}

.info-block .info-value a:hover {
  text-decoration: underline;
}

.itemLink a:empty {
  display: none;
}


.toggle {
  background: none;
  border: none;
  color: var(--brand);
  cursor: pointer;
  font-size: 0.9em;
  text-decoration: underline;
  display: block;
  width: 100%;
  order: 1;
  margin-top: -20px;
}



/* Explain button */
.explanation-btn {
  position: absolute;
  top: 12px;
  right: 12px;
  padding: 8px 12px;
  background: #F8FAFF;
  color: var(--brand);
  font: 700 11px/1 "Inter", Arial, sans-serif;
  border: 1px solid var(--brand);
  border-radius: 9999px;
  cursor: pointer;
  opacity: 1;
  transition: all .2s ease;
}

.explanation-btn::after {
  content: "Why this result";
}

.explanation-btn:hover {
  background: #EFF6FF;
}

/* Explain panel */
.service-wrapper {
  margin-bottom: 24px;
}

.explanation {
  max-height: 0;
  overflow: hidden;
  opacity: 0;
  transition: max-height .4s ease, opacity .4s ease, padding .4s ease;
  padding-top: 0;
  margin-top: 0;
}

.explanation.loading.open {
  max-height: 600px;
}

.explanation.open {
  opacity: 1;
  padding-left: 24px;
  max-height: 600px;
}

.explanation-text {
  font-style: italic;
  width: 90%;
  font-size: .85em;
  line-height: 1.5;
}

/* Skeleton */
.loader-label {
  font-size: .8em;
  color: #000;
  font-weight: 700;
  text-transform: uppercase;
  margin-bottom: 5px;
  border-left: 1px solid #000;
  padding-top: 25px;
  padding-left: 10px;
}

.loader-label::before {
  content: "?";
  margin-left: -21px;
  margin-right: 5px;
  display: inline-block;
  height: 20px;
  min-width: 20px;
  background: #fff;
  color: #000;
  font-size: 11px;
  font-family: Arial, sans-serif;
  font-weight: bold;
  text-align: center;
  line-height: 20px;
  border: 1px solid #000;
  border-radius: 9999px;
}

.skeleton-line {
  height: 12px;
  border-radius: 4px;
  margin-bottom: 10px;
  background: linear-gradient(90deg, #ebebeb 25%, #dcdcdc 50%, #ebebeb 75%);
  background-size: 200% 100%;
  animation: shimmer 3s linear infinite;
}

.skeleton-line.line1 {
  width: 80%;
}

.skeleton-line.line2 {
  width: 95%;
}

.skeleton-line.line3 {
  width: 70%;
}

@keyframes shimmer {
  0% {
    background-position: -200% 0;
  }

  100% {
    background-position: 200% 0;
  }
}

/* Load more */
.splash .load-more {
  display: none;
}

.splash h2#result-title {
  display: none;
}

.load-more {
  display: block;
  margin: 10px auto 24px;
  padding: 12px 18px;
  background: var(--brand);
  color: #fff;
  border: 0;
  border-radius: 999px;
  font-weight: 700;
  box-shadow: var(--shadow-soft);
  cursor: pointer;
}

.load-more:hover {
  filter: brightness(.96);
}




/* =========================
   6) FORMS / SELECTS
========================= */
select {
  appearance: none;
  background: #fff;
  border: 1px solid #ccc;
  border-radius: 4px;
  padding: 8px 12px;
  font-size: 1em;
  color: #333;
  box-shadow: 0 1px 2px rgba(0, 0, 0, .1);
  outline: none;
  transition: border-color .2s ease, box-shadow .2s ease;
  cursor: pointer;
  position: relative;
  background-image: url("data:image/svg+xml;utf8,<svg fill='%23007bff' height='20' viewBox='0 0 24 24' width='20' xmlns='http://www.w3.org/2000/svg'><path d='M7 10l5 5 5-5z'/></svg>");
  background-repeat: no-repeat;
  background-position: right 10px center;
  background-size: 20px;
  padding-right: 30px;
}

select:hover {
  border-color: #007bff;
}

select:focus {
  border-color: #007bff;
  box-shadow: 0 0 4px rgba(0, 123, 255, .5);
}

#request-selector label {
  margin-right: 10px;
  white-space: nowrap;
  display: inline-block;
  vertical-align: middle;
  font-size: .9em;
}

#request-selector select {
  display: inline-block;
  vertical-align: middle;
  font-size: .9em;
  margin-right: 15px;
}

/* =========================
   7) VISIBILITY LOGIC (home vs results)
   - #layout-container has class .splash on home
========================= */
/* Default hidden */
#search-instruction,
#target-audience,
#result-description,
#logos,
#credits {
  display: none;
}

/* Visible on splash (home) */
#layout-container.splash #search-instruction,
#layout-container.splash #target-audience,
#layout-container.splash #result-description,
#layout-container.splash #logos,
#layout-container.splash #credits {
  display: block;
}

/* =========================
   8) RESPONSIVE
========================= */
@media (min-width:901px) and (max-height:640px) {
  #request-selector h2 {
    margin-bottom: 30px;
    margin-top: 15px;
  }

  #search-instruction {
    font-size: .8em;
  }
}

@media (max-width:900px) {

  /* stack paddings */
  .section-recherche,
  .section-results {
    padding: 80px 0 50px;
  }

  /* icons off on small */
  #request-selector::before,
  #request-selector::after {
    display: none;
  }



  /* container padding */
  #layout-container {
    padding: 0 var(--gutter) 24px;
  }

  #filters-column,
  #results-column {
    width: 90%;
    position: initial;
  }

  #request-selector {
    width: 90%;
  }

  #filters-column h2 {
    font-size: 2rem;
  }


  /* SAMW in white band: unfix */
  .section-recherche #logo-sponsor {
    position: static;
    text-align: right;
    margin-bottom: 8px;
  }

  /* keep providers logos visible on mobile */
  #logos {
    display: none;
  }

  .splash #logos {
    display: block;
  }

  #layout-container #filters-column h2 {
    margin-top: 70px;
    font-size: 1.4em;
  }

  #layout-container.splash #filters-column h2 {
    margin-top: 80px;
    font-size: 1.7em;
  }


}



/* Stack result columns on mobile */
@media (max-width: 900px) {
  .service-main {
    display: flex;
    flex-direction: column;
    /* stack */
    gap: 12px;
  }

  /* ensure the right column can shrink and take full width */
  .service-info {
    order: 2;
    /* goes below the description */
    width: 100%;
    min-width: 0;
    /* override previous 200px */
  }

  .service-description {
    order: 1;
    width: 100%;
  }

  /* tidy inner blocks so content wraps nicely */
  .info-block .info-value {
    word-break: break-word;
  }

  /* document tags: allow good wrapping */
  .info-block.documents .info-value {
    display: block;
  }

  .splash .section-results #logos img {
    max-height: 65px;
  }

  .splash .section-results #logos .logos-row {
    gap: clamp(14px, 4vw, 28px);
    width: 90%;
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
  }
}



@media (max-width: 900px) {
  .service-info {
    min-width: unset;
    /* in case another rule sets 200px */
  }
}




.section-results #logos {
  width: 100vw;
  position: relative;
  left: 50%;
  margin-left: -50vw;
  right: 50%;
  margin-right: -50vw;
  background: var(--bg);
  /* gris clair */
  padding: 28px 0 40px;
  position: relative;
  overflow: hidden;
  padding-bottom: 44px;
  /* room for the scroll hint */
}

@media (max-width: 1100px) {
  .section-results #logos {
    padding: 10px 0 30px;
  }
}


/* Contraindre l'intérieur à ta grille max */
.section-results #logos .logos-label,
.section-results #logos .logos-row {
  max-width: var(--maxw);
  padding: 0 var(--gutter);
  margin: 0 auto;
}

.section-results #logos .logos-label {
  text-align: center;
  margin-bottom: 1vh;
  color: var(--brand);
}

.section-results #logos .logos-label h2 {
  font-weight: 300;
  font-size: clamp(1.2em, 1.2vw, 1.5em);
}


.section-results #logos .logos-row {
  display: grid;
  /*grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));*/
  place-items: center;
  gap: clamp(16px, 3vw, 28px);

  width: 100%;
  max-width: var(--maxw);
  padding: 0 var(--gutter) 50px;
  margin: 0 auto;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

/* tablette / petit laptop: 3 colonnes => 3 + 2 */
@media (min-width: 700px) {
  .section-results #logos .logos-row {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

/* laptop et +: 5 colonnes => 1 ligne */
@media (min-width: 1100px) {
  .section-results #logos .logos-row {
    grid-template-columns: repeat(5, minmax(0, 1fr));
  }
}

.section-results #logos img {
  height: clamp(45px, 3.8vw, 60px);
  width: auto;
  max-width: 220px;
  /* évite qu’un logo s’étire trop dans une colonne large */
  object-fit: contain;
}

.section-results #logos img.sphn {
  height: clamp(50px, 3.8vw, 70px);
}

/* Forcer 5 logos sur une ligne (desktop/laptop) */
@media (min-width: 1024px) {
  .section-results #logos .logos-row {
    grid-template-columns: repeat(5, minmax(0, 1fr));
  }
}

@media (max-width: 1023px) {
  .section-results #logos .logos-row {
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  }
}

/* Scroll hint visible sur tous les écrans */
.section-results #logos .scroll {
  position: absolute;
  left: 50%;
  bottom: 12px;
  transform: translateX(-50%);
  margin: 0;
  text-align: center;
  font-size: .9rem;
  color: var(--brand);
  letter-spacing: .05em;
  opacity: .9;
  z-index: 1;
}

.section-results #logos .scroll::after {
  content: "";
  display: block;
  width: 12px;
  height: 12px;
  margin: 6px auto 0;
  border-right: 2px solid var(--muted);
  border-bottom: 2px solid var(--muted);
  transform: rotate(45deg);
  animation: chevronPulse 1.6s ease-in-out infinite;
}

@keyframes chevronPulse {

  0%,
  100% {
    transform: rotate(45deg) translateY(0);
    opacity: .85;
  }

  50% {
    transform: rotate(45deg) translateY(2px);
    opacity: 1;
  }
}

/* === État desktop plein écran === */
@media (min-width: 1024px) {

  /* Make splash view fill the viewport and allow the hero to flex */
  #layout-container.splash {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
  }

  #layout-container.splash .section-recherche {
    min-height: calc(100vh - 30vh);
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 0;
  }

  #layout-container.splash .section-results #logos {
    flex-shrink: 0;
    height: 28vh;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    padding: 0;

  }

}

/* === État desktop plein écran === */
@media (min-width: 1024px) and (max-width: 1200px) {

  #layout-container.splash .section-recherche {
    min-height: calc(100vh - 25vh);
  }

  #layout-container.splash .section-results #logos {
    height: 23vh;
  }

}

@media (prefers-reduced-motion: reduce) {
  .section-results #logos .scroll::after {
    animation: none !important;
  }
}








/*TESTS*/

.filters-test {display: none;}



@media (hover: none) and (pointer: coarse) {

  .filters-test {display: inherit;}

  /* zone de test */
.filters-test{
  border-top: 1px solid #ddd;
  border-bottom: 1px solid #ddd;
  padding: 8px 0;
}

/* conteneur scrollable */
.filters-scroll{
  display: flex;
  flex-direction: row;
  flex-wrap: nowrap;

  overflow-x: auto;
  overflow-y: hidden;

  padding-left: 16px;
  padding-right: 16px;

  gap: 8px;

  -webkit-overflow-scrolling: touch;
  justify-content: flex-start;
}

/* les blocs */
.filter-chip{
  flex: 0 0 auto;
  padding: 8px 14px;
  border-radius: 999px;
  border: 1px solid #ccc;
  background: #f7f7f7;
  font-size: 14px;
  white-space: nowrap;
  cursor: pointer;
}

/* scrollbar masquée */
.filters-scroll::-webkit-scrollbar{
  display: none;
}

  #filter-overlay {
    position: fixed;
    inset: 0;
    background: white;
    z-index: 9999;
    display: flex;
    flex-direction: column;
  }

  #filter-overlay[hidden] {
    display: none;
  }

  .filter-overlay-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px;
    border-bottom: 1px solid #ddd;
    font-weight: 600;
  }

  .filter-overlay-content {
    padding: 16px;
    overflow-y: auto;
  }

  .filter-overlay-content label {
    display: block;
    padding: 12px 0;
    border-bottom: 1px solid #eee;
  }

}