.generator-box {
    background: #fff;
    padding: 30px;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
    max-width: 800px;
    margin: 0 auto;
    text-align: center;
}

.upload-section {
    padding: 40px;
    border: 2px dashed #ddd;
    border-radius: 8px;
    margin-bottom: 30px;
    transition: all 0.2s;
}

.upload-section:hover,
.upload-section.drag-over {
    border-color: #2196f3;
    background: #f0f7ff;
}

.upload-section.drag-over {
    background: #e3f2fd;
    border-style: solid;
    transform: scale(1.02);
}

.upload-btn {
    display: inline-block;
    padding: 12px 24px;
    background: #2196f3;
    color: white;
    border-radius: 4px;
    cursor: pointer;
    font-weight: bold;
    margin-bottom: 10px;
}

.upload-btn input {
    display: none;
}

.note {
    font-size: 0.9rem;
    color: #888;
}

.preview-section.hidden {
    display: none;
}

.previews {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    justify-content: center;
    margin-bottom: 30px;
}

.preview-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 5px;
}

.preview-item canvas {
    border: 1px solid #eee;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    background: url('data:image/svg+xml;base64,PHN2Zy4uLj4=');
    /* Optional checkerboard pattern */
    background-color: #fff;
    max-width: 100px;
    /* Limit display size for the big ones */
    height: auto;
}

.preview-item span {
    font-size: 0.8rem;
    color: #666;
}

.btn-download {
    background: #4caf50;
    color: white;
    border: none;
    padding: 12px 30px;
    border-radius: 30px;
    font-size: 1.1rem;
    cursor: pointer;
    box-shadow: 0 4px 10px rgba(76, 175, 80, 0.3);
    transition: background 0.2s;
}

.btn-download:hover {
    background: #388e3c;
}

.html-code-section {
    margin-top: 40px;
    text-align: left;
    position: relative;
}

.html-code-section label {
    display: block;
    margin-bottom: 5px;
    font-weight: bold;
    color: #333;
}

.html-code-section textarea {
    width: 100%;
    height: 100px;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-family: monospace;
    font-size: 0.9rem;
    background: #f9f9f9;
    resize: none;
}

.btn-copy {
    position: absolute;
    top: 30px;
    right: 10px;
    background: #ddd;
    border: none;
    padding: 4px 10px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 0.8rem;
}

.btn-copy:hover {
    background: #ccc;
}