/* ============================================================
   LUPRIT Landingpages – Mobile-Optimierung (Google Ads Traffic)
   Ziel: Bild, Preis und "In den Warenkorb" im ersten Bildschirm
   (390 x 844). Wird NACH den Inline-Styles der LPs geladen;
   Inline-style-Attribute im Hero werden per !important übersteuert.
   ============================================================ */

@media (max-width: 640px) {
  /* Hero: weniger Abstand oben, seitlicher Innenabstand (vorher 0) */
  body .lp-hero {
    padding: 86px 16px 40px;
  }
  body .lp-hero h1 {
    font-size: 1.6rem;
    line-height: 1.2;
    margin-bottom: 10px;
  }
  body .lp-hero > p {
    font-size: 1rem;
    line-height: 1.45;
    margin: 0 auto 16px;
  }
  /* Einzelprodukt-LPs: Untertitel ausblenden, Produkt steht im Fokus */
  body .lp-hero:has(.lp-product-showcase) > p { display: none; }

  /* Produktblock kompakt: Bild links, Details rechts/unten */
  body .lp-product-showcase {
    display: grid;
    grid-template-columns: 112px 1fr;
    gap: 12px 14px;
    align-items: center;
    margin-bottom: 32px;
    text-align: left;
  }
  body .lp-product-showcase .lp-product-img {
    width: 112px;
    max-width: 112px;
    filter: drop-shadow(0 10px 20px rgba(0,0,0,.45));
  }
  body .lp-product-showcase .lp-product-details {
    display: contents;
  }
  body .lp-product-details > h2 {
    grid-column: 2;
    grid-row: 1;
    align-self: center;
    font-size: 1.25rem !important;
    line-height: 1.25;
    margin: 0 !important;
  }
  body .lp-product-details > p {
    grid-column: 1 / -1;
    font-size: .9rem;
    margin: 0 !important;
  }
  body .lp-product-details > ul {
    grid-column: 1 / -1;
    margin: 0 !important;
    font-size: .95rem;
  }
  body .lp-product-details > ul li {
    margin-bottom: 6px !important;
    align-items: flex-start !important;
  }
  body .lp-product-details > ul li svg { flex: 0 0 18px; width: 18px !important; margin-top: 2px; }
  body .lp-product-details > .lp-price {
    grid-column: 1 / -1;
    font-size: 1.6rem;
    line-height: 1.3;
    margin: 4px 0 0;
  }
  body .lp-product-details > .lp-price > span:not(#lp-chw-price) {
    display: block;
    font-size: .8rem !important;
    line-height: 1.4;
    margin-top: 2px;
  }
  body .lp-product-details > .lp-variant {
    grid-column: 1 / -1;
    margin: 8px 0 0;
  }
  body .lp-product-details > .btn-buy,
  body .lp-product-details > .add-to-cart-btn {
    grid-column: 1 / -1;
    min-height: 52px;
  }
  /* Elemente die nicht ins Raster passen (z. B. Hinweise) volle Breite */
  body .lp-product-details > *:not(h2) { grid-column: 1 / -1; }

  /* Mehrprodukt-LP (Metallbearbeitung) */
  body .lp-product-card .lp-product-img { max-width: 180px; }

  /* Sticky-Kaufleiste */
  .lp-sticky-buy {
    position: fixed; left: 0; right: 0; bottom: 0; z-index: 9990;
    display: flex; align-items: center; gap: 12px;
    padding: 10px 14px calc(10px + env(safe-area-inset-bottom));
    background: var(--bg-200, #1a1a1a);
    border-top: 1px solid var(--border-2, #333);
    box-shadow: 0 -4px 18px rgba(0,0,0,.4);
    transform: translateY(110%);
    transition: transform .3s cubic-bezier(.22,1,.36,1);
  }
  .lp-sticky-buy.is-visible { transform: translateY(0); }
  .lp-sticky-buy__info { flex: 1; min-width: 0; line-height: 1.25; }
  .lp-sticky-buy__name { display: block; font-size: .8rem; color: var(--text-300, #aaa); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .lp-sticky-buy__price { display: block; font-size: 1.1rem; font-weight: 700; color: var(--text-100, #fff); }
  .lp-sticky-buy__btn {
    flex: 0 0 auto; padding: 12px 18px; min-height: 46px;
    font-size: .95rem; border-radius: 8px; width: auto;
  }
}

@media (min-width: 641px) {
  .lp-sticky-buy { display: none !important; }
}
