.galleryReturn{position:static;display:flex;justify-content:flex-start;align-items:center;margin:0;padding:12px 4vw;background:transparent;color:#24231f;mix-blend-mode:normal}
.galleryReturn--bottom{padding-top:18px;padding-bottom:40px}
.galleryReturnLink{display:inline-flex;align-items:center;min-height:44px;padding:4px 0;color:inherit;text-decoration:none;font:400 13px/1.4 Arial,Helvetica,sans-serif;letter-spacing:.03em;border-bottom:1px solid transparent}
.galleryReturnLink:hover{border-bottom-color:currentColor}
.galleryReturnLink:focus-visible{outline:2px solid currentColor;outline-offset:5px}
.galleryReturnMobile{display:none}
[id^="gallery-return-"]{scroll-margin-top:100px}
@media(max-width:800px){.galleryReturn{padding:8px 22px}.galleryReturn--bottom{padding-bottom:28px}.galleryReturnDesktop{display:none}.galleryReturnMobile{display:inline}.galleryReturnLink{min-height:44px;font-size:14px}}

/* Kompakte Galerie-Uebersicht mit vollstaendigen Bildformaten. */
:is(.portfolioGrid, .homePortfolio .storyCards) {
  box-sizing: border-box;
  width: 100%;
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 40px 80px;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  column-gap: 42px;
  row-gap: 56px;
  align-items: start;
}
:is(.portfolioGrid, .homePortfolio .storyCards) > :is(.portfolioCard, .storyCard),
:is(.portfolioGrid, .homePortfolio .storyCards) > :is(.portfolioCard, .storyCard):nth-child(even) {
  min-width: 0;
  margin-top: 0;
  text-align: center;
}
:is(.portfolioGrid, .homePortfolio .storyCards) :is(.portfolioCard, .storyCard) figure {
  height: 320px !important;
  aspect-ratio: auto !important;
  margin: 0;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  overflow: visible;
}
:is(.portfolioGrid, .homePortfolio .storyCards) :is(.portfolioCard, .storyCard) img {
  display: block;
  width: auto !important;
  height: auto !important;
  max-width: 100%;
  max-height: 100% !important;
  aspect-ratio: auto !important;
  object-fit: contain !important;
  transform: none;
}
:is(.portfolioGrid, .homePortfolio .storyCards) :is(.portfolioCard, .storyCard) :is(h2, h3) {
  font-size: clamp(24px, 2.4vw, 32px);
  line-height: 1.18;
  margin: 18px 0 0;
  overflow-wrap: anywhere;
}
:is(.portfolioGrid, .homePortfolio .storyCards) :is(.portfolioCard, .storyCard) p { line-height: 1.65; }
@media (min-width: 701px) and (max-width: 1000px) {
  :is(.portfolioGrid, .homePortfolio .storyCards) { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 42px 32px; }
  :is(.portfolioGrid, .homePortfolio .storyCards) :is(.portfolioCard, .storyCard) figure { height: 300px !important; }
}
@media (max-width: 700px) {
  :is(.portfolioGrid, .homePortfolio .storyCards) { max-width: 420px; grid-template-columns: 1fr; padding: 0 26px 64px; row-gap: 40px; }
  :is(.portfolioGrid, .homePortfolio .storyCards) :is(.portfolioCard, .storyCard) figure { height: auto !important; align-items: center; }
  :is(.portfolioGrid, .homePortfolio .storyCards) :is(.portfolioCard, .storyCard) img { max-height: 340px !important; }
  :is(.portfolioGrid, .homePortfolio .storyCards) :is(.portfolioCard, .storyCard) :is(h2, h3) { font-size: 28px; margin-top: 14px; }
}

/* Zurueckhaltende Beschriftung; die ganze Vorschau bleibt anklickbar. */
:is(.portfolioGrid, .homePortfolio .storyCards) :is(.portfolioCard, .storyCard) :is(h2, h3) {
  font-size: 16px !important;
  line-height: 1.25;
  margin-top: 14px;
}
:is(.portfolioGrid, .homePortfolio .storyCards) :is(.portfolioCard, .storyCard) p {
  font-size: 10px;
  letter-spacing: .10em;
  margin: 8px 0 0;
}
:is(.portfolioGrid, .homePortfolio .storyCards) :is(.portfolioCard, .storyCard) .storyOpen { display: none; }
@media (max-width: 700px) {
  :is(.portfolioGrid, .homePortfolio .storyCards) :is(.portfolioCard, .storyCard) :is(h2, h3) { font-size: 15px !important; }
}

/* Startseite: identische Kacheln innerhalb der bestehenden Seitenraender. */
.homePortfolio .storyCards { max-width: 1100px; padding: 0; }
.homePortfolio .storyCard > div { display: block; padding-top: 0; text-align: center; }
.homePortfolio .storyCard > div > span { display: none; }
.homePortfolio .storyCard h3 { font-weight: 400; }
@media (max-width: 700px) { .homePortfolio .storyCards { max-width: 368px; } }
