#app-content[data-theme=dark] {
  --bg-body: #0f172a;
  --bg-card: #1e293b;
  --text-primary: #f1f5f9;
  --text-secondary: #94a3b8;
  --text-muted: #64748b;
  --border: #334155;
  --shadow: 0 4px 24px rgba(0,0,0,0.3);
  --primary-light: rgba(67,97,238,0.12);
  --dark: #f1f5f9;
  --gray: #94a3b8;
  --light: #1e293b;
  --bg-gradient: linear-gradient(160deg,#0f172a 0%,#1e293b 100%);
}

#app-content[data-theme=light] {
  --bg-body: #f8fafc;
  --bg-card: #ffffff;
  --text-primary: #1e293b;
  --text-secondary: #475569;
  --text-muted: #94a3b8;
  --border: #e2e8f0;
  --shadow: 0 4px 24px rgba(67,97,238,0.08);
  --primary-light: rgba(67,97,238,0.08);
  --dark: #1a1a2e;
  --gray: #6c757d;
  --light: #f8f9fa;
  --bg-gradient: linear-gradient(160deg,#f0f4ff 0%,#e8ffe8 40%,#f5f0ff 100%);
}

:root {
  --primary: #0d9488;
  --primary-dark: #0f766e;
  --secondary: #0e7490;
  --accent: #06b6d4;
  --success: #10b981;
  --warning: #f59e0b;
  --danger: #ef4444;
  --dark: #0f172a;
  --gray: #64748b;
  --light: #f8fafc;
  --border: #e2e8f0;
  --bg-gradient: linear-gradient(160deg,#f0fdfa 0%,#ecfeff 40%,#f0f9ff 100%);
  --bg-card: #ffffff;
  --text-primary: #1e293b;
  --text-secondary: #475569;
  --text-muted: #94a3b8;
  --shadow: 0 4px 24px rgba(0,0,0,0.08);
  --primary-light: rgba(0,0,0,0.06);
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: "Inter", system-ui, -apple-system, sans-serif;
  background: var(--bg-gradient);
  color: var(--text-primary);
  line-height: 1.75;
  overflow-x: hidden;
  scroll-behavior: smooth;
}

h1, h2, h3, h4, h5, h6 {
  font-family: "Inter", sans-serif;
  font-weight: 700;
  line-height: 1.3;
}

.hero-section {
  padding: 140px 0 100px;
  background: linear-gradient(135deg, #0d9488 0%, #0e7490 50%, #155e75 100%);
  color: #fff;
  position: relative;
  overflow: hidden;
}
.hero-section::after {
  content: "";
  position: absolute;
  bottom: -2px;
  left: 0;
  right: 0;
  height: 80px;
  background: var(--bg-gradient);
  clip-path: ellipse(55% 100% at 50% 100%);
}

.hero-title {
  font-size: clamp(2.2rem, 5vw, 3.8rem);
  font-weight: 900;
  margin-bottom: 1.25rem;
}

.hero-desc {
  font-size: 1.15rem;
  opacity: 0.92;
  max-width: 620px;
}

.tool-wrapper {
  margin-top: -40px;
  position: relative;
  z-index: 10;
  padding-bottom: 2rem;
}

.tool-card {
  background: var(--bg-card);
  border-radius: 20px;
  padding: 2rem;
  box-shadow: 0 4px 24px rgba(13, 148, 136, 0.08);
  border: 1px solid rgba(13, 148, 136, 0.08);
}

.upload-zone {
  border: 2.5px dashed rgba(13, 148, 136, 0.3);
  border-radius: 16px;
  padding: 3.5rem 2rem;
  text-align: center;
  background: rgba(13, 148, 136, 0.03);
  cursor: pointer;
  transition: all 0.3s;
}
.upload-zone:hover, .upload-zone.dragover {
  border-color: var(--primary);
  background: rgba(13, 148, 136, 0.07);
  transform: scale(1.01);
}
.upload-zone h3 {
  font-size: 1.45rem;
  font-weight: 700;
  color: var(--dark);
  margin-bottom: 10px;
}
.upload-zone p {
  color: var(--gray);
  font-size: 0.95rem;
  max-width: 480px;
  margin: 0 auto 1.5rem;
  line-height: 1.65;
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 24px;
  border: none;
  border-radius: 10px;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
  font-family: inherit;
  text-decoration: none;
}

.btn-primary {
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  color: #fff;
}
.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(13, 148, 136, 0.3);
}
.btn-primary:disabled {
  background: #9ca3af;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

.btn-success {
  background: linear-gradient(135deg, var(--success), #059669);
  color: #fff;
}
.btn-success:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(16, 185, 129, 0.3);
}

.btn-secondary {
  background: var(--light);
  color: var(--dark);
  border: 1px solid var(--border);
}
.btn-secondary:hover {
  border-color: var(--primary);
  color: var(--primary-dark);
  background: var(--light);
}

.workspace {
  display: none;
  margin-top: 24px;
}

.workspace.show {
  display: block;
  animation: fadeUp 0.5s ease;
}

@keyframes fadeUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
.file-info {
  display: none;
  background: var(--light);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 14px 18px;
  margin-bottom: 18px;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.file-info.show {
  display: flex;
}

.fi-icon {
  width: 42px;
  height: 42px;
  border-radius: 10px;
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  flex-shrink: 0;
}

.fi-details {
  flex: 1;
  min-width: 0;
}

.fi-name {
  font-weight: 700;
  color: var(--dark);
  font-size: 0.95rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.fi-meta {
  font-size: 0.8rem;
  color: var(--gray);
  margin-top: 2px;
}

.workspace-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr);
  gap: 24px;
  margin-top: 18px;
  align-items: start;
}

@media (max-width: 1024px) {
  .workspace-layout {
    grid-template-columns: minmax(0, 1fr);
    gap: 20px;
  }
}
.workspace-panel {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 20px;
}
.workspace-panel h4 {
  font-size: 1.05rem;
  margin: 0 0 14px;
  color: var(--dark);
  display: flex;
  align-items: center;
  gap: 8px;
}
.workspace-panel h4 i {
  color: var(--primary);
}

.preview-stage {
  background: repeating-conic-gradient(#e2e8f0 0% 25%, #f1f5f9 0% 50%) 50%/16px 16px;
  border-radius: 12px;
  padding: 20px;
  min-height: 380px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--border);
  position: relative;
  overflow: hidden;
}

.preview-stage-label {
  position: absolute;
  top: 10px;
  left: 14px;
  font-size: 0.7rem;
  font-weight: 800;
  color: var(--gray);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  background: var(--bg-card);
  padding: 3px 8px;
  border-radius: 6px;
  border: 1px solid var(--border);
  z-index: 1;
}

#pdf-canvas {
  max-width: 100%;
  height: auto;
  background: var(--bg-card);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
  border-radius: 4px;
  display: block;
}

.page-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 14px;
  padding: 10px 14px;
  background: var(--light);
  border-radius: 10px;
  border: 1px solid var(--border);
  gap: 8px;
  flex-wrap: wrap;
}

.page-nav-btns {
  display: flex;
  gap: 6px;
  align-items: center;
}
.page-nav-btns button {
  padding: 6px 12px;
  border: 1px solid var(--border);
  background: var(--bg-card);
  border-radius: 6px;
  cursor: pointer;
  font-size: 0.85rem;
  color: var(--dark);
  font-weight: 600;
  font-family: inherit;
  transition: all 0.2s;
}
.page-nav-btns button:hover:not(:disabled) {
  border-color: var(--primary);
  color: var(--primary-dark);
}
.page-nav-btns button:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

.page-nav input {
  width: 60px;
  padding: 6px 8px;
  border: 1px solid var(--border);
  border-radius: 6px;
  text-align: center;
  font-weight: 700;
  font-family: inherit;
  font-size: 0.9rem;
}
.page-nav input:focus {
  outline: none;
  border-color: var(--primary);
}

.thumb-strip {
  display: flex;
  gap: 6px;
  overflow-x: auto;
  padding: 10px;
  background: var(--light);
  border-radius: 10px;
  border: 1px solid var(--border);
  margin-top: 12px;
  min-height: 90px;
}
.thumb-strip::-webkit-scrollbar {
  height: 6px;
}
.thumb-strip::-webkit-scrollbar-thumb {
  background: var(--border);
  border-radius: 3px;
}

.thumb-item {
  flex-shrink: 0;
  width: 60px;
  height: 80px;
  background: var(--bg-card);
  border: 2px solid var(--border);
  border-radius: 6px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--gray);
  transition: all 0.2s;
  overflow: hidden;
}
.thumb-item:hover {
  border-color: var(--primary);
  transform: translateY(-2px);
}
.thumb-item.active {
  border-color: var(--primary);
  box-shadow: 0 4px 12px rgba(13, 148, 136, 0.3);
}
.thumb-item canvas {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
}
.thumb-item.selected {
  border-color: var(--primary);
  background: #ccfbf1;
  position: relative;
}
.thumb-item.selected::after {
  content: "\f00c";
  font-family: "Font Awesome 6 Free";
  font-weight: 900;
  position: absolute;
  top: 2px;
  right: 2px;
  background: var(--primary);
  color: #fff;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  font-size: 9px;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 2;
}

.presets-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(105px, 1fr));
  gap: 8px;
  margin-bottom: 18px;
}

.preset-card {
  padding: 11px 8px;
  border: 2px solid var(--border);
  border-radius: 10px;
  background: var(--bg-card);
  text-align: center;
  cursor: pointer;
  transition: all 0.2s;
  font-family: inherit;
  width: 100%;
}
.preset-card:hover {
  border-color: var(--primary);
  background: var(--light);
  transform: translateY(-1px);
}
.preset-card.active {
  border-color: var(--primary);
  background: #ccfbf1;
  box-shadow: 0 4px 12px rgba(13, 148, 136, 0.15);
}
.preset-card .p-name {
  font-weight: 700;
  font-size: 0.85rem;
  color: var(--dark);
}
.preset-card .p-size {
  font-size: 0.7rem;
  color: var(--gray);
  margin-top: 2px;
  font-weight: 500;
}

.dim-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-bottom: 14px;
}

.dim-box {
  background: #f8fafc;
  border-radius: 10px;
  padding: 14px;
  border: 1px solid var(--border);
}
.dim-box label {
  font-weight: 600;
  font-size: 0.78rem;
  color: var(--gray);
  margin-bottom: 8px;
  display: flex;
  align-items: center;
  gap: 6px;
  text-transform: uppercase;
  letter-spacing: 0.3px;
}
.dim-box label i {
  color: var(--primary);
}

.dim-input-row {
  display: flex;
  gap: 6px;
}

.dim-input {
  flex: 1;
  padding: 9px 12px;
  border: 2px solid var(--border);
  border-radius: 8px;
  font-size: 0.95rem;
  font-weight: 700;
  background: var(--bg-card);
  color: var(--dark);
  transition: all 0.2s;
  min-width: 0;
  width: 100%;
  font-family: inherit;
}
.dim-input:focus {
  outline: none;
  border-color: var(--primary);
  background: var(--bg-card);
}

.dim-unit-select {
  padding: 9px 6px;
  border: 2px solid var(--border);
  border-radius: 8px;
  font-size: 0.85rem;
  font-weight: 600;
  background: var(--bg-card);
  color: var(--dark);
  cursor: pointer;
  min-width: 64px;
  font-family: inherit;
}
.dim-unit-select:focus {
  outline: none;
  border-color: var(--primary);
}

.dim-converted {
  font-size: 0.72rem;
  color: var(--gray);
  margin-top: 5px;
  font-weight: 500;
}

.chip-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 14px;
}

.chip {
  padding: 9px 14px;
  background: #f8fafc;
  border: 2px solid var(--border);
  border-radius: 20px;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--gray);
  cursor: pointer;
  transition: all 0.2s;
  font-family: inherit;
  display: inline-flex;
  align-items: center;
  gap: 5px;
}
.chip:hover {
  border-color: var(--primary);
  color: var(--primary-dark);
}
.chip.active {
  border-color: var(--primary);
  background: #ccfbf1;
  color: var(--primary-dark);
  box-shadow: 0 4px 12px rgba(13, 148, 136, 0.15);
}
.chip i {
  font-size: 0.9rem;
}

.dim-preview-wrap {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background: repeating-conic-gradient(#e2e8f0 0% 25%, #f1f5f9 0% 50%) 50%/16px 16px;
  border-radius: 12px;
  border: 1px solid var(--border);
  margin-bottom: 18px;
  min-height: 200px;
}

.dim-preview-box {
  background: var(--bg-card);
  border: 2.5px solid var(--primary);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1);
  position: relative;
  transition: all 0.3s;
}

.dim-label {
  position: absolute;
  background: var(--primary);
  color: #fff;
  font-size: 0.7rem;
  font-weight: 700;
  padding: 2px 7px;
  border-radius: 4px;
  white-space: nowrap;
}

.dim-label-w {
  bottom: -22px;
  left: 50%;
  transform: translateX(-50%);
}

.dim-label-h {
  right: -46px;
  top: 50%;
  transform: translateY(-50%) rotate(90deg);
}

.right-stack {
  display: flex;
  flex-direction: column;
  gap: 16px;
  min-width: 0;
  max-width: 100%;
}

.right-stack .workspace-panel {
  width: 100%;
  min-width: 0;
  max-width: 100%;
}

.sel-panel {
  background: var(--light);
  border: 2px solid var(--border);
  box-shadow: var(--shadow);
}

.sel-panel h4 {
  color: var(--primary-dark);
}

.sel-header-row {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  margin: -4px 0 12px;
}

.sel-count {
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--primary-dark);
  background: var(--bg-card);
  padding: 5px 12px;
  border-radius: 20px;
  border: 1px solid rgba(13, 148, 136, 0.2);
}

.sel-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 8px;
  margin-bottom: 12px;
}

.sel-btn {
  padding: 12px 6px;
  border: 1.5px solid var(--border);
  background: var(--bg-card);
  border-radius: 10px;
  cursor: pointer;
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--dark);
  font-family: inherit;
  transition: all 0.2s;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 5px;
  min-height: 62px;
  line-height: 1.1;
  text-align: center;
  word-break: break-word;
}
.sel-btn i {
  font-size: 1rem;
  color: var(--primary);
}
.sel-btn:hover {
  border-color: var(--primary);
  background: var(--light);
  transform: translateY(-1px);
  box-shadow: 0 4px 10px rgba(13, 148, 136, 0.1);
}
.sel-btn:active {
  transform: translateY(0);
}
.sel-btn.active {
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  color: #fff;
  border-color: var(--primary-dark);
}
.sel-btn.active i {
  color: #fff;
}

.sel-custom {
  display: flex;
  gap: 8px;
  margin-bottom: 12px;
  flex-wrap: wrap;
}

.sel-range-input {
  flex: 1;
  min-width: 140px;
  padding: 10px 12px;
  border: 1.5px solid var(--border);
  border-radius: 8px;
  font-size: 0.88rem;
  font-family: inherit;
  background: var(--bg-card);
  color: var(--dark);
}
.sel-range-input:focus {
  outline: none;
  border-color: var(--primary);
  background: var(--bg-card);
}
.sel-range-input::placeholder {
  color: #94a3b8;
}

.sel-btn-apply {
  padding: 10px 16px;
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  color: #fff;
  border: none;
  border-radius: 8px;
  font-size: 0.85rem;
  font-weight: 700;
  cursor: pointer;
  font-family: inherit;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  white-space: nowrap;
  transition: all 0.2s;
}
.sel-btn-apply:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(13, 148, 136, 0.3);
}

.sel-fit {
  display: flex;
  gap: 8px;
  align-items: center;
  flex-wrap: wrap;
}

.sel-fit-label {
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--gray);
  text-transform: uppercase;
  letter-spacing: 0.3px;
  display: flex;
  align-items: center;
  gap: 5px;
  flex-shrink: 0;
}
.sel-fit-label i {
  color: var(--primary);
}

.sel-fit-select {
  flex: 1;
  min-width: 180px;
  padding: 10px 12px;
  border: 1.5px solid var(--border);
  border-radius: 8px;
  font-size: 0.85rem;
  font-weight: 600;
  background: var(--bg-card);
  color: var(--dark);
  cursor: pointer;
  font-family: inherit;
}
.sel-fit-select:focus {
  outline: none;
  border-color: var(--primary);
}

@media (max-width: 768px) {
  .sel-grid {
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 6px;
  }
  .sel-btn {
    min-height: 58px;
    font-size: 0.76rem;
    padding: 8px 4px;
  }
  .sel-btn i {
    font-size: 0.9rem;
  }
}
@media (max-width: 480px) {
  .sel-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
  .sel-custom {
    flex-direction: column;
  }
  .sel-btn-apply {
    width: 100%;
    justify-content: center;
  }
  .sel-fit {
    flex-direction: column;
    align-items: stretch;
  }
  .sel-fit-label {
    margin-bottom: 2px;
  }
  .sel-fit-select {
    min-width: 0;
    width: 100%;
  }
}
.action-btns {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: center;
  margin-top: 6px;
}

@media (max-width: 480px) {
  .action-btns {
    flex-direction: column;
  }
  .act-btn {
    width: 100%;
    min-width: 0;
  }
}
.act-btn {
  padding: 13px 22px;
  border-radius: 10px;
  border: none;
  font-weight: 700;
  font-size: 0.92rem;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  transition: all 0.2s;
  font-family: inherit;
  flex: 1;
  min-width: 180px;
  justify-content: center;
}

.act-btn-primary {
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  color: #fff;
  box-shadow: 0 6px 18px rgba(13, 148, 136, 0.3);
}
.act-btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 24px rgba(13, 148, 136, 0.4);
}

.act-btn-success {
  background: linear-gradient(135deg, var(--success), #059669);
  color: #fff;
  box-shadow: 0 6px 18px rgba(16, 185, 129, 0.3);
}
.act-btn-success:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 24px rgba(16, 185, 129, 0.4);
}

.act-btn-gray {
  background: var(--bg-card);
  color: var(--dark);
  border: 1px solid var(--border);
}
.act-btn-gray:hover {
  border-color: var(--primary);
  color: var(--primary-dark);
}

.progress-wrap {
  display: none;
  margin-top: 18px;
  padding: 14px 18px;
  background: var(--light);
  border: 1px solid rgba(13, 148, 136, 0.15);
  border-radius: 12px;
}
.progress-wrap.show {
  display: block;
}

.progress-label {
  font-weight: 700;
  color: var(--dark);
  font-size: 0.92rem;
  margin-bottom: 8px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.progress-pct {
  color: var(--primary-dark);
  font-weight: 800;
  font-size: 1rem;
}

.progress-track {
  height: 8px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 6px;
  overflow: hidden;
}

.progress-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--primary), var(--accent));
  width: 0%;
  transition: width 0.4s ease;
}

.result-banner {
  display: none;
  background: linear-gradient(135deg, #10b981, #059669);
  border-radius: 16px;
  padding: 32px;
  color: #fff;
  text-align: center;
  margin-top: 20px;
  animation: fadeUp 0.5s ease;
}
.result-banner.show {
  display: block;
}

.result-stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
  margin: 20px 0;
}

@media (max-width: 768px) {
  .result-stats-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}
.rs-item {
  background: rgba(255, 255, 255, 0.18);
  backdrop-filter: blur(8px);
  border-radius: 12px;
  padding: 16px 10px;
}

.rs-value {
  font-size: 1.5rem;
  font-weight: 800;
  line-height: 1;
}

.rs-label {
  font-size: 0.78rem;
  opacity: 0.85;
  margin-top: 5px;
}

.content-section {
  padding: 60px 0;
}

.content-card {
  background: var(--bg-card);
  border-radius: 20px;
  padding: 40px;
  margin-bottom: 32px;
  box-shadow: 0 4px 24px rgba(13, 148, 136, 0.06);
  border: 1px solid rgba(13, 148, 136, 0.08);
}
.content-card h2 {
  font-size: 1.6rem;
  margin-bottom: 18px;
  color: var(--dark);
  font-weight: 800;
}
.content-card h3 {
  font-size: 1.2rem;
  margin: 24px 0 12px;
  color: var(--text-primary);
  font-weight: 700;
}
.content-card p {
  color: var(--text-secondary);
  margin-bottom: 16px;
  line-height: 1.85;
  font-size: 1.02rem;
}
.content-card ul, .content-card ol {
  color: var(--text-secondary);
  margin-bottom: 18px;
  padding-left: 24px;
  font-size: 1.02rem;
  line-height: 1.85;
}
.content-card ul li, .content-card ol li {
  margin-bottom: 10px;
}
.content-card strong {
  color: var(--dark);
}

.trust-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 32px;
  padding: 16px 20px;
  background: linear-gradient(135deg, rgba(13, 148, 136, 0.05), rgba(14, 116, 144, 0.05));
  border-radius: 12px;
  border: 1px solid rgba(13, 148, 136, 0.1);
}

.trust-item {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.9rem;
  color: var(--dark);
  font-weight: 500;
}
.trust-item i {
  color: var(--success);
  font-size: 1rem;
}

.steps-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 18px;
  margin-top: 24px;
}

.step-item {
  display: flex;
  gap: 14px;
  padding: 20px;
  background: var(--light);
  border-radius: 14px;
  border: 1px solid rgba(13, 148, 136, 0.15);
}

.step-num {
  flex-shrink: 0;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
  font-weight: 800;
}

.step-content h3 {
  font-size: 1rem;
  margin: 0 0 4px;
  color: var(--dark);
  font-weight: 700;
}
.step-content p {
  font-size: 0.88rem;
  margin: 0;
  line-height: 1.6;
}

.case-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 20px;
  margin-top: 20px;
}

.case-card {
  background: var(--light);
  border-radius: 14px;
  padding: 24px;
  border: 1px solid rgba(13, 148, 136, 0.15);
  position: relative;
}
.case-card h3 {
  font-size: 1.05rem;
  margin: 12px 0 14px;
  color: var(--dark);
  font-weight: 700;
}

.case-number {
  position: absolute;
  top: -12px;
  left: 20px;
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  color: #fff;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.9rem;
  font-weight: 800;
}

.case-detail {
  font-size: 0.9rem;
  color: var(--text-secondary);
  margin-bottom: 12px;
  line-height: 1.65;
}

.case-detail strong {
  color: var(--primary-dark);
}

.faq-section {
  margin-top: 8px;
}

.faq-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: 20px;
}

.faq-item {
  background: var(--light);
  border: 1px solid var(--border);
  border-radius: 12px;
  overflow: hidden;
  transition: all 0.2s;
}
.faq-item:hover {
  border-color: var(--primary);
}

.faq-question {
  width: 100%;
  background: none;
  border: none;
  padding: 18px 20px;
  text-align: left;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 1rem;
  font-weight: 600;
  color: var(--dark);
  font-family: inherit;
}
.faq-question:hover {
  color: var(--primary-dark);
}

.faq-toggle {
  color: var(--gray);
  transition: transform 0.3s;
  font-size: 0.9rem;
}

.faq-item.open .faq-toggle {
  transform: rotate(180deg);
  color: var(--primary);
}

.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease;
  padding: 0 20px;
}

.faq-item.open .faq-answer {
  max-height: 500px;
  padding: 0 20px 18px;
}

.faq-answer div {
  color: var(--text-secondary);
  font-size: 0.95rem;
  line-height: 1.75;
}

.related-tools {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 12px;
  margin-top: 20px;
}

.related-tool {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  background: var(--light);
  border: 1px solid var(--border);
  border-radius: 10px;
  text-decoration: none;
  color: var(--dark);
  transition: all 0.2s;
}
.related-tool:hover {
  border-color: var(--primary);
  background: var(--bg-card);
  transform: translateY(-2px);
}

.related-tool-icon {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  flex-shrink: 0;
}

.related-tool-info h4 {
  font-size: 0.95rem;
  margin: 0 0 2px;
  font-weight: 700;
}
.related-tool-info p {
  font-size: 0.8rem;
  color: var(--gray);
  margin: 0;
  line-height: 1.4;
}

@media (max-width: 991px) {
  .related-tools {
    grid-template-columns: repeat(3, 1fr);
  }
}
@media (max-width: 575px) {
  .related-tools {
    grid-template-columns: 1fr;
  }
}
.why-section {
  background: linear-gradient(135deg, rgba(13, 148, 136, 0.04), rgba(14, 116, 144, 0.04));
  border: 1px solid rgba(13, 148, 136, 0.12);
  border-radius: 20px;
  padding: 40px;
  margin-bottom: 32px;
}
.why-section h2 {
  font-size: 1.6rem;
  margin-bottom: 20px;
  color: var(--dark);
  font-weight: 800;
}

.why-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 20px;
  margin-top: 24px;
}

.why-item {
  background: var(--bg-card);
  border-radius: 14px;
  padding: 22px;
  border: 1px solid var(--border);
}
.why-item-icon {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.3rem;
  margin-bottom: 14px;
}
.why-item h3 {
  font-size: 1.1rem;
  margin-bottom: 8px;
  color: var(--dark);
  font-weight: 700;
}
.why-item p {
  font-size: 0.92rem;
  color: var(--text-secondary);
  margin: 0;
  line-height: 1.65;
}

.notif {
  position: fixed;
  top: 20px;
  right: 20px;
  padding: 14px 20px;
  background: var(--bg-card);
  border-radius: 10px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
  display: none;
  align-items: center;
  gap: 10px;
  z-index: 9999;
  border-left: 4px solid var(--primary);
  max-width: 360px;
}
.notif.success {
  border-left-color: var(--success);
}
.notif.success i {
  color: var(--success);
}
.notif.error {
  border-left-color: var(--danger);
}
.notif.error i {
  color: var(--danger);
}
.notif i {
  font-size: 1.2rem;
}
.notif-text {
  font-size: 0.9rem;
  color: var(--dark);
}

.loader-overlay {
  position: fixed;
  inset: 0;
  background: rgba(255, 255, 255, 0.9);
  display: none;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 14px;
  z-index: 9998;
}
.loader-overlay.active {
  display: flex;
}

.loader-spinner {
  width: 56px;
  height: 56px;
  border: 5px solid var(--border);
  border-top-color: var(--primary);
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}
.loader-text {
  font-weight: 700;
  color: var(--dark);
  font-size: 1.05rem;
}

@media (max-width: 900px) {
  .presets-grid {
    grid-template-columns: repeat(auto-fill, minmax(90px, 1fr));
  }
  .dim-grid {
    grid-template-columns: 1fr;
  }
  .chip {
    padding: 7px 10px;
    font-size: 0.78rem;
  }
}
@media (max-width: 768px) {
  .tool-card {
    padding: 1.5rem;
  }
  .upload-zone {
    padding: 2rem 1rem;
  }
  .upload-zone h3 {
    font-size: 1.2rem;
  }
  .hero-section {
    padding: 100px 0 80px;
  }
  .content-card {
    padding: 24px;
  }
  .case-grid, .why-grid, .steps-grid {
    grid-template-columns: 1fr;
  }
  .act-btn {
    min-width: 100%;
  }
  .preset-card .p-name {
    font-size: 0.78rem;
  }
}
#floatThemeToggle {
  position: fixed;
  top: 100px;
  right: 20px;
  width: 48px;
  height: 48px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 50%;
  cursor: pointer;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-primary);
  font-size: 1.2rem;
  box-shadow: var(--shadow);
  transition: all 0.3s;
}
#floatThemeToggle:hover {
  background: var(--primary);
  color: #fff;
  border-color: var(--primary);
}

#backToTop {
  position: fixed;
  bottom: 30px;
  right: 20px;
  width: 48px;
  height: 48px;
  background: var(--primary);
  border: none;
  border-radius: 50%;
  cursor: pointer;
  z-index: 1000;
  display: none;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 1.2rem;
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.2);
  transition: all 0.3s;
}
#backToTop:hover {
  background: var(--primary-dark);
  transform: translateY(-3px);
}
#backToTop.show {
  display: flex;
}

/*# sourceMappingURL=resize-pdf.css.map */
