.kfda-title {
  width: 100%;
  height: 679px;
  background: url(kfdaBg.png) no-repeat;
  background-size: 100% 100%;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  align-items: center;
  padding-top: 86px;
  box-sizing: border-box;
}
.kfda-title .kfda-title-img {
  width: 393px;
  height: 70px;
}
.kfda-search {
  margin-top: 140px;
  display: flex;
  flex-direction: row;
  align-items: center;
  width: 100%;
  justify-content: center;
}
.kfda-search .kfda-search-input {
  width: min(883px, 80vw);
  max-width: 883px;
  height: 80px;
  border-radius: 40px;
  padding: 30px 65px;
  box-sizing: border-box;
  background-color: transparent;
  background-image: radial-gradient(
    circle at right,
    transparent 50px,
    rgb(255, 255, 255) 50px
  );
  color: #004a99;
}
.kfda-search .kfda-search-input::input-placeholder {
  color: #004a99;
}
.kfda-search .kfda-search-icon {
  margin-left: -35px;
  width: 100px;
  height: 100px;
  flex-shrink: 0;
}

.kfda-list {
  width: calc(100% - 40px);
  max-width: 1200px;
  min-height: 500px;
  background-color: #f5faff;
  border-radius: 30px;
  margin: -180px auto 0;
  padding: 50px 30px;
  box-sizing: border-box;
  overflow-y: visible;
}

/* 使用弹性布局的表格样式 */
.flex-table {
  display: flex;
  flex-direction: column;
  width: 100%;
  min-width: 1000px;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
    "Helvetica Neue", Arial, sans-serif;
  overflow-x: auto;
}

.flex-table .table-header {
  display: flex;
  flex-direction: row;
  margin-bottom: 18px;
}

.flex-table .table-header .header-item {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 46px;
  background-color: #004a99; /* 深蓝色背景 */
  color: #ffffff; /* 白色字体 */
  font-weight: bold; /* 字体加粗 */
  text-align: center; /* 居中 */
  font-size: 14px; /* 字体大小 */
  border-radius: 23px;
  margin-right: 12px;
}

.flex-table .table-header .header-item:last-child {
  margin-right: 0;
}

.flex-table .table-row {
  display: flex;
  flex-direction: row;
  background-color: transparent;
}

.flex-table .table-row .row-item {
  color: #333333;
  font-size: 14px;
  line-height: 50px;
  text-align: center;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  margin-right: 12px;
}
.flex-table .table-row .row-item:last-child {
  margin-right: 0;
}

.flex-table .table-row .row-item a {
  color: #333333;
  text-decoration: none;
}

.flex-table .table-row .row-item a:hover {
  text-decoration: underline;
}

/* 固定列宽 */
.col-dh {
  flex: 0 0 160px;
  max-width: 160px;
} /* 档号 */
.col-tm {
  flex: 0 0 1fr;
  flex: 1;
  min-width: 200px;
  text-align: left;
  padding-left: 10px;
} /* 题名 - 自适应剩余空间 */
.col-wjbh {
  flex: 0 0 180px;
  max-width: 180px;
} /* 文件编号 */
.col-zrz {
  flex: 0 0 220px;
  max-width: 220px;
} /* 责任者 */
.col-wjsj {
  flex: 0 0 150px;
  max-width: 150px;
} /* 文件时间 */
.col-cz {
  flex: 0 0 80px;
  max-width: 80px;
} /* 操作 */

/* 分页容器 */
.kfda-pagination {
  display: flex;
  flex-direction: row;
  justify-content: center;
  align-items: center;
  margin-top: 20px;
  gap: 6px;
  font-size: 14px;
  color: #333;
  flex-wrap: wrap;
}
.kfda-pagination .page-btn {
  color: #333;
  text-decoration: none;
  padding: 4px 10px;
  border: 1px solid #ddd;
  border-radius: 4px;
  display: inline-block;
}
.kfda-pagination .page-btn.active {
  color: #fff;
  background: #004a99;
  border-color: #004a99;
}
.kfda-pagination .page-info {
  color: #999;
}

/* 媒体查询适配移动端 */
@media screen and (max-width: 768px) {
  .kfda-title {
    width: 100%;
    height: auto;
    aspect-ratio: 1920 / 679;
    padding-top: 40px;
  }

  .kfda-title .kfda-title-img {
    width: 250px;
    height: auto;
    max-width: 80vw;
  }

  .kfda-search {
    margin-top: 20px;
  }

  .kfda-search .kfda-search-input {
    width: min(460px, 70vw);
    height: 44px;
    padding: 20px 30px;
    font-size: 14px;
    border-radius: 22px;
  }

  .kfda-search .kfda-search-icon {
    width: 50px;
    height: 50px;
    margin-left: -30px;
  }

  /* 在移动端隐藏除档号和题名外的其他列 */
  .col-wjbh,
  .col-zrz,
  .col-wjsj{
    display: none !important;
  }

  .col-dh {
    flex: 0 0 calc(30% - 8px);
    max-width: calc(30% - 8px);
  }

  .col-tm {
    flex: 0 0 calc(55% - 8px);
    max-width: calc(55% - 8px);
  }

  .col-cz {
    flex: 0 0 calc(10% - 8px);
    max-width: calc(10% - 8px);
  }

  .flex-table .table-header .header-item {
    height: 36px;
    font-size: 12px;
    border-radius: 18px;
  }

  .flex-table .table-row .row-item {
    line-height: 40px;
    font-size: 12px;
  }

  .flex-table {
    min-width: auto;
  }

  .kfda-list {
    width: 95vw;
    padding: 30px 15px;
    margin: 0 auto 0;
    height: auto;
    min-height: 400px;
  }
}

/* 适配更小的屏幕 */
@media screen and (max-width: 480px) {
  .kfda-title {
    width: 100%;
    height: auto;
    aspect-ratio: 1920 / 679;
    padding-top: 20px;
  }

  .kfda-title .kfda-title-img {
    width: 200px;
    max-width: 70vw;
  }

  .kfda-search {
    margin-top: 20px;
  }

  .kfda-search .kfda-search-input {
    width: min(360px, 70vw);
    height: 36px;
    padding: 15px 40px;
    font-size: 14px;
    border-radius: 18px;
  }

  .kfda-search .kfda-search-icon {
    width: 40px;
    height: 40px;
    margin-left: -30px;
  }

  .col-wjbh,
  .col-zrz,
  .col-wjsj{
    display: none !important;
  }

  .col-dh {
    flex: 0 0 calc(28% - 8px);
    max-width: calc(28% - 8px);
    font-size: 12px;
  }

  .col-tm {
    flex: 0 0 calc(60% - 8px);
    max-width: calc(60% - 8px);
    font-size: 12px;
  }
  .col-cz {
    flex: 0 0 calc(12% - 8px);
    max-width: calc(12% - 8px);
    font-size: 12px;
  }

  .flex-table .table-header .header-item {
    height: 36px;
    font-size: 12px;
    border-radius: 18px;
  }

  .flex-table .table-row .row-item {
    line-height: 40px;
    font-size: 12px;
  }

  .kfda-list {
    width: 95vw;
    padding: 20px 10px;
    margin: 20px auto 0;
    height: auto;
    min-height: 300px;
  }
}

/* 平板横向适配 */
@media screen and (min-width: 769px) and (max-width: 1024px) {
  .kfda-title {
    width: 100%;
    height: auto;
    aspect-ratio: 1920 / 679;
    padding-top: 60px;
  }

  .kfda-title .kfda-title-img {
    width: 300px;
    height: auto;
  }

  .kfda-search {
    margin-top: 20px;
  }

  .kfda-search .kfda-search-input {
    width: min(560px, 75vw);
    height: 50px;
    padding: 25px 50px;
    font-size: 14px;
    border-radius: 25px;
  }

  .kfda-search .kfda-search-icon {
    width: 65px;
    height: 65px;
    margin-left: -30px;
  }

  .kfda-list {
    width: calc(100% - 40px);
    max-width: 1200px;
    min-height: 400px;
    padding: 40px 20px;
    margin: -100px auto 0;
    overflow-x: auto;
  }

  .flex-table {
    min-width: 800px;
  }
}

/* 宽屏桌面 (1200px+) 表格自适应满宽 */
@media screen and (min-width: 1200px) {
  .kfda-list {
    padding: 50px 40px;
    margin: -180px auto 0;
  }

  .col-dh { flex: 0 0 180px; max-width: 180px; }
  .col-tm { flex: 1; min-width: 200px; }
  .col-wjbh { flex: 0 0 200px; max-width: 200px; }
  .col-zrz { flex: 0 0 240px; max-width: 240px; }
  .col-wjsj { flex: 0 0 160px; max-width: 160px; }
  .col-cz { flex: 0 0 90px; max-width: 90px; }
}

/* 超大屏 (1600px+) 保持1200px容器居中 */
@media screen and (min-width: 1600px) {
  body {
    background: #fff;
  }
}