/* =================================
   VARIABLES DE COLOR Y CONFIGURACIÓN
   ================================= */
:root {
    /* Colores principales */
    --color-primary: #16ED48;
    --color-black: #000000;
    --color-white: #FFFFFF;
    
    /* Variaciones de color */
    --color-primary-dark: #13d540;
    --color-primary-light: #4ef570;
    --color-gray-text: #999999;  /* Más claro para mejor contraste */
    --color-gray-light: #cccccc;  /* Más claro para mejor visibilidad */
    --color-gray-border: #444444; /* Bordes más visibles */
    
    /* Fondos */
    --bg-main: #000000;
    --bg-section: #111111;
    --bg-card: #1a1a1a;
    
    /* Estados y utilidades */
    --color-success: #16ED48;
    --color-warning: #f59e0b;
    --color-error: #ef4444;
    
    /* Gradientes */
    --gradient-primary: linear-gradient(135deg, #16ED48, #13d540);
    --gradient-dark: linear-gradient(135deg, #000000, #111111);
    
    /* Sombras */
    --shadow-sm: 0 4px 12px rgba(22, 237, 72, 0.1);
    --shadow-md: 0 8px 24px rgba(0, 0, 0, 0.2);
    --shadow-lg: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    --shadow-xl: 0 35px 60px -12px rgba(0, 0, 0, 0.35);
    --shadow-primary: 0 4px 15px rgba(22, 237, 72, 0.3);
    --shadow-primary-hover: 0 8px 25px rgba(22, 237, 72, 0.4);
    
    /* Transparencias */
    --alpha-primary-10: rgba(22, 237, 72, 0.1);
    --alpha-primary-20: rgba(22, 237, 72, 0.2);
    --alpha-primary-30: rgba(22, 237, 72, 0.3);
    --alpha-black-10: rgba(0, 0, 0, 0.1);
    --alpha-black-50: rgba(0, 0, 0, 0.5);
    --alpha-black-80: rgba(0, 0, 0, 0.8);
    --alpha-white-10: rgba(255, 255, 255, 0.1);
    --alpha-white-50: rgba(255, 255, 255, 0.5);
}

/* =================================
   RESET Y BASE
   ================================= */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    scroll-padding-top: 100px;
}

body {
    font-family: 'Inter', sans-serif;
    background: var(--bg-main);
    color: var(--color-white);
    line-height: 1.6;
    overflow-x: hidden;
}

/* =================================
   NAVEGACIÓN GLOBAL
   ================================= */
.navbar {
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 1000;
    background: rgba(0, 0, 0, 0.95);
    backdrop-filter: blur(10px);
    padding: 1rem 0;
    transition: all 0.3s ease;
}

.navbar.scrolled {
    background: rgba(0, 0, 0, 0.98);
    padding: 0.5rem 0;
    box-shadow: var(--shadow-lg);
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 clamp(1rem, 4vw, 2rem);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-size: clamp(1.5rem, 4vw, 1.8rem);
    font-weight: 800;
    color: var(--color-primary);
    text-decoration: none;
    letter-spacing: -0.025em;
}

.nav-links {
    display: flex;
    list-style: none;
    gap: clamp(1rem, 3vw, 2rem);
}

.nav-links a {
    color: var(--color-white);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s ease;
    position: relative;
    font-size: clamp(0.9rem, 2vw, 1rem);
}

.nav-links a:hover,
.nav-links a.active {
    color: var(--color-primary);
}

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

.nav-links a:hover::after,
.nav-links a.active::after {
    width: 100%;
}

.cta-nav {
    background: var(--gradient-primary);
    color: var(--color-black);
    padding: clamp(0.5rem, 2vw, 0.75rem) clamp(1rem, 3vw, 1.5rem);
    border-radius: 50px;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
    box-shadow: var(--shadow-primary);
    font-size: clamp(0.85rem, 2vw, 1rem);
    white-space: nowrap;
}

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

/* Menú móvil */
.nav-toggle {
    display: none;
    background: none;
    border: none;
    color: var(--color-white);
    font-size: 1.5rem;
    cursor: pointer;
    padding: 0.5rem;
}

.nav-mobile-menu {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: rgba(0, 0, 0, 0.98);
    backdrop-filter: blur(10px);
    border-top: 1px solid var(--color-gray-border);
    padding: 2rem;
    z-index: 999;
}

.nav-mobile-menu.active {
    display: block !important;
}

.nav-mobile-menu .nav-links {
    display: flex;
    align-items: flex-start;
    flex-direction: column;
    gap: 1.5rem;
    text-align: center;
}

.nav-mobile-menu .nav-links a {
    font-size: 1.1rem;
    padding: 0.5rem;
    border-bottom: 1px solid var(--color-gray-border);
}

.nav-mobile-menu .cta-nav {
    margin-top: 1.5rem;
    display: inline-block;
    width: auto;
    text-align: center;
}

/* =================================
   SECCIONES Y CONTENEDORES
   ================================= */
.section {
    padding: clamp(3rem, 8vh, 5rem) 0;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 clamp(1rem, 4vw, 2rem);
}

.section-header {
    text-align: center;
    max-width: min(600px, 90%);
    margin: 0 auto clamp(2.5rem, 6vh, 4rem) auto;
}

.section-title {
    font-size: clamp(2rem, 6vw, 2.5rem);
    font-weight: 700;
    margin-bottom: clamp(0.75rem, 2vh, 1rem);
    color: var(--color-white);
}

.section-subtitle {
    font-size: clamp(1.1rem, 3vw, 1.2rem);
    color: var(--color-gray-text);
    line-height: 1.6;
}

/* =================================
   BOTONES GLOBALES
   ================================= */
.btn-primary,
.btn-secondary {
    padding: clamp(0.75rem, 2vw, 1rem) clamp(1.5rem, 4vw, 2rem);
    border-radius: 50px;
    text-decoration: none;
    font-weight: 600;
    font-size: clamp(1rem, 2.5vw, 1.1rem);
    transition: all 0.3s ease;
    white-space: nowrap;
    cursor: pointer;
    border: none;
    display: inline-block;
}

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

.btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-primary-hover);
    filter: brightness(1.1);
}

.btn-primary:disabled,
.btn-disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
    pointer-events: none;
}

.btn-secondary {
    background: transparent;
    color: var(--color-primary);  /* Verde en lugar de blanco para mejor visibilidad */
    border: 2px solid var(--color-primary);
}

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

.btn-full {
    width: 100%;
    text-align: center;
    display: block;
}

/* =================================
   CARDS Y COMPONENTES
   ================================= */
.card {
    padding: clamp(1.5rem, 4vw, 2rem);
    border-radius: 20px;
    border: 1px solid var(--color-gray-border);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: var(--gradient-primary);
    transform: scaleX(0);
    transition: transform 0.3s ease;
}

.card:hover::before {
    transform: scaleX(1);
}

.card:hover {
    transform: translateY(-10px);
    border-color: var(--color-primary);
    box-shadow: var(--shadow-xl);
}

.icon {
    width: clamp(50px, 12vw, 60px);
    height: clamp(50px, 12vw, 60px);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: clamp(1rem, 3vw, 1.5rem);
    background: var(--gradient-primary);
}

.icon i {
    font-size: clamp(1.25rem, 3vw, 1.5rem);
    color: var(--color-black);
}

/* =================================
   UTILIDADES DE COLOR
   ================================= */
.highlight {
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.check {
    color: var(--color-success);
    margin-right: 0.75rem;
    font-weight: 600;
}

/* =================================
   FOOTER GLOBAL
   ================================= */
.footer {
    background: var(--bg-main);
    padding: clamp(2rem, 5vh, 3rem) 0 clamp(1rem, 2vh, 2rem);
    border-top: 1px solid var(--color-gray-border);
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(250px, 100%), 1fr));
    gap: clamp(1.5rem, 4vw, 2rem);
    margin-bottom: clamp(1.5rem, 3vh, 2rem);
}

.footer h3 {
    color: var(--color-primary);
    margin-bottom: 1rem;
    font-weight: 600;
    font-size: clamp(1.1rem, 3vw, 1.2rem);
}

.footer p,
.footer a {
    color: var(--color-gray-text);
    text-decoration: none;
    line-height: 1.6;
    font-size: clamp(0.9rem, 2vw, 1rem);
}

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

.social-links {
    display: flex;
    gap: 1rem;
    margin-top: 1rem;
    flex-wrap: wrap;
}

.social-links a {
    width: clamp(35px, 8vw, 40px);
    height: clamp(35px, 8vw, 40px);
    background: var(--bg-section);
    border: 1px solid var(--color-gray-border);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

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

.footer-bottom {
    border-top: 1px solid var(--color-gray-border);
    padding-top: clamp(1.5rem, 3vh, 2rem);
    text-align: center;
    color: var(--color-gray-text);
    font-size: clamp(0.85rem, 2vw, 1rem);
}

/* =================================
   ANIMACIONES
   ================================= */
.scroll-animate {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.6s ease;
}

.scroll-animate.animate {
    opacity: 1;
    transform: translateY(0);
}

.fade-in {
    animation: fadeIn 0.8s ease forwards;
}

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

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

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

@keyframes arrowPulse {
    0%, 100% {
        opacity: 0.6;
        transform: scale(1);
    }
    50% {
        opacity: 1;
        transform: scale(1.1);
    }
}

/* =================================
   INDICADOR DE SCROLL
   ================================= */
.scroll-indicator {
    position: absolute;
    bottom: clamp(2rem, 5vh, 3rem);
    left: 50%;
    transform: translateX(-50%);
    z-index: 10;
    opacity: 0.7;
    transition: opacity 0.3s ease;
    animation: bounce 2s infinite;
}

.scroll-indicator:hover {
    opacity: 1;
}

.scroll-arrow {
    width: clamp(30px, 6vw, 40px);
    height: clamp(30px, 6vw, 40px);
    border: 2px solid var(--color-primary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--alpha-primary-10);
    backdrop-filter: blur(10px);
    cursor: pointer;
    transition: all 0.3s ease;
}

.scroll-arrow:hover {
    background: var(--alpha-primary-20);
    transform: translateY(-2px);
}

.scroll-arrow i {
    font-size: clamp(14px, 3vw, 18px);
    color: var(--color-primary);
    animation: arrowPulse 1.5s ease-in-out infinite;
}

/* =================================
   MEDIA QUERIES RESPONSIVE
   ================================= */
@media (max-width: 768px) {
    .nav-container .cta-nav {
        display: none;
    }
    
    .nav-links {
        display: none;
    }
    
    .nav-toggle {
        display: block;
    }
    
    .nav-mobile-menu.active {
        display: block;
    }
}

@media (max-width: 480px) {
    .section {
        padding: 2rem 0;
    }
    
    .card {
        padding: 1.5rem;
    }
    
    .scroll-indicator {
        display: none;
    }
}

@media (max-height: 500px) {
    .scroll-indicator {
        display: none;
    }
}

@media (max-height: 500px) and (orientation: landscape) {
    /* Ajustes para landscape móvil */
}

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
    
    .scroll-indicator {
        animation: none;
    }
    
    .scroll-arrow i {
        animation: none;
        opacity: 0.8;
    }
}