@import './variables.scss';
@import './mixin.scss';
@import './transition.scss';
@import './element-ui.scss';
@import './sidebar.scss';
@import './btn.scss';

// 工业风全局字体与背景
body {
  height: 100%;
  margin: 0;
  background-color: #071120;
  color: $industrial-text;
  -moz-osx-font-smoothing:  grayscale;
  -webkit-font-smoothing:   antialiased;
  text-rendering:           optimizeLegibility;
  font-family: 'Helvetica Neue', Helvetica, 'PingFang SC', 'Microsoft YaHei',
               'Source Han Sans CN', Arial, monospace;
  font-size: 14px;
}

label { font-weight: 600; color: #8ab0cc; }

html {
  height: 100%;
  box-sizing: border-box;
}

#app { height: 100%; }

*, *:before, *:after { box-sizing: inherit; }

a:focus, a:active { outline: none; }
a, a:focus, a:hover {
  cursor: pointer;
  color: $industrial-cyan;
  text-decoration: none;
}

div:focus { outline: none; }

// 工具类
.fr { float: right; }
.fl { float: left; }
.pr-5 { padding-right: 5px; }
.pl-5 { padding-left: 5px; }
.block { display: block; }
.pointer { cursor: pointer; }
.inlineBlock { display: block; }
.text-center { text-align: center; }
.no-padding { padding: 0 !important; }
.padding-content { padding: 4px 0; }

.clearfix:after {
  visibility: hidden;
  display: block;
  font-size: 0;
  content: " ";
  clear: both;
  height: 0;
}

// 页面内容容器
.app-container {
  padding: 16px 20px;
  background-color: transparent;
}

// 搜索/过滤栏
.filter-container {
  padding-bottom: 12px;
  background-color: $industrial-surface;
  padding: 12px 16px;
  border: 1px solid $industrial-border;
  border-radius: 4px;
  margin-bottom: 12px;

  .filter-item {
    display: inline-block;
    vertical-align: middle;
    margin-bottom: 8px;
    margin-right: 8px;
  }
}

// 状态徽标 — 机组运行状态
.status-dot {
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  margin-right: 6px;

  &.running { background-color: $industrial-green;  box-shadow: 0 0 6px $industrial-green; }
  &.stopped { background-color: $industrial-red;    box-shadow: 0 0 6px $industrial-red; }
  &.standby { background-color: $industrial-amber;  box-shadow: 0 0 6px $industrial-amber; }
  &.offline  { background-color: $industrial-text-muted; }
}

// 数据看板 — 工艺参数数值框
.param-value {
  font-family: 'Courier New', Courier, monospace;
  font-size: 20px;
  font-weight: 700;
  color: $industrial-cyan;
  letter-spacing: 1px;
}

.param-unit {
  font-size: 11px;
  color: $industrial-text-muted;
  margin-left: 4px;
}

// 告警闪烁
@keyframes alarmBlink {
  0%, 100% { opacity: 1; }
  50%       { opacity: 0.3; }
}

.alarm-blink {
  animation: alarmBlink 1s ease-in-out infinite;
  color: $industrial-red;
}

// 顶部导航栏
.navbar {
  background-color: #091628 !important;
  border-bottom: 1px solid #00d4ff33 !important;
  box-shadow: 0 2px 12px rgba(0, 212, 255, 0.08) !important;
}

// 面包屑
.el-breadcrumb__inner { color: #6b8aaa !important; }
.el-breadcrumb__inner.is-link:hover { color: #00d4ff !important; }
.el-breadcrumb__separator { color: #1a3a5c !important; }

// 标签页(tab-view)
.tags-view-container {
  background-color: #071120 !important;
  border-bottom: 1px solid #1a3a5c !important;

  .tags-view-wrapper .tags-view-item {
    background-color: #0e2137 !important;
    border: 1px solid #1a3a5c !important;
    color: #8ab0cc !important;

    &.active {
      background-color: #0077aa !important;
      border-color: #00d4ff !important;
      color: #ffffff !important;
    }
  }
}

// 侧边栏 Logo 区域
.sidebar-logo-container {
  background-color: #060f1e !important;
  border-bottom: 1px solid #1a3a5c !important;

  .sidebar-title {
    color: #00d4ff !important;
    font-size: 16px !important;
    font-weight: 700 !important;
    letter-spacing: 1px;
  }
}

// 滚动条工业风格
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track  { background: #071120; }
::-webkit-scrollbar-thumb  { background: #1a3a5c; border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: #00d4ff55; }

// 提示/备注区域
aside {
  background: #0e2137;
  padding: 8px 16px;
  margin-bottom: 16px;
  border-left: 3px solid #00d4ff;
  border-radius: 2px;
  display: block;
  line-height: 32px;
  font-size: 13px;
  color: #8ab0cc;

  a { color: #00d4ff; &:hover { color: #40e0ff; } }
}

.link-type, .link-type:focus {
  color: #00d4ff;
  cursor: pointer;
  &:hover { color: #40e0ff; }
}

.sub-navbar {
  height: 50px;
  line-height: 50px;
  position: relative;
  width: 100%;
  text-align: right;
  padding-right: 20px;
  background: linear-gradient(90deg, #0a1e35 0%, #0077aa 100%);
  border-bottom: 1px solid #00d4ff44;

  .subtitle { font-size: 16px; color: #fff; letter-spacing: 1px; }
}

.components-container {
  margin: 20px 30px;
  position: relative;
}

// 多选
.multiselect { line-height: 16px; }
.multiselect--active { z-index: 1000 !important; }
