@tailwind base;
@tailwind components;
@tailwind utilities;

@font-face {
  font-family: 'Source Sans 3';
  src: url('../public/fonts/SourceSans3-VariableFont_wght.ttf') format('truetype-variations');
}

@import '@fortawesome/fontawesome-free/css/all.min.css';

@layer base {
  html {
    font-family: 'Source Sans 3', sans-serif;
  }

  body {
    @apply bg-white text-black dark:bg-neutral-800 dark:text-white;
  }

  .border,
  .border-r,
  .border-l,
  .border-t,
  .border-b,
  .border-x,
  .border-y {
    @apply dark:border-neutral-700;
  }
}

@layer components {
  .btn {
    @apply px-3 py-1 inline-block items-center justify-center whitespace-nowrap rounded-md transition-colors;
    @apply focus-visible:outline-none focus-visible:ring;
    @apply disabled:pointer-events-none disabled:opacity-50;
  }

  .btn-primary {
    @apply bg-primary text-white hover:bg-primary/90
  }

  .btn-secondary {
    @apply bg-secondary text-white hover:bg-secondary/90
  }

  .btn-dark {
    @apply bg-dark text-white hover:bg-neutral-600;
  }

  .btn-light {
    @apply bg-light text-black hover:bg-neutral-200;
  }

  .btn-success {
    @apply bg-success text-white hover:bg-success/90
  }

  .btn-danger {
    @apply bg-danger text-white hover:bg-danger/90
  }

  .btn-warning {
    @apply bg-warning text-white hover:bg-warning/90
  }

  .form-input {
    @apply px-3 py-1 rounded-md border bg-white transition-colors;
    @apply dark:bg-neutral-100 dark:text-black;
    @apply focus-visible:outline-none focus-visible:ring;
    @apply disabled:cursor-not-allowed disabled:opacity-50;
    @apply read-only:cursor-not-allowed read-only:opacity-50;
  }

  .form-select {
    @apply px-3 py-1 rounded-md bg-transparent transition-colors;
    @apply focus-visible:outline-none focus-visible:ring;
    @apply disabled:pointer-events-none disabled:opacity-50;
    @apply bg-no-repeat appearance-none pr-8 pl-2;
    background-image: url("data:image/svg+xml,%3csvg xmlns=%27http://www.w3.org/2000/svg%27 viewBox=%270 0 16 16%27%3e%3cpath fill=%27none%27 stroke=%27currentColor%27 stroke-linecap=%27round%27 stroke-linejoin=%27round%27 stroke-width=%272%27 d=%27m2 5 6 6 6-6%27/%3e%3c/svg%3e");
    background-size: 0.7rem;
    background-position: right 0.7rem center;
  }

  .badge {
    @apply px-2 py-1 rounded-lg text-xs font-bold leading-none;
  }

  .alert {
    @apply border px-6 py-4 rounded-2xl;
  }

  .alert-danger {
    @apply bg-red-100 text-red-950 border-red-400;
    @apply dark:bg-red-800 dark:text-red-50 dark:border-red-800
  }

  .table-bordered {
    > :not(caption)>* {
      @apply border-y;

      >* {
        @apply border-x;
      }
    }
  }

  .spinner-border {
    width: 30px;
    height: 30px;
    border-width: 4px;
    border-style: solid;
    border-radius: 50%;
    display: inline-block;
    box-sizing: border-box;
    @apply animate-spin;
    @apply border-black border-b-transparent;
    @apply dark:border-white dark:border-b-transparent;
  }

  .markdown-container {
    ul {
      @apply list-disc ms-8;
    }

    h1 {
      @apply text-4xl font-semibold mt-3 mb-2;
    }

    h2 {
      @apply text-3xl font-semibold mt-3 mb-2;
    }

    h3 {
      @apply text-2xl font-medium mt-3 mb-2;
    }

    code {
      @apply text-orange-700;
    }
  }
}

@layer utilities {

  .animate-striped-bg {
    background-size: 2rem 2rem;
    animation: stripes-move 1.5s linear infinite;
    background-image: linear-gradient(-45deg, rgba(255, 255, 255, .2) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, .2) 50%, rgba(255, 255, 255, .2) 75%, transparent 75%, transparent);
  }

  @keyframes stripes-move {
    0% {
      background-position: 0 0;
    }

    100% {
      background-position: 2rem 2rem;
    }
  }


}

/* Global Styles */
/* :root {
  --primary-color: #dc3545;
  --dark-color: #333333;
  --light-color: #f4f4f4;
  --danger-color: #dc3545;
  --success-color: #28a745;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
} */

/* GENERAL CUSTOM STYLES */

.btn-outline-primary:hover {
  color: #FFFFFF;
}

.select-white-caret {
  --bs-form-select-bg-img: url("data:image/svg+xml,%3csvg xmlns=%27http://www.w3.org/2000/svg%27 viewBox=%270 0 16 16%27%3e%3cpath fill=%27none%27 stroke=%27%23ffffff%27 stroke-linecap=%27round%27 stroke-linejoin=%27round%27 stroke-width=%272%27 d=%27m2 5 6 6 6-6%27/%3e%3c/svg%3e");
}

.header-information-space {
  padding: 2.4rem 0;
}

.header-information-space-sm {
  padding: 1.8rem 0;
}

.list-table tbody tr:hover {
  background-color: #f4f4f4;
  -webkit-transition: 0.4s;
  -o-transition: 0.4s;
  transition: 0.4s;
}

.sticky-wrapper {
  position: relative;
}

.sticky-header {
  position: sticky;
  top: 0;
  z-index: 2;
}

.error-message {
  color: #ff4136;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.menu-btn {
  letter-spacing: 1.5px;
  font-size: 0.8rem !important;
}

.menu-btn-md {
  letter-spacing: 1.2px;
  font-size: 0.8rem !important;
}

.menu-input-append {
  font-size: 0.9rem !important;
}

.important-info {
  font-size: 0.95rem;
  font-weight: 500;
  letter-spacing: 1px;
}

.badge-font {
  font-size: 0.9rem;
  letter-spacing: 1px;
}

/* LOG TAB */

.file-info {
  font-size: 1.05rem;
  letter-spacing: 1.5px;
}

/* PERFORMANCE TAB */

.performance-table-header {
  font-size: 1.05rem;
  letter-spacing: 2px;
  text-transform: uppercase;
}

.performance-main-info {
  font-size: 1.2rem;
  letter-spacing: 2px;
  text-transform: uppercase;
  font-weight: 500;
}

/* CONFIGURATION TAB */

.configuration-nav-pill {
  font-size: 1.2rem;
  letter-spacing: 2px;
}

.configuration-source-info {
  font-size: 1.05rem;
  letter-spacing: 2px;
  text-transform: uppercase;
  font-weight: 700;
}

.configuration-section {
  padding: 0 1.2rem 2.4rem 1.2rem;
}

.configuration-section-title {
  font-size: 1.4rem;
  letter-spacing: 1.5px;
  font-weight: 600;
}

/* 
.bg-transition-div {
  background-color: rgb(110, 107, 107);
}


.bg-transition-div * {
  
} */

.minimum-w-filter {
  min-width: 230px;
}

.p-01 {
  padding: 2px;
}

.card-hover:hover {
  border-color: rgb(45, 99, 180);
  -webkit-transition: all 0.35s ease-in-out;
  -o-transition: all 0.35s ease-in-out;
  transition: all 0.35s ease-in-out;
}

.card-hover .btn {
  -webkit-transform: scale(0);
  -ms-transform: scale(0);
  transform: scale(0);
  -webkit-transition: -webkit-transform 300ms 0ms cubic-bezier(0.6, -0.28, 0.735, 0.045);
  transition: -webkit-transform 300ms 0ms cubic-bezier(0.6, -0.28, 0.735, 0.045);
  -o-transition: transform 300ms 0ms cubic-bezier(0.6, -0.28, 0.735, 0.045);
  transition: transform 300ms 0ms cubic-bezier(0.6, -0.28, 0.735, 0.045);
  transition: transform 300ms 0ms cubic-bezier(0.6, -0.28, 0.735, 0.045),
    -webkit-transform 300ms 0ms cubic-bezier(0.6, -0.28, 0.735, 0.045);
}

.card-hover:hover .btn {
  -webkit-transform: scale(1);
  -ms-transform: scale(1);
  transform: scale(1);
  -webkit-transition: -webkit-transform 300ms 300ms cubic-bezier(0.175, 0.885, 0.32, 1.275);
  transition: -webkit-transform 300ms 300ms cubic-bezier(0.175, 0.885, 0.32, 1.275);
  -o-transition: transform 300ms 300ms cubic-bezier(0.175, 0.885, 0.32, 1.275);
  transition: transform 300ms 300ms cubic-bezier(0.175, 0.885, 0.32, 1.275);
  transition: transform 300ms 300ms cubic-bezier(0.175, 0.885, 0.32, 1.275),
    -webkit-transform 300ms 300ms cubic-bezier(0.175, 0.885, 0.32, 1.275);
  z-index: -1;
}

.runIdtd span {
  display: inline-block;
  -webkit-transform: scale(0);
  -ms-transform: scale(0);
  transform: scale(0);
}

.runIdtd:hover span {
  -webkit-transform: scale(1);
  -ms-transform: scale(1);
  transform: scale(1);
}

/* .row-in-card {
  position: absolute;
  top: 70px;
  left: 50px;
  right: 50px; 
  transform: scale(0);
} */

/* .row-in-card .btn {
  transform: scale(0);
} */

.table th {
  padding: 0.7px 4px 0.7px 4px;
}

.table td {
  padding: 0.7px 2px 0.7px 2px;
  font-size: 1rem;
}

.table-fixed {
  table-layout: fixed;
}

.box {
  width: 400px;
  margin: 0 auto;
  overflow: auto;
  border: 1px solid #0f0;
  padding: 2px;
  text-align: justify;
  background: transparent;
}

.fancytree-ext-childcounter span.fancytree-childcounter {
  border: 0px !important;
}

/* BASH STYLE */
pre.bash {
  background-color: black;
  color: white;
  font-size: 1.2rem;
  font-family: "Lucida Console", Courier, monospace;
  width: 100%;
  display: inline-block;
  text-align: left;
  /* letter-spacing: 0.9px; */
  line-height: 1 !important;
  /* padding: 5px; */
}

pre.bash-joblog {
  font-size: 0.9rem;
}

.bash-joblog li {
  padding: 0.1rem 0;
}

.page-footer {
  padding: 2.5rem 9;
  color: #999;
  text-align: center;
  background-color: #f9f9f9;
  border-top: 0.05rem solid #e5e5e5;
}

.container {
  max-width: 100%;
}

.monitorArea {
  height: 100%;
  min-height: 50%;
  width: 100%;
  font-size: 10px;
}

.modal-dialog-historic {
  max-width: 90%;
  margin: 0 auto;
}

.modal-dialog-log {
  max-width: 90%;
  margin: 0 auto;
}

.modal-dialog-summary {
  max-width: 90%;
  margin: 0 auto;
}

.modal-dialog-status {
  max-width: 600px !important;
}

.modal-dialog-list {
  max-width: 650px !important;
}

/* .wrapper-card {
  height: ;
  min-height: 100%;
} */

.footer {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  height: 22px;
}

.scroll {
  max-height: 75vh;
  overflow-y: auto;
}

.scroll-ready-tree {
  max-height: 308px;
  height: 308px;
  overflow-y: auto;
}

.scroll-ready-graph {
  max-height: 317px;
  height: 317px;
  overflow-y: auto;
}

.scroll-y {
  overflow-y: auto;
  height: 275px;
  font-size: 0.7rem;
  font-family: Arial, Helvetica, sans-serif;
}

.scroll-y-jobs {
  overflow-y: auto;
  min-height: 100px;
  max-height: 500px;
  /* font-size: 0.9rem;
  font-family: Arial, Helvetica, sans-serif; */
}

.scroll-y-tree {
  overflow-y: auto;
  height: 281px;
  font-size: 0.7rem;
  font-family: Arial, Helvetica, sans-serif;
}

.scroll-x {
  overflow-x: auto;
}

.scroll-x-table {
  overflow-x: scroll;
  /* height: 323px; */
  width: 100%;
  /* font-size: 0.7rem;
  font-family: Arial, Helvetica, sans-serif; */
}

/* D3 CSS adjustments */

.tick line {
  stroke: #ccc;
  stroke-dasharray: 10, 5;
}

.tooltip-d3 {
  opacity: 0;
  position: absolute;
  pointer-events: none;
  background-color: lightblue;
  border: 1px solid blue;
  border-radius: 1px;
  padding: 5px;
}

.tooltip-d3 p {
  margin: 0;
}

/* .tooltip-d3:before {
  content: "";
  position: absolute;
  border: 12px solid transparent;
  border-bottom-color: blue;
  top: -30px;
  left: 50%;
  margin-left: -6px;
} */

/* End of D3 CSS */

.allowResizeVertical {
  resize: vertical;
}

ul.fancytree-container {
  border: none;
  background-color: transparent;
  @apply bg-transparent;
}

/* span.fancytree-node.fancytree-clone span.fancytree-title {
  color: blue;
} */
span.fancytree-node.fancytree-clone span.fancytree-title:after {
  content: "";
  background: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAoAAAAKCAMAAAC67D+PAAAAFVBMVEVmmcwzmcyZzP8AZswAZv////////9E6giVAAAAB3RSTlP///////8AGksDRgAAADhJREFUGFcly0ESAEAEA0Ei6/9P3sEcVB8kmrwFyni0bOeyyDpy9JTLEaOhQq7Ongf5FeMhHS/4AVnsAZubxDVmAAAAAElFTkSuQmCC") 100% 50% no-repeat;
  padding-right: 13px;
}

span.fancytree-node.fancytree-active-clone {
  /* border-color: blue; */
  animation: flash 2s ease-out;
  animation-iteration-count: 1;
}

@keyframes flash {
  0% {
    background-color: none;
  }

  50% {
    background-color: #fbf8b2;
  }

  100% {
    background-color: none;
  }
}