/* Custom Styles for fast.upscalex.video */

/* Comparison Badges */
.patch-badge {
    position: absolute;
    top: 12px;
    padding: 4px 10px;
    border-radius: 8px;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.04em;
    z-index: 30;
    pointer-events: none;
    white-space: nowrap;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.25);
}
.patch-badge-src {
    left: 12px;
    background: rgba(10, 12, 14, 0.75);
    color: #e2e8f0;
    backdrop-filter: blur(4px);
}
.patch-badge-out {
    right: 12px;
    background: #5145cd;
    color: #ffffff;
}

/* Draggable Brand Knob Handle */
.brand-knob {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    transition: transform 0.15s ease, background-color 0.15s ease;
}
.brand-knob:hover {
    transform: translate(-50%, -50%) scale(1.1);
    background-color: #4338ca;
}

/* Inset Minimap */
#patch-minimap-wrap {
    position: absolute;
    bottom: 8px;
    left: 8px;
    z-index: 25;
    border: 2px solid rgba(255, 255, 255, 0.85);
    background: #000;
    cursor: crosshair;
    line-height: 0;
    border-radius: 6px;
    overflow: hidden;
}
#patch-viewport-box {
    position: absolute;
    left: 0;
    top: 0;
    border: 1.5px solid #6355dc;
    background: rgba(99, 85, 220, 0.25);
    pointer-events: none;
}

/* Frame Chips Horizontal Strip */
.frame-chip {
    position: relative;
    border-radius: 12px;
    overflow: hidden;
    cursor: pointer;
    border: 2px solid transparent;
    transition: all 0.2s ease;
    background: #000;
    aspect-ratio: 16 / 9;
}
.frame-chip:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}
.frame-chip.selected {
    border-color: #5145cd;
    box-shadow: 0 0 0 2px rgba(81, 69, 205, 0.35);
}
.frame-chip img, .frame-chip canvas {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}
.frame-chip-check {
    position: absolute;
    top: 4px;
    right: 4px;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: #5145cd;
    color: #fff;
    font-size: 10px;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 4px rgba(0,0,0,0.3);
}
.frame-chip-time {
    position: absolute;
    bottom: 4px;
    left: 4px;
    padding: 1px 5px;
    border-radius: 4px;
    background: rgba(0, 0, 0, 0.75);
    color: #fff;
    font-size: 10px;
    font-family: 'DM Mono', monospace;
    font-weight: 500;
    line-height: 1.2;
}

/* Modal Popup Animation */
@keyframes modal-pop {
    0% { opacity: 0; transform: scale(0.95) translateY(10px); }
    100% { opacity: 1; transform: scale(1) translateY(0); }
}
.animate-modal-pop {
    animation: modal-pop 0.2s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

/* Progress Bar Stripes Animation */
.progress-bar-striped-animated {
    background-image: linear-gradient(45deg, rgba(255,255,255,.25) 25%, transparent 25%, transparent 50%, rgba(255,255,255,.25) 50%, rgba(255,255,255,.25) 75%, transparent 75%, transparent);
    background-size: 1rem 1rem;
    animation: progress-bar-stripes 1s linear infinite;
}
@keyframes progress-bar-stripes {
    0% { background-position: 1rem 0; }
    100% { background-position: 0 0; }
}
