:root {
  --bg-color: #051933;
  --bg-alt: #0a2545;
  --bg-soft: #0f2b4f;
  --border-soft: #153a60;
  --txt-main: #e6f1ff;
  --txt-soft: #9db2ce;
  --accent: #00a8ff;
  --accent-alt: #02d5ff;
  --danger: #ff4f6a;
  --radius-lg: 18px;
  --radius-sm: 10px;
  --shadow-soft: 0 18px 40px rgba(0, 0, 0, 0.45);
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
}

body {
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Inter", "Poppins", sans-serif;
  background: radial-gradient(circle at top, #0b2b55 0, #020817 45%, #020817 100%);
  color: var(--txt-main);
  line-height: 1.5;
}

/* Layout base */

.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

.section {
  padding: 4rem 0;
}

.section-heading {
  text-align: center;
  margin-bottom: 2.5rem;
}

.section-heading h2 {
  font-size: 2rem;
  margin: 0 0 0.5rem;
}

.section-heading p {
  margin: 0;
  color: var(--txt-soft);
}

/* Header / Nav */

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  backdrop-filter: blur(16px);
  background: linear-gradient(to bottom, rgba(2, 8, 23, 0.94), rgba(2, 8, 23, 0.8));
  border-bottom: 1px solid rgba(0, 168, 255, 0.1);
}

.navbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.9rem 0;
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.6rem;
}

/* Logo m��s grande en escritorio */
.brand-logo {
  height: 80px;
  width: auto;
  display: block;
}

.brand-text {
  display: flex;
  flex-direction: column;
}

/* AITECHVZLA m��s grande y en blanco */
.brand-text span:first-child {
  font-weight: 700;
  letter-spacing: 0.08em;
  font-size: 1.05rem;
  text-transform: uppercase;
  color: #ffffff;
}

.brand-text span:last-child {
  font-size: 0.7rem;
  color: var(--txt-soft);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 1.5rem;
}

.nav-links a {
  color: var(--txt-soft);
  text-decoration: none;
  font-size: 0.9rem;
  position: relative;
}

.nav-links a:hover {
  color: var(--accent-alt);
}

.nav-links a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -0.4rem;
  width: 0;
  height: 2px;
  background: linear-gradient(90deg, var(--accent), var(--accent-alt));
  transition: width 0.2s ease-out;
}

.nav-links a:hover::after {
  width: 100%;
}

.nav-cta {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.btn {
  border-radius: 999px;
  padding: 0.5rem 1.2rem;
  border: 1px solid transparent;
  font-size: 0.85rem;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  text-decoration: none;
}

.btn-primary {
  background: linear-gradient(135deg, var(--accent), var(--accent-alt));
  color: #020817;
  font-weight: 600;
  box-shadow: 0 8px 22px rgba(0, 168, 255, 0.5);
}

.btn-primary:hover {
  filter: brightness(1.1);
}

.btn-outline {
  background: transparent;
  color: var(--txt-soft);
  border-color: rgba(0, 168, 255, 0.4);
}

.btn-outline:hover {
  border-color: var(--accent-alt);
  color: var(--accent-alt);
}

/* Mobile nav */

.nav-toggle {
  display: none;
  cursor: pointer;
}

.nav-toggle span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--txt-main);
  margin: 4px 0;
}

/* Hero */

.hero {
  padding: 3.5rem 0 3rem;
}

.hero-inner {
  display: grid;
  grid-template-columns: 1.4fr 1.1fr;
  gap: 3rem;
  align-items: center;
}

.hero-title {
  font-size: 2.4rem;
  line-height: 1.15;
  margin: 0 0 1rem;
}

.hero-title span.highlight {
  background: linear-gradient(135deg, #00f0ff, #00a8ff, #6a5cff);
  -webkit-background-clip: text;
  color: transparent;
}

.hero-subtitle {
  color: var(--txt-soft);
  font-size: 0.98rem;
  max-width: 520px;
  margin-bottom: 0;
}

/* Panel lateral reutilizado (�9�5 AITECH...) */

.about-panel {
  background: var(--bg-alt);
  border-radius: var(--radius-lg);
  padding: 1.2rem 1.3rem;
  border: 1px solid rgba(0, 168, 255, 0.18);
  font-size: 0.88rem;
  color: var(--txt-soft);
}

/* Bloque de texto / about */

.about-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 2rem;
}

.about-text p {
  margin-top: 0;
  margin-bottom: 0.7rem;
  color: var(--txt-soft);
  font-size: 0.9rem;
}

.about-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 0.8rem;
}

.badge {
  font-size: 0.72rem;
  padding: 0.2rem 0.7rem;
  border-radius: 999px;
  border: 1px solid rgba(0, 168, 255, 0.4);
  color: var(--txt-soft);
}

/* Cards gen��ricas (otras p��ginas) */

.cards-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1.3rem;
}

.card {
  background: var(--bg-alt);
  border-radius: var(--radius-lg);
  padding: 1.3rem 1.3rem 1.4rem;
  border: 1px solid rgba(0, 168, 255, 0.16);
  box-shadow: 0 14px 32px rgba(0, 0, 0, 0.45);
}

.card h3 {
  margin: 0 0 0.4rem;
  font-size: 1rem;
}

.card p {
  margin: 0;
  color: var(--txt-soft);
  font-size: 0.85rem;
}

.card-tag {
  display: inline-block;
  font-size: 0.65rem;
  padding: 0.2rem 0.6rem;
  border-radius: 999px;
  background: rgba(0, 168, 255, 0.12);
  color: var(--accent-alt);
  margin-bottom: 0.6rem;
}

/* Productos (otras p��ginas) */

.products-layout {
  display: grid;
  grid-template-columns: 1.25fr 1fr;
  gap: 1.6rem;
  align-items: flex-start;
}

.products-main {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1.2rem;
}

.product-card {
  background: var(--bg-alt);
  border-radius: var(--radius-lg);
  padding: 1.1rem 1.2rem;
  border: 1px solid rgba(0, 168, 255, 0.18);
}

.product-label {
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--accent-alt);
  margin-bottom: 0.25rem;
}

.product-name {
  font-size: 1rem;
  font-weight: 600;
  margin-bottom: 0.2rem;
}

.product-slogan {
  font-size: 0.8rem;
  color: var(--txt-soft);
  margin-bottom: 0.6rem;
}

.product-pill {
  font-size: 0.72rem;
  background: rgba(0, 168, 255, 0.12);
  padding: 0.24rem 0.6rem;
  border-radius: 999px;
  display: inline-block;
}

.products-side {
  background: var(--bg-alt);
  border-radius: var(--radius-lg);
  padding: 1.2rem 1.2rem 1.4rem;
  border: 1px solid rgba(0, 168, 255, 0.18);
}

.products-side h3 {
  margin-top: 0;
  margin-bottom: 0.5rem;
}

/* Contacto (otras p��ginas) */

.contact-wrapper {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 1.8rem;
}

.contact-info p {
  margin-top: 0;
  margin-bottom: 0.7rem;
  color: var(--txt-soft);
  font-size: 0.9rem;
}

.contact-channels {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  margin: 0.8rem 0 1.3rem;
}

.contact-channels a {
  font-size: 0.8rem;
  text-decoration: none;
  color: var(--accent-alt);
  padding: 0.3rem 0.7rem;
  border-radius: 999px;
  border: 1px solid rgba(0, 168, 255, 0.32);
}

.contact-form {
  background: var(--bg-alt);
  border-radius: var(--radius-lg);
  padding: 1.2rem 1.3rem 1.4rem;
  border: 1px solid rgba(0, 168, 255, 0.18);
}

.contact-form label {
  display: block;
  font-size: 0.8rem;
  margin-bottom: 0.2rem;
}

.contact-form input,
.contact-form textarea {
  width: 100%;
  background: var(--bg-soft);
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-soft);
  padding: 0.5rem 0.6rem;
  color: var(--txt-main);
  font-family: inherit;
  font-size: 0.85rem;
  margin-bottom: 0.8rem;
}

.contact-form input:focus,
.contact-form textarea:focus {
  outline: 1px solid var(--accent);
  border-color: var(--accent);
}

.contact-form textarea {
  resize: vertical;
  min-height: 100px;
}

/* Footer */

.site-footer {
  border-top: 1px solid rgba(0, 168, 255, 0.16);
  padding: 1.8rem 0 1.4rem;
  background: radial-gradient(circle at top, rgba(0, 168, 255, 0.08), rgba(2, 8, 23, 0.96));
  margin-top: 2rem;
}

.footer-inner {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.8rem;
  color: var(--txt-soft);
  text-align: center;
}

.footer-inner strong {
  color: var(--accent-alt);
}

/* Ocultamos los enlaces del footer */
.footer-links {
  display: none;
}

/* Chat de soporte IA (NEXA) */

.chat-ia {
  position: fixed;
  right: 1.2rem;
  bottom: 1.2rem;
  width: 320px;
  max-height: 70vh;
  background: radial-gradient(circle at top left, #0f274a 0, #061124 55%, #040815 100%);
  border-radius: 22px;
  border: 1px solid rgba(0, 168, 255, 0.25);
  box-shadow: 0 22px 45px rgba(0, 0, 0, 0.75);
  display: none;
  flex-direction: column;
  overflow: hidden;
  z-index: 60;
}

/* "Globo" con peque�0�9a colita */
.chat-ia::after {
  content: "";
  position: absolute;
  bottom: -10px;
  right: 40px;
  border-width: 10px 10px 0 10px;
  border-style: solid;
  border-color: #061124 transparent transparent transparent;
}

.chat-ia.open {
  display: flex;
}

.chat-ia-header {
  padding: 0.6rem 0.9rem;
  background: linear-gradient(135deg, rgba(0, 168, 255, 0.35), rgba(2, 213, 255, 0.12));
  border-bottom: 1px solid rgba(0, 168, 255, 0.35);
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.8rem;
}

.chat-ia-title {
  display: flex;
  align-items: center;
  gap: 0.6rem;
}

/* AVATAR DE NEXA EN EL CHAT (IGUAL ESTILO QUE EL BOT�0�7N) */
.chat-ia-avatar {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: #ffffff; /* c��rculo blanco */
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 0 0 2px rgba(0, 168, 255, 0.6);
}

/* Logo de NEXA dentro del c��rculo blanco */
.chat-ia-avatar img {
  width: 70%;
  height: 70%;
  border-radius: 50%;
  object-fit: contain;
  display: block;
}

.chat-ia-name {
  font-weight: 600;
  letter-spacing: 0.04em;
  font-size: 0.75rem;
  text-transform: uppercase;
}

.chat-ia-status {
  font-size: 0.7rem;
  color: var(--txt-soft);
}

.chat-ia-header button {
  background: transparent;
  border: none;
  color: var(--txt-soft);
  font-size: 1.1rem;
  cursor: pointer;
}

.chat-ia-header button:hover {
  color: var(--accent-alt);
}

.chat-ia-messages {
  padding: 0.7rem 0.8rem;
  overflow-y: auto;
  flex: 1;
  font-size: 0.8rem;
}

/* Estilo de mensajes tipo burbuja */

.msg {
  padding: 0.45rem 0.7rem;
  border-radius: 14px;
  margin-bottom: 0.45rem;
  max-width: 90%;
}

.msg-bot {
  background: rgba(7, 33, 66, 0.95);
  color: var(--txt-soft);
  border: 1px solid rgba(0, 168, 255, 0.18);
}

.msg-user {
  background: linear-gradient(135deg, var(--accent), var(--accent-alt));
  color: #020817;
  margin-left: auto;
  border-bottom-right-radius: 4px;
}

/* Input del chat */

.chat-ia-input {
  display: flex;
  border-top: 1px solid rgba(0, 168, 255, 0.25);
  background: rgba(3, 15, 35, 0.9);
}

.chat-ia-input input {
  flex: 1;
  border: none;
  background: transparent;
  color: var(--txt-main);
  padding: 0.55rem 0.7rem;
  font-size: 0.8rem;
}

.chat-ia-input input::placeholder {
  color: rgba(157, 178, 206, 0.7);
}

.chat-ia-input input:focus {
  outline: none;
}

.chat-ia-input button {
  border: none;
  padding: 0 0.9rem;
  font-size: 0.8rem;
  background: linear-gradient(135deg, var(--accent), var(--accent-alt));
  color: #020817;
  cursor: pointer;
  font-weight: 600;
  border-radius: 0;
}

.chat-ia-input button:hover {
  filter: brightness(1.08);
}

/* Bot��n flotante NEXA (solo c��rculo blanco con logo) */

.nexa-fab {
  position: fixed;
  right: 1.1rem;
  bottom: 1.1rem;
  width: 60px;
  height: 60px;
  border-radius: 50%;
  border: none;
  background: #ffffff;
  box-shadow: 0 14px 30px rgba(0, 0, 0, 0.65);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 55;
}

/* Logo de NEXA dentro del c��rculo blanco */
.nexa-fab img {
  width: 70%;
  height: 70%;
  object-fit: contain;
  display: block;
}

.nexa-fab.hidden-fab {
  display: none;
}

/* Tooltip premium de NEXA (burbuja) */
.nexa-fab::after {
  content: "Hola, soy NEXA. Necesitas soporte técnico?";
  position: absolute;
  bottom: 72px; /* burbuja sobre el bot��n */
  right: 0;
  transform: translateY(8px);
  background: #ffffff;
  color: #020817;
  font-size: 0.72rem;
  padding: 6px 10px;
  border-radius: 8px;
  white-space: nowrap;
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.65);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.18s ease-out, transform 0.18s ease-out;
}

/* Flechita del globo */
.nexa-fab::before {
  content: "";
  position: absolute;
  bottom: 62px;
  right: 18px;
  border-width: 7px 7px 0 7px;
  border-style: solid;
  border-color: #ffffff transparent transparent transparent;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.18s ease-out;
}

/* Mostrar tooltip con hover, focus o clase especial (m��vil) */
.nexa-fab:hover::after,
.nexa-fab:hover::before,
.nexa-fab:focus-visible::after,
.nexa-fab:focus-visible::before,
.nexa-fab.show-tooltip::after,
.nexa-fab.show-tooltip::before {
  opacity: 1;
  transform: translateY(0);
}

/* Responsivo general */

@media (max-width: 960px) {
  .hero-inner,
  .products-layout,
  .about-grid,
  .contact-wrapper {
    grid-template-columns: 1fr;
  }

  .cards-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .products-main {
    grid-template-columns: 1fr;
  }
}

/* Versi��n m��vil (Android / iOS) */

@media (max-width: 768px) {
  .navbar {
    padding: 0.7rem 0;
  }

  .nav-links {
    position: fixed;
    inset: 56px 0 auto 0;
    background: rgba(2, 8, 23, 0.98);
    flex-direction: column;
    padding: 1rem 1.5rem 1.5rem;
    border-bottom: 1px solid rgba(0, 168, 255, 0.2);
    transform: translateY(-120%);
    transition: transform 0.2s ease-out;
  }

  .nav-links.open {
    transform: translateY(0);
  }

  .nav-cta {
    display: none;
  }

  .nav-toggle {
    display: block;
  }

  /* Logo m��s grande en m��vil */
  .brand-logo {
    height: 80px;
  }

  /* Hero m��s compacto y centrado en m��vil */
  .hero {
    padding: 2.5rem 0 2.2rem;
  }

  .hero-inner {
    grid-template-columns: 1fr;
    gap: 1.8rem;
  }

  .hero-title {
    font-size: 1.9rem;
    text-align: center;
  }

  .hero-subtitle {
    text-align: center;
    margin: 0 auto;
  }

  .about-panel {
    margin: 0 auto;
    max-width: 420px;
  }

  .section {
    padding: 2.6rem 0;
  }

  /* Chat IA adaptado a m��vil */
  .chat-ia {
    right: 0.6rem;
    left: 0.6rem;
    width: auto;
    bottom: 0.7rem;
  }

  .chat-ia::after {
    right: 36px;
  }

  /* Posici��n y tama�0�9o de la burbuja NEXA en m��vil */
  .nexa-fab {
    right: 0.8rem;
    bottom: 0.9rem;
    width: 56px;
    height: 56px;
  }
}
