/* PisonetX PC Monitoring - cart & checkout UI */
:root {
  --pcm-accent: #559bcc;
  --pcm-accent-dark: #3d7fae;
  --pcm-success: #059669;
  --pcm-ink: #1e293b;
  --pcm-muted: #6b7280;
  --pcm-line: #e2e8f0;
}

/* floating cart button */
#pcm-cart-fab {
  position: fixed; right: 20px; bottom: 22px; z-index: 1050;
  width: 54px; height: 54px; border-radius: 50%; border: none;
  background: var(--pcm-accent); color: #fff; font-size: 1.35rem;
  box-shadow: 0 8px 24px rgba(0, 0, 0, .22); cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  transition: transform .15s, background .15s;
}
#pcm-cart-fab:hover { background: var(--pcm-accent-dark); transform: translateY(-2px); }
#pcm-cart-badge {
  position: absolute; top: -4px; right: -4px; min-width: 20px; height: 20px;
  padding: 0 5px; border-radius: 10px; background: #ef4444; color: #fff;
  font-size: .72rem; font-weight: 800; display: none;
  align-items: center; justify-content: center;
}

/* drawer */
#pcm-cart-overlay {
  position: fixed; inset: 0; background: rgba(0, 0, 0, .45);
  opacity: 0; visibility: hidden; transition: .2s; z-index: 1060;
}
#pcm-cart-overlay.active { opacity: 1; visibility: visible; }
#pcm-cart-drawer {
  position: fixed; top: 0; right: 0; height: 100%; width: 380px; max-width: 90vw;
  background: #fff; z-index: 1061; transform: translateX(100%);
  transition: transform .25s ease; display: flex; flex-direction: column;
  box-shadow: -12px 0 40px rgba(0, 0, 0, .18); font-family: inherit;
}
#pcm-cart-drawer.active { transform: translateX(0); }
.pcm-cart-head {
  display: flex; align-items: center; justify-content: space-between;
  padding: 18px 20px; border-bottom: 1px solid var(--pcm-line);
  font-weight: 800; font-size: 1.05rem; color: var(--pcm-ink);
}
.pcm-cart-head button { background: none; border: none; font-size: 1.4rem; color: var(--pcm-muted); cursor: pointer; line-height: 1; }
#pcm-cart-items { flex: 1; overflow-y: auto; padding: 14px 16px; }
.pcm-cart-empty { text-align: center; color: var(--pcm-muted); padding: 60px 0; }
.pcm-cart-empty i { font-size: 2.4rem; display: block; margin-bottom: 10px; opacity: .5; }

.pcm-cart-item {
  display: flex; gap: 10px; align-items: flex-start;
  padding: 12px 0; border-bottom: 1px solid #f1f5f9;
}
.pcm-cart-item-main { flex: 1; min-width: 0; }
.pcm-cart-item-name { font-weight: 700; font-size: .9rem; color: var(--pcm-ink); }
.pcm-cart-item-save { font-size: .76rem; color: var(--pcm-success); font-weight: 600; margin-top: 3px; }
.pcm-cart-item-row { display: flex; justify-content: space-between; align-items: center; margin-top: 8px; }
.pcm-qty { display: flex; align-items: center; gap: 8px; }
.pcm-qty button {
  width: 26px; height: 26px; border-radius: 6px; border: 1px solid var(--pcm-line);
  background: #f8fafc; cursor: pointer; color: var(--pcm-ink); display: flex;
  align-items: center; justify-content: center;
}
.pcm-qty span { min-width: 22px; text-align: center; font-weight: 700; font-size: .9rem; }
.pcm-cart-item-price { text-align: right; }
.pcm-cart-item-price span { display: block; font-size: .72rem; color: #9ca3af; }
.pcm-cart-item-price strong { color: var(--pcm-success); font-size: .98rem; }
.pcm-cart-item-rm { background: none; border: none; color: #cbd5e1; cursor: pointer; font-size: .95rem; padding: 2px; }
.pcm-cart-item-rm:hover { color: #ef4444; }

.pcm-cart-foot { padding: 16px 20px; border-top: 1px solid var(--pcm-line); }
.pcm-cart-foot-total { display: flex; justify-content: space-between; font-weight: 800; font-size: 1.1rem; color: var(--pcm-accent-dark); margin-bottom: 12px; }
.pcm-cart-checkout {
  width: 100%; padding: 12px; border: none; border-radius: 10px;
  background: var(--pcm-accent); color: #fff; font-weight: 700; font-size: .95rem; cursor: pointer;
}
.pcm-cart-checkout:hover { background: var(--pcm-accent-dark); }

/* add-to-cart buttons on the pricing section */
.pcm-add-btn {
  display: inline-block; margin-left: 8px; padding: 10px 18px; border-radius: 8px;
  border: 2px solid var(--pcm-accent); background: #fff; color: var(--pcm-accent);
  font-weight: 700; font-size: .9rem; cursor: pointer; text-decoration: none;
  transition: .15s;
}
.pcm-add-btn:hover { background: var(--pcm-accent); color: #fff; }
.pcm-add-btn.pcm-added { background: var(--pcm-success); border-color: var(--pcm-success); color: #fff; }

/* checkout modal */
#pcm-co-wrap, #pcm-ok-wrap { position: fixed; inset: 0; z-index: 1080; }
.pcm-co-backdrop { position: absolute; inset: 0; background: rgba(0, 0, 0, .5); }
.pcm-co-modal {
  position: relative; max-width: 500px; width: calc(100% - 32px); margin: 40px auto;
  max-height: calc(100vh - 80px); background: #fff; border-radius: 16px;
  display: flex; flex-direction: column; overflow: hidden;
  box-shadow: 0 24px 48px rgba(0, 0, 0, .25); font-family: inherit;
}
.pcm-co-head {
  display: flex; align-items: center; justify-content: space-between;
  padding: 18px 22px; background: var(--pcm-accent); color: #fff; font-weight: 700; font-size: 1.05rem;
}
.pcm-co-head button { background: none; border: none; color: #fff; font-size: 1.5rem; cursor: pointer; line-height: 1; }
.pcm-co-body { padding: 20px 22px; overflow-y: auto; }
.pcm-co-label { display: block; font-weight: 700; font-size: .84rem; color: var(--pcm-ink); margin: 14px 0 6px; }
.pcm-co-label span { color: #ef4444; }
.pcm-co-label .pcm-co-opt { color: #9ca3af; font-weight: 400; }
.pcm-co-body input[type=email], .pcm-co-body textarea {
  width: 100%; padding: 10px 12px; border: 1px solid #d1d5db; border-radius: 8px;
  font-size: .9rem; font-family: inherit; outline: none; resize: vertical;
}
.pcm-co-body input[type=email]:focus, .pcm-co-body textarea:focus { border-color: var(--pcm-accent); }

.pcm-pay-tabs { display: flex; gap: 10px; }
.pcm-pay-tabs button {
  flex: 1; padding: 11px; border: 2px solid var(--pcm-line); border-radius: 10px;
  background: #fff; color: #374151; font-weight: 700; font-size: .88rem; cursor: pointer;
}
.pcm-pay-tabs button.active { border-color: var(--pcm-accent); background: #eef6fc; color: var(--pcm-accent-dark); }

.pcm-co-qr { text-align: center; margin: 14px 0 6px; }
.pcm-co-qr img { max-width: 220px; width: 100%; border-radius: 12px; border: 1px solid var(--pcm-line); }
.pcm-co-hint { font-size: .82rem; color: var(--pcm-muted); margin: 6px 0 0; }
.pcm-co-paypal { text-align: center; margin: 14px 0 6px; padding: 18px; background: #f8fafc; border: 1px solid var(--pcm-line); border-radius: 12px; }
.pcm-co-paypal > i { font-size: 2.2rem; color: #003087; }
.pcm-co-paypal p { font-size: .84rem; color: var(--pcm-muted); margin: 8px 0; }
.pcm-co-paypal-email { display: flex; align-items: center; justify-content: center; gap: 8px; flex-wrap: wrap; }
.pcm-co-paypal-email span { font-weight: 800; color: var(--pcm-accent-dark); word-break: break-all; }
.pcm-co-paypal-email button { border: 1px solid #d1d5db; border-radius: 6px; background: #fff; padding: 4px 8px; font-size: .78rem; cursor: pointer; }

.pcm-co-summary { background: #f8fafc; border: 1px solid var(--pcm-line); border-radius: 10px; padding: 14px; margin-top: 16px; }
.pcm-co-summary h6 { font-weight: 700; font-size: .78rem; text-transform: uppercase; letter-spacing: .04em; color: var(--pcm-muted); margin: 0 0 8px; }
.pcm-co-row { display: flex; justify-content: space-between; padding: 6px 0; border-bottom: 1px solid #eef2f6; font-size: .86rem; }
.pcm-co-row em { color: #9ca3af; font-style: normal; }
.pcm-co-total { display: flex; justify-content: space-between; padding-top: 10px; font-weight: 800; font-size: 1.05rem; color: var(--pcm-accent-dark); }

.pcm-co-warn { background: #fef2f2; border: 1px solid #fecaca; border-radius: 8px; padding: 9px 11px; font-size: .78rem; color: #991b1b; margin-top: 8px; }
.pcm-co-warn a { color: #b91c1c; font-weight: 700; }
.pcm-co-verify { background: #fef3c7; border: 1px solid #fde68a; border-radius: 8px; padding: 10px 12px; font-size: .8rem; color: #92400e; margin-top: 16px; }
.pcm-co-err { color: #ef4444; font-size: .78rem; margin-top: 5px; }

#pcm-co-drop {
  border: 2px dashed #d1d5db; border-radius: 10px; padding: 22px; text-align: center;
  cursor: pointer; background: #fafafa;
}
#pcm-co-drop i { font-size: 1.8rem; color: #9ca3af; display: block; margin-bottom: 5px; }
#pcm-co-drop span { font-size: .84rem; color: var(--pcm-muted); }
#pcm-co-preview img { max-width: 100%; max-height: 150px; border-radius: 8px; border: 1px solid var(--pcm-line); margin-top: 10px; }
#pcm-co-preview div { font-size: .78rem; color: var(--pcm-success); font-weight: 600; margin-top: 5px; }

.pcm-co-foot { display: flex; justify-content: flex-end; gap: 10px; padding: 14px 22px; border-top: 1px solid #f1f5f9; }
.pcm-btn-ghost { padding: 10px 18px; border: 1px solid #d1d5db; border-radius: 8px; background: #fff; color: #374151; font-weight: 600; font-size: .86rem; cursor: pointer; }
.pcm-btn-primary { padding: 10px 22px; border: none; border-radius: 8px; background: var(--pcm-accent); color: #fff; font-weight: 700; font-size: .86rem; cursor: pointer; }
.pcm-btn-primary:disabled { opacity: .6; cursor: default; }

.pcm-ok-modal {
  position: relative; max-width: 420px; width: calc(100% - 32px); margin: 12vh auto 0;
  background: #fff; border-radius: 16px; padding: 34px; text-align: center;
  box-shadow: 0 24px 48px rgba(0, 0, 0, .25); font-family: inherit;
}
.pcm-ok-icon { width: 60px; height: 60px; border-radius: 50%; background: #d1fae5; color: var(--pcm-success); font-size: 1.9rem; display: flex; align-items: center; justify-content: center; margin: 0 auto 14px; }
.pcm-ok-modal h3 { font-size: 1.2rem; font-weight: 800; color: var(--pcm-ink); margin-bottom: 8px; }
.pcm-ok-modal p { color: var(--pcm-muted); font-size: .88rem; line-height: 1.6; margin-bottom: 18px; }

@media (max-width: 480px) {
  #pcm-cart-drawer { width: 100%; max-width: 100%; }
}
