/* Homepage-only refinement against the approved Image2 overview direction. */

.kpi-label {
  align-items: center;
  justify-content: flex-start;
  gap: 8px;
}

.kpi-label > span:last-child {
  margin-left: auto;
}

.kpi-icon {
  width: 17px;
  height: 17px;
  flex: 0 0 auto;
  color: var(--i2-cyan);
  filter: drop-shadow(0 0 7px rgba(57, 216, 255, .28));
  stroke-width: 1.75;
}

.alarm-kpi .kpi-icon {
  color: var(--i2-amber);
  filter: drop-shadow(0 0 8px rgba(255, 184, 74, .3));
}

.kpi-item {
  padding-bottom: 14px;
}

.kpi-item.no-progress .progress {
  display: none;
}

.kpi-meta {
  position: relative;
  z-index: 1;
  margin-top: 5px;
  padding-bottom: 5px;
}

.progress {
  right: 16px;
  bottom: 6px;
  left: 16px;
  height: 2px;
}

.scene-canvas {
  background:
    radial-gradient(circle at 52% 48%, rgba(27, 126, 157, .1), transparent 52%),
    rgba(1, 11, 18, .92) !important;
}

.scene-vignette {
  background:
    radial-gradient(ellipse at 50% 47%, transparent 58%, rgba(1, 7, 12, .26) 100%),
    linear-gradient(180deg, rgba(3, 15, 24, .015), transparent 23%, transparent 83%, rgba(1, 7, 12, .18)) !important;
}

body .plant-label {
  min-width: 116px;
  padding: 7px 9px 6px;
  border-radius: 5px;
  background: rgba(3, 19, 29, .88) !important;
}

body .plant-label[data-selected] {
  border-color: rgba(255, 184, 74, .9) !important;
  background: rgba(45, 27, 12, .92) !important;
  box-shadow: 0 0 0 1px rgba(255, 184, 74, .14), 0 10px 28px rgba(0, 4, 10, .38), 0 0 22px rgba(255, 155, 38, .17) !important;
}

body .plant-label__name {
  font-size: 13px;
  font-weight: 700;
}

body .plant-label__metric {
  color: #a9c2cc;
  font-size: 11px;
}

body .scene-panel .plant-device-card {
  top: 76px !important;
  right: 12px !important;
  bottom: auto !important;
  height: auto !important;
  width: 316px;
  min-height: 0;
  padding: 12px;
  border-radius: 6px;
  pointer-events: none;
}

body .scene-panel .plant-device-card.is-open {
  pointer-events: auto;
}

.plant-device-card__header {
  display: flex;
  min-height: 40px;
  margin: -7px -5px 6px 0;
  align-items: center;
  justify-content: space-between;
}

.plant-device-card__kind {
  display: flex;
  align-items: center;
  gap: 7px;
  color: #91aab4;
  font-size: 10px;
  font-weight: 650;
  letter-spacing: .06em;
}

.plant-device-card__kind i {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #44d4e4;
  box-shadow: 0 0 10px rgba(68, 212, 228, .62);
}

.plant-device-card__kind.is-alert {
  color: #ffd18a;
}

.plant-device-card__kind.is-alert i {
  background: #ffb44a;
  box-shadow: 0 0 10px rgba(255, 180, 74, .72);
}

.plant-device-card__kind time {
  padding-left: 7px;
  border-left: 1px solid rgba(255, 255, 255, .1);
  color: #7f99a5;
  font-variant-numeric: tabular-nums;
  font-weight: 500;
  letter-spacing: 0;
}

.plant-device-card__close {
  display: grid;
  width: 44px;
  height: 44px;
  flex: 0 0 44px;
  padding: 0;
  border: 0;
  border-radius: 4px;
  place-items: center;
  background: transparent;
  color: #8da7b2;
  cursor: pointer;
}

.plant-device-card__close:hover,
.plant-device-card__close:focus-visible {
  background: rgba(68, 212, 228, .08);
  color: #effaff;
  outline: 1px solid rgba(68, 212, 228, .48);
  outline-offset: -1px;
}

.plant-device-card__close svg {
  width: 18px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-width: 1.6;
}

.plant-device-card__focus {
  display: grid;
  grid-template-columns: 78px minmax(0, 1fr);
  gap: 10px;
  align-items: center;
}

.plant-device-card__visual {
  position: relative;
  width: 78px;
  height: 66px;
  overflow: hidden;
  border: 1px solid rgba(255, 184, 74, .38);
  border-radius: 5px;
  background: rgba(255, 174, 62, .06);
}

.plant-device-card__visual img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.plant-device-card__visual::after {
  position: absolute;
  inset: 0;
  border: 1px solid rgba(255,255,255,.05);
  box-shadow: inset 0 -24px 32px rgba(2, 8, 12, .22);
  content: "";
}

body .plant-device-card__eyebrow {
  color: #8ce9dd;
  font-size: 9px;
  letter-spacing: .1em;
}

body .plant-device-card__title {
  margin-top: 4px;
  font-size: 15px;
}

.plant-device-card__alert-copy {
  margin: 5px 0 0;
  color: #ffd69b;
  font-size: 10px;
  line-height: 1.45;
}

body .plant-device-card__metrics {
  grid-template-columns: repeat(3, 1fr);
  gap: 6px;
  margin-top: 8px;
}

body .plant-device-card__metrics.is-standard {
  grid-template-columns: repeat(2, 1fr);
}

body .plant-device-card__metric {
  min-width: 0;
  padding: 7px 6px 6px;
  border-radius: 4px;
}

body .plant-device-card__metric small {
  overflow: hidden;
  color: #91aab4;
  font-size: 9px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

body .plant-device-card__metric strong {
  margin-top: 3px;
  color: #effaff;
  font-size: 12px;
  white-space: nowrap;
}

.plant-device-card__metric.is-alert strong {
  color: #ffbd5b;
}

.plant-device-card__trace {
  display: flex;
  margin-top: 8px;
  padding-top: 7px;
  border-top: 1px solid rgba(124, 189, 210, .12);
  justify-content: space-between;
  color: #78929e;
  font-size: 9px;
  font-variant-numeric: tabular-nums;
}

.plant-device-card__actions {
  display: grid;
  grid-template-columns: .86fr 1.2fr;
  gap: 7px;
  margin-top: 9px;
}

.plant-device-card__action {
  display: flex;
  min-width: 0;
  min-height: 44px;
  padding: 0 10px;
  border: 1px solid rgba(111, 165, 184, .22);
  border-radius: 4px;
  align-items: center;
  justify-content: center;
  background: rgba(7, 39, 62, .64);
  color: #a7bdc6;
  font: inherit;
  font-size: 10px;
  font-weight: 620;
  text-decoration: none;
  cursor: pointer;
}

.plant-device-card__action:hover,
.plant-device-card__action:focus-visible {
  border-color: rgba(68, 212, 228, .62);
  color: #effaff;
  outline: none;
}

.plant-device-card__action.is-primary {
  border-color: rgba(68, 212, 228, .42);
  background: linear-gradient(135deg, rgba(11, 105, 145, .72), rgba(5, 65, 105, .76));
  color: #e9fbff;
}

.plant-device-card__action.is-primary span {
  margin-left: 7px;
  color: #65e8ef;
}

.plant-device-card__action:disabled {
  border-color: rgba(90, 210, 154, .22);
  background: rgba(90, 210, 154, .07);
  color: #72d9a7;
  cursor: default;
}

.chart-panel {
  position: relative;
  min-height: 0;
}

.chart-panel .chart-legend {
  min-height: 22px;
  margin-bottom: 0;
}

.chart-panel .line-chart {
  position: absolute;
  right: 8px;
  bottom: 4px;
  left: 8px;
  width: calc(100% - 16px);
  height: calc(100% - 76px) !important;
  min-height: 0;
  max-height: none;
  top: auto;
}

@container console-screen (max-width: 1500px) {
  .brand {
    min-width: 128px !important;
  }

  .brand-name {
    display: block !important;
    font-size: 13px !important;
    letter-spacing: .06em;
  }

  .main-nav {
    min-width: 560px !important;
  }

  .header-title {
    left: 61.8% !important;
    display: block !important;
    padding: 0 16px;
  }

  .header-title::before,
  .header-title::after {
    opacity: .26;
  }

  .header-title h1 {
    font-size: 18px !important;
    letter-spacing: .045em;
  }

  .topbar-meta {
    min-width: 300px !important;
  }

  .clock-block span,
  .weather,
  .meta-divider:nth-of-type(2) {
    display: none;
  }

  .kpi-item {
    padding: 9px 11px 13px;
  }

  .kpi-label {
    gap: 6px;
    font-size: 11px;
  }

  .kpi-icon {
    width: 15px;
    height: 15px;
  }

  .kpi-value {
    margin-top: 3px;
  }

  .kpi-value strong {
    font-size: 25px;
  }

  .kpi-meta {
    margin-top: 3px;
    padding-bottom: 3px;
  }

  .progress {
    right: 12px;
    bottom: 5px;
    left: 12px;
  }

  body .plant-label {
    min-width: 88px !important;
    max-width: 114px !important;
    padding: 6px 8px !important;
  }

  body .plant-label__name {
    font-size: 12px;
  }

  body .plant-label__metric {
    display: none;
  }

  body .scene-panel .plant-device-card {
    top: 66px !important;
    right: 10px !important;
    width: 276px;
    padding: 9px;
  }

  .plant-device-card__focus {
    grid-template-columns: 66px minmax(0, 1fr);
    gap: 8px;
  }

  .plant-device-card__visual {
    width: 66px;
    height: 58px;
  }

  body .plant-device-card__metrics {
    gap: 4px;
    margin-top: 6px;
  }

  body .plant-device-card__metric {
    padding: 5px 4px;
  }

  .plant-device-card__alert-copy {
    margin-top: 3px;
    font-size: 9px;
  }

  .plant-device-card__header {
    margin-top: -5px;
    margin-bottom: 3px;
  }

  .plant-device-card__trace {
    margin-top: 6px;
  }

  .plant-device-card__actions {
    margin-top: 6px;
  }

  .chart-panel .line-chart {
    height: calc(100% - 70px) !important;
    bottom: 3px;
  }
}

@container console-screen (max-height: 820px) {
  .chart-panel .panel-heading {
    margin-bottom: 5px;
  }

  .chart-panel .chart-legend {
    min-height: 18px;
    font-size: 9px;
  }

  .chart-panel .line-chart {
    height: calc(100% - 68px) !important;
    bottom: 2px;
  }

  body .scene-panel .plant-device-card {
    top: 60px !important;
  }
}
