@import url('./core/variables.css');
@import url('./core/reset.css');
@import url('./core/animations.css');
@import url('./core/layouts.css');
@import url('./components/buttons.css');
@import url('./components/links.css');
@import url('./components/inputs.css');
@import url('./components/dialog.css');

:root {
  --icon-fill: currentColor;
  --icon-fill-accent: var(--clr-brand-500);
  --icon-stroke: currentColor;
}

body {
  font-family: var(--font-sans);
  background-color: var(--clr-background-body);
}

.icon {
  width: 1.5rem;
  height: 1.5rem;
}

svg,
path {
  transition: color 300ms ease-out, fill 300ms ease-out, stroke 300ms ease-out;
}

.bbg::before {
  content: '';
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  left: 0;
  z-index: -1;
  height: 800px;

  background-size: cover;
  background-position-y: 0;
  background-position-x: center;
  background-repeat: no-repeat;

  -webkit-mask-image: -webkit-linear-gradient(
          to bottom,
          rgba(0, 0, 0, 0),
          rgba(0, 0, 0, 1),
          rgba(0, 0, 0, 0)
  );
  mask-image: linear-gradient(
          to bottom,
          rgba(0, 0, 0, 0),
          rgba(0, 0, 0, 1),
          rgba(0, 0, 0, 0)
  );
}

.has-tooltip {
  position: relative;
}

/* .has-tooltip > .tooltip-text {
  visibility: hidden;
  width: 120px;
  background-color: black;
  color: #fff;
  text-align: center;
  border-radius: 6px;
  padding: 5px 0;

  position: absolute;
  z-index: 1;
  top: 100%;
  left: 50%;
}
.has-tooltip:hover > .tooltip-text {
  visibility: visible;
}

*/

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border-width: 0;
}

.no-scroll {
  overflow: hidden;
}

.hidden {
  display: none !important;
}

.loading-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: var(--clr-background-body);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 9999;
  overflow: hidden; /* Adicionado para desativar o scroll sem mexer no body */
}

.loading-bar-container {
  width: 50%; /* Define o tamanho fixo desejado */
  height: 5px;
  background: var(--clr-background-body); /* Ajuste conforme necessário */
  overflow: hidden; /* Garante que a barra de carregamento não ultrapasse os limites */
  position: relative; /* Necessário para o posicionamento da barra de carregamento */
}

.loading-bar {
  height: 100%;
  background: var(--clr-accent-brand);
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  animation: load 1s infinite ease-in-out; /* Ajusta a duração e suaviza a animação */
}

@keyframes load {
  0%, 100% {
    width: 25%;
  }
  50% {
    width: 100%;
  }
}


.text-center {
  text-align: center;
}

.responsive-table {
  width: 100%;
  container-type: inline-size;
  overflow-x: auto;
}

.default-table {
  --_row-radius: var(--radius-2);

  max-width: 100%;
  width: 100%;
  border-collapse: collapse;

  th,
  td {
    padding: var(--spacing-3);
    font-size: 1rem;
    font-weight: 400;
    line-height: 1rem;
    text-align: left;
    border: 1px solid var(--clr-base-600--30);
  }

  th {
    background-color: var(--clr-surface-01);
    color: var(--clr-onSurface-01--subtle);
  }

  td {
    background: var(--clr-surface-02);
    color: var(--clr-onSurface-02);
  }

  tr:first-child > th:first-child {
    border-top-left-radius: var(--_row-radius);
  }

  tr:first-child > th:last-child {
    border-top-right-radius: var(--_row-radius);
  }

  tr:last-child > td:first-child {
    border-bottom-left-radius: var(--_row-radius);
  }

  tr:last-child > td:last-child {
    border-bottom-right-radius: var(--_row-radius);
  }
}
