/*
  PDF Merger — first-party styles only.
  AdSense auto ads: do not set overflow:hidden on html/body,
  do not style ins.adsbygoogle or Google iframes,
  keep z-index of site chrome in the single digits,
  and do not use a full-viewport fixed overlay.
*/

:root {
  --navy: #1b2a4a;
  --navy-2: #24375f;
  --coral: #e74c3c;
  --coral-dark: #c93d2f;
  --bg: #f6f7fb;
  --card: #ffffff;
  --muted: #5c6b7a;
  --line: #e6e9ef;
  --text: #1f2933;
  --ok: #1f8a5b;
  --ok-bg: #e9f7f0;
  --err: #b42318;
  --err-bg: #fdecea;
  --shadow: 0 10px 30px rgba(27, 42, 74, 0.08);
  --radius: 16px;
  --font: "Segoe UI", system-ui, -apple-system, Roboto, "Helvetica Neue", Arial, sans-serif;
}

html {
  box-sizing: border-box;
  scroll-behavior: smooth;
}

*,
*::before,
*::after {
  box-sizing: inherit;
}

body {
  margin: 0;
  font-family: var(--font);
  color: var(--text);
  background: var(--bg);
  line-height: 1.6;
}

img,
svg {
  max-width: 100%;
}

a {
  color: var(--coral-dark);
  text-decoration-thickness: 1px;
  text-underline-offset: 2px;
}

a:hover {
  color: var(--navy);
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: absolute;
  left: 12px;
  top: -40px;
  background: var(--navy);
  color: #fff;
  padding: 8px 12px;
  z-index: 5;
}

.skip-link:focus {
  top: 12px;
}

.u-hidden {
  display: none;
}

.shell {
  width: min(1080px, calc(100% - 32px));
  margin-inline: auto;
}

.site-header {
  background: #fff;
  border-bottom: 1px solid var(--line);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  padding: 14px 0;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--navy);
  text-decoration: none;
  font-weight: 700;
  font-size: 1.15rem;
}

.brand:hover {
  color: var(--navy);
}

.brand-mark {
  display: flex;
}

.nav-toggle {
  display: none;
  border: 1px solid var(--line);
  background: #fff;
  border-radius: 10px;
  width: 44px;
  height: 40px;
  cursor: pointer;
}

.nav-toggle-bars,
.nav-toggle-bars::before,
.nav-toggle-bars::after {
  display: block;
  width: 18px;
  height: 2px;
  background: var(--navy);
  margin: 0 auto;
  position: relative;
  content: "";
}

.nav-toggle-bars::before {
  position: absolute;
  top: -6px;
}

.nav-toggle-bars::after {
  position: absolute;
  top: 6px;
}

.site-nav {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.site-nav a {
  color: var(--navy);
  text-decoration: none;
  padding: 8px 12px;
  border-radius: 999px;
  font-weight: 600;
}

.site-nav a:hover,
.site-nav a.is-active {
  background: #f3f4f8;
  color: var(--navy);
}

.hero {
  padding: 48px 0 12px;
  text-align: center;
}

.eyebrow {
  display: inline-block;
  margin: 0 0 10px;
  color: var(--coral-dark);
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  font-size: 0.78rem;
}

.hero h1,
.page h1 {
  margin: 0 0 12px;
  color: var(--navy);
  font-size: clamp(1.8rem, 4vw, 2.7rem);
  line-height: 1.15;
}

.lede {
  margin: 0 auto;
  max-width: 42rem;
  color: var(--muted);
  font-size: 1.08rem;
}

.tool-section {
  padding: 20px 0 8px;
}

.workbench {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 24px;
  box-shadow: var(--shadow);
  padding: 22px;
}

.workbench-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: baseline;
  flex-wrap: wrap;
  margin-bottom: 16px;
}

.workbench-head h2 {
  margin: 0;
  color: var(--navy);
  font-size: 1.15rem;
}

.workbench-limits,
.privacy-note,
.muted {
  color: var(--muted);
  font-size: 0.95rem;
}

.privacy-note {
  text-align: center;
  margin: 14px 0 0;
}

.dropzone {
  position: relative;
  border: 2px dashed #c9d1de;
  border-radius: var(--radius);
  background: #fbfcfe;
  min-height: 220px;
  display: grid;
  place-items: center;
  transition: border-color 0.15s ease, background 0.15s ease;
}

.dropzone.is-dragover {
  border-color: var(--coral);
  background: #fff6f5;
}

.file-input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  overflow: hidden;
}

.dropzone-label {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  padding: 28px 16px;
  text-align: center;
  color: var(--navy);
}

.dropzone-title {
  font-size: 1.2rem;
  font-weight: 700;
}

.dropzone-hint {
  color: var(--muted);
}

.link-like {
  color: var(--coral-dark);
  font-weight: 700;
}

.file-list {
  list-style: none;
  margin: 16px 0 0;
  padding: 0;
  display: grid;
  gap: 10px;
}

.file-row {
  display: grid;
  grid-template-columns: auto 1fr auto auto;
  gap: 10px;
  align-items: center;
  background: #fbfcfe;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 10px 12px;
}

.file-row.is-dragging {
  opacity: 0.55;
}

.file-handle {
  width: 28px;
  height: 28px;
  border: 0;
  background: transparent;
  color: #8a97a8;
  cursor: grab;
  font-size: 1.1rem;
  line-height: 1;
}

.file-meta strong {
  display: block;
  color: var(--navy);
  font-size: 0.95rem;
  word-break: break-word;
}

.file-meta span {
  color: var(--muted);
  font-size: 0.85rem;
}

.file-controls {
  display: flex;
  gap: 6px;
}

.icon-btn {
  border: 1px solid var(--line);
  background: #fff;
  border-radius: 8px;
  width: 36px;
  height: 36px;
  cursor: pointer;
  color: var(--navy);
}

.icon-btn:hover:not(:disabled) {
  border-color: var(--navy);
}

.icon-btn:disabled {
  opacity: 0.4;
  cursor: default;
}

.icon-btn.is-danger:hover:not(:disabled) {
  border-color: var(--err);
  color: var(--err);
}

.tool-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 16px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 0 18px;
  border-radius: 999px;
  border: 1px solid transparent;
  font: inherit;
  font-weight: 700;
  cursor: pointer;
  text-decoration: none;
}

.btn:disabled {
  opacity: 0.5;
  cursor: default;
}

.btn-primary {
  background: var(--coral);
  color: #fff;
}

.btn-primary:hover:not(:disabled) {
  background: var(--coral-dark);
  color: #fff;
}

.btn-ghost {
  background: #fff;
  color: var(--navy);
  border-color: var(--line);
}

.btn-ghost:hover:not(:disabled) {
  border-color: var(--navy);
  color: var(--navy);
}

.progress-panel,
.success-panel {
  padding: 12px 0 4px;
}

.progress-label,
.success-title {
  margin: 0 0 10px;
  font-weight: 700;
  color: var(--navy);
}

.progress {
  height: 10px;
  background: #edf0f5;
  border-radius: 999px;
  overflow: hidden;
}

.progress-fill {
  display: block;
  height: 100%;
  width: 0;
  background: var(--coral);
}

.success-panel {
  background: var(--ok-bg);
  border-radius: var(--radius);
  padding: 18px;
}

.success-meta {
  margin: 0 0 12px;
  color: var(--muted);
}

.alert {
  border-radius: 12px;
  padding: 12px 14px;
  margin-bottom: 12px;
}

.alert-error {
  background: var(--err-bg);
  color: var(--err);
}

.band {
  padding: 48px 0;
}

.band-alt {
  background: #fff;
  border-block: 1px solid var(--line);
}

.band h2,
.page h2 {
  margin: 0 0 18px;
  color: var(--navy);
  font-size: 1.55rem;
}

.steps {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 16px;
  grid-template-columns: repeat(3, 1fr);
}

.step-card,
.feature-card,
.callout {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 20px;
}

.band-alt .feature-card,
.band-alt .callout {
  background: var(--bg);
}

.step-num {
  display: inline-grid;
  place-items: center;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--navy);
  color: #fff;
  font-weight: 700;
  margin-bottom: 10px;
}

.step-card h3,
.feature-card h3,
.callout h3,
.page h3 {
  margin: 0 0 8px;
  color: var(--navy);
}

.step-card p,
.feature-card p {
  margin: 0;
  color: var(--muted);
}

.band-link {
  margin: 18px 0 0;
}

.feature-grid {
  display: grid;
  gap: 16px;
  grid-template-columns: repeat(2, 1fr);
}

.split {
  display: grid;
  grid-template-columns: 1.4fr 0.8fr;
  gap: 24px;
  align-items: start;
}

.callout ul {
  margin: 0;
  padding-left: 18px;
  color: var(--muted);
}

.faq-list {
  display: grid;
  gap: 10px;
}

.faq-item {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 4px 16px 4px;
}

.band-alt .faq-item {
  background: var(--bg);
}

.faq-item summary {
  cursor: pointer;
  font-weight: 700;
  color: var(--navy);
  padding: 12px 0;
}

.faq-item p {
  margin: 0 0 14px;
  color: var(--muted);
}

.prose {
  max-width: 46rem;
}

.prose p,
.prose li {
  color: var(--text);
}

.seo-article .prose {
  max-width: 46rem;
  margin-inline: auto;
}

.page {
  padding: 32px 0 56px;
}

.crumbs {
  display: flex;
  gap: 8px;
  color: var(--muted);
  font-size: 0.92rem;
  margin-bottom: 16px;
}

.crumbs a {
  color: var(--muted);
}

.guide-steps {
  padding-left: 20px;
}

.contact-email {
  font-size: 1.2rem;
  font-weight: 700;
}

.site-footer {
  background: var(--navy);
  color: #d7deea;
  padding: 36px 0 28px;
  margin-top: 24px;
}

.footer-inner {
  display: grid;
  gap: 18px;
}

.footer-title {
  margin: 0 0 6px;
  color: #fff;
  font-weight: 700;
}

.footer-copy,
.footer-legal {
  margin: 0;
  color: #b7c2d4;
}

.footer-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 16px;
}

.footer-nav a,
.site-footer a {
  color: #fff;
}

.footer-legal {
  font-size: 0.9rem;
}

@media (max-width: 860px) {
  .steps,
  .feature-grid,
  .split {
    grid-template-columns: 1fr;
  }

  .nav-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
  }

  .site-nav {
    display: none;
    width: 100%;
    flex-direction: column;
  }

  .site-nav.is-open {
    display: flex;
  }
}

@media (max-width: 640px) {
  .hero {
    padding-top: 28px;
    text-align: left;
  }

  .lede {
    margin: 0;
  }

  .file-row {
    grid-template-columns: auto 1fr;
  }

  .file-controls {
    grid-column: 1 / -1;
    justify-content: flex-end;
  }

  .tool-actions {
    justify-content: stretch;
  }

  .tool-actions .btn {
    flex: 1;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .dropzone,
  .progress-fill {
    transition: none;
  }
}
