:root {
  --ink: #101820;
  --muted: #64707d;
  --line: #dfe6ee;
  --green: #20a35b;
  --green-dark: #147541;
  --red: #b42318;
  --soft: #f5f8fa;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* { box-sizing: border-box; }
body {
  margin: 0;
  color: var(--ink);
  background: linear-gradient(180deg, #ffffff 0%, #f7fafc 100%);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}
.site-header {
  height: 72px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 clamp(20px, 5vw, 64px);
  border-bottom: 1px solid var(--line);
  background: #fff;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  color: var(--ink);
  text-decoration: none;
  font-weight: 800;
  font-size: 22px;
}
.brand-mark {
  width: 40px;
  height: 40px;
  display: inline-grid;
  place-items: center;
  border-radius: 8px;
  overflow: hidden;
  background: #fff;
  border: 1px solid var(--line);
}
.brand-mark img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.header-note, .eyebrow { color: var(--muted); font-weight: 700; }
.shell {
  flex: 1;
  width: min(920px, calc(100% - 32px));
  margin: 48px auto;
}
.admin-shell { width: min(760px, calc(100% - 32px)); }
.panel {
  background: white;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: clamp(24px, 5vw, 44px);
  box-shadow: 0 18px 55px rgba(16, 24, 32, .08);
}
h1 {
  font-size: clamp(36px, 6vw, 64px);
  line-height: 1;
  margin: 10px 0 14px;
  letter-spacing: 0;
}
.lede {
  font-size: 19px;
  color: var(--muted);
  max-width: 640px;
  line-height: 1.55;
}
.status-line { min-height: 24px; color: var(--muted); font-weight: 700; }
.status-line.ok { color: var(--green-dark); }
.status-line.warn, .status-line.error { color: var(--red); }
.meta-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  margin: 28px 0;
}
.meta-grid div {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 14px;
  background: var(--soft);
}
.meta-grid span { display: block; color: var(--muted); font-size: 12px; text-transform: uppercase; font-weight: 800; }
.meta-grid strong { display: block; margin-top: 6px; overflow-wrap: anywhere; }
.drop-zone {
  display: grid;
  place-items: center;
  min-height: 260px;
  border: 2px dashed #aebbc8;
  border-radius: 8px;
  background: #fbfdfe;
  cursor: pointer;
  text-align: center;
  transition: border-color .15s ease, background .15s ease;
  padding: 28px;
}
.drop-zone.dragging {
  border-color: var(--green);
  background: #eefaf3;
}
.drop-zone input { display: none; }
.drop-icon {
  display: grid;
  place-items: center;
  width: 54px;
  height: 54px;
  border-radius: 50%;
  background: var(--green);
  color: white;
  font-size: 34px;
  margin-bottom: 14px;
}
.drop-zone strong { display: block; font-size: 28px; }
.drop-zone small { color: var(--muted); margin-top: 6px; }
.file-list { margin: 22px 0; display: grid; gap: 12px; }
.file-row {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 14px;
  background: white;
}
.file-row.done { border-color: rgba(32, 163, 91, .45); }
.file-row.failed { border-color: rgba(180, 35, 24, .45); }
.file-top { display: flex; justify-content: space-between; gap: 16px; margin-bottom: 10px; }
.file-top strong { overflow-wrap: anywhere; }
.file-top span, .file-row small { color: var(--muted); }
.progress {
  height: 10px;
  background: #e9eef3;
  border-radius: 999px;
  overflow: hidden;
}
.progress div {
  height: 100%;
  width: 0;
  background: var(--green);
}
.button {
  border: 0;
  border-radius: 8px;
  padding: 12px 18px;
  font-weight: 800;
  cursor: pointer;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.small-button {
  margin-top: 8px;
  font-size: 14px;
  padding: 9px 12px;
}
.primary { background: var(--green); color: white; }
.primary:hover { background: var(--green-dark); }
.secondary { background: var(--ink); color: white; }
.danger { background: var(--red); color: white; }
.closed {
  margin: 22px 0;
  border: 1px solid #f1b8b3;
  border-radius: 8px;
  padding: 18px;
  color: var(--red);
  background: #fff6f5;
  font-weight: 800;
}
.form-grid {
  display: grid;
  gap: 16px;
  margin-top: 24px;
}
label { display: grid; gap: 7px; font-weight: 800; }
input, textarea {
  width: 100%;
  border: 1px solid #b9c4cf;
  border-radius: 8px;
  padding: 12px 14px;
  font: inherit;
}
textarea { min-height: 96px; resize: vertical; }
.result { margin-top: 24px; display: grid; gap: 14px; }
footer {
  color: var(--muted);
  padding: 28px;
  text-align: center;
  border-top: 1px solid var(--line);
  background: #fff;
}
@media (max-width: 760px) {
  .site-header { height: 64px; }
  .header-note { display: none; }
  .shell { margin: 24px auto; }
  .meta-grid { grid-template-columns: 1fr; }
  h1 { font-size: 42px; }
  .file-top { display: grid; }
}
