/*
 * Style overrides for Devsite directory framebox
 */

.devsite-directory__content {
  -webkit-box-align: stretch;
  -ms-flex-align: stretch;
  align-items: stretch;
}

.devsite-directory__content__item {
  background-color: #fff;
  -webkit-box-shadow: 0 2px 5px 0 rgba(0, 0, 0, .26), 0 2px 5px 0 rgba(0, 0, 0, .26);
  box-shadow: 0 2px 5px 0 rgba(0, 0, 0, .26), 0 2px 5px 0 rgba(0, 0, 0, .26);
  -ms-flex-preferred-size: calc((100% - (16px * 3)) / 4);
  flex-basis: calc((100% - (16px * 4)) / 4);
  margin: 0 8px 16px;
  padding: 0;
}

/* remove default border */
.devsite-directory__content__item:not(:last-child) {
  border-bottom: none;
}

.devsite-directory__wrapper {
  padding: 32px 12px 0;
}

/*
 * Custom styles for experts directory items
 */

.experts-directory__item__profile {
  padding: 20px;
  text-align: center;
}

.experts-directory__item__profile-pic-holder {
  background-size: cover;
  border-radius: 50%;
  display: block;
  height: 100px;
  margin: 0 auto 20px;
  overflow: hidden;
  position: relative;
  width: 100px;
}

.experts-directory__item__name {
  margin: 0 0 4px;
}

.experts-directory__item__location,
.experts-directory__item__experience {
  font: 400 14px/20px Roboto, sans-serif;
}

/*
 * Overrides for items in the map info window
 */

.experts-directory__item--map {
  width: 240px;
}

.experts-directory__item--map .experts-directory__item__profile {
  padding: 10px;
}

.experts-directory__item--map .experts-directory__item__profile-pic-holder {
  height: 80px;
  margin-bottom: 10px;
  width: 80px;
}

/*
 * Media queries are based on the iframe's max width, not the top document
 */

@media screen and (max-width: 1000px) {
  .devsite-directory__content__item {
    flex-basis: calc((100% - (16px * 3)) / 3);
  }
}

@media screen and (max-width: 720px) {
  .devsite-directory__content__item {
    flex-basis: calc((100% - 16px * 2) / 2);
  }
}

@media screen and (max-width: 500px) {
  .devsite-directory__content__item {
    flex-basis: calc(100% - 16px);
  }
}
