* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: linear-gradient(135deg, #0f0f23 0%, #1a1a2e 50%, #16213e 100%);
    color: #e2e8f0;
    line-height: 1.6;
    min-height: 100vh;
}

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

header {
    text-align: center;
    margin-bottom: 40px;
    color: white;
}

header h1 {
    font-size: 2.5rem;
    margin-bottom: 10px;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.3);
}

header p {
    font-size: 1.1rem;
    opacity: 0.9;
}

.main-sections {
    display: flex;
    gap: 2rem;
    align-items: flex-start;
}

.input-section, .data-table-section, .chart-section, .summary-section {
    background: rgba(30, 41, 59, 0.9);
    border: 1px solid rgba(71, 85, 105, 0.3);
    border-radius: 12px;
    padding: 30px;
    margin-bottom: 30px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.3);
    backdrop-filter: blur(10px);
}

.input-section h2, .data-table-section h2, .chart-section h2, .summary-section h2 {
    color: #f1f5f9;
    margin-bottom: 20px;
    font-size: 1.5rem;
    font-weight: 700;
}

.input-group {
    margin-bottom: 20px;
}

.input-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: 600;
    color: #cbd5e1;
}

.input-group input {
    width: 100%;
    max-width: 300px;
    padding: 12px;
    border: 2px solid rgba(71, 85, 105, 0.5);
    border-radius: 8px;
    font-size: 16px;
    background: rgba(15, 23, 42, 0.8);
    color: #e2e8f0;
    transition: all 0.3s ease;
}

.input-group input::placeholder {
    color: #64748b;
}

.input-group input:focus {
    outline: none;
    border-color: #6366f1;
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.2);
    background: rgba(15, 23, 42, 1);
}

button {
    background: linear-gradient(135deg, #6366f1 0%, #8b5cf6 100%);
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: 0 4px 12px rgba(99, 102, 241, 0.3);
}

button:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(99, 102, 241, 0.4);
    background: linear-gradient(135deg, #7c3aed 0%, #a855f7 100%);
}

button:active {
    transform: translateY(0);
}

.table-container {
    width: 100%;
    overflow-x: auto;
    margin-bottom: 20px;
}

table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 20px;
}

th, td {
    padding: 12px;
    text-align: left;
    border-bottom: 1px solid rgba(71, 85, 105, 0.3);
}

th {
    background-color: rgba(15, 23, 42, 0.8);
    font-weight: 600;
    color: #f1f5f9;
}

tr:hover {
    background-color: rgba(71, 85, 105, 0.2);
}

.delete-btn {
    background: #e53e3e;
    padding: 6px 12px;
    font-size: 14px;
}

.delete-btn:hover {
    background: #c53030;
    transform: none;
    box-shadow: none;
}

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

.chart-container {
    position: relative;
    width: 100%;
    height: 450px;
    margin-top: 20px;
}

.summary-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-top: 20px;
}

.stat-card {
    text-align: center;
    padding: 20px;
    background: linear-gradient(135deg, rgba(15, 23, 42, 0.8) 0%, rgba(30, 41, 59, 0.8) 100%);
    border-radius: 12px;
    border: 1px solid rgba(71, 85, 105, 0.3);
    backdrop-filter: blur(5px);
}

.stat-card h3 {
    color: #cbd5e1;
    margin-bottom: 10px;
    font-size: 1rem;
    font-weight: 600;
}

.stat-card span {
    font-size: 1.5rem;
    font-weight: bold;
    color: #f1f5f9;
}

.positive {
    color: #38a169 !important;
}

.negative {
    color: #e53e3e !important;
}

.neutral {
    color: #718096 !important;
}

@media (max-width: 768px) {
    .container {
        padding: 10px;
    }
    
    header h1 {
        font-size: 2rem;
    }
    
    .input-section, .data-table-section, .chart-section, .summary-section {
        padding: 20px;
    }
    
    .input-group input {
        max-width: 100%;
    }
    
    .chart-container {
        height: 300px;
    }
}

@media (max-width: 900px) {
    .main-sections {
        flex-direction: column;
        gap: 1.5rem;
    }
    .input-section, .data-table-section {
        max-width: 100%;
        min-width: 0;
    }
}

.no-data {
    text-align: center;
    color: #718096;
    padding: 40px;
    font-style: italic;
}

.error-message {
    background: rgba(220, 38, 38, 0.2);
    color: #fca5a5;
    padding: 12px;
    border-radius: 8px;
    margin-bottom: 10px;
    border: 1px solid rgba(220, 38, 38, 0.3);
    backdrop-filter: blur(5px);
}

.success-message {
    background: rgba(34, 197, 94, 0.2);
    color: #86efac;
    padding: 12px;
    border-radius: 8px;
    margin-bottom: 10px;
    border: 1px solid rgba(34, 197, 94, 0.3);
    backdrop-filter: blur(5px);
}

.info-message {
    background: rgba(59, 130, 246, 0.2);
    color: #93c5fd;
    padding: 12px;
    border-radius: 8px;
    margin-bottom: 10px;
    border: 1px solid rgba(59, 130, 246, 0.3);
    backdrop-filter: blur(5px);
}

.data-table-section {
    flex: 2 1 0;
    min-width: 0;
    width: 100%;
}

#dataTable {
    width: 100%;
}
