/* ==============================
   CARRINHO
============================== */
/* ==============================
   PAINEL
============================== */

.painel-carrinho {
  position: absolute;

  width: 350px;
  height: 550px;
  max-width: 100%;

  visibility: hidden;

  display: flex;
  flex-direction: column;

  background: #1c1111;
  border: 1px solid #3d2424;
  border-radius: 20px;
  box-shadow: -10px 0 40px rgba(0, 0, 0, 0.45);

  /* começa fora da tela, à direita */
  transform: translateX(300%);

  transition:
    transform 0.5s ease,
    visibility 0s linear 0.5s;
}

#painel-carrinho.aberto {
  visibility: visible;
  z-index: 100;

  /* vai para a posição central */
  transform: translateX(0);

  transition:
    transform 0.5s ease,
    visibility 0s;
}

/* BOTÃO DO CARRINHO */

.btn-carrinho {
  width: 55px;
  height: 55px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid #5a3030;
  border-radius: 50%;
  background: #291515;
  color: #fff;
  font-size: 24px;
  cursor: pointer;
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.35);
  transition: 0.2s ease;
}

.btn-carrinho:hover {
  background: #4a2020;
  width: 59px;
  height: 59px;

}

/* CONTADOR */

#contador-carrinho {
  position: absolute;
  top: 16px;
  right: 42px;
  min-width: 22px;
  height: 22px;
  padding: 0 5px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: #b85c3a;
  color: #fff;
  font-size: 12px;
  font-weight: bold;
  border: 2px solid #1c1111;
}

#contador-carrinho:hover {
  transform: scale(1.05);

}


/* ==============================
   HEADER DO CARRINHO
============================== */

.carrinho-header {
  display: flex;
  justify-content: space-around;
  padding: 20px;
  background: #291515;
  border-bottom: 1px solid #3d2424;
  height: 90px;
  border-radius: 10px 0;
  text-align: center;
}

.carrinho-header h2 {
  color: #ffffff;
  font-size: 1.2rem;
  padding-top: 17px;

}

.carrinho-header button {
  background: transparent;
  color: #c7a8a8;
  cursor: pointer;
  transition: 0.2s ease;
  font-weight: bold;
}

.carrinho-header button:hover {
  color: #fff;

}

/* ==============================
   LISTA
============================== */

.lista-carrinho {
  flex: 1;
  overflow-y: auto;
  padding: 20px;
}

/* ==============================
   ITEM
============================== */

.item-carrinho {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 15px 0;
  border-bottom: 1px solid #3d2424;
}

.item-emoji {
  font-size: 35px;
}

.item-info {
  flex: 1;
}

/* ==============================
   CONTROLE DE QUANTIDADE
============================== */

.controle-quantidade {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 8px;
}

.controle-quantidade span {
  min-width: 25px;
  text-align: center;
  color: #fff;
  font-size: 14px;
  font-weight: bold;
}

.btn-quantidade {
  width: 26px;
  height: 26px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid #5a3030;
  border-radius: 6px;
  background: #291515;
  color: #fff;
  font-size: 18px;
  line-height: 1;
  cursor: pointer;
  transition: 0.2s ease;
}

.btn-quantidade:hover {
  background: #4a2020;
  border-color: #b85c3a;
}

.item-info h3 {
  margin-bottom: 5px;
  color: #fff;
  font-size: 16px;
}

.item-info span {
  color: #c7a8a8;
  font-size: 14px;
}

.item-subtotal {
  color: #fff;

  font-weight: bold;
}

/* ==============================
   REMOVER
============================== */

.btn-remover {
  border: none;
  background: transparent;
  color: #b85c3a;
  cursor: pointer;
  font-size: 16px;
  transition: 0.2s ease;
}

.btn-remover:hover {
  color: #d36d47;
}

/* ==============================
   FOOTER
============================== */

.carrinho-footer {
  padding: 20px;
  background: #291515;
  border-top: 1px solid #3d2424;
}

.carrinho-total {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 15px;
  color: #fff;
  font-size: 18px;
}

.carrinho-total strong {
  color: #d36d47;
}

/* ==============================
   FINALIZAR
============================== */

.btn-finalizar {
  width: 100%;
  padding: 14px;
  border: none;
  border-radius: 10px;
  background: #b85c3a;
  color: #fff;
  font-size: 16px;
  font-weight: bold;
  cursor: pointer;
  transition: 0.2s ease;
}

.btn-finalizar:hover {
  background: #d36d47;
}

/* ==============================
   CARRINHO VAZIO
============================== */

.carrinho-vazio {
  height: 100%;

  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  color: #8f7777;
}

.resumo-pedido {
  width: min(100%, 420px);
  padding: 18px;
}

.resumo-header {
  font-size: 1.05rem;
  margin-bottom: 16px;
  padding-bottom: 12px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.resumo-itens {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.resumo-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 15px;
}

.resumo-item-info {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}

.resumo-emoji {
  font-size: 1.5rem;
}

.resumo-item-info div {
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.resumo-item-info strong {
  font-size: 0.95rem;
}

.resumo-item-info small {
  opacity: 0.7;
}

.resumo-item>strong {
  white-space: nowrap;
}

.resumo-total {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 16px;
  padding-top: 14px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  font-size: 1.05rem;
}

.resumo-total strong {
  font-size: 1.2rem;
}

.resumo-dados {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: 18px;
  padding-top: 15px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.resumo-dados div {
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.resumo-dados span {
  font-size: 0.8rem;
  opacity: 0.65;
}

.resumo-dados strong {
  font-size: 0.9rem;
  line-height: 1.4;
  word-break: break-word;
}

.resumo-confirmacao {
  display: flex;
  flex-direction: column;
  gap: 5px;
  margin-top: 18px;
  padding-top: 15px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.resumo-confirmacao strong {
  font-size: 0.9rem;
}


.resumo-valores {
  display: flex;
  flex-direction: column;
  gap: 8px;

  margin-top: 16px;
  padding-top: 14px;

  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.resumo-valor {
  display: flex;
  justify-content: space-between;
  align-items: center;

  font-size: 0.9rem;
}

.resumo-valor span {
  opacity: 0.75;
}

.resumo-total {
  display: flex;
  justify-content: space-between;
  align-items: center;

  margin-top: 6px;
  padding-top: 12px;

  border-top: 1px solid rgba(255, 255, 255, 0.1);

  font-size: 1.05rem;
}

.resumo-total strong {
  font-size: 1.2rem;
}