/* ══════════════════════════════════════════════════════
   executivo.css
   · Fora do #cv  → visual temtudinho (dark, DM Mono, accent azul)
   · Dentro do #cv → design original do modelo (navy, gold, cream)
══════════════════════════════════════════════════════════ */

/* ─── VARIÁVEIS DO MODELO (usadas só dentro do #cv) ─── */
:root {
  /* Site temtudinho */
  --tt-ink: #0d0f14;
  --tt-paper: #f0f3f8;
  --tt-accent: #2a6dd9;
  --tt-border: rgba(240, 243, 248, 0.1);
  --tt-muted: #707a8a;
  --tt-card-bg: rgba(240, 243, 248, 0.04);

  /* Modelo executivo (só usadas dentro de #cv) */
  --navy: #1a2744;
  --gold: #b8933f;
  --gold-light: #d4aa5a;
  --cream: #faf8f4;
  --gray-light: #f0ede8;
  --gray-mid: #c8c4bc;
  --text: #2c2c2c;
  --muted: #6b6560;
  --ink: #0f0e0d;
  --paper: #f5f2ee;
  --accent: #c8472b;
  --border: rgba(15, 14, 13, 0.12);
}

*,
*::before,
*::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

/* ─── BODY — fundo do site ──────────────────────────── */
body {
  font-family: "DM Sans", sans-serif;
  background: var(--tt-ink);
  background-image:
    linear-gradient(rgba(240, 243, 248, 0.025) 1px, transparent 1px),
    linear-gradient(90deg, rgba(240, 243, 248, 0.025) 1px, transparent 1px);
  background-size: 60px 60px;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 80px 20px 80px;
  min-height: 100vh;
}

/* ─── BACK NAVBAR ───────────────────────────────────── */
.back-nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 200;
  height: 56px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 2rem;
  background: rgba(13, 15, 20, 0.9);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--tt-border);
}

.back-nav-left {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.back-nav-logo {
  font-family: "Playfair Display", serif;
  font-weight: 900;
  font-size: 1.1rem;
  color: rgba(240, 243, 248, 0.88);
  text-decoration: none;
  letter-spacing: -0.02em;
}
.back-nav-logo span {
  color: var(--tt-accent);
}

.back-nav-sep {
  color: var(--tt-border);
  font-size: 1rem;
}

.back-nav-label {
  font-family: "DM Mono", monospace;
  font-size: 0.62rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: rgba(240, 243, 248, 0.35);
}

.back-nav-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-family: "DM Mono", monospace;
  font-size: 0.62rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: rgba(240, 243, 248, 0.55);
  background: none;
  border: 1px solid var(--tt-border);
  text-decoration: none;
  padding: 0.4rem 0.9rem;
  border-radius: 3px;
  transition:
    color 0.2s,
    border-color 0.2s;
}
.back-nav-btn:hover {
  color: rgba(240, 243, 248, 0.9);
  border-color: rgba(240, 243, 248, 0.25);
}

/* ─── TOAST ──────────────────────────────────────────── */
.saved-toast {
  position: fixed;
  top: 68px;
  right: 1.5rem;
  background: rgba(34, 197, 94, 0.12);
  border: 1px solid rgba(34, 197, 94, 0.3);
  color: #6ee7a0;
  font-family: "DM Mono", monospace;
  font-size: 0.62rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding: 0.45rem 1rem;
  border-radius: 3px;
  opacity: 0;
  transition: opacity 0.3s;
  z-index: 999;
  pointer-events: none;
}
.saved-toast.show {
  opacity: 1;
}

/* ─── TOOLBAR ────────────────────────────────────────── */
.toolbar {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: rgba(13, 15, 20, 0.95);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-top: 1px solid var(--tt-border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.65rem 2rem;
  z-index: 100;
}

.toolbar-hint {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  font-family: "DM Mono", monospace;
  font-size: 0.58rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(240, 243, 248, 0.25);
}
.toolbar-hint svg {
  stroke: rgba(240, 243, 248, 0.25);
  flex-shrink: 0;
}

.toolbar-actions {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.toolbar-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-family: "DM Mono", monospace;
  font-size: 0.62rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 0.5rem 1rem;
  border-radius: 3px;
  border: none;
  cursor: pointer;
  transition: all 0.2s;
  white-space: nowrap;
}

.toolbar-btn-save {
  background: var(--tt-card-bg);
  color: rgba(240, 243, 248, 0.7);
  border: 1px solid var(--tt-border);
}
.toolbar-btn-save:hover {
  background: rgba(240, 243, 248, 0.08);
  color: rgba(240, 243, 248, 0.95);
}

.toolbar-btn-print {
  background: var(--tt-accent);
  color: #fff;
}
.toolbar-btn-print:hover {
  background: #3a7de9;
}
.toolbar-btn-print:active {
  transform: scale(0.97);
}

.toolbar-btn-reset {
  background: transparent;
  color: rgba(240, 243, 248, 0.25);
  border: 1px solid rgba(240, 243, 248, 0.08);
  font-size: 0.58rem;
}
.toolbar-btn-reset:hover {
  color: rgba(240, 243, 248, 0.55);
  border-color: rgba(240, 243, 248, 0.18);
}

/* ══════════════════════════════════════════════════════
   A PARTIR DAQUI: tudo dentro do #cv
   Mantém o design original do modelo executivo
══════════════════════════════════════════════════════════ */

/* ── EDIT HINTS (dentro do cv) ── */
#cv [contenteditable="true"]:hover {
  outline: 1.5px dashed rgba(184, 147, 63, 0.5);
  border-radius: 2px;
  cursor: text;
}
#cv [contenteditable="true"]:focus {
  outline: 2px solid var(--gold);
  border-radius: 2px;
  background: rgba(184, 147, 63, 0.07);
}

/* ── PÁGINA A4 ── */
#cv {
  width: 210mm;
  height: 297mm;
  background: var(--cream);
  box-shadow:
    0 8px 40px rgba(0, 0, 0, 0.5),
    0 2px 8px rgba(0, 0, 0, 0.3);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  font-family: "Source Sans 3", sans-serif;
  /* Separação do resto da página */
  margin-top: 1.5rem;
  margin-bottom: 1.5rem;
}

/* ── HEADER ── */
.cv-header {
  background: var(--navy);
  color: #fff;
  padding: 20px 34px;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 20px;
  align-items: center;
  flex-shrink: 0;
}

.cv-header h1 {
  font-family: "Playfair Display", serif;
  font-size: 27px;
  font-weight: 700;
  line-height: 1.15;
  margin-bottom: 3px;
}

.tagline {
  font-size: 10.5px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--gold-light);
  font-weight: 500;
}

.contacts {
  margin-top: 9px;
  display: flex;
  flex-direction: column;
  gap: 3px;
}
.contacts span,
.contacts a {
  font-size: 11px;
  color: rgba(255, 255, 255, 0.82);
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 6px;
}
.contacts a:hover {
  color: var(--gold-light);
}

.ci {
  width: 11px;
  height: 11px;
  fill: var(--gold-light);
  flex-shrink: 0;
}

/* ── FOTO ── */
.photo-area {
  width: 84px;
  height: 100px;
  border: 2px solid var(--gold);
  border-radius: 3px;
  overflow: hidden;
  cursor: pointer;
  background: rgba(255, 255, 255, 0.06);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: border-color 0.2s;
}
.photo-area:hover {
  border-color: var(--gold-light);
}
.photo-area img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: none;
}
.photo-ph {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 5px;
  color: rgba(255, 255, 255, 0.38);
  font-size: 9.5px;
  text-align: center;
  padding: 6px;
  pointer-events: none;
  font-family: "Source Sans 3", sans-serif;
}
.photo-ph svg {
  width: 24px;
  height: 24px;
}
#photo-input {
  display: none;
}

/* ── STRIPE ── */
.stripe {
  height: 4px;
  background: linear-gradient(
    90deg,
    var(--gold),
    var(--gold-light) 55%,
    transparent
  );
  flex-shrink: 0;
}

/* ── BODY ── */
.cv-body {
  display: grid;
  grid-template-columns: 196px 1fr;
  flex: 1;
  min-height: 0;
}

/* ── SIDEBAR ── */
.sidebar {
  background: var(--gray-light);
  border-right: 1px solid var(--gray-mid);
  padding: 16px 18px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  overflow: hidden;
}

/* ── MAIN ── */
.main {
  padding: 16px 28px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  overflow: hidden;
}

/* ── SECTION TITLE ── */
.stitle {
  font-family: "Playfair Display", serif;
  font-size: 9.5px;
  font-weight: 600;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--gold);
  border-bottom: 1px solid var(--gold);
  padding-bottom: 4px;
  margin-bottom: 9px;
}

/* ── OBJETIVO ── */
.obj {
  font-size: 12px;
  line-height: 1.65;
  color: var(--text);
}

/* ── EXPERIÊNCIA ── */
.exp + .exp {
  margin-top: 13px;
}

.exp-role {
  font-family: "Playfair Display", serif;
  font-size: 14px;
  font-weight: 600;
  color: var(--navy);
  margin-bottom: 1px;
}
.exp-co {
  font-size: 11px;
  font-weight: 600;
  color: var(--gold);
  letter-spacing: 0.04em;
  margin-bottom: 1px;
}
.exp-period {
  font-size: 10px;
  color: var(--muted);
  font-style: italic;
  margin-bottom: 6px;
}
.exp-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 3px;
}
.exp-list li {
  font-size: 11.5px;
  line-height: 1.5;
  color: var(--text);
  padding-left: 11px;
  padding-right: 18px;
  position: relative;
}
.exp-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 7px;
  width: 5px;
  height: 1px;
  background: var(--gold);
}

.badge {
  display: inline-block;
  background: var(--navy);
  color: var(--gold-light);
  font-size: 9.5px;
  font-weight: 600;
  letter-spacing: 0.05em;
  padding: 2px 8px;
  border-radius: 2px;
  margin-top: 5px;
  text-transform: uppercase;
  font-family: "Source Sans 3", sans-serif;
}

/* ── FORMAÇÃO ── */
.edu + .edu {
  margin-top: 9px;
}
.edu-deg {
  font-family: "Playfair Display", serif;
  font-size: 11.5px;
  font-weight: 600;
  color: var(--navy);
  line-height: 1.3;
  margin-bottom: 2px;
}
.edu-school {
  font-size: 10px;
  color: var(--muted);
  margin-bottom: 1px;
}
.edu-year {
  font-size: 9.5px;
  color: var(--gold);
  font-weight: 600;
  letter-spacing: 0.08em;
}

/* ── TAGS ── */
.tags {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
}
.tag {
  background: #fff;
  border: 1px solid var(--gray-mid);
  color: var(--text);
  font-size: 9.5px;
  padding: 2px 20px 2px 6px;
  border-radius: 2px;
  line-height: 1.5;
  position: relative;
  font-family: "Source Sans 3", sans-serif;
}

/* ── IDIOMAS ── */
.lang-item {
  position: relative;
}
.lang-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 3px;
}
.lang-name {
  font-size: 11px;
  font-weight: 500;
  color: var(--text);
}
.lang-lvl {
  font-size: 9.5px;
  color: var(--muted);
  font-style: italic;
}
.lang-bar {
  width: 100%;
  height: 3px;
  background: var(--gray-mid);
  border-radius: 2px;
  margin-bottom: 7px;
  overflow: hidden;
  cursor: pointer;
  transition: background 0.2s;
}
.lang-bar:hover {
  background: #b0aca4;
}
.lang-bar-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--navy), var(--gold));
  border-radius: 2px;
}

/* ── CURSOS ── */
.course {
  font-size: 10.5px;
  color: var(--text);
  padding: 3px 0;
  border-bottom: 1px dashed var(--gray-mid);
  line-height: 1.4;
  position: relative;
  font-family: "Source Sans 3", sans-serif;
}
.course:last-of-type {
  border-bottom: none;
}

/* ══════════════════════════════════════════════════════
   CONTROLES DINÂMICOS (dentro do #cv)
══════════════════════════════════════════════════════════ */
.section-wrap {
  position: relative;
}
.section-wrap:hover .dyn-add-row {
  opacity: 1;
  pointer-events: all;
}

.dyn-block {
  position: relative;
}
.dyn-block:hover > .dyn-remove {
  opacity: 1;
  pointer-events: all;
}

.dyn-remove {
  position: absolute;
  top: 1px;
  right: 0;
  width: 15px;
  height: 15px;
  background: #d94040;
  color: #fff;
  border: none;
  border-radius: 50%;
  font-size: 11px;
  line-height: 1;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition:
    opacity 0.15s,
    background 0.15s;
  z-index: 10;
}
.dyn-remove:hover {
  background: #b02020;
}

.dyn-add-row {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-top: 6px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.15s;
}

.dyn-add-btn {
  font-family: "Source Sans 3", sans-serif;
  font-size: 8px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--gold);
  background: transparent;
  border: 1px dashed var(--gold);
  border-radius: 2px;
  padding: 2px 7px;
  cursor: pointer;
  transition:
    background 0.15s,
    color 0.15s;
  white-space: nowrap;
}
.dyn-add-btn:hover {
  background: var(--gold);
  color: #fff;
}

.exp:hover .exp-inline-controls {
  opacity: 1;
  pointer-events: all;
}
.exp-inline-controls {
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.15s;
  margin-top: 4px;
  display: flex;
  gap: 5px;
}

.tag-remove {
  position: absolute;
  right: 4px;
  top: 50%;
  transform: translateY(-50%);
  width: 11px;
  height: 11px;
  background: #d94040;
  color: #fff;
  border: none;
  border-radius: 50%;
  font-size: 8px;
  line-height: 1;
  cursor: pointer;
  display: none;
  align-items: center;
  justify-content: center;
}
.tag:hover .tag-remove {
  display: flex;
}

.li-remove {
  position: absolute;
  right: 0;
  top: 3px;
  width: 13px;
  height: 13px;
  background: #d94040;
  color: #fff;
  border: none;
  border-radius: 50%;
  font-size: 9px;
  line-height: 1;
  cursor: pointer;
  display: none;
  align-items: center;
  justify-content: center;
}
.exp-list li:hover .li-remove {
  display: flex;
}

.badge-wrap {
  position: relative;
  display: inline-block;
  margin-top: 5px;
}
.badge-remove {
  position: absolute;
  top: -4px;
  right: -4px;
  width: 13px;
  height: 13px;
  background: #d94040;
  color: #fff;
  border: none;
  border-radius: 50%;
  font-size: 9px;
  cursor: pointer;
  display: none;
  align-items: center;
  justify-content: center;
}
.badge-wrap:hover .badge-remove {
  display: flex;
}

/* ─── PRINT ──────────────────────────────────────────── */
@media print {
  @page {
    size: A4;
    margin: 0;
  }

  body {
    background: none;
    padding: 0;
  }
  #cv {
    box-shadow: none;
    margin: 0;
  }

  .toolbar,
  .back-nav,
  .saved-toast {
    display: none !important;
  }

  .dyn-add-row,
  .dyn-remove,
  .li-remove,
  .tag-remove,
  .badge-remove,
  .exp-inline-controls {
    display: none !important;
  }

  .photo-ph {
    display: none !important;
  }

  #cv [contenteditable="true"]:hover,
  #cv [contenteditable="true"]:focus {
    outline: none !important;
    background: transparent !important;
  }

  .cv-header,
  .sidebar,
  .stripe,
  .badge,
  .lang-bar-fill,
  .tag {
    -webkit-print-color-adjust: exact;
    print-color-adjust: exact;
  }
}

/* ─── Botão formulário guiado ─── */
.back-nav-form-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-family: "DM Mono", monospace;
  font-size: 0.62rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #fff;
  background: var(--tt-accent);
  text-decoration: none;
  padding: 0.4rem 0.9rem;
  border-radius: 3px;
  transition: background 0.2s;
}
.back-nav-form-btn:hover {
  background: #3a7de9;
}
