/* Photo to PDF — site-wide design system
   Minimal / Swiss: white space, high contrast, brand red, Outfit + Work Sans */

:root {
  --red: #d92d2d;
  --red-dark: #b31f1f;
  --red-deep: #8f1616;
  --red-soft: #fdeaea;
  --red-wash: #fff7f7;
  --ink: #191b1f;
  --ink-soft: #43474f;
  --ink-mute: #6b7078;
  --line: #e8e4e0;
  --paper: #ffffff;
  --paper-warm: #faf8f6;
  --ok: #1a7f4b;
  --ok-soft: #e7f6ed;
  --radius: 14px;
  --radius-lg: 22px;
  --shadow-sm: 0 1px 2px rgba(25, 27, 31, 0.06);
  --shadow-md: 0 6px 24px -8px rgba(25, 27, 31, 0.14);
  --shadow-lg: 0 24px 60px -20px rgba(143, 22, 22, 0.25);
  --font-head: "Outfit", system-ui, -apple-system, sans-serif;
  --font-body: "Work Sans", system-ui, -apple-system, sans-serif;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

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

body {
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.65;
  color: var(--ink);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4 { font-family: var(--font-head); line-height: 1.15; letter-spacing: -0.015em; }
h1 { font-size: clamp(2.1rem, 5.2vw, 3.4rem); font-weight: 700; }
h2 { font-size: clamp(1.55rem, 3.4vw, 2.2rem); font-weight: 700; }
h3 { font-size: 1.22rem; font-weight: 600; }

p { max-width: 68ch; }
a { color: var(--red-dark); text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { color: var(--red); }
img { max-width: 100%; height: auto; display: block; }

:focus-visible { outline: 3px solid var(--red); outline-offset: 2px; border-radius: 4px; }

.wrap { max-width: 1120px; margin: 0 auto; padding: 0 24px; }
.wrap-narrow { max-width: 780px; margin: 0 auto; padding: 0 24px; }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.site-header .wrap { display: flex; align-items: center; gap: 20px; height: 64px; }
.brand { display: flex; align-items: center; gap: 10px; font-family: var(--font-head); font-weight: 700; font-size: 1.06rem; color: var(--ink); text-decoration: none; }
.brand img { width: 34px; height: 34px; border-radius: 8px; }
.site-nav { margin-left: auto; display: flex; align-items: center; gap: 4px; }
.site-nav a { text-decoration: none; color: var(--ink-soft); font-size: 0.95rem; font-weight: 500; padding: 8px 12px; border-radius: 8px; transition: color 0.2s, background 0.2s; }
.site-nav a:hover { color: var(--ink); background: var(--paper-warm); }
.site-nav .nav-cta { background: var(--red); color: #fff; font-weight: 600; padding: 9px 16px; border-radius: 999px; }
.site-nav .nav-cta:hover { background: var(--red-dark); color: #fff; }
@media (max-width: 720px) { .site-nav a:not(.nav-cta) { display: none; } }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  font-family: var(--font-head); font-weight: 600; font-size: 1.02rem;
  min-height: 48px; padding: 12px 26px; border-radius: 999px;
  border: none; cursor: pointer; text-decoration: none;
  transition: background 0.2s, color 0.2s, box-shadow 0.2s;
}
.btn-primary { background: var(--red); color: #fff; box-shadow: var(--shadow-md); }
.btn-primary:hover { background: var(--red-dark); color: #fff; }
.btn-secondary { background: var(--paper); color: var(--ink); border: 1.5px solid var(--line); }
.btn-secondary:hover { border-color: var(--ink-mute); color: var(--ink); }
.btn[disabled] { opacity: 0.55; cursor: not-allowed; }
.btn svg { flex: none; }

/* ---------- Hero ---------- */
.hero { background: linear-gradient(180deg, var(--red-wash) 0%, var(--paper) 88%); padding: 72px 0 56px; }
.hero-grid { display: grid; grid-template-columns: 1.15fr 0.85fr; gap: 56px; align-items: center; }
@media (max-width: 900px) { .hero-grid { grid-template-columns: 1fr; gap: 40px; } }
.hero-copy .app-badge-row { display: flex; align-items: center; gap: 14px; margin-bottom: 26px; }
.hero-copy .app-badge-row img { width: 64px; height: 64px; border-radius: 15px; box-shadow: var(--shadow-md); }
.hero-copy h1 { margin-bottom: 18px; }
.hero-copy h1 em { font-style: normal; color: var(--red); }
.hero-sub { font-size: 1.15rem; color: var(--ink-soft); margin-bottom: 30px; }
.hero-ctas { display: flex; flex-wrap: wrap; align-items: center; gap: 16px; margin-bottom: 22px; }
.hero-proof { display: flex; flex-wrap: wrap; gap: 18px; font-size: 0.92rem; color: var(--ink-mute); }
.hero-proof span { display: inline-flex; align-items: center; gap: 7px; }
.hero-proof svg { color: var(--ok); flex: none; }
.hero-shot { justify-self: center; position: relative; }
.hero-shot img { width: min(300px, 78vw); border-radius: 30px; box-shadow: var(--shadow-lg); }

.stars { position: relative; display: inline-block; color: #d9d3cd; letter-spacing: 2px; font-size: 0.95rem; white-space: nowrap; }
.stars .stars-fill { position: absolute; top: 0; left: 0; overflow: hidden; color: #e8a13c; white-space: nowrap; }

/* ---------- Sections ---------- */
.section { padding: 72px 0; }
.section-alt { background: var(--paper-warm); }
.section-head { max-width: 640px; margin-bottom: 44px; }
.section-head .kicker { font-family: var(--font-head); font-weight: 600; font-size: 0.85rem; text-transform: uppercase; letter-spacing: 0.1em; color: var(--red); margin-bottom: 10px; }
.section-head p { color: var(--ink-soft); margin-top: 12px; }

/* ---------- Cards / grids ---------- */
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 22px; }
@media (max-width: 900px) { .grid-3 { grid-template-columns: 1fr 1fr; } }
@media (max-width: 620px) { .grid-3, .grid-2 { grid-template-columns: 1fr; } }

.card {
  background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius-lg);
  padding: 28px; box-shadow: var(--shadow-sm);
  transition: box-shadow 0.25s, border-color 0.25s;
}
a.card { display: block; text-decoration: none; color: var(--ink); cursor: pointer; }
a.card:hover { box-shadow: var(--shadow-md); border-color: #d9d3cd; color: var(--ink); }
.card .icon-chip {
  width: 46px; height: 46px; border-radius: 12px; display: flex; align-items: center; justify-content: center;
  background: var(--red-soft); color: var(--red-dark); margin-bottom: 18px;
}
.card h3 { margin-bottom: 8px; }
.card p { font-size: 0.97rem; color: var(--ink-soft); }
.card .card-more { display: inline-block; margin-top: 14px; font-weight: 600; font-size: 0.93rem; color: var(--red-dark); }

/* ---------- Screenshots ---------- */
.shots { display: flex; gap: 20px; overflow-x: auto; padding: 6px 4px 18px; scroll-snap-type: x mandatory; }
.shots figure { flex: 0 0 auto; scroll-snap-align: start; margin: 0; }
.shots img { width: 226px; border-radius: 22px; box-shadow: var(--shadow-md); border: 1px solid var(--line); }
.shots figcaption { text-align: center; font-size: 0.88rem; color: var(--ink-mute); margin-top: 10px; }

/* ---------- Steps ---------- */
.steps { counter-reset: step; display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
@media (max-width: 720px) { .steps { grid-template-columns: 1fr; } }
.step { counter-increment: step; background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 28px; }
.step::before {
  content: counter(step);
  display: flex; align-items: center; justify-content: center;
  width: 40px; height: 40px; border-radius: 999px; margin-bottom: 16px;
  background: var(--red); color: #fff; font-family: var(--font-head); font-weight: 700; font-size: 1.05rem;
}
.step h3 { margin-bottom: 8px; }
.step p { font-size: 0.97rem; color: var(--ink-soft); }

/* ---------- FAQ ---------- */
.faq-list { display: grid; gap: 12px; }
.faq-list details { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); padding: 0; overflow: hidden; }
.faq-list summary {
  list-style: none; cursor: pointer; display: flex; justify-content: space-between; align-items: center; gap: 16px;
  padding: 18px 22px; font-family: var(--font-head); font-weight: 600; font-size: 1.04rem;
  transition: background 0.2s;
}
.faq-list summary:hover { background: var(--paper-warm); }
.faq-list summary::-webkit-details-marker { display: none; }
.faq-list summary::after {
  content: ""; flex: none; width: 12px; height: 12px;
  border-right: 2.5px solid var(--ink-mute); border-bottom: 2.5px solid var(--ink-mute);
  transform: rotate(45deg); transition: transform 0.2s; margin-right: 4px;
}
.faq-list details[open] summary::after { transform: rotate(225deg); }
.faq-list .faq-body { padding: 0 22px 20px; color: var(--ink-soft); font-size: 0.99rem; }
.faq-body a { font-weight: 600; }

/* ---------- Big CTA ---------- */
.cta-banner {
  background: linear-gradient(135deg, var(--red) 0%, var(--red-deep) 100%);
  border-radius: var(--radius-lg); color: #fff; text-align: center;
  padding: 64px 32px; box-shadow: var(--shadow-lg);
}
.cta-banner h2 { color: #fff; margin-bottom: 14px; }
.cta-banner p { color: rgba(255, 255, 255, 0.88); margin: 0 auto 30px; }
.cta-banner .btn-primary { background: #fff; color: var(--red-deep); }
.cta-banner .btn-primary:hover { background: var(--red-wash); color: var(--red-deep); }
.cta-banner .cta-alt { display: block; margin-top: 18px; }
.cta-banner .cta-alt a { color: #fff; }

/* ---------- Footer ---------- */
.site-footer { border-top: 1px solid var(--line); padding: 52px 0 40px; background: var(--paper-warm); font-size: 0.94rem; }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: 32px; }
@media (max-width: 820px) { .footer-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 520px) { .footer-grid { grid-template-columns: 1fr; } }
.site-footer h4 { font-size: 0.85rem; text-transform: uppercase; letter-spacing: 0.08em; color: var(--ink-mute); margin-bottom: 14px; }
.site-footer ul { list-style: none; display: grid; gap: 9px; }
.site-footer a { color: var(--ink-soft); text-decoration: none; }
.site-footer a:hover { color: var(--red-dark); text-decoration: underline; }
.footer-brand p { color: var(--ink-mute); margin-top: 12px; font-size: 0.9rem; }
.footer-legal { margin-top: 36px; padding-top: 20px; border-top: 1px solid var(--line); color: var(--ink-mute); font-size: 0.86rem; display: flex; flex-wrap: wrap; gap: 8px 24px; }

/* ---------- Tool UI ---------- */
.tool-shell { max-width: 880px; margin: 0 auto; }
.dropzone {
  border: 2.5px dashed #dcc9c9; border-radius: var(--radius-lg); background: var(--red-wash);
  padding: 56px 28px; text-align: center; cursor: pointer;
  transition: border-color 0.2s, background 0.2s;
}
.dropzone:hover, .dropzone.dragover { border-color: var(--red); background: var(--red-soft); }
.dropzone .dz-icon { color: var(--red); margin: 0 auto 16px; width: 52px; height: 52px; }
.dropzone .dz-title { font-family: var(--font-head); font-weight: 600; font-size: 1.2rem; margin-bottom: 6px; }
.dropzone .dz-hint { color: var(--ink-mute); font-size: 0.93rem; max-width: none; }
.dropzone input[type="file"] { display: none; }

.privacy-note {
  display: flex; align-items: center; justify-content: center; gap: 9px;
  margin-top: 16px; font-size: 0.92rem; color: var(--ok); font-weight: 500;
}
.privacy-note svg { flex: none; }

.file-list { margin-top: 26px; display: grid; gap: 10px; }
.file-row {
  display: flex; align-items: center; gap: 14px; background: var(--paper);
  border: 1px solid var(--line); border-radius: var(--radius); padding: 12px 16px;
}
.file-row .thumb { width: 46px; height: 46px; border-radius: 9px; object-fit: cover; background: var(--paper-warm); border: 1px solid var(--line); flex: none; }
.file-row .thumb-pdf { display: flex; align-items: center; justify-content: center; color: var(--red); }
.file-row .meta { min-width: 0; flex: 1; }
.file-row .name { font-weight: 500; font-size: 0.96rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.file-row .sub { font-size: 0.84rem; color: var(--ink-mute); }
.file-row .row-actions { display: flex; gap: 6px; }
.icon-btn {
  width: 38px; height: 38px; min-width: 38px; border-radius: 9px; border: 1px solid var(--line);
  background: var(--paper); cursor: pointer; display: flex; align-items: center; justify-content: center;
  color: var(--ink-soft); transition: background 0.2s, color 0.2s, border-color 0.2s;
}
.icon-btn:hover { background: var(--paper-warm); color: var(--ink); }
.icon-btn.danger:hover { background: var(--red-soft); color: var(--red-dark); border-color: #efc9c9; }
.icon-btn[disabled] { opacity: 0.4; cursor: not-allowed; }

.tool-options { margin-top: 26px; display: flex; flex-wrap: wrap; gap: 26px; }
.opt-group .opt-label { font-family: var(--font-head); font-weight: 600; font-size: 0.88rem; margin-bottom: 9px; color: var(--ink-soft); }
.seg { display: inline-flex; background: var(--paper-warm); border: 1px solid var(--line); border-radius: 999px; padding: 4px; }
.seg button {
  border: none; background: transparent; cursor: pointer; font-family: var(--font-body); font-weight: 500;
  font-size: 0.92rem; color: var(--ink-soft); padding: 8px 16px; min-height: 38px; border-radius: 999px;
  transition: background 0.2s, color 0.2s;
}
.seg button:hover { color: var(--ink); }
.seg button[aria-pressed="true"] { background: var(--red); color: #fff; font-weight: 600; }

.tool-run { margin-top: 30px; display: flex; flex-wrap: wrap; align-items: center; gap: 18px; }
.progress-wrap { flex: 1 1 240px; display: none; }
.progress-wrap.active { display: block; }
.progress-track { height: 10px; border-radius: 999px; background: var(--red-soft); overflow: hidden; }
.progress-bar { height: 100%; width: 0%; border-radius: 999px; background: var(--red); transition: width 0.25s ease; }
.progress-label { font-size: 0.86rem; color: var(--ink-mute); margin-top: 7px; }

.tool-status { margin-top: 18px; font-size: 0.95rem; display: none; padding: 14px 18px; border-radius: var(--radius); }
.tool-status.error { display: block; background: #fdeeee; color: var(--red-deep); border: 1px solid #f3caca; }
.tool-status.success { display: block; background: var(--ok-soft); color: var(--ok); border: 1px solid #bfe6cf; }

.results { margin-top: 30px; display: none; }
.results.active { display: block; }
.results h3 { margin-bottom: 16px; }
.result-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 16px; }
.result-cell { border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; background: var(--paper); }
.result-cell img { width: 100%; aspect-ratio: 3 / 4; object-fit: contain; background: var(--paper-warm); }
.result-cell .cell-foot { padding: 10px 12px; display: flex; justify-content: space-between; align-items: center; gap: 8px; font-size: 0.84rem; color: var(--ink-mute); }
.result-cell a { font-weight: 600; font-size: 0.88rem; }
.results .btn { margin-top: 20px; }

/* ---------- Guide / article pages ---------- */
.article { padding: 56px 0 72px; }
.article h1 { margin-bottom: 16px; }
.article .article-lede { font-size: 1.14rem; color: var(--ink-soft); margin-bottom: 8px; }
.article .article-meta { font-size: 0.88rem; color: var(--ink-mute); margin-bottom: 36px; }
.article h2 { margin: 44px 0 14px; }
.article h3 { margin: 30px 0 10px; }
.article p { margin-bottom: 16px; }
.article ul, .article ol { margin: 0 0 18px 24px; display: grid; gap: 8px; }
.article li::marker { color: var(--red); font-weight: 600; }
.callout {
  background: var(--red-wash); border: 1px solid #f3d5d5; border-left: 4px solid var(--red);
  border-radius: 12px; padding: 18px 22px; margin: 26px 0;
}
.callout p { margin: 0; font-size: 0.98rem; }
.callout p + p { margin-top: 8px; }
.article .inline-cta {
  display: flex; flex-wrap: wrap; align-items: center; gap: 16px; margin: 34px 0;
  background: var(--paper-warm); border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 24px 26px;
}
.article .inline-cta img { width: 52px; height: 52px; border-radius: 12px; }
.article .inline-cta .cta-copy { flex: 1 1 260px; }
.article .inline-cta .cta-copy strong { font-family: var(--font-head); display: block; margin-bottom: 2px; }
.article .inline-cta .cta-copy span { font-size: 0.92rem; color: var(--ink-soft); }
.breadcrumbs { font-size: 0.88rem; color: var(--ink-mute); margin-bottom: 26px; }
.breadcrumbs a { color: var(--ink-mute); }
.breadcrumbs a:hover { color: var(--red-dark); }

.related { margin-top: 56px; padding-top: 36px; border-top: 1px solid var(--line); }
.related h2 { margin-bottom: 22px; }

table.cmp { width: 100%; border-collapse: collapse; margin: 22px 0; font-size: 0.95rem; }
table.cmp th, table.cmp td { text-align: left; padding: 11px 14px; border-bottom: 1px solid var(--line); }
table.cmp th { font-family: var(--font-head); font-weight: 600; background: var(--paper-warm); }

/* ---------- Utility ---------- */
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.center { text-align: center; }
.center p { margin-inline: auto; }
