.drawer-overlay,
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.5);
  opacity: 0;
  pointer-events: none;
  transition: 0.3s;
  z-index: 999;
  display: flex;
  align-items: center;
  justify-content: center;
}

.drawer-overlay.open,
.modal-overlay.open {
  opacity: 1;
  pointer-events: auto;
}

.drawer {
  position: fixed;
  top: 0;
  right: -400px;
  width: 400px;
  height: 100vh;
  background: var(--surface);
  z-index: 1000;
  transition: right 0.3s;
  display: flex;
  flex-direction: column;
}

.drawer.open {
  right: 0;
}

.drawer-head,
.drawer-foot {
  padding: 24px;
  border-bottom: 1px solid var(--line);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.drawer-foot {
  border-bottom: none;
  border-top: 1px solid var(--line);
  flex-direction: column;
  gap: 16px;
}

.drawer-body {
  flex: 1;
  overflow-y: auto;
  padding: 24px;
}

.drawer-total {
  display: flex;
  justify-content: space-between;
  width: 100%;
  font-weight: 800;
  font-size: 18px;
}

.close-btn {
  background: none;
  border: none;
  font-size: 24px;
  cursor: pointer;
  position: absolute;
  top: 16px;
  right: 16px;
}

.cart-item {
  display: flex;
  gap: 16px;
  margin-bottom: 24px;
  align-items: center;
}

.cart-item img {
  width: 80px;
  height: 80px;
  object-fit: cover;
  border-radius: 8px;
}

.cart-item .name {
  font-weight: 600;
  font-size: 14px;
}

.cart-item .meta {
  font-size: 12px;
  color: var(--ink-soft);
  margin-bottom: 8px;
}

.cart-item .qty {
  display: flex;
  align-items: center;
  gap: 12px;
  border: 1px solid var(--line);
  width: fit-content;
  padding: 4px 8px;
  border-radius: 4px;
}

.cart-item .qty button {
  border: none;
  background: none;
  cursor: pointer;
  font-weight: bold;
}

.cart-item .remove {
  font-size: 12px;
  color: #ef4444;
  cursor: pointer;
  margin-top: 8px;
  text-align: right;
  font-weight: 600;
}

.cart-empty-message {
  text-align: center;
  padding: 40px 20px;
  color: var(--ink-soft);
}

.cart-item-details {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.cart-item-right {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 8px;
  min-width: 90px;
}

.cart-item-price {
  font-weight: 700;
  color: var(--accent);
  font-size: 14px;
}
