.sut {
    position: fixed;
    inset: 0;
    z-index: 70;
    background: #120b0a;
    font-family: Orbitron, sans-serif;
    color: #f1ece9;
    user-select: none;
    opacity: 0;
    visibility: hidden;
    transition: opacity .35s ease, visibility 0s linear .35s;
}

.sut.show {
    opacity: 1;
    visibility: visible;
    transition: opacity .35s ease;
}

.sut canvas {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    display: block;
    cursor: none;
    touch-action: none;
}

.sut-vignette {
    position: absolute;
    inset: 0;
    pointer-events: none;
    background: radial-gradient(ellipse at 50% 45%, transparent 45%, rgba(0, 0, 0, .55) 85%, rgba(0, 0, 0, .85) 100%);
}

.sut-top {
    position: absolute;
    top: 26px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 18px;
    align-items: center;
    padding: 7px 16px;
    border-radius: 999px;
    background: rgba(14, 18, 20, .72);
    border: 1px solid rgba(255, 255, 255, .08);
    font-size: 12px;
    letter-spacing: .14em;
    color: #9fb3ad;
    pointer-events: none;
}

.sut-top b {
    color: #fff;
    font-weight: 700;
}

.sut-tag {
    color: #3ef0a0;
    font-weight: 800;
}

.sut-panel {
    position: absolute;
    left: 50%;
    bottom: 4vh;
    transform: translateX(-50%);
    width: 620px;
    padding: 14px 18px 12px;
    border-radius: 14px;
    background: rgba(12, 15, 17, .86);
    border: 1px solid rgba(255, 255, 255, .08);
    box-shadow: 0 18px 40px rgba(0, 0, 0, .55);
    pointer-events: none;
}

.sut-steps {
    display: flex;
    gap: 8px;
    margin-bottom: 10px;
}

.sut-steps span {
    flex: 1;
    padding: 3px 0;
    border-radius: 4px;
    background: rgba(255, 255, 255, .06);
    font-size: 10px;
    font-weight: 700;
    letter-spacing: .16em;
    text-align: center;
    color: #6f7d79;
}

.sut-steps [hidden] { display: none; }
.sut canvas[hidden] { display: none; }

.sut-steps span.fatto {
    background: rgba(62, 240, 160, .16);
    color: #3ef0a0;
}

.sut-steps span.attivo {
    background: #ff7a2f;
    color: #fff;
}

.sut-main {
    display: flex;
    justify-content: space-between;
    gap: 18px;
}

.sut-text {
    flex: 1;
    min-width: 0;
}

.sut-title {
    font-size: 20px;
    font-weight: 800;
    letter-spacing: .03em;
    color: #fff;
}

.sut-desc {
    margin-top: 2px;
    font-size: 13px;
    line-height: 1.35;
    overflow-wrap: break-word;
    color: #a9b6b2;
}

.sut-stats {
    display: flex;
    flex-shrink: 0;
    gap: 18px;
    text-align: right;
}

.sut-stats small {
    display: block;
    font-size: 10px;
    letter-spacing: .14em;
    color: #6d8f84;
}

.sut-stats b {
    display: block;
    font-size: 22px;
    font-weight: 700;
    color: #3ef0a0;
    font-variant-numeric: tabular-nums;
}

.sut-stats b.ko { color: #ff4d4d; }

.sut-bar {
    height: 5px;
    margin-top: 10px;
    border-radius: 3px;
    background: rgba(255, 255, 255, .07);
    overflow: hidden;
}

.sut-bar div {
    width: 0;
    height: 100%;
    background: linear-gradient(90deg, #1fbf75, #3ef0a0);
    transition: width .2s ease;
}

.sut-keys {
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 8px 16px;
    margin-top: 10px;
    font-size: 13px;
    color: #e6ecea;
}

.sut-keys em {
    font-style: normal;
}

.sut-keys kbd {
    display: inline-block;
    margin-right: 7px;
    padding: 1px 8px;
    border-radius: 4px;
    background: #f2f2f2;
    color: #111;
    font-family: inherit;
    font-size: 11px;
    font-weight: 700;
    box-shadow: 0 2px 0 #9a9a9a;
}

.sut-voto {
    position: absolute;
    left: 50%;
    top: 16vh;
    transform: translateX(-50%);
    font-size: 26px;
    font-weight: 900;
    letter-spacing: .16em;
    text-shadow: 0 2px 12px rgba(0, 0, 0, .8);
    opacity: 0;
    pointer-events: none;
}

.sut-voto.perfetta { color: #3ef0a0; }
.sut-voto.buona { color: #ffd34d; }
.sut-voto.errore { color: #ff4d4d; }
.sut-voto.info { color: #9fc6ff; }

.sut-voto.pop {
    animation: sutVoto 1.1s ease-out forwards;
}

.sut-esito {
    position: absolute;
    left: 50%;
    top: 40%;
    transform: translate(-50%, -50%) scale(.9);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    padding: 22px 40px;
    border-radius: 16px;
    background: rgba(10, 20, 16, .88);
    border: 1px solid rgba(62, 240, 160, .4);
    box-shadow: 0 0 40px rgba(62, 240, 160, .25);
    opacity: 0;
    pointer-events: none;
    transition: opacity .3s ease, transform .3s ease;
}

.sut-esito i {
    font-size: 40px;
    color: #3ef0a0;
}

.sut-esito span {
    font-size: 24px;
    font-weight: 900;
    letter-spacing: .14em;
}

.sut-esito small {
    font-size: 13px;
    letter-spacing: .08em;
    color: #9fb3ad;
}

.sut-esito.show {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1);
}

@keyframes sutVoto {
    0% { opacity: 0; transform: translateX(-50%) translateY(10px) scale(1.2); }
    15% { opacity: 1; transform: translateX(-50%) translateY(0) scale(1); }
    75% { opacity: 1; }
    100% { opacity: 0; transform: translateX(-50%) translateY(-12px); }
}

@media (max-width: 560px) {
    .sut-top { width: max-content; max-width: 94vw; gap: 10px; font-size: 10px; }
    .sut-con-estrazione .sut-steps span { min-width: 0; font-size: 8px; letter-spacing: .05em; overflow-wrap: anywhere; }
    .sut-main { flex-wrap: wrap; }
    .sut-text { flex-basis: 100%; }
    .sut-stats { width: 100%; justify-content: flex-end; }
    .sut-title { font-size: 17px; }
    .sut-desc, .sut-keys { font-size: 11px; }
    .sut-esito { width: max-content; max-width: 94vw; padding: 16px; text-align: center; }
    .sut-esito span { font-size: 18px; }
}
