/**
 * Pending checkout recovery — dashboard hero + header cart pulse
 */
.pco-hero {
  --pco-navy: #0b1f3a;
  --pco-blue: #1d6fd8;
  --pco-teal: #0ea5a8;
  position: relative;
  isolation: isolate;
  margin: 0 0 1.25rem;
  border-radius: 1.35rem;
  overflow: hidden;
  background:
    linear-gradient(135deg, rgba(29, 111, 216, 0.14) 0%, rgba(14, 165, 168, 0.1) 48%, rgba(255, 255, 255, 0.96) 100%);
  border: 1px solid rgba(29, 111, 216, 0.22);
  box-shadow:
    0 18px 44px -26px rgba(11, 31, 58, 0.45),
    0 1px 0 rgba(255, 255, 255, 0.85) inset;
  animation: pcoBreath 4.2s ease-in-out infinite;
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}

.pco-hero:hover {
  transform: translateY(-2px);
  border-color: rgba(29, 111, 216, 0.38);
  box-shadow:
    0 22px 48px -24px rgba(11, 31, 58, 0.5),
    0 1px 0 rgba(255, 255, 255, 0.9) inset;
}

.pco-hero__hit {
  position: absolute;
  inset: 0;
  z-index: 2;
  border-radius: inherit;
}

.pco-hero__cta,
.pco-hero__details {
  position: relative;
  z-index: 3;
}

.pco-hero__glow {
  position: absolute;
  width: 16rem;
  height: 16rem;
  right: -4rem;
  top: -6rem;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(29, 111, 216, 0.28), transparent 68%);
  pointer-events: none;
  animation: pcoOrb 5s ease-in-out infinite;
}

.pco-hero__inner {
  position: relative;
  z-index: 1;
  display: grid;
  gap: 1.15rem;
  padding: 1.25rem 1.2rem 1.35rem;
}

@media (min-width: 768px) {
  .pco-hero__inner {
    grid-template-columns: auto minmax(0, 1fr) auto;
    align-items: center;
    gap: 1.35rem;
    padding: 1.45rem 1.55rem;
  }
}

.pco-hero__media {
  position: relative;
  width: 5.5rem;
  height: 5.5rem;
  flex-shrink: 0;
}

.pco-hero__img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  border-radius: 1.1rem;
  background: #fff;
  border: 1px solid rgba(15, 23, 42, 0.08);
  box-shadow: 0 12px 28px -18px rgba(15, 23, 42, 0.45);
  padding: 0.35rem;
  transition: transform 0.3s ease;
}

.pco-hero:hover .pco-hero__img {
  transform: translateY(-3px) scale(1.03);
}

.pco-hero__img--placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  color: #1d6fd8;
  background: linear-gradient(145deg, #eff6ff, #ecfeff);
}

.pco-hero__stack {
  position: absolute;
  right: -0.35rem;
  bottom: -0.25rem;
  min-width: 1.6rem;
  height: 1.6rem;
  padding: 0 0.35rem;
  border-radius: 999px;
  background: linear-gradient(135deg, #1d6fd8, #0ea5a8);
  color: #fff;
  font-size: 0.7rem;
  font-weight: 800;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 8px 16px -8px rgba(29, 111, 216, 0.7);
}

.pco-hero__kicker {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  margin: 0 0 0.35rem;
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #184f9c;
}

.pco-hero__pulse-dot {
  width: 0.55rem;
  height: 0.55rem;
  border-radius: 50%;
  background: #1d6fd8;
  box-shadow: 0 0 0 0 rgba(29, 111, 216, 0.55);
  animation: pcoDot 1.8s ease-out infinite;
}

.pco-hero__title {
  margin: 0;
  font-family: Outfit, "Plus Jakarta Sans", system-ui, sans-serif;
  font-size: clamp(1.35rem, 2.4vw, 1.7rem);
  font-weight: 700;
  letter-spacing: -0.035em;
  color: var(--pco-navy);
  line-height: 1.15;
}

.pco-hero__product {
  margin: 0.35rem 0 0;
  color: #475569;
  font-size: 0.98rem;
  font-weight: 600;
}

.pco-hero__meta {
  list-style: none;
  margin: 0.85rem 0 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.55rem;
}

@media (max-width: 520px) {
  .pco-hero__meta {
    grid-template-columns: 1fr;
  }
}

.pco-hero__meta li {
  padding: 0.55rem 0.65rem;
  border-radius: 0.85rem;
  background: rgba(255, 255, 255, 0.82);
  border: 1px solid rgba(15, 23, 42, 0.06);
  transition: transform 0.22s ease, border-color 0.22s ease, box-shadow 0.22s ease;
}

.pco-hero__meta li:hover {
  transform: translateY(-2px);
  border-color: rgba(29, 111, 216, 0.22);
  box-shadow: 0 10px 20px -14px rgba(29, 111, 216, 0.45);
}

.pco-hero__meta-label {
  display: block;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: #64748b;
  margin-bottom: 0.15rem;
}

.pco-hero__meta strong {
  color: var(--pco-navy);
  font-size: 0.92rem;
}

.pco-hero__badges {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  margin-top: 0.85rem;
}

.pco-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.35rem 0.7rem;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 700;
  color: #334155;
  background: rgba(255, 255, 255, 0.88);
  border: 1px solid rgba(15, 23, 42, 0.08);
}

.pco-badge--escrow {
  color: #0f766e;
  background: rgba(14, 165, 168, 0.12);
  border-color: rgba(14, 165, 168, 0.28);
}

.pco-hero__details {
  margin-top: 0.75rem;
  font-size: 0.85rem;
  color: #475569;
}

.pco-hero__details summary {
  cursor: pointer;
  font-weight: 700;
  color: #184f9c;
}

.pco-hero__lines {
  list-style: none;
  margin: 0.5rem 0 0;
  padding: 0;
  display: grid;
  gap: 0.35rem;
}

.pco-hero__lines li {
  display: flex;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.45rem 0.55rem;
  border-radius: 0.65rem;
  background: rgba(248, 250, 252, 0.95);
}

.pco-hero__cta {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 0.55rem;
  min-width: 11.5rem;
}

.pco-hero__btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  min-height: 3rem;
  padding: 0.75rem 1.15rem;
  border-radius: 0.95rem;
  background: linear-gradient(135deg, #1d6fd8 0%, #0ea5a8 100%);
  color: #fff !important;
  font-weight: 800;
  font-size: 0.95rem;
  text-decoration: none !important;
  box-shadow: 0 14px 28px -14px rgba(29, 111, 216, 0.75);
  transition: transform 0.22s ease, box-shadow 0.22s ease, filter 0.22s ease;
  animation: pcoCtaBreath 3.4s ease-in-out infinite;
}

.pco-hero__btn:hover {
  transform: translateY(-2px) scale(1.02);
  filter: brightness(1.05);
  animation-play-state: paused;
  box-shadow: 0 18px 34px -14px rgba(14, 165, 168, 0.7);
}

.pco-hero__link {
  text-align: center;
  font-size: 0.85rem;
  font-weight: 700;
  color: #184f9c;
  text-decoration: none;
}

.pco-hero__link:hover {
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* Header cart pending state */
.gp-cart-btn.gp-cart-btn--pending,
a.gp-cart-btn.gp-cart-btn--pending {
  position: relative;
  color: #1d6fd8;
  animation: pcoCartBreath 2.6s ease-in-out infinite;
}

.gp-cart-btn.gp-cart-btn--pending .gp-cart-badge,
.gp-cart-btn.gp-cart-btn--pending .cart-count-badge {
  background: linear-gradient(135deg, #1d6fd8, #0ea5a8) !important;
  color: #fff !important;
  box-shadow: 0 0 0 0 rgba(29, 111, 216, 0.55);
  animation: pcoBadgePulse 1.7s ease-out infinite;
}

.gp-cart-btn.gp-cart-btn--pending::after {
  content: '';
  position: absolute;
  inset: -3px;
  border-radius: 999px;
  border: 2px solid rgba(29, 111, 216, 0.35);
  pointer-events: none;
  animation: pcoRing 2.4s ease-out infinite;
}

@keyframes pcoBreath {
  0%, 100% { box-shadow: 0 18px 44px -26px rgba(11, 31, 58, 0.45), 0 1px 0 rgba(255, 255, 255, 0.85) inset; }
  50% { box-shadow: 0 22px 50px -22px rgba(29, 111, 216, 0.4), 0 1px 0 rgba(255, 255, 255, 0.9) inset; }
}

@keyframes pcoOrb {
  0%, 100% { transform: scale(1); opacity: 0.85; }
  50% { transform: scale(1.12); opacity: 1; }
}

@keyframes pcoDot {
  0% { box-shadow: 0 0 0 0 rgba(29, 111, 216, 0.55); }
  70% { box-shadow: 0 0 0 10px rgba(29, 111, 216, 0); }
  100% { box-shadow: 0 0 0 0 rgba(29, 111, 216, 0); }
}

@keyframes pcoCtaBreath {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-2px); }
}

@keyframes pcoCartBreath {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.06); }
}

@keyframes pcoBadgePulse {
  0% { box-shadow: 0 0 0 0 rgba(29, 111, 216, 0.55); }
  70% { box-shadow: 0 0 0 8px rgba(29, 111, 216, 0); }
  100% { box-shadow: 0 0 0 0 rgba(29, 111, 216, 0); }
}

@keyframes pcoRing {
  0% { opacity: 0.7; transform: scale(0.92); }
  70% { opacity: 0; transform: scale(1.18); }
  100% { opacity: 0; transform: scale(1.18); }
}

@media (prefers-reduced-motion: reduce) {
  .pco-hero,
  .pco-hero__glow,
  .pco-hero__pulse-dot,
  .pco-hero__btn,
  .gp-cart-btn.gp-cart-btn--pending,
  .gp-cart-btn.gp-cart-btn--pending .gp-cart-badge,
  .gp-cart-btn.gp-cart-btn--pending::after {
    animation: none !important;
  }
}
