/* Preview Overlay Styles */
#preview-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.9);
    z-index: 1000;
    display: flex;
    justify-content: center;
    align-items: center;
    overflow: auto;
    padding: 20px;
    box-sizing: border-box;
}

#video-container {
    position: relative;
    max-width: 90%;
    max-height: 90vh;
    margin: auto;
    background: rgba(0, 0, 0, 0.5);
    box-shadow: 0 0 20px rgba(0, 0, 0, 0.5);
    display: flex;
    justify-content: center;
    align-items: center;
}

#preview-video {
    max-width: 100%;
    max-height: 80vh;
    display: block;
}

.preview-buttons-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
}

/* Alignment Guides */
.alignment-guides {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 1;
}

.guide {
    position: absolute;
    background: rgba(255, 255, 0, 0.3);
    z-index: 2;
    pointer-events: none;
}

.guide.vertical {
    width: 1px;
    height: 100%;
    left: 50%;
    transform: translateX(-50%);
}

.guide.horizontal {
    height: 1px;
    width: 100%;
    top: 50%;
    transform: translateY(-50%);
}

.guide.quarter {
    opacity: 0.2;
}

.guide.quarter.vertical {
    left: 25%;
}

.guide.quarter.vertical.right {
    left: 75%;
}

.guide.quarter.horizontal {
    top: 25%;
}

.guide.quarter.horizontal.bottom {
    top: 75%;
}

/* Close button */
#close-preview-btn {
    position: absolute;
    top: 20px;
    right: 20px;
    background: rgba(0, 0, 0, 0.7);
    color: white;
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    font-size: 24px;
    cursor: pointer;
    z-index: 1001;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background-color 0.2s;
}

#close-preview-btn:hover {
    background: rgba(255, 0, 0, 0.8);
}
