/* --- TUTORIAL SYSTEM STYLES --- */
#tutorial-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.3);
    z-index: 10000;
    display: none;
    pointer-events: none;
}

#tutorial-container {
    position: fixed;
    z-index: 10001;
    max-width: 300px;
    background: var(--bg-dark);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 16px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.5);
    color: var(--text-primary);
    font-size: 13px;
    display: none;
    pointer-events: auto;
}

#tutorial-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
    padding-bottom: 10px;
    border-bottom: 1px solid var(--border-color);
}

#tutorial-heading {
    font-size: 14px;
    color: var(--accent-primary);
    margin: 0;
    font-weight: bold;
}

#tutorial-close {
    background: none;
    border: none;
    color: var(--text-secondary);
    cursor: pointer;
    font-size: 16px;
    padding: 0;
    margin: 0;
    line-height: 1;
}

#tutorial-content {
    margin-bottom: 16px;
    line-height: 1.4;
    color: var(--text-secondary);
}

#tutorial-controls {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-top: 12px;
    padding-top: 12px;
    border-top: 1px solid var(--border-color);
}

.tutorial-btn {
    padding: 6px 12px;
    border: 1px solid var(--border-color);
    background: var(--bg-medium);
    color: var(--text-primary);
    border-radius: 4px;
    font-size: 11px;
    cursor: pointer;
    transition: all 0.2s;
    font-weight: bold;
}

.tutorial-btn:hover {
    background: var(--bg-light);
    border-color: var(--accent-primary);
    color: var(--accent-primary);
}

.tutorial-btn.secondary {
    border-style: dashed;
    opacity: 0.8;
}

.tutorial-btn.secondary:hover {
    opacity: 1;
    border-color: var(--accent-tertiary);
    color: var(--accent-tertiary);
}

#tutorial-buttons {
    display: flex;
    justify-content: center;
    gap: 8px;
}

#tutorial-progress-dots {
    display: flex;
    justify-content: center;
    gap: 6px;
    margin-top: 8px;
}

.tutorial-progress-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--border-color);
    transition: all 0.3s;
}

.tutorial-progress-dot.active {
    background: var(--accent-primary);
    transform: scale(1.2);
}

#tutorial-close {
    background: none;
    border: none;
    color: var(--text-secondary);
    cursor: pointer;
    font-size: 18px;
    padding: 0;
    margin: 0;
    line-height: 1;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 4px;
    transition: all 0.2s;
}

#tutorial-close:hover {
    background: rgba(255, 255, 255, 0.1);
    color: var(--text-primary);
}

/* Tutorial Directional Arrows */
.tutorial-arrow {
    position: absolute;
    width: 0;
    height: 0;
    border-style: solid;
    z-index: 10002;
}


/* Tutorial Directional Arrows */

/* If tutorial is BELOW target (position: 'bottom'), arrow should be on TOP, pointing UP. */
.tutorial-arrow.bottom {
    bottom: -8px;
    left: 50%;
    transform: translateX(-50%);
    border-width: 8px 8px 0px 8px;
    border-color: var(--accent-primary) transparent transparent transparent;

}

/* If tutorial is ABOVE target (position: 'top'), arrow should be on BOTTOM, pointing DOWN. */
.tutorial-arrow.top {
    top: -8px;
    left: 50%;
    transform: translateX(-50%);
    border-width: 0px 8px 8px 8px;
    border-color: transparent transparent var(--accent-primary) transparent;
}

/* For a tutorial placed to the LEFT of the target (position: 'left'), the arrow should be on the LEFT side of the panel, pointing LEFT. */
.tutorial-arrow.left {
    /* Arrow should be on the left edge */
    top: 50%;
    left: -8px;
    transform: translateY(-50%);
    border-width: 8px 8px 8px 0px;
    border-color: transparent var(--accent-primary) transparent transparent;
}

/* For a tutorial placed to the RIGHT of the target (position: 'right'), the arrow should be on the RIGHT side of the panel, pointing RIGHT. */
.tutorial-arrow.right {
    /* Arrow should be on the right edge */
    top: 50%;
    right: -8px;
    transform: translateY(-50%);
    border-width: 8px 0px 8px 8px;
    border-color: transparent transparent transparent var(--accent-primary);
}

/* Arrow Position Overrides - precise placement along sides */
.tutorial-arrow.top-third {
    /* Corrected for vertical positioning */
    top: 33.33% !important;
}

.tutorial-arrow.middle-third {
    top: 50% !important;
}

.tutorial-arrow.bottom-third {
    /* Corrected for vertical positioning */
    top: 66.66% !important;
}

.tutorial-arrow.left-third {
    /* Corrected for horizontal positioning */
    left: 33.33% !important;
}

.tutorial-arrow.center-third {
    left: 50% !important;
}

.tutorial-arrow.right-third {
    /* Corrected for horizontal positioning */
    left: 66.66% !important;
}
/* Style for setting descriptions */
.setting-description {
    font-size: 0.8rem;
    color: var(--text-secondary);
    margin-top: 4px;
    margin-left: 30px;
}

/* Ensure tutorial tab matches the scene tab style */
.settings-tab-content[data-tab-content="tutorial"] .property-group {
    margin-bottom: 12px;
    padding: 8px 0;
}

.settings-tab-content[data-tab-content="tutorial"] .property-group:last-child {
    margin-bottom: 0;
    padding-bottom: 0;
    border-bottom: none;
}

/* Fix tutorial tab button styling */
.settings-tab-content[data-tab-content="tutorial"] button {
    margin-top: 12px;
    padding: 8px 12px;
    font-size: 0.8rem;
}
