/* =========================
   Paleta Mercado Livre
========================= */
:root {
  --ml-yellow: #fff159;
  --ml-yellow-dark: #ffe600;
  --ml-blue: #3483fa;
  --ml-blue-dark: #2968c8;
  --ml-bg: #f5f5f5;
  --ml-text: #333;
  --ml-muted: #666;
  --ml-border: #ddd;
}

/* =========================
   Reset & Base
========================= */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: Arial, sans-serif;
  background: var(--ml-bg);
  color: var(--ml-text);
  line-height: 1.5;
}

/* transição suave com tema */
body,
.ml-container,
.ml-header,
.ml-footer,
input,
textarea,
select,
.ml-btn {
  transition: background-color 0.3s ease,
              color 0.3s ease,
              border-color 0.3s ease;
}

/* =========================
   Layout Main
========================= */

.layout-main {
  min-height: calc(100vh - 140px);
  padding: 20px 16px 30px;
}

/* tenta centralizar conteúdo “solto” */
.layout-main > h1,
.layout-main > h2,
.layout-main > .ml-container,
.layout-main > .ranking-container,
.layout-main > .ml-quiz-container,
.layout-main > .quiz-container,
.layout-main > .painel-container,
.layout-main > .ml-form-container {
  max-width: 1100px;
  margin-left: auto;
  margin-right: auto;
}

/* =========================
   Header & Navigation (estilo Mercado Livre)
========================= */


.ml-header-inner {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 18px;
  flex-wrap: nowrap;
}

/* LOGO BLOCO */
.ml-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--ml-text);
  margin-right: 16px;
  transition: transform 0.18s ease, opacity 0.18s ease;
}

.ml-logo:hover {
  transform: translateY(-1px);
  opacity: 0.95;
}

.ml-logo-mark {
  background: #fff;
  color: #222;
  padding: 6px 10px;
  border-radius: 10px;
  font-weight: 800;
  font-size: 14px;
  box-shadow: 0 2px 5px rgba(0,0,0,0.18);
}

.ml-logo-text {
  display: flex;
  flex-direction: column;
}

.ml-logo-title {
  font-size: 18px;
  font-weight: 700;
  line-height: 1.1;
}

.ml-logo-subtitle {
  font-size: 11px;
  opacity: 0.7;
}

/* NAV PRINCIPAL */
.ml-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
  flex: 1 1 auto;
}

.ml-link {
  text-decoration: none;
  font-weight: 600;
  color: #333;
  padding: 6px 10px;
  border-radius: 999px;
  font-size: 14px;
  transition: background 0.2s, color 0.2s, transform 0.15s;
  white-space: nowrap;
}

/* LADO DIREITO (usuário + botões) */
.ml-header-right {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

/* PILL DO USUÁRIO */
.ml-user-pill {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 4px 10px;
  border-radius: 999px;
  background: rgba(255,255,255,0.9);
  border: 1px solid rgba(0,0,0,0.05);
  font-size: 13px;
}

.ml-user-avatar {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 14px;
}

.ml-user-info {
  display: flex;
  flex-direction: column;
  line-height: 1.1;
}

.ml-user-name {
  font-weight: 600;
}

.ml-user-role {
  font-size: 11px;
  color: var(--ml-muted);
}

.ml-user-logout {
  margin-left: 4px;
  text-decoration: none;
  font-size: 18px;
}

/* BOTÕES DO TOPO (tema + menu) */
.ml-menu-toggle,
.ml-theme-toggle {
  background: #fff;
  border: 1px solid rgba(0,0,0,0.15);
  border-radius: 999px;
  padding: 6px 10px;
  font-size: 0.95rem;
  cursor: pointer;
  color: #333;
  transition: background 0.2s, color 0.2s, box-shadow 0.2s;
}

.ml-theme-toggle {
  min-width: 38px;
  text-align: center;
}

.ml-menu-toggle {
  display: none; /* só mostra em mobile */
}

.ml-menu-toggle:hover,
.ml-theme-toggle:hover {
  background: var(--ml-blue);
  color: #fff;
  box-shadow: 0 2px 8px rgba(0,0,0,0.18);
}

/* Mobile nav */
@media (max-width: 900px) {
  .ml-header-inner {
    flex-wrap: wrap;
    align-items: flex-start;
  }

  .ml-nav {
    display: none;
    flex-direction: column;
    width: 100%;
    margin-top: 10px;
    background: #fff;
    border-radius: 10px;
    padding: 8px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.06);
  }

  .ml-nav.show {
    display: flex;
  }

  .ml-link {
    width: 100%;
    text-align: left;
    padding: 8px 10px;
  }

  .ml-menu-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
  }

  .ml-user-pill {
    display: none; /* some no mobile pra não espremer tudo */
  }
}

/* =========================
   Banner (usado em algumas páginas)
========================= */

.ml-banner {
  background: linear-gradient(90deg, var(--ml-yellow) 0%, var(--ml-yellow-dark) 100%);
  padding: 60px 20px;
  text-align: center;
}

.ml-banner-content h1 {
  font-size: 32px;
  margin-bottom: 12px;
  color: var(--ml-text);
}

.ml-banner-content p {
  font-size: 18px;
  margin-bottom: 20px;
  color: var(--ml-muted);
}

/* =========================
   Containers & Titles
========================= */

.ml-container {
  max-width: 1100px;
  margin: 30px auto;
  padding: 20px;
  background: #fff;
  border-radius: 8px;
}

.ml-title {
  font-size: 24px;
  margin-bottom: 20px;
  text-align: center;
}

/* =========================
   Cards & Grid (genéricos)
========================= */

.ml-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 20px;
}

.ml-card {
  background: #fff;
  border: 1px solid var(--ml-border);
  border-radius: 6px;
  padding: 16px;
  text-align: center;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.ml-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 4px 10px rgba(0,0,0,0.08);
}

.ml-card-title {
  font-size: 18px;
  margin-bottom: 8px;
}

.ml-card-desc {
  font-size: 14px;
  color: var(--ml-muted);
  margin-bottom: 12px;
}

.ml-card.safety {
  background-color: #fff4e5;
  border-left: 6px solid #f57c00;
}

.ml-card.safety h3 {
  color: #d84315;
}

.ml-card.safety .ml-btn {
  background-color: #f57c00;
  color: #fff;
}

.ml-card.safety .ml-btn:hover {
  background-color: #e65100;
}

/* =========================
   Buttons
========================= */

.ml-btn {
  display: inline-block;
  padding: 10px 20px;
  border-radius: 6px;
  border: none;
  cursor: pointer;
  text-decoration: none;
  font-weight: bold;
  transition: background 0.2s ease, opacity 0.2s ease, color 0.2s ease;
  background: var(--ml-yellow);
  color: var(--ml-text);
}

.ml-btn:hover {
  opacity: 0.95;
}

.ml-btn.primary {
  background: var(--ml-blue);
  color: #fff;
}

.ml-btn.primary:hover {
  background: var(--ml-blue-dark);
}

.ml-btn.danger {
  background-color: #e74c3c;
  color: #fff;
}

.ml-btn.info {
  background-color: #3498db;
  color: #fff;
}

.ml-btn.success {
  background-color: #2ecc71;
  color: #fff;
}

/* =========================
   Actions
========================= */

.ml-actions {
  margin-top: 20px;
  text-align: center;
}

.ml-actions .ml-btn {
  margin: 5px;
}

/* =========================
   Tables
========================= */

.ml-table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 20px;
}

.ml-table th,
.ml-table td {
  border: 1px solid var(--ml-border);
  padding: 10px;
  text-align: center;
}

.ml-table th {
  background: var(--ml-yellow);
  color: var(--ml-text);
}

.ml-table tr:nth-child(even) {
  background: #f9f9f9;
}

.ml-table tr:hover {
  background: #f1f1f1;
}

/* Podium styles dentro de tabelas de ranking (alternativo) */
.podium {
  font-weight: bold;
  font-size: 1.1em;
}

.gold {
  background: #ffd70033;
}

.silver {
  background: #c0c0c033;
}

.bronze {
  background: #cd7f3233;
}

/* Tabelas textuais de correção (avaliações escritas) */

table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 20px;
  background-color: #f9fcff;
  border: 2px solid #0077cc;
}

th,
td {
  padding: 12px;
  border: 1px solid #ccc;
  vertical-align: top;
  text-align: left;
}

th {
  background-color: #e6f2ff;
  color: #003366;
}

td.correta {
  background-color: #e0ffe0;
  color: green;
  font-weight: bold;
}

td.parcial {
  background-color: #fff8dc;
  color: orange;
  font-weight: bold;
}

td.incorreta {
  background-color: #ffe0e0;
  color: red;
  font-weight: bold;
}

/* Filtros de tabela */

.painel-filtros {
  display: flex;
  gap: 20px;
  margin-bottom: 20px;
  align-items: center;
  flex-wrap: wrap;
}

.painel-filtros label {
  font-weight: bold;
}

.painel-filtros input,
.painel-filtros select {
  padding: 6px 10px;
  border-radius: 4px;
  border: 1px solid #ccc;
}

/* Efeitos em linhas */

tr {
  transition: all 0.3s ease;
}

tr.oculto {
  opacity: 0;
  transform: scaleY(0);
  height: 0;
  overflow: hidden;
  pointer-events: none;
}
/* =========================
   Quiz blocks
========================= */

.ml-quiz-container {
  max-width: 600px;
  margin: 4rem auto;
  padding: 2rem;
  background-color: #fff;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.ml-quiz-form {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.ml-quiz-question p {
  font-size: 1.2rem;
  margin: 0;
}

.ml-quiz-options {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.ml-quiz-option {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 1rem;
}

.ml-quiz-option input[type="radio"] {
  accent-color: #007bff;
}

.ml-quiz-actions {
  text-align: right;
}

.ml-info {
  text-align: center;
  font-style: italic;
  color: #666;
}

/* Quiz (nova versão) */

.quiz-container {
  max-width: 800px;
  margin: 4rem auto;
  padding: 2rem;
  background-color: #fff;
  border-radius: 12px;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.1);
}

.quiz-title {
  text-align: center;
  font-size: 2rem;
  margin-bottom: 2rem;
  color: #333;
}

.quiz-question {
  border: 1px solid #ddd;
  border-radius: 8px;
  padding: 1.5rem;
  margin-bottom: 1.5rem;
  background-color: #f9f9f9;
}

.quiz-question legend {
  font-weight: bold;
  font-size: 1.1rem;
  margin-bottom: 1rem;
}

.quiz-option {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin: 0.5rem 0;
  font-size: 1rem;
  cursor: pointer;
  padding: 0.4rem 0.6rem;
  border-radius: 6px;
  transition: background 0.2s;
}

.quiz-option:hover {
  background-color: #eef2ff;
}

.quiz-actions {
  text-align: center;
  margin-top: 2rem;
}

.quiz-btn {
  background-color: #007bff;
  color: #fff;
  font-size: 1rem;
  padding: 0.75rem 1.5rem;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  transition: background 0.3s;
}

.quiz-btn:hover {
  background-color: #0056b3;
}

.quiz-result {
  margin-top: 2rem;
  text-align: center;
  font-size: 1.2rem;
  font-weight: bold;
  color: #333;
}

/* Correção visual */

.correct {
  background-color: #d4edda !important;
  border-left: 4px solid #28a745;
}

.wrong {
  background-color: #f8d7da !important;
  border-left: 4px solid #dc3545;
}

/* Versão ML das alternativas */

.ml-question {
  font-size: 16px;
  margin-bottom: 20px;
  padding: 10px;
  border: 1px solid var(--ml-border);
  border-radius: 6px;
  background: #fff;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.ml-question:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

.ml-option {
  display: block;
  margin-bottom: 8px;
  font-size: 14px;
}

.ml-option.correct {
  background-color: #e8f5e9;
  border-left: 4px solid #4caf50;
  padding: 8px;
  border-radius: 4px;
  font-weight: bold;
  color: #2e7d32;
}

.ml-option.wrong {
  background-color: #ffebee;
  border-left: 4px solid #f44336;
  padding: 8px;
  border-radius: 4px;
  font-weight: bold;
  color: #c62828;
}

/* Questões escritas */

.quiz-written-section {
  margin-top: 40px;
  padding: 20px;
  background-color: #f9f9f9;
  border: 1px solid #ddd;
  border-radius: 8px;
}

.quiz-subtitle {
  font-size: 1.2em;
  font-weight: bold;
  margin-bottom: 20px;
  color: #333;
}

.quiz-written {
  margin-bottom: 25px;
}

.quiz-written label {
  display: block;
  margin-bottom: 8px;
  font-weight: 500;
  color: #222;
}

.quiz-written textarea {
  width: 100%;
  padding: 12px;
  font-size: 1em;
  border: 1px solid #ccc;
  border-radius: 6px;
  resize: vertical;
  background-color: #fff;
  box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.05);
}

.quiz-written textarea:focus {
  border-color: #0077cc;
  outline: none;
  box-shadow: 0 0 0 2px rgba(0, 119, 204, 0.2);
}

/* =========================
   Ranking Layout
========================= */

.ranking-container {
  max-width: 800px;
  margin: 40px auto;
  padding: 20px;
  background: #fff;
  border-radius: 10px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.08);
}

.ranking-title {
  text-align: center;
  font-size: 28px;
  margin-bottom: 20px;
  color: var(--ml-blue-dark);
}

.ranking-table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 10px;
}

.ranking-table th,
.ranking-table td {
  padding: 12px;
  border: 1px solid var(--ml-border);
  text-align: center;
}

.ranking-table th {
  background: var(--ml-yellow);
  color: var(--ml-text);
  font-size: 16px;
}

.ranking-table tr:nth-child(even) {
  background: #f9f9f9;
}

.ranking-table tr:hover {
  background: #eef6ff;
}

/* Destaque para top 3 */

.ranking-table tr.gold td {
  background: #fff8dc;
  font-weight: bold;
  color: #b8860b;
}

.ranking-table tr.silver td {
  background: #f0f0f0;
  font-weight: bold;
  color: #555;
}

.ranking-table tr.bronze td {
  background: #fff0e0;
  font-weight: bold;
  color: #8b4513;
}

/* =========================
   Página de erro
========================= */

.error-icon {
  font-size: 4rem;
  color: #e74c3c;
  margin-bottom: 20px;
}

.error-title {
  color: #e74c3c;
  font-size: 2rem;
  margin-bottom: 15px;
}

.error-message {
  font-size: 1.2rem;
  margin-bottom: 30px;
  color: var(--ml-muted);
}

/* =========================
   Alert / Toast simples
========================= */

.ml-alert {
  background: #ffeeba;
  color: #856404;
  padding: 12px 16px;
  border: 1px solid #ffeeba;
  border-radius: 4px;
  margin: 15px;
  font-size: 14px;
  font-weight: 500;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.ml-alert-close {
  background: none;
  border: none;
  font-size: 20px;
  color: #856404;
  cursor: pointer;
  padding: 0 8px;
}

/* =========================
   Destaque Home (slider)
========================= */

.ml-destaque {
  position: relative;
  overflow: hidden;
  max-width: 700px;
  margin: 30px auto;
  background-color: #fff3cd;
  border-left: 6px solid #ffc107;
  border-radius: 8px;
  padding: 20px;
  color: #856404;
  box-sizing: border-box;
}

.ml-destaque-wrapper {
  display: flex;
  width: 100%;
  transition: transform 0.5s ease;
  will-change: transform;
}

.ml-destaque-slide {
  flex: 0 0 100%;
  box-sizing: border-box;
  padding-right: 20px;
  opacity: 0;
  transition: opacity 0.4s ease;
}

.ml-destaque-slide.active {
  opacity: 1;
}

.ml-destaque-dots {
  text-align: center;
  margin-top: 15px;
}

.ml-destaque-dots .dot {
  display: inline-block;
  width: 12px;
  height: 12px;
  margin: 0 6px;
  background-color: #ffc107;
  border-radius: 50%;
  opacity: 0.4;
  cursor: pointer;
  transition: opacity 0.3s ease, transform 0.3s ease;
}

.ml-destaque-dots .dot.active {
  opacity: 1;
  transform: scale(1.2);
}

/* =========================
   Menu dropdown usuário
========================= */

.menu-container {
  position: relative;
  display: inline-block;
}

.menu-btn {
  background: none;
  border: none;
  font-size: 20px;
  cursor: pointer;
}

.menu-opcoes {
  display: block;
  position: absolute;
  right: 0;
  background: #fff;
  border: 1px solid #ddd;
  padding: 8px;
  box-shadow: 0 2px 6px rgba(0,0,0,0.15);
  z-index: 10;
  min-width: 180px;
  opacity: 0;
  transform: translateY(-10px);
  pointer-events: none;
  transition: opacity 0.25s ease, transform 0.25s ease;
}

.menu-opcoes form {
  margin: 4px 0;
}

.menu-container.show .menu-opcoes {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}

.menu-divider {
  border: none;
  border-top: 1px solid #ddd;
  margin: 8px 0;
}

/* Mobile menu-opcoes (modalzinho) */

@media (max-width: 600px) {
  .ml-table {
    display: block;
    overflow-x: auto;
    white-space: nowrap;
  }

  .menu-opcoes {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    min-width: 260px;
    width: 80%;
    border-radius: 8px;
    padding: 16px;
  }

  .menu-opcoes::before {
    content: "⚙️ Ações do usuário";
    display: block;
    font-weight: bold;
    margin-bottom: 10px;
    text-align: center;
  }

  .menu-opcoes form {
    margin: 10px 0;
  }
}

/* =========================
   Painel Administrativo
========================= */

.painel-container {
  max-width: 960px;
  margin: 0 auto;
  padding: 2rem;
  background-color: #fff;
  border-radius: 8px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.05);
}

.painel-container h2.ml-title {
  font-size: 2rem;
  color: var(--ml-blue-dark);
  margin-bottom: 1.5rem;
  text-align: center;
}

.painel-header {
  background-color: #f0f4ff;
  padding: 1em;
  border-bottom: 2px solid #ccc;
  text-align: center;
}

.user-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  gap: 1em;
}

.user-card {
  background-color: #fff;
  border: 1px solid #ddd;
  padding: 1em;
  border-radius: 8px;
  box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}

.user-card.admin {
  border-left: 5px solid #007bff;
}

.user-actions form {
  margin-top: 0.5em;
}

.painel-massa {
  margin-top: 40px;
  padding: 20px;
  border-top: 2px dashed #ccc;
}

.painel-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  justify-content: space-between;
}

/* pódio */

.ml-podio {
  display: flex;
  justify-content: center;
  align-items: flex-end;
  gap: 2em;
  margin: 2em 0;
}

.ml-podio-item {
  text-align: center;
  padding: 1em;
  border-radius: 8px;
  background-color: #f0f4ff;
  box-shadow: 0 2px 6px rgba(0,0,0,0.1);
  width: 120px;
}

.ml-podio-item.primeiro {
  background-color: #ffeaa7;
  transform: scale(1.1);
}

.ml-podio-item.segundo {
  background-color: #dfe6e9;
}

.ml-podio-item.terceiro {
  background-color: #fab1a0;
}

.ml-podio-posicao {
  font-size: 2em;
}

.ml-podio-nome {
  font-weight: bold;
  margin-top: 0.5em;
}

.ml-podio-pontos {
  font-size: 1.2em;
  margin-top: 0.25em;
}

/* =========================
   Responsividade geral
========================= */

@media (max-width: 1024px) {
  .ml-container {
    margin: 20px;
    padding: 15px;
  }

  .ml-title {
    font-size: 22px;
  }

  .ml-banner-content h1 {
    font-size: 28px;
  }

  .ml-banner-content p {
    font-size: 16px;
  }

  .ml-grid {
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  }

  .ml-form-container {
    margin: 20px auto;
    padding: 20px;
  }
}

@media (max-width: 768px) {
  .ml-banner {
    padding: 40px 15px;
  }

  .ml-banner-content h1 {
    font-size: 24px;
  }

  .ml-banner-content p {
    font-size: 15px;
  }

  .ml-btn,
  .ml-form-actions .ml-btn {
    width: 100%;
    text-align: center;
  }

  .ml-table th,
  .ml-table td {
    font-size: 13px;
    padding: 8px;
  }

  .quiz-container {
    padding: 10px;
  }
}

@media (max-width: 480px) {
  .ml-title {
    font-size: 20px;
  }

  .ml-banner-content h1 {
    font-size: 20px;
  }

  .ml-banner-content p {
    font-size: 14px;
  }

  .ml-card-title {
    font-size: 16px;
  }

  .ml-card-desc {
    font-size: 13px;
  }

  .ml-btn {
    font-size: 14px;
    padding: 8px 16px;
  }

  .ml-form-container {
    padding: 15px;
  }

  .ml-form-container h2 {
    font-size: 20px;
  }

  .ml-form-group input {
    font-size: 13px;
    padding: 8px;
  }

  .ml-footer {
    font-size: 13px;
    padding: 10px;
  }
}
/* =========================
   ML + LAB ANIMADO LOOP 🧪⚡
========================= */

/* ===== HEADER GRADIENTE ANIMADO ===== */
.ml-header {
  background: linear-gradient(
    270deg,
    #ffe600,
    #fff159,
    #ffffff,
    #fff159,
    #ffe600
  );
  background-size: 500% 500%;
  animation: headerFlow 12s ease infinite;
  position: relative;
  overflow: hidden;
}

@keyframes headerFlow {
  0% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}

/* ===== LINHA AZUL ANIMADA EMBAIXO ===== */
.ml-header::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: -50%;
  width: 50%;
  height: 3px;
  background: linear-gradient(90deg, transparent, #3483fa, transparent);
  animation: lineMove 4s linear infinite;
}

@keyframes lineMove {
  0% { left: -50%; }
  100% { left: 100%; }
}

/* ===== LINKS MAIS FLUIDOS ===== */
.ml-link {
  transition: all 0.3s ease;
}

.ml-link:hover {
  background: #3483fa;
  color: #fff;
  transform: translateY(-3px);
  box-shadow: 0 6px 18px rgba(52,131,250,0.35);
}

/* ===== AVATAR COM PULSO SUAVE ===== */
.ml-user-avatar {
  background: linear-gradient(135deg, #3483fa, #2968c8);
  animation: avatarPulse 3s ease-in-out infinite;
}

@keyframes avatarPulse {
  0% { box-shadow: 0 0 8px rgba(52,131,250,0.4); }
  50% { box-shadow: 0 0 18px rgba(52,131,250,0.8); }
  100% { box-shadow: 0 0 8px rgba(52,131,250,0.4); }
}

/* ===== FUNDO COM MOVIMENTO SUTIL ===== */
body {
  background: linear-gradient(
    135deg,
    #f5f7fb,
    #eef2ff,
    #f5f7fb
  );
  background-size: 300% 300%;
  animation: bgMove 20s ease infinite;
}

@keyframes bgMove {
  0% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}
/* =========================
   NOVO VISUAL ML + LAB 🧪
========================= */

/* Fundo geral com textura sutil */
body {
  background:
    radial-gradient(circle at 20% 20%, rgba(52,131,250,0.06) 0%, transparent 40%),
    radial-gradient(circle at 80% 80%, rgba(255,230,0,0.08) 0%, transparent 40%),
    #f5f7fb;
}

/* Header mais vibrante */
.ml-header {
  background: linear-gradient(
    90deg,
    #ffe600 0%,
    #fff159 40%,
    #ffffff 100%
  );
  padding: 14px 28px;
  box-shadow: 0 6px 20px rgba(0,0,0,0.12);
}

/* Logo mais forte */
.ml-logo-title {
  font-size: 20px;
  font-weight: 800;
  letter-spacing: 0.6px;
  color: #0f172a;
}

/* Links estilo moderno */
.ml-link {
  padding: 8px 14px;
  border-radius: 12px;
  font-weight: 600;
  transition: all 0.25s ease;
}

/* ===== HOVER MAIS SUAVE ===== */

.ml-link:hover {
  background: rgba(0, 0, 0, 0.08);
  color: #222;
  box-shadow: none;
  transform: translateY(-2px);
}


/* Link ativo (se quiser usar depois) */
.ml-link.active {
  background: #2968c8;
  color: #fff;
}

/* Avatar estilo tech */
.ml-user-avatar {
  background: linear-gradient(135deg, #3483fa, #2968c8);
  box-shadow: 0 0 12px rgba(52,131,250,0.5);
}

/* Containers mais modernos */
.ml-container,
.ranking-container,
.painel-container,
.quiz-container {
  border-radius: 16px;
  box-shadow: 0 10px 30px rgba(0,0,0,0.06);
  border: 1px solid rgba(52,131,250,0.08);
}

/* Cards mais vivos */
.ml-card {
  border-radius: 14px;
  border: 1px solid rgba(0,0,0,0.05);
  transition: all 0.3s ease;
}

.ml-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 12px 25px rgba(0,0,0,0.1);
}

/* Botão primário mais impactante */
.ml-btn.primary {
  background: linear-gradient(135deg, #3483fa, #2968c8);
  box-shadow: 0 6px 14px rgba(52,131,250,0.4);
}

.ml-btn.primary:hover {
  transform: translateY(-2px);
}
/* =========================
   CAMINHOS COM ENERGIA ⚡🔥
========================= */

.ml-link {
  position: relative;
  padding: 8px 16px;
  border-radius: 14px;
  color: #222;
  font-weight: 600;
  z-index: 1;
  overflow: hidden;
  transition: all 0.3s ease;
}

/* BORDA ANIMADA */
.ml-link::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 14px;
  padding: 2px;
  background: linear-gradient(
    270deg,
    #3483fa,
    #ffe600,
    #3483fa,
    #2968c8
  );
  background-size: 400% 400%;
  animation: borderEnergy 6s linear infinite;
  -webkit-mask:
    linear-gradient(#000 0 0) content-box,
    linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
          mask-composite: exclude;
  z-index: -1;
}

/* Movimento do gradiente */
@keyframes borderEnergy {
  0% { background-position: 0% 50%; }
  100% { background-position: 400% 50%; }
}

/* Hover poderoso */
.ml-link:hover {
  color: #fff;
  background: linear-gradient(135deg, #3483fa, #2968c8);
  box-shadow: 0 0 20px rgba(52,131,250,0.6);
  transform: translateY(-3px) scale(1.05);
}
/* =========================
   MENU MAIS ORGANIZADO
========================= */

/* Permite quebra controlada */
.ml-nav {
  flex-wrap: wrap;
  row-gap: 8px;     /* espaço vertical pequeno */
  column-gap: 10px; /* espaço horizontal */
  align-items: center;
}

/* Reduz altura geral do header */
.ml-header {
  padding: 10px 24px;
}

/* Diminui um pouco os botões */
.ml-link {
  padding: 5px 12px;
  font-size: 13.5px;
  border-radius: 12px;
}

/* Impede que o texto quebre dentro do botão */
.ml-link {
  white-space: nowrap;
}

/* Controla altura máxima do header */
.ml-header-inner {
  align-items: center;
  gap: 14px;
}
