.progress-btn { position: relative; overflow: hidden; border: none; }
.progress-btn .progress-fill {
    position: absolute; top: 0; left: 0; bottom: 0;
    background: rgba(0, 0, 0, 0.15); width: 0%;
    transition: width 0.1s linear; z-index: 1;
}
body.dark-mode .progress-btn .progress-fill { background: rgba(255, 255, 255, 0.2); }
.progress-btn span { position: relative; z-index: 2; pointer-events: none; }

/* Preview: the canvas is the picture that is recorded */
.canvas-container {
    position: relative; display: block; width: 100%; max-width: 280px;
    border-radius: 12px; overflow: hidden; border: 2px solid var(--glass-border);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    transition: max-width 0.2s ease;
}
.canvas-container canvas {
    display: block; width: 100%; height: auto; background: #000;
    cursor: grab; touch-action: none;          /* dragging and pinching move the background image */
}
.canvas-container canvas:active { cursor: grabbing; }
