/* Ultra Sonus — logos PNG transparent, anti-doublon, bascule clair/sombre */

img[src*="ultra-sonus-logo"],
img[src*="SparkyFitness.webp"],
img[data-us-logo="1"] {
  object-fit: contain !important;
  background: transparent !important;
}

.container.mx-auto .flex.items-center.gap-1 > img,
header .flex.items-center.gap-1 > img,
nav .flex.items-center.gap-1 > img {
  width: min(320px, 50vw) !important;
  height: auto !important;
  max-height: 120px !important;
  min-height: 56px !important;
}

.container.mx-auto .flex.items-center.gap-1 > :not(img),
header .flex.items-center.gap-1 > :not(img),
nav .flex.items-center.gap-1 > :not(img) {
  display: none !important;
}

/* Un seul logo dans la barre (évite doublon au clic thème) */
header .flex.items-center.gap-1 img ~ img,
.container.mx-auto .flex.items-center.gap-1 img ~ img {
  display: none !important;
}

/* Fallback CSS si JS en retard */
html[data-us-theme="light"] img[data-us-logo="1"],
html:not([data-us-theme="dark"]) img[src*="SparkyFitness"] {
  content: url("/images/ultra-sonus-logo-light.png");
}

html[data-us-theme="dark"] img[data-us-logo="1"],
html.dark img[src*="SparkyFitness"],
html.dark img[src*="ultra-sonus-logo"] {
  content: url("/images/ultra-sonus-logo-dark.png");
}

.flex.items-center.justify-center.mb-4 > img,
.flex.flex-col.items-center > img[src*="logo"] {
  width: min(400px, 92vw) !important;
  height: auto !important;
  max-height: 150px !important;
  min-height: 80px !important;
}

.flex.items-center.justify-center.mb-4 > :not(img) {
  display: none !important;
}

aside img[src*="logo"],
[data-sidebar] img[src*="logo"] {
  width: min(280px, 90%) !important;
  max-height: 110px !important;
  height: auto !important;
}
