/* ─────────────────────────────────────────────
   Dashboard Educadores — OEBP
   ───────────────────────────────────────────── */

/* ── Wrapper do dashboard ── */
.oebp-dashboard {
  width: 100%;
  box-sizing: border-box;
  padding: 0 24px;
  max-width: 1265px;
  margin: 0 auto;
}

/* ── Seção de busca ── */
.edu-busca-section {
  background: linear-gradient(135deg, #5f54d8 0%, #8b7fe8 100%);
  border-radius: 20px;
  padding: 48px 32px;
  text-align: center;
  margin-bottom: 32px;
  width: 100%;
  box-sizing: border-box;
}

.edu-busca-title {
  font-size: 28px;
  font-weight: 700;
  color: #fff;
  margin: 0 0 8px;
}

.edu-busca-sub {
  font-size: 15px;
  color: rgba(255,255,255,0.8);
  margin: 0 0 24px;
}

.edu-busca-wrap {
  display: flex;
  gap: 8px;
  max-width: 600px;
  margin: 0 auto;
  position: relative;
}

#edu-busca-input {
  height: 48px;
  flex: 1;
  padding: 14px 18px;
  border: none;
  border-radius: 10px;
  font-size: 15px;
  font-family: inherit;
  outline: none;
  box-shadow: 0 4px 16px rgba(0,0,0,0.15);
}

#edu-busca-suggestions {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  background: #fff;
  border-radius: 0 0 10px 10px;
  box-shadow: 0 8px 24px rgba(0,0,0,0.15);
  list-style: none;
  margin: 0;
  padding: 0;
  z-index: 100;
  display: none;
  max-height: 240px;
  overflow-y: auto;
}

#edu-busca-suggestions li {
  padding: 10px 18px;
  cursor: pointer;
  font-size: 14px;
  color: #333;
  border-bottom: 1px solid #f0f0f0;
  transition: background 0.1s;
}

#edu-busca-suggestions li:hover {
  background: #f5f0ff;
  color: #5f54d8;
}

/* ── Resultado da busca ── */
#edu-resultado { display: none; }

.edu-resultado-header { margin-bottom: 20px; }

.edu-resultado-header h3 {
  margin: 0;
  font-size: 22px;
  font-weight: 700;
  color: #2c2c2c;
}

.edu-resultado-header h3 span { color: #5f54d8; }

/* ── Grid de comparativos ── */
.edu-comp-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 16px;
  margin-bottom: 24px;
}

.edu-comp-card {
  background: #fff;
  border-radius: 12px;
  padding: 18px;
  box-shadow: 0 2px 12px rgba(0,0,0,0.06);
}

.edu-comp-header {
  margin-bottom: 14px;
  padding-bottom: 10px;
  border-bottom: 1px solid #f0f0f0;
}

.edu-comp-label { display: block; font-size: 13px; font-weight: 700; color: #333; margin-bottom: 2px; }
.edu-comp-sub { display: block; font-size: 11px; color: #aaa; }

.edu-comp-valores {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  margin-bottom: 12px;
}

.edu-comp-mun { display: flex; flex-direction: column; gap: 2px; }
.edu-comp-mun-label { font-size: 11px; color: #888; }
.edu-comp-mun-valor { font-size: 28px; font-weight: 700; line-height: 1; }
.edu-comp-diff { font-size: 12px; font-weight: 600; }
.edu-comp-pr { display: flex; flex-direction: column; align-items: flex-end; gap: 2px; }
.edu-comp-pr-label { font-size: 10px; color: #aaa; }
.edu-comp-pr-valor { font-size: 18px; font-weight: 600; color: #999; }

.edu-comp-dica {
  font-size: 11px;
  color: #888;
  line-height: 1.4;
  padding-top: 10px;
  border-top: 1px solid #f5f5f5;
}

/* ── Classificação e tendência ── */
.edu-comp-classificacao {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 10px;
  flex-wrap: wrap;
}

.edu-comp-rank-icon { font-size: 16px; }

.edu-comp-rank-txt {
  font-size: 12px;
  font-weight: 700;
}

.edu-comp-tend {
  font-size: 11px;
  font-weight: 600;
  margin-left: auto;
}

/* ── Total estabelecimentos ── */
.edu-estab-total {
  display: flex;
  align-items: baseline;
  gap: 6px;
  margin-bottom: 12px;
}

.edu-estab-total-num {
  font-size: 32px;
  font-weight: 700;
  line-height: 1;
}

.edu-estab-total-label {
  font-size: 12px;
  color: #888;
}

/* ── Estabelecimentos ── */
.edu-estab-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; margin-bottom: 12px; }
.edu-estab-item { display: flex; flex-direction: column; align-items: center; gap: 2px; }
.edu-estab-num { font-size: 22px; font-weight: 700; color: #333; }
.edu-estab-rede { font-size: 10px; color: #aaa; text-align: center; }

/* ── Gráficos ── */
.edu-graficos-grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr;
  gap: 16px;
  margin-bottom: 32px;
}

.edu-grafico-card {
  background: #fff;
  border-radius: 12px;
  padding: 18px;
  box-shadow: 0 2px 12px rgba(0,0,0,0.06);
}

.edu-grafico-wrap { height: 200px; position: relative; }

/* ─────────────────────────────────────────────
   Infográficos — cards com flip no hover
   ───────────────────────────────────────────── */

.edu-infograficos {
  margin-bottom: 32px;
  width: 100%;
  box-sizing: border-box;
}

.edu-infograficos-title {
  font-size: 18px;
  font-weight: 700;
  color: #2c2c2c;
  margin-bottom: 16px;
}

.edu-infograficos-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

/* Container com perspectiva para o flip */
.edu-info-card {
  height: 220px;
  perspective: 1000px;
  cursor: pointer;
}

/* Inner que rotaciona */
.edu-info-card-inner {
  position: relative;
  width: 100%;
  height: 100%;
  transition: transform 0.55s cubic-bezier(0.4, 0, 0.2, 1);
  transform-style: preserve-3d;
}

.edu-info-card:hover .edu-info-card-inner,
.edu-info-card:focus-within .edu-info-card-inner {
  transform: rotateY(180deg);
}

/* Faces frontal e traseira */
.edu-info-front,
.edu-info-back {
  position: absolute;
  inset: 0;
  border-radius: 16px;
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 28px 24px;
  box-sizing: border-box;
}

/* Frente — roxo escuro, título + ícone */
.edu-info-front {
  background: #3d3591;
  color: #fff;
  text-align: center;
  gap: 16px;
}

.edu-info-front-titulo {
  font-size: 20px;
  font-weight: 700;
  color: #fff;
  line-height: 1.25;
}

.edu-info-front-icone {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: rgba(255,255,255,0.2);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  color: #fff;
  flex-shrink: 0;
}

/* Verso — roxo médio, lista com bullets coloridos */
.edu-info-back {
  background: #5f54d8;
  color: #fff;
  transform: rotateY(180deg);
  align-items: flex-start;
  justify-content: center;
  gap: 0;
  text-align: left;
  overflow-y: auto;
}

.edu-info-back-lista {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
  width: 100%;
}

.edu-info-back-lista li {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 13px;
  color: #fff;
  line-height: 1.45;
}

.edu-info-bullet {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  flex-shrink: 0;
  margin-top: 2px;
}

/* ── Cards de dicas ── */
.edu-dicas {
  width: 100%;
  box-sizing: border-box;
  margin-bottom: 16px;
}

.edu-dicas-title {
  font-size: 18px;
  font-weight: 700;
  color: #2c2c2c;
  margin-bottom: 16px;
}

.edu-dicas-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}

.edu-dica-card {
  background: linear-gradient(135deg, #f8f6ff 0%, #fff 100%);
  border-radius: 12px;
  padding: 20px;
  box-shadow: 0 2px 12px rgba(0,0,0,0.06);
  border-left: 4px solid #5f54d8;
}

.edu-dica-tag {
  display: inline-block;
  background: #5f54d8;
  color: #fff;
  font-size: 10px;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: 4px;
  margin-bottom: 10px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.edu-dica-titulo { font-size: 14px; font-weight: 700; color: #333; margin-bottom: 8px; line-height: 1.3; }
.edu-dica-texto { font-size: 13px; color: #666; line-height: 1.5; }

/* ── Responsivo ── */
@media (max-width: 900px) {
  .edu-comp-grid { grid-template-columns: 1fr 1fr; }
  .edu-graficos-grid { grid-template-columns: 1fr; }
  .edu-infograficos-grid, .edu-dicas-grid { grid-template-columns: 1fr; }
  .edu-info-card { height: 260px; }
}

@media (max-width: 600px) {
  .edu-comp-grid { grid-template-columns: 1fr; }
  .oebp-dashboard { padding: 0 12px; }
}