* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

body {
    background: linear-gradient(135deg, #1a2a6c, #b21f1f, #fdbb2d);
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 20px;
}

.container {
    max-width: 1100px;
    width: 100%;
    background: rgba(255, 255, 255, 0.95);
    border-radius: 12px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    overflow: hidden;
}

header {
    background: linear-gradient(to right, #1a2a6c, #b21f1f);
    color: white;
    padding: 25px 30px;
    text-align: center;
    position: relative;
}

h1 {
    font-size: 32px;
    margin-bottom: 10px;
    text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.3);
}

.subtitle {
    font-size: 16px;
    opacity: 0.9;
}

.powerball-icon {
    position: absolute;
    top: 20px;
    right: 30px;
    font-size: 40px;
}

.content {
    padding: 30px;
}

.upload-area {
    border: 2px dashed #b21f1f;
    border-radius: 8px;
    padding: 40px 20px;
    text-align: center;
    margin-bottom: 25px;
    transition: all 0.3s;
    background: #f9f9f9;
    cursor: pointer;
}

.upload-area:hover {
    border-color: #1a2a6c;
    background: #f0f4ff;
}

.upload-area.highlight {
    border-color: #1a2a6c;
    background: #e8edff;
}

.upload-icon {
    font-size: 48px;
    color: #b21f1f;
    margin-bottom: 15px;
}

.upload-text {
    font-size: 18px;
    margin-bottom: 10px;
    color: #333;
}

.file-input {
    display: none;
}

.browse-btn {
    background: linear-gradient(to right, #1a2a6c, #b21f1f);
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: 5px;
    cursor: pointer;
    font-size: 16px;
    transition: all 0.3s;
    margin-top: 10px;
    font-weight: 600;
}

.browse-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

.file-info {
    margin-top: 15px;
    font-size: 14px;
    color: #666;
}

.file-list {
    background: #f0f7ff;
    border-radius: 8px;
    padding: 15px;
    margin-bottom: 20px;
    max-height: 200px;
    overflow-y: auto;
    display: none;
}

.file-list h3 {
    color: #1a2a6c;
    margin-bottom: 10px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.file-count {
    background: #b21f1f;
    color: white;
    padding: 2px 8px;
    border-radius: 12px;
    font-size: 14px;
}

.file-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 10px;
    background: white;
    margin-bottom: 5px;
    border-radius: 4px;
    border-left: 4px solid #1a2a6c;
}

.file-name {
    flex: 1;
    font-weight: 500;
}

.file-size {
    color: #666;
    font-size: 12px;
    margin-right: 10px;
}

.remove-file {
    background: #b21f1f;
    color: white;
    border: none;
    border-radius: 50%;
    width: 24px;
    height: 24px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
}

.remove-file:hover {
    background: #8a1818;
}

.excel-layout {
    background: #f0f7ff;
    border-radius: 8px;
    padding: 20px;
    margin-bottom: 25px;
}

.excel-layout h3 {
    color: #1a2a6c;
    margin-bottom: 15px;
    text-align: center;
}

.layout-visual {
    display: flex;
    justify-content: center;
    margin-bottom: 15px;
}

.column {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin: 0 5px;
}

.column-header {
    background: #1a2a6c;
    color: white;
    padding: 8px 12px;
    border-radius: 4px 4px 0 0;
    font-weight: 600;
    width: 100px;
    text-align: center;
}

.column-cells {
    display: flex;
    flex-direction: column;
}

.cell {
    width: 100px;
    height: 30px;
    background: white;
    border: 1px solid #ddd;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
}

.column-a .column-header { background: #1a2a6c; }
.columns-b-f .column-header { background: #fdbb2d; color: #333; }
.column-g .column-header { background: #48bb78; }

.layout-description {
    text-align: center;
    color: #444;
    font-size: 14px;
}

.instructions {
    background: #f0f7ff;
    border-left: 4px solid #1a2a6c;
    padding: 15px;
    margin-bottom: 25px;
    border-radius: 0 8px 8px 0;
}

.instructions h3 {
    color: #1a2a6c;
    margin-bottom: 10px;
}

.instructions ul {
    padding-left: 20px;
}

.instructions li {
    margin-bottom: 8px;
    color: #444;
}

.format-preview {
    background: #f9f9f9;
    border: 1px solid #ddd;
    border-radius: 8px;
    padding: 15px;
    margin-bottom: 25px;
    font-family: monospace;
    white-space: pre-wrap;
    font-size: 14px;
    line-height: 1.5;
}

.action-buttons {
    display: flex;
    gap: 15px;
    margin-bottom: 25px;
    flex-wrap: wrap;
}

.convert-btn, .download-btn, .copy-btn {
    flex: 1;
    min-width: 150px;
    padding: 14px;
    border: none;
    border-radius: 5px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
}

.convert-btn {
    background: linear-gradient(to right, #1a2a6c, #b21f1f);
    color: white;
}

.convert-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

.convert-btn:disabled {
    background: #a0aec0;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

.download-btn, .copy-btn {
    background: #e2e8f0;
    color: #4a5568;
}

.download-btn:hover, .copy-btn:hover {
    background: #cbd5e0;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.download-btn:disabled, .copy-btn:disabled {
    background: #edf2f7;
    color: #a0aec0;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

.preview-area {
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    overflow: hidden;
    margin-bottom: 20px;
}

.preview-header {
    background: #1a2a6c;
    color: white;
    padding: 12px 15px;
    font-weight: 600;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.record-count {
    background: #b21f1f;
    padding: 3px 10px;
    border-radius: 20px;
    font-size: 14px;
}

.preview-content {
    height: 300px;
    overflow: auto;
    padding: 15px;
    background: #fafafa;
    font-family: monospace;
    white-space: pre-wrap;
    font-size: 14px;
    line-height: 1.4;
}

.validation-error {
    color: #b21f1f;
    background: #ffe6e6;
    padding: 10px;
    border-radius: 5px;
    margin-top: 10px;
    display: none;
}

.notification {
    position: fixed;
    top: 20px;
    right: 20px;
    padding: 15px 20px;
    background: #48bb78;
    color: white;
    border-radius: 5px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    transform: translateX(150%);
    transition: transform 0.3s;
    z-index: 1000;
}

.notification.show {
    transform: translateX(0);
}

footer {
    text-align: center;
    padding: 20px;
    color: #718096;
    font-size: 14px;
    border-top: 1px solid #e2e8f0;
    background: #f7fafc;
}

@media (max-width: 768px) {
    .action-buttons {
        flex-direction: column;
    }
    
    .content {
        padding: 20px;
    }
    
    .powerball-icon {
        position: static;
        margin-bottom: 10px;
    }
    
    .layout-visual {
        flex-wrap: wrap;
    }
    
    .column {
        margin-bottom: 10px;
    }
    
    .file-item {
        flex-direction: column;
        align-items: flex-start;
        gap: 5px;
    }
    
    .file-size {
        margin-right: 0;
    }
}