/* =========================================
   VARIABLES Y FUENTES
   ========================================= */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;700&display=swap');

:root {
    --bg-dark: #050505; --bg-card: rgba(255, 255, 255, 0.02);
    --text-main: #ffffff; --text-muted: #aaaaaa;
    --accent-cyan: #00ffff; --accent-violet: #8a2be2;
    --border-thin: 1px solid rgba(255, 255, 255, 0.05);
    --font-main: 'Inter', sans-serif;
}

/* =========================================
   BASE Y CURSOR
   ========================================= */
html { scroll-behavior: smooth; }
body { font-family: var(--font-main); font-weight: 300; background-color: var(--bg-dark); color: var(--text-main); margin: 0; line-height: 1.6; overflow-x: hidden; }
.container { width: 90%; max-width: 1200px; margin: 0 auto; padding: 20px; }
h1, h2, h3 { font-weight: 500; margin-top: 0; }
a { color: var(--text-main); text-decoration: none; transition: color 0.3s; }
a:hover { color: var(--accent-cyan); }
.login-link { white-space: nowrap; }

@media (min-width: 1024px) { body, a, button, input { cursor: none; } }
.custom-cursor { position: fixed; top: 0; left: 0; width: 20px; height: 20px; border: 2px solid var(--accent-cyan); border-radius: 50%; pointer-events: none; z-index: 9999; transform: translate(-50%, -50%); transition: width 0.2s, height 0.2s, background-color 0.2s; mix-blend-mode: difference; }
.custom-cursor.hover-effect { width: 50px; height: 50px; background-color: rgba(0, 255, 255, 0.2); border-color: transparent; }

/* =========================================
   BOTONES Y ANIMACIONES
   ========================================= */
.cta-button { background: linear-gradient(45deg, #007bff, var(--accent-violet)); color: #fff; border: none; padding: 12px 24px; border-radius: 6px; cursor: pointer; font-weight: 500; transition: transform 0.2s, box-shadow 0.2s, color 0.2s; display: flex; justify-content: center; align-items: center; width: 100%; text-align: center; }
.cta-button:hover { transform: translateY(-2px); box-shadow: 0 5px 15px rgba(0, 123, 255, 0.4); color: #fff; }
.cta-button.large { font-size: 1.1em; padding: 15px 40px; display: inline-flex; width: auto; }
.cta-button.outline { background: transparent; border: 1px solid var(--accent-cyan); color: var(--text-main); }
.cta-button.outline:hover { background: var(--accent-cyan); color: #000; }
.icon-btn { background: transparent; border: none; color: var(--text-main); font-size: 1.2em; cursor: pointer; transition: color 0.3s, transform 0.3s; padding: 5px; margin-right: 15px; }
.icon-btn:hover { color: var(--accent-cyan); transform: rotate(20deg); }
.fade-in-section { opacity: 0; transform: translateY(40px); transition: opacity 0.8s ease-out, transform 0.8s ease-out; will-change: opacity, visibility; }
.fade-in-section.is-visible { opacity: 1; transform: none; }
#scroll-to-top {
    position: fixed !important;
    bottom: 100px !important; /* Lo subimos bastante para que notes el cambio */
    right: 30px !important;
    display: block; /* Solo para probar si se ve */
}

/* =========================================
   CABECERA Y HERO
   ========================================= */
.glass-header { position: sticky; top: 0; z-index: 100; background-color: rgba(5, 5, 5, 0.6); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); border-bottom: var(--border-thin); }
.header-content { display: flex; justify-content: space-between; align-items: center; padding: 15px 20px; }
.logo { display: flex; align-items: center; gap: 10px; }
.logo i { color: var(--accent-cyan); font-size: 1.8em; }
.logo h2 { margin: 0; font-size: 1.4em; letter-spacing: -1px; }
.main-nav ul { display: flex; gap: 30px; list-style: none; margin: 0; padding: 0; }
.actions { display: flex; align-items: center; gap: 15px; }
.hero { position: relative; text-align: center; padding: 120px 0 80px 0; background: radial-gradient(circle at center, #1a1a2e 0%, var(--bg-dark) 70%); overflow: hidden; }
#particle-canvas { position: absolute; top: 0; left: 0; width: 100%; height: 100%; z-index: 0; pointer-events: none; }
.hero-content { position: relative; z-index: 1; }
.animated-text { font-size: 3em; letter-spacing: -2px; line-height: 1.2; margin-bottom: 20px; }
.typed-text { color: var(--accent-cyan); }
.cursor { display: inline-block; width: 3px; background-color: var(--accent-cyan); animation: blink 1s infinite; }
@keyframes blink { 0%, 100% { opacity: 1; } 50% { opacity: 0; } }
.hero-subtitle { font-size: 1.2em; color: var(--text-muted); max-width: 600px; margin: 0 auto 40px auto; }
.dashboard-graphic { width: 100%; max-width: 800px; height: 350px; background-color: var(--bg-card); border: var(--border-thin); border-radius: 10px; margin: 0 auto 40px auto; display: flex; justify-content: center; align-items: center; color: var(--accent-cyan); font-style: italic; }

/* =========================================
   CARRUSEL Y ESTADÍSTICAS
   ========================================= */
.brand-ticker { background-color: #030303; padding: 30px 0; overflow: hidden; border-top: var(--border-thin); border-bottom: var(--border-thin); position: relative; white-space: nowrap; }
.brand-ticker::before, .brand-ticker::after { content: ''; position: absolute; top: 0; width: 100px; height: 100%; z-index: 2; }
.brand-ticker::before { left: 0; background: linear-gradient(to right, #050505, transparent); }
.brand-ticker::after { right: 0; background: linear-gradient(to left, #050505, transparent); }
.ticker-track { display: inline-block; animation: scrollTicker 30s linear infinite; }
.ticker-item { display: inline-flex; align-items: center; gap: 10px; font-size: 1.5em; font-weight: 700; color: var(--text-muted); margin: 0 40px; opacity: 0.5; transition: opacity 0.3s, color 0.3s; }
.ticker-item:hover { opacity: 1; color: var(--accent-cyan); }
@keyframes scrollTicker { 0% { transform: translateX(0); } 100% { transform: translateX(-50%); } }
.stats { background: linear-gradient(90deg, rgba(0, 123, 255, 0.1) 0%, rgba(138, 43, 226, 0.1) 100%); padding: 60px 0; border-top: var(--border-thin); border-bottom: var(--border-thin); }
.stats-grid { display: flex; justify-content: space-around; flex-wrap: wrap; gap: 30px; text-align: center; }
.stat-item h3 { display: inline-block; font-size: 3.5em; font-weight: 700; color: var(--accent-cyan); margin: 0; }
.stat-item .symbol { font-size: 2em; font-weight: 700; color: var(--accent-cyan); }
.stat-item p { color: var(--text-muted); font-size: 1.1em; margin-top: 5px; text-transform: uppercase; letter-spacing: 1px; }

/* =========================================
   SECCIONES Y TARJETAS
   ========================================= */
.section-title { text-align: center; font-size: 2.2em; letter-spacing: -1px; margin-bottom: 50px; color: var(--text-main); }
.solutions, .testimonials, .pricing, .products, .try-us { padding: 80px 0; }
.testimonials, .try-us { background-color: #080808; }
.pricing, .products { background-color: var(--bg-dark); }
.solution-cards, .testimonial-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 25px; }
.product-grid { display: flex; justify-content: center; gap: 30px; flex-wrap: wrap; }
.card, .testimonial-card { background-color: var(--bg-card); padding: 40px 20px; border-radius: 12px; text-align: center; border: var(--border-thin); transition: transform 0.3s; }
.card:hover { transform: translateY(-8px); background-color: rgba(255, 255, 255, 0.04); border-color: rgba(0, 255, 255, 0.3); }
.card i { font-size: 2.5em; color: var(--accent-cyan); margin-bottom: 20px; }
.card p, .quote { color: var(--text-muted); }
.quote { font-style: italic; line-height: 1.8; margin-bottom: 20px; }
.stars { color: #ffd700; margin-bottom: 15px; font-size: 0.9em; }
.author strong { display: block; color: var(--accent-cyan); }
.author span { font-size: 0.85em; }

/* =========================================
   PRODUCTOS Y DETALLES
   ========================================= */
.product-card { background-color: var(--bg-card); border: var(--border-thin); border-radius: 12px; overflow: hidden; display: flex; flex-direction: column; transition: transform 0.3s, border-color 0.3s, box-shadow 0.3s; text-decoration: none; width: 100%; max-width: 400px; }
.product-card:hover { transform: translateY(-8px); border-color: var(--accent-cyan); box-shadow: 0 10px 30px rgba(0, 255, 255, 0.1); }
.product-image { background: linear-gradient(135deg, #111, #222); height: 200px; display: flex; justify-content: center; align-items: center; font-size: 5em; color: var(--accent-violet); border-bottom: var(--border-thin); }
.product-info { padding: 25px; display: flex; flex-direction: column; flex-grow: 1; }
.product-info h3 { color: var(--text-main); font-size: 1.4em; margin-bottom: 10px; }
.product-info p { color: var(--text-muted); font-size: 0.9em; margin-bottom: 20px; flex-grow: 1; }
.product-price { font-size: 1.5em; font-weight: 700; color: var(--accent-cyan); margin-bottom: 15px; }
.product-link { color: var(--accent-violet); font-weight: 500; display: flex; align-items: center; gap: 8px; transition: gap 0.3s; }
.product-card:hover .product-link { gap: 12px; color: var(--accent-cyan); }

.product-detail { min-height: 80vh; }
.product-detail-wrapper { display: flex; gap: 60px; align-items: center; flex-wrap: wrap; }
.product-detail-image { flex: 1; min-width: 300px; background-color: var(--bg-card); border: var(--border-thin); border-radius: 20px; height: 500px; display: flex; justify-content: center; align-items: center; position: relative; overflow: hidden; }
.hologram-effect { font-size: 10em; color: var(--accent-cyan); position: relative; animation: float 4s ease-in-out infinite; }
@keyframes float { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-15px); } }
.scan-line { position: absolute; top: 0; left: -50%; width: 200%; height: 5px; background: rgba(0, 255, 255, 0.5); box-shadow: 0 0 20px rgba(0, 255, 255, 0.8); animation: scan 3s linear infinite; }
@keyframes scan { 0% { top: -10%; } 100% { top: 110%; } }
.product-detail-info { flex: 1.2; min-width: 300px; }
.product-title { font-size: 3em; margin-bottom: 10px; letter-spacing: -1px; }
.product-price-large { font-size: 2.5em; font-weight: 700; color: var(--accent-cyan); margin-bottom: 25px; }
.product-price-large span { font-size: 0.4em; color: var(--text-muted); font-weight: 300; margin-left: 10px; }
.product-description { font-size: 1.1em; color: var(--text-muted); line-height: 1.8; margin-bottom: 30px; }
.features-title { color: var(--text-main); margin-bottom: 15px; }
.product-features-list { list-style: none; padding: 0; margin: 0 0 40px 0; }
.product-features-list li { display: flex; align-items: center; gap: 12px; margin-bottom: 15px; color: var(--text-muted); }
.product-features-list li i { color: var(--accent-violet); font-size: 1.2em; }
.product-actions { display: flex; gap: 20px; margin-bottom: 20px; flex-wrap: wrap; }

/* =========================================
   CHECKOUT Y ÉXITO
   ========================================= */
.checkout-section { padding: 60px 0; min-height: 80vh; background-color: var(--bg-dark); }
.checkout-wrapper { display: flex; gap: 40px; flex-wrap: wrap; align-items: flex-start; }
.checkout-form-col { flex: 2; min-width: 300px; background-color: var(--bg-card); padding: 40px; border-radius: 12px; border: var(--border-thin); }
.checkout-summary-col { flex: 1.2; min-width: 300px; position: sticky; top: 100px; background: linear-gradient(180deg, rgba(255, 255, 255, 0.02) 0%, rgba(138, 43, 226, 0.05) 100%); padding: 40px; border-radius: 12px; border: 1px solid rgba(138, 43, 226, 0.2); }
.checkout-item { display: flex; justify-content: space-between; align-items: center; margin-bottom: 15px; border-bottom: var(--border-thin); padding-bottom: 15px; }
.checkout-item-name { color: var(--text-main); font-weight: 500; }
.checkout-item-price { color: var(--accent-cyan); font-weight: 700; }
.checkout-total-box { display: flex; justify-content: space-between; align-items: center; margin-top: 30px; font-size: 1.5em; font-weight: bold; color: var(--text-main); }
.success-section { flex-grow: 1; display: flex; justify-content: center; align-items: center; position: relative; padding: 60px 20px; background: radial-gradient(circle at center, #1a1a2e 0%, var(--bg-dark) 70%); min-height: 80vh; overflow: hidden; }
.success-card { background-color: rgba(18, 18, 18, 0.8); backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px); border: 1px solid rgba(0, 255, 255, 0.3); border-radius: 16px; width: 100%; max-width: 500px; padding: 50px 40px; position: relative; z-index: 1; box-shadow: 0 0 40px rgba(0, 255, 255, 0.1); text-align: center; }
.success-icon { font-size: 5em; color: #28a745; margin-bottom: 20px; text-shadow: 0 0 20px rgba(40, 167, 69, 0.5); animation: popIn 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275); }
.download-box { background: linear-gradient(180deg, rgba(255, 255, 255, 0.05) 0%, rgba(255, 255, 255, 0.01) 100%); border: var(--border-thin); padding: 30px 20px; border-radius: 12px; margin-top: 20px; }
.download-box h3 { color: var(--text-main); margin: 0 0 5px 0; }
.download-box p { color: var(--text-muted); margin: 0; font-size: 0.9em; }
.crm-links a { color: var(--text-main); text-decoration: none; }
.crm-links a:hover { color: var(--accent-cyan) !important; padding-left: 5px; transition: 0.3s; }
@keyframes popIn { 0% { transform: scale(0); opacity: 0; } 100% { transform: scale(1); opacity: 1; } }

/* =========================================
   FORMULARIOS Y IA
   ========================================= */
#ai-form { max-width: 500px; margin: 0 auto 30px auto; background-color: var(--bg-card); padding: 30px; border-radius: 12px; border: var(--border-thin); }
.form-group { margin-bottom: 20px; text-align: left; }
.form-group label { display: block; color: var(--accent-cyan); font-weight: 500; margin-bottom: 8px; }
.form-group input { width: 100%; box-sizing: border-box; padding: 12px; border-radius: 6px; border: 1px solid rgba(255, 255, 255, 0.1); background-color: rgba(0, 0, 0, 0.5); color: #fff; font-family: var(--font-main); }
.form-group input:focus { outline: none; border-color: var(--accent-cyan); box-shadow: 0 0 10px rgba(0, 255, 255, 0.2); }
#result-area { max-width: 600px; margin: 0 auto; padding: 25px; background-color: rgba(138, 43, 226, 0.05); border: 1px solid rgba(138, 43, 226, 0.4); border-radius: 8px; font-style: italic; font-weight: 300; line-height: 1.8; }
#result-area.hidden { display: none; }

/* =========================================
   CARRITO DE COMPRAS LATERAL
   ========================================= */
.cart-btn-wrapper { position: relative; display: inline-block; }
.badge-count { position: absolute; top: -5px; right: 0; background-color: #ff4d4d; color: white; font-size: 0.6em; font-weight: bold; padding: 2px 6px; border-radius: 50%; pointer-events: none; transition: transform 0.2s; }
.cart-overlay { position: fixed; top: 0; left: 0; width: 100%; height: 100%; background: rgba(0,0,0,0.6); backdrop-filter: blur(5px); z-index: 999; opacity: 0; visibility: hidden; transition: 0.3s; }
.cart-overlay.active { opacity: 1; visibility: visible; }
.cart-sidebar { position: fixed; top: 0; right: -450px; width: 100%; max-width: 400px; height: 100vh; background-color: var(--bg-dark); z-index: 1000; box-shadow: -5px 0 20px rgba(0,0,0,0.5); display: flex; flex-direction: column; transition: right 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94); border-left: var(--border-thin); }
.cart-sidebar.active { right: 0; }
.cart-header { padding: 20px 25px; border-bottom: var(--border-thin); display: flex; justify-content: space-between; align-items: center; }
.cart-items { flex-grow: 1; overflow-y: auto; padding: 20px 25px; display: flex; flex-direction: column; gap: 15px; }
.cart-item { display: flex; justify-content: space-between; align-items: center; background-color: var(--bg-card); padding: 15px; border-radius: 8px; border: var(--border-thin); animation: fadeIn 0.3s; }
.cart-item-info h4 { margin: 0 0 5px 0; color: var(--text-main); font-size: 1em; }
.cart-item-info p { margin: 0; color: var(--accent-cyan); font-weight: 700; }
.remove-item { color: #ff4d4d; background: none; border: none; cursor: pointer; font-size: 1.2em; transition: transform 0.2s; }
.remove-item:hover { transform: scale(1.2); }
.cart-footer { padding: 25px; border-top: var(--border-thin); background-color: rgba(0,0,0,0.2); }
.cart-total { font-size: 1.3em; font-weight: bold; margin-bottom: 20px; display: flex; justify-content: space-between; color: var(--text-main); }

/* =========================================
   FOOTER Y BOTÓN SCROLL
   ========================================= */
footer { padding: 60px 0 30px 0; text-align: center; border-top: var(--border-thin); background-color: #050505; }
.copyright { color: #666; font-size: 0.9em; margin-top: 30px; }
#scroll-to-top { position: fixed; bottom: 30px; right: 30px; background: linear-gradient(45deg, #007bff, var(--accent-violet)); color: #fff; width: 50px; height: 50px; border-radius: 50%; border: none; font-size: 1.5em; cursor: pointer; box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3); transition: opacity 0.3s, transform 0.3s; z-index: 99; }
#scroll-to-top:hover { transform: translateY(-5px); }
#scroll-to-top.hidden { opacity: 0; pointer-events: none; transform: translateY(20px); }

/* =========================================
   RESPONSIVE (MÓVILES)
   ========================================= */
@media (max-width: 768px) {
    .header-content { flex-direction: column; gap: 15px; }
    .main-nav ul { gap: 15px; font-size: 0.9em; flex-wrap: wrap; justify-content: center; }
    .actions { width: 100%; justify-content: center; }
    .animated-text { font-size: 2em; }
    .hero { padding: 80px 0 40px 0; }
    .dashboard-graphic { height: 200px; }
    .stat-item h3 { font-size: 2.5em; }
    .product-detail-wrapper, .checkout-wrapper { flex-direction: column; text-align: center; }
    .product-actions { justify-content: center; }
    .cart-sidebar { right: -100%; max-width: 100%; }
}