/* 
  ViTechCode Shared Design System
  Style: Glassmorphic Premium Dark Mode
*/

@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;500;600;700&display=swap');

:root {
  --font-family: 'Outfit', sans-serif;
  --bg-base: #0f0f13;
  --bg-surface: rgba(22, 22, 28, 0.7);
  --bg-surface-hover: rgba(30, 30, 40, 0.85);
  --border-color: rgba(255, 255, 255, 0.08);
  --border-color-hover: rgba(255, 255, 255, 0.15);
  
  /* HSL Colors */
  --primary-hue: 220; /* Blue-Violet default */
  --primary-color: hsl(var(--primary-hue), 90%, 60%);
  --primary-color-glow: hsla(var(--primary-hue), 90%, 60%, 0.15);
  --accent-color: #ec4899; /* Pink */
  
  --text-main: #f3f4f6;
  --text-muted: #9ca3af;
  --text-light: #ffffff;
  
  --card-blur: 16px;
  --header-height: 70px;
  --transition-smooth: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Base Body Setup */
body {
  margin: 0;
  padding: 0;
  background-color: var(--bg-base);
  color: var(--text-main);
  font-family: var(--font-family);
  background-image: 
    radial-gradient(circle at 10% 20%, rgba(59, 130, 246, 0.08) 0%, transparent 40%),
    radial-gradient(circle at 90% 80%, rgba(236, 72, 153, 0.08) 0%, transparent 40%);
  background-attachment: fixed;
  overflow-x: hidden;
}

/* Header Banner - Common Layout */
.vitech-header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: var(--header-height);
  background: rgba(15, 15, 20, 0.75);
  backdrop-filter: blur(var(--card-blur));
  -webkit-backdrop-filter: blur(var(--card-blur));
  border-bottom: 1px solid var(--border-color);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 24px;
  box-sizing: border-box;
  z-index: 1000;
  box-shadow: 0 4px 30px rgba(0, 0, 0, 0.2);
}

.vitech-header-left {
  display: flex;
  align-items: center;
  gap: 12px;
}

.vitech-logo {
  font-size: 1.25rem;
  font-weight: 700;
  background: linear-gradient(135deg, var(--primary-color) 0%, var(--accent-color) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 8px;
}

.vitech-logo-dot {
  width: 10px;
  height: 10px;
  background: var(--primary-color);
  border-radius: 50%;
  box-shadow: 0 0 10px var(--primary-color);
}

.vitech-search-container {
  position: relative;
  width: 320px;
}

.vitech-search-input {
  width: 100%;
  padding: 8px 16px 8px 36px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-color);
  border-radius: 30px;
  color: var(--text-light);
  font-family: var(--font-family);
  font-size: 0.9rem;
  outline: none;
  transition: var(--transition-smooth);
}

.vitech-search-input:focus {
  background: rgba(255, 255, 255, 0.08);
  border-color: var(--primary-color);
  box-shadow: 0 0 15px var(--primary-color-glow);
}

.vitech-search-icon {
  position: absolute;
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-muted);
  pointer-events: none;
}

.vitech-header-right {
  display: flex;
  align-items: center;
  gap: 20px;
}

/* Action Icons with Badges */
.vitech-icon-button {
  background: none;
  border: none;
  color: var(--text-main);
  font-size: 1.25rem;
  cursor: pointer;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border-color);
  transition: var(--transition-smooth);
  text-decoration: none;
}

.vitech-icon-button:hover {
  background: rgba(255, 255, 255, 0.08);
  color: var(--primary-color);
  border-color: var(--border-color-hover);
  transform: translateY(-2px);
}

.vitech-badge {
  position: absolute;
  top: -4px;
  right: -4px;
  background: var(--accent-color);
  color: var(--text-light);
  font-size: 0.7rem;
  font-weight: 700;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 0 6px var(--accent-color);
  border: 2px solid var(--bg-base);
}

/* User Profile Widget */
.vitech-user-widget {
  display: flex;
  align-items: center;
  gap: 10px;
  cursor: pointer;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border-color);
  padding: 4px 14px 4px 6px;
  border-radius: 30px;
  transition: var(--transition-smooth);
  position: relative;
}

.vitech-user-widget:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: var(--border-color-hover);
}

.vitech-avatar {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  object-fit: cover;
  border: 1.5px solid var(--primary-color);
}

.vitech-username {
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--text-light);
  max-width: 100px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* Launcher Grid Menu */
.vitech-launcher {
  position: relative;
}

.vitech-dropdown-menu {
  position: absolute;
  top: 50px;
  right: 0;
  width: 280px;
  background: rgba(18, 18, 24, 0.9);
  backdrop-filter: blur(var(--card-blur));
  -webkit-backdrop-filter: blur(var(--card-blur));
  border: 1px solid var(--border-color);
  border-radius: 16px;
  padding: 16px;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5);
  display: none;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
  z-index: 1001;
}

.vitech-dropdown-menu.active {
  display: grid;
}

.vitech-app-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 12px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid var(--border-color);
  color: var(--text-main);
  text-decoration: none;
  text-align: center;
  transition: var(--transition-smooth);
}

.vitech-app-card:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: var(--primary-color);
  transform: translateY(-2px);
  box-shadow: 0 0 10px var(--primary-color-glow);
}

.vitech-app-icon {
  font-size: 1.5rem;
  margin-bottom: 6px;
}

.vitech-app-name {
  font-size: 0.8rem;
  font-weight: 500;
}

.vitech-app-port {
  font-size: 0.7rem;
  color: var(--text-muted);
}

/* Glassmorphism Common Card */
.glass-card {
  background: var(--bg-surface);
  backdrop-filter: blur(var(--card-blur));
  -webkit-backdrop-filter: blur(var(--card-blur));
  border: 1px solid var(--border-color);
  border-radius: 16px;
  padding: 24px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.25);
  transition: var(--transition-smooth);
}

.glass-card:hover {
  border-color: var(--border-color-hover);
  background: var(--bg-surface-hover);
}

/* Dropdown list for Chats & Notifications */
.vitech-list-dropdown {
  position: absolute;
  top: 50px;
  right: 0;
  width: 340px;
  background: rgba(18, 18, 24, 0.95);
  backdrop-filter: blur(var(--card-blur));
  border: 1px solid var(--border-color);
  border-radius: 16px;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5);
  display: none;
  flex-direction: column;
  z-index: 1001;
  overflow: hidden;
}

.vitech-list-dropdown.active {
  display: flex;
}

.vitech-dropdown-header {
  padding: 12px 16px;
  border-bottom: 1px solid var(--border-color);
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text-light);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.vitech-dropdown-item {
  display: flex;
  gap: 12px;
  padding: 12px 16px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.03);
  color: var(--text-main);
  text-decoration: none;
  font-size: 0.85rem;
  transition: var(--transition-smooth);
}

.vitech-dropdown-item:hover {
  background: rgba(255, 255, 255, 0.05);
}

.vitech-dropdown-item-avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  object-fit: cover;
}

.vitech-dropdown-item-content {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.vitech-dropdown-item-title {
  font-weight: 600;
  color: var(--text-light);
}

.vitech-dropdown-item-text {
  color: var(--text-muted);
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.vitech-dropdown-item-time {
  font-size: 0.7rem;
  color: var(--text-muted);
  margin-top: 4px;
}

/* Shared Layout Workspace Grid for Admin Pages */
.admin-container {
  margin-top: var(--header-height);
  padding: 24px;
  display: grid;
  grid-template-columns: 240px 1fr;
  gap: 24px;
  min-height: calc(100vh - var(--header-height));
  box-sizing: border-box;
}

/* Admin Sidebar Layout */
.admin-sidebar {
  background: rgba(18, 18, 24, 0.4);
  border-right: 1px solid var(--border-color);
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  border-radius: 16px;
}

.admin-sidebar-link {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  border-radius: 12px;
  color: var(--text-muted);
  text-decoration: none;
  font-weight: 500;
  transition: var(--transition-smooth);
}

.admin-sidebar-link:hover, .admin-sidebar-link.active {
  color: var(--text-light);
  background: rgba(255, 255, 255, 0.05);
  border-left: 3px solid var(--primary-color);
}

/* Utility classes */
.flex { display: flex; }
.flex-col { flex-direction: column; }
.justify-between { justify-content: space-between; }
.items-center { align-items: center; }
.gap-2 { gap: 8px; }
.gap-4 { gap: 16px; }
.mt-4 { margin-top: 16px; }
.mb-4 { margin-bottom: 16px; }
.grid-cols-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.badge-status { padding: 4px 8px; border-radius: 12px; font-size: 0.75rem; font-weight: 600; }
.badge-active { background: rgba(16, 185, 129, 0.15); color: #10b981; }
.badge-inactive { background: rgba(239, 68, 68, 0.15); color: #ef4444; }

/* Responsive styles */
@media (max-width: 768px) {
  .admin-container {
    grid-template-columns: 1fr;
  }
  .vitech-search-container {
    display: none;
  }
}
