/* ============================================
   THE REBORN SIGNAL — CIPHER
   Cold / Glitch / Digital / Dissolution
   ============================================ */

.page-cipher {
  background: var(--cipher-night);
}

/* ── CODE PARTICLES BACKGROUND ── */

.cipher-particles {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 0;
  overflow: hidden;
}

.cipher-particle {
  position: absolute;
  font-family: 'IBM Plex Mono', monospace;
  font-size: 10px;
  color: var(--cipher-cyan);
  opacity: 0;
  animation: code-float linear infinite;
}

.cipher-particle:nth-child(1) { left: 5%; animation-duration: 18s; animation-delay: 0s; }
.cipher-particle:nth-child(2) { left: 15%; animation-duration: 22s; animation-delay: 3s; }
.cipher-particle:nth-child(3) { left: 25%; animation-duration: 20s; animation-delay: 7s; }
.cipher-particle:nth-child(4) { left: 35%; animation-duration: 25s; animation-delay: 2s; }
.cipher-particle:nth-child(5) { left: 45%; animation-duration: 19s; animation-delay: 5s; }
.cipher-particle:nth-child(6) { left: 55%; animation-duration: 23s; animation-delay: 1s; }
.cipher-particle:nth-child(7) { left: 65%; animation-duration: 17s; animation-delay: 8s; }
.cipher-particle:nth-child(8) { left: 75%; animation-duration: 21s; animation-delay: 4s; }
.cipher-particle:nth-child(9) { left: 85%; animation-duration: 24s; animation-delay: 6s; }
.cipher-particle:nth-child(10) { left: 95%; animation-duration: 20s; animation-delay: 9s; }

/* ── MATRIX CANVAS ── */

#cipher-matrix {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 0;
  opacity: 0.05;
}

/* ── CIPHER HERO ── */

.cipher-hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 8rem 4rem;
  z-index: 1;
}

.cipher-tagline {
  font-family: 'IBM Plex Mono', monospace;
  font-weight: 400;
  font-size: 0.8rem;
  letter-spacing: 0.2em;
  color: var(--cipher-cyan);
  text-transform: uppercase;
  margin-bottom: 1rem;
  opacity: 0.5;
}

.cipher-name {
  font-family: 'IBM Plex Mono', monospace;
  font-weight: 700;
  font-size: clamp(3rem, 7vw, 6rem);
  color: var(--cipher-cyan);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  line-height: 0.95;
}

.cipher-subtitle {
  font-family: 'IBM Plex Mono', monospace;
  font-weight: 400;
  font-size: clamp(0.8rem, 1.5vw, 1.1rem);
  color: var(--cipher-cold-white);
  text-transform: uppercase;
  letter-spacing: 0.15em;
  margin-top: 1.5rem;
  opacity: 0.4;
}

/* ── CIPHER BIO — CODE FORMAT ── */

.cipher-bio {
  position: relative;
  z-index: 1;
  padding: 4rem 2rem 8rem;
  max-width: 900px;
  margin: 0 auto;
}

.cipher-code-block {
  background: rgba(0, 0, 0, 0.4);
  border: 1px solid rgba(0, 255, 225, 0.08);
  border-radius: 2px;
  padding: 2.5rem;
  font-family: 'IBM Plex Mono', monospace;
  position: relative;
  overflow: hidden;
}

.cipher-code-block::before {
  content: 'cipher.identity';
  position: absolute;
  top: 0.8rem;
  right: 1rem;
  font-size: 0.65rem;
  color: var(--cipher-cyan);
  opacity: 0.2;
  letter-spacing: 0.05em;
}

.code-line {
  display: flex;
  gap: 1.5rem;
  padding: 0.35rem 0;
  line-height: 1.8;
}

.line-number {
  color: #333;
  font-size: 0.75rem;
  min-width: 2.5rem;
  text-align: right;
  user-select: none;
  flex-shrink: 0;
}

.line-content {
  font-size: 0.9rem;
  color: var(--cipher-cold-white);
  opacity: 0.7;
}

.line-content .comment {
  color: #4A5568;
  font-style: italic;
}

.line-content .keyword {
  color: var(--cipher-cyan);
}

.line-content .string {
  color: var(--canon-amber);
  opacity: 0.7;
}

.line-content .null-val {
  color: #FF6B6B;
  opacity: 0.6;
}

.line-content .bracket {
  color: #555;
}

.code-line.empty {
  height: 1.5rem;
}

/* ── CIPHER SOUND DESCRIPTION ── */

.cipher-sound {
  font-family: 'IBM Plex Mono', monospace;
  font-weight: 700;
  font-size: clamp(1rem, 2vw, 1.5rem);
  color: var(--cipher-cyan);
  text-transform: uppercase;
  letter-spacing: 0.2em;
  text-align: center;
  padding: 4rem 2rem;
  position: relative;
  z-index: 1;
  opacity: 0.4;
}

.cipher-sound::before,
.cipher-sound::after {
  content: '';
  display: block;
  width: 40px;
  height: 1px;
  background: var(--cipher-cyan);
  margin: 0 auto;
  opacity: 0.3;
}

.cipher-sound::before {
  margin-bottom: 2rem;
}

.cipher-sound::after {
  margin-top: 2rem;
}

/* ── CIPHER BIO TEXT ── */

.cipher-bio-text {
  position: relative;
  z-index: 1;
  padding: 0 2rem 4rem;
  max-width: 700px;
  margin: 0 auto;
}

.cipher-bio-text p {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 0.95rem;
  line-height: 2;
  color: var(--cipher-cold-white);
  opacity: 0.6;
}

/* ── CANON BLEED (left edge) ── */

.cipher-canon-bleed {
  position: fixed;
  top: 0;
  left: 0;
  width: 2px;
  height: 100%;
  pointer-events: none;
  z-index: 5;
}

.cipher-canon-bleed::before {
  content: '';
  position: absolute;
  top: 25%;
  left: 0;
  width: 1px;
  height: 50%;
  background: var(--canon-amber);
  opacity: 0.15;
  box-shadow: 0 0 8px rgba(200, 135, 58, 0.1);
}

/* ── RESPONSIVE ── */

@media (max-width: 768px) {
  .cipher-hero {
    padding: 6rem 2rem;
  }

  .cipher-code-block {
    padding: 1.5rem;
  }

  .code-line {
    gap: 1rem;
  }

  .line-content {
    font-size: 0.8rem;
  }
}

@media (max-width: 640px) {
  .cipher-hero {
    padding: 5rem 1.5rem;
  }

  .line-number {
    min-width: 2rem;
    font-size: 0.65rem;
  }
}
