
:root {
  /* Colores base */
  --color-white: #ffffff;
  --color-bg-soft: #f5f5f7;
  --color-bg-soft-2: #eeeef1;
  --color-gray-100: #e4e4e8;
  --color-gray-300: #b9b9c3;
  --color-gray-500: #74747f;
  --color-gray-700: #45454f;
  --color-dark: #1c1b22;
  --color-dark-2: #121116;

  /* Morado (acento) */
  --purple-100: #ece7fd;
  --purple-300: #b6a3f7;
  --purple-500: #7c5cfa;
  --purple-600: #6a45f0;
  --purple-700: #5734d1;
  --purple-900: #2a1a63;

  /* Tipografía */
  --font-display: 'Space Grotesk', 'Inter', sans-serif;
  --font-body: 'Inter', sans-serif;

  /* Espaciado */
  --section-pad: 7rem;
  --container-w: 1180px;

  /* Sombras y bordes */
  --shadow-soft: 0 20px 50px -25px rgba(28, 27, 34, 0.35);
  --shadow-card: 0 12px 30px -18px rgba(28, 27, 34, 0.28);
  --radius-md: 14px;
  --radius-lg: 22px;

  --ease: cubic-bezier(0.16, 1, 0.3, 1);
}

/* ============ RESET ============ */
* { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: 0.001ms !important; transition-duration: 0.001ms !important; }
}

body {
  font-family: var(--font-body);
  color: var(--color-dark);
  background: var(--color-white);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img { max-width: 100%; display: block; }

a { color: inherit; text-decoration: none; }

ul { list-style: none; }

button { font-family: inherit; cursor: pointer; border: none; background: none; }

input, select, textarea { font-family: inherit; font-size: 1rem; }

:focus-visible {
  outline: 2px solid var(--purple-500);
  outline-offset: 3px;
}

.container {
  max-width: var(--container-w);
  margin: 0 auto;
  padding: 0 1.75rem;
}

h1, h2, h3 { font-family: var(--font-display); font-weight: 600; line-height: 1.15; letter-spacing: -0.01em; }

/* ============ BOTONES ============ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.55rem;
  padding: 0.95rem 1.9rem;
  border-radius: 999px;
  font-weight: 600;
  font-size: 0.97rem;
  transition: transform 0.3s var(--ease), box-shadow 0.3s var(--ease), background-color 0.3s var(--ease), color 0.3s var(--ease);
  white-space: nowrap;
}

.btn-primary {
  background: var(--purple-500);
  color: var(--color-white);
  box-shadow: 0 14px 30px -12px rgba(124, 92, 250, 0.55);
}

.btn-primary:hover {
  background: var(--purple-600);
  transform: translateY(-2px);
  box-shadow: 0 18px 34px -12px rgba(124, 92, 250, 0.65);
}

.btn-ghost {
  background: transparent;
  color: var(--color-dark);
  border: 1.5px solid var(--color-gray-100);
}

.btn-ghost:hover {
  border-color: var(--purple-500);
  color: var(--purple-700);
}

.link-arrow {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  margin-top: 1.75rem;
  font-weight: 600;
  color: var(--purple-600);
  position: relative;
  padding-bottom: 2px;
}

.link-arrow::after {
  content: "";
  position: absolute;
  left: 0; bottom: 0;
  width: 100%; height: 1.5px;
  background: currentColor;
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.35s var(--ease);
}

.link-arrow:hover::after { transform: scaleX(1); }

/* ============ HEADER ============ */
.site-header {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  background: rgba(255, 255, 255, 0.82);
  backdrop-filter: blur(14px) saturate(160%);
  -webkit-backdrop-filter: blur(14px) saturate(160%);
  border-bottom: 1px solid rgba(28, 27, 34, 0.06);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 76px;
}

.logo { display: flex; align-items: center; }
.logo-img { height: 34px; width: auto; }
.logo-fallback {
  font-family: var(--font-display);
  font-size: 1.3rem;
  font-weight: 700;
  color: var(--color-dark);
}
.logo-fallback em { font-style: normal; color: var(--purple-500); }

.main-nav { display: flex; align-items: center; gap: 2.4rem; }

.nav-link {
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--color-gray-700);
  position: relative;
  padding: 0.3rem 0;
  transition: color 0.25s var(--ease);
}

.nav-link:hover { color: var(--color-dark); }

.nav-link::after {
  content: "";
  position: absolute;
  left: 0; bottom: -2px;
  width: 100%; height: 2px;
  background: var(--purple-500);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.3s var(--ease);
}

.nav-link:hover::after { transform: scaleX(1); }

.nav-link--cta {
  background: var(--color-dark);
  color: var(--color-white);
  padding: 0.6rem 1.3rem;
  border-radius: 999px;
}

.nav-link--cta::after { display: none; }
.nav-link--cta:hover { background: var(--purple-500); color: var(--color-white); }

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  width: 30px;
  z-index: 101;
}

.nav-toggle span {
  height: 2px;
  width: 100%;
  background: var(--color-dark);
  border-radius: 2px;
  transition: transform 0.3s var(--ease), opacity 0.3s var(--ease);
}

.nav-toggle.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle.open span:nth-child(2) { opacity: 0; }
.nav-toggle.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ============ HERO ============ */
.hero {
  padding: calc(76px + 6rem) 0 6rem;
  background:
    radial-gradient(60% 55% at 82% 18%, rgba(124, 92, 250, 0.12), transparent 70%),
    var(--color-white);
  position: relative;
}

.hero-inner {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 3rem;
  align-items: center;
}

.hero-kicker {
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--purple-600);
  margin-bottom: 1.1rem;
}

.hero-title {
  font-size: clamp(2.4rem, 4.6vw, 3.6rem);
  color: var(--color-dark);
  margin-bottom: 1.4rem;
}

.hero-sub {
  font-size: 1.1rem;
  color: var(--color-gray-700);
  max-width: 46ch;
  margin-bottom: 2.2rem;
}

.hero-actions { display: flex; gap: 1rem; flex-wrap: wrap; margin-bottom: 3rem; }

.hero-stats {
  display: flex;
  gap: 2.2rem;
  flex-wrap: wrap;
  padding-top: 2rem;
  border-top: 1px solid var(--color-gray-100);
}

.hero-stat { display: flex; flex-direction: column; gap: 0.2rem; }

.hero-stat-num {
  font-family: var(--font-display);
  font-size: 1.3rem;
  font-weight: 700;
  color: var(--color-dark);
}

.hero-stat-label { font-size: 0.85rem; color: var(--color-gray-500); }

/* Visual del hero: composición abstracta, no una foto de stock */
.hero-visual {
  position: relative;
  height: 420px;
}

.hero-blob {
  position: absolute;
  inset: 0;
  background: linear-gradient(145deg, var(--purple-300), var(--purple-600));
  border-radius: 38% 62% 55% 45% / 45% 40% 60% 55%;
  opacity: 0.9;
  animation: blobMove 12s var(--ease) infinite alternate;
}

@keyframes blobMove {
  0% { border-radius: 38% 62% 55% 45% / 45% 40% 60% 55%; transform: rotate(0deg) scale(1); }
  100% { border-radius: 55% 45% 40% 60% / 55% 60% 40% 45%; transform: rotate(8deg) scale(1.04); }
}

.hero-card {
  position: absolute;
  width: 230px;
  background: var(--color-white);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-soft);
  padding: 1.2rem;
}

.hero-card--1 { top: 8%; left: 2%; animation: floatY 6s ease-in-out infinite; }
.hero-card--2 { bottom: 10%; right: 0%; width: 200px; animation: floatY 7s ease-in-out infinite 0.6s; }

@keyframes floatY {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-12px); }
}

.hero-card-dot {
  width: 34px; height: 34px;
  border-radius: 50%;
  background: var(--purple-100);
  margin-bottom: 0.9rem;
  position: relative;
}
.hero-card-dot::after {
  content: "";
  position: absolute; inset: 9px;
  background: var(--purple-500);
  border-radius: 50%;
}

.hero-card-line { height: 8px; border-radius: 5px; background: var(--color-bg-soft-2); margin-top: 0.6rem; }
.hero-card-line--w70 { width: 70%; }
.hero-card-line--w40 { width: 40%; }
.hero-card-line--w60 { width: 60%; background: var(--purple-100); }
.hero-card-line--w90 { width: 90%; }
.hero-card-line--w50 { width: 50%; }

/* ============ SECCIONES GENERALES ============ */
section:not(.hero) { padding: var(--section-pad) 0; }

.section-head { max-width: 640px; margin: 0 auto 3.5rem; text-align: center; }

.section-title {
  font-size: clamp(1.9rem, 3.2vw, 2.5rem);
  color: var(--color-dark);
  margin-bottom: 0.9rem;
}

.section-lead { font-size: 1.08rem; color: var(--color-gray-500); }

/* ============ QUIÉNES SOMOS ============ */
.about { background: var(--color-bg-soft); }

.about-inner {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: 3.5rem;
  align-items: center;
}

.about-image {
  border-radius: var(--radius-lg);
  overflow: hidden;
  aspect-ratio: 4 / 5;
  box-shadow: var(--shadow-card);
  background: linear-gradient(160deg, var(--color-dark), var(--purple-900));
}

.about-img { width: 100%; height: 100%; object-fit: cover; }

.about-image--placeholder .about-img { display: none; }
.about-image--placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--purple-300);
  font-family: var(--font-display);
  font-size: 1rem;
  text-align: center;
  padding: 2rem;
}
.about-image--placeholder::before {
  content: "Espacio para imagen\A(reemplazar quienes-somos.jpg)";
  white-space: pre-wrap;
}

.about-copy .section-title { text-align: left; }

.about-copy p { color: var(--color-gray-700); margin-bottom: 1.1rem; max-width: 52ch; }

.about-copy .section-lead { text-align: left; color: var(--color-dark); font-weight: 500; margin-bottom: 1.3rem; }

/* ============ QUÉ OFRECEMOS ============ */
.services-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.4rem;
}

.service-card {
  background: var(--color-white);
  border: 1px solid var(--color-gray-100);
  border-radius: var(--radius-md);
  padding: 2rem 1.7rem;
  transition: border-color 0.3s var(--ease), transform 0.3s var(--ease), box-shadow 0.3s var(--ease);
}

.service-card:hover {
  border-color: var(--purple-500);
  transform: translateY(-4px);
  box-shadow: var(--shadow-card);
}

.service-icon {
  width: 46px; height: 46px;
  display: flex; align-items: center; justify-content: center;
  border-radius: 12px;
  background: var(--purple-100);
  color: var(--purple-600);
  margin-bottom: 1.2rem;
  transition: background-color 0.3s var(--ease), color 0.3s var(--ease);
}

.service-icon svg { width: 22px; height: 22px; }

.service-card:hover .service-icon { background: var(--purple-500); color: var(--color-white); }

.service-card h3 { font-size: 1.08rem; margin-bottom: 0.5rem; color: var(--color-dark); }
.service-card p { font-size: 0.94rem; color: var(--color-gray-500); }

/* Bloque de urgencia / captación */
.urgency-block {
  margin-top: 4.5rem;
  background: linear-gradient(120deg, var(--color-dark) 0%, var(--purple-900) 100%);
  border-radius: var(--radius-lg);
  padding: 3.2rem;
  color: var(--color-white);
}

.urgency-content { max-width: 680px; }

.urgency-content h3 {
  font-size: clamp(1.4rem, 2.4vw, 1.8rem);
  margin-bottom: 1.1rem;
  font-weight: 600;
}

.urgency-content p { color: var(--color-gray-300); margin-bottom: 1.3rem; }

.urgency-list { margin-bottom: 1.9rem; }

.urgency-list li {
  position: relative;
  padding-left: 1.6rem;
  margin-bottom: 0.65rem;
  color: var(--color-gray-100);
}

.urgency-list li::before {
  content: "";
  position: absolute;
  left: 0; top: 0.5em;
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--purple-300);
}

/* ============ COTIZACIÓN ============ */
.quote { background: var(--color-bg-soft); }

.quote-form {
  max-width: 780px;
  margin: 0 auto;
  background: var(--color-white);
  border-radius: var(--radius-lg);
  padding: 2.6rem;
  box-shadow: var(--shadow-card);
}

.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.4rem 1.3rem;
  margin-bottom: 2rem;
  min-width: 0;
}

.form-field textarea { resize: vertical; }

.form-field { display: flex; flex-direction: column; gap: 0.45rem; min-width: 0; }
.form-field--full { grid-column: 1 / -1; }

.form-field label { font-size: 0.9rem; font-weight: 600; color: var(--color-dark); }

.req { color: var(--purple-500); }

.form-field input,
.form-field select,
.form-field textarea {
  width: 100%;
  min-width: 0;
  padding: 0.8rem 1rem;
  border: 1.5px solid var(--color-gray-100);
  border-radius: 10px;
  background: var(--color-bg-soft);
  color: var(--color-dark);
  transition: border-color 0.25s var(--ease), background-color 0.25s var(--ease);
}

.form-field input:focus,
.form-field select:focus,
.form-field textarea:focus {
  border-color: var(--purple-500);
  background: var(--color-white);
  outline: none;
}

.form-field input.invalid,
.form-field select.invalid {
  border-color: #d9534f;
}

.field-error {
  font-size: 0.8rem;
  color: #c0392b;
  min-height: 1em;
}

.choice-label { font-size: 0.9rem; font-weight: 600; color: var(--color-dark); }

.choice-group { display: flex; gap: 0.6rem; }

.choice-btn {
  flex: 1;
  padding: 0.75rem 0;
  border: 1.5px solid var(--color-gray-100);
  border-radius: 10px;
  background: var(--color-bg-soft);
  color: var(--color-gray-700);
  font-weight: 600;
  font-size: 0.92rem;
  transition: all 0.25s var(--ease);
}

.choice-btn:hover { border-color: var(--purple-300); }

.choice-btn.selected {
  background: var(--purple-500);
  border-color: var(--purple-500);
  color: var(--color-white);
}

.btn-submit {
  width: 100%;
  padding: 1.05rem;
  font-size: 1.02rem;
}

.wa-icon { width: 19px; height: 19px; }

.form-note {
  text-align: center;
  margin-top: 1rem;
  font-size: 0.9rem;
  min-height: 1.2em;
}

.form-note.error { color: #c0392b; }
.form-note.success { color: var(--purple-700); }

/* ============ FOOTER ============ */
.site-footer {
  background: var(--color-dark-2);
  color: var(--color-gray-300);
  padding-top: 4rem;
}

.footer-inner {
  display: flex;
  justify-content: space-between;
  gap: 3rem;
  flex-wrap: wrap;
  padding-bottom: 3rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.footer-brand { max-width: 320px; }

.footer-logo-img { height: 30px; margin-bottom: 1rem; }
.footer-logo-fallback {
  font-family: var(--font-display);
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--color-white);
  margin-bottom: 1rem;
}
.footer-logo-fallback em { font-style: normal; color: var(--purple-300); }

.footer-brand p { font-size: 0.9rem; color: var(--color-gray-500); }

.footer-info { display: flex; flex-direction: column; gap: 0.5rem; font-size: 0.92rem; }

.footer-bottom {
  padding: 1.6rem 1.75rem;
  font-size: 0.82rem;
  color: var(--color-gray-500);
  text-align: center;
}

/* ============ RESPONSIVE ============ */
@media (max-width: 980px) {
  .hero-inner { grid-template-columns: 1fr; }
  .hero-visual { height: 300px; margin-top: 1rem; order: -1; }
  .about-inner { grid-template-columns: 1fr; }
  .about-image { aspect-ratio: 16/10; }
  .about-copy .section-title, .about-copy .section-lead { text-align: left; }
  .services-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 720px) {
  :root { --section-pad: 4.5rem; }

  .main-nav {
    position: fixed;
    top: 76px; left: 0; right: 0; bottom: 0;
    background: var(--color-white);
    flex-direction: column;
    justify-content: flex-start;
    align-items: flex-start;
    gap: 0.5rem;
    padding: 2rem 1.75rem;
    transform: translateX(100%);
    transition: transform 0.35s var(--ease);
  }

  .main-nav.open { transform: translateX(0); }

  .main-nav .nav-link { width: 100%; padding: 0.9rem 0; border-bottom: 1px solid var(--color-gray-100); }
  .nav-link--cta { text-align: center; margin-top: 0.5rem; }

  .nav-toggle { display: flex; }

  .services-grid { grid-template-columns: 1fr; }

  .form-grid { grid-template-columns: 1fr; }

  .urgency-block { padding: 2.2rem 1.6rem; }

  .quote-form { padding: 1.8rem 1.3rem; }

  .footer-inner { flex-direction: column; gap: 2rem; }
}

@media (max-width: 420px) {
  .hero-title { font-size: 2rem; }
  .hero-stats { gap: 1.4rem; }
}
