/* Importação de fontes */
@import url("https://fonts.googleapis.com/css2?family=Playfair+Display:ital,wght@0,400;0,700;1,400&family=Satisfy&family=Montserrat:wght@400;500;600&display=swap");

/* Reset CSS */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

/* Variáveis CSS para cores */
:root {
  --pizza-primary: #d32f2f; /* Vermelho pizza */
  --pizza-secondary: #388e3c; /* Verde italiano */
  --pizza-accent: #fbc02d; /* Amarelo queijo */
  --pizza-dark: #121212; /* Fundo escuro */
  --pizza-darkgray: #1e1e1e; /* Cinza escuro */
  --pizza-light: #f5f5f5; /* Texto claro */
  --white: #ffffff;
  --cream: #fff8e1; /* Cor creme para detalhes */
  --gray-300: #d1d5db;
  --gray-400: #9ca3af;
  --gray-700: #374151;
  --green-500: #10b981;
  --red-500: #ef4444;
}

/* Estilos base */
html,
body {
  height: 100%;
  width: 100%;
  overflow: hidden;
  touch-action: manipulation;
  font-family: "Montserrat", sans-serif;
  -webkit-tap-highlight-color: transparent;
  background-color: var(--pizza-dark);
  color: var(--pizza-light);
  position: fixed;
  max-width: 100vw;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: "Playfair Display", serif;
}

/* Estilos para páginas */
.app-page {
  transition: opacity 0.3s ease, transform 0.3s ease;
  opacity: 0;
  transform: translateX(20px);
  pointer-events: none;
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  height: 100%;
  width: 100%;
  max-width: 786px;
  margin: auto;
  overflow: hidden;
  display: none;
  flex-direction: column;
  background-color: var(--pizza-dark);
}

.app-page.active {
  opacity: 1;
  transform: translateX(0);
  pointer-events: auto;
  display: flex;
}

/* Cabeçalho das páginas */
.page-header {
  background-color: var(--pizza-primary);
  padding: 12px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.page-header h2 {
  color: var(--white);
  font-size: 20px;
  font-weight: bold;
}

.back-btn {
  color: var(--white);
  background: none;
  border: none;
  font-size: 20px;
  cursor: pointer;
}

.spacer {
  width: 24px;
}

.container {
  display: flex;
  flex-direction: column;
  justify-content: center;
  height: 100%;
  padding-left: 24px;
  padding-right: 24px;
}

/* Conteúdo das páginas */
.page-content {
  flex: 1;
  overflow-y: auto;
  padding: 24px;
  -webkit-overflow-scrolling: touch;
  max-height: calc(100% - 120px); /* Ajuste para evitar overflow */
}

/* Rodapé das páginas */
.page-footer {
  padding: 20px;
  background-color: var(--pizza-darkgray);
}

/* Botões */
.btn {
  display: inline-block;
  padding: 12px;
  background-color: var(--pizza-secondary);
  color: var(--white);
  border: none;
  border-radius: 8px;
  font-weight: bold;
  cursor: pointer;
  text-align: center;
  width: 100%;
  font-family: "Montserrat", sans-serif;
  position: relative;
  overflow: hidden;
}

.btn-primary {
  background-color: var(--pizza-primary);
}

.btn-secondary {
  background-color: var(--pizza-secondary);
}

/* Efeito de ripple para botões */
.ripple:after {
  content: "";
  display: block;
  position: absolute;
  width: 100%;
  height: 100%;
  top: 0;
  left: 0;
  pointer-events: none;
  background-image: radial-gradient(circle, #fff 10%, transparent 10.01%);
  background-repeat: no-repeat;
  background-position: 50%;
  transform: scale(10, 10);
  opacity: 0;
  transition: transform 0.5s, opacity 1s;
}

.ripple:active:after {
  transform: scale(0, 0);
  opacity: 0.3;
  transition: 0s;
}

/* Animações para botões */
.app-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  justify-content: center;
  background-color: var(--pizza-primary);
  border-radius: 12px;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  border: none;
  color: var(--white);
  cursor: pointer;
  padding: 10px;
  position: relative;
}

.app-btn:active {
  transform: scale(0.95);
}

.app-btn .icon-circle {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background-color: var(--pizza-darkgray);
  display: flex;
  align-items: center;
  justify-content: center;
  justify-items: center;
  position: absolute;
  left: 5%;
}

.app-btn .icon-circle i {
  color: var(--pizza-accent);
  font-size: 18px;
}

.app-btn span {
  font-family: "Playfair Display", serif;
  font-size: 20px;
  font-weight: bold;
  text-align: center;
}

/* Grid de botões */
.buttons-grid {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

/* Logo e descrição */
.logo-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 16px 24px 24px 24px;
}

.app-title {
  font-size: 26px;
  font-weight: bold;
  color: var(--white);
  text-align: center;
  margin-top: 10px;
  margin-bottom: 8px;
}

.app-description {
  font-size: 14px;
  color: var(--gray-300);
  text-align: center;
  margin-bottom: 20px;
}

/* Modal Cart*/
.modal {
  position: fixed;
  inset: 0;
  z-index: 50;
  display: none;
  align-items: center;
  justify-content: center;
  background-color: rgba(0, 0, 0, 0.8);
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.3s ease, transform 0.3s ease;
  pointer-events: none;
}

.modal.active {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
  display: flex;
}

.modal-container {
  background-color: var(--pizza-dark);
  width: 100%;
  height: 100%;
  max-width: 786px;
  max-height: 100%;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.modal-header {
  background-color: var(--pizza-primary);
  padding: 12px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.modal-header h2 {
  color: var(--white);
  font-size: 20px;
  font-weight: bold;
}

.modal-content {
  flex: 1;
  overflow-y: auto;
  padding: 24px;
}

.modal-footer {
  padding: 24px;
  background-color: var(--pizza-dark);
}

.empty-cart-message {
  text-align: center;
  padding: 20px;
}

.order-note {
  margin-top: 24px;
}

.order-note h3 {
  color: var(--pizza-accent);
  font-size: 18px;
  margin-bottom: 12px;
  font-weight: bold;
  text-align: center;
}

.form-content {
  background-color: var(--pizza-darkgray);
  border-radius: 8px;
  padding: 16px;
  margin-bottom: 16px;
}

.tatal-content {
  margin-top: 24px;
  background-color: var(--pizza-darkgray);
  border-radius: 8px;
  padding: 16px;
}

.subtotal-info {
  display: flex;
  justify-content: space-between;
  margin-bottom: 8px;
}

.total-info {
  display: flex;
  justify-content: space-between;
  font-weight: bold;
  font-size: 18px;
}

#clear-cart {
  margin-bottom: 12px;
}

/* Formulário */
.form-group {
  margin-bottom: 16px;
}

.form-label {
  display: block;
  color: var(--white);
  margin-bottom: 8px;
  font-size: 14px;
}

.form-control {
  width: 100%;
  padding: 12px 16px;
  background-color: var(--pizza-dark);
  border: 1px solid var(--gray-700);
  border-radius: 8px;
  color: var(--white);
  font-family: "Poppins", sans-serif;
  transition: all 0.3s ease;
  -webkit-appearance: none;
  appearance: none;
}

.form-control:focus {
  outline: none;
  border-color: var(--pizza-dark);
}

textarea.form-control {
  resize: vertical;
  min-height: 80px;
}

.radio-items {
  display: flex;
  gap: 20px;
  margin-bottom: 14px;
}

.radio-items div {
  display: flex;
  flex-direction: row;
  gap: 5px;
}

#address-block {
  display: none;
}

/* Cartões de produtos */
.category-name {
  color: var(--pizza-accent);
  font-size: 22px;
  margin-bottom: 12px;
  font-weight: bold;
  text-align: center;
}

.product-card {
  background-color: var(--pizza-darkgray);
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
  margin-bottom: 24px;
}

.btn-add-cart,
#add-half-pizza {
  background-color: var(--pizza-secondary);
  font-family: "Montserrat", sans-serif;
  color: white;
  border: none;
  border-radius: 4px;
  padding: 6px 12px;
  font-size: 14px;
  cursor: pointer;
  transition: background-color 0.2s;
}

.btn-add-cart:hover,
#add-half-pizza {
  background-color: #2e7d32;
}

.cart-count {
  display: inline-block;
  background-color: var(--pizza-accent);
  color: var(--pizza-dark);
  border-radius: 50%;
  width: 20px;
  height: 20px;
  font-size: 12px;
  line-height: 20px;
  text-align: center;
  margin-left: 8px;
  font-weight: bold;
}

.product-card-content {
  padding: 10px;
  display: flex;
  align-items: start;
}

.product-icon {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background-color: var(--pizza-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-right: 16px;
}

.product-icon i {
  color: var(--pizza-accent);
  font-size: 20px;
}

.product-image {
  width: 80px;
  height: 80px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-right: 8px;
}

.product-image img {
  border-radius: 8px;
  width: 100%;
  height: 100%;
}

.product-info {
  flex: 1;
}

.product-title {
  font-size: 20px;
  font-weight: bold;
  color: var(--pizza-accent);
}

.product-description {
  font-size: 14px;
  color: var(--gray-300);
}

.product-card-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0 10px 10px 10px;
}

.product-price {
  font-size: 18px;
  font-weight: bold;
  color: var(--white);
  text-align: right;
}

/* Galeria */
.gallery-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.gallery-item {
  height: 140px;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Sobre */
.about-logo {
  display: flex;
  align-items: center;
  justify-items: center;
  justify-content: center;
  width: 100%;
}

.about-logo img {
  width: 96px;
  height: 96px;
}

.about-section {
  margin-bottom: 24px;
}

.about-title {
  font-size: 18px;
  font-weight: bold;
  color: var(--pizza-accent);
  margin-bottom: 8px;
}

.about-text {
  font-size: 14px;
  color: var(--gray-300);
}

.about-values {
  margin-top: 8px;
}

.value-item {
  display: flex;
  align-items: center;
  margin-bottom: 8px;
}

.value-item i {
  color: var(--pizza-secondary);
  font-size: 14px;
  margin-right: 8px;
}

.value-text {
  font-size: 14px;
  color: var(--gray-300);
}

.contact-item {
  display: flex;
  align-items: center;
  margin-bottom: 8px;
}

.contact-item i {
  color: var(--pizza-secondary);
  font-size: 14px;
  margin-right: 8px;
}

.contact-text {
  font-size: 14px;
  color: var(--gray-300);
}

.social-links {
  display: flex;
  justify-content: center;
  gap: 16px;
  padding-top: 16px;
}

.social-link {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background-color: var(--pizza-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--pizza-accent);
  transition: background-color 0.3s ease, color 0.3s ease;
  text-decoration: none;
}

.social-link:hover {
  background-color: var(--pizza-secondary);
  color: var(--white);
}

/* Localização */
.map-container {
  background-color: var(--pizza-darkgray);
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  margin-bottom: 20px;
}

.location-section {
  margin-bottom: 24px;
}

.location-title {
  font-size: 18px;
  font-weight: bold;
  color: var(--pizza-accent);
  margin-bottom: 8px;
}

.location-item {
  display: flex;
  margin-bottom: 16px;
}

.location-icon {
  color: var(--pizza-secondary);
  font-size: 18px;
  margin-right: 12px;
  margin-top: 4px;
}

.location-content {
  flex: 1;
}

.location-name {
  color: var(--white);
  font-weight: 500;
}

.location-text {
  color: var(--gray-300);
}

.location-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.location-btn {
  display: flex;
  align-items: center;
  justify-content: center;
}

.location-btn i {
  margin-right: 8px;
}

.cart-item {
  background-color: var(--pizza-darkgray);
  border-radius: 8px;
  padding: 16px;
  margin-bottom: 16px;
  position: relative;
}

.cart-content {
  display: flex;
  justify-content: space-between;
  margin-bottom: 8px;
}

.cart-content h3 {
  font-weight: bold;
  color: var(--pizza-accent);
  margin-bottom: 10px;
}

.remove-item {
  background: none;
  border: none;
  color: var(--red-500);
  cursor: pointer;
  font-size: 20px;
  position: absolute;
  right: 5px;
  top: 5px;
}

.quantity-btn {
  width: 30px;
  height: 30px;
  background-color: var(--pizza-primary);
  border: none;
  border-radius: 4px;
  color: white;
  cursor: pointer;
}

.quantity-items {
  display: flex;
  align-items: center;
}

.quantity-items span {
  margin: 0 10px;
  min-width: 20px;
  text-align: center;
}

/* Success Modal */
.success-modal-container {
  background-color: var(--pizza-dark);
  width: 83.333%;
  max-width: 384px;
  border-radius: 12px;
  overflow: hidden;
  padding: 24px;
  text-align: center;
}

.success-icon {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  background-color: var(--green-500);
  margin: 0 auto 16px auto;
  display: flex;
  align-items: center;
  justify-content: center;
}

.success-icon i {
  color: var(--white);
  font-size: 32px;
}

.success-title {
  font-size: 20px;
  font-weight: bold;
  color: var(--pizza-accent);
  margin-bottom: 8px;
}

.success-message {
  color: var(--gray-300);
  margin-bottom: 24px;
}

/* Info Modal */
.info-modal-container {
  background-color: var(--pizza-dark);
  width: 83.333%;
  max-width: 384px;
  border-radius: 12px;
  overflow: hidden;
  padding: 24px;
  text-align: center;
}

.info-icon {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  background-color: var(--pizza-primary);
  margin: 0 auto 16px auto;
  display: flex;
  align-items: center;
  justify-content: center;
}

.info-icon i {
  color: var(--white);
  font-size: 32px;
}

.info-message {
  color: var(--gray-300);
  margin-bottom: 24px;
}

/* Option Modal */
.confirm-modal-container {
  background-color: var(--pizza-dark);
  width: 83.333%;
  max-width: 384px;
  border-radius: 12px;
  overflow: hidden;
  padding: 24px;
  text-align: center;
}

.confirm-icon {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  background-color: var(--pizza-primary);
  margin: 0 auto 16px auto;
  display: flex;
  align-items: center;
  justify-content: center;
}

.confirm-icon i {
  color: var(--white);
  font-size: 32px;
}

.confirm-message {
  color: var(--gray-300);
  margin-bottom: 24px;
}

.btn-container {
  display: flex;
  gap: 8px;
}

.yes {
  background-color: var(--pizza-primary);
}

/* Toast Modal */
.toast-modal-container {
  background-color: var(--pizza-dark);
  width: 75%;
  max-width: 384px;
  border-radius: 12px;
  overflow: hidden;
  padding: 8px;
  text-align: center;
}

.toast-icon {
  width: 60px;
  height: 60px;
  border-radius: 50%;
  background-color: var(--pizza-secondary);
  margin: 0 auto 16px auto;
  display: flex;
  align-items: center;
  justify-content: center;
}

.toast-icon i {
  color: var(--white);
  font-size: 28px;
}

.toast-message {
  color: var(--gray-300);
  margin-bottom: 10px;
}

/* Animações */
@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.animate-fade-in {
  animation: fadeIn 0.3s ease forwards;
}

@keyframes pulse {
  0% {
    transform: scale(1);
  }
  50% {
    transform: scale(1.05);
  }
  100% {
    transform: scale(1);
  }
}

.back-btn:active {
  animation: pulse 0.3s ease;
}

@keyframes slideInRight {
  from {
    transform: translateX(100%);
    opacity: 0;
  }
  to {
    transform: translateX(0);
    opacity: 1;
  }
}

.slide-in-right {
  animation: slideInRight 0.3s ease forwards;
}

@keyframes slideOutRight {
  from {
    transform: translateX(0);
    opacity: 1;
  }
  to {
    transform: translateX(100%);
    opacity: 0;
  }
}

.slide-out-right {
  animation: slideOutRight 0.3s ease forwards;
}

@keyframes slideUp {
  from {
    transform: translateY(100%);
    opacity: 0;
  }
  to {
    transform: translateY(0);
    opacity: 1;
  }
}

.slide-up {
  animation: slideUp 0.3s ease forwards;
}

@keyframes slideDown {
  from {
    transform: translateY(0);
    opacity: 1;
  }
  to {
    transform: translateY(100%);
    opacity: 0;
  }
}

.slide-down {
  animation: slideDown 0.3s ease forwards;
}

/* Animação para carregamento da página */
.app-container {
  opacity: 0;
  transform: translateY(10px);
  animation: appLoad 0.5s ease forwards 0.2s;
}

@keyframes appLoad {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Estilos para scrollbar */
.app-page::-webkit-scrollbar,
.modal-content::-webkit-scrollbar {
  width: 4px;
}

.app-page::-webkit-scrollbar-track,
.modal-content::-webkit-scrollbar-track {
  background: rgba(30, 30, 30, 0.5);
}

.app-page::-webkit-scrollbar-thumb,
.modal-content::-webkit-scrollbar-thumb {
  background: var(--barber-primary);
  border-radius: 4px;
}

/* Utilitários */
.mb-6 {
  margin-bottom: 24px;
}

.space-y-6 > * + * {
  margin-top: 24px;
}

.space-y-2 > * + * {
  margin-top: 8px;
}

.alert {
  color: var(--pizza-dark) !important;
  background-color: var(--pizza-accent) !important;
}
