/* 巡检点管理组件样式 */
.container {
  padding: 20px;
  background-color: #ffffff;
  min-height: 100vh;
  border-radius: 10px;
}

.resetBtn {
  background-size: cover;
  background-position: center;
  color: #006665;
  //opacity:0.7;
  border-radius: 4px;
  width: 88px;
  height: 36px;
}

/* 进度条容器 */
.progressContainer {
  margin-bottom: 20px;
  width: 810px;
  height: 48px;
  background-image: url('~@/assets/img/progress1.svg');
  background-position: left top;
  background-repeat: no-repeat;
  overflow: hidden;
}

/* 主体内容容器 */
.contentContainer {
  display: flex;
  gap: 20px;
}

/* 主体内容容器 */
.contentContainer {
  display: flex;
  gap: 20px;
}

/* 左侧树形结构区域 */
.leftSide {
  flex: 0 0 300px;
  background: #e8f1ec;
  padding: 20px;
  max-height: calc(100vh - 150px);
  overflow-y: auto;
  border-radius: 4px;
  border: 1px solid;
  border-image-source: linear-gradient(96.54deg, #FFFFFF -0.94%, rgba(255, 255, 255, 0) 25.28%, rgba(0, 143, 142, 0) 59.69%, #008F8E 79.76%);
  box-shadow: 1px 2px 5px 0px rgba(0, 102, 101, 0.25);

  box-shadow: -2px 4px 10px 0px rgba(145, 145, 145, 0.05);

  box-shadow: -7px 17px 18px 0px rgba(145, 145, 145, 0.04);

  box-shadow: -15px 37px 24px 0px rgba(145, 145, 145, 0.03);

  box-shadow: -27px 66px 29px 0px rgba(145, 145, 145, 0.01);

  box-shadow: -42px 103px 31px 0px rgba(145, 145, 145, 0);

  backdrop-filter: blur(3.4000000953674316px)
}

.leftSide .ant-tree-list {
  background: #e8f1ec;
}

.tree {
  background: #e8f1ec;
}

/* 树形结构标题 */
.treeTitle {
  font-size: 16px;
  font-weight: 500;
  margin-bottom: 16px;
  color: #333;
  padding-bottom: 8px;
  border-bottom: 1px solid #f0f0f0;
}

/* 树形结构样式 */
.tree {
  .ant-tree-treenode {
    margin-bottom: 4px;
  }

  .ant-tree-node-content-wrapper {
    padding: 4px 8px;
    border-radius: 4px;
    transition: all 0.2s;

    &:hover {
      background-color: #f0f7f7;
    }
  }

  .ant-tree-checkbox-checked .ant-tree-checkbox-inner {
    background-color: #006665;
    border-color: #006665;
  }

  .ant-tree-checkbox:hover .ant-tree-checkbox-inner {
    border-color: #006665;
  }

  .ant-tree-selected .ant-tree-node-content-wrapper {
    background-color: #f0f7f7;
    color: #006665;
    font-weight: 500;
  }
}

/* 右侧表格区域 */
.rightSide {
  flex: 1;
  background: white;
  padding: 20px;
  display: flex;
  flex-direction: column;
  transition: all 0.3s ease;
}

/* 当左侧树形结构隐藏时，右侧内容占据全部宽度 */
.contentContainer:only-child .rightSide,
.contentContainer>.rightSide:last-child {
  width: 100%;
}

/* 顶部按钮区域 */
.topButtons {
  display: flex;
  margin-bottom: 20px;
}

.delBtn {
  background-size: cover;
  background-position: center;
  color: #000;
  //opacity:0.7;
  border-radius: 4px;
  width: 88px;
  height: 36px;
}

/* 按钮样式 */
.button {
  border: none;
  // background-color: transparent;
  padding: 6px 16px;
  font-size: 14px;
  color: #fff;
  transition: all 0.3s;
  background-position: center;
  background-size: cover;
  height: 36px;

  &:hover {
    opacity: 0.9;
  }

  &.ant-btn-danger {
    color: #fff;
  }
}

/* 搜索区域 */
.searchContainer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
}

/* 搜索框样式 */
.searchBox {
  display: flex;
  align-items: center;
  border: 1px solid #d9d9d9;
  border-radius: 4px;
  padding: 0 12px;
  width: 300px;
  height: 36px;
  transition: all 0.3s;

  &:focus-within {
    border-color: #006665;
    box-shadow: 0 0 0 2px rgba(0, 102, 101, 0.1);
  }

  .anticon {
    color: #999;
    margin-right: 8px;
  }

  .searchInput {
    border: none;
    outline: none;
    flex: 1;
    height: 100%;
    font-size: 14px;

    &::placeholder {
      color: #bfbfbf;
    }
  }
}

/* 新增按钮 */
.addButton {
  background-color: #006665;
  border-color: #006665;
  border-radius: 4px;
  padding: 6px 20px;
  font-size: 14px;
  transition: all 0.3s;
  height: 36px;

  &:hover {
    background-color: #00876e;
    border-color: #00876e;
    transform: translateY(-1px);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.15);
  }
}

/* 表格样式 */
.table {
  margin-bottom: 20px;

  .ant-table-thead>tr>th {
    background-color: #f0f7f7;
    color: #333;
    font-weight: 500;
    border-bottom: 1px solid #e8e8e8;
    padding: 12px 16px;
  }

  .ant-table-tbody>tr>td {
    padding: 12px 16px;
    border-bottom: 1px solid #f0f0f0;

    &:last-child {
      padding-right: 24px;
    }
  }

  .ant-table-tbody>tr:hover {
    background-color: #fafafa;
  }

  /* 自定义序号列宽度 */
  .ant-table-column-has-actions {
    width: 80px;
  }
}

/* 分页区域 */
.pagination {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  margin-top: auto;
  padding-top: 20px;
  border-top: 1px solid #f0f0f0;

  >span {
    margin-right: 20px;
    color: #666;
    font-size: 14px;
  }

  .ant-pagination {
    display: flex;
    align-items: center;

    .ant-pagination-item-active {
      border-color: #006665;

      a {
        color: #006665;
        font-weight: 500;
      }
    }

    .ant-pagination-item:hover {
      border-color: #006665;

      a {
        color: #006665;
      }
    }

    .ant-pagination-prev:hover .ant-pagination-item-link,
    .ant-pagination-next:hover .ant-pagination-item-link {
      color: #006665;
      border-color: #006665;
    }
  }
}

/* 表单操作按钮区域 */
/* 新增巡检点表单样式 */
.addInspectionPointForm {
  background: #fff;
  padding: 24px;
  border-radius: 8px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
}

.formHeader {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 24px;
  padding-bottom: 16px;
  border-bottom: 1px solid #f0f0f0;

  h3 {
    margin: 0;
    font-size: 18px;
    font-weight: 500;
    color: #333;
  }
}

.formContent {
  width: 100%;
}

.formGroup {
  display: flex;
  align-items: center;
  margin-bottom: 20px;

  label {
    width: 120px;
    font-size: 14px;
    color: #333;
    text-align: right;
    margin-right: 16px;
  }

  input[type="text"],
  select {
    flex: 1;
    max-width: 400px;
    height: 36px;
    padding: 0 12px;
    border: 1px solid #d9d9d9;
    border-radius: 4px;
    font-size: 14px;
    transition: all 0.3s;

    &:focus {
      border-color: #1890ff;
      box-shadow: 0 0 0 2px rgba(24, 144, 255, 0.2);
      outline: none;
    }
  }
}

.checkboxGroup {
  flex: 1;
  max-width: 400px;
  display: flex;
  gap: 24px;
  margin-bottom: 12px;

  label {
    width: auto;
    text-align: left;
    margin-right: 8px;
    font-weight: normal;
    cursor: pointer;
  }
}

.deviceTagGroup {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 12px;
}

.deviceTag {
  display: inline-block;
  padding: 4px 12px;
  background-color: #f0f0f0;
  border-radius: 12px;
  font-size: 14px;
  cursor: pointer;
  transition: all 0.3s ease;

  &:hover {
    background-color: #e0e0e0;
    color: #1890ff;
  }
}

/* 响应式设计 */
@media (max-width: 1200px) {
  .contentContainer {
    flex-direction: column;
  }

  .leftSide {
    flex: none;
    max-height: 400px;
  }
}

/* 查询条件区域样式 */
.queryConditionContainer {
  background: #fff;
  // padding: 20px;
  // border-radius: 8px;
  // box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
  margin-bottom: 20px;
}

.queryConditionHeader {
  display: flex;
  align-items: center;
  margin-bottom: 20px;
  font-size: 16px;
  font-weight: 500;
  color: #333;
  justify-content: space-between;
}

.queryConditionIcon {
  margin-right: 8px;
}

/* 查询行布局 */
.queryRow {
  display: flex;
  margin-bottom: 16px;
  gap: 20px;
}

/* 查询列布局 */
.queryCol {
  flex: 1;
  display: flex;
  flex-direction: column;
}

/* 查询标签样式 */
.queryColLabel {
  font-size: 14px;
  color: #333;
  margin-bottom: 8px;
}

/* 查询输入框样式 */
.queryInput {
  width: 100%;
  max-width: 200px;
}

/* 查询选择器样式 */
.querySelect {
  width: 100%;
  max-width: 200px;
}

/* 查询日期范围样式 */
.queryDateRange {
  width: 100%;
  max-width: 280px;
}

/* 设备标签组样式 */
.deviceTags {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

/* 查询操作按钮区域 */
.queryActions {
  display: flex;
  justify-content: flex-end;
  gap: 12px;
  margin-top: 16px;
  padding-top: 16px;
  border-top: 1px solid #f0f0f0;
}

.queryButton {
  background-color: #006665;
  border-color: #006665;
}

.queryButton:hover {
  background-color: #00876e;
  border-color: #00876e;
}

/* 确保第一行四个查询项正确显示 */
.queryRow:first-of-type {
  .queryCol {
    flex: 1;
  }
}

/* 确保第二行两个查询项正确显示 */
.queryRow:last-of-type:not(:last-child) {
  .queryCol {
    flex: 1;
  }
}

@media (max-width: 1200px) {
  .queryRow {
    flex-wrap: wrap;
  }

  .queryCol {
    min-width: calc(50% - 10px);
  }
}

@media (max-width: 768px) {
  .container {
    padding: 10px;
  }

  .searchContainer {
    flex-direction: column;
    gap: 12px;
    align-items: stretch;
  }

  .searchBox {
    width: 100%;
  }

  .pagination {
    flex-direction: column;
    align-items: center;
    gap: 12px;
  }

  .queryRow {
    flex-direction: column;
  }

  .queryCol {
    min-width: 100%;
  }

  .queryInput,
  .querySelect,
  .queryDateRange {
    max-width: 100%;
  }
}