/* ==========================================================================
   NovaChat - Stylesheet Principal (White Mode por Defecto)
   ========================================================================== */

:root {
  /* Paleta White Mode Principal */
  --bg-primary: #ffffff;
  --bg-secondary: #f8fafc;
  --bg-tertiary: #f1f5f9;
  --bg-card: rgba(255, 255, 255, 0.92);
  --bg-card-hover: #ffffff;
  
  /* Textos y Contraste */
  --text-primary: #0f172a;
  --text-secondary: #475569;
  --text-muted: #94a3b8;
  --text-inverse: #ffffff;
  
  /* Colores de Marca y Acentos */
  --accent: #4f46e5;
  --accent-rgb: 79, 70, 229;
  --accent-hover: #4338ca;
  --accent-light: #eef2ff;
  --accent-cyan: #06b6d4;
  --accent-emerald: #10b981;
  --accent-rose: #f43f5e;
  --accent-amber: #f59e0b;
  --accent-gradient: linear-gradient(135deg, #4f46e5 0%, #3b82f6 50%, #06b6d4 100%);
  --accent-gradient-text: linear-gradient(135deg, #3730a3 0%, #4f46e5 40%, #0284c7 100%);
  
  /* Bordes y Sombras */
  --border: #e2e8f0;
  --border-light: #f1f5f9;
  --border-focus: #818cf8;
  --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
  --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.06), 0 2px 4px -2px rgba(0, 0, 0, 0.04);
  --shadow-lg: 0 10px 25px -3px rgba(0, 0, 0, 0.06), 0 4px 6px -4px rgba(0, 0, 0, 0.04);
  --shadow-xl: 0 20px 35px -5px rgba(15, 23, 42, 0.08), 0 8px 10px -6px rgba(15, 23, 42, 0.03);
  --shadow-glow: 0 0 35px -5px rgba(79, 70, 229, 0.25);
  --shadow-mockup: 0 25px 60px -15px rgba(15, 23, 42, 0.18), 0 0 0 1px rgba(0, 0, 0, 0.06);

  /* Espaciados y Radios */
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 18px;
  --radius-xl: 26px;
  --radius-full: 9999px;
  
  --header-height: 76px;
  --container-max: 1240px;
}

/* Reset y Base */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  background-color: var(--bg-primary);
  color: var(--text-primary);
  line-height: 1.6;
  overflow-x: hidden;
  position: relative;
  min-height: 100vh;
}

/* Tipografía */
h1, h2, h3, h4, h5, h6 {
  color: var(--text-primary);
  font-weight: 700;
  line-height: 1.25;
  letter-spacing: -0.025em;
}

h1 { font-size: clamp(2.4rem, 5vw, 3.8rem); font-weight: 800; }
h2 { font-size: clamp(1.8rem, 3.5vw, 2.6rem); }
h3 { font-size: clamp(1.3rem, 2vw, 1.7rem); }
p { color: var(--text-secondary); font-size: 1.05rem; }

a {
  color: var(--accent);
  text-decoration: none;
  transition: all 0.2s ease;
}
a:hover { color: var(--accent-hover); }

img, svg {
  display: block;
  max-width: 100%;
}

button, input, textarea, select {
  font-family: inherit;
  font-size: inherit;
}

/* Utilidades */
.container {
  width: 100%;
  max-width: var(--container-max);
  margin-left: auto;
  margin-right: auto;
  padding-left: 1.5rem;
  padding-right: 1.5rem;
}

.text-gradient {
  background: var(--accent-gradient-text);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  display: inline-block;
}

.section-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.35rem 0.95rem;
  border-radius: var(--radius-full);
  background: var(--accent-light);
  color: var(--accent);
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  margin-bottom: 1rem;
  box-shadow: 0 2px 8px rgba(79, 70, 229, 0.08);
}

.section-header {
  text-align: center;
  max-width: 720px;
  margin: 0 auto 3.5rem auto;
}

.section-header p {
  margin-top: 1rem;
  font-size: 1.15rem;
}

/* ==========================================================================
   Header y Barra de Navegación
   ========================================================================== */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: var(--header-height);
  z-index: 1000;
  background: rgba(255, 255, 255, 0.88);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--border);
  transition: all 0.3s ease;
}

.site-header.scrolled {
  box-shadow: var(--shadow-sm);
  background: rgba(255, 255, 255, 0.96);
}

.nav-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 100%;
}

.brand-logo {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-size: 1.35rem;
  font-weight: 800;
  color: var(--text-primary);
  text-decoration: none;
}

.brand-icon {
  width: 40px;
  height: 40px;
  flex-shrink: 0;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 1.75rem;
  list-style: none;
}

.nav-link {
  font-weight: 500;
  color: var(--text-secondary);
  font-size: 0.95rem;
  position: relative;
  padding: 0.5rem 0;
}

.nav-link:hover, .nav-link.active {
  color: var(--accent);
}

.nav-link.active::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: var(--accent);
  border-radius: var(--radius-full);
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 1rem;
}

/* Botón Web Chat en Navbar */
.btn-nav-web {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.55rem 1.15rem;
  background: var(--accent-light);
  color: var(--accent);
  border: 1px solid rgba(79, 70, 229, 0.2);
  border-radius: var(--radius-full);
  font-weight: 600;
  font-size: 0.9rem;
  transition: all 0.2s ease;
}

.btn-nav-web:hover {
  background: var(--accent);
  color: var(--text-inverse);
  box-shadow: 0 4px 12px rgba(79, 70, 229, 0.25);
}

.btn-nav-web svg {
  width: 17px;
  height: 17px;
}

/* Botón Hamburguesa Móvil */
.mobile-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.5rem;
  color: var(--text-primary);
}

.mobile-toggle svg {
  width: 26px;
  height: 26px;
}

/* ==========================================================================
   Secciones Principales de Contenido
   ========================================================================== */
section {
  padding: 5.5rem 0;
  position: relative;
}

.hero-section {
  padding-top: calc(var(--header-height) + 3.5rem);
  padding-bottom: 6rem;
  background: radial-gradient(circle at 50% 10%, rgba(99, 102, 241, 0.08) 0%, transparent 60%),
              radial-gradient(circle at 90% 40%, rgba(6, 182, 212, 0.05) 0%, transparent 40%);
  overflow: hidden;
}

/* Footer */
.site-footer {
  background: var(--bg-secondary);
  border-top: 1px solid var(--border);
  padding: 4.5rem 0 2.5rem 0;
  margin-top: 4rem;
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr 1.2fr;
  gap: 2.5rem;
  margin-bottom: 3.5rem;
}

.footer-brand p {
  margin-top: 1rem;
  font-size: 0.95rem;
  max-width: 320px;
}

.footer-title {
  font-size: 0.9rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-primary);
  margin-bottom: 1.2rem;
}

.footer-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.footer-list a {
  color: var(--text-secondary);
  font-size: 0.92rem;
}

.footer-list a:hover {
  color: var(--accent);
  transform: translateX(2px);
}

.footer-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 2rem;
  border-top: 1px solid var(--border);
  font-size: 0.88rem;
  color: var(--text-muted);
}

.footer-social {
  display: flex;
  gap: 1rem;
}

.social-icon-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border-radius: var(--radius-full);
  background: var(--bg-primary);
  border: 1px solid var(--border);
  color: var(--text-secondary);
  transition: all 0.2s ease;
}

.social-icon-btn:hover {
  background: var(--accent);
  color: var(--text-inverse);
  border-color: var(--accent);
  transform: translateY(-2px);
}

.social-icon-btn svg {
  width: 18px;
  height: 18px;
}

/* Responsive Breakpoints */
@media (max-width: 992px) {
  .footer-grid {
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
  }
  .footer-brand {
    grid-column: span 2;
  }
}

@media (max-width: 768px) {
  .mobile-toggle {
    display: block;
  }
  
  .nav-links {
    position: fixed;
    top: var(--header-height);
    left: 0;
    right: 0;
    background: var(--bg-primary);
    flex-direction: column;
    padding: 1.5rem;
    gap: 1.25rem;
    border-bottom: 1px solid var(--border);
    box-shadow: var(--shadow-lg);
    transform: translateY(-120%);
    opacity: 0;
    pointer-events: none;
    transition: all 0.3s ease;
  }
  
  .nav-links.open {
    transform: translateY(0);
    opacity: 1;
    pointer-events: auto;
  }

  .nav-actions .btn-nav-web {
    display: none;
  }

  .footer-grid {
    grid-template-columns: 1fr;
  }
  .footer-brand {
    grid-column: span 1;
  }
  
  .footer-bottom {
    flex-direction: column;
    gap: 1.25rem;
    text-align: center;
  }
}
