@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@300;400;600;700;900&family=Orbitron:wght@700;900&display=swap');

:root {
  --red: #e31b1b;
  --red-glow: rgba(227,27,27,0.18);
  --red-dim: #c01515;
  --red-light: #fdf2f2;
  --red-pale: #fff5f5;

  --black: #111111;
  --dark: #1a1a1a;
  --darker: #0f0f0f;

  /* Light mode palette */
  --bg-primary: #ffffff;
  --bg-secondary: #f8f7f5;
  --bg-tertiary: #f2f1ee;
  --bg-card: #ffffff;

  --text-primary: #111111;
  --text-secondary: #444444;
  --text-muted: #888888;

  --border-subtle: rgba(0,0,0,0.06);
  --border-medium: rgba(0,0,0,0.12);
  --border-strong: rgba(0,0,0,0.18);

  --shadow-sm: 0 1px 4px rgba(0,0,0,0.06), 0 1px 2px rgba(0,0,0,0.04);
  --shadow-md: 0 4px 16px rgba(0,0,0,0.08), 0 1px 4px rgba(0,0,0,0.04);
  --shadow-lg: 0 8px 32px rgba(0,0,0,0.10), 0 2px 8px rgba(0,0,0,0.06);
  --shadow-red: 0 8px 32px rgba(227,27,27,0.14), 0 2px 8px rgba(227,27,27,0.06);
  --shadow-card: 0 2px 20px rgba(0,0,0,0.07), 0 1px 6px rgba(0,0,0,0.04);

  --white: #ffffff;
  --white-dim: #f0eeeb;
  --gray: #f4f3f0;
  --gray-mid: #e8e6e2;
  --gray-light: #888888;

  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 20px;
  --radius-xl: 28px;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: 'Poppins', sans-serif;
  background: var(--bg-primary);
  color: var(--text-primary);
  overflow-x: hidden;
}

::-webkit-scrollbar { width: 4px; }
::-webkit-scrollbar-track { background: var(--bg-secondary); }
::-webkit-scrollbar-thumb { background: var(--red); border-radius: 2px; }

/* ─── HEADER ─── */
/* ─── HEADER ─── */
header {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 48px;
  height: 80px;
  background: rgba(255,255,255,0.96);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border-subtle);
  transition: box-shadow .3s, background .3s;
}

/* Línea animada roja debajo del header al hacer scroll */
header::after {
  content: '';
  position: absolute;
  bottom: 0; left: 0;
  width: 0%;
  height: 2px;
  background: linear-gradient(90deg, var(--red) 0%, #ff6b6b 50%, var(--red) 100%);
  background-size: 200% 100%;
  border-radius: 0 2px 2px 0;
  transition: width 0.6s cubic-bezier(0.22, 1, 0.36, 1);
  box-shadow: 0 0 10px rgba(227,27,27,0.4);
  animation: shimmer 2s linear infinite;
    z-index: 0;

}
header.scrolled::after { width: 100%; }
header.scrolled { box-shadow: 0 2px 28px rgba(0,0,0,0.07); }

@keyframes shimmer {
  0%   { background-position: 200% center; }
  100% { background-position: -200% center; }
}

/* ─── LOGO ─── */
.logo {
  font-family: 'Orbitron', sans-serif;
  font-size: 1.55rem;
  font-weight: 900;
  color: var(--text-primary);
  letter-spacing: 2px;
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 10px;
}
.logo span { color: var(--red); }
.logo .tech { color: var(--red); }
.logo .home { color: var(--black); }

/* ─── NAV ─── */
nav { display: flex; align-items: center; gap: 6px; }
nav a {
  display: flex; align-items: center; gap: 7px;
  padding: 8px 16px;
  color: var(--text-secondary);
  text-decoration: none;
  font-size: .92rem;
  font-weight: 600;
  letter-spacing: .8px;
  text-transform: uppercase;
  border-radius: 6px;
  transition: color .25s, background .25s;
  position: relative;
}
nav a svg { transition: color .25s; }
nav a::after {
  content: '';
  position: absolute;
  bottom: 4px; left: 50%; right: 50%;
  height: 2px;
  background: var(--red);
  transition: left .3s cubic-bezier(0.22, 1, 0.36, 1), right .3s cubic-bezier(0.22, 1, 0.36, 1);
  border-radius: 1px;
  box-shadow: 0 0 6px rgba(227,27,27,0.35);
}
nav a:hover { color: var(--black); }
nav a:hover::after { left: 16px; right: 16px; }
nav a:hover svg { color: var(--red); }

/* ─── HAMBURGER ─── */
.hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  padding: 8px;
  border: 1px solid var(--border-medium);
  border-radius: 6px;
  background: transparent;
  transition: border-color .25s, background .25s;
}
.hamburger:hover { border-color: var(--red); background: var(--red-light); }
.hamburger span {
  display: block;
  width: 22px; height: 2px;
  background: var(--text-primary);
  border-radius: 1px;
  transition: transform .35s, opacity .35s;
}
.hamburger.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); background: var(--red); }
.hamburger.open span:nth-child(2) { opacity: 0; }
.hamburger.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); background: var(--red); }

/* ─── MOBILE NAV ─── */
.mobile-nav {
  display: none;
  position: fixed;
  top: 80px;
  left: 0; right: 0;
  z-index: 999;
  background: rgba(255,255,255,0.98);
  backdrop-filter: blur(18px);
  border-bottom: 1px solid var(--border-subtle);
  flex-direction: column;
  align-items: stretch;
  gap: 0;
  opacity: 0;
  transform: translateY(-8px);
  transition: opacity .3s, transform .3s;
  pointer-events: none;
  box-shadow: 0 8px 32px rgba(0,0,0,0.10);
}
.mobile-nav.open { opacity: 1; transform: translateY(0); pointer-events: all; }
.mobile-nav a {
  display: flex; align-items: center; gap: 12px;
  padding: 15px 28px;
  color: var(--text-secondary);
  text-decoration: none;
  font-size: .88rem;
  font-weight: 600;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  border-bottom: 1px solid var(--border-subtle);
  transition: color .2s, background .2s, padding-left .2s;
}
.mobile-nav a:last-child { border-bottom: none; }
.mobile-nav a:hover {
  color: var(--black);
  background: var(--red-light);
  padding-left: 36px;
}
.mobile-nav a svg { color: var(--red); flex-shrink: 0; }

/* ─── SECTION DIVIDERS ─── */
section + section {
  border-top: 1px solid var(--border-subtle);
}

/* ─── HERO ─── */
#inicio {
  min-height: 100vh;
  padding-top: 80px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: center;
  padding-left: 80px;
  padding-right: 60px;
  gap: 40px;
  position: relative;
  overflow: hidden;
  background: var(--bg-primary);
}

.hero-bg {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 55% 55% at 72% 50%, rgba(227,27,27,0.06) 0%, transparent 70%),
    radial-gradient(ellipse 30% 40% at 15% 80%, rgba(227,27,27,0.03) 0%, transparent 70%),
    repeating-linear-gradient(0deg, transparent, transparent 39px, rgba(0,0,0,0.02) 39px, rgba(0,0,0,0.02) 40px),
    repeating-linear-gradient(90deg, transparent, transparent 39px, rgba(0,0,0,0.02) 39px, rgba(0,0,0,0.02) 40px);
}





.hero-left {
  position: relative; z-index: 2;
  padding-left: 28px;
  animation: fadeSlideLeft .9s ease both;
}

/* Barra vertical roja a la izquierda del contenido hero */
.hero-left::before {
  content: '';
  position: absolute;
  left: 0; top: 10%; bottom: 10%;
  width: 3px;
  background: linear-gradient(180deg, transparent 0%, var(--red) 30%, var(--red) 70%, transparent 100%);
  border-radius: 2px;
  box-shadow: 0 0 12px rgba(227,27,27,0.3);
}

.hero-tag {
  display: inline-flex; align-items: center; gap: 8px;
  background: var(--red-light);
  border: 1px solid rgba(227,27,27,0.22);
  color: var(--red);
  font-size: .72rem;
  font-weight: 700;
  letter-spacing: 2.5px;
  text-transform: uppercase;
  padding: 6px 14px;
  border-radius: 4px;
  margin-bottom: 20px;
  box-shadow: 0 2px 12px rgba(227,27,27,0.10);
}
.hero-tag::before {
  content: '';
  width: 6px; height: 6px;
  background: var(--red);
  border-radius: 50%;
  box-shadow: 0 0 8px var(--red);
  animation: blink 1.4s infinite;
}

.hero-title {
  font-family: 'Orbitron', sans-serif;
  font-size: clamp(3rem, 6vw, 5.5rem);
  font-weight: 900;
  line-height: 1;
  letter-spacing: -1px;
  margin-bottom: 24px;
  color: var(--text-primary);
}
.hero-title .red { color: var(--red); }

/* Línea decorativa roja bajo el título */
.hero-title-line {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 24px;
  margin-top: -10px;
}
.hero-title-line::before {
  content: '';
  display: block;
  width: 48px;
  height: 3px;
  background: var(--red);
  border-radius: 2px;
  box-shadow: 0 0 8px rgba(227,27,27,0.4);
}

@media (max-width: 900px) {

  .hero-title-line {
    justify-content: center;
    gap: 0;
  }

  .hero-title-line::before {
    width: 170px;
    margin: 0 auto;
  }

  .hero-title-line::after {
    content: none !important;
    display: none !important;
  }

}

.hero-title-line::after {
  content: '';
  display: block;
  flex: 1;
  max-width: 140px;
  height: 1px;
  background: var(--border-medium);
  border-radius: 1px;
}

.hero-desc {
  font-size: .97rem;
  line-height: 1.8;
  color: var(--text-secondary);
  max-width: 460px;
  margin-bottom: 36px;
}
.hero-desc strong { color: var(--black); }

.btn-group { display: flex; gap: 14px; flex-wrap: wrap; }

.btn-primary {
  display: inline-flex; align-items: center; gap: 9px;
  background: var(--red);
  color: #fff;
  padding: 14px 30px;
  border-radius: 8px;
  font-weight: 700;
  font-size: .85rem;
  letter-spacing: 1px;
  text-transform: uppercase;
  text-decoration: none;
  border: none; cursor: pointer;
  transition: box-shadow .3s, transform .2s, background .25s;
  box-shadow: 0 4px 14px rgba(227,27,27,0.22);
}
.btn-primary:hover {
  background: var(--red-dim);
  box-shadow: 0 6px 24px rgba(227,27,27,0.35);
  transform: translateY(-2px);
}

.btn-large {
  padding: 16px 40px;
  font-size: .95rem;
  letter-spacing: 1.5px;
}

.btn-outline {
  display: inline-flex; align-items: center; gap: 9px;
  background: transparent;
  color: var(--text-primary);
  padding: 14px 30px;
  border-radius: 8px;
  font-weight: 700;
  font-size: .85rem;
  letter-spacing: 1px;
  text-transform: uppercase;
  text-decoration: none;
  border: 1.5px solid var(--border-strong);
  cursor: pointer;
  transition: border-color .25s, box-shadow .3s, transform .2s, background .25s;
}
.btn-outline:hover {
  border-color: var(--red);
  color: var(--red);
  background: var(--red-light);
  transform: translateY(-2px);
  box-shadow: 0 4px 14px rgba(227,27,27,0.12);
}

.hero-right {
  position: relative; z-index: 2;
  display: flex; align-items: center; justify-content: center;
  animation: fadeSlideRight .9s .2s ease both;
}

.robot-stage {
  position: relative;
  width: 520px;
  height: 440px;
  display: flex;
  align-items: center;
  justify-content: center;
}

#robotCanvas {
  width: 520px !important;
  height: 440px !important;
  display: block;
  background: transparent;
  cursor: default;
}

#robotLoader {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  pointer-events: none;
}
#robotLoader .loader-ring {
  width: 48px; height: 48px;
  border: 3px solid rgba(227,27,27,0.12);
  border-top-color: var(--red);
  border-radius: 50%;
  animation: spin 1s linear infinite;
}
#robotLoader span {
  font-size: .68rem;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: rgba(227,27,27,0.55);
}

/* ─── SECTION BRAND STRIP ─── */
.brand-strip {
  background: var(--bg-secondary);
  border-top: 1px solid var(--border-subtle);
  border-bottom: 1px solid var(--border-subtle);
  padding: 18px 80px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 60px;
  overflow: hidden;
  position: relative;
}
.brand-strip::before,
.brand-strip::after {
  content: '';
  position: absolute;
  top: 0; bottom: 0;
  width: 80px;
  z-index: 2;
  pointer-events: none;
}
.brand-strip::before { left: 0; background: linear-gradient(90deg, var(--bg-secondary), transparent); }
.brand-strip::after  { right: 0; background: linear-gradient(-90deg, var(--bg-secondary), transparent); }

.brand-strip-inner {
  display: flex;
  align-items: center;
  gap: 64px;
  animation: marquee 18s linear infinite;
  white-space: nowrap;
}
.brand-strip-item {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: 'Orbitron', sans-serif;
  font-size: .85rem;
  font-weight: 700;
  letter-spacing: 2px;
  color: var(--text-muted);
  opacity: 0.55;
}
.brand-strip-item .dot {
  width: 5px; height: 5px;
  background: var(--red);
  border-radius: 50%;
}
.brand-strip-item .tech { color: var(--red); opacity: 1; }
.brand-strip-item .home { color: var(--black); opacity: 1; }

@keyframes marquee {
  from { transform: translateX(0); }
  to   { transform: translateX(-50%); }
}

/* ─── SECTION LAYOUT ─── */
section { padding: 100px 80px; }

.section-label {
  display: inline-flex; align-items: center; gap: 10px;
  font-size: 1.2rem;
  font-weight: 700;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: var(--red);
  margin-bottom: 12px;
}
.section-label::before {
  content: '';
  width: 28px; height: 2px;
  background: var(--red);
  box-shadow: 0 0 6px rgba(227,27,27,0.3);
}

.section-title {
  font-family: 'Orbitron', sans-serif;
  font-size: clamp(1.6rem, 3vw, 2.8rem);
  font-weight: 900;
  margin-bottom: 14px;
  color: var(--text-primary);
}
.section-title .red { color: var(--red); }

.section-sub {
  font-size: 1.0rem;
  color: var(--text-secondary);
  max-width: 520px;
  line-height: 1.7;
  margin-bottom: 60px;
}

/* ─── SECTION HEADER WITH BRAND ─── */
.section-header-wrap {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: 60px;
  flex-wrap: wrap;
  gap: 20px;
}
.section-header-wrap .section-sub { margin-bottom: 0; }
.section-brand-tag {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-family: 'Orbitron', sans-serif;
  font-size: .75rem;
  font-weight: 900;
  letter-spacing: 2px;
  padding: 8px 16px;
  border-radius: 6px;
  border: 1.5px solid var(--border-medium);
  background: var(--bg-card);
  box-shadow: var(--shadow-sm);
  white-space: nowrap;
  align-self: flex-start;
  margin-top: 4px;
}
.section-brand-tag .tech { color: var(--red); }
.section-brand-tag .home { color: var(--black); }

/* ─── HABILIDADES ─── */
#habilidades {
  background: var(--bg-secondary);
  position: relative;
  overflow: hidden;
}
#habilidades::before {
  content: '';
  position: absolute;
  top: 0; right: 0;
  width: 500px; height: 500px;
  background: radial-gradient(ellipse, rgba(227,27,27,0.04) 0%, transparent 70%);
  pointer-events: none;
}

.features-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.feature-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 32px 28px;
  position: relative;
  overflow: hidden;
  transition: transform .3s, border-color .3s, box-shadow .3s;
  cursor: default;
  animation: fadeUp .6s ease both;
  box-shadow: var(--shadow-card);
}
.feature-card:nth-child(1) { animation-delay: .1s; }
.feature-card:nth-child(2) { animation-delay: .2s; }
.feature-card:nth-child(3) { animation-delay: .3s; }
.feature-card::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(227,27,27,0.04) 0%, transparent 60%);
  opacity: 0;
  transition: opacity .3s;
}
/* Top accent line on hover */
.feature-card::after {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--red), #ff6b6b);
  border-radius: var(--radius-md) var(--radius-md) 0 0;
  transform: scaleX(0);
  transform-origin: left;
  transition: transform .35s cubic-bezier(0.22, 1, 0.36, 1);
}
.feature-card:hover {
  transform: translateY(-6px);
  border-color: rgba(227,27,27,0.2);
  box-shadow: var(--shadow-red);
}
.feature-card:hover::before { opacity: 1; }
.feature-card:hover::after  { transform: scaleX(1); }
.feature-header {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 14px;
}
.feature-header h3 { margin-bottom: 0; }

.feature-icon {
  width: 44px; height: 44px;
  flex-shrink: 0;
  background: var(--red-light);
  border: 1px solid rgba(227,27,27,0.18);
  border-radius: 10px;
  display: flex; align-items: center; justify-content: center;
  color: var(--red);
  transition: background .3s, box-shadow .3s, transform .3s;
}
.feature-card:hover .feature-icon {
  background: rgba(227,27,27,0.12);
  box-shadow: 0 0 16px rgba(227,27,27,0.15);
  transform: scale(1.08);
}
.feature-card h3 { font-size: 1rem; font-weight: 700; margin-bottom: 10px; letter-spacing: .3px; color: var(--text-primary); }
.feature-card p  { font-size: .83rem; color: var(--black); line-height: 1.7; }

/* ─── ROBOTS SECTION ─── */
#robots {
  background: var(--bg-primary);
  position: relative;
  overflow: hidden;
}
#robots::before {
  content: '';
  position: absolute;
  bottom: 0; left: 0;
  width: 600px; height: 400px;
  background: radial-gradient(ellipse, rgba(227,27,27,0.04) 0%, transparent 70%);
  pointer-events: none;
}

/* TECH HOME inline banner above robots grid */
.robots-brand-banner {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 36px;
  padding: 14px 22px;
  background: var(--bg-secondary);
  border: 1px solid var(--border-subtle);
  border-left: 3px solid var(--red);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  width: fit-content;
}
.robots-brand-banner .brand-text {
  font-family: 'Orbitron', sans-serif;
  font-size: .8rem;
  font-weight: 900;
  letter-spacing: 2.5px;
}
.robots-brand-banner .brand-text .tech { color: var(--red); }
.robots-brand-banner .brand-text .home { color: var(--black); }
.robots-brand-banner span {
  font-size: .72rem;
  font-weight: 600;
  color: var(--text-muted);
  letter-spacing: .5px;
}

.robots-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 36px;
}

.robot-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: transform .35s, border-color .35s, box-shadow .35s;
  animation: fadeUp .7s ease both;
  box-shadow: var(--shadow-card);
}
.robot-card:nth-child(1) { animation-delay: .1s; }
.robot-card:nth-child(2) { animation-delay: .25s; }
.robot-card:hover {
  transform: translateY(-8px);
  border-color: rgba(227,27,27,0.28);
  box-shadow: var(--shadow-red);
}

.robot-img-wrap {
  height: 280px;
  background: linear-gradient(145deg, #fafafa 0%, var(--bg-secondary) 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
}
.robot-img-wrap::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 50%, var(--bg-card) 100%);
  pointer-events: none;
}

.robot-card-glow {
  position: absolute;
  width: 240px; height: 240px;
  border-radius: 50%;
  background: radial-gradient(ellipse, rgba(227,27,27,0.07) 0%, transparent 70%);
  pointer-events: none;
  z-index: 0;
}

.robot-img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: center;
  position: relative;
  z-index: 1;
  padding: 20px;
  animation: float 5s ease-in-out infinite;
  filter: drop-shadow(0 8px 24px rgba(0,0,0,0.12));
  transition: filter .3s;
}
.robot-card:nth-child(2) .robot-img { animation-delay: 1.2s; }
.robot-card:hover .robot-img {
  filter: drop-shadow(0 12px 32px rgba(227,27,27,0.2));
}

.robot-info {
  padding: 28px 30px 32px;
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.robot-badge {
  display: inline-flex;
  align-items: center;
  background: var(--red-light);
  border: 1px solid rgba(227,27,27,0.2);
  color: var(--red);
  font-size: .68rem;
  font-weight: 700;
  letter-spacing: 2px;
  text-transform: uppercase;
  padding: 4px 12px;
  border-radius: 20px;
  width: fit-content;
}

.robot-name {
  font-family: 'Orbitron', sans-serif;
  font-size: 1.5rem;
  font-weight: 900;
  letter-spacing: .3px;
  line-height: 1.1;
  color: var(--text-primary);
}
.robot-name .red { color: var(--red); }

.robot-desc {
  font-size: 1.0rem;
  color: var(--text-secondary);
  line-height: 1.75;
}

.robot-features {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 4px;
}
.robot-features li {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: .9rem;
  color: var(--text-secondary);
}
.robot-features li svg { color: var(--red); flex-shrink: 0; }

/* ─── MAPAS ─── */
#mapas { background: var(--bg-secondary); }

.cards-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 32px;
}

.content-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: transform .35s, box-shadow .35s, border-color .35s;
  animation: fadeUp .7s ease both;
  box-shadow: var(--shadow-card);
}
.content-card:nth-child(1) { animation-delay: .1s; }
.content-card:nth-child(2) { animation-delay: .25s; }
.content-card:hover {
  transform: translateY(-8px);
  border-color: rgba(227,27,27,0.28);
  box-shadow: var(--shadow-red);
}

.card-visual {
  height: 220px;
  background: #ffffff !important;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
}
.card-glow-bg {
  background: #ffffff !important;
  opacity: 1;
}

.card-visual-inner {
  display: flex; align-items: center; justify-content: center;
  width: 100%; height: 100%;
  position: relative;
}

.card-img-cover { align-items: stretch; justify-content: stretch; }
.card-cover-img {
  width: 100%; height: 100%;
  object-fit: cover;
  object-position: center;
  position: relative; z-index: 1;
  transition: transform .4s ease;
}
.content-card:hover .card-cover-img { transform: scale(1.04); }

.map-grid-svg { position: relative; z-index: 1; animation: float 5s ease-in-out infinite; }
.book-svg { position: relative; z-index: 1; animation: float 4.5s 1s ease-in-out infinite; }
.card-glow-bg {
  position: absolute;
  width: 200px; height: 200px;
  border-radius: 50%;
  background: radial-gradient(ellipse, rgba(227,27,27,0.06) 0%, transparent 70%);
}
.card-body {
  padding: 28px 30px 32px;
  flex: 1;
  display: flex;
  flex-direction: column;
}
.card-tag {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: .9rem;
  font-weight: 700;
  letter-spacing: 2.5px;
  text-transform: uppercase;
  color: var(--red);
  margin-bottom: 14px;
}
.card-body h3 {
  font-family: 'Orbitron', sans-serif;
  font-size: 1.15rem;
  font-weight: 700;
  margin-bottom: 12px;
  letter-spacing: .3px;
  color: var(--text-primary);
}
.card-body p {
  font-size: 1.0rem;
  color: var(--text-secondary);
  line-height: 1.75;
  flex: 1;
  margin-bottom: 24px;
}

/* ─── MODAL ─── */
.modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 2000;
  background: rgba(0,0,0,0.3);
  backdrop-filter: blur(10px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  opacity: 0;
  pointer-events: none;
  transition: opacity .3s;
}
.modal-overlay.open { opacity: 1; pointer-events: all; }

.modal-box {
  background: var(--bg-card);
  border: 1px solid var(--border-medium);
  border-radius: var(--radius-xl);
  padding: 44px 40px 40px;
  max-width: 480px;
  width: 100%;
  position: relative;
  box-shadow: 0 32px 80px rgba(0,0,0,0.14), 0 0 0 1px var(--border-subtle);
  transform: translateY(20px) scale(0.97);
  transition: transform .35s cubic-bezier(0.34, 1.56, 0.64, 1);
}
.modal-overlay.open .modal-box { transform: translateY(0) scale(1); }

.modal-close {
  position: absolute;
  top: 16px; right: 16px;
  background: var(--bg-secondary);
  border: 1px solid var(--border-subtle);
  border-radius: 6px;
  color: var(--text-muted);
  cursor: pointer;
  padding: 6px;
  display: flex; align-items: center; justify-content: center;
  transition: background .2s, color .2s, border-color .2s;
}
.modal-close:hover { background: var(--red-light); border-color: rgba(227,27,27,0.3); color: var(--red); }

.modal-icon {
  width: 56px; height: 56px;
  background: var(--red-light);
  border: 1px solid rgba(227,27,27,0.2);
  border-radius: 14px;
  display: flex; align-items: center; justify-content: center;
  color: var(--red);
  margin-bottom: 20px;
}

.modal-title {
  font-family: 'Orbitron', sans-serif;
  font-size: 1.4rem;
  font-weight: 900;
  margin-bottom: 14px;
  color: var(--text-primary);
}
.modal-title .red { color: var(--red); }

.modal-desc {
  font-size: .87rem;
  color: var(--text-muted);
  line-height: 1.75;
  margin-bottom: 28px;
}

.modal-contact {
  background: var(--bg-secondary);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 20px 22px;
  margin-bottom: 28px;
}
.modal-contact-label {
  font-size: .7rem;
  font-weight: 700;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--red);
  margin-bottom: 14px;
}
.modal-contact-items { display: flex; flex-direction: column; gap: 10px; }
.modal-contact-item {
  display: flex; align-items: center; gap: 12px;
  font-size: .84rem;
  color: var(--text-secondary);
}
.modal-contact-item svg { color: var(--red); flex-shrink: 0; }

.modal-btn-close { width: 100%; justify-content: center; }

/* ─── CONTACT ─── */
#contacto {
  background: var(--bg-primary);
  text-align: center;
  position: relative;
  overflow: hidden;
}
#contacto::before {
  content: '';
  position: absolute;
  top: 0; left: 50%;
  transform: translateX(-50%);
  width: 700px; height: 300px;
  background: radial-gradient(ellipse, rgba(227,27,27,0.04) 0%, transparent 70%);
  pointer-events: none;
}

/* TECH HOME watermark in contact section */
.contact-watermark {
  position: absolute;
  top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  font-family: 'Orbitron', sans-serif;
  font-size: clamp(3rem, 8vw, 7rem);
  font-weight: 900;
  letter-spacing: 8px;
  white-space: nowrap;
  pointer-events: none;
  user-select: none;
  opacity: 0.025;
  z-index: 0;
}

.contact-inner {
  max-width: 560px;
  margin: 0 auto;
  position: relative;
  z-index: 1;
}
.contact-inner .section-label { justify-content: center; }
.contact-inner .section-label::before { display: none; }
.contact-inner .section-title { text-align: center; }
.contact-inner .section-sub { margin: 0 auto 48px; text-align: center; }

.contact-form { display: flex; flex-direction: column; gap: 16px; text-align: left; }
.input-group { display: flex; flex-direction: column; gap: 6px; }
.input-group label {
  font-size: .72rem;
  font-weight: 700;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: var(--text-muted);
}
.input-group input,
.input-group textarea {
  background: var(--bg-secondary);
  border: 1.5px solid var(--border-medium);
  border-radius: var(--radius-sm);
  padding: 13px 16px;
  color: var(--text-primary);
  font-family: 'Poppins', sans-serif;
  font-size: .88rem;
  outline: none;
  transition: border-color .25s, box-shadow .25s, background .25s;
  resize: none;
}
.input-group input::placeholder,
.input-group textarea::placeholder { color: var(--border-strong); }
.input-group input:focus,
.input-group textarea:focus {
  border-color: var(--red);
  box-shadow: 0 0 0 3px rgba(227,27,27,0.08);
  background: var(--bg-primary);
}
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }

/* ─── FOOTER ─── */
footer {
  background: var(--bg-secondary);
  border-top: 1px solid var(--border-subtle);
  padding: 32px 80px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
}
footer .logo { font-size: 1rem; }
footer p { font-size: .75rem; color: var(--text-muted); }
.footer-links { display: flex; gap: 20px; }
.footer-links a {
  color: var(--text-muted);
  text-decoration: none;
  font-size: .75rem;
  font-weight: 600;
  transition: color .25s;
}
.footer-links a:hover { color: var(--red); }

/* ─── ANIMATIONS ─── */
@keyframes fadeSlideLeft {
  from { opacity: 0; transform: translateX(-40px); }
  to   { opacity: 1; transform: translateX(0); }
}
@keyframes fadeSlideRight {
  from { opacity: 0; transform: translateX(40px); }
  to   { opacity: 1; transform: translateX(0); }
}
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(30px); }
  to   { opacity: 1; transform: translateY(0); }
}
@keyframes fadeIn {
  from { opacity: 0; }
  to   { opacity: .5; }
}
@keyframes float {
  0%, 100% { transform: translateY(0); }
  50%       { transform: translateY(-14px); }
}
@keyframes pulse {
  0%, 100% { transform: scale(1); opacity: .8; }
  50%       { transform: scale(1.06); opacity: 1; }
}
@keyframes spin {
  from { transform: rotate(0deg); }
  to   { transform: rotate(360deg); }
}
@keyframes blink {
  0%, 100% { opacity: 1; }
  50%       { opacity: .3; }
}
@keyframes scrollDot {
  0%   { transform: translateY(0); opacity: 1; }
  80%  { transform: translateY(10px); opacity: 0; }
  100% { transform: translateY(0); opacity: 0; }
}

/* ─── RESPONSIVE ─── */
@media (max-width: 900px) {
  header { padding: 0 24px; }
  nav { display: none; }
  .hamburger { display: flex; }
  .mobile-nav { display: flex; }

  #inicio {
    grid-template-columns: 1fr;
    padding: 120px 28px 80px;
    text-align: center;
  }
  .hero-left { order: 2; padding-left: 0; }
  .hero-left::before { display: none; }
  .hero-lines { display: none; }
  .hero-bg-number { font-size: 7rem; left: 50%; transform: translateX(-50%); }
  .hero-right { order: 1; }
  .btn-group { justify-content: center; }
  .hero-desc { margin: 0 auto 36px; }
  .hero-title-line { justify-content: center; }

  .robot-stage { width: 320px; height: 320px; }
  #robotCanvas { width: 320px !important; height: 320px !important; }

  section { padding: 70px 28px; }
  .features-grid { grid-template-columns: 1fr; }
  .robots-grid   { grid-template-columns: 1fr; }
  .cards-grid    { grid-template-columns: 1fr; }
  .form-row      { grid-template-columns: 1fr; }

  .robot-img-wrap { height: 220px; }
  .modal-box { padding: 36px 24px 28px; }
  .brand-strip { padding: 16px 28px; gap: 40px; }
  .section-header-wrap { flex-direction: column; }

  footer {
    padding: 28px 28px;
    flex-direction: column;
    text-align: center;
  }
  .footer-links { justify-content: center; }
}

/* ─── LOGO IMAGE HOVER ─── */
.logo img {
  transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}
.logo img:hover { transform: scale(1.15) translateY(-4px); }

/* ─── CARRUSEL 3D ─── */
.carousel {
  width: 100%;
  padding: 1.5rem 0 1rem;
  overflow: hidden;
  position: relative;
}
.carousel-track {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 240px;
  position: relative;
  perspective: 900px;
}
.carousel-slide {
  position: absolute;
  width: 190px; height: 275px;
  border-radius: var(--radius-md);
  overflow: hidden;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1),
              opacity  0.6s cubic-bezier(0.4, 0, 0.2, 1),
              filter   0.6s cubic-bezier(0.4, 0, 0.2, 1),
              box-shadow 0.6s cubic-bezier(0.4, 0, 0.2, 1);
  user-select: none;
}
.carousel-slide img { width: 100%; flex: 1; object-fit: cover; display: block; }
.carousel-label {
  display: block;
  text-align: center;
  padding: 8px 0;
  font-size: 14px;
  font-weight: 600;
  background: rgba(255,255,255,0.95);
  color: var(--text-primary);
  border-top: 1px solid var(--border-subtle);
}
.carousel-slide.pos-center {
  transform: translateX(0) scale(1);
  opacity: 1; filter: blur(0px);
  box-shadow: var(--shadow-lg);
  z-index: 10;
}
.carousel-slide.pos-side { opacity: 0.5; filter: blur(2px); box-shadow: none; z-index: 5; }
.carousel-slide.pos-side-left  { transform: translateX(-210px) scale(0.78); }
.carousel-slide.pos-side-right { transform: translateX(210px) scale(0.78); }
.carousel-slide.pos-far { opacity: 0.2; filter: blur(4px); box-shadow: none; z-index: 1; }
.carousel-slide.pos-far-left  { transform: translateX(-310px) scale(0.62); }
.carousel-slide.pos-far-right { transform: translateX(310px) scale(0.62); }
.carousel-dots { display: flex; justify-content: center; gap: 8px; margin-top: 1rem; }
.carousel-dots .dot {
  width: 7px; height: 7px;
  border-radius: 50%;
  background: var(--border-strong);
  cursor: pointer;
  transition: all 0.3s ease;
}
.carousel-dots .dot.active { background: var(--red); width: 20px; border-radius: 4px; }

/* ─── CARD LIBRO ─── */
.card-libro .card-visual {
  width: 100%; height: 340px;
  position: relative; overflow: hidden;
  border-radius: 8px 8px 0 0;
  background: var(--bg-tertiary);
  display: flex; align-items: center; justify-content: center;
  box-shadow: none;
}
.card-libro .card-visual-inner.card-img-cover {
  width: 90%; height: 100%;
  display: flex; align-items: center; justify-content: center;
  padding: 0;
}

/* ─── FOOTER LOGO ─── */
footer .logo {
  display: flex; align-items: center;
  text-decoration: none;
  font-size: 28px; font-weight: 900;
  gap: 4px;
}
footer .tech { color: var(--red); }
footer .home { color: var(--black); }

/* ─── NAV DROPDOWN ─── */
.nav-dropdown { position: relative; display: flex; align-items: center; }
.nav-dropdown-btn {
  background: none; border: none; cursor: pointer;
  display: flex; align-items: center; gap: 7px;
  font-family: 'Poppins', sans-serif;
  font-size: .92rem; font-weight: 600;
  letter-spacing: .8px; text-transform: uppercase;
  color: var(--text-secondary);
  padding: 8px 16px;
  border-radius: 6px;
  transition: color .25s;
  position: relative;
}
.nav-dropdown-btn::after {
  content: '';
  position: absolute;
  bottom: 4px; left: 50%; right: 50%;
  height: 2px;
  background: var(--red);
  transition: left .3s cubic-bezier(0.22,1,0.36,1), right .3s cubic-bezier(0.22,1,0.36,1);
  border-radius: 1px;
  box-shadow: 0 0 6px rgba(227,27,27,0.35);
}
.nav-dropdown:hover .nav-dropdown-btn { color: var(--black); }
.nav-dropdown:hover .nav-dropdown-btn::after { left: 16px; right: 16px; }
.nav-dropdown:hover .nav-dropdown-btn svg:first-child { color: var(--red); }
.nav-chevron { transition: transform 0.3s ease; }
.nav-dropdown:hover .nav-chevron { transform: rotate(180deg); }
.nav-dropdown-menu {
  display: none;
  position: absolute;
  top: calc(100% + 4px);
  left: 50%; transform: translateX(-50%);
  background: var(--bg-card);
  border: 1px solid var(--border-medium);
  border-radius: var(--radius-md);
  padding: 6px;
  min-width: 180px;
  z-index: 1100;
  flex-direction: column; gap: 2px;
  box-shadow: var(--shadow-lg);
}
.nav-dropdown-menu::before {
  content: '';
  position: absolute;
  top: -12px; left: 0;
  width: 100%; height: 12px;
}
.nav-dropdown:hover .nav-dropdown-menu { display: flex; }
.nav-dropdown-item {
  display: flex; align-items: center; gap: 8px;
  padding: 9px 12px;
  border-radius: 8px;
  font-size: 14px;
  color: var(--text-secondary);
  text-decoration: none;
  transition: background 0.2s, color 0.2s;
}
.nav-dropdown-item:hover { background: var(--red-light); color: var(--red); }

/* ─── MOBILE DROPDOWN ─── */
.mobile-dropdown { width: 100%; border-bottom: 1px solid var(--border-subtle); }
.mobile-dropdown-btn {
  background: none; border: none; cursor: pointer;
  display: flex; align-items: center; gap: 12px;
  font-family: 'Poppins', sans-serif;
  font-size: .88rem; font-weight: 600;
  letter-spacing: 1.5px; text-transform: uppercase;
  color: var(--text-secondary);
  padding: 15px 28px; width: 100%; text-align: left;
  transition: color .2s, background .2s, padding-left .2s;
}
.mobile-dropdown-btn:hover { color: var(--black); background: var(--red-light); padding-left: 36px; }
.mobile-dropdown-btn svg:first-child { color: var(--red); flex-shrink: 0; }
.mobile-chevron { margin-left: auto; transition: transform 0.3s ease; opacity: 0.5; }
.mobile-chevron.open { transform: rotate(180deg); }
.mobile-dropdown-menu {
  display: none; flex-direction: column;
  padding: 4px 0 8px 52px; gap: 2px;
  background: rgba(0,0,0,0.02);
}
.mobile-dropdown-menu.open { display: flex; }
.mobile-dropdown-menu a {
  display: flex; align-items: center; gap: 8px;
  padding: 10px 16px; border-radius: 8px;
  font-size: .82rem; font-weight: 600;
  letter-spacing: 1px; text-transform: uppercase;
  color: var(--text-muted); text-decoration: none;
  transition: background 0.2s, color 0.2s;
  border-bottom: none !important;
}
.mobile-dropdown-menu a svg { color: var(--red); flex-shrink: 0; }
.mobile-dropdown-menu a:hover { background: var(--red-light); color: var(--red); }





/*
 * logo-brand.css
 * Integración del logo logotechhome.png
 */

/* ═══════════════════════════════════════════════════════════════
   ① HERO — Watermark más grande y visible
   ═══════════════════════════════════════════════════════════════ */
.hero-logo-watermark {
  position: absolute;
  bottom: 40px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 1;
  pointer-events: none;
  user-select: none;
}

.hero-logo-watermark img {
  width: clamp(140px, 18vw, 240px);
  height: auto;
  object-fit: contain;
  opacity: 0.08;
  filter: grayscale(100%);
  animation: watermarkPulse 8s ease-in-out infinite;
}
@keyframes watermarkPulse {
  0%, 100% { opacity: 0.08; }
  50%       { opacity: 0.13; }
}

@media (max-width: 900px) {
  .hero-logo-watermark { bottom: 20px; }
  .hero-logo-watermark img {
    width: clamp(160px, 40vw, 240px);
    opacity: 0.07;
  }
}

@media (max-width: 600px) {
  .hero-logo-watermark img {
    width: clamp(90px, 30vw, 130px);
    opacity: 0.06;
  }
}


/* ═══════════════════════════════════════════════════════════════
   ② BRAND STRIP — Logo en el marquee
   ═══════════════════════════════════════════════════════════════ */
.brand-strip-logo-item {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 8px;
}

.brand-strip-logo-img {
  height: 26px;
  width: auto;
  object-fit: contain;
  opacity: 0.45;
  filter: grayscale(30%);
  transition: opacity 0.3s, filter 0.3s;
  flex-shrink: 0;
}

.brand-strip:hover .brand-strip-logo-img {
  opacity: 0.65;
  filter: grayscale(0%);
}

@media (max-width: 900px) {
  .brand-strip-logo-img { height: 20px; }
}


/* ═══════════════════════════════════════════════════════════════
   ③ & ④ SECTION BRAND TAG — Logo visible en todas las pantallas
   ═══════════════════════════════════════════════════════════════ */
.section-brand-tag--logo {
  padding: 10px 20px;
  background: var(--bg-card);
  border: 1.5px solid var(--border-medium);
  border-radius: 8px;
  box-shadow: var(--shadow-sm);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  white-space: nowrap;
  align-self: flex-start;
  margin-top: 4px;
  transition: border-color 0.3s, box-shadow 0.3s, transform 0.25s;
}

.section-brand-tag--logo:hover {
  border-color: rgba(227, 27, 27, 0.28);
  box-shadow: var(--shadow-red);
  transform: translateY(-2px);
}

.section-tag-logo-img {
  height: 48px;
  width: auto;
  object-fit: contain;
  opacity: 0.88;
  transition: opacity 0.3s;
}

.section-brand-tag--logo:hover .section-tag-logo-img {
  opacity: 1;
}

/* Tablet: logo un poco más pequeño pero siempre visible */
@media (max-width: 900px) {
  .section-brand-tag--logo {
    padding: 8px 14px;
    align-self: flex-start;
  }
  .section-tag-logo-img {
    height: 38px;
  }
}

/* Mobile: logo más compacto pero siempre visible — sin display:none */
@media (max-width: 600px) {
  .section-brand-tag--logo {
    padding: 6px 12px;
    align-self: flex-start;
  }
  .section-tag-logo-img {
    height: 30px;
  }
}


/* ═══════════════════════════════════════════════════════════════
   ⑤ MODAL — Logo firma institucional
   ═══════════════════════════════════════════════════════════════ */
.modal-brand-logo {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  margin-bottom: 16px;
}

.modal-logo-img {
  height: 22px;
  width: auto;
  object-fit: contain;
  opacity: 0.55;
  filter: grayscale(20%);
  transition: opacity 0.3s;
}

.modal-box:hover .modal-logo-img {
  opacity: 0.75;
}

@media (max-width: 600px) {
  .modal-logo-img { height: 18px; }
}


/* ═══════════════════════════════════════════════════════════════
   ⑥ FOOTER — Logo principal
   ═══════════════════════════════════════════════════════════════ */
.footer-logo-link {
  display: inline-flex;
  align-items: center;
  text-decoration: none;
  transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1), opacity 0.25s;
}

.footer-logo-img {
  height: 50px;
  width: auto;
  object-fit: contain;
  opacity: 0.95;
  transition: opacity 0.3s, transform 0.3s;
}
.footer-logo-link:hover .footer-logo-img {
  opacity: 1;
  transform: scale(1.06) translateY(-3px);
}

@media (max-width: 900px) {
  .footer-logo-img { height: 36px; }
  .footer-logo-link { align-self: center; }
}

@media (max-width: 600px) {
  .footer-logo-img {
    height: 50px;
    opacity: 1;
  }
}






/* ─── HEADER: LOGOS WRAPPER IZQUIERDA ─── */
.header-left-logos {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-shrink: 0;
}

/* ─── LOGO TECHHOME DESKTOP (extremo derecho) ─── */
.header-techhome-desktop {
  display: flex;
  align-items: center;
  flex-shrink: 0;
  text-decoration: none;
  margin-left: auto; /* empuja al extremo derecho si nav no lo llena */
}
.header-techhome-desktop img {
  height: 46px;
  width: auto;
  object-fit: contain;
  opacity: 0.85;
  transition: opacity 0.3s, transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}
.header-techhome-desktop:hover img {
  opacity: 1;
  transform: scale(1.07) translateY(-2px);
}

/* ─── LOGO TECHHOME MÓVIL (junto a EduBot, oculto en desktop) ─── */
.header-techhome-mobile {
  display: none;
  align-items: center;
  text-decoration: none;
}
.header-techhome-mobile img {
  height: 38px;
  width: auto;
  object-fit: contain;
  opacity: 0.88;
}

/* ─── LOGO EDUBOT RESPONSIVE ─── */
.logo-edubot-img {
  height: 80px;
  width: auto;
  object-fit: contain;
}

@media (max-width: 900px) {
  .header-techhome-desktop {
    display: none;
  }
  .header-techhome-mobile {
    display: flex;
  }
  .logo-edubot-img {
    height: 60px;
  }
  .header-techhome-mobile img {
    height: 44px;
  }
  .header-left-logos {
    gap: 10px;
  }
}

@media (max-width: 420px) {
  .logo-edubot-img {
    height: 54px;
  }
  .header-techhome-mobile img {
    height: 44px;
  }
  .header-left-logos {
    gap: 6px;
  }
}

/* ─── NAV CENTRADO EN HEADER (desktop) ─── */
header nav {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  z-index: 1100;
}

.header-left-logos {
  position: relative;
  z-index: 1;
}

.header-techhome-desktop {
  position: relative;
  z-index: 1;
}

.hamburger {
  position: relative;
  z-index: 1;
}


.nav-dropdown { 

  z-index: 1100;
}