/* =============================================
    Art-Community: Стили приложения
    SaaS система управления театрами
    Премиум тёмная тема с glassmorphism
    ============================================= */

/* CSS Variables - Premium Dark Theme */
:root {
  --bg-deep: #08080c;
  --bg-primary: #0f0f14;
  --bg-card: #1a1a22;
  --bg-card-hover: #22222c;
  --bg-elevated: #2a2a36;
  --bg-glass: rgba(20, 20, 28, 0.85);
  
  --accent: #e50914;
  --accent-hover: #ff1a25;
  --accent-glow: rgba(229, 9, 20, 0.35);
  --accent-soft: rgba(229, 9, 20, 0.12);
  
  --text-primary: #f0f0f5;
  --text-secondary: #a0a0b0;
  --text-muted: #606070;
  --text-light: #ffffff;
  
  --border: rgba(255, 255, 255, 0.08);
  --border-light: rgba(255, 255, 255, 0.04);
  --border-accent: rgba(229, 9, 20, 0.3);
  
  --badge-spectacle: #e50914;
  --badge-rehearsal: #3b82f6;
  --badge-vocal: #a855f7;
  --badge-fitting: #f97316;
  --badge-meeting: #6b7280;
  --badge-tour: #22c55e;
  
  --priority-critical: #e50914;
  --priority-high: #f97316;
  --priority-medium: #eab308;
  --priority-low: #22c55e;
  
  --success: #22c55e;
  --warning: #eab308;
  --danger: #e50914;
  --info: #3b82f6;
  
  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.4);
  --shadow-md: 0 8px 32px rgba(0, 0, 0, 0.5);
  --shadow-lg: 0 20px 60px rgba(0, 0, 0, 0.6);
  --shadow-glow: 0 0 40px rgba(229, 9, 20, 0.15);
  
  --radius-sm: 10px;
  --radius-md: 14px;
  --radius-lg: 20px;
  --radius-full: 50%;
  
  --header-height: 60px;
  --sidebar-width: 260px;
  --bottom-nav-height: 60px;
  
  --transition: 0.25s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-fast: 0.15s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-slow: 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Reset & Base */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-size: 16px;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  background: var(--bg-deep);
  color: var(--text-primary);
  line-height: 1.5;
  overflow: hidden;
  height: 100vh;
}

a {
  text-decoration: none;
  color: inherit;
}

button {
  border: none;
  background: none;
  cursor: pointer;
  font-family: inherit;
}

input, select, textarea {
  font-family: inherit;
  font-size: inherit;
}

.hidden {
  display: none !important;
}

/* Custom Scrollbar */
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: #444; border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: #555; }

/* =============================================
   Background Animation
   ============================================= */
.bg-pulse {
  position: fixed;
  top: 0;
  left: var(--sidebar-width);
  right: 0;
  bottom: 0;
  pointer-events: none;
  z-index: 0;
  opacity: 0.03;
  background: radial-gradient(ellipse at 70% 20%, var(--accent), transparent 60%),
              radial-gradient(ellipse at 30% 80%, rgba(139,0,0,0.5), transparent 50%);
  animation: bgShift 20s ease-in-out infinite alternate;
}

@keyframes bgShift {
  0% { opacity: 0.03; transform: scale(1); }
  50% { opacity: 0.05; transform: scale(1.1); }
  100% { opacity: 0.03; transform: scale(1); }
}

/* =============================================
   Splash Screen
   ============================================= */
.splash {
  position: fixed;
  inset: 0;
  background: linear-gradient(135deg, var(--bg-deep), var(--bg-primary));
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  transition: opacity 0.5s ease;
}

.splash.fade-out {
  opacity: 0;
  pointer-events: none;
}

.splash-content {
  text-align: center;
  color: var(--text-light);
}

.splash-logo {
  font-size: 5rem;
  margin-bottom: 1rem;
  animation: pulse 2s infinite;
  color: var(--accent);
}

.splash-title {
  font-size: 2rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
  letter-spacing: 2px;
}

.splash-subtitle {
  font-size: 1rem;
  opacity: 0.6;
  margin-bottom: 2rem;
  color: var(--text-secondary);
}

.splash-loader {
  display: flex;
  justify-content: center;
}

.loader-spinner {
  width: 40px;
  height: 40px;
  border: 3px solid rgba(255, 255, 255, 0.1);
  border-top-color: var(--accent);
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

@keyframes pulse {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.1); }
}

/* =============================================
   Login Screen — Premium Glassmorphism
   ============================================= */
.login-screen {
  position: fixed;
  inset: 0;
  background: 
    radial-gradient(ellipse at 20% 50%, rgba(229, 9, 20, 0.08) 0%, transparent 50%),
    radial-gradient(ellipse at 80% 20%, rgba(139, 0, 0, 0.06) 0%, transparent 40%),
    linear-gradient(135deg, var(--bg-deep), var(--bg-primary));
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 8000;
  padding: 1rem;
}

.login-container {
  background: var(--bg-glass);
  backdrop-filter: blur(40px) saturate(150%);
  -webkit-backdrop-filter: blur(40px) saturate(150%);
  border-radius: var(--radius-lg);
  padding: 3rem 2.5rem;
  width: 100%;
  max-width: 420px;
  box-shadow: 
    0 24px 80px rgba(0, 0, 0, 0.6),
    0 0 0 1px rgba(255, 255, 255, 0.05),
    inset 0 1px 0 rgba(255, 255, 255, 0.05);
  text-align: center;
  border: 1px solid rgba(255, 255, 255, 0.08);
  animation: loginAppear 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes loginAppear {
  from { 
    opacity: 0; 
    transform: translateY(20px) scale(0.96);
  }
  to { 
    opacity: 1; 
    transform: translateY(0) scale(1);
  }
}

.login-logo {
  font-size: 4.5rem;
  margin-bottom: 0.75rem;
  color: var(--accent);
  filter: drop-shadow(0 0 30px var(--accent-glow));
  animation: logoFloat 3s ease-in-out infinite;
}

@keyframes logoFloat {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-6px); }
}

.login-title {
  font-size: 2rem;
  font-weight: 800;
  color: var(--text-light);
  margin-bottom: 0.5rem;
  letter-spacing: 3px;
  text-transform: uppercase;
  background: linear-gradient(135deg, var(--text-light), var(--text-secondary));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.login-subtitle {
  color: var(--text-secondary);
  margin-bottom: 2.5rem;
  font-size: 0.95rem;
}

.login-form {
  text-align: left;
}

.form-group {
  margin-bottom: 1.5rem;
  position: relative;
}

.form-group label {
  display: block;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-secondary);
  margin-bottom: 0.6rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.form-group input,
.form-group select,
.form-group textarea {
  width: 100%;
  padding: 1rem 1.25rem;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: var(--radius-sm);
  font-size: 1rem;
  color: var(--text-primary);
  transition: all var(--transition);
}

.form-group input::placeholder,
.form-group textarea::placeholder {
  color: var(--text-muted);
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--accent);
  background: rgba(229, 9, 20, 0.04);
  box-shadow: 0 0 0 3px rgba(229, 9, 20, 0.1), 0 4px 20px rgba(0, 0, 0, 0.2);
}

.form-error {
  background: rgba(229, 9, 14, 0.1);
  color: var(--danger);
  padding: 0.875rem 1rem;
  border-radius: var(--radius-sm);
  font-size: 0.875rem;
  margin-bottom: 1rem;
  border: 1px solid rgba(229, 9, 14, 0.2);
  backdrop-filter: blur(10px);
}

.btn-login {
  width: 100%;
  padding: 1rem;
  background: linear-gradient(135deg, var(--accent), #c20812);
  color: var(--text-light);
  border-radius: var(--radius-sm);
  font-size: 1rem;
  font-weight: 700;
  transition: all var(--transition);
  box-shadow: 0 4px 24px var(--accent-glow);
  text-transform: uppercase;
  letter-spacing: 1px;
  position: relative;
  overflow: hidden;
}

.btn-login::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.15), transparent);
  transition: left 0.5s;
}

.btn-login:hover::before {
  left: 100%;
}

.btn-login:hover {
  background: linear-gradient(135deg, var(--accent-hover), var(--accent));
  transform: translateY(-2px);
  box-shadow: 0 8px 32px var(--accent-glow);
}

.btn-login:active {
  transform: translateY(0);
}

/* =============================================
   App Layout
   ============================================= */
.app-wrapper {
  display: flex;
  min-height: 100vh;
  position: relative;
  z-index: 1;
}

/* Sidebar — Glassmorphism */
.sidebar {
  position: fixed;
  top: 0;
  left: 0;
  bottom: 0;
  width: var(--sidebar-width);
  background: var(--bg-glass);
  backdrop-filter: blur(30px) saturate(150%);
  -webkit-backdrop-filter: blur(30px) saturate(150%);
  border-right: 1px solid rgba(255, 255, 255, 0.06);
  display: flex;
  flex-direction: column;
  z-index: 900;
  transform: translateX(-100%);
  transition: transform var(--transition);
  box-shadow: 4px 0 24px rgba(0, 0, 0, 0.3);
}

.sidebar.open {
  transform: translateX(0);
}

.sidebar-top {
  flex: 1;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.sidebar-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  padding: 16px;
  position: relative;
}

/* Logo */
.logo {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 24px 20px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.logo-icon {
  width: 44px;
  height: 44px;
  background: linear-gradient(135deg, var(--accent), #c20812);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 20px;
  font-weight: 800;
  box-shadow: 0 4px 20px var(--accent-glow), inset 0 1px 0 rgba(255, 255, 255, 0.2);
  transition: transform var(--transition);
}

.logo:hover .logo-icon {
  transform: rotate(-5deg) scale(1.05);
}

.logo-text {
  font-size: 22px;
  font-weight: 800;
  color: var(--text-light);
  letter-spacing: 3px;
  text-transform: uppercase;
}

.logo-sub {
  font-size: 10px;
  color: var(--text-muted);
  margin-top: 2px;
  letter-spacing: 1px;
  text-transform: uppercase;
}

/* Navigation */
.nav-list {
  flex: 1;
  padding: 16px 12px;
  overflow-y: auto;
}

.nav-item {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 12px 16px;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: all var(--transition);
  color: var(--text-secondary);
  font-size: 14px;
  font-weight: 500;
  margin-bottom: 4px;
  position: relative;
}

.nav-item i {
  width: 22px;
  text-align: center;
  font-size: 17px;
  transition: all var(--transition);
}

.nav-item:hover {
  background: rgba(255, 255, 255, 0.06);
  color: var(--text-primary);
  transform: translateX(4px);
}

.nav-item.active {
  background: linear-gradient(135deg, rgba(229, 9, 20, 0.15), rgba(229, 9, 20, 0.05));
  color: var(--text-light);
  font-weight: 600;
  box-shadow: inset 0 0 0 1px rgba(229, 9, 20, 0.2);
}

.nav-item.active i {
  color: var(--accent);
  filter: drop-shadow(0 0 6px var(--accent-glow));
}

.nav-item.active::before {
  content: '';
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 3px;
  height: 24px;
  background: linear-gradient(to bottom, var(--accent), var(--accent-hover));
  border-radius: 0 4px 4px 0;
  box-shadow: 0 0 10px var(--accent-glow);
}

.nav-item.hidden-nav {
  display: none;
}

/* Theater Switcher */
.theater-switcher {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: var(--radius-sm);
  padding: 12px 14px;
  cursor: pointer;
  transition: all var(--transition);
  display: flex;
  align-items: center;
  justify-content: space-between;
  color: var(--text-primary);
  font-size: 13px;
  font-weight: 500;
}

.theater-switcher:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: var(--accent);
  box-shadow: 0 0 16px var(--accent-glow);
}

.theater-switcher i:last-child {
  color: var(--text-muted);
  font-size: 12px;
  transition: transform var(--transition);
}

.theater-switcher:hover i:last-child {
  transform: rotate(180deg);
}

.theater-dropdown {
  position: absolute;
  bottom: 70px;
  left: 16px;
  width: calc(100% - 32px);
  background: var(--bg-card);
  border-radius: 12px;
  border: 1px solid var(--border);
  padding: 8px;
  box-shadow: 0 12px 40px rgba(0,0,0,0.5);
  display: none;
  z-index: 110;
}

.theater-dropdown.show {
  display: block;
}

.theater-option {
  padding: 10px 12px;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.2s;
  font-size: 13px;
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.theater-option:hover {
  background: rgba(255,255,255,0.05);
  color: var(--text-primary);
}

.theater-option.active-theater,
.theater-option.active {
  color: var(--accent);
  font-weight: 500;
}

.theater-option .theater-actions {
  display: flex;
  gap: 0.5rem;
}

.theater-option .theater-actions button {
  padding: 0.25rem 0.5rem;
  font-size: 0.75rem;
  border-radius: 4px;
  transition: background var(--transition);
  color: var(--text-secondary);
}

.theater-option .theater-actions button:hover {
  background: rgba(255,255,255,0.1);
}

/* =============================================
   Main Area
   ============================================= */
.main-area {
  flex: 1;
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  height: 100vh;
  overflow: hidden;
}

/* Topbar — Glassmorphism */
.topbar {
  height: var(--header-height);
  background: var(--bg-glass);
  backdrop-filter: blur(30px) saturate(150%);
  -webkit-backdrop-filter: blur(30px) saturate(150%);
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 28px;
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
}

.topbar-left {
  display: flex;
  align-items: center;
  gap: 16px;
}

.topbar-right {
  display: flex;
  align-items: center;
  gap: 16px;
}

.mobile-menu-btn {
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  font-size: 18px;
  color: var(--text-secondary);
  transition: all var(--transition);
}

.mobile-menu-btn:hover {
  background: rgba(255,255,255,0.05);
  color: var(--text-primary);
}

/* Search Box — Premium */
.search-box {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: var(--radius-sm);
  padding: 10px 16px 10px 42px;
  color: var(--text-primary);
  font-size: 14px;
  width: 300px;
  position: relative;
  transition: all var(--transition);
}

.search-box i {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-muted);
  font-size: 14px;
  transition: color var(--transition);
}

.search-box input {
  background: transparent;
  border: none;
  outline: none;
  color: var(--text-primary);
  font-size: 14px;
  width: 100%;
}

.search-box input::placeholder {
  color: var(--text-muted);
}

.search-box:focus-within {
  border-color: var(--accent);
  background: rgba(229, 9, 20, 0.04);
  box-shadow: 0 0 0 3px rgba(229, 9, 20, 0.1), 0 4px 20px rgba(0, 0, 0, 0.2);
  width: 360px;
}

.search-box:focus-within i {
  color: var(--accent);
}

/* Role Switcher — Premium */
.role-switcher {
  display: flex;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: var(--radius-sm);
  padding: 4px;
  gap: 4px;
}

.role-btn {
  padding: 8px 16px;
  border-radius: 8px;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  transition: all var(--transition);
  background: transparent;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.role-btn:hover {
  background: rgba(255, 255, 255, 0.08);
  color: var(--text-primary);
}

.role-btn.active,
.role-btn.active-role {
  background: linear-gradient(135deg, var(--accent), #c20812);
  color: #fff;
  box-shadow: 0 2px 12px var(--accent-glow);
}

/* Notification Button — Premium */
.notif-btn {
  width: 40px;
  height: 40px;
  border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.06);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all var(--transition);
  color: var(--text-secondary);
  position: relative;
}

.notif-btn:hover {
  background: rgba(255, 255, 255, 0.08);
  color: var(--text-primary);
  border-color: var(--accent);
  box-shadow: 0 0 16px var(--accent-glow);
}

.notif-btn:hover i {
  animation: bellRing 0.5s ease;
}

@keyframes bellRing {
  0%, 100% { transform: rotate(0); }
  25% { transform: rotate(15deg); }
  75% { transform: rotate(-15deg); }
}

.notif-dot {
  position: absolute;
  top: 6px;
  right: 6px;
  width: 8px;
  height: 8px;
  background: var(--accent);
  border-radius: 50%;
  display: none;
  box-shadow: 0 0 8px var(--accent-glow);
}

.notif-dot.show {
  display: block;
}

/* Notification Dropdown */
.notif-dropdown {
  position: absolute;
  top: 56px;
  right: 0;
  width: 320px;
  background: var(--bg-card);
  border-radius: 12px;
  border: 1px solid var(--border);
  box-shadow: 0 12px 40px rgba(0,0,0,0.5);
  display: none;
  z-index: 110;
  overflow: hidden;
}

.notif-dropdown.show {
  display: block;
}

.notif-dropdown-header {
  padding: 14px 16px;
  font-weight: 600;
  font-size: 14px;
  color: var(--text-primary);
  border-bottom: 1px solid var(--border-light);
}

.notif-item {
  padding: 12px 16px;
  display: flex;
  gap: 12px;
  align-items: flex-start;
  cursor: pointer;
  transition: background 0.2s;
  border-bottom: 1px solid rgba(255,255,255,0.03);
}

.notif-item:hover {
  background: rgba(255,255,255,0.04);
}

.notif-item.unread {
  background: rgba(229,9,14,0.05);
}

.notif-icon {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  background: rgba(229,9,14,0.15);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent);
  flex-shrink: 0;
}

.notif-title {
  font-weight: 500;
  font-size: 13px;
  color: var(--text-primary);
  margin-bottom: 0.25rem;
}

.notif-text {
  font-size: 13px;
  color: var(--text-primary);
  line-height: 1.4;
}

.notif-time {
  font-size: 11px;
  color: var(--text-muted);
  margin-top: 4px;
}

.notif-empty {
  padding: 2rem;
  text-align: center;
  color: var(--text-muted);
}

/* User Info — Premium */
.user-info {
  display: flex;
  align-items: center;
  gap: 12px;
  cursor: pointer;
  padding: 6px 10px;
  border-radius: var(--radius-sm);
  transition: all var(--transition);
  border: 1px solid transparent;
}

.user-info:hover {
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(255, 255, 255, 0.08);
}

.user-avatar {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background: linear-gradient(135deg, var(--accent), #c20812);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 14px;
  color: #fff;
  box-shadow: 0 2px 12px var(--accent-glow);
  transition: transform var(--transition);
}

.user-info:hover .user-avatar {
  transform: scale(1.05);
}

.user-name {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-primary);
}

.user-role,
.user-role-label {
  font-size: 11px;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* =============================================
   Content Area
   ============================================= */
.content-area {
  flex: 1;
  overflow-y: auto;
  padding: 24px;
  background: var(--bg-deep);
  position: relative;
  z-index: 1;
}

.content-scroll {
  flex: 1;
  overflow-y: auto;
  padding: 24px;
  background: var(--bg-deep);
  position: relative;
  z-index: 1;
}

.view-container {
  animation: fadeSlideIn 0.3s ease;
}

@keyframes fadeSlideIn {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: translateY(0); }
}

/* Section Headers */
.section-title,
.block-title {
  font-size: 22px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 20px;
  display: flex;
  align-items: center;
  gap: 10px;
}

.section-title .accent-dot {
  width: 8px;
  height: 8px;
  background: var(--accent);
  border-radius: 50%;
  box-shadow: 0 0 8px var(--accent-glow);
}

.section-subtitle {
  font-size: 13px;
  color: var(--text-muted);
  margin-bottom: 16px;
  margin-top: -8px;
}

.block-title .btn-add {
  padding: 8px 16px;
  background: var(--accent);
  color: var(--text-light);
  border-radius: 8px;
  font-size: 13px;
  font-weight: 500;
  transition: all var(--transition);
  box-shadow: 0 2px 12px var(--accent-glow);
}

.block-title .btn-add:hover {
  background: var(--accent-hover);
  transform: translateY(-1px);
}

/* =============================================
   Event Cards (Schedule)
   ============================================= */
.event-grid,
.cards-grid,
.schedule-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 16px;
}

.event-card,
.card {
  background: var(--bg-card);
  border-radius: 12px;
  padding: 16px;
  cursor: pointer;
  transition: all 0.2s ease;
  border: 1px solid rgba(255,255,255,0.04);
  position: relative;
  overflow: hidden;
}

.event-card:hover,
.card:hover {
  transform: scale(1.02);
  border-color: var(--accent);
  box-shadow: 0 8px 30px rgba(0,0,0,0.4), 0 0 20px var(--accent-glow);
}

.event-card.past-event {
  opacity: 0.45;
  filter: grayscale(0.3);
}

.event-card.past-event:hover {
  opacity: 0.7;
  transform: scale(1.01);
}

.event-card.static {
  cursor: default;
}

.event-card.static:hover {
  transform: none;
  border-color: rgba(255,255,255,0.04);
  box-shadow: none;
}

.event-card-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
}

.card-header {
  padding: 16px;
  border-bottom: 1px solid var(--border-light);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.card-title {
  font-size: 16px;
  font-weight: 600;
  color: var(--text-primary);
}

.card-body {
  padding: 16px;
}

.card-footer {
  padding: 12px 16px;
  border-top: 1px solid var(--border-light);
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
}

/* Type Badges */
.type-badge,
.badge {
  padding: 4px 10px;
  border-radius: 6px;
  font-size: 11px;
  font-weight: 600;
  color: #fff;
  letter-spacing: 0.5px;
}

.type-badge.spectacle,
.badge-primary { background: var(--badge-spectacle); }
.type-badge.rehearsal { background: var(--badge-rehearsal); }
.type-badge.vocal { background: var(--badge-vocal); }
.type-badge.fitting { background: var(--badge-fitting); }
.type-badge.meeting,
.badge-secondary { background: var(--badge-meeting); }
.type-badge.tour { background: var(--badge-tour); }

.badge-success {
  background: rgba(34,197,94,0.15);
  color: var(--success);
}

.badge-warning {
  background: rgba(234,179,8,0.15);
  color: var(--warning);
}

.badge-danger {
  background: rgba(229,9,14,0.15);
  color: var(--danger);
}

.badge-info {
  background: rgba(59,130,246,0.15);
  color: var(--info);
}

.event-status {
  font-size: 11px;
  color: var(--text-muted);
}

.event-title,
.schedule-title {
  font-size: 16px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 8px;
}

.event-meta,
.schedule-meta {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.event-meta-row {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  color: var(--text-secondary);
}

.event-meta-row i {
  width: 16px;
  color: var(--text-muted);
  font-size: 12px;
}

.event-card-gradient {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 60px;
  background: linear-gradient(transparent, rgba(229,9,14,0.08));
  pointer-events: none;
}

/* Schedule specific */
.schedule-day {
  background: var(--bg-card);
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid rgba(255,255,255,0.04);
}

.schedule-day-header {
  padding: 12px 16px;
  background: var(--accent);
  color: #fff;
  font-weight: 600;
  font-size: 14px;
}

.schedule-show {
  padding: 12px 16px;
  border-bottom: 1px solid var(--border-light);
  display: flex;
  align-items: center;
  gap: 16px;
}

.schedule-show:last-child {
  border-bottom: none;
}

.schedule-time {
  font-size: 16px;
  font-weight: 600;
  color: var(--accent);
  min-width: 60px;
}

.schedule-info {
  flex: 1;
}

.schedule-title {
  font-weight: 500;
  margin-bottom: 2px;
}

.schedule-meta {
  font-size: 13px;
  color: var(--text-secondary);
}

/* =============================================
   Schedule Table (dates × stages)
   ============================================= */
.schedule-table-wrapper {
  overflow-x: auto;
  border-radius: 12px;
  background: var(--bg-card);
  border: 1px solid rgba(255,255,255,0.04);
}

.schedule-table {
  width: 100%;
  border-collapse: collapse;
  min-width: 600px;
}

.schedule-table thead th {
  padding: 14px 12px;
  font-size: 13px;
  font-weight: 600;
  text-align: center;
  border-bottom: 2px solid rgba(255,255,255,0.08);
  white-space: nowrap;
}

.schedule-table-date-col {
  background: var(--bg-elevated) !important;
  color: var(--text-primary) !important;
  text-align: left !important;
  min-width: 120px;
  border-right: 1px solid rgba(255,255,255,0.06);
}

.schedule-table tbody tr {
  border-bottom: 1px solid rgba(255,255,255,0.04);
  transition: background 0.15s;
}

.schedule-table tbody tr:hover {
  background: rgba(255,255,255,0.02);
}

.schedule-table-date-cell {
  padding: 12px 14px;
  background: var(--bg-elevated);
  border-right: 1px solid rgba(255,255,255,0.06);
  vertical-align: top;
}

.schedule-table-date {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 2px;
}

.schedule-table-time {
  font-size: 12px;
  color: var(--accent);
  font-weight: 500;
}

.schedule-table-cell {
  padding: 8px;
  text-align: center;
  vertical-align: top;
  cursor: pointer;
  min-width: 140px;
  border-right: 1px solid rgba(255,255,255,0.03);
}

.schedule-table-cell:last-child {
  border-right: none;
}

.schedule-table-empty {
  color: var(--text-muted);
  font-size: 14px;
  opacity: 0.4;
  cursor: default;
}

.schedule-table-empty:hover {
  background: transparent;
}

.schedule-event {
  padding: 8px 10px;
  border-radius: 8px;
  text-align: left;
  transition: all 0.15s;
  border: 1px solid transparent;
}

.schedule-event:hover {
  transform: scale(1.02);
  box-shadow: 0 4px 16px rgba(0,0,0,0.3);
}

.schedule-event.event-spectacle {
  background: rgba(139, 0, 0, 0.25);
  border-color: rgba(139, 0, 0, 0.4);
}

.schedule-event.event-rehearsal {
  background: rgba(26, 58, 92, 0.3);
  border-color: rgba(26, 58, 92, 0.5);
}

.schedule-event.event-other {
  background: rgba(45, 80, 22, 0.25);
  border-color: rgba(45, 80, 22, 0.4);
}

.schedule-event-title {
  font-size: 12px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 4px;
  line-height: 1.3;
}

.schedule-event-meta {
  font-size: 10px;
  color: var(--text-secondary);
  margin-bottom: 4px;
}

/* Stages list (manage stages modal) */
.stages-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.stage-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 12px;
  background: var(--bg-elevated);
  border-radius: 8px;
  border: 1px solid rgba(255,255,255,0.04);
}

.stage-color {
  width: 24px;
  height: 24px;
  border-radius: 6px;
  flex-shrink: 0;
}

.stage-name {
  flex: 1;
  font-size: 14px;
  font-weight: 500;
  color: var(--text-primary);
}

.stage-actions {
  display: flex;
  gap: 4px;
}

/* =============================================
   Repertoire - Netflix style
   ============================================= */
.rep-row {
  margin-bottom: 32px;
}

.rep-row-title {
  font-size: 18px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 12px;
  padding-left: 4px;
}

.rep-row-title-wrap {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 12px;
}

.rep-row-edit-btn {
  width: 28px;
  height: 28px;
  background: var(--bg-elevated);
  border-radius: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: var(--text-muted);
  font-size: 11px;
  transition: all 0.2s;
}

.rep-row-edit-btn:hover {
  background: var(--accent);
  color: #fff;
}

.rep-row-title-input {
  background: var(--bg-elevated);
  border: 1px solid var(--accent);
  border-radius: 6px;
  padding: 4px 10px;
  color: var(--text-primary);
  font-size: 16px;
  font-weight: 600;
  outline: none;
}

.rep-row-scroll {
  display: flex;
  gap: 14px;
  overflow-x: auto;
  padding-bottom: 8px;
  scroll-snap-type: x mandatory;
}

.show-card {
  width: 220px;
  height: 300px;
  border-radius: 12px;
  position: relative;
  cursor: pointer;
  transition: all 0.25s ease;
  overflow: hidden;
  flex-shrink: 0;
  scroll-snap-align: start;
  background: var(--bg-card);
}

.show-card:hover {
  transform: scale(1.08);
  z-index: 10;
  box-shadow: 0 12px 40px rgba(0,0,0,0.6), 0 0 30px var(--accent-glow);
}

.show-card-img {
  width: 100%;
  height: 70%;
  object-fit: cover;
  background: linear-gradient(135deg, #1a1a2e, #16213e);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 48px;
  color: rgba(255,255,255,0.1);
}

.show-card-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 16px;
  background: linear-gradient(transparent, rgba(0,0,0,0.9));
}

.show-card-title {
  font-size: 16px;
  font-weight: 700;
  color: #fff;
  margin-bottom: 4px;
}

.show-card-genre {
  font-size: 12px;
  color: var(--text-secondary);
}

.show-card-play {
  position: absolute;
  top: 40%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 48px;
  height: 48px;
  background: var(--accent);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: all 0.2s;
  box-shadow: 0 4px 20px var(--accent-glow);
}

.show-card:hover .show-card-play {
  opacity: 1;
}

/* Repertoire Grid (alternative) */
.repertoire-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1.5rem;
}

.spectacle-card {
  background: var(--bg-card);
  border-radius: 12px;
  overflow: hidden;
  transition: all 0.2s;
  border: 1px solid rgba(255,255,255,0.04);
}

.spectacle-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 40px rgba(0,0,0,0.5), 0 0 20px var(--accent-glow);
  border-color: var(--accent);
}

.spectacle-image {
  width: 100%;
  height: 200px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 4rem;
  color: var(--text-light);
  background: linear-gradient(135deg, #1a1a2e, #16213e);
}

.spectacle-content {
  padding: 1.25rem;
}

.spectacle-title {
  font-size: 1.125rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 0.5rem;
}

.spectacle-description {
  font-size: 0.875rem;
  color: var(--text-secondary);
  margin-bottom: 1rem;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.spectacle-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.meta-tag {
  padding: 0.25rem 0.75rem;
  background: var(--bg-elevated);
  border-radius: 100px;
  font-size: 0.75rem;
  color: var(--text-secondary);
}

/* Cast list & chips */
.cast-list {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-left: 28px;
}

.cast-chip {
  background: var(--bg-elevated);
  border-radius: 6px;
  padding: 4px 10px;
  font-size: 12px;
  color: var(--text-primary);
  border: 1px solid rgba(255,255,255,0.06);
}

.event-cast {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-top: 8px;
  font-size: 12px;
  color: var(--text-muted);
}

.event-cast i {
  font-size: 11px;
}

.event-cast span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* =============================================
   Chat Styles
   ============================================= */
.chat-layout {
  display: flex;
  gap: 0;
  height: calc(100vh - var(--header-height) - 48px);
  border-radius: 12px;
  overflow: hidden;
  background: var(--bg-card);
  border: 1px solid rgba(255,255,255,0.04);
}

.chat-list {
  width: 280px;
  border-right: 1px solid var(--border-light);
  overflow-y: auto;
  background: var(--bg-primary);
}

.chat-list-header {
  padding: 16px;
  font-weight: 600;
  font-size: 15px;
  color: var(--text-primary);
  border-bottom: 1px solid var(--border-light);
}

.chat-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  cursor: pointer;
  transition: all 0.2s;
  border-bottom: 1px solid rgba(255,255,255,0.03);
}

.chat-item:hover {
  background: rgba(255,255,255,0.04);
}

.chat-item.active-chat {
  background: rgba(229,9,14,0.1);
}

.chat-avatar {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  background: var(--bg-elevated);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 600;
  font-size: 16px;
  color: var(--accent);
  flex-shrink: 0;
}

.chat-item-info {
  flex: 1;
  min-width: 0;
}

.chat-item-name {
  font-size: 14px;
  font-weight: 500;
  color: var(--text-primary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.chat-item-preview {
  font-size: 12px;
  color: var(--text-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  margin-top: 2px;
}

.chat-item-time {
  font-size: 11px;
  color: var(--text-muted);
  flex-shrink: 0;
}

.chat-window {
  flex: 1;
  display: flex;
  flex-direction: column;
}

.chat-header {
  padding: 14px 20px;
  border-bottom: 1px solid var(--border-light);
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: rgba(20,20,20,0.5);
}

.chat-header-name {
  font-weight: 600;
  font-size: 15px;
  color: var(--text-primary);
}

.chat-header-status {
  font-size: 12px;
  color: var(--badge-tour);
}

.chat-messages {
  flex: 1;
  overflow-y: auto;
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.message {
  max-width: 70%;
  padding: 10px 14px;
  border-radius: 12px;
  font-size: 14px;
  line-height: 1.5;
}

.message.sent {
  background: rgba(229,9,14,0.2);
  color: var(--text-primary);
  align-self: flex-end;
  border-bottom-right-radius: 4px;
}

.message.received {
  background: var(--bg-elevated);
  color: var(--text-primary);
  align-self: flex-start;
  border-bottom-left-radius: 4px;
}

.message-time {
  font-size: 10px;
  color: var(--text-muted);
  margin-top: 4px;
}

.chat-input-area {
  padding: 14px 20px;
  border-top: 1px solid var(--border-light);
  display: flex;
  gap: 10px;
  background: rgba(20,20,20,0.5);
}

.chat-input {
  flex: 1;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 10px 14px;
  color: var(--text-primary);
  font-size: 14px;
  outline: none;
  transition: border-color 0.2s;
}

.chat-input:focus {
  border-color: var(--accent);
}

.chat-send-btn {
  width: 40px;
  height: 40px;
  background: var(--accent);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s;
  color: #fff;
}

.chat-send-btn:hover {
  background: var(--accent-hover);
  box-shadow: 0 4px 16px var(--accent-glow);
}

/* Chat Search */
.chat-search {
  padding: 12px 16px;
  border-bottom: 1px solid var(--border-light);
}

.chat-search-input {
  width: 100%;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 8px 12px 8px 34px;
  color: var(--text-primary);
  font-size: 13px;
  outline: none;
  transition: border-color 0.2s;
}

.chat-search-input:focus {
  border-color: var(--accent);
}

.chat-search-input::placeholder {
  color: var(--text-muted);
}

.chat-search-icon {
  position: absolute;
  left: 26px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-muted);
  font-size: 13px;
  pointer-events: none;
}

.chat-search {
  position: relative;
}

/* Chat Create Button */
.chat-create-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  background: var(--accent);
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.2s;
  color: #fff;
  font-size: 14px;
}

.chat-create-btn:hover {
  background: var(--accent-hover);
  box-shadow: 0 4px 12px var(--accent-glow);
  transform: scale(1.05);
}

/* Chat List Header with Actions */
.chat-list-header-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px;
  border-bottom: 1px solid var(--border-light);
}

.chat-list-title {
  font-weight: 600;
  font-size: 15px;
  color: var(--text-primary);
}

/* Group Chat Avatar */
.chat-avatar-group {
  position: relative;
  width: 40px;
  height: 40px;
  border-radius: 10px;
  background: var(--bg-elevated);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.chat-avatar-group .group-icon {
  font-size: 18px;
  color: var(--accent);
}

.chat-avatar-group .members-count {
  position: absolute;
  bottom: -2px;
  right: -2px;
  background: var(--accent);
  color: #fff;
  font-size: 9px;
  font-weight: 600;
  min-width: 16px;
  height: 16px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 4px;
  border: 2px solid var(--bg-primary);
}

/* Message Status */
.message-status {
  display: inline-flex;
  align-items: center;
  margin-left: 6px;
  font-size: 11px;
}

.message-status.sending {
  color: var(--text-muted);
}

.message-status.sent {
  color: var(--text-muted);
}

.message-status.delivered {
  color: var(--badge-tour);
}

.message-status.read {
  color: var(--accent);
}

.message-status i {
  font-size: 12px;
}

/* Message with status container */
.message-content {
  display: flex;
  flex-direction: column;
}

.message-text {
  word-break: break-word;
}

.message-footer {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 4px;
  margin-top: 4px;
}

/* Chat Empty State */
.chat-empty {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
  gap: 12px;
}

.chat-empty-icon {
  font-size: 48px;
  opacity: 0.3;
}

.chat-empty-title {
  font-size: 16px;
  font-weight: 500;
  color: var(--text-secondary);
}

.chat-empty-desc {
  font-size: 13px;
  text-align: center;
  max-width: 240px;
}

/* Chat Header Actions */
.chat-header-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.chat-header-action-btn {
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.2s;
  color: var(--text-muted);
}

.chat-header-action-btn:hover {
  background: rgba(255,255,255,0.08);
  color: var(--text-primary);
}

/* Chat Back Button (mobile) */
.chat-back-btn {
  display: none;
  width: 32px;
  height: 32px;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.2s;
  color: var(--text-muted);
  margin-right: 8px;
}

.chat-back-btn:hover {
  background: rgba(255,255,255,0.08);
  color: var(--text-primary);
}

/* Chat Typing Indicator */
.chat-typing {
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 8px 14px;
  background: var(--bg-elevated);
  border-radius: 12px;
  align-self: flex-start;
}

.chat-typing-dot {
  width: 6px;
  height: 6px;
  background: var(--text-muted);
  border-radius: 50%;
  animation: typingBounce 1.4s infinite ease-in-out;
}

.chat-typing-dot:nth-child(1) { animation-delay: 0s; }
.chat-typing-dot:nth-child(2) { animation-delay: 0.2s; }
.chat-typing-dot:nth-child(3) { animation-delay: 0.4s; }

@keyframes typingBounce {
  0%, 60%, 100% { transform: translateY(0); opacity: 0.4; }
  30% { transform: translateY(-4px); opacity: 1; }
}

/* Chat Date Separator */
.chat-date-separator {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 8px 0;
}

.chat-date-separator::before,
.chat-date-separator::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--border-light);
}

.chat-date-separator span {
  font-size: 11px;
  color: var(--text-muted);
  white-space: nowrap;
}

/* Unread badge for chat items */
.chat-unread-badge {
  min-width: 18px;
  height: 18px;
  background: var(--accent);
  color: #fff;
  font-size: 10px;
  font-weight: 600;
  border-radius: 9px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 5px;
  flex-shrink: 0;
}

/* =============================================
   Kanban Board
   ============================================= */
.kanban-board,
.kanban-layout {
  display: flex;
  gap: 16px;
  overflow-x: auto;
  padding-bottom: 16px;
  min-height: calc(100vh - var(--header-height) - 48px - 60px);
}

.kanban-column,
.kanban-col {
  min-width: 260px;
  flex: 1;
  background: var(--bg-primary);
  border-radius: 12px;
  padding: 16px;
  border: 1px solid rgba(255,255,255,0.04);
}

.kanban-column-title,
.kanban-col-title {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.kanban-count,
.kanban-col-count {
  font-size: 12px;
  color: var(--text-muted);
  background: var(--bg-card);
  padding: 2px 8px;
  border-radius: 6px;
}

.kanban-card,
.task-card {
  background: var(--bg-card);
  border-radius: 10px;
  padding: 14px;
  margin-bottom: 10px;
  cursor: pointer;
  transition: all 0.2s;
  border: 1px solid rgba(255,255,255,0.04);
}

.kanban-card:hover,
.task-card:hover {
  transform: translateY(-2px);
  border-color: var(--accent);
  box-shadow: 0 6px 20px rgba(0,0,0,0.3), 0 0 12px var(--accent-glow);
}

.kanban-card-title,
.task-title {
  font-size: 14px;
  font-weight: 500;
  color: var(--text-primary);
  margin-bottom: 8px;
}

.kanban-card-meta,
.task-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 12px;
  color: var(--text-secondary);
}

.priority-dot,
.priority-badge {
  width: 8px;
  height: 8px;
  border-radius: 50%;
}

.priority-badge {
  font-size: 11px;
  font-weight: 600;
  padding: 2px 8px;
  border-radius: 4px;
  color: #fff;
  width: auto;
}

.priority-critical { background: var(--priority-critical); }
.priority-high { background: var(--priority-high); }
.priority-medium { background: var(--priority-medium); color: #000; }
.priority-low { background: var(--priority-low); }

.task-assignee {
  font-size: 12px;
  color: var(--text-muted);
}

.task-due {
  font-size: 11px;
  color: var(--text-muted);
  margin-top: 6px;
}

.task-due i {
  font-size: 10px;
  margin-right: 4px;
}

/* Kanban card extras */
.kanban-card-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 8px;
}

.kanban-card-menu {
  background: none;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  padding: 2px 4px;
  border-radius: 4px;
  font-size: 14px;
  line-height: 1;
  opacity: 0;
  transition: opacity 0.2s, background 0.2s;
}

.kanban-card:hover .kanban-card-menu {
  opacity: 1;
}

.kanban-card-menu:hover {
  background: rgba(255,255,255,0.1);
  color: var(--text-primary);
}

.kanban-card-desc {
  font-size: 12px;
  color: var(--text-secondary);
  margin-bottom: 8px;
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* Drag & Drop */
.kanban-card.dragging {
  opacity: 0.4;
  transform: rotate(2deg);
  box-shadow: 0 8px 30px rgba(0,0,0,0.5);
}

.kanban-column.drag-over {
  background: rgba(99, 102, 241, 0.08);
  border-color: var(--accent);
  box-shadow: inset 0 0 0 1px var(--accent-glow);
}

.kanban-column.drag-over .kanban-column-title {
  color: var(--accent);
}

/* Context Menu */
.kanban-context-menu {
  position: fixed;
  background: var(--bg-card);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 10px;
  padding: 6px 0;
  min-width: 180px;
  box-shadow: 0 12px 40px rgba(0,0,0,0.6);
  z-index: 9999;
  backdrop-filter: blur(20px);
}

.kanban-context-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 16px;
  cursor: pointer;
  font-size: 13px;
  color: var(--text-primary);
  transition: background 0.15s;
  border: none;
  background: none;
  width: 100%;
  text-align: left;
}

.kanban-context-item:hover {
  background: rgba(255,255,255,0.06);
}

.kanban-context-item i {
  width: 16px;
  font-size: 13px;
  color: var(--text-muted);
}

.kanban-context-item.danger {
  color: var(--danger);
}

.kanban-context-item.danger i {
  color: var(--danger);
}

.kanban-context-separator {
  height: 1px;
  background: rgba(255,255,255,0.06);
  margin: 4px 0;
}

/* Submenu */
.kanban-submenu {
  position: fixed;
  background: var(--bg-card);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 10px;
  padding: 6px 0;
  min-width: 160px;
  box-shadow: 0 12px 40px rgba(0,0,0,0.6);
  z-index: 10000;
  backdrop-filter: blur(20px);
}

/* Overdue */
.kanban-card.overdue {
  border-left: 3px solid var(--danger);
}

.kanban-card.overdue .task-due {
  color: var(--danger);
  font-weight: 600;
}

/* =============================================
   Media Gallery
   ============================================= */
.media-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 16px;
}

.media-folder {
  background: var(--bg-card);
  border-radius: 12px;
  padding: 20px;
  cursor: pointer;
  transition: all 0.2s;
  border: 1px solid rgba(255,255,255,0.04);
  text-align: center;
  position: relative;
}

.media-folder:hover {
  transform: scale(1.04);
  border-color: var(--accent);
  box-shadow: 0 8px 30px rgba(0,0,0,0.4), 0 0 20px var(--accent-glow);
}

.media-folder-icon {
  font-size: 36px;
  color: var(--text-muted);
  margin-bottom: 12px;
  transition: color 0.2s;
}

.media-folder:hover .media-folder-icon {
  color: var(--accent);
}

.media-folder-name {
  font-size: 14px;
  font-weight: 500;
  color: var(--text-primary);
  margin-bottom: 4px;
}

.media-folder-count {
  font-size: 12px;
  color: var(--text-muted);
}

.media-folder-delete {
  position: absolute;
  top: 8px;
  right: 8px;
  width: 24px;
  height: 24px;
  background: rgba(0,0,0,0.5);
  border-radius: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: rgba(255,255,255,0.5);
  font-size: 11px;
  transition: all 0.2s;
  opacity: 0;
}

.media-folder:hover .media-folder-delete {
  opacity: 1;
}

.media-folder-delete:hover {
  background: var(--accent);
  color: #fff;
}

.media-video-card,
.media-image-card {
  background: var(--bg-card);
  border-radius: 12px;
  overflow: hidden;
  cursor: pointer;
  transition: all 0.2s;
  border: 1px solid rgba(255,255,255,0.04);
  position: relative;
}

.media-video-card:hover,
.media-image-card:hover {
  transform: scale(1.04);
  box-shadow: 0 8px 30px rgba(0,0,0,0.4), 0 0 20px var(--accent-glow);
}

.media-video-thumb {
  height: 140px;
  background: linear-gradient(135deg, #1a1a2e, #0f3460);
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
}

.media-image-thumb {
  width: 100%;
  height: 120px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.media-video-play-overlay {
  width: 44px;
  height: 44px;
  background: var(--accent);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0.8;
  transition: opacity 0.2s;
  box-shadow: 0 4px 20px var(--accent-glow);
}

.media-video-card:hover .media-video-play-overlay {
  opacity: 1;
}

.media-video-info {
  padding: 12px;
}

.media-video-title {
  font-size: 13px;
  font-weight: 500;
  color: var(--text-primary);
}

.media-video-duration {
  font-size: 11px;
  color: var(--text-muted);
}

.section-label {
  font-size: 16px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 14px;
}

/* Icon picker grid */
.icon-picker-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.icon-pick {
  width: 40px;
  height: 40px;
  background: var(--bg-elevated);
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: var(--text-secondary);
  transition: all 0.2s;
  border: 2px solid transparent;
}

.icon-pick:hover {
  background: rgba(255,255,255,0.1);
  color: var(--text-primary);
}

.icon-pick.picked {
  border-color: var(--accent);
  color: var(--accent);
  background: rgba(229,9,14,0.1);
}

/* =============================================
   Modal
   ============================================= */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.7);
  backdrop-filter: blur(8px);
  z-index: 200;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s;
}

.modal-overlay.show {
  opacity: 1;
  pointer-events: all;
}

.modal-content {
  background: var(--bg-card);
  border-radius: 16px;
  padding: 28px;
  max-width: 480px;
  width: 90%;
  transform: scale(0.9) translateY(20px);
  transition: transform 0.25s;
  border: 1px solid rgba(255,255,255,0.08);
  box-shadow: 0 20px 60px rgba(0,0,0,0.5);
  position: relative;
}

.modal-overlay.show .modal-content {
  transform: scale(1) translateY(0);
}

.modal-close {
  position: absolute;
  top: 16px;
  right: 16px;
  width: 32px;
  height: 32px;
  background: var(--bg-elevated);
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: var(--text-secondary);
  transition: all 0.2s;
}

.modal-close:hover {
  background: var(--accent);
  color: #fff;
}

.modal-title {
  font-size: 20px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 16px;
}

.modal-body {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.6;
}

.modal-body .detail-row {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 10px;
}

.modal-body .detail-row i {
  color: var(--text-muted);
  width: 20px;
}

.modal-actions {
  margin-top: 16px;
  display: flex;
  gap: 10px;
}

.modal-btn-primary {
  padding: 8px 20px;
  background: var(--accent);
  border-radius: 8px;
  color: #fff;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: background 0.2s;
  border: none;
}

.modal-btn-primary:hover {
  background: var(--accent-hover);
}

.modal-btn-secondary {
  padding: 8px 20px;
  background: var(--bg-elevated);
  border-radius: 8px;
  color: var(--text-secondary);
  font-size: 14px;
  cursor: pointer;
  border: none;
}

/* =============================================
   Stats & Reports
   ============================================= */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  margin-bottom: 24px;
}

.stat-card {
  background: var(--bg-card);
  border-radius: 12px;
  padding: 16px;
  border: 1px solid rgba(255,255,255,0.04);
  text-align: center;
  cursor: default;
}

.stat-card:hover {
  transform: none;
  border-color: rgba(255,255,255,0.04);
  box-shadow: none;
}

.stat-card-icon {
  color: var(--accent);
  font-size: 28px;
  margin-bottom: 12px;
}

.stat-card-value {
  font-size: 28px;
  font-weight: 700;
  color: var(--text-primary);
}

.stat-card-label {
  font-size: 13px;
  color: var(--text-secondary);
  margin-top: 6px;
}

/* Chart */
.chart-card {
  background: var(--bg-card);
  border-radius: 12px;
  padding: 24px;
  border: 1px solid rgba(255,255,255,0.04);
  cursor: default;
}

.chart-card:hover {
  transform: none;
  border-color: rgba(255,255,255,0.04);
  box-shadow: none;
}

.chart-title {
  font-size: 16px;
  font-weight: 600;
  margin-bottom: 16px;
  color: var(--text-primary);
}

.chart-bars {
  display: flex;
  gap: 8px;
  align-items: flex-end;
  height: 180px;
}

.chart-bar-col {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
}

.chart-bar-value {
  font-size: 12px;
  color: var(--text-secondary);
}

.chart-bar {
  width: 100%;
  background: linear-gradient(to top, var(--accent), rgba(229,9,14,0.3));
  border-radius: 6px 6px 0 0;
  transition: height 0.5s;
}

.chart-bar-label {
  font-size: 12px;
  color: var(--text-muted);
}

/* =============================================
   Profile
   ============================================= */
.profile-container {
  max-width: 900px;
  margin: 0 auto;
}

.profile-header {
  background: linear-gradient(135deg, var(--bg-card), var(--bg-elevated));
  border-radius: var(--radius-lg);
  padding: 32px;
  display: flex;
  gap: 24px;
  align-items: center;
  border: 1px solid rgba(255,255,255,0.06);
  box-shadow: var(--shadow-md);
  margin-bottom: 24px;
  position: relative;
  overflow: hidden;
}

.profile-header::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, var(--accent), var(--accent-hover), var(--accent));
}

.profile-avatar {
  width: 90px;
  height: 90px;
  border-radius: 20px;
  background: linear-gradient(135deg, var(--accent), #c20812);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 36px;
  color: #fff;
  flex-shrink: 0;
  box-shadow: 0 8px 32px var(--accent-glow);
  transition: transform var(--transition);
}

.profile-avatar:hover {
  transform: scale(1.05) rotate(-3deg);
}

.profile-info {
  flex: 1;
}

.profile-name {
  font-size: 26px;
  font-weight: 800;
  color: var(--text-light);
  margin-bottom: 4px;
  letter-spacing: 0.5px;
}

.profile-email {
  font-size: 14px;
  color: var(--text-secondary);
  margin-bottom: 8px;
  display: flex;
  align-items: center;
  gap: 6px;
}

.profile-email i {
  font-size: 12px;
  color: var(--text-muted);
}

.profile-role-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  background: linear-gradient(135deg, rgba(229,9,20,0.15), rgba(229,9,20,0.05));
  border: 1px solid rgba(229,9,20,0.3);
  border-radius: 100px;
  font-size: 12px;
  font-weight: 600;
  color: var(--accent);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.profile-role-badge i {
  font-size: 10px;
}

/* Profile Sections Grid */
.profile-sections {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 16px;
  margin-bottom: 24px;
}

.profile-section-card {
  background: var(--bg-card);
  border-radius: var(--radius-md);
  padding: 20px;
  border: 1px solid rgba(255,255,255,0.04);
  cursor: pointer;
  transition: all var(--transition);
  display: flex;
  align-items: center;
  gap: 16px;
}

.profile-section-card:hover {
  transform: translateY(-4px);
  border-color: var(--accent);
  box-shadow: 0 12px 40px rgba(0,0,0,0.4), 0 0 20px var(--accent-glow);
}

.profile-section-icon {
  width: 52px;
  height: 52px;
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  flex-shrink: 0;
  transition: all var(--transition);
  position: relative;
  overflow: hidden;
}

.profile-section-icon::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  opacity: 0;
  transition: opacity var(--transition);
}

.profile-section-card:hover .profile-section-icon {
  transform: scale(1.15) rotate(-5deg);
  box-shadow: 0 8px 24px rgba(0,0,0,0.3);
}

.profile-section-card:hover .profile-section-icon::before {
  opacity: 1;
}

/* Icon variants with unique gradients */
.profile-section-icon.icon-user {
  background: linear-gradient(135deg, #667eea, #764ba2);
  color: #fff;
  box-shadow: 0 4px 16px rgba(102, 126, 234, 0.4);
}

.profile-section-icon.icon-bell {
  background: linear-gradient(135deg, #f093fb, #f5576c);
  color: #fff;
  box-shadow: 0 4px 16px rgba(245, 87, 108, 0.4);
}

.profile-section-icon.icon-shield {
  background: linear-gradient(135deg, #4facfe, #00f2fe);
  color: #fff;
  box-shadow: 0 4px 16px rgba(79, 172, 254, 0.4);
}

.profile-section-icon.icon-building {
  background: linear-gradient(135deg, #43e97b, #38f9d7);
  color: #fff;
  box-shadow: 0 4px 16px rgba(67, 233, 123, 0.4);
}

.profile-section-icon.icon-logout {
  background: linear-gradient(135deg, #fa709a, #fee140);
  color: #fff;
  box-shadow: 0 4px 16px rgba(250, 112, 154, 0.4);
}

.profile-section-content {
  flex: 1;
}

.profile-section-title {
  font-size: 15px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 4px;
}

.profile-section-desc {
  font-size: 12px;
  color: var(--text-muted);
}

.profile-section-arrow {
  color: var(--text-muted);
  font-size: 14px;
  transition: all var(--transition);
}

.profile-section-card:hover .profile-section-arrow {
  color: var(--accent);
  transform: translateX(4px);
}

/* Profile Logout Button */
.profile-logout-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  padding: 14px 24px;
  background: rgba(229,9,14,0.08);
  border: 1px solid rgba(229,9,14,0.2);
  border-radius: var(--radius-md);
  color: var(--accent);
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all var(--transition);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.profile-logout-btn:hover {
  background: rgba(229,9,14,0.15);
  border-color: var(--accent);
  box-shadow: 0 4px 20px var(--accent-glow);
  transform: translateY(-2px);
}

.profile-logout-btn i {
  font-size: 16px;
}

/* Theaters Section */
.theaters-section {
  margin-top: 24px;
}

.theaters-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
}

.theaters-title {
  font-size: 20px;
  font-weight: 700;
  color: var(--text-primary);
  display: flex;
  align-items: center;
  gap: 10px;
}

.theaters-title i {
  color: var(--accent);
}

.btn-create-theater {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 20px;
  background: linear-gradient(135deg, var(--accent), #c20812);
  border-radius: var(--radius-sm);
  color: #fff;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: all var(--transition);
  box-shadow: 0 4px 16px var(--accent-glow);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.btn-create-theater:hover {
  background: linear-gradient(135deg, var(--accent-hover), var(--accent));
  transform: translateY(-2px);
  box-shadow: 0 8px 24px var(--accent-glow);
}

.theater-card {
  background: var(--bg-card);
  border-radius: var(--radius-md);
  padding: 20px;
  border: 1px solid rgba(255,255,255,0.04);
  margin-bottom: 12px;
  transition: all var(--transition);
  display: flex;
  align-items: center;
  gap: 16px;
}

.theater-card:hover {
  border-color: rgba(229,9,20,0.3);
  box-shadow: 0 4px 20px rgba(0,0,0,0.3);
  transform: translateX(4px);
}

.theater-icon {
  width: 50px;
  height: 50px;
  border-radius: 12px;
  background: linear-gradient(135deg, var(--bg-elevated), var(--bg-card));
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent);
  font-size: 22px;
  flex-shrink: 0;
  border: 1px solid rgba(229,9,20,0.2);
}

.theater-info {
  flex: 1;
}

.theater-name {
  font-size: 16px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 4px;
}

.theater-address {
  font-size: 13px;
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  gap: 6px;
}

.theater-address i {
  font-size: 11px;
  color: var(--text-muted);
}

.theater-director {
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 4px;
  display: flex;
  align-items: center;
  gap: 6px;
}

.theater-director i {
  font-size: 10px;
  color: var(--accent);
}

.theater-actions {
  display: flex;
  gap: 8px;
}

.theater-action-btn {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background: var(--bg-elevated);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: var(--text-secondary);
  font-size: 14px;
  transition: all var(--transition);
  border: 1px solid rgba(255,255,255,0.04);
}

.theater-action-btn:hover {
  background: var(--accent);
  color: #fff;
  transform: scale(1.1);
  box-shadow: 0 4px 12px var(--accent-glow);
}

.theater-action-btn.danger:hover {
  background: var(--danger);
}

/* Empty State */
.empty-state {
  text-align: center;
  padding: 60px 20px;
  color: var(--text-muted);
}

.empty-state-icon {
  font-size: 48px;
  margin-bottom: 16px;
  opacity: 0.5;
  color: var(--text-muted);
}

.empty-state-title {
  font-size: 18px;
  font-weight: 600;
  color: var(--text-secondary);
  margin-bottom: 8px;
}

.empty-state-desc {
  font-size: 14px;
  color: var(--text-muted);
  max-width: 300px;
  margin: 0 auto;
}

/* Profile edit form */
.profile-edit-form {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.profile-form-group {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.profile-form-group label {
  font-size: 12px;
  color: var(--text-muted);
}

/* Profile notification settings */
.profile-notif-settings {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.notif-toggle-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 0;
  border-bottom: 1px solid rgba(255,255,255,0.04);
  font-size: 14px;
  color: var(--text-secondary);
}

.notif-toggle-row:last-child {
  border-bottom: none;
}

/* Toggle switch */
.toggle-switch {
  position: relative;
  display: inline-block;
  width: 44px;
  height: 24px;
  cursor: pointer;
}

.toggle-switch input {
  opacity: 0;
  width: 0;
  height: 0;
}

.toggle-slider {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: var(--bg-elevated);
  border-radius: 12px;
  transition: 0.3s;
}

.toggle-slider:before {
  content: '';
  position: absolute;
  height: 18px;
  width: 18px;
  left: 3px;
  bottom: 3px;
  background: #fff;
  border-radius: 50%;
  transition: 0.3s;
}

.toggle-switch input:checked + .toggle-slider {
  background: var(--accent);
}

.toggle-switch input:checked + .toggle-slider:before {
  transform: translateX(20px);
}

/* Passport section */
.passport-section {
  margin-top: 16px;
  padding-top: 16px;
  border-top: 1px solid rgba(255,255,255,0.06);
}

.passport-header {
  font-size: 14px;
  font-weight: 600;
  color: var(--accent);
  margin-bottom: 12px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.passport-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.passport-item {
  background: var(--bg-elevated);
  border-radius: 8px;
  padding: 8px 12px;
}

.passport-label {
  font-size: 11px;
  color: var(--text-muted);
  margin-bottom: 2px;
}

.passport-value {
  font-size: 13px;
  color: var(--text-primary);
  font-weight: 500;
}

.passport-desc {
  margin-top: 12px;
  font-size: 13px;
  color: var(--text-secondary);
  line-height: 1.5;
}

/* =============================================
   Settings & Lists
   ============================================= */
.list-card,
.settings-group-card {
  background: var(--bg-card);
  border-radius: 12px;
  padding: 16px;
  border: 1px solid rgba(255,255,255,0.04);
  cursor: default;
  margin-bottom: 16px;
}

.list-card:hover,
.settings-group-card:hover {
  transform: none;
  border-color: rgba(255,255,255,0.04);
  box-shadow: none;
}

.list-card-title {
  font-size: 16px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 12px;
}

.settings-group-header {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 16px;
}

.settings-group-icon {
  width: 36px;
  height: 36px;
  background: rgba(229,9,14,0.12);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent);
  font-size: 16px;
  flex-shrink: 0;
}

.settings-group-title {
  font-size: 16px;
  font-weight: 600;
  color: var(--text-primary);
}

.list-item,
.settings-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 0;
  border-bottom: 1px solid rgba(255,255,255,0.04);
}

.list-item:last-child,
.settings-item:last-child {
  border-bottom: none;
}

.list-item-text {
  font-size: 14px;
  color: var(--text-secondary);
}

.list-item-arrow {
  color: var(--text-muted);
  font-size: 12px;
  cursor: pointer;
}

.list-item-clickable {
  cursor: pointer;
  transition: background 0.2s;
  border-radius: 6px;
  padding: 10px 8px !important;
  margin: 0 -8px;
}

.list-item-clickable:hover {
  background: rgba(255,255,255,0.04);
}

.settings-item-clickable {
  cursor: pointer;
  border-radius: 6px;
  padding: 12px 8px;
  margin: 0 -8px;
  transition: background 0.2s;
}

.settings-item-clickable:hover {
  background: rgba(255,255,255,0.04);
}

.settings-item-left {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}

.settings-item-label {
  font-size: 14px;
  color: var(--text-secondary);
}

.settings-item-value {
  font-size: 13px;
  color: var(--text-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 300px;
}

.settings-item-right {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

.settings-item-arrow {
  color: var(--text-muted);
  font-size: 12px;
}

.settings-item-edit-icon {
  color: var(--accent);
  font-size: 12px;
  opacity: 0;
  transition: opacity 0.2s;
}

.settings-item-clickable:hover .settings-item-edit-icon {
  opacity: 1;
}

/* =============================================
   Buttons
   ============================================= */
.back-btn {
  width: 36px;
  height: 36px;
  background: var(--bg-elevated);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: var(--text-secondary);
  transition: all 0.2s;
  flex-shrink: 0;
}

.back-btn:hover {
  background: var(--accent);
  color: #fff;
}

.logout-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-top: 24px;
  padding: 12px 24px;
  background: rgba(229,9,14,0.1);
  border: 1px solid rgba(229,9,14,0.2);
  border-radius: 10px;
  color: var(--accent);
  font-size: 14px;
  cursor: pointer;
  transition: all 0.2s;
  width: 100%;
}

.logout-btn:hover {
  background: rgba(229,9,14,0.2);
}

.admin-action-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  background: var(--accent);
  border-radius: 8px;
  color: #fff;
  font-size: 12px;
  font-weight: 500;
  cursor: pointer;
  border: none;
  transition: background 0.2s;
}

.admin-action-btn:hover {
  background: var(--accent-hover);
}

.specialty-delete-btn {
  width: 28px;
  height: 28px;
  background: rgba(229,9,14,0.1);
  border-radius: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: var(--accent);
  font-size: 11px;
  transition: all 0.2s;
}

.specialty-delete-btn:hover {
  background: var(--accent);
  color: #fff;
}

/* =============================================
   Roles Access Modal
   ============================================= */
.roles-access-list {
  max-height: 60vh;
  overflow-y: auto;
  padding-right: 4px;
}

.roles-access-section-title {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 10px;
}

.role-access-card {
  background: var(--bg-elevated);
  border-radius: 10px;
  padding: 14px;
  margin-bottom: 8px;
  border: 1px solid rgba(255,255,255,0.04);
}

.role-access-card.custom {
  border-left: 3px solid var(--accent);
}

.role-access-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
}

.role-access-name {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
}

.role-access-badge {
  font-size: 11px;
  padding: 3px 8px;
  border-radius: 4px;
  font-weight: 500;
}

.role-access-badge.director {
  background: rgba(229,9,14,0.15);
  color: var(--accent);
}

.role-access-badge.admin {
  background: rgba(34,197,94,0.15);
  color: #22c55e;
}

.role-access-badge.custom {
  background: rgba(234,179,8,0.15);
  color: #eab308;
}

.role-access-badge:not(.director):not(.admin):not(.custom) {
  background: rgba(255,255,255,0.06);
  color: var(--text-muted);
}

.role-access-sections {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
}

.role-section-chip {
  font-size: 11px;
  padding: 3px 8px;
  border-radius: 4px;
  transition: all 0.2s;
}

.role-section-chip.enabled {
  background: rgba(229,9,14,0.12);
  color: var(--accent);
}

.role-section-chip.disabled {
  background: rgba(255,255,255,0.03);
  color: var(--text-muted);
  opacity: 0.5;
}

/* Specialty access grid */
.spec-access-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.spec-access-item {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  color: var(--text-secondary);
  cursor: pointer;
  padding: 8px 10px;
  background: var(--bg-elevated);
  border-radius: 8px;
  transition: background 0.2s;
}

.spec-access-item:hover {
  background: rgba(255,255,255,0.08);
}

.spec-access-check {
  accent-color: var(--accent);
  width: 16px;
  height: 16px;
  cursor: pointer;
}

/* =============================================
   Toast
   ============================================= */
.toast-container {
  position: fixed;
  top: 20px;
  right: 20px;
  z-index: 300;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.toast {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 12px 20px;
  font-size: 13px;
  color: var(--text-primary);
  box-shadow: 0 8px 30px rgba(0,0,0,0.4);
  animation: toastIn 0.3s ease, toastOut 0.3s ease 2.7s forwards;
  display: flex;
  align-items: center;
  gap: 10px;
}

.toast i {
  color: var(--accent);
}

@keyframes toastIn {
  from { opacity: 0; transform: translateX(40px); }
  to { opacity: 1; transform: translateX(0); }
}

@keyframes toastOut {
  from { opacity: 1; }
  to { opacity: 0; transform: translateY(-10px); }
}

/* =============================================
   Responsive
   ============================================= */
@media (max-width: 1200px) {
  .kanban-col { min-width: 220px; }
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 768px) {
  /* Sidebar скрыт по умолчанию на мобильных */
  .sidebar {
    position: fixed;
    left: -280px;
    top: 0;
    bottom: 0;
    width: 260px;
    z-index: 1000;
    transition: left 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: none;
  }
  
  .sidebar.open {
    left: 0;
    box-shadow: 4px 0 30px rgba(0, 0, 0, 0.5);
  }
  
  .sidebar.open ~ .sidebar-overlay {
    opacity: 1;
    pointer-events: auto;
  }
  
  /* Показываем полный sidebar на мобильных при открытии */
  .sidebar.open .nav-item span,
  .sidebar.open .logo-text,
  .sidebar.open .logo-sub,
  .sidebar.open .sidebar-bottom {
    display: flex;
  }
  
  .sidebar.open .nav-item {
    justify-content: flex-start;
    padding: 12px 16px;
  }
  
  .nav-item span, .logo-text, .logo-sub, .sidebar-bottom { display: none; }
  .nav-item { justify-content: center; padding: 12px; }
  .nav-item i { font-size: 20px; }
  .main-area { margin-left: 0; }
  
  /* Overlay для sidebar на мобильных */
  .sidebar-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(8px);
    z-index: 999;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
  }
  
  .sidebar-overlay.show {
    opacity: 1;
    pointer-events: auto;
  }
  .chat-list { width: 0; display: none; }
  .search-box { width: 160px; }
  .role-btn { padding: 4px 8px; font-size: 10px; }
  .stats-grid { grid-template-columns: 1fr 1fr; }
  .spec-access-grid { grid-template-columns: 1fr; }
  .settings-item-value { max-width: 140px; }
}

/* ============================================
   Passport Tabs (вкладки в карточке спектакля)
   ============================================ */
.passport-tab {
  padding: 10px 16px;
  border: none;
  background: transparent;
  color: var(--text-secondary);
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  border-bottom: 2px solid transparent;
  transition: all 0.2s ease;
  display: flex;
  align-items: center;
  gap: 6px;
}

.passport-tab:hover {
  color: var(--text-primary);
  background: var(--hover-bg);
}

.passport-tab.active {
  color: var(--primary);
  border-bottom-color: var(--primary);
}

/* ============================================
   Cast Table (таблица состава)
   ============================================ */
.cast-table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 8px;
}

.cast-table th,
.cast-table td {
  padding: 10px 12px;
  text-align: left;
  border-bottom: 1px solid var(--border);
}

.cast-table th {
  font-weight: 600;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--text-secondary);
  background: var(--bg-secondary);
}

.cast-table tr:hover {
  background: var(--hover-bg);
}

.cast-table td:first-child {
  font-weight: 500;
  color: var(--text-primary);
}

.cast-table td:last-child {
  color: var(--text-secondary);
}

/* Cast Editor (редактор состава) */
.cast-row {
  animation: fadeIn 0.2s ease;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(-4px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ============================================
   Theater Settings (Настройки театра)
   ============================================ */
.settings-container {
  max-width: 1100px;
  margin: 0 auto;
}

/* Settings Tabs */
.settings-tabs {
  display: flex;
  gap: 4px;
  margin-bottom: 24px;
  background: var(--bg-card);
  border-radius: var(--radius-md);
  padding: 6px;
  border: 1px solid rgba(255,255,255,0.04);
}

.settings-tab {
  flex: 1;
  padding: 12px 20px;
  border-radius: var(--radius-sm);
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: all var(--transition);
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: none;
  background: transparent;
}

.settings-tab:hover {
  background: rgba(255,255,255,0.06);
  color: var(--text-primary);
}

.settings-tab.active {
  background: linear-gradient(135deg, var(--accent), #c20812);
  color: #fff;
  box-shadow: 0 4px 16px var(--accent-glow);
}

.settings-tab i {
  font-size: 15px;
}

/* Settings Panel */
.settings-panel {
  display: none;
  animation: fadeSlideIn 0.3s ease;
}

.settings-panel.active {
  display: block;
}

/* Settings Cards */
.settings-card {
  background: var(--bg-card);
  border-radius: var(--radius-md);
  padding: 24px;
  margin-bottom: 20px;
  border: 1px solid rgba(255,255,255,0.04);
}

.settings-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
  padding-bottom: 16px;
  border-bottom: 1px solid rgba(255,255,255,0.06);
}

.settings-card-title {
  font-size: 18px;
  font-weight: 600;
  color: var(--text-primary);
  display: flex;
  align-items: center;
  gap: 10px;
}

.settings-card-title i {
  color: var(--accent);
  font-size: 20px;
}

/* Settings Info Grid */
.settings-info-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 16px;
}

.settings-info-item {
  background: var(--bg-elevated);
  border-radius: var(--radius-sm);
  padding: 16px 20px;
  border: 1px solid rgba(255,255,255,0.04);
  transition: all var(--transition);
}

.settings-info-item:hover {
  border-color: rgba(229,9,20,0.3);
  transform: translateY(-2px);
  box-shadow: 0 4px 16px rgba(0,0,0,0.2);
}

.settings-info-label {
  font-size: 12px;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 6px;
  display: flex;
  align-items: center;
  gap: 6px;
}

.settings-info-label i {
  font-size: 11px;
  color: var(--accent);
}

.settings-info-value {
  font-size: 15px;
  font-weight: 500;
  color: var(--text-primary);
}

/* Staff Table */
.staff-table-wrapper {
  overflow-x: auto;
  border-radius: var(--radius-sm);
  background: var(--bg-elevated);
  border: 1px solid rgba(255,255,255,0.04);
}

.staff-table {
  width: 100%;
  border-collapse: collapse;
  min-width: 600px;
}

.staff-table thead th {
  padding: 14px 16px;
  font-size: 12px;
  font-weight: 600;
  text-align: left;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--text-muted);
  background: var(--bg-card);
  border-bottom: 2px solid rgba(255,255,255,0.06);
}

.staff-table tbody tr {
  border-bottom: 1px solid rgba(255,255,255,0.04);
  transition: background var(--transition-fast);
}

.staff-table tbody tr:hover {
  background: rgba(255,255,255,0.03);
}

.staff-table tbody tr:last-child {
  border-bottom: none;
}

.staff-table td {
  padding: 14px 16px;
  font-size: 14px;
  color: var(--text-primary);
  vertical-align: middle;
}

.staff-name {
  display: flex;
  align-items: center;
  gap: 10px;
}

.staff-avatar {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  background: linear-gradient(135deg, var(--accent), #c20812);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: 600;
  color: #fff;
  flex-shrink: 0;
}

.staff-info {
  display: flex;
  flex-direction: column;
}

.staff-fio {
  font-weight: 500;
  color: var(--text-primary);
}

.staff-email {
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 2px;
}

.staff-position-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px 10px;
  background: rgba(229,9,20,0.12);
  border-radius: 6px;
  font-size: 12px;
  font-weight: 500;
  color: var(--accent);
}

.staff-status {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px 10px;
  border-radius: 6px;
  font-size: 12px;
  font-weight: 500;
}

.staff-status.active {
  background: rgba(34,197,94,0.12);
  color: var(--success);
}

.staff-status.pending {
  background: rgba(234,179,8,0.12);
  color: var(--warning);
}

.staff-actions {
  display: flex;
  gap: 4px;
}

.staff-action-btn {
  width: 30px;
  height: 30px;
  border-radius: 6px;
  background: rgba(255,255,255,0.04);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: var(--text-muted);
  font-size: 12px;
  transition: all var(--transition-fast);
  border: 1px solid transparent;
}

.staff-action-btn:hover {
  background: rgba(255,255,255,0.1);
  color: var(--text-primary);
  border-color: rgba(255,255,255,0.1);
}

.staff-action-btn.danger:hover {
  background: rgba(229,9,14,0.15);
  color: var(--danger);
  border-color: rgba(229,9,14,0.3);
}

/* Positions List */
.positions-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.position-card {
  background: var(--bg-elevated);
  border-radius: var(--radius-sm);
  padding: 16px 20px;
  border: 1px solid rgba(255,255,255,0.04);
  display: flex;
  align-items: center;
  justify-content: space-between;
  transition: all var(--transition);
}

.position-card:hover {
  border-color: rgba(229,9,20,0.3);
  transform: translateX(4px);
  box-shadow: 0 4px 16px rgba(0,0,0,0.2);
}

.position-info {
  display: flex;
  align-items: center;
  gap: 14px;
}

.position-icon {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  background: linear-gradient(135deg, rgba(229,9,20,0.15), rgba(229,9,20,0.05));
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent);
  font-size: 16px;
  border: 1px solid rgba(229,9,20,0.2);
}

.position-details {
  display: flex;
  flex-direction: column;
}

.position-name {
  font-size: 15px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 4px;
}

.position-permissions {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
}

.permission-tag {
  padding: 2px 8px;
  background: rgba(255,255,255,0.06);
  border-radius: 4px;
  font-size: 11px;
  color: var(--text-muted);
}

.position-actions {
  display: flex;
  gap: 6px;
}

/* Invite Form */
.invite-form {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.invite-form .full-width {
  grid-column: 1 / -1;
}

.invite-field label {
  display: block;
  font-size: 12px;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 6px;
}

.invite-field input,
.invite-field select {
  width: 100%;
  padding: 12px 16px;
  background: var(--bg-elevated);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: var(--radius-sm);
  color: var(--text-primary);
  font-size: 14px;
  transition: all var(--transition);
}

.invite-field input:focus,
.invite-field select:focus {
  outline: none;
  border-color: var(--accent);
  background: rgba(229,9,20,0.04);
  box-shadow: 0 0 0 3px rgba(229,9,20,0.1);
}

.invite-field input::placeholder {
  color: var(--text-muted);
}

/* Staff Filters */
.staff-filters {
  display: flex;
  gap: 12px;
  margin-bottom: 16px;
  align-items: center;
}

.staff-search-box {
  flex: 1;
  position: relative;
  max-width: 300px;
}

.staff-search-box i {
  position: absolute;
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-muted);
  font-size: 13px;
  pointer-events: none;
  transition: color var(--transition);
}

.staff-search-box input {
  width: 100%;
  padding: 10px 14px 10px 36px;
  background: var(--bg-elevated);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: var(--radius-sm);
  color: var(--text-primary);
  font-size: 13px;
  outline: none;
  transition: all var(--transition);
}

.staff-search-box input::placeholder {
  color: var(--text-muted);
}

.staff-search-box input:focus {
  border-color: var(--accent);
  background: rgba(229, 9, 20, 0.04);
  box-shadow: 0 0 0 3px rgba(229, 9, 20, 0.1);
}

.staff-search-box input:focus + i,
.staff-search-box:focus-within i {
  color: var(--accent);
}

.staff-filter-dropdown select {
  padding: 10px 14px;
  background: var(--bg-elevated);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: var(--radius-sm);
  color: var(--text-primary);
  font-size: 13px;
  outline: none;
  cursor: pointer;
  transition: all var(--transition);
  min-width: 180px;
}

.staff-filter-dropdown select:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(229, 9, 20, 0.1);
}

.staff-filter-dropdown select:hover {
  border-color: rgba(255, 255, 255, 0.12);
}

/* Empty staff state */
.empty-staff {
  text-align: center;
  padding: 48px 20px;
}

.empty-staff-icon {
  font-size: 48px;
  color: var(--text-muted);
  margin-bottom: 16px;
  opacity: 0.5;
}

.empty-staff-title {
  font-size: 16px;
  font-weight: 600;
  color: var(--text-secondary);
  margin-bottom: 8px;
}

.empty-staff-desc {
  font-size: 13px;
  color: var(--text-muted);
  max-width: 320px;
  margin: 0 auto;
}

/* Responsive for settings */
@media (max-width: 768px) {
  .settings-tabs {
    flex-wrap: wrap;
  }
  
  .settings-tab {
    flex: 1 1 calc(50% - 4px);
    min-width: 0;
    padding: 10px 12px;
    font-size: 12px;
  }
  
  .invite-form {
    grid-template-columns: 1fr;
  }
  
  .settings-info-grid {
    grid-template-columns: 1fr;
  }
}

/* ============================================
   DOCUMENTS / ДОКУМЕНТАЦИЯ
   ============================================ */

/* Категории документов */
.docs-categories {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 16px;
}

.docs-cat-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 16px;
  border-radius: 20px;
  border: 1px solid var(--border-color, #333);
  background: var(--card-bg, #1e1e2e);
  color: var(--text-primary, #eee);
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s;
  position: relative;
}

.docs-cat-btn:hover {
  border-color: var(--cat-color, var(--primary, #e50914));
  background: var(--cat-color, var(--primary, #e50914))15;
}

.docs-cat-btn.active {
  border-color: var(--cat-color, var(--primary, #e50914));
  background: var(--cat-color, var(--primary, #e50914))20;
  color: var(--cat-color, var(--primary, #e50914));
}

.docs-cat-count {
  background: var(--border-color, #333);
  color: var(--text-secondary, #888);
  font-size: 11px;
  padding: 2px 6px;
  border-radius: 10px;
  min-width: 20px;
  text-align: center;
}

.docs-cat-btn.active .docs-cat-count {
  background: var(--cat-color, var(--primary, #e50914));
  color: #fff;
}

.docs-cat-delete {
  display: none;
  margin-left: 4px;
  color: var(--danger, #ef4444);
  font-size: 16px;
  font-weight: bold;
  cursor: pointer;
  line-height: 1;
}

.docs-cat-btn:hover .docs-cat-delete {
  display: inline;
}

/* Поиск документов */
.docs-search {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 16px;
  background: var(--card-bg, #1e1e2e);
  border: 1px solid var(--border-color, #333);
  border-radius: 10px;
  margin-bottom: 16px;
}

.docs-search i {
  color: var(--text-muted, #666);
  font-size: 14px;
}

.docs-search input {
  flex: 1;
  border: none;
  background: transparent;
  color: var(--text-primary, #eee);
  font-size: 14px;
  outline: none;
}

.docs-search input::placeholder {
  color: var(--text-muted, #666);
}

/* Список документов */
.docs-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.doc-item {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 16px;
  background: var(--card-bg, #1e1e2e);
  border: 1px solid var(--border-color, #333);
  border-radius: 12px;
  cursor: pointer;
  transition: all 0.2s;
}

.doc-item:hover {
  border-color: var(--primary, #e50914);
  background: var(--primary, #e50914)08;
  transform: translateY(-1px);
}

.doc-icon {
  width: 44px;
  height: 44px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  flex-shrink: 0;
}

.doc-info {
  flex: 1;
  min-width: 0;
}

.doc-title {
  font-weight: 600;
  font-size: 14px;
  color: var(--text-primary, #eee);
  margin-bottom: 4px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.doc-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

.doc-category-tag {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 2px 8px;
  border-radius: 8px;
  font-size: 11px;
  font-weight: 500;
}

.doc-date,
.doc-size {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 11px;
  color: var(--text-muted, #666);
}

.doc-desc {
  font-size: 12px;
  color: var(--text-secondary, #888);
  margin-top: 4px;
  line-height: 1.4;
}

.doc-actions {
  display: flex;
  gap: 4px;
  flex-shrink: 0;
}

.doc-action-btn {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  border: none;
  background: transparent;
  color: var(--text-secondary, #888);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  transition: all 0.2s;
}

.doc-action-btn:hover {
  background: var(--primary, #e50914)20;
  color: var(--primary, #e50914);
}

.doc-action-btn.danger:hover {
  background: var(--danger, #ef4444)20;
  color: var(--danger, #ef4444);
}

/* Загрузка файла */
.doc-file-upload {
  padding: 12px;
  border: 2px dashed var(--border-color, #333);
  border-radius: 10px;
  text-align: center;
}

.doc-file-upload input[type="file"] {
  width: 100%;
  padding: 8px;
  color: var(--text-primary, #eee);
  font-size: 13px;
}

.doc-file-hint {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  color: var(--text-muted, #666);
  font-size: 12px;
  margin-top: 8px;
}

/* Просмотр документа */
.doc-viewer {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.doc-viewer-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--border-color, #333);
}

.doc-viewer-info {
  display: flex;
  gap: 12px;
  align-items: center;
}

.doc-viewer-content {
  min-height: 200px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.doc-pdf-viewer {
  width: 100%;
  height: 60vh;
  border: 1px solid var(--border-color, #333);
  border-radius: 8px;
}

.doc-image-viewer {
  padding: 16px;
  background: var(--input-bg, #2a2a3e);
  border-radius: 8px;
}

.doc-image-viewer img {
  max-width: 100%;
  max-height: 60vh;
  border-radius: 8px;
  object-fit: contain;
}

.doc-text-viewer {
  width: 100%;
  max-height: 60vh;
  overflow: auto;
  padding: 16px;
  background: var(--input-bg, #2a2a3e);
  border-radius: 8px;
  font-family: 'Courier New', monospace;
  font-size: 13px;
  line-height: 1.6;
  color: var(--text-primary, #eee);
  white-space: pre-wrap;
  word-wrap: break-word;
}

.doc-file-preview {
  flex-direction: column;
  text-align: center;
  padding: 40px 20px;
}

.doc-file-large-icon {
  font-size: 4rem;
  color: var(--primary, #e50914);
  margin-bottom: 16px;
}

.doc-file-name {
  font-size: 16px;
  font-weight: 600;
  color: var(--text-primary, #eee);
  margin-bottom: 8px;
}

.doc-file-size {
  font-size: 13px;
  color: var(--text-muted, #666);
}

.doc-no-file {
  flex-direction: column;
  text-align: center;
  padding: 40px 20px;
}

/* Модальное окно danger кнопка */
.modal-btn-danger {
  background: var(--danger, #ef4444);
  color: #fff;
  border: none;
  padding: 10px 20px;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: all 0.2s;
}

.modal-btn-danger:hover {
  background: #dc2626;
}

/* Адаптив для документов */
@media (max-width: 768px) {
  .docs-categories {
    gap: 6px;
  }
  
  .docs-cat-btn {
    padding: 6px 12px;
    font-size: 12px;
  }
  
  .doc-item {
    padding: 12px;
    gap: 10px;
  }
  
  .doc-icon {
    width: 36px;
    height: 36px;
    font-size: 16px;
  }
  
  .doc-title {
    font-size: 13px;
  }
  
  .doc-actions {
    flex-direction: column;
    gap: 2px;
  }
  
  .doc-action-btn {
    width: 28px;
    height: 28px;
  }
  
  .doc-pdf-viewer {
    height: 50vh;
  }
}
