/* ==========================================
   NEMESIS PROTOCOL // PROJETO NEMESIS
========================================== */

/* Overlay escuro que congela tudo */
.nemesis-freeze-overlay {
  position: fixed;
  inset: 0;
  z-index: 80000;
  background: rgba(0, 0, 0, 0.97);
  opacity: 0;
  transition: opacity 0.8s ease;
  pointer-events: none;
}

.nemesis-freeze-overlay.active {
  opacity: 1;
  pointer-events: all;
}

/* Console central do Projeto Nemesis */
.nemesis-console {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: min(90vw, 700px);
  z-index: 80001;
  background: linear-gradient(
    180deg,
    rgba(20, 0, 0, 0.98) 0%,
    rgba(5, 0, 0, 0.99) 100%
  );
  border: 1px solid rgba(255, 0, 0, 0.4);
  border-radius: 4px;
  box-shadow:
    0 0 60px rgba(255, 0, 0, 0.15),
    0 0 120px rgba(0, 0, 0, 0.9),
    inset 0 0 80px rgba(0, 0, 0, 0.8);
  opacity: 0;
  transform: translate(-50%, -50%) scale(0.9);
  transition:
    opacity 0.5s ease,
    transform 0.5s ease;
  overflow: hidden;
}

.nemesis-console.active {
  opacity: 1;
  transform: translate(-50%, -50%) scale(1);
}

.nemesis-console::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(rgba(255, 0, 0, 0.03) 50%, transparent 50%);
  background-size: 100% 4px;
  pointer-events: none;
  z-index: 1;
}

/* Header do console */
.nemesis-console-header {
  padding: 12px 20px;
  background: linear-gradient(
    90deg,
    rgba(139, 0, 0, 0.5) 0%,
    rgba(50, 0, 0, 0.3) 100%
  );
  border-bottom: 1px solid rgba(255, 0, 0, 0.3);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.nemesis-console-title {
  font-family: var(--font-mono);
  font-size: 12px;
  color: #ff4444;
  letter-spacing: 3px;
  text-shadow: 0 0 10px rgba(255, 0, 0, 0.5);
}

.nemesis-console-status {
  font-family: var(--font-mono);
  font-size: 10px;
  color: var(--caution);
  letter-spacing: 2px;
  animation: blink 1s infinite;
}

/* Body do console */
.nemesis-console-body {
  padding: 20px;
  min-height: 350px;
  max-height: 60vh;
  overflow-y: auto;
  font-family: var(--font-mono);
  font-size: 12px;
  line-height: 1.8;
  color: #aaa;
  position: relative;
  z-index: 2;
}

.nemesis-console-body::-webkit-scrollbar {
  width: 4px;
}

.nemesis-console-body::-webkit-scrollbar-track {
  background: rgba(255, 0, 0, 0.1);
}

.nemesis-console-body::-webkit-scrollbar-thumb {
  background: rgba(255, 0, 0, 0.4);
}

/* Linhas do console */
.nem-line {
  margin-bottom: 3px;
  opacity: 0;
  transform: translateX(-10px);
  animation: nem-line-appear 0.3s ease forwards;
}

@keyframes nem-line-appear {
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

.nem-line.success {
  color: var(--fine);
}
.nem-line.warning {
  color: var(--caution);
}
.nem-line.error {
  color: var(--danger);
  text-shadow: 0 0 8px rgba(255, 0, 0, 0.5);
}
.nem-line.system {
  color: #888;
}
.nem-line.highlight {
  color: #fff;
  font-weight: bold;
  text-shadow: 0 0 10px rgba(255, 255, 255, 0.3);
}
.nem-line.classified {
  color: #ff3333;
  font-weight: bold;
  letter-spacing: 2px;
  text-shadow: 0 0 15px rgba(255, 0, 0, 0.6);
}

/* Barra de progresso do console */
.nem-progress-container {
  margin: 15px 0;
  padding: 10px 0;
}

.nem-progress-label {
  font-size: 10px;
  color: #666;
  letter-spacing: 2px;
  margin-bottom: 8px;
}

.nem-progress-bar {
  width: 100%;
  height: 6px;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 0, 0, 0.3);
  border-radius: 3px;
  overflow: hidden;
}

.nem-progress-fill {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, var(--danger) 0%, #ff6600 100%);
  box-shadow: 0 0 15px var(--danger);
  transition: width 0.3s ease;
}

/* Seção de diretivas */
.nem-directive-box {
  margin: 20px 0;
  padding: 15px;
  background: rgba(139, 0, 0, 0.15);
  border: 1px solid rgba(255, 0, 0, 0.3);
  border-left: 3px solid var(--danger);
}

.nem-directive-title {
  font-size: 11px;
  color: var(--danger);
  letter-spacing: 3px;
  margin-bottom: 12px;
  text-shadow: 0 0 10px rgba(255, 0, 0, 0.4);
}

.nem-directive-item {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin-bottom: 8px;
  font-size: 11px;
}

.nem-directive-bullet {
  color: var(--danger);
  font-weight: bold;
}

.nem-directive-text {
  color: #ccc;
  flex: 1;
}

.nem-directive-text.primary {
  color: #fff;
  font-weight: bold;
  text-shadow: 0 0 8px rgba(255, 255, 255, 0.3);
}

/* Seção de target */
.nem-target-box {
  margin: 20px 0;
  padding: 20px;
  text-align: center;
  background: repeating-linear-gradient(
    45deg,
    rgba(139, 0, 0, 0.1),
    rgba(139, 0, 0, 0.1) 10px,
    transparent 10px,
    transparent 20px
  );
  border: 2px solid var(--danger);
  animation: target-pulse 1s infinite;
}

@keyframes target-pulse {
  0%,
  100% {
    border-color: rgba(255, 0, 0, 0.5);
    box-shadow: 0 0 20px rgba(255, 0, 0, 0.1);
  }
  50% {
    border-color: rgba(255, 0, 0, 1);
    box-shadow: 0 0 40px rgba(255, 0, 0, 0.3);
  }
}

.nem-target-label {
  font-size: 10px;
  color: #888;
  letter-spacing: 3px;
  margin-bottom: 10px;
}

.nem-target-name {
  font-family: var(--font-ui);
  font-size: 42px;
  font-weight: 700;
  color: var(--danger);
  letter-spacing: 12px;
  text-shadow:
    0 0 30px var(--danger),
    0 0 60px rgba(255, 0, 0, 0.4);
  animation: target-flicker 0.1s infinite;
}

@keyframes target-flicker {
  0%,
  90%,
  100% {
    opacity: 1;
  }
  92%,
  94%,
  96% {
    opacity: 0.8;
  }
}

@keyframes static-flicker {
  0%,
  100% {
    opacity: 0.3;
  }
  25% {
    opacity: 0.5;
  }
  50% {
    opacity: 0.2;
  }
  75% {
    opacity: 0.6;
  }
}

/* Tela de ativação */
.nemesis-activation-screen {
  position: fixed;
  inset: 0;
  z-index: 85000;
  background: #000;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.5s ease;
}

.nemesis-activation-screen.active {
  opacity: 1;
  pointer-events: all;
}

.activation-icon {
  font-size: 100px;
  color: var(--danger);
  text-shadow:
    0 0 50px var(--danger),
    0 0 100px var(--danger);
  margin-bottom: 30px;
  animation: activation-throb 0.8s ease-in-out infinite;
}

@keyframes activation-throb {
  0%,
  100% {
    transform: scale(1);
    opacity: 0.8;
  }
  50% {
    transform: scale(1.1);
    opacity: 1;
  }
}

.activation-title {
  font-family: var(--font-ui);
  font-size: 52px;
  font-weight: 700;
  color: #fff;
  letter-spacing: 15px;
  text-shadow: 0 0 30px rgba(255, 255, 255, 0.5);
  margin-bottom: 10px;
}

.activation-subtitle {
  font-family: var(--font-mono);
  font-size: 14px;
  color: var(--danger);
  letter-spacing: 8px;
  text-shadow: 0 0 20px var(--danger);
  animation: blink 0.5s infinite;
}

/* Flash e efeitos */
.nemesis-flash {
  position: fixed;
  inset: 0;
  z-index: 99999;
  pointer-events: none;
  opacity: 0;
  background: #fff;
}

/* Crash screen */
.nemesis-crash {
  position: fixed;
  inset: 0;
  z-index: 90000;
  background: #000;
  padding: 40px;
  opacity: 0;
  pointer-events: none;
  font-family: var(--font-mono);
  font-size: 13px;
  color: #ff3333;
  line-height: 1.7;
  overflow: hidden;
  white-space: pre-wrap;
}

.nemesis-crash.active {
  opacity: 1;
}

.crash-cursor {
  display: inline-block;
  width: 8px;
  height: 14px;
  background: #ff3333;
  animation: blink 0.8s infinite;
  vertical-align: text-bottom;
  margin-left: 2px;
}

@media (max-width: 950px) {
  .nemesis-console {
    width: 95vw;
  }

  .nemesis-console-body {
    padding: 15px;
    font-size: 10px;
    min-height: 300px;
  }

  .nem-target-name {
    font-size: 28px;
    letter-spacing: 8px;
  }

  .activation-icon {
    font-size: 60px;
  }

  .activation-title {
    font-size: 32px;
    letter-spacing: 8px;
  }

  .activation-subtitle {
    font-size: 11px;
    letter-spacing: 4px;
  }

  .nemesis-crash {
    padding: 20px;
    font-size: 10px;
  }
}
