/*====================================
  NÍVEIS DE ENSINO — niveis.css
  Páginas de nível de ensino do CFV
  Inclui após style.css
====================================*/


/* ══════════════════════════════════
   ACCENT POR NÍVEL (CSS vars no body)
══════════════════════════════════ */
body.nivel-infantil     { --nv: #0c666a; --nv-rgb: 12,102,106;  --nv-light: rgba(12,102,106,0.08);  --nv-dark: #0a5257; }
body.nivel-fundamental1 { --nv: #a67c00; --nv-rgb: 166,124,0;   --nv-light: rgba(166,124,0,0.08);   --nv-dark: #8a6600; }
body.nivel-fundamental2 { --nv: #cc5852; --nv-rgb: 204,88,82;   --nv-light: rgba(204,88,82,0.08);   --nv-dark: #b04840; }
body.nivel-medio        { --nv: #a67c00; --nv-rgb: 166,124,0;   --nv-light: rgba(166,124,0,0.08);   --nv-dark: #8a6600; }


/* ══════════════════════════════════
   HERO
══════════════════════════════════ */
.nivel-hero {
  background: linear-gradient(135deg, #1a3a58 0%, #0f2035 100%);
  padding: 120px 32px 56px;
}

.nivel-hero__container {
  max-width: 1140px;
  margin: 0 auto;
}

.nivel-breadcrumb {
  font-size: 0.6875rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.45);
  margin-bottom: 16px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.nivel-breadcrumb a {
  color: rgba(255, 255, 255, 0.45);
  text-decoration: none;
  transition: color 0.2s;
}

.nivel-breadcrumb a:hover { color: rgba(255, 255, 255, 0.70); }
.nivel-breadcrumb__sep { color: rgba(255, 255, 255, 0.22); }

.nivel-hero__titulo {
  font-family: 'Poppins', sans-serif;
  font-size: clamp(2.25rem, 5vw, 3.5rem);
  font-weight: 800;
  color: #ffffff;
  line-height: 1.08;
  letter-spacing: -0.02em;
  margin: 0;
}


/* ══════════════════════════════════
   SHARED STRUCTURE
══════════════════════════════════ */
.nivel-main {
  background: #ffffff;
}

.nivel-container {
  max-width: 1140px;
  margin: 0 auto;
  padding: 0 32px;
}

.nivel-divider {
  border: none;
  border-top: 1px solid #e5eaf0;
  margin: 0;
}

/* Short accent bar before section titles */
.nivel-bar {
  display: block;
  width: 36px;
  height: 4px;
  border-radius: 99px;
  background-color: var(--nv, #2c6c9c);
  margin-bottom: 14px;
}

.nivel-bar--amarelo { background-color: #e09200; }
.nivel-bar--azul    { background-color: #1a2d3e; }
.nivel-bar--vermelho { background-color: #cc5852; }


/* ══════════════════════════════════
   INTRO — 2 COLUNAS
══════════════════════════════════ */
.nivel-intro {
  padding: 64px 0 60px;
}

.nivel-intro__grid {
  display: grid;
  grid-template-columns: 1fr 400px;
  gap: 60px;
  align-items: start;
}

/* Colored label: "—— LABEL TEXT" */
.nivel-label {
  font-size: 0.6875rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--nv);
  margin-bottom: 20px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.nivel-label__linha {
  display: inline-block;
  width: 28px;
  height: 3px;
  background-color: var(--nv);
  border-radius: 2px;
  flex-shrink: 0;
}

.nivel-intro__p {
  font-size: 0.9375rem;
  color: #445566;
  line-height: 1.8;
  margin-bottom: 24px;
}

.nivel-intro__subtitulo {
  font-family: 'Poppins', sans-serif;
  font-size: 1.0625rem;
  font-weight: 700;
  color: #1a2d3e;
  margin-bottom: 16px;
}

/* Bullet list with colored squares */
.nivel-bullets {
  list-style: none;
  padding: 0;
  margin: 0 0 20px;
  display: flex;
  flex-direction: column;
  gap: 9px;
}

.nivel-bullets li {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 0.9rem;
  color: #445566;
  line-height: 1.5;
}

.nivel-bullets li::before {
  content: '■';
  color: var(--nv);
  font-size: 0.7rem;
  flex-shrink: 0;
  margin-top: 4px;
}

/* Highlighted sentence below bullets */
.nivel-intro__destaque {
  font-size: 0.9375rem;
  color: var(--nv);
  line-height: 1.65;
  margin-bottom: 16px;
  font-weight: 500;
}

/* Blockquote sidebar-style note */
.nivel-blockquote {
  border-left: 4px solid var(--nv);
  background: var(--nv-light);
  padding: 12px 16px;
  border-radius: 0 8px 8px 0;
  font-size: 0.875rem;
  color: #445566;
  line-height: 1.65;
  margin: 0;
}

/* Right column: image with decorative border offset */
.nivel-intro__foto {
  position: relative;
}

.nivel-intro__foto::after {
  content: '';
  position: absolute;
  top: 14px;
  left: 14px;
  right: -14px;
  bottom: -14px;
  border: 2px solid #dde6ef;
  border-radius: 12px;
  z-index: 0;
  pointer-events: none;
}

.nivel-intro__foto img {
  width: 100%;
  border-radius: 10px;
  display: block;
  position: relative;
  z-index: 1;
  object-fit: cover;
  aspect-ratio: 4 / 3;
}


/* ══════════════════════════════════
   CALENDÁRIO CARD
══════════════════════════════════ */
.nivel-calendario {
  padding: 40px 0;
}

.nivel-cal {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 20px 0;
}

.nivel-cal__left {}

.nivel-cal__acento {
  display: block;
  width: 32px;
  height: 4px;
  border-radius: 99px;
  background: #e09200;
  margin-bottom: 12px;
}

.nivel-cal__titulo {
  font-family: 'Poppins', sans-serif;
  font-size: 1.0625rem;
  font-weight: 700;
  color: #1a2d3e;
  margin-bottom: 5px;
}

.nivel-cal__sub {
  font-size: 0.875rem;
  color: #7a8fa0;
}

.nivel-cal__btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: #1a2d3e;
  color: #ffffff;
  font-family: 'Poppins', sans-serif;
  font-weight: 600;
  font-size: 0.875rem;
  padding: 11px 22px;
  border-radius: 8px;
  text-decoration: none;
  white-space: nowrap;
  flex-shrink: 0;
  transition: background 0.2s;
}

.nivel-cal__btn:hover { background: #0c3c60; }


/* ══════════════════════════════════
   LISTA DE MATERIAL
══════════════════════════════════ */
.nivel-material {
  padding: 48px 0 40px;
}

.nivel-secao__titulo {
  font-family: 'Poppins', sans-serif;
  font-size: 1.0625rem;
  font-weight: 700;
  color: #1a2d3e;
  margin-bottom: 6px;
}

.nivel-secao__sub {
  font-size: 0.875rem;
  color: #7a8fa0;
  margin-bottom: 28px;
}

/* Grid of material cards */
.nivel-material__grade {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 36px;
}

.nivel-material__card {
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  padding: 18px 14px 14px;
  text-align: center;
  text-decoration: none;
  color: #1a2d3e;
  width: 116px;
  transition: box-shadow 0.22s, transform 0.22s;
  cursor: pointer;
  background: #ffffff;
}

.nivel-material__card:hover {
  box-shadow: 0 6px 22px rgba(44, 108, 156, 0.14);
  transform: translateY(-2px);
}

.nivel-material__icone {
  width: 50px;
  height: 50px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 12px;
  color: #ffffff;
}

/* Icon background colors */
.ic-verde    { background-color: #0c666a; }
.ic-amarelo  { background-color: #e09200; }
.ic-azul     { background-color: #1a2d3e; }
.ic-vermelho { background-color: #cc5852; }
.ic-azul2    { background-color: #2c6c9c; }
.ic-roxo     { background-color: #7a4fa0; }

.nivel-material__nome {
  font-size: 0.8125rem;
  font-weight: 700;
  color: #1a2d3e;
  line-height: 1.3;
}

/* Observations */
.nivel-obs {
  margin-bottom: 36px;
}

.nivel-obs__titulo {
  font-family: 'Poppins', sans-serif;
  font-size: 0.9375rem;
  font-weight: 700;
  color: #1a2d3e;
  margin-bottom: 12px;
}

.nivel-obs__lista {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.nivel-obs__lista li {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 0.875rem;
  color: #445566;
  line-height: 1.6;
}

.nivel-obs__lista li::before {
  content: '■';
  color: #cc5852;
  font-size: 0.68rem;
  flex-shrink: 0;
  margin-top: 4px;
}

.nivel-obs__lista li strong { color: #1a2d3e; }

/* Material Didático */
.nivel-mat-didatico {
  padding: 0 0 16px;
}

.nivel-mat-didatico__titulo {
  font-family: 'Poppins', sans-serif;
  font-size: 0.9375rem;
  font-weight: 700;
  color: #1a2d3e;
  margin-bottom: 12px;
}

.nivel-mat-didatico p {
  font-size: 0.875rem;
  color: #445566;
  line-height: 1.65;
  margin-bottom: 5px;
}

.nivel-mat-didatico a {
  color: #a67c00;
  font-weight: 600;
  text-decoration: none;
}

.nivel-mat-didatico a:hover { text-decoration: underline; }


/* ══════════════════════════════════
   HORÁRIO DAS AULAS
══════════════════════════════════ */
.nivel-horario {
  padding: 48px 0;
}

.nivel-horario__cabecalho {
  display: flex;
  align-items: flex-start;
  gap: 16px;
  margin-bottom: 24px;
}

.nivel-horario__barra {
  width: 4px;
  min-height: 44px;
  border-radius: 99px;
  background-color: var(--nv);
  flex-shrink: 0;
  margin-top: 3px;
}

.nivel-horario__titulo {
  font-family: 'Poppins', sans-serif;
  font-size: 1.0625rem;
  font-weight: 700;
  color: #1a2d3e;
  margin-bottom: 0;
}

/* Turma pill buttons */
.nivel-turmas {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 16px;
}

.nivel-turma-btn {
  display: inline-flex;
  align-items: center;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.07em;
  color: #4a607a;
  background: #f4f7fa;
  border: 1px solid #d0dce8;
  border-radius: 6px;
  padding: 7px 14px;
  text-decoration: none;
  transition: background 0.18s, border-color 0.18s, color 0.18s;
  cursor: pointer;
}

.nivel-turma-btn:hover {
  background: #e4edf5;
  border-color: var(--nv);
  color: #1a2d3e;
}

.nivel-turmas-hint {
  font-size: 0.8125rem;
  color: #a67c00;
  font-style: italic;
  margin-top: 8px;
}


/* ══════════════════════════════════
   INFO BAR
══════════════════════════════════ */
.nivel-info-bar {
  background: #eef2f6;
  padding: 48px 32px;
}

.nivel-info-bar__container {
  max-width: 1140px;
  margin: 0 auto;
  text-align: center;
}

.nivel-info-bar__texto {
  font-size: 1rem;
  color: var(--nv);
  font-weight: 500;
  line-height: 1.65;
  margin-bottom: 22px;
  max-width: 640px;
  margin-left: auto;
  margin-right: auto;
  margin-bottom: 22px;
}

.nivel-info-bar__contatos {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 36px;
  flex-wrap: wrap;
}

.nivel-info-bar__item {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.9rem;
  color: #445566;
}

.nivel-info-bar__item svg {
  flex-shrink: 0;
  color: #7a8fa0;
}


/* ══════════════════════════════════
   CTA FINAL
══════════════════════════════════ */
.nivel-cta {
  background: linear-gradient(135deg, #1a3a58 0%, #0f2035 100%);
  padding: 60px 32px 0;
  text-align: center;
}

.nivel-cta__titulo {
  font-family: 'Poppins', sans-serif;
  font-size: clamp(1.5rem, 3vw, 2.125rem);
  font-weight: 800;
  color: #ffffff;
  margin-bottom: 28px;
  line-height: 1.2;
}

.nivel-cta__botao {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: #f8ec0f;
  color: #0c3c60;
  font-family: 'Poppins', sans-serif;
  font-weight: 700;
  font-size: 1rem;
  padding: 14px 40px;
  border-radius: 999px;
  text-decoration: none;
  margin-bottom: 52px;
  transition: background 0.2s, transform 0.2s, box-shadow 0.2s;
  box-shadow: 0 8px 28px rgba(248, 236, 15, 0.35);
}

.nivel-cta__botao:hover {
  background: #ffe94d;
  transform: translateY(-2px);
  box-shadow: 0 12px 36px rgba(248, 236, 15, 0.45);
}

/* Rainbow decoration bar */
.nivel-cta__rainbow {
  display: flex;
  height: 6px;
}

.nivel-cta__rainbow span {
  flex: 1;
}

.nivel-cta__rainbow span:nth-child(1) { background: #0c666a; }
.nivel-cta__rainbow span:nth-child(2) { background: #f8ec0f; }
.nivel-cta__rainbow span:nth-child(3) { background: #cc5852; }


/* ══════════════════════════════════
   RESPONSIVIDADE
══════════════════════════════════ */
@media (max-width: 1024px) {
  .nivel-intro__grid {
    grid-template-columns: 1fr;
    gap: 40px;
  }

  .nivel-intro__foto::after {
    display: none;
  }

  .nivel-intro__foto img {
    aspect-ratio: 16 / 9;
  }

  .nivel-material__card {
    width: calc(33.33% - 7px);
  }
}

@media (max-width: 768px) {
  .nivel-hero {
    padding: 108px 20px 44px;
  }

  .nivel-container {
    padding: 0 20px;
  }

  .nivel-info-bar {
    padding: 40px 20px;
  }

  .nivel-cta {
    padding: 48px 20px 0;
  }

  .nivel-cal {
    flex-direction: column;
    align-items: flex-start;
    gap: 18px;
  }

  .nivel-material__card {
    width: calc(50% - 5px);
  }

  .nivel-info-bar__contatos {
    flex-direction: column;
    gap: 14px;
  }
}

@media (max-width: 480px) {
  .nivel-material__card {
    width: calc(50% - 5px);
  }

  .nivel-turmas {
    gap: 6px;
  }

  .nivel-turma-btn {
    font-size: 0.6875rem;
    padding: 6px 10px;
  }
}


/* ══════════════════════════════════
   RESPONSIVIDADE ADICIONAL — Níveis
══════════════════════════════════ */

@media (max-width: 768px) {
  /* Hero */
  .nivel-hero__titulo {
    font-size: clamp(1.75rem, 7vw, 2.5rem);
  }

  /* Intro — texto */
  .nivel-intro__p {
    font-size: 0.9rem;
  }

  .nivel-intro__subtitulo {
    font-size: 1rem;
  }

  /* Material — cards ocupam 50% */
  .nivel-material__grade {
    gap: 10px;
  }

  /* Horário — cabeçalho */
  .nivel-horario__cabecalho {
    gap: 10px;
    margin-bottom: 16px;
  }

  .nivel-horario__titulo {
    font-size: 1.1rem;
  }

  /* Turmas — wrap melhorado */
  .nivel-turmas {
    flex-wrap: wrap;
    gap: 8px;
  }

  /* Observações */
  .nivel-obs {
    padding: 16px;
  }

  .nivel-obs__lista {
    font-size: 0.85rem;
  }

  /* CTA */
  .nivel-cta__titulo {
    font-size: clamp(1.25rem, 5vw, 1.75rem);
  }

  /* Info bar */
  .nivel-info-bar__texto {
    font-size: 0.875rem;
    text-align: center;
  }
}

@media (max-width: 480px) {
  /* Material — botões em linha única */
  .nivel-material__card {
    width: calc(50% - 5px);
    padding: 14px 8px;
  }

  .nivel-material__nome {
    font-size: 0.8rem;
  }

  /* Horário hint */
  .nivel-turmas-hint {
    font-size: 0.82rem;
  }

  /* Blockquote */
  .nivel-blockquote {
    font-size: 0.875rem;
    padding: 12px 16px;
  }

  /* Calendário botão */
  .nivel-cal__btn {
    width: 100%;
    justify-content: center;
    padding: 10px 16px;
  }
}
