/* File: shopping-multi-lojas/inc/carrinho/cart.css */

/* botão flutuante */
.sml-botao-pedido {
    position: fixed;
    right: 1.5em;
    bottom: 1.5em;
    z-index: 1000;
    background: #ff4b4b;
    color: #fff;
    border: none;
    border-radius: 50px;
    padding: 0.7em 1.5em;
    box-shadow: 0 2px 8px rgba(0,0,0,0.12);
    font-size: 1.2em;
    display: flex;
    align-items: center;
    gap: 0.6em;
}

/* sidebar */
.sml-pedido-sidebar {
    position: fixed;
    top: 0;
    right: -400px;
    width: 340px;
    max-width: 95vw;
    height: 100vh;
    background: #fff;
    box-shadow: -2px 0 12px rgba(0,0,0,0.18);
    transition: right 0.3s ease-in-out;
    z-index: 10000;
    display: flex;
    flex-direction: column;
}
.sml-pedido-sidebar.aberto {
    right: 0;
}

/* header da sidebar */
.sml-pedido-sidebar-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1em;
    background: #ff4b4b;
    color: #fff;
    font-size: 1.1em;
    font-weight: bold;
}
.sml-pedido-fechar {
    background: none;
    border: none;
    font-size: 1.5em;
    line-height: 1;
    color: #fff;
    cursor: pointer;
}

/* conteúdo scrollável */
.sml-pedido-sidebar-content {
    flex: 1;
    overflow-y: auto;
    padding: 1em;
}

/* lista de itens */
.sml-pedido-lista {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 0.75em;
}

/* item do carrinho */
.sml-pedido-item {
    display: flex;
    align-items: center;
    background: #fafafa;
    border-radius: 8px;
    padding: 0.75em;
    box-shadow: 0 1px 4px rgba(0,0,0,0.08);
    position: relative;
}

/* miniatura */
.sml-pedido-item-thumb {
    flex-shrink: 0;
    width: 50px;
    height: 50px;
    border-radius: 4px;
    overflow: hidden;
    background: #f0f0f0;
}
.sml-pedido-item-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.sml-pedido-thumb-placeholder {
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg,#eee,#ddd);
}

/* detalhes do item */
.sml-pedido-item-details {
    flex: 1;
    margin-left: 0.75em;
    display: flex;
    flex-direction: column;
    gap: 0.25em;
}
.sml-pedido-item-nome {
    font-weight: 600;
    font-size: 1em;
    color: #333;
}
.sml-pedido-item-cor,
.sml-pedido-item-tamanho,
.sml-pedido-item-quantidade,
.sml-pedido-item-preco {
    font-size: 0.9em;
    color: #555;
}

/* botão remover */
.sml-pedido-remover {
    position: absolute;
    top: 0.5em;
    right: 0.5em;
    background: none;
    border: none;
    font-size: 1em;
    color: #f44336;
    cursor: pointer;
}

/* botão enviar pedido */
.sml-pedido-enviar {
    width: calc(100% - 2em);
    margin: 1em;
    padding: 0.8em;
    background: #ff4b4b;
    color: #fff;
    border: none;
    border-radius: 6px;
    font-size: 1em;
    font-weight: 600;
    cursor: pointer;
}

/* footer da sidebar */
.sml-pedido-sidebar-footer {
    padding: 1em;
    border-top: 1px solid #eee;
    text-align: center;
}
.sml-pedido-todos {
    background: #ff4b4b;
    color: #fff;
    border: none;
    border-radius: 6px;
    padding: 0.6em 1.2em;
    font-size: 1em;
    cursor: pointer;
}

.sml-pedido-vazio {
    text-align: center;
    color: #888;
    padding: 2em 0;
}

/* Modal de WhatsApp */
#sml-whatsapp-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 10001;
}

.sml-whatsapp-modal-overlay {
    /* container para facilitar seleção por classe */
}

.sml-whatsapp-modal-container {
    position: relative;
    background: #ffffff;
    padding: 1.5em;
    border-radius: 8px;
    max-width: 90%;
    width: 380px;
    text-align: center;
}

.sml-whatsapp-modal-container h2 {
    margin-top: 0;
    font-size: 1.5em;
    color: #333;
}

.sml-whatsapp-modal-container p {
    margin: 1em 0;
    line-height: 1.4;
    color: #555;
}

.sml-whatsapp-modal-close {
    position: absolute;
    top: 8px;
    right: 12px;
    background: none;
    border: none;
    font-size: 1.5em;
    line-height: 1;
    cursor: pointer;
    color: #999;
}

.sml-modal-btn {
    display: inline-block;
    margin-top: 1em;
    padding: 0.8em 1.2em;
    background: #25D366;
    color: #fff;
    border: none;
    border-radius: 6px;
    font-size: 1em;
    text-decoration: none;
    cursor: pointer;
}
