/* ==========================================================================
   DIREKTOR TO-DO LISTA - MODERAN POSLOVNI SUSTAV
   Dizajnerski sustav: Tamna izvršna tema, glassmorphism, piramidalna hijerarhija
   ========================================================================== */

:root {
  /* Osnovne boje teme */
  --bg-dark: #090d16;
  --bg-surface: #101626;
  --bg-surface-elevated: #182238;
  --bg-card: rgba(20, 29, 48, 0.75);
  --bg-card-hover: rgba(28, 41, 68, 0.85);
  
  /* Tekstualne boje */
  --text-primary: #f1f5f9;
  --text-secondary: #94a3b8;
  --text-muted: #64748b;
  --text-light: #ffffff;

  /* Brend & Akcenti */
  --primary: #3b82f6;
  --primary-light: #60a5fa;
  --primary-glow: rgba(59, 130, 246, 0.25);
  
  /* Statusne boje */
  --status-new: #38bdf8;
  --status-inprogress: #eab308;
  --status-review: #f97316;
  --status-done: #10b981;
  --status-urgent: #ef4444;

  /* Sektorske boje */
  --color-director: #f59e0b;
  --color-financije: #10b981;
  --color-prodaja: #3b82f6;
  --color-nabava: #06b6d4;
  --color-skladiste: #f59e0b;
  --color-informatika: #8b5cf6;
  --color-dizajn: #ec4899;
  --color-benzinska: #ef4444;

  /* Granice i sjene */
  --border-subtle: rgba(255, 255, 255, 0.08);
  --border-highlight: rgba(255, 255, 255, 0.16);
  --shadow-sm: 0 2px 6px rgba(0, 0, 0, 0.25);
  --shadow-md: 0 8px 24px rgba(0, 0, 0, 0.35);
  --shadow-lg: 0 16px 40px rgba(0, 0, 0, 0.45);
  --shadow-glow: 0 0 30px rgba(59, 130, 246, 0.18);

  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-xl: 20px;
  --radius-full: 9999px;

  --transition: all 0.22s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Reset & Bazni stilovi */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: 'Plus Jakarta Sans', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  background-color: var(--bg-dark);
  color: var(--text-primary);
  line-height: 1.5;
  min-height: 100vh;
  background-image: 
    radial-gradient(circle at 50% 0%, rgba(59, 130, 246, 0.1) 0%, transparent 50%),
    radial-gradient(circle at 100% 100%, rgba(139, 92, 246, 0.06) 0%, transparent 40%),
    radial-gradient(circle at 0% 50%, rgba(16, 185, 129, 0.05) 0%, transparent 40%);
  background-attachment: fixed;
  -webkit-font-smoothing: antialiased;
}

/* Layout */
.app-layout {
  max-width: 1600px;
  margin: 0 auto;
  padding: 20px 24px 40px;
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.main-content {
  display: flex;
  flex-direction: column;
  gap: 28px;
}

/* ==========================================================================
   HEADER
   ========================================================================== */
.app-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 24px;
  background: var(--bg-card);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  flex-wrap: wrap;
  gap: 16px;
}

.header-brand {
  display: flex;
  align-items: center;
  gap: 14px;
}

.brand-icon {
  width: 44px;
  height: 44px;
  border-radius: var(--radius-md);
  background: linear-gradient(135deg, #2563eb, #1d4ed8);
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  box-shadow: 0 4px 14px rgba(37, 99, 235, 0.4);
}

.brand-title {
  font-size: 1.35rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--text-light);
  line-height: 1.2;
}

.brand-title span {
  background: linear-gradient(90deg, #60a5fa, #93c5fd);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.brand-subtitle {
  font-size: 0.8rem;
  color: var(--text-secondary);
  font-weight: 500;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.date-badge {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 14px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-full);
  font-size: 0.82rem;
  color: var(--text-secondary);
  font-weight: 500;
}

/* ==========================================================================
   GUMBI (BUTTONS)
   ========================================================================== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 9px 18px;
  font-size: 0.86rem;
  font-weight: 600;
  border-radius: var(--radius-md);
  border: 1px solid transparent;
  cursor: pointer;
  transition: var(--transition);
  user-select: none;
  font-family: inherit;
}

.btn-primary {
  background: linear-gradient(135deg, #3b82f6, #2563eb);
  color: white;
  box-shadow: 0 4px 14px rgba(37, 99, 235, 0.35);
}

.btn-primary:hover {
  background: linear-gradient(135deg, #60a5fa, #3b82f6);
  transform: translateY(-1px);
  box-shadow: 0 6px 18px rgba(37, 99, 235, 0.45);
}

.btn-outline {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border-subtle);
  color: var(--text-primary);
}

.btn-outline:hover {
  background: rgba(255, 255, 255, 0.09);
  border-color: var(--border-highlight);
  color: white;
}

.btn-danger-outline {
  background: rgba(239, 68, 68, 0.08);
  border: 1px solid rgba(239, 68, 68, 0.45);
  color: #fca5a5;
  transition: var(--transition);
}

.btn-danger-outline:hover {
  background: rgba(239, 68, 68, 0.22);
  border-color: #ef4444;
  color: #ffffff;
  transform: translateY(-1px);
}

.btn-ghost {
  background: transparent;
  color: var(--text-secondary);
  border: 1px solid transparent;
}

.btn-ghost:hover, .btn-ghost.active {
  background: rgba(255, 255, 255, 0.08);
  color: var(--text-light);
}

.btn-sm {
  padding: 6px 12px;
  font-size: 0.8rem;
}

.btn-xs {
  padding: 5px 10px;
  font-size: 0.75rem;
  border-radius: var(--radius-sm);
}

/* ==========================================================================
   KPI STATS BAR & FILTERI
   ========================================================================== */
.kpi-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 20px;
  margin: 6px 0 10px;
}

.kpi-card {
  background: var(--bg-card);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 20px 22px;
  display: flex;
  align-items: center;
  gap: 16px;
  position: relative;
  cursor: pointer;
  transition: var(--transition);
  box-shadow: 0 4px 18px rgba(0, 0, 0, 0.25);
}

.kpi-card:hover {
  transform: translateY(-2px);
  border-color: var(--border-highlight);
  background: var(--bg-card-hover);
  box-shadow: var(--shadow-md);
}

.kpi-card.active {
  border-color: var(--primary);
  background: rgba(59, 130, 246, 0.12);
  box-shadow: 0 0 0 1px var(--primary);
}

.kpi-icon {
  width: 46px;
  height: 46px;
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.icon-total { background: rgba(59, 130, 246, 0.15); color: #60a5fa; }
.icon-pending { background: rgba(56, 189, 248, 0.15); color: #38bdf8; }
.icon-review { background: rgba(249, 115, 22, 0.15); color: #f97316; }
.icon-completed { background: rgba(16, 185, 129, 0.15); color: #34d399; }
.icon-urgent { background: rgba(239, 68, 68, 0.15); color: #f87171; }

.kpi-data {
  display: flex;
  flex-direction: column;
}

.kpi-value {
  font-size: 1.7rem;
  font-weight: 800;
  line-height: 1.1;
  color: var(--text-light);
}

.kpi-label {
  font-size: 0.78rem;
  color: var(--text-secondary);
  font-weight: 500;
}

.kpi-pill {
  position: absolute;
  top: 12px;
  right: 12px;
  font-size: 0.68rem;
  font-weight: 700;
  text-transform: uppercase;
  padding: 2px 8px;
  border-radius: var(--radius-full);
}

.pulse-badge {
  background: rgba(249, 115, 22, 0.2);
  color: #fb923c;
  border: 1px solid rgba(249, 115, 22, 0.4);
  animation: pulse 2s infinite;
}

@keyframes pulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.7; transform: scale(0.96); }
}

/* ==========================================================================
   SEKCIJE I ZAJEDNIČKI ELEMENTI
   ========================================================================== */
.section-card {
  background: var(--bg-card);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  padding: 24px;
  box-shadow: var(--shadow-md);
}

.section-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 24px;
  flex-wrap: wrap;
  gap: 16px;
}

.section-badge {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--primary-light);
  background: rgba(59, 130, 246, 0.12);
  padding: 4px 10px;
  border-radius: var(--radius-full);
  margin-bottom: 6px;
  border: 1px solid rgba(59, 130, 246, 0.2);
}

.section-title-wrap h2 {
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--text-light);
  line-height: 1.25;
}

.section-title-wrap p {
  font-size: 0.85rem;
  color: var(--text-secondary);
  margin-top: 4px;
}

/* ==========================================================================
   PIRAMIDA: PREKIDAČ POGLEDA (2D DIJAGRAM / 3D PROSTOR)
   ========================================================================== */
.pyramid-view-switch {
  display: flex;
  align-items: center;
  background: rgba(15, 23, 42, 0.7);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-full);
  padding: 3px;
  gap: 3px;
}

.btn-view-tab {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 5px 13px;
  border-radius: var(--radius-full);
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-secondary);
  background: transparent;
  border: none;
  cursor: pointer;
  transition: var(--transition);
}

.btn-view-tab:hover {
  color: var(--text-light);
  background: rgba(255, 255, 255, 0.06);
}

.btn-view-tab.active {
  background: var(--primary);
  color: #ffffff;
  box-shadow: 0 2px 10px rgba(59, 130, 246, 0.45);
}

.badge-pill-3d {
  font-size: 0.62rem;
  background: linear-gradient(135deg, #f59e0b, #ec4899);
  color: #ffffff;
  padding: 1px 6px;
  border-radius: var(--radius-full);
  font-weight: 800;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  box-shadow: 0 0 10px rgba(236, 72, 153, 0.5);
  animation: pulse 2.5s infinite;
}

/* ==========================================================================
   3D PIRAMIDA ENGINE STYLES (Three.js WebGL)
   ========================================================================== */
.pyramid-3d-wrapper {
  position: relative;
  width: 100%;
  border-radius: var(--radius-xl);
  overflow: hidden;
  background: radial-gradient(circle at 50% 20%, #0e172a 0%, #070b13 100%);
  border: 1px solid rgba(59, 130, 246, 0.25);
  box-shadow: 0 14px 40px rgba(0, 0, 0, 0.6), 0 0 25px rgba(59, 130, 246, 0.12);
  display: flex;
  flex-direction: column;
  margin-top: 6px;
}

.pyramid-3d-wrapper.is-fullscreen {
  position: fixed;
  inset: 0;
  width: 100vw;
  height: 100vh;
  z-index: 99999;
  border-radius: 0;
  border: none;
}

.pyramid-3d-toolbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 18px;
  background: rgba(16, 22, 38, 0.88);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--border-subtle);
  z-index: 10;
  flex-wrap: wrap;
  gap: 10px;
}

.toolbar-group {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.btn-3d-tool {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-subtle);
  color: var(--text-primary);
  padding: 6px 12px;
  border-radius: var(--radius-md);
  font-size: 0.8rem;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 6px;
  cursor: pointer;
  transition: var(--transition);
}

.btn-3d-tool:hover {
  background: rgba(59, 130, 246, 0.18);
  border-color: var(--primary-light);
  color: #ffffff;
  box-shadow: 0 0 12px rgba(59, 130, 246, 0.3);
}

.btn-3d-tool.active {
  background: rgba(59, 130, 246, 0.25);
  border-color: var(--primary);
  color: #60a5fa;
  box-shadow: 0 0 14px rgba(59, 130, 246, 0.35);
}

.btn-3d-apex {
  border-color: rgba(245, 158, 11, 0.4);
  color: #fde68a;
  background: rgba(245, 158, 11, 0.1);
}

.btn-3d-apex:hover {
  background: rgba(245, 158, 11, 0.25);
  border-color: #f59e0b;
  color: #ffffff;
  box-shadow: 0 0 14px rgba(245, 158, 11, 0.4);
}

.pyramid-3d-viewport {
  position: relative;
  width: 100%;
  height: 740px;
  min-height: 620px;
  overflow: hidden;
  cursor: grab;
}

.pyramid-3d-viewport:active {
  cursor: grabbing;
}

.pyramid-3d-wrapper.is-fullscreen .pyramid-3d-viewport {
  height: calc(100vh - 60px);
}

/* 3D HUD Tooltip */
.pyramid-3d-tooltip {
  position: absolute;
  pointer-events: none;
  z-index: 50;
  background: rgba(13, 20, 36, 0.94);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: var(--radius-md);
  padding: 12px 14px;
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.6), 0 0 20px rgba(59, 130, 246, 0.2);
  min-width: 220px;
  max-width: 290px;
  color: var(--text-light);
  transform: translateY(0);
  transition: opacity 0.15s ease;
}

.pyramid-3d-tooltip strong {
  display: block;
  font-size: 0.92rem;
  font-weight: 700;
  color: #ffffff;
  margin-bottom: 3px;
}

.pyramid-3d-tooltip small {
  display: block;
  font-size: 0.74rem;
  color: var(--text-secondary);
  margin-bottom: 6px;
}

.pyramid-3d-tooltip .tooltip-level-tag {
  display: inline-block;
  font-size: 0.68rem;
  font-weight: 700;
  color: #38bdf8;
  background: rgba(56, 189, 248, 0.16);
  border: 1px solid rgba(56, 189, 248, 0.35);
  border-radius: var(--radius-full);
  padding: 2px 8px;
  margin-bottom: 6px;
}

.pyramid-3d-tooltip .tooltip-badge {
  display: inline-block;
  font-size: 0.68rem;
  font-weight: 700;
  color: #93c5fd;
  background: rgba(59, 130, 246, 0.18);
  border: 1px solid rgba(59, 130, 246, 0.35);
  border-radius: var(--radius-full);
  padding: 2px 8px;
}

.tip-header {
  display: flex;
  align-items: center;
  gap: 10px;
  padding-left: 8px;
  padding-bottom: 8px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.tip-header.tip-director {
  border-left: 3px solid #f59e0b;
}

.tip-icon {
  font-size: 1.4rem;
  line-height: 1;
}

.tip-avatar {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 0.9rem;
  color: #0f172a;
}

.tip-header strong {
  display: block;
  font-size: 0.92rem;
  color: #ffffff;
  line-height: 1.15;
}

.tip-header small {
  display: block;
  font-size: 0.72rem;
  color: var(--text-secondary);
}

.tip-stats {
  margin: 8px 0;
  font-size: 0.78rem;
  display: flex;
  flex-direction: column;
  gap: 4px;
  color: var(--text-secondary);
}

.tip-stats strong {
  color: #f1f5f9;
}

.tip-alert {
  color: #ef4444 !important;
}

.tip-action {
  font-size: 0.71rem;
  color: var(--primary-light);
  font-weight: 600;
  margin-top: 6px;
  text-align: center;
  background: rgba(59, 130, 246, 0.12);
  padding: 4px 6px;
  border-radius: var(--radius-sm);
}

/* Sektor Quick Bar - Postavljen na vrh ispod toolbar-a kako ne bi prekrivao 3D prostor */
.pyramid-3d-sector-bar {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 8px 16px;
  background: rgba(12, 18, 32, 0.94);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--border-subtle);
  z-index: 15;
  flex-wrap: wrap;
}

.sector-bar-label {
  font-size: 0.72rem;
  text-transform: uppercase;
  color: var(--text-muted);
  font-weight: 700;
  margin-right: 4px;
  white-space: nowrap;
}

.sector-chip-btn {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--border-subtle);
  color: var(--text-primary);
  padding: 5px 12px;
  border-radius: var(--radius-full);
  font-size: 0.78rem;
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
  transition: var(--transition);
}

.sector-chip-btn:hover {
  background: rgba(255, 255, 255, 0.15);
  color: #ffffff;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
}

.sector-chip-btn.chip-apex:hover { border-color: #f59e0b; color: #fde68a; box-shadow: 0 0 12px rgba(245, 158, 11, 0.4); }
.sector-chip-btn.chip-financije:hover { border-color: #10b981; color: #a7f3d0; box-shadow: 0 0 12px rgba(16, 185, 129, 0.4); }
.sector-chip-btn.chip-prodaja:hover { border-color: #3b82f6; color: #bfdbfe; box-shadow: 0 0 12px rgba(59, 130, 246, 0.4); }
.sector-chip-btn.chip-nabava:hover { border-color: #06b6d4; color: #a5f3fc; box-shadow: 0 0 12px rgba(6, 182, 212, 0.4); }
.sector-chip-btn.chip-skladiste:hover { border-color: #f59e0b; color: #fde68a; box-shadow: 0 0 12px rgba(245, 158, 11, 0.4); }
.sector-chip-btn.chip-informatika:hover { border-color: #8b5cf6; color: #ddd6fe; box-shadow: 0 0 12px rgba(139, 92, 246, 0.4); }
.sector-chip-btn.chip-dizajn:hover { border-color: #ec4899; color: #fbcfe8; box-shadow: 0 0 12px rgba(236, 72, 153, 0.4); }
.sector-chip-btn.chip-benzinska:hover { border-color: #ef4444; color: #fecaca; box-shadow: 0 0 12px rgba(239, 68, 68, 0.4); }

/* 3D Hints Bar - Diskretno smješten u donjem desnom kutu */
.pyramid-3d-hints {
  position: absolute;
  bottom: 12px;
  right: 16px;
  font-size: 0.72rem;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  gap: 8px;
  pointer-events: none;
  background: rgba(9, 13, 22, 0.78);
  backdrop-filter: blur(8px);
  padding: 4px 14px;
  border-radius: var(--radius-full);
  white-space: nowrap;
  border: 1px solid rgba(255, 255, 255, 0.08);
  z-index: 10;
}

@media (max-width: 900px) {
  .pyramid-3d-viewport {
    height: 560px;
  }
  .pyramid-3d-hints {
    display: none;
  }
}

/* ==========================================================================
   PIRAMIDALNA ORGANIZACIJSKA STRUKTURA (HIERARCHY)
   ========================================================================== */
.pyramid-container {
  display: flex;
  flex-direction: column;
  position: relative;
  padding: 10px 0 20px;
  width: 100%;
  max-width: 100%;
}

/* LEVEL 1: DIREKTOR (VRH PIRAMIDE) */
.pyramid-level-apex {
  display: flex;
  flex-direction: column;
  align-items: center;
  z-index: 5;
  width: 100%;
}

.director-card {
  background: linear-gradient(135deg, rgba(30, 41, 59, 0.95), rgba(15, 23, 42, 0.95));
  border: 2px solid rgba(245, 158, 11, 0.6);
  border-radius: var(--radius-xl);
  padding: 22px 28px;
  width: 380px;
  max-width: 95%;
  position: relative;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5), 0 0 25px rgba(245, 158, 11, 0.18);
  transition: var(--transition);
  cursor: pointer;
}

.director-card:hover {
  transform: translateY(-3px) scale(1.01);
  box-shadow: 0 14px 38px rgba(0, 0, 0, 0.6), 0 0 35px rgba(245, 158, 11, 0.3);
  border-color: #f59e0b;
}

.director-card.active-selection {
  outline: 3px solid #f59e0b;
  outline-offset: 3px;
}

.apex-crown {
  position: absolute;
  top: -16px;
  right: 28px;
  background: linear-gradient(135deg, #f59e0b, #d97706);
  width: 34px;
  height: 34px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #1e1b4b;
  box-shadow: 0 4px 12px rgba(245, 158, 11, 0.5);
}

.director-header {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 14px;
}

.director-avatar {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: linear-gradient(135deg, #f59e0b, #b45309);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  font-weight: 800;
  color: #0f172a;
  border: 3px solid rgba(254, 243, 199, 0.3);
  box-shadow: 0 4px 12px rgba(245, 158, 11, 0.3);
}

.director-role {
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: #fbbf24;
}

.director-name {
  font-size: 1.45rem;
  font-weight: 800;
  color: var(--text-light);
  line-height: 1.1;
}

.director-status-dot {
  display: inline-block;
  font-size: 0.72rem;
  color: #94a3b8;
  font-weight: 600;
}

.director-meta {
  display: flex;
  background: rgba(0, 0, 0, 0.3);
  border-radius: var(--radius-md);
  padding: 10px 14px;
  justify-content: space-around;
  margin-bottom: 14px;
  border: 1px solid rgba(255, 255, 255, 0.05);
}

.meta-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
}

.meta-label {
  font-size: 0.7rem;
  color: var(--text-secondary);
}

.meta-val {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--text-light);
}

.meta-highlight {
  color: #f97316;
}

.director-actions {
  display: flex;
  gap: 8px;
}

.btn-director-action {
  flex: 1;
  background: rgba(245, 158, 11, 0.12);
  color: #fde68a;
  border: 1px solid rgba(245, 158, 11, 0.3);
  border-radius: var(--radius-sm);
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition);
}

.btn-director-action:hover {
  background: rgba(245, 158, 11, 0.25);
  color: #fff;
}

/* ==========================================================================
   2D PREGLED: NAVIGACIJA & SCROLL KONTROLE SEKORA
   ========================================================================== */
.sectors-scroll-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  padding: 10px 16px;
  background: linear-gradient(135deg, rgba(30, 41, 59, 0.7) 0%, rgba(15, 23, 42, 0.8) 100%);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  margin: 12px 0 6px;
  gap: 12px;
  flex-wrap: wrap;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2);
}

.sectors-scroll-info {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.85rem;
}

.scroll-info-icon {
  font-size: 1.15rem;
  line-height: 1;
}

.scroll-info-text {
  font-weight: 700;
  color: var(--text-light);
  letter-spacing: 0.02em;
}

.scroll-info-hint {
  font-size: 0.74rem;
  font-weight: 600;
  color: var(--primary-light);
  background: rgba(59, 130, 246, 0.12);
  border: 1px solid rgba(59, 130, 246, 0.25);
  padding: 3px 10px;
  border-radius: var(--radius-full);
}

.sectors-scroll-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.btn-scroll-arrow {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--text-light);
  background: rgba(59, 130, 246, 0.18);
  border: 1px solid rgba(59, 130, 246, 0.4);
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: var(--transition);
  user-select: none;
}

.btn-scroll-arrow:hover:not(:disabled) {
  background: rgba(59, 130, 246, 0.35);
  border-color: #3b82f6;
  transform: translateY(-1px);
  box-shadow: 0 4px 14px rgba(59, 130, 246, 0.3);
}

.btn-scroll-arrow:active:not(:disabled) {
  transform: translateY(0);
}

.btn-scroll-arrow:disabled {
  opacity: 0.35;
  cursor: not-allowed;
  border-color: rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.04);
}

/* ==========================================================================
   VIEWPORT ZA VODORAVNO KLIZANJE SEKORA (HORIZONTAL SCROLL)
   ========================================================================== */
.pyramid-sectors-scroll-viewport {
  width: 100%;
  max-width: 100%;
  overflow-x: auto;
  overflow-y: hidden;
  padding: 6px 6px 22px;
  position: relative;
  scroll-behavior: smooth;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: thin;
  scrollbar-color: #3b82f6 rgba(15, 23, 42, 0.7);
}

.pyramid-sectors-scroll-viewport::-webkit-scrollbar {
  height: 10px;
}

.pyramid-sectors-scroll-viewport::-webkit-scrollbar-track {
  background: rgba(15, 23, 42, 0.75);
  border-radius: var(--radius-full);
  margin: 0 14px;
  border: 1px solid rgba(255, 255, 255, 0.06);
}

.pyramid-sectors-scroll-viewport::-webkit-scrollbar-thumb {
  background: linear-gradient(90deg, #3b82f6, #8b5cf6, #ec4899);
  border-radius: var(--radius-full);
  border: 2px solid rgba(15, 23, 42, 0.85);
  box-shadow: 0 0 12px rgba(59, 130, 246, 0.4);
}

.pyramid-sectors-scroll-viewport::-webkit-scrollbar-thumb:hover {
  background: linear-gradient(90deg, #60a5fa, #a78bfa, #f472b6);
}

.pyramid-sectors-scroll-viewport.is-panning {
  cursor: grabbing !important;
  user-select: none;
}

/* POVEZNE LINIJE PIRAMIDE (CONNECTORS) */
.pyramid-connector {
  width: max-content;
  min-width: 100%;
  display: flex;
  flex-direction: column;
  align-items: stretch;
  margin: -4px 0 16px;
  position: relative;
}

.connector-vertical {
  width: 2px;
  height: 24px;
  background: linear-gradient(to bottom, #f59e0b, rgba(255, 255, 255, 0.25));
  margin: 0 auto;
}

.connector-horizontal {
  height: 2px;
  width: calc(100% - 296px);
  margin-left: 148px;
  background: linear-gradient(90deg, #10b981 0%, #3b82f6 15%, #06b6d4 32%, #f59e0b 50%, #8b5cf6 68%, #ec4899 84%, #ef4444 100%);
  position: relative;
  opacity: 0.7;
}

.connector-drop-lines {
  display: flex;
  gap: 18px;
  width: max-content;
  min-width: 100%;
  padding: 0 12px;
}

.drop-line-slot {
  width: 272px;
  min-width: 272px;
  flex: 0 0 272px;
  display: flex;
  justify-content: center;
}

.drop-line {
  width: 2px;
  height: 20px;
  background: rgba(255, 255, 255, 0.25);
}

/* LEVEL 2: SEKTORI I LJUDI - VODORAVNI RASPORED */
.pyramid-level-sectors {
  display: flex;
  gap: 18px;
  width: max-content;
  min-width: 100%;
  padding: 6px 12px 14px;
}

.sector-group {
  width: 272px;
  min-width: 272px;
  flex: 0 0 272px;
  background: rgba(15, 23, 42, 0.7);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 14px 12px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  position: relative;
  transition: var(--transition);
  box-shadow: 0 6px 22px rgba(0, 0, 0, 0.3);
}

.sector-group:hover {
  border-color: var(--border-highlight);
  background: rgba(20, 29, 48, 0.82);
  transform: translateY(-2px);
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.4);
}

/* Sektorske tematske boje & gornji naglasak */
.sector-financije { border-top: 4px solid var(--color-financije) !important; }
.sector-prodaja { border-top: 4px solid var(--color-prodaja) !important; }
.sector-nabava { border-top: 4px solid var(--color-nabava) !important; }
.sector-skladiste { border-top: 4px solid var(--color-skladiste) !important; }
.sector-informatika { border-top: 4px solid var(--color-informatika) !important; }
.sector-dizajn { border-top: 4px solid var(--color-dizajn) !important; }
.sector-benzinska { border-top: 4px solid var(--color-benzinska) !important; }

/* ==========================================================================
   NAGLAŠENO VIZUALNO ZAGLAVLJE SEKORA (SECTOR HEADER BANNER)
   ========================================================================== */
.sector-header-chip {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 12px 14px;
  background: rgba(15, 23, 42, 0.85);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: var(--radius-md);
  color: var(--text-light);
  cursor: pointer;
  user-select: none;
  transition: var(--transition);
  position: relative;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.35);
}

.sector-header-chip:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.45);
  border-color: rgba(255, 255, 255, 0.28);
}

.sector-header-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
  width: 100%;
}

.sector-header-badge-tag {
  display: flex;
  align-items: center;
  gap: 6px;
}

.sector-header-badge-tag .drag-handle {
  color: var(--text-muted);
  cursor: grab;
  font-size: 0.85rem;
  line-height: 1;
}

.sector-badge-pill {
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 2.5px 8px;
  border-radius: var(--radius-full);
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.18);
  color: var(--text-secondary);
}

.sector-chip-label {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  min-width: 0;
}

.sector-icon {
  font-size: 1.65rem;
  line-height: 1;
  flex-shrink: 0;
  filter: drop-shadow(0 2px 6px rgba(0, 0, 0, 0.6));
}

.sector-title-wrap {
  display: flex;
  flex-direction: column;
  gap: 3px;
  min-width: 0;
  flex: 1;
}

.sector-title {
  font-size: 1.28rem;
  font-weight: 900;
  letter-spacing: 0.03em;
  line-height: 1.15;
  color: #ffffff;
  white-space: normal;
  word-break: break-word;
  text-transform: uppercase;
}

.sector-members-count {
  font-size: 0.74rem;
  font-weight: 700;
  color: var(--text-secondary);
  letter-spacing: 0.02em;
}

.sector-chip-actions {
  display: flex;
  align-items: center;
  gap: 4px;
  flex-shrink: 0;
}

.btn-sector-view-pyramid,
.btn-sector-add-sub,
.btn-sector-del {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.16);
  color: var(--text-secondary);
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: all 0.15s ease;
  line-height: 1;
}

.btn-sector-view-pyramid {
  width: 24px;
  height: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.78rem;
}

.btn-sector-view-pyramid:hover {
  background: rgba(56, 189, 248, 0.25);
  border-color: #38bdf8;
  color: #fff;
  transform: scale(1.1);
}

.btn-sector-add-sub {
  width: 24px;
  height: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
}

.btn-sector-add-sub:hover {
  background: rgba(16, 185, 129, 0.25);
  border-color: #10b981;
  color: #fff;
  transform: scale(1.1);
}

.btn-sector-del {
  width: 24px;
  height: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.72rem;
  color: #f87171;
  background: rgba(239, 68, 68, 0.12);
  border-color: rgba(239, 68, 68, 0.25);
}

.btn-sector-del:hover {
  background: #ef4444;
  border-color: #ef4444;
  color: #fff;
  transform: scale(1.1);
}

/* Pojedinačni sektorski naglasci & boje */
.sector-financije .sector-header-chip {
  border-color: rgba(16, 185, 129, 0.45);
  background: linear-gradient(135deg, rgba(16, 185, 129, 0.22) 0%, rgba(15, 23, 42, 0.85) 100%);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.35), 0 0 16px rgba(16, 185, 129, 0.16);
}
.sector-financije .sector-title {
  color: #a7f3d0;
  text-shadow: 0 0 12px rgba(16, 185, 129, 0.5);
}
.sector-financije .sector-badge-pill {
  color: #10b981;
  border-color: rgba(16, 185, 129, 0.4);
  background: rgba(16, 185, 129, 0.15);
}

.sector-prodaja .sector-header-chip {
  border-color: rgba(59, 130, 246, 0.45);
  background: linear-gradient(135deg, rgba(59, 130, 246, 0.22) 0%, rgba(15, 23, 42, 0.85) 100%);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.35), 0 0 16px rgba(59, 130, 246, 0.16);
}
.sector-prodaja .sector-title {
  color: #bfdbfe;
  text-shadow: 0 0 12px rgba(59, 130, 246, 0.5);
}
.sector-prodaja .sector-badge-pill {
  color: #3b82f6;
  border-color: rgba(59, 130, 246, 0.4);
  background: rgba(59, 130, 246, 0.15);
}

.sector-nabava .sector-header-chip {
  border-color: rgba(6, 182, 212, 0.45);
  background: linear-gradient(135deg, rgba(6, 182, 212, 0.22) 0%, rgba(15, 23, 42, 0.85) 100%);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.35), 0 0 16px rgba(6, 182, 212, 0.16);
}
.sector-nabava .sector-title {
  color: #a5f3fc;
  text-shadow: 0 0 12px rgba(6, 182, 212, 0.5);
}
.sector-nabava .sector-badge-pill {
  color: #06b6d4;
  border-color: rgba(6, 182, 212, 0.4);
  background: rgba(6, 182, 212, 0.15);
}

.sector-skladiste .sector-header-chip {
  border-color: rgba(245, 158, 11, 0.45);
  background: linear-gradient(135deg, rgba(245, 158, 11, 0.22) 0%, rgba(15, 23, 42, 0.85) 100%);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.35), 0 0 16px rgba(245, 158, 11, 0.16);
}
.sector-skladiste .sector-title {
  color: #fde68a;
  text-shadow: 0 0 12px rgba(245, 158, 11, 0.5);
}
.sector-skladiste .sector-badge-pill {
  color: #f59e0b;
  border-color: rgba(245, 158, 11, 0.4);
  background: rgba(245, 158, 11, 0.15);
}

.sector-informatika .sector-header-chip {
  border-color: rgba(139, 92, 246, 0.45);
  background: linear-gradient(135deg, rgba(139, 92, 246, 0.22) 0%, rgba(15, 23, 42, 0.85) 100%);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.35), 0 0 16px rgba(139, 92, 246, 0.16);
}
.sector-informatika .sector-title {
  color: #ddd6fe;
  text-shadow: 0 0 12px rgba(139, 92, 246, 0.5);
}
.sector-informatika .sector-badge-pill {
  color: #8b5cf6;
  border-color: rgba(139, 92, 246, 0.4);
  background: rgba(139, 92, 246, 0.15);
}

.sector-dizajn .sector-header-chip {
  border-color: rgba(236, 72, 153, 0.45);
  background: linear-gradient(135deg, rgba(236, 72, 153, 0.22) 0%, rgba(15, 23, 42, 0.85) 100%);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.35), 0 0 16px rgba(236, 72, 153, 0.16);
}
.sector-dizajn .sector-title {
  color: #fbcfe8;
  text-shadow: 0 0 12px rgba(236, 72, 153, 0.5);
}
.sector-dizajn .sector-badge-pill {
  color: #ec4899;
  border-color: rgba(236, 72, 153, 0.4);
  background: rgba(236, 72, 153, 0.15);
}

.sector-benzinska .sector-header-chip {
  border-color: rgba(239, 68, 68, 0.45);
  background: linear-gradient(135deg, rgba(239, 68, 68, 0.22) 0%, rgba(15, 23, 42, 0.85) 100%);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.35), 0 0 16px rgba(239, 68, 68, 0.16);
}
.sector-benzinska .sector-title {
  color: #fecaca;
  text-shadow: 0 0 12px rgba(239, 68, 68, 0.5);
}
.sector-benzinska .sector-badge-pill {
  color: #ef4444;
  border-color: rgba(239, 68, 68, 0.4);
  background: rgba(239, 68, 68, 0.15);
}

/* ==========================================================================
   UKLANJANJE VIDLJIVOSTI ČLANOVA NIŽIH PIRAMIDA U 2D PROZORU
   ========================================================================== */
.pyramid-container:not(.show-subpyramids) .person-subpyramids,
.pyramid-container:not(.show-subpyramids) .sector-subpyramids,
.pyramid-container:not(.show-subpyramids) .director-subpyramids {
  display: none !important;
}

/* Elegantni bedž podređenih u kartici voditelja */
.member-subordinates-pill {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
  margin-top: 8px;
  padding: 5px 9px;
  border-radius: var(--radius-sm);
  background: rgba(16, 185, 129, 0.1);
  border: 1px solid rgba(16, 185, 129, 0.3);
  color: #6ee7b7;
  font-size: 0.72rem;
  font-weight: 700;
  cursor: pointer;
  transition: var(--transition);
}

.member-subordinates-pill:hover {
  background: rgba(16, 185, 129, 0.22);
  border-color: #10b981;
  color: #fff;
  transform: translateY(-1px);
  box-shadow: 0 3px 10px rgba(16, 185, 129, 0.25);
}

.sub-pill-action {
  font-size: 0.72rem;
  opacity: 0.85;
}

.sector-members {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

/* KARTICA ČLANA TIMA (MEMBER CARD) */
.member-card {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 10px 12px;
  cursor: pointer;
  transition: var(--transition);
  position: relative;
}

.member-card:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: var(--border-highlight);
  transform: translateY(-2px);
  box-shadow: var(--shadow-sm);
}

.member-card.active-selection {
  border-color: var(--primary);
  background: rgba(59, 130, 246, 0.15);
  box-shadow: 0 0 0 1px var(--primary);
}

.member-top {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 8px;
}

.member-avatar {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: linear-gradient(135deg, #334155, #1e293b);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.85rem;
  color: var(--text-light);
  border: 1px solid var(--border-subtle);
  flex-shrink: 0;
}

/* Specifične boje avatara po osobama */
[data-person-id="erna"] .member-avatar { background: linear-gradient(135deg, #059669, #047857); }
[data-person-id="mahir"] .member-avatar { background: linear-gradient(135deg, #2563eb, #1d4ed8); }
[data-person-id="ivo"] .member-avatar { background: linear-gradient(135deg, #3b82f6, #1e40af); }
[data-person-id="jozo-prodaja"] .member-avatar { background: linear-gradient(135deg, #60a5fa, #2563eb); }
[data-person-id="nabava"] .member-avatar { background: linear-gradient(135deg, #0891b2, #0e7490); }
[data-person-id="zeljko"] .member-avatar { background: linear-gradient(135deg, #d97706, #b45309); }
[data-person-id="adi"] .member-avatar { background: linear-gradient(135deg, #7c3aed, #5b21b6); }
[data-person-id="vedran"] .member-avatar { background: linear-gradient(135deg, #db2777, #9d174d); }
[data-person-id="jozo-benzinska"] .member-avatar { background: linear-gradient(135deg, #dc2626, #b91c1c); }
[data-person-id="daniel"] .member-avatar { background: linear-gradient(135deg, #e11d48, #be123c); }
[data-person-id="dragan"] .member-avatar { background: linear-gradient(135deg, #ea580c, #c2410c); }

.member-details {
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.member-name {
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--text-light);
  white-space: nowrap;
  text-overflow: ellipsis;
  overflow: hidden;
}

.member-role {
  font-size: 0.68rem;
  color: var(--text-secondary);
  white-space: nowrap;
  text-overflow: ellipsis;
  overflow: hidden;
}

.member-stats {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-top: 1px solid rgba(255, 255, 255, 0.04);
  padding-top: 6px;
}

.task-count {
  font-size: 0.72rem;
  color: var(--text-secondary);
  font-weight: 600;
}

.task-count.has-tasks {
  color: #93c5fd;
}

.task-count.has-urgent {
  color: #f87171;
  font-weight: 700;
}

.member-quick-add {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--border-subtle);
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.85rem;
  font-weight: bold;
  cursor: pointer;
  transition: var(--transition);
}

.member-quick-add:hover {
  background: var(--primary);
  color: white;
  border-color: var(--primary);
  transform: scale(1.15);
}

/* ==========================================================================
   TASK MANAGER TOOLBAR & FILTERS
   ========================================================================== */
.task-manager-section {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.task-toolbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 16px;
  background: rgba(15, 23, 42, 0.6);
  padding: 14px 18px;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-subtle);
}

.toolbar-left {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
  flex: 1;
  min-width: 280px;
}

.active-filter-indicator {
  display: flex;
  align-items: center;
  gap: 8px;
  background: rgba(255, 255, 255, 0.05);
  padding: 6px 12px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-subtle);
}

.filter-label {
  font-size: 0.75rem;
  color: var(--text-secondary);
}

.filter-badge {
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--primary-light);
}

.btn-clear-filter {
  background: transparent;
  border: none;
  color: var(--text-secondary);
  font-size: 0.75rem;
  cursor: pointer;
  padding: 2px 5px;
  border-radius: 4px;
}

.btn-clear-filter:hover {
  background: rgba(239, 68, 68, 0.2);
  color: #ef4444;
}

.search-box {
  display: flex;
  align-items: center;
  gap: 8px;
  background: rgba(0, 0, 0, 0.25);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 8px 12px;
  flex: 1;
  max-width: 400px;
  color: var(--text-secondary);
}

.search-box:focus-within {
  border-color: var(--primary);
  box-shadow: 0 0 0 1px var(--primary);
}

.search-box input {
  background: transparent;
  border: none;
  color: var(--text-primary);
  font-size: 0.85rem;
  width: 100%;
  outline: none;
  font-family: inherit;
}

.btn-clear-search {
  background: none;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  font-size: 0.75rem;
}

.toolbar-right {
  display: flex;
  align-items: center;
  gap: 10px;
}

.form-select-sm {
  background: rgba(0, 0, 0, 0.3);
  border: 1px solid var(--border-subtle);
  color: var(--text-primary);
  padding: 7px 12px;
  border-radius: var(--radius-md);
  font-size: 0.82rem;
  font-family: inherit;
  cursor: pointer;
  outline: none;
}

.form-select-sm:focus {
  border-color: var(--primary);
}

.view-switcher {
  display: flex;
  background: rgba(0, 0, 0, 0.3);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 4px;
  gap: 4px;
}

.view-btn {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  background: transparent;
  border: none;
  color: var(--text-secondary);
  border-radius: 6px;
  font-size: 0.8rem;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition);
  font-family: inherit;
}

.view-btn.active {
  background: rgba(255, 255, 255, 0.1);
  color: var(--text-light);
}

/* ==========================================================================
   KANBAN BOARD VIEW
   ========================================================================== */
.board-view {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  min-height: 480px;
}

.kanban-col {
  background: rgba(15, 23, 42, 0.5);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.kanban-col-header {
  padding: 14px 16px;
  border-bottom: 1px solid var(--border-subtle);
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-weight: 700;
  font-size: 0.86rem;
  background: rgba(255, 255, 255, 0.02);
}

.col-title {
  display: flex;
  align-items: center;
  gap: 8px;
}

.status-dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
}

.status-new .status-dot { background-color: var(--status-new); box-shadow: 0 0 8px var(--status-new); }
.status-inprogress .status-dot { background-color: var(--status-inprogress); box-shadow: 0 0 8px var(--status-inprogress); }
.status-review .status-dot { background-color: var(--status-review); box-shadow: 0 0 8px var(--status-review); }
.status-done .status-dot { background-color: var(--status-done); box-shadow: 0 0 8px var(--status-done); }

.col-badge {
  font-size: 0.74rem;
  padding: 2px 8px;
  background: rgba(255, 255, 255, 0.07);
  border-radius: var(--radius-full);
  color: var(--text-secondary);
}

.kanban-cards-list {
  padding: 14px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  flex: 1;
  overflow-y: auto;
  max-height: 750px;
}

/* ==========================================================================
   TASK CARDS (KARTICA ZADATKA)
   ========================================================================== */
.task-card {
  background: rgba(26, 36, 58, 0.7);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 14px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  position: relative;
  transition: var(--transition);
  box-shadow: var(--shadow-sm);
}

.task-card:hover {
  background: rgba(33, 46, 73, 0.9);
  border-color: var(--border-highlight);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.task-card.is-director-task {
  border-left: 4px solid #f59e0b;
}

.task-card.priority-urgent {
  border-left: 4px solid var(--status-urgent);
}

.task-card-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 8px;
}

.task-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: center;
}

.tag-sector {
  font-size: 0.68rem;
  font-weight: 700;
  text-transform: uppercase;
  padding: 2px 7px;
  border-radius: 4px;
  letter-spacing: 0.04em;
}

.tag-sector.sec-financije { background: rgba(16, 185, 129, 0.15); color: #34d399; }
.tag-sector.sec-prodaja { background: rgba(59, 130, 246, 0.15); color: #60a5fa; }
.tag-sector.sec-nabava { background: rgba(6, 182, 212, 0.15); color: #22d3ee; }
.tag-sector.sec-skladiste { background: rgba(245, 158, 11, 0.15); color: #fbbf24; }
.tag-sector.sec-informatika { background: rgba(139, 92, 246, 0.15); color: #a78bfa; }
.tag-sector.sec-dizajn { background: rgba(236, 72, 153, 0.15); color: #f472b6; }
.tag-sector.sec-benzinska { background: rgba(239, 68, 68, 0.15); color: #f87171; }
.tag-sector.sec-uprava { background: rgba(245, 158, 11, 0.2); color: #fde68a; }

.tag-priority {
  font-size: 0.68rem;
  font-weight: 700;
  padding: 2px 6px;
  border-radius: 4px;
}

.priority-urgent-pill { background: rgba(239, 68, 68, 0.2); color: #fca5a5; border: 1px solid rgba(239, 68, 68, 0.3); }
.priority-medium-pill { background: rgba(234, 179, 8, 0.15); color: #fef08a; }
.priority-normal-pill { background: rgba(100, 116, 139, 0.2); color: #cbd5e1; }

.task-card-title {
  font-size: 0.92rem;
  font-weight: 700;
  color: var(--text-light);
  line-height: 1.35;
}

.task-card-desc {
  font-size: 0.78rem;
  color: var(--text-secondary);
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.task-card-director-note {
  font-size: 0.74rem;
  background: rgba(245, 158, 11, 0.1);
  border-left: 2px solid #f59e0b;
  padding: 4px 8px;
  border-radius: 0 4px 4px 0;
  color: #fde68a;
  font-style: italic;
}

.task-card-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 8px;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  font-size: 0.75rem;
}

.task-assignee-badge {
  display: flex;
  align-items: center;
  gap: 6px;
  color: var(--text-primary);
  font-weight: 600;
}

.assignee-avatar-sm {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: #3b82f6;
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.65rem;
  font-weight: 700;
}

.task-deadline-badge {
  display: flex;
  align-items: center;
  gap: 4px;
  color: var(--text-secondary);
}

.task-deadline-badge.overdue {
  color: #ef4444;
  font-weight: 700;
}

.task-deadline-badge.today {
  color: #eab308;
  font-weight: 700;
}

/* Gumbi unutar kartice zadatka */
.task-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
  margin-top: 4px;
}

.task-status-btn-group {
  display: flex;
  gap: 4px;
  flex: 1;
}

.btn-task-action {
  padding: 4px 8px;
  font-size: 0.72rem;
  font-weight: 600;
  border-radius: 5px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.05);
  color: var(--text-secondary);
  cursor: pointer;
  transition: var(--transition);
  font-family: inherit;
}

.btn-task-action:hover {
  background: rgba(255, 255, 255, 0.12);
  color: var(--text-light);
}

.btn-approve-director {
  background: linear-gradient(135deg, #10b981, #059669);
  color: white;
  border: none;
  font-weight: 700;
  box-shadow: 0 2px 8px rgba(16, 185, 129, 0.3);
}

.btn-approve-director:hover {
  background: linear-gradient(135deg, #34d399, #10b981);
}

.btn-review-ready {
  background: rgba(249, 115, 22, 0.18);
  color: #fdba74;
  border-color: rgba(249, 115, 22, 0.4);
}

.btn-review-ready:hover {
  background: rgba(249, 115, 22, 0.3);
  color: #fff;
}

.task-more-menu {
  display: flex;
  gap: 4px;
}

.btn-icon-task {
  width: 24px;
  height: 24px;
  border-radius: 4px;
  background: transparent;
  border: none;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: var(--transition);
}

.btn-icon-task:hover {
  color: var(--text-light);
  background: rgba(255, 255, 255, 0.08);
}

.btn-icon-task.delete:hover {
  color: #ef4444;
  background: rgba(239, 68, 68, 0.15);
}

/* ==========================================================================
   TABLIČNI PRIKAZ (TABLE / LIST VIEW)
   ========================================================================== */
.table-responsive {
  width: 100%;
  overflow-x: auto;
}

.tasks-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.85rem;
}

.tasks-table th {
  text-align: left;
  padding: 12px 16px;
  background: rgba(255, 255, 255, 0.03);
  color: var(--text-secondary);
  font-weight: 600;
  border-bottom: 1px solid var(--border-subtle);
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.tasks-table td {
  padding: 14px 16px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.04);
  vertical-align: middle;
}

.tasks-table tr:hover td {
  background: rgba(255, 255, 255, 0.02);
}

.table-task-title {
  font-weight: 700;
  color: var(--text-light);
  margin-bottom: 2px;
}

.table-task-desc {
  font-size: 0.75rem;
  color: var(--text-secondary);
}

.status-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  border-radius: var(--radius-full);
  font-size: 0.74rem;
  font-weight: 700;
}

.status-pill-new { background: rgba(56, 189, 248, 0.15); color: #38bdf8; }
.status-pill-in-progress { background: rgba(234, 179, 8, 0.15); color: #facc15; }
.status-pill-review { background: rgba(249, 115, 22, 0.2); color: #fb923c; border: 1px solid rgba(249, 115, 22, 0.3); }
.status-pill-done { background: rgba(16, 185, 129, 0.15); color: #34d399; }

/* Empty state */
.empty-state-notice {
  text-align: center;
  padding: 60px 20px;
  color: var(--text-secondary);
}

.empty-icon {
  font-size: 3rem;
  margin-bottom: 10px;
}

.empty-state-notice h3 {
  color: var(--text-light);
  margin-bottom: 6px;
}

.empty-state-notice p {
  font-size: 0.88rem;
  margin-bottom: 16px;
}

/* ==========================================================================
   MODALNI PROZOR
   ========================================================================== */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.75);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  padding: 20px;
  animation: fadeIn 0.2s ease;
}

.modal-window {
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-highlight);
  border-radius: var(--radius-xl);
  width: 100%;
  max-width: 620px;
  max-height: 90vh;
  display: flex;
  flex-direction: column;
  box-shadow: var(--shadow-lg), var(--shadow-glow);
  overflow: hidden;
  animation: slideUp 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes slideUp {
  from { transform: translateY(20px) scale(0.97); opacity: 0; }
  to { transform: translateY(0) scale(1); opacity: 1; }
}

.modal-header {
  padding: 18px 24px;
  border-bottom: 1px solid var(--border-subtle);
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-shrink: 0;
  background: rgba(15, 23, 42, 0.6);
}

.modal-header h3 {
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--text-light);
}

.modal-close {
  background: none;
  border: none;
  color: var(--text-secondary);
  font-size: 1.1rem;
  cursor: pointer;
  padding: 4px 8px;
  border-radius: var(--radius-sm);
  transition: var(--transition);
}

.modal-close:hover {
  background: rgba(255, 255, 255, 0.1);
  color: var(--text-light);
}

#task-form {
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  overflow-y: auto;
  flex: 1;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.form-row {
  display: flex;
  gap: 16px;
}

.col-6 {
  flex: 1;
}

.form-label {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-secondary);
}

.required {
  color: #ef4444;
}

.form-input, .form-select, .form-textarea {
  background: rgba(10, 14, 26, 0.8);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 10px 14px;
  color: var(--text-primary);
  font-size: 0.88rem;
  font-family: inherit;
  outline: none;
  transition: var(--transition);
}

.form-input:focus, .form-select:focus, .form-textarea:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 1px var(--primary);
}

.form-select optgroup {
  background: #111827;
  color: #93c5fd;
  font-weight: 700;
}

.form-select option {
  background: #1f2937;
  color: #f1f5f9;
}

.modal-footer {
  display: flex;
  justify-content: flex-end;
  gap: 12px;
  margin-top: 10px;
  padding-top: 16px;
  border-top: 1px solid var(--border-subtle);
}

/* ==========================================================================
   TOAST NOTIFIKACIJE
   ========================================================================== */
.toast-container {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 2000;
  display: flex;
  flex-direction: column;
  gap: 10px;
  pointer-events: none;
}

.toast {
  background: #1e293b;
  border: 1px solid var(--border-highlight);
  color: var(--text-light);
  padding: 12px 18px;
  border-radius: var(--radius-md);
  font-size: 0.85rem;
  font-weight: 600;
  box-shadow: var(--shadow-lg);
  display: flex;
  align-items: center;
  gap: 10px;
  pointer-events: auto;
  animation: slideInRight 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  max-width: 360px;
}

.toast-success { border-left: 4px solid #10b981; }
.toast-info { border-left: 4px solid #3b82f6; }
.toast-warning { border-left: 4px solid #f59e0b; }

@keyframes slideInRight {
  from { transform: translateX(100%); opacity: 0; }
  to { transform: translateX(0); opacity: 1; }
}

/* ==========================================================================
   FOOTER
   ========================================================================== */
.app-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 20px;
  border-top: 1px solid var(--border-subtle);
  color: var(--text-muted);
  font-size: 0.78rem;
  flex-wrap: wrap;
  gap: 12px;
}

/* ==========================================================================
   RESPONSIVNOST
   ========================================================================== */
@media (max-width: 1280px) {
  .board-view {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 900px) {
  .board-view {
    grid-template-columns: 1fr;
  }
  
  .form-row {
    flex-direction: column;
  }
  
  .task-toolbar {
    flex-direction: column;
    align-items: stretch;
  }
  
  .toolbar-right {
    justify-content: space-between;
  }
}

/* ==========================================================================
   SLIKE U ZADACIMA (IMAGES & ATTACHMENTS)
   ========================================================================== */
.task-card-images {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(68px, 1fr));
  gap: 6px;
  margin-top: 4px;
}

.task-thumb-wrap {
  position: relative;
  height: 64px;
  border-radius: var(--radius-sm);
  overflow: hidden;
  border: 1px solid var(--border-subtle);
  cursor: pointer;
  background: #0b0f19;
}

.task-thumb-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.25s ease;
}

.task-thumb-wrap:hover img {
  transform: scale(1.08);
}

.task-thumb-more-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.65);
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.8rem;
  font-weight: 700;
}

/* Modal Images Preview */
.form-section-divider {
  border-top: 1px solid var(--border-subtle);
  padding-top: 14px;
  margin-top: 4px;
}

.form-section-title {
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--text-light);
  letter-spacing: 0.02em;
}

.image-upload-wrapper {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.upload-hint {
  font-size: 0.72rem;
  color: var(--text-muted);
}

.modal-images-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 8px;
  min-height: 20px;
}

.modal-image-item {
  position: relative;
  width: 76px;
  height: 76px;
  border-radius: var(--radius-sm);
  overflow: hidden;
  border: 1px solid var(--border-highlight);
  background: #0b0f19;
}

.modal-image-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.btn-remove-img {
  position: absolute;
  top: 3px;
  right: 3px;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: rgba(239, 68, 68, 0.9);
  color: white;
  border: none;
  font-size: 0.7rem;
  font-weight: bold;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
}

.btn-remove-img:hover {
  background: #dc2626;
  transform: scale(1.1);
}

/* Badges for Images & Comments on Cards */
.card-indicators {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.72rem;
  color: var(--text-secondary);
}

.indicator-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 2px 6px;
  border-radius: 4px;
  background: rgba(255, 255, 255, 0.05);
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition);
}

.indicator-badge:hover {
  background: rgba(255, 255, 255, 0.12);
  color: var(--text-light);
}

/* ==========================================================================
   KOMENTARI (COMMENTS & DISCUSSION)
   ========================================================================== */
.comments-section {
  display: flex;
  flex-direction: column;
  gap: 12px;
  background: rgba(10, 15, 28, 0.6);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 12px;
}

.comments-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
  max-height: 200px;
  overflow-y: auto;
  padding-right: 4px;
}

.comments-empty-notice {
  font-size: 0.78rem;
  color: var(--text-muted);
  text-align: center;
  padding: 14px;
  font-style: italic;
}

.comment-bubble {
  display: flex;
  gap: 10px;
  padding: 8px 10px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  font-size: 0.8rem;
}

.comment-bubble.from-director {
  background: rgba(245, 158, 11, 0.08);
  border-color: rgba(245, 158, 11, 0.25);
}

.comment-avatar {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: #3b82f6;
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.72rem;
  font-weight: 700;
  flex-shrink: 0;
}

.comment-avatar.dir-avatar {
  background: linear-gradient(135deg, #f59e0b, #d97706);
  color: #1e1b4b;
}

.comment-body {
  display: flex;
  flex-direction: column;
  gap: 2px;
  flex: 1;
}

.comment-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.comment-author-name {
  font-weight: 700;
  color: var(--text-light);
  font-size: 0.78rem;
}

.comment-bubble.from-director .comment-author-name {
  color: #fbbf24;
}

.comment-time {
  font-size: 0.68rem;
  color: var(--text-muted);
}

.comment-text {
  color: var(--text-primary);
  line-height: 1.35;
  word-break: break-word;
}

/* Compose comment */
.comment-compose-box {
  display: flex;
  flex-direction: column;
  gap: 8px;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  padding-top: 10px;
}

.comment-compose-header {
  display: flex;
  align-items: center;
  gap: 8px;
}

.form-label-xs {
  font-size: 0.72rem;
  color: var(--text-secondary);
  font-weight: 600;
}

.form-select-xs {
  background: rgba(0, 0, 0, 0.4);
  border: 1px solid var(--border-subtle);
  color: var(--text-light);
  padding: 3px 8px;
  border-radius: 4px;
  font-size: 0.74rem;
  outline: none;
  font-family: inherit;
}

.comment-input-wrap {
  display: flex;
  gap: 8px;
  align-items: flex-end;
}

.form-textarea-sm {
  flex: 1;
  background: rgba(0, 0, 0, 0.35);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  padding: 8px 10px;
  color: var(--text-primary);
  font-size: 0.82rem;
  font-family: inherit;
  outline: none;
  resize: vertical;
}

.form-textarea-sm:focus {
  border-color: var(--primary);
}

/* ==========================================================================
   LIGHTBOX (FULLSCREEN IMAGE MODAL)
   ========================================================================== */
.lightbox-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.88);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  z-index: 3000;
  display: flex;
  align-items: center;
  justify-content: center;
  animation: fadeIn 0.2s ease;
  padding: 24px;
}

.lightbox-content {
  position: relative;
  max-width: 90vw;
  max-height: 85vh;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.lightbox-content img {
  max-width: 100%;
  max-height: 80vh;
  object-fit: contain;
  border-radius: var(--radius-md);
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.8);
  border: 1px solid var(--border-highlight);
}

.lightbox-caption {
  margin-top: 10px;
  color: var(--text-secondary);
  font-size: 0.85rem;
  font-weight: 500;
  text-align: center;
}

.lightbox-close {
  position: absolute;
  top: 24px;
  right: 28px;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: white;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  font-size: 1.2rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
  z-index: 3010;
}

.lightbox-close:hover {
  background: rgba(239, 68, 68, 0.8);
  transform: scale(1.1);
}

/* ==========================================================================
   POP-UP PROZOR RADNIKA (WORKER TASKS MODAL)
   ========================================================================== */
.worker-modal-window {
  max-width: 820px;
  width: 95%;
  max-height: 90vh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.worker-modal-header {
  padding: 20px 24px;
  border-bottom: 1px solid var(--border-subtle);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  background: rgba(15, 23, 42, 0.6);
}

.worker-modal-profile {
  display: flex;
  align-items: center;
  gap: 16px;
}

.worker-modal-avatar {
  width: 50px;
  height: 50px;
  border-radius: 50%;
  background: linear-gradient(135deg, #3b82f6, #1d4ed8);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.35rem;
  font-weight: 800;
  color: white;
  border: 2px solid rgba(255, 255, 255, 0.15);
  box-shadow: var(--shadow-sm);
  flex-shrink: 0;
}

.worker-modal-info {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.worker-modal-sector-chip {
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--primary-light);
}

.worker-modal-name {
  font-size: 1.3rem;
  font-weight: 800;
  color: var(--text-light);
  line-height: 1.2;
}

.worker-modal-role {
  font-size: 0.8rem;
  color: var(--text-secondary);
}

.worker-modal-header-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

/* Tabs */
.worker-modal-tabs {
  display: flex;
  background: rgba(10, 15, 28, 0.7);
  padding: 8px 24px;
  gap: 8px;
  border-bottom: 1px solid var(--border-subtle);
  overflow-x: auto;
}

.worker-tab-btn {
  background: transparent;
  border: 1px solid transparent;
  color: var(--text-secondary);
  font-size: 0.8rem;
  font-weight: 600;
  padding: 6px 14px;
  border-radius: var(--radius-full);
  cursor: pointer;
  transition: var(--transition);
  font-family: inherit;
  white-space: nowrap;
}

.worker-tab-btn:hover {
  background: rgba(255, 255, 255, 0.06);
  color: var(--text-light);
}

.worker-tab-btn.active {
  background: rgba(59, 130, 246, 0.18);
  color: var(--primary-light);
  border-color: rgba(59, 130, 246, 0.4);
}

/* Body & Items */
.worker-modal-body {
  padding: 20px 24px;
  overflow-y: auto;
  flex: 1;
  max-height: 58vh;
  display: flex;
  flex-direction: column;
}

.worker-tasks-list {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.worker-task-card {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  transition: var(--transition);
}

.worker-task-card:hover {
  background: rgba(255, 255, 255, 0.06);
  border-color: var(--border-highlight);
  box-shadow: var(--shadow-sm);
}

.worker-task-card.is-urgent {
  border-left: 4px solid var(--status-urgent);
}

.worker-task-card-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
}

.worker-task-card-title {
  font-size: 0.98rem;
  font-weight: 700;
  color: var(--text-light);
  line-height: 1.3;
}

.worker-task-card-desc {
  font-size: 0.82rem;
  color: var(--text-secondary);
  line-height: 1.45;
}

.worker-task-card-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
  padding-top: 10px;
  margin-top: 2px;
}

.worker-modal-footer {
  padding: 14px 24px;
  border-top: 1px solid var(--border-subtle);
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: rgba(15, 23, 42, 0.5);
}

/* ==========================================================================
   PODPIRAMIDE (SUB-PYRAMIDS) & HIJERARHIJSKA STRUKTURA
   ========================================================================== */

/* Gumbi za otvaranje podpiramide */
.btn-primary-soft {
  background: rgba(16, 185, 129, 0.16);
  color: #34d399;
  border: 1px solid rgba(16, 185, 129, 0.35);
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  cursor: pointer;
  transition: var(--transition);
}

.btn-primary-soft:hover {
  background: rgba(16, 185, 129, 0.28);
  border-color: #10b981;
  color: #a7f3d0;
  transform: translateY(-1px);
  box-shadow: 0 4px 14px rgba(16, 185, 129, 0.25);
}

.btn-3d-subpyramid {
  border-color: rgba(16, 185, 129, 0.4) !important;
  color: #6ee7b7 !important;
  background: rgba(16, 185, 129, 0.12) !important;
}

.btn-3d-subpyramid:hover {
  background: rgba(16, 185, 129, 0.25) !important;
  border-color: #10b981 !important;
  color: #ffffff !important;
  box-shadow: 0 0 14px rgba(16, 185, 129, 0.4) !important;
}

.sector-group.sector-pyramid-open {
  outline: 2px solid var(--primary-light);
  outline-offset: 2px;
  box-shadow: 0 0 25px rgba(59, 130, 246, 0.35);
  position: relative;
}

.sector-group.sector-pyramid-open::after {
  content: '▼ PIRAMIDA OTVORENA';
  position: absolute;
  bottom: -11px;
  left: 50%;
  transform: translateX(-50%);
  background: #2563eb;
  color: #fff;
  font-size: 0.58rem;
  font-weight: 800;
  padding: 1px 7px;
  border-radius: 999px;
  letter-spacing: 0.05em;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.5);
  z-index: 5;
  white-space: nowrap;
}

/* Gumbi na kartici člana */
.member-card-btns {
  display: flex;
  align-items: center;
  gap: 5px;
}

.member-add-sub {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: rgba(16, 185, 129, 0.12);
  border: 1px solid rgba(16, 185, 129, 0.3);
  color: #34d399;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.72rem;
  cursor: pointer;
  transition: var(--transition);
}

.member-add-sub:hover {
  background: #10b981;
  color: #064e3b;
  border-color: #10b981;
  transform: scale(1.15);
}

.btn-director-sub {
  background: rgba(16, 185, 129, 0.15) !important;
  color: #6ee7b7 !important;
  border-color: rgba(16, 185, 129, 0.35) !important;
}

.btn-director-sub:hover {
  background: rgba(16, 185, 129, 0.3) !important;
  color: #ffffff !important;
}

/* Podređene kartice direktora (Ured uprave / Savjetnici) */
.director-subpyramids {
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 14px;
  padding-top: 12px;
  border-top: 1px dashed rgba(245, 158, 11, 0.3);
}

.director-subpyramids:empty {
  display: none;
}

.director-subpyramids-title {
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #fde68a;
  display: flex;
  align-items: center;
  gap: 6px;
}

/* Kontejneri podređenih kartica unutar sektora i osoba */
.sector-subpyramids,
.person-subpyramids {
  display: flex;
  flex-direction: column;
  gap: 7px;
  margin-top: 6px;
  position: relative;
}

.sector-subpyramids:empty,
.person-subpyramids:empty {
  display: none;
}

.person-subpyramids {
  padding-left: 12px;
  border-left: 2px dashed rgba(255, 255, 255, 0.15);
  margin-left: 8px;
}

.sector-subpyramids {
  padding-top: 8px;
  border-top: 1px dashed rgba(255, 255, 255, 0.12);
}

.subpyramid-section-title {
  font-size: 0.65rem;
  font-weight: 700;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin-bottom: 2px;
  display: flex;
  align-items: center;
  gap: 4px;
}

/* Pojedinačna kartica podpiramide (podređeni član ili podtim) */
.sub-member-card {
  background: rgba(15, 23, 42, 0.7);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: var(--radius-md);
  padding: 8px 10px;
  cursor: pointer;
  transition: var(--transition);
  position: relative;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.25);
}

.sub-member-card:hover {
  background: rgba(30, 41, 59, 0.85);
  border-color: var(--border-highlight);
  transform: translateX(2px);
  box-shadow: var(--shadow-sm);
}

.sub-member-card.is-unit {
  background: rgba(30, 41, 59, 0.5);
  border-style: dashed;
}

.sub-member-card.active-selection {
  border-color: var(--primary);
  background: rgba(59, 130, 246, 0.15);
  box-shadow: 0 0 0 1px var(--primary);
}

.sub-member-top {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 6px;
}

.sub-member-avatar {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
  font-weight: 700;
  color: #fff;
  flex-shrink: 0;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.3);
}

.sub-member-info {
  display: flex;
  flex-direction: column;
  overflow: hidden;
  flex: 1;
}

.sub-member-name-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 4px;
}

.sub-member-name {
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--text-light);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.sub-type-badge {
  font-size: 0.58rem;
  font-weight: 700;
  padding: 1px 5px;
  border-radius: var(--radius-full);
  background: rgba(255, 255, 255, 0.08);
  color: var(--text-secondary);
  white-space: nowrap;
}

.sub-member-role {
  font-size: 0.65rem;
  color: var(--text-secondary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.sub-member-stats {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
  padding-top: 5px;
  margin-top: 2px;
}

.sub-card-delete {
  background: transparent;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  font-size: 0.75rem;
  padding: 2px 4px;
  border-radius: 4px;
  line-height: 1;
  transition: var(--transition);
}

.sub-card-delete:hover {
  color: #ef4444;
  background: rgba(239, 68, 68, 0.15);
}

/* ==========================================================================
   MODAL ZA DODAVANJE PODPIRAMIDE (STILIZACIJA)
   ========================================================================== */
.subpyramid-modal-window {
  max-width: 540px;
  width: 95%;
}

.modal-title-with-badge {
  display: flex;
  align-items: center;
  gap: 12px;
}

.modal-badge-icon {
  width: 42px;
  height: 42px;
  border-radius: 12px;
  background: rgba(16, 185, 129, 0.15);
  border: 1px solid rgba(16, 185, 129, 0.35);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.4rem;
  color: #34d399;
}

.modal-subtitle {
  font-size: 0.78rem;
  color: var(--text-secondary);
  margin-top: 2px;
}

.subpyramid-type-selector {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-top: 6px;
}

.type-radio-card {
  display: flex;
  align-items: center;
  padding: 12px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: var(--transition);
  position: relative;
}

.type-radio-card input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.type-radio-card:hover {
  background: rgba(255, 255, 255, 0.06);
  border-color: var(--border-highlight);
}

.type-radio-card.active {
  background: rgba(16, 185, 129, 0.12);
  border-color: #10b981;
  box-shadow: 0 0 0 1px #10b981;
}

.type-radio-content {
  display: flex;
  align-items: center;
  gap: 10px;
}

.type-radio-icon {
  font-size: 1.5rem;
}

.type-radio-content strong {
  display: block;
  font-size: 0.82rem;
  color: var(--text-light);
  line-height: 1.2;
}

.type-radio-content small {
  display: block;
  font-size: 0.68rem;
  color: var(--text-secondary);
  margin-top: 2px;
}

.form-hint {
  display: block;
  font-size: 0.72rem;
  color: var(--text-muted);
  margin-top: 5px;
}

/* ==========================================================================
   VIZUALNA PIRAMIDA SEKORA (SECTOR VISUAL PYRAMID)
   Prikaz hijerarhijske strukture pojedinog sektora s voditeljem i radnicima
   ========================================================================== */

.sector-pyramid-wrapper {
  width: 100%;
  max-width: 1600px;
  margin: 22px 0 10px;
  animation: slideDownPyramid 0.35s cubic-bezier(0.16, 1, 0.3, 1);
}

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

.sector-pyramid-panel {
  background: linear-gradient(180deg, rgba(16, 23, 42, 0.96), rgba(15, 23, 42, 0.98));
  backdrop-filter: blur(20px);
  border: 1px solid var(--border-highlight);
  border-radius: var(--radius-xl);
  padding: 24px 28px;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.6), inset 0 1px 0 rgba(255, 255, 255, 0.1);
  position: relative;
  overflow: hidden;
}

/* Zaglavlje sektorske piramide */
.sector-pyramid-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--border-subtle);
}

.sector-pyramid-header-left {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 14px;
}

.sector-badge-pill {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 16px;
  background: rgba(255, 255, 255, 0.05);
  border: 1.5px solid;
  border-radius: var(--radius-full);
}

.sector-badge-icon {
  font-size: 1.25rem;
}

.sector-badge-title {
  font-size: 0.92rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  color: #fff;
}

.sector-pyramid-meta-tags {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.meta-tag {
  font-size: 0.76rem;
  font-weight: 600;
  color: var(--text-secondary);
  background: rgba(255, 255, 255, 0.05);
  padding: 4px 10px;
  border-radius: var(--radius-full);
  border: 1px solid var(--border-subtle);
}

.meta-tag-leader {
  font-size: 0.78rem;
  color: var(--text-light);
  background: rgba(245, 158, 11, 0.12);
  border: 1px solid rgba(245, 158, 11, 0.3);
  padding: 4px 10px;
  border-radius: var(--radius-full);
}

.sector-pyramid-header-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.btn-sec-close {
  background: rgba(239, 68, 68, 0.12);
  color: #fca5a5;
  border: 1px solid rgba(239, 68, 68, 0.3);
  border-radius: var(--radius-sm);
  padding: 6px 12px;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition);
}

.btn-sec-close:hover {
  background: rgba(239, 68, 68, 0.3);
  color: #fff;
}

/* Sektorski tab switcher (Pills) */
.sector-switcher-bar {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 16px 0 24px;
  padding: 8px 14px;
  background: rgba(0, 0, 0, 0.28);
  border-radius: var(--radius-full);
  border: 1px solid rgba(255, 255, 255, 0.04);
  overflow-x: auto;
}

.sector-switcher-label {
  font-size: 0.74rem;
  font-weight: 700;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  white-space: nowrap;
}

.sector-switcher-pills {
  display: flex;
  align-items: center;
  gap: 6px;
  overflow-x: auto;
}

.sector-switcher-pill {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 5px 12px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-full);
  color: var(--text-secondary);
  font-size: 0.74rem;
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
  transition: var(--transition);
}

.sector-switcher-pill:hover {
  background: rgba(255, 255, 255, 0.1);
  color: var(--text-light);
  transform: translateY(-1px);
}

.sector-switcher-pill.active {
  font-weight: 800;
}

/* Tijelo piramide sektora */
.sector-pyramid-body {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding-top: 10px;
  position: relative;
  width: 100%;
}

/* Vrh piramide sektora (Apex - Voditelj) */
.sector-pyramid-apex {
  display: flex;
  justify-content: center;
  position: relative;
  z-index: 3;
}

.sector-leader-card {
  background: linear-gradient(135deg, rgba(30, 41, 59, 0.95), rgba(15, 23, 42, 0.95));
  border: 2px solid;
  border-radius: var(--radius-xl);
  padding: 16px 22px;
  width: 320px;
  max-width: 95%;
  position: relative;
  transition: var(--transition);
  cursor: pointer;
}

.sector-leader-card:hover {
  transform: translateY(-2px);
}

.sector-leader-crown {
  position: absolute;
  top: -12px;
  right: 20px;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.82rem;
  color: #fff;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.4);
}

.sector-leader-top {
  display: flex;
  align-items: center;
  gap: 14px;
}

.sector-leader-avatar {
  width: 48px;
  height: 48px;
  border-radius: var(--radius-md);
  color: #fff;
  font-weight: 800;
  font-size: 1.25rem;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.35);
  flex-shrink: 0;
}

.sector-leader-info {
  flex: 1;
  min-width: 0;
}

.sector-leader-role-badge {
  font-size: 0.65rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.sector-leader-name {
  font-size: 1.1rem;
  font-weight: 800;
  color: var(--text-light);
  line-height: 1.2;
}

.sector-leader-role {
  font-size: 0.74rem;
  color: var(--text-secondary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.sector-leader-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 12px;
  padding-top: 10px;
  border-top: 1px solid var(--border-subtle);
}

.sector-leader-btns {
  display: flex;
  align-items: center;
  gap: 6px;
}

/* Povezne linije unutar piramide sektora */
.sector-pyramid-connector {
  width: 90%;
  max-width: 1200px;
  display: flex;
  flex-direction: column;
  align-items: center;
  margin: -2px 0 16px;
  position: relative;
}

.sec-connector-vertical {
  width: 2px;
  height: 22px;
}

.sec-connector-horizontal {
  width: 100%;
  height: 2px;
  position: relative;
}

.sec-connector-drop-lines {
  width: 100%;
  display: flex;
  justify-content: space-around;
}

.sec-drop-line {
  width: 2px;
  height: 16px;
}

/* Mini konektori za ugniježđenu 3. razinu */
.nested-level3-branch {
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 100%;
  margin-top: 6px;
}

.sec-connector-vertical.mini {
  height: 14px;
}

.sec-connector-horizontal.mini {
  width: 80%;
  height: 2px;
}

.sec-connector-drop-lines.mini {
  width: 80%;
  display: flex;
  justify-content: space-around;
}

.sec-connector-drop-lines.mini .sec-drop-line {
  height: 12px;
}

.nested-level3-cards {
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: wrap;
  width: 100%;
}

/* Baza piramide sektora: Level 2 i 3 */
.sector-pyramid-level-subs {
  display: flex;
  justify-content: center;
  gap: 20px;
  flex-wrap: wrap;
  width: 100%;
  z-index: 2;
}

.sector-sub-branch-wrapper {
  display: flex;
  flex-direction: column;
  align-items: center;
  min-width: 220px;
  max-width: 280px;
  flex: 1 1 230px;
}

.sector-sub-card {
  background: rgba(20, 29, 48, 0.85);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 14px 16px;
  width: 100%;
  position: relative;
  transition: var(--transition);
  cursor: pointer;
  box-shadow: var(--shadow-sm);
}

.sector-sub-card:hover {
  transform: translateY(-3px);
  background: rgba(28, 41, 68, 0.95);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.45);
  border-color: var(--border-highlight);
}

.sector-sub-card.is-unit {
  background: rgba(23, 37, 66, 0.9);
}

.sub-card-type-tag {
  font-size: 0.64rem;
  font-weight: 800;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  margin-bottom: 6px;
}

.sub-card-header {
  display: flex;
  align-items: center;
  gap: 10px;
}

.sub-card-avatar {
  width: 38px;
  height: 38px;
  border-radius: var(--radius-sm);
  color: #fff;
  font-weight: 800;
  font-size: 1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

.sub-card-details {
  flex: 1;
  min-width: 0;
}

.sub-card-name {
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--text-light);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.sub-card-role {
  font-size: 0.70rem;
  color: var(--text-secondary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.sub-card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 10px;
  padding-top: 8px;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
}

.sub-card-actions {
  display: flex;
  align-items: center;
  gap: 4px;
}

.sec-btn-icon {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.15);
  color: #cbd5e1;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.7rem;
  cursor: pointer;
  transition: var(--transition);
}

.sec-btn-icon:hover {
  background: rgba(255, 255, 255, 0.2);
  color: #fff;
  transform: scale(1.1);
}

.sec-btn-add:hover {
  background: #3b82f6;
  border-color: #3b82f6;
  color: #fff;
}

.sec-btn-sub {
  background: rgba(16, 185, 129, 0.15);
  border-color: rgba(16, 185, 129, 0.3);
  color: #34d399;
}

.sec-btn-sub:hover {
  background: #10b981;
  border-color: #10b981;
  color: #064e3b;
}

.sec-btn-del:hover {
  background: #ef4444;
  border-color: #ef4444;
  color: #fff;
}

/* Empty state ako sektor nema podređenih */
.sector-empty-pyramid-prompt {
  background: rgba(255, 255, 255, 0.02);
  border: 2px dashed rgba(255, 255, 255, 0.15);
  border-radius: var(--radius-lg);
  padding: 24px 32px;
  text-align: center;
  cursor: pointer;
  transition: var(--transition);
  max-width: 480px;
}

.sector-empty-pyramid-prompt:hover {
  background: rgba(255, 255, 255, 0.05);
  border-color: var(--primary-light);
  transform: translateY(-2px);
}

.empty-prompt-icon {
  font-size: 1.8rem;
  margin-bottom: 6px;
}

.empty-prompt-title {
  font-size: 0.92rem;
  font-weight: 700;
  color: var(--text-light);
  margin-bottom: 4px;
}

.empty-prompt-desc {
  font-size: 0.74rem;
  color: var(--text-secondary);
  line-height: 1.4;
}

/* ==========================================================================
   DRAG & DROP GRADITELJ ORGANIZACIJSKE STRUKTURE & TRASH DROPZONE
   ========================================================================== */

.org-builder-dock {
  background: linear-gradient(135deg, rgba(15, 23, 42, 0.95), rgba(30, 41, 59, 0.85));
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: var(--radius-lg);
  padding: 10px 18px;
  margin-bottom: 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.35);
  backdrop-filter: blur(12px);
  position: relative;
  z-index: 10;
  flex-wrap: wrap;
}

.dock-badge {
  display: flex;
  align-items: center;
  gap: 8px;
  background: rgba(59, 130, 246, 0.12);
  border: 1px solid rgba(59, 130, 246, 0.3);
  padding: 5px 12px;
  border-radius: var(--radius-full);
  font-size: 0.75rem;
  font-weight: 700;
  color: #60a5fa;
  letter-spacing: 0.04em;
  flex-shrink: 0;
}

.dock-pulse {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #3b82f6;
  box-shadow: 0 0 10px #3b82f6;
  animation: dockPulseAnim 2s infinite;
}

@keyframes dockPulseAnim {
  0% { transform: scale(0.9); opacity: 0.7; }
  50% { transform: scale(1.3); opacity: 1; box-shadow: 0 0 14px #60a5fa; }
  100% { transform: scale(0.9); opacity: 0.7; }
}

.dock-palette {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.palette-chip {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 6px 14px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: var(--radius-md);
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--text-light);
  cursor: grab;
  user-select: none;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2);
}

.palette-chip:hover {
  transform: translateY(-2px);
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.3);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

.palette-chip:active {
  cursor: grabbing;
}

.palette-chip.chip-sector {
  border-color: rgba(16, 185, 129, 0.4);
  background: rgba(16, 185, 129, 0.08);
}
.palette-chip.chip-sector:hover {
  border-color: #10b981;
  box-shadow: 0 0 14px rgba(16, 185, 129, 0.3);
}

.palette-chip.chip-person {
  border-color: rgba(59, 130, 246, 0.4);
  background: rgba(59, 130, 246, 0.08);
}
.palette-chip.chip-person:hover {
  border-color: #3b82f6;
  box-shadow: 0 0 14px rgba(59, 130, 246, 0.3);
}

.palette-chip.chip-unit {
  border-color: rgba(245, 158, 11, 0.4);
  background: rgba(245, 158, 11, 0.08);
}
.palette-chip.chip-unit:hover {
  border-color: #f59e0b;
  box-shadow: 0 0 14px rgba(245, 158, 11, 0.3);
}

.chip-handle {
  color: rgba(255, 255, 255, 0.35);
  font-size: 0.85rem;
  font-weight: bold;
}

.dock-hint {
  font-size: 0.72rem;
  color: var(--text-secondary);
  line-height: 1.3;
  flex: 1;
  min-width: 200px;
}

/* Kanta za smeće / Zona za uklanjanje (Trash Dropzone) */
.org-trash-dropzone {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 6px 14px;
  background: rgba(239, 68, 68, 0.06);
  border: 1.5px dashed rgba(239, 68, 68, 0.3);
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
  flex-shrink: 0;
}

.trash-icon {
  font-size: 1.25rem;
  transition: transform 0.2s ease;
}

.trash-label {
  display: flex;
  flex-direction: column;
}

.trash-title {
  font-size: 0.74rem;
  font-weight: 700;
  color: #fca5a5;
}

.trash-desc {
  font-size: 0.64rem;
  color: rgba(252, 165, 165, 0.7);
}

/* Stanje kada je drag aktivan */
body.org-dragging-active .org-trash-dropzone {
  border-color: #ef4444;
  background: rgba(239, 68, 68, 0.18);
  box-shadow: 0 0 20px rgba(239, 68, 68, 0.35);
  animation: trashPulse 1.5s infinite alternate;
}

@keyframes trashPulse {
  0% { transform: scale(1); box-shadow: 0 0 14px rgba(239, 68, 68, 0.3); }
  100% { transform: scale(1.04); box-shadow: 0 0 24px rgba(239, 68, 68, 0.6); }
}

.org-trash-dropzone.org-drop-hover {
  background: rgba(239, 68, 68, 0.45) !important;
  border-color: #ff4d4d !important;
  transform: scale(1.08) !important;
  box-shadow: 0 0 30px rgba(239, 68, 68, 0.8) !important;
}

.org-trash-dropzone.org-drop-hover .trash-icon {
  transform: rotate(-15deg) scale(1.3);
}

/* Dragging vizualne klase */
.is-dragging {
  opacity: 0.4 !important;
  border: 2px dashed #60a5fa !important;
  transform: scale(0.96) !important;
}

/* Isticanje mogućih drop meta dok korisnik vuče karticu */
body.org-dragging-active .sector-group,
body.org-dragging-active .member-card,
body.org-dragging-active .sub-member-card,
body.org-dragging-active .sector-sub-card,
body.org-dragging-active .sector-leader-card,
body.org-dragging-active #card-director {
  transition: all 0.2s ease;
}

body.org-dragging-active .sector-group {
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.1);
}

/* Hover preko drop mete */
.org-drop-hover {
  outline: 2px dashed #38bdf8 !important;
  background: rgba(56, 189, 248, 0.15) !important;
  transform: scale(1.02) !important;
  box-shadow: 0 0 20px rgba(56, 189, 248, 0.4) !important;
}

#card-director.org-drop-hover {
  outline: 3px dashed #f59e0b !important;
  box-shadow: 0 0 28px rgba(245, 158, 11, 0.6) !important;
}

/* Gumbi za brisanje i ručke */
.card-drag-handle,
.drag-handle {
  display: inline-block;
  color: rgba(255, 255, 255, 0.35);
  font-size: 0.75rem;
  cursor: grab;
  margin-right: 4px;
  user-select: none;
}

.card-drag-handle:active,
.drag-handle:active {
  cursor: grabbing;
}

.member-card-del,
.btn-sector-del {
  width: 22px;
  height: 22px;
  border-radius: var(--radius-sm);
  background: rgba(239, 68, 68, 0.1);
  border: 1px solid rgba(239, 68, 68, 0.25);
  color: #f87171;
  font-size: 0.68rem;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: var(--transition);
}

.member-card-del:hover,
.btn-sector-del:hover {
  background: #ef4444;
  border-color: #ef4444;
  color: #fff;
  transform: scale(1.1);
}

.leader-crown-badge {
  font-size: 0.72rem;
  margin-left: 4px;
}

.member-name-row {
  display: flex;
  align-items: center;
  gap: 4px;
}

/* Modal za novi sektor */
.modal-sector-card {
  max-width: 540px;
}

.sector-icon-picker,
.sector-color-picker {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 6px;
}

.icon-pick-btn {
  width: 36px;
  height: 36px;
  border-radius: var(--radius-md);
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.15);
  font-size: 1.15rem;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.18s ease;
}

.icon-pick-btn:hover {
  background: rgba(255, 255, 255, 0.15);
  transform: scale(1.1);
}

.icon-pick-btn.active {
  border-color: #3b82f6;
  background: rgba(59, 130, 246, 0.25);
  box-shadow: 0 0 10px rgba(59, 130, 246, 0.5);
  transform: scale(1.12);
}

.color-pick-btn {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  border: 2px solid transparent;
  cursor: pointer;
  transition: all 0.18s ease;
}

.color-pick-btn:hover {
  transform: scale(1.2);
}

.color-pick-btn.active {
  border-color: #ffffff;
  transform: scale(1.25);
  box-shadow: 0 0 12px rgba(255, 255, 255, 0.6);
}

/* ==========================================================================
   MODAL ZA UREĐIVANJE DJELATNIKA I VODITELJA
   ========================================================================== */
.person-edit-modal-window {
  max-width: 580px;
}

.member-card-edit,
.sec-btn-edit {
  width: 22px;
  height: 22px;
  border-radius: var(--radius-sm);
  background: rgba(59, 130, 246, 0.12);
  border: 1px solid rgba(59, 130, 246, 0.28);
  color: #93c5fd;
  font-size: 0.68rem;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: var(--transition);
}

.member-card-edit:hover,
.sec-btn-edit:hover {
  background: #3b82f6;
  border-color: #3b82f6;
  color: #fff;
  transform: scale(1.1);
}

/* Prekidač / kartica za status voditelja sektora */
.person-leader-toggle {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 12px 16px;
  background: rgba(245, 158, 11, 0.08);
  border: 1.5px solid rgba(245, 158, 11, 0.3);
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  user-select: none;
}

.person-leader-toggle:hover {
  background: rgba(245, 158, 11, 0.16);
  border-color: #f59e0b;
  transform: translateY(-1px);
}

.person-leader-toggle input[type="checkbox"] {
  width: 20px;
  height: 20px;
  accent-color: #f59e0b;
  cursor: pointer;
}

.leader-toggle-content {
  display: flex;
  align-items: center;
  gap: 10px;
}

.leader-toggle-crown {
  font-size: 1.4rem;
}

.leader-toggle-content strong {
  display: block;
  font-size: 0.86rem;
  color: #fbbf24;
}

.leader-toggle-content small {
  display: block;
  font-size: 0.72rem;
  color: rgba(253, 230, 138, 0.75);
  line-height: 1.3;
}

/* Sektorska vizualna piramida - podrška za više voditelja (Co-leaders apex) */
.sector-pyramid-apex {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}

.sector-leader-card.is-co-leader {
  flex: 0 1 320px;
}

/* ==========================================================================
   NOVA POBOLJŠANJA: STRATEŠKI ZADACI, PODZADACI, AUDIT TRAIL, KAPACITET, BULK
   ========================================================================== */

/* 1. BRZA PRETRAGA U PIRAMIDI */
.pyramid-search-box {
  display: flex;
  align-items: center;
}

#input-pyramid-search {
  background: rgba(15, 23, 42, 0.7);
  border: 1px solid rgba(255, 255, 255, 0.16);
  color: #fff;
  border-radius: var(--radius-full);
  padding: 5px 12px;
  font-size: 0.75rem;
  width: 175px;
  transition: var(--transition);
}

#input-pyramid-search:focus {
  outline: none;
  width: 220px;
  border-color: var(--primary-light);
  background: rgba(15, 23, 42, 0.95);
  box-shadow: 0 0 12px rgba(59, 130, 246, 0.35);
}

.member-card.pyramid-match,
.director-card-hero.pyramid-match {
  outline: 3px solid #38bdf8 !important;
  outline-offset: 3px !important;
  box-shadow: 0 0 24px rgba(56, 189, 248, 0.6) !important;
  transform: translateY(-3px) scale(1.02);
  z-index: 10;
  transition: all 0.25s ease;
}

.member-card.pyramid-dim,
.director-card-hero.pyramid-dim {
  opacity: 0.35;
  filter: grayscale(0.5);
  transition: all 0.25s ease;
}

/* 2. STRATEŠKI PRIORITET (VIP STAR) */
.tag-strategic-pill {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  background: linear-gradient(135deg, rgba(245, 158, 11, 0.25) 0%, rgba(217, 119, 6, 0.15) 100%);
  border: 1px solid rgba(245, 158, 11, 0.5);
  color: #fbbf24;
  font-size: 0.62rem;
  font-weight: 800;
  padding: 2px 7px;
  border-radius: var(--radius-full);
  letter-spacing: 0.04em;
  text-transform: uppercase;
  box-shadow: 0 0 10px rgba(245, 158, 11, 0.25);
  animation: strategicGlow 2.5s infinite alternate;
}

@keyframes strategicGlow {
  0% { box-shadow: 0 0 6px rgba(245, 158, 11, 0.2); }
  100% { box-shadow: 0 0 14px rgba(245, 158, 11, 0.45); }
}

.task-card.is-strategic-task {
  border-left: 3px solid #f59e0b !important;
  background: linear-gradient(145deg, rgba(245, 158, 11, 0.05) 0%, rgba(15, 23, 42, 0.75) 100%);
}

.strategic-checkbox-badge {
  font-size: 0.8rem;
  font-weight: 700;
  color: #fbbf24;
  display: flex;
  align-items: center;
  gap: 4px;
}

/* 3. PONAVLJAJUĆI ZADACI */
.tag-recurring-pill {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  background: rgba(139, 92, 246, 0.18);
  border: 1px solid rgba(139, 92, 246, 0.4);
  color: #c4b5fd;
  font-size: 0.62rem;
  font-weight: 700;
  padding: 2px 7px;
  border-radius: var(--radius-full);
  letter-spacing: 0.03em;
}

.executive-options-row {
  margin-top: 4px;
  margin-bottom: 8px;
  padding: 10px 14px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.07);
  border-radius: var(--radius-md);
  align-items: center;
}

/* 4. KONTROLNI POPIS (CHECKLIST / SUBTASKS) */
.subtasks-progress-badge {
  font-size: 0.68rem;
  font-weight: 800;
  color: #38bdf8;
  background: rgba(56, 189, 248, 0.12);
  border: 1px solid rgba(56, 189, 248, 0.25);
  padding: 2px 8px;
  border-radius: var(--radius-full);
}

.subtasks-container {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 8px;
}

.subtasks-progress-bar-wrap {
  width: 100%;
  height: 5px;
  background: rgba(255, 255, 255, 0.08);
  border-radius: var(--radius-full);
  overflow: hidden;
}

.subtasks-progress-bar {
  height: 100%;
  background: linear-gradient(90deg, #10b981 0%, #38bdf8 100%);
  border-radius: var(--radius-full);
  transition: width 0.3s ease;
}

.subtasks-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
  max-height: 180px;
  overflow-y: auto;
  padding-right: 4px;
}

.subtask-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 6px 10px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: var(--radius-sm);
  transition: var(--transition);
}

.subtask-item:hover {
  background: rgba(255, 255, 255, 0.07);
  border-color: rgba(255, 255, 255, 0.16);
}

.subtask-item-left {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
  flex: 1;
}

.subtask-item-left input[type="checkbox"] {
  width: 16px;
  height: 16px;
  accent-color: #10b981;
  cursor: pointer;
}

.subtask-text {
  font-size: 0.8rem;
  color: var(--text-light);
  line-height: 1.3;
  word-break: break-word;
  transition: color 0.15s ease;
}

.subtask-item.is-completed .subtask-text {
  text-decoration: line-through;
  color: var(--text-muted);
}

.subtask-del-btn {
  background: none;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  padding: 2px 4px;
  font-size: 0.72rem;
  border-radius: var(--radius-sm);
  transition: var(--transition);
}

.subtask-del-btn:hover {
  color: #ef4444;
  background: rgba(239, 68, 68, 0.15);
}

.subtask-add-row {
  display: flex;
  gap: 6px;
  margin-top: 4px;
}

.subtask-add-row input {
  flex: 1;
}

/* Prikaz koraka na kartici zadatka (Kanban) */
.task-card-subtasks {
  margin: 6px 0 8px;
  padding: 6px 9px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: var(--radius-sm);
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.subtasks-label {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.68rem;
  font-weight: 700;
  color: var(--text-secondary);
}

.subtasks-mini-progress {
  width: 100%;
  height: 4px;
  background: rgba(255, 255, 255, 0.08);
  border-radius: var(--radius-full);
  overflow: hidden;
}

.subtasks-mini-bar {
  height: 100%;
  background: linear-gradient(90deg, #10b981 0%, #38bdf8 100%);
  border-radius: var(--radius-full);
  transition: width 0.25s ease;
}

/* 5. DNEVNIK AKTIVNOSTI (AUDIT TRAIL / REVIZIJSKI TRAG) */
.activity-log-section {
  max-height: 160px;
  overflow-y: auto;
  padding: 4px 6px 4px 0;
}

.activity-log-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  position: relative;
  padding-left: 12px;
  border-left: 2px solid rgba(255, 255, 255, 0.1);
}

.activity-log-item {
  position: relative;
  font-size: 0.72rem;
  line-height: 1.35;
  color: var(--text-secondary);
}

.activity-log-item::before {
  content: '';
  position: absolute;
  left: -17px;
  top: 4px;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #38bdf8;
  border: 2px solid #0f172a;
}

.activity-log-meta {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 2px;
}

.activity-log-author {
  font-weight: 700;
  color: #cbd5e1;
}

.activity-log-time {
  font-size: 0.65rem;
  color: var(--text-muted);
}

.activity-log-text {
  color: var(--text-light);
}

/* 6. INDIKATOR OPTEREĆENJA DJELATNIKA (WORKLOAD CAPACITY) */
.member-workload-pill {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 1px 6px;
  border-radius: var(--radius-full);
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  line-height: 1.2;
}

.workload-dot {
  font-size: 0.55rem;
  line-height: 1;
}

.member-workload-pill.workload-low {
  background: rgba(16, 185, 129, 0.14);
  color: #34d399;
  border: 1px solid rgba(16, 185, 129, 0.28);
}

.member-workload-pill.workload-medium {
  background: rgba(245, 158, 11, 0.14);
  color: #fbbf24;
  border: 1px solid rgba(245, 158, 11, 0.28);
}

.member-workload-pill.workload-high {
  background: rgba(239, 68, 68, 0.15);
  color: #f87171;
  border: 1px solid rgba(239, 68, 68, 0.35);
  animation: pulseBadge 2s infinite;
}

.worker-modal-workload {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.72rem;
  font-weight: 700;
  padding: 3px 9px;
  border-radius: var(--radius-full);
  margin-top: 4px;
}

/* 7. MASOVNE RADNJE U TABLICI (BULK ACTIONS) */
.table-bulk-actions-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  background: linear-gradient(135deg, rgba(30, 41, 59, 0.95) 0%, rgba(15, 23, 42, 0.95) 100%);
  border: 1px solid var(--primary);
  box-shadow: 0 4px 18px rgba(0, 0, 0, 0.4), 0 0 14px rgba(59, 130, 246, 0.25);
  border-radius: var(--radius-md);
  padding: 8px 14px;
  margin-bottom: 12px;
  animation: slideDown 0.2s ease-out;
}

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

.bulk-info {
  display: flex;
  align-items: center;
  gap: 8px;
}

.bulk-icon {
  font-size: 1.1rem;
}

.bulk-count {
  font-size: 0.82rem;
  font-weight: 800;
  color: #93c5fd;
}

.bulk-buttons {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}

.task-row-checkbox {
  width: 16px;
  height: 16px;
  accent-color: var(--primary);
  cursor: pointer;
}

#th-check-all-tasks {
  width: 16px;
  height: 16px;
  accent-color: var(--primary);
  cursor: pointer;
}

/* 8. VODIČ KROZ TIPKOVNIČKE PREČACE */
.shortcuts-modal-window {
  max-width: 480px;
}

.shortcuts-intro {
  font-size: 0.82rem;
  color: var(--text-secondary);
  margin-bottom: 16px;
}

.shortcuts-grid {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.shortcut-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 8px 12px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: var(--radius-sm);
  font-size: 0.82rem;
}

.shortcut-item kbd {
  background: rgba(15, 23, 42, 0.9);
  border: 1px solid rgba(255, 255, 255, 0.25);
  box-shadow: 0 2px 0 rgba(255, 255, 255, 0.2);
  color: #38bdf8;
  font-family: inherit;
  font-weight: 800;
  font-size: 0.78rem;
  padding: 3px 8px;
  border-radius: 4px;
  min-width: 28px;
  text-align: center;
}

/* 9. SLUŽBENI ISPIS / PDF IZVJEŠTAJ ZA UPRAVU (@media print) */
@media print {
  body {
    background: #fff !important;
    color: #000 !important;
    font-size: 11pt !important;
  }

  header.app-header,
  .pyramid-section,
  .task-toolbar,
  .table-bulk-actions-bar,
  .app-footer,
  .toast-container,
  .modal-overlay,
  .lightbox-overlay,
  .btn,
  .btn-icon-task {
    display: none !important;
  }

  .main-content {
    padding: 0 !important;
  }

  .task-manager-section {
    background: transparent !important;
    border: none !important;
    box-shadow: none !important;
    padding: 0 !important;
  }

  .table-view {
    display: block !important;
  }

  .board-view {
    display: none !important;
  }

  .table-responsive {
    overflow: visible !important;
  }

  .tasks-table {
    width: 100% !important;
    border-collapse: collapse !important;
  }

  .tasks-table th,
  .tasks-table td {
    border: 1px solid #cbd5e1 !important;
    color: #0f172a !important;
    padding: 8px 10px !important;
  }

  .tasks-table th {
    background: #f1f5f9 !important;
    font-weight: bold !important;
  }

  .tasks-table th:first-child,
  .tasks-table td:first-child,
  .tasks-table th:last-child,
  .tasks-table td:last-child {
    display: none !important; /* Sakrij checkbox i gumbe akcija pri printu */
  }

  /* Zaglavlje ispisa za direktora */
  .task-manager-section::before {
    content: 'DIREKTOR TO-DO LISTA — OPERATIVNI IZVJEŠTAJ PODUZEĆA';
    display: block;
    font-size: 16pt;
    font-weight: bold;
    text-align: center;
    margin-bottom: 6px;
    border-bottom: 2px solid #0f172a;
    padding-bottom: 8px;
  }
}

/* ==========================================================================
   NOVA POBOLJŠANJA: 12 DIREKTORSKIH ZNAČAJKI I STILOVI
   ========================================================================== */

/* 1. Header Badges & Alerts */
.badge-pill-alert {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  background: linear-gradient(135deg, #ef4444, #dc2626);
  color: #ffffff;
  border-radius: var(--radius-full);
  font-size: 0.68rem;
  font-weight: 800;
  margin-left: 5px;
  box-shadow: 0 0 8px rgba(239, 68, 68, 0.6);
  animation: pulseBadge 1.8s infinite;
}

@keyframes pulseBadge {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.12); }
}

/* 2. 3D Tour Overlay HUD & Heatmap */
.pyramid-3d-tour-overlay {
  position: absolute;
  bottom: 26px;
  left: 50%;
  transform: translateX(-50%);
  min-width: 440px;
  max-width: 92%;
  background: rgba(15, 23, 42, 0.90);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid rgba(56, 189, 248, 0.4);
  border-radius: var(--radius-lg);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.6), 0 0 24px rgba(56, 189, 248, 0.2);
  padding: 16px 22px;
  z-index: 35;
  display: flex;
  flex-direction: column;
  gap: 10px;
  animation: fadeInTour 0.3s ease;
}

@keyframes fadeInTour {
  from { opacity: 0; transform: translate(-50%, 10px); }
  to { opacity: 1; transform: translate(-50%, 0); }
}

.tour-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.tour-badge {
  font-size: 0.72rem;
  font-weight: 800;
  color: #38bdf8;
  letter-spacing: 0.06em;
}

.tour-step {
  font-size: 0.75rem;
  color: var(--text-secondary);
  font-weight: 600;
}

.tour-title {
  font-size: 1.15rem;
  font-weight: 800;
  color: #f8fafc;
}

.tour-desc {
  font-size: 0.82rem;
  color: var(--text-secondary);
  margin-top: 2px;
}

.tour-stats {
  display: flex;
  gap: 8px;
  margin-top: 6px;
  flex-wrap: wrap;
}

.tour-stat-pill {
  font-size: 0.74rem;
  padding: 3px 10px;
  background: rgba(255, 255, 255, 0.08);
  border-radius: 20px;
  color: #cbd5e1;
}

.tour-stat-pill.warning {
  background: rgba(245, 158, 11, 0.16);
  color: #fbbf24;
  border: 1px solid rgba(245, 158, 11, 0.3);
}

.tour-controls {
  display: flex;
  gap: 8px;
  justify-content: flex-end;
  align-items: center;
  margin-top: 6px;
}

/* 3D Heatmap Legend */
.pyramid-3d-heatmap-legend {
  position: absolute;
  top: 16px;
  right: 16px;
  background: rgba(15, 23, 42, 0.88);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border: 1px solid rgba(239, 68, 68, 0.35);
  border-radius: var(--radius-md);
  padding: 8px 14px;
  z-index: 25;
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 0.76rem;
  color: var(--text-primary);
  box-shadow: var(--shadow-md);
}

.legend-title {
  font-weight: 700;
  color: #f87171;
}

.legend-item {
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

.legend-dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  display: inline-block;
}

.dot-low { background: #10b981; box-shadow: 0 0 6px #10b981; }
.dot-med { background: #f59e0b; box-shadow: 0 0 6px #f59e0b; }
.dot-high { background: #ef4444; box-shadow: 0 0 8px #ef4444; }

/* 3. Kompaktni mod Kanban ploče */
.board-view.compact-mode {
  gap: 12px;
}

.board-view.compact-mode .kanban-cards-list {
  gap: 6px;
}

.board-view.compact-mode .task-card {
  padding: 9px 12px;
  min-height: auto;
  border-radius: 8px;
  margin-bottom: 0;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2);
}

.board-view.compact-mode .task-card-header {
  margin-bottom: 4px;
}

.board-view.compact-mode .task-card-title {
  font-size: 0.84rem;
  font-weight: 600;
  line-height: 1.3;
}

.board-view.compact-mode .task-card-desc,
.board-view.compact-mode .task-card-images {
  display: none;
}

.board-view.compact-mode .task-card-meta {
  margin-top: 5px;
  padding-top: 5px;
  font-size: 0.7rem;
}

.board-view.compact-mode .task-card-subtasks {
  padding: 4px 6px;
  margin: 4px 0;
}

/* 4. Jutarnji direktorski brifing modal */
.digest-modal-window {
  max-width: 860px;
  width: 92%;
  max-height: 88vh;
  overflow-y: auto;
}

.digest-kpi-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 12px;
  margin-bottom: 16px;
}

.digest-kpi-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 14px 16px;
  display: flex;
  align-items: center;
  gap: 12px;
  transition: var(--transition);
}

.digest-kpi-card:hover {
  border-color: rgba(255, 255, 255, 0.2);
  transform: translateY(-2px);
}

.kpi-review-highlight {
  border-color: rgba(245, 158, 11, 0.45);
  background: rgba(245, 158, 11, 0.08);
}

.kpi-overdue-highlight {
  border-color: rgba(239, 68, 68, 0.45);
  background: rgba(239, 68, 68, 0.08);
}

.digest-kpi-icon {
  font-size: 1.8rem;
  line-height: 1;
}

.digest-kpi-val {
  display: block;
  font-size: 1.5rem;
  font-weight: 800;
  color: #f8fafc;
  line-height: 1.1;
}

.digest-kpi-lbl {
  font-size: 0.74rem;
  color: var(--text-secondary);
}

.digest-bottleneck-alert {
  background: rgba(239, 68, 68, 0.12);
  border: 1px solid rgba(239, 68, 68, 0.35);
  border-radius: var(--radius-md);
  padding: 12px 16px;
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 16px;
}

.bottleneck-icon {
  font-size: 1.5rem;
}

.bottleneck-text {
  font-size: 0.82rem;
  color: #fecaca;
}

.bottleneck-text strong {
  color: #ef4444;
}

.digest-section {
  margin-bottom: 18px;
}

.digest-section-title {
  font-size: 0.88rem;
  font-weight: 700;
  color: #e2e8f0;
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 8px;
  border-bottom: 1px solid var(--border-subtle);
  padding-bottom: 6px;
}

.digest-section-count {
  font-size: 0.72rem;
  padding: 2px 8px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 12px;
}

.digest-tasks-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.digest-task-item {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  padding: 10px 14px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
}

.digest-task-info {
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.digest-task-title {
  font-size: 0.85rem;
  font-weight: 600;
  color: #f1f5f9;
}

.digest-task-meta {
  font-size: 0.72rem;
  color: var(--text-secondary);
  display: flex;
  gap: 10px;
  align-items: center;
}

.digest-task-actions {
  display: flex;
  gap: 6px;
  align-items: center;
  flex-shrink: 0;
}

.digest-dont-show-label {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.8rem;
  color: var(--text-secondary);
  cursor: pointer;
}

/* 5. OKR Goals Modal */
.okr-modal-window {
  max-width: 860px;
  width: 92%;
  max-height: 85vh;
  overflow-y: auto;
}

.okr-top-actions {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 14px;
  flex-wrap: wrap;
  gap: 10px;
}

.okr-hint {
  font-size: 0.76rem;
  color: var(--text-muted);
}

.okr-form-card {
  background: var(--bg-surface-elevated);
  border: 1px solid var(--primary);
  border-radius: var(--radius-md);
  padding: 16px;
  margin-bottom: 16px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.okr-goals-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.okr-goal-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 16px 18px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  transition: var(--transition);
}

.okr-goal-card:hover {
  border-color: rgba(59, 130, 246, 0.45);
}

.okr-goal-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
}

.okr-goal-title {
  font-size: 1.02rem;
  font-weight: 700;
  color: #f8fafc;
}

.okr-goal-sector-badge {
  font-size: 0.72rem;
  padding: 3px 9px;
  border-radius: 6px;
  font-weight: 600;
  background: rgba(255, 255, 255, 0.08);
  color: #93c5fd;
}

.okr-goal-progress-wrap {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.okr-progress-bar-bg {
  width: 100%;
  height: 8px;
  background: rgba(255, 255, 255, 0.08);
  border-radius: 4px;
  overflow: hidden;
}

.okr-progress-bar-fill {
  height: 100%;
  background: linear-gradient(90deg, #3b82f6, #10b981);
  border-radius: 4px;
  transition: width 0.4s ease;
}

.okr-goal-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.75rem;
  color: var(--text-secondary);
}

/* 6. Predlošci zadataka modal */
.templates-modal-window {
  max-width: 920px;
  width: 92%;
  max-height: 85vh;
  overflow-y: auto;
}

.templates-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(265px, 1fr));
  gap: 14px;
}

.template-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 16px;
  cursor: pointer;
  transition: var(--transition);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 10px;
}

.template-card:hover {
  border-color: var(--primary);
  transform: translateY(-3px);
  box-shadow: 0 8px 24px rgba(59, 130, 246, 0.25);
}

.template-card-title {
  font-size: 0.94rem;
  font-weight: 700;
  color: #f1f5f9;
  display: flex;
  align-items: center;
  gap: 8px;
}

.template-card-desc {
  font-size: 0.78rem;
  color: var(--text-secondary);
  line-height: 1.4;
}

.template-card-subtasks-preview {
  font-size: 0.73rem;
  color: #94a3b8;
  background: rgba(0, 0, 0, 0.3);
  padding: 6px 10px;
  border-radius: 6px;
}

/* 7. Vraćanje na doradu modal */
.revision-modal-window {
  max-width: 580px;
  width: 90%;
}

.revision-task-summary {
  background: rgba(255, 255, 255, 0.04);
  border-radius: var(--radius-sm);
  padding: 10px 14px;
  margin-bottom: 14px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.revision-assignee-badge {
  font-size: 0.74rem;
  padding: 3px 8px;
  background: rgba(59, 130, 246, 0.15);
  color: #60a5fa;
  border-radius: 4px;
}

.quick-reasons-label {
  font-size: 0.76rem;
  font-weight: 600;
  color: var(--text-secondary);
  margin-top: 10px;
}

.quick-reasons-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 6px;
}

.reason-chip {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--border-subtle);
  border-radius: 14px;
  padding: 4px 10px;
  font-size: 0.73rem;
  color: #cbd5e1;
  cursor: pointer;
  transition: var(--transition);
}

.reason-chip:hover {
  background: rgba(245, 158, 11, 0.16);
  border-color: rgba(245, 158, 11, 0.45);
  color: #fbbf24;
}

.revision-badge-on-card {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 0.7rem;
  font-weight: 600;
  color: #fbbf24;
  background: rgba(245, 158, 11, 0.12);
  border: 1px solid rgba(245, 158, 11, 0.35);
  padding: 2px 7px;
  border-radius: 6px;
  margin-top: 4px;
}

/* 8. Koš za smeće modal */
.trash-modal-window {
  max-width: 760px;
  width: 92%;
  max-height: 80vh;
  overflow-y: auto;
}

.trash-top-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.8rem;
  color: var(--text-secondary);
  margin-bottom: 12px;
}

.trash-tasks-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.trash-task-row {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  padding: 10px 14px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
}

/* 9. Glasovne bilješke direktora */
.voice-memo-section {
  background: rgba(255, 255, 255, 0.025);
  border: 1px dashed rgba(255, 255, 255, 0.12);
  border-radius: var(--radius-sm);
  padding: 12px;
}

.voice-memo-controls {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.voice-record-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #ef4444;
  display: inline-block;
  margin-right: 4px;
}

.voice-record-dot.recording {
  animation: pulseBadge 1s infinite;
}

.voice-timer {
  font-family: monospace;
  font-size: 0.85rem;
  color: #ef4444;
  font-weight: 700;
}

.task-card-voice-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 0.72rem;
  color: #38bdf8;
  background: rgba(56, 189, 248, 0.12);
  padding: 2px 7px;
  border-radius: 6px;
  cursor: pointer;
  transition: var(--transition);
}

.task-card-voice-badge:hover {
  background: rgba(56, 189, 248, 0.22);
}

.task-card-goal-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 0.7rem;
  color: #a78bfa;
  background: rgba(167, 139, 250, 0.12);
  padding: 2px 7px;
  border-radius: 6px;
}

/* 10. Undo Toast Button */
.toast-undo-btn {
  margin-left: 10px;
  background: rgba(255, 255, 255, 0.18);
  border: 1px solid rgba(255, 255, 255, 0.35);
  color: #ffffff;
  border-radius: 4px;
  padding: 2px 9px;
  font-size: 0.74rem;
  font-weight: 700;
  cursor: pointer;
  transition: var(--transition);
}

.toast-undo-btn:hover {
  background: rgba(255, 255, 255, 0.35);
}

/* 11. Slojeviti Zoom HUD i Kontrola */
.pyramid-3d-level-hud {
  position: absolute;
  top: 20px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 35;
  display: flex;
  align-items: center;
  gap: 10px;
  background: rgba(15, 23, 42, 0.94);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border: 1.5px solid rgba(56, 189, 248, 0.55);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.55), 0 0 20px rgba(56, 189, 248, 0.25);
  border-radius: var(--radius-full);
  padding: 8px 22px;
  color: #f8fafc;
  font-size: 0.86rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  pointer-events: none;
  animation: slideDownLevelHud 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  transition: opacity 0.3s ease, transform 0.3s ease;
}

@keyframes slideDownLevelHud {
  from {
    opacity: 0;
    transform: translate(-50%, -15px) scale(0.96);
  }
  to {
    opacity: 1;
    transform: translate(-50%, 0) scale(1);
  }
}

.btn-3d-tool#btn-3d-level-zoom.active {
  background: rgba(56, 189, 248, 0.22);
  border-color: #38bdf8;
  color: #ffffff;
  box-shadow: 0 0 14px rgba(56, 189, 248, 0.35);
}

/* 12. Financijski bedževi & KPI zaglavlja */
.header-financial-pill {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  background: rgba(16, 185, 129, 0.12);
  border: 1px solid rgba(16, 185, 129, 0.35);
  padding: 5px 12px;
  border-radius: var(--radius-full);
  font-size: 0.8rem;
  font-weight: 700;
  color: #34d399;
  letter-spacing: 0.02em;
  box-shadow: 0 0 12px rgba(16, 185, 129, 0.14);
}

.header-financial-pill .financial-icon {
  font-size: 0.95rem;
}

/* 12.1. Plesk Cloud Sinkronizacija Status Pill */
.sync-status-pill {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  background: rgba(30, 41, 59, 0.7);
  border: 1px solid rgba(255, 255, 255, 0.12);
  padding: 5px 12px;
  border-radius: var(--radius-full);
  font-size: 0.78rem;
  font-weight: 600;
  color: #94a3b8;
  cursor: pointer;
  transition: all 0.25s ease;
  user-select: none;
}

.sync-status-pill:hover {
  background: rgba(30, 41, 59, 0.95);
  border-color: rgba(255, 255, 255, 0.25);
  transform: translateY(-1px);
}

.sync-status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #94a3b8;
  display: inline-block;
  transition: all 0.3s ease;
}

/* Stanje: Povezano i sinkronizirano */
.sync-status-pill.status-synced {
  background: rgba(16, 185, 129, 0.1);
  border-color: rgba(16, 185, 129, 0.35);
  color: #34d399;
}
.sync-status-pill.status-synced .sync-status-dot {
  background: #10b981;
  box-shadow: 0 0 8px rgba(16, 185, 129, 0.6);
}

/* Stanje: Spremanje u tijeku... */
.sync-status-pill.status-saving {
  background: rgba(245, 158, 11, 0.12);
  border-color: rgba(245, 158, 11, 0.4);
  color: #fbbf24;
}
.sync-status-pill.status-saving .sync-status-dot {
  background: #f59e0b;
  box-shadow: 0 0 8px rgba(245, 158, 11, 0.6);
  animation: pulse-sync-dot 0.8s infinite alternate;
}

/* Stanje: Lokalno / Nema poslužitelja */
.sync-status-pill.status-offline {
  background: rgba(100, 116, 139, 0.15);
  border-color: rgba(148, 163, 184, 0.25);
  color: #94a3b8;
}
.sync-status-pill.status-offline .sync-status-dot {
  background: #64748b;
}

/* Stanje: Greška pri spremanju */
.sync-status-pill.status-error {
  background: rgba(239, 68, 68, 0.12);
  border-color: rgba(239, 68, 68, 0.4);
  color: #f87171;
}
.sync-status-pill.status-error .sync-status-dot {
  background: #ef4444;
  box-shadow: 0 0 8px rgba(239, 68, 68, 0.6);
}

@keyframes pulse-sync-dot {
  0% { transform: scale(0.8); opacity: 0.5; }
  100% { transform: scale(1.25); opacity: 1; }
}

.task-financial-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 0.72rem;
  font-weight: 700;
  padding: 2px 7px;
  border-radius: 5px;
  letter-spacing: 0.01em;
}

.task-financial-badge.finance-revenue {
  background: rgba(16, 185, 129, 0.14);
  color: #34d399;
  border: 1px solid rgba(16, 185, 129, 0.32);
}

.task-financial-badge.finance-saving {
  background: rgba(56, 189, 248, 0.14);
  color: #38bdf8;
  border: 1px solid rgba(56, 189, 248, 0.32);
}

.task-financial-badge.finance-expense {
  background: rgba(245, 158, 11, 0.14);
  color: #fbbf24;
  border: 1px solid rgba(245, 158, 11, 0.32);
}

/* 13. Međusektorske ovisnosti (Dependencies) */
.task-dependency-pill {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 0.71rem;
  padding: 2px 8px;
  border-radius: 5px;
  font-weight: 600;
  margin-top: 3px;
}

.task-dependency-pill.is-waiting {
  background: rgba(245, 158, 11, 0.12);
  color: #f59e0b;
  border: 1px dashed rgba(245, 158, 11, 0.45);
}

.task-dependency-pill.is-cleared {
  background: rgba(16, 185, 129, 0.1);
  color: #10b981;
  border: 1px solid rgba(16, 185, 129, 0.3);
}

/* 14. Vremenska crta / Gantt Timeline View */
.timeline-view {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 18px;
  margin-top: 14px;
}

.timeline-toolbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 16px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--border-subtle);
}

.timeline-scale-selector {
  display: flex;
  align-items: center;
  gap: 8px;
}

.timeline-scale-label {
  font-size: 0.78rem;
  color: var(--text-secondary);
  font-weight: 600;
}

.timeline-legend {
  display: flex;
  align-items: center;
  gap: 14px;
  font-size: 0.75rem;
  color: var(--text-secondary);
  flex-wrap: wrap;
}

.t-legend-item {
  display: flex;
  align-items: center;
  gap: 5px;
}

.t-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  display: inline-block;
}

.t-dot.dot-urgent { background: #ef4444; }
.t-dot.dot-strategic { background: #f59e0b; }
.t-dot.dot-in-progress { background: #3b82f6; }
.t-dot.dot-review { background: #eab308; }
.t-dot.dot-done { background: #10b981; }

.timeline-scroll-container {
  overflow-x: auto;
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  background: rgba(15, 23, 42, 0.4);
}

.timeline-grid {
  min-width: 950px;
  position: relative;
}

.timeline-header-row {
  display: grid;
  background: rgba(15, 23, 42, 0.85);
  border-bottom: 1px solid var(--border-subtle);
  position: sticky;
  top: 0;
  z-index: 5;
}

.timeline-col-header-sector {
  padding: 10px 14px;
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  border-right: 1px solid var(--border-subtle);
  display: flex;
  align-items: center;
}

.timeline-date-cell {
  padding: 8px 4px;
  text-align: center;
  font-size: 0.72rem;
  color: var(--text-secondary);
  border-right: 1px solid rgba(255, 255, 255, 0.04);
}

.timeline-date-cell.is-today {
  background: rgba(56, 189, 248, 0.12);
  color: #38bdf8;
  font-weight: 700;
}

.timeline-date-cell.is-weekend {
  background: rgba(0, 0, 0, 0.2);
  color: var(--text-muted);
}

.timeline-sector-row {
  display: grid;
  border-bottom: 1px solid rgba(255, 255, 255, 0.04);
  min-height: 58px;
}

.timeline-sector-row:hover {
  background: rgba(255, 255, 255, 0.015);
}

.timeline-sector-label-cell {
  padding: 12px 14px;
  border-right: 1px solid var(--border-subtle);
  display: flex;
  flex-direction: column;
  justify-content: center;
  background: rgba(15, 23, 42, 0.5);
}

.timeline-sector-label-title {
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--text-light);
  display: flex;
  align-items: center;
  gap: 6px;
}

.timeline-sector-label-sub {
  font-size: 0.7rem;
  color: var(--text-secondary);
}

.timeline-track-area {
  position: relative;
  display: flex;
  align-items: center;
  padding: 6px 0;
}

.timeline-bar {
  position: absolute;
  height: 34px;
  border-radius: 6px;
  display: flex;
  align-items: center;
  padding: 0 10px;
  font-size: 0.74rem;
  font-weight: 600;
  color: #fff;
  cursor: pointer;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.35);
  transition: transform 0.15s ease, box-shadow 0.15s ease;
  z-index: 2;
  border: 1px solid rgba(255, 255, 255, 0.18);
}

.timeline-bar:hover {
  transform: translateY(-2px);
  box-shadow: 0 5px 14px rgba(0, 0, 0, 0.5);
  z-index: 4;
}

.timeline-bar.status-new { background: linear-gradient(90deg, #3b82f6, #2563eb); }
.timeline-bar.status-in-progress { background: linear-gradient(90deg, #0ea5e9, #0284c7); }
.timeline-bar.status-review { background: linear-gradient(90deg, #f59e0b, #d97706); }
.timeline-bar.status-done { background: linear-gradient(90deg, #10b981, #059669); opacity: 0.78; }
.timeline-bar.is-urgent { border: 1.5px solid #ef4444; }
.timeline-bar.is-strategic { border: 1.5px solid #fde047; box-shadow: 0 0 10px rgba(250, 204, 21, 0.3); }

.timeline-today-line {
  position: absolute;
  top: 0;
  bottom: 0;
  width: 2px;
  background: #ef4444;
  box-shadow: 0 0 8px rgba(239, 68, 68, 0.6);
  z-index: 3;
  pointer-events: none;
}

/* 15. Direktorski radar zdravlja sektora (Executive Health Radar) */
.radar-modal-window {
  max-width: 1040px;
  width: 95%;
  max-height: 90vh;
  overflow-y: auto;
}

.radar-layout {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 20px;
}

@media (max-width: 900px) {
  .radar-layout { grid-template-columns: 1fr; }
}

.radar-chart-card, .radar-insights-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 18px;
}

.radar-chart-header, .radar-insights-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px;
}

.radar-chart-title {
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--text-light);
}

.radar-svg-container {
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 10px 0;
}

.radar-svg-container svg {
  max-width: 100%;
  height: auto;
  filter: drop-shadow(0 4px 12px rgba(0, 0, 0, 0.4));
}

.radar-sector-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 12px;
  justify-content: center;
}

.radar-chip {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 0.72rem;
  font-weight: 600;
  padding: 3px 9px;
  border-radius: var(--radius-full);
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-subtle);
  cursor: pointer;
  transition: var(--transition);
  color: var(--text-secondary);
}

.radar-chip.active {
  background: rgba(56, 189, 248, 0.15);
  border-color: #38bdf8;
  color: #fff;
}

.radar-ranking-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 14px;
}

.radar-rank-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 12px;
  background: rgba(255, 255, 255, 0.025);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  font-size: 0.78rem;
}

.radar-rank-score {
  font-weight: 800;
  font-size: 0.85rem;
}

.radar-executive-note {
  background: rgba(56, 189, 248, 0.06);
  border: 1px solid rgba(56, 189, 248, 0.22);
  border-radius: var(--radius-sm);
  padding: 12px;
  font-size: 0.78rem;
  line-height: 1.5;
  color: #e2e8f0;
}

.radar-benchmark-badge {
  font-size: 0.7rem;
  font-weight: 700;
  color: #34d399;
  background: rgba(16, 185, 129, 0.12);
  padding: 2px 7px;
  border-radius: 4px;
}

/* ==========================================================================
   13. ROLE-BASED ACCESS CONTROL (RBAC) & KORISNIČKI PROFIL
   ========================================================================== */

/* Profilna traka u zaglavlju */
.user-profile-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(30, 41, 59, 0.7);
  border: 1px solid rgba(255, 255, 255, 0.14);
  padding: 4px 10px 4px 6px;
  border-radius: var(--radius-full);
  cursor: pointer;
  transition: all 0.25s ease;
  user-select: none;
}

.user-profile-pill:hover {
  background: rgba(30, 41, 59, 0.95);
  border-color: rgba(255, 255, 255, 0.28);
  transform: translateY(-1px);
}

.user-profile-avatar {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.82rem;
  font-weight: 800;
  color: #fff;
  background: #f59e0b;
  box-shadow: 0 0 10px rgba(0, 0, 0, 0.3);
}

.user-profile-info {
  display: flex;
  flex-direction: column;
  line-height: 1.15;
}

.user-profile-name {
  font-size: 0.8rem;
  font-weight: 700;
  color: #f8fafc;
  white-space: nowrap;
}

.user-profile-role-badge {
  font-size: 0.65rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  padding: 1px 5px;
  border-radius: 4px;
  display: inline-block;
  margin-top: 1px;
}

/* Boje uloga za bedževe */
.badge-role-admin {
  background: rgba(99, 102, 241, 0.2);
  color: #a5b4fc;
  border: 1px solid rgba(99, 102, 241, 0.4);
}

.badge-role-director {
  background: rgba(245, 158, 11, 0.2);
  color: #fcd34d;
  border: 1px solid rgba(245, 158, 11, 0.4);
}

.badge-role-sector_leader {
  background: rgba(16, 185, 129, 0.2);
  color: #6ee7b7;
  border: 1px solid rgba(16, 185, 129, 0.4);
}

.badge-role-member {
  background: rgba(59, 130, 246, 0.2);
  color: #93c5fd;
  border: 1px solid rgba(59, 130, 246, 0.4);
}

.btn-user-action {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: #cbd5e1;
  padding: 4px 7px;
  border-radius: 6px;
  font-size: 0.72rem;
  font-weight: 600;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  transition: all 0.2s ease;
}

.btn-user-action:hover {
  background: rgba(255, 255, 255, 0.18);
  color: #fff;
}

.btn-user-action.btn-logout:hover {
  background: rgba(239, 68, 68, 0.25);
  border-color: rgba(239, 68, 68, 0.5);
  color: #fca5a5;
}

@media (max-width: 900px) {
  .btn-switch-label {
    display: none;
  }
}

/* ==========================================================================
   LOGIN MODAL SUČELJE
   ========================================================================== */
.login-modal-window {
  max-width: 680px;
  width: 95%;
  background: #0f172a;
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: var(--radius-lg);
  box-shadow: 0 25px 60px -15px rgba(0, 0, 0, 0.8), 0 0 35px rgba(56, 189, 248, 0.15);
  overflow: hidden;
}

.login-modal-header {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 22px 24px 18px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  position: relative;
}

.login-brand-icon {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  background: linear-gradient(135deg, rgba(245, 158, 11, 0.25), rgba(99, 102, 241, 0.35));
  border: 1px solid rgba(245, 158, 11, 0.4);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fbbf24;
  box-shadow: 0 0 16px rgba(245, 158, 11, 0.2);
}

.login-modal-title {
  font-size: 1.25rem;
  font-weight: 800;
  color: #f8fafc;
  margin: 0;
}

.login-modal-subtitle {
  font-size: 0.82rem;
  color: #94a3b8;
  margin: 3px 0 0;
}

.login-tabs {
  display: flex;
  gap: 8px;
  padding: 14px 24px;
  background: rgba(15, 23, 42, 0.6);
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.login-tab-btn {
  flex: 1;
  padding: 9px 14px;
  border-radius: var(--radius-md);
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.03);
  color: #94a3b8;
  font-size: 0.82rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s ease;
}

.login-tab-btn:hover {
  background: rgba(255, 255, 255, 0.07);
  color: #fff;
}

.login-tab-btn.active {
  background: rgba(56, 189, 248, 0.16);
  border-color: #38bdf8;
  color: #38bdf8;
  box-shadow: 0 0 14px rgba(56, 189, 248, 0.2);
}

.login-tab-content {
  padding: 20px 24px 24px;
  max-height: 520px;
  overflow-y: auto;
}

/* Vodič kroz ovlasti */
.login-roles-guide {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
  margin-bottom: 18px;
}

@media (max-width: 600px) {
  .login-roles-guide {
    grid-template-columns: 1fr;
  }
}

.role-guide-item {
  padding: 8px 11px;
  border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.025);
  border: 1px solid rgba(255, 255, 255, 0.07);
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.role-guide-tag {
  font-size: 0.74rem;
  font-weight: 700;
  color: #f1f5f9;
}

.role-guide-text {
  font-size: 0.68rem;
  color: #94a3b8;
  line-height: 1.35;
}

.role-guide-admin { border-left: 3px solid #6366f1; }
.role-guide-director { border-left: 3px solid #f59e0b; }
.role-guide-leader { border-left: 3px solid #10b981; }
.role-guide-member { border-left: 3px solid #3b82f6; }

/* Grid profila */
.login-group-heading {
  font-size: 0.72rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #64748b;
  margin: 14px 0 8px;
  padding-bottom: 4px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.login-group-heading:first-child {
  margin-top: 0;
}

.login-profiles-grid {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.login-profile-card {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 14px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: all 0.2s ease;
}

.login-profile-card:hover {
  background: rgba(255, 255, 255, 0.07);
  border-color: rgba(255, 255, 255, 0.2);
  transform: translateX(3px);
}

.login-profile-card.active-profile {
  background: rgba(16, 185, 129, 0.12);
  border-color: rgba(16, 185, 129, 0.4);
}

.login-card-avatar {
  width: 38px;
  height: 38px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 1.05rem;
  color: #fff;
  flex-shrink: 0;
}

.login-card-content {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.login-card-name-row {
  display: flex;
  align-items: center;
  gap: 8px;
}

.login-card-name {
  font-size: 0.88rem;
  font-weight: 700;
  color: #f8fafc;
}

.login-card-badge {
  font-size: 0.65rem;
  font-weight: 700;
  padding: 1px 6px;
  border-radius: 4px;
}

.login-card-role {
  font-size: 0.74rem;
  color: #94a3b8;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.login-card-desc {
  font-size: 0.68rem;
  color: #64748b;
  line-height: 1.3;
}

.btn-login-quick {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.14);
  color: #e2e8f0;
  font-size: 0.76rem;
  font-weight: 700;
  padding: 6px 12px;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: all 0.2s ease;
  white-space: nowrap;
}

.login-profile-card:hover .btn-login-quick {
  background: #38bdf8;
  border-color: #38bdf8;
  color: #0f172a;
}

/* Lozinka & Forma */
.login-password-wrap {
  position: relative;
  display: flex;
  align-items: center;
}

.login-password-wrap .form-input {
  padding-right: 42px;
}

.btn-toggle-password {
  position: absolute;
  right: 10px;
  background: transparent;
  border: none;
  cursor: pointer;
  font-size: 1rem;
  opacity: 0.7;
  transition: opacity 0.2s;
}

.btn-toggle-password:hover {
  opacity: 1;
}

.login-pin-hint {
  display: block;
  font-size: 0.74rem;
  color: #94a3b8;
  margin-top: 6px;
}

.login-pin-hint code {
  background: rgba(255, 255, 255, 0.1);
  padding: 1px 5px;
  border-radius: 3px;
  color: #38bdf8;
}

.login-error-alert {
  background: rgba(239, 68, 68, 0.15);
  border: 1px solid rgba(239, 68, 68, 0.4);
  color: #fca5a5;
  padding: 10px 14px;
  border-radius: var(--radius-sm);
  font-size: 0.78rem;
  font-weight: 600;
  margin-top: 12px;
  animation: shakeAlert 0.35s ease;
}

@keyframes shakeAlert {
  0%, 100% { transform: translateX(0); }
  20%, 60% { transform: translateX(-6px); }
  40%, 80% { transform: translateX(6px); }
}

.login-modal-overlay.mandatory-lock {
  background: rgba(6, 11, 24, 0.94) !important;
  backdrop-filter: blur(16px) !important;
  z-index: 99999 !important;
}

.login-modal-overlay.mandatory-lock .login-modal-window {
  box-shadow: 0 30px 80px -15px rgba(0, 0, 0, 0.95), 0 0 50px rgba(217, 119, 6, 0.2), 0 0 30px rgba(56, 189, 248, 0.15);
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.login-selected-user-card {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 14px;
  background: rgba(56, 189, 248, 0.08);
  border: 1px solid rgba(56, 189, 248, 0.25);
  border-radius: var(--radius-md);
  margin-bottom: 14px;
}

.login-selected-avatar {
  width: 36px;
  height: 36px;
  border-radius: 9px;
  background: #3b82f6;
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 1.1rem;
}

.login-selected-details {
  flex: 1;
  min-width: 0;
}

.login-selected-name {
  font-size: 0.88rem;
  font-weight: 700;
  color: #f8fafc;
}

.login-selected-role {
  font-size: 0.75rem;
  color: #94a3b8;
}

/* ==========================================================================
   14. API POSTAVKE & VANJSKE INTEGRACIJE (ADMIN ONLY)
   ========================================================================== */

.btn-api-header-pill {
  border-color: rgba(56, 189, 248, 0.45) !important;
  color: #38bdf8 !important;
  background: rgba(56, 189, 248, 0.08) !important;
  transition: all 0.25s ease !important;
}

.btn-api-header-pill:hover {
  background: rgba(56, 189, 248, 0.2) !important;
  border-color: #38bdf8 !important;
  box-shadow: 0 0 15px rgba(56, 189, 248, 0.3) !important;
  transform: translateY(-1px);
}

.api-modal-window {
  max-width: 960px;
  width: 95%;
  max-height: 88vh;
  display: flex;
  flex-direction: column;
  background: #0f172a;
  border: 1px solid rgba(56, 189, 248, 0.3);
  box-shadow: 0 25px 70px rgba(0, 0, 0, 0.8), 0 0 30px rgba(56, 189, 248, 0.15);
  border-radius: 14px;
  overflow: hidden;
}

.api-badge-icon {
  background: linear-gradient(135deg, #0284c7, #38bdf8);
  color: #ffffff;
  box-shadow: 0 0 15px rgba(56, 189, 248, 0.4);
}

.api-modal-tabs {
  display: flex;
  gap: 6px;
  padding: 10px 24px;
  background: rgba(15, 23, 42, 0.6);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  overflow-x: auto;
}

.api-tab-btn {
  background: transparent;
  border: 1px solid transparent;
  color: var(--text-secondary);
  padding: 8px 14px;
  border-radius: 8px;
  font-size: 0.82rem;
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: all 0.2s ease;
}

.api-tab-btn:hover {
  color: var(--text-primary);
  background: rgba(255, 255, 255, 0.05);
}

.api-tab-btn.active {
  background: rgba(56, 189, 248, 0.15);
  border-color: rgba(56, 189, 248, 0.4);
  color: #38bdf8;
  box-shadow: 0 2px 10px rgba(56, 189, 248, 0.1);
}

.api-modal-body {
  padding: 20px 24px;
  overflow-y: auto;
  flex: 1;
}

.api-pane-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 16px;
  margin-bottom: 18px;
  padding-bottom: 14px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.api-inline-box {
  background: rgba(30, 41, 59, 0.7);
  border: 1px solid rgba(56, 189, 248, 0.3);
  border-radius: 10px;
  padding: 16px;
  margin-bottom: 20px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.3);
  animation: fadeInDown 0.25s ease-out;
}

.api-inline-box-title {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.88rem;
  font-weight: 700;
  color: #38bdf8;
  margin-bottom: 14px;
}

.api-form-row {
  display: flex;
  gap: 14px;
  margin-bottom: 12px;
}

.api-form-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 14px;
}

.api-success-banner {
  display: flex;
  gap: 12px;
  background: rgba(14, 165, 233, 0.12);
  border: 1px solid rgba(56, 189, 248, 0.5);
  border-radius: 10px;
  padding: 14px;
  margin-bottom: 20px;
  align-items: flex-start;
}

.api-token-clipboard-row {
  display: flex;
  gap: 8px;
  max-width: 600px;
}

.api-token-input {
  flex: 1;
  background: #090d16;
  border: 1px solid #38bdf8;
  color: #38bdf8;
  font-family: 'Consolas', 'Courier New', monospace;
  font-size: 0.88rem;
  font-weight: bold;
  padding: 7px 12px;
  border-radius: 6px;
  user-select: all;
}

.api-items-grid {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.api-key-card, .api-webhook-card {
  background: rgba(30, 41, 59, 0.5);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 10px;
  padding: 16px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  transition: all 0.2s ease;
}

.api-key-card:hover, .api-webhook-card:hover {
  background: rgba(30, 41, 59, 0.75);
  border-color: rgba(56, 189, 248, 0.3);
  transform: translateY(-1px);
}

.api-card-main {
  flex: 1;
  min-width: 0;
}

.api-card-header-row {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 6px;
}

.api-card-title {
  font-weight: 700;
  font-size: 0.92rem;
  color: var(--text-primary);
}

.api-role-badge {
  font-size: 0.7rem;
  font-weight: 600;
  padding: 2px 7px;
  border-radius: 12px;
  text-transform: uppercase;
}

.api-role-badge.role-full {
  background: rgba(16, 185, 129, 0.15);
  border: 1px solid rgba(16, 185, 129, 0.4);
  color: #34d399;
}

.api-role-badge.role-read {
  background: rgba(148, 163, 184, 0.15);
  border: 1px solid rgba(148, 163, 184, 0.3);
  color: #cbd5e1;
}

.api-key-string-preview {
  font-family: 'Consolas', 'Courier New', monospace;
  font-size: 0.78rem;
  background: rgba(0, 0, 0, 0.4);
  padding: 3px 8px;
  border-radius: 4px;
  color: #94a3b8;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 6px;
}

.api-meta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  font-size: 0.74rem;
  color: var(--text-muted);
}

.api-card-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

/* Webhook Checkboxes */
.api-events-checklist {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 8px;
  margin-top: 6px;
  background: rgba(0, 0, 0, 0.25);
  padding: 10px;
  border-radius: 6px;
}

.api-checkbox-label {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.78rem;
  color: var(--text-secondary);
  cursor: pointer;
}

.api-checkbox-label input {
  cursor: pointer;
  accent-color: #38bdf8;
}

.api-event-pill {
  display: inline-block;
  background: rgba(56, 189, 248, 0.12);
  color: #38bdf8;
  border: 1px solid rgba(56, 189, 248, 0.25);
  padding: 1px 6px;
  border-radius: 4px;
  font-size: 0.7rem;
  font-family: monospace;
  margin-right: 4px;
}

/* Webhook Toggle Switch */
.api-switch {
  position: relative;
  display: inline-block;
  width: 36px;
  height: 20px;
}

.api-switch input {
  opacity: 0;
  width: 0;
  height: 0;
}

.api-slider {
  position: absolute;
  cursor: pointer;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: #334155;
  transition: .3s;
  border-radius: 20px;
}

.api-slider:before {
  position: absolute;
  content: "";
  height: 14px;
  width: 14px;
  left: 3px;
  bottom: 3px;
  background-color: white;
  transition: .3s;
  border-radius: 50%;
}

input:checked + .api-slider {
  background-color: #10b981;
}

input:checked + .api-slider:before {
  transform: translateX(16px);
}

/* Documentation Cards */
.api-docs-container {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.api-doc-card {
  background: rgba(30, 41, 59, 0.6);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 10px;
  padding: 18px;
}

.api-doc-badge-row {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 8px;
}

.api-method-badge {
  font-size: 0.72rem;
  font-weight: 800;
  padding: 2px 8px;
  border-radius: 4px;
  letter-spacing: 0.5px;
}

.method-get {
  background: rgba(16, 185, 129, 0.2);
  color: #10b981;
  border: 1px solid rgba(16, 185, 129, 0.4);
}

.method-post {
  background: rgba(59, 130, 246, 0.2);
  color: #3b82f6;
  border: 1px solid rgba(59, 130, 246, 0.4);
}

.method-webhook {
  background: rgba(168, 85, 247, 0.2);
  color: #c084fc;
  border: 1px solid rgba(168, 85, 247, 0.4);
}

.api-endpoint-url {
  font-family: 'Consolas', monospace;
  font-size: 0.86rem;
  color: var(--text-primary);
  font-weight: 600;
}

.api-doc-desc {
  font-size: 0.82rem;
  color: var(--text-secondary);
  margin-bottom: 12px;
}

.api-code-block-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.75rem;
  color: var(--text-muted);
  margin-bottom: 4px;
}

.btn-copy-code {
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.15);
  color: #94a3b8;
  padding: 2px 8px;
  border-radius: 4px;
  font-size: 0.72rem;
  cursor: pointer;
  transition: all 0.2s;
}

.btn-copy-code:hover {
  background: rgba(255, 255, 255, 0.1);
  color: #f1f5f9;
}

.api-code-block {
  background: #090d16;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 6px;
  padding: 12px 14px;
  font-family: 'Consolas', 'Courier New', monospace;
  font-size: 0.8rem;
  color: #38bdf8;
  overflow-x: auto;
  line-height: 1.5;
  margin: 0;
}

/* Logs Table */
.api-logs-table-wrap {
  background: rgba(15, 23, 42, 0.6);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 8px;
  overflow-x: auto;
  max-height: 400px;
}

.api-logs-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.78rem;
  text-align: left;
}

.api-logs-table th {
  background: rgba(30, 41, 59, 0.8);
  color: var(--text-secondary);
  padding: 9px 12px;
  font-weight: 600;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  white-space: nowrap;
}

.api-logs-table td {
  padding: 9px 12px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  color: var(--text-primary);
}

.api-status-pill {
  display: inline-block;
  padding: 2px 6px;
  border-radius: 4px;
  font-weight: 700;
  font-size: 0.7rem;
}

.api-status-pill.status-2xx {
  background: rgba(16, 185, 129, 0.15);
  color: #10b981;
  border: 1px solid rgba(16, 185, 129, 0.3);
}

.api-status-pill.status-4xx {
  background: rgba(245, 158, 11, 0.15);
  color: #f59e0b;
  border: 1px solid rgba(245, 158, 11, 0.3);
}

.api-status-pill.status-5xx {
  background: rgba(239, 68, 68, 0.15);
  color: #ef4444;
  border: 1px solid rgba(239, 68, 68, 0.3);
}

.btn-xs-close {
  background: transparent;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  font-size: 0.88rem;
  padding: 2px 6px;
  border-radius: 4px;
}

.btn-xs-close:hover {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.1);
}

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




