@import url("https://fonts.googleapis.com/css2?family=Roboto:ital,wght@0,100..900;1,100..900&display=swap");

.widget-card {
  background-color: #020714;
  border: 1px solid #252a40;
  border-radius: 12px;
  opacity: 0.9;
  padding: 12px;

  color: #ffffff;

  width: 100%;
  height: 100%;

  font-family: "Roboto", sans-serif;
  font-optical-sizing: auto;
  font-size: 14px;
  font-weight: 400;

  box-sizing: border-box;

  line-height: 1.5;

  user-select: none;
  position: relative;
}

.popup-story {
  min-width: 400px;
  width: 100%;
  max-width: 1200px;

  min-height: 300px;
  height: 100%;
  max-height: 700px;
}

button.close {
  border: none;
  background-color: transparent;
  color: white;
  transition: all 150ms;
}
button.close:hover {
  opacity: 0.75;
}

.canvas-3d-model-container {
  position: absolute;
  top: 0px;
  bottom: 0px;
  left: 0px;
  right: 0px;

  font-family: "Roboto", sans-serif;
  font-optical-sizing: auto;
  font-size: 14px;
  font-weight: 400;

  box-sizing: border-box;

  line-height: 1.5;
}

.widget-card .title {
  color: #fce80c;
  font-size: 30px;
  /*margin-bottom: 10px;*/
}

.widget-card .title-small {
  color: white;
  font-size: 16px;
}

.widget-card .title-medium {
  color: #fce80c;
  font-size: 24px;
}

.widget-card .title-small.multiple-values {
  color: white;
  font-size: 16px;
  margin-bottom: 0.25rem;
}

.key-value-pairs {
  display: grid;
  grid-template-columns: auto 1fr;
  /* grid-template-rows: auto; */
  grid-auto-rows: minmax(min-content, 1.25rem);
  column-gap: 1rem;
}

.key-value-pairs.multiple-values {
  grid-template-columns: auto minmax(auto, 60%);
}

.key-value-pairs .important {
  font-size: 16px;
  margin-top: 14px;
}

.key-value-pairs .key {
  font-weight: 300;
  align-self: start;
}

.key-value-pairs .key.important {
  font-weight: 400;
}

.key-value-pairs .value {
  font-weight: 400;
  align-self: start;
  display: inline-flex !important;
  align-items: center;
  gap: 0.5rem;
}

.key-value-pairs .lastGridRow {
  align-self: end;
}

.key-value-pairs.multiple-values .value {
  overflow: hidden;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
}

.key-value-pairs .value.important {
  font-weight: 700;
}

.key-value-pairs .value img {
  display: block;
  height: 1.25rem;

  aspect-ratio: 1;
}

.status-ok {
  color: #24fc0c;
}

.status-error,
.widget-card .title.status-error {
  color: #fc0c3d;
}

.status-alarm,
.widget-card .title.status-alarm {
  color: #fc0c3d;
}

.status-warning,
.widget-card .title.status-warning {
  color: #ffe400;
}

.status-info,
.widget-card .title.status-info {
  color: white;
}

.status-unknown {
  color: white;
}

.status-on {
  color: #00c926;
}

.status-off {
  color: gray;
}

.production-data-step-info-row {
  display: flex;
  flex-direction: row;
  justify-content: center;
  margin-top: 0.5rem;
  margin-bottom: 1.2rem;
}

.production-data-step-info {
  display: inline-block;
  text-align: center;
  padding-left: 24px;
  padding-right: 24px;
}

.production-data-step-separator {
  background-color: #555d7f;
  width: 1px;
  height: 24px;
  align-self: center;
}

.production-data-step-info .key {
  font-weight: 300;
}

.production-data-step-info .value {
  font-weight: 700;
  color: #fce80c;
  font-size: 25px;
}

.production-data.key-value-pairs .value {
  color: #2089c9;
  text-align: right;
}

.gauges-row {
  display: flex;
  flex-direction: row;
  justify-content: center;
  margin-bottom: 16px;
}

.gauges-cell {
  flex: 1;
}

.gauges-cell div {
  width: 100%;
}

.loading-error-message {
  margin: 0;
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  font-size: "12px";
}

/* Optional: Style the container inside Html */
.loading-progress-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  position: absolute;
  bottom: 0px;
  width: 100%;
  pointer-events: none;
  gap: 2px;
  z-index: 100;
}

/* Style for the overall progress element */
.loading-progress-bar {
  width: 100%;
  height: 8px;

  /* Remove default browser styling */
  -webkit-appearance: none;
  -moz-appearance: none;
  appearance: none;
  border: none; /* Remove default border */
  background-color: #3a3f53; /* Dark background for the track */
}

/* Style for the filled part in Webkit browsers (Chrome, Safari, Edge) */
.loading-progress-bar::-webkit-progress-value {
  background-color: #3197d7; /* Black color for the filled part */
  transition: width 0.1s ease-out; /* Smooth transition */
}

/* Style for the track (empty part) in Webkit browsers */
.loading-progress-bar::-webkit-progress-bar {
  background-color: #3a3f53; /* Dark background for the track */
}

/* Style for the filled part in Firefox */
.loading-progress-bar::-moz-progress-bar {
  background-color: #3197d7; /* Black color for the filled part */
  transition: width 0.1s ease-out; /* Smooth transition */
}

.loading-progress-text {
  margin-top: 4px;
  color: "#2089c9";
  font-size: "12px";
  text-align: "center";
}

.round-status-indicator-outer {
  width: 38px;
  height: 38px;
  border-radius: 19px;
  color: black;

  display: flex;
  justify-content: center;
  align-items: center;
  position: absolute;
  top: 16px;
  right: 16px;
}

.round-status-indicator-outer.open-popup {
  bottom: 1rem;
  top: initial;
}

.widget-blinking-element {
  animation: widget-blinking-element-blinker 1s step-end infinite;
}

@keyframes widget-blinking-element-blinker {
  0% {
    opacity: 1;
  } /* Start fully visible */
  50% {
    opacity: 0;
  } /* Mid-point fully invisible */
  100% {
    opacity: 1;
  }
}

.alarms-panel-status-indicator-icon {
  width: 38px;
  position: absolute;
  top: 16px;
  right: 16px;
}

.widget-card-flex {
  display: flex;
  flex-direction: column;
  justify-content: stretch;
  overflow: hidden;
}

.round-status-indicator-inner {
  font-size: 16px;
  font-weight: 700;
  text-transform: uppercase;

  display: flex;
  justify-content: center;
  align-items: center;
  border: 2px solid black;
  position: absolute;
  top: 4px;
  bottom: 4px;
  left: 4px;
  right: 4px;
  border-radius: 16px;
}

button.reload {
  cursor: pointer;
  border: none;
  background-color: transparent;
  color: white;
  font-size: 1.5rem;
  display: flex;
  justify-items: center;
  align-items: center;
  justify-content: center;
  padding: 0.25rem;
  line-height: 24px;
  transition: all 100ms;
  aspect-ratio: 1;
}
button.reload:hover {
  opacity: 0.5;
}

div.popup-opener-wrapper {
  align-self: flex-end;
}

button.popup-opener {
  z-index: 5;
  pointer-events: all;
  font-size: 0.8rem;
  line-height: 0.8rem;
  padding: 0.5rem;
  cursor: pointer;
  text-align: end;
  background-color: transparent;
  color: #fff;
  font-weight: 500;
  border: 0;
  cursor: pointer;
}

/* .data-grid .Error {
  background: #dc262680;
} */
.data-grid .Error {
  background: rgba(236, 70, 56, 0.5);
}

.alarms-history-table {
  border: 0 !important;
  min-width: 800px;
  /* Fill the popup's height (the popup has an explicit height, see popup.css) */
  flex: 1;
  min-height: 0;
}

.alarms-history-table.loading .MuiDataGrid-row {
  display: none;
}

.alarms-history-table .MuiDataGrid-filler {
  opacity: 0;
}

.history-line-graph {
  padding-right: 16px;
}

.history-line-graph .customMarkElement {
  scale: 0.6;
  fill: #70baeb;
}

.data-grid .Warning {
  background: rgba(255, 162, 25, 0.5);
}

/* TESTING */

table th,
td {
  padding: initial;
  width: initial;
  background-color: initial;
}

div .linear-indicators-grid {
  width: 100%;
  overflow: clip;
  display: grid;
  grid-template-columns: fit-content(33%) 1fr;
  grid-auto-rows: min-content;
  align-items: end;
  column-gap: 0.5rem;
}

/* 1. The entire scrollbar */
.dashboard-grid-container ::-webkit-scrollbar {
  width: 10px; /* Adjust the width for vertical scrollbar */
  height: 10px; /* Adjust the height for horizontal scrollbar */
}

/* 2. The track (the background area) */
.dashboard-grid-container ::-webkit-scrollbar-track {
  background-color: #3a3f53; /* Light gray track */
  border-radius: 10px;
}

/* 3. The thumb (the draggable part) */
.dashboard-grid-container ::-webkit-scrollbar-thumb {
  background-color: #4a95ce; /* Blue thumb */
  border-radius: 10px;
}

/* 4. On hover for visual feedback */
.dashboard-grid-container ::-webkit-scrollbar-thumb:hover {
  background-color: #57b0f4; /* Darker blue on hover */
}

.widget-loading-overlay {
  position: absolute;
  inset: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: rgba(2, 7, 20, 0.75);
  border-radius: 12px;
}

/* Variable status timeline */

.state-timeline-segments g rect {
  transition: 150ms ease-in-out outline;
  outline: red;
}

.state-timeline-segments rect:hover {
  outline: 3px solid red;

  z-index: 10;
}
