.tutorial-overlay {
    position: fixed;
    inset: 0;
    z-index: 9999;
    background: rgba(0, 0, 0, 0.5);
    display: none;
    pointer-events: none;
    opacity: 0;
    transition: all 0.5s cubic-bezier(0.19, 1, 0.22, 1);
}

.tutorial-overlay.active {
    display: block;
    opacity: 1;
}

.tutorial-overlay.intro-mode {
    background: #000 !important;
    pointer-events: all;
    opacity: 1;
}

.tutorial-content {
    position: fixed;
    z-index: 10001;
    background: rgba(10, 10, 10, 0.9);
    border: 1px solid var(--border, #444);
    border-top: 2px solid var(--fg, #fff);
    padding: 20px;
    width: 280px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.9);
    pointer-events: all;
    transition: all 0.3s cubic-bezier(0.19, 1, 0.22, 1);
    animation: tutorialBoxEntry 0.35s cubic-bezier(0.19, 1, 0.22, 1);
    color: #fff;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

@keyframes tutorialBoxEntry {
    from {
        transform: translate(-50%, calc(-50% + 15px));
        opacity: 0;
    }

    to {
        transform: translate(-50%, -50%);
        opacity: 1;
    }
}

.tutorial-step-indicator {
    font-size: 10px;
    color: var(--fg, #fff);
    opacity: 0.5;
    margin-bottom: 4px;
    letter-spacing: 2px;
}

.tutorial-header {
    font-size: 16px;
    font-weight: 900;
    margin-bottom: 10px;
    color: var(--fg, #fff);
    text-transform: uppercase;
    letter-spacing: 2px;
    text-shadow: 0 0 10px var(--glow, rgba(255, 255, 255, 0.3));
}

.tutorial-body {
    font-size: 14px;
    line-height: 1.6;
    margin-bottom: 20px;
    color: rgba(255, 255, 255, 0.8);
    font-family: 'Courier New', monospace;
}

.tutorial-controls {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 15px;
}

.tutorial-btn {
    background: transparent;
    border: 1px solid #fff;
    color: #fff;
    padding: 6px 14px;
    cursor: pointer;
    font-size: 11px;
    text-transform: uppercase;
    font-weight: 800;
    letter-spacing: 1px;
    transition: all 0.2s ease;
    position: relative;
    overflow: hidden;
}

.tutorial-btn::after {
    content: '';
    position: absolute;
    inset: 0;
    background: #fff;
    transform: translateX(-100%);
    transition: transform 0.3s cubic-bezier(0.19, 1, 0.22, 1);
    z-index: -1;
}

.tutorial-btn:hover {
    color: #000;
}

.tutorial-btn:hover::after {
    transform: translateX(0);
}

.tutorial-btn.btn-prev {
    opacity: 0.7;
    border-color: rgba(255, 255, 255, 0.3);
}

.tutorial-btn.btn-prev:hover {
    opacity: 1;
    border-color: #fff;
}

.tutorial-skip {
    display: inline-block;
    background: transparent;
    border: none;
    color: rgba(255, 255, 255, 0.4);
    cursor: pointer;
    font-size: 10px;
    margin-top: 15px;
    text-transform: uppercase;
    letter-spacing: 1px;
    transition: color 0.2s;
    width: auto;
}

.tutorial-skip:hover {
    color: #fff;
    text-decoration: underline;
}

.tutorial-highlight {
    position: fixed;
    pointer-events: none;
    border: 2px solid var(--fg, #fff);
    z-index: 10000;
    transition: all 0.6s cubic-bezier(0.19, 1, 0.22, 1);
    border-radius: 4px;
    opacity: 0;
    box-shadow: 0 0 20px var(--glow, #fff);
}

.tutorial-highlight.active {
    opacity: 1;
    box-shadow: 0 0 0 9999px rgba(0, 0, 0, 0.5), 0 0 20px var(--glow, #fff);
}

@media (max-width: 1024px) {
    .tutorial-content {
        width: 240px;
        padding: 15px;
        bottom: 20px !important;
        left: 50% !important;
        transform: translateX(-50%) !important;
        top: auto !important;
    }

    @keyframes tutorialBoxEntry {
        from {
            transform: translate(-50%, 20px);
            opacity: 0;
        }

        to {
            transform: translate(-50%, 0);
            opacity: 1;
        }
    }
}

.virtual-cursor {
    position: fixed;
    width: 28px;
    height: 28px;
    background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='white' stroke='black' stroke-width='1.5'%3E%3Cpath d='M5.5 3.21V20.8l5.2-5.13 3.51 8.27h2l-3.66-8.59 7.45.05L5.5 3.21z'/%3E%3C/svg%3E") no-repeat;
    pointer-events: none;
    z-index: 10002;
    transition: all 0.8s cubic-bezier(0.19, 1, 0.22, 1), transform 0.2s ease;
    opacity: 0;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.5));
    transform-origin: top left;
}

.virtual-cursor.active {
    opacity: 1;
}

.virtual-cursor.clicking {
    transform: scale(0.85);
}

.virtual-click-pulse {
    position: absolute;
    width: 60px;
    height: 60px;
    border: 3px solid var(--fg, #fff);
    border-radius: 50%;
    transform: translate(-50%, -50%) scale(0);
    opacity: 0;
    pointer-events: none;
    z-index: 10003;
    animation: clickPulse 0.5s cubic-bezier(0.215, 0.61, 0.355, 1);
}

@keyframes clickPulse {
    0% {
        transform: translate(-50%, -50%) scale(0);
        opacity: 1;
    }

    100% {
        transform: translate(-50%, -50%) scale(1.5);
        opacity: 0;
    }
}