:root {
  color-scheme: light;
  --ink: #18243a;
  --muted: #748097;
  --line: #e7eaf0;
  --paper: #ffffff;
  --canvas: #f5f7fb;
  --blue: #4268e8;
  --blue-dark: #3455cc;
  --mint: #e6f7f1;
  --green: #18866b;
  --red: #bd4d55;
  font-family: 'DM Sans', 'Segoe UI', sans-serif;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  color: var(--ink);
  background:
    radial-gradient(ellipse at 12% 2%, rgba(216, 228, 255, .53), transparent 34rem),
    var(--canvas);
  min-height: 100vh;
}

button, input { font: inherit; }
button { cursor: pointer; }
.hidden { display: none !important; }

.topbar {
  height: 76px;
  padding: 0 clamp(22px, 6vw, 88px);
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid rgba(226, 231, 240, .82);
  background: rgba(255, 255, 255, .64);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--ink);
  text-decoration: none;
  font: 800 17px 'Manrope', sans-serif;
  letter-spacing: -.7px;
}

.brand-mark {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  color: white;
  border-radius: 11px;
  background: linear-gradient(145deg, #718dfa, #4268e8);
  box-shadow: 0 5px 12px rgba(66, 104, 232, .24);
  font-size: 17px;
}

.brand-light { color: #78849b; font-weight: 500; }
.account-bar { display: flex; align-items: center; gap: 14px; }
.account-email { color: #66738a; font-size: 13px; }

main { width: min(1050px, calc(100% - 40px)); margin: 0 auto; }
.auth-layout {
  min-height: calc(100vh - 140px);
  display: grid;
  grid-template-columns: 1.15fr .85fr;
  align-items: center;
  gap: clamp(40px, 8vw, 100px);
  padding: 62px 0 76px;
}

.intro { max-width: 500px; padding-left: 10px; }
.eyebrow {
  display: flex;
  align-items: center;
  gap: 9px;
  color: #64728a;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .1em;
  text-transform: uppercase;
}

.eyebrow-dot { width: 7px; height: 7px; border-radius: 50%; background: #4ea88c; box-shadow: 0 0 0 4px #e2f5ee; }
h1, h2, p { margin-top: 0; }
h1 {
  margin: 21px 0 16px;
  font: 800 clamp(38px, 5vw, 57px)/1.12 'Manrope', sans-serif;
  letter-spacing: -2.7px;
}

.intro > p, .muted { color: var(--muted); line-height: 1.75; font-size: 16px; }
.intro-note {
  margin-top: 34px;
  display: flex;
  align-items: center;
  gap: 13px;
  max-width: 440px;
  color: #65728a;
  font-size: 13px;
  line-height: 1.6;
}

.note-icon {
  flex: 0 0 34px;
  height: 34px;
  display: grid;
  place-items: center;
  color: var(--blue);
  border-radius: 11px;
  background: #e9efff;
  font-weight: 700;
  font-size: 18px;
}

.card {
  border: 1px solid rgba(226, 231, 240, .9);
  border-radius: 18px;
  background: var(--paper);
  box-shadow: 0 15px 40px rgba(33, 54, 95, .055);
}

.auth-card { padding: 27px 29px 24px; }
.auth-tabs { display: flex; gap: 22px; border-bottom: 1px solid var(--line); margin-bottom: 24px; }
.auth-tab {
  padding: 0 0 13px;
  color: #8892a4;
  border: 0;
  border-bottom: 2px solid transparent;
  background: transparent;
  font-weight: 600;
  font-size: 14px;
}

.auth-tab.active { color: var(--blue); border-color: var(--blue); }
label:not(.drop-zone):not(.rights-check) { display: block; margin: 16px 0 8px; color: #39465d; font-size: 12px; font-weight: 700; }
input[type=email], input[type=password] {
  width: 100%;
  height: 46px;
  padding: 0 13px;
  outline: 0;
  border: 1px solid #e1e6ef;
  border-radius: 9px;
  color: var(--ink);
  background: #fff;
  transition: border .15s, box-shadow .15s;
}

input:focus { border-color: #9aafff; box-shadow: 0 0 0 3px rgba(66, 104, 232, .1); }
input::placeholder { color: #adb6c5; }
.field-hint { margin: 7px 0 0; color: var(--muted); font-size: 11px; }
.button {
  border: 0;
  border-radius: 9px;
  font-weight: 700;
  transition: transform .15s, background .15s;
}

.button:disabled { opacity: .62; cursor: wait; }
.button-primary {
  min-height: 44px;
  padding: 0 18px;
  color: white;
  background: var(--blue);
  box-shadow: 0 6px 14px rgba(66, 104, 232, .16);
}

.button-primary:hover:not(:disabled) { background: var(--blue-dark); transform: translateY(-1px); }
.button-primary span { padding-left: 8px; font-size: 17px; }
.button-wide { width: 100%; margin-top: 23px; }
.button-quiet { padding: 8px 11px; color: #67748b; background: transparent; font-size: 12px; }
.button-quiet:hover { color: var(--blue); background: #eef2ff; }
.message { min-height: 18px; margin: 11px 0 0; color: var(--red); font-size: 12px; line-height: 1.5; }
.message.success { color: var(--green); }
.privacy-note { margin: 14px 0 0; color: #929bad; text-align: center; font-size: 11px; }

.app-layout { padding: 53px 0 80px; }
.page-heading { margin-bottom: 27px; }
.page-heading h1 { margin: 13px 0 7px; font-size: clamp(32px, 4vw, 42px); letter-spacing: -1.7px; }
.page-heading p { margin-bottom: 0; font-size: 14px; }
.upload-card { padding: 26px 29px 19px; }
.section-title { display: flex; align-items: center; gap: 12px; margin-bottom: 19px; }
.section-icon { width: 39px; height: 39px; display: grid; place-items: center; border-radius: 12px; color: var(--blue); background: #edf1ff; font-size: 20px; font-weight: 700; }
.section-title h2, .jobs-heading h2 { margin: 0 0 4px; font: 700 16px 'Manrope', sans-serif; letter-spacing: -.3px; }
.section-title p, .jobs-heading p { margin: 0; color: var(--muted); font-size: 12px; }
.drop-zone {
  min-height: 147px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 5px;
  border: 1px dashed #cbd4e4;
  border-radius: 12px;
  background: #fafbfe;
  cursor: pointer;
  transition: border .15s, background .15s;
}

.drop-zone:hover, .drop-zone.dragging { border-color: var(--blue); background: #f6f8ff; }
.upload-symbol { width: 30px; height: 30px; display: grid; place-items: center; margin-bottom: 4px; border-radius: 9px; color: var(--blue); background: #e9efff; font-size: 20px; font-weight: 700; }
.drop-title { color: #334159; font-size: 13px; font-weight: 700; }
.drop-subtitle { color: #929bad; font-size: 11px; }
.selected-file { max-width: 90%; overflow: hidden; color: var(--green); font-size: 12px; text-overflow: ellipsis; white-space: nowrap; }
.drop-zone input { position: absolute; width: 1px; height: 1px; opacity: 0; }
.rights-check { display: flex; align-items: flex-start; gap: 10px; margin: 16px 0; color: #68758b; font-size: 11px; line-height: 1.55; cursor: pointer; }
.rights-check input { flex: 0 0 auto; margin: 2px 0 0; accent-color: var(--blue); }
.fine-print { display: flex; gap: 7px; margin-top: 13px; color: #909bad; font-size: 10px; }
.fine-print span { color: #5da38d; }

.jobs-section { margin-top: 37px; }
.jobs-heading { display: flex; align-items: center; justify-content: space-between; margin-bottom: 14px; }
.jobs-heading h2 { font-size: 18px; }
.jobs-list { display: grid; gap: 11px; }
.job-card { padding: 17px 19px; border: 1px solid var(--line); border-radius: 13px; background: white; box-shadow: 0 5px 16px rgba(33, 54, 95, .025); }
.job-top { display: flex; align-items: center; gap: 12px; }
.file-icon { width: 37px; height: 42px; display: grid; place-items: center; flex: 0 0 auto; border: 1px solid #e5e9f1; border-radius: 8px; color: #687896; background: #f9faff; font-size: 10px; font-weight: 800; }
.job-details { min-width: 0; flex: 1; }
.job-name { overflow: hidden; margin: 0 0 4px; color: #2a374e; font-size: 13px; font-weight: 700; text-overflow: ellipsis; white-space: nowrap; }
.job-meta { margin: 0; color: #8d98aa; font-size: 11px; }
.status { flex: 0 0 auto; display: inline-flex; align-items: center; gap: 6px; padding: 6px 9px; border-radius: 20px; color: #64728a; background: #f1f3f7; font-size: 10px; font-weight: 700; }
.status::before { width: 6px; height: 6px; border-radius: 50%; background: currentColor; content: ''; }
.status-running { color: #4767d8; background: #edf1ff; }
.status-running::before { animation: pulse 1.3s infinite; }
.status-completed { color: var(--green); background: var(--mint); }
.status-failed { color: var(--red); background: #fff0ef; }
.status-cancelled { color: #788397; background: #f0f2f5; }
.progress-line { height: 5px; overflow: hidden; margin: 14px 0 0 49px; border-radius: 4px; background: #edf0f5; }
.progress-fill { display: block; width: 100%; height: 5px; appearance: none; border: 0; background: transparent; }
.progress-fill::-webkit-progress-bar { border-radius: 4px; background: #edf0f5; }
.progress-fill::-webkit-progress-value { border-radius: 4px; background: linear-gradient(90deg, #5479ef, #6e8df2); transition: width .4s ease; }
.progress-fill::-moz-progress-bar { border-radius: 4px; background: linear-gradient(90deg, #5479ef, #6e8df2); }
.job-bottom { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin: 10px 0 0 49px; }
.job-progress-label { color: #8490a4; font-size: 10px; }
.job-actions { display: flex; align-items: center; gap: 5px; }
.job-actions button, .job-actions a { padding: 6px 9px; border: 0; border-radius: 7px; color: var(--blue); background: #f2f5ff; text-decoration: none; font-size: 10px; font-weight: 700; }
.job-actions button:hover, .job-actions a:hover { background: #e8edff; }
.job-error { margin: 11px 0 0 49px; color: var(--red); font-size: 11px; line-height: 1.5; }
.empty-state { min-height: 155px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 7px; border: 1px dashed #dce2ed; border-radius: 13px; color: #8b96a8; background: rgba(255,255,255,.55); font-size: 11px; }
.empty-state strong { color: #58667d; font-size: 13px; }
.empty-icon { margin-bottom: 3px; color: #9aa8bf; font-size: 25px; }
footer { width: min(1050px, calc(100% - 40px)); margin: 0 auto; display: flex; justify-content: space-between; padding: 18px 0 24px; border-top: 1px solid rgba(226, 231, 240, .75); color: #9aa4b4; font-size: 10px; }

@keyframes pulse { 50% { box-shadow: 0 0 0 4px rgba(71, 103, 216, .12); } }
@media (max-width: 760px) {
  .auth-layout { grid-template-columns: 1fr; gap: 30px; padding-top: 48px; }
  .intro { padding: 0; }
  .intro h1 { max-width: 460px; font-size: 42px; }
  .intro-note { margin-top: 19px; }
  .auth-card { max-width: 500px; width: 100%; }
}

@media (max-width: 520px) {
  .topbar { height: 65px; padding: 0 17px; }
  main, footer { width: calc(100% - 30px); }
  .account-email { display: none; }
  .intro h1 { font-size: 36px; letter-spacing: -1.7px; }
  .auth-card, .upload-card { padding-right: 19px; padding-left: 19px; }
  .app-layout { padding-top: 35px; }
  .job-card { padding: 14px 12px; }
  .status { font-size: 9px; padding: 5px 7px; }
  .progress-line, .job-bottom, .job-error { margin-left: 0; }
  .job-top { gap: 9px; }
  .job-bottom { align-items: flex-start; }
  footer { gap: 10px; font-size: 9px; }
}
