#toaster-scene {
    position: relative;
    width: 300px;
    height: 250px;
    margin: 20px auto;
    display: flex;
    justify-content: center;
    align-items: flex-end;
}

#toaster {
    width: 200px;
    height: 120px;
    background: #ccc;
    border-radius: 20px 20px 5px 5px;
    position: relative;
    border: 4px solid #999;
    box-shadow: inset -10px -10px 0 rgba(0,0,0,0.1);
}

.slot {
    width: 140px;
    height: 15px;
    background: #333;
    margin: 10px auto;
    border-radius: 10px;
    position: relative; /* Rimosso overflow: hidden per lasciare il toast sempre visibile */
}

#toast {
    width: 120px;
    height: 100px;
    background: #f5e1c8; /* Pane crudo */
    position: absolute;
    left: 10px;
    bottom: 20px; /* Fuori dal tostapane all'inizio */
    border-radius: 10px 10px 0 0;
    transition: bottom 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275), background 0.1s;
    border: 2px solid rgba(0,0,0,0.1);
}

#toast.cooking {
    bottom: 5px; /* Scende solo leggermente per dare l'idea di essere nel tostapane ma resta visibile */
}

#cooking-timer {
    position: absolute;
    top: -40px;
    font-size: 2rem;
    font-weight: bold;
    color: #FF5722;
    text-shadow: 2px 2px 0px #000;
    pointer-events: none;
    transition: opacity 0.2s;
}

#lever-track {
    position: absolute;
    right: -30px;
    top: 30px;
    width: 10px;
    height: 60px;
    background: #666;
    border-radius: 5px;
}

#lever {
    position: absolute;
    top: 0;
    left: -10px;
    width: 30px;
    height: 15px;
    background: #444;
    border-radius: 5px;
    cursor: grab;
    transition: top 0.3s;
}

#lever.active {
    top: 45px;
    cursor: grabbing;
}

#status-msg {
    font-weight: bold;
    min-height: 1.5em;
}

#smoke-container {
    position: absolute;
    top: 50px;
    width: 100%;
    height: 50px;
    pointer-events: none;
}

.smoke {
    position: absolute;
    width: 20px;
    height: 20px;
    background: rgba(50,50,50,0.6);
    border-radius: 50%;
    animation: floatUp 2s infinite;
}

@keyframes floatUp {
    0% { transform: translateY(0) scale(1); opacity: 0.6; }
    100% { transform: translateY(-100px) scale(3); opacity: 0; }
}

/* Colori del pane */
/* Crudo: #f5e1c8 */
/* Cotto: #8d5524 */
/* Bruciato: #222 */

#value {
    margin: 15px 0;
    font-family: monospace;
    color: #FF5722;
}