* { box-sizing: border-box; }
body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    max-width: 720px;
    margin: 30px auto;
    padding: 0 20px;
    background: #f5f7fa;
    color: #1a1a2e;
}
.container {
    background: #fff;
    padding: 30px;
    border-radius: 16px;
    box-shadow: 0 2px 12px rgba(0,0,0,0.08);
}
h1 { text-align: center; margin-top: 0; }
.input-group { margin-bottom: 18px; display: flex; flex-direction: column; gap: 6px; }
.input-group label { font-weight: 600; font-size: 14px; }
.input-group input, .input-group textarea {
    padding: 10px 14px;
    border: 1px solid #d1d5db;
    border-radius: 8px;
    font-size: 16px;
    font-family: inherit;
}
.input-group input:focus, .input-group textarea:focus {
    outline: none;
    border-color: #3b82f6;
    box-shadow: 0 0 0 3px rgba(59,130,246,0.1);
}
.input-group textarea { resize: vertical; min-height: 80px; }
.input-group input[type="file"] { padding: 8px; }

.params-row {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 12px;
    margin-bottom: 18px;
}
.param-group { display: flex; flex-direction: column; gap: 4px; }
.param-group label { font-size: 13px; font-weight: 600; color: #4b5563; }
.param-group input { padding: 8px 12px; border: 1px solid #d1d5db; border-radius: 6px; font-size: 14px; }
.param-group input:focus { outline: none; border-color: #3b82f6; }

button#generateBtn {
    width: 100%;
    padding: 14px;
    background: #3b82f6;
    color: #fff;
    border: none;
    border-radius: 8px;
    font-size: 18px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s;
}
button#generateBtn:hover { background: #2563eb; }
button#generateBtn:disabled { opacity: 0.6; cursor: not-allowed; }

.progress-container {
    position: relative;
    height: 8px;
    background: #e5e7eb;
    border-radius: 10px;
    margin-top: 12px;
    overflow: hidden;
}
.progress-bar {
    height: 100%;
    background: #3b82f6;
    border-radius: 10px;
    transition: width 0.5s ease;
    width: 0%;
}
.progress-text {
    position: absolute;
    right: 4px;
    top: -18px;
    font-size: 11px;
    color: #6b7280;
}

#statusMsg { margin-top: 12px; font-size: 14px; }
#outputArea { margin-top: 16px; }

@media (max-width: 600px) {
    .params-row { grid-template-columns: 1fr; }
    .container { padding: 16px; }
}