/* Reset y Variables */
:root {
  --primary-color: #0066ff;
  --primary-dark: #0052cc;
  --secondary-color: #00d4ff;
  --accent-color: #ff6b35;
  --text-primary: #1a1a1a;
  --text-secondary: #6b7280;
  --text-light: #9ca3af;
  --bg-primary: #ffffff;
  --bg-secondary: #f8fafc;
  --bg-dark: #0f1419;
  --gradient-primary: linear-gradient(135deg, #0066ff 0%, #00d4ff 100%);
  --gradient-secondary: linear-gradient(135deg, #ff6b35 0%, #f093fb 100%);
  --gradient-neural: linear-gradient(45deg, rgba(0, 102, 255, 0.1), rgba(0, 212, 255, 0.1));
  --shadow-light: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
  --shadow-medium: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
  --shadow-heavy: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
  --border-radius: 12px;
  --font-primary: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-mono: 'JetBrains Mono', 'Fira Code', monospace;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-primary);
  line-height: 1.6;
  color: var(--text-primary);
  background: var(--bg-primary);
  overflow-x: hidden;
}

/* Neural Network Background */
.neural-bg {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: -1;
  opacity: 0.03;
  background-image:
  radial-gradient(circle at 20% 20%, var(--primary-color) 1px, transparent 1px),
  radial-gradient(circle at 80% 80%, var(--secondary-color) 1px, transparent 1px),
  radial-gradient(circle at 40% 60%, var(--primary-color) 1px, transparent 1px);
  background-size: 50px 50px, 80px 80px, 60px 60px;
  animation: float 20s ease-in-out infinite;
}

@keyframes float {
  0%, 100% { transform: translateY(0) rotate(0deg); }
  50% { transform: translateY(-20px) rotate(1deg); }
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
  font-weight: 600;
  line-height: 1.2;
  color: var(--text-primary);
}

.gradient-text {
  background: var(--gradient-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* Container */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

/* Header */
.header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(20px);
  border-bottom: 1px solid rgba(0, 102, 255, 0.1);
  transition: all 0.3s ease;
}

.nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem 2rem;
  max-width: 1200px;
  margin: 0 auto;
}

.nav-brand .logo {
  font-family: var(--font-mono);
  font-size: 1.5rem;
  font-weight: 700;
  background: var(--gradient-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.nav-links {
  display: flex;
  gap: 2rem;
  align-items: center;
}

.nav-link {
  text-decoration: none;
  color: var(--text-primary);
  font-weight: 500;
  transition: color 0.3s ease;
  position: relative;
}

.nav-link:hover {
  color: var(--primary-color);
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: -5px;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--gradient-primary);
  transition: width 0.3s ease;
}

.nav-link:hover::after {
  width: 100%;
}

.cta-nav {
  background: var(--gradient-primary);
  color: white !important;
  padding: 0.5rem 1rem;
  border-radius: var(--border-radius);
  transition: transform 0.3s ease;
}

.cta-nav:hover {
  transform: translateY(-2px);
}

.cta-nav::after {
  display: none;
}

/* Hero Section */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding-top: 100px;
  position: relative;
  background: linear-gradient(135deg, rgba(0, 102, 255, 0.02) 0%, rgba(0, 212, 255, 0.02) 100%);
}

.hero-content {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: center;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 2rem;
}

.hero-title {
  font-size: 3.5rem;
  margin-bottom: 1rem;
  line-height: 1.1;
}

.hero-subtitle {
  display: block;
  font-size: 2rem;
  color: var(--text-secondary);
  font-weight: 400;
  margin-top: 0.5rem;
}

.hero-description {
  font-size: 1.25rem;
  color: var(--text-secondary);
  margin-bottom: 2rem;
  line-height: 1.6;
}

.hero-meta {
  display: flex;
  gap: 2rem;
  margin-bottom: 2rem;
  font-size: 0.95rem;
}

.author {
  color: var(--text-secondary);
}

.isbn {
  color: var(--text-light);
  font-family: var(--font-mono);
}

.hero-cta {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
}

/* Book Container */
.book-container {
  position: relative;
  margin: 0 auto;
  max-width: 400px;
  padding: 20px;
}

.book-cover {
  width: 100%;
  height: auto;
  border-radius: var(--border-radius);
  box-shadow: var(--shadow-heavy);
  transition: all 0.4s ease;
  transform: translateZ(0); /* Forzar aceleración hardware de forma simple */
}

.book-cover:hover {
  transform: translateY(-10px) scale(1.03);
  box-shadow: 0 30px 60px -12px rgba(0, 0, 0, 0.4);
}

.book-glow {
  position: absolute;
  top: 10px;
  left: 10px;
  right: 10px;
  bottom: 10px;
  background: var(--gradient-primary);
  border-radius: var(--border-radius);
  opacity: 0.2;
  filter: blur(20px);
  z-index: -1;
  animation: glow-pulse 4s ease-in-out infinite alternate;
  pointer-events: none;
}

@keyframes glow-pulse {
  0% {
    opacity: 0.1;
    transform: scale(0.98);
  }
  100% {
    opacity: 0.3;
    transform: scale(1.02);
  }
}

/* Scroll Indicator */
.scroll-indicator {
  position: absolute;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%);
  animation: bounce 2s infinite;
}

.scroll-arrow {
  width: 24px;
  height: 24px;
  border: 2px solid var(--primary-color);
  border-top: none;
  border-left: none;
  transform: rotate(45deg);
}

@keyframes bounce {
  0%, 20%, 50%, 80%, 100% { transform: translateX(-50%) translateY(0); }
  40% { transform: translateX(-50%) translateY(-10px); }
  60% { transform: translateX(-50%) translateY(-5px); }
}

/* Buttons */
.btn-primary, .btn-secondary {
  padding: 1rem 2rem;
  border: none;
  border-radius: var(--border-radius);
  font-weight: 600;
  font-size: 1rem;
  cursor: pointer;
  transition: all 0.3s ease;
  text-decoration: none;
  display: inline-block;
  text-align: center;
}

.btn-primary {
  background: var(--gradient-primary);
  color: white;
  box-shadow: var(--shadow-medium);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-heavy);
}

.btn-secondary {
  background: transparent;
  color: var(--primary-color);
  border: 2px solid var(--primary-color);
}

.btn-secondary:hover {
  background: var(--primary-color);
  color: white;
  transform: translateY(-2px);
}

.btn-large {
  padding: 1.25rem 2.5rem;
  font-size: 1.1rem;
  width: 100%;
  max-width: 300px;
}

/* Quote Section */
.quote-section {
  padding: 6rem 2rem;
  background: var(--bg-dark);
  color: white;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.quote-section::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: var(--gradient-neural);
  opacity: 0.1;
}

.quote-container {
  max-width: 800px;
  margin: 0 auto;
  position: relative;
  z-index: 2;
}

.main-quote {
  font-size: 1.4rem;
  line-height: 1.8;
  font-style: italic;
  margin: 0;
}

.main-quote p {
  margin-bottom: 2rem;
  opacity: 0.9;
}

.main-quote footer {
  font-size: 1.2rem;
  font-style: normal;
  color: var(--secondary-color);
  margin-top: 2rem;
}

/* Sections */
.book-section, .author-section, .purchase-section {
  padding: 6rem 2rem;
}

.book-section {
  background: var(--bg-secondary);
}

.section-title {
  font-size: 2.5rem;
  text-align: center;
  margin-bottom: 3rem;
  position: relative;
}

.section-title::after {
  content: '';
  position: absolute;
  bottom: -10px;
  left: 50%;
  transform: translateX(-50%);
  width: 60px;
  height: 4px;
  background: var(--gradient-primary);
  border-radius: 2px;
}

/* Book Details */
.book-details {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 4rem;
  margin-top: 3rem;
}

.book-description p {
  font-size: 1.1rem;
  margin-bottom: 1.5rem;
  color: var(--text-secondary);
}

.conclusion {
  background: rgba(0, 102, 255, 0.05);
  padding: 1.5rem;
  border-radius: var(--border-radius);
  border-left: 4px solid var(--primary-color);
}

.benefits h3 {
  color: var(--primary-color);
  margin-bottom: 1.5rem;
  font-size: 1.3rem;
}

.benefits-list {
  list-style: none;
}

.benefits-list li {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  margin-bottom: 1rem;
  padding: 0.5rem;
  border-radius: 8px;
  transition: background 0.3s ease;
}

.benefits-list li:hover {
  background: rgba(0, 102, 255, 0.05);
}

.check {
  color: var(--secondary-color);
  font-size: 1.2rem;
  flex-shrink: 0;
}

/* Author Section */
.author-content {
  max-width: 800px;
  margin: 0 auto;
  text-align: center;
}

.author-info h3 {
  font-size: 2rem;
  color: var(--primary-color);
  margin-bottom: 0.5rem;
}

.author-birth {
  color: var(--text-light);
  font-size: 0.95rem;
  margin-bottom: 1.5rem;
}

.author-bio {
  font-size: 1.1rem;
  line-height: 1.8;
  color: var(--text-secondary);
  margin-bottom: 2rem;
}

.social-links {
  display: flex;
  justify-content: center;
  gap: 1rem;
}

.social-link {
  display: inline-block;
  padding: 0.75rem;
  background: var(--bg-secondary);
  border-radius: 50%;
  text-decoration: none;
  font-size: 1.2rem;
  transition: all 0.3s ease;
}

.social-link:hover {
  background: var(--primary-color);
  transform: translateY(-2px);
}

/* Purchase Section */
.purchase-section {
  background: linear-gradient(135deg, rgba(0, 102, 255, 0.02) 0%, rgba(0, 212, 255, 0.02) 100%);
}

.purchase-content {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: center;
  max-width: 1000px;
  margin: 0 auto;
}

.price-box {
  text-align: center;
  background: white;
  padding: 2rem;
  border-radius: var(--border-radius);
  box-shadow: var(--shadow-medium);
  margin-bottom: 2rem;
}

.price {
  display: block;
  font-size: 3rem;
  font-weight: 700;
  color: var(--primary-color);
  margin-bottom: 0.5rem;
}

.format {
  color: var(--text-secondary);
  font-size: 1rem;
}

.payment-methods h4 {
  margin-bottom: 1rem;
  color: var(--text-primary);
}

.payment-icons {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
}

.payment-stripe, .payment-paypal {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.75rem 1rem;
  background: white;
  border-radius: var(--border-radius);
  box-shadow: var(--shadow-light);
  font-size: 0.9rem;
  color: var(--text-secondary);
}

.purchase-actions {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  align-items: center;
}

.guarantee {
  text-align: center;
  margin-top: 2rem;
  padding: 1.5rem;
  background: rgba(0, 212, 255, 0.05);
  border-radius: var(--border-radius);
  border: 1px solid rgba(0, 212, 255, 0.2);
}

.guarantee p {
  margin-bottom: 0.5rem;
  font-size: 0.95rem;
  color: var(--text-secondary);
}

/* Footer */
.footer {
  background: var(--bg-dark);
  color: white;
  padding: 3rem 2rem 2rem;
}

.footer-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
  max-width: 1200px;
  margin: 0 auto;
  flex-wrap: wrap;
  gap: 2rem;
}

.footer-info h4 {
  color: var(--secondary-color);
  margin-bottom: 1rem;
}

.footer-info p {
  color: rgba(255, 255, 255, 0.7);
  font-size: 0.9rem;
  margin-bottom: 0.5rem;
}

.footer-links {
  display: flex;
  gap: 2rem;
}

.footer-links a {
  color: rgba(255, 255, 255, 0.7);
  text-decoration: none;
  transition: color 0.3s ease;
}

.footer-links a:hover {
  color: var(--secondary-color);
}

/* Responsive Design */
@media (max-width: 1024px) {
  .hero-content {
    grid-template-columns: 1fr;
    text-align: center;
    gap: 3rem;
  }

  .book-details {
    grid-template-columns: 1fr;
    gap: 3rem;
  }

  .purchase-content {
    grid-template-columns: 1fr;
    gap: 3rem;
  }
}

@media (max-width: 768px) {
  .nav-links {
    gap: 1rem;
  }

  .nav-link {
    font-size: 0.9rem;
  }

  .hero-title {
    font-size: 2.5rem;
  }

  .hero-subtitle {
    font-size: 1.5rem;
  }

  .hero-description {
    font-size: 1.1rem;
  }

  .hero-cta {
    flex-direction: column;
    align-items: center;
  }

  .btn-primary, .btn-secondary {
    width: 100%;
    max-width: 300px;
  }

  .quote-section {
    padding: 4rem 1rem;
  }

  .main-quote {
    font-size: 1.2rem;
  }

  .section-title {
    font-size: 2rem;
  }

  .book-section, .author-section, .purchase-section {
    padding: 4rem 1rem;
  }
}

@media (max-width: 480px) {
  .nav {
    padding: 1rem;
  }

  .nav-links {
    gap: 0.5rem;
  }

  .cta-nav {
    padding: 0.4rem 0.8rem;
    font-size: 0.8rem;
  }

  .hero-title {
    font-size: 2rem;
  }

  .hero-subtitle {
    font-size: 1.2rem;
  }

  .hero-meta {
    flex-direction: column;
    gap: 0.5rem;
    text-align: center;
  }

  .price {
    font-size: 2.5rem;
  }

  .footer-content {
    flex-direction: column;
    text-align: center;
  }

  .footer-links {
    justify-content: center;
  }
}

/* Smooth Animations */
.hero-content > * {
  animation: fadeInUp 0.8s ease forwards;
}

.hero-text > *:nth-child(1) { animation-delay: 0.1s; }
.hero-text > *:nth-child(2) { animation-delay: 0.2s; }
.hero-text > *:nth-child(3) { animation-delay: 0.3s; }
.hero-text > *:nth-child(4) { animation-delay: 0.4s; }

.book-container {
  animation: fadeInUp 0.8s ease 0.5s forwards;
  opacity: 0;
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Loading States */
.loading {
  opacity: 0.6;
  pointer-events: none;
  position: relative;
}

.loading::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 20px;
  height: 20px;
  border: 2px solid transparent;
  border-top: 2px solid var(--primary-color);
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

@keyframes spin {
  0% { transform: translate(-50%, -50%) rotate(0deg); }
  100% { transform: translate(-50%, -50%) rotate(360deg); }
}
