/* Reset y configuración base */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  overflow-x: hidden;
  width: 100%;
}

body {
  font-family: 'Poppins', sans-serif;
  overflow-x: hidden;
  width: 100%;
  margin: 0;
  padding: 0;
  min-width: 320px;
  background-color: #0f172a;
  color: #e5e7eb;
  min-height: 100vh;
}

.gradient-bg {
  background: #0f172a;
  background-image: 
    radial-gradient(circle at top left, rgba(84, 134, 204, 0.2), transparent 40%),
    radial-gradient(circle at bottom right, rgba(0, 217, 184, 0.2), transparent 40%);
}

/* Asegurar que todos los contenedores respeten el viewport */
main, section, header, footer {
  overflow-x: hidden;
  max-width: 100vw;
  width: 100%;
}

.container {
  overflow-x: hidden;
  max-width: 100%;
  margin-left: auto;
  margin-right: auto;
  padding-left: 1rem;
  padding-right: 1rem;
}

@media (min-width: 640px) {
  .container {
    padding-left: 1.5rem;
    padding-right: 1.5rem;
  }
}

/* Prevenir overflow en mobile */
img, svg, video {
  max-width: 100%;
  height: auto;
}

/* Word breaking para evitar overflow de texto */
h1, h2, h3, h4, h5, h6, p, span, a {
  word-wrap: break-word;
  overflow-wrap: break-word;
}

/* Header */
header {
  background-color: rgba(15, 23, 42, 0.8);
  backdrop-filter: blur(12px);
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 50;
  width: 100%;
}

.header-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 1rem;
  padding-bottom: 1rem;
  max-width: 100%;
}

.logo {
  height: 2.5rem;
  width: auto;
}

@media (min-width: 768px) {
  .logo {
    height: 3rem;
  }
}

.nav-desktop {
  display: none;
  gap: 2rem;
}

@media (min-width: 768px) {
  .nav-desktop {
    display: flex;
  }
}

.nav-link {
  color: #d1d5db;
  text-decoration: none;
  transition: color 0.3s;
}

.nav-link:hover {
  color: #00D9B8;
}

.menu-button {
  background: none;
  border: none;
  cursor: pointer;
  padding: 0;
}

.menu-icon {
  width: 1.5rem;
  height: 1.5rem;
  color: white;
}

.mobile-menu-toggle {
  display: block;
}

@media (min-width: 768px) {
  .mobile-menu-toggle {
    display: none;
  }
}

.mobile-menu {
  background-color: #1e293b;
}

.mobile-menu.hidden {
  display: none;
}

@media (min-width: 768px) {
  .mobile-menu {
    display: none;
  }
}

.mobile-nav {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
  padding: 1rem 0;
}

/* Main */
main {
  width: 100%;
  overflow-x: hidden;
}

/* Hero Section */
.hero-section {
  padding-top: 8rem;
  padding-bottom: 5rem;
}

@media (min-width: 768px) {
  .hero-section {
    padding-top: 12rem;
    padding-bottom: 8rem;
  }
}

.hero-container {
  text-align: center;
}

.hero-title {
  font-size: 2.25rem;
  font-weight: 700;
  color: white;
  margin-bottom: 1rem;
  line-height: 1.2;
}

@media (min-width: 768px) {
  .hero-title {
    font-size: 3.75rem;
  }
}

.hero-highlight {
  color: #00D9B8;
}

.hero-subtitle {
  font-size: 1.125rem;
  color: #9ca3af;
  max-width: 48rem;
  margin-left: auto;
  margin-right: auto;
  margin-bottom: 2rem;
}

@media (min-width: 768px) {
  .hero-subtitle {
    font-size: 1.25rem;
  }
}

.hero-buttons {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 1rem;
}

@media (min-width: 640px) {
  .hero-buttons {
    flex-direction: row;
  }
}

.btn {
  width: 100%;
  font-weight: 600;
  padding: 0.75rem 2rem;
  border-radius: 9999px;
  transition: all 0.3s;
  text-align: center;
  text-decoration: none;
  display: inline-block;
}

@media (min-width: 640px) {
  .btn {
    width: auto;
  }
}

.btn-primary {
  background-color: #00D9B8;
  color: #0f172a;
}

.btn-primary:hover {
  opacity: 0.8;
}

.btn-secondary {
  background-color: transparent;
  border: 2px solid #5486CC;
  color: white;
}

.btn-secondary:hover {
  background-color: #5486CC;
  color: white;
}

/* Services Section */
.services-section {
  padding: 5rem 0;
}

.section-header {
  text-align: center;
  margin-bottom: 3rem;
}

.section-title {
  font-size: 1.875rem;
  font-weight: 700;
  color: white;
}

@media (min-width: 768px) {
  .section-title {
    font-size: 2.25rem;
  }
}

.section-divider {
  width: 6rem;
  height: 0.25rem;
  margin: 1rem auto 0;
}

.divider-teal {
  background-color: #00D9B8;
}

.divider-blue {
  background-color: #5486CC;
}

.services-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2rem;
}

@media (min-width: 768px) {
  .services-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 1024px) {
  .services-grid {
    grid-template-columns: repeat(4, 1fr);
  }
}

.service-card {
  background-color: rgba(30, 41, 59, 0.5);
  padding: 1.5rem;
  border-radius: 0.5rem;
  border: 1px solid #334155;
  transition: all 0.3s;
}

.service-card:hover {
  border-color: #00D9B8;
  transform: translateY(-0.25rem);
}

.service-icon {
  color: #00D9B8;
  margin-bottom: 1rem;
}

.service-title {
  font-size: 1.25rem;
  font-weight: 600;
  color: white;
  margin-bottom: 0.5rem;
}

.service-description {
  color: #9ca3af;
}

/* About Section */
.about-section {
  padding: 5rem 0;
  background-color: #0f172a;
}

.about-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3rem;
}

@media (min-width: 768px) {
  .about-content {
    flex-direction: row;
  }
}

.about-text {
  width: 100%;
}

@media (min-width: 768px) {
  .about-text {
    width: 50%;
  }
}

.about-title {
  font-size: 1.875rem;
  font-weight: 700;
  color: white;
  margin-bottom: 1rem;
}

@media (min-width: 768px) {
  .about-title {
    font-size: 2.25rem;
  }
}

.text-blue {
  color: #5486CC;
}

.text-teal {
  color: #00D9B8;
}

.about-divider {
  width: 6rem;
  height: 0.25rem;
  margin-top: 0.5rem;
  margin-bottom: 1.5rem;
}

.about-paragraph {
  color: #9ca3af;
  margin-bottom: 1rem;
}

.about-image-wrapper {
  width: 100%;
  display: flex;
  justify-content: center;
}

@media (min-width: 768px) {
  .about-image-wrapper {
    width: 50%;
  }
}

.about-image {
  border-radius: 0.5rem;
  box-shadow: 0 25px 50px -12px rgba(15, 23, 42, 0.5);
  width: 100%;
  max-width: 28rem;
  height: auto;
  object-fit: cover;
}

/* Contact Section */
.contact-section {
  padding: 5rem 0;
}

.contact-header {
  text-align: center;
  margin-bottom: 3rem;
}

.contact-subtitle {
  color: #9ca3af;
  margin-top: 0.5rem;
}

.contact-container {
  max-width: 32rem;
  margin-left: auto;
  margin-right: auto;
  width: 100%;
}

.contact-links {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1.5rem;
}

@media (min-width: 768px) {
  .contact-links {
    flex-direction: row;
    gap: 3rem;
  }
}

.contact-link {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-size: 1rem;
  color: #d1d5db;
  text-decoration: none;
  transition: color 0.3s;
  max-width: 100%;
}

@media (min-width: 640px) {
  .contact-link {
    font-size: 1.125rem;
  }
}

.contact-link:hover {
  color: #00D9B8;
}

.contact-icon {
  height: 1.5rem;
  width: 1.5rem;
  flex-shrink: 0;
}

@media (min-width: 640px) {
  .contact-icon {
    height: 2rem;
    width: 2rem;
  }
}

.contact-email {
  word-break: break-all;
}

/* Footer */
footer {
  background-color: #0f172a;
  border-top: 1px solid #1e293b;
  padding: 1.5rem 0;
}

.footer-container {
  text-align: center;
  color: #6b7280;
}

/* Utilidades */
.hidden {
  display: none;
}

.text-center {
  text-align: center;
}
