/* ==========================================================
   wyq.lol 公共样式
   ========================================================== */

* { margin: 0; padding: 0; box-sizing: border-box; }

:root {
  --bg: #0b0d10;
  --card: rgba(255,255,255,0.025);
  --card-hover: rgba(255,255,255,0.05);
  --line: rgba(255,255,255,0.08);
  --line-hover: rgba(52,211,153,0.4);
  --text: #e6e8ec;
  --text-dim: #9aa0ab;
  --text-faint: #6b7280;
  --green: #34d399;
  --green-soft: #6ee7b7;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
    "PingFang SC", "Microsoft YaHei", sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.65;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  background:
    radial-gradient(800px 480px at 15% 0%, rgba(52,211,153,0.05), transparent 60%),
    radial-gradient(700px 480px at 100% 100%, rgba(52,211,153,0.035), transparent 60%);
}

/* ===== 页面容器 ===== */
.wrap {
  max-width: 720px;
  margin: 0 auto;
  padding: 72px 24px 80px;
}

/* ===== 头部 ===== */
.head { margin-bottom: 36px; }

.back {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 0.82rem;
  color: var(--text-faint);
  text-decoration: none;
  margin-bottom: 20px;
  transition: color .2s ease;
}
.back:hover { color: var(--green); }
.back::before { content: "←"; }

.head h1 {
  font-size: 1.4rem;
  font-weight: 600;
  margin-bottom: 8px;
}
.head p {
  color: var(--text-dim);
  font-size: 0.92rem;
}

/* ===== 区块标题 ===== */
.section + .section { margin-top: 48px; }

.section-title {
  font-size: 0.78rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-faint);
  margin-bottom: 18px;
}

/* ===== 网格 ===== */
.grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 14px;
}

/* ===== 卡片 ===== */
.card {
  display: flex;
  flex-direction: column;
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--card);
  text-decoration: none;
  color: inherit;
  cursor: pointer;
  transition: border-color .22s ease, background .22s ease, transform .22s ease;
}
.card:hover {
  border-color: var(--line-hover);
  background: var(--card-hover);
  transform: translateY(-2px);
}
.card h3 {
  font-size: 1rem;
  font-weight: 600;
  margin-bottom: 8px;
}
.card p {
  font-size: 0.84rem;
  color: var(--text-dim);
  line-height: 1.55;
  margin-bottom: 18px;
  flex: 1;
}
.card .go {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--green);
  margin-top: auto;
}
.card .go::after {
  content: "→";
  transition: transform .2s ease;
}
.card:hover .go::after { transform: translateX(3px); }

/* ===== 按钮 ===== */
button {
  padding: 9px 16px;
  border: 1px solid var(--green);
  background: var(--green);
  color: #06281c;
  border-radius: 6px;
  font-size: 0.88rem;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  white-space: nowrap;
  transition: opacity .2s ease;
}
button:hover { opacity: .88; }
button:disabled { opacity: .4; cursor: not-allowed; }

button.ghost {
  background: transparent;
  color: var(--text-dim);
  border-color: var(--line);
}
button.ghost:hover {
  color: var(--text);
  border-color: var(--text-faint);
  opacity: 1;
}

/* ===== 表单 ===== */
input[type=text] {
  flex: 1;
  min-width: 0;
  padding: 9px 12px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: rgba(0,0,0,0.2);
  color: var(--text);
  font-size: 0.9rem;
  font-family: inherit;
  outline: none;
  transition: border-color .2s ease;
}
input[type=text]:focus { border-color: var(--green); }
input[type=text]::placeholder { color: var(--text-faint); }

/* ===== 面板 ===== */
.panel {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 20px;
}
.panel h2 {
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-faint);
  margin-bottom: 16px;
}

/* ===== 文件选择 ===== */
.file-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 9px 16px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: rgba(0,0,0,0.2);
  color: var(--text-dim);
  cursor: pointer;
  font-size: 0.88rem;
  transition: all .2s ease;
}
.file-btn:hover {
  color: var(--text);
  border-color: var(--text-faint);
}
.file-btn input { display: none; }

/* ===== 结果框 ===== */
.result {
  margin-top: 16px;
  padding: 14px;
  background: rgba(0,0,0,0.2);
  border: 1px solid var(--line);
  border-radius: 8px;
  min-height: 60px;
}
.result-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 6px;
}
.result .label {
  font-size: 0.72rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-faint);
}
.result .value {
  font-family: Consolas, "Courier New", monospace;
  font-size: 0.85rem;
  color: var(--green-soft);
  word-break: break-all;
  line-height: 1.55;
}
.result .empty { color: var(--text-faint); font-size: 0.85rem; }
.result .error { color: #f87171; font-size: 0.85rem; }

/* ===== 复制按钮 ===== */
.copy-btn {
  padding: 3px 10px;
  font-size: 0.75rem;
  font-weight: 500;
  border-radius: 5px;
  border: 1px solid var(--line);
  background: transparent;
  color: var(--text-dim);
  cursor: pointer;
  transition: all .2s ease;
  display: none;
}
.copy-btn.show { display: inline-block; }
.copy-btn:hover {
  color: var(--green);
  border-color: var(--green);
  opacity: 1;
}
.copy-btn.copied {
  color: var(--green);
  border-color: var(--green);
}

/* ===== 页脚 ===== */
footer {
  margin-top: 64px;
  text-align: center;
  color: var(--text-faint);
  font-size: 0.78rem;
}

/* ===== 响应式 ===== */
@media (max-width: 600px) {
  .wrap { padding: 48px 18px 64px; }
  .grid { grid-template-columns: 1fr; }
  .section + .section { margin-top: 40px; }
}
/* 卡片状态灯 */
.card { position: relative; }

.status-dot {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--text-faint);
  transition: background .3s ease, box-shadow .3s ease;
}
.status-dot.checking { animation: pulse 1.2s ease-in-out infinite; }
.status-dot.ok {
  background: var(--green);
  box-shadow: 0 0 8px rgba(52,211,153,.6);
}
.status-dot.down {
  background: #f87171;
  box-shadow: 0 0 8px rgba(248,113,113,.6);
}
@keyframes pulse {
  0%, 100% { opacity: .4; }
  50% { opacity: 1; }
}
/* 服务状态文字行 */
.service-status {
  margin-top: 8px;
  font-size: 0.84rem;
  line-height: 1.55;
  color: var(--text-faint);
}
.service-status.ok { color: var(--green-soft); }
.service-status.down { color: #f87171; }