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

:root {
  /* HSL Color System */
  --primary-hue: 224;
  --accent-hue: 262;
  
  --primary: hsl(var(--primary-hue), 85%, 55%);
  --primary-light: hsl(var(--primary-hue), 85%, 65%);
  --primary-glow: hsla(var(--primary-hue), 85%, 55%, 0.15);
  
  --accent: hsl(var(--accent-hue), 80%, 50%);
  --accent-glow: hsla(var(--accent-hue), 80%, 50%, 0.15);
  
  --bg-gradient-start: hsl(220, 40%, 96%);
  --bg-gradient-end: hsl(260, 40%, 95%);
  
  --glass-bg: rgba(255, 255, 255, 0.75);
  --glass-bg-hover: rgba(255, 255, 255, 0.85);
  --glass-border: rgba(255, 255, 255, 0.6);
  --glass-border-focus: hsla(var(--primary-hue), 85%, 55%, 0.4);
  --glass-shadow: 0 8px 32px 0 rgba(31, 38, 135, 0.05),
                   inset 0 1px 0 0 rgba(255, 255, 255, 0.8);
  --glass-shadow-hover: 0 12px 40px 0 rgba(31, 38, 135, 0.08),
                         inset 0 1px 0 0 rgba(255, 255, 255, 0.9);
  
  /* Text colors */
  --text-main: hsl(220, 40%, 15%);
  --text-muted: hsl(220, 20%, 45%);
  --text-light: hsl(220, 15%, 60%);
  
  /* Status Colors */
  --status-draft-color: hsl(200, 80%, 40%);
  --status-draft-bg: hsl(200, 80%, 94%);
  --status-review-color: hsl(35, 90%, 45%);
  --status-review-bg: hsl(35, 90%, 94%);
  --status-approved-color: hsl(145, 75%, 35%);
  --status-approved-bg: hsl(145, 75%, 93%);
  --status-obsolete-color: hsl(0, 70%, 45%);
  --status-obsolete-bg: hsl(0, 70%, 95%);
  
  /* Card colors */
  --card-shadow: 0 10px 30px -10px rgba(0,0,0,0.06);
  --radius-lg: 16px;
  --radius-md: 12px;
  --radius-sm: 8px;
  
  --transition-smooth: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
  --transition-bounce: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: 'Outfit', 'Sarabun', 'Inter', -apple-system, sans-serif;
  background: linear-gradient(135deg, var(--bg-gradient-start), var(--bg-gradient-end));
  min-height: 100vh;
  color: var(--text-main);
  line-height: 1.5;
  overflow-x: hidden;
  padding: 24px;
}

/* Background glowing blobs */
.bg-blobs {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  z-index: -1;
  pointer-events: none;
  overflow: hidden;
}

.blob {
  position: absolute;
  border-radius: 50%;
  filter: blur(140px);
  opacity: 0.3;
  animation: float-blob 20s infinite ease-in-out alternate;
}

.blob-1 {
  top: -10%;
  right: 10%;
  width: 500px;
  height: 500px;
  background: radial-gradient(circle, var(--primary) 0%, rgba(255,255,255,0) 70%);
  animation-duration: 25s;
}

.blob-2 {
  bottom: -10%;
  left: 5%;
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, var(--accent) 0%, rgba(255,255,255,0) 70%);
  animation-duration: 30s;
}

@keyframes float-blob {
  0% { transform: translate(0, 0) scale(1); }
  100% { transform: translate(50px, 80px) scale(1.1); }
}

/* Scrollbar styling */
::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}

::-webkit-scrollbar-track {
  background: rgba(255, 255, 255, 0.3);
  border-radius: 10px;
}

::-webkit-scrollbar-thumb {
  background: rgba(0, 0, 0, 0.15);
  border-radius: 10px;
  border: 2px solid transparent;
}

::-webkit-scrollbar-thumb:hover {
  background: rgba(0, 0, 0, 0.25);
}

/* Glassmorphic Container Shell */
.app-container {
  max-width: 1600px;
  margin: 0 auto;
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  box-shadow: var(--glass-shadow);
  border-radius: 24px;
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  min-height: calc(100vh - 48px);
  display: flex;
  flex-direction: column;
  transition: var(--transition-smooth);
}

/* Header & Role Bar */
header {
  padding: 20px 30px;
  border-bottom: 1px solid var(--glass-border);
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 16px;
}

.brand-section {
  display: flex;
  align-items: center;
  gap: 12px;
}

.brand-icon {
  width: 44px;
  height: 44px;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  color: white;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 1.3rem;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
  letter-spacing: -0.5px;
}

.brand-title h1 {
  font-size: 1.35rem;
  font-weight: 700;
  color: var(--text-main);
  line-height: 1.2;
}

.brand-title p {
  font-size: 0.75rem;
  color: var(--text-muted);
  font-weight: 500;
}

/* Controls (Project, Role Switcher) */
.header-controls {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}

.select-wrapper {
  position: relative;
  display: flex;
  align-items: center;
}

.control-label {
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--text-muted);
  position: absolute;
  top: -8px;
  left: 12px;
  background: var(--glass-bg);
  padding: 0 4px;
  border-radius: 4px;
}

.styled-select {
  background: rgba(255, 255, 255, 0.8);
  border: 1px solid var(--glass-border);
  padding: 10px 16px;
  padding-top: 14px;
  padding-bottom: 8px;
  border-radius: var(--radius-md);
  font-family: inherit;
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--text-main);
  outline: none;
  cursor: pointer;
  box-shadow: inset 0 1px 2px rgba(0,0,0,0.02);
  transition: var(--transition-smooth);
  min-width: 180px;
}

.styled-select:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px var(--primary-glow);
}

/* Role Selector buttons */
.role-selector-pill {
  display: flex;
  background: rgba(0, 0, 0, 0.04);
  padding: 4px;
  border-radius: 14px;
  gap: 2px;
  border: 1px solid var(--glass-border);
}

.role-btn {
  border: none;
  background: transparent;
  padding: 8px 16px;
  border-radius: 10px;
  font-family: inherit;
  font-weight: 600;
  font-size: 0.85rem;
  color: var(--text-muted);
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 6px;
  transition: var(--transition-smooth);
}

.role-btn:hover {
  color: var(--text-main);
  background: rgba(255,255,255,0.4);
}

.role-btn.active {
  background: white;
  color: var(--primary);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

/* Tab Navigation Menu */
.tab-navigation {
  display: flex;
  border-bottom: 1px solid var(--glass-border);
  background: rgba(255, 255, 255, 0.3);
  padding: 0 24px;
  overflow-x: auto;
  gap: 8px;
}

.tab-btn {
  border: none;
  background: transparent;
  padding: 16px 20px;
  font-family: inherit;
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--text-muted);
  cursor: pointer;
  position: relative;
  transition: var(--transition-smooth);
  white-space: nowrap;
  display: flex;
  align-items: center;
  gap: 8px;
}

.tab-btn:hover {
  color: var(--text-main);
}

.tab-btn.active {
  color: var(--primary);
}

.tab-btn::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 20px;
  right: 20px;
  height: 3px;
  background: linear-gradient(90deg, var(--primary), var(--accent));
  border-radius: 3px 3px 0 0;
  transform: scaleX(0);
  transition: var(--transition-smooth);
}

.tab-btn.active::after {
  transform: scaleX(1);
}

.tab-btn .badge {
  background: var(--primary-glow);
  color: var(--primary);
  font-size: 0.75rem;
  padding: 2px 8px;
  border-radius: 20px;
  font-weight: 700;
}

/* Main Dashboard Area */
.main-content {
  padding: 24px;
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.tab-panel {
  display: none;
  flex-direction: column;
  gap: 24px;
  animation: fadeIn 0.4s ease forwards;
}

.tab-panel.active {
  display: flex;
}

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

/* Stat Cards Widget Row */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 20px;
}

.stat-card {
  background: rgba(255, 255, 255, 0.6);
  border: 1px solid var(--glass-border);
  box-shadow: var(--glass-shadow);
  border-radius: var(--radius-lg);
  padding: 20px;
  display: flex;
  align-items: center;
  gap: 16px;
  transition: var(--transition-smooth);
}

.stat-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--glass-shadow-hover);
  background: var(--glass-bg-hover);
}

.stat-icon {
  width: 50px;
  height: 50px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.4rem;
}

.stat-icon.total { background: hsla(220, 90%, 55%, 0.1); color: hsl(220, 90%, 55%); }
.stat-icon.review { background: hsla(35, 90%, 50%, 0.1); color: hsl(35, 90%, 50%); }
.stat-icon.approved { background: hsla(145, 75%, 45%, 0.1); color: hsl(145, 75%, 45%); }
.stat-icon.obsolete { background: hsla(0, 70%, 45%, 0.1); color: hsl(0, 70%, 45%); }

.stat-info .stat-val {
  font-size: 1.8rem;
  font-weight: 800;
  line-height: 1.1;
  color: var(--text-main);
}

.stat-info .stat-lbl {
  font-size: 0.8rem;
  color: var(--text-muted);
  font-weight: 500;
  margin-top: 4px;
}

/* Main Dashboard Panel Split: Filters + List */
.index-container {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 24px;
  align-items: start;
}

@media (max-width: 992px) {
  .index-container {
    grid-template-columns: 1fr;
  }
}

/* Left Filter Box */
.filter-card {
  background: rgba(255, 255, 255, 0.55);
  border: 1px solid var(--glass-border);
  box-shadow: var(--glass-shadow);
  border-radius: var(--radius-lg);
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.filter-title {
  font-size: 1rem;
  font-weight: 700;
  color: var(--text-main);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.clear-filter-btn {
  border: none;
  background: transparent;
  color: var(--primary);
  font-weight: 600;
  font-size: 0.8rem;
  cursor: pointer;
}

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

.filter-group label {
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--text-muted);
}

.filter-control {
  background: white;
  border: 1px solid var(--glass-border);
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  font-family: inherit;
  font-size: 0.85rem;
  color: var(--text-main);
  outline: none;
  width: 100%;
}

.filter-control:focus {
  border-color: var(--primary);
}

/* Tags Filter list */
.tags-filter-list {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  max-height: 100px;
  overflow-y: auto;
  padding-right: 4px;
}

.tag-filter-pill {
  font-size: 0.75rem;
  padding: 4px 8px;
  border-radius: 20px;
  background: rgba(0,0,0,0.04);
  color: var(--text-muted);
  cursor: pointer;
  border: 1px solid transparent;
  transition: var(--transition-smooth);
}

.tag-filter-pill:hover {
  background: rgba(0,0,0,0.08);
}

.tag-filter-pill.active {
  background: var(--primary-glow);
  color: var(--primary);
  border-color: hsla(var(--primary-hue), 85%, 55%, 0.3);
}

/* Right Master Index Registry */
.registry-card {
  background: rgba(255, 255, 255, 0.6);
  border: 1px solid var(--glass-border);
  box-shadow: var(--glass-shadow);
  border-radius: var(--radius-lg);
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.registry-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
}

.search-wrapper {
  position: relative;
  flex: 1;
  max-width: 400px;
  min-width: 250px;
}

.search-input {
  width: 100%;
  padding: 10px 16px;
  padding-left: 38px;
  border-radius: 20px;
  border: 1px solid var(--glass-border);
  outline: none;
  font-family: inherit;
  font-size: 0.9rem;
  background: white;
  transition: var(--transition-smooth);
}

.search-input:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px var(--primary-glow);
}

.search-icon {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-light);
  font-size: 0.95rem;
}

.action-buttons {
  display: flex;
  gap: 10px;
}

.btn {
  padding: 10px 18px;
  border-radius: var(--radius-md);
  border: 1px solid transparent;
  font-family: inherit;
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 8px;
  transition: var(--transition-smooth);
}

.btn-primary {
  background: linear-gradient(135deg, var(--primary), var(--primary-light));
  color: white;
  box-shadow: 0 4px 12px rgba(var(--primary-hue), 85%, 55%, 0.2);
}

.btn-primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 16px rgba(var(--primary-hue), 85%, 55%, 0.3);
}

.btn-secondary {
  background: rgba(255, 255, 255, 0.8);
  border: 1px solid var(--glass-border);
  color: var(--text-main);
  box-shadow: 0 2px 6px rgba(0,0,0,0.02);
}

.btn-secondary:hover {
  background: var(--glass-bg-hover);
}

/* Master Document Registry Table */
.table-container {
  overflow-x: auto;
  border-radius: var(--radius-md);
  border: 1px solid var(--glass-border);
  background: white;
}

.styled-table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
  font-size: 0.88rem;
}

.styled-table th {
  background: rgba(0, 0, 0, 0.02);
  color: var(--text-muted);
  font-weight: 600;
  padding: 14px 16px;
  border-bottom: 2px solid var(--glass-border);
  text-transform: uppercase;
  font-size: 0.75rem;
  letter-spacing: 0.5px;
}

.styled-table tr {
  border-bottom: 1px solid rgba(0,0,0,0.05);
  transition: var(--transition-smooth);
}

.styled-table tbody tr:hover {
  background: var(--primary-glow);
}

.styled-table td {
  padding: 14px 16px;
  vertical-align: middle;
  color: var(--text-main);
}

/* Specific cell columns */
.doc-id-cell {
  font-weight: 700;
  font-family: 'Outfit', sans-serif;
  color: var(--primary);
}

.doc-title-cell {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.doc-title-cell .doc-name {
  font-weight: 600;
  color: var(--text-main);
}

.doc-title-cell .doc-meta-sub {
  font-size: 0.75rem;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  gap: 8px;
}

.doc-type-badge {
  font-size: 0.7rem;
  font-weight: 700;
  padding: 3px 6px;
  border-radius: 4px;
  letter-spacing: 0.5px;
  display: inline-block;
}

.wbs-badge {
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--text-muted);
  background: rgba(0,0,0,0.05);
  padding: 2px 6px;
  border-radius: 4px;
}

.lifecycle-badge {
  font-size: 0.75rem;
  color: var(--text-muted);
}

/* Status Badges */
.status-badge {
  font-size: 0.75rem;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: 20px;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.status-badge::before {
  content: '';
  width: 6px;
  height: 6px;
  border-radius: 50%;
  display: inline-block;
}

.status-badge.draft {
  color: var(--status-draft-color);
  background: var(--status-draft-bg);
}
.status-badge.draft::before { background: var(--status-draft-color); }

.status-badge.under_review {
  color: var(--status-review-color);
  background: var(--status-review-bg);
}
.status-badge.under_review::before { background: var(--status-review-color); }

.status-badge.approved {
  color: var(--status-approved-color);
  background: var(--status-approved-bg);
}
.status-badge.approved::before { background: var(--status-approved-color); }

.status-badge.obsolete {
  color: var(--status-obsolete-color);
  background: var(--status-obsolete-bg);
}
.status-badge.obsolete::before { background: var(--status-obsolete-color); }

/* Quick Action Menu items */
.action-trigger {
  border: none;
  background: transparent;
  color: var(--text-light);
  cursor: pointer;
  font-size: 1.1rem;
  padding: 6px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition-smooth);
}

.action-trigger:hover {
  background: rgba(0,0,0,0.05);
  color: var(--text-main);
}

/* Manager Dashboard Specific Layout */
.manager-summary-grid {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 24px;
}

@media (max-width: 992px) {
  .manager-summary-grid {
    grid-template-columns: 1fr;
  }
}

.manager-card {
  background: rgba(255, 255, 255, 0.6);
  border: 1px solid var(--glass-border);
  box-shadow: var(--glass-shadow);
  border-radius: var(--radius-lg);
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.manager-title {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--text-main);
  border-bottom: 1px solid var(--glass-border);
  padding-bottom: 12px;
}

/* Department loads list */
.team-load-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.team-load-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 16px;
  background: white;
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-md);
  transition: var(--transition-smooth);
}

.team-load-item:hover {
  transform: translateX(4px);
  box-shadow: 0 4px 10px rgba(0,0,0,0.02);
}

.team-member-info {
  display: flex;
  align-items: center;
  gap: 12px;
}

.team-avatar {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid white;
  box-shadow: 0 2px 6px rgba(0,0,0,0.08);
}

.member-name-text {
  font-size: 0.88rem;
  font-weight: 600;
}

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

.member-task-stat {
  display: flex;
  align-items: center;
  gap: 8px;
}

.count-bubble {
  font-size: 0.75rem;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 12px;
}

.count-bubble.review { background: var(--status-review-bg); color: var(--status-review-color); }
.count-bubble.total { background: rgba(0,0,0,0.05); color: var(--text-muted); }

/* Manager Action Approval Cards */
.approval-queue {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.approval-item {
  background: white;
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-md);
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  transition: var(--transition-smooth);
}

.approval-item:hover {
  box-shadow: var(--card-shadow);
}

.approval-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
}

.approval-meta {
  display: flex;
  flex-direction: column;
}

.approval-title {
  font-weight: 600;
  font-size: 0.9rem;
}

.approval-sub {
  font-size: 0.75rem;
  color: var(--text-muted);
}

.approval-actions {
  display: flex;
  gap: 8px;
  align-self: flex-end;
}

/* Kanban Board Styling */
.kanban-filter-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  background: rgba(255, 255, 255, 0.4);
  border: 1px solid var(--glass-border);
  padding: 14px 20px;
  border-radius: var(--radius-md);
}

.kanban-columns-container {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
  align-items: start;
}

@media (max-width: 1200px) {
  .kanban-columns-container {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 768px) {
  .kanban-columns-container {
    grid-template-columns: 1fr;
  }
}

.kanban-column {
  background: rgba(255, 255, 255, 0.45);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-lg);
  padding: 16px;
  min-height: 500px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  box-shadow: var(--glass-shadow);
}

.kanban-column-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 2px solid transparent;
  padding-bottom: 8px;
}

.kanban-column-header.draft { border-color: var(--status-draft-color); }
.kanban-column-header.review { border-color: var(--status-review-color); }
.kanban-column-header.approved { border-color: var(--status-approved-color); }
.kanban-column-header.obsolete { border-color: var(--status-obsolete-color); }

.kanban-column-title {
  font-weight: 700;
  font-size: 0.95rem;
  color: var(--text-main);
  display: flex;
  align-items: center;
  gap: 8px;
}

.kanban-column-count {
  font-size: 0.75rem;
  font-weight: 700;
  background: rgba(0,0,0,0.06);
  padding: 2px 8px;
  border-radius: 10px;
  color: var(--text-muted);
}

.kanban-cards-wrapper {
  display: flex;
  flex-direction: column;
  gap: 12px;
  flex: 1;
  min-height: 400px;
}

/* Kanban Cards Details */
.kanban-card {
  background: white;
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-md);
  padding: 16px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.02);
  display: flex;
  flex-direction: column;
  gap: 12px;
  cursor: grab;
  transition: var(--transition-smooth);
}

.kanban-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(31, 38, 135, 0.08);
}

.kanban-card:active {
  cursor: grabbing;
}

.kanban-card-id {
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--primary);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.kanban-card-title {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-main);
  line-height: 1.4;
}

.kanban-card-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
}

.kanban-tag {
  font-size: 0.68rem;
  background: rgba(0, 0, 0, 0.03);
  color: var(--text-muted);
  padding: 2px 6px;
  border-radius: 4px;
}

.kanban-card-footer {
  border-top: 1px solid rgba(0,0,0,0.04);
  padding-top: 10px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.75rem;
  color: var(--text-muted);
}

.kanban-card-owner {
  display: flex;
  align-items: center;
  gap: 6px;
  font-weight: 500;
}

.kanban-card-actions {
  display: flex;
  gap: 6px;
}

.card-action-btn {
  background: rgba(0,0,0,0.03);
  border: none;
  cursor: pointer;
  padding: 4px;
  border-radius: 4px;
  color: var(--text-muted);
  font-size: 0.85rem;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition-smooth);
}

.card-action-btn:hover {
  background: var(--primary-glow);
  color: var(--primary);
}

/* Modals styling (Glassmorphism Modal Overlays) */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(255, 255, 255, 0.4);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  z-index: 1000;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 20px;
  animation: fadeIn 0.2s ease forwards;
}

.modal-overlay.active {
  display: flex;
}

.modal-content {
  background: rgba(255, 255, 255, 0.9);
  border: 1px solid var(--glass-border);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.15);
  border-radius: 20px;
  width: 100%;
  max-width: 680px;
  max-height: 90vh;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  animation: scaleIn 0.3s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
}

@keyframes scaleIn {
  from { transform: scale(0.9); opacity: 0; }
  to { transform: scale(1); opacity: 1; }
}

.modal-header {
  padding: 20px 24px;
  border-bottom: 1px solid var(--glass-border);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.modal-title {
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--text-main);
}

.modal-close {
  background: transparent;
  border: none;
  font-size: 1.5rem;
  color: var(--text-light);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  transition: var(--transition-smooth);
}

.modal-close:hover {
  background: rgba(0,0,0,0.05);
  color: var(--text-main);
}

.modal-body {
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.modal-footer {
  padding: 16px 24px;
  border-top: 1px solid var(--glass-border);
  display: flex;
  justify-content: flex-end;
  gap: 12px;
  background: rgba(0,0,0,0.01);
}

/* Document Smart Naming Wizard layout inside modals or panels */
.naming-wizard-panel {
  background: var(--status-draft-bg);
  border: 1px dashed hsla(var(--primary-hue), 85%, 55%, 0.3);
  border-radius: var(--radius-md);
  padding: 16px;
  margin-bottom: 10px;
}

.wizard-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
  margin-top: 10px;
}

.generated-name-box {
  background: white;
  border: 1px solid var(--glass-border);
  padding: 12px;
  border-radius: var(--radius-sm);
  font-family: 'Outfit', sans-serif;
  font-weight: 700;
  font-size: 1rem;
  text-align: center;
  color: var(--primary);
  letter-spacing: 0.5px;
  box-shadow: inset 0 2px 4px rgba(0,0,0,0.02);
}

/* Document Preview Details tab details style */
.detail-grid {
  display: grid;
  grid-template-columns: 2fr 1.2fr;
  gap: 20px;
}

@media (max-width: 768px) {
  .detail-grid {
    grid-template-columns: 1fr;
  }
}

.meta-info-card {
  background: white;
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-md);
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.meta-row {
  display: flex;
  justify-content: space-between;
  border-bottom: 1px solid rgba(0,0,0,0.04);
  padding-bottom: 8px;
  font-size: 0.85rem;
}

.meta-row-label {
  color: var(--text-muted);
  font-weight: 500;
}

.meta-row-value {
  font-weight: 600;
  text-align: right;
}

/* Diff View Engine visual comparison classes */
.diff-container {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.diff-version-select {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.85rem;
}

.diff-pane {
  background: hsl(220, 10%, 97%);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-md);
  padding: 16px;
  font-family: 'Consolas', 'Courier New', Courier, monospace;
  font-size: 0.8rem;
  max-height: 250px;
  overflow-y: auto;
  line-height: 1.6;
}

.diff-line {
  display: flex;
  padding: 2px 8px;
  border-radius: 2px;
}

.diff-line.added {
  background-color: hsl(140, 60%, 90%);
  color: hsl(140, 70%, 25%);
}

.diff-line.deleted {
  background-color: hsl(0, 70%, 92%);
  color: hsl(0, 80%, 30%);
}

.diff-line.normal {
  color: var(--text-muted);
}

.diff-line-number {
  min-width: 24px;
  user-select: none;
  opacity: 0.5;
  margin-right: 12px;
}

/* Audit Logs visual component in preview modal */
.audit-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
  max-height: 300px;
  overflow-y: auto;
  padding-right: 6px;
}

.audit-item {
  border-left: 2px solid var(--primary-light);
  padding-left: 14px;
  position: relative;
  font-size: 0.8rem;
}

.audit-item::before {
  content: '';
  position: absolute;
  left: -5px;
  top: 4px;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--primary);
}

.audit-date {
  font-size: 0.72rem;
  color: var(--text-light);
  font-weight: 500;
}

.audit-actor {
  font-weight: 700;
  color: var(--text-main);
}

.audit-action-name {
  font-weight: 600;
  color: var(--primary);
}

.audit-hash-code {
  font-family: monospace;
  background: rgba(0,0,0,0.04);
  padding: 1px 4px;
  border-radius: 3px;
  font-size: 0.7rem;
  color: var(--text-muted);
}

/* Infrastructure Simulation styling */
.infra-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
}

@media (max-width: 768px) {
  .infra-grid {
    grid-template-columns: 1fr;
  }
}

.disk-meter-container {
  display: flex;
  flex-direction: column;
  gap: 8px;
  background: white;
  border: 1px solid var(--glass-border);
  padding: 16px;
  border-radius: var(--radius-md);
}

.disk-bar {
  height: 20px;
  background: #f0f0f0;
  border-radius: 10px;
  overflow: hidden;
  position: relative;
}

.disk-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--primary), var(--accent));
  border-radius: 10px;
  width: 32%;
  transition: var(--transition-smooth);
}

.sync-feed {
  background: #1e1e24;
  color: #39ff14;
  font-family: 'Consolas', monospace;
  font-size: 0.75rem;
  padding: 16px;
  border-radius: var(--radius-md);
  max-height: 200px;
  overflow-y: auto;
  line-height: 1.5;
  box-shadow: inset 0 2px 8px rgba(0,0,0,0.5);
}

/* Digital Signature Box simulation */
.signature-box-container {
  border: 1px dashed var(--glass-border-focus);
  background: white;
  border-radius: var(--radius-md);
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.signature-canvas-mock {
  height: 100px;
  background: hsl(210, 20%, 98%);
  border: 1px solid #ddd;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: 'Sinyature', 'Outfit', cursive, sans-serif;
  font-size: 2rem;
  color: var(--primary);
  font-style: italic;
  font-weight: 500;
  user-select: none;
}

/* Form layout elements */
.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

@media (max-width: 576px) {
  .form-grid {
    grid-template-columns: 1fr;
  }
}

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

.form-field.full-width {
  grid-column: 1 / -1;
}

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

.form-input {
  background: white;
  border: 1px solid var(--glass-border);
  padding: 10px 14px;
  border-radius: var(--radius-md);
  font-family: inherit;
  font-size: 0.9rem;
  outline: none;
  transition: var(--transition-smooth);
}

.form-input:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px var(--primary-glow);
}

.tags-input-container {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  border: 1px solid var(--glass-border);
  background: white;
  padding: 6px 12px;
  border-radius: var(--radius-md);
}

.tags-input-pill {
  font-size: 0.75rem;
  background: var(--primary-glow);
  color: var(--primary);
  padding: 2px 8px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  gap: 4px;
}

.tags-input-pill .remove-pill {
  cursor: pointer;
  font-size: 0.9rem;
  font-weight: 700;
}

.tag-adder-input {
  border: none;
  outline: none;
  font-family: inherit;
  font-size: 0.85rem;
  flex: 1;
  min-width: 80px;
  padding: 4px 0;
}

/* Toast alert messages */
.toast-container {
  position: fixed;
  bottom: 24px;
  right: 24px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  z-index: 2000;
}

.toast {
  background: white;
  border: 1px solid var(--glass-border);
  box-shadow: 0 10px 30px rgba(0,0,0,0.08);
  border-radius: var(--radius-md);
  padding: 16px 20px;
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 0.88rem;
  font-weight: 500;
  border-left: 4px solid var(--primary);
  min-width: 280px;
  animation: slideInRight 0.3s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
}

.toast.success { border-left-color: var(--status-approved-color); }
.toast.info { border-left-color: var(--primary); }
.toast.warning { border-left-color: var(--status-review-color); }
.toast.error { border-left-color: var(--status-obsolete-color); }

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

.toast.fade-out {
  animation: fadeOut 0.4s ease forwards;
}

@keyframes fadeOut {
  to { opacity: 0; transform: translateY(10px) scale(0.95); }
}

/* Utilities */
.text-center { text-align: center; }
.mt-4 { margin-top: 16px; }
.mr-2 { margin-right: 8px; }
.flex-row-center { display: flex; align-items: center; gap: 8px; }
.pointer-events-none { pointer-events: none; }

/* ═══════════════════════════════════════════════
   DASHBOARD BODY GRID
   ═══════════════════════════════════════════════ */
.dashboard-body-grid {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 24px;
  align-items: start;
}

.dashboard-left,
.dashboard-right {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

@media (max-width: 992px) {
  .dashboard-body-grid { grid-template-columns: 1fr; }
}

/* ═══════════════════════════════════════════════
   PROJECT PROGRESS
   ═══════════════════════════════════════════════ */
.project-progress-item {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 14px 0;
  border-bottom: 1px solid var(--glass-border);
}

.project-progress-item:last-child { border-bottom: none; }

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

.project-name-text {
  font-weight: 600;
  font-size: 0.88rem;
  color: var(--text-main);
}

.project-progress-pct {
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--status-approved-color);
}

.progress-track {
  height: 8px;
  background: rgba(0,0,0,0.06);
  border-radius: 10px;
  overflow: hidden;
}

.progress-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--primary), var(--accent));
  border-radius: 10px;
  transition: width 0.8s cubic-bezier(0.25, 0.8, 0.25, 1);
}

.project-progress-sub {
  font-size: 0.75rem;
  color: var(--text-muted);
}

/* ═══════════════════════════════════════════════
   DOC TYPE CHART
   ═══════════════════════════════════════════════ */
.doc-type-chart-wrap {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 4px 0;
}

.doc-type-bar-row {
  display: flex;
  align-items: center;
  gap: 10px;
}

.type-bar-track {
  flex: 1;
  height: 10px;
  background: rgba(0,0,0,0.05);
  border-radius: 8px;
  overflow: hidden;
}

.type-bar-fill {
  height: 100%;
  border-radius: 8px;
  min-width: 4px;
  transition: width 0.6s ease;
  opacity: 0.85;
}

/* ═══════════════════════════════════════════════
   ACTIVITY FEED
   ═══════════════════════════════════════════════ */
.activity-feed {
  display: flex;
  flex-direction: column;
  gap: 2px;
  max-height: 400px;
  overflow-y: auto;
  padding-right: 4px;
}

.activity-item {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  transition: var(--transition-smooth);
}

.activity-item:hover {
  background: var(--primary-glow);
  transform: translateX(2px);
}

.activity-icon {
  font-size: 1rem;
  flex-shrink: 0;
  margin-top: 2px;
}

.activity-body {
  flex: 1;
}

.activity-action {
  font-size: 0.83rem;
  font-weight: 600;
  color: var(--text-main);
  line-height: 1.3;
}

.activity-meta {
  font-size: 0.72rem;
  color: var(--text-muted);
  margin-top: 2px;
}

/* ═══════════════════════════════════════════════
   ROLE PILLS
   ═══════════════════════════════════════════════ */
.role-pill {
  font-size: 0.78rem;
  font-weight: 700;
  padding: 6px 12px;
  border-radius: 20px;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.role-pill.role-controller {
  background: hsla(var(--accent-hue), 80%, 50%, 0.12);
  color: hsl(var(--accent-hue), 80%, 40%);
  border: 1px solid hsla(var(--accent-hue), 80%, 50%, 0.25);
}

.role-pill.role-manager {
  background: hsla(220, 90%, 55%, 0.1);
  color: hsl(220, 90%, 45%);
  border: 1px solid hsla(220, 90%, 55%, 0.2);
}

.role-pill.role-member {
  background: rgba(0,0,0,0.04);
  color: var(--text-muted);
  border: 1px solid rgba(0,0,0,0.08);
}

/* ═══════════════════════════════════════════════
   SMART NAMING WIZARD CHIPS
   ═══════════════════════════════════════════════ */
.wizard-chip {
  background: rgba(255,255,255,0.8);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-sm);
  padding: 8px 4px;
  text-align: center;
  font-weight: 700;
  font-size: 0.78rem;
  color: var(--primary);
  font-family: 'Outfit', monospace;
  letter-spacing: 0.5px;
}

/* ═══════════════════════════════════════════════
   MODAL SUB-TABS
   ═══════════════════════════════════════════════ */
.modal-sub-tabs {
  display: flex;
  border-bottom: 1px solid var(--glass-border);
  background: rgba(0,0,0,0.01);
  padding: 0 20px;
  gap: 4px;
  overflow-x: auto;
}

.modal-sub-tab {
  border: none;
  background: transparent;
  padding: 12px 16px;
  font-family: inherit;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-muted);
  cursor: pointer;
  position: relative;
  white-space: nowrap;
  transition: var(--transition-smooth);
}

.modal-sub-tab:hover { color: var(--text-main); }

.modal-sub-tab.active {
  color: var(--primary);
}

.modal-sub-tab.active::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 16px;
  right: 16px;
  height: 2px;
  background: linear-gradient(90deg, var(--primary), var(--accent));
  border-radius: 2px 2px 0 0;
}

.modal-subtab-panel { display: none; }
.modal-subtab-panel.active { display: block; animation: fadeIn 0.25s ease forwards; }

.modal-content-wide { max-width: 860px; }

/* ═══════════════════════════════════════════════
   VERSION LIST
   ═══════════════════════════════════════════════ */
.version-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.version-row {
  display: grid;
  grid-template-columns: 140px 1fr auto;
  gap: 16px;
  align-items: start;
  padding: 14px 16px;
  background: white;
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-md);
  transition: var(--transition-smooth);
}

.version-row:hover {
  box-shadow: var(--card-shadow);
}

.version-row.current-version {
  border-color: hsla(var(--primary-hue), 85%, 55%, 0.3);
  background: var(--primary-glow);
}

.version-badge-wrap {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.version-tag {
  font-size: 0.78rem;
  font-weight: 700;
  padding: 4px 8px;
  border-radius: 6px;
  background: rgba(0,0,0,0.05);
  color: var(--text-muted);
  font-family: monospace;
  display: inline-block;
}

.version-tag.active-ver {
  background: var(--primary-glow);
  color: var(--primary);
}

.version-details {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

/* ═══════════════════════════════════════════════
   WORKFLOW STEPS
   ═══════════════════════════════════════════════ */
.wf-track {
  display: flex;
  align-items: center;
  gap: 0;
  padding: 20px 0;
}

.wf-step {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  flex: 1;
}

.wf-dot {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.9rem;
  border: 2px solid var(--glass-border);
  background: white;
  transition: var(--transition-smooth);
}

.wf-step.wf-done .wf-dot {
  background: var(--status-approved-bg);
  border-color: var(--status-approved-color);
  color: var(--status-approved-color);
}

.wf-step.wf-active .wf-dot {
  background: linear-gradient(135deg, var(--primary), var(--accent));
  border-color: transparent;
  color: white;
  box-shadow: 0 4px 14px rgba(0,0,0,0.15);
  transform: scale(1.1);
}

.wf-step.wf-pending .wf-dot {
  background: rgba(0,0,0,0.03);
  color: var(--text-light);
}

.wf-label {
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--text-muted);
  text-align: center;
}

.wf-step.wf-active .wf-label { color: var(--primary); }
.wf-step.wf-done .wf-label { color: var(--status-approved-color); }

.wf-connector {
  flex: 1;
  height: 2px;
  background: var(--glass-border);
  margin-bottom: 28px;
  max-width: 80px;
}

.wf-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 24px;
}

.wf-locked-box {
  background: rgba(0,0,0,0.03);
  border: 1px dashed var(--glass-border);
  border-radius: var(--radius-md);
  padding: 16px;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-muted);
  text-align: center;
  line-height: 1.7;
  margin-top: 12px;
  width: 100%;
}

/* ═══════════════════════════════════════════════
   KANBAN EXTRAS
   ═══════════════════════════════════════════════ */
.kanban-empty-hint {
  text-align: center;
  padding: 40px 20px;
  color: var(--text-light);
  font-size: 0.82rem;
  border: 2px dashed rgba(0,0,0,0.06);
  border-radius: var(--radius-md);
}

.kanban-cards-wrapper.drag-over {
  background: var(--primary-glow);
  border-radius: var(--radius-md);
  border: 2px dashed var(--primary);
}

.kanban-card.dragging {
  opacity: 0.5;
  transform: scale(0.97) rotate(1deg);
  box-shadow: 0 20px 40px rgba(0,0,0,0.15);
}

.status-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  display: inline-block;
  flex-shrink: 0;
}
.status-dot.draft { background: var(--status-draft-color); }
.status-dot.review { background: var(--status-review-color); }
.status-dot.approved { background: var(--status-approved-color); }
.status-dot.obsolete { background: var(--status-obsolete-color); }

/* ═══════════════════════════════════════════════
   WBS HEATMAP
   ═══════════════════════════════════════════════ */
.wbs-heatmap {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.wbs-heat-row {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 0.8rem;
}

.wbs-heat-label {
  min-width: 80px;
  font-weight: 700;
  color: var(--text-main);
  font-size: 0.78rem;
}

.wbs-heat-bars {
  flex: 1;
  display: flex;
  height: 22px;
  border-radius: 6px;
  overflow: hidden;
  gap: 1px;
}

.wbs-heat-bar {
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.68rem;
  font-weight: 700;
  color: white;
  min-width: 22px;
  transition: var(--transition-smooth);
  cursor: default;
}

.wbs-heat-bar.draft { background: var(--status-draft-color); }
.wbs-heat-bar.review { background: var(--status-review-color); }
.wbs-heat-bar.approved { background: var(--status-approved-color); }
.wbs-heat-bar.obsolete { background: var(--status-obsolete-color); }

.wbs-heat-total {
  min-width: 24px;
  text-align: right;
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--text-muted);
}

/* ═══════════════════════════════════════════════
   INTEGRATION LIST
   ═══════════════════════════════════════════════ */
.integration-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.integration-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  background: white;
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-md);
  transition: var(--transition-smooth);
}

.integration-item:hover {
  box-shadow: var(--card-shadow);
  transform: translateX(2px);
}

/* ═══════════════════════════════════════════════
   SECURITY PANEL
   ═══════════════════════════════════════════════ */
.security-panel {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

/* ═══════════════════════════════════════════════
   INFRASTRUCTURE EXTRA
   ═══════════════════════════════════════════════ */
.backup-stat-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 0;
  border-bottom: 1px solid var(--glass-border);
  font-size: 0.85rem;
}

.backup-stat-row:last-child { border-bottom: none; }

/* ═══════════════════════════════════════════════
   UPLOAD DROP ZONE
   ═══════════════════════════════════════════════ */
.upload-drop-zone {
  border: 2px dashed var(--glass-border);
  border-radius: var(--radius-md);
  padding: 28px;
  text-align: center;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  transition: var(--transition-smooth);
  background: rgba(0,0,0,0.01);
  font-size: 0.88rem;
  color: var(--text-muted);
}

.upload-drop-zone:hover,
.upload-drop-zone.drop-active {
  border-color: var(--primary);
  background: var(--primary-glow);
  color: var(--primary);
}

/* ═══════════════════════════════════════════════
   REGISTRY RESULT INFO
   ═══════════════════════════════════════════════ */
.registry-result-info {
  font-size: 0.8rem;
  color: var(--text-muted);
  font-weight: 500;
  padding: 4px 0;
}

/* ═══════════════════════════════════════════════
   REFERENCE PILL
   ═══════════════════════════════════════════════ */
.ref-pill {
  font-size: 0.75rem;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: 6px;
  background: var(--primary-glow);
  color: var(--primary);
  border: 1px solid hsla(var(--primary-hue), 85%, 55%, 0.2);
  font-family: monospace;
  transition: var(--transition-smooth);
}

.ref-pill:hover {
  background: var(--primary);
  color: white;
}

/* ═══════════════════════════════════════════════
   USER LOGIN & MANAGEMENT STYLES
   ═══════════════════════════════════════════════ */
.login-screen {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  padding: 20px;
}

.login-card {
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  box-shadow: var(--glass-shadow);
  border-radius: 24px;
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  width: 100%;
  max-width: 540px;
  padding: 40px;
  display: flex;
  flex-direction: column;
  gap: 24px;
  animation: scaleIn 0.4s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
}

.login-header {
  text-align: center;
}

.login-header h2 {
  font-size: 1.6rem;
  font-weight: 800;
  margin-top: 12px;
  color: var(--text-main);
}

.login-header p {
  font-size: 0.85rem;
  color: var(--text-muted);
}

.quick-user-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
}

@media (max-width: 480px) {
  .quick-user-grid {
    grid-template-columns: 1fr;
  }
}

.quick-user-btn {
  background: white;
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-md);
  padding: 12px;
  display: flex;
  align-items: center;
  gap: 12px;
  cursor: pointer;
  text-align: left;
  transition: var(--transition-bounce);
}

.quick-user-btn:hover {
  transform: scale(1.03);
  border-color: var(--primary);
  box-shadow: 0 8px 20px rgba(var(--primary-hue), 85%, 55%, 0.08);
}

.quick-user-btn img {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  object-fit: cover;
}

.quick-user-details {
  display: flex;
  flex-direction: column;
}

.quick-user-name {
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--text-main);
}

.quick-user-role {
  font-size: 0.7rem;
  color: var(--text-muted);
  font-weight: 600;
}

.login-divider {
  display: flex;
  align-items: center;
  text-align: center;
  color: var(--text-light);
  font-size: 0.75rem;
  font-weight: 600;
  margin: 10px 0;
}

.login-divider::before, .login-divider::after {
  content: '';
  flex: 1;
  border-bottom: 1px solid rgba(0,0,0,0.06);
}

.login-divider:not(:empty)::before { margin-right: .5em; }
.login-divider:not(:empty)::after { margin-left: .5em; }

.header-user-profile {
  display: flex;
  align-items: center;
  gap: 12px;
  background: rgba(255, 255, 255, 0.6);
  padding: 6px 12px;
  border-radius: 20px;
  border: 1px solid var(--glass-border);
}

.header-user-avatar {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  object-fit: cover;
}

.header-user-meta {
  display: flex;
  flex-direction: column;
}

.header-user-name {
  font-size: 0.8rem;
  font-weight: 700;
}

.header-user-role-badge {
  font-size: 0.65rem;
  font-weight: 800;
  text-transform: uppercase;
  color: var(--primary);
  letter-spacing: 0.3px;
}

.logout-btn {
  background: transparent;
  border: none;
  color: var(--status-obsolete-color);
  cursor: pointer;
  font-size: 0.85rem;
  font-weight: 700;
  padding: 6px 10px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  gap: 4px;
  transition: var(--transition-smooth);
}

.logout-btn:hover {
  background: var(--status-obsolete-bg);
}

/* User Management grid */
.user-mgmt-grid {
  display: grid;
  grid-template-columns: 1.2fr 2fr;
  gap: 24px;
}

@media (max-width: 992px) {
  .user-mgmt-grid {
    grid-template-columns: 1fr;
  }
}


