Not legal. Unless they are located in CA, it is not legal for them to collect CA taxes. Shipping cost is excluded from taxes if the item not taxable. In this case they can not tax the item as they are not located in CA. I would then let them know that it is a reportable offense. Please note in-state in quote below.
"Sales taxes, including those imposed by local governments, are generally administered at the state level. States imposing sales tax require retail sellers to collect tax from customers, file returns, and remit the tax to the state. Procedural rules vary widely. Sellers generally must collect tax from in-state purchasers unless the purchaser provides an exemption certificate. Most states allow or require electronic remittance."