/* RESET CSS BÁSICO */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  --backgroundester: #043776;
  --textheadercolor: white;
  --textcolor: #404040;
  --texthover: #bbb8b8;
  --borderColor: #8d8d8d59;
}

.separator{
 text-align: center;
 margin: 20px 0;
 width: 100%;
 background-color: #c5c5c53d;
  border-radius: 5px;
}

.info-label {
    margin-left: 10px;
    font-size: 0.9em;
    font-weight: bold;
}

.text-danger {
    color: red;
}

.separator h4{
  padding: 10px;
}

.success-message.success,
.success-message.error {
  justify-content: space-between;

  position: fixed;
  top: 80px;
  right: 0;
  background: var(--bg-color, #5BB85D);
  color: #ebebeb;
  padding: 10px 20px;
  border-radius: 5px 0 0 0;
  border: 1px solid #376E37;
  overflow: hidden;
  z-index: 9999;
  animation: fadeOut 1.7s forwards 1.5s;
}

.success-message.error {
  background: var(--bg-color, #e06a74);
  border: 1px solid #DC3645;
}

.success-message.success::after,
.success-message.error::after {
  content: "";
  position: absolute;
  width: 100%;
  height: 5px;
  right: 0;
  bottom: 0;
  background: var(--backgroundester);
  animation: shrinkBar 1.5s linear forwards;
  border-radius: 0 0 0 5px;
}

.success-message.error::after {
  background: red;
}

.sucess {
  position: fixed;
  color: #2ca02c;
  background-color: #9ce99c;
  font-weight: bold;
}

.form_row {
  display: flex;
  flex-direction: column;
  margin-bottom: 10px;
  width: 100%;
}

.form_row label span {
  color: red;
}

.form_row label {
  width: 100%;
  /* Largura fixa para alinhamento */
  font-weight: bold;
}

.form_row input,
.form_row select,
.form_row textarea {
  flex: 1;
  /* Faz o input ocupar o restante do espaço */
  padding: 14px 6px;
  border: 1px solid #d3d3d3;
  border-radius: 4px;
  width: 100%;
}

.form_check label {
  font-weight: bold;
  margin: 10px;
  justify-content: left;
}

.form_check input:focus,
.form_check select:focus,
.form_check textarea:focus {
  border: 2px solid #86d2f5;
}

.form_check {
  padding: 20px;
  margin: 10px auto;
  border-radius: 10px;
  width: 60%;
  box-shadow: 0 0 10px #8f8e8e52;
}

.form_submit {
  display: flex;
  justify-items: center;
  align-items: center;
  justify-content: center;
  width: 100%;
}

.form_submit>#submit {
  background-color: var(--backgroundester);
  border-radius: 5px;
  padding: 10px 0;
  margin-top: 20px;
  width: 30%;
  text-align: center;
  font-weight: bold;
  color: white;
}

.form_submit>#submit:hover {
  background-color: #014ca8;
}

.table_rool {
  max-height: 500px !important;
  overflow-y: auto !important;
  overflow-x: hidden !important;
  table-layout: fixed;
  width: 100%;
}



.formFilter {
  display: flex;
  width: 100%;
  align-items: center;
}

.itensForm {
  display: flex;
  align-items: center;
}

.itensForm label {
  width: 100%;
}

.itensForm label:nth-child(1) {
  margin-right: 10px;
  margin-left: 10px;
}

.btn {
  margin-left: 20px;
}

.btn_login {
  transition: .2s;
  width: 100%;
  border: none;
  outline: none;
  cursor: pointer;
  background-color: var(--backgroundester);
  color: white;
  border-radius: 10px;
  padding: 5px 0px;
  margin-top: 10px;
}

.btn_login:hover {

  background-color: #014ca8;
}

/* Remove decorações padrão de listas e links */
ul,
ol {
  list-style: none;
}

a {
  text-decoration: none;
}

/* Herança de fonte e tamanho base */
body {
  font-family: "Trebuchet MS", sans-serif;
  font-size: 16px;
  line-height: 1.6;
  background-color: var(--textheadercolor);
  color: var(--textcolor);
}

/* Elementos de formulário */
input,
button,
textarea,
select {
  font-family: inherit;
  font-size: 1rem;
  border: none;
  outline: none;
  background: none;
}

/* Botões e formulários básicos */
button {
  cursor: pointer;
}

header,
footer {
  padding: 5px 40px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  text-align: center;
  background-color: var(--backgroundester);
  color: var(--textheadercolor);
  font-size: 18px;
  font-weight: bold;
  left: 0;
  position: fixed;
  width: 100%;
  height: 60px;
  z-index: 10;
}


footer {
  height: 40px;
}

header {
  top: 0;
}

nav a {
  margin-left: 10px;
  color: var(--textheadercolor);
  text-decoration: none;
  transition: .3s;
}

nav a:hover {
  color: var(--texthover);
}

.logo {
  height: 100%;
  display: flex;
  align-items: center;
}

footer {
  bottom: 0;
  justify-content: center;
}

section {
  min-height: 100vh;
  background-color: white;
  padding: 80px 30px;
}

#btn-menu {
  background-color: transparent;
  display: none;
  border-radius: 5px;
  border: none;
  width: 40px;
  height: 30px;
  cursor: pointer;
}

.linha {
  width: 25px;
  height: 2px;
  background: white;
  display: block;
  margin: 4px auto;
  position: relative;
  transform-origin: center;
  transition: .3s;
}

button.ativar .linha:nth-child(1) {
  transform: translateY(6px) rotate(-55deg);
}

button.ativar .linha:nth-child(2) {
  width: 0;
}

button.ativar .linha:nth-child(3) {
  transform: translateY(-6px) rotate(55deg);
}

.fade-in-up {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.fade-in-up.show {
  opacity: 1;
  transform: translateY(0);
}

.title {
  margin-bottom: 40px;
}

.card-hover:hover {
  background-color: #f8f9fa;
  transform: scale(1.02);
  transition: 0.3s;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

/*Parte Login*/
.conteudoLogin {
  border: 1px solid var(--borderColor);
  padding: 20px;
  margin: 0 auto;
  border-radius: 10px;
  width: 600px;
}

.conteudoFiltro {
  padding: 20px;
  margin: 20px auto;
  border-radius: 10px;
  width: 100%;
  box-shadow: 0 0 10px #8f8e8e52;
}

tr {
  text-align: center;
}

th:first-child,
td:first-child {
  background-color: #f0f0f0;
  /* Um cinza claro para o fundo */
  font-weight: bold;
  /* Deixa o texto em negrito */
  color: #333;
  /* Cor do texto mais escura */
  text-align: left;
  /* Alinha o texto à esquerda */
  padding-left: 15px;
  /* Um pouco mais de padding para o alinhamento */
}

.passowordView {
  position: relative;
  display: flex;
  align-items: center;
  width: 100%;
  overflow: hidden;
}

.passowordView input {
  padding-right: 20px;
}

.passowordView i {
  display: none;
  position: absolute;
  right: 0;
  bottom: 0;
  height: 100%;
  padding: 0 10px;
  justify-content: center;
  align-items: center;
  cursor: pointer;
  border: 1px solid #dadada;
  border-radius: 0 5px 5px 0;
  transition: .2s;
}

.passowordView i:hover {
  color: #363636;
}

.passowordView i.ativo {
  display: flex;
}

/*Geotecnologia*/
#UploadJson {
  width: 600px;
  padding: 24px;
  margin: auto;
  background: #fff;
  border: 2px solid var(--borderColor);
  border-radius: 10px;
  color: var(--textcolor);
}

.form-group {
  display: flex;
  flex-direction: column;
  margin-bottom: 10px;
}

#UploadJson input[type="text"],
#UploadJson input[type="file"] {
  background-color: #222;
  color: #fff;
  border: 1px solid var(--borderColor);
  border-radius: 6px;
  padding: 10px;
  width: 100%;
  margin-bottom: 12px;
}

.upload-box {
  width: 140px;
  height: 140px;
  border: 2px dashed var(--borderColor);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  margin-bottom: 10px;
  border-radius: 10px;
  transition: background-color 0.3s;
}

.upload-box.json:hover {
  background-color: #c300ff23;
}

.plus-sign {
  font-size: 48px;
  color: var(--textcolor);
  user-select: none;
}

.upload-box.json {
  color: transparent;
  background-image: url('../img/icones/json.png');
  background-size: 60%;
  background-repeat: no-repeat;
  background-position: center;
}

.file-name {
  margin-top: 6px;
  color: var(--textcolor);
  font-size: 0.9rem;
}

.enviarFile {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
}

input[type="file"] {
  display: none;
}

/* Estilizando o botão */
#UploadJson button[type="submit"] {
  background-color: var(--backgroundester);
  color: #fff;
  padding: 10px 20px;
  border: none;
  border-radius: 8px;
  font-weight: bold;
  cursor: pointer;
  transition: 0.3s;
  margin-top: 12px;
}

#UploadJson button[type="submit"]:hover {
  background-color: #014ca8;
}

/* Estilo do spinner de carregamento dentro do botão */
.spinner {
  border: 4px solid #f3f3f3;
  border-top: 4px solid var(--backgroundester);
  border-radius: 50%;
  width: 24px;
  height: 24px;
  position: absolute;
  transform: translate(-50%, -50%);
  animation: spin 1s linear infinite;
  display: inline-block;
}

/* Melhorando a aparência de foco */
#UploadJson input:focus {
  outline: none;
  box-shadow: 0 0 5px var(--borderColor);
}

#UploadJson button[type="submit"] {
  position: relative;
  width: 100%;
  height: 40px;
  display: flex;
  justify-content: center;
  align-items: center;
  font-size: 15px;
  font-weight: bolder;
  overflow: hidden;
}

.info {
  width: 600px;
  margin: 0 auto;
  border: 1px solid var(--borderColor);
  border-radius: 10px;
  margin-top: 10px;
  padding: 10px;
  display: flex;
  align-items: center;
  font-size: 13px;
  color: black;
  background: #ffffff17;
}

.if {
  height: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 4px 10px;
  font-size: 23px;
  border: 1px solid var(--borderColor);
  border-radius: 50%;
}

.description {
  padding: 0 10px;
}

#downloadBtn {
  position: fixed;
  bottom: 70px;
  right: 20px;
  width: 50px;
  height: 50px;
  overflow: hidden;
  background: transparent;
  border: none;
  outline: none;
  cursor: pointer;
  transition: .2s;
  z-index: 1000;
}

#dashboardContent {
  padding: 10px;
}

#downloadBtn img {
  width: 100%;
  height: 100%;
}

#downloadBtn:hover {
  transform: scale(1.1);
}

.block_title {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  border-radius: 0 0 10px 10px;
  background: #ffffff83;
}

.block_title h3 img {
  width: 80px;
  height: 50px;
  margin-bottom: -5px;
}

.block_title h3 {
  font-size: 30px;
}

.block_title small {
  font-size: 19px;
}

#data-atualizacao {
  margin-top: -40px;
}

.cards-container {
  display: flex;
  flex-wrap: wrap;
  gap: 1.5rem;
  margin-top: 2rem;
  margin-bottom: 2rem;
  padding: 0 20px;
}

.card-metric {
  flex: 1 1 200px;
  background-color: #ffffff;
  padding: 1.5rem;
  border-radius: 10px;
  border: 1px solid #969696;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
  text-align: center;
  transition: transform 0.2s ease-in-out;
}

.card-metric:hover {
  transform: translateY(-3px);
}

.card-metric h5 {
  font-size: 1rem;
  color: #192f61;
  margin-bottom: 0.75rem;
  font-weight: bold;
}

.metric-value {
  font-size: 1.8rem;
  font-weight: bold;
}

.metric-value.green {
  color: #2ca02c;
}

.metric-value.red {
  color: #d62728;
}

.charts-container {
  display: flex;
  flex-wrap: wrap;
  gap: 2rem;
  margin: 1rem 0 0 0;
  justify-content: space-between;
  padding: 0 20px;
}

.chart-box {
  flex: 1 1 45%;
  background-color: #fff;
  border: 1px solid #ddd;
  border-radius: 10px;
  padding: 1rem;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
  text-align: center;
  transition: transform 0.2s ease-in-out;
  margin-bottom: -10px;
}

.chart-box:hover {
  transform: translateY(-3px);
}

.chart-box h4 {
  color: #192f61;
  font-weight: bold;
  margin-bottom: 1rem;
}

.chart-img {
  max-width: 100%;
  height: auto;
  border-radius: 6px;
}

.arquivo {
  display: block;
  z-index: 10;
}

.UsinaEsterlogo {
  position: absolute;
  right: 0;
  width: 100px;
}

.shps {
  width: 100%;
  display: flex;
  justify-content: space-around;
  margin: 5px 0;
}

/*Parte Responsiva*/


@media (max-width: 1300px) {
  .conteudoDashboard {
    padding: 15px;
    flex-direction: column;
  }

  .graph-container {
    margin: 0;
    margin-bottom: 10px;
    padding: 0;
  }

  table {
    margin: 0;
    margin-bottom: 10px;
  }
}

@media (max-width: 900px) {
  table {
    font-size: 10px;
  }

  .titleDash,
  .titleDash i {
    font-size: 18px;
  }

  .form_check {
    font-size: 13px;
  }

  .subtitleDash {
    font-size: 17px;
  }

}

@media (max-width: 600px) {
  #btn-menu {
    display: block;
    z-index: 999;
  }

  nav {
    position: fixed;
    right: 0;
    top: 60px;
    height: 100vh;
    background: var(--backgroundester);
    z-index: 1;
    display: none;
    flex-direction: column;
    padding-top: 60px;
    width: 50%;
  }

  .form_check {
    display: flex;
    flex-direction: column;
    justify-content: center;
    width: 100%;
    font-size: 14px;
  }

  /* Quando o menu for ativado (entrada) */
  nav.ativo {
    display: flex;
    animation: slideInRight 0.4s forwards;
  }

  /* Classe auxiliar para animação de saída */
  nav.saindo {
    animation: slideOutRight 0.3s forwards;
  }

  .conteudoLogin {
    width: 100%;
  }

  .title {
    font-size: 25px;
  }
}

@media (max-width: 500px) {
  nav {
    width: 100%;
  }

  .form_submit>#submit {
    width: 100%;
  }

  .formFilter {
    display: flex;
    flex-direction: column;
    justify-content: center;
    width: 100%;
  }

  .formFilter div {
    font-size: 13px;
    width: 100%;
    margin-bottom: 10px;
  }

  .btn {
    width: 100%;
    margin-top: 20px;
  }

}



/*Parte Animações*/
@keyframes aparecer {
  0% {
    transform: translateX(1000px);
  }
}

@keyframes slideInRight {
  from {
    transform: translateX(100%);
    opacity: 0;
  }

  to {
    transform: translateX(0);
    opacity: 1;
  }
}

/* Animação de saída */
@keyframes slideOutRight {
  from {
    transform: translateX(0);
    opacity: 1;
  }

  to {
    transform: translateX(100%);
    opacity: 0;
  }
}

@keyframes shrinkBar {
  from {
    width: 100%;
  }

  to {
    width: 0%;
  }
}

@keyframes fadeOut {
  to {
    opacity: 0;
    transform: translateX(100%);
    visibility: hidden;
  }
}

@keyframes spin {
  0% {
    transform: rotate(0deg);
  }

  100% {
    transform: rotate(360deg);
  }
}