/**
 * 1. The overlay captures mouse events even if it's empty space. To counter-act this,
 *    we remove all pointer events from the overlay then add them back on the
 *    individual widgets.
 */

.mapWidgetOverlay {
  position: absolute;
  z-index: $euiZLevel1;
  top: $euiSizeM;
  right: $euiSizeM;
  bottom: $euiSizeM;
  left: 0; // Necessary to have a left value for IE
  pointer-events: none; /* 1 */
}

.mapWidgetOverlay__layerWrapper {
  align-items: flex-end;
  width: $euiSize * 20;
  min-height: 0; // Fixes scroll in Firefox
}

.mapWidgetControl__headerFlexItem {
  flex-shrink: 0;
}

.mapWidgetControl {
  max-height: 100%;
  width: 100%;
  overflow: hidden;
  padding-bottom: $euiSizeS; // ensures the scrollbar doesn't appear unnecessarily because of flex group negative margins
  // sass-lint:disable-block no-important
  border-color: transparent !important;
  flex-direction: column;
  display: flex;
  pointer-events: all; /* 1 */

  &.mapWidgetControl-hasShadow {
    @include euiBottomShadowLarge;
  }
}

.mapWidgetControl__header {
  padding: 0 $euiSize;
  flex-shrink: 0;
  text-transform: uppercase;
}
