/* ============================================================
   CV Maker - editor extras and the five paper templates.
   Paper sizes mirror the PDF: 1pt = 1.3333px (A4 = 794px wide).
   ============================================================ */

@font-face { font-family: "CV Noto Sans"; src: url("/lib/fonts/noto/NotoSans-Regular.ttf") format("truetype"); font-weight: 400; font-display: swap; }
@font-face { font-family: "CV Noto Sans"; src: url("/lib/fonts/noto/NotoSans-Bold.ttf") format("truetype"); font-weight: 700; font-display: swap; }
@font-face { font-family: "CV Noto Sans"; src: url("/lib/fonts/noto/NotoSans-Italic.ttf") format("truetype"); font-weight: 400; font-style: italic; font-display: swap; }
@font-face { font-family: "CV Noto Serif"; src: url("/lib/fonts/noto/NotoSerif-Regular.ttf") format("truetype"); font-weight: 400; font-display: swap; }
@font-face { font-family: "CV Noto Serif"; src: url("/lib/fonts/noto/NotoSerif-Bold.ttf") format("truetype"); font-weight: 700; font-display: swap; }

/* ---------------- editor extras ---------------- */
.cv-meter {
    --cv-score: 0%;
    padding: 14px 16px; border-radius: var(--dst-radius); background: #fff; border: 1px solid var(--dst-line);
    box-shadow: 0 10px 30px rgba(18, 26, 51, .05);
}
.cv-meter-top { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; margin: 0 0 8px; }
.cv-meter-label { font-size: 14px; font-weight: 800; color: var(--dst-ink); }
.cv-meter-value { font-size: 20px; font-weight: 800; color: var(--dst-accent); font-variant-numeric: tabular-nums; }
.cv-meter-track { position: relative; height: 9px; border-radius: 999px; background: var(--dst-soft); overflow: hidden; }
.cv-meter-fill {
    position: absolute; inset: 0 auto 0 0; width: var(--cv-score); border-radius: inherit;
    background: linear-gradient(90deg, var(--dst-accent), var(--dst-accent-2)); transition: width .5s cubic-bezier(.2,.8,.2,1);
}
.cv-meter.is-low .cv-meter-fill { background: linear-gradient(90deg, #f59e0b, #f97316); }
.cv-meter.is-high .cv-meter-fill { background: linear-gradient(90deg, #16a34a, var(--dst-accent-2)); }
.cv-meter-tip { margin: 8px 0 0; font-size: 13px; line-height: 1.45; color: var(--dst-ink-2); }

.cv-count { transition: color .2s ease; }
.cv-count.is-good { color: #15803d; }
.cv-tips { margin: 10px 0 0; padding: 10px 12px 10px 30px; border-radius: 12px; background: var(--dst-accent-soft); font-size: 13px; line-height: 1.55; color: var(--dst-ink-2); }
.cv-warn { color: #9a3412; font-weight: 600; }
.cv-extra { margin-top: 12px; padding-top: 12px; border-top: 1px dashed var(--dst-line); }
.cv-quick { margin: 0 0 12px; }
.cv-onrequest { margin: 0 0 12px; }
.cv-after-add { margin-top: 8px; }
.cv-ats { margin: 0 0 12px; }
.dst-input:disabled { background: var(--dst-soft); color: var(--dst-ink-3); cursor: not-allowed; }

.cv-grid-compact { grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); }
.cv-rep-compact { padding: 10px 12px; }
.cv-rep-compact .dst-rep-head { margin-bottom: 6px; }

/* section manager */
.cv-secs { display: flex; flex-direction: column; gap: 6px; margin: 0 0 14px; padding: 0; list-style: none; }
.cv-secrow {
    display: flex; align-items: center; gap: 10px; padding: 7px 8px 7px 10px; border: 1px solid var(--dst-line); border-radius: 12px; background: #fff;
    transition: background-color .2s ease, opacity .2s ease; animation: dst-rise .2s ease both;
}
.cv-secrow.is-hidden { background: var(--dst-soft); }
.cv-secrow.is-hidden .cv-secrow-name { color: var(--dst-ink-3); text-decoration: line-through; }
.cv-secrow-text { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.cv-secrow-name { font-size: 13.5px; font-weight: 700; color: var(--dst-ink); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cv-secrow-state { font-size: 11.5px; color: var(--dst-ink-3); }
.cv-secrow-state:empty { display: none; }
.cv-secrow-tools { display: flex; gap: 4px; }
.cv-switch { position: relative; flex: none; display: inline-block; width: 36px; height: 20px; margin: 0; cursor: pointer; }
.cv-switch input { position: absolute; inset: 0; width: 100%; height: 100%; margin: 0; opacity: 0; cursor: pointer; }
.cv-switch-ui { position: absolute; inset: 0; border-radius: 999px; background: #cfd6e4; transition: background-color .2s ease; pointer-events: none; }
.cv-switch-ui::after { content: ""; position: absolute; top: 3px; left: 3px; width: 14px; height: 14px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(0,0,0,.2); transition: transform .2s ease; }
.cv-switch input:checked + .cv-switch-ui { background: var(--dst-accent); }
.cv-switch input:checked + .cv-switch-ui::after { transform: translateX(16px); }
.cv-switch input:focus-visible + .cv-switch-ui { outline: 3px solid color-mix(in srgb, var(--dst-accent) 35%, transparent); outline-offset: 2px; }

@media (max-width: 640px) {
    .cv-grid-compact { grid-template-columns: minmax(0, 1fr); }
    .dst-image { flex-wrap: wrap; }
}
@media (prefers-reduced-motion: reduce) {
    .cv-meter-fill, .cv-secrow { transition: none; animation: none; }
}

/* ============================================================
   Paper (shared)
   ============================================================ */
.dst-paper .cv {
    --a: var(--doc-accent, #2563eb);
    --ink: #1f2433; --body: #333a4d; --muted: #5d6679; --line: #dfe3eb;
    position: relative; min-height: 1123px; color: var(--body);
    font-family: "CV Noto Sans", "Noto Sans", "Segoe UI", Arial, sans-serif; font-size: 12.67px; line-height: 1.45;
}
.dst-paper .cv * { box-sizing: border-box; }
.dst-paper .cv a { color: inherit; text-decoration: none; }
.dst-paper .cv p { margin: 0; }
.dst-paper .cv .is-placeholder { color: #b7bdcc !important; }
.dst-paper .cv-empty { margin: 18px 0 0; padding: 18px; border: 1.5px dashed #d5dae6; border-radius: 10px; color: #8a92a6; font-size: 14px; text-align: center; }

.dst-paper .cv-name { color: var(--ink); font-size: 33px; font-weight: 700; line-height: 1.15; letter-spacing: -.01em; overflow-wrap: anywhere; }
.dst-paper .cv-role { margin-top: 3px; color: var(--a); font-size: 16.7px; line-height: 1.3; overflow-wrap: anywhere; }
.dst-paper .cv-contact { --sep-space: 21px; margin-top: 8px; overflow: hidden; color: var(--muted); font-size: 12px; line-height: 1.55; }
.dst-paper .cv-contact-in { display: flex; flex-wrap: wrap; align-items: center; row-gap: 2px; margin-left: calc(-1 * var(--sep-space)); }
.dst-paper .cv-ci { display: inline-flex; align-items: center; min-width: 0; max-width: 100%; }
.dst-paper .cv-contact-item { min-width: 0; overflow-wrap: anywhere; }
.dst-paper .cv-contact a.cv-contact-item:hover { text-decoration: underline; }
.dst-paper .cv-sep { flex: none; display: inline-block; width: 1px; height: 11px; margin: 0 10px; background: color-mix(in srgb, var(--a) 45%, #cfd4de); }
.dst-paper .cv-extras { margin-top: 0; font-size: 11.3px; }

.dst-paper .cv-photo { flex: none; width: 104px; height: 104px; border-radius: 50%; overflow: hidden; background: #eef1f6; }
.dst-paper .cv-photo img { display: block; width: 100%; height: 100%; object-fit: cover; }

.dst-paper .cv-sec { margin-bottom: 16px; }
.dst-paper .cv-h { color: var(--a); font-size: 14px; font-weight: 700; line-height: 1.3; text-transform: uppercase; letter-spacing: .03em; margin-bottom: 10px; }
.dst-paper .cv-summary { font-size: 13.3px; line-height: 1.5; color: var(--body); }
.dst-paper .cv-inline-list { line-height: 1.5; }

.dst-paper .cv-entry { margin-bottom: 11px; break-inside: avoid; }
.dst-paper .cv-entry-top { display: flex; align-items: flex-start; gap: 16px; }
.dst-paper .cv-entry-title { flex: 1; min-width: 0; color: var(--ink); font-size: 14px; font-weight: 700; line-height: 1.3; overflow-wrap: anywhere; }
.dst-paper .cv-entry-date { flex: none; max-width: 45%; padding-top: 2px; color: var(--muted); font-size: 11.3px; white-space: nowrap; }
.dst-paper .cv-entry-sub { display: block; color: var(--a); font-size: 12.67px; line-height: 1.35; overflow-wrap: anywhere; }
.dst-paper .cv-entry-text { margin-top: 3px !important; }
.dst-paper .cv-bullets { margin: 3px 0 0; padding: 0; list-style: none; }
.dst-paper .cv-bullets li { position: relative; margin: 0 0 2px; padding-left: 15px; line-height: 1.45; overflow-wrap: anywhere; }
.dst-paper .cv-bullets li::before { content: ""; position: absolute; left: 2px; top: .62em; width: 5px; height: 5px; border-radius: 50%; background: var(--a); }

.dst-paper .cv-tags { display: flex; flex-wrap: wrap; gap: 8px; }
.dst-paper .cv-tag { padding: 3px 11px; border-radius: 999px; background: color-mix(in srgb, var(--a) 14%, #fff); color: var(--cv-deep, var(--a)); font-size: 11.3px; font-weight: 700; line-height: 1.45; }
.dst-paper .cv-dots-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 4px 21px; }
.dst-paper .cv-dot-row { display: flex; align-items: flex-start; justify-content: space-between; gap: 6px; }
.dst-paper .cv-dot-name { color: var(--ink); overflow-wrap: anywhere; }
.dst-paper .cv-dots { flex: none; display: inline-flex; gap: 4px; padding-top: 5px; }
.dst-paper .cv-dots i { width: 7px; height: 7px; border-radius: 50%; background: var(--cv-tint-2, #d7e2ff); }
.dst-paper .cv-dots i.on { background: var(--a); }
.dst-paper .cv-langs { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 6px 21px; }
.dst-paper .cv-lang strong { display: block; color: var(--ink); font-size: 12.67px; overflow-wrap: anywhere; }
.dst-paper .cv-lang small { display: block; color: var(--muted); font-size: 11.3px; }
.dst-paper .cv-refs { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px 26px; }
.dst-paper .cv-ref strong { display: block; color: var(--ink); font-size: 13.3px; }
.dst-paper .cv-ref span, .dst-paper .cv-ref a { display: block; font-size: 12px; color: var(--muted); overflow-wrap: anywhere; }
.dst-paper .cv-ref a.cv-ref-contact { color: var(--a); }

/* ============================================================
   Modern - tinted sidebar
   ============================================================ */
.dst-paper .cv-modern { display: grid; grid-template-columns: 253px minmax(0, 1fr); }
.dst-paper .cv-modern .cv-side { position: relative; padding: 45px 32px 40px; background: var(--cv-tint, #eef3ff); box-shadow: inset 5px 0 0 var(--a); }
.dst-paper .cv-modern .cv-side .cv-photo { width: 139px; height: 139px; margin: 0 auto 29px; box-shadow: 0 0 0 5px #fff; }
.dst-paper .cv-modern .cv-side .cv-h { padding-bottom: 7px; margin-bottom: 11px; border-bottom: 1px solid var(--cv-tint-2, #c6d6fb); color: color-mix(in srgb, var(--a) 90%, #000); font-size: 12.67px; }
.dst-paper .cv-modern .cv-side .cv-sec { margin-bottom: 22px; }
.dst-paper .cv-side-item { margin-bottom: 8px; }
.dst-paper .cv-side-item small { display: block; color: var(--muted); font-size: 9.3px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; }
.dst-paper .cv-side-value { display: block; color: var(--ink); font-size: 12px; line-height: 1.35; overflow-wrap: anywhere; }
.dst-paper .cv-side a.cv-side-value { color: color-mix(in srgb, var(--a) 85%, #000); }
.dst-paper .cv-bar-row { margin-bottom: 8px; }
.dst-paper .cv-bar-name { display: block; color: var(--ink); font-size: 12px; line-height: 1.35; overflow-wrap: anywhere; }
.dst-paper .cv-bar { display: block; height: 5px; margin-top: 3px; border-radius: 3px; background: var(--cv-tint-2, #c6d6fb); overflow: hidden; }
.dst-paper .cv-bar i { display: block; height: 100%; border-radius: inherit; background: var(--a); }
.dst-paper .cv-lang-row { display: flex; justify-content: space-between; gap: 8px; margin-bottom: 4px; color: var(--ink); font-size: 12px; }
.dst-paper .cv-lang-row small { flex: none; color: var(--muted); font-size: 11.3px; }
.dst-paper .cv-modern .cv-side .cv-inline-list { font-size: 12px; }
.dst-paper .cv-modern .cv-main { min-width: 0; padding: 53px 48px 48px 37px; }
.dst-paper .cv-modern .cv-head { margin-bottom: 21px; }
.dst-paper .cv-modern .cv-main .cv-h { display: flex; align-items: center; gap: 13px; }
.dst-paper .cv-modern .cv-main .cv-h::after { content: ""; flex: 1; height: 1px; background: var(--line); }

/* ============================================================
   Classic - top rule, underlined headings, photo right
   ============================================================ */
.dst-paper .cv-classic { padding: 64px 61px 56px; box-shadow: inset 0 7px 0 var(--a); }
.dst-paper .cv-classic .cv-head { display: flex; align-items: flex-start; gap: 27px; padding-bottom: 11px; margin-bottom: 21px; border-bottom: 2px solid var(--a); }
.dst-paper .cv-classic .cv-head-text { flex: 1; min-width: 0; }
.dst-paper .cv-classic .cv-photo { width: 104px; height: 104px; }
.dst-paper .cv-classic .cv-h { padding-bottom: 5px; margin-bottom: 11px; border-bottom: 1.2px solid var(--a); font-size: 15.3px; }

/* ============================================================
   Minimal ATS - black and white, one column, no graphics
   ============================================================ */
.dst-paper .cv-ats { padding: 59px 61px 56px; color: var(--body); }
.dst-paper .cv-ats .cv-head { padding-bottom: 11px; margin-bottom: 21px; border-bottom: 1px solid #6b7280; }
.dst-paper .cv-ats .cv-name { font-size: 28px; }
.dst-paper .cv-ats .cv-role { color: var(--body); font-size: 15.3px; }
.dst-paper .cv-ats .cv-contact { --sep-space: 19px; color: var(--ink); font-size: 12.67px; }
.dst-paper .cv-ats .cv-sep { width: 7px; height: auto; margin: 0 6px; background: none; text-align: center; }
.dst-paper .cv-ats .cv-sep::before { content: "|"; color: #6b7280; }
.dst-paper .cv-ats .cv-h { padding-bottom: 5px; margin-bottom: 10px; border-bottom: 1px solid #9ca3af; color: var(--ink); font-size: 14.7px; letter-spacing: .02em; }
.dst-paper .cv-ats .cv-entry-sub { color: var(--body); }
.dst-paper .cv-ats .cv-bullets li::before { background: var(--ink); width: 4px; height: 4px; }
.dst-paper .cv-ats a { text-decoration: underline; }

/* ============================================================
   Elegant - serif, centred header, ruled headings
   ============================================================ */
.dst-paper .cv-elegant { padding: 59px 61px 56px; font-family: "CV Noto Serif", "Noto Serif", Georgia, "Times New Roman", serif; }
.dst-paper .cv-elegant .cv-head { display: flex; flex-direction: column; align-items: center; gap: 16px; padding-bottom: 20px; margin-bottom: 22px; text-align: center;
    border-bottom: 1px solid var(--cv-tint-2, #c6d6fb); box-shadow: 0 3px 0 -2px var(--cv-tint-2, #c6d6fb); }
.dst-paper .cv-elegant .cv-head-text { display: flex; flex-direction: column; align-items: center; }
.dst-paper .cv-elegant .cv-photo { width: 101px; height: 101px; }
.dst-paper .cv-elegant .cv-name { font-size: 36px; letter-spacing: 0; }
.dst-paper .cv-elegant .cv-role { font-size: 13.3px; text-transform: uppercase; letter-spacing: .08em; }
/* centred lines cannot clip a leading separator, so Elegant spaces items instead (the PDF matches) */
.dst-paper .cv-elegant .cv-contact { align-self: stretch; }
.dst-paper .cv-elegant .cv-contact-in { justify-content: center; column-gap: 24px; margin-left: 0; }
.dst-paper .cv-elegant .cv-sep { display: none; }
.dst-paper .cv-elegant .cv-h { display: flex; align-items: center; gap: 16px; letter-spacing: .08em; }
.dst-paper .cv-elegant .cv-h::before, .dst-paper .cv-elegant .cv-h::after { content: ""; flex: 1; height: 1px; background: var(--cv-tint-2, #c6d6fb); }
.dst-paper .cv-elegant .cv-entry-sub { color: var(--muted); font-style: italic; }

/* ============================================================
   Bold - full-width colour header
   ============================================================ */
.dst-paper .cv-bold .cv-head { display: flex; align-items: center; gap: 32px; min-height: 203px; padding: 51px 61px 40px; background: var(--a); color: #fff; }
.dst-paper .cv-bold .cv-head-text { flex: 1; min-width: 0; }
.dst-paper .cv-bold .cv-name { color: #fff; font-size: 36px; }
.dst-paper .cv-bold .cv-role { color: color-mix(in srgb, var(--a) 20%, #fff); }
.dst-paper .cv-bold .cv-contact { margin-top: 11px; color: #fff; }
.dst-paper .cv-bold .cv-extras { margin-top: 0; color: color-mix(in srgb, var(--a) 18%, #fff); }
.dst-paper .cv-bold .cv-sep { background: color-mix(in srgb, var(--a) 45%, #fff); }
.dst-paper .cv-bold .cv-photo { width: 123px; height: 123px; box-shadow: 0 0 0 5px #fff; }
.dst-paper .cv-bold .is-placeholder { color: color-mix(in srgb, var(--a) 40%, #fff) !important; }
.dst-paper .cv-bold .cv-body { padding: 35px 61px 56px; }
.dst-paper .cv-bold .cv-h { display: flex; align-items: center; gap: 11px; color: var(--ink); font-size: 16.7px; text-transform: none; letter-spacing: 0; }
.dst-paper .cv-bold .cv-h::before { content: ""; flex: none; width: 5px; height: 19px; border-radius: 2px; background: var(--a); }
