/* The directory logo row (content/directories.mjs, directoriesHtml()).
   One reusable block: "Reconnu par les plus grands répertoires du pays" and
   one logo per LIVE listing, each opening Duo Vert's own listing in a new tab.
   Every logo stays in its own brand colours at all times, never grey
   (Emile, 2026-11-18); every logo gets about the same visual weight (same
   area, not same height), so a square badge and a long wordmark read as
   equals. */
.dv-dirs { --dv-dir-area: 2300; --dv-dir-gap: 18px 34px; }
.dv-dirs-line {
  margin: 0 0 14px !important;
  font: 600 15px/1.35 'Inter', system-ui, sans-serif;
  color: #4f6958;
  text-wrap: balance;
}
.dv-dirs-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--dv-dir-gap);
}
.dv-dirs-list li { display: flex; margin: 0; padding: 0; }
.dv-dir {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-height: 44px;
  padding: 0 2px;
  text-decoration: none;
  border-radius: 8px;
  -webkit-tap-highlight-color: transparent;
}
.dv-dir img {
  display: block;
  width: auto;
  height: clamp(18px, calc(sqrt(var(--dv-dir-area) * var(--k, 1) / var(--ar, 2)) * 1px), 46px);
  transition: transform 160ms cubic-bezier(0.23, 1, 0.32, 1);
}
.dv-dir-word { font: 700 15px/1 'Outfit', system-ui, sans-serif; color: #5a3d2b; }
.dv-more-narrow { display: none; }
.dv-dir:focus-visible { outline: 3px solid #4caf50; outline-offset: 3px; }
.dv-dir:active img { transform: scale(0.96); }
@media (hover: hover) and (pointer: fine) {
  .dv-dir:hover img { transform: translateY(-2px); }
}
.dv-dir-more {
  min-width: 44px;
  justify-content: center;
  font: 800 15px/1 'Outfit', system-ui, sans-serif;
  color: #2f6b3f;
}

/* Full row: every listing, centred, used as its own band. */
.dv-dirs-full { text-align: center; }
.dv-dirs-full .dv-dirs-list { justify-content: center; }

/* Mini: one line under a hero headline, smaller logos. */
.dv-dirs-mini { --dv-dir-area: 1500; --dv-dir-gap: 6px 18px; }
.dv-dirs-mini .dv-dirs-line { font-size: 14px; margin-bottom: 4px !important; }
/* On a photo: a frosted white strip so the logos keep their contrast. */
.dv-dirs-glass {
  display: inline-block;
  padding: 10px 14px 6px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.9);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  box-shadow: 0 10px 30px -14px rgba(10, 20, 14, 0.5);
}
.dv-dirs-glass .dv-dirs-line { color: #34463b; }

@media (max-width: 767px) {
  .dv-dirs { --dv-dir-area: 1700; --dv-dir-gap: 10px 22px; }
  .dv-dirs-mini { --dv-dir-area: 900; --dv-dir-gap: 4px 10px; }
  .dv-dirs-mini .dv-dirs-list { flex-wrap: nowrap; }
  .dv-dirs-mini .dv-dir-more { white-space: nowrap; font-size: 14px; padding: 0; }
  /* one line at 360px: the last logo steps out, the link counts it */
  .dv-dirs-mini li:nth-last-child(2):not(:first-child) { display: none; }
  .dv-dirs-mini .dv-more-wide { display: none; }
  .dv-dirs-mini .dv-more-narrow { display: inline; }
}
@media (prefers-reduced-motion: reduce) {
  .dv-dir img { transition: none; }
}
