@charset "UTF-8";
.analyse-page {
  padding-top: 0;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  width: 100vw;
  margin-left: calc(-50vw + 50%);
  padding-left: var(--spacing-sm);
  padding-right: var(--spacing-sm);
}

.analyse-header {
  margin-bottom: var(--spacing-xs);
  position: relative;
  background: var(--color-bg-elevated);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
}

.analyse-title {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  font-size: 1.8rem;
  font-weight: 600;
  white-space: nowrap;
  pointer-events: none;
}

.analyse-header-tools {
  margin-left: auto;
  gap: var(--spacing-xs);
}
.analyse-header-tools > * {
  margin: 0;
}

.analyse-video-container {
  background: #000;
  border-radius: var(--radius-md);
  overflow: hidden;
  margin-bottom: 0;
  position: relative;
}
.analyse-video-container .analyse-zoom-badge {
  position: absolute;
  top: 8px;
  right: 8px;
  z-index: 5;
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: 0.7rem;
  font-weight: 600;
  padding: 2px 8px;
  border-radius: var(--radius-xl);
  border: 1px solid var(--color-border-hover);
  background: rgba(1, 12, 28, 0.75);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  color: var(--color-text-primary);
  cursor: pointer;
  transition: all var(--transition-fast);
}
.analyse-video-container .analyse-zoom-badge:hover {
  background: var(--color-brand-blue);
  border-color: var(--color-brand-blue);
  color: white;
}

.analyse-cut-flash {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  pointer-events: none;
  z-index: 10;
  animation: cut-flash 0.6s ease-out forwards;
}
.analyse-cut-flash i {
  font-size: 4rem;
  filter: drop-shadow(0 2px 8px rgba(0, 0, 0, 0.5));
}

@keyframes cut-flash {
  0% {
    opacity: 0.85;
    transform: scale(0.7);
  }
  30% {
    opacity: 0.9;
    transform: scale(1.05);
  }
  100% {
    opacity: 0;
    transform: scale(1.1);
  }
}
@keyframes pill-denied-shake {
  0%, 100% {
    transform: translateX(0);
  }
  25% {
    transform: translateX(-3px);
  }
  75% {
    transform: translateX(3px);
  }
}
.analyse-multi-grid {
  display: grid;
  width: 100%;
  height: 100%;
  gap: 2px;
  background: var(--color-border);
}
.analyse-multi-grid.mag-solo {
  grid-template: 1fr/1fr;
}
.analyse-multi-grid.mag-grid.mag-count-2 {
  grid-template: 1fr/1fr 1fr;
}
.analyse-multi-grid.mag-grid.mag-count-3 {
  grid-template: 1fr 1fr/1fr 1fr;
}
.analyse-multi-grid.mag-grid.mag-count-4 {
  grid-template: 1fr 1fr/1fr 1fr;
}
.analyse-multi-grid.mag-grid.mag-count-5 {
  grid-template: 1fr 1fr/1fr 1fr 1fr;
}
.analyse-multi-grid.mag-grid.mag-count-6 {
  grid-template: 1fr 1fr/1fr 1fr 1fr;
}
.analyse-multi-grid.mag-grid.mag-count-7 {
  grid-template: 1fr 1fr/1fr 1fr 1fr 1fr;
}
.analyse-multi-grid.mag-grid.mag-count-8 {
  grid-template: 1fr 1fr/1fr 1fr 1fr 1fr;
}
.analyse-multi-grid.mag-dominant-left {
  grid-template-columns: 2fr 1fr;
  grid-template-rows: repeat(auto-fill, 1fr);
}
.analyse-multi-grid.mag-dominant-left.mag-count-2 {
  grid-template-rows: 1fr;
}
.analyse-multi-grid.mag-dominant-left.mag-count-3 {
  grid-template-rows: 1fr 1fr;
}
.analyse-multi-grid.mag-dominant-left.mag-count-4 {
  grid-template-rows: 1fr 1fr 1fr;
}
.analyse-multi-grid.mag-dominant-left.mag-count-5 {
  grid-template-columns: 2fr 1fr 1fr;
  grid-template-rows: 1fr 1fr;
}
.analyse-multi-grid.mag-dominant-left.mag-count-6 {
  grid-template-columns: 2fr 1fr 1fr;
  grid-template-rows: 1fr 1fr 1fr;
}
.analyse-multi-grid.mag-dominant-left.mag-count-7 {
  grid-template-columns: 2fr 1fr 1fr;
  grid-template-rows: 1fr 1fr 1fr;
}
.analyse-multi-grid.mag-dominant-left.mag-count-8 {
  grid-template-columns: 2fr 1fr 1fr;
  grid-template-rows: 1fr 1fr 1fr 1fr;
}
.analyse-multi-grid.mag-dominant-left .analyse-multi-slot.is-dominant {
  grid-row: 1/-1;
  grid-column: 1;
}
.analyse-multi-grid.mag-dominant-right {
  grid-template-columns: 1fr 2fr;
  grid-template-rows: repeat(auto-fill, 1fr);
}
.analyse-multi-grid.mag-dominant-right.mag-count-2 {
  grid-template-rows: 1fr;
}
.analyse-multi-grid.mag-dominant-right.mag-count-3 {
  grid-template-rows: 1fr 1fr;
}
.analyse-multi-grid.mag-dominant-right.mag-count-4 {
  grid-template-rows: 1fr 1fr 1fr;
}
.analyse-multi-grid.mag-dominant-right.mag-count-5 {
  grid-template-columns: 1fr 1fr 2fr;
  grid-template-rows: 1fr 1fr;
}
.analyse-multi-grid.mag-dominant-right.mag-count-6 {
  grid-template-columns: 1fr 1fr 2fr;
  grid-template-rows: 1fr 1fr 1fr;
}
.analyse-multi-grid.mag-dominant-right.mag-count-7 {
  grid-template-columns: 1fr 1fr 2fr;
  grid-template-rows: 1fr 1fr 1fr;
}
.analyse-multi-grid.mag-dominant-right.mag-count-8 {
  grid-template-columns: 1fr 1fr 2fr;
  grid-template-rows: 1fr 1fr 1fr 1fr;
}
.analyse-multi-grid.mag-dominant-right .analyse-multi-slot.is-dominant {
  grid-row: 1/-1;
  grid-column: 2;
}
.analyse-multi-grid.mag-dominant-right.mag-count-5 .analyse-multi-slot.is-dominant, .analyse-multi-grid.mag-dominant-right.mag-count-6 .analyse-multi-slot.is-dominant, .analyse-multi-grid.mag-dominant-right.mag-count-7 .analyse-multi-slot.is-dominant, .analyse-multi-grid.mag-dominant-right.mag-count-8 .analyse-multi-slot.is-dominant {
  grid-column: 3;
}
.analyse-multi-grid.mag-dominant-top {
  grid-template-rows: 2fr 1fr;
}
.analyse-multi-grid.mag-dominant-top.mag-count-2 {
  grid-template-columns: 1fr;
}
.analyse-multi-grid.mag-dominant-top.mag-count-3 {
  grid-template-columns: 1fr 1fr;
}
.analyse-multi-grid.mag-dominant-top.mag-count-4 {
  grid-template-columns: 1fr 1fr 1fr;
}
.analyse-multi-grid.mag-dominant-top.mag-count-5 {
  grid-template-columns: 1fr 1fr;
  grid-template-rows: 2fr 1fr 1fr;
}
.analyse-multi-grid.mag-dominant-top.mag-count-6 {
  grid-template-columns: 1fr 1fr 1fr;
  grid-template-rows: 2fr 1fr 1fr;
}
.analyse-multi-grid.mag-dominant-top.mag-count-7 {
  grid-template-columns: 1fr 1fr 1fr;
  grid-template-rows: 2fr 1fr 1fr;
}
.analyse-multi-grid.mag-dominant-top.mag-count-8 {
  grid-template-columns: 1fr 1fr 1fr 1fr;
  grid-template-rows: 2fr 1fr 1fr;
}
.analyse-multi-grid.mag-dominant-top .analyse-multi-slot.is-dominant {
  grid-column: 1/-1;
  grid-row: 1;
}
.analyse-multi-grid.mag-dominant-bottom {
  grid-template-rows: 1fr 2fr;
}
.analyse-multi-grid.mag-dominant-bottom.mag-count-2 {
  grid-template-columns: 1fr;
}
.analyse-multi-grid.mag-dominant-bottom.mag-count-3 {
  grid-template-columns: 1fr 1fr;
}
.analyse-multi-grid.mag-dominant-bottom.mag-count-4 {
  grid-template-columns: 1fr 1fr 1fr;
}
.analyse-multi-grid.mag-dominant-bottom.mag-count-5 {
  grid-template-columns: 1fr 1fr;
  grid-template-rows: 1fr 1fr 2fr;
}
.analyse-multi-grid.mag-dominant-bottom.mag-count-6 {
  grid-template-columns: 1fr 1fr 1fr;
  grid-template-rows: 1fr 1fr 2fr;
}
.analyse-multi-grid.mag-dominant-bottom.mag-count-7 {
  grid-template-columns: 1fr 1fr 1fr;
  grid-template-rows: 1fr 1fr 2fr;
}
.analyse-multi-grid.mag-dominant-bottom.mag-count-8 {
  grid-template-columns: 1fr 1fr 1fr 1fr;
  grid-template-rows: 1fr 1fr 2fr;
}
.analyse-multi-grid.mag-dominant-bottom .analyse-multi-slot.is-dominant {
  grid-column: 1/-1;
  grid-row: 2;
}
.analyse-multi-grid.mag-dominant-bottom.mag-count-5 .analyse-multi-slot.is-dominant, .analyse-multi-grid.mag-dominant-bottom.mag-count-6 .analyse-multi-slot.is-dominant, .analyse-multi-grid.mag-dominant-bottom.mag-count-7 .analyse-multi-slot.is-dominant, .analyse-multi-grid.mag-dominant-bottom.mag-count-8 .analyse-multi-slot.is-dominant {
  grid-row: 3;
}

.analyse-multi-slot {
  position: relative;
  background: #000;
  overflow: hidden;
  cursor: pointer;
}
.analyse-multi-slot.is-zoomed {
  cursor: grab;
}
.analyse-multi-slot.is-zoomed:active {
  cursor: grabbing;
}
.analyse-multi-slot:not(.is-dominant):hover {
  outline: 1px solid rgba(255, 255, 255, 0.3);
  outline-offset: -1px;
}
.analyse-multi-slot video {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
}
.analyse-multi-slot .slot-label {
  position: absolute;
  top: 4px;
  left: 4px;
  font-size: 0.65rem;
  background: none;
  padding: 1px 6px;
  border: 1px solid #fff;
  border-radius: var(--radius-sm);
  color: #fff;
  opacity: 0.6;
  pointer-events: none;
  z-index: 2;
}
.analyse-multi-slot .slot-debug {
  position: absolute;
  bottom: 4px;
  left: 4px;
  font-family: SFMono-Regular, Menlo, monospace;
  font-size: 0.6rem;
  line-height: 1.35;
  white-space: pre;
  background: rgba(0, 0, 0, 0.75);
  color: #7fd4ff;
  padding: 2px 6px;
  border-radius: var(--radius-sm);
  pointer-events: none;
  z-index: 3;
}
.analyse-multi-slot.is-dominant .slot-label {
  background: none;
  border-color: var(--color-brand-blue);
  color: var(--color-brand-blue);
}
.analyse-multi-slot .slot-no-footage {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--color-text-muted);
  font-size: 0.75rem;
  pointer-events: none;
}
.analyse-multi-slot.is-empty {
  display: none;
}

.analyse-multi-grid:not(.mag-solo) .analyse-multi-slot video {
  max-height: none;
}

.analyse-video {
  width: 100%;
  display: block;
  max-height: 60vh;
  transition: opacity 0.3s ease;
}
.analyse-video::-webkit-media-controls-panel {
  background: none;
  background-image: none;
}
.analyse-video::-webkit-media-controls-enclosure {
  background: none;
}

.analyse-overlay-controls {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 4;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.75), rgba(0, 0, 0, 0));
  opacity: 0;
  transform: translateY(4px);
  transition: opacity 0.15s ease, transform 0.15s ease;
  pointer-events: none;
}
.analyse-overlay-controls.is-visible {
  opacity: 1;
  transform: none;
  pointer-events: auto;
}
.analyse-overlay-controls .aoc-btn {
  flex: 0 0 auto;
  min-width: 32px;
  height: 32px;
  padding: 0 9px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: none;
  border: none;
  color: rgba(255, 255, 255, 0.9);
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  border-radius: var(--radius-sm);
}
.analyse-overlay-controls .aoc-btn:hover {
  color: #fff;
  background: rgba(255, 255, 255, 0.15);
}
.analyse-overlay-controls .aoc-btn.is-active {
  color: var(--color-brand-blue);
}
.analyse-overlay-controls .aoc-loop-a, .analyse-overlay-controls .aoc-loop-b {
  font-family: SFMono-Regular, Menlo, monospace;
}
.analyse-overlay-controls .aoc-scrub {
  flex: 1 1 auto;
  min-width: 80px;
  height: 30px;
  display: flex;
  align-items: center;
  cursor: pointer;
  touch-action: none;
}
.analyse-overlay-controls .aoc-scrub-track {
  position: relative;
  width: 100%;
  height: 6px;
  background: rgba(255, 255, 255, 0.25);
  border-radius: 3px;
}
.analyse-overlay-controls .aoc-scrub-fill {
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 0;
  background: var(--color-brand-blue);
  border-radius: 3px;
}
.analyse-overlay-controls .aoc-loop-region {
  position: absolute;
  top: -3px;
  bottom: -3px;
  background: rgba(245, 200, 66, 0.35);
  border-left: 2px solid #f5c842;
  border-right: 2px solid #f5c842;
  pointer-events: none;
}
.analyse-overlay-controls .aoc-loop-mark {
  position: absolute;
  top: -6px;
  bottom: -6px;
  width: 2px;
  margin-left: -1px;
  background: #f5c842;
  border-radius: 1px;
  pointer-events: none;
}
.analyse-overlay-controls .aoc-scrub-thumb {
  position: absolute;
  top: 50%;
  width: 15px;
  height: 15px;
  margin-left: -7.5px;
  transform: translateY(-50%);
  background: #fff;
  border-radius: 50%;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.5);
  pointer-events: none;
}
.analyse-overlay-controls .aoc-time {
  flex: 0 0 auto;
  font-size: 0.8rem;
  color: rgba(255, 255, 255, 0.9);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
.analyse-overlay-controls .aoc-time .aoc-time-sep {
  opacity: 0.5;
  margin: 0 2px;
}
.analyse-overlay-controls .aoc-speed {
  position: relative;
  flex: 0 0 auto;
}
.analyse-overlay-controls .aoc-speed-panel {
  position: absolute;
  bottom: 100%;
  right: 0;
  margin-bottom: 6px;
  display: none;
  flex-direction: column;
  gap: 8px;
  width: 232px;
  background: rgba(20, 20, 24, 0.97);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  padding: 12px 14px 10px;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.5);
}
.analyse-overlay-controls .aoc-speed-panel.is-open {
  display: flex;
}
.analyse-overlay-controls .aoc-speed-value {
  text-align: center;
  color: #fff;
  font-size: 1.05rem;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  line-height: 1;
}
.analyse-overlay-controls .aoc-speed-slider {
  position: relative;
  height: 40px;
  display: flex;
  align-items: center;
  cursor: pointer;
  touch-action: none;
}
.analyse-overlay-controls .aoc-speed-track {
  position: relative;
  width: 100%;
  height: 6px;
  background: rgba(255, 255, 255, 0.25);
  border-radius: 3px;
}
.analyse-overlay-controls .aoc-speed-fill {
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 0;
  background: var(--color-brand-blue);
  border-radius: 3px;
}
.analyse-overlay-controls .aoc-speed-tick {
  position: absolute;
  top: 50%;
  width: 2px;
  height: 10px;
  margin-left: -1px;
  transform: translateY(-50%);
  background: rgba(255, 255, 255, 0.35);
  border-radius: 1px;
  pointer-events: none;
}
.analyse-overlay-controls .aoc-speed-tick.is-active {
  background: var(--color-brand-blue);
}
.analyse-overlay-controls .aoc-speed-thumb {
  position: absolute;
  top: 50%;
  left: 0;
  width: 18px;
  height: 18px;
  margin-left: -9px;
  transform: translateY(-50%);
  background: #fff;
  border-radius: 50%;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.5);
  pointer-events: none;
  z-index: 1;
}
.analyse-overlay-controls .aoc-speed-steplabels {
  display: flex;
  justify-content: space-between;
  color: rgba(255, 255, 255, 0.55);
  font-size: 0.7rem;
  font-variant-numeric: tabular-nums;
}

.analyse-overlay-controls.aoc-multi [data-aoc=loop-a], .analyse-overlay-controls.aoc-multi [data-aoc=loop-b],
.analyse-overlay-controls.aoc-multi [data-aoc=loop-toggle], .analyse-overlay-controls.aoc-multi [data-aoc=loop-clear] {
  display: none;
}

@media (hover: none), (pointer: coarse) {
  .analyse-overlay-controls {
    opacity: 1;
    transform: none;
    pointer-events: auto;
    gap: 10px;
  }
  .analyse-overlay-controls .aoc-btn {
    min-width: 44px;
    height: 44px;
  }
  .analyse-overlay-controls .aoc-speed-slider {
    height: 48px;
  }
  .analyse-overlay-controls .aoc-speed-thumb {
    width: 26px;
    height: 26px;
    margin-left: -13px;
  }
  .analyse-overlay-controls .aoc-speed-panel {
    width: 260px;
  }
}
.cut-modal-video-wrap {
  position: relative;
  line-height: 0;
}

.analyse-overlay-controls.cut-modal-controls {
  background: linear-gradient(to top, rgba(0, 0, 0, 0.85), rgba(0, 0, 0, 0));
}
.analyse-overlay-controls.cut-modal-controls.is-visible {
  opacity: 1;
  transform: none;
  pointer-events: auto;
}

.play-modal-video-wrap {
  position: relative;
}

.pm-angle-overlay {
  position: absolute;
  top: 10px;
  left: 10px;
  z-index: 6;
  max-width: 180px;
}

.analyse-overlay-controls.play-modal-controls {
  background: linear-gradient(to top, rgba(0, 0, 0, 0.85), rgba(0, 0, 0, 0));
}
.analyse-overlay-controls.play-modal-controls.is-visible {
  opacity: 1;
  transform: none;
  pointer-events: auto;
}

.modal-video-wide {
  max-width: min(94vw, 150vh) !important;
  width: 100%;
}

#cut-modal-video {
  max-height: 85vh;
  object-fit: contain;
  background: #000;
}

.cut-modal-video-wrap:fullscreen,
.play-modal-video-wrap:fullscreen {
  display: flex;
  align-items: center;
  justify-content: center;
  background: #000;
}
.cut-modal-video-wrap:fullscreen video,
.play-modal-video-wrap:fullscreen video {
  max-height: 100vh;
  max-width: 100vw;
  object-fit: contain;
}

.analyse-video-controls {
  height: 28px;
  margin-bottom: var(--spacing-xs);
  cursor: ns-resize;
  display: flex;
  align-items: center;
  position: relative;
  background: var(--color-bg-elevated);
  border-radius: 0 0 var(--radius-md) var(--radius-md);
}
.analyse-video-controls button:focus:not(:focus-visible) {
  outline: none;
  box-shadow: none;
}
.analyse-video-controls .marker-tl-live-btn {
  margin-left: var(--spacing-md);
  margin-right: 0;
  flex: 0 0 auto;
  height: 20px;
  padding: 0 8px;
}
.analyse-video-controls .analyse-angle-select {
  cursor: default;
  margin-right: var(--spacing-xs);
  margin-left: var(--spacing-md);
  min-width: 0;
}
.analyse-video-controls .analyse-angle-select select {
  font-size: 0.6rem;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  padding: 0.1rem 1.75rem 0.1rem 0.4rem;
  line-height: 1.2;
  height: 20px;
  background: rgba(84, 85, 255, 0.1);
  border-color: var(--color-brand-blue);
  color: var(--color-brand-blue);
  border-radius: var(--radius-sm);
}
.analyse-video-controls .analyse-angle-select select:focus {
  border-color: var(--color-brand-blue);
  box-shadow: none;
}
.analyse-video-controls .analyse-multi-toggle {
  background: none;
  border: 1px solid var(--color-border);
  color: var(--color-text-secondary);
  border-radius: var(--radius-sm);
  height: 20px;
  padding: 0 5px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 0.6rem;
  margin-right: var(--spacing-xs);
}
.analyse-video-controls .analyse-multi-toggle:hover {
  border-color: var(--color-brand-blue);
  color: var(--color-brand-blue);
}
.analyse-video-controls .analyse-multi-toggle.is-active {
  border-color: var(--color-brand-blue);
  color: var(--color-brand-blue);
  background: rgba(84, 85, 255, 0.1);
}
.analyse-video-controls .analyse-minor-pause {
  background: none;
  border: 1px solid var(--color-border);
  color: var(--color-text-secondary);
  border-radius: var(--radius-sm);
  height: 20px;
  width: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 0.6rem;
  margin-right: var(--spacing-xs);
}
.analyse-video-controls .analyse-minor-pause:hover {
  border-color: var(--color-brand-blue);
  color: var(--color-brand-blue);
}
.analyse-video-controls .analyse-minor-pause.is-active {
  border-color: var(--color-warning, #f0ad4e);
  color: var(--color-warning, #f0ad4e);
  background: rgba(240, 173, 78, 0.1);
}
.analyse-video-controls .analyse-layout-picker {
  cursor: default;
  margin-right: var(--spacing-xs);
}
.analyse-video-controls .analyse-layout-picker select {
  font-size: 0.6rem;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  padding: 0.1rem 1.5rem 0.1rem 0.35rem;
  line-height: 1.2;
  height: 20px;
  background: rgba(84, 85, 255, 0.1);
  border-color: var(--color-brand-blue);
  color: var(--color-brand-blue);
  border-radius: var(--radius-sm);
}
.analyse-video-controls .analyse-layout-picker select:focus {
  border-color: var(--color-brand-blue);
  box-shadow: none;
}
.analyse-video-controls .analyse-bw-meter {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: 0.65rem;
  font-weight: 600;
  line-height: 1.2;
  height: 20px;
  padding: 0 8px;
  border-radius: var(--radius-xl);
  border: 1px solid var(--color-border);
  color: var(--color-text-secondary);
  white-space: nowrap;
  cursor: default;
}
.analyse-video-controls .analyse-bw-meter.is-warn {
  border-color: var(--color-warning);
  color: var(--color-warning);
  background: rgba(245, 158, 11, 0.1);
}
.analyse-video-controls .analyse-bw-meter.is-hot {
  border-color: var(--color-danger);
  color: var(--color-danger);
  background: rgba(239, 68, 68, 0.1);
}
.analyse-video-controls .analyse-angle-pills {
  display: flex;
  align-items: center;
  gap: 3px;
  flex-wrap: nowrap;
  margin-right: var(--spacing-xs);
}
.analyse-video-controls .analyse-angle-pills .analyse-angle-pill {
  font-size: 0.65rem;
  font-weight: 600;
  line-height: 1;
  width: 20px;
  height: 20px;
  padding: 0;
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  border: 1px solid var(--color-border);
  background: none;
  color: var(--color-text-muted);
  cursor: pointer;
  transition: all var(--transition-fast);
}
.analyse-video-controls .analyse-angle-pills .analyse-angle-pill:hover {
  border-color: var(--color-border-hover);
  color: var(--color-text-primary);
}
.analyse-video-controls .analyse-angle-pills .analyse-angle-pill.is-included {
  background: rgba(var(--color-brand-blue-rgb), 0.15);
  border-color: var(--color-brand-blue);
  color: var(--color-brand-blue);
}
.analyse-video-controls .analyse-angle-pills .analyse-angle-pill.is-dominant {
  background: var(--color-brand-blue);
  border-color: var(--color-brand-blue);
  color: white;
}
.analyse-video-controls .analyse-angle-pills .analyse-angle-pill.pill-denied {
  animation: pill-denied-shake 300ms ease;
}
.analyse-video-controls .analyse-overlay-toggle {
  margin-left: auto;
  margin-right: var(--spacing-sm);
  background: none;
  border: 1px solid var(--color-border);
  color: var(--color-text-secondary);
  border-radius: var(--radius-sm);
  height: 20px;
  padding: 0 5px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 0.7rem;
  gap: 3px;
}
@media (hover: hover) {
  .analyse-video-controls .analyse-overlay-toggle:hover {
    border-color: var(--color-brand-blue);
    color: var(--color-brand-blue);
  }
}
.analyse-video-controls .analyse-overlay-toggle .analyse-overlay-chevron {
  font-size: 0.5rem;
  display: none;
}
.analyse-video-controls .analyse-overlay-toggle.is-bottom .analyse-overlay-chevron, .analyse-video-controls .analyse-overlay-toggle.is-top .analyse-overlay-chevron {
  display: inline;
}
.analyse-video-controls .analyse-badge-toggle {
  margin-right: var(--spacing-sm);
  background: none;
  border: 1px solid var(--color-border);
  color: var(--color-text-secondary);
  border-radius: var(--radius-sm);
  height: 20px;
  padding: 0 5px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 0.7rem;
  opacity: 0.7;
}
@media (hover: hover) {
  .analyse-video-controls .analyse-badge-toggle:hover {
    border-color: var(--color-brand-blue);
    color: var(--color-brand-blue);
    opacity: 1;
  }
}
.analyse-video-controls .analyse-badge-toggle.is-active {
  opacity: 1;
  border-color: var(--color-brand-blue);
  color: #fff;
  background: var(--color-brand-blue);
}
.analyse-video-controls .analyse-burned-toggle {
  margin-right: var(--spacing-sm);
  background: none;
  border: 1px solid var(--color-border);
  color: var(--color-text-secondary);
  border-radius: var(--radius-sm);
  height: 20px;
  padding: 0 5px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 0.7rem;
}
@media (hover: hover) {
  .analyse-video-controls .analyse-burned-toggle:hover {
    border-color: var(--color-brand-blue);
    color: var(--color-brand-blue);
  }
}
.analyse-video-controls .analyse-burned-toggle.active {
  border-color: var(--color-brand-blue);
  color: #fff;
  background: var(--color-brand-blue);
}
.analyse-video-controls .analyse-mute-btn {
  background: none;
  border: 1px solid var(--color-border);
  color: var(--color-text-secondary);
  border-radius: var(--radius-sm);
  width: 24px;
  height: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 0.6rem;
  margin-right: var(--spacing-sm);
}
.analyse-video-controls .analyse-mute-btn:hover {
  border-color: var(--color-brand-blue);
  color: var(--color-brand-blue);
}
.analyse-video-controls .analyse-mute-btn.is-muted {
  color: var(--color-text-muted);
}
.analyse-video-controls .analyse-controls-toggle {
  background: none;
  border: 1px solid var(--color-border);
  color: var(--color-text-secondary);
  border-radius: var(--radius-sm);
  width: 24px;
  height: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 0.6rem;
  margin-right: var(--spacing-sm);
}
.analyse-video-controls .analyse-controls-toggle:hover {
  border-color: var(--color-brand-blue);
  color: var(--color-brand-blue);
}
.analyse-video-controls .analyse-controls-toggle.is-active {
  border-color: var(--color-brand-blue);
  color: var(--color-brand-blue);
}
.analyse-video-controls .analyse-live-btn {
  background: var(--color-brand);
  border: 1px solid white;
  color: white;
  border-radius: var(--radius-sm);
  height: 20px;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  cursor: pointer;
  font-size: 0.55rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  padding: 0 6px;
  margin-right: var(--spacing-sm);
  white-space: nowrap;
}
.analyse-video-controls .analyse-live-btn .analyse-live-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: white;
}
.analyse-video-controls .analyse-live-btn:hover {
  opacity: 0.85;
}
.analyse-video-controls .analyse-live-btn.is-active .analyse-live-dot {
  animation: marker-tl-live-pulse 1.5s ease-in-out infinite;
}

.analyse-layout.stacked {
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
.analyse-layout.stacked .analyse-video-container {
  border: 1px solid var(--color-border);
  border-bottom: none;
  border-radius: var(--radius-md) var(--radius-md) 0 0;
  background: var(--color-bg-elevated);
  min-height: 0;
  overflow: hidden;
}
.analyse-layout.stacked .analyse-video-controls {
  border-left: 1px solid var(--color-border);
  border-right: 1px solid var(--color-border);
  border-radius: 0;
  margin-bottom: 0;
  cursor: default;
}
.analyse-layout.stacked .analyse-angle-select {
  margin-left: var(--spacing-sm);
}
.analyse-layout.stacked .analyse-video-controls:last-child {
  border-bottom: 1px solid var(--color-border);
}
.analyse-layout.stacked .analyse-schema-widget {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  border-top: none;
  border-radius: 0;
  margin-bottom: 0;
}

.analyse-stacked-video-row {
  display: flex;
  min-height: 0;
  overflow: hidden;
}
.analyse-stacked-video-row .analyse-video-container {
  min-width: 0;
}
.analyse-stacked-video-row .analyse-rtc-panel {
  min-width: 120px;
  max-width: 60%;
  border-top: 1px solid var(--color-border);
}
.analyse-stacked-video-row .analyse-rtc-panel .analyse-rtc-video {
  flex: 1;
  min-height: 0;
}
.analyse-stacked-video-row .analyse-rtc-panel:first-child {
  border-right: 1px solid var(--color-border);
  border-radius: var(--radius-md) 0 0 0;
}
.analyse-stacked-video-row .analyse-rtc-panel:first-child ~ .analyse-video-container {
  border-radius: 0 var(--radius-md) 0 0;
}
.analyse-stacked-video-row .analyse-video-container:first-child {
  border-radius: var(--radius-md) 0 0 0;
}
.analyse-stacked-video-row .analyse-video-container:first-child ~ .analyse-stacked-rtc-divider ~ .analyse-rtc-panel {
  border-left: 1px solid var(--color-border);
  border-radius: 0 var(--radius-md) 0 0;
}
.analyse-stacked-video-row .analyse-stacked-rtc-divider {
  cursor: col-resize;
  width: 5px;
  min-width: 5px;
  background: transparent;
  touch-action: none;
}
.analyse-stacked-video-row .analyse-stacked-rtc-divider:hover, .analyse-stacked-video-row .analyse-stacked-rtc-divider.is-dragging {
  background: var(--color-brand);
}

.analyse-layout.compact-left,
.analyse-layout.compact-right {
  display: flex;
  flex-wrap: nowrap;
  overflow: hidden;
}
.analyse-layout.compact-left .analyse-video-controls,
.analyse-layout.compact-right .analyse-video-controls {
  cursor: default;
}

.analyse-layout-panel {
  display: flex;
  flex-direction: column;
  min-width: 20%;
  max-width: 80%;
  overflow: hidden;
}

.analyse-layout.compact-left .analyse-layout-panel.analyse-layout-video .analyse-video-container,
.analyse-layout.compact-right .analyse-layout-panel.analyse-layout-video .analyse-video-container {
  flex: 1;
  border: 1px solid var(--color-border);
  border-bottom: none;
  border-radius: var(--radius-md) 0 0 0;
  margin-bottom: 0;
  background: var(--color-bg-elevated);
}
.analyse-layout.compact-left .analyse-layout-panel.analyse-layout-video .analyse-video,
.analyse-layout.compact-right .analyse-layout-panel.analyse-layout-video .analyse-video {
  max-height: none;
  height: 100%;
  object-fit: contain;
}
.analyse-layout.compact-left .analyse-layout-panel.analyse-layout-video .analyse-video-controls,
.analyse-layout.compact-right .analyse-layout-panel.analyse-layout-video .analyse-video-controls {
  border: 1px solid var(--color-border);
  border-top: none;
  border-radius: 0;
  margin-bottom: 0;
}
.analyse-layout.compact-left .analyse-layout-panel.analyse-layout-schema .analyse-rtc-panel,
.analyse-layout.compact-right .analyse-layout-panel.analyse-layout-schema .analyse-rtc-panel {
  flex: 0 0 35%;
  min-height: 80px;
  border-radius: 0 var(--radius-md) 0 0;
}
.analyse-layout.compact-left .analyse-layout-panel.analyse-layout-schema .analyse-rtc-panel .analyse-rtc-video,
.analyse-layout.compact-right .analyse-layout-panel.analyse-layout-schema .analyse-rtc-panel .analyse-rtc-video {
  flex: 1;
  min-height: 0;
}
.analyse-layout.compact-left .analyse-layout-panel.analyse-layout-schema .analyse-schema-widget,
.analyse-layout.compact-right .analyse-layout-panel.analyse-layout-schema .analyse-schema-widget {
  flex: 1;
  margin-bottom: 0;
  border-radius: 0;
  overflow-y: auto;
}
.analyse-layout.compact-left .analyse-layout-panel.analyse-layout-schema .analyse-schema-widget:first-child,
.analyse-layout.compact-right .analyse-layout-panel.analyse-layout-schema .analyse-schema-widget:first-child {
  border-radius: 0 var(--radius-md) 0 0;
}

.analyse-layout.compact-right .analyse-layout-panel.analyse-layout-video {
  order: 2;
}
.analyse-layout.compact-right .analyse-layout-panel.analyse-layout-video .analyse-video-container {
  border-radius: 0 var(--radius-md) 0 0;
}
.analyse-layout.compact-right .analyse-layout-panel.analyse-layout-video .analyse-video-controls {
  border-radius: 0;
}
.analyse-layout.compact-right .analyse-layout-divider {
  order: 1;
}
.analyse-layout.compact-right .analyse-layout-panel.analyse-layout-schema {
  order: 0;
}
.analyse-layout.compact-right .analyse-layout-panel.analyse-layout-schema .analyse-rtc-panel {
  border-radius: var(--radius-md) 0 0 0;
}
.analyse-layout.compact-right .analyse-layout-panel.analyse-layout-schema .analyse-schema-widget:first-child {
  border-radius: var(--radius-md) 0 0 0;
}

.analyse-layout:not(.show-angle-badges) .analyse-multi-slot .slot-label {
  display: none;
}

.analyse-layout.vtl-left,
.analyse-layout.vtl-right {
  display: flex;
  flex-wrap: nowrap;
  overflow: hidden;
  flex-shrink: 0;
}
.analyse-layout.vtl-left .analyse-layout-panel.analyse-layout-vtl,
.analyse-layout.vtl-right .analyse-layout-panel.analyse-layout-vtl {
  display: flex;
  flex-direction: column;
  min-width: 15%;
  max-width: 60%;
}
.analyse-layout.vtl-left .analyse-layout-panel.analyse-layout-vtl #marker-timeline,
.analyse-layout.vtl-right .analyse-layout-panel.analyse-layout-vtl #marker-timeline {
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
}
.analyse-layout.vtl-left .analyse-layout-panel.analyse-layout-vtl .marker-tl,
.analyse-layout.vtl-right .analyse-layout-panel.analyse-layout-vtl .marker-tl {
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
}
.analyse-layout.vtl-left .analyse-layout-panel.analyse-layout-vtl .marker-tl-body,
.analyse-layout.vtl-right .analyse-layout-panel.analyse-layout-vtl .marker-tl-body {
  flex: 1;
  min-height: 0;
  max-height: none;
}
.analyse-layout.vtl-left .analyse-layout-panel.analyse-layout-main,
.analyse-layout.vtl-right .analyse-layout-panel.analyse-layout-main {
  flex: 1;
}
.analyse-layout.vtl-left .analyse-layout-panel.analyse-layout-main .analyse-video-container,
.analyse-layout.vtl-right .analyse-layout-panel.analyse-layout-main .analyse-video-container {
  flex: 1 1 45%;
  min-height: 120px;
  border: 1px solid var(--color-border);
  border-bottom: none;
  border-radius: var(--radius-md) var(--radius-md) 0 0;
  background: var(--color-bg-elevated);
  overflow: hidden;
}
.analyse-layout.vtl-left .analyse-layout-panel.analyse-layout-main .analyse-video,
.analyse-layout.vtl-right .analyse-layout-panel.analyse-layout-main .analyse-video {
  max-height: none;
  height: 100%;
  object-fit: contain;
}
.analyse-layout.vtl-left .analyse-layout-panel.analyse-layout-main .analyse-video-controls,
.analyse-layout.vtl-right .analyse-layout-panel.analyse-layout-main .analyse-video-controls {
  border-left: 1px solid var(--color-border);
  border-right: 1px solid var(--color-border);
}
.analyse-layout.vtl-left .analyse-layout-panel.analyse-layout-main .analyse-schema-widget,
.analyse-layout.vtl-right .analyse-layout-panel.analyse-layout-main .analyse-schema-widget {
  flex: 1;
  min-height: 0;
  overflow: auto;
}
.analyse-layout.vtl-left .analyse-layout-panel.analyse-layout-main #asb-dock,
.analyse-layout.vtl-right .analyse-layout-panel.analyse-layout-main #asb-dock {
  display: flex;
  flex: 0 0 auto !important;
  min-height: 0;
  min-width: 0;
}
.analyse-layout.vtl-left .analyse-layout-panel.analyse-layout-main:has(#asb-panel.open) #asb-dock,
.analyse-layout.vtl-right .analyse-layout-panel.analyse-layout-main:has(#asb-panel.open) #asb-dock {
  flex: 1 1 auto !important;
}
.analyse-layout.vtl-left .analyse-layout-panel.analyse-layout-main:has(#asb-panel.open) .analyse-schema-widget,
.analyse-layout.vtl-right .analyse-layout-panel.analyse-layout-main:has(#asb-panel.open) .analyse-schema-widget {
  display: none;
}
.analyse-layout.vtl-left .analyse-layout-panel.analyse-layout-main:has(#pm-panel.open) #asb-dock,
.analyse-layout.vtl-right .analyse-layout-panel.analyse-layout-main:has(#pm-panel.open) #asb-dock {
  flex: 0 1 45% !important;
  min-height: 200px;
  margin-bottom: var(--spacing-sm);
}
.analyse-layout.vtl-left .analyse-layout-panel.analyse-layout-main:has(#pm-panel.open) .analyse-schema-widget,
.analyse-layout.vtl-right .analyse-layout-panel.analyse-layout-main:has(#pm-panel.open) .analyse-schema-widget {
  min-height: 140px;
}

.analyse-layout.vtl-right .analyse-layout-panel.analyse-layout-vtl {
  order: 2;
}
.analyse-layout.vtl-right .analyse-layout-divider {
  order: 1;
}
.analyse-layout.vtl-right .analyse-layout-panel.analyse-layout-main {
  order: 0;
}

.analyse-layout.vtl-below {
  display: flex;
  flex-direction: column;
  flex-wrap: nowrap;
  overflow: hidden;
  flex-shrink: 0;
}
.analyse-layout.vtl-below > .analyse-video-container {
  flex: 1 1 45%;
  min-height: 120px;
  border: 1px solid var(--color-border);
  border-bottom: none;
  border-radius: var(--radius-md) var(--radius-md) 0 0;
  background: var(--color-bg-elevated);
  overflow: hidden;
}
.analyse-layout.vtl-below .analyse-video {
  max-height: none;
  height: 100%;
  object-fit: contain;
}
.analyse-layout.vtl-below .analyse-vtlbelow-row {
  flex: 1 1 auto;
  min-height: 0;
  display: flex;
  flex-direction: row;
  flex-wrap: nowrap;
  overflow: hidden;
}
.analyse-layout.vtl-below .analyse-layout-panel.analyse-layout-schema {
  display: flex;
  flex-direction: column;
  min-width: 15%;
  overflow: hidden;
}
.analyse-layout.vtl-below .analyse-layout-panel.analyse-layout-schema .analyse-schema-widget {
  flex: 1;
  min-height: 0;
  overflow: auto;
  margin-bottom: 0;
}
.analyse-layout.vtl-below .analyse-layout-panel.analyse-layout-schema #asb-dock {
  flex: 0 0 auto !important;
  min-height: 0;
}
.analyse-layout.vtl-below .analyse-layout-panel.analyse-layout-schema:has(#asb-panel.open) #asb-dock {
  flex: 1 1 auto !important;
}
.analyse-layout.vtl-below .analyse-layout-panel.analyse-layout-schema:has(#asb-panel.open) .analyse-schema-widget {
  display: none;
}
.analyse-layout.vtl-below .analyse-layout-panel.analyse-layout-schema:has(#pm-panel.open) #asb-dock {
  display: flex;
  flex: 0 1 45% !important;
  min-height: 200px;
  margin-bottom: var(--spacing-sm);
}
.analyse-layout.vtl-below .analyse-layout-panel.analyse-layout-schema:has(#pm-panel.open) .analyse-schema-widget {
  min-height: 140px;
}
.analyse-layout.vtl-below .analyse-layout-panel.analyse-layout-vtl {
  display: flex;
  flex-direction: column;
  min-width: 15%;
}
.analyse-layout.vtl-below .analyse-layout-panel.analyse-layout-vtl #marker-timeline {
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
  padding-bottom: 0;
}
.analyse-layout.vtl-below .analyse-layout-panel.analyse-layout-vtl .marker-tl {
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
}
.analyse-layout.vtl-below .analyse-layout-panel.analyse-layout-vtl .marker-tl-body {
  flex: 1;
  min-height: 0;
  max-height: none;
}

.analyse-rtc-panel {
  display: flex;
  flex-direction: column;
  background: #000;
  overflow: hidden;
}

.analyse-rtc-header {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 4px 8px;
  background: var(--color-bg-elevated);
  border-bottom: 1px solid var(--color-border);
  overflow-x: auto;
  scrollbar-width: none;
}
.analyse-rtc-header::-webkit-scrollbar {
  display: none;
}
.analyse-rtc-header > * {
  flex-shrink: 0;
}

.analyse-rtc-badge {
  font-size: 0.55rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: var(--color-danger);
}
.analyse-rtc-badge::before {
  content: "";
  display: inline-block;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--color-danger);
  margin-right: 4px;
  vertical-align: middle;
  animation: marker-tl-live-pulse 1.5s ease-in-out infinite;
}

.analyse-rtc-spacer {
  flex: 1;
  min-width: 0;
}

.analyse-rtc-angle-select {
  font-size: 0.6rem !important;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  padding: 0.1rem 1.5rem 0.1rem 0.5rem !important;
  height: 20px !important;
  max-width: 140px;
}

.analyse-rtc-follow-label {
  gap: 4px;
  height: 20px;
  position: relative;
  top: 2px;
}
.analyse-rtc-follow-label .checkbox-icon {
  font-size: 0.55rem;
  line-height: 1;
}
.analyse-rtc-follow-label .checkbox-label {
  font-size: 0.55rem;
  line-height: 1;
}

.analyse-rtc-latency {
  display: flex;
  align-items: center;
  gap: 4px;
}
.analyse-rtc-latency .analyse-rtc-latency-slider {
  width: 60px;
  height: 3px;
  -webkit-appearance: none;
  appearance: none;
  background: var(--color-border);
  border-radius: 2px;
  outline: none;
  cursor: pointer;
}
.analyse-rtc-latency .analyse-rtc-latency-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--color-danger);
  cursor: pointer;
}
.analyse-rtc-latency .analyse-rtc-latency-slider::-moz-range-thumb {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--color-danger);
  border: none;
  cursor: pointer;
}
.analyse-rtc-latency .analyse-rtc-latency-label {
  font-size: 0.5rem;
  color: var(--color-danger);
  min-width: 30px;
  text-align: right;
}

.analyse-rtc-fullscreen-btn,
.analyse-rtc-popout-btn,
.analyse-rtc-close-btn {
  background: none;
  border: none;
  color: var(--color-text-secondary);
  cursor: pointer;
  padding: 2px 4px;
  line-height: 1;
}
.analyse-rtc-fullscreen-btn:hover,
.analyse-rtc-popout-btn:hover,
.analyse-rtc-close-btn:hover {
  color: var(--color-text-primary);
}
.analyse-rtc-fullscreen-btn.is-active,
.analyse-rtc-popout-btn.is-active,
.analyse-rtc-close-btn.is-active {
  color: var(--color-brand);
}

.analyse-rtc-video {
  flex: 1;
  width: 100%;
  min-height: 0;
  object-fit: contain;
  display: block;
  background: #000;
}

.analyse-video-controls :is(button, select, input, textarea, label, a[href], [role=button]),
.marker-tl-controls :is(button, select, input, textarea, label, a[href], [role=button]) {
  position: relative;
  z-index: 13;
}

.analyse-layout-divider {
  position: relative;
  z-index: 12;
}
.analyse-layout-divider::before {
  content: "";
  position: absolute;
}
.analyse-layout-divider::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  border-radius: 2px;
  background: var(--color-text-muted);
  opacity: 0.55;
  pointer-events: none;
  transition: opacity 0.15s, background 0.15s;
}
.analyse-layout-divider:hover::after, .analyse-layout-divider.is-dragging::after {
  background: #fff;
  opacity: 1;
}
.analyse-layout-divider::before {
  top: 0;
  bottom: 0;
  left: -8px;
  right: -8px;
}
.analyse-layout-divider::after {
  width: 2px;
  height: 36px;
}
@media (pointer: coarse) {
  .analyse-layout-divider::before {
    left: -14px;
    right: -14px;
  }
  .analyse-layout-divider::after {
    width: 3px;
    height: 48px;
    opacity: 0.8;
  }
}
.analyse-layout-divider {
  width: 6px;
  cursor: col-resize;
  background: var(--color-border);
  transition: background 0.15s;
  flex-shrink: 0;
  touch-action: none;
}
.analyse-layout-divider:hover, .analyse-layout-divider.is-dragging {
  background: var(--color-brand-blue);
}

.analyse-layout-hdivider {
  position: relative;
  z-index: 12;
}
.analyse-layout-hdivider::before {
  content: "";
  position: absolute;
}
.analyse-layout-hdivider::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  border-radius: 2px;
  background: var(--color-text-muted);
  opacity: 0.55;
  pointer-events: none;
  transition: opacity 0.15s, background 0.15s;
}
.analyse-layout-hdivider:hover::after, .analyse-layout-hdivider.is-dragging::after {
  background: #fff;
  opacity: 1;
}
.analyse-layout-hdivider::before {
  left: 0;
  right: 0;
  top: -8px;
  bottom: -8px;
}
.analyse-layout-hdivider::after {
  width: 36px;
  height: 2px;
}
@media (pointer: coarse) {
  .analyse-layout-hdivider::before {
    top: -14px;
    bottom: -14px;
  }
  .analyse-layout-hdivider::after {
    width: 48px;
    height: 3px;
    opacity: 0.8;
  }
}
.analyse-layout-hdivider {
  height: 6px;
  cursor: ns-resize;
  background: var(--color-border);
  transition: background 0.15s;
  flex-shrink: 0;
  touch-action: none;
}
.analyse-layout-hdivider:hover, .analyse-layout-hdivider.is-dragging {
  background: var(--color-brand-blue);
}

.analyse-layout-hdivider + #marker-timeline .marker-tl,
.analyse-layout-hdivider + #timeline-dock-row .marker-tl {
  border-radius: 0 0 var(--radius-md) var(--radius-md);
}

.analyse-layout-hdivider + #timeline-dock-row.asb-docked #asb-panel {
  border-top-left-radius: 0;
  border-top-right-radius: 0;
}

.marker-tl-layout-select {
  background: none;
  border: 1px solid var(--color-border);
  color: var(--color-text-secondary);
  border-radius: var(--radius-sm);
  height: 28px;
  font-size: 0.6rem;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  padding: 0 1.5rem 0 0.4rem;
  margin-left: 6px;
  cursor: pointer;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='8' height='8' viewBox='0 0 8 8'%3E%3Cpath fill='%23999' d='M0 2l4 4 4-4z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 5px center;
}
.marker-tl-layout-select:hover, .marker-tl-layout-select:focus {
  border-color: var(--color-brand-blue);
  color: var(--color-brand-blue);
  outline: none;
}

.marker-tl-vertical-btn {
  background: none;
  border: 1px solid var(--color-border);
  color: var(--color-text-secondary);
  border-radius: var(--radius-sm);
  width: 28px;
  height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 0.85rem;
  margin-left: 6px;
}
.marker-tl-vertical-btn:hover {
  border-color: var(--color-brand-blue);
  color: var(--color-brand-blue);
}
.marker-tl-vertical-btn.is-active {
  border-color: var(--color-border);
  color: var(--color-text-secondary);
  background: none;
}
.marker-tl-vertical-btn.is-active:hover {
  border-color: var(--color-brand-blue);
  color: var(--color-brand-blue);
}

.marker-tl-rtc-toggle {
  background: none;
  border: 1px solid var(--color-border);
  color: var(--color-text-secondary);
  border-radius: var(--radius-sm);
  height: 28px;
  padding: 0 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  cursor: pointer;
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  margin-left: 2px;
  white-space: nowrap;
}
.marker-tl-rtc-toggle:hover {
  border-color: var(--color-brand-blue);
  color: var(--color-brand-blue);
}
.marker-tl-rtc-toggle.is-active {
  color: var(--color-danger);
  border-color: var(--color-danger);
}
.marker-tl-rtc-toggle.is-active:hover {
  color: var(--color-brand-blue);
  border-color: var(--color-brand-blue);
}

.analyse-schema-widget {
  background: var(--color-bg-elevated);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  padding: var(--spacing-md);
  margin-bottom: var(--spacing-xs);
}

.analyse-schema-widget-header {
  display: flex;
  align-items: center;
  font-weight: 600;
  font-size: 0.85rem;
  color: var(--color-text-secondary);
  margin-bottom: var(--spacing-sm);
}

.analyse-schema-select {
  background: var(--color-bg-elevated);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  color: var(--color-text-primary);
  font-size: 0.85rem;
  font-weight: 600;
  padding: 2px 8px;
  cursor: pointer;
}
.analyse-schema-select:focus {
  outline: none;
  border-color: var(--color-brand);
}

.analyse-schema-category {
  margin-bottom: var(--spacing-xs);
}

.analyse-schema-category-label {
  font-size: 0.7rem;
  color: var(--color-text-muted);
  margin-bottom: 4px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.analyse-schema-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.analyse-schema-btn {
  position: relative;
  padding: 6px 14px 14px;
  border: none;
  border-radius: var(--radius-sm);
  color: white;
  font-size: 0.8rem;
  font-weight: 500;
  cursor: pointer;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.4);
  transition: filter 0.1s, transform 0.1s;
  overflow: hidden;
}
.analyse-schema-btn::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: repeating-conic-gradient(rgba(255, 255, 255, 0.15) 0deg 10deg, transparent 10deg 20deg);
  background-position: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.15s;
}
.analyse-schema-btn:hover {
  filter: brightness(1.15);
}
.analyse-schema-btn:active {
  transform: scale(0.96);
}
.analyse-schema-btn.is-flash {
  animation: schema-btn-flash 0.4s ease;
}
.analyse-schema-btn.is-flash::after {
  animation: schema-btn-radial-flash 0.4s ease;
}
.analyse-schema-btn.is-recording {
  animation: schema-btn-recording 1s ease-in-out infinite;
  box-shadow: 0 0 0 2px white;
}
.analyse-schema-btn.is-recording::after {
  opacity: 1;
}

.analyse-schema-canvas-mode {
  position: relative;
}

.analyse-canvas-viewport {
  position: relative;
  height: clamp(280px, 42vh, 600px);
  overflow: hidden;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  background-color: var(--color-bg);
  background-image: radial-gradient(rgba(255, 255, 255, 0.07) 1px, transparent 1px);
  background-size: 22px 22px;
  cursor: grab;
  touch-action: none;
  user-select: none;
}
.analyse-canvas-viewport.is-panning {
  cursor: grabbing;
}

.analyse-canvas-surface {
  position: absolute;
  top: 0;
  left: 0;
  width: 0;
  height: 0;
  transform-origin: 0 0;
}

.analyse-schema-btn-canvas {
  white-space: nowrap;
  touch-action: none;
}
.analyse-schema-btn-canvas.is-dragging {
  opacity: 0.85;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.55);
  z-index: 10;
}

.analyse-schema-canvas-mode.is-arranging .analyse-schema-btn-canvas {
  cursor: move;
  outline: 1px dashed rgba(255, 255, 255, 0.35);
  outline-offset: 1px;
}

.analyse-canvas-toolbar {
  position: absolute;
  top: 6px;
  right: 6px;
  z-index: 5;
  display: flex;
  gap: 4px;
}

.analyse-canvas-tool {
  width: 26px;
  height: 26px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  background: var(--color-bg-elevated);
  color: var(--color-text-secondary);
  font-size: 0.75rem;
  cursor: pointer;
  transition: background 0.1s, color 0.1s;
}
.analyse-canvas-tool:hover {
  color: var(--color-text-primary);
  border-color: var(--color-brand);
}
.analyse-canvas-tool.active {
  background: var(--color-brand);
  border-color: var(--color-brand);
  color: #fff;
}

.analyse-flow-zone {
  position: absolute;
  min-width: 150px;
  max-width: 240px;
  padding: 8px 10px;
  background: var(--color-bg-elevated);
  border: 1px solid var(--color-brand-blue);
  border-radius: var(--radius-md);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.5);
  z-index: 8;
  animation: flow-zone-pop 0.2s ease;
}
.analyse-flow-zone .analyse-note-input {
  width: 100%;
  margin-top: 4px;
}

.analyse-flow-zone-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--color-text-muted);
  margin-bottom: 6px;
}

.analyse-flow-zone-step {
  color: var(--color-brand-blue);
  font-weight: 700;
}

.analyse-flow-zone-actions {
  display: flex;
  gap: 6px;
  margin-top: 8px;
}

.analyse-flow-back,
.analyse-flow-skip,
.analyse-flow-done {
  font-size: 0.7rem;
  padding: 2px 10px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--color-border);
  background: transparent;
  color: var(--color-text-secondary);
  cursor: pointer;
}
.analyse-flow-back:hover,
.analyse-flow-skip:hover,
.analyse-flow-done:hover {
  color: var(--color-text-primary);
  border-color: var(--color-brand);
}

.analyse-flow-done {
  background: var(--color-brand);
  border-color: var(--color-brand);
  color: #fff;
}

@keyframes flow-zone-pop {
  from {
    opacity: 0;
    transform: scale(0.9);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}
.analyse-flow-chip {
  position: absolute;
  top: 8px;
  left: 8px;
  z-index: 9;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 4px 6px 4px 10px;
  background: var(--color-bg-elevated);
  border: 1px solid var(--color-brand-blue);
  border-radius: 999px;
  font-size: 0.75rem;
  color: var(--color-text-primary);
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.4);
}

.analyse-flow-chip-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--color-brand-blue);
  animation: flow-chip-pulse 1s ease-in-out infinite;
}

@keyframes flow-chip-pulse {
  0%, 100% {
    opacity: 1;
  }
  50% {
    opacity: 0.3;
  }
}
.analyse-flow-chip-cancel {
  border: none;
  background: transparent;
  color: var(--color-text-muted);
  cursor: pointer;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
}
.analyse-flow-chip-cancel:hover {
  color: var(--color-text-primary);
  background: rgba(255, 255, 255, 0.08);
}

.analyse-flow-zone-ghost {
  position: absolute;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  background: rgba(var(--color-brand-blue-rgb), 0.14);
  border: 1px dashed var(--color-brand-blue);
  border-radius: var(--radius-sm);
  color: var(--color-text-secondary);
  font-size: 0.7rem;
  white-space: nowrap;
  cursor: move;
  touch-action: none;
  z-index: 7;
}
.analyse-flow-zone-ghost.is-dragging {
  opacity: 0.85;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.5);
  z-index: 11;
}

.analyse-flow-zone-ghost-step {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 15px;
  height: 15px;
  border-radius: 50%;
  background: var(--color-brand-blue);
  color: #fff;
  font-size: 0.6rem;
  font-weight: 700;
}

.analyse-canvas-connectors {
  z-index: 0;
}

.analyse-canvas-connectors line {
  stroke-width: 2;
  opacity: 0.6;
  vector-effect: non-scaling-stroke;
}

.analyse-canvas-connectors line[data-navlink],
.analyse-canvas-connectors line[data-actionlink=navigate] {
  stroke-dasharray: 5 4;
  opacity: 0.8;
}

.analyse-canvas-connectors line[data-actionlink=trigger] {
  stroke-width: 2.5;
  opacity: 0.85;
}

.analyse-canvas-surface.hide-connectors .analyse-canvas-connectors {
  display: none;
}

.analyse-schema-btn-none {
  outline: 1px dashed rgba(255, 255, 255, 0.65);
  outline-offset: -3px;
}

.markup-nav-node {
  position: absolute;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 12px;
  background: var(--color-bg-elevated);
  border: 1px dashed currentColor;
  border-radius: 999px;
  font-size: 0.78rem;
  font-weight: 600;
  white-space: nowrap;
  cursor: pointer;
  touch-action: none;
  z-index: 5;
  transition: filter 0.1s, transform 0.1s;
}
.markup-nav-node:hover {
  filter: brightness(1.2);
}
.markup-nav-node:active {
  transform: scale(0.96);
}
.markup-nav-node.is-dragging {
  opacity: 0.85;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.5);
  z-index: 12;
}

.markup-bookmark-flag {
  position: absolute;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 3px 9px;
  background: rgba(255, 178, 0, 0.15);
  border: 1px solid var(--color-warning, #ffb200);
  border-radius: var(--radius-sm);
  color: var(--color-warning, #ffb200);
  font-size: 0.7rem;
  white-space: nowrap;
  cursor: move;
  touch-action: none;
  z-index: 6;
}
.markup-bookmark-flag.is-dragging {
  opacity: 0.85;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.5);
  z-index: 12;
}

.markup-bookmark-menu {
  position: absolute;
  z-index: 20;
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 5px;
  background: var(--color-bg-elevated);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.5);
}
.markup-bookmark-menu input, .markup-bookmark-menu select {
  background: var(--color-bg);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  color: var(--color-text-primary);
  font-size: 0.75rem;
  padding: 2px 6px;
}
.markup-bookmark-menu input:focus, .markup-bookmark-menu select:focus {
  outline: none;
  border-color: var(--color-brand);
}
.markup-bookmark-menu input.markup-bookmark-menu-name {
  width: 120px;
}
.markup-bookmark-menu input.markup-nav-menu-color {
  width: 64px;
}
.markup-bookmark-menu button {
  border: 1px solid var(--color-border);
  background: transparent;
  color: var(--color-text-secondary);
  border-radius: var(--radius-sm);
  font-size: 0.7rem;
  padding: 2px 8px;
  cursor: pointer;
  white-space: nowrap;
}
.markup-bookmark-menu button:hover {
  color: var(--color-text-primary);
  border-color: var(--color-brand);
}
.markup-bookmark-menu .markup-bookmark-menu-del:hover {
  color: var(--color-danger, #e5484d);
  border-color: var(--color-danger, #e5484d);
}

.analyse-schema-btn-times {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 3px;
  height: 10px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0 4px;
  font-size: 0.55rem;
  font-weight: 400;
  opacity: 0.7;
  text-shadow: none;
  pointer-events: none;
}
.analyse-schema-btn-times i {
  margin-right: 1px;
}
.analyse-schema-btn-times .analyse-schema-btn-note {
  line-height: 1;
}

@keyframes schema-btn-flash {
  0% {
    filter: brightness(2);
  }
  100% {
    filter: brightness(1);
  }
}
@keyframes schema-btn-recording {
  0%, 100% {
    filter: brightness(1);
  }
  50% {
    filter: brightness(1.4);
  }
}
@keyframes schema-btn-radial-flash {
  0% {
    opacity: 1;
  }
  100% {
    opacity: 0;
  }
}
.analyse-qual-picker {
  background: var(--color-bg-elevated);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  padding: var(--spacing-sm);
  margin-bottom: var(--spacing-md);
  display: flex;
  flex-wrap: wrap;
  gap: var(--spacing-md);
}
.analyse-qual-picker.is-attention {
  animation: qual-picker-attention 0.6s ease 5;
}

@keyframes qual-picker-attention {
  0%, 100% {
    border-color: var(--color-border);
  }
  50% {
    border-color: var(--color-brand-blue);
  }
}
.analyse-qual-list {
  min-width: 120px;
}

.analyse-qual-list-name {
  font-size: 0.7rem;
  color: var(--color-text-muted);
  margin-bottom: 4px;
  text-transform: uppercase;
}

.analyse-qual-btns {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
}

.analyse-qual-btn {
  position: relative;
  padding: 4px 10px;
  border: 2px solid transparent;
  border-radius: var(--radius-sm);
  color: white;
  font-size: 0.75rem;
  cursor: pointer;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.4);
  overflow: hidden;
}
.analyse-qual-btn::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: repeating-conic-gradient(rgba(255, 255, 255, 0.15) 0deg 10deg, transparent 10deg 20deg);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.15s;
}
.analyse-qual-btn:hover {
  filter: brightness(1.15);
}
.analyse-qual-btn.is-selected {
  border-color: white;
}
.analyse-qual-btn.is-selected::after {
  opacity: 1;
}

.analyse-qual-actions {
  display: flex;
  gap: var(--spacing-sm);
  align-items: flex-end;
  margin-left: auto;
}

.analyse-qual-done {
  padding: 6px 16px;
  background: var(--color-brand);
  border: none;
  border-radius: var(--radius-sm);
  color: white;
  font-size: 0.8rem;
  cursor: pointer;
}
.analyse-qual-done:hover {
  filter: brightness(1.15);
}

.analyse-qual-cancel {
  padding: 6px 16px;
  background: none;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  color: var(--color-text-secondary);
  font-size: 0.8rem;
  cursor: pointer;
}
.analyse-qual-cancel:hover {
  border-color: var(--color-border-hover);
}

.analyse-note-input {
  width: 100%;
  margin-top: var(--spacing-xs);
  padding: 6px 8px;
  background: var(--color-bg-secondary);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  color: var(--color-text);
  font-size: 0.8rem;
  resize: vertical;
}
.analyse-note-input::placeholder {
  color: var(--color-text-muted);
}

#marker-timeline {
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
  padding-bottom: var(--spacing-sm);
}

.marker-tl {
  background: var(--color-bg-secondary);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  overflow: hidden;
  margin-bottom: 0;
  user-select: none;
  display: flex;
  flex-direction: column;
  flex: 1;
  min-height: 0;
  container-type: inline-size;
}

@container (max-width: 640px) {
  .marker-tl-controls {
    flex-wrap: wrap;
    overflow-x: visible;
    row-gap: 4px;
  }
}
.marker-tl-empty {
  padding: 2rem;
  text-align: center;
  color: var(--color-text-muted);
  font-size: 0.9rem;
}

.marker-tl-controls {
  display: flex;
  align-items: center;
  gap: var(--spacing-sm);
  padding: var(--spacing-xs) var(--spacing-sm);
  border-bottom: 1px solid var(--color-border);
  background: var(--color-bg-elevated);
  overflow-x: auto;
  scrollbar-width: none;
}
.marker-tl-controls::-webkit-scrollbar {
  display: none;
}
.marker-tl-controls > * {
  flex-shrink: 0;
}
.marker-tl-controls button:focus:not(:focus-visible) {
  outline: none;
  box-shadow: none;
}

.marker-tl-note-btn,
.marker-tl-delete-btn,
.marker-tl-cut-sel-btn,
.marker-tl-composer-export-btn {
  background: none;
  border: 1px solid var(--color-border);
  color: var(--color-text-secondary);
  border-radius: var(--radius-sm);
  width: 28px;
  height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 0.85rem;
  margin-right: var(--spacing-sm);
}

.marker-tl-note-btn:hover {
  border-color: var(--color-brand-blue);
  color: var(--color-brand-blue);
}

.marker-tl-delete-btn:hover {
  border-color: var(--bs-danger);
  color: var(--bs-danger);
}

.marker-tl-cut-sel-btn:hover {
  border-color: var(--color-brand-blue);
  color: var(--color-brand-blue);
}

.marker-tl-composer-export-btn:hover {
  border-color: var(--color-brand-blue);
  color: var(--color-brand-blue);
}

.marker-tl-composer-export-btn.is-exporting {
  pointer-events: none;
  border-color: var(--color-brand-blue);
  color: var(--color-brand-blue);
}
.marker-tl-composer-export-btn.is-exporting svg {
  animation: composer-export-spin 1s linear infinite;
}

@keyframes composer-export-spin {
  from {
    transform: rotate(0deg);
  }
  to {
    transform: rotate(360deg);
  }
}
.marker-tl-export-progress {
  display: flex;
  align-items: center;
  gap: var(--spacing-sm);
  padding: 4px var(--spacing-sm);
  border-bottom: 1px solid var(--color-border);
  background: var(--color-bg-elevated);
  font-size: 0.75rem;
  color: var(--color-text-secondary);
}

.marker-tl-export-bar {
  flex: 1;
  height: 6px;
  background: var(--color-border);
  border-radius: 3px;
  overflow: hidden;
}

.marker-tl-export-bar-fill {
  height: 100%;
  background: var(--color-brand-blue);
  border-radius: 3px;
  transition: width 0.3s ease;
}

.marker-tl-export-bar-fill.is-zipping {
  width: 100% !important;
  animation: export-pulse 1.2s ease-in-out infinite;
}

@keyframes export-pulse {
  0%, 100% {
    opacity: 1;
  }
  50% {
    opacity: 0.5;
  }
}
.marker-tl-export-label {
  white-space: nowrap;
  flex-shrink: 0;
}

.marker-tl-sort-dropdown .dropdown-menu {
  z-index: 1060 !important;
}

.marker-tl-label-spacer {
  overflow: visible;
  position: relative;
  z-index: 10;
}

.marker-tl-create-row-btn,
.marker-tl-sort-btn,
.marker-tl-fit-labels-btn {
  background: none;
  border: 1px solid var(--color-border);
  color: var(--color-text-secondary);
  border-radius: var(--radius-sm);
  width: 20px;
  height: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 0.65rem;
  padding: 0;
}
.marker-tl-create-row-btn:hover,
.marker-tl-sort-btn:hover,
.marker-tl-fit-labels-btn:hover {
  border-color: var(--color-brand-blue);
  color: var(--color-brand-blue);
}

.marker-tl-spacer-fill {
  flex: 1;
}

.marker-tl-zoom-btn {
  background: none;
  border: 1px solid var(--color-border);
  color: var(--color-text-secondary);
  border-radius: var(--radius-sm);
  width: 28px;
  height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 0.85rem;
}
.marker-tl-zoom-btn:hover {
  border-color: var(--color-brand-blue);
  color: var(--color-brand-blue);
}
.marker-tl-zoom-btn.is-active {
  border-color: var(--color-brand-blue);
  color: var(--color-brand-blue);
  background: rgba(var(--color-brand-blue-rgb, 59, 130, 246), 0.12);
}

.marker-tl-zoom-label {
  font-size: 0.7rem;
  color: var(--color-text-secondary);
  min-width: 36px;
  text-align: center;
}

.marker-tl-expand-btn {
  background: none;
  border: 1px solid var(--color-border);
  color: var(--color-text-secondary);
  border-radius: var(--radius-sm);
  height: 28px;
  display: flex;
  align-items: center;
  cursor: pointer;
  font-size: 0.7rem;
  padding: 0 8px;
  margin-left: 6px;
}
.marker-tl-expand-btn:hover {
  border-color: var(--color-brand-blue);
  color: var(--color-brand-blue);
}

.marker-tl-help-btn {
  background: none;
  border: 1px solid var(--color-border);
  color: var(--color-text-secondary);
  border-radius: var(--radius-sm);
  width: 28px;
  height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 0.85rem;
  margin-left: 6px;
}
.marker-tl-help-btn:hover {
  border-color: var(--color-brand-blue);
  color: var(--color-brand-blue);
}

.marker-tl-help-table {
  width: 100%;
  font-size: 0.8rem;
}
.marker-tl-help-table td {
  padding: 4px 8px;
  border-bottom: 1px solid var(--color-border);
}
.marker-tl-help-table td:first-child {
  white-space: nowrap;
  width: 1%;
}
.marker-tl-help-table kbd {
  background: var(--color-bg-secondary);
  border: 1px solid var(--color-border);
  border-radius: 3px;
  padding: 1px 6px;
  font-size: 0.7rem;
  font-family: inherit;
}

.marker-tl-controls-spacer {
  flex: 1;
  min-width: 0;
}

.marker-tl-time {
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--color-text-primary);
  font-variant-numeric: tabular-nums;
}

.marker-tl-rate-indicator {
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--color-brand-blue);
  margin-left: var(--spacing-xs);
  min-width: 32px;
}

.marker-tl-live-btn {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 0.65rem;
  font-weight: 700;
  color: #e53e3e;
  margin-right: var(--spacing-xs);
  letter-spacing: 0.05em;
  background: none;
  border: 1px solid #e53e3e;
  border-radius: var(--radius-sm);
  padding: 2px 8px;
  cursor: pointer;
}
.marker-tl-live-btn:hover {
  background: rgba(229, 62, 62, 0.15);
}
.marker-tl-live-btn:disabled {
  opacity: 0.35;
  cursor: default;
  pointer-events: none;
}

.marker-tl-live-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #e53e3e;
}

.marker-tl-live-btn.is-webrtc .marker-tl-live-dot {
  animation: marker-tl-live-pulse 1.5s ease-in-out infinite;
}

@keyframes marker-tl-live-pulse {
  0%, 100% {
    opacity: 1;
  }
  50% {
    opacity: 0.3;
  }
}
.marker-tl-play-btn,
.marker-tl-play-selection-btn,
.marker-tl-rw-btn,
.marker-tl-ff-btn {
  background: none;
  border: 1px solid var(--color-border);
  color: var(--color-text-secondary);
  border-radius: var(--radius-sm);
  width: 28px;
  height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 0.75rem;
  margin-left: var(--spacing-xs);
}
.marker-tl-play-btn:hover,
.marker-tl-play-selection-btn:hover,
.marker-tl-rw-btn:hover,
.marker-tl-ff-btn:hover {
  border-color: var(--color-brand-blue);
  color: var(--color-brand-blue);
}

.marker-tl-cut-btn {
  background: none;
  border: 1px solid var(--color-border);
  color: var(--color-text-secondary);
  border-radius: var(--radius-sm);
  width: 28px;
  height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 0.75rem;
  margin-left: var(--spacing-xs);
}
.marker-tl-cut-btn:hover {
  border-color: var(--color-text-primary);
  color: var(--color-text-primary);
}
.marker-tl-cut-btn.is-active {
  border-color: var(--color-brand-blue);
  color: var(--color-brand-blue);
  background: rgba(var(--color-brand-blue-rgb, 59, 130, 246), 0.12);
}
.marker-tl-cut-btn.is-multi {
  border-color: var(--color-brand-orange, #f59e0b);
  color: var(--color-brand-orange, #f59e0b);
  background: rgba(245, 158, 11, 0.12);
}

.marker-tl-cut-multi-icon {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1em;
  height: 1em;
}
.marker-tl-cut-multi-icon i {
  position: absolute;
  font-size: 0.6em;
}
.marker-tl-cut-multi-icon i:first-child {
  transform: translate(-2px, -2px);
}
.marker-tl-cut-multi-icon i:last-child {
  transform: translate(2px, 2px);
}

.marker-tl-speed-btn {
  background: none;
  border: 1px solid var(--color-border);
  color: var(--color-text-secondary);
  border-radius: var(--radius-sm);
  height: 28px;
  width: auto;
  padding: 0 6px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 0.65rem;
  font-weight: 600;
  margin-left: var(--spacing-xs);
}
.marker-tl-speed-btn:hover {
  border-color: var(--color-brand-blue);
  color: var(--color-brand-blue);
}
.marker-tl-speed-btn.active {
  border-color: var(--color-brand-blue);
  color: var(--color-brand-blue);
}

.marker-tl-speed-play-icon {
  margin-right: 4px;
  font-size: 0.55rem;
}

.marker-tl-speed-caret {
  margin-left: 3px;
  opacity: 0.6;
  padding: 2px;
}
.marker-tl-speed-caret:hover {
  opacity: 1;
}

.marker-tl-speed-group {
  position: relative;
}

.marker-tl-speed-menu {
  min-width: auto;
  padding: 4px 0;
  z-index: 1000;
}
.marker-tl-speed-menu .dropdown-item {
  font-size: 0.75rem;
  padding: 4px 12px;
}

.marker-tl-body {
  display: flex;
  overflow: hidden;
  position: relative;
  flex: 1;
  min-height: 0;
}

.marker-tl-vertical {
  display: none;
  flex: 1;
  overflow: hidden;
  min-height: 0;
}

.marker-tl-labels {
  flex-shrink: 0;
  width: 140px;
  min-width: 60px;
  max-width: 400px;
  overflow: hidden;
  border-right: 1px solid var(--color-border);
  background: var(--color-bg-secondary);
  z-index: 2;
  position: relative;
}

.marker-tl-resize {
  position: absolute;
  right: 0;
  top: 0;
  width: 5px;
  height: 100%;
  cursor: col-resize;
  z-index: 3;
}
.marker-tl-resize:hover, .marker-tl-resize.is-dragging {
  background: var(--color-brand-blue);
  opacity: 0.5;
}

.marker-tl-label-spacer {
  height: 24px;
  border-bottom: 1px solid var(--color-border);
  position: sticky;
  top: 0;
  background: var(--color-bg-secondary);
  z-index: 1;
  display: flex;
  align-items: center;
  padding: 0 4px;
  gap: 2px;
}
.marker-tl-label-spacer button:focus:not(:focus-visible) {
  outline: none;
  box-shadow: none;
}

.marker-tl-label {
  height: 32px;
  display: flex;
  align-items: center;
  padding: 0 var(--spacing-sm);
  font-size: 0.75rem;
  font-weight: 500;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  border-bottom: 1px solid rgba(255, 255, 255, 0.03);
  color: var(--color-text-secondary);
  cursor: pointer;
}
.marker-tl-label.is-active {
  color: white;
  font-weight: 600;
  background: var(--color-bg-elevated);
}

.marker-tl-label-num {
  font-size: 0.65rem;
  color: var(--color-text-muted);
  min-width: 16px;
  text-align: right;
  margin-right: 6px;
  flex-shrink: 0;
}

.marker-tl-label-grip {
  color: var(--color-text-muted);
  cursor: grab;
  margin-right: 2px;
  flex-shrink: 0;
  opacity: 0;
}

.marker-tl-label:hover .marker-tl-label-grip {
  opacity: 0.5;
}

.marker-tl-label-grip:hover {
  opacity: 1 !important;
  color: var(--color-text-secondary);
}

.marker-tl-label.is-dragging {
  opacity: 0.4;
}

.marker-tl-drop-indicator {
  position: absolute;
  left: 0;
  right: 0;
  height: 2px;
  background: var(--color-brand-blue);
  z-index: 4;
  pointer-events: none;
}

.marker-tl-label-ghost {
  position: fixed;
  height: 32px;
  display: flex;
  align-items: center;
  padding: 0 var(--spacing-sm);
  font-size: 0.75rem;
  font-weight: 600;
  white-space: nowrap;
  color: white;
  background: var(--color-bg-elevated);
  border: 1px solid var(--color-brand-blue);
  border-radius: 4px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
  opacity: 0.9;
  pointer-events: none;
  z-index: 9999;
  transform: scale(1.03);
}

.marker-tl-label-bar {
  width: 3px;
  height: 100%;
  margin-right: 6px;
  flex-shrink: 0;
  border-radius: 1px;
}

.marker-tl-scroll {
  flex: 1;
  overflow: auto;
  position: relative;
}
.marker-tl-scroll.is-fitted {
  overflow-x: hidden;
}
.marker-tl-scroll {
  scrollbar-width: thin;
  scrollbar-color: rgba(255, 255, 255, 0.2) var(--color-bg-secondary);
  scroll-behavior: auto;
}
.marker-tl-scroll::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}
.marker-tl-scroll::-webkit-scrollbar-track {
  background: var(--color-bg-secondary);
}
.marker-tl-scroll::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.2);
  border-radius: 3px;
}
.marker-tl-scroll::-webkit-scrollbar-thumb:hover {
  background: rgba(255, 255, 255, 0.35);
}
.marker-tl-scroll::-webkit-scrollbar-corner {
  background: var(--color-bg-secondary);
}

.marker-tl-canvas {
  position: relative;
  min-width: 100%;
}

.marker-tl-axis {
  position: sticky;
  top: 0;
  height: 24px;
  min-width: 100%;
  background: var(--color-bg-elevated);
  border-bottom: 1px solid var(--color-border);
  z-index: 4;
}

.marker-tl-tick {
  position: absolute;
  top: 0;
  height: 100%;
  border-left: 1px solid rgba(255, 255, 255, 0.06);
  font-size: 0.65rem;
  color: var(--color-text-muted);
  padding-left: 4px;
  line-height: 24px;
  white-space: nowrap;
  user-select: none;
}

.marker-tl-rows {
  position: relative;
  overflow: hidden;
}

.marker-tl-row {
  position: relative;
  height: 32px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.03);
}
.marker-tl-row.is-selected-row {
  background: var(--color-bg-elevated);
}
.marker-tl-row.is-selected-row .marker-tl-clip {
  outline: 2px solid white;
  outline-offset: -1px;
  opacity: 1;
}

.marker-tl-clip {
  position: absolute;
  top: 4px;
  height: 24px;
  border-radius: 4px;
  cursor: pointer;
  opacity: 0.85;
  transition: opacity 0.1s ease, filter 0.1s ease;
  min-width: 6px;
  overflow: hidden;
  user-select: none;
}
.marker-tl-clip:hover {
  opacity: 1;
  filter: brightness(1.2);
  z-index: 1;
}
.marker-tl-clip.is-selected {
  outline: 2px solid white;
  outline-offset: -1px;
  opacity: 1;
  z-index: 2;
}

.marker-tl-clip-label {
  font-size: 0.6rem;
  color: white;
  padding: 0 4px;
  line-height: 24px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.5);
}

.marker-tl-clip-handle {
  position: absolute;
  top: 0;
  bottom: 0;
  width: 6px;
  cursor: inherit;
  z-index: 3;
}
.marker-tl-clip-handle.left {
  left: 0;
}
.marker-tl-clip-handle.right {
  right: 0;
}

#marker-timeline.shift-held .marker-tl-clip-handle {
  cursor: col-resize;
}

.marker-tl-clip:hover .marker-tl-clip-handle {
  background: rgba(255, 255, 255, 0.15);
}

.marker-tl-clip-preview {
  position: absolute;
  top: 2px;
  bottom: 2px;
  opacity: 0.5;
  border-radius: 3px;
  pointer-events: none;
  z-index: 5;
}

.marker-tl-rows.is-paintable .marker-tl-row {
  cursor: crosshair;
}

.marker-tl-clip-ghost {
  position: absolute;
  height: 24px;
  border-radius: 4px;
  opacity: 0.5;
  pointer-events: none;
  z-index: 10;
  border: 2px dashed rgba(255, 255, 255, 0.7);
}

.marker-tl-row.is-copy-target {
  background: rgba(255, 255, 255, 0.08);
}

.marker-tl-rows.is-copyable .marker-tl-clip {
  cursor: copy;
}

.marker-tl-playhead {
  position: absolute;
  top: 0;
  width: 2px;
  background: none;
  z-index: 3;
  pointer-events: none;
  transform: translateX(-1px);
}
.marker-tl-playhead::after {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 2px;
  bottom: 0;
  background: white;
  box-shadow: 0 0 4px rgba(255, 255, 255, 0.3);
}

.marker-tl-playhead-dot {
  display: none;
  position: absolute;
  left: -4px;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--color-brand);
  border: 1px solid white;
  transform: translateY(-50%);
  z-index: 4;
}

.marker-tl-playhead-handle {
  position: absolute;
  top: 2px;
  transform: translateX(-50%);
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: var(--color-brand);
  border: 1px solid white;
  cursor: grab;
  z-index: 5;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.4);
  touch-action: none;
  transition: transform 0.12s;
}
.marker-tl-playhead-handle:active {
  cursor: grabbing;
}
.marker-tl-playhead-handle.is-dragging {
  transform: translateX(-50%) scale(1.35);
}

.marker-tl-axis {
  touch-action: none;
}

@media (pointer: coarse) {
  .marker-tl-playhead-handle::before {
    content: "";
    position: absolute;
    inset: -12px;
    border-radius: 50%;
  }
  .marker-tl-playhead {
    touch-action: none;
  }
  .marker-tl-playhead::before {
    content: "";
    position: absolute;
    top: 0;
    bottom: 0;
    left: -13px;
    width: 28px;
    pointer-events: auto;
  }
}
.tl-scrub-bubble {
  position: fixed;
  z-index: 2000;
  transform: translateX(-50%);
  padding: 6px 12px;
  border-radius: 999px;
  background: var(--color-brand);
  color: #fff;
  font-size: 1rem;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.5);
  pointer-events: none;
  white-space: nowrap;
}

.marker-tl-tooltip {
  position: fixed;
  padding: 6px 10px;
  background: rgba(0, 0, 0, 0.9);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  color: var(--color-text-primary);
  font-size: 0.75rem;
  pointer-events: none;
  z-index: 100;
  max-width: 300px;
  transform: translateX(-50%);
  word-wrap: break-word;
}

.marker-tl-tooltip-name {
  font-weight: 600;
}

.marker-tl-tooltip-time {
  color: var(--color-text-muted);
  margin-left: 0.5rem;
}

.marker-tl-tooltip-note {
  color: var(--color-text-secondary);
  white-space: normal;
  margin-top: 2px;
}

.marker-tl-tooltip-quals {
  display: flex;
  flex-wrap: wrap;
  gap: 3px;
  margin-top: 3px;
}

.marker-tl-tooltip-qual {
  font-size: 0.65rem;
}

.marker-tl-context-menu {
  position: fixed;
  z-index: 1000;
  min-width: 140px;
  padding: 4px 0;
  font-size: 0.8rem;
}

#cut-modal .modal-content {
  border: 1px solid var(--color-border);
  overflow: hidden;
}
#cut-modal .modal-header {
  border-bottom: 1px solid var(--color-border);
  background: var(--color-bg-elevated);
}
#cut-modal .modal-header .modal-title {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--color-text-primary);
}
#cut-modal .modal-body video {
  display: block;
  background: #000;
  max-height: 70vh;
}

.analyse-clip-overlay {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.45);
  backdrop-filter: blur(4px);
  padding: 5px 12px;
  z-index: 9;
  pointer-events: none;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 4px 8px;
  font-size: 0.75rem;
  color: white;
  transition: opacity 0.15s ease;
}
.analyse-clip-overlay.is-top {
  top: 0;
  bottom: auto;
}

.analyse-clip-overlay:not(.is-top) {
  transition: opacity 0.15s ease, bottom 0.2s ease;
}

.analyse-video-container:has(> .analyse-overlay-controls.is-visible) > .analyse-clip-overlay:not(.is-top) {
  bottom: var(--aoc-h, 0px);
}

@media (hover: none), (pointer: coarse) {
  .analyse-video-container > .analyse-clip-overlay:not(.is-top) {
    bottom: var(--aoc-h, 0px);
  }
}
.analyse-video-container.tp-chrome-hidden > .analyse-clip-overlay:not(.is-top),
body.analyse-mobile .analyse-video-container > .analyse-clip-overlay:not(.is-top) {
  bottom: 0 !important;
}

.analyse-clip-overlay-swatch {
  width: 4px;
  height: 20px;
  border-radius: 2px;
  flex-shrink: 0;
}

.analyse-clip-overlay-name {
  font-weight: 600;
  white-space: nowrap;
}

.analyse-clip-overlay-quals {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
}

.analyse-clip-overlay-qual {
  font-size: 0.65rem;
  font-weight: 500;
}

.analyse-clip-overlay-note {
  color: var(--color-text-secondary);
  font-size: 0.7rem;
  width: 100%;
}

.analyse-cut-banner {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 6px 12px;
  background: rgba(0, 0, 0, 0.8);
  color: white;
  font-size: 0.8rem;
  z-index: 10;
  backdrop-filter: blur(4px);
}
.analyse-cut-banner .analyse-cut-banner-back {
  background: none;
  border: 1px solid rgba(255, 255, 255, 0.4);
  color: white;
  border-radius: var(--radius-sm);
  padding: 2px 10px;
  font-size: 0.75rem;
  cursor: pointer;
}
.analyse-cut-banner .analyse-cut-banner-back:hover {
  border-color: white;
  background: rgba(255, 255, 255, 0.1);
}

.analyse-cut-hint {
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 6px 10px;
  margin-bottom: 6px;
  background: var(--color-bg-elevated);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  font-size: 0.75rem;
  color: var(--color-text-secondary);
}
.analyse-cut-hint .analyse-cut-hint-mode {
  background: none;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  color: var(--color-text-secondary);
  cursor: pointer;
  padding: 2px 6px;
  font-size: 0.6rem;
  line-height: 1;
  margin-left: 2px;
}
.analyse-cut-hint .analyse-cut-hint-mode:hover {
  border-color: var(--color-brand-blue);
  color: var(--color-brand-blue);
}
.analyse-cut-hint .analyse-cut-hint-mode[data-mode=multi]:hover {
  border-color: var(--color-brand-orange, #f59e0b);
  color: var(--color-brand-orange, #f59e0b);
}
.analyse-cut-hint .analyse-cut-hint-mode .marker-tl-cut-multi-icon {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.4em;
  height: 1em;
}
.analyse-cut-hint .analyse-cut-hint-mode .marker-tl-cut-multi-icon i {
  position: absolute;
  font-size: 0.8em;
}
.analyse-cut-hint .analyse-cut-hint-mode .marker-tl-cut-multi-icon i:first-child {
  transform: translate(-3px, -2px);
}
.analyse-cut-hint .analyse-cut-hint-mode .marker-tl-cut-multi-icon i:last-child {
  transform: translate(3px, 2px);
}
.analyse-cut-hint .analyse-cut-hint-dismiss {
  margin-left: auto;
  background: none;
  border: none;
  color: var(--color-text-muted);
  cursor: pointer;
  padding: 0 2px;
}
.analyse-cut-hint .analyse-cut-hint-dismiss:hover {
  color: var(--color-text-primary);
}

.pip-preview {
  position: fixed;
  z-index: 950;
  width: 320px;
  min-width: 200px;
  max-width: 80vw;
  background: var(--color-bg-elevated);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.5);
  right: 20px;
  bottom: 80px;
}

.pip-preview-header {
  display: flex;
  align-items: center;
  padding: 4px 8px;
  background: rgba(0, 0, 0, 0.6);
  cursor: grab;
  touch-action: none;
  user-select: none;
}
.pip-preview-header:active {
  cursor: grabbing;
}

.pip-preview-badge {
  font-size: 0.55rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: var(--color-danger);
}
.pip-preview-badge::before {
  content: "";
  display: inline-block;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--color-danger);
  margin-right: 4px;
  vertical-align: middle;
  animation: marker-tl-live-pulse 1.5s ease-in-out infinite;
}

.pip-preview-spacer {
  flex: 1;
}

.pip-preview-btn {
  background: none;
  border: none;
  color: var(--color-text-secondary);
  cursor: pointer;
  padding: 2px 5px;
  font-size: 0.6rem;
  line-height: 1;
}
.pip-preview-btn:hover {
  color: white;
}

.pip-preview-video {
  width: 100%;
  display: block;
  background: #000;
}

.pip-preview-controls {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 4px 8px;
  background: var(--color-bg-elevated);
}
.pip-preview-controls select {
  font-size: 0.6rem;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  padding: 0.1rem 1.5rem 0.1rem 0.35rem;
  height: 20px;
  flex: 1;
  min-width: 0;
}

.pip-preview-follow-label {
  display: flex;
  align-items: center;
  gap: 3px;
  font-size: 0.55rem;
  color: var(--color-text-secondary);
  cursor: pointer;
  white-space: nowrap;
}
.pip-preview-follow-label input {
  margin: 0;
  width: 12px;
  height: 12px;
}

.pip-preview-resize-handle {
  position: absolute;
  right: 0;
  bottom: 0;
  width: 14px;
  height: 14px;
  cursor: nwse-resize;
  touch-action: none;
}
.pip-preview-resize-handle::after {
  content: "";
  position: absolute;
  right: 3px;
  bottom: 3px;
  width: 8px;
  height: 8px;
  border-right: 2px solid rgba(255, 255, 255, 0.3);
  border-bottom: 2px solid rgba(255, 255, 255, 0.3);
}

.pip-preview.is-minimized {
  width: auto !important;
  min-width: 0;
}
.pip-preview.is-minimized .pip-preview-video,
.pip-preview.is-minimized .pip-preview-controls,
.pip-preview.is-minimized .pip-preview-resize-handle {
  display: none;
}

.analyse-pip-btn {
  background: none;
  border: 1px solid var(--color-border);
  color: var(--color-text-secondary);
  border-radius: var(--radius-sm);
  width: 24px;
  height: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 0.6rem;
  margin-right: var(--spacing-sm);
}
.analyse-pip-btn:hover {
  border-color: var(--color-brand-blue);
  color: var(--color-brand-blue);
}
.analyse-pip-btn.is-active {
  border-color: var(--color-brand-blue);
  color: var(--color-brand-blue);
  background: rgba(84, 85, 255, 0.1);
}

.analyse-ll-hls-toggle {
  background: none;
  border: 1px solid var(--color-border);
  color: var(--color-text-secondary);
  border-radius: var(--radius-sm);
  width: 24px;
  height: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 0.6rem;
  margin-right: var(--spacing-sm);
}
.analyse-ll-hls-toggle:hover {
  border-color: var(--color-warning);
  color: var(--color-warning);
}
.analyse-ll-hls-toggle.active {
  border-color: var(--color-warning);
  color: var(--color-warning);
  background: rgba(255, 193, 7, 0.1);
}

.analyse-comms-bar {
  display: flex;
  align-items: center;
  gap: var(--spacing-sm);
  height: 36px;
  padding: 0 var(--spacing-sm);
  margin-bottom: var(--spacing-xs);
  background: var(--color-bg-elevated);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  font-size: 0.8rem;
  -webkit-user-select: none;
  user-select: none;
  -webkit-touch-callout: none;
  touch-action: manipulation;
}
.analyse-comms-bar.comms-active {
  border-color: var(--color-success);
  background: rgba(119, 179, 0, 0.06);
}

.comms-join-btn,
.comms-leave-btn,
.comms-mute-btn,
.comms-ptt-btn {
  border: none;
  background: none;
  color: var(--color-text-secondary);
  cursor: pointer;
  padding: 4px 8px;
  border-radius: var(--radius-sm);
  font-size: 0.8rem;
  white-space: nowrap;
}
.comms-join-btn:hover,
.comms-leave-btn:hover,
.comms-mute-btn:hover,
.comms-ptt-btn:hover {
  background: var(--color-bg-hover);
  color: var(--color-text-primary);
}

.comms-join-btn {
  color: var(--color-success);
  font-weight: 500;
}
.comms-join-btn:hover {
  background: rgba(119, 179, 0, 0.12);
  color: var(--color-success);
}
.comms-join-btn:disabled {
  opacity: 0.5;
  cursor: default;
}

.comms-leave-btn {
  color: var(--color-danger);
  margin-left: auto;
}
.comms-leave-btn:hover {
  background: rgba(239, 68, 68, 0.12);
  color: var(--color-danger);
}

.comms-mute-btn.comms-muted {
  color: var(--color-danger);
}

.comms-ptt-btn {
  display: none;
  touch-action: none;
}
.comms-ptt-mode .comms-ptt-btn {
  display: inline-flex;
}
.comms-ptt-btn.comms-ptt-active {
  background: rgba(119, 179, 0, 0.2);
  color: var(--color-success);
}

@media (pointer: coarse) {
  .analyse-comms-bar {
    height: auto;
    min-height: 48px;
    flex-wrap: wrap;
  }
  .comms-join-btn,
  .comms-leave-btn,
  .comms-mute-btn,
  .comms-ptt-btn,
  .comms-chat-toggle,
  .comms-device-btn {
    min-height: 44px;
    min-width: 44px;
    padding: 8px 14px;
    font-size: 1rem;
    align-items: center;
    justify-content: center;
  }
  .comms-ptt-btn {
    min-width: 88px;
    border: 1px solid var(--color-border);
  }
  .comms-ptt-btn.comms-ptt-active {
    border-color: var(--color-success);
  }
}
.comms-ptt-mode .comms-mute-btn {
  display: none;
}

.comms-mode-toggle {
  display: flex;
  align-items: center;
  margin-left: 2px;
  padding-left: var(--spacing-xs);
  border-left: 1px solid var(--color-border);
}

.comms-ptt-label {
  margin-top: 4px;
}
.comms-ptt-label .checkbox-icon {
  font-size: 0.8rem;
}
.comms-ptt-label .checkbox-label {
  font-size: 0.75rem;
}

.analyse-comms-bar .comms-ptt-label input[type=checkbox]:checked + .checkbox-icon {
  color: var(--color-success);
}
.analyse-comms-bar .comms-ptt-label input[type=checkbox]:checked ~ .checkbox-label {
  color: var(--color-success);
}

.comms-controls {
  display: flex;
  align-items: center;
  gap: 2px;
}

.comms-participants {
  display: flex;
  align-items: center;
  gap: var(--spacing-xs);
  flex: 1;
  overflow-x: auto;
  padding: 0 var(--spacing-xs);
}

.comms-participant {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  padding: 2px 8px;
  border-radius: 12px;
  background: var(--color-bg-hover);
  font-size: 0.75rem;
  white-space: nowrap;
  transition: box-shadow 0.15s ease;
}
.comms-participant.speaking {
  box-shadow: 0 0 0 2px var(--color-success);
}
.comms-participant.muted .comms-participant-mic {
  color: var(--color-text-secondary);
  font-size: 0.6rem;
}
.comms-participant.comms-local {
  background: rgba(84, 85, 255, 0.1);
}

.comms-participant-mic {
  font-size: 0.6rem;
  color: var(--color-success);
}

.comms-remote-mic {
  cursor: pointer;
}
.comms-remote-mic:hover {
  color: var(--color-text-primary);
}

.comms-cursor-toggle {
  font-size: 0.55rem;
  margin-left: 2px;
  cursor: pointer;
  opacity: 0.3;
  transition: opacity 0.15s;
}
.comms-cursor-toggle.is-active {
  opacity: 1;
}
.comms-cursor-toggle:hover {
  opacity: 1;
}

.comms-follow-btn {
  font-size: 0.55rem;
  margin-left: 2px;
  cursor: pointer;
  opacity: 0.7;
  color: var(--color-text-secondary);
  transition: opacity 0.15s, color 0.15s;
}
.comms-follow-btn:hover {
  opacity: 1;
  color: var(--color-brand-blue);
}
.comms-follow-btn.is-following {
  opacity: 1;
  color: var(--color-brand-blue);
}

.comms-participant[data-identity] {
  cursor: pointer;
}

.comms-participant.is-followed {
  background: color-mix(in srgb, var(--comms-pill-color, var(--color-brand-blue)) 22%, transparent);
  box-shadow: inset 0 0 0 1.5px var(--comms-pill-color, var(--color-brand-blue));
}

.comms-following-chip {
  margin-left: 4px;
  padding: 0 6px;
  border-radius: 999px;
  background: var(--comms-pill-color, var(--color-brand-blue));
  color: #fff;
  font-size: 0.62rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  white-space: nowrap;
}
.comms-following-chip.is-suspended {
  background: #d97706;
}

.comms-participant.is-suspended {
  background: rgba(217, 119, 6, 0.16);
  box-shadow: inset 0 0 0 1.5px #d97706;
}

.comms-follow-back,
.comms-follow-stop {
  border: none;
  border-radius: 999px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.7rem;
  line-height: 1;
  touch-action: manipulation;
}

.comms-follow-back {
  margin-left: 4px;
  padding: 3px 10px;
  background: var(--color-brand-blue);
  color: #fff;
  font-weight: 600;
}

.comms-follow-stop {
  margin-left: 2px;
  padding: 3px 6px;
  background: none;
  color: var(--color-text-secondary);
}
@media (hover: hover) {
  .comms-follow-stop:hover {
    color: var(--color-danger);
  }
}

.comms-pmenu {
  position: fixed;
  z-index: 2100;
  min-width: 230px;
  max-width: min(320px, 100vw - 16px);
  padding: 6px;
  border-radius: var(--radius-md);
  background: var(--color-bg-elevated);
  border: 1px solid var(--color-border);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.35);
  color: var(--color-text-primary);
  -webkit-user-select: none;
  user-select: none;
}

.comms-pmenu-head {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 8px 8px;
  border-bottom: 1px solid var(--color-border);
  margin-bottom: 4px;
}

.comms-pmenu-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  flex: 0 0 auto;
}

.comms-pmenu-name {
  font-weight: 600;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.comms-pmenu-where {
  margin-left: auto;
  font-size: 0.75rem;
  color: var(--color-text-secondary);
  white-space: nowrap;
}

.comms-pmenu-row {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  min-height: 46px;
  padding: 8px 12px;
  border: none;
  border-radius: var(--radius-sm);
  background: none;
  color: inherit;
  font-size: 0.95rem;
  text-align: left;
  cursor: pointer;
  touch-action: manipulation;
}
.comms-pmenu-row i {
  width: 18px;
  text-align: center;
  color: var(--color-text-secondary);
}
.comms-pmenu-row:hover, .comms-pmenu-row:active {
  background: var(--color-bg-hover);
}
.comms-pmenu-row.is-primary {
  font-weight: 600;
  color: var(--color-brand-blue);
}
.comms-pmenu-row.is-primary i {
  color: var(--color-brand-blue);
}
.comms-pmenu-row .comms-pmenu-state {
  margin-left: auto;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--color-text-secondary);
}
.comms-pmenu-row.is-on .comms-pmenu-state, .comms-pmenu-row.is-on i {
  color: var(--color-brand-blue);
}

@media (pointer: coarse) {
  .analyse-comms-bar {
    height: auto;
    min-height: 48px;
  }
  .comms-participant {
    min-height: 40px;
    padding: 4px 12px;
    font-size: 0.9rem;
    gap: 4px;
  }
  .comms-participant .comms-participant-mic,
  .comms-participant .comms-cursor-toggle,
  .comms-participant .comms-follow-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 36px;
    font-size: 0.95rem;
    padding: 12px 6px;
    margin: -6px 0;
  }
  .comms-follow-back {
    min-height: 32px;
    padding: 4px 14px;
    font-size: 0.85rem;
  }
  .comms-follow-stop {
    min-width: 36px;
    min-height: 36px;
    margin: -4px -6px -4px 0;
    font-size: 0.95rem;
  }
}
.comms-device-wrapper {
  position: relative;
}

.comms-device-btn {
  border: none;
  background: none;
  color: var(--color-text-secondary);
  cursor: pointer;
  padding: 4px 8px;
  border-radius: var(--radius-sm);
  font-size: 0.8rem;
}
.comms-device-btn:hover, .comms-device-btn.active {
  background: var(--color-bg-hover);
  color: var(--color-text-primary);
}

.comms-device-menu {
  display: none;
  position: absolute;
  top: calc(100% + 6px);
  right: 0;
  width: 280px;
  background: var(--color-bg-elevated);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  padding: var(--spacing-sm);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
  z-index: 1000;
}

.comms-device-section + .comms-device-section {
  margin-top: var(--spacing-sm);
}

.comms-device-heading {
  font-size: 0.7rem;
  font-weight: 600;
  color: var(--color-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.03em;
  margin-bottom: 4px;
}

.comms-vol-row {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 4px;
}
.comms-vol-row:last-child {
  margin-bottom: 0;
}

.comms-vol-name {
  font-size: 0.75rem;
  color: var(--color-text-secondary);
  min-width: 60px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.comms-vol-range {
  flex: 1;
  height: 4px;
  accent-color: var(--color-success);
}

.comms-vol-value {
  font-size: 0.65rem;
  color: var(--color-text-muted);
  min-width: 30px;
  text-align: right;
}

.comms-look-btn,
.comms-chat-toggle {
  border: none;
  background: none;
  color: var(--color-text-secondary);
  cursor: pointer;
  padding: 4px 8px;
  border-radius: var(--radius-sm);
  font-size: 0.8rem;
  position: relative;
}
.comms-look-btn:hover,
.comms-chat-toggle:hover {
  background: var(--color-bg-hover);
  color: var(--color-text-primary);
}
.comms-look-btn.active,
.comms-chat-toggle.active {
  color: var(--color-brand-blue);
}

.comms-chat-badge {
  position: absolute;
  top: 0;
  right: 2px;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--color-danger);
}

.comms-chat-panel {
  display: none;
  position: fixed;
  right: 0;
  bottom: 0;
  width: 320px;
  background: var(--color-bg-elevated);
  border-left: 1px solid var(--color-border);
  border-top-left-radius: var(--radius-md);
  z-index: 900;
  flex-direction: column;
  transition: transform 0.2s ease;
  transform: translateX(100%);
}
.comms-chat-panel.is-open {
  display: flex;
  transform: translateX(0);
}

.analyse-page.comms-chat-open {
  padding-right: calc(320px + var(--spacing-sm));
}

.comms-chat-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 12px;
  border-bottom: 1px solid var(--color-border);
  flex-shrink: 0;
}

.comms-chat-title {
  font-size: 0.85rem;
  font-weight: 600;
}

.comms-chat-look {
  margin-left: auto;
}

.comms-chat-close {
  border: none;
  background: none;
  color: var(--color-text-muted);
  cursor: pointer;
  padding: 2px 6px;
  border-radius: var(--radius-sm);
}
.comms-chat-close:hover {
  background: var(--color-bg-hover);
  color: var(--color-text-primary);
}

.comms-chat-messages {
  flex: 1;
  overflow-y: auto;
  padding: 8px 12px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.comms-chat-msg {
  font-size: 0.8rem;
  line-height: 1.35;
}

.comms-chat-msg-sender {
  font-weight: 600;
  font-size: 0.75rem;
  margin-right: 4px;
}

.comms-chat-msg-time {
  font-size: 0.6rem;
  color: var(--color-text-muted);
  margin-left: 4px;
}

.comms-chat-msg-text {
  color: var(--color-text-primary);
}

.comms-chat-msg {
  position: relative;
}

.comms-chat-msg-delete {
  display: none;
  position: absolute;
  top: 0;
  right: 0;
  border: none;
  background: var(--color-bg-elevated);
  color: var(--color-text-muted);
  cursor: pointer;
  padding: 2px 4px;
  font-size: 0.6rem;
  border-radius: var(--radius-sm);
}
.comms-chat-msg-delete:hover {
  color: var(--color-danger);
}

.comms-chat-msg.is-local:hover .comms-chat-msg-delete {
  display: block;
}

.comms-chat-system {
  font-size: 0.7rem;
  color: var(--color-text-muted);
  font-style: italic;
  text-align: center;
  padding: 2px 0;
}

.comms-chat-clip {
  background: var(--color-bg-hover);
  border-radius: var(--radius-sm);
  padding: 6px 10px;
  margin-top: 2px;
  cursor: pointer;
  border-left: 3px solid var(--color-brand);
  transition: background 0.15s ease;
}
.comms-chat-clip:hover {
  background: rgba(84, 85, 255, 0.12);
}

.comms-chat-clip-name {
  font-weight: 600;
  font-size: 0.8rem;
}

.comms-chat-clip-time {
  font-size: 0.7rem;
  color: var(--color-text-muted);
}

.comms-chat-clip-note {
  font-size: 0.7rem;
  color: var(--color-text-secondary);
  margin-top: 2px;
}

.comms-chat-clip-actions {
  display: flex;
  gap: 6px;
  margin-top: 4px;
}

.comms-chat-clip-play,
.comms-chat-clip-dl {
  display: inline-flex;
  align-items: center;
  padding: 2px 8px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--color-border);
  background: none;
  color: var(--color-text-secondary);
  font-size: 0.7rem;
  text-decoration: none;
  cursor: pointer;
  transition: border-color 0.15s, color 0.15s;
}
.comms-chat-clip-play:hover,
.comms-chat-clip-dl:hover {
  border-color: var(--color-brand-blue);
  color: var(--color-brand-blue);
}

.comms-chat-timestamp {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: var(--color-bg-hover);
  border-radius: var(--radius-sm);
  padding: 2px 8px;
  margin-top: 2px;
  cursor: pointer;
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--color-brand-blue);
  transition: background 0.15s ease;
}
.comms-chat-timestamp:hover {
  background: rgba(84, 85, 255, 0.12);
}
.comms-chat-timestamp i {
  font-size: 0.7rem;
}

.comms-chat-input {
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 8px 12px;
  border-top: 1px solid var(--color-border);
  flex-shrink: 0;
}

.comms-chat-send-btn {
  border: none;
  background: none;
  color: var(--color-brand-blue);
  cursor: pointer;
  padding: 4px 8px;
  border-radius: var(--radius-sm);
  font-size: 0.85rem;
}
.comms-chat-send-btn:hover {
  background: rgba(84, 85, 255, 0.12);
}

.comms-chat-reactions {
  margin-top: 4px;
}

.comms-chat-reaction-btns {
  display: flex;
  gap: 2px;
}

.comms-react-btn {
  border: none;
  background: none;
  cursor: pointer;
  font-size: 0.75rem;
  padding: 1px 4px;
  border-radius: var(--radius-sm);
  opacity: 0.5;
  transition: opacity 0.15s, transform 0.15s;
}
.comms-react-btn:hover {
  opacity: 1;
  transform: scale(1.3);
}
.comms-react-btn.is-selected {
  opacity: 1;
  background: var(--color-bg-hover);
  transform: scale(1.1);
}

.comms-chat-reaction-counts {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  margin-top: 3px;
}

.comms-react-pill {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  padding: 1px 6px;
  border-radius: 10px;
  background: var(--color-bg-hover);
  border: 1px solid var(--color-border);
  font-size: 0.7rem;
  cursor: default;
  transition: transform 0.15s;
}
.comms-react-pill.comms-react-bump {
  transform: scale(1.2);
}

.comms-react-count {
  font-size: 0.65rem;
  color: var(--color-text-muted);
  font-weight: 600;
}

.comms-timeline-flash {
  position: absolute;
  top: 0;
  bottom: 0;
  width: 2px;
  border-left: 2px solid;
  z-index: 5;
  pointer-events: none;
  animation: comms-flash-pulse 3s ease-out forwards;
}

.comms-timeline-flash-label {
  position: absolute;
  top: 2px;
  left: 4px;
  font-size: 0.6rem;
  font-weight: 600;
  white-space: nowrap;
  animation: comms-flash-pulse 3s ease-out forwards;
}

.comms-vtl-flash {
  position: absolute;
  left: 0;
  right: 0;
  height: 2px;
  border-top: 2px solid;
  z-index: 5;
  pointer-events: none;
  animation: comms-flash-pulse 3s ease-out forwards;
}

.comms-vtl-flash-label {
  position: absolute;
  left: 4px;
  top: 4px;
  font-size: 0.6rem;
  font-weight: 600;
  white-space: nowrap;
  animation: comms-flash-pulse 3s ease-out forwards;
}

@keyframes comms-flash-pulse {
  0% {
    opacity: 1;
  }
  20% {
    opacity: 1;
  }
  100% {
    opacity: 0;
  }
}
.comms-cursor {
  position: absolute;
  top: 0;
  bottom: 0;
  width: 0;
  border-left: 2px solid;
  z-index: 6;
  pointer-events: none;
  opacity: 1;
  transition: left 0.2s linear;
}
.comms-cursor.is-paused {
  border-left-style: dashed;
  opacity: 0.6;
}

.comms-cursor-label {
  position: absolute;
  bottom: 2px;
  left: 2px;
  font-size: 0.65rem;
  font-weight: 600;
  color: #fff;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.8);
  padding: 1px 4px;
  border-radius: 3px;
  white-space: nowrap;
  line-height: 1.2;
}

.comms-vtl-cursor {
  position: absolute;
  left: 0;
  right: 0;
  height: 0;
  border-top: 2px solid;
  z-index: 6;
  pointer-events: none;
  opacity: 1;
  transition: top 0.2s linear;
}
.comms-vtl-cursor.is-paused {
  border-top-style: dashed;
  opacity: 0.6;
}

.comms-vtl-cursor-label {
  position: absolute;
  right: 4px;
  top: 2px;
  font-size: 0.65rem;
  font-weight: 600;
  color: #fff;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.8);
  padding: 1px 4px;
  border-radius: 3px;
  white-space: nowrap;
  line-height: 1.2;
}

.comms-chat-divider {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.65rem;
  color: var(--color-text-muted);
  padding: 6px 0;
}
.comms-chat-divider::before, .comms-chat-divider::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--color-border);
}

.marker-tl-ctx-share {
  color: var(--color-brand-blue) !important;
}

.analyse-mobile-markers {
  display: none;
}

body.analyse-mobile .analyse-layout-picker {
  display: none !important;
}
body.analyse-mobile #marker-timeline {
  display: none !important;
}
body.analyse-mobile .analyse-mobile-markers {
  display: block;
  max-height: 150px;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  background: var(--color-bg-elevated);
}
body.analyse-mobile .analyse-schema-widget {
  display: none !important;
}
body.analyse-mobile .analyse-layout {
  padding-bottom: env(safe-area-inset-bottom, 0);
}

.mml-row {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 44px;
  padding: 6px 12px;
  border-bottom: 1px solid var(--color-border);
  cursor: pointer;
  -webkit-user-select: none;
  user-select: none;
  -webkit-touch-callout: none;
}
.mml-row:last-child {
  border-bottom: none;
}
.mml-row.mml-active {
  background: rgba(119, 179, 0, 0.12);
}

.mml-chip {
  flex-shrink: 0;
  width: 12px;
  height: 12px;
  border-radius: 50%;
}

.mml-name {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 0.9rem;
}

.mml-category {
  margin-left: 8px;
  font-size: 0.75rem;
  color: var(--color-text-muted);
}

.mml-time {
  flex-shrink: 0;
  font-variant-numeric: tabular-nums;
  font-size: 0.85rem;
  color: var(--color-text-secondary);
}

.mml-empty {
  padding: 16px 12px;
  font-size: 0.85rem;
  color: var(--color-text-muted);
}

@media (pointer: coarse) {
  .analyse-schema-btn {
    min-height: 48px;
    min-width: 64px;
    font-size: 0.95rem;
    -webkit-user-select: none;
    user-select: none;
    -webkit-touch-callout: none;
    touch-action: manipulation;
  }
  #comms-chat-input {
    min-height: 44px;
    font-size: 1rem;
  }
  #comms-chat-send,
  #comms-chat-close {
    min-height: 44px;
    min-width: 44px;
  }
}
body.analyse-mobile .marker-tl-vertical-btn,
body.analyse-mobile .marker-tl-layout-select {
  display: none !important;
}
body.analyse-mobile .analyse-video-container {
  border-radius: var(--radius-md) var(--radius-md) 0 0;
}
body.analyse-mobile #analyse-overlay-controls {
  position: static;
  opacity: 1 !important;
  transform: none !important;
  pointer-events: auto !important;
  justify-content: center;
  flex-wrap: wrap;
  margin-top: 0;
  padding: 6px 8px;
  background: var(--color-bg-elevated);
  border: none;
  border-radius: 0;
}
body.analyse-mobile #analyse-overlay-controls .aoc-btn {
  min-width: 52px;
  height: 52px;
  font-size: 1.05rem;
}
body.analyse-mobile .analyse-video-controls {
  border-top: 1px solid var(--color-border);
}
body.analyse-mobile .analyse-layout-hdivider {
  display: none;
}
body.analyse-mobile .comms-chat-panel {
  position: static;
  width: 100%;
  transform: none;
  border: 1px solid var(--color-border);
  border-left: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  margin-bottom: var(--spacing-xs);
}
body.analyse-mobile .comms-chat-panel.is-open {
  display: flex;
}
body.analyse-mobile .comms-chat-panel .comms-chat-messages {
  max-height: 35vh;
}
body.analyse-mobile .analyse-page.comms-chat-open {
  padding-right: 0 !important;
}
body.analyse-mobile .comms-ptt-mode .comms-ptt-fs-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 44px;
  min-height: 44px;
}

.comms-ptt-fs-btn {
  display: none;
  border: none;
  background: none;
  color: var(--color-text-secondary);
  cursor: pointer;
  border-radius: var(--radius-sm);
}
.comms-ptt-fs-btn:hover {
  background: var(--color-bg-hover);
  color: var(--color-text-primary);
}

.comms-ptt-overlay {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 3000;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 16px;
  background: rgba(8, 12, 18, 0.94);
  -webkit-user-select: none;
  user-select: none;
  -webkit-touch-callout: none;
  touch-action: none;
}
.comms-ptt-overlay.is-open {
  display: flex;
}
.comms-ptt-overlay.comms-ptt-overlay-active .comms-ptt-overlay-hold {
  background: rgba(30, 52, 8, 0.96);
}
.comms-ptt-overlay.comms-ptt-overlay-active .comms-ptt-overlay-hint {
  color: var(--color-success);
}

.comms-ptt-overlay-hold {
  flex: 1;
  width: 100%;
  min-height: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  touch-action: none;
  -webkit-user-select: none;
  user-select: none;
  -webkit-touch-callout: none;
  border-top: 1px solid var(--color-border);
}

.comms-ptt-overlay-hint {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
  color: var(--color-text-secondary);
  font-size: 1.1rem;
  pointer-events: none;
}
.comms-ptt-overlay-hint i {
  font-size: 3.2rem;
}

.comms-ptt-overlay-exit {
  position: absolute;
  top: calc(14px + env(safe-area-inset-top, 0px));
  right: 14px;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  border: 1px solid var(--color-border);
  background: var(--color-bg-elevated);
  color: var(--color-text-primary);
  font-size: 1.1rem;
}

.comms-ptt-overlay-video {
  display: none;
  flex: 0 0 50%;
  width: 100%;
  min-height: 0;
  padding-top: env(safe-area-inset-top, 0px);
  background: #000;
}
.comms-ptt-overlay-video video {
  flex: 1;
  min-height: 0;
  width: 100%;
  object-fit: contain;
}
.comms-ptt-overlay-video #analyse-overlay-controls {
  margin: 4px 6px 6px;
}

.comms-ptt-overlay.comms-ptt-has-video {
  justify-content: flex-start;
}
.comms-ptt-overlay.comms-ptt-has-video .comms-ptt-overlay-video {
  display: flex;
  flex-direction: column;
}

body.analyse-mobile .analyse-comms-bar {
  height: auto;
  flex-wrap: wrap;
  padding: 6px var(--spacing-sm);
}
body.analyse-mobile .analyse-comms-bar .comms-participants {
  flex-basis: 100%;
  order: 99;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-top: 2px;
  padding: 6px 0 8px;
  border-top: 1px solid var(--color-border);
}
body.analyse-mobile .analyse-comms-bar .comms-participants:empty {
  display: none;
}
body.analyse-mobile .analyse-comms-bar .comms-participant.speaking {
  box-shadow: inset 0 0 0 2px var(--color-success);
}
body.analyse-mobile .analyse-comms-bar .comms-participant {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 42px;
  padding: 6px 12px;
  font-size: 0.95rem;
}
body.analyse-mobile .analyse-comms-bar .comms-participant .comms-participant-mic,
body.analyse-mobile .analyse-comms-bar .comms-participant .comms-cursor-toggle,
body.analyse-mobile .analyse-comms-bar .comms-participant .comms-follow-btn {
  font-size: 1.05rem;
  padding: 8px 6px;
}

body.analyse-mobile {
  padding-top: env(safe-area-inset-top, 0px) !important;
}
body.analyse-mobile > nav.navbar.fixed-top {
  display: none;
}

#timeline-dock-row {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  min-height: 0;
}
#timeline-dock-row:has(.vtl) {
  flex: 1 1 0;
  align-items: stretch;
}
#timeline-dock-row:has(.vtl) #marker-timeline {
  display: flex;
  flex-direction: column;
  min-height: 0;
}
#timeline-dock-row.asb-docked {
  flex: 1 1 0;
  min-height: 380px;
  align-items: stretch;
  gap: 0;
}
#timeline-dock-row #marker-timeline {
  flex: 1 1 50%;
  min-width: 0;
}
#timeline-dock-row #asb-dock {
  display: none;
  flex: 1 1 50%;
  min-width: 0;
  min-height: 0;
  order: 2;
}
#timeline-dock-row #asb-dock.dock-left {
  order: -2;
}
#timeline-dock-row .asb-dock-divider {
  position: relative;
  z-index: 12;
}
#timeline-dock-row .asb-dock-divider::before {
  content: "";
  position: absolute;
}
#timeline-dock-row .asb-dock-divider::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  border-radius: 2px;
  background: var(--color-text-muted);
  opacity: 0.55;
  pointer-events: none;
  transition: opacity 0.15s, background 0.15s;
}
#timeline-dock-row .asb-dock-divider:hover::after, #timeline-dock-row .asb-dock-divider.is-dragging::after {
  background: #fff;
  opacity: 1;
}
#timeline-dock-row .asb-dock-divider::before {
  top: 0;
  bottom: 0;
  left: -8px;
  right: -8px;
}
#timeline-dock-row .asb-dock-divider::after {
  width: 2px;
  height: 36px;
}
@media (pointer: coarse) {
  #timeline-dock-row .asb-dock-divider::before {
    left: -14px;
    right: -14px;
  }
  #timeline-dock-row .asb-dock-divider::after {
    width: 3px;
    height: 48px;
    opacity: 0.8;
  }
}
#timeline-dock-row .asb-dock-divider {
  display: none;
  width: 6px;
  align-self: stretch;
  cursor: col-resize;
  background: var(--color-border);
  border-radius: 3px;
  transition: background 0.15s;
  flex-shrink: 0;
  touch-action: none;
  order: 1;
}
#timeline-dock-row .asb-dock-divider:hover, #timeline-dock-row .asb-dock-divider.is-dragging {
  background: var(--color-brand-blue);
}
#timeline-dock-row #asb-dock.dock-left + .asb-dock-divider {
  order: -1;
}
#timeline-dock-row.asb-docked #asb-dock {
  display: flex;
}
#timeline-dock-row.asb-docked .asb-dock-divider {
  display: block;
}
#timeline-dock-row.asb-docked #marker-timeline {
  padding-bottom: 0;
}
#timeline-dock-row.asb-docked .asb-dock-divider {
  border-radius: 0;
}
#timeline-dock-row.asb-docked:not(:has(#asb-dock.dock-left)) .marker-tl {
  border-top-right-radius: 0;
  border-bottom-right-radius: 0;
}
#timeline-dock-row.asb-docked:not(:has(#asb-dock.dock-left)) #asb-panel {
  border-top-left-radius: 0;
  border-bottom-left-radius: 0;
}
#timeline-dock-row.asb-docked:has(#asb-dock.dock-left) .marker-tl {
  border-top-left-radius: 0;
  border-bottom-left-radius: 0;
}
#timeline-dock-row.asb-docked:has(#asb-dock.dock-left) #asb-panel {
  border-top-right-radius: 0;
  border-bottom-right-radius: 0;
}

@media (max-width: 767px) {
  #timeline-dock-row {
    flex-wrap: wrap;
  }
  #timeline-dock-row #asb-dock {
    flex-basis: 100%;
  }
}
#asb-toggle {
  display: none;
  background: none;
  border: 1px solid var(--color-border);
  color: var(--color-text-secondary);
  border-radius: var(--radius-sm);
  height: 28px;
  padding: 0 8px;
  align-items: center;
  gap: 4px;
  cursor: pointer;
  font-size: 0.7rem;
  font-weight: 600;
}
#asb-toggle:hover {
  border-color: var(--color-brand-blue);
  color: var(--color-brand-blue);
}
#asb-toggle.open {
  background: var(--color-brand-blue);
  border-color: var(--color-brand-blue);
  color: #fff;
}

.marker-tl-controls #asb-toggle {
  display: flex;
}

.marker-stars,
.marker-tl-tooltip-stars,
.analyse-clip-overlay-stars,
.mml-stars {
  display: inline-flex;
  align-items: center;
  gap: 1px;
  color: #f5c542;
  font-size: 0.6rem;
  line-height: 1;
  vertical-align: middle;
}

.marker-tl-tooltip-stars {
  display: flex;
  margin-top: 2px;
}

.analyse-clip-overlay-stars {
  font-size: 0.65rem;
}

.mml-stars {
  margin-left: 8px;
  font-size: 0.7rem;
}

.marker-tl-clip-stars {
  margin-left: 4px;
  color: #f5c542;
  font-size: 0.55rem;
}
.marker-tl-clip-stars i {
  margin-right: 1px;
}

.marker-qual-attrs,
.marker-tl-tooltip-qual-attrs,
.analyse-clip-overlay-qual-attrs {
  margin-left: 4px;
  color: var(--color-text-muted);
  font-weight: 400;
  opacity: 0.9;
}

.marker-tl-stars-sel {
  display: inline-flex;
  align-items: center;
  height: 28px;
  padding: 0 4px;
  margin-right: var(--spacing-sm);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
}

.marker-tl-star {
  background: none;
  border: 0;
  padding: 0 2px;
  height: 100%;
  color: var(--color-text-muted);
  cursor: pointer;
  font-size: 0.85rem;
  line-height: 1;
}
.marker-tl-star:hover {
  color: #f5c542;
}
.marker-tl-star.is-on {
  color: #f5c542;
}

.marker-tl-stars-dropdown {
  display: inline-flex;
  margin-right: var(--spacing-sm);
}

.marker-tl-stars-filter-btn {
  background: none;
  border: 1px solid var(--color-border);
  color: var(--color-text-secondary);
  border-radius: var(--radius-sm);
  height: 28px;
  min-width: 28px;
  padding: 0 6px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 3px;
  cursor: pointer;
  font-size: 0.85rem;
}
.marker-tl-stars-filter-btn:hover {
  border-color: var(--color-brand-blue);
  color: var(--color-brand-blue);
}
.marker-tl-stars-filter-btn.is-active {
  border-color: #f5c542;
  color: #f5c542;
}

.marker-tl-stars-filter-num {
  font-size: 0.65rem;
  font-weight: 600;
}

.marker-tl-stars-option-stars {
  color: #f5c542;
  font-size: 0.7rem;
  letter-spacing: 1px;
  margin-right: 4px;
}

#pm-toggle {
  display: none;
  background: none;
  border: 1px solid var(--color-border);
  color: var(--color-text-secondary);
  border-radius: var(--radius-sm);
  height: 28px;
  padding: 0 8px;
  align-items: center;
  gap: 4px;
  cursor: pointer;
  font-size: 0.7rem;
  font-weight: 600;
}
#pm-toggle:hover {
  border-color: var(--color-brand-blue);
  color: var(--color-brand-blue);
}
#pm-toggle.open {
  background: var(--color-brand-blue);
  border-color: var(--color-brand-blue);
  color: #fff;
}

.marker-tl-controls #pm-toggle {
  display: flex;
}

#pm-panel {
  display: none;
  width: 100%;
  height: 100%;
  min-height: 0;
  flex-direction: column;
  gap: 8px;
  background: var(--color-bg-secondary);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  padding: 10px;
  overflow: hidden;
}
#pm-panel.open {
  display: flex;
}

.pm-head {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}

.pm-title {
  font-weight: 600;
  font-size: 0.85rem;
  letter-spacing: 0.04em;
  margin-right: auto;
}

.pm-select {
  height: 28px;
  max-width: 160px;
  padding: 0 6px;
  font-size: 0.75rem;
  background: var(--color-bg-primary);
  color: var(--color-text-primary);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
}

.pm-btn {
  background: none;
  border: 1px solid var(--color-border);
  color: var(--color-text-secondary);
  border-radius: var(--radius-sm);
  width: 28px;
  height: 28px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 0.8rem;
}
.pm-btn:hover:not(:disabled) {
  border-color: var(--color-brand-blue);
  color: var(--color-brand-blue);
}
.pm-btn.is-active {
  background: var(--color-brand-blue);
  border-color: var(--color-brand-blue);
  color: #fff;
}
.pm-btn:disabled {
  opacity: 0.4;
  cursor: default;
}

.pm-body {
  flex: 1 1 auto;
  min-height: 0;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}

.pm-svg-host {
  width: 100%;
  height: 100%;
  min-height: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}
.pm-svg-host svg {
  width: 100%;
  height: 100%;
  max-height: 100%;
}

.pm-empty {
  position: absolute;
  inset: auto 12px 12px 12px;
  text-align: center;
  font-size: 0.75rem;
  color: var(--color-text-muted);
}

.pm-foot {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  font-size: 0.7rem;
  color: var(--color-text-muted);
  min-height: 16px;
}

.pm-legend {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.pm-legend-item {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}
.pm-legend-item i {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  display: inline-block;
}

.pm-svg {
  display: block;
}
.pm-svg .pm-turf {
  fill: rgba(255, 255, 255, 0.04);
  stroke: var(--color-text-muted);
  stroke-width: 2;
}
.pm-svg .pm-lines {
  fill: none;
  stroke: var(--color-text-muted);
  stroke-width: 2;
  opacity: 0.8;
}
.pm-svg .pm-lines .pm-dashed {
  stroke-dasharray: 12 10;
  opacity: 0.6;
}
.pm-svg .pm-lines .pm-post {
  stroke-width: 6;
}
.pm-svg .pm-lines .pm-mark {
  fill: var(--color-text-muted);
  stroke: none;
}
.pm-svg .pm-dot {
  stroke: rgba(0, 0, 0, 0.55);
  stroke-width: 1.5;
  opacity: 0.9;
  cursor: pointer;
  transition: opacity 0.15s;
}
.pm-svg .pm-dot:hover {
  opacity: 1;
  stroke: #fff;
}
.pm-svg .pm-dot.is-selected {
  stroke: #fff;
  stroke-width: 4;
  opacity: 1;
}

#pm-panel.pm-follow .pm-dot:not(.is-near):not(.is-selected) {
  opacity: 0.2;
}

#pm-panel.pm-follow .pm-dot.is-near {
  stroke: #fff;
  stroke-width: 3;
  opacity: 1;
}

.pm-tip {
  position: fixed;
  z-index: 2100;
  pointer-events: none;
  background: var(--color-bg-secondary);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  padding: 6px 8px;
  font-size: 0.7rem;
  color: var(--color-text-primary);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.4);
  max-width: 240px;
}

.pm-tip-muted {
  color: var(--color-text-muted);
}

.vtl {
  flex: 1;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.vtl-body {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  overflow-x: hidden;
  scrollbar-width: thin;
  scrollbar-color: rgba(255, 255, 255, 0.2) var(--color-bg-secondary);
}
.vtl-body::-webkit-scrollbar {
  width: 6px;
}
.vtl-body::-webkit-scrollbar-track {
  background: var(--color-bg-secondary);
}
.vtl-body::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.2);
  border-radius: 3px;
}
.vtl-body::-webkit-scrollbar-thumb:hover {
  background: rgba(255, 255, 255, 0.35);
}

.vtl-body-content {
  position: relative;
  padding: 20px 0;
}

.vtl-y-axis {
  position: absolute;
  left: calc(50% - 24px / 2);
  top: 0;
  bottom: 0;
  width: 24px;
  background: var(--color-bg-elevated);
  border-left: 1px solid var(--color-border);
  border-right: 1px solid var(--color-border);
  z-index: 3;
  cursor: grab;
  touch-action: none;
}
.vtl-y-axis:active {
  cursor: grabbing;
}

.vtl-playhead {
  position: absolute;
  left: 50%;
  z-index: 5;
  pointer-events: none;
}

.vtl-playhead-handle {
  position: absolute;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: var(--color-brand);
  border: 1px solid white;
  cursor: grab;
  pointer-events: auto;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.4);
  left: -10px;
  top: -10px;
  touch-action: none;
  transition: transform 0.12s;
}
.vtl-playhead-handle:active {
  cursor: grabbing;
}
.vtl-playhead-handle.is-dragging {
  transform: scale(1.35);
}
@media (pointer: coarse) {
  .vtl-playhead-handle::before {
    content: "";
    position: absolute;
    inset: -12px;
    border-radius: 50%;
  }
}

.vtl-playhead-preview {
  position: absolute;
  width: 160px;
  height: 90px;
  left: -80px;
  bottom: 14px;
  border-radius: var(--radius-sm);
  border: 2px solid var(--color-brand);
  background: #000;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.6);
  pointer-events: none;
  display: none;
}
.vtl-playhead-preview.is-visible {
  display: block;
}

.vtl-playhead-line {
  position: absolute;
  height: 2px;
  z-index: 4;
  pointer-events: none;
}
.vtl-playhead-line.is-left {
  left: 0;
  width: 50%;
  background: linear-gradient(to right, rgba(255, 255, 255, 0.25), rgba(255, 255, 255, 0.08));
}
.vtl-playhead-line.is-right {
  right: 0;
  width: calc(100% - 50%);
  background: linear-gradient(to left, rgba(255, 255, 255, 0.25), rgba(255, 255, 255, 0.08));
}

.vtl-playhead-time {
  position: absolute;
  left: 14px;
  top: -7px;
  font-size: 0.6rem;
  font-weight: 600;
  color: var(--color-brand);
  white-space: nowrap;
  pointer-events: none;
  display: none;
}
.vtl-playhead-time.is-visible {
  display: block;
}

.vtl-tick {
  position: absolute;
  left: 0;
  width: 100%;
  height: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.55rem;
  color: var(--color-text-muted);
  white-space: nowrap;
  user-select: none;
  pointer-events: none;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}
.vtl-tick span {
  transform: rotate(-270deg);
}

.vtl-entry {
  position: absolute;
  display: flex;
  align-items: center;
  transform: translateY(-50%);
  z-index: 2;
  width: 50%;
  pointer-events: none;
}
.vtl-entry.is-left {
  left: 0;
  flex-direction: row-reverse;
  padding-right: calc(24px / 2 + 15px + 4px);
}
.vtl-entry.is-left .vtl-card {
  margin-right: 0;
  margin-left: auto;
}
.vtl-entry.is-right {
  right: 0;
  flex-direction: row;
  padding-left: calc(24px / 2 + 15px + 4px);
}
.vtl-entry.is-right .vtl-card {
  margin-left: 0;
  margin-right: auto;
}
.vtl-entry.is-current {
  z-index: 4;
}
.vtl-entry.is-current .vtl-card {
  border-color: var(--color-brand-blue);
}
.vtl-entry.is-selected {
  z-index: 6;
}
.vtl-entry.is-selected .vtl-card.is-marker {
  box-shadow: inset 0 0 0 2px white;
}
.vtl-entry.is-selected .vtl-card.is-cut {
  border-color: var(--color-brand-blue);
}
.vtl-entry.vtl-associated {
  z-index: 5;
}
.vtl-entry.vtl-associated .vtl-card.is-cut {
  border-color: white;
}

.vtl-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  flex-shrink: 0;
  z-index: 3;
  border: 2px solid var(--color-bg-secondary);
}

.vtl-connector {
  width: 30px;
  height: 2px;
  background: var(--color-border);
  flex-shrink: 0;
}

.vtl-card {
  max-width: 100%;
  min-width: 0;
  background: var(--color-bg-elevated);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  cursor: pointer;
  overflow: hidden;
  position: relative;
  transition: border-color 0.15s;
  flex-shrink: 1;
  pointer-events: auto;
}
.vtl-card:hover {
  border-color: var(--color-brand-blue);
}
.vtl-card:hover .vtl-delete,
.vtl-card:hover .vtl-download,
.vtl-card:hover .vtl-share-btn {
  opacity: 1;
}
.vtl-card:hover .vtl-play {
  opacity: 1;
}

.vtl-card.is-marker {
  width: 220px;
}
.vtl-card.is-marker .vtl-label {
  padding: 7px 9px;
}
.vtl-card.is-marker:hover {
  border-color: var(--color-brand-blue);
}

.vtl-card.is-cut {
  width: 180px;
}

.vtl-thumb-wrap {
  position: relative;
  width: 100%;
  aspect-ratio: 16/9;
  background: #000;
  overflow: hidden;
}

.vtl-thumb {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.vtl-play {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, 0.25);
  opacity: 0;
  transition: opacity 0.15s;
  cursor: pointer;
}
.vtl-play i {
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding-left: 3px;
  font-size: 1.05rem;
  color: #fff;
  background: var(--color-brand-blue);
  border-radius: 50%;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.45);
}

.vtl-delete,
.vtl-download,
.vtl-share-btn {
  position: absolute;
  top: 4px;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.7);
  border: none;
  color: var(--color-text-secondary);
  font-size: 0.6rem;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  opacity: 0;
  transition: opacity 0.15s, color 0.15s;
  z-index: 2;
  text-decoration: none;
}

.vtl-delete {
  right: 4px;
}
.vtl-delete:hover {
  color: var(--bs-danger);
}

.vtl-download {
  right: 28px;
}
.vtl-download:hover {
  color: var(--color-brand-blue);
}

.vtl-share-btn {
  right: 52px;
}
.vtl-share-btn:hover {
  color: var(--color-success);
}

.vtl-label {
  padding: 5px 7px;
  font-size: 0.65rem;
  line-height: 1.3;
  color: var(--color-text-secondary);
  overflow: hidden;
}

.vtl-label-category {
  font-size: 0.55rem;
  color: var(--color-text-muted);
  text-transform: uppercase;
}

.vtl-label-name {
  font-weight: 600;
  color: var(--color-text-primary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.vtl-label-time {
  color: var(--color-text-muted);
  margin-left: 3px;
  white-space: nowrap;
}

.vtl-note {
  color: var(--color-text-primary);
  font-size: 0.6rem;
  margin-top: 2px;
  word-wrap: break-word;
  overflow-wrap: break-word;
}

.vtl-quals {
  display: flex;
  flex-wrap: wrap;
  gap: 3px;
  margin-top: 3px;
}

.vtl-qual {
  font-size: 0.55rem;
  font-weight: 500;
}

.vtl-processing {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
  color: var(--color-text-muted);
  font-size: 1rem;
}
.vtl-processing .spinner-border {
  width: 1rem;
  height: 1rem;
  border-width: 2px;
}

.vtl-group-badge {
  position: absolute;
  bottom: 4px;
  left: 4px;
  background: rgba(0, 0, 0, 0.8);
  color: var(--color-brand-blue);
  font-size: 0.55rem;
  font-weight: 600;
  padding: 2px 5px;
  border-radius: var(--radius-sm);
  z-index: 2;
  display: flex;
  align-items: center;
}
.vtl-group-badge i {
  font-size: 0.5rem;
}

.vtl-clip-bar {
  position: absolute;
  width: 4px;
  border-radius: 2px;
  opacity: 0.55;
  pointer-events: none;
  z-index: 4;
}

.vtl-empty {
  padding: var(--spacing-sm);
  text-align: center;
  color: var(--color-text-muted);
  font-size: 0.8rem;
}

.vtl-stars {
  display: inline-flex;
  align-items: center;
  gap: 1px;
  margin-left: 4px;
  color: #f5c542;
  font-size: 0.5rem;
  line-height: 1;
  vertical-align: middle;
}

.vtl-qual-attrs {
  margin-left: 3px;
  color: var(--color-text-muted);
  font-weight: 400;
}

.analyse-touch-player {
  display: none;
  position: absolute;
  inset: 0;
  z-index: 3;
  flex-direction: column;
  color: #fafafa;
  -webkit-user-select: none;
  user-select: none;
  -webkit-touch-callout: none;
}
.analyse-touch-player.is-active, .analyse-touch-player.is-prompt {
  display: flex;
}
.analyse-touch-player.is-sheet {
  z-index: 8;
}
.analyse-touch-player.is-cutting {
  z-index: 8;
}

.tp-stage {
  position: relative;
  flex: 1 1 auto;
  min-height: 0;
  touch-action: none;
  overscroll-behavior: none; /* trackpad swipes are ours, not back/forward */
  overflow: hidden;
}

body.analyse-touch .analyse-video-container video::-webkit-media-controls,
body.analyse-touch .play-modal-video-wrap video::-webkit-media-controls {
  display: none !important;
}

.play-modal-video-wrap {
  overflow: hidden;
}

.tp-hud {
  position: absolute;
  inset: 0;
  display: grid;
  grid-template: 1fr 1fr 1fr/1fr 1fr 1fr;
  background: rgba(0, 0, 0, 0.4);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.15s ease;
  z-index: 3;
}
.tp-hud.is-visible {
  opacity: 1;
}
.tp-hud.is-split {
  display: block;
  background: transparent;
}
.tp-hud .tp-hud-cell {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  font-size: 13px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.85);
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.6);
}
.tp-hud .tp-hud-cell i {
  font-size: 34px;
}
.tp-hud .tp-hud-cell .tp-hud-sub {
  font-size: 11px;
  text-transform: none;
  letter-spacing: 0;
  color: rgba(255, 255, 255, 0.6);
}
.tp-hud .tp-hud-c i {
  color: var(--color-brand-blue, #39B3EA);
}
.tp-hud .tp-hud-pane {
  position: absolute;
  box-sizing: border-box;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, 0.35);
}
.tp-hud .tp-hud-pane.is-dominant {
  background: rgba(0, 0, 0, 0.5);
}
.tp-hud .tp-hud-grid {
  position: absolute;
  inset: 0;
  display: grid;
}
.tp-hud .tp-hud-pane-hint {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  color: rgba(255, 255, 255, 0.9);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  font-size: 13px;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.6);
}
.tp-hud .tp-hud-pane-hint i {
  font-size: 30px;
  color: var(--color-brand-blue, #39B3EA);
}

.tp-badge {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 22px;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.55);
  color: #fff;
  font-size: 26px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  opacity: 0;
  pointer-events: none;
  z-index: 4;
  transition: opacity 0.9s ease;
}
.tp-badge i {
  font-size: 30px;
}
.tp-badge.is-on {
  opacity: 1;
  transition: opacity 0.05s ease;
}
.tp-badge.tp-badge-plain {
  font-size: 18px;
  font-weight: 600;
}

.tp-toast {
  position: absolute;
  left: 50%;
  bottom: 18px;
  transform: translateX(-50%);
  padding: 10px 16px;
  border-radius: 8px;
  background: rgba(10, 25, 41, 0.92);
  border: 1px solid rgba(255, 255, 255, 0.15);
  color: #fafafa;
  font-size: 15px;
  opacity: 0;
  pointer-events: none;
  z-index: 5;
  transition: opacity 0.2s ease;
  max-width: 80%;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.tp-toast.is-on {
  opacity: 1;
}
.tp-toast .tp-toast-dot {
  display: inline-block;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  margin-right: 8px;
  vertical-align: -1px;
}

.tp-btn {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  min-width: 44px;
  height: 44px;
  padding: 0 10px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: #fafafa;
  font-size: 16px;
  cursor: pointer;
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
}
.tp-btn:active {
  background: rgba(255, 255, 255, 0.14);
}
.tp-btn:focus-visible {
  outline: 2px solid var(--color-brand-blue, #39B3EA);
  outline-offset: -2px;
}
.tp-btn i {
  font-size: 18px;
}

.analyse-video-container.is-touch-split .analyse-multi-grid {
  gap: 2px;
  background: #000;
}
.analyse-video-container.is-touch-split .analyse-multi-slot {
  outline: 2px solid transparent;
  outline-offset: -2px;
}
.analyse-video-container.is-touch-split .analyse-multi-slot.is-dominant {
  outline-color: var(--color-brand-blue, #39B3EA);
}

.tp-kiosk {
  position: absolute;
  inset: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #000;
  cursor: pointer;
}
.tp-kiosk .tp-kiosk-card {
  text-align: center;
  padding: 32px;
}
.tp-kiosk i {
  font-size: 72px;
  color: var(--color-brand-blue, #39B3EA);
}
.tp-kiosk .tp-kiosk-title {
  margin-top: 18px;
  font-size: 30px;
  font-weight: 700;
}
.tp-kiosk .tp-kiosk-sub {
  margin-top: 6px;
  font-size: 16px;
  color: rgba(255, 255, 255, 0.6);
}
.tp-kiosk .tp-kiosk-skip {
  margin-top: 28px;
  color: rgba(255, 255, 255, 0.55);
  font-size: 15px;
}

.tp-cut-bar {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 7;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 14px;
  padding: 10px 14px calc(10px + env(safe-area-inset-bottom, 0));
  background: rgba(10, 25, 41, 0.96);
  border-top: 1px solid rgba(255, 255, 255, 0.15);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
}
.tp-cut-bar[hidden] {
  display: none;
}

.tp-cut-field {
  display: flex;
  align-items: center;
  gap: 6px;
}

.tp-cut-tag {
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: #a1a1aa;
  min-width: 26px;
}

.tp-cut-time {
  min-width: 52px;
  text-align: center;
  font-variant-numeric: tabular-nums;
  font-weight: 600;
  color: #fafafa;
}

.tp-cut-nudge {
  width: 40px;
  height: 40px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.06);
  color: #fafafa;
  font-size: 20px;
  line-height: 1;
  cursor: pointer;
}
.tp-cut-nudge:active {
  background: rgba(255, 255, 255, 0.18);
}

.tp-cut-set {
  height: 40px;
  padding: 0 12px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.06);
  color: #fafafa;
  font-size: 14px;
  cursor: pointer;
}
.tp-cut-set:active {
  background: rgba(255, 255, 255, 0.18);
}

.tp-cut-buttons {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-left: auto;
}

.tp-cut-cancel {
  background: rgba(255, 255, 255, 0.08);
}

.tp-cut-go {
  background: var(--color-brand-blue, #39B3EA);
  color: #041016;
  font-weight: 700;
}

.tp-cut-go-all {
  background: rgba(57, 179, 234, 0.18);
  color: var(--color-brand-blue, #39B3EA);
  font-weight: 600;
}

.tp-sheet {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  max-height: 70%;
  display: flex;
  flex-direction: column;
  background: #0A1929;
  border-top: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 16px 16px 0 0;
  box-shadow: 0 -8px 30px rgba(0, 0, 0, 0.6);
  z-index: 6;
  padding-bottom: env(safe-area-inset-bottom, 0);
}
.tp-sheet[hidden] {
  display: none;
}

.tp-sheet-head {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 10px 8px 18px;
  font-size: 17px;
  font-weight: 600;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.tp-sheet-empty {
  padding: 24px 18px;
  color: #a1a1aa;
}
.tp-sheet-empty[hidden] {
  display: none;
}

.tp-mark-grid {
  flex: 1 1 auto;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 10px;
  padding: 14px 18px 18px;
}

.tp-mark-btn {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 64px;
  padding: 10px 14px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.06);
  color: #fafafa;
  font-size: 16px;
  font-weight: 600;
  text-align: left;
  cursor: pointer;
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
}
.tp-mark-btn .tp-mark-swatch {
  flex: 0 0 auto;
  width: 14px;
  align-self: stretch;
  min-height: 34px;
  border-radius: 4px;
}
.tp-mark-btn .tp-mark-name {
  flex: 1 1 auto;
  min-width: 0;
  white-space: normal;
  overflow-wrap: anywhere;
  line-height: 1.2;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.tp-mark-btn .tp-mark-cutico {
  flex: 0 0 auto;
  color: #9fd8f2;
  opacity: 0.85;
}
.tp-mark-btn.is-recording {
  border-color: #ef4444;
  background: rgba(239, 68, 68, 0.16);
}
.tp-mark-btn:active {
  background: rgba(255, 255, 255, 0.16);
}

.tp-rec {
  position: absolute;
  top: calc(10px + env(safe-area-inset-top, 0px));
  left: 50%;
  transform: translateX(-50%);
  z-index: 7;
  display: flex;
  align-items: center;
  gap: 10px;
  max-width: 90%;
  padding: 8px 12px;
  border-radius: 999px;
  background: rgba(239, 68, 68, 0.92);
  color: #fff;
  font-size: 14px;
  font-weight: 600;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.4);
}
.tp-rec[hidden] {
  display: none;
}
.tp-rec .tp-rec-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #fff;
  animation: tp-rec-blink 1s steps(2, start) infinite;
}
.tp-rec .tp-rec-names {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.tp-rec .tp-rec-stop {
  flex: 0 0 auto;
  border: 0;
  border-radius: 999px;
  background: #fff;
  color: #b91c1c;
  font-weight: 700;
  padding: 4px 12px;
  cursor: pointer;
}

@keyframes tp-rec-blink {
  50% {
    opacity: 0.2;
  }
}
.tp-follow {
  position: absolute;
  top: calc(10px + env(safe-area-inset-top, 0px));
  left: 12px;
  z-index: 7;
  display: flex;
  align-items: stretch;
  max-width: min(70%, 440px);
  border-radius: 999px;
  background: var(--tp-follow-color, rgba(10, 25, 41, 0.85));
  color: #fff;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.4);
  font-size: 14px;
  transition: opacity 0.4s ease, background 0.2s ease;
  -webkit-user-select: none;
  user-select: none;
}
.tp-follow[hidden] {
  display: none;
}
.tp-follow.is-dim {
  opacity: 0.55;
}
.tp-follow button {
  border: 0;
  background: none;
  color: inherit;
  font: inherit;
  cursor: pointer;
  touch-action: manipulation;
}
.tp-follow .tp-follow-main {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 44px;
  padding: 6px 14px;
  min-width: 0;
}
.tp-follow .tp-follow-text {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.35);
}
.tp-follow .tp-follow-stop {
  min-width: 44px;
  padding: 0 14px 0 6px;
  border-left: 1px solid rgba(255, 255, 255, 0.3);
}
.tp-follow .tp-follow-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #fff;
  flex: 0 0 auto;
  animation: tp-follow-pulse 2s ease-in-out infinite;
}
.tp-follow .tp-follow-icon, .tp-follow .tp-follow-ring {
  display: none;
}
.tp-follow .tp-follow-ring {
  width: 20px;
  height: 20px;
  flex: 0 0 auto;
}
.tp-follow .tp-follow-ring svg {
  width: 100%;
  height: 100%;
  transform: rotate(-90deg);
}
.tp-follow .tp-follow-ring circle {
  fill: none;
  stroke-width: 3;
}
.tp-follow .tp-follow-ring .tp-follow-ring-track {
  stroke: rgba(0, 0, 0, 0.18);
}
.tp-follow .tp-follow-ring .tp-follow-ring-bar {
  stroke: #fff;
  stroke-dasharray: 50.27;
  stroke-dashoffset: 0;
}
.tp-follow[data-state=suspended] {
  background: #d97706;
}
.tp-follow[data-state=suspended] .tp-follow-dot {
  display: none;
}
.tp-follow[data-state=suspended] .tp-follow-ring {
  display: block;
}
.tp-follow[data-state=idle] {
  background: rgba(10, 25, 41, 0.72);
  border: 1px solid rgba(255, 255, 255, 0.18);
}
.tp-follow[data-state=idle] .tp-follow-dot, .tp-follow[data-state=idle] .tp-follow-stop {
  display: none;
}
.tp-follow[data-state=idle] .tp-follow-icon {
  display: inline-block;
  opacity: 0.85;
}

@keyframes tp-follow-countdown {
  to {
    stroke-dashoffset: 50.27;
  }
}
@keyframes tp-follow-pulse {
  50% {
    opacity: 0.45;
  }
}
.tp-follow-picker {
  position: absolute;
  top: calc(62px + env(safe-area-inset-top, 0px));
  left: 12px;
  z-index: 8;
  min-width: 240px;
  max-width: min(80%, 360px);
  max-height: 60%;
  overflow-y: auto;
  padding: 6px;
  border-radius: 14px;
  background: rgba(10, 25, 41, 0.96);
  border: 1px solid rgba(255, 255, 255, 0.14);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
  color: #fafafa;
}
.tp-follow-picker[hidden] {
  display: none;
}
.tp-follow-picker .tp-follow-picker-head {
  padding: 6px 10px 8px;
  font-size: 12px;
  opacity: 0.7;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.tp-follow-picker .tp-follow-picker-empty {
  padding: 10px;
  opacity: 0.7;
}
.tp-follow-picker .tp-follow-pick {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  min-height: 48px;
  padding: 8px 12px;
  border: 0;
  border-radius: 10px;
  background: none;
  color: inherit;
  font-size: 16px;
  text-align: left;
  cursor: pointer;
  touch-action: manipulation;
}
.tp-follow-picker .tp-follow-pick:active, .tp-follow-picker .tp-follow-pick:hover {
  background: rgba(255, 255, 255, 0.1);
}
.tp-follow-picker .tp-follow-pick-dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  flex: 0 0 auto;
}

.tp-marker-info {
  position: absolute;
  left: 50%;
  bottom: 12px;
  transform: translateX(-50%) translateY(6px);
  z-index: 7;
  display: none;
  align-items: flex-start;
  gap: 10px;
  max-width: min(90%, 420px);
  padding: 10px 14px;
  border-radius: 12px;
  background: rgba(10, 25, 41, 0.94);
  border: 1px solid rgba(255, 255, 255, 0.14);
  color: #fafafa;
  box-shadow: 0 6px 22px rgba(0, 0, 0, 0.5);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  opacity: 0;
  transition: opacity 0.15s ease, transform 0.15s ease;
  pointer-events: none;
}
.tp-marker-info.is-on {
  display: flex;
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}
.tp-marker-info .tp-mi-dot {
  flex: 0 0 auto;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  margin-top: 4px;
}
.tp-marker-info .tp-mi-body {
  display: flex;
  flex-direction: column;
  min-width: 0;
}
.tp-marker-info .tp-mi-name {
  font-size: 16px;
  font-weight: 700;
  line-height: 1.2;
}
.tp-marker-info .tp-mi-meta {
  font-size: 13px;
  color: #a1a1aa;
  font-variant-numeric: tabular-nums;
}
.tp-marker-info .tp-mi-note {
  font-size: 13px;
  color: #d4d4d8;
  margin-top: 3px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.tp-prompt-body {
  flex: 1 1 auto;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  padding: 12px 18px;
}

.tp-qual-list {
  margin-bottom: 14px;
}

.tp-qual-list-name {
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: #a1a1aa;
  margin-bottom: 8px;
}

.tp-qual-btns {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.tp-qual-btn {
  min-height: 48px;
  padding: 8px 16px;
  border: 2px solid transparent;
  border-radius: 10px;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  touch-action: manipulation;
  opacity: 0.72;
}
.tp-qual-btn.is-on {
  opacity: 1;
  border-color: #fff;
  box-shadow: 0 0 0 2px rgba(0, 0, 0, 0.35);
}
.tp-qual-btn:active {
  opacity: 1;
}

.tp-note-wrap {
  margin-top: 6px;
}

.tp-note-input {
  width: 100%;
  box-sizing: border-box;
  padding: 12px;
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  background: rgba(255, 255, 255, 0.08);
  color: #fafafa;
  font-size: 16px;
  resize: vertical;
}

.tp-prompt-actions {
  flex: 0 0 auto;
  display: flex;
  gap: 10px;
  padding: 12px 18px calc(12px + env(safe-area-inset-bottom, 0));
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.tp-prompt-cancel {
  background: rgba(255, 255, 255, 0.08);
}

.tp-prompt-done {
  margin-left: auto;
  background: var(--color-brand-blue, #39B3EA);
  color: #041016;
  font-weight: 700;
}

.tp-settings-body {
  flex: 1 1 auto;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  padding: 8px 18px 18px;
}

.tp-set-row {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: 12px;
  min-height: 56px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}
.tp-set-row:last-child {
  border-bottom: 0;
}
.tp-set-row .tp-set-label {
  font-size: 15px;
}
.tp-set-row .tp-set-hint {
  display: block;
  font-size: 12px;
  color: #a1a1aa;
}

.tp-stepper {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}
.tp-stepper .tp-stepper-val {
  min-width: 64px;
  text-align: center;
  font-variant-numeric: tabular-nums;
  font-weight: 600;
  font-size: 16px;
}
.tp-stepper .tp-btn {
  background: rgba(255, 255, 255, 0.08);
}

.tp-set-row .toggle-pills {
  display: inline-flex;
  gap: 4px;
}

.tp-set-row .toggle-pill {
  cursor: pointer;
}
.tp-set-row .toggle-pill input {
  position: absolute;
  opacity: 0;
  width: 0;
  height: 0;
}
.tp-set-row .toggle-pill .pill-label {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
  min-width: 64px;
  height: 40px;
  padding: 0 18px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  color: #d4d4d8;
  font-size: 14px;
  text-align: center;
  white-space: nowrap;
}
.tp-set-row .toggle-pill input:checked + .pill-label {
  background: var(--color-brand, #6500AA);
  border-color: var(--color-brand-light, #8B2FC9);
  color: #fff;
}

.analyse-overlay-controls .aoc-touch {
  display: none;
}

@media (hover: none), (pointer: coarse) {
  .analyse-overlay-controls .aoc-touch {
    display: inline-flex;
  }
}
.analyse-overlay-controls:hover .aoc-touch,
.analyse-overlay-controls.is-visible .aoc-touch {
  display: inline-flex;
}

.analyse-overlay-controls .aoc-touch.is-active {
  background: rgba(57, 179, 234, 0.22);
  color: var(--color-brand-blue, #39B3EA);
}

.analyse-overlay-controls .aoc-touch-extra {
  display: none;
}

body.analyse-touch .analyse-overlay-controls .aoc-touch-extra {
  display: inline-flex;
}

body.analyse-touch .analyse-overlay-controls .aoc-touch-extra.is-active {
  background: rgba(57, 179, 234, 0.22);
  color: var(--color-brand-blue, #39B3EA);
}

.tp-layout-editor {
  padding-bottom: 6px;
}

.tp-set-section {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--color-brand-blue, #39B3EA);
  font-weight: 700;
  margin: 14px 0 8px;
}

.tp-le-row {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 8px;
}
.tp-le-row .tp-set-label {
  flex: 0 0 46px;
  font-size: 14px;
}

.tp-le-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.tp-le-pill {
  border: 1px solid rgba(255, 255, 255, 0.18);
  background: rgba(255, 255, 255, 0.06);
  color: #d4d4d8;
  border-radius: 999px;
  padding: 6px 12px;
  font-size: 13px;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
.tp-le-pill.is-on {
  background: var(--color-brand, #6500AA);
  border-color: var(--color-brand-light, #8B2FC9);
  color: #fff;
}
.tp-le-pill:active {
  background: rgba(255, 255, 255, 0.16);
}

.tp-le-grid {
  display: grid;
  gap: 6px;
  margin: 10px 0;
  aspect-ratio: 16/7;
  max-height: 220px;
}

.tp-le-cell {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.05);
  color: #fafafa;
  cursor: pointer;
  min-height: 44px;
  padding: 4px;
  overflow: hidden;
}
.tp-le-cell i {
  font-size: 20px;
}
.tp-le-cell .tp-le-empty {
  font-size: 20px;
  color: #71717a;
}
.tp-le-cell .tp-le-cell-label {
  font-size: 11px;
  text-align: center;
  line-height: 1.1;
}
.tp-le-cell .tp-le-cell-hold {
  font-size: 10px;
  color: #a1a1aa;
}
.tp-le-cell.is-selected {
  border-color: var(--color-brand-blue, #39B3EA);
  box-shadow: 0 0 0 1px var(--color-brand-blue, #39B3EA) inset;
}

.tp-le-bind {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  padding: 10px 0;
  margin-bottom: 8px;
}

.tp-le-org {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.tp-le-org-empty {
  color: #a1a1aa;
  font-size: 13px;
}

.tp-le-org-row {
  display: flex;
  align-items: center;
  gap: 6px;
}

.tp-le-org-apply {
  flex: 1 1 auto;
  text-align: left;
  border: 1px solid rgba(255, 255, 255, 0.15);
  background: rgba(255, 255, 255, 0.06);
  color: #fafafa;
  border-radius: 8px;
  padding: 10px 12px;
  font-size: 14px;
  cursor: pointer;
}
.tp-le-org-apply:active {
  background: rgba(255, 255, 255, 0.16);
}

.tp-le-org-row.is-default .tp-le-org-apply {
  border-color: rgba(57, 179, 234, 0.6);
  background: rgba(57, 179, 234, 0.12);
}

.tp-le-org-badge {
  margin-left: 8px;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--color-brand-blue, #39B3EA);
}

.tp-le-org-default {
  flex: 0 0 auto;
  width: 40px;
  height: 40px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: #a1a1aa;
  cursor: pointer;
}
.tp-le-org-default.is-on {
  color: #f5c518;
}

.tp-le-org-del {
  flex: 0 0 auto;
  width: 40px;
  height: 40px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: #ef4444;
  cursor: pointer;
}

.tp-le-save {
  margin-top: 10px;
  width: 100%;
  border: 1px dashed rgba(57, 179, 234, 0.5);
  background: rgba(57, 179, 234, 0.1);
  color: var(--color-brand-blue, #39B3EA);
  border-radius: 10px;
  padding: 12px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
}

.tp-css-fs {
  position: fixed;
  inset: 0;
  z-index: 2147483000;
  width: 100vw;
  height: 100vh;
  height: 100dvh;
  margin: 0;
  border: 0 !important;
  border-radius: 0 !important;
  background: #000;
  display: flex;
  align-items: center;
  justify-content: center;
}
.tp-css-fs:not(.is-touch-split) .analyse-video, .tp-css-fs:not(.is-touch-split) > #play-modal-video {
  width: 100%;
  height: 100%;
  max-height: none;
  object-fit: contain;
}

body.tp-css-fs-body {
  overflow: hidden;
  touch-action: none;
}

.tp-chrome-hidden {
  cursor: none;
}
.tp-chrome-hidden .analyse-overlay-controls {
  opacity: 0 !important;
  transform: translateY(6px) !important;
  pointer-events: none !important;
  transition: opacity 0.4s ease, transform 0.4s ease;
}
.tp-chrome-hidden .tp-follow,
.tp-chrome-hidden .tp-follow-picker,
.tp-chrome-hidden .tp-hud {
  opacity: 0 !important;
  pointer-events: none;
  transition: opacity 0.4s ease;
}

.tp-set-row.tp-split-row {
  grid-template-columns: 1fr;
  padding: 10px 0;
}

.tp-split-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.tp-split-pills .tp-le-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 40px;
  padding: 6px 14px;
  font-size: 14px;
}
.tp-split-pills .tp-le-pill.is-locked {
  box-shadow: inset 0 0 0 2px rgba(255, 255, 255, 0.55);
}

.tp-split-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  flex: 0 0 auto;
}

.analyse-video-container:fullscreen,
.analyse-video-container:-webkit-full-screen {
  border: 0 !important;
  border-radius: 0 !important;
}

.form-group {
  margin-bottom: 1rem;
}

.text-muted {
  color: var(--color-text-muted) !important;
}

@font-face {
  font-family: "Gilroy";
  src: url("/fonts/gilroy-light.woff2") format("woff2"), url("/fonts/gilroy-light.woff") format("woff");
  font-weight: 300;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Gilroy";
  src: url("/fonts/gilroy-regular.woff2") format("woff2"), url("/fonts/gilroy-regular.woff") format("woff");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Gilroy";
  src: url("/fonts/gilroy-medium.woff2") format("woff2"), url("/fonts/gilroy-medium.woff") format("woff");
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Gilroy";
  src: url("/fonts/gilroy-bold.woff2") format("woff2"), url("/fonts/gilroy-bold.woff") format("woff");
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Gilroy";
  src: url("/fonts/gilroy-black.otf") format("opentype");
  font-weight: 900;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Source Sans 3";
  src: url("/fonts/SourceSans3VF-Upright.ttf.woff2") format("woff2-variations");
  font-weight: 200 900;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Source Sans 3";
  src: url("/fonts/SourceSans3VF-Italic.ttf.woff2") format("woff2-variations");
  font-weight: 200 900;
  font-style: italic;
  font-display: swap;
}
@font-face {
  font-family: "Source Sans 3";
  src: url("/fonts/SourceSans3-Regular.ttf.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Source Sans 3";
  src: url("/fonts/SourceSans3-It.ttf.woff2") format("woff2");
  font-weight: 400;
  font-style: italic;
  font-display: swap;
}
@font-face {
  font-family: "Source Sans 3";
  src: url("/fonts/SourceSans3-Medium.ttf.woff2") format("woff2");
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Source Sans 3";
  src: url("/fonts/SourceSans3-MediumIt.ttf.woff2") format("woff2");
  font-weight: 500;
  font-style: italic;
  font-display: swap;
}
@font-face {
  font-family: "Source Sans 3";
  src: url("/fonts/SourceSans3-Semibold.ttf.woff2") format("woff2");
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Source Sans 3";
  src: url("/fonts/SourceSans3-SemiboldIt.ttf.woff2") format("woff2");
  font-weight: 600;
  font-style: italic;
  font-display: swap;
}
@font-face {
  font-family: "Source Sans 3";
  src: url("/fonts/SourceSans3-Bold.ttf.woff2") format("woff2");
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Source Sans 3";
  src: url("/fonts/SourceSans3-BoldIt.ttf.woff2") format("woff2");
  font-weight: 700;
  font-style: italic;
  font-display: swap;
}
:root {
  --color-bg-primary: #010C1C;
  --color-bg-secondary: #0A1929;
  --color-bg-elevated: #0F2336;
  --color-bg-hover: #1A3550;
  --color-brand: #6500AA;
  --color-brand-light: #8B2FC9;
  --color-brand-dark: #4A0080;
  --color-brand-blue: #39B3EA;
  --color-brand-blue-rgb: 57, 179, 234;
  --color-brand-blue-dark: #2899cc;
  --color-text-primary: #fafafa;
  --color-text-secondary: #a1a1aa;
  --color-text-muted: #71717a;
  --color-border: rgba(255, 255, 255, 0.08);
  --color-border-hover: rgba(255, 255, 255, 0.15);
  --color-success: #77B300;
  --color-warning: #f59e0b;
  --color-danger: #ef4444;
  --color-info: #3b82f6;
  --spacing-xs: 0.25rem;
  --spacing-sm: 0.5rem;
  --spacing-md: 1rem;
  --spacing-lg: 1.5rem;
  --spacing-xl: 2rem;
  --spacing-2xl: 3rem;
  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 16px;
  --radius-xl: 24px;
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.3);
  --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.3), 0 2px 4px -2px rgba(0, 0, 0, 0.3);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.4), 0 4px 6px -4px rgba(0, 0, 0, 0.4);
  --shadow-glow: 0 0 20px rgba(84, 85, 255, 0.15);
  --transition-fast: 150ms ease;
  --transition-normal: 250ms ease;
  --transition-slow: 350ms ease;
}

/* Brand-toned text states — Bootstrap's .text-success/.text-warning are
   Bootstrap's greens and ambers, not ours. */
.text-brand-success {
  color: var(--color-success) !important;
}

.text-brand-warning {
  color: var(--color-warning) !important;
}

* {
  box-sizing: border-box;
}

body {
  color: var(--color-text-primary);
  background-color: var(--color-bg-primary);
  font-family: "Source Sans 3", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  font-weight: 400;
  line-height: 1.6;
  padding-top: calc(80px + env(safe-area-inset-top, 0px));
  padding-left: env(safe-area-inset-left, 0px);
  padding-right: env(safe-area-inset-right, 0px);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
@media (max-width: 767.98px) {
  body {
    padding-top: calc(80px + env(safe-area-inset-top, 0px));
  }
}
body::before {
  content: "";
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: env(safe-area-inset-top, 0px);
  background: var(--color-bg-primary);
  z-index: 1035;
  pointer-events: none;
}
body.tp-css-fs-body::before {
  display: none;
}
body.no-navbar {
  padding-top: env(safe-area-inset-top, 0px);
}
@media (max-width: 767.98px) {
  body.no-navbar {
    padding-top: env(safe-area-inset-top, 0px);
  }
}

h1, h2, h3, h4, h5, h6, .h1, .h2, .h3, .h4, .h5, .h6 {
  font-family: "Gilroy", -apple-system, BlinkMacSystemFont, sans-serif;
  color: var(--color-text-primary);
  font-weight: 700;
  line-height: 1.3;
  margin-bottom: var(--spacing-md);
}

h1 {
  font-weight: 700;
  font-size: 2rem;
  letter-spacing: -0.02em;
}

h2 {
  font-weight: 700;
  font-size: 1.5rem;
}

h3 {
  font-weight: 700;
  font-size: 1.25rem;
}

p {
  color: var(--color-text-secondary);
  margin-bottom: var(--spacing-md);
}

a {
  color: var(--color-text-primary);
  text-decoration: none;
  transition: opacity var(--transition-fast);
}
a:hover, a:focus {
  color: var(--color-text-primary);
  opacity: 0.8;
  text-decoration: none;
}
a.btn {
  opacity: 1;
}
a.btn:hover, a.btn:focus {
  opacity: 1;
}

section {
  margin: var(--spacing-lg) var(--spacing-md);
}

.dropdown-menu {
  background-color: var(--color-bg-elevated);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-lg);
  padding: var(--spacing-sm);
  margin-top: var(--spacing-sm);
}

.dropdown-item {
  color: var(--color-text-primary);
  border-radius: var(--radius-sm);
  padding: var(--spacing-sm) var(--spacing-md);
  transition: background-color var(--transition-fast), color var(--transition-fast);
  text-align: left;
  opacity: 1;
}
.dropdown-item:hover, .dropdown-item:focus {
  color: white;
  opacity: 1;
  background-color: var(--color-brand-blue);
}
.dropdown-item.active {
  color: white;
  background-color: var(--color-brand-blue);
}

.dropdown-divider {
  border-color: var(--color-border);
  margin: var(--spacing-sm) 0;
}

.dropdown-toggle-split.dropdown-toggle::after,
.dropdown-toggle.no-caret::after {
  display: none;
}

.btn-group .btn.dropdown-toggle-split,
.btn-group .lg-text,
.dropdown .btn.dropdown-toggle-split {
  outline: none !important;
  box-shadow: none !important;
  border: none !important;
}
.btn-group .btn.dropdown-toggle-split:focus, .btn-group .btn.dropdown-toggle-split:active, .btn-group .btn.dropdown-toggle-split:focus-visible, .btn-group .btn.dropdown-toggle-split:hover, .btn-group .btn.dropdown-toggle-split[aria-expanded=true],
.btn-group .lg-text:focus,
.btn-group .lg-text:active,
.btn-group .lg-text:focus-visible,
.btn-group .lg-text:hover,
.btn-group .lg-text[aria-expanded=true],
.dropdown .btn.dropdown-toggle-split:focus,
.dropdown .btn.dropdown-toggle-split:active,
.dropdown .btn.dropdown-toggle-split:focus-visible,
.dropdown .btn.dropdown-toggle-split:hover,
.dropdown .btn.dropdown-toggle-split[aria-expanded=true] {
  outline: none !important;
  box-shadow: none !important;
  border: none !important;
}

.btn-group .dropdown-toggle-split {
  color: var(--color-text-muted);
  transition: color var(--transition-fast);
}
.btn-group .dropdown-toggle-split:hover {
  color: white;
}

.bg-frost {
  -webkit-backdrop-filter: blur(12px) saturate(180%);
  backdrop-filter: blur(12px) saturate(180%);
  background-color: rgba(1, 12, 28, 0.85);
  border: 1px solid var(--color-border);
}
.bg-frost .navbar-nav > li > .dropdown-menu {
  backdrop-filter: blur(12px) saturate(180%);
  background-color: rgba(1, 12, 28, 0.95);
}
.bg-frost .dropdown-item {
  color: var(--color-text-primary);
  opacity: 1;
}
.bg-frost .dropdown-item:hover, .bg-frost .dropdown-item:focus {
  color: white;
  opacity: 1;
  background-color: var(--color-brand-blue);
}
.bg-frost .dropdown-divider {
  border-color: var(--color-border);
}

.lg-text {
  font-family: "Gilroy", -apple-system, BlinkMacSystemFont, sans-serif !important;
  font-size: 1.75rem;
  font-weight: 700 !important;
  letter-spacing: -0.01em;
}

.lg-text-sm {
  font-family: "Gilroy", -apple-system, BlinkMacSystemFont, sans-serif !important;
  font-size: 1.5rem;
  font-weight: 700 !important;
  letter-spacing: -0.01em;
}

.btn.lg-text,
.btn.lg-text-sm {
  border: none !important;
  box-shadow: none !important;
  outline: none !important;
  background: transparent !important;
  padding-top: 0 !important;
  padding-bottom: 0 !important;
  cursor: default;
}

.navbar-header {
  color: var(--color-text-secondary);
}

.navbar-toggler {
  border: 1px solid var(--color-border);
  color: var(--color-text-primary);
  padding: var(--spacing-sm) var(--spacing-md);
  border-radius: var(--radius-sm);
  margin-right: var(--spacing-md);
  background-color: rgba(255, 255, 255, 0.1);
  -webkit-backdrop-filter: blur(8px) saturate(150%);
  backdrop-filter: blur(8px) saturate(150%);
  transition: background-color var(--transition-fast), border-color var(--transition-fast), backdrop-filter var(--transition-fast);
}
.navbar-toggler:hover {
  background-color: rgba(255, 255, 255, 0.15);
  border-color: var(--color-border-hover);
}

.navbar {
  font-family: "Gilroy", -apple-system, BlinkMacSystemFont, sans-serif;
  margin: 0 calc(var(--spacing-md) + env(safe-area-inset-right, 0px)) var(--spacing-md) calc(var(--spacing-md) + env(safe-area-inset-left, 0px));
  padding-top: var(--spacing-sm);
  padding-bottom: var(--spacing-sm);
  min-height: 60px;
  width: calc(100% - 2 * var(--spacing-md) - env(safe-area-inset-left, 0px) - env(safe-area-inset-right, 0px));
  border-radius: 0 0 var(--radius-lg) var(--radius-lg);
  background: linear-gradient(135deg, #6500AA 0%, #04182F 25%, #04182F 75%, #39B3EA 100%);
  border: 1px solid #1a1a1f;
}
.navbar .navbar-collapse.show,
.navbar .navbar-collapse.collapsing {
  display: flex;
  flex-direction: column;
}
@media (min-width: 992px) {
  .navbar .navbar-collapse {
    display: flex !important;
    flex-basis: auto;
    flex-grow: 1;
    align-items: center;
    justify-content: space-between;
  }
}
.navbar .navbar-nav {
  align-items: center;
}
.navbar .navbar-brand {
  font-weight: 700;
  font-size: 1.1rem;
  letter-spacing: 0.02em;
  color: var(--color-text-primary);
  transition: opacity var(--transition-fast);
}
.navbar .navbar-brand:hover {
  opacity: 0.8;
}
.navbar .navbar-brand > img {
  display: inline-block;
  width: 40px;
  height: 40px;
  margin-right: var(--spacing-sm);
}
.navbar .nav-item {
  margin-right: var(--spacing-sm);
}
.navbar .nav-link {
  color: white;
  font-weight: 500;
  padding: var(--spacing-sm) var(--spacing-md);
  border-radius: var(--radius-sm);
  transition: color var(--transition-fast), background-color var(--transition-fast), backdrop-filter var(--transition-fast);
}
.navbar .nav-link:hover, .navbar .nav-link:focus {
  color: var(--color-text-primary);
  background-color: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(8px) saturate(150%);
  -webkit-backdrop-filter: blur(8px) saturate(150%);
}
.navbar .nav-link.clock {
  color: var(--color-text-secondary);
}
.navbar .nav-link.clock:hover, .navbar .nav-link.clock:focus {
  color: var(--color-text-primary);
}
.navbar .nav-link.clock.clock-tz-mismatch, .navbar .nav-link.clock.clock-tz-mismatch:hover, .navbar .nav-link.clock.clock-tz-mismatch:focus {
  color: var(--color-warning);
}

.btn {
  font-weight: 500;
  border-radius: var(--radius-sm);
  padding: var(--spacing-sm) var(--spacing-md);
  transition: all var(--transition-fast);
  border: 1px solid transparent;
}
.btn:focus {
  box-shadow: 0 0 0 3px rgba(57, 179, 234, 0.25);
}

.btn-primary {
  background-color: var(--color-brand);
  border-color: var(--color-brand);
  color: white;
}
.btn-primary:hover, .btn-primary:focus {
  background-color: var(--color-brand-dark);
  border-color: var(--color-brand-dark);
  transform: translateY(-1px);
}
.btn-primary:active {
  transform: translateY(0);
}

.btn-success {
  background-color: var(--color-success);
  border-color: var(--color-success);
  color: white;
}
.btn-success:hover {
  background-color: #8BC934;
  border-color: #8BC934;
  transform: translateY(-1px);
}

.new-session-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--spacing-sm) var(--spacing-md);
  border-radius: var(--radius-sm);
  transition: background-color var(--transition-fast), backdrop-filter var(--transition-fast);
}
.new-session-btn .new-session-plus {
  display: none;
  font-size: 1.2rem;
  width: 28px;
  height: 28px;
  align-items: center;
  justify-content: center;
}
.new-session-btn:not(.no-hover):hover {
  background-color: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(8px) saturate(150%);
  -webkit-backdrop-filter: blur(8px) saturate(150%);
}
.new-session-btn:not(.no-hover):hover .new-session-icon {
  display: none;
}
.new-session-btn:not(.no-hover):hover .new-session-plus {
  display: flex;
}
.new-session-btn.no-hover {
  cursor: default;
}

.new-session-icon {
  width: 28px;
  height: 28px;
}

.btn-danger {
  background-color: var(--color-danger);
  border-color: var(--color-danger);
  color: white;
}
.btn-danger:hover, .btn-danger:focus {
  transform: translateY(-1px);
}
.btn-danger:active {
  transform: translateY(0);
}

.btn-info {
  background-color: var(--color-brand);
  border-color: var(--color-brand);
  color: white;
}
.btn-info:hover {
  background-color: var(--color-brand-dark);
  transform: translateY(-1px);
}

.btn-outline-danger {
  color: var(--color-text-primary);
  border-color: transparent;
  background: transparent;
}
.btn-outline-danger:hover {
  color: white;
  background-color: var(--color-danger);
  border-color: var(--color-danger);
}

.btn-outline-warning {
  color: white;
  border-color: transparent;
  background: transparent;
}
.btn-outline-warning:hover {
  color: white;
  background-color: var(--color-warning);
  border-color: var(--color-warning);
}

.btn-outline-dark {
  color: var(--color-text-primary);
  border-color: var(--color-border);
  background-color: transparent;
}
.btn-outline-dark:hover {
  border-color: var(--color-border-hover);
  background-color: var(--color-bg-hover);
}
.btn-outline-dark:focus {
  box-shadow: 0 0 0 3px rgba(57, 179, 234, 0.15);
  border-color: var(--color-border-hover);
  background-color: var(--color-bg-hover);
}
.btn-outline-dark:active {
  background-color: var(--color-bg-elevated);
}

.btn-outline-info {
  color: var(--color-text-primary);
  border-color: transparent;
  background: transparent;
}
.btn-outline-info:hover {
  color: white;
  background-color: var(--color-brand);
  border-color: var(--color-brand);
}

.btn-outline-success {
  color: white;
  border-color: transparent;
  background: transparent;
}
.btn-outline-success:hover {
  color: white;
  background-color: var(--color-success);
  border-color: var(--color-success);
}

.btn-outline-primary {
  color: var(--color-text-primary);
  border-color: transparent;
  background: transparent;
}
.btn-outline-primary:hover {
  color: white;
  background-color: var(--color-brand);
  border-color: var(--color-brand);
}

.btn-brand {
  background-color: var(--color-brand-blue);
  border-color: var(--color-brand-blue);
  color: white;
}
.btn-brand:hover, .btn-brand:focus {
  background-color: var(--color-brand-blue-dark);
  border-color: var(--color-brand-blue-dark);
  color: white;
  transform: translateY(-1px);
}
.btn-brand:active {
  transform: translateY(0);
}
.btn-brand.active {
  background-color: var(--color-brand-blue-dark);
  border-color: var(--color-brand-blue-dark);
  color: white;
}

.btn-outline-brand {
  color: white;
  border-color: transparent;
  background: transparent;
}
.btn-outline-brand:hover, .btn-outline-brand:focus-visible {
  color: white;
  background-color: var(--color-brand-blue);
  border-color: var(--color-brand-blue);
}
.btn-outline-brand.active {
  background-color: var(--color-brand-blue);
  border-color: var(--color-brand-blue);
  color: white;
}

.btn-group-vertical > .btn {
  margin-bottom: var(--spacing-sm);
  border-radius: var(--radius-sm) !important;
}

.bg-warning {
  background-color: var(--color-brand) !important;
}

pre {
  color: var(--color-brand-blue);
  background-color: var(--color-bg-elevated);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  white-space: pre-wrap;
  overflow-x: auto;
  padding: var(--spacing-md);
  font-family: "SF Mono", "Fira Code", "Consolas", monospace;
  font-size: 0.875rem;
}
pre > h3 {
  color: var(--color-text-primary);
  font-size: 1em;
  margin-top: var(--spacing-xs);
  margin-bottom: var(--spacing-xs);
}
pre.angle-log {
  color: var(--color-text-primary);
}

.angle-log-container {
  position: relative;
}
.angle-log-container .angle-log-email {
  position: absolute;
  top: var(--spacing-sm);
  right: var(--spacing-sm);
  z-index: 2;
  font-size: 1rem;
}
.angle-log-container .angle-log-email:hover {
  color: var(--color-brand);
}

code {
  color: var(--color-brand-blue);
  white-space: nowrap;
  background-color: var(--color-bg-elevated);
  padding: 0.125em 0.375em;
  border-radius: var(--radius-sm);
  font-size: 0.875em;
}

.form-control {
  color: var(--color-text-primary);
  background-color: var(--color-bg-secondary);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  padding: var(--spacing-sm) var(--spacing-md);
  transition: border-color var(--transition-fast), box-shadow var(--transition-fast);
}
.form-control::placeholder {
  color: var(--color-text-muted);
}
.form-control:hover {
  border-color: var(--color-border-hover);
}
.form-control:focus {
  border-color: var(--color-brand-blue);
  box-shadow: 0 0 0 3px rgba(57, 179, 234, 0.15);
  background-color: var(--color-bg-secondary);
  color: var(--color-text-primary);
}
.form-control:disabled {
  color: var(--color-text-muted);
  background-color: var(--color-bg-elevated);
  opacity: 0.65;
}

.form-label, label {
  color: var(--color-text-secondary);
  font-weight: 600;
  margin-bottom: var(--spacing-xs);
}

.help-block {
  color: var(--color-text-muted);
  font-size: 0.85rem;
  margin-top: var(--spacing-xs);
}

input[type=number] {
  color-scheme: dark;
}

.form-select {
  color: var(--color-text-primary);
  background-color: var(--color-bg-secondary);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3e%3cpath fill='none' stroke='%2339B3EA' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='m2 5 6 6 6-6'/%3e%3c/svg%3e");
}
.form-select:hover {
  border-color: var(--color-brand-blue);
}
.form-select:focus {
  border-color: var(--color-brand-blue);
  box-shadow: 0 0 0 3px rgba(57, 179, 234, 0.15);
}
.form-select option {
  background-color: var(--color-bg-secondary);
  color: var(--color-text-primary);
}
.form-select:disabled {
  color: var(--color-text-muted);
  background-color: var(--color-bg-elevated);
  opacity: 0.65;
}

textarea.auto-resize {
  resize: none;
  overflow: hidden;
  min-height: 38px;
  height: auto !important;
  line-height: 1.5;
  field-sizing: content;
}

.sign-in-hero {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--color-bg-primary);
  background-image: url(/images/fulcrum-orb-logo.svg);
  background-size: 150vmin;
  background-position: center;
  background-repeat: no-repeat;
  z-index: 1000;
}

.sign-in-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: radial-gradient(ellipse at center, rgba(1, 12, 28, 0.4) 0%, rgba(1, 12, 28, 0.6) 50%, rgba(1, 12, 28, 0.85) 100%);
  pointer-events: none;
  animation: overlay-fade 1s ease-out both, overlay-pulse 4s ease-in-out 1s infinite;
}

@keyframes overlay-fade {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}
@keyframes overlay-pulse {
  0%, 100% {
    opacity: 1;
  }
  50% {
    opacity: 0.88;
  }
}
.sign-in-card {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 400px;
  padding: var(--spacing-md) var(--spacing-xl);
  background: rgba(24, 24, 27, 0.8);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: var(--radius-xl);
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5), 0 0 0 1px rgba(255, 255, 255, 0.05) inset, var(--shadow-glow);
  text-align: center;
  animation: sign-in-appear 1.2s ease-out both;
}
@media (max-width: 480px) {
  .sign-in-card {
    margin: var(--spacing-md);
    padding: var(--spacing-xl);
  }
}

@keyframes sign-in-appear {
  from {
    opacity: 0;
    transform: scale(0.96);
    filter: blur(4px);
  }
  to {
    opacity: 1;
    transform: scale(1);
    filter: blur(0);
  }
}
.sign-in-logo {
  margin: -1.5rem 0 -1rem 0;
  line-height: 0;
}
.sign-in-logo img {
  width: 300px;
  height: 300px;
  opacity: 0.9;
  filter: drop-shadow(0 4px 12px rgba(84, 85, 255, 0.3));
  margin: -40px 0;
}

.sign-in-title {
  font-family: "Gilroy", -apple-system, BlinkMacSystemFont, sans-serif;
  font-size: 3rem;
  font-weight: 900;
  letter-spacing: 0.05em;
  color: var(--color-text-primary);
  margin-bottom: var(--spacing-xs);
  text-transform: uppercase;
}

.sign-in-subtitle {
  font-size: 0.9rem;
  color: var(--color-text-muted);
  margin-bottom: var(--spacing-md);
  letter-spacing: 0.02em;
}

.sign-in-field {
  margin-bottom: var(--spacing-md);
  text-align: left;
}

.sign-in-label {
  display: block;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--color-text-secondary);
  margin-bottom: var(--spacing-xs);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.sign-in-input {
  width: 100%;
  padding: var(--spacing-md);
  font-size: 1rem;
  color: var(--color-text-primary);
  background: rgba(1, 12, 28, 0.6);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  transition: border-color var(--transition-fast), box-shadow var(--transition-fast), background-color var(--transition-fast);
}
.sign-in-input::placeholder {
  color: var(--color-text-muted);
}
.sign-in-input:hover {
  border-color: var(--color-border-hover);
  background: rgba(1, 12, 28, 0.8);
}
.sign-in-input:focus {
  outline: none;
  border-color: var(--color-brand);
  background: rgba(1, 12, 28, 0.9);
  box-shadow: 0 0 0 3px rgba(84, 85, 255, 0.2);
}

.sign-in-button {
  width: 100%;
  padding: var(--spacing-md) var(--spacing-lg);
  margin-top: var(--spacing-md);
  font-family: "Gilroy", -apple-system, BlinkMacSystemFont, sans-serif;
  font-size: 1rem;
  font-weight: 600;
  color: white;
  background: linear-gradient(135deg, var(--color-brand) 0%, var(--color-brand-dark) 100%);
  border: none;
  border-radius: var(--radius-md);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--spacing-sm);
  transition: transform var(--transition-fast), box-shadow var(--transition-fast), background var(--transition-fast);
}
.sign-in-button:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 25px -5px rgba(84, 85, 255, 0.4);
  background: linear-gradient(135deg, var(--color-brand-light) 0%, var(--color-brand) 100%);
}
.sign-in-button:active {
  transform: translateY(0);
}
.sign-in-button:focus {
  outline: none;
  box-shadow: 0 0 0 3px rgba(84, 85, 255, 0.3);
}
.sign-in-button i {
  font-size: 0.9em;
  transition: transform var(--transition-fast);
}
.sign-in-button:hover i {
  transform: translateX(3px);
}
.sign-in-button:disabled {
  opacity: 0.7;
  cursor: not-allowed;
  transform: none;
}

.sign-in-licence-warning {
  margin-top: var(--spacing-xl);
  padding: var(--spacing-md);
  background: rgba(239, 68, 68, 0.15);
  border: 1px solid rgba(239, 68, 68, 0.3);
  border-radius: var(--radius-md);
  color: #fca5a5;
  font-size: 0.85rem;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--spacing-sm);
}
.sign-in-licence-warning i {
  color: var(--color-danger);
}

.licence-card {
  max-width: 500px;
  margin-top: 80px;
}
.licence-card .sign-in-logo {
  margin: -0.5rem 0 0 0;
}
.licence-card .sign-in-logo img {
  width: 120px;
  height: 120px;
  margin: -10px 0;
}
.licence-card .sign-in-title {
  font-size: 1.5rem;
  margin-bottom: 0;
}
.licence-card .sign-in-subtitle {
  margin-bottom: var(--spacing-sm);
}
.licence-card .alert {
  margin-bottom: var(--spacing-sm);
  padding: var(--spacing-sm) var(--spacing-md);
  font-size: 0.9rem;
}

.sign-in-card .command-errors {
  text-align: left;
  margin-bottom: var(--spacing-md);
}
.sign-in-card .command-errors ul {
  margin: 0;
  padding-left: var(--spacing-lg);
}

form .command-errors {
  display: none;
}

.session-action-menu {
  display: inline-block;
  background: var(--color-bg-secondary);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  font-size: 1rem;
  padding: var(--spacing-sm);
}
.session-action-menu .btn {
  font-size: 1rem;
}

.marker-count {
  font-size: 1.2rem;
  color: var(--color-text-secondary);
}

.widget {
  background: var(--color-bg-secondary);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  padding: var(--spacing-sm) var(--spacing-md) var(--spacing-md);
  margin-bottom: 1rem;
  flex-grow: 1;
}
.widget:not(:has(.widget-content)) {
  padding-bottom: var(--spacing-sm);
}
.widget.widget-danger {
  border-color: var(--color-danger);
}
.widget .widget-header {
  display: flex;
  align-items: center;
  min-height: 28px;
}
.widget .widget-title {
  font-weight: 600;
  font-size: 1rem;
}
.widget .widget-content {
  padding: var(--spacing-sm) var(--spacing-sm) 0;
}
.widget .dropdown-toggle:hover {
  background-color: var(--color-brand-blue);
  border-color: var(--color-brand-blue);
  color: white;
}

.sftp-widget {
  background: var(--color-bg-elevated);
}

/* Amplify upload widget (admin page) */
.amplify-sessions-table td, .amplify-sessions-table th {
  vertical-align: middle;
}
.amplify-sessions-table .amplify-progress-row td {
  border-top: none;
  padding-top: 0;
}

.amplify-badge {
  display: inline-block;
  padding: 1px 8px;
  border-radius: 10px;
  font-size: 0.75rem;
  font-weight: 600;
  white-space: nowrap;
}
.amplify-badge.amplify-badge-success {
  background: rgba(40, 167, 69, 0.15);
  color: var(--color-success, #28a745);
}
.amplify-badge.amplify-badge-active {
  background: rgba(13, 110, 253, 0.15);
  color: var(--color-brand-blue);
}
.amplify-badge.amplify-badge-warn {
  background: rgba(255, 193, 7, 0.15);
  color: #d39e00;
}
.amplify-badge.amplify-badge-danger {
  background: rgba(220, 53, 69, 0.15);
  color: var(--color-danger, #dc3545);
}
.amplify-badge.amplify-badge-muted {
  background: var(--color-bg-elevated);
  color: var(--color-text-secondary, #888);
}

.amplify-progress-bar {
  height: 8px;
  background-color: transparent;
  border: 1px solid var(--color-border);
}
.amplify-progress-bar .progress-bar {
  background-color: var(--color-success);
}

.amplify-angle-name {
  font-weight: 600;
}

.amplify-angle-btn {
  padding: 0 6px;
  font-size: 0.7rem;
  line-height: 1.4;
}

/* Session-list upload badge: nudge up so the pill's bottom edge sits on the
   session name's text bottom (the centered flex row leaves it a touch low) */
.session-list [data-amplify-badge] {
  position: relative;
  top: -2px;
}

/* Countdown on scheduled/live session rows — always brand blue (the muted
   base was hard to read), success green once it flips to Starting…/Ending… */
.scheduled-countdown {
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
  color: var(--color-brand-blue);
}
.scheduled-countdown.is-starting {
  color: var(--color-success);
}

.scheduled_sessions,
.session-schedules {
  width: 100%;
  position: relative;
  z-index: 2;
}
.scheduled_sessions .session,
.session-schedules .session {
  background: var(--color-bg-secondary);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  transition: transform var(--transition-normal), box-shadow var(--transition-normal), border-color var(--transition-normal);
}
.scheduled_sessions .session:hover,
.session-schedules .session:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
  border-color: var(--color-brand-blue);
}
.scheduled_sessions .session,
.session-schedules .session {
  background: var(--color-bg-elevated);
  position: relative;
  padding: var(--spacing-md);
  padding-right: calc(var(--spacing-md) + 4rem);
}
.scheduled_sessions .session .timecode,
.session-schedules .session .timecode {
  font-family: "SF Mono", monospace;
  font-size: 0.85em;
  color: var(--color-text-secondary);
}
.scheduled_sessions .session .fa-thin,
.session-schedules .session .fa-thin {
  color: var(--color-text-secondary);
}
.scheduled_sessions .session .dropdown-toggle-split,
.session-schedules .session .dropdown-toggle-split {
  color: var(--color-text-muted);
  transition: color var(--transition-fast);
}
.scheduled_sessions .session:hover .dropdown-toggle-split,
.session-schedules .session:hover .dropdown-toggle-split {
  color: white;
}
.scheduled_sessions .session .dropdown-menu,
.session-schedules .session .dropdown-menu {
  z-index: 1050;
}
.scheduled_sessions .badge,
.session-schedules .badge {
  font-size: 0.75rem;
  padding: 0.35em 0.65em;
}
.scheduled_sessions .camera-pill,
.session-schedules .camera-pill {
  color: white;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}

.session-list .session {
  background: var(--color-bg-secondary);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  transition: transform var(--transition-normal), box-shadow var(--transition-normal), border-color var(--transition-normal);
}
.session-list .session:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
  border-color: var(--color-brand-blue);
}
.session-list .session {
  background: var(--color-bg-elevated);
}
.session-list .session.is-live {
  border-color: var(--color-danger, #dc3545);
  background: rgba(220, 53, 69, 0.06);
}
.session-list .session {
  position: relative;
  list-style: none;
  font-size: 1.4em;
  width: 100%;
  padding: var(--spacing-sm) var(--spacing-md);
  padding-right: calc(var(--spacing-md) + 2rem);
}
.session-list .session .p-2 {
  padding: var(--spacing-xs) var(--spacing-sm) !important;
}
.session-list .session .name {
  font-weight: 400;
  color: var(--color-text-primary);
}
.session-list .session .thumbnail {
  border-radius: var(--radius-md);
  width: 64px;
  padding: var(--spacing-xs);
  transition: transform var(--transition-fast);
}
.session-list .session .thumbnail:hover {
  transform: scale(1.05);
}
.session-list .session .stats {
  width: 100px;
}
.session-list .session .started {
  width: 140px;
}
.session-list .session .markers, .session-list .session .angles, .session-list .session .date, .session-list .session .time {
  display: block;
  font-weight: 400;
  font-size: 0.75rem;
  color: var(--color-text-muted);
}

.session-title {
  font-size: 1.5em;
  margin-bottom: 1rem;
}
.session-title .title-bar {
  width: 100%;
  background: var(--color-bg-secondary);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  padding: var(--spacing-xs) var(--spacing-md);
}
.session-title .title-bar .p-2 {
  padding: var(--spacing-xs) var(--spacing-sm) !important;
}
.session-title .title-bar h1 {
  margin-bottom: 0;
}
.session-title .title-bar .flex-grow-1 {
  min-width: 0;
}
.session-title .title-bar .btn-danger {
  color: white;
}
.session-title .title-bar .btn-danger i {
  color: white;
}

.session-info {
  padding-top: 0.15rem;
  margin-left: var(--spacing-sm);
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 0.75rem;
}

.ssh-support-links {
  margin-left: var(--spacing-sm);
  padding-top: 0.15rem;
  font-size: 0.75rem;
  display: flex;
  align-items: center;
  gap: var(--spacing-md);
}

.ssh-link-heading {
  color: var(--color-text-muted);
  font-weight: 500;
}

.ssh-link-item {
  display: inline-flex;
  align-items: center;
}

.ssh-link-label {
  color: var(--color-brand-blue);
  font-weight: 500;
  margin-right: 0.15rem;
}
.ssh-link-label:hover {
  color: var(--color-brand-blue-hover);
}

.ssh-link-copy {
  padding: 0 0.2rem;
  font-size: 0.7rem;
  color: var(--color-text-muted);
}
.ssh-link-copy:hover {
  color: var(--color-brand-blue);
}

.camera-form .form-control {
  background-color: var(--color-bg-elevated) !important;
}

.camera-list {
  overflow: visible;
}
.camera-list .camera-card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: var(--spacing-md);
  padding: 4px;
}
.camera-list .camera-card {
  background: var(--color-bg-secondary);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  transition: transform var(--transition-normal), box-shadow var(--transition-normal), border-color var(--transition-normal);
}
.camera-list .camera-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
  border-color: var(--color-brand-blue);
}
.camera-list .camera-card {
  background: var(--color-bg-elevated);
  padding: var(--spacing-sm);
  padding-left: calc(var(--spacing-sm) + 12px);
  padding-bottom: var(--spacing-md);
  position: relative;
  cursor: pointer;
  min-height: 90px;
}
.camera-list .camera-card::before {
  content: "";
  position: absolute;
  left: 1px;
  top: 1px;
  bottom: 1px;
  width: 8px;
  background: var(--card-gradient, linear-gradient(to bottom, #268bd2, #2aa198));
  border-radius: calc(var(--radius-md) - 1px) 0 0 calc(var(--radius-md) - 1px);
}
.camera-list .camera-card-name {
  font-weight: 600;
  font-size: 1.1rem;
  color: var(--color-text-primary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.camera-list .camera-card-url {
  font-size: 0.75rem;
  color: var(--color-text-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  margin-bottom: var(--spacing-xs);
}
.camera-list .camera-card-associations {
  position: absolute;
  bottom: var(--spacing-sm);
  left: calc(var(--spacing-sm) + 12px);
  display: flex;
  align-items: center;
  gap: var(--spacing-sm);
}
.camera-list .camera-card-orgs {
  display: flex;
  flex-wrap: wrap;
  gap: var(--spacing-xs);
}
.camera-list .camera-card-org-avatar {
  pointer-events: auto;
  opacity: 0.85;
}
.camera-list .camera-card-org-avatar:hover {
  opacity: 1;
}
.camera-list .camera-card-separator {
  width: 1px;
  height: 16px;
  background-color: var(--color-border-hover);
}
.camera-list .camera-card-groups {
  display: flex;
  flex-wrap: wrap;
  gap: var(--spacing-xs);
}
.camera-list .camera-card-group-avatar {
  pointer-events: auto;
  opacity: 0.85;
}
.camera-list .camera-card-group-avatar:hover {
  opacity: 1;
}
.camera-list .camera-checkbox-label {
  display: flex;
  align-items: center;
  margin: 0;
  cursor: pointer;
  position: relative;
}
.camera-list .camera-checkbox-label input[type=checkbox] {
  position: absolute;
  opacity: 0;
  width: 0;
  height: 0;
}
.camera-list .camera-checkbox-label .checkbox-icon {
  font-size: 0.75rem;
  color: var(--color-text-muted);
  transition: color var(--transition-fast);
}
.camera-list .camera-checkbox-label .checkbox-icon::before {
  content: "\f111";
  font-family: "Font Awesome 7 Pro";
  font-weight: 400;
}
.camera-list .camera-checkbox-label:hover .checkbox-icon {
  color: var(--color-text-secondary);
}
.camera-list .camera-checkbox-label input[type=checkbox]:checked + .checkbox-icon {
  color: var(--color-brand-blue);
}
.camera-list .camera-checkbox-label input[type=checkbox]:checked + .checkbox-icon::before {
  content: "\f058";
  font-weight: 900;
}
.camera-list #cam-delete-btn[disabled] {
  visibility: hidden;
  opacity: 0;
}
.camera-list #selected-count {
  color: var(--color-text-secondary);
}

.icon-checkbox, .icon-checkbox-compact {
  display: inline-flex;
  align-items: center;
  gap: var(--spacing-sm);
  cursor: pointer;
  position: relative;
  user-select: none;
}
.icon-checkbox input[type=checkbox], .icon-checkbox-compact input[type=checkbox] {
  position: absolute;
  opacity: 0;
  width: 0;
  height: 0;
}
.icon-checkbox .checkbox-icon, .icon-checkbox-compact .checkbox-icon {
  font-size: 1rem;
  color: var(--color-text-muted);
  transition: color var(--transition-fast);
}
.icon-checkbox .checkbox-icon::before, .icon-checkbox-compact .checkbox-icon::before {
  content: "\f111";
  font-family: "Font Awesome 7 Pro";
  font-weight: 400;
}
.icon-checkbox .checkbox-label, .icon-checkbox-compact .checkbox-label {
  color: var(--color-text-secondary);
}
.icon-checkbox:hover .checkbox-icon, .icon-checkbox-compact:hover .checkbox-icon {
  color: var(--color-text-secondary);
}
.icon-checkbox input[type=checkbox]:checked + .checkbox-icon, .icon-checkbox-compact input[type=checkbox]:checked + .checkbox-icon {
  color: var(--color-brand-blue);
}
.icon-checkbox input[type=checkbox]:checked + .checkbox-icon::before, .icon-checkbox-compact input[type=checkbox]:checked + .checkbox-icon::before {
  content: "\f058";
  font-weight: 900;
}
.icon-checkbox input[type=checkbox]:checked ~ .checkbox-label, .icon-checkbox-compact input[type=checkbox]:checked ~ .checkbox-label {
  color: var(--color-brand-blue);
}

.icon-checkbox-compact {
  gap: var(--spacing-xs);
}
.icon-checkbox-compact .checkbox-icon {
  font-size: 0.875rem;
}
.icon-checkbox-compact .checkbox-label {
  font-size: 0.9rem;
}

.icon-checkbox-brand-blue input[type=checkbox]:checked + .checkbox-icon {
  color: var(--color-brand-blue);
}
.icon-checkbox-brand-blue input[type=checkbox]:checked ~ .checkbox-label {
  color: var(--color-brand-blue);
}

.icon-radio {
  display: inline-flex;
  align-items: center;
  gap: var(--spacing-sm);
  cursor: pointer;
  position: relative;
  user-select: none;
}
.icon-radio input[type=radio] {
  position: absolute;
  opacity: 0;
  width: 0;
  height: 0;
}
.icon-radio .radio-icon {
  font-size: 1rem;
  color: var(--color-text-muted);
  transition: color var(--transition-fast);
}
.icon-radio .radio-icon::before {
  content: "\f111";
  font-family: "Font Awesome 7 Pro";
  font-weight: 400;
}
.icon-radio .radio-label {
  color: var(--color-text-primary);
}
.icon-radio:hover .radio-icon {
  color: var(--color-text-secondary);
}
.icon-radio input[type=radio]:checked + .radio-icon {
  color: var(--color-brand-blue);
}
.icon-radio input[type=radio]:checked + .radio-icon::before {
  content: "\f058";
  font-weight: 900;
}
.icon-radio input[type=radio]:checked ~ .radio-label {
  color: var(--color-brand-blue);
}

.org-select-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: var(--spacing-md);
}

.org-select-card {
  background: var(--color-bg-secondary);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  transition: transform var(--transition-normal), box-shadow var(--transition-normal), border-color var(--transition-normal);
}
.org-select-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
  border-color: var(--color-brand-blue);
}
.org-select-card {
  padding: var(--spacing-sm) var(--spacing-md);
  padding-right: calc(var(--spacing-md) + 1.5rem);
  position: relative;
  cursor: pointer;
}
.org-select-card input[type=radio] {
  position: absolute;
  opacity: 0;
  width: 0;
  height: 0;
}
.org-select-card .org-select-card-content {
  display: flex;
  align-items: center;
  gap: var(--spacing-sm);
}
.org-select-card .org-select-card-name {
  font-weight: 600;
  font-size: 1.1rem;
  color: var(--color-text-primary);
}
.org-select-card .radio-icon {
  font-size: 0.875rem;
  color: var(--color-text-muted);
  transition: color var(--transition-fast);
}
.org-select-card .radio-icon::before {
  content: "\f111";
  font-family: "Font Awesome 7 Pro";
  font-weight: 400;
}
.org-select-card:hover .radio-icon {
  color: var(--color-text-secondary);
}
.org-select-card input[type=radio]:checked ~ .card-actions .radio-icon {
  color: var(--color-brand-blue);
}
.org-select-card input[type=radio]:checked ~ .card-actions .radio-icon::before {
  content: "\f058";
  font-weight: 900;
}
.org-select-card:has(input[type=radio]:checked) {
  border-color: var(--color-brand-blue);
  box-shadow: 0 0 0 1px var(--color-brand-blue);
}
.org-select-card .card-actions {
  top: 50%;
  bottom: auto;
  transform: translateY(-50%);
}

.s3-sync-config-list {
  display: flex;
  flex-direction: column;
  gap: var(--spacing-sm);
}
.s3-sync-config-list .s3-config-card {
  background: var(--color-bg-secondary);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  transition: transform var(--transition-normal), box-shadow var(--transition-normal), border-color var(--transition-normal);
}
.s3-sync-config-list .s3-config-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
  border-color: var(--color-brand-blue);
}
.s3-sync-config-list .s3-config-card {
  background: var(--color-bg-elevated);
  position: relative;
  padding: var(--spacing-sm) var(--spacing-md);
  padding-right: calc(var(--spacing-md) + 70px);
}
.s3-sync-config-list .s3-config-name {
  font-weight: 600;
  color: var(--color-text-primary);
}
.s3-sync-config-list .s3-config-detail {
  font-size: 0.8rem;
  color: var(--color-text-muted);
}

.user-list .user-card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: var(--spacing-md);
}
.user-list .user-card {
  background: var(--color-bg-secondary);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  transition: transform var(--transition-normal), box-shadow var(--transition-normal), border-color var(--transition-normal);
}
.user-list .user-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
  border-color: var(--color-brand-blue);
}
.user-list .user-card {
  background: var(--color-bg-elevated);
  padding: var(--spacing-md);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  min-height: 100px;
}
.user-list .user-card-header {
  display: flex;
  align-items: center;
  gap: var(--spacing-sm);
  margin-bottom: var(--spacing-sm);
}
.user-list .user-card-avatar {
  pointer-events: none;
  flex-shrink: 0;
}
.user-list .user-card-avatar svg {
  border-radius: var(--radius-md);
}
.user-list .user-card-orgs {
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem;
  align-items: center;
}
.user-list .user-card-body {
  margin-bottom: var(--spacing-sm);
}
.user-list .user-card-name {
  font-weight: 600;
  font-size: 1.1rem;
  color: var(--color-text-primary);
}
.user-list .user-card-role {
  font-size: 0.8rem;
  color: var(--color-text-muted);
  text-transform: capitalize;
}
.user-list .user-card-org-avatar svg {
  border-radius: var(--radius-sm);
}
.user-list .user-card-actions {
  display: flex;
  gap: var(--spacing-xs);
}
.user-list .user-card-delete {
  position: absolute;
  bottom: var(--spacing-sm);
  right: var(--spacing-sm);
  z-index: 2;
}
.user-list .user-card-current {
  position: absolute;
  top: var(--spacing-sm);
  right: var(--spacing-sm);
  font-size: 0.75rem;
  color: var(--color-brand-blue);
  z-index: 2;
}
.user-list .user-card {
  position: relative;
  cursor: pointer;
}
.user-list .user-card.is-current-user {
  background: linear-gradient(135deg, rgba(var(--color-brand-blue-rgb), 0.25) 0%, rgba(var(--color-brand-blue-rgb), 0.15) 100%);
}

.live-export-config-list .organisation {
  background: var(--color-bg-secondary);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  transition: transform var(--transition-normal), box-shadow var(--transition-normal), border-color var(--transition-normal);
}
.live-export-config-list .organisation:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
  border-color: var(--color-brand-blue);
}
.live-export-config-list .organisation {
  width: 100%;
  padding: var(--spacing-sm) var(--spacing-md);
}

.organisation-list .org-card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: var(--spacing-md);
}
.organisation-list .org-card {
  background: var(--color-bg-secondary);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  transition: transform var(--transition-normal), box-shadow var(--transition-normal), border-color var(--transition-normal);
}
.organisation-list .org-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
  border-color: var(--color-brand-blue);
}
.organisation-list .org-card {
  background: var(--color-bg-elevated);
  padding: var(--spacing-md);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  min-height: 100px;
}
.organisation-list .org-card-link {
  display: block;
  text-decoration: none;
  color: inherit;
  cursor: pointer;
  flex: 1;
}
.organisation-list .org-card-link:hover, .organisation-list .org-card-link:focus {
  text-decoration: none;
  color: inherit;
}
.organisation-list .org-card-header {
  display: flex;
  align-items: center;
  gap: var(--spacing-sm);
  margin-bottom: var(--spacing-sm);
}
.organisation-list .org-card-avatar {
  pointer-events: none;
}
.organisation-list .org-card-avatar svg {
  border-radius: var(--radius-md);
}
.organisation-list .org-card-body {
  pointer-events: none;
  margin-bottom: var(--spacing-sm);
}
.organisation-list .org-card-name {
  font-weight: 600;
  font-size: 1.1rem;
  color: var(--color-text-primary);
}
.organisation-list .org-card-members {
  font-size: 0.8rem;
  color: var(--color-text-muted);
}
.organisation-list .org-card-actions {
  position: absolute;
  bottom: var(--spacing-sm);
  right: var(--spacing-sm);
  display: flex;
  gap: var(--spacing-xs);
  z-index: 2;
}
.organisation-list .org-card-orgs {
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem;
  align-items: center;
}
.organisation-list .org-card-org-avatar svg {
  border-radius: var(--radius-md);
}
.organisation-list .org-card {
  position: relative;
}

.btn-ghost-icon {
  background: transparent;
  border: none;
  padding: var(--spacing-xs);
  font-size: 0.75rem;
  color: var(--color-text-muted);
  cursor: pointer;
  transition: color var(--transition-fast);
}
.btn-ghost-icon:hover, .btn-ghost-icon:focus {
  background: transparent;
  color: var(--color-text-muted);
}
.btn-ghost-icon.btn-ghost-danger:hover, .btn-ghost-icon.btn-ghost-danger:focus {
  color: var(--color-danger);
}
.btn-ghost-icon.btn-ghost-primary:hover, .btn-ghost-icon.btn-ghost-primary:focus {
  color: var(--color-brand);
}
.btn-ghost-icon.btn-ghost-brand:hover, .btn-ghost-icon.btn-ghost-brand:focus {
  color: var(--color-brand-blue);
}
.btn-ghost-icon.btn-ghost-success:hover, .btn-ghost-icon.btn-ghost-success:focus {
  color: var(--color-success);
}
.btn-ghost-icon.btn-ghost-info:hover, .btn-ghost-icon.btn-ghost-info:focus {
  color: var(--color-info);
}

.btn-ghost-text {
  background: transparent;
  border: none;
  color: var(--color-text-secondary);
  cursor: pointer;
  transition: color var(--transition-fast);
}
.btn-ghost-text:hover, .btn-ghost-text:focus {
  background: transparent;
  color: var(--color-text-primary);
}

.card-actions {
  position: absolute;
  bottom: var(--spacing-sm);
  right: var(--spacing-sm);
  display: flex;
  gap: var(--spacing-xs);
  z-index: 2;
}

.view-toggle-group {
  display: inline-flex;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  overflow: hidden;
  margin-left: var(--spacing-sm);
}

.header-sort-dropdown {
  display: inline-flex;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  margin-left: var(--spacing-sm);
}
.header-sort-dropdown .view-toggle-btn {
  border-radius: calc(var(--radius-sm) - 1px);
}

.view-toggle-btn {
  background: transparent;
  border: none;
  padding: 2px 7px;
  font-size: 0.7rem;
  color: var(--color-text-muted);
  cursor: pointer;
  transition: background var(--transition-fast), color var(--transition-fast);
  line-height: 1;
}
.view-toggle-btn:hover {
  color: var(--color-text-primary);
}
.view-toggle-btn.active {
  background: transparent;
  color: var(--color-brand-blue);
}

[data-view-toggle] .view-cards {
  display: none;
}

.view-rows {
  display: none;
  flex-direction: column;
  gap: 4px;
}

.view-row {
  background: var(--color-bg-elevated);
  border: 1px solid var(--color-border);
  border-radius: 20px var(--radius-sm) var(--radius-sm) 20px;
  padding: var(--spacing-xs) var(--spacing-sm);
  overflow: hidden;
  display: flex;
  align-items: center;
  gap: var(--spacing-sm);
  position: relative;
  cursor: pointer;
  transition: box-shadow var(--transition-normal), border-color var(--transition-normal);
}
.view-row:hover {
  box-shadow: var(--shadow-md);
  border-color: var(--color-brand-blue);
}

.view-row-accent {
  width: 8px;
  align-self: stretch;
  border-radius: 0;
  margin: calc(var(--spacing-xs) * -1) 0 calc(var(--spacing-xs) * -1) calc(var(--spacing-sm) * -1);
  flex-shrink: 0;
}

.view-row-avatar {
  flex-shrink: 0;
  pointer-events: none;
}
.view-row-avatar svg {
  border-radius: var(--radius-sm);
}

.view-row-slate-thumb,
.slate-thumb {
  aspect-ratio: 16/9;
  width: auto;
  object-fit: cover;
  border-radius: var(--radius-sm);
  border: 1px solid var(--color-border);
  background: #000;
  flex-shrink: 0;
}

.view-row-slate-thumb {
  height: 28px;
  pointer-events: none;
}

.camera-card-name .view-row-slate-thumb {
  height: 22px;
  margin-right: var(--spacing-xs);
  vertical-align: middle;
}

.slate-thumb {
  height: 34px;
}

.view-row-name {
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--color-text-primary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  min-width: 0;
  flex-shrink: 0;
}

.view-row-secondary {
  font-size: 0.8rem;
  color: var(--color-text-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  min-width: 0;
}

.view-row-badges {
  display: flex;
  gap: var(--spacing-xs);
  align-items: center;
  flex-shrink: 0;
  margin-left: auto;
}

.view-row-actions {
  display: flex;
  gap: var(--spacing-xs);
  align-items: center;
  flex-shrink: 0;
  margin-left: auto;
  z-index: 2;
}

.view-row-badges ~ .view-row-actions {
  margin-left: 0;
}

.view-row.is-current-user {
  background: linear-gradient(135deg, rgba(var(--color-brand-blue-rgb), 0.25) 0%, rgba(var(--color-brand-blue-rgb), 0.15) 100%);
}

@keyframes cameraEditedGlow {
  0% {
    box-shadow: 0 0 0 0 rgba(var(--color-brand-blue-rgb), 0);
  }
  15% {
    box-shadow: 0 0 0 4px rgba(var(--color-brand-blue-rgb), 0.55);
  }
  45% {
    box-shadow: 0 0 0 7px rgba(var(--color-brand-blue-rgb), 0);
  }
  60% {
    box-shadow: 0 0 0 4px rgba(var(--color-brand-blue-rgb), 0.4);
  }
  100% {
    box-shadow: 0 0 0 9px rgba(var(--color-brand-blue-rgb), 0);
  }
}
.camera-card.camera-just-edited,
.view-row.camera-just-edited {
  animation: cameraEditedGlow 2.4s ease-out;
  border-color: var(--color-brand-blue);
  position: relative;
  z-index: 3;
}

.camera-gradient-icon {
  position: relative;
  z-index: 2;
  pointer-events: auto;
  background: transparent !important;
  font-size: 1rem;
}
.camera-gradient-icon::before {
  background: var(--cam-gradient);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}
.camera-gradient-icon.camera-gradient-icon-sm {
  font-size: 0.8rem;
}

.angle-list {
  padding: 0;
  list-style: none;
}

.angle-grid {
  display: grid;
  grid-template-columns: repeat(var(--angle-cols, 2), 1fr);
  gap: var(--spacing-md);
}
@media (max-width: 768px) {
  .angle-grid {
    grid-template-columns: 1fr !important;
  }
}

.angle-tile {
  border-radius: var(--radius-md);
  overflow: hidden;
  background: var(--color-bg-secondary);
  border: 1px solid var(--color-border);
}

.angle-tile-media {
  position: relative;
  aspect-ratio: 16/9;
  overflow: hidden;
  background: #000;
  cursor: pointer;
}

.angle-tile-thumb {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.angle-tile-overlay {
  position: absolute;
  inset: 0;
  opacity: 0;
  pointer-events: none;
  background: rgba(0, 0, 0, 0.55);
  transition: opacity 200ms;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

@media (hover: hover) {
  .angle-tile-media:hover .angle-tile-overlay {
    opacity: 1;
    pointer-events: auto;
  }
}
.angle-tile.angle-active .angle-tile-overlay {
  opacity: 1;
  pointer-events: auto;
}

.angle-tile-play {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.15);
  backdrop-filter: blur(4px);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 1.4rem;
  transition: transform 200ms;
  text-decoration: none;
}
.angle-tile-play:hover {
  transform: scale(1.1);
  color: #fff;
}

.angle-tile-actions {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: var(--spacing-xs) var(--spacing-sm);
  background: linear-gradient(to top, rgba(0, 0, 0, 0.7), transparent);
  display: flex;
  justify-content: center;
  gap: var(--spacing-xs);
}
.angle-tile-actions .btn-ghost-icon {
  color: rgba(255, 255, 255, 0.8);
  padding: 0.25rem 0.5rem;
  font-size: 1rem;
}
.angle-tile-actions .btn-ghost-icon:hover {
  color: #fff;
}

.angle-tile-name {
  padding: var(--spacing-xs) var(--spacing-sm);
  text-align: center;
  font-size: 0.8rem;
  font-weight: 500;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.angle-tile-color {
  height: 4px;
}

.angle-tile-status {
  position: absolute;
  top: 6px;
  right: 6px;
  z-index: 2;
  padding: 2px 8px;
  border-radius: var(--radius-sm);
  font-size: 0.65rem;
  font-weight: 600;
  background: rgba(0, 0, 0, 0.6);
  color: rgba(255, 255, 255, 0.8);
  backdrop-filter: blur(4px);
  display: flex;
  align-items: center;
  gap: 4px;
  border: 1px solid rgba(255, 255, 255, 0.3);
}
.angle-tile-status.is-error {
  color: var(--color-warning);
  border-color: var(--color-warning);
}
.angle-tile-status.is-recording {
  color: var(--color-danger);
  border-color: var(--color-danger);
}

.angle-tile-status-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--color-danger);
  animation: status-pulse 1.5s ease-in-out infinite;
}

@keyframes status-pulse {
  0%, 100% {
    opacity: 1;
  }
  50% {
    opacity: 0.3;
  }
}
.markers-badge-toggle {
  background: var(--color-brand-blue);
  cursor: pointer;
  position: relative;
  top: -2px;
  padding: 0.35em 0.75em;
  font-size: 0.8rem;
  border-radius: var(--radius-sm);
  clip-path: polygon(0 0, 100% 0, 100% 75%, 50% 100%, 0 75%);
  transition: clip-path 0.2s ease;
}
.markers-badge-toggle:hover {
  opacity: 0.9;
}
.markers-badge-toggle.is-expanded {
  clip-path: polygon(50% 0, 100% 25%, 100% 100%, 0 100%, 0 25%);
}

.marker-list {
  list-style: none;
  padding: 0;
}
.marker-list .box {
  display: inline-block;
  top: 1px;
  position: relative;
  width: 12px;
  height: 12px;
  border: 1px solid rgba(0, 0, 0, 0.2);
  margin-right: 0.2em;
  border-radius: 2px;
}
.marker-list .green {
  background: var(--color-success);
}
.marker-list .red {
  background: var(--color-danger);
}
.marker-list .blue {
  background: var(--color-info);
}
.marker-list .timecode-start,
.marker-list .timecode-end {
  font-family: "SF Mono", monospace;
  font-size: 0.9em;
  margin-right: 0.5em;
  color: var(--color-text-secondary);
}
.marker-list .name {
  font-weight: 600;
  margin-right: 0.5em;
}
.marker-list .color {
  display: inline-block;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  position: relative;
  top: 2px;
}
.marker-list .qualifier-list {
  margin-right: 0.5em;
}
.marker-list .note {
  color: var(--color-text-muted);
  font-style: italic;
}

.marker-schema {
  list-style: none;
  padding: 0;
}
.marker-schema li {
  padding: 1px 0;
}
.marker-schema li .p-3 {
  padding: 0.15rem var(--spacing-sm) !important;
}
.marker-schema li .rounded {
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  z-index: 2;
}
.marker-schema li .handle {
  cursor: grab;
  font-size: 1.2em;
  color: white;
  padding: 0 var(--spacing-sm);
  transition: color var(--transition-fast);
  line-height: 1;
}
.marker-schema li .handle:hover {
  color: var(--color-text-secondary);
}
.marker-schema li .handle:active {
  cursor: grabbing;
}
.marker-schema li .name {
  font-size: 1.1em;
  font-weight: 500;
}
.marker-schema li .delete, .marker-schema li .edit {
  font-size: 1.1em;
  color: var(--color-text-secondary);
  transition: color var(--transition-fast);
}
.marker-schema li .delete:hover, .marker-schema li .edit:hover {
  color: var(--color-text-primary);
}
.marker-schema li .marker {
  background: var(--color-bg-secondary);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  transition: transform var(--transition-normal), box-shadow var(--transition-normal), border-color var(--transition-normal);
}
.marker-schema li .marker:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
  border-color: var(--color-brand-blue);
}
.marker-schema li .marker {
  position: relative;
  width: 100%;
  padding: 0.2rem var(--spacing-sm);
  cursor: pointer;
}
.marker-schema li .marker-actions {
  position: relative;
  z-index: 2;
  display: flex;
  gap: var(--spacing-xs);
}
.marker-schema ~ .btn:last-of-type {
  margin-bottom: var(--spacing-2xl);
}

.marker-schema-widget {
  margin-bottom: var(--spacing-xl);
}

.marker-schema-widget-title {
  font-size: 1.4rem;
}

.marker-schema-widget-content {
  margin-top: var(--spacing-sm);
}

.marker-schema-canvas {
  margin-bottom: var(--spacing-md);
}

#marker-schema-layout-toggle {
  border: none;
  background: transparent;
}

.marker-schema-list .schema-card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: var(--spacing-md);
}
.marker-schema-list .schema-card {
  background: var(--color-bg-secondary);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  transition: transform var(--transition-normal), box-shadow var(--transition-normal), border-color var(--transition-normal);
}
.marker-schema-list .schema-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
  border-color: var(--color-brand-blue);
}
.marker-schema-list .schema-card {
  background: var(--color-bg-elevated);
  padding: var(--spacing-md);
  padding-bottom: var(--spacing-xl);
  padding-left: calc(var(--spacing-md) + 6px);
  position: relative;
  cursor: pointer;
  min-height: 80px;
  overflow: hidden;
}
.marker-schema-list .schema-card-accent {
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 8px;
  z-index: 1;
  pointer-events: none;
}
.marker-schema-list .schema-card-name {
  font-weight: 600;
  font-size: 1.1rem;
  color: var(--color-text-primary);
  pointer-events: none;
}
.marker-schema-list .schema-card-org {
  margin-top: var(--spacing-xs);
  opacity: 0.8;
  pointer-events: none;
}

.qualifier-schema {
  list-style: none;
  padding: 0;
}
.qualifier-schema li {
  padding: 1px 0;
}
.qualifier-schema li .p-2 {
  padding: 0.15rem var(--spacing-sm) !important;
}
.qualifier-schema li .rounded {
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  z-index: 2;
}
.qualifier-schema li .handle {
  cursor: grab;
  font-size: 1.2em;
  color: white;
  padding: 0 var(--spacing-sm);
  transition: color var(--transition-fast);
  line-height: 1;
}
.qualifier-schema li .handle:hover {
  color: var(--color-text-secondary);
}
.qualifier-schema li .handle:active {
  cursor: grabbing;
}
.qualifier-schema li .name {
  font-size: 1.1em;
  font-weight: 500;
}
.qualifier-schema li .delete, .qualifier-schema li .edit {
  font-size: 1.1em;
  color: var(--color-text-secondary);
  transition: color var(--transition-fast);
}
.qualifier-schema li .delete:hover, .qualifier-schema li .edit:hover {
  color: var(--color-text-primary);
}
.qualifier-schema li .marker {
  background: var(--color-bg-secondary);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  transition: transform var(--transition-normal), box-shadow var(--transition-normal), border-color var(--transition-normal);
}
.qualifier-schema li .marker:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
  border-color: var(--color-brand-blue);
}
.qualifier-schema li .marker {
  position: relative;
  width: 100%;
  padding: 0.2rem var(--spacing-sm);
  cursor: pointer;
}
.qualifier-schema li .marker-actions {
  position: relative;
  z-index: 2;
  display: flex;
  gap: var(--spacing-xs);
}
.qualifier-schema ~ .btn:last-of-type {
  margin-bottom: var(--spacing-2xl);
}

.qualifier-schema-list .schema-card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: var(--spacing-md);
}
.qualifier-schema-list .schema-card {
  background: var(--color-bg-secondary);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  transition: transform var(--transition-normal), box-shadow var(--transition-normal), border-color var(--transition-normal);
}
.qualifier-schema-list .schema-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
  border-color: var(--color-brand-blue);
}
.qualifier-schema-list .schema-card {
  background: var(--color-bg-elevated);
  padding: var(--spacing-md);
  padding-bottom: var(--spacing-xl);
  padding-left: calc(var(--spacing-md) + 6px);
  position: relative;
  cursor: pointer;
  min-height: 80px;
  overflow: hidden;
}
.qualifier-schema-list .schema-card-accent {
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 8px;
  z-index: 1;
  pointer-events: none;
}
.qualifier-schema-list .schema-card-name {
  font-weight: 600;
  font-size: 1.1rem;
  color: var(--color-text-primary);
  pointer-events: none;
}
.qualifier-schema-list .schema-card-org {
  margin-top: var(--spacing-xs);
  opacity: 0.8;
  pointer-events: none;
}

.multiselect-selected-text {
  float: left;
}

.linked-qualifier-lists {
  list-style: none;
  padding: 0;
}
.linked-qualifier-lists li .handle {
  cursor: grab;
  color: var(--color-text-muted);
  transition: color var(--transition-fast);
}
.linked-qualifier-lists li .handle:hover {
  color: var(--color-text-secondary);
}
.linked-qualifier-lists li .handle:active {
  cursor: grabbing;
}
.linked-qualifier-lists li .linked-qualifier-list {
  background: var(--color-bg-secondary);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  transition: transform var(--transition-normal), box-shadow var(--transition-normal), border-color var(--transition-normal);
}
.linked-qualifier-lists li .linked-qualifier-list:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
  border-color: var(--color-brand-blue);
}
.linked-qualifier-lists li .linked-qualifier-list {
  background: var(--color-bg-elevated);
  padding: var(--spacing-md);
}

.cp-color-picker {
  z-index: 2000;
}

.number-spinner {
  display: flex;
  align-items: center;
}
.number-spinner input.form-control {
  text-align: center;
  border-radius: 0;
  border-left: none;
  border-right: none;
  -moz-appearance: textfield;
}
.number-spinner input.form-control::-webkit-outer-spin-button, .number-spinner input.form-control::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

.number-spinner-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  min-width: 36px;
  height: 38px;
  padding: 0;
  border: 1px solid var(--color-border);
  background: var(--color-bg-secondary);
  color: var(--color-brand-blue);
  cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease;
  font-size: 0.7rem;
}
.number-spinner-btn:hover {
  background: var(--color-bg-hover);
  color: #fff;
}
.number-spinner-btn:active {
  background: var(--color-brand-blue);
  color: #fff;
}
.number-spinner-btn.number-spinner-down {
  border-radius: var(--radius-sm) 0 0 var(--radius-sm);
}
.number-spinner-btn.number-spinner-up {
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
}

#csp-progress-bar {
  background-color: var(--color-brand-blue) !important;
}

.number-spinner-sm .number-spinner-btn {
  width: 28px;
  min-width: 28px;
  height: auto;
  align-self: stretch;
  font-size: 0.6rem;
}
.number-spinner-sm input.form-control {
  width: 52px;
  text-align: center;
}

.clr-picker {
  z-index: 1060;
  background: var(--color-bg-elevated);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4);
}

.clr-picker .clr-gradient {
  border-radius: var(--radius-sm);
}

.clr-picker .clr-hue,
.clr-picker .clr-alpha {
  border-radius: 4px;
}

.clr-picker .clr-swatches button {
  border-radius: 50%;
  border: none;
  transition: transform 0.15s ease;
}
.clr-picker .clr-swatches button:hover {
  transform: scale(1.25);
}

.clr-picker input.clr-color {
  background: var(--color-bg-secondary);
  color: var(--color-text-primary);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
}
.clr-picker input.clr-color:focus {
  border-color: var(--color-brand-blue);
  outline: none;
}

.clr-picker .clr-clear {
  background: var(--color-bg-hover);
  color: var(--color-text-secondary);
  border-radius: var(--radius-sm);
}
.clr-picker .clr-clear:hover {
  background: var(--color-brand-blue);
  color: #fff;
}

.clr-field {
  display: block;
  margin-top: 0.25rem;
}

.clr-field button {
  width: 38px;
  border-radius: var(--radius-sm);
  pointer-events: auto;
  cursor: pointer;
  outline: none;
  background-image: none;
  border: 1px solid var(--color-border);
  z-index: 1;
}

.clr-field:has(input:disabled) button {
  pointer-events: none;
  cursor: default;
}

.clr-field button::after {
  border-radius: inherit;
  box-shadow: none;
}

.settings section {
  width: 100%;
}

span.filesize {
  font-weight: 600;
  color: var(--color-text-secondary);
}

span.licence {
  font-weight: 600;
}

span.licence_red {
  color: var(--color-danger);
  font-weight: 600;
}

span.licence_amber {
  color: var(--color-warning);
  font-weight: 600;
}

.tiny-button {
  padding: 0.15rem 0.25rem;
  font-size: 0.65rem;
  border-radius: var(--radius-sm);
}

.alert {
  border-radius: var(--radius-md);
  border: 1px solid transparent;
}

.alert-danger {
  background-color: rgba(239, 68, 68, 0.15);
  border-color: rgba(239, 68, 68, 0.3);
  color: #fca5a5;
}

.alert-success {
  background-color: rgba(34, 197, 94, 0.15);
  border-color: rgba(34, 197, 94, 0.3);
  color: #86efac;
}

.alert-warning {
  background-color: rgba(245, 158, 11, 0.15);
  border-color: rgba(245, 158, 11, 0.3);
  color: #fcd34d;
}

.alert-info {
  background-color: rgba(59, 130, 246, 0.15);
  border-color: rgba(59, 130, 246, 0.3);
  color: #93c5fd;
}

.alert-dark {
  background-color: var(--color-bg-secondary);
  border-color: var(--color-border);
  color: var(--color-text-secondary);
}

.table {
  color: var(--color-text-primary);
  border-color: var(--color-border);
  --bs-table-bg: transparent;
  --bs-table-color: var(--color-text-primary);
  --bs-table-striped-bg: var(--color-bg-hover);
  --bs-table-hover-bg: var(--color-bg-hover);
}
.table th {
  color: var(--color-text-secondary);
  font-weight: 600;
  border-color: var(--color-border);
  background-color: transparent;
}
.table td {
  border-color: var(--color-border);
  background-color: transparent;
  color: var(--color-text-secondary);
}
.table tbody tr:hover {
  background-color: var(--color-bg-hover);
}
.table.table-dark {
  --bs-table-bg: transparent;
  --bs-table-color: var(--color-text-primary);
  --bs-table-border-color: var(--color-border);
}

.modal-content {
  background-color: var(--color-bg-secondary);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
}

.modal-header {
  border-bottom-color: var(--color-border);
}
.modal-header .btn-close {
  filter: invert(1);
}

.modal-footer {
  border-top-color: var(--color-border);
}

.form-control {
  background-color: var(--color-bg-secondary) !important;
}

.form-control:-webkit-autofill,
.form-control:-webkit-autofill:hover,
.form-control:-webkit-autofill:focus {
  -webkit-box-shadow: 0 0 0 1000px var(--color-bg-secondary) inset !important;
  -webkit-text-fill-color: var(--color-text-primary) !important;
  caret-color: var(--color-text-primary);
}

.card {
  background-color: var(--color-bg-secondary);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
}

.centered-box {
  background-color: var(--color-bg-secondary);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
  padding: var(--spacing-xl);
  border-radius: var(--radius-lg);
  border: 1px solid var(--color-border);
  box-shadow: var(--shadow-lg);
  color: var(--color-text-secondary);
}
.centered-box h1, .centered-box h2, .centered-box h3, .centered-box h4, .centered-box h5, .centered-box h6 {
  color: var(--color-text-primary);
}

.danger-menu-item:hover, .danger-menu-item:focus {
  background-color: var(--color-danger) !important;
  color: white !important;
}

.success-menu-item:hover {
  background-color: var(--color-brand-blue);
  color: white;
}

.angle-amplify-badge {
  position: absolute;
  top: 8px;
  right: 8px;
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 2px 8px;
  border-radius: var(--radius-sm);
  background: rgba(1, 12, 28, 0.75);
  border: 1px solid rgba(255, 255, 255, 0.15);
  color: var(--color-text-primary);
  font-size: 0.7rem;
  font-weight: 600;
  pointer-events: auto;
  z-index: 2;
}
.angle-amplify-badge.is-hidden {
  display: none;
}
.angle-amplify-badge.is-uploading {
  border-color: var(--color-brand-blue);
  color: var(--color-brand-blue);
}
.angle-amplify-badge .amplify-mask-icon {
  width: 0.9em;
  height: 0.9em;
  vertical-align: 0;
}

.angle-s3-badge {
  top: 34px;
}
.angle-s3-badge i {
  font-size: 0.8em;
}

#app-alert-stack {
  position: fixed;
  top: 72px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 2000;
  width: min(560px, 100vw - 32px);
}
#app-alert-stack .alert {
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.45);
  margin-bottom: 8px;
}

.afp {
  position: relative;
}
.afp .afp-control {
  cursor: pointer;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.afp .afp-path {
  color: var(--color-text-muted);
}
.afp .afp-shared {
  color: var(--color-brand-blue);
  font-size: 0.85em;
  margin-left: 0.35em;
}
.afp .afp-panel {
  position: absolute;
  z-index: 1080;
  top: calc(100% + 4px);
  left: 0;
  min-width: 320px;
  max-width: 420px;
  background: var(--color-bg-elevated);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.45);
  padding: 8px;
}
.afp .afp-tree {
  max-height: 260px;
  overflow-y: auto;
  margin-top: 8px;
}
.afp .afp-row {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 4px 6px;
  border-radius: var(--radius-sm);
  cursor: pointer;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.afp .afp-row:hover {
  background: var(--color-bg-hover);
}
.afp .afp-row.afp-selected {
  background: rgba(57, 179, 234, 0.18);
}
.afp .afp-toggle {
  width: 1.1em;
  text-align: center;
  color: var(--color-text-muted);
  flex: 0 0 auto;
}
.afp .afp-toggle:hover {
  color: var(--color-brand-blue);
}
.afp .afp-icon {
  color: var(--color-brand-blue);
  flex: 0 0 auto;
}
.afp .afp-delete {
  margin-left: auto;
  flex: 0 0 auto;
  color: var(--color-text-muted);
  visibility: hidden;
  padding: 0 4px;
}
.afp .afp-delete:hover {
  color: var(--bs-danger, #dc3545);
}
.afp .afp-row:hover .afp-delete {
  visibility: visible;
}
.afp .afp-empty {
  padding: 6px;
}
.afp .afp-footer {
  margin-top: 8px;
}
.afp .afp-note, .afp .afp-error {
  margin-top: 6px;
}

/* Session title line: name, live timer, scoreboard badge, Angles Sync chip
   and the edit pencil sit on ONE centre line (they mixed baseline and
   middle alignment, so the chip floated below the timer). */
.session-title h1 {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  row-gap: 0.25rem;
}

.live-session-timer {
  color: var(--color-brand-blue);
  font-size: 0.55em;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  vertical-align: middle;
  white-space: nowrap;
}

/* Optical tweak: in the title row the small tabular digits read a little
   high against Gilroy's baseline — sit them down a touch. Tune here. */
.session-title h1 .live-session-timer {
  position: relative;
  top: 0.12em;
}

.amplify-mask-icon {
  display: inline-block;
  width: 1.25em;
  height: 1em;
  vertical-align: -0.125em;
  background-color: currentColor;
  -webkit-mask: url("/images/amplify-white-icon.svg") no-repeat center/contain;
  mask: url("/images/amplify-white-icon.svg") no-repeat center/contain;
}

.amplify-menu-icon {
  width: 1.25em;
  height: 1em;
  object-fit: contain;
  vertical-align: -0.125em;
}

.clock {
  font-family: "SF Mono", monospace;
  font-size: 0.9em;
  color: var(--color-text-secondary);
  line-height: inherit;
  display: flex;
  align-items: center;
  white-space: nowrap;
}

.clock-tz-mismatch, .nav-link.clock-tz-mismatch {
  background: rgba(245, 158, 11, 0.15);
  border: 1px solid rgba(245, 158, 11, 0.4);
  color: var(--color-warning);
  border-radius: var(--radius-sm);
  padding: 0.15rem 0.5rem;
}

.caption {
  display: block;
  font-size: 0.75rem;
  padding: 0;
  color: var(--color-text-muted);
}

.select-camera-list {
  column-count: 2;
  column-gap: var(--spacing-md);
  list-style-type: none;
  padding: 0 !important;
  margin: 0;
}
.select-camera-list li {
  padding: var(--spacing-sm) 0;
  break-inside: avoid;
}
.select-camera-list .form-check {
  padding-left: 0;
  margin-bottom: 0;
}
.select-camera-list .form-check-input {
  margin-left: 0;
  margin-right: var(--spacing-sm);
  float: none;
}

.ffmpeg-cli {
  width: 100%;
  margin-bottom: var(--spacing-sm);
}
.ffmpeg-cli .card {
  background-color: var(--color-bg-elevated);
  border-color: var(--color-border);
}
.ffmpeg-cli .card-body {
  padding: var(--spacing-md);
}
.ffmpeg-cli p {
  color: var(--color-text-muted);
  font-size: 0.9rem;
  margin-bottom: var(--spacing-sm);
}

.video-modal .modal-dialog {
  max-width: 640px;
  margin: 1.75rem auto;
  display: flex;
  align-items: center;
  min-height: calc(100% - 3.5rem);
}
.video-modal .close-container {
  overflow: hidden;
  text-align: right;
  margin-bottom: var(--spacing-xs);
}
.video-modal .modal-content {
  background: transparent;
  border: none;
}
.video-modal video {
  background: black;
  border-radius: var(--radius-md);
  width: 100%;
  max-height: 80vh;
}

#play-all-modal .modal-content {
  max-height: 100vh;
}
#play-all-modal .modal-body {
  display: flex;
  flex-direction: column;
  padding: var(--spacing-sm);
  overflow: hidden;
}

.sync-controls {
  display: flex;
  align-items: center;
  gap: var(--spacing-md);
  padding: var(--spacing-md);
  background: var(--color-bg-tertiary);
  border-radius: var(--radius-md);
  margin-bottom: var(--spacing-sm);
  flex-shrink: 0;
}
.sync-controls #sync-play-pause,
.sync-controls #sync-mute {
  width: 50px;
  height: 50px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.sync-controls #sync-play-pause i,
.sync-controls #sync-mute i {
  font-size: 1.2rem;
}
.sync-controls .sync-time-display {
  font-family: monospace;
  font-size: 0.9rem;
  color: var(--color-text-muted);
  white-space: nowrap;
  min-width: 140px;
}
.sync-controls .sync-scrubber-container {
  flex: 1;
  display: flex;
  align-items: center;
}
.sync-controls .sync-scrubber {
  width: 100%;
  height: 6px;
  -webkit-appearance: none;
  appearance: none;
  background: rgba(255, 255, 255, 0.15);
  border-radius: 3px;
  cursor: pointer;
  border: 1px solid rgba(255, 255, 255, 0.1);
}
.sync-controls .sync-scrubber::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 16px;
  height: 16px;
  background: var(--color-brand);
  border-radius: 50%;
  border: 1px solid white;
  cursor: pointer;
  transition: transform var(--transition-fast);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.3);
  margin-top: -5px;
}
.sync-controls .sync-scrubber::-webkit-slider-thumb:hover {
  transform: scale(1.2);
}
.sync-controls .sync-scrubber::-moz-range-thumb {
  width: 16px;
  height: 16px;
  background: var(--color-brand);
  border-radius: 50%;
  border: 1px solid white;
  cursor: pointer;
  transition: transform var(--transition-fast);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.3);
}
.sync-controls .sync-scrubber::-moz-range-thumb:hover {
  transform: scale(1.2);
}
.sync-controls .sync-scrubber::-webkit-slider-runnable-track {
  height: 6px;
  border-radius: 3px;
}
.sync-controls .sync-scrubber::-moz-range-track {
  height: 6px;
  background: rgba(255, 255, 255, 0.15);
  border-radius: 3px;
  border: 1px solid rgba(255, 255, 255, 0.1);
}
.sync-controls .wall-pagination {
  display: flex;
  align-items: center;
  gap: var(--spacing-sm);
  margin-left: auto;
}
.sync-controls .wall-pagination .btn {
  width: 32px;
  height: 32px;
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}
.sync-controls .wall-pagination #wall-page-indicator {
  font-size: 0.85rem;
  color: var(--color-text-muted);
  white-space: nowrap;
}

.play-all-grid {
  display: grid;
  grid-template-columns: repeat(var(--wall-cols, 4), 1fr);
  align-content: start;
  gap: 2px;
  background: #000;
  border-radius: var(--radius-md);
  overflow: hidden;
  max-height: 100%;
  overflow-y: auto;
}
@media (max-width: 480px) {
  .play-all-grid {
    grid-template-columns: 1fr !important;
  }
}

.play-all-item {
  position: relative;
  overflow: hidden;
  display: none;
}
.play-all-item.wall-visible {
  display: block;
}
.play-all-item video {
  width: 100%;
  display: block;
  background: #000;
  aspect-ratio: 16/9;
}
.play-all-item video::-webkit-media-controls {
  opacity: 0;
  transition: opacity 200ms;
}
.play-all-item:hover video::-webkit-media-controls {
  opacity: 1;
}
.play-all-item .wall-overlay {
  position: absolute;
  inset: 0;
  opacity: 0;
  transition: opacity 200ms ease;
  pointer-events: none;
  background: linear-gradient(to bottom, rgba(0, 0, 0, 0.6) 0%, transparent 40%);
}
.play-all-item:hover .wall-overlay {
  opacity: 1;
}
.play-all-item .angle-name {
  position: absolute;
  top: 6px;
  right: 8px;
  font-size: 0.75rem;
  color: white;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.8);
}

.bg-piston {
  background-image: url(/images/piston-icon-400x400.png);
  background-size: contain;
  background-position: center;
  text-align: center;
  width: 400px;
  height: 400px;
  background-repeat: no-repeat;
}

.input-group-text {
  background-color: var(--color-bg-secondary);
  border: 1px solid var(--color-border);
  color: var(--color-text-secondary);
}

.input-group-text[data-td-toggle=datetimepicker] {
  color: var(--color-text-muted);
  cursor: pointer;
  transition: background-color var(--transition-fast), color var(--transition-fast);
}
.input-group-text[data-td-toggle=datetimepicker]:hover {
  background-color: var(--color-brand-blue);
  color: white;
}

.bootstrap-datetimepicker-widget {
  background-color: var(--color-bg-elevated);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
}
.bootstrap-datetimepicker-widget table {
  color: var(--color-text-primary);
}
.bootstrap-datetimepicker-widget table td.day {
  border-radius: var(--radius-sm);
  transition: background-color var(--transition-fast);
}
.bootstrap-datetimepicker-widget table td.day:hover {
  background-color: var(--color-brand-blue);
}
.bootstrap-datetimepicker-widget table td.active {
  background-color: var(--color-brand-blue);
}
.bootstrap-datetimepicker-widget table td.active:hover {
  background-color: var(--color-brand-blue-dark);
}
.bootstrap-datetimepicker-widget table span:hover {
  background: var(--color-brand-blue);
  border-radius: var(--radius-sm);
}
.bootstrap-datetimepicker-widget table span.month.active {
  background-color: var(--color-brand-blue);
}
.bootstrap-datetimepicker-widget table th:hover {
  background: var(--color-bg-hover);
  border-radius: var(--radius-sm);
}

::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}

::-webkit-scrollbar-track {
  background: var(--color-bg-primary);
}

::-webkit-scrollbar-thumb {
  background: var(--color-bg-hover);
  border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
  background: var(--color-text-muted);
}

::selection {
  background-color: rgba(84, 85, 255, 0.3);
  color: var(--color-text-primary);
}

.toggle-pills {
  display: flex;
  flex-wrap: wrap;
  gap: var(--spacing-xs);
}
.toggle-pills.toggle-pills-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
}
.toggle-pills .toggle-pill {
  position: relative;
  cursor: pointer;
  user-select: none;
  margin-bottom: 0;
}
.toggle-pills .toggle-pill input[type=checkbox],
.toggle-pills .toggle-pill input[type=radio] {
  position: absolute;
  opacity: 0;
  width: 0;
  height: 0;
}
.toggle-pills .toggle-pill .pill-label {
  display: inline-block;
  padding: var(--spacing-xs) var(--spacing-sm);
  font-size: 0.85rem;
  font-weight: 500;
  border-radius: var(--radius-xl);
  border: 1px solid var(--color-border);
  background-color: var(--color-bg-elevated);
  color: var(--color-text-secondary);
  transition: all var(--transition-fast);
}
.toggle-pills .toggle-pill .pill-label:hover {
  border-color: var(--color-border-hover);
  color: var(--color-text-primary);
}
.toggle-pills .toggle-pill[style*="--pill-gradient"] input[type=checkbox]:not(:checked) + .pill-label:hover, .toggle-pills .toggle-pill[style*="--pill-gradient"] input[type=radio]:not(:checked) + .pill-label:hover {
  background: linear-gradient(rgba(0, 0, 0, 0.4), rgba(0, 0, 0, 0.4)), var(--pill-gradient);
  background-clip: padding-box;
  border-color: transparent;
  color: white;
}
.toggle-pills .toggle-pill input[type=checkbox]:checked + .pill-label,
.toggle-pills .toggle-pill input[type=radio]:checked + .pill-label {
  background-color: var(--color-brand);
  border-color: var(--color-brand);
  color: white;
}
.toggle-pills .toggle-pill.org-pill input[type=checkbox]:checked + .pill-label, .toggle-pills .toggle-pill.org-pill input[type=radio]:checked + .pill-label {
  background: var(--pill-gradient);
  background-clip: padding-box;
  border-color: transparent;
}
.toggle-pills .toggle-pill.camera-group-pill input[type=checkbox]:checked + .pill-label, .toggle-pills .toggle-pill.camera-pill input[type=checkbox]:checked + .pill-label, .toggle-pills .toggle-pill.publishing-pill input[type=checkbox]:checked + .pill-label, .toggle-pills .toggle-pill.user-pill input[type=checkbox]:checked + .pill-label {
  background: var(--pill-gradient);
  background-clip: padding-box;
  border-color: transparent;
  color: white;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}
.toggle-pills .toggle-pill.schema-pill input[type=checkbox]:checked + .pill-label, .toggle-pills .toggle-pill.schema-pill input[type=radio]:checked + .pill-label {
  background: var(--pill-gradient);
  background-clip: padding-box;
  border-color: transparent;
}
.toggle-pills .toggle-pill input[type=checkbox]:focus + .pill-label,
.toggle-pills .toggle-pill input[type=radio]:focus + .pill-label {
  box-shadow: 0 0 0 2px rgba(57, 179, 234, 0.3);
}
.toggle-pills .toggle-pill.pill-disabled {
  cursor: not-allowed;
}
.toggle-pills .toggle-pill.pill-disabled .pill-label {
  opacity: 0.7;
}
.toggle-pills .toggle-pill.pill-disabled input:disabled:checked + .pill-label {
  background-color: var(--color-brand);
  border-color: var(--color-brand);
  color: white;
}
.toggle-pills .toggle-pill.pill-mw-signal input:not(:checked) + .pill-label {
  border-color: var(--color-success);
}
.toggle-pills .toggle-pill.pill-mw-blocked input:not(:checked) + .pill-label {
  border-color: var(--color-warning);
  position: relative;
  overflow: hidden;
}
.toggle-pills .toggle-pill.pill-mw-blocked input:not(:checked) + .pill-label::after {
  content: "";
  position: absolute;
  inset: 0;
  background: repeating-linear-gradient(-45deg, transparent, transparent 4px, rgba(245, 158, 11, 0.12) 4px, rgba(245, 158, 11, 0.12) 8px);
  border-radius: inherit;
  pointer-events: none;
}

.toggle-pills .toggle-pill.pill-display .pill-label {
  background: var(--pill-gradient);
  background-clip: padding-box;
  border-color: transparent;
  color: white;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
  cursor: default;
}

.toggle-pills .toggle-pill.camera-pill .pill-label,
.toggle-pills .toggle-pill.schema-pill .pill-label,
.toggle-pills .toggle-pill.camera-group-pill .pill-label {
  position: relative;
  padding-left: calc(var(--spacing-sm) + 4px);
  overflow: hidden;
}
.toggle-pills .toggle-pill.camera-pill input:not(:checked) + .pill-label::before,
.toggle-pills .toggle-pill.camera-pill .pill-label:only-child::before,
.toggle-pills .toggle-pill.schema-pill input:not(:checked) + .pill-label::before,
.toggle-pills .toggle-pill.schema-pill .pill-label:only-child::before,
.toggle-pills .toggle-pill.camera-group-pill input:not(:checked) + .pill-label::before,
.toggle-pills .toggle-pill.camera-group-pill .pill-label:only-child::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 8px;
  background: var(--pill-gradient);
  border-radius: var(--radius-xl) 0 0 var(--radius-xl);
  opacity: 0.85;
}
.toggle-pills .toggle-pill.camera-pill input:not(:checked) + .pill-label:hover::before,
.toggle-pills .toggle-pill.camera-pill .pill-label:only-child:hover::before,
.toggle-pills .toggle-pill.schema-pill input:not(:checked) + .pill-label:hover::before,
.toggle-pills .toggle-pill.schema-pill .pill-label:only-child:hover::before,
.toggle-pills .toggle-pill.camera-group-pill input:not(:checked) + .pill-label:hover::before,
.toggle-pills .toggle-pill.camera-group-pill .pill-label:only-child:hover::before {
  opacity: 1;
}

.cam-grouped-list,
#session-camera-list {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--spacing-xs);
}
.cam-grouped-list .toggle-pill,
#session-camera-list .toggle-pill {
  width: 100%;
}
.cam-grouped-list .toggle-pill .pill-label,
#session-camera-list .toggle-pill .pill-label {
  display: block;
  text-align: left;
}
.cam-grouped-list .cam-group-header,
#session-camera-list .cam-group-header {
  grid-column: 1/-1;
  width: 100%;
  font-size: 0.7rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--color-brand-blue);
  padding: var(--spacing-sm) 0 var(--spacing-xs);
  border-bottom: 1px solid var(--color-border);
  margin-bottom: var(--spacing-sm);
}
.cam-grouped-list .cam-group-header:not(:first-child),
#session-camera-list .cam-group-header:not(:first-child) {
  margin-top: var(--spacing-sm);
}
.cam-grouped-list .cam-group-pills,
#session-camera-list .cam-group-pills {
  grid-column: 1/-1;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--spacing-xs);
  width: 100%;
}

.schema-pills-grouped {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--spacing-xs);
}
.schema-pills-grouped .toggle-pill {
  width: 100%;
}
.schema-pills-grouped .toggle-pill .pill-label {
  display: block;
  text-align: left;
}
.schema-pills-grouped > .toggle-pill {
  grid-column: 1/-1;
  margin-bottom: var(--spacing-sm);
}
.schema-pills-grouped .schema-group-header {
  grid-column: 1/-1;
  width: 100%;
  font-size: 0.7rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--color-brand-blue);
  padding: var(--spacing-sm) 0 var(--spacing-xs);
  border-bottom: 1px solid var(--color-border);
  margin-bottom: var(--spacing-sm);
}
.schema-pills-grouped .schema-group-header:not(:first-child) {
  margin-top: var(--spacing-sm);
}
.schema-pills-grouped .schema-group-pills {
  grid-column: 1/-1;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--spacing-xs);
  width: 100%;
}

.share-org-schema-section,
.share-org-camera-section {
  padding-bottom: var(--spacing-md);
  margin-bottom: var(--spacing-sm);
  border-bottom: 1px solid var(--color-border);
}
.share-org-schema-section:last-child,
.share-org-camera-section:last-child {
  border-bottom: none;
  margin-bottom: 0;
  padding-bottom: 0;
}

.share-org-header {
  display: flex;
  align-items: center;
  gap: var(--spacing-xs);
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--color-text-primary);
  margin-top: var(--spacing-md);
}

.share-org-schema-header {
  font-size: 0.7rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--color-text-secondary);
  padding: var(--spacing-sm) 0 var(--spacing-xs);
  margin-bottom: var(--spacing-sm);
}

.avatar-toggles {
  display: flex;
  flex-wrap: wrap;
  gap: var(--spacing-sm);
}
.avatar-toggles .avatar-toggle {
  position: relative;
  cursor: pointer;
  user-select: none;
}
.avatar-toggles .avatar-toggle input[type=checkbox],
.avatar-toggles .avatar-toggle input[type=radio] {
  position: absolute;
  opacity: 0;
  width: 0;
  height: 0;
}
.avatar-toggles .avatar-toggle .avatar-label {
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  opacity: 0.4;
  filter: grayscale(0.5);
  transition: all var(--transition-fast);
  border: 2px solid transparent;
}
.avatar-toggles .avatar-toggle .avatar-label:hover {
  opacity: 1;
  filter: grayscale(0);
}
.avatar-toggles .avatar-toggle input[type=checkbox]:checked + .avatar-label,
.avatar-toggles .avatar-toggle input[type=radio]:checked + .avatar-label {
  opacity: 1;
  filter: grayscale(0);
}
.avatar-toggles .avatar-toggle input[type=checkbox]:focus + .avatar-label,
.avatar-toggles .avatar-toggle input[type=radio]:focus + .avatar-label {
  box-shadow: 0 0 0 2px rgba(57, 179, 234, 0.3);
}

.display-pills {
  display: flex;
  flex-wrap: wrap;
  gap: var(--spacing-xs);
}
.display-pills .display-pill {
  display: inline-block;
  padding: var(--spacing-xs) var(--spacing-sm);
  font-size: 0.85rem;
  font-weight: 500;
  border-radius: var(--radius-xl);
  border: 1px solid var(--color-border);
  background-color: var(--color-bg-elevated);
  color: var(--color-text-muted);
}

.display-avatars {
  display: flex;
  flex-wrap: wrap;
  gap: var(--spacing-xs);
}
.display-avatars .display-avatar {
  position: relative;
  z-index: 1;
}
.display-avatars .display-avatar svg {
  display: block;
  border-radius: var(--radius-sm);
}

.avatar-cycler {
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
  border-radius: var(--radius-md);
  position: relative;
}
.avatar-cycler:hover {
  transform: scale(1.05);
  box-shadow: 0 0 12px rgba(57, 179, 234, 0.4);
}
.avatar-cycler:active {
  transform: scale(0.95);
}
.avatar-cycler svg {
  display: block;
  border-radius: var(--radius-md);
}
.avatar-cycler .cycler-hint-up,
.avatar-cycler .cycler-hint-down {
  position: absolute;
  left: 0;
  right: 0;
  height: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 0.15s ease;
  pointer-events: none;
  z-index: 5;
  font-size: 0.7rem;
  color: white;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.8);
}
.avatar-cycler .cycler-hint-up {
  top: 0;
  border-radius: var(--radius-md) var(--radius-md) 0 0;
}
.avatar-cycler .cycler-hint-down {
  bottom: 0;
  border-radius: 0 0 var(--radius-md) var(--radius-md);
}
.avatar-cycler:hover .cycler-hint-up, .avatar-cycler:hover .cycler-hint-down {
  opacity: 0.8;
}
.avatar-cycler .color-index-indicator {
  position: absolute;
  top: -8px;
  left: 50%;
  transform: translateX(-50%);
  font-size: 1.2rem;
  font-weight: 700;
  color: white;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.8), 0 0 8px rgba(0, 0, 0, 0.6);
  pointer-events: none;
  animation: colorIndexFlash 0.8s ease-out forwards;
  z-index: 10;
}

@keyframes colorIndexFlash {
  0% {
    opacity: 1;
    transform: translateX(-50%) scale(1.5);
  }
  30% {
    opacity: 1;
    transform: translateX(-50%) scale(1);
  }
  100% {
    opacity: 0;
    transform: translateX(-50%) scale(0.8);
  }
}
.update-progress {
  width: 100%;
  height: 8px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: var(--radius-md);
  overflow: hidden;
  margin-top: var(--spacing-lg);
  box-shadow: 0 0 20px rgba(57, 179, 234, 0.3);
}

.progress-bar-success {
  background-color: var(--color-success);
}

.update-progress-bar {
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, #39B3EA 0%, #6DD5FA 25%, #39B3EA 50%, #2980B9 75%, #39B3EA 100%);
  background-size: 200% 100%;
  border-radius: var(--radius-md);
  animation: progress-glow 2s ease-in-out infinite;
  box-shadow: 0 0 10px rgba(57, 179, 234, 0.5), 0 0 20px rgba(57, 179, 234, 0.3), inset 0 1px 0 rgba(255, 255, 255, 0.2);
}

@keyframes progress-glow {
  0% {
    background-position: 200% 0;
    box-shadow: 0 0 10px rgba(57, 179, 234, 0.5), 0 0 20px rgba(57, 179, 234, 0.3);
  }
  50% {
    box-shadow: 0 0 15px rgba(57, 179, 234, 0.7), 0 0 30px rgba(57, 179, 234, 0.5);
  }
  100% {
    background-position: 0 0;
    box-shadow: 0 0 10px rgba(57, 179, 234, 0.5), 0 0 20px rgba(57, 179, 234, 0.3);
  }
}
.disk-progress {
  margin-top: 0.35rem;
  width: 100%;
  height: 24px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.2);
}

.disk-progress-bar {
  height: 100%;
  min-width: 60px;
  background: linear-gradient(90deg, #2980B9 0%, #39B3EA 50%, #6DD5FA 100%);
  border-radius: var(--radius-md);
  box-shadow: 0 0 10px rgba(57, 179, 234, 0.5), 0 0 20px rgba(57, 179, 234, 0.3), inset 0 1px 0 rgba(255, 255, 255, 0.2);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: width 0.5s ease;
}

.disk-progress-text {
  font-size: 0.75rem;
  font-weight: 600;
  color: white;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}

.disk-progress-danger {
  background: linear-gradient(90deg, #a71d2a 0%, #dc3545 50%, #f17c85 100%);
  box-shadow: 0 0 10px rgba(220, 53, 69, 0.5), 0 0 20px rgba(220, 53, 69, 0.3), inset 0 1px 0 rgba(255, 255, 255, 0.2);
}

.disk-op-progress {
  border-radius: var(--radius-md);
  overflow: hidden;
  background: rgba(0, 0, 0, 0.25);
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.disk-op-progress-bar {
  height: 4px;
  background: linear-gradient(90deg, #39B3EA 0%, #6DD5FA 25%, #39B3EA 50%, #2980B9 75%, #39B3EA 100%);
  background-size: 200% 100%;
  animation: progress-glow 2s ease-in-out infinite;
}

.disk-op-progress-log {
  padding: var(--spacing-sm) var(--spacing-md);
  font-family: "SF Mono", "Fira Code", "Consolas", monospace;
  font-size: 0.8rem;
  line-height: 1.5;
  color: var(--color-text-secondary);
  white-space: pre-wrap;
  word-break: break-word;
  min-height: 2.4em;
}

.device-paths-list {
  display: flex;
  flex-direction: column;
  gap: var(--spacing-sm);
}

.device-path-item {
  background: var(--color-bg-secondary);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  transition: transform var(--transition-normal), box-shadow var(--transition-normal), border-color var(--transition-normal);
}
.device-path-item:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
  border-color: var(--color-brand-blue);
}
.device-path-item {
  background: var(--color-bg-elevated);
  padding: var(--spacing-sm) var(--spacing-md);
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
}

.device-path-text {
  font-family: monospace;
  font-size: 0.9rem;
  color: var(--color-brand-blue);
  background: none;
  padding: 0;
  word-break: break-all;
  flex: 1;
}

.btn-copy-path {
  background: transparent;
  border: none;
  color: var(--color-text-muted);
  padding: var(--spacing-xs);
  border-radius: var(--radius-sm);
  cursor: pointer;
  flex-shrink: 0;
  margin-left: var(--spacing-sm);
  font-size: 0.75rem;
  align-self: flex-end;
  transition: color var(--transition-fast), background-color var(--transition-fast);
}
.btn-copy-path:hover {
  color: var(--color-brand-blue);
  background-color: rgba(255, 255, 255, 0.1);
}
.btn-copy-path.copied {
  color: var(--color-success);
}

.session-start-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.9);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  opacity: 0;
  animation: fadeIn 0.3s ease forwards;
}

@keyframes fadeIn {
  to {
    opacity: 1;
  }
}
@keyframes fadeOut {
  to {
    opacity: 0;
  }
}
.countdown-animation {
  text-align: center;
}
.countdown-animation .countdown-number {
  font-size: 12rem;
  font-weight: 700;
  color: white;
  opacity: 0;
  transform: scale(2);
  animation: countdownPop 0.8s ease forwards;
  font-family: "Gilroy", system-ui, sans-serif;
  text-shadow: 0 0 60px rgba(255, 255, 255, 0.5);
}
.countdown-animation .countdown-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  animation: fadeIn 0.5s ease forwards;
}
.countdown-animation .countdown-icon-img {
  width: 320px;
  height: 320px;
  filter: drop-shadow(0 0 20px rgba(57, 179, 234, 0.6)) drop-shadow(0 0 50px rgba(130, 0, 143, 0.4));
  animation: iconGlow 2.5s ease-in-out infinite;
}

.busy-splash {
  text-align: center;
}
.busy-splash .busy-splash-icon {
  width: 220px;
  height: 220px;
  filter: drop-shadow(0 0 20px rgba(57, 179, 234, 0.6)) drop-shadow(0 0 50px rgba(130, 0, 143, 0.4));
  animation: iconGlow 2.5s ease-in-out infinite;
}

.busy-splash-text {
  margin-top: 0.75rem;
  font-size: 2.25rem;
  font-weight: 900;
  color: white;
  font-family: "Gilroy", system-ui, sans-serif;
  opacity: 0;
  animation: fadeIn 0.5s ease 0.2s forwards;
  text-align: center;
  text-shadow: 0 0 30px rgba(255, 255, 255, 0.25);
}

@keyframes countdownPop {
  0% {
    opacity: 0;
    transform: scale(2);
  }
  20% {
    opacity: 1;
    transform: scale(1);
  }
  80% {
    opacity: 1;
    transform: scale(1);
  }
  100% {
    opacity: 0;
    transform: scale(0.5);
  }
}
@keyframes iconGlow {
  0%, 100% {
    filter: drop-shadow(0 0 20px rgba(57, 179, 234, 0.6)) drop-shadow(0 0 50px rgba(130, 0, 143, 0.4));
    transform: scale(1);
  }
  50% {
    filter: drop-shadow(0 0 35px rgba(57, 179, 234, 0.9)) drop-shadow(0 0 70px rgba(130, 0, 143, 0.6)) drop-shadow(0 0 100px rgba(57, 179, 234, 0.3));
    transform: scale(1.05);
  }
}
.aperture-animation {
  text-align: center;
}
.aperture-animation .aperture-container {
  width: 200px;
  height: 200px;
  position: relative;
  margin: 0 auto 2rem;
}
.aperture-animation .aperture-blade {
  position: absolute;
  width: 100%;
  height: 100%;
  clip-path: polygon(50% 50%, 30% 0%, 70% 0%);
  background: linear-gradient(135deg, #39b3ea 0%, #2196F3 100%);
  transform-origin: 50% 50%;
  animation: apertureOpen 1.5s ease forwards;
}
.aperture-animation .aperture-blade:nth-child(1) {
  transform: rotate(0deg);
  animation-delay: 0.05s;
}
.aperture-animation .aperture-blade:nth-child(2) {
  transform: rotate(45deg);
  animation-delay: 0.1s;
}
.aperture-animation .aperture-blade:nth-child(3) {
  transform: rotate(90deg);
  animation-delay: 0.15s;
}
.aperture-animation .aperture-blade:nth-child(4) {
  transform: rotate(135deg);
  animation-delay: 0.2s;
}
.aperture-animation .aperture-blade:nth-child(5) {
  transform: rotate(180deg);
  animation-delay: 0.25s;
}
.aperture-animation .aperture-blade:nth-child(6) {
  transform: rotate(225deg);
  animation-delay: 0.3s;
}
.aperture-animation .aperture-blade:nth-child(7) {
  transform: rotate(270deg);
  animation-delay: 0.35s;
}
.aperture-animation .aperture-blade:nth-child(8) {
  transform: rotate(315deg);
  animation-delay: 0.4s;
}
.aperture-animation .aperture-text {
  font-size: 1.5rem;
  color: white;
  font-family: "Gilroy", system-ui, sans-serif;
  opacity: 0;
  animation: fadeIn 0.5s ease 1s forwards;
}

@keyframes apertureOpen {
  0% {
    clip-path: polygon(50% 50%, 30% 0%, 70% 0%);
    opacity: 1;
  }
  100% {
    clip-path: polygon(50% 50%, 0% -50%, 100% -50%);
    opacity: 0.3;
  }
}
.pulse-record-animation {
  text-align: center;
}
.pulse-record-animation .pulse-container {
  position: relative;
  width: 120px;
  height: 120px;
  margin: 0 auto 2rem;
}
.pulse-record-animation .pulse-ring {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 80px;
  height: 80px;
  border: 3px solid #ff0000;
  border-radius: 50%;
  opacity: 0;
  animation: pulseRing 1.5s ease infinite;
}
.pulse-record-animation .pulse-ring:nth-child(2) {
  animation-delay: 0.5s;
}
.pulse-record-animation .pulse-ring:nth-child(3) {
  animation-delay: 1s;
}
.pulse-record-animation .pulse-dot {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 40px;
  height: 40px;
  background: #ff0000;
  border-radius: 50%;
  box-shadow: 0 0 30px #ff0000, 0 0 60px #ff0000;
  animation: pulseDot 1s ease infinite;
}
.pulse-record-animation .pulse-text {
  font-size: 1.5rem;
  color: white;
  font-family: "Gilroy", system-ui, sans-serif;
}
.pulse-record-animation .pulse-bars {
  display: flex;
  justify-content: center;
  gap: 4px;
  margin-top: 1.5rem;
}
.pulse-record-animation .pulse-bars .bar {
  width: 6px;
  height: 30px;
  background: linear-gradient(to top, #ff0000, #ff6b6b);
  border-radius: 3px;
  animation: barBounce 0.8s ease infinite;
}
.pulse-record-animation .pulse-bars .bar:nth-child(1) {
  animation-delay: 0.1s;
}
.pulse-record-animation .pulse-bars .bar:nth-child(2) {
  animation-delay: 0.2s;
}
.pulse-record-animation .pulse-bars .bar:nth-child(3) {
  animation-delay: 0.3s;
}
.pulse-record-animation .pulse-bars .bar:nth-child(4) {
  animation-delay: 0.4s;
}
.pulse-record-animation .pulse-bars .bar:nth-child(5) {
  animation-delay: 0.5s;
}

@keyframes pulseRing {
  0% {
    width: 40px;
    height: 40px;
    opacity: 1;
  }
  100% {
    width: 150px;
    height: 150px;
    opacity: 0;
  }
}
@keyframes pulseDot {
  0%, 100% {
    transform: translate(-50%, -50%) scale(1);
  }
  50% {
    transform: translate(-50%, -50%) scale(1.1);
  }
}
@keyframes barBounce {
  0%, 100% {
    height: 15px;
  }
  50% {
    height: 40px;
  }
}
.wave-animation {
  text-align: center;
}
.wave-animation .wave-text {
  font-size: 2.5rem;
  font-weight: 600;
  color: white;
  font-family: "Gilroy", system-ui, sans-serif;
  margin-bottom: 2rem;
  min-height: 3rem;
}
.wave-animation .wave-text .char {
  display: inline-block;
  opacity: 0;
  transform: translateY(20px);
  animation: charReveal 0.4s ease forwards;
}
.wave-animation .wave-bars {
  display: flex;
  justify-content: center;
  align-items: flex-end;
  gap: 6px;
  height: 80px;
}
.wave-animation .wave-bars .wave-bar {
  width: 8px;
  background: linear-gradient(to top, #39b3ea, #00d4ff);
  border-radius: 4px;
  animation: waveBar 1.2s ease-in-out infinite;
}
.wave-animation .wave-bars .wave-bar:nth-child(1) {
  animation-delay: 0.1s;
}
.wave-animation .wave-bars .wave-bar:nth-child(2) {
  animation-delay: 0.2s;
}
.wave-animation .wave-bars .wave-bar:nth-child(3) {
  animation-delay: 0.3s;
}
.wave-animation .wave-bars .wave-bar:nth-child(4) {
  animation-delay: 0.4s;
}
.wave-animation .wave-bars .wave-bar:nth-child(5) {
  animation-delay: 0.5s;
}
.wave-animation .wave-bars .wave-bar:nth-child(6) {
  animation-delay: 0.6s;
}
.wave-animation .wave-bars .wave-bar:nth-child(7) {
  animation-delay: 0.7s;
}
.wave-animation .wave-bars .wave-bar:nth-child(8) {
  animation-delay: 0.8s;
}
.wave-animation .wave-bars .wave-bar:nth-child(9) {
  animation-delay: 0.9s;
}
.wave-animation .wave-bars .wave-bar:nth-child(10) {
  animation-delay: 1s;
}
.wave-animation .wave-bars .wave-bar:nth-child(11) {
  animation-delay: 1.1s;
}
.wave-animation .wave-bars .wave-bar:nth-child(12) {
  animation-delay: 1.2s;
}
.wave-animation .wave-subtext {
  margin-top: 2rem;
  font-size: 1rem;
  color: rgba(255, 255, 255, 0.6);
}

@keyframes charReveal {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
@keyframes waveBar {
  0%, 100% {
    height: 20px;
  }
  50% {
    height: 70px;
  }
}
.networking-addresses {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  margin-top: 0.35rem;
  margin-bottom: 0.5rem;
}

.networking-address-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  border: 1px solid var(--color-border);
  border-radius: 999px;
  padding: 0.2rem 0.6rem;
  font-size: 0.75rem;
  background: rgba(255, 255, 255, 0.03);
}

.networking-address-name {
  font-weight: 600;
  color: var(--color-text-muted);
}

.networking-address-ip {
  color: var(--color-text-secondary);
  font-variant-numeric: tabular-nums;
}

.conn-priority-list {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.conn-priority-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border: 1px solid var(--color-border);
  border-radius: 0.5rem;
  padding: 0.25rem 0.5rem;
  font-size: 0.8rem;
}

.conn-priority-info {
  display: flex;
  align-items: center;
  gap: 0.35rem;
}

.conn-priority-status {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  flex-shrink: 0;
  background: var(--color-text-muted);
}
.conn-priority-status.is-connected {
  background: var(--color-success);
}
.conn-priority-status.is-disconnected {
  background: var(--color-text-muted);
  opacity: 0.4;
}

.conn-priority-badge {
  background: var(--color-bg-tertiary);
  padding: 0.1rem 0.4rem;
  border-radius: 0.25rem;
  font-size: 0.7rem;
  color: var(--color-text-muted);
}

.conn-priority-ip {
  font-variant-numeric: tabular-nums;
}

.conn-priority-badge-label {
  font-size: 0.6rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  opacity: 0.7;
}

.conn-priority-rename {
  color: var(--color-text-muted);
  text-decoration: none;
  font-size: 0.65rem;
  padding: 0.1rem 0.2rem;
  opacity: 0;
  transition: opacity 120ms ease;
}
.conn-priority-rename:hover {
  color: var(--color-brand-blue);
}

.conn-priority-item:hover .conn-priority-rename {
  opacity: 1;
}

.conn-priority-rename-input {
  width: 11rem;
  padding: 0.1rem 0.3rem;
  font-size: 0.75rem;
  border: 1px solid var(--color-border);
  border-radius: 0.25rem;
  background-color: var(--color-bg-secondary);
  color: var(--color-text-primary);
}
.conn-priority-rename-input:focus {
  outline: none;
  border-color: var(--color-brand-blue);
  box-shadow: 0 0 0 3px rgba(57, 179, 234, 0.15);
}

.conn-priority-metric {
  display: flex;
  align-items: center;
  gap: 0.25rem;
  margin-left: auto;
  margin-right: 0.5rem;
}

.conn-priority-metric-label {
  font-size: 0.7rem;
  color: var(--color-text-muted);
}

.conn-priority-metric-input {
  width: 4rem;
  padding: 0.1rem 0.3rem;
  font-size: 0.75rem;
  border: 1px solid var(--color-border);
  border-radius: 0.25rem;
  background-color: var(--color-bg-secondary);
  color: var(--color-text-primary);
  text-align: center;
}
.conn-priority-metric-input:hover {
  border-color: var(--color-border-hover);
}
.conn-priority-metric-input:focus {
  outline: none;
  border-color: var(--color-brand-blue);
  box-shadow: 0 0 0 3px rgba(57, 179, 234, 0.15);
  background-color: var(--color-bg-secondary);
}
.conn-priority-metric-input::placeholder {
  color: var(--color-text-muted);
  font-size: 0.65rem;
}
.conn-priority-metric-input:-webkit-autofill, .conn-priority-metric-input:-webkit-autofill:hover, .conn-priority-metric-input:-webkit-autofill:focus {
  -webkit-box-shadow: 0 0 0 1000px var(--color-bg-secondary) inset;
  -webkit-text-fill-color: var(--color-text-primary);
}
.conn-priority-metric-input {
  /* Hide number spinners */
  -moz-appearance: textfield;
}
.conn-priority-metric-input::-webkit-outer-spin-button, .conn-priority-metric-input::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

.conn-priority-metric-set {
  font-size: 0.7rem;
  color: var(--color-brand-blue);
  text-decoration: none;
  padding: 0.1rem 0.3rem;
}
.conn-priority-metric-set:hover {
  text-decoration: underline;
}

.conn-priority-actions {
  display: flex;
  gap: 0.25rem;
}

.conn-priority-up,
.conn-priority-down {
  color: var(--color-text-muted);
  padding: 0.1rem 0.3rem;
  text-decoration: none;
}
.conn-priority-up:hover,
.conn-priority-down:hover {
  color: var(--color-brand-blue);
}

.wifi-intro {
  font-size: 0.75rem;
  color: var(--color-text-muted);
  margin-top: 0.25rem;
}

.wifi-status-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.wifi-status-indicator {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.8rem;
}

.wifi-status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
}
.wifi-status-dot.is-connected {
  background: var(--color-success);
}
.wifi-status-dot.is-disconnected {
  background: var(--color-warning);
}
.wifi-status-dot.is-off {
  background: var(--color-text-muted);
}

.wifi-actions {
  display: flex;
  gap: 0.35rem;
}

.wifi-scan-empty {
  font-size: 0.8rem;
  color: var(--color-text-muted);
}

.wifi-scan-footer {
  display: flex;
  justify-content: flex-end;
  margin-top: 0.5rem;
}

.wifi-overlay {
  position: absolute;
  inset: 0;
  background: rgba(30, 33, 40, 0.92);
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-md);
  z-index: 10;
  animation: wifiFadeIn 0.3s ease;
}

@keyframes wifiFadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}
.wifi-arc-animation {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
}

.wifi-arcs {
  position: relative;
  width: 90px;
  height: 90px;
}

.wifi-arc {
  position: absolute;
  bottom: 0;
  left: 50%;
  border: 3px solid var(--color-brand-blue);
  border-radius: 50%;
  transform: translateX(-50%);
  opacity: 0;
}

.wifi-arc-3 {
  width: 80px;
  height: 80px;
}

.wifi-arc-2 {
  width: 56px;
  height: 56px;
}

.wifi-arc-1 {
  width: 32px;
  height: 32px;
}

.wifi-arc-dot {
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--color-brand-blue);
}

.wifi-arc-icon {
  position: absolute;
  bottom: -2px;
  left: 50%;
  transform: translateX(-50%);
  font-size: 1.2rem;
  color: var(--color-brand-blue);
}

.wifi-arc-on .wifi-arc-1 {
  animation: wifiArcPulse 2.4s ease infinite;
}
.wifi-arc-on .wifi-arc-2 {
  animation: wifiArcPulse 2.4s ease infinite 0.3s;
}
.wifi-arc-on .wifi-arc-3 {
  animation: wifiArcPulse 2.4s ease infinite 0.6s;
}
.wifi-arc-on .wifi-arc-dot {
  animation: wifiDotPulse 2.4s ease-in-out infinite;
}

.wifi-arc-off .wifi-arc-3 {
  animation: wifiArcPulse 2.4s ease infinite;
}
.wifi-arc-off .wifi-arc-2 {
  animation: wifiArcPulse 2.4s ease infinite 0.3s;
}
.wifi-arc-off .wifi-arc-1 {
  animation: wifiArcPulse 2.4s ease infinite 0.6s;
}
.wifi-arc-off .wifi-arc-dot {
  animation: wifiDotPulse 2.4s ease-in-out infinite;
}

@keyframes wifiArcPulse {
  0% {
    opacity: 0;
    transform: translateX(-50%) scale(1.5);
  }
  15% {
    opacity: 1;
    transform: translateX(-50%) scale(0.95);
  }
  20% {
    opacity: 1;
    transform: translateX(-50%) scale(1);
    filter: drop-shadow(0 0 8px rgba(57, 179, 234, 0.8));
  }
  50% {
    opacity: 1;
    transform: translateX(-50%) scale(1);
    filter: drop-shadow(0 0 4px rgba(57, 179, 234, 0.4));
  }
  65% {
    opacity: 0;
    transform: translateX(-50%) scale(0.85);
    filter: none;
  }
  100% {
    opacity: 0;
  }
}
@keyframes wifiDotPulse {
  0%, 100% {
    transform: translateX(-50%) scale(0.8);
    opacity: 0.5;
  }
  50% {
    transform: translateX(-50%) scale(1);
    opacity: 1;
    filter: drop-shadow(0 0 4px rgba(57, 179, 234, 0.6));
  }
}
.wifi-arc-text {
  color: var(--color-brand-blue);
  font-size: 0.85rem;
  font-weight: 500;
  opacity: 0;
  animation: wifiFadeIn 0.4s ease forwards 1.4s;
}

.wifi-saved-list {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
}

.wifi-saved-pill {
  display: inline-flex;
  align-items: center;
  border: 1px solid var(--color-border);
  border-radius: 1rem;
  font-size: 0.75rem;
  overflow: hidden;
}

.wifi-saved-connect {
  padding: 0.2rem 0.5rem;
  color: var(--color-text);
  text-decoration: none;
}
.wifi-saved-connect:hover {
  background: var(--color-brand-blue);
  color: #fff;
}

.wifi-saved-delete {
  padding: 0.2rem 0.4rem;
  color: var(--color-text-muted);
  text-decoration: none;
  border-left: 1px solid var(--color-border);
}
.wifi-saved-delete:hover {
  color: var(--color-danger);
  background: rgba(220, 53, 69, 0.15);
}

.btn-xs {
  padding: 0.1rem 0.4rem;
  font-size: 0.7rem;
  line-height: 1.4;
}

.wifi-pulse {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--color-brand-blue);
  font-size: 1.1rem;
}
.wifi-pulse i {
  font-size: 1.75rem;
  animation: wifiPulse 1.5s ease-in-out infinite;
}

@keyframes wifiPulse {
  0%, 100% {
    opacity: 0.3;
    transform: scale(0.9);
    filter: drop-shadow(0 0 0 transparent);
  }
  50% {
    opacity: 1;
    transform: scale(1.15);
    filter: drop-shadow(0 0 10px var(--color-brand-blue));
  }
}
.s3-sync-progress {
  background: var(--color-bg-secondary);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  padding: var(--spacing-md);
}

.s3-sync-header {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.75rem;
}

.s3-sync-title {
  font-weight: 600;
  font-size: 0.9rem;
}

.s3-sync-badge {
  font-size: 0.7rem;
  font-weight: 600;
  padding: 0.15rem 0.5rem;
  border-radius: 999px;
  text-transform: uppercase;
  letter-spacing: 0.03em;
}

.s3-sync-badge-syncing {
  background: rgba(var(--color-brand-blue-rgb), 0.2);
  color: var(--color-brand-blue);
  animation: s3SyncPulse 2s ease-in-out infinite;
}

.s3-sync-badge-finishing {
  background: rgba(245, 158, 11, 0.2);
  color: var(--color-warning);
}

.s3-sync-badge-completed {
  background: rgba(119, 179, 0, 0.2);
  color: var(--color-success);
}

.s3-sync-eta {
  font-size: 0.75rem;
  color: var(--color-text-muted);
}

@keyframes s3SyncPulse {
  0%, 100% {
    opacity: 1;
  }
  50% {
    opacity: 0.5;
  }
}
.s3-sync-overall {
  margin-bottom: 0.75rem;
}

.s3-sync-bar-track {
  width: 100%;
  height: 20px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.2);
}

.s3-sync-bar-fill {
  height: 100%;
  min-width: 0;
  background: linear-gradient(90deg, #2980B9 0%, #39B3EA 50%, #6DD5FA 100%);
  border-radius: var(--radius-md);
  box-shadow: 0 0 10px rgba(57, 179, 234, 0.5), 0 0 20px rgba(57, 179, 234, 0.3), inset 0 1px 0 rgba(255, 255, 255, 0.2);
  transition: width 0.5s ease;
}

.s3-sync-overall-text {
  font-size: 0.75rem;
  color: var(--color-text-muted);
  margin-top: 0.25rem;
}

.s3-sync-lag {
  display: flex;
  align-items: baseline;
  gap: 0.5rem;
  margin-bottom: 0.75rem;
}

.s3-sync-lag-count {
  font-size: 1.5rem;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  line-height: 1;
}

.s3-sync-lag-label {
  font-size: 0.8rem;
  color: var(--color-text-muted);
}

.s3-sync-lag-trend {
  font-size: 0.85rem;
}

.s3-sync-lag-rate {
  font-size: 0.75rem;
  color: var(--color-text-muted);
}

.s3-sync-lag-delay {
  font-size: 0.75rem;
  color: var(--color-text-muted);
  margin-left: auto;
}

.s3-sync-lag-good {
  color: var(--color-success);
}

.s3-sync-lag-warn {
  color: var(--color-warning);
}

.s3-sync-angles {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.s3-sync-angle {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.s3-sync-angle-name {
  font-size: 0.75rem;
  font-weight: 500;
  min-width: 100px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.s3-sync-angle-bar-track {
  flex: 1;
  height: 10px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 5px;
  overflow: hidden;
}

.s3-sync-angle-bar-fill {
  height: 100%;
  background: linear-gradient(90deg, #2980B9 0%, #39B3EA 100%);
  border-radius: 5px;
  transition: width 0.5s ease;
}

.s3-sync-angle-count {
  font-size: 0.7rem;
  color: var(--color-text-muted);
  min-width: 50px;
  text-align: right;
  white-space: nowrap;
}

.s3-sync-header-spacer {
  flex: 1;
}

.s3-sync-action-btn {
  background: none;
  border: 1px solid;
  border-radius: var(--radius-sm);
  font-size: 0.7rem;
  font-weight: 600;
  padding: 0.2rem 0.5rem;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  transition: background 0.15s ease;
}

.s3-sync-pause-btn {
  border-color: var(--color-text-muted);
  color: var(--color-text-muted);
}
.s3-sync-pause-btn:hover {
  background: rgba(255, 255, 255, 0.08);
}

.s3-sync-cancel-btn {
  border-color: var(--color-warning);
  color: var(--color-warning);
}
.s3-sync-cancel-btn:hover {
  background: rgba(245, 158, 11, 0.15);
}

.s3-sync-delete-btn {
  border-color: var(--color-danger);
  color: var(--color-danger);
}
.s3-sync-delete-btn:hover {
  background: rgba(239, 68, 68, 0.15);
}

.s3-sync-angle-delete {
  background: none;
  border: none;
  color: var(--color-danger);
  cursor: pointer;
  opacity: 0.5;
  padding: 0 0.25rem;
  font-size: 0.7rem;
  transition: opacity 0.15s ease;
}
.s3-sync-angle-delete:hover {
  opacity: 1;
}

.s3-sync-angle-cancel {
  background: none;
  border: none;
  color: var(--color-warning);
  cursor: pointer;
  opacity: 0.5;
  padding: 0 0.25rem;
  font-size: 0.7rem;
  transition: opacity 0.15s ease;
}
.s3-sync-angle-cancel:hover {
  opacity: 1;
}

.s3-sync-angle-cancelled-text {
  color: var(--color-text-muted);
  font-style: italic;
}

.s3-sync-angle-paused-text {
  color: var(--color-warning);
  font-style: italic;
}

.s3-sync-angle-pause {
  background: none;
  border: none;
  color: var(--color-text-muted);
  cursor: pointer;
  opacity: 0.5;
  padding: 0 0.25rem;
  font-size: 0.7rem;
  transition: opacity 0.15s ease;
}
.s3-sync-angle-pause:hover {
  opacity: 1;
}

.s3-sync-badge-cancelled {
  background: rgba(239, 68, 68, 0.2);
  color: var(--color-danger);
}

.s3-sync-badge-paused {
  background: rgba(234, 179, 8, 0.2);
  color: var(--color-warning);
}

.s3-sync-lag-paused-note {
  color: var(--color-warning);
  font-style: italic;
  margin-left: 0.25rem;
}

.s3-sync-badge-export,
.s3-sync-badge-import {
  background: rgba(var(--color-brand-blue-rgb), 0.15);
  color: var(--color-brand-blue);
}

.s3-sync-badge-export-flash,
.s3-sync-badge-import-flash {
  background: rgba(119, 179, 0, 0.5);
  color: #fff;
}

.s3-sync-chart-toggle {
  font-size: 0.75rem;
  color: var(--color-text-muted);
  cursor: pointer;
  text-align: center;
  padding: 0.25rem 0;
  margin-top: 0.25rem;
}
.s3-sync-chart-toggle:hover {
  color: var(--color-brand-blue);
}

.s3-sync-chart-container {
  margin-top: 0.25rem;
  border-radius: 4px;
  background: rgba(0, 0, 0, 0.15);
}
.s3-sync-chart-container canvas {
  display: block;
}

.s3-sync-badge-export-fade,
.s3-sync-badge-import-fade {
  background: rgba(var(--color-brand-blue-rgb), 0.15);
  color: var(--color-brand-blue);
  transition: background 1s ease-out, color 1s ease-out;
}

.cuts-mgr-group {
  margin-bottom: var(--spacing-md);
}

.cuts-mgr-group-header {
  display: flex;
  align-items: center;
  gap: var(--spacing-sm);
  margin-bottom: var(--spacing-sm);
  font-size: 0.85rem;
  font-weight: 600;
}

.cuts-mgr-group-line {
  height: 2px;
  margin-bottom: var(--spacing-sm);
}

.cuts-mgr-group-count {
  color: var(--color-text-muted);
  font-weight: 400;
}

.cuts-mgr-items {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
  gap: var(--spacing-sm);
}

.cuts-mgr-card {
  background: var(--color-bg-elevated);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  overflow: hidden;
  position: relative;
  transition: border-color 0.15s;
}
.cuts-mgr-card:hover {
  border-color: var(--color-brand-blue);
}

.cuts-mgr-thumb {
  position: relative;
  aspect-ratio: 16/9;
  background: black;
  cursor: pointer;
}
.cuts-mgr-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.cuts-mgr-select {
  position: absolute;
  top: 6px;
  left: 6px;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.55);
  border: 1.5px solid rgba(255, 255, 255, 0.75);
  display: flex;
  align-items: center;
  justify-content: center;
  color: transparent;
  font-size: 0.65rem;
  cursor: pointer;
  z-index: 3;
  opacity: 0;
  transition: opacity 0.15s, background 0.15s;
}

.cuts-mgr-card:hover .cuts-mgr-select,
.cuts-mgr-grid.has-selection .cuts-mgr-select {
  opacity: 1;
}

.cuts-mgr-card.is-selected {
  border-color: var(--color-brand-blue);
  box-shadow: 0 0 0 1px var(--color-brand-blue);
}
.cuts-mgr-card.is-selected .cuts-mgr-select {
  opacity: 1;
  background: var(--color-brand-blue);
  border-color: var(--color-brand-blue);
  color: #fff;
}

.cuts-mgr-composer-export svg {
  vertical-align: -2px;
}

.cuts-mgr-composer-export.is-exporting svg {
  animation: cuts-composer-spin 1.2s linear infinite;
}

@keyframes cuts-composer-spin {
  to {
    transform: rotate(360deg);
  }
}
.cuts-mgr-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, 0.3);
  opacity: 0;
  transition: opacity 0.2s;
}
.cuts-mgr-thumb:hover .cuts-mgr-overlay {
  opacity: 1;
}
.cuts-mgr-overlay i {
  width: 46px;
  height: 46px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding-left: 3px;
  font-size: 1.15rem;
  color: #fff;
  background: var(--color-brand-blue);
  border-radius: 50%;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.45);
}

.cuts-mgr-info {
  padding: 6px 8px;
  font-size: 0.75rem;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.cuts-mgr-time {
  color: var(--color-text-secondary);
}

.cuts-mgr-filename {
  color: var(--color-text-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.cuts-mgr-actions {
  display: flex;
  justify-content: flex-end;
  gap: var(--spacing-xs);
  padding: 0 8px 6px;
}

.cuts-mgr-actions button,
.cuts-mgr-actions a {
  background: none;
  border: 1px solid var(--color-border);
  color: var(--color-text-secondary);
  border-radius: var(--radius-sm);
  width: 28px;
  height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 0.8rem;
  text-decoration: none;
}

.cuts-mgr-delete:hover {
  border-color: var(--bs-danger);
  color: var(--bs-danger);
}

.cuts-mgr-download:hover {
  border-color: var(--color-brand-blue);
  color: var(--color-brand-blue);
}

.cuts-mgr-angle-group {
  grid-column: 1/-1;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
  gap: var(--spacing-sm);
  overflow: hidden;
}
.cuts-mgr-angle-group .cuts-mgr-card {
  overflow: visible;
}
.cuts-mgr-angle-group .cuts-mgr-card .cuts-mgr-thumb {
  border-radius: var(--radius-sm) var(--radius-sm) 0 0;
  overflow: hidden;
}
.cuts-mgr-angle-group .cuts-mgr-card:not(:last-child)::after {
  content: "";
  position: absolute;
  right: calc(-1 * var(--spacing-sm));
  top: 50%;
  width: var(--spacing-sm);
  border-top: 1px solid var(--color-border);
}

.cuts-mgr-group-badge {
  position: absolute;
  bottom: 4px;
  left: 4px;
  background: rgba(0, 0, 0, 0.8);
  color: var(--color-brand-blue);
  font-size: 0.65rem;
  font-weight: 600;
  padding: 2px 6px;
  border-radius: var(--radius-sm);
  z-index: 2;
  display: flex;
  align-items: center;
}
.cuts-mgr-group-badge i {
  font-size: 0.55rem;
}

.cut-group-popup {
  position: fixed;
  z-index: 10000;
  width: 260px;
  background: var(--color-bg-elevated);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.5);
  overflow: hidden;
}

.cut-group-popup-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 10px;
  border-bottom: 1px solid var(--color-border);
}

.cut-group-popup-title {
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--color-text-primary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.cut-group-popup-count {
  font-size: 0.65rem;
  color: var(--color-text-muted);
  flex-shrink: 0;
  margin-left: 6px;
}

.cut-group-popup-list {
  max-height: 300px;
  overflow-y: auto;
  scrollbar-width: thin;
}

.cut-group-popup-item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 10px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}
.cut-group-popup-item:last-child {
  border-bottom: none;
}
.cut-group-popup-item:hover {
  background: rgba(255, 255, 255, 0.03);
}

.cut-group-popup-item-thumb {
  width: 48px;
  height: 27px;
  flex-shrink: 0;
  background: #000;
  border-radius: 2px;
  overflow: hidden;
}
.cut-group-popup-item-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.cut-group-popup-item-processing {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
  color: var(--color-text-muted);
  font-size: 0.6rem;
}

.cut-group-popup-item-name {
  flex: 1;
  font-size: 0.7rem;
  color: var(--color-text-secondary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.cut-group-popup-item-actions {
  display: flex;
  gap: 4px;
  flex-shrink: 0;
}

.cut-group-popup-play,
.cut-group-popup-dl,
.cut-group-popup-share {
  width: 24px;
  height: 24px;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  background: none;
  color: var(--color-text-secondary);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 0.6rem;
  text-decoration: none;
  transition: border-color 0.15s, color 0.15s;
}

.cut-group-popup-play:hover {
  border-color: var(--color-brand-blue);
  color: var(--color-brand-blue);
}

.cut-group-popup-dl:hover {
  border-color: var(--color-brand-blue);
  color: var(--color-brand-blue);
}

.cut-group-popup-share:hover {
  border-color: var(--color-success);
  color: var(--color-success);
}

.cut-group-popup-footer {
  padding: 6px 10px;
  border-top: 1px solid var(--color-border);
}

.cut-group-popup-delete-all {
  width: 100%;
  background: none;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  color: var(--color-text-secondary);
  font-size: 0.7rem;
  padding: 4px 8px;
  cursor: pointer;
  transition: border-color 0.15s, color 0.15s;
}
.cut-group-popup-delete-all:hover {
  border-color: var(--bs-danger);
  color: var(--bs-danger);
}

.ssh-support-description {
  margin-top: 0.35rem;
  font-size: 0.8rem;
  color: var(--color-text-muted);
}

.ssh-support-servers {
  margin-top: 0.4rem;
}
.ssh-support-servers .toggle-pill input[type=radio]:checked + .pill-label {
  background-color: var(--color-brand-blue);
  border-color: var(--color-brand-blue);
}

.ssh-support-ports {
  display: flex;
  gap: var(--spacing-md);
  margin-top: 0.4rem;
  font-size: 0.8rem;
}

.ssh-support-port-label {
  color: var(--color-text-muted);
  font-weight: 500;
  margin-right: 0.25rem;
  text-decoration: none;
}
.ssh-support-port-label[href] {
  color: var(--color-text-muted);
}
.is-running-state .ssh-support-port-label[href] {
  color: var(--color-brand-blue);
}

.ssh-support-port-value {
  font-family: var(--font-monospace);
  color: var(--color-text-primary);
  font-weight: 600;
}

.ssh-support-copy-btn {
  padding: 0 0.2rem;
  font-size: 0.7rem;
  color: var(--color-text-muted);
  visibility: hidden;
}
.is-running-state .ssh-support-copy-btn {
  visibility: visible;
}
.ssh-support-copy-btn:hover {
  color: var(--color-brand-blue);
}

.ssh-support-widget {
  display: flex;
  flex-direction: column;
}

.ssh-support-footer {
  display: flex;
  align-items: center;
  gap: var(--spacing-sm);
  margin-top: auto;
  padding-top: 0.5rem;
  padding-left: var(--spacing-sm);
}

.ssh-support-controls {
  margin-left: auto;
}

.ssh-support-status {
  font-size: 0.85rem;
  font-weight: 500;
}

.ssh-support-status-dot {
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  margin-right: 0.15rem;
}
.ssh-support-status-dot.is-running {
  background: var(--color-success);
}
.ssh-support-status-dot.is-stopped {
  background: var(--color-text-muted);
}

.ssh-support-autostart {
  cursor: pointer;
  user-select: none;
}
.ssh-support-autostart input[type=checkbox] {
  position: absolute;
  opacity: 0;
  width: 0;
  height: 0;
}
.ssh-support-autostart .pill-label {
  display: inline-block;
  padding: var(--spacing-xs) var(--spacing-sm);
  font-size: 0.8rem;
  font-weight: 500;
  border-radius: var(--radius-xl);
  border: 1px solid var(--color-border);
  background-color: var(--color-bg-elevated);
  color: var(--color-text-secondary);
  transition: all var(--transition-fast);
}
.ssh-support-autostart .pill-label:hover {
  border-color: var(--color-border-hover);
  color: var(--color-text-primary);
}
.ssh-support-autostart .pill-tick {
  display: none;
}
.ssh-support-autostart input[type=checkbox]:checked + .pill-label {
  background-color: var(--color-brand-blue);
  border-color: var(--color-brand-blue);
  color: white;
}
.ssh-support-autostart input[type=checkbox]:checked + .pill-label .pill-tick {
  display: inline;
}

.ssh-support-controls {
  margin-left: auto;
}

.software-update-build-info {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.4rem;
  margin-top: 0.35rem;
  font-size: 0.8rem;
}

.software-update-badge {
  display: inline-flex;
  align-items: center;
  padding: 0.15rem 0.5rem;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 500;
}

.software-update-branch {
  background: var(--color-bg-elevated);
  border: 1px solid var(--color-border);
  color: var(--color-brand-blue);
}
.software-update-branch i {
  color: var(--color-brand-blue);
}

.software-update-hash {
  background: var(--color-bg-elevated);
  border: 1px solid var(--color-border);
  color: var(--color-brand-blue);
  font-family: "SF Mono", "Fira Code", "Consolas", monospace;
}

.software-update-subject {
  color: var(--color-text-primary);
}

.software-update-date {
  color: var(--color-text-muted);
  font-size: 0.75rem;
}

.software-update-widget {
  display: flex;
  flex-direction: column;
}

.software-update-content {
  display: flex;
  flex-direction: column;
  flex: 1;
  padding-bottom: var(--spacing-sm);
}

.software-update-footer {
  display: flex;
  align-items: center;
  margin-top: auto;
  padding-top: 0.5rem;
}
.software-update-footer .btn {
  margin-left: auto;
}

.software-update-status {
  font-size: 0.85rem;
  font-weight: 500;
}

.movie-session-header {
  cursor: pointer;
}
.movie-session-header[aria-expanded=true] .movie-session-chevron {
  transform: rotate(180deg);
}

.movie-session-chevron {
  font-size: 0.75rem;
  color: var(--color-text-secondary);
  transition: transform 0.2s ease;
}

.movie-session-warning {
  margin-top: 0.35rem;
  margin-bottom: 0.5rem;
  padding: 0.4rem 0.6rem;
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--color-warning);
  background: rgba(var(--color-warning-rgb), 0.1);
  border: 1px solid rgba(var(--color-warning-rgb), 0.25);
  border-radius: var(--radius-sm);
}

.movie-s3-sync-warning {
  font-size: 0.78rem;
  color: var(--color-brand-blue);
}

.movie-file-dropzone {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
  border: 2px dashed var(--color-border);
  border-radius: var(--radius-md);
  color: var(--color-text-muted);
  cursor: pointer;
  transition: all var(--transition-fast);
  text-align: center;
  font-size: 0.85rem;
}
.movie-file-dropzone:hover, .movie-file-dropzone.dragover {
  border-color: var(--color-brand-blue);
  color: var(--color-brand-blue);
  background: rgba(var(--color-brand-blue-rgb), 0.05);
}
.movie-file-dropzone.disabled {
  pointer-events: none;
  opacity: 0.4;
}
.movie-file-dropzone.has-files {
  margin-top: 0.35rem;
  padding: 0.4rem 0.75rem;
  flex-direction: row;
  gap: 0.5rem;
  border-style: dashed;
  font-size: 0.8rem;
}
.movie-file-dropzone.has-files .fa-cloud-arrow-up {
  font-size: 1rem;
  margin: 0;
}
.movie-file-dropzone.has-files .dropzone-text {
  display: none;
}
.movie-file-dropzone.has-files::after {
  content: "Add more files";
  color: inherit;
}

.movie-file-list {
  margin-top: 0.35rem;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  background: var(--color-bg-elevated);
}
.movie-file-list:empty {
  border: none;
}

.movie-file-entry {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.45rem 0.65rem;
  font-size: 0.85rem;
  position: relative;
  background: var(--color-bg-elevated);
}
.movie-file-entry + .movie-file-entry {
  border-top: 1px solid var(--color-border);
}
.movie-file-entry:first-child {
  border-radius: var(--radius-md) var(--radius-md) 0 0;
}
.movie-file-entry:last-child {
  border-radius: 0 0 var(--radius-md) var(--radius-md);
  padding-bottom: calc(0.45rem + 4px);
}
.movie-file-entry:first-child:last-child {
  border-radius: var(--radius-md);
}

.movie-file-icon {
  color: var(--color-brand-blue);
  font-size: 1rem;
  flex-shrink: 0;
}

.movie-file-name {
  flex: 1;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-weight: 500;
}

.movie-file-size {
  color: var(--color-text-muted);
  font-size: 0.75rem;
  white-space: nowrap;
}

.movie-file-remove {
  padding: 0 0.25rem;
  color: var(--color-text-muted);
}
.movie-file-remove:hover {
  color: var(--color-danger);
}

.movie-file-progress {
  display: none;
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: rgba(0, 0, 0, 0.1);
  border-radius: 1px;
}

.movie-file-progress-bar {
  height: 100%;
  width: 0;
  background: var(--color-brand-blue);
  border-radius: 1px;
  transition: width 0.3s ease;
}
.movie-file-progress-bar.complete {
  background: var(--color-success);
}
.movie-file-progress-bar.error {
  background: var(--color-danger);
}

.movie-session-footer {
  display: flex;
  align-items: center;
  margin-top: 0.5rem;
}
.movie-session-footer .btn {
  margin-left: auto;
}
.movie-session-footer .btn + .btn {
  margin-left: 0.5rem;
}

.movie-processing-title {
  font-weight: 600;
  font-size: 0.95rem;
  margin-bottom: 0.5rem;
}

.movie-angle-progress {
  margin-bottom: 0.5rem;
}

.movie-angle-header {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.8rem;
  margin-bottom: 0.2rem;
}

.movie-angle-name {
  font-weight: 500;
}

.movie-angle-info {
  color: var(--color-text-muted);
  font-size: 0.75rem;
  flex: 1;
}

.movie-angle-percent {
  font-weight: 600;
  font-size: 0.75rem;
  min-width: 3rem;
  text-align: right;
}

.movie-angle-bar-container {
  height: 6px;
  background: rgba(0, 0, 0, 0.15);
  border-radius: 3px;
  overflow: hidden;
}

.movie-angle-bar {
  height: 100%;
  width: 0;
  background: var(--color-brand-blue);
  border-radius: 3px;
  transition: width 0.5s ease;
}
.movie-angle-bar.complete {
  background: var(--color-success);
}
.movie-angle-bar.error {
  background: var(--color-danger);
}

.storage-space-content {
  margin-top: 0.35rem;
  font-size: 0.8rem;
}
.storage-space-content .disk-progress {
  margin: 0;
}
.storage-space-content p {
  margin-bottom: 0;
}

.disk-pie-wrapper {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  height: 100%;
}

.disk-doughnut {
  --size: 100px;
  --used-color: var(--color-brand-blue);
  --track-color: rgba(255, 255, 255, 0.08);
  position: relative;
  width: var(--size);
  height: var(--size);
}
.disk-doughnut.disk-doughnut-danger {
  --used-color: #dc3545;
}

.disk-doughnut-svg {
  width: 100%;
  height: 100%;
  transform: rotate(-90deg);
}

.disk-doughnut-track {
  fill: none;
  stroke: var(--track-color);
  stroke-width: 8;
}

.disk-doughnut-fill {
  fill: none;
  stroke: var(--used-color);
  stroke-width: 8;
  stroke-linecap: round;
  transition: stroke-dashoffset 0.6s ease;
}

.disk-doughnut-label {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
}

.disk-pie-value {
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--color-text-primary);
}

.disk-pie-unit {
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--color-text-primary);
}

.disk-pie-stats {
  margin-top: 0.5rem;
  font-size: 0.8rem;
  color: var(--color-text-muted);
  text-align: center;
}

.disk-pie-heading {
  margin-top: 0.25rem;
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: white;
  text-align: center;
}

.disk-indicators-dual {
  display: flex;
  gap: 1rem;
}
.disk-indicators-dual .disk-pie-wrapper {
  flex: 1;
  min-width: 0;
}

.disk-estimate {
  margin-top: 0.5rem;
  text-align: center;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding-top: 0.5rem;
}

.disk-estimate-line {
  font-size: 0.75rem;
  color: var(--color-text-muted);
  line-height: 1.4;
}
.disk-estimate-line:first-child {
  font-weight: 600;
  color: var(--color-text-primary);
}

.storage-disk-section {
  margin-top: 0.75rem;
}

.storage-disk-section-title {
  font-weight: 600;
  font-size: 0.8rem;
  margin-bottom: 0.35rem;
}

.storage-disk-empty {
  font-size: 0.8rem;
  color: var(--color-text-muted);
}

.storage-disk-detail {
  font-size: 0.75rem;
  color: var(--color-text-muted);
  margin-bottom: 0.35rem;
}

.storage-disk-device {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  padding: 0.4rem 0.5rem;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  margin-bottom: 0.35rem;
}

.storage-disk-device-info {
  font-size: 0.8rem;
}

.magewell-empty {
  font-size: 0.8rem;
  color: var(--color-text-muted);
  margin-top: 0.35rem;
}

.magewell-list {
  margin-top: 0.35rem;
}

.magewell-device {
  padding: 0.8rem 0;
}
.magewell-device:first-child {
  padding-top: 0.4rem;
}
.magewell-device:not(:last-child) {
  border-bottom: 2px solid rgba(255, 255, 255, 0.2);
}

.magewell-device-header {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.magewell-device-name {
  font-weight: 600;
  font-size: 0.8rem;
}

.magewell-detail {
  font-size: 0.75rem;
  color: var(--color-text-muted);
}

.signal-dot {
  font-size: 0.45rem;
  vertical-align: middle;
}

.mw-cam-pill {
  display: inline-block;
  padding: 0.1em 0.5em;
  font-size: 0.75rem;
  font-weight: 500;
  border-radius: var(--radius-xl);
  color: white;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}
.mw-cam-pill.mw-cam-pill-nosignal {
  position: relative;
  overflow: hidden;
  isolation: isolate;
  color: rgb(255, 255, 255);
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.6);
}
.mw-cam-pill.mw-cam-pill-nosignal::before {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.55);
  border-radius: inherit;
  z-index: -2;
}
.mw-cam-pill.mw-cam-pill-nosignal::after {
  content: "";
  position: absolute;
  inset: 0;
  background: repeating-linear-gradient(-45deg, transparent, transparent 3px, rgba(0, 0, 0, 0.2) 3px, rgba(0, 0, 0, 0.2) 6px);
  border-radius: inherit;
  z-index: -1;
}

.maintenance-status-indicator {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  margin-top: 0.35rem;
  font-size: 0.8rem;
}

.maintenance-status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
}
.maintenance-status-dot.is-enabled {
  background: var(--color-success);
}
.maintenance-status-dot.is-disabled {
  background: var(--color-text-muted);
}

.maintenance-details {
  margin-top: 0.5rem;
}

.maintenance-detail {
  font-size: 0.75rem;
  color: var(--color-text-muted);
}

.maintenance-widget {
  display: flex;
  flex-direction: column;
}

.maintenance-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: auto;
  padding-top: 0.5rem;
}

.maintenance-last-run {
  font-size: 0.75rem;
  color: var(--color-text-muted);
}

.timezone-widget {
  display: flex;
  flex-direction: column;
}

.timezone-widget.highlight-glow {
  animation: widget-glow 1s ease-in-out 5;
}

@keyframes widget-glow {
  0%, 100% {
    border-color: var(--color-border);
    box-shadow: none;
  }
  50% {
    border-color: var(--color-brand-blue);
    box-shadow: 0 0 8px rgba(var(--color-brand-blue-rgb), 0.4);
  }
}
.timezone-mismatch-alert {
  margin-top: var(--spacing-sm);
  padding: var(--spacing-sm) var(--spacing-md);
  background: rgba(245, 158, 11, 0.15);
  border: 1px solid rgba(245, 158, 11, 0.4);
  border-radius: var(--radius-sm);
  color: var(--color-warning);
  font-size: 0.85rem;
}

.no-internet-alert {
  margin-top: var(--spacing-sm);
  margin-bottom: var(--spacing-sm);
  padding: var(--spacing-sm) var(--spacing-md);
  background: rgba(245, 158, 11, 0.15);
  border: 1px solid rgba(245, 158, 11, 0.4);
  border-radius: var(--radius-sm);
  color: var(--color-warning);
  font-size: 0.85rem;
}

.timezone-content {
  margin-top: 0.35rem;
}

.timezone-select {
  max-width: 280px;
}

.timezone-form {
  flex-grow: 1;
  display: flex;
  flex-direction: column;
}

.timezone-footer {
  display: flex;
  justify-content: flex-end;
  margin-top: auto;
  padding-top: 0.5rem;
}

.scheduler-status-title {
  font-size: 0.9rem;
}

.scheduler-status-indicator {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.8rem;
  margin-top: 0.35rem;
}

.scheduler-status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
}
.scheduler-status-dot.is-running {
  background: var(--color-success);
}
.scheduler-status-dot.is-stopped {
  background: var(--color-danger);
}

.scheduler-job-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  margin-top: 0.5rem;
}

.scheduler-job-tag {
  font-size: 0.7rem;
  color: var(--color-text-muted);
  border: 1px solid var(--color-border);
  border-radius: 999px;
  padding: 0.1rem 0.5rem;
}

.bandwidth-test-widget {
  margin-top: 0.75rem;
}

.bandwidth-test-header {
  margin-bottom: 0.5rem;
}

.bandwidth-test-result {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.bandwidth-test-passes {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.bandwidth-test-pass {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.25rem 0.75rem;
  font-size: 0.8rem;
}

.bandwidth-test-pass-label {
  color: var(--color-text-muted);
}

.bandwidth-test-pass-speed {
  font-weight: 600;
  color: var(--color-text-primary);
}

.bandwidth-test-pass-elapsed {
  color: var(--color-text-muted);
  font-size: 0.75rem;
}

.bandwidth-test-average {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex-wrap: wrap;
  padding-top: 0.4rem;
  border-top: 1px solid var(--color-border);
}

.bandwidth-test-speed {
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--color-text-primary);
}
.bandwidth-test-speed small {
  font-size: 0.75rem;
  font-weight: 400;
  color: var(--color-text-muted);
}

.bandwidth-test-recommendation {
  font-size: 1rem;
  font-weight: 600;
  color: var(--color-text-primary);
}

.bandwidth-test-badge-slow,
.bandwidth-test-badge-moderate,
.bandwidth-test-badge-good,
.bandwidth-test-badge-fast,
.bandwidth-test-badge-excellent {
  font-size: 0.85rem;
  font-weight: 700;
  padding: 0.3rem 0.85rem;
  border-radius: 999px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.bandwidth-test-badge-slow {
  background: rgba(239, 68, 68, 0.2);
  color: var(--color-danger);
}

.bandwidth-test-badge-moderate {
  background: rgba(245, 158, 11, 0.2);
  color: var(--color-warning);
}

.bandwidth-test-badge-good {
  background: rgba(119, 179, 0, 0.2);
  color: var(--color-success);
}

.bandwidth-test-badge-fast {
  background: rgba(var(--color-brand-blue-rgb), 0.2);
  color: var(--color-brand-blue);
}

.bandwidth-test-badge-excellent {
  background: rgba(139, 92, 246, 0.2);
  color: #a78bfa;
}

.bandwidth-test-body {
  display: flex;
  gap: 1rem;
  align-items: flex-start;
}

.bandwidth-test-controls {
  flex: 1;
  min-width: 0;
}

.bandwidth-test-gauge {
  flex: 0 0 180px;
  display: flex;
  flex-direction: column;
  align-items: center;
}
.bandwidth-test-gauge svg {
  width: 100%;
  height: auto;
}

.bandwidth-gauge-badge {
  text-align: center;
  min-height: 1.6rem;
}

@media (max-width: 480px) {
  .bandwidth-test-body {
    flex-wrap: wrap;
  }
  .bandwidth-test-gauge {
    flex-basis: 100%;
  }
}
.bandwidth-gauge-track {
  fill: none;
  stroke: rgba(255, 255, 255, 0.05);
  stroke-linecap: round;
}

.bandwidth-gauge-tier {
  fill: none;
  opacity: 0.7;
  stroke-linecap: round;
}

.bandwidth-gauge-needle {
  transition: transform 1s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.bandwidth-gauge-needle.is-testing {
  transition: none;
  animation: gauge-sweep 1.5s ease-in-out infinite alternate;
}

@keyframes gauge-sweep {
  0% {
    transform: rotate(150deg);
  }
  100% {
    transform: rotate(390deg);
  }
}
.bandwidth-gauge-needle.has-result {
  filter: drop-shadow(0 0 4px currentColor);
}

.bandwidth-gauge-value {
  font-size: 18px;
  font-weight: 700;
  fill: var(--color-text-primary);
}

.bandwidth-gauge-unit {
  font-size: 10px;
  fill: var(--color-text-muted);
}

.bandwidth-gauge-tick-label {
  font-size: 8px;
  fill: var(--color-text-muted);
}

.calibrate-results-table {
  width: 100%;
  border-collapse: collapse;
}
.calibrate-results-table thead th {
  padding: 0.5rem 0.5rem 0.25rem;
  font-size: 0.8rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--color-text-primary);
  border-bottom: 1px solid var(--color-border);
}
.calibrate-results-table td {
  padding: 0.3rem 0.5rem;
  font-size: 0.85rem;
}
.calibrate-results-table .calibrate-label {
  color: var(--color-text-muted);
  width: 40%;
}
.calibrate-results-table .calibrate-value {
  font-variant-numeric: tabular-nums;
}
.calibrate-results-table tfoot td {
  padding-top: 0.6rem;
  border-top: 1px solid var(--color-border);
  font-weight: 600;
}
.calibrate-results-table .calibrate-offset-value {
  color: var(--color-brand-blue);
}

.calibrate-saved-badge {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 500;
  color: var(--color-brand-green, #4caf50);
  margin-left: 0.5rem;
}

.camera-offset-badge {
  display: inline-block;
  font-size: 0.7rem;
  color: var(--color-text-muted);
  font-variant-numeric: tabular-nums;
}

.network-traffic-header {
  gap: 0.5rem;
  flex-wrap: wrap;
}

.network-traffic-title {
  font-size: 0.9rem;
  margin-right: 0.25rem;
}

.network-traffic-iface-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.8rem;
  padding: 0.2rem 0.6rem;
  border-radius: 999px;
  border: 1px solid;
  background: rgba(255, 255, 255, 0.03);
}

.network-traffic-iface-name {
  font-weight: 600;
  font-size: 0.75rem;
}

.network-traffic-rate {
  color: var(--color-text-secondary);
  font-variant-numeric: tabular-nums;
}
.network-traffic-rate small {
  font-size: 0.65rem;
  color: var(--color-text-muted);
}

.network-traffic-waiting {
  font-size: 0.8rem;
  color: var(--color-text-muted);
}

.network-traffic-chart-toggle {
  font-size: 0.75rem;
  color: var(--color-text-muted);
  cursor: pointer;
  text-align: center;
  padding: 0.25rem 0;
  margin-top: 0.25rem;
}
.network-traffic-chart-toggle:hover {
  color: var(--color-brand-blue);
}

.network-traffic-chart-container {
  margin-top: 0.25rem;
  border-radius: 4px;
  background: rgba(0, 0, 0, 0.15);
}
.network-traffic-chart-container canvas {
  display: block;
}

.htop-header {
  margin-bottom: 0.5rem;
}

.htop-title {
  font-size: 0.9rem;
}

.htop-cpu-columns {
  display: flex;
  gap: 0.75rem;
  margin-bottom: 0.35rem;
}

.htop-cpu-col {
  flex: 1;
  min-width: 0;
}

.htop-gauge {
  display: flex;
  align-items: center;
  margin-bottom: 0.35rem;
}
.htop-gauge:last-child {
  margin-bottom: 0;
}

.htop-gauge-label {
  width: 2.2em;
  text-align: right;
  color: var(--color-text-muted);
  flex-shrink: 0;
  padding-right: 0.4rem;
  font-size: 0.75rem;
  font-weight: 600;
}

.htop-gauge-bracket {
  display: none;
}

.htop-gauge-track {
  position: relative;
  flex-grow: 1;
  height: 18px;
  background: rgba(255, 255, 255, 0.05);
  border-radius: 4px;
  overflow: hidden;
}

.htop-gauge-segment {
  position: absolute;
  top: 0;
  height: 100%;
}

.htop-gauge-text {
  position: absolute;
  right: 6px;
  top: 0;
  height: 100%;
  display: flex;
  align-items: center;
  color: var(--color-text-secondary);
  font-size: 0.7rem;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
  text-shadow: 0 0 4px rgba(0, 0, 0, 0.6);
  z-index: 1;
}

.htop-user {
  background: var(--color-success);
}

.htop-system {
  background: var(--color-danger);
}

.htop-nice {
  background: var(--color-brand-blue);
}

.htop-mem-used {
  background: var(--color-brand-blue);
}

.htop-mem-buffers {
  background: var(--color-success);
}

.htop-mem-cached {
  background: var(--color-warning);
}

.htop-thermal-cool {
  background: var(--color-success);
}

.htop-thermal-warm {
  background: var(--color-warning);
}

.htop-thermal-hot {
  background: #e67e22;
}

.htop-thermal-critical {
  background: var(--color-danger);
}

.htop-gauge-thermal .htop-gauge-label {
  width: 7em;
  white-space: nowrap;
}

.htop-gpu-cool {
  background: var(--color-success);
}

.htop-gpu-warm {
  background: var(--color-warning);
}

.htop-gpu-hot {
  background: #e67e22;
}

.htop-gpu-critical {
  background: var(--color-danger);
}

.sysinfo-section {
  margin-top: 0.5rem;
}

.sysinfo-label {
  font-weight: 600;
  font-size: 0.75rem;
  color: var(--color-text-muted);
}

.sysinfo-value {
  font-size: 0.75rem;
  font-family: "SF Mono", "Fira Code", "Consolas", monospace;
  color: var(--color-brand-blue);
  white-space: pre-wrap;
  word-break: break-all;
}

.htop-swap-used {
  background: var(--color-danger);
}

.htop-legend-wrapper {
  position: relative;
}

.htop-legend-btn {
  background: none;
  border: none;
  color: var(--color-text-muted);
  cursor: pointer;
  padding: 2px 4px;
  font-size: 0.85rem;
  line-height: 1;
}
.htop-legend-btn:hover {
  color: var(--color-brand-blue);
}

.htop-legend-popup {
  display: none;
  position: absolute;
  right: 0;
  top: 100%;
  z-index: 10;
  background: var(--color-bg-elevated);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  padding: var(--spacing-sm) var(--spacing-md);
  min-width: 160px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}
.htop-legend-wrapper:hover .htop-legend-popup {
  display: block;
}

.htop-legend-section {
  display: flex;
  flex-direction: column;
  gap: 2px;
  margin-bottom: var(--spacing-sm);
}
.htop-legend-section:last-child {
  margin-bottom: 0;
}
.htop-legend-section strong {
  font-size: 0.65rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--color-text-muted);
  margin-bottom: 1px;
}

.htop-legend-item {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.7rem;
  color: var(--color-text-secondary);
}

.htop-legend-dot {
  width: 10px;
  height: 10px;
  border-radius: 2px;
  flex-shrink: 0;
}

@media (min-width: 992px) and (max-width: 1199.98px) {
  .navbar .navbar-brand {
    max-width: 150px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }
  .navbar .nav-link {
    padding-left: 0.3rem;
    padding-right: 0.3rem;
  }
  .navbar .navbar-nav {
    --bs-navbar-nav-link-padding-x: 0.3rem;
  }
  .navbar .clock, .navbar .clock-pop {
    display: none;
  }
}
.clock-pop {
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  z-index: 1035;
  min-width: 300px;
  padding: 0.75rem;
  font-size: 0.8rem;
  background: var(--color-bg-elevated);
  border: 1px solid var(--color-border-hover);
  border-radius: 0.5rem;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.45);
}
.clock-pop::before {
  content: "";
  position: absolute;
  top: -5px;
  right: 28px;
  width: 8px;
  height: 8px;
  background: var(--color-bg-elevated);
  border-left: 1px solid var(--color-border-hover);
  border-top: 1px solid var(--color-border-hover);
  transform: rotate(45deg);
}

.clock-pop-row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 0.3rem;
}

.clock-pop-label {
  color: var(--color-text-muted);
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.clock-pop-value {
  font-family: "SF Mono", monospace;
  color: var(--color-text-primary);
  white-space: nowrap;
}

.clock-pop-status {
  margin-top: 0.5rem;
  padding: 0.3rem 0.5rem;
  border-radius: 0.35rem;
  font-size: 0.75rem;
}
.clock-pop-status.is-ok {
  color: var(--color-success);
  background: rgba(34, 197, 94, 0.1);
}
.clock-pop-status.is-mismatch {
  color: var(--color-warning);
  background: rgba(245, 158, 11, 0.15);
  border: 1px solid rgba(245, 158, 11, 0.4);
}

.clock-pop-link {
  display: inline-block;
  margin-top: 0.5rem;
  font-size: 0.75rem;
  color: var(--color-brand-blue);
  text-decoration: none;
}
.clock-pop-link:hover {
  text-decoration: underline;
}

.whatsnew-beacon {
  position: relative;
}

.whatsnew-dot {
  position: absolute;
  top: 6px;
  right: 2px;
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--color-brand-blue);
  box-shadow: 0 0 0 2px rgba(1, 12, 28, 0.9);
  animation: whatsnewPulse 2s ease-in-out 3;
}

@keyframes whatsnewPulse {
  50% {
    transform: scale(1.5);
    opacity: 0.6;
  }
}
.whatsnew-nudge {
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  z-index: 1035;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 0.75rem;
  font-size: 0.8rem;
  color: var(--color-text-primary);
  background: var(--color-bg-elevated);
  border: 1px solid var(--color-brand-blue);
  border-radius: 0.5rem;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.45);
  cursor: pointer;
  white-space: nowrap;
}
.whatsnew-nudge::before {
  content: "";
  position: absolute;
  top: -5px;
  right: 18px;
  width: 8px;
  height: 8px;
  background: var(--color-bg-elevated);
  border-left: 1px solid var(--color-brand-blue);
  border-top: 1px solid var(--color-brand-blue);
  transform: rotate(45deg);
}

.whatsnew-beacon {
  display: inline-flex;
}

.navbar-nav .nav-item {
  position: relative;
}

.whatsnew-nudge-close {
  background: none;
  border: none;
  color: var(--color-text-muted);
  font-size: 1rem;
  line-height: 1;
  padding: 0 0.1rem;
  cursor: pointer;
}
.whatsnew-nudge-close:hover {
  color: var(--color-text-primary);
}

#whatsnew-panel {
  --bs-offcanvas-width: 430px;
  color: var(--color-text-primary);
  border-left: 1px solid var(--color-border);
}
#whatsnew-panel .offcanvas-title {
  font-family: "Gilroy", sans-serif;
  letter-spacing: 0.03em;
}

.wn-hero {
  padding: 0.75rem 1rem;
  margin-bottom: 1rem;
  border: 1px solid var(--color-border);
  border-radius: 0.6rem;
  background: linear-gradient(135deg, rgba(57, 179, 234, 0.14), rgba(57, 179, 234, 0.03));
}

.wn-hero-build {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.35rem;
}

.wn-hero-pill {
  background: var(--color-brand-blue);
  color: #fff;
  font-size: 0.7rem;
  font-weight: 700;
  padding: 0.15rem 0.5rem;
  border-radius: 1rem;
  letter-spacing: 0.04em;
}

.wn-hero-date {
  font-size: 0.7rem;
  color: var(--color-text-muted);
}

.wn-hero-title {
  font-family: "Gilroy", sans-serif;
  font-weight: 700;
  margin: 0;
}

.wn-section {
  margin-bottom: 1rem;
}

.wn-section-title {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--color-brand-blue);
  margin-bottom: 0.35rem;
}
.wn-section-title i {
  opacity: 0.8;
}

.wn-list {
  margin: 0;
  padding-left: 1.1rem;
  font-size: 0.85rem;
  color: var(--color-text-secondary);
}
.wn-list li {
  margin-bottom: 0.35rem;
}
.wn-list li::marker {
  color: var(--color-brand-blue);
}

.wn-history {
  margin-top: 1.25rem;
  border-top: 1px solid var(--color-border);
  padding-top: 0.75rem;
}

.wn-history-heading {
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--color-text-muted);
  margin-bottom: 0.5rem;
}

.wn-history-entry {
  border: 1px solid var(--color-border);
  border-radius: 0.4rem;
  padding: 0.4rem 0.6rem;
  margin-bottom: 0.4rem;
  font-size: 0.8rem;
}
.wn-history-entry summary {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  cursor: pointer;
  list-style: none;
}
.wn-history-entry summary::-webkit-details-marker {
  display: none;
}
.wn-history-entry .wn-history-build {
  font-weight: 700;
}
.wn-history-entry .wn-history-title {
  color: var(--color-text-secondary);
}
.wn-history-entry .wn-history-date {
  margin-left: auto;
  font-size: 0.7rem;
  color: var(--color-text-muted);
}

.buildinfo-release {
  margin-top: 0.5rem;
  padding: 0.5rem 0.65rem;
  border-left: 3px solid var(--color-brand-blue);
  background: var(--color-bg-elevated);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
}

.buildinfo-version {
  font-weight: 700;
  font-size: 1rem;
}

.buildinfo-subtitle {
  margin-left: 0.5rem;
  font-size: 0.85rem;
  color: var(--color-brand-blue);
}

.buildinfo-changelog {
  margin-top: 0.75rem;
}

.buildinfo-section-title {
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--color-brand-blue);
  margin-bottom: 0.15rem;
  margin-top: 0.6rem;
}

.buildinfo-list {
  font-size: 0.75rem;
  color: var(--color-text-muted);
  padding-left: 1.25rem;
  margin-bottom: 0;
}

.buildinfo-date {
  margin-left: 0.5rem;
  font-size: 0.75rem;
  color: var(--color-text-muted);
}

.buildinfo-history {
  margin-top: 1rem;
}

.buildinfo-history-entry {
  border-top: 1px solid var(--color-border);
  padding: 0.4rem 0;
}
.buildinfo-history-entry summary {
  cursor: pointer;
  list-style: none;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.8rem;
}
.buildinfo-history-entry summary::before {
  content: "▸";
  color: var(--color-text-muted);
  font-size: 0.7rem;
  transition: transform 0.15s ease;
}
.buildinfo-history-entry[open] summary::before {
  transform: rotate(90deg);
}
.buildinfo-history-entry .buildinfo-history-build {
  font-weight: 700;
}
.buildinfo-history-entry .buildinfo-history-title {
  color: var(--color-text-secondary, #aab);
}
.buildinfo-history-entry .buildinfo-history-date {
  margin-left: auto;
  font-size: 0.7rem;
  color: var(--color-text-muted);
}

.software-update-check {
  margin-top: 0.5rem;
}

.update-check-pill {
  display: inline-block;
  padding: 3px 10px;
  border-radius: 12px;
  font-size: 0.8rem;
  font-weight: 600;
}
.update-check-pill.update-check-current {
  background: rgba(40, 167, 69, 0.15);
  color: var(--color-success, #28a745);
}
.update-check-pill.update-check-behind {
  background: rgba(245, 158, 11, 0.15);
  color: #fcd34d;
}
.update-check-pill.update-check-unknown {
  background: var(--color-bg-elevated);
  color: var(--color-text-muted);
}

.lazy-section-loading {
  padding: 2rem;
  text-align: center;
  color: var(--color-text-muted);
}

.server-time-widget {
  display: none;
}

.server-time-warning {
  display: block;
  background: rgba(245, 158, 11, 0.15);
  border-color: rgba(245, 158, 11, 0.4);
}
.server-time-warning, .server-time-warning .server-time-title, .server-time-warning .server-time-content, .server-time-warning .server-time-content p {
  color: var(--color-warning);
}

.error-page {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 60vh;
  text-align: center;
  position: relative;
}

.error-page-orb {
  position: relative;
  width: 300px;
  height: 300px;
  margin-bottom: -2.5rem;
}
.error-page-orb img {
  width: 100%;
  height: 100%;
  opacity: 0.6;
  filter: drop-shadow(0 0 40px rgba(101, 0, 170, 0.4));
  animation: error-orb-pulse 4s ease-in-out infinite;
}

@keyframes error-orb-pulse {
  0%, 100% {
    opacity: 0.6;
    filter: drop-shadow(0 0 40px rgba(101, 0, 170, 0.4));
  }
  50% {
    opacity: 0.8;
    filter: drop-shadow(0 0 60px rgba(57, 179, 234, 0.4));
  }
}
.error-page-code {
  font-family: "Gilroy", -apple-system, BlinkMacSystemFont, sans-serif;
  font-size: 6rem;
  font-weight: 900;
  letter-spacing: 0.05em;
  line-height: 1;
  background: linear-gradient(135deg, var(--color-brand-blue), var(--color-brand-light));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: 0.25rem;
}

.error-page-icon {
  font-size: 1.5rem;
  color: var(--color-text-muted);
  margin-bottom: 0.75rem;
}

.error-page-message {
  font-size: 1.1rem;
  color: var(--color-text-muted);
  max-width: 400px;
}

.fab-submit {
  position: fixed;
  right: max(var(--spacing-lg), 50% - 360px - 48px);
  top: 50%;
  transform: translateY(-50%);
  z-index: 1000;
  width: 96px;
  height: 96px;
  border-radius: 50%;
  border: 10px solid var(--color-bg-primary);
  cursor: pointer;
  background-color: var(--color-success);
  color: white;
  font-size: 1.2rem;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform var(--transition-fast), background-color var(--transition-fast);
}
.fab-submit .fab-submit-icon {
  width: 48px !important;
  height: 48px !important;
}
.fab-submit {
  box-shadow: var(--shadow-lg);
}
.fab-submit::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 50%;
  opacity: 0;
  box-shadow: 0 0 20px rgba(119, 179, 0, 0.5);
  transition: opacity var(--transition-fast);
  pointer-events: none;
}
.fab-submit:hover {
  background-color: #669900;
  transform: translateY(-50%) scale(1.1);
}
.fab-submit:hover::after {
  opacity: 1;
}
.fab-submit:active {
  transform: translateY(-50%) scale(0.95);
}
.fab-submit img {
  width: 48px;
  height: 48px;
}
@media (min-width: 992px) {
  .fab-submit {
    right: max(var(--spacing-lg), 50% - 480px - 48px);
  }
}
@media (min-width: 1200px) {
  .fab-submit {
    right: max(var(--spacing-lg), 50% - 570px - 48px);
  }
}
@media (min-width: 1400px) {
  .fab-submit {
    right: max(var(--spacing-lg), 50% - 660px - 48px);
  }
}
@media (max-width: 767.98px) {
  .fab-submit {
    top: auto;
    bottom: var(--spacing-lg);
    transform: none;
  }
  .fab-submit:hover {
    transform: scale(1.1);
  }
  .fab-submit:active {
    transform: scale(0.95);
  }
}
.fab-submit.fab-left {
  right: auto;
  left: max(var(--spacing-lg), 50% - 360px - 73px);
}
@media (min-width: 992px) {
  .fab-submit.fab-left {
    left: max(var(--spacing-lg), 50% - 480px - 73px);
  }
}
@media (min-width: 1200px) {
  .fab-submit.fab-left {
    left: max(var(--spacing-lg), 50% - 570px - 73px);
  }
}
@media (min-width: 1400px) {
  .fab-submit.fab-left {
    left: max(var(--spacing-lg), 50% - 660px - 73px);
  }
}
.fab-submit.fab-brand {
  background-color: var(--color-brand-blue);
}
.fab-submit.fab-brand::after {
  box-shadow: 0 0 20px rgba(57, 179, 234, 0.5);
}
.fab-submit.fab-brand:hover {
  background-color: var(--color-brand-blue-dark);
}

.sbt-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: var(--spacing-sm);
}

.sbt-card {
  background: var(--color-bg-elevated);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  overflow: hidden;
  position: relative;
  transition: border-color 0.15s;
}
.sbt-card:hover {
  border-color: var(--color-brand-blue);
}

.sbt-thumb {
  display: block;
  position: relative;
  aspect-ratio: 16/6;
  background: var(--color-bg-primary);
  cursor: pointer;
  overflow: hidden;
}
.sbt-thumb iframe {
  position: absolute;
  width: 1920px;
  height: 1080px;
  border: 0;
  transform-origin: top left;
  pointer-events: none;
}

.sbt-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, 0.3);
  opacity: 0;
  transition: opacity 0.2s;
}
.sbt-thumb:hover .sbt-overlay {
  opacity: 1;
}
.sbt-overlay i {
  width: 46px;
  height: 46px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.05rem;
  color: #fff;
  background: var(--color-brand-blue);
  border-radius: 50%;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.45);
}

.sbt-info {
  padding: 6px 8px 0;
  font-size: 0.8rem;
  min-width: 0;
}

.sbt-name {
  color: var(--color-text-primary);
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.sbt-name .fa-lock {
  color: var(--color-text-muted);
  font-size: 0.7rem;
}

.sbt-meta {
  color: var(--color-text-muted);
  font-size: 0.75rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.sbt-actions {
  display: flex;
  justify-content: flex-end;
  gap: var(--spacing-xs);
  padding: 4px 8px 6px;
}
.sbt-actions button,
.sbt-actions a {
  background: none;
  border: 1px solid var(--color-border);
  color: var(--color-text-secondary);
  border-radius: var(--radius-sm);
  width: 28px;
  height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 0.8rem;
  text-decoration: none;
}

.sbt-edit:hover,
.sbt-duplicate:hover,
.sbt-share:hover {
  border-color: var(--color-brand-blue);
  color: var(--color-brand-blue);
}

.sbt-org-chip {
  display: inline-flex;
  vertical-align: -3px;
  margin-right: 4px;
}

.sbt-section-header {
  display: flex;
  align-items: center;
  gap: var(--spacing-xs);
  margin-bottom: var(--spacing-sm);
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  color: var(--color-text-secondary);
}

.sbt-section-count {
  color: var(--color-text-muted);
  font-weight: 400;
}

.sbt-delete:hover {
  border-color: var(--bs-danger);
  color: var(--bs-danger);
}

.sbe-title {
  font-family: "Gilroy", sans-serif;
  font-size: 1.1rem;
  font-weight: 700;
}

.sbe-name-input {
  background: transparent;
  border: 1px dashed transparent;
  border-radius: var(--radius-sm);
  color: inherit;
  font-family: "Gilroy", sans-serif;
  font-size: 1.1rem;
  font-weight: 700;
  padding: 2px 8px;
  margin-left: var(--spacing-md);
  min-width: 200px;
  flex: 0 1 auto;
}
.sbe-name-input:hover {
  border-color: var(--color-border-hover);
}
.sbe-name-input:focus {
  border-color: var(--color-brand-blue);
  outline: none;
  background: rgba(255, 255, 255, 0.05);
}

.sbe-saved {
  color: var(--color-success);
  font-size: 0.8rem;
  font-weight: 600;
  opacity: 0;
  transition: opacity 200ms ease;
}
.sbe-saved.show {
  opacity: 1;
}

#sbe-stage {
  --sbe-margin: 4%;
  position: relative;
  width: 100%;
  aspect-ratio: 16/9;
  border-radius: var(--radius-md);
  overflow: hidden;
  background: var(--color-bg-primary) center/cover;
  border: 1px solid var(--color-border);
}

#sbe-preview {
  position: absolute;
  top: 0;
  left: 0;
  width: 1920px;
  height: 1080px;
  border: 0;
  transform-origin: top left;
  pointer-events: none;
}

#sbe-safe-area {
  position: absolute;
  inset: var(--sbe-margin);
  border: 1px dashed rgba(255, 255, 255, 0.18);
  border-radius: 4px;
  pointer-events: none;
}

#sbe-anchors {
  position: absolute;
  inset: var(--sbe-margin);
  pointer-events: none;
  opacity: 0;
  transition: opacity var(--transition-fast);
}
.sbe-dragging #sbe-anchors {
  opacity: 1;
}

.sbe-anchor-dot {
  position: absolute;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.4);
  box-shadow: 0 0 6px rgba(0, 0, 0, 0.6);
  transform: translate(-50%, -50%);
  transition: background var(--transition-fast), transform var(--transition-fast);
}
.sbe-anchor-dot.active {
  background: var(--color-brand-blue);
  transform: translate(-50%, -50%) scale(1.5);
}
.sbe-anchor-dot[data-anchor=top_left] {
  top: 0;
  left: 0;
}
.sbe-anchor-dot[data-anchor=top_center] {
  top: 0;
  left: 50%;
}
.sbe-anchor-dot[data-anchor=top_right] {
  top: 0;
  left: 100%;
}
.sbe-anchor-dot[data-anchor=middle_left] {
  top: 50%;
  left: 0;
}
.sbe-anchor-dot[data-anchor=center] {
  top: 50%;
  left: 50%;
}
.sbe-anchor-dot[data-anchor=middle_right] {
  top: 50%;
  left: 100%;
}
.sbe-anchor-dot[data-anchor=bottom_left] {
  top: 100%;
  left: 0;
}
.sbe-anchor-dot[data-anchor=bottom_center] {
  top: 100%;
  left: 50%;
}
.sbe-anchor-dot[data-anchor=bottom_right] {
  top: 100%;
  left: 100%;
}

#sbe-drag {
  position: absolute;
  inset: 0;
  cursor: crosshair;
  touch-action: none;
}

.sbe-hint {
  color: var(--color-text-muted);
  font-size: 0.78rem;
}

.sbe-slot-pill {
  padding: var(--spacing-xs) var(--spacing-md);
  font-size: 0.8rem;
  font-weight: 500;
  border-radius: var(--radius-xl);
  border: 1px solid var(--color-border);
  background: var(--color-bg-elevated);
  color: var(--color-text-secondary);
  cursor: pointer;
  transition: all var(--transition-fast);
}
.sbe-slot-pill:hover {
  border-color: var(--color-border-hover);
}
.sbe-slot-pill.active {
  background: var(--color-brand-blue);
  border-color: var(--color-brand-blue);
  color: #fff;
}

@media (min-width: 992px) {
  .sbe-sticky {
    position: sticky;
    top: 70px;
  }
}
.sbe-panel {
  background: var(--color-bg-secondary);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  padding: var(--spacing-sm) var(--spacing-md) var(--spacing-md);
}
.sbe-panel + .sbe-panel {
  margin-top: var(--spacing-sm);
}

.sbe-val {
  color: var(--color-text-muted);
  font-weight: 400;
  margin-left: var(--spacing-xs);
  font-variant-numeric: tabular-nums;
}

.sbe-theme-btn {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 0.25rem 0.5rem;
  font-size: 0.875rem;
  color: var(--color-text);
  background: var(--color-bg-elevated);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  cursor: pointer;
}
.sbe-theme-btn:hover {
  border-color: var(--color-brand-blue);
}
.sbe-theme-btn:disabled {
  opacity: 0.65;
  cursor: default;
}
.sbe-theme-btn i {
  font-size: 0.65rem;
  color: var(--color-text-muted);
}

.sbe-theme-card {
  cursor: pointer;
}
.sbe-theme-card.selected {
  outline: 2px solid var(--color-brand-blue);
  outline-offset: 2px;
  border-radius: var(--radius-md);
}

.sbe-color-swatch {
  width: 100%;
  padding-right: 44px;
}

.sbe-grad-add,
.sbe-grad-remove {
  padding: 2px 8px;
  font-size: 0.7rem;
  color: var(--color-text-muted);
  border: 1px dashed var(--color-border-hover);
  background: transparent;
}
.sbe-grad-add:hover,
.sbe-grad-remove:hover {
  color: var(--color-brand-blue);
  border-color: var(--color-brand-blue);
}

.sbe-grad-add {
  margin-top: 4px;
}

.sbe-grad-remove {
  border-style: solid;
  flex-shrink: 0;
}

.sbe-grad-angle {
  width: 62px;
  flex-shrink: 0;
}

.form-range {
  height: 1.1rem;
}
.form-range::-webkit-slider-runnable-track {
  height: 6px;
  border-radius: 3px;
  border: 1px solid var(--color-border);
  background: linear-gradient(to right, var(--color-brand-blue) 0%, var(--color-brand-blue) var(--rp, 0%), var(--color-bg-primary) var(--rp, 0%));
}
.form-range::-webkit-slider-thumb {
  width: 16px;
  height: 16px;
  margin-top: -6px;
  border: none;
  border-radius: 50%;
  background: var(--color-brand-blue);
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.5);
  transition: transform var(--transition-fast), background var(--transition-fast);
}
.form-range:hover::-webkit-slider-thumb {
  transform: scale(1.15);
}
.form-range:focus {
  outline: none;
}
.form-range:focus::-webkit-slider-thumb {
  box-shadow: 0 0 0 3px rgba(var(--color-brand-blue-rgb), 0.25);
}
.form-range:disabled::-webkit-slider-thumb {
  background: var(--color-text-muted);
}
.form-range::-moz-range-track {
  height: 6px;
  border-radius: 3px;
  border: 1px solid var(--color-border);
  background: var(--color-bg-primary);
}
.form-range::-moz-range-progress {
  height: 6px;
  border-radius: 3px;
  background: var(--color-brand-blue);
}
.form-range::-moz-range-thumb {
  width: 16px;
  height: 16px;
  border: none;
  border-radius: 50%;
  background: var(--color-brand-blue);
}

.sbw-summary {
  display: flex;
  align-items: center;
  gap: var(--spacing-md);
  flex-wrap: wrap;
}

.sbw-team {
  display: flex;
  align-items: center;
  gap: var(--spacing-sm);
  min-width: 0;
}

.sbw-logo {
  width: 28px;
  height: 28px;
  object-fit: contain;
  display: none;
}

.sbw-name {
  font-family: "Gilroy", sans-serif;
  font-weight: 700;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.sbw-score {
  font-size: 1.4rem;
  font-weight: 800;
  font-variant-numeric: tabular-nums;
}

.sbw-clockwrap {
  margin-left: auto;
  display: flex;
  align-items: baseline;
  gap: var(--spacing-sm);
}

.sbw-clock {
  font-size: 1.4rem;
  font-weight: 800;
  font-variant-numeric: tabular-nums;
  color: var(--color-brand-blue);
}

.sbw-period {
  color: var(--color-text-muted);
  font-size: 0.85rem;
}

.sbw-feed-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-left: var(--spacing-md);
  padding: 2px 8px;
  border: 1px solid var(--color-border);
  border-radius: 999px;
  font-size: 0.72rem;
  color: var(--color-text-muted);
}

.sbw-feed-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--color-text-muted);
}
.sbw-feed-badge.fresh .sbw-feed-dot {
  background: var(--color-success, #2fbf71);
}
.sbw-feed-badge.stale .sbw-feed-dot {
  background: var(--color-danger, #e63946);
}

#sbf-preview-wrap {
  position: relative;
  width: 100%;
  aspect-ratio: 16/5;
  overflow: hidden;
  border-radius: var(--radius-sm);
  background: var(--color-bg-primary);
  border: 1px solid var(--color-border);
}

#sbf-preview {
  position: absolute;
  width: 1920px;
  height: 1080px;
  border: 0;
  transform-origin: top left;
  pointer-events: none;
}

.sbf-logo-btn {
  height: 38px;
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 0 12px;
  flex-shrink: 0;
  border: 1px dashed var(--color-border-hover);
  background: var(--color-bg-elevated);
  color: var(--color-text-secondary);
}
.sbf-logo-btn:hover {
  border-color: var(--color-brand-blue);
  color: var(--color-brand-blue);
  background: var(--color-bg-elevated);
}
.sbf-logo-btn.has-logo {
  border-style: solid;
}

.sbf-logo-thumb {
  max-width: 30px;
  max-height: 28px;
  object-fit: contain;
  display: none;
}

.sbf-logo-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(72px, 1fr));
  gap: var(--spacing-sm);
}

.sbf-logo-tile {
  aspect-ratio: 1;
  border: 2px solid var(--color-border);
  border-radius: var(--radius-sm);
  background: var(--color-bg-elevated);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: border-color var(--transition-fast);
}
.sbf-logo-tile:hover {
  border-color: var(--color-brand-blue);
}
.sbf-logo-tile img {
  max-width: 80%;
  max-height: 80%;
  object-fit: contain;
}

.sbw-panes {
  display: none;
  gap: var(--spacing-sm);
  margin-top: var(--spacing-sm);
  align-items: stretch;
  flex-wrap: wrap;
}
.sbw-panes.open {
  display: flex;
}

.sbw-preview {
  position: relative;
  flex: 1 1 480px;
  min-width: 320px;
  height: 96px;
  align-self: flex-start;
  transition: height 150ms ease;
  overflow: hidden;
  border-radius: var(--radius-sm);
  background: var(--color-bg-primary);
  border: 1px solid var(--color-border);
}
.sbw-preview iframe {
  position: absolute;
  top: 0;
  left: 0;
  width: 1920px;
  height: 1080px;
  border: 0;
  transform-origin: top left;
  pointer-events: none;
}

.sbw-console {
  flex: 0 1 440px;
  min-width: 340px;
  min-height: 400px;
  border-radius: var(--radius-sm);
  overflow: hidden;
  border: 1px solid var(--color-border);
}
.sbw-console iframe {
  width: 100%;
  height: 100%;
  border: 0;
}

#sbw-preview-toggle.active {
  background-color: var(--color-brand-blue);
  border-color: var(--color-brand-blue);
  color: #fff;
}

.sblm-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  gap: var(--spacing-sm);
}

.sblm-tile {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  padding: var(--spacing-sm);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  background: var(--color-bg-elevated);
}
.sblm-tile:hover .sblm-delete {
  opacity: 1;
}

.sblm-img {
  height: 72px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.sblm-img img {
  max-height: 64px;
  max-width: 110px;
  object-fit: contain;
}

.sblm-name {
  width: 100%;
  text-align: center;
  font-size: 0.8rem;
  color: var(--color-text);
  background: transparent;
  border: 1px solid transparent;
  border-radius: var(--radius-sm);
  padding: 4px 6px;
}
.sblm-name:hover {
  border-color: var(--color-border-hover);
}
.sblm-name:focus {
  outline: none;
  background: var(--color-bg);
  border-color: var(--color-brand-blue);
}

.sblm-delete {
  position: absolute;
  top: 4px;
  right: 4px;
  border: 0;
  background: transparent;
  color: var(--color-text-muted);
  font-size: 0.8rem;
  padding: 4px 6px;
  opacity: 0;
  transition: opacity var(--transition-fast), color var(--transition-fast);
  cursor: pointer;
}
.sblm-delete:hover {
  color: var(--color-danger);
}

.sblm-orgs {
  position: absolute;
  top: 4px;
  left: 4px;
  display: flex;
  align-items: center;
  gap: 3px;
  border: 0;
  background: transparent;
  color: var(--color-text-muted);
  font-size: 0.8rem;
  padding: 4px 6px;
  cursor: pointer;
  transition: color var(--transition-fast);
}
.sblm-orgs:hover {
  color: var(--color-brand-blue);
}

.sblm-orgs-count {
  background: var(--color-brand-blue);
  color: #fff;
  border-radius: 999px;
  font-size: 0.6rem;
  font-weight: 700;
  padding: 1px 5px;
  line-height: 1.2;
}

.pill-burn-badge {
  margin-left: 6px;
  color: var(--color-brand-blue);
  font-size: 0.7rem;
}

.toggle-pill input:checked + .pill-label .pill-burn-badge {
  color: #fff;
}

.pill-slate-badge {
  color: var(--color-text-muted);
  font-size: 0.7rem;
}

.toggle-pill input:checked + .pill-label .pill-slate-badge {
  color: #fff;
}

.pill-live-icon {
  color: var(--color-success);
  font-size: 0.7rem;
  animation: livePulse 2s ease-in-out infinite;
}

.toggle-pill input:checked + .pill-label .pill-live-icon {
  color: #fff;
}

@keyframes livePulse {
  50% {
    opacity: 0.45;
  }
}
.form-check-input {
  background-color: var(--color-bg-elevated);
  border-color: var(--color-border-hover);
}
.form-check-input:checked {
  background-color: var(--color-brand-blue);
  border-color: var(--color-brand-blue);
}
.form-check-input:focus {
  border-color: var(--color-brand-blue);
  box-shadow: 0 0 0 3px rgba(var(--color-brand-blue-rgb), 0.15);
}

.form-switch .form-check-input {
  background-color: var(--color-bg-hover);
  border-color: rgba(255, 255, 255, 0.28);
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='-4 -4 8 8'%3e%3ccircle r='3' fill='%23a1a1aa'/%3e%3c/svg%3e");
}
.form-switch .form-check-input:focus {
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='-4 -4 8 8'%3e%3ccircle r='3' fill='%2339B3EA'/%3e%3c/svg%3e");
}
.form-switch .form-check-input:checked {
  background-color: var(--color-brand-blue);
  border-color: var(--color-brand-blue);
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='-4 -4 8 8'%3e%3ccircle r='3' fill='%23fff'/%3e%3c/svg%3e");
}

.marker-stars-cell .marker-stars {
  display: inline-flex;
  gap: 1px;
  color: #f5c542;
  font-size: 0.7rem;
}

.marker-qual-badge .marker-qual-attr {
  display: inline-block;
  margin-left: 6px;
  padding-left: 6px;
  border-left: 1px solid rgba(255, 255, 255, 0.45);
  font-weight: 400;
  opacity: 0.9;
}

.marker-qual-badge .marker-qual-attr-xy {
  margin-left: 3px;
  opacity: 0.75;
  font-variant-numeric: tabular-nums;
}

.pitch-map-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.pitch-map-card {
  position: relative;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 8px 10px;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  background: var(--color-bg-secondary);
  transition: border-color 0.15s;
}
.pitch-map-card:hover {
  border-color: var(--color-brand-blue);
}
.pitch-map-card .card-actions {
  position: relative;
  z-index: 2;
  margin-left: auto;
  display: flex;
  gap: 4px;
}

.pitch-map-thumb {
  width: 96px;
  flex-shrink: 0;
}
.pitch-map-thumb svg {
  width: 100%;
  height: auto;
}

.pitch-map-text {
  min-width: 0;
}

.pitch-map-name {
  font-weight: 600;
  font-size: 0.9rem;
}

.pitch-map-default-badge {
  background: var(--color-brand-blue);
  color: #fff;
  font-size: 0.6rem;
  vertical-align: middle;
}

.pitch-map-detail {
  font-size: 0.75rem;
  color: var(--color-text-muted);
}

.pitch-map-preview {
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  background: var(--color-bg-secondary);
  padding: 8px;
}
.pitch-map-preview svg {
  width: 100%;
  height: auto;
}

.session-pitch-map {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.spm-controls {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}
.spm-controls .spm-select {
  width: auto;
  max-width: 220px;
}
.spm-controls .spm-btn.active {
  background: var(--color-brand-blue);
  border-color: var(--color-brand-blue);
  color: #fff;
}

.spm-map {
  background: var(--color-bg-elevated);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  padding: 8px;
  max-width: 900px;
}
.spm-map svg {
  width: 100%;
  height: auto;
  display: block;
}

.spm-foot {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  font-size: 0.75rem;
  color: var(--color-text-muted);
}

.form-group.is-disabled {
  opacity: 0.45;
}
.form-group.is-disabled .icon-checkbox, .form-group.is-disabled .icon-checkbox-compact {
  cursor: not-allowed;
}

.icon-checkbox input:disabled ~ .checkbox-icon, .icon-checkbox-compact input:disabled ~ .checkbox-icon,
.icon-checkbox input:disabled ~ .checkbox-label,
.icon-checkbox-compact input:disabled ~ .checkbox-label {
  cursor: not-allowed;
}

.ptr-indicator {
  position: fixed;
  top: calc(env(safe-area-inset-top, 0px) + 8px);
  left: 50%;
  z-index: 3000;
  width: 40px;
  height: 40px;
  margin-top: -20px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--color-bg-elevated);
  border: 1px solid var(--color-border);
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.35);
  color: var(--color-text-secondary);
  opacity: 0;
  transform: translate(-50%, 0);
  transition: color 0.15s ease;
  pointer-events: none;
}
.ptr-indicator.is-armed, .ptr-indicator.is-loading {
  color: var(--color-brand-blue);
}
.ptr-indicator.is-loading i {
  animation: ptr-spin 0.8s linear infinite;
}

@keyframes ptr-spin {
  to {
    transform: rotate(360deg);
  }
}
.session-list img.thumbnail.is-pending {
  opacity: 0.45;
  filter: grayscale(1);
  animation: thumb-pending 1.6s ease-in-out infinite;
}

@keyframes thumb-pending {
  50% {
    opacity: 0.2;
  }
}
.navbar.fixed-top {
  top: env(safe-area-inset-top, 0px);
}