/*
 * StreamFlow v2.1 - Live Streaming Lewat VPS
 * 
 * Custom Features & UI Components
 * Created by: Bang Tutorial
 * GitHub: https://github.com/bangtutorial

 * © 2026 Bang Tutorial - All rights reserved
 */

@font-face {
  font-family: 'tabler-icons';
  src: url('https://cdn.jsdelivr.net/npm/@tabler/icons-webfont@2.30.0/fonts/tabler-icons.woff2') format('woff2');
  font-display: block;
  font-weight: normal;
  font-style: normal;
}

.ti {
  font-family: 'tabler-icons' !important;
  visibility: visible !important;
  opacity: 1;
}

.sidebar-icon {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 0.75rem;
  padding: 0.625rem 0.875rem;
  margin-bottom: 0.25rem;
  color: #AFAFAF;
  font-size: 0.875rem;
  font-weight: 500;
  border-radius: 0.5rem;
  transition-property: all;
  transition-timing-function: linear;
  transition-duration: 200ms;
  cursor: pointer;
}

.sidebar-icon:hover {
  background-color: var(--primary-color);
  color: white;
}

.sidebar-icon.bg-primary {
  color: white;
}

:root {
  --primary-color: #E8102A;
}

body {
  font-family: 'Inter', sans-serif;
}

.modal-overlay {
  backdrop-filter: blur(4px);
  transition: opacity 0.2s ease-in-out;
}

.modal-container {
  transform: scale(0.95);
  opacity: 0;
  transition: all 0.2s ease-in-out;
}

.modal-overlay.active {
  opacity: 1;
}

.modal-overlay.active .modal-container {
  transform: scale(1);
  opacity: 1;
}

[onclick^="setVideoOrientation"] {
  position: relative;
  overflow: hidden;
}

[onclick^="setVideoOrientation"]:before {
  content: '';
  position: absolute;
  inset: 0;
  background: var(--primary-color);
  opacity: 0;
  transition: opacity 0.2s ease-in-out;
}

[onclick^="setVideoOrientation"].bg-primary:before {
  opacity: 0.1;
}

[onclick^="setVideoOrientation"]:hover:before {
  opacity: 0.05;
}

[onclick^="setVideoOrientation"] i {
  transition: transform 0.2s ease-in-out;
}

[onclick^="setVideoOrientation"]:active i {
  transform: scale(0.9);
}

/* Custom Scrollbar */
.custom-scrollbar::-webkit-scrollbar {
  width: 8px;
}

.custom-scrollbar::-webkit-scrollbar-track {
  background: #374151;
  border-radius: 4px;
}

.custom-scrollbar::-webkit-scrollbar-thumb {
  background: #6b7280;
  border-radius: 4px;
  transition: background 0.2s ease;
}

.custom-scrollbar::-webkit-scrollbar-thumb:hover {
  background: #9ca3af;
}

.custom-scrollbar {
  scrollbar-width: thin;
  scrollbar-color: #6b7280 #374151;
}

/* Spin Animation - Use Tailwind's built-in or define if needed */
@keyframes spin {
  0% {
    transform: rotate(0deg);
  }
  100% {
    transform: rotate(360deg);
  }
}

.ti.animate-spin {
  animation: spin 1s linear infinite !important;
  display: inline-block;
}

@media (max-width: 768px) {
  .modal-container {
    margin: 1rem;
    max-height: calc(100vh - 2rem);
    overflow-y: auto;
  }
  
  .grid-cols-2 {
    grid-template-columns: 1fr;
  }
  
  .grid-cols-3 {
    grid-template-columns: repeat(2, 1fr);
  }
  
  .modal-form-group {
    margin-bottom: 1rem;
  }
  
  .modal-input {
    padding: 0.75rem;
    font-size: 16px;
  }
}
/* Native <select> dropdown popups: declare a dark UI scheme so Windows/Chrome
   stops painting them light, and on browsers with customizable select
   (Chrome/Edge 131+) restyle the option list — dark panel, Kumix-red hover.
   Long labels stay on a single line (nowrap) instead of wrapping to two.
   Browsers without support keep their native popup untouched. */
:root {
  color-scheme: dark;
}

select,
::picker(select) {
  appearance: base-select;
}

::picker(select) {
  background-color: #252525;
  border: 1px solid #3D3D3D;
  border-radius: 8px;
  padding: 4px;
}

select option {
  background-color: #252525;
  color: #fff;
  border-radius: 6px;
  padding: 8px 12px;
  white-space: nowrap;
}

select option:hover,
select option:focus,
select option:checked {
  background-color: #E8102A;
  color: #fff;
}

/* closed select button: keep the selected label on one line too */
select {
  white-space: nowrap;
}
