* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.container {
    background: white;
    border-radius: 20px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
    padding: 40px;
    max-width: 800px;
    width: 100%;
    text-align: center;
}

h1 {
    color: #333;
    font-size: 2.5rem;
    margin-bottom: 10px;
    font-weight: 300;
}

.subtitle {
    color: #666;
    font-size: 1.1rem;
    margin-bottom: 40px;
    font-weight: 400;
}

.upload-section {
    margin-bottom: 40px;
}

.file-upload-area {
    position: relative;
    width: 300px;
    height: 300px;
    margin: 0 auto;
    border: 3px dashed #667eea;
    border-radius: 20px;
    background: linear-gradient(135deg, #f8f9ff 0%, #f0f2ff 100%);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    overflow: hidden;
}

.file-upload-area:hover {
    border-color: #764ba2;
    background: linear-gradient(135deg, #f0f2ff 0%, #e8ebff 100%);
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(102, 126, 234, 0.2);
}

.file-upload-area.drag-over {
    border-color: #764ba2;
    background: linear-gradient(135deg, #e8ebff 0%, #dde1ff 100%);
    transform: scale(1.02);
}

#csvFile {
    position: absolute;
    width: 100%;
    height: 100%;
    opacity: 0;
    cursor: pointer;
}

.upload-icon {
    font-size: 4rem;
    color: #667eea;
    margin-bottom: 20px;
    transition: color 0.3s ease;
}

.file-upload-area:hover .upload-icon {
    color: #764ba2;
}

.upload-text {
    color: #333;
    font-size: 1.3rem;
    font-weight: 600;
    margin-bottom: 10px;
}

.upload-subtext {
    color: #666;
    font-size: 0.9rem;
    line-height: 1.4;
}

.preview-section {
    margin: 40px 0;
    text-align: left;
}

.preview-section h3 {
    color: #333;
    font-size: 1.5rem;
    margin-bottom: 20px;
    text-align: center;
}

#preview {
    max-height: 300px;
    overflow: auto;
    border: 1px solid #e0e0e0;
    border-radius: 10px;
    background: #fafafa;
}

table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.9rem;
}

th, td {
    padding: 12px 8px;
    text-align: left;
    border-bottom: 1px solid #e0e0e0;
}

th {
    background: #f5f5f5;
    font-weight: 600;
    color: #333;
    position: sticky;
    top: 0;
    z-index: 1;
}

td {
    color: #555;
}

tr:hover {
    background: #f9f9f9;
}

.convert-section {
    text-align: center;
}

#convertBtn {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    padding: 15px 40px;
    font-size: 1.2rem;
    font-weight: 600;
    border-radius: 50px;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 5px 15px rgba(102, 126, 234, 0.3);
}

#convertBtn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(102, 126, 234, 0.4);
}

#convertBtn:active {
    transform: translateY(0);
}

.success-message {
    background: #d4edda;
    color: #155724;
    padding: 15px;
    border-radius: 10px;
    margin: 20px 0;
    border: 1px solid #c3e6cb;
}

.error-message {
    background: #f8d7da;
    color: #721c24;
    padding: 15px;
    border-radius: 10px;
    margin: 20px 0;
    border: 1px solid #f5c6cb;
}

/* Responsive design */
@media (max-width: 768px) {
    .container {
        padding: 20px;
        margin: 10px;
    }
    
    h1 {
        font-size: 2rem;
    }
    
    .file-upload-area {
        width: 250px;
        height: 250px;
    }
    
    .upload-icon {
        font-size: 3rem;
    }
    
    .upload-text {
        font-size: 1.1rem;
    }
}

@media (max-width: 480px) {
    .file-upload-area {
        width: 200px;
        height: 200px;
    }
    
    .upload-icon {
        font-size: 2.5rem;
    }
    
    .upload-text {
        font-size: 1rem;
    }
}