/*
 * This is a manifest file that'll be compiled into application.css.
 *
 * With Propshaft, assets are served efficiently without preprocessing steps. You can still include
 * application-wide styles in this file, but keep in mind that CSS precedence will follow the standard
 * cascading order, meaning styles declared later in the document or manifest will override earlier ones,
 * depending on specificity.
 *
 * Consider organizing styles into separate files for maintainability.
 */

@tailwind utilities;

:root {
  --background-color: #ffffff;
  --text-color: #000000;
  --primary-color: #005CFF;
  --accent-color: #005CFF;
  --secondary-background: #F2F6F7;
  --secondary-text-color: #899DA3;
  --hover-color: #dedede
}

[data-theme="dark"] {
  --background-color: #333333;
  --text-color: #ffffff;
  --primary-color: #005CFF;
  --accent-color: #F2F6F7;
  --secondary-background: #181818;
  --secondary-text-color: #899DA3;
  --hover-color: #1a1a1a;
}

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

h1, h2, h3, h4, h5, h6 {
  font-family: 'Geist', sans-serif;
}

.font-mono-light {
  font-family: 'Geist', sans-serif;
  font-weight: 300;
}

.font-mono-regular {
  font-family: 'Geist', sans-serif;
  font-weight: 400;
}

.font-mono-semibold {
  font-family: 'Geist', sans-serif;
  font-weight: 600;
}

.font-geist-light {
  font-family: 'Geist', sans-serif;
  font-weight: 300;
}

.font-geist-regular {
  font-family: 'Geist', sans-serif;
  font-weight: 400;
}

.font-geist-semibold {
  font-family: 'Geist', sans-serif;
  font-weight: 600;
}

.sidebar-main-scroll {
  direction: rtl;
}

.sidebar-main-scroll > * {
  direction: ltr;
}

.sidebar-scroll {
  overflow-y: auto;
  max-height: 160px;
  padding-right: 4px;
  scrollbar-width: thin;
  scrollbar-color: var(--primary-color) var(--hover-color);
  scroll-behavior: smooth;
}

.sidebar-scroll::-webkit-scrollbar {
  width: 8px;
  background: var(--hover-color);
  border-radius: 8px;
}

.sidebar-scroll::-webkit-scrollbar-thumb {
  background: linear-gradient(135deg, var(--primary-color) 60%, var(--accent-color) 100%);
  border-radius: 8px;
  min-height: 24px;
  border: 2px solid var(--hover-color);
  transition: background 0.2s;
}
.sidebar-main-scroll::-webkit-scrollbar {
  width: 8px;
  background: var(--hover-color);
  border-radius: 8px;
}

.sidebar-main-scroll::-webkit-scrollbar-thumb {
  background: linear-gradient(135deg, var(--primary-color) 60%, var(--accent-color) 100%);
  border-radius: 8px;
  min-height: 24px;
  border: 2px solid var(--hover-color);
  transition: background 0.2s;
}

/* Dashboard Enhanced Styles */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes slideIn {
  from {
    opacity: 0;
    transform: translateX(-20px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

.chart-container {
  animation: fadeInUp 0.6s ease-out;
}

.chart-container:nth-child(1) { animation-delay: 0.1s; }
.chart-container:nth-child(2) { animation-delay: 0.2s; }
.chart-container:nth-child(3) { animation-delay: 0.3s; }
.chart-container:nth-child(4) { animation-delay: 0.4s; }

.skeleton-loader {
  animation: slideIn 0.3s ease-out;
}

/* Enhanced hover effects for dashboard elements */
.group:hover .group-hover\:scale-105 {
  transform: scale(1.05);
}

/* Smooth transitions for dropdown chevrons */
.dropdown-open .transition-transform {
  transform: rotate(180deg);
}

/* Custom scrollbar for year dropdown */
.max-h-60::-webkit-scrollbar {
  width: 6px;
}

.max-h-60::-webkit-scrollbar-track {
  background: var(--hover-color);
  border-radius: 3px;
}

.max-h-60::-webkit-scrollbar-thumb {
  background: var(--primary-color);
  border-radius: 3px;
}

.max-h-60::-webkit-scrollbar-thumb:hover {
  background: var(--accent-color);
}

/* DJ Control Panel Styles */
.dj-control-group {
  padding: 1rem;
  background: var(--background-color);
  border: 1px solid var(--secondary-text-color);
  border-opacity: 0.2;
  border-radius: 0.75rem;
  transition: all 0.2s ease;
}

.dj-control-group:hover {
  border-color: var(--primary-color);
  border-opacity: 0.3;
  box-shadow: 0 4px 12px rgba(0, 92, 255, 0.1);
}

/* Custom Range Slider Styles */
input[type="range"] {
  -webkit-appearance: none;
  background: transparent;
}

input[type="range"]::-webkit-slider-track {
  background: var(--hover-color);
  height: 8px;
  border-radius: 4px;
}

input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none;
  height: 20px;
  width: 20px;
  border-radius: 50%;
  background: var(--primary-color);
  cursor: pointer;
  box-shadow: 0 2px 6px rgba(0, 92, 255, 0.3);
  transition: all 0.2s ease;
}

input[type="range"]::-webkit-slider-thumb:hover {
  transform: scale(1.1);
  box-shadow: 0 4px 12px rgba(0, 92, 255, 0.4);
}

input[type="range"]::-moz-range-track {
  background: var(--hover-color);
  height: 8px;
  border-radius: 4px;
  border: none;
}

input[type="range"]::-moz-range-thumb {
  height: 20px;
  width: 20px;
  border-radius: 50%;
  background: var(--primary-color);
  cursor: pointer;
  border: none;
  box-shadow: 0 2px 6px rgba(0, 92, 255, 0.3);
  transition: all 0.2s ease;
}

input[type="range"]::-moz-range-thumb:hover {
  transform: scale(1.1);
  box-shadow: 0 4px 12px rgba(0, 92, 255, 0.4);
}

/* Custom Checkbox Styles */
input[type="checkbox"] {
  cursor: pointer;
  transition: all 0.2s ease;
}

input[type="checkbox"]:checked {
  background-color: var(--primary-color);
  border-color: var(--primary-color);
}

input[type="checkbox"]:hover {
  transform: scale(1.05);
}

/* Mindmap specific animations */
@keyframes djPulse {
  0%, 100% { opacity: 0.6; }
  50% { opacity: 1; }
}

.dj-control-group:active {
  transform: translateY(1px);
}

/* Text wrapping for long node names */
.mindmap-text {
  word-wrap: break-word;
  hyphens: auto;
  max-width: 200px;
}

/* Layout optimizations */
.mindmap-layout {
  height: calc(100vh - 2rem);
}

/* DJ Control Panel specific scrollbar */
.mindmap-layout .overflow-y-auto {
  scrollbar-width: thin;
  scrollbar-color: var(--primary-color) transparent;
}

.mindmap-layout .overflow-y-auto::-webkit-scrollbar {
  width: 4px;
}

.mindmap-layout .overflow-y-auto::-webkit-scrollbar-track {
  background: transparent;
}

.mindmap-layout .overflow-y-auto::-webkit-scrollbar-thumb {
  background-color: var(--primary-color);
  border-radius: 2px;
  opacity: 0.5;
}

.mindmap-layout .overflow-y-auto::-webkit-scrollbar-thumb:hover {
  opacity: 0.8;
}

/* Responsive adjustments */
@media (max-width: 1024px) {
  .mindmap-layout {
    flex-direction: column;
    height: auto;
    min-height: 100vh;
  }
  
  .dj-control-group-compact {
    padding: 0.5rem;
  }
}

@media (max-width: 768px) {
  .mindmap-layout {
    padding: 0.5rem;
    gap: 0.5rem;
  }
  
  /* Make DJ controls more compact on mobile */
  .dj-controls {
    max-height: 300px;
    overflow-y: auto;
  }
  
  /* DJ Control Panel mobile adjustments */
  .mindmap-layout .w-full.lg\:w-72 {
    height: auto !important;
    max-height: 350px;
  }
  
  /* Ensure mindmap container matches DJ panel height on mobile */
  .mindmap-layout .flex-1.bg-gradient-to-br {
    height: auto !important;
    max-height: 350px;
  }
}

@media (max-width: 640px) {
  .mindmap-layout {
    padding: 0.25rem;
    gap: 0.25rem;
  }
  
  /* Stack category controls vertically on small mobile */
  .category-grid {
    grid-template-columns: 1fr;
  }
}
