assets/css/style.css
@font-face {
  font-family: 'Courier WebCut';
  src: url(./CourierWebCut.ttf);
}

@font-face {
  font-family: 'JupiterSans';
  src: url(./jupitersans.ttf);
}

html, body {
  margin: 0;
  padding: 0;
  font-family: 'JupiterSans';
}

::-moz-selection {
  background: #abe4fd;
  color: #0b284b;
  text-shadow: none;
}

::selection {
  background: #abe4fd;
  color: #0b284b;
  text-shadow :none;
}

::-webkit-scrollbar {
  -webkit-appearance: none;
  display: none;
}
::-webkit-scrollbar-corner { 
  -webkit-appearance: none;
  display: none;
}

.full {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  height: 100%;
  width: 100%;
  margin: 0;
  padding: 0;
}

.popup {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  z-index: 10;
  max-width: 50%;
  padding: 10px;
  background: #2b2f33;
  color: #c0c8d5;
  box-shadow: 2px 2px 10px 3px rgba(0, 0, 0, .2);
  text-align: center;
}

.popup div {
  margin: 25px;
}

div.settings .holder {
    display:grid;
    grid-template-columns: max-content max-content;
    grid-gap:5px;
}
div.settings .holder label       { text-align:right; }
div.settings .holder label:after { content: ":"; }

.popup p {
  padding-bottom: 20px;
}
.popup .close {
  float: right;
  color: #c0c8d5;
}
.popup div a {
  color: #c0c8d5;
}
.popup div {
text-align: center;
}
.popup a:hover {
  cursor: pointer;
}

/* Loading popup specific styles */
#loading-popup {
  min-width: 300px;
  max-width: 400px;
}

#loading-popup h3 {
  margin: 0 0 15px 0;
  font-family: 'JupiterSans';
  font-size: 18px;
  color: #c0c8d5;
}

#loading-progress-container {
  margin: 0;
}

#loading-progress-text {
  font-size: 16px;
  font-weight: bold;
  margin: 8px 0;
  color: #a9e1fa;
}

#loading-current-file {
  font-size: 12px;
  color: #8a9ba8;
  margin: 8px 0 0 0;
  word-break: break-all;
  max-height: 40px;
  overflow: hidden;
}
#loading-popup #loading-progress-fill {
  margin: 0;
}
#background {
  z-index: 0;
  background: #2b2f33;
  overflow: hidden;
}

#foreground {
  z-index: 5;
  background: black;
}

#center-panel {
  position: absolute;
  left: 0;
  top: 0;
  bottom: 30%;
  width: 90%;
  display: flex;
  flex-direction: row;
}

#center-panel #transcription {
  height: 100%;
  width: 40%;
  background: rgba(43, 47, 51, 0.9);
  color: rgb(192, 200, 213);
  overflow-y: auto;
  overflow-x: hidden;
  padding: 30px;
  box-sizing: border-box;
  border-right: #c0c8d5 solid 1px;
  font-family: 'JupiterSans', Arial, sans-serif;
  font-size: 16px;
  line-height: 1.6;
}

#transcription .text-chunks {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  align-items: flex-start;
  margin: 0;
  padding: 0;
}

#transcription .text-chunks > .text-chunk {
  position: relative;
  padding: 2px 2px;
  border-radius: 3px;
  font-size: 13px;
  line-height: 1.4;
  transition: background-color 0.2s ease;
}

#transcription .text-chunks > *:hover {
  background: rgba(255, 255, 255, 0.15);
  cursor: pointer;
}

/* Close button styling */
#transcription .text-chunk .close {
  position: absolute;
  top: -2px;
  right: -2px;
  width: 14px;
  height: 14px;
  background: rgba(220, 53, 69, 0.8);
  color: white;
  border-radius: 50%;
  display: none;
  justify-content: center;
  align-items: center;
  font-size: 8px;
  font-weight: bold;
  line-height: 1;
  cursor: pointer;
  transition: background-color 0.2s ease, transform 0.1s ease;
  z-index: 10;
}

#transcription .text-chunk:hover .close {
  display: flex;
}

#transcription .text-chunk .close:hover {
  background: rgba(220, 53, 69, 1);
  transform: scale(1.1);
}

/* Highlighted chunk styling for current playback position */
#transcription .text-chunk.highlighted {
  background: rgba(169, 225, 250, 0.3);
  color: #0b284b;
  font-weight: bold;
  border: 1px solid rgba(169, 225, 250, 0.6);
}


/* Video canvas takes up 50% width */
#center-panel #video-canvas-panel {
  width: 60%;
  height: 100%;
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
  background: rgba(43, 47, 51, 0.9);
}

#video-canvas {
  position: relative;
  max-width: 90%;
  max-height: 90%;
  aspect-ratio: 16/9;
  background-color: #000;
  box-shadow: 0 0 10px rgba(0, 0, 0, 0.5);
  margin: auto;
}

/* Video canvas content (videos, images, etc) */
#video-canvas video, 
#video-canvas img, 
#video-canvas canvas {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

#layer_holder {
  position: absolute;
  background: rgb(31,31,31);
  overflow: scroll;
  scrollbar-width: none;
  right: 0;
  top: 0;
  bottom: 20%;
  width: 10%;
  color: rgb(192,200,213);
  font-family: 'JupiterSans';
}

#cursor_preview {
  display: none;
  position: absolute;
  background: black;
  box-shadow: 0em 0px 16px 0px #0b284b;
  border-radius: 10px;
  z-index: 6;
  text-align:center;
  color: white;
  font-size: 10px;
  color: rgb(255,255,255);
  font-family: 'JupiterSans';
}

#header {
  background: rgb(43,47,51);
  text-align: center;
  font-size: 12px;
  font-family: 'JupiterSans';
}

a {
  color: rgb(255,255,255);
}
a:visited {
  color: rgb(255,255,255);
}

#header div {
  display: inline-block;
  padding: 4px;
  margin: 4px;
}

#header a {
  padding: 4px;
  margin: 4px;
}

#header div:hover,
#layers div a:hover,
#layers div canvas:hover {
  cursor: pointer;
}

/* Screen recording button styles */
#record-screen-btn {
  background-color: rgba(220, 53, 69, 0.1);
  border: 1px solid rgba(220, 53, 69, 0.3);
  border-radius: 4px;
}

#record-screen-btn:hover {
  background-color: rgba(220, 53, 69, 0.2);
}

#stop-recording-btn {
  background-color: rgba(255, 193, 7, 0.1);
  border: 1px solid rgba(255, 193, 7, 0.3);
  border-radius: 4px;
}

#stop-recording-btn:hover {
  background-color: rgba(255, 193, 7, 0.2);
}

/* Recording indicator animation */
@keyframes recording-pulse {
  0% { opacity: 1; }
  50% { opacity: 0.5; }
  100% { opacity: 1; }
}

#record-screen-btn.recording {
  animation: recording-pulse 1s infinite;
}

#layers .preview {
  font-size: 12px;
  font-family: 'JupiterSans';
  word-break: break-all;
  display: flex;
  padding: 4px;
}

#layers .preview_title {
  padding: 5px;
  width: 70%;
}

#layers .preview_thumb {
  background: black;
  width: 30%;
}

#layers .preview_title input {
  margin: 5px;
}

#layers div {
  border-left: solid rgba(40,41,42,0) 4px;
}

#layers .selected {
  color: rgb();
  background-color: rgb(37,44,58);
  border-left: solid rgb(169,225,250) 4px;
}

/* Context menu styles */
.layer-context-menu {
  position: fixed;
  background: white;
  border: 1px solid #ccc;
  border-radius: 4px;
  padding: 4px;
  box-shadow: 2px 2px 8px rgba(0,0,0,0.2);
  z-index: 1000;
  font-family: 'JupiterSans';
  font-size: 12px;
}

.layer-context-menu-item {
  padding: 4px 8px;
  cursor: pointer;
  transition: background-color 0.2s ease;
}

.layer-context-menu-item:hover {
  background-color: #f0f0f0;
}

.layer-context-menu-item.clone {
  color: #4CAF50;
}

.layer-context-menu-item.clone:hover {
  background-color: #e8f5e8;
}

.layer-context-menu-item.delete {
  color: red;
}

.layer-context-menu-item.delete:hover {
  background-color: #ffe6e6;
}

#foreground #timeline {
  position: absolute;
  background: rgb(43,47,51);
  right: 0;
  left: 0;
  bottom: 0;
  height: 30%;
  width: 100%;
  scrollbar-width: none;
  padding: 0;
  margin-bottom: 15px;
}

#foreground #timeline_content {
  position: relative;
  background: rgb(43,47,51);
  right: 0;
  left: 0;
  bottom: 0;
  height: 100%;
  width: 100%;
  overflow-x: scroll;
  scrollbar-width: none;
  padding: 0;
}

#foreground #timeline_content canvas {
  position: absolute;
  bottom: 0;
  top: 0;
  height: 100%;
}

/* Timeline header styles */
#timeline_header {
  position: relative;
  top: 0;
  left: 0;
  display: flex;
  justify-content: space-between;
  background: rgb(37, 37, 40);
  padding: 8px 12px;
  border-bottom: 1px solid rgba(60, 60, 65, 0.8);
}

#controls_left, #controls_right {
  display: flex;
  align-items: center;
}

.timeline_header_item {
  margin: 0 8px;
  padding: 6px 12px;
  background-color: rgb(53, 53, 58);
  color: rgb(192, 200, 213);
  border-radius: 4px;
  font-size: 12px;
  font-family: 'JupiterSans';
  cursor: pointer;
  transition: background-color 0.2s, color 0.2s;
}

.timeline_header_item:hover {
  background-color: rgb(63, 63, 68);
  color: rgb(220, 225, 235);
}

/* Zoom slider styles */
#controls_right .timeline_header_item {
  display: flex;
  align-items: center;
  width: 180px;
  justify-content: space-between;
}

#timeline_zoom_slider {
  -webkit-appearance: none;
  appearance: none;
  width: 120px;
  height: 6px;
  border-radius: 3px;
  background: rgb(80, 80, 85);
  outline: none;
  margin-left: 8px;
}

#timeline_zoom_slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: rgb(169, 225, 250);
  cursor: pointer;
  border: 2px solid rgb(37, 37, 40);
  transition: background 0.2s;
}

#timeline_zoom_slider::-moz-range-thumb {
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: rgb(169, 225, 250);
  cursor: pointer;
  border: 2px solid rgb(37, 37, 40);
  transition: background 0.2s;
}

#timeline_zoom_slider::-webkit-slider-thumb:hover {
  background: rgb(139, 205, 240);
}

#timeline_zoom_slider::-moz-range-thumb:hover {
  background: rgb(139, 205, 240);
}

/* Speed Control Component Styles */
.speed-control-container {
  display: flex;
  flex-direction: column;
  background-color: rgb(37, 37, 40);
  border-radius: 6px;
  border: 1px solid rgba(60, 60, 65, 0.8);
  font-family: 'JupiterSans', sans-serif;
  min-width: 200px;
}

.speed-control-container.disabled {
  opacity: 0.6;
  pointer-events: none;
}

.speed-control-header {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.speed-control-label {
  font-size: 11px;
  font-weight: 500;
  color: rgb(192, 200, 213);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.speed-control-input-group {
  display: flex;
  align-items: center;
  gap: 4px;
}

.speed-control-input {
  flex: 1;
  background-color: rgb(53, 53, 58);
  border: 1px solid rgba(60, 60, 65, 0.8);
  border-radius: 4px;
  color: rgb(220, 225, 235);
  font-size: 12px;
  font-family: 'JupiterSans', monospace;
  text-align: center;
  width: 60px;
  transition: border-color 0.2s, background-color 0.2s;
}

.speed-control-input:focus {
  outline: none;
  border-color: rgb(69, 155, 255);
  background-color: rgb(58, 58, 63);
}

.speed-control-input:hover:not(:focus) {
  background-color: rgb(58, 58, 63);
}

.speed-control-unit {
  font-size: 11px;
  color: rgb(150, 158, 171);
  font-weight: 500;
}

.speed-control-presets {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
}

.speed-preset-button {
  padding: 4px 8px;
  background-color: rgb(53, 53, 58);
  border: 1px solid rgba(60, 60, 65, 0.8);
  border-radius: 3px;
  color: rgb(192, 200, 213);
  font-size: 10px;
  font-family: 'JupiterSans', monospace;
  cursor: pointer;
  transition: all 0.2s;
  min-width: 32px;
  text-align: center;
}

.speed-preset-button:hover {
  background-color: rgb(63, 63, 68);
  color: rgb(220, 225, 235);
}

.speed-preset-button.active {
  background-color: rgb(69, 155, 255);
  border-color: rgb(69, 155, 255);
  color: white;
}

.speed-preset-button:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.speed-control-error {
  padding: 4px 6px;
  background-color: rgba(255, 59, 48, 0.1);
  border: 1px solid rgba(255, 59, 48, 0.3);
  border-radius: 3px;
  color: rgb(255, 100, 90);
  font-size: 10px;
  text-align: center;
  animation: fadeIn 0.2s ease-in;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(-2px); }
  to { opacity: 1; transform: translateY(0); }
}

/* Timeline header integration */
.timeline_header_item.speed-control-item {
  padding: 4px 8px;
  width: auto;
  min-width: 200px;
}

.timeline_header_item.speed-control-item .speed-control-container {
  background: transparent;
  border: none;
  padding: 0;
  margin: 0;
}

/* Dropdown Menu Styles */
.dropdown {
  position: relative;
  display: inline-block;
}

.dropdown-toggle {
  cursor: pointer;
  user-select: none;
  padding: 8px 12px;
  background: rgb(43,47,51);
  color: white;
  border-radius: 4px;
  transition: background 0.2s;
}

.dropdown-toggle:hover {
  background: rgb(53,57,61);
}

#header .dropdown-menu {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  min-width: 140px;
  background: rgb(43,47,51);
  border: 1px solid rgb(60,64,68);
  border-radius: 4px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.3);
  z-index: 1000;
}

#header .dropdown-menu.show {
  display: block;
}

.dropdown-item {
  padding: 10px 15px;
  cursor: pointer;
  color: white;
  border-bottom: 1px solid rgb(60,64,68);
  transition: background 0.2s;
}

.dropdown-item:last-child {
  border-bottom: none;
}

.dropdown-item:hover {
  background: rgb(53,57,61);
}

/* Aspect Ratio Selector Dropdown */
#aspect-ratio-dropdown {
  position: relative;
  display: inline-block;
  margin-left: 10px;
}

#aspect-ratio-dropdown .dropdown-toggle {
  background: #2b2f33;
  color: #fff;
  padding: 8px 12px;
  border: 1px solid #444;
  border-radius: 4px;
  cursor: pointer;
  font-size: 12px;
  white-space: nowrap;
  user-select: none;
  transition: background-color 0.2s ease;
}

#aspect-ratio-dropdown .dropdown-toggle:hover {
  background: #3a3f44;
}

#aspect-ratio-dropdown .dropdown-menu {
  position: absolute;
  top: 100%;
  left: 0;
  background: #2b2f33;
  border: 1px solid #444;
  border-radius: 4px;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
  z-index: 1000;
  min-width: 140px;
  display: none;
  margin-top: 2px;
}

#aspect-ratio-dropdown .dropdown-menu.show {
  display: block;
}

#aspect-ratio-dropdown .dropdown-item {
  padding: 8px 12px;
  color: #fff;
  cursor: pointer;
  font-size: 12px;
  transition: background-color 0.2s ease;
  border-bottom: 1px solid #444;
}

#aspect-ratio-dropdown .dropdown-item:last-child {
  border-bottom: none;
}

#aspect-ratio-dropdown .dropdown-item:hover {
  background: #3a3f44;
}

#aspect-ratio-dropdown .dropdown-item.active {
  background: #4a90e2;
  color: #fff;
}

#aspect-ratio-dropdown .dropdown-item.active:hover {
  background: #5ba0f2;
}

/* Timeline Layer Reordering Styles */
.timeline-drag-feedback {
  pointer-events: none;
  z-index: 1000;
}

.timeline-drop-zone {
  position: absolute;
  width: 100%;
  height: 2px;
  background: rgba(0, 150, 255, 0.3);
  border: 1px dashed rgba(100, 100, 100, 0.3);
  transition: all 0.2s ease;
}

.timeline-drop-zone.active {
  height: 3px;
  background: rgba(0, 150, 255, 0.8);
  border: 1px solid rgba(0, 150, 255, 0.8);
  box-shadow: 0 0 8px rgba(0, 150, 255, 0.4);
}

.timeline-layer-preview {
  position: absolute;
  background: rgba(0, 150, 255, 0.2);
  border: 2px dashed rgba(0, 150, 255, 0.6);
  border-radius: 4px;
  opacity: 0.8;
  transition: all 0.1s ease;
}

.timeline-layer-ghost {
  opacity: 0.5;
  transform: scale(0.98);
  filter: blur(1px);
}

/* Cursor styles during drag operations */
.timeline-dragging-vertical {
  cursor: ns-resize !important;
}

.timeline-dragging-horizontal {
  cursor: ew-resize !important;
}

/* Timeline canvas hover states */
#timeline_content canvas {
  transition: cursor 0.1s ease;
}

#timeline_content canvas:hover {
  cursor: grab;
}

#timeline_content canvas:active {
  cursor: grabbing;
}