/* === VARIABLES Y PALETAS === */
:root {
  /* TEMA CLARO (Base) */
  --bg-body: #f8fafc;
  --bg-card: #ffffff;
  --text-main: #0f172a;
  --text-secondary: #64748b;
  --primary: #2563eb;
  --accent: #f97316; 
  --shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
  --border: #e2e8f0;
}

/* TEMA OSCURO (Sobrescribe el claro) */
body.dark-mode {
  --bg-body: #0f172a;
  --bg-card: #1e293b;
  --text-main: #f1f5f9;
  --text-secondary: #94a3b8;
  --primary: #60a5fa; 
  --accent: #f97316;
  --shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.5);
  --border: #334155;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

body {
  font-family: 'Segoe UI', system-ui, sans-serif;
  line-height: 1.6;
  color: var(--text-main);
  background-color: var(--bg-body);
  transition: background-color 0.3s ease;
}

a { text-decoration: none; color: inherit; }
ul { list-style: none; }

/* === HEADER & NAV === */
header {
  background: var(--bg-card);
  box-shadow: var(--shadow);
  padding: 1rem 5%;
  position: sticky;
  top: 0;
  z-index: 1000;
  border-bottom: 1px solid var(--border);
}

.nav-container {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

/* LOGO PNG SIN FONDO */
.logo-link {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  font-size: 1.6rem;
  font-weight: 800;
}

.logo-img {
  height: 50px; /* Ajusta según tu logo */
  width: auto;
  object-fit: contain;
  /* ELIMINADO: background-color white para que sea transparente */
}

.brand-text-wrapper { display: flex; align-items: baseline; }
.brand-text { font-weight: 700; color: var(--text-main); }
.brand-text-accent { color: var(--accent); font-weight: 900; }

/* MENU GRANDE */
nav ul { display: flex; gap: 2rem; }
nav a {
  color: var(--text-main);
  font-weight: 600;
  font-size: 1.15rem; /* Un poco más grande */
  padding: 0.5rem 0;
  transition: color 0.2s;
}
nav a:hover { color: var(--primary); }

/* BOTÓN TEMA */
.theme-toggle-btn {
  background: transparent;
  border: none;
  font-size: 1.3rem;
  color: var(--text-main);
  cursor: pointer;
  padding: 0.5rem;
  border-radius: 50%;
  transition: background 0.3s;
  margin-right: 1rem;
}
.theme-toggle-btn:hover { background-color: var(--border); }

/* CTA BUTTON */
.cta-btn {
  background: var(--primary);
  color: white;
  padding: 0.9rem 2rem;
  border-radius: 50px;
  font-weight: 600;
  font-size: 1.1rem;
  transition: all 0.3s;
  box-shadow: var(--shadow);
}
.cta-btn:hover {
  background: var(--text-main);
  color: var(--primary);
  transform: translateY(-2px);
  box-shadow: 0 8px 15px rgba(0,0,0,0.3);
}

/* MOBILE MENU */
.mobile-menu-btn { display: none; font-size: 1.5rem; cursor: pointer; color: var(--text-main); }

/* === HERO SECTION (SIEMPRE CENTRADO) === */
.hero {
  background: linear-gradient(135deg, #e0f2fe 0%, #f0f9ff 100%);
  padding: 6rem 5% 5rem;
  text-align: center;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  min-height: 80vh;
}

body.dark-mode .hero {
  background: linear-gradient(135deg, #0f172a 0%, #1e293b 100%);
}

.hero-content { max-width: 800px; margin: 0 auto; text-align: center; z-index: 2; }

.hero h1 {
  font-size: 3rem;
  margin-bottom: 1.5rem;
  color: var(--text-main);
  line-height: 1.2;
  font-weight: 800;
}

.hero p {
  font-size: 1.25rem;
  color: var(--text-secondary);
  max-width: 700px;
  margin: 0 auto 2.5rem;
}

.hero-btns { display: flex; gap: 1rem; justify-content: center; flex-wrap: wrap; }

.hero-btn {
  padding: 1rem 2.5rem;
  border-radius: 50px;
  font-weight: 600;
  transition: all 0.3s;
  font-size: 1rem;
}

.btn-primary { background: var(--primary); color: white; box-shadow: var(--shadow); }
.btn-primary:hover { background: var(--text-main); color: var(--primary); }

.btn-secondary { background: white; color: var(--primary); border: 2px solid var(--primary); box-shadow: var(--shadow); }
.btn-secondary:hover { background: #f8fafc; border-color: var(--primary-dark); }

body.dark-mode .btn-secondary { background: var(--bg-body); color: var(--primary); border-color: var(--primary); }
body.dark-mode .btn-secondary:hover { background: var(--border); color: white; }

/* === SECCIONES GENERALES === */
.section { padding: 6rem 5%; max-width: 1200px; margin: 0 auto; }
.bg-light { background-color: var(--bg-body); }
.section-title { text-align: center; margin-bottom: 4rem; }
.section-title h2 { font-size: 2.5rem; margin-bottom: 1rem; font-weight: 800; }

.features { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 2.5rem; }

.feature-card {
  background: var(--bg-card);
  padding: 2.5rem;
  border-radius: 1rem;
  box-shadow: var(--shadow);
  transition: transform 0.3s ease;
  border: 1px solid var(--border);
}
.feature-card:hover { transform: translateY(-5px); }

.feature-icon {
  font-size: 2.5rem;
  color: var(--primary);
  margin-bottom: 1.5rem;
  background: rgba(37, 99, 235, 0.1);
  width: 60px; height: 60px;
  line-height: 60px;
  text-align: center;
  border-radius: 50%;
}

/* BENEFITS */
.features-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 2rem; max-width: 1000px; margin: 0 auto; }
.benefit-item { text-align: center; padding: 2rem; }
.icon-circle { width: 80px; height: 80px; background: var(--bg-body); border-radius: 50%; display: flex; align-items: center; justify-content: center; margin: 0 auto 1.5rem; font-size: 2rem; color: var(--primary); }
.benefit-item h3 { margin-bottom: 0.75rem; font-size: 1.25rem; }

/* CONTACTO */
.contact-section { padding: 6rem 5%; background-color: var(--bg-body); }
.contact-container {
  max-width: 900px; margin: 0 auto; background: var(--bg-card);
  padding: 3rem; border-radius: 1rem; box-shadow: var(--shadow);
  display: grid; grid-template-columns: 1fr 1fr; gap: 3rem; align-items: center;
}
.contact-info h2 { font-size: 2.25rem; margin-bottom: 1.5rem; }
.contact-list li { margin-bottom: 1rem; color: var(--text-secondary); display: flex; align-items: center; gap: 10px; }
.contact-list i { color: var(--primary); width: 20px; text-align: center; }

.form-group { text-align: left; margin-bottom: 1.25rem; }
.form-group label { display: block; margin-bottom: 0.5rem; font-weight: 600; }
.form-group input, .form-group textarea {
  width: 100%; padding: 0.8rem; border-radius: 0.5rem;
  border: 1px solid var(--border); background: var(--bg-body); color: var(--text-main);
  transition: border-color 0.3s;
}
.form-group input:focus, .form-group textarea:focus { border-color: var(--primary); outline: none; }

.btn-submit { background: var(--primary); color: white; padding: 1rem; border: none; border-radius: 0.5rem; font-size: 1.1rem; font-weight: 600; cursor: pointer; width: 100%; }
.btn-submit:hover { background: var(--text-main); color: var(--primary); }

/* FOOTER */
footer { background: var(--bg-body); color: var(--text-secondary); padding: 3rem 5% 1.5rem; }
.footer-content { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 2.5rem; max-width: 1200px; margin: 0 auto 2rem; }

.logo-footer-link { display: flex; align-items: center; gap: 0.8rem; margin-bottom: 1rem; }
.footer-logo-img { height: 50px; width: auto; object-fit: contain; }

.footer-col h3 { color: var(--text-main); margin-bottom: 1.25rem; font-size: 1.1rem; text-transform: uppercase; letter-spacing: 1px; border-bottom: 1px solid var(--border); padding-bottom: 0.5rem; display: inline-block; }
.footer-col ul li { margin-bottom: 0.5rem; }
.footer-col a { color: var(--text-secondary); transition: color 0.2s; }
.footer-col a:hover { color: var(--primary); }
.copyright { text-align: center; border-top: 1px solid var(--border); padding-top: 2rem; font-size: 0.9rem; }

/* RESPONSIVE */
@media (max-width: 768px) {
  .nav-container { flex-wrap: wrap; align-items: center; }
  nav ul { display: none; width: 100%; flex-direction: column; text-align: center; background: var(--bg-card); padding: 1rem; border-radius: 8px; margin-top: 1rem; border: 1px solid var(--border); }
  nav ul.active { display: flex; }
  .mobile-menu-btn { display: block; margin-left: 10px; }
  .logo-link { flex-direction: column; font-size: 1.3rem; }
  .brand-text-wrapper { flex-direction: column; align-items: center; margin-top: 5px; }
  
  .hero { padding: 4rem 5% 4rem; }
  .hero h1 { font-size: 2.25rem; }
  .contact-container { grid-template-columns: 1fr; }
  .footer-content { grid-template-columns: 1fr; text-align: center; }
  .theme-toggle-btn { margin: 0; margin-left: auto; }
}