@charset "utf-8";

.player-container {
	background: #000;
	border-radius: 8px;
	position: relative;
}

.video-wrapper { 
    position: relative; 
    width: 100%; 
    aspect-ratio: 16 / 9;
    background: #000; 
    display: flex; 
    align-items: center; 
    justify-content: center; 
    overflow: hidden; 
}

#videoElement, 
#videoCanvas, 
.overlay-layer { 
    position: absolute; 
    top: 0; 
    left: 0; 
    width: 100%; 
    height: 100%; 
    object-fit: contain;
}

#videoCanvas {
	display: none;
}

#cropVideo  {  
    width: 100%; 
    aspect-ratio: 16 / 9;
    background: #000; 
    display: flex; 
    align-items: center; 
    justify-content: center; 
    overflow: hidden; 
}

.fixed-header {
	position: fixed;
	top: 56px;
	left: 0;
	right: 0;
	z-index: 1030;
	backdrop-filter: blur(10px);
}

.overlay-layer {
	position: absolute;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	pointer-events: none;
}

.overlay-item {
	position: absolute;
	pointer-events: all;
	cursor: move;
	border: 2px dashed transparent;
}

.overlay-item:hover {
	border-color: #0d6efd;
}

.overlay-text {
	background: rgba(0,0,0,0.7);
	padding: 8px;
	border-radius: 4px;
	white-space: pre-wrap;
}

.overlay-image {
	overflow: hidden;
}

.overlay-image img {
	width: 100%;
	height: 100%;
	object-fit: contain;
	pointer-events: none;
}

.overlay-controls {
	position: absolute;
	top: -25px;
	right: 0;
	display: flex; gap: 4px;
}

.overlay-btn {
	background: #dc3545;
	color: white;
	border: none;
	padding: 2px 8px;
	border-radius: 4px;
	cursor: pointer;
	font-size: 12px;
}

.resize-handle {
	position: absolute;
	width: 12px;
	height: 12px;
	background: #0d6efd;
	border: 2px solid white;
	border-radius: 50%;
}

.resize-handle.nw {
	top: -6px;
	left: -6px;
	cursor: nwse-resize;
}

.resize-handle.ne {
	top: -6px;
	right: -6px;
	cursor: nesw-resize;
}

.resize-handle.sw {
	bottom: -6px;
	left: -6px;
	cursor: nesw-resize;
}

.resize-handle.se {
	bottom: -6px;
	right: -6px;
	cursor: nwse-resize;
}

.custom-progress {
	position: relative;
	height: 6px;
	background: var(--bs-secondary-bg);
	border-radius: 3px;
	cursor: pointer;
}

.progress-filled {
	height: 100%;
	background: #0d6efd;
	border-radius: 3px;
	position: relative;
}

.progress-handle {
	position: absolute;
	right: -8px;
	top: 50%;
	transform: translateY(-50%);
	width: 16px;
	height: 16px;
	background: #0d6efd;
	border: 2px solid white;
	border-radius: 50%;
	cursor: grab;
	box-shadow: 0 2px 4px rgba(0,0,0,0.3);
}

.progress-handle:active {
	cursor: grabbing;
}

.trim-track {
	position: relative;
	height: 50px;
	background: var(--bs-secondary-bg);
	border-radius: 6px;
	overflow: visible;
	margin: 10px 0;
}

.trim-selection {
	position: absolute;
	height: 100%;
	background: rgba(13, 110, 253, 0.2);
	border-left: 4px solid #198754;
	border-right: 4px solid #dc3545;
	border-radius: 6px;
}

.trim-handle {
	position: absolute;
	width: 5px;
	height: 100%;
	cursor: ew-resize;
	z-index: 10;
}

.trim-handle.start {
	left: 0;
	background: #198754;
}

.trim-handle.end {
	right: 0;
	background: #dc3545;
}

.time-label {
	display: none;
}

.player-container:fullscreen {
	display: flex;
	flex-direction: column;
}

.player-container:fullscreen .video-wrapper {
	flex: 1;
	width: 100%;
	display: flex;
	align-items: center;
	justify-content: center;
}

.player-container:fullscreen .p-3 {
	position: absolute;
	bottom: 0;
	left: 0;
	right: 0;
	width: 100%;
}

.loading-overlay {
	position: fixed;
	top: 0;
	left: 0;
	right: 0;
	bottom: 0;
	background: rgba(0,0,0,0.8);
	display: none;
	align-items: center;
	justify-content: center;
	z-index: 9999;
}

.toast-container {
    position: fixed;
    top: 50%; 
    left: 50%; 
    transform: translate(-50%, -50%); 
    z-index: 9999;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
}

.card-header[data-bs-toggle="collapse"] {
	cursor: pointer;
	user-select: none;
}

.card-header[data-bs-toggle="collapse"]:hover {
	background-color: var(--bs-secondary-bg);
}

.merge-thumbnails {
	display: flex !important;
	gap: 10px;
	padding-bottom: 10px;
}

.merge-thumb {
	flex: 0 0 48%;
	position: relative;
	aspect-ratio: 16/9;
	background: #000;
	border-radius: 6px;
	overflow: hidden;
}

.merge-thumb video {
	width: 100%;
	height: 100%;
	object-fit: cover;
}

.merge-thumb-label {
	position: absolute;
	bottom: 0;
	width: 100%;
	background: rgba(0,0,0,0.8);
	color: #fff;
	font-size: 10px;
	text-align: center;
	padding: 2px;
}
