/* Reset y Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    /* Colores principales inspirados en bplatform */
    --primary: #6366f1;
    --primary-dark: #4f46e5;
    --primary-darker: #4338ca;
    --secondary: #10b981;
    --accent: #f59e0b;
    
    /* Escala de grises moderna */
    --gray-50: #f9fafb;
    --gray-100: #f3f4f6;
    --gray-200: #e5e7eb;
    --gray-300: #d1d5db;
    --gray-400: #9ca3af;
    --gray-500: #6b7280;
    --gray-600: #4b5563;
    --gray-700: #374151;
    --gray-800: #1f2937;
    --gray-900: #111827;
    
    /* Gradientes */
    --gradient-primary: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    --gradient-dark: linear-gradient(135deg, var(--gray-800) 0%, var(--gray-900) 100%);
    --gradient-success: linear-gradient(135deg, var(--secondary) 0%, #059669 100%);
    
    /* Efectos */
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    
    /* Bordes */
    --radius-sm: 6px;
    --radius-md: 8px;
    --radius-lg: 12px;
    --radius-xl: 16px;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    line-height: 1.6;
    color: var(--gray-100);
    background: var(--gray-900);
}

.background-gradient {
    background: var(--gradient-dark);
    min-height: 100vh;
}

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

/* Header Styles */
.main-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 24px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.logo {
    display: flex;
    align-items: center;
    gap: 12px;
    font-weight: 700;
    font-size: 24px;
    color: white;
}

.logo-icon {
    background: var(--gradient-primary);
    padding: 8px;
    border-radius: var(--radius-md);
    font-size: 20px;
}

.nav-links {
    display: flex;
    gap: 32px;
}

.nav-link {
    color: var(--gray-400);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.2s;
}

.nav-link:hover,
.nav-link.active {
    color: white;
}

/* Hero Section */
.hero-section {
    padding: 80px 0 60px;
    text-align: center;
}

.hero-title {
    font-size: 3.5rem;
    font-weight: 700;
    line-height: 1.1;
    margin-bottom: 24px;
    background: linear-gradient(135deg, white 0%, var(--gray-300) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

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

.hero-subtitle {
    font-size: 1.25rem;
    color: var(--gray-400);
    max-width: 600px;
    margin: 0 auto 60px;
    line-height: 1.6;
}

/* Upload Card */
.upload-card {
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: var(--radius-xl);
    padding: 40px;
    max-width: 600px;
    margin: 0 auto 60px;
    box-shadow: var(--shadow-xl);
}

.card-header {
    text-align: center;
    margin-bottom: 32px;
}

.card-icon {
    font-size: 48px;
    margin-bottom: 16px;
}

.card-header h3 {
    font-size: 1.5rem;
    font-weight: 600;
    color: white;
}

/* File Upload */
.file-upload-area {
    border: 2px dashed rgba(255, 255, 255, 0.2);
    border-radius: var(--radius-lg);
    padding: 48px 32px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s;
    margin-bottom: 20px;
}

.file-upload-area:hover,
.file-upload-area.drag-over {
    border-color: var(--primary);
    background: rgba(99, 102, 241, 0.05);
}

.upload-icon {
    font-size: 48px;
    margin-bottom: 16px;
    opacity: 0.7;
}

.upload-text {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.primary-text {
    font-weight: 600;
    color: white;
    font-size: 1.125rem;
}

.secondary-text {
    color: var(--gray-400);
    font-size: 0.875rem;
}

.file-input {
    display: none;
}

.file-info {
    background: rgba(255, 255, 255, 0.05);
    border-radius: var(--radius-md);
    padding: 12px 16px;
    margin-bottom: 24px;
    display: none;
}

.file-name {
    color: var(--gray-300);
    font-weight: 500;
}

/* Buttons */
.generate-btn {
    width: 100%;
    background: var(--gradient-primary);
    color: white;
    border: none;
    padding: 16px 32px;
    border-radius: var(--radius-lg);
    font-size: 1.125rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
}

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

.btn-icon {
    font-size: 1.25rem;
}

/* Features Grid */
.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 24px;
    max-width: 900px;
    margin: 0 auto;
}

.feature-card {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: var(--radius-lg);
    padding: 32px 24px;
    text-align: center;
    transition: all 0.3s;
}

.feature-card:hover {
    transform: translateY(-4px);
    border-color: var(--primary);
}

.feature-icon {
    font-size: 2rem;
    margin-bottom: 16px;
}

.feature-card h4 {
    color: white;
    margin-bottom: 8px;
    font-weight: 600;
}

.feature-card p {
    color: var(--gray-400);
    font-size: 0.875rem;
}

/* Instructions Section */
.instructions-section {
    padding: 60px 0;
}

.instructions-card {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: var(--radius-xl);
    padding: 40px;
    max-width: 800px;
    margin: 0 auto;
}

.instructions-card h3 {
    color: white;
    margin-bottom: 24px;
    font-size: 1.5rem;
}

.code-example {
    background: var(--gray-800);
    border: 1px solid var(--gray-700);
    border-radius: var(--radius-lg);
    padding: 24px;
    margin-bottom: 24px;
    overflow-x: auto;
}

.code-example pre {
    color: var(--gray-300);
    font-family: 'Monaco', 'Consolas', monospace;
    font-size: 0.875rem;
    line-height: 1.5;
}

.requirements h4 {
    color: white;
    margin-bottom: 16px;
}

.requirements ul {
    list-style: none;
    display: grid;
    gap: 8px;
}

.requirements li {
    color: var(--gray-300);
    display: flex;
    align-items: center;
    gap: 12px;
}

/* Results Page Styles */
.results-section {
    padding: 60px 0;
}

.success-card {
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: var(--radius-xl);
    padding: 48px;
    box-shadow: var(--shadow-xl);
}

.success-header {
    display: flex;
    align-items: center;
    gap: 24px;
    margin-bottom: 40px;
    text-align: left;
}

.success-icon {
    font-size: 3rem;
    background: var(--gradient-success);
    padding: 16px;
    border-radius: var(--radius-xl);
}

.success-content h1 {
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 8px;
    color: white;
}

.success-content p {
    color: var(--gray-400);
    font-size: 1.125rem;
}

.highlight {
    color: var(--secondary);
    font-weight: 600;
}

/* Actions Grid */
.actions-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 24px;
    margin-bottom: 40px;
}

.action-card {
    display: flex;
    align-items: center;
    gap: 20px;
    padding: 24px;
    border-radius: var(--radius-lg);
    text-decoration: none;
    transition: all 0.3s;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.primary-action {
    background: rgba(99, 102, 241, 0.1);
    border-color: rgba(99, 102, 241, 0.3);
}

.secondary-action {
    background: rgba(255, 255, 255, 0.05);
}

.action-card:hover {
    transform: translateY(-2px);
    border-color: var(--primary);
}

.action-icon {
    font-size: 2rem;
}

.action-content h3 {
    color: white;
    margin-bottom: 4px;
    font-weight: 600;
}

.action-content p {
    color: var(--gray-400);
    font-size: 0.875rem;
}

.action-arrow {
    margin-left: auto;
    font-size: 1.5rem;
    color: var(--gray-400);
}

/* Files Section */
.files-section {
    margin-bottom: 40px;
}

.files-section h3 {
    color: white;
    margin-bottom: 24px;
    font-size: 1.25rem;
}

.files-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.file-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 20px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: var(--radius-lg);
    transition: all 0.2s;
}

.file-item:hover {
    border-color: var(--primary);
}

.file-info {
    display: flex;
    align-items: center;
    gap: 12px;
}

.file-icon {
    font-size: 1.25rem;
}

.file-name {
    color: var(--gray-300);
    font-weight: 500;
}

.file-actions {
    display: flex;
    gap: 8px;
}

.btn-small {
    padding: 8px 16px;
    border-radius: var(--radius-md);
    font-size: 0.875rem;
    font-weight: 500;
    text-decoration: none;
    transition: all 0.2s;
    border: 1px solid transparent;
}

.preview-btn {
    background: rgba(255, 255, 255, 0.1);
    color: white;
    border-color: rgba(255, 255, 255, 0.2);
}

.download-btn {
    background: var(--gradient-primary);
    color: white;
}

.btn-small:hover {
    transform: translateY(-1px);
}

/* Stats Grid */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 40px;
}

.stat-card {
    text-align: center;
    padding: 20px;
}

.stat-number {
    font-size: 2rem;
    font-weight: 700;
    color: white;
    margin-bottom: 8px;
}

.stat-label {
    color: var(--gray-400);
    font-size: 0.875rem;
}

/* Responsive Design */
@media (max-width: 768px) {
    .hero-title {
        font-size: 2.5rem;
    }
    
    .upload-card {
        padding: 24px;
    }
    
    .file-upload-area {
        padding: 32px 20px;
    }
    
    .main-header {
        flex-direction: column;
        gap: 16px;
    }
    
    .nav-links {
        gap: 20px;
    }
    
    .success-header {
        flex-direction: column;
        text-align: center;
    }
    
    .file-item {
        flex-direction: column;
        gap: 16px;
        align-items: flex-start;
    }
    
    .file-actions {
        width: 100%;
        justify-content: flex-end;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 16px;
    }
    
    .hero-title {
        font-size: 2rem;
    }
    
    .features-grid {
        grid-template-columns: 1fr;
    }
    
    .actions-grid {
        grid-template-columns: 1fr;
    }
}
/* Audit Section Styles */
.audit-section {
    padding: 60px 0;
}

.audit-card {
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: var(--radius-xl);
    padding: 40px;
    box-shadow: var(--shadow-xl);
}

.audit-header {
    text-align: center;
    margin-bottom: 32px;
}

.audit-header h1 {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 16px;
    color: white;
}

.audit-header p {
    color: var(--gray-400);
    font-size: 1.125rem;
}

/* File Selector */
.file-selector {
    background: rgba(255, 255, 255, 0.05);
    border-radius: var(--radius-lg);
    padding: 20px;
    margin-bottom: 24px;
}

.file-selector label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: white;
}

.file-selector select {
    width: 100%;
    padding: 12px 16px;
    background: var(--gray-800);
    border: 1px solid var(--gray-700);
    border-radius: var(--radius-md);
    color: white;
    font-size: 1rem;
}

.file-selector select:focus {
    outline: none;
    border-color: var(--primary);
}

/* Log Content */
.log-content {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: var(--radius-lg);
    overflow: hidden;
}

.log-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 20px;
    background: rgba(255, 255, 255, 0.05);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.log-header h3 {
    color: white;
    margin: 0;
    font-size: 1.125rem;
}

.log-actions {
    display: flex;
    gap: 8px;
}

.btn-danger {
    background: #ef4444 !important;
}

.btn-danger:hover {
    background: #dc2626 !important;
}

.log-entries {
    max-height: 500px;
    overflow-y: auto;
    padding: 20px;
}

.log-entries pre {
    color: var(--gray-300);
    font-family: 'Monaco', 'Consolas', monospace;
    font-size: 0.875rem;
    line-height: 1.5;
    margin: 0;
    white-space: pre-wrap;
    word-wrap: break-word;
}

.no-logs, .no-file-selected {
    text-align: center;
    padding: 40px;
    color: var(--gray-400);
}

/* Stats Section */
.stats-section {
    margin-top: 32px;
    padding-top: 32px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.stats-section h3 {
    color: white;
    margin-bottom: 20px;
    text-align: center;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 16px;
}

.stat-card {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: var(--radius-lg);
    padding: 20px;
    text-align: center;
}

.stat-number {
    font-size: 1.75rem;
    font-weight: 700;
    color: white;
    margin-bottom: 8px;
}

.stat-label {
    color: var(--gray-400);
    font-size: 0.875rem;
}

/* Responsive Design */
@media (max-width: 768px) {
    .log-header {
        flex-direction: column;
        gap: 16px;
        text-align: center;
    }
    
    .audit-header h1 {
        font-size: 2rem;
    }
    
    .stats-grid {
        grid-template-columns: 1fr;
    }
}