:root {
  --bg-black: #111112;
  --cyber-blue: #1b4f72;
  --deep-blue: #0b1c2d;
  --text-dim: #6fa3c9;
  --glow: 0 0 6px #1b4f72, 0 0 12px #0b3c5d;
}

/* RESET */
* { margin:0; padding:0; box-sizing:border-box; }

body {
  background:#000;
  color: var(--cyber-blue);
  font-family:'Share Tech Mono', monospace;
  min-height:100vh;
  overflow-x:hidden;
}

/* =========================
   CONTAINER CRT SCANLINES
========================= */
.container {
  position: relative;
  background: rgba(0,0,0,0.95);
  max-width: 900px;
  margin: 40px auto;
  padding: 20px;
  border: 1px solid var(--cyber-blue);
  box-shadow: var(--glow);
  overflow: hidden;
}

.container::before {
  content:"";
  position: absolute;
  inset:0;
  pointer-events: none;
  background: repeating-linear-gradient(
      to bottom,
      rgba(255,255,255,0) 0px,
      rgba(255,255,255,0.03) 1px,
      rgba(255,255,255,0.06) 2px
  );
  z-index: 5;
  animation: scanlineFlicker 0.8s infinite;
}

@keyframes scanlineFlicker {
  0%,100% {opacity: 0.05;}
  50% {opacity: 0.12;}
}

/* =========================
   ASCII HEADER
========================= */
.ascii {
  font-size:0.9rem;
  line-height:1.2;
  letter-spacing:0.5px;
  white-space:pre;
  margin-bottom:20px;
  color:var(--cyber-blue);
  text-shadow:
    0 0 4px rgba(47,128,201,0.9),
    0 0 10px rgba(47,128,201,0.6),
    0 0 20px rgba(14,60,120,0.6);
  animation: asciiPulse 0.8s infinite alternate, glitch 3s infinite;
}

@keyframes asciiPulse {
  0%   { text-shadow:0 0 4px rgba(47,128,201,0.7),0 0 10px rgba(47,128,201,0.5),0 0 20px rgba(14,60,120,0.5); }
  50%  { text-shadow:0 0 6px rgba(47,128,201,0.9),0 0 12px rgba(47,128,201,0.7),0 0 22px rgba(14,60,120,0.6); }
  100% { text-shadow:0 0 4px rgba(47,128,201,0.7),0 0 10px rgba(47,128,201,0.5),0 0 20px rgba(14,60,120,0.5); }
}

@keyframes glitch {
  0%{ text-shadow: var(--glow); }
  15%{ text-shadow: -2px 0 red, 2px 0 cyan; }
  30%{ text-shadow: 2px 0 red, -2px 0 cyan; }
  45%{ text-shadow: -1px 0 red, 1px 0 cyan; }
  60%{ text-shadow: var(--glow); }
  100%{ text-shadow: var(--glow); }
}

/* =========================
   NAV NODES
========================= */
.nav {
  margin-top: 30px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 15px;
}

.node {
  position: relative;
  padding: 12px;
  border: 1px solid var(--cyber-blue);
  color: var(--cyber-blue);
  text-decoration: none;
  overflow: hidden;
  transition: all 0.2s ease;
}

.node::before {
  content: "> ";
}

.node:hover {
  box-shadow: 0 0 4px #1b4f72, 0 0 8px #0b3c5d; /* slightly reduced glow */
  transform: translateX(3px);
}

.node::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: repeating-linear-gradient(
    to bottom,
    rgba(255,255,255,0.04) 0px, /* much fainter */
    rgba(255,255,255,0.04) 1px,
    rgba(0,0,0,0) 2px
  );
  opacity: 0;
}

.node:hover::after {
  opacity: 1;
  animation: nodeScan 0.25s linear infinite; /* subtle vertical scroll */
}

@keyframes nodeScan {
  from { background-position-y: 0; }
  to   { background-position-y: 6px; }
}


/* =========================
   TERMINAL
========================= */
.terminal{
  margin-top:20px;
  line-height:1.6;
  white-space:pre-wrap;
  position:relative;
  z-index:20;
}

.cursor{
  display:inline-block;
  width:10px;
  color: var(--cyber-blue);
  animation: blink 1s steps(1) infinite, ghostBlink 2s infinite alternate;
}

@keyframes blink{0%,50%{opacity:1;}50.1%,100%{opacity:0;}}
@keyframes ghostBlink{0%{opacity:0.4;}50%{opacity:0.75;}100%{opacity:0.4;}}

/* =========================
   CURSOR TRAIL
========================= */
.cursor-trail {
  position: fixed !important;
  width: 2px;
  height: 6px;
  background: rgba(47,128,201,0.1);
  pointer-events: none;
  mix-blend-mode: screen;
  will-change: transform, opacity;
  border-radius: 0;
  z-index: 99999; /* make sure it's on top of everything */
  animation: trailFlicker 0.4s infinite alternate;
}

/* =========================
   SCROLL PARTICLES
========================= */
.scroll-particle{
  position:fixed;
  width:4px;
  height:4px;
  background: rgba(47,128,201,0.2);
  border-radius:0;
  pointer-events:none;
  mix-blend-mode:screen;
  will-change: transform, opacity;
}

/* =========================
   STATUS & FOOTER
========================= */
.status{
  margin-top:40px;
  font-size:0.8rem;
  color:var(--text-dim);
  border-top:1px dashed var(--cyber-blue);
  padding-top:15px;
}
#identity{margin-top:10px;opacity:0.7;}

footer{
  margin-top:40px;
  font-size:0.85rem; /* slightly bigger */
  text-align:center;
  color: var(--cyber-blue); /* brighter than before */
  opacity:0.95;
  text-shadow:0 0 6px rgba(27,79,114,0.7); /* subtle glow */
}


/* =========================
   SUBTITLE
========================= */
.subtitle{
  font-size:0.9rem;
  color:var(--text-dim);
  opacity:0.8;
}
