/* free-ai-tools 公共样式(深色现代风) */
:root {
  --bg: #0b0d12;
  --bg-soft: #141821;
  --card: #171c26;
  --line: #262d3a;
  --text: #e7ecf3;
  --muted: #93a0b4;
  --accent: #6ea8fe;
  --accent-2: #9b8cff;
  --ok: #4ade80;
  --radius: 14px;
  --maxw: 980px;
}
* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  background: radial-gradient(1200px 600px at 50% -10%, #1a2030 0%, var(--bg) 55%);
  color: var(--text);
  font: 15px/1.6 -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  min-height: 100vh;
}
a { color: var(--accent); text-decoration: none; }
.wrap { max-width: var(--maxw); margin: 0 auto; padding: 24px 20px 80px; }

/* header */
.topbar { display: flex; align-items: center; justify-content: space-between; margin-bottom: 28px; }
.brand { display: flex; align-items: center; gap: 10px; font-weight: 700; letter-spacing: .2px; }
.brand .dot { width: 10px; height: 10px; border-radius: 50%; background: linear-gradient(135deg, var(--accent), var(--accent-2)); }
.badge {
  font-size: 12px; color: var(--muted); border: 1px solid var(--line);
  padding: 5px 10px; border-radius: 999px; background: var(--bg-soft);
}
.badge.ok { color: var(--ok); border-color: #21402f; }

/* headings */
h1 { font-size: 26px; margin: 6px 0 6px; }
.sub { color: var(--muted); margin: 0 0 22px; }

/* card */
.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; }

/* dropzone */
.dropzone {
  border: 1.5px dashed var(--line); border-radius: var(--radius);
  padding: 40px 20px; text-align: center; cursor: pointer;
  transition: .15s; background: var(--bg-soft); color: var(--muted);
}
.dropzone:hover, .dropzone.dragover { border-color: var(--accent); color: var(--text); background: #1a2030; }
.dropzone strong { color: var(--text); }
.hint { font-size: 13px; color: var(--muted); margin-top: 8px; }

/* buttons */
.row { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; margin-top: 16px; }
.btn {
  border: 1px solid var(--line); background: var(--bg-soft); color: var(--text);
  padding: 10px 16px; border-radius: 10px; cursor: pointer; font-size: 14px; font-weight: 600;
  transition: .15s;
}
.btn:hover { border-color: var(--accent); }
.btn:disabled { opacity: .45; cursor: not-allowed; }
.btn-primary { background: linear-gradient(135deg, var(--accent), var(--accent-2)); border: none; color: #0b0d12; }
.btn-ghost { background: transparent; }

/* progress */
.progress { margin-top: 16px; display: none; }
.progress.show { display: block; }
.bar { height: 8px; background: var(--bg-soft); border-radius: 999px; overflow: hidden; border: 1px solid var(--line); }
.bar > i { display: block; height: 100%; width: 0; background: linear-gradient(90deg, var(--accent), var(--accent-2)); transition: width .2s; }
.progress .ptext { font-size: 13px; color: var(--muted); margin-top: 8px; }

/* results */
.compare { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-top: 20px; }
@media (max-width: 700px) { .compare { grid-template-columns: 1fr; } }
.pane { border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; background: var(--bg-soft); }
.pane .label { font-size: 12px; color: var(--muted); padding: 8px 12px; border-bottom: 1px solid var(--line); }
.canvas-wrap { display: flex; align-items: center; justify-content: center; min-height: 220px; padding: 12px; }
.canvas-wrap img, .canvas-wrap canvas { max-width: 100%; max-height: 420px; border-radius: 8px; display: block; }
/* 透明棋盘格(去背景结果) */
.checker { background-image:
  linear-gradient(45deg, #2a2f3a 25%, transparent 25%), linear-gradient(-45deg, #2a2f3a 25%, transparent 25%),
  linear-gradient(45deg, transparent 75%, #2a2f3a 75%), linear-gradient(-45deg, transparent 75%, #2a2f3a 75%);
  background-size: 18px 18px; background-position: 0 0, 0 9px, 9px -9px, -9px 0px; }

/* error */
.error { display:none; margin-top: 16px; color: #fca5a5; font-size: 14px; background:#2a1620; border:1px solid #4a2530; padding:12px; border-radius:10px; }
.error.show { display:block; }

/* CTA + notes */
.cta { margin-top: 22px; padding: 16px 18px; border-radius: var(--radius);
  background: linear-gradient(135deg, #1a2440, #221c3a); border: 1px solid #2c3550; }
.cta b { color: #fff; }
.note { margin-top: 18px; font-size: 12.5px; color: var(--muted); }
.note code { background: var(--bg-soft); padding: 1px 6px; border-radius: 5px; border: 1px solid var(--line); }
.privacy { display:inline-flex; align-items:center; gap:6px; color: var(--ok); font-size: 13px; }

/* home grid */
.tools { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin-top: 8px; }
@media (max-width: 820px) { .tools { grid-template-columns: 1fr; } }
.tool-card { display:block; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; transition: .15s; }
.tool-card:hover { border-color: var(--accent); transform: translateY(-2px); }
.tool-card .ico { font-size: 30px; }
.tool-card h3 { margin: 12px 0 6px; color: var(--text); font-size: 17px; }
.tool-card p { margin: 0; color: var(--muted); font-size: 13.5px; }
.tool-card .tag { display:inline-block; margin-top:12px; font-size:11.5px; color:var(--ok); border:1px solid #21402f; border-radius:999px; padding:3px 9px; }
.feature-row { display:flex; gap:16px; flex-wrap:wrap; margin: 18px 0 26px; color: var(--muted); font-size: 13.5px; }
.feature-row span { display:inline-flex; align-items:center; gap:6px; }
