
/* =========================================================
   Base / Typography
   ========================================================= */

@font-face {
  font-family: Oswald;
  src: url(../fonts/Oswald-VariableFont_wght.ttf);
}

body {
  margin: 0;
  font-family: Arial, sans-serif;
}

h1, h2, h3, h4, h5, h6 {
  font-family: Oswald, sans-serif;
}

/* Slightly dim offline tiles (Bootstrap badge override) */
.card .badge.bg-secondary {
  opacity: 0.9;
}


/* =========================================================
   Layout
   ========================================================= */

/* Sidebar */
.sidebar {
  position: fixed;
  top: 0;
  right: -250px;
  width: 250px;
  height: 100vh;
  background-color: #333;
  padding: 20px 0;
  transition: right 0.3s ease;
  z-index: 1000;
  overflow-y: auto;
}

.sidebar.open {
  right: 0;
}

.sidebar .nav-link {
  color: #fff;
  padding: 15px 20px;
  text-decoration: none;
  display: block;
  transition: background-color 0.2s;
}

.sidebar .nav-link:hover {
  background-color: #555;
  color: #fff;
}

/* Main content wrapper */
.main-content {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  transition: margin-right 0.3s ease;
  margin-right: 0;
}

.main-content.sidebar-open {
  margin-right: 250px;
}

/* Banner */
.banner-container {
  background-color: black;
  width: 100%;
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 60px;
}

.banner-logo {
  flex: 0 0 auto;
  display: flex;
}

.banner-title {
  flex: 1;
  display: flex;
  justify-content: center;
  font-size: 1.5rem;
  color: #ffffff;
}

.banner-menu {
  flex: 0 0 auto;
  display: flex;
  margin-right: 10px;
  max-height: 48px;
  width: auto;
}

/* Footer */
.footer {
  margin-top: auto;
  background-color: #000000;
  text-align: center;
}


/* =========================================================
   Components
   ========================================================= */

/* Component: Service card (visual styling) */
.service-card {
  overflow: hidden; /* keep rounded corners clean */
  border-radius: 15px;
  transition: all 0.3s ease;
  border: none;
  background: linear-gradient(145deg, #ffffff, #f3f3f3);
  box-shadow: 5px 5px 15px #d9d9d9, -5px -5px 15px #ffffff;
  cursor: pointer;
  text-decoration: none;
  color: inherit;
  display: block;
}

.service-card:hover {
  transform: translateY(-10px);
  box-shadow: 8px 8px 20px #d1d1d1, -8px -8px 20px #ffffff;
  text-decoration: none;
  color: inherit;
}

/* Component: Sidebar toggle button */
.toggle-btn {
  color: #fa0808;
}

.toggle-btn:hover {
  background-color: #555;
  color: #fa0808;
}

/* Component: Clickable table row affordance + keyboard focus */
.table-row-action {
  cursor: pointer;
}

.table-row-action:hover {
  background: rgba(51, 50, 50, 0.06);

}

.table-row-action:focus {
  outline: 2px solid rgba(250, 8, 8, 0.6);
  outline-offset: -2px;
}

/* Component: Telemetry table sizing (used on device page) */
.telemetry-table {
  table-layout: fixed;
  width: 100%;
}

.telemetry-table th.value-col,
.telemetry-table td.value-col {
  width: 40%;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}


/* =========================================================
   Devices page components (BEM-ish grouping, no renames)
   ========================================================= */

/* Block: UUT card (behavioral/overlay rules) */
.uut-card {
  position: relative;
  overflow: visible; /* dropdowns/tooltips must not be clipped */
}

/* Modifier/state: UUT card when dropdown is open */
.uut-card.dropdown-open {
  z-index: 3000; /* keep dropdown above underlying cards */
}

/* Element: left status rail */
.uut-card .uut-rail {
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 6px;
  background: rgba(0, 0, 0, 0.12);
}

/* Element: pinned status badge */
.uut-status-badge {
  position: absolute;
  top: 10px;
  right: 10px;
  z-index: 5;
}

/* Modifier/state: online */
.uut-card.uut-online .uut-rail {
  background: rgba(25, 135, 84, 0.65); /* Bootstrap success tone */
}

/* Modifier/state: offline */
.uut-card.uut-offline {
  filter: brightness(0.92) saturate(0.92);
}

.uut-card.uut-offline .uut-rail {
  background: rgba(108, 117, 125, 0.75);
}

/* Block: recording control group */
.uut-rec-group .dropdown-menu {
  z-index: 2000; /* ensure menu above other content */
}

/* Element: recording slot alignment */
.uut-rec-slot {
  display: flex;
  align-items: center;
}

/* Block: Part grouping */
.part-group {
  width: 100%;
}

.part-cards {
  width: 100%;
}

.part-row {
  display: grid;
  grid-template-columns: 160px 1fr;
  gap: 12px;
  align-items: start;
}

.part-label {
  font-size: 0.9rem;
  font-weight: 600;
  color: rgba(0, 0, 0, 0.65);
  padding-top: 6px;
}

@media (max-width: 768px) {
  .part-row { grid-template-columns: 1fr; }
  .part-label { padding-top: 0; }
}

/* Block: Hover tooltip (Popper virtual anchor) */
.uut-hover-tooltip {
  position: fixed;
  z-index: 4000;
  background: rgba(33, 37, 41, 0.92);
  color: #fff;
  font-size: 0.85rem;
  padding: 6px 10px;
  border-radius: 10px;
  pointer-events: none;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.2);
  max-width: 260px;
}


/* =========================================================
   Animations
   ========================================================= */

/* Bootstrap-friendly entrance animation */
.rec-fadein {
  animation: recFadeIn 160ms ease-out;
}

@keyframes recFadeIn {
  from { opacity: 0; transform: translateY(4px); }
  to   { opacity: 1; transform: translateY(0); }
}

