/* Desktop container - solid background */
#desktop-container {
    background-color: #1a1a1a;
}

/* Desktop canvas - background image will be applied via JavaScript */
#desktop-canvas {
    background-color: #1a1a1a;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}

/* FONT DEFINITIONS */
@font-face {
    font-family: 'Europa Grotesk SH';
    src: url('../fonts/europa-grotesk-sh-bold.otf') format('opentype');
    font-weight: bold;
    font-style: normal;
    font-display: swap;
}

.font-europa {
    font-family: 'Europa Grotesk SH', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    font-weight: bold;
}

/* Item labels use Work Sans Bold (similar to Europa Grotesk SH Bold) */
/* Item labels use Work Sans Bold (similar to Europa Grotesk SH Bold) */
.canvas-item span,
.canvas-item .text-sm {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    font-weight: 600;
    letter-spacing: normal;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.5);
    /* Better readability on varied backgrounds */
}

.mobile-item span,
.mobile-item .text-sm {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    font-weight: 600;
    letter-spacing: normal;
    text-shadow: none;
}

/* Smooth dragging */
.canvas-item {
    transition: transform 0.1s ease-out;
    will-change: transform;
}

.canvas-item.dragging {
    opacity: 0.8;
    cursor: grabbing !important;
    z-index: 9999 !important;
}

/* Window shadows */
.finder-window {
    transition: box-shadow 0.2s ease;
}

.finder-window:hover {
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
}

/* Window header cursor */
.window-header {
    user-select: none;
}

/* Prevent text selection during drag */
body.dragging-active {
    user-select: none;
    -webkit-user-select: none;
}

/* Upload drop zone visual feedback */
#desktop-canvas.drag-over::after {
    content: 'Drop to upload';
    position: absolute;
    inset: 20px;
    border: 3px dashed #4ade80;
    background: rgba(74, 222, 128, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    color: #4ade80;
    font-weight: bold;
    pointer-events: none;
    border-radius: 10px;
}

/* Mobile animations */
.mobile-item {
    animation: fadeIn 0.3s ease-out;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Disabled cursor for non-authenticated users */
.canvas-item.no-auth {
    cursor: default !important;
}

/* Folder drop target highlight (when dragging item over folder) */
.canvas-item.drop-target {
    transform: scale(1.15);
    filter: brightness(1.4);
    outline: 4px solid #22c55e !important;
    outline-offset: 6px;
    border-radius: 12px;
    transition: all 0.15s ease;
    z-index: 9998 !important;
    /* Just below dragged item but above other items */
    box-shadow: 0 0 20px rgba(34, 197, 94, 0.6);
}

.canvas-item.drop-target .folder-icon {
    animation: pulse 0.6s ease-in-out infinite;
}

@keyframes pulse {

    0%,
    100% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.08);
    }
}

/* Ensure windows always appear above desktop icons */
.finder-window,
.viewer-window {
    z-index: 100000 !important;
}

/* Cap maximum z-index for desktop items */
/* Cap maximum z-index for desktop items */
.canvas-item {
    /* valid z-index is managed by JS, this was invalid css */
}