/* 蜘蛛大全 - 页面专属样式（公共样式一律用 /css/style.css，本文件只定义 sr- 前缀） */

/* ---------- 工具区容器 ---------- */
.sr-tool {
  background: #fff;
  border: 1px solid #e5e7eb;
  border-radius: 12px;
  padding: 20px;
  margin: 18px 0;
  box-shadow: 0 1px 3px rgba(0, 0, 0, .04);
}
.sr-stat-line {
  text-align: center;
  color: #6b7280;
  font-size: 14px;
  margin: 0 0 14px;
}
.sr-stat-line strong { color: var(--primary, #2563eb); }

/* ---------- Tab ---------- */
.sr-tabs {
  display: flex;
  gap: 8px;
  border-bottom: 1px solid #e5e7eb;
  margin-bottom: 16px;
  flex-wrap: wrap;
}
.sr-tab {
  appearance: none;
  background: none;
  border: none;
  border-bottom: 3px solid transparent;
  padding: 10px 14px;
  font-size: 15px;
  color: #6b7280;
  cursor: pointer;
  margin-bottom: -1px;
}
.sr-tab:hover { color: var(--primary, #2563eb); }
.sr-tab.active {
  color: var(--primary, #2563eb);
  border-bottom-color: var(--primary, #2563eb);
  font-weight: 600;
}

/* ---------- 表单 ---------- */
.sr-field { margin-bottom: 12px; }
.sr-field label {
  display: block;
  font-size: 14px;
  color: #374151;
  margin-bottom: 6px;
  font-weight: 600;
}
.sr-field textarea,
.sr-field input[type="text"] {
  width: 100%;
  box-sizing: border-box;
  border: 1px solid #d1d5db;
  border-radius: 8px;
  padding: 10px 12px;
  font-size: 14px;
  font-family: ui-monospace, SFMono-Regular, Consolas, "Courier New", monospace;
  color: #111827;
}
.sr-field textarea:focus,
.sr-field input[type="text"]:focus {
  outline: none;
  border-color: var(--primary, #2563eb);
  box-shadow: 0 0 0 3px rgba(37, 99, 235, .12);
}
.sr-inline {
  display: flex;
  gap: 10px;
  align-items: center;
  flex-wrap: wrap;
}
.sr-inline select {
  border: 1px solid #d1d5db;
  border-radius: 8px;
  padding: 8px 10px;
  font-size: 14px;
  background: #fff;
  color: #111827;
}
.sr-hint { font-size: 13px; color: #9ca3af; margin: 8px 0 0; }
.sr-error {
  color: #b91c1c;
  font-size: 14px;
  margin: 8px 0;
}

/* ---------- 判定徽章 ---------- */
.sr-badge {
  display: inline-block;
  padding: 6px 12px;
  border-radius: 999px;
  font-size: 14px;
  font-weight: 600;
}
.sr-badge.sr-ok   { background: #dcfce7; color: #15803d; }
.sr-badge.sr-bad  { background: #fee2e2; color: #b91c1c; }
.sr-badge.sr-warn { background: #fef3c7; color: #b45309; }
.sr-badge.sr-info { background: #dbeafe; color: #1d4ed8; }
.sr-badge.sr-mute { background: #f3f4f6; color: #6b7280; }

/* ---------- 识别结果卡片 ---------- */
.sr-card {
  border: 1px solid #e5e7eb;
  border-radius: 10px;
  padding: 14px;
  margin-top: 12px;
  background: #fafafa;
}
.sr-card-head {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 6px;
}
.sr-card-head strong { font-size: 16px; color: #111827; }
.sr-name-link { color: inherit; text-decoration: none; }
.sr-name-link:hover { color: var(--primary, #2563eb); text-decoration: underline; }
.sr-org { font-size: 13px; color: #6b7280; }
.sr-desc { font-size: 14px; color: #374151; margin: 4px 0; line-height: 1.7; }
.sr-token-line, .sr-ver-line { font-size: 13px; color: #6b7280; margin: 4px 0; }
.sr-ua-line {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  margin-top: 8px;
}
.sr-ua-line code {
  flex: 1;
  display: block;
  background: #eef2ff;
  border-radius: 6px;
  padding: 8px 10px;
  font-size: 12px;
  word-break: break-all;
  color: #3730a3;
}
code {
  font-family: ui-monospace, SFMono-Regular, Consolas, "Courier New", monospace;
}
/* 行内代码里的长命令/IP 在窄屏下必须可折行，否则会把页面撑出横向滚动 */
.info-section code, .faq-item code, .sr-reasons code, .sr-steps code {
  word-break: break-all;
}
.sr-card-foot { margin-top: 6px; }
.sr-doc { font-size: 13px; color: var(--primary, #2563eb); text-decoration: none; }
.sr-doc:hover { text-decoration: underline; }
.sr-reasons {
  margin-top: 12px;
  border: 1px solid #fecaca;
  background: #fef2f2;
  border-radius: 10px;
  padding: 10px 14px;
}
.sr-reasons p { margin: 4px 0; font-size: 14px; color: #991b1b; line-height: 1.7; }
.sr-loading { text-align: center; color: #6b7280; padding: 20px 0; }

/* ---------- 分类徽标 ---------- */
.sr-cat {
  display: inline-block;
  font-size: 12px;
  padding: 2px 8px;
  border-radius: 999px;
  background: #f3f4f6;
  color: #4b5563;
  white-space: nowrap;
}
.sr-cat[data-cat="search"]    { background: #dbeafe; color: #1d4ed8; }
.sr-cat[data-cat="aicrawl"]   { background: #ede9fe; color: #6d28d9; }
.sr-cat[data-cat="aisearch"]  { background: #e0e7ff; color: #4338ca; }
.sr-cat[data-cat="aiassist"]  { background: #fae8ff; color: #a21caf; }
.sr-cat[data-cat="seo"]       { background: #ffedd5; color: #c2410c; }
.sr-cat[data-cat="social"]    { background: #e0f2fe; color: #0369a1; }
.sr-cat[data-cat="webmaster"] { background: #ccfbf1; color: #0f766e; }
.sr-cat[data-cat="monitor"]   { background: #cffafe; color: #0e7490; }
.sr-cat[data-cat="archive"]   { background: #fef9c3; color: #a16207; }
.sr-cat[data-cat="security"]  { background: #fee2e2; color: #b91c1c; }
.sr-cat[data-cat="client"]    { background: #e5e7eb; color: #374151; }

/* ---------- IP 校验结果 ---------- */
.sr-verdict { margin-top: 12px; }
.sr-claimed { font-size: 13px; color: #6b7280; margin: 8px 0 0; }
.sr-steps {
  border: 1px solid #e5e7eb;
  border-radius: 10px;
  padding: 12px 14px;
  margin-top: 12px;
  background: #f9fafb;
}
.sr-steps h4, .sr-ipadvice h4 {
  margin: 0 0 8px;
  font-size: 14px;
  color: #111827;
}
.sr-steps p {
  margin: 6px 0;
  font-size: 13px;
  color: #4b5563;
  line-height: 1.7;
  padding-left: 14px;
  position: relative;
}
.sr-steps p::before {
  content: "";
  position: absolute;
  left: 0;
  top: 9px;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--primary, #2563eb);
  opacity: .5;
}
.sr-ipadvice {
  border: 1px solid #bfdbfe;
  background: #eff6ff;
  border-radius: 10px;
  padding: 12px 14px;
  margin-top: 12px;
}
.sr-ipadvice p { margin: 0; font-size: 14px; color: #1e40af; line-height: 1.8; }

/* ---------- 蜘蛛大全列表 ---------- */
.sr-list-bar {
  display: flex;
  gap: 10px;
  margin-bottom: 12px;
  flex-wrap: wrap;
  align-items: center;
}
.sr-list-bar input[type="text"] {
  flex: 1;
  min-width: 220px;
  border: 1px solid #d1d5db;
  border-radius: 8px;
  padding: 9px 12px;
  font-size: 14px;
}
.sr-list-bar input[type="text"]:focus {
  outline: none;
  border-color: var(--primary, #2563eb);
  box-shadow: 0 0 0 3px rgba(37, 99, 235, .12);
}
.sr-count { font-size: 13px; color: #6b7280; white-space: nowrap; }
.sr-chips {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 12px;
}
.sr-chip {
  appearance: none;
  border: 1px solid #d1d5db;
  background: #fff;
  border-radius: 999px;
  padding: 5px 12px;
  font-size: 13px;
  color: #4b5563;
  cursor: pointer;
}
.sr-chip em {
  font-style: normal;
  font-size: 11px;
  color: #9ca3af;
  margin-left: 4px;
}
.sr-chip:hover { border-color: var(--primary, #2563eb); color: var(--primary, #2563eb); }
.sr-chip.active {
  background: var(--primary, #2563eb);
  border-color: var(--primary, #2563eb);
  color: #fff;
}
.sr-chip.active em { color: rgba(255, 255, 255, .75); }

.sr-table-wrap { overflow-x: auto; }
.sr-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
}
.sr-table th, .sr-table td {
  border: 1px solid #e5e7eb;
  padding: 8px 10px;
  text-align: left;
  vertical-align: top;
  line-height: 1.6;
}
.sr-table th {
  background: #f3f4f6;
  color: #374151;
  white-space: nowrap;
  position: sticky;
  top: 0;
}
.sr-table tbody tr:nth-child(even) { background: #fafafa; }
.sr-table tbody tr:hover { background: #eff6ff; }
.sr-td-name { white-space: nowrap; }
.sr-td-ua code {
  display: block;
  max-width: 340px;
  word-break: break-all;
  font-size: 12px;
  color: #3730a3;
}
.sr-td-desc { color: #4b5563; min-width: 220px; }
.sr-td-act { white-space: nowrap; }
.sr-td-act .btn { margin: 2px 4px 2px 0; }

/* ---------- 说明区 ---------- */
.sr-steps-grid { gap: 14px; }
.sr-step-num {
  display: inline-block;
  width: 26px;
  height: 26px;
  line-height: 26px;
  text-align: center;
  border-radius: 50%;
  background: var(--primary, #2563eb);
  color: #fff;
  font-size: 14px;
  margin-right: 6px;
}

/* ---------- 实时识别记录面板 ---------- */
.sr-feed {
  margin-top: 18px;
  border-top: 1px dashed #e5e7eb;
  padding-top: 12px;
}
.sr-feed-h {
  font-size: 14px;
  color: #374151;
  margin: 0 0 8px;
}
.sr-feed-list {
  list-style: none;
  margin: 0;
  padding: 0;
}
.sr-feed-list li {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 5px 0;
  font-size: 13px;
  color: #6b7280;
}
.sr-feed-list li .sr-badge {
  flex: none;
  padding: 3px 9px;
  font-size: 12px;
}
.sr-feed-txt { flex: 1; min-width: 0; }
.sr-feed-txt code {
  background: #f3f4f6;
  border-radius: 4px;
  padding: 1px 6px;
  font-size: 12px;
  color: #374151;
}
.sr-feed-txt strong { color: #111827; }
.sr-feed-txt a.sr-name-link {
  text-decoration: underline;
  text-decoration-color: #c7d2fe;
  text-underline-offset: 3px;
}
.sr-feed-txt a.sr-name-link:hover { text-decoration-color: currentColor; }
.sr-feed-list time {
  flex: none;
  color: #9ca3af;
  font-size: 12px;
  white-space: nowrap;
}
.sr-feed-empty {
  color: #9ca3af;
  justify-content: center;
  padding: 10px 0 !important;
}

/* ---------- 响应式 ---------- */
@media (max-width: 640px) {
  .sr-tool { padding: 14px; }
  .sr-tab { padding: 8px 10px; font-size: 14px; }
  .sr-ua-line { flex-direction: column; }
  .sr-ua-line .btn { align-self: flex-end; }
  .sr-td-ua code { max-width: 200px; }
}
