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

body {
  font-family: system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
  background: #050507;
  color: #e8e8e8;
  min-height: 100vh;
  overflow-x: hidden;
}

/* fondo animado */

body::before {
  content: "";
  position: fixed;
  top: 0;
  left: 0;

  width: 100%;
  height: 100%;

  background: radial-gradient(circle at 30% 20%, rgba(60, 80, 255, 0.15), transparent 40%),
    radial-gradient(circle at 70% 60%, rgba(0, 200, 255, 0.12), transparent 40%),
    radial-gradient(circle at 50% 90%, rgba(255, 80, 120, 0.1), transparent 40%);

  animation: movebg 18s infinite alternate;
  z-index: -1;
}

@keyframes movebg {
  from {
    transform: translateY(-20px);
  }

  to {
    transform: translateY(20px);
  }
}

/* topbar */

.topbar {
  width: 100%;
  padding: 18px 28px;
  display: flex;
  justify-content: space-between;
  align-items: center;

  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  background: rgba(0, 0, 0, 0.25);
  backdrop-filter: blur(8px);
  position: sticky;
  top: 0;
  z-index: 10;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  color: white;
}

.brand-logo {
  height: 40px;
  filter: drop-shadow(0 0 10px rgba(255, 255, 255, 0.2));
}

.brand-title {
  font-family: "Orbitron", sans-serif;
  letter-spacing: 0.08em;
  font-size: 14px;
  opacity: 0.95;
}

/* nav */

.nav {
  display: flex;
  gap: 18px;
}

.nav-link {
  text-decoration: none;
  color: rgba(255, 255, 255, 0.75);
  font-size: 14px;
  transition: 0.2s;
}

.nav-link:hover {
  color: white;
}

.nav-link.active {
  color: white;
  font-weight: 600;
}

/* container */

.container {
  max-width: 1050px;
  margin: 0 auto;
  padding: 60px 25px;
  animation: fade 1.2s ease;
}

/* hero */

.hero {
  display: flex;
  align-items: flex-start;
  gap: 55px;
  margin-bottom: 70px;
}

.hero-logo {
  max-width: 240px;
  filter: drop-shadow(0 0 30px rgba(255, 255, 255, 0.18));
  animation: logo 1.8s ease;
}

.hero-title {
  font-family: "Orbitron", sans-serif;
  font-size: 34px;
  letter-spacing: 0.1em;
  margin-bottom: 14px;
  color: #e8f0ff;
  text-shadow: 0 0 8px rgba(120, 180, 255, 0.4), 0 0 20px rgba(80, 120, 255, 0.25);
}

.hero-manifesto {
  font-size: 16px;
  line-height: 1.6;
  opacity: 0.9;
  margin-bottom: 18px;
  font-style: italic;
}

.hero-description {
  font-size: 15px;
  line-height: 1.8;
  opacity: 0.88;
  margin-bottom: 25px;
  max-width: 650px;
}

.hero-actions {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
}

/* botones */

.btn {
  display: inline-block;
  padding: 12px 18px;
  border-radius: 10px;
  text-decoration: none;
  font-size: 14px;
  transition: 0.25s;
  border: 1px solid rgba(255, 255, 255, 0.12);
}

.btn.primary {
  background: rgba(0, 255, 120, 0.12);
  color: #eafff3;
  border-color: rgba(0, 255, 120, 0.25);
}

.btn.primary:hover {
  background: rgba(0, 255, 120, 0.18);
  transform: translateY(-2px);
}

.btn.secondary {
  background: rgba(255, 255, 255, 0.04);
  color: rgba(255, 255, 255, 0.85);
}

.btn.secondary:hover {
  background: rgba(255, 255, 255, 0.07);
  transform: translateY(-2px);
}

.btn.violet {
  background: rgba(124, 58, 237, 0.12);
  border-color: rgba(124, 58, 237, 0.3);
  color: rgba(240, 230, 255, 0.95);
}

.btn.violet:hover {
  background: rgba(124, 58, 237, 0.18);
  transform: translateY(-2px);
}

/* cards */

.grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
  margin-bottom: 70px;
}

.card {
  padding: 18px 18px;
  border-radius: 14px;

  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.02);
  backdrop-filter: blur(6px);

  transition: 0.25s;
}

.card:hover {
  border-color: rgba(255, 255, 255, 0.22);
  transform: translateY(-2px);
}

.card h2 {
  font-size: 16px;
  margin-bottom: 10px;
  color: rgba(232, 240, 255, 0.95);
}

.card p {
  font-size: 14px;
  line-height: 1.65;
  opacity: 0.85;
}

/* page head */

.page-head {
  margin-bottom: 40px;
}

.page-title {
  font-family: "Orbitron", sans-serif;
  font-size: 30px;
  letter-spacing: 0.08em;
  margin-bottom: 10px;
  color: #e8f0ff;
  text-shadow: 0 0 8px rgba(120, 180, 255, 0.4), 0 0 20px rgba(80, 120, 255, 0.25);
}

.page-subtitle {
  font-size: 15px;
  opacity: 0.85;
  line-height: 1.7;
  max-width: 750px;
}

/* ecosystem */

.ecosystem {
  margin-bottom: 70px;
}

.section-title {
  font-family: "Orbitron", sans-serif;
  font-size: 18px;
  margin-bottom: 18px;
  opacity: 0.95;
}

.ecosystem-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
}

.node {
  display: block;
  padding: 16px;
  border-radius: 14px;
  text-decoration: none;

  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.02);
  backdrop-filter: blur(6px);

  transition: 0.25s;
  color: white;
}

.node:hover {
  border-color: rgba(255, 255, 255, 0.22);
  transform: translateY(-2px);
}

.node-title {
  font-family: "Orbitron", sans-serif;
  font-size: 14px;
  letter-spacing: 0.08em;
  margin-bottom: 6px;
}

.node-desc {
  font-size: 13px;
  opacity: 0.8;
}

/* callout */

.callout {
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.015);
  padding: 22px;
  border-radius: 16px;
  margin-bottom: 70px;
}

.callout h2 {
  font-size: 16px;
  margin-bottom: 10px;
  color: rgba(232, 240, 255, 0.95);
}

.callout p {
  font-size: 14px;
  line-height: 1.7;
  opacity: 0.85;
}

/* sistema cards */

.system-card {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.system-card .small-note {
  font-size: 12px;
  opacity: 0.7;
}

.system-card.prod {
  border-color: rgba(0, 255, 120, 0.12);
}

.system-card.test {
  border-color: rgba(124, 58, 237, 0.18);
}

/* tree */

.tree {
  margin-bottom: 70px;
}

.tree-root {
  padding: 20px;
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.015);
}

.tree-label {
  font-family: "Orbitron", sans-serif;
  letter-spacing: 0.08em;
  font-size: 14px;
  margin-bottom: 18px;
  opacity: 0.9;
}

.tree-branch {
  margin-left: 16px;
  border-left: 1px solid rgba(255, 255, 255, 0.1);
  padding-left: 14px;
  margin-bottom: 18px;
}

.tree-item {
  margin-bottom: 14px;
}

.tree-item-title {
  font-weight: 600;
  margin-bottom: 4px;
}

.tree-item-desc {
  font-size: 13px;
  opacity: 0.78;
  line-height: 1.6;
}

.tree-link {
  display: block;
  text-decoration: none;
  color: rgba(255, 255, 255, 0.88);
  font-size: 14px;
  padding: 6px 0;
  transition: 0.2s;
}

.tree-link:hover {
  opacity: 0.7;
}

.tree-link.test {
  color: rgba(190, 140, 255, 0.95);
}

.tree-link.muted {
  opacity: 0.5;
}

/* footer */

.footer {
  margin-top: 60px;
  padding: 25px 10px;
  display: flex;
  justify-content: center;
  font-size: 12px;
  opacity: 0.7;
}

.footer-link {
  display: flex;
  align-items: center;
  gap: 10px;
  color: white;
  text-decoration: none;
}

.footer-link:hover {
  opacity: 0.9;
}

.footer-logo {
  height: 40px;
}

/* animaciones */

@keyframes logo {
  from {
    opacity: 0;
    transform: scale(0.92);
  }

  to {
    opacity: 1;
    transform: scale(1);
  }
}

@keyframes fade {
  from {
    opacity: 0;
    transform: translateY(12px);
  }

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


/* ==========================
   MENÚ MÓVIL (sin JS)
   ========================== */

.menu-toggle {
  display: none;
}

.menu-btn {
  display: none;
  flex-direction: column;
  gap: 6px;
  cursor: pointer;
  padding: 8px;
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.02);
  transition: 0.25s;
}

.menu-btn:hover {
  border-color: rgba(255, 255, 255, 0.18);
}

.menu-btn span {
  display: block;
  width: 26px;
  height: 2px;
  background: rgba(255, 255, 255, 0.85);
  border-radius: 2px;
  transition: 0.25s;
}


.menu-btn {
  display: none;
}

/* Panel desplegable */
.mobile-menu {
  display: none;
  position: absolute;
  top: 72px;
  right: 18px;
  width: 260px;
  padding: 14px;
  border-radius: 16px;

  border: 1px solid rgba(255, 255, 255, 0.10);
  background: rgba(0, 0, 0, 0.75);
  backdrop-filter: blur(10px);

  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.4);
}

.mobile-link {
  display: block;
  padding: 10px 12px;
  border-radius: 12px;
  text-decoration: none;
  font-size: 14px;
  color: rgba(255, 255, 255, 0.85);
  transition: 0.2s;
}

.mobile-link:hover {
  background: rgba(255, 255, 255, 0.06);
  color: white;
}

.mobile-divider {
  margin: 10px 0;
  height: 1px;
  background: rgba(255, 255, 255, 0.08);
}

/* Activación cuando el checkbox está marcado */
.menu-toggle:checked ~ .mobile-menu {
  display: block;
  animation: fadeMenu 0.25s ease;
}

/* Animación del panel */
@keyframes fadeMenu {
  from {
    opacity: 0;
    transform: translateY(-8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Animación hamburguesa -> X */
.menu-toggle:checked ~ .menu-btn span:nth-child(1) {
  transform: rotate(45deg) translate(6px, 6px);
}

.menu-toggle:checked ~ .menu-btn span:nth-child(2) {
  opacity: 0;
}

.menu-toggle:checked ~ .menu-btn span:nth-child(3) {
  transform: rotate(-45deg) translate(6px, -6px);
}

/* Responsive: ocultar nav desktop y mostrar botón */
@media (max-width: 900px) {
  .hero {
    flex-direction: column;
    align-items: center;
    text-align: center;
  }

  .hero-description {
    margin-left: auto;
    margin-right: auto;
  }

  .hero-actions {
    justify-content: center;
  }

  .grid {
    grid-template-columns: 1fr;
  }

  .ecosystem-grid {
    grid-template-columns: 1fr;
  }

  /* Oculta nav desktop */
  .nav {
    display: none;
  }

  /* Muestra botón hamburguesa */
  .menu-btn {
    display: flex;
  }

  /* Necesario para que el panel se ubique relativo al header */
  .topbar {
    position: relative;
  }
}
