:root {
  font-size: 62.5%; /* 1rem = 10px */
}

body {
  background-color: #f9f9f9;
  margin: 0;
  font-family: system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  font-size: 1.6rem;
}

.page-wrapper {
  width: 100%;
  max-width: 430px;
  margin: 0 auto;
  padding: 0 1rem;
  box-sizing: border-box;
}

.container {
  display: flex;
  flex-direction: column;
  /* min-height: 100vh; */
}


/* Fixar header no topo */
/* header {
  position: fixed;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 100%;
  max-width: 430px; 
  z-index: 1000;
  height: 25vh;
  /* background-image dependia de categoria_pizzaz.jpeg (inexistente); removido para evitar erro no collectstatic */
  background-image: none;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
} */

.sobreposta {
  margin-top: 20vh;
  margin-bottom: 2rem;
  margin-left: 2rem;
  margin-right: 2rem;
  /* width: 90%; */
  /* max-width: 360px; */
  text-align: center;
  font-size: 2.8rem;
  background-color: white;
  padding: 2rem 2rem 2rem;
  border-radius: 2rem;
  box-shadow: rgba(0, 0, 0, 0.9) 0px 4px 10px;
  z-index: 10;
  position: relative;
}



.logo-container {
  position: absolute;
  top: -50px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 11;
}

.logo {
  width: 80px;
  height: 80px;
  object-fit: cover;
  border-radius: 50%;
  background: white;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
  border: 4px solid white;
}

main {
  margin-top: 33vh;
  margin-bottom: 12vh;
  margin-left: 1rem;
  margin-right: 1rem;
  overflow-y: auto;
}

.categoria {
  background-color: #ffffff75;
  border-radius: 2rem;
  padding: 1.2rem;
  margin: 2.2rem 0;
  text-align: center;
  font-size: 2.2rem;
  font-family: 'Poppins', sans-serif;
  color: #000000;
  box-shadow: rgba(0, 0, 0, .2) 0 3px 5px -1px,
              rgba(0, 0, 0, .34) 0 6px 10px 0,
              rgba(0, 0, 0, .12) 0 1px 18px 0;
  display: flex;
  justify-content: center;
  align-items: center;
}

.link-carrinho {
  font-size: 2.4rem;
  text-decoration: none;
  color: #be2626;
  margin-top: 0.5rem;
  background: transparent;
  border: none;
}

.link-carrinho.ativo {
  animation: pulso 2s ease-in-out infinite;
  color: #be2626;
  font-weight: bold;
}

@keyframes pulso {
  0% { transform: scale(1); }
  50% { transform: scale(1.25); }
  100% { transform: scale(1); }
}


/* Fixar footer no fundo */
footer {
  position: fixed;
  bottom: 0;
  left: 0;
  width: 100%;
  z-index: 1000;
  background-color: #ffffff;
  color: #000000;
  height: 10vh;
  text-align: center;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.4rem;
}

#footer-botoes {
  width: 100%;
  display: flex;
  flex-wrap: nowrap;
  flex-direction: row;
  justify-content: space-evenly;
  align-items: stretch;
}

.item-pedido {
  background-color: #ffffff;
  padding-top: 1rem;
  border-radius: 1rem;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.25);
  margin: 3rem;
}

.item-pedido h3 {
  font-size: 2.4rem;
  color: #be2626;
  margin: 0.5rem 0;
}

.itens-pedido {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.linha-item {
  display: flex;
  justify-content: space-between;
  gap: 1.5rem;
  background-color: #fff;
  border-radius: 15px;
  padding: 0.8rem 1rem;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
}

.coluna-esquerda, .coluna-direita {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  font-size: 2rem;
}

.total {
  display: flex;
  justify-content: space-evenly;
  align-items: flex-end;
  font-size: 2.6rem;
  flex-direction: row;
  margin: 2.5rem;
  padding: 2.5rem;
}

.hidden {
  display: none;
}

/* Media queries para celulares menores */
@media (max-width: 380px) {
  .categoria {
    font-size: 1.8rem;
    padding: 1rem;
  }

  .link-carrinho {
    font-size: 2rem;
  }

  .sobreposta {
    font-size: 2.5rem;
    padding-top: 4rem;
  }

  .item-pedido h3 {
    font-size: 2rem;
  }

  .linha-item {
    font-size: 1.6rem;
    padding: 0.6rem 0.8rem;
  }

  .total {
    font-size: 2rem;
    padding: 2rem;
  }

  .logo {
    width: 80px;
    height: 80px;
  }
}

/* 
  =====================================
  Fundo fixo com compatibilidade total
  =====================================
  Este elemento <div class="background-fixa"></div> é posicionado fixamente 
  atrás de todo o conteúdo, simulando um "background-attachment: fixed" 
  de forma compatível com todos os navegadores, inclusive mobile.
*/
/* .background-fixa {
  position: fixed;   
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  z-index: -1;               
  background-image: url('/static/imagens/fundo.png');
  background-size: cover;   
  background-position: center;
  background-repeat: no-repeat;
  opacity: 1;      
} */

.background-fixa::before {
  content: '';
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background-color: rgba(255, 255, 255, 0.2); /* branco com transparência */
  z-index: 1; /* abaixo de tudo, acima apenas da imagem */
  pointer-events: none; /* para não interferir com cliques */
}


/* Efeito de destaque para itens visíveis no centro */
.categoria.destacada {
  transform: scale(1.1);
  opacity: 1;
  transition: transform 0.3s ease, opacity 0.3s ease;
}

/* Estilo padrão dos itens */
.categoria {
  opacity: 0.7;
  transition: transform 0.3s ease, opacity 0.3s ease;
}
