:root {
  --ink: #1d2928;
  --muted: #73807c;
  --line: #e3e9e5;
  --green: #176e51;
  --light: #f5f7f4;
  --sidebar: #172c28;
  --radius: 14px;
  font-family:
    Inter,
    Pretendard,
    "Noto Sans KR",
    system-ui,
    -apple-system,
    sans-serif;
  color: var(--ink);
  font-size: 14px;
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
  background: var(--light);
}
button,
input,
select {
  font: inherit;
}
button,
a,
input,
select {
  -webkit-tap-highlight-color: transparent;
}
button {
  cursor: pointer;
  transition:
    background 0.15s,
    box-shadow 0.15s;
}
button:disabled {
  opacity: 0.5;
  cursor: wait;
}
button:focus-visible,
a:focus-visible,
input:focus-visible,
select:focus-visible {
  outline: 3px solid #69b497;
  outline-offset: 3px;
}
a {
  color: var(--green);
}
[hidden] {
  display: none !important;
}
h1,
h2,
h3,
p {
  margin-top: 0;
}
h1 {
  font-size: 32px;
  letter-spacing: -1.4px;
  font-weight: 650;
  margin-bottom: 12px;
}
h2 {
  font-size: 17px;
  font-weight: 650;
  margin: 0;
}
h3 {
  font-size: 24px;
  line-height: 1.6;
  letter-spacing: -0.8px;
}
small {
  font-size: 12px;
}
.muted {
  color: var(--muted);
  line-height: 1.8;
}
.eyebrow {
  font-size: 10px;
  font-weight: 750;
  letter-spacing: 2px;
  color: var(--green);
  margin-bottom: 14px;
}
.sidebar {
  width: 238px;
  height: 100dvh;
  position: fixed;
  left: 0;
  top: 0;
  background: var(--sidebar);
  color: #e7f0eb;
  padding: 32px 22px;
  display: flex;
  flex-direction: column;
  z-index: 5;
}
.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  color: white;
  text-decoration: none;
  font-size: 18px;
  font-weight: 600;
  letter-spacing: -0.6px;
}
.brand-mark {
  display: inline-grid;
  place-items: center;
  background: #c5edb4;
  color: #204333;
  border-radius: 9px;
  width: 34px;
  height: 34px;
  font-weight: 800;
  font-size: 22px;
}
.workspace-label {
  font-size: 10px;
  letter-spacing: 2px;
  color: #7e9b90;
  margin: 55px 12px 18px;
}
.nav-button {
  display: flex;
  align-items: center;
  gap: 16px;
  text-align: left;
  width: 100%;
  padding: 15px 14px;
  border: 0;
  background: transparent;
  color: #9cb3aa;
  margin: 7px 0;
  border-radius: 8px;
  font-weight: 500;
}
.nav-button span {
  font-size: 10px;
  color: #729787;
}
.nav-button.active,
.nav-button:hover {
  background: #2d443c;
  color: #fff;
}
.nav-button.active span {
  color: #c5edb4;
}
.sidebar-note {
  margin-top: auto;
  padding: 20px 10px 27px;
  font-size: 12px;
  color: #c1d6cb;
  border-bottom: 1px solid #334b40;
}
.sidebar-note p {
  color: #79978a;
  font-size: 11px;
  line-height: 1.8;
  margin: 10px 0 0;
}
.online-dot {
  display: inline-block;
  width: 6px;
  height: 6px;
  background: #a8db99;
  border-radius: 50%;
  margin-right: 8px;
}
.account {
  padding-top: 23px;
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 12px;
}
.account small {
  display: block;
  color: #769185;
  font-size: 10px;
  margin-top: 4px;
}
.account button {
  margin-left: auto;
  border: 0;
  color: #9cb3aa;
  background: transparent;
  font-size: 10px;
}
.avatar {
  width: 31px;
  height: 31px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: #42584a;
}
.main {
  margin-left: 238px;
  padding: 0 48px;
  max-width: 1800px;
}
.topbar {
  height: 76px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid var(--line);
  font-size: 12px;
  color: var(--muted);
}
.topbar b {
  margin: 0 13px;
  color: #bcc5bf;
  font-weight: 400;
}
.environment {
  border: 1px solid #d4ded6;
  border-radius: 4px;
  font-size: 9px;
  letter-spacing: 1px;
  padding: 5px 8px;
  color: #79887e;
}
.page-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 43px 0 25px;
  gap: 20px;
}
.page-heading .muted {
  margin-bottom: 0;
}
.pill {
  white-space: nowrap;
  color: #587364;
  background: #eaf0e7;
  border: 1px solid #dde7d9;
  font-size: 11px;
  padding: 7px 12px;
  border-radius: 100px;
}
.workflow {
  display: flex;
  gap: 30px;
  padding: 23px 30px;
  border: 1px solid var(--line);
  background: #fff;
  border-radius: var(--radius);
  margin: 0 0 26px;
}
.workflow-step {
  display: flex;
  align-items: center;
  gap: 13px;
  flex: 1;
}
.workflow-step > span {
  border: 1px solid #dce3dc;
  border-radius: 50%;
  width: 30px;
  height: 30px;
  display: grid;
  place-items: center;
  font-size: 12px;
  color: #9bac9e;
}
.workflow-step.selected > span {
  color: white;
  background: var(--green);
  border-color: var(--green);
}
.workflow-step strong {
  font-size: 12px;
  font-weight: 600;
  display: block;
  margin-bottom: 5px;
}
.workflow-step small {
  font-size: 10px;
  color: var(--muted);
}
.workflow i {
  align-self: center;
  color: #b4c2b7;
  font-style: normal;
}
.request-grid {
  display: grid;
  grid-template-columns: 1.35fr 1fr;
  gap: 24px;
}
.panel {
  background: white;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 28px;
  margin-bottom: 24px;
  box-shadow: 0 2px 3px #182e2502;
}
.panel-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 27px;
}
.step-label {
  font-size: 9px;
  letter-spacing: 1px;
  color: #94a194;
}
label {
  display: block;
  font-size: 12px;
  font-weight: 550;
  margin-bottom: 21px;
}
input:not([type="radio"]):not([type="checkbox"]),
select {
  width: 100%;
  display: block;
  margin-top: 10px;
  padding: 12px 13px;
  background: white;
  border: 1px solid #dae2da;
  border-radius: 7px;
  color: var(--ink);
  min-height: 44px;
}
input[type="radio"],
input[type="checkbox"] {
  accent-color: var(--green);
  width: 16px;
  height: 16px;
}
.required {
  font-size: 10px;
  margin-left: 6px;
  color: var(--green);
}
.inline-actions {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin: -10px 0 25px;
  gap: 10px;
}
.inline-actions small {
  font-size: 10px;
}
.text-button {
  border: 0;
  background: transparent;
  color: var(--green);
  font-size: 11px;
  white-space: nowrap;
  padding: 4px;
}
fieldset {
  border: 0;
  padding: 0;
  margin: 0 0 20px;
}
legend {
  font-size: 12px;
  font-weight: 550;
  margin-bottom: 12px;
}
.radio-card {
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 14px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  margin-bottom: 10px;
  cursor: pointer;
}
.radio-card:has(input:checked) {
  border-color: #9cbaa8;
  background: #f7faf5;
}
.radio-card strong {
  display: block;
  font-size: 12px;
  margin-bottom: 5px;
}
.radio-card small {
  display: block;
  color: var(--muted);
  font-size: 10px;
  font-weight: 400;
}
.field-row {
  display: flex;
  gap: 16px;
}
.field-row > label {
  flex: 1;
}
.field-row small {
  color: #94a194;
  font-size: 10px;
}
.help {
  font-size: 11px;
  color: var(--muted);
  line-height: 1.9;
  margin: 0 0 20px;
}
.primary,
.secondary {
  display: inline-flex;
  justify-content: center;
  align-items: center;
  gap: 20px;
  border-radius: 7px;
  font-size: 12px;
  padding: 13px 19px;
  min-height: 44px;
  font-weight: 550;
  border: 1px solid transparent;
}
.primary {
  background: var(--green);
  color: white;
}
.primary:hover {
  background: #10573f;
}
.primary span {
  margin-left: auto;
  font-size: 17px;
}
form > .primary {
  width: 100%;
}
.secondary {
  background: white;
  color: var(--ink);
  border-color: #dbe2db;
}
.secondary:hover {
  background: #f2f6f0;
}
.ocr-panel {
  background: #edf2e9;
  padding: 28px 32px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}
.ocr-panel .panel-heading {
  width: 100%;
}
.ocr-symbol {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 80px;
  height: 85px;
  background: #fff;
  border-radius: 15px;
  border: 1px solid #dde5d8;
  color: #37634b;
  font-family: Georgia, serif;
  font-size: 38px;
  margin: 30px 0 25px;
  box-shadow: 0 12px 30px #44653b0a;
}
.ocr-symbol span {
  position: absolute;
  right: -12px;
  bottom: 5px;
  font-size: 20px;
  background: #c8dfa7;
  color: #3e6235;
  padding: 5px 9px;
  border-radius: 9px;
}
.ocr-panel .muted {
  font-size: 12px;
  max-width: 270px;
}
.feature-list {
  list-style: none;
  padding: 0;
  color: #66806c;
  font-size: 11px;
  line-height: 2.5;
  margin: 12px 0 35px;
}
.feature-list li:before {
  content: "✓";
  margin-right: 9px;
}
.ocr-panel > .secondary {
  margin-top: auto;
}
.table-scroll {
  overflow-x: auto;
}
table {
  border-collapse: collapse;
  width: 100%;
  font-size: 12px;
}
th {
  text-align: left;
  white-space: nowrap;
  font-weight: 500;
  color: #87948b;
  border-bottom: 1px solid var(--line);
  padding: 12px;
}
td {
  padding: 15px 12px;
  border-bottom: 1px solid #eef1ec;
  max-width: 380px;
  overflow-wrap: anywhere;
  line-height: 1.6;
}
tbody tr:last-child td {
  border-bottom: 0;
}
.panel-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 23px;
  gap: 20px;
}
.badge {
  font-size: 10px;
  border-radius: 5px;
  padding: 4px 7px;
  display: inline-block;
  background: #edf1ec;
  color: #65766a;
  white-space: nowrap;
}
.badge.running,
.badge.queued {
  background: #e5f0ed;
  color: #237d61;
}
.badge.completed,
.badge.complete,
.badge.done {
  background: #e6efd8;
  color: #53813c;
}
.badge.partial,
.badge.failed,
.badge.completed_with_errors {
  background: #fff1e3;
  color: #ae722d;
}
.stats-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  margin: 0 0 24px;
}
.stat {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 25px;
}
.stat small {
  display: block;
  color: var(--muted);
  font-size: 11px;
}
.stat strong {
  display: block;
  font-size: 29px;
  font-weight: 550;
  margin-top: 12px;
}
.run-actions {
  display: flex;
  gap: 4px;
  flex-wrap: wrap;
}
.run-actions button {
  font-size: 10px;
  padding: 5px 7px;
  background: white;
  border: 1px solid #dce4d9;
  border-radius: 4px;
  color: #47705a;
}
.progress {
  display: block;
  width: 100px;
  accent-color: var(--green);
  height: 5px;
  margin-top: 7px;
}
.library-toolbar {
  display: flex;
  gap: 24px;
  justify-content: space-between;
  align-items: end;
}
.library-toolbar label {
  flex: 1;
  max-width: 600px;
  margin: 0;
}
.empty-state {
  text-align: center;
  color: var(--muted);
  padding: 50px 15px;
  font-size: 12px;
}
.image-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(170px, 1fr));
  gap: 15px;
}
.image-card {
  border: 1px solid var(--line);
  border-radius: 9px;
  padding: 12px;
}
.image-card img {
  width: 100%;
  height: 180px;
  object-fit: cover;
  object-position: top;
  background: #f3f5f1;
  border-radius: 4px;
}
.image-card small {
  display: block;
  color: var(--muted);
  margin: 8px 0;
}
.image-card button {
  width: 100%;
  margin-top: 10px;
}
.result-card {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 20px;
  margin-top: 15px;
}
.result-card pre {
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  background: #f7f9f5;
  padding: 18px;
  font-size: 12px;
  line-height: 1.8;
  max-height: 500px;
  overflow-y: auto;
}
.result-card a {
  font-size: 11px;
}
.notice {
  position: sticky;
  top: 10px;
  background: #e5f1e8;
  border: 1px solid #b8d5bc;
  border-radius: 8px;
  padding: 15px 20px;
  margin-top: 15px;
  font-size: 12px;
  z-index: 10;
}
.notice.error {
  background: #fff0e9;
  border-color: #e8bfac;
  color: #955c41;
}
.main-footer {
  font-size: 9px;
  letter-spacing: 1.5px;
  color: #a2aca1;
  display: flex;
  justify-content: space-between;
  padding: 28px 0 36px;
}
.main-footer span {
  font-size: 10px;
  letter-spacing: 0;
}
.login-body {
  background: #172c28;
  min-height: 100dvh;
  display: grid;
  place-items: center;
  padding: 25px;
}
.login-card {
  background: #f8faf5;
  padding: 42px;
  border-radius: 18px;
  width: 420px;
  max-width: 100%;
  box-shadow: 0 20px 100px #07181160;
}
.login-card .brand-mark {
  margin-bottom: 33px;
  width: 43px;
  height: 43px;
}
.login-card .muted {
  font-size: 12px;
  margin-bottom: 28px;
}
.login-card footer {
  margin-top: 35px;
  font-size: 8px;
  letter-spacing: 1px;
  color: #93a28f;
}
.login-card #message {
  font-size: 12px;
  color: #a54a35;
  line-height: 1.6;
}
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
}
@media (min-width: 1600px) {
  .main {
    padding: 0 70px;
  }
  .request-grid {
    grid-template-columns: 1.4fr 1fr;
  }
  .ocr-panel {
    padding: 28px 45px;
  }
}
@media (max-width: 1100px) {
  .main {
    padding: 0 28px;
  }
  .sidebar {
    width: 200px;
    padding: 30px 15px;
  }
  .main {
    margin-left: 200px;
  }
  .request-grid {
    grid-template-columns: 1fr;
  }
  .ocr-panel {
    display: block;
  }
  .ocr-symbol {
    margin-top: 15px;
  }
  .workflow {
    padding: 20px;
    gap: 13px;
  }
  .workflow-step {
    gap: 7px;
  }
  .workflow-step small {
    font-size: 9px;
  }
}
@media (max-width: 700px) {
  .sidebar {
    position: static;
    width: auto;
    height: auto;
    padding: 17px 20px;
  }
  .sidebar .workspace-label,
  .sidebar-note,
  .account {
    display: none;
  }
  .sidebar nav {
    display: flex;
    gap: 5px;
    margin-top: 14px;
  }
  .nav-button {
    padding: 10px;
    font-size: 11px;
    gap: 8px;
  }
  .brand {
    font-size: 16px;
  }
  .brand-mark {
    width: 28px;
    height: 28px;
    font-size: 18px;
  }
  .main {
    margin-left: 0;
    padding: 0 18px;
  }
  .topbar {
    height: 50px;
  }
  .page-heading {
    padding: 28px 0 20px;
    align-items: start;
  }
  .page-heading .pill {
    display: none;
  }
  h1 {
    font-size: 27px;
  }
  .page-heading .muted {
    font-size: 12px;
  }
  .workflow {
    padding: 15px;
    gap: 8px;
  }
  .workflow-step {
    display: block;
  }
  .workflow-step > span {
    margin-bottom: 9px;
    width: 24px;
    height: 24px;
    font-size: 10px;
  }
  .workflow-step strong {
    font-size: 10px;
  }
  .workflow-step small {
    font-size: 8px;
  }
  .workflow i {
    display: none;
  }
  .panel {
    padding: 21px;
  }
  .library-toolbar,
  .panel-footer {
    flex-direction: column;
    align-items: stretch;
  }
  .library-toolbar label {
    width: 100%;
  }
  .stats-grid {
    gap: 10px;
  }
  .stat {
    padding: 17px;
  }
  .stat strong {
    font-size: 24px;
  }
  .main-footer span {
    display: none;
  }
  .image-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .field-row {
    gap: 10px;
  }
  .inline-actions small {
    font-size: 9px;
  }
}
.partial-toggle {
  display: flex;
  align-items: center;
  gap: 9px;
  color: var(--muted);
}
