.pdf-tool {
  background: linear-gradient(155deg, #f9faff 0%, #f4f3ff 48%, #fafbff 100%);
  min-height: calc(100vh - 76px);
  padding: 26px 0 72px;
}
.pdf-tool [hidden] {
  display: none !important;
}
.pdf-tool .shell {
  max-width: 1240px;
}
.pt-topline {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}
.pt-back {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 600;
  min-height: 44px;
  text-decoration: none;
}
.pt-back span {
  font-size: 22px;
}
.pt-tools {
  display: flex;
  gap: 4px;
  background: #fff;
  border: 1px solid var(--line);
  padding: 5px;
  border-radius: 13px;
}
.pt-tools a {
  display: flex;
  gap: 8px;
  align-items: center;
  padding: 9px 17px;
  text-decoration: none;
  color: var(--text);
  font-size: 13px;
  font-weight: 600;
  border-radius: 9px;
  min-height: 44px;
}
.pt-tools a[aria-current] {
  background: var(--primary);
  color: #fff;
  box-shadow: 0 3px 9px #4c38ff24;
}
.pt-tools .icon {
  width: 17px;
  height: 17px;
}
.pt-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  margin: 32px 0 30px;
}
.pt-eyebrow {
  color: #6355a7;
  font-size: 10px;
  letter-spacing: 1.35px;
  font-weight: 750;
}
.pt-heading h1 {
  font-size: clamp(34px, 4vw, 48px);
  letter-spacing: -2px;
  line-height: 1.1;
  margin: 9px 0 12px;
  font-weight: 800;
}
.pt-dot {
  color: var(--primary);
}
.pt-heading p {
  margin: 0;
  font-size: 15px;
  color: var(--muted);
}
.pt-steps {
  display: flex;
  list-style: none;
  padding: 0;
  margin: 0;
  gap: 22px;
  flex-shrink: 0;
}
.pt-steps li {
  display: flex;
  align-items: center;
  gap: 8px;
  color: #65708b;
  font-size: 11px;
  white-space: nowrap;
}
.pt-steps span {
  border: 1px solid #d5d9eb;
  background: #fff;
  border-radius: 50%;
  width: 27px;
  height: 27px;
  display: grid;
  place-items: center;
  font-size: 12px;
  font-weight: 700;
}
.pt-steps li[aria-current] {
  color: var(--primary);
  font-weight: 700;
}
.pt-steps li[aria-current] span,
.pt-steps li.is-done span {
  background: var(--primary);
  color: #fff;
  border-color: var(--primary);
}
.pt-error {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  background: #fff2f3;
  border: 1px solid #efc6cd;
  color: #922c3e;
  border-radius: 12px;
  padding: 14px 16px;
  margin: 0 0 20px;
  overflow-wrap: anywhere;
}
.pt-error > .icon {
  flex-shrink: 0;
  margin-top: 9px;
}
.pt-error [data-error-text] {
  flex: 1;
  padding: 7px 0;
}
.pt-error .pt-icon-button {
  color: inherit;
}
.pt-sr {
  position: absolute !important;
  width: 1px;
  height: 1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}
.pt-dropzone {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  background: #fff;
  border: 1.5px dashed #bcb5f3;
  border-radius: 23px;
  padding: 42px 24px 28px;
  box-shadow: 0 18px 65px #40377c07;
  transition:
    border-color 0.2s,
    background 0.2s;
}
.pt-dropzone.is-dragover {
  border-color: var(--primary);
  background: #f0edff;
  outline: 4px solid #4c38ff18;
}
.pt-dropzone h2 {
  font-size: 24px;
  letter-spacing: -0.7px;
  margin: 20px 0 6px;
}
.pt-dropzone > p {
  color: var(--muted);
  font-size: 14px;
  margin: 0 0 24px;
}
.pt-paper-art {
  height: 96px;
  width: 122px;
  position: relative;
  margin-top: 0;
}
.pt-paper-front,
.pt-paper-back {
  position: absolute;
  border: 1px solid #d9d4f5;
  border-radius: 10px;
  background: #fff;
  width: 66px;
  height: 86px;
  left: 34px;
  top: 5px;
  box-shadow: 0 6px 15px #48369410;
}
.pt-paper-back {
  transform: rotate(-17deg);
  left: 20px;
  background: #eeebff;
  top: 1px;
}
.pt-paper-front {
  transform: rotate(8deg);
  padding: 13px 11px;
}
.pt-paper-front > span {
  font-size: 10px;
  font-weight: 800;
  color: var(--primary);
  display: block;
  line-height: 1;
  margin-bottom: 10px;
}
.pt-paper-front i {
  display: block;
  background: #dbd5f4;
  height: 3px;
  margin: 5px 0;
  border-radius: 2px;
}
.pt-paper-front i:last-of-type {
  width: 70%;
}
.pt-paper-front b {
  display: grid;
  place-items: center;
  position: absolute;
  right: -16px;
  bottom: -8px;
  width: 36px;
  height: 36px;
  border-radius: 11px;
  background: var(--primary);
  color: #fff;
  border: 3px solid #fff;
  transform: rotate(-8deg);
}
.pt-paper-front .icon {
  width: 18px;
  height: 18px;
}
.pt-spark {
  position: absolute;
  right: -2px;
  top: -8px;
  color: #afa3ff;
  font-size: 23px;
}
.pt-select {
  min-height: 54px;
  min-width: 230px;
  justify-content: center;
  gap: 11px;
  border: 0;
}
.pt-select > span {
  font-size: 23px;
  font-weight: 400;
  margin-left: 9px;
}
.pt-drop-hint {
  font-size: 13px;
  color: var(--muted);
  margin: 12px 0 26px;
}
.pt-limit {
  font-size: 11px;
  color: var(--muted);
}
.pt-assurances {
  display: flex;
  justify-content: center;
  gap: 38px;
  margin: 24px 0 14px;
}
.pt-assurances span {
  display: flex;
  gap: 8px;
  align-items: center;
  font-size: 12px;
  color: var(--text);
}
.pt-assurances .icon {
  color: var(--primary);
  width: 17px;
  height: 17px;
}
.pt-privacy {
  display: flex;
  gap: 7px;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  color: var(--muted);
  text-align: center;
}
.pt-privacy .icon {
  width: 14px;
  height: 14px;
  flex-shrink: 0;
}
.pt-how {
  margin-top: 50px;
  border-top: 1px solid var(--line);
  padding-top: 27px;
}
.pt-how h2 {
  font-size: 18px;
  letter-spacing: -0.5px;
  margin: 0 0 22px;
  text-align: center;
}
.pt-how > div {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 36px;
  max-width: 920px;
  margin: auto;
}
.pt-how article {
  display: flex;
  gap: 14px;
  align-items: flex-start;
}
.pt-how article > span {
  font-weight: 700;
  font-size: 23px;
  color: #7f70d2;
  line-height: 1.4;
}
.pt-how p {
  color: var(--muted);
  font-size: 12px;
  margin: 2px 0;
}
.pt-editor {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 316px;
  gap: 24px;
  align-items: start;
}
.pt-preview-panel {
  min-width: 0;
}
.pt-workspace-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 0 0 20px;
}
.pt-workspace-top h2 {
  font-size: 17px;
  letter-spacing: -0.4px;
  margin: 0;
  overflow-wrap: anywhere;
}
.pt-workspace-top p {
  font-size: 12px;
  margin: 4px 0 0;
  color: var(--muted);
}
.pt-secondary,
.pt-icon-button,
.pt-text-button {
  border: 1px solid var(--line);
  border-radius: 9px;
  background: #fff;
  color: var(--text);
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  min-height: 44px;
  padding: 8px 13px;
  font-size: 12px;
}
.pt-secondary:hover,
.pt-icon-button:hover {
  background: #f0edff;
  color: var(--primary);
  border-color: #c8bfff;
}
.pt-workspace-top > .pt-secondary {
  flex-shrink: 0;
}
.pt-secondary > span {
  font-size: 20px;
  font-weight: 400;
}
.pt-icon-button {
  width: 44px;
  padding: 8px;
  flex-shrink: 0;
}
.pt-icon-button .icon {
  width: 18px;
  height: 18px;
}
.pt-text-button {
  border: 0;
  background: transparent;
  color: var(--primary);
  padding: 8px 0;
}
.pt-text-button:hover {
  text-decoration: underline;
}
.pt-selection-bar {
  display: flex;
  gap: 14px;
  align-items: center;
  flex-wrap: wrap;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  padding: 8px 0;
  font-size: 12px;
  color: var(--muted);
}
.pt-selection-bar > span:first-child {
  font-weight: 600;
  color: var(--text);
}
.pt-selection-bar > div {
  display: flex;
  gap: 2px;
}
.pt-selection-bar button {
  border: 0;
  background: transparent;
  color: var(--primary);
  font-weight: 600;
  min-height: 44px;
  min-width: 44px;
  padding: 5px 9px;
  border-radius: 7px;
}
.pt-selection-bar button:hover {
  background: #eae5ff;
}
.pt-selection-bar > span:last-child {
  margin-left: auto;
}
.pt-grid-hint {
  font-size: 12px;
  margin: 0 0 16px;
  color: var(--muted);
}
.pt-selection-bar + .pt-grid-hint {
  margin-top: 16px;
}
.pt-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 17px;
}
.pt-card {
  border: 1px solid #dee1ed;
  border-radius: 12px;
  background: #fff;
  position: relative;
  min-width: 0;
  transition:
    border-color 0.15s,
    box-shadow 0.15s;
  overflow: hidden;
}
.pt-card.is-selected {
  border-color: var(--primary);
  box-shadow: 0 0 0 1px var(--primary);
}
.pt-card.is-deleted {
  border-color: #c93950;
  background: #fff5f6;
  box-shadow: 0 0 0 1px #c93950;
}
.pt-card.is-dragging {
  opacity: 0.45;
}
.pt-card.is-drop-target {
  outline: 3px solid var(--primary);
  outline-offset: 4px;
}
.pt-card-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 3px 6px;
  color: var(--muted);
  min-height: 42px;
  font-size: 11px;
  gap: 6px;
}
.pt-card-top > span {
  padding-left: 7px;
}
.pt-card-top .pt-icon-button {
  border: 0;
  background: transparent;
  width: 38px;
  height: 44px;
  padding: 10px;
}
.pt-page-toggle,
.pt-page-preview {
  display: block;
  width: 100%;
  border: 0;
  background: transparent;
  padding: 0 14px;
  position: relative;
  color: var(--primary);
}
.pt-page-toggle:focus-visible {
  outline-offset: -3px !important;
}
.pt-page-stage {
  height: 190px;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  background: #f6f7fb;
  border-radius: 4px;
  padding: 10px;
  overflow: hidden;
}
.pt-page-stage canvas {
  max-height: 100%;
  max-width: 100%;
  width: auto;
  height: auto;
  box-shadow: 0 2px 8px #1e25471a;
  display: block;
}
.pt-page-stage.is-loading:after {
  content: "Preparing preview…";
  font-size: 10px;
  color: var(--muted);
  position: absolute;
  left: 0;
  right: 0;
  text-align: center;
}
.pt-page-stage .pt-preview-fallback {
  padding: 8px;
  font-size: 11px;
  color: var(--muted);
  text-align: center;
}
.pt-checkbox {
  border: 1.5px solid #a8a1c6;
  border-radius: 5px;
  width: 19px;
  height: 19px;
  display: grid;
  place-items: center;
  margin-right: 8px;
  background: #fff;
}
.pt-checkbox .icon {
  width: 14px;
  height: 14px;
  opacity: 0;
}
.is-selected .pt-checkbox {
  background: var(--primary);
  border-color: var(--primary);
  color: #fff;
}
.is-deleted .pt-checkbox {
  background: #ba263e;
  border-color: #ba263e;
  color: #fff;
}
.is-selected .pt-checkbox .icon {
  opacity: 1;
}
.is-deleted .pt-page-stage {
  opacity: 0.4;
}
.pt-deleted-label {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  color: #9e1733;
  background: #fff;
  border: 1px solid #e6abb5;
  padding: 6px 10px;
  border-radius: 6px;
  font-size: 11px;
  font-weight: 750;
  white-space: nowrap;
}
.pt-card-info {
  padding: 10px 12px 4px;
}
.pt-card-info strong {
  display: block;
  font-size: 12px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.pt-card-info small {
  display: block;
  color: var(--muted);
  font-size: 10px;
  line-height: 1.5;
  margin-top: 3px;
  min-height: 15px;
}
.pt-card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 5px 3px;
}
.pt-card-footer > div {
  display: flex;
}
.pt-card-footer .pt-icon-button {
  border: 0;
  background: transparent;
  font-size: 19px;
}
.pt-card-footer > span {
  color: var(--primary);
  font-size: 10px;
  font-weight: 650;
  padding: 0 7px;
}
.pt-add-card {
  min-height: 280px;
  border: 1.5px dashed #bcb5e7;
  border-radius: 12px;
  background: #eeebff44;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  color: var(--primary);
  font-size: 12px;
  font-weight: 650;
}
.pt-add-card > span {
  font-size: 28px;
  font-weight: 400;
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  background: #fff;
  border-radius: 50%;
  margin-bottom: 3px;
}
.pt-add-card > small {
  font-size: 10px;
  font-weight: 400;
  color: var(--muted);
}
.pt-pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  margin-top: 25px;
}
.pt-pagination > span {
  font-size: 11px;
  color: var(--muted);
}
.pt-options {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 17px;
  padding: 23px;
  position: sticky;
  top: 96px;
  box-shadow: 0 8px 30px #35306a05;
  min-width: 0;
}
.pt-options-heading {
  display: flex;
  align-items: center;
  gap: 11px;
  border-bottom: 1px solid var(--line);
  padding-bottom: 20px;
  margin-bottom: 20px;
}
.pt-tool-icon {
  display: grid;
  place-items: center;
  width: 45px;
  height: 45px;
  background: #eeebff;
  color: var(--primary);
  border-radius: 12px;
}
.pt-options-heading h2 {
  font-size: 19px;
  line-height: 1.4;
  margin: 2px 0 0;
  letter-spacing: -0.6px;
}
.pt-options-heading .pt-eyebrow {
  font-size: 9px;
}
.pt-option-intro {
  font-size: 14px;
  font-weight: 700;
  margin: 0 0 8px;
}
.pt-help {
  font-size: 11px;
  line-height: 1.65;
  color: var(--muted);
  margin: 7px 0 16px;
  overflow-wrap: anywhere;
}
.pt-stat-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  border: 1px solid #e6e2f6;
  border-radius: 10px;
  background: #f8f7ff;
  padding: 14px 5px;
  margin: 22px 0;
}
.pt-stat-grid > div {
  text-align: center;
  border-right: 1px solid #e6e2f6;
}
.pt-stat-grid > div:last-child {
  border: 0;
}
.pt-stat-grid strong {
  font-size: 21px;
  display: block;
  line-height: 1.4;
}
.pt-stat-grid span {
  font-size: 10px;
  color: var(--muted);
}
.pt-label,
.pt-modes legend {
  display: block;
  font-size: 12px;
  font-weight: 650;
  margin: 0 0 8px;
  color: var(--ink);
}
.pdf-tool input:not([type="file"]):not([type="radio"]):not([type="hidden"]),
.pdf-tool textarea {
  display: block;
  width: 100%;
  background: #fff;
  border: 1px solid #d5d9e8;
  border-radius: 8px;
  padding: 10px 11px;
  font-size: 13px;
  min-height: 44px;
  color: var(--ink);
  outline-offset: 2px;
}
.pdf-tool textarea {
  resize: vertical;
  min-height: 78px;
  max-height: 220px;
  line-height: 1.65;
}
.pdf-tool input[aria-invalid="true"],
.pdf-tool textarea[aria-invalid="true"] {
  border-color: #bc2b41 !important;
}
.pt-filename {
  border-top: 1px solid var(--line);
  padding-top: 19px;
  margin-top: 22px;
}
.pt-filename .pt-help {
  font-size: 10px;
  margin-bottom: 0;
}
.pt-run-bar {
  margin-top: 20px;
}
.pt-run-bar > p {
  font-size: 12px;
  color: var(--text);
  margin: 0 0 10px;
  text-align: center;
}
.pt-run {
  width: 100%;
  justify-content: space-between;
  border: 0;
  min-height: 50px;
  padding: 13px 17px;
  font-size: 13px;
}
.pt-upload-note {
  display: flex;
  align-items: flex-start;
  gap: 6px;
  font-size: 10px;
  color: var(--muted);
  text-align: left;
  line-height: 1.6;
  margin: 15px 0 5px;
}
.pt-upload-note .icon {
  width: 14px;
  height: 14px;
  flex-shrink: 0;
  margin-top: 2px;
}
.pt-start-over {
  width: 100%;
  font-size: 11px;
  color: var(--muted);
}
.pt-modes {
  border: 0;
  margin: 0 0 19px;
  padding: 0;
  min-width: 0;
}
.pt-modes legend {
  margin-bottom: 11px;
}
.pt-modes > label {
  display: flex;
  align-items: center;
  gap: 9px;
  border: 1px solid var(--line);
  border-radius: 9px;
  padding: 10px 11px;
  margin-bottom: 8px;
  cursor: pointer;
}
.pt-modes > label:has(input:checked) {
  border-color: #8677ff;
  background: #f5f3ff;
  box-shadow: 0 0 0 1px #8677ff;
}
.pt-modes input {
  accent-color: var(--primary);
  width: 16px;
  height: 16px;
  flex-shrink: 0;
}
.pt-modes strong {
  display: block;
  font-size: 12px;
}
.pt-modes small {
  display: block;
  font-size: 10px;
  color: var(--muted);
  line-height: 1.6;
  margin-top: 2px;
}
.pt-field-feedback {
  color: #a52037;
  font-size: 11px;
  margin: 10px 0;
}
.pt-split-preview {
  border-radius: 8px;
  background: #f5f3ff;
  padding: 11px 13px;
  font-size: 11px;
  color: #544487;
  max-height: 150px;
  overflow: auto;
}
.pt-split-preview p {
  margin: 0 0 6px;
  overflow-wrap: anywhere;
}
.pt-split-preview p:last-child {
  margin: 0;
}
.pt-range-row {
  display: flex;
  gap: 6px;
  align-items: center;
}
.pt-range-row input {
  min-width: 0;
}
.pt-rotate-actions {
  display: flex;
  gap: 7px;
}
.pt-rotate-actions button {
  flex: 1;
  display: flex;
  align-items: center;
  flex-direction: column;
  gap: 7px;
  border: 1px solid #dbd6f3;
  border-radius: 9px;
  background: #f8f7ff;
  padding: 13px 4px;
  font-size: 10px;
  color: var(--primary);
  font-weight: 600;
  min-width: 0;
}
.pt-rotate-actions button:hover {
  background: #eae5ff;
}
.pt-rotate-actions .icon {
  width: 21px;
  height: 21px;
}
.pt-delete-summary {
  display: flex;
  align-items: center;
  gap: 10px;
  background: #fff2f4;
  border: 1px solid #f5d8df;
  padding: 12px;
  border-radius: 9px;
  margin: 21px 0 5px;
  color: #aa2940;
}
.pt-delete-summary > .icon {
  flex-shrink: 0;
}
.pt-delete-summary p {
  margin: 0;
}
.pt-delete-summary strong {
  display: block;
  font-size: 12px;
}
.pt-delete-summary span {
  display: block;
  font-size: 10px;
  margin-top: 4px;
}
.pt-caution {
  border-left: 2px solid #c4bbe6;
  padding-left: 10px;
}
.pt-processing,
.pt-result {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 22px;
  padding: 55px 24px;
  text-align: center;
  min-height: 450px;
  box-shadow: 0 12px 45px #35306a05;
}
.pt-processing h2,
.pt-result h2 {
  font-size: 32px;
  letter-spacing: -1px;
  margin: 12px 0;
}
.pt-processing > p,
.pt-result > p {
  color: var(--muted);
  font-size: 14px;
}
.pt-spinner {
  width: 46px;
  height: 46px;
  border-radius: 50%;
  border: 4px solid #e8e3ff;
  border-top-color: var(--primary);
  animation: pt-spin 1s linear infinite;
  margin: 5px auto 27px;
}
.pt-processing progress {
  display: block;
  margin: 22px auto;
  width: min(100%, 330px);
  height: 8px;
  accent-color: var(--primary);
  border: 0;
  border-radius: 10px;
}
.pt-success-icon {
  width: 66px;
  height: 66px;
  border-radius: 22px;
  background: #e6f8ef;
  color: #138551;
  display: grid;
  place-items: center;
  margin: 0 auto 25px;
  transform: rotate(-8deg);
}
.pt-success-icon .icon {
  width: 30px;
  height: 30px;
  transform: rotate(8deg);
}
.pt-result .pt-download {
  min-height: 54px;
  gap: 12px;
  margin: 15px 0 0;
  max-width: 100%;
  padding: 15px 26px;
}
.pt-result-name {
  font-size: 11px !important;
  overflow-wrap: anywhere;
  max-width: 500px;
  margin: 12px auto 26px;
}
.pt-result-actions {
  display: flex;
  justify-content: center;
  gap: 22px;
  flex-wrap: wrap;
  margin-top: 17px;
}
.pt-review {
  max-width: 680px;
  margin: 25px auto;
  text-align: left;
  border: 1px solid #e0cda2;
  background: #fffcf4;
  border-radius: 10px;
  padding: 8px 16px;
  color: #775413;
}
.pt-review summary {
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  min-height: 44px;
  align-content: center;
}
.pt-review summary > .icon {
  width: 17px;
  height: 17px;
  vertical-align: middle;
  margin-right: 7px;
}
.pt-review ul {
  padding: 0 0 0 18px;
  margin: 10px 0;
  max-height: 320px;
  overflow: auto;
}
.pt-review li {
  font-size: 12px;
  margin: 0 0 12px;
  overflow-wrap: anywhere;
}
.pt-result-next {
  border-top: 1px solid var(--line);
  max-width: 790px;
  margin: 36px auto 0;
  padding-top: 24px;
}
.pt-result-next h3 {
  font-size: 14px;
  margin: 0 0 18px;
}
.pt-result-next nav {
  display: flex;
  gap: 10px;
  justify-content: center;
  flex-wrap: wrap;
}
.pt-result-next a {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  color: var(--text);
  text-decoration: none;
  font-size: 12px;
  font-weight: 600;
  border: 1px solid var(--line);
  border-radius: 9px;
  padding: 11px 15px;
  min-height: 44px;
}
.pt-result-next .icon {
  color: var(--primary);
  width: 18px;
  height: 18px;
}
.pt-zoom {
  border: 1px solid var(--line);
  border-radius: 15px;
  padding: 18px;
  width: min(760px, calc(100% - 28px));
  max-height: 90dvh;
  box-shadow: var(--shadow);
}
.pt-zoom::backdrop {
  background: #14112e99;
  backdrop-filter: blur(5px);
}
.pt-zoom-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}
.pt-zoom-top h2 {
  font-size: 17px;
  margin: 0;
}
.pt-zoom-stage {
  min-height: 180px;
  margin-top: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #f1f2f8;
  padding: 18px;
  overflow: auto;
}
.pt-zoom-stage canvas {
  max-width: 100%;
  max-height: 65dvh;
  object-fit: contain;
  box-shadow: 0 4px 12px #28304f20;
}
.pt-zoom > .pt-help {
  margin-bottom: 0;
  text-align: center;
}
@keyframes pt-spin {
  to {
    transform: rotate(360deg);
  }
}
@media (min-width: 1100px) {
  .pt-start {
    max-width: 1060px;
    margin: auto;
  }
  .pt-dropzone {
    padding-top: 40px;
    padding-bottom: 30px;
  }
  .pt-heading {
    margin-bottom: 36px;
  }
  .pt-page-stage {
    height: 220px;
  }
}
@media (max-width: 1050px) {
  .pt-heading {
    align-items: flex-start;
  }
  .pt-steps {
    gap: 11px;
  }
  .pt-steps li {
    flex-direction: column;
    gap: 5px;
    font-size: 10px;
  }
  .pt-editor {
    grid-template-columns: minmax(0, 1fr) 290px;
    gap: 18px;
  }
  .pt-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .pt-options {
    padding: 19px;
  }
  .pt-assurances {
    gap: 23px;
  }
  .pt-heading h1 {
    font-size: 40px;
  }
  .pt-page-stage {
    height: 210px;
  }
}
@media (max-width: 760px) {
  .pdf-tool {
    padding-top: 18px;
    padding-bottom: 42px;
  }
  .pt-topline {
    gap: 10px;
  }
  .pt-tools {
    gap: 2px;
  }
  .pt-tools a {
    padding: 8px 12px;
  }
  .pt-tools .icon {
    display: none;
  }
  .pt-heading {
    display: block;
    margin: 23px 0;
  }
  .pt-heading h1 {
    font-size: 38px;
    margin-bottom: 10px;
  }
  .pt-heading p {
    font-size: 13px;
  }
  .pt-eyebrow {
    font-size: 9px;
    letter-spacing: 1px;
  }
  .pt-steps {
    margin-top: 23px;
    justify-content: flex-start;
    gap: 22px;
  }
  .pt-steps li {
    flex-direction: row;
    font-size: 11px;
  }
  .pt-steps span {
    width: 24px;
    height: 24px;
  }
  .pt-editor {
    display: flex;
    flex-direction: column;
    gap: 27px;
  }
  .pt-preview-panel,
  .pt-options {
    width: 100%;
  }
  .pt-options {
    position: static;
    padding: 22px;
  }
  .pt-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 13px;
  }
  .pt-page-stage {
    height: 190px;
  }
  .pt-workspace-top {
    padding-bottom: 15px;
  }
  .pt-workspace-top h2 {
    font-size: 15px;
  }
  .pt-assurances {
    gap: 12px;
    flex-wrap: wrap;
    margin: 21px 0 13px;
  }
  .pt-assurances span {
    font-size: 10px;
    gap: 5px;
  }
  .pt-assurances .icon {
    width: 14px;
    height: 14px;
  }
  .pt-how {
    margin-top: 35px;
  }
  .pt-how > div {
    gap: 15px;
  }
  .pt-how article {
    gap: 8px;
  }
  .pt-how article > span {
    font-size: 18px;
  }
  .pt-how p {
    font-size: 11px;
  }
  .pt-how h2 {
    font-size: 17px;
  }
  .pt-dropzone {
    padding: 34px 17px 24px;
  }
  .pt-dropzone h2 {
    font-size: 22px;
  }
  .pt-dropzone > p {
    font-size: 12px;
    max-width: 320px;
  }
  .pt-privacy {
    font-size: 10px;
    align-items: flex-start;
  }
  .pt-privacy .icon {
    margin-top: 2px;
  }
  .pt-options input:not([type="radio"]),
  .pdf-tool textarea {
    font-size: 16px !important;
  }
  .pt-modes > label {
    padding: 12px;
  }
  .pt-modes strong {
    font-size: 13px;
  }
  .pt-modes small {
    font-size: 11px;
  }
  .pt-help {
    font-size: 12px;
  }
  .pt-run-bar {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 10px max(18px, env(safe-area-inset-left))
      calc(10px + env(safe-area-inset-bottom));
    background: #fffffff5;
    backdrop-filter: blur(12px);
    border-top: 1px solid var(--line);
    box-shadow: 0 -4px 30px #28205209;
    z-index: 45;
    display: flex;
    align-items: center;
    gap: 14px;
    margin: 0;
  }
  .pt-run-bar > p {
    text-align: left;
    flex: 1;
    font-size: 11px;
    margin: 0;
    line-height: 1.5;
    min-width: 0;
  }
  .pt-run {
    width: auto;
    min-width: 160px;
    gap: 12px;
    max-width: 70%;
    font-size: 12px;
    min-height: 48px;
  }
  .pdf-editor-open {
    padding-bottom: 85px;
    scroll-padding-bottom: 110px;
  }
  .pdf-editor-open .site-footer {
    padding-bottom: 85px;
  }
  .pt-options-heading {
    padding-bottom: 18px;
    margin-bottom: 18px;
  }
  .pt-options .pt-filename {
    margin-top: 18px;
  }
  .pt-upload-note {
    font-size: 11px;
  }
  .pt-result,
  .pt-processing {
    padding: 38px 20px;
  }
  .pt-result h2,
  .pt-processing h2 {
    font-size: 27px;
  }
  .pt-result-next a {
    flex: 1;
    min-width: 160px;
  }
  .pt-selection-bar {
    gap: 8px;
  }
  .pt-selection-bar > span:last-child {
    font-size: 10px;
  }
}
@media (max-width: 480px) {
  .pt-topline {
    display: block;
  }
  .pt-back {
    font-size: 12px;
    min-height: 32px;
    margin-bottom: 10px;
  }
  .pt-tools {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
  }
  .pt-tools a {
    justify-content: center;
    padding: 8px;
    gap: 7px;
    font-size: 12px;
  }
  .pt-tools .icon {
    display: block;
    width: 14px;
    height: 14px;
  }
  .pt-heading h1 {
    font-size: 35px;
    letter-spacing: -1.5px;
  }
  .pt-steps {
    justify-content: space-between;
    gap: 8px;
    margin-top: 20px;
  }
  .pt-steps li {
    font-size: 10px;
    gap: 6px;
  }
  .pt-steps span {
    width: 22px;
    height: 22px;
    font-size: 10px;
  }
  .pt-heading p {
    font-size: 12px;
    max-width: 310px;
  }
  .pt-dropzone {
    border-radius: 17px;
    padding-top: 30px;
  }
  .pt-dropzone h2 {
    font-size: 20px;
  }
  .pt-paper-art {
    transform: scale(0.9);
    height: 90px;
  }
  .pt-select {
    width: 100%;
    min-width: 0;
    font-size: 13px;
  }
  .pt-drop-hint {
    margin-bottom: 22px;
    font-size: 12px;
  }
  .pt-limit {
    font-size: 9px;
  }
  .pt-assurances {
    display: grid;
    grid-template-columns: 1fr;
    gap: 9px;
    justify-items: center;
    margin-top: 21px;
  }
  .pt-assurances span {
    font-size: 11px;
  }
  .pt-privacy {
    max-width: 285px;
    margin: 18px auto 0;
    line-height: 1.7;
  }
  .pt-how > div {
    display: block;
  }
  .pt-how article {
    align-items: center;
    gap: 15px;
    padding: 8px 0;
  }
  .pt-how p {
    font-size: 12px;
  }
  .pt-how h2 {
    text-align: left;
    margin-bottom: 9px;
  }
  .pt-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
  }
  .pt-page-stage {
    height: 176px;
    padding: 8px;
  }
  .pt-page-toggle,
  .pt-page-preview {
    padding: 0 9px;
  }
  .pt-card-info {
    padding: 9px 10px 3px;
  }
  .pt-card-info strong {
    font-size: 11px;
  }
  .pt-card-footer .pt-icon-button {
    width: 40px;
  }
  .pt-card-footer > span {
    font-size: 9px;
    padding: 0 4px;
  }
  .pt-card-top {
    padding: 2px 2px;
  }
  .pt-card-top > span {
    padding-left: 8px;
    font-size: 10px;
  }
  .pt-card-top .pt-icon-button {
    width: 36px;
  }
  .pt-card-footer {
    padding: 0 2px 3px;
  }
  .pt-workspace-top {
    align-items: flex-start;
    gap: 10px;
  }
  .pt-workspace-top p {
    font-size: 10px;
  }
  .pt-workspace-top .pt-secondary {
    font-size: 11px;
    padding: 8px 10px;
  }
  .pt-grid-hint {
    font-size: 11px;
  }
  .pt-selection-bar > span:first-child {
    width: 100%;
    font-size: 11px;
  }
  .pt-selection-bar {
    gap: 0;
  }
  .pt-selection-bar > div {
    margin-left: -8px;
  }
  .pt-add-card {
    min-height: 260px;
  }
  .pt-run-bar {
    gap: 10px;
  }
  .pt-run {
    min-width: 150px;
    padding: 12px;
    font-size: 11px;
  }
  .pt-run .icon {
    width: 17px;
    height: 17px;
  }
  .pt-run-bar > p {
    font-size: 10px;
  }
  .pt-options {
    padding: 19px;
  }
  .pt-result-actions {
    gap: 7px;
    flex-direction: column;
    align-items: center;
  }
  .pt-result-next nav {
    display: grid;
    grid-template-columns: 1fr;
  }
  .pt-result-next a {
    font-size: 12px;
  }
  .pt-processing > p,
  .pt-result > p {
    font-size: 12px;
  }
  .pt-pagination {
    gap: 8px;
  }
  .pt-pagination .pt-secondary {
    font-size: 10px;
    padding: 8px;
  }
  .pt-pagination > span {
    font-size: 10px;
  }
}
@media (prefers-reduced-motion: reduce) {
  .pt-spinner {
    animation-duration: 3s;
  }
  .pdf-tool * {
    scroll-behavior: auto !important;
    transition: none !important;
  }
}

.pt-mobile-options {
  display: none;
}
@media (max-width: 760px) {
  .pt-mobile-options {
    display: flex;
    align-items: center;
    flex-direction: column;
    justify-content: center;
    gap: 2px;
    min-height: 44px;
    min-width: 45px;
    border: 0;
    background: transparent;
    color: var(--primary);
    font-size: 9px;
    font-weight: 600;
    padding: 3px;
  }
  .pt-mobile-options .icon {
    width: 18px;
    height: 18px;
  }
  .pt-run-bar {
    gap: 10px;
  }
  .pt-run-bar > p {
    font-size: 10px;
  }
  .pt-run {
    min-width: 140px;
  }
  .pt-options:focus {
    outline: 2px solid #b3aaff;
    outline-offset: 3px;
    scroll-margin-top: 85px;
  }
}
@media (max-width: 480px) {
  .pt-add-card {
    grid-column: 1/-1;
    min-height: 70px;
    flex-direction: row;
    gap: 12px;
  }
  .pt-add-card > span {
    width: 30px;
    height: 30px;
    font-size: 23px;
    margin: 0;
  }
  .pt-add-card > small {
    display: none;
  }
  .pt-run-bar {
    gap: 7px;
  }
  .pt-run {
    min-width: 135px;
    max-width: 58%;
  }
  .pt-run-bar > p {
    font-size: 9px;
  }
}

.pt-check-button {
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  border: 0;
  background: transparent;
  padding: 0;
  flex-shrink: 0;
}
.pt-check-button .pt-checkbox {
  margin: 0;
}
.pt-check-button:hover .pt-checkbox {
  outline: 3px solid #4c38ff15;
}
/* Extract Pages keeps its native checkbox compact inside the shared options form. */
.pdf-tool input[type="checkbox"][data-separate-pages]:not([hidden]){display:inline-block;width:18px;height:18px;min-width:18px;min-height:18px;padding:0;vertical-align:middle;margin:0 6px 0 0;accent-color:var(--primary)}
@media(max-width:760px){.pt-topline{flex-wrap:wrap}.pt-tools{max-width:100%;flex-wrap:wrap}}
