/* ============================================
   UZAIR MASOOD — PROJECTS SYSTEM CSS
   Royal Blue + Dark Cybersecurity Aesthetic
   ============================================ */

/* ---- PROJECT PAGE HERO ---- */
.proj-hero {
  padding: 160px 32px 80px;
  position: relative;
  overflow: hidden;
}

.proj-hero-inner {
  max-width: 1240px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
  align-items: center;
}

@media (max-width: 920px) {
  .proj-hero-inner { grid-template-columns: 1fr; gap: 32px; }
  .proj-hero { padding: 120px 20px 60px; }
}

.proj-hero-tag {
  font-family: 'JetBrains Mono', monospace;
  font-size: 11px;
  color: #5e8aff;
  letter-spacing: 3px;
  text-transform: uppercase;
  margin-bottom: 20px;
  display: flex;
  align-items: center;
  gap: 12px;
}

.proj-hero-tag::before {
  content: '';
  width: 32px; height: 1px;
  background: #3a6dff;
}

.proj-hero h1 {
  font-family: 'Chakra Petch', sans-serif;
  font-size: clamp(40px, 6vw, 80px);
  font-weight: 700;
  color: #f1f5fb;
  letter-spacing: -2px;
  line-height: 0.95;
  margin-bottom: 24px;
}

.proj-hero h1 em {
  font-style: normal;
  background: linear-gradient(135deg, #5e8aff, #5ec8ff);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.proj-hero-desc {
  font-size: 15px;
  color: #6c7d99;
  line-height: 1.8;
  margin-bottom: 32px;
  max-width: 480px;
}

.proj-hero-stats {
  display: flex;
  gap: 32px;
  flex-wrap: wrap;
}

.proj-hero-stat {
  text-align: center;
}

.proj-hero-stat-num {
  font-family: 'Chakra Petch', sans-serif;
  font-size: 32px;
  font-weight: 700;
  color: #5e8aff;
  letter-spacing: -1px;
}

.proj-hero-stat-label {
  font-family: 'JetBrains Mono', monospace;
  font-size: 10px;
  color: #455067;
  letter-spacing: 2px;
  text-transform: uppercase;
  margin-top: 4px;
}

/* Hero terminal mockup */
.proj-hero-terminal {
  background: #080b14;
  border: 1px solid rgba(70,110,220,0.3);
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 24px 64px rgba(0,0,0,0.6), 0 0 40px rgba(58,109,255,0.08);
}

.terminal-bar {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 12px 16px;
  background: #0f1626;
  border-bottom: 1px solid rgba(70,110,220,0.2);
}

.terminal-dot {
  width: 10px; height: 10px;
  border-radius: 50%;
}

.terminal-dot.red { background: #ff4d6d; }
.terminal-dot.amber { background: #ffa940; }
.terminal-dot.green { background: #2ecf83; }

.terminal-title {
  font-family: 'JetBrains Mono', monospace;
  font-size: 11px;
  color: #455067;
  letter-spacing: 1px;
  margin-left: 8px;
}

.terminal-body {
  padding: 20px;
  min-height: 200px;
  font-family: 'JetBrains Mono', monospace;
  font-size: 12px;
  line-height: 2;
}

.t-line {
  display: flex;
  gap: 10px;
  opacity: 0;
  animation: t-fade-in 0.3s forwards;
}

.t-line.l1 { animation-delay: 0.2s; }
.t-line.l2 { animation-delay: 0.7s; }
.t-line.l3 { animation-delay: 1.2s; }
.t-line.l4 { animation-delay: 1.7s; }
.t-line.l5 { animation-delay: 2.2s; }
.t-line.l6 { animation-delay: 2.7s; }

@keyframes t-fade-in {
  from { opacity: 0; transform: translateY(4px); }
  to { opacity: 1; transform: translateY(0); }
}

.t-prompt { color: #3a6dff; }
.t-cmd { color: #f1f5fb; }
.t-out { color: #5ec8ff; }
.t-ok { color: #2ecf83; }
.t-warn { color: #ffa940; }
.t-dim { color: #455067; }

/* ---- FILTERS ---- */
.proj-filters {
  max-width: 1240px;
  margin: 0 auto 48px;
  padding: 0 32px;
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  align-items: center;
}

@media (max-width: 768px) { .proj-filters { padding: 0 20px; } }

.filter-label {
  font-family: 'JetBrains Mono', monospace;
  font-size: 11px;
  color: #455067;
  letter-spacing: 2px;
  margin-right: 8px;
  text-transform: uppercase;
}

.filter-btn {
  font-family: 'JetBrains Mono', monospace;
  font-size: 11px;
  padding: 8px 18px;
  border: 1px solid rgba(70,110,220,0.25);
  background: transparent;
  color: #6c7d99;
  border-radius: 100px;
  letter-spacing: 1px;
  cursor: none;
  transition: all 0.2s;
  text-transform: uppercase;
}

.filter-btn:hover {
  border-color: #3a6dff;
  color: #5e8aff;
  background: rgba(58,109,255,0.06);
}

.filter-btn.active {
  border-color: #3a6dff;
  background: rgba(58,109,255,0.12);
  color: #5e8aff;
}

/* ---- CATEGORY HEADERS ---- */
.proj-category {
  max-width: 1240px;
  margin: 0 auto;
  padding: 0 32px;
}

@media (max-width: 768px) { .proj-category { padding: 0 20px; } }

.proj-cat-head {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 32px;
  padding-bottom: 16px;
  border-bottom: 1px solid rgba(70,110,220,0.15);
}

.proj-cat-icon {
  width: 40px; height: 40px;
  background: rgba(58,109,255,0.1);
  border: 1px solid rgba(58,109,255,0.3);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #5e8aff;
  flex-shrink: 0;
}

.proj-cat-icon svg { width: 20px; height: 20px; }

.proj-cat-name {
  font-family: 'Chakra Petch', sans-serif;
  font-size: 22px;
  font-weight: 600;
  color: #f1f5fb;
  letter-spacing: -0.3px;
}

.proj-cat-count {
  font-family: 'JetBrains Mono', monospace;
  font-size: 11px;
  color: #3a6dff;
  background: rgba(58,109,255,0.1);
  border: 1px solid rgba(58,109,255,0.2);
  padding: 3px 10px;
  border-radius: 100px;
  letter-spacing: 1px;
  margin-left: auto;
}

.proj-section-gap { margin-bottom: 80px; }

/* ---- PROJECT CARDS GRID ---- */
.proj-cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(360px, 1fr));
  gap: 20px;
  margin-bottom: 20px;
}

@media (max-width: 800px) { .proj-cards-grid { grid-template-columns: 1fr; } }

/* ---- PROJECT CARD ---- */
.proj-card {
  background: linear-gradient(135deg, #0f1626, #0a0f1c);
  border: 1px solid rgba(70,110,220,0.2);
  position: relative;
  overflow: hidden;
  transition: border-color 0.3s, transform 0.3s, box-shadow 0.3s;
  cursor: none;
  display: flex;
  flex-direction: column;
}

.proj-card:hover {
  border-color: rgba(58,109,255,0.6);
  transform: translateY(-6px);
  box-shadow: 0 20px 48px rgba(0,0,0,0.5), 0 0 32px rgba(58,109,255,0.12);
}

/* Scan line animation on hover */
.proj-card::after {
  content: '';
  position: absolute;
  top: -100%;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, transparent, #3a6dff, transparent);
  opacity: 0;
  transition: opacity 0.3s;
}

.proj-card:hover::after {
  opacity: 1;
  animation: scan-line 2s linear infinite;
}

@keyframes scan-line {
  0% { top: -2px; }
  100% { top: 100%; }
}

/* Category accent bar */
.proj-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0;
  width: 3px; height: 100%;
  background: var(--card-accent, linear-gradient(180deg, #3a6dff, #1e4dd8));
  transition: width 0.3s;
}

.proj-card:hover::before { width: 4px; }

/* Category color variants */
.proj-card[data-cat="cyber"] { --card-accent: linear-gradient(180deg, #3a6dff, #5ec8ff); }
.proj-card[data-cat="software"] { --card-accent: linear-gradient(180deg, #2ecf83, #3a6dff); }
.proj-card[data-cat="professional"] { --card-accent: linear-gradient(180deg, #ffa940, #3a6dff); }
.proj-card[data-cat="community"] { --card-accent: linear-gradient(180deg, #ff4d6d, #3a6dff); }

/* ---- CARD ANIMATION PANEL ---- */
.card-anim {
  height: 160px;
  position: relative;
  overflow: hidden;
  background: #080b14;
  border-bottom: 1px solid rgba(70,110,220,0.15);
  flex-shrink: 0;
}

/* FORENSICS animation */
.anim-forensics {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 20px;
  gap: 8px;
}

.forensic-hash {
  font-family: 'JetBrains Mono', monospace;
  font-size: 10px;
  color: #3a6dff;
  letter-spacing: 1px;
  animation: hash-appear 3s infinite;
}

.forensic-hash:nth-child(2) { animation-delay: 0.5s; color: #5e8aff; }
.forensic-hash:nth-child(3) { animation-delay: 1s; color: #5ec8ff; }

@keyframes hash-appear {
  0%, 100% { opacity: 0.3; }
  50% { opacity: 1; }
}

.forensic-disk {
  position: absolute;
  right: 20px;
  top: 50%;
  transform: translateY(-50%);
  width: 80px; height: 80px;
  border: 2px solid rgba(58,109,255,0.4);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.forensic-disk::before {
  content: '';
  position: absolute;
  width: 24px; height: 24px;
  background: rgba(58,109,255,0.2);
  border: 2px solid #3a6dff;
  border-radius: 50%;
}

.forensic-disk-ring {
  position: absolute;
  inset: -8px;
  border: 1px dashed rgba(58,109,255,0.3);
  border-radius: 50%;
  animation: spin 8s linear infinite;
}

.forensic-scan-line {
  position: absolute;
  left: 0; right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, #3a6dff, transparent);
  animation: forensic-scan 2.5s ease-in-out infinite;
}

@keyframes forensic-scan {
  0% { top: 0; opacity: 0; }
  10% { opacity: 1; }
  90% { opacity: 1; }
  100% { top: 100%; opacity: 0; }
}

/* SOC MONITORING animation */
.anim-soc {
  padding: 16px;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
}

.soc-alert-card {
  background: rgba(58,109,255,0.05);
  border: 1px solid rgba(58,109,255,0.2);
  padding: 8px;
  border-radius: 4px;
  animation: soc-pulse 3s infinite;
}

.soc-alert-card:nth-child(2) { animation-delay: 0.5s; }
.soc-alert-card:nth-child(3) { animation-delay: 1s; }
.soc-alert-card:nth-child(4) { animation-delay: 1.5s; }
.soc-alert-card:nth-child(5) { animation-delay: 2s; }
.soc-alert-card:nth-child(6) { animation-delay: 2.5s; }

@keyframes soc-pulse {
  0%, 100% { border-color: rgba(58,109,255,0.2); background: rgba(58,109,255,0.05); }
  50% { border-color: rgba(58,109,255,0.6); background: rgba(58,109,255,0.12); }
}

.soc-severity {
  font-family: 'JetBrains Mono', monospace;
  font-size: 8px;
  letter-spacing: 1px;
  margin-bottom: 4px;
}

.soc-severity.high { color: #ff4d6d; }
.soc-severity.med { color: #ffa940; }
.soc-severity.low { color: #2ecf83; }
.soc-severity.info { color: #5e8aff; }

.soc-metric {
  font-family: 'Chakra Petch', sans-serif;
  font-size: 16px;
  font-weight: 700;
  color: #f1f5fb;
}

.soc-label {
  font-family: 'JetBrains Mono', monospace;
  font-size: 8px;
  color: #455067;
  letter-spacing: 0.5px;
}

/* NMAP / NETWORK animation */
.anim-network {
  position: relative;
  overflow: hidden;
}

.network-nodes {
  position: absolute;
  inset: 0;
}

.net-node {
  position: absolute;
  width: 8px; height: 8px;
  background: #3a6dff;
  border-radius: 50%;
  box-shadow: 0 0 8px #3a6dff;
  animation: node-ping 2s infinite;
}

.net-node:nth-child(1) { top: 20%; left: 15%; animation-delay: 0s; }
.net-node:nth-child(2) { top: 50%; left: 35%; animation-delay: 0.3s; background: #5ec8ff; }
.net-node:nth-child(3) { top: 25%; left: 55%; animation-delay: 0.6s; }
.net-node:nth-child(4) { top: 65%; left: 60%; animation-delay: 0.9s; background: #2ecf83; }
.net-node:nth-child(5) { top: 70%; left: 25%; animation-delay: 1.2s; }
.net-node:nth-child(6) { top: 35%; left: 78%; animation-delay: 1.5s; background: #ffa940; }

@keyframes node-ping {
  0%, 100% { transform: scale(1); opacity: 0.7; }
  50% { transform: scale(1.4); opacity: 1; box-shadow: 0 0 16px currentColor; }
}

.net-terminal {
  position: absolute;
  bottom: 12px;
  left: 12px;
  right: 12px;
  font-family: 'JetBrains Mono', monospace;
  font-size: 9px;
  color: #3a6dff;
  letter-spacing: 0.5px;
  line-height: 1.6;
}

.net-scan-progress {
  position: absolute;
  bottom: 0; left: 0;
  height: 2px;
  background: linear-gradient(90deg, #3a6dff, #5ec8ff);
  animation: scan-progress 3s ease-in-out infinite;
}

@keyframes scan-progress {
  0% { width: 0; }
  60% { width: 100%; }
  100% { width: 100%; opacity: 0; }
}

/* LAB ENVIRONMENT animation */
.anim-lab {
  padding: 16px;
  display: flex;
  gap: 10px;
  align-items: center;
  justify-content: center;
  height: 100%;
}

.lab-vm {
  flex: 1;
  background: rgba(58,109,255,0.05);
  border: 1px solid rgba(58,109,255,0.25);
  border-radius: 6px;
  padding: 10px 8px;
  text-align: center;
  transition: all 0.3s;
  animation: lab-heartbeat 4s infinite;
}

.lab-vm:nth-child(1) { animation-delay: 0s; }
.lab-vm:nth-child(3) { animation-delay: 1s; }
.lab-vm:nth-child(5) { animation-delay: 2s; }

@keyframes lab-heartbeat {
  0%, 100% { border-color: rgba(58,109,255,0.25); }
  50% { border-color: rgba(58,109,255,0.6); box-shadow: 0 0 12px rgba(58,109,255,0.2); }
}

.lab-vm-icon {
  font-family: 'JetBrains Mono', monospace;
  font-size: 18px;
  margin-bottom: 4px;
}

.lab-vm-label {
  font-family: 'JetBrains Mono', monospace;
  font-size: 8px;
  color: #5e8aff;
  letter-spacing: 1px;
}

.lab-arrow {
  font-family: 'JetBrains Mono', monospace;
  color: #3a6dff;
  font-size: 14px;
  animation: arrow-pulse 2s infinite;
}

@keyframes arrow-pulse {
  0%, 100% { opacity: 0.3; }
  50% { opacity: 1; }
}

/* AI / NLP animation */
.anim-ai {
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  justify-content: center;
  height: 100%;
}

.ai-bar {
  display: flex;
  align-items: center;
  gap: 10px;
}

.ai-label {
  font-family: 'JetBrains Mono', monospace;
  font-size: 9px;
  color: #6c7d99;
  letter-spacing: 1px;
  width: 40px;
  flex-shrink: 0;
}

.ai-bar-track {
  flex: 1;
  height: 6px;
  background: rgba(58,109,255,0.1);
  border-radius: 3px;
  overflow: hidden;
  position: relative;
}

.ai-bar-fill {
  height: 100%;
  border-radius: 3px;
  animation: ai-fill 3s ease-in-out infinite;
}

.ai-bar-fill.human { background: linear-gradient(90deg, #3a6dff, #5e8aff); animation-delay: 0s; }
.ai-bar-fill.bot { background: linear-gradient(90deg, #ff4d6d, #ffa940); animation-delay: 0.5s; }
.ai-bar-fill.conf { background: linear-gradient(90deg, #2ecf83, #5ec8ff); animation-delay: 1s; }

@keyframes ai-fill {
  0% { width: 20%; }
  60% { width: var(--fill-w, 75%); }
  100% { width: var(--fill-w, 75%); }
}

.ai-bar:nth-child(1) .ai-bar-fill { --fill-w: 78%; }
.ai-bar:nth-child(2) .ai-bar-fill { --fill-w: 22%; }
.ai-bar:nth-child(3) .ai-bar-fill { --fill-w: 91%; }

.ai-score {
  font-family: 'JetBrains Mono', monospace;
  font-size: 9px;
  color: #5e8aff;
  width: 32px;
  text-align: right;
  flex-shrink: 0;
}

/* DATA / PYTHON animation */
.anim-data {
  padding: 16px;
  font-family: 'JetBrains Mono', monospace;
  font-size: 9px;
  line-height: 1.8;
  color: #3a6dff;
  overflow: hidden;
}

.data-line {
  opacity: 0;
  animation: data-stream 0.4s forwards;
  white-space: nowrap;
  overflow: hidden;
}

.data-line:nth-child(1) { animation-delay: 0.1s; }
.data-line:nth-child(2) { animation-delay: 0.3s; }
.data-line:nth-child(3) { animation-delay: 0.5s; color: #5ec8ff; }
.data-line:nth-child(4) { animation-delay: 0.7s; }
.data-line:nth-child(5) { animation-delay: 0.9s; color: #2ecf83; }
.data-line:nth-child(6) { animation-delay: 1.1s; }
.data-line:nth-child(7) { animation-delay: 1.3s; color: #ffa940; }

@keyframes data-stream {
  from { opacity: 0; max-width: 0; }
  to { opacity: 1; max-width: 100%; }
}

/* DESKTOP APP animation */
.anim-desktop {
  padding: 12px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.desktop-titlebar {
  background: #141d33;
  border: 1px solid rgba(70,110,220,0.3);
  border-radius: 6px 6px 0 0;
  padding: 6px 10px;
  display: flex;
  align-items: center;
  gap: 6px;
}

.desktop-dots { display: flex; gap: 4px; }
.desktop-dot { width: 7px; height: 7px; border-radius: 50%; }
.desktop-dot.r { background: #ff4d6d; }
.desktop-dot.a { background: #ffa940; }
.desktop-dot.g { background: #2ecf83; }

.desktop-bar {
  flex: 1;
  background: rgba(58,109,255,0.1);
  height: 6px;
  border-radius: 3px;
  margin-left: 8px;
  position: relative;
  overflow: hidden;
}

.desktop-bar::after {
  content: '';
  position: absolute;
  top: 0; left: -100%;
  width: 50%;
  height: 100%;
  background: linear-gradient(90deg, transparent, #3a6dff, transparent);
  animation: desktop-load 2s infinite;
}

@keyframes desktop-load {
  to { left: 200%; }
}

.desktop-content {
  display: flex;
  gap: 6px;
  flex: 1;
}

.desktop-sidebar {
  width: 60px;
  background: rgba(58,109,255,0.05);
  border: 1px solid rgba(70,110,220,0.2);
  border-radius: 0 0 0 6px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 8px 6px;
}

.desktop-menu-item {
  height: 6px;
  background: rgba(58,109,255,0.2);
  border-radius: 2px;
  animation: menu-highlight 3s infinite;
}

.desktop-menu-item:nth-child(2) { animation-delay: 0.5s; background: rgba(58,109,255,0.4); }
.desktop-menu-item:nth-child(3) { animation-delay: 1s; }

@keyframes menu-highlight {
  0%, 100% { opacity: 0.4; }
  50% { opacity: 1; }
}

.desktop-main {
  flex: 1;
  background: rgba(58,109,255,0.03);
  border: 1px solid rgba(70,110,220,0.15);
  border-radius: 0 0 6px 0;
  padding: 8px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4px;
}

.desktop-cell {
  background: rgba(58,109,255,0.06);
  height: 20px;
  border-radius: 2px;
  animation: cell-fill 2s infinite;
}

.desktop-cell:nth-child(1) { animation-delay: 0s; }
.desktop-cell:nth-child(2) { animation-delay: 0.3s; }
.desktop-cell:nth-child(3) { animation-delay: 0.6s; }
.desktop-cell:nth-child(4) { animation-delay: 0.9s; }

@keyframes cell-fill {
  0%, 100% { opacity: 0.4; }
  50% { opacity: 1; }
}

/* OOP / JAVA animation */
.anim-oop {
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  justify-content: center;
}

.oop-class {
  display: flex;
  align-items: center;
  gap: 10px;
}

.oop-box {
  background: rgba(58,109,255,0.08);
  border: 1px solid rgba(58,109,255,0.3);
  padding: 5px 10px;
  font-family: 'JetBrains Mono', monospace;
  font-size: 9px;
  color: #5e8aff;
  letter-spacing: 0.5px;
  animation: oop-glow 3s infinite;
  flex-shrink: 0;
}

.oop-box.parent { border-color: #5ec8ff; color: #5ec8ff; }
.oop-box.child1 { animation-delay: 0.5s; }
.oop-box.child2 { animation-delay: 1s; }

@keyframes oop-glow {
  0%, 100% { box-shadow: none; }
  50% { box-shadow: 0 0 12px rgba(58,109,255,0.3); }
}

.oop-arrow {
  font-family: 'JetBrains Mono', monospace;
  font-size: 10px;
  color: #3a6dff;
}

.oop-line {
  flex: 1;
  height: 1px;
  background: linear-gradient(90deg, rgba(58,109,255,0.5), transparent);
}

/* DASHBOARD animation */
.anim-dashboard {
  padding: 14px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.dash-kpi {
  background: rgba(58,109,255,0.05);
  border: 1px solid rgba(70,110,220,0.2);
  padding: 8px 10px;
  border-radius: 4px;
  animation: dash-update 4s infinite;
}

.dash-kpi:nth-child(1) { animation-delay: 0s; }
.dash-kpi:nth-child(2) { animation-delay: 1s; }
.dash-kpi:nth-child(3) { animation-delay: 2s; }
.dash-kpi:nth-child(4) { animation-delay: 3s; }

@keyframes dash-update {
  0%, 80%, 100% { border-color: rgba(70,110,220,0.2); }
  90% { border-color: rgba(58,109,255,0.6); background: rgba(58,109,255,0.1); }
}

.dash-kpi-val {
  font-family: 'Chakra Petch', sans-serif;
  font-size: 18px;
  font-weight: 700;
  color: #5e8aff;
  letter-spacing: -0.5px;
}

.dash-kpi-label {
  font-family: 'JetBrains Mono', monospace;
  font-size: 8px;
  color: #455067;
  letter-spacing: 1px;
  margin-top: 2px;
}

/* PROFESSIONAL / BUSINESS animation */
.anim-professional {
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  justify-content: center;
}

.prof-row {
  display: flex;
  align-items: center;
  gap: 10px;
}

.prof-metric {
  font-family: 'Chakra Petch', sans-serif;
  font-size: 14px;
  font-weight: 700;
  color: #ffa940;
  width: 48px;
  flex-shrink: 0;
}

.prof-bar-track {
  flex: 1;
  height: 5px;
  background: rgba(255,169,64,0.1);
  border-radius: 3px;
  overflow: hidden;
}

.prof-bar-fill {
  height: 100%;
  background: linear-gradient(90deg, #ffa940, #ff6b35);
  border-radius: 3px;
  animation: prof-bar 3s ease-out infinite;
}

.prof-bar-fill.w90 { --pw: 90%; }
.prof-bar-fill.w75 { --pw: 75%; animation-delay: 0.3s; }
.prof-bar-fill.w85 { --pw: 85%; animation-delay: 0.6s; }

@keyframes prof-bar {
  0% { width: 0; }
  60% { width: var(--pw, 80%); }
  100% { width: var(--pw, 80%); }
}

.prof-label {
  font-family: 'JetBrains Mono', monospace;
  font-size: 8px;
  color: #6c7d99;
  letter-spacing: 1px;
  width: 60px;
  text-align: right;
  flex-shrink: 0;
}

/* COMMUNITY animation */
.anim-community {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 8px;
  padding: 20px;
}

.community-counter {
  font-family: 'Chakra Petch', sans-serif;
  font-size: 48px;
  font-weight: 700;
  background: linear-gradient(135deg, #ff4d6d, #ffa940);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  letter-spacing: -2px;
  line-height: 1;
}

.community-sub {
  font-family: 'JetBrains Mono', monospace;
  font-size: 11px;
  color: #6c7d99;
  letter-spacing: 2px;
  text-transform: uppercase;
}

.community-dots {
  display: flex;
  gap: 4px;
  flex-wrap: wrap;
  max-width: 160px;
  justify-content: center;
}

.community-dot {
  width: 5px; height: 5px;
  background: #ff4d6d;
  border-radius: 50%;
  opacity: 0;
  animation: dot-appear 0.1s forwards;
}

/* ---- CARD BODY ---- */
.card-body {
  padding: 24px;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.card-category-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: 'JetBrains Mono', monospace;
  font-size: 9px;
  letter-spacing: 2px;
  text-transform: uppercase;
  padding: 4px 10px;
  border: 1px solid;
  margin-bottom: 14px;
  width: fit-content;
}

.card-category-badge.cyber { color: #5e8aff; border-color: rgba(94,138,255,0.3); background: rgba(94,138,255,0.06); }
.card-category-badge.software { color: #2ecf83; border-color: rgba(46,207,131,0.3); background: rgba(46,207,131,0.06); }
.card-category-badge.professional { color: #ffa940; border-color: rgba(255,169,64,0.3); background: rgba(255,169,64,0.06); }
.card-category-badge.community { color: #ff4d6d; border-color: rgba(255,77,109,0.3); background: rgba(255,77,109,0.06); }

.card-title {
  font-family: 'Chakra Petch', sans-serif;
  font-size: 18px;
  font-weight: 600;
  color: #f1f5fb;
  letter-spacing: -0.3px;
  margin-bottom: 10px;
  line-height: 1.3;
}

.card-summary {
  font-size: 13px;
  color: #6c7d99;
  line-height: 1.7;
  margin-bottom: 16px;
  flex: 1;
}

.card-tools {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  margin-bottom: 16px;
}

.tool-badge {
  font-family: 'JetBrains Mono', monospace;
  font-size: 9px;
  padding: 3px 8px;
  background: rgba(58,109,255,0.06);
  border: 1px solid rgba(58,109,255,0.2);
  color: #5e8aff;
  letter-spacing: 0.5px;
  transition: all 0.2s;
}

.tool-badge:hover {
  background: rgba(58,109,255,0.15);
  border-color: #3a6dff;
  box-shadow: 0 0 8px rgba(58,109,255,0.2);
}

.card-status {
  display: flex;
  align-items: center;
  gap: 8px;
  font-family: 'JetBrains Mono', monospace;
  font-size: 10px;
  color: #2ecf83;
  letter-spacing: 1px;
  margin-bottom: 16px;
}

.card-status::before {
  content: '';
  width: 6px; height: 6px;
  background: #2ecf83;
  border-radius: 50%;
  box-shadow: 0 0 6px #2ecf83;
  animation: status-blink 2s infinite;
}

@keyframes status-blink {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.4; }
}

.card-status.academic { color: #5e8aff; }
.card-status.academic::before { background: #5e8aff; box-shadow: 0 0 6px #5e8aff; }

.card-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  padding-top: 16px;
  border-top: 1px dashed rgba(70,110,220,0.2);
}

.card-btn {
  font-family: 'JetBrains Mono', monospace;
  font-size: 10px;
  padding: 8px 14px;
  border: 1px solid;
  letter-spacing: 1px;
  text-transform: uppercase;
  cursor: none;
  transition: all 0.2s;
  background: transparent;
}

.card-btn.primary {
  border-color: #3a6dff;
  color: #5e8aff;
}

.card-btn.primary:hover {
  background: #3a6dff;
  color: #fff;
  box-shadow: 0 0 16px rgba(58,109,255,0.4);
}

.card-btn.secondary {
  border-color: rgba(70,110,220,0.25);
  color: #6c7d99;
}

.card-btn.secondary:hover {
  border-color: #3a6dff;
  color: #5e8aff;
}

/* ============================================
   PROJECT MODAL
   ============================================ */
.proj-modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(5,7,13,0.92);
  backdrop-filter: blur(12px);
  z-index: 9500;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.proj-modal-overlay.open { display: flex; }

.proj-modal {
  width: min(900px, 100%);
  max-height: 90vh;
  background: #0a0f1c;
  border: 1px solid rgba(70,110,220,0.4);
  border-radius: 12px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  box-shadow: 0 32px 80px rgba(0,0,0,0.8), 0 0 60px rgba(58,109,255,0.08);
  animation: modal-in 0.3s ease;
}

@keyframes modal-in {
  from { opacity: 0; transform: translateY(24px) scale(0.97); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

.modal-header {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 20px 28px;
  background: linear-gradient(135deg, #0f1626, #0a0f1c);
  border-bottom: 1px solid rgba(70,110,220,0.2);
  flex-shrink: 0;
}

.modal-header-info { flex: 1; min-width: 0; }

.modal-title {
  font-family: 'Chakra Petch', sans-serif;
  font-size: 22px;
  font-weight: 700;
  color: #f1f5fb;
  letter-spacing: -0.5px;
  margin-bottom: 4px;
}

.modal-subtitle {
  font-family: 'JetBrains Mono', monospace;
  font-size: 11px;
  color: #6c7d99;
  letter-spacing: 1px;
}

.modal-close {
  width: 36px; height: 36px;
  background: rgba(58,109,255,0.08);
  border: 1px solid rgba(70,110,220,0.25);
  border-radius: 6px;
  color: #6c7d99;
  font-size: 18px;
  cursor: none;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s;
  flex-shrink: 0;
}

.modal-close:hover { color: #f1f5fb; border-color: #3a6dff; background: rgba(58,109,255,0.15); }

.modal-body {
  overflow-y: auto;
  flex: 1;
  padding: 28px;
}

.modal-body::-webkit-scrollbar { width: 5px; }
.modal-body::-webkit-scrollbar-track { background: transparent; }
.modal-body::-webkit-scrollbar-thumb { background: rgba(70,110,220,0.3); border-radius: 3px; }

/* Modal content sections */
.modal-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  margin-bottom: 24px;
}

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

.modal-block {
  background: #0f1626;
  border: 1px solid rgba(70,110,220,0.2);
  padding: 20px;
  position: relative;
}

.modal-block::before {
  content: '';
  position: absolute;
  top: 0; left: 0;
  width: 3px; height: 100%;
  background: linear-gradient(180deg, #3a6dff, transparent);
}

.modal-block.full { grid-column: span 2; }
@media (max-width: 640px) { .modal-block.full { grid-column: span 1; } }

.modal-block-label {
  font-family: 'JetBrains Mono', monospace;
  font-size: 10px;
  color: #3a6dff;
  letter-spacing: 2px;
  text-transform: uppercase;
  margin-bottom: 12px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.modal-block-label::after {
  content: '';
  flex: 1;
  height: 1px;
  background: rgba(70,110,220,0.2);
}

.modal-block p {
  font-size: 14px;
  color: #cbd5e8;
  line-height: 1.8;
}

.modal-block ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.modal-block ul li {
  font-size: 13px;
  color: #cbd5e8;
  padding-left: 18px;
  position: relative;
  line-height: 1.6;
}

.modal-block ul li::before {
  content: '▸';
  position: absolute;
  left: 0;
  color: #3a6dff;
}

.modal-tools-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.modal-skills-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.modal-skill-pill {
  font-family: 'JetBrains Mono', monospace;
  font-size: 10px;
  padding: 5px 12px;
  background: rgba(58,109,255,0.08);
  border: 1px solid rgba(58,109,255,0.25);
  color: #5e8aff;
  letter-spacing: 0.5px;
}

/* Workflow chain in modal */
.modal-workflow {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 8px;
}

.workflow-step {
  font-family: 'JetBrains Mono', monospace;
  font-size: 10px;
  padding: 6px 12px;
  background: rgba(58,109,255,0.06);
  border: 1px solid rgba(58,109,255,0.25);
  color: #5e8aff;
  letter-spacing: 0.5px;
  transition: all 0.2s;
}

.workflow-step:hover { background: rgba(58,109,255,0.15); border-color: #3a6dff; }

.workflow-arrow {
  color: #3a6dff;
  font-size: 12px;
  font-family: 'JetBrains Mono', monospace;
}

/* Modal file links */
.modal-links {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 10px;
}

.modal-link-btn {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 16px;
  background: #0f1626;
  border: 1px solid rgba(70,110,220,0.25);
  color: #cbd5e8;
  font-family: 'JetBrains Mono', monospace;
  font-size: 11px;
  letter-spacing: 0.5px;
  transition: all 0.2s;
  cursor: none;
  text-decoration: none;
}

.modal-link-btn:hover {
  border-color: #3a6dff;
  background: rgba(58,109,255,0.08);
  color: #5e8aff;
  transform: translateX(4px);
}

.modal-link-btn svg { width: 16px; height: 16px; color: #3a6dff; flex-shrink: 0; }

.modal-link-btn.placeholder { opacity: 0.45; }
.modal-link-btn.placeholder:hover { opacity: 0.65; cursor: none; }

/* Modal security note */
.modal-security-note {
  background: rgba(58,109,255,0.04);
  border: 1px solid rgba(58,109,255,0.15);
  padding: 14px 18px;
  font-family: 'JetBrains Mono', monospace;
  font-size: 11px;
  color: #6c7d99;
  letter-spacing: 0.5px;
  line-height: 1.7;
  display: flex;
  gap: 12px;
  align-items: flex-start;
}

.modal-security-note::before {
  content: '⚠';
  color: #ffa940;
  font-size: 14px;
  flex-shrink: 0;
  margin-top: 2px;
}

/* ============================================
   BACK TO TOP / NAV UTILITY
   ============================================ */
.back-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: 'JetBrains Mono', monospace;
  font-size: 11px;
  color: #6c7d99;
  letter-spacing: 1px;
  text-transform: uppercase;
  padding: 10px 18px;
  border: 1px solid rgba(70,110,220,0.25);
  transition: all 0.2s;
  text-decoration: none;
  cursor: none;
}

.back-btn:hover { border-color: #3a6dff; color: #5e8aff; }

/* Spin utility */
@keyframes spin { to { transform: rotate(360deg); } }

/* ============================================
   ROYAL UPGRADES — Projects Page Polish
   ============================================ */

/* Category icon — gold tinted on hover for prestige */
.proj-cat-icon {
  position: relative;
  transition: all 0.3s;
}

.proj-cat-head:hover .proj-cat-icon {
  border-color: rgba(212, 168, 87, 0.4);
  background: rgba(212, 168, 87, 0.08);
  color: #f4c574;
}

/* Project hero h1 em — royal blue to gold gradient */
.proj-hero h1 em {
  background: linear-gradient(135deg, #5e8aff 0%, #5ec8ff 50%, #f4c574 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  filter: drop-shadow(0 0 24px rgba(58, 109, 255, 0.18));
}

/* Filter button active — gold accent dot */
.filter-btn.active::before {
  content: '◆';
  color: #f4c574;
  margin-right: 6px;
  font-size: 8px;
  vertical-align: middle;
}

/* Project card shimmer effect on hover */
.proj-card {
  position: relative;
}

.proj-card .card-body::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(115deg,
    transparent 30%,
    rgba(212, 168, 87, 0.05) 50%,
    transparent 70%);
  background-size: 200% 100%;
  background-position: -100% 0;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.4s;
}

.proj-card:hover .card-body::before {
  opacity: 1;
  animation: proj-shimmer 2s ease-in-out infinite;
}

@keyframes proj-shimmer {
  0% { background-position: -100% 0; }
  100% { background-position: 200% 0; }
}

/* Card title hover — subtle gold underline */
.proj-card .card-title {
  position: relative;
  transition: color 0.2s;
}

.proj-card:hover .card-title {
  color: #ffffff;
}

/* Modal title — royal feel */
.modal-title {
  background: linear-gradient(135deg, #f1f5fb, #d4a857 200%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

/* Modal block-label — gold diamond prefix */
.modal-block-label::before {
  content: '◆';
  color: #d4a857;
  margin-right: 6px;
  font-size: 9px;
}

/* Workflow steps — premium hover */
.workflow-step {
  position: relative;
  overflow: hidden;
}

.workflow-step::before {
  content: '';
  position: absolute;
  top: 0; left: -100%;
  width: 100%; height: 100%;
  background: linear-gradient(90deg, transparent, rgba(212, 168, 87, 0.12), transparent);
  transition: left 0.4s;
}

.workflow-step:hover::before {
  left: 100%;
}

/* Terminal hero — gold cursor blink */
.terminal-body::after {
  content: '_';
  display: inline-block;
  color: #d4a857;
  animation: term-blink 1s steps(1) infinite;
  margin-left: 4px;
  font-family: 'JetBrains Mono', monospace;
  font-size: 12px;
}

@keyframes term-blink {
  0%, 50% { opacity: 1; }
  51%, 100% { opacity: 0; }
}

/* Modal close — royal hover */
.modal-close:hover {
  border-color: #d4a857;
  background: rgba(212, 168, 87, 0.08);
  color: #f4c574;
}

/* Reduce motion */
@media (prefers-reduced-motion: reduce) {
  .proj-card:hover .card-body::before,
  .workflow-step:hover::before,
  .terminal-body::after { animation: none !important; }
}
