/* ============================================
   FINBUDDY - ESTILOS GLOBALES
   ============================================ */

/* Variables CSS */
:root {
    /* Colores Primarios */
    --primary-color: #667eea;
    --secondary-color: #764ba2;
    --accent-color: #f093fb;
    
    /* Colores Neutrales */
    --dark-bg: #0f0f1e;
    --light-bg: #ffffff;
    --gray-100: #f7f7f7;
    --gray-200: #e9e9e9;
    --gray-300: #d1d1d1;
    --gray-400: #999999;
    --gray-500: #666666;
    --text-dark: #1a1a1a;
    --text-light: #666666;
    
    /* Estados */
    --success: #10b981;
    --danger: #ef4444;
    --warning: #f59e0b;
    --info: #3b82f6;
    
    /* Sombras */
    --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.1);
    --shadow-md: 0 4px 6px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 25px rgba(0, 0, 0, 0.15);
    
    /* Espaciado */
    --spacing-xs: 0.25rem;
    --spacing-sm: 0.5rem;
    --spacing-md: 1rem;
    --spacing-lg: 1.5rem;
    --spacing-xl: 2rem;
    --spacing-2xl: 3rem;
    
    /* Bordes */
    --radius-sm: 4px;
    --radius-md: 8px;
    --radius-lg: 12px;
    --radius-xl: 16px;
    
    /* Transiciones */
    --transition: all 0.3s ease;
}

/* Reset y Base */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: var(--light-bg);
    color: var(--text-dark);
    line-height: 1.6;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 var(--spacing-lg);
}

/* ============================================
   TIPOGRAFÍA
   ============================================ */

h1, h2, h3, h4, h5, h6 {
    font-weight: 600;
    margin-bottom: var(--spacing-md);
}

h1 {
    font-size: 2.5rem;
    line-height: 1.2;
}

h2 {
    font-size: 2rem;
    line-height: 1.2;
}

h3 {
    font-size: 1.5rem;
}

p {
    margin-bottom: var(--spacing-md);
    color: var(--text-light);
}

a {
    color: var(--primary-color);
    text-decoration: none;
    transition: var(--transition);
}

a:hover {
    color: var(--secondary-color);
}

/* ============================================
   NAVEGACIÓN
   ============================================ */

.navbar {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    color: white;
    padding: var(--spacing-md) 0;
    box-shadow: var(--shadow-md);
    position: sticky;
    top: 0;
    z-index: 100;
}

.navbar-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo h1 {
    font-size: 1.8rem;
    margin: 0;
    color: white;
}

.nav-links {
    list-style: none;
    display: flex;
    gap: var(--spacing-lg);
    align-items: center;
}

.nav-links a {
    color: white;
    transition: var(--transition);
    padding: var(--spacing-sm) var(--spacing-md);
    border-radius: var(--radius-md);
}

.nav-links a:hover {
    background-color: rgba(255, 255, 255, 0.2);
}

.nav-btn {
    background-color: var(--accent-color) !important;
    color: white !important;
    padding: var(--spacing-sm) var(--spacing-lg) !important;
    border-radius: var(--radius-md);
    font-weight: 600;
}

/* ============================================
   HERO SECTION
   ============================================ */

.hero {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    color: white;
    padding: var(--spacing-2xl) 0;
    min-height: 600px;
    display: flex;
    align-items: center;
}

.hero-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--spacing-2xl);
    align-items: center;
}

.hero-text h1 {
    font-size: 3.5rem;
    margin-bottom: var(--spacing-lg);
    color: white;
}

.hero-text p {
    font-size: 1.3rem;
    margin-bottom: var(--spacing-xl);
    color: rgba(255, 255, 255, 0.9);
}

.hero-buttons {
    display: flex;
    gap: var(--spacing-md);
}

.hero-visual {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--spacing-md);
}

.dashboard-preview {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-md);
}

.preview-card {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    padding: var(--spacing-xl);
    border-radius: var(--radius-lg);
    border: 1px solid rgba(255, 255, 255, 0.2);
    text-align: center;
    font-weight: 600;
    font-size: 1.1rem;
    color: white;
}

/* ============================================
   BOTONES
   ============================================ */

.btn {
    padding: var(--spacing-md) var(--spacing-lg);
    border: none;
    border-radius: var(--radius-md);
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.btn-primary {
    background-color: var(--primary-color);
    color: white;
}

.btn-primary:hover {
    background-color: var(--secondary-color);
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.btn-secondary {
    background-color: var(--accent-color);
    color: white;
}

.btn-secondary:hover {
    background-color: #e878d8;
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.btn-icon {
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    padding: var(--spacing-md);
    transition: var(--transition);
}

.btn-icon:hover {
    transform: scale(1.1);
}

/* ============================================
   FEATURES SECTION
   ============================================ */

.features {
    padding: var(--spacing-2xl) 0;
    background-color: var(--gray-100);
}

.features h2 {
    text-align: center;
    margin-bottom: var(--spacing-2xl);
    font-size: 2.5rem;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: var(--spacing-lg);
}

.feature-card {
    background: white;
    padding: var(--spacing-xl);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-md);
    text-align: center;
    transition: var(--transition);
}

.feature-card:hover {
    transform: translateY(-10px);
    box-shadow: var(--shadow-lg);
}

.feature-icon {
    font-size: 3rem;
    margin-bottom: var(--spacing-md);
}

.feature-card h3 {
    color: var(--primary-color);
    margin-bottom: var(--spacing-md);
}

/* ============================================
   HOW IT WORKS SECTION
   ============================================ */

.how-it-works {
    padding: var(--spacing-2xl) 0;
}

.how-it-works h2 {
    text-align: center;
    margin-bottom: var(--spacing-2xl);
    font-size: 2.5rem;
}

.steps {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: var(--spacing-xl);
}

.step {
    background: white;
    padding: var(--spacing-xl);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-md);
    text-align: center;
    border-top: 4px solid var(--primary-color);
}

.step-number {
    display: inline-block;
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: white;
    border-radius: 50%;
    line-height: 50px;
    font-weight: 700;
    font-size: 1.5rem;
    margin-bottom: var(--spacing-md);
}

/* ============================================
   MODALES
   ============================================ */

.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
    transition: var(--transition);
}

.modal.hidden {
    display: none;
}

.modal-content {
    background: white;
    padding: var(--spacing-2xl);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
    max-width: 500px;
    width: 90%;
    position: relative;
    animation: slideIn 0.3s ease;
}

@keyframes slideIn {
    from {
        transform: translateY(-50px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.close-modal {
    position: absolute;
    top: var(--spacing-md);
    right: var(--spacing-md);
    font-size: 1.5rem;
    cursor: pointer;
    color: var(--gray-400);
}

.close-modal:hover {
    color: var(--text-dark);
}

/* ============================================
   FORMULARIOS
   ============================================ */

.auth-form {
    margin-top: var(--spacing-lg);
}

.form-group {
    margin-bottom: var(--spacing-lg);
}

.form-group label {
    display: block;
    margin-bottom: var(--spacing-sm);
    font-weight: 600;
    color: var(--text-dark);
}

.form-group input {
    width: 100%;
    padding: var(--spacing-md);
    border: 1px solid var(--gray-300);
    border-radius: var(--radius-md);
    font-size: 1rem;
    transition: var(--transition);
}

.form-group input:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.form-footer {
    text-align: center;
    margin-top: var(--spacing-lg);
    color: var(--text-light);
}

.form-footer a {
    color: var(--primary-color);
    font-weight: 600;
}

/* ============================================
   FOOTER
   ============================================ */

.footer {
    background: var(--dark-bg);
    color: white;
    padding: var(--spacing-xl) 0;
    text-align: center;
    margin-top: var(--spacing-2xl);
}

.footer p {
    margin: var(--spacing-sm) 0;
    color: rgba(255, 255, 255, 0.8);
}

/* ============================================
   RESPONSIVO
   ============================================ */

@media (max-width: 768px) {
    .nav-links {
        gap: var(--spacing-md);
    }

    .hero-content {
        grid-template-columns: 1fr;
    }

    .hero-text h1 {
        font-size: 2.5rem;
    }

    .hero-buttons {
        flex-direction: column;
    }

    .hero-visual {
        grid-template-columns: 1fr;
    }

    .features-grid {
        grid-template-columns: 1fr;
    }

    .steps {
        grid-template-columns: 1fr;
    }

    .modal-content {
        padding: var(--spacing-lg);
    }
}

@media (max-width: 480px) {
    h1 {
        font-size: 2rem;
    }

    .container {
        padding: 0 var(--spacing-md);
    }

    .hero-text h1 {
        font-size: 2rem;
    }

    .btn {
        padding: var(--spacing-md) var(--spacing-md);
        font-size: 0.9rem;
    }
}
