/* HuntPDF — shared tool page styles */
:root {
  --brand: #DC2626;
  --brand-dark: #B91C1C;
  --brand-soft: #FEE7E7;
  --bg: #FFFFFF;
  --surface: #FFFFFF;
  --text: #0A0A0A;
  --text-2: #3A3A38;
  --text-3: #6A6A66;
  --border: rgba(0,0,0,0.12);
  --r-md: 12px;
  --r-lg: 16px;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; background: var(--bg); color: var(--text); font-family: -apple-system, "Segoe UI", Roboto, "Helvetica Neue", sans-serif; -webkit-font-smoothing: antialiased; }

/* Sticky footer: body fills viewport, content grows, footer sits at bottom */
html, body { height: 100%; }
body { display: flex; flex-direction: column; min-height: 100vh; }
#hp-tool-main { flex: 1 0 auto; }

/* Centered content column for all tool/sub pages (header stays full-width).
   Everything between the header and footer sits in a comfortable centered
   column with generous space on all four sides. */
.hp-header ~ section,
.hp-header ~ div,
.hp-header ~ main,
.hp-header ~ form {
  max-width: 1100px;
  margin-left: auto;
  margin-right: auto;
  padding-left: 48px;
  padding-right: 48px;
  box-sizing: border-box;
}
/* Push first hero section down ~½ inch from header (matches Word-to-PDF look) */
.hp-header ~ section:first-of-type { margin-top: 78px; }
.tool-footer { margin-top: 0; }

@media (max-width: 900px) {
  .hp-header ~ section,
  .hp-header ~ div,
  .hp-header ~ main,
  .hp-header ~ form { padding-left: 24px; padding-right: 24px; }
  .hp-header ~ section:first-of-type { margin-top: 48px; }
}
@media (max-width: 700px) {
  .hp-header ~ section,
  .hp-header ~ div,
  .hp-header ~ main,
  .hp-header ~ form { padding-left: 14px; padding-right: 14px; }
  .hp-header ~ section:first-of-type { margin-top: 28px; }
  .tool-footer { margin-top: 28px; }
}

.container { max-width: 880px; margin: 0 auto; padding: 0 20px; }

/* Top bar (simple, links back to home) */
.topbar { display: flex; align-items: center; justify-content: space-between; padding: 16px 20px; max-width: 1240px; margin: 0 auto; border-bottom: 1px solid var(--border); }
.topbar .brand { display: inline-flex; align-items: center; gap: 8px; text-decoration: none; color: var(--text); }
.topbar .brand img { height: 28px; width: auto; }
.topbar .brand strong { font-size: 17px; font-weight: 700; letter-spacing: -0.3px; }
.topbar .back { font-size: 14px; color: var(--text-2); text-decoration: none; font-weight: 500; }
.topbar .back:hover { color: var(--brand); }

/* Hero / heading — tighter padding to match Word-to-PDF */
.tool-hero { text-align: center; padding: 28px 20px 14px; }
.tool-hero h1 { font-size: clamp(28px, 4.5vw, 40px); font-weight: 700; letter-spacing: -1px; margin: 0 0 6px; }
.tool-hero p { color: var(--text-2); font-size: 16px; margin: 0 auto; max-width: 760px; line-height: 1.5; }

/* Drop zone — Word-to-PDF dimensions: wider (816px), generous padding */
.dropzone {
  margin: 12px auto;
  max-width: 816px;
  border: 2px dashed var(--border);
  background: var(--surface);
  border-radius: var(--r-lg);
  padding: 56px 78px;
  text-align: center;
  cursor: pointer;
  transition: border-color .2s, background .2s;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}
.dropzone:hover, .dropzone.drag-over { border-color: var(--brand); background: #FFF5F5; }
.dropzone .icon { font-size: 44px; line-height: 1; margin-bottom: 12px; color: var(--brand); }
.dropzone h3 { margin: 0 0 6px; font-size: 18px; font-weight: 600; }
.dropzone p { margin: 0; color: var(--text-3); font-size: 14px; }
.dropzone input[type=file] { display: none; }

/* File list — same max-width as dropzone for alignment */
.file-list { max-width: 816px; margin: 16px auto 0; }
.file-item { display: flex; align-items: center; gap: 12px; padding: 10px 14px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--r-md); margin-bottom: 8px; font-size: 14px; }
.file-item .name { flex: 1; font-weight: 500; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.file-item .size { color: var(--text-3); font-size: 12px; }
.file-item .remove { background: none; border: 0; color: var(--text-3); cursor: pointer; font-size: 18px; padding: 0 4px; }
.file-item .remove:hover { color: var(--brand); }

/* Action button */
.actions { text-align: center; margin: 24px 0 40px; }
.btn-primary {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 14px 32px;
  background: var(--brand); color: #fff;
  border: 0; border-radius: 999px;
  font-size: 16px; font-weight: 600; font-family: inherit;
  cursor: pointer;
  box-shadow: 0 4px 14px rgba(220, 38, 38, .3);
  transition: background .15s, transform .15s, box-shadow .15s;
}
.btn-primary:hover { background: var(--brand-dark); transform: translateY(-1px); box-shadow: 0 6px 18px rgba(220,38,38,.4); }
.btn-primary:disabled { opacity: .5; cursor: not-allowed; transform: none; }
.btn-secondary {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 10px 18px; background: var(--surface); color: var(--text);
  border: 1px solid var(--border); border-radius: 999px; cursor: pointer;
  font-family: inherit; font-size: 14px; font-weight: 500;
}
.btn-secondary:hover { background: var(--brand-soft); color: var(--brand); border-color: var(--brand); }

/* Options panel */
.options { max-width: 720px; margin: 0 auto; padding: 16px 20px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--r-md); margin-bottom: 16px; }
.options label { display: block; margin-bottom: 8px; font-weight: 500; color: var(--text-2); font-size: 14px; }
.options input[type=text], .options select, .options textarea {
  width: 100%; padding: 10px 12px; border: 1px solid var(--border); border-radius: 8px;
  font-family: inherit; font-size: 14px; background: var(--bg); color: var(--text);
}
.options input:focus, .options select:focus, .options textarea:focus { outline: 0; border-color: var(--brand); }

/* Status */
.status { text-align: center; margin: 20px 0; font-size: 14px; }
.status.ok { color: #047857; }
.status.err { color: #B91C1C; }
.spinner { display: inline-block; width: 18px; height: 18px; border: 2px solid #ddd; border-top-color: var(--brand); border-radius: 50%; animation: spin 0.7s linear infinite; vertical-align: middle; margin-right: 6px; }
@keyframes spin { to { transform: rotate(360deg); } }

/* Result box — the "Your file is ready" success screen, standardized across all tools */
.result {
  max-width: 816px;
  margin: 24px auto;
  padding: 36px 28px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  text-align: center;
  display: none;
  box-shadow: 0 8px 30px rgba(0,0,0,0.06);
}
.result.show { display: block; }
.result .ok-icon { font-size: 38px; color: #10B981; margin-bottom: 10px; }
.result .result-icon {
  width: 76px; height: 76px; margin: 0 auto 16px;
  background: #ECFDF5; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
}
.result h3 { margin: 0 0 6px; font-size: 21px; font-weight: 700; }
.result p { color: var(--text-3); font-size: 13.5px; margin: 0 0 22px; }
.result a.download {
  display: inline-flex; align-items: center; justify-content: center; gap: 9px;
  background: var(--brand); color: #fff; width: 100%; max-width: 360px;
  padding: 15px 24px; border-radius: 12px; text-decoration: none;
  font-weight: 600; font-size: 16px;
  box-shadow: 0 6px 18px rgba(220,38,38,.32);
  transition: background .15s, transform .15s;
}
.result a.download:hover { background: var(--brand-dark); transform: translateY(-1px); }

/* Share row */
.result .share-row {
  display: flex; gap: 10px; margin: 18px auto 0; max-width: 360px;
}
.result .share-btn {
  flex: 1; display: flex; flex-direction: column; align-items: center; gap: 5px;
  padding: 12px 6px; border: 1px solid var(--border); border-radius: 11px;
  background: var(--surface); color: var(--text-2); cursor: pointer;
  font-family: inherit; font-size: 11.5px; font-weight: 600;
  transition: all .15s;
}
.result .share-btn svg { display: block; }
.result .share-btn:hover { transform: translateY(-2px); }
.result .share-btn.wa:hover { border-color: #25D366; color: #25D366; background: #F0FFF4; }
.result .share-btn.em:hover { border-color: #4285F4; color: #4285F4; background: #EFF5FF; }
.result .share-btn.cp:hover { border-color: var(--brand); color: var(--brand); background: #FFF5F5; }
.result .share-btn.copied { border-color: #10B981; color: #10B981; background: #ECFDF5; }

.result .result-again {
  margin-top: 22px; background: none; border: 0; color: var(--text-3);
  font-family: inherit; font-size: 13px; cursor: pointer; text-decoration: underline;
}
.result .result-again:hover { color: var(--brand); }
.result pre { text-align: left; background: var(--bg); border: 1px solid var(--border); padding: 16px; border-radius: 8px; max-height: 400px; overflow: auto; font-size: 13px; }

/* Footer — compact (½ inch tall, sits at bottom of viewport even when content is short) */
footer.tool-footer {
  flex-shrink: 0;
  max-height: 48px;
  text-align: center;
  padding: 6px 16px;
  color: #000000;
  font-size: 11px;
  border-top: 1px solid var(--border);
  margin-top: 24px;
  background: #FFFFFF;
  line-height: 1.4;
  display: flex; align-items: center; justify-content: center; flex-wrap: wrap; gap: 6px;
}
footer.tool-footer a { color: #000000; margin: 0 4px; text-decoration: none; font-size: 11px; }
footer.tool-footer a:hover { color: var(--brand); }
footer.tool-footer br { display: none; }
footer.tool-footer a::after { content: "·"; margin-left: 4px; color: var(--border); }
footer.tool-footer a:last-of-type::after { content: ""; }

@media (max-width: 600px) {
  .dropzone { padding: 36px 20px; }
  .tool-hero { padding: 20px 16px 12px; }
}
@media (max-width: 900px) and (min-width: 601px) {
  .dropzone { padding: 44px 36px; }
}

/* ----- Ad slots ----- */
.hp-ad { display:block; margin: 18px auto; max-width: 100%; min-height: 90px; clear: both; }
.hp-ad-footer { max-width: 970px; margin: 30px auto 14px; }
.hp-ad-tool-result { max-width: 728px; margin: 20px auto; }
.hp-ad-all-tools  { max-width: 970px; margin: 20px auto 30px; }
.hp-ad-sidebar    { min-height: 250px; max-width: 300px; }

/* Sidebar layout (used on homepage / all-tools / pricing) */
.hp-with-sidebar { display: grid; grid-template-columns: 1fr 300px; gap: 24px; max-width: 1340px;
  margin: 0 auto; align-items: start; }
.hp-with-sidebar > main { min-width: 0; }
.hp-with-sidebar > aside.hp-sidebar { position: sticky; top: 80px; }
@media (max-width: 1100px) {
  .hp-with-sidebar { grid-template-columns: 1fr; }
  .hp-with-sidebar > aside.hp-sidebar { position: static; max-width: 100%; }
  .hp-ad-sidebar { max-width: 728px; min-height: 90px; margin: 0 auto; }
}

/* Hide ads while loading (avoid layout shift on Pro users) */
.hp-ad:empty { min-height: 0; }

/* "What's next?" follow-up tool grid on download/result screen */
.next-tools-section {
  margin: 28px auto 18px;
  max-width: 900px;
  padding-top: 22px;
  border-top: 1px solid #F1F5F9;
}
.next-tools-title {
  font-size: 13px;
  font-weight: 600;
  color: #475569;
  text-align: center;
  margin-bottom: 14px;
  letter-spacing: 0.2px;
}
.next-tools-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 8px;
}
@media (max-width: 760px) { .next-tools-grid { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 480px) { .next-tools-grid { grid-template-columns: repeat(2, 1fr); } }

.next-tool {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 14px 8px;
  background: #FFFFFF;
  border: 1px solid #E5E7EB;
  border-radius: 10px;
  text-decoration: none;
  color: #374151;
  transition: all .15s;
  min-height: 70px;
}
.next-tool:hover {
  border-color: #DC2626;
  background: linear-gradient(135deg, #FFFBFB, #FEF2F2);
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(220, 38, 38, 0.12);
}
.next-tool .nt-ico {
  font-size: 22px;
  line-height: 1;
}
.next-tool .nt-lbl {
  font-size: 11.5px;
  font-weight: 600;
  text-align: center;
  line-height: 1.2;
}

/* ===== Shared Trust bar (injected on tool pages) ===== */
.trust{padding:10px 0 34px}
.trust .container{max-width:1120px;margin:0 auto;padding:0 20px}
.trust-grid{display:grid;grid-template-columns:repeat(4,1fr);gap:14px}
.trust-card{display:flex;align-items:flex-start;gap:13px;background:#fff;border:1px solid #ECECEC;border-radius:16px;padding:18px;box-shadow:0 1px 2px rgba(15,23,42,.04);transition:transform .18s,box-shadow .18s,border-color .18s}
.trust-card:hover{transform:translateY(-3px);box-shadow:0 10px 26px rgba(15,23,42,.08);border-color:rgba(220,38,38,.35)}
.trust-ic{flex:0 0 auto;width:42px;height:42px;border-radius:12px;display:grid;place-items:center;color:#DC2626;background:linear-gradient(135deg,#FEE7E7,#FFF4F0)}
.trust-ic svg{width:22px;height:22px}
.trust-tx h3{margin:1px 0 3px;font-size:14.5px;font-weight:700;color:#0A0A0A}
.trust-tx p{margin:0;font-size:12.5px;line-height:1.45;color:#5A5A57}
@media(max-width:900px){.trust-grid{grid-template-columns:repeat(2,1fr)}}
@media(max-width:520px){.trust-grid{grid-template-columns:1fr}}
