/* Import modern fonts */
@import url('https://fonts.googleapis.com/css2?family=Noto+Sans:wght@300;400;500;600;700&family=Noto+Serif:wght@400;600&display=swap');

* {
  font-family: 'Noto Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
}

:root {
  --primary-color: #2E86DE;
  --primary-dark: #1E6BB8;
  --primary-light: #54A0FF;
  --primary-gradient: linear-gradient(135deg, #2E86DE 0%, #1E6BB8 100%);
  --primary-gradient-hover: linear-gradient(135deg, #1E6BB8 0%, #0F5490 100%);
  --font-noto: 'Noto Sans', sans-serif;
}

html, body {
  font-family: var(--font-noto);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

.editable tbody tr {
  cursor: pointer;
  transition: all 0.2s ease;
  font-family: var(--font-noto);
}

table {
  width: 100%;
  table-layout: fixed;
  border-collapse: collapse;
  border-spacing: 0;
  margin: 0;
  padding: 0;
  font-size: 14px;
  font-family: var(--font-noto);
}

table th, td {
  word-break: break-word;
  transition: background-color 0.2s ease, color 0.2s ease;
  font-family: var(--font-noto);
}

table th {
  font-size: 15px;
  font-weight: 600;
  letter-spacing: 0.3px;
}

@media screen and (max-width: 900px) {
  .responsible {
    border: 0;
  }

  .responsible caption {
    font-size: 1.3em;
  }

  .responsible td, th:first-child {
    width: auto;
  }

  .responsible td, th:nth-child(2) {
    width: auto;
  }

  .responsible td, th:nth-child(3) {
    width: auto;
  }

  .responsible thead {
    border: none;
    clip: rect(0 0 0 0);
    height: 1px;
    margin: -1px;
    overflow: hidden;
    padding: 0;
    position: absolute;
    width: 1px;
  }

  .responsible tfoot {
    border: none;
    clip: rect(0 0 0 0);
    height: 1px;
    margin: -1px;
    overflow: hidden;
    padding: 0;
    position: absolute;
    width: 1px;
  }

  .responsible tr {
    border-bottom: 3px solid #ddd;
    display: block;
    margin-bottom: .625em;
  }

  .responsible td {
    border-bottom: 1px solid #ddd;
    display: block;
    font-size: .8em;
    text-align: center;
  }

  .responsible td::before {
    content: attr(data-label);
    float: left;
    font-weight: bold;
    text-transform: uppercase;
  }

  .responsible td:last-child {
    border-bottom: 0;
  }
}

.preview_img {
  width: 100%;
  border: 1px solid rgba(179, 179, 179, 0.3);
  border-radius: 12px;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.preview_img:hover {
  transform: scale(1.02);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

div.dom_wrapper {
  position: sticky;
  top: 200;
  padding: 5px;
  z-index: 100;
}

.sidebar-dark-primary .nav-sidebar > .nav-item > .nav-link.active, 
.sidebar-light-primary .nav-sidebar > .nav-item > .nav-link.active {
  background: var(--primary-gradient);
  color: #fff;
  border-radius: 8px;
  transition: all 0.3s ease;
}

table tr {
  cursor: pointer;
  transition: all 0.2s ease;
}

.table-hover tbody tr:hover td {
  background: linear-gradient(135deg, #54A0FF 0%, #3D8EEB 100%);
  color: white;
  transform: translateX(2px);
}

.table>tbody>tr.active>td {
  background: var(--primary-gradient);
  color: #fff;
  box-shadow: 0 2px 8px rgba(46, 134, 222, 0.3);
}

tr.selected {   
  background: var(--primary-gradient);
  color: white;
  box-shadow: 0 2px 8px rgba(46, 134, 222, 0.3);
}

.table tbody tr.highlight td {
  background: var(--primary-gradient);
  color: white;
  box-shadow: 0 2px 8px rgba(46, 134, 222, 0.3);
}

mark {
  padding: 6px 10px;
  border-radius: 6px;
  color: #fff;
  background: linear-gradient(135deg, #0c3250 0%, #0a2940 100%) !important;
  box-shadow: 0 2px 4px rgba(12, 50, 80, 0.2);
}

/* For mobile phones: */
.control-sidebar, .control-sidebar::before {
  right: -250px;
  width: 250px;
  transition: right 0.3s ease;
}

@media only screen and (min-width: 768px) {
  /* For desktop: */
  .control-sidebar, .control-sidebar::before {
    right: -600px;
    width: 600px;
  }
}

.control-sidebar-content {
  overflow-y: scroll;
  scrollbar-width: thin;
  scrollbar-color: #1964a1 #f0f0f0;
}

.control-sidebar-content::-webkit-scrollbar {
  width: 8px;
}

.control-sidebar-content::-webkit-scrollbar-track {
  background: #f0f0f0;
  border-radius: 10px;
}

.control-sidebar-content::-webkit-scrollbar-thumb {
  background: var(--primary-color);
  border-radius: 10px;
}

.card-primary.card-outline-tabs .card-header a.active {
  border-top: 3px solid var(--primary-color);
  transition: all 0.3s ease;
}

.callout.callout-primary {
  border-left-color: var(--primary-color);
  border-left-width: 4px;
  background: rgba(46, 134, 222, 0.05);
  border-radius: 8px;
}

.card-primary.card-outline {
  border-top: 3px solid var(--primary-color);
  border-radius: 10px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
  transition: box-shadow 0.3s ease;
}

.card-primary.card-outline:hover {
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.1);
}

.btn-primary {
  color: #fff;
  background: var(--primary-gradient);
  border: none;
  box-shadow: 0 2px 8px rgba(46, 134, 222, 0.3);
  transition: all 0.3s ease;
  border-radius: 8px;
  font-weight: 500;
  font-family: var(--font-noto);
}

.btn-primary:hover {
  background: var(--primary-gradient-hover);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(46, 134, 222, 0.4);
}

.btn-primary:active {
  transform: translateY(0);
}

.clickable {
  cursor: pointer;
  transition: opacity 0.2s ease;
}

.clickable:hover {
  opacity: 0.8;
}

.mb-3, .my-3 {
  margin-bottom: 0.5rem !important;
}

.centered {
  text-align: center;
}

.mediumtext {
  font-size: 20px;
  font-weight: 500;
  font-family: var(--font-noto);
}

.smalltext {
  font-size: 13px;
  font-weight: bold;
  font-family: var(--font-noto);
}

.callout {
  margin-bottom: 0.5rem;
  padding: 0.7rem;
  border-radius: 8px;
  transition: all 0.3s ease;
}

.callout:hover {
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.left {
  float: left;
}

.right {
  float: right;
}

.dt-buttons {
  margin-bottom: -70px;
}

.scrollable-medium {
  height: 300px;
  overflow-y: auto;
  overflow-x: hidden;
  padding: 15px;
  scrollbar-width: thin;
  scrollbar-color: #1964a1 #f0f0f0;
}

.scrollable-medium::-webkit-scrollbar {
  width: 8px;
}

.scrollable-medium::-webkit-scrollbar-track {
  background: #f0f0f0;
  border-radius: 10px;
}

.scrollable-medium::-webkit-scrollbar-thumb {
  background: #1964a1;
  border-radius: 10px;
}

.scrollable-small {
  height: 180px;
  overflow-y: auto;
  padding: 15px;
  overflow-x: hidden;
  scrollbar-width: thin;
  scrollbar-color: #1964a1 #f0f0f0;
}

.scrollable-small::-webkit-scrollbar {
  width: 8px;
}

.scrollable-small::-webkit-scrollbar-track {
  background: #f0f0f0;
  border-radius: 10px;
}

.scrollable-small::-webkit-scrollbar-thumb {
  background: #1964a1;
  border-radius: 10px;
}

.centered-content {
  height: 100%;
}

.icon-anagr-red {
  font-size: 22px;
  transition: transform 0.2s ease;
}

.icon-anagr-green {
  font-size: 22px;
  transition: transform 0.2s ease;
}

.icon-anagr-red:hover,
.icon-anagr-green:hover {
  transform: scale(1.1);
}

.icon-anagr-red i {
  color: #dc3545;
}

.icon-anagr-green i {
  color: #28a745;
}

.elements {
  height: 100px;
  display: table-cell;
  vertical-align: middle;
}

.grid {
  border: 1px solid rgba(202, 202, 202, 0.3);
  border-radius: 12px;
  padding: 10px;
  background: rgba(255, 255, 255, 0.5);
  backdrop-filter: blur(10px);
  transition: all 0.3s ease;
}

.grid:hover {
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
  border-color: rgba(46, 134, 222, 0.3);
}

.deletable {
  position: absolute;
  top: -30px;
  right: -10px;
  transition: transform 0.2s ease;
}

.deletable:hover {
  transform: scale(1.1);
}

#tree > svg {
  background-color: #cacaca !important;
  border-radius: 8px;
}

.img-anag {
  border-radius: 50%;
  width: 100%;
  max-width: 110px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
  transition: all 0.3s ease;
}

.img-anag:hover {
  transform: scale(1.05);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.15);
}

.table-avatar {
  border-radius: 50%;
  display: inline;
  width: 2.5rem;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
  transition: all 0.2s ease;
}

.table-avatar:hover {
  transform: scale(1.1);
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.15);
}

.select2-container--default .select2-selection--multiple .select2-selection__rendered li:first-child.select2-search.select2-search--inline .select2-search__field {
  width: 100% !important;
  cursor: pointer;
}

.select2-container--default .select2-selection--multiple .select2-selection__choice {
  background: linear-gradient(135deg, #2E86DE 0%, #1E6BB8 100%);
  border: none;
  border-radius: 6px;
  transition: all 0.2s ease;
}

.select2-container--default .select2-selection--multiple .select2-selection__choice:hover {
  transform: translateY(-1px);
  box-shadow: 0 2px 6px rgba(46, 134, 222, 0.3);
}

.input-group-sm>.custom-select, .input-group-sm>.form-control:not(textarea) {
  width: 100px;
}

.select2-container--default .select2-selection--single {
  background-color: #fff;
  border: 1px solid rgba(170, 170, 170, 0.3);
  border-radius: 8px;
  height: 40px !important;
  transition: all 0.3s ease;
}

.select2-container--default .select2-selection--single:hover {
  border-color: var(--primary-color);
  box-shadow: 0 2px 8px rgba(46, 134, 222, 0.1);
}

.mirrored {
  -moz-transform: scale(-1, 1);
  -webkit-transform: scale(-1, 1);
  -o-transform: scale(-1, 1);
  -ms-transform: scale(-1, 1);
  transform: scale(-1, 1);
  transition: transform 0.3s ease;
}

.badge-primary {
  background: var(--primary-gradient);
  border-radius: 6px;
  padding: 0.35em 0.65em;
  font-weight: 500;
  box-shadow: 0 2px 4px rgba(46, 134, 222, 0.2);
  font-family: var(--font-noto);
}

.img-circle {
  border-radius: 10px;
  transition: all 0.3s ease;
}

.img-circle:hover {
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.brand-link .brand-image {
  float: left;
  line-height: .8;
  margin-left: .5rem;
  margin-right: .5rem;
  margin-top: -3px;
  max-height: 33px;
  width: 100%;
  max-width: 40px;
  transition: transform 0.3s ease;
}

.brand-link .brand-image:hover {
  transform: scale(1.05);
}

.overlay {
  position: absolute;
  top: 0;
  bottom: 0;
  left: 0;
  right: 0;
  height: 100%;
  width: 100%;
  opacity: 0;
  transition: .3s ease;
  background: linear-gradient(135deg, rgba(46, 134, 222, 0.9) 0%, rgba(30, 107, 184, 0.9) 100%);
  border-radius: 8px;
}

.imageoverlay:hover .overlay {
  opacity: 0.85;
  backdrop-filter: blur(4px);
}

.form-control.is-copied {
  border-color: #ffc107;
  padding-right: 2.25rem;
  background-image: url("data:image/svg+xml;charset=utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 8 8'%3E%3Cpath fill='%23f0ad4e' d='M4.4 5.324h-.8v-2.46h.8zm0 1.42h-.8V5.89h.8zM3.76.63L.04 7.075c-.115.2.016.425.26.426h7.397c.242 0 .372-.226.258-.426C6.726 4.924 5.47 2.79 4.253.63c-.113-.174-.39-.174-.494 0z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: center right calc(.375em + .1875rem);
  background-size: calc(.75em + .375rem) calc(.75em + .375rem);
  transition: all 0.3s ease;
}

input[type="number"] {
  border-radius: 8px !important;
  font-size: 16px !important;
  line-height: 26.666666667px !important;
  padding: 6.666666667px !important;
  width: 133.333333333%;
  transform: scale(0.75);
  transform-origin: left top;
  margin-bottom: -10px;
  margin-right: -33.333333333%;
  transition: all 0.3s ease;
}

input[type="number"]:focus {
  border-color: var(--primary-color);
  box-shadow: 0 0 0 0.2rem rgba(46, 134, 222, 0.15);
}

.inputprice {
  border-radius: 8px !important;
  font-size: 16px !important;
  line-height: 26.666666667px !important;
  padding: 6.666666667px !important;
  width: 133.333333333%;
  transform: scale(0.75);
  transform-origin: left top;
  margin-bottom: -10px;
  margin-right: -33.333333333%;
  transition: all 0.3s ease;
}

.inputprice:focus {
  border-color: var(--primary-color);
  box-shadow: 0 0 0 0.2rem rgba(46, 134, 222, 0.15);
}

.progress-bar {
  font-weight: bold;
  background: linear-gradient(90deg, #2E86DE 0%, #54A0FF 100%);
  border-radius: 8px;
  transition: all 0.3s ease;
}

.legend-item {
  margin-left: 20px;
}

.navbar {
  display: grid;
}

.countryFlag {
  border-radius: 50%;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
  transition: all 0.2s ease;
}

.countryFlag:hover {
  transform: scale(1.1);
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.15);
}

.goUpBtn {
  position: -webkit-sticky;
  position: sticky;
  bottom: 10px;
  opacity: 0.6;
  transition: all 0.3s ease;
  border-radius: 50%;
}

.goUpBtn:hover {
  opacity: 1;
  transform: translateY(-4px);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.2);
}

.btn-primary.disabled, .btn-primary:disabled {
  color: #fff;
  background: linear-gradient(135deg, #87BBFF 0%, #54A0FF 100%);
  border: none;
  opacity: 0.65;
}

.rightborder {
  border-right: 1px solid rgba(202, 202, 202, 0.5);
  width: 100%;
}

.colored {
  color: var(--primary-color);
  font-weight: 600;
  font-family: var(--font-noto);
}

.text-courier {
  font-family: 'Noto Sans Mono', 'Courier New', Courier, monospace;
  font-size: 18px;
}

.customcontainer {
  border: 2px solid rgba(46, 134, 222, 0.3);
  border-radius: 12px;
  padding: 10px;
  background: rgba(255, 255, 255, 0.5);
  backdrop-filter: blur(10px);
  transition: all 0.3s ease;
}

.customcontainer:hover {
  border-color: var(--primary-color);
  box-shadow: 0 4px 16px rgba(46, 134, 222, 0.1);
}

.popper,
.tooltip {
  position: absolute;
  z-index: 9999;
  color: black;
  width: 150px;
  border-radius: 8px;
  box-shadow: 0 4px 16px rgba(46, 134, 222, 0.3);
  text-align: center;
  padding: 0;
  animation: tooltipFadeIn 0.2s ease;
  font-family: var(--font-noto);
}

.style5 .tooltip {
  background: linear-gradient(135deg, #1E252B 0%, #2a3238 100%);
  color: #FFFFFF;
  max-width: 200px;
  width: auto;
  font-size: .8rem;
  padding: .5em 1em;
  font-family: var(--font-noto);
}

.popper .popper__arrow,
.tooltip .tooltip-arrow {
  width: 0;
  height: 0;
  border-style: solid;
  position: absolute;
  margin: 5px;
}

.tooltip .tooltip-arrow,
.popper .popper__arrow {
  border-color: #FFC107;
}

.style5 .tooltip .tooltip-arrow {
  border-color: #1E252B;
}

.popper[x-placement^="top"],
.tooltip[x-placement^="top"] {
  margin-bottom: 5px;
}

.popper[x-placement^="top"] .popper__arrow,
.tooltip[x-placement^="top"] .tooltip-arrow {
  border-width: 5px 5px 0 5px;
  border-left-color: transparent;
  border-right-color: transparent;
  border-bottom-color: transparent;
  bottom: -5px;
  left: calc(50% - 5px);
  margin-top: 0;
  margin-bottom: 0;
}

.popper[x-placement^="bottom"],
.tooltip[x-placement^="bottom"] {
  margin-top: 5px;
}

.tooltip[x-placement^="bottom"] .tooltip-arrow,
.popper[x-placement^="bottom"] .popper__arrow {
  border-width: 0 5px 5px 5px;
  border-left-color: transparent;
  border-right-color: transparent;
  border-top-color: transparent;
  top: -5px;
  left: calc(50% - 5px);
  margin-top: 0;
  margin-bottom: 0;
}

.tooltip[x-placement^="right"],
.popper[x-placement^="right"] {
  margin-left: 5px;
}

.popper[x-placement^="right"] .popper__arrow,
.tooltip[x-placement^="right"] .tooltip-arrow {
  border-width: 5px 5px 5px 0;
  border-left-color: transparent;
  border-top-color: transparent;
  border-bottom-color: transparent;
  left: -5px;
  top: calc(50% - 5px);
  margin-left: 0;
  margin-right: 0;
}

.popper[x-placement^="left"],
.tooltip[x-placement^="left"] {
  margin-right: 5px;
}

.popper[x-placement^="left"] .popper__arrow,
.tooltip[x-placement^="left"] .tooltip-arrow {
  border-width: 5px 0 5px 5px;
  border-top-color: transparent;
  border-right-color: transparent;
  border-bottom-color: transparent;
  right: -5px;
  top: calc(50% - 5px);
  margin-left: 0;
  margin-right: 0;
}

.bg-primary {
  background: var(--primary-gradient) !important;
}

.rotate {
  writing-mode: vertical-lr;
  margin: 5px;
}

.extend {
  height: calc(100vh - 100px);
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: var(--primary-color) #f0f0f0;
}

.extend::-webkit-scrollbar {
  width: 8px;
}

.extend::-webkit-scrollbar-track {
  background: #f0f0f0;
  border-radius: 10px;
}

.extend::-webkit-scrollbar-thumb {
  background: var(--primary-color);
  border-radius: 10px;
}

.customevent {
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  width: 100%;
  height: 100%;
}

.allegato-img {
  height: 100px;
  width: 100%;
  object-fit: cover;
  border-radius: 8px;
  transition: all 0.3s ease;
}

.allegato-img:hover {
  transform: scale(1.05);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

input:is(:-webkit-autofill, :autofill) {
  background-color: #65d9ff !important;
  -webkit-text-fill-color: black !important;
  -webkit-box-shadow: 0 0 0px 1000px rgba(114, 217, 252, 0.65) inset !important;
  border-radius: 8px !important;
  transition: all 0.3s ease !important;
}