:root {
  --bg: #fff5fb;
  --bg-raised: #ffffff;
  --bg-hover: #ffe6f6;
  --border: rgba(242, 61, 184, 0.14);
  --border-strong: rgba(242, 61, 184, 0.3);
  --text: #1c1218;
  --text-dim: #7a5a6a;
  --accent: #f23db8;
  --accent-dim: #d92a9e;
  --neg: #c0392b;
  --font: "DM Sans", system-ui, sans-serif;
  --radius: 16px;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  scrollbar-width: thin;
  scrollbar-color: var(--border-strong) transparent;
}

html,
body {
  min-height: 100%;
  background:
    radial-gradient(120% 90% at 50% 0%, #ffe0f3 0%, #fff5fb 55%, #ffffff 100%);
  color: var(--text);
  font-family: var(--font);
  font-size: 14px;
}

::selection {
  background: var(--accent);
  color: #fff;
}

.page {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 20px 64px;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}
.job-page {
  max-width: 720px;
}

/* ---- shared site header ---- */
.topbar {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px 16px;
  padding: 22px 0 16px;
  border-bottom: 1px solid var(--border);
  margin-bottom: 28px;
}

.brand {
  font-size: 19px;
  font-weight: 700;
  letter-spacing: -0.01em;
  color: var(--accent);
  text-decoration: none;
}

.tagline {
  color: var(--text-dim);
  font-size: 12.5px;
  flex: 1;
  min-width: 140px;
}

.topnav {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  margin-left: auto;
}

.nav-link {
  background: linear-gradient(180deg, #ff4ec4 0%, var(--accent) 55%, var(--accent-dim) 100%);
  color: #fff;
  font-size: 12.5px;
  font-weight: 600;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  border: 1px solid rgba(255, 255, 255, 0.55);
  border-radius: 999px;
  padding: 7px 16px;
  box-shadow: 0 8px 20px rgba(242, 61, 184, 0.22);
  transition: filter 0.15s;
}
.nav-link:hover {
  filter: brightness(1.05);
  color: #fff;
}
.nav-link-active,
.nav-link-active:hover {
  background: #fff;
  color: var(--accent-dim);
  border-color: var(--border-strong);
  box-shadow: none;
  cursor: default;
}

.intro {
  max-width: 640px;
  margin-bottom: 18px;
}
.intro .eyebrow {
  display: inline-block;
  color: var(--accent);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin-bottom: 8px;
}

h1 {
  font-size: 28px;
  font-weight: 700;
  letter-spacing: -0.03em;
  margin-bottom: 10px;
}

.sub {
  color: var(--text-dim);
  font-size: 14.5px;
  line-height: 1.6;
}

.stat-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 0 0 22px;
}

.stat-pill {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 10px 16px;
  display: flex;
  align-items: baseline;
  gap: 8px;
  box-shadow: 0 6px 18px rgba(242, 61, 184, 0.06);
}
.stat-pill strong {
  color: var(--accent);
  font-size: 18px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}
.stat-pill span {
  color: var(--text-dim);
  font-size: 12px;
}

.upload-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(260px, 320px);
  gap: 18px;
  align-items: start;
}

.upload-column {
  min-width: 0;
}

.card {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 22px;
  box-shadow: 0 14px 40px rgba(242, 61, 184, 0.07);
}

textarea {
  width: 100%;
  min-height: 220px;
  resize: vertical;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 12px;
  color: var(--text);
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 12.5px;
  line-height: 1.7;
  padding: 14px;
  outline: none;
}
textarea:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(242, 61, 184, 0.12);
}
textarea.dragover {
  border-color: var(--accent);
  background: #fff0f8;
}
textarea::placeholder {
  color: var(--text-dim);
  opacity: 0.65;
}

.note-field {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  margin: 16px 2px 8px;
  color: var(--text-dim);
  font-size: 12px;
  font-weight: 500;
}
.note-count {
  font-variant-numeric: tabular-nums;
}
.note-input {
  width: 100%;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 10px;
  color: var(--text);
  font: inherit;
  font-size: 13px;
  padding: 11px 13px;
  outline: none;
}
.note-input:focus {
  border-color: var(--accent);
}

.row {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-top: 16px;
  flex-wrap: wrap;
}

.count {
  color: var(--text-dim);
  font-size: 13px;
}
.count strong {
  color: var(--text);
  font-weight: 600;
}
.count.over strong {
  color: var(--neg);
}

.btn {
  border: none;
  border-radius: 999px;
  padding: 11px 26px;
  font-family: var(--font);
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  background: var(--accent);
  color: #fff;
  text-decoration: none;
  display: inline-block;
  transition: filter 0.15s, background 0.15s;
}
.btn:hover {
  filter: brightness(1.05);
  color: #fff;
}
.btn:disabled {
  background: #f3d7e8;
  color: #fff;
  opacity: 0.85;
  cursor: default;
  filter: none;
}

.btn.ghost {
  background: #fff;
  color: var(--accent);
  border: 1px solid var(--border-strong);
}
.btn.ghost:hover {
  background: var(--bg-hover);
  color: var(--accent-dim);
}

.file-label {
  color: var(--accent);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  border: 1px solid var(--border-strong);
  background: #fff;
  border-radius: 999px;
  padding: 10px 18px;
}
.file-label:hover {
  background: var(--bg-hover);
}
.file-label input {
  display: none;
}

.spacer {
  flex: 1;
}

.error {
  margin-top: 16px;
  color: var(--neg);
  font-size: 13px;
}

.notes {
  margin-top: 22px;
  color: var(--text-dim);
  font-size: 12.5px;
  line-height: 1.9;
}
.notes li {
  margin-left: 18px;
}

/* ---- recent side panel (white / pink) ---- */
.side-card {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 18px;
  position: sticky;
  top: 16px;
  box-shadow: 0 14px 40px rgba(242, 61, 184, 0.07);
}

.side-card h2 {
  font-size: 16px;
  margin-top: 4px;
  color: var(--text);
}

.eyebrow {
  color: var(--accent);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.11em;
  text-transform: uppercase;
}

.side-card-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 14px;
}

.activity-pulse {
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: var(--accent);
  box-shadow: 0 0 0 4px rgba(242, 61, 184, 0.15);
  animation: pulse 2s ease-in-out infinite;
}

@keyframes pulse {
  0%,
  100% {
    opacity: 1;
  }
  50% {
    opacity: 0.45;
  }
}

.recent-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  max-height: 520px;
  overflow-y: auto;
}

.recent-item {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 12px;
}

.recent-item-top {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 8px;
}
.recent-item-top strong {
  font-size: 12.5px;
  font-weight: 600;
  color: var(--text);
}
.recent-item-top > span {
  color: var(--text-dim);
  font-size: 11px;
  white-space: nowrap;
}

.recent-item p {
  color: var(--text-dim);
  font-size: 12px;
  line-height: 1.4;
  margin: 7px 0;
  overflow-wrap: anywhere;
}

.recent-status {
  display: flex;
  align-items: center;
  gap: 6px;
  color: var(--text-dim);
  font-size: 11px;
  font-weight: 600;
}
.recent-status > span:first-child {
  width: 6px;
  height: 6px;
  border-radius: 999px;
  background: #c4a0b4;
}
.recent-status.done {
  color: var(--accent-dim);
}
.recent-status.done > span:first-child,
.recent-status.processing > span:first-child {
  background: var(--accent);
}
.recent-status.processing > span:first-child {
  animation: pulse 1.2s ease-in-out infinite;
}

.recent-empty {
  color: var(--text-dim);
  font-size: 13px;
  line-height: 1.5;
  padding: 18px 4px;
}

.live-log {
  display: none;
}

/* job page bits */
.status-line {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 600;
}
.dot {
  width: 10px;
  height: 10px;
  border-radius: 999px;
  background: var(--accent);
}
.progress {
  margin-top: 16px;
  height: 8px;
  background: var(--bg);
  border-radius: 999px;
  overflow: hidden;
  border: 1px solid var(--border);
}
.progress-fill {
  height: 100%;
  width: 0;
  background: var(--accent);
  border-radius: 999px;
  transition: width 0.3s ease;
}
.progress-label {
  margin-top: 10px;
  color: var(--text-dim);
  font-size: 13px;
}

@media (max-width: 860px) {
  .upload-grid {
    grid-template-columns: 1fr;
  }
  .side-card {
    position: static;
  }
  .tagline {
    display: none;
  }
}
