:root {
  --bg: #f7f7f7;
  --panel: #ffffff;
  --text: #111111;
  --muted: #666666;
  --border: #e2e2e2;
  --primary: #111111;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: "Manrope", system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
}

.page {
  max-width: 760px;
  margin: 42px auto;
  padding: 0 16px 42px;
}

h1 {
  margin: 0 0 16px;
  font-size: 2rem;
}

.card-form,
.panel {
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 14px;
}

.panel {
  margin-top: 12px;
}

#progressContainer {
  padding: 10px 12px;
}

.step-indicator {
  display: none;
}

.step {
  width: 30px;
  height: 30px;
  border-radius: 999px;
  border: 1px solid var(--border);
  display: grid;
  place-items: center;
  color: var(--muted);
  font-size: 0.85rem;
}

.step.active {
  background: var(--primary);
  color: #fff;
  border-color: var(--primary);
}

form {
  display: grid;
  gap: 8px;
}

label {
  font-size: 0.9rem;
  color: var(--muted);
}

input,
select,
button {
  width: 100%;
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 10px 12px;
  font-size: 0.95rem;
  background: #fff;
}

.actions {
  margin-top: 6px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

button {
  border: none;
  cursor: pointer;
  background: var(--primary);
  color: #fff;
  font-weight: 600;
}

button:disabled,
input:disabled,
select:disabled {
  opacity: 0.55;
  cursor: not-allowed;
}

#readOnlineBtn {
  background: #333;
}

.progress {
  width: 100%;
  background: #ececec;
  border-radius: 999px;
  overflow: hidden;
  height: 8px;
}

#progressBar {
  width: 0%;
  height: 100%;
  background: #111;
  transition: width 0.18s ease;
}

#loadingText,
#loadingSubtext,
#progressPercentage,
#progressPlaceholder {
  display: none !important;
}

.reader-controls {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 8px;
  align-items: center;
  margin-bottom: 8px;
}

#pageImage,
#pdfCanvas {
  width: 100%;
  max-height: 78vh;
  object-fit: contain;
}
