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

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Microsoft JhengHei", sans-serif;
}

.tool-container {
    background: white;
    border-radius: 20px;
    box-shadow: 0 20px 60px rgba(0,0,0,0.3);
    padding: 40px;
    max-width: 800px;
    width: 100%;
    margin: 0 auto;
}

h1 {
    color: #333;
    margin-bottom: 10px;
    font-size: 28px;
    text-align: center;
}

.subtitle {
    color: #666;
    text-align: center;
    margin-bottom: 30px;
    font-size: 14px;
}

.upload-area {
    border: 3px dashed #667eea;
    border-radius: 15px;
    padding: 40px;
    text-align: center;
    margin-bottom: 30px;
    transition: all 0.3s ease;
    cursor: pointer;
    background: #f8f9ff;
}

.upload-area:hover {
    border-color: #764ba2;
    background: #f0f2ff;
}

.upload-area.dragover {
    background: #e8ebff;
    border-color: #764ba2;
}

.upload-icon {
    font-size: 48px;
    color: #667eea;
    margin-bottom: 15px;
}

.upload-text {
    color: #666;
    font-size: 16px;
    margin-bottom: 10px;
}

.file-input {
    display: none;
}

.btn {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    padding: 12px 30px;
    border-radius: 25px;
    font-size: 16px;
    cursor: pointer;
    transition: transform 0.3s ease;
    display: inline-block;
}

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

.settings {
    background: #f8f9ff;
    border-radius: 15px;
    padding: 20px;
    margin-bottom: 20px;
    display: none;
}

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

.setting-label {
    display: block;
    color: #555;
    margin-bottom: 8px;
    font-weight: 500;
}

.setting-select {
    width: 100%;
    padding: 10px;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    font-size: 14px;
    transition: border-color 0.3s ease;
}

.setting-select:focus {
    outline: none;
    border-color: #667eea;
}

.process-btn {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    padding: 15px 40px;
    border-radius: 25px;
    font-size: 18px;
    cursor: pointer;
    transition: all 0.3s ease;
    width: 100%;
    margin-top: 20px;
    display: none;
}

.process-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(102, 126, 234, 0.4);
}

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

.result {
    display: none;
    background: #f0fff4;
    border: 2px solid #4caf50;
    border-radius: 15px;
    padding: 20px;
    margin-top: 20px;
}

.result-title {
    color: #2e7d32;
    font-size: 20px;
    margin-bottom: 15px;
    font-weight: 600;
}

.result-info {
    color: #555;
    margin-bottom: 10px;
    line-height: 1.6;
}

.download-btn {
    background: linear-gradient(135deg, #4caf50 0%, #45a049 100%);
    color: white;
    border: none;
    padding: 12px 30px;
    border-radius: 25px;
    font-size: 16px;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-top: 15px;
}

.download-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(76, 175, 80, 0.4);
}

.preview-table {
    margin-top: 20px;
    overflow-x: auto;
    background: white;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.preview-title {
    font-size: 16px;
    color: #555;
    margin-bottom: 10px;
    font-weight: 600;
}

table {
    width: 100%;
    border-collapse: collapse;
    font-size: 14px;
}

th {
    background: #667eea;
    color: white;
    padding: 12px;
    text-align: left;
    font-weight: 500;
}

td {
    padding: 10px 12px;
    border-bottom: 1px solid #e0e0e0;
}

tr:hover {
    background: #f8f9ff;
}

.highlight {
    background: #fff3cd;
    font-weight: 600;
}

.error {
    background: #fee;
    border: 2px solid #f44336;
    color: #d32f2f;
    padding: 15px;
    border-radius: 10px;
    margin-top: 20px;
    display: none;
}

.loading {
    display: none;
    text-align: center;
    color: #667eea;
    font-size: 18px;
    margin: 20px 0;
}

.spinner {
    border: 3px solid #f3f3f3;
    border-top: 3px solid #667eea;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    animation: spin 1s linear infinite;
    margin: 20px auto;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

