:root {
  --bg-primary: #0f172a;
  --bg-secondary: #1e293b;
  --bg-card: #1e293b;
  --bg-card-hover: #273548;
  --text-main: #f8fafc;
  --text-muted: #94a3b8;
  --accent-cyan: #06b6d4;
  --accent-indigo: #6366f1;
  --accent-emerald: #10b981;
  --accent-amber: #f59e0b;
  --accent-rose: #f43f5e;
  --border-color: #334155;
  --radius-lg: 16px;
  --radius-md: 10px;
  --shadow-card: 0 10px 25px -5px rgba(0, 0, 0, 0.4), 0 8px 10px -6px rgba(0, 0, 0, 0.3);
  --transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

[data-theme="light"] {
  --bg-primary: #f1f5f9;
  --bg-secondary: #ffffff;
  --bg-card: #ffffff;
  --bg-card-hover: #f8fafc;
  --text-main: #0f172a;
  --text-muted: #64748b;
  --border-color: #e2e8f0;
  --shadow-card: 0 10px 25px -5px rgba(0, 0, 0, 0.08), 0 8px 10px -6px rgba(0, 0, 0, 0.04);
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

body {
  background-color: var(--bg-primary);
  color: var(--text-main);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  transition: var(--transition);
  line-height: 1.6;
}

/* Header & HUD */
.app-header {
  background-color: var(--bg-secondary);
  border-bottom: 1px solid var(--border-color);
  padding: 0.85rem 1.5rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  position: sticky;
  top: 0;
  z-index: 50;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
  flex-wrap: wrap;
  gap: 0.75rem;
}

.logo-container {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.logo-badge {
  background: linear-gradient(135deg, #6366f1, #06b6d4);
  color: white;
  font-weight: 800;
  font-size: 1.2rem;
  padding: 0.4rem 0.8rem;
  border-radius: var(--radius-md);
  box-shadow: 0 0 15px rgba(6, 182, 212, 0.4);
}

.logo-text h1 {
  font-size: 1.25rem;
  font-weight: 700;
  letter-spacing: -0.5px;
}

.logo-text p {
  font-size: 0.75rem;
  color: var(--text-muted);
}

/* HUD de Gamificação */
.hud-container {
  display: flex;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
}

.streak-pill {
  background: rgba(245, 158, 11, 0.15);
  border: 1px solid rgba(245, 158, 11, 0.4);
  color: #fbbf24;
  padding: 0.35rem 0.75rem;
  border-radius: 9999px;
  font-weight: 700;
  font-size: 0.85rem;
  display: flex;
  align-items: center;
  gap: 0.35rem;
}

.level-badge {
  background: linear-gradient(135deg, #8b5cf6, #ec4899);
  color: white;
  padding: 0.35rem 0.75rem;
  border-radius: var(--radius-md);
  font-size: 0.85rem;
  font-weight: 700;
  box-shadow: 0 2px 8px rgba(236, 72, 153, 0.3);
}

.xp-bar-container {
  display: flex;
  flex-direction: column;
  width: 130px;
}

.xp-bar-text {
  font-size: 0.7rem;
  color: var(--text-muted);
  display: flex;
  justify-content: space-between;
}

.xp-bar-bg {
  background: rgba(255, 255, 255, 0.1);
  height: 6px;
  border-radius: 9999px;
  overflow: hidden;
  margin-top: 2px;
}

.xp-bar-fill {
  background: linear-gradient(90deg, #06b6d4, #10b981);
  height: 100%;
  width: 0%;
  transition: width 0.4s ease;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.theme-toggle-btn {
  background: transparent;
  border: 1px solid var(--border-color);
  color: var(--text-main);
  padding: 0.45rem 0.75rem;
  border-radius: var(--radius-md);
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.85rem;
  transition: var(--transition);
}

.theme-toggle-btn:hover {
  background: var(--bg-card-hover);
  border-color: var(--accent-cyan);
}

/* Nav Tabs */
.nav-bar {
  background: var(--bg-secondary);
  border-bottom: 1px solid var(--border-color);
  display: flex;
  overflow-x: auto;
  padding: 0 1.5rem;
  gap: 0.5rem;
}

.nav-tab {
  background: none;
  border: none;
  color: var(--text-muted);
  padding: 0.85rem 1.25rem;
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  border-bottom: 3px solid transparent;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  white-space: nowrap;
  transition: var(--transition);
}

.nav-tab:hover {
  color: var(--text-main);
}

.nav-tab.active {
  color: var(--accent-cyan);
  border-bottom-color: var(--accent-cyan);
}

/* Main Container */
.main-content {
  flex: 1;
  max-width: 1200px;
  width: 100%;
  margin: 0 auto;
  padding: 1.5rem;
}

/* Views */
.view-panel {
  display: none;
  animation: fadeIn 0.3s ease-in-out;
}

.view-panel.active {
  display: block;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(6px); }
  to { opacity: 1; transform: translateY(0); }
}

/* Card Styling */
.card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  box-shadow: var(--shadow-card);
  margin-bottom: 1.5rem;
  transition: var(--transition);
}

.card:hover {
  border-color: rgba(99, 102, 241, 0.4);
}

/* Badges */
.badge {
  display: inline-flex;
  align-items: center;
  padding: 0.25rem 0.65rem;
  border-radius: 9999px;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.badge-linguagens { background: rgba(59, 130, 246, 0.15); color: #60a5fa; border: 1px solid rgba(59, 130, 246, 0.3); }
.badge-humanas { background: rgba(245, 158, 11, 0.15); color: #fbbf24; border: 1px solid rgba(245, 158, 11, 0.3); }
.badge-natureza { background: rgba(16, 185, 129, 0.15); color: #34d399; border: 1px solid rgba(16, 185, 129, 0.3); }
.badge-matematica { background: rgba(139, 92, 246, 0.15); color: #a78bfa; border: 1px solid rgba(139, 92, 246, 0.3); }

/* Buttons */
.btn-primary {
  background: linear-gradient(135deg, var(--accent-indigo), var(--accent-cyan));
  color: white;
  border: none;
  padding: 0.75rem 1.5rem;
  border-radius: var(--radius-md);
  font-weight: 600;
  font-size: 0.95rem;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  box-shadow: 0 4px 15px rgba(6, 182, 212, 0.3);
  transition: var(--transition);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(6, 182, 212, 0.45);
}

.btn-secondary {
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  color: var(--text-main);
  padding: 0.65rem 1.15rem;
  border-radius: var(--radius-md);
  font-weight: 600;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.9rem;
  transition: var(--transition);
}

.btn-secondary:hover {
  background: var(--bg-card-hover);
  border-color: var(--accent-cyan);
}

.btn-secondary.active {
  background: rgba(6, 182, 212, 0.15);
  border-color: var(--accent-cyan);
  color: var(--accent-cyan);
}

.btn-danger {
  background: rgba(244, 63, 94, 0.15);
  border: 1px solid rgba(244, 63, 94, 0.4);
  color: #fb7185;
  padding: 0.65rem 1.15rem;
  border-radius: var(--radius-md);
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition);
}

.btn-danger:hover {
  background: #f43f5e;
  color: white;
}

/* Question Layout */
.question-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1rem;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid var(--border-color);
}

.question-text-box {
  background: rgba(0, 0, 0, 0.15);
  border-left: 4px solid var(--accent-cyan);
  padding: 1rem 1.25rem;
  border-radius: 0 var(--radius-md) var(--radius-md) 0;
  margin-bottom: 1.25rem;
  font-style: italic;
  white-space: pre-line;
  line-height: 1.7;
}

.question-prompt {
  font-weight: 600;
  font-size: 1.05rem;
  margin-bottom: 1.5rem;
}

/* Options */
.options-list {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  margin-bottom: 1.5rem;
}

.option-item {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  padding: 1rem;
  border: 1px solid var(--border-color);
  background: var(--bg-secondary);
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: var(--transition);
}

.option-item:hover {
  background: var(--bg-card-hover);
  border-color: var(--accent-indigo);
}

.option-letter {
  background: var(--bg-primary);
  border: 1px solid var(--border-color);
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.85rem;
  flex-shrink: 0;
}

.option-item.selected {
  border-color: var(--accent-cyan);
  background: rgba(6, 182, 212, 0.08);
}

.option-item.selected .option-letter {
  background: var(--accent-cyan);
  color: black;
  border-color: var(--accent-cyan);
}

.option-item.correct {
  border-color: var(--accent-emerald) !important;
  background: rgba(16, 185, 129, 0.1) !important;
}

.option-item.correct .option-letter {
  background: var(--accent-emerald) !important;
  color: white !important;
}

.option-item.wrong {
  border-color: var(--accent-rose) !important;
  background: rgba(244, 63, 94, 0.1) !important;
}

.option-item.wrong .option-letter {
  background: var(--accent-rose) !important;
  color: white !important;
}

/* Question Explanation Box */
.explanation-box {
  background: rgba(16, 185, 129, 0.08);
  border: 1px solid var(--accent-emerald);
  border-left: 5px solid var(--accent-emerald);
  border-radius: var(--radius-md);
  padding: 1.25rem;
  margin-top: 1.25rem;
  white-space: pre-line;
  line-height: 1.75;
  font-size: 0.95rem;
  color: var(--text-main);
  box-shadow: 0 4px 14px rgba(16, 185, 129, 0.07);
}

/* Gabarito Navigation Bar */
.gabarito-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(40px, 1fr));
  gap: 0.5rem;
  margin-top: 1rem;
}

.gabarito-bubble {
  height: 40px;
  border: 1px solid var(--border-color);
  background: var(--bg-secondary);
  color: var(--text-main);
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  cursor: pointer;
  transition: var(--transition);
}

.gabarito-bubble:hover {
  border-color: var(--accent-cyan);
}

.gabarito-bubble.active {
  box-shadow: 0 0 0 2px var(--accent-cyan);
}

.gabarito-bubble.answered {
  background: var(--accent-indigo);
  color: white;
  border-color: var(--accent-indigo);
}

.gabarito-bubble.reviewed {
  border: 2px dashed var(--accent-amber);
}

/* Flashcards 3D Flip */
.flashcard-wrapper {
  perspective: 1000px;
  width: 100%;
  max-width: 650px;
  height: 380px;
  margin: 1.5rem auto;
  cursor: pointer;
}

.flashcard-inner {
  position: relative;
  width: 100%;
  height: 100%;
  text-align: center;
  transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
  transform-style: preserve-3d;
}

.flashcard-inner.flipped {
  transform: rotateY(180deg);
}

.flashcard-front, .flashcard-back {
  position: absolute;
  width: 100%;
  height: 100%;
  -webkit-backface-visibility: hidden;
  backface-visibility: hidden;
  border-radius: var(--radius-lg);
  padding: 2rem;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  border: 2px solid var(--border-color);
  box-shadow: var(--shadow-card);
}

.flashcard-front {
  background: linear-gradient(145deg, var(--bg-secondary), #172133);
}

.flashcard-back {
  background: linear-gradient(145deg, #152238, var(--bg-secondary));
  transform: rotateY(180deg);
  border-color: var(--accent-cyan);
  text-align: left;
}

/* Redação Editor */
.redacao-textarea {
  width: 100%;
  height: 320px;
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 1.25rem;
  color: var(--text-main);
  font-size: 1rem;
  line-height: 1.8;
  resize: vertical;
  outline: none;
  transition: var(--transition);
}

.redacao-textarea:focus {
  border-color: var(--accent-cyan);
  box-shadow: 0 0 10px rgba(6, 182, 212, 0.25);
}

/* Repetições de Palavras */
.repeticao-tag {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  background: rgba(244, 63, 94, 0.15);
  border: 1px solid rgba(244, 63, 94, 0.4);
  color: #fb7185;
  padding: 0.25rem 0.55rem;
  border-radius: 9999px;
  font-size: 0.8rem;
  font-weight: 600;
}

/* Pomodoro Widget */
.pomodoro-box {
  background: radial-gradient(circle at center, #1e293b, #0f172a);
  border: 2px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 3rem 2rem;
  text-align: center;
  max-width: 500px;
  margin: 0 auto;
  box-shadow: var(--shadow-card);
}

.pomodoro-digits {
  font-size: 4.8rem;
  font-weight: 900;
  letter-spacing: 2px;
  font-variant-numeric: tabular-nums;
  color: var(--accent-cyan);
  margin: 1.5rem 0;
  text-shadow: 0 0 25px rgba(6, 182, 212, 0.4);
}

/* Conquistas (Trophies) */
.conquista-card {
  display: flex;
  align-items: center;
  gap: 1.25rem;
  padding: 1.25rem;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-color);
  background: var(--bg-secondary);
  transition: var(--transition);
}

.conquista-card.bloqueada {
  opacity: 0.45;
  filter: grayscale(1);
}

.conquista-icone {
  font-size: 2.2rem;
  width: 54px;
  height: 54px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.05);
}

/* Caderno de Erros */
.erro-item {
  border: 1px solid var(--border-color);
  background: var(--bg-secondary);
  border-radius: var(--radius-md);
  padding: 1.25rem;
  margin-bottom: 1rem;
  transition: var(--transition);
}

.erro-item.superada {
  border-color: var(--accent-emerald);
  background: rgba(16, 185, 129, 0.06);
}

/* Grid Utilities */
.grid-2 {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.25rem;
}

.grid-3 {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 1rem;
}

/* SiSU Inputs */
.input-field {
  width: 100%;
  padding: 0.75rem 1rem;
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  color: var(--text-main);
  font-size: 0.95rem;
  outline: none;
  transition: var(--transition);
}

.input-field:focus {
  border-color: var(--accent-indigo);
}

/* Stats Progress Bar */
.progress-bar-bg {
  background: rgba(255, 255, 255, 0.1);
  height: 12px;
  border-radius: 9999px;
  overflow: hidden;
  margin: 0.5rem 0;
}

.progress-bar-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--accent-indigo), var(--accent-cyan));
  border-radius: 9999px;
  transition: width 0.5s ease-out;
}

/* Footer */
.app-footer {
  text-align: center;
  padding: 1.5rem;
  color: var(--text-muted);
  font-size: 0.85rem;
  border-top: 1px solid var(--border-color);
  margin-top: auto;
}

/* ========================================================
   ESTILOS DE IMPRESSÃO (@media print) - PADRÃO INEP ENEM
   ======================================================== */
@media print {
  body {
    background: #ffffff !important;
    color: #000000 !important;
    font-size: 11pt;
  }

  .app-header, .nav-bar, .app-footer, .theme-toggle-btn, .btn-primary, .btn-secondary, .btn-danger, #simuladoTimer, .gabarito-grid {
    display: none !important;
  }

  .main-content {
    max-width: 100% !important;
    padding: 0 !important;
  }

  .card {
    border: none !important;
    box-shadow: none !important;
    padding: 0.5rem 0 !important;
    margin-bottom: 1.5rem !important;
    page-break-inside: avoid;
  }

  .question-text-box {
    background: #f4f4f4 !important;
    border-left: 3px solid #000 !important;
    color: #000 !important;
  }

  .option-item {
    border: 1px solid #ccc !important;
    background: #fff !important;
    color: #000 !important;
    margin-bottom: 0.25rem !important;
    padding: 0.5rem !important;
  }

  .option-letter {
    background: #eee !important;
    color: #000 !important;
    border: 1px solid #999 !important;
  }
}

/* ========================================== */
/* ACERVO DE PROVAS & GABARITOS INEP */
/* ========================================== */
.acervo-stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.acervo-stat-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 1.25rem;
  display: flex;
  align-items: center;
  gap: 1rem;
  box-shadow: var(--shadow-card);
}

.acervo-stat-icon {
  font-size: 2rem;
  width: 50px;
  height: 50px;
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(99, 102, 241, 0.15);
}

.acervo-stat-val {
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--text-main);
  line-height: 1.2;
}

.acervo-stat-lbl {
  font-size: 0.8rem;
  color: var(--text-muted);
}

.acervo-toolbar {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 1.25rem;
  margin-bottom: 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.acervo-search-input {
  width: 100%;
  padding: 0.85rem 1rem 0.85rem 2.75rem;
  background: var(--bg-primary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  color: var(--text-main);
  font-size: 0.95rem;
  outline: none;
  transition: var(--transition);
}

.acervo-search-input:focus {
  border-color: var(--accent-cyan);
  box-shadow: 0 0 0 3px rgba(6, 182, 212, 0.15);
}

.acervo-search-wrapper {
  position: relative;
  width: 100%;
}

.acervo-search-icon {
  position: absolute;
  left: 1rem;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-muted);
  font-size: 1rem;
}

.acervo-filters-row {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
  align-items: center;
}

.acervo-select {
  padding: 0.6rem 1rem;
  background: var(--bg-primary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  color: var(--text-main);
  font-size: 0.9rem;
  font-weight: 600;
  outline: none;
  cursor: pointer;
}

.acervo-card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 1rem;
}

.acervo-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 1.25rem;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  transition: var(--transition);
  position: relative;
  overflow: hidden;
}

.acervo-card:hover {
  transform: translateY(-3px);
  border-color: var(--accent-indigo);
  box-shadow: 0 12px 28px -6px rgba(0, 0, 0, 0.4);
}

.acervo-card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.75rem;
  flex-wrap: wrap;
  gap: 0.35rem;
}

.acervo-ano-badge {
  font-weight: 800;
  font-size: 0.95rem;
  color: var(--accent-cyan);
}

.acervo-badges {
  display: flex;
  gap: 0.35rem;
  flex-wrap: wrap;
}

.badge-caderno {
  font-size: 0.75rem;
  font-weight: 700;
  padding: 0.2rem 0.55rem;
  border-radius: 6px;
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
}

.badge-caderno-azul { background: #1e40af; color: #ffffff; }
.badge-caderno-amarelo { background: #d97706; color: #ffffff; }
.badge-caderno-branco { background: #f8fafc; color: #0f172a; border: 1px solid #cbd5e1; }
.badge-caderno-rosa { background: #db2777; color: #ffffff; }
.badge-caderno-cinza { background: #475569; color: #ffffff; }
.badge-caderno-laranja { background: #ea580c; color: #ffffff; }
.badge-caderno-verde { background: #059669; color: #ffffff; }
.badge-caderno-padrao { background: #334155; color: #e2e8f0; }

.badge-tipo-prova { background: rgba(6, 182, 212, 0.15); color: #22d3ee; }
.badge-tipo-gabarito { background: rgba(16, 185, 129, 0.15); color: #34d399; }
.badge-tipo-redacao { background: rgba(168, 85, 247, 0.15); color: #c084fc; }
.badge-cat-ppl { background: rgba(245, 158, 11, 0.15); color: #fbbf24; }
.badge-cat-acessivel { background: rgba(244, 63, 94, 0.15); color: #fb7185; }

.acervo-card-title {
  font-size: 1rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
  line-height: 1.4;
  color: var(--text-main);
}

.acervo-card-filename {
  font-size: 0.75rem;
  color: var(--text-muted);
  font-family: monospace;
  word-break: break-all;
  margin-bottom: 1rem;
}

.acervo-card-actions {
  display: flex;
  gap: 0.5rem;
  margin-top: auto;
}

.acervo-card-actions a,
.acervo-card-actions button {
  flex: 1;
  text-align: center;
  padding: 0.6rem 0.5rem;
  font-size: 0.85rem;
  font-weight: 600;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.35rem;
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: var(--transition);
}

.acervo-pagination {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 0.5rem;
  margin-top: 1.5rem;
  flex-wrap: wrap;
}

/* ========================================================
   RESPONSIVIDADE COMPLETA PARA CELULAR & TABLET
   ======================================================== */
@media (max-width: 768px) {
  /* Header em coluna compacta */
  .app-header {
    padding: 0.65rem 0.85rem;
    gap: 0.5rem;
  }

  .logo-container {
    gap: 0.5rem;
  }

  .logo-badge {
    font-size: 1rem;
    padding: 0.3rem 0.6rem;
  }

  .logo-text h1 {
    font-size: 1.1rem;
  }

  .logo-text p {
    display: none; /* Oculta slogan longo no mobile */
  }

  /* HUD adaptado para telas estreitas */
  .hud-container {
    width: 100%;
    order: 3;
    justify-content: space-between;
    gap: 0.4rem;
    padding-top: 0.25rem;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
  }

  .xp-bar-container {
    flex: 1;
    max-width: none;
  }

  .header-actions {
    margin-left: auto;
    gap: 0.4rem;
  }

  #usuarioHeaderBtn {
    font-size: 0.75rem;
    padding: 0.3rem 0.6rem;
  }

  #simuladoTimer {
    font-size: 0.85rem;
    padding: 0.3rem 0.55rem;
  }

  .theme-toggle-btn {
    padding: 0.35rem 0.55rem;
    font-size: 0.75rem;
  }

  /* Menu de Navegação Horizontal com Scroll Suave */
  .nav-bar {
    padding: 0 0.5rem;
    gap: 0.25rem;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none; /* Esconde scrollbar nativa feia */
  }

  .nav-bar::-webkit-scrollbar {
    display: none;
  }

  .nav-tab {
    padding: 0.65rem 0.75rem;
    font-size: 0.825rem;
  }

  /* Conteúdo Principal com aproveitamento total da tela */
  .main-content {
    padding: 0.75rem;
  }

  .card {
    padding: 1rem;
    border-radius: var(--radius-md);
    margin-bottom: 0.85rem;
  }

  /* Opções das Questões do Simulado fáceis de tocar no dedo */
  .option-item {
    padding: 0.75rem 0.85rem;
    font-size: 0.9rem;
    touch-action: manipulation;
  }

  .option-letter {
    min-width: 32px;
    height: 32px;
    font-size: 0.9rem;
  }

  /* Grids adaptam para 1 coluna */
  .acervo-stats-grid {
    grid-template-columns: 1fr 1fr;
    gap: 0.6rem;
  }

  .acervo-stat-card {
    padding: 0.85rem;
  }

  .acervo-stat-icon {
    font-size: 1.5rem;
    width: 38px;
    height: 38px;
  }

  .acervo-stat-val {
    font-size: 1.2rem;
  }

  .acervo-card-grid {
    grid-template-columns: 1fr;
  }

  .gabarito-grid {
    grid-template-columns: repeat(5, 1fr) !important;
    gap: 0.35rem !important;
  }

  /* Modal de Login no Mobile */
  .modal-overlay .card {
    margin: 0.75rem;
    padding: 1.25rem;
    max-height: 90vh;
    overflow-y: auto;
  }

  /* Flashcards touch */
  .flashcard-inner {
    min-height: 240px !important;
  }
}

/* ========================================================
   ESTILOS E ANIMAÇÕES: FLORESTA & MASCOTES
   ======================================================== */
@keyframes floatPet {
  0%, 100% {
    transform: translateY(0px) rotate(0deg);
  }
  50% {
    transform: translateY(-8px) rotate(2deg);
  }
}

@keyframes treeGrow {
  0% {
    transform: scale(0) rotate(-10deg);
    opacity: 0;
  }
  70% {
    transform: scale(1.15) rotate(3deg);
  }
  100% {
    transform: scale(1) rotate(0deg);
    opacity: 1;
  }
}

.tree-item {
  transition: transform 0.25s ease, filter 0.25s ease;
  user-select: none;
}

.tree-item:hover {
  transform: translateY(-5px) scale(1.1);
}

/* Toast Moderno de Notificação (Sem popup invasivo do navegador) */
#toastContainer {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  gap: 10px;
  pointer-events: none;
}

.toast-message {
  background: rgba(15, 23, 42, 0.95);
  color: #fff;
  border: 1px solid var(--border-color);
  padding: 0.85rem 1.25rem;
  border-radius: var(--radius-md);
  box-shadow: 0 10px 25px -5px rgba(0,0,0,0.5);
  font-size: 0.9rem;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  pointer-events: auto;
  animation: slideToastIn 0.3s cubic-bezier(0.16, 1, 0.3, 1) forwards;
  backdrop-filter: blur(8px);
}

.toast-message.success {
  border-color: #10b981;
  background: linear-gradient(135deg, rgba(16, 185, 129, 0.25), rgba(15, 23, 42, 0.95));
}

.toast-message.info {
  border-color: #38bdf8;
  background: linear-gradient(135deg, rgba(56, 189, 248, 0.25), rgba(15, 23, 42, 0.95));
}

@keyframes slideToastIn {
  from {
    transform: translateY(20px);
    opacity: 0;
  }
  to {
    transform: translateY(0);
    opacity: 1;
  }
}

@media (max-width: 768px) {
  #toastContainer {
    bottom: 16px;
    right: 16px;
    left: 16px;
  }
  .toast-message {
    width: 100%;
    font-size: 0.85rem;
  }
}

/* ========================================== */
/* ESTILOS: PLANO DE ESTUDO & METAS DIÁRIAS */
/* ========================================== */
.cronograma-top-grid {
  display: grid;
  grid-template-columns: 1.25fr 0.75fr;
  gap: 1.25rem;
}

@media (max-width: 900px) {
  .cronograma-top-grid {
    grid-template-columns: 1fr;
  }
}

.missao-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.85rem 1rem;
  background: rgba(15, 23, 42, 0.6);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  transition: all 0.2s ease;
  gap: 0.75rem;
}

.missao-card:hover {
  border-color: rgba(245, 158, 11, 0.4);
  background: rgba(15, 23, 42, 0.85);
  transform: translateY(-2px);
}

.missao-card.concluida {
  border-color: rgba(16, 185, 129, 0.4);
  background: rgba(16, 185, 129, 0.08);
}

.missao-card.concluida .missao-titulo {
  text-decoration: line-through;
  color: var(--text-muted);
}

.missao-checkbox-custom {
  width: 22px;
  height: 22px;
  border-radius: 6px;
  border: 2px solid var(--border-color);
  background: transparent;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
  flex-shrink: 0;
}

.missao-card.concluida .missao-checkbox-custom {
  background: #10b981;
  border-color: #10b981;
  color: white;
}

.crono-semana-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 0.75rem;
}

@media (max-width: 1024px) {
  .crono-semana-grid {
    display: flex;
    overflow-x: auto;
    padding-bottom: 0.75rem;
    scroll-snap-type: x mandatory;
  }
  .crono-dia-card {
    min-width: 160px;
    flex-shrink: 0;
    scroll-snap-align: start;
  }
}

.crono-dia-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 1rem 0.85rem;
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
  transition: all 0.25s ease;
  position: relative;
}

.crono-dia-card:hover {
  transform: translateY(-3px);
  border-color: rgba(245, 158, 11, 0.5);
  box-shadow: 0 8px 20px -6px rgba(0,0,0,0.4);
}

.crono-dia-card.hoje {
  border: 2px solid #f59e0b;
  background: linear-gradient(180deg, rgba(245, 158, 11, 0.12), var(--bg-card));
  box-shadow: 0 0 20px rgba(245, 158, 11, 0.25);
}

.crono-dia-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid var(--border-color);
  padding-bottom: 0.5rem;
}

.badge-hoje-pill {
  background: #f59e0b;
  color: #0f172a;
  font-size: 0.65rem;
  font-weight: 900;
  padding: 0.15rem 0.45rem;
  border-radius: 999px;
  letter-spacing: 0.5px;
  text-transform: uppercase;
}

.crono-materia-tag {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.78rem;
  padding: 0.35rem 0.55rem;
  border-radius: 6px;
  font-weight: 600;
  background: rgba(255, 255, 255, 0.04);
}

.crono-materia-tag.mat {
  background: rgba(244, 63, 94, 0.12);
  color: #fb7185;
  border-left: 3px solid #f43f5e;
}

.crono-materia-tag.nat {
  background: rgba(16, 185, 129, 0.12);
  color: #34d399;
  border-left: 3px solid #10b981;
}

.crono-materia-tag.hum {
  background: rgba(245, 158, 11, 0.12);
  color: #fbbf24;
  border-left: 3px solid #f59e0b;
}

.crono-materia-tag.lin {
  background: rgba(6, 182, 212, 0.12);
  color: #38bdf8;
  border-left: 3px solid #06b6d4;
}

.crono-materia-tag.red {
  background: rgba(168, 85, 247, 0.12);
  color: #c084fc;
  border-left: 3px solid #a855f7;
}

.crono-materia-tag.rev {
  background: rgba(234, 179, 8, 0.12);
  color: #fde047;
  border-left: 3px solid #eab308;
}

.crono-materia-tag.sim {
  background: rgba(99, 102, 241, 0.15);
  color: #818cf8;
  border-left: 3px solid #6366f1;
}

/* 80/20 Cards */
.topico-card-8020 {
  background: rgba(15, 23, 42, 0.5);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 1rem;
}

.topico-item-check {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-size: 0.825rem;
  padding: 0.4rem 0.5rem;
  border-radius: 6px;
  cursor: pointer;
  transition: background 0.15s ease;
}

.topico-item-check:hover {
  background: rgba(255, 255, 255, 0.05);
}

.topico-item-check input[type="checkbox"] {
  accent-color: #f59e0b;
  width: 16px;
  height: 16px;
  cursor: pointer;
}

/* ========================================================
   RAIO-X DAS ALTERNATIVAS (EXPLICAÇÃO PEDAGÓGICA A, B, C, D, E)
   ======================================================== */
.raio-x-container {
  margin-top: 1.25rem;
  background: rgba(15, 23, 42, 0.7);
  border: 1px solid rgba(56, 189, 248, 0.3);
  border-radius: var(--radius-lg);
  padding: 1.25rem;
}

.raio-x-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1rem;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  flex-wrap: wrap;
  gap: 0.5rem;
}

.raio-x-title {
  font-size: 1rem;
  font-weight: 800;
  color: #38bdf8;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.raio-x-grid {
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
}

.raio-x-card {
  border-radius: var(--radius-md);
  padding: 0.9rem 1rem;
  transition: all 0.2s ease;
  border: 1px solid transparent;
}

.raio-x-card.correta {
  background: rgba(16, 185, 129, 0.1);
  border-color: rgba(16, 185, 129, 0.45);
}

.raio-x-card.distrator {
  background: rgba(244, 63, 94, 0.06);
  border-color: rgba(244, 63, 94, 0.25);
}

.raio-x-card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  margin-bottom: 0.4rem;
  flex-wrap: wrap;
}

.raio-x-letter-badge {
  font-weight: 800;
  font-size: 0.85rem;
  padding: 0.2rem 0.55rem;
  border-radius: var(--radius-sm);
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
}

.raio-x-card.correta .raio-x-letter-badge {
  background: #10b981;
  color: #fff;
}

.raio-x-card.distrator .raio-x-letter-badge {
  background: rgba(244, 63, 94, 0.2);
  color: #fb7185;
  border: 1px solid rgba(244, 63, 94, 0.35);
}

.raio-x-original-text {
  font-size: 0.875rem;
  color: var(--text-muted);
  margin-bottom: 0.5rem;
  padding-left: 0.5rem;
  border-left: 2px solid rgba(255, 255, 255, 0.1);
  font-style: italic;
}

.raio-x-explicacao {
  font-size: 0.9rem;
  line-height: 1.55;
  color: var(--text-main);
  padding: 0.5rem 0.75rem;
  border-radius: var(--radius-sm);
  background: rgba(0, 0, 0, 0.25);
}

/* ========================================================
   MAPEAMENTO DE ERROS & HEATMAP PEDAGÓGICO
   ======================================================== */
.diagnostico-painel {
  background: linear-gradient(135deg, rgba(30, 41, 59, 0.9), rgba(15, 23, 42, 0.95));
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 1.25rem;
}

.diagnostico-metrics-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 0.85rem;
  margin-bottom: 1.25rem;
}

.diagnostico-metric-box {
  background: rgba(0, 0, 0, 0.25);
  border-radius: var(--radius-md);
  padding: 0.85rem 1rem;
  border: 1px solid var(--border-color);
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.diagnostico-metric-box.critico {
  border-color: rgba(244, 63, 94, 0.4);
  background: rgba(244, 63, 94, 0.08);
}

.diagnostico-metric-box.atencao {
  border-color: rgba(245, 158, 11, 0.4);
  background: rgba(245, 158, 11, 0.08);
}

.diagnostico-metric-box.dominado {
  border-color: rgba(16, 185, 129, 0.4);
  background: rgba(16, 185, 129, 0.08);
}

.diagnostico-subtema-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.75rem 1rem;
  border-radius: var(--radius-md);
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border-color);
  margin-bottom: 0.5rem;
  gap: 0.75rem;
  flex-wrap: wrap;
  transition: all 0.2s ease;
}

.diagnostico-subtema-card:hover {
  background: rgba(255, 255, 255, 0.06);
  transform: translateX(2px);
}

.diagnostico-subtema-card.critico {
  border-left: 4px solid #f43f5e;
}

.diagnostico-subtema-card.atencao {
  border-left: 4px solid #f59e0b;
}

.diagnostico-subtema-card.dominado {
  border-left: 4px solid #10b981;
}

/* ========================================================
   PIRÂMIDE TRI E COERÊNCIA PEDAGÓGICA
   ======================================================== */
.coerencia-card {
  background: linear-gradient(135deg, rgba(30, 41, 59, 0.95), rgba(15, 23, 42, 0.95));
  border-radius: var(--radius-lg);
  padding: 1.25rem;
  margin-bottom: 1.5rem;
  border: 1px solid rgba(56, 189, 248, 0.3);
  text-align: left;
}

.piramide-vis-bars {
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
  margin: 1rem 0;
}

.piramide-tier-row {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.piramide-tier-label {
  width: 140px;
  font-size: 0.85rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 0.35rem;
}

.piramide-tier-progress {
  flex: 1;
}

.badge-dificuldade {
  font-size: 0.75rem;
  font-weight: 800;
  padding: 0.2rem 0.55rem;
  border-radius: 9999px;
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
}

.badge-dificuldade.facil {
  background: rgba(16, 185, 129, 0.2);
  color: #34d399;
  border: 1px solid rgba(16, 185, 129, 0.4);
}

.badge-dificuldade.media {
  background: rgba(245, 158, 11, 0.2);
  color: #fbbf24;
  border: 1px solid rgba(245, 158, 11, 0.4);
}

.badge-dificuldade.dificil {
  background: rgba(244, 63, 94, 0.2);
  color: #fb7185;
  border: 1px solid rgba(244, 63, 94, 0.4);
}

.badge-inedita-enem {
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.25), rgba(236, 72, 153, 0.25));
  color: #f472b6;
  border: 1px solid rgba(236, 72, 153, 0.4);
  font-size: 0.75rem;
  font-weight: 800;
  padding: 0.2rem 0.55rem;
  border-radius: 9999px;
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
}

/* ==========================================
   ESTILOS DO TOUR DE APRESENTAÇÃO COM O MASCOTE
   ========================================== */
.mascote-tour-overlay {
  position: fixed;
  inset: 0;
  background: rgba(10, 15, 29, 0.85);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 10000;
  padding: 1rem;
  animation: fadeIn 0.25s ease-out;
}

.mascote-tour-card {
  position: relative;
  width: 100%;
  max-width: 520px;
  max-height: min(85vh, 600px);
  background: var(--bg-card);
  border: 1px solid rgba(52, 211, 153, 0.35);
  border-radius: var(--radius-lg);
  padding: 1.25rem 1.4rem;
  box-shadow: 0 25px 60px -10px rgba(0, 0, 0, 0.75), 0 0 35px rgba(52, 211, 153, 0.2);
  animation: scaleUp 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

@keyframes scaleUp {
  from {
    opacity: 0;
    transform: scale(0.92) translateY(10px);
  }
  to {
    opacity: 1;
    transform: scale(1) translateY(0);
  }
}

.mascote-tour-close {
  position: absolute;
  top: 0.85rem;
  right: 0.85rem;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid var(--border-color);
  color: var(--text-muted);
  width: 28px;
  height: 28px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 0.85rem;
  transition: all 0.2s ease;
  z-index: 5;
}

.mascote-tour-close:hover {
  background: rgba(244, 63, 94, 0.2);
  color: #fb7185;
  border-color: rgba(244, 63, 94, 0.4);
  transform: rotate(90deg);
}

.mascote-tour-header {
  display: flex;
  align-items: center;
  gap: 0.9rem;
  margin-bottom: 0.85rem;
  flex-shrink: 0;
  padding-right: 2rem;
}

.mascote-tour-avatar-container {
  position: relative;
  width: 52px;
  height: 52px;
  flex-shrink: 0;
}

.mascote-tour-avatar {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  background: linear-gradient(135deg, rgba(52, 211, 153, 0.2), rgba(6, 182, 212, 0.2));
  border: 2px solid #34d399;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2rem;
  box-shadow: 0 4px 12px rgba(52, 211, 153, 0.3);
  animation: mascoteFloat 3s ease-in-out infinite alternate;
}

@keyframes mascoteFloat {
  0% { transform: translateY(0px) rotate(-1deg); }
  100% { transform: translateY(-5px) rotate(2deg); }
}

.mascote-tour-avatar-pulse {
  position: absolute;
  inset: -5px;
  border-radius: 50%;
  border: 2px solid rgba(52, 211, 153, 0.4);
  animation: pingAura 2.2s cubic-bezier(0, 0, 0.2, 1) infinite;
  pointer-events: none;
}

@keyframes pingAura {
  75%, 100% {
    transform: scale(1.25);
    opacity: 0;
  }
}

.mascote-tour-identity {
  flex: 1;
  min-width: 0;
}

.mascote-tour-speech-bubble {
  position: relative;
  background: rgba(15, 23, 42, 0.7);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: var(--radius-md);
  padding: 0.95rem 1.15rem;
  margin-bottom: 0.85rem;
  flex: 1 1 auto;
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: rgba(52, 211, 153, 0.35) transparent;
}

.mascote-tour-speech-bubble::-webkit-scrollbar {
  width: 5px;
}
.mascote-tour-speech-bubble::-webkit-scrollbar-track {
  background: transparent;
}
.mascote-tour-speech-bubble::-webkit-scrollbar-thumb {
  background: rgba(52, 211, 153, 0.35);
  border-radius: 9999px;
}

.mascote-tour-speech-bubble::before {
  content: '';
  position: absolute;
  top: -7px;
  left: 26px;
  width: 12px;
  height: 12px;
  background: rgba(15, 23, 42, 0.7);
  border-left: 1px solid rgba(255, 255, 255, 0.1);
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  transform: rotate(45deg);
}

.mascote-tour-feature-box {
  background: rgba(255, 255, 255, 0.03);
  border: 1px dashed rgba(56, 189, 248, 0.35);
  border-radius: var(--radius-sm);
  padding: 0.65rem 0.85rem;
  margin-top: 0.6rem;
}

.mascote-tour-feature-item {
  display: flex;
  align-items: flex-start;
  gap: 0.6rem;
  padding: 0.3rem 0;
  font-size: 0.82rem;
  color: var(--text-muted);
  line-height: 1.4;
}

.mascote-tour-feature-item strong {
  color: var(--text-main);
}

.mascote-tour-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-top: 1px solid var(--border-color);
  padding-top: 0.85rem;
  gap: 0.75rem;
  flex-shrink: 0;
}

.mascote-tour-dots {
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.mascote-tour-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.2);
  cursor: pointer;
  transition: all 0.25s ease;
}

.mascote-tour-dot:hover {
  background: rgba(255, 255, 255, 0.45);
}

.mascote-tour-dot.active {
  width: 22px;
  border-radius: 9999px;
  background: linear-gradient(135deg, #10b981, #06b6d4);
  box-shadow: 0 0 10px rgba(16, 185, 129, 0.5);
}

/* ==========================================
   ESTILOS: HUB DA HOME & BARRA DE MODO FOCO
   ========================================== */

/* Barra de Navegação em Modo Foco */
.barra-modo-foco {
  background: var(--bg-secondary);
  border-bottom: 1px solid var(--border-color);
  padding: 0.65rem 1.5rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  position: sticky;
  top: 60px;
  z-index: 45;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
  gap: 1rem;
  flex-wrap: wrap;
}

.foco-esquerda {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  flex-wrap: wrap;
}

.btn-voltar-home {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid var(--border-color);
  color: var(--text-main);
  padding: 0.45rem 0.95rem;
  border-radius: var(--radius-md);
  font-size: 0.85rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-voltar-home:hover {
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.25), rgba(6, 182, 212, 0.25));
  border-color: var(--accent-cyan);
  color: #38bdf8;
  transform: translateX(-2px);
}

.foco-divisor {
  width: 1px;
  height: 22px;
  background: var(--border-color);
}

.foco-atividade-badge {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  flex-wrap: wrap;
}

.foco-icone {
  font-size: 1.25rem;
}

.foco-nome {
  font-size: 0.95rem;
  font-weight: 800;
  color: var(--text-main);
}

.badge-foco-tag {
  background: rgba(16, 185, 129, 0.15);
  border: 1px solid rgba(16, 185, 129, 0.35);
  color: #34d399;
  font-size: 0.7rem;
  font-weight: 800;
  padding: 0.15rem 0.5rem;
  border-radius: 9999px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

/* Dropdown Trocar Atividade */
.dropdown-atividades-container {
  position: relative;
}

.btn-trocar-atividade {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--border-color);
  color: var(--text-muted);
  padding: 0.45rem 0.85rem;
  border-radius: var(--radius-md);
  font-size: 0.825rem;
  font-weight: 700;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 0.45rem;
  transition: all 0.2s ease;
}

.btn-trocar-atividade:hover {
  background: rgba(255, 255, 255, 0.12);
  color: var(--text-main);
  border-color: rgba(255, 255, 255, 0.25);
}

.menu-atividades-dropdown {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  width: 320px;
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  box-shadow: 0 15px 35px rgba(0, 0, 0, 0.5);
  padding: 0.85rem;
  z-index: 100;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  animation: fadeIn 0.18s ease-out;
}

.menu-dropdown-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.65rem;
  padding-bottom: 0.45rem;
  border-bottom: 1px solid var(--border-color);
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--text-muted);
}

.menu-dropdown-close {
  background: none;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  font-size: 0.9rem;
}

.menu-dropdown-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.45rem;
  max-height: 380px;
  overflow-y: auto;
}

.menu-dropdown-item {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.45rem 0.6rem;
  border-radius: var(--radius-sm);
  font-size: 0.775rem;
  font-weight: 600;
  color: var(--text-main);
  cursor: pointer;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid transparent;
  transition: all 0.15s ease;
}

.menu-dropdown-item:hover {
  background: rgba(56, 189, 248, 0.12);
  border-color: rgba(56, 189, 248, 0.3);
  color: #38bdf8;
  transform: translateX(2px);
}

/* Barra de Navegação da Home */
.nav-bar-home {
  background: var(--bg-secondary);
  border-bottom: 1px solid var(--border-color);
  padding: 0.75rem 1.5rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1rem;
}

.home-nav-indicator {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.home-nav-filter-pills {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  flex-wrap: wrap;
}

.pill-filtro-home {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-color);
  color: var(--text-muted);
  padding: 0.35rem 0.75rem;
  border-radius: 9999px;
  font-size: 0.8rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s ease;
}

.pill-filtro-home:hover {
  background: rgba(255, 255, 255, 0.1);
  color: var(--text-main);
}

.pill-filtro-home.active {
  background: linear-gradient(135deg, rgba(14, 165, 233, 0.25), rgba(99, 102, 241, 0.25));
  border-color: #38bdf8;
  color: #38bdf8;
}

/* Hero da Home */
.home-hero-card {
  background: linear-gradient(135deg, rgba(30, 41, 59, 0.7), rgba(15, 23, 42, 0.8));
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: var(--radius-lg);
  padding: 1.75rem;
  margin-bottom: 2rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 2rem;
  flex-wrap: wrap;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.25);
  position: relative;
  overflow: hidden;
}

.home-hero-card::after {
  content: '';
  position: absolute;
  top: -50px;
  right: -50px;
  width: 150px;
  height: 150px;
  background: radial-gradient(circle, rgba(56, 189, 248, 0.15), transparent 70%);
  pointer-events: none;
}

.home-hero-left {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  flex: 1;
  min-width: 300px;
}

.home-mascote-badge {
  position: relative;
  width: 80px;
  height: 80px;
  flex-shrink: 0;
}

.home-mascote-avatar {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  background: linear-gradient(135deg, rgba(52, 211, 153, 0.2), rgba(6, 182, 212, 0.2));
  border: 2px solid #34d399;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 3.2rem;
  box-shadow: 0 4px 15px rgba(52, 211, 153, 0.3);
  animation: mascoteFloat 3s ease-in-out infinite alternate;
}

.home-mascote-pulse {
  position: absolute;
  inset: -6px;
  border-radius: 50%;
  border: 2px solid rgba(52, 211, 153, 0.4);
  animation: pingAura 2.2s cubic-bezier(0, 0, 0.2, 1) infinite;
  pointer-events: none;
}

.home-hero-info {
  flex: 1;
}

.home-hero-tag {
  display: inline-block;
  background: rgba(52, 211, 153, 0.15);
  border: 1px solid rgba(52, 211, 153, 0.3);
  color: #34d399;
  font-size: 0.725rem;
  font-weight: 800;
  padding: 0.15rem 0.55rem;
  border-radius: 9999px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 0.4rem;
}

.home-hero-info h2 {
  font-size: 1.45rem;
  font-weight: 800;
  color: var(--text-main);
  margin-bottom: 0.35rem;
}

.home-hero-fala {
  font-size: 0.9rem;
  color: var(--text-muted);
  line-height: 1.5;
  margin-bottom: 1rem;
}

.home-hero-actions {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
}

/* Stats box no Hero */
.home-hero-stats {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.75rem;
  min-width: 280px;
}

.home-stat-box {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 0.75rem 1rem;
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.home-stat-icon {
  font-size: 1.75rem;
}

.home-stat-data {
  display: flex;
  flex-direction: column;
}

.home-stat-val {
  font-size: 1.05rem;
  font-weight: 800;
  color: var(--text-main);
}

.home-stat-label {
  font-size: 0.7rem;
  color: var(--text-muted);
  font-weight: 600;
}

/* Container de Atividades da Home */
.home-atividades-container {
  display: flex;
  flex-direction: column;
  gap: 2.25rem;
}

.home-secao-bloco {
  transition: all 0.25s ease;
}

.home-secao-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1rem;
  border-bottom: 1px solid var(--border-color);
  padding-bottom: 0.65rem;
}

.home-secao-title {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.home-secao-icone {
  font-size: 1.5rem;
}

.home-secao-title h3 {
  font-size: 1.15rem;
  font-weight: 800;
  color: var(--text-main);
  margin: 0;
}

.home-secao-title p {
  font-size: 0.8rem;
  color: var(--text-muted);
  margin: 0;
}

.home-cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 1.25rem;
}

.home-card-portal {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 1.25rem;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  cursor: pointer;
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  position: relative;
  overflow: hidden;
}

.home-card-portal:hover {
  transform: translateY(-4px);
  border-color: var(--accent-cyan);
  box-shadow: 0 12px 25px -5px rgba(0, 0, 0, 0.4), 0 0 15px rgba(6, 182, 212, 0.15);
}

.home-card-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.85rem;
}

.home-card-icon {
  width: 44px;
  height: 44px;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.6rem;
}

.home-card-portal h4 {
  font-size: 1.05rem;
  font-weight: 800;
  color: var(--text-main);
  margin-bottom: 0.45rem;
}

.home-card-portal p {
  font-size: 0.825rem;
  color: var(--text-muted);
  line-height: 1.5;
  margin-bottom: 1.25rem;
  flex: 1;
}

.home-card-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-top: 1px solid var(--border-color);
  padding-top: 0.75rem;
  margin-top: auto;
}

.home-card-meta {
  font-size: 0.725rem;
  color: var(--text-muted);
  font-weight: 600;
}

.btn-home-entrar {
  background: none;
  border: none;
  color: var(--accent-cyan);
  font-size: 0.825rem;
  font-weight: 800;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 0.25rem;
  transition: transform 0.2s ease;
}

.home-card-portal:hover .btn-home-entrar {
  transform: translateX(4px);
  color: #38bdf8;
}

/* Responsividade Modo Foco & Home */
@media (max-width: 768px) {
  .barra-modo-foco {
    padding: 0.5rem 1rem;
    top: 50px;
  }
  .foco-divisor {
    display: none;
  }
  .home-hero-card {
    padding: 1.25rem;
  }
  .home-hero-left {
    min-width: 100%;
  }
  .home-hero-stats {
    width: 100%;
  }
}

/* ========================================================
   ESTILOS: AUTENTICAÇÃO SEGURA (LOGIN / CADASTRO PRO)
   ======================================================== */
.auth-modal-card {
  max-width: 520px;
  width: 100%;
  border-radius: var(--radius-lg);
  border: 1px solid rgba(99, 102, 241, 0.35);
  box-shadow: 0 25px 60px -15px rgba(0, 0, 0, 0.75);
  background: var(--bg-secondary);
  animation: modalIn 0.25s ease-out;
  position: relative;
  overflow: hidden;
}

.auth-modal-header {
  text-align: center;
  padding: 1.5rem 1.75rem 1rem;
  border-bottom: 1px solid var(--border-color);
  position: relative;
}

.auth-modal-close-btn {
  position: absolute;
  top: 1rem;
  right: 1.25rem;
  background: transparent;
  border: none;
  color: var(--text-muted);
  font-size: 1.25rem;
  cursor: pointer;
  padding: 0.25rem;
  line-height: 1;
  transition: color 0.2s ease;
}

.auth-modal-close-btn:hover {
  color: var(--text-main);
}

.auth-modal-tabs {
  display: flex;
  background: rgba(15, 23, 42, 0.4);
  padding: 0.35rem;
  border-radius: var(--radius-md);
  margin: 1rem 1.5rem 0.5rem;
  gap: 0.35rem;
  border: 1px solid var(--border-color);
}

.auth-tab-btn {
  flex: 1;
  padding: 0.6rem 0.75rem;
  border-radius: var(--radius-sm);
  border: none;
  background: transparent;
  color: var(--text-muted);
  font-size: 0.875rem;
  font-weight: 700;
  cursor: pointer;
  transition: var(--transition);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
}

.auth-tab-btn.active {
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.25), rgba(6, 182, 212, 0.25));
  color: #38bdf8;
  border: 1px solid rgba(56, 189, 248, 0.4);
  box-shadow: 0 4px 12px rgba(6, 182, 212, 0.15);
}

.auth-modal-body {
  padding: 1.25rem 1.75rem 1.75rem;
}

.auth-input-group {
  position: relative;
  margin-bottom: 1rem;
}

.auth-label {
  display: block;
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--text-muted);
  margin-bottom: 0.35rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.auth-input-wrapper {
  position: relative;
  display: flex;
  align-items: center;
}

.auth-input-icon {
  position: absolute;
  left: 0.85rem;
  font-size: 1rem;
  color: var(--text-muted);
  pointer-events: none;
}

.auth-input-field {
  width: 100%;
  padding: 0.75rem 0.85rem 0.75rem 2.5rem;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-color);
  background: var(--bg-primary);
  color: var(--text-main);
  font-size: 0.925rem;
  transition: var(--transition);
}

.auth-input-field:focus {
  outline: none;
  border-color: var(--accent-cyan);
  box-shadow: 0 0 0 3px rgba(6, 182, 212, 0.2);
}

.auth-pwd-toggle {
  position: absolute;
  right: 0.85rem;
  background: none;
  border: none;
  cursor: pointer;
  font-size: 1.1rem;
  padding: 0.25rem;
  color: var(--text-muted);
  transition: color 0.2s ease;
}

.auth-pwd-toggle:hover {
  color: var(--text-main);
}

/* Medidor de Força de Senha Criptográfica */
.pwd-strength-container {
  margin-top: 0.4rem;
  margin-bottom: 0.85rem;
}

.pwd-strength-bars {
  display: flex;
  gap: 4px;
  height: 5px;
  margin-bottom: 0.35rem;
}

.pwd-bar {
  flex: 1;
  height: 100%;
  border-radius: 3px;
  background: rgba(148, 163, 184, 0.25);
  transition: background 0.3s ease;
}

.pwd-bar.active-fraca {
  background: #ef4444;
}

.pwd-bar.active-media {
  background: #f59e0b;
}

.pwd-bar.active-forte {
  background: #06b6d4;
}

.pwd-bar.active-excelente {
  background: #10b981;
}

.pwd-strength-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.725rem;
}

.pwd-strength-text {
  font-weight: 700;
  transition: color 0.3s ease;
}

.pwd-checklist {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.25rem 0.75rem;
  margin-top: 0.4rem;
  font-size: 0.7rem;
  color: var(--text-muted);
}

.pwd-check-item {
  display: flex;
  align-items: center;
  gap: 0.3rem;
  transition: color 0.2s ease;
}

.pwd-check-item.met {
  color: #34d399;
  font-weight: 600;
}

.auth-security-badge {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.6rem 0.75rem;
  border-radius: var(--radius-sm);
  background: rgba(99, 102, 241, 0.1);
  border: 1px solid rgba(99, 102, 241, 0.25);
  font-size: 0.75rem;
  color: #a5b4fc;
  margin-top: 1rem;
}

/* ========================================================
   ESTILOS: PAINEL DO PERFIL DO ALUNO (#view-perfil)
   ======================================================== */
.perfil-container {
  max-width: 1040px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  padding-bottom: 2rem;
}

.perfil-hero-card {
  position: relative;
  background: linear-gradient(135deg, rgba(30, 41, 59, 0.95), rgba(15, 23, 42, 0.98));
  border: 1px solid rgba(99, 102, 241, 0.35);
  border-radius: var(--radius-lg);
  padding: 2rem;
  box-shadow: 0 15px 35px -5px rgba(0, 0, 0, 0.5);
  overflow: hidden;
}

.perfil-hero-glow {
  position: absolute;
  top: -50px;
  right: -50px;
  width: 250px;
  height: 250px;
  background: radial-gradient(circle, rgba(99, 102, 241, 0.25) 0%, rgba(6, 182, 212, 0.1) 60%, transparent 80%);
  pointer-events: none;
}

.perfil-hero-content {
  position: relative;
  display: flex;
  align-items: center;
  gap: 1.75rem;
  flex-wrap: wrap;
}

.perfil-avatar-wrapper {
  position: relative;
  cursor: pointer;
  transition: transform 0.2s ease;
  user-select: none;
}

.perfil-avatar-wrapper:hover {
  transform: scale(1.05);
}

.perfil-avatar-display {
  width: 88px;
  height: 88px;
  border-radius: 50%;
  background: linear-gradient(135deg, #4f46e5, #06b6d4);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 3rem;
  box-shadow: 0 8px 24px rgba(79, 70, 229, 0.4);
  border: 3px solid rgba(255, 255, 255, 0.2);
}

.perfil-avatar-edit-badge {
  position: absolute;
  bottom: 0;
  right: 0;
  width: 28px;
  height: 28px;
  background: #10b981;
  color: #fff;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.85rem;
  border: 2px solid var(--bg-secondary);
  box-shadow: 0 2px 6px rgba(0,0,0,0.3);
}

.perfil-hero-info {
  flex: 1;
  min-width: 280px;
}

.perfil-badge-row {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
  margin-bottom: 0.4rem;
}

.badge-pro {
  background: linear-gradient(135deg, rgba(234, 179, 8, 0.2), rgba(245, 158, 11, 0.3));
  border: 1px solid rgba(245, 158, 11, 0.5);
  color: #fde047;
  font-weight: 800;
  font-size: 0.725rem;
  padding: 0.25rem 0.65rem;
  border-radius: 20px;
}

.badge-curso {
  background: rgba(6, 182, 212, 0.15);
  border: 1px solid rgba(6, 182, 212, 0.4);
  color: #38bdf8;
  font-weight: 700;
  font-size: 0.725rem;
  padding: 0.25rem 0.65rem;
  border-radius: 20px;
}

.badge-seguranca {
  background: rgba(16, 185, 129, 0.15);
  border: 1px solid rgba(16, 185, 129, 0.4);
  color: #34d399;
  font-weight: 700;
  font-size: 0.725rem;
  padding: 0.25rem 0.65rem;
  border-radius: 20px;
}

.perfil-hero-nome {
  font-size: 1.65rem;
  font-weight: 800;
  color: var(--text-main);
  margin-bottom: 0.2rem;
}

.perfil-hero-email {
  color: var(--text-muted);
  font-size: 0.875rem;
  margin-bottom: 0.65rem;
}

.perfil-hero-meta {
  display: flex;
  gap: 0.6rem;
  align-items: center;
  font-size: 0.8rem;
  color: var(--text-muted);
  flex-wrap: wrap;
}

.perfil-hero-meta strong {
  color: var(--text-main);
}

.perfil-hero-actions {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  min-width: 170px;
}

.btn-danger-outline {
  background: rgba(239, 68, 68, 0.1);
  color: #f87171;
  border: 1px solid rgba(239, 68, 68, 0.4);
  padding: 0.55rem 1rem;
  border-radius: var(--radius-md);
  font-weight: 700;
  font-size: 0.85rem;
  cursor: pointer;
  transition: var(--transition);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
}

.btn-danger-outline:hover {
  background: rgba(239, 68, 68, 0.25);
  border-color: #ef4444;
  color: #fff;
}

/* Grade de Métricas do Aluno */
.perfil-metrics-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1rem;
}

.perfil-metric-card {
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 1.25rem;
  display: flex;
  align-items: center;
  gap: 1rem;
  box-shadow: var(--shadow-card);
  transition: transform 0.2s ease, border-color 0.2s ease;
}

.perfil-metric-card:hover {
  transform: translateY(-3px);
  border-color: rgba(99, 102, 241, 0.4);
}

.perfil-metric-icon {
  width: 48px;
  height: 48px;
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.6rem;
}

.perfil-metric-data {
  display: flex;
  flex-direction: column;
}

.perfil-metric-val {
  font-size: 1.45rem;
  font-weight: 800;
  color: var(--text-main);
  line-height: 1.2;
}

.perfil-metric-label {
  font-size: 0.775rem;
  color: var(--text-muted);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.perfil-metric-sub {
  font-size: 0.725rem;
  color: var(--accent-cyan);
  font-weight: 600;
  margin-top: 0.15rem;
}

/* Sub-Abas do Perfil */
.perfil-tabs-nav {
  display: flex;
  background: var(--bg-secondary);
  padding: 0.4rem;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-color);
  gap: 0.5rem;
}

.perfil-tab-btn {
  flex: 1;
  padding: 0.75rem 1rem;
  border: none;
  background: transparent;
  color: var(--text-muted);
  font-weight: 700;
  font-size: 0.9rem;
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: var(--transition);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
}

.perfil-tab-btn.active {
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.2), rgba(6, 182, 212, 0.2));
  color: #38bdf8;
  border: 1px solid rgba(56, 189, 248, 0.35);
  box-shadow: 0 4px 14px rgba(6, 182, 212, 0.12);
}

.perfil-tab-content {
  display: none;
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 1.75rem;
  box-shadow: var(--shadow-card);
}

.perfil-tab-content.active {
  display: block;
  animation: fadeIn 0.25s ease-out;
}

.perfil-form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.25rem;
}

.perfil-field-group {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.perfil-field-group.full-width {
  grid-column: 1 / -1;
}

.perfil-field-label {
  font-size: 0.825rem;
  font-weight: 700;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  gap: 0.35rem;
}

.perfil-field-input, .perfil-field-select {
  padding: 0.75rem 1rem;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-color);
  background: var(--bg-primary);
  color: var(--text-main);
  font-size: 0.925rem;
  transition: var(--transition);
}

.perfil-field-input:focus, .perfil-field-select:focus {
  outline: none;
  border-color: var(--accent-cyan);
  box-shadow: 0 0 0 3px rgba(6, 182, 212, 0.2);
}

.perfil-security-card {
  background: rgba(15, 23, 42, 0.5);
  border: 1px solid rgba(99, 102, 241, 0.3);
  border-radius: var(--radius-md);
  padding: 1.25rem;
  margin-bottom: 1.5rem;
}

.perfil-security-header {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 0.75rem;
}

.perfil-security-title {
  font-weight: 800;
  font-size: 1.05rem;
  color: #a5b4fc;
}

.perfil-security-detail-list {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  font-size: 0.8rem;
  color: var(--text-muted);
}

.perfil-security-detail-list li {
  display: flex;
  align-items: center;
  gap: 0.45rem;
}

/* Modal de Seleção de Avatar */
.avatar-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(70px, 1fr));
  gap: 0.75rem;
  max-height: 320px;
  overflow-y: auto;
  padding: 0.5rem;
}

.avatar-option-btn {
  aspect-ratio: 1;
  border-radius: var(--radius-md);
  border: 2px solid var(--border-color);
  background: var(--bg-primary);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  font-size: 2rem;
  cursor: pointer;
  transition: transform 0.2s ease, border-color 0.2s ease, background 0.2s ease;
  position: relative;
}

.avatar-option-btn:hover {
  transform: scale(1.1);
  border-color: var(--accent-cyan);
  background: rgba(6, 182, 212, 0.15);
}

.avatar-option-btn.selected {
  border-color: #10b981;
  background: rgba(16, 185, 129, 0.2);
  box-shadow: 0 0 12px rgba(16, 185, 129, 0.4);
}

.avatar-option-label {
  font-size: 0.65rem;
  font-weight: 700;
  color: var(--text-muted);
  margin-top: 0.2rem;
  text-align: center;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 90%;
}

@media (max-width: 860px) {
  .perfil-metrics-grid {
    grid-template-columns: 1fr 1fr;
  }
  .perfil-form-grid {
    grid-template-columns: 1fr;
  }
  .perfil-hero-content {
    flex-direction: column;
    text-align: center;
  }
  .perfil-badge-row {
    justify-content: center;
  }
  .perfil-hero-meta {
    justify-content: center;
  }
  .perfil-hero-actions {
    width: 100%;
  }
  .perfil-tabs-nav {
    flex-direction: column;
  }
}

/* ========================================== */
/* PAINEL ADMINISTRATIVO & CRM DE VENDAS      */
/* ========================================== */
.admin-container {
  max-width: 1280px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.admin-header-card {
  background: linear-gradient(135deg, rgba(30, 41, 59, 0.95), rgba(15, 23, 42, 0.95));
  border: 1px solid rgba(245, 158, 11, 0.3);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.25);
}

.admin-header-left {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.admin-crown-badge {
  font-size: 2.2rem;
  width: 56px;
  height: 56px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 14px;
  background: linear-gradient(135deg, rgba(245, 158, 11, 0.25), rgba(239, 68, 68, 0.2));
  border: 1px solid rgba(245, 158, 11, 0.4);
  box-shadow: 0 0 20px rgba(245, 158, 11, 0.2);
}

.admin-header-actions {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  flex-wrap: wrap;
}

.admin-alert-bar {
  background: rgba(15, 23, 42, 0.6);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 0.65rem 1rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.75rem;
  font-size: 0.85rem;
}

.live-pulse-dot {
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background-color: #10b981;
  box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.7);
  animation: pulseNeon 1.6s infinite;
  margin-right: 4px;
}

@keyframes pulseNeon {
  0% {
    box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.8);
  }
  70% {
    box-shadow: 0 0 0 8px rgba(16, 185, 129, 0);
  }
  100% {
    box-shadow: 0 0 0 0 rgba(16, 185, 129, 0);
  }
}

/* Scorecards KPI */
.admin-kpis-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 1rem;
}

.admin-kpi-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 1.25rem;
  display: flex;
  flex-direction: column;
  transition: var(--transition);
}

.admin-kpi-card:hover {
  transform: translateY(-2px);
  border-color: rgba(245, 158, 11, 0.4);
}

.admin-kpi-card.highlight-neon {
  border-color: rgba(16, 185, 129, 0.4);
  background: linear-gradient(180deg, rgba(16, 185, 129, 0.08), var(--bg-card));
  box-shadow: 0 4px 20px rgba(16, 185, 129, 0.1);
}

.admin-kpi-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.75rem;
}

.admin-kpi-icon {
  width: 38px;
  height: 38px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.15rem;
}

.admin-kpi-tag {
  font-size: 0.7rem;
  font-weight: 800;
  padding: 0.2rem 0.5rem;
  border-radius: 999px;
  letter-spacing: 0.05em;
}

.admin-kpi-val {
  font-size: 2.2rem;
  font-weight: 800;
  color: var(--text-main);
  line-height: 1.1;
  margin-bottom: 0.2rem;
}

.admin-kpi-card.highlight-neon .admin-kpi-val {
  color: #34d399;
}

.admin-kpi-title {
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--text-muted);
}

.admin-kpi-sub {
  font-size: 0.75rem;
  color: var(--text-muted);
  margin-top: 0.35rem;
}

/* Abas Administrativas */
.admin-tabs-nav {
  display: flex;
  gap: 0.5rem;
  border-bottom: 1px solid var(--border-color);
  padding-bottom: 0.5rem;
  flex-wrap: wrap;
}

.admin-tab-btn {
  background: transparent;
  border: 1px solid transparent;
  color: var(--text-muted);
  font-size: 0.875rem;
  font-weight: 700;
  padding: 0.65rem 1.1rem;
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: var(--transition);
}

.admin-tab-btn:hover {
  background: var(--bg-card-hover);
  color: var(--text-main);
}

.admin-tab-btn.active {
  background: rgba(245, 158, 11, 0.15);
  border-color: rgba(245, 158, 11, 0.4);
  color: #fbbf24;
}

.admin-tab-content {
  display: none;
  animation: fadeIn 0.25s ease;
}

.admin-tab-content.active {
  display: block;
}

.admin-content-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1rem;
}

/* Tabela e Filtros */
.admin-search-input {
  flex: 1;
  min-width: 220px;
  background: var(--bg-primary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 0.55rem 0.85rem;
  color: var(--text-main);
  font-size: 0.85rem;
}

.admin-search-input:focus {
  outline: none;
  border-color: #f59e0b;
}

.admin-filter-select {
  background: var(--bg-primary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 0.55rem 0.85rem;
  color: var(--text-main);
  font-size: 0.85rem;
  cursor: pointer;
}

.admin-table-wrapper {
  overflow-x: auto;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  background: var(--bg-card);
}

.admin-table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
  font-size: 0.85rem;
}

.admin-table th {
  background: var(--bg-secondary);
  color: var(--text-muted);
  font-weight: 700;
  padding: 0.85rem 1rem;
  border-bottom: 1px solid var(--border-color);
  white-space: nowrap;
}

.admin-table td {
  padding: 0.85rem 1rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  vertical-align: middle;
}

.admin-table tr:hover td {
  background: var(--bg-card-hover);
}

.btn-whatsapp-venda {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  background: linear-gradient(135deg, #25d366, #128c7e);
  color: #ffffff !important;
  font-weight: 800;
  font-size: 0.775rem;
  padding: 0.35rem 0.75rem;
  border-radius: 9999px;
  text-decoration: none;
  border: none;
  cursor: pointer;
  box-shadow: 0 2px 8px rgba(37, 211, 102, 0.3);
  transition: var(--transition);
  white-space: nowrap;
}

.btn-whatsapp-venda:hover {
  transform: scale(1.04);
  box-shadow: 0 4px 12px rgba(37, 211, 102, 0.5);
}

/* Cards de Usuários Online */
.online-users-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1rem;
}

.online-user-card {
  background: var(--bg-card);
  border: 1px solid rgba(16, 185, 129, 0.3);
  border-radius: var(--radius-md);
  padding: 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  position: relative;
  overflow: hidden;
}

.online-user-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 4px;
  height: 100%;
  background: #10b981;
}

.online-user-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
}

.online-user-info {
  display: flex;
  align-items: center;
  gap: 0.6rem;
}

.online-user-avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: rgba(99, 102, 241, 0.2);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
}

.online-user-name {
  font-weight: 700;
  font-size: 0.9rem;
  color: var(--text-main);
  line-height: 1.2;
}

.online-user-tag {
  font-size: 0.7rem;
  color: var(--text-muted);
}

.online-user-action-box {
  background: rgba(0, 0, 0, 0.25);
  border-radius: 6px;
  padding: 0.5rem 0.65rem;
  font-size: 0.8rem;
  color: #38bdf8;
  display: flex;
  align-items: center;
  gap: 0.35rem;
}

.online-user-meta {
  display: flex;
  justify-content: space-between;
  font-size: 0.75rem;
  color: var(--text-muted);
}

/* Scripts de Vendas */
.admin-scripts-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 1rem;
}

.script-box {
  background: var(--bg-primary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 0.85rem;
  font-size: 0.825rem;
  line-height: 1.6;
  color: var(--text-main);
  user-select: all;
}

/* Role Badges */
.badge-role-admin {
  background: rgba(245, 158, 11, 0.2);
  color: #fbbf24;
  font-weight: 800;
  padding: 0.2rem 0.55rem;
  border-radius: 999px;
  font-size: 0.75rem;
  border: 1px solid rgba(245, 158, 11, 0.4);
}

.badge-role-pro {
  background: rgba(16, 185, 129, 0.2);
  color: #34d399;
  font-weight: 800;
  padding: 0.2rem 0.55rem;
  border-radius: 999px;
  font-size: 0.75rem;
  border: 1px solid rgba(16, 185, 129, 0.4);
}

.badge-role-lead {
  background: rgba(99, 102, 241, 0.15);
  color: #a5b4fc;
  font-weight: 700;
  padding: 0.2rem 0.55rem;
  border-radius: 999px;
  font-size: 0.75rem;
}

/* ========================================================
   ESTILOS: RECUPERAÇÃO DE SENHA & CÓDIGO DE SEGURANÇA
   ======================================================== */
.codigo-recuperacao-destaque {
  font-family: 'JetBrains Mono', 'Courier New', monospace;
  font-size: 2rem;
  font-weight: 900;
  letter-spacing: 0.5rem;
  color: #38bdf8;
  background: rgba(6, 182, 212, 0.12);
  border: 1px dashed rgba(56, 189, 248, 0.5);
  border-radius: var(--radius-md);
  padding: 0.85rem 1rem;
  text-align: center;
  margin: 0.85rem 0;
  box-shadow: inset 0 2px 10px rgba(0, 0, 0, 0.3);
  user-select: all;
}

/* ========================================================
   ESTILOS: DASHBOARD ACADÊMICA DO ALUNO (COCKPIT TRI)
   ======================================================== */
.aluno-cockpit-container {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.cockpit-tri-banner {
  background: linear-gradient(135deg, rgba(79, 70, 229, 0.18), rgba(6, 182, 212, 0.15));
  border: 1px solid rgba(56, 189, 248, 0.35);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1.5rem;
  flex-wrap: wrap;
  box-shadow: 0 10px 30px -10px rgba(6, 182, 212, 0.2);
}

.cockpit-tri-left {
  flex: 1;
  min-width: 280px;
}

.cockpit-tri-thermometer {
  width: 100%;
  background: rgba(15, 23, 42, 0.6);
  border-radius: 999px;
  height: 18px;
  border: 1px solid var(--border-color);
  overflow: hidden;
  margin: 0.6rem 0 0.35rem;
  position: relative;
}

.cockpit-tri-bar {
  height: 100%;
  border-radius: 999px;
  background: linear-gradient(90deg, #6366f1, #06b6d4, #10b981, #f59e0b);
  transition: width 0.8s cubic-bezier(0.4, 0, 0.2, 1);
  position: relative;
}

.cockpit-areas-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1rem;
}

.cockpit-area-card {
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 1.15rem;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  transition: transform 0.2s ease, border-color 0.2s ease;
}

.cockpit-area-card:hover {
  transform: translateY(-2px);
  border-color: rgba(56, 189, 248, 0.4);
}

.cockpit-area-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.cockpit-area-progress {
  width: 100%;
  height: 8px;
  background: rgba(255, 255, 255, 0.08);
  border-radius: 999px;
  overflow: hidden;
}

.cockpit-area-fill {
  height: 100%;
  border-radius: 999px;
  transition: width 0.6s ease;
}

.cockpit-shortcuts-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 0.85rem;
}

.cockpit-shortcut-btn {
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 1rem 0.85rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  text-align: center;
  cursor: pointer;
  transition: all 0.2s ease;
}

.cockpit-shortcut-btn:hover {
  background: rgba(99, 102, 241, 0.12);
  border-color: #6366f1;
  transform: translateY(-3px);
  box-shadow: 0 8px 20px -6px rgba(99, 102, 241, 0.3);
}

.cockpit-shortcut-icon {
  font-size: 1.85rem;
}

.cockpit-shortcut-title {
  font-weight: 800;
  font-size: 0.85rem;
  color: var(--text-main);
}

.cockpit-shortcut-desc {
  font-size: 0.725rem;
  color: var(--text-muted);
}

/* ==========================================
   ESTILOS: O OLHO QUE TUDO VÊ (TELEMETRIA AO VIVO)
   ========================================== */
.telemetria-mini-stat {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  padding: 0.35rem 0.65rem;
  border-radius: var(--radius-sm);
}

.olho-grid-layout {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 1.25rem;
  margin-top: 1rem;
}

@media (max-width: 980px) {
  .olho-grid-layout {
    grid-template-columns: 1fr;
  }
}

.olho-col-online {
  display: flex;
  flex-direction: column;
}

.olho-col-feed {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 1rem;
  display: flex;
  flex-direction: column;
}

.feed-telemetria-scroll {
  max-height: 560px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  padding-right: 0.35rem;
  scrollbar-width: thin;
  scrollbar-color: rgba(56, 189, 248, 0.3) transparent;
}

.feed-telemetria-scroll::-webkit-scrollbar {
  width: 5px;
}
.feed-telemetria-scroll::-webkit-scrollbar-thumb {
  background: rgba(56, 189, 248, 0.3);
  border-radius: 9999px;
}

.feed-item-card {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.07);
  border-radius: var(--radius-sm);
  padding: 0.65rem 0.8rem;
  display: flex;
  align-items: flex-start;
  gap: 0.65rem;
  transition: all 0.2s ease;
  animation: fadeIn 0.25s ease-out;
}

.feed-item-card:hover {
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(56, 189, 248, 0.3);
  transform: translateX(2px);
}

.feed-item-icon {
  font-size: 1.25rem;
  flex-shrink: 0;
  margin-top: 0.1rem;
}

.feed-item-body {
  flex: 1;
  min-width: 0;
}

.feed-item-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.2rem;
}

.feed-item-user {
  font-weight: 700;
  font-size: 0.825rem;
  color: var(--text-main);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.feed-item-hora {
  font-size: 0.7rem;
  color: var(--text-muted);
  font-variant-numeric: tabular-nums;
  flex-shrink: 0;
}

.feed-item-titulo {
  font-size: 0.775rem;
  font-weight: 600;
  color: #38bdf8;
  line-height: 1.35;
}

.feed-item-detalhe {
  font-size: 0.725rem;
  color: var(--text-muted);
  margin-top: 0.15rem;
  line-height: 1.35;
}

/* Card Pro de Usuário Conectado */
.online-user-card-pro {
  background: var(--bg-card);
  border: 1px solid rgba(16, 185, 129, 0.35);
  border-radius: var(--radius-md);
  padding: 1.1rem;
  margin-bottom: 0.85rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
  position: relative;
  overflow: hidden;
}

.online-user-card-pro::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 5px;
  height: 100%;
  background: linear-gradient(180deg, #10b981, #06b6d4);
}

.online-user-spotlight {
  background: linear-gradient(135deg, rgba(16, 185, 129, 0.12), rgba(6, 182, 212, 0.12));
  border: 1px solid rgba(16, 185, 129, 0.3);
  border-radius: var(--radius-sm);
  padding: 0.75rem 0.85rem;
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.online-user-spotlight-icon {
  font-size: 1.8rem;
  flex-shrink: 0;
  animation: pulse 2s infinite ease-in-out;
}

.online-user-spotlight-title {
  font-size: 0.7rem;
  font-weight: 800;
  color: #34d399;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.online-user-spotlight-action {
  font-size: 0.925rem;
  font-weight: 800;
  color: #fff;
  margin-top: 0.15rem;
  line-height: 1.3;
}

.online-user-recent-steps {
  background: rgba(0, 0, 0, 0.2);
  border-radius: 6px;
  padding: 0.5rem 0.75rem;
  font-size: 0.75rem;
}

.online-user-recent-step-item {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.2rem 0;
  color: var(--text-muted);
}

.online-user-recent-step-item span.hora {
  font-size: 0.68rem;
  color: rgba(255, 255, 255, 0.4);
  font-variant-numeric: tabular-nums;
}

/* ==========================================
   ESTILOS: MODAL DOSSIÊ COMPLETO DO ALUNO
   ========================================== */
.dossie-modal-card {
  position: relative;
  width: 100%;
  max-width: 680px;
  max-height: min(90vh, 740px);
  background: var(--bg-card);
  border: 1px solid rgba(56, 189, 248, 0.4);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  box-shadow: 0 25px 60px -10px rgba(0, 0, 0, 0.8), 0 0 35px rgba(56, 189, 248, 0.15);
  display: flex;
  flex-direction: column;
  gap: 1rem;
  overflow-y: auto;
  animation: scaleUp 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.dossie-modal-close {
  position: absolute;
  top: 1rem;
  right: 1rem;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid var(--border-color);
  color: var(--text-muted);
  width: 30px;
  height: 30px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 0.9rem;
  transition: all 0.2s ease;
  z-index: 5;
}

.dossie-modal-close:hover {
  background: rgba(244, 63, 94, 0.2);
  color: #fb7185;
  border-color: rgba(244, 63, 94, 0.4);
  transform: rotate(90deg);
}

.dossie-header {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.dossie-avatar-box {
  width: 58px;
  height: 58px;
  border-radius: 50%;
  background: linear-gradient(135deg, rgba(56, 189, 248, 0.2), rgba(99, 102, 241, 0.2));
  border: 2px solid #38bdf8;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2.2rem;
  flex-shrink: 0;
}

.dossie-info-box {
  flex: 1;
  min-width: 0;
}

.dossie-live-action {
  background: linear-gradient(135deg, rgba(16, 185, 129, 0.15), rgba(6, 182, 212, 0.15));
  border: 1px solid #10b981;
  border-radius: var(--radius-sm);
  padding: 0.75rem 1rem;
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.dossie-scorecards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(130px, 1fr));
  gap: 0.65rem;
}

.dossie-kpi {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  padding: 0.75rem;
  text-align: center;
}

.dossie-kpi-val {
  font-size: 1.35rem;
  font-weight: 800;
  color: var(--text-main);
}

.dossie-kpi-label {
  font-size: 0.725rem;
  font-weight: 700;
  color: var(--text-muted);
  margin-top: 0.15rem;
}

.dossie-kpi-sub {
  font-size: 0.68rem;
  color: #38bdf8;
  margin-top: 0.15rem;
}

.dossie-timeline-section {
  display: flex;
  flex-direction: column;
}

.dossie-timeline-list {
  max-height: 280px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  padding-right: 0.25rem;
  scrollbar-width: thin;
}

.dossie-timeline-item {
  background: rgba(255, 255, 255, 0.02);
  border-left: 3px solid #38bdf8;
  padding: 0.5rem 0.75rem;
  border-radius: 0 6px 6px 0;
  font-size: 0.8rem;
}

.dossie-timeline-item.acerto {
  border-left-color: #10b981;
}

.dossie-timeline-item.erro {
  border-left-color: #ef4444;
}

.dossie-timeline-item.foco {
  border-left-color: #fbbf24;
}

.dossie-modal-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  border-top: 1px solid var(--border-color);
  padding-top: 0.85rem;
  flex-wrap: wrap;
}

/* ==========================================================================
   TREINO POR ÁREA & SUBTEMA: DESIGN LIMPO E MODERNO (ANTI-POLUIÇÃO)
   ========================================================================== */
.treino-header-card {
  background: var(--card-bg, #0f172a);
  border: 1px solid var(--border-color, rgba(255, 255, 255, 0.08));
  border-radius: var(--radius-lg, 16px);
  padding: 1.25rem 1.5rem;
  margin-bottom: 1.5rem;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
}

.treino-header-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-bottom: 1rem;
}

.treino-title {
  font-size: 1.35rem;
  font-weight: 800;
  color: var(--text-main, #f8fafc);
  margin-bottom: 0.25rem;
}

.treino-subtitle {
  color: var(--text-muted, #94a3b8);
  font-size: 0.85rem;
  margin: 0;
}

.treino-areas-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 0.5rem;
  margin-bottom: 1rem;
}

.treino-area-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.6rem 0.85rem;
  font-size: 0.85rem;
  font-weight: 700;
  border-radius: var(--radius-md, 10px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.03);
  color: var(--text-muted, #94a3b8);
  cursor: pointer;
  transition: all 0.2s ease;
  white-space: nowrap;
}

.treino-area-btn:hover {
  background: rgba(56, 189, 248, 0.08);
  border-color: rgba(56, 189, 248, 0.3);
  color: var(--text-main, #f8fafc);
}

.treino-area-btn.active {
  background: linear-gradient(135deg, rgba(56, 189, 248, 0.2), rgba(99, 102, 241, 0.2));
  border-color: #38bdf8;
  color: #38bdf8;
  box-shadow: 0 0 12px rgba(56, 189, 248, 0.2);
}

.treino-subtemas-clean-bar {
  display: flex;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
  padding-top: 0.85rem;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.treino-select-wrapper {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.treino-select-label {
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--text-muted, #94a3b8);
  white-space: nowrap;
}

.treino-select {
  padding: 0.45rem 0.85rem;
  font-size: 0.85rem;
  font-weight: 600;
  border-radius: 8px;
  background: rgba(15, 23, 42, 0.8);
  border: 1px solid rgba(255, 255, 255, 0.15);
  color: var(--text-main, #f8fafc);
  cursor: pointer;
  min-width: 220px;
}

.treino-pills-row {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  flex-wrap: wrap;
  flex: 1;
}

.treino-pill-btn {
  padding: 0.35rem 0.65rem;
  font-size: 0.78rem;
  font-weight: 600;
  border-radius: 6px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.02);
  color: var(--text-muted, #94a3b8);
  cursor: pointer;
  transition: all 0.15s ease;
}

.treino-pill-btn:hover {
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(255, 255, 255, 0.2);
  color: var(--text-main, #f8fafc);
}

.treino-pill-btn.active {
  background: rgba(56, 189, 248, 0.15);
  border-color: rgba(56, 189, 248, 0.5);
  color: #38bdf8;
  font-weight: 700;
}
