/* PDF Craft — paper studio theme
   White paper + coral accent + slate ink. No external fonts. */

:root {
  --paper: #faf7f2;
  --paper-2: #f3ede5;
  --card: #ffffff;
  --ink: #1b2430;
  --slate: #5b6b7c;
  --slate-2: #8794a3;
  --line: #e7dfd4;
  --line-strong: #d5cabc;
  --coral: #ff6a4d;
  --coral-dark: #e14f31;
  --coral-soft: #fff0ec;
  --teal: #2f6f6a;
  --teal-soft: #eaf4f2;
  --ok: #2f7d5c;
  --warn: #b45309;
  --radius: 16px;
  --radius-sm: 10px;
  --shadow: 0 1px 2px rgba(27, 36, 48, 0.04), 0 8px 24px rgba(27, 36, 48, 0.06);
  --shadow-lift: 0 2px 4px rgba(27, 36, 48, 0.05), 0 18px 40px rgba(27, 36, 48, 0.09);
  --sans: -apple-system, BlinkMacSystemFont, "Segoe UI", "Inter", "Helvetica Neue", Arial,
    "Liberation Sans", "DejaVu Sans", "Apple SD Gothic Neo", "Noto Sans CJK KR", "Malgun Gothic",
    sans-serif;
  --mono: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  --max: 1120px;
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--sans);
  color: var(--ink);
  background-color: var(--paper);
  background-image: radial-gradient(rgba(27, 36, 48, 0.055) 1px, transparent 1px);
  background-size: 22px 22px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3 { line-height: 1.18; letter-spacing: -0.02em; margin: 0; }
p { margin: 0; }
a { color: var(--coral-dark); text-decoration: none; }
a:hover { text-decoration: underline; }
img { max-width: 100%; }
button { font-family: inherit; }

.wrap { width: 100%; max-width: var(--max); margin: 0 auto; padding: 0 20px; }

/* ---------- header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 40;
  background: rgba(250, 247, 242, 0.9);
  backdrop-filter: saturate(160%) blur(10px);
  border-bottom: 1px solid var(--line);
}
.header-inner { display: flex; align-items: center; gap: 18px; height: 64px; }
.brand { display: inline-flex; align-items: center; gap: 9px; color: var(--ink); font-weight: 800; letter-spacing: -0.03em; font-size: 18px; }
.brand:hover { text-decoration: none; }
.brand-mark {
  width: 30px; height: 30px; border-radius: 8px;
  background: linear-gradient(145deg, var(--coral) 0%, #ff9166 100%);
  display: inline-flex; align-items: center; justify-content: center;
  box-shadow: 0 4px 10px rgba(255, 106, 77, 0.35);
}
.brand-mark svg { width: 18px; height: 18px; display: block; }
.nav { display: flex; gap: 22px; margin-left: 14px; }
.nav a { color: var(--slate); font-size: 14.5px; font-weight: 550; }
.nav a:hover { color: var(--ink); text-decoration: none; }
.header-right { margin-left: auto; display: flex; align-items: center; gap: 10px; }
.lang-toggle {
  display: inline-flex; align-items: center; gap: 6px;
  border: 1px solid var(--line-strong); background: #fff; color: var(--ink);
  padding: 7px 12px; border-radius: 999px; font-size: 13px; font-weight: 700;
  cursor: pointer; transition: border-color .15s, box-shadow .15s;
}
.lang-toggle:hover { border-color: var(--coral); box-shadow: 0 0 0 3px var(--coral-soft); }
.lang-toggle .dot { width: 6px; height: 6px; border-radius: 50%; background: var(--coral); }

/* ---------- hero ---------- */
.hero { padding: 52px 0 26px; text-align: center; }
.eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  background: var(--teal-soft); color: var(--teal);
  border: 1px solid #cfe6e2; border-radius: 999px;
  font-size: 12.5px; font-weight: 700; letter-spacing: .02em;
  padding: 6px 13px; margin-bottom: 20px;
}
.eyebrow svg { width: 14px; height: 14px; }
.hero h1 { font-size: clamp(30px, 5.2vw, 52px); font-weight: 800; max-width: 820px; margin: 0 auto; }
.hero h1 .hl {
  background: linear-gradient(180deg, transparent 62%, rgba(255, 106, 77, 0.28) 62%);
  padding: 0 2px;
}
.hero p.lede { color: var(--slate); font-size: clamp(15px, 2.1vw, 18.5px); max-width: 660px; margin: 18px auto 0; }
.trust-row { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px 10px; margin-top: 24px; }
.trust {
  display: inline-flex; align-items: center; gap: 7px;
  font-size: 12.5px; font-weight: 650; color: var(--slate);
  background: #fff; border: 1px solid var(--line); border-radius: 999px; padding: 6px 12px;
}
.trust svg { width: 14px; height: 14px; color: var(--teal); flex: none; }

/* ---------- tool shell ---------- */
.tool-shell {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 22px;
  box-shadow: var(--shadow-lift);
  margin: 34px 0 10px;
  overflow: hidden;
}
.tabs {
  display: grid; grid-template-columns: repeat(3, 1fr);
  gap: 6px; padding: 8px;
  background: var(--paper-2);
  border-bottom: 1px solid var(--line);
}
.tab {
  display: flex; align-items: center; justify-content: center; gap: 9px;
  border: 0; background: transparent; color: var(--slate);
  padding: 13px 10px; border-radius: 12px;
  font-size: 14.5px; font-weight: 700; cursor: pointer;
  transition: background .18s, color .18s, box-shadow .18s;
}
.tab svg { width: 18px; height: 18px; flex: none; }
.tab:hover { color: var(--ink); background: rgba(255,255,255,.6); }
.tab[aria-selected="true"] { background: #fff; color: var(--ink); box-shadow: 0 2px 8px rgba(27,36,48,.08); }
.tab[aria-selected="true"] svg { color: var(--coral); }
.tab-num {
  font-size: 10.5px; font-weight: 800; color: var(--slate-2);
  border: 1px solid var(--line-strong); border-radius: 5px; padding: 1px 4px;
}
.tab[aria-selected="true"] .tab-num { color: var(--coral-dark); border-color: #f4c4b6; }

.panel { padding: 26px; }
.panel[hidden] { display: none; }
.panel-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; margin-bottom: 18px; flex-wrap: wrap; }
.panel-head h2 { font-size: 21px; font-weight: 780; }
.panel-head p { color: var(--slate); font-size: 13.5px; margin-top: 4px; max-width: 560px; }

/* ---------- drop zone ---------- */
.drop {
  position: relative; display: block; width: 100%;
  border: 2px dashed var(--line-strong); border-radius: var(--radius);
  background: #fffdfb; padding: 30px 20px; text-align: center; cursor: pointer;
  transition: border-color .16s, background .16s, transform .16s;
}
.drop:hover, .drop.is-over { border-color: var(--coral); background: var(--coral-soft); }
.drop:focus-visible { outline: 3px solid rgba(255,106,77,.35); outline-offset: 2px; }
.drop input[type="file"] { position: absolute; width: 1px; height: 1px; opacity: 0; pointer-events: none; }
.drop-icon {
  width: 46px; height: 46px; border-radius: 13px; margin: 0 auto 12px;
  background: var(--coral-soft); color: var(--coral-dark);
  display: flex; align-items: center; justify-content: center;
}
.drop-icon svg { width: 24px; height: 24px; }
.drop-title { display: block; font-weight: 750; font-size: 15.5px; }
.drop-sub { display: block; color: var(--slate); font-size: 13px; margin-top: 3px; }
.drop-formats { display: inline-block; margin-top: 10px; font-size: 11.5px; font-weight: 700; color: var(--slate-2); letter-spacing: .04em; background: var(--paper-2); border-radius: 6px; padding: 3px 8px; }

/* ---------- file list ---------- */
.filelist { list-style: none; padding: 0; margin: 16px 0 0; display: grid; gap: 8px; }
.filelist:empty { margin: 0; }
.file {
  display: flex; align-items: center; gap: 12px;
  border: 1px solid var(--line); border-radius: var(--radius-sm);
  padding: 10px 12px; background: #fff;
  animation: fade-in .18s ease-out;
}
@keyframes fade-in { from { opacity: 0; transform: translateY(-3px); } to { opacity: 1; transform: none; } }
.file-icon {
  width: 34px; height: 34px; border-radius: 8px; flex: none;
  display: flex; align-items: center; justify-content: center;
  background: var(--coral-soft); color: var(--coral-dark); font-size: 10px; font-weight: 800; letter-spacing: .02em;
}
.file-icon.img { background: var(--teal-soft); color: var(--teal); }
.file-body { min-width: 0; flex: 1; }
.file-name { font-size: 13.5px; font-weight: 650; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.file-meta { font-size: 11.5px; color: var(--slate); margin-top: 1px; }
.file-meta .err { color: #b42318; font-weight: 650; }
.file-actions { display: flex; gap: 4px; flex: none; }
.icon-btn {
  width: 30px; height: 30px; border-radius: 8px; border: 1px solid var(--line);
  background: #fff; color: var(--slate); cursor: pointer;
  display: inline-flex; align-items: center; justify-content: center;
  transition: background .14s, color .14s, border-color .14s;
}
.icon-btn svg { width: 15px; height: 15px; }
.icon-btn:hover:not(:disabled) { border-color: var(--line-strong); color: var(--ink); background: var(--paper); }
.icon-btn.danger:hover:not(:disabled) { border-color: #f3c1bb; color: #b42318; background: #fff4f3; }
.icon-btn:disabled { opacity: .35; cursor: not-allowed; }

/* ---------- split panel ---------- */
.page-grid { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 14px; }
.page-chip {
  min-width: 34px; height: 34px; padding: 0 7px;
  border: 1px solid var(--line-strong); border-radius: 7px; background: #fff;
  color: var(--slate); font-size: 12.5px; font-weight: 700; cursor: pointer;
  display: inline-flex; align-items: center; justify-content: center;
  transition: all .12s;
}
.page-chip:hover { border-color: var(--coral); color: var(--coral-dark); }
.page-chip[aria-pressed="true"] { background: var(--coral); border-color: var(--coral); color: #fff; }
.split-tools { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin-top: 12px; }
.ghost-btn {
  border: 1px solid var(--line-strong); background: #fff; color: var(--slate);
  font-size: 12.5px; font-weight: 650; padding: 6px 11px; border-radius: 8px; cursor: pointer;
}
.ghost-btn:hover { border-color: var(--ink); color: var(--ink); }

.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-top: 16px; }
.field label { display: block; font-size: 12px; font-weight: 700; color: var(--slate); letter-spacing: .02em; margin-bottom: 6px; }
.field .hint { font-weight: 500; color: var(--slate-2); }
.input, .select {
  width: 100%; border: 1px solid var(--line-strong); border-radius: 9px;
  padding: 10px 12px; font-size: 14px; font-family: inherit; color: var(--ink); background: #fff;
}
.input:focus, .select:focus { outline: none; border-color: var(--coral); box-shadow: 0 0 0 3px var(--coral-soft); }
.input.is-bad { border-color: #e28b80; background: #fff8f7; }
.input-hint { font-size: 11.5px; color: var(--slate); margin-top: 5px; min-height: 17px; }
.input-hint.bad { color: #b42318; font-weight: 600; }

/* ---------- buttons ---------- */
.actions { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; margin-top: 20px; }
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  border: 0; border-radius: 11px; padding: 13px 20px;
  font-size: 14.5px; font-weight: 750; cursor: pointer;
  transition: transform .12s, box-shadow .16s, background .16s, opacity .16s;
}
.btn svg { width: 17px; height: 17px; }
.btn-primary { background: var(--coral); color: #fff; box-shadow: 0 6px 16px rgba(255,106,77,.32); }
.btn-primary:hover:not(:disabled) { background: var(--coral-dark); transform: translateY(-1px); }
.btn-primary:active:not(:disabled) { transform: none; }
.btn-secondary { background: #fff; color: var(--ink); border: 1px solid var(--line-strong); }
.btn-secondary:hover:not(:disabled) { border-color: var(--ink); }
.btn:disabled { opacity: .45; cursor: not-allowed; box-shadow: none; }
.btn .spinner {
  width: 15px; height: 15px; border-radius: 50%;
  border: 2px solid rgba(255,255,255,.4); border-top-color: #fff;
  animation: spin .7s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

.summary { color: var(--slate); font-size: 13px; margin-top: 12px; }
.summary strong { color: var(--ink); }

/* ---------- result ---------- */
.result { display: none; margin-top: 18px; }
.result.show { display: block; }
.result-card {
  display: flex; align-items: center; gap: 14px; flex-wrap: wrap;
  border: 1px solid #bfe0d4; background: #f4fbf7; border-radius: 12px; padding: 14px 16px;
  animation: fade-in .2s ease-out;
}
.result-check {
  width: 34px; height: 34px; border-radius: 50%; flex: none;
  background: var(--ok); color: #fff; display: flex; align-items: center; justify-content: center;
}
.result-check svg { width: 17px; height: 17px; }
.result-body { flex: 1; min-width: 180px; }
.result-title { font-weight: 750; font-size: 14px; }
.result-meta { font-size: 12.5px; color: var(--slate); }
.result .btn { padding: 10px 16px; font-size: 13.5px; }

.alert {
  display: none; margin-top: 14px; border-radius: 10px; padding: 11px 14px;
  font-size: 13px; font-weight: 600; border: 1px solid #f3c1bb; background: #fff5f4; color: #9a2b1d;
}
.alert.show { display: block; }
.alert.info { border-color: #cfe0ee; background: #f4f9fd; color: #2b577a; }

.note { font-size: 11.5px; color: var(--slate-2); margin-top: 14px; display: flex; align-items: center; gap: 6px; }
.note svg { width: 13px; height: 13px; flex: none; }

/* ---------- ad slots ---------- */
.ad-slot {
  margin: 26px auto; max-width: 970px; min-height: 90px;
  border: 1px dashed var(--line); border-radius: 12px;
  display: flex; align-items: center; justify-content: center;
  color: var(--slate-2); font-size: 10.5px; letter-spacing: .14em; text-transform: uppercase;
  background: rgba(255,255,255,.5);
}

/* ---------- sections ---------- */
.section { padding: 58px 0 10px; }
.section-head { max-width: 680px; margin-bottom: 26px; }
.section-head h2 { font-size: clamp(23px, 3.4vw, 32px); font-weight: 800; }
.section-head p { color: var(--slate); margin-top: 10px; font-size: 15px; }

.features { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }
.feature {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  padding: 20px 18px; box-shadow: var(--shadow);
}
.feature-icon {
  width: 38px; height: 38px; border-radius: 10px; margin-bottom: 12px;
  display: flex; align-items: center; justify-content: center;
  background: var(--coral-soft); color: var(--coral-dark);
}
.feature:nth-child(even) .feature-icon { background: var(--teal-soft); color: var(--teal); }
.feature-icon svg { width: 19px; height: 19px; }
.feature h3 { font-size: 15px; font-weight: 750; margin-bottom: 5px; }
.feature p { font-size: 13px; color: var(--slate); line-height: 1.55; }

.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; counter-reset: step; }
.step { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; }
.step-num {
  width: 26px; height: 26px; border-radius: 50%; background: var(--ink); color: #fff;
  font-size: 12.5px; font-weight: 800; display: flex; align-items: center; justify-content: center;
  margin-bottom: 11px;
}
.step h3 { font-size: 15px; font-weight: 750; margin-bottom: 4px; }
.step p { font-size: 13px; color: var(--slate); }

.faq { max-width: 820px; }
.faq details {
  background: #fff; border: 1px solid var(--line); border-radius: 12px;
  padding: 15px 18px; margin-bottom: 9px;
}
.faq details[open] { border-color: var(--line-strong); box-shadow: var(--shadow); }
.faq summary {
  cursor: pointer; font-weight: 700; font-size: 14.5px; list-style: none;
  display: flex; justify-content: space-between; align-items: center; gap: 14px;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; color: var(--coral); font-size: 20px; font-weight: 500; line-height: 1; flex: none; }
.faq details[open] summary::after { content: "\2212"; }
.faq .answer { color: var(--slate); font-size: 13.5px; margin-top: 10px; line-height: 1.65; }

/* ---------- footer ---------- */
.site-footer { border-top: 1px solid var(--line); margin-top: 64px; padding: 30px 0 40px; background: rgba(255,255,255,.6); }
.footer-inner { display: flex; flex-wrap: wrap; gap: 16px 26px; align-items: center; justify-content: space-between; }
.footer-links { display: flex; flex-wrap: wrap; gap: 18px; font-size: 13px; }
.footer-links a { color: var(--slate); }
.footer-copy { font-size: 12px; color: var(--slate-2); }
.visually-hidden {
  position: absolute !important; width: 1px; height: 1px; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap;
}

/* ---------- responsive ---------- */
@media (max-width: 900px) {
  .features { grid-template-columns: repeat(2, 1fr); }
  .nav { display: none; }
}
@media (max-width: 700px) {
  .hero { padding: 34px 0 18px; }
  .panel { padding: 18px 16px; }
  .tabs { gap: 4px; padding: 6px; }
  .tab { flex-direction: column; gap: 4px; font-size: 12.5px; padding: 10px 6px; }
  .tab-num { display: none; }
  .steps { grid-template-columns: 1fr; }
  .field-row { grid-template-columns: 1fr; }
  .actions { flex-direction: column; align-items: stretch; }
  .actions .btn { width: 100%; }
  .file { gap: 9px; padding: 9px 10px; }
  .file-icon { width: 30px; height: 30px; }
  .result-card { flex-direction: column; align-items: flex-start; }
  .result-card .btn { width: 100%; }
  .section { padding: 44px 0 6px; }
  .header-inner { height: 58px; }
  .brand { font-size: 16.5px; }
}
@media (max-width: 420px) {
  .features { grid-template-columns: 1fr; }
  .wrap { padding: 0 14px; }
}

@media (prefers-reduced-motion: reduce) {
  * { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}
