/* @todo font sizes as root variables*/
[data-component-id="theodor:teaser_revised"] {

  container-name: teaser_revised;
  container-type: inline-size;

  & .part--teaser__link_wrapper {
    display: flex;
    flex-direction: column;
    text-decoration: none;
    background-color: var(--brand-colors-boell-lightgray);
    padding: 1.75rem;
    color: var(--brand-colors-gray-dark-2);
    @container teaser_revised (min-width: 380px) {
      flex-direction: row;
      margin-bottom: 1.75rem;
    }
  }

  & .part--teaser__image {
    width: 100%;
    margin-bottom: 2.5rem;
    aspect-ratio: 1 / 1;
    @container teaser_revised (min-width: 380px) {
      aspect-ratio: auto;
      flex-basis: 20%;
      margin-inline-end: 1.5rem;
      margin-bottom: 0;
      flex-shrink: 0;
    }
  }

  & .field--name-field-media-image {
    width: 12.6rem;
    margin-inline: auto;

    > img {
      width: 100%;
    }
  }


  & .part--teaser__texts {

  }

  & .part--teaser__texts-with-image {

  }

  & .part--teaser__texts-without-image {

  }

  & .part--teaser__text,
  & .part--teaser__text p {
    display: none;
    font-weight: 400;
    @container teaser_revised (min-width: 380px) {
      display: block;
    }
    @container teaser_revised (min-width: 700px) {
      font-size: 1.06666rem;
      line-height: 1.4;
    }
  }


  & .part--teaser__title {
    margin-block: 0;
    font-size: 1.333rem;
    line-height: 1.35;
    font-weight: bold;
    @container teaser_revised (min-width: 380px) {
      margin-block-end: 1rem;
    }
    @container teaser_revised (min-width: 700px) {
      font-size: 1.3333rem;
      line-height: 1.3;
    }
  }

  & .part--teaser__genre {
    font-weight: 600;
    margin-bottom: 7px;
  }

  & .part--teaser__subtitle {
    font-weight: 400;
    font-size: 1.2rem;
    line-height: 1.3rem;
    @container teaser_revised (min-width: 380px) {
      display: inline-block;
      font-weight: 400;
    }
    @container teaser_revised (min-width: 700px) {
      font-size: 1.3333rem;
      line-height: 1.3;
    }
  }

  & .part--teaser__header {
    display: flex;
    flex-direction: column;
    @container teaser_revised (min-width: 380px) {
      flex-direction: row;
      justify-content: space-between;
    }
  }


  & .part--teaser__core {

  }

  & .part--teaser__buttons {
    display: none;
    @container teaser_revised (min-width: 380px) {
      display: flex;
      width: 20%;
      justify-content: flex-end;
    }
  }

  & .part--teaser__price {
    display: none;
    font-size: 1.125rem;
    line-height: 1.375rem;
    margin-top: 0.4rem;
  }

  & .part--teaser__meta {
    display: none;
  }

  & .part--teaser__button {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 2rem;
    width: 2rem;
    padding: 0.125rem;
    margin-left: 1rem;
    text-align: center;
    border: 1px solid var(--brand-colors-gray-dark-2);
    cursor: pointer;
    color: var(--brand-colors-gray-dark-2);
    transition: color 0.3s ease-in-out, background-color 0.3s ease-in-out;
    &:hover {
      background-color: var(--brand-colors-gray-dark-2);
      color: var(--brand-colors-gray-light-2) !important;
      * {
        color: var(--brand-colors-gray-light-2);
        transition: none;
      }
    }
  }

  & .download_label {
    display: none;
  }

  & .button-product {
    margin: 0;
    padding: 0;
    background: transparent;
  }

  & a {
    text-decoration: none;

    * {
      transition: color 0.3s ease-in-out;
    }

    & .field--name-field-media-image > img {
      transition: opacity 0.3s ease-in-out;
    }

    &:hover {
      color: var(--brand-colors-gray-1);
      * {
        color: var(--brand-colors-gray-1);
      }
      & .field--name-field-media-image > img {
        opacity: 0.6;
      }
    }
  }
}

/* We want almost the same Teaser in Grids, but without the buttons */

.grid-box-inner > [data-component-id="theodor:teaser_revised"],
.grid-box-node_by_selection > .grid-box-inner > .views-row > [data-component-id="theodor:teaser_revised"] {
  & .part--teaser__image {
    aspect-ratio: auto;
    flex-basis: 33%;
    gap: 2rem;
    flex-shrink: 0;
  }
  & .field--name-field-media-image {
    @container teaser_revised (min-width: 380px) {
      width: 100%;
    }
  }
  & .part--teaser__buttons {
    display: none;
  }
  & .part--teaser__title {
    @container teaser_revised (min-width: 700px) {
      font-size: 2.133rem;
      line-height: 1.2;
    }
  }
  & .part--teaser__subtitle {
    @container teaser_revised (min-width: 700px) {
      font-size: 2.133rem;
      line-height: 1.2;
    }
  }
  & .part--teaser__text,
  & .part--teaser__text p {
    display: none;
    font-weight: 400;
    @container teaser_revised (min-width: 380px) {
      display: block;
    }
    @container teaser_revised (min-width: 700px) {
      font-size: 1.125rem;
      line-height: 1.5rem;
    }
  }
}

.grid-slot:has([data-component-id="theodor:teaser_revised"]) {
  background-color: var(--brand-colors-boell-lightgray);
}

.grid-slot-1d1:has([data-component-id="theodor:teaser_revised"]) {
  background: none;
}

.part--teaser__overlay {
  position: fixed;
  width: 100%;
  height: 100%;
  top: 0;
  left: 0;
  background: rgba(0, 0, 0, 0.3);
  display: -webkit-box;
  display: -webkit-flex;
  display: -ms-flexbox;
  display: flex;
  z-index: 10;
}

.part--teaser__overlay.hide {
  display: none;
}

.part--teaser__overlay .button-product--download {
  display: none;
}

.js .part--teaser__overlay .download-overlay--wrapper .download-overlay--content {
  max-width: 35rem;
}

.color--boell-yellow-2 .component--teaser-revised .part--teaser__link_wrapper {
  background-color: var(--brand-colors-boell-yellow-2);
}

.grid-slot:has(.color--boell-yellow-2 .component--teaser-revised) {
  background-color: var(--brand-colors-boell-yellow-2);
}
