/* Content Block: Contact disruptor. Scoped variant of the product-contact CTA from the static template. */

.contact-disruptor-content-block {
  padding: 24px 0 28px 0;
  background: #fff;
}

.contact-disruptor-content-block .product-contact-container {
  width: 100%;
  margin-right: auto;
  margin-left: auto;
  padding-right: calc(var(--bs-gutter-x, 1.5rem) * .5);
  padding-left: calc(var(--bs-gutter-x, 1.5rem) * .5);
  box-sizing: border-box;
}

.contact-disruptor-content-block .product-contact-panel {
  display: grid;
  grid-template-columns: minmax(170px, 230px) minmax(0, 1fr) minmax(380px, 32.5%);
  grid-template-areas: "actions text media";
  align-items: stretch;
  min-height: 0;
  background: #fdc815;
  color: #000;
  overflow: hidden;
}

.contact-disruptor-content-block .product-contact-text {
  grid-area: text;
  display: flex;
  align-items: center;
  padding: 32px 28px;
}

.contact-disruptor-content-block .product-contact-text h2 {
  margin: 0;
  font-size: clamp(1.45rem, 1.4vw, 1.9rem);
  line-height: 1.08;
  font-weight: 600;
  letter-spacing: 0.005em;
}

.contact-disruptor-content-block .product-contact-actions {
  grid-area: actions;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: center;
  gap: 16px;
  padding: 32px 0 32px 42px;
}

.contact-disruptor-content-block .product-contact-button,
.contact-disruptor-content-block .product-contact-button:link,
.contact-disruptor-content-block .product-contact-button:visited {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 178px;
  height: auto;
  min-height: 0;
  padding: 9px 22px;
  background: #fff !important;
  color: #000 !important;
  -webkit-text-fill-color: #000 !important;
  text-decoration: none !important;
  text-decoration-line: none !important;
  text-align: center;
  font-size: 1rem;
  line-height: 1.5;
  font-weight: 500;
  transition: background-color .15s ease, color .15s ease;
}

.contact-disruptor-content-block .product-contact-button:hover,
.contact-disruptor-content-block .product-contact-button:focus,
.contact-disruptor-content-block .product-contact-button:focus-visible {
  background: #000 !important;
  color: #fff !important;
  -webkit-text-fill-color: #fff !important;
  text-decoration: none !important;
  text-decoration-line: none !important;
  outline: none;
}

/*
 * Image area and AI badge positioning.
 *
 * Badge appearance itself is defined globally in ai-image-label.css.
 * Position matches the TYPO3 standard content element "Nur Bilder".
 */
.contact-disruptor-content-block .product-contact-media {
  grid-area: media;
  align-self: stretch;
  width: 100%;
  min-height: 100%;
  height: auto;
  overflow: hidden;

  position: relative;

  --ai-label-top: 12px;
  --ai-label-right: auto;
  --ai-label-bottom: auto;
  --ai-label-left: 12px;

  --ai-label-top-mobile: 8px;
  --ai-label-right-mobile: auto;
  --ai-label-bottom-mobile: auto;
  --ai-label-left-mobile: 8px;
}

/*
 * Scope image sizing to the actual content image only.
 * This prevents the AI badge SVG from inheriting the full image dimensions.
 */
.contact-disruptor-content-block .product-contact-media picture,
.contact-disruptor-content-block .product-contact-media picture > img {
  display: block;
  width: 100%;
  height: 100%;
}

.contact-disruptor-content-block .product-contact-media picture > img {
  object-fit: cover;
  object-position: center;
}

body.theme-mono-light .contact-disruptor-content-block,
body.theme-mono-light .contact-disruptor-content-block .product-contact-panel {
  background: #fff !important;
  color: #000 !important;
}

body.theme-mono-light .contact-disruptor-content-block .product-contact-panel {
  border: 1px solid #000 !important;
}

body.theme-mono-light .contact-disruptor-content-block .product-contact-button,
body.theme-mono-light .contact-disruptor-content-block .product-contact-button:link,
body.theme-mono-light .contact-disruptor-content-block .product-contact-button:visited {
  background: #fff !important;
  color: #000 !important;
  -webkit-text-fill-color: #000 !important;
  border: 1px solid #000 !important;
  text-decoration: none !important;
  text-decoration-line: none !important;
}

body.theme-mono-light .contact-disruptor-content-block .product-contact-button:hover,
body.theme-mono-light .contact-disruptor-content-block .product-contact-button:focus,
body.theme-mono-light .contact-disruptor-content-block .product-contact-button:focus-visible {
  background: #000 !important;
  color: #fff !important;
  -webkit-text-fill-color: #fff !important;
  text-decoration: none !important;
  text-decoration-line: none !important;
}

body.theme-mono-dark .contact-disruptor-content-block,
body.theme-mono-dark .contact-disruptor-content-block .product-contact-panel {
  background: #000 !important;
  color: #fff !important;
}

body.theme-mono-dark .contact-disruptor-content-block .product-contact-panel {
  border: 1px solid #fff !important;
}

/*
 * Only invert the actual content image.
 * The AI badge icon has its own dark-theme handling in ai-image-label.css.
 */
body.theme-mono-dark .contact-disruptor-content-block .product-contact-media picture > img {
  filter: invert(1);
}

body.theme-mono-dark .contact-disruptor-content-block .product-contact-button,
body.theme-mono-dark .contact-disruptor-content-block .product-contact-button:link,
body.theme-mono-dark .contact-disruptor-content-block .product-contact-button:visited {
  background: #000 !important;
  color: #fff !important;
  -webkit-text-fill-color: #fff !important;
  border: 1px solid #fff !important;
  text-decoration: none !important;
  text-decoration-line: none !important;
}

body.theme-mono-dark .contact-disruptor-content-block .product-contact-button:hover,
body.theme-mono-dark .contact-disruptor-content-block .product-contact-button:focus,
body.theme-mono-dark .contact-disruptor-content-block .product-contact-button:focus-visible {
  background: #fff !important;
  color: #000 !important;
  -webkit-text-fill-color: #000 !important;
  text-decoration: none !important;
  text-decoration-line: none !important;
}

@media (min-width: 576px) {
  .contact-disruptor-content-block .product-contact-container {
    max-width: 540px;
  }
}

@media (min-width: 768px) {
  .contact-disruptor-content-block .product-contact-container {
    max-width: 720px;
  }
}

@media (min-width: 992px) {
  .contact-disruptor-content-block .product-contact-container {
    max-width: 960px;
  }
}

@media (min-width: 1200px) {
  .contact-disruptor-content-block .product-contact-container {
    max-width: 1140px;
  }
}

@media (min-width: 1400px) {
  .contact-disruptor-content-block .product-contact-container {
    max-width: 1320px;
  }
}

@media (min-width: 992px) and (max-width: 1199.98px) {
  .contact-disruptor-content-block .product-contact-panel {
    grid-template-columns: 210px minmax(0, 1fr) minmax(360px, 40%);
    align-items: stretch;
  }

  .contact-disruptor-content-block .product-contact-text {
    padding: 30px 24px;
  }

  .contact-disruptor-content-block .product-contact-actions {
    gap: 16px;
    padding: 30px 0 30px 28px;
  }

  .contact-disruptor-content-block .product-contact-media {
    align-self: stretch;
    min-height: 100%;
  }
}

@media (max-width: 991.98px) {
  .contact-disruptor-content-block {
    padding: 20px 0 28px 0;
  }

  .contact-disruptor-content-block .product-contact-panel {
    grid-template-columns: 1fr;
    grid-template-areas:
      "text"
      "actions"
      "media";
    min-height: 0;
  }

  .contact-disruptor-content-block .product-contact-text {
    display: block;
    padding: 34px 28px 30px 28px;
    text-align: center;
  }

  .contact-disruptor-content-block .product-contact-text h2 {
    font-size: clamp(1.45rem, 1.4vw, 1.9rem);
    line-height: 1.08;
  }

  .contact-disruptor-content-block .product-contact-actions {
    align-items: center;
    gap: 14px;
    padding: 0 28px 32px 28px;
  }

  .contact-disruptor-content-block .product-contact-button {
    width: 178px;
    min-height: 0;
    padding: 9px 22px;
    font-size: 1rem;
    line-height: 1.5;
  }

  .contact-disruptor-content-block .product-contact-media {
    width: 100%;
    min-height: 0;
    height: auto;
    aspect-ratio: 3 / 1;
  }

  .contact-disruptor-content-block .product-contact-media picture,
  .contact-disruptor-content-block .product-contact-media picture > img {
    height: 100%;
  }
}

@media (max-width: 767.98px) {
  .contact-disruptor-content-block .product-contact-text {
    padding-top: 36px;
  }

  .contact-disruptor-content-block .product-contact-text h2 {
    font-size: clamp(1.45rem, 1.4vw, 1.9rem);
  }
}

/* Fine tuning: between 768px and 991px the contact disruptor already uses the mobile layout. */
@media (min-width: 768px) and (max-width: 991.98px) {
  .contact-disruptor-content-block .product-contact-text h2 {
    font-size: clamp(1.18rem, 2.25vw, 1.48rem);
    line-height: 1.12;
  }
}

/* Fine tuning: desktop layout remains active between 992px and 1199px. */
@media (min-width: 992px) and (max-width: 1199.98px) {
  .contact-disruptor-content-block .product-contact-text h2 {
    font-size: 1.25rem;
    line-height: 1.16;
  }
}

/* Desktop fine tuning: align the image column with the 3-column card grid above. */
@media (min-width: 1200px) {
  .contact-disruptor-content-block .product-contact-panel {
    grid-template-columns: minmax(170px, 230px) minmax(0, 1fr) minmax(360px, 31.65%);
  }
}

/* Topic-page width alignment: the contact disruptor uses the same content width as the slider above. */
.topic-page-content-section .contact-disruptor-content-block .product-contact-container {
  max-width: none !important;
  padding-left: 0 !important;
  padding-right: 0 !important;
}

/* Desktop alignment: match the image column to the image width of the slider cards above. */
@media (min-width: 1200px) {
  .topic-page-content-section .contact-disruptor-content-block .product-contact-panel {
    grid-template-columns: minmax(170px, 230px) minmax(0, 1fr) 416px !important;
  }

  .topic-page-content-section .contact-disruptor-content-block .product-contact-media {
    width: 416px !important;
    max-width: 416px !important;
    justify-self: end;
  }
}

/* Keep the headline at about 20px between 992px and 1199px. */
@media (min-width: 992px) and (max-width: 1199.98px) {
  .contact-disruptor-content-block .product-contact-text h2 {
    font-size: 1.25rem !important;
    line-height: 1.16 !important;
  }
}

/* Between 1200px and 1399px the image column aligns with the slider above. */
@media (min-width: 1200px) and (max-width: 1399.98px) {
  .contact-disruptor-content-block .product-contact-panel {
    grid-template-columns: minmax(170px, 230px) minmax(0, 1fr) 356px;
  }
}

/* Final override for the 1200px-1399px image-column width. */
@media (min-width: 1200px) and (max-width: 1399.98px) {
  .topic-page-content-section .contact-disruptor-content-block .product-contact-panel,
  .contact-disruptor-content-block .product-contact-panel {
    grid-template-columns: minmax(170px, 230px) minmax(0, 1fr) 356px !important;
  }

  .topic-page-content-section .contact-disruptor-content-block .product-contact-media,
  .contact-disruptor-content-block .product-contact-media {
    width: 356px !important;
    max-width: 356px !important;
    justify-self: end;
  }
}