/* SYL & ECO — Cart styles
   Override these variables to match your site's palette/fonts. */
:root {
  --cart-bg: #ffffff;
  --cart-text: #1a1a1a;
  --cart-muted: #888888;
  --cart-border: #e5e5e5;
  --cart-accent: #1a1a1a;
  --cart-accent-text: #ffffff;
  --cart-radius: 8px;
}

.cart-toggle-btn {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 1000;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: var(--cart-accent);
  color: var(--cart-accent-text);
  border: none;
  font-size: 22px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.2);
}

.cart-count {
  position: absolute;
  top: -4px;
  right: -4px;
  background: #e53935;
  color: #fff;
  border-radius: 50%;
  font-size: 11px;
  min-width: 18px;
  height: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 3px;
}

.cart-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.4);
  z-index: 1001;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease;
}
.cart-overlay.cart-open {
  opacity: 1;
  pointer-events: auto;
}

.cart-drawer {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  width: min(380px, 100vw);
  background: var(--cart-bg);
  color: var(--cart-text);
  z-index: 1002;
  display: flex;
  flex-direction: column;
  transform: translateX(100%);
  transition: transform 0.25s ease;
  font-family: inherit;
}
.cart-drawer.cart-open {
  transform: translateX(0);
}

.cart-drawer-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px;
  border-bottom: 1px solid var(--cart-border);
}
.cart-drawer-header h2 {
  margin: 0;
  font-size: 18px;
}
.cart-close-btn {
  background: none;
  border: none;
  font-size: 24px;
  cursor: pointer;
  color: var(--cart-text);
  line-height: 1;
}

.cart-items {
  flex: 1;
  overflow-y: auto;
  padding: 12px 20px;
}
.cart-empty {
  color: var(--cart-muted);
  text-align: center;
  margin-top: 40px;
}

.cart-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 0;
  border-bottom: 1px solid var(--cart-border);
}
.cart-item-img {
  width: 48px;
  height: 48px;
  object-fit: cover;
  border-radius: 4px;
  flex-shrink: 0;
}
.cart-item-info {
  flex: 1;
  min-width: 0;
}
.cart-item-name {
  margin: 0 0 4px;
  font-size: 14px;
  font-weight: 600;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.cart-item-price {
  margin: 0;
  font-size: 13px;
  color: var(--cart-muted);
}
.cart-item-remove {
  background: none;
  border: none;
  color: var(--cart-muted);
  font-size: 18px;
  cursor: pointer;
  flex-shrink: 0;
}

.cart-drawer-footer {
  padding: 16px 20px 20px;
  border-top: 1px solid var(--cart-border);
}
.cart-total-row {
  display: flex;
  justify-content: space-between;
  font-weight: 700;
  font-size: 16px;
  margin-bottom: 12px;
}
.cart-checkout-btn {
  width: 100%;
  padding: 13px;
  background: var(--cart-accent);
  color: var(--cart-accent-text);
  border: none;
  border-radius: var(--cart-radius);
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
}
.cart-checkout-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}
.cart-note {
  margin: 10px 0 0;
  font-size: 12px;
  color: var(--cart-muted);
  text-align: center;
}
