#contenedor-principal {
  width: 384px;
  height: 760px;
  position: relative;
  overflow: hidden;
  border-radius: 70px;
  box-shadow: 0 0 12px rgba(0, 0, 0, 0.4);
  background-color: #0b0b0b50;

  /* Dos imágenes sobrepuestas */
  background-image: url('https://i.ibb.co/wZthmVJz/iPhoneX.png'), url('https://i.ibb.co/yFMWsXmN/Screan1.png');
  background-position: center center;
  background-size: cover, contain;
  background-repeat: no-repeat, no-repeat;
}

/* Clave de Acceso */
.clave-acceso {
  position: absolute;
  width: 400px;
  height: 770px;
  background: #cccccc;
  border-radius: 60px;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

@keyframes salida-clave {
  0% {
    opacity: 1;
  }
  100% {
    opacity: 0;
  }
}

.animar-salida {
  animation: salida-clave 1.6s ease-out forwards;
}

h1 {
  margin-bottom: 20px;
  font-size: 1.5rem;
  letter-spacing: 1px;
  color: #FFFFFF;
}

.code-input {
  display: flex;
  gap: 10px;
  margin-bottom: 20px;
}

.code-input input {
  width: 50px;
  height: 50px;
  text-align: center;
  font-size: 1.5rem;
  border: 2px solid #3A3A3C;
  border-radius: 8px;
  background-color: #1C1C1E;
  color: #FFFFFF;
  box-shadow: none;
  transition: border-color 0.3s ease;
}

.code-input input:focus {
  border-color: #AEAEB2;
  outline: none;
}

button {
  padding: 10px 20px;
  font-size: 1rem;
  border: none;
  border-radius: 6px;
  background-color: #3A3A3C;
  color: #FFFFFF;
  cursor: pointer;
  transition: background-color 0.3s ease;
}

button:hover {
  background-color: #AEAEB2;
  color: #000000;
}

#reloj {
  position: absolute;
  top: 28px;
  left: 32px;
  font-size: 12px;
  font-family: 'Courier New', monospace; /* Estilo técnico */
  color: #f0f0f0; /* Blanco ritual */
  padding: 4px 8px;
  border-radius: 6px;
  z-index: 50;
}

#bluetooth-icono {
  position: absolute;
  top: 30px;
  left: 88px;
  font-size: 14px;
  color: #007aff;
  text-shadow: 0 0 6px rgba(0, 122, 255, 0.6); /* Resplandor ceremonial */
  opacity: 1;
  z-index: 10;
}
@keyframes pulso-azul {
  0% {
    color: #007aff;
    text-shadow: 0 0 64px rgba(0, 122, 255, 0.9);
  }
  50% {
    color: #ffffff;
    text-shadow: 0 0 128px rgba(255, 255, 255, 0.6);
  }
  100% {
    color: #007aff;
    text-shadow: 0 0 64px rgba(0, 122, 255, 0.9);
  }
}
#bluetooth-icono.activo {
  animation: pulso-azul 2s infinite;
}

#signal-bars {
  position: absolute;
  top: 10px;
  right: 52px;
  z-index: 10;
}

.bar {
  fill: #ffffff;
  opacity: 0.4;
  transform-origin: bottom center;
}

@keyframes signalPulse {
  0%, 100% { transform: scaleY(1); opacity: 0.4; }
  50% { transform: scaleY(1.1); opacity: 1; }
}

.bar-1 { animation: signalPulse 1.2s infinite ease-in-out; }
.bar-2 { animation: signalPulse 1.4s infinite ease-in-out; }
.bar-3 { animation: signalPulse 1.6s infinite ease-in-out; }
.bar-4 { animation: signalPulse 1.8s infinite ease-in-out; }

#bateria-icono {
  position: absolute;
  top: 20px;
  right: 35px; /* Ajusta según tu layout */
  width: 35px;
  height: 30px;
  z-index: 10;
}https://i.ibb.co/yFMWsXmN/Screan1.png

#nivel-bateria {
  transition: width 1s ease-in-out, fill 1s ease-in-out;
}

/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */
#bloques-container {
  position: relative;
  width: 100%;
  height: 100%;
}

/* Botón Clock */
.Clock {
  position: absolute;
  top: 70px;
  left: 40px;
  width: 60px;
  height: 60px;
  border: none;
  background: transparent;
  cursor: pointer;
  padding: 0;
  z-index: 2;
}

.Clock img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

/* ======================= Bloque B1 ======================= */
.bloque-ritual {
  position: absolute;
  top: 68px;
  left: 196px;
  width: 120px;
  height: 120px;
  background-color: rgba(255, 255, 255, 0.08); /* Transparencia ligera */
  border: 2px solid #01010160;                  /* Bisel blanco */
  border-radius: 12%;                         /* Forma burbuja */
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);   /* Sombra externa */
  padding: 12px;
  z-index: 20;
}

/* Modal del reloj */
.modal-reloj {
  position: absolute;
  top: 70px;
  left: 198px;
  width: 140px;
  height: 140px;
  background-color: #000000cc;
  border: 2px solid #ffffff;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 60;
}

.modal-reloj.oculto {
  display: none;
}

/* 🔘 Botón Calculadora */
.Calculator {
  position: absolute;
  top: 70px;
  left: 115px;
  width: 60px;
  height: 60px;
  background: transparent;
  border: none;
  padding: 0;
  cursor: pointer;
  z-index: 20;
}

.Calculator img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

/* 🧮 Modal Calculadora */
.modal-calculadora {
  position: absolute;
  top: 68px;
  left: 196px;
  width: 140px;
  height: 140px;
  background-color: rgba(0, 0, 0, 0.8);
  border: 2px solid #fff;
  border-radius: 12px;
  overflow: hidden;
  z-index: 30;
}

.modal-calculadora.oculto {
  display: none;
}

/* 📦 Contenedor interno */
.iframe-wrapper {
  position: relative;
  width: 100%;
  height: 100%;
}

/* 🔍 Escala y desplazamiento ritual */
.iframe-inner {
  position: absolute;
  margin-top: -124px;
  margin-left: -140px;
  zoom: 0.27;
  width: 800px;
  height: 800px;
  pointer-events: auto;
}

.iframe-inner iframe {
  width: 100%;
  height: 100%;
  border-radius: 12px;
}

/* Boton Camara */
.Camera {
  position: absolute;
  top: 150px;
  left: 36px;
  width: 62px;
  height: 62px;
  background: transparent;
  border: none;
  padding: 0;
  cursor: pointer;
  z-index: 20;
}

.Camera img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

/* Botón Brújula */
.Brujula {
  position: absolute;
  top: 150px;
  left: 115px;
  width: 60px;
  height: 60px;
  background: transparent;
  border: none;
  padding: 0;
  cursor: pointer;
  z-index: 20;
}

.Brujula img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.modal-brujula {
  position: absolute;
  top: 70px;
  left: 198px;
  width: 140px;
  height: 140px;
  background-color: rgba(0, 0, 0, 0.8);
  border: 2px solid #fff;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 30;
}

.Brujula img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  pointer-events: none; /* ← permite que el clic atraviese la imagen */
}

#flecha-direccion {
  transition: transform 0.5s ease;
  transform-origin: 50% 50%;
  margin-bottom: 8px;
}

.modal-brujula.oculto {
  display: none;
}

.brujula-contenido {
  color: #fff;
  font-size: 14px;
  text-align: center;
}

.brujula-contenido {
  color: #fff;
  font-size: 14px;
  text-align: center;
}
/* ======================= Seccion B2 ======================= */
/* Panel de Tiempo */
.info-tiempo {
  position: absolute;
  top: 0px;
  left: 0px;
  padding: 12px;
  width: 120px;
  height: 120px;
  border-radius: 12%;
  color: #fff;
  font-size: 14px;
}

/* ======================= Bloque B2 ======================= */
.bloque-b2 {
  position: absolute;
  top: 340px;
  left: 40px;
  width: 120px;
  height: 120px;
  background-color: rgba(255, 255, 255, 0.08); /* Transparencia ligera */
  border: 2px solid #01010160;                  /* Bisel blanco */
  border-radius: 12%;                         /* Forma burbuja */
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);   /* Sombra externa */
  padding: 12px;
  z-index: 20;
}

/* Botón Weather */
.Weather {
  position: absolute;
  top: 0px;
  left: 160px;
  width: 60px;
  height: 60px;
  background: transparent;
  border: none;
  padding: 0;
  cursor: pointer;
  z-index: 20;
}
.Weather img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

/* ======================= Modal Weather ======================= */
.modal-weather {
  position: absolute;
  top: 0px;
  left: 0px;
  width: 120px;
  height: 120px;
  max-height: 200px; /* ajusta según tu diseño */
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: #c1c1c1 #111;
  background-color: rgba(0, 0, 0, 0.85);
  border: 2px solid #ffffff;
  border-radius: 12px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
  padding: 12px;
  z-index: 30;
  color: #ffffff;
  font-family: 'Courier New', monospace;
}

.modal-weather.oculto {
  display: none;
}

.weather-contenido p,
.weather-contenido h3 {
  margin: 6px 0;
  font-size: 14px;
}

/* Botón YouTube */
.YouTube {
  position: absolute;
  top: 0px;
  left: 240px;
  width: 60px;
  height: 60px;
  background: transparent;
  border: none;
  padding: 0;
  cursor: pointer;
  z-index: 20;
}
.YouTube img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.modal-youtube {
  position: absolute;
  top: 0px;
  left: 0px;
  width: 140px;
  height: 140px;
  background-color: #000000;
  border: 2px solid #ffffff;
  border-radius: 12px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
  z-index: 30;
}

.modal-youtube.oculto {
  display: none;
}

/* Botón Video */
.Video {
  position: absolute;
  top: 420px;
  left: 200px;
  width: 60px;
  height: 60px;
  background: transparent;
  border: none;
  padding: 0;
  cursor: pointer;
  z-index: 10;
}

.Video img {
  width: 60px;
  height: 60px;
  border-radius: 12px;
  object-fit: cover;
}

/* 🎥 Modal envolvente refinado */
#modal-video.modal-video {
  position: absolute;
  top: 10px;
  left: 10px;
  width: 384px;
  height: 760px;
  background-color: rgba(0, 0, 0, 0.85);
  border-radius: 70px;
  overflow: hidden;
  z-index: 9999;
  display: flex;
  justify-content: center;
  align-items: center;
  opacity: 0;
  transform: scale(0.95);
  transition: opacity 0.3s ease, transform 0.3s ease;
}

/* 🧙 Activación ritual */
#modal-video.modal-video:not(.oculto) {
  opacity: 1;
  transform: scale(1);
}

#modal-video.modal-video.oculto {
  display: none !important;
  opacity: 0 !important;
  visibility: hidden !important;
}

/* 🎬 Video contenido */
#video-fondo {
  width: 100%;
  height: auto;
  object-fit: cover;
  border-radius: 24px;
  box-shadow: 0 0 20px rgba(0, 0, 0, 0.6);
  pointer-events: auto;
}

/* 🎮 Botón Juego */
.btn-juego {
  position: absolute;
  top: 80px;
  left: 240px;
  width: 60px;
  height: 60px;
  background: transparent;
  border: none;
  padding: 0;
  cursor: pointer;
  z-index: 20;
}

.btn-juego img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

/* 🕹️ Modal Juego */
#modal-juego {
  position: absolute;
  top: 0;
  left: 100%;
  transform: translate(-50%, -50%);
  width: 384px;
  height: 650px;
  background-color: rgba(0, 0, 0, 0.85);
  border-radius: 50px;
  overflow: hidden !important;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  pointer-events: auto;
}

/* Estado oculto */
.modal-juego.oculto {
  display: none;
}

/* 📦 Contenedor interno */
.wrapper-juego {
  width: 100%;
  height: 100%;
  position: relative;
  overflow: hidden !important;
}

/* 🔳 Juego */
.inner-juego {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 400px;
  height: 645px;
  transform: translate(-50%, -50%);
  overflow: hidden;
  border-radius: 24px;
  background: rgba(0, 0, 0, 0.3); /* guía visual temporal */
  box-shadow: 0 0 12px rgba(0, 0, 0, 0.6);
  display: flex;
  align-items: center;
  justify-content: center;
}

/* 🎮 Iframe del juego */
.inner-juego iframe {
  position: absolute;
  width: 645px;
  height: 645px;
  transform: scale(1.10); /* reduce el ancho a ~355px */
  transform-origin: center;
  border: none;
  display: block;
  pointer-events: auto;
}

@media (max-width: 420px) {
  .inner-juego {
    width: 100%;
    height: 100%;
    border-radius: 0;
  }

  .inner-juego iframe {
    width: 100%;
    height: 100%;
    transform: scale(1);
  }
}

/* ======================= Sección B3 ======================= */
.Notas {
  position: absolute;
  top: 500px;       /* Ajusta según tu layout */
  left: 40px;      /* Ajusta según tu layout */
  width: 60px;
  height: 60px;
  background: transparent;
  border: none;
  padding: 0;
  cursor: pointer;
  z-index: 10;
}

.Notas img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.modal-notas {
  position: absolute;
  top: 500px;
  left: 195px;
  width: 126px;
  height: 126px;
  background-color: rgba(0, 0, 0, 0.85);
  border: 2px solid #FFD700;
  border-radius: 12px;
  padding: 8px; /* ← Ajuste fino para espacio interno */
  box-shadow: 0 0 12px rgba(255, 215, 0, 0.4);
  z-index: 100;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.modal-notas.oculto {
  display: none;
}

#area-notas {
  width: 100%;
  height: 70px; /* ← Ajuste para que el botón quepa sin desbordar */
  background-color: #111;
  color: #FFD700;
  border: 1px solid #FFD700;
  border-radius: 8px;
  padding: 6px;
  resize: none;
  font-family: monospace;
  font-size: 13px; /* ← Ajuste para que no se corte el texto */
  box-sizing: border-box;
}

#guardar-notas {
  width: 100%;
  padding: 4px;
  background-color: #FFD700;
  color: #000;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  font-weight: bold;
  font-size: 12px;
}
/*  BLOQUE B3  */
.bloque-b3 {
  position: absolute;
  top: 500px;
  left: 200px;
  width: 140px;
  height: 140px;
  border: 2px solid #01010160;
  border-radius: 12px;
  overflow: visible;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
  z-index: 10;
}

.fondo-b3 {
  position: absolute;
  border-radius: 12px;
  width: 100%;
  height: 100%;
  background-size: cover;
  background-position: center;
  opacity: 0;
  animation: cicloB3 24s infinite;
}

/*BG-Backgrounds */
.fondo-1 { background-image: url("https://i.ibb.co/4ZFwmQZv/Apple1.jpg"); animation-delay: 0s; }
.fondo-2 { background-image: url("https://i.ibb.co/fV28Vm4C/Apple2.jpg"); animation-delay: 6s; }
.fondo-3 { background-image: url("https://i.ibb.co/q3Tcrcxf/Apple3.jpg"); animation-delay: 12s; }
.fondo-4 { background-image: url("https://i.ibb.co/S7n9HKKy/Apple4.jpg"); animation-delay: 18s; }

@keyframes cicloB3 {
  0%   { opacity: 0; }
  5%   { opacity: 1; }
  25%  { opacity: 1; }
  30%  { opacity: 0; }
  100% { opacity: 0; }
}

/* Botón Photos */
.Fotos {
  position: absolute;
  top: 500px;
  left: 120px;
  width: 60px;
  height: 60px;
  background: transparent;
  border: none;
  padding: 0;
  cursor: pointer;
  z-index: 10;
}

.Fotos img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.carrusel-contenido {
  display: flex;
  flex-direction: column; /* ← Esto es clave */
  align-items: center;
  justify-content: flex-start;
  overflow-y: auto;
  height: 100%;
  width: 100%;
  gap: 12px;
}

.modal-slider-fotos {
  position: fixed;
  top: 506px;
  left: 206px;
  width: 120px;
  height: 120px;
  background-color: rgba(0, 0, 0, 0.85);
  border: 2px solid #010101;
  border-radius: 12px;
  padding: 12px;
  box-shadow: 0 0 12px rgba(0, 0, 0, 0.4);
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow-x: auto;
  gap: 12px;
  scroll-behavior: smooth;
}

.modal-slider-fotos.oculto {
  display: none;
}

.carrusel-contenido::-webkit-scrollbar {
  width: 2px;
}

.carrusel-contenido::-webkit-scrollbar-track {
  background: transparent;
}

.carrusel-contenido::-webkit-scrollbar-thumb {
  background-color: rgba(255, 255, 255, 0.2);
  border-radius: 4px;
}

.foto-mini {
  width: 80px;
  height: 80px;
  object-fit: cover;
  border-radius: 8px;
  cursor: pointer;
  transition: transform 0.3s ease;
}

.foto-mini:hover {
  transform: scale(1.1);
}

.foto-expandida {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background-color: rgba(0, 0, 0, 0.9);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
}

.foto-expandida.oculto {
  display: none;
}

#imagen-grande {
  max-width: 90%;
  max-height: 90%;
  border: 2px solid #010101;
  border-radius: 12px;
  box-shadow: 0 0 20px rgba(0, 0, 0, 0.5);
}

/* ============================= Botones Notificaciones ============================= */
/* Contenedor de burbujas */
.notificaciones-container {
  position: absolute;
  top: 60px;
  left: 102px;
  width: 180px;
  display: flex;
  flex-direction: column-reverse;
  gap: 10px;
  z-index: 20;
}

.oculto {
  display: none;
}
/* Botón Mensajes */
.btn-notificaciones {
  position: absolute;
  top: 568px;
  left: 40px;
  width: 65px;
  height: 65px;
  background: transparent;
  border: none;
  padding: 0;
  cursor: pointer;
  z-index: 10;
  display: inline-block;
}

.btn-notificaciones img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  transition: background-color 0.3s ease;
}

/* 🩶 Hover visual */
.btn-notificaciones:hover img {
  background-color: rgba(255, 255, 255, 0.1);
  border-radius: 12px;
}

/* Burbujas flotantes */
.burbuja-notificacion {
  padding: 10px 14px;
  border-radius: 12px;
  font-size: 13px;
  color: #fff;
  background-color: rgba(255, 255, 255, 0.08);
  border: 1px solid #01010160;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.3);
  animation: flotarBurbuja 3s ease-in-out forwards;
  opacity: 0;
  animation-fill-mode: forwards;
}

/* Tipos de burbuja */
.tipo-info   { background-color: rgba(0, 150, 255, 0.7); }
.tipo-error  { background-color: rgba(255, 0, 0, 0.7); }
.tipo-noti { background-color: rgba(255, 215, 0, 0.7); }
.tipo-wsp { background-color: rgba(37, 211, 102, 0.7); }

/* Animación flotante */
@keyframes flotarBurbuja {
  0%   { transform: translateY(20px); opacity: 0; }
  10%  { opacity: 1; }
  50%  { transform: translateY(-10px); }
  90%  { opacity: 1; }
  100% { transform: translateY(-20px); opacity: 0; }
}

/* Botón Play Store */
.Store {
  position: absolute;
  top: 570px;
  left: 120px;
  width: 60px;
  height: 60px;
  background: transparent;
  border: none;
  padding: 0;
  cursor: pointer;
  z-index: 10;
  display: inline-block;
}

.Store img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

/* =========================== Ultima Seccion =========================== */
/* ======================= Bloque iMusic ======================= */
.imusic {
  position: absolute;
  top: 225px; /* Ubicación más baja que B1 */
  left: 38px;
  width: 280px; /* Más largo que B1 */
  min-height: 50px;         /* Mantiene altura mínima */
  height: auto;             /* Se adapta al contenido */
  background-color: rgba(255, 255, 255, 0.08); /* Transparencia ligera */
  border: 2px solid #01010160;                /* Bisel blanco */
  border-radius: 12px;                         /* Forma cápsula */
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);   /* Sombra externa */
  padding: 12px;
  z-index: 20;
}

.track-info {
  width: 100%;
  overflow: hidden;
}

.track-time {
  font-weight: normal;
  font-size: 14px;
  color: #ccc;
  display: block;
  margin-top: 4px;
}

/* ======================= Contenedor iMenu (Decorativo) ======================= */
#capsula-menu {
  position: absolute;
  top: 660px;
  left: 38px;
  width: 280px;
  height: 50px;
  background-color: rgba(255, 255, 255, 0.08);
  border: 2px solid #01010160;
  border-radius: 12px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
  padding: 12px;
  z-index: 20;
  pointer-events: none;
}

/* ======================= Botón ritual iTunes ======================= */
.boton-itunes {
  position: absolute;
  top: 668px; /* Dentro de la cápsula */
  left: 70px;
  width: 60px;
  height: 60px;
  background: transparent;
  border: none;
  padding: 0;
  cursor: pointer;
  z-index: 21;
}

.boton-itunes img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */
/* 🎛️ P6 — Modal universal, reproductor personalizado y controles */
/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */

/* 🪟 Modal envolvente */
#modal-player.modal {
  position: absolute;
  top: 10px;
  left: 10px;
  width: 384px;
  height: 760px;
  background: rgba(0, 0, 0, 0.95);
  border-radius: 70px;
  overflow: hidden;
  z-index: 9999;
  display: flex;
  justify-content: center;
  align-items: center;
  opacity: 0;
  transform: scale(0.95);
  transition: opacity 0.3s ease, transform 0.3s ease;
}

/* 🧙 Activación ritual */
#modal-player.modal:not(.hidden) {
  opacity: 1;
  transform: scale(1);
}

#modal-player.modal.hidden {
  display: none;
}

/* 📦 Contenido del modal */
.modal-content {
  width: 100%;
  height: 100%;
  padding: 1.5rem;
  border-radius: 24px;
  background: rgba(0, 0, 0, 0.3); /* guía visual temporal */
  box-shadow: 0 0 12px rgba(0, 0, 0, 0.6);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-between;
  overflow: hidden;
  color: white;
  text-align: center;
}

/* ❌ Botón de cierre */
.close-modal {
  position: absolute;
  top: 1rem;
  right: 1rem;
  background: none;
  border: none;
  font-size: 2.2rem;
  color: white;
  cursor: pointer;
  z-index: 10000;
}

/* 🎧 Botón de ocultamiento */
.hide-modal {
  position: absolute;
  top: 1.2rem;
  left: 0.8rem;
  background: none;
  border: none;
  font-size: 1.2rem;
  color: white;
  cursor: pointer;
  z-index: 10000;
}

/* 🖼️ Carátula */
.cover {
  width: 240px;
  height: 240px;
  overflow: hidden;
  border-radius: 1rem;
  margin-top: 1rem;
}

.cover img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  border-radius: 14px;
  box-shadow: 0 0 12px rgba(0,0,0,0.4);
  transition: transform 0.4s ease;
}

.cover img.animate {
  transform: scale(1.05);
}

/* ℹ️ Información de pista */
.info {
  margin-top: 1rem;
  font-size: 1rem;
}

/* ▶️ Reproductor personalizado */
.custom-player {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-top: 1rem;
  width: 100%;
}

.play-btn {
  background: #222;
  color: white;
  border: none;
  padding: 0.5rem 1rem;
  font-size: 1.2rem;
  border-radius: 0.5rem;
  cursor: pointer;
  transition: transform 0.2s ease;
}

.play-btn:hover {
  transform: scale(1.1);
}

.play-btn i {
  font-size: 1.5rem;
  color: white;
  transition: transform 0.2s ease;
}

.play-btn:hover i {
  transform: scale(1.2);
}

/* 📊 Barra de progreso */
.progress-container {
  flex: 1;
  height: 6px;
  background: #333;
  border-radius: 3px;
  overflow: hidden;
  position: relative;
}

.progress-bar {
  height: 100%;
  width: 0%;
  background: #1db954;
  transition: width 0.2s ease;
}

/* ⬅️➡️ Navegación entre pistas */
.modal-nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
  padding: 1rem 0;
  gap: 1rem;
}

.nav-btn {
  background: #222;
  color: white;
  border: none;
  padding: 0.5rem 1rem;
  font-size: 1.2rem;
  border-radius: 0.5rem;
  cursor: pointer;
}

.nav-btn:disabled {
  opacity: 0.4;
  cursor: not-allowed;
  background: #333;
  color: #aaa;
}

/* 📜 Cola visual de pistas */
.modal-queue {
  list-style: none;
  padding: 0;
  margin-top: 1rem;
  max-height: 220px;
  overflow-y: auto;
  border-top: 1px solid #333;
  scrollbar-width: thin;
  scrollbar-color: #1db954 #111;
  width: 100%;
}

/* 🎛️ Controles extendidos */
.modal-controls {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  margin-top: 1rem;
  align-items: center;
  justify-content: center;
  color: white;
}

/* 🎶 Ítems individuales de la cola */
.modal-queue-item {
  padding: 0.5rem 1rem;
  cursor: pointer;
  transition: background 0.3s ease, color 0.3s ease;
  color: #ccc;
  font-size: 0.9rem;
  border-bottom: 1px solid #222;
}

/* 🌟 Hover ceremonial */
.modal-queue-item:hover {
  background: rgba(255, 255, 255, 0.05);
  color: #fff;
}

/* 🔊 Track activo */
.modal-queue-item.active {
  background: linear-gradient(90deg, #1db954 0%, #111 100%);
  color: white;
  font-weight: bold;
  border-left: 4px solid #1db954;
}

/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */
/* 📱 Final — Responsividad móvil para el reproductor modal        */
/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */

@media (max-width: 768px) {
  /* 📦 Modal compacto */
  .modal-content {
    padding: 1rem;
    font-size: 0.9rem;
    max-width: 90%;
    border-radius: 0.75rem;
  }

  /* 🖼️ Carátula centrada */
  .cover img {
    max-width: 160px;
    height: auto;
    margin: 0 auto;
  }

  /* 🎛️ Controles extendidos en columna */
  .modal-controls {
    flex-direction: column;
    gap: 0.75rem;
  }

  /* ▶️ Reproductor en columna */
  .custom-player {
    flex-direction: column;
    gap: 0.75rem;
  }

  /* ⬅️➡️ Navegación espaciada */
  .modal-nav {
    flex-direction: row;
    justify-content: space-around;
    padding: 0.5rem 0;
  }

  /* 📜 Cola visual más compacta */
  .modal-queue {
    max-height: 30vh;
    font-size: 0.85rem;
    padding: 0.5rem;
  }

  /* 📊 Barra de progreso adaptativa */
  .progress-container {
    width: 100%;
    height: 6px;
  }

  /* ▶️ Botón de reproducción táctil */
  .play-btn {
    font-size: 1.4rem;
    padding: 0.75rem 1.25rem;
  }

  /* ⬅️➡️ Botones de navegación táctil */
  .nav-btn {
    font-size: 1rem;
    padding: 0.5rem 0.75rem;
  }

  /* ❌ Cierre accesible */
  .close-modal {
    font-size: 1.8rem;
    top: 0.5rem;
    right: 0.5rem;
  }
}

/* 🎶 Metadatos en Bloque Music */
#bloque-iMusic .track-info {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 8px;
  height: 60px;
  overflow: hidden;
}

/* 🎧 Carátula restaurada */
#bloque-iMusic .caratula-mini {
  width: 80px !important;
  height: 80px !important;
  object-fit: cover;
  border-radius: 8px;
  flex-shrink: 0;
  display: block;
}

/* 🧾 Metadatos */
#bloque-iMusic .meta {
  font-family: 'Helvetica Neue', sans-serif;
  color: #fff;
  line-height: 1.2;
}

/* Botón Power */
.boton-power {
  position: absolute;
  top: 668px;
  left: 160px;
  width: 60px;
  height: 60px;
  background: transparent;
  border: none;
  padding: 0;
  cursor: pointer;
  z-index: 1000;
}

.boton-power img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

powerOverlay.style.display = "block";
powerOverlay.style.opacity = "1";
powerOverlay.style.visibility = "visible";

.power-overlay {
  position: fixed; /* ← cambia de absolute a fixed */
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  display: flex;
  justify-content: center;
  align-items: center; /* ← centra verticalmente */
  background-color: rgba(0, 0, 0, 0.85);
  z-index: 99999;
}

.power-overlay img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  border-radius: 40px;
    margin-top: -750px; /* mueve la imagen 50px hacia arriba */
    animation: fadePower 6s forwards; /* ← antes 1.8s */
    z-index: 99999;
}

@keyframes fadePower {
  0% {
    opacity: 0;
    transform: scale(0.9);
  }
  50% {
    opacity: 1;
    transform: scale(1.05);
  }
  100% {
    opacity: 0;
    transform: scale(0.8);
  }
}

/* Botón Contactos */
.Contactos {
  position: absolute;
  top: 668px;       /* misma altura que Power */
  left: 250px;      /* desplazado a la derecha respecto a Power */
  width: 60px;
  height: 60px;
  background: transparent;
  border: none;
  padding: 0;
  cursor: pointer;
  z-index: 21;
}

.Contactos img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.close-modal {
  position: absolute;
  top: 20px;
  right: 20px;
  font-size: 28px;
  background: transparent;
  border: none;
  color: white;
  cursor: pointer;
  z-index: 10000;
}

.oculto {
  display: none !important;
  opacity: 0 !important;
  visibility: hidden !important;
}

/* Contenedor principal dentro del modal */
.contacts-container {
  margin-bottom: 20px;
    margin-right: 200px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  width: 100%;
  max-width: 600px;
}

/* Grupo de amigos */
.friends {
  display: flex;
  flex-direction: column;
  gap: 12px;
  width: 100%;
  align-items: center;
}

/* Cada contacto */
.box-friends {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 100%;
  max-width: 200px;
  text-decoration: none;
  margin-bottom: 5px;
  transition: transform 0.3s ease;
}

.box-friends:hover {
  transform: scale(1.05);
}

/* Imagen redonda con aura */
.img-friends {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  background: #00f0ff;
  padding: 5px;
  object-fit: cover;
  z-index: 2;
  transition: box-shadow 0.3s ease;
}

.box-friends:hover .img-friends {
  box-shadow: 0 0 12px #00f0ff;
}

/* Cinta blanca oculta detrás del círculo */
.box-friends h2 {
  position: absolute;
  top: 30%;
  left: 0%;
  transform: translate(30%, -50%) scaleX(0.75); /* ← antes scaleX(0) */
  transform-origin: left center;
  width: 160px;
  height: 40px;
  background: white;
  border-radius: 50px;
  display: flex;
  align-items: center;
  justify-content: center; /* ← antes: flex-start */
  gap: 10px; /* ← espacio entre símbolo y nombre */
  overflow: hidden;
  white-space: nowrap;
  transition: transform 0.4s ease, opacity 0.4s ease;
  z-index: 1;
  padding: 0 12px;
  box-shadow:
    0 0 8px rgba(0, 240, 255, 0.8),
    0 0 16px rgba(0, 240, 255, 0.5);
}

.box-friends:hover h2 {
  transform: translate(65%, -50%) scaleX(1);
  opacity: 1;
}

/* Nombre y símbolo */
.simbol {
  font-size: 1.2em;
  color: #00f0ff;
  flex-shrink: 0;
  margin-left: 40px;
  opacity: 1;
}

.name {
  margin-left: 8px;
  color: #00f0ff;
  opacity: 0;
  transition: opacity 0.4s ease;
}

.box-friends:hover .name {
  opacity: 1;
}

#modal-contacts.modal-universal {
  position: absolute;
  top: 10px;
  left: 10px;
  width: 384px;
  height: 760px;
  background-color: rgba(0, 0, 0, 0.85);
  border-radius: 70px;
  overflow: hidden;
  z-index: 9999;
  display: flex;
  justify-content: center;
  align-items: center;
  opacity: 0;
  transform: scale(0.95);
  transition: opacity 0.3s ease, transform 0.3s ease;
}

#modal-contacts.modal-universal:not(.oculto) {
  opacity: 1;
  transform: scale(1);
}

.close-modal {
  position: absolute;
  top: 20px;
  right: 20px;
  font-size: 28px;
  background: transparent;
  border: none;
  color: white;
  cursor: pointer;
  z-index: 10000;
}
