/*
 * Estilos principales para PlanetaWeb.cl
 * Este archivo define la paleta de colores, tipografías, componentes y
 * disposiciones responsivas del sitio. Inspirado en la maqueta original
 * proporcionada por el cliente, mantiene un diseño limpio, moderno y
 * tecnológico con predominancia de tonos violetas y azules.
 */

/* Variables globales */
:root {
  --primary-color: #6e5bef;
  --secondary-color: #5c46d4;
  --accent-color: #4a38c5;
  --bg-color: #f8f8fb;
  --text-color: #2f2f38;
  --heading-font: 'Playfair Display', serif;
  --body-font: 'Inter', sans-serif;
}

/* Reset básico */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--body-font);
  color: var(--text-color);
  background-color: var(--bg-color);
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}

a {
  color: inherit;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

.container {
  width: 90%;
  max-width: 1200px;
  margin: 0 auto;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--heading-font);
  font-weight: 600;
  color: var(--secondary-color);
}

section {
  padding: 4rem 0;
}

/* Botones */
.btn {
  display: inline-block;
  padding: 0.75rem 1.6rem;
  border-radius: 8px;
  font-weight: 600;
  text-decoration: none;
  transition: transform 0.3s ease, background-color 0.3s ease;
  cursor: pointer;
}
.btn:hover {
  transform: translateY(-3px);
}
.primary-btn {
  background: var(--secondary-color);
  color: #fff;
}
.primary-btn:hover {
  background: var(--accent-color);
}
.secondary-btn {
  background: transparent;
  border: 2px solid var(--secondary-color);
  color: var(--secondary-color);
}
.secondary-btn:hover {
  background: var(--secondary-color);
  color: #fff;
}

/* WhatsApp floating button */
.whatsapp-btn {
  position: fixed;
  bottom: 20px;
  right: 20px;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: #25d366;
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
  z-index: 1000;
  transition: transform 0.3s ease;
}
.whatsapp-btn:hover {
  transform: scale(1.1);
}

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 999;
  background: #fff;
  border-bottom: 1px solid #eee;
}
.header-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 0;
}
.logo span {
  /* Utilizamos la misma tipografía que el resto de elementos para mantener consistencia */
  font-family: var(--body-font);
  font-size: 1.4rem;
  letter-spacing: 1px;
  color: var(--secondary-color);
  font-weight: 700;
}
.main-nav ul {
  list-style: none;
  display: flex;
  gap: 1.5rem;
}
.main-nav a {
  font-family: var(--body-font);
  font-size: 1rem;
  color: var(--text-color);
  text-decoration: none;
  transition: color 0.3s ease;
}
.main-nav a:hover {
  color: var(--secondary-color);
}
.header-cta {
  margin-left: 1rem;
}
/* Mobile nav toggle */
.menu-toggle {
  display: none;
  background: none;
  border: none;
  font-size: 1.5rem;
  color: var(--secondary-color);
  cursor: pointer;
}
.mobile-cta {
  display: none;
}

/* Hero */
.hero {
  position: relative;
  overflow: hidden;
  background: var(--bg-color);
}
.hero-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 2rem;
  padding-top: 3rem;
}
.hero-content {
  max-width: 600px;
}
.hero-content h1 {
  font-size: 2.75rem;
  line-height: 1.2;
  margin-bottom: 1rem;
}
.hero-content p {
  margin-bottom: 2rem;
  color: #555;
  max-width: 550px;
}
.hero-graphic {
  flex: 1 1 400px;
  display: flex;
  justify-content: center;
  align-items: center;
}
.hero-graphic img {
  width: 100%;
  height: auto;
  max-width: 500px;
  filter: brightness(1) saturate(1.2);
}

/* Beneficios */
.beneficios {
  background: #fff;
}
.beneficios-container h2 {
  text-align: center;
  margin-bottom: 2rem;
}
.beneficios-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 2rem;
}
.beneficio-item {
  background: var(--bg-color);
  border-radius: 12px;
  padding: 2rem 1.5rem;
  text-align: center;
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.05);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.beneficio-item:hover {
  transform: translateY(-6px);
  box-shadow: 0 15px 25px rgba(0, 0, 0, 0.1);
}
.beneficio-item i {
  font-size: 2rem;
  color: var(--secondary-color);
  margin-bottom: 1rem;
}
.beneficio-item h3 {
  font-size: 1.25rem;
  margin-bottom: 0.5rem;
}
.beneficio-item p {
  font-size: 0.95rem;
  color: #555;
}

/* Planes */
.planes {
  background: var(--bg-color);
}
.planes-container h2 {
  text-align: center;
  margin-bottom: 1rem;
}
.planes-intro {
  text-align: center;
  max-width: 700px;
  margin: 0 auto 3rem;
  color: #555;
}
.planes-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 2rem;
}
.plan-card {
  background: #fff;
  border-radius: 16px;
  box-shadow: 0 20px 30px rgba(0, 0, 0, 0.05);
  padding: 2rem 1.5rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.plan-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
}
.plan-card h3 {
  font-size: 1.5rem;
  margin-bottom: 0.25rem;
}
.plan-price {
  display: flex;
  align-items: baseline;
  gap: 0.25rem;
  margin: 1rem 0;
}
.plan-price .price {
  font-size: 2rem;
  font-weight: 700;
  color: var(--secondary-color);
}
.plan-price .iva {
  font-size: 0.85rem;
  color: #777;
}
.plan-list {
  list-style: none;
  width: 100%;
  margin-top: 1rem;
  padding-left: 0;
  color: #555;
  font-size: 0.95rem;
  flex-grow: 1;
}
.plan-list li {
  margin: 0.4rem 0;
  padding-left: 1.4rem;
  position: relative;
}
.plan-list li::before {
  /* Utilizamos un caracter unicode de check para evitar depender de iconos externos */
  content: '\2713';
  font-family: inherit;
  font-weight: 700;
  color: var(--secondary-color);
  position: absolute;
  left: 0;
  top: 0.1rem;
}
.plan-note {
  color: #999;
  font-style: italic;
  font-size: 0.85rem;
}
.plan-note::before {
  content: '\2139'; /* Símbolo de información (ℹ) */
  font-family: inherit;
  font-weight: 700;
  position: absolute;
  left: 0;
  top: 0.1rem;
  color: #999;
}
.plan-btn {
  margin-top: 1.5rem;
  width: 100%;
  text-align: center;
}
.featured {
  background: linear-gradient(135deg, var(--secondary-color), var(--primary-color));
  color: #fff;
}
.featured h3,
.featured .plan-price .price {
  color: #fff;
}
.featured .plan-price .iva {
  color: rgba(255, 255, 255, 0.8);
}
.featured .plan-list li {
  color: rgba(255, 255, 255, 0.85);
}
.featured .plan-list li::before {
  color: #fff;
}
.featured .plan-note {
  color: rgba(255, 255, 255, 0.75);
}
.featured .plan-note::before {
  color: rgba(255, 255, 255, 0.75);
}

/* Cómo funciona */
.funciona {
  background: #fff;
}
.funciona-container h2 {
  text-align: center;
  margin-bottom: 1rem;
}
.funciona-intro {
  text-align: center;
  max-width: 700px;
  margin: 0 auto 3rem;
  color: #555;
}
.funciona-steps {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 2rem;
}
.funciona-step {
  background: var(--bg-color);
  padding: 2rem 1.5rem;
  border-radius: 12px;
  text-align: center;
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.05);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.funciona-step:hover {
  transform: translateY(-6px);
  box-shadow: 0 15px 25px rgba(0, 0, 0, 0.1);
}
.step-icon {
  font-size: 2rem;
  color: var(--secondary-color);
  margin-bottom: 1rem;
}
.funciona-step h3 {
  font-size: 1.25rem;
  margin-bottom: 0.5rem;
}
.funciona-step p {
  font-size: 0.95rem;
  color: #555;
}

/* SEO */
.seo {
  background: #fff;
  position: relative;
  overflow: hidden;
}
.seo-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 2rem;
}
.seo-text {
  flex: 1 1 500px;
}
.seo-text h2 {
  margin-bottom: 1rem;
}
.seo-text p {
  color: #555;
  margin-bottom: 1.5rem;
}
.seo-list {
  list-style: none;
  padding-left: 0;
  color: #555;
  font-size: 1rem;
}
.seo-list li {
  margin: 0.5rem 0;
  padding-left: 1.6rem;
  position: relative;
}
.seo-list li i {
  position: absolute;
  left: 0;
  top: 0.1rem;
  color: var(--secondary-color);
}
.seo-graphic {
  flex: 1 1 350px;
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 300px;
}
.blob {
  width: 320px;
  height: 320px;
  background: radial-gradient(circle at 30% 30%, var(--primary-color) 0%, var(--secondary-color) 50%, transparent 80%);
  border-radius: 60% 40% 70% 30% / 50% 60% 40% 50%;
  filter: blur(60px);
  animation: float 8s ease-in-out infinite;
}
.blob.large {
  width: 400px;
  height: 400px;
}
@keyframes float {
  0%, 100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-20px);
  }
}

/*
 * Decoraciones con forma abstracta. Se utilizan en el hero, la sección de SEO y en
 * Quiénes Somos para mantener coherencia visual. La clase rotate aplica una
 * rotación diferente para variar el aspecto.
 */
.decor-shape {
  width: 320px;
  max-width: 100%;
  height: auto;
  opacity: 0.9;
  pointer-events: none;
  user-select: none;
}
.decor-shape.large {
  width: 400px;
}
.rotate {
  transform: rotate(-15deg);
}
.rotate-2 {
  transform: rotate(30deg);
}

/* Testimonios */
.testimonios {
  background: var(--bg-color);
}
.testimonios-container h2 {
  text-align: center;
  margin-bottom: 2rem;
}
.testimonios-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 2rem;
}
.testimonial-item {
  background: #fff;
  padding: 2rem;
  border-radius: 12px;
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.05);
  font-style: italic;
  color: #555;
  position: relative;
  line-height: 1.6;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.testimonial-item:hover {
  transform: translateY(-6px);
  box-shadow: 0 15px 25px rgba(0, 0, 0, 0.1);
}
.testimonial-item p {
  margin-bottom: 1.5rem;
  font-size: 1rem;
}
.testimonial-author {
  display: flex;
  align-items: center;
  gap: 1rem;
}
.avatar {
  width: 50px;
  height: 50px;
  border-radius: 50%;
  background: var(--secondary-color);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-family: var(--heading-font);
}
.author-info strong {
  display: block;
  font-family: var(--heading-font);
  font-size: 1rem;
  color: var(--secondary-color);
}
.author-info span {
  font-size: 0.85rem;
  color: #777;
}

/* FAQ */
.faq {
  background: #fff;
}
.faq-container h2 {
  text-align: center;
  margin-bottom: 2rem;
}
.faq-item {
  border-bottom: 1px solid #eee;
  margin-bottom: 1rem;
  padding-bottom: 1rem;
}
.faq-question {
  width: 100%;
  background: none;
  border: none;
  padding: 1rem;
  font-family: var(--heading-font);
  font-size: 1.1rem;
  color: var(--secondary-color);
  text-align: left;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.faq-question .icon {
  font-size: 1rem;
  transition: transform 0.3s ease;
}
.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.4s ease;
}
.faq-answer p {
  margin: 0.5rem 1rem 0;
  color: #555;
  font-size: 0.95rem;
  line-height: 1.6;
}
.faq-item.open .faq-answer {
  max-height: 200px;
}
.faq-item.open .faq-question .icon {
  transform: rotate(180deg);
}

/* Nosotros */
.nosotros {
  background: var(--bg-color);
}
.nosotros-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 2rem;
}
.nosotros-text {
  flex: 1 1 500px;
}
.nosotros-text h2 {
  margin-bottom: 1rem;
}
.nosotros-text p {
  color: #555;
  margin-bottom: 1rem;
  line-height: 1.7;
}
.nosotros-graphic {
  flex: 1 1 350px;
  display: flex;
  justify-content: center;
  align-items: center;
  position: relative;
}

/* Contacto */
.contacto {
  background: #fff;
}
.contacto-container h2 {
  text-align: center;
  margin-bottom: 1rem;
}
.contacto-container p {
  text-align: center;
  max-width: 700px;
  margin: 0 auto 2rem;
  color: #555;
}
.contacto-wrapper {
  display: flex;
  flex-wrap: wrap;
  gap: 2rem;
  justify-content: center;
  align-items: flex-start;
}
.contacto-form {
  flex: 1 1 350px;
  background: var(--bg-color);
  padding: 2rem;
  border-radius: 12px;
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.05);
}
.contacto-info {
  flex: 1 1 300px;
}
.form-group {
  margin-bottom: 1rem;
}
.form-group label {
  display: block;
  margin-bottom: 0.5rem;
  color: var(--secondary-color);
  font-weight: 600;
}
.form-group input,
.form-group textarea {
  width: 100%;
  padding: 0.75rem;
  border: 1px solid #ddd;
  border-radius: 8px;
  font-family: var(--body-font);
  font-size: 1rem;
  resize: vertical;
}
.form-group input:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--secondary-color);
  box-shadow: 0 0 0 3px rgba(92, 70, 212, 0.2);
}
.form-group.full {
  width: 100%;
}
.contacto-form button {
  margin-top: 1rem;
  width: 100%;
}
.contacto-info h3 {
  color: var(--secondary-color);
  margin-bottom: 1rem;
}
.contacto-info p {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.5rem;
  color: #555;
  font-size: 0.95rem;
}
.contacto-info i {
  color: var(--secondary-color);
}

/* Footer */
.site-footer {
  background: var(--secondary-color);
  color: #fff;
  padding: 3rem 0 1rem;
}
.footer-container {
  display: flex;
  flex-wrap: wrap;
  gap: 2rem;
  justify-content: space-between;
}
.footer-about,
.footer-links,
.footer-contact {
  flex: 1 1 250px;
}
.footer-about h3,
.footer-links h4,
.footer-contact h4 {
  font-family: var(--heading-font);
  margin-bottom: 0.5rem;
  color: #fff;
}
.footer-about p {
  color: #e6e6e6;
  line-height: 1.6;
  font-size: 0.95rem;
}
.footer-links ul {
  list-style: none;
  padding: 0;
  margin: 0;
}
.footer-links li {
  margin: 0.3rem 0;
}
.footer-links a {
  color: #e0e0ff;
  text-decoration: none;
  font-size: 0.95rem;
}
.footer-links a:hover {
  text-decoration: underline;
}
.footer-contact p {
  margin: 0.3rem 0;
  font-size: 0.95rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}
.footer-contact i {
  color: #e0e0ff;
}
.footer-bottom {
  text-align: center;
  border-top: 1px solid rgba(255, 255, 255, 0.2);
  padding-top: 1rem;
  margin-top: 2rem;
  font-size: 0.8rem;
  color: #d9d9ff;
}
.footer-bottom a {
  color: #d9d9ff;
  text-decoration: none;
}
.footer-bottom a:hover {
  text-decoration: underline;
}

/* Media queries */
@media (max-width: 880px) {
  .menu-toggle {
    display: block;
  }
  .main-nav {
    display: none;
    position: absolute;
    top: 100%;
    right: 0;
    background: #fff;
    width: 240px;
    border: 1px solid #eee;
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.05);
    padding: 1rem;
    z-index: 998;
  }
  .main-nav ul {
    flex-direction: column;
    align-items: flex-start;
    gap: 1rem;
  }
  .main-nav.open {
    display: block;
  }
  .header-cta {
    display: none;
  }
  .mobile-cta {
    display: block;
    margin-top: 1rem;
  }
  .hero-container {
    flex-direction: column;
    text-align: center;
    gap: 3rem;
  }
  .hero-content h1 {
    font-size: 2.2rem;
  }
  .plans-grid {
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  }
  .seo-container {
    flex-direction: column;
    text-align: center;
  }
  .seo-list li {
    justify-content: center;
  }
  .nosotros-container {
    flex-direction: column;
    text-align: center;
  }
  .contacto-wrapper {
    flex-direction: column;
    align-items: stretch;
  }
  .main-nav .mobile-cta {
    margin-top: 1rem;
  }
}
/* Galería de proyectos */
.galeria {
  background: var(--bg-color);
}
.galeria-container {
  text-align: center;
}
.galeria h2 {
  font-family: var(--heading-font);
  color: var(--secondary-color);
  margin-bottom: 2rem;
  font-size: 2rem;
}
.galeria-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 2rem;
}
.project-card {
  background: #fff;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.06);
  display: flex;
  flex-direction: column;
  transition: transform 0.3s ease;
}
.project-card:hover {
  transform: translateY(-5px);
}
.project-image img {
  width: 100%;
  height: auto;
  display: block;
}
.project-info {
  padding: 1rem 1.25rem 1.5rem;
  display: flex;
  flex-direction: column;
  flex: 1;
}
.project-info h3 {
  margin: 0 0 0.5rem;
  font-family: var(--heading-font);
  font-size: 1.2rem;
  color: var(--secondary-color);
}
.project-info p {
  font-size: 0.95rem;
  margin-bottom: 1rem;
  color: #555;
  flex-grow: 1;
}
.project-info .btn {
  align-self: flex-start;
  background: var(--secondary-color);
  color: #fff;
  padding: 0.5rem 1rem;
  border-radius: 6px;
  font-weight: 600;
  font-size: 0.9rem;
  text-decoration: none;
  transition: background-color 0.3s ease, transform 0.3s ease;
}
.project-info .btn:hover {
  background: var(--accent-color);
  transform: translateY(-2px);
}
