@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;700&display=swap');

/* Base Styles */
body {
    font-family: 'Outfit', sans-serif;
    color: white;
    background-color: black;
    overflow-x: hidden;
}

/* Liquid Glass Effect */
.liquid-glass {
    background: rgba(255, 255, 255, 0.03);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.05);
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.1);
}

/* Hide Scrollbar */
.hide-scrollbar::-webkit-scrollbar {
    display: none;
}

.hide-scrollbar {
    -ms-overflow-style: none;
    scrollbar-width: none;
}

/* Layout Utilities */
.snap-container {
    display: flex;
    flex-direction: row;
    overflow-x: auto;
    overflow-y: hidden;
    scroll-snap-type: x mandatory;
    width: 100vw;
    height: 100vh;
}

.snap-section {
    scroll-snap-align: center;
    min-width: 100vw;
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.main-card {
    width: 90vw;
    height: 85vh;
    max-width: 864px;
    border-radius: 40px;
    position: relative;
    overflow: hidden;
}

/* Overlays */
.overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(10px);
    z-index: 100;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s;
    display: flex;
    align-items: center;
    justify-content: center;
}

.overlay.active {
    opacity: 1;
    pointer-events: auto;
}

.overlay.active #popup-content {
    transform: scale(1);
}


/* Draggable Items */
/* Draggable Items - Base */
.movable {
    position: absolute;
    user-select: none;
    /* Ensure consistent sizing */
    box-sizing: border-box;
    border: 2px solid transparent;
    /* Reserve space for border to prevent jumps */
    padding: 8px;
    /* Fatter grab area */
    border-radius: 12px;
    transition: background 0.2s, border-color 0.2s;
}

/* Edit Mode Styles */
.movable.editable {
    cursor: grab;
    border-color: rgba(255, 255, 255, 0.15);
    /* Visible border */
    background: rgba(255, 255, 255, 0.02);
    /* Slight highlight */
}

.movable.editable:hover {
    border-color: rgba(255, 255, 255, 0.3);
    background: rgba(255, 255, 255, 0.05);
}

.movable.editable:active {
    cursor: grabbing;
    background: rgba(255, 255, 255, 0.1);
}

/* Read-Only Mode (Saved) Styles */
.movable.read-only {
    cursor: default;
    /* No grab cursor */
    border-color: transparent;
    padding: 8px;
    /* Maintain spacing */
}

/* Remove default pointer events on images in read-only if they aren't interactive */
.movable.read-only img {
    pointer-events: none;
}

.selected-element {
    border-color: rgba(255, 255, 255, 0.5);
    border-style: dashed;
    /* padding is inherited from .movable (8px), do not override */
}

/* Chat Bubble Style */
/* Chat Bubble Style */
.chat-bubble {
    background: rgba(255, 255, 255, 0.1);
    padding: 12px 20px;
    border-radius: 20px;
    border-bottom-left-radius: 4px;
    /* Default Left/Received */
    font-size: 16px;
    line-height: 1.4;
    max-width: 250px;
    transition: all 0.3s ease;
}

.chat-bubble.right {
    background: white;
    color: black;
    border-bottom-left-radius: 20px;
    border-bottom-right-radius: 4px;
    align-self: flex-end;
    /* If using grid/flex alignment, though here we use absolute positioning */
    /* For absolute positioning, the JS might need to adjust origin or we just rely on visual style */
}

/* Sidebar Open State */
#properties-sidebar {
    margin-left: 0;
}

#properties-sidebar.open {
    width: 20rem;
    /* w-80 */
    opacity: 1;
    margin-left: 2rem;
    /* gap-8 equivalent */
}

/* Specific override for Editor Canvas to fit flex layout */
/* Specific override for Editor Canvas to fit flex layout */
#canvas-container {
    height: 100%;
    /* Max width is 864px (from .main-card), but we ensure it fits flex layout */
    max-width: 864px;
    width: 90vw;
    flex-shrink: 0;
}

/* Volume Slider Customization */
input[type=range].volume-slider {
    -webkit-appearance: none;
    appearance: none;
    width: 60px;
    height: 4px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 2px;
    outline: none;
    cursor: pointer;
}

input[type=range].volume-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: white;
    cursor: pointer;
    transition: transform 0.1s;
}

input[type=range].volume-slider::-webkit-slider-thumb:hover {
    transform: scale(1.2);
}

input[type=range].volume-slider::-moz-range-thumb {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: white;
    cursor: pointer;
    border: none;
}