.popup-cookies {
  position: fixed;
  z-index: 9999;
  box-sizing: border-box;
  pointer-events: none;
  bottom: 16px;
  right: 16px;
  left: 16px;
  width: auto;
  max-width: 640px;
  margin: 0 auto;
  opacity: 0;
  visibility: hidden;
  transform: translateY(20px);
  transition: all 0.3s ease;
}

.popup-cookies--visivel {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: translateY(0);
}

.popup-cookies__content {
  background: #ffffff;
  padding: 20px;
  border-radius: 8px;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.1);
  width: 100%;
  box-sizing: border-box;
}

.popup-cookies__texto {
  color: #666666;
  font-size: 14px;
  line-height: 1.5;
  margin: 0 0 20px;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen,
    Ubuntu, Cantarell, sans-serif;
}

.popup-cookies__texto a {
  color: #b91c1c;
  text-decoration: none;
}

.popup-cookies__texto a:hover {
  text-decoration: underline;
}

.popup-cookies__acoes {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 12px;
}

.popup-cookies__botao {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  min-height: 40px;
  padding: 8px 24px;
  border-radius: 8px;
  cursor: pointer;
  text-align: center;
  background: transparent;
  border: 1px solid #e5e7eb;
  color: #666666;
  transition: all 0.3s ease;
  white-space: nowrap;
  text-decoration: none;
  width: auto;
  min-width: 120px;
  font-family: inherit;
  font-weight: normal;
}

.popup-cookies__botao:hover {
  background: rgba(185, 28, 28, 0.1);
  border-color: #b91c1c;
  color: #b91c1c;
}

.popup-cookies__botao:focus-visible {
  outline: 2px solid rgba(185, 28, 28, 0.3);
  outline-offset: 2px;
}

.popup-cookies__botao--personalizar {
  border-color: #b91c1c;
  color: #b91c1c;
}

.popup-cookies__botao--rejeitar {
  border-color: #e5e7eb;
}

.popup-cookies__botao--aceitar {
  border-color: #b91c1c;
  background: #b91c1c;
  color: #ffffff;
}

.popup-cookies__botao--aceitar:hover {
  background: #a31919;
  color: #ffffff;
}

/* Popup de Preferências */
.popup-preferencias {
  position: fixed;
  inset: 0;
  z-index: 10000;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, 0.5);
  padding: 16px;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: all 0.3s ease;
}

.popup-preferencias--visivel {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

.popup-preferencias__content {
  background: #ffffff;
  width: 100%;
  max-width: 500px;
  border-radius: 8px;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.1);
  padding: 24px;
  position: relative;
  max-height: calc(100vh - 32px);
  overflow-y: auto;
  box-sizing: border-box;
}

.popup-preferencias__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 24px;
}

.popup-preferencias__titulo {
  font-size: 18px;
  font-weight: 600;
  color: #666666;
  margin: 0;
}

.popup-preferencias__fechar {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 4px;
  font-size: 20px;
  border: none;
  background: transparent;
  color: #666666;
  cursor: pointer;
  transition: all 0.3s ease;
}

.popup-preferencias__fechar:hover {
  background: rgba(185, 28, 28, 0.1);
  color: #b91c1c;
}

.popup-preferencias__corpo {
  color: #666666;
  margin-bottom: 24px;
}

.popup-preferencias__opcoes {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.popup-preferencias__opcao {
  background: #f9f9f9;
  padding: 16px;
  border-radius: 6px;
  transition: background 0.3s ease;
}

.popup-preferencias__opcao:hover {
  background: #f1f1f1;
}

.popup-preferencias__checkbox {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 8px;
}

.popup-preferencias__checkbox input[type="checkbox"] {
  width: 18px;
  height: 18px;
  border: 2px solid #e5e7eb;
  border-radius: 3px;
  appearance: none;
  transition: all 0.3s ease;
}

.popup-preferencias__checkbox input[type="checkbox"]:checked {
  background: #b91c1c;
  border-color: #b91c1c;
}

.popup-preferencias__checkbox input[type="checkbox"]:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.popup-preferencias__checkbox-texto {
  font-weight: 500;
  color: #666666;
}

.popup-preferencias__opcao-descricao {
  font-size: 14px;
  color: #808080;
  margin: 0;
  padding-left: 26px;
}

.popup-preferencias__rodape {
  border-top: 1px solid #e5e7eb;
  padding-top: 24px;
  margin-top: 24px;
}

.popup-preferencias__acoes {
  display: flex;
  justify-content: flex-end;
  gap: 12px;
}

.popup-preferencias__botao {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  padding: 8px 16px;
  border-radius: 6px;
  cursor: pointer;
  text-align: center;
  background: transparent;
  border: 1px solid #e5e7eb;
  color: #666666;
  transition: all 0.3s ease;
  white-space: nowrap;
  text-decoration: none;
  width: auto;
  min-width: 100px;
}

.popup-preferencias__botao:hover {
  background: rgba(185, 28, 28, 0.1);
  border-color: #b91c1c;
  color: #b91c1c;
}

.popup-preferencias__botao:focus-visible {
  outline: 2px solid rgba(185, 28, 28, 0.3);
  outline-offset: 2px;
}

.popup-preferencias__botao--salvar {
  border-color: #b91c1c;
  background: #b91c1c;
  color: #ffffff;
}

/* Mobile Styles */
@media (max-width: 768px) {
  .popup-cookies {
    bottom: 0;
    right: 0;
    left: 0;
    width: 100%;
    max-width: 100%;
    margin: 0;
    padding: 0;
    transform: translateY(100%);
  }

  .popup-cookies--visivel {
    transform: translateY(0);
  }

  .popup-cookies__content {
    border-radius: 0;
    padding: 20px;
    margin: 0;
  }

  .popup-cookies__texto {
    text-align: left;
    margin-bottom: 24px;
  }

  .popup-cookies__acoes {
    display: flex;
    flex-direction: column;
    gap: 10px;
    width: 100%;
    justify-content: center;
  }

  .popup-cookies__botao {
    width: 100%;
    margin: 0;
    justify-content: center;
    border-radius: 4px;
    font-weight: normal;
    padding: 12px;
    min-height: 44px;
  }

  .popup-preferencias {
    padding: 8px;
  }

  .popup-preferencias__content {
    height: auto;
    max-height: calc(100vh - 16px);
    margin: 8px;
    padding: 16px;
  }

  .popup-preferencias__acoes {
    flex-direction: column;
    gap: 10px;
  }

  .popup-preferencias__acoes button {
    width: 100%;
    justify-content: center;
    text-align: center;
    min-height: 44px;
  }
}

/* Base Reset */
html {
  box-sizing: border-box;
}

*,
*::before,
*::after {
  box-sizing: inherit;
}

body {
  margin: 0;
  padding: 0;
  overflow-x: hidden;
  width: 100%;
  min-height: 100vh;
}