/* Complementos do Teste de Padrões sobre o style.css do Diagnóstico de Carreira */

#lead-form select {
  width: 100%;
  margin-top: 6px;
  padding: 13px 14px;
  border: 1px solid #D9D2C7;
  border-radius: 8px;
  font-size: 16px;
  font-family: 'Source Sans 3', system-ui, sans-serif;
  background: var(--branco);
  color: var(--cinza);
}

.btn-back {
  display: inline-block;
  margin-top: 22px;
  background: none;
  border: none;
  padding: 6px 0;
  color: #636B6D;
  font-family: 'Source Sans 3', system-ui, sans-serif;
  font-size: 14px;
  text-decoration: underline;
  cursor: pointer;
}

.screen.screen-wide { max-width: 860px; }
.progress-wide { max-width: 860px; }

/* ---------- Tela com várias frases ---------- */
.card-page { padding: 36px 40px; }
.card-page h2 { font-size: 22px; margin: 0 0 6px 0; }
.page-sub { font-size: 15px; color: #636B6D; margin: 0 0 22px 0; }

.item { border: 0; margin: 0; padding: 0; min-width: 0; }
.item-texto { margin: 0; padding: 0; font-size: 16px; line-height: 1.5; color: var(--cinza); }

/* Linha de cabeçalho com os rótulos da escala (só no computador) */
.escala-head, .item-frase {
  display: grid;
  grid-template-columns: 1fr repeat(5, 76px);
  align-items: center;
  column-gap: 4px;
}
.escala-head {
  position: sticky; top: 0; z-index: 2;
  background: var(--branco);
  padding: 8px 0 10px 0;
  border-bottom: 1px solid rgba(24,69,112,0.14);
}
.escala-head span { font-size: 12px; font-weight: 700; color: var(--azul); text-align: center; line-height: 1.25; }
.escala-legenda { display: none; }

.item-frase { padding: 14px 0; border-bottom: 1px solid rgba(24,69,112,0.08); }
.item-frase .item-texto { grid-column: 1; padding-right: 16px; }
.item-opcoes { display: contents; }

.op { display: flex; flex-direction: column; align-items: center; cursor: pointer; padding: 4px 0; }
.op input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.op-marca {
  width: 30px; height: 30px; border-radius: 50%;
  border: 2px solid #C9D3DC; background: var(--branco);
  display: flex; align-items: center; justify-content: center;
  transition: background 0.12s ease, border-color 0.12s ease;
}
.op-num { font-size: 0; }
.op-label { display: none; }
.op:hover .op-marca { border-color: var(--terracota); }
.op input:checked + .op-marca { background: var(--azul); border-color: var(--azul); box-shadow: inset 0 0 0 4px var(--branco); }
.op input:focus-visible + .op-marca { outline: 3px solid var(--terracota-texto); outline-offset: 2px; }

.item.respondido .item-texto { color: #636B6D; }
.item.faltando { background: rgba(166,102,81,0.08); border-radius: 10px; }
.item.faltando .item-texto { color: var(--terracota-texto); font-weight: 600; }
.page-erro { color: var(--terracota-texto); font-weight: 600; font-size: 15px; min-height: 22px; margin: 16px 0 0 0; }

.page-nav { display: flex; justify-content: space-between; align-items: center; margin-top: 12px; }
.page-nav .btn-back { margin-top: 0; }

/* Custo: 3 perguntas com opções empilhadas */
.item-custo { margin-bottom: 26px; }
.item-custo .item-texto { font-weight: 600; color: var(--azul); margin-bottom: 10px; }
.item-custo.respondido .item-texto { color: var(--azul); }
.custo-opcoes { display: flex; flex-direction: column; gap: 8px; }
.op-custo {
  display: block; position: relative; cursor: pointer;
  background: var(--off-white); border: 2px solid transparent; border-radius: 12px;
  padding: 13px 16px; font-size: 15px; line-height: 1.45;
}
.op-custo input { position: absolute; opacity: 0; }
.op-custo:hover { border-color: var(--terracota); }
.op-custo:has(input:checked) { border-color: var(--azul); background: rgba(24,69,112,0.06); color: var(--azul); font-weight: 700; }
.op-custo:has(input:focus-visible) { outline: 3px solid var(--terracota-texto); outline-offset: 2px; }

/* Celular: frase em cima, 5 números embaixo, legenda fixa no topo */
@media (max-width: 680px) {
  .card-page { padding: 26px 18px; }
  .escala-head { display: none; }
  .escala-legenda {
    display: block; position: sticky; top: 0; z-index: 2;
    background: var(--branco); margin: 0 -18px; padding: 10px 18px;
    border-bottom: 1px solid rgba(24,69,112,0.14);
    font-size: 13px; color: var(--cinza); line-height: 1.6;
  }
  .escala-legenda b { color: var(--azul); }
  .item-frase { display: block; padding: 16px 0; }
  .item-frase .item-texto { padding-right: 0; margin-bottom: 10px; }
  .item-opcoes { display: grid; grid-template-columns: repeat(5, 1fr); gap: 6px; }
  .op-marca { width: 100%; height: 42px; border-radius: 10px; }
  .op-num { font-size: 16px; font-weight: 700; color: var(--cinza); }
  .op input:checked + .op-marca { box-shadow: none; }
  .op input:checked + .op-marca .op-num { color: var(--branco); }
}

.result-meta {
  font-size: 14px;
  color: #636B6D;
  margin: -6px 0 6px 0;
}

.rel-sec {
  margin-top: 34px;
  padding-top: 26px;
  border-top: 1px solid rgba(24,69,112,0.12);
}

.rel-sec h2 { font-size: 22px; margin: 0 0 10px 0; }

.rel-sec p, .rel-fechamento {
  font-size: 15px;
  line-height: 1.7;
  margin: 0 0 14px 0;
}

.rel-intro { color: #636B6D; font-size: 13px !important; line-height: 1.55 !important; }

.rel-destaque {
  background: var(--off-white);
  border-radius: 12px;
  padding: 16px 18px;
}

/* Título: só os nomes dos padrões em destaque */
#result-title { font-weight: 400; }
#result-title strong { font-weight: 600; }

/* Resumo em 3 cartões logo abaixo do título */
.resumo { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin: 22px 0 6px 0; }
.resumo > div { background: var(--off-white); border-radius: 12px; padding: 14px 16px; }
.resumo-rot { display: block; font-size: 12px; font-weight: 700; letter-spacing: 1px; text-transform: uppercase; color: var(--terracota-texto); margin-bottom: 4px; }
.resumo-val { display: block; font-family: 'Source Serif 4', Georgia, serif; font-size: 20px; color: var(--azul); line-height: 1.25; }

/* Barras verticais, as 2 famílias no mesmo eixo */
.vchart { margin: 14px 0 20px 0; padding-left: 18px; }
.vplot { position: relative; height: 220px; display: flex; gap: 18px; padding-top: 22px; border-bottom: 1.5px solid #C9D3DC; }
.vgrupo { display: flex; gap: 6px; }
.vplot .vgrupo:first-of-type, .vlabels .vgrupo:first-child { flex: 6; }
.vplot .vgrupo:last-of-type, .vlabels .vgrupo:last-child { flex: 5; }
.vcol { position: relative; flex: 1; display: flex; flex-direction: column; justify-content: flex-end; align-items: center; height: 100%; min-width: 0; }
.vcol::before { content: ''; position: absolute; bottom: 0; left: 50%; transform: translateX(-50%); width: 24px; height: 100%; background: rgba(24,69,112,0.07); border-radius: 4px 4px 0 0; }
.vcol .vbar { z-index: 1; }
.vtopo { position: absolute; left: 0; right: 0; top: 22px; border-top: 1px solid rgba(24,69,112,0.14); pointer-events: none; }
.vtopo-tag { position: absolute; left: -24px; top: -9px; font-size: 12px; font-weight: 700; color: #636B6D; }
.vbar { position: relative; width: 24px; background: #A9BACB; border-radius: 4px 4px 0 0; }
.vcol.dom .vbar { background: var(--azul); }
.vval { position: absolute; left: 50%; bottom: 100%; transform: translateX(-50%); padding-bottom: 3px; font-size: 14px; color: var(--cinza); white-space: nowrap; }
.vcol.dom .vval { font-weight: 700; color: var(--azul); }
.vlimiar { z-index: 2; position: absolute; left: 0; right: 0; bottom: calc((100% - 22px) * 0.5); border-top: 1.5px dashed var(--terracota-texto); pointer-events: none; }
.vlimiar-tag { position: absolute; left: -18px; top: -9px; font-size: 12px; font-weight: 700; color: var(--terracota-texto); background: var(--branco); padding: 0 4px 0 0; }
.vlabels { display: flex; gap: 18px; margin-top: 8px; }
.vlab { flex: 1; min-width: 0; display: flex; justify-content: center; align-items: flex-start; }
.vlab span { writing-mode: vertical-rl; transform: rotate(180deg); font-size: 13px; color: var(--cinza); white-space: nowrap; }
.vlab.dom span { font-weight: 700; color: var(--azul); }
.vfams { display: flex; gap: 18px; margin-top: 6px; }
.vfam { border-top: 2px solid var(--terracota); padding-top: 6px; font-size: 12px; font-weight: 700; letter-spacing: 1px; text-transform: uppercase; color: var(--terracota-texto); text-align: center; }

@media (max-width: 520px) {
  .resumo { grid-template-columns: 1fr; }
  .vplot, .vlabels, .vfams { gap: 8px; }
  .vgrupo { gap: 3px; }
  .vval { font-size: 12px; }
  .vbar, .vcol::before { width: 12px; }
  .vlab span { font-size: 12px; }
  .vfam { font-size: 11px; letter-spacing: 0.5px; }
}
@media print {
  .vbar, .resumo > div, .pizza-legenda .sw, .defs .sw { -webkit-print-color-adjust: exact; print-color-adjust: exact; }
}

/* Pizza */
.pizza-wrap { display: flex; align-items: center; gap: 28px; flex-wrap: wrap; margin: 10px 0 18px 0; }
.chart-pizza { width: 200px; height: 200px; flex-shrink: 0; }
.pizza-legenda { list-style: none; margin: 0; padding: 0; flex: 1; min-width: 200px; }
.pizza-legenda li { display: flex; align-items: center; gap: 10px; padding: 8px 0; border-bottom: 1px solid rgba(24,69,112,0.08); font-size: 15px; }
.pizza-legenda .sw { width: 14px; height: 14px; border-radius: 4px; flex-shrink: 0; }
.pizza-legenda .lg-nome { flex: 1; color: var(--cinza); font-weight: 600; }
.pizza-legenda .lg-val { color: var(--azul); font-weight: 700; }
.pizza-legenda .lg-pct { color: #636B6D; width: 44px; text-align: right; }

.pizza-lado { flex: 1; min-width: 200px; }
.pizza-legenda li.maior .lg-nome, .pizza-legenda li.maior .lg-val { color: var(--azul); font-weight: 700; }
.asterisco { font-size: 13px !important; color: #636B6D; margin: 10px 0 0 0 !important; font-style: italic; }
.defs-titulo { font-size: 13px !important; font-weight: 700; letter-spacing: 1px; text-transform: uppercase; color: var(--terracota-texto); margin: 22px 0 4px 0 !important; }
.defs { margin: 0; }
.defs dt { display: flex; align-items: center; gap: 8px; font-weight: 700; color: var(--azul); margin-top: 12px; }
.defs dd { margin: 4px 0 0 22px; font-size: 15px; line-height: 1.6; }
.defs .sw { width: 12px; height: 12px; border-radius: 3px; display: inline-block; }

/* Fichas */
.ficha {
  border: 1px solid rgba(24,69,112,0.14);
  border-radius: 14px;
  padding: 24px 24px 18px 24px;
  margin: 18px 0;
}
.ficha-fam { font-size: 12px; font-weight: 700; letter-spacing: 1.5px; text-transform: uppercase; color: var(--terracota-texto); margin: 0 0 4px 0 !important; }
.ficha h3 { font-family: 'Source Serif 4', Georgia, serif; color: var(--azul); font-size: 24px; margin: 0 0 8px 0; }
.ficha-oque { font-size: 16px !important; color: var(--azul); }
.ficha dl { margin: 0; }
.ficha dt { font-size: 13px; font-weight: 700; color: var(--cinza); margin-top: 14px; }
.ficha dd { margin: 4px 0 0 0; font-size: 15px; line-height: 1.65; }
.ficha-sub { font-size: 13px !important; font-weight: 700; color: var(--cinza); margin: 18px 0 6px 0 !important; }
.ficha-semanas { margin: 6px 0 0 0; }
.ficha-semanas p { font-size: 15px !important; line-height: 1.6; margin: 0 0 10px 0 !important; }
.sem-tag { display: block; font-size: 12px; font-weight: 700; letter-spacing: 0.5px; text-transform: uppercase; color: var(--terracota-texto); margin-bottom: 2px; }

/* Outros padrões */
.outros-grupo { font-size: 12px !important; font-weight: 700; letter-spacing: 1px; text-transform: uppercase; color: var(--terracota-texto); margin: 16px 0 2px 0 !important; }
.outros { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: 1fr 1fr; column-gap: 20px; }
.outros li { display: grid; grid-template-columns: 1fr auto; align-content: start; gap: 1px 8px; padding: 8px 0; border-bottom: 1px solid rgba(24,69,112,0.08); }
.outros-nome { font-size: 14px; font-weight: 700; color: var(--azul); }
.outros-val { font-size: 13px; color: #636B6D; font-weight: 600; }
.outros-linha { grid-column: 1 / -1; font-size: 12.5px; line-height: 1.4; color: #636B6D; }
@media (max-width: 520px) { .outros { column-gap: 14px; } }

.rel-fechamento { margin-top: 30px; font-style: italic; }
#print-btn { margin-top: 10px; }

@media (max-width: 520px) {
  .pizza-wrap { justify-content: center; }
  .ficha { padding: 20px 16px 14px 16px; }
}

@media print {
  body { background: #fff; }
  .no-print, .brand-header { display: none; }
  .card { box-shadow: none; padding: 0; }
  .app-body { padding: 0; }
  .ficha { break-inside: avoid; }
  .rel-sec h2 { break-after: avoid; }
}
