/* STAGE 4: Modern ERP UI/UX - App Launcher Design */

/* CSS Variables for theming */
:root {
  --primary-color: #6366f1;
  --primary-dark: #4f46e5;
  --secondary-color: #64748b;
  --accent-color: #06b6d4;
  --success-color: #10b981;
  --warning-color: #f59e0b;
  --error-color: #ef4444;
  --background: #f8fafc;
  --surface: #ffffff;
  --surface-hover: #f1f5f9;
  --border-color: #e2e8f0;
  --text-primary: #0f172a;
  --text-secondary: #64748b;
  --text-muted: #94a3b8;
  --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05);
  --shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
  --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);
  --radius: 8px;
  --radius-lg: 12px;
  --app-bar-height: 64px;
  --sidebar-width: 280px;
}

/* Base reset and typography */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
  line-height: 1.6;
  color: var(--text-primary);
  background-color: var(--background);
  font-size: 14px;
  overflow-x: hidden;
}

/* App Layout Structure */
.app-container {
  display: flex;
  height: 100vh;
  background: var(--background);
}

/* Top App Bar */
.app-bar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: var(--app-bar-height);
  background: var(--surface);
  border-bottom: 1px solid var(--border-color);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 24px;
  z-index: 100;
  box-shadow: var(--shadow-sm);
}

.app-bar-left {
  display: flex;
  align-items: center;
  gap: 16px;
}

.app-bar-logo {
  display: flex;
  align-items: center;
  gap: 12px;
  font-weight: 600;
  font-size: 18px;
  color: var(--primary-color);
  text-decoration: none;
}

.app-bar-logo svg {
  width: 32px;
  height: 32px;
}

.app-bar-center {
  flex: 1;
  display: flex;
  justify-content: center;
}

.app-bar-search {
  width: 100%;
  max-width: 480px;
  position: relative;
}

.app-bar-search input {
  width: 100%;
  padding: 8px 12px 8px 40px;
  border: 1px solid var(--border-color);
  border-radius: var(--radius);
  background: var(--background);
  font-size: 14px;
  transition: all 0.2s ease;
}

.app-bar-search input:focus {
  outline: none;
  border-color: var(--primary-color);
  background: var(--surface);
  box-shadow: 0 0 0 3px rgb(99 102 241 / 0.1);
}

.app-bar-search svg {
  position: absolute;
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  width: 16px;
  height: 16px;
  color: var(--text-muted);
}

.app-bar-right {
  display: flex;
  align-items: center;
  gap: 12px;
}

.app-bar-notifications {
  position: relative;
  padding: 8px;
  border-radius: var(--radius);
  background: transparent;
  border: none;
  cursor: pointer;
  transition: background-color 0.2s ease;
}

.app-bar-notifications:hover {
  background: var(--surface-hover);
}

.notification-badge {
  position: absolute;
  top: 4px;
  right: 4px;
  width: 8px;
  height: 8px;
  background: var(--error-color);
  border-radius: 50%;
  border: 2px solid var(--surface);
}

.app-bar-user {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 4px 8px;
  border-radius: var(--radius);
  cursor: pointer;
  transition: background-color 0.2s ease;
}

.app-bar-user:hover {
  background: var(--surface-hover);
}

.user-avatar {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--primary-color);
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-weight: 500;
  font-size: 14px;
}

.user-name {
  font-weight: 500;
  color: var(--text-primary);
}

.user-role {
  font-size: 12px;
  color: var(--text-secondary);
}

/* Main Content Area */
.main-content {
  margin-top: var(--app-bar-height);
  display: flex;
  flex: 1;
}

.sidebar {
  width: var(--sidebar-width);
  background: var(--surface);
  border-right: 1px solid var(--border-color);
  padding: 24px 0;
  overflow-y: auto;
}

.content-area {
  flex: 1;
  padding: 24px;
  overflow-y: auto;
}

/* App Launcher Grid */
.app-launcher {
  padding: 24px;
}

.app-launcher-title {
  font-size: 24px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 8px;
}

.app-launcher-subtitle {
  color: var(--text-secondary);
  margin-bottom: 32px;
}

.app-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 20px;
  margin-bottom: 40px;
}

.app-card {
  background: var(--surface);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 24px;
  text-decoration: none;
  transition: all 0.2s ease;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  min-height: 160px;
  justify-content: center;
}

.app-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
  border-color: var(--primary-color);
}

.app-icon {
  width: 48px;
  height: 48px;
  background: var(--primary-color);
  border-radius: var(--radius);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 16px;
  color: white;
  font-size: 24px;
}

.app-card.administration .app-icon {
  background: var(--error-color);
}

.app-card.sales .app-icon {
  background: var(--success-color);
}

.app-card.inventory .app-icon {
  background: var(--warning-color);
}

.app-card.hr .app-icon {
  background: var(--accent-color);
}

.app-card.finance .app-icon {
  background: var(--secondary-color);
}

.app-name {
  font-size: 16px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 4px;
}

.app-description {
  font-size: 12px;
  color: var(--text-secondary);
  line-height: 1.4;
}

/* Login form - Modern design */
.login-container {
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 100vh;
  background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
  padding: 20px;
}

.login-form {
  background: var(--surface);
  padding: 48px;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  width: 100%;
  max-width: 400px;
}

.login-form h2 {
  text-align: center;
  margin-bottom: 32px;
  color: var(--text-primary);
  font-size: 28px;
  font-weight: 600;
}

/* Form elements */
.form-group {
  margin-bottom: 20px;
}

label {
  display: block;
  margin-bottom: 5px;
  font-weight: 500;
  color: #555;
}

input[type="email"],
input[type="password"],
input[type="text"],
textarea,
select {
  width: 100%;
  padding: 12px;
  border: 2px solid #e0e0e0;
  border-radius: 5px;
  font-size: 16px;
  transition: border-color 0.3s;
}

input:focus,
textarea:focus,
select:focus {
  outline: none;
  border-color: #667eea;
}

/* Buttons */
.btn {
  padding: 12px 24px;
  border: none;
  border-radius: 5px;
  font-size: 16px;
  cursor: pointer;
  transition: all 0.3s;
  text-decoration: none;
  display: inline-block;
  text-align: center;
}

.btn-primary {
  background: #667eea;
  color: white;
}

.btn-primary:hover {
  background: #5a6fd8;
}

.btn-secondary {
  background: #6c757d;
  color: white;
}

.btn-secondary:hover {
  background: #5a6268;
}

.btn-success {
  background: #28a745;
  color: white;
}

.btn-success:hover {
  background: #218838;
}

.btn-danger {
  background: #dc3545;
  color: white;
}

.btn-danger:hover {
  background: #c82333;
}

.btn-logout {
  background: #6c757d;
  color: white;
  padding: 8px 16px;
  font-size: 14px;
}

/* Dashboard */
.dashboard {
  background: white;
  border-radius: 8px;
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
  overflow: hidden;
}

.nav-tabs {
  display: flex;
  background: #f8f9fa;
  border-bottom: 1px solid #dee2e6;
}

.nav-tab {
  padding: 15px 20px;
  cursor: pointer;
  border: none;
  background: none;
  font-size: 16px;
  color: #666;
  transition: all 0.3s;
}

.nav-tab:hover {
  background: #e9ecef;
}

.nav-tab.active {
  background: white;
  color: #333;
  border-bottom: 2px solid #667eea;
}

.tab-content {
  padding: 20px;
}

/* Tables */
.table-container {
  overflow-x: auto;
}

table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 20px;
}

th, td {
  padding: 12px;
  text-align: left;
  border-bottom: 1px solid #dee2e6;
}

th {
  background: #f8f9fa;
  font-weight: 600;
  color: #333;
}

tr:hover {
  background: #f8f9fa;
}

/* Modal */
.modal {
  display: none;
  position: fixed;
  z-index: 1000;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  background: rgba(0,0,0,0.5);
}

.modal.active {
  display: flex;
  justify-content: center;
  align-items: center;
}

.modal-content {
  background: white;
  padding: 30px;
  border-radius: 10px;
  width: 90%;
  max-width: 500px;
  max-height: 80vh;
  overflow-y: auto;
}

.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
}

.modal-header h3 {
  margin: 0;
  color: #333;
}

.close {
  font-size: 28px;
  font-weight: bold;
  cursor: pointer;
  color: #aaa;
}

.close:hover {
  color: #333;
}

/* Chat */
.chat-container {
  height: 400px;
  display: flex;
  flex-direction: column;
  border: 1px solid #dee2e6;
  border-radius: 8px;
}

.chat-messages {
  flex: 1;
  padding: 15px;
  overflow-y: auto;
  background: #f8f9fa;
}

.chat-input-container {
  padding: 15px;
  border-top: 1px solid #dee2e6;
  display: flex;
  gap: 10px;
}

.chat-input {
  flex: 1;
  padding: 10px;
  border: 1px solid #dee2e6;
  border-radius: 5px;
}

.chat-status {
  padding: 10px;
  text-align: center;
  font-size: 14px;
  background: #e9ecef;
  border-top: 1px solid #dee2e6;
}

.chat-status.online {
  background: #d4edda;
  color: #155724;
}

.chat-status.offline {
  background: #f8d7da;
  color: #721c24;
}

.message {
  margin-bottom: 10px;
  padding: 8px 12px;
  background: white;
  border-radius: 5px;
  box-shadow: 0 1px 2px rgba(0,0,0,0.1);
}

.message-time {
  font-size: 12px;
  color: #666;
  margin-left: 8px;
}

/* Alerts */
.alert {
  padding: 12px 16px;
  margin: 10px 0;
  border-radius: 5px;
  border-left: 4px solid;
}

.alert-success {
  background: #d4edda;
  color: #155724;
  border-color: #28a745;
}

.alert-error {
  background: #f8d7da;
  color: #721c24;
  border-color: #dc3545;
}

/* Loading */
.loading {
  text-align: center;
  padding: 20px;
  color: #666;
}

/* Responsive */
@media (max-width: 768px) {
  .container {
    padding: 10px;
  }
  
  .header {
    flex-direction: column;
    text-align: center;
    gap: 10px;
  }
  
  .nav-tabs {
    flex-direction: column;
  }
  
  .nav-tab {
    text-align: left;
  }
  
  .modal-content {
    width: 95%;
    padding: 20px;
  }
  
  .chat-input-container {
    flex-direction: column;
  }
}

/* Module and Sub-App Styles */
.sidebar-header {
  padding: 0 24px 16px;
  border-bottom: 1px solid var(--border-color);
}

.sidebar-header h3 {
  font-size: 18px;
  font-weight: 600;
  color: var(--text-primary);
}

.sidebar-nav {
  padding: 16px 0;
}

.sidebar-nav-item {
  display: flex;
  align-items: center;
  padding: 12px 24px;
  color: var(--text-secondary);
  text-decoration: none;
  transition: all 0.2s ease;
}

.sidebar-nav-item:hover {
  background: var(--surface-hover);
  color: var(--text-primary);
}

.sidebar-nav-item.active {
  background: var(--primary-color);
  color: white;
}

.sidebar-nav-icon {
  margin-right: 12px;
  font-size: 16px;
}

.sidebar-nav-text {
  font-size: 14px;
  font-weight: 500;
}

.module-header {
  margin-bottom: 32px;
}

.module-header h1 {
  font-size: 32px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 8px;
}

.module-header p {
  color: var(--text-secondary);
  font-size: 16px;
}

/* Administration Module Styles */
.admin-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 24px;
  margin-top: 24px;
}

.admin-card {
  background: var(--surface);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 24px;
  cursor: pointer;
  transition: all 0.2s ease;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}

.admin-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
  border-color: var(--primary-color);
}

.admin-icon {
  font-size: 32px;
  margin-bottom: 16px;
}

.admin-title {
  font-size: 18px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 8px;
}

.admin-desc {
  color: var(--text-secondary);
  font-size: 14px;
  line-height: 1.5;
}

.breadcrumb {
  color: var(--text-secondary);
  margin-left: 16px;
  font-size: 14px;
}

.breadcrumb:before {
  content: "/ ";
  color: var(--text-muted);
}

/* Slack-like Chat Interface Styles */
.slack-container {
  display: flex;
  height: calc(100vh - var(--app-bar-height));
  background: var(--background);
}

.slack-sidebar {
  width: 260px;
  background: #3f0e40;
  color: #ffffff;
  display: flex;
  flex-direction: column;
  border-right: 1px solid #522653;
}

.workspace-header {
  padding: 16px;
  border-bottom: 1px solid #522653;
  background: #350d36;
}

.workspace-name {
  font-size: 18px;
  font-weight: 700;
  color: #ffffff;
  margin-bottom: 4px;
}

.workspace-status {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  color: #d1d9e0;
}

.status-indicator {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #2eb67d;
}

.status-indicator.away { background: #ecb22e; }
.status-indicator.busy { background: #e01e5a; }
.status-indicator.offline { background: #868686; }

.sidebar-section {
  padding: 16px 0;
  border-bottom: 1px solid #522653;
}

.sidebar-section:last-child {
  border-bottom: none;
  flex: 1;
}

.section-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 4px 16px;
  color: #d1d9e0;
  cursor: pointer;
  transition: background 0.2s ease;
}

.section-item:hover {
  background: rgba(255, 255, 255, 0.1);
}

.section-icon {
  font-size: 16px;
  width: 20px;
  text-align: center;
}

.section-text {
  font-size: 15px;
}

.section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 16px 8px;
  margin-bottom: 4px;
}

.section-title {
  font-size: 15px;
  font-weight: 400;
  color: #d1d9e0;
}

.add-btn {
  background: none;
  border: none;
  color: #d1d9e0;
  font-size: 18px;
  cursor: pointer;
  padding: 0;
  width: 20px;
  height: 20px;
  border-radius: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.add-btn:hover {
  background: rgba(255, 255, 255, 0.1);
}

.channel-item, .dm-item, .call-item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 2px 16px;
  color: #d1d9e0;
  cursor: pointer;
  position: relative;
  min-height: 28px;
}

.channel-item:hover, .dm-item:hover, .call-item:hover {
  background: rgba(255, 255, 255, 0.1);
}

.channel-item.active, .dm-item.active {
  background: #1264a3;
  color: #ffffff;
}

.channel-hash {
  color: #bcabbc;
  font-weight: 400;
}

.channel-name, .dm-name, .call-name {
  font-size: 15px;
  flex: 1;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.user-avatar, .group-avatar {
  width: 20px;
  height: 20px;
  border-radius: 4px;
  background: #4a154b;
  color: #ffffff;
  font-size: 11px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  text-transform: uppercase;
}

.user-avatar.online { border: 2px solid #2eb67d; }
.user-avatar.away { border: 2px solid #ecb22e; }

.group-avatar {
  background: #616061;
}

.unread-badge, .member-count, .call-participants {
  background: #e01e5a;
  color: #ffffff;
  font-size: 11px;
  font-weight: 700;
  padding: 2px 6px;
  border-radius: 12px;
  min-width: 16px;
  text-align: center;
}

.member-count, .call-participants {
  background: #616061;
}

.call-icon {
  font-size: 14px;
}

.call-item.active .call-icon {
  animation: pulse 2s infinite;
}

@keyframes pulse {
  0% { opacity: 1; }
  50% { opacity: 0.5; }
  100% { opacity: 1; }
}

.slack-main {
  flex: 1;
  display: flex;
  flex-direction: column;
  background: #ffffff;
}

.chat-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 20px;
  border-bottom: 1px solid var(--border-color);
  background: #ffffff;
}

.channel-info {
  flex: 1;
}

.channel-title {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: 18px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 2px;
}

.channel-prefix {
  color: var(--text-secondary);
}

.channel-meta {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 13px;
  color: var(--text-secondary);
}

.header-actions {
  display: flex;
  gap: 8px;
}

.header-btn, .action-btn {
  background: none;
  border: 1px solid var(--border-color);
  border-radius: 4px;
  padding: 6px 8px;
  cursor: pointer;
  font-size: 14px;
  transition: all 0.2s ease;
}

.header-btn:hover, .action-btn:hover {
  background: var(--surface-hover);
  border-color: var(--primary-color);
}

.action-btn.small {
  padding: 2px 6px;
  font-size: 12px;
  border: none;
  background: transparent;
}

.messages-container {
  flex: 1;
  padding: 20px;
  overflow-y: auto;
  background: #ffffff;
}

.date-divider {
  text-align: center;
  margin: 24px 0 16px;
  position: relative;
}

.date-divider span {
  background: #ffffff;
  color: var(--text-secondary);
  font-size: 13px;
  font-weight: 700;
  padding: 0 12px;
  position: relative;
  z-index: 1;
}

.date-divider:before {
  content: '';
  position: absolute;
  top: 50%;
  left: 0;
  right: 0;
  height: 1px;
  background: var(--border-color);
}

.message-group {
  display: flex;
  gap: 12px;
  margin-bottom: 16px;
  padding: 4px 0;
  border-radius: 8px;
  transition: background 0.2s ease;
}

.message-group:hover {
  background: #f8f9fa;
}

.message-group:hover .message-actions {
  opacity: 1;
}

.message-avatar {
  width: 36px;
  height: 36px;
  border-radius: 8px;
  background: var(--primary-color);
  color: #ffffff;
  font-size: 14px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.message-avatar img {
  width: 100%;
  height: 100%;
  border-radius: 8px;
  object-fit: cover;
}

.message-content {
  flex: 1;
  min-width: 0;
}

.message-header {
  display: flex;
  align-items: baseline;
  gap: 8px;
  margin-bottom: 4px;
}

.message-author {
  font-weight: 700;
  font-size: 15px;
  color: var(--text-primary);
}

.message-time {
  font-size: 12px;
  color: var(--text-secondary);
}

.message-text {
  font-size: 15px;
  line-height: 1.5;
  color: var(--text-primary);
  word-wrap: break-word;
}

.message-reactions {
  display: flex;
  gap: 4px;
  margin-top: 4px;
  flex-wrap: wrap;
}

.reaction {
  background: var(--surface-hover);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  padding: 2px 8px;
  font-size: 12px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.reaction:hover {
  background: var(--primary-color);
  color: #ffffff;
  border-color: var(--primary-color);
}

.message-actions {
  display: flex;
  gap: 4px;
  margin-top: 4px;
  opacity: 0;
  transition: opacity 0.2s ease;
}

.message-composer {
  padding: 20px;
  border-top: 1px solid var(--border-color);
  background: #ffffff;
}

.composer-toolbar {
  display: flex;
  gap: 8px;
  margin-bottom: 8px;
}

.composer-btn {
  background: none;
  border: none;
  padding: 4px;
  cursor: pointer;
  font-size: 16px;
  border-radius: 4px;
  transition: background 0.2s ease;
}

.composer-btn:hover {
  background: var(--surface-hover);
}

.input-container {
  position: relative;
  display: flex;
  align-items: center;
}

.message-input {
  width: 100%;
  padding: 12px 50px 12px 16px;
  border: 1px solid var(--border-color);
  border-radius: 8px;
  font-size: 15px;
  resize: none;
  min-height: 44px;
  max-height: 200px;
}

.message-input:focus {
  outline: none;
  border-color: var(--primary-color);
  box-shadow: 0 0 0 1px var(--primary-color);
}

.send-btn {
  position: absolute;
  right: 8px;
  background: var(--primary-color);
  color: #ffffff;
  border: none;
  border-radius: 6px;
  width: 32px;
  height: 32px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s ease;
}

.send-btn:hover {
  background: var(--primary-dark);
}

.send-icon {
  font-size: 14px;
}

.slack-right-panel {
  width: 320px;
  background: #ffffff;
  border-left: 1px solid var(--border-color);
  display: flex;
  flex-direction: column;
}

.panel-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  border-bottom: 1px solid var(--border-color);
}

.close-panel {
  background: none;
  border: none;
  font-size: 18px;
  cursor: pointer;
  padding: 4px;
  border-radius: 4px;
}

.close-panel:hover {
  background: var(--surface-hover);
}

.panel-content {
  flex: 1;
  padding: 20px;
  overflow-y: auto;
}

.channel-details h4 {
  font-size: 24px;
  margin-bottom: 8px;
}

.channel-details p {
  color: var(--text-secondary);
  margin-bottom: 24px;
}

.channel-stats .stat {
  display: flex;
  justify-content: space-between;
  padding: 8px 0;
  border-bottom: 1px solid var(--border-color);
}

.stat-label {
  color: var(--text-secondary);
  font-weight: 500;
}

.app-bar-actions {
  display: flex;
  gap: 8px;
  margin-right: 16px;
}

/* Administration Dashboard Styles */
.module-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 32px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--border-color);
}

.header-left h1 {
  font-size: 28px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 4px;
}

.header-left p {
  color: var(--text-secondary);
  font-size: 16px;
  margin: 0;
}

.header-actions {
  display: flex;
  gap: 12px;
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 16px;
  border: 1px solid var(--border-color);
  border-radius: 6px;
  background: var(--surface);
  color: var(--text-primary);
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
  text-decoration: none;
}

.btn:hover {
  background: var(--surface-hover);
  border-color: var(--primary-color);
}

.btn-primary {
  background: var(--primary-color);
  border-color: var(--primary-color);
  color: #ffffff;
}

.btn-primary:hover {
  background: var(--primary-dark);
  border-color: var(--primary-dark);
}

.btn-secondary {
  background: var(--secondary-color);
  border-color: var(--secondary-color);
  color: #ffffff;
}

.btn-icon {
  font-size: 16px;
}

.data-table-container {
  background: var(--surface);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  overflow: hidden;
}

.table-filters {
  padding: 16px 20px;
  border-bottom: 1px solid var(--border-color);
  background: #f8f9fa;
}

.filter-group {
  display: flex;
  gap: 12px;
  align-items: center;
}

.filter-input, .filter-select {
  padding: 8px 12px;
  border: 1px solid var(--border-color);
  border-radius: 4px;
  font-size: 14px;
}

.filter-input {
  min-width: 200px;
}

.filter-select {
  min-width: 120px;
}

.table-wrapper {
  overflow-x: auto;
}

.data-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
}

.data-table th {
  background: #f8f9fa;
  padding: 12px 16px;
  text-align: left;
  font-weight: 600;
  color: var(--text-primary);
  border-bottom: 1px solid var(--border-color);
}

.data-table td {
  padding: 12px 16px;
  border-bottom: 1px solid var(--border-color);
  vertical-align: middle;
}

.data-table tr:last-child td {
  border-bottom: none;
}

.data-table tr:hover {
  background: #f8f9fa;
}

.loading-cell, .empty-cell, .error-cell {
  text-align: center;
  padding: 40px 16px;
  color: var(--text-secondary);
}

.error-cell {
  color: var(--error-color);
}

.user-info {
  display: flex;
  align-items: center;
  gap: 12px;
}

.user-avatar-small {
  width: 32px;
  height: 32px;
  border-radius: 6px;
  background: var(--primary-color);
  color: #ffffff;
  font-size: 12px;
  font-weight: 600;
  display: flex;
  align-items: center;
  justify-content: center;
}

.user-details {
  flex: 1;
}

.user-name {
  font-weight: 500;
  color: var(--text-primary);
}

.user-meta {
  font-size: 12px;
  color: var(--text-secondary);
}

.role-badges {
  display: flex;
  gap: 4px;
  flex-wrap: wrap;
}

.role-badge {
  background: var(--accent-color);
  color: #ffffff;
  padding: 2px 8px;
  border-radius: 12px;
  font-size: 11px;
  font-weight: 500;
}

.status-badge {
  padding: 4px 8px;
  border-radius: 12px;
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
}

.status-badge.active {
  background: #d1fae5;
  color: #065f46;
}

.status-badge.inactive {
  background: #fef3c7;
  color: #92400e;
}

.action-buttons {
  display: flex;
  gap: 4px;
}

.btn-icon {
  background: none;
  border: none;
  padding: 4px;
  cursor: pointer;
  font-size: 16px;
  border-radius: 4px;
  transition: background 0.2s ease;
}

.btn-icon:hover {
  background: var(--surface-hover);
}

.btn-icon.danger:hover {
  background: #fef2f2;
  color: var(--error-color);
}

.role-info {
  display: flex;
  align-items: center;
  gap: 8px;
}

.role-name {
  font-weight: 500;
  color: var(--text-primary);
}

.system-badge {
  background: var(--warning-color);
  color: #ffffff;
  padding: 2px 6px;
  border-radius: 10px;
  font-size: 10px;
  font-weight: 600;
}

.permission-count, .user-count {
  color: var(--text-secondary);
  font-size: 13px;
}

.type-badge {
  padding: 4px 8px;
  border-radius: 12px;
  font-size: 11px;
  font-weight: 600;
}

.type-badge.system {
  background: #fef3c7;
  color: #92400e;
}

.type-badge.custom {
  background: #dbeafe;
  color: #1e40af;
}

/* Modal Styles */
.modal {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.5);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
}

.modal-content {
  background: var(--surface);
  border-radius: var(--radius-lg);
  width: 90%;
  max-width: 600px;
  max-height: 90vh;
  display: flex;
  flex-direction: column;
  box-shadow: var(--shadow-lg);
}

.modal-content.large {
  max-width: 900px;
}

.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 24px;
  border-bottom: 1px solid var(--border-color);
}

.modal-header h2 {
  font-size: 20px;
  font-weight: 600;
  color: var(--text-primary);
  margin: 0;
}

.modal-close {
  background: none;
  border: none;
  font-size: 24px;
  cursor: pointer;
  padding: 4px;
  border-radius: 4px;
  color: var(--text-secondary);
}

.modal-close:hover {
  background: var(--surface-hover);
}

.modal-body {
  flex: 1;
  padding: 24px;
  overflow-y: auto;
}

.modal-footer {
  display: flex;
  gap: 12px;
  justify-content: flex-end;
  padding: 16px 24px;
  border-top: 1px solid var(--border-color);
}

/* Form Styles */
.form-group {
  margin-bottom: 16px;
}

.form-row {
  display: flex;
  gap: 16px;
}

.form-row .form-group {
  flex: 1;
}

.form-group label {
  display: block;
  margin-bottom: 6px;
  font-weight: 500;
  color: var(--text-primary);
}

.form-group input,
.form-group select,
.form-group textarea {
  width: 100%;
  padding: 8px 12px;
  border: 1px solid var(--border-color);
  border-radius: 4px;
  font-size: 14px;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--primary-color);
  box-shadow: 0 0 0 2px rgba(99, 102, 241, 0.1);
}

.form-help {
  display: block;
  margin-top: 4px;
  font-size: 12px;
  color: var(--text-secondary);
}

.checkbox-group {
  max-height: 200px;
  overflow-y: auto;
  border: 1px solid var(--border-color);
  border-radius: 4px;
  padding: 8px;
}

.checkbox-item {
  display: block;
  padding: 8px;
  cursor: pointer;
  border-radius: 4px;
  transition: background 0.2s ease;
}

.checkbox-item:hover {
  background: var(--surface-hover);
}

.checkbox-item input {
  width: auto;
  margin-right: 8px;
}

.checkbox-label {
  font-weight: 500;
  color: var(--text-primary);
}

.checkbox-description {
  display: block;
  color: var(--text-secondary);
  font-size: 12px;
  margin-top: 2px;
}

/* Permissions Tree */
.permissions-container {
  border: 1px solid var(--border-color);
  border-radius: 6px;
  max-height: 400px;
  overflow: hidden;
}

.permissions-search {
  padding: 12px;
  border-bottom: 1px solid var(--border-color);
}

.permissions-tree {
  max-height: 350px;
  overflow-y: auto;
  padding: 12px;
}

.permission-module {
  margin-bottom: 16px;
}

.module-header h4 {
  font-size: 16px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 8px;
  padding: 8px 12px;
  background: var(--surface-hover);
  border-radius: 4px;
}

.permission-category {
  margin-left: 16px;
  margin-bottom: 12px;
}

.permission-category h5 {
  font-size: 14px;
  font-weight: 500;
  color: var(--text-secondary);
  margin-bottom: 6px;
}

.permission-item {
  display: block;
  padding: 4px 8px;
  margin-left: 16px;
  cursor: pointer;
  border-radius: 4px;
}

.permission-item:hover {
  background: var(--surface-hover);
}

.permission-item input {
  width: auto;
  margin-right: 8px;
}

.permission-name {
  font-weight: 500;
  color: var(--text-primary);
}

.permission-desc {
  display: block;
  color: var(--text-secondary);
  font-size: 12px;
  margin-top: 2px;
}

/* Tab Styles */
.permission-tabs {
  display: flex;
  border-bottom: 1px solid var(--border-color);
  margin-bottom: 20px;
}

.tab-btn {
  background: none;
  border: none;
  padding: 12px 20px;
  cursor: pointer;
  font-size: 14px;
  font-weight: 500;
  color: var(--text-secondary);
  border-bottom: 2px solid transparent;
  transition: all 0.2s ease;
}

.tab-btn:hover {
  color: var(--text-primary);
}

.tab-btn.active {
  color: var(--primary-color);
  border-bottom-color: var(--primary-color);
}

.coming-soon {
  text-align: center;
  padding: 60px 20px;
}

.coming-soon-icon {
  font-size: 64px;
  margin-bottom: 20px;
}

.coming-soon h2 {
  font-size: 24px;
  color: var(--text-primary);
  margin-bottom: 12px;
}

.coming-soon p {
  color: var(--text-secondary);
  font-size: 16px;
  margin-bottom: 32px;
}

/* Mock Mode Indicator */
.mock-indicator {
  background: #fef3c7;
  color: #92400e;
  padding: 4px 12px;
  border-radius: 12px;
  font-size: 12px;
  font-weight: 600;
  margin-left: 16px;
  border: 1px solid #f59e0b;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.sub-app-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 24px;
}

.sub-app-card {
  background: var(--surface);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 24px;
  cursor: pointer;
  transition: all 0.2s ease;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}

.sub-app-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
  border-color: var(--primary-color);
}

.sub-app-icon {
  width: 40px;
  height: 40px;
  background: var(--primary-color);
  border-radius: var(--radius);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  color: white;
  margin-bottom: 16px;
}

.sub-app-name {
  font-size: 18px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 8px;
}

.sub-app-description {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.5;
}

/* User Management Specific Styles */
.user-management-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 24px;
}

.user-management-title {
  font-size: 24px;
  font-weight: 600;
  color: var(--text-primary);
}

.user-management-actions {
  display: flex;
  gap: 12px;
}

.data-table {
  background: var(--surface);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  overflow: hidden;
}

.data-table table {
  width: 100%;
  border-collapse: collapse;
}

.data-table th {
  background: var(--background);
  padding: 16px;
  text-align: left;
  font-weight: 600;
  color: var(--text-primary);
  border-bottom: 1px solid var(--border-color);
}

.data-table td {
  padding: 16px;
  border-bottom: 1px solid var(--border-color);
}

.data-table tr:hover {
  background: var(--surface-hover);
}

/* Badges and Status Indicators */
.badge {
  display: inline-block;
  padding: 4px 8px;
  font-size: 12px;
  font-weight: 500;
  border-radius: 4px;
  background: var(--primary-color);
  color: white;
}

.status-badge {
  display: inline-block;
  padding: 4px 8px;
  font-size: 12px;
  font-weight: 500;
  border-radius: 12px;
}

.status-badge.active {
  background: #dcfce7;
  color: #166534;
}

.status-badge.inactive {
  background: #fee2e2;
  color: #991b1b;
}

.btn-sm {
  padding: 6px 12px;
  font-size: 12px;
}

/* Responsive Design */
@media (max-width: 768px) {
  .app-bar {
    padding: 0 16px;
  }
  
  .app-bar-center {
    display: none;
  }
  
  .app-grid {
    grid-template-columns: 1fr;
  }
  
  .sidebar {
    display: none;
  }
  
  .content-area {
    padding: 16px;
  }
}

/* Role Management Styles */
.role-management-grid {
  margin-top: 24px;
}

.modal-lg {
  width: 90%;
  max-width: 800px;
}

.permissions-grid {
  max-height: 400px;
  overflow-y: auto;
  border: 1px solid #e0e0e0;
  border-radius: 8px;
  padding: 16px;
}

.permission-module {
  margin-bottom: 24px;
}

.permission-module-title {
  font-size: 18px;
  font-weight: 600;
  margin-bottom: 12px;
  color: var(--primary-color);
  border-bottom: 2px solid #e0e0e0;
  padding-bottom: 8px;
}

.permission-category {
  margin-bottom: 16px;
  margin-left: 16px;
}

.permission-category-title {
  font-size: 14px;
  font-weight: 500;
  margin-bottom: 8px;
  color: var(--text-muted);
  text-transform: capitalize;
}

.permission-item {
  display: block;
  margin-bottom: 8px;
  padding: 8px 12px;
  border: 1px solid #f0f0f0;
  border-radius: 6px;
  cursor: pointer;
  transition: background-color 0.2s;
}

.permission-item:hover {
  background: #f8f9fa;
}

.permission-item input[type="checkbox"] {
  margin-right: 10px;
  width: auto;
}

.permission-name {
  font-weight: 500;
  color: var(--text-primary);
}

.permission-desc {
  display: block;
  font-size: 12px;
  color: var(--text-muted);
  margin-left: 26px;
  margin-top: 2px;
}

.permission-management {
  padding: 16px 0;
}

.permission-actions {
  margin-bottom: 20px;
}

.add-permission-form {
  background: #f8f9fa;
  border: 1px solid #e0e0e0;
  border-radius: 8px;
  padding: 20px;
  margin-bottom: 20px;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.form-actions {
  margin-top: 16px;
  text-align: right;
}

.form-actions .btn {
  margin-left: 8px;
}

.role-icon {
  width: 24px;
  height: 24px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
}

.badge-info {
  background: #17a2b8;
  color: white;
}

.badge-warning {
  background: #ffc107;
  color: #212529;
}

.font-weight-bold {
  font-weight: 600;
}

/* Alert Styles */
.alert {
  padding: 12px 16px;
  border-radius: 6px;
  margin: 12px 0;
}

.alert-success {
  background: #d4edda;
  color: #155724;
  border: 1px solid #c3e6cb;
}

.alert-error {
  background: #f8d7da;
  color: #721c24;
  border: 1px solid #f5c6cb;
}

/* Utilities */
.text-center { text-align: center; }
.mt-3 { margin-top: 1rem; }
.mb-3 { margin-bottom: 1rem; }
.mr-2 { margin-right: 0.5rem; }
.ml-2 { margin-left: 0.5rem; }
.d-flex { display: flex; }
.justify-content-between { justify-content: space-between; }
.align-items-center { align-items: center; }
.w-100 { width: 100%; }

/* Discuss - Slack-like Chat Interface */
.discuss-workspace {
  display: flex;
  height: calc(100vh - 60px);
  background: #fff;
}

.discuss-sidebar {
  width: 260px;
  background: #3f0f40;
  color: #fff;
  display: flex;
  flex-direction: column;
  border-right: 1px solid rgba(255, 255, 255, 0.1);
}

.discuss-header {
  padding: 20px 16px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.discuss-header h2 {
  margin: 0;
  font-size: 1.25rem;
  font-weight: 600;
}

.discuss-actions .btn-icon {
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
  border: none;
  padding: 6px;
  border-radius: 4px;
  cursor: pointer;
  transition: background-color 0.2s;
}

.discuss-actions .btn-icon:hover {
  background: rgba(255, 255, 255, 0.2);
}

.channels-section, .direct-messages-section {
  flex: 1;
  overflow-y: auto;
}

.section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 16px 8px;
  font-size: 0.9rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: rgba(255, 255, 255, 0.7);
}

.section-header h3 {
  margin: 0;
  font-size: 0.9rem;
}

.section-header .btn-icon {
  background: none;
  color: rgba(255, 255, 255, 0.5);
  border: none;
  font-size: 1rem;
  cursor: pointer;
  width: 20px;
  height: 20px;
  border-radius: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.section-header .btn-icon:hover {
  background: rgba(255, 255, 255, 0.1);
  color: rgba(255, 255, 255, 0.8);
}

.channels-list, .direct-messages-list {
  padding: 0 8px;
}

.conversation-item {
  display: flex;
  align-items: center;
  padding: 6px 12px;
  margin: 1px 0;
  border-radius: 6px;
  cursor: pointer;
  transition: background-color 0.2s;
  font-size: 0.9rem;
}

.conversation-item:hover {
  background: rgba(255, 255, 255, 0.1);
}

.conversation-item.active {
  background: #1264a3;
}

.conversation-icon {
  width: 20px;
  height: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-right: 12px;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.7);
}

.conversation-item.private .conversation-icon {
  color: rgba(255, 255, 255, 0.5);
}

.user-avatar-small {
  width: 20px;
  height: 20px;
  border-radius: 3px;
  background: #007a5a;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
  font-weight: 600;
  margin-right: 12px;
  color: #fff;
}

.conversation-info {
  flex: 1;
  min-width: 0;
}

.conversation-name {
  font-weight: 500;
  color: rgba(255, 255, 255, 0.9);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.last-message {
  font-size: 0.8rem;
  color: rgba(255, 255, 255, 0.5);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.unread-count {
  background: #e01e5a;
  color: #fff;
  font-size: 0.75rem;
  font-weight: 600;
  padding: 2px 6px;
  border-radius: 10px;
  min-width: 18px;
  text-align: center;
}

.status-indicator {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  margin-left: 8px;
}

.status-indicator.online {
  background: #2eb67d;
}

.status-indicator.away {
  background: #ecb22e;
}

.status-indicator.offline {
  background: rgba(255, 255, 255, 0.3);
}

.user-status {
  padding: 16px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.current-user {
  display: flex;
  align-items: center;
  font-size: 0.9rem;
}

.user-name {
  flex: 1;
  margin: 0 8px;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.9);
}

.loading-channels, .no-items, .error {
  padding: 16px;
  text-align: center;
  color: rgba(255, 255, 255, 0.5);
  font-size: 0.9rem;
}

/* Main Chat Area */
.discuss-main {
  flex: 1;
  display: flex;
  flex-direction: column;
  background: #fff;
}

.chat-header {
  padding: 20px 24px;
  border-bottom: 1px solid #e0e0e0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: #fff;
  z-index: 1;
}

.channel-info h2 {
  margin: 0;
  font-size: 1.25rem;
  font-weight: 600;
  color: #1d1c1d;
}

.channel-info p {
  margin: 4px 0 0;
  color: #616061;
  font-size: 0.9rem;
}

.chat-actions {
  display: flex;
  gap: 8px;
}

.chat-actions .btn-icon {
  background: none;
  color: #616061;
  border: 1px solid #e0e0e0;
  padding: 8px;
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.2s;
}

.chat-actions .btn-icon:hover {
  background: #f8f8f8;
  color: #1d1c1d;
}

.messages-container {
  flex: 1;
  overflow-y: auto;
  padding: 0;
  background: #fff;
}

.messages-list {
  padding: 20px 24px;
}

.message-item {
  display: flex;
  margin-bottom: 16px;
  align-items: flex-start;
}

.message-avatar {
  width: 36px;
  height: 36px;
  border-radius: 8px;
  background: linear-gradient(135deg, #007a5a, #2eb67d);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 600;
  color: #fff;
  margin-right: 12px;
  flex-shrink: 0;
}

.message-content {
  flex: 1;
  min-width: 0;
}

.message-header {
  display: flex;
  align-items: baseline;
  margin-bottom: 4px;
}

.message-author {
  font-weight: 600;
  color: #1d1c1d;
  margin-right: 8px;
}

.message-time {
  font-size: 0.8rem;
  color: #616061;
}

.message-text {
  color: #1d1c1d;
  line-height: 1.46;
  word-wrap: break-word;
}

.message-attachment {
  margin-top: 8px;
  padding: 12px;
  border: 1px solid #e0e0e0;
  border-radius: 8px;
  background: #f8f8f8;
}

.message-attachment a {
  color: #1264a3;
  text-decoration: none;
  font-weight: 500;
}

.message-attachment a:hover {
  text-decoration: underline;
}

.welcome-message {
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Message Input */
.message-input {
  padding: 20px 24px;
  border-top: 1px solid #e0e0e0;
  background: #fff;
}

.message-form {
  position: relative;
}

.input-container {
  position: relative;
  border: 2px solid #e0e0e0;
  border-radius: 8px;
  transition: border-color 0.2s;
}

.input-container:focus-within {
  border-color: #1264a3;
}

.message-form input {
  width: 100%;
  border: none;
  padding: 16px 80px 16px 16px;
  font-size: 1rem;
  outline: none;
  background: transparent;
  resize: none;
}

.message-actions {
  position: absolute;
  right: 8px;
  top: 50%;
  transform: translateY(-50%);
  display: flex;
  gap: 4px;
}

.message-actions .btn-icon {
  background: none;
  border: none;
  color: #616061;
  padding: 6px;
  border-radius: 4px;
  cursor: pointer;
  transition: all 0.2s;
}

.message-actions .btn-icon:hover {
  background: #f8f8f8;
  color: #1d1c1d;
}

.btn-send {
  background: #007a5a !important;
  color: #fff !important;
}

.btn-send:hover {
  background: #006644 !important;
  color: #fff !important;
}

/* Modals for Chat */
.dm-user-list {
  max-height: 400px;
}

.dm-user-list input {
  width: 100%;
  padding: 12px;
  border: 1px solid #e0e0e0;
  border-radius: 6px;
  margin-bottom: 16px;
  outline: none;
}

.dm-user-list input:focus {
  border-color: #1264a3;
}

.users-list {
  max-height: 300px;
  overflow-y: auto;
}

.user-item {
  display: flex;
  align-items: center;
  padding: 12px;
  border-radius: 6px;
  cursor: pointer;
  transition: background-color 0.2s;
}

.user-item:hover {
  background: #f8f8f8;
}

.user-item .user-avatar-small {
  margin-right: 12px;
  background: #007a5a;
}

.user-item .user-info {
  flex: 1;
}

.user-item .user-name {
  font-weight: 500;
  color: #1d1c1d;
}

.user-item .user-email {
  font-size: 0.9rem;
  color: #616061;
}

/* App Launcher States */
.loading-spinner {
  display: flex;
  justify-content: center;
  align-items: center;
  height: 200px;
  color: var(--text-muted);
  font-size: 1.1rem;
}

.no-access-message, .error-message {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 60px 40px;
  height: 300px;
  color: var(--text-muted);
}

.no-access-icon, .error-icon {
  font-size: 4rem;
  margin-bottom: 20px;
  opacity: 0.7;
}

.no-access-message h3, .error-message h3 {
  margin: 0 0 12px;
  color: var(--text-color);
  font-size: 1.5rem;
}

.no-access-message p, .error-message p {
  margin: 0;
  font-size: 1.1rem;
  line-height: 1.5;
  max-width: 400px;
}

/* Responsive Design */
@media (max-width: 768px) {
  .discuss-workspace {
    height: calc(100vh - 60px);
  }
  
  .discuss-sidebar {
    width: 100%;
    position: absolute;
    z-index: 10;
    transform: translateX(-100%);
    transition: transform 0.3s;
  }
  
  .discuss-sidebar.active {
    transform: translateX(0);
  }
  
  .discuss-main {
    width: 100%;
  }
  
  .no-access-message, .error-message {
    padding: 40px 20px;
    height: 250px;
  }
  
  .no-access-icon, .error-icon {
    font-size: 3rem;
  }
  
  .no-access-message h3, .error-message h3 {
    font-size: 1.25rem;
  }
  
  .no-access-message p, .error-message p {
    font-size: 1rem;
  }
}