:root {
  --ink: #172026;
  --muted: #62727f;
  --line: #d7e0e7;
  --surface: #ffffff;
  --soft: #f4f7f9;
  --accent: #117c69;
  --accent-dark: #0b5f50;
  --warn: #a15c06;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--ink);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background:
    linear-gradient(180deg, rgba(17, 124, 105, 0.08), transparent 34rem),
    var(--soft);
}

.shell {
  width: min(980px, calc(100vw - 32px));
  margin: 0 auto;
  padding: 48px 0;
}

.workspace {
  display: grid;
  gap: 20px;
}

.topbar {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
}

h1 {
  margin: 0 0 8px;
  font-size: clamp(2rem, 5vw, 4rem);
  line-height: 0.95;
  letter-spacing: 0;
}

p {
  margin: 0;
  color: var(--muted);
  font-size: 1rem;
}

.status-pill {
  flex: 0 0 auto;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 8px 14px;
  color: var(--accent-dark);
  background: var(--surface);
  font-weight: 700;
}

.steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}

.step {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 56px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  color: var(--muted);
}

.step span {
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  color: var(--muted);
  background: var(--soft);
  font-weight: 800;
}

.step.active {
  border-color: rgba(17, 124, 105, 0.45);
  color: var(--ink);
  box-shadow: inset 0 0 0 1px rgba(17, 124, 105, 0.18);
}

.step.active span {
  color: white;
  background: var(--accent);
}

.panel {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  padding: 18px;
  box-shadow: 0 18px 55px rgba(32, 50, 61, 0.08);
}

.dropzone {
  min-height: 280px;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 12px;
  border: 2px dashed #aebcc6;
  border-radius: 8px;
  background: #fbfcfd;
  cursor: pointer;
  text-align: center;
  transition: border-color 160ms ease, background 160ms ease;
}

.dropzone:hover,
.dropzone.dragging {
  border-color: var(--accent);
  background: #f0faf7;
}

.dropzone input {
  position: absolute;
  inline-size: 1px;
  block-size: 1px;
  opacity: 0;
  pointer-events: none;
}

.upload-icon {
  display: grid;
  place-items: center;
  width: 64px;
  height: 64px;
  border-radius: 8px;
  background: #e5f4f0;
  color: var(--accent);
}

svg {
  width: 22px;
  height: 22px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.9;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.upload-icon svg {
  width: 34px;
  height: 34px;
}

.drop-title {
  font-size: 1.25rem;
  font-weight: 800;
}

.drop-subtitle {
  color: var(--muted);
}

.actions {
  display: flex;
  gap: 12px;
  margin-top: 16px;
  flex-wrap: wrap;
}

button,
.download {
  min-height: 46px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  border: 0;
  border-radius: 8px;
  padding: 0 18px;
  color: white;
  background: var(--accent);
  font: inherit;
  font-weight: 800;
  text-decoration: none;
  cursor: pointer;
}

button:hover,
.download:hover {
  background: var(--accent-dark);
}

button:disabled {
  cursor: not-allowed;
  color: #82919d;
  background: #d9e2e8;
}

.download {
  background: #263843;
}

.download.hidden {
  display: none;
}

.result {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  border: 1px solid rgba(17, 124, 105, 0.32);
  border-radius: 8px;
  padding: 16px;
  background: #effaf6;
}

.result strong {
  display: block;
  margin-bottom: 4px;
}

.error {
  color: #8b1e1e;
  border-color: rgba(139, 30, 30, 0.3);
  background: #fff1f1;
}

@media (max-width: 720px) {
  .shell {
    width: min(100% - 20px, 980px);
    padding: 24px 0;
  }

  .topbar,
  .actions {
    align-items: stretch;
    flex-direction: column;
  }

  .steps {
    grid-template-columns: 1fr;
  }

  .dropzone {
    min-height: 220px;
  }
}
