﻿:root {
  --bg: #f6f7f8;
  --surface: #ffffff;
  --surface-soft: #fbfbfc;
  --text: #101114;
  --muted: #5f636b;
  --line: rgba(16, 17, 20, 0.1);
  --line-strong: rgba(16, 17, 20, 0.2);
  --shadow: 0 6px 22px rgba(17, 17, 17, 0.06);
  --accent: #0f1720;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  color: var(--text);
  background:
    radial-gradient(circle at 12% 12%, rgba(0, 0, 0, 0.05), transparent 26%),
    radial-gradient(circle at 90% 92%, rgba(0, 0, 0, 0.04), transparent 22%),
    var(--bg);
}

.page-shell {
  width: min(980px, 92vw);
  margin: 34px auto;
  display: grid;
  gap: 18px;
}

.hero-card,
.form-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 22px;
  box-shadow: var(--shadow);
}

.hero-card {
  padding: 26px 28px;
}

.hero-topline {
  display: inline-flex;
  align-items: center;
  height: 28px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--surface-soft);
  padding: 0 12px;
  font-size: 12px;
  font-weight: 600;
  color: #3d4148;
}

h1 {
  margin: 10px 0 0;
  letter-spacing: -0.02em;
  font-size: clamp(1.4rem, 2.8vw, 2rem);
}

p {
  margin: 10px 0 0;
  color: var(--muted);
  line-height: 1.6;
}

code {
  background: #f0f2f4;
  border: 1px solid #e3e6ea;
  border-radius: 8px;
  padding: 2px 6px;
}

.form-card {
  padding: 22px;
}

.alert {
  border: 1px solid rgba(167, 44, 44, 0.28);
  border-radius: 12px;
  background: #fff5f5;
  color: #912c2c;
  padding: 10px 12px;
  margin-bottom: 14px;
}

.field-block {
  margin-bottom: 18px;
}

.field-title {
  display: block;
  font-size: 14px;
  font-weight: 700;
  margin-bottom: 9px;
}

.dropzone {
  position: relative;
  border: 1px dashed var(--line-strong);
  background: linear-gradient(180deg, #ffffff, #fafbfc);
  border-radius: 18px;
  min-height: 220px;
  padding: 20px;
  display: grid;
  place-items: center;
  text-align: center;
  cursor: pointer;
  transition: border-color 0.2s ease, background 0.2s ease, transform 0.2s ease;
}

.dropzone:hover,
.dropzone.is-dragover {
  border-color: #111;
  background: #f7f8fa;
  transform: translateY(-1px);
}

.dropzone input[type="file"] {
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: pointer;
}

.dropzone-main {
  font-size: 18px;
  font-weight: 700;
  letter-spacing: -0.01em;
}

.dropzone-sub {
  margin-top: 8px;
  color: var(--muted);
  font-size: 13px;
}

.file-summary {
  margin-top: 14px;
  padding: 8px 12px;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: #fff;
  color: #42464f;
  font-size: 12px;
  width: min(100%, 680px);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.option-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 10px;
}

.option-grid label {
  display: flex;
  align-items: center;
  gap: 8px;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 10px 12px;
  background: #fff;
}

.submit-btn {
  margin-top: 6px;
  width: 100%;
  border: 1px solid #111;
  border-radius: 14px;
  padding: 12px 14px;
  font-size: 15px;
  font-weight: 700;
  color: #fff;
  background: #111;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  transition: transform 0.2s ease, opacity 0.2s ease;
}

.submit-btn:hover {
  opacity: 0.95;
}

.submit-btn:active {
  transform: scale(0.99);
}

.icon {
  width: 18px;
  height: 18px;
}

.result-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 14px;
}

.action-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 10px 12px;
  color: var(--text);
  text-decoration: none;
  background: #fff;
  cursor: pointer;
}

.action-btn.solid {
  color: #fff;
  border-color: #111;
  background: #111;
}

.result-table {
  width: 100%;
  border-collapse: collapse;
  border: 1px solid var(--line);
  border-radius: 14px;
  overflow: hidden;
}

.result-table th,
.result-table td {
  text-align: left;
  padding: 10px 12px;
  border-bottom: 1px solid var(--line);
}

.result-table th {
  background: #f4f6f8;
}

.download-link {
  color: #111;
  font-weight: 700;
  text-decoration: none;
}

@media (max-width: 640px) {
  .page-shell {
    width: 94vw;
    margin: 18px auto 30px;
  }

  .hero-card,
  .form-card {
    border-radius: 16px;
    padding: 16px;
  }

  .dropzone {
    min-height: 180px;
    padding: 14px;
  }

  .dropzone-main {
    font-size: 16px;
  }

  .result-table th,
  .result-table td {
    font-size: 13px;
  }
}
