/* ==========================================================================
   CVIP LAB - ADVANCED MODERN THEME & DESIGN SYSTEM
   Computer Vision & Image Processing Research Laboratory
   ========================================================================== */

@import url('https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:ital,wght@0,300;0,400;0,500;0,600;0,700;0,800;1,400&family=Vazirmatn:wght@300;400;500;600;700;800;900&family=Fira+Code:wght@400;500;600&display=swap');

:root {
  /* Color Palette - Dark Theme (Default Tech Mode) */
  --bg-primary: #0a0e1a;
  --bg-secondary: #0f172a;
  --bg-tertiary: #1e293b;
  --bg-card: rgba(15, 23, 42, 0.75);
  --bg-card-hover: rgba(30, 41, 59, 0.85);
  --bg-glass: rgba(15, 23, 42, 0.65);
  --border-color: rgba(255, 255, 255, 0.08);
  --border-glow: rgba(56, 189, 248, 0.35);

  --text-primary: #f8fafc;
  --text-secondary: #94a3b8;
  --text-muted: #64748b;

  --accent-blue: #3b82f6;
  --accent-cyan: #06b6d4;
  --accent-indigo: #6366f1;
  --accent-purple: #a855f7;
  --accent-emerald: #10b981;
  --accent-amber: #f59e0b;
  --accent-rose: #f43f5e;

  --gradient-hero: linear-gradient(135deg, #0a0e1a 0%, #0f172a 50%, #1e1b4b 100%);
  --gradient-accent: linear-gradient(135deg, #38bdf8 0%, #3b82f6 50%, #818cf8 100%);
  --gradient-glow: linear-gradient(135deg, rgba(56, 189, 248, 0.15), rgba(99, 102, 241, 0.15));
  --gradient-card: linear-gradient(180deg, rgba(30, 41, 59, 0.6) 0%, rgba(15, 23, 42, 0.8) 100%);

  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.2);
  --shadow-md: 0 8px 24px rgba(0, 0, 0, 0.3);
  --shadow-lg: 0 16px 40px rgba(0, 0, 0, 0.4);
  --shadow-glow: 0 0 25px rgba(56, 189, 248, 0.2);

  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 20px;
  --radius-xl: 28px;
  --radius-full: 9999px;

  --font-en: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-fa: 'Vazirmatn', system-ui, -apple-system, sans-serif;
  --font-code: 'Fira Code', monospace;

  --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-slow: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Light Mode Overrides */
[data-theme="light"] {
  --bg-primary: #f8fafc;
  --bg-secondary: #f1f5f9;
  --bg-tertiary: #e2e8f0;
  --bg-card: rgba(255, 255, 255, 0.9);
  --bg-card-hover: #ffffff;
  --bg-glass: rgba(255, 255, 255, 0.8);
  --border-color: rgba(0, 0, 0, 0.08);
  --border-glow: rgba(37, 99, 235, 0.3);

  --text-primary: #0f172a;
  --text-secondary: #475569;
  --text-muted: #64748b;

  --gradient-hero: linear-gradient(135deg, #f8fafc 0%, #e2e8f0 50%, #eff6ff 100%);
  --gradient-accent: linear-gradient(135deg, #0284c7 0%, #2563eb 50%, #4f46e5 100%);
  --gradient-glow: linear-gradient(135deg, rgba(37, 99, 235, 0.08), rgba(99, 102, 241, 0.08));
  --gradient-card: linear-gradient(180deg, rgba(255, 255, 255, 0.95) 0%, rgba(248, 250, 252, 0.9) 100%);

  --shadow-sm: 0 2px 8px rgba(15, 23, 42, 0.04);
  --shadow-md: 0 10px 30px rgba(15, 23, 42, 0.08);
  --shadow-lg: 0 20px 45px rgba(15, 23, 42, 0.12);
  --shadow-glow: 0 0 25px rgba(37, 99, 235, 0.15);
}

/* ==========================================================================
   Base & Reset
   ========================================================================== */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  font-family: var(--font-en);
  background-color: var(--bg-primary);
  color: var(--text-primary);
  line-height: 1.65;
  overflow-x: hidden;
  transition: background-color 0.4s ease, color 0.4s ease;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* Persian / RTL Mode */
html[dir="rtl"] body,
html[lang="fa"] body {
  font-family: var(--font-fa);
  direction: rtl;
  text-align: right;
}

a {
  color: inherit;
  text-decoration: none;
  transition: var(--transition);
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

button, input, textarea, select {
  font-family: inherit;
  font-size: inherit;
  color: inherit;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
  width: 10px;
}
::-webkit-scrollbar-track {
  background: var(--bg-primary);
}
::-webkit-scrollbar-thumb {
  background: var(--bg-tertiary);
  border-radius: var(--radius-full);
}
::-webkit-scrollbar-thumb:hover {
  background: var(--accent-blue);
}

/* ==========================================================================
   Typography & Utilities
   ========================================================================== */
.container {
  width: 100%;
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 24px;
}

.gradient-text {
  background: var(--gradient-accent);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  display: inline-block;
}

.section-title-wrap {
  text-align: center;
  margin-bottom: 48px;
  position: relative;
}

.section-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 16px;
  background: var(--gradient-glow);
  border: 1px solid var(--border-glow);
  border-radius: var(--radius-full);
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--accent-cyan);
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 16px;
}

html[dir="rtl"] .section-badge {
  letter-spacing: 0;
}

.section-title {
  font-size: 2.35rem;
  font-weight: 800;
  color: var(--text-primary);
  margin-bottom: 12px;
  letter-spacing: -0.5px;
}

.section-subtitle {
  font-size: 1.05rem;
  color: var(--text-secondary);
  max-width: 680px;
  margin: 0 auto;
}

/* Glassmorphism Card */
.glass-card {
  background: var(--bg-card);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
  transition: var(--transition);
  position: relative;
  overflow: hidden;
}

.glass-card:hover {
  transform: translateY(-4px);
  border-color: var(--border-glow);
  box-shadow: var(--shadow-glow), var(--shadow-lg);
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 12px 26px;
  border-radius: var(--radius-md);
  font-weight: 600;
  font-size: 0.95rem;
  cursor: pointer;
  border: none;
  outline: none;
  transition: var(--transition);
  position: relative;
  z-index: 1;
}

.btn-primary {
  background: var(--gradient-accent);
  color: #ffffff !important;
  box-shadow: 0 4px 18px rgba(37, 99, 235, 0.35);
}

.btn-primary:hover {
  box-shadow: 0 8px 25px rgba(37, 99, 235, 0.55);
  transform: translateY(-2px);
}

.btn-secondary {
  background: var(--bg-tertiary);
  color: var(--text-primary);
  border: 1px solid var(--border-color);
}

.btn-secondary:hover {
  background: var(--bg-card-hover);
  border-color: var(--border-glow);
  transform: translateY(-2px);
}

.btn-outline {
  background: transparent;
  color: var(--text-primary);
  border: 1px solid var(--border-color);
}

.btn-outline:hover {
  border-color: var(--accent-blue);
  color: var(--accent-cyan);
  background: rgba(56, 189, 248, 0.05);
}

.btn-sm {
  padding: 7px 14px;
  font-size: 0.82rem;
  border-radius: var(--radius-sm);
}

.btn-icon {
  width: 40px;
  height: 40px;
  padding: 0;
  border-radius: var(--radius-full);
}

/* ==========================================================================
   Navigation Bar
   ========================================================================== */
.navbar {
  position: sticky;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 1000;
  background: var(--bg-glass);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border-color);
  transition: var(--transition);
}

.navbar-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 76px;
}

.nav-brand {
  display: flex;
  align-items: center;
  gap: 14px;
  font-weight: 800;
  font-size: 1.25rem;
}

.nav-logo-icon {
  width: 44px;
  height: 44px;
  border-radius: var(--radius-md);
  background: var(--gradient-accent);
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  box-shadow: 0 4px 15px rgba(56, 189, 248, 0.35);
  flex-shrink: 0;
}

.nav-logo-icon svg {
  width: 24px;
  height: 24px;
}

.nav-brand-text {
  display: flex;
  flex-direction: column;
}

.nav-brand-title {
  color: var(--text-primary);
  line-height: 1.2;
  font-size: 1.15rem;
}

.nav-brand-sub {
  font-size: 0.72rem;
  color: var(--text-muted);
  font-weight: 500;
  letter-spacing: 0.5px;
}

.nav-menu {
  display: flex;
  align-items: center;
  gap: 6px;
  list-style: none;
}

.nav-item {
  position: relative;
}

.nav-link {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  font-size: 0.92rem;
  font-weight: 600;
  color: var(--text-secondary);
  border-radius: var(--radius-sm);
  transition: var(--transition);
}

.nav-link:hover, .nav-link.active {
  color: var(--text-primary);
  background: rgba(255, 255, 255, 0.05);
}

[data-theme="light"] .nav-link:hover, [data-theme="light"] .nav-link.active {
  background: rgba(0, 0, 0, 0.05);
}

/* Dropdown */
.nav-dropdown {
  position: absolute;
  top: 100%;
  left: 0;
  min-width: 220px;
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 8px;
  box-shadow: var(--shadow-lg);
  opacity: 0;
  visibility: hidden;
  transform: translateY(10px);
  transition: var(--transition);
  z-index: 100;
}

html[dir="rtl"] .nav-dropdown {
  left: auto;
  right: 0;
}

.nav-item:hover .nav-dropdown {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.nav-dropdown-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  font-size: 0.88rem;
  font-weight: 500;
  color: var(--text-secondary);
  border-radius: var(--radius-sm);
  transition: var(--transition);
}

.nav-dropdown-item:hover {
  background: var(--bg-tertiary);
  color: var(--accent-cyan);
}

/* Controls (Theme + Lang + Admin) */
.nav-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.theme-toggle, .lang-toggle {
  background: var(--bg-tertiary);
  border: 1px solid var(--border-color);
  color: var(--text-primary);
  width: 40px;
  height: 40px;
  border-radius: var(--radius-full);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: var(--transition);
}

.theme-toggle:hover, .lang-toggle:hover {
  border-color: var(--accent-blue);
  color: var(--accent-cyan);
  transform: scale(1.05);
}

.lang-toggle {
  width: auto;
  padding: 0 14px;
  font-weight: 700;
  font-size: 0.82rem;
}

.mobile-toggle {
  display: none;
  background: transparent;
  border: none;
  color: var(--text-primary);
  font-size: 1.5rem;
  cursor: pointer;
}

/* ==========================================================================
   Hero Section & Canvas
   ========================================================================== */
.hero-section {
  position: relative;
  min-height: 86vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 70px 0 50px 0;
  overflow: hidden;
  background: var(--gradient-hero);
}

#vision-canvas,
.page-canvas {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 1;
  opacity: 0.9;
}

.page-header {
  position: relative;
  overflow: hidden;
  padding: 135px 0 50px 0;
  background: var(--gradient-hero);
  text-align: center;
  border-bottom: 1px solid var(--border-color);
}

.page-header .container {
  position: relative;
  z-index: 3;
}

.hero-glow-1 {
  position: absolute;
  top: 15%;
  left: 10%;
  width: 450px;
  height: 450px;
  background: radial-gradient(circle, rgba(56, 189, 248, 0.18) 0%, rgba(56, 189, 248, 0) 70%);
  filter: blur(50px);
  pointer-events: none;
}

.hero-glow-2 {
  position: absolute;
  bottom: 10%;
  right: 10%;
  width: 500px;
  height: 500px;
  background: radial-gradient(circle, rgba(99, 102, 241, 0.18) 0%, rgba(99, 102, 241, 0) 70%);
  filter: blur(50px);
  pointer-events: none;
}

.hero-content {
  position: relative;
  z-index: 2;
  text-align: center;
  max-width: 960px;
  margin: 0 auto;
}

.hero-tag {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 20px;
  background: rgba(56, 189, 248, 0.1);
  border: 1px solid rgba(56, 189, 248, 0.3);
  border-radius: var(--radius-full);
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--accent-cyan);
  margin-bottom: 24px;
  box-shadow: 0 4px 15px rgba(56, 189, 248, 0.15);
  animation: pulse-glow 3s infinite alternate;
}

@keyframes pulse-glow {
  0% { box-shadow: 0 0 10px rgba(56, 189, 248, 0.2); }
  100% { box-shadow: 0 0 25px rgba(56, 189, 248, 0.45); }
}

.hero-title {
  font-size: 3.4rem;
  font-weight: 900;
  line-height: 1.2;
  letter-spacing: -1px;
  margin-bottom: 20px;
}

.hero-desc {
  font-size: 1.15rem;
  color: var(--text-secondary);
  line-height: 1.8;
  max-width: 800px;
  margin: 0 auto 36px auto;
}

.hero-actions {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 60px;
}

/* Hero Stats Bar */
.hero-stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
  margin-top: 20px;
}

.stat-item {
  padding: 24px;
  text-align: center;
  background: var(--bg-card);
  backdrop-filter: blur(12px);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  transition: var(--transition);
}

.stat-item:hover {
  transform: translateY(-5px);
  border-color: var(--border-glow);
  box-shadow: var(--shadow-glow);
}

.stat-number {
  font-size: 2.6rem;
  font-weight: 800;
  background: var(--gradient-accent);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  line-height: 1;
  margin-bottom: 8px;
}

.stat-label {
  font-size: 0.9rem;
  color: var(--text-secondary);
  font-weight: 600;
}

/* ==========================================================================
   Section Layouts
   ========================================================================== */
.section {
  padding: 90px 0;
  position: relative;
}

.section-alt {
  background: var(--bg-secondary);
}

/* Research Areas Grid */
.research-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 28px;
}

.research-card {
  padding: 32px;
  display: flex;
  flex-direction: column;
  height: 100%;
}

.research-icon {
  width: 56px;
  height: 56px;
  border-radius: var(--radius-md);
  background: var(--gradient-glow);
  border: 1px solid var(--border-glow);
  color: var(--accent-cyan);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 22px;
  font-size: 1.6rem;
  transition: var(--transition);
}

.research-card:hover .research-icon {
  transform: scale(1.1) rotate(5deg);
  background: var(--gradient-accent);
  color: white;
}

.research-title {
  font-size: 1.3rem;
  font-weight: 700;
  margin-bottom: 12px;
  color: var(--text-primary);
}

.research-desc {
  font-size: 0.95rem;
  color: var(--text-secondary);
  line-height: 1.7;
  flex-grow: 1;
  margin-bottom: 20px;
}

.research-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.tag {
  font-size: 0.78rem;
  font-weight: 600;
  padding: 4px 10px;
  border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.05);
  color: var(--text-secondary);
  border: 1px solid var(--border-color);
}

[data-theme="light"] .tag {
  background: rgba(0, 0, 0, 0.04);
}

/* ==========================================================================
   Faculty / Professors Spotlight
   ========================================================================== */
.professors-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(460px, 1fr));
  gap: 32px;
}

.prof-featured-card {
  display: flex;
  gap: 28px;
  padding: 36px;
  align-items: flex-start;
}

.prof-img-wrap {
  position: relative;
  flex-shrink: 0;
  width: 170px;
  height: 215px;
  border-radius: var(--radius-md);
  overflow: hidden;
  border: 2px solid var(--border-glow);
  box-shadow: var(--shadow-md);
}

.prof-img-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top;
  transition: transform 0.5s ease;
}

.prof-featured-card:hover .prof-img-wrap img {
  transform: scale(1.05);
}

.prof-info {
  flex-grow: 1;
}

.prof-badge {
  display: inline-block;
  font-size: 0.78rem;
  font-weight: 700;
  padding: 4px 12px;
  border-radius: var(--radius-full);
  background: rgba(59, 130, 246, 0.15);
  color: var(--accent-blue);
  margin-bottom: 8px;
}

.prof-name {
  font-size: 1.55rem;
  font-weight: 800;
  margin-bottom: 4px;
  color: var(--text-primary);
}

.prof-title {
  font-size: 0.95rem;
  color: var(--accent-cyan);
  font-weight: 600;
  margin-bottom: 12px;
}

.prof-field {
  font-size: 0.9rem;
  color: var(--text-secondary);
  margin-bottom: 16px;
  line-height: 1.6;
}

.prof-links {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 14px;
}

/* ==========================================================================
   Team / Students Section & Filter
   ========================================================================== */
.filter-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 20px;
  margin-bottom: 36px;
  background: var(--bg-card);
  padding: 16px 24px;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-color);
}

.filter-tabs {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.filter-btn {
  padding: 8px 18px;
  border-radius: var(--radius-full);
  font-size: 0.88rem;
  font-weight: 600;
  background: transparent;
  border: 1px solid transparent;
  color: var(--text-secondary);
  cursor: pointer;
  transition: var(--transition);
}

.filter-btn:hover {
  color: var(--text-primary);
  background: var(--bg-tertiary);
}

.filter-btn.active {
  background: var(--gradient-accent);
  color: #ffffff;
  box-shadow: 0 4px 14px rgba(37, 99, 235, 0.3);
}

.search-input-wrap {
  position: relative;
  min-width: 260px;
}

.search-input-wrap input {
  width: 100%;
  padding: 10px 16px 10px 42px;
  background: var(--bg-tertiary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-full);
  font-size: 0.9rem;
  color: var(--text-primary);
  outline: none;
  transition: var(--transition);
}

html[dir="rtl"] .search-input-wrap input {
  padding: 10px 42px 10px 16px;
}

.search-input-wrap input:focus {
  border-color: var(--accent-cyan);
  box-shadow: 0 0 12px rgba(6, 182, 212, 0.25);
}

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

html[dir="rtl"] .search-icon-pos {
  left: auto;
  right: 15px;
}

/* Students Grid */
.students-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 24px;
}

.student-card {
  padding: 24px;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.student-avatar {
  width: 100px;
  height: 100px;
  border-radius: 50%;
  object-fit: cover;
  border: 3px solid var(--border-glow);
  margin-bottom: 16px;
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
}

.student-card:hover .student-avatar {
  transform: scale(1.08);
  border-color: var(--accent-cyan);
}

.student-degree-badge {
  font-size: 0.72rem;
  font-weight: 700;
  padding: 3px 10px;
  border-radius: var(--radius-full);
  margin-bottom: 8px;
}

.badge-phd {
  background: rgba(168, 85, 247, 0.15);
  color: var(--accent-purple);
  border: 1px solid rgba(168, 85, 247, 0.3);
}

.badge-msc {
  background: rgba(56, 189, 248, 0.15);
  color: var(--accent-cyan);
  border: 1px solid rgba(56, 189, 248, 0.3);
}

.badge-alumni {
  background: rgba(16, 185, 129, 0.15);
  color: var(--accent-emerald);
  border: 1px solid rgba(16, 185, 129, 0.3);
}

.badge-bsc {
  background: rgba(245, 158, 11, 0.15);
  color: var(--accent-amber);
  border: 1px solid rgba(245, 158, 11, 0.3);
}

.student-name {
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 4px;
}

.student-major {
  font-size: 0.82rem;
  color: var(--text-muted);
  margin-bottom: 12px;
}

.student-thesis {
  font-size: 0.85rem;
  color: var(--text-secondary);
  line-height: 1.5;
  background: rgba(255, 255, 255, 0.03);
  padding: 10px;
  border-radius: var(--radius-sm);
  width: 100%;
  margin-bottom: 16px;
  flex-grow: 1;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

[data-theme="light"] .student-thesis {
  background: rgba(0, 0, 0, 0.02);
}

.student-card-actions {
  display: flex;
  gap: 8px;
  width: 100%;
  margin-top: auto;
}

/* ==========================================================================
   Publications List
   ========================================================================== */
.pub-list {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.pub-item {
  padding: 26px 30px;
  border-left: 4px solid var(--accent-blue);
  display: flex;
  flex-direction: column;
  gap: 12px;
}

html[dir="rtl"] .pub-item {
  border-left: none;
  border-right: 4px solid var(--accent-blue);
}

.pub-item:hover {
  border-color: var(--accent-cyan);
}

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

.pub-year-badge {
  font-size: 0.8rem;
  font-weight: 700;
  padding: 3px 12px;
  border-radius: var(--radius-full);
  background: rgba(56, 189, 248, 0.15);
  color: var(--accent-cyan);
}

.pub-venue-badge {
  font-size: 0.78rem;
  font-weight: 600;
  padding: 3px 10px;
  border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.05);
  color: var(--text-secondary);
}

.pub-title {
  font-size: 1.18rem;
  font-weight: 700;
  color: var(--text-primary);
  line-height: 1.45;
}

.pub-authors {
  font-size: 0.92rem;
  color: var(--text-secondary);
}

.pub-journal {
  font-size: 0.88rem;
  color: var(--text-muted);
  font-style: italic;
}

.pub-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 4px;
}

/* ==========================================================================
   Projects Showcase
   ========================================================================== */
.projects-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(360px, 1fr));
  gap: 28px;
}

.project-card {
  padding: 0;
  display: flex;
  flex-direction: column;
}

.project-img-wrap {
  width: 100%;
  height: 200px;
  overflow: hidden;
  position: relative;
  background: linear-gradient(135deg, #1e293b 0%, #0f172a 100%);
}

.project-img-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s ease;
}

.project-card:hover .project-img-wrap img {
  transform: scale(1.08);
}

.project-status-tag {
  position: absolute;
  top: 14px;
  right: 14px;
  padding: 4px 12px;
  border-radius: var(--radius-full);
  font-size: 0.75rem;
  font-weight: 700;
  backdrop-filter: blur(8px);
}

html[dir="rtl"] .project-status-tag {
  right: auto;
  left: 14px;
}

.status-active {
  background: rgba(16, 185, 129, 0.85);
  color: #ffffff;
}

.status-completed {
  background: rgba(59, 130, 246, 0.85);
  color: #ffffff;
}

.project-body {
  padding: 26px;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.project-title {
  font-size: 1.25rem;
  font-weight: 700;
  margin-bottom: 10px;
  color: var(--text-primary);
}

.project-desc {
  font-size: 0.92rem;
  color: var(--text-secondary);
  line-height: 1.6;
  margin-bottom: 18px;
  flex-grow: 1;
}

.project-tech {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 18px;
}

.tech-tag {
  font-size: 0.72rem;
  font-weight: 600;
  padding: 3px 8px;
  border-radius: var(--radius-sm);
  background: rgba(56, 189, 248, 0.1);
  color: var(--accent-cyan);
  border: 1px solid rgba(56, 189, 248, 0.2);
}

/* ==========================================================================
   News & Events
   ========================================================================== */
.news-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 24px;
}

.news-card {
  padding: 26px;
  display: flex;
  flex-direction: column;
}

.news-date {
  font-size: 0.82rem;
  color: var(--accent-cyan);
  font-weight: 700;
  margin-bottom: 8px;
  display: flex;
  align-items: center;
  gap: 6px;
}

.news-title {
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 10px;
  line-height: 1.4;
}

.news-excerpt {
  font-size: 0.9rem;
  color: var(--text-secondary);
  line-height: 1.6;
  flex-grow: 1;
  margin-bottom: 16px;
}

/* ==========================================================================
   Contact / Join Us Section
   ========================================================================== */
.contact-wrap {
  display: grid;
  grid-template-columns: 1fr 1.3fr;
  gap: 40px;
}

.contact-info-card {
  padding: 36px;
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.contact-item {
  display: flex;
  align-items: flex-start;
  gap: 16px;
}

.contact-icon {
  width: 44px;
  height: 44px;
  border-radius: var(--radius-md);
  background: var(--gradient-glow);
  color: var(--accent-cyan);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.contact-label {
  font-size: 0.85rem;
  color: var(--text-muted);
  font-weight: 600;
}

.contact-val {
  font-size: 0.95rem;
  color: var(--text-primary);
  font-weight: 500;
}

.contact-form {
  padding: 36px;
}

.form-group {
  margin-bottom: 20px;
}

.form-label {
  display: block;
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 8px;
}

.form-control {
  width: 100%;
  padding: 12px 16px;
  background: var(--bg-tertiary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  color: var(--text-primary);
  outline: none;
  transition: var(--transition);
}

.form-control:focus {
  border-color: var(--accent-cyan);
  box-shadow: 0 0 14px rgba(6, 182, 212, 0.25);
}

/* ==========================================================================
   Modal Dialogs
   ========================================================================== */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(10, 14, 26, 0.8);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  z-index: 2000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  opacity: 0;
  visibility: hidden;
  transition: var(--transition);
}

.modal-overlay.active {
  opacity: 1;
  visibility: visible;
}

.modal-card {
  width: 100%;
  max-width: 650px;
  background: var(--bg-secondary);
  border: 1px solid var(--border-glow);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  padding: 32px;
  position: relative;
  transform: scale(0.95);
  transition: var(--transition);
  max-height: 90vh;
  overflow-y: auto;
}

.modal-overlay.active .modal-card {
  transform: scale(1);
}

.modal-close {
  position: absolute;
  top: 20px;
  right: 20px;
  background: var(--bg-tertiary);
  border: none;
  color: var(--text-primary);
  width: 36px;
  height: 36px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

html[dir="rtl"] .modal-close {
  right: auto;
  left: 20px;
}

.bibtex-box {
  background: var(--bg-primary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 16px;
  font-family: var(--font-code);
  font-size: 0.85rem;
  color: var(--accent-cyan);
  white-space: pre-wrap;
  word-break: break-all;
  margin: 16px 0;
}

/* ==========================================================================
   Footer
   ========================================================================== */
.footer {
  margin-top: auto;
  background: var(--bg-secondary);
  border-top: 1px solid var(--border-color);
  padding: 70px 0 30px 0;
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1.5fr;
  gap: 40px;
  margin-bottom: 50px;
}

.footer-brand-desc {
  color: var(--text-secondary);
  font-size: 0.92rem;
  margin-top: 16px;
  line-height: 1.7;
  max-width: 360px;
}

.footer-heading {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 20px;
}

.footer-links {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.footer-links a {
  color: var(--text-secondary);
  font-size: 0.9rem;
  transition: var(--transition);
}

.footer-links a:hover {
  color: var(--accent-cyan);
  padding-left: 6px;
}

html[dir="rtl"] .footer-links a:hover {
  padding-left: 0;
  padding-right: 6px;
}

.footer-bottom {
  padding-top: 24px;
  border-top: 1px solid var(--border-color);
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
  font-size: 0.88rem;
  color: var(--text-muted);
}

/* ==========================================================================
   Responsive Breakpoints & Mobile Optimization
   ========================================================================== */

/* Large Laptops & Desktops (max-width: 1200px) */
@media (max-width: 1200px) {
  .container {
    max-width: 96%;
    padding: 0 20px;
  }
  .hero-title {
    font-size: clamp(2.2rem, 4vw, 3rem);
  }
  .footer-grid {
    grid-template-columns: 1.5fr 1fr 1fr 1.2fr;
    gap: 30px;
  }
}

/* Tablets & Small Laptops (max-width: 1024px) */
@media (max-width: 1024px) {
  .hero-title {
    font-size: clamp(1.9rem, 3.8vw, 2.7rem);
  }
  .hero-stats {
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
  }
  .professors-grid {
    grid-template-columns: 1fr;
  }
  .contact-wrap {
    grid-template-columns: 1fr;
  }
  .footer-grid {
    grid-template-columns: 1fr 1fr;
    gap: 36px;
  }
  .pillar-card {
    grid-template-columns: 1fr;
    gap: 20px;
  }
  .pillar-visual {
    height: 180px;
  }
}

/* Tablets & Mobile Landscape (max-width: 768px) */
@media (max-width: 768px) {
  .navbar-container {
    height: 70px;
  }

  .nav-brand-title {
    font-size: 0.98rem;
  }

  .nav-brand-sub {
    font-size: 0.72rem;
  }

  .nav-menu {
    position: fixed;
    top: 70px;
    left: 0;
    right: 0;
    width: 100%;
    max-height: calc(100vh - 70px);
    overflow-y: auto;
    background: var(--bg-secondary);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--border-color);
    box-shadow: var(--shadow-lg);
    flex-direction: column;
    padding: 24px 20px 36px 20px;
    gap: 10px;
    transform: translateY(-120%);
    opacity: 0;
    pointer-events: none;
    transition: all 0.35s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 999;
  }

  .nav-menu.active {
    transform: translateY(0);
    opacity: 1;
    pointer-events: auto;
  }

  .nav-link {
    width: 100%;
    padding: 12px 16px;
    border-radius: var(--radius-sm);
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid transparent;
  }

  .nav-link:hover, .nav-link.active {
    background: rgba(56, 189, 248, 0.1);
    border-color: rgba(56, 189, 248, 0.2);
  }

  .mobile-toggle {
    display: flex;
    align-items: center;
    justify-content: center;
  }

  /* Hero Section */
  .hero-section {
    padding: 130px 0 60px 0;
    min-height: auto;
  }

  .hero-title {
    font-size: clamp(1.75rem, 5.5vw, 2.3rem);
    line-height: 1.35;
  }

  .hero-desc {
    font-size: 0.98rem;
    margin-bottom: 30px;
  }

  .hero-actions {
    flex-direction: column;
    width: 100%;
    gap: 12px;
  }

  .hero-actions .btn {
    width: 100%;
    justify-content: center;
  }

  .hero-stats {
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
    margin-top: 40px;
  }

  .stat-item {
    padding: 18px 12px;
  }

  .stat-number {
    font-size: 1.8rem;
  }

  .stat-label {
    font-size: 0.78rem;
  }

  /* Faculty */
  .prof-featured-card, .prof-detail-card {
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 24px 18px;
  }

  .prof-img-wrap {
    width: 180px !important;
    height: 220px !important;
    margin: 0 auto 20px auto;
  }

  .prof-links {
    justify-content: center;
    flex-direction: column;
    width: 100%;
    gap: 10px;
  }

  .prof-links .btn {
    width: 100%;
    justify-content: center;
  }

  /* Filter Bar & Tabs Horizontal Touch Scroll */
  .filter-bar {
    flex-direction: column;
    align-items: stretch;
    gap: 16px;
  }

  .filter-tabs {
    display: flex;
    flex-wrap: nowrap;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    padding-bottom: 6px;
    gap: 8px;
    scrollbar-width: none;
  }

  .filter-tabs::-webkit-scrollbar {
    display: none;
  }

  .filter-btn {
    white-space: nowrap;
    flex-shrink: 0;
    padding: 9px 14px;
    font-size: 0.85rem;
  }

  .search-input-wrap {
    width: 100%;
  }

  .search-input-wrap input {
    font-size: 0.9rem;
    padding: 12px 14px 12px 42px;
  }

  html[dir="rtl"] .search-input-wrap input {
    padding: 12px 42px 12px 14px;
  }

  /* Grids */
  .students-grid {
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 16px;
  }

  .projects-grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .research-grid {
    grid-template-columns: 1fr;
    gap: 18px;
  }

  .pub-item {
    padding: 20px 16px;
  }

  .pub-actions {
    flex-direction: column;
    width: 100%;
  }

  .pub-actions .btn {
    width: 100%;
    justify-content: center;
  }

  /* Modals */
  .modal-card {
    width: 94% !important;
    max-width: 94% !important;
    max-height: 88vh;
    padding: 24px 16px !important;
    border-radius: var(--radius-lg);
  }

  .member-modal-content {
    flex-direction: column;
    align-items: center;
    text-align: center;
  }

  .member-modal-avatar {
    width: 120px;
    height: 150px;
    margin-bottom: 12px;
  }

  /* Page Headers */
  .page-header {
    padding: 110px 0 40px 0 !important;
  }

  .page-header .hero-title {
    font-size: 1.8rem !important;
  }

  .page-header .hero-desc {
    font-size: 0.92rem !important;
  }

  /* Footer */
  .footer {
    padding: 50px 0 24px 0;
  }

  .footer-grid {
    grid-template-columns: 1fr;
    gap: 32px;
  }

  .footer-bottom {
    flex-direction: column;
    text-align: center;
    gap: 12px;
  }
}

/* Small SmartPhones (max-width: 480px) */
@media (max-width: 480px) {
  .nav-brand-sub {
    display: none;
  }

  .nav-brand-title {
    font-size: 0.88rem;
    max-width: 170px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .lang-toggle {
    padding: 7px 10px;
    font-size: 0.78rem;
  }

  .btn-sm {
    padding: 7px 11px;
    font-size: 0.78rem;
  }

  .theme-toggle {
    width: 36px;
    height: 36px;
    font-size: 1rem;
  }

  .hero-stats {
    grid-template-columns: 1fr 1fr;
    gap: 10px;
  }

  .stat-item {
    padding: 14px 8px;
  }

  .stat-number {
    font-size: 1.55rem;
  }

  .stat-label {
    font-size: 0.72rem;
  }

  .students-grid {
    grid-template-columns: 1fr;
  }

  .student-card {
    padding: 22px 16px;
  }

  .student-card-actions {
    flex-direction: column;
  }

  .student-card-actions .btn {
    width: 100%;
    justify-content: center;
  }

  .contact-form {
    padding: 22px 16px;
  }

  .form-control {
    padding: 11px 14px;
    font-size: 0.88rem;
  }

  .glass-card {
    padding: 20px 16px !important;
  }
}

/* Ultra Small Screens (max-width: 360px) */
@media (max-width: 360px) {
  .navbar-container {
    padding: 0 12px;
  }
  .hero-stats {
    grid-template-columns: 1fr;
  }
}

