/* AIOS Hub Custom Styles & High-Contrast Dark Theme */
@import url('https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:wght@400;500;600;700;800&family=JetBrains+Mono:wght@400;500;600;700&display=swap');

:root {
  --bg-primary: #0b0f17;
  --bg-card: #111827;
  --bg-card-hover: #172033;
  --border-card: #1f293d;
  --text-main: #f8fafc;
  --text-muted: #94a3b8;
  --accent-cyan: #06b6d4;
  --accent-emerald: #10b981;
  --accent-amber: #f59e0b;
  --accent-violet: #8b5cf6;
}

* {
  box-sizing: border-box;
}

body {
  font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  background-color: var(--bg-primary);
  color: var(--text-main);
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

code, pre, .font-mono {
  font-family: 'JetBrains Mono', monospace;
  font-feature-settings: "liga" 0;
}

/* Crisp Cards (No Chrome backdrop raster blur on text) */
.glass-panel {
  background: var(--bg-card);
  border: 1px solid var(--border-card);
  box-shadow: 0 4px 20px -2px rgba(0, 0, 0, 0.4);
}

.kanban-col {
  min-height: 520px;
  background: #0f172a;
  border: 1px solid #1e293b;
}

.project-card {
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  background: #111827;
  border: 1px solid #1f293d;
}

.project-card:hover {
  transform: translateY(-2px);
  border-color: #0891b2;
  box-shadow: 0 10px 25px -5px rgba(6, 182, 212, 0.2);
}

.badge-crit {
  transition: all 0.15s ease;
  user-select: none;
}

.badge-crit:hover {
  transform: scale(1.05);
}

/* FIX: Dropdowns and Options styling across all browsers */
select {
  background-color: #0f172a !important;
  color: #f8fafc !important;
  border: 1px solid #334155 !important;
}

select option {
  background-color: #0f172a !important;
  color: #f8fafc !important;
  padding: 8px 12px;
}

select option:checked {
  background-color: #0284c7 !important;
  color: #ffffff !important;
}

/* Inputs & Textareas */
input, textarea {
  background-color: #0f172a !important;
  color: #f8fafc !important;
  border: 1px solid #334155 !important;
}

input:focus, textarea:focus, select:focus {
  border-color: #06b6d4 !important;
  outline: none !important;
  box-shadow: 0 0 0 1px #06b6d4 !important;
}

input::placeholder, textarea::placeholder {
  color: #64748b !important;
}

/* Category Badges High Contrast */
.badge-cat-perso {
  background-color: #2e1065 !important;
  color: #d8b4fe !important;
  border: 1px solid #6b21a8 !important;
}

.badge-cat-pro {
  background-color: #0c4a6e !important;
  color: #7dd3fc !important;
  border: 1px solid #0369a1 !important;
}

.badge-cat-aios {
  background-color: #064e3b !important;
  color: #6ee7b7 !important;
  border: 1px solid #047857 !important;
}

.badge-cat-general {
  background-color: #1e293b !important;
  color: #cbd5e1 !important;
  border: 1px solid #475569 !important;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}
::-webkit-scrollbar-track {
  background: #0b0f17;
}
::-webkit-scrollbar-thumb {
  background: #334155;
  border-radius: 3px;
}
::-webkit-scrollbar-thumb:hover {
  background: #475569;
}

/* Dual-Segment Left-Right Sliding Switch Button */
.service-sliding-switch {
  position: relative;
  display: inline-flex;
  align-items: center;
  width: 84px;
  height: 30px;
  padding: 2px;
  border-radius: 9999px;
  background-color: #0f172a;
  border: 1px solid #334155;
  cursor: pointer;
  user-select: none;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.service-sliding-switch:hover {
  border-color: #475569;
}

.service-sliding-switch.is-on {
  border-color: rgba(16, 185, 129, 0.4);
  box-shadow: 0 0 10px rgba(16, 185, 129, 0.2);
}

.service-sliding-thumb {
  position: absolute;
  top: 2px;
  left: 2px;
  width: 38px;
  height: 24px;
  border-radius: 9999px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: 'JetBrains Mono', monospace;
  font-size: 11px;
  font-weight: 700;
  transition: transform 0.25s cubic-bezier(0.4, 0, 0.2, 1), background-color 0.25s ease, color 0.25s ease;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.4);
  z-index: 2;
}

.service-sliding-switch.is-on .service-sliding-thumb {
  transform: translateX(40px);
  background-color: #10b981;
  color: #ffffff;
}

.service-sliding-switch.is-off .service-sliding-thumb {
  transform: translateX(0);
  background-color: #475569;
  color: #f1f5f9;
}

.service-sliding-label {
  width: 38px;
  text-align: center;
  font-family: 'JetBrains Mono', monospace;
  font-size: 10px;
  font-weight: 700;
  color: #64748b;
  z-index: 1;
  transition: opacity 0.2s ease;
}


/* Dual-Mode View Sliding Switch (Detailed Grid vs Kanban Pipeline - Compact Icons Only) */
.view-sliding-switch {
  position: relative;
  display: inline-flex;
  align-items: center;
  width: 68px;
  height: 30px;
  padding: 2px;
  border-radius: 9999px;
  background-color: #0f172a;
  border: 1px solid #334155;
  cursor: pointer;
  user-select: none;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.view-sliding-switch:hover {
  border-color: #0891b2;
}

.view-sliding-switch:focus-visible {
  outline: none;
  border-color: #06b6d4;
  box-shadow: 0 0 0 2px rgba(6, 182, 212, 0.4);
}

.view-sliding-thumb {
  position: absolute;
  top: 2px;
  left: 2px;
  width: 30px;
  height: 24px;
  border-radius: 9999px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  transition: transform 0.25s cubic-bezier(0.4, 0, 0.2, 1), background-color 0.25s ease;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.4);
  z-index: 2;
  background-color: #0891b2;
  color: #ffffff;
}

.view-sliding-switch.is-compact .view-sliding-thumb,
.view-sliding-switch.is-list .view-sliding-thumb,
.view-sliding-switch.is-table .view-sliding-thumb {
  transform: translateX(0);
}

.view-sliding-switch.is-kanban .view-sliding-thumb,
.view-sliding-switch.is-grid .view-sliding-thumb {
  transform: translateX(32px);
}

.view-sliding-option {
  width: 32px;
  height: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  color: #64748b;
  z-index: 1;
  transition: color 0.2s ease;
}

.view-sliding-switch.is-compact .view-sliding-option.opt-kanban,
.view-sliding-switch.is-list .view-sliding-option.opt-kanban,
.view-sliding-switch.is-table .view-sliding-option.opt-kanban,
.view-sliding-switch.is-list .view-sliding-option.opt-grid {
  color: #94a3b8;
}

.view-sliding-switch.is-kanban .view-sliding-option.opt-compact,
.view-sliding-switch.is-kanban .view-sliding-option.opt-list,
.view-sliding-switch.is-kanban .view-sliding-option.opt-table,
.view-sliding-switch.is-grid .view-sliding-option.opt-list {
  color: #94a3b8;
}

/* ============================================================= */
/* TO-DO & TASK MANAGEMENT STYLES                                */
/* ============================================================= */
.task-row {
  transition: all 0.15s ease-in-out;
}
.task-row:hover {
  border-color: rgba(6, 182, 212, 0.4);
  transform: translateY(-1px);
}
.task-row.task-completed {
  opacity: 0.55;
}
.task-row.task-completed .task-title {
  text-decoration: line-through;
  color: #94a3b8;
}

.task-checkbox-btn {
  width: 20px;
  height: 20px;
  border-radius: 6px;
  border: 1.5px solid #475569;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
  cursor: pointer;
  flex-shrink: 0;
  background-color: rgba(15, 23, 42, 0.8);
}
.task-checkbox-btn:hover {
  border-color: #06b6d4;
  background-color: rgba(6, 182, 212, 0.1);
}
.task-checkbox-btn.is-checked {
  background-color: #0891b2;
  border-color: #06b6d4;
  color: #ffffff;
}

.task-kanban-col {
  background: rgba(15, 23, 42, 0.6);
  border: 1px solid rgba(51, 65, 85, 0.5);
  border-radius: 16px;
  min-height: 480px;
}
.task-kanban-card {
  cursor: grab;
  transition: all 0.18s ease;
}
.task-kanban-card:hover {
  border-color: rgba(6, 182, 212, 0.5);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.35);
}
.task-kanban-card:active {
  cursor: grabbing;
}

/* Studio Diarisation & Audio Karaoke Styles */
.turn-card {
  transition: all 0.22s cubic-bezier(0.16, 1, 0.3, 1);
}

.turn-card.karaoke-active {
  background: linear-gradient(135deg, rgba(8, 47, 73, 0.95), rgba(15, 23, 42, 0.98)) !important;
  border-color: #06b6d4 !important;
  box-shadow: 0 0 25px rgba(6, 182, 212, 0.45), inset 0 0 15px rgba(6, 182, 212, 0.15) !important;
  transform: scale(1.012) translateX(4px);
  z-index: 10;
}

.turn-card.karaoke-active .turn-text {
  color: #f0fdfa !important;
  font-weight: 500;
  text-shadow: 0 0 8px rgba(6, 182, 212, 0.3);
}

.turn-card.karaoke-active .turn-play-btn {
  background-color: #0891b2 !important;
  color: #ffffff !important;
  box-shadow: 0 0 10px rgba(6, 182, 212, 0.6);
}

/* Shimmer on compute progress bar */
@keyframes shimmerAnim {
  0% { background-position: -200% 0; }
  100% { background-position: 200% 0; }
}

.progress-bar-shimmer {
  background-size: 200% 100%;
  animation: shimmerAnim 2.5s infinite linear;
}
