@import url("https://fonts.googleapis.com/css2?family=Archivo:ital,wght@0,100..900;1,100..900&family=Chivo:ital,wght@0,100..900;1,100..900&family=Montserrat:ital,wght@0,100..900;1,100..900&family=Poppins:ital,wght@0,100;0,200;0,300;0,400;0,500;0,600;0,700;0,800;0,900;1,100;1,200;1,300;1,400;1,500;1,600;1,700;1,800;1,900&family=Racing+Sans+One&display=swap");
:root {
  --1-color: #003a40;
  --2-color: #004851;
  --3-color: #00bb7e;
  --4-color: #a7da20;
  --5-color: #f0e9d7;
  --button-bg-color: #00bb7e;
}
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}
body {
  font-family: "Archivo", serif;
  background-color: #003a40;
  display: flex;
  flex-direction: column;
  align-items: center;
  min-height: 100vh;
}
.popup-message {
  display: none;
  position: fixed;
  top: 20px;
  left: 50%;
  transform: translateX(-50%);
  padding: 15px;
  background-color: #4caf50; /* Verde para sucesso */
  color: white;
  border-radius: 5px;
  z-index: 1000;
  font-size: 16px;
}
/* Estilo de erro */
.popup-message.error {
  background-color: #f44336; /* Vermelho para erro */
}
.navbar {
  width: 100%;
  background-color: var(--2-color);
  display: flex;
  align-items: center;
  padding: 10px 20px;
  justify-content: space-between;
}

.navbar-logo img {
  height: 35px;
  margin-left: 20px;
}
.navbar-buttons button {
  background-color: var(--button-bg-color);
  color: var(--5-color);
  border: none;
  padding: 9px 10px;
  margin-left: 10px;
  border-radius: 5px;
  cursor: pointer;
  font-weight: bold;
  font-size: 14px;
}
.navbar-buttons button:hover {
  background-color: #00a76a;
}
#cadastro,
#visualizar {
  text-align: center;
  padding: 8px 1px;
  border-radius: 5px;
  border: none;
  font-size: 14px;
  font-weight: bold;
  outline: none;
  background-color: #00bb7e;
  color: #f0e9d7;
  font-family: "Archivo", serif;
  transition: background-color 0.3s ease, box-shadow 0.3s ease;
  margin-left: 10px;
}
.hamburger-menu {
  display: none;
  flex-direction: column;
  cursor: pointer;
  gap: 5px;
}
.hamburger-menu span {
  display: block;
  width: 25px;
  height: 3px;
  background-color: var(--5-color);
}
.menu-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.9);
  display: none;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  opacity: 0;
  transition: opacity 0.3s ease;
}
.menu-overlay.active {
  display: flex;
  opacity: 1;
}
.close-btn {
  position: absolute;
  top: 20px;
  right: 20px;
  font-size: 24px;
  color: var(--5-color);
  background: none;
  border: none;
  cursor: pointer;
}
.menu-items {
  list-style: none;
  text-align: center;
  padding: 0;
}
.menu-items li {
  margin: 20px 0;
}
.menu-items li a {
  color: var(--5-color);
  font-size: 24px;
  text-decoration: none;
}
.logo-title {
  display: flex;
  align-items: center;
  gap: 15px;
  margin-bottom: 20px;
}
.logo-title img {
  width: 100px;
  height: auto;
}
.title-text h2 {
  margin: 0;
  color: var(--4-color);
  font-size: 1.2rem;
  font-family: "Chivo", serif;
}
.title-text p {
  margin: 0;
  color: #f0e9d7;
  font-size: 0.9rem;
  font-family: "Poppins", sans-serif;
}
.container {
  background: var(--2-color);
  border-radius: 10px;
  width: 25%;
  padding: 20px;
  margin-top: 60px;
  margin-bottom: 70px;
}
#container-busca {
  width: 35%;
}
#box-input form {
  display: flex;
  flex-direction: column;
  gap: 5px;
}
#box-input form label {
  font-weight: bold;
  color: #fff;
  font-size: 19px;
}
#box-input form input,
#box-input form select,
#box-input form button {
  padding: 5px;
  border-radius: 5px;
  border: none;
}
#editAgenciador {
  width: 100%;
  margin-top: 5px;
  padding: 5px;
  border-radius: 5px;
  border: none;
}
#box-input form button {
  margin-top: 20px;
  background-color: var(--button-bg-color);
  color: var(--5-color);
  font-size: 16px;
  font-weight: bold;
  cursor: pointer;
  border: none;
  transition: background 0.3s;
}
#box-input form button:hover {
  background-color: var(--4-color);
}
.filters {
  display: flex;
  gap: 10px;
  margin-bottom: 20px;
  justify-content: center;
  font-family: "Archivo", serif;
}
.filters input[type="text"],
.filters select {
  padding: 5px 10px;
  border-radius: 5px;
  border: none;
  font-size: 16px;
  outline: none;
  background-color: #f0e9d7;
  color: #003a40;
  font-family: "Archivo", serif;
  box-shadow: 0px 4px 6px rgba(0, 0, 0, 0.1);
  transition: background-color 0.3s ease, box-shadow 0.3s ease;
}
.filters input[type="text"]::placeholder {
  color: #607d8b;
}
.filters input[type="text"]:focus,
.filters select:focus {
  background-color: #e8e0c9;
  box-shadow: 0px 6px 8px rgba(0, 0, 0, 0.2);
}
.filters select {
  appearance: none;
  background-image: url("data:image/svg+xml;charset=UTF-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 16 16'%3E%3Cpath fill='%23003a40' d='M12 6l-4 4-4-4z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 10px center;
  background-size: 12px;
  padding-right: 30px;
}
#ordensContainer,
#agenciadoresContainer {
  display: flex;
  flex-direction: column;
  gap: 15px;
}

.ordem-item {
  padding: 15px;
  border-radius: 5px;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.5);
  gap: 5px;
}
#ordensContainer h2,
#agenciadoresContainer h2 {
  color: var(--3-color);
  font-size: 26px;
  margin: 10px 0;
}
#ordensContainer p,
#agenciadoresContainer p {
  color: var(--5-color);
}
#ordensContainer strong,
#agenciadoresContainer strong {
  color: var(--4-color);
  font-size: 19px;
}
#ordensContainer button,
#agenciadoresContainer button {
  color: var(--5-color);
  background: var(--3-color);
  font-size: 16px;
  font-weight: bold;
  padding: 10px;
  border-radius: 5px;
  margin: 10px 0;
  border: none;
}
#editModal,
#modalOverlay {
  display: none;
}
#modalOverlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.5);
  z-index: 999;
  display: none;
}
.submenu {
  list-style: none;
  padding-left: 20px;
  display: none; /* Inicialmente oculto */
}

.menu-parent {
  cursor: pointer;
}

.menu-parent span {
  font-weight: bold;
  color: var(--5-color); /* Cor do texto principal */
}

.menu-parent:hover span {
  color: var(--3-color); /* Cor ao passar o mouse */
}

.submenu li a {
  text-decoration: none;
  color: var(--5-color);
}

.submenu li a:hover {
  color: var(--3-color);
}
#editModal {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  background-color: var(--2-color);
  padding: 20px;
  border-radius: 10px;
  box-shadow: 0px 4px 12px rgba(0, 0, 0, 0.2);
  width: 80%;
  max-width: 500px;
  max-height: 95vh; /* Limita a altura máxima a 80% da altura da janela */
  overflow-y: auto; /* Permite rolagem vertical */
  z-index: 1000;
  color: var(--5-color);
}

#editModal h2 {
  color: var(--4-color);
  font-weight: bold;
  text-align: center;
  margin-bottom: 15px;
}
#editModal label {
  font-weight: bold;
  margin-top: 10px;
  display: block;
  color: var(--5-color);
}
#editModal input[type="text"],
#editModal input[type="date"] {
  width: 100%;
  padding: 8px;
  margin-top: 5px;
  border-radius: 5px;
  border: 1px solid var(--1-color);
  outline: none;
  box-sizing: border-box;
}
#editModal button {
  font-size: 16px;
  padding: 8px 16px;
  margin-top: 15px;
  border: none;
  border-radius: 5px;
  cursor: pointer;
  font-weight: bold;
  width: 100px;
  gap: 5px;
}
#editModal button[type="button"] {
  background-color: var(--button-bg-color);
  color: var(--5-color);
}
#editModal button[type="button"]:hover {
  background-color: var(--4-color);
}
#editModal .cancel-btn {
  background-color: #f44336;
  color: #fff;
}
#editModal .cancel-btn:hover {
  background-color: #d32f2f;
}
#informacoes,
#informacoes_pessoais,
#editInformacoesPessoais,
#editInformacoes {
  width: 100%;
  height: 80px;
  padding: 8px;
  border-radius: 5px;
  overflow-y: auto;
  white-space: pre-wrap;
  box-sizing: border-box;
  resize: vertical;
}
#ajuda {
  width: 50%;
  margin-bottom: 50px;
}
#ajuda h1 {
  margin: 10px 0 0 0;
  color: var(--4-color);
  font-size: 1.6rem;
}
#ajuda p {
  margin: 0;
  color: #f0e9d7;
  font-size: 1rem;
  line-height: 25px;
}
footer {
  background-color: #004851;
  padding: 20px 0;
  text-align: center;
  font-size: 14px;
  color: #fefff3;
  width: 100%;
  margin-top: auto;
  position: relative;
}
footer a {
  color: #f0e9d7;
}
footer p {
  margin: 0;
}
footer img {
  width: 100px;

  height: auto;

  margin-bottom: 5px;
}

/* CSS MODAL DE FINALIZACAO PG VISUALIZAR ORDENS */
/* Estilo geral do modal */
#finalizarModal {
  display: none; /* Inicialmente oculto */
  position: fixed;
  top: 50%; /* Centraliza verticalmente */
  left: 50%; /* Centraliza horizontalmente */
  transform: translate(-50%, -50%); /* Ajusta para centralização perfeita */
  background: var(--2-color); /* Fundo do modal */
  border-radius: 8px; /* Cantos arredondados */
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2); /* Sombra */
  padding: 20px; /* Espaçamento interno */
  z-index: 1000; /* Garantir que fique acima de outros elementos */
  width: 90%; /* Largura padrão em dispositivos móveis */
  max-width: 400px; /* Largura máxima em desktops */

  /* Centralização interna */
  display: flex;
  flex-direction: column; /* Organização em coluna */
  justify-content: center; /* Centraliza verticalmente os elementos */
  align-items: center; /* Centraliza horizontalmente os elementos */
  gap: 15px; /* Espaçamento entre os elementos */
}


/* Estilo para o overlay (fundo escuro) */
#modalOverlay {
  display: none; /* Inicialmente oculto */
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.5); /* Fundo semitransparente */
  z-index: 999; /* Abaixo do modal */
}

/* Título do modal */
#finalizarModal h2 {
  color: var(--4-color);
  font-size: 1.5rem;
  font-family: "Chivo", serif;
  margin-bottom: 20px;
  text-align: center;
}

/* Parágrafo do título da ordem */
#finalizarModal p {
  font-size: 1.2rem;
  margin-bottom: 15px;
  color: var(--3-color);
  text-align: center;
  font-weight: 700;
}

#finalizarModal label {
  font-size: 1rem;
  margin-bottom: 15px;
  color: #ffffff; /* Cor do texto */
  text-align: center;
}

/* Inputs no modal */
#finalizarModal input[type="number"] {
  width: calc(100% - 20px); /* Ajusta largura com base no padding */
  padding: 10px;
  margin-bottom: 20px;
  margin-top: 10px;
  border: 1px solid #ccc; /* Borda */
  border-radius: 5px; /* Cantos arredondados */
  font-size: 1rem;
}

/* Botões no modal */
#div-btn-finalizar {
  display: flex;
  justify-content: space-evenly; /* Divide o espaço uniformemente entre os botões */
  width: 100%; /* Faz com que os botões ocupem a largura do contêiner */
  gap: 10px; /* Espaçamento entre os botões */
}

#finalizarModal button {
  display: inline-block;
  padding: 15px;
  margin: 5px;
  font-size: 1rem;
  border: none;
  border-radius: 5px;
  cursor: pointer;
  width: 40%; /* Cada botão ocupa 40% da largura do contêiner */
  max-width: 200px; /* Largura máxima opcional */
  text-align: center;
}

#finalizarModal button:first-of-type {
  background: var(--3-color); /* Azul */
  color: white; /* Cor do texto */
}

#finalizarModal button:last-of-type {
  background: var(--3-color); /* Vermelho */
  color: white; /* Cor do texto */
}

/* Adiciona hover aos botões */
#finalizarModal button:hover {
  opacity: 0.9;
}

@media screen and (max-width: 1630px) {
  .container,
  #container-busca,
  #ajuda {
    width: 80%;
  }
}
@media screen and (max-width: 768px) {
  body {
    font-size: 14px;
    margin: 0;
  }
  .desktop-buttons {
    display: none;
  }
  .hamburger-menu {
    display: flex;
  }
  .container,
  #container-busca,
  #ajuda {
    width: 90%;
    padding: 10px;
  }
  .filters {
    display: flex;
    flex-direction: column;
  }
  .menu-items {
    font-size: 24px; /* Categorias principais maiores */
    font-weight: bold;
  }

  .menu-parent span {
    font-size: 24px; /* Categorias principais maiores */
    font-weight: bold;
  }

  .submenu li a {
    font-size: 24px; /* Categorias principais maiores */
    font-weight: bold;
  }
}
