/* RESET */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: Arial, Helvetica, sans-serif;
}

body {
    background: #fff9e6;
    color: #333;
}

/* HEADER */
header {
    background: #fbbf24;
    padding: 15px;
    text-align: center;
    font-size: 1.4rem;
    font-weight: bold;
    color: #92400e;
    box-shadow: 0 2px 5px rgba(0,0,0,0.2);
}

/* LISTA DE PRODUTOS */
.products {
    display: flex;
    flex-direction: column;
    gap: 12px;
    padding: 10px;
}

/* CARD */
.card {
    display: grid;
    grid-template-columns: 90px 1fr 90px;
    gap: 10px;
    background: #fff;
    border-radius: 14px;
    padding: 8px;
    align-items: center;
    box-shadow: 0 2px 6px rgba(0,0,0,0.1);
}

/* IMAGEM */
.img-container {
    width: 90px;
    height: 90px;
    overflow: hidden;
    border-radius: 10px;
    flex-shrink: 0;
}

.img-container img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* CARD INFO (MEIO) */
.card-info {
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.card-info h3 {
    font-size: 0.95rem;
    color: #92400e;
    margin-bottom: 4px;
}

.card-info p {
    font-size: 0.85rem;
    font-weight: bold;
    margin-bottom: 6px;
}

/* EXTRAS */
.extras {
    display: flex;
    flex-direction: column;
    gap: 4px;
    max-height: 90px;
    overflow-y: auto;
    transition: all 0.2s ease;
}

.extras.closed {
    display: none;
}

.extra-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.75rem;
}

.extra-controls {
    display: flex;
    gap: 4px;
}

.extra-controls button {
    background: #fbbf24;
    border: none;
    padding: 2px 6px;
    border-radius: 6px;
    font-weight: bold;
    cursor: pointer;
    color: #92400e;
}

.extra-controls input {
    width: 26px;
    text-align: center;
    border-radius: 6px;
    border: 1px solid #fbbf24;
    font-size: 12px;
}

/* BOTÃO ADICIONAR */
.card-btn button {
    width: 100%;
    height: 100%;
    background: #22c55e;
    color: white;
    border: none;
    border-radius: 12px;
    font-weight: bold;
    font-size: 0.8rem;
    cursor: pointer;
}

.card-btn button:hover {
    background: #16a34a;
}

/* BOTÃO MOSTRAR EXTRAS */
.toggle-extras {
    background: transparent;
    border: none;
    color: #92400e;
    font-size: 0.75rem;
    font-weight: bold;
    cursor: pointer;
    padding: 2px 0;
    text-align: left;
}

/* BOTÃO CARRINHO */
#cart-btn {
    position: fixed;
    right: 15px;
    bottom: 15px;
    background: #fbbf24;
    padding: 14px 18px;
    border-radius: 40px;
    font-weight: bold;
    color: #92400e;
    cursor: pointer;
    box-shadow: 0 3px 8px rgba(0,0,0,0.3);
    z-index: 1000;
}

/* SIDEBAR CARRINHO */
#cart-sidebar {
    position: fixed;
    top: 0;
    right: -100%;
    width: 90%;
    max-width: 360px;
    height: 100%;
    background: #fff;
    padding: 15px;
    transition: 0.3s;
    z-index: 999;
    overflow-y: auto;
    box-shadow: -2px 0 10px rgba(0,0,0,0.3);
}

#cart-sidebar.active {
    right: 0;
}

/* ITENS DO CARRINHO */
.cart-item {
    display: flex;
    align-items: center;
    gap: 10px;
    background: #f8fafc;
    padding: 8px;
    border-radius: 10px;
    margin-bottom: 8px;
}

.cart-item img {
    width: 55px;
    height: 55px;
    object-fit: cover;
    border-radius: 6px;
}

.cart-item-info {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 3px;
    font-size: 0.8rem;
}

.cart-item-info strong {
    color: #92400e;
}

.cart-extras span {
    display: flex;
    justify-content: space-between;
    font-size: 0.75rem;
}

.cart-extras button {
    background: #dc2626;
    color: #fff;
    border: none;
    padding: 2px 6px;
    border-radius: 6px;
    cursor: pointer;
    margin-left: 4px;
}

.remove-item {
    background: #dc2626;
    color: #fff;
    border: none;
    padding: 6px;
    border-radius: 6px;
    cursor: pointer;
    font-size: 0.75rem;
}

/* BOTÃO FECHAR CARRINHO */
.close-btn {
    background: #fbbf24;
    border: none;
    padding: 8px;
    border-radius: 8px;
    margin-bottom: 10px;
    cursor: pointer;
    font-weight: bold;
}

/* TIPO DE PEDIDO */
.tipo-btn {
    flex: 1;
    padding: 8px;
    border-radius: 8px;
    border: none;
    font-weight: bold;
    cursor: pointer;
    background: #e5e7eb;
    margin-right: 4px;
}

.tipo-btn.selected {
    background: #22c55e;
    color: #fff;
}

/* BOTÃO FINALIZAR */
#finalizar-btn {
    width: 100%;
    margin-top: 10px;
    padding: 14px;
    background: #22c55e;
    color: white;
    border: none;
    border-radius: 40px;
    font-weight: bold;
    cursor: pointer;
}

/* RESPONSIVO */
@media (max-width: 420px) {
    .card {
        grid-template-columns: 80px 1fr 80px;
    }

    .img-container {
        width: 80px;
        height: 80px;
    }
}