/*
 * ---------------------
 * ----- DASHBOARD -----
 * ---------------------
 **/
.dashboards-container section.dashboard-gin-panel,
.layout-builder__layout section.dashboard-gin-panel {
  border: 1px solid rgba(212, 212, 218, 0.8) !important;
  border-radius: 4px 4px 0px 0px !important;
  background-color: #fff !important;
  box-shadow: 0 0.25rem 0.625rem rgba(0, 0, 0, 0.1) !important;
  padding: 0 !important;

  /* dxpr-subtheme puts margin top in 2nd section, resulting in sections not starting uniform */
  margin-top: 0 !important;
  margin-bottom: 20px !important;
}

.dashboards-container section.dashboard-gin-panel > h2.panel__title,
.layout-builder__layout section.dashboard-gin-panel > h2.panel__title {
  background-color: #871D33;
  color: #fff;
  width: 100%;
  margin-top: 0 !important;
  padding: 0.75rem 1.25rem !important;
  font-size: 11pt;
  font-weight: 700 !important;
  height: auto !important;
  border-radius: 3.25px 3.25px 0 0;
}

.dashboards-container section.dashboard-gin-panel > div.panel__content,
.layout-builder__layout section.dashboard-gin-panel > div.panel__content {
  padding: 0 0.75rem 0.75rem 0.75rem !important;
}

.dashboards-container section.dashboard-gin-panel > div.panel__content .field__label,
.layout-builder__layout section.dashboard-gin-panel > div.panel__content .field__label {
    text-transform: none;
    background-color: #ededed;
    padding: 10px;
    color: #555555;
    font-weight: 700;
    margin-top: 1em;
}

.dashboards-container section.dashboard-gin-panel > div.panel__content .field__item,
.layout-builder__layout section.dashboard-gin-panel > div.panel__content .field__item {
    background-color: #fff;
    padding: 10px;
}

/*
 * -------------------------------------------------
 * ----- "EDIT FAVORITE LINKS (QUICKLINKS)" FORM -----
 * -------------------------------------------------
 **/
#edit-favorite-links-items-wrapper div.form-type-textfield {
  margin: 0;
  margin-bottom: 5px;
  margin-right: 7.5px;
}

#edit-favorite-links-items-wrapper div.form-type-select {
  margin: 0;
  margin-bottom: 5px;
}

#edit-favorite-links-items-wrapper div.edit-favorite-links-main {
  display: inline-flex;
  flex-direction: column;
  margin-bottom: 15px;
  border: 1px solid rgba(212, 212, 218, 0.8);
  border-radius: 2px;
  background-color: #fff;
  box-shadow: 0 0.25rem 0.625rem rgba(0, 0, 0, 0.1);
  padding: 0.75rem;
}

#edit-favorite-links-items-wrapper div.edit-favorite-links-textfields {
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  margin-bottom: 0.5rem;
}

#edit-favorite-links-items-wrapper div.edit-favorite-links-image {
  border: 1px solid rgba(212, 212, 218, 0.8);
  padding: 0.5rem;
  margin-bottom: 1rem;
  border-radius: 0.375rem;
}

#edit-favorite-links-items-wrapper div.edit-favorite-links-image legend {
  border: 0;
}

#edit-favorite-links-items-wrapper div.edit-favorite-links-image div.description {
  display: none;
}

/*
 * ---------------------------------------------
 * ----- FAVORITE LINKS (QUICKLINKS) BLOCK -----
 * ---------------------------------------------
 **/
div.favorite-links-item-container {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-start;
  container-type: inline-size;
}

a.favorite-links-item {
  aspect-ratio: 1 / 1;

  flex: 1 0 calc(50% - 1rem); /* exactly 2 items per row */
  margin: 0.5rem;
  max-width: calc(50% - 1rem);

  hyphens: auto;
  border: 7px solid #871D32;
  border-radius: 15%;
  background-color: #871D32;
  overflow: hidden;

  /*clip everything inside this a-element*/
  clip-path: inset(0 0 0 0 round 15% 15% 15% 15%);
}

@container (width > 525px) {
  div.favorite-links-item-container a.favorite-links-item {
    flex: 1 0 calc(33% - 1rem); /* exactly 3 items per row */
    margin: 0.5rem;
    max-width: calc(33% - 1rem);
  }
}
@container (width > 700px) {
  div.favorite-links-item-container a.favorite-links-item {
    flex: 1 0 calc(25% - 1rem); /* exactly 4 items per row */
    margin: 0.5rem;
    max-width: calc(25% - 1rem);
  }
}

a.favorite-links-item > div {
  height: 50%;
}

a.favorite-links-item > div.favorite-links-item-title-div {
  display: flex;
  align-items: center;
  justify-content: center;
  container-type: size;
  background-color: white;
}

a.favorite-links-item > div.favorite-links-item-title-div > h4 {
  font-size: 13cqw;
}

a.favorite-links-item > div.favorite-links-item-title-div > span {
  font-size: 8cqw;
}

a.favorite-links-item > div.favorite-links-item-img-div {
  /* center image */
  display: flex;
  align-items: center;
  justify-content: center;
}

a.favorite-links-item > div.favorite-links-item-img-div > img {
  /**
   * resize image to fit entire div
   * - if you want only the height to be clipped, leave only the 'height' option
   */
  object-fit: cover;
  width: 100%;
  height: 100%;
}

a.favorite-links-item > div.favorite-links-item-img-div > img[src=""],
a.favorite-links-item > div.favorite-links-item-img-div > img[src="/"],
a.favorite-links-item > div.favorite-links-item-img-div > img:not([src]) {
  display: none;
}

div.favorite-links-main-services {
  /* center image */
  display: flex;
  flex-direction: row;
  flex-wrap: nowrap;
  align-items: center;
  justify-content: center;
  padding: 0 1.5rem;
}

div.favorite-links-main-services > a.favorite-links-main-service-link {
  aspect-ratio: 1 / 1;

  flex: 1 0 calc(15% - 0.5rem);
  margin: 0.25rem;
  max-width: calc(15% - 0.5rem);
  background-color: #871D32;

  border-radius: 100%;

  display: flex;
  align-items: center;
  justify-content: center;

  container-type: inline-size;
}
@container (width > 525px) {
  div.favorite-links-main-services > a.favorite-links-main-service-link {
    aspect-ratio: 1 / 1;

    flex: 1 0 calc(15% - 1rem);
    margin: 0.5rem;
    max-width: calc(15% - 1rem);
    background-color: #871D32;

    border-radius: 100%;

    display: flex;
    align-items: center;
    justify-content: center;
  }
}

a.favorite-links-main-service-link > div {
  align-items: center;
  display: flex;
  justify-content: center;
}

a.favorite-links-main-service-link img{
  width: 60%;
  height: 60%;
}

div.favorite-links-block-wrapper {
  div.favorite-links-action-buttons {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;

    a.btn {
      margin: 0;
    }
  }
}

/**
 * ---------------------------------
 * ----- "ADD QUICKLINK" BLOCK -----
 * ---------------------------------
 */
/*
#add-current-link-to-quicklinks-button > button {
  background-color: #ccc;
}
*/
#block-bks-portal-theme-bksdashboardquicklinkhinzufugen {
  float: left;
  /* fixes the problem, where the breadcrumb covers this button */
  z-index: 10;
}

#block-bks-portal-theme-bksdashboardquicklinkhinzufugen button.add-current-link-to-quicklinks-button {
  display: inline-flex;
  align-items: center;
  padding: 8px 10px;
  border: 3px;
  margin: 0 0.5em 0 0;
}

#block-bks-portal-theme-bksdashboardquicklinkhinzufugen button.add-current-link-to-quicklinks-button:hover {
  background-color: #bababa;
  border-color: #bababa;
}

#block-bks-portal-theme-bksdashboardquicklinkhinzufugen button.add-current-link-to-quicklinks-button:active {
  background-color: #878787;
  border-color: #878787;
}

#block-bks-portal-theme-bksdashboardquicklinkhinzufugen button.add-current-link-to-quicklinks-button > img {
  width: 1.25em;
  height: 1.25em;
}

#block-bks-portal-theme-bksdashboardquicklinkhinzufugen button.add-current-link-to-quicklinks-button-enabled {
  background-color: #ededed;
  color: #ffffff;
}

#block-bks-portal-theme-bksdashboardquicklinkhinzufugen button.add-current-link-to-quicklinks-button-disabled {
  background-color: #ededed;
  color: #ffffff;
  text-decoration: line-through;
  /* https://stackoverflow.com/questions/3144050/use-css-to-make-a-span-not-clickable */
  /*pointer-events: none;*/
}

/**
 * ------------------------------------------
 * ----- "VIEW FAVORITE LINKS FULL" PAGE -----
 * ------------------------------------------
 */
@container (width > 900px) {
  div.favorite-links-block-wrapper-full div.favorite-links-item-container a.favorite-links-item {
    flex: 1 0 calc(20% - 1rem); /* exactly 5 items per row */
    margin: 0.5rem;
    max-width: calc(20% - 1rem);
  }
}
@container (width > 1200px) {
  div.favorite-links-block-wrapper-full div.favorite-links-item-container a.favorite-links-item {
    flex: 1 0 calc(15% - 1rem); /* exactly 6 items per row */
    margin: 0.5rem;
    max-width: calc(15% - 1rem);
  }
}

/**
 * ------------------------------------------
 * ----- "BKS DASHBOARD HOMEPAGE" BLOCK -----
 * ------------------------------------------
 */
a#bks-dashboard-homepage-block-mini-link-to-main-dashboard {
  margin: 1.0rem 0 1.0rem 0;
  background-color: #1f561a;
}

div#bks-dashboard-homepage-block-mini div.dashboard-block-action-buttons {
  visibility: hidden;
  position: absolute;
}
.layout-builder__layout,
.dashboards-container {
  div.layout section.block-bks-blocks-portal-news-job-board-block,
  div.layout section.block-bks-blocks-portal-news-bks-ticker-block,
  div.layout section.block-bks-blocks-portal-news-tech-news-block {
    div.bks-blocks-portal-news-summarized-block {
      display: flex;
      flex-direction: column;
      gap: .25rem;
    }
  }
}
