/* Button */
.b360-cart-sc-root {
    position: relative;
    display: inline-block;
}

.b360-cart-sc-button {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px 12px;
    border-radius: 999px;
    text-decoration: none;
    box-shadow: 0 8px 20px rgba(10, 50, 84, 0.18);
    fill: #FFFFFF;
}


.b360-cart-sc-icon {
    display: block;
}

.b360-cart-sc-badge {
    min-width: 20px;
    height: 20px;
    padding: 0 6px;
    border-radius: 10px;
    background: #fff;
    color: #0a3254;
    font-size: 12px;
    line-height: 20px;
    font-weight: 700;
    text-align: center;
}

/* Modal */
.b360-cart-sc-modal[hidden] {
    display: none !important;
}

.b360-cart-sc-modal {
    position: fixed;
    inset: 0;
    z-index: 10000;
    display: grid;
    grid-template-rows: 1fr;
    place-items: center;
}

.b360-cart-sc-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(15, 23, 42, 0.45);
    backdrop-filter: blur(2px);
}

.b360-cart-sc-dialog {
    position: relative;
    z-index: 1;
    width: min(960px, 94vw);
    max-height: min(80vh, 920px);
    background: #fff;
    border-radius: 14px;
    box-shadow: 0 24px 48px rgba(16, 24, 40, .24);
    border: 1px solid #e5e7eb;
    overflow: auto;
    padding: 16px;
}

.b360-cart-sc-close {
    position: absolute;
    top: 8px;
    right: 10px;
    z-index: 2;
    width: 36px;
    height: 36px;
    border-radius: 18px;
    border: none;
    background: #0a3254;
    color: #fff;
    font-size: 22px;
    line-height: 36px;
    cursor: pointer;
}

.b360-cart-sc-close:hover {
    background: #0c3e6a;
}

/* Cart content container */
.b360-cart-sc-body {
    min-height: 160px;
}

/* Loader */
.b360-cart-sc-loading {
  position: relative;
}

/* Force a true circle + center it */
.b360-cart-sc-spinner {
  display: block;               /* don't let flex rules stretch it */
  width: 36px;
  height: 36px;                 /* equal sides */
  aspect-ratio: 1 / 1;          /* safeguard against layout stretching */
  margin: 48px auto;            /* center horizontally */
  line-height: 0;               /* no extra inline height */
  position: relative;
  border: none !important;      /* ring is drawn by ::after */
  border-radius: 50% !important;
  box-sizing: content-box;
}

/* Draw the spinning ring inside the fixed square above */
.b360-cart-sc-spinner::after {
  content: "";
  position: absolute;
  inset: 0;                     /* fill the 36x36 square */
  border-radius: 50%;
  box-sizing: border-box;
  border: 3px solid #d1d5db;
  border-top-color: #0a3254;
  animation: b360spin .8s linear infinite;
}

/* Keep your original keyframes */
@keyframes b360spin { to { transform: rotate(360deg); } }


/* Prevent page scroll when modal opened */
body.b360-cart-sc-open {
    overflow: hidden;
}

/* Optional: tweak remote cart blocks inside modal */
.b360-cart-sc-body .b360-store,
.b360-cart-sc-body .cart {
    width: 100%;
}

/* =========================
   Remote cart (Bottle360) → plugin look
   Scope: inside our modal only
   ========================= */

#b360-cart-sc-modal .b360-cart-sc-body {
  --b360-bg: #ffffff;
  --b360-fg: #0e1117;
  --b360-muted: #6b7280;
  --b360-border: #e5e7eb;
  --b360-surface: #f8fafc;
  --b360-primary: #2563eb;    /* adjust to your brand */
  --b360-primary-ink: #ffffff;
  --b360-secondary: #111827;
  --b360-secondary-ink: #ffffff;
  --b360-radius: 14px;
  --b360-shadow: 0 10px 30px rgba(0,0,0,.08);

  color: var(--b360-fg);
  background: var(--b360-bg);
  padding: 18px;
  border-radius: var(--b360-radius);
  box-shadow: var(--b360-shadow);
}

/* Header */
#b360-cart-sc-modal .b360-cart-sc-body h2 {
  margin: 0 0 14px;
  font-size: 1.25rem;
  font-weight: 700;
  letter-spacing: .2px;
}

/* Close “X” injected by remote HTML */
#b360-cart-sc-modal .b360-cart-sc-body .close-icon {
  position: absolute;
  top: 12px;
  right: 12px;
  width: 36px;
  height: 36px;
  border-radius: 999px;
  background: var(--b360-surface);
  color: var(--b360-muted);
  display: grid;
  place-items: center;
  cursor: pointer;
  font-weight: 700;
  line-height: 1;
  transition: transform .12s ease, background .12s ease, color .12s ease;
}
#b360-cart-sc-modal .b360-cart-sc-body .close-icon:hover {
  transform: scale(1.06);
  background: #eef2ff;
  color: var(--b360-primary);
}

/* Table container */
#b360-cart-sc-modal .b360-cart-sc-body .body {
  background: var(--b360-surface);
  border: 1px solid var(--b360-border);
  border-radius: var(--b360-radius);
  padding: 10px;
  overflow-x: auto; /* mobile scroll if needed */
}

/* Table */
#b360-cart-sc-modal .b360-cart-sc-body table {
  width: 100%;
  border-collapse: collapse;
  min-width: 520px; /* keep columns readable on small screens */
  font-size: 0.95rem;
}

#b360-cart-sc-modal .b360-cart-sc-body thead th {
  text-align: left;
  font-weight: 600;
  color: var(--b360-muted);
  background: #f3f4f6;
  border-bottom: 1px solid var(--b360-border);
  padding: 12px 10px;
}

#b360-cart-sc-modal .b360-cart-sc-body tbody td {
  padding: 12px 10px;
  border-bottom: 1px solid var(--b360-border);
  vertical-align: middle;
}

#b360-cart-sc-modal .b360-cart-sc-body tbody tr:nth-child(even) td {
  background: #fafafa;
}

/* Align numeric columns */
#b360-cart-sc-modal .b360-cart-sc-body td:nth-child(2),
#b360-cart-sc-modal .b360-cart-sc-body td:nth-child(3),
#b360-cart-sc-modal .b360-cart-sc-body td:nth-child(4) {
  text-align: right;
  white-space: nowrap;
}
/* Image + product title/price */
/* #shopping-cart-popup-content .w-img img { */
#shopping-cart-popup-content .cart-left img {
  width: 60px;
  height: 60px;
  object-fit: cover;
  border-radius: 8px;
  margin-right: 12px;
  float: left;
  padding: 0 0 10px 0;
}

/* Bottom action row */
#b360-cart-sc-modal .b360-cart-sc-body .bottom {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 14px 0 0;
}

/* Normalize all buttons from remote HTML */
#b360-cart-sc-modal .b360-cart-sc-body .bottom a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  padding: 10px 16px;
  font-weight: 600;
  text-decoration: none;
  border: 1px solid transparent;
  transition: transform .12s ease, background .12s ease, color .12s ease, border-color .12s ease;
}

/* Primary CTA */
#b360-cart-sc-modal .b360-cart-sc-body .bottom a.simply-btn-new,
#b360-cart-sc-modal .b360-cart-sc-body .bottom a.add-to-cart {
  background: var(--b360-primary);
  color: var(--b360-primary-ink);
}
#b360-cart-sc-modal .b360-cart-sc-body .bottom a.simply-btn-new:hover,
#b360-cart-sc-modal .b360-cart-sc-body .bottom a.add-to-cart:hover {
  transform: translateY(-1px);
  filter: brightness(1.05);
}

/* Secondary / ghost */
#b360-cart-sc-modal .b360-cart-sc-body .bottom a.simply-btn,
#b360-cart-sc-modal .b360-cart-sc-body .bottom a.close-button {
  background: transparent;
  color: var(--b360-secondary);
  border-color: var(--b360-border);
}
#b360-cart-sc-modal .b360-cart-sc-body .bottom a.simply-btn:hover,
#b360-cart-sc-modal .b360-cart-sc-body .bottom a.close-button:hover {
  background: #eef2ff;
  border-color: #c7d2fe;
}

/* Prop 65 notice */
#b360-cart-sc-modal .b360-cart-sc-body .prop65warning {
  margin-top: 12px;
  font-size: 0.85rem;
  color: var(--b360-muted);
  border-color: var(--b360-border) !important;
  border-radius: 12px;
}
#b360-cart-sc-modal .b360-cart-sc-body .prop65warning a {
  color: var(--b360-primary);
  text-decoration: underline;
}

/* Small screens */
@media (max-width: 520px) {
  #b360-cart-sc-modal .b360-cart-sc-body {
    padding: 14px;
  }
  #b360-cart-sc-modal .b360-cart-sc-body h2 {
    font-size: 1.1rem;
  }
  #b360-cart-sc-modal .b360-cart-sc-body .bottom {
    flex-direction: column;
  }
  #b360-cart-sc-modal .b360-cart-sc-body .bottom a {
    width: 100%;
  }
}
