/* ==========================================================================
   KOBIL — Pre-footer CTA
   Helle Karte (1360x442) mit Verlaufs-Stroke, zartem Muster und abgeschrägter
   Ecke unten rechts. Zentrierte H2 + Subline + zwei Kerben-Buttons.
   ========================================================================== */

.sec-pre-footer-cta {
  position: relative;
  isolation: isolate;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 442px;
  padding: 64px 40px;
  text-align: center;
}

/* Karten-Hintergrund: bg-card.svg = abgeschrägte Karten-Form (Maske) mit
   eingebetteter, in Figma gerenderter Verlaufs-Textur + Gradient-Stroke.
   (Die frühere Live-SVG-Variante mit riesigen feGaussianBlur-Filtern wurde
   von Chromium klötzchenartig gerendert — daher gebackene Textur.) */
.sec-pre-footer-cta::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: url("../../assets/pre-footer-cta/bg-card.svg") center / 100% 100% no-repeat;
}

/* ---- Inhalt: 977px-Spalte, vertikal zentriert ---- */

.sec-pre-footer-cta__inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 48px;
  width: 100%;
  max-width: 977px;
}

.sec-pre-footer-cta__copy {
  display: flex;
  flex-direction: column;
  gap: 24px;
  color: var(--navy);
}

.sec-pre-footer-cta__title {
  font-size: 40px;
  line-height: 50px;
  font-weight: 700;
}

.sec-pre-footer-cta__sub {
  font-size: 18px;
  line-height: 26px;
  font-weight: 400;
}

/* ---- CTAs: Buttons mit diagonaler Kerbe unten rechts (Figma-Shape als Maske) ---- */

.sec-pre-footer-cta__ctas {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  flex-wrap: wrap;
}

.sec-pre-footer-cta__btn {
  position: relative;
  isolation: isolate;
  height: 40px;
  padding: 4px 20px 4px 16px;
  gap: 8px;
  font-size: 14px;
  line-height: 18px;
  border-radius: 4px;
}

.sec-pre-footer-cta__btn::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  -webkit-mask-position: left center, right center;
  -webkit-mask-size: calc(100% - 40px) 100%, 67px 100%;
  -webkit-mask-repeat: no-repeat, no-repeat;
  mask-position: left center, right center;
  mask-size: calc(100% - 40px) 100%, 67px 100%;
  mask-repeat: no-repeat, no-repeat;
  transition: background-color var(--dur) var(--ease);
}

.sec-pre-footer-cta__btn--primary {
  color: var(--white);
}

.sec-pre-footer-cta__btn--primary::before {
  background: var(--blue);
  -webkit-mask-image: url("../../assets/pre-footer-cta/btn-body-blue.svg"),
    url("../../assets/pre-footer-cta/btn-end-blue.svg");
  mask-image: url("../../assets/pre-footer-cta/btn-body-blue.svg"),
    url("../../assets/pre-footer-cta/btn-end-blue.svg");
}

.sec-pre-footer-cta__btn--primary:hover::before {
  background: #1e4fd6;
}

.sec-pre-footer-cta__btn--light {
  color: var(--navy);
}

.sec-pre-footer-cta__btn--light::before {
  background: var(--white);
  -webkit-mask-image: url("../../assets/pre-footer-cta/btn-body-white.svg"),
    url("../../assets/pre-footer-cta/btn-end-white.svg");
  mask-image: url("../../assets/pre-footer-cta/btn-body-white.svg"),
    url("../../assets/pre-footer-cta/btn-end-white.svg");
}

.sec-pre-footer-cta__btn--light:hover::before {
  background: var(--navy-30);
}

.sec-pre-footer-cta__btn-icon {
  transition: transform var(--dur) var(--ease);
}

/* Mobile-Label-Varianten (M-Design: "Book a demo" / "Contact Sales") */
.sec-pre-footer-cta__btn-label--mobile {
  display: none;
}

.sec-pre-footer-cta__btn:hover .sec-pre-footer-cta__btn-icon {
  transform: translateX(3px);
}

/* ---- Responsive ---- */

@media (max-width: 1024px) {
  .sec-pre-footer-cta {
    min-height: 400px;
  }

  .sec-pre-footer-cta__title {
    font-size: 36px;
    line-height: 46px;
  }
}

@media (max-width: 768px) {
  .sec-pre-footer-cta {
    min-height: 0;
    padding: 40px 24px 64px;
    text-align: left;
  }

  /* Mobile Karten-Form aus Figma (369x416): gerundete Ecken r=6, abgeschrägte
     Ecke unten rechts, Gradient-Stroke, gebackene Verlaufs-Textur */
  .sec-pre-footer-cta::before {
    background: url("../../assets/pre-footer-cta/bg-card-mobile.svg") center / 100% 100% no-repeat;
  }

  .sec-pre-footer-cta__inner {
    align-items: stretch;
    gap: 40px;
  }

  .sec-pre-footer-cta__copy {
    gap: 12px;
  }

  .sec-pre-footer-cta__title {
    font-size: 32px;
    line-height: 42px;
  }

  /* Body S, System/70 */
  .sec-pre-footer-cta__sub {
    font-size: 14px;
    line-height: 20px;
    color: var(--navy-70);
  }

  /* Buttons gestapelt, volle Inhaltsbreite */
  .sec-pre-footer-cta__ctas {
    flex-direction: column;
    align-items: stretch;
    width: 100%;
    max-width: 360px;
  }

  /* Zweiter Button auf Mobile dunkel (Navy) mit weißem Label + Pfeil */
  .sec-pre-footer-cta__btn--light {
    color: var(--white);
  }

  .sec-pre-footer-cta__btn--light::before {
    background: var(--navy);
  }

  .sec-pre-footer-cta__btn--light:hover::before {
    background: #1a3164;
  }

  .sec-pre-footer-cta__btn--light .sec-pre-footer-cta__btn-icon {
    filter: brightness(0) invert(1);
  }

  /* Label-Wechsel: "Book a demo" / "Contact Sales" */
  .sec-pre-footer-cta__btn-label--desktop {
    display: none;
  }

  .sec-pre-footer-cta__btn-label--mobile {
    display: inline;
  }
}

@media (max-width: 480px) {
  .sec-pre-footer-cta__title {
    font-size: 28px;
    line-height: 36px;
  }
}
