/* FUENTES */
@font-face {
  font-family: "Ethnocentric";
  src: url("Ethnocentric-Regular.woff2") format("woff2");
}
@font-face {
  font-family: "JetBrains Mono";
  src: url("JetBrainsMono-Medium.woff2") format("woff2");
}

:root {
  --bg-black: #000000;
  --card-dark: #0a0a0a;
  --accent-purple: #a855f7;
  --neon-cyan: #00ffcc;
  --text-dim: #888;
  --border-glass: rgba(255, 255, 255, 0.05);
}

body {
  background-color: var(--bg-black);
  color: #fff;
  font-family: "JetBrains Mono", monospace;
  margin: 0;
  line-height: 1.6;
  padding-top: 95px; /* 35px de top-bar + 60px de nav. Evita que el hero se oculte */
}

h1,
h2,
h3,
h4 {
  font-family: "Ethnocentric", sans-serif;
  letter-spacing: 1px;
  margin: 0;
}

/* CONTENEDOR PRINCIPAL */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 5%;
}

/* --- CONFIGURACIÓN GLOBAL DE NAV --- */
nav {
  position: fixed;
  top: 0; /* Ahora el nav manda en la parte superior */
  width: 100%;
  height: 60px;
  background: rgba(0, 0, 0, 0.85);
  backdrop-filter: blur(15px);
  -webkit-backdrop-filter: blur(15px);
  z-index: 5000; /* Máxima prioridad para cubrir el texto al hacer scroll */
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  display: flex;
  justify-content: center;
}

.top-bar {
  position: fixed;
  top: 60px; /* Se queda anclada exactamente debajo del nav */
  left: 0;
  width: 100%;
  height: 35px;
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 4000; /* Un nivel por debajo del nav */
  background: rgba(0, 0, 0, 0.95);
  border-bottom: 1px solid rgba(0, 255, 204, 0.2);
}

.nav-container {
  width: 100%;
  max-width: 1200px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0 5%;
}

.brand-container {
  display: flex;
  align-items: center;
  gap: 12px;
}

.isologo-nav {
  height: 25px;
}
.logo-text-nav {
  height: 18px;
}

.text-mobile {
  display: none;
}

.top-bar p {
  font-family: "JetBrains Mono", monospace;
  font-size: 0.65rem;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  margin: 0;
  background: linear-gradient(90deg, #00ffcc, #a855f7);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  font-weight: bold;
  text-align: center;
  width: 100%;
}

/* --- PC: ENLACES --- */
.nav-links {
  display: flex;
  list-style: none;
  gap: 25px;
  align-items: center;
}

.nav-links a {
  text-decoration: none;
  color: #fff;
  font-size: 0.7rem;
  font-weight: bold;
  letter-spacing: 1px;
  transition: 0.3s;
}

.nav-links a:hover {
  color: var(--neon-cyan);
}

.menu-toggle {
  display: none; /* Oculto en PC por defecto */
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  z-index: 6500;
}

.menu-toggle .bar {
  width: 25px;
  height: 2px;
  background-color: #fff;
  transition: all 0.3s ease;
}

/* --- MÓVIL: HAMBURGUESA --- */
@media (max-width: 850px) {
  body {
    padding-top: 95px; /* Sigue igual: 60px del nav + 35px de la top-bar */
  }

  nav {
    top: 0;
    width: 100%;
  }

  .menu-toggle {
    display: flex !important;
    position: fixed;
    top: 17px; /* Perfectamente centrado en la altura de 60px del nav */
    right: 5%;
    z-index: 6500;
    cursor: pointer;
  }

  /* Corrección de la barra superior en móvil */
  .top-bar {
    padding: 0 15px;
    box-sizing: border-box;
  }

  .top-bar p {
    font-size: 0.55rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    width: 100%;
    text-align: center;
  }

  /* Animación de la Hamburguesa a 'X' */
  .menu-toggle.is-active .bar:nth-child(1) {
    transform: translateY(8px) rotate(45deg);
    background-color: var(--neon-cyan);
  }
  .menu-toggle.is-active .bar:nth-child(2) {
    opacity: 0;
  }
  .menu-toggle.is-active .bar:nth-child(3) {
    transform: translateY(-8px) rotate(-45deg);
    background-color: var(--neon-cyan);
  }

  .nav-links {
    position: fixed;
    top: 0;
    right: -100%;
    width: 100%;
    height: 100vh;
    background: rgba(0, 0, 0, 0.98);
    backdrop-filter: blur(25px);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 35px;
    padding: 0;
    margin: 0;
    list-style: none;
    transition: 0.5s cubic-bezier(0.77, 0, 0.175, 1);
    z-index: 6000; /* Mayor que la top-bar (5000) para cubrirla al abrirse */
  }

  .nav-links.active {
    right: 0;
  }

  .nav-links li {
    width: 100%;
    text-align: center;
  }

  .nav-links a {
    font-size: 1.5rem;
    font-family: "Ethnocentric", sans-serif;
    display: block;
    width: 100%;
  }

  .logo-text-nav {
    display: none;
  }
}

/* HERO */
.hero {
  height: 100vh;
  display: flex;
  justify-content: center;
  align-items: center;
  text-align: center;
  padding-top: 20px; /* Compensación ajustada porque el body ya tiene padding */
}

.hero-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
  width: 100%;
  max-width: 1200px;
  padding: 0 5%;
}

.hero-video {
  width: 220px;
}

.hero-identity {
  width: 350px;
  max-width: 80%;
  margin-bottom: 15px;
}

.hero-subtitle {
  font-size: 0.8rem;
  color: var(--neon-cyan);
  letter-spacing: 5px;
}

/* --- VISTA ESCRITORIO (PC): SPLIT LAYOUT --- */
@media (min-width: 850px) {
  .hero-content {
    flex-direction: row;
    justify-content: space-between;
    text-align: left;
    gap: 50px;
  }

  .hero-text {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
  }

  .hero-visual {
    flex: 1;
    display: flex;
    justify-content: center;
  }

  .hero-video {
    width: 320px;
  }

  .hero-identity {
    width: 450px;
    max-width: 100%;
  }
}

/* SECCIÓN INVITACIONES */
.section {
  padding: 80px 0;
}
.section-heading {
  text-align: center;
  margin-bottom: 50px;
  font-size: 1.5rem;
  opacity: 0.9;
}

.invitaciones-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 30px;
  max-width: 1200px;
  margin: 0 auto;
  padding: 20px;
  justify-items: center;
}

.inv-card {
  position: relative;
  width: 100%;
  max-width: 280px;
  aspect-ratio: 9 / 16;
  background: rgba(15, 15, 15, 0.7);
  backdrop-filter: blur(15px);
  border-radius: 35px;
  border: 1px solid var(--border-glass);
  transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
  overflow: hidden; /* Evita que el notch se salga */
}

.inv-card:hover {
  transform: translateY(-10px);
  border-color: var(--accent-purple);
}

.preview-box {
  width: 100%;
  aspect-ratio: 16/9;
  background: #000;
}
.preview-box video,
.preview-box img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.card-info {
  padding: 25px;
  text-align: center;
}
.card-tag {
  font-size: 0.6rem;
  color: var(--text-dim);
}
.card-info h3 {
  font-size: 1rem;
  margin: 10px 0 20px;
}

.card-actions {
  display: grid;
  gap: 10px;
}
.btn-action-primary {
  background: var(--accent-purple);
  color: #fff;
  text-decoration: none;
  padding: 12px;
  font-size: 0.7rem;
  border-radius: 5px;
}
.btn-action-secondary {
  border: 1px solid var(--neon-cyan);
  color: var(--neon-cyan);
  text-decoration: none;
  padding: 12px;
  font-size: 0.7rem;
  border-radius: 5px;
}

/* PROTOCOLO TÉCNICO / SERVICIOS */
.protocolo-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 20px;
}

.proto-card {
  background: var(--card-dark);
  padding: 40px 20px;
  border-radius: 15px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.proto-icon {
  width: 100%;
  height: 110px;
  object-fit: contain;
  margin-bottom: 20px;
  z-index: 2;
}

.proto-body {
  z-index: 2;
  width: 100%;
}

.num {
  font-size: 5rem;
  color: rgba(255, 255, 255, 0.06);
  position: absolute;
  top: -10px;
  right: 15px;
  font-weight: 900;
  pointer-events: none;
  user-select: none;
  z-index: 1;
}

@media (max-width: 850px) {
  .num {
    color: rgba(255, 255, 255, 0.1);
    font-size: 4rem;
  }
}

/* ESTADÍSTICAS */
.stats-container {
  margin-top: 60px;
  padding: 40px;
  background: rgba(255, 255, 255, 0.02);
  display: flex;
  justify-content: space-around;
  border-radius: 20px;
  flex-wrap: wrap;
  gap: 30px;
}
.stat-item h4 {
  font-size: 2rem;
  color: #fff;
}
.stat-item p {
  font-size: 0.7rem;
  color: var(--text-dim);
}

/* HELIX ADVENTURE BANNER */
.adventure-banner {
  background: linear-gradient(90deg, #0a0a0a, #151515);
  border: 1px solid var(--accent-purple);
  padding: 40px;
  border-radius: 20px;
  display: flex;
  align-items: center;
  gap: 40px;
  margin: 40px 0;
}
.adventure-img {
  width: 120px;
}
.adventure-text h3 {
  margin-bottom: 10px;
  color: var(--accent-purple);
}
.adventure-text p {
  font-size: 0.8rem;
  color: var(--text-dim);
  margin-bottom: 20px;
}

/* FOOTER */
footer {
  padding: 60px 0;
  border-top: 1px solid var(--border-glass);
  text-align: center;
}
.footer-grid {
  display: flex;
  justify-content: center;
  gap: 100px;
  margin-bottom: 40px;
}
.footer-logo {
  height: 40px;
  margin-bottom: 15px;
}

/* --- REDISEÑO QUIRÚRGICO WIDGET HELIX --- */
.helix-widget {
  position: fixed;
  bottom: 30px;
  right: 30px;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 15px;
}

.helix-trigger {
  width: 70px;
  height: 70px;
  background: #000;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 50%;
  display: flex;
  justify-content: center;
  align-items: center;
  cursor: pointer;
  transition:
    transform 0.3s ease,
    border-color 0.3s ease;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.5);
}

.helix-trigger:hover {
  transform: scale(1.05);
  border-color: var(--neon-cyan);
}

.helix-img-trigger {
  width: 50px;
}

.helix-menu {
  position: absolute;
  bottom: 90px;
  right: 0;
  background: rgba(5, 5, 5, 0.9);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid var(--border-glass);
  border-top: 2px solid var(--neon-cyan);
  border-radius: 12px;
  padding: 15px 10px;
  display: none;
  flex-direction: column;
  gap: 5px;
  min-width: 240px;
  box-shadow:
    0 15px 35px rgba(0, 0, 0, 0.8),
    0 -5px 20px rgba(0, 255, 204, 0.1);
}

.helix-menu.active {
  display: flex;
  animation: slideUpFade 0.4s ease forwards;
}

.menu-item {
  text-decoration: none;
  color: #aaa;
  font-family: "JetBrains Mono", monospace;
  font-size: 0.75rem;
  font-weight: bold;
  padding: 12px 15px;
  border-radius: 6px;
  transition: all 0.3s ease;
  display: flex;
  align-items: center;
  gap: 12px;
  border-left: 2px solid transparent;
}

.tech-arrow {
  color: var(--accent-purple);
  font-weight: 900;
  opacity: 0.5;
  transition: 0.3s;
}

.menu-item:hover {
  background: linear-gradient(90deg, rgba(0, 255, 204, 0.1), transparent);
  color: #fff;
  border-left: 2px solid var(--neon-cyan);
}

.menu-item:hover .tech-arrow {
  color: var(--neon-cyan);
  opacity: 1;
  transform: translateX(4px);
}

/* Desbloqueo del widget de Helix en móvil */
.chat-bubble {
  background: #fff !important; /* Obliga al fondo a ser blanco */
  color: #000 !important; /* Obliga al texto a ser negro */
  font-size: 0.65rem;
  padding: 8px 10px;
  min-width: 140px;
}

@keyframes slideUpFade {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.preview-box {
  filter: blur(10px) grayscale(0.5);
  transition:
    filter 0.6s ease,
    transform 0.6s ease;
}

.inv-card:hover .preview-box,
.inv-card.is-active .preview-box {
  filter: blur(0) grayscale(0);
}

.btn-action-primary {
  background: #a855f7;
  color: white;
}

.btn-action-secondary {
  border: 1px solid #00ffcc;
  color: #00ffcc;
}

/* DISEÑO DE TARJETAS RECTANGULARES (ESTILO MÓVIL) */
.invitaciones-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 30px;
  padding: 20px;
  justify-items: center;
}

.inv-card {
  position: relative;
  width: 100%;
  max-width: 280px;
  aspect-ratio: 9 / 16;
  background: rgba(15, 15, 15, 0.7);
  backdrop-filter: blur(15px) saturate(160%);
  -webkit-backdrop-filter: blur(15px) saturate(160%);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 35px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: all 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

.card-notch {
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 100px;
  height: 18px;
  background: #000;
  border-bottom-left-radius: 12px;
  border-bottom-right-radius: 12px;
  z-index: 10;
}

.inv-card:hover {
  transform: scale(1.03) translateY(-10px);
  border-color: var(--neon-cyan);
  box-shadow: 0 15px 45px rgba(0, 255, 204, 0.15);
}

.preview-box {
  flex: 1;
  overflow: hidden;
  filter: blur(20px) brightness(0.4);
  transition: all 0.7s ease;
}

.inv-card:hover .preview-box,
.inv-card.is-active .preview-box {
  filter: blur(0) brightness(1);
}

.preview-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.card-content {
  padding: 20px;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.8), transparent);
  text-align: center;
}

.card-header h3 {
  font-family: "Ethnocentric", sans-serif;
  font-size: 0.8rem;
  margin-bottom: 15px;
  color: #fff;
}

.card-tag {
  font-family: "JetBrains Mono", monospace;
  font-size: 0.55rem;
  color: var(--neon-cyan);
  letter-spacing: 1px;
}

.card-actions {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.btn-modern-primary,
.btn-modern-ghost {
  font-size: 0.6rem;
  padding: 10px;
  border-radius: 10px;
  text-decoration: none;
  font-weight: bold;
  transition: 0.3s;
}

.btn-modern-primary {
  background: #fff;
  color: #000;
}

.btn-modern-ghost {
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: #fff;
}

.btn-catalog,
.btn-download {
  display: inline-block;
  padding: 15px 35px;
  border-radius: 50px;
  font-family: "Ethnocentric", sans-serif;
  font-size: 0.7rem;
  text-decoration: none;
  letter-spacing: 2px;
  transition: all 0.3s ease;
  text-transform: uppercase;
  cursor: pointer;
  border: 1px solid var(--neon-cyan);
  color: var(--neon-cyan);
  background: transparent;
  box-shadow: 0 0 10px rgba(0, 255, 204, 0.2);
}

.btn-catalog:hover,
.btn-download:hover {
  background: var(--neon-cyan);
  color: #000;
  box-shadow: 0 0 25px var(--neon-cyan);
  transform: translateY(-3px);
}

.btn-white.special {
  background: transparent;
  border: 1px solid var(--accent-purple);
  color: var(--accent-purple);
}

.btn-white.special:hover {
  background: var(--accent-purple);
  color: #fff;
  box-shadow: 0 0 25px var(--accent-purple);
}

@media (max-width: 850px) {
  .nav-links {
    position: fixed;
    top: 0;
    right: -100%;
    width: 80%;
    height: 100vh;
    background: rgba(0, 0, 0, 0.95);
    backdrop-filter: blur(20px);
    flex-direction: column;
    justify-content: center;
    gap: 40px;
    transition: 0.5s cubic-bezier(0.77, 0, 0.175, 1);
    border-left: 1px solid var(--border-glass);
    z-index: 6000;
  }

  .nav-links.active {
    right: 0;
  }

  .adventure-banner {
    flex-direction: column !important;
    text-align: center;
    padding: 40px 20px;
    margin: 20px 5%;
    gap: 20px;
  }

  .adventure-img {
    width: 140px;
    margin-bottom: 10px;
  }

  .adventure-text h3 {
    font-size: 1.2rem;
  }

  .footer-grid {
    flex-direction: column;
    gap: 50px;
    text-align: center;
  }

  .footer-brand,
  .footer-col {
    align-items: center;
    display: flex;
    flex-direction: column;
  }

  .chat-bubble {
    font-size: 0.65rem;
    padding: 8px 10px;
    min-width: 140px;
  }

  .helix-widget {
    bottom: 20px;
    right: 20px;
    gap: 10px;
  }

  .helix-trigger {
    width: 60px;
    height: 60px;
  }
}

.estudio-grid {
  display: flex;
  align-items: center;
  gap: 50px;
  background: rgba(10, 10, 10, 0.6);
  backdrop-filter: blur(15px);
  border: 1px solid var(--border-glass);
  border-radius: 20px;
  padding: 50px;
  margin-bottom: 40px;
}

.estudio-grid.reverse {
  flex-direction: row-reverse;
}

.estudio-text {
  flex: 1;
  text-align: left;
}

.estudio-text p {
  color: var(--text-dim);
  font-size: 0.85rem;
  margin-bottom: 15px;
}

.estudio-visual {
  flex: 1;
  display: flex;
  justify-content: center;
  background: transparent;
  padding: 0;
  border: none;
}

@media (max-width: 850px) {
  .estudio-grid,
  .estudio-grid.reverse {
    flex-direction: column;
    padding: 30px;
    text-align: center;
  }
  .estudio-text {
    text-align: center;
  }
}

a.link-card {
  text-decoration: none;
  color: inherit;
  transition:
    transform 0.4s cubic-bezier(0.16, 1, 0.3, 1),
    border-color 0.4s ease,
    box-shadow 0.4s ease;
  border: 1px solid transparent;
}

a.link-card p {
  margin-bottom: 15px;
  font-size: 0.75rem;
}

.card-link-text {
  font-family: "JetBrains Mono", monospace;
  font-size: 0.65rem;
  font-weight: bold;
  letter-spacing: 1px;
  opacity: 0.6;
  transition:
    opacity 0.3s ease,
    transform 0.3s ease;
  display: inline-block;
}

a.link-card:hover {
  transform: translateY(-10px);
  background: rgba(15, 15, 15, 0.9);
}

a.link-card:hover .card-link-text {
  opacity: 1;
  transform: translateX(5px);
}

a.link-card:nth-child(1):hover {
  border-color: var(--accent-purple);
  box-shadow: 0 10px 30px rgba(168, 85, 247, 0.15);
}

a.link-card:nth-child(2):hover {
  border-color: var(--neon-cyan);
  box-shadow: 0 10px 30px rgba(0, 255, 204, 0.15);
}

a.link-card:nth-child(3):hover {
  border-color: rgba(255, 255, 255, 0.3);
  box-shadow: 0 10px 30px rgba(255, 255, 255, 0.05);
}

.true-carousel-wrapper {
  position: relative;
  max-width: 800px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 15px;
}

.true-carousel-track {
  display: flex;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  scrollbar-width: none;
  gap: 20px;
  flex: 1;
  border-radius: 20px;
  padding-bottom: 10px;
}

.true-carousel-track::-webkit-scrollbar {
  display: none;
}

.true-slide {
  flex: 0 0 100%;
  scroll-snap-align: center;
  display: flex;
  flex-direction: column;
  background: rgba(15, 15, 15, 0.7);
  backdrop-filter: blur(15px);
  border: 1px solid var(--border-glass);
  border-radius: 20px;
  overflow: hidden;
}

.slide-image-box {
  width: 100%;
  height: 350px;
  background: #050505;
  display: flex;
  justify-content: center;
  align-items: center;
}

.slide-image-box img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  padding: 20px;
}

.slide-text {
  padding: 30px;
  text-align: center;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
}

.slide-text h4 {
  font-family: "Ethnocentric", sans-serif;
  font-size: 0.9rem;
  margin-bottom: 15px;
}

.slide-text p {
  font-family: "JetBrains Mono", monospace;
  font-size: 0.8rem;
  color: var(--text-dim);
  line-height: 1.5;
}

.carousel-btn {
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
  border: 1px solid var(--border-glass);
  width: 40px;
  height: 40px;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  justify-content: center;
  align-items: center;
  transition: all 0.3s ease;
  z-index: 10;
}

.carousel-btn:hover {
  background: var(--neon-cyan);
  color: #000;
  transform: scale(1.1);
  box-shadow: 0 0 15px rgba(0, 255, 204, 0.4);
}

@media (max-width: 850px) {
  .carousel-btn {
    display: none;
  }
  .slide-image-box {
    height: 250px;
  }
}

.modal {
  display: none;
  position: fixed;
  z-index: 4000;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.95);
  backdrop-filter: blur(15px);
  justify-content: center;
  align-items: center;
}

.modal.active {
  display: flex;
  animation: fadeIn 0.3s ease;
}

.modal-body {
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 100%;
  max-width: 800px;
  padding: 0 20px;
}

.modal-content {
  max-width: 100%;
  max-height: 60vh;
  object-fit: contain;
  border-radius: 10px;
  box-shadow: 0 0 30px rgba(0, 255, 204, 0.2);
  margin-bottom: 25px;
}

.modal-caption {
  text-align: center;
  color: white;
}

.modal-caption h4 {
  font-family: "Ethnocentric", sans-serif;
  font-size: 1rem;
  color: var(--neon-cyan);
  margin-bottom: 10px;
}

.modal-caption p {
  font-family: "JetBrains Mono", monospace;
  font-size: 0.85rem;
  color: #ccc;
  line-height: 1.5;
}

.modal-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
  border: 1px solid var(--border-glass);
  width: 50px;
  height: 50px;
  border-radius: 50%;
  font-size: 20px;
  cursor: pointer;
  z-index: 4001;
  transition: all 0.3s ease;
  display: flex;
  justify-content: center;
  align-items: center;
}

.modal-btn:hover {
  background: var(--neon-cyan);
  color: #000;
  box-shadow: 0 0 20px rgba(0, 255, 204, 0.5);
  transform: translateY(-50%) scale(1.1);
}

.prev-modal {
  left: 5%;
}
.next-modal {
  right: 5%;
}

.close-modal {
  position: absolute;
  top: 20px;
  right: 40px;
  color: #fff;
  font-size: 45px;
  font-weight: bold;
  cursor: pointer;
  transition: color 0.3s ease;
  z-index: 4001;
}

.close-modal:hover {
  color: var(--neon-cyan);
}

@media (max-width: 850px) {
  .prev-modal {
    left: 2%;
    width: 40px;
    height: 40px;
  }
  .next-modal {
    right: 2%;
    width: 40px;
    height: 40px;
  }
  .modal-content {
    max-height: 50vh;
  }
}

@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

.iframe-container {
  position: relative;
  width: 90vw;
  max-width: 375px;
  height: 75vh;
  max-height: 800px;
  background: #050505;
  border-radius: 35px;
  border: 2px solid var(--neon-cyan);
  overflow: hidden;
  box-shadow:
    0 0 40px rgba(0, 255, 204, 0.2),
    inset 0 0 20px rgba(0, 0, 0, 1);
  display: flex;
  justify-content: center;
  align-items: center;
}

#preview-frame {
  position: relative;
  width: 100%;
  height: 100%;
  border: none;
  z-index: 2;
  background: #000;
}

.iframe-loader {
  position: absolute;
  color: var(--neon-cyan);
  font-family: "JetBrains Mono", monospace;
  font-size: 0.8rem;
  z-index: 1;
  animation: pulse 1.5s infinite;
}

@keyframes pulse {
  0% {
    opacity: 0.5;
  }
  50% {
    opacity: 1;
  }
  100% {
    opacity: 0.5;
  }
}

/* Intercambio de texto */
.text-desktop {
  display: none !important;
}
.text-mobile {
  display: block !important;
}

/* Aseguramos que en móvil el texto baje de tamaño y NO pierda el color */
.top-bar p {
  white-space: normal !important;
  overflow: visible !important;
  font-size: 0.55rem !important;
  /* Candado para el degradado en móvil */
  background: linear-gradient(90deg, #00ffcc, #a855f7) !important;
  -webkit-background-clip: text !important;
  background-clip: text !important;
  color: transparent !important;
}

@media (max-width: 600px) {
  .chat-bubble {
    background: #fff !important;
    color: #000 !important;
    font-size: 0.65rem;
    padding: 8px 10px;
    min-width: 140px;
    pointer-events: none !important; /* Para que no estorbe toques */
  }

  .helix-widget {
    bottom: 20px;
    right: 20px;
    gap: 10px;
  }

  .helix-trigger {
    width: 60px;
    height: 60px;
  }
}
