:root {
  --fondo: #070d1a;
  --azul-marino: #0f1b33;
  --gris: #1c2433;
  --texto: #cbd5e1;
  --cian: #22d3ee;
  --capa-ui: 2147483000;
}

html, body {
  margin: 0;
  height: 100%;
  overflow: hidden;
  background: var(--fondo);
  color: var(--texto);
  font-family: system-ui, "Segoe UI", Roboto, sans-serif;
}

.titulo {
  position: fixed;
  top: 20px;
  left: 24px;
  z-index: var(--capa-ui);
  font-size: 15px;
  letter-spacing: 0.04em;
  color: #e2e8f0;
  pointer-events: none;
}

.indicacion {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%);
  z-index: var(--capa-ui);
  padding: 8px 16px;
  font-size: 13px;
  white-space: nowrap;
  background: rgba(15, 27, 51, 0.75);
  border: 1px solid rgba(34, 211, 238, 0.25);
  border-radius: 999px;
  backdrop-filter: blur(6px);
  pointer-events: none;
}

.etiqueta {
  position: fixed;
  top: 0;
  left: 0;
  z-index: var(--capa-ui);
  padding: 4px 10px;
  font-size: 13px;
  font-weight: 600;
  color: #e2e8f0;
  background: var(--gris);
  border: 1px solid var(--cian);
  border-radius: 6px;
  opacity: 0;
  transition: opacity 0.2s ease;
  pointer-events: none;
}

.etiqueta.visible {
  opacity: 1;
}

body.sobre-componente .a-canvas {
  cursor: pointer !important;
}

@media (prefers-reduced-motion: reduce) {
  .etiqueta {
    transition: none;
  }
}


/* Fondo de la ventana */
.ventana-fondo {
  position: fixed;
  inset: 0;
  z-index: 2147483001;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(3, 8, 18, 0.65);
  backdrop-filter: blur(0px);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.35s ease, backdrop-filter 0.35s ease,
              visibility 0.35s ease;
}

.ventana-fondo.activa {
  opacity: 1;
  visibility: visible;
  backdrop-filter: blur(8px);
}

.ventana {
  position: relative;
  width: min(650px, 85vw);
  max-height: 75vh;
  overflow-y: auto;
  padding: 40px;
  color: #e2e8f0;
  background: rgba(10, 20, 38, 0.96);
  border: 1px solid rgba(34, 211, 238, 0.5);
  border-radius: 16px;
  box-shadow:
    0 0 25px rgba(34, 211, 238, 0.12),
    0 0 80px rgba(34, 211, 238, 0.08);
  transform: translateY(25px) scale(0.95);
  transition: transform 0.4s cubic-bezier(.2,.8,.2,1);
}

.ventana-fondo.activa .ventana {
  transform: translateY(0) scale(1);
}

.ventana-subtitulo {
  color: #22d3ee;
  font-size: 11px;
  letter-spacing: 3px;
}

.ventana h2 {
  font-size: 32px;
  margin: 15px 0 25px;
  color: #ffffff;
}

.ventana h3 {
  color: #22d3ee;
}

.ventana p {
  color: #aabbd0;
  line-height: 1.8;
}

.cerrar {
  position: absolute;
  top: 15px;
  right: 20px;
  width: 35px;
  height: 35px;
  border: 1px solid rgba(34, 211, 238, 0.3);
  border-radius: 8px;
  background: transparent;
  color: #22d3ee;
  font-size: 25px;
  cursor: pointer;
  transition: 0.2s;
}

.cerrar:hover {
  background: #22d3ee;
  color: #07111f;
}

.proyecto {
  padding: 12px 16px;
  margin-top: 12px;
  background: rgba(34, 211, 238, 0.05);
  border-left: 2px solid #22d3ee;
  border-radius: 5px;
}

.proyecto h4 {
  color: #ffffff;
  margin: 5px 0;
}

@media (max-width: 600px) {
  .ventana {
    padding: 28px 22px;
    width: 82vw;
  }

  .ventana h2 {
    font-size: 25px;
  }
}
