/* ========== 全局 ========== */
body {
  margin: 0;
  font-family: "Segoe UI", Arial, sans-serif;
  background: linear-gradient(135deg, #f5f6f9, #eef3f9);
  color: #333;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

/* ========== 工单管理：筛选 / 分组 / 分页 / 统计 ========== */
.filters {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin: 8px 0 16px;
  padding: 12px;
  background: rgba(255, 255, 255, 0.65);
  border-radius: 10px;
  box-shadow: 0 3px 10px rgba(0,0,0,.05);
  backdrop-filter: blur(8px);
}
.filter-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}
.filters input[type="text"],
.filters input[type="date"],
.filters select {
  min-width: 140px;
  flex: 1 1 180px;
  height: 34px;
  padding: 4px 10px;
  font-size: 14px;
  border: 1px solid #cfd4dc;
  border-radius: 6px;
  background: #fff;
  box-sizing: border-box;
  transition: all .25s ease;
}
.filters input[type="text"]::placeholder { color: #a0a7b5; }
.filters input:hover,
.filters select:hover {
  background: #f2f6fc;
}
.filters input:focus,
.filters select:focus {
  outline: none;
  border-color: #2563eb;
  background: #f9fbff;
  box-shadow: 0 0 0 3px rgba(37,99,235,.15);
}

/* 顶部统计条 */
#list-stats {
  margin: 6px 0 14px;
  padding: 10px 14px;
  font-size: 13px;
  color: #0e3862;
  background: linear-gradient(90deg, #f8f9fb, #eef4fb);
  border: 1px solid #dce3eb;
  border-radius: 8px;
  box-shadow: inset 0 1px 3px rgba(0,0,0,.05);
}

/* 分组容器 */
#group-container { display: none; }
#group-container section {
  margin: 16px 0;
  padding: 16px;
  background: #fff;
  border: 1px solid #e5e7eb;
  border-radius: 12px;
  box-shadow: 0 3px 6px rgba(0,0,0,.08);
  transition: all .3s ease;
}
#group-container section:hover {
  box-shadow: 0 6px 16px rgba(0,0,0,.12);
  transform: translateY(-2px);
}
#group-container h3 {
  margin: 0 0 10px;
  font-size: 16px;
  font-weight: 600;
  color: #0e3862;
  border-left: 4px solid #ffd166;
  padding-left: 8px;
}

/* 分页区 */
#pager {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  margin-top: 18px;
}
#page-info {
  font-size: 13px;
  color: #444;
  font-weight: 500;
  background: #f9fafc;
  padding: 5px 12px;
  border-radius: 6px;
  border: 1px solid #e0e6ef;
  box-shadow: inset 0 1px 2px rgba(0,0,0,.05);
}

/* 表头粘滞 */
.data-table thead th {
  position: sticky;
  top: 0;
  z-index: 1;
  background: linear-gradient(to bottom, #f0f4fa, #e2e8f0);
  box-shadow: inset 0 -2px 0 #d0d7e0;
}

/* 顶部导航栏 */
.topbar {
  background: linear-gradient(90deg, #0a2342 0%, #0e3862 40%, #1a4d80 70%, #2d6fb3 100%);
  color: #fff;
  padding: 14px 24px;
  font-size: 20px;
  font-weight: bold;
  text-shadow: 0 2px 4px rgba(0,0,0,.35);
  box-shadow: 0 4px 12px rgba(0,0,0,0.35);
  border-bottom: 2px solid #133252;
  letter-spacing: .5px;
}

/* 页面布局 */
.layout {
  display: flex;
  min-height: calc(100vh - 60px);
}

/* 左侧菜单 */
.sidebar {
  width: 200px;
  background: linear-gradient(180deg, #e5e7eb, #f3f4f6);
  color: #333;
  box-shadow: inset -1px 0 0 #d1d5db;
}
.sidebar ul { list-style: none; padding: 0; margin: 0; }
.sidebar li {
  padding: 12px 18px;
  cursor: pointer;
  transition: all .25s ease;
  border-bottom: 1px solid #e5e7eb;
}
.sidebar li:hover { background: #17436e; color: #fff; }
.sidebar .active {
  background: linear-gradient(90deg, #0e3862, #245a93);
  color: #fff;
  font-weight: 600;
  box-shadow: inset 4px 0 0 #ffd166;
}
.sidebar a { display: block; color: inherit; text-decoration: none; }

/* 主体内容 */
.content {
  flex: 1;
  background: #fff;
  margin: 20px;
  padding: 20px;
  border-radius: 12px;
  box-shadow: 0 4px 14px rgba(0,0,0,0.15);
  overflow-y: auto;
  border-top: 4px solid #0e3862;
  transition: all .3s ease;
  max-width: 1200px;
}
.content:hover {
  box-shadow: 0 6px 14px rgba(0,0,0,0.2);
}

/* 按钮 */
.btn-group { margin-bottom: 20px; }
button {
  margin-right: 8px;
  padding: 7px 16px;
  border: none;
  border-radius: 6px;
  font-size: 14px;
  cursor: pointer;
  transition: all .25s ease;
}
button.primary {
  background: linear-gradient(135deg, #0e3862, #1f5c94);
  color: #fff;
}
button.primary:hover {
  background: linear-gradient(135deg, #154472, #2564a1);
  box-shadow: 0 4px 12px rgba(14,56,98,.35);
  transform: translateY(-1px) scale(1.02);
}
button.secondary {
  background: #f0f0f0;
  color: #333;
}
button.secondary:hover {
  background: #e2e8f0;
  color: #0e3862;
  transform: translateY(-1px);
}
button:focus-visible { outline: 2px solid #0e3862; outline-offset: 2px; }
button:disabled { opacity: .6; cursor: not-allowed; }

/* 表格 */
.data-table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 12px;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 2px 6px rgba(0,0,0,.05);
}
.data-table th, .data-table td {
  border: 1px solid #e0e6ef;
  padding: 8px;
  text-align: center;
  min-width: 120px;   /* ✅ 防止竖排，保证可横向滚动 */
  white-space: nowrap;
}
.data-table th {
  background: linear-gradient(to bottom, #f0f4fa, #e2e8f0);
  color: #0e3862;
  font-weight: 600;
}
.data-table tr:nth-child(even) { background: #fafafa; }
.data-table tr:hover {
  background: #f0f6ff;
  box-shadow: inset 0 0 0 2px rgba(14,56,98,.1);
  transition: all .2s ease;
}

/* 输出框 */
pre {
  margin-top: 20px;
  background: linear-gradient(90deg, #f8f9fa, #eef3f9);
  padding: 12px;
  border-radius: 8px;
  font-size: 13px;
  border: 1px solid #d0d7e0;
  color: #0e3862;
  white-space: pre-wrap;
  word-break: break-word;
  box-shadow: inset 0 1px 3px rgba(0,0,0,.05);
}

/* ========== 报修填写表单 ========== */
.form-hero { margin: 6px 0 16px; text-align: center; }
.hero-title {
  font-size: 26px;
  font-weight: 700;
  background: linear-gradient(90deg, #0e3862, #1e4f84);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  letter-spacing: .4px;
}
.repair-form { margin-top: 12px; }
.repair-form--pill .pill-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: 6px;
}
.pill-field { position: relative; min-width: 0; }
.pill-input {
  width: 100%;
  height: 34px;
  border-radius: 6px;
  border: 1px solid #cfd4dc;
  background: #fff;
  padding: 0 10px;
  font-size: 14px;
  box-sizing: border-box;
  transition: all .25s ease;
}
.pill-input::placeholder { color: #9aa0a6; }
.pill-input:hover { background: #f2f6fc; }
.pill-input:focus {
  border-color: #2563eb;
  background: #f9fbff;
  box-shadow: 0 0 0 3px rgba(37,99,235,.15);
}
.repair-form--pill .pill-row-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

/* 底部状态栏 */
.status-bar {
  margin-top: 16px;
  padding: 8px 12px;
  border-radius: 6px;
  background: #f8f9fa;
  border: 1px solid #e0e0e0;
  font-size: 13px;
  color: #333;
  display: flex;
  align-items: center;
  gap: 6px;
  box-shadow: inset 0 1px 2px rgba(0,0,0,0.05);
}
.status-bar .status-icon { font-size: 14px; }
.status-bar .status-text { flex: 1; }

/* 提交/重置 */
.pill-actions {
  display: flex;
  gap: 10px;
  margin-top: 14px;
  padding-top: 10px;
  border-top: 1px dashed #cfd4dc;
}

/* PC 端隐藏顶部按钮组 */
@media (min-width: 769px) {
  .btn-group {
    display: none !important;
  }
}