/* ══════════════════════════════════════════════════════
   missoes.css — Embaixada Destaque · DCER Capixaba
   Todas as classes usam prefixo ms- para não colidir
   com style.css
   ══════════════════════════════════════════════════════ */

/* ─── RESET INTERNO ─────────────────────────────────── */
.ms-hero *, .ms-pts-banner *,
.ms-section *, .ms-projeto-bg *,
.ms-ranking-bg *, .ms-modal-overlay * {
  box-sizing: border-box;
}

/* ─── HERO ──────────────────────────────────────────── */
.ms-hero {
  background: linear-gradient(135deg, #0a1628 0%, #1e4db7 55%, #0a1628 100%);
  padding: 100px 24px 64px;
  text-align: center;
  position: relative;
  overflow: hidden;
  margin-top: 68px; /* altura da navbar */
}
.ms-hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.03'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
  pointer-events: none;
}

.ms-hero-tag {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(245, 197, 24, .15);
  border: 1px solid rgba(245, 197, 24, .4);
  border-radius: 30px;
  padding: 6px 18px;
  color: #f5c518;
  font-size: .78rem;
  font-weight: 700;
  letter-spacing: .08em;
  margin-bottom: 20px;
  position: relative;
}

.ms-hero h1 {
  font-size: clamp(2rem, 5vw, 3.2rem);
  font-weight: 900;
  color: #fff;
  line-height: 1.15;
  margin-bottom: 14px;
  position: relative;
  font-family: 'Poppins', sans-serif;
}
.ms-hero h1 span { color: #f5c518; }

.ms-hero p {
  color: rgba(255, 255, 255, .75);
  font-size: 1rem;
  max-width: 560px;
  margin: 0 auto 32px;
  line-height: 1.7;
  position: relative;
}

.ms-hero-badges {
  display: flex;
  justify-content: center;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 36px;
  position: relative;
}
.ms-badge {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  background: rgba(255, 255, 255, .1);
  border: 1px solid rgba(255, 255, 255, .2);
  border-radius: 30px;
  padding: 7px 16px;
  color: rgba(255, 255, 255, .85);
  font-size: .78rem;
  font-weight: 600;
}

.ms-hero-stats {
  display: flex;
  justify-content: center;
  gap: 40px;
  flex-wrap: wrap;
  position: relative;
}
.ms-stat { text-align: center; }
.ms-stat strong {
  display: block;
  font-size: 2rem;
  font-weight: 900;
  color: #f5c518;
}
.ms-stat span {
  font-size: .75rem;
  color: rgba(255, 255, 255, .65);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .05em;
}

/* ─── BANNER AVISO ─────────────────────────────────── */
.ms-pts-banner {
  background: linear-gradient(90deg, #f5c518, #f59e0b);
  padding: 14px 24px;
  text-align: center;
}
.ms-pts-banner p {
  font-size: .9rem;
  font-weight: 700;
  color: #0a1628;
  margin: 0;
}

/* ─── SECTION WRAPPER ──────────────────────────────── */
.ms-section {
  padding: 60px 0;
}
.ms-bg-light { background: #f0f4ff; }
.ms-bg-white { background: #fff; }

.ms-container {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 20px;
}
.ms-container-sm {
  max-width: 800px;
  margin: 0 auto;
  padding: 0 20px;
}

/* Tags / rótulos de seção */
.ms-tag {
  display: inline-block;
  background: #e8f0fe;
  color: #1e4db7;
  font-size: .72rem;
  font-weight: 800;
  letter-spacing: .1em;
  padding: 5px 14px;
  border-radius: 20px;
  margin-bottom: 12px;
  text-transform: uppercase;
}
.ms-tag-gold {
  background: rgba(245, 197, 24, .15);
  color: #f5c518;
  border: 1px solid rgba(245, 197, 24, .3);
}

.ms-section-title {
  font-size: clamp(1.5rem, 3vw, 2rem);
  font-weight: 900;
  color: #0d1b35;
  margin-bottom: 8px;
  font-family: 'Poppins', sans-serif;
}
.ms-section-title span { color: #1e4db7; }
.ms-section-title.ms-white { color: #fff; }

.ms-section-sub {
  font-size: .9rem;
  color: #64748b;
  line-height: 1.65;
  max-width: 620px;
}

/* ─── COMO FUNCIONA ───────────────────────────────── */
.ms-how-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  margin-top: 36px;
}
.ms-how-card {
  background: #fff;
  border-radius: 16px;
  padding: 24px 20px;
  border: 1px solid #e2eaf8;
  text-align: center;
}
.ms-how-icon {
  width: 56px;
  height: 56px;
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  margin: 0 auto 14px;
}
.ms-hi-blue   { background: #dbeafe; color: #1e4db7; }
.ms-hi-gold   { background: #fef9c3; color: #d97706; }
.ms-hi-green  { background: #d1fae5; color: #059669; }
.ms-hi-purple { background: #ede9fe; color: #7c3aed; }

.ms-how-card h3 {
  font-size: .9rem;
  font-weight: 800;
  color: #0d1b35;
  margin-bottom: 6px;
}
.ms-how-card p {
  font-size: .78rem;
  color: #64748b;
  line-height: 1.6;
}
.ms-how-meta {
  display: flex;
  justify-content: center;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 10px;
}
.ms-ht {
  font-size: .68rem;
  font-weight: 700;
  padding: 3px 10px;
  border-radius: 20px;
}
.ms-ht-blue   { background: #dbeafe; color: #1e40af; }
.ms-ht-gold   { background: #fef3c7; color: #92400e; }
.ms-ht-green  { background: #d1fae5; color: #065f46; }
.ms-ht-purple { background: #ede9fe; color: #5b21b6; }

/* ─── PROJETO DO MÊS ──────────────────────────────── */
.ms-projeto-bg {
  background: linear-gradient(135deg, #0a1628, #1e3a8a);
  padding: 60px 0;
}

/* Skeleton loader */
.ms-projeto-skeleton {
  animation: ms-pulse 1.4s ease-in-out infinite;
}
.ms-skeleton-box {
  background: rgba(255, 255, 255, .07);
}
.ms-rank-skeleton {
  background: rgba(255, 255, 255, .06);
  animation: ms-pulse 1.4s ease-in-out infinite;
}
@keyframes ms-pulse {
  0%, 100% { opacity: 1; }
  50%       { opacity: .45; }
}

.ms-projeto-card {
  background: rgba(255, 255, 255, .06);
  border: 1px solid rgba(255, 255, 255, .12);
  border-radius: 20px;
  padding: 32px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 32px;
  align-items: center;
}
.ms-projeto-img {
  border-radius: 14px;
  overflow: hidden;
  aspect-ratio: 16 / 9;
  background: linear-gradient(135deg, #1e4db7, #3b82f6);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 3rem;
}
.ms-projeto-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.ms-projeto-info { /* right column */ }
.ms-projeto-label {
  font-size: .72rem;
  font-weight: 800;
  color: #f5c518;
  letter-spacing: .1em;
  text-transform: uppercase;
  margin-bottom: 10px;
}
.ms-projeto-title {
  font-size: 1.4rem;
  font-weight: 900;
  color: #fff;
  margin-bottom: 12px;
  font-family: 'Poppins', sans-serif;
}
.ms-projeto-desc {
  font-size: .88rem;
  color: rgba(255, 255, 255, .72);
  line-height: 1.7;
  margin-bottom: 24px;
}
.ms-pix-box {
  background: rgba(245, 197, 24, .12);
  border: 1px solid rgba(245, 197, 24, .3);
  border-radius: 12px;
  padding: 16px 20px;
  display: flex;
  align-items: center;
  gap: 14px;
}
.ms-pix-icon { font-size: 1.5rem; }
.ms-pix-label {
  font-size: .7rem;
  color: rgba(255, 255, 255, .55);
  font-weight: 700;
  text-transform: uppercase;
  margin-bottom: 3px;
}
.ms-pix-key {
  font-size: .9rem;
  color: #f5c518;
  font-weight: 700;
  font-family: monospace;
  letter-spacing: .04em;
}
.ms-pix-value {
  font-size: .78rem;
  color: rgba(255, 255, 255, .6);
  margin-top: 4px;
}

/* ─── RANKING ─────────────────────────────────────── */
.ms-ranking-bg {
  background: #0a1628;
  padding: 60px 0;
}
.ms-ranking-header {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  margin-bottom: 32px;
  flex-wrap: wrap;
  gap: 16px;
}
.ms-ranking-sup {
  font-size: .75rem;
  color: rgba(255, 255, 255, .45);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .08em;
  margin-bottom: 6px;
}
.ms-ranking-title {
  font-size: 1.8rem;
  font-weight: 900;
  color: #fff;
  font-family: 'Poppins', sans-serif;
}
.ms-ranking-title span { color: #f5c518; }

.ms-btn-ver-todas {
  background: rgba(255, 255, 255, .08);
  border: 1px solid rgba(255, 255, 255, .15);
  color: #fff;
  padding: 9px 20px;
  border-radius: 50px;
  font-size: .82rem;
  font-weight: 600;
  cursor: pointer;
  font-family: 'Poppins', sans-serif;
  transition: background .2s;
}
.ms-btn-ver-todas:hover {
  background: rgba(255, 255, 255, .14);
}

.ms-ranking-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

/* Linha do ranking */
.ms-ranking-item {
  background: rgba(255, 255, 255, .05);
  border: 1px solid rgba(255, 255, 255, .08);
  border-radius: 14px;
  padding: 16px 20px;
  display: flex;
  align-items: center;
  gap: 16px;
}
.ms-ranking-item.ms-top1 {
  background: linear-gradient(90deg, rgba(245,197,24,.15), rgba(245,197,24,.05));
  border-color: rgba(245, 197, 24, .3);
}
.ms-ranking-item.ms-top2 {
  background: linear-gradient(90deg, rgba(192,192,192,.12), rgba(192,192,192,.04));
  border-color: rgba(192, 192, 192, .25);
}
.ms-ranking-item.ms-top3 {
  background: linear-gradient(90deg, rgba(205,127,50,.12), rgba(205,127,50,.04));
  border-color: rgba(205, 127, 50, .25);
}

/* Posição */
.ms-rank-pos {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 900;
  font-size: .9rem;
  flex-shrink: 0;
}
.ms-rp1     { background: #f5c518; color: #0a1628; }
.ms-rp2     { background: #cbd5e1; color: #0a1628; }
.ms-rp3     { background: #cd7f32; color: #fff; }
.ms-rp-other { background: rgba(255,255,255,.08); color: rgba(255,255,255,.5); font-size: .8rem; }

/* Info da embaixada */
.ms-rank-info { flex: 1; min-width: 0; }
.ms-rank-church {
  font-size: .92rem;
  font-weight: 700;
  color: #fff;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.ms-rank-daer {
  font-size: .74rem;
  color: rgba(255, 255, 255, .45);
}
.ms-rank-tasks {
  margin-top: 6px;
  display: flex;
  gap: 5px;
  align-items: center;
  flex-wrap: wrap;
}
.ms-task-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
}
.ms-td-done    { background: #22c55e; }
.ms-td-pending { background: rgba(255,255,255,.15); }
.ms-rank-task-count {
  font-size: .68rem;
  color: rgba(255, 255, 255, .4);
  margin-left: 4px;
}

/* Pontos e badge */
.ms-rank-right { text-align: right; flex-shrink: 0; }
.ms-rank-pts strong {
  display: block;
  font-size: 1.1rem;
  font-weight: 900;
  color: #f5c518;
}
.ms-rank-pts span {
  font-size: .7rem;
  color: rgba(255, 255, 255, .4);
}
.ms-rank-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: rgba(245, 197, 24, .15);
  border: 1px solid rgba(245, 197, 24, .3);
  border-radius: 20px;
  padding: 3px 10px;
  font-size: .68rem;
  font-weight: 700;
  color: #f5c518;
  margin-top: 4px;
}

/* ─── CADASTRO ───────────────────────────────────── */
.ms-cadastro-card {
  background: #f8faff;
  border: 1px solid #dce8ff;
  border-radius: 20px;
  padding: 32px 28px;
}

.ms-form-info {
  background: #fef9c3;
  border: 1px solid #fde68a;
  border-radius: 10px;
  padding: 12px 14px;
  font-size: .78rem;
  color: #78350f;
  display: flex;
  gap: 10px;
  align-items: flex-start;
  margin-bottom: 20px;
}
.ms-form-info i { color: #d97706; margin-top: 1px; flex-shrink: 0; }
.ms-form-info a { color: #1e4db7; font-weight: 600; text-decoration: none; }
.ms-form-info a:hover { text-decoration: underline; }

/* Avisos */
.ms-aviso-duplicata {
  background: #fef2f2;
  border: 1px solid #fca5a5;
  border-radius: 12px;
  padding: 14px 16px;
  margin-bottom: 16px;
  display: flex;
  gap: 10px;
  align-items: flex-start;
}
.ms-aviso-duplicata i { color: #dc2626; margin-top: 2px; flex-shrink: 0; }
.ms-aviso-duplicata strong { color: #991b1b; font-size: .82rem; }
.ms-aviso-duplicata span  { font-size: .78rem; color: #7f1d1d; line-height: 1.5; }
.ms-aviso-duplicata a     { color: #dc2626; font-weight: 700; text-decoration: none; }

.ms-aviso-sucesso {
  background: #f0fdf4;
  border: 1px solid #86efac;
  border-radius: 12px;
  padding: 14px 16px;
  margin-bottom: 16px;
  display: flex;
  gap: 10px;
  align-items: flex-start;
}
.ms-aviso-sucesso i      { color: #16a34a; margin-top: 2px; flex-shrink: 0; }
.ms-aviso-sucesso strong { color: #166534; font-size: .82rem; }
.ms-aviso-sucesso span   { font-size: .78rem; color: #15803d; line-height: 1.5; }

.ms-form-erro {
  background: #fef2f2;
  border: 1px solid #fca5a5;
  border-radius: 10px;
  padding: 10px 14px;
  font-size: .82rem;
  color: #dc2626;
  font-weight: 600;
}

.ms-form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-bottom: 16px;
}

/* Campo genérico */
.ms-field { position: relative; }
.ms-field label {
  display: block;
  font-size: .72rem;
  font-weight: 700;
  color: #1e4db7;
  text-transform: uppercase;
  letter-spacing: .05em;
  margin-bottom: 5px;
}
.ms-field input,
.ms-field select,
.ms-field textarea {
  width: 100%;
  padding: 11px 14px;
  border: 1.5px solid #c5d3f0;
  border-radius: 10px;
  font-size: .9rem;
  color: #0d1b35;
  font-family: 'Poppins', sans-serif;
  background: #fff;
  transition: border-color .2s, box-shadow .2s;
}
.ms-field input:focus,
.ms-field select:focus,
.ms-field textarea:focus {
  outline: none;
  border-color: #1e4db7;
  box-shadow: 0 0 0 3px rgba(30, 77, 183, .1);
}
.ms-field-hint {
  font-size: .68rem;
  color: #94a3b8;
  margin-top: 4px;
  display: block;
}

/* Botões */
.ms-btn-primary {
  width: 100%;
  padding: 14px;
  background: linear-gradient(135deg, #1e4db7, #2563eb);
  color: #fff;
  border: none;
  border-radius: 12px;
  font-size: 1rem;
  font-weight: 800;
  font-family: 'Poppins', sans-serif;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin-top: 8px;
  transition: opacity .2s;
}
.ms-btn-primary:hover  { opacity: .92; }
.ms-btn-primary:disabled {
  opacity: .5;
  cursor: not-allowed;
}

.ms-btn-secondary {
  padding: 10px 24px;
  background: transparent;
  border: 1.5px solid #c5d3f0;
  border-radius: 50px;
  font-size: .88rem;
  font-weight: 700;
  font-family: 'Poppins', sans-serif;
  color: #1e4db7;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  transition: background .2s, border-color .2s;
}
.ms-btn-secondary:hover {
  background: #e8f0fe;
  border-color: #1e4db7;
}

/* ─── TAREFAS ─────────────────────────────────────── */
.ms-tarefas-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-top: 36px;
}

.ms-tarefa-card {
  background: #fff;
  border-radius: 16px;
  overflow: hidden;
  border: 1px solid #e2eaf8;
  transition: box-shadow .2s;
}
.ms-tarefa-card:hover {
  box-shadow: 0 4px 24px rgba(30, 77, 183, .1);
}
.ms-tarefa-card.ms-encerrada {
  opacity: .6;
}
.ms-tarefa-card.ms-em-breve {
  opacity: .72;
}

.ms-tarefa-header {
  padding: 20px 20px 14px;
  display: flex;
  align-items: flex-start;
  gap: 14px;
}
.ms-tarefa-icon {
  width: 48px;
  height: 48px;
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.3rem;
  flex-shrink: 0;
}

/* Cores dos ícones das tarefas */
.ms-ti-blue   { background: #dbeafe; color: #1e4db7; }
.ms-ti-gold   { background: #fef9c3; color: #d97706; }
.ms-ti-green  { background: #d1fae5; color: #059669; }
.ms-ti-purple { background: #ede9fe; color: #7c3aed; }
.ms-ti-gray   { background: #f1f5f9; color: #94a3b8; }
.ms-ti-red    { background: #fee2e2; color: #dc2626; }

.ms-tarefa-info h3 {
  font-size: .95rem;
  font-weight: 800;
  color: #0d1b35;
  margin-bottom: 3px;
  font-family: 'Poppins', sans-serif;
}
.ms-tarefa-info h3.ms-text-muted { color: #94a3b8; }
.ms-tarefa-info p {
  font-size: .78rem;
  color: #64748b;
  line-height: 1.5;
}

.ms-tarefa-body {
  padding: 0 20px 20px;
}

.ms-tarefa-progress-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 6px;
}
.ms-tarefa-progress-label {
  font-size: .72rem;
  color: #64748b;
  font-weight: 600;
}
.ms-tarefa-progress-val {
  font-size: .72rem;
  color: #1e4db7;
  font-weight: 800;
}

.ms-progress-bar {
  background: #e8f0fe;
  border-radius: 50px;
  height: 8px;
  overflow: hidden;
  margin-bottom: 14px;
}
.ms-progress-fill {
  height: 100%;
  border-radius: 50px;
  background: linear-gradient(90deg, #1e4db7, #3b82f6);
  transition: width .6s ease;
}
.ms-pf-green  { background: linear-gradient(90deg, #059669, #34d399); }
.ms-pf-purple { background: linear-gradient(90deg, #7c3aed, #a78bfa); }
.ms-pf-gold   { background: linear-gradient(90deg, #d97706, #fbbf24); }

.ms-tarefa-dates {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 12px;
}
.ms-tarefa-date {
  display: flex;
  align-items: center;
  gap: 5px;
  font-size: .72rem;
  color: #64748b;
  background: #f8faff;
  border: 1px solid #e2eaf8;
  padding: 4px 10px;
  border-radius: 20px;
}

/* Badges de status */
.ms-status-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 12px;
  border-radius: 20px;
  font-size: .74rem;
  font-weight: 700;
  margin-bottom: 10px;
}
.ms-sb-open   { background: #d1fae5; color: #065f46; }
.ms-sb-soon   { background: #e0e7ff; color: #3730a3; }
.ms-sb-closed { background: #fee2e2; color: #991b1b; }

/* Botão da tarefa */
.ms-tarefa-btn {
  width: 100%;
  padding: 10px;
  border: none;
  border-radius: 10px;
  font-size: .85rem;
  font-weight: 700;
  font-family: 'Poppins', sans-serif;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  transition: opacity .2s;
}
.ms-tb-active {
  background: linear-gradient(135deg, #1e4db7, #2563eb);
  color: #fff;
}
.ms-tb-active:hover  { opacity: .9; }
.ms-tb-disabled {
  background: #f1f5f9;
  color: #94a3b8;
  cursor: not-allowed;
}

/* ─── MODAL — ENVIAR EVIDÊNCIAS ──────────────────── */
.ms-modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(10, 22, 40, .75);
  z-index: 9000;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  padding: 90px 20px 40px;
  overflow-y: auto;
  backdrop-filter: blur(4px);
}
.ms-modal-box {
  background: #fff;
  border-radius: 24px;
  width: 100%;
  max-width: 600px;
  max-height: 80vh;
  overflow-y: auto;
  box-shadow: 0 24px 80px rgba(0, 0, 0, .35);
  scroll-behavior: smooth;
  margin: auto;
}

/* Header do modal */
.ms-modal-header {
  background: linear-gradient(135deg, #0a1628, #1e4db7);
  border-radius: 24px 24px 0 0;
  padding: 24px 28px;
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}
.ms-modal-tag {
  font-size: .68rem;
  font-weight: 800;
  color: rgba(245, 197, 24, .9);
  text-transform: uppercase;
  letter-spacing: .1em;
  margin-bottom: 4px;
}
.ms-modal-header h3 {
  font-size: 1.1rem;
  font-weight: 900;
  color: #fff;
  font-family: 'Poppins', sans-serif;
}
.ms-modal-close {
  background: rgba(255, 255, 255, .12);
  border: none;
  color: #fff;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  cursor: pointer;
  font-size: 1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: background .2s;
}
.ms-modal-close:hover { background: rgba(255, 255, 255, .22); }

/* Corpo */
.ms-modal-body { padding: 24px 28px; }

.ms-modal-label {
  font-size: .72rem;
  font-weight: 800;
  color: #1e4db7;
  text-transform: uppercase;
  letter-spacing: .08em;
  margin-bottom: 10px;
  display: flex;
  align-items: center;
  gap: 6px;
}
.ms-divider {
  border: none;
  border-top: 1px solid #e8edf8;
  margin: 20px 0;
}

/* Upload */
.ms-upload-area {
  border: 2px dashed #c5d3f0;
  border-radius: 14px;
  padding: 28px 20px;
  text-align: center;
  cursor: pointer;
  transition: border-color .2s, background .2s;
  margin-bottom: 8px;
}
.ms-upload-area:hover {
  border-color: #1e4db7;
  background: #f0f4ff;
}
.ms-upload-icon {
  font-size: 2rem;
  margin-bottom: 8px;
  color: #1e4db7;
  display: block;
}
.ms-upload-area strong {
  display: block;
  font-size: .9rem;
  font-weight: 700;
  color: #0d1b35;
  margin-bottom: 4px;
}
.ms-upload-area span {
  display: block;
  font-size: .75rem;
  color: #94a3b8;
}
.ms-upload-hint {
  font-size: .7rem;
  color: #94a3b8;
  text-align: center;
  margin-bottom: 0;
}

/* Preview de fotos */
.ms-fotos-preview {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 4px;
}
.ms-foto-thumb {
  width: 72px;
  height: 72px;
  border-radius: 8px;
  object-fit: cover;
  border: 2px solid #c5d3f0;
}

/* Preview nome de arquivo */
.ms-arquivo-preview {
  font-size: .78rem;
  color: #1e4db7;
  font-weight: 600;
  background: #e8f0fe;
  border-radius: 8px;
  padding: 6px 12px;
  margin-bottom: 4px;
  display: flex;
  align-items: center;
  gap: 6px;
}

/* Contador de caracteres */
.ms-char-count {
  font-size: .7rem;
  font-weight: 400;
  color: #94a3b8;
  text-transform: none;
  letter-spacing: 0;
  margin-left: 6px;
}
.ms-char-count.quase { color: #f59e0b; }
.ms-char-count.cheio { color: #ef4444; }

/* LGPD */
.ms-lgpd-box {
  background: #f0f4ff;
  border: 1px solid #c5d3f0;
  border-radius: 12px;
  padding: 14px 16px;
  display: flex;
  align-items: flex-start;
  gap: 12px;
}
.ms-lgpd-box input[type="checkbox"] {
  width: 18px;
  height: 18px;
  margin-top: 1px;
  flex-shrink: 0;
  accent-color: #1e4db7;
  cursor: pointer;
}
.ms-lgpd-text {
  font-size: .78rem;
  color: #374151;
  line-height: 1.6;
  cursor: pointer;
}
.ms-lgpd-text a {
  color: #1e4db7;
  font-weight: 600;
  text-decoration: none;
}
.ms-lgpd-text a:hover { text-decoration: underline; }

/* Rodapé do modal */
.ms-modal-footer {
  padding: 0 28px 28px;
  display: flex;
  gap: 12px;
}
.ms-btn-cancelar {
  flex: 1;
  padding: 12px;
  background: #f1f5f9;
  color: #64748b;
  border: none;
  border-radius: 12px;
  font-size: .9rem;
  font-weight: 700;
  font-family: 'Poppins', sans-serif;
  cursor: pointer;
  transition: background .2s;
}
.ms-btn-cancelar:hover { background: #e2e8f0; }
.ms-btn-enviar {
  flex: 2;
  padding: 12px;
  background: linear-gradient(135deg, #1e4db7, #2563eb);
  color: #fff;
  border: none;
  border-radius: 12px;
  font-size: .9rem;
  font-weight: 800;
  font-family: 'Poppins', sans-serif;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  transition: opacity .2s;
}
.ms-btn-enviar:hover    { opacity: .92; }
.ms-btn-enviar:disabled { opacity: .5; cursor: not-allowed; }

/* Spinner de loading */
.ms-spinner {
  width: 16px;
  height: 16px;
  border: 2px solid rgba(255,255,255,.35);
  border-top-color: #fff;
  border-radius: 50%;
  animation: ms-spin .7s linear infinite;
  display: inline-block;
}
@keyframes ms-spin {
  to { transform: rotate(360deg); }
}

/* ─── RESPONSIVO ─────────────────────────────────── */
@media (max-width: 960px) {
  .ms-how-grid { grid-template-columns: 1fr 1fr; }
  .ms-projeto-card { grid-template-columns: 1fr; }
}
@media (max-width: 720px) {
  .ms-tarefas-grid  { grid-template-columns: 1fr; }
  .ms-form-grid     { grid-template-columns: 1fr; }
  .ms-ranking-title { font-size: 1.4rem; }
}
@media (max-width: 600px) {
  .ms-how-grid       { grid-template-columns: 1fr; }
  .ms-hero-stats     { gap: 24px; }
  .ms-modal-footer   { flex-direction: column; }
  .ms-modal-box      { border-radius: 18px; }
  .ms-modal-header   { border-radius: 18px 18px 0 0; }
  .ms-cadastro-card  { padding: 20px 16px; }
}

/* ══════════════════════════════════════════════════════════
   REGRAS DE DESEMPATE — Botão + Modal
   ══════════════════════════════════════════════════════════ */

/* Wrapper dos dois botões do header do ranking */
.ms-ranking-header-btns {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  align-items: center;
}

/* Botão Regras de Desempate */
.ms-btn-regras {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 10px 18px;
  background: rgba(255,255,255,.1);
  border: 1px solid rgba(255,255,255,.25);
  color: #fff;
  border-radius: 10px;
  font-family: 'Poppins', sans-serif;
  font-size: .82rem;
  font-weight: 600;
  cursor: pointer;
  transition: background .2s, border-color .2s;
  white-space: nowrap;
}
.ms-btn-regras:hover {
  background: rgba(255,255,255,.18);
  border-color: rgba(255,255,255,.45);
}
.ms-btn-regras i { font-size: .85rem; }

/* Modal */
.ms-regras-modal {
  background: #fff;
  border-radius: 20px;
  padding: 32px 28px 28px;
  margin: auto;
  max-width: 520px;
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
  position: relative;
  box-shadow: 0 24px 72px rgba(0,0,0,.3);
  animation: ms-slideUp .25s ease;
}

/* Cabeçalho do modal */
.ms-regras-header {
  text-align: center;
  margin-bottom: 24px;
}
.ms-regras-icon {
  width: 58px;
  height: 58px;
  background: linear-gradient(135deg, #1e4db7, #2563eb);
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 14px;
  font-size: 1.5rem;
  color: #fff;
}
.ms-regras-header h2 {
  font-size: 1.3rem;
  font-weight: 800;
  color: #0a1628;
  margin: 0 0 8px;
}
.ms-regras-header p {
  font-size: .86rem;
  color: #64748b;
  line-height: 1.6;
  margin: 0;
}

/* Lista de regras */
.ms-regras-lista {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-bottom: 20px;
}
.ms-regra-item {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 14px;
  padding: 16px;
  transition: border-color .2s;
}
.ms-regra-item:hover { border-color: #2563eb44; }

.ms-regra-num {
  min-width: 40px;
  height: 40px;
  background: linear-gradient(135deg, #1e4db7, #2563eb);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: .82rem;
  color: #fff;
  flex-shrink: 0;
}
.ms-regra-body {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.ms-regra-body strong {
  font-size: .92rem;
  font-weight: 700;
  color: #0a1628;
}
.ms-regra-body span {
  font-size: .82rem;
  color: #64748b;
  line-height: 1.55;
}
.ms-regra-body em { color: #2563eb; font-style: normal; font-weight: 600; }
.ms-regra-icone {
  font-size: 1.1rem;
  color: #2563eb;
  opacity: .5;
  flex-shrink: 0;
  padding-top: 2px;
}

/* Rodapé informativo */
.ms-regras-footer {
  background: #eff6ff;
  border: 1px solid #bfdbfe;
  border-radius: 12px;
  padding: 12px 16px;
  font-size: .8rem;
  color: #1e40af;
  display: flex;
  align-items: flex-start;
  gap: 8px;
  line-height: 1.55;
}
.ms-regras-footer i { flex-shrink: 0; margin-top: 2px; }

/* Responsivo */
@media (max-width: 600px) {
  .ms-regras-modal   { padding: 24px 16px 20px; border-radius: 18px; }
  .ms-ranking-header-btns { flex-direction: column; align-items: flex-start; }
  .ms-btn-regras     { font-size: .78rem; padding: 8px 14px; }
}
