.container {
  max-width: 1000px;
  margin: 40px auto;
  font-family: system-ui, sans-serif;
  background: var(--color-cards);
  border: 1px solid rgba(15, 23, 42, 0.04);
  padding: 1rem;
  border-radius: 10px;
  box-shadow: 0 8px 20px rgba(15, 23, 42, 0.05);
}

.container h3 { margin: 0 0 .75rem; }
.container h3.section-title { margin-top: 30px; }

/* ================= SETTINGS ================= */
.settings-card {
  background: rgba(37, 99, 235, 0.06);
  border: 1px solid rgba(37, 99, 235, 0.12);
  padding: 20px;
  border-radius: 12px;
  text-align: center;
}

.settings-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
  gap: 15px;
  margin-top: 5px;
  text-align: left;
}

.settings-grid label {
  display: flex;
  flex-direction: column;
  gap: 4px;
  font-size: 14px;
}

.settings-grid select,
.settings-grid input[type="number"] {
  padding: 6px;
  font: inherit;
}

.settings-grid input[type="color"] { height: 34px; padding: 2px; }

/* ================= DROP ZONE ================= */
#ir-drop {
  margin-top: 30px;
  border: 2px dashed #ccc;
  border-radius: 14px;
  padding: 30px;
  background: rgba(37, 99, 235, 0.06);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 15px;
  position: relative;
  transition: border-color 0.2s ease, background 0.2s ease;
}

#ir-drop.drag-over {
  border-color: #2563eb;
  background: rgba(37, 99, 235, 0.12);
}

#ir-browse {
  padding: 10px 18px;
  cursor: pointer;
  z-index: 10;
  position: relative;
  border-radius: 0.5em;
}

#ir-drop > p { pointer-events: none; margin: 0; }
.file-name-note { font-size: 13px; color: #334155; word-break: break-all; }

/* ================= ERRORS ================= */
.warning-panel {
  margin-top: 20px;
  padding: 12px;
  border-radius: 10px;
  background: #fff3f3;
  border: 1px solid #e0a1a1;
  font-size: 13px;
}

[hidden] { display: none !important; }

/* ================= CROP ================= */
.crop-help { font-size: 13px; color: #475569; margin: 0 0 12px; }
.crop-wrap { text-align: center; }
.crop-stage {
  position: relative;
  display: inline-block;
  max-width: 100%;
  line-height: 0;
  overflow: hidden;
  border-radius: 6px;
  user-select: none;
}
.crop-stage canvas { display: block; max-width: 100%; height: auto; }
.crop-box {
  position: absolute;
  box-sizing: border-box;
  border: 2px solid #fff;
  box-shadow: 0 0 0 9999px rgba(15, 23, 42, 0.5);
  cursor: move;
  touch-action: none;
}
.crop-handle {
  position: absolute;
  right: 0;
  bottom: 0;
  width: 18px;
  height: 18px;
  background: #2563eb;
  border: 2px solid #fff;
  border-radius: 3px;
  cursor: nwse-resize;
  touch-action: none;
}
.zoom-row {
  display: flex;
  flex-direction: column;
  gap: 4px;
  max-width: 320px;
  margin: 14px auto 0;
  font-size: 14px;
}

/* ================= SUMMARY + RESULT ================= */
.summary-box {
  background: #f5f8ff;
  border: 1px solid #dbe4ff;
  border-radius: 10px;
  padding: 12px 16px;
  font-size: 14px;
  color: #334155;
  line-height: 1.6;
}

.pages-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 18px;
  margin-top: 16px;
}

.page-card {
  background: rgba(37, 99, 235, 0.06);
  border: 1px solid rgba(37, 99, 235, 0.12);
  border-radius: 10px;
  padding: 10px;
}

.page-card img {
  display: block;
  max-width: 100%;
  max-height: 420px;
  margin: 0 auto;
  background: #fff;
  border-radius: 4px;
  box-shadow: 0 2px 8px rgba(15, 23, 42, 0.12);
}

/* ================= ACTIONS ================= */
.convert-wrapper {
  margin-top: 30px;
  text-align: center;
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  justify-content: center;
}

.convert-wrapper .btn,
.convert-wrapper button {
  padding: 12px 20px;
  border-radius: 0.5em;
  font-size: 16px;
  cursor: pointer;
}

.convert-wrapper button:disabled { opacity: 0.5; cursor: not-allowed; }

.print-note {
  margin: 14px 0 0;
  text-align: center;
  font-size: 13px;
  color: #475569;
}

/* ================= SEO CONTENT ================= */
.seo-content {
  max-width: 1000px;
  margin: 40px auto;
  padding: 24px;
  background: var(--color-cards);
  border: 1px solid rgba(15, 23, 42, 0.04);
  border-radius: 12px;
  box-shadow: 0 8px 20px rgba(15, 23, 42, 0.05);
  font-family: system-ui, sans-serif;
  line-height: 1.65;
  color: #0f172a;
}

.seo-content h1 { font-size: 1.75rem; margin-bottom: 1rem; line-height: 1.3; }
.seo-content h2 { font-size: 1.25rem; margin: 2rem 0 0.75rem; line-height: 1.35; }
.seo-content p { margin-bottom: 1rem; font-size: 15px; color: #334155; }
.seo-content ul, .seo-content ol { margin: 0.75rem 0 1.25rem 1.25rem; padding: 0; }
.seo-content li { margin-bottom: 0.5rem; font-size: 15px; color: #334155; }
.seo-content strong { color: #0f172a; }

.how-it-works {
  margin: 30px 0;
  padding: 5px 20px;
  background: #f5f8ff;
  border: 1px solid #dbe4ff;
  border-radius: 10px;
  font-family: system-ui, sans-serif;
}

@media (max-width: 640px) {
  .seo-content { padding: 18px; }
  .seo-content h1 { font-size: 1.5rem; }
  .seo-content h2 { font-size: 1.15rem; }
}