body {
  margin: 0;
  font-family: "Bebas Neue", sans-serif;
  background-color: #000;
  overflow: hidden;
}

.page {
  position: relative;
  width: 100vw;
  height: 100vh;
  overflow: hidden;
}

.front,
.back {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: opacity 1s ease, filter 1s ease;
  backface-visibility: hidden; /* no giramos, pero por seguridad */
  opacity: 1;
  filter: blur(0);
  pointer-events: auto;
  z-index: 1;
}

.back {
  opacity: 0;
  filter: blur(10px);
  pointer-events: none;
  z-index: 0;
}

.page.transitioning .front {
  opacity: 0;
  filter: blur(10px);
  pointer-events: none;
  z-index: 0;
}

.page.transitioning .back {
  opacity: 1;
  filter: blur(0);
  pointer-events: auto;
  z-index: 1;
}

.content {
  text-align: center;
  max-width: 600px;
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.avatar {
  width: 300px;
  height: auto;
  object-fit: cover;
  margin-bottom: 20px;
  border: 4px solid transparent; /* Borde invisible inicialmente */
  box-shadow: 0 0 20px rgba(0, 0, 0, 0.4);
  border-radius: 12px;
  position: relative;
  z-index: 2;
  opacity: 0.4; /* Imagen atenuada al inicio */
  transition: opacity 0.4s ease, border-color 0.4s ease, box-shadow 0.4s ease;
}

/* Al pasar el ratón por encima */
.avatar:hover {
  opacity: 1; /* Se ilumina */
  border-color: #a8ff60; /* Verde pistacho */
  box-shadow: 0 0 25px #a8ff60aa; /* Resplandor verde */
}

h1 {
  font-size: 32px;
  margin: 10px 0;
}

button {
  font-family: "Bebas Neue", sans-serif;
  background-color: transparent;
  color: transparent;
  border: 2px solid transparent;
  padding: 12px 24px;
  font-size: 16px;
  border-radius: 8px;
  cursor: pointer;
  position: relative;
  transition: all 0.4s ease;
  z-index: 3;
}

/* Al pasar el ratón se "activa" */
button:hover {
  background-color: #a8ff60; /* verde pistacho */
  color: #111;
  border-color: #a8ff60;
  box-shadow: 0 0 10px #a8ff60, 0 0 20px #a8ff60, 0 0 40px #a8ff60;
  animation: pulsar 1.2s infinite alternate;
}

/* Efecto pulsante */
@keyframes pulsar {
  0% {
    box-shadow: 0 0 5px #a8ff60, 0 0 10px #a8ff60, 0 0 20px #a8ff60;
  }
  100% {
    box-shadow: 0 0 15px #a8ff60, 0 0 30px #a8ff60, 0 0 60px #a8ff60;
  }
}

.front .big-name {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  text-align: center;
  font-family: "Bebas Neue", sans-serif;
  font-size: 14vw;
  color: rgba(255, 255, 255, 0.123); /* Más visible */
  font-weight: 900;
  z-index: 0;
  pointer-events: none;
  line-height: 1;
  text-transform: uppercase;
  letter-spacing: 2px;
}

.front .big-name .line1,
.front .big-name .line2 {
  display: block;
}

.matrix-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 1;
  pointer-events: none;
  background: repeating-linear-gradient(
    0deg,
    rgba(2, 241, 2, 0.514) 0px,
    rgba(0, 255, 0, 0.288) 1px,
    transparent 1px,
    transparent 3px
  );
  animation: matrixRain 4s linear infinite;
  mix-blend-mode: screen;
  opacity: 0.5;
}

@keyframes matrixRain {
  0% {
    background-position: 0 0;
  }
  100% {
    background-position: 0 100px;
  }
}

/* === Responsive para pantallas pequeñas (móviles, tablets) === */
@media (max-width: 768px) {
  .content {
    padding: 1rem;
    max-width: 90%;
  }

  .avatar {
    width: 80%;
    max-width: 250px;
    margin-bottom: 1rem;
  }

  h1 {
    font-size: 24px;
  }

  button {
    width: 90%;
    font-size: 18px;
    padding: 0.75rem 1rem;
    text-align: center;
  }

  .front .big-name {
    font-size: 20vw;
    line-height: 1.1;
    letter-spacing: 1px;
  }
}

/* === Extra small screens (muy móviles) === */
@media (max-width: 480px) {
  .avatar {
    max-width: 200px;
  }

  button {
    font-size: 16px;
    padding: 0.6rem 0.9rem;
  }

  .front .big-name {
    font-size: 24vw;
  }
}

/* === Responsive adicional para .page y .front === */
@media (max-width: 768px) {
  .page {
    height: auto;
    min-height: 100vh;
    overflow-x: hidden;
  }

  .front,
  .back {
    flex-direction: column;
    justify-content: flex-start;
    padding-top: 3rem;
    text-align: center;
  }

  .front .content {
    max-width: 90%;
    padding: 1rem;
  }
}

/* === Extra responsive tweaks for very small screens === */
@media (max-width: 480px) {
  .front .content {
    padding: 0.5rem;
  }

  .avatar {
    width: 100%;
    max-width: 180px;
  }

  h1 {
    font-size: 20px;
  }
}