/* ===== Template 4 – Prime Sidebar (A4 = 794 x 1123 px, premium) ===== */
.tpl-prime {
  --ac: #b8923a; --ac-dark: #14284b; --ac-soft: #d9b865; --ac-tint: #f4f0e6;
  --dens: 1; --ink: #1c1f26; --gray: #5b6472; --photo: 150px; --bullet: "•"; --bfs: 1em; --bfsn: 1;
  width: 794px; min-height: 1123px; flex: none;
  display: grid; grid-template-columns: 268px 1fr;
  background: #fff; color: var(--ink);
  font-family: var(--f-body, Arial, Helvetica, 'Liberation Sans', sans-serif);
  font-size: calc(13px * var(--s-body, 1));
  line-height: calc(1.45 + (var(--dens) - 1) * .4);
  box-shadow: 0 10px 40px rgba(11, 29, 58, .22);
}
.tpl-prime, .tpl-prime * { box-sizing: border-box; }

/* Sidebar */
.tpl-prime .side { --ln: rgba(255, 255, 255, .3); background: var(--ac-dark); color: #fff; padding: 40px 26px 34px 28px; }
.tpl-prime.sb-light .side { --ln: var(--ac); background: var(--ac-tint); color: var(--ink); }
.tpl-prime .main { --ln: var(--ac); padding: 44px 44px 34px 40px; }
.tpl-prime.has-foot .side, .tpl-prime.has-foot .main { padding-bottom: 56px; }

.tpl-prime .photo-wrap { width: var(--photo); height: var(--photo); margin: 0 auto calc(26px * var(--dens)); }
.tpl-prime .photo-wrap img { width: 100%; height: 100%; display: block; object-fit: contain; }

.tpl-prime .sec { margin: 0 0 calc(22px * var(--dens)); }
.tpl-prime .sec:last-child { margin-bottom: 0; }
.tpl-prime .sec h2 {
  margin: 0 0 calc(10px * var(--dens)); padding-bottom: 5px;
  font-family: var(--f-head, Georgia, 'Times New Roman', serif); font-weight: 700;
  font-size: calc(13.5px * var(--s-h2, 1)); line-height: 1.25; letter-spacing: .14em;
  text-transform: uppercase; color: var(--ac-dark); text-align: var(--a-h2, left);
}
.tpl-prime .side .sec h2 { color: var(--ac-soft); }
.tpl-prime.sb-light .side .sec h2 { color: var(--ac-dark); }
.tpl-prime.hc-off .sec h2 { text-transform: none; letter-spacing: .02em; }
/* filled headings inside the dark sidebar use the light accent so they stay visible */
.tpl-prime.hs-filled .side .sec h2 { background: var(--ac-soft); color: var(--ac-dark); }
.tpl-prime.hs-filled.sb-light .side .sec h2 { background: var(--ac); color: #fff; }

/* Sidebar content */
.tpl-prime .ci { display: flex; align-items: center; gap: 9px; margin-bottom: calc(8px * var(--dens)); }
.tpl-prime .ico { flex: none; width: 17px; height: 17px; border-radius: 50%; background: var(--ac); display: inline-flex; align-items: center; justify-content: center; }
.tpl-prime .ico svg { width: 9px; height: 9px; fill: #fff; }
.tpl-prime .txt { flex: 1; min-width: 0; overflow-wrap: anywhere; text-align: var(--a-body, left); }
.tpl-prime .pd-i { margin-bottom: calc(9px * var(--dens)); }
.tpl-prime .pd-k { display: block; font-size: .76em; letter-spacing: .12em; text-transform: uppercase; color: var(--ac-soft); }
.tpl-prime.sb-light .pd-k { color: var(--ac); }
.tpl-prime .pd-v { display: block; font-weight: 700; overflow-wrap: anywhere; }

/* Header of the main column */
.tpl-prime .head { margin-bottom: calc(26px * var(--dens)); }
.tpl-prime .name {
  margin: 0; font-family: var(--f-head, Georgia, 'Times New Roman', serif); font-weight: 700;
  font-size: calc(34px * var(--s-name, 1)); line-height: 1.1; letter-spacing: .04em;
  text-transform: uppercase; color: var(--ac-dark); text-align: var(--a-name, left); overflow-wrap: anywhere;
}
.tpl-prime.nc-off .name { text-transform: none; letter-spacing: 0; }
.tpl-prime .title-row { margin-top: 9px; text-align: var(--a-title, left); }
.tpl-prime .title {
  display: inline-block; font-family: var(--f-head, Georgia, 'Times New Roman', serif); font-weight: 600;
  font-size: calc(13px * var(--s-title, 1)); line-height: 1.3; letter-spacing: .2em; text-transform: uppercase; color: var(--ac);
}
.tpl-prime.ts-plain .title { color: var(--ink); }
.tpl-prime.ts-tag .title { background: var(--ac); color: #fff; padding: .35em .85em; border-radius: 3px; }
.tpl-prime .p-rule { width: 64px; height: 0; margin-top: 14px; border-top: 3px solid var(--ac); }

.tpl-prime .summary { margin: 0; text-align: var(--a-body, justify); white-space: pre-line; }

/* Entries (+ optional timeline) */
.tpl-prime .job, .tpl-prime .edu { margin-bottom: calc(16px * var(--dens)); }
.tpl-prime .edu:last-child { margin-bottom: 0; }
.tpl-prime .row { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; }
.tpl-prime .it { font-weight: 700; font-size: calc(14px * var(--s-sub, 1)); line-height: 1.3; color: var(--ac-dark); text-align: var(--a-sub, left); }
.tpl-prime .dt { flex: none; white-space: nowrap; color: var(--gray); font-size: .92em; font-style: italic; }
.tpl-prime .org { color: var(--ac); font-weight: 600; margin: 1px 0 4px; text-align: var(--a-body, left); }
.tpl-prime.tl-on .tl .job { position: relative; margin: 0; padding: 0 0 calc(16px * var(--dens)) 18px; border-left: 2px solid var(--ac-soft); }
.tpl-prime.tl-on .tl .job:last-child { padding-bottom: 0; }
.tpl-prime.tl-on .tl .job::before { content: ''; position: absolute; left: -7px; top: 3px; width: 12px; height: 12px; border-radius: 50%; background: var(--ac); border: 2px solid #fff; box-sizing: border-box; }
.tpl-prime:not(.tl-on) .tl .job:last-child { margin-bottom: 0; }

/* Lists with themed bullets */
.tpl-prime ul { margin: 4px 0 0; padding-left: 16px; list-style: none; }
.tpl-prime li { --lh: calc(1.45 + (var(--dens) - 1) * .4); position: relative; margin-bottom: calc(2px * var(--dens)); line-height: var(--lh); text-align: var(--a-body, left); overflow-wrap: anywhere; }
.tpl-prime li::before { content: var(--bullet); position: absolute; left: -13px; top: 0; font-size: var(--bfs); line-height: calc(var(--lh) / var(--bfsn, 1)); color: var(--ac); }
.tpl-prime .side li::before { color: var(--ac-soft); }
.tpl-prime.sb-light .side li::before { color: var(--ac); }
.tpl-prime .side ul { margin-top: 0; }
