/* style.css - VERSÃO TABS + LOGO 100% + SEM CONFETTI */
:root {
  --bg-dark: #0a0a0f;
  --bg-card: rgba(255, 255, 255, 0.04);
  --bg-card-hover: rgba(255, 255, 255, 0.08);
  --glass-border: 1px solid rgba(255, 255, 255, 0.12);
  --gold-gradient: linear-gradient(135deg, #d4af37, #fcf6ba, #bf953f);
  --gold-text: #ffd700;
  --text-main: #ffffff;
  --text-muted: #a0a0c0;
  
  --font-serif: 'Playfair Display', serif;
  --font-sans: 'Montserrat', sans-serif;
  
  --success-color: #4caf50;
  --error-color: #ff4444;
  --warning-color: #ffaa00;
  
  --shadow: 0 4px 20px rgba(0,0,0,0.4);
  --shadow-strong: 0 8px 32px rgba(0,0,0,0.6);
}

* { 
  margin: 0; 
  padding: 0; 
  box-sizing: border-box; 
}

html, body {
  margin: 0 !important;
  padding: 0 !important;
  border: 0;
  outline: 0;
}

html {
  height: 100%;
  -webkit-text-size-adjust: 100%;
  -ms-text-size-adjust: 100%;
  font-size: 14px;
  -webkit-tap-highlight-color: transparent;
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-sans);
  background-color: var(--bg-dark);
  color: var(--text-main);
  position: relative;
  overflow-x: hidden;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  line-height: 1.4;
  display: block;
}

.background-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: 
    radial-gradient(circle at 10% 20%, rgba(212, 175, 55, 0.08) 0%, transparent 35%),
    radial-gradient(circle at 90% 80%, rgba(191, 149, 63, 0.06) 0%, transparent 35%),
    linear-gradient(180deg, #0a0a0f 0%, #151520 50%, #0a0a0f 100%);
  z-index: -1;
  pointer-events: none;
}

.container {
  margin: 0 !important;
  padding: 0 !important;
  padding-left: 6px !important;
  padding-right: 6px !important;
  width: 100%;
  max-width: 100%;
  position: relative;
}

/* ========================================= HEADER ========================================= */
.header {
  margin-top: 0 !important;
  margin-bottom: 6px;
  padding: 8px 0 6px;
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(10, 10, 15, 0.98);
  backdrop-filter: blur(25px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.header-container-logo {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-bottom: 8px;
  padding: 0 4px;
  width: 100%;
  position: relative;
  min-height: 44px;
}

/* ✅ LOGO 100% COM BORDAS ARREDONDADAS */
.logo-box {
  width: 36px;
  height: 36px;
  flex-shrink: 0;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 50%;
  padding: 0;
  backdrop-filter: blur(10px);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
  overflow: hidden;
}

.logo-box:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(212, 175, 55, 0.3);
  transform: scale(1.05);
}

.logo-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: brightness(1.1);
}

.logo-box.logo-dsng {
  position: absolute;
  left: 6px;
}

.logo-box.logo-kreativuz {
  position: absolute;
  right: 6px;
}

.header-content {
  flex: 1;
  padding: 0 8px;
  text-align: center;
  max-width: 600px;
  margin: 0 auto;
}

.header h1 {
  font-family: var(--font-serif);
  font-size: 1.25rem;
  font-weight: 700;
  background: var(--gold-gradient);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  margin-bottom: 2px;
  line-height: 1.2;
  letter-spacing: 0.4px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
}

.header .year {
  color: var(--gold-text);
  font-size: 0.8em;
  font-weight: 600;
  display: inline-block;
  background: rgba(212, 175, 55, 0.1);
  padding: 2px 6px;
  border-radius: 4px;
}

.header p {
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.8px;
  font-size: 0.62rem;
  margin-top: 2px;
  font-weight: 500;
}

.daily-limit-info {
  margin-top: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  background: rgba(212, 175, 55, 0.12);
  padding: 4px 10px;
  border-radius: 10px;
  border: 1px solid rgba(212, 175, 55, 0.25);
  font-size: 0.62rem;
  width: fit-content;
  margin-left: auto;
  margin-right: auto;
}

.limit-icon {
  font-size: 0.75rem;
}

.limit-text {
  color: var(--gold-text);
  font-weight: 600;
  font-size: 0.62rem;
}

/* ========================================= STATS BAR ========================================= */
.stats-bar-wrapper {
  padding: 0 4px;
  margin-top: 4px;
}

.stats-bar {
  display: flex;
  justify-content: space-around;
  align-items: center;
  background: rgba(0, 0, 0, 0.3);
  backdrop-filter: blur(15px);
  padding: 6px 8px;
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: var(--shadow);
}

.stat-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  flex: 1;
  min-width: 0;
}

.stat-divider {
  width: 1px;
  height: 24px;
  background: rgba(255, 255, 255, 0.1);
  margin: 0 8px;
}

.stat-number {
  font-family: var(--font-serif);
  font-size: 0.95rem;
  color: var(--gold-text);
  font-weight: 700;
  line-height: 1;
}

.stat-label {
  font-size: 0.5rem;
  color: var(--text-muted);
  margin-top: 3px;
  text-transform: uppercase;
  letter-spacing: 0.3px;
  text-align: center;
  white-space: nowrap;
}

/* ========================================= SIDEBAR TABS ========================================= */
.sidebar {
  position: sticky;
  top: 72px;
  z-index: 99;
  background: rgba(15, 15, 25, 0.95);
  backdrop-filter: blur(25px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 12px;
  padding: 10px;
  margin: 0 0 10px 0;
  box-shadow: var(--shadow-strong);
  max-height: 260px;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.sidebar-header {
  margin-bottom: 8px;
}

.sidebar h3 {
  font-family: var(--font-serif);
  color: var(--gold-text);
  font-size: 0.85rem;
  margin-bottom: 6px;
  padding-bottom: 4px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.search-container {
  position: relative;
  margin-bottom: 6px;
  margin-top: 6px;
}

.search-input {
  width: 100%;
  padding: 8px 10px 8px 30px;
  font-size: 0.75rem;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 8px;
  color: var(--text-main);
  transition: all 0.2s ease;
}

.search-input:focus {
  outline: none;
  border-color: var(--gold-text);
  background: rgba(212, 175, 55, 0.1);
  box-shadow: 0 0 0 2px rgba(212, 175, 55, 0.15);
}

.search-icon {
  position: absolute;
  left: 10px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--gold-text);
  opacity: 0.7;
  font-size: 0.85rem;
}

.nav-container {
  flex: 1;
  overflow-y: auto;
  overflow-x: hidden;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: thin;
  scrollbar-color: var(--gold-text) transparent;
  padding-right: 3px;
  margin-bottom: 6px;
}

.nav-container::-webkit-scrollbar {
  width: 3px;
}

.nav-container::-webkit-scrollbar-track {
  background: transparent;
}

.nav-container::-webkit-scrollbar-thumb {
  background: rgba(212, 175, 55, 0.5);
  border-radius: 2px;
}

#navCategorias {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 6px;
  padding: 2px;
}

.nav-link {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 10px;
  padding: 6px 8px;
  font-size: 0.7rem;
  color: var(--text-main);
  text-decoration: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 4px;
  transition: all 0.2s ease;
  min-height: 34px;
  overflow: hidden;
  cursor: pointer;
}

.nav-link:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.12);
}

.nav-link.active {
  background: linear-gradient(135deg, #ffd700, #e6c200);
  color: #000;
  font-weight: 700;
  border-color: #ffd700;
  box-shadow: 0 2px 10px rgba(255, 215, 0, 0.3);
}

.nav-text {
  flex: 1;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-weight: 500;
  font-size: 0.7rem;
}

.nav-badge, .nav-badge-lock {
  background: rgba(255, 215, 0, 0.15);
  color: var(--gold-text);
  padding: 2px 4px;
  border-radius: 6px;
  font-size: 0.6rem;
  font-weight: 700;
  min-width: 16px;
  text-align: center;
  flex-shrink: 0;
}

.nav-link.active .nav-badge,
.nav-link.active .nav-badge-lock {
  background: rgba(0, 0, 0, 0.2);
  color: #000;
}

.sidebar-footer {
  margin-top: auto;
  padding-top: 8px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  text-align: center;
}

.sidebar-footer p {
  font-size: 0.65rem;
  color: var(--text-muted);
  margin-bottom: 6px;
}

.btn-share {
  width: 100%;
  padding: 8px;
  background: transparent;
  color: var(--gold-text);
  border: 1px solid var(--gold-text);
  border-radius: 8px;
  font-size: 0.65rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-share:hover {
  background: var(--gold-text);
  color: var(--bg-dark);
  box-shadow: 0 3px 10px rgba(255, 215, 0, 0.2);
}

/* ========================================= CONTEÚDO TABS ========================================= */
.main-layout {
  display: block;
  padding: 0 4px;
}

.content-area {
  width: 100%;
  position: relative;
  min-height: 400px;
}

/* ✅ APENAS UMA CATEGORIA VISÍVEL POR VEZ */
.categoria-section {
  background: rgba(20, 20, 30, 0.7);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 12px;
  padding: 12px;
  margin-bottom: 12px;
  backdrop-filter: blur(10px);
  box-shadow: var(--shadow);
  display: none; /* ✅ Esconde todas por padrão */
}

.categoria-section.active {
  display: block; /* ✅ Mostra apenas a ativa */
  animation: fadeInUp 0.3s ease;
}

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

.categoria-header {
  text-align: center;
  margin-bottom: 12px;
  padding-bottom: 8px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.categoria-header h2 {
  font-family: var(--font-serif);
  font-size: 1.15rem;
  color: var(--text-main);
  margin-bottom: 4px;
  line-height: 1.3;
}

.categoria-desc {
  color: var(--text-muted);
  font-size: 0.7rem;
  margin-bottom: 6px;
}

.votos-restantes-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 5px 10px;
  border-radius: 12px;
  font-size: 0.65rem;
  font-weight: 600;
}

.votos-restantes-badge.active {
  background: rgba(76, 175, 80, 0.12);
  color: var(--success-color);
  border: 1px solid rgba(76, 175, 80, 0.25);
}

.votos-restantes-badge.limite-atingido {
  background: rgba(244, 67, 54, 0.12);
  color: var(--error-color);
  border: 1px solid rgba(244, 67, 54, 0.25);
  animation: pulse 1.5s infinite;
}

.decorative-line {
  width: 30px;
  height: 2px;
  background: var(--gold-gradient);
  margin: 6px auto;
  border-radius: 1px;
}

/* ========================================= GRID CANDIDATOS ========================================= */
.candidatos-grid {
  display: flex;
  overflow-x: auto;
  overflow-y: hidden;
  gap: 10px;
  padding: 8px 2px 12px;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  margin: 0 -4px;
}

.candidatos-grid::-webkit-scrollbar {
  display: none;
}

.candidato-card {
  flex: 0 0 auto;
  width: 200px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 12px;
  overflow: hidden;
  transition: all 0.3s ease;
  display: flex;
  flex-direction: column;
}

.candidato-card:hover {
  background: rgba(255, 255, 255, 0.05);
  border-color: rgba(212, 175, 55, 0.2);
  box-shadow: 0 4px 12px rgba(212, 175, 55, 0.1);
}

.card-visual {
  height: 140px;
  background: linear-gradient(135deg, #1a1a25, #252535);
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* ========================================= AJUSTES INDIVIDUAIS DE FOTOS ========================================= */
/* Use estas classes no data.js se uma foto específica estiver cortando o rosto */

/* Prioriza o topo da imagem (para fotos de corpo inteiro) */
.foto-wrapper img[data-position="top"] {
  object-position: center top !important;
}

/* Prioriza o centro (padrão) */
.foto-wrapper img[data-position="center"] {
  object-position: center center !important;
}

/* Prioriza o fundo (raramente usado) */
.foto-wrapper img[data-position="bottom"] {
  object-position: center bottom !important;
}

/* Aumenta o zoom para rostos muito pequenos */
.foto-wrapper img[data-zoom="in"] {
  transform: scale(1.3);
  object-position: center 30%;
}

/* Diminui o zoom para fotos muito próximas */
.foto-wrapper img[data-zoom="out"] {
  transform: scale(0.85);
}

.foto-wrapper {
  width: 90px;
  height: 90px;
  border-radius: 50%;
  border: 3px solid rgba(255, 255, 255, 0.2);
  overflow: hidden;
  background: rgba(0, 0, 0, 0.2);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.5);
  transition: transform 0.3s ease;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}

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

.foto-wrapper img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 15%;
  /* 15% = foca bem no topo, ideal para fotos de corpo inteiro */
  transition: transform 0.3s ease;
}

.placeholder-icon {
  font-size: 1rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
  color: #ffd700;
  background: #1a1a25;
  border-radius: 50%;
  text-shadow: 0 2px 4px rgba(0,0,0,0.3);
  padding: 10px;
  text-align: center;
  line-height: 1.2;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  overflow: hidden;
  word-wrap: break-word;
  hyphens: auto;
}

.medal {
  position: absolute;
  top: 6px;
  left: 6px;
  padding: 2px 6px;
  border-radius: 10px;
  font-size: 0.6rem;
  font-weight: 700;
  color: #000;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.3);
  z-index: 2;
}

.medal.gold {
  background: linear-gradient(135deg, #ffd700, #ffed4e);
}

.medal.silver {
  background: linear-gradient(135deg, #c0c0c0, #e8e8e8);
}

.medal.bronze {
  background: linear-gradient(135deg, #cd7f32, #e8a87c);
}

.card-content {
  padding: 10px;
  flex: 1;
  display: flex;
  flex-direction: column;
}

.info-top {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 8px;
  gap: 6px;
}

.info-top h4 {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-main);
  flex: 1;
  line-height: 1.3;
}

.percent-badge {
  font-family: var(--font-serif);
  color: var(--gold-text);
  font-size: 0.85rem;
  font-weight: 700;
  background: rgba(212, 175, 55, 0.12);
  padding: 2px 5px;
  border-radius: 6px;
  white-space: nowrap;
}

.progress-track {
  height: 4px;
  background: rgba(255, 255, 255, 0.08);
  border-radius: 3px;
  margin-bottom: 8px;
  overflow: hidden;
}

.progress-bar {
  height: 100%;
  background: var(--gold-gradient);
  border-radius: 3px;
  transition: width 0.5s ease;
  box-shadow: 0 0 8px rgba(255, 215, 0, 0.3);
}

.info-bottom {
  text-align: center;
  margin-bottom: 10px;
  font-size: 0.7rem;
  color: var(--text-muted);
}

.votos-count {
  display: inline-flex;
  align-items: center;
  gap: 3px;
}

.votos-icon {
  font-size: 0.8rem;
  animation: heartbeat 1.5s infinite;
}

.btn-votar {
  width: 100%;
  padding: 8px;
  background: transparent;
  color: var(--gold-text);
  border: 2px solid var(--gold-text);
  border-radius: 8px;
  font-family: var(--font-sans);
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.3px;
  cursor: pointer;
  transition: all 0.2s ease;
  margin-top: auto;
  min-height: 36px;
}

.btn-votar:hover:not(:disabled) {
  background: var(--gold-text);
  color: var(--bg-dark);
  transform: translateY(-1px);
  box-shadow: 0 3px 10px rgba(255, 215, 0, 0.3);
}

.btn-votar:active:not(:disabled) {
  transform: translateY(0);
}

.btn-votar:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  border-color: #555;
  color: #555;
}

.btn-votar.success {
  background: var(--success-color);
  border-color: var(--success-color);
  color: white;
  box-shadow: 0 3px 10px rgba(76, 175, 80, 0.3);
}

/* ========================================= NOTIFICAÇÕES CENTRALIZADAS ========================================= */
.toast-container {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: 10000;
  pointer-events: none;
}

.toast {
  background: rgba(15, 15, 25, 0.98);
  backdrop-filter: blur(30px);
  color: var(--text-main);
  padding: 20px 24px;
  border-radius: 16px;
  border: 2px solid rgba(255, 255, 255, 0.12);
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.7);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  text-align: center;
  transform: scale(0.8);
  opacity: 0;
  transition: all 0.4s cubic-bezier(0.68, -0.55, 0.265, 1.55);
  pointer-events: auto;
  min-width: 280px;
  max-width: 90vw;
}

.toast.show {
  transform: scale(1);
  opacity: 1;
}

.toast-icon {
  font-size: 2.5rem;
}

.toast-message {
  font-weight: 600;
  font-size: 1rem;
}

.toast-details {
  font-size: 0.8rem;
  color: var(--text-muted);
}

/* ✅ CANVAS ESCONDIDO (SEM CONFETTI) */
.confetti-canvas {
  display: none !important;
}

/* ========================================= MODAL LIMITE ========================================= */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.8);
  backdrop-filter: blur(10px);
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 0.3s ease;
  padding: 20px;
  pointer-events: none;
}

.modal-overlay.show {
  opacity: 1;
  pointer-events: auto;
}

.modal-content {
  background: rgba(20, 20, 30, 0.98);
  border: 2px solid rgba(255, 255, 255, 0.12);
  border-radius: 16px;
  padding: 24px;
  max-width: 320px;
  width: 100%;
  text-align: center;
  transform: scale(0.9);
  transition: transform 0.3s ease;
}

.modal-overlay.show .modal-content {
  transform: scale(1);
}

.modal-icon {
  font-size: 3rem;
  margin-bottom: 12px;
}

.modal-content h2 {
  font-family: var(--font-serif);
  color: var(--gold-text);
  font-size: 1.2rem;
  margin-bottom: 12px;
}

.modal-content p {
  color: var(--text-muted);
  font-size: 0.85rem;
  margin-bottom: 10px;
}

.modal-categoria {
  background: rgba(255, 215, 0, 0.12);
  border: 1px solid rgba(255, 215, 0, 0.2);
  color: var(--gold-text);
  padding: 8px 12px;
  border-radius: 8px;
  margin: 12px 0;
  font-weight: 600;
}

.modal-info {
  font-size: 0.75rem;
  color: var(--error-color);
}

.modal-btn {
  width: 100%;
  padding: 10px;
  background: var(--gold-text);
  color: #000;
  border: none;
  border-radius: 8px;
  font-weight: 700;
  text-transform: uppercase;
  cursor: pointer;
  margin-top: 16px;
  transition: all 0.2s ease;
}

.modal-btn:hover {
  background: #e6c200;
  box-shadow: 0 3px 10px rgba(255, 215, 0, 0.2);
}

/* ========================================= LOADING ========================================= */
.loading-state {
  text-align: center;
  padding: 40px 20px;
}

.spinner {
  border: 3px solid rgba(255, 215, 0, 0.1);
  border-top: 3px solid var(--gold-text);
  border-radius: 50%;
  width: 40px;
  height: 40px;
  animation: spin 1s linear infinite;
  margin: 0 auto 16px;
}

/* ========================================= FOOTER ========================================= */
.footer {
  text-align: center;
  padding: 16px 12px;
  margin-top: 16px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  color: var(--text-muted);
  font-size: 0.65rem;
}

/* ========================================= RESPONSIVIDADE ========================================= */
@media (max-width: 599px) {
  .logo-box.logo-dsng,
  .logo-box.logo-kreativuz {
    position: relative;
  }

  .header-container-logo {
    min-height: 40px;
  }

  .header h1 {
    font-size: 1.15rem;
  }
}

@media (min-width: 600px) and (max-width: 900px) {
  html { font-size: 15px; }
  
  .container { 
    padding-left: 12px !important;
    padding-right: 12px !important;
  }
  
  .header h1 {
    font-size: 1.3rem;
  }
  
  .sidebar {
    max-height: 300px;
    top: 75px;
  }
  
  #navCategorias {
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
  }
  
  .nav-link {
    padding: 8px 10px;
    font-size: 0.75rem;
  }
  
  .candidato-card {
    width: 220px;
  }
  
  .card-visual {
    height: 130px;
  }
  
  .foto-wrapper {
    width: 80px;
    height: 80px;
  }
}

@media (min-width: 901px) {
  html { font-size: 16px; }
  
  body {
    overflow-y: auto;
  }
  
  .container {
    max-width: 1400px;
    padding-left: 20px !important;
    padding-right: 20px !important;
    margin: 0 auto;
  }
  
  .header h1 {
    font-size: 1.4rem;
  }
  
  .logo-box {
    width: 42px;
    height: 42px;
  }
  
  .main-layout {
    display: grid;
    grid-template-columns: 320px 1fr;
    gap: 30px;
    align-items: start;
  }
  
  .sidebar {
    position: sticky;
    top: 20px;
    max-height: calc(100vh - 40px);
    margin: 0;
  }
  
  #navCategorias {
    grid-template-columns: 1fr;
    gap: 8px;
  }
  
  .candidatos-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  }
}

/* ========================================= ANIMAÇÕES ========================================= */
@keyframes spin {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.6; }
}

@keyframes heartbeat {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.1); }
}

/* --- CONTROLE DE VISIBILIDADE (ADMIN) --- */

/* Ocultar Número de Votos */
body.ocultar-votos .votos-count {
  display: none !important;
}

/* Ocultar Barra de Progresso e Percentagem */
body.ocultar-barra .progress-track,
body.ocultar-barra .percent-badge {
  display: none !important;
}
body.ocultar-barra .info-bottom {
  margin-top: 15px; /* Ajuste visual quando a barra some */
}

/* Ocultar Ranking/Medalhas (#1, #2, #3) */
body.ocultar-ranking .medal {
  display: none !important;
}

/* Ocultar Estatísticas Globais (Header) */
body.ocultar-stats .stats-bar {
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease;
}

/* Ocultar Badges de Votos Restantes (Opcional - para suspense total) */
body.ocultar-votos .nav-badge, 
body.ocultar-votos .votos-restantes-badge {
  display: none !important; 
}