/* ADAG Cart Experience — Styles
 * Pfad live:  /pub/adag/css/adag-cart-experience.css
 * URL:        /adag/css/adag-cart-experience.css
 * Backup lok: /app/magento_module/adag-css/adag-cart-experience.css
 *
 * Mobile-first, dezent, ADAG-Branding (#00963f).
 */

/* ============================================================
   MODUL 1 — Sticky Live-Pricing-Bar (PDP)
   ============================================================ */

.adag-sticky-price-bar {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 998;
  background: #ffffff;
  border-top: 1px solid #e2e8f0;
  box-shadow: 0 -4px 16px rgba(0, 0, 0, 0.08);
  transform: translateY(110%);
  transition: transform 0.4s cubic-bezier(0.2, 0.9, 0.3, 1);
  /* Safe area inset für iPhone-Home-Indicator */
  padding-bottom: env(safe-area-inset-bottom, 0);
}
.adag-sticky-price-bar.adag-spb-visible {
  transform: translateY(0);
}
.adag-sticky-price-bar .adag-spb-inner {
  max-width: 1240px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 16px;
}
.adag-sticky-price-bar .adag-spb-left {
  display: flex;
  flex-direction: column;
  line-height: 1.2;
  min-width: 0;
}
.adag-sticky-price-bar .adag-spb-label {
  font-size: 11px;
  color: #6b7280;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  font-weight: 600;
}
.adag-sticky-price-bar .adag-spb-amount {
  font-size: 22px;
  font-weight: 800;
  color: #00963f;
  font-feature-settings: "tnum" 1;
  letter-spacing: -0.01em;
}
.adag-sticky-price-bar .adag-spb-meta {
  font-size: 11px;
  color: #9ca3af;
  margin-top: 1px;
}
.adag-sticky-price-bar .adag-spb-cta {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: #00963f;
  color: #ffffff;
  font-weight: 700;
  font-size: 14px;
  padding: 12px 20px;
  border: none;
  border-radius: 999px;
  cursor: pointer;
  transition: background 0.2s ease, transform 0.15s ease;
  box-shadow: 0 4px 12px rgba(0, 150, 63, 0.25);
  white-space: nowrap;
}
.adag-sticky-price-bar .adag-spb-cta:hover {
  background: #007a33;
  transform: translateY(-1px);
}
.adag-sticky-price-bar .adag-spb-cta:active {
  transform: translateY(0);
}
.adag-sticky-price-bar .adag-spb-cta-icon {
  font-size: 16px;
  line-height: 1;
}
.adag-sticky-price-bar .adag-spb-cta-text {
  white-space: nowrap;
}

/* Desktop: Bar dezenter, weniger raumgreifend */
@media (min-width: 1024px) {
  .adag-sticky-price-bar .adag-spb-inner {
    padding: 14px 24px;
  }
  .adag-sticky-price-bar .adag-spb-amount {
    font-size: 26px;
  }
  .adag-sticky-price-bar .adag-spb-cta {
    font-size: 15px;
    padding: 14px 28px;
  }
}

/* Verstecken bei Print + auf Cart-Page (Sticky-Bar ergibt da keinen Sinn) */
.checkout-cart-index .adag-sticky-price-bar,
.checkout-index-index .adag-sticky-price-bar,
.customer-account-login .adag-sticky-price-bar {
  display: none;
}
@media print {
  .adag-sticky-price-bar { display: none; }
}

/* ============================================================
   MODUL 2 — Cart Trust-Bar
   ============================================================ */

.adag-cart-trust-bar {
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px;
  background: linear-gradient(135deg, #f0fdf4 0%, #ecfdf5 100%);
  border: 1px solid #bbf7d0;
  border-radius: 14px;
  padding: 16px 20px;
  margin: 0 0 20px;
}
@media (min-width: 768px) {
  .adag-cart-trust-bar {
    grid-template-columns: repeat(2, 1fr);
    gap: 12px 24px;
  }
}
@media (min-width: 1024px) {
  .adag-cart-trust-bar {
    grid-template-columns: repeat(4, 1fr);
    gap: 8px 24px;
    padding: 14px 22px;
  }
}
.adag-cart-trust-bar .adag-ctb-item {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 13px;
  color: #14532d;
  line-height: 1.4;
}
.adag-cart-trust-bar .adag-ctb-item strong {
  color: #064e3b;
  font-weight: 700;
}
.adag-cart-trust-bar .adag-ctb-stars {
  color: #f59e0b;
  font-size: 16px;
  letter-spacing: -1px;
}
.adag-cart-trust-bar .adag-ctb-icon {
  font-size: 18px;
  line-height: 1;
}
.adag-cart-trust-bar .adag-ctb-save-hint {
  /* Letzter Punkt: Bridge-zum-Save-Button */
  color: #166534;
}

/* ============================================================
   MODUL 3 — Save-Cart Hint Toast (Cart-Page nach ATC)
   ============================================================ */

.adag-save-hint-toast {
  position: fixed;
  right: 16px;
  bottom: 16px;
  z-index: 999;
  max-width: 360px;
  background: #ffffff;
  border: 1px solid #00963f;
  border-radius: 14px;
  box-shadow: 0 12px 32px rgba(0, 150, 63, 0.18);
  padding: 16px 16px 16px 18px;
  display: flex;
  align-items: flex-start;
  gap: 12px;
  transform: translateY(20px) scale(0.96);
  opacity: 0;
  transition: transform 0.5s cubic-bezier(0.2, 0.9, 0.3, 1), opacity 0.4s ease;
}
.adag-save-hint-toast.adag-sht-visible {
  transform: translateY(0) scale(1);
  opacity: 1;
}
.adag-save-hint-toast.adag-sht-out {
  transform: translateY(20px) scale(0.96);
  opacity: 0;
}
.adag-save-hint-toast .adag-sht-icon {
  font-size: 22px;
  line-height: 1;
  flex-shrink: 0;
  margin-top: 2px;
}
.adag-save-hint-toast .adag-sht-body {
  flex: 1;
  min-width: 0;
}
.adag-save-hint-toast .adag-sht-title {
  font-size: 14px;
  font-weight: 700;
  color: #0f172a;
  margin-bottom: 4px;
}
.adag-save-hint-toast .adag-sht-text {
  font-size: 13px;
  line-height: 1.5;
  color: #475569;
}
.adag-save-hint-toast .adag-sht-close {
  background: transparent;
  border: none;
  color: #9ca3af;
  font-size: 22px;
  line-height: 1;
  cursor: pointer;
  padding: 0;
  width: 24px;
  height: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.adag-save-hint-toast .adag-sht-close:hover {
  color: #1f2937;
}

/* Auf kleinen Screens: Toast voll-breit */
@media (max-width: 640px) {
  .adag-save-hint-toast {
    left: 12px;
    right: 12px;
    max-width: none;
    bottom: 88px; /* Über der Sticky-Price-Bar wenn parallel */
  }
}

/* Sicherheits-Override: keine Konflikte mit Smartwave Porto Theme */
.adag-sticky-price-bar *,
.adag-cart-trust-bar *,
.adag-save-hint-toast * {
  box-sizing: border-box;
}
