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

:root {
    --primary: #667eea;
    --primary-dark: #5568d3;
    --secondary: #764ba2;
    --success: #10b981;
    --danger: #ef4444;
    --warning: #f59e0b;
    --dark: #1f2937;
    --light: #f9fafb;
    --border: #e5e7eb;
    --shadow: rgba(0, 0, 0, 0.1);
    --shadow-lg: rgba(0, 0, 0, 0.2);
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    padding: 20px;
    line-height: 1.6;
}

.container {
    max-width: 900px;
    margin: 0 auto;
}

/* ============================================
   HEADER
   ============================================ */
.header {
    text-align: center;
    margin-bottom: 40px;
    animation: fadeInDown 0.6s ease;
}

.logo {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px;
    margin-bottom: 10px;
}

.emoji {
    font-size: 48px;
    animation: bounce 2s infinite;
}

.header h1 {
    color: white;
    font-size: 42px;
    font-weight: 700;
    letter-spacing: 2px;
}

.highlight {
    color: #fbbf24;
}

.subtitle {
    color: rgba(255, 255, 255, 0.9);
    font-size: 18px;
    font-weight: 300;
}

/* ============================================
   NAVEGACIÓN
   ============================================ */
.main-nav {
    display: flex;
    gap: 15px;
    justify-content: center;
    margin-top: 25px;
    flex-wrap: wrap;
}

.nav-btn {
    padding: 12px 24px;
    background: rgba(255, 255, 255, 0.2);
    color: white;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 12px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    backdrop-filter: blur(10px);
}

.nav-btn:hover {
    background: rgba(255, 255, 255, 0.3);
    border-color: rgba(255, 255, 255, 0.5);
    transform: translateY(-2px);
}

.nav-btn.active {
    background: white;
    color: var(--primary);
    border-color: white;
    box-shadow: 0 4px 15px rgba(255, 255, 255, 0.3);
}

.nav-btn.disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.nav-btn.disabled:hover {
    transform: none;
}

/* Ocultar secciones por defecto */
.stats-card,
.history-card,
.comparator-card {
    display: none;
}

/* Mostrar solo la sección activa */
.section-active {
    display: block !important;
}

/* ============================================
   CARDS
   ============================================ */
.card {
    background: white;
    border-radius: 20px;
    box-shadow: 0 10px 40px var(--shadow-lg);
    margin-bottom: 30px;
    overflow: hidden;
    animation: fadeInUp 0.6s ease;
}

.card-header {
    background: linear-gradient(135deg, var(--primary) 0%, var(--secondary) 100%);
    color: white;
    padding: 25px 30px;
}

.card-header h2 {
    font-size: 24px;
    margin-bottom: 8px;
}

.card-header p {
    opacity: 0.9;
    font-size: 14px;
}

.card-body {
    padding: 30px;
}

/* ============================================
   FORM ELEMENTS
   ============================================ */
.form-group {
    margin-bottom: 25px;
}

.form-label {
    display: block;
    font-weight: 600;
    color: var(--dark);
    margin-bottom: 10px;
    font-size: 15px;
}

.form-select {
    width: 100%;
    padding: 12px 15px;
    border: 2px solid var(--border);
    border-radius: 10px;
    font-size: 15px;
    background: white;
    cursor: pointer;
    transition: all 0.3s;
}

.form-select:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.form-textarea {
    width: 100%;
    padding: 15px;
    border: 2px solid var(--border);
    border-radius: 10px;
    font-size: 15px;
    font-family: inherit;
    resize: vertical;
    transition: all 0.3s;
}

.form-textarea:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.char-count {
    text-align: right;
    color: #6b7280;
    font-size: 13px;
    margin-top: 5px;
}

/* ============================================
   THRESHOLD SLIDER
   ============================================ */
.threshold-value {
    background: var(--primary);
    color: white;
    padding: 4px 12px;
    border-radius: 20px;
    font-weight: 600;
    font-size: 14px;
    margin-left: 10px;
}

.form-range {
    width: 100%;
    height: 8px;
    border-radius: 5px;
    background: linear-gradient(to right, #10b981 0%, #fbbf24 50%, #ef4444 100%);
    outline: none;
    -webkit-appearance: none;
    appearance: none;
    margin: 15px 0;
}

.form-range::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: white;
    cursor: pointer;
    border: 3px solid var(--primary);
    box-shadow: 0 2px 10px var(--shadow);
    transition: all 0.3s;
}

.form-range::-webkit-slider-thumb:hover {
    transform: scale(1.2);
}

.form-range::-moz-range-thumb {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: white;
    cursor: pointer;
    border: 3px solid var(--primary);
    box-shadow: 0 2px 10px var(--shadow);
}

.threshold-labels {
    display: flex;
    justify-content: space-between;
    font-size: 12px;
    color: #6b7280;
    margin-top: 5px;
}

.threshold-info {
    background: #eff6ff;
    border-left: 4px solid #3b82f6;
    padding: 12px 15px;
    border-radius: 8px;
    font-size: 13px;
    color: #1e40af;
    margin-top: 15px;
}

/* ============================================
   OPCIONES AVANZADAS
   ============================================ */
.advanced-options {
    margin: 25px 0;
}

.toggle-advanced {
    width: 100%;
    padding: 12px;
    background: var(--light);
    border: 2px solid var(--border);
    border-radius: 10px;
    font-size: 15px;
    font-weight: 600;
    color: var(--dark);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: space-between;
    transition: all 0.3s;
}

.toggle-advanced:hover {
    background: #f3f4f6;
    border-color: var(--primary);
}

.arrow {
    transition: transform 0.3s;
}

.arrow.rotated {
    transform: rotate(180deg);
}

.advanced-content {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s ease;
    padding: 0 15px;
}

.advanced-content.show {
    max-height: 600px;
    padding: 20px 15px;
}

/* ============================================
   BUTTONS
   ============================================ */
.btn-primary {
    width: 100%;
    padding: 16px;
    background: linear-gradient(135deg, var(--primary) 0%, var(--secondary) 100%);
    color: white;
    border: none;
    border-radius: 12px;
    font-size: 16px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s;
    text-transform: uppercase;
    letter-spacing: 1px;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.4);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.6);
}

.btn-primary:disabled {
    background: #9ca3af;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

.btn-secondary {
    padding: 12px 24px;
    background: white;
    color: var(--primary);
    border: 2px solid var(--primary);
    border-radius: 10px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
}

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

.spinner {
    display: inline-block;
    width: 16px;
    height: 16px;
    border: 3px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    border-top-color: white;
    animation: spin 0.8s linear infinite;
}

/* ============================================
   RESULTS
   ============================================ */
.result-card {
    animation: slideInUp 0.5s ease;
}

.result-main {
    text-align: center;
    padding: 30px;
    background: linear-gradient(135deg, #f0f9ff 0%, #e0f2fe 100%);
    border-radius: 15px;
    margin-bottom: 25px;
}

.result-emoji {
    font-size: 80px;
    margin-bottom: 15px;
    animation: scaleIn 0.5s ease;
}

.result-sentiment {
    font-size: 36px;
    font-weight: 700;
    margin-bottom: 10px;
}

.result-sentiment.positivo {
    color: var(--success);
}

.result-sentiment.negativo {
    color: var(--danger);
}

.result-metrics {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-bottom: 25px;
}

.metric-card {
    background: var(--light);
    padding: 20px;
    border-radius: 12px;
    text-align: center;
    border: 2px solid var(--border);
}

.metric-label {
    font-size: 14px;
    color: #6b7280;
    margin-bottom: 8px;
}

.metric-value {
    font-size: 28px;
    font-weight: 700;
    color: var(--primary);
}

.result-text {
    background: white;
    padding: 20px;
    border-radius: 12px;
    border: 2px solid var(--border);
    margin-bottom: 20px;
}

.result-text h3 {
    font-size: 16px;
    color: var(--dark);
    margin-bottom: 10px;
}

.result-text p {
    color: #4b5563;
    font-size: 15px;
    line-height: 1.6;
}

.result-config {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
    margin-bottom: 20px;
}

.config-item {
    background: var(--light);
    padding: 10px 20px;
    border-radius: 8px;
    font-size: 14px;
}

.config-label {
    font-weight: 600;
    color: #6b7280;
    margin-right: 8px;
}

.config-value {
    color: var(--primary);
    font-weight: 700;
}

.result-actions {
    display: flex;
    gap: 15px;
    justify-content: center;
    flex-wrap: wrap;
}

/* ============================================
   ERROR CARD
   ============================================ */
.error-card {
    animation: shake 0.5s ease;
}

.error-content {
    text-align: center;
    padding: 40px;
}

.error-icon {
    font-size: 64px;
    margin-bottom: 20px;
}

.error-content h3 {
    color: var(--danger);
    font-size: 24px;
    margin-bottom: 15px;
}

.error-content p {
    color: #6b7280;
    margin-bottom: 25px;
}

/* ============================================
   ESTADÍSTICAS DE SESIÓN
   ============================================ */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.stat-item {
    background: linear-gradient(135deg, #f0f9ff 0%, #e0f2fe 100%);
    padding: 25px;
    border-radius: 15px;
    text-align: center;
    border: 2px solid #bfdbfe;
    transition: all 0.3s;
}

.stat-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(102, 126, 234, 0.2);
}

.stat-item.positive {
    background: linear-gradient(135deg, #d1fae5 0%, #a7f3d0 100%);
    border-color: #6ee7b7;
}

.stat-item.negative {
    background: linear-gradient(135deg, #fee2e2 0%, #fecaca 100%);
    border-color: #fca5a5;
}

.stat-icon {
    font-size: 36px;
    margin-bottom: 10px;
}

.stat-value {
    font-size: 32px;
    font-weight: 700;
    color: var(--primary);
    margin-bottom: 5px;
}

.stat-item.positive .stat-value {
    color: var(--success);
}

.stat-item.negative .stat-value {
    color: var(--danger);
}

.stat-label {
    font-size: 14px;
    color: #6b7280;
    font-weight: 600;
}

.stats-chart {
    background: white;
    padding: 20px;
    border-radius: 15px;
    border: 2px solid var(--border);
    max-width: 400px;
    margin: 0 auto;
}

/* ============================================
   HISTORIAL DE ANÁLISIS
   ============================================ */
.btn-small {
    padding: 8px 16px;
    font-size: 13px;
}

.history-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.history-item {
    background: var(--light);
    padding: 20px;
    border-radius: 12px;
    border: 2px solid var(--border);
    display: grid;
    grid-template-columns: auto 1fr auto;
    gap: 20px;
    align-items: center;
    transition: all 0.3s;
    animation: slideInRight 0.3s ease;
}

.history-item:hover {
    border-color: var(--primary);
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.1);
}

.history-emoji {
    font-size: 36px;
}

.history-details {
    flex: 1;
}

.history-sentiment {
    font-size: 18px;
    font-weight: 700;
    margin-bottom: 5px;
}

.history-sentiment.positivo {
    color: var(--success);
}

.history-sentiment.negativo {
    color: var(--danger);
}

.history-text {
    font-size: 14px;
    color: #6b7280;
    margin-bottom: 8px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.history-meta {
    display: flex;
    gap: 15px;
    font-size: 12px;
    color: #9ca3af;
}

.history-actions {
    display: flex;
    gap: 10px;
}

.btn-icon {
    width: 40px;
    height: 40px;
    border-radius: 10px;
    border: 2px solid var(--border);
    background: white;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    transition: all 0.3s;
}

.btn-icon:hover {
    border-color: var(--primary);
    background: var(--primary);
    transform: scale(1.1);
}

.empty-history {
    text-align: center;
    padding: 60px 20px;
    color: #9ca3af;
}

.empty-history p {
    margin-bottom: 10px;
}

/* ============================================
   COMPARADOR DE THRESHOLD
   ============================================ */
.comparison-results {
    margin-top: 30px;
    animation: fadeInUp 0.5s ease;
}

.comparison-results h3 {
    font-size: 18px;
    color: var(--dark);
    margin-bottom: 20px;
}

.comparison-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 20px;
}

.comparison-item {
    background: var(--light);
    border-radius: 15px;
    overflow: hidden;
    border: 2px solid var(--border);
    transition: all 0.3s;
}

.comparison-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
}

.comparison-header {
    padding: 15px;
    background: white;
    border-bottom: 2px solid var(--border);
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.threshold-badge {
    display: inline-block;
    padding: 6px 12px;
    border-radius: 20px;
    font-weight: 700;
    font-size: 13px;
    width: fit-content;
}

.threshold-badge.low {
    background: #d1fae5;
    color: #065f46;
}

.threshold-badge.medium {
    background: #fef3c7;
    color: #92400e;
}

.threshold-badge.high {
    background: #fee2e2;
    color: #991b1b;
}

.threshold-note {
    font-size: 12px;
    color: #6b7280;
    font-style: italic;
}

.comparison-result {
    padding: 25px;
    text-align: center;
}

.comp-sentiment {
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 10px;
}

.comp-sentiment.positivo {
    color: var(--success);
}

.comp-sentiment.negativo {
    color: var(--danger);
}

.comp-probability {
    font-size: 18px;
    color: #6b7280;
}

/* ============================================
   EXPLICABILIDAD
   ============================================ */
.explain-content {
    display: flex;
    flex-direction: column;
    gap: 30px;
}

.explain-text {
    background: white;
    padding: 25px;
    border-radius: 15px;
    border: 2px solid var(--border);
    font-size: 16px;
    line-height: 1.8;
}

.explain-text .word-highlight {
    padding: 2px 6px;
    border-radius: 4px;
    font-weight: 600;
    transition: all 0.2s;
    cursor: help;
}

.explain-text .word-highlight.positive {
    background: rgba(16, 185, 129, 0.2);
    color: #065f46;
}

.explain-text .word-highlight.negative {
    background: rgba(239, 68, 68, 0.2);
    color: #991b1b;
}

.explain-text .word-highlight:hover {
    transform: scale(1.05);
}

.top-words h3 {
    font-size: 18px;
    color: var(--dark);
    margin-bottom: 15px;
}

.words-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 15px;
}

.word-item {
    background: var(--light);
    padding: 15px;
    border-radius: 12px;
    border: 2px solid var(--border);
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: all 0.3s;
}

.word-item:hover {
    border-color: var(--primary);
    transform: translateX(5px);
}

.word-item.positive {
    border-left: 4px solid var(--success);
}

.word-item.negative {
    border-left: 4px solid var(--danger);
}

.word-name {
    font-weight: 600;
    color: var(--dark);
    font-size: 15px;
}

.word-score {
    background: var(--primary);
    color: white;
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 700;
}

/* ============================================
   ANIMACIONES ADICIONALES
   ============================================ */
@keyframes slideInRight {
    from {
        opacity: 0;
        transform: translateX(30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* ============================================
   RESPONSIVE ADICIONAL
   ============================================ */
@media (max-width: 768px) {
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .comparison-grid {
        grid-template-columns: 1fr;
    }
    
    .history-item {
        grid-template-columns: auto 1fr;
        gap: 15px;
    }
    
    .history-actions {
        grid-column: 1 / -1;
        justify-content: center;
    }
    
    .words-grid {
        grid-template-columns: 1fr;
    }
}


/* ============================================
   ESTADÍSTICAS BATCH MEJORADAS
   ============================================ */
#batchResults .stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin: 30px 0;
}

#batchResults .stat-card {
    background: linear-gradient(135deg, #ffffff 0%, #f8fafc 100%);
    padding: 25px;
    border-radius: 15px;
    text-align: center;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border: 2px solid transparent;
}

#batchResults .stat-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

#batchResults .stat-card.positive {
    border-color: var(--success);
    background: linear-gradient(135deg, #dcfce7 0%, #f0fdf4 100%);
}

#batchResults .stat-card.negative {
    border-color: var(--danger);
    background: linear-gradient(135deg, #fee2e2 0%, #fef2f2 100%);
}

#batchResults .stat-value {
    font-size: 42px;
    font-weight: 800;
    margin-bottom: 8px;
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

#batchResults .stat-card.positive .stat-value {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

#batchResults .stat-card.negative .stat-value {
    background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

#batchResults .stat-label {
    font-size: 14px;
    font-weight: 600;
    color: #6b7280;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}


/* Spinner pequeño para batch */
#batchLoader .spinner {
    width: 24px;
    height: 24px;
    border: 3px solid #e5e7eb;
    border-top-color: var(--primary);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

/* Animación de pulso para la barra */
@keyframes pulse-bar {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.8;
    }
}

#progressBar {
    animation: pulse-bar 2s ease-in-out infinite;
}


/* ============================================
   GRÁFICO BATCH RESPONSIVE
   ============================================ */
@media (max-width: 968px) {
    #batchResults > div:nth-child(2) {
        grid-template-columns: 1fr !important;
        gap: 20px !important;
    }
    
    #batchChart {
        max-width: 100%;
        height: auto;
    }
}

/* Mejorar stat-cards en batch */
#batchResults .stat-card {
    background: linear-gradient(135deg, #ffffff 0%, #f8fafc 100%);
    padding: 20px;
    border-radius: 12px;
    text-align: center;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border: 2px solid transparent;
}

#batchResults .stat-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

#batchResults .stat-card.positive {
    border-color: #10b981;
    background: linear-gradient(135deg, #dcfce7 0%, #f0fdf4 100%);
}

#batchResults .stat-card.negative {
    border-color: #ef4444;
    background: linear-gradient(135deg, #fee2e2 0%, #fef2f2 100%);
}

#batchResults .stat-value {
    font-size: 36px;
    font-weight: 800;
    margin-bottom: 8px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

#batchResults .stat-card.positive .stat-value {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

#batchResults .stat-card.negative .stat-value {
    background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

#batchResults .stat-label {
    font-size: 13px;
    font-weight: 600;
    color: #6b7280;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}


/* ============================================
   INPUT DE ARCHIVO PERSONALIZADO
   ============================================ */
.file-input-wrapper {
    display: flex;
    align-items: center;
    gap: 15px;
    flex-wrap: wrap;
}

.file-input-hidden {
    display: none;
}

.file-input-button {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 14px 28px;
    border: none;
    border-radius: 10px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.3);
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.file-input-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.4);
}

.file-input-button:active {
    transform: translateY(0);
}

.file-input-name {
    flex: 1;
    padding: 12px 16px;
    background: #f3f4f6;
    border-radius: 8px;
    color: #6b7280;
    font-size: 14px;
    font-style: italic;
    border: 2px dashed #d1d5db;
    min-width: 200px;
}

.file-input-name.selected {
    background: #dcfce7;
    color: #166534;
    border-color: #10b981;
    font-style: normal;
    font-weight: 500;
}

/* ============================================
   SELECT PERSONALIZADO
   ============================================ */
.select-wrapper {
    position: relative;
    display: inline-block;
    width: 100%;
    max-width: 400px;
}

.select-styled {
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    width: 100%;
    padding: 14px 45px 14px 16px;
    font-size: 15px;
    font-weight: 500;
    color: #374151;
    background: white;
    border: 2px solid #e5e7eb;
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.select-styled:hover {
    border-color: var(--primary);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.15);
}

.select-styled:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.select-arrow {
    position: absolute;
    right: 16px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--primary);
    pointer-events: none;
    font-size: 12px;
    transition: transform 0.3s ease;
}

.select-wrapper:hover .select-arrow {
    transform: translateY(-50%) scale(1.2);
}

/* Responsive */
@media (max-width: 768px) {
    .file-input-wrapper {
        flex-direction: column;
        align-items: stretch;
    }
    
    .file-input-button {
        width: 100%;
        justify-content: center;
    }
    
    .file-input-name {
        width: 100%;
        text-align: center;
    }
    
    .select-wrapper {
        max-width: 100%;
    }
}




/* ============================================
   FOOTER
   ============================================ */
.footer {
    text-align: center;
    color: white;
    padding: 30px 0;
    margin-top: 40px;
}

.footer p {
    margin-bottom: 10px;
}

.footer-links {
    display: flex;
    justify-content: center;
    gap: 20px;
    flex-wrap: wrap;
}

.footer-links a {
    color: white;
    text-decoration: none;
    transition: all 0.3s;
    opacity: 0.8;
}

.footer-links a:hover {
    opacity: 1;
    transform: translateY(-2px);
}

/* ============================================
   ANIMATIONS
   ============================================ */
@keyframes fadeInDown {
    from {
        opacity: 0;
        transform: translateY(-30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

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

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

@keyframes bounce {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-10px);
    }
}

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

@keyframes scaleIn {
    from {
        transform: scale(0);
    }
    to {
        transform: scale(1);
    }
}

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    25% { transform: translateX(-10px); }
    75% { transform: translateX(10px); }
}

/* ============================================
   RESPONSIVE
   ============================================ */
@media (max-width: 768px) {
    body {
        padding: 10px;
    }
    
    .header h1 {
        font-size: 32px;
    }
    
    .emoji {
        font-size: 36px;
    }
    
    .card-body {
        padding: 20px;
    }
    
    .result-emoji {
        font-size: 60px;
    }
    
    .result-sentiment {
        font-size: 28px;
    }
    
    .result-actions {
        flex-direction: column;
    }
    
    .btn-secondary {
        width: 100%;
    }
}