* { box-sizing: border-box; margin: 0; padding: 0; }
body {
  background: #0e1117;
  color: #fafafa;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.5;
  padding: 24px 16px 60px;
}
.wrap { max-width: 720px; margin: 0 auto; }
header { text-align: center; margin-bottom: 24px; }
h1 { font-size: 1.6rem; margin-bottom: 6px; }
.sub { color: #9aa4b2; font-size: 0.92rem; }
.card {
  background: #1a1e2e;
  border: 1px solid #2a2e3e;
  border-radius: 14px;
  padding: 20px;
  margin-bottom: 20px;
}
.file-drop {
  display: flex; align-items: center; justify-content: center;
  min-height: 120px;
  border: 2px dashed #3a4152;
  border-radius: 12px;
  color: #9aa4b2;
  cursor: pointer;
  text-align: center;
  padding: 16px;
  transition: border-color .15s, background .15s;
}
.file-drop.drag, .file-drop:hover { border-color: #1f77b4; background: #161b2b; }
.file-drop.has-file { color: #fafafa; border-color: #1f77b4; }
.presets {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin: 16px 0;
}
.preset-btn {
  background: #232838;
  border: 1px solid #2a2e3e;
  border-radius: 10px;
  color: #fafafa;
  padding: 12px 10px;
  font-size: 0.9rem;
  cursor: pointer;
  transition: all .15s;
}
.preset-btn:hover { border-color: #1f77b4; }
.preset-btn.active { background: #1f77b4; border-color: #1f77b4; font-weight: 600; }
.go {
  display: block;
  width: 100%;
  background: #1f77b4;
  color: #fff;
  border: none;
  border-radius: 10px;
  padding: 13px;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  text-align: center;
  text-decoration: none;
}
.go:disabled { background: #2a2e3e; color: #6b7280; cursor: not-allowed; }
.go.loading { opacity: .7; cursor: progress; }
.hint { color: #6b7280; font-size: 0.8rem; margin-top: 10px; text-align: center; }
.err { color: #f87171; font-size: 0.88rem; margin-top: 10px; text-align: center; }
.compare {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-bottom: 16px;
}
.compare figure { display: flex; flex-direction: column; gap: 6px; }
.compare figcaption { color: #9aa4b2; font-size: 0.82rem; text-align: center; }
.compare img { width: 100%; border-radius: 10px; background: #0e1117; }
@media (max-width: 480px) {
  .presets { grid-template-columns: 1fr; }
  .compare { grid-template-columns: 1fr; }
}
