/* Reset */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

@font-face {
  font-family: 'StrangerThings';
  src: url('../font/Bolton.ttf') format('truetype');
}

/* Body */
body {
  font-family: 'Inter', sans-serif;
  background: #0d0d0e;
  transition: background 0.5s ease, filter 0.5s ease;
}

body.loading {
  overflow: hidden;
}

/* Loader */
.loader {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;

  display: flex;
  justify-content: center;
  align-items: center;

  transition: opacity 0.6s ease;
  z-index: 9999;
}

/* Fondos dinámicos */
body.light #loader {
  background: url('../img/loading_light.png') center/cover no-repeat;
}

body.dark #loader-dark {
  background: url('../img/loading_dark.png') center/cover no-repeat;
}

/* Caja */
.loader-box {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  background: rgba(255, 255, 255, 0.9);
  padding: 120px 200px;
  border-radius: 15px;
  text-align: center;
  z-index: 1;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.loader-box h2 {
  font-family: 'Orbitron', sans-serif;
  margin-bottom: 10px;
}

/* Imagen */
.bikes {
  position: absolute;
  bottom: 30%;
  width: 220px;
  z-index: 2;
}

/* Header */
.header {
  display: flex;
  justify-content: space-between;
  align-items: center;

  padding: 15px 40px;
  background: rgba(0, 0, 0, 0.85);
  min-height: 80px;
}

.logo-img {
  height: 80px;
}

.title {
  font-family: 'StrangerThings', serif;
  font-size: 50px;
  margin: 50px;
  letter-spacing: 3px;
}

/* Titulo modo claro */
body.light .title {
  color: #e50914;
  text-shadow:
    0 0 15px #ff0000,
    0 0 20px #FFFFFF,
    0 0 30px #ff0000;
}

/* Titulo modo oscuro */
body.dark .title {
  color: #000000;
  -webkit-text-stroke: 2px #e50914;
  text-shadow:
    0 0 10px #ff0000,
    0 0 20px #ff0000;
}

/* Menu */
.menu-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
}

.menu-toggle span {
  width: 25px;
  height: 3px;
  background: #fff;
}

/* Nav */
.nav {
  display: flex;
  align-items: center;
  gap: 30px;
  z-index: 2000;
}

.nav-link {
  color: #fff;
  text-decoration: none;
  font-size: 14px;
  transition: color 0.3s;
}

.nav-link:hover,
.nav-link.active {
  color: #a80000;
}

/* Aspecto del Boton */
.theme-btn {
  background: none;
  border: none;
  cursor: pointer;
}

.theme-btn img {
  width: 110px;
  transition: transform 0.3s ease;
}

.theme-btn:hover img {
  transform: scale(1.1);
}

.animate__hinge {
  animation-duration: 1.5s;
}

.dark #main-title {
  animation-fill-mode: none !important;

}

/* Boton volver */
.back-btn {
  position: fixed;
  top: 110px;
  left: 20px;
  z-index: 1000;
}

.back-btn img {
  width: 70px;
}

/* Home */
.home {
  text-align: center;
  padding: 20px;
  min-height: 100vh;

  background: url('../img/hawkins.png') center/cover no-repeat;
}

body.dark .home {
  background: url('../img/upside-down.png') center/cover no-repeat;
}

/* Portada */
.portada {
  max-width: 800px;
  margin: 20px auto;
}

.portada img {
  width: 100%;
  max-width: 580px;
}

body.light .descripcion {
  font-size: 22px;
  color: #000000;
  text-shadow: 1px 1px 3px #000000;
  font-family: "Bolton";
}

body.dark .descripcion {
  font-size: 22px;
  color: #fff;
  text-shadow: 1px 1px 3px #fff;
  font-family: "Bolton";
}

/* Acerca de nosotros */
.about {
  max-width: 900px;
  margin: 30px auto;
  font-size: 18px;
  color: #fff;
  line-height: 1.6;
  text-shadow: 1px 1px 2px #000000;
  text-align: justify;
}

.box-about-description {
  color: #fff;
  background: rgba(255, 255, 255, 0.2);
  backdrop-filter: blur(10px);
  padding: .625rem;
  border-radius: .3125rem;
}

body.light .about-description {
  color: #000;
}

body.dark .about-description {
  color: #fff;
}

/* Perfiles */
.grid {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 50px;
  padding: 80px 0;
}

/* Cards */
.card {
  position: relative;
  width: 240px;
  height: 340px;
  transition: 0.4s;
  isolation: isolate;
}

/* Borde */
.card::before,
.card::after {
  position: absolute;
  z-index: 0;
  pointer-events: none;
}

.card::before {
  content: "";
  inset: -3px;
  border: 2px solid rgba(255, 0, 0, 0.4);
  filter: blur(6px);
  opacity: 0;
  transition: 0.4s;
}

/* Niebla */
.card::after {
  content: "";
  inset: 0;
  background: radial-gradient(circle, rgba(255, 0, 0, 0.2), transparent 70%);
  opacity: 0;
  transition: 0.4s;
}

/* Contenido */
.card-frame {
  position: relative;
  height: 100%;
  background: rgba(0, 0, 0, 0.9);
  border: 1px solid rgba(255, 0, 0, 0.3);
  padding: 20px;
  text-align: center;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

/* Imagen */
.card-image img {
  width: 100%;
  transition: 0.4s;
}

/* Texto */
.card-frame h2 {
  font-family: 'StrangerThings', serif;
  color: #ff2a2a;
  text-shadow: 0 0 10px #ff0000;
  letter-spacing: 2px;
}

.card-frame p {
  color: #ccc;
}

/* Boton */
.card-frame a {
  background: transparent;
  border: 1px solid #FF0000;
  color: #FF0000;
  padding: 8px;
  cursor: pointer;
  transition: 0.3s;
  text-decoration: none;
}

.card-frame a:hover {
  background: #FF0000;
  color: #000000;
  box-shadow: 0 0 10px #FF0000;
}

.card-frame button {
  background: transparent;
  border: 1px solid #FF0000;
  color: #FF0000;
  padding: 8px;
  cursor: pointer;
  transition: 0.3s;
}

.card-frame button:hover {
  background: #FF0000;
  color: #000000;
  box-shadow: 0 0 10px #FF0000;
}

/* Hover */
.card:hover::before {
  opacity: 1;
}

.card:hover::after {
  opacity: 1;
}

.card:hover {
  transform: scale(1.05);
}

.card:hover .card-image img {
  transform: scale(1.1);
  filter: grayscale(100%) contrast(140%) brightness(0.7);
}

.card:hover h2 {
  text-shadow:
    0 0 10px #FF0000,
    0 0 20px #FF0000,
    0 0 40px #FF0000;
}

.card:hover {
  transform: scale(1.07) rotateX(4deg);
  box-shadow:
    0 0 20px #FF0000,
    0 0 40px #FF0000,
    0 0 80px rgba(255, 0, 0, 0.6);
}

.card:hover::before {
  opacity: 1;
  animation: borderFlicker 1.5s infinite;
}

.card:hover::after {
  opacity: 1;
  background: radial-gradient(circle, rgba(255, 0, 0, 0.35), transparent 70%);
}

.card:hover .card-image img {
  transform: scale(1.15);
  filter: grayscale(100%) contrast(160%) brightness(0.6);
}

.card:hover h2 {
  animation: textFlicker 1.5s infinite;
}

/* Animaciones */

@keyframes borderFlicker {

  0%,
  18%,
  22%,
  25%,
  53%,
  57%,
  100% {
    opacity: 1;
  }

  20%,
  24%,
  55% {
    opacity: 0.3;
  }
}

@keyframes textFlicker {

  0%,
  100% {
    text-shadow: 0 0 10px #FF0000, 0 0 20px #FF0000;
  }

  50% {
    text-shadow: 0 0 5px #FF0000, 0 0 40px #FF0000;
  }
}

/* Perfil */
.profile {
  min-height: 100vh;
  display: flex;
  justify-content: center;
  align-items: center;
  position: relative;
}

.profile::before {
  content: "";
  position: absolute;
  inset: -2px;
  border: 1px solid #FF0000;
  opacity: 0.3;
  filter: blur(6px);
  background: radial-gradient(circle, rgba(0, 0, 0, 0.6), rgba(0, 0, 0, 0.9));
  z-index: 0;
}

.profile-card {
  position: relative;
  z-index: 1;
  align-items: flex-start;
  display: flex;
  gap: 30px;

  padding: 40px;
  border-radius: 20px;

  width: 900px;
  max-width: 95%;

  background: rgba(0, 0, 0, 0.7);
  backdrop-filter: blur(10px);

  border: 1px solid rgba(255, 0, 0, 0.3);

  box-shadow:
    0 0 20px rgba(255, 0, 0, 0.3),
    0 0 60px rgba(255, 0, 0, 0.2);

  color: #fff;
}

#profile-name {
  font-family: 'StrangerThings', serif;
  color: #ff2a2a;
  text-shadow: 0 0 10px #FF0000;
  letter-spacing: 2px;
}

.profile-info {
  max-width: 450px;
}

.quote {
  font-style: italic;
  opacity: 0.8;
}

.profile-left {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 15px;
}

.profile-left img {
  width: 260px;
  margin-top: -20px;
  border-radius: 12px;
  border: 2px solid rgba(255, 0, 0, 0.4);
  box-shadow: 0 0 15px rgba(255, 0, 0, 0.3);
}

.profile-left .quote {
  font-style: italic;
  font-size: 14px;
  text-align: center;
  max-width: 240px;
  color: #ccc;
  border-top: 1px solid rgba(255, 0, 0, 0.3);
  padding-top: 10px;
}

.profile-info {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.profile-data {
  font-size: 14px;
  opacity: 0.8;
}

.profile-block {
  border-left: 3px solid #FF0000;
  padding-left: 15px;
}

.profile-block h3 {
  color: #ff2a2a;
  margin-bottom: 5px;
  font-size: 16px;
  letter-spacing: 1px;
}

.profile-block p {
  font-size: 14px;
  line-height: 1.5;
}

.profile-left img:hover {
  filter: grayscale(100%) contrast(150%) brightness(0.6);
  transform: scale(1.05);
}

.profile-card {
  animation: flicker 3s infinite;
}

@keyframes flicker {

  0%,
  100% {
    opacity: 1;
  }

  50% {
    opacity: 0.97;
  }

  52% {
    opacity: 0.9;
  }

  54% {
    opacity: 1;
  }
}

.profile-info {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

/* Fondos */

body.max.light .profile {
  background: url('../img/background_max_profile_light.png') center/cover no-repeat;
}

body.max.dark .profile {
  background: url('../img/background_maax_profile_dark.jpg') center/cover no-repeat;
}

body.nancy.light .profile {
  background: url('../img/background_nancy_profile_light.jpg') center/cover no-repeat;
}

body.nancy.dark .profile {
  background: url('../img/background_nancy_profile_dark.webp') center/cover no-repeat;
}

body.steve.light .profile {
  background: url('../img/background_stevee_profile_light.jpg') center/cover no-repeat;
}

body.steve.dark .profile {
  background: url('../img/background_stevee_profile_dark.jpg') center/cover no-repeat;
}

body.robin.light .profile {
  background: url('../img/background_robin_profile_light.jpg') center/cover no-repeat;
}

body.robin.dark .profile {
  background: url('../img/background_robin_profile_dark.jpg') center/cover no-repeat;
}

/* Bitácora */
.bitacora {
  min-height: 100vh;
  padding: 40px 20px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

/* Titulo */
body.light .bitacora .title {
  font-family: 'Orbitron', sans-serif;
  font-size: 48px;
  color: #b30000;
  margin-bottom: 10px;
}

body.dark .bitacora .title {
  font-family: 'Orbitron', sans-serif;
  font-size: 48px;
  color: #b30000;
  margin-bottom: 10px;
  text-shadow: 1px 1px 3px rgba(255, 255, 255, 0.398);
}

body.light .bitacora .subtitle {
  font-size: 24px;
  color: #000;
  text-shadow: 1px 1px 3px #fff;
  margin-bottom: 40px;
}

body.dark .bitacora .subtitle {
  font-size: 24px;
  color: #fff;
  text-shadow: 1px 1px 3px #000000;
  margin-bottom: 40px;
}

/* Caja central */
.bitacora-content {
  width: 90%;
  max-width: 900px;
  margin: 10px auto;
  position: relative;
  overflow: hidden;

  background: rgba(255, 255, 255, 0.9);
  border-radius: 20px;

  padding: 40px 30px;

  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);

  transition: 0.4s;
  animation: fadeUp 0.8s ease forwards;
  opacity: 0;
}

/* Delays animación */
.bitacora-content:nth-child(1) {
  animation-delay: 0.2s;
}

.bitacora-content:nth-child(2) {
  animation-delay: 0.4s;
}

.bitacora-content:nth-child(3) {
  animation-delay: 0.6s;
}

/* Modo oscuro cards */
body.dark .bitacora-content {
  background: rgba(10, 0, 0, 0.9);
  border: 1px solid rgba(255, 0, 0, 0.3);
  box-shadow: 0 0 20px rgba(255, 0, 0, 0.2);
}

.bitacora-content::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at top, rgba(255, 0, 0, 0.15), transparent 70%);
  opacity: 0;
  transition: 0.4s;
}

/* Línea roja lateral */
.bitacora-content::after {
  content: "";
  position: absolute;
  left: 0;
  top: 0;
  width: 4px;
  height: 100%;
  background: linear-gradient(to bottom, transparent, #FF0000, transparent);
  opacity: 0.7;
}

.bitacora-content:hover {
  transform: translateY(-8px) scale(1.01);
  box-shadow: 0 0 25px rgba(255, 0, 0, 0.4);
}

.bitacora-content:hover::before {
  opacity: 1;
}

.bitacora-content h3 {
  font-family: 'Orbitron', sans-serif;
  margin-bottom: 15px;
  font-size: 22px;
  letter-spacing: 1px;
  color: #b30000;
}

body.dark .bitacora-content h3 {
  color: #ff2a2a;
  text-shadow:
    0 0 5px #FF0000,
    0 0 10px dark#FF0000,
    0 0 20px #FF0000;
}

.bitacora-content p {
  color: #333;
  line-height: 1.6;
  font-size: 18px;
  transition: 0.3s;
  text-align: justify;
}

body.dark .bitacora-content p {
  color: #ddd;
}

/* Animacion */

@keyframes fadeUp {
  from {
    opacity: 0;
    transform: translateY(40px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Footer */
.footer {
  text-align: center;
  padding: 20px;
  background: rgba(0, 0, 0, 0.85);
}

.footer p {
  color: #fff;
}

/* Ocultar contenido durante loading */
body.loading main,
body.loading header,
body.loading footer {
  display: none;
  visibility: hidden;
}

/* Transición suave cuando aparece */
main,
header,
footer {
  transition: opacity 0.6s ease;
}

/* Responsive */

/* 1200px Pantallas de escritorio */
@media (max-width: 1200px) {

  .logo-img {
    height: 60px;
  }

  .grid {
    gap: 25px;
  }

  .card {
    max-width: 220px;
  }

  .profile-card {
    width: 95%;
  }

  .back-btn {
    top: 100px;
  }
}

/* 900px Tablets o pantallas medianas */
@media (max-width: 900px) {

  /* Nav mobile */
  .menu-toggle {
    display: flex;
  }

  .nav {
    display: none;
    position: absolute;
    top: 80px;
    left: 0;
    width: 100%;
    background: rgba(0, 0, 0, 0.95);
    flex-direction: column;
    padding: 20px;
    gap: 15px;
  }

  .nav.active {
    display: flex;
  }

  /* Grid */
  .grid {
    gap: 20px;
  }

  .card {
    max-width: 200px;
  }

  /* PORTADA */
  .portada img {
    max-width: 450px;
  }

  .descripcion {
    font-size: 20px;
  }

  /* Profile */
  .profile-card {
    flex-direction: column;
    align-items: center;
    text-align: center;
  }

  .profile-card img {
    width: 200px;
  }

  .profile-info {
    max-width: 100%;
  }

  /* Bitácora */
  .bitacora .title {
    font-size: 36px;
  }

  .bitacora .subtitle {
    font-size: 20px;
  }

  .bitacora-content {
    padding: 30px 20px;
  }

  .bitacora-entry p {
    font-size: 16px;
  }

  /* Boton volver */
  .back-btn {
    top: 90px;
  }

  .grid {
    grid-template-columns: 1fr;
    gap: 40px;
  }
}

/* 400px Dispositivos moviles pequeños */
@media (max-width: 400px) {

  /* Grid una columna */
  .grid {
    flex-direction: column;
    align-items: center;
  }

  .card {
    width: 90%;
    max-width: 300px;
  }

  /* Portada */
  .portada img {
    max-width: 280px;
  }

  .descripcion {
    font-size: 16px;
  }

  .about {
    font-size: 15px;
    padding: 0 10px;
  }

  /* Perfil */
  .profile-card {
    padding: 15px;
  }

  .profile-card img {
    width: 150px;
  }

  .profile-info h2 {
    font-size: 18px;
  }

  .profile-info p {
    font-size: 13px;
  }

  /* Bitácora */
  .bitacora .title {
    font-size: 28px;
  }

  .bitacora .subtitle {
    font-size: 16px;
  }

  .bitacora-entry h3 {
    font-size: 18px;
  }

  .bitacora-entry p {
    font-size: 14px;
  }

  /* Boton volver */
  .back-btn {
    top: 80px;
    left: 10px;
  }

  .back-btn img {
    width: 55px;
  }
}

.surprise-container {
  display: flex;
  justify-content: center;
  align-items: center;
  height: 100%;
}

.surprise-container img {
  max-width: 100%;
  max-height: 400px;
  object-fit: contain;
}

.btn-surprice {
  background: transparent;
  border: 1px solid #FF0000;
  color: #FF0000;
  padding: 8px;
  cursor: pointer;
  transition: 0.3s;
  text-decoration: none;
}

.btn-surprice:hover {
  background: #FF0000;
  color: #000000;
  box-shadow: 0 0 10px #FF0000;
}