/* The theme renderer repaints the project gallery after fetching its registry.
   Scope the published image and caption to the linked project in either language. */
.te-hub-project-image[href$="/atlas/zapis/improve-river-life/"] {
  --project-img: url("/assets/eko-project-photos-20261104/jadro-gaspina-mlinica-800.webp");
  --project-caption: "AI ilustracija · Ekologija.hr";
  --project-alt: "Jadro ispred Gašpine mlinice u Solinu.";
}
html[lang^="en"] .te-hub-project-image[href$="/atlas/zapis/improve-river-life/"] {
  --project-caption: "AI illustration · Ekologija.hr";
  --project-alt: "The Jadro River at Gašpina watermill, Solin.";
}
.te-hub-project-image[href$="/atlas/zapis/improve-river-life/"] img { content: var(--project-img); }
@supports (content: url("image.webp") / "description") {
  .te-hub-project-image[href$="/atlas/zapis/improve-river-life/"] img { content: var(--project-img) / var(--project-alt); }
}
.te-hub-project-image[href$="/atlas/zapis/improve-river-life/"] .te-hub-image-note { font-size: 0; }
.te-hub-project-image[href$="/atlas/zapis/improve-river-life/"] .te-hub-image-note::before { content: var(--project-caption); font-size: .65rem; }
@media (max-width: 620px) and (max-resolution: 1.5dppx) {
  .te-hub-project-image[href$="/atlas/zapis/improve-river-life/"] { --project-img: url("/assets/eko-project-photos-20261104/jadro-gaspina-mlinica-480.webp"); }
}

/* European Amazon: independently commissioned AI illustration. */
.te-hub-project-image[href$="/atlas/zapis/europska-amazona/"] {
  --project-img: url("/assets/eko-project-photos-20261104/usce-drave-u-dunav-aljmas-ai-800.webp");
  --project-caption: "Ušće Drave u Dunav · AI ilustracija";
  --project-alt: "AI ilustracija ušća Drave u Dunav kod Aljmaša i okolne nizinske poplavne šume.";
}
html[lang^="en"] .te-hub-project-image[href$="/atlas/zapis/europska-amazona/"] {
  --project-caption: "Drava–Danube confluence · AI illustration";
  --project-alt: "AI illustration of the Drava–Danube confluence near Aljmaš and the surrounding lowland floodplain forest.";
}
.te-hub-project-image[href$="/atlas/zapis/europska-amazona/"] img { content: var(--project-img); }
@supports (content: url("image.webp") / "description") {
  .te-hub-project-image[href$="/atlas/zapis/europska-amazona/"] img { content: var(--project-img) / var(--project-alt); }
}
.te-hub-project-image[href$="/atlas/zapis/europska-amazona/"] .te-hub-image-note { font-size: 0; max-width: calc(100% - 16px); }
.te-hub-project-image[href$="/atlas/zapis/europska-amazona/"] .te-hub-image-note::before { content: var(--project-caption); font-size: .65rem; line-height: 1.35; }
@media (max-width: 620px) and (max-resolution: 1.5dppx) {
  .te-hub-project-image[href$="/atlas/zapis/europska-amazona/"] { --project-img: url("/assets/eko-project-photos-20261104/usce-drave-u-dunav-aljmas-ai-480.webp"); }
}

/* Keep the two project illustrations readable without a badge behind the words. */
.te-hub-project-image:is([href$="/atlas/zapis/europska-amazona/"], [href$="/atlas/zapis/improve-river-life/"])::after {
  content: "";
  position: absolute;
  pointer-events: none;
  inset: auto 0 0;
  height: 2.45rem;
  background: linear-gradient(to bottom, transparent, rgba(16, 23, 19, .30) 48%, rgba(16, 23, 19, .72));
}
.te-hub-project-image:is([href$="/atlas/zapis/europska-amazona/"], [href$="/atlas/zapis/improve-river-life/"]) .te-hub-image-note {
  z-index: 1;
  right: .55rem;
  bottom: .32rem;
  max-width: calc(100% - 1.1rem);
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  color: #e3e6e4;
  font-weight: 400;
  text-shadow: 0 1px 2px rgba(0, 0, 0, .75);
}
.te-hub-project-image:is([href$="/atlas/zapis/europska-amazona/"], [href$="/atlas/zapis/improve-river-life/"]) .te-hub-image-note::before {
  font-size: .625rem;
  line-height: 1.25;
}
