/* ===================================================
   CURRICULUMPRO - FOLHAS DE ESTILO DOS MODELOS DE CURRÍCULO
   Dimensões A4: 210mm x 297mm (Ratio 1:1.414)
   =================================================== */

:root {
  --primary-color: #1e40af;
  --primary-light: #dbeafe;
  --primary-dark: #1e3a8a;
  --primary-tint: #eef2fb;
  --on-primary: #ffffff;
  --text-main: #1e293b;
  --text-muted: #64748b;
  --bg-sheet: #ffffff;
  --page-h: 1123px; /* altura de 1 página A4 (96 dpi) */
}

/* Folha A4 em tela e na impressão.
   A altura é sempre um múltiplo exato de página (--pages, definido pelo JS). */
.cv-sheet {
  width: 210mm;
  height: calc(var(--page-h) * var(--pages, 1));
  background: var(--bg-sheet);
  box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.1);
  box-sizing: border-box;
  position: relative;
  overflow: hidden;
  color: var(--text-main);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  font-size: 12px;
  line-height: 1.45;
  margin: 0 auto;
}

/* Durante a medição da paginação a folha cresce livremente com o conteúdo */
.cv-sheet.measuring {
  height: auto;
  min-height: var(--page-h);
}

/* Guias de quebra de página (somente no preview em tela) */
.cv-sheet:not(.exporting):not(.cv-thumb)[data-pages]:not([data-pages="1"])::after {
  content: '';
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 50;
  background-image: repeating-linear-gradient(
    to bottom,
    transparent 0,
    transparent calc(var(--page-h) - 2px),
    rgba(239, 68, 68, 0.6) calc(var(--page-h) - 2px),
    rgba(239, 68, 68, 0.6) var(--page-h)
  );
}

.cv-sheet * {
  box-sizing: border-box;
  overflow-wrap: anywhere;
  word-break: break-word;
}

/* ===================================================
   1. MODELO SÃO FRANCISCO (Creative / Fita Lateral)
   =================================================== */
.cv-sheet.template-sao-francisco {
  display: grid;
  grid-template-columns: 72mm 1fr;
  padding: 0;
}

.cv-sheet.template-sao-francisco .sf-sidebar {
  background: #f8fafc;
  display: flex;
  flex-direction: column;
  position: relative;
  border-right: 1px solid #e2e8f0;
  width: 100%;
}

/* Fita com corte em V na base */
.cv-sheet.template-sao-francisco .sf-ribbon {
  background: var(--primary-color);
  color: #ffffff;
  padding: 24px 14px 42px 14px;
  text-align: center;
  position: relative;
  clip-path: polygon(0 0, 100% 0, 100% calc(100% - 25px), 50% 100%, 0 calc(100% - 25px));
  box-shadow: 0 4px 12px rgba(0,0,0,0.15);
  width: 100%;
  box-sizing: border-box;
}

.cv-sheet.template-sao-francisco .sf-photo-container {
  width: 90px;
  height: 90px;
  margin: 0 auto 12px auto;
  border-radius: 50%;
  border: 4px solid rgba(255, 255, 255, 0.9);
  overflow: hidden;
  background: #e2e8f0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.cv-sheet.template-sao-francisco .sf-photo-container img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.cv-sheet.template-sao-francisco .sf-name {
  font-size: 20px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin: 0 0 4px 0;
  line-height: 1.2;
  overflow-wrap: anywhere;
  word-break: break-word;
}

.cv-sheet.template-sao-francisco .sf-title {
  font-size: 12px;
  font-weight: 500;
  opacity: 0.9;
  margin-bottom: 14px;
  overflow-wrap: anywhere;
  word-break: break-word;
}

.cv-sheet.template-sao-francisco .sf-summary-box {
  background: rgba(0, 0, 0, 0.28);
  border-radius: 6px;
  padding: 10px 12px;
  font-size: 11px;
  line-height: 1.45;
  text-align: left;
  overflow-wrap: anywhere;
  word-break: break-word;
  white-space: pre-wrap;
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
}

.cv-sheet.template-sao-francisco .sf-summary-content {
  overflow-wrap: anywhere;
  word-break: break-word;
  white-space: pre-wrap;
  line-height: 1.45;
  display: block;
}

.cv-sheet.template-sao-francisco .sf-summary-title {
  font-weight: 700;
  text-transform: uppercase;
  font-size: 10px;
  margin-bottom: 6px;
  letter-spacing: 1px;
  text-align: center;
}

.cv-sheet.template-sao-francisco .sf-contact-list {
  padding: 24px 18px;
  font-size: 11.5px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.cv-sheet.template-sao-francisco .sf-contact-item {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  word-break: break-word;
}

.cv-sheet.template-sao-francisco .sf-contact-icon {
  width: 22px;
  height: 22px;
  border-radius: 4px;
  background: var(--primary-light);
  color: var(--primary-color);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  font-size: 12px;
}

.cv-sheet.template-sao-francisco .sf-main {
  padding: 30px 24px;
}

.cv-sheet.template-sao-francisco .section-title {
  font-size: 14px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--primary-color);
  border-bottom: 2px solid var(--primary-color);
  padding-bottom: 4px;
  margin: 18px 0 12px 0;
  display: flex;
  align-items: center;
  gap: 8px;
}

.cv-sheet.template-sao-francisco .section-title:first-child {
  margin-top: 0;
}

/* ===================================================
   2. MODELO EUROPEAN 2023 (Formato Europeu / Timeline)
   =================================================== */
.cv-sheet.template-european {
  display: grid;
  grid-template-columns: 68mm 1fr;
  padding: 0;
}

.cv-sheet.template-european .eu-badge-top {
  position: absolute;
  top: 14px;
  left: 20px;
  background: #4f46e5;
  color: white;
  font-size: 9px;
  font-weight: 700;
  text-transform: uppercase;
  padding: 4px 10px;
  border-radius: 4px;
  letter-spacing: 1px;
}

.cv-sheet.template-european .eu-sidebar {
  background: #f1f5f9;
  padding: 45px 18px 24px 18px;
  border-right: 1px solid #e2e8f0;
}

.cv-sheet.template-european .eu-photo-circle {
  width: 100px;
  height: 100px;
  border-radius: 50%;
  border: 3px solid #ffffff;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
  margin: 0 auto 16px auto;
  overflow: hidden;
  background: #cbd5e1;
}

.cv-sheet.template-european .eu-photo-circle img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.cv-sheet.template-european .eu-sidebar-section {
  margin-top: 22px;
}

.cv-sheet.template-european .eu-sidebar-title {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  color: var(--primary-color);
  margin-bottom: 8px;
  border-bottom: 1.5px solid var(--primary-color);
  padding-bottom: 3px;
}

.cv-sheet.template-european .eu-main {
  padding: 30px 26px;
}

.cv-sheet.template-european .eu-header {
  border-bottom: 1.5px solid #e2e8f0;
  padding-bottom: 14px;
  margin-bottom: 20px;
}

.cv-sheet.template-european .eu-name {
  font-size: 24px;
  font-weight: 800;
  color: var(--text-main);
  margin: 0;
  letter-spacing: -0.5px;
}

.cv-sheet.template-european .eu-title {
  font-size: 13px;
  font-weight: 600;
  color: var(--primary-color);
  margin-top: 3px;
  text-transform: uppercase;
}

/* Timeline Vertical */
.cv-sheet.template-european .timeline-container {
  position: relative;
  padding-left: 20px;
  border-left: 2px solid var(--primary-light);
  margin-left: 6px;
}

.cv-sheet.template-european .timeline-item {
  position: relative;
  margin-bottom: 18px;
}

.cv-sheet.template-european .timeline-dot {
  position: absolute;
  left: -27px;
  top: 4px;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: #ffffff;
  border: 3px solid var(--primary-color);
}

/* ===================================================
   3. MODELO TAMPA / ATS (Otimizado para Robôs de RH)
   =================================================== */
.cv-sheet.template-tampa-ats {
  padding: 0;
}

.cv-sheet.template-tampa-ats .ats-header-block {
  background: var(--primary-color);
  color: #ffffff;
  padding: 24px 28px;
}

.cv-sheet.template-tampa-ats .ats-badge {
  display: inline-block;
  background: rgba(255, 255, 255, 0.2);
  color: #ffffff;
  font-size: 9px;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 3px;
  margin-bottom: 8px;
  letter-spacing: 1px;
}

.cv-sheet.template-tampa-ats .ats-name {
  font-size: 26px;
  font-weight: 800;
  text-transform: uppercase;
  margin: 0 0 4px 0;
  letter-spacing: 0.5px;
}

.cv-sheet.template-tampa-ats .ats-role {
  font-size: 14px;
  font-weight: 500;
  opacity: 0.95;
  margin-bottom: 10px;
}

.cv-sheet.template-tampa-ats .ats-name:only-child,
.cv-sheet.template-tampa-ats .ats-name + .ats-contacts {
  margin-top: 10px;
}

.cv-sheet.template-tampa-ats .ats-contacts {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 16px;
  font-size: 11.5px;
  opacity: 0.95;
  border-top: 1px solid rgba(255, 255, 255, 0.25);
  padding-top: 10px;
}

.cv-sheet.template-tampa-ats .ats-body {
  padding: 24px 28px;
}

.cv-sheet.template-tampa-ats .ats-section {
  margin-bottom: 20px;
}

.cv-sheet.template-tampa-ats .ats-section-title {
  font-size: 13.5px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  color: var(--primary-color);
  border-bottom: 1.5px solid var(--primary-color);
  padding-bottom: 3px;
  margin-bottom: 11px;
}

/* ===================================================
   4. MODELO MUNIQUE (Minimalista Executivo Serif)
   =================================================== */
.cv-sheet.template-munique {
  padding: 32px 30px;
  font-family: Georgia, "Times New Roman", serif;
}

.cv-sheet.template-munique .munique-badge {
  display: inline-block;
  background: #3b82f6;
  color: white;
  font-family: sans-serif;
  font-size: 9px;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: 3px;
  margin-bottom: 10px;
  letter-spacing: 0.5px;
}

.cv-sheet.template-munique .munique-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  border-bottom: 1.5px solid #334155;
  padding-bottom: 16px;
  margin-bottom: 20px;
}

.cv-sheet.template-munique .munique-name {
  font-size: 28px;
  font-weight: 700;
  letter-spacing: 1px;
  color: #0f172a;
  text-transform: uppercase;
  margin: 0;
}

.cv-sheet.template-munique .munique-role {
  font-size: 13px;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: #475569;
  margin-top: 4px;
}

.cv-sheet.template-munique .munique-photo {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  overflow: hidden;
  border: 1px solid #cbd5e1;
  background: #f1f5f9;
}

.cv-sheet.template-munique .munique-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.cv-sheet.template-munique .munique-grid {
  display: grid;
  grid-template-columns: 58mm 1fr;
  gap: 24px;
}

.cv-sheet.template-munique .munique-side-title {
  font-size: 11px;
  font-family: sans-serif;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 1.2px;
  color: #0f172a;
  margin-bottom: 8px;
  border-bottom: 1px solid #94a3b8;
  padding-bottom: 2px;
}

/* ===================================================
   5. MODELO DANIELA / MODERNO CORPORATIVO
   =================================================== */
.cv-sheet.template-daniela-modern {
  display: grid;
  grid-template-columns: 68mm 1fr;
  padding: 0;
}

.cv-sheet.template-daniela-modern .dm-sidebar {
  background: #f8fafc;
  border-right: 1px solid #e2e8f0;
  padding: 28px 18px;
}

.cv-sheet.template-daniela-modern .dm-avatar-box {
  text-align: center;
  margin-bottom: 20px;
}

.cv-sheet.template-daniela-modern .dm-photo {
  width: 100px;
  height: 100px;
  border-radius: 50%;
  margin: 0 auto;
  border: 3px solid var(--primary-color);
  overflow: hidden;
  background: #e2e8f0;
}

.cv-sheet.template-daniela-modern .dm-monogram {
  width: 75px;
  height: 75px;
  border-radius: 50%;
  margin: 0 auto;
  background: var(--primary-light);
  color: var(--primary-color);
  font-size: 24px;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 2px solid var(--primary-color);
}

.cv-sheet.template-daniela-modern .dm-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.cv-sheet.template-daniela-modern .dm-side-title {
  font-size: 11px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--primary-color);
  border-bottom: 1.5px solid var(--primary-color);
  padding-bottom: 3px;
  margin: 18px 0 10px 0;
}

.cv-sheet.template-daniela-modern .dm-main {
  padding: 28px 24px;
}

.cv-sheet.template-daniela-modern .dm-name {
  font-size: 25px;
  font-weight: 800;
  color: var(--primary-color);
  margin: 0;
}

.cv-sheet.template-daniela-modern .dm-role {
  font-size: 13px;
  font-weight: 600;
  color: #475569;
  margin: 2px 0 16px 0;
}

.cv-sheet.template-daniela-modern .dm-section-title {
  font-size: 12.5px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  color: var(--primary-color);
  border-bottom: 1.5px solid var(--primary-light);
  padding-bottom: 3px;
  margin: 16px 0 10px 0;
}

/* ===================================================
   ELEMENTOS COMUNS (Experiências, Formações, Barras de Língua)
   =================================================== */

.exp-item, .edu-item {
  margin-bottom: 16px;
}

.item-header {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin-bottom: 3px;
}

.item-role {
  font-weight: 700;
  font-size: 12.5px;
  color: var(--text-main);
}

.item-period {
  font-size: 11px;
  font-weight: 600;
  color: var(--primary-color);
  white-space: nowrap;
  text-align: right;
  margin-left: 12px;
}

.item-company {
  font-size: 11.5px;
  font-weight: 500;
  color: var(--text-muted);
  margin-bottom: 5px;
}

.item-description {
  font-size: 11px;
  color: #334155;
  white-space: pre-line;
  line-height: 1.55;
}

/* Grid de Competências e Habilidades */
.skills-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.skill-tag {
  background: #f1f5f9;
  color: #1e293b;
  font-size: 11px;
  font-weight: 500;
  padding: 3px 8px;
  border-radius: 4px;
  border: 1px solid #e2e8f0;
}

/* Barras de Proficiência de Idiomas (Conforme Fotos 4 e 5) */
.lang-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.lang-item {
  font-size: 11px;
}

.lang-header {
  display: flex;
  justify-content: space-between;
  margin-bottom: 2px;
}

.lang-name {
  font-weight: 600;
}

.lang-level {
  color: var(--text-muted);
  font-size: 10.5px;
}

.lang-bar {
  width: 100%;
  height: 5px;
  background: #e2e8f0;
  border-radius: 3px;
  overflow: hidden;
}

.lang-progress {
  height: 100%;
  background: var(--primary-color);
  border-radius: 3px;
}

/* ===================================================
   NOVOS MODELOS (estrutura genérica .tpl)
   Todos usam o mesmo HTML (buildGenericTemplate); cada
   modelo é apenas uma "skin" CSS abaixo.
   =================================================== */
.cv-sheet.tpl {
  display: flex;
  flex-direction: column;
  padding: 0;
}

.cv-sheet.tpl > * { flex-shrink: 0; min-width: 0; }

.cv-sheet.tpl.layout-side-left {
  display: grid;
  grid-template-columns: 70mm minmax(0, 1fr);
}

.cv-sheet.tpl.layout-side-right {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 66mm;
}

.tpl.layout-side-right > .cv-side { order: 2; }

.tpl .cv-cols {
  flex: 1 0 auto;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
}

.tpl.layout-top-split .cv-cols { grid-template-columns: minmax(0, 1fr) 62mm; }
.tpl .cv-main, .tpl .cv-side { min-width: 0; }

/* Elementos comuns */
.tpl .cv-name { margin: 0; font-size: 28px; line-height: 1.1; font-weight: 800; color: var(--text-main); }
.tpl .cv-role { font-size: 14px; font-weight: 600; color: var(--primary-color); margin-top: 4px; }
.tpl .cv-section { margin-bottom: 20px; }
.tpl .cv-section-title {
  font-size: 12.5px; font-weight: 800; text-transform: uppercase; letter-spacing: 1px;
  color: var(--primary-color); margin: 0 0 11px 0;
}
.tpl .cv-summary { font-size: 11.5px; line-height: 1.58; color: #334155; white-space: pre-line; }
.tpl .cv-section-objective { margin-bottom: 20px; }
.tpl .cv-objective-text { font-size: 11.5px; line-height: 1.58; color: #334155; white-space: pre-line; }
.tpl .cv-head .cv-name + .cv-contacts,
.tpl .cv-head .cv-id:not(:has(.cv-role)) .cv-contacts { margin-top: 14px; }
.tpl .cv-id .cv-name:last-child { margin-bottom: 6px; }
.tpl .item-period { white-space: nowrap; margin-left: 10px; }

.tpl .cv-contacts { display: flex; flex-direction: column; gap: 7px; font-size: 11px; }
.tpl .cv-contact { display: flex; gap: 8px; align-items: flex-start; }
.tpl .cv-ico { flex: 0 0 16px; text-align: center; }

.tpl .cv-photo {
  width: 92px; height: 92px; border-radius: 50%; overflow: hidden; flex: 0 0 auto;
  background: var(--primary-tint); border: 3px solid #ffffff; box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.1);
  display: flex; align-items: center; justify-content: center;
}
.tpl .cv-photo img { width: 100%; height: 100%; object-fit: cover; display: block; }
.tpl .cv-monogram { font-size: 28px; font-weight: 800; color: var(--primary-color); }

/* Competências */
.tpl .cv-skills-inline { font-size: 11.5px; line-height: 1.75; color: #1e293b; }
.tpl .cv-dot { color: var(--primary-color); margin: 0 2px; }
.tpl .cv-skills-list { display: grid; grid-template-columns: 1fr 1fr; gap: 3px 18px; font-size: 11.5px; }
.tpl .cv-side .cv-skills-list { grid-template-columns: 1fr; }
.tpl .cv-skill-li { position: relative; padding-left: 12px; }
.tpl .cv-skill-li::before { content: '•'; position: absolute; left: 1px; color: var(--primary-color); font-weight: 700; }
.tpl .cv-skills-pills .skill-tag {
  background: var(--primary-color); color: var(--on-primary); border: none;
  border-radius: 12px; padding: 3px 10px; font-weight: 600;
}

/* Idiomas */
.tpl .lang-list-text { gap: 4px; }
.tpl .lang-text { font-size: 11.5px; }
.tpl .lang-dotrow { display: flex; gap: 4px; margin-top: 3px; }
.tpl .lang-dotrow i { display: block; width: 9px; height: 9px; border-radius: 50%; background: #dbe2ec; }
.tpl .lang-dotrow i.on { background: var(--primary-color); }

/* Regiões sobre cor de destaque (texto sempre branco, contraste >= 4.5:1) */
.tpl .on-accent { color: var(--on-primary); }
.tpl .on-accent .cv-section-title,
.tpl .on-accent .cv-name,
.tpl .on-accent .cv-role,
.tpl .on-accent .cv-monogram,
.tpl .on-accent .cv-dot { color: var(--on-primary); }
.tpl .on-accent .skill-tag { background: rgba(0, 0, 0, 0.22); color: var(--on-primary); border-color: rgba(255, 255, 255, 0.45); }
.tpl .on-accent .lang-level { color: var(--on-primary); }
.tpl .on-accent .lang-bar { background: rgba(0, 0, 0, 0.28); }
.tpl .on-accent .lang-progress { background: var(--on-primary); }
.tpl .on-accent .lang-dotrow i { background: rgba(0, 0, 0, 0.28); }
.tpl .on-accent .lang-dotrow i.on { background: var(--on-primary); }

/* ---------- 6. AURORA (Moderno / barra lateral colorida) ---------- */
.template-aurora .cv-side { background: var(--primary-color); color: var(--on-primary); padding: 34px 20px 30px; }
.template-aurora .cv-photo { width: 104px; height: 104px; margin: 0 auto 24px; border-color: rgba(255, 255, 255, 0.95); background: rgba(0, 0, 0, 0.2); }
.template-aurora .cv-side .cv-section { margin-bottom: 20px; }
.template-aurora .cv-side .cv-section-title { border-bottom: 1px solid rgba(255, 255, 255, 0.5); padding-bottom: 4px; font-size: 11.5px; }
.template-aurora .cv-main { padding: 40px 30px 30px 28px; }
.template-aurora .cv-head { margin-bottom: 22px; padding-bottom: 16px; border-bottom: 3px solid var(--primary-light); }
.template-aurora .cv-name { font-size: 32px; letter-spacing: -0.5px; color: var(--primary-color); }
.template-aurora .cv-role { color: #475569; text-transform: uppercase; letter-spacing: 2px; font-size: 12.5px; }
.template-aurora .cv-main .cv-section-title { border-left: 4px solid var(--primary-color); padding-left: 9px; }

/* ---------- 7. NORDIC (Moderno / minimalista em 2 colunas) ---------- */
.template-nordic .cv-head { display: flex; flex-wrap: wrap; align-items: center; padding: 38px 34px 20px; }
.template-nordic .cv-id { order: 1; flex: 1 1 calc(100% - 130px); min-width: 0; }
.template-nordic .cv-photo { order: 2; margin-left: 20px; border-radius: 14px; width: 98px; height: 98px; }
.template-nordic .cv-contacts {
  order: 3; flex: 0 0 100%; flex-direction: row; flex-wrap: wrap; gap: 6px 20px;
  margin-top: 16px; padding-top: 12px; border-top: 1px solid #e2e8f0;
}
.template-nordic .cv-name { font-size: 36px; font-weight: 300; letter-spacing: -1px; text-transform: uppercase; }
.template-nordic .cv-name::after { content: ''; display: block; width: 54px; height: 4px; background: var(--primary-color); margin-top: 10px; border-radius: 2px; }
.template-nordic .cv-role { color: #475569; font-weight: 500; letter-spacing: 1px; margin-top: 8px; }
.template-nordic .cv-main { padding: 8px 24px 30px 34px; }
.template-nordic .cv-side { background: #f8fafc; border-left: 1px solid #e2e8f0; padding: 8px 22px 30px 20px; }
.template-nordic .cv-section-title { border-bottom: 1px solid #e2e8f0; padding-bottom: 4px; }

/* ---------- 8. CLÁSSICO (Clássico / serifado centralizado) ---------- */
.template-classico { font-family: Georgia, "Times New Roman", serif; color: #111111; }
.template-classico .cv-head { text-align: center; margin: 0 46px; padding: 38px 0 14px; border-bottom: 3px double var(--primary-color); }
.template-classico .cv-photo { margin: 0 auto 12px; width: 84px; height: 84px; }
.template-classico .cv-name { font-size: 30px; font-weight: 700; letter-spacing: 3px; text-transform: uppercase; color: #111111; }
.template-classico .cv-role { font-size: 14px; font-style: italic; font-weight: 400; color: #333333; margin-top: 6px; }
.template-classico .cv-contacts { display: block; margin-top: 10px; font-size: 11px; color: #222222; line-height: 1.6; }
.template-classico .cv-contact { display: inline; }
.template-classico .cv-sep { color: var(--primary-color); font-weight: 700; margin: 0 2px; }
.template-classico .cv-main { padding: 20px 46px 30px; }
.template-classico .cv-section-title { font-size: 12.5px; letter-spacing: 2px; color: #111111; border-bottom: 1px solid var(--primary-color); padding-bottom: 3px; }
.template-classico .item-role { font-weight: 700; }
.template-classico .item-period { font-style: italic; color: #333333; font-weight: 500; }
.template-classico .cv-summary { text-align: justify; }

/* ---------- 9. OXFORD (Clássico / acadêmico com lateral) ---------- */
.template-oxford { font-family: Georgia, "Times New Roman", serif; }
.template-oxford .cv-main { padding: 40px 28px 30px 38px; }
.template-oxford .cv-head { border-bottom: 2px solid var(--primary-color); padding-bottom: 14px; margin-bottom: 20px; }
.template-oxford .cv-name { font-size: 30px; font-weight: 700; letter-spacing: 0.5px; color: #111111; }
.template-oxford .cv-role { font-style: italic; font-weight: 400; font-size: 14px; }
.template-oxford .cv-section-title { font-size: 13px; letter-spacing: 1.5px; color: #111111; border-bottom: 1px solid #cbd5e1; padding-bottom: 3px; }
.template-oxford .cv-side { background: var(--primary-tint); border-left: 1px solid var(--primary-light); padding: 40px 20px 30px; }
.template-oxford .cv-side .cv-section-title { color: var(--primary-color); border-bottom-color: var(--primary-color); font-size: 11.5px; }
.template-oxford .cv-photo { border-radius: 4px; width: 100px; height: 124px; margin: 0 auto 22px; }
.template-oxford .cv-contacts-labels .cv-contact { display: block; }
.template-oxford .cv-contacts-labels strong { display: block; font-size: 9.5px; text-transform: uppercase; letter-spacing: 0.8px; color: #475569; }
.template-oxford .cv-contacts { gap: 8px; }

/* ---------- 10. EXECUTIVO PRIME (Executivo / cabeçalho em faixa) ---------- */
.template-executivo-prime .cv-head {
  background: var(--primary-color); color: var(--on-primary);
  display: flex; flex-wrap: wrap; align-items: center; padding: 36px 34px 22px;
}
.template-executivo-prime .cv-id { order: 1; flex: 1 1 calc(100% - 130px); min-width: 0; }
.template-executivo-prime .cv-photo { order: 2; margin-left: 20px; border-radius: 6px; width: 96px; height: 114px; border-color: rgba(255, 255, 255, 0.9); background: rgba(0, 0, 0, 0.2); }
.template-executivo-prime .cv-name { font-family: Georgia, "Times New Roman", serif; font-size: 34px; font-weight: 700; letter-spacing: 0.5px; }
.template-executivo-prime .cv-role { letter-spacing: 3px; text-transform: uppercase; font-size: 12px; font-weight: 500; margin-top: 8px; }
.template-executivo-prime .cv-contacts {
  order: 3; flex: 0 0 100%; flex-direction: row; flex-wrap: wrap; gap: 6px 20px;
  margin-top: 18px; padding-top: 12px; border-top: 1px solid rgba(255, 255, 255, 0.45);
}
.template-executivo-prime .cv-main { padding: 24px 24px 30px 34px; }
.template-executivo-prime .cv-side { background: var(--primary-tint); border-left: 1px solid var(--primary-light); padding: 24px 20px 30px; }
.template-executivo-prime .cv-section-title { font-family: Georgia, "Times New Roman", serif; border-bottom: 2px solid var(--primary-color); padding-bottom: 3px; }

/* ---------- 11. DIRETOR (Executivo / sóbrio com filete lateral) ---------- */
.template-diretor .cv-head {
  display: flex; flex-wrap: wrap; align-items: center;
  margin: 38px 40px 0; padding: 4px 0 4px 20px; border-left: 6px solid var(--primary-color);
}
.template-diretor .cv-id { order: 1; flex: 1 1 calc(100% - 130px); min-width: 0; }
.template-diretor .cv-photo { order: 2; margin-left: 20px; width: 88px; height: 88px; }
.template-diretor .cv-name { font-family: Georgia, "Times New Roman", serif; font-size: 32px; font-weight: 700; color: #0f172a; }
.template-diretor .cv-role { color: #475569; font-size: 13px; font-weight: 500; letter-spacing: 1.5px; text-transform: uppercase; }
.template-diretor .cv-contacts {
  order: 3; flex: 0 0 100%; display: grid; grid-template-columns: 1fr 1fr; gap: 3px 20px; margin-top: 12px;
}
.template-diretor .cv-contact { display: block; }
.template-diretor .cv-main { padding: 26px 40px 30px; }
.template-diretor .cv-section-title { font-family: Georgia, "Times New Roman", serif; font-size: 14px; letter-spacing: 1.5px; border-bottom: 1px solid #cbd5e1; padding-bottom: 4px; }

/* ---------- 12. VIBRANT (Criativo / faixa colorida e painel arredondado) ---------- */
.template-vibrant .cv-head {
  position: relative; overflow: hidden; background: var(--primary-color); color: var(--on-primary);
  display: flex; flex-wrap: wrap; align-items: center; padding: 34px 34px 26px;
}
.template-vibrant .cv-head::before {
  content: ''; position: absolute; right: -60px; top: -90px; width: 270px; height: 270px; border-radius: 50%; background: rgba(255, 255, 255, 0.14);
}
.template-vibrant .cv-head::after {
  content: ''; position: absolute; left: 38%; bottom: -130px; width: 250px; height: 250px; border-radius: 50%; background: rgba(0, 0, 0, 0.12);
}
.template-vibrant .cv-head > * { position: relative; z-index: 1; }
.template-vibrant .cv-photo { order: 1; margin-right: 22px; width: 104px; height: 104px; border: 5px solid #ffffff; background: rgba(0, 0, 0, 0.2); }
.template-vibrant .cv-id { order: 2; flex: 1 1 calc(100% - 150px); min-width: 0; }
.template-vibrant .cv-name { font-size: 36px; font-weight: 900; letter-spacing: -1px; }
.template-vibrant .cv-role { text-transform: uppercase; letter-spacing: 3px; font-size: 12.5px; margin-top: 8px; }
.template-vibrant .cv-contacts { order: 3; flex: 0 0 100%; flex-direction: row; flex-wrap: wrap; gap: 6px 8px; margin-top: 18px; }
.template-vibrant .cv-contact { background: rgba(0, 0, 0, 0.22); padding: 3px 11px; border-radius: 14px; align-items: center; }
.template-vibrant .cv-main { padding: 26px 22px 30px 34px; }
.template-vibrant .cv-side { background: var(--primary-tint); border-radius: 16px; margin: 22px 24px 24px 4px; padding: 18px 16px; }
.template-vibrant .cv-section-title { display: inline-block; font-size: 13.5px; border-bottom: 3px solid var(--primary-color); padding-bottom: 2px; margin-bottom: 11px; }

/* ---------- 13. MOSAICO (Criativo / cartões e etiquetas) ---------- */
.template-mosaico .cv-main { padding: 38px 26px 30px 34px; }
.template-mosaico .cv-head { margin-bottom: 22px; }
.template-mosaico .cv-name { font-size: 34px; font-weight: 900; line-height: 1.05; letter-spacing: -0.5px; color: var(--primary-color); }
.template-mosaico .cv-role { color: #334155; }
.template-mosaico .cv-main .cv-section-title {
  display: inline-block; background: var(--primary-color); color: var(--on-primary);
  padding: 3px 13px; border-radius: 14px; font-size: 11px; margin-bottom: 11px;
}
.template-mosaico .cv-side { background: var(--primary-tint); border-left: 5px solid var(--primary-color); padding: 30px 16px 30px 14px; }
.template-mosaico .cv-side .cv-section { background: #ffffff; border: 1px solid var(--primary-light); border-radius: 10px; padding: 12px; margin-bottom: 12px; }
.template-mosaico .cv-side .cv-section-title { border-bottom: 1px solid var(--primary-light); padding-bottom: 3px; font-size: 11px; }
.template-mosaico .cv-photo { border-radius: 16px; width: 112px; height: 112px; margin: 0 auto 16px; }

/* ---------- 14. ATS CLEAN (ATS / texto puro em 1 coluna) ---------- */
.template-ats-clean { font-family: Arial, Helvetica, sans-serif; color: #000000; }
.template-ats-clean .cv-head { padding: 38px 42px 6px; }
.template-ats-clean .cv-name { font-size: 26px; font-weight: 700; color: #000000; }
.template-ats-clean .cv-role { color: #000000; font-size: 14px; font-weight: 400; }
.template-ats-clean .cv-contacts { display: block; margin-top: 8px; line-height: 1.6; color: #000000; }
.template-ats-clean .cv-contact { display: inline; }
.template-ats-clean .cv-main { padding: 12px 42px 30px; }
.template-ats-clean .cv-section-title { color: #000000; font-size: 12px; letter-spacing: 0.6px; border-bottom: 1px solid var(--primary-color); padding-bottom: 2px; }
.template-ats-clean .item-role, .template-ats-clean .item-period { color: #000000; }
.template-ats-clean .item-company, .template-ats-clean .item-description, .template-ats-clean .cv-summary { color: #222222; }
.template-ats-clean .cv-dot { color: #000000; }

/* ---------- 15. ATS PRO (ATS / títulos fortes em 1 coluna) ---------- */
.template-ats-pro { font-family: Arial, Helvetica, sans-serif; }
.template-ats-pro .cv-head { padding: 36px 42px 16px; border-bottom: 4px solid var(--primary-color); }
.template-ats-pro .cv-name { font-size: 28px; font-weight: 800; color: var(--primary-color); }
.template-ats-pro .cv-role { color: #1e293b; font-size: 14px; }
.template-ats-pro .cv-contacts { flex-direction: row; flex-wrap: wrap; gap: 3px 18px; margin-top: 10px; }
.template-ats-pro .cv-contact { display: block; }
.template-ats-pro .cv-main { padding: 20px 42px 30px; }
.template-ats-pro .cv-section-title { font-size: 13px; border-bottom: 2px solid var(--primary-color); padding-bottom: 3px; }

/* ===================================================
   ESTILOS COMPARTILHADOS - CONTATOS SEM ÍCONES
   =================================================== */
.cv-contacts-no-icons {
  font-size: 11px;
  line-height: 1.5;
  color: #334155;
}

.cv-contacts-no-icons strong,
.cv-contacts-no-icons .cv-contact-lbl {
  font-weight: 600;
  color: #1e293b;
}

.cv-contacts-no-icons .cv-contact-val {
  color: #334155;
}

.cv-contacts-compact {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px 10px;
}

.cv-contacts-compact .cv-contact-item,
.cv-contacts-bullets .cv-contact-item {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.cv-contacts-compact .cv-contact-sep,
.cv-contacts-bullets .cv-contact-sep {
  color: var(--primary-color);
  font-weight: 700;
  opacity: 0.75;
  user-select: none;
}

.cv-contacts-bullets {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px 12px;
}

.cv-contacts-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 4px 16px;
}

.cv-contacts-grid .cv-contact-grid-item {
  display: flex;
  gap: 5px;
  font-size: 10.5px;
  line-height: 1.4;
  word-break: break-word;
}

.cv-contacts-grid .cv-contact-lbl {
  white-space: nowrap;
}

.cv-contacts-list {
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.cv-contacts-list .cv-contact-row {
  display: flex;
  gap: 6px;
  font-size: 11px;
  line-height: 1.45;
}

/* ===================================================
   16. EXECUTIVO CLÁSSICO
   Visual corporativo tradicional, serifado elegante, divisórias discretas
   =================================================== */
.cv-sheet.template-executivo-classico {
  font-family: Georgia, "Times New Roman", Garamond, serif;
  color: #1a202c;
  background: #ffffff;
}

.template-executivo-classico .eclass-head {
  padding: 38px 46px 14px;
  text-align: center;
}

.template-executivo-classico .eclass-photo-wrapper {
  margin-bottom: 12px;
}

.template-executivo-classico .eclass-photo {
  width: 90px;
  height: 90px;
  margin: 0 auto;
  border-radius: 50%;
  overflow: hidden;
  border: 2px solid var(--primary-color);
  box-shadow: 0 2px 6px rgba(0,0,0,0.08);
}

.template-executivo-classico .eclass-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.template-executivo-classico .eclass-name {
  margin: 0 0 4px 0;
  font-size: 28px;
  font-weight: 700;
  letter-spacing: 1.2px;
  text-transform: uppercase;
  color: #0f172a;
  line-height: 1.15;
}

.template-executivo-classico .eclass-role {
  font-size: 13.5px;
  font-style: italic;
  font-weight: 500;
  color: var(--primary-color);
  margin-bottom: 12px;
  letter-spacing: 0.5px;
}

.template-executivo-classico .cv-contacts-compact {
  justify-content: center;
  font-size: 11px;
  line-height: 1.6;
}

.template-executivo-classico .eclass-divider {
  border: 0;
  height: 1px;
  background: #cbd5e1;
  position: relative;
  margin: 16px auto 0 auto;
  width: 100%;
}

.template-executivo-classico .eclass-divider::after {
  content: '';
  position: absolute;
  left: 50%;
  top: -1px;
  transform: translateX(-50%);
  width: 80px;
  height: 3px;
  background: var(--primary-color);
}

.template-executivo-classico .eclass-main {
  padding: 16px 46px 32px;
}

.template-executivo-classico .cv-section {
  margin-bottom: 18px;
}

.template-executivo-classico .cv-section-title {
  font-size: 12.5px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.8px;
  color: #0f172a;
  border-bottom: 1px solid #cbd5e1;
  padding-bottom: 4px;
  margin-bottom: 10px;
}

.template-executivo-classico .item-role {
  font-family: Georgia, "Times New Roman", serif;
  font-weight: 700;
  color: #0f172a;
  font-size: 12.5px;
}

.template-executivo-classico .item-company {
  color: #334155;
  font-size: 11.5px;
  margin-bottom: 4px;
}

.template-executivo-classico .item-period {
  font-style: italic;
  color: #475569;
  font-size: 11px;
  white-space: nowrap;
}

.template-executivo-classico .cv-summary,
.template-executivo-classico .item-description {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  font-size: 11px;
  line-height: 1.5;
  color: #334155;
}

.template-executivo-classico .cv-skills-inline {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  font-size: 11.5px;
  line-height: 1.7;
  color: #1e293b;
}

.template-executivo-classico .cv-dot {
  color: var(--primary-color);
  font-weight: 700;
  margin: 0 4px;
}

/* ===================================================
   17. MINIMALISTA PROFISSIONAL
   Design limpo, bastante espaço em branco, sem elementos decorativos desnecessários
   =================================================== */
.cv-sheet.template-minimalista-pro {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  color: #1e293b;
  background: #ffffff;
}

.template-minimalista-pro .mpro-head {
  padding: 42px 42px 14px;
}

.template-minimalista-pro .mpro-top-row {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 20px;
}

.template-minimalista-pro .mpro-titles {
  flex: 1;
}

.template-minimalista-pro .mpro-photo-container {
  flex-shrink: 0;
}

.template-minimalista-pro .mpro-photo {
  width: 84px;
  height: 84px;
  border-radius: 6px;
  overflow: hidden;
  border: 1px solid #e2e8f0;
}

.template-minimalista-pro .mpro-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.template-minimalista-pro .mpro-name {
  margin: 0 0 6px 0;
  font-size: 32px;
  font-weight: 600;
  letter-spacing: -0.5px;
  color: #0f172a;
  line-height: 1.1;
}

.template-minimalista-pro .mpro-role {
  font-size: 12.5px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: var(--primary-color);
  margin-bottom: 12px;
}

.template-minimalista-pro .mpro-contacts-wrapper {
  margin-top: 10px;
}

.template-minimalista-pro .mpro-divider {
  height: 1px;
  background: #f1f5f9;
  border-top: 1px solid #e2e8f0;
  margin-top: 14px;
}

.template-minimalista-pro .mpro-main {
  padding: 16px 42px 34px;
}

.template-minimalista-pro .cv-section {
  margin-bottom: 22px;
}

.template-minimalista-pro .cv-section-title {
  font-size: 11.5px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: #0f172a;
  margin-bottom: 10px;
  display: flex;
  align-items: center;
  gap: 12px;
}

.template-minimalista-pro .cv-section-title::after {
  content: '';
  flex: 1;
  height: 1px;
  background: #f1f5f9;
}

.template-minimalista-pro .item-header {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin-bottom: 2px;
}

.template-minimalista-pro .item-role {
  font-weight: 600;
  font-size: 12px;
  color: #0f172a;
}

.template-minimalista-pro .item-period {
  font-size: 11px;
  color: #64748b;
  font-weight: 400;
}

.template-minimalista-pro .item-company {
  font-size: 11.5px;
  color: #475569;
  margin-bottom: 4px;
}

.template-minimalista-pro .cv-summary,
.template-minimalista-pro .item-description {
  font-size: 11px;
  line-height: 1.55;
  color: #334155;
}

.template-minimalista-pro .mpro-skills-grid .skill-tag {
  background: #ffffff;
  color: #334155;
  border: 1px solid #e2e8f0;
  border-radius: 4px;
  font-size: 10.5px;
  padding: 3px 9px;
  font-weight: 500;
}

/* ===================================================
   18. CORPORATIVO MODERNO
   Cabeçalho bem estruturado, títulos destacados e cores discretas
   =================================================== */
.cv-sheet.template-corporativo-moderno {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  color: #1e293b;
  background: #ffffff;
}

.template-corporativo-moderno .cmod-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 280px;
  gap: 16px;
  padding: 24px 36px 14px;
  background: #ffffff;
  border-bottom: 2px solid var(--primary-light);
  align-items: center;
}

.template-corporativo-moderno .cmod-identity {
  display: flex;
  align-items: center;
  gap: 16px;
}

.template-corporativo-moderno .cmod-photo-container {
  flex-shrink: 0;
}

.template-corporativo-moderno .cmod-photo {
  width: 90px;
  height: 90px;
  border-radius: 8px;
  overflow: hidden;
  border: 2px solid var(--primary-color);
  box-shadow: 0 2px 8px rgba(0,0,0,0.06);
}

.template-corporativo-moderno .cmod-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.template-corporativo-moderno .cmod-name {
  margin: 0 0 4px 0;
  font-size: 26px;
  font-weight: 800;
  color: #0f172a;
  letter-spacing: -0.3px;
  line-height: 1.15;
}

.template-corporativo-moderno .cmod-role {
  font-size: 13px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: var(--primary-color);
}

.template-corporativo-moderno .cmod-card {
  background: var(--primary-tint);
  border: 1px solid var(--primary-light);
  border-radius: 8px;
  padding: 10px 14px;
}

.template-corporativo-moderno .cmod-card-label {
  font-size: 9.5px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--primary-color);
  margin-bottom: 6px;
  border-bottom: 1px solid var(--primary-light);
  padding-bottom: 3px;
}

.template-corporativo-moderno .cmod-main {
  padding: 16px 36px 24px;
}

.template-corporativo-moderno .cv-section {
  margin-bottom: 14px;
}

.template-corporativo-moderno .cv-section-title {
  font-size: 12.5px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--primary-color);
  border-left: 4px solid var(--primary-color);
  padding: 3px 10px;
  background: linear-gradient(90deg, var(--primary-tint) 0%, transparent 100%);
  border-radius: 0 4px 4px 0;
  margin-bottom: 11px;
}

.template-corporativo-moderno .item-header {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin-bottom: 2px;
}

.template-corporativo-moderno .item-role {
  font-weight: 700;
  font-size: 12px;
  color: #0f172a;
}

.template-corporativo-moderno .item-period {
  font-size: 10.5px;
  color: #475569;
  background: #f1f5f9;
  padding: 2px 7px;
  border-radius: 4px;
  font-weight: 500;
  white-space: nowrap;
}

.template-corporativo-moderno .item-company {
  font-size: 11.5px;
  font-weight: 500;
  color: var(--primary-color);
  margin-bottom: 4px;
}

.template-corporativo-moderno .cv-summary,
.template-corporativo-moderno .item-description {
  font-size: 11px;
  line-height: 1.5;
  color: #334155;
}

/* ===================================================
   19. ELEGANTE PREMIUM
   Aparência sofisticada, hierarquia tipográfica refinada e excelente legibilidade
   =================================================== */
.cv-sheet.template-elegante-premium {
  font-family: "Garamond", "Palatino Linotype", Georgia, serif;
  color: #1a202c;
  background: #ffffff;
}

.template-elegante-premium .eprem-head {
  padding: 34px 44px 16px;
  text-align: center;
  position: relative;
}

.template-elegante-premium .eprem-top-accent {
  width: 100%;
  height: 3px;
  background: var(--primary-color);
  margin-bottom: 18px;
}

.template-elegante-premium .eprem-photo-box {
  margin-bottom: 12px;
}

.template-elegante-premium .eprem-photo {
  width: 90px;
  height: 90px;
  margin: 0 auto;
  border-radius: 50%;
  overflow: hidden;
  border: 1px solid #cbd5e1;
  padding: 3px;
  background: #ffffff;
}

.template-elegante-premium .eprem-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 50%;
  display: block;
}

.template-elegante-premium .eprem-name {
  margin: 0 0 4px 0;
  font-size: 30px;
  font-weight: 600;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: #0f172a;
  line-height: 1.15;
}

.template-elegante-premium .eprem-role {
  font-size: 13px;
  font-style: italic;
  font-weight: 400;
  letter-spacing: 1px;
  color: var(--primary-color);
  margin-bottom: 10px;
}

.template-elegante-premium .eprem-contacts-line {
  display: flex;
  justify-content: center;
  margin-top: 6px;
}

.template-elegante-premium .eprem-contacts-line .cv-contacts-bullets {
  justify-content: center;
  font-size: 11px;
  line-height: 1.5;
}

.template-elegante-premium .eprem-ornament-line {
  position: relative;
  height: 1px;
  background: #e2e8f0;
  margin: 14px auto 0 auto;
  width: 80%;
}

.template-elegante-premium .eprem-ornament-mark {
  position: absolute;
  left: 50%;
  top: -3px;
  transform: translateX(-50%);
  width: 7px;
  height: 7px;
  background: var(--primary-color);
  transform: translateX(-50%) rotate(45deg);
}

.template-elegante-premium .eprem-main {
  padding: 18px 44px 32px;
}

.template-elegante-premium .cv-section {
  margin-bottom: 20px;
}

.template-elegante-premium .cv-section-title {
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 2.2px;
  color: #0f172a;
  border-bottom: 1px solid var(--primary-color);
  padding-bottom: 3px;
  margin-bottom: 10px;
}

.template-elegante-premium .item-role {
  font-weight: 700;
  font-size: 12.5px;
  color: #0f172a;
}

.template-elegante-premium .item-period {
  font-style: italic;
  font-size: 11px;
  color: #475569;
  white-space: nowrap;
}

.template-elegante-premium .item-company {
  font-size: 11.5px;
  color: #334155;
  margin-bottom: 4px;
}

.template-elegante-premium .cv-summary,
.template-elegante-premium .item-description {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  font-size: 11px;
  line-height: 1.55;
  color: #334155;
}

.template-elegante-premium .cv-skills-inline {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  font-size: 11.5px;
  line-height: 1.7;
  color: #1e293b;
}

/* ===================================================
   20. PROFISSIONAL ATS
   Estrutura simples, 100% coluna única, sem tabelas complexas, otimizado para sistemas ATS
   =================================================== */
.cv-sheet.template-profissional-ats {
  font-family: Arial, Helvetica, sans-serif;
  color: #111827;
  background: #ffffff;
}

.template-profissional-ats .pats-head {
  padding: 38px 42px 14px;
}

.template-profissional-ats .pats-name {
  margin: 0 0 4px 0;
  font-size: 26px;
  font-weight: 700;
  color: #111827;
  line-height: 1.15;
}

.template-profissional-ats .pats-role {
  font-size: 14px;
  font-weight: 600;
  color: var(--primary-color);
  margin-bottom: 10px;
}

.template-profissional-ats .pats-contacts-wrapper {
  margin-bottom: 12px;
}

.template-profissional-ats .cv-contacts-compact {
  font-size: 11px;
  line-height: 1.6;
  color: #111827;
}

.template-profissional-ats .cv-contacts-compact strong {
  color: #111827;
}

.template-profissional-ats .pats-divider {
  height: 2px;
  background: var(--primary-color);
  margin-top: 6px;
}

.template-profissional-ats .pats-main {
  padding: 14px 42px 30px;
}

.template-profissional-ats .cv-section {
  margin-bottom: 18px;
}

.template-profissional-ats .cv-section-title {
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  color: #111827;
  border-bottom: 1px solid #111827;
  padding-bottom: 3px;
  margin-bottom: 9px;
}

.template-profissional-ats .item-header {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin-bottom: 2px;
}

.template-profissional-ats .item-role {
  font-weight: 700;
  font-size: 12px;
  color: #111827;
}

.template-profissional-ats .item-period {
  font-size: 11px;
  font-weight: 600;
  color: #374151;
  white-space: nowrap;
}

.template-profissional-ats .item-company {
  font-size: 11.5px;
  color: #374151;
  margin-bottom: 3px;
}

.template-profissional-ats .cv-summary,
.template-profissional-ats .item-description {
  font-size: 11px;
  line-height: 1.5;
  color: #1f2937;
}

.template-profissional-ats .cv-skills-inline {
  font-size: 11.5px;
  line-height: 1.7;
  color: #111827;
}

/* ===================================================
   21. EXECUTIVO CONTEMPORÂNEO
   Design atual, formal e equilibrado, adequado para profissionais de diferentes áreas
   =================================================== */
.cv-sheet.template-executivo-contemporaneo {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  color: #1e293b;
  background: #ffffff;
}

.template-executivo-contemporaneo .econt-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 290px;
  gap: 20px;
  padding: 34px 40px 18px;
  border-bottom: 1px solid #e2e8f0;
  align-items: center;
  position: relative;
}

.template-executivo-contemporaneo .econt-head::before {
  content: '';
  position: absolute;
  left: 0;
  top: 34px;
  bottom: 18px;
  width: 5px;
  background: var(--primary-color);
  border-radius: 0 3px 3px 0;
}

.template-executivo-contemporaneo .econt-identity {
  display: flex;
  align-items: center;
  gap: 16px;
}

.template-executivo-contemporaneo .econt-photo-container {
  flex-shrink: 0;
}

.template-executivo-contemporaneo .econt-photo {
  width: 88px;
  height: 88px;
  border-radius: 8px;
  overflow: hidden;
  border: 1px solid #cbd5e1;
  box-shadow: 0 2px 6px rgba(0,0,0,0.06);
}

.template-executivo-contemporaneo .econt-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.template-executivo-contemporaneo .econt-name {
  margin: 0 0 4px 0;
  font-size: 28px;
  font-weight: 800;
  color: #0f172a;
  letter-spacing: -0.5px;
  line-height: 1.15;
}

.template-executivo-contemporaneo .econt-role {
  font-size: 13px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: var(--primary-color);
}

.template-executivo-contemporaneo .econt-contacts-panel {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 6px;
  padding: 10px 14px;
}

.template-executivo-contemporaneo .econt-main {
  padding: 22px 40px 30px;
}

.template-executivo-contemporaneo .cv-section {
  margin-bottom: 19px;
}

.template-executivo-contemporaneo .cv-section-title {
  font-size: 12.5px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: #0f172a;
  display: flex;
  align-items: center;
  gap: 8px;
  border-bottom: 1px solid #e2e8f0;
  padding-bottom: 4px;
  margin-bottom: 11px;
}

.template-executivo-contemporaneo .econt-title-bullet {
  display: inline-block;
  width: 5px;
  height: 13px;
  background: var(--primary-color);
  border-radius: 1px;
}

.template-executivo-contemporaneo .item-header {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin-bottom: 2px;
}

.template-executivo-contemporaneo .item-role {
  font-weight: 700;
  font-size: 12px;
  color: #0f172a;
}

.template-executivo-contemporaneo .item-period {
  font-size: 10.5px;
  color: #64748b;
  font-weight: 500;
  white-space: nowrap;
}

.template-executivo-contemporaneo .item-company {
  font-size: 11.5px;
  color: var(--primary-color);
  font-weight: 500;
  margin-bottom: 4px;
}

.template-executivo-contemporaneo .cv-summary,
.template-executivo-contemporaneo .item-description {
  font-size: 11px;
  line-height: 1.5;
  color: #334155;
}

/* ===================================================
   MINIATURAS DA GALERIA (pré-visualização em tempo real)
   =================================================== */
.tpl-thumb {
  width: 100px;
  height: 141px;
  overflow: hidden;
  position: relative;
  margin: 0 auto 6px auto;
  border: 1px solid #cbd5e1;
  border-radius: 4px;
  background: #ffffff;
}

.cv-sheet.cv-thumb {
  position: absolute;
  left: 0;
  top: 0;
  margin: 0;
  width: 794px;
  transform: scale(0.126);
  transform-origin: top left;
  pointer-events: none;
  box-shadow: none;
}

/* ===================================================
   IMPRESSÃO PERFEITA (PDF A4 LIMPO SEM MARGENS OU CABEÇALHOS)
   Fallback do navegador: suporta N páginas A4 sem página em branco.
   =================================================== */

/* ===================================================
   ESPAÇAMENTOS REFINADOS - CABEÇALHOS SEM CARGO
   Garante distância proporcional e elegante entre nome e contatos
   =================================================== */
.template-sao-francisco .sf-name + .sf-summary-box,
.template-sao-francisco .sf-name + .sf-objective-box {
  margin-top: 14px;
}

.template-european .eu-header:not(:has(.eu-title)) .eu-name,
.template-european .eu-header .eu-name:last-child {
  margin-bottom: 4px;
}

.template-daniela-modern .dm-name + .dm-objective-box,
.template-daniela-modern .dm-name + .cv-section,
.template-daniela-modern .dm-name + div {
  margin-top: 14px;
}

.template-executivo-classico .eclass-name + .cv-contacts-no-icons {
  margin-top: 12px;
}

.template-minimalista-pro .mpro-top-row + .mpro-contacts-wrapper {
  margin-top: 12px;
}

.template-elegante-premium .eprem-name + .eprem-contacts-line {
  margin-top: 12px;
}

.template-profissional-ats .pats-name + .pats-contacts-wrapper {
  margin-top: 12px;
}

/* ===================================================
   DISTRIBUIÇÃO EQUILIBRADA NO A4 (Currículos concisos de 1 página)
   Evita concentração excessiva no topo sem esticar artificialmente
   =================================================== */
.cv-sheet.cv-balanced-a4 .cv-main {
  padding-top: 34px;
  padding-bottom: 38px;
}

.cv-sheet.cv-balanced-a4 .cv-side {
  padding-top: 34px;
  padding-bottom: 38px;
}

.cv-sheet.cv-balanced-a4 .cv-section,
.cv-sheet.cv-balanced-a4 .ats-section {
  margin-bottom: 24px;
}

.cv-sheet.cv-balanced-a4 .cv-section-title,
.cv-sheet.cv-balanced-a4 .ats-section-title,
.cv-sheet.cv-balanced-a4 .section-title,
.cv-sheet.cv-balanced-a4 .dm-section-title {
  margin-bottom: 13px;
}

.cv-sheet.cv-balanced-a4 .exp-item,
.cv-sheet.cv-balanced-a4 .edu-item {
  margin-bottom: 18px;
}

.cv-sheet.cv-balanced-a4 .cv-summary,
.cv-sheet.cv-balanced-a4 .cv-objective-text,
.cv-sheet.cv-balanced-a4 .item-description {
  line-height: 1.62;
}

.cv-sheet.cv-balanced-a4.template-tampa-ats .ats-header-block {
  padding: 30px 32px;
}

.cv-sheet.cv-balanced-a4.template-tampa-ats .ats-body {
  padding: 28px 32px;
}

.cv-sheet.cv-balanced-a4.template-sao-francisco .sf-main {
  padding: 36px 28px;
}

.cv-sheet.cv-balanced-a4.template-sao-francisco .sf-contact-list {
  padding: 28px 20px;
  gap: 16px;
}

.cv-sheet.cv-balanced-a4.template-european .eu-main {
  padding: 36px 30px;
}

.cv-sheet.cv-balanced-a4.template-european .eu-sidebar {
  padding: 50px 20px 30px;
}

.cv-sheet.cv-balanced-a4.template-daniela-modern .dm-main {
  padding: 34px 28px;
}

.cv-sheet.cv-balanced-a4.template-daniela-modern .dm-sidebar {
  padding: 34px 20px;
}

.cv-sheet.cv-balanced-a4.template-executivo-classico .eclass-main {
  padding: 22px 46px 36px;
}

.cv-sheet.cv-balanced-a4.template-minimalista-pro .mpro-main {
  padding: 24px 42px 38px;
}

.cv-sheet.cv-balanced-a4.template-corporativo-moderno .cmod-main {
  padding: 22px 36px 32px;
}

.cv-sheet.cv-balanced-a4.template-elegante-premium .eprem-main {
  padding: 22px 44px 36px;
}

.cv-sheet.cv-balanced-a4.template-profissional-ats .pats-main {
  padding: 20px 42px 34px;
}

.cv-sheet.cv-balanced-a4.template-executivo-contemporaneo .econt-main {
  padding: 26px 40px 34px;
}

@media print {
  @page {
    size: A4 portrait;
    margin: 0;
  }

  :root {
    --page-h: 296.5mm;
  }

  *, *:before, *:after {
    -webkit-print-color-adjust: exact !important;
    print-color-adjust: exact !important;
    color-adjust: exact !important;
  }

  html, body {
    margin: 0 !important;
    padding: 0 !important;
    background: #ffffff !important;
    width: 210mm !important;
    height: auto !important;
    overflow: visible !important;
  }

  /* Oculta tudo que é interface web, botões, modais e anúncios */
  header, nav, footer, .sidebar-editor, .editor-sidebar, .ads-banner-area, .app-header, .app-footer,
  .install-banner, .btn-action, .modal-backdrop, .toast-box,
  .preview-toolbar, .no-print, .mobile-view-tabs {
    display: none !important;
    visibility: hidden !important;
    height: 0 !important;
    margin: 0 !important;
    padding: 0 !important;
  }

  /* FORÇA a exibição do container e da folha do currículo, mesmo em mobile */
  .app-container, main {
    display: block !important;
    padding: 0 !important;
    margin: 0 !important;
    width: 210mm !important;
    max-width: 210mm !important;
    overflow: visible !important;
  }

  .preview-panel, .preview-scale-wrapper, .preview-stage {
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
    padding: 0 !important;
    margin: 0 !important;
    width: 210mm !important;
    height: auto !important;
    overflow: visible !important;
    position: static !important;
    left: auto !important;
    transform: none !important;
  }

  .cv-sheet {
    visibility: visible !important;
    opacity: 1 !important;
    box-shadow: none !important;
    border: none !important;
    width: 210mm !important;
    height: calc(var(--page-h) * var(--pages, 1)) !important;
    max-height: none !important;
    margin: 0 !important;
    overflow: hidden !important;
    transform: none !important;
    position: relative !important;
    -webkit-print-color-adjust: exact !important;
    print-color-adjust: exact !important;
  }

  .cv-sheet::after { display: none !important; }
}
