/* ResumeForge (ZeroDataUpload, /tools-app/resume-builder/): the paper. The original's paper and its eight templates,
   with fixed paper colours in both themes of the site. Contrast fixes (3 Nov 2026): the grey of empty placeholders
   and of the page numbers reaches 4.5:1, and secondary text on the accent colour uses --on-ac-2 (worked out in
   paper.js to keep 4.5:1) instead of opacity.
   ======================================================================
   The paper. Sizes are in pt and mm so the screen matches the PDF.
   Variables set per page: --pw --ph page size, --m margin, --fs body size,
   --lh line height, --sp section spacing, --fh / --fb fonts,
   --ac accent, --on-ac text on accent, --on-ac-2 secondary text on accent, --ac-soft light accent.
   ====================================================================== */
.page {
  position: relative; width: var(--pw); height: var(--ph); overflow: hidden; flex: none;
  display: flex; flex-direction: column;
  background: #fff; color: #1f232b; font-family: var(--fb); font-size: var(--fs); line-height: var(--lh);
  font-kerning: normal; text-rendering: optimizeLegibility; -webkit-font-smoothing: antialiased;
  overflow-wrap: break-word; color-scheme: light;
}
.page a { color: inherit; text-decoration: none; }
/* The site's text rules (libs/site-pages.css: p, ul, li, a) must not reach the paper: in the dark theme they would
   colour its paragraphs light grey, and they change the line height. These selectors weigh as much as the site's and
   come later, so they win; every template rule below carries a class and still wins over them. (In the original,
   p had no margin and the paper set its own colour and line height.) */
:where(.page) p, :where(.page) ul, :where(.page) ol, :where(.page) li { margin: 0; color: inherit; line-height: inherit; }
:where(.page) ul, :where(.page) ol { padding-left: 1.15em; }
:where(.page) li { padding: 0; }
:where(.page) a, :where(.page) a:hover { color: inherit; text-decoration: none; transition: none; }
.pg-top { flex: none; }
.pg-body { flex: 1; min-height: 0; display: grid; grid-template-columns: minmax(0, 1fr); grid-template-rows: minmax(0, 1fr); }
.col { min-width: 0; min-height: 0; overflow: hidden; }
.pg-foot { position: absolute; left: 0; right: 0; bottom: calc(var(--m) * 0.42); text-align: center; font-size: 0.78em; color: #6b7280; font-family: var(--fb); }

/* shared paper elements */
.r-name { font-family: var(--fh); font-size: 2.5em; line-height: 1.08; font-weight: 700; letter-spacing: -0.01em; color: #15181e; }
.r-headline { font-family: var(--fh); font-size: 1.18em; line-height: 1.3; margin-top: 0.2em; color: var(--ac); }
.r-ph { color: #6b7280 !important; font-style: italic; }
.r-contact { display: flex; flex-wrap: wrap; gap: 0.15em 1.1em; margin-top: 0.7em; font-size: 0.92em; color: #3f4550; }
.r-ci { display: inline-flex; align-items: baseline; gap: 0.4em; min-width: 0; }
.r-ci .ri { width: 1.05em; height: 1.05em; flex: none; align-self: center; fill: none; stroke: var(--ac); stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.r-ci .rk { color: #6b7280; }
.r-photo { width: 27mm; height: 27mm; object-fit: cover; display: block; flex: none; border-radius: 50%; }
.r-photo.sq { border-radius: 2mm; }
.r-h {
  font-family: var(--fh); font-size: 1.12em; line-height: 1.25; font-weight: 700; color: var(--ac);
  margin-top: calc(1.45em * var(--sp)); margin-bottom: calc(0.5em * var(--sp));
}
.col > .r-h:first-child { margin-top: 0; }
.col > .r-head + .r-h { margin-top: calc(1.2em * var(--sp)); }
.r-side-head .r-h { margin-top: 0; }
.r-entry { margin-top: calc(0.8em * var(--sp)); }
.r-h + .r-entry, .r-entry.cont { margin-top: 0; }
.r-when { display: none; }
.r-l1, .r-l2 { display: flex; justify-content: space-between; align-items: baseline; gap: 0.3em 1em; }
.r-l1 { flex-wrap: wrap; }
.r-title { font-weight: 700; color: #15181e; }
.r-date { white-space: nowrap; font-size: 0.92em; color: #4b5260; font-variant-numeric: tabular-nums; margin-left: auto; }
.r-l2 { color: #3f4550; }
.r-org { font-style: italic; }
.r-loc { font-size: 0.92em; color: #5f6673; white-space: nowrap; margin-left: auto; }
.r-url { font-size: 0.9em; color: var(--ac); }
.r-body { margin-top: 0.25em; }
.r-body > p { margin: 0.28em 0 0; }
.r-body > p:first-child { margin-top: 0; }
.r-body > ul { margin: 0.18em 0 0; padding-left: 1.15em; }
.r-body > ul:first-child { margin-top: 0; }
.r-body li { margin-top: 0.14em; padding-left: 0.1em; }
.r-body li::marker { color: var(--ac); }
.r-entry.cont .r-body > ul:first-child { margin-top: 0.14em; }
.r-para { margin-top: 0.35em; }
.r-h + .r-para { margin-top: 0; }
.r-tags { display: flex; flex-wrap: wrap; gap: 0.35em; margin-top: 0.4em; }
.r-h + .r-tags, .r-h + .r-sk { margin-top: 0; }
.r-tag { padding: 0.12em 0.6em; border-radius: 0.3em; background: var(--ac-soft); color: #20242c; font-size: 0.92em; line-height: 1.35; }
.r-sk { margin-top: 0.35em; }
.r-sk-name { font-weight: 700; color: #15181e; }
.r-sk-row { display: flex; justify-content: space-between; align-items: center; gap: 1em; }
.r-dots { display: inline-flex; gap: 0.22em; flex: none; }
.r-dots i { width: 0.55em; height: 0.55em; border-radius: 50%; border: 0.07em solid var(--ac); display: block; }
.r-dots i.on { background: var(--ac); }
.r-sk .r-tags { margin-top: 0.25em; }
.r-sk-kw { color: #3f4550; }
.r-lang { display: flex; justify-content: space-between; gap: 1em; margin-top: 0.25em; }
.r-h + .r-lang { margin-top: 0; }
.r-lang .r-lvl { color: #5f6673; font-size: 0.92em; }
.r-ref { margin-top: 0.5em; }
.r-ref .r-title { display: block; }
.r-refs-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0.6em 1.5em; }
.r-extra { display: flex; gap: 0.5em; }

/* letter */
.l-date { margin-bottom: 1.4em; color: #3f4550; }
.l-to { margin-bottom: 1.3em; white-space: pre-line; }
.l-to b { color: #15181e; }
.l-subject { font-weight: 700; margin-bottom: 1.1em; color: #15181e; }
.l-greet { margin-bottom: 0.8em; }
.l-p { margin-bottom: 0.8em; }
.l-close { margin-top: 1.4em; }
.l-sign { margin-top: 2.2em; font-weight: 700; color: #15181e; }
.l-sign .r-headline { font-weight: 400; font-size: 0.95em; margin-top: 0.1em; }

/* review marks: on screen only */
.pm { position: absolute; z-index: 3; pointer-events: none; }
.pm-bar { position: absolute; width: 0.9mm; border-radius: 1mm; background: #d23b2f; opacity: 0.85; }
.pm-n {
  position: absolute; width: 5.4mm; height: 5.4mm; border-radius: 50%; border: 0.55mm solid #d23b2f; background: #fff;
  color: #d23b2f; font: 700 8pt/1 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; display: grid; place-items: center;
  pointer-events: auto; cursor: pointer; font-variant-numeric: tabular-nums;
}
.pm-n.tip { border-color: #b07800; color: #8a5d00; }
.pm-bar.tip { background: #c98a00; }
.pm-u { text-decoration: underline wavy #d23b2f 0.7pt; text-underline-offset: 0.22em; text-decoration-skip-ink: none; }
.pm-u.tip { text-decoration-color: #c98a00; }
.pm-flash { animation: pmflash 1.2s ease-out; }
@keyframes pmflash { 0%, 40% { transform: scale(1.35); } 100% { transform: scale(1); } }

/* ---------- template: Classic ---------- */
.t-classic .pg-top { padding: var(--m) var(--m) 0; text-align: center; }
.t-classic .pg-body { padding: calc(var(--m) * 0.55) var(--m) var(--m); }
.t-classic.pg-n .pg-body { padding-top: var(--m); }
.t-classic .r-head .r-photo { margin: 0 auto 0.8em; }
.t-classic .r-name { font-size: 2.35em; letter-spacing: 0.01em; }
.t-classic .r-headline { color: #3f4550; font-size: 1.1em; }
.t-classic .r-contact { justify-content: center; gap: 0.1em 0; }
.t-classic .r-contact .r-ci + .r-ci:not(.lead)::before { content: "|"; color: #b4bac4; margin: 0 0.65em; }
.t-classic .r-h { text-transform: uppercase; letter-spacing: 0.12em; font-size: 0.98em; padding-bottom: 0.25em; border-bottom: 0.75pt solid var(--ac); }

/* ---------- template: Executive ---------- */
.t-executive { border-top: 2.4mm solid var(--ac); }
.t-executive .pg-top { padding: calc(var(--m) * 0.85) var(--m) 0; }
.t-executive .pg-body { padding: calc(var(--m) * 0.6) var(--m) var(--m); }
.t-executive.pg-n .pg-body { padding-top: calc(var(--m) * 0.85); }
.t-executive .r-head { display: flex; gap: 6mm; align-items: center; justify-content: space-between; padding-bottom: 0.9em; border-bottom: 0.6pt solid #d5d9e0; }
.t-executive .r-name { color: var(--ac); font-size: 2.6em; }
.t-executive .r-headline { color: #4b5260; text-transform: uppercase; letter-spacing: 0.16em; font-size: 0.9em; margin-top: 0.45em; }
.t-executive .r-h { display: flex; align-items: center; gap: 0.7em; text-transform: uppercase; letter-spacing: 0.14em; font-size: 0.92em; }
.t-executive .r-h::after { content: ""; flex: 1; height: 0.6pt; background: #cfd4dc; }

/* ---------- template: Swiss ---------- */
.t-swiss .pg-top { padding: var(--m) var(--m) 0; }
.t-swiss .pg-body { padding: calc(var(--m) * 0.7) var(--m) var(--m); }
.t-swiss.pg-n .pg-body { padding-top: var(--m); }
.t-swiss .r-head { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 0 6mm; align-items: end; }
.t-swiss .r-head .r-photo { grid-column: 2; grid-row: 1 / span 3; border-radius: 0; }
.t-swiss .r-name { font-size: 3.1em; font-weight: 800; letter-spacing: -0.025em; line-height: 1; }
.t-swiss .r-headline { font-size: 1.3em; font-weight: 600; margin-top: 0.3em; }
.t-swiss .r-contact { margin-top: 0.9em; }
.t-swiss .r-h { color: #15181e; font-size: 1.1em; font-weight: 800; padding: 0.55em 0 0 calc(27mm + 5mm); border-top: 1.4pt solid #15181e; position: relative; }
.t-swiss .r-h::before { content: ""; position: absolute; left: 0; top: -1.4pt; width: 27mm; height: 1.4pt; background: var(--ac); }
.t-swiss .r-entry { display: grid; grid-template-columns: 27mm minmax(0, 1fr); column-gap: 5mm; }
.t-swiss .r-entry > * { grid-column: 2; }
.t-swiss .r-entry > .r-when { display: block; grid-column: 1; grid-row: 1 / span 2; font-size: 0.86em; color: #4b5260; font-variant-numeric: tabular-nums; padding-top: 0.12em; }
.t-swiss .r-entry .r-date { display: none; }
.t-swiss .r-para, .t-swiss .r-tags, .t-swiss .r-sk, .t-swiss .r-lang, .t-swiss .r-ref, .t-swiss .r-refs-grid { margin-left: calc(27mm + 5mm); }
.t-swiss .r-org { font-style: normal; color: var(--ac); font-weight: 600; }

/* ---------- template: Sidebar ---------- */
.t-sidebar .pg-body { grid-template-columns: 33% minmax(0, 1fr); }
.t-sidebar .col-side { background: var(--ac); color: var(--on-ac); padding: var(--m) calc(var(--m) * 0.75); }
.t-sidebar .col-main { padding: var(--m) var(--m) var(--m) calc(var(--m) * 0.9); }
.t-sidebar .col-side .r-photo { width: 34mm; height: 34mm; margin: 0 auto 1.1em; border: 0.9mm solid color-mix(in srgb, var(--on-ac) 30%, transparent); }
.t-sidebar .col-side .r-contact { flex-direction: column; gap: 0.45em; margin-top: 0; color: inherit; }
.t-sidebar .col-side .r-ci { align-items: flex-start; overflow-wrap: anywhere; }
.t-sidebar .col-side .r-ci .ri { stroke: currentColor; margin-top: 0.15em; align-self: flex-start; }
.t-sidebar .col-side .r-ci .rk { color: var(--on-ac-2); }
.t-sidebar .col-side .r-h { color: inherit; text-transform: uppercase; letter-spacing: 0.14em; font-size: 0.86em; padding-bottom: 0.35em; border-bottom: 0.6pt solid color-mix(in srgb, var(--on-ac) 40%, transparent); }
.t-sidebar .col-side .r-title, .t-sidebar .col-side .r-sk-name, .t-sidebar .col-side .r-sk-kw, .t-sidebar .col-side .r-l2,
.t-sidebar .col-side .r-date, .t-sidebar .col-side .r-loc, .t-sidebar .col-side .r-lvl, .t-sidebar .col-side .r-url { color: inherit; }
.t-sidebar .col-side .r-lvl, .t-sidebar .col-side .r-date { color: var(--on-ac-2); }
.t-sidebar .col-side .r-tag { background: color-mix(in srgb, #000000 18%, transparent); color: inherit; } /* a light tint under white text fell to 3.4:1 */
.t-sidebar .col-side .r-dots i { border-color: var(--on-ac); }
.t-sidebar .col-side .r-dots i.on { background: var(--on-ac); }
.t-sidebar .col-side li::marker { color: inherit; }
.t-sidebar .col-side .r-l1, .t-sidebar .col-side .r-l2 { flex-direction: column; align-items: flex-start; gap: 0; }
.t-sidebar .col-side .r-date, .t-sidebar .col-side .r-loc { margin-left: 0; }
.t-sidebar .col-main > .r-head { margin-bottom: 0.3em; }
.t-sidebar .col-main .r-name { font-size: 2.6em; }
.t-sidebar .col-main .r-h { text-transform: uppercase; letter-spacing: 0.12em; font-size: 0.95em; padding-bottom: 0.3em; border-bottom: 1.2pt solid var(--ac); }

/* ---------- template: Timeline ---------- */
.t-timeline .pg-top { padding: var(--m) var(--m) 0; }
.t-timeline .pg-body { padding: calc(var(--m) * 0.7) var(--m) var(--m); }
.t-timeline.pg-n .pg-body { padding-top: var(--m); }
.t-timeline .r-head { display: flex; align-items: center; gap: 6mm; }
.t-timeline .r-name { font-size: 2.55em; }
.t-timeline .r-h { font-size: 1.2em; display: flex; align-items: center; gap: 0.5em; }
.t-timeline .r-h::before { content: ""; width: 0.55em; height: 0.55em; background: var(--ac); border-radius: 0.12em; transform: rotate(45deg); flex: none; }
.t-timeline .r-entry.dated { position: relative; margin-top: 0; padding: calc(0.75em * var(--sp)) 0 0 6.5mm; border-left: 0.75pt solid #c9ced8; margin-left: 1.2mm; }
.t-timeline .r-h + .r-entry.dated { padding-top: 0.15em; }
.t-timeline .r-entry.dated.cont { padding-top: 0; }
.t-timeline .r-entry.dated:not(.cont)::before {
  content: ""; position: absolute; left: -1.45mm; top: calc(0.75em * var(--sp) + 0.38em); width: 2.9mm; height: 2.9mm; border-radius: 50%;
  background: #fff; border: 0.9pt solid var(--ac); box-sizing: border-box;
}
.t-timeline .r-h + .r-entry.dated:not(.cont)::before { top: 0.53em; }
.t-timeline .r-date { color: var(--ac); font-weight: 600; }

/* ---------- template: Banner ---------- */
.t-banner .pg-top { background: var(--ac); color: var(--on-ac); padding: var(--m) var(--m) calc(var(--m) * 0.8); }
.t-banner .pg-body { padding: calc(var(--m) * 0.8) var(--m) var(--m); }
.t-banner.pg-n .pg-body { padding-top: var(--m); }
.t-banner .r-head { display: flex; align-items: center; justify-content: space-between; gap: 6mm; }
.t-banner .r-head .r-photo { width: 30mm; height: 30mm; border: 0.9mm solid color-mix(in srgb, var(--on-ac) 35%, transparent); }
.t-banner .r-name { color: inherit; font-size: 2.75em; font-weight: 800; }
.t-banner .r-headline { color: var(--on-ac-2); }
.t-banner .r-contact { color: inherit; }
.t-banner .r-contact .ri { stroke: currentColor; }
.t-banner .r-contact .rk { color: var(--on-ac-2); }
.t-banner .pg-top .r-ph { color: var(--on-ac-2) !important; } /* on the band only: the original's rule also reached the letter's placeholder on white */
.t-banner .r-h { border-left: 1.6mm solid var(--ac); padding-left: 2.6mm; text-transform: uppercase; letter-spacing: 0.1em; font-size: 1em; color: #15181e; }
.t-banner .r-tag { background: var(--ac); color: var(--on-ac); border-radius: 99em; padding: 0.15em 0.75em; }

/* ---------- template: Compact ---------- */
.t-compact .pg-top { padding: var(--m) var(--m) 0; }
.t-compact .pg-body { padding: calc(var(--m) * 0.6) var(--m) var(--m); grid-template-columns: minmax(0, 1.75fr) minmax(0, 1fr); column-gap: 6mm; }
.t-compact.pg-n .pg-body { padding-top: var(--m); }
.t-compact .col-side { border-left: 0.6pt solid #d5d9e0; padding-left: 5mm; }
.t-compact .r-head { display: flex; gap: 5mm; align-items: flex-end; padding-bottom: 0.8em; border-bottom: 1.2pt solid #15181e; }
.t-compact .r-head .r-photo { width: 22mm; height: 22mm; }
.t-compact .r-head-text { flex: 1; min-width: 0; }
.t-compact .r-name { font-size: 2.2em; }
.t-compact .r-contact { flex-direction: column; align-items: flex-end; gap: 0.1em; margin: 0; text-align: right; font-size: 0.9em; }
.t-compact .r-h { text-transform: uppercase; letter-spacing: 0.12em; font-size: 0.9em; margin-top: calc(1.2em * var(--sp)); }
.t-compact .col-side .r-l1, .t-compact .col-side .r-l2 { flex-direction: column; align-items: flex-start; gap: 0; }
.t-compact .col-side .r-date, .t-compact .col-side .r-loc { margin-left: 0; }

/* ---------- template: Elegant ---------- */
.t-elegant .pg-top { padding: var(--m) var(--m) 0; text-align: center; }
.t-elegant .pg-body { padding: calc(var(--m) * 0.6) var(--m) var(--m); }
.t-elegant.pg-n .pg-body { padding-top: var(--m); }
.t-elegant .r-head { padding-bottom: 1em; border-bottom: 2.2pt double var(--ac); }
.t-elegant .r-head .r-photo { margin: 0 auto 0.8em; width: 25mm; height: 25mm; }
.t-elegant .r-name { font-weight: 400; text-transform: uppercase; letter-spacing: 0.2em; font-size: 2.2em; margin-right: -0.2em; }
.t-elegant .r-headline { font-style: italic; margin-top: 0.35em; }
.t-elegant .r-contact { justify-content: center; gap: 0.1em 0; }
.t-elegant .r-contact .r-ci + .r-ci:not(.lead)::before { content: ""; width: 0.28em; height: 0.28em; border-radius: 50%; background: var(--ac); margin: 0 0.8em; align-self: center; }
.t-elegant .r-h { display: flex; align-items: center; gap: 0.9em; justify-content: center; text-transform: uppercase; letter-spacing: 0.22em; font-weight: 600; font-size: 0.92em; }
.t-elegant .r-h::before, .t-elegant .r-h::after { content: ""; flex: 1; height: 0.5pt; background: color-mix(in srgb, var(--ac) 55%, #fff); }
.t-elegant .r-title { font-weight: 600; }
.t-elegant .r-para { text-align: center; }
.t-elegant .r-tags { justify-content: center; }
