/* PDF Copy-Paste Text Fixer — ToolNest mobile-first styles.
   System font stack only (no webfont downloads, PRD 8). */

* { box-sizing: border-box; }

body {
  margin: 0;
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, "Noto Sans Bengali", "Nirmala UI", sans-serif;
  background: #f4f7f5;
  color: #17211d;
  line-height: 1.5;
}

.wrap {
  max-width: 880px;
  margin: 0 auto;
  padding: 12px 14px 32px;
}

header.site {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  padding: 8px 0 4px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 700;
  font-size: 1.05rem;
}

.brand .tool { font-weight: 600; color: #0b6b57; }

.spacer { flex: 1; }

.lang-toggle {
  display: flex;
  border: 1px solid #b9ccc4;
  border-radius: 8px;
  overflow: hidden;
}

.lang-toggle button {
  border: 0;
  background: #fff;
  padding: 10px 14px;
  min-height: 44px;
  cursor: pointer;
  font: inherit;
}

.lang-toggle button[aria-pressed="true"] {
  background: #0b6b57;
  color: #fff;
}

h1 { font-size: 1.45rem; line-height: 1.3; margin: 14px 0 8px; }
h2 { font-size: 1.2rem; margin: 4px 0 6px; }
h3 { font-size: 1.05rem; margin: 16px 0 6px; }
h4 { font-size: 1rem; margin: 12px 0 4px; }

.hint { color: #3c4a44; font-size: 0.92rem; margin: 4px 0 8px; }
.counts { color: #3c4a44; font-size: 0.92rem; margin: 6px 0 2px; min-height: 1.2em; }

.banner {
  padding: 10px 12px;
  border-radius: 8px;
  margin: 10px 0;
}

.banner.warn { background: #fdf3e3; border: 1px solid #e8c98a; }
.banner.info { background: #eef4f1; border: 1px solid #b9ccc4; }
.banner.error { background: #fbe9e9; border: 1px solid #d99a9a; }

.confirm-bar {
  background: #fdf3e3;
  border: 1px solid #e8c98a;
  border-radius: 8px;
  padding: 12px;
  margin: 10px 0;
}

.card {
  background: #fff;
  border: 1px solid #d8e2dd;
  border-radius: 12px;
  padding: 16px;
  margin: 14px 0;
}

.panes {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0;
}

@media (min-width: 720px) {
  .panes { grid-template-columns: 1fr 1fr; gap: 14px; }
  .panes .card { margin: 14px 0; }
}

label { display: block; font-weight: 600; margin: 6px 0 4px; }

input[type="text"], textarea, select {
  width: 100%;
  padding: 11px 12px;
  min-height: 44px;
  border: 1px solid #b9ccc4;
  border-radius: 8px;
  font: inherit;
  background: #fff;
  color: inherit;
}

textarea { resize: vertical; overflow-wrap: anywhere; white-space: pre-wrap; }

textarea[readonly] { background: #f4f7f5; }

select { width: auto; min-width: 64px; }

input:focus-visible, textarea:focus-visible, button:focus-visible,
a:focus-visible, summary:focus-visible, select:focus-visible,
.file-btn:focus-visible {
  outline: 3px solid #f2a93b;
  outline-offset: 1px;
}

fieldset.group {
  border: 1px solid #d8e2dd;
  border-radius: 10px;
  padding: 10px 12px 14px;
  margin: 10px 0 4px;
}

fieldset.group legend { font-weight: 700; padding: 0 6px; }

.choice {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-weight: 500;
  margin: 6px 14px 6px 0;
  min-height: 44px;
  cursor: pointer;
}

.choice input[type="checkbox"], .choice input[type="radio"] { width: 20px; height: 20px; }

.row {
  display: flex;
  gap: 8px;
  align-items: center;
  flex-wrap: wrap;
  margin: 10px 0;
}

.wrap-row { row-gap: 2px; }

.btn {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-height: 44px;
  padding: 9px 16px;
  border: 1px solid #0b6b57;
  border-radius: 8px;
  background: #fff;
  color: #0b6b57;
  font: inherit;
  font-weight: 600;
  cursor: pointer;
  text-decoration: none;
}

.btn.primary { background: #0b6b57; color: #fff; }
.btn.small-btn { min-height: 44px; padding: 7px 12px; }
.btn:disabled { opacity: 0.45; cursor: not-allowed; }
.file-btn { cursor: pointer; margin: 0; }

.plain-list { margin: 6px 0 10px; padding-left: 20px; }
.plain-list li { margin: 4px 0; overflow-wrap: anywhere; }
.mono { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 0.92rem; }

.stat-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 8px;
  margin: 10px 0;
}

.stat {
  border: 1px solid #d8e2dd;
  border-radius: 8px;
  padding: 8px 10px;
  background: #f8faf9;
}

.stat .stat-label { color: #3c4a44; font-size: 0.88rem; display: block; }
.stat .stat-value { font-weight: 700; font-size: 1.05rem; overflow-wrap: anywhere; }

.no-changes {
  background: #eef4f1;
  border-left: 4px solid #0b6b57;
  padding: 10px 12px;
  border-radius: 6px;
  margin: 10px 0;
}

.flag-box {
  border-left: 4px solid #d98a00;
  padding: 6px 10px;
  margin: 6px 0;
  background: #fdf8ec;
  overflow-wrap: anywhere;
}

details {
  border: 1px solid #d8e2dd;
  border-radius: 8px;
  padding: 10px 12px;
  margin: 8px 0;
}

summary { font-weight: 600; cursor: pointer; min-height: 44px; display: flex; align-items: center; }

footer { color: #3c4a44; font-size: 0.92rem; margin-top: 18px; }

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

@media (max-width: 480px) {
  h1 { font-size: 1.25rem; }
  .card { padding: 13px; }
}
