@layer shwt-widgets {
  shwt-widget-tiled-gallery {
    display: block;
    width: 100%;
    height: auto;
  }

  shwt-widget-tiled-gallery > .tiled-gallery {
    width: 100%;
    height: auto;
  }

  shwt-widget-tiled-gallery shwt-widget-grid {
    height: auto;
    overflow: visible;
  }

  shwt-widget-tiled-gallery img {
    cursor: pointer;
  }

  shwt-widget-tiled-gallery:has(> img) {
    display: flex;
    align-items: flex-start;
  }

  shwt-widget-tiled-gallery:has(> img) > img {
    flex: 1 1 0;
    min-width: 0;
  }

  shwt-widget-tiled-gallery:has(> img) > .tiled-gallery {
    flex: 0 0 0;
    min-width: 0;
    overflow: hidden;
  }
}
