.ce-intext.ce-left .ce-gallery {
  margin-right: 20px;
  margin-bottom: 10px;
}

.ce-intext.ce-right .ce-gallery {
  margin-left: 20px;
  margin-bottom: 10px;
}


/**
 * Foundation styled gallery.
 */
.gallery {
  max-width: 100%;
}

.gallery a {
  display: inline-block !important;
}

.gallery figure {
  display: block;
  margin-bottom: 15px;
  width: 100%;
}

.gallery figure a {
  max-width: 100%;
  border: 0;
  text-decoration: none;
}

.gallery figure.image img {
  width: 100%;
}

.gallery figure.image.custom-dimension img {
  width: auto;
}

.gallery figure.video .video-embed {
  width: 100%;
  height: 100%;
}

.gallery figure.video video {
  width: 100%;
  min-width: 100%;
  height: 100%;
  min-height: 100%;

  vertical-align: bottom;
  object-fit: cover;
}

.gallery figure.video iframe {
  width: 100%;
  height: 100%;

  border: none;

  vertical-align: bottom;
}

/* TextMedia with gallery below/above */
.ce-textpic.ce-below .gallery-wrap {
  margin-top: 1rem;
}

.ce-textpic.ce-center .gallery-wrap {
  display: flex;
  justify-content: center;
}

/* TextMedia with gallery in text */
.ce-textpic.ce-right.ce-intext .gallery {
  float: right;
  margin-left: 1rem;
}

.ce-textpic.ce-left.ce-intext .gallery {
  float: left;
  margin-right: 1rem;
}

.ce-textpic.ce-right.ce-intext .gallery,
.ce-textpic.ce-left.ce-intext .gallery {
  width: 300px;
}

/* TextMedia with gallery next to text */
.ce-textpic.ce-right.ce-intext.ce-nowrap .gallery {
  float: right;
  margin: 0 0 1rem 1rem;
}

.ce-textpic.ce-left.ce-intext.ce-nowrap .gallery {
  float: left;
  margin: 0 1rem 1rem 0;
}

.ce-textpic.ce-right.ce-intext.ce-nowrap .gallery,
.ce-textpic.ce-left.ce-intext.ce-nowrap .gallery {
  width: 200px;
}

/* Move top margin from header to wrapping element, so that header and images start at the same position */
.ce-textpic.ce-right.ce-intext.ce-nowrap,
.ce-textpic.ce-left.ce-intext.ce-nowrap {
  margin-top: 30px;
}

.ce-textpic.ce-right.ce-intext.ce-nowrap header h3,
.ce-textpic.ce-left.ce-intext.ce-nowrap header h3 {
  margin-top: 0;
}

/* Clear any floats afterwards */
.ce-textpic::after {
  content: "";
  clear: both;
}

@media only screen and (max-width: 47.938em) {
}

@media only screen and (max-width: 40em) {
  .ce-textpic .gallery,
  .ce-textpic .gallery {
    float: none !important;
    width: 100% !important;

    margin-left: 0 !important;
    margin-right: 0 !important;
  }
}


/**
 * TYPO3 paginator.
 */
.f3-widget-paginator {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;

  margin-bottom: 50px !important;

  font-size: 13px;
}

.f3-widget-paginator li {
  padding: 0 !important;
  margin: 0 0.25rem 0.5rem 0.25rem !important;
}

.f3-widget-paginator li a {
  display: inline-block;

  padding: 2px 10px;

  border: 1px solid #e5ebed !important;

  color: #333333;
  background-color: white;
  text-decoration: none !important;

  transition: background-color 250ms, color 250ms !important;
}

.f3-widget-paginator li a:hover {
  background-color: #4691af;
  color: white;
}

.f3-widget-paginator li.current {
  display: inline-block;

  padding: 2px 10px !important;

  border: 1px solid #e5ebed !important;
  border-bottom: 2px solid #4691af !important;

  background-color: white;
}

.f3-widget-paginator li::before,
.f3-widget-paginator li::after {
  display: none !important;
  content: "" !important;
}

.f3-widget-paginator li a:not([href]) {
  padding: 0;

  border: none !important;

  cursor: default;
}

.f3-widget-paginator li a:not([href]):hover {
  background-color: white;
  color: #333333;
}

.f3-widget-paginator li a:not([href]):focus {
  background-color: inherit;
  color: inherit;
}
