/* =============================
   SECCIONES TEMÁTICAS EN EL MAIN
   ============================= */
.section {
  display: none;
  opacity: 0;
  transform: translateY(40px);
  transition: opacity 0.7s cubic-bezier(.77, 0, .18, 1), transform 0.7s cubic-bezier(.77, 0, .18, 1);
  padding: 2.5rem 1rem 2rem 1rem;
  border-radius: 1.5rem;
  margin-bottom: 2rem;
  min-height: 350px;
  box-sizing: border-box;
}

.section.section--active {
  display: block;
  opacity: 1;
  transform: translateY(0);
  z-index: 20;
}

.section__title {
  font-size: 2.2rem;
  margin-bottom: 1.5rem;
  text-align: center;
  letter-spacing: 0.12em;
  font-family: 'Orbitron', 'Audiowide', Arial, sans-serif;
  text-shadow: 0 0 16px #fff;
  position: relative;
}

.section__entries,
.section__comments {
  min-height: 80px;
  margin-bottom: 1.5rem;
}

/* ====== FONDO ANIMADO CYBERPUNK PARALLAX Y GLOW ====== */
.cyberpunk-background {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  z-index: -10;
  background: radial-gradient(ellipse at center, #0ff 0%, #000 100%);
  overflow: hidden;
  pointer-events: none;
}

.cyberpunk-lines::before {
  content: '';
  position: absolute;
  top: -100%;
  left: 0;
  width: 100%;
  height: 300%;
  background-image: repeating-linear-gradient(to bottom,
      rgba(0, 255, 255, 0.1) 0px,
      rgba(0, 255, 255, 0.15) 2px,
      transparent 2px,
      transparent 4px);
  animation: staticLines 6s linear infinite;
  pointer-events: none;
}

@keyframes staticLines {
  0% {
    transform: translateY(0);
  }

  100% {
    transform: translateY(100%);
  }
}

.glitch-text {
  position: relative;
  color: #0ff;
  font-family: 'Courier New', monospace;
  font-size: 2rem;
  animation: flicker 1.5s infinite alternate;
  text-align: center;
  margin-bottom: 2rem;
}

@keyframes flicker {
  0% {
    opacity: 1;
    text-shadow: 0 0 5px #0ff, 0 0 10px #0ff;
  }

  50% {
    opacity: 0.7;
    text-shadow: 0 0 3px #0ff, 0 0 6px #f0f;
  }

  100% {
    opacity: 1;
    text-shadow: 0 0 6px #0ff, 0 0 12px #f0f;
  }
}

.glow {
  box-shadow: 0 0 15px #0ff, 0 0 30px #f0f;
  transition: box-shadow 0.3s ease-in-out;
}

.parallax-layer {
  position: relative;
  will-change: transform;
}

.layer-back {
  z-index: 2;
}

.layer-front {
  z-index: 3;
}

/* ====== FONDO ANIMADO CYBERPUNK ====== */
.section--cyberpunk {
  position: relative;
  overflow: hidden;
  background: #0d0d0d;
  color: #00ffee;
}

.section--cyberpunk .section__background {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  pointer-events: none;
}

.cyberpunk-lines {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image: repeating-linear-gradient(to bottom,
      rgba(0, 255, 255, 0.03),
      rgba(0, 255, 255, 0.03) 2px,
      transparent 2px,
      transparent 4px);
  animation: cyberpunk-lines-scroll 1s linear infinite;
  z-index: 1;
  pointer-events: none;
}

@keyframes cyberpunk-lines-scroll {
  0% {
    background-position: 0 0;
  }

  100% {
    background-position: 0 100%;
  }
}

.cyberpunk-glitch {
  position: absolute;
  width: 100%;
  height: 100%;
  background: repeating-linear-gradient(to bottom,
      rgba(255, 0, 255, 0.08) 0px,
      rgba(0, 255, 255, 0.08) 1px,
      transparent 2px);
  mix-blend-mode: screen;
  animation: cyberpunk-glitch-flicker 0.3s steps(2) infinite;
  z-index: 2;
  pointer-events: none;
}

@keyframes cyberpunk-glitch-flicker {

  0%,
  100% {
    opacity: 0.1;
  }

  50% {
    opacity: 0.3;
  }
}

.section--cyberpunk .section__content {
  position: relative;
  z-index: 3;
  padding: 3rem;
  font-family: 'Orbitron', monospace;
  text-shadow: 0 0 5px #0ff, 0 0 10px #f0f, 0 0 20px #0ff;
  animation: neon-pulse 3s ease-in-out infinite;
}

@keyframes neon-pulse {

  0%,
  100% {
    text-shadow: 0 0 5px #0ff, 0 0 10px #f0f, 0 0 20px #0ff;
  }

  50% {
    text-shadow: 0 0 15px #0ff, 0 0 30px #f0f, 0 0 45px #0ff;
  }
}

/* CYBERPUNK */
.section--cyberpunk {
  background: linear-gradient(120deg, #0f0f0f 70%, #1a0033 100%);
  border: 2px solid #00fff7;
  box-shadow: 0 0 32px #ff00c8, 0 0 64px #00fff7;
  position: relative;
  overflow: hidden;
}

.section--cyberpunk::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  right: 0;
  bottom: 0;
  background: repeating-linear-gradient(180deg, #00fff733 0 2px, transparent 2px 8px);
  pointer-events: none;
  animation: cyberpunk-scan 2.5s linear infinite;
}

@keyframes cyberpunk-scan {
  0% {
    background-position-y: 0;
  }

  100% {
    background-position-y: 32px;
  }
}

/* ====== FONDO ANIMADO STEAMPUNK ====== */
.section--steampunk {
  position: relative;
  overflow: hidden;
  background: #3e2c1c;
  color: #fff8e1;
}

.steampunk__background {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  pointer-events: none;
  background: url('../img/steampunk_texture.jpg') repeat;
}

.steampunk__smoke {
  position: absolute;
  bottom: 0;
  left: 50%;
  width: 320px;
  height: 320px;
  filter: blur(32px);
  opacity: 0.32;
  background: radial-gradient(ellipse at center,
      rgba(255, 255, 255, 0.7) 0%,
      rgba(220, 220, 220, 0.2) 60%,
      rgba(220, 220, 220, 0) 100%);
  border-radius: 50%;
  animation: riseSmoke 14s linear infinite, driftSmoke 8s ease-in-out infinite;
  transform-origin: center bottom;
  pointer-events: none;
}

.steampunk__smoke:nth-child(1) {
  width: 260px;
  height: 260px;
  left: 30%;
  animation-delay: 0s, 0s;
  opacity: 0.28;
}

.steampunk__smoke:nth-child(2) {
  width: 400px;
  height: 400px;
  left: 54%;
  animation-delay: 3s, 1.5s;
  opacity: 0.22;
}

.steampunk__smoke:nth-child(3) {
  width: 340px;
  height: 340px;
  left: 62%;
  animation-delay: 5s, 3s;
  opacity: 0.25;
}

.steampunk__smoke:nth-child(4) {
  width: 220px;
  height: 220px;
  left: 45%;
  animation-delay: 7s, 2s;
  opacity: 0.18;
}

.steampunk__smoke:nth-child(5) {
  width: 500px;
  height: 500px;
  left: 70%;
  animation-delay: 10s, 4s;
  opacity: 0.13;
}

@keyframes riseSmoke {
  0% {
    transform: translateY(0) scale(0.8);
    opacity: 0.15;
  }

  50% {
    opacity: 0.25;
  }

  100% {
    transform: translateY(-300px) scale(1.2);
    opacity: 0;
  }
}

@keyframes driftSmoke {

  0%,
  100% {
    transform: translateX(0);
  }

  50% {
    transform: translateX(10px);
  }
}

.steampunk__gear {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 30vw;
  height: auto;
  z-index: 2;
  opacity: 0.9;
  filter: blur(6px) drop-shadow(0 0 24px #b08d57) drop-shadow(0 0 32px #3e2c1c);
  pointer-events: none;
  transition: transform 1.2s cubic-bezier(.77, 0, .18, 1);
  border-radius: 400px;
  transform: translate(-50%, -50%);
}

.steampunk__gear--left {
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
}

/* ====== ESPIRAL DE HUMO SEGUIMIENTO CURSOR STEAMPUNK ====== */
.steampunk-smoke-spiral {
  position: fixed;
  left: 0;
  top: 0;
  width: 0;
  height: 0;
  pointer-events: none;
  z-index: 100;
  mix-blend-mode: lighten;
  opacity: 0;
  transition: opacity 0.5s;
}

.steampunk-smoke-spiral.active {
  opacity: 1;
}

.steampunk-smoke-spiral .smoke-layer {
  position: absolute;
  left: 0;
  top: 0;
  width: 90px;
  height: 90px;
  border-radius: 50%;
  background: radial-gradient(ellipse at center, rgba(230, 230, 230, 0.22) 0%, rgba(200, 200, 200, 0.12) 60%, rgba(200, 200, 200, 0) 100%);
  filter: blur(8px);
  opacity: 0.8;
  pointer-events: none;
  animation: spiralSmoke 3.8s infinite linear, fadeSmoke 3.8s infinite linear;
}

.steampunk-smoke-spiral .smoke-layer:nth-child(2) {
  width: 60px;
  height: 60px;
  opacity: 0.6;
  animation-delay: 0.5s;
  filter: blur(12px);
}

.steampunk-smoke-spiral .smoke-layer:nth-child(3) {
  width: 120px;
  height: 120px;
  opacity: 0.45;
  animation-delay: 1s;
  filter: blur(16px);
}

@keyframes spiralSmoke {
  0% {
    transform: scale(0.7) rotate(0deg);
  }

  50% {
    transform: scale(1.1) rotate(180deg);
  }

  100% {
    transform: scale(0.7) rotate(360deg);
  }
}

@keyframes fadeSmoke {
  0% {
    opacity: 0.8;
  }

  60% {
    opacity: 0.5;
  }

  100% {
    opacity: 0;
  }
}

/* ALTA FANTASÍA */
.section--fantasy {
  background: linear-gradient(120deg, #0f2d1c 70%, #e6d8a7 100%);
  border: 2px solid #e6d8a7;
  box-shadow: 0 0 32px #39ff14, 0 0 64px #e6d8a7;
  position: relative;
  overflow: hidden;
  font-family: 'Dancing Script', 'Orbitron', cursive;
}

.section__title--fantasy {
  color: #39ff14;
  text-shadow: 0 0 24px #39ff14, 0 0 48px #e6d8a7;
  font-family: 'Dancing Script', 'Orbitron', cursive;
}

.section--fantasy::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  right: 0;
  bottom: 0;
  background: radial-gradient(circle at 80% 10%, #fff8 0 10%, transparent 60%), url('https://svgshare.com/i/13wG.svg') repeat;
  opacity: 0.12;
  animation: fantasy-stars 10s linear infinite;
  pointer-events: none;
}

@keyframes fantasy-stars {
  0% {
    background-position: 0 0, 0 0;
  }

  100% {
    background-position: 0 0, 200px 200px;
  }
}