/* ===========================
   DUAL STACK — STYLES
   =========================== */

:root {
  --bg: #0B0F1A;
  --bg-2: #0f1422;
  --surface: #1F2A44;
  --blue: #4F8CFF;
  --violet: #7B61FF;
  --cyan: #00E5FF;
  --text: #E8EEFF;
  --text-muted: #8892A4;
  --border: rgba(255, 255, 255, 0.07);
  --glass: rgba(255, 255, 255, 0.04);
  --glass-border: rgba(255, 255, 255, 0.10);
  --radius: 16px;
  --radius-sm: 8px;
  --shadow-glow: 0 0 40px rgba(79, 140, 255, 0.12);
  --transition: 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}

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

html { scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: 'Space Grotesk', 'Inter', sans-serif;
  font-size: 16px;
  line-height: 1.65;
  overflow-x: hidden;
}

img { max-width: 100%; display: block; }
a { text-decoration: none; color: inherit; }
ul { list-style: none; }

.container { max-width: 1180px; margin: 0 auto; padding: 0 24px; }
.section { padding: 100px 0; position: relative; overflow: hidden; display: flex; align-items: center; min-height: 90vh; }

/* ===========================
   TYPOGRAPHY
   =========================== */

h1, h2, h3, h4, h5 { font-weight: 700; line-height: 1.15; letter-spacing: -0.02em; }
h1 { font-size: clamp(2.4rem, 5vw, 3.8rem); }
h2 { font-size: clamp(1.9rem, 3.5vw, 2.8rem); }
h3 { font-size: 1.3rem; }
h4 { font-size: 1.1rem; }
h5 { font-size: 0.9rem; text-transform: uppercase; letter-spacing: 0.08em; }

.gradient-text {
  background: linear-gradient(135deg, var(--blue) 0%, var(--violet) 50%, var(--cyan) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* ===========================
   GLASSMORPHISM
   =========================== */

.glassmorphism {
  background: var(--glass);
  border: 1px solid var(--glass-border);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
}

/* ===========================
   BUTTONS
   =========================== */

.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 24px;
  border-radius: 10px;
  font-weight: 600;
  font-size: 0.95rem;
  cursor: pointer;
  border: none;
  transition: var(--transition);
  font-family: inherit;
  letter-spacing: -0.01em;
}

.btn-primary {
  background: linear-gradient(135deg, var(--blue), var(--violet));
  color: #fff;
  box-shadow: 0 4px 24px rgba(79, 140, 255, 0.3);
}
.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 32px rgba(79, 140, 255, 0.45);
}

.btn-ghost {
  background: transparent;
  color: var(--text);
  border: 1px solid var(--glass-border);
}
.btn-ghost:hover {
  background: var(--glass);
  border-color: rgba(255,255,255,0.18);
  transform: translateY(-2px);
}

.btn-lg { padding: 16px 32px; font-size: 1rem; border-radius: 12px; }
.btn-full { width: 100%; justify-content: center; }

/* ===========================
   SECTION HEADER
   =========================== */

.section-header { text-align: center; margin-bottom: 32px; max-width: 640px; margin-left: auto; margin-right: auto; }
.section-header p { color: var(--text-muted); margin-top: 16px; font-size: 1.05rem; }

.section-tag {
  display: inline-block;
  padding: 6px 16px;
  border-radius: 100px;
  background: rgba(79, 140, 255, 0.1);
  border: 1px solid rgba(79, 140, 255, 0.2);
  color: var(--blue);
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  margin-bottom: 20px;
}

/* ===========================
   REVEAL ANIMATION
   =========================== */

.reveal {
  opacity: 0;
  transform: translateY(36px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}
.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ===========================
   NAVBAR
   =========================== */

.navbar {
  position: absolute; /* Cambiado de fixed a absolute para que se pierda al scrollear */
  top: 0; left: 0; right: 0;
  z-index: 1000;
  padding: 18px 0;
  transition: var(--transition);
}

.navbar.scrolled,
.navbar.menu-open {
  background: #0b0f1a;
  border-bottom: 1px solid var(--border);
  padding: 12px 0;
}

.nav-inner {
  display: flex;
  align-items: center;
  gap: 40px;
}

.logo {
  font-size: 1.3rem;
  font-weight: 700;
  letter-spacing: -0.03em;
  flex-shrink: 0;
}
.logo-ds { color: var(--text); }
.logo-stack {
  background: linear-gradient(135deg, var(--blue), var(--violet));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.nav-links {
  display: flex;
  gap: 32px;
  flex: 1;
  justify-content: center;
}
.nav-links a {
  color: var(--text-muted);
  font-size: 0.92rem;
  font-weight: 500;
  transition: color 0.25s;
  position: relative;
}
.nav-links a::after {
  content: '';
  position: absolute;
  bottom: -4px; left: 0;
  width: 0; height: 2px;
  background: linear-gradient(90deg, var(--blue), var(--violet));
  transition: width 0.3s;
  border-radius: 2px;
}
.nav-links a:hover { color: var(--text); }
.nav-links a:hover::after { width: 100%; }

.nav-cta { margin-left: auto; }

.hamburger {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
  margin-left: auto;
  z-index: 1001;
  width: 40px;
  height: 40px;
  border-radius: 8px;
  transition: background var(--transition);
}
.hamburger:hover { background: var(--glass); }
.hamburger span {
  display: block;
  width: 22px; height: 2px;
  background: var(--text);
  border-radius: 2px;
  transition: transform 0.35s cubic-bezier(0.4,0,0.2,1), opacity 0.25s ease, width 0.25s ease;
  transform-origin: center;
}
/* Hamburger → X animation */
.navbar.menu-open .hamburger span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}
.navbar.menu-open .hamburger span:nth-child(2) {
  opacity: 0;
  width: 0;
}
.navbar.menu-open .hamburger span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

/* ===========================
   HERO
   =========================== */

.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding-top: 100px;
  position: relative;
  overflow: hidden;
}

.hero-bg-grid {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(79,140,255,0.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(79,140,255,0.04) 1px, transparent 1px);
  background-size: 64px 64px;
  mask-image: radial-gradient(ellipse at center, black 30%, transparent 80%);
}

.hero-orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(80px);
  pointer-events: none;
}
.hero-orb-1 { width: 500px; height: 500px; background: rgba(79,140,255,0.13); top: -100px; right: 5%; }
.hero-orb-2 { width: 400px; height: 400px; background: rgba(123,97,255,0.12); bottom: -100px; left: 10%; }
.hero-orb-3 { width: 300px; height: 300px; background: rgba(0,229,255,0.08); top: 40%; right: 30%; }

.hero-content {
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: center;
  gap: 64px;
  padding-bottom: 80px;
}

.hero-text { z-index: 1; }

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 8px 18px;
  border-radius: 100px;
  background: rgba(79,140,255,0.08);
  border: 1px solid rgba(79,140,255,0.18);
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--blue);
  letter-spacing: 0.05em;
  margin-bottom: 28px;
}
.badge-dot {
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--cyan);
  box-shadow: 0 0 10px var(--cyan);
  animation: pulse 2s infinite;
}

@keyframes pulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.6; transform: scale(0.8); }
}

.hero-title { margin-bottom: 24px; }

.hero-subtitle {
  color: var(--text-muted);
  font-size: 1.1rem;
  margin-bottom: 40px;
  max-width: 500px;
}
.hero-subtitle strong { color: var(--text); font-weight: 600; }

.hero-actions { display: flex; gap: 16px; margin-bottom: 56px; flex-wrap: wrap; }

.hero-stats {
  display: flex;
  align-items: center;
  gap: 24px;
}
.stat { display: flex; flex-direction: column; }
.stat-number {
  font-size: 1.6rem;
  font-weight: 700;
  background: linear-gradient(135deg, var(--blue), var(--cyan));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  line-height: 1;
}
.stat-label { font-size: 0.78rem; color: var(--text-muted); margin-top: 4px; }
.stat-divider { width: 1px; height: 36px; background: var(--border); flex-shrink: 0; }

/* Hero Pillars */
.hero-pillars {
  display: flex;
  flex-direction: column;
  gap: 20px;
  margin-top: 32px;
}
.pillar {
  display: flex;
  align-items: flex-start;
  gap: 16px;
}
.pillar-icon {
  font-size: 1.5rem;
  flex-shrink: 0;
  margin-top: 2px;
}
.pillar-content h4 {
  font-size: 1.05rem;
  margin-bottom: 4px;
  color: var(--text);
}
.pillar-content p {
  font-size: 0.9rem;
  color: var(--text-muted);
  line-height: 1.4;
}

/* Hero visual */
.hero-visual { position: relative; z-index: 1; }

.hero-image-wrapper {
  position: relative;
  border-radius: var(--radius);
  overflow: visible;
}

.hero-img {
  width: 100%;
  border-radius: var(--radius);
  display: block;
  box-shadow: 0 24px 80px rgba(0,0,0,0.6), 0 0 60px rgba(79,140,255,0.15);
  animation: float 6s ease-in-out infinite;
}

/* SVG illustrations */
.about-svg-art {
  width: 100%;
  height: auto;
  border-radius: var(--radius);
  display: block;
  box-shadow: 0 24px 80px rgba(0,0,0,0.5), 0 0 50px rgba(123,97,255,0.15);
  animation: float 7s ease-in-out infinite;
}

@keyframes float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-12px); }
}

.hero-float-card {
  position: absolute;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 18px;
  border-radius: 12px;
  font-size: 0.82rem;
  animation: float 6s ease-in-out infinite;
}
.hero-float-card svg { flex-shrink: 0; }
.float-label { color: var(--text-muted); font-size: 0.72rem; margin-bottom: 1px; }
.float-value { font-weight: 700; font-size: 0.95rem; color: var(--text); }

.card-1 { top: 12%; left: -10%; animation-delay: -2s; }
.card-2 { bottom: 18%; left: -12%; animation-delay: -4s; }
.card-3 { top: -5%; right: -5%; animation-delay: -1s; }

.hero-scroll-hint {
  position: absolute;
  bottom: 32px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  color: var(--text-muted);
  font-size: 0.72rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}
.scroll-line {
  width: 1px;
  height: 40px;
  background: linear-gradient(to bottom, var(--blue), transparent);
  animation: scrollAnim 1.8s ease-in-out infinite;
}
@keyframes scrollAnim {
  0% { opacity: 0; transform: scaleY(0); transform-origin: top; }
  50% { opacity: 1; transform: scaleY(1); }
  100% { opacity: 0; transform: scaleY(1); transform-origin: bottom; }
}

/* ===========================
   SERVICES
   =========================== */

.services { background: var(--bg-2); }

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

.service-card {
  border-radius: var(--radius);
  padding: 40px 32px;
  position: relative;
  overflow: hidden;
  transition: transform var(--transition), box-shadow var(--transition);
  cursor: default;
}
.service-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 24px 60px rgba(0,0,0,0.35);
}

.service-icon-wrap {
  width: 56px; height: 56px;
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 24px;
}
.icon-blue { background: rgba(79,140,255,0.12); color: var(--blue); }
.icon-violet { background: rgba(123,97,255,0.12); color: var(--violet); }
.icon-cyan { background: rgba(0,229,255,0.12); color: var(--cyan); }

.service-card h3 { margin-bottom: 14px; }
.service-card p { color: var(--text-muted); font-size: 0.95rem; margin-bottom: 24px; }

.service-tags {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}
.service-tags li {
  padding: 4px 12px;
  border-radius: 100px;
  background: rgba(255,255,255,0.05);
  border: 1px solid var(--border);
  font-size: 0.76rem;
  color: var(--text-muted);
  font-weight: 500;
}

.service-glow {
  position: absolute;
  bottom: -40px; right: -40px;
  width: 160px; height: 160px;
  border-radius: 50%;
  filter: blur(50px);
  pointer-events: none;
  opacity: 0.4;
  transition: opacity var(--transition);
}
.service-card:hover .service-glow { opacity: 0.7; }
.glow-blue { background: var(--blue); }
.glow-violet { background: var(--violet); }
.glow-cyan { background: var(--cyan); }

/* ===========================
   PORTFOLIO
   =========================== */

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

.portfolio-card {
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--glass);
  border: 1px solid var(--glass-border);
  transition: transform var(--transition), box-shadow var(--transition);
}
.portfolio-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 24px 60px rgba(0,0,0,0.35);
}

.portfolio-img-wrap {
  position: relative;
  overflow: hidden;
  height: 220px;
}
.portfolio-img-wrap img,
.portfolio-img-wrap svg {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}
.portfolio-img-wrap svg {
  object-fit: initial;
}
.portfolio-card:hover .portfolio-img-wrap img { transform: scale(1.05); }

.portfolio-overlay {
  position: absolute;
  top: 14px; left: 14px;
}
.portfolio-tag {
  padding: 5px 14px;
  border-radius: 100px;
  background: rgba(11,15,26,0.85);
  backdrop-filter: blur(8px);
  border: 1px solid var(--glass-border);
  font-size: 0.76rem;
  font-weight: 600;
  color: var(--blue);
  letter-spacing: 0.05em;
}

.portfolio-info { padding: 24px; }
.portfolio-info h3 { margin-bottom: 10px; font-size: 1.15rem; }
.portfolio-info p { color: var(--text-muted); font-size: 0.9rem; margin-bottom: 16px; }

.portfolio-stack {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.portfolio-stack span {
  padding: 3px 10px;
  border-radius: 100px;
  background: rgba(79,140,255,0.08);
  border: 1px solid rgba(79,140,255,0.15);
  font-size: 0.73rem;
  color: var(--blue);
  font-weight: 500;
}

/* ===========================
   PROCESO (TIMELINE)
   =========================== */

.proceso { background: var(--bg-2); }

.timeline {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 0;
}

.timeline-line {
  position: absolute;
  left: 27px;
  top: 0; bottom: 0;
  width: 2px;
  background: linear-gradient(to bottom, var(--blue), var(--violet), var(--cyan));
  opacity: 0.3;
}

.timeline-step {
  display: flex;
  align-items: flex-start;
  gap: 24px;
  padding-bottom: 32px;
  position: relative;
}

.timeline-dot {
  width: 56px; height: 56px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  position: relative;
  z-index: 1;
}
.dot-blue { background: rgba(79,140,255,0.15); border: 2px solid rgba(79,140,255,0.4); color: var(--blue); }
.dot-violet { background: rgba(123,97,255,0.15); border: 2px solid rgba(123,97,255,0.4); color: var(--violet); }
.dot-cyan { background: rgba(0,229,255,0.15); border: 2px solid rgba(0,229,255,0.4); color: var(--cyan); }

.timeline-content {
  border-radius: var(--radius);
  padding: 24px 28px;
  flex: 1;
  transition: transform var(--transition);
}
.timeline-content:hover { transform: translateX(6px); }

.step-number {
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--text-muted);
  letter-spacing: 0.1em;
  display: block;
  margin-bottom: 6px;
}
.timeline-content h4 { margin-bottom: 8px; }
.timeline-content p { color: var(--text-muted); font-size: 0.92rem; }

/* ===========================
   ABOUT
   =========================== */

.about-inner {
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: center;
  gap: 80px;
}

.about-orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(100px);
  pointer-events: none;
}
.about-orb-1 { width: 400px; height: 400px; background: rgba(123,97,255,0.1); top: 0; left: -100px; }
.about-orb-2 { width: 300px; height: 300px; background: rgba(0,229,255,0.07); bottom: 0; right: -50px; }

.about-text .section-tag { display: inline-block; margin-bottom: 20px; }
.about-text h2 { margin-bottom: 24px; }
.about-text p { color: var(--text-muted); margin-bottom: 16px; font-size: 1rem; }
.about-text p strong { color: var(--text); }

.about-features { margin-top: 32px; display: flex; flex-direction: column; gap: 14px; }
.about-feature {
  display: flex;
  align-items: center;
  gap: 14px;
  font-size: 0.95rem;
  font-weight: 500;
}
.feature-dot {
  width: 10px; height: 10px;
  border-radius: 50%;
  flex-shrink: 0;
}
.feature-dot.dot-blue { background: var(--blue); box-shadow: 0 0 10px rgba(79,140,255,0.5); }
.feature-dot.dot-violet { background: var(--violet); box-shadow: 0 0 10px rgba(123,97,255,0.5); }
.feature-dot.dot-cyan { background: var(--cyan); box-shadow: 0 0 10px rgba(0,229,255,0.5); }

.about-img-wrapper {
  position: relative;
  border-radius: var(--radius);
}
.about-img-wrapper img {
  border-radius: var(--radius);
  width: 100%;
  box-shadow: 0 24px 80px rgba(0,0,0,0.5), 0 0 50px rgba(123,97,255,0.15);
  animation: float 7s ease-in-out infinite;
}

.about-badge {
  position: absolute;
  bottom: -16px; left: -24px;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 20px;
  border-radius: 14px;
}

/* ===========================
   TESTIMONIALS
   =========================== */

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

.testimonial-card {
  border-radius: var(--radius);
  padding: 32px;
  transition: transform var(--transition);
}
.testimonial-card:hover { transform: translateY(-4px); }

.stars { color: #FFD700; font-size: 1rem; margin-bottom: 16px; letter-spacing: 2px; }

.testimonial-text {
  color: var(--text-muted);
  font-size: 0.95rem;
  line-height: 1.75;
  margin-bottom: 24px;
  font-style: italic;
}

.testimonial-author { display: flex; align-items: center; gap: 14px; }
.author-avatar {
  width: 44px; height: 44px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.85rem;
  flex-shrink: 0;
}
.avatar-1 { background: linear-gradient(135deg, var(--blue), var(--violet)); color: #fff; }
.avatar-2 { background: linear-gradient(135deg, var(--violet), var(--cyan)); color: #fff; }
.avatar-3 { background: linear-gradient(135deg, var(--cyan), var(--blue)); color: var(--bg); }

.author-name { font-weight: 600; font-size: 0.92rem; }
.author-role { color: var(--text-muted); font-size: 0.8rem; }

/* ===========================
   CONTACT
   =========================== */

.contact { 
  background: var(--bg-2); 
  min-height: 100vh; 
  display: flex; 
  align-items: center; 
  justify-content: center; 
  padding: 80px 0; 
  position: relative;
}

.contact-bg-network {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse at 10% 50%, rgba(79,140,255,0.06) 0%, transparent 60%),
    radial-gradient(ellipse at 90% 30%, rgba(123,97,255,0.07) 0%, transparent 60%),
    radial-gradient(ellipse at 50% 80%, rgba(0,229,255,0.04) 0%, transparent 60%);
  pointer-events: none;
}

.contact-orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(100px);
  pointer-events: none;
}
.contact-orb-1 { width: 500px; height: 500px; background: rgba(79,140,255,0.07); top: -100px; right: -100px; }
.contact-orb-2 { width: 350px; height: 350px; background: rgba(123,97,255,0.08); bottom: -100px; left: -50px; }

.contact-inner {
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  gap: 80px;
  align-items: center;
  position: relative;
  z-index: 1;
  width: 100%;
}

.contact-text .section-tag { display: inline-block; margin-bottom: 20px; }
.contact-text h2 { margin-bottom: 20px; }
.contact-text p { color: var(--text-muted); margin-bottom: 40px; font-size: 1rem; }

.contact-methods { display: flex; flex-direction: column; gap: 14px; }
.contact-method {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 16px 20px;
  border-radius: var(--radius-sm);
  font-weight: 500;
  font-size: 0.92rem;
  transition: var(--transition);
}
.contact-method:hover { background: rgba(255,255,255,0.07); transform: translateX(6px); }

/* Contact Form */
.contact-form {
  border-radius: var(--radius);
  padding: 40px;
}

.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }

.form-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 20px;
}
.form-group:last-of-type { margin-bottom: 0; }

.form-group label {
  font-size: 0.84rem;
  font-weight: 600;
  color: var(--text-muted);
  letter-spacing: 0.03em;
}

.form-group input,
.form-group select,
.form-group textarea {
  background: rgba(255,255,255,0.04);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-sm);
  padding: 12px 16px;
  color: var(--text);
  font-family: inherit;
  font-size: 0.95rem;
  transition: border-color 0.25s, box-shadow 0.25s;
  appearance: none;
  outline: none;
}
.form-group input::placeholder,
.form-group textarea::placeholder { color: rgba(136,146,164,0.5); }
.form-group select option { background: var(--surface); }

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  border-color: var(--blue);
  box-shadow: 0 0 0 3px rgba(79,140,255,0.12);
}
.form-group textarea { resize: vertical; min-height: 100px; }

.contact-form .btn-primary { margin-top: 8px; }

.form-success {
  display: none;
  align-items: center;
  gap: 10px;
  margin-top: 16px;
  color: var(--cyan);
  font-size: 0.92rem;
  font-weight: 600;
}

/* ===========================
   FOOTER
   =========================== */

.footer {
  background: var(--bg);
  border-top: 1px solid var(--border);
  padding-top: 40px;
}

.footer-inner {
  display: flex;
  gap: 40px;
  padding-bottom: 32px;
  flex-wrap: wrap;
}

.footer-brand { max-width: 240px; }
.footer-brand .logo { margin-bottom: 14px; display: inline-block; }
.footer-brand p { color: var(--text-muted); font-size: 0.9rem; }

.footer-links { display: flex; gap: 40px; flex: 1; }
.footer-col { display: flex; flex-direction: column; gap: 8px; }
.footer-col h5 { color: var(--text-muted); margin-bottom: 2px; font-size: 0.72rem; }
.footer-col a { color: var(--text-muted); font-size: 0.8rem; transition: color 0.25s; }
.footer-col a:hover { color: var(--text); }

.footer-bottom {
  border-top: 1px solid var(--border);
  padding: 12px 0;
  text-align: center;
}
.footer-bottom p { color: var(--text-muted); font-size: 0.82rem; }

/* ===========================
   FAQ
   =========================== */

.faq { background: var(--bg-2); }

.faq-grid {
  max-width: 800px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.faq-item {
  border-radius: var(--radius);
  overflow: hidden;
  transition: transform var(--transition), box-shadow var(--transition);
}
.faq-item:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 40px rgba(0,0,0,0.25);
}

.faq-question {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 22px 28px;
  cursor: pointer;
  font-weight: 600;
  font-size: 1rem;
  color: var(--text);
  list-style: none;
  transition: color 0.25s;
}
.faq-question::-webkit-details-marker { display: none; }
.faq-question::marker { display: none; content: ''; }

.faq-question:hover { color: var(--blue); }

.faq-chevron {
  flex-shrink: 0;
  color: var(--text-muted);
  transition: transform 0.35s cubic-bezier(0.4, 0, 0.2, 1), color 0.25s;
}

.faq-item[open] .faq-chevron {
  transform: rotate(180deg);
  color: var(--blue);
}

.faq-answer {
  padding: 0 28px 22px;
  animation: faqFadeIn 0.3s ease-out;
}
.faq-answer p {
  color: var(--text-muted);
  font-size: 0.95rem;
  line-height: 1.75;
}
.faq-answer p strong { color: var(--text); }

@keyframes faqFadeIn {
  from { opacity: 0; transform: translateY(-8px); }
  to   { opacity: 1; transform: translateY(0); }
}


/* ===========================
   RESPONSIVE
   =========================== */

/* —— Tablet grande (≤1024px) —— */
@media (max-width: 1024px) {
  h1 { font-size: 2.6rem; }
  .hero-content { gap: 40px; }
  .services-grid { grid-template-columns: repeat(2, 1fr); }
  .portfolio-grid { grid-template-columns: repeat(2, 1fr); }
  .testimonials-grid { grid-template-columns: repeat(2, 1fr); }
  .about-inner { gap: 48px; }
  .contact-inner { gap: 48px; }
}

/* —— Tablet (≤768px) —— */
@media (max-width: 768px) {
  .section { padding: 72px 0; min-height: unset; }

  /* NAV */
  .nav-links, .nav-cta { display: none; }
  .hamburger { display: flex; }

  .navbar.menu-open .nav-links {
    display: flex;
    flex-direction: column;
    position: fixed;
    top: 64px;
    left: 0; 
    right: 0; 
    bottom: 0;
    background: #0b0f1a;
    padding: 30px 40px; /* Padding para alinear a la izquierda */
    gap: 0;
    align-items: flex-start; /* Alineado a la izquierda como la referencia */
    justify-content: flex-start;
    z-index: 10000;
    overflow-y: hidden;
    border-top: 2px solid var(--violet); /* Línea de acento estilo la captura */
    animation: menuFadeIn 0.3s ease-out;
  }
  .navbar.menu-open .nav-links li { 
    width: 100%; 
    text-align: left; 
    border-bottom: 1px solid rgba(255,255,255,0.03); /* Divisor sutil entre items */
  }
  .navbar.menu-open .nav-links a {
    font-size: 1.25rem;
    font-weight: 500;
    color: var(--text);
    display: block;
    padding: 18px 20px; /* Aumentado padding para el efecto */
    margin: 0 -20px; /* Compensa el padding para que el fondo cubra todo el ancho */
    letter-spacing: 0.02em;
    transition: background 0.2s, color 0.2s, padding-left 0.2s;
    border-radius: 4px;
  }
  .navbar.menu-open .nav-links a:active,
  .navbar.menu-open .nav-links a.active-selection {
    background: linear-gradient(90deg, rgba(79, 140, 255, 0.15), transparent);
    color: var(--blue);
    padding-left: 30px;
  }
  .navbar.menu-open .nav-links a::after { display: none; }

  .navbar.menu-open .nav-cta {
    display: none !important;
  }

  @keyframes menuFadeIn {
    from { opacity: 0; transform: translateY(-8px); }
    to   { opacity: 1; transform: translateY(0); }
  }

  /* HERO */
  .hero { padding-top: 80px; min-height: unset; }
  .hero-content {
    grid-template-columns: 1fr;
    gap: 40px;
    padding-bottom: 48px;
    text-align: center;
  }
  .hero-visual { display: none; }
  .hero-subtitle { max-width: 100%; margin-left: auto; margin-right: auto; }
  .hero-actions { justify-content: center; }
  .hero-stats { justify-content: center; flex-wrap: wrap; gap: 20px; }
  .hero-scroll-hint { display: none; }

  /* SERVICES */
  .services-grid { grid-template-columns: 1fr; gap: 16px; }
  .service-card { padding: 28px 24px; }

  /* PORTFOLIO */
  .portfolio-grid { grid-template-columns: 1fr; gap: 20px; }

  /* PROCESO / TIMELINE */
  .timeline-line {
    display: block;
    left: 19px;
    opacity: 0.2;
  }
  .timeline-step { gap: 16px; padding-bottom: 24px; }
  .timeline-dot { width: 40px; height: 40px; flex-shrink: 0; }
  .timeline-dot svg { width: 16px; height: 16px; }
  .timeline-content { padding: 20px; }
  .timeline-content:hover { transform: none; }

  /* ABOUT */
  .about-inner { grid-template-columns: 1fr; gap: 40px; }
  .about-visual { display: none; }

  /* TESTIMONIALS */
  .testimonials-grid { grid-template-columns: 1fr; gap: 16px; }
  .testimonial-card { padding: 24px; }

  /* CONTACT */
  .contact { padding: 72px 0; min-height: unset; }
  .contact-inner { grid-template-columns: 1fr; gap: 40px; }
  .contact-methods { gap: 10px; }
  .contact-method { padding: 14px 16px; }
  .contact-form { padding: 28px 20px; }
  .form-row { grid-template-columns: 1fr; gap: 0; }

  /* FAQ */
  .faq { min-height: unset; }
  .faq-question { padding: 18px 20px; font-size: 0.92rem; }
  .faq-answer { padding: 0 20px 18px; }

  /* FOOTER */
  .footer-inner { flex-direction: column; gap: 32px; }
  .footer-links { flex-direction: column; gap: 24px; }
  .footer-brand { max-width: 100%; }
}

/* —— Móvil (≤480px) —— */
@media (max-width: 480px) {
  h1 { font-size: 2rem; }
  h2 { font-size: 1.6rem; }

  .section { padding: 60px 0; }
  .container { padding: 0 16px; }

  .hero-actions { flex-direction: column; align-items: center; }
  .btn-lg { width: 100%; justify-content: center; }

  .card-1, .card-2, .card-3 { display: none; }

  .section-tag { font-size: 0.75rem; }
  .service-card { padding: 24px 20px; }
  .timeline-content { padding: 16px; }
  .contact-form { padding: 20px 16px; }

  /* FAQ */
  .faq-question { padding: 16px; font-size: 0.88rem; }
  .faq-answer { padding: 0 16px 16px; }

  .form-group input,
  .form-group select,
  .form-group textarea { font-size: 16px; /* evita zoom en iOS */ }
}
