/* Resume document – ONE scale for every template. Everything is in em, driven by --fs. */
.doc{--ac:#4871e0;--hc:var(--ac);--tc:#222;--bg-d:#fff;--ff:Arial,Helvetica,sans-serif;--fs:15px;--sp:14px;
  box-sizing:border-box;width:100%;min-height:1123px;padding:2.4em 2.6em;
  font-family:var(--ff);font-size:var(--fs);line-height:1.5;color:var(--tc);background:var(--bg-d);text-align:left}
.doc,.doc *{box-sizing:border-box}
.doc h1,.doc h2,.doc p,.doc ul,.doc li,.doc div{margin:0}

/* header */
.doc h1{font-size:2.1em;line-height:1.15;font-weight:800;color:var(--hc);letter-spacing:-.01em}
.doc .ti{font-size:1.15em;font-weight:600;color:var(--ac);margin-top:.15em}
.doc .ct{font-size:.88em;color:#555;margin-top:.5em;overflow-wrap:anywhere}
.doc .rph{display:block;width:5.5em;height:5.5em;border-radius:50%;object-fit:cover;margin-bottom:.7em;border:.15em solid var(--ac)}

/* sections – same size for every template */
.doc .sc{margin-top:calc(var(--sp) * 1.3)}
.doc h2{font-size:1em;font-weight:800;line-height:1.3;color:var(--hc);text-transform:uppercase;letter-spacing:.06em;margin-bottom:.5em}
.doc p{font-size:1em;margin-bottom:.3em}
.doc ul{padding-left:1.15em}
.doc li{font-size:1em;margin-bottom:.22em}
.doc li::marker{color:var(--ac)}
.doc p b{font-weight:700}

/* heading styles (config.heading_style) */
.doc.hs-ul h2{border-bottom:.12em solid var(--ac);padding-bottom:.2em}
.doc.hs-bar h2{border-left:.3em solid var(--ac);padding-left:.55em}
.doc.hs-bg h2{background:var(--ac);color:#fff;padding:.25em .6em;border-radius:.2em}
.doc.hs-line h2{display:flex;align-items:center;gap:.6em}
.doc.hs-line h2::after{content:"";flex:1;height:1px;background:var(--ac);opacity:.5}
.doc.hs-plain h2{text-transform:none;letter-spacing:0;font-size:1.1em}

/* layouts (config.layout) */
.doc .hd.ctr{text-align:center}
.doc .hd.ctr .rph{margin-left:auto;margin-right:auto}
.doc .hd.spl{display:flex;justify-content:space-between;align-items:flex-end;gap:1.5em}
.doc .hd.spl .ct{text-align:right;margin:0;max-width:45%}
.doc .band{margin:-2.4em -2.6em 0;padding:1.8em 2.6em;background:var(--ac);color:#fff}
.doc .band h1,.doc .band .ti,.doc .band .ct{color:#fff}
.doc .band .rph{float:right;margin:0 0 0 1em;border-color:#fff}

.doc.lay-side,.doc.lay-rside{display:grid;padding:0}
.doc.lay-side{grid-template-columns:31% 1fr}
.doc.lay-rside{grid-template-columns:1fr 31%}
.doc.lay-side>div,.doc.lay-rside>div{padding:2.2em 1.6em}
.doc.lay-side>div:first-child,.doc.lay-rside>div:last-child{background:var(--ac);color:#fff}
.doc.lay-side>div:first-child :is(h1,h2,.ti,.ct,p,li),
.doc.lay-rside>div:last-child :is(h1,h2,.ti,.ct,p,li){color:#fff;border-color:rgba(255,255,255,.45)}
.doc.lay-side>div:first-child h2,.doc.lay-rside>div:last-child h2{background:rgba(255,255,255,.18)}
.doc.lay-side>div:first-child li::marker,.doc.lay-rside>div:last-child li::marker{color:#fff}
.doc.lay-side .rph{margin-left:auto;margin-right:auto;border-color:#fff}

/* scaled "paper" used by cards, preview panel and editor */
.fit{position:relative;overflow:hidden;container-type:inline-size;aspect-ratio:794/1123;background:#fff;border-radius:6px}
.fit-in{width:794px;transform-origin:0 0;scale:tan(atan2(100cqw,794px));pointer-events:none}
.fit.auto{aspect-ratio:auto;overflow:visible}
.fit.auto .fit-in{scale:none;zoom:tan(atan2(100cqw,794px));pointer-events:auto}

@media print{
  .fit,.fit.auto{aspect-ratio:auto;overflow:visible;container-type:normal}
  .fit-in,.fit.auto .fit-in{scale:none;zoom:1;width:100%}
  .doc{min-height:0}
}